diff --git a/build.js b/build.js index aa0352f..99dd810 100644 --- a/build.js +++ b/build.js @@ -204,16 +204,18 @@ class Build{ if (totalHp < 5) totalHp = 5; defenseStats.push(totalHp); //EHP - let ehp = totalHp; + let ehp = [totalHp, totalHp]; let defMult = classDefenseMultipliers.get(this.weapon.get("type")); - ehp /= ((1-def_pct)*(1-agi_pct)*(2-defMult)); + ehp[0] /= ((1-def_pct)*(1-agi_pct)*(2-defMult)); + ehp[1] /= ((1-def_pct)*(2-defMult)); defenseStats.push(ehp); //HPR let totalHpr = rawToPct(stats.get("hprRaw"), stats.get("hprPct")/100.); defenseStats.push(totalHpr); //EHPR - let ehpr = totalHpr; - ehpr /= ((1-def_pct)*(1-agi_pct)*(2-defMult)); + let ehpr = [totalHpr, totalHpr]; + ehpr[0] /= ((1-def_pct)*(1-agi_pct)*(2-defMult)); + ehpr[1] /= ((1-def_pct)*(2-defMult)); defenseStats.push(ehpr); //skp stats defenseStats.push([def_pct*100, agi_pct*100]); @@ -224,7 +226,7 @@ class Build{ } defenseStats.push(eledefs); - //[total hp, ehp, total hpr, ehpr, [def%, agi%], [edef,tdef,wdef,fdef,adef]] + //[total hp, [ehp w/ agi, ehp w/o agi], total hpr, [ehpr w/ agi, ehpr w/o agi], [def%, agi%], [edef,tdef,wdef,fdef,adef]] return defenseStats; } diff --git a/display.js b/display.js index cf52951..16db9e2 100644 --- a/display.js +++ b/display.js @@ -669,12 +669,26 @@ function displayDefenseStats(parent_elem,defenseStats){ ehp.textContent = "Effective HP:"; boost = document.createElement("td"); - boost.textContent = stats[1]; + boost.textContent = stats[1][0]; boost.classList.add("right"); ehpRow.appendChild(ehp); ehpRow.append(boost); statsTable.append(ehpRow); + + ehpRow = document.createElement("tr"); + ehp = document.createElement("td"); + ehp.classList.add("left"); + ehp.textContent = "Effective HP (no agi):"; + + boost = document.createElement("td"); + boost.textContent = stats[1][1]; + boost.classList.add("right"); + + ehpRow.appendChild(ehp); + ehpRow.append(boost); + statsTable.append(ehpRow); + //total HPR let hprRow = document.createElement("tr"); let hpr = document.createElement("td"); @@ -695,7 +709,20 @@ function displayDefenseStats(parent_elem,defenseStats){ ehpr.textContent = "Effective HP Regen:"; boost = document.createElement("td"); - boost.textContent = stats[3]; + boost.textContent = stats[3][0]; + boost.classList.add("right"); + + ehprRow.appendChild(ehpr); + ehprRow.append(boost); + statsTable.append(ehprRow); + + ehprRow = document.createElement("tr"); + ehpr = document.createElement("td"); + ehpr.classList.add("left"); + ehpr.textContent = "Effective HP Regen (no agi):"; + + boost = document.createElement("td"); + boost.textContent = stats[3][1]; boost.classList.add("right"); ehprRow.appendChild(ehpr); @@ -713,7 +740,7 @@ function displayDefenseStats(parent_elem,defenseStats){ eledefTitle.classList.add(damageClasses[i+1]); let defense = document.createElement("b"); - defense.textContent = " Defense: "; + defense.textContent = " Def: "; eledef.appendChild(eledefTitle); eledef.appendChild(defense); diff --git a/styles.css b/styles.css index 0baf040..5179715 100644 --- a/styles.css +++ b/styles.css @@ -9,7 +9,7 @@ } th, td { - padding-right: 20px; + padding-right: 10px; } .nomargin {