More fixes

TGB, ^cast, group/ae checks, in group/raid checks, inviting others bots to group, group disband fix, prevent rogue bs spam, ^follow fixes and cleanup, follow owner only by default when joining raid/group, group buff fixes for bots, range fixes for group buffs
This commit is contained in:
nytmyr
2024-10-31 07:32:16 -05:00
parent 32e37660d8
commit 4aa7a18b4f
17 changed files with 1053 additions and 670 deletions
+10 -2
View File
@@ -174,7 +174,7 @@ void bot_command_cast(Client* c, const Seperator* sep)
if (!tar->IsOfClientBot() && !(tar->IsPet() && tar->GetOwner() && tar->GetOwner()->IsOfClientBot())) {
c->Message(Chat::Yellow, "[%s] is an invalid target.", tar->GetCleanName());
return;
}
}
}
}
LogTestDebug("{}: Attempting {} on {}", __LINE__, c->GetSpellTypeNameByID(spellType), (tar ? tar->GetCleanName() : "NOBODY")); //deleteme
@@ -223,7 +223,7 @@ void bot_command_cast(Client* c, const Seperator* sep)
Bot* firstFound = nullptr;
for (auto bot_iter : sbl) {
if (!bot_iter->IsInGroupOrRaid()) {
if (!bot_iter->IsInGroupOrRaid(c)) {
continue;
}
@@ -248,6 +248,14 @@ void bot_command_cast(Client* c, const Seperator* sep)
continue;
}
if (
BOT_SPELL_TYPES_BENEFICIAL(spellType) &&
!RuleB(Bots, CrossRaidBuffingAndHealing) &&
!bot_iter->IsInGroupOrRaid(newTar, true)
) {
continue;
}
if (BOT_SPELL_TYPES_DETRIMENTAL(spellType, bot_iter->GetClass()) && !bot_iter->IsAttackAllowed(newTar)) {
bot_iter->BotGroupSay(
bot_iter,