Exemplo n.º 1
0
 /// <summary>
 /// Changes <see cref="IActor.Rotation"/> over Z-axis (Euler angle) over specified time using provided animation easing.
 /// </summary>
 public static async UniTask ChangeRotationZAsync(this IActor actor, float rotZ, float duration, EasingType easingType = default, CancellationToken cancellationToken = default)
 => await actor.ChangeRotationAsync(Quaternion.Euler(actor.Rotation.eulerAngles.x, actor.Rotation.eulerAngles.y, rotZ), duration, easingType, cancellationToken);