diff --git a/components/esm4/loadhdpt.cpp b/components/esm4/loadhdpt.cpp index 250a687042..c560ff5fac 100644 --- a/components/esm4/loadhdpt.cpp +++ b/components/esm4/loadhdpt.cpp @@ -48,6 +48,9 @@ void ESM4::HeadPart::load(ESM4::Reader& reader) case ESM4::SUB_EDID: reader.getZString(mEditorId); break; + case ESM::fourCC("XALG"): // FO76 + reader.get(mExtraFlags2); + break; case ESM4::SUB_FULL: reader.getLocalizedString(mFullName); break; @@ -58,7 +61,7 @@ void ESM4::HeadPart::load(ESM4::Reader& reader) reader.getZString(mModel); break; case ESM4::SUB_HNAM: - reader.getFormId(mAdditionalPart); + reader.getFormId(mExtraParts.emplace_back()); break; case ESM4::SUB_NAM0: // TES5 { @@ -87,15 +90,25 @@ void ESM4::HeadPart::load(ESM4::Reader& reader) case ESM4::SUB_TNAM: reader.getFormId(mBaseTexture); break; + case ESM4::SUB_CNAM: + reader.getFormId(mColor); + break; + case ESM4::SUB_RNAM: + reader.getFormId(mValidRaces.emplace_back()); + break; case ESM4::SUB_PNAM: reader.get(mType); break; case ESM4::SUB_MODT: // Model data case ESM4::SUB_MODC: case ESM4::SUB_MODS: - case ESM4::SUB_MODF: // Model data end - case ESM4::SUB_RNAM: - case ESM4::SUB_CNAM: + case ESM4::SUB_MODF: + case ESM::fourCC("ENLM"): + case ESM::fourCC("XFLG"): + case ESM::fourCC("ENLT"): + case ESM::fourCC("ENLS"): + case ESM::fourCC("AUUV"): + case ESM::fourCC("MODD"): // Model data end case ESM4::SUB_CTDA: reader.skipSubRecordData(); break; diff --git a/components/esm4/loadhdpt.hpp b/components/esm4/loadhdpt.hpp index aca3b0ca7b..5d17720100 100644 --- a/components/esm4/loadhdpt.hpp +++ b/components/esm4/loadhdpt.hpp @@ -43,6 +43,7 @@ namespace ESM4 { ESM::FormId mId; // from the header std::uint32_t mFlags; // from the header, see enum type RecordFlag for details + std::uint64_t mExtraFlags2; std::string mEditorId; std::string mFullName; @@ -70,10 +71,12 @@ namespace ESM4 Type_Eyelashes = 13, }; - ESM::FormId mAdditionalPart; + std::vector mExtraParts; std::array mTriFile; ESM::FormId mBaseTexture; + ESM::FormId mColor; + std::vector mValidRaces; void load(ESM4::Reader& reader); // void save(ESM4::Writer& writer) const;