Updated for box2d demo.