|
Download docs/research/QVM_ANIMATION_TABLES.md from nmarshall/urt-rs: direct link, hf CLI and curl.
- Browser
- Download file 8.42 kB
-
https://huggingface.co/nmarshall/urt-rs/resolve/main/docs/research/QVM_ANIMATION_TABLES.md
- Command line
-
hf download hf://nmarshall/urt-rs/docs/research/QVM_ANIMATION_TABLES.md
-
curl -L -o QVM_ANIMATION_TABLES.md https://huggingface.co/nmarshall/urt-rs/resolve/main/docs/research/QVM_ANIMATION_TABLES.md
8.42 kB
| # Game-QVM animation assets, table loader and duration consumers | |
| RE-449–451 / F-196–198. [qvm-animation-tables.json](qvm-animation-tables.json) connects verified extracted player configs and their header to shipped qagame registration/helper20297 and the previously recovered timed-animation consumer. Reproduce with `python3 scripts/analyze_qvm_animation_tables.py`; check with `python3 scripts/test_qvm_animation_tables.py`. | |
| The report preserves both asset variants and provenance,76 rows per config, complete loader/registration instruction partitions, eleven prefix/load-failure probes, two signed-FPS probes and152 asset-duration bridges. The ordinary Git report contains derived analysis; original assets remain in their existing extracted locations under the repository's asset filters. No assets are modified or newly copied by this analysis. | |
| This is bounded synthetic instruction evaluation. The native token preprocessor and its ABI, original executable, complete QVM, playback and rendering do not execute. A strict parser recognizes only the observed numeric definitions, one include and nine-column rows; it supplies token integer values and handle/token success/EOF to the recorded callback boundaries. It is not a general C preprocessor. Actual filesystem search precedence, live table allocation/changes and invalid input/runtime behavior remain open. | |
| ## TABLE-001 — Verified variants, symbols and model registration (RE-449) | |
| All extraction manifests are searched for `models/animdef.h` and player `animation.cfg` members, retaining archive/member identity and checking each extracted payload against its recorded SHA-256. The observed header has one variant. The two configs are: | |
| | Asset path | Archive/member | Model selector from QVM registration | | |
| | --- | --- | --- | | |
| | models/players/athena/animation.cfg | zUrT43_005.pk3 /648 | 0 | | |
| | models/players/orion/animation.cfg | zUrT43_007.pk3 /3 | 1 | | |
| Their4131-byte payloads share SHA-256 `ef9a02aac32a97b4712c7bcd3ef4996ebf8b3b283746d67d7223dd23131cfa50`, but remain separate source records. The include header comes from zUrT43_008.pk3 member1; its SHA-256 and member metadata are retained separately. Multiple header variants currently cause an explicit ambiguity error rather than silently choosing one. Additional configuration paths without known registration require further analysis. | |
| Helper20280 records helper20297 with the literal Orion path at VM40563 and destination35021100, then the literal Athena path at40527 and destination35018540. It discards each returned value. Since the timed consumer uses base35018540 plus selector*2560, these calls establish Orion selector1 and Athena selector0 for these registered tables. The header declares `MAX_PLAYER_ANIMATIONS=80`;80 records ×32 bytes matches the2560 stride. Dynamic selector producers and legal ranges still need recovery. | |
| The observed definitions give the following source-level names for earlier numeric findings: | |
| | ID | Header name | Connection | | |
| | --- | --- | --- | | |
| | 25 | LEGS_SWIM | Posture helper's masked-animation low-height branch | | |
| | 26/28/30/32 | LEGS_JUMP / LEGS_JUMPRT / LEGS_BACKJUMP / LEGS_BACKJUMPRT | Earlier ground kick animation requests | | |
| | 36/37 | LEGS_STANDCR / LEGS_CRSTAND | Posture entry/exit requests | | |
| | 45 | TORSO_USE | Example timed torso row | | |
| This strengthens animation ID names using shipped definitions; it does not by itself establish every surrounding state/flag meaning or gameplay reachability. Both configs contain76 distinct indexed rows, omitting1 (`BOTH_WALLJUMP`) and77/78/79 (dual torso definitions). They need not be laid out in numeric ID order; symbol expansion determines the write index. | |
| ## TABLE-002 — Record layout, integer timing and partial-load behavior (RE-450) | |
| Helper20297 requests encoded target-579(path). A supplied zero handle returns0 without a close request. With a nonzero handle, it repeatedly requests target-581(handle, local token buffer). The integer word at buffer+8 supplies the animation index, then eight data tokens. The report supplies these values from the verified config/header parsing; native preprocessing/conversion semantics remain unverified. | |
| For each record at destination + index*32, observed writes are: | |
| | Byte offset | Derived value | | |
| | --- | --- | | |
| | +0 | Start frame (second token) | | |
| | +4 | Frame count (third token) | | |
| | +8 | Loop value (fifth token) | | |
| | +12 /+16 | Signed integer division1000/FPS (fourth token), truncating toward zero in the evaluator | | |
| | +20 | Flip value (sixth token) | | |
| | +24 | No write in this loader | | |
| | +28 | word[+16] + word[+12] × word[+4] | | |
| The remaining upper/lower/hit tokens are consumed but not stored by this helper. Their names come from the asset column comment; other consumers may use related data. No animation-index bounds check appears before the address arithmetic in this helper. The offline config parser restricts observed rows to0–79 and rejects duplicates; this validation is an analysis constraint, not a claimed guard in the original game. | |
| The duration expression is an initial interval plus one interval per counted frame, hence interval×(count+1), with QVM integer operations. For these small source values there is no overflow. FPS30 yields33, rather than a fractional33.333… interval. Synthetic FPS-30 yields-33 and FPS2000 yields0. Zero FPS reaches the evaluator's explicit division rejection; original error/crash behavior and preprocessing/legal-input guarantees remain unverified. | |
| Every token request can end the loop. With an opened source, EOF triggers target-580(handle), then return1—even if EOF occurs partway through a row. Earlier stores are retained; no rollback or record completion check occurs here. Eleven prefix probes cover zero through nine tokens plus failed open. In a complete nine-token row the three ignored values still must be read before +28 is assigned. Absent indices and +24 retain test sentinels, which prove lack of writes and are not a claim about runtime contents. A guard record beyond the80 analyzed slots remains unchanged. | |
| ## TABLE-003 — Asset-derived duration to timed helper (RE-451) | |
| For every loaded row in each config, one bridge passes the actual derived +28 word into helper39552 at that asset's registered model selector and animation index. The supplied address exactly matches destination + index*32 +28. All152 bridges evaluate the previously recovered torso setter child and final timer assignment, replacing arbitrary duration examples with source-derived table words for these requests. | |
| Examples shared by these identical configs: | |
| | ID/name | Start/count/FPS | Interval | Derived duration | | |
| | --- | --- | --- | --- | | |
| | 25 LEGS_SWIM | 440 /30 /30 | 33 | 1023 | | |
| | 36 LEGS_STANDCR | 600 /11 /25 | 40 | 480 | | |
| | 37 LEGS_CRSTAND | 611 /8 /25 | 40 | 360 | | |
| | 45 TORSO_USE | 384 /37 /45 | 22 | 836 | | |
| Passing all rows into the timed helper is a synthetic address/value compatibility check, not evidence that every row is requested as a torso animation during gameplay. It does not claim the posture caller uses table durations: that caller explicitly writes timer200 after helper39525, as already recovered. Playback interpolation, frame/loop/flip consumers and rendering remain unresolved. | |
| ## Validation and next tasks | |
| Eight independent tests check QVM/asset hashes and retained variant identity, literal registration destinations/selector mapping, definitions/row coverage/missing indices, every loaded record/token request and canary, partial writes/EOF/failed-open behavior, signed/zero-FPS model boundaries, all152 duration/child-helper bridges, strict parser failures, instruction partitions and explicit scope. Direct animation-contact and posture dependencies regenerate unchanged; the new report reproduces twice byte-identically. Full-suite/storage/link/whitespace outcomes are recorded in the ledger. | |
| RE-448 remains open for live allocation/producers, contact consumers and full state. RE-452 tracks native token/preprocessor ABI/search/include/define/error behavior, missing-index/+24 initialization and any later table writers, selector/request legality, animation frame/interpolation/loop/flip playback consumers, model/skeleton mapping and Bevy conversion, full posture/ground/contact/animation composition and gameplay/macOS/Linux/Solari validation. Resource production and broader packet/entity/player/snapshot/rendering milestones remain open. | |