Physics.Arcade.Body#moves

moves : boolean

If you have a Body that is being moved around the world via a tween or a Group motion, but its local x/y position never
actually changes, then you should set Body.moves = false. Otherwise it will most likely fly off the screen.
If you want the physics system to move the body around, then set moves to true. Set to true to allow the Physics system to move this Body, otherwise false to move it manually.

Default Value
  • true
Source code: physics/arcade/Body.js (Line 315)
doc_phaser
2025-01-10 15:47:30
Comments
Leave a Comment

Please login to continue.