I have ported/rewritten Box2D physics engine to JavaScript, for cross-platform HTML5 game development. Planck.js includes entire Box2D algorithms, a simple HTML5 Testbed, more than 50 examples and some new game prototypes. The project is pre-released and there may still be minor issues, which I'm working to fix. So far I have spent more than 400 hours for developing this project and it consists of around 20k lines of code.
https://github.com/shakiba/planck.js
My main motivations for working on this project are:
- Taking advantage of Box2D's efforts, achievements and community knowledge
- Developing readable and maintainable JavaScript code
- Optimizing the library for web and mobile platforms
- Providing a JavaScrip-friendly API
Your feedback is highly appreciated, and I hope you use Planck.js to make some awesome games soon!