From e322573ecc55a821506e5313e3b9994e1b58745e Mon Sep 17 00:00:00 2001 From: Astatin Date: Fri, 2 May 2025 11:47:47 +0200 Subject: Fix laser not taking a turn to turn when jumped over --- enemiesattacks/laser.gbasm | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) (limited to 'enemiesattacks/laser.gbasm') diff --git a/enemiesattacks/laser.gbasm b/enemiesattacks/laser.gbasm index 9e2f67d..648c5f7 100644 --- a/enemiesattacks/laser.gbasm +++ b/enemiesattacks/laser.gbasm @@ -1,4 +1,4 @@ -Laser_sight_check: ; BC = XY of the enemy. D is unchanged. Direction to face in E (or 0 if not) +Laser_sight_check: ; BC = XY of the enemy. D = direction (must be unchanged). Direction to face in E (or 0 if not) LD E, $00 ; straight line + distance <= 4 @@ -49,22 +49,6 @@ Laser_sight_check: ; BC = XY of the enemy. D is unchanged. Direction to face in RET Laser_Enemy_Attack: ; Direction to face in E. Result in BC (XY), Direction in D - LD A, E - DEC A - DEC D - XOR D - INC D - CP $00 - JR Z, =.attack - BIT 1, A - JR NZ, =.attack - - LD A, E - OR $00 - LD D, A - RET - - .attack: PUSH DE PUSH BC -- cgit v1.2.3-70-g09d2