From dc817b62ccd63ed6477d8f2082d980769e5f359b Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Wed, 26 Jun 2024 00:49:56 +0900 Subject: [PATCH] Fix editor performance dropping over time when hit markers are enabled There's probably a better solution but let's hotfix this for now. --- osu.Game.Rulesets.Osu/Objects/Drawables/DrawableHitCircle.cs | 3 ++- osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSlider.cs | 2 +- osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSliderTail.cs | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableHitCircle.cs b/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableHitCircle.cs index 6f419073eb..7d707dea6c 100644 --- a/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableHitCircle.cs +++ b/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableHitCircle.cs @@ -325,13 +325,14 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables internal void SuppressHitAnimations() { - UpdateState(ArmedState.Idle); + UpdateState(ArmedState.Idle, true); UpdateComboColour(); // This method is called every frame. If we need to, the following can likely be converted // to code which doesn't use transforms at all. // Matches stable (see https://github.com/peppy/osu-stable-reference/blob/bb57924c1552adbed11ee3d96cdcde47cf96f2b6/osu!/GameplayElements/HitObjects/Osu/HitCircleOsu.cs#L336-L338) + using (BeginAbsoluteSequence(StateUpdateTime - 5)) this.TransformBindableTo(AccentColour, Color4.White, Math.Max(0, HitStateUpdateTime - StateUpdateTime)); diff --git a/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSlider.cs b/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSlider.cs index 7bae3cefcf..02d0ebee83 100644 --- a/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSlider.cs +++ b/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSlider.cs @@ -375,7 +375,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables internal void SuppressHitAnimations() { - UpdateState(ArmedState.Idle); + UpdateState(ArmedState.Idle, true); HeadCircle.SuppressHitAnimations(); TailCircle.SuppressHitAnimations(); } diff --git a/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSliderTail.cs b/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSliderTail.cs index 21aa672d10..42abf41d6f 100644 --- a/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSliderTail.cs +++ b/osu.Game.Rulesets.Osu/Objects/Drawables/DrawableSliderTail.cs @@ -132,7 +132,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables internal void SuppressHitAnimations() { - UpdateState(ArmedState.Idle); + UpdateState(ArmedState.Idle, true); UpdateComboColour(); using (BeginAbsoluteSequence(StateUpdateTime - 5))