1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-22 00:43:25 +08:00

Remove "Unranked" text from ModDisplay

This commit is contained in:
Dean Herbert 2021-06-09 13:45:09 +09:00
parent 249a8f259b
commit 7774344f0e
9 changed files with 2 additions and 28 deletions

View File

@ -202,7 +202,6 @@ namespace osu.Game.Screens.OnlinePlay
Child = modDisplay = new ModDisplay Child = modDisplay = new ModDisplay
{ {
Scale = new Vector2(0.4f), Scale = new Vector2(0.4f),
DisplayUnrankedText = false,
ExpansionMode = ExpansionMode.AlwaysExpanded ExpansionMode = ExpansionMode.AlwaysExpanded
} }
} }

View File

@ -31,7 +31,6 @@ namespace osu.Game.Screens.OnlinePlay
{ {
Anchor = Anchor.Centre, Anchor = Anchor.Centre,
Origin = Anchor.Centre, Origin = Anchor.Centre,
DisplayUnrankedText = false,
Scale = new Vector2(0.8f), Scale = new Vector2(0.8f),
ExpansionMode = ExpansionMode.AlwaysContracted, ExpansionMode = ExpansionMode.AlwaysContracted,
}); });

View File

@ -185,7 +185,6 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer
{ {
Anchor = Anchor.CentreLeft, Anchor = Anchor.CentreLeft,
Origin = Anchor.CentreLeft, Origin = Anchor.CentreLeft,
DisplayUnrankedText = false,
Current = UserMods, Current = UserMods,
Scale = new Vector2(0.8f), Scale = new Vector2(0.8f),
}, },

View File

@ -139,7 +139,6 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer.Participants
{ {
Scale = new Vector2(0.5f), Scale = new Vector2(0.5f),
ExpansionMode = ExpansionMode.AlwaysContracted, ExpansionMode = ExpansionMode.AlwaysContracted,
DisplayUnrankedText = false,
} }
}, },
userStateDisplay = new StateDisplay userStateDisplay = new StateDisplay

View File

@ -175,7 +175,6 @@ namespace osu.Game.Screens.OnlinePlay.Playlists
{ {
Anchor = Anchor.CentreLeft, Anchor = Anchor.CentreLeft,
Origin = Anchor.CentreLeft, Origin = Anchor.CentreLeft,
DisplayUnrankedText = false,
Current = UserMods, Current = UserMods,
Scale = new Vector2(0.8f), Scale = new Vector2(0.8f),
}, },

View File

@ -3,18 +3,15 @@
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq;
using osu.Framework.Bindables; using osu.Framework.Bindables;
using osu.Framework.Graphics; using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers; using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.UserInterface; using osu.Framework.Graphics.UserInterface;
using osu.Game.Graphics.Sprites; using osu.Framework.Input.Events;
using osu.Game.Graphics.Containers;
using osu.Game.Rulesets.Mods; using osu.Game.Rulesets.Mods;
using osu.Game.Rulesets.UI; using osu.Game.Rulesets.UI;
using osuTK; using osuTK;
using osu.Game.Graphics.Containers;
using osu.Framework.Input.Events;
using osu.Game.Graphics;
namespace osu.Game.Screens.Play.HUD namespace osu.Game.Screens.Play.HUD
{ {
@ -22,8 +19,6 @@ namespace osu.Game.Screens.Play.HUD
{ {
private const int fade_duration = 1000; private const int fade_duration = 1000;
public bool DisplayUnrankedText = true;
public ExpansionMode ExpansionMode = ExpansionMode.ExpandOnHover; public ExpansionMode ExpansionMode = ExpansionMode.ExpandOnHover;
private readonly Bindable<IReadOnlyList<Mod>> current = new Bindable<IReadOnlyList<Mod>>(); private readonly Bindable<IReadOnlyList<Mod>> current = new Bindable<IReadOnlyList<Mod>>();
@ -42,7 +37,6 @@ namespace osu.Game.Screens.Play.HUD
} }
private readonly FillFlowContainer<ModIcon> iconsContainer; private readonly FillFlowContainer<ModIcon> iconsContainer;
private readonly OsuSpriteText unrankedText;
public ModDisplay() public ModDisplay()
{ {
@ -63,13 +57,6 @@ namespace osu.Game.Screens.Play.HUD
AutoSizeAxes = Axes.Both, AutoSizeAxes = Axes.Both,
Direction = FillDirection.Horizontal, Direction = FillDirection.Horizontal,
}, },
unrankedText = new OsuSpriteText
{
Anchor = Anchor.TopCentre,
Origin = Anchor.TopCentre,
Text = @"/ UNRANKED /",
Font = OsuFont.Numeric.With(size: 12)
}
}, },
}; };
} }
@ -102,11 +89,6 @@ namespace osu.Game.Screens.Play.HUD
private void appearTransform() private void appearTransform()
{ {
if (DisplayUnrankedText && Current.Value.Any(m => !m.Ranked))
unrankedText.FadeInFromZero(fade_duration, Easing.OutQuint);
else
unrankedText.Hide();
expand(); expand();
using (iconsContainer.BeginDelayedSequence(1200)) using (iconsContainer.BeginDelayedSequence(1200))

View File

@ -137,7 +137,6 @@ namespace osu.Game.Screens.Ranking.Contracted
Origin = Anchor.TopCentre, Origin = Anchor.TopCentre,
AutoSizeAxes = Axes.Both, AutoSizeAxes = Axes.Both,
ExpansionMode = ExpansionMode.AlwaysExpanded, ExpansionMode = ExpansionMode.AlwaysExpanded,
DisplayUnrankedText = false,
Current = { Value = score.Mods }, Current = { Value = score.Mods },
Scale = new Vector2(0.5f), Scale = new Vector2(0.5f),
} }

View File

@ -242,7 +242,6 @@ namespace osu.Game.Screens.Ranking.Expanded
{ {
Anchor = Anchor.CentreLeft, Anchor = Anchor.CentreLeft,
Origin = Anchor.CentreLeft, Origin = Anchor.CentreLeft,
DisplayUnrankedText = false,
ExpansionMode = ExpansionMode.AlwaysExpanded, ExpansionMode = ExpansionMode.AlwaysExpanded,
Scale = new Vector2(0.5f), Scale = new Vector2(0.5f),
Current = { Value = score.Mods } Current = { Value = score.Mods }

View File

@ -37,7 +37,6 @@ namespace osu.Game.Screens.Select
{ {
Anchor = Anchor.Centre, Anchor = Anchor.Centre,
Origin = Anchor.Centre, Origin = Anchor.Centre,
DisplayUnrankedText = false,
Scale = new Vector2(0.8f), Scale = new Vector2(0.8f),
ExpansionMode = ExpansionMode.AlwaysContracted, ExpansionMode = ExpansionMode.AlwaysContracted,
}); });