Prev: A713 Up: Map Next: A739
A727: Explode Enemies
Used by the routines at UseEnergy and MoveRobotHorizontally.
Turns every enemy that is in use into smoke.
ExplodeEnemies A727 LD HL,$96D0 Point HL at the first enemy.
A72A LD DE,$0010 Each entity is 10 bytes long.
A72D LD B,$0A There are ten enemies.
ExplodeEnemies_Next A72F LD A,(HL) Fetch the type of the enemy.
A730 AND A Jump if the enemy is not in use.
A731 JR Z,ExplodeEnemies_Skip
A733 LD (HL),$38 Otherwise turn it into smoke.
ExplodeEnemies_Skip A735 ADD HL,DE Move on to the next enemy.
A736 DJNZ ExplodeEnemies_Next Loop back until every enemy has been dealt with.
A738 RET Return.
Prev: A713 Up: Map Next: A739