Fix poison to use actual statmap instead of build statmap (#204)
Co-authored-by: hppeng <hppeng>
This commit is contained in:
parent
66a8ff2166
commit
874b8b1746
2 changed files with 4 additions and 4 deletions
|
@ -717,7 +717,7 @@ class BuildDisplayNode extends ComputeNode {
|
|||
// TODO: move weapon out?
|
||||
// displayDefenseStats(document.getElementById("defensive-stats"), stats);
|
||||
|
||||
displayPoisonDamage(document.getElementById("build-poison-stats"), build);
|
||||
displayPoisonDamage(document.getElementById("build-poison-stats"), stats);
|
||||
displayEquipOrder(document.getElementById("build-order"), build.equip_order);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -997,9 +997,9 @@ function displayFixedID(active, id, value, elemental_format, style) {
|
|||
}
|
||||
}
|
||||
|
||||
function displayPoisonDamage(overallparent_elem, build) {
|
||||
function displayPoisonDamage(overallparent_elem, statMap) {
|
||||
overallparent_elem.textContent = "";
|
||||
if (build.statMap.get('poison') <= 0) {
|
||||
if (statMap.get('poison') <= 0) {
|
||||
overallparent_elem.style = "display: none";
|
||||
return;
|
||||
}
|
||||
|
@ -1013,7 +1013,7 @@ function displayPoisonDamage(overallparent_elem, build) {
|
|||
title_elemavg.append(make_elem('span', [], { textContent: "Poison Stats" }));
|
||||
spell_summary.append(title_elemavg);
|
||||
|
||||
let poison_tick = Math.ceil(build.statMap.get("poison") * (1+skillPointsToPercentage(build.total_skillpoints[0])) * (build.statMap.get("poisonPct"))/100 /3);
|
||||
let poison_tick = Math.ceil(statMap.get("poison") * (1+skillPointsToPercentage(statMap.get('str'))) * (statMap.get("poisonPct"))/100 /3);
|
||||
|
||||
let overallpoisonDamage = make_elem("p");
|
||||
overallpoisonDamage.append(
|
||||
|
|
Loading…
Reference in a new issue