Pseudocode decompialtion improvements and docs

This commit is contained in:
MaddoScientisto 2026-03-26 22:10:48 +01:00
commit 589bfc31ef
1898 changed files with 60634 additions and 6597 deletions

View file

@ -21,6 +21,23 @@ The most useful next upgrades are:
5. add corpus-level pattern clustering and family annotations
6. keep strengthening the runtime bridge back into the retail binary
## Current status
Implemented in the current local parser/exporter batch:
- first evidence-backed class/slot aliasing for spawned or called helpers, so common wrappers now render with class names and known slot names such as `FREE.waitNTimerTicks(...)` instead of raw `class_0A0C_slot_32(...)`
- first real loop-selector decoding for the common `nearby_items(...)` family/shape searches used by alarm and trigger bodies
- structured rendering now upgrades the simpler selector loops to real `for item in nearby_items(...)` output instead of raw `loopscr` comment runs
- a second common selector family now renders as readable `selector_0x42(arg0=..., arg1=..., arg2=..., origin=...)` signatures, and the simpler back-edge cases upgrade to `for ... in selector_0x42(...)` instead of raw `loopscr 0x42` comment runs
- full corpus export regenerated through `tools/export_usecode_pseudocode.py`, so the checked-in pseudocode corpus matches the improved renderer
Still open after this batch:
- broader selector mini-language coverage beyond the common `nearby_items(...)` forms and the currently opaque but readable `selector_0x42(...)` fallback
- more wrapper aliasing than the currently verified `FREE.waitNTimerTicks` seed entry
- a more authoritative opcode metadata table instead of the current mixed declarative/heuristic decoder
- corpus-level clustering/index outputs feeding back into inline annotations
## Priority 1: Authoritative opcode metadata
### What to borrow