From ecc12d11aade0a7eeab558f7b2c0501935eaa697 Mon Sep 17 00:00:00 2001 From: lowercasedonkey <lowercasedonkey@gmail.com> Date: Mon, 16 Mar 2020 22:55:58 -0400 Subject: [PATCH] specNationality --- js/003-data/gameVariableData.js | 3 ++- src/Corporation/corporate.js | 1 + src/Corporation/corporateMarket.tw | 8 ++++++-- src/Corporation/manageCorporation.tw | 9 +++++++++ src/init/storyInit.tw | 2 +- src/js/generateMarketSlave.js | 3 +++ 6 files changed, 22 insertions(+), 4 deletions(-) diff --git a/js/003-data/gameVariableData.js b/js/003-data/gameVariableData.js index d63b39821ce..9e775184cc7 100644 --- a/js/003-data/gameVariableData.js +++ b/js/003-data/gameVariableData.js @@ -209,7 +209,8 @@ App.Data.CorpInitData = { ExpandToken: 0, Spec: 0, SpecToken: 0, - SpecRaces: [] + SpecRaces: [], + SpecNationality: 0 }; // The other half of the above whitelist. However, entries in this array will be forced to the values set here upon starting NG+. diff --git a/src/Corporation/corporate.js b/src/Corporation/corporate.js index 9f1696350da..decdce36585 100644 --- a/src/Corporation/corporate.js +++ b/src/Corporation/corporate.js @@ -609,6 +609,7 @@ App.Corporate.Init = function() { "Dividend", "SpecAccent", "SpecAge", + "SpecNationality", "SpecAmputee", "SpecBalls", "SpecDevotion", diff --git a/src/Corporation/corporateMarket.tw b/src/Corporation/corporateMarket.tw index 67bd1920e83..15f32aaa8a1 100644 --- a/src/Corporation/corporateMarket.tw +++ b/src/Corporation/corporateMarket.tw @@ -41,8 +41,12 @@ sales<<if $corp.SpecAge == 3>>_womanU<<else>>_girlU<</if>> in a slutty suit gree _HeU has cute little breasts and a petite rump. <</if>> <<if $corp.SpecCosmetics == 1>>_HisU face is flawless.<</if>> -<<if ($corp.SpecRaces.length == 1)>> - <<set _corpSpecRace = $corp.SpecRaces.random()>> +<<if ($corp.SpecRaces.length == 1) || $corp.SpecNationality>> + <<if $corp.SpecNationality>> + <<set _corpSpecRace = $corp.SpecNationality>> + <<elseif ($corp.SpecRaces.length == 1)>> + <<set _corpSpecRace = $corp.SpecRaces.random()>> + <</if>> _HeU's <<print _corpSpecRace>>, of course<<if $corp.SpecAccent == 1>>, and has a cute accent<</if>>. <</if>> <<if $corp.SpecHormones == 1>> diff --git a/src/Corporation/manageCorporation.tw b/src/Corporation/manageCorporation.tw index 91434dcc0a8..ff91e963cf9 100644 --- a/src/Corporation/manageCorporation.tw +++ b/src/Corporation/manageCorporation.tw @@ -411,6 +411,15 @@ You own <<print num($personalShares)>> shares while another <<print num($publicS <br>Only slaves of a particular race requires 3 tokens. <</if>> <</if>> + <<if (ndef $corp.SpecNationality && $corp.DivExtra > 0) && ($arcologies[0].FSEdoRevivalist != "unset" || $arcologies[0].FSChineseRevivalist != "unset")>> + <br> + <<if $arcologies[0].FSEdoRevivalist != "unset">> + Since you are pursuing Edo Revivalism, slaves who are [[Japanese|Manage Corporation][$corp.SpecNationality = "Japanese", $corp.SpecToken -= 1, $corp.SpecTimer = 2]] + <</if>> + <<if $arcologies[0].FSChineseRevivalist != "unset">> + Since you are pursuing Chinese Revivalism, slaves who are [[Chinese|Manage Corporation][$corp.SpecNationality = "Chinese", $corp.SpecToken -= 1, $corp.SpecTimer = 2]] + <</if>> + <</if>> <<if $seeDicks != 0 && ndef $corp.SpecGender && ($corp.DivExtra > 0 || $corp.DivLegal > 0)>> /*This used to be $captureUpgradeGender, it is a general acquisition specialization*/ <br>Train only slaves with [[Pussies|Manage Corporation][$corp.SpecGender = 1, $corp.SpecToken -= 1, $corp.SpecTimer = 2]] | [[Dicks|Manage Corporation][$corp.SpecGender = 2, $corp.SpecToken -= 1, $corp.SpecTimer = 2]] <</if>> diff --git a/src/init/storyInit.tw b/src/init/storyInit.tw index 7857148221d..b24a18772b8 100644 --- a/src/init/storyInit.tw +++ b/src/init/storyInit.tw @@ -98,7 +98,7 @@ You should have received a copy of the GNU General Public License along with thi <</if>> /*Undefining corporation variables*/ - <<unset $corp.AssetsDev, $corp.AssetsDevOld, $corp.AssetsSlave, $corp.AssetsSlaveOld, $corp.Cash, $corp.Div, $corp.DivArcadeFromMarket, $corp.DivArcadeSlaves, $corp.DivBreakFromMarket, $corp.DivBreakSlaves, $corp.DivBreakSlaves2, $corp.DivBreakToMarket, $corp.DivBreakToMenial, $corp.DivBreakToSurgery, $corp.DivBreakToTrain, $corp.DivDairyFromMarket, $corp.DivDairySlaves, $corp.DivExtraSlaves, $corp.DivExtraToArcade, $corp.DivExtraToBreak, $corp.DivExtraToMarket, $corp.Dividend, $corp.DivLegalSlaves, $corp.DivLegalToMarket, $corp.DivLegalToMenial, $corp.DivLegalToSurgery, $corp.DivLegalToTrain, $corp.DivMenialFromMarket, $corp.DivMenialSlaves, $corp.DivSurgeryFromMarket, $corp.DivSurgerySlaves, $corp.DivSurgerySlaves2, $corp.DivSurgeryToDairy, $corp.DivSurgeryToMarket, $corp.DivSurgeryToTrain, $corp.DivTrainFromMarket, $corp.DivTrainSlaves, $corp.DivTrainSlaves2, $corp.DivTrainToMarket, $corp.DivTrainToWhore, $corp.DivWhoreFromMarket, $corp.DivWhoreSlaves, $corp.OpCostOld, $corp.OverheadOld, $corp.ProfitOld, $corp.Rev, $corp.RevOld, $corp.SpecAccent, $corp.SpecAge, $corp.SpecAmputee, $corp.SpecBalls, $corp.SpecDevotion, $corp.SpecDick, $corp.SpecEducation, $corp.SpecGender, $corp.SpecGenitalia, $corp.SpecHeight, $corp.SpecHormones, $corp.SpecImplants, $corp.SpecInjection, $corp.SpecIntelligence, $corp.SpecMilk, $corp.SpecMuscle, $corp.SpecPussy, $corp.SpecSexEd, $corp.SpecTrust, $corp.SpecVirgin, $corp.SpecWeight, $dividendTimer, $personalShares, $publicShares>> + <<unset $corp.AssetsDev, $corp.AssetsDevOld, $corp.AssetsSlave, $corp.AssetsSlaveOld, $corp.Cash, $corp.Div, $corp.DivArcadeFromMarket, $corp.DivArcadeSlaves, $corp.DivBreakFromMarket, $corp.DivBreakSlaves, $corp.DivBreakSlaves2, $corp.DivBreakToMarket, $corp.DivBreakToMenial, $corp.DivBreakToSurgery, $corp.DivBreakToTrain, $corp.DivDairyFromMarket, $corp.DivDairySlaves, $corp.DivExtraSlaves, $corp.DivExtraToArcade, $corp.DivExtraToBreak, $corp.DivExtraToMarket, $corp.Dividend, $corp.DivLegalSlaves, $corp.DivLegalToMarket, $corp.DivLegalToMenial, $corp.DivLegalToSurgery, $corp.DivLegalToTrain, $corp.DivMenialFromMarket, $corp.DivMenialSlaves, $corp.DivSurgeryFromMarket, $corp.DivSurgerySlaves, $corp.DivSurgerySlaves2, $corp.DivSurgeryToDairy, $corp.DivSurgeryToMarket, $corp.DivSurgeryToTrain, $corp.DivTrainFromMarket, $corp.DivTrainSlaves, $corp.DivTrainSlaves2, $corp.DivTrainToMarket, $corp.DivTrainToWhore, $corp.DivWhoreFromMarket, $corp.DivWhoreSlaves, $corp.OpCostOld, $corp.OverheadOld, $corp.ProfitOld, $corp.Rev, $corp.RevOld, $corp.SpecAccent, $corp.SpecAge, $corp.SpecNationality, $corp.SpecAmputee, $corp.SpecBalls, $corp.SpecDevotion, $corp.SpecDick, $corp.SpecEducation, $corp.SpecGender, $corp.SpecGenitalia, $corp.SpecHeight, $corp.SpecHormones, $corp.SpecImplants, $corp.SpecInjection, $corp.SpecIntelligence, $corp.SpecMilk, $corp.SpecMuscle, $corp.SpecPussy, $corp.SpecSexEd, $corp.SpecTrust, $corp.SpecVirgin, $corp.SpecWeight, $dividendTimer, $personalShares, $publicShares>> <</if>> /* Porn star counts (prestige 1) and ID's (prestige 3) */ diff --git a/src/js/generateMarketSlave.js b/src/js/generateMarketSlave.js index 962e07422a0..77e0d0dc54f 100644 --- a/src/js/generateMarketSlave.js +++ b/src/js/generateMarketSlave.js @@ -30,6 +30,9 @@ window.generateMarketSlave = function(market = "kidnappers", numArcology = 1) { if (V.corp.SpecRaces.length > 0) { V.fixedRace = jsEither(V.corp.SpecRaces); } + if (V.corp.SpecNationality) { + V.fixedNationality = V.corp.SpecNationality; + } if (V.corp.SpecGender === 1) { r += `Slaves without pussies are not trained. `; V.activeSlave = GenerateNewSlave("XX"); -- GitLab