1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-29 15:52:56 +08:00
osu-lazer/osu.Game.Modes.Taiko/Objects/Drawable/Pieces/CentreHitCirclePiece.cs

47 lines
1.3 KiB
C#
Raw Normal View History

2017-03-28 09:51:22 +08:00
// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
2017-03-28 09:33:23 +08:00
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Sprites;
using osu.Game.Graphics;
2017-03-28 10:01:35 +08:00
using OpenTK;
2017-03-28 09:33:23 +08:00
2017-03-28 10:01:35 +08:00
namespace osu.Game.Modes.Taiko.Objects.Drawable.Pieces
2017-03-28 09:33:23 +08:00
{
/// <summary>
/// A circle piece used for centre hits.
/// </summary>
public class CentreHitCirclePiece : Container
{
2017-03-28 09:51:22 +08:00
private readonly CirclePiece circle;
2017-03-28 09:33:23 +08:00
public CentreHitCirclePiece(CirclePiece piece)
{
Add(circle = piece);
circle.Add(new CircularContainer
{
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
Size = new Vector2(CirclePiece.SYMBOL_INNER_SIZE),
Masking = true,
Children = new[]
{
new Box
{
RelativeSizeAxes = Axes.Both
}
}
});
}
[BackgroundDependencyLoader]
private void load(OsuColour colours)
{
circle.AccentColour = colours.PinkDarker;
}
}
}