Prev: 58599 Up: Map Next: 58789
58764: Clear the spell message text area on the scroll
Used by the routine at 50807.
Clears any messages on two lines of the message area of the scroll, e.g. "Project thy soul", "Gatehouse level"
58764 LD L,136 Low byte of HL screen display address pointer which is set to the top left of the scroll spell area, where the spell messages (e.g. "Project thy soul") are printed
58766 LD C,2 2 row of text
58768 LD E,16 16 columns of text
58770 LD H,80 High byte of HL screen display address pointer which is set to the top left of the scroll spell area, where the spell messages (e.g. "Project thy soul") are printed
58772 LD B,8 8 pixel rows to clear
58774 LD (HL),0 Clear pixel row
58776 INC H Move down one pixel line
58777 DJNZ 58774 Repeat x 8
58779 INC L Move right one character square/column
58780 DEC E Repeat x 16 columns
58781 JR NZ,58770
58783 LD L,167 Set column position to character row below, one line down.
This should probably be one less as this value is one character to the left of the previous line, though it doesn't really matter
58785 DEC C Repeat the clear loop for 2 character rows
58786 JR NZ,58768
58788 RET
Prev: 58599 Up: Map Next: 58789