From 4868823a5c6f0e1f4dceb986b97dde591a2de365 Mon Sep 17 00:00:00 2001 From: Dan Weatherford Date: Thu, 12 Oct 2023 01:33:16 -0500 Subject: [PATCH] Mark jaw-flap bone as a moving transform Prevents removal during 'Delete Unused GameObjects' optimization pass --- Editor/d4rkAvatarOptimizer.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Editor/d4rkAvatarOptimizer.cs b/Editor/d4rkAvatarOptimizer.cs index 84a56bc..ebf70f8 100644 --- a/Editor/d4rkAvatarOptimizer.cs +++ b/Editor/d4rkAvatarOptimizer.cs @@ -2305,6 +2305,11 @@ private HashSet FindAllMovingTransforms() transforms.Add(avDescriptor.customEyeLookSettings.upperRightEyelid); } + if (avDescriptor.lipSync == VRC.SDKBase.VRC_AvatarDescriptor.LipSyncStyle.JawFlapBone) + { + transforms.Add(avDescriptor.lipSyncJawBone); + } + var layers = avDescriptor.baseAnimationLayers.Select(a => a.animatorController).ToList(); layers.AddRange(avDescriptor.specialAnimationLayers.Select(a => a.animatorController)); foreach (var layer in layers.Where(a => a != null))