[Bots] Fix rule Bots:FinishBuffing (#4788)

This commit is contained in:
nytmyr
2025-03-29 15:17:33 -05:00
committed by GitHub
parent deb298dda7
commit d554eb3423
4 changed files with 30 additions and 4 deletions
+8 -1
View File
@@ -9533,7 +9533,14 @@ bool Bot::CastChecks(uint16 spell_id, Mob* tar, uint16 spell_type, bool precheck
return false;
}
if (!BotHasEnoughMana(spell_id)) {
if (
!BotHasEnoughMana(spell_id) &&
(
!RuleB(Bots, FinishBuffing) ||
IsEngaged() ||
IsBotBuffSpellType(spell_type)
)
) {
LogBotSpellChecksDetail("{} says, 'Cancelling cast of {} due to !BotHasEnoughMana.'", GetCleanName(), GetSpellName(spell_id));
return false;
}