Update physicsEngine.js