Making menues selectable by keyboard or controller

This commit is contained in:
Zoe Roux
2021-06-10 18:05:56 +02:00
parent d328a976ed
commit e38c2e56fe
5 changed files with 53 additions and 70 deletions
+1 -1
View File
@@ -30,7 +30,7 @@ namespace BBM
};
for (auto key : keyPressedMap)
key.second = gamepad.isPressed(key.first);
key.second = gamepad.isDown(key.first);
controllable.move.x = gamepad.getAxisValue(gamepadComponent.LeftStickX) * -1;
controllable.move.y = gamepad.getAxisValue(gamepadComponent.LeftStickY) * -1;
controllable.move.x -= gamepad.isDown(gamepadComponent.keyRight);