Play's Zone Posted December 26, 2014 Share Posted December 26, 2014 I have one emitter that setups like this: var lifespan = 2000; this.__emitter = this.__game.add.emitter(0, 0, 500); this.__emitter.makeParticles('particle'); this.__emitter.forEach(function(particle){ particle.tint = this.logic.owner.color; }.bind(this)); var shipSpeed = this.logic.getSpeedXY(); shipSpeed.x *= -0.4; shipSpeed.y *= -0.4; var spread = 20; this.__emitter.setXSpeed(shipSpeed.x - spread, shipSpeed.x + spread); this.__emitter.setYSpeed(shipSpeed.y - spread, shipSpeed.y + spread); this.__emitter.minParticleScale = 0.01; this.__emitter.maxParticleScale = 0.2; this.__emitter.gravity = 0; this.__emitter.setAlpha(0.6, 0, lifespan, Phaser.Easing.Quintic.Out); then I start it first like this: startEmitter: function(){ var emitter = this.getEmitter(); emitter.start(false, 2000, 25) }, end later explodeEmitter: function(){ var emitter = this.getEmitter(); emitter.setXSpeed(10, 10); emitter.setYSpeed(10, 10); emitter.explode(3000, 500); }, But the explosion doesn't happen. The emitter still emits at the same speed as set the first time, seems like the explodeEmitter doesn't do anything. Link to comment Share on other sites More sharing options...
Recommended Posts