From 8d3e10dd11b77e9e45f7d5bb4086433ccf997356 Mon Sep 17 00:00:00 2001 From: Ovahlord Date: Thu, 28 Sep 2023 19:46:44 +0200 Subject: [PATCH] Core/Pets: do not use the spell Id of SPELL_EFFECT_CREATE_TAMED_PET spells in UNIT_CREATED_BY_SPELL to match sniff data --- src/server/game/Entities/Unit/Unit.cpp | 2 +- src/server/game/Spells/SpellEffects.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index caa0df8c1c..8ecfba522f 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -14316,7 +14316,7 @@ NewPet* Unit::SummonPet(uint32 creatureId, uint8 slot, uint32 spellId, bool asCl if (pet->IsHunterPet()) { // Hunter pets have some special settings - pet->SetByteFlag(UNIT_FIELD_BYTES_2, UNIT_BYTES_2_OFFSET_PET_FLAGS, UNIT_CAN_BE_ABANDONED | 0x4); + pet->SetByteFlag(UNIT_FIELD_BYTES_2, UNIT_BYTES_2_OFFSET_PET_FLAGS, UNIT_CAN_BE_ABANDONED); if (!playerPetData->HasBeenRenamed) pet->SetByteFlag(UNIT_FIELD_BYTES_2, UNIT_BYTES_2_OFFSET_PET_FLAGS, UNIT_CAN_BE_RENAMED); } diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index 1e88b55f49..c5121a4131 100644 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -5243,7 +5243,7 @@ void Spell::EffectCreateTamedPet(SpellEffIndex effIndex) Position pos = unitTarget->GetPosition(); unitTarget->MovePositionToFirstCollision(pos, DEFAULT_FOLLOW_DISTANCE_PET, float(M_PI_2)); - player->SummonPet(0, *slot, m_spellInfo->Id, true, pos); + player->SummonPet(0, *slot, 0, true, pos); } void Spell::EffectDiscoverTaxi(SpellEffIndex effIndex)