1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-13 13:32:54 +08:00
osu-lazer/osu.Game.Rulesets.Catch/Skinning/Argon/CatchArgonSkinTransformer.cs
Dean Herbert 9969c00ead
Apply two minor fixes from code review
Co-authored-by: Bartłomiej Dach <dach.bartlomiej@gmail.com>
2022-10-28 10:19:53 +09:00

47 lines
1.5 KiB
C#

// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Graphics;
using osu.Game.Skinning;
namespace osu.Game.Rulesets.Catch.Skinning.Argon
{
public class CatchArgonSkinTransformer : SkinTransformer
{
public CatchArgonSkinTransformer(ISkin skin)
: base(skin)
{
}
public override Drawable? GetDrawableComponent(ISkinComponent component)
{
switch (component)
{
case CatchSkinComponent catchComponent:
// TODO: Once everything is finalised, consider throwing UnsupportedSkinComponentException on missing entries.
switch (catchComponent.Component)
{
case CatchSkinComponents.HitExplosion:
return new ArgonHitExplosion();
case CatchSkinComponents.Catcher:
return new ArgonCatcher();
case CatchSkinComponents.Fruit:
return new ArgonFruitPiece();
case CatchSkinComponents.Banana:
return new ArgonBananaPiece();
case CatchSkinComponents.Droplet:
return new ArgonDropletPiece();
}
break;
}
return base.GetDrawableComponent(component);
}
}
}