Vector3.RotateTowards Manual     Reference     Scripting  
Scripting > Runtime Classes > Vector3

static function RotateTowards (from : Vector3, to : Vector3, maxRadiansDelta : float, maxMagnitudeDelta : float) : Vector3


Rotates a vector/from/ towards to.

The vector will be rotated on an arc instead of being interpolated linearly. This is essentially the same as Vector3.Slerp but instead the function will ensure that the angular speed and change of magnitude never exceeds maxRadiansDelta and maxMagnitudeDelta.