d4rkc0d3r / d4rkAvatarOptimizer

d4rkpl4y3r's VRChat Avatar 3.0 optimizer
MIT License
402 stars 17 forks source link

The VRCSDK build was aborted #73

Closed Pandaptable closed 11 months ago

Pandaptable commented 11 months ago

System.InvalidOperationException: Avatar is null. at UnityEngine.Animator.GetBoneTransform (UnityEngine.HumanBodyBones humanBoneId) [0x00011] in <9802f153e66043958995cd88a8668a6e>:0 at d4rkAvatarOptimizer.FindAllMovingTransforms () [0x00238] in .\Packages\d4rkpl4y3r.d4rkavataroptimizer\Editor\d4rkAvatarOptimizer.cs:2291 at d4rkAvatarOptimizer.FindAllUnmovingTransforms () [0x00029] in .\Packages\d4rkpl4y3r.d4rkavataroptimizer\Editor\d4rkAvatarOptimizer.cs:2346 at d4rkAvatarOptimizer.FindMovingParent () [0x00000] in .\Packages\d4rkpl4y3r.d4rkavataroptimizer\Editor\d4rkAvatarOptimizer.cs:3425 at d4rkAvatarOptimizer.CombineSkinnedMeshes () [0x0003b] in .\Packages\d4rkpl4y3r.d4rkavataroptimizer\Editor\d4rkAvatarOptimizer.cs:3444 at d4rkAvatarOptimizer.Optimize () [0x00184] in .\Packages\d4rkpl4y3r.d4rkavataroptimizer\Editor\d4rkAvatarOptimizer.cs:149 at d4rkpl4y3r.AvatarOptimizer.AvatarBuildHook.OnPreprocessAvatar (UnityEngine.GameObject avatarGameObject) [0x00045] in .\Packages\d4rkpl4y3r.d4rkavataroptimizer\Editor\AvatarBuildHook.cs:37 UnityEngine.Debug:LogError (object) d4rkpl4y3r.AvatarOptimizer.AvatarBuildHook:OnPreprocessAvatar (UnityEngine.GameObject) (at ./Packages/d4rkpl4y3r.d4rkavataroptimizer/Editor/AvatarBuildHook.cs:42) VRC.SDKBase.Editor.BuildPipeline.VRCBuildPipelineCallbacks:OnPreprocessAvatar (UnityEngine.GameObject) VRC.SDK3.Builder.VRCAvatarBuilder:ExportCurrentAvatarResource (UnityEngine.Object,bool,bool,string&,System.Action1<string>,System.Action1) VRC.SDK3.Builder.VRCAvatarBuilder:ExportAvatarBlueprint (UnityEngine.GameObject) VRC.SDK3A.Editor.VRCSdkControlPanelAvatarBuilder/d__106:MoveNext () (at ./Packages/com.vrchat.avatars/Editor/VRCSDK/SDK3A/VRCSdkControlPanelAvatarBuilder.cs:2081) UnityEngine.UnitySynchronizationContext:ExecuteTasks ()

The VRCSDK build was aborted because the VRCSDKPreprocessAvatarCallback 'AvatarBuildHook' reported a failure. UnityEngine.Debug:LogError (object) VRC.SDKBase.Editor.BuildPipeline.VRCBuildPipelineCallbacks:OnPreprocessAvatar (UnityEngine.GameObject) VRC.SDK3.Builder.VRCAvatarBuilder:ExportCurrentAvatarResource (UnityEngine.Object,bool,bool,string&,System.Action1<string>,System.Action1) VRC.SDK3.Builder.VRCAvatarBuilder:ExportAvatarBlueprint (UnityEngine.GameObject) VRC.SDK3A.Editor.VRCSdkControlPanelAvatarBuilder/d__106:MoveNext () (at ./Packages/com.vrchat.avatars/Editor/VRCSDK/SDK3A/VRCSdkControlPanelAvatarBuilder.cs:2081) UnityEngine.UnitySynchronizationContext:ExecuteTasks ()

d4rkc0d3r commented 11 months ago

Same issue as https://github.com/d4rkc0d3r/d4rkAvatarOptimizer/issues/65

There is an extra animator somewhere on your avatar. If you remove it it will work. Otherwise the bug is new in unity 2022 and will be fixed whenever I finish the next release.

Pandaptable commented 11 months ago

I'm 99% sure there are no extra animators...? I have looked

d4rkc0d3r commented 11 months ago

It might get added by other nondestructive tools like MA or VRCFury. Either that or your main animators avatar definition is null which would be extremely weird.