mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 22:37:02 +00:00
Cmangos commits applied
Cmangos commits applied
This commit is contained in:
parent
df3ab5df8e
commit
068c67b932
12 changed files with 261 additions and 138 deletions
|
|
@ -18416,7 +18416,7 @@ void Player::PetSpellInitialize()
|
|||
uint8 addlist = 0;
|
||||
data << uint8(addlist); // placeholder
|
||||
|
||||
if (pet->IsPermanentPetFor(this))
|
||||
if (pet->isControlled())
|
||||
{
|
||||
// spells loop
|
||||
for (PetSpellMap::const_iterator itr = pet->m_spells.begin(); itr != pet->m_spells.end(); ++itr)
|
||||
|
|
@ -21328,7 +21328,7 @@ struct UpdateZoneDependentPetsHelper
|
|||
explicit UpdateZoneDependentPetsHelper(Player* _owner, uint32 zone, uint32 area) : owner(_owner), zone_id(zone), area_id(area) {}
|
||||
void operator()(Unit* unit) const
|
||||
{
|
||||
if (unit->GetTypeId() == TYPEID_UNIT && ((Creature*)unit)->IsPet() && !((Pet*)unit)->IsPermanentPetFor(owner))
|
||||
if (unit->GetTypeId() == TYPEID_UNIT && ((Creature*)unit)->IsPet() && !((Pet*)unit)->isControlled())
|
||||
if (uint32 spell_id = unit->GetUInt32Value(UNIT_CREATED_BY_SPELL))
|
||||
if (SpellEntry const* spellEntry = sSpellStore.LookupEntry(spell_id))
|
||||
if (sSpellMgr.GetSpellAllowedInLocationError(spellEntry, owner->GetMapId(), zone_id, area_id, owner) != SPELL_CAST_OK)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue