HTML and CSS Reference
Chapter 9. Canvas Games: Part II
Geo Blaster Basic was constructed using pure paths for drawing. In its creation, we began to
cover some game-application-related topics, such as basic collision detection and state ma-
chines. In this chapter, we focus on using bitmaps and tile sheets for our game graphics, and
Along the way, we update the FrameRateCounter from Chapter 8 by adding in a step timer.
We also examine how we can eliminate the use of a tile sheet for rotations by precreating an
array of imageData instances using the getImageData() and putImageData() Canvas func-
In the second half of this chapter, we create another small turn-based strategy game using bit-
maps. This game is roughly based on the classic computer game, Daleks .