modify the AnAL.lua
get the get getImageData()function support.
I don't know why can't cover to *.love file.
『QT』about click mouse to select the sprite(image)
-
- Prole
- Posts: 47
- Joined: Thu Sep 24, 2009 1:49 pm
Re: 『QT』about click mouse to select the sprite(image)
- Attachments
-
- testclick.zip
- anim for click
- (4.69 KiB) Downloaded 159 times
Re: 『QT』about click mouse to select the sprite(image)
You should ask about AnAL implementation or problems in the library threadpoorenglish wrote:modify the AnAL.lua
get the get getImageData()function support.
I don't know why can't cover to *.love file.
viewtopic.php?f=5&t=948
- TechnoCat
- Inner party member
- Posts: 1612
- Joined: Thu Jul 30, 2009 12:31 am
- Location: Milwaukee, WI
- Contact:
Re: 『QT』about click mouse to select the sprite(image)
If it works as loose files and not as a love file and you are Windows. Then your capital/lower case letters are wrong most likely.
-
- Prole
- Posts: 47
- Joined: Thu Sep 24, 2009 1:49 pm
Re: 『QT』about click mouse to select the sprite(image)
Work fine when I use the SciTE.
It seems the newFramebuffer error when create .love file.
attempt to call field 'newFramebuffer' <a nil value> stack traceback:
same found in the viewtopic.php?f=4&t=3891&p=39065&hilit= ... fer#p39065
I does not update the love to 0.80 version.
Work fine on the my another computer.
It seems the newFramebuffer error when create .love file.
attempt to call field 'newFramebuffer' <a nil value> stack traceback:
same found in the viewtopic.php?f=4&t=3891&p=39065&hilit= ... fer#p39065
I does not update the love to 0.80 version.
Work fine on the my another computer.
- Attachments
-
- AnAL_M2.love
- error newframebuffer.
- (4.38 KiB) Downloaded 127 times
Last edited by poorenglish on Mon Feb 06, 2012 11:57 am, edited 1 time in total.
- ston
- Prole
- Posts: 21
- Joined: Fri Jan 27, 2012 9:53 am
- Location: Holt, a small village in Wiltshire. We have cider!
Re: 『QT』about click mouse to select the sprite(image)
Morning :-)coffee wrote: Nice, your Z-code works but you probably have something wrong eating memory or infinite looping. I change and move some circles but some time after always crash.
It's some combination of mouse clicking which seems to upset it; if you just leave it alone it's stable. I need to understand more about love's theading model and what, if any, synchronisation needs to be done in the lua script. Anyway, hopefully it was of some help.
[edit] Think I've found the BUG now, if the mouse is released whilst these two lines of code are being executed in the mousepressed event handler:
table.remove(t, i)
table.insert(t, this_layer)
...then there's a window of opportunity for the mouse released code to run after the .remove call, but before the .insert, so the table won't then have an item at index [10]. I added a global 'm_pressed' flag which I set to true at the start of mousepressed() and false at the end. Then in mousereleased() I added:
Code: Select all
while m_pressed do
love.timer.sleep(1)
end
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: 『QT』about click mouse to select the sprite(image)
Ehm... I think not. LÖVE is not multithreaded (at least, unless you're using love.thread, but it doesn't sound like it), so handlers are run sequentially, not asynchronously.ston wrote:[edit] Think I've found the BUG now, if the mouse is released whilst these two lines of code are being executed in the mousepressed event handler:
table.remove(t, i)
table.insert(t, this_layer)
...then there's a window of opportunity for the mouse released code to run after the .remove call, but before the .insert, so the table won't then have an item at index [10].
Help us help you: attach a .love.
- ston
- Prole
- Posts: 21
- Joined: Fri Jan 27, 2012 9:53 am
- Location: Holt, a small village in Wiltshire. We have cider!
Re: 『QT』about click mouse to select the sprite(image)
Ah, thx for the info. Another theory bites the dustRobin wrote: Ehm... I think not. LÖVE is not multithreaded (at least, unless you're using love.thread, but it doesn't sound like it), so handlers are run sequentially, not asynchronously.
Who is online
Users browsing this forum: Bing [Bot] and 6 guests