From d26f31b71d7fda2fc6e8b90431db3f61b67d8bc5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bart=C5=82omiej=20Dach?= Date: Mon, 18 Aug 2025 09:09:34 +0200 Subject: [PATCH] Unapply replay playback speed when going to results closes https://github.com/ppy/osu/issues/34700 --- osu.Game/Screens/Play/ReplayPlayer.cs | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/osu.Game/Screens/Play/ReplayPlayer.cs b/osu.Game/Screens/Play/ReplayPlayer.cs index 92eeb3c9fe..131ce452bc 100644 --- a/osu.Game/Screens/Play/ReplayPlayer.cs +++ b/osu.Game/Screens/Play/ReplayPlayer.cs @@ -197,8 +197,7 @@ namespace osu.Game.Screens.Play public override void OnSuspending(ScreenTransitionEvent e) { - // safety against filters or samples from the indicator playing long after the screen is exited - failIndicator.RemoveAndDisposeImmediately(); + stopAllAudioEffects(); base.OnSuspending(e); } @@ -208,5 +207,17 @@ namespace osu.Game.Screens.Play failIndicator.RemoveAndDisposeImmediately(); return base.OnExiting(e); } + + private void stopAllAudioEffects() + { + // safety against filters or samples from the indicator playing long after the screen is exited + failIndicator.RemoveAndDisposeImmediately(); + + if (GameplayClockContainer is MasterGameplayClockContainer master) + { + playbackSettings.UserPlaybackRate.UnbindFrom(master.UserPlaybackRate); + master.UserPlaybackRate.SetDefault(); + } + } } }