[Attack target] Valid target check

This commit is contained in:
Yunfan Li
2024-06-28 20:09:04 +08:00
parent 7395acb660
commit 6abc8d51e9
2 changed files with 7 additions and 18 deletions

View File

@@ -27,9 +27,7 @@ bool InvalidTargetValue::Calculate()
target->isFeared() ||
target->HasUnitState(UNIT_STATE_ISOLATED) ||
target->IsFriendlyTo(bot) ||
!AttackersValue::IsValidTarget(target, bot) ||
// !bot->IsWithinDistInMap(target, sPlayerbotAIConfig->sightDistance) ||
!bot->IsWithinLOSInMap(target);
!AttackersValue::IsValidTarget(target, bot);
}
return !target;