1
0
mirror of https://github.com/ppy/osu.git synced 2025-03-23 02:57:25 +08:00

Fix incorrect HUD component fallback

Legacy skins should now always show the legacy hud components. The
conditional here is no longer valid as fallback lookups happen at a
*skin*-fallback level rather than internal *source*-fallback.

Put another way, `LegacyDefaultSkin` (with user customisations) should
still display the classic HUD components even if a font is not provided,
as that font will be available via the skin lookup hierarchy.

The TODO removed in this commit has been already resolved so this code
is no longer required.
This commit is contained in:
Dean Herbert 2022-03-24 12:36:16 +09:00
parent 05c7e09d79
commit a4d17a915f

View File

@ -356,26 +356,15 @@ namespace osu.Game.Skinning
}
})
{
Children = this.HasFont(LegacyFont.Score)
? new Drawable[]
{
new LegacyComboCounter(),
new LegacyScoreCounter(),
new LegacyAccuracyCounter(),
new LegacyHealthDisplay(),
new SongProgress(),
new BarHitErrorMeter(),
}
: new Drawable[]
{
// TODO: these should fallback to using osu!classic skin textures, rather than doing this.
new DefaultComboCounter(),
new DefaultScoreCounter(),
new DefaultAccuracyCounter(),
new DefaultHealthDisplay(),
new SongProgress(),
new BarHitErrorMeter(),
}
Children = new Drawable[]
{
new LegacyComboCounter(),
new LegacyScoreCounter(),
new LegacyAccuracyCounter(),
new LegacyHealthDisplay(),
new SongProgress(),
new BarHitErrorMeter(),
}
};
return skinnableTargetWrapper;