Core/Entities: allow guardian pets to inherit spellmods
This commit is contained in:
1 parent
6a7f15ecf4
commit
4eaa6b50b6
1 file changed
+2
-2
@@ -13210,13 +13210,13 @@ Player* Unit::GetSpellModOwner() const
|
||||
if (Player* player = const_cast<Unit*>(this)->ToPlayer())
|
||||
return player;
|
||||
|
||||
if (IsPet() || IsTotem())
|
||||
if (HasUnitTypeMask(UNIT_MASK_PET | UNIT_MASK_TOTEM | UNIT_MASK_GUARDIAN))
|
||||
{
|
||||
if (Unit* owner = GetOwner())
|
||||
if (Player* player = owner->ToPlayer())
|
||||
return player;
|
||||
}
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
///----------Pet responses methods-----------------
|
||||
|
||||
Reference in new issue
Block a user