- Home /
Unity 2017.1f1 Freezes while compiling scripts
My Unity started to freeze every time i compile scripts few days ago. The loading "circle" on bottom right corner just freezes and so does Unity, so i have to stop the process from task manager. Restarting Unity obviously didn't work and i also tried to restart my pc. I'm using Photon on my project and i have heard that some people had same issue with photon but their solutions didnt work for me.
We are currently also experiencing this problem. Could you tell me which solutions you already have tried?
I have been facing the same problem for a long time, with unity 2017.x (not only a specific version) and unity 2018.1.x. I 'm not using Photon. Have you found any solution?
No real fix no :/ What we have implemented is a script that checks if unity is in play mode and compiling and then forces play mode to stop. This way it won't hang when you change something during play mode. Like this: http://www.rebz.org/2014/05/gist-stop-playing-on-recompile
In my case, the problem was first happening if I edit a script during play mode, I solved it in the same way as yours (It was because of a server plugin, called GameSparks). But later, unity started to freeze after editing a script in editor mode, it happens very frequently, but not always, so I still haven't pinpointed a specific reason. It really kills your time, especially if you are working on the gameplay mechanics, which needs a lot of trails and errors.
Answer by SamuelRoos · Nov 21, 2018 at 05:05 PM
Quick fix if you get stuck is just to reimport the script(s) you've changed.
Answer by Must_I_have_a_name · Oct 01, 2018 at 10:05 PM
I am having something similar happening. I ...think... it is because I have a script which has many,many errors in it. I am working on writing a method which has hundreds of lines in it with the predominant error being an invalid,incorrect calls(hundreds of such error calls) to a method in the same class. If I go back and comment out the entire contents of the script then the freeze on "compiling scripts" goes away. I speculate the reason it is freezing is either 1)totally cannot cope with that many errors or 2)there's a combinatorial explosion in the amount of processing required to compile.it might never finish compiling,i ran out of patience. the editor also will not shut down normally.
Answer by $$anonymous$$ · Oct 23, 2018 at 10:06 AM
My solution:
Close all programs when compilating, and disable firewall, the last is very important!
Your answer
![](https://koobas.hobune.stream/wayback/20220612135129im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Unity freezes sometimes when I'm tabbed out. 0 Answers
Unity Only Crashes in Editor, not in Build App 0 Answers
iOS game freezes on startup 0 Answers
Webplayer Freeze / Crash After Facebook Interaction 0 Answers