diff options
author | QAston <none@none> | 2009-03-08 03:10:03 +0100 |
---|---|---|
committer | QAston <none@none> | 2009-03-08 03:10:03 +0100 |
commit | 86a4bc7f3f8f0d4f015050469b65ffe4d983864e (patch) | |
tree | 98bf4541c1bb4a6a80ce9bab2196bc2f2c476ac2 /src | |
parent | 63b4a12251345f6bd7c4e85d9acc63ad6ca64cb9 (diff) |
*Fix judgements of the Wise
*Fix Druids Survival Instincts and thunder clap - by Lightguard.
*Fix Death Coil - by Fisherman, aerione_alt, Lightguard
--HG--
branch : trunk
Diffstat (limited to 'src')
-rw-r--r-- | src/game/SpellAuras.cpp | 14 | ||||
-rw-r--r-- | src/game/SpellEffects.cpp | 26 | ||||
-rw-r--r-- | src/game/SpellMgr.cpp | 5 | ||||
-rw-r--r-- | src/game/Unit.cpp | 11 |
4 files changed, 51 insertions, 5 deletions
diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index 75d3b2d431c..1ce2c5142b4 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -1909,6 +1909,15 @@ void Aura::HandleAuraDummy(bool apply, bool Real) m_modifier.m_amount = caster->SpellHealingBonus(m_target, GetSpellProto(), m_modifier.m_amount, SPELL_DIRECT_DAMAGE); return; } + //Druid, Survival Instincts + if(GetSpellProto()->SpellFamilyName==SPELLFAMILY_DRUID && GetSpellProto()->SpellFamilyFlags[2]& 0x40 ) + { + if(!m_target) + return; + + int32 bp0 = int32(m_target->GetMaxHealth() * m_modifier.m_amount / 100); + m_target->CastCustomSpell(m_target, 50322, &bp0, NULL, NULL, true); + } } // AT REMOVE else @@ -5820,7 +5829,6 @@ void Aura::PeriodicTick() { // ignore non positive values (can be result apply spellmods to aura damage uint32 pdamage = m_modifier.m_amount > 0 ? m_modifier.m_amount : 0; - sLog.outDetail("PeriodicTick: %u (TypeId: %u) energize %u (TypeId: %u) for %u dmg inflicted by %u", GUID_LOPART(GetCasterGUID()), GuidHigh2TypeId(GUID_HIPART(GetCasterGUID())), m_target->GetGUIDLow(), m_target->GetTypeId(), pdamage, GetId()); @@ -5832,6 +5840,10 @@ void Aura::PeriodicTick() if(m_target->GetMaxPower(power) == 0) break; + // Replenishment (Judgements of the Wise) + if (m_spellProto->SpellIconID == 3184 && m_spellProto->SpellVisual[0] == 12495) + pdamage = 0.25f * m_target->GetMaxPower(POWER_MANA); + WorldPacket data(SMSG_PERIODICAURALOG, (21+16));// we guess size data.append(m_target->GetPackGUID()); data.appendPackGUID(GetCasterGUID()); diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index caf33897be9..494957e354c 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -425,6 +425,12 @@ void Spell::SpellDamageSchoolDmg(uint32 effect_idx) damage+= int32(m_caster->GetTotalAttackPowerValue(BASE_ATTACK) * pct / 100); break; } + // Thunder Clap + else if(m_spellInfo->SpellFamilyFlags[0] & 0x80) + { + damage += int32(m_caster->GetTotalAttackPowerValue(BASE_ATTACK) * 12 / 100); + break; + } break; } case SPELLFAMILY_WARLOCK: @@ -1858,7 +1864,27 @@ void Spell::EffectDummy(uint32 i) m_caster->CastSpell(m_caster,spell_id,true); return; } + // Death Coil + if(m_spellInfo->SpellFamilyFlags[0] & 0x002000) + { + uint32 spell_id = NULL; + damage += m_caster->GetTotalAttackPowerValue(BASE_ATTACK) * 0.15f; + if(m_caster->IsFriendlyTo(unitTarget)) + { + if(unitTarget->GetCreatureType() != CREATURE_TYPE_UNDEAD) + return; + spell_id = 47633; + damage *= 1.5f; + } + else + spell_id = 47632; + + bp = int32(damage); + m_caster->CastCustomSpell(unitTarget,spell_id,&bp,NULL,NULL,true); + return; + } + break; } //spells triggered by dummy effect should not miss diff --git a/src/game/SpellMgr.cpp b/src/game/SpellMgr.cpp index f381d54f999..8004890b747 100644 --- a/src/game/SpellMgr.cpp +++ b/src/game/SpellMgr.cpp @@ -370,7 +370,7 @@ SpellSpecific GetSpellSpecific(uint32 spellId) if (spellInfo->SpellFamilyFlags[0] & 0x11010002) return SPELL_BLESSING; - if ((spellInfo->SpellFamilyFlags[1] & 0x000008 || spellInfo->SpellFamilyFlags[0] & 20180400) && (spellInfo->AttributesEx3 & 0x200)) + if ((spellInfo->SpellFamilyFlags[1] & 0x000008 || spellInfo->SpellFamilyFlags[0] & 0x20180400) && (spellInfo->AttributesEx3 & 0x200)) return SPELL_JUDGEMENT; for (int i = 0; i < 3; i++) @@ -498,9 +498,6 @@ bool IsPositiveEffect(uint32 spellId, uint32 effIndex) case 23333: // BG spell case 23335: // BG spell case 34976: // BG spell - case 31579: // Arcane Empowerment Rank1 talent aura with one positive and one negative (check not needed in wotlk) - case 31582: // Arcane Empowerment Rank2 - case 31583: // Arcane Empowerment Rank3 return true; case 28441: // not positive dummy spell case 37675: // Chaos Blast diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 13c168ea126..bf508cf48fb 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -5843,6 +5843,17 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAu basepoints0 = GetAttackTime(BASE_ATTACK) * int32(ap*0.022f + 0.044f * holy) / 1000; break; } + // Judgements of the Wise + if (dummySpell->SpellIconID == 3017) + { + // hardcoded amount + basepoints0 = 15 * GetMaxPower(POWER_MANA)/100; + target = this; + triggered_spell_id = 57669; + // replenishment + CastCustomSpell(this,31930,&basepoints0,0,0,true,0,triggeredByAura); + break; + } // Sanctified Wrath if (dummySpell->SpellIconID == 3029) { |