fix(spell): paladin and dk aggro spell, warrior

This commit is contained in:
Yunfan Li
2023-06-11 15:55:36 +08:00
parent b11fad1a46
commit 33576bd969
21 changed files with 117 additions and 62 deletions

View File

@@ -60,6 +60,14 @@ bool ComboPointsAvailableTrigger::IsActive()
bool LoseAggroTrigger::IsActive()
{
Unit* mt = AI_VALUE(Unit*, "main tank");
if (mt) {
botAI->TellMasterNoFacing("Has aggro: " + std::to_string(AI_VALUE2(bool, "has aggro", "current target"))
+ " My main tank is: " + mt->GetName());
} else {
botAI->TellMasterNoFacing("Has aggro: " + std::to_string(AI_VALUE2(bool, "has aggro", "current target"))
+ " No main tank detected");
}
return !AI_VALUE2(bool, "has aggro", "current target");
}