From 22b082519ee4c2edd33dc1dfdf58366a0a250cca Mon Sep 17 00:00:00 2001 From: megamage Date: Thu, 14 May 2009 11:44:27 -0500 Subject: Backed out changeset: 7dcbf5239f55 --HG-- branch : trunk --- src/game/Unit.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index f142ea623a5..95547b68621 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -2767,9 +2767,7 @@ SpellMissInfo Unit::MeleeSpellHitResult(Unit *pVictim, SpellEntry const *spell) { WeaponAttackType attType = BASE_ATTACK; - // Check damage class instead of attack type to correctly handle judgements - // - they are meele, but can't be dodged/parried/deflected because of ranged dmg class - if (spell->DmgClass == SPELL_DAMAGE_CLASS_RANGED) + if (spell->DmgClass == SPELL_DAMAGE_CLASS_RANGED && IsRangedWeaponSpell(spell)) attType = RANGED_ATTACK; // bonus from skills is 0.04% per skill Diff @@ -2811,7 +2809,9 @@ SpellMissInfo Unit::MeleeSpellHitResult(Unit *pVictim, SpellEntry const *spell) return SPELL_MISS_NONE; // Ranged attack cannot be parry/dodge only deflect - if (attType == RANGED_ATTACK) + // Check damage class instead of attack type to correctly handle judgements + // - they are meele, but can't be dodged/parried/deflected because of ranged dmg class + if (spell->DmgClass == SPELL_DAMAGE_CLASS_RANGED) { // only if in front if (pVictim->HasInArc(M_PI,this)) -- cgit v1.2.3