mirror of
https://github.com/photonstorm/phaser
synced 2024-11-23 05:03:37 +00:00
Adding in Particle Manager destroy handling
This commit is contained in:
parent
4b4473394c
commit
1121cedf60
2 changed files with 20 additions and 0 deletions
|
@ -2090,6 +2090,12 @@ var ParticleEmitter = new Class({
|
||||||
depthSortCallback: function (a, b)
|
depthSortCallback: function (a, b)
|
||||||
{
|
{
|
||||||
return a.y - b.y;
|
return a.y - b.y;
|
||||||
|
},
|
||||||
|
|
||||||
|
destroy: function ()
|
||||||
|
{
|
||||||
|
// TODO
|
||||||
|
// Particles, animations, etc
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
|
@ -494,6 +494,20 @@ var ParticleEmitterManager = new Class({
|
||||||
*/
|
*/
|
||||||
setBlendMode: function ()
|
setBlendMode: function ()
|
||||||
{
|
{
|
||||||
|
},
|
||||||
|
|
||||||
|
preDestroy: function ()
|
||||||
|
{
|
||||||
|
var emitters = this.emitters.list;
|
||||||
|
|
||||||
|
for (var i = 0; i < emitters.length; i++)
|
||||||
|
{
|
||||||
|
emitters[i].destroy();
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
// Wells, references, etc
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue