From e6185248d60793eff38dea48703090131b3de7d1 Mon Sep 17 00:00:00 2001 From: b Date: Wed, 17 Mar 2021 08:38:45 -0700 Subject: [PATCH] Fixed damage calculation bug causing overcounting of neutral damage in unpowdered weapons --- damage_calc.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/damage_calc.js b/damage_calc.js index d3b443c..c2962ad 100644 --- a/damage_calc.js +++ b/damage_calc.js @@ -81,11 +81,12 @@ function calculateSpellDamage(stats, spellConversions, rawModifier, pctModifier, neutralRemainingRaw[0] = Math.floor(round_near(neutralRemainingRaw[0] - min_diff)); neutralRemainingRaw[1] = Math.floor(round_near(neutralRemainingRaw[1] - max_diff)); } - damages[0] = neutralRemainingRaw; damages[element+1][0] += powder.min; damages[element+1][1] += powder.max; } + damages[0] = neutralRemainingRaw; + let damageMult = damageMultiplier; let melee = false; // If we are doing melee calculations: