1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-28 16:52:55 +08:00

Merge pull request #121 from Tom94/better-glow

Use better glow in beatmap selection.
This commit is contained in:
Dean Herbert 2016-11-02 16:49:32 +09:00 committed by GitHub
commit 5c93ab3ecc
2 changed files with 15 additions and 8 deletions

@ -1 +1 @@
Subproject commit 059520c91803855835c734bb6d9b56e90238fe78
Subproject commit b0a06ff37b1c9594b5d64bdcfca8c250bf2889b2

View File

@ -23,7 +23,6 @@ namespace osu.Game.Beatmaps.Drawable
Masking = true;
CornerRadius = 10;
BorderColour = new Color4(221, 255, 255, 0);
GlowColour = new Color4(102, 204, 255, 100);
RelativeSizeAxes = Axes.X;
}
@ -54,21 +53,29 @@ namespace osu.Game.Beatmaps.Drawable
protected virtual void Selected()
{
BorderColour = new Color4(BorderColour.R, BorderColour.G, BorderColour.B, 1f);
GlowRadius = 10;
BorderThickness = 2.5f;
EdgeEffect = new EdgeEffect
{
Type = EdgeEffectType.Glow,
Colour = new Color4(130, 204, 255, 150),
Radius = 20,
Roundness = 10,
};
}
protected virtual void Deselected()
{
BorderColour = new Color4(BorderColour.R, BorderColour.G, BorderColour.B, 0);
GlowRadius = 0;
BorderThickness = 0;
EdgeEffect = new EdgeEffect { Type = EdgeEffectType.None };
}
protected override bool OnClick(InputState state)
{
State = PanelSelectedState.Selected;
return true;
protected override bool OnClick(InputState state)
{
State = PanelSelectedState.Selected;
return true;
}
}