diff --git a/osu.Game.Rulesets.Karaoke/KaraokeRuleset.cs b/osu.Game.Rulesets.Karaoke/KaraokeRuleset.cs index 41b3b6e1e..61519774e 100644 --- a/osu.Game.Rulesets.Karaoke/KaraokeRuleset.cs +++ b/osu.Game.Rulesets.Karaoke/KaraokeRuleset.cs @@ -31,7 +31,9 @@ using osu.Game.Rulesets.Karaoke.Replays; using osu.Game.Rulesets.Karaoke.Resources; using osu.Game.Rulesets.Karaoke.Scoring; +using osu.Game.Rulesets.Karaoke.Skinning.Argon; using osu.Game.Rulesets.Karaoke.Skinning.Legacy; +using osu.Game.Rulesets.Karaoke.Skinning.Triangles; using osu.Game.Rulesets.Karaoke.Statistics; using osu.Game.Rulesets.Karaoke.UI; using osu.Game.Rulesets.Mods; @@ -193,8 +195,22 @@ public override IResourceStore CreateResourceStore() public override ISkin CreateSkinTransformer(ISkin skin, IBeatmap beatmap) { - // always return the legacy skin for now until have skin for karaoke. - return new KaraokeLegacySkinTransformer(skin, beatmap); + switch (skin) + { + case TrianglesSkin: + return new KaraokeTrianglesSkinTransformer(skin, beatmap); + + case ArgonSkin: + return new KaraokeArgonSkinTransformer(skin, beatmap); + + case DefaultLegacySkin: + return new KaraokeClassicSkinTransformer(skin, beatmap); + + case LegacySkin: + return new KaraokeLegacySkinTransformer(skin, beatmap); + } + + return null; } public override IConvertibleReplayFrame CreateConvertibleReplayFrame() => new KaraokeReplayFrame(); diff --git a/osu.Game.Rulesets.Karaoke/Skinning/Argon/KaraokeArgonSkinTransformer.cs b/osu.Game.Rulesets.Karaoke/Skinning/Argon/KaraokeArgonSkinTransformer.cs new file mode 100644 index 000000000..6bed074f5 --- /dev/null +++ b/osu.Game.Rulesets.Karaoke/Skinning/Argon/KaraokeArgonSkinTransformer.cs @@ -0,0 +1,17 @@ +// Copyright (c) andy840119 . Licensed under the GPL Licence. +// See the LICENCE file in the repository root for full licence text. + +using osu.Game.Beatmaps; +using osu.Game.Rulesets.Karaoke.Skinning.Default; +using osu.Game.Skinning; + +namespace osu.Game.Rulesets.Karaoke.Skinning.Argon +{ + public class KaraokeArgonSkinTransformer : KaraokeDefaultSkinTransformer + { + public KaraokeArgonSkinTransformer(ISkin skin, IBeatmap beatmap) + : base(skin, beatmap) + { + } + } +} diff --git a/osu.Game.Rulesets.Karaoke/Skinning/Default/KaraokeDefaultSkinTransformer.cs b/osu.Game.Rulesets.Karaoke/Skinning/Default/KaraokeDefaultSkinTransformer.cs new file mode 100644 index 000000000..a7cda0dd1 --- /dev/null +++ b/osu.Game.Rulesets.Karaoke/Skinning/Default/KaraokeDefaultSkinTransformer.cs @@ -0,0 +1,23 @@ +// Copyright (c) andy840119 . Licensed under the GPL Licence. +// See the LICENCE file in the repository root for full licence text. + +using osu.Framework.Bindables; +using osu.Game.Beatmaps; +using osu.Game.Skinning; + +namespace osu.Game.Rulesets.Karaoke.Skinning.Default +{ + public class KaraokeDefaultSkinTransformer : SkinTransformer + { + private readonly KaraokeSkin karaokeSkin; + + public KaraokeDefaultSkinTransformer(ISkin skin, IBeatmap beatmap) + : base(skin) + { + karaokeSkin = new KaraokeSkin(new SkinInfo(), new InternalSkinStorageResourceProvider("Default")); + } + + public override IBindable? GetConfig(TLookup lookup) + => karaokeSkin.GetConfig(lookup); + } +} diff --git a/osu.Game.Rulesets.Karaoke/Skinning/Legacy/KaraokeClassicSkinTransformer.cs b/osu.Game.Rulesets.Karaoke/Skinning/Legacy/KaraokeClassicSkinTransformer.cs new file mode 100644 index 000000000..ba876fe50 --- /dev/null +++ b/osu.Game.Rulesets.Karaoke/Skinning/Legacy/KaraokeClassicSkinTransformer.cs @@ -0,0 +1,16 @@ +// Copyright (c) andy840119 . Licensed under the GPL Licence. +// See the LICENCE file in the repository root for full licence text. + +using osu.Game.Beatmaps; +using osu.Game.Skinning; + +namespace osu.Game.Rulesets.Karaoke.Skinning.Legacy +{ + public class KaraokeClassicSkinTransformer : KaraokeLegacySkinTransformer + { + public KaraokeClassicSkinTransformer(ISkin source, IBeatmap beatmap) + : base(source, beatmap) + { + } + } +} diff --git a/osu.Game.Rulesets.Karaoke/Skinning/Triangles/KaraokeTrianglesSkinTransformer.cs b/osu.Game.Rulesets.Karaoke/Skinning/Triangles/KaraokeTrianglesSkinTransformer.cs new file mode 100644 index 000000000..aded68f44 --- /dev/null +++ b/osu.Game.Rulesets.Karaoke/Skinning/Triangles/KaraokeTrianglesSkinTransformer.cs @@ -0,0 +1,17 @@ +// Copyright (c) andy840119 . Licensed under the GPL Licence. +// See the LICENCE file in the repository root for full licence text. + +using osu.Game.Beatmaps; +using osu.Game.Rulesets.Karaoke.Skinning.Default; +using osu.Game.Skinning; + +namespace osu.Game.Rulesets.Karaoke.Skinning.Triangles +{ + public class KaraokeTrianglesSkinTransformer : KaraokeDefaultSkinTransformer + { + public KaraokeTrianglesSkinTransformer(ISkin skin, IBeatmap beatmap) + : base(skin, beatmap) + { + } + } +}