Update rcore_desktop_glfw.c
This commit is contained in:
parent
89b4fbd298
commit
8eb613e50a
1 changed files with 5 additions and 5 deletions
|
|
@ -1325,7 +1325,7 @@ void PollInputEvents(void)
|
||||||
// Register previous gamepad states
|
// Register previous gamepad states
|
||||||
for (int k = 0; k < MAX_GAMEPAD_BUTTONS; k++) CORE.Input.Gamepad.previousButtonState[i][k] = CORE.Input.Gamepad.currentButtonState[i][k];
|
for (int k = 0; k < MAX_GAMEPAD_BUTTONS; k++) CORE.Input.Gamepad.previousButtonState[i][k] = CORE.Input.Gamepad.currentButtonState[i][k];
|
||||||
|
|
||||||
// Get current gamepad state
|
// Get current gamepad state using internal GLFW mapping, instead of the immediate joystick API
|
||||||
// NOTE: There is no callback available, getting it manually
|
// NOTE: There is no callback available, getting it manually
|
||||||
GLFWgamepadstate state = { 0 };
|
GLFWgamepadstate state = { 0 };
|
||||||
int result = glfwGetGamepadState(i, &state); // This remaps all gamepads so they have their buttons mapped like an xbox controller
|
int result = glfwGetGamepadState(i, &state); // This remaps all gamepads so they have their buttons mapped like an xbox controller
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue