Chapter 17. Animating the Appearance of Sprites

You’re hopefully fairly comfortable with using sprites to create graphical objects that can move around the game screen and interact with each other. You’ve seen sprites in action in several programs’ examples and a couple of complete games. One thing you might have found missing in the sprites that you’ve worked with is that they don’t have any capability to change their appearance. Granted, being able to move around is certainly a huge benefit, but it would also be nice for some sprites to change their appearances every so often. For example, the guys moving across the screen in the Battle Office game would look much better if their legs were moving to give a more realistic impression that they ...

Get Sams Teach Yourself Game Programming in 24 Hours now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.