diff --git a/osu.Game/Screens/Select/BeatmapCarousel.cs b/osu.Game/Screens/Select/BeatmapCarousel.cs index 0354e72803..861385f453 100644 --- a/osu.Game/Screens/Select/BeatmapCarousel.cs +++ b/osu.Game/Screens/Select/BeatmapCarousel.cs @@ -419,6 +419,8 @@ public void UpdateBeatmapSet(BeatmapSetInfo beatmapSet) => Schedule(() => if (beatmapsSplitOut) { + var newSets = new List(); + foreach (var beatmap in beatmapSet.Beatmaps) { var newSet = createCarouselSet(new BeatmapSetInfo(new[] { beatmap }) @@ -429,13 +431,18 @@ public void UpdateBeatmapSet(BeatmapSetInfo beatmapSet) => Schedule(() => if (newSet != null) { + newSets.Add(newSet); root.AddItem(newSet); - - // check if we can/need to maintain our current selection. - if (previouslySelectedID != null) - select((CarouselItem?)newSet.Beatmaps.FirstOrDefault(b => b.BeatmapInfo.ID == previouslySelectedID) ?? newSet); } } + + // check if we can/need to maintain our current selection. + if (previouslySelectedID != null) + { + var toSelect = newSets.FirstOrDefault(s => s.Beatmaps.Any(b => b.BeatmapInfo.ID == previouslySelectedID)) + ?? newSets.FirstOrDefault(); + select(toSelect); + } } else {