Fixed Arcade Physics Circle body collision, after the #2654 change broke it unintentionally.

This commit is contained in:
photonstorm 2016-08-22 16:23:22 +01:00
parent 92fc28010b
commit 11b0436a26

View file

@ -1158,7 +1158,10 @@ Phaser.Physics.Arcade.prototype = {
this.getOverlapX(body1, body2);
this.getOverlapY(body1, body2);
var angleCollision = this.angleBetweenCenters(body1, body2);
var dx = body2.center.x - body1.center.x;
var dy = body2.center.y - body1.center.y;
var angleCollision = Math.atan2(dy, dx);
var overlap = 0;