![]() |
Routines |
| Prev: 70DB | Up: Map | Next: 71E1 |
|
Used by the routine at Handler_Frogs.
|
||||
|
Return if an egg isn't being dropped at this point.
|
||||
| HandlerFrog01_CheckEggCollision | 7190 | LD A,($5FA9) | Return if *EggDropFlag is unset. | |
| 7193 | OR A | |||
| 7194 | RET Z | |||
|
Check the first frog.
|
||||
| 7195 | LD HL,$71E9 | HL=Frog1_StunCountdown. | ||
| 7198 | LD IY,$DAE0 | IY=Egg_X_Position. | ||
| 719C | LD IX,$DAC8 | IX=Sprite02_3Wide_X_Position. | ||
| 71A0 | CALL CheckEggCollision | Call CheckEggCollision. | ||
| 71A3 | JR C,HandlerFrog02_CheckEggCollision | Jump to HandlerFrog02_CheckEggCollision if the egg isn't colliding with the first frog. | ||
|
Item hit the first frog.
|
||||
| 71A5 | LD A,(HL) | Jump to HandlerEggCollision_Destroy01 if the frog is already stunned. | ||
| 71A6 | OR A | |||
| 71A7 | JR NZ,HandlerEggCollision_Destroy01 | |||
|
Stun the frog and set a random stun timer/ award points.
|
||||
| 71A9 | LD A,R | A=the contents of the Memory Refresh Register. | ||
| 71AB | OR %01000000 | Set bit 6 (ensure a minimum stun duration). | ||
| 71AD | LD (HL),A | Write the stun duration to the first frogs stun countdown. | ||
| 71AE | LD A,$0A | Call AddToScore to add 0A points to the score. | ||
| 71B0 | CALL AddToScore | |||
| 71B3 | CALL PlayHitSound | Call PlayHitSound. | ||
| HandlerEggCollision_Destroy01 | 71B6 | CALL CancelEggDrop | Call CancelEggDrop. | |
|
Check if the second frog is active (level above 01).
|
||||
| HandlerFrog02_CheckEggCollision | 71B9 | LD A,($5FB1) | Return if *CurrentLevel is equal to 01. | |
| 71BC | CP $01 | |||
| 71BE | RET Z | |||
|
Check the second frog.
|
||||
| 71BF | LD IX,$DACC | IX=Sprite03_3Wide_X_Position. | ||
| 71C3 | LD HL,$71EC | HL=Frog2_StunCountdown. | ||
| 71C6 | CALL CheckEggCollision | Call CheckEggCollision. | ||
| 71C9 | RET C | Return if the egg isn't colliding with the second frog. | ||
|
Item hit the second frog.
|
||||
| 71CA | LD A,(HL) | Jump to HandlerEggCollision_Destroy02 if the frog is already stunned. | ||
| 71CB | OR A | |||
| 71CC | JR NZ,HandlerEggCollision_Destroy02 | |||
|
Stun the second frog and award points.
|
||||
| 71CE | LD A,R | A=the contents of the Memory Refresh Register. | ||
| 71D0 | OR %00011111 | Set bits 0-4 (ensure minimum stun duration). | ||
| 71D2 | AND %01111111 | Clear bit 7 (cap the maximum duration). | ||
| 71D4 | LD (HL),A | Write the stun duration to the second frogs stun countdown. | ||
| 71D5 | LD A,$0A | Call AddToScore to add 0A points to the score. | ||
| 71D7 | CALL AddToScore | |||
| HandlerEggCollision_Destroy02 | 71DA | CALL CancelEggDrop | Call CancelEggDrop. | |
| 71DD | CALL PlayHitSound | Call PlayHitSound. | ||
| 71E0 | RET | Return. | ||
| Prev: 70DB | Up: Map | Next: 71E1 |