mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 19:22:54 +08:00
Reorder HitErrorDisplay
This commit is contained in:
parent
6fb8a6cdbe
commit
dfccc60361
@ -35,18 +35,6 @@ namespace osu.Game.Screens.Play.HUD
|
||||
processor.NewJudgement += onNewJudgement;
|
||||
}
|
||||
|
||||
protected override void Dispose(bool isDisposing)
|
||||
{
|
||||
base.Dispose(isDisposing);
|
||||
processor.NewJudgement -= onNewJudgement;
|
||||
}
|
||||
|
||||
private void onNewJudgement(JudgementResult result)
|
||||
{
|
||||
foreach (var c in Children)
|
||||
c.OnNewJudgement(result);
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(OsuConfigManager config)
|
||||
{
|
||||
@ -59,6 +47,12 @@ namespace osu.Game.Screens.Play.HUD
|
||||
type.BindValueChanged(typeChanged, true);
|
||||
}
|
||||
|
||||
private void onNewJudgement(JudgementResult result)
|
||||
{
|
||||
foreach (var c in Children)
|
||||
c.OnNewJudgement(result);
|
||||
}
|
||||
|
||||
private void typeChanged(ValueChangedEvent<ScoreMeterType> type)
|
||||
{
|
||||
Children.ForEach(c => c.FadeOut(fade_duration, Easing.OutQuint));
|
||||
@ -96,5 +90,11 @@ namespace osu.Game.Screens.Play.HUD
|
||||
Add(display);
|
||||
display.FadeInFromZero(fade_duration, Easing.OutQuint);
|
||||
}
|
||||
|
||||
protected override void Dispose(bool isDisposing)
|
||||
{
|
||||
base.Dispose(isDisposing);
|
||||
processor.NewJudgement -= onNewJudgement;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user