mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-25 22:56:24 +00:00
fix(Core/Player): Check if the player can summon the warlock pet on B… (#18064)
fix(Core/Player): Check if the player can summon the warlock pet on BG ress
This commit is contained in:
@@ -105,6 +105,14 @@ void Pet::AddToWorld()
|
||||
|
||||
if (GetOwnerGUID().IsPlayer())
|
||||
{
|
||||
if (Player* owner = GetOwner())
|
||||
{
|
||||
if (getPetType() == SUMMON_PET && owner->getClass() == CLASS_WARLOCK)
|
||||
{
|
||||
owner->SetLastPetSpell(GetUInt32Value(UNIT_CREATED_BY_SPELL));
|
||||
}
|
||||
}
|
||||
|
||||
sScriptMgr->OnPetAddToWorld(this);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user