From 21c731c4ec9d42f0e96265b106fc70c387597bab Mon Sep 17 00:00:00 2001 From: lowercasedonkey <lowercasedonkey@gmail.com> Date: Sat, 14 Mar 2020 14:09:13 -0400 Subject: [PATCH] fixes puchased --- js/003-data/gameVariableData.js | 2 +- src/data/backwardsCompatibility/backwardsCompatibility.js | 4 ++++ src/js/heroCreator.js | 2 +- src/uncategorized/newSlaveIntro.tw | 2 +- 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/js/003-data/gameVariableData.js b/js/003-data/gameVariableData.js index ba41370a04e..df7bef2efcb 100644 --- a/js/003-data/gameVariableData.js +++ b/js/003-data/gameVariableData.js @@ -1403,7 +1403,7 @@ App.Data.resetOnNGPlus = { DefaultBirthDestination: "individually decided fates", abbreviateHormoneBalance: 2, legendaryFacility: 0, - heroSlavesPuchased: [], + heroSlavesPurchased : [], fcnn: [ ("...coming up at the top of the hour: Catgirl slaves, science fact or science fiction..."), ("...coming up at the top of the hour: Malnockestivi Smith, Free Cities' first MtFtMtFtH transgendered person..."), diff --git a/src/data/backwardsCompatibility/backwardsCompatibility.js b/src/data/backwardsCompatibility/backwardsCompatibility.js index fe51a50a8e7..b04dee29383 100644 --- a/src/data/backwardsCompatibility/backwardsCompatibility.js +++ b/src/data/backwardsCompatibility/backwardsCompatibility.js @@ -220,6 +220,10 @@ App.Update.globalVariables = function() { App.Update.CustomSlaveOrder(V.huskSlave); App.Update.CustomSlaveOrder(V.customSlave); + if (V.heroSlavesPuchased) { // fix typo + V.heroSlavesPurchased = Array.from(V.heroSlavesPuchased); + } + // Farmyard Subsection const animalsBought = ["canines", "hooved", "felines", "labradorRetrievers", "germanShepherds", "goldenRetrievers", "frenchBulldogs", "bulldogs", "beagles", "poodles", "rottweilers", "yorkshireTerriers", "siberianHuskies", "horses", "bulls", "pigs", "siameses", "persians", "maineCoons", "ragdolls", "bengals", "abbysinians", "birmans", "orientalShorthairs", "sphynxes", "russianBlues", "wolves", "foxes", "jackals", "dingos", "zebras", "cougars", "jaguars", "pumas", "lynx", "leopards", "lions", "tigers"]; animalsBought.forEach(function(species) { V.animalsBought[species] = V.animalsBought[species] || 0; }); diff --git a/src/js/heroCreator.js b/src/js/heroCreator.js index 15102be1303..50d669cecd5 100644 --- a/src/js/heroCreator.js +++ b/src/js/heroCreator.js @@ -33,7 +33,7 @@ App.Utils.buildHeroArray = function() { hero--; continue; } - if (V.heroSlavesPuchased.includes(array[hero].ID)) { + if (V.heroSlavesPurchased .includes(array[hero].ID)) { array.splice(hero, 1); hero--; continue; diff --git a/src/uncategorized/newSlaveIntro.tw b/src/uncategorized/newSlaveIntro.tw index 4a4c6cdee00..222c171c1df 100644 --- a/src/uncategorized/newSlaveIntro.tw +++ b/src/uncategorized/newSlaveIntro.tw @@ -89,7 +89,7 @@ <</if>> <<if $specialSlave == 1>> - <<run $heroSlavesPuchased.push($heroSlaveID)>> + <<run $heroSlavesPurchased .push($heroSlaveID)>> <<unset $heroSlaveID>> <<set $specialSlave = 0>> <</if>> -- GitLab