Merge branch 'master' into hud_visibility

This commit is contained in:
Dean Herbert
2017-04-06 13:40:10 +09:00
committed by GitHub
46 changed files with 511 additions and 449 deletions

View File

@ -56,13 +56,17 @@ namespace osu.Game.Modes.Objects.Drawables
Sample?.Play();
}
protected override void LoadComplete()
[BackgroundDependencyLoader]
private void load()
{
base.LoadComplete();
//we may be setting a custom judgement in test cases or what not.
if (Judgement == null)
Judgement = CreateJudgement();
}
protected override void LoadComplete()
{
base.LoadComplete();
//force application of the state that was set before we loaded.
UpdateState(State);

View File

@ -42,6 +42,16 @@ namespace osu.Game.Modes.UI
/// </summary>
protected readonly KeyConversionInputManager KeyConversionInputManager;
/// <summary>
/// Whether we are currently providing the local user a gameplay cursor.
/// </summary>
public virtual bool ProvidingUserCursor => false;
/// <summary>
/// Whether we have a replay loaded currently.
/// </summary>
public bool HasReplayLoaded => InputManager.ReplayInputHandler != null;
/// <summary>
/// Whether all the HitObjects have been judged.
/// </summary>
@ -157,6 +167,8 @@ namespace osu.Game.Modes.UI
{
public event Action<TJudgement> OnJudgement;
public sealed override bool ProvidingUserCursor => !HasReplayLoaded && Playfield.ProvidingUserCursor;
protected override Container<Drawable> Content => content;
protected override bool AllObjectsJudged => Playfield.HitObjects.Children.All(h => h.Judgement.Result != HitResult.None);

View File

@ -22,6 +22,11 @@ namespace osu.Game.Modes.UI
internal Container<Drawable> ScaledContent;
/// <summary>
/// Whether we are currently providing the local user a gameplay cursor.
/// </summary>
public virtual bool ProvidingUserCursor => false;
protected override Container<Drawable> Content => content;
private readonly Container<Drawable> content;