aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSarjuuk <junkdump@gmx.net>2011-07-24 06:22:53 +0700
committertobmaps <spambot42@yandex.ru>2011-07-24 06:22:53 +0700
commit3e70742e816cdc0de0fda35f3be9692efd626fc8 (patch)
tree6f3bd7d13c5510d839324e4479165a2a2be8a976 /src
parentec9d738f3e06b797f4898c19df04e20772ada61f (diff)
Core/Units: Prevent dodge/parry/block while under the effects of fear or desorientation
Diffstat (limited to 'src')
-rwxr-xr-xsrc/server/game/Entities/Unit/Unit.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp
index b61d3b825f0..5207e85ad63 100755
--- a/src/server/game/Entities/Unit/Unit.cpp
+++ b/src/server/game/Entities/Unit/Unit.cpp
@@ -2652,7 +2652,7 @@ uint32 Unit::GetDefenseSkillValue(Unit const* target) const
float Unit::GetUnitDodgeChance() const
{
- if (IsNonMeleeSpellCasted(false) || HasUnitState(UNIT_STAT_STUNNED))
+ if (IsNonMeleeSpellCasted(false) || HasUnitState(UNIT_STAT_CONTROLLED))
return 0.0f;
if (GetTypeId() == TYPEID_PLAYER)
@@ -2672,7 +2672,7 @@ float Unit::GetUnitDodgeChance() const
float Unit::GetUnitParryChance() const
{
- if (IsNonMeleeSpellCasted(false) || HasUnitState(UNIT_STAT_STUNNED))
+ if (IsNonMeleeSpellCasted(false) || HasUnitState(UNIT_STAT_CONTROLLED))
return 0.0f;
float chance = 0.0f;
@@ -2703,7 +2703,7 @@ float Unit::GetUnitParryChance() const
float Unit::GetUnitBlockChance() const
{
- if (IsNonMeleeSpellCasted(false) || HasUnitState(UNIT_STAT_STUNNED))
+ if (IsNonMeleeSpellCasted(false) || HasUnitState(UNIT_STAT_CONTROLLED))
return 0.0f;
if (Player const* player = ToPlayer())