mirror of
https://github.com/EmulatorJS/EmulatorJS.git
synced 2026-02-06 03:06:57 +00:00
Fix const assignment error
This commit is contained in:
parent
977dd04a0a
commit
48e8adb676
@ -64,7 +64,7 @@ class GamepadHandler {
|
||||
const val = (axis < 0.01 && axis > -0.01) ? 0 : axis;
|
||||
const newVal = (gamepad.axes[axisIndex] < 0.01 && gamepad.axes[axisIndex] > -0.01) ? 0 : gamepad.axes[axisIndex];
|
||||
if (newVal !== val) {
|
||||
const axis = ['LEFT_STICK_X', 'LEFT_STICK_Y', 'RIGHT_STICK_X', 'RIGHT_STICK_Y'][axisIndex];
|
||||
let axis = ['LEFT_STICK_X', 'LEFT_STICK_Y', 'RIGHT_STICK_X', 'RIGHT_STICK_Y'][axisIndex];
|
||||
if (!axis) {
|
||||
axis = "EXTRA_STICK_" + axisIndex;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user