This commit is contained in:
Richard Davey 2019-07-11 14:00:49 +01:00
commit dcf8b96095

View file

@ -1134,22 +1134,7 @@ var Group = new Class({
return;
}
if (destroyChildren)
{
var children = this.children;
for (var i = 0; i < children.size; i++)
{
var gameObject = children.entries[i];
// Remove the event hook first or it'll go all recursive hell on us
gameObject.off(Events.DESTROY, this.remove, this);
gameObject.destroy();
}
}
this.children.clear();
this.clear(false, destroyChildren);
this.scene = undefined;
this.children = undefined;