mirror of
https://github.com/osukey/osukey.git
synced 2025-07-02 16:59:53 +09:00
Fix crash when starting with an empty bracket
This commit is contained in:
@ -104,9 +104,10 @@ namespace osu.Game.Tournament.Screens.MapPool
|
|||||||
|
|
||||||
private void beatmapChanged(ValueChangedEvent<BeatmapInfo> beatmap)
|
private void beatmapChanged(ValueChangedEvent<BeatmapInfo> beatmap)
|
||||||
{
|
{
|
||||||
if (currentMatch.Value.PicksBans.Count(p => p.Type == ChoiceType.Ban) < 2)
|
if (currentMatch.Value == null || currentMatch.Value.PicksBans.Count(p => p.Type == ChoiceType.Ban) < 2)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
// if bans have already been placed, beatmap changes result in a selection being made autoamtically
|
||||||
if (beatmap.NewValue.OnlineBeatmapID != null)
|
if (beatmap.NewValue.OnlineBeatmapID != null)
|
||||||
addForBeatmap(beatmap.NewValue.OnlineBeatmapID.Value);
|
addForBeatmap(beatmap.NewValue.OnlineBeatmapID.Value);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user