From d413ea424323d834e1dc3d9b01a720f7063be697 Mon Sep 17 00:00:00 2001 From: Roy Love Date: Fri, 10 Apr 2026 21:00:39 -0500 Subject: [PATCH] fix: only dismiss pet summoned by the fading familiar buff MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When a Familiar buff fades, BuffFadeBySlot called GetPet() and depopulated whatever pet the player currently had — regardless of whether that pet was the familiar or a combat pet summoned later. Add a spell ID check: only dismiss the pet if its PetSpellID matches the buff's spell ID. If the player replaced the familiar with a different pet, the new pet is unaffected when the old familiar buff expires. Fixes #5026 --- zone/spell_effects.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/zone/spell_effects.cpp b/zone/spell_effects.cpp index 7b29ca2c5..4930f1154 100644 --- a/zone/spell_effects.cpp +++ b/zone/spell_effects.cpp @@ -4394,9 +4394,9 @@ void Mob::BuffFadeBySlot(int slot, bool iRecalcBonuses) case SpellEffect::Familiar: { Mob *mypet = GetPet(); - if (mypet){ - if(mypet->IsNPC()) - mypet->CastToNPC()->Depop(); + if (mypet && mypet->IsNPC() && + mypet->CastToNPC()->GetPetSpellID() == buffs[slot].spellid) { + mypet->CastToNPC()->Depop(); SetPetID(0); } break;