Please work

This commit is contained in:
kalaposfos13 2025-04-25 21:54:11 +02:00
parent 057f2f9beb
commit 05ee6f0f42

View File

@ -351,7 +351,7 @@ u8 GameControllers::GetGamepadIndexFromJoystickId(SDL_JoystickID id) {
UNREACHABLE_MSG("Gamepad is null!");
}
for (int i = 0; i < 4; i++) {
if (controllers[i]->m_sdl_gamepad == gamepad) {
if (SDL_GetGamepadID(controllers[i]->m_sdl_gamepad) == id) {
return controllers[i]->player_index;
}
}