From 8bab844e0c3ac5ea17a6417ceb7ecf28d43875a5 Mon Sep 17 00:00:00 2001 From: LeonGamerPS4 <108237023+LeonGamerPS1@users.noreply.github.com> Date: Sat, 13 Dec 2025 03:09:15 +0100 Subject: [PATCH] Fix Sustain Clipping --- source/funkin/game/Strum.hx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/source/funkin/game/Strum.hx b/source/funkin/game/Strum.hx index d5031945..9ad90edf 100644 --- a/source/funkin/game/Strum.hx +++ b/source/funkin/game/Strum.hx @@ -121,7 +121,7 @@ class Strum extends FlxSprite { public override function update(elapsed:Float) { super.update(elapsed); if (cpu) { - if (lastHit + (Conductor.crochet / 2) < Conductor.songPosition && getAnim() == "confirm") { + if (lastHit + (Conductor.crochet * 0.5) < Conductor.songPosition && getAnim() == "confirm") { playAnim("static"); } } @@ -133,7 +133,7 @@ class Strum extends FlxSprite { } @:noCompletion public static inline final PIX180:Float = 565.4866776461628; // 180 * Math.PI - @:noCompletion public static final N_WIDTHDIV2:Float = Note.swagWidth / 2; + @:noCompletion public static final N_WIDTHDIV2:Float = Note.swagWidth / 2; // DEPRECATED /** * Updates the position of a note. @@ -162,16 +162,16 @@ class Strum extends FlxSprite { if (shouldX || shouldY) { if (daNote.strumRelativePos) { - if (shouldX) daNote.x = (this.width - daNote.width) / 2; + if (shouldX) daNote.x = (this.width - daNote.width) * 0.5; if (shouldY) { daNote.y = (daNote.strumTime - Conductor.songPosition) * (0.45 * CoolUtil.quantize(getScrollSpeed(daNote), 100)); - if (daNote.isSustainNote) daNote.y += N_WIDTHDIV2; + if (daNote.isSustainNote) daNote.y += height * 0.5; } } else { var offset = FlxPoint.get(0, (Conductor.songPosition - daNote.strumTime) * (0.45 * CoolUtil.quantize(getScrollSpeed(daNote), 100))); var realOffset = FlxPoint.get(0, 0); - if (daNote.isSustainNote) offset.y -= N_WIDTHDIV2; + if (daNote.isSustainNote) offset.y -= height * 0.5; if (Std.int(daNote.__noteAngle % 360) != 0) { var noteAngleCos = FlxMath.fastCos(daNote.__noteAngle / PIX180); @@ -257,4 +257,4 @@ class Strum extends FlxSprite { public inline function getAnim() { return animation.name; } -} \ No newline at end of file +}