From 0d748abb3412262ff364a99aa5631e70427769ca Mon Sep 17 00:00:00 2001 From: Derrick Timmermans Date: Wed, 21 Feb 2024 14:57:45 +0100 Subject: [PATCH] Fix Holds resetting holdstarttime on every input --- .../Objects/Drawables/DrawableHold.cs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/osu.Game.Rulesets.Sentakki/Objects/Drawables/DrawableHold.cs b/osu.Game.Rulesets.Sentakki/Objects/Drawables/DrawableHold.cs index 28d1d156b..63184d050 100644 --- a/osu.Game.Rulesets.Sentakki/Objects/Drawables/DrawableHold.cs +++ b/osu.Game.Rulesets.Sentakki/Objects/Drawables/DrawableHold.cs @@ -200,6 +200,9 @@ protected override void ClearNestedHitObjects() private bool beginHoldAt(double timeOffset) { + if (HoldStartTime is not null) + return false; + if (timeOffset < -Head.HitObject.HitWindows.WindowFor(HitResult.Miss)) return false; @@ -225,15 +228,14 @@ public bool OnPressed(KeyBindingPressEvent e) if (e.Action != SentakkiAction.Key1 + HitObject.Lane) return false; + pressedCount++; + if (beginHoldAt(Time.Current - Head.HitObject.StartTime)) { Head.UpdateResult(); NoteBody.FadeColour(AccentColour.Value, 50); - } - - // Only the first input to this hitobject will be blocked - if (pressedCount++ == 0) return true; + } // Passthrough excess inputs to later hitobjects in the same lane return false;