mirror of
https://github.com/ppy/osu.git
synced 2025-01-16 00:13:12 +08:00
Avoid polluting Player with HUD-specific code.
This commit is contained in:
parent
10910cfcef
commit
48368779ab
@ -109,6 +109,11 @@ namespace osu.Game.Screens.Play
|
|||||||
public virtual void BindHitRenderer(HitRenderer hitRenderer)
|
public virtual void BindHitRenderer(HitRenderer hitRenderer)
|
||||||
{
|
{
|
||||||
hitRenderer.InputManager.Add(KeyCounter.GetReceptor());
|
hitRenderer.InputManager.Add(KeyCounter.GetReceptor());
|
||||||
|
|
||||||
|
// in the case a replay isn't loaded, we want some elements to only appear briefly.
|
||||||
|
if (!hitRenderer.HasReplayLoaded)
|
||||||
|
using (ModDisplay.BeginDelayedSequence(2000))
|
||||||
|
ModDisplay.FadeOut(200);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override bool OnKeyDown(InputState state, KeyDownEventArgs args)
|
protected override bool OnKeyDown(InputState state, KeyDownEventArgs args)
|
||||||
|
@ -356,10 +356,6 @@ namespace osu.Game.Screens.Play
|
|||||||
|
|
||||||
hitRendererContainer.Alpha = 0;
|
hitRendererContainer.Alpha = 0;
|
||||||
hitRendererContainer.FadeIn(750, EasingTypes.OutQuint);
|
hitRendererContainer.FadeIn(750, EasingTypes.OutQuint);
|
||||||
|
|
||||||
if (!HitRenderer.HasReplayLoaded)
|
|
||||||
using (hudOverlay.ModDisplay.BeginDelayedSequence(2000))
|
|
||||||
hudOverlay.ModDisplay.FadeOut(200);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void OnSuspending(Screen next)
|
protected override void OnSuspending(Screen next)
|
||||||
|
Loading…
Reference in New Issue
Block a user