diff options
| author | Yehonal <yehonal.azeroth@gmail.com> | 2017-08-20 04:59:52 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-08-20 04:59:52 +0200 |
| commit | c854b658828f66f69b13eb62c6a984de8e345b45 (patch) | |
| tree | 0118efcdd8898db4857961009f8eac79ca27b4d4 /src/scripts/Spells/spell_generic.cpp | |
| parent | fa147d84d29b6ebd99af6f8eb9eb39476d2f0228 (diff) | |
| parent | 0dd68dfbee97eb7ed2c9bd4109ba3f2aed697860 (diff) | |
Merge branch 'master' into master
Diffstat (limited to 'src/scripts/Spells/spell_generic.cpp')
| -rw-r--r-- | src/scripts/Spells/spell_generic.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/scripts/Spells/spell_generic.cpp b/src/scripts/Spells/spell_generic.cpp index d9dae48c23..880c3eeebd 100644 --- a/src/scripts/Spells/spell_generic.cpp +++ b/src/scripts/Spells/spell_generic.cpp @@ -2242,7 +2242,8 @@ class spell_pvp_trinket_wotf_shared_cd : public SpellScriptLoader enum AnimalBloodPoolSpell { SPELL_ANIMAL_BLOOD = 46221, - SPELL_SPAWN_BLOOD_POOL = 63471 + SPELL_SPAWN_BLOOD_POOL = 63471, + FACTION_DETHA_ATTACK = 942 }; class spell_gen_animal_blood : public SpellScriptLoader @@ -2266,13 +2267,20 @@ class spell_gen_animal_blood : public SpellScriptLoader // Remove all auras with spell id 46221, except the one currently being applied while (Aura* aur = GetUnitOwner()->GetOwnedAura(SPELL_ANIMAL_BLOOD, 0, 0, 0, GetAura())) GetUnitOwner()->RemoveOwnedAura(aur); + if (Unit* owner = GetUnitOwner()) + { + owner->setFaction(FACTION_DETHA_ATTACK); + } } void OnRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/) { if (Unit* owner = GetUnitOwner()) + { + owner->RestoreFaction(); if (owner->IsInWater()) owner->CastSpell(owner, SPELL_SPAWN_BLOOD_POOL, true); + } } void Register() |
