Phaser API Documentation

  Version: 
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: BEFORE_ADD
Phaser.Physics.Matter.Events.BEFORE_ADD
BEFORE_ADD

Description:

The Matter Physics Before Add Event.

This event is dispatched by a Matter Physics World instance at the start of the process when a new Body or Constraint is being added to the world.

Listen to it from a Scene using: this.matter.world.on('beforeadd', listener).

Parameters:

name type description
event Phaser.Physics.Matter.Events.BeforeAddEvent

The Add Event object.