-- name: Run Binds -- description: Are you on keyboard?\nAre you tired of always running?\nDo you want to take it slow sometimes and just walk?\nThen this mod is for YOU.\n\nThis mods adds run binds which can be toggled through the mod settings.\n\nMod by \\#DCDCDC\\x\\#00FF00\\Luigi\\#434343\\Gamer\\#DCDCDC\\x local settingsList = { runBinds = mod_storage_load_bool("Run-Binds") or false, invertBinds = mod_storage_load_bool("Invert-Binds") or false, walkSpeed = mod_storage_load_number("Walk-Speed") or 32, tipToeSpeed = mod_storage_load_number("Tip-Toe-Speed") or 16 } function run(m) if m.playerIndex ~= 0 then return end if m.controller.stickMag > 0 then if settingsList.runBinds then runBind = m.controller.buttonDown & Y_BUTTON ~= 0 if settingsList.invertBinds then if runBind then m.controller.stickMag = settingsList.walkSpeed end elseif not runBind then m.controller.stickMag = settingsList.walkSpeed end if not runBind and m.controller.buttonDown & X_BUTTON ~= 0 then m.controller.stickMag = settingsList.tipToeSpeed end end end end --Settings Enum RUN_BINDS = 0 INVERT_BINDS = 1 WALK_SPEED = 2 TIP_TOE_SPEED = 3 function settings(i, v) if i == RUN_BINDS then settingsList.runBinds = v mod_storage_save_bool("Run-Binds", settingsList.runBinds) elseif i == INVERT_BINDS then settingsList.invertBinds = v mod_storage_save_bool("Invert-Binds", settingsList.invertBinds) elseif i == WALK_SPEED then settingsList.walkSpeed = v mod_storage_save_number("Walk-Speed", settingsList.walkSpeed) elseif i == TIP_TOE_SPEED then settingsList.tipToeSpeed = v mod_storage_save_number("Tip-Toe-Speed", settingsList.tipToeSpeed) end end hook_event(HOOK_BEFORE_MARIO_UPDATE, run) hook_mod_menu_checkbox("Run Binds", mod_storage_load_bool("Run-Binds") or false, settings) hook_mod_menu_checkbox("Invert Binds", mod_storage_load_bool("Invert-Binds") or false, settings) hook_mod_menu_slider("Walk Speed", mod_storage_load_number("Walk-Speed") or 32, 26, 47, settings) hook_mod_menu_slider("Tip Toe Speed", mod_storage_load_number("Tip-Toe-Speed") or 16, 1, 25, settings)