Pre-Flight — WP-006 — 2026-11-13
Filled-in copy of docs/reference/pre-flight for WP-006. Verdict at the bottom.
Written before the first probe. The session continues the WP-001/WP-004/WP-005 session on Jeff’s “continue” after PRs #34 and #35 merged. The
tgifile-artnext steps name this run as step 3.
Header
- WP:
WP-006 - Title: Phantom archive format verification (Gen 1 vs Gen 2)
- Pre-flight date:
2026-11-13 - Targets generation(s): Gen 1 (Phantom), compared against Gen 1 (Showdown), per vision §Engine Lineage
- Targets disc(s): Phantom of the Knight, with Showdown as the reference
Pre-flight intent
Validating readiness for
WP-006. Verdict only.
Dependency check
| Prereq | Status in WORK_INDEX |
Locked on | Notes |
|---|---|---|---|
none listed (Depends on: —) |
n/a | n/a | |
| WP-001 (informs) | ✅ Done | 2026-11-13 | The header layout and --verify engine checks this run uses |
| WP-002 (informs) | ✅ Done | 2026-11-13 | tools/probe_art.py, the cel decoder |
| WP-004 (informs) | ✅ Done | 2026-11-13 | tools/probe_audio.py; see the scope amendment below |
Repo + disc state
- Working tree clean; HEAD on branch
claude/wp-006at5cc458b(=main) - Phantom files already cached at
C:\dev\scooby-engine\tools\exes\phantom\(2026-06-03). SHA-256 re-hashed this session:TGIFILE.ARTAC24E9AE…BF04,Scooby.exe619EA687…07EDandOBJECT.INI67B9EF79…7870match the tools/exes/README Phantom table. No mount is needed. - Doc-vs-data cross-check: VISION already says “Phantom: Gen 1 confirmed” (
TGIFILE.ARTon the disc, identicalbinkw32.dll), whiletgifile-art.mdandscooby-exe.mdstill say “predicted” and “pending”. Presence of a file namedTGIFILE.ARTis not a structural check, so this WP still has work to do. - WP text predates WP-001. WP-006 §Scope puts the name table at a fixed
0x0F60. WP-001 found the header is count-driven: object count at0x118, then the object descriptors, then the name count and 68-byte records. The name table’s offset therefore depends on the object count, and any fixed offset is wrong for a title with different counts. This run follows the header, not the WP’s offsets, and records why.
Phantom: C:\dev\scooby-engine\tools\exes\phantom\
Showdown: C:\dev\scooby-engine\tools\exes\showdown\
Scope lock
Allowed paths for WP-006:
docs/01-VISION.md (Engine Lineage Phantom text only)
docs/formats/tgifile-art.md (engine-generation line, Cross-title verification, Remaining unknowns, Next steps)
docs/formats/scooby-exe.md ("Pending: Phantom archive format" subsection only)
docs/formats/audio-archives.md (cross-title line only; see amendment)
docs/work-packets/WP-006-phantom-archive-format.md
docs/work-packets/WORK_INDEX.md
docs/reference/pre-flight-WP-006-2026-11-13.md
tools/probe_art.py (only if a Showdown-only assumption blocks the Phantom run)
Scope amendment: WP-006 lists “anything else on the Phantom disc” as out of scope. Running tools/probe_audio.py --verify on Phantom’s three .dat files costs one command and answers whether WP-004’s format holds for the second Gen 1 title. It is added here and reported separately from the archive verdict.
Local-only: rendered PNGs, decoded audio and any listings stay in the session scratchpad.
Forbidden: game data, decoded images or audio committed anywhere; engines/scooby/**.
Exit check: git diff --name-only origin/main..HEAD before opening the PR.
Risk review
| Risk | Likelihood | Impact | Mitigation |
|---|---|---|---|
Verdict on a 4-byte coincidence (the opening u32 happens to look like a room count) |
low | high | The WP’s own rule: the verdict needs the structural checks. This run goes further and runs the full --verify (every cel decoded, descriptors, name table, sequences, placements). |
Showdown-only assumptions in the tooling (the 20-name character table at 0x46A720 is Showdown’s) |
med | med | --verify does not use the character table. A Phantom --room render does, so any render is labelled with that caveat, or the table is read from Phantom’s own Scooby.exe. |
A failing check read as a format difference when it is a tool assumption (e.g. “0xB0/0xB8 tables empty” is a Showdown observation, not a format rule) |
med | med | Read each failure before deciding. A populated table is a finding about Phantom’s data, not a reason to call it another generation. |
| Copyright leak | low | high | Images and audio stay in the scratchpad |
Verdict
- READY TO EXECUTE
- NOT READY
Rationale: no prereqs; inputs cached and SHA-locked; the tools exist.
Prepared by: Claude (WP-001 session, continuing), on Jeff’s “continue” of 2026-11-13 Date: 2026-11-13
After execution — lessons learned
Lesson: a “magic number” can be a count. The WP’s Gen 1 marker 45 00 00 00 was Showdown’s room count. Phantom opens with 35 00 00 00 and is still Gen 1. Run the 4-byte test alone and it reads “not Gen 1”. Fixed offsets taken from one title (0x0F60, 0x0118) fail the same way once a count changes. The header walk and the full --verify are the test.
Lesson: comparing code is cheap once one binary is labelled. Masking absolute addresses and call targets and comparing the 71 WP-001 functions took one script and settled “same engine build”, not just “same file format”. Do this for any title with a labelled sibling before opening Ghidra on it.
Lesson: a strict check found real data. --verify failed on Phantom over a field Showdown leaves at zero. Reading the two failing steps, rather than loosening the check blindly, turned up a plausible per-step offset that the engine ignores.
Scope note: the lock held. Edits stayed in the listed files. The tools/probe_art.py change is the one the lock allowed: a Showdown-only assumption (step word always 0) that blocked the Phantom run.