I need to know if there are any functions that can tell if a key is BEING pressed. I dont want any event listeners because those are always active. i need some function that is used like this:
if (keyDown("a")){
alert("You pressed a")
}
I need to know if there are any functions that can tell if a key is BEING pressed. I dont want any event listeners because those are always active. i need some function that is used like this:
if (keyDown("a")){
alert("You pressed a")
}