Bug #4051

game freeze at regular intervals

Added by rkman over 4 years ago. Updated over 3 years ago.

Unity Bug
Target version:
Start date:
% Done:


English (US)
Arrow u r green
Arrow d r red


Interval ranging from some 5 to 15 seconds depending on current physics delta; with the game slowed down (ingame clock color other than green) the interval is longer. The freeze lasts for several 10's of ms to maybe a 100ms, and seems to become more severe the longer a game session lasts.

same as
Bug #530 Framedropping with sound crackling

Which is marked as resolved, but it is actually still an issue:


#1 Updated by Squelch about 4 years ago

  • Platform Win32 added
  • Platform deleted (Windows)

#2 Updated by sal_vager almost 4 years ago

  • Status changed from New to Unity Bug
  • Priority changed from High to Low

This has been identified as Unity3D game engine issue, caused by the Mono garbage collection algorithm.

#3 Updated by Broco over 3 years ago

sal_vager wrote:

This has been identified as Unity3D game engine issue, caused by the Mono garbage collection algorithm.

This bug is still present and got worse in 1.1.1 for me and many others. Yes, the freezes are triggered by Unity GC BUT there are ways to get around it as seen here:

Basically you need to significantly reduce the amount of garbage created each frame by not instatiating and destroying objects but instead enable and disable them after instatiating them, avoid string concatenation and avoid GetComponents.
This bug needs to be addressed with higher priority since it affects a majority of players. Some think it's an issue with their settings or their computers but it's definitely not.

At the current state the game is unplayable for me, even in vanilla state the GC runs every ~5 seconds.

I know this one requires a lot of code rewriting but after 1.1.1 came out I think it's time to get rid of some lose ends, optimize the code base and create a good basis to movoe on before new features are implemented. Stability + performance > features.

You can't really say this is a unity issue. A friend of mine works with Unity too and says these problems are known to the Unity community and they describe ways to avoid it.

I really like you guys and love KSP, but don't try to hand this one over to Unity when it's evident that it can be avoided with proper coding.

#4 Updated by funkcanna over 3 years ago

This issue MUST be fixed. I think it was more acceptable in pre 1.1.x days as there were all sorts of other issues caused by not having 64bit and this issue is exaggerated by mods, however now 64bit is here, its worse! A game that stutters every five seconds is unplayable and unprofessional.

Hire someone specifically to fix this issue so your "priority list" for employees is unaffected.

Also available in: Atom PDF