Phaser API Documentation

This is a beta release of our new docs system. Found an issue?
Please tell us about it in the #📖-newdocs-feedback channel on the Phaser Discord
Event: DRAG


The Matter Physics Drag Event.

This event is dispatched by a Matter Physics World instance when a Pointer Constraint is actively dragging a body. It is emitted each time the pointer moves.

Listen to it from a Scene using:'drag', listener).


name type description
body MatterJS.BodyType

The Body that is being dragged. This is a Matter Body, not a Phaser Game Object.

constraint Phaser.Physics.Matter.PointerConstraint

The Pointer Constraint that is dragging the body.

Since: 3.16.2