Version: 2018.3 (switch to 2019.1)
LanguageEnglish
  • C#

Vector4.MoveTowards

public static Vector4 MoveTowards(Vector4 current, Vector4 target, float maxDistanceDelta);

Description

Moves a point current towards target.

This is essentially the same as Vector4.Lerp but instead the method will ensure that the speed never exceeds maxDistanceDelta. Negative values of maxDistanceDelta pushes the vector away from target.

Did you find this page useful? Please give it a rating: