@atilim or anyone that has "deep" tested animations with gideros... :-B
as you know i'm making tnt animator studio...
now... i'm trying to optimize the code...
but some doubt came in my mind...
1. using movieclip (used simply to draw single sprite and "emulating" timed animation with "MovieClip:gotoAndStop(frame) every n millisecs") i suspect to overload the system because for every frame it dispatches an Event.COMPLETE (imagine a game with 30-50 animated sprites on the screen!) and also the majority of movieclip functionality are not used...
2. using "timed" removechild addchild system like in bird animations example seems to me a more light solution but is 100% lua code (and i think is slower over movieclip that is in the Gideros C++ SDK)
what do you think ?
is better using solution 1 or 2 ?
:-?
Comments
For example, if you have 60 fps, then by inserting 60 same images in MovieClip, you'll get one second long "frame". And if same graphic is reused inside Gideros, wouldn't that be more optimal than using timers?
BTW is vacation over?
ho no!!! i'm using my wife laptop and using an "open" wifi connection!!!
www.tntengine.com
www.tntengine.com
and adding to the sdk Sprite:changeImage(newImage) (or Sprite:setImage(newImage)) where newImage is a bitmap .... to avoid use of removechild and addchild and speedup things a little bit ? =P~
;;) pleeeaaassee ;;)
www.tntengine.com
Website: http://www.castlegateinteractive.com
https://play.google.com/store/apps/developer?id=Castlegate+Interactive
yes! she is very understanding wife, but we work for IT company and both (me and her) we Need to connect to internet for check work (even on vacations yes... it's a curse) now she is sleeping with our baby... and i can't sleep (it's very hot temperature here now) so i'm "working" on tnt animator eheheheh!!!
www.tntengine.com
Website: http://www.castlegateinteractive.com
https://play.google.com/store/apps/developer?id=Castlegate+Interactive
Regarding MovieClip, I've also noticed that if I want to jump exactly 10 frames forward from whatever the current frame is I can't do that. I submitted an issue ab out it. Using the Bird Animation code as the basis of controlling frames allows me to jump the 10 frames. So I've debated if MovieClip is useful for what I need.
http://bugs.giderosmobile.com/issues/124
My apps: http://www.yummyyellow.com
Hopefully there is time-based Movieclip soon on the API (i think i saw it on roadmap somewhere)
update: yes time-based Movieclip is on roadmap http://bugs.giderosmobile.com/issues/63
http://www.nightspade.com
i've added this feature request some month ago! hope atilim will implement soon
www.tntengine.com
@GregBUG I think MovieClip:gotoAndStop(frame) is an great solution and it doesn't dispatch Event.COMPLETE. It's definitely faster than addChild/removeChild.
And about time based animations, most probably I'll implement it with the next version.
http://www.nightspade.com