From 9c17f3473a71a8131d975ce5e100d9f043c1b31e Mon Sep 17 00:00:00 2001 From: Marlian <84173858+MCbabel@users.noreply.github.com> Date: Thu, 5 Mar 2026 14:39:11 +0100 Subject: [PATCH] Fix Ctrl-sprint not working while flying in creative mode (#563) Remove the !player->abilities.flying guard that was incorrectly added around the Ctrl-sprint block in Input.cpp during the KBM refactor. This prevented Ctrl+W from initiating sprint while flying in creative mode. Sprinting on the ground in both survival and creative worked fine. The sprint flag now sets correctly whenever Ctrl+W is held, including while flying. LocalPlayer::aiStep() still properly gates setSprinting() with onGround, enoughFoodToSprint, isUsingItem etc. Fixes smartcmd/MinecraftConsoles#470 --- Minecraft.Client/Input.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/Minecraft.Client/Input.cpp b/Minecraft.Client/Input.cpp index 4d931d3e..1fd67683 100644 --- a/Minecraft.Client/Input.cpp +++ b/Minecraft.Client/Input.cpp @@ -104,8 +104,7 @@ void Input::tick(LocalPlayer *player) } } - // Ctrl + forward = sprint (hold to sprint) - if (!player->abilities.flying) + // Ctrl + forward = sprint (hold to sprint, including while flying) { bool ctrlHeld = g_KBMInput.IsKeyDown(KeyboardMouseInput::KEY_SPRINT); bool movingForward = (kbYA > 0.0f); @@ -119,10 +118,6 @@ void Input::tick(LocalPlayer *player) sprinting = false; } } - else - { - sprinting = false; - } } else if (iPad == 0) {