Hi. I am working on a projectile and as a trail I added a particle system to blueprint which emits some particles that looks like a trail. I want this projectile to get destroyed when it hits something however that causes the remaining particles to disappear instantly before their lifetime ends. Is there a way to destroy an emitter or an actor with emitter without destroying the remaining particles?
Fastest way to do it is before to:
- Set your projectile Mesh to Hidden, and disable its collision, which will make the player think the projectile is gone
- Use the Deactivate function on your emitter which will stop it from spawning new particles but will keep the old ones until they fade
- Add a delay to give the particle effect some time to fully deactivate
- Destroy your projectile
It would be slightly more optimal to already delete the mesh so it gets removed from memory and what not, also make sure to set your particles to “kill on completed” in the required node.
Thank you, that worked perfectly!
There is a bAutoDestroyWhenFinished flag in an actor, so we can set it to true and the actor will self destroy. It’s mor convinient then calculating times when all particles of the system are done.