A while back I noticed some new tweening engines for Haxe. That got me curious: can I build my own tweening engine?
Yes I can!
I named it Go, like “lets Go”.
(And like they say in a track from The Prodigy – Everybody In The Place, lets go )
You can check it out on github: https://github.com/MatthijsKamstra/go
There you can find more detailed explanation about how it works, so I only will show some basic code here:
Animate a sprite in 1.5 second to x and y position and call function when animation is done
Go.to(sprite, 1.5).x(100).y(200).onComplete(onCompleteHandler, ['hello']);
It was fun to write it, but I haven’t tested in all situations.
I have tested
lets.Go on targets flash/cpp/html5/neko.
But I wouldn’t use it in a production situation. It needs more testing.
Let me know what you think!