Prev: D191 Up: Map Next: D2CF
D192: Copy Source Character Data To Character State Data
Handles copying a "normal" bandit into the bandit state cache at Bandit_State_Reference.
Prep_Bandit_Open D192 LD L,(IX+$02) Handles copying 0007 bytes of data from the address contained at (depending on which door is currently being actioned);
Address Door
Door_Source_01 Door 1
Door_Source_02 Door 2
Door_Source_03 Door 3
to Bandit_State_Reference.
D195 LD H,(IX+$03)
D198 LD DE,$D71E
D19B LD BC,$0007
D19E PUSH HL
D19F PUSH DE
D1A0 PUSH BC
D1A1 LDIR
D1A3 CALL Bandit_Open_Routing Call Bandit_Open_Routing to begin this characters actions.
D1A6 POP BC Restore the source, target and counter from above.
D1A7 POP DE
D1A8 POP HL
D1A9 EX DE,HL Swap the source and target.
D1AA LD A,($D18F) Check if D18F is zero. Write 00 to it. If it wasn't zero then return.
D1AD AND A
D1AE LD A,$00
D1B0 LD ($D18F),A
D1B3 RET NZ
D1B4 LDIR Else copy the (swapped) source back to the new target and return.
D1B6 RET
And copying a successful bandit encounter to close the door.
Prep_Bandit_Close D1B7 LD L,(IX+$02) Handles copying 0007 bytes of data from the address contained at (depending on which door is currently being actioned);
Address Door
Door_Source_01 Door 1
Door_Source_02 Door 2
Door_Source_03 Door 3
to Bandit_State_Reference.
D1BA LD H,(IX+$03)
D1BD LD DE,$D71E
D1C0 LD BC,$0007
D1C3 PUSH HL
D1C4 PUSH DE
D1C5 PUSH BC
D1C6 LDIR
D1C8 CALL Bandit_Close_Routing Call Bandit_Close_Routing to begin this characters actions.
D1CB POP BC Restore the source, target and counter from above.
D1CC POP DE
D1CD POP HL
D1CE EX DE,HL Swap the source and target.
D1CF LD A,($D18F) Check if D18F is zero. Write $00 to it. If it wasn't zero then return.
D1D2 AND A
D1D3 LD A,$00
D1D5 LD ($D18F),A
D1D8 RET NZ
D1D9 LDIR Else copy the (swapped) source back to the new target and return.
D1DB RET
Handles copying Bowie state data into the state cache at Bowie_Good_Bad.
Prep_Bowie D1DC LD L,(IX+$02) Handles copying $0009 bytes of data from the address contained at (depending on which door is currently being actioned);
Address Door
Door_Source_01 Door 1
Door_Source_02 Door 2
Door_Source_03 Door 3
to Bowie_Good_Bad.
D1DF LD H,(IX+$03)
D1E2 LD DE,$D7C5
D1E5 LD BC,$0009
D1E8 PUSH HL
D1E9 PUSH DE
D1EA PUSH BC
D1EB LDIR
D1ED CALL Bowie_Routing Call Bowie_Routing to begin this characters actions.
D1F0 POP BC Restore the source, target and counter from above.
D1F1 POP DE
D1F2 POP HL
D1F3 EX DE,HL Swap the source and target.
D1F4 LD A,($D18F) Check if D18F is zero. Write $00 to it. If it wasn't zero then return.
D1F7 AND A
D1F8 LD A,$00
D1FA LD ($D18F),A
D1FD RET NZ
D1FE LDIR Else copy the (swapped) source back to the new target and return.
D200 RET
Handles copying customer state data into the state cache at Customer_Frame_01.
Prep_Customer D201 LD L,(IX+$02) Handles copying $000F bytes of data from the address contained at (depending on which door is currently being actioned);
Address Door
Door_Source_01 Door 1
Door_Source_02 Door 2
Door_Source_03 Door 3
to Customer_Frame_01.
D204 LD H,(IX+$03)
D207 LD DE,$D48F
D20A LD BC,$000F
D20D PUSH HL
D20E PUSH DE
D20F PUSH BC
D210 LDIR
D212 CALL Customer_Routing Call Customer_Routing to begin this characters actions.
D215 POP BC Restore the source, target and counter from above.
D216 POP DE
D217 POP HL
D218 EX DE,HL Swap the source and target.
D219 LD A,($D18F) Check if D18F is zero. Write $00 to it. If it wasn't zero then return.
D21C AND A
D21D LD A,$00
D21F LD ($D18F),A
D222 RET NZ
D223 LDIR Else copy the (swapped) source back to the new target and return.
D225 RET
Handles copying customer "is shot" state data into the state cache at Customer_Frame_01.
Prep_Customer_Shot D226 LD L,(IX+$02) Handles copying $000F bytes of data from the address contained at (depending on which door is currently being actioned);
Address Door
Door_Source_01 Door 1
Door_Source_02 Door 2
Door_Source_03 Door 3
to Customer_Frame_01.
D229 LD H,(IX+$03)
D22C LD DE,$D48F
D22F LD BC,$000F
D232 PUSH HL
D233 PUSH DE
D234 PUSH BC
D235 LDIR
D237 CALL Customer_Shot Call Customer_Shot.
D23A POP BC Restore the source, target and counter from above.
D23B POP DE
D23C POP HL
D23D EX DE,HL Swap the source and target.
D23E LDIR Copy the (swapped) source back to the new target and return.
D240 RET
Handles copying Julius state data into the state cache at Julius_Good_Bad.
Prep_Julius_Open D241 LD L,(IX+$02) Handles copying $000A bytes of data from the address contained at (depending on which door is currently being actioned);
Address Door
Door_Source_01 Door 1
Door_Source_02 Door 2
Door_Source_03 Door 3
to Julius_Good_Bad.
D244 LD H,(IX+$03)
D247 LD DE,$D8E5
D24A LD BC,$000A
D24D PUSH HL
D24E PUSH DE
D24F PUSH BC
D250 LDIR
D252 CALL Julius_Open_Routing Call Julius_Open_Routing.
D255 POP BC Restore the source, target and counter from above.
D256 POP HL
D257 POP DE
D258 LD A,($D18F) Check if D18F is zero. Write $00 to it. If it wasn't zero then return.
D25B AND A
D25C LD A,$00
D25E LD ($D18F),A
D261 RET NZ
D262 LDIR Copy the source to the target again and return.
D264 RET
And copying a successful Julius encounter to close the door.
Prep_Julius_Close D265 LD L,(IX+$02) Handles copying $000A bytes of data from the address contained at (depending on which door is currently being actioned);
Address Door
Door_Source_01 Door 1
Door_Source_02 Door 2
Door_Source_03 Door 3
to Julius_Good_Bad.
D268 LD H,(IX+$03)
D26B LD DE,$D8E5
D26E LD BC,$000A
D271 PUSH HL
D272 PUSH DE
D273 PUSH BC
D274 LDIR
D276 CALL Julius_Close_Routing Call Julius_Close_Routing.
D279 POP BC Restore the source, target and counter from above.
D27A POP HL
D27B POP DE
D27C LD A,($D18F) Check if D18F is zero. Write $00 to it. If it wasn't zero then return.
D27F AND A
D280 LD A,$00
D282 LD ($D18F),A
D285 RET NZ
D286 LDIR Copy the source to the target again and return.
D288 RET
Handles copying a "drawing bandit" into the bandit state cache at Bandit_Draw.
Prep_Bandit_Draw_Open D289 LD L,(IX+$02) Handles copying $000B bytes of data from the address contained at (depending on which door is currently being actioned);
Address Door
Door_Source_01 Door 1
Door_Source_02 Door 2
Door_Source_03 Door 3
to Bandit_Draw.
D28C LD H,(IX+$03)
D28F LD DE,$DA0C
D292 LD BC,$000B
D295 PUSH HL
D296 PUSH DE
D297 PUSH BC
D298 LDIR
D29A CALL Bandit_Draw_Open_Routing Call Bandit_Draw_Open_Routing.
D29D POP BC Restore the source, target and counter from above.
D29E POP HL
D29F POP DE
D2A0 LD A,($D18F) Check if D18F is zero. Write $00 to it. If it wasn't zero then return.
D2A3 AND A
D2A4 LD A,$00
D2A6 LD ($D18F),A
D2A9 RET NZ
D2AA LDIR Copy the source to the target again and return.
D2AC RET
And copying a successful "drawing bandit" encounter to close the door.
Prep_Bandit_Draw_Close D2AD LD L,(IX+$02) Handles copying $000B bytes of data from the address contained at (depending on which door is currently being actioned);
Address Door
Door_Source_01 Door 1
Door_Source_02 Door 2
Door_Source_03 Door 3
to Bandit_Draw.
D2B0 LD H,(IX+$03)
D2B3 LD DE,$DA0C
D2B6 LD BC,$000B
D2B9 PUSH HL
D2BA PUSH DE
D2BB PUSH BC
D2BC LDIR
D2BE CALL Bandit_Draw_Close_Routing Call Bandit_Draw_Close_Routing.
D2C1 POP BC Restore the source, target and counter from above.
D2C2 POP HL
D2C3 POP DE
D2C4 LD A,($D18F) Check if D18F is zero. If it wasn't zero then return.
D2C7 AND A
D2C8 LD ($D18F),A
D2CB RET NZ
D2CC LDIR Copy the source to the target again and return.
D2CE RET
Prev: D191 Up: Map Next: D2CF