Particles behave weridly (SOLVED)


Describe the bug:
Sometimes after rotating game object particles are not spawning even when particlefx is in spawning state and no particle cap is reached.

To Reproduce:
Have GO that spawn particles for long period of time (or in loop mode)
Change its rotation multiple times
result: Sometimes particles will be spawned, other times not.

Expected behavior:
Particlefx shloud always spawn particles unless its stopped or particle cap is reached.

Defold version:
Version 1.2.164
Editor SHA1: 2be2687cbb670c2dbe9cf2e99577bc3338561778
Engine SHA1: 2be2687cbb670c2dbe9cf2e99577bc3338561778

Happens in Editor during debug, Android builds exhibit same behaviour

Project showing issue:
particle (1002.0 KB)

Project shows GO with 2 PFX, each with 2 emmiters. When particles are not spawned, it always affects both emmiters, but not always both PFXs of that game object.

1 Like


It’s some kind of rounding error on the z-value of the emitters. The emitters are spawning on z = -1 and you have set your render script near plane to -1. If you either change the near and far plane to something a little bit higher or move the emitters closer to 0 the problem goes away.



Oh. I completely forgot about near/far. Thanks!