From d40fb8bb2a6c29f20cdccee2d62ea4f42597e26c Mon Sep 17 00:00:00 2001 From: mehmed-faheim-arslan Date: Sat, 11 Apr 2026 14:39:22 +0100 Subject: [PATCH] run target tracking for all players- allies skipped tracking entirely. target can be a moving entity (siege tower, enemy unit), allies need the same update logic. --- .../mods/public/simulation/components/RallyPoint.js | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/binaries/data/mods/public/simulation/components/RallyPoint.js b/binaries/data/mods/public/simulation/components/RallyPoint.js index ce68589d5d..37089cce4a 100644 --- a/binaries/data/mods/public/simulation/components/RallyPoint.js +++ b/binaries/data/mods/public/simulation/components/RallyPoint.js @@ -37,14 +37,7 @@ RallyPoint.prototype.GetPositions = function(player = this.GetOwner()) if (!playerEntry) return []; - // for allied players, return positions directly without moving target tracking. - if (player !== this.GetOwner()) - return [...playerEntry.pos]; - - // (for owner only) update positions for moving target entities. - const cmpRangeManager = Engine.QueryInterface(SYSTEM_ENTITY, IID_RangeManager); - const cmpOwnership = Engine.QueryInterface(this.entity, IID_Ownership); // We must not affect the simulation state here, so copy the state const ret = []; @@ -56,9 +49,9 @@ RallyPoint.prototype.GetPositions = function(player = this.GetOwner()) if (!playerEntry.data[i]?.target || !this.TargetIsAlive(playerEntry.data[i].target)) continue; - // and visible - if (cmpRangeManager && cmpOwnership && - cmpRangeManager.GetLosVisibility(playerEntry.data[i].target, cmpOwnership.GetOwner()) != "visible") + // and visible to the player who set this rally point + if (cmpRangeManager && + cmpRangeManager.GetLosVisibility(playerEntry.data[i].target, player) != "visible") continue; // Get the actual position of the target entity