pnj
This commit is contained in:
parent
565f6d4c19
commit
f6bdd4b51d
1 changed files with 4 additions and 1 deletions
|
@ -32,7 +32,10 @@ class Input {
|
|||
});
|
||||
|
||||
window.addEventListener("keydown", (e)=>{
|
||||
e.preventDefault(); //blocks the action of the key (cf. Killian)
|
||||
//blocks the action of the key (cf. Killian)
|
||||
if(["Space","ArrowUp","ArrowDown","ArrowLeft","ArrowRight"].indexOf(e.code) > -1) {
|
||||
e.preventDefault();
|
||||
}
|
||||
this.keysDown.add(e.key.toLowerCase())
|
||||
this.updateDir();
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue