mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-10 02:53:51 +00:00
refactor(editor): extract zone-data maintenance into cli_zone_data.cpp
Moves three derived-data maintenance handlers (--fix-zone,
--regen-collision, --build-woc) out of main.cpp into a new
cli_zone_data.{hpp,cpp} module. Distinct from cli_repair
(which fixes manifest-vs-disk drift): these rebuild derived
terrain data and clean up JSON files via load+save:
- fix-zone re-parses + re-saves every JSON sidecar to apply
load-time scrubs and save-time caps
- regen-collision rebuilds WOC for every WHM/WOT in a zone
- build-woc handles single-tile WOC generation
main.cpp shrinks by 104 lines (1,541 to 1,437).
This commit is contained in:
parent
288c4e93b6
commit
fca17592b1
4 changed files with 181 additions and 108 deletions
21
tools/editor/cli_zone_data.hpp
Normal file
21
tools/editor/cli_zone_data.hpp
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
#pragma once
|
||||
|
||||
namespace wowee {
|
||||
namespace editor {
|
||||
namespace cli {
|
||||
|
||||
// Dispatch the zone-data maintenance handlers — re-derive
|
||||
// stored data files (collision, JSON sidecars) from sources
|
||||
// after authoring changes. Distinct from cli_repair (which
|
||||
// fixes manifest-vs-disk drift): these rebuild derived
|
||||
// terrain data and clean up JSON files via load+save.
|
||||
// --fix-zone re-parse + re-save every zone JSON to apply scrubs
|
||||
// --regen-collision rebuild WOC for every WHM/WOT in a zone
|
||||
// --build-woc single-tile WOC build from a WHM/WOT base
|
||||
//
|
||||
// Returns true if matched; outRc holds the exit code.
|
||||
bool handleZoneData(int& i, int argc, char** argv, int& outRc);
|
||||
|
||||
} // namespace cli
|
||||
} // namespace editor
|
||||
} // namespace wowee
|
||||
Loading…
Add table
Add a link
Reference in a new issue