Fix SkinnableSprite lookups broken in lazer-first skins

Regressed with removal of local `GetTexture` calls in e19ba65f91
This commit is contained in:
Dean Herbert
2022-11-13 12:46:20 +09:00
parent f7913cbf1c
commit eae8530722
4 changed files with 10 additions and 23 deletions

View File

@ -82,21 +82,14 @@ namespace osu.Game.Skinning
public override Drawable? GetDrawableComponent(ISkinComponentLookup lookup)
{
// Temporary until default skin has a valid hit lighting.
if ((lookup as SkinnableSprite.SpriteComponentLookup)?.LookupName == @"lighting") return Drawable.Empty();
if (base.GetDrawableComponent(lookup) is Drawable c)
return c;
switch (lookup)
{
case SkinnableSprite.SpriteComponentLookup spriteLookup:
switch (spriteLookup.LookupName)
{
// Temporary until default skin has a valid hit lighting.
case @"lighting":
return Drawable.Empty();
}
break;
case GlobalSkinComponentLookup globalLookup:
switch (globalLookup.Lookup)
{