mask shards and vessel fragments %
This commit is contained in:
parent
1aa3b55b12
commit
93bf936d8b
2 changed files with 12 additions and 2 deletions
|
|
@ -544,11 +544,21 @@ function CompletionHTML(jsObj) {
|
|||
h2 = jsObj[i].h2;
|
||||
h2id = "h2-" + jsObj[i].id;
|
||||
|
||||
(jsObj[i].hasOwnProperty("percent")) ? cp = jsObj[i].percent + "/": cp = "";
|
||||
(jsObj[i].hasOwnProperty("percent")) ? cp = jsObj[i].percent: cp = "";
|
||||
|
||||
if (!jsObj[i].hasOwnProperty("maxPercent") || i === "intro") {
|
||||
mp = "";
|
||||
} else {
|
||||
|
||||
if (i === "maskShards") {
|
||||
let perc = jsObj[i].percent;
|
||||
(perc % 4) ? cp = Math.floor(perc / 4): cp = perc / 4;
|
||||
} else if (i === "vesselFragments") {
|
||||
let perc = jsObj[i].percent;
|
||||
(perc % 3) ? cp = Math.floor(perc / 3): cp = perc / 3;
|
||||
}
|
||||
|
||||
if (jsObj[i].hasOwnProperty("percent")) cp += "/";
|
||||
mp = " (" + cp + jsObj[i].maxPercent + "%)";
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@ function loadJSON(filename, callback) {
|
|||
xobj.send(null);
|
||||
}
|
||||
|
||||
loadJSON("save/" + fileName[4],
|
||||
loadJSON("save/" + fileName[5],
|
||||
function JSONparse(response) {
|
||||
// Parse JSON string into object
|
||||
jsonObj = JSON.parse(response);
|
||||
|
|
|
|||
Loading…
Reference in a new issue