summaryrefslogtreecommitdiff
path: root/src/articulated_vehicles.cpp
diff options
context:
space:
mode:
authorsmatz <smatz@openttd.org>2009-07-01 23:57:20 +0000
committersmatz <smatz@openttd.org>2009-07-01 23:57:20 +0000
commitd86e17d65adebad6f0213451b99645be3494ea45 (patch)
tree9e09a7d8cff8a641c8ee90ad463362fe534e6e44 /src/articulated_vehicles.cpp
parentecfaa0564d9588b9f6826b1033d93b827751f410 (diff)
downloadopenttd-d86e17d65adebad6f0213451b99645be3494ea45.tar.xz
(svn r16719) -Codechange: make IsArticulatedPart(), IsTrainEngine(), IsTrainWagon(), IsMultiheaded(), EngineHasArticPart() and IsRearDualheaded() members of Train
Diffstat (limited to 'src/articulated_vehicles.cpp')
-rw-r--r--src/articulated_vehicles.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/articulated_vehicles.cpp b/src/articulated_vehicles.cpp
index e325642f2..7936b1273 100644
--- a/src/articulated_vehicles.cpp
+++ b/src/articulated_vehicles.cpp
@@ -207,7 +207,7 @@ bool IsArticulatedVehicleCarryingDifferentCargos(const Vehicle *v, CargoID *carg
switch (v->type) {
case VEH_TRAIN:
- v = (EngineHasArticPart(Train::From(v)) ? GetNextArticPart(Train::From(v)) : NULL);
+ v = Train::From(v)->EngineHasArticPart() ? GetNextArticPart(Train::From(v)) : NULL;
break;
case VEH_ROAD:
@@ -254,7 +254,7 @@ void CheckConsistencyOfArticulatedVehicle(const Vehicle *v)
switch (v->type) {
case VEH_TRAIN:
- v = (EngineHasArticPart(Train::From(v)) ? GetNextArticPart(Train::From(v)) : NULL);
+ v = Train::From(v)->EngineHasArticPart() ? GetNextArticPart(Train::From(v)) : NULL;
break;
case VEH_ROAD: