mirror of
https://github.com/eugene-serb/wavelovers.git
synced 2023-09-09 23:41:16 +03:00
Fixed no add gamepad if this length >= 1
This commit is contained in:
@@ -53,7 +53,7 @@
|
|||||||
window.addEventListener('gamepaddisconnected', () => this.deleteGamepad(event));
|
window.addEventListener('gamepaddisconnected', () => this.deleteGamepad(event));
|
||||||
},
|
},
|
||||||
addGamepad(event) {
|
addGamepad(event) {
|
||||||
if (this.gamepads.length > 1) {
|
if (this.gamepads.length >= 1) {
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
this.gamepads.push(new Gamepad(event.gamepad));
|
this.gamepads.push(new Gamepad(event.gamepad));
|
||||||
|
|||||||
Reference in New Issue
Block a user