From 5cd3136170d9765df9b54f643184bf6511085ccb Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Tue, 16 Feb 2021 18:14:40 +0000 Subject: [PATCH] Fix: Autorenew failure advice due to bad refit being shown to all companies --- src/autoreplace_cmd.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/autoreplace_cmd.cpp b/src/autoreplace_cmd.cpp index aa4a23c4d9..3a4b6412d8 100644 --- a/src/autoreplace_cmd.cpp +++ b/src/autoreplace_cmd.cpp @@ -324,6 +324,8 @@ static CommandCost BuildReplacementVehicle(Vehicle *old_veh, Vehicle **new_vehic /* Does it need to be refitted */ CargoID refit_cargo = GetNewCargoTypeForReplace(old_veh, e, part_of_chain); if (refit_cargo == CT_INVALID) { + if (!IsLocalCompany()) return CommandCost(); + SetDParam(0, old_veh->index); int order_id = GetIncompatibleRefitOrderIdForAutoreplace(old_veh, e);