Răsfoiți Sursa

Fixed invalid armature node population when there's mesh on a node with the same name as the bone

Frooxius 5 ani în urmă
părinte
comite
29603128f4
1 a modificat fișierele cu 2 adăugiri și 1 ștergeri
  1. 2 1
      code/PostProcessing/ArmaturePopulate.cpp

+ 2 - 1
code/PostProcessing/ArmaturePopulate.cpp

@@ -150,7 +150,8 @@ void ArmaturePopulate::BuildNodeList(const aiNode *current_node,
     aiNode *child = current_node->mChildren[nodeId];
     aiNode *child = current_node->mChildren[nodeId];
     ai_assert(child);
     ai_assert(child);
 
 
-    nodes.push_back(child);
+    if (child->mNumMeshes == 0)
+        nodes.push_back(child);
 
 
     BuildNodeList(child, nodes);
     BuildNodeList(child, nodes);
   }
   }