![]() |
Routines |
| Prev: A0AD | Up: Map | Next: A1AB |
|
Used by the routine at 9470.
|
||||
| A0F8 | XOR A | Reset Rex on elevtor | ||
| A0F9 | LD ($A213),A | |||
| A0FC | LD HL,($A1B2) | Set HL to point into tile type buffer data under Rex feet | ||
| A0FF | LD DE,$0060 | |||
| A102 | ADD HL,DE | |||
| A103 | LD A,(HL) | Check tile type | ||
| A104 | CP $12 | Jump forward to handle elevator | ||
| A106 | JP Z,$A130 | |||
| A109 | LD HL,($A1B2) | Set HL to point into tile type buffer data in front-under Rex feet | ||
| A10C | LD DE,$0061 | |||
| A10F | ADD HL,DE | |||
| A110 | LD A,(HL) | Check tile type | ||
| A111 | CP $07 | Jump to handle respawn | ||
| A113 | JP Z,$9D2D | |||
| A116 | CP $08 | Jump to handle shield recharging | ||
| A118 | JP Z,$A187 | |||
| A11B | CP $0D | Jump to handle Double fire weapon bonus | ||
| A11D | JP Z,$A14B | |||
| A120 | CP $0A | Jump to handle laser weapon bonus | ||
| A122 | JP Z,$A15A | |||
| A125 | CP $0B | Jump to handle multiple weapon bonus | ||
| A127 | JP Z,$A169 | |||
| A12A | CP $0C | Jump to handle spray weapon bonus | ||
| A12C | JP Z,$A178 | |||
| A12F | RET | |||
|
handle Rex on elevator
|
||||
| A130 | XOR A | Reset speed Rex | ||
| A131 | LD ($A22A),A | |||
| A134 | LD A,$01 | Set Rex on elevator | ||
| A136 | LD ($A213),A | |||
| A139 | LD A,($A250) | Return if Rex is not grid fixed | ||
| A13C | AND $07 | |||
| A13E | OR A | |||
| A13F | RET NZ | |||
| A140 | XOR A | Set falling speed to zero | ||
| A141 | LD ($A255),A | |||
| A144 | CALL $CEB2 | Configure Rex for falling - Does nothing | ||
| A147 | CALL $CE52 | Configure Rex for jump | ||
| A14A | RET | |||
|
handle double fire weapon bonus
|
||||
| A14B | INC HL | Return if next tile is not the same type | ||
| A14C | LD A,(HL) | |||
| A14D | CP $0D | |||
| A14F | RET NZ | |||
| A150 | CALL $A8F6 | Update weapon in inventory (HUD) | ||
| A153 | LD HL,$AC5D | Set HL the base address for text definition of DOUBLE FIRE weapon | ||
| A156 | CALL $D609 | Show weapon bonus windows | ||
| A159 | RET | |||
|
handle laser weapon bonus
|
||||
| A15A | INC HL | Return if next tile is not the same type | ||
| A15B | LD A,(HL) | |||
| A15C | CP $0A | |||
| A15E | RET NZ | |||
| A15F | CALL $A8FC | Update weapon in inventory (HUD) | ||
| A162 | LD HL,$AC6E | Set HL the base address for text definition of LASER weapon | ||
| A165 | CALL $D609 | Show weapon bonus windows | ||
| A168 | RET | |||
|
handle multiple weapon bonus
|
||||
| A169 | INC HL | Return if next tile is not the same type | ||
| A16A | LD A,(HL) | |||
| A16B | CP $0B | |||
| A16D | RET NZ | |||
| A16E | CALL $A902 | Update weapon in inventory (HUD) | ||
| A171 | LD HL,$AC79 | Set HL the base address for text definition of MULTIPLE weapon | ||
| A174 | CALL $D609 | Show weapon bonus windows | ||
| A177 | RET | |||
|
handle spray weapon bonus
|
||||
| A178 | INC HL | Return if next tile is not the same type | ||
| A179 | LD A,(HL) | |||
| A17A | CP $0C | |||
| A17C | RET NZ | |||
| A17D | CALL $A908 | Update weapon in inventory (HUD) | ||
| A180 | LD HL,$AC87 | Set HL the base address for text definition of SPRAY weapon | ||
| A183 | CALL $D609 | Show weapon bonus windows | ||
| A186 | RET | |||
|
handle shield recharging
|
||||
| A187 | INC HL | Return if next tile is not the same type | ||
| A188 | LD A,(HL) | |||
| A189 | CP $08 | |||
| A18B | RET NZ | |||
| A18C | LD A,($A1E2) | Return if shield active | ||
| A18F | OR A | |||
| A190 | RET NZ | |||
| A191 | LD A,($A1E6) | Increment shield power | ||
| A194 | INC A | |||
| A195 | CP $64 | Return if shield power = 100 | ||
| A197 | RET Z | |||
| A198 | LD ($A1E6),A | Set the new shield power | ||
| A19B | CALL $9918 | Draw shield power | ||
| A19E | LD A,($D5D2) | Return if channel 2 in use | ||
| A1A1 | CP $FF | |||
| A1A3 | RET NZ | |||
| A1A4 | LD DE,$D5BE | Set DE to the shield recharging sound | ||
| A1A7 | CALL $D37F | Configure sound channel and mixer register | ||
| A1AA | RET | |||
| Prev: A0AD | Up: Map | Next: A1AB |