From ddd48b61a28dcd9ce837bfd3fb0556d30faf9653 Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Thu, 16 May 2019 20:13:36 +0100 Subject: [PATCH] Unconditionally notify YAPF of track layout change in ChangeOwnershipOfCompanyItems --- src/economy.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/economy.cpp b/src/economy.cpp index 288a580471..8b9f00fec4 100644 --- a/src/economy.cpp +++ b/src/economy.cpp @@ -54,6 +54,7 @@ #include "tracerestrict.h" #include "tbtr_template_vehicle.h" #include "scope_info.h" +#include "pathfinder/yapf/yapf_cache.h" #include "table/strings.h" #include "table/pricebase.h" @@ -594,6 +595,8 @@ void ChangeOwnershipOfCompanyItems(Owner old_owner, Owner new_owner) IntialiseOrderDestinationRefcountMap(); + YapfNotifyTrackLayoutChange(INVALID_TILE, INVALID_TRACK); + cur_company.Restore(); MarkWholeScreenDirty();