You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/physics/matter-js/components/Collision.js
+10-3Lines changed: 10 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -13,7 +13,9 @@
13
13
varCollision={
14
14
15
15
/**
16
-
* Sets the collision category of this Game Object's Matter Body. This number must be a power of two between 2^0 (= 1) and 2^31. Two bodies with different collision groups (see {@link #setCollisionGroup}) will only collide if their collision categories are included in their collision masks (see {@link #setCollidesWith}).
16
+
* Sets the collision category of this Game Object's Matter Body. This number must be a power of two between 2^0 (= 1) and 2^31.
17
+
* Two bodies with different collision groups (see {@link #setCollisionGroup}) will only collide if their collision
18
+
* categories are included in their collision masks (see {@link #setCollidesWith}).
* Sets the collision group of this Game Object's Matter Body. If this is zero or two Matter Bodies have different values, they will collide according to the usual rules (see {@link #setCollisionCategory} and {@link #setCollisionGroup}). If two Matter Bodies have the same positive value, they will always collide; if they have the same negative value, they will never collide.
35
+
* Sets the collision group of this Game Object's Matter Body. If this is zero or two Matter Bodies have different values,
36
+
* they will collide according to the usual rules (see {@link #setCollisionCategory} and {@link #setCollisionGroup}).
37
+
* If two Matter Bodies have the same positive value, they will always collide; if they have the same negative value,
* Sets the collision mask for this Game Object's Matter Body. Two Matter Bodies with different collision groups will only collide if each one includes the other's category in its mask based on a bitwise AND, i.e. `(categoryA & maskB) !== 0` and `(categoryB & maskA) !== 0` are both true.
55
+
* Sets the collision mask for this Game Object's Matter Body. Two Matter Bodies with different collision groups will only
56
+
* collide if each one includes the other's category in its mask based on a bitwise AND, i.e. `(categoryA & maskB) !== 0`
0 commit comments