1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-14 22:42:57 +08:00

Fix position of gradient in beatmap carousel

This commit is contained in:
David Zhao 2019-06-20 15:05:15 +09:00
parent d5a7b839ee
commit 65c84428cc

View File

@ -143,10 +143,9 @@ namespace osu.Game.Screens.Select.Carousel
Origin = Anchor.Centre,
FillMode = FillMode.Fill,
},
new FillFlowContainer
new Container
{
Depth = -1,
Direction = FillDirection.Horizontal,
RelativeSizeAxes = Axes.Both,
// This makes the gradient not be perfectly horizontal, but diagonal at a ~40° angle
Shear = new Vector2(0.8f, 0),
@ -157,6 +156,7 @@ namespace osu.Game.Screens.Select.Carousel
new Box
{
RelativeSizeAxes = Axes.Both,
RelativePositionAxes = Axes.Both,
Colour = Color4.Black,
Width = 0.4f,
},
@ -164,20 +164,26 @@ namespace osu.Game.Screens.Select.Carousel
new Box
{
RelativeSizeAxes = Axes.Both,
RelativePositionAxes = Axes.Both,
Colour = ColourInfo.GradientHorizontal(Color4.Black, new Color4(0f, 0f, 0f, 0.9f)),
Width = 0.05f,
X = 0.4f,
},
new Box
{
RelativeSizeAxes = Axes.Both,
RelativePositionAxes = Axes.Both,
Colour = ColourInfo.GradientHorizontal(new Color4(0f, 0f, 0f, 0.9f), new Color4(0f, 0f, 0f, 0.1f)),
Width = 0.2f,
X = 0.45f,
},
new Box
{
RelativeSizeAxes = Axes.Both,
RelativePositionAxes = Axes.Both,
Colour = ColourInfo.GradientHorizontal(new Color4(0f, 0f, 0f, 0.1f), new Color4(0, 0, 0, 0)),
Width = 0.05f,
X = 0.65f,
},
}
},