From accbae3c80f8fec86b044ea586fbd8a47a1913e5 Mon Sep 17 00:00:00 2001 From: Cameron Taylor Date: Fri, 4 Jun 2021 02:43:05 -0400 Subject: [PATCH] anim swapping easier --- source/DebugBoundingState.hx | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/source/DebugBoundingState.hx b/source/DebugBoundingState.hx index 21bc4d7c3..024ad35c9 100644 --- a/source/DebugBoundingState.hx +++ b/source/DebugBoundingState.hx @@ -182,6 +182,7 @@ class DebugBoundingState extends FlxState spriteSheetView.visible = true; case OFFSETSHIT: spriteSheetView.visible = false; + offsetControls(); } /* if (charInput.hasFocus && FlxG.keys.justPressed.ENTER) @@ -200,6 +201,22 @@ class DebugBoundingState extends FlxState super.update(elapsed); } + function offsetControls():Void + { + if (FlxG.keys.justPressed.RBRACKET) + { + if (Std.parseInt(animDropDownMenu.selectedId) + 1 < animDropDownMenu.length) + animDropDownMenu.selectedId = Std.string(Std.parseInt(animDropDownMenu.selectedId) + 1); + animDropDownMenu.callback(animDropDownMenu.selectedId); + } + if (FlxG.keys.justPressed.LBRACKET) + { + if (Std.parseInt(animDropDownMenu.selectedId) - 1 >= 0) + animDropDownMenu.selectedId = Std.string(Std.parseInt(animDropDownMenu.selectedId) - 1); + animDropDownMenu.callback(animDropDownMenu.selectedId); + } + } + var swagChar:Character; function loadAnimShit(char:String)