From 28d6ff5d9c8bac9390e7576829623798934fc61a Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Tue, 21 Dec 2021 12:36:01 +0900 Subject: [PATCH] Fix potential wrong thread mutation in `ColourHitErrorMeter` --- .../Screens/Play/HUD/HitErrorMeters/ColourHitErrorMeter.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/osu.Game/Screens/Play/HUD/HitErrorMeters/ColourHitErrorMeter.cs b/osu.Game/Screens/Play/HUD/HitErrorMeters/ColourHitErrorMeter.cs index 5012be7249..00e6059541 100644 --- a/osu.Game/Screens/Play/HUD/HitErrorMeters/ColourHitErrorMeter.cs +++ b/osu.Game/Screens/Play/HUD/HitErrorMeters/ColourHitErrorMeter.cs @@ -53,13 +53,13 @@ namespace osu.Game.Screens.Play.HUD.HitErrorMeters LayoutEasing = Easing.OutQuint; } - public void Push(Color4 colour) + public void Push(Color4 colour) => Schedule(() => { Add(new HitErrorCircle(colour, drawable_judgement_size)); if (Children.Count > max_available_judgements) Children.FirstOrDefault(c => !c.IsRemoved)?.Remove(); - } + }); } internal class HitErrorCircle : Container