I’ve got this problem with mecanim lately. My model is boned in 3ds max (precisely following a tutorial) and it used to work just fine about a month ago, I was able to assign bones to body parts and all. But now when I click “configure” button in rig mode it will focus viewport on some random part of the model and pops this straight away:
NullReferenceException
UnityEngine.Transform.get_position () (at C:/BuildAgent/work/7535de4ca26c26ac/Runtime/ExportGenerated/Editor/UnityEngineTransform.cs:26)
UnityEditor.Handles.DoBoneHandle (UnityEngine.Transform target, System.Collections.Generic.Dictionary2 validBones) (at C:/BuildAgent/work/7535de4ca26c26ac/Editor/Mono/EditorHandles/BoneHandle.cs:43) UnityEditor.AvatarSkeletonDrawer.DrawSkeletonSubTree (System.Collections.Generic.Dictionary
2 actualBones, .BoneWrapper bones, Quaternion orientation, UnityEngine.Transform tr, Bounds bounds) (at C:/BuildAgent/work/7535de4ca26c26ac/Editor/Mono/Inspector/Avatar/AvatarSkeletonDrawer.cs:123)
UnityEditor.AvatarSkeletonDrawer.DrawSkeleton (UnityEngine.Transform reference, System.Collections.Generic.Dictionary`2 actualBones, .BoneWrapper bones) (at C:/BuildAgent/work/7535de4ca26c26ac/Editor/Mono/Inspector/Avatar/AvatarSkeletonDrawer.cs:56)
UnityEditor.AvatarMappingEditor.OnSceneGUI () (at C:/BuildAgent/work/7535de4ca26c26ac/Editor/Mono/Inspector/Avatar/AvatarMappingEditor.cs:745)
UnityEditor.AvatarEditor.OnSceneGUI () (at C:/BuildAgent/work/7535de4ca26c26ac/Editor/Mono/Inspector/Avatar/AvatarEditor.cs:405)
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:232)
System.Reflection.MethodBase.Invoke (System.Object obj, System.Object parameters) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MethodBase.cs:115)
UnityEditor.SceneView.CallOnSceneGUI () (at C:/BuildAgent/work/7535de4ca26c26ac/Editor/Mono/SceneView/SceneView.cs:1346)
UnityEditor.SceneView.HandleSelectionAndOnSceneGUI () (at C:/BuildAgent/work/7535de4ca26c26ac/Editor/Mono/SceneView/SceneView.cs:850)
UnityEditor.SceneView.OnGUI () (at C:/BuildAgent/work/7535de4ca26c26ac/Editor/Mono/SceneView/SceneView.cs:739)
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
The only change I can think of in the meantime is upgrading Unity to 4.1.2f1. Is it even possible that something changed dramatically in mecanim or is it something else? I have another model that uses biped and it doesn’t pop the error, but bone connections look completely out of place. Models are exported in FBX 2013, but also tried 2012 and there is no change. What might be the possible cause of this?