diff --git a/binaries/data/mods/public/simulation/components/UnitAI.js b/binaries/data/mods/public/simulation/components/UnitAI.js index ce377c4511..289661fbab 100644 --- a/binaries/data/mods/public/simulation/components/UnitAI.js +++ b/binaries/data/mods/public/simulation/components/UnitAI.js @@ -3170,7 +3170,8 @@ UnitAI.prototype.UnitFsmSpec = { // If this building was e.g. a farm of ours, the entities that received // the build command should start gathering from it - if ((oldData.force || oldData.autoharvest) && this.CanGather(msg.data.newentity)) + if ((oldData.force || oldData.autoharvest) && this.CanGather(msg.data.newentity) && + Engine.QueryInterface(msg.data.newentity, IID_ResourceSupply).IsAvailableTo(this.entity)) { this.PerformGather(msg.data.newentity, true, false); return;