mirror of
https://github.com/ppy/osu
synced 2025-03-01 17:11:12 +00:00
Fix incorrect event unbind logic
This commit is contained in:
parent
52db7b36fc
commit
edcbd4de6d
@ -40,10 +40,12 @@ namespace osu.Game.Screens.Play.HUD.HitErrorMeters
|
|||||||
if (gameplayClockContainer != null)
|
if (gameplayClockContainer != null)
|
||||||
gameplayClockContainer.OnSeek += Clear;
|
gameplayClockContainer.OnSeek += Clear;
|
||||||
|
|
||||||
// Scheduled as meter implementations are likely going to change/add drawables when reacting to this.
|
processor.NewJudgement += processorNewJudgement;
|
||||||
processor.NewJudgement += j => Schedule(() => OnNewJudgement(j));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Scheduled as meter implementations are likely going to change/add drawables when reacting to this.
|
||||||
|
private void processorNewJudgement(JudgementResult j) => Schedule(() => OnNewJudgement(j));
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Fired when a new judgement arrives.
|
/// Fired when a new judgement arrives.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -89,7 +91,7 @@ namespace osu.Game.Screens.Play.HUD.HitErrorMeters
|
|||||||
base.Dispose(isDisposing);
|
base.Dispose(isDisposing);
|
||||||
|
|
||||||
if (processor != null)
|
if (processor != null)
|
||||||
processor.NewJudgement -= OnNewJudgement;
|
processor.NewJudgement -= processorNewJudgement;
|
||||||
|
|
||||||
if (gameplayClockContainer != null)
|
if (gameplayClockContainer != null)
|
||||||
gameplayClockContainer.OnSeek -= Clear;
|
gameplayClockContainer.OnSeek -= Clear;
|
||||||
|
Loading…
Reference in New Issue
Block a user