aboutsummaryrefslogtreecommitdiffstats
path: root/macros
diff options
context:
space:
mode:
authordannye <33dannye@gmail.com>2024-05-05 11:06:40 -0500
committerdannye <33dannye@gmail.com>2024-05-05 11:06:40 -0500
commitb135272f9510ed78e8c062efe552d6dbdcc1523f (patch)
tree5dc1941a3b42651f268dbb90f6e3170ccd977408 /macros
parentRemove pcm.py since pcm.c handles it (diff)
parentUse constant in wram for hidden item flags (#445) (diff)
downloadpokeyellow-b135272f9510ed78e8c062efe552d6dbdcc1523f.tar.gz
pokeyellow-b135272f9510ed78e8c062efe552d6dbdcc1523f.tar.xz
pokeyellow-b135272f9510ed78e8c062efe552d6dbdcc1523f.zip
Merge branch 'master' of https://github.com/pret/pokered
Diffstat (limited to 'macros')
-rw-r--r--macros/asserts.asm6
-rw-r--r--macros/ram.asm4
2 files changed, 8 insertions, 2 deletions
diff --git a/macros/asserts.asm b/macros/asserts.asm
index 64e6bc7b..bc5b2582 100644
--- a/macros/asserts.asm
+++ b/macros/asserts.asm
@@ -16,6 +16,12 @@ MACRO assert_table_length
"{CURRENT_TABLE_START}: expected {d:x} entries, each {d:CURRENT_TABLE_WIDTH} bytes"
ENDM
+MACRO assert_max_table_length
+ DEF x = \1
+ ASSERT x * CURRENT_TABLE_WIDTH >= @ - {CURRENT_TABLE_START}, \
+ "{CURRENT_TABLE_START}: expected a maximum of {d:x} entries, each {d:CURRENT_TABLE_WIDTH} bytes"
+ENDM
+
MACRO list_start
DEF list_index = 0
IF _NARG == 1
diff --git a/macros/ram.asm b/macros/ram.asm
index f45708a3..58704807 100644
--- a/macros/ram.asm
+++ b/macros/ram.asm
@@ -23,7 +23,7 @@ MACRO box_struct
\1DefenseExp:: dw
\1SpeedExp:: dw
\1SpecialExp:: dw
-\1DVs:: ds 2
+\1DVs:: dw
\1PP:: ds NUM_MOVES
ENDM
@@ -49,7 +49,7 @@ MACRO battle_struct
\1Type2:: db
\1CatchRate:: db
\1Moves:: ds NUM_MOVES
-\1DVs:: ds 2
+\1DVs:: dw
\1Level:: db
\1Stats::
\1MaxHP:: dw