From a88c058ef0740b5e52484bb263e5310ee0f100a3 Mon Sep 17 00:00:00 2001 From: Jelle Meeus Date: Mon, 14 Jul 2025 10:23:55 +0200 Subject: [PATCH] fix(Core/AI): prevent PetAI autocast leap to self and allies (#22472) Co-authored-by: xomachine Co-authored-by: jackpoz --- src/server/game/AI/CoreAI/PetAI.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/server/game/AI/CoreAI/PetAI.cpp b/src/server/game/AI/CoreAI/PetAI.cpp index 042c0d583..5b3aad614 100644 --- a/src/server/game/AI/CoreAI/PetAI.cpp +++ b/src/server/game/AI/CoreAI/PetAI.cpp @@ -282,6 +282,14 @@ void PetAI::UpdateAI(uint32 diff) } } + if (spellInfo->HasEffect(SPELL_EFFECT_JUMP_DEST)) + { + if (!spellUsed) + delete spell; + + continue; // Pets must only jump to target + } + // No enemy, check friendly if (!spellUsed) {