mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-12 18:40:29 +00:00
(svn r24201) -Fix [FS#5170]: Mark group list dirty when setting/clearing autoreplace for an engine type.
This commit is contained in:
parent
fb63991851
commit
a9165d3f32
@ -769,7 +769,10 @@ CommandCost CmdSetAutoReplace(TileIndex tile, DoCommandFlag flags, uint32 p1, ui
|
||||
cost = RemoveEngineReplacementForCompany(c, old_engine_type, id_g, flags);
|
||||
}
|
||||
|
||||
if (flags & DC_EXEC) GroupStatistics::UpdateAutoreplace(_current_company);
|
||||
if (flags & DC_EXEC) {
|
||||
GroupStatistics::UpdateAutoreplace(_current_company);
|
||||
SetWindowClassesDirty(GetWindowClassForVehicleType(Engine::Get(old_engine_type)->type));
|
||||
}
|
||||
if ((flags & DC_EXEC) && IsLocalCompany()) InvalidateAutoreplaceWindow(old_engine_type, id_g);
|
||||
|
||||
return cost;
|
||||
|
Loading…
Reference in New Issue
Block a user