In short I’m making a space “exploration” game. You can mine asteroids in said game, and to visualize this effect I’m using a particle emitter. The thing is, my gameobject get’s destroy when the particle emitter stopped emitting.
So essentially it happens after the last particle have been picked up by my ship, or destroyed in any other way (I’m doing this with a Particle World Collider that decrease the energy level by the energy level of the particles).
To make this easier to understand here’s what happens.
-
[Asteroid Starts Emitting Particles]
-
10 Particles are currently in world
space and are being picked up by the
ship. -
[Asteroid Stops Emitting Particles]
-
5 Particles are currently in world
space -
2 Particles are currently in world
space -
[All particles have been picked up by
the player!] - That’s the exact
moment my asteroid gameobject gets
destroyed.
It has to be some value in inspector that’s doing this, as the only thing I’m doing script wise is to tell the particle to emit towards the ship.