From d77a8568b7df8e1e7131f81c0c67487384232047 Mon Sep 17 00:00:00 2001 From: Faq Date: Thu, 14 Jun 2012 22:36:56 +0300 Subject: Fixing Death Knight T8 Melee 4P Bonus (darkruned set). tibbi --- src/server/scripts/Spells/spell_dk.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/server/scripts/Spells') diff --git a/src/server/scripts/Spells/spell_dk.cpp b/src/server/scripts/Spells/spell_dk.cpp index 118097a38cb..defca2b8d33 100644 --- a/src/server/scripts/Spells/spell_dk.cpp +++ b/src/server/scripts/Spells/spell_dk.cpp @@ -400,7 +400,12 @@ class spell_dk_scourge_strike : public SpellScriptLoader { Unit* caster = GetCaster(); if (Unit* unitTarget = GetHitUnit()) + { multiplier = (GetEffectValue() * unitTarget->GetDiseasesByCaster(caster->GetGUID()) / 100.f); + // Death Knight T8 Melee 4P Bonus + if (AuraEffect const* aurEff = caster->GetAuraEffect(64736, EFFECT_0)) + AddPctF(multiplier, aurEff->GetAmount()); + } } void HandleAfterHit() -- cgit v1.2.3 From ac7485341554d09cf7740b9a2b5a9cf43674710b Mon Sep 17 00:00:00 2001 From: Faq Date: Fri, 15 Jun 2012 01:21:02 +0300 Subject: Adding enums --- src/server/scripts/Spells/spell_dk.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/server/scripts/Spells') diff --git a/src/server/scripts/Spells/spell_dk.cpp b/src/server/scripts/Spells/spell_dk.cpp index defca2b8d33..9051d9510f9 100644 --- a/src/server/scripts/Spells/spell_dk.cpp +++ b/src/server/scripts/Spells/spell_dk.cpp @@ -40,6 +40,8 @@ enum DeathKnightSpells DK_SPELL_IMPROVED_BLOOD_PRESENCE_TRIGGERED = 63611, DK_SPELL_UNHOLY_PRESENCE = 48265, DK_SPELL_IMPROVED_UNHOLY_PRESENCE_TRIGGERED = 63622, + DK_SPELL_IMPROVED_BLOOD_PRESENCE_TRIGGERED = 63611, + SPELL_DK_ITEM_T8_MALEE_4P_BONUS = 64736, }; // 50462 - Anti-Magic Shell (on raid member) @@ -403,7 +405,7 @@ class spell_dk_scourge_strike : public SpellScriptLoader { multiplier = (GetEffectValue() * unitTarget->GetDiseasesByCaster(caster->GetGUID()) / 100.f); // Death Knight T8 Melee 4P Bonus - if (AuraEffect const* aurEff = caster->GetAuraEffect(64736, EFFECT_0)) + if (AuraEffect const* aurEff = caster->GetAuraEffect(SPELL_DK_ITEM_T8_MALEE_4P_BONUS, EFFECT_0)) AddPctF(multiplier, aurEff->GetAmount()); } } @@ -608,7 +610,7 @@ public: if (!target->HasAura(DK_SPELL_BLOOD_PRESENCE) && !target->HasAura(DK_SPELL_IMPROVED_BLOOD_PRESENCE_TRIGGERED)) { int32 basePoints1 = aurEff->GetAmount(); - target->CastCustomSpell(target, 63611, NULL, &basePoints1, NULL, true, 0, aurEff); + target->CastCustomSpell(target, DK_SPELL_IMPROVED_BLOOD_PRESENCE_TRIGGERED, NULL, &basePoints1, NULL, true, 0, aurEff); } } -- cgit v1.2.3 From 67a0e54bb9afc4ddcd4c6c4e47c57cb5079b62af Mon Sep 17 00:00:00 2001 From: Faq Date: Fri, 15 Jun 2012 01:29:52 +0300 Subject: Correct the amount of dmg absorbed by Anti-magic shell.tibbi --- src/server/scripts/Spells/spell_dk.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/server/scripts/Spells') diff --git a/src/server/scripts/Spells/spell_dk.cpp b/src/server/scripts/Spells/spell_dk.cpp index 9051d9510f9..2a414c7c094 100644 --- a/src/server/scripts/Spells/spell_dk.cpp +++ b/src/server/scripts/Spells/spell_dk.cpp @@ -113,8 +113,7 @@ class spell_dk_anti_magic_shell_self : public SpellScriptLoader void CalculateAmount(AuraEffect const* /*aurEff*/, int32 & amount, bool & /*canBeRecalculated*/) { - // Set absorbtion amount to unlimited - amount = -1; + amount = GetCaster()->CountPctFromMaxHealth(hpPct); } void Absorb(AuraEffect* /*aurEff*/, DamageInfo & dmgInfo, uint32 & absorbAmount) -- cgit v1.2.3 From 6bd8a01aa5474b55dc8681e224d31b16a43a87bc Mon Sep 17 00:00:00 2001 From: Faq Date: Fri, 15 Jun 2012 17:21:34 +0300 Subject: ... --- src/server/scripts/Spells/spell_dk.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'src/server/scripts/Spells') diff --git a/src/server/scripts/Spells/spell_dk.cpp b/src/server/scripts/Spells/spell_dk.cpp index 2a414c7c094..38901287e0d 100644 --- a/src/server/scripts/Spells/spell_dk.cpp +++ b/src/server/scripts/Spells/spell_dk.cpp @@ -40,7 +40,6 @@ enum DeathKnightSpells DK_SPELL_IMPROVED_BLOOD_PRESENCE_TRIGGERED = 63611, DK_SPELL_UNHOLY_PRESENCE = 48265, DK_SPELL_IMPROVED_UNHOLY_PRESENCE_TRIGGERED = 63622, - DK_SPELL_IMPROVED_BLOOD_PRESENCE_TRIGGERED = 63611, SPELL_DK_ITEM_T8_MALEE_4P_BONUS = 64736, }; -- cgit v1.2.3