From 482b251a26c6701e77ddcc167b78e7986fb0a25e Mon Sep 17 00:00:00 2001 From: Star Rauchenberger Date: Sun, 10 Aug 2025 09:03:23 -0400 Subject: Assigned IDs for the_colorful Also fixed bug where the ID assigner didn't read letter and mastery IDs and would thus reuse them. I reassigned all IDs because of this (since we don't need to worry about ID stability yet). --- tools/assign_ids/main.cpp | 12 ++++++++++++ tools/datapacker/main.cpp | 9 +++++++++ 2 files changed, 21 insertions(+) (limited to 'tools') diff --git a/tools/assign_ids/main.cpp b/tools/assign_ids/main.cpp index eba4fd6..349c258 100644 --- a/tools/assign_ids/main.cpp +++ b/tools/assign_ids/main.cpp @@ -61,6 +61,12 @@ class AssignIds { next_id_ = id; } } + + for (const auto& [_, id] : room.masteries()) { + if (id > next_id_) { + next_id_ = id; + } + } } } @@ -70,6 +76,12 @@ class AssignIds { } } + for (const auto& [_, id] : id_mappings_.letters()) { + if (id > next_id_) { + next_id_ = id; + } + } + next_id_++; } diff --git a/tools/datapacker/main.cpp b/tools/datapacker/main.cpp index 2ad97b0..260ab62 100644 --- a/tools/datapacker/main.cpp +++ b/tools/datapacker/main.cpp @@ -139,6 +139,15 @@ class DataPacker { map_name, h_panel.required_door().name(), current_map_name)); } + if (h_panel.has_required_room()) { + std::optional map_name = + h_panel.required_room().has_map() + ? std::optional(h_panel.required_room().map()) + : std::nullopt; + panel.set_required_room(container_.FindOrAddRoom( + map_name, h_panel.required_room().name(), current_map_name)); + } + return panel_id; } -- cgit 1.4.1