var dt:Number=1/30; var y0:Number=_body.GetPosition().y; var y:Number=y0+_body.GetLinearVelocity().y*dt+_world.GetGravity().y*dt*dt; trace(y0, "y:"+y); b2Island中的实现: var l_gravity:b2Vec2=b.m_customGravity?b.m_customGravity:gravity; //===========…
var dt:Number=1/30; var y0:Number=_body.GetPosition().y; var y:Number=y0+_body.GetLinearVelocity().y*dt+_world.GetGravity().y*dt*dt; trace(y0, "y:"+y);…