top of page
Search
cedarcantab

Box2D-Lite Walkthrough in Javascript: Body, World and Unconstrained Dynamics

Updated: Jun 10







All my Box2D-Lite posts have been transferred to my new blog site:



Sample Code


And here is the sample code. You should see the box falling from the sky. I've added a bit of angular velocity, so it should be rotating as it falls due to gravity. However, there is no collision detection yet so the box will fall straight through the ground and will continue falling in the virtual world forever.





Useful References






26 views0 comments

Recent Posts

See All

p2 naive broadphase

var Broadphase = require('../collision/Broadphase'); module.exports = NaiveBroadphase; /** * Naive broadphase implementation. Does N^2...

sopiro motor constranit

import { Matrix2, Vector2 } from "./math.js"; import { RigidBody } from "./rigidbody.js"; import { Settings } from "./settings.js";...

Comments


記事: Blog2_Post
bottom of page