diff options
Diffstat (limited to 'asm/macros')
-rw-r--r-- | asm/macros/map.s | 15 | ||||
-rw-r--r-- | asm/macros/pokemon_data.s | 17 |
2 files changed, 30 insertions, 2 deletions
diff --git a/asm/macros/map.s b/asm/macros/map.s new file mode 100644 index 000000000..452f9b714 --- /dev/null +++ b/asm/macros/map.s @@ -0,0 +1,15 @@ + .macro new_map_group + .set cur_map_group, cur_map_group + 1 + .set cur_map_num, 0 + .endm + + .macro map_group map_name + .set GROUP_\map_name, cur_map_group + .set MAP_\map_name, cur_map_num + .set cur_map_num, cur_map_num + 1 + .endm + + .macro map map_name + .byte GROUP_\map_name + .byte MAP_\map_name + .endm diff --git a/asm/macros/pokemon_data.s b/asm/macros/pokemon_data.s index 712044f61..bbdd07043 100644 --- a/asm/macros/pokemon_data.s +++ b/asm/macros/pokemon_data.s @@ -28,10 +28,10 @@ .2byte (\level << 9) | \move .endm - .macro evo_entry method, parameter, target_pokemon + .macro evo_entry method, parameter, target_species .2byte \method .2byte \parameter - .2byte \target_pokemon + .2byte \target_species .2byte 0 ; padding .endm @@ -42,3 +42,16 @@ .macro egg_moves_begin species .2byte 20000 + \species .endm + +; If the min level equals the max level, only one level argument is needed. + .macro wild_mon species, min_level, max_level + .byte \min_level + + .ifb \max_level + .byte \min_level + .else + .byte \max_level + .endif + + .2byte SPECIES_\species + .endm |