From e9339591c2a63f645a1808da07f2c3f1bca88acc Mon Sep 17 00:00:00 2001 From: phosit Date: Fri, 5 Sep 2025 13:09:18 +0200 Subject: [PATCH] Reset turnCach at the begin of the turn --- binaries/data/mods/public/simulation/ai/petra/basesManager.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/binaries/data/mods/public/simulation/ai/petra/basesManager.js b/binaries/data/mods/public/simulation/ai/petra/basesManager.js index 0d7e7b67cb..44689da1fc 100644 --- a/binaries/data/mods/public/simulation/ai/petra/basesManager.js +++ b/binaries/data/mods/public/simulation/ai/petra/basesManager.js @@ -130,6 +130,7 @@ BasesManager.prototype.createBase = function(gameState, ent, type = BaseManager. /** TODO check if the new anchorless bases should be added to addBase */ BasesManager.prototype.checkEvents = function(gameState, events) { + this.turnCache = {}; let addBase = false; for (const evt of events.Destroy) @@ -760,7 +761,6 @@ BasesManager.prototype.update = function(gameState, queues, events) { Engine.ProfileStart("BasesManager update"); - this.turnCache = {}; this.assignGatherers(); let nbBases = this.baseManagers.length; let activeBase = false;