![]() |
Routines |
| Prev: C403 | Up: Map | Next: C41F |
|
Used by the routines at GameEntryPoint, WaitForAKey, PrintStringAndWaitForKeypress and ScrollScreenAndResetDisplay.
Waits until a key is held, then returns that key without the press bit.
|
||||||||
|
Bit 7 is only set after a key has been pressed.
|
||||||||
| WaitForKeypress_Loop | C415 | CALL GetKeypress | Call GetKeypress to read the keyboard. | |||||
| C418 | BIT 7,A | Jump back to WaitForKeypress_Loop while bit 7 of A is clear. | ||||||
| C41A | JR Z,WaitForKeypress_Loop | |||||||
|
Strip off the set bit for the response.
|
||||||||
| C41C | AND %01111111 | Strip the key-pressed marker (bit 7) to leave the ASCII code. | ||||||
| C41E | RET | Return. | ||||||
| Prev: C403 | Up: Map | Next: C41F |