

The spikes happen when the memory garbage limits met and the collection runs, cleaning up the unnecessary objects from the memory. These can be huge frame rate spikes and are easily noticed while playing the game. Garbage collection spikes are frame rate drops specifically caused by the garbage collection system of Unity. Annoying Spikes are a problem in high-intensity games which need a stable frame rate and high control over the game to feel good, such as driving or shooting games ( FPS). Spikes are mainly caused by complex calculations or difficult operations performed during a single frame. Spikes can be seen as a high points on Profiler Graph. This can break the immersion of the player or cause him to make a mistake he wouldn’t have otherwise made. This is noticed when a game suddenly stops and doesn’t move for a noticeable time. Spike is a sudden drop in the frame rate of a game. Performance problems can be divided into several types depending on their nature. You can Optimize Unity Game in different ways depending on problem nature. Repeated profiling allows you to understand what happened after the completion of a single optimization task, whether this procedure brought a performance improvement or not. Next stored data can be compared with a previous data allowing for closer inspection of the state of the whole optimization process. If the game still has problems then project should be profiled and the data stored.If the game is executing excellent without visible problems and the list of optimization tasks is not empty then forget further optimization process.Follow this list until the game on target platforms has smooth gameplay and stable frame rate. This also helps to gain the most performance with the least efforts.

Resulting ordered list of optimization tasks will work as a guideline for the entire process of optimization starting with the most effective action. This is done by comparing the approximated time each specific implementing of optimization would take and a performance gain in result.

Next will be presented common optimization cycle, which you need to go sequentially every time when noticeably low FPS suddenly occurs in your game after next stage of development: Usually the main reason for optimization is to make the gameplay smoother, or to make the game more available to a wider audience so the game runs better on lower end devices. Unity Optimization refers to the process of making your game run better. 5.5 Convex Mesh Collider for Complex Objects.
