Routines
| Prev: C403 | Up: Map | Next: C41F |
C415: GET-KEY, but block until a key is actually pressed
|
A thin blocking wrapper: repeatedly calls the real GET-KEY at C41F, ignoring the 'no key' result, until bit 7 of the return value is set - then masks that bit off and returns the plain ASCII code. Used wherever the game needs to pause for 'press a key to continue' (e.g. the page-wait logic in the print-window routine below), as opposed to the non-blocking poll used elsewhere (e.g. in the boot sequence above).
|
||||||||
| C415 | CALL $C41F | Ask if a key is available | ||||||
| C418 | BIT 7,A | Was one? | ||||||
| C41A | JR Z,$C415 | No: keep asking | ||||||
| C41C | AND $7F | Yes: strip the "a key was pressed" tag, keep just the ASCII | ||||||
| C41E | RET | Return to the caller | ||||||
| Prev: C403 | Up: Map | Next: C41F |