summaryrefslogtreecommitdiff
path: root/engine/items
diff options
context:
space:
mode:
authorRangi <remy.oukaour+rangi42@gmail.com>2021-03-25 16:33:05 -0400
committerRangi <remy.oukaour+rangi42@gmail.com>2021-03-25 16:44:41 -0400
commit95ec2cf039f0efdc6dadfb6fe766ace231a1b6b1 (patch)
tree5a7b79846bd7f07e40310da46b21873774a08ef7 /engine/items
parente1f6bb53939be34f55e05cbbd19cd758936b3422 (diff)
Verify data table and name list sizes with assertion macros
Fixes #312
Diffstat (limited to 'engine/items')
-rw-r--r--engine/items/item_effects.asm11
1 files changed, 3 insertions, 8 deletions
diff --git a/engine/items/item_effects.asm b/engine/items/item_effects.asm
index 804a316d..0448866e 100644
--- a/engine/items/item_effects.asm
+++ b/engine/items/item_effects.asm
@@ -1292,7 +1292,7 @@ ItemUseMedicine:
ld [hl], a
pop hl
call .recalculateStats
- ld hl, VitaminText
+ ld hl, VitaminStats
ld a, [wcf91]
sub HP_UP - 1
ld c, a
@@ -1425,12 +1425,7 @@ VitaminNoEffectText:
text_far _VitaminNoEffectText
text_end
-VitaminText:
- db "HEALTH@"
- db "ATTACK@"
- db "DEFENSE@"
- db "SPEED@"
- db "SPECIAL@"
+INCLUDE "data/battle/stat_names.asm"
ItemUseBait:
ld hl, ThrewBaitText
@@ -2490,7 +2485,7 @@ GetMaxPP:
dec a
push hl
ld hl, Moves
- ld bc, MoveEnd - Moves
+ ld bc, MOVE_LENGTH
call AddNTimes
ld de, wcd6d
ld a, BANK(Moves)