diff options
-rw-r--r-- | sql/updates/1694_world.sql | 16 | ||||
-rw-r--r-- | src/game/SharedDefines.h | 1 | ||||
-rw-r--r-- | src/game/SpellAuras.cpp | 23 | ||||
-rw-r--r-- | src/game/SpellEffects.cpp | 23 | ||||
-rw-r--r-- | src/game/Unit.cpp | 26 |
5 files changed, 67 insertions, 22 deletions
diff --git a/sql/updates/1694_world.sql b/sql/updates/1694_world.sql new file mode 100644 index 00000000000..627c9e446fd --- /dev/null +++ b/sql/updates/1694_world.sql @@ -0,0 +1,16 @@ +-- Sanctified wrath +INSERT INTO `spell_proc_event` VALUES (57318, 0x00, 10, 0x00000000, 0x00002000, 0x00000000, 0x00004000, 0x00000000, 0.000000, 0.000000, 6); +INSERT INTO `spell_proc_event` VALUES (53375, 0x00, 10, 0x00000000, 0x00002000, 0x00000000, 0x00004000, 0x00000000, 0.000000, 0.000000, 6); + +-- Star Sinner +DELETE FROM `spell_proc_event` WHERE `entry` IN (54738); +INSERT INTO `spell_proc_event` VALUES (54738, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000002, 0.000000, 0.000000, 45); + +-- Tentacles +DELETE FROM `spell_proc_event` WHERE `entry` IN (61618); +INSERT INTO `spell_proc_event` VALUES (61618, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0.000000, 0.000000, 45); + +-- Demonic Sacriface +DELETE FROM `spell_bonus_data` WHERE `entry` = 18790; +INSERT INTO `spell_bonus_data` (`entry`,`direct_bonus`,`dot_bonus`,`ap_bonus`,`comments`) VALUES +('18790','0','0','0','Warlock - Fel Stamina'); diff --git a/src/game/SharedDefines.h b/src/game/SharedDefines.h index cc425083074..e86f537ab5a 100644 --- a/src/game/SharedDefines.h +++ b/src/game/SharedDefines.h @@ -2166,6 +2166,7 @@ enum SummonType SUMMON_TYPE_UNKNOWN5 = 409, SUMMON_TYPE_POSESSED3 = 427, SUMMON_TYPE_POSESSED2 = 428, + SUMMON_TYPE_WILD2 = 429, SUMMON_TYPE_FORCE_OF_NATURE = 669, SUMMON_TYPE_GUARDIAN2 = 1161 }; diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index c378c01371e..7639e8e7619 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -3295,20 +3295,23 @@ void Aura::HandleModStealth(bool apply, bool Real) } } - // Master of Subtlety - Unit::AuraList const& mDummyAuras = m_target->GetAurasByType(SPELL_AURA_DUMMY); - for(Unit::AuraList::const_iterator i = mDummyAuras.begin();i != mDummyAuras.end(); ++i) + if (Real) { - if ((*i)->GetSpellProto()->SpellIconID == 2114 && Real) + // Master of Subtlety + Unit::AuraList const& mDummyAuras = m_target->GetAurasByType(SPELL_AURA_DUMMY); + for(Unit::AuraList::const_iterator i = mDummyAuras.begin();i != mDummyAuras.end(); ++i) { - if (apply) + if ((*i)->GetSpellProto()->SpellIconID == 2114) { - int32 bp = (*i)->GetModifier()->m_amount; - m_target->CastCustomSpell(m_target,31665,&bp,NULL,NULL,true); + if (apply) + { + int32 bp = (*i)->GetModifier()->m_amount; + m_target->CastCustomSpell(m_target,31665,&bp,NULL,NULL,true); + } + else + m_target->CastSpell(m_target,31666,true); + break; } - else - m_target->CastSpell(m_target,31666,true); - break; } } } diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index 01bf60ccde1..cf96a3cd19d 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -3331,6 +3331,7 @@ void Spell::EffectSummonType(uint32 i) EffectSummonGuardian(i); break; case SUMMON_TYPE_WILD: + case SUMMON_TYPE_WILD2: EffectSummonWild(i); break; case SUMMON_TYPE_DEMON: @@ -6242,24 +6243,22 @@ void Spell::EffectDispelMechanic(uint32 i) uint32 mechanic = m_spellInfo->EffectMiscValue[i]; + std::deque <Aura *> dispel_list; + Unit::AuraMap& Auras = unitTarget->GetAuras(); - for(Unit::AuraMap::iterator iter = Auras.begin(), next; iter != Auras.end(); iter = next) + for(Unit::AuraMap::iterator iter = Auras.begin(), next; iter != Auras.end(); iter++) { - next = iter; - ++next; - SpellEntry const *spell = sSpellStore.LookupEntry(iter->second->GetSpellProto()->Id); if (!iter->second->GetDispelChance(this)) continue; + SpellEntry const *spell = iter->second->GetSpellProto(); if(spell->Mechanic == mechanic || spell->EffectMechanic[iter->second->GetEffIndex()] == mechanic) - { - unitTarget->RemoveAurasDueToSpell(spell->Id); - if(Auras.empty()) - break; - else - next = Auras.begin(); - } + dispel_list.push_back(iter->second); + } + for(;!dispel_list.empty();) + { + unitTarget->RemoveAurasDueToSpell(dispel_list.front()->GetId()); + dispel_list.pop_front(); } - return; } void Spell::EffectSummonDeadPet(uint32 /*i*/) diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index da76612bec7..8fb5d008c66 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -496,6 +496,21 @@ void Unit::RemoveSpellsCausingAuraWithDispel(AuraType auraType, Spell * spell) return; } } + + std::deque <Aura *> dispel_list; + + AuraList const& dispelAuras = GetAurasByType(auraType); + for(AuraList::const_iterator itr = dispelAuras.begin(); itr != dispelAuras.end(); ++itr) + { + if (!(*iter)->GetDispelChance( spell)) + continue; + dispel_list.push_back(*iter); + } + for(;!dispel_list.empty();) + { + RemoveAurasDueToSpell(dispel_list.front()->GetId()); + dispel_list.pop_front(); + } } void Unit::RemoveAurasWithInterruptFlags(uint32 flag, uint32 except) @@ -5547,6 +5562,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAu return false; basepoints0 = triggerAmount * GetMaxHealth() / 100; triggered_spell_id = 34299; + break; } // Healing Touch (Dreamwalker Raiment set) case 28719: @@ -5650,6 +5666,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAu { triggered_spell_id = 60889; basepoints0 = triggerAmount * GetMaxPower(POWER_MANA) / 100; + break; } break; } @@ -5769,6 +5786,15 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAu basepoints0 = GetAttackTime(BASE_ATTACK) * int32(ap*0.022f + 0.044f * holy) / 1000; break; } + // Sanctified Wrath + if (dummySpell->SpellIconID == 3029) + { + triggered_spell_id = 57318; + target = this; + basepoints0 = triggerAmount; + CastCustomSpell(target,triggered_spell_id,&basepoints0,&basepoints0,NULL,true,castItem,triggeredByAura); + return true; + } // Sacred Shield if (dummySpell->SpellFamilyFlags[1]&0x00080000) { |