Make ready button also have triangles

This commit is contained in:
Dean Herbert 2020-02-20 18:39:10 +09:00
parent e7fca689b1
commit a0b578082e
2 changed files with 7 additions and 3 deletions

View File

@ -47,7 +47,6 @@ public Footer()
private void load(OsuColour colours)
{
background.Colour = OsuColour.FromHex(@"28242d");
startButton.BackgroundColour = colours.Green;
}
}
}

View File

@ -6,12 +6,13 @@
using osu.Framework.Allocation;
using osu.Framework.Bindables;
using osu.Game.Beatmaps;
using osu.Game.Graphics;
using osu.Game.Graphics.UserInterface;
using osu.Game.Online.Multiplayer;
namespace osu.Game.Screens.Multi.Match.Components
{
public class ReadyButton : OsuButton
public class ReadyButton : TriangleButton
{
public readonly Bindable<PlaylistItem> SelectedItem = new Bindable<PlaylistItem>();
@ -32,12 +33,16 @@ public ReadyButton()
}
[BackgroundDependencyLoader]
private void load()
private void load(OsuColour colours)
{
beatmaps.ItemAdded += beatmapAdded;
beatmaps.ItemRemoved += beatmapRemoved;
SelectedItem.BindValueChanged(item => updateSelectedItem(item.NewValue), true);
BackgroundColour = colours.Green;
Triangles.ColourDark = colours.Green;
Triangles.ColourLight = colours.GreenLight;
}
private void updateSelectedItem(PlaylistItem item)