(svn r6765) - Fix: Don't add up running cost of articulated engine parts.
authorpeter1138
Fri, 13 Oct 2006 15:15:22 +0000
changeset 4839 7b645d57a84f
parent 4838 af7376f8a68d
child 4840 a76d40e0aea4
(svn r6765) - Fix: Don't add up running cost of articulated engine parts.
train_cmd.c
--- a/train_cmd.c	Thu Oct 12 22:11:18 2006 +0000
+++ b/train_cmd.c	Fri Oct 13 15:15:22 2006 +0000
@@ -3560,7 +3560,7 @@
 		const RailVehicleInfo *rvi = RailVehInfo(v->engine_type);
 		if (rvi->running_cost_base > 0)
 			cost += rvi->running_cost_base * _price.running_rail[rvi->running_cost_class];
-	} while ((v = v->next) != NULL);
+	} while ((v = GetNextVehicle(v)) != NULL);
 
 	return cost;
 }