From ad34d808647ba650a05323e79e03d5f729b182f9 Mon Sep 17 00:00:00 2001 From: Julian Date: Fri, 30 Jul 2021 20:08:55 +0200 Subject: [PATCH] Changing the Glancing Blow chance to 25% (#18) --- src/game/Object/Unit.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/game/Object/Unit.cpp b/src/game/Object/Unit.cpp index 7acc1f5f4d..2c277a8fcb 100644 --- a/src/game/Object/Unit.cpp +++ b/src/game/Object/Unit.cpp @@ -3600,7 +3600,7 @@ MeleeHitOutcome Unit::RollMeleeOutcomeAgainst(const Unit* pVictim, WeaponAttackT } } - // Max 40% chance to score a glancing blow against mobs that are higher level (can do only players and pets and not with ranged weapon) + // Max 25% chance to score a glancing blow against mobs that are higher level (can do only players and pets and not with ranged weapon) if (attType != RANGED_ATTACK && (GetTypeId() == TYPEID_PLAYER || ((Creature*)this)->IsPet()) && pVictim->GetTypeId() != TYPEID_PLAYER && !((Creature*)pVictim)->IsPet() && @@ -3610,10 +3610,10 @@ MeleeHitOutcome Unit::RollMeleeOutcomeAgainst(const Unit* pVictim, WeaponAttackT int32 skill = attackerMaxSkillValueForLevel; tmp = (10 + (victimMaxSkillValueForLevel - skill)) * 100; - tmp = tmp > 4000 ? 4000 : tmp; + tmp = tmp > 2500 ? 2500 : tmp; if (roll < (sum += tmp)) { - DEBUG_FILTER_LOG(LOG_FILTER_COMBAT, "RollMeleeOutcomeAgainst: GLANCING <%d, %d)", sum - 4000, sum); + DEBUG_FILTER_LOG(LOG_FILTER_COMBAT, "RollMeleeOutcomeAgainst: GLANCING <%d, %d)", sum - 2500, sum); return MELEE_HIT_GLANCING; } }