Disables the Arcade Physics Body of a Game Object, an array of Game Objects, or the children of a Group.
The difference between this and the disableBody
method is that you can pass arrays or Groups
to this method.
The body itself is not deleted, it just has its enable
property set to false, which
means you can re-enable it again at any point by passing it to enable World.enable
or World.add
.
name | type | description |
---|---|---|
object | Phaser.GameObjects.GameObject | Array.<Phaser.GameObjects.GameObject> | Phaser.GameObjects.Group | Array.<Phaser.GameObjects.Group> |
The object, or objects, on which to disable the bodies. |