From de8adacb54570ca58aa233ed59e5210cefb6f497 Mon Sep 17 00:00:00 2001 From: Alexandre Avenel Date: Sat, 23 Jun 2018 20:25:31 +0200 Subject: [PATCH] Fix regression on FBX importer unit test box.fbx was broken since b28bcc commit. --- code/FBXMeshGeometry.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/code/FBXMeshGeometry.cpp b/code/FBXMeshGeometry.cpp index cc1a5a83e..8bfd60570 100644 --- a/code/FBXMeshGeometry.cpp +++ b/code/FBXMeshGeometry.cpp @@ -437,6 +437,9 @@ void ResolveVertexDataArray(std::vector& data_out, const Scope& source, // deal with this more elegantly and with less redundancy, but right // now it seems unavoidable. if (MappingInformationType == "ByVertice" && isDirect) { + if (!HasElement(source, indexDataElementName)) { + return; + } std::vector tempData; ParseVectorDataArray(tempData, GetRequiredElement(source, dataElementName));