From 01d994b8a30df12c0353bc912bcb046edf6a61b6 Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Tue, 2 Jan 2018 18:06:56 -0500 Subject: dsprite always has 6 arguments --- macros/data.asm | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'macros/data.asm') diff --git a/macros/data.asm b/macros/data.asm index 55f41a204..d01abb8ea 100644 --- a/macros/data.asm +++ b/macros/data.asm @@ -85,20 +85,17 @@ ENDM dbpixel: MACRO if _NARG >= 4 +; x tile, x pxl, y tile, y pxl db \1 * 8 + \3, \2 * 8 + \4 else +; x, y db \1 * 8, \2 * 8 endc ENDM dsprite: MACRO -; conditional segment is there because not every instance of -; this macro is directly OAM -if _NARG >= 7 ; y tile, y pxl, x tile, x pxl, vtile offset, flags, palette - db (\1 * 8) % $100 + \2, (\3 * 8) % $100 + \4, \5, (\6 << 3) + (\7 & PALETTE_MASK) -else +; y tile, y pxl, x tile, x pxl, vtile offset, flags, attributes db (\1 * 8) % $100 + \2, (\3 * 8) % $100 + \4, \5, \6 -endc ENDM -- cgit v1.2.3 From 2ab60fa8a49dfe9e20ebb620471ba4c2ca64a4aa Mon Sep 17 00:00:00 2001 From: Remy Oukaour Date: Sat, 13 Jan 2018 16:38:14 -0500 Subject: menu_coords macro for (x1, y1, x2, y2) order (see issue #440) --- macros/data.asm | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'macros/data.asm') diff --git a/macros/data.asm b/macros/data.asm index d01abb8ea..8345a2523 100644 --- a/macros/data.asm +++ b/macros/data.asm @@ -99,6 +99,13 @@ dsprite: MACRO ENDM +menu_coords: MACRO +; x1, y1, x2, y2 + db \2, \1 ; start coords + db \4, \3 ; end coords +ENDM + + sine_wave: MACRO ; \1: amplitude x = 0 -- cgit v1.2.3