This is an alternate method of doing tile animations. This method uses only a single tile per animation, making it easier to pack in a lot of animated tiles into a single tile. It's not the best way of doing this. It's just a way of doing this. :)
Basically it just cycles through the colors in the tile according to the order you want them to appear, and changes them to a new color, also set by you in the code. The upshot is you can fit entire simple animations into a single tile.
(BTW, I'm not claiming credit for this method... it's one of those things that I'm sure a thousand devs before me have figured out before, and probably 10x more efficient ways than I cranked out tonight.) :D
This is how I did the broken mirror portals on my Ghostbusters game. Worked incredibly well and saved on a lot of sprite space.
[Please log in to post a comment]