mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-08 10:03:51 +00:00
feat(editor): --audit-project also runs items schema + spawn placement
Extended the composite project audit from 4 sub-checks to 6, adding the two new gates: - validate-project-items (items.json schema across zones) - audit-project-spawns (spawn Z within 5y of terrain) Sub-checks now ordered cheapest → most expensive so a fast failure surfaces before the slow ones run: format validation runs in milliseconds, but spawn-placement audit requires loading every WHM tile and casting rays. Single-command release-readiness gate: a green --audit-project now means format-clean + open-only + items-clean + refs-resolve + content-sane + spawns-grounded.
This commit is contained in:
parent
fb4421e5df
commit
7a43e4eb3b
1 changed files with 12 additions and 7 deletions
|
|
@ -8674,11 +8674,14 @@ int main(int argc, char* argv[]) {
|
|||
// overall result. Designed to be the only command CI needs
|
||||
// to run before --pack-wcp.
|
||||
//
|
||||
// Sub-checks:
|
||||
// Sub-checks (ordered cheapest→most expensive so a fast
|
||||
// failure surfaces before the slow ones run):
|
||||
// 1. validate-project (per-format integrity)
|
||||
// 2. validate-project-open-only (no proprietary leaks)
|
||||
// 3. check-project-refs (every model/NPC ref resolves)
|
||||
// 4. check-project-content (sane field values)
|
||||
// 3. validate-project-items (items.json schema)
|
||||
// 4. check-project-refs (every model/NPC ref resolves)
|
||||
// 5. check-project-content (sane field values)
|
||||
// 6. audit-project-spawns (spawn Z near terrain)
|
||||
std::string projectDir = argv[++i];
|
||||
namespace fs = std::filesystem;
|
||||
if (!fs::exists(projectDir) || !fs::is_directory(projectDir)) {
|
||||
|
|
@ -8705,10 +8708,12 @@ int main(int argc, char* argv[]) {
|
|||
};
|
||||
struct Step { const char* name; const char* flag; int rc; };
|
||||
std::vector<Step> steps = {
|
||||
{"format validation ", "--validate-project", 0},
|
||||
{"open-only release gate ", "--validate-project-open-only", 0},
|
||||
{"reference integrity ", "--check-project-refs", 0},
|
||||
{"content field sanity ", "--check-project-content", 0},
|
||||
{"format validation ", "--validate-project", 0},
|
||||
{"open-only release gate ", "--validate-project-open-only", 0},
|
||||
{"items schema ", "--validate-project-items", 0},
|
||||
{"reference integrity ", "--check-project-refs", 0},
|
||||
{"content field sanity ", "--check-project-content", 0},
|
||||
{"spawn placement ", "--audit-project-spawns", 0},
|
||||
};
|
||||
int totalFailed = 0;
|
||||
std::printf("audit-project: %s\n\n", projectDir.c_str());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue