Games made by unity start stuttering after a while?

I am on MacOS Mojave, I was playing The Long Dark made in unity, after like about half an hour the game starts stuttering / lagging non stop(seems like fps dropped), i found out switching to windowed temporarily fixed the issue until it struck again and i was able to temporarily fix it again by going full screen then windowed again , and again. I thought the issue was from the game and i reached out to their support but now im playing a new game made in unity (SkillWarz) and the same exact issue happens in that too, so im pretty sure its something have to do with unity. is there a way to fix that? Thanks in andvance !

Does this happen with games made on other engines?

Have you checked for signs of thermal throttling? e.g. CPU frequency dropping.

What type of Mac are you using?

No, it seems to only happen on games made by unity, also these games meet my system requirments and other more demanding games run really well without issues and it never overheated or anything its macbook pro mid 2012 but upgraded with cpu and 8gb ram

Have you checked CPU frequencies for signs of thermal throttling? Just because a game is perceived as being “more demanding” doesn’t mean that it is using more CPU/GPU power. The 2 Unity games you tried just might use the the CPU more heavily and consistently for whatever reason.

What you describe sounds an awful lot like thermal throttling.

+1 thermal throttling. Especially if you are running on a laptop

1 Like

Hmm, Is thermal throtle supposed to drop FPS ? because my fps does not change at all when the issue occurs it starts stuttering while the fps stays the same as it was before.

Thermal throttling can cause all sorts of strange performance problems.

It is very easy to test, just monitor the CPU frequency while playing a game.

i did, it was below 50%, below 40% even

Macs have some of the worst thermal solutions out there. They heat up fast playing games. If you are playing non-Unity games and it doesn’t happen, I have a strong suspicion it’s just happenstance; being that the non-Unity games you are playing are not particularly demanding games. I’ve tried plenty of games on my Mac, and the demanding ones throttle nearly 100% of the time, but the simple ones never cause a problem for me; regardless of the game engine.

Might just be me though.

1 Like

What resolution are you playing at? If it’s 4k, your CPU will likely not be a significant factor. Your GPU will be the one heating up and hitting high usage percentages. If it’s 1080p or lower resolution, then it will be a CPU dependent experience.

Regardless, a Mac does not need to hit 100% CPU usage to build up heat and thermal throttle. Mac’s thermals have a problem with long-term and consistently medium/medium-high usage too, since the heat doesn’t escape the tiny case particularly well. In other words, the heat builds up over time and causes thermal throttling that is similar to shorter periods of high CPU/GPU usage. That would also explain why it takes a while before you experience these issues.

And yes, thermal throttling is perhaps the only way that I can think of that causes stuttering without a notable difference in the FPS being rendered. Although that doesn’t mean that FPS can’t be affected. It’s just fairly common in my experience. So that would be expected behavior during throttling.

One, perhaps goofy, way to test this is to play your game until stuttering, then put your Mac into your freezer, or get ice packs out and place it on top of them with a cloth between the computer and the ice packs to absorb condensation. This won’t take long. Give it a matter of a minute or so to notice if the stuttering has stopped and the game is acting more normal. If so, get a laptop cooler and place your Mac on it when playing games.

Apart from the thermal throttling mentioned several times earlier, have you checked that maybe os switches back to the integrated GPU rather than dedicated? You can disable this behavior in the power settings.

CPU usage percentage has little to do with CPU frequency. Frequency is measured in GHz.

For example, lets say you have a quad core CPU, and you’re running a game which has 2 CPU heavy threads. You’ll likely see full or near full CPU usage on 2 cores, and near idle on the other 2. That would appear as 40-50% CPU usage. Then after a while your laptop heats up enough, where it thermal throttles. Lets say it was running at around 3GHz, but when thermal throttled it cuts back to 1GHz. So you’re effectively getting only 1/3 of your previous CPU performance. What will that look like in CPU utilization? It will show about 40-50% CPU usage, basically unchanged.

You were CPU bound before thermal throttling, and you’re of course still CPU bound while the CPU is thermal throttling. What you see on the screen in game depends on the game. You may a smooth but much lower FPS, or you might get a choppiness where certain frames take a lot longer than others to complete.