1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-15 02:33:02 +08:00

Fix attempting to add key counter controller to hierarchy in multiple places

This commit is contained in:
Bartłomiej Dach 2023-06-26 19:02:49 +02:00
parent cc45ec4fff
commit dbd76c1193
No known key found for this signature in database

View File

@ -111,12 +111,14 @@ namespace osu.Game.Screens.Play
RelativeSizeAxes = Axes.Both; RelativeSizeAxes = Axes.Both;
// intentionally not added to hierarchy here as it will be attached via `BindDrawableRuleset()`.
KeyCounter = new KeyCounterController();
Children = new[] Children = new[]
{ {
CreateFailingLayer(), CreateFailingLayer(),
//Needs to be initialized before skinnable drawables. //Needs to be initialized before skinnable drawables.
tally = new JudgementTally(), tally = new JudgementTally(),
KeyCounter = new KeyCounterController(),
mainComponents = new HUDComponentsContainer { AlwaysPresent = true, }, mainComponents = new HUDComponentsContainer { AlwaysPresent = true, },
rulesetComponents = drawableRuleset != null rulesetComponents = drawableRuleset != null
? new HUDComponentsContainer(drawableRuleset.Ruleset.RulesetInfo) { AlwaysPresent = true, } ? new HUDComponentsContainer(drawableRuleset.Ruleset.RulesetInfo) { AlwaysPresent = true, }