diff options
author | Rat <none@none> | 2009-04-11 19:31:20 +0200 |
---|---|---|
committer | Rat <none@none> | 2009-04-11 19:31:20 +0200 |
commit | 80e1a5faaccc30e121cb4f97c0be7f640ff59577 (patch) | |
tree | e8dc68559196fd58bc4fc3dc4dffdf7f450d91ab /src | |
parent | 901bf73d758257a83c6eee03f37cfb89cb734d07 (diff) |
*fix melee hit crit and add it to debuglog if disabled
--HG--
branch : trunk
Diffstat (limited to 'src')
-rw-r--r-- | src/game/Unit.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index e5c6200e7a5..037945b896b 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -2557,7 +2557,9 @@ MeleeHitOutcome Unit::RollMeleeOutcomeAgainst (const Unit *pVictim, WeaponAttack if (tmp > 0 && roll < (sum += tmp)) { DEBUG_LOG ("RollMeleeOutcomeAgainst: CRIT <%d, %d)", sum-tmp, sum); - if(GetTypeId()!=TYPEID_PLAYER && !(((Creature*)this)->GetCreatureInfo()->flags_extra & CREATURE_FLAG_EXTRA_NO_CRIT)) + if(GetTypeId() == TYPEID_UNIT && (((Creature*)this)->GetCreatureInfo()->flags_extra & CREATURE_FLAG_EXTRA_NO_CRIT)) + DEBUG_LOG ("RollMeleeOutcomeAgainst: CRIT DISABLED)"); + else return MELEE_HIT_CRIT; } |