Discord
Login
Community
DARK THEME

How can i Disallow the use of the wasd or any other specific keys?

i want to use the arrow keys for moving the player (i will try have a left handed option that uses the wasd keys for moving the player) but i have plans for those keys that don't involve moving the player. Can i make it so that you can't use the wasd keys to move unless the left handed mode gives the engine the ok?

P.S: Pressing CMD + S makes the player move down infinitely, and pressing CMD + W straight up just crashes the engine. So that's why i want to disallow the use of other keys such as CMD and CTRL

Any help is very much appreciated.

Thank you for reading!

I have no idea how to disable them, but you can access the arrow keys on their own.

keyboard.ARROW_UP and so on.

And then you check keyboard.A etc. on their own.

P.S. @gilles made a keyboard test program that shows you the return string for each pressed key.

https://microstudio.dev/i/gilles/keyboardtest/

Thank you so much, that's exactly what i wanted to know

Post a reply

Progress

Status

Preview
Cancel
Post
Validate your e-mail address to participate in the community