![]() |
Routines |
| Prev: E51D | Up: Map | Next: E65B |
|
Used by the routine at Animate_Introduction.
Draws a two-column, two-row UDG from *HL to the screen at *DE. The introduction uses this for the moon and bat frames.
|
||||||||||
|
Draw the upper character row.
|
||||||||||
| Draw_IntroUDG | E63A | LD B,$08 | Set the pixel-row counter to 08. | |||||||
| E63C | PUSH DE | Stash the screen address on the stack. | ||||||||
| Draw_IntroUDG_Upper | E63D | LD A,(HL) | Write the left-hand pixel byte to the screen. | |||||||
| E63E | LD (DE),A | |||||||||
| E63F | INC HL | Advance the graphic pointer and move to the next column. | ||||||||
| E640 | INC E | |||||||||
| E641 | LD A,(HL) | Write the right-hand pixel byte to the screen. | ||||||||
| E642 | LD (DE),A | |||||||||
| E643 | DEC E | Move back to the left-hand column. | ||||||||
| E644 | INC D | Move down one pixel row. | ||||||||
| E645 | INC HL | Advance the graphic pointer. | ||||||||
| E646 | DJNZ Draw_IntroUDG_Upper | Decrease the pixel-row counter by one and jump to Draw_IntroUDG_Upper until all eight rows are drawn. | ||||||||
|
Move down one character row.
|
||||||||||
| E648 | POP DE | Restore the original screen address from the stack. | ||||||||
| E649 | LD A,$20 | Add 20 to the screen address. | ||||||||
| E64B | ADD A,E | |||||||||
| E64C | LD E,A | |||||||||
| E64D | LD B,$08 | Set the pixel-row counter to 08. | ||||||||
|
Draw the lower character row.
|
||||||||||
| Draw_IntroUDG_Lower | E64F | LD A,(HL) | Write the left-hand pixel byte to the screen. | |||||||
| E650 | LD (DE),A | |||||||||
| E651 | INC HL | Advance the graphic pointer and move to the next column. | ||||||||
| E652 | INC E | |||||||||
| E653 | LD A,(HL) | Write the right-hand pixel byte to the screen. | ||||||||
| E654 | LD (DE),A | |||||||||
| E655 | INC HL | Advance the graphic pointer. | ||||||||
| E656 | DEC E | Move back to the left-hand column. | ||||||||
| E657 | INC D | Move down one pixel row. | ||||||||
| E658 | DJNZ Draw_IntroUDG_Lower | Decrease the pixel-row counter by one and jump to Draw_IntroUDG_Lower until all eight rows are drawn. | ||||||||
| E65A | RET | Return. | ||||||||
| Prev: E51D | Up: Map | Next: E65B |