(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'.
This commit is contained in:
@@ -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;
|
||||
}
|
||||
|
Reference in New Issue
Block a user