We have explained the performance optimization knowledge points of Unity’s mainstream modules one by one four years ago, commonly known as “Basic Version”. As the engine itself, hardware equipment, production standards, etc. have been upgraded in recent years, UWA has also continued to update optimization rules and methods and continue to output to the majority of developers. As an “upgraded version” of the performance optimization manual, [Unity Performance Optimization Series] will try to express it in a simple and understandable way, so that more developers can use it. In this issue, we will continue to share the knowledge points related to the animation module. https://blog.en.uwa4d.com Currently, in UWA report, we can see that the main functions related to animation include: There are two Animator-related functions: one is DirectorUpdateAnimationBegin and the other is DirectorUpdateAnimationEnd. Generally speaking, we must pay attention to the stack of these two functions, and further locate the cause through the number of calls of the stack function and the proportion of time consumed. Common factors affecting performance and optimization countermeasures are as follows: 1)Control the number of Active Animator The number of characters increase will lead to an overall time-consuming increase, and the CPU time of each function increases approximately linearly with the increase of the character data. The above picture is a real-device evaluation report of a project. We selected a frame to check its stack information and found that the number of calls to ApplyOnAnimatorMove is up to 168 times, which means the current scene there are 168 Animators in the Update state i, this value is very high. In general, it is recommended to keep it within 30 as much as possible. The reason for this high value is usually the CPU time caused by a large number of off-screen Animators that are still updating calculations. It may be caused by the Animator component of the cached character being still in the Active state, or it may be caused by too many Animator components on the UI. For the Animator on the UI, if the animation is relatively simple, it is recommended to try to use Dotween instead. Read the full content in the below website: https://blog.en.uwa4d.com/2022/01/18/unity-performance-optimization-animation-module/