diff --git a/src/obj/NiGeomMorpherController.cpp b/src/obj/NiGeomMorpherController.cpp index 559795eba93aac7566039274c50c6c0f2c3021a6..9603a546990940548ed6f559283ebfc1b251325d 100644 --- a/src/obj/NiGeomMorpherController.cpp +++ b/src/obj/NiGeomMorpherController.cpp @@ -70,7 +70,7 @@ void NiGeomMorpherController::Read( istream& in, list<unsigned int> & link_stack NifStream( unknownInts1[i2], in, info ); }; }; - if ( info.version >= 0x14000005 ) { + if ( ( info.version >= 0x14000004 ) && ( info.userVersion == 10 ) ) { NifStream( numUnknownInts2, in, info ); unknownInts2.resize(numUnknownInts2); for (unsigned int i2 = 0; i2 < unknownInts2.size(); i2++) { @@ -126,7 +126,7 @@ void NiGeomMorpherController::Write( ostream& out, const map<NiObjectRef,unsigne NifStream( unknownInts1[i2], out, info ); }; }; - if ( info.version >= 0x14000005 ) { + if ( ( info.version >= 0x14000004 ) && ( info.userVersion == 10 ) ) { NifStream( numUnknownInts2, out, info ); for (unsigned int i2 = 0; i2 < unknownInts2.size(); i2++) { NifStream( unknownInts2[i2], out, info ); diff --git a/src/obj/NiMorphData.cpp b/src/obj/NiMorphData.cpp index ab907c0dadebffd19ea29a67a11d855a1fcb55c3..807c93bf81a86ef5e6f09aebbe89a7f921b50621 100644 --- a/src/obj/NiMorphData.cpp +++ b/src/obj/NiMorphData.cpp @@ -59,7 +59,10 @@ void NiMorphData::Read( istream& in, list<unsigned int> & link_stack, const NifI NifStream( morphs[i1].keys[i3], in, info, morphs[i1].interpolation ); }; }; - if ( ( info.version >= 0x0A01006A ) && ( info.version <= 0x14000004 ) ) { + if ( ( info.version >= 0x0A01006A ) && ( info.version <= 0x0A01006A ) ) { + NifStream( morphs[i1].unknownInt, in, info ); + }; + if ( info.version >= 0x14000004 ) { NifStream( morphs[i1].unknownInt, in, info ); }; morphs[i1].vectors.resize(numVertices); @@ -93,7 +96,10 @@ void NiMorphData::Write( ostream& out, const map<NiObjectRef,unsigned int> & lin NifStream( morphs[i1].keys[i3], out, info, morphs[i1].interpolation ); }; }; - if ( ( info.version >= 0x0A01006A ) && ( info.version <= 0x14000004 ) ) { + if ( ( info.version >= 0x0A01006A ) && ( info.version <= 0x0A01006A ) ) { + NifStream( morphs[i1].unknownInt, out, info ); + }; + if ( info.version >= 0x14000004 ) { NifStream( morphs[i1].unknownInt, out, info ); }; for (unsigned int i2 = 0; i2 < morphs[i1].vectors.size(); i2++) {