static void SetTransformVerticalAngle(Transform trans, float newAngle, float maxLookOffset = 3f) { Vector3 localRotation = trans.localEulerAngles; localRotation.x = MathExtensions.ClampAngle(newAngle, -90f + maxLookOffset, 90f - maxLookOffset); trans.localEulerAngles = localRotation; }