Meta reader: decode every member type the meta files use #422
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/holdmysocks--SixNG!422
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-422"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@holdmysocks on GitHub · 2026-11-26 23:04 UTC · original
holdmysocks:claude/meta-types→master· +84 −25 · 3 files · 2 commits · merged 2026-11-27 02:11 UTCUses the type table from the schema check in #400, where every file type code is matched to the executable's parser type across all meta files. The codes form families by high nibble:
Fixes
u32andf32payloads were the following fields. The three readers of["tag"](vehicle colours, the vehicle export, the GUI vehicle table) take the number and still accept older JSON.New decodes
Meta::scalarsnow goes through the full decoder for every plain-value type. It used to skip bool, s32, u64, half floats, vec2, matrices, enums, bit sets and strings, so readers that use it (lights, archetypes and others) now get those fields too.Checked
sixng meta dataandmeta packs --dump, old build against new, 20,442 resources. Before, the dumps held 5,934 tagged values and 23,494 undecoded values (u64, mat33v, both string types, 8-bit bit sets), plus 25 opaque arrays (u64 and enum elements). After, nothing is undecoded; 38 arrays of arrays (0x5c elements) stay opaque.sixng vehicles packs: the differences are enums as numbers, model names as text, and 32-bit-word bit sets.cargo test -p sixng-core --lib: all pass. The new test ismember_types_from_the_parser_tables.@holdmysocks on GitHub · 2026-11-27 02:27 UTC · original
Downstream check. I built this PR and master at the same commit (master merged in, conflict in the tests resolved) and ran the exports that read through the meta reader with both builds.
Byte-identical:
lights levels: sets, world, distant, LOD and timecycle files.pso data: 2,225 files.handling data.materials data.placements levelson 1,027 sampled map files.head_skins.json,part_skins.jsonandhair_links.json, rebuilt from scratch with each build.Also unchanged:
vehicles packs: the only differences are 5lamp_lightscolours. Two runs of the master build differ in exactly the same way, so that is existing run-to-run variation, not this PR.So this PR changes the raw
meta --dump/--instancesoutput (enums as numbers, 32-bit-word bit sets, the newly decoded types) and the fieldsMeta::scalarsreturns. No current export output changes. Not run:outfit,ped-variationsandgrooms. They read the same caches as above.