7EED: Background : Draw all of the background.
Bg_DrawAll |
7EED |
LD HL,(Coords_NS) |
|
7EF0 |
LD DE,(Coords_EW) |
|
7EF4 |
RES 0,L |
|
7EF6 |
RES 0,E |
|
7EF8 |
PUSH HL |
|
7EF9 |
PUSH DE |
|
7EFA |
LD A,(Hero_LastDirection) |
|
7EFD |
PUSH AF |
|
7EFE |
LD A,$01 |
|
7F00 |
LD (Hero_LastDirection),A |
|
7F03 |
LD A,(Camera_Compass) |
|
7F06 |
BIT 0,A |
|
7F08 |
JR NZ,Bg_DrawAll_0 |
|
7F0A |
EX DE,HL |
Bg_DrawAll_0 |
7F0B |
LD BC,$0042 |
|
7F0E |
BIT 1,A |
|
7F10 |
JR NZ,Bg_DrawAll_1 |
|
7F12 |
LD BC,$FFBE |
Bg_DrawAll_1 |
7F15 |
ADD HL,BC |
|
7F16 |
BIT 0,A |
|
7F18 |
JR NZ,Bg_DrawAll_2 |
|
7F1A |
EX DE,HL |
Bg_DrawAll_2 |
7F1B |
LD (Coords_NS),HL |
|
7F1E |
LD (Coords_EW),DE |
|
7F22 |
LD HL,Offscreen_Bitmap |
|
7F25 |
LD B,$22 |
Bg_DrawAll_3 |
7F27 |
PUSH BC |
|
7F28 |
PUSH HL |
|
7F29 |
LD IX,Table_PathOffsets_Right |
|
7F2D |
CALL Bg_DrawColumn |
|
7F30 |
LD HL,(Camera_Compass) |
|
7F33 |
LD H,$00 |
|
7F35 |
ADD HL,HL |
|
7F36 |
LD BC,Coords_MoveVector |
|
7F39 |
ADD HL,BC |
|
7F3A |
LD E,L |
|
7F3B |
LD D,H |
|
7F3C |
CALL JP_HL |
|
7F3F |
EX DE,HL |
|
7F40 |
CALL JP_HL |
|
7F43 |
POP HL |
|
7F44 |
INC HL |
|
7F45 |
POP BC |
|
7F46 |
DJNZ Bg_DrawAll_3 |
|
7F48 |
POP AF |
|
7F49 |
LD (Hero_LastDirection),A |
|
7F4C |
POP DE |
|
7F4D |
POP HL |
|
7F4E |
LD (Coords_NS),HL |
|
7F51 |
LD (Coords_EW),DE |
|
7F55 |
RET |