Skip to content

Commit

Permalink
damage calc. v0.11.0, season 3 overpower fix
Browse files Browse the repository at this point in the history
  • Loading branch information
fquirin committed Jan 20, 2024
1 parent b70c447 commit ee318db
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions damage.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@

<script>
var d4cType = "dmgcalc"; //TODO: this is added to the storage key and can in theory be in conflict with calc name
var d4cVersion = "0.10.0";
var d4season = "2";
var d4cVersion = "0.11.0";
var d4season = "3";
</script>
</head>
<body>
Expand Down
6 changes: 4 additions & 2 deletions damage.js
Original file line number Diff line number Diff line change
Expand Up @@ -224,8 +224,10 @@ function buildCalculator(containerEle, options){
//Overpower attacks gain +2% damage per 1% of your Base Life that you have in bonus life above your Base Life.
//Overpower attacks gain +2% damage per 1% of your Base Life you have in Fortify.
//discussion: https://us.forums.blizzard.com/en/d4/t/new-formula-for-overpower-damage-in-120/128302/40
overpowerAddDmgPercentLife = (maxLifeEle.value - baseLifeEle.value)/baseLifeEle.value * 100 * 2;
overpowerAddDmgPercentFortify = isFortified.checked? ((maxLifeEle.value/baseLifeEle.value) * 100 * 2) : 0.0;
//Changes for season 3: damage per 1% reduced from 2% to 1% for both bonus and fortified life
let dmgPer1pct = 1.0;
overpowerAddDmgPercentLife = (maxLifeEle.value - baseLifeEle.value)/baseLifeEle.value * 100 * dmgPer1pct;
overpowerAddDmgPercentFortify = isFortified.checked? ((maxLifeEle.value/baseLifeEle.value) * 100 * dmgPer1pct) : 0.0;
let bonusLifeFactor = overpowerAddDmgPercentLife/100;
let fortifyFactor = overpowerAddDmgPercentFortify/100;
overpowerAddBaseDamage = addModBaseDamage * thisFactorAdd;
Expand Down

0 comments on commit ee318db

Please sign in to comment.