Skip to content

fix(mh3g): preserve companion mask mastery state - #41

Closed
VincentAdamNemessisX wants to merge 1 commit into
mainfrom
fix/mh3g-companion-mask-proficiency
Closed

fix(mh3g): preserve companion mask mastery state#41
VincentAdamNemessisX wants to merge 1 commit into
mainfrom
fix/mh3g-companion-mask-proficiency

Conversation

@VincentAdamNemessisX

Copy link
Copy Markdown
Contributor

Summary

  • correct the Cha-Cha/Kayamba record schema from one u32 prefix plus u16 scalars, instead of three u32 header fields
  • preserve the complete packed mask/mastery block at relative offsets 0xDE..0x140, including the historically mis-swapped pair at 0xE4
  • keep 0.0.3-0.0.6 conversion replay byte-identical for version detection, then repair matching historical fields without reverting later Wii U progress
  • update compatibility-field granularity, docs, played-save fixture boundaries, and the disabled legacy-wrapper markers

Root cause

The previous Lamp Mask fix inferred that companion-relative 0xE4 was an isolated endian-sensitive u16. Five paired 3DS -> Wii U transfer samples disprove that assumption: 0xDE..0x140 is byte-packed and remains identical on both platforms. The old transform changed values such as 18 00 into 00 18, so the companion status path observed a leading zero; quest serialization could then write zero back into the mask state.

The same paired samples also show that relative 0x04..0x0B consists of four u16 values, not two u32 values.

Evidence

  • cargo test -p mh3g-save-convert: 220 passed
  • native and x86_64-pc-windows-msvc clippy with -D warnings: passed
  • macOS Swift tests: 72 passed
  • macOS packaged-app synthetic smoke: passed
  • documentation and Windows source contracts: passed
  • supplied archive SHA-256: 0262a4c5353deca35fa1220d89c87414383bab1454509d06d14d6414f7827712
  • five paired saves, two companions each: zero byte differences across the confirmed 0x000..0x13F companion schema; packed 0xDE..0x13F equals the 3DS source in all ten records
  • real-sample compatibility repair detected 0.0.6 exactly, repaired ten companion fields, produced the same SHA-256 as a fresh corrected conversion (a1815a838bbe45cf33fc6db41efc4d5b438b53d7f6bc7d1704b78d56879b562c), and rollback removed the separate output successfully

Validation boundary

  • no Cemu gameplay/runtime test was performed
  • no real Azahar/Nemessix/Cemu MLC was modified
  • an already quest-normalized 00 00 conflict is preserved fail-closed; forcing recovery requires a paired before/after snapshot rather than guessing over later Wii U progress

@VincentAdamNemessisX
VincentAdamNemessisX requested a review from a team as a code owner August 12, 2026 08:41
@VincentAdamNemessisX

Copy link
Copy Markdown
Contributor Author

Superseded by #44. The mask/mastery fix is preserved there with the same stable patch-id, together with the paired-transfer Hunter's Notes correction and Windows repair-flow regression fix. Closing this standalone PR avoids a duplicate auto-release; attribution is retained in the cherry-picked commit.

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