Particle emitter destroyed as having "no particles" if the flow is too small
Setting the flow of particles to small values ends up crashing the emission. Setting the flow to 1 sends a few particles (sometimes two, sometimes a dozen) and then the flow stops (and the last particle disappears). Increasing the flow again doesn't resume it.
game.zip Press Space to lower emission, v to restore.
Expanded from: source
This happens because the object is configured to be deleted "when it's out of particles", but here it actually should never run out of particles (but I guess it considers it has not even 1 particle, and so stop and gets deleted).
This can be worked around by disabling this option. But this is also a bug that should be fixed I think.
(Just a nitpicking on the naming: this is not a crash, because the game or the editor are not crashing, the game just continues to run.)
This bug is due to the fact that the condition uses the method getParticleCount that is misleading:
https://github.com/4ian/GDevelop/blob/master/Extensions/ParticleSystem/particleemitterobject.ts#L333-L339
it returns the number of active (displayed) particles and not the number of particles that remains in the tank. And I think that there is no such data in the pixi object: https://pixijs.io/particle-emitter/docs/classes/Emitter.html#particleCount
We could maybe watch _emitterLife to have this piece of information https://pixijs.io/particle-emitter/docs/classes/Emitter.html#_emitterLife