mirror of
https://github.com/wassname/phaser.git
synced 2026-10-02 12:30:54 +08:00
Don’t test self-collisions
This commit is contained in:
1 parent
666df67453
commit
b48669dded
1 file changed
+6
-3
@@ -750,9 +750,12 @@ Phaser.Physics.Arcade.prototype = {
|
||||
* @returns {boolean} Returns true if the bodies were separated, otherwise false.
|
||||
*/
|
||||
separate: function (body1, body2) {
|
||||
|
||||
this._result = (this.separateX(body1, body2) || this.separateY(body1, body2));
|
||||
|
||||
if(body1 !== body2)
|
||||
{
|
||||
this._result = (this.separateX(body1, body2) || this.separateY(body1, body2));
|
||||
} else {
|
||||
this._result = false;
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
Reference in new issue
Block a user