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

@@ -137,10 +137,16 @@ CastEnchantItemAction::CastEnchantItemAction(PlayerbotAI* botAI, std::string con
bool CastEnchantItemAction::isPossible()
{
if (!CastSpellAction::isPossible())
if (!CastSpellAction::isPossible()) {
botAI->TellMasterNoFacing("Impossible: " + spell);
return false;
}
uint32 spellId = AI_VALUE2(uint32, "spell id", spell);
bool ok = AI_VALUE2(Item*, "item for spell", spellId);
botAI->TellMasterNoFacing("spell: " + spell + ", spell id: " + std::to_string(spellId) + " item for spell: " + std::to_string(ok));
return spellId && AI_VALUE2(Item*, "item for spell", spellId);
}