![]() |
Routines |
| Prev: 5F48 | Up: Map | Next: 5F6D |
|
Used by the routines at Show_Briefing_One, Show_Briefing_Two, Show_Briefing_Three, Show_Briefing_Four and Show_Briefing_Five.
Prints C characters from HL at DE, then fills two attribute rows with A.
|
||||||||||||||
|
Print the characters, then colour two attribute rows.
|
||||||||||||||
| Print_Briefing_Line | 5F4B | PUSH AF | Stash the attribute, character counter and screen address on the stack. | |||||||||||
| 5F4C | PUSH BC | |||||||||||||
| 5F4D | PUSH DE | |||||||||||||
| 5F4E | CALL Print_Double_Height | Call Print_Double_Height. | ||||||||||||
| 5F51 | POP HL | Restore the screen address from the stack. | ||||||||||||
| 5F52 | LD A,H | Rotate the high byte into an attribute offset. | ||||||||||||
| 5F53 | RRCA | |||||||||||||
| 5F54 | RRCA | |||||||||||||
| 5F55 | RRCA | |||||||||||||
| 5F56 | OR %01010000 | Set bits 4 and 6. | ||||||||||||
| 5F58 | LD H,A | Copy the attribute address to H. | ||||||||||||
| 5F59 | POP BC | Restore the character counter from the stack, and copy it to D. | ||||||||||||
| 5F5A | LD D,C | |||||||||||||
| 5F5B | LD E,$02 | Set the row counter to 02 in E. | ||||||||||||
| 5F5D | POP AF | Restore the attribute from the stack. | ||||||||||||
|
Fill two attribute rows.
|
||||||||||||||
| Fill_Briefing_Attribute_Rows | 5F5E | PUSH HL | Stash the attribute pointer on the stack. | |||||||||||
| 5F5F | LD B,D | Set the column counter from D. | ||||||||||||
| Fill_Briefing_Attribute_Column | 5F60 | LD (HL),A | Write the attribute to the current cell. | |||||||||||
| 5F61 | INC L | Advance the attribute pointer by one. | ||||||||||||
| 5F62 | DJNZ Fill_Briefing_Attribute_Column | Decrease the column counter by one and loop back to Fill_Briefing_Attribute_Column until the column counter is zero. | ||||||||||||
| 5F64 | LD BC,$0020 | Set the row stride to 20 in BC. | ||||||||||||
| 5F67 | POP HL | Restore the attribute pointer from the stack. | ||||||||||||
| 5F68 | ADD HL,BC | Advance the attribute pointer by the row stride. | ||||||||||||
| 5F69 | DEC E | Decrease the row counter by one, and jump to Fill_Briefing_Attribute_Rows until the row counter is zero. | ||||||||||||
| 5F6A | JR NZ,Fill_Briefing_Attribute_Rows | |||||||||||||
| 5F6C | RET | Return. | ||||||||||||
| Prev: 5F48 | Up: Map | Next: 5F6D |