Crusader_Decomp/USECODE/EUSECODE_extracted/readable_script_ir.tsv
MaddoScientisto de42fd1ea1 Add Crusader-specific USECODE data and documentation
- Introduced new file `vm_mask_ladder.tsv` containing detailed mappings for Crusader USECODE VM masks and their associated descriptors.
- Added comprehensive documentation in `scummvm-crusader-reference.md` outlining the structure, findings, and implications for reverse-engineering the Crusader engine within ScummVM.
- Created `usecode-roundtrip-ir.md` to document the plan for converting Crusader USECODE bytes into a human-readable format, detailing the container layout, event names, and intrinsic tables.
- Implemented a PowerShell script `temp_usecode_sample.ps1` for extracting and analyzing USECODE data from the Crusader FLX files, providing insights into class and event structures.
2026-03-22 17:26:39 +01:00

9.3 KiB

1template_idsectioncenter_indexcenter_labelattach_labelscallback_labelsneighbor_labelsevent_familiesruntime_opsmask_pairsowner_sourcemirror_writeselector_statusbridge_note
2jelyhack_anchor_attachmentJELYHACK anchor lane277JELYHACKREE_BOOT,SFXTRIGSURCAMNS,SURCAMEWBASEGUN,TIMER,SPECIAL,TRIGPAD,MONSTER,ELITE,D_ESTORM,DATALINK,SLIDEFLR,JELYH2,HOFFMAN,D_HOFFMAcallback-eventtrigger,boot-event-core,minimal-event-coreAPPEND_UNIQUE_INLINE,APPEND_UNIQUE_INDIRECT,REMOVE_MATCHING_INDIRECT,REMOVE_MATCHING_INLINE,MATERIALIZE_OR_FORWARD_VALUE,PREPEND_INLINE_PAYLOAD,BUILD_ENTITY_LINK_MATRIX,EMIT_OR_PUSHBACK_RESULT,FINALIZE_MIXED_VALUE_TO_OUTPTRindirect-only active-event-biased ladder; no direct anchor-specific mask proven000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedReferent-only anchors are now readable as payload owners, but the current mask ladder still correlates more strongly with active-event descriptors than with anchor-only rows.
3jelyhack_anchor_attachmentJELYHACK anchor lane280JELYH2REE_BOOT,SFXTRIGSURCAMEWSPECIAL,TRIGPAD,MONSTER,ELITE,D_ESTORM,JELYHACK,DATALINK,SLIDEFLR,HOFFMAN,D_HOFFMA,SKILLBOX,D_GURDSQ,VETRONboot-event-core,callback-eventtrigger,minimal-event-coreAPPEND_UNIQUE_INLINE,APPEND_UNIQUE_INDIRECT,REMOVE_MATCHING_INDIRECT,REMOVE_MATCHING_INLINE,MATERIALIZE_OR_FORWARD_VALUE,PREPEND_INLINE_PAYLOAD,BUILD_ENTITY_LINK_MATRIX,EMIT_OR_PUSHBACK_RESULT,FINALIZE_MIXED_VALUE_TO_OUTPTRindirect-only active-event-biased ladder; no direct anchor-specific mask proven000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedReferent-only anchors are now readable as payload owners, but the current mask ladder still correlates more strongly with active-event descriptors than with anchor-only rows.
4event_hub_clusterEVENT hub lane189COR_BOOTEVENT,NPCTRIGGRENADE,SCIENTIS,ROLL_NS,REB_COUP,MEDIKIT,K,CRUZTRIG,NPC_ONLYevent-hub,npc-triggerAPPEND_UNIQUE_INLINE,APPEND_UNIQUE_INDIRECT,REMOVE_MATCHING_INDIRECT,REMOVE_MATCHING_INLINE,MATERIALIZE_OR_FORWARD_VALUE,PREPEND_INLINE_PAYLOAD,BUILD_ENTITY_LINK_MATRIX,EMIT_OR_PUSHBACK_RESULT,FINALIZE_MIXED_VALUE_TO_OUTPTR0x0001:0000,0x0002:0001,0x0004:0002,0x0010:0004,0x0020:0005,0x0200:0009,0x0400:000a,0x0800:000b,0x1000:000c,0x2000:0015,0x4000:000e,0x8000:0007,0x8000:000f000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedThis is the strongest current descriptor-side bridge into the active event runtime lane: the neighborhood contains explicit event cores and matches the proven payload-chain plus link-matrix VM behavior.
5event_hub_clusterEVENT hub lane190EVENTCOR_BOOT,NPCTRIGSCIENTIS,ROLL_NS,REB_COUP,MEDIKIT,K,CRUZTRIG,NPC_ONLY,VMAILboot-event-core,npc-triggerAPPEND_UNIQUE_INLINE,APPEND_UNIQUE_INDIRECT,REMOVE_MATCHING_INDIRECT,REMOVE_MATCHING_INLINE,MATERIALIZE_OR_FORWARD_VALUE,PREPEND_INLINE_PAYLOAD,BUILD_ENTITY_LINK_MATRIX,EMIT_OR_PUSHBACK_RESULT,FINALIZE_MIXED_VALUE_TO_OUTPTR0x0001:0000,0x0002:0001,0x0004:0002,0x0010:0004,0x0020:0005,0x0200:0009,0x0400:000a,0x0800:000b,0x1000:000c,0x2000:0015,0x4000:000e,0x8000:0007,0x8000:000f000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedThis is the strongest current descriptor-side bridge into the active event runtime lane: the neighborhood contains explicit event cores and matches the proven payload-chain plus link-matrix VM behavior.
6event_hub_clusterEVENT hub lane191NPCTRIGCOR_BOOT,EVENTROLL_NS,REB_COUP,MEDIKIT,K,CRUZTRIG,NPC_ONLY,VMAIL,STORMTROboot-event-core,event-hubAPPEND_UNIQUE_INLINE,APPEND_UNIQUE_INDIRECT,REMOVE_MATCHING_INDIRECT,REMOVE_MATCHING_INLINE,MATERIALIZE_OR_FORWARD_VALUE,PREPEND_INLINE_PAYLOAD,BUILD_ENTITY_LINK_MATRIX,EMIT_OR_PUSHBACK_RESULT,FINALIZE_MIXED_VALUE_TO_OUTPTR0x0001:0000,0x0002:0001,0x0004:0002,0x0010:0004,0x0020:0005,0x0200:0009,0x0400:000a,0x0800:000b,0x1000:000c,0x2000:0015,0x4000:000e,0x8000:0007,0x8000:000f000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedThis is the strongest current descriptor-side bridge into the active event runtime lane: the neighborhood contains explicit event cores and matches the proven payload-chain plus link-matrix VM behavior.
7environmental_event_clusterEnvironmental event lane229FLAMEBOXWVENTNS,WVENTEW,REBEL_TV,SDOOR_N,SDOOR_E,EBRIDGE2,MCRATE,COPY_EW,COPY_NSAPPEND_UNIQUE_INLINE,APPEND_UNIQUE_INDIRECT,REMOVE_MATCHING_INDIRECT,REMOVE_MATCHING_INLINE,MATERIALIZE_OR_FORWARD_VALUE,PREPEND_INLINE_PAYLOAD,BUILD_ENTITY_LINK_MATRIX,EMIT_OR_PUSHBACK_RESULT,FINALIZE_MIXED_VALUE_TO_OUTPTR0x0001:0000,0x0002:0001,0x0004:0002,0x0010:0004,0x0020:0005,0x0200:0009,0x0400:000a,0x0800:000b,0x1000:000c,0x2000:0015,0x4000:000e,0x8000:0007,0x8000:000f000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedEnvironmental descriptors share the same active event field grammar, so they likely ride the same generic VM event lane even though no hazard-specific opcode split is proven yet.
8environmental_event_clusterEnvironmental event lane237NOSTRILCOPY_EW,COPY_NS,FLAME1,REB_PAD,VARDESK,BLASER1,REB_BOOT,UPPLATE,KEYPADNSAPPEND_UNIQUE_INLINE,APPEND_UNIQUE_INDIRECT,REMOVE_MATCHING_INDIRECT,REMOVE_MATCHING_INLINE,MATERIALIZE_OR_FORWARD_VALUE,PREPEND_INLINE_PAYLOAD,BUILD_ENTITY_LINK_MATRIX,EMIT_OR_PUSHBACK_RESULT,FINALIZE_MIXED_VALUE_TO_OUTPTR0x0001:0000,0x0002:0001,0x0004:0002,0x0010:0004,0x0020:0005,0x0200:0009,0x0400:000a,0x0800:000b,0x1000:000c,0x2000:0015,0x4000:000e,0x8000:0007,0x8000:000f000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedEnvironmental descriptors share the same active event field grammar, so they likely ride the same generic VM event lane even though no hazard-specific opcode split is proven yet.
9environmental_event_clusterEnvironmental event lane296STEAMBOXBOUNCBOX,HOVER1,STEAM1,FADE,PHIR,FLAME2,STEAM2,FLAMELP,BBOX,GBOX_NSAPPEND_UNIQUE_INLINE,APPEND_UNIQUE_INDIRECT,REMOVE_MATCHING_INDIRECT,REMOVE_MATCHING_INLINE,MATERIALIZE_OR_FORWARD_VALUE,PREPEND_INLINE_PAYLOAD,BUILD_ENTITY_LINK_MATRIX,EMIT_OR_PUSHBACK_RESULT,FINALIZE_MIXED_VALUE_TO_OUTPTR0x0001:0000,0x0002:0001,0x0004:0002,0x0010:0004,0x0020:0005,0x0200:0009,0x0400:000a,0x0800:000b,0x1000:000c,0x2000:0015,0x4000:000e,0x8000:0007,0x8000:000f000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedEnvironmental descriptors share the same active event field grammar, so they likely ride the same generic VM event lane even though no hazard-specific opcode split is proven yet.
10callback_trigger_clusterCallback trigger lane269SURCAMNSD_SOLD,D_VARG,D_COUR,D_SUSAN,D_THERM,BASEGUN,TIMER,SPECIAL,TRIGPAD,MONSTERMATERIALIZE_OR_FORWARD_VALUE,PUSH_FRAME_WORD_LITERAL,COMPARE_STREAM_DWORD_AND_PUSH_BOOL,FINALIZE_MIXED_VALUE_TO_OUTPTRno callback-specific mask pair proven; current ladder favors active event carriers000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedCallback/eventTrigger descriptors are structurally distinct from the active event lane, so the runtime bridge is still generic slot-backed context flow rather than a callback-specific opcode family.
11callback_trigger_clusterCallback trigger lane284SURCAMEWREE_BOOT,SFXTRIGSLIDEFLR,JELYH2,HOFFMAN,D_HOFFMA,SKILLBOX,D_GURDSQ,VETRON,DEATHBOXboot-event-core,minimal-event-coreMATERIALIZE_OR_FORWARD_VALUE,PUSH_FRAME_WORD_LITERAL,COMPARE_STREAM_DWORD_AND_PUSH_BOOL,FINALIZE_MIXED_VALUE_TO_OUTPTRno callback-specific mask pair proven; current ladder favors active event carriers000d:44df -> 000d:4c99 -> 000d:7000 -> (+0x10/+0x12) + 0x0d*slot + 4entity_vm_context_create_from_slot_index writes the same source pair to 0x39ca[context_slot]0x19/0x1a/0x1b proven in 000d:0988; 0x18 implied; upstream [BP-0x32] seed unresolvedCallback/eventTrigger descriptors are structurally distinct from the active event lane, so the runtime bridge is still generic slot-backed context flow rather than a callback-specific opcode family.