Browse Source

Fix invalid use of material reference.

Kim Kulling 3 years ago
parent
commit
174b2fcf59
1 changed files with 3 additions and 2 deletions
  1. 3 2
      code/AssetLib/ASE/ASEParser.cpp

+ 3 - 2
code/AssetLib/ASE/ASEParser.cpp

@@ -648,10 +648,11 @@ void Parser::ParseLV2MaterialBlock(ASE::Material &mat) {
                 // get a reference to the material
                 // get a reference to the material
                 if (iIndex < mat.avSubMaterials.size()) {
                 if (iIndex < mat.avSubMaterials.size()) {
                     Material &sMat = mat.avSubMaterials[iIndex];
                     Material &sMat = mat.avSubMaterials[iIndex];
+
+                    // parse the material block
+                    ParseLV2MaterialBlock(sMat);
                 }
                 }
 
 
-                // parse the material block
-                ParseLV2MaterialBlock(sMat);
                 continue;
                 continue;
             }
             }
         }
         }