path_speed


Description

You can use this variable to get or to set the speed of a path after it has been started. The speed is the number of pixels along the path that an instance should move each step, when the path node has a speed factor of 100. You can use negative values to signify that the instance should follow the path in reverse.

For functions relating to paths, see here.


Syntax:

path_speed;


Returns:

Real


Example:

path_speed = -1 + random(2);

The above code will set the instance to travel the path at a random speed between -1 and 1.