updated comment in rcore_desktop_glfw.c

This commit is contained in:
Dino 2025-12-26 10:48:58 +01:00 committed by GitHub
parent c4531302ee
commit b0431fea1b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1269,7 +1269,7 @@ void PollInputEvents(void)
int isGamepadConnected = glfwGetGamepadState(i, &state); // This remapps all gamepads so they have their buttons mapped like an xbox controller int isGamepadConnected = glfwGetGamepadState(i, &state); // This remapps all gamepads so they have their buttons mapped like an xbox controller
if (!isGamepadConnected) if (!isGamepadConnected)
{ {
// setting axes to expected value instead of GLFW's 0.0f default when gamepad isnt connected // setting axes to expected resting value instead of GLFW's 0.0f default when gamepad isnt connected
state.axes[GAMEPAD_AXIS_LEFT_TRIGGER] = -1.0f; state.axes[GAMEPAD_AXIS_LEFT_TRIGGER] = -1.0f;
state.axes[GAMEPAD_AXIS_RIGHT_TRIGGER] = -1.0f; state.axes[GAMEPAD_AXIS_RIGHT_TRIGGER] = -1.0f;
} }