Just off the cuff:
-Culling
-Batching
-Pooling
-Limit AI cycles
-LOD for colliders, art, and scripts
-Imposters
-Force the Garbage collector at appropriate times
-Use rays instead of colliders when possible. even if it’s a projectile, you can do a series of ray casts on a moving point.
-avoid mesh colliders when you can use primatives
-use box colliders that have a 0,0,0 rotation (cheapest of the colliders)
-use 2D colliders when possible. Even if you use 3d models, if it’s on a 2D plane do 2D colliders
-multithreading
-I’m really not sure how this is done, but optimize CPU memory. That is, load the CPU with relevant data to avoid having to pull it from the RAM when possible. I’m at a total loss as to what this is called or any tutorials in it, but I know it’s a thing.
-static methods that have multiple functions
-use particle emitters when possible
-use animations instead of manual movement when possible
-avoid the built in RNG when possible
-use int instead of float when possible
-run an asset clean up tool before building
-use A* method instead of navmesh when possible
-build the game instead of running it in editor to see actual performance
-identify your bottleneck between the GPU, CPU, and RAM. It’s usually only one slowing down that is giving you issues
-pro builder is can be a resource hog
-stagger processes when possible. As an example I’m making a shotgun. Rather than doing the math for the spread when pulling the trigger, I’m doing the math for each pellet one frame at a time before hand, and when I pull the trigger doing whatever pellets are not done.
OR another example is rather than having all of my enemies do decisions every frame I’m doing them in chunks taking turns. There’s lots of ways of doing this. Some prefer to give them a clock to do it every so often, rather than every frame. Some prefer to make an array and cycle through it.
-cache rather than find when possible
-I’ve had a lot of success with this, if you have a complicated collider do a large simple collider that turns on the more complicated colliders
-avoid changing variables and GUI elements every frame, and instead only do so when they change
-avoid instantiate and destroy like the plague (see pooling)