Open Rails

AETraveller.DistanceTo(WorldLocation) Method

[This is preliminary documentation and subject to change.]

Returns the distance from the traveller's current lcation, in its current direction, to the location specified

public float DistanceTo(
   WorldLocation location
);

Parameters

location
Target world location

Return Value

f the target is found, the distance from the traveller's current location, along the track nodes, to the specified location. If the target is not found, -1.

See Also

AETraveller Class | Orts.Formats.OR Namespace | AETraveller.DistanceTo Overload List