diff options
author | megamage <none@none> | 2009-03-28 17:33:46 -0600 |
---|---|---|
committer | megamage <none@none> | 2009-03-28 17:33:46 -0600 |
commit | 4bf4575f9a9542fc8f264f6adb0a19783204f3ef (patch) | |
tree | 64603dde8cb21c169357d2a88e047105facd081d | |
parent | 2ab52aa2a12edf8411a8231101957c59f2ec2bc1 (diff) |
Fix typo in spell block chance calc Author: pasdVn
--HG--
branch : trunk
-rw-r--r-- | src/game/Unit.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 056c2fa8952..91e2338e4fc 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -2682,8 +2682,8 @@ bool Unit::isSpellBlocked(Unit *pVictim, SpellEntry const *spellProto, WeaponAtt ((Creature*)pVictim)->GetCreatureInfo()->flags_extra & CREATURE_FLAG_EXTRA_NO_BLOCK ) return false; - float blockChance = GetUnitBlockChance(); - blockChance += (GetWeaponSkillValue(attackType) - pVictim->GetMaxSkillValueForLevel() )*0.04; + float blockChance = pVictim->GetUnitBlockChance(); + blockChance += (int32(GetWeaponSkillValue(attackType)) - int32(pVictim->GetMaxSkillValueForLevel()))*0.04f; if (roll_chance_f(blockChance)) return true; } |