Fix clone template from vehicle validation for artic vehicles.
This commit is contained in:
@@ -1130,7 +1130,7 @@ CommandCost CmdTemplateVehicleFromTrain(TileIndex tile, DoCommandFlag flags, uin
|
|||||||
return CMD_ERROR;
|
return CMD_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (Train *v = clicked; v != NULL; v = v->Next()) {
|
for (Train *v = clicked; v != NULL; v = v->GetNextUnit()) {
|
||||||
if (!IsEngineBuildable(v->engine_type, VEH_TRAIN, _current_company)) {
|
if (!IsEngineBuildable(v->engine_type, VEH_TRAIN, _current_company)) {
|
||||||
return_cmd_error(STR_ERROR_RAIL_VEHICLE_NOT_AVAILABLE + VEH_TRAIN);
|
return_cmd_error(STR_ERROR_RAIL_VEHICLE_NOT_AVAILABLE + VEH_TRAIN);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user