Changeset - r18022:eec2fa716cc6
[Not reviewed]
master
0 1 0
frosch - 13 years ago 2011-08-27 08:41:36
frosch@openttd.org
(svn r22847) -Fix (r22816): Wagons shall not be processed by autorenew.
1 file changed with 3 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/vehicle.cpp
Show inline comments
 
@@ -81,7 +81,9 @@ bool Vehicle::NeedsAutorenewing(const Co
 

	
 
	if (!c->settings.engine_renew) return false;
 
	if (this->age - this->max_age < (c->settings.engine_renew_months * 30)) return false;
 
	if (this->age == 0) return false; // rail cars don't age and lacks a max age
 

	
 
	/* Only engines need renewing */
 
	if (this->type == VEH_TRAIN && !Train::From(this)->IsEngine()) return false;
 

	
 
	return true;
 
}
0 comments (0 inline, 0 general)