[Bug Fix] An Update to Xtarget to exclude Bot owned Temp/Swarm Pets (#4172)

* An Update to Xtarget to exclude Bot owned Temp/Swarm Pets

* Missing a parentheses

* Cleaned up logic.
This commit is contained in:
MortimerGreenwald 2024-03-08 12:29:53 -08:00 committed by GitHub
parent fef5108b0d
commit 96370e0298
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -6775,7 +6775,7 @@ void Client::UpdateClientXTarget(Client *c)
// IT IS NOT SAFE TO CALL THIS IF IT'S NOT INITIAL AGGRO
void Client::AddAutoXTarget(Mob *m, bool send)
{
if (m->IsBot() || (m->IsPet() && m->IsPetOwnerBot())) {
if (m->IsBot() || ((m->IsPet() || m->IsTempPet()) && m->IsPetOwnerBot())) {
return;
}