mirror of
https://github.com/ppy/osu.git
synced 2024-11-09 09:37:42 +08:00
5ea948aabe
This allows the `FillMode.Fill` to take up the full space of the storyboard container.
39 lines
1.0 KiB
C#
39 lines
1.0 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.Game.Storyboards.Drawables;
|
|
using System.Collections.Generic;
|
|
|
|
namespace osu.Game.Storyboards
|
|
{
|
|
public class StoryboardLayer
|
|
{
|
|
public readonly string Name;
|
|
|
|
public readonly int Depth;
|
|
|
|
public readonly bool Masking;
|
|
|
|
public bool VisibleWhenPassing = true;
|
|
|
|
public bool VisibleWhenFailing = true;
|
|
|
|
public List<IStoryboardElement> Elements = new List<IStoryboardElement>();
|
|
|
|
public StoryboardLayer(string name, int depth, bool masking = true)
|
|
{
|
|
Name = name;
|
|
Depth = depth;
|
|
Masking = masking;
|
|
}
|
|
|
|
public void Add(IStoryboardElement element)
|
|
{
|
|
Elements.Add(element);
|
|
}
|
|
|
|
public virtual DrawableStoryboardLayer CreateDrawable()
|
|
=> new DrawableStoryboardLayer(this) { Depth = Depth, Name = Name };
|
|
}
|
|
}
|