From 019262763034571c531a62558f266633d62d2e94 Mon Sep 17 00:00:00 2001 From: lunarcleint <88809950+lunarcleint@users.noreply.github.com> Date: Wed, 26 Jul 2023 22:05:39 -0700 Subject: [PATCH] notes dragging fixed --- source/funkin/editors/charter/CharterNote.hx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/source/funkin/editors/charter/CharterNote.hx b/source/funkin/editors/charter/CharterNote.hx index b066a465..353b0a8d 100644 --- a/source/funkin/editors/charter/CharterNote.hx +++ b/source/funkin/editors/charter/CharterNote.hx @@ -140,7 +140,12 @@ class CharterNote extends UISprite implements ICharterSelectable { } public function handleDrag(change:FlxPoint) { - updatePos(step + change.x, id + Std.int(change.y), susLength, type); + var newID:Int = id + Std.int(change.y); + if (newID > ((Charter.instance.strumLines.members.length*4)-1)) newID %= 4; + else if (newID < 0) newID = (Charter.instance.strumLines.members.length*4) + newID % 4; + + updatePos(step + change.x, newID, susLength, type); + Charter.instance.notesGroup.remove(this); Charter.instance.notesGroup.add(this); }