Prev: 6B45 Up: Map Next: 6B69
6B46: Print a message box
Used by the routines at 7414 and 7EB1. Prepares the text of a message in the graphic buffer at E428 and then copies the buffer to the screen.
Input
A Message number
C Message box attribute byte
DE Attribute file address at which to print the message box
6B46 LD HL,$E428 The graphic data for the message box will be stored in the buffer at E428 before being copied to the screen
6B49 LD B,$18 24=3 rows of 8 character squares
6B4B LD (HL),C Prepare the attribute bytes in the buffer
6B4C INC L
6B4D DJNZ $6B4B
6B4F PUSH DE Save the attribute file address temporarily
6B50 LD L,A Set DE to the start address of the message
6B51 LD H,$FE
6B53 LD E,(HL)
6B54 INC H
6B55 LD D,(HL)
6B56 LD HL,$E458 Point HL at the address in the buffer corresponding to the start of the fourth row of pixels from the top of the message box (the first three rows are always empty)
6B59 CALL $6B1B Prepare the first line of text in the buffer
6B5C LD HL,$E498 Point HL at the address in the buffer corresponding to the start of the 12th row of pixels from the top
6B5F CALL $6B1F Prepare the second line of text in the buffer
6B62 POP DE Retrieve the attribute file address for the message box
6B63 LD HL,$E428 Point to the start of the buffer
6B66 JP $6AE4 Transfer the buffer to the screen
Prev: 6B45 Up: Map Next: 6B69