Show:

Matter.Pair

The Matter.Pair module contains methods for creating and manipulating collision pairs.

Methods

Matter.Pair.create

(collision, timestamp)
Pair

Creates a pair.

Parameters

  • collision Collision
  • timestamp Number

Returns

Pair

A new pair

Matter.Pair.id

(bodyA, bodyB)
String

Get the id for the given pair.

Parameters

Returns

String

Unique pairId

Matter.Pair.setActive

(pair, isActive, timestamp)

Set a pair as active or inactive.

Parameters

Matter.Pair.update

(pair, collision, timestamp)

Updates a pair given a collision.

Parameters

Item Index

0.11.0