Clean up some macro definitions

This commit is contained in:
Rangi
2021-03-21 20:09:34 -04:00
parent 90ce126139
commit 5037adc55f
3 changed files with 16 additions and 14 deletions

View File

@@ -50,8 +50,8 @@ FIRST_MUSIC_CMD EQU const_value
const octave_cmd ; $d0
octave: MACRO
assert 0 < (\1) && (\1) < 8, "octave must be 1-8"
db octave_cmd | 8 - (\1) ; octave
assert 1 <= (\1) && (\1) <= 8, "octave must be 1-8"
db octave_cmd + 8 - (\1) ; octave
ENDM
const_skip 7 ; all octave values

View File

@@ -1,12 +1,12 @@
anim_wait: MACRO
assert (\1) < $d0, "anim_wait argument must be less than $d0"
db \1
ENDM
; BattleAnimCommands indexes (see engine/battle_anims/anim_commands.asm)
const_def $d0
FIRST_BATTLE_ANIM_CMD EQU const_value
anim_wait: MACRO
assert (\1) < FIRST_BATTLE_ANIM_CMD, "anim_wait argument must be less than {FIRST_BATTLE_ANIM_CMD}"
db \1
ENDM
const anim_obj_command ; $d0
anim_obj: MACRO
db anim_obj_command