SGDK Sprite Cache
Posted: Sun Jan 25, 2015 4:34 pm
I'm playing with the sprite engine, but I think that the cache system must be reviewed. I've made a video showing the problem.
There are 4 sprites, 3 of them doing the same looped animation, and another (player controlled) that changes the animation, to look up or down.
Making those 1 frame animations, makes the whole sprite cache, to refresh.. so all VDP space is rewritten, you can se a fps drop also.
I think that the sprite engine, must be some more flexible about this. Maybe defining a cache space for each sprite. In my example, I don't need tiles of 3 sprites to be reloaded, and its tiles should not be overwritten by another sprite.
Check out the video, it's sloppy but I hope it can help to show what I mean.
http://youtu.be/2SQHB0IiIJI
There are 4 sprites, 3 of them doing the same looped animation, and another (player controlled) that changes the animation, to look up or down.
Making those 1 frame animations, makes the whole sprite cache, to refresh.. so all VDP space is rewritten, you can se a fps drop also.
I think that the sprite engine, must be some more flexible about this. Maybe defining a cache space for each sprite. In my example, I don't need tiles of 3 sprites to be reloaded, and its tiles should not be overwritten by another sprite.
Check out the video, it's sloppy but I hope it can help to show what I mean.
http://youtu.be/2SQHB0IiIJI