Etienne Posted April 7, 2017 Share Posted April 7, 2017 Hello! The doc api don't reflect the code and the behavior of Emitter.start for the quantity parameter in Phaser. In the doc we can read : [ quantity : How many particles to launch. 0 = "all of the particles" which will keep emitting until Emitter.maxParticles is reached. ] For me is more something like [ quantity : How many particles will be launched. 0 = "keep launching particle forever". ] I'm wrong ? Best regards, Etienne Emitter.start(explode, lifespan, frequency, quantity, forceQuantity) quantity : How many particles to launch. 0 = "all of the particles" which will keep emitting until Emitter.maxParticles is reached. Link to comment Share on other sites More sharing options...
samme Posted April 7, 2017 Share Posted April 7, 2017 It's usually easier to use Emitter#explode or Emitter#flow instead. The 2.6.2 docs on Emitter#start are a bit misleading. With explodes=true, you have to pass a quantity > 0. With explode=false, quantity=0 means stay on forever and release particles as long as there are some available. drhayes 1 Link to comment Share on other sites More sharing options...
Etienne Posted April 10, 2017 Author Share Posted April 10, 2017 Thanks for your help! Doc can be easily updated I guest to be more clear for #start... Agree with you, explode and flow are more straightforward . samme 1 Link to comment Share on other sites More sharing options...
samme Posted April 11, 2017 Share Posted April 11, 2017 #start seems to be an older method. Unfortunately #explode and #flow don't appear in Phaser Examples. Link to comment Share on other sites More sharing options...
drhayes Posted April 11, 2017 Share Posted April 11, 2017 That explains problems I've had with start for forever. I never get exactly what I want the first few times and always have to dig in. Thanks for letting me know about those methods. Link to comment Share on other sites More sharing options...
Recommended Posts