Skip to main content

Module validate

Module validate 

Source
Expand description

Campaign validation: all six rule groups from spec-0001.

validate_campaign uses the vendored v0 registries; the compiler injects full registries via validate_campaign_with.

Functions§

declares_bonfire
Does the campaign declare a bonfire — a rest point that re-seats fights (spec-0016 §1)? Read at the roots the compiler collects rest points from: a quest’s bundles and an environment trigger’s effects, at any nesting depth. The match over the site is exhaustive, so a new root answers here. DW0370 asks it, and so does the compiler’s fight_comes_back where no plan exists yet (DW0914/DW0915).
declares_checkpoint
Does the campaign declare any checkpoint a fallen player respawns at — a set-checkpoint or a bonfire — at a root the compiler collects checkpoints from: the roots declares_bonfire reads, plus a dialogue option’s set-checkpoint. The reading DW0925 needs.
produced_flags
The one inventory of flags this campaign produces.
validate_campaign
Validate a campaign against all spec-0001 rules using the vendored v0 registries (subset item + entity registries + hello-world anchor metadata).
validate_campaign_with
Validate a campaign with caller-supplied registries. The entities registry (DSL v0.3) validates stage-5 wave mobs; the compiler injects the full 1.21.11 item/entity registries and real prefab metadata.