summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-04-12 19:28:05 +0000
committerrubidium <rubidium@openttd.org>2009-04-12 19:28:05 +0000
commit8a39da7618779fe41c1a578e1c40ee531ab8116f (patch)
tree9f3f2df898495999702c56dd3549bfce62a62d6f /src
parent848404eea566add302bfbdc95aaeabab20a7d6fd (diff)
downloadopenttd-8a39da7618779fe41c1a578e1c40ee531ab8116f.tar.xz
(svn r16048) -Fix/Feature-ish [FS#2740]: don't warn that crashed vehicles are getting old; upgrading them is impossible (racetrack)
Diffstat (limited to 'src')
-rw-r--r--src/vehicle.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/vehicle.cpp b/src/vehicle.cpp
index d56759592..98cb45734 100644
--- a/src/vehicle.cpp
+++ b/src/vehicle.cpp
@@ -921,8 +921,8 @@ void AgeVehicle(Vehicle *v)
InvalidateWindow(WC_VEHICLE_DETAILS, v->index);
- /* Don't warn about non-primary or not ours vehicles */
- if (v->Previous() != NULL || v->owner != _local_company) return;
+ /* Don't warn about non-primary or not ours vehicles or vehicles that are crashed */
+ if (v->Previous() != NULL || v->owner != _local_company || (v->vehstatus & VS_CRASHED) != 0) return;
/* Don't warn if a renew is active */
if (GetCompany(v->owner)->engine_renew && GetEngine(v->engine_type)->company_avail != 0) return;