aboutsummaryrefslogtreecommitdiff
path: root/entity/bunny.gbasm
diff options
context:
space:
mode:
authorAstatin <[email protected]>2024-11-05 19:42:46 +0900
committerAstatin <[email protected]>2024-11-05 19:42:46 +0900
commit6c8f7c72cb96ce59ffcda5279225381ecb394b4f (patch)
tree941e6b464bd0fe90b325ae792b3a6fdbdc9b40fe /entity/bunny.gbasm
parent14ae7d8def1159b395bf1176b351651cbd98ba19 (diff)
Add a jump table macro
Diffstat (limited to 'entity/bunny.gbasm')
-rw-r--r--entity/bunny.gbasm23
1 files changed, 3 insertions, 20 deletions
diff --git a/entity/bunny.gbasm b/entity/bunny.gbasm
index f180e9e..4e27929 100644
--- a/entity/bunny.gbasm
+++ b/entity/bunny.gbasm
@@ -169,28 +169,11 @@ Move_Bunny:
PUSH HL
PUSH BC
- LD E, (HL)
- LD D, $00
-
- SLA E
- RL D
- SLA E
- RL D
-
LD BC, =Interaction_Jump_table
- LD A, E
- ADD C
- LD E, A
- LD A, D
- ADC B
- LD D, A
-
- LD BC, =Interaction.interaction_end
- PUSH BC
- PUSH DE
- RET
+ LD A, (HL)
+
+ .JUMP_TABLE
- Interaction.interaction_end:
POP BC
POP HL