summaryrefslogtreecommitdiff
path: root/macros.asm
diff options
context:
space:
mode:
authoryenatch <yenatch@gmail.com>2015-10-13 19:23:12 -0400
committeryenatch <yenatch@gmail.com>2015-10-13 19:23:12 -0400
commitd5f94e9ee5a2f5ec8fb26c29d74c02531fc79c5a (patch)
tree003a0d9a296095020d110e3cdc6b2127a3e20e38 /macros.asm
parent7176eff7aafda5378305a593c459d158ac27601f (diff)
parentd338a092c5a54d73e3e0a186569cc3b84e61c4ae (diff)
Merge pull request #320 from PikalaxALT/master
More labels, including fns responsible for partymon generation
Diffstat (limited to 'macros.asm')
-rw-r--r--macros.asm26
1 files changed, 26 insertions, 0 deletions
diff --git a/macros.asm b/macros.asm
index 4370886b2..e366ad498 100644
--- a/macros.asm
+++ b/macros.asm
@@ -149,3 +149,29 @@ bcd: MACRO
shift
endr
ENDM
+
+ln: MACRO
+ if _NARG == 5
+ lb \1, \2 << 4 + \3, \4 << 4 + \5
+ else
+ if _NARG == 3
+ ld \1, \2 << 4 + \3
+ else
+ fail "incorrect number of arguments for ln"
+ endc
+ endc
+ENDM
+
+dwtile: MACRO
+ dw (\1 << 4) + \2
+ if _NARG > 2
+ rept _NARG + -2
+ dw \3
+ shift
+ endr
+ endc
+ENDM
+
+ldtile: MACRO
+ ld \1, (\2 << 4) + \3
+ENDM