input.fs (lib) ☞
The input.fs library contains words to read key input.
Usage
Initialise the lib with init-input to set up the correct interrupt flags:
require input.fs
: main
init-input ;
Word Index
key ( – c )
Wait for a key press and return the keycode.
key-state ( – c )
Return the keycode of the currently pressed keys, or 0 when no keys are pressed.
constants
Use these constants to determine which keycode corresponds to which key:
k-upk-downk-leftk-rightk-ak-bk-startk-start