Fix AttackEntityInZone after eslint 'no-shadow'

Fix for 7b4cf11e25

Fixes: #7965
Signed-off-by: Ralph Sennhauser <ralph.sennhauser@gmail.com>
This commit is contained in:
Ralph Sennhauser
2025-05-22 17:46:15 +02:00
parent 8c85f32327
commit 72be06fd7f
@@ -5066,7 +5066,7 @@ UnitAI.prototype.AttackEntityInZone = function(ents)
{
var target = ents.find(entity =>
this.CanAttack(entity) &&
this.CheckTargetDistanceFromHeldPosition(entity, IID_Attack, this.GetBestAttackAgainst(target, true)) &&
this.CheckTargetDistanceFromHeldPosition(entity, IID_Attack, this.GetBestAttackAgainst(entity, true)) &&
(this.GetStance().respondChaseBeyondVision || this.CheckTargetIsInVisionRange(entity))
);
if (!target)