1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-18 09:32:53 +08:00
osu-lazer/osu.Game/Skinning/SkinComponentsContainerLookup.cs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

38 lines
1.2 KiB
C#
Raw Normal View History

// 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.Game.Rulesets;
namespace osu.Game.Skinning
{
/// <summary>
/// Represents a lookup of a collection of elements that make up a particular skinnable <see cref="TargetArea"/> of the game.
/// </summary>
public class SkinComponentsContainerLookup : ISkinComponentLookup
{
/// <summary>
/// The target area / layer of the game for which skin components will be returned.
/// </summary>
public readonly TargetArea Target;
public readonly RulesetInfo? Ruleset;
public string GetSerialisableIdentifier() => Ruleset?.ShortName ?? "global";
public SkinComponentsContainerLookup(TargetArea target, RulesetInfo? ruleset = null)
{
Target = target;
Ruleset = ruleset;
}
/// <summary>
/// Represents a particular area or part of a game screen whose layout can be customised using the skin editor.
/// </summary>
public enum TargetArea
{
MainHUDComponents,
SongSelect
}
}
}