HTML and CSS Reference
Advanced Cell-Based Animation
In the previous example, we simply flipped back and forth between two tiles on our tile sheet.
Next, we are going to create a method that uses a tile sheet to play through a series of im-
ages. First, let's look at the new tile sheet, created by using tiles from SpriteLib. Figure 4-7
shows the example sprite sheet, tanks_sheet.png ; we will refer back to this figure throughout
Figure 4-7. Example tile sheet
As you can see, it contains a number of 32×32 tiles that can be used in a game. We will not
create an entire game in this chapter, but we will examine how to use these tiles to create a
gamescreen.In Chapter 9 ,wewillcreateasimplemaze-chasegameusingsomeofthesetiles.