DeltaAngle() public static method

public static DeltaAngle ( float current, float target ) : float
current float
target float
return float
Ejemplo n.º 1
0
 public static float MoveTowardsAngle(float current, float target, float maxDelta)
 {
     target = current + Mathf.DeltaAngle(current, target);
     return(Mathf.MoveTowards(current, target, maxDelta));
 }
Ejemplo n.º 2
0
 public static float SmoothDampAngle(float current, float target, ref float currentVelocity, float smoothTime, [DefaultValue("Mathf.Infinity")] float maxSpeed, [DefaultValue("Time.deltaTime")] float deltaTime)
 {
     target = current + Mathf.DeltaAngle(current, target);
     return(Mathf.SmoothDamp(current, target, ref currentVelocity, smoothTime, maxSpeed, deltaTime));
 }
Ejemplo n.º 3
0
 public static float SmoothDampAngle(float current, float target, ref float currentVelocity, float smoothTime, float maxSpeed, float deltaTime)
 {
     target = current + Mathf.DeltaAngle(current, target);
     return(Mathf.SmoothDamp(current, target, ref currentVelocity, smoothTime, maxSpeed, deltaTime));
 }