mirror of
https://github.com/OpenTTD/OpenTTD
synced 2026-01-23 04:04:09 +01:00
Add: Road waypoint functionality
This commit is contained in:
committed by
rubidium42
parent
c6387c7784
commit
9c84e5df3f
@@ -427,6 +427,15 @@ static Order GetOrderCmdFromTile(const Vehicle *v, TileIndex tile)
|
||||
return order;
|
||||
}
|
||||
|
||||
/* check road waypoint */
|
||||
if (IsRoadWaypointTile(tile) &&
|
||||
v->type == VEH_ROAD &&
|
||||
IsTileOwner(tile, _local_company)) {
|
||||
order.MakeGoToWaypoint(GetStationIndex(tile));
|
||||
if (_settings_client.gui.new_nonstop != _ctrl_pressed) order.SetNonStopType(ONSF_NO_STOP_AT_ANY_STATION);
|
||||
return order;
|
||||
}
|
||||
|
||||
/* check buoy (no ownership) */
|
||||
if (IsBuoyTile(tile) && v->type == VEH_SHIP) {
|
||||
order.MakeGoToWaypoint(GetStationIndex(tile));
|
||||
|
||||
Reference in New Issue
Block a user