pub enum EffectSite {
Objective {
quest: String,
objective: String,
},
QuestComplete {
quest: String,
},
Trigger {
trigger: String,
},
Trap {
trap: String,
},
DialogueRespawn {
npc: String,
node: String,
},
ShortcutUnlock {
shortcut: String,
},
ShopOffer {
shop: String,
offer: usize,
},
OnDeath,
OnKill {
fight: String,
},
AssemblyLand {
assembly: String,
step: usize,
},
LoopCross {
loop: String,
},
}Expand description
Where in the campaign one effect sits — the attribution every per-branch proof and the branch chronicle need (spec-0025).
Variants§
Objective
A quest’s on_objective_complete[<objective>] bundle.
Fields
QuestComplete
A quest’s on_complete bundle.
Trigger
An environment trigger’s effects bundle — ambient, no DAG position.
Trap
A trap’s spec-0022 payload bundle — ambient, no DAG position.
DialogueRespawn
A dialogue option’s set-checkpoint on_respawn bundle — ambient, no
DAG position, and the only site that does not live in the quests stage.
This variant did not exist until the effect-root sweep, and its absence was
load-bearing: EffectSite had no way to represent a dialogue-hosted
bundle, so the four proofs that walk for_each_campaign_effect
(combat::actor_beats, wave::difficulty_checks,
daylight::fightable_actor, nav::actor_fights) could not have seen root 5
even if their authors had thought of it. Widening the type is what let the
walk widen.
Fields
ShortcutUnlock
A shortcuts[].on_unlock bundle (spec-0016 §2) — ambient, no DAG
position, and the sixth root: representable here only since spec-0031, for
exactly the reason EffectSite::DialogueRespawn records above.
ShopOffer
A shops[].offers[].effects bundle (DSL v0.10, spec-0032) — ambient, no
DAG position: nobody is forced to buy anything.
Fields
OnDeath
The campaign’s on_death bundle (spec-0031) — ambient, no DAG position,
and no owning object: there is one per campaign.
OnKill
A wave’s or an actor’s on_kill bundle (spec-0074) — ambient, no DAG
position: nobody is forced to be credited with a kill.
AssemblyLand
An assembly strike step’s on_land bundle (spec-0082) — ambient, no
DAG position: nobody is forced to stand where a blow lands.
LoopCross
A loop’s on_cross bundle (spec-0086) — no DAG position of its own: it
runs when a body crosses the holding slab.
Implementations§
Source§impl EffectSite
impl EffectSite
Sourcepub fn quest(&self) -> Option<&str>
pub fn quest(&self) -> Option<&str>
The quest this site belongs to, if it has a DAG position at all.
This Option is the capability, and it is on the enum rather than on the
variants that happen to have a quest. Only two of the eight sites name a
quest, because only two of the eight roots HAVE a DAG position: an ambient
root — a trigger, a trap payload, a dialogue on_respawn, a shortcut’s
on_unlock, the campaign’s on_death, a shop offer — fires at a moment no
static model can order, and inventing a quest for one would be exactly the
over-attribution the completability model must not make. Asking the question
of every variant and getting an honest None is the lift;
tools/ci/check-capability-ownership.py check D asked for it while the field
was still cross-cutting, and spec-0032’s eighth site took it below that
threshold, so the reasoning lives here now rather than in an exemption.