From ce08786ddf173e6e308412bf3f5398abc4e061de Mon Sep 17 00:00:00 2001 From: Rachel Date: Sun, 19 May 2024 23:02:48 -0700 Subject: [PATCH] Clean up build logic and file structure --- include/overlay113/FootprintSizeData.h | 10 ---------- include/overlay113/footprint_data.h | 11 +++++++++++ res/pokemon/meson.build | 7 +++++-- src/overlay113/ov113_02260620.c | 2 +- tools/scripts/make_species_tables.py | 4 ++-- 5 files changed, 19 insertions(+), 15 deletions(-) delete mode 100644 include/overlay113/FootprintSizeData.h create mode 100644 include/overlay113/footprint_data.h diff --git a/include/overlay113/FootprintSizeData.h b/include/overlay113/FootprintSizeData.h deleted file mode 100644 index 1555fb0c62..0000000000 --- a/include/overlay113/FootprintSizeData.h +++ /dev/null @@ -1,10 +0,0 @@ -#ifndef POKEPLATINUM_FOOTPRINTSIZEDATA_H -#define POKEPLATINUM_FOOTPRINTSIZEDATA_H - -typedef struct FootprintSizeData { - u8 hasFootprint; - u8 footprintSize; - u16 unk_02; -} FootprintSizeData; - -#endif // POKEPLATINUM_FOOTPRINTSIZEDATA_H diff --git a/include/overlay113/footprint_data.h b/include/overlay113/footprint_data.h new file mode 100644 index 0000000000..006f576235 --- /dev/null +++ b/include/overlay113/footprint_data.h @@ -0,0 +1,11 @@ +#ifndef POKEPLATINUM_FOOTPRINT_DATA_H +#define POKEPLATINUM_FOOTPRINT_DATA_H + +typedef struct FootprintData { + u8 hasFootprint; + u8 footprintSize; + u16 unk_02; +} FootprintData; + +#endif // POKEPLATINUM_FOOTPRINT_DATA_H + diff --git a/res/pokemon/meson.build b/res/pokemon/meson.build index f7c7b79202..815332f503 100644 --- a/res/pokemon/meson.build +++ b/res/pokemon/meson.build @@ -773,8 +773,11 @@ pl_growtbl_narc = custom_target('pl_growtbl.narc', species_header_target = meson.current_build_dir() -gen_species_headers = custom_target('auto-generated species headers', - output: 'gen_species_headers', +gen_species_headers = custom_target('gen_species_headers', + output: [ + 'tutor_movesets.h', + 'footprint_data.h', + ], input: personal_files, env: json2bin_env, depends: [ py_consts_generators ], diff --git a/src/overlay113/ov113_02260620.c b/src/overlay113/ov113_02260620.c index 488bc5737d..ac3bc557e7 100644 --- a/src/overlay113/ov113_02260620.c +++ b/src/overlay113/ov113_02260620.c @@ -11,7 +11,7 @@ #include "touch_screen.h" #include "struct_defs/struct_0205AA50.h" #include "overlay113/struct_ov113_02260818.h" -#include "overlay113/FootprintSizeData.h" +#include "overlay113/footprint_data.h" #include "message.h" #include "constants/species.h" diff --git a/tools/scripts/make_species_tables.py b/tools/scripts/make_species_tables.py index 24acbec150..fd5d0991c3 100644 --- a/tools/scripts/make_species_tables.py +++ b/tools/scripts/make_species_tables.py @@ -140,10 +140,10 @@ with open(output_path, "w") as output_file: output_file.writelines(generated_disclaimer) output_file.write("#ifndef POKEPLATINUM_GENERATED_FOOTPRINT_DATA_H\n") output_file.write("#define POKEPLATINUM_GENERATED_FOOTPRINT_DATA_H\n") - output_file.write("#include \"overlay113/FootprintSizeData.h\"\n") + output_file.write("#include \"overlay113/footprint_data.h\"\n") output_file.write("#include \"constants/species.h\"\n") output_file.write("\n") - output_file.write("static const FootprintSizeData sSpeciesFootprintData[NATIONAL_DEX_COUNT + 1] = {\n") + output_file.write("static const FootprintData sSpeciesFootprintData[NATIONAL_DEX_COUNT + 1] = {\n") sorted_array = sorted(species_footprints.items())