From d5beb2bbe97afa0e50df8a2cef49bcac4a607f4a Mon Sep 17 00:00:00 2001 From: KingPin Date: Sun, 2 Nov 2008 16:53:46 -0600 Subject: [svn] *Implement new player conditions CONDITION_NO_AURA, CONDITION_ACTIVE_EVENT * Default behaviour of pets for creatures changed to REACT_DEFENSIVE * Disallowed sending wrapped items as COD * Prevent loading and saving single target auras for pet in same way as already implemented for player * Correctly limit use some flask types to zones. * Fixed extracting common.MPQ under *nix * Many small xleanups and fixes. ** mangos merge rev. TEST REV so be careful of creepy crawly bugs! --HG-- branch : trunk --- src/game/SpellEffects.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/game/SpellEffects.cpp') diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index bfa14d9cebb..9ac2d4f2ded 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -4073,12 +4073,12 @@ void Spell::EffectSummonPet(uint32 i) NewSummon->setPetType(SUMMON_PET); uint32 faction = m_caster->getFaction(); - if(m_caster->GetTypeId() == TYPEID_UNIT && ((Creature*)m_caster)->isTotem()) + if(m_caster->GetTypeId() == TYPEID_UNIT) { - Unit* owner = ((Totem*)m_caster)->GetOwner(); - if(owner) - faction = owner->getFaction(); - NewSummon->GetCharmInfo()->SetReactState(REACT_AGGRESSIVE); + if ( ((Creature*)m_caster)->isTotem() ) + NewSummon->GetCharmInfo()->SetReactState(REACT_AGGRESSIVE); + else + NewSummon->GetCharmInfo()->SetReactState(REACT_DEFENSIVE); } NewSummon->SetUInt64Value(UNIT_FIELD_SUMMONEDBY, m_caster->GetGUID()); -- cgit v1.2.3