Prev: 58032 Up: Map Next: 58106
58064: Set up message text on scroll to print
Used by the routines at 49215, 51043, 55944 and 58599.
Set up the message data, pointers and next character to print, in preparation before the print routine at 58106.
58064 LD DE,(60065) Get address of message text to print
58068 LD A,(DE) Get the number of letters/characters in the message
58069 LD (60067),A ...and store
58072 LD (60068),HL Store the screen display address pointer
58075 INC DE Point at the first letter/character to print
58076 LD (60065),DE ...and store address pointer
This entry point is used by the routines at 56668, 57139, 58106, 59130 and 59330.
58080 LD DE,(60065) Get the message text address pointer
58084 LD A,(DE) Get the letter/character to print
58085 INC DE Move the pointer on to the next one
58086 LD (60065),DE ...and store
58090 CP 27 Is the character a line break (code 27)?
58092 JR NZ,58106 If not, continue to print text
End of line character (27) encountered. Move down one character row and to the left hand position of the scroll. New screen display address calculated and stored.
As all printing is done in the bottom third of the screen, only the low byte of the screen display address needs changing.
58094 LD A,(60068) Get the current screen display address low byte
58097 AND 224 Reset the column number to 0
58099 ADD A,40 ...and add 40, thus moving down one row (32 characters) and right 8 characters, to the left hand side of the scroll, on the next row down
58101 LD (60068),A Store the screen display address low byte
58104 JR 58156 ...and jump straight into the text print routine.
Prev: 58032 Up: Map Next: 58106