Implement ^discipline

This commit is contained in:
nytmyr
2024-12-29 20:01:18 -06:00
parent 1c01b716d5
commit a0c2abfedf
10 changed files with 1311 additions and 50 deletions
+21 -5
View File
@@ -649,6 +649,10 @@ bool Bot::AI_PursueCastCheck() {
continue;
}
if (AIBot_spells_by_type[currentCast.spellType].empty()) {
continue;
}
result = AttemptAICastSpell(currentCast.spellType, nullptr);
if (!result && IsBotSpellTypeBeneficial(currentCast.spellType)) {
@@ -721,6 +725,10 @@ bool Bot::AI_IdleCastCheck() {
continue;
}
if (AIBot_spells_by_type[currentCast.spellType].empty()) {
continue;
}
result = AttemptAICastSpell(currentCast.spellType, nullptr);
if (result) {
@@ -778,6 +786,10 @@ bool Bot::AI_EngagedCastCheck() {
continue;
}
if (AIBot_spells_by_type[currentCast.spellType].empty()) {
continue;
}
result = AttemptAICastSpell(currentCast.spellType, nullptr);
if (!result && IsBotSpellTypeBeneficial(currentCast.spellType)) {
@@ -1041,11 +1053,15 @@ std::vector<BotSpell_wPriority> Bot::GetPrioritizedBotSpellsBySpellType(Bot* bot
}
if (
!RuleB(Bots, EnableBotTGB) &&
IsGroupSpell(botSpellList[i].spellid) &&
!IsTGBCompatibleSpell(botSpellList[i].spellid) &&
!botCaster->IsInGroupOrRaid(tar, true)
) {
!botCaster->IsInGroupOrRaid(tar, true) &&
(
!RuleB(Bots, EnableBotTGB) ||
(
IsGroupSpell(botSpellList[i].spellid) &&
!IsTGBCompatibleSpell(botSpellList[i].spellid)
)
)
) {
continue;
}