Keyboard only input for a GBA inspired game

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By reinapepiada

I’m inspired by GBA emulators to plan the input for my current project (so like, Z, X, arrow keys,etc)- I’m wondering if anyone’s been able to do something like this? Like no mouse input, just navigating everything with those few keys.

I’m aware you can disable the mouse cursor and disable mouse input, but I’m drawing a blank when it comes to organizing the actual keyboard input. Is there an intuitive way to nest input so it can be navigated smoothly? The best I can come up is a ton of booleans but I’m sure there must be a better way (a good time to say I’m still a newbie in this!)

I have a few things already coded with keyboard input as far as actual gameplay goes, it’s the GUI that’s troubling me a lot now- especially because the gameplay and GUI will be very connected with each other.

You could try looking at some of the demo projects on github, like the role-playing game demo.

exuin | 2020-09-18 08:21

hey thank you! that’s very helpful- looking around demo projects i found out that i could be using a finite state machine to handle input so i’m gonna be looking into that!

reinapepiada | 2020-09-19 00:03