public static bool FaceBlendShapeLateUpdate(FaceBlendShape __instance) { if (_needsFullCharaUpdate) { return(true); } // Don't update during loading screens if (_throttledDict.Count == 0) { return(false); } // If player is not found fall back to always updating if (!_playerPos.HasValue) { return(true); } // Update when player is close (4 units away) if ((__instance.transform.position - _playerPos.Value).sqrMagnitude < 4 * 4) { return(true); } return(false); }
public static void CalcBlendShapePostfix(FaceBlendShape __instance) { NewCalcBlendShape(__instance.MouthCtrl); __instance.MouthCtrl.CalculateBlendShape(); }