summaryrefslogtreecommitdiff
path: root/src/ai/api/ai_vehicle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/ai/api/ai_vehicle.cpp')
-rw-r--r--src/ai/api/ai_vehicle.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/ai/api/ai_vehicle.cpp b/src/ai/api/ai_vehicle.cpp
index acf1a3bd8..91c3cf547 100644
--- a/src/ai/api/ai_vehicle.cpp
+++ b/src/ai/api/ai_vehicle.cpp
@@ -195,11 +195,7 @@
/* static */ bool AIVehicle::SkipToVehicleOrder(VehicleID vehicle_id, AIOrder::OrderPosition order_position)
{
- order_position = AIOrder::ResolveOrderPosition(vehicle_id, order_position);
-
- EnforcePrecondition(false, AIOrder::IsValidVehicleOrder(vehicle_id, order_position));
-
- return AIObject::DoCommand(0, vehicle_id, order_position, CMD_SKIP_TO_ORDER);
+ return AIOrder::SkipToOrder(vehicle_id, order_position);
}
/* static */ bool AIVehicle::ReverseVehicle(VehicleID vehicle_id)