From 4b0223976f2a4aabb0f8434ee41921673a35f3b1 Mon Sep 17 00:00:00 2001 From: frosch Date: Sun, 1 Feb 2009 11:38:18 +0000 Subject: (svn r15304) -Fix [FS#2587]: When loading savegames use the roadtype of the front vehicles just like it is done on construction. --- src/saveload/vehicle_sl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/saveload') diff --git a/src/saveload/vehicle_sl.cpp b/src/saveload/vehicle_sl.cpp index 1bde737d6..f5564e3f0 100644 --- a/src/saveload/vehicle_sl.cpp +++ b/src/saveload/vehicle_sl.cpp @@ -331,7 +331,7 @@ void AfterLoadVehicles(bool part_of_load) FOR_ALL_VEHICLES(v) { switch (v->type) { case VEH_ROAD: - v->u.road.roadtype = HasBit(EngInfo(v->engine_type)->misc_flags, EF_ROAD_TRAM) ? ROADTYPE_TRAM : ROADTYPE_ROAD; + v->u.road.roadtype = HasBit(EngInfo(v->First()->engine_type)->misc_flags, EF_ROAD_TRAM) ? ROADTYPE_TRAM : ROADTYPE_ROAD; v->u.road.compatible_roadtypes = RoadTypeToRoadTypes(v->u.road.roadtype); /* FALL THROUGH */ case VEH_TRAIN: -- cgit v1.2.3-70-g09d2