9F13: Stage: Draw everyone including Cuchulain and everything on stage.
Stage_Draw |
9F13 |
LD A,(Hero_FrameCount) |
Stage_Draw_0 |
9F16 |
LD (Hero_FrameCount),A |
|
9F19 |
CALL Room_Events |
|
9F1C |
LD A,(Camera_Compass) |
|
9F1F |
BIT 1,A |
|
9F21 |
JR NZ,Stage_Draw_1 |
|
9F23 |
CALL People_Main |
Stage_Draw_1 |
9F26 |
LD A,(Hero_FrameCount) |
|
9F29 |
AND A |
|
9F2A |
JP Z,Stage_Draw_8 |
|
9F2D |
LD DE,ScratchPad |
|
9F30 |
LD A,(Hero_FrameCount) |
|
9F33 |
LD (Hero_FrameCount),A |
|
9F36 |
LD HL,_60db |
|
9F39 |
LD A,$38 |
Stage_Draw_2 |
9F3B |
LDI |
|
9F3D |
LDI |
|
9F3F |
LDI |
|
9F41 |
LDI |
|
9F43 |
LD BC,$001E |
|
9F46 |
ADD HL,BC |
|
9F47 |
DEC A |
|
9F48 |
JR NZ,Stage_Draw_2 |
|
9F4A |
LD HL,(Hero_FrameCount) |
|
9F4D |
LD H,$00 |
|
9F4F |
LD DE,Bmp_HeroMaskIndices |
|
9F52 |
ADD HL,DE |
|
9F53 |
LD A,(HL) |
|
9F54 |
LD (Bmp_IndexTemp),A |
|
9F57 |
LD A,(Hero_FrameCount) |
|
9F5A |
CP $12 |
|
9F5C |
JR Z,Stage_Draw_4 |
|
9F5E |
CP $13 |
|
9F60 |
JR Z,Stage_Draw_4 |
|
9F62 |
LD L,A |
|
9F63 |
CALL Bitmap_CopyFrame |
|
9F66 |
LD A,(Hero_LastDirection) |
|
9F69 |
RRCA |
|
9F6A |
RRCA |
|
9F6B |
XOR (HL) |
|
9F6C |
JP P,Stage_Draw_3 |
|
9F6F |
LD HL,(Hero_FrameCount) |
|
9F72 |
CALL Bitmap_Reverse |
Stage_Draw_3 |
9F75 |
LD HL,(Bmp_IndexTemp) |
|
9F78 |
CALL Bitmap_CopyFrame |
|
9F7B |
LD A,(Hero_LastDirection) |
|
9F7E |
RRCA |
|
9F7F |
RRCA |
|
9F80 |
XOR (HL) |
|
9F81 |
JP P,Stage_Draw_4 |
|
9F84 |
LD HL,(Bmp_IndexTemp) |
|
9F87 |
CALL Bitmap_Reverse |
Stage_Draw_4 |
9F8A |
LD HL,(Hero_FrameCount) |
|
9F8D |
CALL Bitmap_CopyFrame |
|
9F90 |
LD HL,(Bitmap_InfoCache) |
|
9F93 |
LD (TempAl),HL |
|
9F96 |
LD HL,(Bmp_IndexTemp) |
|
9F99 |
CALL Bitmap_CopyFrame |
|
9F9C |
LD A,(Bitmap_InfoCache_Height) |
|
9F9F |
AND $7F |
|
9FA1 |
RLA |
|
9FA2 |
RLA |
|
9FA3 |
RLA |
|
9FA4 |
LD (TempBl),A |
|
9FA7 |
LD A,(Bitmap_InfoCache_Width) |
|
9FAA |
AND $7F |
|
9FAC |
LD (TempBh),A |
|
9FAF |
LD DE,(Bitmap_InfoCache) |
|
9FB3 |
LD HL,_60db |
|
9FB6 |
LD A,(TempBh) |
|
9FB9 |
CP $02 |
|
9FBB |
JR NZ,Stage_Draw_5 |
|
9FBD |
INC HL |
Stage_Draw_5 |
9FBE |
LD IX,(TempAl) |
|
9FC2 |
LD BC,(TempBl) |
Stage_Draw_6 |
9FC6 |
PUSH BC |
|
9FC7 |
PUSH HL |
Stage_Draw_7 |
9FC8 |
LD A,(DE) |
|
9FC9 |
AND (HL) |
|
9FCA |
OR (IX+$00) |
|
9FCD |
LD (HL),A |
|
9FCE |
INC HL |
|
9FCF |
INC DE |
|
9FD0 |
INC IX |
|
9FD2 |
DJNZ Stage_Draw_7 |
|
9FD4 |
POP HL |
|
9FD5 |
LD BC,$0022 |
|
9FD8 |
ADD HL,BC |
|
9FD9 |
POP BC |
|
9FDA |
DEC C |
|
9FDB |
JR NZ,Stage_Draw_6 |
Stage_Draw_8 |
9FDD |
LD A,(Camera_Compass) |
|
9FE0 |
BIT 1,A |
|
9FE2 |
RET Z |
|
9FE3 |
JP People_Main |