Optimization advice horde wave shooter.

I am making a horde based wave shooter and I have noticing major FPS dips when a wave goes on for over 30 seconds.

The enemy being spawned is under 900 vertices and has a tick rate of 0.15 and only has two animations attached with a behavior tree that has three nodes.

Nav mesh rendering is static.

any advice would be helpful because I know it’s doable because of games like L4D2 and space marine.

You must figure out what is your bottleneck. Profile! Nothing matters more than that. You can safely ignore the rest of the post.

Remove all creature colliders - you shouldn’t have any use of them when on mass. Profile.

Check how often are you dong pathing and limit it. Use group leaders when pathing. Use boid or fluid mechanics in close range.

Use animation LOD - update animations sparsely, drop blendings far from camera, don’t animate when not on sceen. Its not the number of animations, it is the number of interpolations done on each component of each bone on each creature. Synchronize animations - make one calculation and and apply the transformation to multiple characters. Use shader animations where you can.

Check your creature Tick. Figure out what is needed and what can be cached. Move sparse actions in components with large tick intervals. Make sure all your world queries are global and they are done rarely.

Profile! These are only the things from the top of my head - usually the problem is deeper and game specific but you can turn off each of these elements and test to see which has the biggest performance impact.