1
0
mirror of synced 2025-03-01 16:10:52 +01:00

Another importing fix from my stupid mistakes

This commit is contained in:
KillzXGaming 2019-07-05 19:28:49 -04:00
parent b10aaed86e
commit f5e7996bd3
4 changed files with 10 additions and 9 deletions

Binary file not shown.

View File

@ -202,7 +202,16 @@ namespace Switch_Toolbox.Library
if (scene.RootNode != null) if (scene.RootNode != null)
{ {
var idenity = Matrix4x4.Identity; var idenity = Matrix4x4.Identity;
var SklRoot = GetSklRoot(scene.RootNode, BoneNames);
if (SklRoot != null)
{
BuildSkeletonNodes(SklRoot, BoneNames, skeleton, ref idenity);
}
else
{
BuildSkeletonNodes(scene.RootNode, BoneNames, skeleton, ref idenity); BuildSkeletonNodes(scene.RootNode, BoneNames, skeleton, ref idenity);
}
skeleton.update(); skeleton.update();
skeleton.reset(); skeleton.reset();
@ -481,20 +490,12 @@ namespace Switch_Toolbox.Library
else else
{ {
if (node.HasChildren) if (node.HasChildren)
{
var SklRoot = GetSklRoot(node, boneNames);
if (SklRoot != null)
{
BuildSkeletonNodes(SklRoot, boneNames, skeleton, ref world);
}
else
{ {
foreach (Node child in node.Children) foreach (Node child in node.Children)
BuildSkeletonNodes(child, boneNames, skeleton, ref world); BuildSkeletonNodes(child, boneNames, skeleton, ref world);
} }
} }
} }
}
private List<Node> tempBoneNodes = new List<Node>(); private List<Node> tempBoneNodes = new List<Node>();
private void CreateByNode(Node node, STSkeleton skeleton, string ParentArmatureName, private void CreateByNode(Node node, STSkeleton skeleton, string ParentArmatureName,