1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-05 09:42:54 +08:00

Merge pull request #30862 from frenzibyte/dont-scare-the-player

Don't play fail animation if restarting on fail
This commit is contained in:
Dean Herbert 2024-11-24 23:11:19 +09:00 committed by GitHub
commit c34827a4ed
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -976,6 +976,8 @@ namespace osu.Game.Screens.Play
if (PauseOverlay.State.Value == Visibility.Visible)
PauseOverlay.Hide();
bool restartOnFail = GameplayState.Mods.OfType<IApplicableFailOverride>().Any(m => m.RestartOnFail);
if (!restartOnFail)
failAnimationContainer.Start();
// Failures can be triggered either by a judgement, or by a mod.
@ -990,7 +992,7 @@ namespace osu.Game.Screens.Play
ScoreProcessor.FailScore(Score.ScoreInfo);
OnFail();
if (GameplayState.Mods.OfType<IApplicableFailOverride>().Any(m => m.RestartOnFail))
if (restartOnFail)
Restart(true);
});
}