Skip to content

fix: P3D model info names after property_frequent - #46

Merged
TheWillard merged 1 commit into
mainfrom
fix/p3d-model-info-strings
Nov 5, 2026
Merged

TheWillard merged 1 commit into
mainfrom
fix/p3d-model-info-strings

Conversation

@TheWillard

Copy link
Copy Markdown
Contributor
  • ModelInfo: the u32 after property_frequent (version 31 and up) counts names that follow it. It was read as a plain unknown int, so a model with one name put everything after it off by the name's length: the shadow LOD arrays, the animations and the LOD addresses. Now read as ModelInfo::unknown_strings.
  • Test data: FFAA's invisibletargetvehicle.p3d in rv-test-data-part-4.7z, the only model with a name there (component01).

Checked by loading every P3D of Arma 3 (6,682, all load) and of 150 mods (~28,000): every real ODOL model loads. The ones that still fail are obfuscation decoys (junk names, garbage after a valid header) in 3CB Factions, Pr.1204, Tiger, Stargate and Blastcore. Some of them make the reader panic or abort on huge allocations, that follows in a separate PR.

- ModelInfo: the u32 after property_frequent (version 31 and up) counts
  names that follow it. It was read as a plain unknown int, so a model
  with one name put everything after it off by the name's length: the
  shadow LOD arrays, the animations and the LOD addresses. Now read as
  ModelInfo::unknown_strings. The only model with one in Arma 3 and
  ~28,000 mod models is FFAA's invisibletargetvehicle.p3d (component01),
  which loads now.
- Test data: the FFAA model in rv-test-data-part-4.7z.
@codecov

codecov Bot commented Nov 5, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@TheWillard
TheWillard merged commit ea4985f into main Nov 5, 2026
2 checks passed
@TheWillard
TheWillard deleted the fix/p3d-model-info-strings branch November 5, 2026 21:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant