This commit is contained in:
Perfare 2019-04-26 09:51:02 +08:00
parent 59be547a82
commit cefdf08873

View File

@ -463,13 +463,16 @@ namespace AssetStudio
{ {
meshR.m_GameObject.TryGet(out var m_GameObject); meshR.m_GameObject.TryGet(out var m_GameObject);
var frame = RootFrame.FindChild(m_GameObject.m_Name); var frame = RootFrame.FindChild(m_GameObject.m_Name);
frame.LocalPosition = RootFrame.LocalPosition; if (frame != null)
frame.LocalRotation = RootFrame.LocalRotation;
while (frame.Parent != null)
{ {
frame = frame.Parent;
frame.LocalPosition = RootFrame.LocalPosition; frame.LocalPosition = RootFrame.LocalPosition;
frame.LocalRotation = RootFrame.LocalRotation; frame.LocalRotation = RootFrame.LocalRotation;
while (frame.Parent != null)
{
frame = frame.Parent;
frame.LocalPosition = RootFrame.LocalPosition;
frame.LocalRotation = RootFrame.LocalRotation;
}
} }
} }