mirror of
https://github.com/EQEmu/Server.git
synced 2026-04-19 21:02:41 +00:00
fix: only dismiss pet summoned by the fading familiar buff
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
This commit is contained in:
parent
ba2ca5eada
commit
d413ea4243
@ -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;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user