mirror of
https://github.com/photonstorm/phaser
synced 2024-11-22 20:53:39 +00:00
Destroy the EmitterOps
This commit is contained in:
parent
9ce33a2fd5
commit
bc1bc3baba
1 changed files with 10 additions and 1 deletions
|
@ -3398,11 +3398,19 @@ var ParticleEmitter = new Class({
|
||||||
this.deathZones = null;
|
this.deathZones = null;
|
||||||
this.bounds = null;
|
this.bounds = null;
|
||||||
this.follow = null;
|
this.follow = null;
|
||||||
this.ops = null;
|
|
||||||
this.counters = null;
|
this.counters = null;
|
||||||
|
|
||||||
var i;
|
var i;
|
||||||
|
|
||||||
|
var ops = this.ops;
|
||||||
|
|
||||||
|
for (i = 0; i < configOpMap.length; i++)
|
||||||
|
{
|
||||||
|
var key = configOpMap[i];
|
||||||
|
|
||||||
|
ops[key].destroy();
|
||||||
|
}
|
||||||
|
|
||||||
for (i = 0; i < this.particles.length; i++)
|
for (i = 0; i < this.particles.length; i++)
|
||||||
{
|
{
|
||||||
this.particles[i].destroy();
|
this.particles[i].destroy();
|
||||||
|
@ -3413,6 +3421,7 @@ var ParticleEmitter = new Class({
|
||||||
this.dead[i].destroy();
|
this.dead[i].destroy();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.ops = null;
|
||||||
this.particles = [];
|
this.particles = [];
|
||||||
this.dead = [];
|
this.dead = [];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue