Find anything about what? I’ve this fully implemented and working. You just need an array of transforms of when the projectile is shot. Then in your tick (I’m using a timer in a GameplayAbility) you “move” their transforms to where they should be. During that move you run a line or sphere trace for objects and only check for things it can collide with. If it colliders remove its index from the projectiles array. If it doesn’t set its index in the projectiles array to the new location. Below is my projectile handling chopped out. This is done entirely from BP. It of course performs better if C++, but am doing my game almost exclusively with BP and will nativize my gameplay abilities.
Shoot Projectile:
Projectile Tick:
Move Projectile:
It’s 1 tick no matter the amount of projectiles. I don’t notice any form of FPS impact until around 1500 projectiles then it can start to go down. Note that’s 1500 ACTIVE projectiles. It’s VERY unlikely to ever have that many active projectiles. Most will be colliding and being removed.
It’s strictly the collision checks causing the performance decline for me. I’m not sure how to optimize that further yet. Without collisions I can easily have 50,000 projectiles going but kinda useless without collisions. Using Niagara for projectiles performed way better, but it ate through CPU usage like crazy having tons of particle collisions and became crazy inaccurate with its collisions.
How did you go about implementing your solution? Looks like you have collisions, but it’s hard to tell. Do you get collision events so you can apply damage to things?