mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-30 18:45:38 +00:00
Bring ESM4 head part reading up-to-date with FO76
This commit is contained in:
parent
0b63fafc6d
commit
bd2ea715b4
2 changed files with 21 additions and 5 deletions
|
@ -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;
|
||||
|
|
|
@ -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<ESM::FormId> mExtraParts;
|
||||
|
||||
std::array<std::string, 3> mTriFile;
|
||||
ESM::FormId mBaseTexture;
|
||||
ESM::FormId mColor;
|
||||
std::vector<ESM::FormId> mValidRaces;
|
||||
|
||||
void load(ESM4::Reader& reader);
|
||||
// void save(ESM4::Writer& writer) const;
|
||||
|
|
Loading…
Reference in a new issue