(svn r5891) -Code cleanup: cleaned up the code added in revision 5888
authorbjarni
Mon, 14 Aug 2006 16:18:41 +0000
changeset 4263 22d7a462e150
parent 4262 4657d940a84c
child 4264 88bd44d27954
(svn r5891) -Code cleanup: cleaned up the code added in revision 5888
vehicle.c
--- a/vehicle.c	Mon Aug 14 15:03:01 2006 +0000
+++ b/vehicle.c	Mon Aug 14 16:18:41 2006 +0000
@@ -102,10 +102,7 @@
 		return false; /* Crashed vehicles don't need service anymore */
 
 	if (_patches.no_servicing_if_no_breakdowns && _opt.diff.vehicle_breakdowns == 0) {
-		if (EngineReplacementForPlayer(GetPlayer(v->owner), v->engine_type) != INVALID_ENGINE)
-			return true; /* Vehicles set for autoreplacing needs to go to a depot even if breakdowns are turned off */
-		else
-			return false;
+		return EngineHasReplacementForPlayer(GetPlayer(v->owner), v->engine_type);  /* Vehicles set for autoreplacing needs to go to a depot even if breakdowns are turned off */
 	}
 
 	return _patches.servint_ispercent ?