migrant input: ja mapeja be tots els botons desde el fitxer de configuració

This commit is contained in:
2025-08-04 19:58:10 +02:00
parent adf21086e5
commit 4fd78d216a
4 changed files with 22 additions and 12 deletions

View File

@@ -143,7 +143,7 @@ auto Input::getNumGamepads() const -> int { return gamepads_.size(); }
// Obtiene el gamepad a partir de un event.id
std::shared_ptr<Input::Gamepad> Input::getGamepad(SDL_JoystickID id) const {
for (const auto& gamepad : gamepads_) {
for (const auto &gamepad : gamepads_) {
if (gamepad->instance_id == id) {
return gamepad;
}