- Home /
Inconsistent framerate -- and not using full CPU!
Working on a 2D platforming game that is very script-heavy: texture assets are small and low res, but scripts do a lot of pathfinding, volumetric gases and fluids, etc.
Sometimes it runs at a silky smooth 60 fps. Other times it jerks and stutters along between 20 and 40 fps. When it's jerky, and I switch over to OS X's Activity Monitor, I see that the game is using only 40-60% of the CPU. When it's smooth, it's generally using 80-100% of the CPU.
One more wrinkle... when it's jerky, and I open Unity in the background, it suddenly gets smooth, and that lasts as long as Unity stays open. The project doesn't have to be loaded... even if Unity stays on its launcher screen, that does the trick. This works 100% of the time. I have tested it a LOT. Closing Unity often means the framerate gets jerky again. Opening it back up solves the issue. It's as though having Unity open in the background tells the application that it can use the entire CPU.
I am using Unity version 2017.3.1f1 (fc1d3344e6ea) on Mac OS X, version 10.13.6 (17G6030) on a 2015 MacBook Pro.
Does anyone know how to solve this issue? Obviously asking my players to download Unity and keep it open in the background won't work :)
Your answer
Follow this Question
Related Questions
Unity 2017 frame rate capped? 2 Answers
Game Freezes upon successive loads 0 Answers
low FPS when battery is low ( unity android ) 0 Answers
Unity 2D Empty Scene Framerate Drop in Editor When I switch to fullscreen 0 Answers
Frame rate issue for mobile 1 Answer