From 5928348aba12869fb319e18a8ca0d652411862bf Mon Sep 17 00:00:00 2001 From: lowercasedonkey <lowercasedonkey@gmail.com> Date: Mon, 2 Mar 2020 13:09:24 -0500 Subject: [PATCH] move corp --- .../backwardsCompatibility.js | 254 +++++++++--------- 1 file changed, 127 insertions(+), 127 deletions(-) diff --git a/src/data/backwardsCompatibility/backwardsCompatibility.js b/src/data/backwardsCompatibility/backwardsCompatibility.js index 4888515338f..0f7e5e9e9af 100644 --- a/src/data/backwardsCompatibility/backwardsCompatibility.js +++ b/src/data/backwardsCompatibility/backwardsCompatibility.js @@ -1880,133 +1880,6 @@ App.Update.globalVariables = function() { App.SF.BC(); } - // Corp - { - App.Corporate.Backcompat(); - /* Corporation variables added*/ - if (typeof V.vanillaShareSplit === "undefined") { - V.vanillaShareSplit = 1; - } - if (typeof V.corpCashDividend === "undefined") { - V.corpCashDividend = 0; - } - if (typeof V.corpDiv === "undefined") { - V.corpDiv = 0; - } - if (typeof V.corpExpandToken === "undefined") { - V.corpExpandToken = 0; - } - if (V.corpExpandToken > 1) { - V.corpExpandToken = 1; - } - if (typeof V.corpSpec === "undefined") { - V.corpSpec = 0; - } - if (typeof V.corpSpecToken === "undefined") { - V.corpSpecToken = 0; - } - if (typeof V.corpDivExtra === "undefined") { - V.corpDivExtra = 0; - } - if (typeof V.corpDivLegal === "undefined") { - V.corpDivLegal = 0; - } - if (typeof V.corpDivBreak === "undefined") { - V.corpDivBreak = 0; - } - if (typeof V.corpDivSurgery === "undefined") { - V.corpDivSurgery = 0; - } - if (typeof V.corpDivTrain === "undefined") { - V.corpDivTrain = 0; - } - if (typeof V.corpDivArcade === "undefined") { - V.corpDivArcade = 0; - } - if (typeof V.corpDivMenial === "undefined") { - V.corpDivMenial = 0; - } - if (typeof V.corpDivDairy === "undefined") { - V.corpDivDairy = 0; - } - if (typeof V.corpDivWhore === "undefined") { - V.corpDivWhore = 0; - } - if (typeof V.corpDivExtraDev === "undefined") { - V.corpDivExtraDev = 0; - } - if (typeof V.corpDivLegalDev === "undefined") { - V.corpDivLegalDev = 0; - } - if (typeof V.corpDivBreakDev === "undefined") { - V.corpDivBreakDev = 0; - } - if (typeof V.corpDivSurgeryDev === "undefined") { - V.corpDivSurgeryDev = 0; - } - if (typeof V.corpDivTrainDev === "undefined") { - V.corpDivTrainDev = 0; - } - if (typeof V.corpDivArcadeDev === "undefined") { - V.corpDivArcadeDev = 0; - } - if (typeof V.corpDivMenialDev === "undefined") { - V.corpDivMenialDev = 0; - } - if (typeof V.corpDivDairyDev === "undefined") { - V.corpDivDairyDev = 0; - } - if (typeof V.corpDivWhoreDev === "undefined") { - V.corpDivWhoreDev = 0; - } - if (typeof V.corpSpecRaces === "undefined") { - V.corpSpecRaces = []; - } - V.dividendTimer = V.dividendTimer || 13; - if (typeof V.corpEcon === "undefined") { - V.corpEcon = 0; - } - - /* Removing the old Corp from save*/ - if (typeof V.newCorp === "undefined") { - V.newCorp = 1; - V.corpIncorporated = 0; - cashX(Math.min(Math.trunc((V.corpValue / (V.publicShares + V.personalShares)) * V.personalShares), 1000000), "stocksTraded"); - /* Paying the player for his old corporation, so they can get the new one started with haste. It should perhaps have a message going with it*/ - V.mercenariesHelpCorp = 0; - V.corpMarket = 0; - if (typeof V.sectors !== "undefined") { - for (let _i = 0; _i < V.sectors.length; _i++) { - if (V.sectors[_i].type === "CorporateMarket") { - V.sectors[_i].type = "Markets"; - break; - } - } - } - } - // TODO: Corp, should captureUpgradeRace be removed? -LCD - if (V.captureUpgradeRace === "") { - V.generalUpgradeBreaking = "unselected"; - V.generalUpgradeWeight = "unselected"; - V.generalUpgradeMuscle = "unselected"; - V.entrapmentUpgradeDevotionOne = "unselected"; - V.entrapmentUpgradeDevotionTwo = "unselected"; - V.entrapmentUpgradeIntelligence = "unselected"; - V.captureUpgradeGender = "unselected"; - V.surgicalUpgradeGenitalia = "unselected"; - V.captureUpgradeAge = "unselected"; - V.captureUpgradeRace = "unselected"; - V.trainingUpgradeAccent = "unselected"; - V.trainingUpgradeEducation = "unselected"; - V.trainingUpgradeSexEd = "unselected"; - V.surgicalUpgradeCosmetics = "unselected"; - V.surgicalUpgradeImplants = "unselected"; - V.drugUpgradeHormones = "unselected"; - V.drugUpgradeInjectionOne = "unselected"; - V.drugUpgradeInjectionTwo = "unselected"; - } - } - // FS { if (typeof V.FSCreditCount === "undefined") { @@ -2820,6 +2693,133 @@ App.Update.globalVariables = function() { // Clean up neighbor's arcologies App.Update.neighborArcologyCheatDatatypeCleanup(); + // Corp + { + App.Corporate.Backcompat(); + /* Corporation variables added*/ + if (typeof V.vanillaShareSplit === "undefined") { + V.vanillaShareSplit = 1; + } + if (typeof V.corpCashDividend === "undefined") { + V.corpCashDividend = 0; + } + if (typeof V.corpDiv === "undefined") { + V.corpDiv = 0; + } + if (typeof V.corpExpandToken === "undefined") { + V.corpExpandToken = 0; + } + if (V.corpExpandToken > 1) { + V.corpExpandToken = 1; + } + if (typeof V.corpSpec === "undefined") { + V.corpSpec = 0; + } + if (typeof V.corpSpecToken === "undefined") { + V.corpSpecToken = 0; + } + if (typeof V.corpDivExtra === "undefined") { + V.corpDivExtra = 0; + } + if (typeof V.corpDivLegal === "undefined") { + V.corpDivLegal = 0; + } + if (typeof V.corpDivBreak === "undefined") { + V.corpDivBreak = 0; + } + if (typeof V.corpDivSurgery === "undefined") { + V.corpDivSurgery = 0; + } + if (typeof V.corpDivTrain === "undefined") { + V.corpDivTrain = 0; + } + if (typeof V.corpDivArcade === "undefined") { + V.corpDivArcade = 0; + } + if (typeof V.corpDivMenial === "undefined") { + V.corpDivMenial = 0; + } + if (typeof V.corpDivDairy === "undefined") { + V.corpDivDairy = 0; + } + if (typeof V.corpDivWhore === "undefined") { + V.corpDivWhore = 0; + } + if (typeof V.corpDivExtraDev === "undefined") { + V.corpDivExtraDev = 0; + } + if (typeof V.corpDivLegalDev === "undefined") { + V.corpDivLegalDev = 0; + } + if (typeof V.corpDivBreakDev === "undefined") { + V.corpDivBreakDev = 0; + } + if (typeof V.corpDivSurgeryDev === "undefined") { + V.corpDivSurgeryDev = 0; + } + if (typeof V.corpDivTrainDev === "undefined") { + V.corpDivTrainDev = 0; + } + if (typeof V.corpDivArcadeDev === "undefined") { + V.corpDivArcadeDev = 0; + } + if (typeof V.corpDivMenialDev === "undefined") { + V.corpDivMenialDev = 0; + } + if (typeof V.corpDivDairyDev === "undefined") { + V.corpDivDairyDev = 0; + } + if (typeof V.corpDivWhoreDev === "undefined") { + V.corpDivWhoreDev = 0; + } + if (typeof V.corpSpecRaces === "undefined") { + V.corpSpecRaces = []; + } + V.dividendTimer = V.dividendTimer || 13; + if (typeof V.corpEcon === "undefined") { + V.corpEcon = 0; + } + + /* Removing the old Corp from save*/ + if (typeof V.newCorp === "undefined") { + V.newCorp = 1; + V.corpIncorporated = 0; + cashX(Math.min(Math.trunc((V.corpValue / (V.publicShares + V.personalShares)) * V.personalShares), 1000000), "stocksTraded"); + /* Paying the player for his old corporation, so they can get the new one started with haste. It should perhaps have a message going with it*/ + V.mercenariesHelpCorp = 0; + V.corpMarket = 0; + if (typeof V.sectors !== "undefined") { + for (let _i = 0; _i < V.sectors.length; _i++) { + if (V.sectors[_i].type === "CorporateMarket") { + V.sectors[_i].type = "Markets"; + break; + } + } + } + } + // TODO: Corp, should captureUpgradeRace be removed? -LCD + if (V.captureUpgradeRace === "") { + V.generalUpgradeBreaking = "unselected"; + V.generalUpgradeWeight = "unselected"; + V.generalUpgradeMuscle = "unselected"; + V.entrapmentUpgradeDevotionOne = "unselected"; + V.entrapmentUpgradeDevotionTwo = "unselected"; + V.entrapmentUpgradeIntelligence = "unselected"; + V.captureUpgradeGender = "unselected"; + V.surgicalUpgradeGenitalia = "unselected"; + V.captureUpgradeAge = "unselected"; + V.captureUpgradeRace = "unselected"; + V.trainingUpgradeAccent = "unselected"; + V.trainingUpgradeEducation = "unselected"; + V.trainingUpgradeSexEd = "unselected"; + V.surgicalUpgradeCosmetics = "unselected"; + V.surgicalUpgradeImplants = "unselected"; + V.drugUpgradeHormones = "unselected"; + V.drugUpgradeInjectionOne = "unselected"; + V.drugUpgradeInjectionTwo = "unselected"; + } + } + // Organs { let _newOrgans = []; -- GitLab