From ab06dcc442dffeaf21478b49d6a4d0ba9d9d1f9c Mon Sep 17 00:00:00 2001 From: QAston Date: Tue, 16 Jun 2009 22:46:17 +0200 Subject: "*Fix Kindred Spirits. *Fix typo causing auras SPELL_AURA_MOD_ATTACK_POWER_OF_ARMOR to modify ap with too big amount. --HG-- branch : trunk --- src/game/Unit.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/game/Unit.cpp') diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 4cef59a9037..e12b7ecd7ca 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -13340,6 +13340,12 @@ void Unit::AddPetAura(PetAura const* petSpell) if(GetTypeId() != TYPEID_PLAYER) return; + // Aura already added - not need to add it twice + // This check is to prevent existing pet having aura applied twice (passive auras can stack) + // if aura has more than 1 dummy effect + if (m_petAuras.find(petSpell)!= m_petAuras.end()) + return; + m_petAuras.insert(petSpell); if(Pet* pet = ((Player*)this)->GetPet()) pet->CastPetAura(petSpell); -- cgit v1.2.3