mirror of
https://github.com/ppy/osu.git
synced 2025-01-28 02:43:19 +08:00
Fix seeding screen crashing on seedings with null mod
This commit is contained in:
parent
9a2fb8ca6c
commit
714255e6d4
@ -179,21 +179,28 @@ namespace osu.Game.Tournament.Screens.TeamIntro
|
|||||||
[BackgroundDependencyLoader]
|
[BackgroundDependencyLoader]
|
||||||
private void load(TextureStore textures)
|
private void load(TextureStore textures)
|
||||||
{
|
{
|
||||||
|
FillFlowContainer row;
|
||||||
|
|
||||||
InternalChildren = new Drawable[]
|
InternalChildren = new Drawable[]
|
||||||
{
|
{
|
||||||
new FillFlowContainer
|
row = new FillFlowContainer
|
||||||
{
|
{
|
||||||
AutoSizeAxes = Axes.Both,
|
AutoSizeAxes = Axes.Both,
|
||||||
Direction = FillDirection.Horizontal,
|
Direction = FillDirection.Horizontal,
|
||||||
Spacing = new Vector2(5),
|
Spacing = new Vector2(5),
|
||||||
Children = new Drawable[]
|
},
|
||||||
|
};
|
||||||
|
|
||||||
|
if (!string.IsNullOrEmpty(mods))
|
||||||
{
|
{
|
||||||
new Sprite
|
row.Add(new Sprite
|
||||||
{
|
{
|
||||||
Texture = textures.Get($"mods/{mods.ToLower()}"),
|
Texture = textures.Get($"mods/{mods.ToLower()}"),
|
||||||
Scale = new Vector2(0.5f)
|
Scale = new Vector2(0.5f)
|
||||||
},
|
});
|
||||||
new Container
|
}
|
||||||
|
|
||||||
|
row.Add(new Container
|
||||||
{
|
{
|
||||||
Size = new Vector2(50, 16),
|
Size = new Vector2(50, 16),
|
||||||
CornerRadius = 10,
|
CornerRadius = 10,
|
||||||
@ -213,10 +220,7 @@ namespace osu.Game.Tournament.Screens.TeamIntro
|
|||||||
Colour = TournamentGame.ELEMENT_FOREGROUND_COLOUR
|
Colour = TournamentGame.ELEMENT_FOREGROUND_COLOUR
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
},
|
});
|
||||||
}
|
|
||||||
},
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user