mirror of
https://github.com/photonstorm/phaser
synced 2024-11-22 20:53:39 +00:00
Group.createFromConfig
will now check to see if the config contains either internalCreateCallback
or internalRemoveCallback
and set them accordingly. This fixes an issue where the callbacks would never be set if specified in an array of single configuration objects. Fix #6519
This commit is contained in:
parent
bebc146125
commit
4fa348e161
1 changed files with 10 additions and 0 deletions
|
@ -431,6 +431,16 @@ var Group = new Class({
|
||||||
this.removeCallback = options.removeCallback;
|
this.removeCallback = options.removeCallback;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (options.internalCreateCallback)
|
||||||
|
{
|
||||||
|
this.internalCreateCallback = options.internalCreateCallback;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (options.internalRemoveCallback)
|
||||||
|
{
|
||||||
|
this.internalRemoveCallback = options.internalRemoveCallback;
|
||||||
|
}
|
||||||
|
|
||||||
for (var c = 0; c < range.length; c++)
|
for (var c = 0; c < range.length; c++)
|
||||||
{
|
{
|
||||||
var created = this.create(0, 0, range[c].a, range[c].b, visible, active);
|
var created = this.create(0, 0, range[c].a, range[c].b, visible, active);
|
||||||
|
|
Loading…
Reference in a new issue