diff options
author | smatz <smatz@openttd.org> | 2009-07-01 23:49:13 +0000 |
---|---|---|
committer | smatz <smatz@openttd.org> | 2009-07-01 23:49:13 +0000 |
commit | ecfaa0564d9588b9f6826b1033d93b827751f410 (patch) | |
tree | f04dff76baabb0dcc7e952f9d81b70828398a740 /src/ai/api | |
parent | adc5363202629aa07c762f459d7e9f5bc78efa34 (diff) | |
download | openttd-ecfaa0564d9588b9f6826b1033d93b827751f410.tar.xz |
(svn r16718) -Codechange: make IsFreeWagon() member of Train
Diffstat (limited to 'src/ai/api')
-rw-r--r-- | src/ai/api/ai_vehicle.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ai/api/ai_vehicle.cpp b/src/ai/api/ai_vehicle.cpp index b1e4e0ad7..45e50ca4d 100644 --- a/src/ai/api/ai_vehicle.cpp +++ b/src/ai/api/ai_vehicle.cpp @@ -20,7 +20,7 @@ /* static */ bool AIVehicle::IsValidVehicle(VehicleID vehicle_id) { const Vehicle *v = ::Vehicle::GetIfValid(vehicle_id); - return v != NULL && v->owner == _current_company && (v->IsPrimaryVehicle() || (v->type == VEH_TRAIN && ::IsFreeWagon(v))); + return v != NULL && v->owner == _current_company && (v->IsPrimaryVehicle() || (v->type == VEH_TRAIN && ::Train::From(v)->IsFreeWagon())); } /* static */ int32 AIVehicle::GetNumWagons(VehicleID vehicle_id) |