diff options
author | Deokishisu <6993375+Deokishisu@users.noreply.github.com> | 2021-02-09 11:20:52 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-09 11:20:52 -0500 |
commit | 60b9b0add2aa446fb058e26fdf7d615887cf2e42 (patch) | |
tree | 43441de8378dc3b6092bdaf05b4c966d3cc4a4a9 /src | |
parent | efba18bb0bc1e919b13d1b6421011f94b409e33f (diff) |
Fix Trainer Tower Magic Number
A magic number was missed that will lead to edited projects breaking the Trainer Tower if new map layouts are added. This commit fixes it.
Diffstat (limited to 'src')
-rw-r--r-- | src/trainer_tower.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/trainer_tower.c b/src/trainer_tower.c index 36468a34d..fd10e33b2 100644 --- a/src/trainer_tower.c +++ b/src/trainer_tower.c @@ -508,7 +508,7 @@ static void SetUpTrainerTowerDataStruct(void) // fakematching const struct TrainerTowerFloor *const * r7; sTrainerTowerState = AllocZeroed(sizeof(*sTrainerTowerState)); - sTrainerTowerState->floorIdx = gMapHeader.mapLayoutId - 42; + sTrainerTowerState->floorIdx = gMapHeader.mapLayoutId - LAYOUT_TRAINER_TOWER_1F; if (ReadTrainerTowerAndValidate() == TRUE) CEReaderTool_LoadTrainerTower(&sTrainerTowerState->unk_0004); else |