natiny_particles_get_alive
bool natiny_particles_get_alive(NatinyParticles particles);
Returns whether anything is left to happen: the system is emitting at a rate above zero, or it still has live particles.
Parameters
| Name | Type | Description |
|---|---|---|
particles |
NatinyParticles |
Particle system handle from natiny_particles_create |
Returns
| Type | Description |
|---|---|
bool |
true while emitting or while particles are alive; false for an invalid handle |
Example
natiny_particles_stop(explosion);
/* later, every frame: */
if (!natiny_particles_get_alive(explosion))
natiny_particles_destroy(explosion);