Exemple #1
0
 /// <summary>
 /// Add a new bone modifier. Make sure it doesn't exist yet.
 /// </summary>
 public void AddModifier(BoneModifier bone)
 {
     if (bone == null)
     {
         throw new ArgumentNullException(nameof(bone));
     }
     Modifiers.Add(bone);
     ModifiersFillInTransforms();
     bone.CollectBaseline();
 }
Exemple #2
0
        /// <summary>
        /// Force reset baseline of bones affected by dynamicbones
        /// to avoid overwriting dynamicbone animations
        /// </summary>
        private static void HandleDynamicBoneModifiers(BoneModifier modifier)
        {
#if KK || KKS || EC
            if (modifier.BoneName.StartsWith("cf_d_sk_", StringComparison.Ordinal) ||
                modifier.BoneName.StartsWith("cf_j_bust0", StringComparison.Ordinal) ||
                modifier.BoneName.StartsWith("cf_d_siri01_", StringComparison.Ordinal) ||
                modifier.BoneName.StartsWith("cf_j_siri_", StringComparison.Ordinal))
#elif AI || HS2
            if (modifier.BoneName.StartsWith("cf_J_SiriDam", StringComparison.Ordinal) ||
                modifier.BoneName.StartsWith("cf_J_Mune00", StringComparison.Ordinal))
#else
            todo fix
#endif
            {
                modifier.Reset();
                modifier.CollectBaseline();
            }
        }