src/ai/api/ai_vehicle.cpp
branchnoai
changeset 11000 51305152af09
parent 10999 f238f608f45c
child 11029 776c7cc8bda5
--- a/src/ai/api/ai_vehicle.cpp	Tue Jun 17 21:35:32 2008 +0000
+++ b/src/ai/api/ai_vehicle.cpp	Tue Jun 17 21:44:41 2008 +0000
@@ -200,7 +200,7 @@
 	byte vehstatus = v->vehstatus;
 
 	if (vehstatus & ::VS_CRASHED) return AIVehicle::VS_CRASHED;
-	if (vehstatus & ::VS_BROKEN) return AIVehicle::VS_BROKEN;
+	if (v->breakdown_ctr != 0) return AIVehicle::VS_BROKEN;
 	if (v->IsStoppedInDepot()) return AIVehicle::VS_IN_DEPOT;
 	if (vehstatus & ::VS_STOPPED) return AIVehicle::VS_STOPPED;
 	if (v->current_order.IsType(OT_LOADING)) return AIVehicle::VS_AT_STATION;