skip counting collectibles in True Completion

This commit is contained in:
ReznoRMichael 2022-01-20 14:35:07 +01:00
parent a63d0bae9c
commit a6abdd126f
3 changed files with 35 additions and 20 deletions

View file

@ -351,9 +351,8 @@ function CheckExtendedCompletion(db) {
// console.info("Section loop:", section); // console.info("Section loop:", section);
for (var entry in entries) { for (var entry in entries) {
// console.info("Entry loop:", entry); // console.info("Entry loop:", entry);
/* Do not count (ignore) these entries at all */
switch (entry) { switch (entry) {
/* Do not count (ignore) these entries at all */
case "oldNail": case "oldNail":
case "pantheonMaster": // Pantheons are counted in Godmaster section case "pantheonMaster": // Pantheons are counted in Godmaster section
@ -365,7 +364,6 @@ function CheckExtendedCompletion(db) {
case "dreamOrbs": case "dreamOrbs":
case "charmsOwned": case "charmsOwned":
case "nailDamage": case "nailDamage":
case "rancidEggs":
case "jinnEggsSold": case "jinnEggsSold":
case "xunFlowerBrokeTimes": case "xunFlowerBrokeTimes":
case "itemsDiscovered": case "itemsDiscovered":
@ -385,6 +383,16 @@ function CheckExtendedCompletion(db) {
case "greyPrinceDefeated": case "greyPrinceDefeated":
case "killedHollowKnight": case "killedHollowKnight":
case "killedFinalBoss": case "killedFinalBoss":
case "grubsCollected":
/* Collectibles are counted in their own sections */
case "whisperingRoots":
case "relicsWandererJournal":
case "relicsHallownestSeal":
case "relicsKingsIdol":
case "relicsArcaneEgg":
case "rancidEggs":
case "geoRocks":
// console.info("Ignored:", entry); // console.info("Ignored:", entry);
continue; continue;
} }
@ -475,21 +483,21 @@ function CheckExtendedCompletion(db) {
max = 0; max = 0;
} }
/* Counting Geo Rocks */ /* Counting Geo Rocks */
else if (entries[entry].hasOwnProperty("activated") && entries[entry].hasOwnProperty("max")) {
/* else if (entries[entry].hasOwnProperty("activated") && entries[entry].hasOwnProperty("max")) {
amount = entries[entry].activated; amount = entries[entry].activated;
max = entries[entry].max; max = entries[entry].max;
/* Check in case the player has discovered more than 205 (max) Geo Rocks */ // Check in case the player has discovered more than 205 (max) Geo Rocks
if (max < entries[entry].discoveredTotal) { if (max < entries[entry].discoveredTotal) {
max = entries[entry].discoveredTotal; max = entries[entry].discoveredTotal;
} }
intro.extendedCompletionDone += amount; intro.extendedCompletionDone += amount;
intro.extendedCompletionTotal += max; // console.info(`${entry}: ${amount}/${max}`, entries[entry].name); intro.extendedCompletionTotal += max;
console.info(`${entry}: ${amount}/${max}`, entries[entry].name);
amount = 0; amount = 0;
max = 0; max = 0;
} } */
} }
} }

File diff suppressed because one or more lines are too long

View file

@ -466,9 +466,9 @@ function CheckExtendedCompletion(db) {
// console.info("Entry loop:", entry); // console.info("Entry loop:", entry);
/* Do not count (ignore) these entries at all */
switch (entry) { switch (entry) {
/* Do not count (ignore) these entries at all */
case "oldNail": case "oldNail":
case "pantheonMaster": // Pantheons are counted in Godmaster section case "pantheonMaster": // Pantheons are counted in Godmaster section
case "pantheonArtist": case "pantheonArtist":
@ -479,7 +479,6 @@ function CheckExtendedCompletion(db) {
case "dreamOrbs": case "dreamOrbs":
case "charmsOwned": case "charmsOwned":
case "nailDamage": case "nailDamage":
case "rancidEggs":
case "jinnEggsSold": case "jinnEggsSold":
case "xunFlowerBrokeTimes": case "xunFlowerBrokeTimes":
case "itemsDiscovered": case "itemsDiscovered":
@ -499,6 +498,14 @@ function CheckExtendedCompletion(db) {
case "greyPrinceDefeated": case "greyPrinceDefeated":
case "killedHollowKnight": case "killedHollowKnight":
case "killedFinalBoss": case "killedFinalBoss":
case "grubsCollected": /* Collectibles are counted in their own sections */
case "whisperingRoots":
case "relicsWandererJournal":
case "relicsHallownestSeal":
case "relicsKingsIdol":
case "relicsArcaneEgg":
case "rancidEggs":
case "geoRocks":
// console.info("Ignored:", entry); // console.info("Ignored:", entry);
@ -605,12 +612,12 @@ function CheckExtendedCompletion(db) {
max = 0; max = 0;
} }
/* Counting Geo Rocks */ /* Counting Geo Rocks */
else if (entries[entry].hasOwnProperty("activated") && entries[entry].hasOwnProperty("max")) { /* else if (entries[entry].hasOwnProperty("activated") && entries[entry].hasOwnProperty("max")) {
amount = entries[entry].activated; amount = entries[entry].activated;
max = entries[entry].max; max = entries[entry].max;
/* Check in case the player has discovered more than 205 (max) Geo Rocks */ // Check in case the player has discovered more than 205 (max) Geo Rocks
if (max < entries[entry].discoveredTotal) { if (max < entries[entry].discoveredTotal) {
max = entries[entry].discoveredTotal; max = entries[entry].discoveredTotal;
} }
@ -618,11 +625,11 @@ function CheckExtendedCompletion(db) {
intro.extendedCompletionDone += amount; intro.extendedCompletionDone += amount;
intro.extendedCompletionTotal += max; intro.extendedCompletionTotal += max;
// console.info(`${entry}: ${amount}/${max}`, entries[entry].name); console.info(`${entry}: ${amount}/${max}`, entries[entry].name);
amount = 0; amount = 0;
max = 0; max = 0;
} } */
} }
} }