Implementing Visual Effects in Unreal Engine 5 Blueprints

Just some general advice:
I would avoid casts in blueprints, if possible. They will create hard references, which means it loads everything into memory at the same time (the blueprint your logic is in + all the ones that you are casting to).
A better way of checking if your other actor is a specific one, is simply by tag. Just set an actor tag on your ACT_Receiver and check if your ‘Other Actor’ has this tag.
You can also get rid of your 2nd cast and just do ‘Get Actor Transform’ it will pick ‘Self’ by default.

For the destroy part of your missile, I would do this inside the missile itself, just after you have spawned your impact. Then there is also no need to cast, as it’s all handled in the projectile itself.

And now, finally, to your impact :slight_smile:
If it’s a Niagara System only (only VFX), you can just use ‘Spawn System at Location’ to spawn a Niagara system, instead of an actor. It will handle the destroy by itself once the effect is finished, if you tick ‘Auto Destroy’.
If you have other logic in your impact actor, that you need to trigger though (and your Niagara System is directly in that actor), it’s fine the way you are doing it. Just make sure to destroy the impact actor, once the impact effect (and other logic) has finished.

1 Like