Fix for group vs group within group collision (fixes #877)

This commit is contained in:
Allen Cook 2014-08-28 20:21:13 -04:00
parent 52ea95d9ce
commit 5a3eeb8a9c

View file

@ -653,7 +653,12 @@ Phaser.Physics.Arcade.prototype = {
{ {
if (group1.children[i].exists) if (group1.children[i].exists)
{ {
this.collideSpriteVsGroup(group1.children[i], group2, collideCallback, processCallback, callbackContext, overlapOnly); if (group1.children[i].type == Phaser.GROUP)
{
this.collideGroupVsGroup(group1.children[i], group2, collideCallback, processCallback, callbackContext, overlapOnly);
} else {
this.collideSpriteVsGroup(group1.children[i], group2, collideCallback, processCallback, callbackContext, overlapOnly);
}
} }
} }