From b108f54d98cddcaa9dde00ff400e6f69c8db96af Mon Sep 17 00:00:00 2001 From: lunarcleint <88809950+lunarcleint@users.noreply.github.com> Date: Tue, 30 Jan 2024 15:22:25 -0700 Subject: [PATCH] fix dumbass events when less then 16 --- source/funkin/editors/charter/CharterEventTypeSelection.hx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/source/funkin/editors/charter/CharterEventTypeSelection.hx b/source/funkin/editors/charter/CharterEventTypeSelection.hx index bb32f41e..994788a3 100644 --- a/source/funkin/editors/charter/CharterEventTypeSelection.hx +++ b/source/funkin/editors/charter/CharterEventTypeSelection.hx @@ -70,8 +70,9 @@ class CharterEventTypeSelection extends UISubstateWindow { buttonCameras.x = -subCam.scroll.x + Std.int(windowSpr.x+10); buttonCameras.y = -subCam.scroll.y + Std.int(windowSpr.y+41); - buttonCameras.scroll.y = FlxMath.bound(buttonCameras.scroll.y - (buttonsBG.hovered ? FlxG.mouse.wheel : 0) * 12, 0, - (buttons[buttons.length-1].y + buttons[buttons.length-1].bHeight) - buttonCameras.height); + if (buttons.length > 16) + buttonCameras.scroll.y = FlxMath.bound(buttonCameras.scroll.y - (buttonsBG.hovered ? FlxG.mouse.wheel : 0) * 12, 0, + (buttons[buttons.length-1].y + buttons[buttons.length-1].bHeight) - buttonCameras.height); } override function destroy() {