Arrival steering behavior

In this demonstration, the green vehicle's goal is to move towards the target at the center of the window and to arrive there with zero velocity. The vehicle initialized to a random position a given distance from the target, moving at full speed in a random direction. When it reaches the target (indicated by a color change in the target symbol) the demonstration is restarted. The red circle indicates the maximum distance at which the vehicle may begin to slow down. The orange circle indicates the vehicle's speed, scaled so that its maximum speed corresponds to the size of the red circle. The vehicle's velocity is indicated by a magenta vector, and its steering force is indicated by a blue vector.

Because (in this implementation) "desired speed" varies linearly with distance to target, the orange circle would always touch the center of a perfectly agile vehicle (one with infinite acceleration). The deviation seen here between the orange circle and the vehicle's position is due to its limited agility.

From
Steering Behaviors for Autonomous Characters