[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6JZX5BKVHNNSDPH58T2B7Z7":3,"skill-same:01M6JZX5BKVHNNSDPH58T2B7Z7":68},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":39,"linkOnly":40,"markdownContent":41,"markdownBody":42,"frontMatter":43,"refName":45,"commitSha":46,"skillDirectory":47,"forksCount":48,"repositoryHtmlUrl":49,"repositoryHomepageUrl":6,"ownerHtmlUrl":50,"ownerBlogUrl":51,"ownerDescription":52,"updatedAt":53,"install":54,"resources":67},"01M6JZX5BKVHNNSDPH58T2B7Z7","audit-scripting",null,"Deep audit of the M30\u002FM47 scripting runtime — AST→ECS recognizer chain (decline-on-unmodeled), the M47.2 Papyrus VM that runs what the lowering declines (budget, reference\u002Falias scripts, update\u002Fevent registrations), fragment\u002Fquest-stage dispatch, ECS event\u002Ftimer\u002Fcondition\u002Ftrigger systems, cell-loader script attach, scene\u002Fpackage\u002Fcinematic playback, legacy ObScript quest execution (M47.3), extender-compat provider layer. Compiler frontends (.pex decompiler, .psc parser) are \u002Faudit-papyrus","matiaszanolli\u002FByroRedux","matiaszanolli","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F2379093?v=4","01M6JZJDYMPY01793W4XK157YG","Matias Zanolli","01M6JZJE2KE2BXSDPAYPQC6BSH",40,"MIT","https:\u002F\u002Fgithub.com\u002Fmatiaszanolli\u002FByroRedux\u002Fblob\u002Fmain\u002F.claude\u002Fcommands\u002Faudit-scripting\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],"audit scripting","audit","scripting","what the","ecs","condition","quest","chain","systems","cell","deep","dimensions","update","attach","provider","reference","timer","dispatch","Budget","vm","2026-11-10 10:12:30",false,"---\ndescription: \"Deep audit of the M30\u002FM47 scripting runtime — AST→ECS recognizer chain (decline-on-unmodeled), the M47.2 Papyrus VM that runs what the lowering declines (budget, reference\u002Falias scripts, update\u002Fevent registrations), fragment\u002Fquest-stage dispatch, ECS event\u002Ftimer\u002Fcondition\u002Ftrigger systems, cell-loader script attach, scene\u002Fpackage\u002Fcinematic playback, legacy ObScript quest execution (M47.3), extender-compat provider layer. Compiler frontends (.pex decompiler, .psc parser) are \u002Faudit-papyrus\"\nargument-hint: \"--focus \u003Cdimensions> --depth shallow|deep\"\n---\n\n# Scripting Runtime Audit (M30 \u002F M47.0–M47.3)\n\nRead `.claude\u002Fcommands\u002F_audit-common.md` and `.claude\u002Fcommands\u002F_audit-severity.md` for shared protocol.\n\nAudit `crates\u002Fscripting\u002F` and its engine-side wiring: the AST→ECS **recognizer chain** whose load-bearing\ninvariant is *decline-on-any-unmodeled-term*, the **Papyrus VM** (`fragment\u002Fvm\u002F`, M47.2) that interprets the\nfragments \u002F reference \u002F alias scripts the lowering declines — its own contract is *check ahead of time, run whole\nor not at all* (`check_function` \u002F `check_reference_script`; a native that declines its actual values stops the\nrun, it never guesses) — fragment \u002F quest-stage dispatch, the ECS event runtime, the cell-loader attach path,\nscene\u002Fpackage\u002Fcinematic playback, and the two legacy\u002Fcompat execution layers (compiled ObScript, Papyrus\nprovider calls). **A partial or approximate lowering is worse than none**: an inert unrecognized script is safe;\na wrongly-lowered one corrupts game state with no fallback (the scripting analogue of NIFAL's no-fabrication rule).\nBoth fragment paths (lowered `Effect` list, VM `Effect::Interpret`) end in the same `apply_effects` runtime, so\nDim 2's lock rules cover both.\n\n**Split**: the `.pex` reader\u002Fdecompiler (`crates\u002Fpex`) and the `.psc` lexer\u002Fparser (`crates\u002Fpapyrus`) are\n`\u002Faudit-papyrus` (untrusted-input bounds, decompiler soundness, depth caps). `crates\u002Fhkx` parsing →\n`\u002Faudit-parsers` (this skill keeps only cinematic *playback* of decoded clips, Dim 5). `crates\u002Fsdk` →\n`\u002Faudit-tooling` (this skill keeps the provider\u002Fextension *seam*, Dim 7). AI-package procedure runtimes and\n`systems\u002Fcombat_ai.rs` → `\u002Faudit-gameplay`; scheduler\u002Flock shape in general → `\u002Faudit-ecs`,\n`\u002Faudit-concurrency`.\n\n**Architecture**: Orchestrator; each dimension is a Task agent (max 3 concurrent).\n\n## Scope\n\n`crates\u002Fscripting\u002Fsrc\u002F` (~124k LOC incl. tests; re-measure with `find crates\u002Fscripting\u002Fsrc -name '*.rs' | xargs wc -l`): `translate\u002F` (`mod`, `source`, `archetype`, `compose`, `effects`, `tables`,\n`recognizers\u002F{quest_stage_gate,rumble,two_state_activator}`); `fragment.rs` + `fragment\u002F{effects,populate,\nstate,systems}.rs` with the per-family appliers in `fragment\u002Feffects\u002F{resolve,deferred,inventory,placement,scene,lock,\nplayer_control,vehicle_cinematic,ai_combat,quest_scoped,evaluate,guards,quest_vars,actor_values,actor_lists,\nlocation_alias,reference_state,player_stats,messages}.rs` (#5468 split; #6142 `b269744f2` moved the older inline\n`apply_effect` arms into the last seven and `evaluate_guard`'s into `guards.rs`); the **Papyrus VM family**\n(M47.2): `fragment\u002Fvm\u002F` (`interp.rs` the interpreter, `checker.rs` + `natives\u002F` the `check_*` ahead-of-time checks; `vm.rs` is a ~136-LOC hub), `fragment\u002Fbudget.rs` (per-frame\nstatement budget, #5763), `fragment\u002Fdispatch.rs` (`run_papyrus_call` \u002F `flush_advances`, the one budget→defer→apply\ntail every Papyrus-call system shares, #5797 `e27c93a97`), `fragment\u002F{reference,alias_scripts,owners}.rs` (reference \u002F alias script instances and\nevent delivery), `fragment\u002F{updates,distance,events,hits,anim_events}.rs` (registration families),\n`fragment\u002F{package,perk,terminal}.rs` (PACK\u002FPERK\u002FTERM fragments); `quest_stages.rs`, `globals.rs`, `vm_state.rs`,\n`events.rs`, `cleanup.rs`, `timer.rs`, `recurring_update.rs`, `condition\u002F`, `trigger.rs`, `player_control.rs`,\n`equipment.rs`, `registry.rs`; `scene.rs` + `scene\u002F{playback,quest_alias}.rs`, `package.rs`, `dialogue.rs`\n(incl. `DialogueSurfaceState`, `DialogueQuestConditions`), `cinematic.rs`, `combat.rs`\n(`FactionRelations`, `AiCombatState`), `magic.rs` (`SpellCatalog`\u002F`SpellList`\u002F`RaceSpells`, #4415), `story_manager.rs` (#5366 SM dispatch: `SmTree`, `StoryEvent`, `story_manager_dispatch_system`), `load_order.rs`\n(`LoadOrderIdentity`, slot↔`PluginId` bridge); `animation_graph.rs` (placed-object behavior graphs); the M47.2\n**native-state stores** the VM's primitives write and conditions read — one small saved module each (CK page quoted\nin its module doc; each is a `FORMAT_MAJOR` question for `\u002Faudit-save`): `quest_variables.rs`, `location.rs`,\n`bleedout.rs`, `messages.rs`, `keywords.rs`, `relationships.rs`, `faction_changes.rs`, `alias_overrides.rs`,\n`alias_collections.rs`, `created_references.rs`, `perk_entry_points{,\u002F{bodies,catalog,gates}}.rs` (the hook catalog + gate + body split of #6654), `destruction.rs` and the sibling\n`activate_parents`\u002F`crime_*`\u002F`jail`\u002F`guards`\u002F`followers`\u002F`map_markers`\u002F`menus`\u002F`ownership`\u002F`scanning`\u002F`skills`\u002F`speechcraft`\u002F\n`*_requests`\u002F`tempering`\u002F`words_of_power` files (subsystems migrated by #5802 export their own `install(world)` + `register_saved(registry)`;\n`build_save_registry` calls each at its old row position — the schema fingerprint is order-sensitive); the M47.3 ObScript family\n`obscript{,_runtime,_vm,_quests,_results,_objects,_cmd,_actions,_actor_values,_anim,_speech,_state,_ledger,_more}.rs`\n+ `obscript_effects\u002F` (`mod.rs` the effect table + shared helpers; `getters`\u002F`inventory`\u002F`combat`\u002F`actor_state`\u002F`world_state`\u002F`presentation`, #6355 `aa29774ec`) + `obscript_more\u002F` with its sibling runtimes `magic_effects.rs`\n(caster runtime), `magic_shaders.rs`, `script_packages.rs`, `challenges.rs` (Dim 6); `registration.rs` (the crate's\n`register`, #5806 — a flat list of per-subsystem `install(world)` calls since #6706 `70e58334f`, pinned by\n`register_installs_the_same_resource_set`); `papyrus_provider\u002F`,\n`compatibility.rs`; `papyrus_demo\u002F` (reference scripts\u002Ftest fixtures; `ScriptRegistry` is the pre-Skyrim\n`SCRI`→`SCPT` extension point — boot no longer seeds it). Engine side: `byroredux\u002Fsrc\u002Fcell_loader\u002Freferences\u002F\n{attach,synth_child}.rs`, `cell_loader\u002F{spawn,exterior,unload,created,graph_nodes}.rs` + `cell_loader\u002Fexterior\u002F{persistent,apply_job}.rs` (#6271 split of the exterior hub; `created.rs` places\u002Fspawns\nCreated Object \"At\" references; `graph_nodes.rs` keeps the NiNode tree of graph-animated props), `asset_provider\u002Fscript.rs`\n(`attach_vm_reference_script`, `check_running_quest_alias_scripts`, `ProviderScriptLibrary`, `DecompiledPexCache`,\n`ensure_obscript_tables`), `scene\u002Fscene_runtime.rs` (`populate_scene_runtime` — the ObScript quest\u002Fobject\u002Fitem installs, ambient\npackages and the quest-fragment walk — and `materialize_scene_actor_alias_stubs`; both left `asset_provider\u002Fscript.rs` in #6716 `6413d542b`),\n`asset_provider\u002F{object_graph,actor_graph}.rs`,\n`systems\u002F{cinematic,npc_dialogue,forcegreet,story_events,scripted_sound,trap_hits,projectiles,archetype_idle}.rs`\n(consumers of the VM's request markers), the M43 Story Manager producers `systems\u002F{random_conversation,attraction,mines,dead_body,iron_sights}.rs` (registered in `boot\u002Fschedule\u002Fupdate\u002Fquest_scene\u002Fstory_manager.rs`) and `commands\u002Fstory_actions.rs` (their console doors) and the M47.3 ObScript request consumers\n`systems\u002F{script_requests,script_queries,revive,knockdown,flee,magic_shader,head_look}.rs`, `commands\u002Fquest.rs` (`sm.event`, `dialogue.forcegreet`), `boot\u002Fschedule\u002F` (one `register_*` file per subsystem under `update\u002F\u003Cdomain>\u002F`, `late\u002F` and `post_update\u002F`, #6703\u002F#6704 `22e0f71fc`\u002F`49aa54e36`; a cross-subsystem order the old file position stood for is a named `run_after`\u002F`run_before` constraint beside the later system, #6702 `065aac9c4`; `Access::with` lets a subsystem export its own declarations, #6701 `c22a9d410`), plus `crates\u002Fplugin\u002Fsrc\u002Fesm\u002Frecords\u002F{index,\nscript_instance}.rs` (VMAD retention; decode is `\u002Faudit-esm`).\n\nGround truth: `docs\u002Fengine\u002Fscripting.md` (the M47.2 sections — \"The Papyrus VM\", \"The frame budget\", \"Reference\nscripts on the VM\", the registration families — carry each primitive's CK-page contract and its \"Not modelled\"\nlist; those lists are documented gaps, not findings), `story-manager.md`, `m47-0-design.md`, `m47-2-design.md` (recognizer + \"no opcode\nsemantics guessed\"), `m47-2-recognizer-scaling.md` (corpus: handler vs fragment populations, decline-the-tail),\n`m47-3-quest-alias-design.md` (its \"Remaining subsystem boundary\" predates M47.2: Created Object \"At\"\u002F\"In\"\nfills, the `LCTN` runtime + location aliases, `FromEvent` fills and script-filled `RefCollectionAlias`es have\nsince shipped; still real gaps — world-query search across unloaded data, condition\u002Ffill-type collection fills,\ninjected packages\u002Fspells\u002Fkeywords\u002Fnames\u002Fvoice-type\u002Fcombat overlays — don't re-file as discoveries), crate docstrings\n(`translate\u002Fmod.rs`, `fragment.rs`, `fragment\u002Fvm\u002F`, `fragment\u002Fbudget.rs`, `cleanup.rs` marker house rules).\n\n**Known-open — cite, don't re-file** (verified 2026-11-09 with `gh issue view`): #5764 (interpreter deferral ~0.8 µs a delivery; a value-called function or an\narray\u002Fstruct-holding frame cannot suspend — the budget-split residual; its idle-walk half shipped as `11685934d`,\nDim 2),\n#4113 is open but lives in `crates\u002Fpapyrus`\u002F`crates\u002Fpex`\n(`\u002Faudit-papyrus`). Closed since the 2026-11-06 sync: #5802 (closed 2026-11-07; hub-file growth — every subsystem migrated to its own\n`install` + `register_saved` + `register_*_systems` file, `bde3478db`\u002F`e619dbbaf`, `93bcda9bc`, and the Part-of commits #6701-#6707\n`c22a9d410`..`5c983ecd0`: `register_late_systems` is a flat 14-call list, the Update domains and `register_post_update_systems` are flat\ncall lists into one file per subsystem, `Scheduler::run_before`\u002F`run_after` replace file position as the order carrier). Closed since the\n2026-10-31 sync: #5586 (the `mq101_conformance` example's oversized `run` — fixed\n`d7c47d741` (`run` 44 lines, one `check_*` per stage), then #6360 `01f48c929` split the file into\n`crates\u002Fscripting\u002Fexamples\u002Fmq101_conformance\u002F{main,ast_probe,scenes,packages,scripts,fragments,report}.rs`; longest\nfunction ~165 lines, `scenes.rs::check_scene_runtime`; the issue was closed 2026-11-03), #6688 (the scripting crate's Pattern-B\nmarker scans became runs of the consumers — `every_documented_pattern_b_marker_drains_in_its_named_consumer`,\n`pattern_b_markers_survive_event_cleanup`, `byroredux\u002Fsrc\u002Fsystems\u002Frequest_drain_tests.rs`, `58caf1799`; Dim 3), #6684\u002F#6685\n(the schedule-order guards read the built schedule — `build_scheduler()` \u002F `access_report()`, `2a02c5446` — and\n`system_access_declaration_tests` reads acquisitions from a `syn` tree in `byroredux\u002Fsrc\u002Facquisition_scan.rs`, depth 3\nsame-file callees, `c98a4552f`; Dim 2), #6554\u002F#6558\u002F#6545 (CTDA getters the ObScript VM already answered\ncatalogued — `CATALOG` 88 → 102 with #6657's `IsWeaponSkillType` (103 with #6654's `GetPermanentActorValue`), Oblivion's four `OBLIVION_CONDITION_GETTERS`,\n`6dec5c4a9`\u002F`612f876f9`\u002F`d3db6fd58`; Dim 3), #6570 (CTDA 659 foreign on Fallout 4, `57a49a4d4`), #6571\n(`tempering_multiplier` takes back the `SceneAliasCandidate` it lends, `9e033a595`), #6572 (`CHRR` queues on\n`DeferredFragmentEffects::relationship_events` and raises at the flush, not under the quest guards, `076de275e`), #6573\n(`SendPlayerToJail` deposits into the evidence chest before taking anything, `81332fc38`) and #6569 (declines with no\n`CrimeModel`, `dcc3dc681`), #6510\u002F#6511 (Oblivion's caller-scoped crime-gold getters honour the caller, `a48017e7b`;\n`SendTrespassAlarm` declines, `baa93fe87`), #6615 (`select_info` takes a short `QuestStageState` read per question, not a\nbody-long one, `6af13ef37`), #6619 (a scripted `AddPerk` raises a held perk's rank on FO3\u002FFNV\u002FFO4, `2d9c5802c`), #6620\n(`MenuMode` answers Oblivion's barter code 1008 from a `MenuCodes` resource, `16d9e18f3`), #6716 (`populate_scene_runtime` \u002F\n`materialize_scene_actor_alias_stubs` live in `scene\u002Fscene_runtime.rs`, `6413d542b`). Closed since the 2026-10-27 sync: #6355 (*obscript_effects.rs* crossed 2 000 LOC after the #6139 table conversion — now\n`obscript_effects\u002F`, `aa29774ec`), #6460 (ten FO3\u002FFNV script getters — `IsChild` 365, `GetTalkedToPC` 50, `GetHasNote` 382,\n`IsInList` 372, `GetLocked` 5, `GetCurrentTime` 18, `GetInSameCell` 32, `GetBaseActorValue` 277, `GetDestructionStage` 471,\n`GetMapMarkerVisible` 492 — are `CATALOG` rows read through the ObScript getter's own body, `vm_getter_command`; modeled on FO3\u002FFNV only (Oblivion for four of them since #6554),\n`102e4f5cd`; Oblivion's 365 `GetPlayerInSEWorld` moved to `OBLIVION_DIALECT`), #6478 (`IgnoreCrime` 0x10ab, `GetIgnoreCrime` 0x10c0,\n`SetEnemy` 0x1078, `SetAlly` 0x1079 and `SendAssaultAlarm` 0x105f are `Games::Fallout` rows: as `Games::Any` they shadowed Oblivion's\n`IsPlayerInJail` \u002F `CloseCurrentOblivionGate` \u002F `PositionWorld` \u002F `PositionCell` \u002F `Yield`, `598067e2a`,\n`fallout_only_opcodes_do_not_shadow_oblivions`), #6466 (a Find package's activate arrival queues through\n`PendingFragmentActivations` instead of a PostUpdate `ActivateEvent` insert that only Late readers saw, `9f783b30f`), #6470\n(`item_count` — GetItemCount and its ObScript getter — sums a form list through `Inventory::count_of_any`, saturating, `457c5cd0d`),\n#6447 (`player_controller_system` declares its `PendingScriptStoryEvents` write, `1ebb38bce`). Closed since the 2026-10-24 sync: #5646 (`GetRandomPercent` drew `pick(101)`, 0..=100; the CK\u002FGECK say\n0-99 — now `pick(100)`, pinned by `get_random_percent_is_an_integer_in_zero_to_ninety_nine`, `6701086fd`), #5647 (the\none-slot `StoryEvent` marker lost a second same-frame event on one entity — all three engine producers, `CLOC`\u002F`AHEL`\u002F`KILL`,\nnow go through `story_manager::raise_story_event`: the first event on an entity takes the marker, a later one queues on\n`PendingScriptStoryEvents`; `two_events_on_one_entity_in_a_frame_both_dispatch`, `eca0c4709`), #6139 (the ObScript\ncommand chain became the `obscript_cmd.rs` table and `ObScriptCommandHost::call` was split, `bd4cabf81`..`d5d13edcc`),\n#6142 (`apply_effect` \u002F `evaluate_guard` \u002F `check_call` \u002F `guard_reading` \u002F `call_statement` split by family,\n`b269744f2`), #6221 (`GetIsPlayerBirthsign`, `GetAnimAction` and every `IsPlayerActionActive` index but the tracked\njump (6) return `Action::Declined` instead of a constant, `c1b2b1d12`,\n`untracked_state_declines_instead_of_answering_a_constant`), #6226\u002F#6281 (script sounds go through the bounded\nvoice cache, skip decode with no device and honour SNDD attenuation and the 2D\u002FMenu bits; ObScript `PlaySound` has no\nsource reference — `NON_LOCATIONAL_SOURCE` — and is heard at the `AudioListener`, the player body only when no\nlistener exists, `f04c3433d`), #6333\u002F#6335 (per-frame cost: `collect_due` asks the stub question per due instance,\n`4f6cac254`; `StoryLocationMemo`, `80471eb78`), #6338 (`resolve_entity_by_global_form_id` answers from the\n`FormIdPool` generation-keyed index `entity_with_local`, `ab3a604bf`), #6365 (effect handlers open through\n`live_caller` \u002F `open_actor_effects`, `bf27df84c`, `handlers_open_through_the_live_caller_helpers`), #6287 (the scalar\n`npc_refuses_dialogue` agrees with the bulk gather, `aa1016f3c`), #6286 (the alias inventory grant folds into the\nform's row, `f3c8461fc`). Closed since the 2026-10-21 sync: #5750 (`GetIsVoiceType` catalogued — 426 Skyrim\u002FFO4, 427 FO3\u002FFNV, each foreign in\nthe other family; true for the speaker's VTCK voice type or any member of an FLST of them, the leveled base's terminal\ntraits via #6228 `b76a74e45` — plus `IsCommandedActor` 700, a documented 0.0 since the engine has no summon\u002Freanimate,\nso Skyrim's Hello greeting selects by voice again — `20d01cd6c`) and its FO3\u002FFNV sibling #6251 (ten functions the\nObScript getters already answered catalogued so the fail-closed gates stop declining them — `f57c75616`). Closed since the 2026-10-20 sync: #5778 (Oblivion's quest-level dialogue gates catalogued —\n254 `GetIsPlayableRace`, 365 `GetPlayerInSEWorld` (Oblivion-only through `OBLIVION_DIALECT`; every later game's 365 is `IsChild`, #6460), 70 `GetIsSex`, 310\n`GetInWorldspace`; the census now declines 1 quest \u002F 9 INFOs, the one gated by uncatalogued fn 313 — `71e488a26`).\nClosed since the 2026-10-15 sync: #5682 (the menu entry carries the INFO that admitted it and selection reuses it, so a fn-77 gate is\nrolled once — `8daa24105`, `selected_info_is_not_re_evaluated_after_menu_filtering`; the click half #6007\n`f7c8f02a7`, `a_topic_click_speaks_the_info_the_menu_offered`), #5752 (`select_info` declines an INFO whose CTDA\nset holds any term `condition::is_modeled` rejects instead of evaluating it against `0.0` — `bd85de5ea`,\n`uncatalogued_info_condition_is_declined_instead_of_matching_zero`), the Dim 6 ObScript follow-ups #5787 (`a5e5346d0`,\ntests below), #5788 (module doc refreshed, `fecdd043a`), #5789 (`%0.f` precision, `1502fbd3d`), #5790\n(`GetButtonPressed` answer global, `173f9e155`). Closed earlier: #5608\n(the `ScriptTimer`\u002F`TimerExpired` pair has no production producer or consumer — docs made honest, `bef345396`;\nFO4 `OnTimer` rides `fragment\u002Fupdates.rs`), #5681 (fragment `Utility.Wait` capped at `MAX_PROVIDER_WAIT_SECONDS`,\n`FragmentExecutionQueue` capped at `MAX_FRAGMENT_CONTINUATIONS` = 4 096, `ef130cd6c`), #5734 (quest-level dialogue\nconditions gate their quest's INFOs, `6709eb65e`), #5763 (interpreter frame budget + `ReferenceScriptIndex`,\n`195e3b4ef`), #3817 (cinematic retention reversible, `63bf3347f`), #4415 (magic runtime incl. the racial pair, `9813af435`), #5366 (Story Manager, Phases 0-4 all shipped), #5367 (dialogue\ntrees: greeting\u002Fline lifetime\u002FFO3-FNV force-greet `14cff35ae`, Skyrim force-greet `287214103`) and its #5397\nRandom-stack follow-up (`0436bea5c`), #4334 (once-only persistence, `ReferenceScriptState`), #4190, #4116.\nNot gaps: the M47.1 condition resolvers and fragment lowerer are implemented and live-verified; `MoveTo`\ndefault-materialized shapes lower (#3487); the QUST VMAD property table is wired; a Papyrus interpreter exists\n(`fragment\u002Fvm\u002F`) — \"no VM\" findings are stale; structs are modelled on the VM for Fallout 4 (the VM header's \"Not\nmodelled: structs\" line is stale, `Value::Struct` exists).\n\n**Instruments**: `crates\u002Fscripting\u002Fexamples\u002Fmq101_conformance\u002F` (the MQ101 conformance run — a module directory since #6360: `main.rs` hub, `scenes`\u002F`packages`\u002F`scripts`\u002F`fragments`\u002F`ast_probe`\u002F`report`) and `crates\u002Fscripting\u002Fexamples\u002F{fragment_coverage,extender_preflight,\nquest_fragment_populate,dump_stage_fragment_effects,refr_script_coverage,alias_script_coverage,refr_script_props,\nterminal_fragment_census,cndf_census,sm_tree_dump,dump_pex_script,obscript_tools}.rs` (need game data; `fragment_coverage` counts fragments through\n`Effect::contains_placeholder` primitives separately; `refr_script_coverage` with `VM_REASONS=1` lists why the VM declines\na reference script; `sm_tree_dump` prints a Story Manager event's tree in evaluation order; `obscript_tools\nnames \u003CESM> all` measures ObScript call-site coverage, `census`\u002F`avcodes` re-derive block and actor-value ids),\n`cargo test -p byroredux-scripting --release --lib -- --ignored --nocapture vm_cost` (interpreter cost bench,\n`fragment\u002Fvm\u002Ftests.rs`), `docs\u002Fsmoke-tests\u002Fm47-triggers.sh` (spawn+attach gate on\nSkyrim data via `--scripts-bsa`), `docs\u002Fsmoke-tests\u002Fm47-3-obscript.sh` (ObScript object blocks live on FNV), `tests\u002F{pex_recognize_e2e,location_aliases_real_data,perk_entry_points_real_data}.rs`\n(`#[ignore]`d, need game data).\n\n## Parameters \u002F Extra Fields \u002F Severity\n\n`--focus` default all 7 · `--depth shallow` (API contracts + decline\u002Fbounds invariants) | `deep` (per-frame\nECS lifecycle, lock traces). Finding fields: **Dimension**: Recognizer Chain | Fragment Dispatch & Locks |\nEvent Runtime | Attach & Reference Identity | Scene\u002FPackage\u002FCinematic | Legacy ObScript | Provider\u002FExtender Layer ·\n**Untrusted-Input**: Yes | No (Yes on any path decoding mod-supplied bytes — `.pex` derivatives, `SCDA`,\nprovider manifests).\nEscalations over `_audit-severity.md`: recognizer\u002Feffect emits on an **unmodeled** term instead of declining,\nor a wrong AST is accepted → HIGH; ECS lock held across a second resource\u002Fcomponent mutation (deadlock) →\nHIGH; transient marker not drained \u002F drained out of stage order (re-fires every frame, or a frame late) →\nHIGH; panic\u002FOOB\u002Funbounded alloc or recursion on mod-supplied bytes → HIGH; `feature-matrix.md`\u002Fcomment rot → LOW.\n\n## Phase 1: Setup\n\n`mkdir -p \u002Ftmp\u002Faudit\u002Fscripting`; dedup `gh issue list --repo matiaszanolli\u002FByroRedux --limit 300 --json number,title,state,labels > \u002Ftmp\u002Faudit\u002Fscripting\u002Fissues.json`;\nread the newest `docs\u002Faudits\u002FAUDIT_SCRIPTING_*.md` (older reports use the pre-split 8-dimension numbering:\nold 5→Dim 1\u002F2, old 6→Dims 2\u002F3, old 7→Dim 4, old 8→Dim 5) and diff against it; read `translate\u002Fmod.rs`,\n`fragment.rs`, `cleanup.rs` docstrings and `m47-2-design.md` §\"Risks & mitigations\" to separate designed\ndeclines from defects. Delta-first: `git log --since=\u003Clast report> --format='%h %cs %s' -- crates\u002Fscripting byroredux\u002Fsrc\u002Fcell_loader\u002Freferences byroredux\u002Fsrc\u002Fasset_provider\u002Fscript.rs byroredux\u002Fsrc\u002Fsystems\u002Fcinematic.rs byroredux\u002Fsrc\u002Fsystems\u002Fnpc_dialogue.rs byroredux\u002Fsrc\u002Fsystems\u002Fforcegreet.rs byroredux\u002Fsrc\u002Fsystems\u002Fstory_events.rs`.\nRun `cargo test -p byroredux-scripting` and `cargo test -p byroredux --bin byroredux boot::schedule`.\n\n## Phase 2: Dimensions\n\n### Dimension 1: Recognizer Chain & Effect Lowering (decline-on-unmodeled — highest yield)\nPaths: `crates\u002Fscripting\u002Fsrc\u002Ftranslate\u002F**`, `crates\u002Fscripting\u002Fsrc\u002Fpapyrus_provider\u002F{catalog,lower_call,lower_program}.rs` (seam)\nFirst step: `cargo test -p byroredux-scripting -- translate::`; `git log --since=\u003Clast report> -- crates\u002Fscripting\u002Fsrc\u002Ftranslate\u002F` (`effects.rs` is a thin hub over `translate\u002Feffects\u002F`; never scope to the hub file)\nGuard (E2): `every_effect_primitive_bounds_its_argument_count` (`translate\u002Feffects\u002Ftests.rs` — every `prim_*` bounds `args`\nwith a real *upper* bound or a real call to a bounded helper, comments stripped, row-for-row against the table, #5977\n`51f30c95c`; so an over-arity call from a modded `.pex` declines) and `unrecognized_script_is_a_silent_miss`; aim at what\nthey cannot see:\n- **Decline enforcement — two guard paths.** *Handler recognizers* (`compose.rs`): `classify_guard_atom(atom, ..)?`\n  propagates `None` on any atom no `GUARD_PRIMITIVES` entry claims (no `if let Some` that drops a `None`);\n  `split_and` splits `&&` only, so a `||` declines rather than lowering half\n  (`split_and_flattens_conjunction_keeps_disjunction_whole`). *Fragment lowerer* (`translate\u002Feffects\u002Flower.rs`, guards in `translate\u002Feffects\u002Fguards.rs`):\n  `classify_condition` folds an `If`\u002F`While` condition into `FragmentGuard`s — quest\u002Fobjective\u002Fglobal\u002Fquest-variable\n  reads, actor\u002Fscene\u002Flocation\u002Fmap-marker atoms, run-time `Compare`, and (M47.2) `Any` for `||` (`A || (B && C)`;\n  a negated `||` is a conjunction, a nested disjunction flattens). Any atom no guard claims returns `None` and the\n  whole fragment declines (then Dim 2's VM check gets a chance — a decline here is never a partial lowering).\n  A comparison operand that casts a numeric reading to `Bool`\u002F`String` declines (a cast is no longer transparent, #6512 `62fb2cd6d`,\n  `a_bool_cast_over_a_numeric_reading_no_longer_lowers_as_the_bare_number`); `as_num` applies each cast's own rule to a literal.\n  Flat-sequence effect model: `Stmt::ExprStmt → classify_effect_with_providers(..)`, then the quest-script inline \u002F\n  `quest_vmad_statement` fallbacks, else decline; locals bind only via `bind_local` (quest \u002F object \u002F player \u002F\n  plain, else decline); a named call argument declines instead of binding positionally (#5068). Control flow is\n  closed to: `Stmt::While` only via `lower_3d_loaded_wait` (OR-tree of `!\u003Cactor>.Is3DLoaded()` + exactly one\n  positive `Utility.Wait`) or `lower_wait_while` (any modelled guard + exactly one positive literal `Wait` →\n  `Effect::WaitWhile`), and `Stmt::If` only as `Effect::Conditional` (`ElseIf` chains nest as the else branch,\n  bounded by the same depth cap; branches lowered against **cloned** `Scope`s, and a branch that re-binds a local\n  declared before the `If` declines — `Scope::rebound_by`, #5632 `ed6998c51`; a branch may wait since the cursor\n  stack suspends mid-branch, but `has_latent_tail` still refuses a latent effect where nothing can resume it —\n  quest scope, speaker line, run-time locals). Bare `Return` lowers only as the body's final\n  statement at depth 0 (#5631), and an assignment to a bare identifier that is no declared local declines\n  (#5638, `rebinding_a_pre_branch_local_inside_a_branch_declines`, `assignment_to_a_script_variable_declines`)\n  — except where the VMAD is the quest's own and the name is one of its script variables\n  (`vmad_is_quest && is_script_variable`, M47.2; only Bool\u002FInt\u002FFloat declarations count — a non-numeric one\n  declines rather than reading `0.0`, #5978 `e802d1705`). A compound assignment (`n += 2`) to a declared local\n  declines (#5976 `686885652`); Int `\u002F` lowers only when an operand is provably Float and `SetValueInt` only on an\n  integral value (#5974 `4cf0e087f` — `ValueExpr` arithmetic is untyped f32); a truncating global read\n  (`GetValueInt`, `GetValue() as Int`) lowers in a guard only as exact bounds on the stored float and declines in a\n  value, where the VM runs it (#6215 `a16053fbb`). Widening any of these is a decline-invariant\n  regression. `lower_statements` recursion is capped (`MAX_CONDITIONAL_DEPTH` = `MAX_STMT_DEPTH`, the smaller\n  upstream cap), and one fragment's lowering across inlined quest-script callees shares `MAX_LOWERED_STATEMENTS`\n  = 10 000 (#5970 `07f2a6561` — `MAX_INLINE_DEPTH` alone let N^4 expansion through).\n- **Lower only what is modeled, name it from the declared signature.** For each primitive compare against the\n  engine class's real Papyrus signature (decompile the vanilla `.pex` — e.g. `faction.pex`, `game.pex`):\n  parameters must carry their *declared* names (#4322 `SetInChargen` flags were invented; #4318\n  `SetEnemy` lowered `abSelfIsNeutralToOther`\u002F`abOtherIsNeutralToSelf` then discarded them, so \"mutually\n  neutral\" was recorded as hostility). A primitive that lowers an argument and drops it, or accepts a\n  non-literal for a default-only parameter, is a finding; the pattern is \"accept only the literal-default form,\n  decline the rest\" (`MoveTo`: ≤ `MOVE_TO_MAX_ARGS`=6; the three offsets and `abMatchRotation` must be literals and\n  are *carried* into `Effect::MoveTo` since `24755f1d7` — the player's teleport still declines a non-zero offset \u002F\n  `!match_rotation`, and Starfield `abRotateOffset = true` declines; `AddItem`: literal `abSilent`, parsed and not\n  applied). The M47.2 primitive wave (~60 `M47.2:` commits adding `prim_*` \u002F `classify_native_*` pairs) quotes the\n  CK page in each module doc — an argument dropped or defaulted beyond what that page says is the finding.\n  Post-2026-09-19 primitives to hold to this: `StopCombat`, `AddSpell` (accepts\n  and drops a literal `abVerbose`), `RemoveSpell` (#4414\u002F#4415), `AddRaceSpells`\u002F`RemoveRaceSpells` (unqualified argless call onto the player; apply re-applies\u002Fclears exactly the stamped `RaceSpells` set, a scripted `AddSpell` survives the clear, `9813af435`; the player's own stamp is `attach_to_player`'s, #5413 `212a71dba` — before it both were silent no-ops on the only actor they target), `SetUnconscious` (`prim_set_unconscious`,\n  `[abUnconscious = true]`, player receiver declines; #5017 `3c08cfe50`). Also held to it since 2026-10-10:\n  `Lock` takes the compiled two-parameter shape (`abLock`, literal `abAsOwner` parsed and not applied; a\n  non-literal or third argument declines, #5653 `2ce808553`), `SetObjectiveDisplayed` parses `abForce` through\n  `bool_arg` (#5652 `9777c41a2`), `Enable`\u002F`DisablePlayerControls` fill absent arguments from their *own*\n  default tables (`ENABLE_PLAYER_CONTROLS_DEFAULT` vs `DISABLE_PLAYER_CONTROLS_DEFAULT`, #5651 `5e2fc3c8e`), and\n  `SetMotionType` integer literals lower only where every game agrees (just `1` = Dynamic; Skyrim\u002FFO4 constants\n  differ, the named `Motion_*` property read still lowers; #5633 `92a1782fe`,\n  `literal_motion_types_lower_only_where_every_game_agrees`; the game-aware VM accepts Skyrim's raw 1\u002F4\u002F5\u002F7 via\n  `ScriptGame` and stops the run on the inertia variants and other games' numbers, `2517782fc`). Since 2026-10-17:\n  Skyrim's `DamageActorValue`\u002F`RestoreActorValue` (and `*AV`) lower the amount's magnitude — a literal folded, a\n  run-time amount through `ValueExpr::Abs` (CK: negatives convert to positive; FO4\u002FStarfield `*Value` keep the sign,\n  #5973 `3f32efc04`); `SetEssential`\u002F`SetProtected` lower only on an ActorBase receiver, FO4\u002FStarfield's per-instance\n  Actor\u002Falias spellings decline to the VM (#5972 `40345ea0d`); the set-stage trigger recognizers fall back to the\n  script's declared bool initializers for omitted VMAD properties (#5969 `f417c3f64`).\n- **Receiver\u002Fhole binding never defaults to form-id 0**: `QuestRef::{OwningQuest, SelfRef, Property}` must\n  fully resolve (`OwningQuest` needs `ctx.owning_quest` and lowers only from `Self.GetOwningQuest()` — an\n  alias property's `GetOwningQuest()` names another quest, #5634 `221befd61`; `SelfRef` on a REFR declines); `ObjectRef` has no\n  bare-receiver case (`receiver_object` rejects `self`; object locals resolve through\n  `scope.object_locals`, alias-bound via `SceneActorBindings`); a receiver the runtime would *drive* must\n  not be the player (`StartCombat`, #4323). `PlayerRef` (0x14) resolves inside the shared\n  `resolve_entity_by_global_form_id` (#4694; every other id answers from `FormIdPool::entity_with_local`, a\n  generation-keyed index rebuilt only when `FormIdComponent` membership moves, first duplicate wins as the old scan did,\n  #6338 `ab3a604bf`) and its inverse `entity_global_form_id` returns 0x14 for the player\n  (#5979 `a6e66a08c`, which deleted the per-writer copies) — a local 0x14 special-case elsewhere is drift. A VMAD\n  `None` object property resolves to absent, never form 0 (`ScriptInstance::object_form_id`, #5971 `34cc809ae`). `Disable`\u002F`Enable` classify the receiver through the same\n  alias-aware `receiver_object` as their siblings (an alias-bound marker must not decline alone).\n- **Placeholders are coverage with a hole**: `Effect::is_placeholder` (`ShowRaceMenu`, `RequestSave`,\n  `SetHudCartMode`, `AddAchievement` — state nothing reads) must be reported separately by coverage harnesses\n  (#4328\u002F#4372), nested ones included (`Effect::contains_placeholder` \u002F `visit_nested` walk `Conditional` arms and\n  `QuestScope` bodies, #5975 `fd70bf557`); any *new* effect whose runtime arm only records a value needs listing\n  there and a pin (`only_the_counter_only_primitives_are_placeholders`).\n- **Chain order**: `RECOGNIZERS` = per-script first (`two_state_activator`, `rumble`), generic second\n  (`quest_stage_gate`); first match wins, all-`None` = silent miss; a new generic recognizer must not shadow a\n  per-script one. `quest_stage_gate` declines when the condition quest and the `SetStage` target disagree, and arms only the\n  handler in effect in the script's **boot state** (the `Auto State`'s handler, else script scope; handlers\n  only in non-auto states are ignored — #5639 `e1b7e31e7`, `advance_handler_must_be_in_the_boot_state`).\n  `rumble` extracts literal property values only. Fidelity gate: `recognizes_da10_and_reproduces_hand_builder`\n  (`.psc` side) **and** `da10_pex_reproduces_hand_builder_byte_for_byte` (`.pex` side, `#[ignore]`d, Skyrim SE\n  data) — the `.psc` half alone never touches the decompiler; run both.\n- **Provider catalog is consulted after the canonical table** (`classify_effect_with_providers`: primitives\n  first, #3934 — an installed alias must never change how vanilla lowers); lowering must only accept\n  provider barriers the dispatcher can serve (`servable_catalog()` gates on `callback.is_some()`;\n  `every_lowering_seam_reads_the_servable_catalog` in `asset_provider\u002Fscript.rs`), and only as many as the runtime can\n  cross — the four fragment entry points count the longest path's barriers and decline at\n  `MAX_PROVIDER_FRAGMENT_BARRIERS` (#6022 `893ad4838`). A script that mixes provider and non-provider handlers no\n  recognizer claims declines whole (`MixedScript`, #6021 `45c28ad66`) — the VM attach is suppressed once a provider\n  program attaches, so a half-lowered script left the rest inert.\n- **`translate_pex` clean-`None` on bad bytes and on panic**: `catching_panics` wraps the whole\n  parse→decompile→analyze→lower sequence (`a_decompile_panic_is_a_silent_none`), now split as `decompile_pex`\n  (reference-independent, cached per script) + `translate_decompiled_with_providers` (per reference, #5999\n  `f28930504`), and the VM's `check_reference_script`\u002F`check_alias_script` (#6000 `586290057`,\n  `the_vm_script_checkers_run_inside_the_panic_net`); it cannot recover OOM\u002Fstack\n  overflow (those need the bounds `\u002Faudit-papyrus` checks). `CanonicalEvent::from_papyrus` is\n  case-insensitive; `Unknown` means \"no consumer\", never a wildcard.\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_1.md`\n\n### Dimension 2: Fragment Dispatch, Quest Stages & Lock Nesting\nPaths: `crates\u002Fscripting\u002Fsrc\u002F{fragment.rs,fragment\u002F**,quest_stages.rs,quest_variables.rs,globals.rs}`, `byroredux\u002Fsrc\u002Fboot\u002Fschedule\u002F`\nFirst step: `cargo test -p byroredux-scripting -- fragment:: quest_stages::`; `cargo test -p byroredux --bin byroredux boot::schedule`\nGuards: `boot\u002Fschedule\u002Fmod.rs` — `scene_and_fragment_dispatch_chain_stays_in_dependency_order`,\n`fragment_activation_order_tests`, `hit_event_consumers_run_after_every_producer`,\n`every_parallel_system_declares_everything_it_acquires`,\n`papyrus_provider_system_…`\u002F`legacy_obscript_load_order_system_declares_everything_it_acquires`,\n`build_scheduler_reports_zero_access_conflicts`. The order guards read the *built* schedule — `build_scheduler()` +\n`access_report()` through the `schedule_order` helper, which matches an exact system name and panics on a missing one\n(#6684 `2a02c5446`; two parallel systems in one stage count as unordered) — not registration text; the\n`…declares_everything_it_acquires` guards still read `boot::SOURCES`, now through the `syn` visitor in\n`byroredux\u002Fsrc\u002Facquisition_scan.rs` (#6685 `c98a4552f`: comments, strings and `#[cfg(test)]` cannot match; same-file callees to\ndepth 3; `drain_into_resource` is listed as a write acquisition, #6707). Also `fragment\u002Ftests.rs::{nested_lock_contract_documents_\napply_effect_itself, the_nested_lock_residual_list_names_every_type_apply_effect_acquires}` (source scans over\n`fragment::SOURCES`: `apply_effect`'s doc block must name every type its per-family helpers acquire).\n- **Nested-lock safety is exclusive scheduling.** `apply_effect` (`fragment\u002Feffects.rs`, ~120 lines: every arm\n  delegates to `apply_{quest_vars,inventory,placement,scene,lock,player_control,vehicle_cinematic,messages,\n  reference_state,player_stats,location_alias,actor_values,actor_lists,ai_combat}_effect`\n  + `apply_quest_scoped_effect` in `fragment\u002Feffects\u002F*.rs`, #4340\u002F#5468\u002F#6142; `SetGlobalValue` lives in `quest_vars.rs`, and\n  `evaluate_guard` delegates to `evaluate_{quest,actor,world}_guard` in `guards.rs`; the scans read those bodies through\n  `fragment::SOURCES`, which `sources_completeness` pins to every production file) runs under one `resource_2_mut::\u003CQuestStageState, QuestObjectiveState>()`\n  taken in `apply_fragment_guard_free`; `QuestStageFragments` is cloned before any quest lock (no read→write\n  nesting). Safe only because every quest-resource system is `add_exclusive` — moving\n  `quest_fragment_dispatch_system`, `scene_fragment_dispatch_system`, or any sibling to the parallel lane, or\n  adding a nested component\u002Fresource lock, needs the ABBA analysis re-derived (`apply_effect`'s doc block is\n  the running inventory — re-read it, do not trust a count; since #5986 `9712354c9` it states the real invariant —\n  *everything* under the paired guards, VM natives and the `FragmentExecutionQueue` write included, relies on\n  exclusive scheduling — and the scan follows the helper bodies, `nested_helper_bodies`: `apply_effects`, `defer`,\n  inventory transfers, evaluators, resolvers, equipment emitters, plus the `has`\u002F`query_2_mut_mut`\u002F`resource_2_mut`\n  forms). Reverse-order acquirers (`Inventory`\u002F`Transform`\u002F\n  `Globals` first, quest resources second) on any path are the finding. The stage\u002Fobjective *pair* itself is taken\n  TypeId-sorted everywhere — `resource_2_mut` for writes, `World::try_resource_2` for the guard-free getter\n  (`evaluate_guard_guard_free`, #6101 `824c620a5`; TypeIds move with the feature set, so a code-order pair reddens the\n  lock-order lane in only some builds) — two sequential `resource::\u003C…>()` reads of the pair are the recurrence.\n- **`apply_effects` is an explicit cursor stack** (#3935) — no per-`Conditional` recursion or program clone; an\n  unresolvable guard `QuestRef` declines the whole `Conditional` (neither branch; #3785,\n  `apply_effects_declines_conditional_with_unresolvable_guard`), with a `warn!`.\n- **Cascade**: `MAX_CASCADE = 64` bounds only fragment-emitted (`is_cascade`) `SetStage`s, not authored\n  ingress; FIFO `VecDeque`; overflow warns; a no-op re-set (`previous == new`) does not cascade. A quest started\n  with no Start Up Stage reports `QuestStageAdvanced::stage_set == false`, so no stage fragment runs (CK *Quest\n  Stages Tab*); `is_run_once` gates the radiant-reset on `start_quest` (#5406). Stopping a quest or scene goes\n  through the one `QuestStageState::stop_with_shutdown` (a running quest advances to its shut-down stage first;\n  #5812 `32bebaa19`, `stop_with_shutdown_advances_only_a_running_quest`) — a private stop tail is drift.\n- **Objective transitions** (#5153): `QuestObjectiveState` mutators push a bounded `QuestObjectiveEvent` only on\n  false→true flips (`objective_mutators_emit_transitions_only`); the queue is serde-skipped presentation\n  (drained by the app frame into announcements) — a repeat\u002Fun-flip that emits is the regression.\n- **Quest journal**: `QuestStageState` keeps a sequenced event journal (`QUEST_EVENT_RETENTION` = 16 384) with\n  four fixed subscribers (`SCENE_QUEST_EVENT_SUBSCRIBER`, `FRAGMENT_QUEST_EVENT_SUBSCRIBER`, `TERMINAL_QUEST_EVENT_SUBSCRIBER`, and\n  `OBSCRIPT_STAGE_QUEST_EVENT_SUBSCRIBER` for `obscript_stage_result_system`, Dim 6), each polling its own cursor\n  (`missed_events > 0` ⇒ the subscriber must resync from canonical state). `set_stage` keeps `stages_done`\n  history (`GetStageDone(37)` stays true after 40). The journal is authoritative; `QuestStageAdvancedBatch` is a\n  compatibility mirror written through `push_quest_stage_advances` (one `SparseSetStorage` slot: a bare\n  `insert` drops same-frame producers, #3277). A consumer that reads both must dedup the mirror as a multiset\n  (as `quest_fragment_dispatch_system` does — otherwise a double advance) and must not claim (`poll`) the\n  journal while it has nothing to consume (#3012); a new consumer picks a subscriber constant, not a private cursor.\n- **Populate**: `populate_quest_fragments_from_pex` merges all of a stage's `Fragment_N` effect chains in VMAD\n  order and *replaces* the installed chain (re-population must not duplicate); `QuestStageFragments::vmad`\n  is registered so `Property`-targeted effects resolve — a decline with a populated VMAD is a regression.\n  `SceneFragments` is one binding per `(scene, event)`.\n- **Lock & enable ledgers** (`ReferenceLockState`, `ReferenceEnableState`, FormID-keyed, saved): a scripted\n  `SetLocked`\u002F`SetLockLevel` records the component's **full outcome** (level + key), never a partial delta that\n  outranks the authored XLOC (#4329); alias-bound receivers come back to a FormID via `entity_global_form_id`;\n  non-resident references still record where the ledger can hold them (#4330; `Enable`\u002F`Disable` do). Third\n  sibling `ReferenceScriptState` (#4334, save v26): fire-once triggers park their script there and the\n  recognizer's spawn closure consults it so a reload does not re-arm. Fourth sibling `ReferenceMotionTypeState`\n  (local FormID → `MotionType`, #6237 `6765e60eb`): `Effect::SetMotionType` (lowering and VM) records it through the\n  deferred batch and `cell_loader::spawn::scripted_motion_type` applies it to every collider a placement spawns — a\n  `RigidBodyData` column cannot carry it, because collision entities never hold a `FormIdComponent`\n  (`reference_motion_type_state_survives_save_load_round_trip`,\n  `a_scripted_motion_type_is_applied_to_the_placements_rebuilt_colliders`). A \"simplification\" that keys any of the\n  four ledgers by entity is the regression.\n- `Effect::StartCombat` also removes the actor's `AmbientEngagement` (moved into `crates\u002Fscripting\u002Fsrc\u002Fcombat.rs`\n  beside `AiCombatState`) in its own guard scope, so a scripted fight is never auto-dropped by the ambient\n  disengage (#5046 `fef67f3c3`); `Effect::SetUnconscious` writes `ActorControlState` (mutually exclusive with\n  restrained) and ends the actor's combat — both acquisitions belong in `apply_effect`'s lock inventory.\n- `Effect::AddSpell`\u002F`RemoveSpell` apply through `magic::{add_spell,remove_spell}` (`SpellList` + permanent\n  `ActorValues` modifier, add\u002Fundo symmetric — `add_and_remove_spell_apply_and_undo_permanent_modifiers`); both\n  types are nested under the quest lock, so they belong in `apply_effect`'s lock inventory.\n- `Effect::SetGlobalValue` writes `Globals` (saved, `resolve_property_form_id` — a GLOB is never alias-bound).\n  `QuestAliasReadinessGate`: advances only when `is_running`, `stage \u003C only_below_stage`, and\n  `!get_stage_done(target)` (idempotent); one gate per quest (upsert).\n- **Papyrus VM contract** (`fragment\u002Fvm\u002F`, `docs\u002Fengine\u002Fscripting.md` \"The Papyrus VM\"): populate installs\n  `Effect::Interpret` only through `interpret_fallback`, i.e. when `check_function` accepts the fragment ahead of\n  time — against typed placeholders, in every state's version down the `extends` chain, collecting each script the\n  run needs (`the_check_takes_what_the_lowering_declines`); reference and alias scripts go through\n  `check_reference_script` \u002F `check_alias_script` (every handler of `DELIVERED_EVENTS` \u002F `DELIVERED_ALIAS_EVENTS`\n  must run whole; both lists are built from one `SHARED_REFERENCE_EVENTS` table, the reference list appending the\n  documented `REFERENCE_ONLY_EVENTS`, #6158 `fa719a9d5`) and each delivery re-checks via `handler_runs` against the installed scripts. A run that still\n  meets a native declining its *actual* values stops and logs — never a guessed value (`feedback_no_guessing`).\n  Int-typed natives (`GetStage`, `GetItemCount`, `GetRelationshipRank`, `GetLevel`, `RandomInt`, a truncated\n  `GetValueInt`) return `Value::Int` and a typed local keeps its declared numeric type, so `i \u002F 10` and string\n  concatenation match the compiled Int\u002FFloat split the decompiler erased (#6216 `8dee19ed4`).\n  Anything that raises a Story Manager event or touches a resource outside the quest pair defers onto `DeferredFragmentEffects`\n  (`fragment\u002Feffects\u002Fdeferred.rs`; ~50 queues, flushed in a fixed order by `apply_at_depth` once the quest guards drop, most through\n  the shared `drain_into_resource` helper, #6707): `Faction.SendPlayerToJail` → `jail_sends` and `Game.TeachWord`\u002F`UnlockWord`\n  (`Effect::ObtainWord`) → `word_gains` (`jail::send_player_to_jail` raises `ARRT`\u002F`JAIL` and declines with no `CrimeModel`, #6569\n  `dcc3dc681`, and deposits into the evidence chest before taking a stack, #6573 `81332fc38`; `words_of_power::obtain_word` raises\n  `NVPE`; a fake jail moves nobody), `SetRelationshipRank` and the VM friend-rank native → `relationship_events` (`CHRR`, #6572\n  `076de275e`) — none may take a second resource lock under the pair; a new native that calls a `raise_*_story_event` inline is the\n  recurrence.\n  Natives are not interpreted here: `classify_native_{effect,value,guard}` re-use the lowering's primitive table\n  and `apply_effects` applies the result, so Dim 1's per-primitive rules and this dimension's lock inventory apply\n  to every VM native unchanged. Bounds: `MAX_STEPS` = 100 000 statements per *logical* run (the budget's\n  `carried_steps` keeps it cumulative across yields), `MAX_DEPTH` = 16 script-function nesting, a `Utility.Wait`\n  past `MAX_PROVIDER_WAIT_SECONDS` stops the run (`waits_past_the_shared_cap_stop_the_run`, #5681), the continuation\n  queue holds `MAX_FRAGMENT_CONTINUATIONS` = 4 096, enforced at every push (`FragmentExecutionQueue::push` \u002F\n  `extend_capped` drop the newest tail — zero-delay deferrals, custom-event deliveries and yields used to bypass it,\n  #5984 `73fddb4b8`). Allocation caps (#5791 `5c3c5758d`): `MAX_ARRAY_ELEMENTS` \u002F `MAX_STRING_BYTES` reuse the SDK's\n  `MAX_SCRIPT_ARRAY_ELEMENTS` (512) \u002F `MAX_SCRIPT_STRING_BYTES` (4 KiB) and stop the run in `Expr::New`, array\n  literals, `Add`\u002F`Insert` and both string-concat sites; a stored script variable follows at most `MAX_STORED_DEPTH`\n  = 8 levels (a struct cycle `s.m = s` stops instead of overflowing the stack, #5983 `9018a5523`). The *checks* run\n  under `catching_panics` (#6000), the run itself does not (populate does); the\n  production `unreachable!`\u002F`expect` arms in `fragment\u002Fvm\u002Finterp.rs` each rest on a \"loaded\u002Fchecked above\" invariant — re-verify.\n  Script variables live in the saved `QuestScriptVariables` (numbers) \u002F `QuestScriptObjects` (objects, strings,\n  arrays, structs) keyed by the *owner id* — a quest FormID, a reference FormID, or an `AliasScriptOwners` id in the\n  `ALIAS_OWNER_BASE` (0xFC00_0000) range, which no plugin can occupy since regular slot allocation stops at 0xFB\n  (#5988 `0edc61bbf`) — so they outlive the cell unload; keying any of them by entity is the\n  regression (same rule as Dim 2's ledgers).\n- **Frame budget** (`fragment\u002Fbudget.rs`, #5763): `VmFrameBudget` = `DEFAULT_FRAME_BUDGET` (10 000 statements) per\n  frame, `RUN_START_COST` (16) per run, renewed by `event_cleanup_system` — a budget nothing renews kills the\n  interpreter after one frame. A run that has not started defers onto `FragmentExecutionQueue` with zero delay; a\n  run in progress yields between statements exactly as a `Utility.Wait(0)` would (`VmResume.carried_steps`); a due\n  `OnUpdate` the budget cannot start is left due, not queued; a matching one-shot `RegisterForHitEvent` fires and its\n  run defers rather than being dropped (#5987 `746214f29`); `fragment_continuation_system` only advances the\n  clocks while `budget::exhausted`. Every Papyrus-call system goes through the shared tail\n  `fragment\u002Fdispatch.rs::run_papyrus_call` (budget → `defer` → `apply_fragment_guard_free`) and `flush_advances`\n  (#5797 — hits, distance, package, perk and terminal ran unbudgeted before it); a new system that hand-rolls the\n  tail is the recurrence. Unsplittable (documented residual, open as #5764): a statement inside a function called for its value\n  and any frame holding an array\u002Fstruct local — they finish in-frame, charged to the budget. Guards:\n  `a_budget_is_spent_and_renewed`, `a_run_the_budget_cuts_short_resumes_where_it_stopped`,\n  `several_runaway_handlers_stay_inside_the_frame_budget`; cost bench `vm_cost_*` (`#[ignore]`d).\n  `ReferenceScriptIndex` (one hash lookup for \"is this reference loaded, which scripts\") is rebuilt at the first\n  lookup after an attach and re-validates the entity it finds — a despawned\u002Freused id reads as not loaded.\n  `fragment\u002Freference.rs::collect_deliveries` returns before walking the attached scripts on a frame that raised none\n  of its sources (`OnDeathEvent` — drained first, ahead of the early-out — bleedout\u002Fcombat\u002Fplayer-location changes,\n  `OnCellLoadEvent`, `OnInitEvent`, `ActivateEvent`, `OnTriggerEnterEvent`, `HitEvent`; #5764 part, `11685934d`): a new\n  delivery source not added to that gate is silently never delivered.\n- **Delivery systems** (all exclusive `Update`; order in `boot\u002Fschedule\u002Fupdate\u002F`): (`obscript_object_system`, Dim 6) →\n  `check_alias_scripts_dispatch` →\n  `alias_script_event_system` → `reference_script_event_system` (ahead of quest dispatch so a stage a script sets\n  runs its fragment the same frame; drains `OnDeathEvent` at its head; every marker but `HitEvent`) → `activate_parent_relay_system` →\n  `animation_event_system` → `scripted_sound_system` → `quest_fragment_dispatch` → `quest_terminal_stage_system` →\n  `fragment_continuation_system` → `script_update_dispatch` → `distance_event_system` → … →\n  `pending_trap_hit_flush_system` → `reference_script_hit_system` (reference\u002Falias `OnHit`, split out by #5991\n  `e4810c125` because projectile and trap hits land after the frame pass) → `hit_event_system` →\n  `obscript_hit_system`\u002F`obscript_combat_system` — every `HitEvent` consumer after every producer. Registration families (`fragment\u002F{updates,distance,events,\n  hits,anim_events}.rs`): per script *instance*, saved, delivered to the registrant only; a quest's registrations\n  end when it stops, a reference's wait while it is unloaded; a registration is accepted only when its handler\n  passes the VM check, so a delivery never meets an unchecked body (a registration whose handler cannot run is\n  skipped without failing the registering code). PACK \u002F PERK \u002F TERM fragments (`fragment\u002F{package,perk,terminal}.rs`)\n  are *host-reported* (`report_package_end` on a Travel arrival, `report_perk_entry` \u002F `report_terminal_selection`\n  from the `perk.run` \u002F `terminal.select` console commands — no engine producer for the activation popup or terminal\n  screen yet, a documented gap).\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_2.md`\n\n### Dimension 3: Event Runtime — Markers, Timers, Conditions, Triggers\nPaths: `crates\u002Fscripting\u002Fsrc\u002F{events,cleanup,timer,recurring_update,condition,trigger,vm_state,player_control}.rs`, `crates\u002Fscripting\u002Fsrc\u002Fpapyrus_demo\u002Fquest_advance.rs`, the marker producers\u002Fconsumers in the M47.2 request modules (`*_requests.rs`, `havok_impulse.rs`, `activate_parents.rs`)\nFirst step: `cargo test -p byroredux-scripting -- cleanup:: condition:: trigger:: recurring_update:: quest_advance`\nGuards: `cleanup.rs::every_drained_marker_is_a_documented_pattern_a_marker` (the one remaining doc-vs-body text pin),\n`every_documented_pattern_b_marker_drains_in_its_named_consumer` and `pattern_b_markers_survive_event_cleanup` — behavioural\nsince #6688 `58caf1799`: the first raises each scripting-crate marker (`OnDeathEvent`, the scene \u002F dialogue \u002F package batches\nand requests, `StoryEvent`, `TwoStateTransitionBatch`), runs its named consumer and expects it gone (the old source scan was\nsatisfied by a producer's `query_mut::\u003CT>` insert just as well); the second runs `event_cleanup_system` and expects every\nPattern-B marker still present. The binary crate's request consumers (`HavokImpulseRequest`, `MotionTypeChangeRequest`,\n`PickIdleRequest`, `FleeRequest`, `PushActorRequest`, `ReviveRequest`, `UseWeaponRequest`, `ResetInventoryRequest`) are run in\n`byroredux\u002Fsrc\u002Fsystems\u002Frequest_drain_tests.rs`; `OnResetEvent`'s private consumer in\n`obscript_objects.rs::the_reset_marker_is_taken_even_when_nothing_has_a_script` (it drains ahead of `collect_due`'s\nno-instances early returns, #6267 `cf7380e27`) — a new Pattern-B row needs its consumer run in one of those, not a text row.\nAlso `cleanup_removes_all_event_types`;\n`boot\u002Fschedule\u002Fmod.rs::{transient_cleanup_is_the_last_late_exclusive, activation_flush_is_scheduled_before_every_activate_event_consumer, extension_event_adapters_run_before_transient_cleanup}`.\n- **Marker lifetime — two sanctioned patterns** (module doc of `cleanup.rs` is authoritative): **A** = listed in\n  `event_cleanup_system` for markers with no single owner (last system in `Stage::Late`); **B** = drained\n  *unconditionally at the head* of the one owning consumer (no early return before the drain, or the marker\n  strands and re-fires forever). A marker in neither is the bug — cross-check every `world.insert` of a\n  marker type against the drain lists, and check each Pattern-B owner's first statements. **Multi-producer\n  markers must merge, not overwrite** (`SparseSetStorage` = one slot per entity): `QuestStageAdvancedBatch`\n  (`push_quest_stage_advances`), `HitEvent` (one row per target: the NPC melee producer holds a strike on an\n  already-hit target, #4324; projectile hits ride the `ProcessTrapHit` queue whose flush applies the same hold,\n  #5860 `ea28a35b8` — re-verify after any new producer; a VATS queue's folded shots ride the sibling `HitParts` (per-shot `PartStrike`, VATS-LIMB-002, `83e9c6c92`), a Pattern-A marker drained with the `HitEvent` it describes), `ActivateEvent` (a system running after the Update consumers must queue through `PendingFragmentActivations`, not insert — the Find package's arrival did, so Update `OnActivate` consumers missed it until #6466 `9f783b30f`; Update-stage consumer order pinned by the flush test, which now\n  lists `container_loot_system` and `mg07_on_activate_dispatch` (#4712\u002F#4116), plus\n  `reference_script_event_system`; the Late-stage `npc_dialogue` selection system is a further consumer — it must\n  stay before `event_cleanup_system`); `NativeActivation` rides an `ActivateEvent` raised by `Activate(akActivator,\n  true)` and makes the Papyrus `OnActivate` delivery and the `BlockActivation` gate stand aside (CK\n  *Activate - ObjectReference*) — every script-side `OnActivate` consumer (lowered quest-advance, rumble, MG07,\n  provider, WASM extension, VM) reads `papyrus_activations` (`ActivateEvent` minus `NativeActivation`, #5994\n  `6f7dd2213`), so a raw `ActivateEvent` read in a script consumer is the regression (the last two,\n`two_state_activator_system` and `legacy_obscript_load_order_system`, moved over in #6218 `36d1a2c2c`); `OnDeathEvent` is Pattern B, drained at the head of\n  `reference_script_event_system` (a Late-stage script kill is delivered next frame, not lost to cleanup).\n  `event_cleanup_system` also renews `VmFrameBudget` (Dim 2) and drains `NativeActivation`; its module-doc table\n  lists the request markers the engine-side consumers drain (e.g. `HavokImpulseRequest` →\n  `scripted_havok_impulse_system`, which snapshots, drains exactly those and early-returns only when there are none —\na missing `HavokImpulseRules` drains the snapshot before returning, #6009 `f00bfd6e5`; a resource check placed after\nthe resolve and before the drain is the recurrence).\n- **Two-phase lock discipline**: `timer_tick_system` (no production code starts a `ScriptTimer` or reads\n  `TimerExpired` — #5608; FO4 `OnTimer` is `fragment\u002Fupdates.rs`), `trigger_detection_system`,\n  `recurring_update_tick_system` collect under one `query_mut`, `drop()`, then acquire the marker-insert\n  `query_mut`; two component-mut locks at once forces the TypeId-sorted contract (deadlock vector).\n- **CTDA OR-precedence** (`condition\u002Feval.rs::evaluate`): consecutive `or_next` conditions form a block that binds\n  tighter than the AND chain (`A AND B OR C AND D` = `A AND (B OR C) AND D`); empty list → `true`; guards\n  `or_precedence_quirk_*`, `and_chain_short_circuits_on_first_false`. Function catalog per the module-doc\n  table (indices verified against TES5Edit; a function is added as one `condition\u002Fcatalog.rs` `ROWS` entry, in `CATALOG` order; `CATALOG` was 24 at #5380 `395d2d831`, which added 56 `GetQuestRunning`,\n  74 `GetGlobalValue`, 77 `GetRandomPercent` — the last rides `StoryManagerRng`, a documented 50.0 with none\n  installed, and draws an integer 0..=99 as the CK says — `pick(100)`, #5646 `6701086fd`; the module-doc table and a row-count pin\n  (`the_module_doc_table_lists_the_whole_catalog`) track the catalog, #5648 `2ed7f8ec3`. `GetQuestRunning`\n  reads `is_running` alone — a stopped\u002Fcompleted\u002Ffailed quest is not running, #5636 `aac92c6ca`; the plugin-side\n  `param1_is_form_id` load-order remap mirrors the catalog by index, with rows for 56\u002F71\u002F74 and an exhaustive\n  mirror test, #5637 `722c06a76`; M47.2 grew `CATALOG` to 48, #5778 `71e488a26` to 52, #5750\u002F#6251\u002Fthe crime\ngetters to 77, #6460 `102e4f5cd` + the tempering read to 88, #6558 `612f876f9` +9 to 97, #6545 `d3db6fd58` +4 to 101 and #6657's `IsWeaponSkillType` (109, FO3\u002FFNV) to 102 and `GetPermanentActorValue` (495, FO3\u002FFNV, #6654 `3ae93950b`) to 103 (the array length is the live count; #6251 `f57c75616` added 35 `GetDisabled`, 47 `GetItemCount`\n(a form list sums its members), 64 `GetIsCreature`, 84 `GetDeadCount`, 131 `GetPCIsSex`, 289 `IsInCombat`, FNV's\n420\u002F421 `GetObjectiveCompleted`\u002F`Displayed`, 431 `GetHealthPercentage`, 546 `GetQuestCompleted`; #5750 `20d01cd6c`\n426\u002F427 `GetIsVoiceType` and 700 `IsCommandedActor`; the crime commits the `GetCrimeGold`\u002F`GetCrime`\u002F`IsGuard`\u002F\n`GetPCFame`-family reads, whose state is `crime_*`\u002F`jail`\u002F`guards` — `\u002Faudit-gameplay`; #5778 added 254 `GetIsPlayableRace` over `PlayableRaces`, 365 `GetPlayerInSEWorld`, 70 `GetIsSex`, 310\n`GetInWorldspace`, whose `param_1` joins the plugin remap) — 629 `GetVMQuestVariable`, the\n  location family 181\u002F359\u002F360\u002F562\u002F563\u002F565\u002F566\u002F567\u002F605 plus the cleared \u002F keyword-data location reads (250, 598 and the\n  `GetKeywordDataFor*` rows), 576 `GetEventData` (xEdit's packed `function:member` in `param_1`, the form in\n  `param_2`), 560 `HasKeyword`, 403 `GetRelationshipRank`, 237 `GetIsGhost` and the essential\u002Fprotected\u002F\n  bleedout\u002Fteammate reads — those that need a context read `ConditionContext` (owning quest's aliases, a\n  location-alias fill's `location_subject`) through `evaluate_contextual` (`reads_context`), and\n  `param2_is_form_id` remaps 605\u002F181's (and 576's) second parameter; 180\u002F610 stay unmapped (Oblivion\u002FFNV collisions); fn 0 is deliberately **unmapped** (xEdit: `GetWantBlocking` on TES5\u002FFO4, no index 0 on\n  TES4\u002FFO3\u002FFNV — the short-lived `GetButtonPressed` mapping was removed by #5431; `GetButtonPressed` exists\n  only as an ObScript script function in `obscript_quests`)); `GetIsID` compares the Run-On's **base** object\n  (`SceneAliasCandidate::base_form_id`), not the placed ref (#5041 `1816bbc14`,\n  `get_is_id_matches_run_on_base_object_not_placed_reference`); `GetActorValue` reads through\n  `CharacterRuleset::actor_value` (the shared derived+modifier composer, #5042 — `\u002Faudit-character` Dim 4), its\n  authored enum index translated to the loaded AVIF by `condition_actor_value_form` (FO3\u002FFNV GetAV table, Skyrim UESP\n  indices; unreadable on Oblivion, which has no AVIFs — #5989 `d1dd5e030`); unknown functions return the documented safe default — a\n  display\u002Fselection default only: a consumer that *acts* on a pass must decline on any `Unknown` term first\n  (Story Manager nodes, #5380; the ambient force-greet install's `package_conditions_fully_modeled`, #5376;\n  dialogue INFOs, #5752; scene\u002Fphase starts, quest-log entries, objective targets, base-form trigger advances and\n  consumable branches through `evaluate_modeled`, #5993 `9b6dcf872`;\n  every such check goes through the one game-aware `condition::is_modeled` — fn 79 `GetQuestVariable` reads\n  `ObScriptQuestLocals` on Oblivion\u002FFO3\u002FFNV and stays unmodeled on FO4\u002FStarfield where 79 is another function,\n  `f67d82b3c`; catalogued indices another game reuses — 109, 125, 131, 403, 426\u002F427, 431, 449, 459, 533, 550, 555, 630, 659 (FO4 `HasVMScript`, #6570 `57a49a4d4`) — are unmodeled there (`FOREIGN_INDICES`, per-game rows), #5990 `9f418b4fa`; the VM-bridged getters (`vm_getter_command`: the ten of #6460 plus #6558's nine and #6545's four, 23 in all) are modeled only where `obscript_cmd::getter_answers_conditions` finds the VM's row — FO3\u002FFNV, and Oblivion for the four `OBLIVION_CONDITION_GETTERS` (5\u002F18\u002F32\u002F50, #6554 `6dec5c4a9`); an untranslatable `GetActorValue` index is unmodeled), and\n  a new intrusive consumer that trusts the fail-open pass is the finding; `RunOn`\n  resolution declines (condition fails) on an unresolvable target rather than defaulting to the subject; a\n  wrong sentinel flips a condition. `crates\u002Fplugin\u002Fsrc\u002Fconsumables.rs` borrows fn-586 semantics by profile\n  (`\u002Faudit-character` Dim 1).\n- **Triggers** (`trigger_detection_system`): edge-triggered (outside→inside); `occupant_inside: Option\u003Cbool>`\n  with `None` = never checked (first tick never fires for the player — a player loaded inside a volume must\n  not fire); `contains` math (Sphere `half_extents.x` radius; OBB via `rotation.inverse()`);\n  `OnTriggerEnterEvent.triggerers: Vec\u003CEntityId>` — no consumer may read `[0]` only\n  (`preserves_all_actors_entering_one_volume_in_the_same_frame`); actors tracked in `TriggerOccupancyState`\n  keyed `(trigger, actor)` and pruned each frame (`retain(observed)`); only tethered horses use\n  `intersects_sphere` (`TETHERED_HORSE_TRIGGER_RADIUS`); `became_ready_inside` is a level condition that stops\n  once the target stage is done. `GetTriggerObjectCount` counts through `trigger_occupants` (player included; an\n  empty candidate list clears stale pairs, #5992 `06f6382fe`). `actor_quest_trigger_is_in_sequence` (gate) and\n  `scene_trigger_actor_approach_system_inner` (router, Dim 5) answer \"which BaseForm trigger stage is next\"\n  separately — verify they agree via the shared `base_form_advance_is_eligible`\u002F`scene_phase_awaited_stage`\n  (#4333) on cross-quest phase waits and centerless triggers.\n- `quest_advance_system` unifies `ActivateEvent` + `OnTriggerEnterEvent` on `QuestAdvanceOnActivate` with a\n  three-way `ActivatorGate` (`Any`\u002F`PlayerOnly`\u002F`BaseForm`), evaluated per `(entity, triggerer)` pair, and the first\n  passing triggerer of a source wins — one advance per volume per frame, so two actors entering together cannot run\n  the stage fragment twice past `onlyOnce` (#5995 `6a85756d6`);\n  nothing may deliver both signals to one entity in one frame. `disable_reference_after_advance` (from\n  `disableWhenDone`) records into `ReferenceEnableState`; both fire-once variants park in `ReferenceScriptState`\n  (`fire_once_advances_park_the_reference_script_state`, #4334).\n- `recurring_update_tick_system`: no fire on the registering frame\u002Fzero dt; once per interval; overshoot fires\n  once; `UnregisterForUpdate` in a handler terminates cleanly. `QuestAliasReadinessGate` timing: after\n  `quest_alias_refresh_system`, before `scene_playback_system`.\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_3.md`\n\n### Dimension 4: Engine Attach Path & Reference Identity\nPaths: `byroredux\u002Fsrc\u002Fcell_loader\u002Freferences\u002F{attach,synth_child,mod}.rs`, `byroredux\u002Fsrc\u002Fcell_loader\u002F{spawn,exterior,unload}.rs`, `byroredux\u002Fsrc\u002Fcell_loader\u002Fexterior\u002Fpersistent.rs`, `byroredux\u002Fsrc\u002Fasset_provider\u002Fscript.rs`, `crates\u002Fscripting\u002Fsrc\u002Ffragment\u002F{reference,alias_scripts}.rs` (the attached component + check), `crates\u002Fplugin\u002Fsrc\u002Fesm\u002Frecords\u002Findex.rs`\nFirst step: `cargo test -p byroredux --bin byroredux -- cell_loader::references reference_enable_gate`; `grep -rn 'spawn_logical_quest_reference' byroredux\u002Fsrc`\nUntrusted-Input: Yes — `.pex` bytes come from possibly-modded archives.\n- **Silent-miss everywhere**: no `--scripts-bsa`, VMAD absent, `.pex` missing (`extract_pex` → `None`), decode\u002F\n  decompile failure, recognizer miss — every branch is `continue`\u002F`return`, never `unwrap`\u002F`expect`.\n  `--scripts-bsa` is repeatable, **first-listed-archive-hit wins** (the inverse of mod-manager priority:\n  list overrides first); `pex_archive_path` normalizes to `scripts\\\u003Clowercase>.pex` (a wrong prefix\u002Fseparator =\n  every `.pex` misses, zero attach, no error).\n- **Script sources**: `base_record_script_instance` (VMAD on ACTI\u002FCONT\u002FNPC\u002FCREA, item family, statics family\n  incl. STAT\u002FMSTT\u002FFURN\u002FDOOR\u002FLIGH\u002F…, TERM; pins per family) and legacy `base_record_script` (SCRI incl. the\n  statics family); REFR's own VMAD is merged by `dedup_vmad_scripts` (names differing only by case collapse\n  to one attach; a reference that lists a script with fewer properties than its base record's copy keeps its own\n  values and inherits the rest — `a_reference_inherits_the_base_copys_properties_it_does_not_set`).\n  **Attach order**: the `.pex` is extracted and decompiled once per script name (`decompiled_pex` →\n  `DecompiledPexCache`, compatibility preflight recorded on first sight; #5999 `f28930504`), then\n  `translate_decompiled_with_providers` runs per reference against the shared AST and yields a provider program and\u002For a recognized\n  archetype (each attaches when present); only when neither claimed the script does\n  `attach_vm_reference_script` (`asset_provider\u002Fscript.rs`) run, which declines a reference with no FormID (a\n  non-primary SCOL\u002FPKIN child — the VM reaches scripts by FormID, #5998 `838ce679d`) and attaches\n  `PapyrusReferenceScripts` when `check_reference_script` accepts every handler of the delivered events (verdict\n  cached per script name in `VmReferenceScriptChecks`; a script a recognizer models gets no VM instance, so VM\n  calls into it decline). Quest alias scripts are checked lazily by `check_running_quest_alias_scripts` —\n  `ALIAS_CHECKS_PER_FRAME` = 4 quests and `ALIAS_SCRIPT_CHECKS_PER_FRAME` = 8 distinct uncached scripts per frame\n  (#6001 `b7c04b44b`; a stopped quest resumes next frame), only for running quests — never at cell load. A legacy\n  `SCRI` reference attaches its ObScript object script (`attach_object_script`, Dim 6) in the same `attach.rs` arm\n  set. Verifying coverage against only the first few accessor arms re-derives a closed gap.\n- **Every identity-only actor\u002Freference stub must attach scripts.** All `spawn_logical_quest_reference`\n  callers outside `synth_child.rs` — the persistent-worldspace loop in `cell_loader\u002Fexterior\u002Fpersistent.rs` and\n  `materialize_scene_actor_alias_stubs` in `scene\u002Fscene_runtime.rs` — go through\n  `spawn_logical_quest_reference_with_scripts` (attaches once per `reference_form_id`, #4112\u002F#4331; the source\n  pin in `cell_loader\u002Freferences\u002Fsource_pin_tests.rs` rejects the bare spelling and scans production text only,\n  #5650 `a7e05dd7b`). Identity-only entities get `OnInit` alone: `attach_script_for_refr` takes `has_3d` and inserts\n  `OnCellLoadEvent` (→ `OnInit`\u002F`OnCellAttach`\u002F`OnLoad`\u002F`OnCellLoad`) only with real 3D, else `OnInitEvent`; every\n  `spawn_logical_quest_reference` site pairs with `attach_identity_reference_script` and a `Disable()`d trigger passes\n  `!placement_disabled` (#5997 `a44d4a20d`, `attach_script_for_refr_sends_the_load_events_only_to_entities_with_3d`)\n  — a stub that receives `OnCellLoadEvent` runs its `OnLoad` twice. The persistent loader also stamps\n  `UnloadedReferenceStub` on a stub whose home cell is not loaded, so ObScript `GameMode` skips it like a\n  `RemoteSceneActorStub` while its event blocks still answer (#6220 `335994b4c`). Residual (documented in the helper): a stub followed by the home cell\n  streaming in leaves scripts on both — stub\u002Freal reconciliation is unbuilt and untracked (the helper doc calls it\n  *#2664's half*, but #2664 closed on the stamping\u002F`Transform` half; no open issue owns it). New spawn paths\n  that call the bare spawner are the recurrence.\n- **Canonical identity stamping** (`stamp_quest_reference`: `FormIdComponent` + `SceneAliasCandidate` +\n  `mark_scene_actor_bindings_dirty`) is applied at every synthetic REFR path, gated on the primary synth child\n  (`synth_idx == 0`) so a SCOL\u002FPKIN fan-out registers one candidate per authored alias; the no-mesh fallback\n  still spawns a `Transform`\u002F`GlobalTransform` entity.\n- **Enable\u002Flock gates** consult the FormID ledgers *before* content is built: `reference_is_disabled` is asked\n  once per REFR ahead of every branch in `load_references_budgeted` (actor jobs, LIGH-only\u002Ffxlight placements,\n  invisible triggers — #4326\u002F#4327), `placement_is_disabled` in `spawn_placed_instances` after the root but\n  before mesh\u002Fcollider\u002Flight, `scripted_lock_override` at the `Locked` stamp. A disabled actor\u002Ftrigger keeps\n  identity + scripts but no body\u002Fvolume. Regression = a spawn path that never reaches a gate, or the gate\n  moved render-side (`AnimatedVisibility` is honored in static but not skinned rendering). An XESP child resolves\n  through `reference_enabled_from`: the chain is followed (cycle-capped) to its first parent-less reference, whose\n  scripted Enable\u002FDisable beats its authored flag, flipping once per inverted hop; a child cannot be toggled\n  independently (CK *Reference*), and a parent-disabled child keeps a content-withheld root with identity + scripts\n  (#6077 `22ff0e12e`). Guard:\n  `cell_loader\u002Freference_enable_gate_tests.rs`.\n- **XPRM → `TriggerVolume`** (`trigger_volume_from_primitive`): bounds are z-up **half**-extents (do not\n  divide by 2), permute `[x, z, y]` with `.abs()`, REFR scale baked into a world-space volume, sphere radius in\n  `half_extents.x`, shape `1 → Box`, `3 → Sphere`, else `None`\n  (`trigger_volume_from_{box,sphere}_primitive_*`); invisible (MODL-less) trigger REFRs compose world space once.\n- **Spawn\u002Funload hooks the VM reads** (M47.2): `spawn.rs` stamps `EditorLocation` (the spawn pose, for\n  `MoveToMyEditorLocation`), `ExplicitOwner` \u002F `ExplicitEncounterZone` from the REFR, and re-applies scripted\n  faction edits (`reapply_scripted_faction_changes`) after the actor job so record-derived membership never undoes\n  them; `unload.rs` calls `raise_unload_events` on the victims *before* despawn (`OnCellDetach` \u002F `OnUnload`) — but a\n  save load's own teardown must not deliver them: `byroredux\u002Fsrc\u002Fsave_io\u002Flive_load.rs` calls `discard_pending_unload_deliveries` and\n  `rebaseline_actor_watch` (no cross-timeline `OnUnload` \u002F `OnEnterBleedout` \u002F `OnCombatStateChanged` \u002F\n  `OnLocationChange`; #6083 `4b8e62d87`, `a_load_discards_the_unload_events_its_own_teardown_raised`). An\n  evicted reference's `TwoStateActivator` \u002F `ScriptVariables` (ObScript object locals included), `ScriptTimer` \u002F\n  `RumbleOnActivate` (#6085 `3b9060701`) and its `ScriptPackage` slot are parked in the eviction row\n  (`cell_loader\u002Freference_state.rs`, `\u002Faudit-gameplay`) and put back over the defaults the re-attach stamps, before the\n  `OnLoad` marker is consumed (#6071\u002F#6072 `611769b16`). A new spawn path that skips these is the recurrence.\n- The `M47.2 scripts:` cell-load summary counters (`recognized`, `trigger volumes`) must be wired or\n  `m47-triggers.sh` is vacuous; exterior stub loops report attach counts. `commands\u002Fquest.rs`\n  (the `quest.*` and `scene.*` console commands, incl. `quest.effects`) stays read-only over `&World` except the explicit start\u002Fstage\n  commands.\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_4.md`\n\n### Dimension 5: Scene \u002F Package \u002F Dialogue \u002F Cinematic Playback\nPaths: `crates\u002Fscripting\u002Fsrc\u002F{scene.rs,scene\u002F**,package.rs,dialogue.rs,cinematic.rs,story_manager.rs,location.rs,animation_graph.rs}`, `byroredux\u002Fsrc\u002Fsystems\u002F{cinematic,npc_dialogue,forcegreet,story_events}.rs`, `byroredux\u002Fsrc\u002Fcell_loader\u002Funload.rs`, `byroredux\u002Fsrc\u002Fasset_provider\u002Fanimation.rs`\nFirst step: `cargo test -p byroredux-scripting -- scene:: package:: dialogue:: cinematic:: story_manager::`; `cargo test -p byroredux --bin byroredux -- cinematic strip_ active_tether npc_dialogue forcegreet story_dispatch_and_forcegreet`\nThe M47.2 MQ101 cart sequence is the first scripted sequence that drives *animation*, not just ECS state.\n- **Scene alias substrate**: `SceneActorBindings` `(quest, alias) → EntityId` is what `resolve_object`,\n  `RunOn::QuestAlias`, and `SceneShowCommand` all resolve through (one entry point — a debug view must not use\n  a different path); an unfilled alias returns `None`, never fabricates an entity;\n  `apply_alias_injections`\u002F`QuestAliasInjectionState` (permanent inventory-grant ledger, saved) must not\n  double-grant after load. **Refresh pre-filters must be exact supersets**: `refresh_scene_actor_bindings`\n  visits per-fill `CandidateIndex` buckets and skips\u002Ffilters condition-only fills via `subject_requirement`\n  (`ConditionFunction::reads_run_on_entity` and `is_deterministic` must stay exhaustive — a stochastic\n  function like `GetRandomPercent` is never folded into a once-for-everyone value, #5645; `run_on_identity`\n  is shared with the evaluator) — a bucket or requirement that excludes a candidate the full fill test or `evaluate` would admit silently\n  unbinds an alias (`subject_requirement_never_excludes_a_passing_subject`,\n  `condition_only_identity_fill_binds_what_the_full_scan_would`).\n- **NPC dialogue selection** (`systems\u002Fnpc_dialogue.rs`, Late exclusive): consumes the player's `ActivateEvent`\n  on an NPC that `running_quests_binding_entity` names (owned DIALs via `DialRecord::quest_refs` — QSTI and,\n  for Skyrim, QNAM). Candidates are **Player-category** topics with an INFO that passes `select_first_info` for\n  this NPC (actor subject, player target); a qualifying **Blocking** DLBR entry opens the conversation and its\n  INFO's TCLT links replace the list; otherwise the list is the **Top-Level** starting topics, and mid-branch\n  children are reached only through links (#5037\u002F#5045 `7ab87c0fb`; FO3\u002FFNV branch-less topics without the DIAL\n  Top-level flag are link-only, #5224 `305363122`). It stamps `NpcDialogueTopic` on exactly one NPC (the\n  surface keys on `DialogueSurfaceState::npc`, #5038); both entry points gate on `player_can_act` and the shared\n  `npc_refuses_dialogue` (dead \u002F `AiCombatState` \u002F unconscious — the whole `collect_unconscious` set, so also knocked\n  down, fleeing or `SetActorsAI 0`, #6287 `aa1016f3c`), also applied by the interaction Talk arm\n  (#5043, `1d31ced2b`) and by `default_activation_blocked` (a script `BlockActivation`, M47.2). `DialogueSurfaceState`\n  lives in `crates\u002Fscripting\u002Fsrc\u002Fdialogue.rs` (re-exported by `npc_dialogue.rs`). UI re-selection goes through `select_topic_by_form_id` and must re-check live\n  ownership. Each menu entry records the INFO that admitted it and a click on a listed topic speaks that INFO —\n  conditions are evaluated once per offer, never re-rolled at selection (#5682 `8daa24105`, #6007 `f7c8f02a7`); an\n  unlisted topic is evaluated fresh. The Late selection system's head ends the open conversation (OnEnd, selection,\n  voice) once `npc_refuses_dialogue` holds for the partner, and `begin_barter` applies the same refusal (#5867\n  `ca3caf411`). **Spoken-line fragments** (#5152, `c59600138`): `DialogueInfoFragments` (TIF_ INFO VMAD, rebuilt\n  from plugin data, unsaved) dispatches the line's OnBegin at selection and the outgoing line's OnEnd on\n  selection change \u002F close via `apply_spoken_info_fragment` (the speaking NPC is passed as `akSpeaker`, M47.2) — the same guard-free executor + journal polling\n  as the quest\u002Fscene dispatchers (`the_spoken_lines_fragments_advance_the_stage`); every native leave path\n  (Close, Escape, the Inventory key) funnels through `App::leave_dialogue_page` → `end_open_conversation`, so\n  the OnEnd dispatches on all of them (#5409 `14b0d33f2`). Greetings and line\n  lifetime (#5367 `14cff35ae`): `open_conversation` falls back to the master's generic greeting topic\n  (`GREETING` Oblivion\u002FFO3\u002FFNV, `DialogueGenericHello` Skyrim — resolved once per load order onto\n  `EsmIndex::generic_greeting_form`, the map scan kept only as the hand-built-index fallback, #5426\n  `411d0eeaf`) when no owned quest topic qualifies; `select_info`\n  first gates each candidate through its owning quest's own condition list (`DialogueQuestConditions`, the CK\n  *Quest Conditions* tab, #5734 `6709eb65e`) — memoised per quest per call, an uncatalogued function fails the gate\n  closed (a hijacker gated only by functions we cannot read must not win on priority; on Oblivion that once declined 87 % of\n  INFOs until #5778 `71e488a26` catalogued the gate functions — re-run `condition\u002Ftests.rs::oblivion_quest_level_dialogue_gates_census`, `#[ignore]`d, after any catalog change), and the list is cloned out and its guard released before `evaluate` (the `QuestStageState` ↔\n  `DialogueQuestConditions` cycle, `8e4c6e40a`); `select_info` never holds `QuestStageState` across an `evaluate` either — the\n  running-quest check takes a short read per question, because `GetStageDone` re-reads the resource and a body-long read was a\n  recursive read behind a parked writer on every FNV force-greet (#6615 `6af13ef37`, pinned by a per-thread warning counter); an INFO whose own CTDA set holds any term `is_modeled` rejects is\n  declined outright (#5752 `bd85de5ea`); then `select_info`\n  collects every passing candidate — the first wins, and a Random first INFO rolls within its positional\n  Random stack (ended by the next passing non-Random INFO or a Random End, #5397 `0436bea5c`) through the seeded\n  `DialogueRandomState`; position is the merged INFO chain (override INFOs fold by FormID after their PNAM\n  predecessor, #5375 `168b81322`, one pass per override since #5644 `0c2bd4d6d` — the merge itself is `\u002Faudit-esm`). Spoken Say-Once INFOs are disqualified\n  per actor through the saved `DialogueSpokenInfoForms` ledger — `(speaker reference FormID, INFO)` pairs since\n  FORMAT_MAJOR 38 (Skyrim ENAM\u002Flegacy-DATA flags now decode; #5300 `f18224b02`; re-selecting the same INFO ends\n  the outgoing line first); a spoken Goodbye closes on\n  the presentation estimate. FO3\u002FFNV\n  INFOs honour their own owning quest (QSTI, #5271 `dbc07e8f0`). **Force-greet**\n  (`systems\u002Fforcegreet.rs`, `ForceGreetDirective` bridge): FO3\u002FFNV Dialogue procedure (`PKDD` topic on\n  `PackRecord::dialogue_topic`) and the Skyrim `ForceGreet` procedure-tree leaf (#5367 `287214103`; a concrete package's leaf and topic are\n  sought on its own tree first, then on its PKCU template — 334 of 339 Skyrim.esm force-greet packs are template\n  instances, #5511 `72e863d80`) walk the NPC to the player and open the topic through the same selection path\n  without activation. The walk goes through `navmesh_path::cached_walk_step` and honours KCC-blocked: a mover\n  held against an obstacle for `LOCOMOTION_STUCK_REPICK_SECS` gives up the approach and opens in place (#5452\n  `6316719ed`), and the step is gated on the shared `ai_locomotion_enabled()` kill switch (the in-radius open\n  stays live and the directive stays pending, #5430 `bd366e300`). Two installers: the\n  `dialogue.forcegreet` console door (any Dialogue package, unconditionally — the drivable one, smoke `dt1`\u002F`dt2`)\n  and FO3\u002FFNV ambient package selection, which installs only from a fully-modeled, player-targeted (PTDT 0x14 or\n  none) Conversation (`PackRecord::dialogue_type` 0) — #5376 `4e58f241d`, `AmbientBehavior::from_package` in\n  `byroredux\u002Fsrc\u002Fnpc_spawn\u002Fai_package.rs` (`\u002Faudit-gameplay`), pinned by `dialogue_ambient_install_declines_unmodeled_offtarget_sayto`;\n  the Skyrim+ tree dialect installs a `ForceGreet` leaf from the ambient driver under the same rule (every leaf condition modelled,\n  target the player or absent; `ai_package\u002Ftree.rs`, AIP-TREE-005, `88c239b35`). A failed open consumes the directive (no per-frame retry);\n  `forcegreet_system` holds every directive while `player_can_act` is false and holds one while the player talks\n  to another NPC (consumed if already talking to the greeter) — #5392 `16544d4c9`,\n  `dead_player_holds_the_forcegreet_directive`, `open_conversation_holds_or_consumes_the_forcegreet_directive`.\n  Pass 2 re-reads the open conversation partner per open (`open_conversation_partner`), so a second same-tick\n  greeter holds instead of stripping the first's line (#5642 `c0c9c9d1b`,\n  `two_same_frame_force_greeters_open_one_conversation`).\n  Walk steps write `Transform` (not `GlobalTransform`) and `PhysicsWorld` is held for the step alone (#5373\u002F#5371\n  `f0c683ef1`). Every opened conversation raises an `AHEL` story event; `raise_hello_story_event` resolves the\n  location *before* taking the `StoryEvent` guard and the open sites scope their `LoadedCellIndex` read to a clone\n  (#5372 `1c15a2270` — the `LoadedCellIndex → StoryEvent → LoadedCellIndex` cycle). The `npc_dialogue_selection`\n  Access row declares the cross-file voice and AHEL hops, and the declaration scan\n  (`npc_dialogue_selection_declares_everything_the_spoken_fragment_path_acquires`) lists `dialogue_voice.rs`,\n  `story_events.rs`, the condition evaluator (`evaluate_function`, incl. the `StoryManagerRng` write and what the VM-bridged\n  getters read) and `apply_at_depth` (the deferred flush, four hops from the entry) explicitly (#5414 `9d8fd4cc9`, #5649\n  `197a9e245`, #6685 `c98a4552f` — the same-file callee walk cannot follow a hop into another file); the row's\n  fragment-effect claims live in `fragment_effect_family_access`, and the crime-faction \u002F crime-gold \u002F ownership claims in\n  functions those subsystems export through `Access::with` (#6701 `c22a9d410`), which the scan follows into the delegate files. A replaced or closed line cuts its voice (`stop_line_voice` →\n  `AudioWorld::stop_sounds_for`; #5432 `40b77828b`). Talk-candidate filtering (`populate_candidates`, `byroredux\u002Fsrc\u002Finteraction.rs`)\n  takes each alias-resource guard alone and builds bulk sets per storage (`running_quest_bound_entities`;\n  #5025 `2a1a7a362` closed two ABBA cycles, #5109 `83d52707e`) — a guard nest reintroduced there reddens the\n  lock-order lane. The egui response page itself is `\u002Faudit-tooling`.\n- **Story Manager** (`story_manager.rs`, `docs\u002Fengine\u002Fstory-manager.md`; #5366 Phases 0-4, live gate `docs\u002Fsmoke-tests\u002Fsm1-story-manager.sh`):\n  `install_story_manager` folds the parsed `SMBN`\u002F`SMEN`\u002F`SMQN` map into an `SmTree`. `SNAM` names the\n  **previous** sibling (xEdit): the head is the `SNAM == 0` (or dangling) member and the fold follows the inverse\n  edges, authored top-down (#5385 `846e4a6dd`, `snam_previous_semantics_walk_head_first`; every member of a\n  sibling group is placed — groups replay in FormID order, not one SNAM chain, #5405 `76a927f8a`; the earlier same-parent\n  check held in both directions, so a direction pin must be asymmetric); a sibling cycle must still terminate\n  (`sibling_cycle_builds_and_dispatch_terminates`).\n  The tree build is linear in sibling-group size and the walk runs on an explicit stack capped at\n  `MAX_WALK_DEPTH` = 64 (#5643 `b79f0d2eb`, `a_huge_sibling_group_builds_and_keeps_every_member`,\n  `a_hugely_nested_tree_walks_without_overflowing_the_stack`).\n  `story_manager_dispatch_system` (exclusive, Update; `StoryClock` synced from `GameTimeRes` first) drains the\n  `StoryEvent` marker (Pattern B) and `PendingScriptStoryEvents` (script-raised `SCPT`, below) and walks the event mnemonic's `SMEN` root: a node whose CTDA set holds any\n  uncatalogued function **declines before evaluation** — neither starts nor consumes, the walk continues to its\n  siblings (#5380 `395d2d831`, `unknown_condition_function_declines_the_node`; the Unknown→0.0 default once\n  passed `== 0` gates vacuously) — otherwise node CTDA runs through the shared M47.1\n  evaluator with `RunOn::EventData` resolved over the positional R1\u002FR2\u002FL1\u002FL2 slots, a passing quest node starts\n  through the canonical `QuestStageState` lifecycle (never a private start path), `FromEvent` aliases fill from\n  the slots via `StoryEventAliasFill` consumed by `refresh_scene_actor_bindings`, which probes slot liveness\n  (despawned id, or `Dead` without ALLOW_DEAD → `StoryManagerEventUnavailable`, never a stale bind; #5419\n  `1dfdeb4f9`, `from_event_alias_skips_stale_and_dead_slot_entities`) and honours the shared reserved set — a slot\n  entity another alias reserved stays unbound unless the alias is Allow Reserved (#6006 `e4afa2b0d`). `DNAM` policies: random parents\n  shuffle (`StoryManagerRng`, whose write guard is taken for the draw alone — `GetRandomPercent` fn 77 re-enters\n  it during `evaluate`, #5628 `faa00de2a`; the `StoryManagerNodeState` pool marks are written after the\n  `QuestStageState` guard drops, a source pin keeping them out of the stages-held region, #6003 `738fbbd5d`), a non-sharing quest node consumes the event only when its own pool\n  queued a start candidate (a passing node with an exhausted pool no longer swallows the event, #5404\n  `76a927f8a`), pools round-robin with\n  `RNAM` reset windows (hours, decoded through xEdit's 1\u002F24 scale, #5386) in `StoryManagerNodeState`. Saved SM\n  resources: `StoryManagerNodeState` and `StoryEventAliasFill` (the CLOC location cursor is session-local and reset on every save load, #5435 `557ead21d`; #5394 `03e51dfad`, column added at FORMAT_MAJOR 35 — the R1\u002FR2\n  slots persist as reference FormIds and re-resolve among resident candidates, session `EntityId`s serde-skipped;\n  `story_event_alias_fill_survives_save_load_as_reference_forms`); `SmTree`\u002Fcursors\u002Fclock\u002FRNG are\n  not-saved-by-design, so a quickload cannot re-fire spent radiants. Update ordering (the M43 polling producers — `register_random_conversations` in `boot\u002Fschedule\u002Fupdate\u002Fquest_scene\u002Fstory_manager.rs` — and the CLOC producer → dispatcher →\n  `quest_alias_refresh_system`, ambient installer → `forcegreet_system`) is pinned by\n  `story_dispatch_and_forcegreet_update_ordering_is_pinned` (`byroredux\u002Fsrc\u002Fscheduler_access_tests.rs`, #5415).\n  Producers: `KILL` (`raise_kill_story_event`, called from all four live death producers — combat, NPC and\n  player drowning, SDK actor-value batch — with the session LCTN as L1; corpse restores deliberately do not\n  raise it, #5434 `c85d50356`; the per-frame CLOC key derivation early-outs on an empty `SmTree`, #5447, and otherwise runs once per cell context through `StoryLocationMemo`, #6335 `80471eb78`),\n  `CLOC` (`systems\u002Fstory_events.rs`, LCTN-granularity key), `AHEL` (every opened conversation), `sm.event` console, the M43 families below, and\n  **`SCPT`**: `Keyword.SendStoryEvent(akLoc, akRef1, akRef2, aiValue1, aiValue2)` lowers to `Effect::SendStoryEvent`,\n  which queues onto `PendingScriptStoryEvents` once the quest-state guards drop (a queue, not a per-entity marker, so\n  several raised in one frame all dispatch — `queued_script_events_in_one_frame_all_dispatch`; the engine producers\n  `CLOC`\u002F`AHEL`\u002F`KILL` share the one-slot `StoryEvent` marker through `raise_story_event`, whose second event on the same\n  entity in a frame queues on `PendingScriptStoryEvents` too — #5647 `eca0c4709`,\n  `two_events_on_one_entity_in_a_frame_both_dispatch`); `SCPT` nodes route on condition fn 576 `GetEventData`\n  (K1\u002FL1\u002FL2 `GetIsID`, location `HasKeyword`, V1\u002FV2 `GetValue`), and a non-optional `FromEvent` alias with an empty\n  slot makes its quest ineligible so the walk continues (`a_required_from_event_alias_without_its_slot_fails_the_start`);\n  **M43 (closed session 106, `docs\u002Fengine\u002Fstory-manager.md` §6.4) added the rest of the producer inventory**, each idle\n  when the tree has no root for its mnemonic: `ADIA` (`systems\u002Frandom_conversation.rs` — NPC-to-NPC random conversations,\n  every number a game setting; the pair is held by `ConversationHold` while the initiator walks over, an enabled\n  `ComplexSceneMarker` suppresses it; `BYRO_NO_RANDOM_CONVERSATIONS=1`) and the natural moving-actors `AHEL` beside it;\n  `LEVL`\u002F`ASSU`\u002F`AIPL`\u002F`REMP`\u002F`CRFT`\u002F`OAAT` in `systems\u002Fstory_events.rs` (`raise_*_story_event`; an integer payload rides\n  `ScriptedStoryEvent { keyword: 0, .. }`, which reads as no `K1`) and `LCLD` beside `CLOC` in `emit_change_location_on_key_change`;\n  `DEAD` (`dead_body.rs`), `IRON` (`iron_sights.rs`), `TMEE` (`mines.rs`), `AOBJ` (`attraction.rs`), `LOCK`\u002F`HACK`\n  (`byroredux\u002Fsrc\u002Flockpick.rs`), and in the scripting crate `CAST` (`magic_effects.rs`), `CHRR` (`relationships.rs`; raised at the deferred flush, not under the quest guards, #6572 `076de275e`), `SKIL`\n  (`skills.rs`), `NVPE` (`words_of_power.rs`) and `JAIL`\u002F`ARRT`\u002F`ESJA` (`jail.rs`). `MNAM`\u002F`XNAM` (Num quests to run \u002F\n  Max concurrent) are consumed — a pass starts up to *Num quests to run* pool quests and stops at the running-pool cap, re-checked\n  when phase B starts a second event's pick in one frame (`max_concurrent_holds_across_events_in_one_frame`); the FO4+\n  node-level `HNAM` window gates the whole node; `FNAM` bit 2 is an **inferred** per-link *shares event* (`af51f6730`; xEdit\n  declares `FNAM` unknown — one-line removal if a source disagrees, not a finding). Every producer's engine-policy numbers and\n  \"Not modelled\" list are in §6.4 — documented gaps. Each engine producer must go through `raise_story_event` (never a bare\n  `StoryEvent` insert, #5647; the `sm.event` debug console still inserts directly), and a new one's reads\u002Fwrites belong in its system's `Access` declaration (#6447). The console doors\n  are `commands\u002Fstory_actions.rs` (`lock.status`\u002F`lock.open`, `word.teach`, `jail.send`\u002F`jail.escape`, `place.at`, `sm.nodes`,\n  `conv.status`, `entity.move`) plus `sm.event`.\n- **Locations & location aliases** (`location.rs`, `docs\u002Fengine\u002Fscripting.md` \"Locations and location aliases\"):\n  `install_location_table` flattens `LCTN` + each cell's `XLCN` into `LocationTable`; a cell-loaded entity's current\n  location is its `CellRoot`'s cell location, the player's is published as `PlayerLocation` by\n  `story_change_location_system` only where the load order authors locations (FO3\u002FFNV\u002FOblivion keep #5447's\n  no-per-frame-work contract). `ALLS` aliases fill in list order with the reference aliases inside\n  `refresh_scene_actor_bindings` (Specific \u002F Reference-Alias \u002F External \u002F Find Matching), the binding is saved\n  (`LocationAliasBindings`), a Find Matching alias never picks a cleared location unless flagged Allow Cleared.\n  Reference-alias fills read *this pass's* location bindings, not the committed ones (#6002 `2424b119c`), and a\n  Location Alias Reference fill is scoped to its bound location (listed by it under the ref type, or standing in it;\n  declines while the location alias is unbound — #6004 `f52a048f3`).\n  Cleared state is `LocationClearState`, fed by `note_actor_death` on the one death path every kill \u002F start-dead\n  actor \u002F save load funnels through — a new death path that skips `reconcile_dead_actor` never clears a location.\n- **Placed-object animation graphs** (`animation_graph.rs`, `asset_provider\u002Fobject_graph.rs`,\n  `object_graph_step_system`, `docs\u002Fengine\u002Fscripting.md` \"Animation graphs of placed objects\" \u002F \"Behavior graph\n  depth\"): `PlayAnimation` sends an event to the reference's `ObjectAnimationGraph`; an event takes the state's own\n  transition (else a wildcard one; `DISABLED` transitions never fire), enters the new state and starts its clip on\n  the object's `AnimationPlayer` (a lazily decoded clip restarts only the graphs whose pose it changes,\n  `start_if_pose_changed`, #6005 `d55940d0a`); the clip's trigger events are scheduled in real time and raised by\n  `object_graph_step_system` (bounded by `MAX_TRIGGERS_PER_STEP` = 1 024; a saturated step drops still-due one-shots\n  too, not just periodic ones, and reports once through the runaway latch — mutually re-arming zero-length triggers\n  used to spend the cap every frame forever, #6010 `26e8afb52`,\n  `one_shots_that_re_arm_each_other_are_dropped_once_a_step_saturates`), and graph-raised events reach `OnAnimationEvent` through registrations\n  (`fragment\u002Fanim_events.rs`). FO4 actors run their own graph (`asset_provider\u002Factor_graph.rs`,\n  `systems\u002Fgraph_locomotion.rs`) — `\u002Faudit-gameplay`.\n  The behavior-graph decode is `\u002Faudit-parsers`; collider\u002Fmotion halves `\u002Faudit-physics`.\n- **Marker patterns** for this domain (Pattern B, drained at consumer head): `Scene{Start,Stop}Request`,\n  `SceneActionCompletionBatch`, `DialoguePresentationEventBatch`, `DialogueLineCompletionBatch`,\n  `ScenePackage*Batch`, `EvaluatePackageRequest`, `MotionTypeChangeRequest` (tail-drains exactly what it\n  snapshotted). Pattern-A `SceneEventBatch`\u002F`SceneFragmentInvocationBatch` feed\n  `scene_fragment_dispatch_system` (Dim 2 order guard). SCEN package `Activate` leaf ordering vs `ActivateEvent`\n  consumers is pinned by the schedule tests.\n- **Playback lifecycle**: `idle_clip_playback_system` starts a scoped player once per serial and drains the\n  request (`idle_request_starts_scoped_animation_player_once_per_serial`); `cinematic_root_motion_system` applies\n  then drains the delta (`cart_exit_root_motion_moves_and_orients_actor_then_drains_delta` — an undrained\n  delta launches the actor); `cinematic_animation_event_system`\u002F`behavior_completion_events` ignore unknown\n  annotations safely and a missing completion event cannot deadlock a quest stage;\n  `vehicle_attachment_system`\u002F`scripted_motion_type_system` flip motion type with the same `Keyframed`\n  discipline `npc_spawn` uses (physics half → `\u002Faudit-physics`); `cinematic_horse_route_system` drives the\n  tethered cart along the horse's XLKR marker chain from `PackageTargetRegistry` (markers are not render\n  entities). Clip conversion (`convert_hkx_clip`: unmatched bones reported not dropped; Z-up→Y-up exactly\n  once; deterministic candidate order in `idle_animation_candidates`) — decode itself is `\u002Faudit-parsers`.\n- **Router vs gate**: `scene_trigger_actor_approach_system_inner` (registered via\n  `make_scene_trigger_actor_approach_system`, persistent scratch) routes an offscreen actor to the lowest-stage\n  reachable `BaseForm` trigger; the gate in `trigger.rs` decides whether it may fire. They must share one\n  eligibility predicate (#4333) and agree on cross-quest phase waits and centerless triggers. Lock order:\n  the `SceneRegistry` read guard is held across the scan and must not invert the canonical scene→quest order\n  (drop before quest resources); the router's conditioned advances are evaluated in a pre-pass *before* the\n  `QuestStageState` guard (the evaluator re-reads it for the GetStage family; source-pinned, #6008 `22ba1f5fe`). Cinematic systems take `Transform` before `ActorCinematicState`\u002F\n  `HorseTetherState` (#4546, `docs\u002Fengine\u002Fecs.md` canonical chain; `BYRO_LOCK_ORDER_CHECK=1` is the gate).\n- **Cinematic retention** (`cinematic_retained_entities` computed once per unload batch;\n  `strip_retained_cell_root(world, victims, retained)` per cell, scoped to `retained ∩ victims`): walk is\n  transitive over `Children` (`active_tether_retains_horse_cart_rider_and_hierarchy`); stripping never\n  orphans an entity from indexes that expect a `CellRoot`; the retention set's lifetime is bounded since\n  #3817 `63bf3347f`: `cinematic_horse_route_system` releases the tether at the XLKR chain's terminal marker, and\n  released entities that lost their `CellRoot` to a mid-tether unload queue on `CinematicReAdoption` (unsaved,\n  session-local ids) for the streaming step (`retry_cinematic_readoption`) to stamp onto the loaded exterior cell\n  root containing them — un-rooted entities are despawn-immune, so a non-draining list is residency leak. Only\n  **parentless** members queue and a root's adoption stamps its whole `Children` subtree (a local `Transform` is\n  not a world position, #5384 `faf8e5682`); the player's subtree is never queued or cell-owned, and\n  `purge_cinematic_retention_state(world, ctx)` releases the still-pending roots' whole `Children` closure\n  (minus the player rig) through `release_entities` at session replacement (#5379 `203be9ed4`; the closure and\n  the render-side release, #5490 `99cd9fd6c`). `release_finished_tethers` clears `vehicle`, so `ExitCart`'s exit\n  heading falls back to the rider's own rotation — equal only because `vehicle_attachment_system` last wrote\n  `vehicle.rotation * vehicle_local_rotation` (`released_rider_exit_heading_matches_the_attached_heading`, #5461).\n  Pins: `systems\u002Fcinematic.rs` (the #3817 lifecycle pair plus `parented_subtree_rides_the_roots_adoption`,\n  `player_rider_is_never_queued_or_cell_adopted`) and `cell_loader\u002Funload.rs`\n  (`pending_readoption_victims_are_the_whole_subtree_closure`, `pending_readoption_victims_spare_the_player_rig`); a release path\n  that strips `vehicle`\u002F`cart_seat` would break the awaited-event exit.\n- Player `CinematicPresentationState`\u002F`PlayerControlState` flags are saved; a flag a consumer never reads is\n  a placeholder (Dim 1) — `disable_saving` is read by `SaveCommand`; `hud_cart_mode` had no reader at #4372.\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_5.md`\n\n### Dimension 6: Legacy ObScript Execution (Oblivion\u002FFO3\u002FFNV; M47.3 quest + object scripts)\nPaths: `crates\u002Fscripting\u002Fsrc\u002Fobscript{,_runtime,_vm,_quests,_objects,_cmd,_actions,_actor_values,_anim,_speech,_state,_ledger,_more}.rs`, `crates\u002Fscripting\u002Fsrc\u002Fobscript_more\u002F`, `crates\u002Fscripting\u002Fsrc\u002Fobscript_effects\u002F`, `crates\u002Fscripting\u002Fsrc\u002F{magic_effects,magic_shaders,script_packages,challenges}.rs`, `byroredux\u002Fsrc\u002Fcell_loader\u002Freferences\u002Fattach.rs` (`attach_scpt_script`, `obscript_dialect_for`, `attach_object_script` call), `byroredux\u002Fsrc\u002Fasset_provider\u002Fscript.rs` (`install_quest_scripts` \u002F `install_object_scripts` \u002F `install_item_scripts` calls), the request consumers `byroredux\u002Fsrc\u002Fsystems\u002F{script_requests,script_queries,revive,knockdown,flee,magic_shader,head_look}.rs`\nFirst step: `cargo test -p byroredux-scripting -- obscript`; `cargo test -p byroredux --bin byroredux -- attach::tests`; `git log -p --since=\u003Clast report> -- crates\u002Fscripting\u002Fsrc\u002Fobscript_vm.rs`\nUntrusted-Input: Yes — `SCDA` bytecode comes from mod-supplied plugins. Distinct from the (unbuilt) `.psc`-side\nSCTX frontend (`ScriptSource::Obscript` placeholder).\n- **`obscript_vm.rs` (pure interpreter) bounds discipline**: statement framing `[op][len][payload]`,\n  `0x1c` explicit-caller escapes, implicit-caller statement calls (line opcode = command id), RPN expression\n  tokens, `[u16 count]` typed arguments, `If\u002FElseIf\u002FElse` nesting with `Return`-inside-arm early exit,\n  1-based SLSD local \u002F SCRO+SCRV reference resolution — compiled reference indices are 1-based into the\n  *interleaved* SCRO+SCRV list (`ScriptRef`; `SCHR.num_refs` counts both; an unresolved explicit caller is\n  declined, #5629). Remote variables (`Quest.var`, `ref.var`) are read and written by ordinal through the synthetic\n  `CMD_GET_REMOTE_VARIABLE` \u002F `CMD_SET_REMOTE_VARIABLE` host calls (`72fd96dfe`;\n  `remote_variables_read_and_write_by_ordinal_on_the_vanilla_bytes`); `exec_remote_set` declines and counts\n  (`CMD_DECLINED`) a malformed or unresolvable target, never storing it as a ref assignment (#5630). Reference\n  variables hold exact form ids (`VmState::ref_locals`). Argument payload reads (#5655 `291af4528`) and an\n  `If`\u002F`ElseIf` condition (#6016 `9a7298283`) are bounded by the statement's own payload, not the script buffer.\n  Every `read_u16`\u002F`checked_add`\u002Fspan end must be bounds-checked\n  and malformed input must yield `BlockOutcome::Malformed`, never panic (`truncated_bytecode_reports_malformed`;\n  `installed_legacy_masters_have_structurally_valid_scda` is the real-data check, `#[ignore]`d). Recursion is\n  capped by `MAX_OBSCRIPT_VM_NESTING` = 32 on both `exec_if_chain` ↔ `run_arm_body` and nested `X` argument\n  decode (`decode_args_at_depth`); guards `excessive_nested_if_chains_are_malformed`,\n  `excessive_nested_x_arguments_are_rejected` — a new recursive path that skips the depth parameter is the\n  regression. The operand stack in\n  `eval_expr`\u002F`apply_operator` must not grow unbounded from a lying token count.\n- **Command and block IDs are empirical** — recovered by aligning each script's `SCTX` with its compiled stream over\n  the vanilla masters (`obscript_tools`), never from a spec. The quest core (`SetStage` 0x1039, `GetStage` 0x103a,\n  `GetStageDone` 0x103b, `StartQuest`\u002F`StopQuest` 0x1036\u002F0x1037, `GetQuestRunning` 0x1038, `GetSecondsPassed`\n  0x100c, `Message` 0x1059, `GetButtonPressed` 0x101f, `GetSelf` 0x10ce) carries a per-game evidence table in the\n  `obscript_quests.rs` module doc (#6015 `3f78f9fe1`): all agree across the three games except `MessageBox`\n  0x1000, which no Fallout script compiles to, so FO3\u002FFNV decline it. Getters run through the M47.1 evaluator (id =\n  `0x1000` + CTDA index); the wider surface is split by family — `obscript_effects\u002F` (the effect bridge: `mod.rs` holds `EFFECT_COMMANDS`, the shared `Binder` and helpers, `getters.rs` the 43 getters' `GETTER_COMMANDS`, the handlers sit in `inventory`\u002F`combat`\u002F`actor_state`\u002F`world_state`\u002F`presentation`;\n  commands lowered to the Papyrus `Effect` their namesake builds and applied through `apply_fragment_guard_free`, so\n  Dim 1's per-primitive rules and Dim 2's lock inventory cover them), `obscript_actions.rs` (reference-bound\n  `Enable`\u002F`Disable`\u002F`MoveTo`\u002F`EVP`\u002F`AddScriptPackage` onto the existing sinks), `obscript_actor_values.rs` (GECK AV\n  codes → AVIF, checked by `obscript_tools avcodes`), `obscript_anim.rs`, `obscript_speech.rs`, and\n  `obscript_more.rs` and its four sibling files (`actions`\u002F`extras`\u002F`state`\u002F`tail`). Every one of those commands is a **row of the command table**\n  (`obscript_cmd.rs`, #6139: id, `Games`, `needs_caller`, handler; each family file exports its own `*_COMMANDS`\n  slice, listed in `FAMILIES`); the host asks the table, not a `match cmd` chain, so an id claimed twice in one\n  game is `duplicate_rows`' test failure, never a shadowed arm, and one id that names different commands per family\n  (`0x116b`, `0x116c`, `0x10db`) is two rows told apart by the loaded game (`Game::of`: Oblivion, Fallout, or\n  `Other`, which runs only the `Games::Any` rows). A row whose id Oblivion numbers differently must be `Games::Fallout`, never `Any` —\n  the table runs ahead of the CTDA-getter route, so an `Any` row answers Oblivion's `IsPlayerInJail` (0x10ab) \u002F\n  `CloseCurrentOblivionGate` (0x10c0) with a Fallout effect (#6478 `598067e2a`, `fallout_only_opcodes_do_not_shadow_oblivions`). The `FALLOUT` \u002F `OBLIVION` census lives in\n  `obscript_more\u002Ftests.rs`, checked against the rows both ways. Only the VM's own statements\n  (`ObScriptCommandHost::call`: `Set`, quest variables, `RemoveMe` \u002F `DropMe`, `GetSecondsPassed`) stay outside it.\n  Handlers that act on the calling actor open through\n  `obscript_effects\u002Fmod.rs::{live_caller, open_actor_effects}` (decline when the caller is not loaded; #6365 `bf27df84c`,\n  source guard `handlers_open_through_the_live_caller_helpers`, which reads every production file of the split through `SOURCES`) — a hand-spelled `caller_of` + `live` prologue is the\n  recurrence. Anything unmodelled\n  is a **traced no-op returning 0, counted per owner in `ObScriptQuestTimers.unknown_commands`, never faked**\n  — a command that returns a guessed value, or answers state the engine does not keep, is a finding\n  (*feedback_no_guessing*; #6221 `c1b2b1d12` turned `GetIsPlayerBirthsign`, `GetAnimAction` and every\n  `IsPlayerActionActive` index but the tracked jump into `Action::Declined`, pinned by\n  `untracked_state_declines_instead_of_answering_a_constant`; `obscript_more` answers only from a named page, engine state or the ledger); the\n  remaining unmodelled tail and each command's blocker are tabled in `docs\u002Fengine\u002Fscripting.md` (M47.3 phase 3) —\n  not new findings. Dialect tables (xNVSE vs xOBSE opcode\n  numbering, `ObscriptDialect`) stay separate because the same number names unrelated commands.\n- **Message \u002F MessageBox** (`5182f7817`): `decode_message` parses the `[u16 length]` text, the set\u002Fif-format variable\n  list and the button strings out of the statement's own argument region (untrusted: every length is checked against\n  `end`; a payload that fails to decode is declined and counted `CMD_DECLINED`, never shown half-decoded). The\n  decoded `ObScriptMessage` reaches the host's `message`, which substitutes the variables (`substitute_numbers`\n  reads width before precision, so `%0.f` \u002F `%2.0f` give zero places, #5789 `1502fbd3d`; `[+- 0#]` flags, minimum\n  field width and `%e`\u002F`%g` per the CS *MessageFormatting* template, #6014 `a4e524c9c` — an unparsed spec used to\n  shift every later argument; mod width\u002Fprecision clamped, #6011) and queues it through\n  `messages::show_obscript_message`, which drops any unread answer (the CS: −1 while a box is open, #6013\n  `cbee28109`); `GetButtonPressed` consumes the last answered box from one global slot (`messages::take_button`, any\n  quest's first call gets it — CS wiki contract, #5790 `173f9e155`, `obscript_button_answer_is_consumed_globally_once`),\n  −1 otherwise.\n- **`obscript_quest_tick_system`** (exclusive `Stage::Update`): runs only *running* quests' GameMode block — due\n  quests in FormID order, never `QuestStageState`'s `HashMap` order (#6013 `cbee28109`; two quests polling\n  `GetButtonPressed` or cross-`SetStage`ing in one tick raced per process) — each on\n  `quest_script_interval` — the authored `QUST` delay (FO3\u002FFNV), overridden by a runtime `SetQuestDelay` (saved in\n  `ObScriptQuestLocals`), either one ≤ 0 meaning the INI default `QUEST_SCRIPT_INTERVAL_SECS` = 5 s (GECK\n  *SetQuestDelay*). It runs through `ObScriptCommandHost` (generic over its owner — a quest, a placed reference or an\n  inventory item), which lowers onto the same\n  `QuestStageState`\u002F`Globals` and emits the same stage events as the fragment path (so Dim 2's journal and\n  cascade rules apply). Timers\u002Feffect ring (`ObScriptQuestTimers`, `ObScriptEffectLog`, cap 64) are unsaved by\n  design — elapsed time restarts on load (documented residual, not silent save loss). Quest-script **locals persist**\n  between GameMode runs in the saved `ObScriptQuestLocals` (seeded into each run's `VmState`, stored back after the\n  run; an unassigned slot reads 0) and condition fn 79 `GetQuestVariable` reads them on Oblivion\u002FFO3\u002FFNV only\n  (`f67d82b3c`; the game split and the cross-tick read are pinned since #5787 `a5e5346d0` by\n  `get_quest_variable_uses_obscript_locals_only_for_legacy_game_paths` and\n  `quest_game_mode_local_is_read_on_the_next_tick_and_by_condition_79`); `StartQuest`\u002F`StopQuest` attach\u002Fdetach the\n  script loop consistently. The 255-script corpus gate in `obscript_quests.rs`\n  (`vanilla_oblivion_quest_scripts_execute_and_setstage`, `#[ignore]`d) resolves Oblivion.esm via\n  `test_paths::oblivion_esm()`, panics under `BYROREDUX_REQUIRE_GAME_DATA=1` instead of returning green, and runs in\n  `.github\u002Fworkflows\u002Freal-data-gates.yml` (#5088 `1377d3463`).\n- **Result scripts** (`obscript_results.rs`, `6db47b0e4`): the compiled streams a FO3\u002FFNV\u002FOblivion `QUST` stage item and\n  a dialogue `INFO` carry inline (`QuestStageLogEntry::result_script`, `result_script_begin`\u002F`_end`).\n  `obscript_stage_result_system` (exclusive `Update`, after `obscript_quest_tick_system`) polls the quest journal as\n  its own subscriber (`OBSCRIPT_STAGE_QUEST_EVENT_SUBSCRIBER`, Dim 2) and runs every stage item whose conditions pass\n  (GECK: all of them, not the first) plus the stages they set, up to `MAX_STAGE_SCRIPT_ROUNDS` = 16\n  (`a_stage_cycle_is_bounded`); an INFO's Begin\u002FEnd scripts run with the speaker as implicit reference. Documented\n  deviation: the calling script finishes before the stage's items run (the original ran them inside the\n  `SetStage` statement). Same decline rules as the other hosts: an `If` whose condition reads a declined getter runs no\n  arm. Any new `SCDA` path here is untrusted input (above).\n- **Sound commands** (`systems\u002Fscripted_sound.rs`, `crates\u002Fscripting\u002Fsrc\u002Fsound_requests.rs`): `PlaySound` is\n  non-locational (GECK) — its request carries `NON_LOCATIONAL_SOURCE` (form 0, never a placement) and plays at the\n  `AudioListener` entity, the player body only when none exists (`listener_or_player`; #6226 `f04c3433d`,\n  `a_non_locational_play_is_heard_at_the_listener`); `PlaySound3D` and a Papyrus `Sound.Play` keep their source, and a\n  record's 2D bit takes the listener too. All script plays use the byte-budgeted voice cache and skip decode on an\n  inactive `AudioWorld` (#6281 `41b53ab41`); the audio engine itself is `\u002Faudit-audio`.\n- **Ledger honesty** (#6190 `7e867cf47`): a command whose value no system, gate or UI reads back declines instead of\n  storing it in the saved `ObScriptLedger` and reporting done (`AddTopic`, `ModDisposition`, `SetQuestObject`,\n  `SetItemValue` were removed; `GetTalkedToPC` is written by `apply_selection`). Mod-supplied accumulators saturate\n  (`ModCrimeGold`\u002F`ModDisposition`, #6187 `50e743a56`). The compiled and source `If`\u002F`ElseIf`\u002F`Else` line forms share one\n  `parse_conditional` recursion that enforces `MAX_LEGACY_OBSCRIPT_NESTING` once (#6159 `3c553b7ca`). Same rule since 2026-11: `SendTrespassAlarm` declines\nuntil trespass is routed into the crime runtime (#6511 `baa93fe87`); Oblivion's caller-scoped `GetCrimeGold` \u002F `SetCrimeGold` \u002F\n`ModCrimeGold` \u002F `GetGold` honour the calling reference — no caller or the player's own keeps the player path, any other named\nactor declines (crime gold) or counts that actor's own `Gold001` (`GetGold`), and an unloaded caller never falls through to the\nplayer (#6510 `a48017e7b`); `MenuMode` reads its per-game codes from the `MenuCodes` resource, so Oblivion answers barter 1008\n(#6620 `16d9e18f3`).\n- **Object and item scripts** (`obscript_objects.rs`, M47.3 phase 2; live gate `docs\u002Fsmoke-tests\u002Fm47-3-obscript.sh`\n  on FNV): a placed reference whose base carries an `SCRI` gets an `ObScriptInstance` at attach; blocks run on the\n  events the engine already raises — `GameMode` every frame per loaded scripted reference (not an `UnloadedReferenceStub` \u002F `RemoteSceneActorStub`, #6220; the\n  residency question is asked per due instance, #6333 `4f6cac254`), `OnLoad`, `OnDeath`,\n  `OnActivate`, the trigger trio, `OnHit`\u002F`OnHitWith`, `OnStartCombat`\u002F`OnCombatEnd`, the package blocks,\n  `SayToDone`, the item blocks `OnAdd`\u002F`OnDrop`\u002F`OnEquip`\u002F`OnUnequip`, `OnReset` (a cell's pending reset lives for\n  its whole budgeted load — each pass marks the scripted references that appeared since, once each — and the loaders'\n  `obscript_state::cell_load_finished` makes the next pass retire it, scriptless or cancelled cells included; #6102\n  `2efed9843`; the worldspace persistent CELL's apply job retires it too, #6219 `a99b2f461`, and a save load's own\n  reload drops the resets it raised via `discard_pending_cell_resets`, #6238 `078df54e1`,\n  `live_load_drain_discards_the_cell_resets_its_reload_raised`), `OnDestructionStageChange`, and\n  the scripted-effect blocks in `magic_effects.rs`. A block written for one reference (`Begin OnTrigger player`)\n  runs only for it (`BlockInfo`). **`OnActivate` replaces default processing**: `has_activate_block` feeds\n  `default_activation_blocked` (the same gate Papyrus `BlockActivation` uses) and the script's own `Activate`\n  queues the native activation — but an `OnActivate` run that declined any command or came back malformed lets the\n  default go ahead (a door nothing can open is the failure mode). Block ids (`BLOCK_*` in `obscript_vm.rs`) differ\n  between Oblivion and the Fallout pair for 0x1a\u002F0x1b (`OnTriggerActor`\u002F`OnTriggerMob` vs enter\u002Fleave) — a block\n  read in the wrong game's meaning is the finding. Object locals live in the saved `ScriptVariables` and ride the\n  eviction row (#6071, Dim 4). Systems: `obscript_object_system` before `reference_script_event_system` (which drains\n  `OnDeathEvent`), `obscript_hit_system`\u002F`obscript_combat_system` after every `HitEvent` producer,\n  `obscript_destruction_system`, the Late `obscript_item_system`; `BYRO_NO_OBSCRIPT_OBJECTS` is the kill switch. New\n  saved state (`ObScriptLedger`, the `obscript_state` stores, `magic_effects` — each `register_saved`) is a\n  `FORMAT_MAJOR` question for `\u002Faudit-save`.\n- **Legacy load-order\u002Fextender path**: `attach_scpt_script` resolves SCPT via `ScriptRegistry` (logs an error\n  when the resource is absent); dialect selection is by *profile row*, pinned by\n  `obscript_dialect_follows_the_profile_not_the_game_kind`; source-less FNV\u002FFO3 bytecode is decoded\n  structurally (`decode_extender_calls`, only registered xNVSE\u002FxOBSE opcodes) and FO3 must not apply the\n  xNVSE table (`source_less_fo3_scpt_does_not_apply_xnvse_opcode_table`). Arguments\u002Fbytes obey the SDK caps\n  (`MAX_SCRIPT_CALL_BYTES`, `MAX_SCRIPT_STRING_BYTES`, `MAX_LEGACY_OBSCRIPT_NESTING`); the compatibility analysis\n  caps findings per script (`MAX_COMPATIBILITY_FINDINGS_PER_SCRIPT`) and retained entries per registry\n  (`MAX_COMPATIBILITY_RETAINED_ENTRIES`), logging the first truncation (#6024 `fcead3b9d`).\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_6.md`\n\n### Dimension 7: Provider \u002F Extender-Compatibility Layer (SKSE, JContainers, StorageUtil, ModEvent seam)\nPaths: `crates\u002Fscripting\u002Fsrc\u002F{papyrus_provider\u002F**,compatibility.rs}`, `crates\u002Fscripting\u002Ftests\u002Fextender_compat_e2e.rs`, `byroredux\u002Fsrc\u002Fextensions\u002F`, `crates\u002Fpex\u002Fsrc\u002Fcall_sites.rs` (consumer)\nFirst step: `cargo test -p byroredux-scripting -- papyrus_provider compatibility`; `cargo test -p byroredux --bin byroredux -- boot::schedule::system_access_declaration_tests`\nThis layer (~8.7k LOC scripting-side: `papyrus_provider\u002F` + `compatibility.rs`, incl. tests) was a reported coverage gap through 2026-09-14 (only its *seams* were\naudited). Its SDK half (`crates\u002Fsdk`: StorageUtil\u002FJContainers verbs, typed script values, limits, manifests)\nis `\u002Faudit-tooling`; audit here the runtime that consumes it.\n- **Untrusted-input**: preflight\u002Flowering run on `.pex`-derived data and provider manifests. `compatibility`\n  caps its script table (`MAX_COMPATIBILITY_SCRIPTS`, `truncated()` must surface); lowering recursion is capped\n  (`MAX_PROVIDER_HANDLER_NESTING` = 32 — an `elseif` chain counts its clause index into the depth so lowering and\n  the per-dispatch `validate_provider_statements` agree, #5656; `MAX_PROVIDER_FRAGMENT_BARRIERS` = 64 —\n  cap-before-descend); a literal `Utility.Wait` is capped at `MAX_PROVIDER_WAIT_SECONDS` (one game day) at\n  lowering so a mod cannot park immortal continuations in the bounded 4 096-slot queue, #5657 `05d8d5864` — the\n  same bound is shared by the fragment lowerer, the VM and `FragmentExecutionQueue`, #5681 `ef130cd6c` (Dim 2);\n  `execute_statements` runs on an explicit cursor stack, not a recursion per executed `If` (#5635 `afa5186a1`,\n  20 000 sequential `If`s on a 256 KiB stack; nesting depth is threaded through receiver chains too, and saved\n  `Wait` values obey the same cap, #6025); `papyrus_provider_system` groups ModEvent registrations by entity\n  once per frame and only when events are pending (#5640 `34a47ba81`). ModEvent runtime (#6018–#6025, `2f4b59041`):\n  registrations whose registrant no longer carries a provider program are pruned (entity ids are never\n  reclaimed), delivery runs under `MAX_PAPYRUS_MOD_EVENT_DELIVERIES_PER_FRAME` = 1 024 with the rest left queued in\n  order, owner FormIDs resolve per entity on demand, and a failing provider call keeps the registrations collected\n  before it. A reference's provider `OnInit` runs once, its first-init flag saved in `QuestScriptVariables` under\n  the reference FormID (#6017 `0b1f1545f`). Value sizes\n  obey `MAX_SCRIPT_ARRAY_ELEMENTS`\u002F`MAX_SCRIPT_CALL_BYTES`\u002F`MAX_PENDING_PAPYRUS_MOD_EVENTS` (256) \u002F\n  `MAX_PAPYRUS_MOD_EVENT_REGISTRATIONS` (4 096). `execute.rs` has\n  `unreachable!` arms guarded by \"validated …\" invariants — each must be truly established by lowering.\n  The `catching_panics` net (#3948) wraps the translate\u002Flower path; check whether runtime execution in\n  `papyrus_provider_system` has any equivalent (none found 2026-10-20: no `catch_unwind` under `papyrus_provider\u002F`, nor around the VM's run in `fragment\u002Fvm\u002Finterp.rs` — only the VM's ahead-of-time checks joined the net, #6000).\n- **Decline-on-unmodeled at the seam**: a provider call that cannot be typed declines the whole fragment\u002F\n  handler (`lower_provider_call` errors → `None`), it never lowers a prefix and silently drops the tail — nor\n  lowers a script's provider handlers while leaving its other handlers inert (`MixedScript`, #6021, Dim 1); a\n  `PapyrusProviderRuntime::default()` with a non-empty catalog but `callback: None` is not servable (Dim 1).\n- **Continuation persistence**: `PapyrusProviderContinuationQueue` and `FragmentExecutionQueue` are saved\n  resources; continuations must stay principal-owned and typed (no raw closures or process-local handles).\n  Locals holding `ScriptValue::Entity(EntityRef)` are session-scoped (`world_generation`) — they are dropped\n  after load by `drop_entity_bound_continuations` (#4139; `\u002Faudit-save` Dim 5 owns the ordering); any new\n  saved shape here is a `FORMAT_MAJOR` question (`\u002Faudit-save` Dim 2).\n- **Lock\u002Faccess**: `papyrus_provider_system` and `legacy_obscript_load_order_system` declare what they acquire\n  (the schedule tests scan bodies to 3 call hops); `extension_*` adapters run before `event_cleanup_system`\n  (`extension_event_adapters_run_before_transient_cleanup`). Any new SDK-state exposure that nests a resource\n  lock against `QuestStageState`\u002F`Inventory`\u002Fetc. is a Dim 2-class finding.\n- **Provider resolvers\u002Fcallbacks** (`set_papyrus_provider_{runtime,entity_resolver,form_resolver,\n  mod_event_publisher}`, `set_extension_script_function_invoker`, `set_legacy_obscript_content_catalog`) are\n  installed by boot\u002Fextension setup; an uninstalled resolver must degrade to a decline, not a panic.\n- Census\u002Finstrument: `crates\u002Fscripting\u002Fexamples\u002Fextender_preflight.rs`; docs: `feature-matrix.md`\u002FROADMAP M47.2\n  rows must acknowledge this layer (SCR-ORCH-2026-09-06-01).\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_7.md`\n\n## Phase 3: Merge\n\nCombine `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_*.md` into `docs\u002Faudits\u002FAUDIT_SCRIPTING_\u003CTODAY>.md`: **Executive Summary**\n(shipped vs deferred; findings by severity; **untrusted-input verdict** for the runtime-side decoders —\n`SCDA`, provider manifests — must be NO panic\u002FOOB\u002FOOM\u002Foverflow; frontends' verdict lives in the newest\n`AUDIT_PAPYRUS_*`) · **Decline-Invariant Audit** (every recognizer\u002Fcomposer\u002Feffect decline point ×\nverified-conservative vs leaks-a-partial-lowering) · **Runtime Lifecycle Matrix** (marker drain coverage;\ntwo-phase lock-drop per system; cascade bound; edge-trigger seed; CTDA OR-precedence; journal subscribers) ·\n**Findings** (CRITICAL first, deduplicated) · **Future-Phase Readiness** (invariants pinned for ObScript\nphase 2, alias follow-ups). Dedup ownership: marker-drain coverage = Dim 3 (pointers from others);\n`translate_pex` clean-`None` = Dim 1 (pointer from Dim 4); half-extent convention = Dim 4; cinematic router\u002F\ngate agreement = Dim 5 (pointer from Dim 3).\n\n## Phase 4: Cleanup\n\n`rm -rf \u002Ftmp\u002Faudit\u002Fscripting`; tell the user the report is ready; suggest\n`\u002Faudit-publish docs\u002Faudits\u002FAUDIT_SCRIPTING_\u003CTODAY>.md` (domain label `scripting`; add `quests` for\nQUST\u002Falias findings and the matching `game:*` for one title's scripts).\n","# Scripting Runtime Audit (M30 \u002F M47.0–M47.3)\n\nRead `.claude\u002Fcommands\u002F_audit-common.md` and `.claude\u002Fcommands\u002F_audit-severity.md` for shared protocol.\n\nAudit `crates\u002Fscripting\u002F` and its engine-side wiring: the AST→ECS **recognizer chain** whose load-bearing\ninvariant is *decline-on-any-unmodeled-term*, the **Papyrus VM** (`fragment\u002Fvm\u002F`, M47.2) that interprets the\nfragments \u002F reference \u002F alias scripts the lowering declines — its own contract is *check ahead of time, run whole\nor not at all* (`check_function` \u002F `check_reference_script`; a native that declines its actual values stops the\nrun, it never guesses) — fragment \u002F quest-stage dispatch, the ECS event runtime, the cell-loader attach path,\nscene\u002Fpackage\u002Fcinematic playback, and the two legacy\u002Fcompat execution layers (compiled ObScript, Papyrus\nprovider calls). **A partial or approximate lowering is worse than none**: an inert unrecognized script is safe;\na wrongly-lowered one corrupts game state with no fallback (the scripting analogue of NIFAL's no-fabrication rule).\nBoth fragment paths (lowered `Effect` list, VM `Effect::Interpret`) end in the same `apply_effects` runtime, so\nDim 2's lock rules cover both.\n\n**Split**: the `.pex` reader\u002Fdecompiler (`crates\u002Fpex`) and the `.psc` lexer\u002Fparser (`crates\u002Fpapyrus`) are\n`\u002Faudit-papyrus` (untrusted-input bounds, decompiler soundness, depth caps). `crates\u002Fhkx` parsing →\n`\u002Faudit-parsers` (this skill keeps only cinematic *playback* of decoded clips, Dim 5). `crates\u002Fsdk` →\n`\u002Faudit-tooling` (this skill keeps the provider\u002Fextension *seam*, Dim 7). AI-package procedure runtimes and\n`systems\u002Fcombat_ai.rs` → `\u002Faudit-gameplay`; scheduler\u002Flock shape in general → `\u002Faudit-ecs`,\n`\u002Faudit-concurrency`.\n\n**Architecture**: Orchestrator; each dimension is a Task agent (max 3 concurrent).\n\n## Scope\n\n`crates\u002Fscripting\u002Fsrc\u002F` (~124k LOC incl. tests; re-measure with `find crates\u002Fscripting\u002Fsrc -name '*.rs' | xargs wc -l`): `translate\u002F` (`mod`, `source`, `archetype`, `compose`, `effects`, `tables`,\n`recognizers\u002F{quest_stage_gate,rumble,two_state_activator}`); `fragment.rs` + `fragment\u002F{effects,populate,\nstate,systems}.rs` with the per-family appliers in `fragment\u002Feffects\u002F{resolve,deferred,inventory,placement,scene,lock,\nplayer_control,vehicle_cinematic,ai_combat,quest_scoped,evaluate,guards,quest_vars,actor_values,actor_lists,\nlocation_alias,reference_state,player_stats,messages}.rs` (#5468 split; #6142 `b269744f2` moved the older inline\n`apply_effect` arms into the last seven and `evaluate_guard`'s into `guards.rs`); the **Papyrus VM family**\n(M47.2): `fragment\u002Fvm\u002F` (`interp.rs` the interpreter, `checker.rs` + `natives\u002F` the `check_*` ahead-of-time checks; `vm.rs` is a ~136-LOC hub), `fragment\u002Fbudget.rs` (per-frame\nstatement budget, #5763), `fragment\u002Fdispatch.rs` (`run_papyrus_call` \u002F `flush_advances`, the one budget→defer→apply\ntail every Papyrus-call system shares, #5797 `e27c93a97`), `fragment\u002F{reference,alias_scripts,owners}.rs` (reference \u002F alias script instances and\nevent delivery), `fragment\u002F{updates,distance,events,hits,anim_events}.rs` (registration families),\n`fragment\u002F{package,perk,terminal}.rs` (PACK\u002FPERK\u002FTERM fragments); `quest_stages.rs`, `globals.rs`, `vm_state.rs`,\n`events.rs`, `cleanup.rs`, `timer.rs`, `recurring_update.rs`, `condition\u002F`, `trigger.rs`, `player_control.rs`,\n`equipment.rs`, `registry.rs`; `scene.rs` + `scene\u002F{playback,quest_alias}.rs`, `package.rs`, `dialogue.rs`\n(incl. `DialogueSurfaceState`, `DialogueQuestConditions`), `cinematic.rs`, `combat.rs`\n(`FactionRelations`, `AiCombatState`), `magic.rs` (`SpellCatalog`\u002F`SpellList`\u002F`RaceSpells`, #4415), `story_manager.rs` (#5366 SM dispatch: `SmTree`, `StoryEvent`, `story_manager_dispatch_system`), `load_order.rs`\n(`LoadOrderIdentity`, slot↔`PluginId` bridge); `animation_graph.rs` (placed-object behavior graphs); the M47.2\n**native-state stores** the VM's primitives write and conditions read — one small saved module each (CK page quoted\nin its module doc; each is a `FORMAT_MAJOR` question for `\u002Faudit-save`): `quest_variables.rs`, `location.rs`,\n`bleedout.rs`, `messages.rs`, `keywords.rs`, `relationships.rs`, `faction_changes.rs`, `alias_overrides.rs`,\n`alias_collections.rs`, `created_references.rs`, `perk_entry_points{,\u002F{bodies,catalog,gates}}.rs` (the hook catalog + gate + body split of #6654), `destruction.rs` and the sibling\n`activate_parents`\u002F`crime_*`\u002F`jail`\u002F`guards`\u002F`followers`\u002F`map_markers`\u002F`menus`\u002F`ownership`\u002F`scanning`\u002F`skills`\u002F`speechcraft`\u002F\n`*_requests`\u002F`tempering`\u002F`words_of_power` files (subsystems migrated by #5802 export their own `install(world)` + `register_saved(registry)`;\n`build_save_registry` calls each at its old row position — the schema fingerprint is order-sensitive); the M47.3 ObScript family\n`obscript{,_runtime,_vm,_quests,_results,_objects,_cmd,_actions,_actor_values,_anim,_speech,_state,_ledger,_more}.rs`\n+ `obscript_effects\u002F` (`mod.rs` the effect table + shared helpers; `getters`\u002F`inventory`\u002F`combat`\u002F`actor_state`\u002F`world_state`\u002F`presentation`, #6355 `aa29774ec`) + `obscript_more\u002F` with its sibling runtimes `magic_effects.rs`\n(caster runtime), `magic_shaders.rs`, `script_packages.rs`, `challenges.rs` (Dim 6); `registration.rs` (the crate's\n`register`, #5806 — a flat list of per-subsystem `install(world)` calls since #6706 `70e58334f`, pinned by\n`register_installs_the_same_resource_set`); `papyrus_provider\u002F`,\n`compatibility.rs`; `papyrus_demo\u002F` (reference scripts\u002Ftest fixtures; `ScriptRegistry` is the pre-Skyrim\n`SCRI`→`SCPT` extension point — boot no longer seeds it). Engine side: `byroredux\u002Fsrc\u002Fcell_loader\u002Freferences\u002F\n{attach,synth_child}.rs`, `cell_loader\u002F{spawn,exterior,unload,created,graph_nodes}.rs` + `cell_loader\u002Fexterior\u002F{persistent,apply_job}.rs` (#6271 split of the exterior hub; `created.rs` places\u002Fspawns\nCreated Object \"At\" references; `graph_nodes.rs` keeps the NiNode tree of graph-animated props), `asset_provider\u002Fscript.rs`\n(`attach_vm_reference_script`, `check_running_quest_alias_scripts`, `ProviderScriptLibrary`, `DecompiledPexCache`,\n`ensure_obscript_tables`), `scene\u002Fscene_runtime.rs` (`populate_scene_runtime` — the ObScript quest\u002Fobject\u002Fitem installs, ambient\npackages and the quest-fragment walk — and `materialize_scene_actor_alias_stubs`; both left `asset_provider\u002Fscript.rs` in #6716 `6413d542b`),\n`asset_provider\u002F{object_graph,actor_graph}.rs`,\n`systems\u002F{cinematic,npc_dialogue,forcegreet,story_events,scripted_sound,trap_hits,projectiles,archetype_idle}.rs`\n(consumers of the VM's request markers), the M43 Story Manager producers `systems\u002F{random_conversation,attraction,mines,dead_body,iron_sights}.rs` (registered in `boot\u002Fschedule\u002Fupdate\u002Fquest_scene\u002Fstory_manager.rs`) and `commands\u002Fstory_actions.rs` (their console doors) and the M47.3 ObScript request consumers\n`systems\u002F{script_requests,script_queries,revive,knockdown,flee,magic_shader,head_look}.rs`, `commands\u002Fquest.rs` (`sm.event`, `dialogue.forcegreet`), `boot\u002Fschedule\u002F` (one `register_*` file per subsystem under `update\u002F\u003Cdomain>\u002F`, `late\u002F` and `post_update\u002F`, #6703\u002F#6704 `22e0f71fc`\u002F`49aa54e36`; a cross-subsystem order the old file position stood for is a named `run_after`\u002F`run_before` constraint beside the later system, #6702 `065aac9c4`; `Access::with` lets a subsystem export its own declarations, #6701 `c22a9d410`), plus `crates\u002Fplugin\u002Fsrc\u002Fesm\u002Frecords\u002F{index,\nscript_instance}.rs` (VMAD retention; decode is `\u002Faudit-esm`).\n\nGround truth: `docs\u002Fengine\u002Fscripting.md` (the M47.2 sections — \"The Papyrus VM\", \"The frame budget\", \"Reference\nscripts on the VM\", the registration families — carry each primitive's CK-page contract and its \"Not modelled\"\nlist; those lists are documented gaps, not findings), `story-manager.md`, `m47-0-design.md`, `m47-2-design.md` (recognizer + \"no opcode\nsemantics guessed\"), `m47-2-recognizer-scaling.md` (corpus: handler vs fragment populations, decline-the-tail),\n`m47-3-quest-alias-design.md` (its \"Remaining subsystem boundary\" predates M47.2: Created Object \"At\"\u002F\"In\"\nfills, the `LCTN` runtime + location aliases, `FromEvent` fills and script-filled `RefCollectionAlias`es have\nsince shipped; still real gaps — world-query search across unloaded data, condition\u002Ffill-type collection fills,\ninjected packages\u002Fspells\u002Fkeywords\u002Fnames\u002Fvoice-type\u002Fcombat overlays — don't re-file as discoveries), crate docstrings\n(`translate\u002Fmod.rs`, `fragment.rs`, `fragment\u002Fvm\u002F`, `fragment\u002Fbudget.rs`, `cleanup.rs` marker house rules).\n\n**Known-open — cite, don't re-file** (verified 2026-11-09 with `gh issue view`): #5764 (interpreter deferral ~0.8 µs a delivery; a value-called function or an\narray\u002Fstruct-holding frame cannot suspend — the budget-split residual; its idle-walk half shipped as `11685934d`,\nDim 2),\n#4113 is open but lives in `crates\u002Fpapyrus`\u002F`crates\u002Fpex`\n(`\u002Faudit-papyrus`). Closed since the 2026-11-06 sync: #5802 (closed 2026-11-07; hub-file growth — every subsystem migrated to its own\n`install` + `register_saved` + `register_*_systems` file, `bde3478db`\u002F`e619dbbaf`, `93bcda9bc`, and the Part-of commits #6701-#6707\n`c22a9d410`..`5c983ecd0`: `register_late_systems` is a flat 14-call list, the Update domains and `register_post_update_systems` are flat\ncall lists into one file per subsystem, `Scheduler::run_before`\u002F`run_after` replace file position as the order carrier). Closed since the\n2026-10-31 sync: #5586 (the `mq101_conformance` example's oversized `run` — fixed\n`d7c47d741` (`run` 44 lines, one `check_*` per stage), then #6360 `01f48c929` split the file into\n`crates\u002Fscripting\u002Fexamples\u002Fmq101_conformance\u002F{main,ast_probe,scenes,packages,scripts,fragments,report}.rs`; longest\nfunction ~165 lines, `scenes.rs::check_scene_runtime`; the issue was closed 2026-11-03), #6688 (the scripting crate's Pattern-B\nmarker scans became runs of the consumers — `every_documented_pattern_b_marker_drains_in_its_named_consumer`,\n`pattern_b_markers_survive_event_cleanup`, `byroredux\u002Fsrc\u002Fsystems\u002Frequest_drain_tests.rs`, `58caf1799`; Dim 3), #6684\u002F#6685\n(the schedule-order guards read the built schedule — `build_scheduler()` \u002F `access_report()`, `2a02c5446` — and\n`system_access_declaration_tests` reads acquisitions from a `syn` tree in `byroredux\u002Fsrc\u002Facquisition_scan.rs`, depth 3\nsame-file callees, `c98a4552f`; Dim 2), #6554\u002F#6558\u002F#6545 (CTDA getters the ObScript VM already answered\ncatalogued — `CATALOG` 88 → 102 with #6657's `IsWeaponSkillType` (103 with #6654's `GetPermanentActorValue`), Oblivion's four `OBLIVION_CONDITION_GETTERS`,\n`6dec5c4a9`\u002F`612f876f9`\u002F`d3db6fd58`; Dim 3), #6570 (CTDA 659 foreign on Fallout 4, `57a49a4d4`), #6571\n(`tempering_multiplier` takes back the `SceneAliasCandidate` it lends, `9e033a595`), #6572 (`CHRR` queues on\n`DeferredFragmentEffects::relationship_events` and raises at the flush, not under the quest guards, `076de275e`), #6573\n(`SendPlayerToJail` deposits into the evidence chest before taking anything, `81332fc38`) and #6569 (declines with no\n`CrimeModel`, `dcc3dc681`), #6510\u002F#6511 (Oblivion's caller-scoped crime-gold getters honour the caller, `a48017e7b`;\n`SendTrespassAlarm` declines, `baa93fe87`), #6615 (`select_info` takes a short `QuestStageState` read per question, not a\nbody-long one, `6af13ef37`), #6619 (a scripted `AddPerk` raises a held perk's rank on FO3\u002FFNV\u002FFO4, `2d9c5802c`), #6620\n(`MenuMode` answers Oblivion's barter code 1008 from a `MenuCodes` resource, `16d9e18f3`), #6716 (`populate_scene_runtime` \u002F\n`materialize_scene_actor_alias_stubs` live in `scene\u002Fscene_runtime.rs`, `6413d542b`). Closed since the 2026-10-27 sync: #6355 (*obscript_effects.rs* crossed 2 000 LOC after the #6139 table conversion — now\n`obscript_effects\u002F`, `aa29774ec`), #6460 (ten FO3\u002FFNV script getters — `IsChild` 365, `GetTalkedToPC` 50, `GetHasNote` 382,\n`IsInList` 372, `GetLocked` 5, `GetCurrentTime` 18, `GetInSameCell` 32, `GetBaseActorValue` 277, `GetDestructionStage` 471,\n`GetMapMarkerVisible` 492 — are `CATALOG` rows read through the ObScript getter's own body, `vm_getter_command`; modeled on FO3\u002FFNV only (Oblivion for four of them since #6554),\n`102e4f5cd`; Oblivion's 365 `GetPlayerInSEWorld` moved to `OBLIVION_DIALECT`), #6478 (`IgnoreCrime` 0x10ab, `GetIgnoreCrime` 0x10c0,\n`SetEnemy` 0x1078, `SetAlly` 0x1079 and `SendAssaultAlarm` 0x105f are `Games::Fallout` rows: as `Games::Any` they shadowed Oblivion's\n`IsPlayerInJail` \u002F `CloseCurrentOblivionGate` \u002F `PositionWorld` \u002F `PositionCell` \u002F `Yield`, `598067e2a`,\n`fallout_only_opcodes_do_not_shadow_oblivions`), #6466 (a Find package's activate arrival queues through\n`PendingFragmentActivations` instead of a PostUpdate `ActivateEvent` insert that only Late readers saw, `9f783b30f`), #6470\n(`item_count` — GetItemCount and its ObScript getter — sums a form list through `Inventory::count_of_any`, saturating, `457c5cd0d`),\n#6447 (`player_controller_system` declares its `PendingScriptStoryEvents` write, `1ebb38bce`). Closed since the 2026-10-24 sync: #5646 (`GetRandomPercent` drew `pick(101)`, 0..=100; the CK\u002FGECK say\n0-99 — now `pick(100)`, pinned by `get_random_percent_is_an_integer_in_zero_to_ninety_nine`, `6701086fd`), #5647 (the\none-slot `StoryEvent` marker lost a second same-frame event on one entity — all three engine producers, `CLOC`\u002F`AHEL`\u002F`KILL`,\nnow go through `story_manager::raise_story_event`: the first event on an entity takes the marker, a later one queues on\n`PendingScriptStoryEvents`; `two_events_on_one_entity_in_a_frame_both_dispatch`, `eca0c4709`), #6139 (the ObScript\ncommand chain became the `obscript_cmd.rs` table and `ObScriptCommandHost::call` was split, `bd4cabf81`..`d5d13edcc`),\n#6142 (`apply_effect` \u002F `evaluate_guard` \u002F `check_call` \u002F `guard_reading` \u002F `call_statement` split by family,\n`b269744f2`), #6221 (`GetIsPlayerBirthsign`, `GetAnimAction` and every `IsPlayerActionActive` index but the tracked\njump (6) return `Action::Declined` instead of a constant, `c1b2b1d12`,\n`untracked_state_declines_instead_of_answering_a_constant`), #6226\u002F#6281 (script sounds go through the bounded\nvoice cache, skip decode with no device and honour SNDD attenuation and the 2D\u002FMenu bits; ObScript `PlaySound` has no\nsource reference — `NON_LOCATIONAL_SOURCE` — and is heard at the `AudioListener`, the player body only when no\nlistener exists, `f04c3433d`), #6333\u002F#6335 (per-frame cost: `collect_due` asks the stub question per due instance,\n`4f6cac254`; `StoryLocationMemo`, `80471eb78`), #6338 (`resolve_entity_by_global_form_id` answers from the\n`FormIdPool` generation-keyed index `entity_with_local`, `ab3a604bf`), #6365 (effect handlers open through\n`live_caller` \u002F `open_actor_effects`, `bf27df84c`, `handlers_open_through_the_live_caller_helpers`), #6287 (the scalar\n`npc_refuses_dialogue` agrees with the bulk gather, `aa1016f3c`), #6286 (the alias inventory grant folds into the\nform's row, `f3c8461fc`). Closed since the 2026-10-21 sync: #5750 (`GetIsVoiceType` catalogued — 426 Skyrim\u002FFO4, 427 FO3\u002FFNV, each foreign in\nthe other family; true for the speaker's VTCK voice type or any member of an FLST of them, the leveled base's terminal\ntraits via #6228 `b76a74e45` — plus `IsCommandedActor` 700, a documented 0.0 since the engine has no summon\u002Freanimate,\nso Skyrim's Hello greeting selects by voice again — `20d01cd6c`) and its FO3\u002FFNV sibling #6251 (ten functions the\nObScript getters already answered catalogued so the fail-closed gates stop declining them — `f57c75616`). Closed since the 2026-10-20 sync: #5778 (Oblivion's quest-level dialogue gates catalogued —\n254 `GetIsPlayableRace`, 365 `GetPlayerInSEWorld` (Oblivion-only through `OBLIVION_DIALECT`; every later game's 365 is `IsChild`, #6460), 70 `GetIsSex`, 310\n`GetInWorldspace`; the census now declines 1 quest \u002F 9 INFOs, the one gated by uncatalogued fn 313 — `71e488a26`).\nClosed since the 2026-10-15 sync: #5682 (the menu entry carries the INFO that admitted it and selection reuses it, so a fn-77 gate is\nrolled once — `8daa24105`, `selected_info_is_not_re_evaluated_after_menu_filtering`; the click half #6007\n`f7c8f02a7`, `a_topic_click_speaks_the_info_the_menu_offered`), #5752 (`select_info` declines an INFO whose CTDA\nset holds any term `condition::is_modeled` rejects instead of evaluating it against `0.0` — `bd85de5ea`,\n`uncatalogued_info_condition_is_declined_instead_of_matching_zero`), the Dim 6 ObScript follow-ups #5787 (`a5e5346d0`,\ntests below), #5788 (module doc refreshed, `fecdd043a`), #5789 (`%0.f` precision, `1502fbd3d`), #5790\n(`GetButtonPressed` answer global, `173f9e155`). Closed earlier: #5608\n(the `ScriptTimer`\u002F`TimerExpired` pair has no production producer or consumer — docs made honest, `bef345396`;\nFO4 `OnTimer` rides `fragment\u002Fupdates.rs`), #5681 (fragment `Utility.Wait` capped at `MAX_PROVIDER_WAIT_SECONDS`,\n`FragmentExecutionQueue` capped at `MAX_FRAGMENT_CONTINUATIONS` = 4 096, `ef130cd6c`), #5734 (quest-level dialogue\nconditions gate their quest's INFOs, `6709eb65e`), #5763 (interpreter frame budget + `ReferenceScriptIndex`,\n`195e3b4ef`), #3817 (cinematic retention reversible, `63bf3347f`), #4415 (magic runtime incl. the racial pair, `9813af435`), #5366 (Story Manager, Phases 0-4 all shipped), #5367 (dialogue\ntrees: greeting\u002Fline lifetime\u002FFO3-FNV force-greet `14cff35ae`, Skyrim force-greet `287214103`) and its #5397\nRandom-stack follow-up (`0436bea5c`), #4334 (once-only persistence, `ReferenceScriptState`), #4190, #4116.\nNot gaps: the M47.1 condition resolvers and fragment lowerer are implemented and live-verified; `MoveTo`\ndefault-materialized shapes lower (#3487); the QUST VMAD property table is wired; a Papyrus interpreter exists\n(`fragment\u002Fvm\u002F`) — \"no VM\" findings are stale; structs are modelled on the VM for Fallout 4 (the VM header's \"Not\nmodelled: structs\" line is stale, `Value::Struct` exists).\n\n**Instruments**: `crates\u002Fscripting\u002Fexamples\u002Fmq101_conformance\u002F` (the MQ101 conformance run — a module directory since #6360: `main.rs` hub, `scenes`\u002F`packages`\u002F`scripts`\u002F`fragments`\u002F`ast_probe`\u002F`report`) and `crates\u002Fscripting\u002Fexamples\u002F{fragment_coverage,extender_preflight,\nquest_fragment_populate,dump_stage_fragment_effects,refr_script_coverage,alias_script_coverage,refr_script_props,\nterminal_fragment_census,cndf_census,sm_tree_dump,dump_pex_script,obscript_tools}.rs` (need game data; `fragment_coverage` counts fragments through\n`Effect::contains_placeholder` primitives separately; `refr_script_coverage` with `VM_REASONS=1` lists why the VM declines\na reference script; `sm_tree_dump` prints a Story Manager event's tree in evaluation order; `obscript_tools\nnames \u003CESM> all` measures ObScript call-site coverage, `census`\u002F`avcodes` re-derive block and actor-value ids),\n`cargo test -p byroredux-scripting --release --lib -- --ignored --nocapture vm_cost` (interpreter cost bench,\n`fragment\u002Fvm\u002Ftests.rs`), `docs\u002Fsmoke-tests\u002Fm47-triggers.sh` (spawn+attach gate on\nSkyrim data via `--scripts-bsa`), `docs\u002Fsmoke-tests\u002Fm47-3-obscript.sh` (ObScript object blocks live on FNV), `tests\u002F{pex_recognize_e2e,location_aliases_real_data,perk_entry_points_real_data}.rs`\n(`#[ignore]`d, need game data).\n\n## Parameters \u002F Extra Fields \u002F Severity\n\n`--focus` default all 7 · `--depth shallow` (API contracts + decline\u002Fbounds invariants) | `deep` (per-frame\nECS lifecycle, lock traces). Finding fields: **Dimension**: Recognizer Chain | Fragment Dispatch & Locks |\nEvent Runtime | Attach & Reference Identity | Scene\u002FPackage\u002FCinematic | Legacy ObScript | Provider\u002FExtender Layer ·\n**Untrusted-Input**: Yes | No (Yes on any path decoding mod-supplied bytes — `.pex` derivatives, `SCDA`,\nprovider manifests).\nEscalations over `_audit-severity.md`: recognizer\u002Feffect emits on an **unmodeled** term instead of declining,\nor a wrong AST is accepted → HIGH; ECS lock held across a second resource\u002Fcomponent mutation (deadlock) →\nHIGH; transient marker not drained \u002F drained out of stage order (re-fires every frame, or a frame late) →\nHIGH; panic\u002FOOB\u002Funbounded alloc or recursion on mod-supplied bytes → HIGH; `feature-matrix.md`\u002Fcomment rot → LOW.\n\n## Phase 1: Setup\n\n`mkdir -p \u002Ftmp\u002Faudit\u002Fscripting`; dedup `gh issue list --repo matiaszanolli\u002FByroRedux --limit 300 --json number,title,state,labels > \u002Ftmp\u002Faudit\u002Fscripting\u002Fissues.json`;\nread the newest `docs\u002Faudits\u002FAUDIT_SCRIPTING_*.md` (older reports use the pre-split 8-dimension numbering:\nold 5→Dim 1\u002F2, old 6→Dims 2\u002F3, old 7→Dim 4, old 8→Dim 5) and diff against it; read `translate\u002Fmod.rs`,\n`fragment.rs`, `cleanup.rs` docstrings and `m47-2-design.md` §\"Risks & mitigations\" to separate designed\ndeclines from defects. Delta-first: `git log --since=\u003Clast report> --format='%h %cs %s' -- crates\u002Fscripting byroredux\u002Fsrc\u002Fcell_loader\u002Freferences byroredux\u002Fsrc\u002Fasset_provider\u002Fscript.rs byroredux\u002Fsrc\u002Fsystems\u002Fcinematic.rs byroredux\u002Fsrc\u002Fsystems\u002Fnpc_dialogue.rs byroredux\u002Fsrc\u002Fsystems\u002Fforcegreet.rs byroredux\u002Fsrc\u002Fsystems\u002Fstory_events.rs`.\nRun `cargo test -p byroredux-scripting` and `cargo test -p byroredux --bin byroredux boot::schedule`.\n\n## Phase 2: Dimensions\n\n### Dimension 1: Recognizer Chain & Effect Lowering (decline-on-unmodeled — highest yield)\nPaths: `crates\u002Fscripting\u002Fsrc\u002Ftranslate\u002F**`, `crates\u002Fscripting\u002Fsrc\u002Fpapyrus_provider\u002F{catalog,lower_call,lower_program}.rs` (seam)\nFirst step: `cargo test -p byroredux-scripting -- translate::`; `git log --since=\u003Clast report> -- crates\u002Fscripting\u002Fsrc\u002Ftranslate\u002F` (`effects.rs` is a thin hub over `translate\u002Feffects\u002F`; never scope to the hub file)\nGuard (E2): `every_effect_primitive_bounds_its_argument_count` (`translate\u002Feffects\u002Ftests.rs` — every `prim_*` bounds `args`\nwith a real *upper* bound or a real call to a bounded helper, comments stripped, row-for-row against the table, #5977\n`51f30c95c`; so an over-arity call from a modded `.pex` declines) and `unrecognized_script_is_a_silent_miss`; aim at what\nthey cannot see:\n- **Decline enforcement — two guard paths.** *Handler recognizers* (`compose.rs`): `classify_guard_atom(atom, ..)?`\n  propagates `None` on any atom no `GUARD_PRIMITIVES` entry claims (no `if let Some` that drops a `None`);\n  `split_and` splits `&&` only, so a `||` declines rather than lowering half\n  (`split_and_flattens_conjunction_keeps_disjunction_whole`). *Fragment lowerer* (`translate\u002Feffects\u002Flower.rs`, guards in `translate\u002Feffects\u002Fguards.rs`):\n  `classify_condition` folds an `If`\u002F`While` condition into `FragmentGuard`s — quest\u002Fobjective\u002Fglobal\u002Fquest-variable\n  reads, actor\u002Fscene\u002Flocation\u002Fmap-marker atoms, run-time `Compare`, and (M47.2) `Any` for `||` (`A || (B && C)`;\n  a negated `||` is a conjunction, a nested disjunction flattens). Any atom no guard claims returns `None` and the\n  whole fragment declines (then Dim 2's VM check gets a chance — a decline here is never a partial lowering).\n  A comparison operand that casts a numeric reading to `Bool`\u002F`String` declines (a cast is no longer transparent, #6512 `62fb2cd6d`,\n  `a_bool_cast_over_a_numeric_reading_no_longer_lowers_as_the_bare_number`); `as_num` applies each cast's own rule to a literal.\n  Flat-sequence effect model: `Stmt::ExprStmt → classify_effect_with_providers(..)`, then the quest-script inline \u002F\n  `quest_vmad_statement` fallbacks, else decline; locals bind only via `bind_local` (quest \u002F object \u002F player \u002F\n  plain, else decline); a named call argument declines instead of binding positionally (#5068). Control flow is\n  closed to: `Stmt::While` only via `lower_3d_loaded_wait` (OR-tree of `!\u003Cactor>.Is3DLoaded()` + exactly one\n  positive `Utility.Wait`) or `lower_wait_while` (any modelled guard + exactly one positive literal `Wait` →\n  `Effect::WaitWhile`), and `Stmt::If` only as `Effect::Conditional` (`ElseIf` chains nest as the else branch,\n  bounded by the same depth cap; branches lowered against **cloned** `Scope`s, and a branch that re-binds a local\n  declared before the `If` declines — `Scope::rebound_by`, #5632 `ed6998c51`; a branch may wait since the cursor\n  stack suspends mid-branch, but `has_latent_tail` still refuses a latent effect where nothing can resume it —\n  quest scope, speaker line, run-time locals). Bare `Return` lowers only as the body's final\n  statement at depth 0 (#5631), and an assignment to a bare identifier that is no declared local declines\n  (#5638, `rebinding_a_pre_branch_local_inside_a_branch_declines`, `assignment_to_a_script_variable_declines`)\n  — except where the VMAD is the quest's own and the name is one of its script variables\n  (`vmad_is_quest && is_script_variable`, M47.2; only Bool\u002FInt\u002FFloat declarations count — a non-numeric one\n  declines rather than reading `0.0`, #5978 `e802d1705`). A compound assignment (`n += 2`) to a declared local\n  declines (#5976 `686885652`); Int `\u002F` lowers only when an operand is provably Float and `SetValueInt` only on an\n  integral value (#5974 `4cf0e087f` — `ValueExpr` arithmetic is untyped f32); a truncating global read\n  (`GetValueInt`, `GetValue() as Int`) lowers in a guard only as exact bounds on the stored float and declines in a\n  value, where the VM runs it (#6215 `a16053fbb`). Widening any of these is a decline-invariant\n  regression. `lower_statements` recursion is capped (`MAX_CONDITIONAL_DEPTH` = `MAX_STMT_DEPTH`, the smaller\n  upstream cap), and one fragment's lowering across inlined quest-script callees shares `MAX_LOWERED_STATEMENTS`\n  = 10 000 (#5970 `07f2a6561` — `MAX_INLINE_DEPTH` alone let N^4 expansion through).\n- **Lower only what is modeled, name it from the declared signature.** For each primitive compare against the\n  engine class's real Papyrus signature (decompile the vanilla `.pex` — e.g. `faction.pex`, `game.pex`):\n  parameters must carry their *declared* names (#4322 `SetInChargen` flags were invented; #4318\n  `SetEnemy` lowered `abSelfIsNeutralToOther`\u002F`abOtherIsNeutralToSelf` then discarded them, so \"mutually\n  neutral\" was recorded as hostility). A primitive that lowers an argument and drops it, or accepts a\n  non-literal for a default-only parameter, is a finding; the pattern is \"accept only the literal-default form,\n  decline the rest\" (`MoveTo`: ≤ `MOVE_TO_MAX_ARGS`=6; the three offsets and `abMatchRotation` must be literals and\n  are *carried* into `Effect::MoveTo` since `24755f1d7` — the player's teleport still declines a non-zero offset \u002F\n  `!match_rotation`, and Starfield `abRotateOffset = true` declines; `AddItem`: literal `abSilent`, parsed and not\n  applied). The M47.2 primitive wave (~60 `M47.2:` commits adding `prim_*` \u002F `classify_native_*` pairs) quotes the\n  CK page in each module doc — an argument dropped or defaulted beyond what that page says is the finding.\n  Post-2026-09-19 primitives to hold to this: `StopCombat`, `AddSpell` (accepts\n  and drops a literal `abVerbose`), `RemoveSpell` (#4414\u002F#4415), `AddRaceSpells`\u002F`RemoveRaceSpells` (unqualified argless call onto the player; apply re-applies\u002Fclears exactly the stamped `RaceSpells` set, a scripted `AddSpell` survives the clear, `9813af435`; the player's own stamp is `attach_to_player`'s, #5413 `212a71dba` — before it both were silent no-ops on the only actor they target), `SetUnconscious` (`prim_set_unconscious`,\n  `[abUnconscious = true]`, player receiver declines; #5017 `3c08cfe50`). Also held to it since 2026-10-10:\n  `Lock` takes the compiled two-parameter shape (`abLock`, literal `abAsOwner` parsed and not applied; a\n  non-literal or third argument declines, #5653 `2ce808553`), `SetObjectiveDisplayed` parses `abForce` through\n  `bool_arg` (#5652 `9777c41a2`), `Enable`\u002F`DisablePlayerControls` fill absent arguments from their *own*\n  default tables (`ENABLE_PLAYER_CONTROLS_DEFAULT` vs `DISABLE_PLAYER_CONTROLS_DEFAULT`, #5651 `5e2fc3c8e`), and\n  `SetMotionType` integer literals lower only where every game agrees (just `1` = Dynamic; Skyrim\u002FFO4 constants\n  differ, the named `Motion_*` property read still lowers; #5633 `92a1782fe`,\n  `literal_motion_types_lower_only_where_every_game_agrees`; the game-aware VM accepts Skyrim's raw 1\u002F4\u002F5\u002F7 via\n  `ScriptGame` and stops the run on the inertia variants and other games' numbers, `2517782fc`). Since 2026-10-17:\n  Skyrim's `DamageActorValue`\u002F`RestoreActorValue` (and `*AV`) lower the amount's magnitude — a literal folded, a\n  run-time amount through `ValueExpr::Abs` (CK: negatives convert to positive; FO4\u002FStarfield `*Value` keep the sign,\n  #5973 `3f32efc04`); `SetEssential`\u002F`SetProtected` lower only on an ActorBase receiver, FO4\u002FStarfield's per-instance\n  Actor\u002Falias spellings decline to the VM (#5972 `40345ea0d`); the set-stage trigger recognizers fall back to the\n  script's declared bool initializers for omitted VMAD properties (#5969 `f417c3f64`).\n- **Receiver\u002Fhole binding never defaults to form-id 0**: `QuestRef::{OwningQuest, SelfRef, Property}` must\n  fully resolve (`OwningQuest` needs `ctx.owning_quest` and lowers only from `Self.GetOwningQuest()` — an\n  alias property's `GetOwningQuest()` names another quest, #5634 `221befd61`; `SelfRef` on a REFR declines); `ObjectRef` has no\n  bare-receiver case (`receiver_object` rejects `self`; object locals resolve through\n  `scope.object_locals`, alias-bound via `SceneActorBindings`); a receiver the runtime would *drive* must\n  not be the player (`StartCombat`, #4323). `PlayerRef` (0x14) resolves inside the shared\n  `resolve_entity_by_global_form_id` (#4694; every other id answers from `FormIdPool::entity_with_local`, a\n  generation-keyed index rebuilt only when `FormIdComponent` membership moves, first duplicate wins as the old scan did,\n  #6338 `ab3a604bf`) and its inverse `entity_global_form_id` returns 0x14 for the player\n  (#5979 `a6e66a08c`, which deleted the per-writer copies) — a local 0x14 special-case elsewhere is drift. A VMAD\n  `None` object property resolves to absent, never form 0 (`ScriptInstance::object_form_id`, #5971 `34cc809ae`). `Disable`\u002F`Enable` classify the receiver through the same\n  alias-aware `receiver_object` as their siblings (an alias-bound marker must not decline alone).\n- **Placeholders are coverage with a hole**: `Effect::is_placeholder` (`ShowRaceMenu`, `RequestSave`,\n  `SetHudCartMode`, `AddAchievement` — state nothing reads) must be reported separately by coverage harnesses\n  (#4328\u002F#4372), nested ones included (`Effect::contains_placeholder` \u002F `visit_nested` walk `Conditional` arms and\n  `QuestScope` bodies, #5975 `fd70bf557`); any *new* effect whose runtime arm only records a value needs listing\n  there and a pin (`only_the_counter_only_primitives_are_placeholders`).\n- **Chain order**: `RECOGNIZERS` = per-script first (`two_state_activator`, `rumble`), generic second\n  (`quest_stage_gate`); first match wins, all-`None` = silent miss; a new generic recognizer must not shadow a\n  per-script one. `quest_stage_gate` declines when the condition quest and the `SetStage` target disagree, and arms only the\n  handler in effect in the script's **boot state** (the `Auto State`'s handler, else script scope; handlers\n  only in non-auto states are ignored — #5639 `e1b7e31e7`, `advance_handler_must_be_in_the_boot_state`).\n  `rumble` extracts literal property values only. Fidelity gate: `recognizes_da10_and_reproduces_hand_builder`\n  (`.psc` side) **and** `da10_pex_reproduces_hand_builder_byte_for_byte` (`.pex` side, `#[ignore]`d, Skyrim SE\n  data) — the `.psc` half alone never touches the decompiler; run both.\n- **Provider catalog is consulted after the canonical table** (`classify_effect_with_providers`: primitives\n  first, #3934 — an installed alias must never change how vanilla lowers); lowering must only accept\n  provider barriers the dispatcher can serve (`servable_catalog()` gates on `callback.is_some()`;\n  `every_lowering_seam_reads_the_servable_catalog` in `asset_provider\u002Fscript.rs`), and only as many as the runtime can\n  cross — the four fragment entry points count the longest path's barriers and decline at\n  `MAX_PROVIDER_FRAGMENT_BARRIERS` (#6022 `893ad4838`). A script that mixes provider and non-provider handlers no\n  recognizer claims declines whole (`MixedScript`, #6021 `45c28ad66`) — the VM attach is suppressed once a provider\n  program attaches, so a half-lowered script left the rest inert.\n- **`translate_pex` clean-`None` on bad bytes and on panic**: `catching_panics` wraps the whole\n  parse→decompile→analyze→lower sequence (`a_decompile_panic_is_a_silent_none`), now split as `decompile_pex`\n  (reference-independent, cached per script) + `translate_decompiled_with_providers` (per reference, #5999\n  `f28930504`), and the VM's `check_reference_script`\u002F`check_alias_script` (#6000 `586290057`,\n  `the_vm_script_checkers_run_inside_the_panic_net`); it cannot recover OOM\u002Fstack\n  overflow (those need the bounds `\u002Faudit-papyrus` checks). `CanonicalEvent::from_papyrus` is\n  case-insensitive; `Unknown` means \"no consumer\", never a wildcard.\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_1.md`\n\n### Dimension 2: Fragment Dispatch, Quest Stages & Lock Nesting\nPaths: `crates\u002Fscripting\u002Fsrc\u002F{fragment.rs,fragment\u002F**,quest_stages.rs,quest_variables.rs,globals.rs}`, `byroredux\u002Fsrc\u002Fboot\u002Fschedule\u002F`\nFirst step: `cargo test -p byroredux-scripting -- fragment:: quest_stages::`; `cargo test -p byroredux --bin byroredux boot::schedule`\nGuards: `boot\u002Fschedule\u002Fmod.rs` — `scene_and_fragment_dispatch_chain_stays_in_dependency_order`,\n`fragment_activation_order_tests`, `hit_event_consumers_run_after_every_producer`,\n`every_parallel_system_declares_everything_it_acquires`,\n`papyrus_provider_system_…`\u002F`legacy_obscript_load_order_system_declares_everything_it_acquires`,\n`build_scheduler_reports_zero_access_conflicts`. The order guards read the *built* schedule — `build_scheduler()` +\n`access_report()` through the `schedule_order` helper, which matches an exact system name and panics on a missing one\n(#6684 `2a02c5446`; two parallel systems in one stage count as unordered) — not registration text; the\n`…declares_everything_it_acquires` guards still read `boot::SOURCES`, now through the `syn` visitor in\n`byroredux\u002Fsrc\u002Facquisition_scan.rs` (#6685 `c98a4552f`: comments, strings and `#[cfg(test)]` cannot match; same-file callees to\ndepth 3; `drain_into_resource` is listed as a write acquisition, #6707). Also `fragment\u002Ftests.rs::{nested_lock_contract_documents_\napply_effect_itself, the_nested_lock_residual_list_names_every_type_apply_effect_acquires}` (source scans over\n`fragment::SOURCES`: `apply_effect`'s doc block must name every type its per-family helpers acquire).\n- **Nested-lock safety is exclusive scheduling.** `apply_effect` (`fragment\u002Feffects.rs`, ~120 lines: every arm\n  delegates to `apply_{quest_vars,inventory,placement,scene,lock,player_control,vehicle_cinematic,messages,\n  reference_state,player_stats,location_alias,actor_values,actor_lists,ai_combat}_effect`\n  + `apply_quest_scoped_effect` in `fragment\u002Feffects\u002F*.rs`, #4340\u002F#5468\u002F#6142; `SetGlobalValue` lives in `quest_vars.rs`, and\n  `evaluate_guard` delegates to `evaluate_{quest,actor,world}_guard` in `guards.rs`; the scans read those bodies through\n  `fragment::SOURCES`, which `sources_completeness` pins to every production file) runs under one `resource_2_mut::\u003CQuestStageState, QuestObjectiveState>()`\n  taken in `apply_fragment_guard_free`; `QuestStageFragments` is cloned before any quest lock (no read→write\n  nesting). Safe only because every quest-resource system is `add_exclusive` — moving\n  `quest_fragment_dispatch_system`, `scene_fragment_dispatch_system`, or any sibling to the parallel lane, or\n  adding a nested component\u002Fresource lock, needs the ABBA analysis re-derived (`apply_effect`'s doc block is\n  the running inventory — re-read it, do not trust a count; since #5986 `9712354c9` it states the real invariant —\n  *everything* under the paired guards, VM natives and the `FragmentExecutionQueue` write included, relies on\n  exclusive scheduling — and the scan follows the helper bodies, `nested_helper_bodies`: `apply_effects`, `defer`,\n  inventory transfers, evaluators, resolvers, equipment emitters, plus the `has`\u002F`query_2_mut_mut`\u002F`resource_2_mut`\n  forms). Reverse-order acquirers (`Inventory`\u002F`Transform`\u002F\n  `Globals` first, quest resources second) on any path are the finding. The stage\u002Fobjective *pair* itself is taken\n  TypeId-sorted everywhere — `resource_2_mut` for writes, `World::try_resource_2` for the guard-free getter\n  (`evaluate_guard_guard_free`, #6101 `824c620a5`; TypeIds move with the feature set, so a code-order pair reddens the\n  lock-order lane in only some builds) — two sequential `resource::\u003C…>()` reads of the pair are the recurrence.\n- **`apply_effects` is an explicit cursor stack** (#3935) — no per-`Conditional` recursion or program clone; an\n  unresolvable guard `QuestRef` declines the whole `Conditional` (neither branch; #3785,\n  `apply_effects_declines_conditional_with_unresolvable_guard`), with a `warn!`.\n- **Cascade**: `MAX_CASCADE = 64` bounds only fragment-emitted (`is_cascade`) `SetStage`s, not authored\n  ingress; FIFO `VecDeque`; overflow warns; a no-op re-set (`previous == new`) does not cascade. A quest started\n  with no Start Up Stage reports `QuestStageAdvanced::stage_set == false`, so no stage fragment runs (CK *Quest\n  Stages Tab*); `is_run_once` gates the radiant-reset on `start_quest` (#5406). Stopping a quest or scene goes\n  through the one `QuestStageState::stop_with_shutdown` (a running quest advances to its shut-down stage first;\n  #5812 `32bebaa19`, `stop_with_shutdown_advances_only_a_running_quest`) — a private stop tail is drift.\n- **Objective transitions** (#5153): `QuestObjectiveState` mutators push a bounded `QuestObjectiveEvent` only on\n  false→true flips (`objective_mutators_emit_transitions_only`); the queue is serde-skipped presentation\n  (drained by the app frame into announcements) — a repeat\u002Fun-flip that emits is the regression.\n- **Quest journal**: `QuestStageState` keeps a sequenced event journal (`QUEST_EVENT_RETENTION` = 16 384) with\n  four fixed subscribers (`SCENE_QUEST_EVENT_SUBSCRIBER`, `FRAGMENT_QUEST_EVENT_SUBSCRIBER`, `TERMINAL_QUEST_EVENT_SUBSCRIBER`, and\n  `OBSCRIPT_STAGE_QUEST_EVENT_SUBSCRIBER` for `obscript_stage_result_system`, Dim 6), each polling its own cursor\n  (`missed_events > 0` ⇒ the subscriber must resync from canonical state). `set_stage` keeps `stages_done`\n  history (`GetStageDone(37)` stays true after 40). The journal is authoritative; `QuestStageAdvancedBatch` is a\n  compatibility mirror written through `push_quest_stage_advances` (one `SparseSetStorage` slot: a bare\n  `insert` drops same-frame producers, #3277). A consumer that reads both must dedup the mirror as a multiset\n  (as `quest_fragment_dispatch_system` does — otherwise a double advance) and must not claim (`poll`) the\n  journal while it has nothing to consume (#3012); a new consumer picks a subscriber constant, not a private cursor.\n- **Populate**: `populate_quest_fragments_from_pex` merges all of a stage's `Fragment_N` effect chains in VMAD\n  order and *replaces* the installed chain (re-population must not duplicate); `QuestStageFragments::vmad`\n  is registered so `Property`-targeted effects resolve — a decline with a populated VMAD is a regression.\n  `SceneFragments` is one binding per `(scene, event)`.\n- **Lock & enable ledgers** (`ReferenceLockState`, `ReferenceEnableState`, FormID-keyed, saved): a scripted\n  `SetLocked`\u002F`SetLockLevel` records the component's **full outcome** (level + key), never a partial delta that\n  outranks the authored XLOC (#4329); alias-bound receivers come back to a FormID via `entity_global_form_id`;\n  non-resident references still record where the ledger can hold them (#4330; `Enable`\u002F`Disable` do). Third\n  sibling `ReferenceScriptState` (#4334, save v26): fire-once triggers park their script there and the\n  recognizer's spawn closure consults it so a reload does not re-arm. Fourth sibling `ReferenceMotionTypeState`\n  (local FormID → `MotionType`, #6237 `6765e60eb`): `Effect::SetMotionType` (lowering and VM) records it through the\n  deferred batch and `cell_loader::spawn::scripted_motion_type` applies it to every collider a placement spawns — a\n  `RigidBodyData` column cannot carry it, because collision entities never hold a `FormIdComponent`\n  (`reference_motion_type_state_survives_save_load_round_trip`,\n  `a_scripted_motion_type_is_applied_to_the_placements_rebuilt_colliders`). A \"simplification\" that keys any of the\n  four ledgers by entity is the regression.\n- `Effect::StartCombat` also removes the actor's `AmbientEngagement` (moved into `crates\u002Fscripting\u002Fsrc\u002Fcombat.rs`\n  beside `AiCombatState`) in its own guard scope, so a scripted fight is never auto-dropped by the ambient\n  disengage (#5046 `fef67f3c3`); `Effect::SetUnconscious` writes `ActorControlState` (mutually exclusive with\n  restrained) and ends the actor's combat — both acquisitions belong in `apply_effect`'s lock inventory.\n- `Effect::AddSpell`\u002F`RemoveSpell` apply through `magic::{add_spell,remove_spell}` (`SpellList` + permanent\n  `ActorValues` modifier, add\u002Fundo symmetric — `add_and_remove_spell_apply_and_undo_permanent_modifiers`); both\n  types are nested under the quest lock, so they belong in `apply_effect`'s lock inventory.\n- `Effect::SetGlobalValue` writes `Globals` (saved, `resolve_property_form_id` — a GLOB is never alias-bound).\n  `QuestAliasReadinessGate`: advances only when `is_running`, `stage \u003C only_below_stage`, and\n  `!get_stage_done(target)` (idempotent); one gate per quest (upsert).\n- **Papyrus VM contract** (`fragment\u002Fvm\u002F`, `docs\u002Fengine\u002Fscripting.md` \"The Papyrus VM\"): populate installs\n  `Effect::Interpret` only through `interpret_fallback`, i.e. when `check_function` accepts the fragment ahead of\n  time — against typed placeholders, in every state's version down the `extends` chain, collecting each script the\n  run needs (`the_check_takes_what_the_lowering_declines`); reference and alias scripts go through\n  `check_reference_script` \u002F `check_alias_script` (every handler of `DELIVERED_EVENTS` \u002F `DELIVERED_ALIAS_EVENTS`\n  must run whole; both lists are built from one `SHARED_REFERENCE_EVENTS` table, the reference list appending the\n  documented `REFERENCE_ONLY_EVENTS`, #6158 `fa719a9d5`) and each delivery re-checks via `handler_runs` against the installed scripts. A run that still\n  meets a native declining its *actual* values stops and logs — never a guessed value (`feedback_no_guessing`).\n  Int-typed natives (`GetStage`, `GetItemCount`, `GetRelationshipRank`, `GetLevel`, `RandomInt`, a truncated\n  `GetValueInt`) return `Value::Int` and a typed local keeps its declared numeric type, so `i \u002F 10` and string\n  concatenation match the compiled Int\u002FFloat split the decompiler erased (#6216 `8dee19ed4`).\n  Anything that raises a Story Manager event or touches a resource outside the quest pair defers onto `DeferredFragmentEffects`\n  (`fragment\u002Feffects\u002Fdeferred.rs`; ~50 queues, flushed in a fixed order by `apply_at_depth` once the quest guards drop, most through\n  the shared `drain_into_resource` helper, #6707): `Faction.SendPlayerToJail` → `jail_sends` and `Game.TeachWord`\u002F`UnlockWord`\n  (`Effect::ObtainWord`) → `word_gains` (`jail::send_player_to_jail` raises `ARRT`\u002F`JAIL` and declines with no `CrimeModel`, #6569\n  `dcc3dc681`, and deposits into the evidence chest before taking a stack, #6573 `81332fc38`; `words_of_power::obtain_word` raises\n  `NVPE`; a fake jail moves nobody), `SetRelationshipRank` and the VM friend-rank native → `relationship_events` (`CHRR`, #6572\n  `076de275e`) — none may take a second resource lock under the pair; a new native that calls a `raise_*_story_event` inline is the\n  recurrence.\n  Natives are not interpreted here: `classify_native_{effect,value,guard}` re-use the lowering's primitive table\n  and `apply_effects` applies the result, so Dim 1's per-primitive rules and this dimension's lock inventory apply\n  to every VM native unchanged. Bounds: `MAX_STEPS` = 100 000 statements per *logical* run (the budget's\n  `carried_steps` keeps it cumulative across yields), `MAX_DEPTH` = 16 script-function nesting, a `Utility.Wait`\n  past `MAX_PROVIDER_WAIT_SECONDS` stops the run (`waits_past_the_shared_cap_stop_the_run`, #5681), the continuation\n  queue holds `MAX_FRAGMENT_CONTINUATIONS` = 4 096, enforced at every push (`FragmentExecutionQueue::push` \u002F\n  `extend_capped` drop the newest tail — zero-delay deferrals, custom-event deliveries and yields used to bypass it,\n  #5984 `73fddb4b8`). Allocation caps (#5791 `5c3c5758d`): `MAX_ARRAY_ELEMENTS` \u002F `MAX_STRING_BYTES` reuse the SDK's\n  `MAX_SCRIPT_ARRAY_ELEMENTS` (512) \u002F `MAX_SCRIPT_STRING_BYTES` (4 KiB) and stop the run in `Expr::New`, array\n  literals, `Add`\u002F`Insert` and both string-concat sites; a stored script variable follows at most `MAX_STORED_DEPTH`\n  = 8 levels (a struct cycle `s.m = s` stops instead of overflowing the stack, #5983 `9018a5523`). The *checks* run\n  under `catching_panics` (#6000), the run itself does not (populate does); the\n  production `unreachable!`\u002F`expect` arms in `fragment\u002Fvm\u002Finterp.rs` each rest on a \"loaded\u002Fchecked above\" invariant — re-verify.\n  Script variables live in the saved `QuestScriptVariables` (numbers) \u002F `QuestScriptObjects` (objects, strings,\n  arrays, structs) keyed by the *owner id* — a quest FormID, a reference FormID, or an `AliasScriptOwners` id in the\n  `ALIAS_OWNER_BASE` (0xFC00_0000) range, which no plugin can occupy since regular slot allocation stops at 0xFB\n  (#5988 `0edc61bbf`) — so they outlive the cell unload; keying any of them by entity is the\n  regression (same rule as Dim 2's ledgers).\n- **Frame budget** (`fragment\u002Fbudget.rs`, #5763): `VmFrameBudget` = `DEFAULT_FRAME_BUDGET` (10 000 statements) per\n  frame, `RUN_START_COST` (16) per run, renewed by `event_cleanup_system` — a budget nothing renews kills the\n  interpreter after one frame. A run that has not started defers onto `FragmentExecutionQueue` with zero delay; a\n  run in progress yields between statements exactly as a `Utility.Wait(0)` would (`VmResume.carried_steps`); a due\n  `OnUpdate` the budget cannot start is left due, not queued; a matching one-shot `RegisterForHitEvent` fires and its\n  run defers rather than being dropped (#5987 `746214f29`); `fragment_continuation_system` only advances the\n  clocks while `budget::exhausted`. Every Papyrus-call system goes through the shared tail\n  `fragment\u002Fdispatch.rs::run_papyrus_call` (budget → `defer` → `apply_fragment_guard_free`) and `flush_advances`\n  (#5797 — hits, distance, package, perk and terminal ran unbudgeted before it); a new system that hand-rolls the\n  tail is the recurrence. Unsplittable (documented residual, open as #5764): a statement inside a function called for its value\n  and any frame holding an array\u002Fstruct local — they finish in-frame, charged to the budget. Guards:\n  `a_budget_is_spent_and_renewed`, `a_run_the_budget_cuts_short_resumes_where_it_stopped`,\n  `several_runaway_handlers_stay_inside_the_frame_budget`; cost bench `vm_cost_*` (`#[ignore]`d).\n  `ReferenceScriptIndex` (one hash lookup for \"is this reference loaded, which scripts\") is rebuilt at the first\n  lookup after an attach and re-validates the entity it finds — a despawned\u002Freused id reads as not loaded.\n  `fragment\u002Freference.rs::collect_deliveries` returns before walking the attached scripts on a frame that raised none\n  of its sources (`OnDeathEvent` — drained first, ahead of the early-out — bleedout\u002Fcombat\u002Fplayer-location changes,\n  `OnCellLoadEvent`, `OnInitEvent`, `ActivateEvent`, `OnTriggerEnterEvent`, `HitEvent`; #5764 part, `11685934d`): a new\n  delivery source not added to that gate is silently never delivered.\n- **Delivery systems** (all exclusive `Update`; order in `boot\u002Fschedule\u002Fupdate\u002F`): (`obscript_object_system`, Dim 6) →\n  `check_alias_scripts_dispatch` →\n  `alias_script_event_system` → `reference_script_event_system` (ahead of quest dispatch so a stage a script sets\n  runs its fragment the same frame; drains `OnDeathEvent` at its head; every marker but `HitEvent`) → `activate_parent_relay_system` →\n  `animation_event_system` → `scripted_sound_system` → `quest_fragment_dispatch` → `quest_terminal_stage_system` →\n  `fragment_continuation_system` → `script_update_dispatch` → `distance_event_system` → … →\n  `pending_trap_hit_flush_system` → `reference_script_hit_system` (reference\u002Falias `OnHit`, split out by #5991\n  `e4810c125` because projectile and trap hits land after the frame pass) → `hit_event_system` →\n  `obscript_hit_system`\u002F`obscript_combat_system` — every `HitEvent` consumer after every producer. Registration families (`fragment\u002F{updates,distance,events,\n  hits,anim_events}.rs`): per script *instance*, saved, delivered to the registrant only; a quest's registrations\n  end when it stops, a reference's wait while it is unloaded; a registration is accepted only when its handler\n  passes the VM check, so a delivery never meets an unchecked body (a registration whose handler cannot run is\n  skipped without failing the registering code). PACK \u002F PERK \u002F TERM fragments (`fragment\u002F{package,perk,terminal}.rs`)\n  are *host-reported* (`report_package_end` on a Travel arrival, `report_perk_entry` \u002F `report_terminal_selection`\n  from the `perk.run` \u002F `terminal.select` console commands — no engine producer for the activation popup or terminal\n  screen yet, a documented gap).\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_2.md`\n\n### Dimension 3: Event Runtime — Markers, Timers, Conditions, Triggers\nPaths: `crates\u002Fscripting\u002Fsrc\u002F{events,cleanup,timer,recurring_update,condition,trigger,vm_state,player_control}.rs`, `crates\u002Fscripting\u002Fsrc\u002Fpapyrus_demo\u002Fquest_advance.rs`, the marker producers\u002Fconsumers in the M47.2 request modules (`*_requests.rs`, `havok_impulse.rs`, `activate_parents.rs`)\nFirst step: `cargo test -p byroredux-scripting -- cleanup:: condition:: trigger:: recurring_update:: quest_advance`\nGuards: `cleanup.rs::every_drained_marker_is_a_documented_pattern_a_marker` (the one remaining doc-vs-body text pin),\n`every_documented_pattern_b_marker_drains_in_its_named_consumer` and `pattern_b_markers_survive_event_cleanup` — behavioural\nsince #6688 `58caf1799`: the first raises each scripting-crate marker (`OnDeathEvent`, the scene \u002F dialogue \u002F package batches\nand requests, `StoryEvent`, `TwoStateTransitionBatch`), runs its named consumer and expects it gone (the old source scan was\nsatisfied by a producer's `query_mut::\u003CT>` insert just as well); the second runs `event_cleanup_system` and expects every\nPattern-B marker still present. The binary crate's request consumers (`HavokImpulseRequest`, `MotionTypeChangeRequest`,\n`PickIdleRequest`, `FleeRequest`, `PushActorRequest`, `ReviveRequest`, `UseWeaponRequest`, `ResetInventoryRequest`) are run in\n`byroredux\u002Fsrc\u002Fsystems\u002Frequest_drain_tests.rs`; `OnResetEvent`'s private consumer in\n`obscript_objects.rs::the_reset_marker_is_taken_even_when_nothing_has_a_script` (it drains ahead of `collect_due`'s\nno-instances early returns, #6267 `cf7380e27`) — a new Pattern-B row needs its consumer run in one of those, not a text row.\nAlso `cleanup_removes_all_event_types`;\n`boot\u002Fschedule\u002Fmod.rs::{transient_cleanup_is_the_last_late_exclusive, activation_flush_is_scheduled_before_every_activate_event_consumer, extension_event_adapters_run_before_transient_cleanup}`.\n- **Marker lifetime — two sanctioned patterns** (module doc of `cleanup.rs` is authoritative): **A** = listed in\n  `event_cleanup_system` for markers with no single owner (last system in `Stage::Late`); **B** = drained\n  *unconditionally at the head* of the one owning consumer (no early return before the drain, or the marker\n  strands and re-fires forever). A marker in neither is the bug — cross-check every `world.insert` of a\n  marker type against the drain lists, and check each Pattern-B owner's first statements. **Multi-producer\n  markers must merge, not overwrite** (`SparseSetStorage` = one slot per entity): `QuestStageAdvancedBatch`\n  (`push_quest_stage_advances`), `HitEvent` (one row per target: the NPC melee producer holds a strike on an\n  already-hit target, #4324; projectile hits ride the `ProcessTrapHit` queue whose flush applies the same hold,\n  #5860 `ea28a35b8` — re-verify after any new producer; a VATS queue's folded shots ride the sibling `HitParts` (per-shot `PartStrike`, VATS-LIMB-002, `83e9c6c92`), a Pattern-A marker drained with the `HitEvent` it describes), `ActivateEvent` (a system running after the Update consumers must queue through `PendingFragmentActivations`, not insert — the Find package's arrival did, so Update `OnActivate` consumers missed it until #6466 `9f783b30f`; Update-stage consumer order pinned by the flush test, which now\n  lists `container_loot_system` and `mg07_on_activate_dispatch` (#4712\u002F#4116), plus\n  `reference_script_event_system`; the Late-stage `npc_dialogue` selection system is a further consumer — it must\n  stay before `event_cleanup_system`); `NativeActivation` rides an `ActivateEvent` raised by `Activate(akActivator,\n  true)` and makes the Papyrus `OnActivate` delivery and the `BlockActivation` gate stand aside (CK\n  *Activate - ObjectReference*) — every script-side `OnActivate` consumer (lowered quest-advance, rumble, MG07,\n  provider, WASM extension, VM) reads `papyrus_activations` (`ActivateEvent` minus `NativeActivation`, #5994\n  `6f7dd2213`), so a raw `ActivateEvent` read in a script consumer is the regression (the last two,\n`two_state_activator_system` and `legacy_obscript_load_order_system`, moved over in #6218 `36d1a2c2c`); `OnDeathEvent` is Pattern B, drained at the head of\n  `reference_script_event_system` (a Late-stage script kill is delivered next frame, not lost to cleanup).\n  `event_cleanup_system` also renews `VmFrameBudget` (Dim 2) and drains `NativeActivation`; its module-doc table\n  lists the request markers the engine-side consumers drain (e.g. `HavokImpulseRequest` →\n  `scripted_havok_impulse_system`, which snapshots, drains exactly those and early-returns only when there are none —\na missing `HavokImpulseRules` drains the snapshot before returning, #6009 `f00bfd6e5`; a resource check placed after\nthe resolve and before the drain is the recurrence).\n- **Two-phase lock discipline**: `timer_tick_system` (no production code starts a `ScriptTimer` or reads\n  `TimerExpired` — #5608; FO4 `OnTimer` is `fragment\u002Fupdates.rs`), `trigger_detection_system`,\n  `recurring_update_tick_system` collect under one `query_mut`, `drop()`, then acquire the marker-insert\n  `query_mut`; two component-mut locks at once forces the TypeId-sorted contract (deadlock vector).\n- **CTDA OR-precedence** (`condition\u002Feval.rs::evaluate`): consecutive `or_next` conditions form a block that binds\n  tighter than the AND chain (`A AND B OR C AND D` = `A AND (B OR C) AND D`); empty list → `true`; guards\n  `or_precedence_quirk_*`, `and_chain_short_circuits_on_first_false`. Function catalog per the module-doc\n  table (indices verified against TES5Edit; a function is added as one `condition\u002Fcatalog.rs` `ROWS` entry, in `CATALOG` order; `CATALOG` was 24 at #5380 `395d2d831`, which added 56 `GetQuestRunning`,\n  74 `GetGlobalValue`, 77 `GetRandomPercent` — the last rides `StoryManagerRng`, a documented 50.0 with none\n  installed, and draws an integer 0..=99 as the CK says — `pick(100)`, #5646 `6701086fd`; the module-doc table and a row-count pin\n  (`the_module_doc_table_lists_the_whole_catalog`) track the catalog, #5648 `2ed7f8ec3`. `GetQuestRunning`\n  reads `is_running` alone — a stopped\u002Fcompleted\u002Ffailed quest is not running, #5636 `aac92c6ca`; the plugin-side\n  `param1_is_form_id` load-order remap mirrors the catalog by index, with rows for 56\u002F71\u002F74 and an exhaustive\n  mirror test, #5637 `722c06a76`; M47.2 grew `CATALOG` to 48, #5778 `71e488a26` to 52, #5750\u002F#6251\u002Fthe crime\ngetters to 77, #6460 `102e4f5cd` + the tempering read to 88, #6558 `612f876f9` +9 to 97, #6545 `d3db6fd58` +4 to 101 and #6657's `IsWeaponSkillType` (109, FO3\u002FFNV) to 102 and `GetPermanentActorValue` (495, FO3\u002FFNV, #6654 `3ae93950b`) to 103 (the array length is the live count; #6251 `f57c75616` added 35 `GetDisabled`, 47 `GetItemCount`\n(a form list sums its members), 64 `GetIsCreature`, 84 `GetDeadCount`, 131 `GetPCIsSex`, 289 `IsInCombat`, FNV's\n420\u002F421 `GetObjectiveCompleted`\u002F`Displayed`, 431 `GetHealthPercentage`, 546 `GetQuestCompleted`; #5750 `20d01cd6c`\n426\u002F427 `GetIsVoiceType` and 700 `IsCommandedActor`; the crime commits the `GetCrimeGold`\u002F`GetCrime`\u002F`IsGuard`\u002F\n`GetPCFame`-family reads, whose state is `crime_*`\u002F`jail`\u002F`guards` — `\u002Faudit-gameplay`; #5778 added 254 `GetIsPlayableRace` over `PlayableRaces`, 365 `GetPlayerInSEWorld`, 70 `GetIsSex`, 310\n`GetInWorldspace`, whose `param_1` joins the plugin remap) — 629 `GetVMQuestVariable`, the\n  location family 181\u002F359\u002F360\u002F562\u002F563\u002F565\u002F566\u002F567\u002F605 plus the cleared \u002F keyword-data location reads (250, 598 and the\n  `GetKeywordDataFor*` rows), 576 `GetEventData` (xEdit's packed `function:member` in `param_1`, the form in\n  `param_2`), 560 `HasKeyword`, 403 `GetRelationshipRank`, 237 `GetIsGhost` and the essential\u002Fprotected\u002F\n  bleedout\u002Fteammate reads — those that need a context read `ConditionContext` (owning quest's aliases, a\n  location-alias fill's `location_subject`) through `evaluate_contextual` (`reads_context`), and\n  `param2_is_form_id` remaps 605\u002F181's (and 576's) second parameter; 180\u002F610 stay unmapped (Oblivion\u002FFNV collisions); fn 0 is deliberately **unmapped** (xEdit: `GetWantBlocking` on TES5\u002FFO4, no index 0 on\n  TES4\u002FFO3\u002FFNV — the short-lived `GetButtonPressed` mapping was removed by #5431; `GetButtonPressed` exists\n  only as an ObScript script function in `obscript_quests`)); `GetIsID` compares the Run-On's **base** object\n  (`SceneAliasCandidate::base_form_id`), not the placed ref (#5041 `1816bbc14`,\n  `get_is_id_matches_run_on_base_object_not_placed_reference`); `GetActorValue` reads through\n  `CharacterRuleset::actor_value` (the shared derived+modifier composer, #5042 — `\u002Faudit-character` Dim 4), its\n  authored enum index translated to the loaded AVIF by `condition_actor_value_form` (FO3\u002FFNV GetAV table, Skyrim UESP\n  indices; unreadable on Oblivion, which has no AVIFs — #5989 `d1dd5e030`); unknown functions return the documented safe default — a\n  display\u002Fselection default only: a consumer that *acts* on a pass must decline on any `Unknown` term first\n  (Story Manager nodes, #5380; the ambient force-greet install's `package_conditions_fully_modeled`, #5376;\n  dialogue INFOs, #5752; scene\u002Fphase starts, quest-log entries, objective targets, base-form trigger advances and\n  consumable branches through `evaluate_modeled`, #5993 `9b6dcf872`;\n  every such check goes through the one game-aware `condition::is_modeled` — fn 79 `GetQuestVariable` reads\n  `ObScriptQuestLocals` on Oblivion\u002FFO3\u002FFNV and stays unmodeled on FO4\u002FStarfield where 79 is another function,\n  `f67d82b3c`; catalogued indices another game reuses — 109, 125, 131, 403, 426\u002F427, 431, 449, 459, 533, 550, 555, 630, 659 (FO4 `HasVMScript`, #6570 `57a49a4d4`) — are unmodeled there (`FOREIGN_INDICES`, per-game rows), #5990 `9f418b4fa`; the VM-bridged getters (`vm_getter_command`: the ten of #6460 plus #6558's nine and #6545's four, 23 in all) are modeled only where `obscript_cmd::getter_answers_conditions` finds the VM's row — FO3\u002FFNV, and Oblivion for the four `OBLIVION_CONDITION_GETTERS` (5\u002F18\u002F32\u002F50, #6554 `6dec5c4a9`); an untranslatable `GetActorValue` index is unmodeled), and\n  a new intrusive consumer that trusts the fail-open pass is the finding; `RunOn`\n  resolution declines (condition fails) on an unresolvable target rather than defaulting to the subject; a\n  wrong sentinel flips a condition. `crates\u002Fplugin\u002Fsrc\u002Fconsumables.rs` borrows fn-586 semantics by profile\n  (`\u002Faudit-character` Dim 1).\n- **Triggers** (`trigger_detection_system`): edge-triggered (outside→inside); `occupant_inside: Option\u003Cbool>`\n  with `None` = never checked (first tick never fires for the player — a player loaded inside a volume must\n  not fire); `contains` math (Sphere `half_extents.x` radius; OBB via `rotation.inverse()`);\n  `OnTriggerEnterEvent.triggerers: Vec\u003CEntityId>` — no consumer may read `[0]` only\n  (`preserves_all_actors_entering_one_volume_in_the_same_frame`); actors tracked in `TriggerOccupancyState`\n  keyed `(trigger, actor)` and pruned each frame (`retain(observed)`); only tethered horses use\n  `intersects_sphere` (`TETHERED_HORSE_TRIGGER_RADIUS`); `became_ready_inside` is a level condition that stops\n  once the target stage is done. `GetTriggerObjectCount` counts through `trigger_occupants` (player included; an\n  empty candidate list clears stale pairs, #5992 `06f6382fe`). `actor_quest_trigger_is_in_sequence` (gate) and\n  `scene_trigger_actor_approach_system_inner` (router, Dim 5) answer \"which BaseForm trigger stage is next\"\n  separately — verify they agree via the shared `base_form_advance_is_eligible`\u002F`scene_phase_awaited_stage`\n  (#4333) on cross-quest phase waits and centerless triggers.\n- `quest_advance_system` unifies `ActivateEvent` + `OnTriggerEnterEvent` on `QuestAdvanceOnActivate` with a\n  three-way `ActivatorGate` (`Any`\u002F`PlayerOnly`\u002F`BaseForm`), evaluated per `(entity, triggerer)` pair, and the first\n  passing triggerer of a source wins — one advance per volume per frame, so two actors entering together cannot run\n  the stage fragment twice past `onlyOnce` (#5995 `6a85756d6`);\n  nothing may deliver both signals to one entity in one frame. `disable_reference_after_advance` (from\n  `disableWhenDone`) records into `ReferenceEnableState`; both fire-once variants park in `ReferenceScriptState`\n  (`fire_once_advances_park_the_reference_script_state`, #4334).\n- `recurring_update_tick_system`: no fire on the registering frame\u002Fzero dt; once per interval; overshoot fires\n  once; `UnregisterForUpdate` in a handler terminates cleanly. `QuestAliasReadinessGate` timing: after\n  `quest_alias_refresh_system`, before `scene_playback_system`.\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_3.md`\n\n### Dimension 4: Engine Attach Path & Reference Identity\nPaths: `byroredux\u002Fsrc\u002Fcell_loader\u002Freferences\u002F{attach,synth_child,mod}.rs`, `byroredux\u002Fsrc\u002Fcell_loader\u002F{spawn,exterior,unload}.rs`, `byroredux\u002Fsrc\u002Fcell_loader\u002Fexterior\u002Fpersistent.rs`, `byroredux\u002Fsrc\u002Fasset_provider\u002Fscript.rs`, `crates\u002Fscripting\u002Fsrc\u002Ffragment\u002F{reference,alias_scripts}.rs` (the attached component + check), `crates\u002Fplugin\u002Fsrc\u002Fesm\u002Frecords\u002Findex.rs`\nFirst step: `cargo test -p byroredux --bin byroredux -- cell_loader::references reference_enable_gate`; `grep -rn 'spawn_logical_quest_reference' byroredux\u002Fsrc`\nUntrusted-Input: Yes — `.pex` bytes come from possibly-modded archives.\n- **Silent-miss everywhere**: no `--scripts-bsa`, VMAD absent, `.pex` missing (`extract_pex` → `None`), decode\u002F\n  decompile failure, recognizer miss — every branch is `continue`\u002F`return`, never `unwrap`\u002F`expect`.\n  `--scripts-bsa` is repeatable, **first-listed-archive-hit wins** (the inverse of mod-manager priority:\n  list overrides first); `pex_archive_path` normalizes to `scripts\\\u003Clowercase>.pex` (a wrong prefix\u002Fseparator =\n  every `.pex` misses, zero attach, no error).\n- **Script sources**: `base_record_script_instance` (VMAD on ACTI\u002FCONT\u002FNPC\u002FCREA, item family, statics family\n  incl. STAT\u002FMSTT\u002FFURN\u002FDOOR\u002FLIGH\u002F…, TERM; pins per family) and legacy `base_record_script` (SCRI incl. the\n  statics family); REFR's own VMAD is merged by `dedup_vmad_scripts` (names differing only by case collapse\n  to one attach; a reference that lists a script with fewer properties than its base record's copy keeps its own\n  values and inherits the rest — `a_reference_inherits_the_base_copys_properties_it_does_not_set`).\n  **Attach order**: the `.pex` is extracted and decompiled once per script name (`decompiled_pex` →\n  `DecompiledPexCache`, compatibility preflight recorded on first sight; #5999 `f28930504`), then\n  `translate_decompiled_with_providers` runs per reference against the shared AST and yields a provider program and\u002For a recognized\n  archetype (each attaches when present); only when neither claimed the script does\n  `attach_vm_reference_script` (`asset_provider\u002Fscript.rs`) run, which declines a reference with no FormID (a\n  non-primary SCOL\u002FPKIN child — the VM reaches scripts by FormID, #5998 `838ce679d`) and attaches\n  `PapyrusReferenceScripts` when `check_reference_script` accepts every handler of the delivered events (verdict\n  cached per script name in `VmReferenceScriptChecks`; a script a recognizer models gets no VM instance, so VM\n  calls into it decline). Quest alias scripts are checked lazily by `check_running_quest_alias_scripts` —\n  `ALIAS_CHECKS_PER_FRAME` = 4 quests and `ALIAS_SCRIPT_CHECKS_PER_FRAME` = 8 distinct uncached scripts per frame\n  (#6001 `b7c04b44b`; a stopped quest resumes next frame), only for running quests — never at cell load. A legacy\n  `SCRI` reference attaches its ObScript object script (`attach_object_script`, Dim 6) in the same `attach.rs` arm\n  set. Verifying coverage against only the first few accessor arms re-derives a closed gap.\n- **Every identity-only actor\u002Freference stub must attach scripts.** All `spawn_logical_quest_reference`\n  callers outside `synth_child.rs` — the persistent-worldspace loop in `cell_loader\u002Fexterior\u002Fpersistent.rs` and\n  `materialize_scene_actor_alias_stubs` in `scene\u002Fscene_runtime.rs` — go through\n  `spawn_logical_quest_reference_with_scripts` (attaches once per `reference_form_id`, #4112\u002F#4331; the source\n  pin in `cell_loader\u002Freferences\u002Fsource_pin_tests.rs` rejects the bare spelling and scans production text only,\n  #5650 `a7e05dd7b`). Identity-only entities get `OnInit` alone: `attach_script_for_refr` takes `has_3d` and inserts\n  `OnCellLoadEvent` (→ `OnInit`\u002F`OnCellAttach`\u002F`OnLoad`\u002F`OnCellLoad`) only with real 3D, else `OnInitEvent`; every\n  `spawn_logical_quest_reference` site pairs with `attach_identity_reference_script` and a `Disable()`d trigger passes\n  `!placement_disabled` (#5997 `a44d4a20d`, `attach_script_for_refr_sends_the_load_events_only_to_entities_with_3d`)\n  — a stub that receives `OnCellLoadEvent` runs its `OnLoad` twice. The persistent loader also stamps\n  `UnloadedReferenceStub` on a stub whose home cell is not loaded, so ObScript `GameMode` skips it like a\n  `RemoteSceneActorStub` while its event blocks still answer (#6220 `335994b4c`). Residual (documented in the helper): a stub followed by the home cell\n  streaming in leaves scripts on both — stub\u002Freal reconciliation is unbuilt and untracked (the helper doc calls it\n  *#2664's half*, but #2664 closed on the stamping\u002F`Transform` half; no open issue owns it). New spawn paths\n  that call the bare spawner are the recurrence.\n- **Canonical identity stamping** (`stamp_quest_reference`: `FormIdComponent` + `SceneAliasCandidate` +\n  `mark_scene_actor_bindings_dirty`) is applied at every synthetic REFR path, gated on the primary synth child\n  (`synth_idx == 0`) so a SCOL\u002FPKIN fan-out registers one candidate per authored alias; the no-mesh fallback\n  still spawns a `Transform`\u002F`GlobalTransform` entity.\n- **Enable\u002Flock gates** consult the FormID ledgers *before* content is built: `reference_is_disabled` is asked\n  once per REFR ahead of every branch in `load_references_budgeted` (actor jobs, LIGH-only\u002Ffxlight placements,\n  invisible triggers — #4326\u002F#4327), `placement_is_disabled` in `spawn_placed_instances` after the root but\n  before mesh\u002Fcollider\u002Flight, `scripted_lock_override` at the `Locked` stamp. A disabled actor\u002Ftrigger keeps\n  identity + scripts but no body\u002Fvolume. Regression = a spawn path that never reaches a gate, or the gate\n  moved render-side (`AnimatedVisibility` is honored in static but not skinned rendering). An XESP child resolves\n  through `reference_enabled_from`: the chain is followed (cycle-capped) to its first parent-less reference, whose\n  scripted Enable\u002FDisable beats its authored flag, flipping once per inverted hop; a child cannot be toggled\n  independently (CK *Reference*), and a parent-disabled child keeps a content-withheld root with identity + scripts\n  (#6077 `22ff0e12e`). Guard:\n  `cell_loader\u002Freference_enable_gate_tests.rs`.\n- **XPRM → `TriggerVolume`** (`trigger_volume_from_primitive`): bounds are z-up **half**-extents (do not\n  divide by 2), permute `[x, z, y]` with `.abs()`, REFR scale baked into a world-space volume, sphere radius in\n  `half_extents.x`, shape `1 → Box`, `3 → Sphere`, else `None`\n  (`trigger_volume_from_{box,sphere}_primitive_*`); invisible (MODL-less) trigger REFRs compose world space once.\n- **Spawn\u002Funload hooks the VM reads** (M47.2): `spawn.rs` stamps `EditorLocation` (the spawn pose, for\n  `MoveToMyEditorLocation`), `ExplicitOwner` \u002F `ExplicitEncounterZone` from the REFR, and re-applies scripted\n  faction edits (`reapply_scripted_faction_changes`) after the actor job so record-derived membership never undoes\n  them; `unload.rs` calls `raise_unload_events` on the victims *before* despawn (`OnCellDetach` \u002F `OnUnload`) — but a\n  save load's own teardown must not deliver them: `byroredux\u002Fsrc\u002Fsave_io\u002Flive_load.rs` calls `discard_pending_unload_deliveries` and\n  `rebaseline_actor_watch` (no cross-timeline `OnUnload` \u002F `OnEnterBleedout` \u002F `OnCombatStateChanged` \u002F\n  `OnLocationChange`; #6083 `4b8e62d87`, `a_load_discards_the_unload_events_its_own_teardown_raised`). An\n  evicted reference's `TwoStateActivator` \u002F `ScriptVariables` (ObScript object locals included), `ScriptTimer` \u002F\n  `RumbleOnActivate` (#6085 `3b9060701`) and its `ScriptPackage` slot are parked in the eviction row\n  (`cell_loader\u002Freference_state.rs`, `\u002Faudit-gameplay`) and put back over the defaults the re-attach stamps, before the\n  `OnLoad` marker is consumed (#6071\u002F#6072 `611769b16`). A new spawn path that skips these is the recurrence.\n- The `M47.2 scripts:` cell-load summary counters (`recognized`, `trigger volumes`) must be wired or\n  `m47-triggers.sh` is vacuous; exterior stub loops report attach counts. `commands\u002Fquest.rs`\n  (the `quest.*` and `scene.*` console commands, incl. `quest.effects`) stays read-only over `&World` except the explicit start\u002Fstage\n  commands.\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_4.md`\n\n### Dimension 5: Scene \u002F Package \u002F Dialogue \u002F Cinematic Playback\nPaths: `crates\u002Fscripting\u002Fsrc\u002F{scene.rs,scene\u002F**,package.rs,dialogue.rs,cinematic.rs,story_manager.rs,location.rs,animation_graph.rs}`, `byroredux\u002Fsrc\u002Fsystems\u002F{cinematic,npc_dialogue,forcegreet,story_events}.rs`, `byroredux\u002Fsrc\u002Fcell_loader\u002Funload.rs`, `byroredux\u002Fsrc\u002Fasset_provider\u002Fanimation.rs`\nFirst step: `cargo test -p byroredux-scripting -- scene:: package:: dialogue:: cinematic:: story_manager::`; `cargo test -p byroredux --bin byroredux -- cinematic strip_ active_tether npc_dialogue forcegreet story_dispatch_and_forcegreet`\nThe M47.2 MQ101 cart sequence is the first scripted sequence that drives *animation*, not just ECS state.\n- **Scene alias substrate**: `SceneActorBindings` `(quest, alias) → EntityId` is what `resolve_object`,\n  `RunOn::QuestAlias`, and `SceneShowCommand` all resolve through (one entry point — a debug view must not use\n  a different path); an unfilled alias returns `None`, never fabricates an entity;\n  `apply_alias_injections`\u002F`QuestAliasInjectionState` (permanent inventory-grant ledger, saved) must not\n  double-grant after load. **Refresh pre-filters must be exact supersets**: `refresh_scene_actor_bindings`\n  visits per-fill `CandidateIndex` buckets and skips\u002Ffilters condition-only fills via `subject_requirement`\n  (`ConditionFunction::reads_run_on_entity` and `is_deterministic` must stay exhaustive — a stochastic\n  function like `GetRandomPercent` is never folded into a once-for-everyone value, #5645; `run_on_identity`\n  is shared with the evaluator) — a bucket or requirement that excludes a candidate the full fill test or `evaluate` would admit silently\n  unbinds an alias (`subject_requirement_never_excludes_a_passing_subject`,\n  `condition_only_identity_fill_binds_what_the_full_scan_would`).\n- **NPC dialogue selection** (`systems\u002Fnpc_dialogue.rs`, Late exclusive): consumes the player's `ActivateEvent`\n  on an NPC that `running_quests_binding_entity` names (owned DIALs via `DialRecord::quest_refs` — QSTI and,\n  for Skyrim, QNAM). Candidates are **Player-category** topics with an INFO that passes `select_first_info` for\n  this NPC (actor subject, player target); a qualifying **Blocking** DLBR entry opens the conversation and its\n  INFO's TCLT links replace the list; otherwise the list is the **Top-Level** starting topics, and mid-branch\n  children are reached only through links (#5037\u002F#5045 `7ab87c0fb`; FO3\u002FFNV branch-less topics without the DIAL\n  Top-level flag are link-only, #5224 `305363122`). It stamps `NpcDialogueTopic` on exactly one NPC (the\n  surface keys on `DialogueSurfaceState::npc`, #5038); both entry points gate on `player_can_act` and the shared\n  `npc_refuses_dialogue` (dead \u002F `AiCombatState` \u002F unconscious — the whole `collect_unconscious` set, so also knocked\n  down, fleeing or `SetActorsAI 0`, #6287 `aa1016f3c`), also applied by the interaction Talk arm\n  (#5043, `1d31ced2b`) and by `default_activation_blocked` (a script `BlockActivation`, M47.2). `DialogueSurfaceState`\n  lives in `crates\u002Fscripting\u002Fsrc\u002Fdialogue.rs` (re-exported by `npc_dialogue.rs`). UI re-selection goes through `select_topic_by_form_id` and must re-check live\n  ownership. Each menu entry records the INFO that admitted it and a click on a listed topic speaks that INFO —\n  conditions are evaluated once per offer, never re-rolled at selection (#5682 `8daa24105`, #6007 `f7c8f02a7`); an\n  unlisted topic is evaluated fresh. The Late selection system's head ends the open conversation (OnEnd, selection,\n  voice) once `npc_refuses_dialogue` holds for the partner, and `begin_barter` applies the same refusal (#5867\n  `ca3caf411`). **Spoken-line fragments** (#5152, `c59600138`): `DialogueInfoFragments` (TIF_ INFO VMAD, rebuilt\n  from plugin data, unsaved) dispatches the line's OnBegin at selection and the outgoing line's OnEnd on\n  selection change \u002F close via `apply_spoken_info_fragment` (the speaking NPC is passed as `akSpeaker`, M47.2) — the same guard-free executor + journal polling\n  as the quest\u002Fscene dispatchers (`the_spoken_lines_fragments_advance_the_stage`); every native leave path\n  (Close, Escape, the Inventory key) funnels through `App::leave_dialogue_page` → `end_open_conversation`, so\n  the OnEnd dispatches on all of them (#5409 `14b0d33f2`). Greetings and line\n  lifetime (#5367 `14cff35ae`): `open_conversation` falls back to the master's generic greeting topic\n  (`GREETING` Oblivion\u002FFO3\u002FFNV, `DialogueGenericHello` Skyrim — resolved once per load order onto\n  `EsmIndex::generic_greeting_form`, the map scan kept only as the hand-built-index fallback, #5426\n  `411d0eeaf`) when no owned quest topic qualifies; `select_info`\n  first gates each candidate through its owning quest's own condition list (`DialogueQuestConditions`, the CK\n  *Quest Conditions* tab, #5734 `6709eb65e`) — memoised per quest per call, an uncatalogued function fails the gate\n  closed (a hijacker gated only by functions we cannot read must not win on priority; on Oblivion that once declined 87 % of\n  INFOs until #5778 `71e488a26` catalogued the gate functions — re-run `condition\u002Ftests.rs::oblivion_quest_level_dialogue_gates_census`, `#[ignore]`d, after any catalog change), and the list is cloned out and its guard released before `evaluate` (the `QuestStageState` ↔\n  `DialogueQuestConditions` cycle, `8e4c6e40a`); `select_info` never holds `QuestStageState` across an `evaluate` either — the\n  running-quest check takes a short read per question, because `GetStageDone` re-reads the resource and a body-long read was a\n  recursive read behind a parked writer on every FNV force-greet (#6615 `6af13ef37`, pinned by a per-thread warning counter); an INFO whose own CTDA set holds any term `is_modeled` rejects is\n  declined outright (#5752 `bd85de5ea`); then `select_info`\n  collects every passing candidate — the first wins, and a Random first INFO rolls within its positional\n  Random stack (ended by the next passing non-Random INFO or a Random End, #5397 `0436bea5c`) through the seeded\n  `DialogueRandomState`; position is the merged INFO chain (override INFOs fold by FormID after their PNAM\n  predecessor, #5375 `168b81322`, one pass per override since #5644 `0c2bd4d6d` — the merge itself is `\u002Faudit-esm`). Spoken Say-Once INFOs are disqualified\n  per actor through the saved `DialogueSpokenInfoForms` ledger — `(speaker reference FormID, INFO)` pairs since\n  FORMAT_MAJOR 38 (Skyrim ENAM\u002Flegacy-DATA flags now decode; #5300 `f18224b02`; re-selecting the same INFO ends\n  the outgoing line first); a spoken Goodbye closes on\n  the presentation estimate. FO3\u002FFNV\n  INFOs honour their own owning quest (QSTI, #5271 `dbc07e8f0`). **Force-greet**\n  (`systems\u002Fforcegreet.rs`, `ForceGreetDirective` bridge): FO3\u002FFNV Dialogue procedure (`PKDD` topic on\n  `PackRecord::dialogue_topic`) and the Skyrim `ForceGreet` procedure-tree leaf (#5367 `287214103`; a concrete package's leaf and topic are\n  sought on its own tree first, then on its PKCU template — 334 of 339 Skyrim.esm force-greet packs are template\n  instances, #5511 `72e863d80`) walk the NPC to the player and open the topic through the same selection path\n  without activation. The walk goes through `navmesh_path::cached_walk_step` and honours KCC-blocked: a mover\n  held against an obstacle for `LOCOMOTION_STUCK_REPICK_SECS` gives up the approach and opens in place (#5452\n  `6316719ed`), and the step is gated on the shared `ai_locomotion_enabled()` kill switch (the in-radius open\n  stays live and the directive stays pending, #5430 `bd366e300`). Two installers: the\n  `dialogue.forcegreet` console door (any Dialogue package, unconditionally — the drivable one, smoke `dt1`\u002F`dt2`)\n  and FO3\u002FFNV ambient package selection, which installs only from a fully-modeled, player-targeted (PTDT 0x14 or\n  none) Conversation (`PackRecord::dialogue_type` 0) — #5376 `4e58f241d`, `AmbientBehavior::from_package` in\n  `byroredux\u002Fsrc\u002Fnpc_spawn\u002Fai_package.rs` (`\u002Faudit-gameplay`), pinned by `dialogue_ambient_install_declines_unmodeled_offtarget_sayto`;\n  the Skyrim+ tree dialect installs a `ForceGreet` leaf from the ambient driver under the same rule (every leaf condition modelled,\n  target the player or absent; `ai_package\u002Ftree.rs`, AIP-TREE-005, `88c239b35`). A failed open consumes the directive (no per-frame retry);\n  `forcegreet_system` holds every directive while `player_can_act` is false and holds one while the player talks\n  to another NPC (consumed if already talking to the greeter) — #5392 `16544d4c9`,\n  `dead_player_holds_the_forcegreet_directive`, `open_conversation_holds_or_consumes_the_forcegreet_directive`.\n  Pass 2 re-reads the open conversation partner per open (`open_conversation_partner`), so a second same-tick\n  greeter holds instead of stripping the first's line (#5642 `c0c9c9d1b`,\n  `two_same_frame_force_greeters_open_one_conversation`).\n  Walk steps write `Transform` (not `GlobalTransform`) and `PhysicsWorld` is held for the step alone (#5373\u002F#5371\n  `f0c683ef1`). Every opened conversation raises an `AHEL` story event; `raise_hello_story_event` resolves the\n  location *before* taking the `StoryEvent` guard and the open sites scope their `LoadedCellIndex` read to a clone\n  (#5372 `1c15a2270` — the `LoadedCellIndex → StoryEvent → LoadedCellIndex` cycle). The `npc_dialogue_selection`\n  Access row declares the cross-file voice and AHEL hops, and the declaration scan\n  (`npc_dialogue_selection_declares_everything_the_spoken_fragment_path_acquires`) lists `dialogue_voice.rs`,\n  `story_events.rs`, the condition evaluator (`evaluate_function`, incl. the `StoryManagerRng` write and what the VM-bridged\n  getters read) and `apply_at_depth` (the deferred flush, four hops from the entry) explicitly (#5414 `9d8fd4cc9`, #5649\n  `197a9e245`, #6685 `c98a4552f` — the same-file callee walk cannot follow a hop into another file); the row's\n  fragment-effect claims live in `fragment_effect_family_access`, and the crime-faction \u002F crime-gold \u002F ownership claims in\n  functions those subsystems export through `Access::with` (#6701 `c22a9d410`), which the scan follows into the delegate files. A replaced or closed line cuts its voice (`stop_line_voice` →\n  `AudioWorld::stop_sounds_for`; #5432 `40b77828b`). Talk-candidate filtering (`populate_candidates`, `byroredux\u002Fsrc\u002Finteraction.rs`)\n  takes each alias-resource guard alone and builds bulk sets per storage (`running_quest_bound_entities`;\n  #5025 `2a1a7a362` closed two ABBA cycles, #5109 `83d52707e`) — a guard nest reintroduced there reddens the\n  lock-order lane. The egui response page itself is `\u002Faudit-tooling`.\n- **Story Manager** (`story_manager.rs`, `docs\u002Fengine\u002Fstory-manager.md`; #5366 Phases 0-4, live gate `docs\u002Fsmoke-tests\u002Fsm1-story-manager.sh`):\n  `install_story_manager` folds the parsed `SMBN`\u002F`SMEN`\u002F`SMQN` map into an `SmTree`. `SNAM` names the\n  **previous** sibling (xEdit): the head is the `SNAM == 0` (or dangling) member and the fold follows the inverse\n  edges, authored top-down (#5385 `846e4a6dd`, `snam_previous_semantics_walk_head_first`; every member of a\n  sibling group is placed — groups replay in FormID order, not one SNAM chain, #5405 `76a927f8a`; the earlier same-parent\n  check held in both directions, so a direction pin must be asymmetric); a sibling cycle must still terminate\n  (`sibling_cycle_builds_and_dispatch_terminates`).\n  The tree build is linear in sibling-group size and the walk runs on an explicit stack capped at\n  `MAX_WALK_DEPTH` = 64 (#5643 `b79f0d2eb`, `a_huge_sibling_group_builds_and_keeps_every_member`,\n  `a_hugely_nested_tree_walks_without_overflowing_the_stack`).\n  `story_manager_dispatch_system` (exclusive, Update; `StoryClock` synced from `GameTimeRes` first) drains the\n  `StoryEvent` marker (Pattern B) and `PendingScriptStoryEvents` (script-raised `SCPT`, below) and walks the event mnemonic's `SMEN` root: a node whose CTDA set holds any\n  uncatalogued function **declines before evaluation** — neither starts nor consumes, the walk continues to its\n  siblings (#5380 `395d2d831`, `unknown_condition_function_declines_the_node`; the Unknown→0.0 default once\n  passed `== 0` gates vacuously) — otherwise node CTDA runs through the shared M47.1\n  evaluator with `RunOn::EventData` resolved over the positional R1\u002FR2\u002FL1\u002FL2 slots, a passing quest node starts\n  through the canonical `QuestStageState` lifecycle (never a private start path), `FromEvent` aliases fill from\n  the slots via `StoryEventAliasFill` consumed by `refresh_scene_actor_bindings`, which probes slot liveness\n  (despawned id, or `Dead` without ALLOW_DEAD → `StoryManagerEventUnavailable`, never a stale bind; #5419\n  `1dfdeb4f9`, `from_event_alias_skips_stale_and_dead_slot_entities`) and honours the shared reserved set — a slot\n  entity another alias reserved stays unbound unless the alias is Allow Reserved (#6006 `e4afa2b0d`). `DNAM` policies: random parents\n  shuffle (`StoryManagerRng`, whose write guard is taken for the draw alone — `GetRandomPercent` fn 77 re-enters\n  it during `evaluate`, #5628 `faa00de2a`; the `StoryManagerNodeState` pool marks are written after the\n  `QuestStageState` guard drops, a source pin keeping them out of the stages-held region, #6003 `738fbbd5d`), a non-sharing quest node consumes the event only when its own pool\n  queued a start candidate (a passing node with an exhausted pool no longer swallows the event, #5404\n  `76a927f8a`), pools round-robin with\n  `RNAM` reset windows (hours, decoded through xEdit's 1\u002F24 scale, #5386) in `StoryManagerNodeState`. Saved SM\n  resources: `StoryManagerNodeState` and `StoryEventAliasFill` (the CLOC location cursor is session-local and reset on every save load, #5435 `557ead21d`; #5394 `03e51dfad`, column added at FORMAT_MAJOR 35 — the R1\u002FR2\n  slots persist as reference FormIds and re-resolve among resident candidates, session `EntityId`s serde-skipped;\n  `story_event_alias_fill_survives_save_load_as_reference_forms`); `SmTree`\u002Fcursors\u002Fclock\u002FRNG are\n  not-saved-by-design, so a quickload cannot re-fire spent radiants. Update ordering (the M43 polling producers — `register_random_conversations` in `boot\u002Fschedule\u002Fupdate\u002Fquest_scene\u002Fstory_manager.rs` — and the CLOC producer → dispatcher →\n  `quest_alias_refresh_system`, ambient installer → `forcegreet_system`) is pinned by\n  `story_dispatch_and_forcegreet_update_ordering_is_pinned` (`byroredux\u002Fsrc\u002Fscheduler_access_tests.rs`, #5415).\n  Producers: `KILL` (`raise_kill_story_event`, called from all four live death producers — combat, NPC and\n  player drowning, SDK actor-value batch — with the session LCTN as L1; corpse restores deliberately do not\n  raise it, #5434 `c85d50356`; the per-frame CLOC key derivation early-outs on an empty `SmTree`, #5447, and otherwise runs once per cell context through `StoryLocationMemo`, #6335 `80471eb78`),\n  `CLOC` (`systems\u002Fstory_events.rs`, LCTN-granularity key), `AHEL` (every opened conversation), `sm.event` console, the M43 families below, and\n  **`SCPT`**: `Keyword.SendStoryEvent(akLoc, akRef1, akRef2, aiValue1, aiValue2)` lowers to `Effect::SendStoryEvent`,\n  which queues onto `PendingScriptStoryEvents` once the quest-state guards drop (a queue, not a per-entity marker, so\n  several raised in one frame all dispatch — `queued_script_events_in_one_frame_all_dispatch`; the engine producers\n  `CLOC`\u002F`AHEL`\u002F`KILL` share the one-slot `StoryEvent` marker through `raise_story_event`, whose second event on the same\n  entity in a frame queues on `PendingScriptStoryEvents` too — #5647 `eca0c4709`,\n  `two_events_on_one_entity_in_a_frame_both_dispatch`); `SCPT` nodes route on condition fn 576 `GetEventData`\n  (K1\u002FL1\u002FL2 `GetIsID`, location `HasKeyword`, V1\u002FV2 `GetValue`), and a non-optional `FromEvent` alias with an empty\n  slot makes its quest ineligible so the walk continues (`a_required_from_event_alias_without_its_slot_fails_the_start`);\n  **M43 (closed session 106, `docs\u002Fengine\u002Fstory-manager.md` §6.4) added the rest of the producer inventory**, each idle\n  when the tree has no root for its mnemonic: `ADIA` (`systems\u002Frandom_conversation.rs` — NPC-to-NPC random conversations,\n  every number a game setting; the pair is held by `ConversationHold` while the initiator walks over, an enabled\n  `ComplexSceneMarker` suppresses it; `BYRO_NO_RANDOM_CONVERSATIONS=1`) and the natural moving-actors `AHEL` beside it;\n  `LEVL`\u002F`ASSU`\u002F`AIPL`\u002F`REMP`\u002F`CRFT`\u002F`OAAT` in `systems\u002Fstory_events.rs` (`raise_*_story_event`; an integer payload rides\n  `ScriptedStoryEvent { keyword: 0, .. }`, which reads as no `K1`) and `LCLD` beside `CLOC` in `emit_change_location_on_key_change`;\n  `DEAD` (`dead_body.rs`), `IRON` (`iron_sights.rs`), `TMEE` (`mines.rs`), `AOBJ` (`attraction.rs`), `LOCK`\u002F`HACK`\n  (`byroredux\u002Fsrc\u002Flockpick.rs`), and in the scripting crate `CAST` (`magic_effects.rs`), `CHRR` (`relationships.rs`; raised at the deferred flush, not under the quest guards, #6572 `076de275e`), `SKIL`\n  (`skills.rs`), `NVPE` (`words_of_power.rs`) and `JAIL`\u002F`ARRT`\u002F`ESJA` (`jail.rs`). `MNAM`\u002F`XNAM` (Num quests to run \u002F\n  Max concurrent) are consumed — a pass starts up to *Num quests to run* pool quests and stops at the running-pool cap, re-checked\n  when phase B starts a second event's pick in one frame (`max_concurrent_holds_across_events_in_one_frame`); the FO4+\n  node-level `HNAM` window gates the whole node; `FNAM` bit 2 is an **inferred** per-link *shares event* (`af51f6730`; xEdit\n  declares `FNAM` unknown — one-line removal if a source disagrees, not a finding). Every producer's engine-policy numbers and\n  \"Not modelled\" list are in §6.4 — documented gaps. Each engine producer must go through `raise_story_event` (never a bare\n  `StoryEvent` insert, #5647; the `sm.event` debug console still inserts directly), and a new one's reads\u002Fwrites belong in its system's `Access` declaration (#6447). The console doors\n  are `commands\u002Fstory_actions.rs` (`lock.status`\u002F`lock.open`, `word.teach`, `jail.send`\u002F`jail.escape`, `place.at`, `sm.nodes`,\n  `conv.status`, `entity.move`) plus `sm.event`.\n- **Locations & location aliases** (`location.rs`, `docs\u002Fengine\u002Fscripting.md` \"Locations and location aliases\"):\n  `install_location_table` flattens `LCTN` + each cell's `XLCN` into `LocationTable`; a cell-loaded entity's current\n  location is its `CellRoot`'s cell location, the player's is published as `PlayerLocation` by\n  `story_change_location_system` only where the load order authors locations (FO3\u002FFNV\u002FOblivion keep #5447's\n  no-per-frame-work contract). `ALLS` aliases fill in list order with the reference aliases inside\n  `refresh_scene_actor_bindings` (Specific \u002F Reference-Alias \u002F External \u002F Find Matching), the binding is saved\n  (`LocationAliasBindings`), a Find Matching alias never picks a cleared location unless flagged Allow Cleared.\n  Reference-alias fills read *this pass's* location bindings, not the committed ones (#6002 `2424b119c`), and a\n  Location Alias Reference fill is scoped to its bound location (listed by it under the ref type, or standing in it;\n  declines while the location alias is unbound — #6004 `f52a048f3`).\n  Cleared state is `LocationClearState`, fed by `note_actor_death` on the one death path every kill \u002F start-dead\n  actor \u002F save load funnels through — a new death path that skips `reconcile_dead_actor` never clears a location.\n- **Placed-object animation graphs** (`animation_graph.rs`, `asset_provider\u002Fobject_graph.rs`,\n  `object_graph_step_system`, `docs\u002Fengine\u002Fscripting.md` \"Animation graphs of placed objects\" \u002F \"Behavior graph\n  depth\"): `PlayAnimation` sends an event to the reference's `ObjectAnimationGraph`; an event takes the state's own\n  transition (else a wildcard one; `DISABLED` transitions never fire), enters the new state and starts its clip on\n  the object's `AnimationPlayer` (a lazily decoded clip restarts only the graphs whose pose it changes,\n  `start_if_pose_changed`, #6005 `d55940d0a`); the clip's trigger events are scheduled in real time and raised by\n  `object_graph_step_system` (bounded by `MAX_TRIGGERS_PER_STEP` = 1 024; a saturated step drops still-due one-shots\n  too, not just periodic ones, and reports once through the runaway latch — mutually re-arming zero-length triggers\n  used to spend the cap every frame forever, #6010 `26e8afb52`,\n  `one_shots_that_re_arm_each_other_are_dropped_once_a_step_saturates`), and graph-raised events reach `OnAnimationEvent` through registrations\n  (`fragment\u002Fanim_events.rs`). FO4 actors run their own graph (`asset_provider\u002Factor_graph.rs`,\n  `systems\u002Fgraph_locomotion.rs`) — `\u002Faudit-gameplay`.\n  The behavior-graph decode is `\u002Faudit-parsers`; collider\u002Fmotion halves `\u002Faudit-physics`.\n- **Marker patterns** for this domain (Pattern B, drained at consumer head): `Scene{Start,Stop}Request`,\n  `SceneActionCompletionBatch`, `DialoguePresentationEventBatch`, `DialogueLineCompletionBatch`,\n  `ScenePackage*Batch`, `EvaluatePackageRequest`, `MotionTypeChangeRequest` (tail-drains exactly what it\n  snapshotted). Pattern-A `SceneEventBatch`\u002F`SceneFragmentInvocationBatch` feed\n  `scene_fragment_dispatch_system` (Dim 2 order guard). SCEN package `Activate` leaf ordering vs `ActivateEvent`\n  consumers is pinned by the schedule tests.\n- **Playback lifecycle**: `idle_clip_playback_system` starts a scoped player once per serial and drains the\n  request (`idle_request_starts_scoped_animation_player_once_per_serial`); `cinematic_root_motion_system` applies\n  then drains the delta (`cart_exit_root_motion_moves_and_orients_actor_then_drains_delta` — an undrained\n  delta launches the actor); `cinematic_animation_event_system`\u002F`behavior_completion_events` ignore unknown\n  annotations safely and a missing completion event cannot deadlock a quest stage;\n  `vehicle_attachment_system`\u002F`scripted_motion_type_system` flip motion type with the same `Keyframed`\n  discipline `npc_spawn` uses (physics half → `\u002Faudit-physics`); `cinematic_horse_route_system` drives the\n  tethered cart along the horse's XLKR marker chain from `PackageTargetRegistry` (markers are not render\n  entities). Clip conversion (`convert_hkx_clip`: unmatched bones reported not dropped; Z-up→Y-up exactly\n  once; deterministic candidate order in `idle_animation_candidates`) — decode itself is `\u002Faudit-parsers`.\n- **Router vs gate**: `scene_trigger_actor_approach_system_inner` (registered via\n  `make_scene_trigger_actor_approach_system`, persistent scratch) routes an offscreen actor to the lowest-stage\n  reachable `BaseForm` trigger; the gate in `trigger.rs` decides whether it may fire. They must share one\n  eligibility predicate (#4333) and agree on cross-quest phase waits and centerless triggers. Lock order:\n  the `SceneRegistry` read guard is held across the scan and must not invert the canonical scene→quest order\n  (drop before quest resources); the router's conditioned advances are evaluated in a pre-pass *before* the\n  `QuestStageState` guard (the evaluator re-reads it for the GetStage family; source-pinned, #6008 `22ba1f5fe`). Cinematic systems take `Transform` before `ActorCinematicState`\u002F\n  `HorseTetherState` (#4546, `docs\u002Fengine\u002Fecs.md` canonical chain; `BYRO_LOCK_ORDER_CHECK=1` is the gate).\n- **Cinematic retention** (`cinematic_retained_entities` computed once per unload batch;\n  `strip_retained_cell_root(world, victims, retained)` per cell, scoped to `retained ∩ victims`): walk is\n  transitive over `Children` (`active_tether_retains_horse_cart_rider_and_hierarchy`); stripping never\n  orphans an entity from indexes that expect a `CellRoot`; the retention set's lifetime is bounded since\n  #3817 `63bf3347f`: `cinematic_horse_route_system` releases the tether at the XLKR chain's terminal marker, and\n  released entities that lost their `CellRoot` to a mid-tether unload queue on `CinematicReAdoption` (unsaved,\n  session-local ids) for the streaming step (`retry_cinematic_readoption`) to stamp onto the loaded exterior cell\n  root containing them — un-rooted entities are despawn-immune, so a non-draining list is residency leak. Only\n  **parentless** members queue and a root's adoption stamps its whole `Children` subtree (a local `Transform` is\n  not a world position, #5384 `faf8e5682`); the player's subtree is never queued or cell-owned, and\n  `purge_cinematic_retention_state(world, ctx)` releases the still-pending roots' whole `Children` closure\n  (minus the player rig) through `release_entities` at session replacement (#5379 `203be9ed4`; the closure and\n  the render-side release, #5490 `99cd9fd6c`). `release_finished_tethers` clears `vehicle`, so `ExitCart`'s exit\n  heading falls back to the rider's own rotation — equal only because `vehicle_attachment_system` last wrote\n  `vehicle.rotation * vehicle_local_rotation` (`released_rider_exit_heading_matches_the_attached_heading`, #5461).\n  Pins: `systems\u002Fcinematic.rs` (the #3817 lifecycle pair plus `parented_subtree_rides_the_roots_adoption`,\n  `player_rider_is_never_queued_or_cell_adopted`) and `cell_loader\u002Funload.rs`\n  (`pending_readoption_victims_are_the_whole_subtree_closure`, `pending_readoption_victims_spare_the_player_rig`); a release path\n  that strips `vehicle`\u002F`cart_seat` would break the awaited-event exit.\n- Player `CinematicPresentationState`\u002F`PlayerControlState` flags are saved; a flag a consumer never reads is\n  a placeholder (Dim 1) — `disable_saving` is read by `SaveCommand`; `hud_cart_mode` had no reader at #4372.\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_5.md`\n\n### Dimension 6: Legacy ObScript Execution (Oblivion\u002FFO3\u002FFNV; M47.3 quest + object scripts)\nPaths: `crates\u002Fscripting\u002Fsrc\u002Fobscript{,_runtime,_vm,_quests,_objects,_cmd,_actions,_actor_values,_anim,_speech,_state,_ledger,_more}.rs`, `crates\u002Fscripting\u002Fsrc\u002Fobscript_more\u002F`, `crates\u002Fscripting\u002Fsrc\u002Fobscript_effects\u002F`, `crates\u002Fscripting\u002Fsrc\u002F{magic_effects,magic_shaders,script_packages,challenges}.rs`, `byroredux\u002Fsrc\u002Fcell_loader\u002Freferences\u002Fattach.rs` (`attach_scpt_script`, `obscript_dialect_for`, `attach_object_script` call), `byroredux\u002Fsrc\u002Fasset_provider\u002Fscript.rs` (`install_quest_scripts` \u002F `install_object_scripts` \u002F `install_item_scripts` calls), the request consumers `byroredux\u002Fsrc\u002Fsystems\u002F{script_requests,script_queries,revive,knockdown,flee,magic_shader,head_look}.rs`\nFirst step: `cargo test -p byroredux-scripting -- obscript`; `cargo test -p byroredux --bin byroredux -- attach::tests`; `git log -p --since=\u003Clast report> -- crates\u002Fscripting\u002Fsrc\u002Fobscript_vm.rs`\nUntrusted-Input: Yes — `SCDA` bytecode comes from mod-supplied plugins. Distinct from the (unbuilt) `.psc`-side\nSCTX frontend (`ScriptSource::Obscript` placeholder).\n- **`obscript_vm.rs` (pure interpreter) bounds discipline**: statement framing `[op][len][payload]`,\n  `0x1c` explicit-caller escapes, implicit-caller statement calls (line opcode = command id), RPN expression\n  tokens, `[u16 count]` typed arguments, `If\u002FElseIf\u002FElse` nesting with `Return`-inside-arm early exit,\n  1-based SLSD local \u002F SCRO+SCRV reference resolution — compiled reference indices are 1-based into the\n  *interleaved* SCRO+SCRV list (`ScriptRef`; `SCHR.num_refs` counts both; an unresolved explicit caller is\n  declined, #5629). Remote variables (`Quest.var`, `ref.var`) are read and written by ordinal through the synthetic\n  `CMD_GET_REMOTE_VARIABLE` \u002F `CMD_SET_REMOTE_VARIABLE` host calls (`72fd96dfe`;\n  `remote_variables_read_and_write_by_ordinal_on_the_vanilla_bytes`); `exec_remote_set` declines and counts\n  (`CMD_DECLINED`) a malformed or unresolvable target, never storing it as a ref assignment (#5630). Reference\n  variables hold exact form ids (`VmState::ref_locals`). Argument payload reads (#5655 `291af4528`) and an\n  `If`\u002F`ElseIf` condition (#6016 `9a7298283`) are bounded by the statement's own payload, not the script buffer.\n  Every `read_u16`\u002F`checked_add`\u002Fspan end must be bounds-checked\n  and malformed input must yield `BlockOutcome::Malformed`, never panic (`truncated_bytecode_reports_malformed`;\n  `installed_legacy_masters_have_structurally_valid_scda` is the real-data check, `#[ignore]`d). Recursion is\n  capped by `MAX_OBSCRIPT_VM_NESTING` = 32 on both `exec_if_chain` ↔ `run_arm_body` and nested `X` argument\n  decode (`decode_args_at_depth`); guards `excessive_nested_if_chains_are_malformed`,\n  `excessive_nested_x_arguments_are_rejected` — a new recursive path that skips the depth parameter is the\n  regression. The operand stack in\n  `eval_expr`\u002F`apply_operator` must not grow unbounded from a lying token count.\n- **Command and block IDs are empirical** — recovered by aligning each script's `SCTX` with its compiled stream over\n  the vanilla masters (`obscript_tools`), never from a spec. The quest core (`SetStage` 0x1039, `GetStage` 0x103a,\n  `GetStageDone` 0x103b, `StartQuest`\u002F`StopQuest` 0x1036\u002F0x1037, `GetQuestRunning` 0x1038, `GetSecondsPassed`\n  0x100c, `Message` 0x1059, `GetButtonPressed` 0x101f, `GetSelf` 0x10ce) carries a per-game evidence table in the\n  `obscript_quests.rs` module doc (#6015 `3f78f9fe1`): all agree across the three games except `MessageBox`\n  0x1000, which no Fallout script compiles to, so FO3\u002FFNV decline it. Getters run through the M47.1 evaluator (id =\n  `0x1000` + CTDA index); the wider surface is split by family — `obscript_effects\u002F` (the effect bridge: `mod.rs` holds `EFFECT_COMMANDS`, the shared `Binder` and helpers, `getters.rs` the 43 getters' `GETTER_COMMANDS`, the handlers sit in `inventory`\u002F`combat`\u002F`actor_state`\u002F`world_state`\u002F`presentation`;\n  commands lowered to the Papyrus `Effect` their namesake builds and applied through `apply_fragment_guard_free`, so\n  Dim 1's per-primitive rules and Dim 2's lock inventory cover them), `obscript_actions.rs` (reference-bound\n  `Enable`\u002F`Disable`\u002F`MoveTo`\u002F`EVP`\u002F`AddScriptPackage` onto the existing sinks), `obscript_actor_values.rs` (GECK AV\n  codes → AVIF, checked by `obscript_tools avcodes`), `obscript_anim.rs`, `obscript_speech.rs`, and\n  `obscript_more.rs` and its four sibling files (`actions`\u002F`extras`\u002F`state`\u002F`tail`). Every one of those commands is a **row of the command table**\n  (`obscript_cmd.rs`, #6139: id, `Games`, `needs_caller`, handler; each family file exports its own `*_COMMANDS`\n  slice, listed in `FAMILIES`); the host asks the table, not a `match cmd` chain, so an id claimed twice in one\n  game is `duplicate_rows`' test failure, never a shadowed arm, and one id that names different commands per family\n  (`0x116b`, `0x116c`, `0x10db`) is two rows told apart by the loaded game (`Game::of`: Oblivion, Fallout, or\n  `Other`, which runs only the `Games::Any` rows). A row whose id Oblivion numbers differently must be `Games::Fallout`, never `Any` —\n  the table runs ahead of the CTDA-getter route, so an `Any` row answers Oblivion's `IsPlayerInJail` (0x10ab) \u002F\n  `CloseCurrentOblivionGate` (0x10c0) with a Fallout effect (#6478 `598067e2a`, `fallout_only_opcodes_do_not_shadow_oblivions`). The `FALLOUT` \u002F `OBLIVION` census lives in\n  `obscript_more\u002Ftests.rs`, checked against the rows both ways. Only the VM's own statements\n  (`ObScriptCommandHost::call`: `Set`, quest variables, `RemoveMe` \u002F `DropMe`, `GetSecondsPassed`) stay outside it.\n  Handlers that act on the calling actor open through\n  `obscript_effects\u002Fmod.rs::{live_caller, open_actor_effects}` (decline when the caller is not loaded; #6365 `bf27df84c`,\n  source guard `handlers_open_through_the_live_caller_helpers`, which reads every production file of the split through `SOURCES`) — a hand-spelled `caller_of` + `live` prologue is the\n  recurrence. Anything unmodelled\n  is a **traced no-op returning 0, counted per owner in `ObScriptQuestTimers.unknown_commands`, never faked**\n  — a command that returns a guessed value, or answers state the engine does not keep, is a finding\n  (*feedback_no_guessing*; #6221 `c1b2b1d12` turned `GetIsPlayerBirthsign`, `GetAnimAction` and every\n  `IsPlayerActionActive` index but the tracked jump into `Action::Declined`, pinned by\n  `untracked_state_declines_instead_of_answering_a_constant`; `obscript_more` answers only from a named page, engine state or the ledger); the\n  remaining unmodelled tail and each command's blocker are tabled in `docs\u002Fengine\u002Fscripting.md` (M47.3 phase 3) —\n  not new findings. Dialect tables (xNVSE vs xOBSE opcode\n  numbering, `ObscriptDialect`) stay separate because the same number names unrelated commands.\n- **Message \u002F MessageBox** (`5182f7817`): `decode_message` parses the `[u16 length]` text, the set\u002Fif-format variable\n  list and the button strings out of the statement's own argument region (untrusted: every length is checked against\n  `end`; a payload that fails to decode is declined and counted `CMD_DECLINED`, never shown half-decoded). The\n  decoded `ObScriptMessage` reaches the host's `message`, which substitutes the variables (`substitute_numbers`\n  reads width before precision, so `%0.f` \u002F `%2.0f` give zero places, #5789 `1502fbd3d`; `[+- 0#]` flags, minimum\n  field width and `%e`\u002F`%g` per the CS *MessageFormatting* template, #6014 `a4e524c9c` — an unparsed spec used to\n  shift every later argument; mod width\u002Fprecision clamped, #6011) and queues it through\n  `messages::show_obscript_message`, which drops any unread answer (the CS: −1 while a box is open, #6013\n  `cbee28109`); `GetButtonPressed` consumes the last answered box from one global slot (`messages::take_button`, any\n  quest's first call gets it — CS wiki contract, #5790 `173f9e155`, `obscript_button_answer_is_consumed_globally_once`),\n  −1 otherwise.\n- **`obscript_quest_tick_system`** (exclusive `Stage::Update`): runs only *running* quests' GameMode block — due\n  quests in FormID order, never `QuestStageState`'s `HashMap` order (#6013 `cbee28109`; two quests polling\n  `GetButtonPressed` or cross-`SetStage`ing in one tick raced per process) — each on\n  `quest_script_interval` — the authored `QUST` delay (FO3\u002FFNV), overridden by a runtime `SetQuestDelay` (saved in\n  `ObScriptQuestLocals`), either one ≤ 0 meaning the INI default `QUEST_SCRIPT_INTERVAL_SECS` = 5 s (GECK\n  *SetQuestDelay*). It runs through `ObScriptCommandHost` (generic over its owner — a quest, a placed reference or an\n  inventory item), which lowers onto the same\n  `QuestStageState`\u002F`Globals` and emits the same stage events as the fragment path (so Dim 2's journal and\n  cascade rules apply). Timers\u002Feffect ring (`ObScriptQuestTimers`, `ObScriptEffectLog`, cap 64) are unsaved by\n  design — elapsed time restarts on load (documented residual, not silent save loss). Quest-script **locals persist**\n  between GameMode runs in the saved `ObScriptQuestLocals` (seeded into each run's `VmState`, stored back after the\n  run; an unassigned slot reads 0) and condition fn 79 `GetQuestVariable` reads them on Oblivion\u002FFO3\u002FFNV only\n  (`f67d82b3c`; the game split and the cross-tick read are pinned since #5787 `a5e5346d0` by\n  `get_quest_variable_uses_obscript_locals_only_for_legacy_game_paths` and\n  `quest_game_mode_local_is_read_on_the_next_tick_and_by_condition_79`); `StartQuest`\u002F`StopQuest` attach\u002Fdetach the\n  script loop consistently. The 255-script corpus gate in `obscript_quests.rs`\n  (`vanilla_oblivion_quest_scripts_execute_and_setstage`, `#[ignore]`d) resolves Oblivion.esm via\n  `test_paths::oblivion_esm()`, panics under `BYROREDUX_REQUIRE_GAME_DATA=1` instead of returning green, and runs in\n  `.github\u002Fworkflows\u002Freal-data-gates.yml` (#5088 `1377d3463`).\n- **Result scripts** (`obscript_results.rs`, `6db47b0e4`): the compiled streams a FO3\u002FFNV\u002FOblivion `QUST` stage item and\n  a dialogue `INFO` carry inline (`QuestStageLogEntry::result_script`, `result_script_begin`\u002F`_end`).\n  `obscript_stage_result_system` (exclusive `Update`, after `obscript_quest_tick_system`) polls the quest journal as\n  its own subscriber (`OBSCRIPT_STAGE_QUEST_EVENT_SUBSCRIBER`, Dim 2) and runs every stage item whose conditions pass\n  (GECK: all of them, not the first) plus the stages they set, up to `MAX_STAGE_SCRIPT_ROUNDS` = 16\n  (`a_stage_cycle_is_bounded`); an INFO's Begin\u002FEnd scripts run with the speaker as implicit reference. Documented\n  deviation: the calling script finishes before the stage's items run (the original ran them inside the\n  `SetStage` statement). Same decline rules as the other hosts: an `If` whose condition reads a declined getter runs no\n  arm. Any new `SCDA` path here is untrusted input (above).\n- **Sound commands** (`systems\u002Fscripted_sound.rs`, `crates\u002Fscripting\u002Fsrc\u002Fsound_requests.rs`): `PlaySound` is\n  non-locational (GECK) — its request carries `NON_LOCATIONAL_SOURCE` (form 0, never a placement) and plays at the\n  `AudioListener` entity, the player body only when none exists (`listener_or_player`; #6226 `f04c3433d`,\n  `a_non_locational_play_is_heard_at_the_listener`); `PlaySound3D` and a Papyrus `Sound.Play` keep their source, and a\n  record's 2D bit takes the listener too. All script plays use the byte-budgeted voice cache and skip decode on an\n  inactive `AudioWorld` (#6281 `41b53ab41`); the audio engine itself is `\u002Faudit-audio`.\n- **Ledger honesty** (#6190 `7e867cf47`): a command whose value no system, gate or UI reads back declines instead of\n  storing it in the saved `ObScriptLedger` and reporting done (`AddTopic`, `ModDisposition`, `SetQuestObject`,\n  `SetItemValue` were removed; `GetTalkedToPC` is written by `apply_selection`). Mod-supplied accumulators saturate\n  (`ModCrimeGold`\u002F`ModDisposition`, #6187 `50e743a56`). The compiled and source `If`\u002F`ElseIf`\u002F`Else` line forms share one\n  `parse_conditional` recursion that enforces `MAX_LEGACY_OBSCRIPT_NESTING` once (#6159 `3c553b7ca`). Same rule since 2026-11: `SendTrespassAlarm` declines\nuntil trespass is routed into the crime runtime (#6511 `baa93fe87`); Oblivion's caller-scoped `GetCrimeGold` \u002F `SetCrimeGold` \u002F\n`ModCrimeGold` \u002F `GetGold` honour the calling reference — no caller or the player's own keeps the player path, any other named\nactor declines (crime gold) or counts that actor's own `Gold001` (`GetGold`), and an unloaded caller never falls through to the\nplayer (#6510 `a48017e7b`); `MenuMode` reads its per-game codes from the `MenuCodes` resource, so Oblivion answers barter 1008\n(#6620 `16d9e18f3`).\n- **Object and item scripts** (`obscript_objects.rs`, M47.3 phase 2; live gate `docs\u002Fsmoke-tests\u002Fm47-3-obscript.sh`\n  on FNV): a placed reference whose base carries an `SCRI` gets an `ObScriptInstance` at attach; blocks run on the\n  events the engine already raises — `GameMode` every frame per loaded scripted reference (not an `UnloadedReferenceStub` \u002F `RemoteSceneActorStub`, #6220; the\n  residency question is asked per due instance, #6333 `4f6cac254`), `OnLoad`, `OnDeath`,\n  `OnActivate`, the trigger trio, `OnHit`\u002F`OnHitWith`, `OnStartCombat`\u002F`OnCombatEnd`, the package blocks,\n  `SayToDone`, the item blocks `OnAdd`\u002F`OnDrop`\u002F`OnEquip`\u002F`OnUnequip`, `OnReset` (a cell's pending reset lives for\n  its whole budgeted load — each pass marks the scripted references that appeared since, once each — and the loaders'\n  `obscript_state::cell_load_finished` makes the next pass retire it, scriptless or cancelled cells included; #6102\n  `2efed9843`; the worldspace persistent CELL's apply job retires it too, #6219 `a99b2f461`, and a save load's own\n  reload drops the resets it raised via `discard_pending_cell_resets`, #6238 `078df54e1`,\n  `live_load_drain_discards_the_cell_resets_its_reload_raised`), `OnDestructionStageChange`, and\n  the scripted-effect blocks in `magic_effects.rs`. A block written for one reference (`Begin OnTrigger player`)\n  runs only for it (`BlockInfo`). **`OnActivate` replaces default processing**: `has_activate_block` feeds\n  `default_activation_blocked` (the same gate Papyrus `BlockActivation` uses) and the script's own `Activate`\n  queues the native activation — but an `OnActivate` run that declined any command or came back malformed lets the\n  default go ahead (a door nothing can open is the failure mode). Block ids (`BLOCK_*` in `obscript_vm.rs`) differ\n  between Oblivion and the Fallout pair for 0x1a\u002F0x1b (`OnTriggerActor`\u002F`OnTriggerMob` vs enter\u002Fleave) — a block\n  read in the wrong game's meaning is the finding. Object locals live in the saved `ScriptVariables` and ride the\n  eviction row (#6071, Dim 4). Systems: `obscript_object_system` before `reference_script_event_system` (which drains\n  `OnDeathEvent`), `obscript_hit_system`\u002F`obscript_combat_system` after every `HitEvent` producer,\n  `obscript_destruction_system`, the Late `obscript_item_system`; `BYRO_NO_OBSCRIPT_OBJECTS` is the kill switch. New\n  saved state (`ObScriptLedger`, the `obscript_state` stores, `magic_effects` — each `register_saved`) is a\n  `FORMAT_MAJOR` question for `\u002Faudit-save`.\n- **Legacy load-order\u002Fextender path**: `attach_scpt_script` resolves SCPT via `ScriptRegistry` (logs an error\n  when the resource is absent); dialect selection is by *profile row*, pinned by\n  `obscript_dialect_follows_the_profile_not_the_game_kind`; source-less FNV\u002FFO3 bytecode is decoded\n  structurally (`decode_extender_calls`, only registered xNVSE\u002FxOBSE opcodes) and FO3 must not apply the\n  xNVSE table (`source_less_fo3_scpt_does_not_apply_xnvse_opcode_table`). Arguments\u002Fbytes obey the SDK caps\n  (`MAX_SCRIPT_CALL_BYTES`, `MAX_SCRIPT_STRING_BYTES`, `MAX_LEGACY_OBSCRIPT_NESTING`); the compatibility analysis\n  caps findings per script (`MAX_COMPATIBILITY_FINDINGS_PER_SCRIPT`) and retained entries per registry\n  (`MAX_COMPATIBILITY_RETAINED_ENTRIES`), logging the first truncation (#6024 `fcead3b9d`).\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_6.md`\n\n### Dimension 7: Provider \u002F Extender-Compatibility Layer (SKSE, JContainers, StorageUtil, ModEvent seam)\nPaths: `crates\u002Fscripting\u002Fsrc\u002F{papyrus_provider\u002F**,compatibility.rs}`, `crates\u002Fscripting\u002Ftests\u002Fextender_compat_e2e.rs`, `byroredux\u002Fsrc\u002Fextensions\u002F`, `crates\u002Fpex\u002Fsrc\u002Fcall_sites.rs` (consumer)\nFirst step: `cargo test -p byroredux-scripting -- papyrus_provider compatibility`; `cargo test -p byroredux --bin byroredux -- boot::schedule::system_access_declaration_tests`\nThis layer (~8.7k LOC scripting-side: `papyrus_provider\u002F` + `compatibility.rs`, incl. tests) was a reported coverage gap through 2026-09-14 (only its *seams* were\naudited). Its SDK half (`crates\u002Fsdk`: StorageUtil\u002FJContainers verbs, typed script values, limits, manifests)\nis `\u002Faudit-tooling`; audit here the runtime that consumes it.\n- **Untrusted-input**: preflight\u002Flowering run on `.pex`-derived data and provider manifests. `compatibility`\n  caps its script table (`MAX_COMPATIBILITY_SCRIPTS`, `truncated()` must surface); lowering recursion is capped\n  (`MAX_PROVIDER_HANDLER_NESTING` = 32 — an `elseif` chain counts its clause index into the depth so lowering and\n  the per-dispatch `validate_provider_statements` agree, #5656; `MAX_PROVIDER_FRAGMENT_BARRIERS` = 64 —\n  cap-before-descend); a literal `Utility.Wait` is capped at `MAX_PROVIDER_WAIT_SECONDS` (one game day) at\n  lowering so a mod cannot park immortal continuations in the bounded 4 096-slot queue, #5657 `05d8d5864` — the\n  same bound is shared by the fragment lowerer, the VM and `FragmentExecutionQueue`, #5681 `ef130cd6c` (Dim 2);\n  `execute_statements` runs on an explicit cursor stack, not a recursion per executed `If` (#5635 `afa5186a1`,\n  20 000 sequential `If`s on a 256 KiB stack; nesting depth is threaded through receiver chains too, and saved\n  `Wait` values obey the same cap, #6025); `papyrus_provider_system` groups ModEvent registrations by entity\n  once per frame and only when events are pending (#5640 `34a47ba81`). ModEvent runtime (#6018–#6025, `2f4b59041`):\n  registrations whose registrant no longer carries a provider program are pruned (entity ids are never\n  reclaimed), delivery runs under `MAX_PAPYRUS_MOD_EVENT_DELIVERIES_PER_FRAME` = 1 024 with the rest left queued in\n  order, owner FormIDs resolve per entity on demand, and a failing provider call keeps the registrations collected\n  before it. A reference's provider `OnInit` runs once, its first-init flag saved in `QuestScriptVariables` under\n  the reference FormID (#6017 `0b1f1545f`). Value sizes\n  obey `MAX_SCRIPT_ARRAY_ELEMENTS`\u002F`MAX_SCRIPT_CALL_BYTES`\u002F`MAX_PENDING_PAPYRUS_MOD_EVENTS` (256) \u002F\n  `MAX_PAPYRUS_MOD_EVENT_REGISTRATIONS` (4 096). `execute.rs` has\n  `unreachable!` arms guarded by \"validated …\" invariants — each must be truly established by lowering.\n  The `catching_panics` net (#3948) wraps the translate\u002Flower path; check whether runtime execution in\n  `papyrus_provider_system` has any equivalent (none found 2026-10-20: no `catch_unwind` under `papyrus_provider\u002F`, nor around the VM's run in `fragment\u002Fvm\u002Finterp.rs` — only the VM's ahead-of-time checks joined the net, #6000).\n- **Decline-on-unmodeled at the seam**: a provider call that cannot be typed declines the whole fragment\u002F\n  handler (`lower_provider_call` errors → `None`), it never lowers a prefix and silently drops the tail — nor\n  lowers a script's provider handlers while leaving its other handlers inert (`MixedScript`, #6021, Dim 1); a\n  `PapyrusProviderRuntime::default()` with a non-empty catalog but `callback: None` is not servable (Dim 1).\n- **Continuation persistence**: `PapyrusProviderContinuationQueue` and `FragmentExecutionQueue` are saved\n  resources; continuations must stay principal-owned and typed (no raw closures or process-local handles).\n  Locals holding `ScriptValue::Entity(EntityRef)` are session-scoped (`world_generation`) — they are dropped\n  after load by `drop_entity_bound_continuations` (#4139; `\u002Faudit-save` Dim 5 owns the ordering); any new\n  saved shape here is a `FORMAT_MAJOR` question (`\u002Faudit-save` Dim 2).\n- **Lock\u002Faccess**: `papyrus_provider_system` and `legacy_obscript_load_order_system` declare what they acquire\n  (the schedule tests scan bodies to 3 call hops); `extension_*` adapters run before `event_cleanup_system`\n  (`extension_event_adapters_run_before_transient_cleanup`). Any new SDK-state exposure that nests a resource\n  lock against `QuestStageState`\u002F`Inventory`\u002Fetc. is a Dim 2-class finding.\n- **Provider resolvers\u002Fcallbacks** (`set_papyrus_provider_{runtime,entity_resolver,form_resolver,\n  mod_event_publisher}`, `set_extension_script_function_invoker`, `set_legacy_obscript_content_catalog`) are\n  installed by boot\u002Fextension setup; an uninstalled resolver must degrade to a decline, not a panic.\n- Census\u002Finstrument: `crates\u002Fscripting\u002Fexamples\u002Fextender_preflight.rs`; docs: `feature-matrix.md`\u002FROADMAP M47.2\n  rows must acknowledge this layer (SCR-ORCH-2026-09-06-01).\n**Output**: `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_7.md`\n\n## Phase 3: Merge\n\nCombine `\u002Ftmp\u002Faudit\u002Fscripting\u002Fdim_*.md` into `docs\u002Faudits\u002FAUDIT_SCRIPTING_\u003CTODAY>.md`: **Executive Summary**\n(shipped vs deferred; findings by severity; **untrusted-input verdict** for the runtime-side decoders —\n`SCDA`, provider manifests — must be NO panic\u002FOOB\u002FOOM\u002Foverflow; frontends' verdict lives in the newest\n`AUDIT_PAPYRUS_*`) · **Decline-Invariant Audit** (every recognizer\u002Fcomposer\u002Feffect decline point ×\nverified-conservative vs leaks-a-partial-lowering) · **Runtime Lifecycle Matrix** (marker drain coverage;\ntwo-phase lock-drop per system; cascade bound; edge-trigger seed; CTDA OR-precedence; journal subscribers) ·\n**Findings** (CRITICAL first, deduplicated) · **Future-Phase Readiness** (invariants pinned for ObScript\nphase 2, alias follow-ups). Dedup ownership: marker-drain coverage = Dim 3 (pointers from others);\n`translate_pex` clean-`None` = Dim 1 (pointer from Dim 4); half-extent convention = Dim 4; cinematic router\u002F\ngate agreement = Dim 5 (pointer from Dim 3).\n\n## Phase 4: Cleanup\n\n`rm -rf \u002Ftmp\u002Faudit\u002Fscripting`; tell the user the report is ready; suggest\n`\u002Faudit-publish docs\u002Faudits\u002FAUDIT_SCRIPTING_\u003CTODAY>.md` (domain label `scripting`; add `quests` for\nQUST\u002Falias findings and the matching `game:*` for one title's scripts).\n",{"description":7,"argument-hint":44},"--focus \u003Cdimensions> --depth shallow|deep","main","6afdb791976ed2c24a6c7e61fcbe0cd1f8776061",".claude\u002Fcommands\u002Faudit-scripting",6,"https:\u002F\u002Fgithub.com\u002Fmatiaszanolli\u002FByroRedux","https:\u002F\u002Fgithub.com\u002Fmatiaszanolli","matiaszanolli.com","15+ years turning mate into code, and just getting started! All things Python and data lover overall. Music addict, always looking to unite music and tech.","2026-11-15 04:03:52",{"source":8,"skillName":5,"commands":55,"prompt":65,"zipAvailable":66},[56,59,62],{"tool":57,"command":58},"npx","npx skills add matiaszanolli\u002FByroRedux --skill audit-scripting",{"tool":60,"command":61},"bunx","bunx skills add matiaszanolli\u002FByroRedux --skill audit-scripting",{"tool":63,"command":64},"pnpm","pnpm dlx skills add matiaszanolli\u002FByroRedux --skill audit-scripting","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fmatiaszanolli\u002FByroRedux\u002Fblob\u002Fmain\u002F.claude\u002Fcommands\u002Faudit-scripting\u002FSKILL.md",true,[],[69,78,87,96,105,113],{"skillNo":70,"name":71,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":72,"categories":73,"keywords":74,"publishedAt":39},"01M6K028GPYDYZ5441BW6YDFNK","trace-flow","https:\u002F\u002Fgithub.com\u002Fmatiaszanolli\u002FByroRedux\u002Fblob\u002Fmain\u002F.zcode\u002Fcommands\u002Ftrace-flow\u002FSKILL.md",[],[75,76,77],"trace flow","trace","flow",{"skillNo":79,"name":80,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":81,"categories":82,"keywords":83,"publishedAt":39},"01M6K026GTTXBBXXCH09SDRNX6","session-close","https:\u002F\u002Fgithub.com\u002Fmatiaszanolli\u002FByroRedux\u002Fblob\u002Fmain\u002F.zcode\u002Fcommands\u002Fsession-close\u002FSKILL.md",[],[84,85,86],"close","session close","session",{"skillNo":88,"name":89,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":90,"categories":91,"keywords":92,"publishedAt":39},"01M6K024KA1JFTV7BGYFSZV2VV","legacy-lookup","https:\u002F\u002Fgithub.com\u002Fmatiaszanolli\u002FByroRedux\u002Fblob\u002Fmain\u002F.zcode\u002Fcommands\u002Flegacy-lookup\u002FSKILL.md",[],[93,94,95],"lookup","legacy lookup","Legacy",{"skillNo":97,"name":98,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":99,"categories":100,"keywords":101,"publishedAt":39},"01M6K022H36BJ35KB6MT2NHVH6","fix-issue","https:\u002F\u002Fgithub.com\u002Fmatiaszanolli\u002FByroRedux\u002Fblob\u002Fmain\u002F.zcode\u002Fcommands\u002Ffix-issue\u002FSKILL.md",[],[102,103,104],"issue","fix","fix issue",{"skillNo":106,"name":107,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":108,"categories":109,"keywords":110,"publishedAt":39},"01M6K0208JHG4WDJX143YKFF0W","audit-ui","https:\u002F\u002Fgithub.com\u002Fmatiaszanolli\u002FByroRedux\u002Fblob\u002Fmain\u002F.zcode\u002Fcommands\u002Faudit-ui\u002FSKILL.md",[],[111,112,20],"audit ui","ui",{"skillNo":114,"name":115,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":116,"categories":117,"keywords":118,"publishedAt":39},"01M6K01XPHAPHF9BPS4CG5DDWX","audit-tooling","https:\u002F\u002Fgithub.com\u002Fmatiaszanolli\u002FByroRedux\u002Fblob\u002Fmain\u002F.zcode\u002Fcommands\u002Faudit-tooling\u002FSKILL.md",[],[20,119,120],"audit tooling","tooling"]