mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 11:35:35 +08:00
Change conditional ordering to allow player to always run its fadeOut sequence.
This commit is contained in:
parent
24deaf05b6
commit
2ccb8b154f
@ -315,24 +315,23 @@ namespace osu.Game.Screens.Play
|
||||
protected override void OnSuspending(Screen next)
|
||||
{
|
||||
fadeOut();
|
||||
|
||||
base.OnSuspending(next);
|
||||
}
|
||||
|
||||
protected override bool OnExiting(Screen next)
|
||||
{
|
||||
if (HasFailed || !ValidForResume)
|
||||
return false;
|
||||
|
||||
if (pauseOverlay != null && !HitRenderer.HasReplayLoaded)
|
||||
if (!HasFailed && ValidForResume)
|
||||
{
|
||||
//pause screen override logic.
|
||||
if (pauseOverlay?.State == Visibility.Hidden && !canPause) return true;
|
||||
|
||||
if (!IsPaused) // For if the user presses escape quickly when entering the map
|
||||
if (pauseOverlay != null && !HitRenderer.HasReplayLoaded)
|
||||
{
|
||||
Pause();
|
||||
return true;
|
||||
//pause screen override logic.
|
||||
if (pauseOverlay?.State == Visibility.Hidden && !canPause) return true;
|
||||
|
||||
if (!IsPaused) // For if the user presses escape quickly when entering the map
|
||||
{
|
||||
Pause();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user