TheGreatCthulhu
Member
Posts: 213
Threads: 10
Joined: Oct 2010
Reputation:
32
|
RE: [Script / Particle Editor] About Particle System Behavior
No, you didn't understand what I was trying to say. I don't want all the particles to simply disappear. The problem is that there is a period where spawning doesn't stop.
The particle system appears to be implemented to work this way: particles are spawned at a certain rate untill Max Particles value is reached; each particle has a lifetime (set on the Life tab), and the lifetime of each particle starts when it's spawned.
Particles are spawned untill MaxParticles value is reached, and then the "normal", rate-based spawning stops; however, if Respawn Dead Particles checkbox is checked, once the particle dies, it will be respawned from the emitter at the rate the particles die (and they can have different lifetimes - hence the small "spawn-gaps" in my PS).
Now, if I call DestroyParticleSystem() before Max Particles is reached, it basically has no immediate effect - it just stops dead particles from respawning.
If I do it after Max Particles is reached, the emitter stops spawning new particles instantly (and the existing ones just drift away).
P.S. BTW, what I did in the test map was: I hooked up a lever so that one state creates, and the other destroys the PS on an entity. The effect can be observed if you do a create-destroy "move" - it doesn't have to be too fast. Within the first 4-5 seconds.
|
|
12-02-2012, 12:44 AM |
|