summaryrefslogtreecommitdiff
path: root/src/ai
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2009-05-02 00:10:24 +0000
committerfrosch <frosch@openttd.org>2009-05-02 00:10:24 +0000
commitd518b3d0acf38509813daa0614559d267f196154 (patch)
treeb63f38d5da1c67e9a037b28ffdc0f043387b33e5 /src/ai
parenta22ff74ef205dc3409c7e743d24892960cdbb0b1 (diff)
downloadopenttd-d518b3d0acf38509813daa0614559d267f196154.tar.xz
(svn r16199) -Codechange: Pass OrderNonStopFlags also to MakeGoToDepotOrder().
-Fix: 'Go non-stop to nearest depot'-orders did not work wrt. the 'non-stop' part. -Fix: Adding 'Go to nearest depot'-orders did not respect the default setting for 'non-stop'.
Diffstat (limited to 'src/ai')
-rw-r--r--src/ai/api/ai_order.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ai/api/ai_order.cpp b/src/ai/api/ai_order.cpp
index fa397e6c0..20733c4f9 100644
--- a/src/ai/api/ai_order.cpp
+++ b/src/ai/api/ai_order.cpp
@@ -340,10 +340,10 @@ static const Order *ResolveOrder(VehicleID vehicle_id, AIOrder::OrderPosition or
* to a depot (other vehicle types). */
if (::GetVehicle(vehicle_id)->type == VEH_AIRCRAFT) {
if (!::IsTileType(destination, MP_STATION)) return false;
- order.MakeGoToDepot(::GetStationIndex(destination), odtf, odaf);
+ order.MakeGoToDepot(::GetStationIndex(destination), odtf, ONSF_STOP_EVERYWHERE, odaf);
} else {
if (::IsTileType(destination, MP_STATION)) return false;
- order.MakeGoToDepot(::GetDepotByTile(destination)->index, odtf, odaf);
+ order.MakeGoToDepot(::GetDepotByTile(destination)->index, odtf, ONSF_STOP_EVERYWHERE, odaf);
}
break;
}