fixed bugs
This commit is contained in:
parent
48ccac6022
commit
ee42f25d16
2 changed files with 9 additions and 7 deletions
2
craft.js
2
craft.js
|
@ -348,7 +348,7 @@ class Craft{
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (const d in statMap.get("duration")) {
|
for (const d in statMap.get("duration")) {
|
||||||
if(statMap.get("duration")[d] < 10) { statMap.get("duration")[d] = 10;}
|
if(!allNone && statMap.get("duration")[d] < 10) { statMap.get("duration")[d] = 10;}
|
||||||
}
|
}
|
||||||
if(statMap.has("charges") && statMap.get("charges") < 1 ) { statMap.set("charges",1)}
|
if(statMap.has("charges") && statMap.get("charges") < 1 ) { statMap.set("charges",1)}
|
||||||
|
|
||||||
|
|
14
display.js
14
display.js
|
@ -726,12 +726,13 @@ function displayExpandedItem(item, parent_id){
|
||||||
effects = powderSpecial["armorSpecialEffects"];
|
effects = powderSpecial["armorSpecialEffects"];
|
||||||
specialTitle.textContent += powderSpecial["armorSpecialName"] + ": ";
|
specialTitle.textContent += powderSpecial["armorSpecialName"] + ": ";
|
||||||
}
|
}
|
||||||
for (let i = 0; i < effects.length; i++) {
|
console.log(effects);
|
||||||
if (effects[i][0] !== "Description") {
|
for (const [key,value] of effects.entries()) {
|
||||||
|
if (key !== "Description") {
|
||||||
let effect = document.createElement("p");
|
let effect = document.createElement("p");
|
||||||
effect.classList.add("itemp");
|
effect.classList.add("itemp");
|
||||||
effect.textContent += effects[i][0] + ": " + effects[i][1][power] + specialSuffixes.get(effects[i][0]);
|
effect.textContent = key + ": " + value[power] + specialSuffixes.get(key);
|
||||||
if(effects[i][0] === "Damage"){
|
if(key === "Damage"){
|
||||||
effect.textContent += elementIcons[skp_elements.indexOf(element)];
|
effect.textContent += elementIcons[skp_elements.indexOf(element)];
|
||||||
}
|
}
|
||||||
if (element === "w") {
|
if (element === "w") {
|
||||||
|
@ -742,11 +743,12 @@ function displayExpandedItem(item, parent_id){
|
||||||
specialTitle.textContent += "[ " + effects.get("Description") + " ]";
|
specialTitle.textContent += "[ " + effects.get("Description") + " ]";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
specialTitle.append(specialEffects);
|
//specialTitle.append(specialEffects);
|
||||||
powder_special.appendChild(specialTitle);
|
powder_special.appendChild(specialTitle);
|
||||||
|
powder_special.appendChild(specialEffects);
|
||||||
|
|
||||||
|
|
||||||
parent_div.append(powder_special);
|
parent_div.appendChild(powder_special);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue