From f31d840c13eecb92af95e69aceb26fad15a69a0f Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Tue, 2 Jul 2019 22:25:03 +0900 Subject: [PATCH] Dispose previous WorkingBeatmap on change --- osu.Game/OsuGame.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/osu.Game/OsuGame.cs b/osu.Game/OsuGame.cs index bfa4aeadef..49c543537a 100644 --- a/osu.Game/OsuGame.cs +++ b/osu.Game/OsuGame.cs @@ -296,6 +296,8 @@ private void beatmapChanged(ValueChangedEvent beatmap) if (nextBeatmap?.Track != null) nextBeatmap.Track.Completed += currentTrackCompleted; + beatmap.OldValue?.Dispose(); + nextBeatmap?.LoadBeatmapAsync(); }