Its really annoying that if I accidently make an infinite loop in my code, or call Debug.Log in too big a loop, unity basically freezes and goes unresponsive and the only way to get it back is to force quit and reopen it.
There should be some ‘abort play’ button which will break whatever its doing and stop playing. Or maybe just press ‘esc’.
I know what you mean. I have lost work to that a few times.
I also have lost work to that. Some kind of force abort play mode would be nice.
I think a lot have lost work to that.
Hope anyone could give a workaround to that.
Unity saves your scene every time you hit play, so you don’t need to lose any work. Move the “_EditModeScene” file from the temp folder (before restarting Unity) to your assets folder and rename it appropriately.
–Eric
This solution isn’t so elegant, an abort button or something like some browsers do showing a popup like “Script X maybe is making the window unresponsive, do you want do finish it?” is better
Obviously an abort button would be surely be preferable…just pointing out that losing work isn’t necessary even without one. (Also it would be nice if this backup scene were made more obvious; maybe check for it if Unity was force-quit and ask if you want to restore it when you restart, instead of having to do it manually.)
–Eric