![]() |
Routines |
| Prev: 46975 | Up: Map | Next: 47103 |
|
Used by the routine at 47336. Waits for a keypress and returns with the zero flag set if it was ENTER; otherwise inserts the ASCII code of the keypress into the next slot in the character's name message, and returns with A holding the number of characters typed so far.
|
||||||||||
| 47080 | PUSH HL | Save the message address for the character's name | ||||||||
| 47081 | PUSH DE | |||||||||
| 47082 | LD DE,20512 | Set DE to the display file address at which to print the character's name | ||||||||
| 47085 | CALL 45032 | Print the character's name (which is being edited) | ||||||||
| 47088 | CALL 26426 | Wait for a keypress and collect its ASCII code in A | ||||||||
| 47091 | JR Z,47088 | |||||||||
| 47093 | POP DE | |||||||||
| 47094 | POP HL | Restore the character name message address to HL | ||||||||
| 47095 | CP 13 | Was ENTER pressed? | ||||||||
| 47097 | RET Z | Return if so | ||||||||
| 47098 | LD (DE),A | Store the ASCII code of the key just pressed | ||||||||
| 47099 | INC E | Move DE along to the next slot in the name message | ||||||||
| 47100 | LD A,E | Set A equal to the number of characters typed so far | ||||||||
| 47101 | SUB L | |||||||||
| 47102 | RET | |||||||||
| Prev: 46975 | Up: Map | Next: 47103 |