From ef1f9ead0ba44c67185dccc616846646d7ce9257 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Thu, 23 Jan 2020 14:46:03 -0500 Subject: Document Trainer Tower scripts --- include/cereader_tool.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'include/cereader_tool.h') diff --git a/include/cereader_tool.h b/include/cereader_tool.h index 6275eaabf..db1dd04fa 100644 --- a/include/cereader_tool.h +++ b/include/cereader_tool.h @@ -2,6 +2,7 @@ #define GUARD_CEREADER_TOOL_H #include "global.h" +#include "constants/trainer_tower.h" struct TrainerTowerTrainer { @@ -21,13 +22,13 @@ struct TrainerTowerFloor /* 0x001 */ u8 floorIdx; /* 0x002 */ u8 challengeType; /* 0x003 */ u8 prize; - /* 0x004 */ struct TrainerTowerTrainer trainers[3]; + /* 0x004 */ struct TrainerTowerTrainer trainers[MAX_TRAINERS_PER_FLOOR]; /* 0x3DC */ u32 checksum; }; struct EReaderTrainerHillSetSubstruct { - u8 count; + u8 numFloors; u8 id; u16 dummy; u32 checksum; @@ -35,11 +36,11 @@ struct EReaderTrainerHillSetSubstruct struct EReaderTrainerHillSet { - u8 count; + u8 numFloors; u8 id; u16 dummy; u32 checksum; - struct TrainerTowerFloor floors[8]; + struct TrainerTowerFloor floors[MAX_TRAINER_TOWER_FLOORS]; }; bool32 ValidateTrainerTowerData(struct EReaderTrainerHillSet * ttdata); -- cgit v1.2.3 From 5106fc1c9a503ba3856267ecaf16d9f6393e5072 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Sun, 26 Jan 2020 16:50:32 -0500 Subject: Move ReadTrainerTowerAndValidate --- include/cereader_tool.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/cereader_tool.h') diff --git a/include/cereader_tool.h b/include/cereader_tool.h index db1dd04fa..c3eadfe81 100644 --- a/include/cereader_tool.h +++ b/include/cereader_tool.h @@ -47,5 +47,6 @@ bool32 ValidateTrainerTowerData(struct EReaderTrainerHillSet * ttdata); bool32 CEReaderTool_SaveTrainerTower(struct EReaderTrainerHillSet * ttdata); bool32 CEReaderTool_LoadTrainerTower(struct EReaderTrainerHillSet * ttdata); u8 sub_815D654(void); +bool32 ReadTrainerTowerAndValidate(void); #endif //GUARD_CEREADER_TOOL_H -- cgit v1.2.3 From 017fa7e3361e3dafd06dd34d434f1d56159c051e Mon Sep 17 00:00:00 2001 From: GriffinR Date: Sun, 26 Jan 2020 18:34:06 -0500 Subject: Trainer Hill --> Trainer Tower --- include/cereader_tool.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'include/cereader_tool.h') diff --git a/include/cereader_tool.h b/include/cereader_tool.h index c3eadfe81..dd1866fb3 100644 --- a/include/cereader_tool.h +++ b/include/cereader_tool.h @@ -26,7 +26,7 @@ struct TrainerTowerFloor /* 0x3DC */ u32 checksum; }; -struct EReaderTrainerHillSetSubstruct +struct EReaderTrainerTowerSetSubstruct { u8 numFloors; u8 id; @@ -34,7 +34,7 @@ struct EReaderTrainerHillSetSubstruct u32 checksum; }; -struct EReaderTrainerHillSet +struct EReaderTrainerTowerSet { u8 numFloors; u8 id; @@ -43,9 +43,9 @@ struct EReaderTrainerHillSet struct TrainerTowerFloor floors[MAX_TRAINER_TOWER_FLOORS]; }; -bool32 ValidateTrainerTowerData(struct EReaderTrainerHillSet * ttdata); -bool32 CEReaderTool_SaveTrainerTower(struct EReaderTrainerHillSet * ttdata); -bool32 CEReaderTool_LoadTrainerTower(struct EReaderTrainerHillSet * ttdata); +bool32 ValidateTrainerTowerData(struct EReaderTrainerTowerSet * ttdata); +bool32 CEReaderTool_SaveTrainerTower(struct EReaderTrainerTowerSet * ttdata); +bool32 CEReaderTool_LoadTrainerTower(struct EReaderTrainerTowerSet * ttdata); u8 sub_815D654(void); bool32 ReadTrainerTowerAndValidate(void); -- cgit v1.2.3