summaryrefslogtreecommitdiff
path: root/src/ai/default
diff options
context:
space:
mode:
Diffstat (limited to 'src/ai/default')
-rw-r--r--src/ai/default/default.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/ai/default/default.cpp b/src/ai/default/default.cpp
index 24755a281..b28e2a2b8 100644
--- a/src/ai/default/default.cpp
+++ b/src/ai/default/default.cpp
@@ -338,7 +338,7 @@ static void AiHandleReplaceRoadVeh(Player *p)
BackuppedOrders orderbak[1];
EngineID veh;
- if (!IsRoadVehInDepotStopped(v)) {
+ if (!v->IsStoppedInDepot()) {
AiHandleGotoDepot(p, CMD_SEND_ROADVEH_TO_DEPOT);
return;
}
@@ -367,7 +367,7 @@ static void AiHandleReplaceAircraft(Player *p)
BackuppedOrders orderbak[1];
EngineID veh;
- if (!IsAircraftInHangarStopped(v)) {
+ if (!v->IsStoppedInDepot()) {
AiHandleGotoDepot(p, CMD_SEND_AIRCRAFT_TO_HANGAR);
return;
}
@@ -3578,7 +3578,7 @@ static void AiStateSellVeh(Player *p)
DoCommand(v->tile, v->index, 1, DC_EXEC, CMD_SELL_RAIL_WAGON);
} else if (v->type == VEH_ROAD) {
- if (!IsRoadVehInDepotStopped(v)) {
+ if (!v->IsStoppedInDepot()) {
if (v->current_order.type != OT_GOTO_DEPOT)
DoCommand(0, v->index, 0, DC_EXEC, CMD_SEND_ROADVEH_TO_DEPOT);
goto going_to_depot;
@@ -3586,7 +3586,7 @@ static void AiStateSellVeh(Player *p)
DoCommand(0, v->index, 0, DC_EXEC, CMD_SELL_ROAD_VEH);
} else if (v->type == VEH_AIRCRAFT) {
- if (!IsAircraftInHangarStopped(v)) {
+ if (!v->IsStoppedInDepot()) {
if (v->current_order.type != OT_GOTO_DEPOT)
DoCommand(0, v->index, 0, DC_EXEC, CMD_SEND_AIRCRAFT_TO_HANGAR);
goto going_to_depot;