Move gradient to be part of the background for now

This commit is contained in:
Dean Herbert 2021-08-23 15:26:39 +09:00
parent 58fb0c042b
commit 99bb3032a5
2 changed files with 10 additions and 14 deletions

View File

@ -3,10 +3,14 @@
using System.Threading;
using osu.Framework.Allocation;
using osu.Framework.Extensions.Color4Extensions;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Colour;
using osu.Framework.Graphics.Shapes;
using osu.Framework.Screens;
using osu.Game.Online.Rooms;
using osuTK;
using osuTK.Graphics;
#nullable enable
@ -20,6 +24,12 @@ namespace osu.Game.Screens.OnlinePlay.Components
protected OnlinePlayBackgroundScreen()
: base(false)
{
AddInternal(new Box
{
RelativeSizeAxes = Axes.Both,
Depth = float.MinValue,
Colour = ColourInfo.GradientVertical(Color4.Black.Opacity(0.9f), Color4.Black.Opacity(0.6f))
});
}
[BackgroundDependencyLoader]

View File

@ -1,26 +1,12 @@
// 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.Framework.Extensions.Color4Extensions;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Colour;
using osu.Framework.Graphics.Shapes;
using osu.Framework.Screens;
using osuTK.Graphics;
namespace osu.Game.Screens.OnlinePlay
{
public class OnlinePlaySubScreenStack : OsuScreenStack
{
public OnlinePlaySubScreenStack()
{
AddInternal(new Box
{
RelativeSizeAxes = Axes.Both,
Colour = ColourInfo.GradientVertical(Color4.Black.Opacity(0.9f), Color4.Black.Opacity(0.6f))
});
}
protected override void ScreenChanged(IScreen prev, IScreen next)
{
base.ScreenChanged(prev, next);