4. Box2D
A Open Source Physics Engine
• www.box2d.org
• Erin Catto, 2007, C++
• zlib License (good open source stuff)
• Angry Birds, Tiny Wings etc.
5. Box2D-web
JavaScript Awesomeness
http://code.google.com/p/box2dweb/
Note: There are one more port called Box2D-js, it is outdated, don’t use it.
6. Good thing to know
Otherwise stuff will be messy
• No pixels. Only meters.
• Convex, not conaves.
• Moving objects 0.1-10 m. Static 0.1-50 m.
• Only physics, no graphics.
7. “Bodies are soft bags with hard fixtures inside.”
Bodies Fixtures
• Contains fixture(s) • Density
• Position • Friction
• Angle • Has a shape
• Static or dynamic • Collision