- Home /
fps drop even after optimization
hello guys, i want to ask that even after i reduced my batches from 167 to 57 the problem is that when i run it on my PC with a gtx 960 graphics card it works fine the CPU time remains between the 5 and 4ms but when i run the same sene in my laptop which have a basic Intel hd graphics 620 the CPU time gets high to 20 and 30ms even the batches are same,i run the profiler and found that the "Editor Loop" is using a lot of time ms ,is there any solution how can i optimize that as the sene i made is for mobile ,and with that higher CPU ms its really overkill for the mobile also i also found that that in "Player Loop" there are also some other issues i attached the screenshot for better look into problem so kindly show me the way of how i can optimize these ,as i have build the standalone file but still no luck.
Answer by JonPQ · May 04, 2020 at 06:35 PM
run profiler in deep mode, open up that player-loop section, keep opening it up , all the way down inside the hierarchy to see what is going on, to see where your time is going. also turn off logs before you start, as those are very slow and interfere with accurate profiling.
its hard to suggest improvements without seeing some information about where your time is going. Can only suggest general performance tips, that you could easily find googling around. Unity has an optimization section in their docs also. some general stuff.... cache your variables, avoid using GetComponent() at run-time. If you are using Instantiate alot.... don't, use an object pool instead. If you are using a lot of physics...think if some it if can be switched off / idle most of the time, or only updated occasionally.
Answer by Eh3an · May 04, 2020 at 06:37 PM
What i know is that EditorLoop in the profiler means the resources used by the UnityEditor, so while you run your game in unity this overhead happens, i suggest you to build game and then run it.
And since your target device is mobile, it's very important that you test your game performance on mobile not PC or UnityEditor.
Your answer
