(svn r16165) -Add [FS#2801] [NoAI]: several functions to AIOrder to check the what kind of order an order is.
-Fix: AIOrder::GetOrderDestination and AIOrder::GetOrderFlags didn't work on ORDER_CURRENT when the vehicle was loading/leaving in a station.
This commit is contained in:
@@ -160,6 +160,13 @@
|
||||
return AIObject::DoCommand(0, vehicle_id, 0, GetCmdSendToDepot(::GetVehicle(vehicle_id)));
|
||||
}
|
||||
|
||||
/* static */ bool AIVehicle::SendVehicleToDepotForServicing(VehicleID vehicle_id)
|
||||
{
|
||||
EnforcePrecondition(false, IsValidVehicle(vehicle_id));
|
||||
|
||||
return AIObject::DoCommand(0, vehicle_id, DEPOT_SERVICE, GetCmdSendToDepot(::GetVehicle(vehicle_id)));
|
||||
}
|
||||
|
||||
/* static */ bool AIVehicle::IsInDepot(VehicleID vehicle_id)
|
||||
{
|
||||
if (!IsValidVehicle(vehicle_id)) return false;
|
||||
|
Reference in New Issue
Block a user