Introduction

One of the much-heralded features of the new HTML5 Canvas tag is the capability to access pixel data directly. So far you haven’t played around with pixels, but in this chapter you see what it takes to inspect and manipulate pixels directly. As a practical application to use pixel data, you build a Lander-style game that involves flying a ship around a map using small bursts of thruster (see Figure 17-1). But first, this chapter takes a brief diversion into 2-D physics to get the basis to build Lander.

Figure 17-1: The final Lander game.

c17f001.tif

Get Professional HTML5 Mobile Game Development 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.