[Bots] Cleanup AI_IdleCastCheck Logic (#3004)

* [Bots] Cleanup AI_IdleCastCheck Logic

* cleanup logic
This commit is contained in:
Aeadoin
2023-02-25 20:16:09 -05:00
committed by GitHub
parent a470931fdd
commit d2c3c14ae0
2 changed files with 47 additions and 27 deletions
+1
View File
@@ -2470,6 +2470,7 @@ void Bot::AI_Process()
}
// We also need a leash owner and follow mob (subset of primary AI criteria)
bot_group->VerifyGroup();
Client* leash_owner = (bot_group->GetLeader() && bot_group->GetLeader()->IsClient() ? bot_group->GetLeader()->CastToClient() : bot_owner);
if (!leash_owner) {
return;