Index: binaries/data/mods/public/simulation/components/Fogging.js =================================================================== --- binaries/data/mods/public/simulation/components/Fogging.js +++ binaries/data/mods/public/simulation/components/Fogging.js @@ -165,9 +165,7 @@ Fogging.prototype.OnOwnershipChanged = function(msg) { - // Always activate fogging for non-Gaia entities. - if (msg.to > 0) - this.Activate(); + this.Activate(); if (msg.to != -1) return; Index: binaries/data/mods/public/simulation/components/UnitAI.js =================================================================== --- binaries/data/mods/public/simulation/components/UnitAI.js +++ binaries/data/mods/public/simulation/components/UnitAI.js @@ -4293,19 +4293,13 @@ }; /** - * Returns true if the target exists and needs to be killed before - * beginning to gather resources from it. + * @return {boolean} - Whether the target exists and needs to be killed before + * beginning to gather resources from it. */ UnitAI.prototype.MustKillGatherTarget = function(ent) { - var cmpResourceSupply = Engine.QueryInterface(ent, IID_ResourceSupply); - if (!cmpResourceSupply) - return false; - - if (!cmpResourceSupply.GetKillBeforeGather()) - return false; - - return this.TargetIsAlive(ent); + const cmpResourceSupply = QueryMiragedInterface(ent, IID_ResourceSupply); + return cmpResourceSupply && cmpResourceSupply.GetKillBeforeGather() && this.TargetIsAlive(ent); }; /** Index: binaries/data/mods/public/simulation/templates/template_unit_fauna.xml =================================================================== --- binaries/data/mods/public/simulation/templates/template_unit_fauna.xml +++ binaries/data/mods/public/simulation/templates/template_unit_fauna.xml @@ -3,6 +3,7 @@ 0 + 4.0