From caa0f6a044656be127f1820b6935a548057eb4a3 Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Mon, 6 Jul 2020 17:21:24 +0100 Subject: [PATCH] TBTR: Relax assert restriction on new train in TransferCargoForTrain --- src/tbtr_template_vehicle_func.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tbtr_template_vehicle_func.cpp b/src/tbtr_template_vehicle_func.cpp index c0c08a5f56..ec46805550 100644 --- a/src/tbtr_template_vehicle_func.cpp +++ b/src/tbtr_template_vehicle_func.cpp @@ -394,7 +394,7 @@ CommandCost TestBuyAllTemplateVehiclesInChain(TemplateVehicle *tv, TileIndex til */ void TransferCargoForTrain(Train *old_veh, Train *new_head) { - assert(new_head->IsPrimaryVehicle()); + assert(new_head->IsPrimaryVehicle() || new_head->IsFreeWagon()); CargoID _cargo_type = old_veh->cargo_type; byte _cargo_subtype = old_veh->cargo_subtype;