I started working on a new project and was wondering how i could rotate sprites and came up with this. It's not very efficient but once the rotation is done, the rotated sprite is cached in the sprite sheet. Please use it with care :)
I hope this can be useful to someone else too! Happy coding!
good experiment
for real use, suggest: https://www.lexaloffle.com/bbs/?pid=78451 for realtime rotation, without blowing your spritesheet!
note: rotation caching is a good idea when using lua memory - many sprites can fit and be displayed in realtime (this is how I did Snow! before tline)
You can check a different way to do this here:
https://www.lexaloffle.com/bbs/?tid=38548
It's a bit more efficient
[Please log in to post a comment]