User Tools

Site Tools


4rpl:commands:movetowards

Index
Math Utility

MoveTowards

MoveTowards(<-current <-target <-maxDistance) ->result

Description

Calculate a position between the points specified by current and target, moving no farther than the distance specified by maxDistance. Current, target are treated as vector3. MaxDistance is a float. Result is a vector3.

Examples

MoveTowards(GetUnitPosition(self) <-target 2) ->result

Index

4rpl/commands/movetowards.txt · Last modified: 2025/02/14 14:57 by 127.0.0.1