Merge branch 'master' into user-status-wiring

This commit is contained in:
Lucas A
2019-04-15 11:43:53 +02:00
committed by GitHub
60 changed files with 222 additions and 182 deletions

View File

@ -2,6 +2,7 @@
// See the LICENCE file in the repository root for full licence text.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using osu.Framework.Allocation;
@ -16,6 +17,7 @@ using osu.Game.Beatmaps;
using osu.Game.Graphics;
using osu.Game.Graphics.Sprites;
using osu.Game.Graphics.UserInterface;
using osu.Game.Rulesets.Mods;
using osu.Game.Screens.Menu;
using osu.Game.Screens.Play.HUD;
using osu.Game.Screens.Play.PlayerSettings;
@ -69,7 +71,7 @@ namespace osu.Game.Screens.Play
RelativeSizeAxes = Axes.Both,
Children = new Drawable[]
{
info = new BeatmapMetadataDisplay(Beatmap.Value)
info = new BeatmapMetadataDisplay(Beatmap.Value, Mods.Value)
{
Alpha = 0,
Anchor = Anchor.Centre,
@ -302,6 +304,7 @@ namespace osu.Game.Screens.Play
}
private readonly WorkingBeatmap beatmap;
private readonly IReadOnlyList<Mod> mods;
private LoadingAnimation loading;
private Sprite backgroundSprite;
private ModDisplay modDisplay;
@ -323,9 +326,10 @@ namespace osu.Game.Screens.Play
}
}
public BeatmapMetadataDisplay(WorkingBeatmap beatmap)
public BeatmapMetadataDisplay(WorkingBeatmap beatmap, IReadOnlyList<Mod> mods)
{
this.beatmap = beatmap;
this.mods = mods;
}
[BackgroundDependencyLoader]
@ -406,7 +410,7 @@ namespace osu.Game.Screens.Play
Origin = Anchor.TopCentre,
AutoSizeAxes = Axes.Both,
Margin = new MarginPadding { Top = 20 },
Current = beatmap.Mods
Current = { Value = mods }
}
},
}