[Avoid aoe] Fix friendly game object

This commit is contained in:
Yunfan Li
2024-04-15 22:22:10 +08:00
parent caa3eb6423
commit 47064cc0f4
2 changed files with 16 additions and 12 deletions

View File

@@ -59,6 +59,11 @@ GuidVector NearestTrapWithDamageValue::Calculate()
{
continue;
}
Unit* owner = go->GetOwner();
if (owner && owner->IsFriendlyTo(bot))
{
continue;
}
const GameObjectTemplate* goInfo = go->GetGOInfo();
if (!goInfo)
{