From ce17866ef08b10957e9a246a4a8d0839995033af Mon Sep 17 00:00:00 2001 From: Spp Date: Tue, 4 May 2010 21:54:13 +0200 Subject: [PATCH] Unstable Affliction: Fix caster, bonus and penalty damage Original Patch by N4rk0 Closes issue 739 --HG-- branch : trunk --- src/game/Unit.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 54d0b47dbe..865c95d4d1 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -2491,7 +2491,7 @@ uint32 Unit::CalculateDamage(WeaponAttackType attType, bool normalized, bool add float Unit::CalculateLevelPenalty(SpellEntry const* spellProto) const { - if (spellProto->spellLevel <= 0) + if (spellProto->spellLevel <= 0 || spellProto->spellLevel >= spellProto->maxLevel) return 1.0f; float LvlPenalty = 0.0f; @@ -4033,7 +4033,7 @@ void Unit::RemoveAurasDueToSpellByDispel(uint32 spellId, uint64 casterGUID, Unit { int32 damage = aurEff->GetAmount()*9; // backfire damage and silence - dispeller->CastCustomSpell(dispeller, 31117, &damage, NULL, NULL, true, NULL, NULL, GetGUID()); + dispeller->CastCustomSpell(dispeller, 31117, &damage, NULL, NULL, true, NULL, NULL, aura->GetCasterGUID()); } } // Flame Shock