mirror of
https://github.com/osukey/osukey.git
synced 2025-05-21 13:37:20 +09:00
Ensure fail animation sequence isn't run after the player exit sequence has started
This commit is contained in:
parent
4c45f7d938
commit
8f4a953d11
@ -4,6 +4,7 @@
|
|||||||
#nullable disable
|
#nullable disable
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
|
using System.Diagnostics;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
@ -828,9 +829,17 @@ namespace osu.Game.Screens.Play
|
|||||||
|
|
||||||
private bool onFail()
|
private bool onFail()
|
||||||
{
|
{
|
||||||
|
// Failing after the quit sequence has started may cause weird side effects with the fail animation / effects.
|
||||||
|
if (GameplayState.HasQuit)
|
||||||
|
return false;
|
||||||
|
|
||||||
if (!CheckModsAllowFailure())
|
if (!CheckModsAllowFailure())
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
Debug.Assert(!GameplayState.HasFailed);
|
||||||
|
Debug.Assert(!GameplayState.HasPassed);
|
||||||
|
Debug.Assert(!GameplayState.HasQuit);
|
||||||
|
|
||||||
GameplayState.HasFailed = true;
|
GameplayState.HasFailed = true;
|
||||||
|
|
||||||
updateGameplayState();
|
updateGameplayState();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user