Fix GetTargetIcons calls (thanks xuanfeng66)

This commit is contained in:
郑佩茹
2023-03-28 09:30:11 -06:00
parent 256b8c79f9
commit 4abe553f27
6 changed files with 8 additions and 8 deletions

View File

@@ -14,7 +14,7 @@ class FindLeastHpTargetStrategy : public FindTargetStrategy
{
if (Group* group = botAI->GetBot()->GetGroup())
{
ObjectGuid guid = group->GetTargetIcon(4);
ObjectGuid guid = group->GetTargetIcons()[4];
if (guid && attacker->GetGUID() == guid)
return;
}
@@ -46,7 +46,7 @@ class FindMaxHpTargetStrategy : public FindTargetStrategy
{
if (Group* group = botAI->GetBot()->GetGroup())
{
ObjectGuid guid = group->GetTargetIcon(4);
ObjectGuid guid = group->GetTargetIcons()[4];
if (guid && attacker->GetGUID() == guid)
return;
}