(bb2624736) Don't keep running the end round cinematic if the player leaves the game screen. Otherwise the player can, for example, quickly start a new single player round or switch to the sub editor, and have the game crash when then end round cinematic finishes and unloads the sub.
This commit is contained in:
@@ -1199,7 +1199,7 @@ namespace Barotrauma.Networking
|
||||
{
|
||||
secondsLeft -= CoroutineManager.UnscaledDeltaTime;
|
||||
yield return CoroutineStatus.Running;
|
||||
} while (secondsLeft > 0.0f);
|
||||
} while (secondsLeft > 0.0f && Screen.Selected == GameMain.GameScreen);
|
||||
}
|
||||
|
||||
Submarine.Unload();
|
||||
|
||||
Reference in New Issue
Block a user