diff --git a/devTools/types/FC.d.ts b/devTools/types/FC.d.ts index 8952ac49eb45a3da1711b2432aa14a8fe23b9122..63d72036c1ed7e13767e754a6eee8c040319d1b7 100644 --- a/devTools/types/FC.d.ts +++ b/devTools/types/FC.d.ts @@ -519,7 +519,6 @@ declare global { FSStatuesqueGlorificationLaw: number; FSStatuesqueGlorificationLaw2: number; FSStatuesqueGlorificationSMR: number; - FSRestartResearchPassed: number; FSEgyptianRevivalistIncestPolicy: number; FSEgyptianRevivalistInterest: number; FSRepopulationFocusPregPolicy: number; diff --git a/js/003-data/gameVariableData.js b/js/003-data/gameVariableData.js index e3432c04859968490ce39296b3944508fa482708..83412e326c786528149110ed53b3f924a919c3c7 100644 --- a/js/003-data/gameVariableData.js +++ b/js/003-data/gameVariableData.js @@ -377,12 +377,6 @@ App.Data.resetOnNGPlus = { PClossStreak: 0, foughtThisWeek: 0, /* buildings */ - secHQ: 0, - secMenials: 0, - secUpgrades: {}, - crimeUpgrades: {}, - intelUpgrades: {}, - readinessUpgrades: {}, riotCenter: 0, riotUpgrades: {}, fort: {}, @@ -390,21 +384,6 @@ App.Data.resetOnNGPlus = { advancedRiotEquip: 0, brainImplant: -1, brainImplantProject: 0, - weapMenials: 0, - weapManu: 0, - weapProductivity: 1, - weapLab: 1, - weapUpgrades: [], - currentUpgrade: {}, - droneUpgrades: {}, - humanUpgrade: {}, - sellTo: {}, - completedUpgrades: [], - transportHub: 0, - airport: 1, - railway: 1, - docks: 1, - hubSecurity: 1, /* rebellions */ tension: 0, diff --git a/src/002-config/fc-version.js b/src/002-config/fc-version.js index 06195761b0b034389a9722ead3c5560a5b2716bf..81d046ed6ba66e2781c24c09e1d9dc6ce4c2675e 100644 --- a/src/002-config/fc-version.js +++ b/src/002-config/fc-version.js @@ -2,5 +2,5 @@ App.Version = { base: "0.10.7.1", // The vanilla version the mod is based off of, this should never be changed. pmod: "3.7.1", commitHash: null, - release: 1091 + release: 1093 }; diff --git a/src/Mods/SecExp/SecExpBackwardCompatibility.tw b/src/Mods/SecExp/SecExpBackwardCompatibility.tw index 6901f8056333e00a85e81242098e8bcaefa75d29..b8ace6a4b3f7f18fc19ab0234e7a128830009898 100644 --- a/src/Mods/SecExp/SecExpBackwardCompatibility.tw +++ b/src/Mods/SecExp/SecExpBackwardCompatibility.tw @@ -6,85 +6,6 @@ <<run App.SecExp.generalBC()>> <<set $lastRebellionWeeks = Number($lastRebellionWeeks) || 0>> -<<if ndef $currentUpgrade.ID>> - <<if $currentUpgrade.name == "magnetic based ballistic weaponry">> - <<set $currentUpgrade.ID = 0>> - <<elseif $currentUpgrade.name == "ceramo-metallic alloys">> - <<set $currentUpgrade.ID = 1>> - <<elseif $currentUpgrade.name == "rapid action stimulants">> - <<set $currentUpgrade.ID = 2>> - <<elseif $currentUpgrade.name == "fast response neural stimulant">> - <<set $currentUpgrade.ID = 3>> - <<elseif $currentUpgrade.name == "universal cyber enhancements">> - <<set $currentUpgrade.ID = 4>> - <<elseif $currentUpgrade.name == "remote neural links">> - <<set $currentUpgrade.ID = 5>> - <<elseif $currentUpgrade.name == "combined training regimens with the special force">> - <<set $currentUpgrade.ID = 6>> - <<elseif $currentUpgrade.name == "a variant of the stimulant cocktail that the special force created">> - <<set $currentUpgrade.ID = 7>> - <<elseif $currentUpgrade.name == "a mesh network based off the custom network of the special force">> - <<set $currentUpgrade.ID = 8>> - <<elseif $currentUpgrade.name == "dynamic battle aware AI">> - <<set $currentUpgrade.ID = -1>> - <<elseif $currentUpgrade.name == "adaptive armored frames">> - <<set $currentUpgrade.ID = -2>> - <<elseif $currentUpgrade.name == "advanced synthetic alloys">> - <<set $currentUpgrade.ID = -3>> - <</if>> -<</if>> -<<if $droneUpgrades == null>> - <<set $droneUpgrades = { - attack: 0, - defense: 0, - hp:0}>> -<<else>> - <<if Number.isInteger($droneUpgrades)>> - <<unset $droneUpgrades>> - <<set $droneUpgrades = { - attack: 0, - defense: 0, - hp:0}>> - <</if>> - <<if ndef $droneUpgrades.attack || !Number.isInteger($droneUpgrades.attack)>> - <<set $droneUpgrades.attack = 0>> - <</if>> - <<if ndef $droneUpgrades.defense || !Number.isInteger($droneUpgrades.defense)>> - <<set $droneUpgrades.defense = 0>> - <</if>> - <<if ndef $droneUpgrades.hp || !Number.isInteger($droneUpgrades.hp)>> - <<set $droneUpgrades.hp = 0>> - <</if>> -<</if>> -<<if $humanUpgrade == null>> - <<set $humanUpgrade = { - attack: 0, - defense: 0, - hp:0, - morale: 0}>> -<<else>> - <<if Number.isInteger($humanUpgrade)>> - <<unset $humanUpgrade>> - <<set $humanUpgrade = { - attack: 0, - defense: 0, - hp:0, - morale: 0}>> - <</if>> - <<if ndef $humanUpgrade.attack || !Number.isInteger($humanUpgrade.attack)>> - <<set $humanUpgrade.attack = 0>> - <</if>> - <<if ndef $humanUpgrade.defense || !Number.isInteger($humanUpgrade.defense)>> - <<set $humanUpgrade.defense = 0>> - <</if>> - <<if ndef $humanUpgrade.hp || !Number.isInteger($humanUpgrade.hp)>> - <<set $humanUpgrade.hp = 0>> - <</if>> - <<if ndef $humanUpgrade.morale || !Number.isInteger($humanUpgrade.morale)>> - <<set $humanUpgrade.morale = 0>> - <</if>> -<</if>> - /* SFanon additions */ <<if ndef $secUpgrades.coldstorage>> <<set $secUpgrades.coldstorage = 0>> diff --git a/src/Mods/SecExp/buildings/securityHQ.tw b/src/Mods/SecExp/buildings/securityHQ.tw index 8effa79b7d98f4d734b4d7d8949a90a7f03f75c8..7a9bc63d3bbadc068ef3199833bb686b19a88655 100644 --- a/src/Mods/SecExp/buildings/securityHQ.tw +++ b/src/Mods/SecExp/buildings/securityHQ.tw @@ -1,33 +1,28 @@ :: securityHQ [nobr jump-to-safe jump-from-safe] +<<set $nextButton = "Back", $nextLink = "Main", _HistoryDiscount = 1>> <<if $career == "mercenary" || $career == "gang" || $career == "slaver">> - <<set _HistoryDiscount = .5>> -<<else>> - <<set _HistoryDiscount = 1>> + <<set _HistoryDiscount = 0.5>> <</if>> -<<set $nextButton = "Back">> -<<set $nextLink = "Main">> - -Security Headquarters -<hr> +Security Headquarters<hr> +The security headquarters stand in front of you. Innumerable screens flood with light the great central room. <<if $SecExp.buildings.secHub.menials > 0>>Some slaves see you enter and interrupt their work to greet you.<</if>> From here you can build a safe and prosperous arcology. +<<if $SecExp.core.authority < 10000 || $SecExp.core.authority < 12000>> + <br><br>You lack the authority to access more advanced upgrades. +<</if>> -The security headquarters stand in front of you. Innumerable screens flood with light the great central room. <<if $secMenials > 0>>Some slaves see you enter and interrupt their work to greet you.<</if>> From here you can build a safe and prosperous arcology. -<br> -/* security level. Slaves */ -You have <span id="secHel"> <<print num($secMenials)>> </span> slaves working in the HQ. <<= App.SecExp.Check.reqMenials()>> are required and you have <span id="hel"> <<print num($menials)>> </span> free menial slaves. -<<if $secMenials < App.SecExp.Check.reqMenials()>> - You do not have enough slaves here. You will not receive the full benefit of the installed upgrades. +<br><br>You have <span id="secHel"> <<print num($SecExp.buildings.secHub.menials)>> </span> slaves working in the HQ. <<= App.SecExp.Check.reqMenials()>> are required and you have <span id="hel"> <<print num($menials)>> </span> free menial slaves. +<<if $SecExp.buildings.secHub.menials < App.SecExp.Check.reqMenials()>> + <br>You do not have enough slaves here. You will not receive the full benefit of the installed upgrades. <<else>> - You have enough slaves to man all security systems. + <br>You have enough slaves to man all security systems. <</if>> <<set _popCap = menialPopCap()>> <<set _menialPrice = menialSlaveCost()>> <<set _bulkMax = _popCap.value-$menials-$fuckdolls-$menialBioreactors>> <<if $cash > _menialPrice>> <<if _bulkMax > 0 || $menials+$fuckdolls+$menialBioreactors == 0>> - <br> - [[Buy|securityHQ][$menials += 1,$menialSupplyFactor -= 1, cashX(-_menialPrice, "menialTransfer")]] + <br>[[Buy|securityHQ][$menials++,$menialSupplyFactor -= 1, cashX(-_menialPrice, "menialTransfer")]] <<if $cash > (menialSlaveCost(10))*10>> [[(x10)|securityHQ][$menials += 10,$menialSupplyFactor -= 10, cashX(-(menialSlaveCost(10)*10), "menialTransfer")]] <</if>> @@ -43,164 +38,62 @@ You have <span id="secHel"> <<print num($secMenials)>> </span> slaves working in //Bulk transactions may require offering a premium. The remaining slaves will be more efficient in dealing with crime.// <</if>> <</if>> + +<<set _optionsList = [1, 5, 10, 100, 500, 100]>> <<if $menials > 0>> <br>Transfer in: - <<if $menials >= 5>> - <<link "5">> - <<set $menials -= 5>> - <<set $secMenials += 5>> - <<replace "#secHel">><<print $secMenials>><</replace>> - <<replace "#hel">><<print $menials>><</replace>> - <<if $menials < 5 || $secMenials >= App.SecExp.Check.reqMenials() || $secMenials == 5>> - <<goto "securityHQ">> - <</if>> - <</link>> - <</if>> - <<if $menials >= 10>> - |<<link "10">> - <<set $menials -= 10>> - <<set $secMenials += 10>> - <<replace "#secHel">><<print $secMenials>><</replace>> - <<replace "#hel">><<print $menials>><</replace>> - <<if $menials < 10 || $secMenials >= App.SecExp.Check.reqMenials() || $secMenials == 10>> - <<goto "securityHQ">> - <</if>> - <</link>> - <</if>> - <<if $menials >= 100>> - |<<link "100">> - <<set $menials -= 100>> - <<set $secMenials += 100>> - <<replace "#secHel">><<print $secMenials>><</replace>> - <<replace "#hel">><<print $menials>><</replace>> - <<if $menials < 100 || $secMenials >= App.SecExp.Check.reqMenials() || $secMenials == 100>> - <<goto "securityHQ">> - <</if>> - <</link>> - <</if>> - <<if $menials >= 500>> - |<<link "500">> - <<set $menials -= 500>> - <<set $secMenials += 500>> - <<replace "#secHel">><<print $secMenials>><</replace>> - <<replace "#hel">><<print $menials>><</replace>> - <<if $menials < 500 || $secMenials >= App.SecExp.Check.reqMenials() || $secMenials == 500>> - <<goto "securityHQ">> - <</if>> - <</link>> - <</if>> - <<if $menials >= 1000>> - |<<link "1000">> - <<set $menials -= 1000>> - <<set $secMenials += 1000>> - <<replace "#secHel">><<print $secMenials>><</replace>> - <<replace "#hel">><<print $menials>><</replace>> - <<if $menials < 1000 || $secMenials >= App.SecExp.Check.reqMenials() || $secMenials == 1000>> - <<goto "securityHQ">> - <</if>> - <</link>> - <</if>> - - <<if $secMenials > 0>> - <br>Transfer out - <<if $secMenials >= 5>> - <<link "5">> - <<set $menials += 5>> - <<set $secMenials -= 5>> - <<replace "#secHel">><<print $secMenials>><</replace>> - <<replace "#hel">><<print $menials>><</replace>> - <<if $secMenials < 5>> - <<goto "securityHQ">> - <</if>> - <<if $secMenials < App.SecExp.Check.reqMenials()>> - <<goto "securityHQ">> - <</if>> - <</link>> - <</if>> - <<if $secMenials >= 10>> - |<<link "10">> - <<set $menials += 10>> - <<set $secMenials -= 10>> - <<replace "#secHel">><<print $secMenials>><</replace>> - <<replace "#hel">><<print $menials>><</replace>> - <<if $secMenials < 10>> - <<goto "securityHQ">> - <</if>> - <<if $secMenials < App.SecExp.Check.reqMenials()>> - <<goto "securityHQ">> - <</if>> - <</link>> - <</if>> - <<if $secMenials >= 100>> - |<<link "100">> - <<set $menials += 100>> - <<set $secMenials -= 100>> - <<replace "#secHel">><<print $secMenials>><</replace>> - <<replace "#hel">><<print $menials>><</replace>> - <<if $secMenials < 100>> - <<goto "securityHQ">> - <</if>> - <<if $secMenials < App.SecExp.Check.reqMenials()>> - <<goto "securityHQ">> - <</if>> - <</link>> - <</if>> - <<if $secMenials >= 500>> - |<<link "500">> - <<set $menials += 500>> - <<set $secMenials -= 500>> - <<replace "#secHel">><<print $secMenials>><</replace>> + <<for _i = 0; _i < _optionsList.length; _i++>> + <<capture _optionsList[_i]>> + <<if $menials >= _optionsList[_i]>> + <<if _optionsList[_i] > 1>> | <</if>> + <<link _optionsList[_i]>> + <<set $menials -= _optionsList[_i]>> + <<set $SecExp.buildings.secHub.menials += _optionsList[_i]>> + <<replace "#secHel">><<print $SecExp.buildings.secHub.menials>><</replace>> <<replace "#hel">><<print $menials>><</replace>> - <<if $secMenials < 500>> - <<goto "securityHQ">> - <</if>> - <<if $secMenials < App.SecExp.Check.reqMenials()>> + <<if $menials < _optionsList[_i] || $SecExp.buildings.secHub.menials >= App.SecExp.Check.reqMenials() || $SecExp.buildings.secHub.menials == _i>> <<goto "securityHQ">> <</if>> <</link>> <</if>> - <<if $secMenials >= 1000>> - |<<link "1000">> - <<set $menials += 1000>> - <<set $secMenials -= 1000>> - <<replace "#secHel">><<print $secMenials>><</replace>> + <</capture>> + <</for>> + + <<if $SecExp.buildings.secHub.menials > 0>> + <br>Transfer out + <<for _i = 0; _i < _optionsList.length; _i++>> + <<capture _optionsList[_i]>> + <<if _optionsList[_i] > 1>> | <</if>> + <<link _optionsList[_i]>> + <<set $menials += _optionsList[_i]>> + <<set $SecExp.buildings.secHub.menials -= _optionsList[_i]>> + <<replace "#secHel">><<print $SecExp.buildings.secHub.menials>><</replace>> <<replace "#hel">><<print $menials>><</replace>> - <<if $secMenials < 1000>> - <<goto "securityHQ">> - <</if>> - <<if $secMenials < App.SecExp.Check.reqMenials()>> + <<if $SecExp.buildings.secHub.menials < _optionsList[_i] || $SecExp.buildings.secHub.menials < App.SecExp.Check.reqMenials()>> <<goto "securityHQ">> <</if>> <</link>> - <</if>> + <</capture>> + <</for>> <</if>> <</if>> -<<if $secMenials != App.SecExp.Check.reqMenials()>> +<<if $SecExp.buildings.secHub.menials != App.SecExp.Check.reqMenials()>> <br><<link "Match the requirement" "securityHQ">> - <<if $menials >= App.SecExp.Check.reqMenials() - $secMenials>> - <<set $menials -= App.SecExp.Check.reqMenials() - $secMenials>> - <<set $secMenials = App.SecExp.Check.reqMenials()>> - <<elseif App.SecExp.Check.reqMenials() < $secMenials>> - <<set $menials += $secMenials - App.SecExp.Check.reqMenials()>> - <<set $secMenials = App.SecExp.Check.reqMenials()>> + <<if $menials >= App.SecExp.Check.reqMenials() - $SecExp.buildings.secHub.menials>> + <<set $menials -= App.SecExp.Check.reqMenials() - $SecExp.buildings.secHub.menials>> + <<set $SecExp.buildings.secHub.menials = App.SecExp.Check.reqMenials()>> + <<elseif App.SecExp.Check.reqMenials() < $SecExp.buildings.secHub.menials>> + <<set $menials += $SecExp.buildings.secHub.menials - App.SecExp.Check.reqMenials()>> + <<set $SecExp.buildings.secHub.menials = App.SecExp.Check.reqMenials()>> <<else>> - <<set $secMenials += $menials>> + <<set $SecExp.buildings.secHub.menials += $menials>> <<set $menials = 0>> <</if>> - /*<<replace "#secHel">><<print $secMenials>><</replace>> - <<replace "#hel">><<print $menials>><</replace>> - <<if $secMenials == App.SecExp.Check.reqMenials()>> - <<goto "securityHQ">> - <</if>> - */ <</link>> <</if>> -<br><br> - -/* security level and upgrades */ -Your security level (@@.deepskyblue;$SecExp.core.security@@) +<br><br>Your security level (@@.deepskyblue;$SecExp.core.security@@) /* security level and upgrades */ <<if $SecExp.core.security <= 20>> is dangerously low. <<elseif $SecExp.core.security <= 40>> @@ -212,48 +105,9 @@ Your security level (@@.deepskyblue;$SecExp.core.security@@) <<else>> is great. <</if>> -Considering the current upgrades the resting level for security is <<print App.SecExp.Check.reqMenials()>>, while the effective maximum level is <<print Math.trunc(App.SecExp.Check.reqMenials() * (Math.clamp($secMenials,0,App.SecExp.Check.reqMenials()) / App.SecExp.Check.reqMenials()))>>. - -<br> -<br> +Considering the current upgrades the resting level for security is <<print App.SecExp.Check.reqMenials()>>, while the effective maximum level is <<print Math.trunc(App.SecExp.Check.reqMenials() * (Math.clamp($SecExp.buildings.secHub.menials,0,App.SecExp.Check.reqMenials()) / App.SecExp.Check.reqMenials()))>>. -<<if $secUpgrades.nanoCams == 0>> - [[Install a nano-camera system |securityHQ][cashX(-Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.nanoCams = 1]] - <br>//Costs <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will raise rest point of security by 10 points, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// -<<else>> - You have installed all across the arcology closed circuit nano-cameras to keep the arcology under your watchful eye. -<</if>> -<br> -<<if $secUpgrades.cyberBots == 0>> - [[Buy cybersecurity algorithms|securityHQ][cashX(-Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.cyberBots = 1]] - <br>//Costs <<print cashFormat(Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will raise rest point of security by 10 points, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// -<<else>> - You have bought advanced cybersecurity algorithms that will defend your arcology against hack attempts or cyber frauds. -<</if>> -<br> -<<if $SecExp.core.authority > 10000>> - <<if $secUpgrades.eyeScan == 0>> - [[Install invisible eye scanners|securityHQ][cashX(-Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.eyeScan = 1]] - <br>//Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will raise rest point of security by 15 points, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<else>> - You have installed numerous hidden eye scanners that accurately register the movements of everyone inside the arcology. - <</if>> - <br> - <<if $secUpgrades.cryptoAnalyzer == 0>> - [[Buy and install crypto analyzers|securityHQ][cashX(-Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.cryptoAnalyzer = 1]] - <br>//Costs <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will raise rest point of security by 15 points, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<else>> - You have bought and employed sophisticated crypto analyzing software to accurately track and archive every financial movement or transaction made inside the walls of your arcology. - <</if>> -<<else>> - <br>You lack the authority to access more advanced upgrades. -<</if>> - -<br> -<br> - -/* crime level and upgrades */ -Your crime level (@@.orangered;$SecExp.core.crimeLow@@) +<br>Your crime level (@@.orangered;$SecExp.core.crimeLow@@) /* crime level and upgrades */ <<if $SecExp.core.crimeLow <= 20>> is very low. <<elseif $SecExp.core.crimeLow <= 40>> @@ -265,178 +119,188 @@ Your crime level (@@.orangered;$SecExp.core.crimeLow@@) <<else>> is extremely high. <</if>> -Considering the current upgrades the maximum level of crime is <<print App.SecExp.Check.crimeCap()>>, while the effective maximum level is <<print Math.trunc(Math.clamp(App.SecExp.Check.crimeCap() + (App.SecExp.Check.crimeCap() - App.SecExp.Check.crimeCap() * ($secMenials / App.SecExp.Check.reqMenials())),0,100))>>. - -<br> -<br> - -<<if $crimeUpgrades.advForensic == 0>> - [[Install advanced forensic equipment|securityHQ][cashX(-Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $crimeUpgrades.advForensic = 1, $PC.skill.hacking += 1]] - <br>//Costs <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will bring down the crime level cap by 10 points, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// -<<else>> - You have installed advanced forensic equipment, able to extract every bit of precious information from any clue. -<</if>> -<br> -<<if $crimeUpgrades.autoArchive == 0>> - [[Install auto-curating archiver|securityHQ][cashX(-Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $crimeUpgrades.autoArchive = 1, $PC.skill.hacking += 1]] - <br>//Costs <<print cashFormat(Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will bring down the crime level cap by 10 points, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// -<<else>> - You have installed auto-curating archiver software, which will update in real time your data archives with any new relevant information on criminals residing in your arcology. -<</if>> -<br> -<<if $SecExp.core.authority > 10000>> - <<if $crimeUpgrades.autoTrial == 0>> - [[Install automated trials software|securityHQ][cashX(-Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $crimeUpgrades.autoTrial = 1, $PC.skill.hacking += 1]] - <br>//Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will bring down the crime level cap by 15 points, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<else>> - You have installed advanced legal algorithms that allows the handling of legal matters much quicker and much more accurately. - <</if>> - <br> - <<if $crimeUpgrades.worldProfiler == 0>> - [[Install worldwide profilers|securityHQ][cashX(-Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $crimeUpgrades.worldProfiler = 1, $PC.skill.hacking += 1]] - <br>//Costs <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will bring down the crime level cap by 15 points, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<else>> - You have installed advanced profiler software, which will constantly scour every known data archive on the globe (legally or not) to gather as much information as possible on dangerous criminals. - <</if>> -<<else>> - <br>You lack the authority to access more advanced upgrades. -<</if>> - -<br> -<br> - -/* intelligence */ +Considering the current upgrades the maximum level of crime is <<print App.SecExp.Check.crimeCap()>>, while the effective maximum level is <<print Math.trunc(Math.clamp(App.SecExp.Check.crimeCap() + (App.SecExp.Check.crimeCap() - App.SecExp.Check.crimeCap() * ($SecExp.buildings.secHub.menials / App.SecExp.Check.reqMenials())),0,100))>>. <<if App.SecExp.battle.recon() == 0>> - Your reconnaissance capabilities are very limited. Very little information will be available if the arcology is attacked. + <br>Your reconnaissance capabilities are very limited. Very little information will be available if the arcology is attacked. <<elseif App.SecExp.battle.recon() == 1>> - You have limited reconnaissance capabilities. You'll have limited intel available in case of an attack. + <br>You have limited reconnaissance capabilities. You'll have limited intel available in case of an attack. <<elseif App.SecExp.battle.recon() == 2>> - You have good reconnaissance capabilities. Good, reliable intel will be available if the arcology is attacked. -<<else>> - You have great reconnaissance capabilities. You'll have very accurate information on the enemy if the arcology is attacked. -<</if>> - -<br> -<br> - -<<if $intelUpgrades.sensors == 0>> - [[Install perimeter sensors|securityHQ][cashX(-Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $intelUpgrades.sensors = 1, $PC.skill.hacking += 1]] - <br>//Costs <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will increase recon capabilities, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// -<<else>> - You have installed perimeter seismic sensors able to detect movement with high accuracy. -<</if>> -<br> -<<if $intelUpgrades.signalIntercept == 0>> - [[Create signal interception hub|securityHQ][cashX(-Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $intelUpgrades.signalIntercept = 1, $PC.skill.hacking += 1]] - <br>//Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will increase recon capabilities, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// -<<else>> - You have installed advanced signal interception equipment. -<</if>> -<br> -<<if $SecExp.core.authority > 10000>> - <<if $intelUpgrades.radar == 0>> - [[Install advanced radar equipment|securityHQ][cashX(-Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $intelUpgrades.radar = 1, $PC.skill.hacking += 1]] - <br>//Costs <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will increase recon capabilities, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<else>> - You have installed sophisticated radar equipment. - <</if>> + <br>You have good reconnaissance capabilities. Good, reliable intel will be available if the arcology is attacked. <<else>> - <br>You lack the authority to access more advanced upgrades. + <br>You have great reconnaissance capabilities. You'll have very accurate information on the enemy if the arcology is attacked. <</if>> -<br> -<br> - -/* readiness */ - <<if App.SecExp.battle.deploySpeed() == 1>> - You have low readiness. You won't be able to mobilize many troops in time in case of an attack. + <br>You have low readiness. You won't be able to mobilize many troops in time in case of an attack. <<elseif App.SecExp.battle.deploySpeed() == 2>> - You have decent readiness. You will be able to muster up sufficient forces to handle an average attack. + <br>You have decent readiness. You will be able to muster up sufficient forces to handle an average attack. <<elseif App.SecExp.battle.deploySpeed() == 3>> - You have good readiness. You will be able to mobilize a lot of troops in case of an attack. + <br>You have good readiness. You will be able to mobilize a lot of troops in case of an attack. <<else>> - You have great readiness. You can mobilize a small army in very little time. + <br>You have great readiness. You can mobilize a small army in very little time. <</if>> -<br> -<br> - -<<if $readinessUpgrades.pathways == 0>> - [[Build specialized pathways in the arcology|securityHQ][cashX(-Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount), "capEx"), $readinessUpgrades.pathways = 1]] - <br>//Costs <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount))>>. Will increase readiness by 1, but will increase upkeep. The remaining slaves will be more efficient in dealing with crime.// -<<else>> - You have built specialized pathways inside the arcology to quickly move troops around the structure. -<</if>> -<br> -<<if $readinessUpgrades.rapidVehicles == 0>> - [[Buy rapid armored transport vehicles|securityHQ][cashX(-Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount), "capEx"), $readinessUpgrades.rapidVehicles = 1]] - <br>//Costs <<print cashFormat(Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount))>>. Will increase readiness by 2, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// -<<else>> - You have bought rapid armored transport vehicles able to bring your troops to battle much quicker than before. -<</if>> -<br> -<<if $SecExp.core.authority > 10000>> - <<if $readinessUpgrades.rapidPlatforms == 0>> - [[Build rapid deployment platforms|securityHQ][cashX(-Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount), "capEx"), $readinessUpgrades.rapidPlatforms = 1]] - <br>//Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount))>>. Will increase readiness by 2, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<else>> - You have built rapid deployment platforms able to equip and deploy units within very limited time windows. - <</if>> - <br> - <<if $readinessUpgrades.earlyWarn == 0>> - [[Institute early warning systems|securityHQ][cashX(-Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount), "capEx"), $readinessUpgrades.earlyWarn = 1]] - <br>//Costs <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount))>>. Will increase readiness by 2, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<else>> - You have created early warning systems that constantly analyze in real time data to determine the likeness of an attack. - <</if>> -<<else>> - <br>You lack the authority to access more advanced upgrades. -<</if>> - -<br> - <<if $SecExp.core.authority > 12000>> - <br>__Cold Data Storage Facility__: + <br><br>__Cold Data Storage Facility__: <<if App.SecExp.Check.reqMenials() <= 10>> <br>Personnel cannot be further reduced. - <<elseif $secUpgrades.coldstorage > 6>> + <<elseif $SecExp.buildings.secHub.coldstorage > 6>> <br>You have installed a cold storage facility for the Security HQ's archives with a data retention capability of three years. - <<elseif $secUpgrades.coldstorage == 6 && $SecExp.core.authority >= 19500 && App.SecExp.Check.reqMenials() > 10>> + <<elseif $SecExp.buildings.secHub.coldstorage == 6 && $SecExp.core.authority >= 19500 && App.SecExp.Check.reqMenials() > 10>> <br>You have installed a cold storage facility for the Security HQ's archives with a data retention capability of two years. - <br> - [[Expand the cold storage facility to increase data retention to three years|securityHQ][cashX(-Math.trunc(2400000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.coldstorage++, $PC.skill.hacking += 1]] + <br>[[Expand the cold storage facility to increase data retention to three years|securityHQ][cashX(-Math.trunc(2400000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.coldstorage++, $PC.skill.hacking += 1]] <br>//Costs <<print cashFormat(Math.trunc(2400000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will lower the amount of required slaves by a further 10, but will increase upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<elseif $secUpgrades.coldstorage == 5 && $SecExp.core.authority >= 19500 && App.SecExp.Check.reqMenials() > 10>> + <<elseif $SecExp.buildings.secHub.coldstorage == 5 && $SecExp.core.authority >= 19500 && App.SecExp.Check.reqMenials() > 10>> <br>You have installed a cold storage facility for the Security HQ's archives with a data retention capability of one year. - <br> - [[Expand the cold storage facility to increase data retention to two years|securityHQ][cashX(-Math.trunc(1200000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.coldstorage++, $PC.skill.hacking += 1]] + <br>[[Expand the cold storage facility to increase data retention to two years|securityHQ][cashX(-Math.trunc(1200000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.coldstorage++, $PC.skill.hacking += 1]] <br>//Costs <<print cashFormat(Math.trunc(1200000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will lower the amount of required slaves by a further 10, but will increase upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<elseif $secUpgrades.coldstorage == 4 && $SecExp.core.authority >= 19500 && App.SecExp.Check.reqMenials() > 10>> + <<elseif $SecExp.buildings.secHub.coldstorage == 4 && $SecExp.core.authority >= 19500 && App.SecExp.Check.reqMenials() > 10>> <br>You have installed a cold storage facility for the Security HQ's archives with a data retention capability of nine months. - <br> - [[Expand the cold storage facility to increase data retention to one year|securityHQ][cashX(-Math.trunc(900000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.coldstorage++, $PC.skill.hacking += 1]] + <br>[[Expand the cold storage facility to increase data retention to one year|securityHQ][cashX(-Math.trunc(900000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.coldstorage++, $PC.skill.hacking += 1]] <br>//Costs <<print cashFormat(Math.trunc(900000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will lower the amount of required slaves by a further 10, but will increase upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<elseif $secUpgrades.coldstorage == 3 && $SecExp.core.authority > 18000 && App.SecExp.Check.reqMenials() > 10>> + <<elseif $SecExp.buildings.secHub.coldstorage == 3 && $SecExp.core.authority > 18000 && App.SecExp.Check.reqMenials() > 10>> <br>You have installed a cold storage facility for the Security HQ's archives with a data retention capability of six months. - <br> - [[Expand the cold storage facility to increase data retention to nine months|securityHQ][cashX(-Math.trunc(600000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.coldstorage++, $PC.skill.hacking += 1]] + <br>[[Expand the cold storage facility to increase data retention to nine months|securityHQ][cashX(-Math.trunc(600000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.coldstorage++, $PC.skill.hacking += 1]] <br>//Costs <<print cashFormat(Math.trunc(600000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will lower the amount of required slaves by a further 10, but will increase upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<elseif $secUpgrades.coldstorage == 2 && $SecExp.core.authority > 16000 && App.SecExp.Check.reqMenials() > 10>> + <<elseif $SecExp.buildings.secHub.coldstorage == 2 && $SecExp.core.authority > 16000 && App.SecExp.Check.reqMenials() > 10>> <br>You have installed a cold storage facility for the Security HQ's archives with a data retention capability of three months. - <br> - [[Expand the cold storage facility to increase data retention to six months|securityHQ][cashX(-Math.trunc(300000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.coldstorage++, $PC.skill.hacking += 1]] + <br>[[Expand the cold storage facility to increase data retention to six months|securityHQ][cashX(-Math.trunc(300000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.coldstorage++, $PC.skill.hacking += 1]] <br>//Costs <<print cashFormat(Math.trunc(300000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will lower the amount of required slaves by a further 10, but will increase upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<elseif $secUpgrades.coldstorage == 1 && $SecExp.core.authority > 14000 && App.SecExp.Check.reqMenials() > 10>> + <<elseif $SecExp.buildings.secHub.coldstorage == 1 && $SecExp.core.authority > 14000 && App.SecExp.Check.reqMenials() > 10>> <br>You have installed a cold storage facility for the Security HQ's archives with a data retention capability of one month. - <br> - [[Expand the cold storage facility to increase data retention to three months|securityHQ][cashX(-Math.trunc(100000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.coldstorage++, $PC.skill.hacking += 1]] + <br>[[Expand the cold storage facility to increase data retention to three months|securityHQ][cashX(-Math.trunc(100000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.coldstorage++, $PC.skill.hacking += 1]] <br>//Costs <<print cashFormat(Math.trunc(100000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will lower the amount of required slaves by a further 10, but will increase upkeep. The remaining slaves will be more efficient in dealing with crime.// - <<elseif $secUpgrades.coldstorage == 0 && $SecExp.core.authority > 12000 && App.SecExp.Check.reqMenials() > 10>> - [[Install a cold storage facility|securityHQ][cashX(-Math.trunc(50000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $secUpgrades.coldstorage++, $PC.skill.hacking += 1]] + <<elseif $SecExp.buildings.secHub.coldstorage == 0 && $SecExp.core.authority > 12000 && App.SecExp.Check.reqMenials() > 10>> + [[Install a cold storage facility|securityHQ][cashX(-Math.trunc(50000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.coldstorage++, $PC.skill.hacking += 1]] <br>//Costs <<print cashFormat(Math.trunc(50000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will lower the amount of required slaves by 10, but will increase upkeep. The remaining slaves will be more efficient in dealing with crime.// <</if>> -<<else>> - <br>You lack the authority to access more advanced upgrades. <</if>> + +<br><br> <<run App.UI.tabBar.handlePreSelectedTab($tabChoice.securityHQ)>> +<div class="tab-bar"> + <button class="tab-links" onclick="App.UI.tabBar.openTab(event, 'SecurityCrime')" id="tab SecurityCrime">Security and crime</button> + <button class="tab-links" onclick="App.UI.tabBar.openTab(event, 'ReconReadiness')" id="tab ReconReadiness">Reconnaissance and readiness</button> +</div> + +<div id="SecurityCrime" class="tab-content"> + <div class="content"> + Security<hr> + <<if $SecExp.buildings.secHub.upgrades.security.nanoCams == 0>> + [[Install a nano-camera system |securityHQ][cashX(-Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.security.nanoCams = 1]] + <br>//Costs <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will raise rest point of security by 10 points, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + You have installed all across the arcology closed circuit nano-cameras to keep the arcology under your watchful eye. + <</if>> + + <<if $SecExp.buildings.secHub.upgrades.security.cyberBots == 0>> + <br>[[Buy cybersecurity algorithms|securityHQ][cashX(-Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.security.cyberBots = 1]] + <br>//Costs <<print cashFormat(Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will raise rest point of security by 10 points, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have bought advanced cybersecurity algorithms that will defend your arcology against hack attempts or cyber frauds. + <</if>> + + <<if $SecExp.core.authority > 10000>> + <<if $SecExp.buildings.secHub.upgrades.security.eyeScan == 0>> + <br>[[Install invisible eye scanners|securityHQ][cashX(-Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.security.eyeScan = 1]] + <br>//Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will raise rest point of security by 15 points, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have installed numerous hidden eye scanners that accurately register the movements of everyone inside the arcology. + <</if>> + <<if $SecExp.buildings.secHub.upgrades.security.cryptoAnalyzer == 0>> + <br>[[Buy and install crypto analyzers|securityHQ][cashX(-Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.security.cryptoAnalyzer = 1]] + <br>//Costs <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will raise rest point of security by 15 points, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have bought and employed sophisticated crypto analyzing software to accurately track and archive every financial movement or transaction made inside the walls of your arcology. + <</if>> + <</if>> + + <br><br>Crime<hr> + <<if $SecExp.buildings.secHub.upgrades.crime.advForensic == 0>> + [[Install advanced forensic equipment|securityHQ][cashX(-Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.crime.advForensic = 1, $PC.skill.hacking += 1]] + <br>//Costs <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will bring down the crime level cap by 10 points, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + You have installed advanced forensic equipment, able to extract every bit of precious information from any clue. + <</if>> + + <<if $SecExp.buildings.secHub.upgrades.crime.autoArchive == 0>> + <br>[[Install auto-curating archiver|securityHQ][cashX(-Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.crime.autoArchive = 1, $PC.skill.hacking += 1]] + <br>//Costs <<print cashFormat(Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will bring down the crime level cap by 10 points, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have installed auto-curating archiver software, which will update in real time your data archives with any new relevant information on criminals residing in your arcology. + <</if>> + + <<if $SecExp.core.authority > 10000>> + <<if $SecExp.buildings.secHub.upgrades.crime.autoTrial == 0>> + <br>[[Install automated trials software|securityHQ][cashX(-Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.crime.autoTrial = 1, $PC.skill.hacking += 1]] + <br>//Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will bring down the crime level cap by 15 points, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have installed advanced legal algorithms that allows the handling of legal matters much quicker and much more accurately. + <</if>> + <<if $SecExp.buildings.secHub.upgrades.crime.worldProfiler == 0>> + <br>[[Install worldwide profilers|securityHQ][cashX(-Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.crime.worldProfiler = 1, $PC.skill.hacking += 1]] + <br>//Costs <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will bring down the crime level cap by 15 points, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have installed advanced profiler software, which will constantly scour every known data archive on the globe (legally or not) to gather as much information as possible on dangerous criminals. + <</if>> + <</if>> + </div> +</div> + +<div id="ReconReadiness" class="tab-content"> + <div class="content"> + Reconnaissance<hr> + <<if $SecExp.buildings.secHub.upgrades.intel.sensors == 0>> + [[Install perimeter sensors|securityHQ][cashX(-Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.intel.sensors = 1, $PC.skill.hacking += 1]] + <br>//Costs <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will increase recon capabilities, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + You have installed perimeter seismic sensors able to detect movement with high accuracy. + <</if>> + + <<if $SecExp.buildings.secHub.upgrades.intel.signalIntercept == 0>> + <br>[[Create signal interception hub|securityHQ][cashX(-Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.intel.signalIntercept = 1, $PC.skill.hacking += 1]] + <br>//Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will increase recon capabilities, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have installed advanced signal interception equipment. + <</if>> + + <<if $SecExp.core.authority > 10000>> + <<if $SecExp.buildings.secHub.upgrades.intel.radar == 0>> + <br>[[Install advanced radar equipment|securityHQ][cashX(-Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier), "capEx"), $SecExp.buildings.secHub.upgrades.intel.radar = 1, $PC.skill.hacking += 1]] + <br>//Costs <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount*$HackingSkillMultiplier))>>. Will increase recon capabilities, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have installed sophisticated radar equipment. + <</if>> + <</if>> + + <br><br>Readiness<hr> + <<if $SecExp.buildings.secHub.upgrades.readiness.pathways == 0>> + [[Build specialized pathways in the arcology|securityHQ][cashX(-Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount), "capEx"), $SecExp.buildings.secHub.upgrades.readiness.pathways = 1]] + <br>//Costs <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology*_HistoryDiscount))>>. Will increase readiness by 1, but will increase upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + You have built specialized pathways inside the arcology to quickly move troops around the structure. + <</if>> + + <<if $SecExp.buildings.secHub.upgrades.readiness.rapidVehicles == 0>> + <br>[[Buy rapid armored transport vehicles|securityHQ][cashX(-Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount), "capEx"), $SecExp.buildings.secHub.upgrades.readiness.rapidVehicles = 1]] + <br>//Costs <<print cashFormat(Math.trunc(7500*$upgradeMultiplierArcology*_HistoryDiscount))>>. Will increase readiness by 2, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have bought rapid armored transport vehicles able to bring your troops to battle much quicker than before. + <</if>> + + <<if $SecExp.core.authority > 10000>> + <<if $SecExp.buildings.secHub.upgrades.readiness.rapidPlatforms == 0>> + <br>[[Build rapid deployment platforms|securityHQ][cashX(-Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount), "capEx"), $SecExp.buildings.secHub.upgrades.readiness.rapidPlatforms = 1]] + <br>//Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology*_HistoryDiscount))>>. Will increase readiness by 2, but will require 5 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have built rapid deployment platforms able to equip and deploy units within very limited time windows. + <</if>> + <<if $SecExp.buildings.secHub.upgrades.readiness.earlyWarn == 0>> + <br>[[Institute early warning systems|securityHQ][cashX(-Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount), "capEx"), $SecExp.buildings.secHub.upgrades.readiness.earlyWarn = 1]] + <br>//Costs <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology*_HistoryDiscount))>>. Will increase readiness by 2, but will require 10 extra slaves in the headquarters and increases upkeep. The remaining slaves will be more efficient in dealing with crime.// + <<else>> + <br>You have created early warning systems that constantly analyze in real time data to determine the likeness of an attack. + <</if>> + <</if>> + </div> +</div> \ No newline at end of file diff --git a/src/Mods/SecExp/buildings/transportHub.tw b/src/Mods/SecExp/buildings/transportHub.tw index e23ee48ac11d2242bc3f3187b40d650361c95212..53bae3e250548cba8d12798d033982607aee8d16 100644 --- a/src/Mods/SecExp/buildings/transportHub.tw +++ b/src/Mods/SecExp/buildings/transportHub.tw @@ -2,9 +2,8 @@ <<set $nextButton = "Back", $nextLink = "Main">> -<strong>The Transport Hub</strong> -<hr> -You quickly reach the transport hub, where a constant stream of vehicles, people and goods greets you. Part of the structure is dedicated to air travel and the other is mainly occupied by <<if $terrain != "oceanic" && $terrain != "marine">>the rail station.<<else>> the docks.<</if>> +<strong>The Transport Hub</strong> <hr> +You quickly reach the transport hub, where a constant stream of vehicles, people and goods greets you. Part of the structure is dedicated to air travel and the other is mainly occupied by the <<if $terrain != "oceanic" && $terrain != "marine">>rail station<<else>>docks<</if>>. <<if $SecExp.edicts.limitImmigration == 1 || $policies.immigrationRep == -1>> Due to your strict policies concerning immigration, very few new citizens arrive in the transport hub. @@ -12,165 +11,143 @@ You quickly reach the transport hub, where a constant stream of vehicles, people Due to your liberal policies concerning immigration, the transport hub is filled with a flow of new citizens. <</if>> -<<if $airport == 1>> - The arcology's airport is relatively small and poorly equipped. It can handle some traffic, but nothing noteworthy. -<<elseif $airport == 2>> - The arcology's airport is relatively small, but well equipped. It can handle some traffic, but nothing too serious. -<<elseif $airport == 3>> - The arcology's airport is good sized and well equipped. It can handle a good amount of traffic. -<<elseif $airport == 4>> - The arcology's airport is good sized and very well equipped. It can handle a lot of traffic. +<<if $SecExp.buildings.transportHub.airport == 1>> + The arcology's airport is relatively small and poorly equipped. It can handle some traffic, but nothing noteworthy. +<<elseif $SecExp.buildings.transportHub.airport == 2>> + The arcology's airport is relatively small, but well equipped. It can handle some traffic, but nothing too serious. +<<elseif $SecExp.buildings.transportHub.airport == 3>> + The arcology's airport is good sized and well equipped. It can handle a good amount of traffic. +<<elseif $SecExp.buildings.transportHub.airport == 4>> + The arcology's airport is good sized and very well equipped. It can handle a lot of traffic. <<else>> - The arcology's airport is huge and very well equipped. It can handle an impressive amount of traffic. + The arcology's airport is huge and very well equipped. It can handle an impressive amount of traffic. <</if>> <<if $terrain != "oceanic" && $terrain != "marine">> - <<if $railway == 1>> + <<if $SecExp.buildings.transportHub.surfaceTransport == 1>> The railway network is old and limited. It can handle some traffic, but not sustain commercial activity. - <<elseif $railway == 2>> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 2>> The railway network is modern and efficient, but limited in reach. It can handle some traffic, but not sustain commercial activity of any significant size. - <<elseif $railway == 3>> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 3>> The railway network is modern, efficient and expansive. It can handle a significant amount of traffic. <<else>> The railway network is high tech and very far reaching. It can handle an enormous amount of traffic. <</if>> <<else>> - <<if $docks == 1>> + <<if $SecExp.buildings.transportHub.surfaceTransport == 1>> The docks are old and small. They can handle some traffic, but not sustain commercial activity. - <<elseif $docks == 2>> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 2>> The docks are modern and efficient, but limited in size. They can handle some traffic, but not sustain commercial activity of significant size. - <<elseif $docks == 3>> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 3>> The docks are modern, efficient and expansive. They can handle a significant amount of traffic. <<else>> The docks are huge in size and high tech. They can handle an enormous amount of traffic. <</if>> <</if>> -<<if $hubSecurity == 1>> + +<<if $SecExp.buildings.transportHub.security == 1>> The security of the hub is limited to a few cameras and the occasional guard. -<<elseif $hubSecurity == 2>> +<<elseif $SecExp.buildings.transportHub.security == 2>> The security of the hub is guaranteed by a powerful camera surveillance system. -<<elseif $hubSecurity == 3>> +<<elseif $SecExp.buildings.transportHub.security == 3>> The security of the hub is guaranteed by a powerful camera surveillance system and a rapid response team constantly patrolling the structure. <<else>> The security of the hub is guaranteed by a powerful camera surveillance system, a rapid response team constantly patrolling the building and additional security drones making the rounds around the exterior. <</if>> -<br> -<br> - <<if $SecExp.core.trade <= 20>> - Trade is @@.red;almost non-existent.@@ Outside the supplies for the arcology's domestic consumption little else crosses the territory of the free city. + <br><br>Trade is @@.red;almost non-existent.@@ Outside the supplies for the arcology's domestic consumption little else crosses the territory of the free city. <<elseif $SecExp.core.trade <= 40>> - Trade is @@.orange;low.@@ There's some but limited commercial activity crossing the territory of the free city. + <br><br>Trade is @@.orange;low.@@ There's some but limited commercial activity crossing the territory of the free city. <<elseif $SecExp.core.trade <= 60>> - Trade is at @@.yellow;positive levels.@@ There's a good amount commercial activity outside the supplies for the arcology's domestic consumption. + <br><br>Trade is at @@.yellow;positive levels.@@ There's a good amount commercial activity outside the supplies for the arcology's domestic consumption. <<elseif $SecExp.core.trade <= 80>> - Trade is at @@.limegreen;high levels.@@ There's a lot of commercial activity outside the supplies for the arcology's domestic consumption. + <br><br>Trade is at @@.limegreen;high levels.@@ There's a lot of commercial activity outside the supplies for the arcology's domestic consumption. <<else>> - Trade is at @@.green;extremely high levels.@@ There's a constant stream of commercial activity crossing the arcology. + <br><br>Trade is at @@.green;extremely high levels.@@ There's a constant stream of commercial activity crossing the arcology. <</if>> -<br> -<br> -/* airport */ -<<if $airport == 1>> - <<link "Modernize the airport">> +<<if $SecExp.buildings.transportHub.airport == 1>> + <br><br> <<link "Modernize the airport" "transportHub">> <<run cashX(forceNeg(Math.trunc(5000*$upgradeMultiplierArcology)), "capEx")>> - <<set $airport++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.airport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology))>> and will increase trade, but will affect security// -<<elseif $airport == 2>> - <<link "Enlarge the airport">> +<<elseif $SecExp.buildings.transportHub.airport == 2>> + <br><br> <<link "Enlarge the airport" "transportHub">> <<run cashX(forceNeg(Math.trunc(15000*$upgradeMultiplierArcology)), "capEx")>> - <<set $airport++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.airport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology))>> and will increase trade, but will affect security// -<<elseif $airport == 3>> - <<link "Further modernize the airport">> +<<elseif $SecExp.buildings.transportHub.airport == 3>> + <br><br> <<link "Further modernize the airport" "transportHub">> <<run cashX(forceNeg(Math.trunc(45000*$upgradeMultiplierArcology)), "capEx")>> - <<set $airport++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.airport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(45000*$upgradeMultiplierArcology))>> and will increase trade, but will affect security// -<<elseif $airport == 4>> - <<link "Further enlarge the airport">> +<<elseif $SecExp.buildings.transportHub.airport == 4>> + <br><br> <<link "Further enlarge the airport" "transportHub">> <<run cashX(forceNeg(Math.trunc(85000*$upgradeMultiplierArcology)), "capEx")>> - <<set $airport++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.airport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(85000*$upgradeMultiplierArcology))>> and will increase trade, but will affect security// <<else>> - The airport is fully upgraded. + <br><br>The airport is fully upgraded. <</if>> -<br> -/* trainyard/dockyard */ -<<if $terrain != "oceanic" && $terrain != "marine">> - <<if $railway == 1>> - <<link "Modernize the railway">> + +<<if $terrain != "oceanic" && $terrain != "marine">> /* trainyard/dockyard */ + <<if $SecExp.buildings.transportHub.surfaceTransport == 1>> + <br> <<link "Modernize the railway" "transportHub">> <<run cashX(forceNeg(Math.trunc(10000*$upgradeMultiplierArcology)), "capEx")>> - <<set $railway++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.surfaceTransport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology))>>, will increase trade and slightly lower arcology's upkeep, but will affect security// - <<elseif $railway == 2>> - <<link "Enlarge the railway">> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 2>> + <br> <<link "Enlarge the railway" "transportHub">> <<run cashX(forceNeg(Math.trunc(25000*$upgradeMultiplierArcology)), "capEx")>> - <<set $railway++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.surfaceTransport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(25000*$upgradeMultiplierArcology))>>, will increase trade and slightly lower arcology's upkeep, but will affect security// - <<elseif $railway == 3>> - <<link "Further modernize and enlarge the railway">> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 3>> + <br> <<link "Further modernize and enlarge the railway" "transportHub">> <<run cashX(forceNeg(Math.trunc(65000*$upgradeMultiplierArcology)), "capEx")>> - <<set $railway++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.surfaceTransport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(65000*$upgradeMultiplierArcology))>>, will increase trade and slightly lower arcology's upkeep, but will affect security// <<else>> - The railway is fully upgraded. + <br>The railway is fully upgraded. <</if>> <<else>> - <<if $docks == 1>> - <<link "Modernize the docks">> + <<if $SecExp.buildings.transportHub.surfaceTransport == 1>> + <br> <<link "Modernize the docks" "transportHub">> <<run cashX(forceNeg(Math.trunc(10000*$upgradeMultiplierArcology)), "capEx")>> - <<set $docks++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.surfaceTransport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology))>>, will increase trade and slightly lower arcology's upkeep, but will affect security// - <<elseif $docks == 2>> - <<link "Enlarge the docks">> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 2>> + <br> <<link "Enlarge the docks" "transportHub">> <<run cashX(forceNeg(Math.trunc(25000*$upgradeMultiplierArcology)), "capEx")>> - <<set $docks++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.surfaceTransport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(25000*$upgradeMultiplierArcology))>>, will increase trade and slightly lower arcology's upkeep, but will affect security// - <<elseif $docks == 3>> - <<link "Further modernize and enlarge the docks">> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 3>> + <br> <<link "Further modernize and enlarge the docks" "transportHub">> <<run cashX(forceNeg(Math.trunc(65000*$upgradeMultiplierArcology)), "capEx")>> - <<set $docks++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.surfaceTransport++>> <</link>> //Will cost <<print cashFormat(Math.trunc(65000*$upgradeMultiplierArcology))>>, will increase trade and slightly lower arcology's upkeep, but will affect security// <<else>> - The docks are fully upgraded. + <br>The docks are fully upgraded. <</if>> <</if>> -<br> -/* security */ -<<if $hubSecurity == 1>> - <<link "Expand and modernize the surveillance system">> + +<<if $SecExp.buildings.transportHub.security == 1>> /* security */ + <br> <<link "Expand and modernize the surveillance system" "transportHub">> <<run cashX(forceNeg(Math.trunc(15000*$upgradeMultiplierArcology)), "capEx")>> - <<set $hubSecurity++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.security++>> <</link>> //Will cost <<print cashFormat(Math.trunc(15000*$upgradeMultiplierArcology))>> and lower the transport hub security modifiers// -<<elseif $hubSecurity == 2>> - <<link "Establish a rapid response team">> +<<elseif $SecExp.buildings.transportHub.security == 2>> + <br> <<link "Establish a rapid response team" "transportHub">> <<run cashX(forceNeg(Math.trunc(35000*$upgradeMultiplierArcology)), "capEx")>> - <<set $hubSecurity++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.security++>> <</link>> //Will cost <<print cashFormat(Math.trunc(35000*$upgradeMultiplierArcology))>> and further lower the transport hub security modifiers// -<<elseif $hubSecurity == 3>> - <<link "Add additional security drones to the structure">> +<<elseif $SecExp.buildings.transportHub.security == 3>> + <br> <<link "Add additional security drones to the structure" "transportHub">> <<run cashX(forceNeg(Math.trunc(55000*$upgradeMultiplierArcology)), "capEx")>> - <<set $hubSecurity++>> - <<goto "transportHub">> + <<set $SecExp.buildings.transportHub.security++>> <</link>> //Will cost <<print cashFormat(Math.trunc(55000*$upgradeMultiplierArcology))>> and further lower the transport hub security modifiers// <<else>> - The hub security is fully upgraded + <br>The hub security is fully upgraded <</if>> - -<br><br> -[[Return this sector to standard markets|Main][cashX(forceNeg(Math.trunc(10000*$upgradeMultiplierArcology)), "capEx"), App.Arcology.cellUpgrade($building, App.Arcology.Cell.Market, "Transport Hub", "Markets"), $transportHub = 0, $hubSecurity = 1]] //Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology))>>// +<br><br>[[Return this sector to standard markets|Main][delete $SecExp.buildings.transportHub, cashX(forceNeg(Math.trunc(10000*$upgradeMultiplierArcology)), "capEx"), App.Arcology.cellUpgrade($building, App.Arcology.Cell.Market, "Transport Hub", "Markets")]] //Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology))>>// \ No newline at end of file diff --git a/src/Mods/SecExp/buildings/weaponsManufacturing.tw b/src/Mods/SecExp/buildings/weaponsManufacturing.tw index ceb9dcb970478d0c5ba899503a0376cfabc73516..97f01210c79a92d7058fd4dd4c85f5c9a31d0205 100644 --- a/src/Mods/SecExp/buildings/weaponsManufacturing.tw +++ b/src/Mods/SecExp/buildings/weaponsManufacturing.tw @@ -1,42 +1,43 @@ :: weaponsManufacturing [nobr] -<<set $nextButton = "Back", $nextLink = "Main", _baseUpgradeTime = 10>> +<<set $nextButton = "Back", $nextLink = "Main", _baseUpgradeTime = App.SecExp.weapManuUpgrade.baseTime()>> This sector of the arcology has been dedicated to weapons manufacturing. These factories supply <<if $militiaUnits.length > 0>> your militia and<</if>> <<if $slaveUnits.length > 0>> your slave soldiers and<</if>> <<if $mercenaries > 0>> your mercenaries and<</if>> many small old world nations as the advanced technology that Free Cities have available is hard to come by otherwise. -<br> -<<if $weapProductivity == 1>> - Production is completely manned by human workers. The complex has close to zero automation. -<<elseif $weapProductivity == 2>> - Production is mostly handled by human workers. A few of the most tiresome tasks are handled by robots. -<<elseif $weapProductivity == 3>> - A good part of production is handled by robots with humans handling the most complex tasks. -<<elseif $weapProductivity == 4>> - Almost all production is handled by robots, with humans acting as support for the machines. +<<if $SecExp.buildings.weapManu.productivity == 1>> + <br>Production is completely manned by human workers. The complex has close to zero automation. +<<elseif $SecExp.buildings.weapManu.productivity == 2>> + <br>Production is mostly handled by human workers. A few of the most tiresome tasks are handled by robots. +<<elseif $SecExp.buildings.weapManu.productivity == 3>> + <br>A good part of production is handled by robots with humans handling the most complex tasks. +<<elseif $SecExp.buildings.weapManu.productivity == 4>> + <br>Almost all production is handled by robots, with humans acting as support for the machines. <<else>> - All production here is handled by robots. The few humans working in the complex occupy themselves exclusively with management and quality assurance. + <br>All production here is handled by robots. The few humans working in the complex occupy themselves exclusively with management and quality assurance. <</if>> -<br> -<<if $weapLab == 1>> - There's a very spartan lab attached to the complex that occupies itself mainly with weapons testing and small adjustments to the manufacturing process. -<<elseif $weapLab == 2>> - There's a lab attached to the complex. It mainly test weapons effectiveness and manufacturing efficiency, but has enough equipment and personnel to develop new technology. +<<if $SecExp.buildings.weapManu.lab == 1>> + <br>There's a very spartan lab attached to the complex that occupies itself mainly with weapons testing and small adjustments to the manufacturing process. +<<elseif $SecExp.buildings.weapManu.lab == 2>> + <br>There's a lab attached to the complex. It mainly test weapons effectiveness and manufacturing efficiency, but has enough equipment and personnel to develop new technology. <<else>> - There's a large lab attached to the complex. The complement of equipment and personnel makes it a great beacon of military science in an otherwise ignorant world. + <br>There's a large lab attached to the complex. The complement of equipment and personnel makes it a great beacon of military science in an otherwise ignorant world. <</if>> -<br> -<<if $weapMenials> 0>>Assigned here are $weapMenials slaves working to produce as much equipment as possible.<<else>>There are no assigned menial slaves here. The spaces is manned exclusively by low rank citizens.<</if>> -You own <<print num($menials)>> free menial slaves. This manufacturing complex can house 500 at most, with <<print 500 - $weapMenials>> free slots. + +<<if $SecExp.buildings.weapManu.menials > 0>> + <br><br>Assigned here are $SecExp.buildings.weapManu.menials slaves working to produce as much equipment as possible. +<<else>> + <br><br>There are no assigned menial slaves here. The spaces is manned exclusively by low rank citizens. +<</if>> +You own <<print num($menials)>> free menial slaves. This manufacturing complex can house 500 at most, with <<print 500 - $SecExp.buildings.weapManu.menials>> free slots. <br> <<set _popCap = menialPopCap()>> <<set _menialPrice = menialSlaveCost()>> <<set _bulkMax = _popCap.value-$menials-$fuckdolls-$menialBioreactors>> <<if $cash > _menialPrice>> <<if _bulkMax > 0 || $menials+$fuckdolls+$menialBioreactors == 0>> - <br> [[Buy|weaponsManufacturing][$menials+=1,$menialSupplyFactor-=1,cashX(forceNeg(_menialPrice), "menialTransfer")]] <<if $cash > (menialSlaveCost(10))*10>> [[(x10)|weaponsManufacturing][$menials+=10,$menialSupplyFactor-=10,cashX(forceNeg((menialSlaveCost(10))*10), "menialTransfer")]] @@ -52,414 +53,167 @@ You own <<print num($menials)>> free menial slaves. This manufacturing complex c <</if>> <</if>> -<<if $weapMenials < 500>> +<<if $SecExp.buildings.weapManu.menials < 500>> <<if $menials >= 1>> - <<link "Transfer a menial slave">> - <<set $menials-->> - <<set $weapMenials++>> - <<goto "weaponsManufacturing">> + <<link "Transfer a menial slave" "weaponsManufacturing">> + <<set $menials--, $SecExp.buildings.weapManu.menials++>> + <</link>> + <</if>> + <<if $menials >= 10 && $SecExp.buildings.weapManu.menials <= 490>> + | + <<link "Transfer 10 menial slaves" "weaponsManufacturing">> + <<set $menials -= 10, $SecExp.buildings.weapManu.menials += 10>> <</link>> <</if>> - <<if $menials >= 10 && $weapMenials <= 490>> + <<if $menials >= 100 && $SecExp.buildings.weapManu.menials <= 400>> | - <<link "Transfer 10 menial slaves">> - <<set $menials -= 10>> - <<set $weapMenials += 10>> - <<goto "weaponsManufacturing">> + <<link "Transfer 100 menial slaves" "weaponsManufacturing">> + <<set $menials -= 100, $SecExp.buildings.weapManu.menials += 100>> <</link>> <</if>> <<if $menials > 0>> | - <<link "Transfer all free menial slaves">> - <<if $menials > 500 - $weapMenials>> - <<set $menials -= 500 - $weapMenials>> - <<set $weapMenials = 500>> + <<link "Transfer all free menial slaves" "weaponsManufacturing">> + <<if $menials > 500 - $SecExp.buildings.weapManu.menials>> + <<set $menials -= 500 - $SecExp.buildings.weapManu.menials>> + <<set $SecExp.buildings.weapManu.menials = 500>> <<else>> - <<set $weapMenials += $menials>> - <<set $menials = 0>> + <<set $SecExp.buildings.weapManu.menials += $menials, $menials = 0>> <</if>> - <<goto "weaponsManufacturing">> - <</link>> - <</if>> - <<if $weapMenials > 0>> - <br> - <<link "Transfer out all menial slaves">> - <<set $menials += $weapMenials>> - <<set $weapMenials = 0>> - <<goto "weaponsManufacturing">> <</link>> <</if>> -<<else>> +<<else>> The complex does not require more workers. - <br> - <<link "Transfer out all menial slaves">> - <<set $menials += $weapMenials>> - <<set $weapMenials = 0>> - <<goto "weaponsManufacturing">> +<</if>> +<<if $SecExp.buildings.weapManu.menials > 0>> + <br> <<link "Transfer out all menial slaves" "weaponsManufacturing">> + <<set $menials += $SecExp.buildings.weapManu.menials, $SecExp.buildings.weapManu.menials = 0>> <</link>> <</if>> -<br> -<<if $weapProductivity < 5>> - <<link "Invest in automating the complex">> - <<run cashX(forceNeg(10000 * $weapProductivity), "capEx")>> - <<set $weapProductivity++>> - <<if $currentUpgrade.time > 0>> - <<set _percentComplete = $currentUpgrade.time / (_baseUpgradeTime / ($weapProductivity - 1))>> - <<set _newTime = Math.ceil(_percentComplete * _baseUpgradeTime / $weapProductivity)>> - <<set $currentUpgrade.time = _newTime>> + +<<if $SecExp.buildings.weapManu.productivity < 5>> + <br> <<link "Invest in automating the complex" "weaponsManufacturing">> + <<run cashX(forceNeg(10000 * $SecExp.buildings.weapManu.productivity), "capEx")>> + <<set $SecExp.buildings.weapManu.productivity++>> + <<if $SecExp.buildings.weapManu.upgrades.current.time > 0>> + <<set _percentComplete = $SecExp.buildings.weapManu.upgrades.current.time / (_baseUpgradeTime / ($SecExp.buildings.weapManu.productivity - 1))>> + <<set _newTime = Math.ceil(_percentComplete * _baseUpgradeTime / $SecExp.buildings.weapManu.productivity)>> + <<set $SecExp.buildings.weapManu.upgrades.current.time = _newTime>> <</if>> - <<goto "weaponsManufacturing">> <</link>> - //Will cost <<print cashFormat(10000 * $weapProductivity)>> and will increase the facility income in addition to speeding up upgrade production.// -<<elseif $weapLab < 3>> - You have fully automated the complex. + //Will cost <<print cashFormat(10000 * $SecExp.buildings.weapManu.productivity)>> and will increase the facility income in addition to speeding up upgrade production.// +<<elseif $SecExp.buildings.weapManu.lab < 3>> + <br>You have fully automated the complex. <</if>> -<br> -<<if $weapLab < 3>> - <<link "Invest in research and development">> - <<run cashX(forceNeg(10000 * $weapLab), "capEx")>> - <<set $weapLab++>> - <<goto "weaponsManufacturing">> +<<if $SecExp.buildings.weapManu.lab < 3>> + <br> <<link "Invest in research and development" "weaponsManufacturing">> + <<run cashX(forceNeg(10000 * $SecExp.buildings.weapManu.lab), "capEx")>> + <<set $SecExp.buildings.weapManu.lab++>> <</link>> - //Will cost <<print cashFormat(10000 * $weapLab)>> and will increase the facility income as well as unlock upgrades for our troops// -<<elseif $weapProductivity < 5>> - You have fully upgraded and funded the R&D department + //Will cost <<print cashFormat(10000 * $SecExp.buildings.weapManu.lab)>> and will increase the facility income as well as unlock upgrades for our troops// +<<elseif $SecExp.buildings.weapManu.productivity < 5>> + <br>You have fully upgraded and funded the R&D department <</if>> -<<if $weapLab >= 3 && $weapProductivity >= 5>> +<<if $SecExp.buildings.weapManu.lab >= 3 && $SecExp.buildings.weapManu.productivity >= 5>> The facility is completely automated and its R&D department is fully upgraded and funded. <</if>> -<br> -<br> -__Markets__: -//You are free to sell to whoever you please, but expect hostile forces of a certain kind to be stronger if we'll ever meet in battle.// -<br> -<<if $sellTo.citizen == 1>> - We are currently selling our weapons to the domestic market of the arcology. - <<link "Forbid">> - <<set $sellTo.citizen = 0>> - <<goto "weaponsManufacturing">> - <</link>> +<br><br>__Markets__: //You are free to sell to whoever you please, but expect hostile forces of a certain kind to be stronger if we'll ever meet in battle.// +<<if $SecExp.buildings.weapManu.sellTo.citizen == 1>> + <br>We are currently selling our weapons to the domestic market of the arcology. + [[Forbid|weaponsManufacturing][$SecExp.buildings.weapManu.sellTo.citizen = 0]] <<else>> - We are not selling our weaponry to our citizens. - <<link "Allow">> - <<set $sellTo.citizen = 1>> - <<goto "weaponsManufacturing">> - <</link>> + <br>We are not selling our weaponry to our citizens. + [[Allow|weaponsManufacturing][$SecExp.buildings.weapManu.sellTo.citizen = 1]] <</if>> -<br> -<<if $sellTo.raiders == 1>> - We are currently selling our weapons to various groups of outlaws, also known as raiders. - <<link "Forbid">> - <<set $sellTo.raiders = 0>> - <<goto "weaponsManufacturing">> - <</link>> +<<if $SecExp.buildings.weapManu.sellTo.raiders == 1>> + <br>We are currently selling our weapons to various groups of outlaws, also known as raiders. + [[Forbid|weaponsManufacturing][$SecExp.buildings.weapManu.sellTo.raiders = 0]] <<else>> - We are not selling our weaponry to raiders. - <<link "Allow">> - <<set $sellTo.raiders = 1>> - <<goto "weaponsManufacturing">> - <</link>> + <br>We are not selling our weaponry to raiders. + [[Allow|weaponsManufacturing][$SecExp.buildings.weapManu.sellTo.raiders = 1]] <</if>> -<br> -<<if $sellTo.oldWorld == 1>> - We are currently selling our weapons to many old world nations. - <<link "Forbid">> - <<set $sellTo.oldWorld = 0>> - <<goto "weaponsManufacturing">> - <</link>> +<<if $SecExp.buildings.weapManu.sellTo.oldWorld == 1>> + <br>We are currently selling our weapons to many old world nations. + [[Forbid|weaponsManufacturing][$SecExp.buildings.weapManu.sellTo.oldWorld = 0]] <<else>> - We are not selling our weaponry to old world nations. - <<link "Allow">> - <<set $sellTo.oldWorld = 1>> - <<goto "weaponsManufacturing">> - <</link>> + <br>We are not selling our weaponry to old world nations. + [[Allow|weaponsManufacturing][$SecExp.buildings.weapManu.sellTo.oldWorld = 1]] <</if>> -<br> -<<if $sellTo.FC == 1>> - We are currently selling our weapons to other Free Cities. - <<link "Forbid">> - <<set $sellTo.FC = 0>> - <<goto "weaponsManufacturing">> - <</link>> +<<if $SecExp.buildings.weapManu.sellTo.FC == 1>> + <br>We are currently selling our weapons to other Free Cities. + [[Forbid|weaponsManufacturing][$SecExp.buildings.weapManu.sellTo.FC = 0]] <<else>> - We are not selling our weaponry to other Free Cities. - <<link "Allow">> - <<set $sellTo.FC = 1>> - <<goto "weaponsManufacturing">> - <</link>> + <br>We are not selling our weaponry to other Free Cities. + [[Allow|weaponsManufacturing][$SecExp.buildings.weapManu.sellTo.FC = 1]] <</if>> -<br><br> -<<set _time = Math.ceil(_baseUpgradeTime / $weapProductivity)>> -Upgrades: -With our current industrial and research capabilities upgrades will be finished in _time weeks. -<<if $currentUpgrade.time <= 0>> +<<set _time = Math.ceil(_baseUpgradeTime / $SecExp.buildings.weapManu.productivity)>> +<br><br>Upgrades: With our current industrial and research capabilities upgrades will be finished in _time weeks. +<<if $SecExp.buildings.weapManu.upgrades.current.time <= 0>> <br>Security Drones: - <<if $weapLab < 3>> + <<if $SecExp.buildings.weapManu.lab < 3>> Upgrade the research facility further to unlock more upgrades for the security drones. - <<elseif $completedUpgrades.includesAll(-1, -2, -3)>> - You have fully upgraded the security drones. <</if>> - <<if !$completedUpgrades.includesAll(-1, -2, -3)>> <br> <</if>> - /* Drones upgrades */ - <<if !$completedUpgrades.includes(-1)>> - <<link "Develop dynamic battle aware AI">> - <<set $currentUpgrade = { - ID: -1, - name: "dynamic battle aware AI", - unit: 0, - type: "attack", - time: _time}>> - <<run cashX(forceNeg(10000*$HackingSkillMultiplier), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(10000*$HackingSkillMultiplier)>> and will increase the base attack value of the security drones.// - <<elseif !$completedUpgrades.includes(-2) && $weapLab >= 2>> - <<link "Develop adaptive armored frames">> - <<set $currentUpgrade = { - ID: -2, - name: "adaptive armored frames", - unit: 0, - type: "defense", - time: _time}>> - <<run cashX(forceNeg(10000), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(10000)>> and will increase the base defense value of the security drones.// - <<elseif !$completedUpgrades.includes(-3) && $weapLab >= 3>> + <<if $SecExp.buildings.weapManu.upgrades.completed.includesAll(-1, -2, -3)>> + You have fully upgraded the security drones. + <<else>> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(-1)>> </p> + <<if $SecExp.buildings.weapManu.lab >= 2>> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(-2)>> </p> + <</if>> + <<if $SecExp.buildings.weapManu.lab >= 3>> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(-3)>> </p> + <</if>> <br> - <<link "Develop advanced synthetic alloys">> - <<set $currentUpgrade = { - ID: -3, - name: "advanced synthetic alloys", - unit: 0, - type: "hp", - time: _time}>> - <<run cashX(forceNeg(30000), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(30000)>> and will increase the base hp value of the security drones.// <</if>> - <<if !$completedUpgrades.includesAll(-1, -2, -3)>> <br> <</if>> - /* human troops upgrades */ <br>Troops: - <<if $SF.Toggle && $SF.Active >= 1 && ($humanUpgrade.attack >= 4 || $humanUpgrade.hp >= 4 || $humanUpgrade.morale >= 40 || $humanUpgrade.defense >= 4)>> + <<if $SF.Toggle && $SF.Active >= 1 && (App.SecExp.getAppliedUpgrades('human').attack >= 4 || App.SecExp.getAppliedUpgrades('human').hp >= 4 || App.SecExp.getAppliedUpgrades('human').morale >= 40 || App.SecExp.getAppliedUpgrades('human').defense >= 4)>> You have fully upgraded your human troops. - <<elseif $humanUpgrade.attack >= 2 || $humanUpgrade.hp >= 2 || $humanUpgrade.morale >= 20 || $humanUpgrade.defense >= 2>> + <<elseif App.SecExp.getAppliedUpgrades('human').attack >= 2 || App.SecExp.getAppliedUpgrades('human').hp >= 2 || App.SecExp.getAppliedUpgrades('human').morale >= 20 || App.SecExp.getAppliedUpgrades('human').defense >= 2>> You have fully upgraded your human troops. - <<if $SF.Toggle && $SF.Active >= 1 && ($humanUpgrade.attack < 4 || $humanUpgrade.hp < 4 || $humanUpgrade.morale < 40 || $humanUpgrade.defense < 4) && (($SecExp.edicts.SFSupportLevel >= 2 && $SF.Squad.Firebase >= 7) || ($SecExp.edicts.SFSupportLevel >= 4 && $SF.Squad.Drugs >= 8) || ($SecExp.edicts.SFSupportLevel >= 5))>> + <<if $SF.Toggle && $SF.Active >= 1 && ($SecExp.edicts.SFSupportLevel >= 2 && $SF.Squad.Firebase >= 7 || $SecExp.edicts.SFSupportLevel >= 4 && $SF.Squad.Drugs >= 8 || $SecExp.edicts.SFSupportLevel >= 5)>> With support from $SF.Lower, however, we may be able to further upgrade our troops. <</if>> - <<elseif $weapLab < 3>> + <<elseif $SecExp.buildings.weapManu.lab < 3>> Upgrade the research facility further to unlock more upgrades for human troops. <</if>> - <<if !$completedUpgrades.includes(0)>> <br> - <<link "Develop magnetic based ballistic weaponry">> - <<set $currentUpgrade = { - ID: 0, - name: "magnetic based ballistic weaponry", - unit: 1, - type: "attack", - time: _time}>> - <<run cashX(forceNeg(30000), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(30000)>> and will increase the base attack value of human troops.// - <br> - <</if>> - <<if !$completedUpgrades.includes(1)>> - <<link "Develop ceramo-metallic alloys">> - <<set $currentUpgrade = { - ID: 1, - name: "ceramo-metallic alloys", - unit: 1, - type: "defense", - time: _time}>> - <<run cashX(forceNeg(30000), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(30000)>> and will increase the base defense value of human troops.// + + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(0)>> </p> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(1)>> </p> + <<if $SecExp.buildings.weapManu.lab >= 2>> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(2)>> </p> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(3)>> </p> <</if>> - <<if !$completedUpgrades.includes(2) && $weapLab >= 2>> - <br> - <<link "Develop rapid action stimulants">> - <<set $currentUpgrade = { - ID: 2, - name: "rapid action stimulants", - unit: 1, - type: "hp", - time: _time}>> - <<run cashX(forceNeg(60000), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(60000)>> and will increase the base hp value of human troops.// - <br> - <</if>> - <<if !$completedUpgrades.includes(3) && $weapLab >= 2>> - <<link "Develop fast response neural stimulant">> - <<set $currentUpgrade = { - ID: 3, - name: "fast response neural stimulant", - unit: 1, - type: "morale", - time: _time}>> - <<run cashX(forceNeg(60000), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(60000)>> and will increase the base morale value of human troops.// - <</if>> - <<if !$completedUpgrades.includes(4) && $weapLab >= 3>> - <br> - <<link "Develop universal cyber enhancements">> - <<set $currentUpgrade = { - ID: 4, - name: "universal cyber enhancements", - unit: 1, - type: "attackAndDefense", - time: _time}>> - <<run cashX(forceNeg(120000*$HackingSkillMultiplier), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(120000*$HackingSkillMultiplier)>> and will increase the base attack and "defense" values of human troops.// - <</if>> - <<if !$completedUpgrades.includes(5) && $weapLab >= 3>> - <br> - <<link "Develop remote neural links">> - <<set $currentUpgrade = { - ID: 5, - name: "remote neural links", - unit: 1, - type: "hpAndMorale", - time: _time}>> - <<run cashX(forceNeg(120000*$HackingSkillMultiplier), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(120000*$HackingSkillMultiplier)>> and will increase the base hp and morale values of human troops.// + <<if $SecExp.buildings.weapManu.lab >= 3>> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(4)>> </p> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(5)>> </p> <</if>> <<if $SF.Toggle && $SF.Active >= 1>> <br> - <<if !$completedUpgrades.includes(6) && $weapLab >= 2 && $SecExp.edicts.SFSupportLevel >= 2 && $SF.Squad.Firebase >= 7>> - <br> - <<link "Develop combined training regimens with $SF.Lower">> - <<set $currentUpgrade = { - ID: 6, - name: "combined training regimens with the special force", - unit: 1, - type: "attackAndDefense", - time: _time}>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, and will increase the base attack and defense values of human troops.// + <<if $SecExp.buildings.weapManu.lab >= 2 && $SecExp.edicts.SFSupportLevel >= 2 && $SF.Squad.Firebase >= 7>> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(6)>> </p> <</if>> - <<if !$completedUpgrades.includes(7) && $weapLab >= 2 && $SecExp.edicts.SFSupportLevel >= 4 && $SF.Squad.Drugs >= 8>> - <br> - <<link "Develop a variant of the stimulant cocktail that $SF.Lower created">> - <<set $currentUpgrade = { - ID: 7, - name: "a variant of the stimulant cocktail that the special force created", - unit: 1, - type: "hpAndMorale", - time: _time}>> - <<run cashX(forceNeg(300000), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(300000)>> and will increase the base morale and hp values of human troops.// + <<if $SecExp.buildings.weapManu.lab >= 2 && $SecExp.edicts.SFSupportLevel >= 4 && $SF.Squad.Drugs >= 8>> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(7)>> </p> <</if>> - <<if !$completedUpgrades.includes(8) && $weapLab >= 3 && $SecExp.edicts.SFSupportLevel >= 5>> - <br> - <<link "Create a mesh network based off the custom network of $SF.Lower">> - <<set $currentUpgrade = { - ID: 8, - name: "a mesh network based off the custom network of the special force", - unit: 1, - type: "all", - time: _time}>> - <<run cashX(forceNeg(1000000*$HackingSkillMultiplier), "capEx")>> - <<goto "weaponsManufacturing">> - <</link>> - <br>//Will take _time weeks, cost <<print cashFormat(1000000*$HackingSkillMultiplier)>> and will increase all base stats of human troops.// + <<if $SecExp.buildings.weapManu.lab >= 3 && $SecExp.edicts.SFSupportLevel >= 5>> + <p> <<includeDOM App.SecExp.weapManuUpgrade.purchase(8)>> </p> <</if>> <</if>> <<else>> + <<set _current = App.SecExp.weapManuUpgrade.current()>> + <br>You are developing _current.dec. + It is for _current.unit. It will enhance their _current.purpose. + Estimated completion time is <<= numberWithPluralOne($SecExp.buildings.weapManu.upgrades.current.time, "week")>>. <br> - You are developing <<print $currentUpgrade.name>>. - It is for <<if $currentUpgrade.unit == 0>> the security drones<<else>> our troops<</if>>. It will enhance their - <<if $currentUpgrade.type == "attack">> - attack power. - <<elseif $currentUpgrade.type == "defense">> - defensive capabilities. - <<elseif $currentUpgrade.type == "hp">> - survivability. - <<elseif $currentUpgrade.type == "morale">> - standing power. - <<elseif $currentUpgrade.type == "attackAndDefense">> - offensive and defensive effectiveness. - <<elseif $currentUpgrade.type == "hpAndMorale">> - morale and survivability. - <<elseif $currentUpgrade.type == "all">> - offensive, defensive effectiveness in addition to morale and survivability. - <</if>> - Estimated completion time is <<print $currentUpgrade.time>> weeks. <</if>> -<<if $completedUpgrades.length > 0>> - <br> + +<<set _completed = $SecExp.buildings.weapManu.upgrades.completed.length>> +<<if _completed > 0>> You have completed the following projects: - <<for _i = 0; _i < $completedUpgrades.length; _i++>> - <<if _i < $completedUpgrades.length - 2>> - <<if $completedUpgrades[_i] == 0>> - magnetic based ballistic weaponry, - <<elseif $completedUpgrades[_i] == 1>> - ceramo-metallic alloys, - <<elseif $completedUpgrades[_i] == 2>> - rapid action stimulants, - <<elseif $completedUpgrades[_i] == 3>> - fast response neural stimulant, - <<elseif $completedUpgrades[_i] == 4>> - universal cyber enhancements, - <<elseif $completedUpgrades[_i] == 5>> - remote neural links, - <<elseif $completedUpgrades[_i] == 6>> - combined training regimens with the special force, - <<elseif $completedUpgrades[_i] == 7>> - a variant of the stimulant cocktail that the special force created, - <<elseif $completedUpgrades[_i] == 8>> - a mesh network based off the custom network of the special force, - <<elseif $completedUpgrades[_i] == -1>> - dynamic battle aware AI, - <<elseif $completedUpgrades[_i] == -2>> - adaptive armored frames, - <<elseif $completedUpgrades[_i] == -3>> - advanced synthetic alloys, - <</if>> - <<else>> - <<if $completedUpgrades[_i] == 0>> - magnetic based ballistic weaponry. - <<elseif $completedUpgrades[_i] == 1>> - ceramo-metallic alloys. - <<elseif $completedUpgrades[_i] == 2>> - rapid action stimulants. - <<elseif $completedUpgrades[_i] == 3>> - fast response neural stimulant. - <<elseif $completedUpgrades[_i] == 4>> - universal cyber enhancements. - <<elseif $completedUpgrades[_i] == 5>> - remote neural links. - <<elseif $completedUpgrades[_i] == 6>> - combined training regimens with the special force. - <<elseif $completedUpgrades[_i] == 7>> - a variant of the stimulant cocktail that the special force created. - <<elseif $completedUpgrades[_i] == 8>> - a mesh network based off the custom network of the special force. - <<elseif $completedUpgrades[_i] == -1>> - dynamic battle aware AI. - <<elseif $completedUpgrades[_i] == -2>> - adaptive armored frames. - <<elseif $completedUpgrades[_i] == -3>> - advanced synthetic alloys. - <</if>> - <</if>> + <<for _i = 0; _i < _completed; _i++>> + <<= App.SecExp.weapManuUpgrade.current($SecExp.buildings.weapManu.upgrades.completed[_i]).dec>><<if _i < _completed - 1>>,<<else>>.<</if>> <</for>> <</if>> -<br> -<br> -[[Return this sector to standard manufacturing|Main][$weapManu = 0, cashX(forceNeg(Math.trunc(10000*$upgradeMultiplierArcology)), "capEx"), App.Arcology.cellUpgrade($building, App.Arcology.Cell.Manufacturing, "Weapon Manufacturing", "Manufacturing")]] //Costs <<print cashFormat(Math.trunc(10000*$upgradeMultiplierArcology))>>// \ No newline at end of file +<br><br> <<set _cost = Math.trunc(10000*$upgradeMultiplierArcology)>> +[[Return this sector to standard manufacturing|Main][delete $SecExp.buildings.weapManu, cashX(-_cost), "capEx"), App.Arcology.cellUpgrade($building, App.Arcology.Cell.Manufacturing, "Weapon Manufacturing", "Manufacturing")]] //Costs <<print cashFormat(_cost)>>// \ No newline at end of file diff --git a/src/Mods/SecExp/edicts.tw b/src/Mods/SecExp/edicts.tw index d2b33f923bdb8b8a9e212b2f57f46da8f12cfa5c..490489b8c1afb9eabd561e3bd4c604658880a75c 100644 --- a/src/Mods/SecExp/edicts.tw +++ b/src/Mods/SecExp/edicts.tw @@ -38,10 +38,11 @@ <br> //Will provide cash each week. The higher the flux of citizens to slaves the higher the income. Will cost a small amount of authority each week.// <</if>> + <<set _secUpgrades = $SecExp.buildings.secHub.upgrades>> <<if $SecExp.edicts.sellData === 1>> <br>''Private Data marketization:'' you are selling private citizens' data to the best bidder. [[Repeal|edicts][$SecExp.edicts.sellData = 0]] - <<elseif $SecExp.edicts.sellData === 0 && ($secUpgrades.nanoCams || $secUpgrades.cyberBots || $secUpgrades.eyeScan || $secUpgrades.cryptoAnalyzer || $crimeUpgrades.autoTrial || $crimeUpgrades.autoArchive || $crimeUpgrades.worldProfiler || $crimeUpgrades.advForensic)>> + <<elseif $SecExp.edicts.sellData === 0 && $SecExp.buildings.secHub && (Object.values(_secUpgrades.security).reduce((a, b) => a + b) > 0 || Object.values(_secUpgrades.crime).reduce((a, b) => a + b) > 0) || Object.values(_secUpgrades.intel).reduce((a, b) => a + b) > 0)>> <br>''Private Data marketization:'' allow the selling of private citizens' data. <<if $SecExp.core.authority >= 1000>> [[Implement|edicts][$SecExp.edicts.sellData = 1, cashX(-5000, "edicts"), $SecExp.core.authority -= 1000]] @@ -66,7 +67,7 @@ <</if>> <</if>> - <<if $transportHub == 1>> + <<if $SecExp.buildings.transportHub>> <<if $SecExp.edicts.tradeLegalAid == 1>> <br>''Legal aid for new businesses:'' New businesses can rely on your help for legal expenses and issues. [[Repeal|edicts][$SecExp.edicts.tradeLegalAid = 0]] @@ -643,4 +644,4 @@ <</if>> <</if>> </div> -</div> \ No newline at end of file +</div> diff --git a/src/Mods/SecExp/js/Unit.js b/src/Mods/SecExp/js/Unit.js index f4aec181e6aa7899e4aa9dd75b7b4c0f21cacfeb..b981a75fe7354c2f2f37cc5d65bcb814399f0241 100644 --- a/src/Mods/SecExp/js/Unit.js +++ b/src/Mods/SecExp/js/Unit.js @@ -121,7 +121,7 @@ App.SecExp.generateUnit = function(type) { /** Display's the deploy menu for the unit. * @param {object} [input] the unit to be checked. - * @param {number} count + * @param {number} [count=0] */ App.SecExp.deployUnitMenu = function(input, count = 0) { let el = document.createElement("div"), options = document.createElement("div"); @@ -369,6 +369,56 @@ App.SecExp.trainingValueToBonusFactor = function(value) { return Math.min(value * 3 / 400, 0.5); }; +/** Gets the bonus values provided for completing weapon manufacturing upgrades. + * @param {string} type - unit type to check. + * @returns {Object} bouns values after checking for completed upgrades. + */ +App.SecExp.getAppliedUpgrades = function(type) { + let hp = 0, morale = 0, def = 0, attack = 0; + if (V.SecExp.buildings.weapManu) { + if (type === 'drone') { + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(-3)) { + hp++; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(-2)) { + def++; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(-1)) { + attack++; + } + } else if (type === 'human') { + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(0)) { + attack++; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(1)) { + def++; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(2)) { + hp++; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(3)) { + morale += 10; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(4)) { + attack++; def++; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(5)) { + hp++; morale += 10; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(6)) { + attack++; def++; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(7)) { + hp++; morale += 10; + } + if (V.SecExp.buildings.weapManu.upgrades.completed.includes(8)) { + attack++; def++; hp++; morale += 10; + } + } + } + return {attack: attack, defense: def, hp: hp, morale: morale}; +} + App.SecExp.getEdictUpgradeVal = (function() { const data = { Militia: new Map([ @@ -419,19 +469,19 @@ App.SecExp.getEdictUpgradeVal = (function() { /** @implements {BaseUnit} */ App.SecExp.BaseMilitiaUnit = class BaseMilitiaUnit { static get attack() { - return 7 + V.humanUpgrade.attack + App.SecExp.getEdictUpgradeVal("Militia", "attack"); + return 7 + App.SecExp.getAppliedUpgrades('human').attack + App.SecExp.getEdictUpgradeVal("Militia", "attack"); } static get defense() { - return 5 + V.humanUpgrade.defense + App.SecExp.getEdictUpgradeVal("Militia", "defense"); + return 5 + App.SecExp.getAppliedUpgrades('human').defense + App.SecExp.getEdictUpgradeVal("Militia", "defense"); } static get morale() { - return 140 + V.humanUpgrade.morale + App.SecExp.getEdictUpgradeVal("Militia", "morale"); + return 140 + App.SecExp.getAppliedUpgrades('human').morale + App.SecExp.getEdictUpgradeVal("Militia", "morale"); } static get hp() { - return 3 + V.humanUpgrade.hp + App.SecExp.getEdictUpgradeVal("Militia", "hp"); + return 3 + App.SecExp.getAppliedUpgrades('human').hp + App.SecExp.getEdictUpgradeVal("Militia", "hp"); } }; @@ -439,49 +489,49 @@ App.SecExp.BaseMilitiaUnit = class BaseMilitiaUnit { /** @implements {BaseUnit} */ App.SecExp.BaseSlaveUnit = class BaseSlaveUnit { static get attack() { - return 8 + V.humanUpgrade.attack + App.SecExp.getEdictUpgradeVal("Slave", "attack"); + return 8 + App.SecExp.getAppliedUpgrades('human').attack + App.SecExp.getEdictUpgradeVal("Slave", "attack"); } static get defense() { - return 3 + V.humanUpgrade.defense + App.SecExp.getEdictUpgradeVal("Slave", "defense"); + return 3 + App.SecExp.getAppliedUpgrades('human').defense + App.SecExp.getEdictUpgradeVal("Slave", "defense"); } static get morale() { - return 110 + V.humanUpgrade.morale + App.SecExp.getEdictUpgradeVal("Slave", "morale"); + return 110 + App.SecExp.getAppliedUpgrades('human').morale + App.SecExp.getEdictUpgradeVal("Slave", "morale"); } static get hp() { - return 3 + V.humanUpgrade.hp + App.SecExp.getEdictUpgradeVal("Slave", "hp"); + return 3 + App.SecExp.getAppliedUpgrades('human').hp + App.SecExp.getEdictUpgradeVal("Slave", "hp"); } }; /** @implements {BaseUnit} */ App.SecExp.BaseMercUnit = class BaseMercUnit { static get attack() { - return 8 + V.humanUpgrade.attack + App.SecExp.getEdictUpgradeVal("Merc", "attack"); + return 8 + App.SecExp.getAppliedUpgrades('human').attack + App.SecExp.getEdictUpgradeVal("Merc", "attack"); } static get defense() { - return 4 + V.humanUpgrade.defense + App.SecExp.getEdictUpgradeVal("Merc", "defense"); + return 4 + App.SecExp.getAppliedUpgrades('human').defense + App.SecExp.getEdictUpgradeVal("Merc", "defense"); } static get morale() { - return 125 + V.humanUpgrade.morale + App.SecExp.getEdictUpgradeVal("Merc", "morale"); + return 125 + App.SecExp.getAppliedUpgrades('human').morale + App.SecExp.getEdictUpgradeVal("Merc", "morale"); } static get hp() { - return 4 + V.humanUpgrade.hp + App.SecExp.getEdictUpgradeVal("Merc", "hp"); + return 4 + App.SecExp.getAppliedUpgrades('human').hp + App.SecExp.getEdictUpgradeVal("Merc", "hp"); } }; /** @implements {BaseUnit} */ App.SecExp.BaseDroneUnit = class BaseDroneUnit { static get attack() { - return 7 + V.droneUpgrades.attack; + return 7 + App.SecExp.getAppliedUpgrades('drone').attack; } static get defense() { - return 3 + V.droneUpgrades.defense; + return 3 + App.SecExp.getAppliedUpgrades('drone').defense; } static get morale() { @@ -489,7 +539,7 @@ App.SecExp.BaseDroneUnit = class BaseDroneUnit { } static get hp() { - return 3 + V.droneUpgrades.hp; + return 3 + App.SecExp.getAppliedUpgrades('drone').hp; } }; @@ -572,19 +622,19 @@ App.SecExp.BaseFreedomFighterUnit = class BaseFreedomFighterUnit { /** @implements {BaseUnit} */ App.SecExp.BaseSpecialForcesUnit = class BaseSpecialForcesUnit { static get attack() { - return 8 + V.humanUpgrade.attack; + return 8 + App.SecExp.getAppliedUpgrades('human').attack; } static get defense() { - return 4 + V.humanUpgrade.defense; + return 4 + App.SecExp.getAppliedUpgrades('human').defense; } static get morale() { - return 140 + V.humanUpgrade.morale; + return 140 + App.SecExp.getAppliedUpgrades('human').morale; } static get hp() { - return 4 + V.humanUpgrade.hp; + return 4 + App.SecExp.getAppliedUpgrades('human').hp; } }; @@ -783,12 +833,12 @@ App.SecExp.EnemyUnit = class SecExpEnemyUnit extends App.SecExp.Unit { get attack() { const equipmentFactor = this._data.equip * App.SecExp.equipMod; - return this._baseUnit.attack * (1 + equipmentFactor) + V.weapManu * V.sellTo.oldWorld; + return this._baseUnit.attack * (1 + equipmentFactor) + V.SecExp.buildings.weapManu ? V.SecExp.buildings.weapManu.sellTo.oldWorld : 0; } get defense() { const equipmentFactor = this._data.equip * App.SecExp.equipMod; - return this._baseUnit.defense * (1 + equipmentFactor) + V.weapManu * V.sellTo.oldWorld; + return this._baseUnit.defense * (1 + equipmentFactor) + V.SecExp.buildings.weapManu ? V.SecExp.buildings.weapManu.sellTo.oldWorld : 0; } get hp() { @@ -806,16 +856,16 @@ App.SecExp.IrregularUnit = class SecExpEnemyUnit extends App.SecExp.Unit { get attack() { const equipmentFactor = this._data.equip * App.SecExp.equipMod; - return (this._baseUnit.attack - V.humanUpgrade.attack) * (1 + equipmentFactor); + return (this._baseUnit.attack - App.SecExp.getAppliedUpgrades('human').attack) * (1 + equipmentFactor); } get defense() { const equipmentFactor = this._data.equip * App.SecExp.equipMod; - return (this._baseUnit.defense - V.humanUpgrade.defense) * (1 + equipmentFactor); + return (this._baseUnit.defense - App.SecExp.getAppliedUpgrades('human').defense) * (1 + equipmentFactor); } get hp() { - return (this._baseUnit.hp - V.humanUpgrade.hp) * this._data.troops; + return (this._baseUnit.hp - App.SecExp.getAppliedUpgrades('human').hp) * this._data.troops; } }; @@ -923,7 +973,7 @@ App.SecExp.describeUnit = (function() { r += `They are consummate veterans, with a wealth of experience and perfectly trained. On the battlefield they are a well oiled war machine capable of facing pretty much anything. `; } - if(input.loyalty < 10) { + if (input.loyalty < 10) { r += `The unit is extremely disloyal. Careful monitoring of their activities and relationships should be implemented. `; } else if (input.loyalty < 33) { r += `Their loyalty is low. Careful monitoring of their activities and relationships is advised. `; @@ -941,7 +991,7 @@ App.SecExp.describeUnit = (function() { if (input.medics > 0) { r += `The unit has a dedicated squad of medics that will follow them in battle. `; } - if(V.SF.Toggle && V.SF.Active >= 1 && input.SF > 0) { + if (V.SF.Toggle && V.SF.Active >= 1 && input.SF > 0) { r += `The unit has "advisors" from ${V.SF.Lower} that will help the squad remain tactically aware and active. `; } } else { @@ -955,7 +1005,7 @@ App.SecExp.describeUnit = (function() { } r += `Loyalty: `; - if(input.loyalty < 10) { + if (input.loyalty < 10) { r += `extremely disloyal. `; } else if (input.loyalty < 33) { r += `low. `; @@ -973,7 +1023,7 @@ App.SecExp.describeUnit = (function() { if (jsDef(input.medics) && input.medics > 0) { r += `Medical squad attached. `; } - if(V.SF.Toggle && V.SF.Active >= 1 && jsDef(input.SF) || input.SF > 0) { + if (V.SF.Toggle && V.SF.Active >= 1 && jsDef(input.SF) || input.SF > 0) { r += `${App.SF.Caps()} "advisors" attached. `; } } diff --git a/src/Mods/SecExp/js/buildingsJS.js b/src/Mods/SecExp/js/buildingsJS.js index 0b6650b04f058adb136337d1e9d8847fcdd34d67..eb0bc92e40eff336c0b8a94a7a5f6baa0527d72f 100644 --- a/src/Mods/SecExp/js/buildingsJS.js +++ b/src/Mods/SecExp/js/buildingsJS.js @@ -1,71 +1,147 @@ -/* -App.SecExp.weapManuUpgrade = function() { - if (!V.currentUpgrade.ID) { - return; - } +App.SecExp.weapManuUpgrade = (function() { + return { + baseTime, + current, + purchase, + }; + + /** Weeks to completion without any modification. + * @returns {number} + */ + function baseTime() { return 10; } + + /** Checks the supplied ID value and assigns values. + * @param {number} [x=null] the optional ID value to use instead of the current upgrades ID. + * @returns {Object} + */ + function current(x = null) { + let o = {unit: "our human troops", ID: x || V.SecExp.buildings.weapManu.upgrades.current.ID}; + switch(o.ID) { + case -3: + Object.assign(o, { + dec: "advanced synthetic alloys", type: "hp", unit: "the security drones", + cost: 10000*V.HackingSkillMultiplier, + }); + break; + case -2: + Object.assign(o, { + dec: "adaptive armored frames", type: "defense", unit: "the security drones", + cost: 10000 + }); + break; + case -1: + Object.assign(o, { + dec: "dynamic battle aware AI", type: "attack", unit: "the security drones", + cost: 30000 + }); + break; + case 0: + Object.assign(o, { + dec: "magnetic based ballistic weaponry", type: "attack", + cost: 30000 + }); + break; + case 1: + Object.assign(o, { + dec: "ceramo-metallic alloys", type: "defense", + cost: 30000 + }); + break; + case 2: + Object.assign(o, { + dec: "rapid action stimulants", type: "hp", + cost: 60000 + }); + break; + case 3: + Object.assign(o, { + dec: "fast response neural stimulant", type: "morale", + cost: 60000 + }); + break; + case 4: + Object.assign(o, { + dec: "universal cyber enhancements", type: "attack and defense", + cost: 120000*V.HackingSkillMultiplier + }); + break; + case 5: + Object.assign(o, { + dec: "remote neural links", type: "hp and morale", + cost: 120000*V.HackingSkillMultiplier + }); + break; + case 6: + Object.assign(o, { + dec: "combined training regimens with the special force", type: "attack and defense", + cost: 0 + }); + break; + case 7: + Object.assign(o, { + dec: `a variant of the stimulant cocktail that the ${V.SF.Lower} created`, type: "hp and morale", + cost: 300000 + }); + break; + case 8: + Object.assign(o, { + dec: "a mesh network based off the custom network of the special force", type: "all", + cost: 1000000*V.HackingSkillMultiplier + }); + break; + } - let name, type, unit = 1, purpose; - switch(V.currentUpgrade.ID) { - case -3: - name = "advanced synthetic alloys"; type = "hp"; unit = 0; - break; - case -2: - name = "adaptive armored frames"; type = "defense"; unit = 0; - break; - case -1: - name = "dynamic battle aware AI"; type = "attack"; unit = 0; - break; - case 0: - name = "magnetic based ballistic weaponry"; type = "attack"; - break; - case 1: - name = "ceramo-metallic alloys"; type = "defense"; - break; - case 2: - name = "rapid action stimulants"; type = "hp"; - break; - case 3: - name = "fast response neural stimulant"; type = "morale"; - break; - case 4: - name = "universal cyber enhancements"; type = "attackAndDefense"; - break; - case 5: - name = "remote neural links"; type = "hpAndMorale"; - break; - case 6: - name = "combined training regimens with the special force"; type = "attackAndDefense"; - break; - case 7: - name = "a variant of the stimulant cocktail that the special force created"; type = "hpAndMorale"; - break; - case 8: - name = "a mesh network based off the custom network of the special force"; type = "all"; - break; + switch(o.type) { + case "hp": + Object.assign(o, {purpose: "survivability"}); break; + case "defense": + Object.assign(o, {purpose: "defensive capabilities"}); break; + case "attack": + Object.assign(o, {purpose: "attack power"}); break; + case "morale": + Object.assign(o, {purpose: "standing power"}); break; + case "attack and defense": + Object.assign(o, {purpose: "offensive and defensive effectiveness."}); break; + case "hp and morale": + Object.assign(o, {purpose: "morale and survivability"}); break; + case "all": + Object.assign(o, {purpose: "offensive,defensive effectiveness in addition to morale and survivability"}); break; + } + return o; } - switch(type) { - case "hp": - purpose = "survivability"; break; - case "defense": - purpose = "defensive capabilities"; break; - case "attack": - purpose = "attack power"; break; - case "morale": - purpose = "standing power"; break; - case "attackAndDefense": - purpose = "offensive and defensive effectiveness."; break; - case "hpAndMorale": - purpose = "morale and survivability"; break; - case "all": - purpose = "offensive,defensive effectiveness in addition to morale and survivability"; break; + /** Prints a line that allows a user to purchase an upgrade. + * @param {number} [x] ID value to use. + * @returns {Node} + */ + function purchase(x) { + let el = document.createElement("div") , options; + if (!V.SecExp.buildings.weapManu.upgrades.completed.includes(x)) { + options = document.createElement("div"); + const item = current(x), time = Math.ceil(baseTime() / V.SecExp.buildings.weapManu.productivity); + el.append(App.UI.DOM.link(`Develop ${item.dec}`, () => { + V.SecExp.buildings.weapManu.upgrades.current = {ID: x, time: time}; + cashX(-item.cost, "capEx"); + }, + [], passage() + )); + options.append(`Will take ${time} weeks`); + if (item.cost > 0) { + options.append(`, cost ${cashFormat(item.cost)}`); + } + options.append(` and will increase `); + if (item.type !== "all") { + options.append(`the base ${item.type} value${item.type.contains("and") ? 's' : ''}`); + } else { + options.append('all base stats'); + } + options.append(` of ${item.unit}.`); + el.append(options); + } + return el; } +})(); - return { - name: name, type: type, unit: unit, purpose: purpose - }; -}; -*/ App.SecExp.propHub = (function() { return { Init:Init, @@ -165,9 +241,8 @@ App.SecExp.barracks = (function() { delete V.SecExp.buildings.barracks.upgrades; } } - })(); -/* + App.SecExp.secHub = (function() { return { Init:Init, @@ -208,6 +283,7 @@ App.SecExp.secHub = (function() { function BC() { if (V.secHQ || (V.SecExp.buildings.secHub && Object.entries(V.SecExp.buildings.secHub).length > 0)){ + V.SecExp.buildings.secHub = V.SecExp.buildings.secHub || {}; V.SecExp.buildings.secHub.menials = V.SecExp.buildings.secHub.menials || V.secMenials || V.secHelots || 0; V.SecExp.buildings.secHub.coldstorage = V.SecExp.buildings.secHub.coldstorage || V.secUpgrades.coldstorage || 0; delete V.secUpgrades.coldstorage; @@ -238,9 +314,8 @@ App.SecExp.secHub = (function() { V.SecExp.buildings.secHub.upgrades.readiness.rapidVehicles = V.SecExp.buildings.secHub.upgrades.readiness.rapidVehicles || 0; } } - })(); - +/* App.SecExp.riotCenter = (function() { return { Init:Init, @@ -286,9 +361,8 @@ App.SecExp.riotCenter = (function() { V.SecExp.buildings.riotCenter.brainImplantProject = V.SecExp.buildings.riotCenter.brainImplantProject || V.brainImplantProject || 0; } } - })(); - +*/ App.SecExp.weapManu = (function() { return { Init:Init, @@ -307,17 +381,6 @@ App.SecExp.weapManu = (function() { FC: 1, }, upgrades: { - drone: { - attack: 0, - defense: 0, - hp: 0, - }, - human: { - attack: 0, - defense: 0, - hp: 0, - morale: 0, - }, completed: [], current: {time: 0} } @@ -328,37 +391,57 @@ App.SecExp.weapManu = (function() { if (V.weapManu || (V.SecExp.buildings.weapManu && Object.entries(V.SecExp.buildings.weapManu).length > 0)) { V.SecExp.buildings.weapManu = V.SecExp.buildings.weapManu || {}; V.SecExp.buildings.weapManu.menials = V.SecExp.buildings.weapManu.menials || V.weapMenials || V.weapHelots || 0; - V.SecExp.buildings.weapManu.productivity = V.SecExp.buildings.weapManu.productivity || V.weapProductivity || 1; V.SecExp.buildings.weapManu.lab = V.SecExp.buildings.weapManu.lab || V.weapLab || 1; - V.SecExp.buildings.weapManu.sellTo = V.SecExp.buildings.weapManu.sellTo || V.sellTo || {}; - V.SecExp.buildings.weapManu.sellTo.citizen = V.SecExp.buildings.weapManu.sellTo.citizen || 1; - V.SecExp.buildings.weapManu.sellTo.raiders = V.SecExp.buildings.weapManu.sellTo.raiders || 1; - V.SecExp.buildings.weapManu.sellTo.oldWorld = V.SecExp.buildings.weapManu.sellTo.oldWorld || 1; - V.SecExp.buildings.weapManu.sellTo.FC = V.SecExp.buildings.weapManu.sellTo.FC || 1; + if (!jsDef(V.SecExp.buildings.weapManu.sellTo.citizen)) { + V.SecExp.buildings.weapManu.sellTo.citizen = 1; + } + if (!jsDef(V.SecExp.buildings.weapManu.sellTo.raiders)) { + V.SecExp.buildings.weapManu.sellTo.raiders = 1; + } + if (!jsDef(V.SecExp.buildings.weapManu.sellTo.oldWorld)) { + V.SecExp.buildings.weapManu.sellTo.oldWorld = 1; + } + if (!jsDef(V.SecExp.buildings.weapManu.sellTo.FC)) { + V.SecExp.buildings.weapManu.sellTo.FC = 1; + } V.SecExp.buildings.weapManu.upgrades = V.SecExp.buildings.weapManu.upgrades || {}; - V.SecExp.buildings.weapManu.upgrades.drone = V.SecExp.buildings.weapManu.upgrades.drone || V.droneUpgrades || {}; - V.SecExp.buildings.weapManu.upgrades.human = V.SecExp.buildings.weapManu.upgrades.human || V.humanUpgrade || {}; - V.SecExp.buildings.weapManu.upgrades.completed = V.SecExp.buildings.weapManu.upgrades.completed || V.completedUpgrades || []; - - V.SecExp.buildings.weapManu.upgrades.drone.attack = V.SecExp.buildings.weapManu.upgrades.drone.attack || 0; - V.SecExp.buildings.weapManu.upgrades.drone.defense = V.SecExp.buildings.weapManu.upgrades.drone.defense || 0; - V.SecExp.buildings.weapManu.upgrades.drone.hp = V.SecExp.buildings.weapManu.upgrades.drone.hp || 0; - - V.SecExp.buildings.weapManu.upgrades.human.attack = V.SecExp.buildings.weapManu.upgrades.human.attack || 0; - V.SecExp.buildings.weapManu.upgrades.human.defense = V.SecExp.buildings.weapManu.upgrades.human.defense || 0; - V.SecExp.buildings.weapManu.upgrades.human.hp = V.SecExp.buildings.weapManu.upgrades.human.hp || 0; - V.SecExp.buildings.weapManu.upgrades.human.morale = V.SecExp.buildings.weapManu.upgrades.human.morale || 0; - + V.SecExp.buildings.weapManu.upgrades.completed = V.SecExp.buildings.weapManu.upgrades.completed || V.completedUpgrades || []; V.SecExp.buildings.weapManu.upgrades.current = V.SecExp.buildings.weapManu.upgrades.current || {time: 0}; if (jsDef(V.currentUpgrade)) { + if (!jsDef(V.currentUpgrade.ID)) { + if (V.currentUpgrade.name === "magnetic based ballistic weaponry") { + V.currentUpgrade.ID = 0; + } else if (V.currentUpgrade.name === "ceramo-metallic alloys") { + V.currentUpgrade.ID = 1; + } else if (V.currentUpgrade.name === "rapid action stimulants") { + V.currentUpgrade.ID = 2; + } else if (V.currentUpgrade.name === "fast response neural stimulant") { + V.currentUpgrade.ID = 3; + } else if (V.currentUpgrade.name === "universal cyber enhancements") { + V.currentUpgrade.ID = 4; + } else if (V.currentUpgrade.name === "remote neural links") { + V.currentUpgrade.ID = 5; + } else if (V.currentUpgrade.name === "combined training regimens with the special force") { + V.currentUpgrade.ID = 6; + } else if (V.currentUpgrade.name === "a variant of the stimulant cocktail that the special force created") { + V.currentUpgrade.ID = 7; + } else if (V.currentUpgrade.name === "a mesh network based off the custom network of the special force") { + V.currentUpgrade.ID = 8; + } else if (V.currentUpgrade.name === "dynamic battle aware AI") { + V.currentUpgrade.ID = -1; + } else if (V.currentUpgrade.name === "adaptive armored frames") { + V.currentUpgrade.ID = -2; + } else if (V.currentUpgrade.name === "advanced synthetic alloys") { + V.currentUpgrade.ID = -3; + } + } V.SecExp.buildings.weapManu.upgrades.current = {ID: V.currentUpgrade.ID, time: V.currentUpgrade.time}; } } } - })(); App.SecExp.transportHub = (function() { @@ -370,13 +453,9 @@ App.SecExp.transportHub = (function() { function Init() { V.SecExp.buildings.transportHub = { airport: 1, - security: 1 + security: 1, + surfaceTransport: 1, }; - if (V.terrain !== "oceanic" && V.terrain !== "marine") { - V.SecExp.buildings.transportHub.railway = 1; - } else { - V.SecExp.buildings.transportHub.docks = 1; - } } function BC() { @@ -384,13 +463,14 @@ App.SecExp.transportHub = (function() { V.SecExp.buildings.transportHub = V.SecExp.buildings.transportHub || {}; V.SecExp.buildings.transportHub.airport = V.SecExp.buildings.transportHub.airport || V.airport || 1; V.SecExp.buildings.transportHub.security = V.SecExp.buildings.transportHub.security || V.hubSecurity || 1; - - if (V.terrain !== "oceanic" && V.terrain !== "marine") { - V.SecExp.buildings.transportHub.railway = V.SecExp.buildings.transportHub.railway || V.railway || 1; - } else { - V.SecExp.buildings.transportHub.docks = V.SecExp.buildings.transportHub.docks || V.docks || 1; + V.SecExp.buildings.transportHub.surfaceTransport = V.SecExp.buildings.transportHub.surfaceTransport || 1; + if (V.releaseID < 1091) { + if (V.terrain !== "oceanic" && V.terrain !== "marine") { + V.SecExp.buildings.transportHub.surfaceTransport = V.railway || 1; + } else { + V.SecExp.buildings.transportHub.surfaceTransport = V.docks || 1; + } } } } - })(); diff --git a/src/Mods/SecExp/js/secExp.js b/src/Mods/SecExp/js/secExp.js index 25a3d310cd57f339adbe56e2a192712163f74031..22c76c9433b19e98d16d12574adbeaab547f3b9a 100644 --- a/src/Mods/SecExp/js/secExp.js +++ b/src/Mods/SecExp/js/secExp.js @@ -246,16 +246,12 @@ App.SecExp.upkeep = (function() { if (V.SecExp.buildings.propHub) { value += base + upgrade * Object.values(V.SecExp.buildings.propHub.upgrades).reduce((a, b) => a + b); } - if (V.secHQ > 0) { - value += base + 20 * V.secMenials; - let buildingUgradePool = []; - buildingUgradePool.push(...Object.values(V.secUpgrades)); - buildingUgradePool.push(...Object.values(V.crimeUpgrades)); - buildingUgradePool.push(...Object.values(V.readinessUpgrades)); - buildingUgradePool.push(...Object.values(V.intelUpgrades)); - for(let i = 0; i < buildingUgradePool.length; i++) { - value += upgrade*buildingUgradePool[i]; - } + if (V.SecExp.buildings.secHub) { + value += base + 20 * V.SecExp.buildings.secHub.menials; + value += upgrade * Object.values(V.SecExp.buildings.secHub.upgrades.security).reduce((a, b) => a + b); + value += upgrade * Object.values(V.SecExp.buildings.secHub.upgrades.crime).reduce((a, b) => a + b); + value += upgrade * Object.values(V.SecExp.buildings.secHub.upgrades.readiness).reduce((a, b) => a + b); + value += upgrade * Object.values(V.SecExp.buildings.secHub.upgrades.intel).reduce((a, b) => a + b); if (V.SecExp.edicts.SFSupportLevel >= 5) { value += 1000; } @@ -385,19 +381,21 @@ App.SecExp.battle = (function() { */ function deploySpeed() { let init = 1; - if(V.readinessUpgrades.pathways > 0) { - init += 1; - } - if(V.readinessUpgrades.rapidVehicles > 0) { - init += 2; - } - if(V.readinessUpgrades.rapidPlatforms > 0) { - init += 2; - } - if(V.readinessUpgrades.earlyWarn > 0) { - init += 2; + if (V.SecExp.buildings.secHub) { + if (V.SecExp.buildings.secHub.upgrades.readiness.pathways > 0) { + init += 1; + } + if (V.SecExp.buildings.secHub.upgrades.readiness.rapidVehicles > 0) { + init += 2; + } + if (V.SecExp.buildings.secHub.upgrades.readiness.rapidPlatforms > 0) { + init += 2; + } + if (V.SecExp.buildings.secHub.upgrades.readiness.earlyWarn > 0) { + init += 2; + } } - if( V.SF.Toggle && V.SF.Active >= 1 && V.sectionInFirebase >= 1) { + if (V.SF.Toggle && V.SF.Active >= 1 && V.sectionInFirebase >= 1) { init += 2; } return init; @@ -466,14 +464,8 @@ App.SecExp.battle = (function() { */ function recon() { let recon = 0; - if (V.intelUpgrades.sensors > 0) { - recon++; - } - if (V.intelUpgrades.signalIntercept > 0) { - recon++; - } - if (V.intelUpgrades.radar > 0) { - recon++; + if (V.SecExp.buildings.secHub) { + recon *= Object.values(V.SecExp.buildings.secHub.upgrades.intel).reduce((a, b) => a + b); } return recon; } @@ -514,94 +506,94 @@ App.SecExp.Check = (function() { function secRestPoint() { let rest = 40; - - if(V.secUpgrades.nanoCams === 1) { - rest += 15; - } - if(V.secUpgrades.cyberBots === 1) { - rest += 15; - } - if(V.secUpgrades.eyeScan === 1) { - rest += 20; - } - if(V.secUpgrades.cryptoAnalyzer === 1) { - rest += 20; + if (V.SecExp.buildings.secHub) { + if (V.SecExp.buildings.secHub.upgrades.security.nanoCams === 1) { + rest += 15; + } + if (V.SecExp.buildings.secHub.upgrades.security.cyberBots === 1) { + rest += 15; + } + if (V.SecExp.buildings.secHub.upgrades.security.eyeScan === 1) { + rest += 20; + } + if (V.SecExp.buildings.secHub.upgrades.security.cryptoAnalyzer === 1) { + rest += 20; + } } - return rest; } function crimeCap() { let cap = 100; - - if(V.crimeUpgrades.autoTrial === 1) { - cap -= 10; - } - if(V.crimeUpgrades.autoArchive === 1) { - cap -= 10; - } - if(V.crimeUpgrades.worldProfiler === 1) { - cap -= 15; - } - if(V.crimeUpgrades.advForensic === 1) { - cap -= 15; + if (V.SecExp.buildings.secHub) { + if (V.SecExp.buildings.secHub.upgrades.crime.autoTrial === 1) { + cap -= 10; + } + if (V.SecExp.buildings.secHub.upgrades.crime.autoArchive === 1) { + cap -= 10; + } + if (V.SecExp.buildings.secHub.upgrades.crime.worldProfiler === 1) { + cap -= 15; + } + if (V.SecExp.buildings.secHub.upgrades.crime.advForensic === 1) { + cap -= 15; + } } - return cap; } function reqMenials() { let Req = 20; - - if(V.secUpgrades.nanoCams === 1) { - Req += 5; - } - if(V.secUpgrades.cyberBots === 1) { - Req += 5; - } - if(V.secUpgrades.eyeScan === 1) { - Req += 10; - } - if(V.secUpgrades.cryptoAnalyzer === 1) { - Req += 10; - } - if(V.crimeUpgrades.autoTrial === 1) { - Req += 5; - } - if(V.crimeUpgrades.autoArchive === 1) { - Req += 5; - } - if(V.crimeUpgrades.worldProfiler === 1) { - Req += 10; - } - if(V.crimeUpgrades.advForensic === 1) { - Req += 10; - } - if(V.intelUpgrades.sensors === 1) { - Req += 5; - } - if(V.intelUpgrades.signalIntercept === 1) { - Req += 5; - } - if(V.intelUpgrades.radar === 1) { - Req += 10; - } - if(V.readinessUpgrades.rapidVehicles === 1) { - Req += 5; - } - if(V.readinessUpgrades.rapidPlatforms === 1) { - Req += 10; - } - if(V.readinessUpgrades.earlyWarn === 1) { - Req += 10; - } - if(V.SecExp.edicts.SFSupportLevel >= 1) { - Req -= 5 * V.SecExp.edicts.SFSupportLevel; - } - if(V.secUpgrades.coldstorage >= 1) { - Req -= 10 * V.secUpgrades.coldstorage; + if (V.SecExp.buildings.secHub) { + if (V.SecExp.buildings.secHub.upgrades.security.nanoCams === 1) { + Req += 5; + } + if (V.SecExp.buildings.secHub.upgrades.security.cyberBots === 1) { + Req += 5; + } + if (V.SecExp.buildings.secHub.upgrades.security.eyeScan === 1) { + Req += 10; + } + if (V.SecExp.buildings.secHub.upgrades.security.cryptoAnalyzer === 1) { + Req += 10; + } + if (V.SecExp.buildings.secHub.upgrades.crime.autoTrial === 1) { + Req += 5; + } + if (V.SecExp.buildings.secHub.upgrades.crime.autoArchive === 1) { + Req += 5; + } + if (V.SecExp.buildings.secHub.upgrades.crime.worldProfiler === 1) { + Req += 10; + } + if (V.SecExp.buildings.secHub.upgrades.crime.advForensic === 1) { + Req += 10; + } + if (V.SecExp.buildings.secHub.upgrades.intel.sensors === 1) { + Req += 5; + } + if (V.SecExp.buildings.secHub.upgrades.intel.signalIntercept === 1) { + Req += 5; + } + if (V.SecExp.buildings.secHub.upgrades.intel.radar === 1) { + Req += 10; + } + if (V.SecExp.buildings.secHub.upgrades.readiness.rapidVehicles === 1) { + Req += 5; + } + if (V.SecExp.buildings.secHub.upgrades.readiness.rapidPlatforms === 1) { + Req += 10; + } + if (V.SecExp.buildings.secHub.upgrades.readiness.earlyWarn === 1) { + Req += 10; + } + if (V.SecExp.edicts.SFSupportLevel >= 1) { + Req -= 5 * V.SecExp.edicts.SFSupportLevel; + } + if (V.SecExp.buildings.secHub.coldstorage >= 1) { + Req -= 10 * V.SecExp.buildings.secHub.coldstorage; + } } - return Req; } })(); diff --git a/src/Mods/SecExp/js/secExpBC.js b/src/Mods/SecExp/js/secExpBC.js index 8884e43a3ef66354761d58724b8b9c021c3ff30d..21b422b021426b942b9418beed63639faf4db910 100644 --- a/src/Mods/SecExp/js/secExpBC.js +++ b/src/Mods/SecExp/js/secExpBC.js @@ -289,11 +289,11 @@ App.SecExp.generalBC = function() { V.SecExp.buildings = V.SecExp.buildings || {}; App.SecExp.propHub.BC(); App.SecExp.barracks.BC(); - /* App.SecExp.secHub.BC(); - App.SecExp.riotCenter.BC(); + App.SecExp.transportHub.BC(); + // App.SecExp.riotCenter.BC(); App.SecExp.weapManu.BC(); - */ + V.SecExp.proclamation = V.SecExp.proclamation || {}; V.SecExp.proclamation.cooldown = V.SecExp.proclamation.cooldown || V.proclamationsCooldown || 0; V.SecExp.proclamation.currency = V.SecExp.proclamation.currency || V.proclamationCurrency || ""; diff --git a/src/Mods/SecExp/secExpSmilingMan.tw b/src/Mods/SecExp/secExpSmilingMan.tw index a97eacf2e3158fa8a2d1336c5fce957361097097..8cf3fa49afb92faf7ba0d0fce845dd62d1b5fac4 100644 --- a/src/Mods/SecExp/secExpSmilingMan.tw +++ b/src/Mods/SecExp/secExpSmilingMan.tw @@ -160,7 +160,7 @@ </p> <</if>> <p> - <<if $secUpgrades.cyberBots == 1>> + <<if $SecExp.buildings.secHub.upgrades.security.cyberBots == 1>> <<set _lostCash -= Math.min(30000, _lostCash)>> The additional cyber defenses acquired and running in the security HQ <<if _lostCash < 200000>>further<</if>> limit the damage. <</if>> @@ -262,9 +262,9 @@ Vast amount of data relative to the ownership of the arcology is lost. You would've run the risk of losing ownership of one of the sectors, but fortunately your authority is so high your citizens do not dare question your claims even in the absence of a valid legal case. <</if>> <</if>> - <<if $secUpgrades.coldstorage > 3>> + <<if $SecExp.buildings.secHub.coldstorage > 3>> Your cold storage facility has ensured that the Smiling Man's destruction of the primary archives was unable to damage the security of your arcology. - <<elseif $secUpgrades.coldstorage == 0>> + <<elseif $SecExp.buildings.secHub.coldstorage == 0>> Your security department sees its archives butchered by the Smiling Man. Almost all data on criminals, citizens, and operations are lost. The <span class="red">security of the arcology is greatly reduced.</span> Criminals, on the other hand, with their past erased, cannot wait to join this new world, so <span class="red">crime will inevitably increase.</span> <<set $SecExp.core.security = Math.clamp($SecExp.core.security * 0.2,0,100)>> <<set $SecExp.core.crimeLow = Math.clamp($SecExp.core.crimeLow * 1.5, 20,100)>> diff --git a/src/Mods/SecExp/securityReport.tw b/src/Mods/SecExp/securityReport.tw index 136a163d014c59a21afa74c3687d56eddf159982..aa7c125cd4644e28ba8e57dfce88a3758c7950d3 100644 --- a/src/Mods/SecExp/securityReport.tw +++ b/src/Mods/SecExp/securityReport.tw @@ -17,23 +17,18 @@ The @@.red;easily manageable economic and logistical challenges@@ of attacking an $terrain arcology ensure that your security force(s) do not <</if>> have the luxury of focusing exclusively on internal matters.<br> -<<if $secMenials > 0>> - <<print num($secMenials)>> slaves work to improve the security of your arcology, - <<if $mercenaries >= 1 && $arcologyUpgrade.drones == 1>> - while your mercenaries and security drones tirelessly patrol the streets to keep them safe. - <<elseif $arcologyUpgrade.drones == 1>> - while your security drones tirelessly patrol the arcology to keep it safe. - <<else>> - while your loyal subordinates try to keep the arcology safe to the best of their abilities. - <</if>> +<<if (def $SecExp.buildings.secHub) && ($SecExp.buildings.secHub.menials > 0)>> + <<print num($SecExp.buildings.secHub.menials)>> slaves work to improve the security of your arcology, while your <<else>> - <<if $mercenaries >= 1 && $arcologyUpgrade.drones == 1>> - Your mercenaries and security drones tirelessly patrol the streets to keep them safe. - <<elseif $arcologyUpgrade.drones == 1>> - Your security drones tirelessly patrol the arcology to keep it safe. - <<else>> - Your loyal subordinates try to keep the arcology safe to the best of their abilities. - <</if>> + Your +<</if>> + +<<if $mercenaries >= 1 && $arcologyUpgrade.drones == 1>> + mercenaries and security drones tirelessly patrol the streets to keep them safe. +<<elseif $arcologyUpgrade.drones == 1>> + security drones tirelessly patrol the arcology to keep it safe. +<<else>> + loyal subordinates try to keep the arcology safe to the best of their abilities. <</if>> /* security modifiers */ @@ -158,14 +153,10 @@ <<set _secGrowth += 0.5>> <</if>> -<<if $transportHub == 1>> - <<if $terrain != "oceanic" && $terrain != "marine">> - <<set _secGrowth -= ($airport + $railway - $hubSecurity * 3) / 2>> - <<else>> - <<set _secGrowth -= ($airport + $docks - $hubSecurity * 3) / 2>> - <</if>> +<<if $SecExp.buildings.transportHub>> + <<set _secGrowth -= ($SecExp.buildings.transportHub.airport + $SecExp.buildings.transportHub.surfaceTransport - $SecExp.buildings.transportHub.security * 3) / 2>> The transport hub, for all its usefulness, is a hotspot of malicious - <<if $airport + $docks > $hubSecurity * 3>> + <<if $SecExp.buildings.transportHub.airport + $SecExp.buildings.transportHub.surfaceTransport > $SecExp.buildings.transportHub.security * 3>> activity and hub security forces are not sufficient to keep up with all threats. <<else>> activity, but the hub security forces are up to the task. @@ -201,11 +192,11 @@ <</if>> /* resting point */ -<<set _secRest = App.SecExp.Check.secRestPoint() * (Math.clamp($secMenials,0,App.SecExp.Check.reqMenials()) / App.SecExp.Check.reqMenials())>> +<<set _secRest = App.SecExp.Check.secRestPoint() * $SecExp.buildings.secHub ? (Math.clamp($SecExp.buildings.secHub.menials,0,App.SecExp.Check.reqMenials()) / App.SecExp.Check.reqMenials()) : 1>> <<if _secRest < 0>> <<set _secRest = 20>> <</if>> -<<if _secRest < App.SecExp.Check.reqMenials() && $secHQ == 1>> +<<if _secRest < App.SecExp.Check.reqMenials() && $SecExp.buildings.secHub>> The limited staff assigned to the HQ hampered the improvements to security achieved this week. <<elseif _secRest < App.SecExp.Check.reqMenials()>> The limited infrastructure available slowly erodes away the security level of the arcology. @@ -327,13 +318,13 @@ Due to the deterioration of the old world countries, organized crime focuses mor <</if>> /* crime cap */ -<<set _crimeCap = Math.trunc(Math.clamp(App.SecExp.Check.crimeCap() + (App.SecExp.Check.crimeCap() - App.SecExp.Check.crimeCap() * ($secMenials / App.SecExp.Check.reqMenials())),0,100))>> -<<if _crimeCap > App.SecExp.Check.crimeCap() && $secHQ == 1>> +<<set _crimeCap = Math.trunc(Math.clamp(App.SecExp.Check.crimeCap() + (App.SecExp.Check.crimeCap() - App.SecExp.Check.crimeCap() * $SecExp.buildings.secHub ? ($SecExp.buildings.secHub.menials / App.SecExp.Check.reqMenials()) : 0),0,100))>> +<<if _crimeCap > App.SecExp.Check.crimeCap() && $SecExp.buildings.secHub>> The limited staff assigned to the HQ allows more space for criminals to act. <</if>> <<if $SecExp.core.authority > 12000>> - <<if $secUpgrades.coldstorage < 6>> - <<if $secUpgrades.coldstorage === 0>>Adding a facility<<else>>Improving the cold storage facility attached<</if>> to the SecurityHQ should allow the staff to be more efficient in dealing with crime. + <<if $SecExp.buildings.secHub.coldstorage < 6>> + <<if $SecExp.buildings.secHub.coldstorage === 0>>Adding a facility<<else>>Improving the cold storage facility attached<</if>> to the SecurityHQ should allow the staff to be more efficient in dealing with crime. <<else>> The cold storage facility attached to SecurityHQ allows the staff to be more efficient in dealing with crime. <</if>> @@ -519,74 +510,21 @@ Due to the deterioration of the old world countries, organized crime focuses mor <</if>> <</if>> -<<if $currentUpgrade.time > 0>> - <br><br>In the research lab, <<print $currentUpgrade.name>> - <<switch $currentUpgrade.name>> +<<if $SecExp.buildings.weapManu && $SecExp.buildings.weapManu.upgrades.current.time > 0>> + <<set _current = App.SecExp.weapManuUpgrade.current(), $SecExp.buildings.weapManu.upgrades.current.time-->> + <br>In the research lab, _current.dec + <<switch _current.dec>> <<case "adaptive armored frames" "advanced synthetic alloys" "ceramo-metallic alloys" "rapid action stimulants" "universal cyber enhancements" "remote neural links" "combined training regimens with the special force">> are <<default>> is <</switch>> - being developed, with the objective to enhance - <<if $currentUpgrade.type == "attack">> - attack power - <<elseif $currentUpgrade.type == "defense">> - defense capabilities - <<elseif $currentUpgrade.type == "hp">> - survivability - <<elseif $currentUpgrade.type == "morale">> - standing power - <<elseif $currentUpgrade.type == "attackAndDefense">> - offensive and defensive effectiveness - <<elseif $currentUpgrade.type == "hpAndMorale">> - morale and survivability - <<elseif $currentUpgrade.type == "all">> - offensive,defensive effectiveness in addition to morale and survivability - <</if>> - for <<if $currentUpgrade.unit == 0>> the security drones<<else>> our human troops<</if>>. - - <<set $currentUpgrade.time-->> - <<if $currentUpgrade.time <= 0>> - Reports indicate it is ready for deployment and will be issued to - <<if $currentUpgrade.unit == 0>> - the security drones - <<if $currentUpgrade.type == "attack">> - <<set $droneUpgrades.attack++>> - <<elseif $currentUpgrade.type == "defense">> - <<set $droneUpgrades.defense++>> - <<elseif $currentUpgrade.type == "hp">> - <<set $droneUpgrades.hp++>> - <</if>> - <<else>> - all human troops - <<if $currentUpgrade.type == "attack">> - <<set $humanUpgrade.attack++>> - <<elseif $currentUpgrade.type == "defense">> - <<set $humanUpgrade.defense++>> - <<elseif $currentUpgrade.type == "hp">> - <<set $humanUpgrade.hp++>> - <<elseif $currentUpgrade.type == "morale">> - <<set $humanUpgrade.morale += 10>> - <<elseif $currentUpgrade.type == "attackAndDefense">> - <<set $humanUpgrade.attack++>> - <<set $humanUpgrade.defense++>> - <<elseif $currentUpgrade.type == "hpAndMorale">> - <<set $humanUpgrade.hp++>> - <<set $humanUpgrade.morale += 10>> - <<elseif $currentUpgrade.type == "all">> - <<set $humanUpgrade.attack++>> - <<set $humanUpgrade.defense++>> - <<set $humanUpgrade.hp++>> - <<set $humanUpgrade.morale += 10>> - <</if>> - <</if>> - <<set $currentUpgrade.name = " ">> - <<set $currentUpgrade.type = " ">> - <<set $currentUpgrade.unit = -1>> - <<set $currentUpgrade.time = 0>> - in the following days. - <<set $completedUpgrades.push($currentUpgrade.ID)>> + being developed with the aim of enhancing _current.unit' _current.purpose. + <<if $SecExp.buildings.weapManu.upgrades.current.time <= 0>> + Reports indicate it is ready for deployment and will be issued in the following days. + <<set $SecExp.buildings.weapManu.upgrades.completed.push(_current.ID)>> + <<set $SecExp.buildings.weapManu.upgrades.current = {time: 0}>> <<else>> - It will be finished in <<= numberWithPluralOne($currentUpgrade.time, "week")>>. + It will be finished in <<= numberWithPluralOne($SecExp.buildings.weapManu.upgrades.current.time, "week")>>. <</if>> -<</if>> +<</if>> \ No newline at end of file diff --git a/src/Mods/SecExp/tradeReport.tw b/src/Mods/SecExp/tradeReport.tw index fbea6a04a071f18644dc8de2967c4f97bf1507ce..9ae708d0bec6ca5b595b76aeb05b9b244be63744 100644 --- a/src/Mods/SecExp/tradeReport.tw +++ b/src/Mods/SecExp/tradeReport.tw @@ -72,21 +72,21 @@ <<set _tradeChange -= 1>> <</if>> -<<if $weapManu == 1>> +<<if $SecExp.buildings.weapManu>> The weapons manufacturing facility of the arcology attracts a significant amount of trade. - <<set _tradeChange += 0.5 * ($weapProductivity + $weapLab)>> + <<set _tradeChange += 0.5 * ($SecExp.buildings.weapManu.productivity + $SecExp.buildings.weapManu.lab)>> <</if>> -<<if $transportHub == 1>> - <<if $airport == 1>> +<<if $SecExp.buildings.transportHub>> + <<if $SecExp.buildings.transportHub.airport == 1>> The airport, while small, helps facilitate the commercial development of the arcology. <<set _tradeChange += 1>> - <<elseif $airport == 2>> + <<elseif $SecExp.buildings.transportHub.airport == 2>> The airport, while fairly small, helps facilitate the commercial development of the arcology. <<set _tradeChange += 1.5>> - <<elseif $airport == 3>> + <<elseif $SecExp.buildings.transportHub.airport == 3>> The airport helps facilitate the commercial development of the arcology. <<set _tradeChange += 2>> - <<elseif $airport == 4>> + <<elseif $SecExp.buildings.transportHub.airport == 4>> The airport is a great boon to the commercial development of the arcology. <<set _tradeChange += 2.5>> <<else>> @@ -95,12 +95,12 @@ <</if>> <<if $terrain != "oceanic" && $terrain != "marine">> - <<if $railway == 1>> + <<if $SecExp.buildings.transportHub.surfaceTransport == 1>> The railway network's age and limited extension limit commercial activity. - <<elseif $railway == 2>> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 2>> The railway network is a great help to the commercial development of the arcology, but its limited extension hampers its potential. <<set _tradeChange += 1>> - <<elseif $railway == 3>> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 3>> The railway network is a great help to the commercial development of the arcology. <<set _tradeChange += 1.5>> <<else>> @@ -108,12 +108,12 @@ <<set _tradeChange += 2>> <</if>> <<else>> - <<if $docks == 1>> + <<if $SecExp.buildings.transportHub.surfaceTransport == 1>> The docks' age and limited size limit commercial activity. - <<elseif $docks == 2>> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 2>> The docks are a great help to the commercial development of the arcology, but their limited size hampers its potential. <<set _tradeChange += 1>> - <<elseif $docks == 3>> + <<elseif $SecExp.buildings.transportHub.surfaceTransport == 3>> The docks are a great help to the commercial development of the arcology. <<set _tradeChange += 1.5>> <<else>> @@ -153,4 +153,4 @@ <<set _AWeekGrowth += 4.5>> <</if>> -<<set $SecExp.core.trade = Math.clamp($SecExp.core.trade + _tradeChange,0,100)>> \ No newline at end of file +<<set $SecExp.core.trade = Math.clamp($SecExp.core.trade + _tradeChange,0,100)>> diff --git a/src/Mods/SecExp/widgets/miscSecExpWidgets.tw b/src/Mods/SecExp/widgets/miscSecExpWidgets.tw index f2e993457f03834f477748497bd40754410bd13d..b79afeb83c3664d5353cf0e4de90240fe18acfed 100644 --- a/src/Mods/SecExp/widgets/miscSecExpWidgets.tw +++ b/src/Mods/SecExp/widgets/miscSecExpWidgets.tw @@ -16,8 +16,7 @@ <</widget>> <<widget "replenishAllUnits">> - <<set _hasLossesBots = 0, _hasLossesM = 0>> - <<set _hasLossesS = 0, _hasLossesMe = 0>> + <<set _hasLossesBots = 0, _hasLossesM = 0, _hasLossesS = 0, _hasLossesMe = 0>> <<if $secBots.troops < $secBots.maxTroops && $cash >= 500>> <<set _hasLossesBots = 1>> @@ -105,15 +104,8 @@ <</for>> <</if>> - <<if $slaveRebellion == 1 || $citizenRebellion == 1>> - <<goto "rebellionOptions">> - <<elseif $attackThisWeek == 1>> - <<goto "attackOptions">> - <<else>> - <<goto "secBarracks">> - <</if>> - + <<= SugarCube.Engine.play(passage())>> <</link>> //Will replenish units as long as requirements are met.//<br> <</if>> -<</widget>> +<</widget>> \ No newline at end of file diff --git a/src/arcologyBuilding/manufacturing.js b/src/arcologyBuilding/manufacturing.js index 20a901b6a74d1fda7e4fc6412e328f0c942731ef..5833c14e3b14504f64e2467e62adaa0d04f07406 100644 --- a/src/arcologyBuilding/manufacturing.js +++ b/src/arcologyBuilding/manufacturing.js @@ -220,16 +220,14 @@ App.Arcology.Cell.Manufacturing = class extends App.Arcology.Cell.BaseCell { } } - if (V.secExpEnabled > 0) { - if (V.weapManu !== 1) { - fragment.append(thisCell._makeUpgrade( - "Convert this sector to weapons manufacturing", - () => { - V.weapManu = 1; - thisCell.type = "Weapon Manufacturing"; - }, cost, "but will provide a weekly income and will unlock upgrades for our troops" - )); - } + if (V.secExpEnabled > 0 && !V.SecExp.buildings.weapManu) { + fragment.append(thisCell._makeUpgrade( + "Convert this sector to weapons manufacturing", + () => { + App.SecExp.weapManu.Init(); + thisCell.type = "Weapon Manufacturing"; + }, cost, "but will provide a weekly income and will unlock upgrades for our troops" + )); } if (thisCell.type !== "Pens") { diff --git a/src/arcologyBuilding/markets.js b/src/arcologyBuilding/markets.js index 05160b6a812f53ed5501a7cfe7de8c234cf6685e..b837a0e70cd2e40c8c46df065a40d9e70efd736e 100644 --- a/src/arcologyBuilding/markets.js +++ b/src/arcologyBuilding/markets.js @@ -99,15 +99,12 @@ App.Arcology.Cell.Market = class extends App.Arcology.Cell.BaseCell { )); } - if (V.secExpEnabled > 0 && V.transportHub === 0) { + if (V.secExpEnabled > 0 && !V.SecExp.buildings.transportHub) { fragment.append(this._makeUpgrade( "Centralize and modernize the transport hub", () => { this.type = "Transport Hub"; - V.transportHub = 1; - V.docks = 1; - V.railway = 1; - V.airport = 1; + App.SecExp.transportHub.Init(); }, cost )); } diff --git a/src/descriptions/arcologyDescription.js b/src/descriptions/arcologyDescription.js index eea88baa74fe895a9d512dea5424766f3b11250c..e4bc2db212d67a476f74060b938aff3a38846c0c 100644 --- a/src/descriptions/arcologyDescription.js +++ b/src/descriptions/arcologyDescription.js @@ -455,19 +455,19 @@ App.Desc.playerArcology = function(lastElement) { if (V.SecExp.buildings.propHub) { buffer.push(`A small street hides a surprisingly inconspicuous building, whose task is to manage your public image, protection and population control.`); } - if (V.secHQ === 1) { + if (V.SecExp.buildings.secHub) { buffer.push(`In a secure corner of the penthouse, the Security HQ silently works to build a safe and prosperous arcology.`); } if (V.SecExp.buildings.barracks) { buffer.push(`At the center of the structure the barracks can be found filling the halls with the noise of ballistic weapons and training troops.`); } - if (V.weapManu === 1) { + if (V.SecExp.buildings.weapManu) { buffer.push(`Down in the lower levels of the arcology the weapons manufacturing facility dominates the environment; there, armaments of all kind are produced and shipped away.`); } if (V.riotCenter === 1) { buffer.push(`Near the penthouse the riot control center can be found. Here dissidents and dangerous political forces of ${A.name} are carefully monitored and managed.`); } - if (V.transportHub === 1) { + if (V.SecExp.buildings.transportHub) { buffer.push(`The transport hub, in the commercial section of the arcology, deals with new arrivals to ${A.name} via ${V.terrain === "oceanic" || V.terrain === "marine" ? "sea" : "land"} in addition to air.`); } return buffer.join(" "); diff --git a/src/endWeek/saDrugs.js b/src/endWeek/saDrugs.js index f6f831799f2034a434d5000d6fb6d82e1e483333..60b39ae21201b5fe0f20e2287e0e68b23ea06329 100644 --- a/src/endWeek/saDrugs.js +++ b/src/endWeek/saDrugs.js @@ -778,7 +778,7 @@ App.SlaveAssignment.drugs = (function() { case "growth stimulants": slave.chem += 2; growth = 1; - r += `${He} receives frequent <span class="lime"> injections of growth stimulants.</span>`; + r += `${He} receives frequent <span class="lime">injections of growth stimulants.</span>`; // Hormones if (slave.hormones === 2 || slave.hormones === -2) { growth--; diff --git a/src/endWeek/saGuardYou.js b/src/endWeek/saGuardYou.js index 41040672cef920539ae2fadd5a3ce2b78f159423..8de6917f25c89bd7c7032fed8be16bc73705880c 100644 --- a/src/endWeek/saGuardYou.js +++ b/src/endWeek/saGuardYou.js @@ -239,7 +239,7 @@ App.SlaveAssignment.guardYou = (function() { * */ function jobEffects(slave) { - r.push(`Being continually trusted with your life <span class="hotpink"> increases ${his} devotion to you</span> and encourages ${him} to <span class="mediumaquamarine"> trust you in turn.</span>`); + r.push(`Being continually trusted with your life <span class="hotpink">increases ${his} devotion to you</span> and encourages ${him} to <span class="mediumaquamarine">trust you in turn.</span>`); slave.devotion += 2; slave.trust += 4; diff --git a/src/endWeek/saServeYourOtherSlaves.js b/src/endWeek/saServeYourOtherSlaves.js index fcfc84116405ad309d5008f0e78782902b2002d1..f228f2668f94962878dd525764aad3903e46dcaa 100644 --- a/src/endWeek/saServeYourOtherSlaves.js +++ b/src/endWeek/saServeYourOtherSlaves.js @@ -1433,7 +1433,7 @@ App.SlaveAssignment.serveYourOtherSlaves = (function() { if (slave.fetishKnown) { r.push(`Having all the other slaves see ${him} in such a humiliating role really satisfies ${subName}.`); } else { - r.push(`${He} seems to enjoy ${his} humiliating role; ${he} <span class="lightcoral"> gets off to being degraded.</span>`); + r.push(`${He} seems to enjoy ${his} humiliating role; ${he} <span class="lightcoral">gets off to being degraded.</span>`); slave.fetishKnown = 1; } subSlaveLikedFetish = 1; @@ -1616,7 +1616,7 @@ App.SlaveAssignment.serveYourOtherSlaves = (function() { if (slave.fetishKnown) { r.push(`Having all the other slaves see ${him} in such a humiliating role really satisfies ${subName}.`); } else { - r.push(`${He} seems to enjoy ${his} humiliating role; ${he} <span class="lightcoral"> gets off to being degraded.</span>`); + r.push(`${He} seems to enjoy ${his} humiliating role; ${he} <span class="lightcoral">gets off to being degraded.</span>`); slave.fetishKnown = 1; } slave.need = 0; diff --git a/src/events/RESS/lazyEvening.js b/src/events/RESS/lazyEvening.js index 387bbfe9d44a0e1369ece5dc5c562edef6de02e6..49e046dca051f738dc75f450afbca905fbde290b 100644 --- a/src/events/RESS/lazyEvening.js +++ b/src/events/RESS/lazyEvening.js @@ -240,7 +240,7 @@ App.Events.RESSLazyEvening = class RESSLazyEvening extends App.Events.BaseEvent let t = []; t.push(`Though there is no shortage of torments you inflict during the course of your day to day life as an arcology owner, there is something refreshing about torturing a slave out of idle boredom rather than corrective disciple or sexual domination. Your night is filled with ${eventSlave.voice === 0 ? "the horrible rasping that a mute throat substitutes for cries of agony" : "echoing shrieks of anguish"}, though every vocal outburst is idly punished with electro shock or strike of the whip. Come the morning, ${eventSlave.slaveName}`); if (eventSlave.fetish === "masochist") { - t.push(`is mortified by the intensity of ${his} orgasms that night,<span class="devotion inc"> and more convinced than ever that ${he}'s a pain slut,</span> and yet`); + t.push(`is mortified by the intensity of ${his} orgasms that night,<span class="devotion inc">and more convinced than ever that ${he}'s a pain slut,</span> and yet`); eventSlave.devotion += 4; } t.push(`<span class="trust dec">scuttles away to tend to the bruises and marks that litter ${his} battered body.</span>`); diff --git a/src/events/intro/initNationalities.js b/src/events/intro/initNationalities.js index 45b2c5abbc490088a2b71cbcf018e33759d2aca2..e79d4a3952c37bf45559b407d18ba90e746027e6 100644 --- a/src/events/intro/initNationalities.js +++ b/src/events/intro/initNationalities.js @@ -477,7 +477,6 @@ App.Intro.initNationalities = function() { V.arcologies[0].FSPhysicalIdealistResearch = 0; V.arcologies[0].FSRepopulationFocusResearch = 0; V.arcologies[0].FSRestartResearch = 0; - V.arcologies[0].FSRestartResearchPassed = 0; V.arcologies[0].FSHedonisticDecadenceResearch = 0; V.arcologies[0].FSHedonisticDecadenceDietResearch = 0; V.arcologies[0].FSCummunismResearch = 0; diff --git a/src/gui/quicklinks.js b/src/gui/quicklinks.js index dc78a193be9d590c747c1a3d889c77811dc12124..11381652e7e14c0829ac05c60fddc84ded99f0c3 100644 --- a/src/gui/quicklinks.js +++ b/src/gui/quicklinks.js @@ -110,7 +110,7 @@ App.UI.quickMenu = (function() { riotControlCenter: () => V.secExpEnabled === 0 || V.riotCenter <= 0, Schoolroom: () => !V.schoolroom, secBarracks: () => V.secExpEnabled === 0 || !V.SecExp.buildings.barracks, - securityHQ: () => V.secExpEnabled === 0 || V.secHQ <= 0, + securityHQ: () => V.secExpEnabled === 0 || !V.SecExp.buildings.secHub, "Servants' Quarters": () => !V.servantsQuarters, Spa: () => !V.spa, "The Black Market": () => V.rep < 10000, diff --git a/src/interaction/rename.js b/src/interaction/rename.js index c5c8f696980e4ed7d94123d4ad2af6c436224e15..98609deb9dfe5e4af4d8735f819f6a69f8d12d97 100644 --- a/src/interaction/rename.js +++ b/src/interaction/rename.js @@ -35,15 +35,15 @@ App.UI.SlaveInteract.rename = function(slave, {oldName = "", oldSurname = ""} = } else if ((oldName === slave.birthName && slave.slaveName !== slave.birthName) || (oldSurname === slave.birthSurname && slave.slaveSurname !== slave.birthSurname)) { r.push(`${slave.slaveName}`); if (slave.devotion > 50) { - r.push(`accepts ${his} new name cheerfully. This attachment to you <span class="devotion inc"> increases ${his} devotion.</span>`); + r.push(`accepts ${his} new name cheerfully. This attachment to you <span class="devotion inc">increases ${his} devotion.</span>`); slave.devotion += 4; } else if (slave.devotion >= -20) { - r.push(`obediently accepts ${his} new name. This surrender to you <span class="devotion inc"> increases ${his} obedience.</span>`); + r.push(`obediently accepts ${his} new name. This surrender to you <span class="devotion inc">increases ${his} obedience.</span>`); slave.devotion += 4; } else if (slave.devotion >= -50) { r.push(`reluctantly accepts ${his} new name.`); } else { - r.push(`angrily tries to resist ${his} new name, insisting that ${his} name is ${SlaveFullBirthName(slave)}. This resistance <span class="devotion dec"> increases ${his} rebelliousness.</span>`); + r.push(`angrily tries to resist ${his} new name, insisting that ${his} name is ${SlaveFullBirthName(slave)}. This resistance <span class="devotion dec">increases ${his} rebelliousness.</span>`); slave.devotion -= 5; } } else { diff --git a/src/js/economyJS.js b/src/js/economyJS.js index 6c7a2f5b4e7543c54923d55b48f133d94914af1b..d4eae8cf0a928eae19d6fc582a725839b1123212 100644 --- a/src/js/economyJS.js +++ b/src/js/economyJS.js @@ -855,14 +855,8 @@ globalThis.calculateCosts = (function() { } function getEnvironmentCosts(cost = 0) { - if (V.secExpEnabled > 0) { - if (V.terrain === 'oceanic' || V.terrain === 'marine') { - if (V.docks > 0) { - cost *= (1 - V.docks * 0.05); - } - } else if (V.railway > 0) { - cost *= (1 - V.railway * 0.05); - } + if (V.secExpEnabled > 0 && V.SecExp.buildings.transportHub) { + cost *= (1 - V.SecExp.buildings.transportHub.surfaceTransport * 0.05); } return Math.trunc(cost); } diff --git a/src/js/futureSocietyJS.js b/src/js/futureSocietyJS.js index 49b9735e00b5c9804cbbd7b7ebe8e6cdfb019aca..a9d9386821fa8e6e98902727680de5dc3e17d36e 100644 --- a/src/js/futureSocietyJS.js +++ b/src/js/futureSocietyJS.js @@ -361,6 +361,7 @@ globalThis.FutureSocieties = (function() { case "FSRestart": arcology[FSLaw] = 0; arcology[FSSMR] = 0; + arcology.FSRestartResearch = 0; // not really research at all; reset breeding program if (_.get(V, "SecExp.edicts")) { V.SecExp.edicts.defense.eliteOfficers = 0; } diff --git a/src/npc/descriptions/belly/belly.js b/src/npc/descriptions/belly/belly.js index e611ce8452d16ed529e1f2b03640be7a0e3935a7..9273ceb2dd22109c25bde08e6392a1f6b46235af 100644 --- a/src/npc/descriptions/belly/belly.js +++ b/src/npc/descriptions/belly/belly.js @@ -7309,7 +7309,7 @@ App.Desc.belly = function(slave, {market, eventDescription} = {}) { if (slave.bellyFluid >= slave.bellyPreg && slave.bellyFluid >= slave.bellyImplant) { r.push(`Traditional battle armor would be useless on ${slave.slaveName}'s unfathomable, hyper-swollen, ${slave.inflationType}-filled belly. Instead, ${he} wears armor more suited to protecting an industrial tanker truck rather than a human being, complete with an internal mechanical frame designed to draw the shock of physical blows away from ${his} dangerously pressurized ${slave.inflationType} and special hookups to optimize the value of mobility aids.`); } else if (slave.bellyImplant > 0) { - r.push(`Traditional battle armor would be useless on ${slave.slaveName} 's unfathomable, hyper-swollen, implant-filled belly. Instead, ${he} wears armor more suited to protecting an industrial tanker truck rather than a human being, complete with an internal mechanical frame designed to draw the shock of physical blows away from ${his} dangerously pressurized implant and special hookups to optimize the value of mobility aids.`); + r.push(`Traditional battle armor would be useless on ${slave.slaveName}'s unfathomable, hyper-swollen, implant-filled belly. Instead, ${he} wears armor more suited to protecting an industrial tanker truck rather than a human being, complete with an internal mechanical frame designed to draw the shock of physical blows away from ${his} dangerously pressurized implant and special hookups to optimize the value of mobility aids.`); } else { r.push(`Traditional battle armor would be useless on ${slave.slaveName}'s unfathomable, hyper-swollen pregnant belly. Instead, ${he} wears armor more suited to protecting an industrial tanker truck rather than a human being, complete with an internal mechanical frame designed to draw the shock of physical blows away from ${his} dangerously pressurized womb and innumerable brood of squirming children, as well as special hookups to optimize the value of mobility aids.`); } diff --git a/src/npc/descriptions/describePiercings.js b/src/npc/descriptions/describePiercings.js index d84364fb08258ae25af45d691ff81bbc12ca7529..8b128f08b7b07bf72a33c26548e345e41f6873d8 100644 --- a/src/npc/descriptions/describePiercings.js +++ b/src/npc/descriptions/describePiercings.js @@ -470,9 +470,9 @@ App.Desc.piercing = function(slave, surface) { r.push(`asshole.`); } } else if (slave.anusPiercing === 2) { - r.push(`${He} has a big ring between ${his} pussy and ${his} asshole`); + r.push(`${He} has a big ring between ${his} pussy and ${his} asshole,`); if (slave.fuckdoll > 0) { - r.push(`, which helps keep the strip of material`); + r.push(`which helps keep the strip of material`); if (slave.vagina > -1) { r.push(`between ${his} holes`); } else { @@ -480,7 +480,7 @@ App.Desc.piercing = function(slave, surface) { } r.push(`in place,`); } - r.push(`and studs in all around ${his} anus.`); + r.push(`and studs all around ${his} anus.`); } } else { if (slave.anusPiercing === 1) { diff --git a/src/npc/descriptions/descriptionWidgets.js b/src/npc/descriptions/descriptionWidgets.js index b8e1a33d8b235ae062651cb000eb1cdfec105ebd..d520c628f8dfa4ccdc15715657ad38838b5e42f3 100644 --- a/src/npc/descriptions/descriptionWidgets.js +++ b/src/npc/descriptions/descriptionWidgets.js @@ -719,11 +719,11 @@ App.Desc.ageAndHealth = function(slave) { } else { r += ` The Fuckdoll gives no external indication of ${his} health or age, but upon query ${his} systems reports that ${he} is `; if (H.health < -90) { - r += `<span class="red"> in dangerously poor health,</span>`; + r += `<span class="red">in dangerously poor health,</span>`; } else if (H.health < -50) { - r += `<span class="red"> in poor health,</span>`; + r += `<span class="red">in poor health,</span>`; } else if (H.health < -20) { - r += `<span class="red"> unhealthy,</span>`; + r += `<span class="red">unhealthy,</span>`; } else if (H.health <= 20) { r += `<span class="yellow">healthy,</span>`; } else if (H.health <= 50) { diff --git a/src/npc/descriptions/longSlave.js b/src/npc/descriptions/longSlave.js index e3f25897f72553695263f08f2b7f802ea70331a3..995a2d04419a2d92323e896beb6b8f9a88a7d174 100644 --- a/src/npc/descriptions/longSlave.js +++ b/src/npc/descriptions/longSlave.js @@ -390,13 +390,13 @@ App.Desc.longSlave = function(slave = V.activeSlave, {market = 0, eventDescripti let scarCounter = 0; for (let scarName in slave.scar) { if (slave.ID === V.BodyguardID && scarCounter > 1) { - r.push(`${His} scars make ${him} look even more menacing than ${he} actually is. `); + r.push(`${His} scars make ${him} look even more menacing than ${he} actually is.`); break; } else if ((slave.ID === V.BodyguardID) && slave.scar[scarName].menacing > 0) { - r.push(`${His} menacing scar makes ${him} look terrifying. `); + r.push(`${His} menacing scar makes ${him} look terrifying.`); break; } else if ((slave.ID === V.WardenessID) && scarCounter > 1) { - r.push(`${His} scars make ${him} look like ${he}'s in the right place. `); + r.push(`${His} scars make ${him} look like ${he}'s in the right place.`); break; } scarCounter++; @@ -404,28 +404,28 @@ App.Desc.longSlave = function(slave = V.activeSlave, {market = 0, eventDescripti if (slave.fuckdoll === 0) { if (slave.markings === "birthmark" && slave.prestige === 0 && slave.porn.prestige < 2) { - r.push(`${He} has a large, liver-colored birthmark, detracting from ${his} beauty. `); + r.push(`${He} has a large, liver-colored birthmark, detracting from ${his} beauty.`); } if (slave.skin === "sun tanned") { if ((slave.rules.release.slaves === 1) || App.Utils.hasFamilySex(slave)) { if (slave.fetishStrength > 60 && slave.fetishKnown === 1) { - r.push(`${His} tan is slightly uneven, since ${he} enjoys `); + r.push(`${His} tan is slightly uneven, since ${he} enjoys`); if (slave.fetish === "buttslut") { - r.push(`letting other tanned slaves share a tanning bed with ${him} so they can sodomize ${him} while ${he} tans. `); + r.push(`letting other tanned slaves share a tanning bed with ${him} so they can sodomize ${him} while ${he} tans.`); } else if ((slave.fetish === "cumslut")) { - r.push(`letting other tanned slaves share a tanning bed with ${him} so they get oral from ${him} while ${he} tans. `); + r.push(`letting other tanned slaves share a tanning bed with ${him} so they get oral from ${him} while ${he} tans.`); } else if ((slave.fetish === "sadist")) { - r.push(`forcing inferior slaves into the tanning beds with ${him} so ${he} can sodomize them while ${he} tans. `); + r.push(`forcing inferior slaves into the tanning beds with ${him} so ${he} can sodomize them while ${he} tans.`); } else if ((slave.fetish === "dom")) { - r.push(`bringing other slaves into the tanning beds with ${him} so ${he} can fuck them while ${he} tans. `); + r.push(`bringing other slaves into the tanning beds with ${him} so ${he} can fuck them while ${he} tans.`); } else if ((slave.fetish === "masochist") || (slave.fetish === "submissive")) { - r.push(`letting other slaves into the tanning beds with ${him} so they can fuck ${him} while ${he} tans. `); + r.push(`letting other slaves into the tanning beds with ${him} so they can fuck ${him} while ${he} tans.`); } else if ((slave.fetish === "boobs")) { - r.push(`bringing other slaves into the tanning beds with ${him} so ${he} can tittyfuck them while ${he} tans. `); + r.push(`bringing other slaves into the tanning beds with ${him} so ${he} can tittyfuck them while ${he} tans.`); } else if ((slave.fetish === "pregnancy") && (jsRandom(0, 99) < V.seeDicks)) { - r.push(`letting slaves with dicks into the tanning beds with ${him} so they can cum inside ${him} while ${he} tans. `); + r.push(`letting slaves with dicks into the tanning beds with ${him} so they can cum inside ${him} while ${he} tans.`); } else { - r.push(`bringing other slaves into the tanning beds with ${him} to have sex while ${he} tans. `); + r.push(`bringing other slaves into the tanning beds with ${him} to have sex while ${he} tans.`); } } } @@ -455,7 +455,7 @@ App.Desc.longSlave = function(slave = V.activeSlave, {market = 0, eventDescripti if (slave.hLength >= 10) { if (slave.markings === "freckles" || slave.markings === "heavily freckled") { if (skinToneLevel(slave.skin) > 5 && skinToneLevel(slave.skin) < 10) { - r.push(`It goes perfectly with ${his} ${slave.skin} skin and freckles. `); + r.push(`It goes perfectly with ${his} ${slave.skin} skin and freckles.`); } } } @@ -463,48 +463,48 @@ App.Desc.longSlave = function(slave = V.activeSlave, {market = 0, eventDescripti const pubertyAge = Math.min(slave.pubertyAgeXX, slave.pubertyAgeXY); if (slave.physicalAge < pubertyAge - 2) { - r.push(`${He} is too sexually immature to have armpit hair. `); + r.push(`${He} is too sexually immature to have armpit hair.`); } else if (slave.underArmHStyle === "hairless") { - r.push(`${His} armpits are perfectly smooth and naturally hairless. `); + r.push(`${His} armpits are perfectly smooth and naturally hairless.`); } else if (slave.underArmHStyle === "bald") { - r.push(`${His} armpits no longer grow hair, leaving them smooth and hairless. `); + r.push(`${His} armpits no longer grow hair, leaving them smooth and hairless.`); } else if (slave.underArmHStyle === "waxed") { if (slave.assignment === "work in the dairy" && V.dairyRestraintsSetting > 1) { - r.push(`${His} armpit hair has been removed to prevent chafing. `); + r.push(`${His} armpit hair has been removed to prevent chafing.`); } else { - r.push(`${His} armpits are waxed and smooth. `); + r.push(`${His} armpits are waxed and smooth.`); } } else if (slave.physicalAge < pubertyAge - 1) { r.push(`${He} has a few ${slave.underArmHColor} wisps of armpit hair.`); } else if (slave.physicalAge < pubertyAge) { r.push(`${He} is on the verge of puberty and has a small patch of ${slave.underArmHColor} armpit hair.`); } else if (slave.underArmHStyle === "shaved") { - r.push(`${His} armpits appear hairless, but closer inspection reveals light, ${slave.underArmHColor} stubble. `); + r.push(`${His} armpits appear hairless, but closer inspection reveals light, ${slave.underArmHColor} stubble.`); } else if (slave.underArmHStyle === "neat") { - r.push(`${His} armpit hair is neatly trimmed `); + r.push(`${His} armpit hair is neatly trimmed`); if (!hasBothArms(slave)) { - r.push(`since `); + r.push(`since`); if (hasAnyArms(slave)) { - r.push(`at least half `); + r.push(`at least half`); } else { - r.push(`it `); + r.push(`it`); } - r.push(`is always in full view. `); + r.push(`is always in full view.`); } else { - r.push(`to not be visible unless ${he} lifts ${his} arms. `); + r.push(`to not be visible unless ${he} lifts ${his} arms.`); } } else if (slave.underArmHStyle === "bushy") { r.push(`${His} ${slave.underArmHColor} armpit hair has been allowed to grow freely,`); if (!hasAnyArms(slave)) { - r.push(`creating two bushy patches under where ${his} arms used to be. `); + r.push(`creating two bushy patches under where ${his} arms used to be.`); } else { - r.push(`so it can be seen poking out from under ${his} `); + r.push(`so it can be seen poking out from under ${his}`); if (hasBothArms(slave)) { - r.push(`arms `); + r.push(`arms`); } else { - r.push(`arm `); + r.push(`arm`); } - r.push(`at all times. `); + r.push(`at all times.`); } } } @@ -541,7 +541,7 @@ App.Desc.longSlave = function(slave = V.activeSlave, {market = 0, eventDescripti if (V.showBodyMods === 1) { if (slave.fuckdoll > 0) { if (slave.earPiercing + slave.eyebrowPiercing + slave.nosePiercing > 0) { - r.push(`The piercings on ${his} head run through ${his} suit, helping secure the material to ${his} head. `); + r.push(`The piercings on ${his} head run through ${his} suit, helping secure the material to ${his} head.`); } } else { r.push(App.Desc.mods(slave, "ear")); @@ -566,27 +566,27 @@ App.Desc.longSlave = function(slave = V.activeSlave, {market = 0, eventDescripti r.push(App.Desc.mouthAccessory(slave)); if (slave.relationship > 4) { if (hasAnyArms(slave)) { - r.push(`${He} has a simple gold band on the little finger of ${his} `); + r.push(`${He} has a simple gold band on the little finger of ${his}`); if (!hasLeftArm(slave)) { - r.push(`right `); + r.push(`right`); } else { - r.push(`left `); + r.push(`left`); } - r.push(`hand. `); + r.push(`hand.`); } else { - r.push(`${He} has a simple gold band on a length of chain around ${his} neck. `); + r.push(`${He} has a simple gold band on a length of chain around ${his} neck.`); } } else if (slave.relationship === -3) { if (hasAnyArms(slave)) { - r.push(`${He} has a simple steel band on the little finger of ${his} `); + r.push(`${He} has a simple steel band on the little finger of ${his}`); if (!hasLeftArm(slave)) { - r.push(`right `); + r.push(`right`); } else { - r.push(`left `); + r.push(`left`); } - r.push(`hand. `); + r.push(`hand.`); } else { - r.push(`${He} has a simple steel band on a length of cord around ${his} neck. `); + r.push(`${He} has a simple steel band on a length of cord around ${his} neck.`); } } } diff --git a/src/npc/descriptions/sceneIntro.js b/src/npc/descriptions/sceneIntro.js index 159e1cbb6dd65e84b367f2feb99349db312fd573..136a415110203e6630ce96a8d0a5da321dac3100 100644 --- a/src/npc/descriptions/sceneIntro.js +++ b/src/npc/descriptions/sceneIntro.js @@ -258,7 +258,7 @@ App.Desc.sceneIntro = function(slave, {market, eventDescription} = {}) { if (slave.rules.relationship === "restrictive") { r.push(`The rules forbid ${him} from associating freely with other slaves.`); } else if (slave.career === "a Futanari Sister") { - r.push(`The rules encourage ${him} to form friendships with other slaves, but ${he} seems disinclined to do so.${He}'s both friendly with them and eagerly sexual with them when allowed, but ${he} seems to be waiting for someone, deep down.`); + r.push(`The rules encourage ${him} to form friendships with other slaves, but ${he} seems disinclined to do so. ${He}'s both friendly with them and eagerly sexual with them when allowed, but ${he} seems to be waiting for someone, deep down.`); } else if (slave.rules.relationship === "just friends") { r.push(`The rules encourage ${him} to form friendships with other slaves.`); } else { diff --git a/src/npc/generate/newSlaveIntro.js b/src/npc/generate/newSlaveIntro.js index a9eaff982656532f5b0a71a1169ddefc2c41ecd9..887fd8c97731add0275e8df5005a7f9dee76b7d8 100644 --- a/src/npc/generate/newSlaveIntro.js +++ b/src/npc/generate/newSlaveIntro.js @@ -1290,10 +1290,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { r.push(`sees ${himself}`); } else { if (hasAnyArms(slave)) { - r.push(`tenderly uses ${his} hand`); - if (hasBothArms(slave)) { - r.push(`s`); - } + r.push(`tenderly uses ${his} hand${hasBothArms(slave) ? 's' : ''}`); r.push(`and finds ${himself}`); } else { r.push(`stoically waits while you vividly describe ${his} new appearance. One`); @@ -1394,14 +1391,14 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { }, result: function(slave) { const r = []; - const {He2, he2, his2, him2} = getPronouns(slave2).appendSuffix('2'); - r.push(`Your new slave appears `); + const {He2, he2, his2, him2, sister2} = getPronouns(slave2).appendSuffix('2'); + r.push(`Your new slave appears`); if (slave.devotion < -10) { r.push(`reluctant to assume ${his} new duties.`); } else { r.push(`unsure what ${his} new duties are.`); } - r.push(`You gesture towards ${slave2.slaveName}. ${He2} is `); + r.push(`You gesture towards ${slave2.slaveName}. ${He2} is`); if (slave2.intelligence + slave2.intelligenceImplant > 15) { r.push(`bright enough`); } else if ((slave2.skill.vaginal + slave2.skill.anal + slave2.skill.oral) > 100) { @@ -1409,7 +1406,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`obedient enough`); } - r.push(` to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a `); + r.push(`to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a`); if (slave2.skill.entertainment >= 100) { r.push(`masterful`); } else if (slave2.skill.entertainment > 10) { @@ -1417,29 +1414,29 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`passable`); } - r.push(` striptease, culminating in ${him2} `); + r.push(`striptease, culminating in ${him2}`); if (slave2.anus > 0 && slave2.fetish !== "cumslut") { r.push(`bending over`); } else { r.push(`kneeling`); } - r.push(` in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); + r.push(`in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); if (slave2.energy > 95) { - r.push(` like the slut ${he2} is`); + r.push(`like the slut ${he2} is.`); } else if (slave2.skill.whoring > 30) { - r.push(` like the whore ${he2} is`); + r.push(`like the whore ${he2} is.`); } else if ((slave2.assignment === "serve in the master suite") || (slave2.assignment === "please you")) { - r.push(` like the fucktoy ${he2} is`); + r.push(`like the fucktoy ${he2} is.`); } - r.push(`. As you finish, ${he2} `); + r.push(`As you finish, ${he2}`); if (slave2.fetish === "cumslut") { - r.push(`opens ${his2} mouth and savors your gift, thanking you once ${he2}'s swallowed enough to be able to talk again`); + r.push(`opens ${his2} mouth and savors your gift, thanking you once ${he2}'s swallowed enough to be able to talk again.`); } else if ((slave2.fetish === "buttslut") || (slave2.fetish === "submissive")) { - r.push(`collapses on the floor with ${his2} ass high in the air, thanking you for painting ${his2} hole white`); + r.push(`collapses on the floor with ${his2} ass high in the air, thanking you for painting ${his2} hole white.`); } else { - r.push(`thanks you`); + r.push(`thanks you.`); } - r.push(`. Witnessing this display of servitude from ${his} big _sister2 <span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); + r.push(`Witnessing this display of servitude from ${his} big ${sister2} <span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); if (slave.anus > 0 && slave.fetish !== "cumslut") { actX(slave2, "anal"); } else { @@ -1460,14 +1457,14 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { }, result: function(slave) { const r = []; - const {He2, he2, his2, him2} = getPronouns(slave2).appendSuffix('2'); - r.push(`Your new slave appears `); + const {He2, he2, his2, him2, sister2} = getPronouns(slave2).appendSuffix('2'); + r.push(`Your new slave appears`); if (slave.devotion < -10) { - r.push(`reluctant to assume ${his} new duties`); + r.push(`reluctant to assume ${his} new duties.`); } else { - r.push(`unsure what ${his} new duties are`); + r.push(`unsure what ${his} new duties are.`); } - r.push(`. You gesture towards ${slave2.slaveName}. ${He2} is `); + r.push(`You gesture towards ${slave2.slaveName}. ${He2} is`); if (slave2.intelligence + slave2.intelligenceImplant > 15) { r.push(`bright enough`); } else if (((slave2.skill.vaginal + slave2.skill.anal + slave2.skill.oral) > 100)) { @@ -1475,7 +1472,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`obedient enough`); } - r.push(` to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a `); + r.push(`to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a`); if (slave2.skill.entertainment >= 100) { r.push(`masterful`); } else if (slave2.skill.entertainment > 10) { @@ -1483,29 +1480,29 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`passable`); } - r.push(` striptease, culminating in ${him2} `); + r.push(`striptease, culminating in ${him2}`); if (slave2.anus > 0 && slave2.fetish !== "cumslut") { r.push(`bending over`); } else { r.push(`kneeling`); } - r.push(` in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); + r.push(`in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); if (slave2.energy > 95) { - r.push(` like the slut ${he2} is`); + r.push(`like the slut ${he2} is.`); } else if (slave2.skill.whoring > 30) { - r.push(` like the whore ${he2} is`); + r.push(`like the whore ${he2} is.`); } else if ((slave2.assignment === "serve in the master suite") || (slave2.assignment === "please you")) { - r.push(` like the fucktoy ${he2} is`); + r.push(`like the fucktoy ${he2} is.`); } - r.push(`. As you finish, ${he2} `); + r.push(`As you finish, ${he2}`); if (slave2.fetish === "cumslut") { - r.push(`opens ${his2} mouth and savors your gift, thanking you once ${he2}'s swallowed enough to be able to talk again`); + r.push(`opens ${his2} mouth and savors your gift, thanking you once ${he2}'s swallowed enough to be able to talk again.`); } else if ((slave2.fetish === "buttslut") || (slave2.fetish === "submissive")) { - r.push(`collapses on the floor with ${his2} ass high in the air, thanking you for painting ${his2} hole white`); + r.push(`collapses on the floor with ${his2} ass high in the air, thanking you for painting ${his2} hole white.`); } else { - r.push(`thanks you`); + r.push(`thanks you.`); } - r.push(`. Witnessing this display of servitude from ${his} little _sister2 <span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); if (slave.anus > 0 && slave.fetish !== "cumslut") { + r.push(`Witnessing this display of servitude from ${his} little ${sister2} <span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); if (slave.anus > 0 && slave.fetish !== "cumslut") { actX(slave2, "anal"); } else { actX(slave2, "oral"); @@ -1525,14 +1522,14 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { }, result: function(slave) { const r = []; - const {He2, he2, his2, him2} = getPronouns(slave2).appendSuffix('2'); - r.push(`Your new slave appears `); + const {He2, he2, his2, him2, sister2} = getPronouns(slave2).appendSuffix('2'); + r.push(`Your new slave appears`); if (slave.devotion < -10) { r.push(`reluctant to assume ${his} new duties.`); } else { r.push(`unsure what ${his} new duties are.`); } - r.push(`You gesture towards ${slave2.slaveName}. ${He2} is `); + r.push(`You gesture towards ${slave2.slaveName}. ${He2} is`); if (slave2.intelligence + slave2.intelligenceImplant > 15) { r.push(`bright enough`); } else if (((slave2.skill.vaginal + slave2.skill.anal + slave2.skill.oral) > 100)) { @@ -1540,7 +1537,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`obedient enough`); } - r.push(` to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a `); + r.push(`to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a`); if (slave2.skill.entertainment >= 100) { r.push(`masterful`); } else if (slave2.skill.entertainment > 10) { @@ -1548,21 +1545,21 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`passable`); } - r.push(` striptease, culminating in ${him2} `); + r.push(`striptease, culminating in ${him2}`); if (slave2.anus > 0 && slave2.fetish !== "cumslut") { r.push(`bending over`); } else { r.push(`kneeling`); } - r.push(` in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); + r.push(`in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); if (slave2.energy > 95) { - r.push(` like the slut ${he2} is`); + r.push(`like the slut ${he2} is.`); } else if (slave2.skill.whoring > 30) { - r.push(` like the whore ${he2} is`); + r.push(`like the whore ${he2} is.`); } else if ((slave2.assignment === "serve in the master suite") || (slave2.assignment === "please you")) { - r.push(` like the fucktoy ${he2} is`); + r.push(`like the fucktoy ${he2} is.`); } - r.push(`. As you finish, ${he2} `); + r.push(`As you finish, ${he2}`); if (slave2.fetish === "cumslut") { r.push(`opens ${his2} mouth and savors your gift, thanking you once ${he2}'s swallowed enough to be able to talk again`); } else if ((slave2.fetish === "buttslut") || (slave2.fetish === "submissive")) { @@ -1570,7 +1567,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`thanks you`); } - r.push(`. Witnessing this display of servitude from ${his} twin _sister2 <span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); + r.push(`Witnessing this display of servitude from ${his} twin ${sister2} <span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); if (slave.anus > 0 && slave.fetish !== "cumslut") { actX(slave2, "anal"); } else { @@ -1589,7 +1586,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { result: function(slave) { const r = []; const {He2, he2, his2, him2} = getPronouns(slave2).appendSuffix('2'); - r.push(`You gesture towards ${slave2.slaveName}. ${He2} is `); + r.push(`You gesture towards ${slave2.slaveName}. ${He2} is`); if (slave2.intelligence + slave2.intelligenceImplant > 15) { r.push(`bright enough`); } else if ((slave2.skill.vaginal + slave2.skill.anal + slave2.skill.oral) > 100) { @@ -1597,7 +1594,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`obedient enough`); } - r.push(` to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a `); + r.push(`to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a`); if (slave2.skill.entertainment >= 100) { r.push(`masterful`); } else if (slave2.skill.entertainment > 10) { @@ -1605,35 +1602,35 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`passable`); } - r.push(` striptease, culminating in ${him2} `); + r.push(`striptease, culminating in ${him2}`); if (slave2.anus > 0 && slave2.fetish !== "cumslut") { r.push(`bending over`); } else { r.push(`kneeling`); } - r.push(` in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); + r.push(`in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); if (slave2.energy > 95) { - r.push(` like the slut ${he2} is`); + r.push(`like the slut ${he2} is.`); } else if (slave2.skill.whoring > 30) { - r.push(` like the whore ${he2} is`); + r.push(`like the whore ${he2} is.`); } else if ((slave2.assignment === "serve in the master suite") || (slave2.assignment === "please you")) { - r.push(` like the fucktoy ${he2} is`); + r.push(`like the fucktoy ${he2} is.`); } - r.push(`. As you finish, ${he2} `); + r.push(`As you finish, ${he2}`); if (slave2.fetish === "cumslut") { - r.push(`opens ${his2} mouth and savors your gift, thanking you once ${he2}'s swallowed enough to be able to talk again`); + r.push(`opens ${his2} mouth and savors your gift, thanking you once ${he2}'s swallowed enough to be able to talk again.`); } else if ((slave2.fetish === "buttslut") || (slave2.fetish === "submissive")) { - r.push(`collapses on the floor with ${his2} ass high in the air, thanking you for painting ${his2} hole white`); + r.push(`collapses on the floor with ${his2} ass high in the air, thanking you for painting ${his2} hole white.`); } else { - r.push(`thanks you`); + r.push(`thanks you.`); } - r.push(`. Witnessing this display of servitude from ${his} `); + r.push(`Witnessing this display of servitude from ${his}`); if (slave.mother === slave2.ID) { r.push(`mother`); } else { r.push(`father`); } - r.push(` <span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); + r.push(`<span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); if (slave.anus > 0 && slave.fetish !== "cumslut") { actX(slave2, "anal"); } else { @@ -1654,8 +1651,8 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { }, result: function(slave) { const r = []; - const {He2, he2, his2, him2} = getPronouns(slave2).appendSuffix('2'); - r.push(`You gesture towards ${slave2.slaveName}. ${He2} is `); + const {He2, he2, his2, him2, daughter2} = getPronouns(slave2).appendSuffix('2'); + r.push(`You gesture towards ${slave2.slaveName}. ${He2} is`); if (slave2.intelligence + slave2.intelligenceImplant > 15) { r.push(`bright enough`); } else if (((slave2.skill.vaginal + slave2.skill.anal + slave2.skill.oral) > 100)) { @@ -1663,7 +1660,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`obedient enough`); } - r.push(` to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a `); + r.push(`to understand you mean a demonstration is in order. ${slave2.slaveName} starts things off with a`); if (slave2.skill.entertainment >= 100) { r.push(`masterful`); } else if (slave2.skill.entertainment > 10) { @@ -1671,29 +1668,29 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`passable`); } - r.push(` striptease, culminating in ${him2} `); + r.push(`striptease, culminating in ${him2}`); if (slave2.anus > 0 && slave2.fetish !== "cumslut") { r.push(`bending over`); } else { r.push(`kneeling`); } - r.push(` in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); + r.push(`in front of you. ${He2} eagerly moans as you enter ${him2}, begging for your seed`); if (slave2.energy > 95) { - r.push(` like the slut ${he2} is`); + r.push(`like the slut ${he2} is.`); } else if (slave2.skill.whoring > 30) { - r.push(` like the whore ${he2} is`); + r.push(`like the whore ${he2} is.`); } else if ((slave2.assignment === "serve in the master suite") || (slave2.assignment === "please you")) { - r.push(` like the fucktoy ${he2} is`); + r.push(`like the fucktoy ${he2} is.`); } - r.push(`. As you finish, ${he2} `); + r.push(`As you finish, ${he2}`); if (slave2.fetish === "cumslut") { - r.push(`opens ${his2} mouth and savors your gift, thanking you once ${he2}'s swallowed enough to be able to talk again`); + r.push(`opens ${his2} mouth and savors your gift, thanking you once ${he2}'s swallowed enough to be able to talk again.`); } else if ((slave2.fetish === "buttslut") || (slave2.fetish === "submissive")) { - r.push(`collapses on the floor with ${his2} ass high in the air, thanking you for painting ${his2} hole white`); + r.push(`collapses on the floor with ${his2} ass high in the air, thanking you for painting ${his2} hole white.`); } else { - r.push(`thanks you`); + r.push(`thanks you.`); } - r.push(`. Witnessing this display of servitude from ${his} _daughter2 <span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); + r.push(`Witnessing this display of servitude from ${his} ${daughter2} <span class="hotpink">eases ${slave.slaveName} into ${his} new life,</span> and <span class="mediumaquamarine">gives ${him} hope</span> ${he} can find a place here.`); if (slave.anus > 0 && slave.fetish !== "cumslut") { actX(slave, "anal"); } else { @@ -2858,22 +2855,23 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { result(slave) { const r = []; const num = jsRandom(1, 100); - r.push(`${He} seems reasonably obedient, so you give ${him} a chance to impress.You remain seated and offer ${him} your`); + r.push(`${He} seems reasonably obedient, so you give ${him} a chance to impress. You remain seated and offer ${him} your`); if (V.PC.dick !== 0) { - r.push(`half - erect cock`); + r.push(`half-erect cock`); if (V.PC.vagina !== -1) { r.push(`and ready pussy`); } } else { r.push(`pussy, wet with arousal at the prospect of breaking in a new slut`); } - r.push(`.${He} comes over obediently and gets`); + r.push(r.pop() + "."); + r.push(`${He} comes over obediently and gets`); if (hasBothLegs(slave)) { - r.push(`on ${his} knees`); + r.push(`on ${his} knees.`); } else { - r.push(`into position`); + r.push(`into position.`); } - r.push(`.${He} works hard and is clearly doing ${his} absolute best to please, so you ${him} finish you with ${his} mouth.`); + r.push(`${He} works hard and is clearly doing ${his} absolute best to please, so you ${him} finish you with ${his} mouth.`); if (V.PC.dick !== 0) { if (num > 20) { r.push(`${He}`); @@ -2895,13 +2893,14 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`${He} worked ${his} tongue hard and did ${his} best`); } - r.push(`.You spend the rest of the day with ${him}`); + r.push(`You spend the rest of the day with ${him}`); + r.push(r.pop() + "."); if (hasAnyLegs(slave)) { r.push(`kneeling`); } else { r.push(`resting`); } - r.push(`on a cushion next to your chair.${He} learns obedience, but also learns that you are < span class="mediumaquamarine" > fair</span > and < span class="hotpink" > reasonable.</span >`); + r.push(`on a cushion next to your chair. ${He} learns obedience, but also learns that you are <span class="mediumaquamarine">fair</span> and <span class="hotpink">reasonable.</span>`); slave.devotion += 4; slave.trust += 4; actX(slave, "oral"); @@ -2917,7 +2916,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { linkName: `Make sure ${he} knows pregnant women can still enjoy sex`, result(slave) { const r = []; - r.push(`You introduce ${him} to obedience and proper manners regarding ${his} ${WrittenMaster(slave)} before sending ${him} off for a physical.That night, ${he} 's returned to your room, and finds you doing business on a tablet in bed. ${He} looks doubtful, but obeys when you direct ${him} to get into bed${V.PC.dick === 0 ? `, even after ${he} realizes you're wearing a strap-on` : ``}. You turn out the light and spoon ${him} from behind, kissing ${his} neck and ears, cupping ${his} swollen breasts, and running your hands across ${his} pregnant belly with its taut ${slave.skin} skin. ${He}'s awkward at first but ${his} body responds to the tenderness. Before long ${he}'s humping ${his} pussy back and forth against`); + r.push(`You introduce ${him} to obedience and proper manners regarding ${his} ${WrittenMaster(slave)} before sending ${him} off for a physical. That night, ${he}'s returned to your room, and finds you doing business on a tablet in bed. ${He} looks doubtful, but obeys when you direct ${him} to get into bed${V.PC.dick === 0 ? `, even after ${he} realizes you're wearing a strap-on` : ``}. You turn out the light and spoon ${him} from behind, kissing ${his} neck and ears, cupping ${his} swollen breasts, and running your hands across ${his} pregnant belly with its taut ${slave.skin} skin. ${He}'s awkward at first but ${his} body responds to the tenderness. Before long ${he}'s humping ${his} pussy back and forth against`); if (V.PC.dick !== 0) { r.push(`your cock.`); } else { @@ -2953,7 +2952,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`force the reluctant ${desc}`); } - r.push(`to lie atop your desk in front of you and go back to business.After a few minutes, you extend an idle hand and begin to fondle ${his}`); + r.push(`to lie atop your desk in front of you and go back to business. After a few minutes, you extend an idle hand and begin to fondle ${his}`); if (slave.boobs > 2000) { r.push(`massive tits,`); } else if (slave.boobs > 400) { @@ -2961,7 +2960,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`cute little boobs,`); } - r.push(`continuing your work with your other hand.You quickly focus your fiddling on ${his} ${slave.nipples} nipples, the stimulation`); + r.push(`continuing your work with your other hand. You quickly focus your fiddling on ${his} ${slave.nipples} nipples, the stimulation`); if (slave.nipples === "fuckable") { if (slave.devotion > 20) { r.push(`quickly engorging them around your fingers.`); @@ -2979,7 +2978,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { if (slave.devotion > 20) { if (slave.fetish === "boobs") { if (slave.fetishKnown === 0) { - r.push(`The slave quickly becomes aroused.Before long, an orgasm convulses ${his} entire body, jiggling the feminine flesh under your hand delightfully. < span class="green" > ${He} 's a breast fetishist!</span>`); + r.push(`The slave quickly becomes aroused. Before long, an orgasm convulses ${his} entire body, jiggling the feminine flesh under your hand delightfully. <span class="green"> ${He}'s a breast fetishist!</span>`); slave.fetishKnown = 1; } else { r.push(`${His} breast fixation makes this teasing quite pleasurable for ${him}, almost as good as a handjob. Before long, an orgasm convulses ${his} entire body, jiggling the feminine flesh under your hand delightfully.`); @@ -3050,7 +3049,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { if (V.PC.dick !== 0) { r.push(`and to finish off ${his} twitching dick`); } - r.push(`${he} <span class="hotpink">complies meekly,</span> knowing you are the < span class="gold" > dominant force</span > in ${his} life now.`); + r.push(`${he} <span class="hotpink">complies meekly,</span> knowing you are the <span class="gold">dominant force</span> in ${his} life now.`); slave.devotion += 5; slave.trust -= 3; return r.join(" "); @@ -3113,13 +3112,11 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } else { r.push(`You knew ${he} had a pregnancy fetish and the look on ${his} face confirms it.`); } - r.push(`A kick from within startles you from your thoughts; it would appear your child`); + r.push(`A kick from within startles you from your thoughts; it would appear your`); if (V.PC.pregType > 1) { - r.push(`ren`); - } - r.push(`agree`); - if (V.PC.pregType === 1) { - r.push(`s`); + r.push(`children agree`); + } else { + r.push(`child agrees`); } r.push(`that you'll have to have another ride sometime.`); slave.devotion += 15; @@ -3148,9 +3145,9 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { } r.push(`milk laden breasts.`); } else if (V.PC.boobs >= 1200) { - r.push(`huge, `); + r.push(`huge,`); if (V.PC.boobsImplant > 0) { - r.push(`fake, `); + r.push(`fake,`); } r.push(`milk laden breasts.`); } else if (V.PC.boobs >= 1000) { @@ -3392,7 +3389,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { slave.devotion += 10; slave.trust += 10; } else if (slave.behavioralFlaw === "anorexic") { - r.push(`Only then does ${he} regain composure enough to realize what ${he}'s done. ${He} <span class="mediumorchid"> bursts into tears</span> as ${he} rubs ${his} disgustingly full belly. ${He} glares at you, only to catch you toying with even more food. ${He} begins to <span class="gold">tremble</span> when ${he} realizes how easily you did this to ${him}. You're sure ${he}'ll change ${his} tune in time, since you know ${he}'ll be unable to resist sneaking treats.`); + r.push(`Only then does ${he} regain composure enough to realize what ${he}'s done. ${He} <span class="mediumorchid">bursts into tears</span> as ${he} rubs ${his} disgustingly full belly. ${He} glares at you, only to catch you toying with even more food. ${He} begins to <span class="gold">tremble</span> when ${he} realizes how easily you did this to ${him}. You're sure ${he}'ll change ${his} tune in time, since you know ${he}'ll be unable to resist sneaking treats.`); slave.devotion -= 10; slave.trust -= 10; } else { @@ -3487,10 +3484,7 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { linkName: `Tie ${him} up and give ${him} a good whipping`, result(slave) { const r = []; - r.push(`You cuff ${his} wrist`); - if (hasBothArms(slave)) { - r.push(`s`); - } + r.push(`You cuff ${his} wrist${hasBothArms(slave) ? 's' : ''}`); r.push(`and tie the cuffs to a hook in the ceiling so ${he}'s forced up on tiptoe. Reflecting that sometimes the old ways are best, you take a whip to ${him}. It's soft leather and you have some skill, so ${his} skin isn't broken, but you lash ${his} buttocks and every stroke draws a scream. After a while, the pain grows dull for ${him} and ${he} slumps in ${his} bindings, moaning. You switch to ${his} nipples, bringing ${him} back to howling life as ${he} dances on tiptoe and tries to dodge.`); if (slave.dick !== 0) { r.push(`You finish by taking the whip to ${his} penis, leaving ${him} sobbing and begging.`); @@ -3513,19 +3507,19 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { const r = []; r.push(`${He}'s not a virgin anywhere, so you'll have to go more extreme to provide a properly introductory level of sexual torture equivalent to defloration. You tie your new slave down on`); if (hasAnyArms(slave)) { - r.push(`hand`); if (hasBothArms(slave)) { - r.push(`s`); + r.push(`hands`); + } else { + r.push(`hand`); } if (hasAnyLegs(slave)) { r.push(`and`); } } - if (hasAnyLegs(slave)) { + if (hasBothLegs(slave)) { + r.push(`knees`); + } else if (hasAnyLegs(slave)) { r.push(`knee`); - if (hasBothLegs(slave)) { - r.push(`s`); - } } r.push(`and bring a fuckmachine up from storage. It fits over ${him} as ${he} whimpers down there on`); if (hasAllLimbs(slave)) { @@ -3558,19 +3552,19 @@ App.UI.newSlaveIntro = function(slave, slave2 = V.eventSlave) { const r = []; r.push(`${He}'s not an anal virgin, so you'll have to go more extreme to provide an introductory level of sexual torture equivalent to defloration. You tie your new slave down on`); if (hasAnyArms(slave)) { - r.push(`hand`); if (hasBothArms(slave)) { - r.push(`s`); + r.push(`hands`); + } else { + r.push(`hand`); } if (hasAnyLegs(slave)) { r.push(`and`); } } - if (hasAnyLegs(slave)) { + if (hasBothLegs(slave)) { + r.push(`knees`); + } else if (hasAnyLegs(slave)) { r.push(`knee`); - if (hasBothLegs(slave)) { - r.push(`s`); - } } r.push(`and bring a fuckmachine up from storage. It fits over ${him} as ${he} whimpers down there on`); if (hasAllLimbs(slave)) { diff --git a/src/uncategorized/RESS.tw b/src/uncategorized/RESS.tw index 9e6128a4681ac946212a102aa1d834bbabf0891b..a43a9b14f7f978128d9480e8c0a4ae782c581f3d 100644 --- a/src/uncategorized/RESS.tw +++ b/src/uncategorized/RESS.tw @@ -7017,7 +7017,7 @@ brought in to you. This time <<= App.UI.slaveDescriptionDialog($activeSlave)>> h <</if>> <</replace>> <</link>> -<<if $activeSlave.buttPlug == "none" && ($activeSlave.vagina < 0 || ($activeSlave.vaginalAccessory == "none" && $activeSlave.vaginalAttachment == "none"))>> +<<if $activeSlave.buttplug == "none" && ($activeSlave.vagina < 0 || ($activeSlave.vaginalAccessory == "none" && $activeSlave.vaginalAttachment == "none"))>> <br><<link "Add dildos to $his gear">> <<replace "#result">> You tell $him that you understand, and that you will get $him some new clothing. $He is thrilled, but $his pleasure turns to horror when $he sees that the new clothes are a version of the same slave bondage gear, just with inward-facing dildos for $his <<if $activeSlave.vagina > -1>>pussy and <</if>> asshole. diff --git a/src/uncategorized/arcmgmt.tw b/src/uncategorized/arcmgmt.tw index a055f694a869fc98121534dcb63e9d7e6fb156ab..4f5bd3c7351d252a14edd6c566f81d7b3de3697e 100644 --- a/src/uncategorized/arcmgmt.tw +++ b/src/uncategorized/arcmgmt.tw @@ -731,8 +731,8 @@ $menialBioreactors -= _expirationBR>> /*Bad weather switch*/ <<if $weatherToday.severity > 3>> - <<if $secExpEnabled > 0>> - <<if $docks < 4 && $railway < 4>> + <<if $secExpEnabled > 0 && $SecExp.buildings.transportHub>> + <<if $SecExp.buildings.transportHub.surfaceTransport < 4>> <<set _weatherFreeze = 1>> <<set $weatherAwareness = 1>> <br>//The terrible weather is @@.red;preventing people from entering or leaving@@ your arcology. Improving your transport infrastructure will prevent this from happening.// @@ -746,8 +746,8 @@ $menialBioreactors -= _expirationBR>> <<set _weatherFreeze = 0>> <</if>> <<elseif $weatherToday.severity > 2>> - <<if $secExpEnabled > 0>> - <<if $docks < 3 && $railway < 3>> + <<if $secExpEnabled > 0 && $SecExp.buildings.transportHub>> + <<if $SecExp.buildings.transportHub.surfaceTransport < 3>> <<set _weatherFreeze = 1>> <br>//The terrible weather is @@.red;preventing people from entering or leaving@@ your arcology. Improving your transport infrastructure will prevent this from happening.// <<else>> @@ -787,19 +787,12 @@ $menialBioreactors -= _expirationBR>> /*Bunch of visitor stuff*/ <<if _weatherFreeze == 0>> -<<set _FSScore = _FSScore / $FSCreditCount, _transportHub = 1>> +<<set _FSScore = _FSScore / $FSCreditCount, _transportHub = 1, _crime = 0.8>> <<if $secExpEnabled > 0>> - <<set _transportHub = 0.7 + $airport / 10>> - <<if $docks > 0>> - <<set _transportHub += $docks / 10>> - <<elseif $railway > 0>> - <<set _transportHub += $railway / 10>> + <<if $SecExp.buildings.transportHub>> + <<set _transportHub = 0.7 + $SecExp.buildings.transportHub.airport / 10 + $SecExp.buildings.transportHub.surfaceTransport / 10>> <</if>> -<</if>> -<<if $secExpEnabled > 0>> <<set _crime = (100 - $SecExp.core.crimeLow) / 100 + 0.2>> -<<else>> - <<set _crime = 0.8>> <</if>> <<if $terrain == "urban">> <<set _terrain = 1.2>> @@ -1143,7 +1136,7 @@ _SCD = Math.trunc(($upperClass * (2 + _slaveDemandU)) + ($topClass * (12 + _slav <<set $ASlaves = $NPCSlaves + $menials + $fuckdolls + $menialBioreactors>> <<if $secExpEnabled > 0>> - <<set $ASlaves += $secMenials + App.SecExp.Manpower.employedSlave>> + <<set $ASlaves += $SecExp.buildings.secHub ? $SecExp.buildings.secHub.menials : 0 + App.SecExp.Manpower.employedSlave>> <</if>> <<set $ACitizens = $lowerClass + $middleClass + $upperClass + $topClass, _percACitizens = Math.trunc(($ACitizens / ($ACitizens + $ASlaves)) * 1000) / 10, diff --git a/src/uncategorized/manageArcology.tw b/src/uncategorized/manageArcology.tw index 7f6c268b4f9625945ee931543e101ee6acc25d94..680103fb271973ff448ad896355b285d0587ff52 100644 --- a/src/uncategorized/manageArcology.tw +++ b/src/uncategorized/manageArcology.tw @@ -192,8 +192,8 @@ </div> <div> - <<if $secHQ == 0>> - [[Set up the security headquarters|Manage Arcology][cashX(forceNeg(Math.trunc((5000*$upgradeMultiplierArcology*$HackingSkillMultiplier))), "capEx"), $secHQ = 1, $PC.skill.engineering += 1, $PC.skill.hacking += 1]] + <<if !$SecExp.buildings.secHub>> + [[Set up the security headquarters|Manage Arcology][cashX(forceNeg(Math.trunc((5000*$upgradeMultiplierArcology*$HackingSkillMultiplier))), "capEx"), App.SecExp.secHub.Init(), $PC.skill.engineering += 1, $PC.skill.hacking += 1]] <span class="detail"> Costs <<print cashFormat(Math.trunc(5000*$upgradeMultiplierArcology*$HackingSkillMultiplier))>>. <div class="indent">Building specialized in the management of security and crime.</div> diff --git a/src/uncategorized/persBusiness.tw b/src/uncategorized/persBusiness.tw index d9ae718da164925aa6db6fdf91225674b3a1726b..e1b9277e03a3a8dee3704a83b31e3db44ba65954 100644 --- a/src/uncategorized/persBusiness.tw +++ b/src/uncategorized/persBusiness.tw @@ -732,41 +732,12 @@ <<run cashX(random(10,20) * 1000, "personalBusiness")>> <</if>> - <<if $SecExp.edicts.sellData == 1>> + <<if $SecExp.buildings.secHub && $SecExp.edicts.sellData == 1>> <<set _upgradeCount = 0>> - <<if $secUpgrades.nanoCams == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $secUpgrades.cyberBots == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $secUpgrades.eyeScan == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $secUpgrades.cryptoAnalyzer == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $crimeUpgrades.autoTrial == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $crimeUpgrades.autoArchive == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $crimeUpgrades.worldProfiler == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $crimeUpgrades.advForensic == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $intelUpgrades.sensors == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $intelUpgrades.radar == 1>> - <<set _upgradeCount += 1>> - <</if>> - <<if $intelUpgrades.signalIntercept == 1>> - <<set _upgradeCount += 1>> - <</if>> + <<set _upgradeCount += Object.values($SecExp.buildings.secHub.upgrades.security).reduce((a, b) => a + b)>> + <<set _upgradeCount += Object.values($SecExp.buildings.secHub.upgrades.crime).reduce((a, b) => a + b)>> + <<set _upgradeCount += Object.values($SecExp.buildings.secHub.upgrades.intel).reduce((a, b) => a + b)>> + <<set _dataGain = _upgradeCount * 200>> <<if !Number.isInteger(_dataGain)>> <br>@@.red;Error, dataGain is NaN@@ @@ -791,15 +762,15 @@ <<set $arcRepairTime--, IncreasePCSkills('engineering', 0.1)>> <</if>> - <<if $weapManu == 1>> + <<if $SecExp.buildings.weapManu>> <br><br>The weapons manufacturing complex produces armaments - <<if $weapProductivity <= 2>> at a steady pace. + <<if $SecExp.buildings.weapManu.productivity <= 2>> at a steady pace. <<else>> with great efficiency. <</if>> <<set _income = 0>> <<set _price = Math.trunc(Math.clamp(random(1,2) + ($arcologies[0].prosperity / 15) - ($week / 30), 2, 8))>> - <<set _factoryMod = Math.round(1 + ($weapProductivity + $weapLab) / 2 + ($weapMenials / 100))>> - <<if $sellTo.citizen == 1>> + <<set _factoryMod = Math.round(1 + ($SecExp.buildings.weapManu.productivity + $SecExp.buildings.weapManu.lab) / 2 + ($SecExp.buildings.weapManu.menials / 100))>> + <<if $SecExp.buildings.weapManu.sellTo.citizen == 1>> <<if $SecExp.edicts.weaponsLaw == 3>> Your lax regulations regarding weapons allows your citizens to buy much of what you are capable of producing. <<set _income += Math.round(($ACitizens * 0.1) * _price * _factoryMod)>> @@ -810,15 +781,15 @@ Your policies do allow your citizen to buy weaponry, meaning all your income will come from exports. <</if>> <</if>> - <<if $sellTo.raiders == 1>> + <<if $SecExp.buildings.weapManu.sellTo.raiders == 1>> Some weapons are sold to the various raider gangs infesting the wastelands. <<set _income += Math.round($week / 3 * (_price / 2) * 10 * _factoryMod)>> <</if>> - <<if $sellTo.oldWorld == 1>> + <<if $SecExp.buildings.weapManu.sellTo.oldWorld == 1>> Part of our production is sold to some old world nations. <<set _income += Math.round($week / 3 * _price * 10 * _factoryMod)>> <</if>> - <<if $sellTo.raiders == 1>> + <<if $SecExp.buildings.weapManu.sellTo.raiders == 1>> A share of our weapons production is sold to other Free Cities. <<set _income += Math.round($week / 3 * _price * 10 * _factoryMod)>> <</if>> diff --git a/src/uncategorized/saRules.tw b/src/uncategorized/saRules.tw index 8a6e9aab602fb4b2fa20adaa8d16de614732f23a..0ffdd1c091e88ac316e1e9079cccfc66832dc661 100644 --- a/src/uncategorized/saRules.tw +++ b/src/uncategorized/saRules.tw @@ -435,7 +435,7 @@ Getting a day off each week @@.mediumaquamarine;builds feelings of liberty@@ a slave shouldn't have. <<set $slaves[$i].trust += 3>> <<else>> - $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster()>>.@@ + $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster($slaves[$i])>>.@@ <<set $slaves[$i].trust += 1>> <</if>> <<elseif $slaveUsedRest>> @@ -1018,7 +1018,7 @@ Getting a day off each week @@.mediumaquamarine;builds feelings of liberty@@ a slave shouldn't have. <<set $slaves[$i].trust += 3>> <<else>> - $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster()>>.@@ + $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster($slaves[$i])>>.@@ <<set $slaves[$i].trust += 1>> <</if>> <<elseif $slaveUsedRest>> @@ -4100,7 +4100,7 @@ Getting a day off each week @@.mediumaquamarine;builds feelings of liberty@@ a slave shouldn't have. <<set $slaves[$i].trust += 3>> <<else>> - $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster()>>.@@ + $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster($slaves[$i])>>.@@ <<set $slaves[$i].trust += 1>> <</if>> <<elseif $slaveUsedRest>> @@ -4749,7 +4749,7 @@ Getting a day off each week @@.mediumaquamarine;builds feelings of liberty@@ a slave shouldn't have. <<set $slaves[$i].trust += 3>> <<else>> - $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster()>>.@@ + $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster($slaves[$i])>>.@@ <<set $slaves[$i].trust += 1>> <</if>> <<elseif $slaveUsedRest>> @@ -6222,7 +6222,7 @@ Getting a day off each week @@.mediumaquamarine;builds feelings of liberty@@ a slave shouldn't have. <<set $slaves[$i].trust += 3>> <<else>> - $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster()>>.@@ + $He appreciates having a weekly day off and takes it as a sign that $he has a @@.mediumaquamarine;caring <<= WrittenMaster($slaves[$i])>>.@@ <<set $slaves[$i].trust += 1>> <</if>> <<elseif $slaveUsedRest>>