O'Reilly logo

Pro HTML5 Games by Aditya Ravi Shankar

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 4

image

Integrating The Physics Engine

In Chapter 2, we developed the basic framework for our game, Froot Wars, and in Chapter 3, we looked at how to simulate a game world in Box2D. Now it is time to put together all the pieces to complete our game.

In this chapter, we will continue where we left off at the end of Chapter 2. We will add entities to our levels, use Box2D to simulate these entities, and then animate these entities within the game. We will use these entities to create a couple of working levels, and we will add mouse interactivity so that we can play the game. Once we have a working game, we will add sounds, background music, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required