From 3cb665532a13e429c0f4c712c1fc3f1423f06d59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabian=20Preu=C3=9F?= Date: Sat, 22 Jul 2023 11:46:05 +0200 Subject: [PATCH] fix governor's over-enthusiastic mass ejection policy --- evolve/main.js | 2 +- src/governor.js | 9 +++++---- wiki/wiki.js | 2 +- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/evolve/main.js b/evolve/main.js index 2a0e8cf6a9..684df1aadd 100644 --- a/evolve/main.js +++ b/evolve/main.js @@ -1 +1 @@ -(()=>{"use strict";var e=window.localStorage,t={seed:1,warseed:1,resource:{},evolution:{},tech:{},city:{},space:{},interstellar:{},portal:{},tauceti:{},civic:{},race:{},genes:{},blood:{},stats:{start:Date.now(),days:0,tdays:0},event:{t:200,l:!1},m_event:{t:499,l:!1}},a={},r={c:{},p:{}},s={},i={},c={},o={},n={},l={},u=0;var d={},_={},p={view:"all"};const h=["all","progress","queue","building_queue","research_queue","combat","spy","events","major_events","minor_events","achievements","hell"];function m(e,a,r){return a=a||1,e=e||0,t[r?"warseed":"seed"]=(9301*t[r?"warseed":"seed"]+49297)%233280,e+t[r?"warseed":"seed"]/233280*(a-e)}Math.rand=function(e,t){return Math.floor(Math.random()*(t-e))+e},t.seed=2,t.warseed=2;{let a=e.getItem("evolved")||!1;if(a){let e=JSON.parse(LZString.decompressFromUTF16(a));e?t=e:f()}else f()}if(t.version||(t.version="0.2.0"),b(t.version)<2060&&Object.keys(t.resource).forEach((function(e){t.resource[e].crates&&(t.resource[e].crates=Math.ceil(t.resource[e].crates/5)),t.resource[e].containers&&(t.resource[e].containers=Math.ceil(t.resource[e].containers/5))})),b(t.version)<2062&&void 0!==t.civic.taxes)switch(Number(t.civic.taxes.tax_rate)){case 0:t.civic.taxes.tax_rate=0;break;case 1:t.civic.taxes.tax_rate=10;break;case 2:t.civic.taxes.tax_rate=20;break;case 3:t.civic.taxes.tax_rate=30;break;case 4:t.civic.taxes.tax_rate=40;break;case 5:t.civic.taxes.tax_rate=50}if(2062===b(t.version)&&void 0!==t.civic.taxes&&2==t.civic.taxes.tax_rate&&(t.civic.taxes.tax_rate=20),b(t.version)<2065&&void 0!==t.race&&"sporgar"===t.race.species&&(delete t.race.crafty,delete t.race.hydrophilic,t.race.infectious=1,t.race.parasite=1,!t.tech.military&&t.tech.primitive&&t.tech.primitive>=3&&(t.civic.garrison.display=!0,t.settings.showCivic=!0,t.city.garrison={count:0})),b(t.version)<3002&&t.space&&(t.tech.space&&t.tech.space>=4&&(t.space.living_quarters||(t.space.living_quarters={count:0,on:0}),t.space.garage||(t.space.garage={count:0}),t.space.red_mine||(t.space.red_mine={count:0,on:0}),t.space.fabrication||(t.space.fabrication={count:0,on:0}),t.space.laboratory||(t.space.laboratory={count:0,on:0})),t.tech.space&&t.tech.space>=3&&(t.space.iridium_mine||(t.space.iridium_mine={count:0,on:0}),t.space.helium_mine||(t.space.helium_mine={count:0,on:0})),t.tech.hell&&(t.space.geothermal||(t.space.geothermal={count:0,on:0}))),b(t.version)<3004&&t.settings&&t.settings.space&&t.settings.space.belt&&(t.space.space_station={count:0,on:0,support:0,s_max:0}),b(t.version)<4001&&t.city&&t.city.factory&&!t.city.factory.Nano&&(t.city.factory.Nano=0),b(t.version)<4003&&t.stats.achieve&&Object.keys(t.stats.achieve).forEach((function(e){t.stats.achieve[e]=1})),b(t.version)<4028&&t.stats.achieve&&t.stats.achieve.genus_demonic&&(t.stats.achieve.biome_hellscape=t.stats.achieve.genus_demonic),b(t.version)<4029&&t.race.mutation&&t.race.mutation>0){t.resource.Genes={name:"Genes",display:!0,value:0,amount:0,crates:0,diff:0,delta:0,max:-2,rate:0};for(let e=0;e=3&&(t.tech.wind_plant=1,t.tech.hunting=2);let e=["Human","Humano","Elf","Elfo","Orc","Cath","Wolven","Centaur","Centauro","Kobold","Goblin","Gnome","Ogre","Ogro","Cyclops","Ciclope","Troll","Tortoisan","Gecko","Slitheryn","Arraak","Pterodacti","Dracnid","Ent","Cacti","Sporgar","Shroomi","Mantis","Scorpid","Antid","Sharkin","Octigoran","Balorg","Imp"];for(let a=0;a0){let e=1;t.race.no_trade&&e++,t.race.no_craft&&e++,t.race.no_crispr&&e++,t.race.weak_mastery&&e++,t.stats.achieve.cross={l:e,a:e}}if(b(t.version)<7e3&&(t.civic.govern||(t.civic.govern={type:"oligarchy",rev:0,fr:0})),b(t.version)<7004&&t.queue&&t.queue.queue)for(let e=0;e0&&(t.stats.harmony=parseFloat(t.stats.harmony.toFixed(2)),t.race.Harmony.count=parseFloat(t.race.Harmony.count.toFixed(2))),b(t.version)<8017&&t.city.garrison&&(t.city.garrison.on=t.city.garrison.count),b(t.version)<9005&&t.race.hasOwnProperty("terrifying")&&t.tech.hasOwnProperty("gambling")&&!t.space.hasOwnProperty("spc_casino")&&(t.space.spc_casino={count:0,on:0}),b(t.version)<9009&&t.genes.hasOwnProperty("ancients")&&t.genes.ancients>=3&&(4===t.genes.ancients?t.genes.ancients=5:t.race.Plasmid.count+=300),b(t.version)<9010&&(["species","gods","old_gods"].forEach((e=>{"orge"===t.race[e]&&(t.race[e]="ogre")})),t.stats.hasOwnProperty("achieve")&&t.stats.achieve.hasOwnProperty("extinct_orge")&&(t.stats.achieve.extinct_ogre=t.stats.achieve.extinct_orge,delete t.stats.achieve.extinct_orge),t.resource.hasOwnProperty("orge")&&(t.resource.ogre=t.resource.orge,delete t.resource.orge),t.city&&t.city.factory&&!t.city.factory.Furs&&(t.city.factory.Furs=0)),b(t.version)<9014&&(["seraph","unicorn","custom"].forEach((e=>{t.race.species===e&&("custom"===e&&t.hasOwnProperty("custom")&&"angelic"===t.custom.race0.genus||"custom"!==e)&&(t.race.holy=1)})),t.hasOwnProperty("arpa")&&t.arpa.hasOwnProperty("sequence")&&(t.arpa.sequence.labs=0)),b(t.version)<1e5&&(delete t.city.lumber,delete t.city.stone,t.stats.dark=0,t.race.Dark&&(t.stats.dark=t.race.Dark.count),t.city.hasOwnProperty("smelter")&&(t.city.smelter.hasOwnProperty("Star")||(t.city.smelter.Star=0),t.city.smelter.hasOwnProperty("StarCap")||(t.city.smelter.StarCap=0),t.city.smelter.hasOwnProperty("Inferno")||(t.city.smelter.Inferno=0)),t.hasOwnProperty("warseed")||(t.warseed=t.seed+1,Math.war=t.hasOwnProperty("warseed")?t.warseed:t.seed),t.portal.hasOwnProperty("bireme")&&(t.portal.bireme.crew=0,t.portal.bireme.mil=0),t.portal.hasOwnProperty("transport")&&(t.portal.transport.crew=0,t.portal.transport.mil=0,t.portal.transport.cargo||(t.portal.transport.cargo={used:0,max:0,Crystal:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0})),t.hasOwnProperty("settings")&&t.settings.portal&&t.settings.portal.spire&&!t.portal.hasOwnProperty("purifier")&&(t.settings.portal.spire=!1),t.portal.hasOwnProperty("mechbay")&&!Array.isArray(t.portal.mechbay.mechs)&&(t.portal.mechbay.mechs=[]),t.portal.transport&&t.portal.transport.count>=1&&!t.tech.hell_spire&&(t.tech.hell_spire=1,t.settings.portal.spire=!0,t.settings.showCargo=!0,t.portal.purifier={count:0,on:0,support:0,s_max:0,supply:0,sup_max:100,diff:0},t.portal.port={count:0,on:0}),t.tech.hasOwnProperty("waygate")&&!t.portal.hasOwnProperty("waygate")&&delete t.tech.waygate,t.hasOwnProperty("blood")||(t.blood={})),b(t.version)<100013&&t.hasOwnProperty("settings")&&t.settings.hasOwnProperty("showPowerGrid")&&t.hasOwnProperty("race")&&t.race.infiltrator&&t.hasOwnProperty("tech")&&t.tech.hasOwnProperty("high_tech")&&t.tech.high_tech>=2&&(t.settings.showPowerGrid=!0),b(t.version)<100014&&(t.race.Dark&&(t.stats.dark=t.race.Dark.count),t.race.casting&&t.race.evil&&(t.race.casting.total-=t.race.casting.lumberjack,t.race.casting.lumberjack=0),t.queue&&t.queue.queue))for(let e=0;e=2,events:!0,major_events:!0,minor_events:!0,achievements:t.stats.achieve&&Object.keys(t.stats.achieve).length>0||t.stats.feat&&Object.keys(t.stats.feat).length>0,hell:t.settings.showPortal||t.stats.blackhole||t.stats.ascend||t.stats.descend}),t.race.hasOwnProperty("inflation")&&["supercollider","stock_exchange","launch_facility","monuments","railway","roid_eject","nexus","syphon"].forEach((function(e){t.tech.hasOwnProperty(e)&&(t.race.inflation+=10*t.tech[e])}))),b(t.version)<101012&&t.civic.garrison&&(t.civic.garrison.rate=0),b(t.version)<101014&&(t.hasOwnProperty("settings")&&t.settings.hasOwnProperty("msgFilters")&&Object.keys(t.settings.msgFilters).forEach((function(e){t.settings.msgFilters[e]={unlocked:!!t.settings.msgFilters[e],vis:!!t.settings.msgFilters[e],max:60,save:3}})),t.hasOwnProperty("lastMsg")&&t.lastMsg)){let e={};h.forEach((function(t){e[t]=[]})),t.lastMsg.forEach((function(t){t.t?t.t.forEach((function(a){e[a].push({m:t.m,c:t.c})})):e.all.push({m:t.m,c:t.c})})),t.lastMsg=e}if(b(t.version)<=101014&&!t.revision&&t.race.cataclysm&&t.race.universe&&"magic"===t.race.universe&&t.tech.magic&&t.tech.magic>=2&&(t.space.pylon={count:0}),b(t.version)<101015&&t.hasOwnProperty("special")&&t.special.hasOwnProperty("trick")&&(t.special.trick[2020]=JSON.parse(JSON.stringify(t.special.trick)),delete t.special.trick.trick1,delete t.special.trick.trick2,delete t.special.trick.trick3,delete t.special.trick.trick4,delete t.special.trick.trick5,delete t.special.trick.trick6,delete t.special.trick.trick7,delete t.special.trick.trick8,delete t.special.trick.trick9,delete t.special.trick.trick10,delete t.special.trick.trick11,delete t.special.trick.trick12),b(t.version)<102e3&&(t.hasOwnProperty("portal")&&t.portal.hasOwnProperty("fortress")&&!t.portal.fortress.hasOwnProperty("nocrew")&&(t.portal.fortress.nocrew=!1),t.city.hasOwnProperty("smelter")&&!t.city.smelter.hasOwnProperty("Iridium")&&(t.city.smelter.Iridium=0),t.hasOwnProperty("portal")&&t.portal.hasOwnProperty("mechbay")&&!t.portal.mechbay.hasOwnProperty("active")&&(t.portal.mechbay.active=0,t.portal.mechbay.scouts=0)),b(t.version)<102001&&(t.race.blood_thirst&&t.race.blood_thirst>3&&(t.race.blood_thirst=1),t.race.rainbow&&t.race.rainbow>3&&(t.race.rainbow=1)),b(t.version)<102005&&!t.stats.cores&&t.race.hasOwnProperty("AICore")&&(t.stats.cores=t.race.AICore.count),b(t.version)<102006&&t.race.artifical&&(t.race.calm&&(t.resource.hasOwnProperty("Zen")&&(t.resource.Zen.display=!0),t.city.meditation={count:0}),t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0})),b(t.version)<102007&&t.stats.hasOwnProperty("achieve")&&delete t.stats.achieve.extinct_sludge,b(t.version)<102012&&(t.city.hasOwnProperty("ptrait")&&(t.city.ptrait="none"===t.city.ptrait?[]:[t.city.ptrait]),t.tech.hell_ruins&&t.tech.hell_ruins>=3&&(t.tech.hell_vault=1)),b(t.version)<102015){if(t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks"))for(let e in t.race.governor.tasks)"asssemble"===t.race.governor.tasks[e]&&(t.race.governor.tasks[e]="assemble");t.settings&&t.settings.hasOwnProperty("restoreCheck")&&delete t.settings.restoreCheck}if(b(t.version)<102017&&(t.portal.hasOwnProperty("fortress")&&(t.portal.observe={settings:{expanded:!1,average:!1,hyperSlow:!1,display:"game_days",dropKills:!0,dropGems:!0},stats:{total:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0}},period:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0}}},graphID:0,graphs:{}}),t.tech.hasOwnProperty("genetics")&&t.tech.genetics>1&&t.hasOwnProperty("arpa")&&(t.arpa.hasOwnProperty("sequence")||(t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!1}),t.arpa.sequence.boost||(t.arpa.sequence.boost=!1),t.arpa.sequence.auto||(t.arpa.sequence.auto=!1),t.arpa.sequence.labs||(t.arpa.sequence.labs=0))),b(t.version)<102021&&t.hasOwnProperty("custom")&&!t.custom.hasOwnProperty("race0")){let e=t.race.hasOwnProperty("species")?t.race.species:"protoplasm";t.galaxy.hasOwnProperty("alien1")&&"custom"===t.galaxy.alien1.id&&(t.galaxy.alien1.id="human"===e?"elven":"human"),t.galaxy.hasOwnProperty("alien2")&&"custom"===t.galaxy.alien2.id&&(t.galaxy.alien2.id="orc"===e||"orc"===t.galaxy.alien1.id?"cath":"orc")}function g(){["reset","plasmid","antiplasmid","universes","phage","starved","tstarved","died","tdied","sac","tsac","know","tknow","portals","dkills","attacks","cfood","tfood","cstone","tstone","clumber","tlumber","mad","bioseed","cataclysm","blackhole","ascend","descend","terraform","aiappoc","matrix","retire","eden","geck","dark","harmony","blood","cores","artifact","cattle","tcattle","murders","tmurders","psykill","tpsykill"].forEach((function(e){t.stats.hasOwnProperty(e)||(t.stats[e]=0)})),t.stats.achieve||(t.stats.achieve={}),t.stats.feat||(t.stats.feat={}),t.stats.hasOwnProperty("womling")||(t.stats.womling={god:{l:0},lord:{l:0},friend:{l:0}}),t.stats.spire||(t.stats.spire={}),t.stats.synth||(t.stats.synth={}),t.stats.hasOwnProperty("banana")||(t.stats.banana={b1:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b2:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b3:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b4:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b5:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1}})}if(b(t.version)<103e3&&(t.hasOwnProperty("tauceti")||(t.tauceti={}),"protoplasm"===t.race.species&&(t.evolution.hasOwnProperty("sexual_reproduction")&&(t.tech.evo=t.evolution.sexual_reproduction.count>0?2:1,delete t.evolution.sexual_reproduction),[["phagocytosis",{evo:3,evo_animal:1}],["chloroplasts",{evo:3,evo_plant:1}],["chitin",{evo:3,evo_fungi:1}],["exterminate",{evo:7,evo_synthetic:2}],["multicellular",{evo:4}],["spores",{evo:5}],["poikilohydric",{evo:5}],["bilateral_symmetry",{evo:5,evo_insectoid:1,evo_mammals:1,evo_eggshell:1,evo_aquatic:1,evo_fey:1,evo_sand:1,evo_heat:1,evo_polar:1}],["bryophyte",{evo:7}],["athropods",{evo:7,evo_insectoid:2}],["mammals",{evo:6,evo_humanoid:1,evo_giant:1,evo_small:1,evo_animalism:1,evo_demonic:1,evo_angelic:1}],["humanoid",{evo:7,evo_humanoid:2}],["gigantism",{evo:7,evo_giant:2}],["dwarfism",{evo:7,evo_small:2}],["animalism",{evo:7,evo_animalism:2}],["carnivore",{evo_animalism:3,evo_carnivore:2}],["herbivore",{evo_animalism:3,evo_herbivore:2}],["omnivore",{evo_animalism:3,evo_omnivore:2}],["celestial",{evo:7,evo_angelic:2}],["demonic",{evo:7,evo_demonic:2}],["aquatic",{evo:7,evo_aquatic:2}],["fey",{evo:7,evo_fey:2}],["heat",{evo:7,evo_heat:2}],["polar",{evo:7,evo_polar:2}],["sand",{evo:7,evo_sand:2}],["eggshell",{evo:6,evo_eggshell:2}],["endothermic",{evo:7,evo_avian:2}],["ectothermic",{evo:7,evo_reptilian:2}],["bunker",{evo_challenge:1}]].forEach((function(e){if(t.evolution.hasOwnProperty(e[0])&&t.evolution[e[0]].count>0)for(let[a,r]of Object.entries(e[1]))t.tech[a]=r;delete t.evolution[e[0]]})),t.evolution.mloaded=1,t.evolution.gmloaded=1)),b(t.version)<103001&&(t.hasOwnProperty("prestige")||(t.prestige={}),t.race.Plasmid&&t.race.Plasmid.hasOwnProperty("anti")&&(t.prestige.AntiPlasmid={count:t.race.Plasmid.anti}),["Plasmid","Phage","AICore","Dark","Harmony"].forEach((function(e){t.race.hasOwnProperty(e)&&(t.prestige[e]={count:t.race[e].count},delete t.race[e])})),["Artifact","Blood_Stone"].forEach((function(e){t.resource.hasOwnProperty(e)&&(t.prestige[e]={count:t.resource[e].amount},delete t.resource[e])})),!t.stats.hasOwnProperty("synth")&&t.race.hasOwnProperty("srace")&&(t.stats.synth={},t.stats.synth[t.race.srace]=!0),t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("config")&&t.race.governor.config.hasOwnProperty("trash")&&["Infernite","Elerium","Copper","Iron"].forEach((function(e){t.race.governor.config.trash.hasOwnProperty(e)&&"number"==typeof t.race.governor.config.trash[e]&&(t.race.governor.config.trash[e]={v:t.race.governor.config.trash[e],s:!0})}))),b(t.version)<103002&&t.portal.hasOwnProperty("observe")&&t.portal.observe.hasOwnProperty("stats")&&(t.portal.observe.stats.period.gems.surveyors=0,t.portal.observe.stats.total.gems.surveyors=0),t.version="1.3.8",t.revision="a",delete t.beta,t.hasOwnProperty("prestige")||(t.prestige={}),["Plasmid","AntiPlasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone"].forEach((function(e){t.prestige.hasOwnProperty(e)||(t.prestige[e]={count:0})})),t.hasOwnProperty("power")||(t.power=[]),t.hasOwnProperty("support")||(t.support={}),["moon","red","belt","alpha","nebula","gateway","alien2","lake","spire","titan","enceladus","eris","tau_home","tau_red","tau_roid"].forEach((function(e){t.support.hasOwnProperty(e)||(t.support[e]=[])})),t.civic.cement_worker&&.25===t.civic.cement_worker.impact&&(t.civic.cement_worker.impact=.4),t.settings||(t.settings={showEvolve:!0,showAchieve:!1,animated:!0,disableReset:!1,font:"standard",q_merge:"merge_nearby",cLabels:!0,theme:"gruvboxDark",locale:"en-US",icon:"star"}),t.settings.space||(t.settings.space={}),t.settings.space.hasOwnProperty("home")||(t.settings.space.home=!0),C(!1),t.settings.icon||(t.settings.icon="star"),t.settings.showResources||(t.settings.showResources=t.settings.showMarket),t.settings.showStorage||(t.city.warehouse||t.city.storage_yard?t.settings.showStorage=!0:t.settings.showStorage=!1),t.settings.hasOwnProperty("touch")||(t.settings.touch=!1),t.settings.hasOwnProperty("lowPowerBalance")||(t.settings.lowPowerBalance=!1),t.queue||(t.queue={display:!1,queue:[]}),t.r_queue||(t.r_queue={display:!1,queue:[]}),t.queue.rename||(t.queue.rename=!1),t.queue.max||(t.queue.max=0),t.r_queue.max||(t.r_queue.max=0),t.queue.pause||(t.queue.pause=!1),t.r_queue.pause||(t.r_queue.pause=!1),t.lastMsg||(t.lastMsg={}),t.settings.msgFilters||(t.settings.msgFilters={}),["all","progress","events","major_events","minor_events"].forEach((function(e){t.settings.msgFilters[e]||(t.settings.msgFilters[e]={unlocked:!0,vis:!0,max:60,save:3})})),h.forEach((function(e){t.lastMsg[e]||(t.lastMsg[e]=[]),t.settings.msgFilters[e]||(t.settings.msgFilters[e]={unlocked:!1,vis:!1,max:60,save:3})})),t.settings.msgQueueHeight||(t.settings.msgQueueHeight=$("#msgQueue").outerHeight(),t.settings.buildQueueHeight=$("#buildQueue").outerHeight()),t.space||(t.space={}),t.starDock||(t.starDock={}),t.interstellar||(t.interstellar={}),t.galaxy||(t.galaxy={}),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Bolognium&&(t.interstellar.mass_ejector.Bolognium=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Vitreloy&&(t.interstellar.mass_ejector.Vitreloy=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Orichalcum&&(t.interstellar.mass_ejector.Orichalcum=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Nanoweave&&(t.interstellar.mass_ejector.Nanoweave=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Scarletite&&(t.interstellar.mass_ejector.Scarletite=0),t.hasOwnProperty("pillars")||(t.pillars={}),t.settings.space.alpha||(t.settings.space.alpha=!1,t.settings.space.proxima=!1,t.settings.space.nebula=!1,t.settings.space.neutron=!1,t.settings.space.blackhole=!1),t.settings.showAchieve||(t.settings.showAchieve=!1),t.settings.locale||(t.settings.locale="en-us"),void 0===t.settings.pause&&(t.settings.pause=!1),void 0===t.settings.mKeys&&(t.settings.mKeys=!0),void 0===t.settings.keyMap&&(t.settings.keyMap={x10:"Control",x25:"Shift",x100:"Alt",q:"q"}),void 0===t.settings.keyMap.showCiv&&(t.settings.keyMap.showCiv="1",t.settings.keyMap.showCivic="2",t.settings.keyMap.showResearch="3",t.settings.keyMap.showResources="4",t.settings.keyMap.showGenetics="5",t.settings.keyMap.showAchieve="6",t.settings.keyMap.settings="7"),delete t.settings.keyMap.d,void 0===t.settings.qAny&&(t.settings.qAny=!1),void 0===t.settings.sPackOn&&(t.settings.sPackOn=!0),void 0===t.settings.qAny_res&&(t.settings.qAny_res=!1),void 0===t.settings.sPackMsg&&(t.settings.sPackMsg=!1),void 0===t.settings.expose&&(t.settings.expose=!1),void 0===t.settings.tabLoad&&(t.settings.tabLoad=!1),void 0===t.settings.boring&&(t.settings.boring=!1),t.settings.hasOwnProperty("mtorder")||(t.settings.mtorder=[]),g(),t.race.seeded||(t.race.seeded=!1),t.race.deterioration||(t.race.deterioration=0),t.race.gene_fortify||(t.race.gene_fortify=0),t.race.old_gods||(t.race.old_gods="none"),t.race.universe||(t.race.universe="standard"),t.genes.minor||(t.genes.minor={}),t.race.minor||(t.race.minor={}),t.hasOwnProperty("govern")||(t.govern={governor:{},candidate:[],policy:{}}),t.settings.hasOwnProperty("showMil")||(t.settings.showMil=!0),t.settings.hasOwnProperty("showPowerGrid")||(t.settings.showPowerGrid=!!(t.hasOwnProperty("tech")&&t.tech.hasOwnProperty("high_tech")&&t.tech.high_tech>=2)),t.settings.affix||(t.settings.affix="si"),t.special||(t.special={}),t.special.gift||(t.special.gift={}),t.special.hasOwnProperty("egg")||(t.special.egg={}),t.special.hasOwnProperty("trick")||(t.special.trick={trick1:!1,trick2:!1,trick3:!1,trick4:!1,trick5:!1,trick6:!1,trick7:!1,trick8:!1,trick9:!1,trick10:!1,trick11:!1,trick12:!1}),t.civic.govern||(t.civic.govern={type:"oligarchy",rev:2e3,fr:0}),t.civic.govern.fr=0,t.hasOwnProperty("custom")||(t.custom={}),t.custom.hasOwnProperty("planet")&&t.custom.planet.hasOwnProperty("biome")&&delete t.custom.planet,t.city.hasOwnProperty("smelter")&&!t.city.smelter.hasOwnProperty("cap")&&(t.city.smelter.cap=0),t.civic.homeless||(t.civic.homeless=0),t.civic.foreign||(t.civic.foreign={gov0:{unrest:0,hstl:100,mil:100,eco:75,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov1:{unrest:0,hstl:0,mil:150,eco:100,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov2:{unrest:0,hstl:50,mil:250,eco:150,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1}}),void 0===t.civic.foreign.gov0.trn&&(t.civic.foreign.gov0.trn=0,t.civic.foreign.gov1.trn=0,t.civic.foreign.gov2.trn=0,t.civic.foreign.gov0.sab=0,t.civic.foreign.gov1.sab=0,t.civic.foreign.gov2.sab=0,t.civic.foreign.gov0.act="none",t.civic.foreign.gov1.act="none",t.civic.foreign.gov2.act="none"),void 0!==t.civic.foreign.gov0.name&&"evo_organism_title"===t.civic.foreign.gov0.name.s1&&(t.civic.foreign.gov0.name.s1="Northern"),void 0!==t.civic.foreign.gov1.name&&"evo_organism_title"===t.civic.foreign.gov1.name.s1&&(t.civic.foreign.gov1.name.s1="Southern"),void 0!==t.civic.foreign.gov2.name&&"evo_organism_title"===t.civic.foreign.gov2.name.s1&&(t.civic.foreign.gov2.name.s1="Divine"),!t.race.evil&&t.race.immoral&&void 0!==t.race&&"wendigo"!==t.race.species)delete t.race.immoral;else if(void 0!==t.race&&"wendigo"===t.race.species){const e=new Date;t.settings.hasOwnProperty("boring")&&!t.settings.boring&&11===e.getMonth()&&e.getDate()>=17&&(t.race.immoral=3)}if(t.hasOwnProperty("special")&&t.special.hasOwnProperty("gift")){const e=new Date(t.stats.start),a=new Date;Object.keys(t.special.gift).forEach((function(r){let s=Number(r.substring(1,5));(s=1?t.civic.d_job="farmer":t.civic.d_job="unemployed"),t.settings.animated=!0,t.settings.disableReset=!1,t.arpa&&t.arpa.launch_facility&&t.arpa.launch_facility.rank>0&&!t.tech.space&&(t.tech.space=1);var v={x10:!1,x25:!1,x100:!1,q:!1};function y(){let e=1;return t.settings.mKeys&&(v.x10&&(e*=10),v.x25&&(e*=25),v.x100&&(e*=100)),e}function b(e){let t=e.split(".",3);return t[0]*=1e5,t[1]*=1e3,Number(t[0])+Number(t[1])+Number(t[2])}function w(){if($(window).width()>=1400&&$("#msgQueue:not(.right)")){let e=$("#buildQueue").detach();e.addClass("right"),e.removeClass("has-text-info");let t=$("#msgQueue").detach();t.addClass("right"),t.removeClass("has-text-info"),t.css("resize","none"),$("#queueColumn").addClass("is-one-quarter"),$("#queueColumn").append(e),$("#queueColumn").append(t),$("#mainColumn").removeClass("is-three-quarters"),$("#mainColumn").addClass("is-half")}else if($(window).width()<1400&&$("#msgQueue").hasClass("right")){let e=$("#buildQueue").detach();e.removeClass("right"),e.addClass("has-text-info");let t=$("#msgQueue").detach();t.removeClass("right"),t.addClass("has-text-info"),t.css("resize","vertical"),$("#queueColumn").removeClass("is-one-quarter"),$("#sideQueue").append(e),$("#sideQueue").append(t),$("#mainColumn").removeClass("is-half"),$("#mainColumn").addClass("is-three-quarters")}}var x={si:["K","M","G","T","P","E","Z","Y"],sci:["e3","e6","e9","e12","e15","e18","e21","e24"],sln:["K","M","B","t","q","Q","s","S"]};function k(e,a,r){let s=0,i="",c=e<0;return c&&(e*=-1),e<=9999?s=+e.toFixed(a):e<1e6?(i=x[t.settings.affix][0],s=r?+(e/1e3).toFixed(1):Math.floor(e/100)/10):e<1e9?(i=x[t.settings.affix][1],s=r?+(e/1e6).toFixed(1):Math.floor(e/1e4)/100):e<1e12?(i=x[t.settings.affix][2],s=r?+(e/1e9).toFixed(1):Math.floor(e/1e7)/100):e<1e15?(i=x[t.settings.affix][3],s=r?+(e/1e12).toFixed(1):Math.floor(e/1e10)/100):e<1e18?(i=x[t.settings.affix][4],s=r?+(e/1e15).toFixed(1):Math.floor(e/1e13)/100):e<1e21?(i=x[t.settings.affix][5],s=r?+(e/1e18).toFixed(1):Math.floor(e/1e16)/100):e<1e24?(i=x[t.settings.affix][6],s=r?+(e/1e21).toFixed(1):Math.floor(e/1e19)/100):(i=x[t.settings.affix][7],s=r?+(e/1e24).toFixed(1):Math.floor(e/1e22)/100),s>=100&&(s=+s.toFixed(1)),c&&(s*=-1),s+i}function q(e,t){var a=document.createElement("div"),r="speak-"+Date.now();a.setAttribute("id",r),a.setAttribute("aria-live",t||"polite"),a.classList.add("sr-only"),document.body.appendChild(a),window.setTimeout((function(){document.getElementById(r).innerHTML=e}),100),window.setTimeout((function(){document.body.removeChild(document.getElementById(r))}),1e3)}$(window).resize((function(){w()})),window.soft_reset=function(a){try{a=a&&"replicator"===a?"replicator":"soft",gtag("event","reset",{end:a})}catch(e){}a||O();let r=!!t.race.hasOwnProperty("srace")&&t.race.srace,s=t.race.hasOwnProperty("geck")?t.race.geck:0;t.race.hasOwnProperty("gecked")&&(s+=t.race.gecked,t.stats.geck-=t.race.gecked);let i={species:"protoplasm",universe:t.race.universe,seeded:t.race.seeded,probes:t.race.probes,seed:t.race.seed,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended,rejuvenated:!!t.race.hasOwnProperty("rejuvenated")&&t.race.rejuvenated};s>0&&(i.geck=s),r&&(i.srace=r),t.race.bigbang&&(i.bigbang=!0),t.race.gods&&(i.gods=t.race.gods),t.race.old_gods&&(i.old_gods=t.race.old_gods),t.race.rapid_mutation&&t.race.rapid_mutation>0&&(i.rapid_mutation=t.race.rapid_mutation),t.race.ancient_ruins&&t.race.ancient_ruins>0&&(i.ancient_ruins=t.race.ancient_ruins),t.race.bigbang&&(i.universe="bigbang"),t.race.hasOwnProperty("corruption")&&(i.corruption=t.race.corruption),t.race=i;let c=t.city.calendar.orbit,o=t.city.biome,n=t.city.ptrait,l=t.city.geology;t.city={calendar:{day:0,year:0,weather:2,temp:1,moon:0,wind:0,orbit:c},biome:o,ptrait:n,geology:l},t.tech.theology&&t.tech.theology>=1?t.tech={theology:1}:t.tech={},j(),t.new=!0,t.seed=Math.rand(0,1e4),t.warseed=Math.rand(0,1e4),t.stats.current=Date.now(),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()};var M={w:!1,s:!1,timers:{},resetTimers(){this.timers={main:250,mid:1e3,long:5e3}}},P={};function O(){h.forEach((function(e){"achievements"!==e&&(t.lastMsg[e]=[])}))}function C(e){let a={base:["showCiv","showCity","showIndustry","showPowerGrid","showMechLab","showShipYard","showResearch","showCivic","showMil","showResources","showMarket","showStorage","showGenetics","showSpace","showDeep","showGalactic","showPortal","showOuter","showTau","showEjector","showCargo","showAlchemy","showGovernor","arpa","showPsychic"],space:["moon","red","hell","sun","gas","gas_moon","belt","dwarf","alpha","proxima","nebula","neutron","blackhole","sirius","stargate","gateway","gorddon","alien1","alien2","chthonian","titan","enceladus","triton","eris","kuiper"],portal:["fortress","badlands","pit","ruins","gate","lake","spire"],tau:["home","red","roid","gas","gas2","star"]};Object.keys(a).forEach((function(r){"base"===r?a[r].forEach((function(a){t.settings.hasOwnProperty(a)&&!e||(t.settings[a]=!1)})):(t.settings.hasOwnProperty(r)||(t.settings[r]={}),a[r].forEach((function(a){t.settings[r].hasOwnProperty(a)&&!e||(t.settings[r][a]=!1)})))})),["civTabs","govTabs","govTabs2","hellTabs","resTabs","spaceTabs","marketTabs","statsTabs"].forEach((function(a){t.settings.hasOwnProperty(a)&&!e||(t.settings[a]=0)}))}function j(){M.w&&M.w.terminate(),t.queue={display:!1,queue:[]},t.r_queue={display:!1,queue:[]},t.space={},t.interstellar={},t.galaxy={},t.portal={},t.starDock={},t.tauceti={},t.civic={new:0},t.civic.foreign={gov0:{unrest:0,hstl:Math.floor(m(80,100)),mil:Math.floor(m(75,125)),eco:Math.floor(m(60,90)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov1:{unrest:0,hstl:Math.floor(m(0,20)),mil:Math.floor(m(125,175)),eco:Math.floor(m(80,120)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov2:{unrest:0,hstl:Math.floor(m(40,60)),mil:Math.floor(m(200,300)),eco:Math.floor(m(130,170)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1}},t.genes.blood||(t.prestige.Blood_Stone.count=0),t.resource={},t.evolution={},t.event={t:100,l:!1},t.m_event={t:499,l:!1},t.stats.days=0,t.stats.know=0,t.stats.starved=0,t.stats.died=0,t.stats.attacks=0,t.stats.dkills=0,t.stats.cfood=0,t.stats.cstone=0,t.stats.clumber=0,t.stats.sac=0,t.stats.cattle=0,t.stats.murders=0,t.settings.at=0,t.settings.showEvolve=!0,t.settings.space.home=!0,C(!0),t.settings.disableReset=!1,t.settings.pause=!1,t.arpa={},delete t.race.hrt,t.genes.queue&&(t.tech.queue=1,t.queue.display=!0)}let S;function F(e,a){let r=S[e];if(!r)return t.settings.expose&&(console.error(`string ${e} not found`),console.log(S)),e;if(a)if(a instanceof Array){for(let s=0;s{r=e})),"en-US"!=a){let e;try{$.getJSON(`strings/strings.${a}.json`,(t=>{e=t}))}catch(e){console.error(e,e.stack)}const s=r.length;e&&Object.assign(r,e),r.length!=s&&t.settings.expose&&console.error(`string.${a}.json has extra keys.`)}let s=e.getItem("string_pack")||!1;if(s&&t.settings.sPackOn){let e;try{e=JSON.parse(LZString.decompressFromUTF16(s))}catch(e){console.error(e,e.stack)}const a=r.length;e&&Object.assign(r,e),r.length!=a&&t.settings.expose&&console.error("string pack has extra keys.")}$.ajaxSetup({async:!0}),S=r}(t.settings.locale);const z={"en-US":"English (US)","es-ES":"Spanish (ESP)","pt-BR":"Português (BR)","zh-CN":"简体中文","zh-TW":"繁體中文","ko-KR":"한국어","cs-CZ":"Čeština","ru-RU":"Русский","im-PL":"Igpay-Atinlay"},A={soldier:{name:F("governor_soldier"),desc:F("governor_soldier_desc"),title:[F("governor_soldier_t1"),F("governor_soldier_t2"),F("governor_soldier_t3")],traits:{tactician:1,militant:1}},criminal:{name:F("governor_criminal"),desc:F("governor_criminal_desc"),title:[F("governor_criminal_t1"),F("governor_criminal_t2"),{m:F("governor_criminal_t3m"),f:F("governor_criminal_t3f")}],traits:{noquestions:1,racketeer:1}},entrepreneur:{name:F("governor_entrepreneur"),desc:F("governor_entrepreneur_desc"),title:[F("governor_entrepreneur_t1"),F("governor_entrepreneur_t2"),{m:F("governor_entrepreneur_t3m"),f:F("governor_entrepreneur_t3f")}],traits:{dealmaker:1,risktaker:1}},educator:{name:F("governor_educator"),desc:F("governor_educator_desc"),title:[F("governor_educator_t1"),F("governor_educator_t2"),F("governor_educator_t3")],traits:{teacher:1,theorist:1}},spiritual:{name:F("governor_spiritual"),desc:F("governor_spiritual_desc"),title:[F("governor_spiritual_t1"),F("governor_spiritual_t2"),F("governor_spiritual_t3")],traits:{inspirational:1,pious:1}},bluecollar:{name:F("governor_bluecollar"),desc:F("governor_bluecollar_desc"),title:[{m:F("governor_bluecollar_t1m"),f:F("governor_bluecollar_t1f")},F("governor_bluecollar_t2"),{m:F("governor_bluecollar_t3m"),f:F("governor_bluecollar_t3f")}],traits:{pragmatist:1,dirty_jobs:1}},noble:{name:F("governor_noble"),desc:F("governor_noble_desc"),title:[{m:F("governor_noble_t1m"),f:F("governor_noble_t1f")},{m:F("governor_noble_t2m"),f:F("governor_noble_t2f")},{m:F("governor_noble_t3m"),f:F("governor_noble_t3f")},{m:F("governor_noble_t4m"),f:F("governor_noble_t4f")}],traits:{extravagant:1,aristocrat:1}},media:{name:F("governor_media"),desc:F("governor_media_desc"),title:[F("governor_media_t1"),{m:F("governor_media_t2m"),f:F("governor_media_t2f")},F("governor_media_t3")],traits:{gaslighter:1,muckraker:1}},sports:{name:F("governor_sports"),desc:F("governor_sports_desc"),title:[F("governor_sports_t1"),F("governor_sports_t2"),F("governor_sports_t3")],traits:{athleticism:1,nopain:1}},bureaucrat:{name:F("governor_bureaucrat"),desc:F("governor_bureaucrat_desc"),title:[F("governor_bureaucrat_t1"),{m:F("governor_bureaucrat_t2m"),f:F("governor_bureaucrat_t2f")},F("governor_bureaucrat_t3")],traits:{organizer:1}}},T={tactician:{name:F("gov_trait_tactician"),effect(){return F("gov_trait_tactician_effect",[$(this)[0].vars()[0]])},vars:()=>[25]},militant:{name:F("gov_trait_militant"),effect(){return F("gov_trait_militant_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[25,10]},noquestions:{name:F("gov_trait_noquestions"),effect(){return F("gov_trait_noquestions_effect",[$(this)[0].vars()[0]])},vars:()=>[.005]},racketeer:{name:F("gov_trait_racketeer"),effect(){return F("gov_trait_racketeer_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[20,35]},dealmaker:{name:F("gov_trait_dealmaker"),effect(){return F("gov_trait_dealmaker_effect",[$(this)[0].vars()[0]])},vars:()=>[125]},risktaker:{name:F("gov_trait_risktaker"),effect(){return F("gov_trait_risktaker_effect",[$(this)[0].vars()[0]])},vars:()=>[12]},teacher:{name:F("gov_trait_teacher"),effect(){return F("gov_trait_teacher_effect",[$(this)[0].vars()[0]])},vars:()=>[6]},theorist:{name:F("gov_trait_theorist"),effect(){return F("gov_trait_theorist_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,4]},inspirational:{name:F("gov_trait_inspirational"),effect(){return F("gov_trait_inspirational_effect",[$(this)[0].vars()[0]])},vars:()=>[20]},pious:{name:F("gov_trait_pious"),effect(){let e=$(this)[0].vars()[1],a=t.tech.monument&&t.tech.monument>=3&&i.s_gate?3:1;return e=("corpocracy"===t.civic.govern.type?2*e:e)*a,F("gov_trait_pious_effect",[$(this)[0].vars()[0],e])},vars:()=>[10,5]},pragmatist:{name:F("gov_trait_pragmatist"),effect(){return F("gov_trait_pragmatist_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,2]},dirty_jobs:{name:F("gov_trait_dirty_jobs"),effect(){return F("gov_trait_dirty_jobs_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[.015,1,10]},extravagant:{name:F("gov_trait_extravagant"),effect(){return F("gov_trait_extravagant_effect",[$(this)[0].vars()[0],Is("large",!0),$(this)[0].vars()[1],$(this)[0].vars()[2]+5])},vars:()=>[10,1.25,1]},aristocrat:{name:F("gov_trait_aristocrat"),effect(){return F("gov_trait_aristocrat_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[50,20,10]},gaslighter:{name:F("gov_trait_gaslighter"),effect(){return F("gov_trait_gaslighter_effect",[$(this)[0].vars()[0],Ts(),$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[1,1,.5]},muckraker:{name:F("gov_trait_muckraker"),effect(){return F("gov_trait_muckraker_effect",[$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[8,12,3]},athleticism:{name:F("gov_trait_athleticism"),effect(){return F("gov_trait_athleticism_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2],Ts()])},vars:()=>[1.5,2,4]},nopain:{name:F("gov_trait_nopain"),effect(){return F("gov_trait_nopain_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,10]},organizer:{name:F("gov_trait_organizer"),effect(){return F("gov_trait_organizer_effect",[$(this)[0].vars()[0]])},vars:()=>[t.genes.governor&&t.genes.governor>=2?2:1]}},E={humanoid:["Sanders","Smith","Geddon","Burgundy","Cristo","Crunch","Berg","Morros","Bower","Maximus"],carnivore:["Instinct","Prowl","Paws","Fluffy","Snarl","Claws","Fang","Stalker","Pounce","Sniff"],herbivore:["Sense","Grazer","Paws","Fluffy","Fern","Claws","Fang","Grass","Stampy","Sniff"],omnivore:["Pelt","Munchy","Paws","Fluffy","Snarl","Claws","Fang","Skavers","Pounce","Sniff"],small:["Bahgins","Banks","Shorty","Parte","Underfoot","Shrimp","Finkle","Littlefoot","Cub","Runt"],giant:["Slender","Titan","Colossus","Bean","Tower","Cloud","Bigfoot","Mountain","Crusher","Megaton"],reptilian:["Scale","Chimera","Ecto","Bask","Forks","Croc","Slither","Sunny","Coldfoot","Webtoe"],avian:["Sparrow","Soar","Shiney","Raven","Squaks","Eddy","Breeze","Flap","Kettle","Flock"],insectoid:["Compound","Centi","Hiver","Buzz","Carpace","Swarm","Devour","Carpi","Chitter","Burrow"],plant:["Grover","Blossom","Leaf","Sapper","Stem","Seed","Sprout","Greensly","Root","Fruit"],fungi:["Detritus","Psychedelic","Cap","Rotface","Patch","Spore","Infecto","Filament","Symbiote","Shade"],aquatic:["Seawolf","Finsley","Inko","Sucker","McBoatFace","Wave","Riptide","Shell","Coral","Pearl"],fey:["Whisper","Prank","Mischief","Flutter","Nature","Dirt","Story","Booker","Tales","Spirit"],heat:["Ash","Magnus","Pumice","Vulcano","Sweat","Flame","Lava","Ember","Smoke","Tinder","Spark"],polar:["Frosty","Snowball","Flake","Chiller","Frost","Cooler","Icecube","Arctic","Tundra","Avalanche"],sand:["Dune","Oasis","Sarlac","Spice","Quick","Grain","Spike","Storm","Glass","Castle"],demonic:["Yekun","Kesabel","Gadreel","Penemue","Abaddon","Azazyel","Leviathan","Samyaza","Kasyade","Typhon"],angelic:["Lightbringer","Illuminous","Sparks","Chrub","Halo","Star","Pompous","Radiant","Fluffy","Fabio"],synthetic:["HK47","D2R2","Bishop","Wally","Number5","Sunny","Data","Beta","Dot","Motoko"],eldritch:["Tentacle","Faceless","Horror","Darkness","Void","Dreamer","Mindflayer","Whisper","Paranoia","Empty"]};function I(e){let a=[],r=di[t.race.species].type,s=Object.keys(A),i=JSON.parse(JSON.stringify(E[r]));e=e||s.length;for(let t=0;t');$("#r_govern1").append(e);let a=$('
');e.append(a);let r=$("
");r.append($(`
${F("governor_office",[t.race.governor.g.n])}
`)),r.append($(`
${F("governor_background")}: ${A[t.race.governor.g.bg].name}
`)),a.append(r),a.append($(`
${F("governor_fire")}
`));let s=[0,1,2];t.genes.governor&&t.genes.governor>=2&&(s.push(s.length),N("organizer",0)&&s.push(s.length)),N("organizer",0)&&s.push(s.length),s.forEach((function(t){let a=`{{ 'none' | label }}`;Object.keys(B).forEach((function(e){B[e].req()&&(a+=`{{ '${e}' | label }}`)})),e.append(`
${F("gov_task",[t+1])}\n \n ${a}\n
`)})),t.race.governor.hasOwnProperty("config")||(t.race.governor.config={});let i=$('
');e.append(i);{t.race.governor.config.hasOwnProperty("storage")||(t.race.governor.config.storage={crt:1e3,cnt:1e3});let e=$(`
${F("gov_task_storage")}
`);i.append(e);let a=$('
');e.append(a);let r=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood",s="Steel";a.append($(`${F("gov_task_storage_reserve",[t.resource[r].name])}`)),a.append($(`${F("gov_task_storage_reserve",[t.resource[s].name])}`))}{t.race.governor.config.hasOwnProperty("bal_storage")||(t.race.governor.config.bal_storage={}),t.race.governor.config.bal_storage.hasOwnProperty("adv")||(t.race.governor.config.bal_storage.adv=!1);let e=$(`
${F("gov_task_bal_storage")}
${F("advanced")}
`);i.append(e);let a=$('
');e.append(a),Object.keys(t.resource).forEach((function(e){t.resource[e].stackable?(t.race.governor.config.bal_storage.hasOwnProperty(e)||(t.race.governor.config.bal_storage[e]="2"),a.append($(`
${t.resource[e].name}\n \n 0x\n 1/2\n 1x\n 2x\n 3x\n 4x\n \n
`))):t.race.governor.config.bal_storage.hasOwnProperty(e)&&delete t.race.governor.config.bal_storage[e]}))}{t.race.governor.config.hasOwnProperty("merc")||(t.race.governor.config.merc={buffer:1,reserve:100});let e=$(`
${F("gov_task_merc")}
`);i.append(e);let a=$('
');e.append(a),a.append($(`${F("gov_task_merc_buffer")}`)),a.append($(`${F("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("spy")||(t.race.governor.config.spy={reserve:100});let e=$(`
${F("gov_task_spy")}
`);i.append(e);let a=$('
');e.append(a),a.append($(`${F("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("spyop")||(t.race.governor.config.spyop={},Object.keys(t.civic.foreign).forEach((function(e){t.race.governor.config.spyop[e]="gov3"===e?["influence","sabotage"]:["sabotage","incite","influence"]})));let e=$(`
${F("gov_task_spyop")}
`);i.append(e),Object.keys(t.civic.foreign).forEach((function(a){if(a.substr(3,1)<3&&!t.tech.world_control||"gov3"===a&&t.tech.rival){let r=$("
");e.append(r),r.append(`\n

${F("gov_task_spyop_priority",[ee(a.substring(3))])}

\n
    \n `);let s=$(`#spyopConfig${a}`);t.race.governor.config.spyop[a].forEach((function(e){s.append(`\n
  • ${F("civics_spy_"+e)}
  • \n `)}))}}))}{t.race.governor.config.hasOwnProperty("tax")||(t.race.governor.config.tax={min:20});let e=$(`
    ${F("gov_task_tax")}
    `);i.append(e);let a=$('
    ');e.append(a),a.append($(`${F("gov_task_tax_min")}`))}{t.race.governor.config.hasOwnProperty("slave")||(t.race.governor.config.slave={reserve:100});let e=$(`
    ${F("gov_task_slave")}
    `);i.append(e);let a=$('
    ');e.append(a),a.append($(`${F("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("trash")||(t.race.governor.config.trash={}),["Infernite","Elerium","Copper","Iron"].forEach((function(e){t.race.governor.config.trash.hasOwnProperty(e)&&"object"==typeof t.race.governor.config.trash[e]&&null!==t.race.governor.config.trash[e]||(t.race.governor.config.trash[e]={v:0,s:!0})}));let e=$(`
    ${F("gov_task_trash")}
    `);i.append(e);let a=$('
    ');e.append(a),Object.keys(t.race.governor.config.trash).forEach((function(e){a.append($(`
    `))}))}{t.race.governor.config.hasOwnProperty("replicate")||(t.race.governor.config.replicate={}),t.race.governor.config.replicate.hasOwnProperty("pow")||(t.race.governor.config.replicate.pow={on:!1,cap:1e4,buffer:0}),t.race.governor.config.replicate.hasOwnProperty("res")||(t.race.governor.config.replicate.res={que:!0,neg:!0,cap:!0});let e=$(`
    ${F("gov_task_replicate")}
    `);i.append(e);let a=$('
    ');e.append(a),a.append($(`
    ${F("gov_task_replicate_auto")}
    `)),a.append($(`${F("gov_task_replicate_pmax")}`)),a.append($(`${F("gov_task_replicate_buff")}`));let r=$('
    ');e.append(r),r.append($(`
    ${F("gov_task_replicate_que")}
    `)),r.append($(`
    ${F("gov_task_replicate_neg")}
    `)),r.append($(`
    ${F("gov_task_replicate_cap")}
    `))}sc({el:"#govOffice",data:{t:t.race.governor.tasks,c:t.race.governor.config,r:t.resource},methods:{setTask(e,a){t.race.governor.tasks[`t${a}`]=e,Zi("govtask",{task:e}),sc({el:"#race"},"update")},showTask:e=>Object.values(t.race.governor.tasks).includes(e),activeTask(e){let a=[];return t.race.hasOwnProperty("governor")&&Object.keys(t.race.governor.tasks).forEach((function(e){"none"!==t.race.governor.tasks[e]&&a.push(t.race.governor.tasks[e])})),!a.includes(e)},showStrRes:e=>t.resource[e].display,bStrEx:()=>t.race.governor.config.bal_storage.adv?"m":"",fire(){let e=(10+(t.race.governor.hasOwnProperty("f")?t.race.governor.f:0))**2-50,a="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";t.prestige[a].count>=e&&(t.prestige[a].count-=e,t.race.governor.candidates=I(10),t.race.governor.hasOwnProperty("f")?t.race.governor.f++:t.race.governor.f=1,delete t.race.governor.g,delete t.race.governor.tasks,Ks(!1,["city-amphitheatre","city-apartment"]),Ri(),Hi(),K())},fireText(){let e=(10+(t.race.governor.hasOwnProperty("f")?t.race.governor.f:0))**2-50;return`
    ${F("governor_fire")}
    ${e} ${F("antimatter"===t.race.universe?"resource_AntiPlasmid_plural_name":"resource_Plasmid_plural_name")}
    `},trashStrat(e){t.race.governor.config.trash[e].s=!t.race.governor.config.trash[e].s},trashLabel:e=>F(t.race.governor.config.trash[e].s?"gov_task_trash_max":"gov_task_trash_min",[t.resource[e].name])},filters:{label:e=>B[e]?"string"==typeof B[e].name?B[e].name:B[e].name():F(`gov_task_${e}`)}}),Ti("govOffice",(function(){let e="";return Object.keys(A[t.race.governor.g.bg].traits).forEach((function(t){e+=(T[t].hasOwnProperty("effect")?T[t].effect():"")+" "})),e}),{elm:"#govOffice .bg"}),Object.keys(t.civic.foreign).forEach((function(e){!function(e){let a=$(`#spyopConfig${e}`)[0];a&&Sortable.create(a,{onEnd(a){let r=t.race.governor.config.spyop[e];r.splice(a.newDraggableIndex,0,r.splice(a.oldDraggableIndex,1)[0]),t.race.governor.config.spyop[e]=r,K()}})}(e)}))}():function(){let e=$('
    ');$("#r_govern1").append(e),t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("candidates")||(t.race.governor={candidates:I(10)}),e.append($(`
    ${F("governor_candidate")}${F("governor_background")}
    `));for(let a=0;a${r.t} ${r.n}${A[r.bg].name}
    `))}sc({el:"#candidates",data:t.race.governor,methods:{appoint(e){if(t.genes.governor&&t.tech.governor){let a=t.race.governor.candidates[e];t.race.governor.g=a,delete t.race.governor.candidates,t.race.governor.tasks={t0:"none",t1:"none",t2:"none",t3:"none",t4:"none",t5:"none"},Ks(!1,["city-amphitheatre","city-apartment"]),Ri(),Hi(),K(),Zi("governor",{appoint:t.race.governor.g.bg})}}}}),t.race.governor.candidates.forEach((function(e){Ti(`candidates-${e.bg}`,(function(){let t="";return Object.keys(A[e.bg].traits).forEach((function(e){t+=(T[e].hasOwnProperty("effect")?T[e].effect():"")+" "})),t}),{elm:`#candidates .${e.bg} .bg`})}))}())}function L(){Object.keys(t.civic.foreign).forEach((function(e){let t=$(`#spyopConfig${e}`)[0];if(t){let e=Sortable.get(t);e&&e.destroy()}}))}function N(e,a){return!(!t.race.hasOwnProperty("governor")||!t.race.governor.hasOwnProperty("g"))&&!!A[t.race.governor.g.bg].traits[e]&&T[e].vars()[a]}function D(e){if(t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks)for(let a=0;at.civic.taxes.display,task(){if($(this)[0].req()){let e=1;t.civic.taxes.tax_rate>=40&&(e+=.5),"oligarchy"===t.civic.govern.type&&t.civic.taxes.tax_rate>=20&&(e-=.5);let a=he("tax_cap",!1);if(t.city.morale.current<100&&t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?45:25))for(;t.city.morale.current<100&&t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?45:25);)he("adj_tax","sub");else t.city.morale.potential>=t.city.morale.cap+e&&t.civic.taxes.tax_ratet.race.governor.config.tax.min&&he("adj_tax","sub")}}},storage:{name:F("gov_task_storage"),req:()=>!!(ns("storage_yard")&&t.tech.container&&t.resource.Crates.display),task(){if($(this)[0].req()){if(t.resource.Crates.amountr&&qr("crate",Math.floor((t.resource[e].amount-r)/a))}if(ns("warehouse")&&t.resource.Containers.display&&t.resource.Containers.amounta&&qr("container",Math.floor((t.resource.Steel.amount-a)/e))}}}},bal_storage:{name:F("gov_task_bal_storage"),req:()=>!!(ns("storage_yard")&&t.tech.container&&t.resource.Crates.display),task(){if($(this)[0].req()){let e=t.resource.Crates.amount,a=e,r=t.resource.Containers.amount,s=r,i=0,c=Object.keys(t.resource).slice().reverse();c.forEach((function(a){t.resource[a].display&&t.resource[a].stackable?(e+=t.resource[a].crates,r+=t.resource[a].containers,i++):(t.resource[a].crates=0,t.resource[a].containers=0)}));let o=Math.floor(e/i),n=Math.floor(r/i),l={Food:{m:.1,cap:100},Coal:{m:.25}};t.race.artifical&&delete l.Food,Object.keys(t.race.governor.config.bal_storage).forEach((function(e){let a=Number(t.race.governor.config.bal_storage[e]);"Coal"===e?l[e]={m:.125*a}:"Food"===e?l[e]={m:.05*a,cap:50*a}:t.resource[e]&&(l[e]={m:a})})),Object.keys(l).forEach((function(a){if(t.resource[a].display)if(l[a].hasOwnProperty("cap")){i--;{let r=Math.floor(o*l[a].m);l[a].hasOwnProperty("cap")&&r>l[a].cap&&(r=l[a].cap),t.resource[a].crates=r,e-=r}if(t.resource.Containers.display){let e=Math.floor(n*l[a].m);l[a].hasOwnProperty("cap")&&e>l[a].cap&&(e=l[a].cap),t.resource[a].containers=e,r-=e}}else i+=l[a].m-1})),o=0!==i?Math.floor(e/i):0,n=0!==i?Math.floor(r/i):0,e-=Math.floor(o*i),r-=Math.floor(n*i),c.forEach((function(a){if((!l[a]||!l[a].hasOwnProperty("cap"))&&(!t.race.artifical||"Food"!==a)&&t.resource[a].display&&t.resource[a].stackable){let s=l[a]?l[a].m:1,i=Math.floor(o>0?o*s:0);if(t.resource[a].crates=i,t.resource.Containers.display){let e=Math.floor(n>0?n*s:0);t.resource[a].containers=e}if(e>0&&s>=1){let r=Math.ceil(s/2);e0&&s>=1){let e=Math.ceil(s/2);r0&&(e>0||r>0);)u--,c.forEach((function(a){l[a]&&l[a].hasOwnProperty("cap")||t.race.artifical&&"Food"===a||t.resource[a].display&&t.resource[a].stackable&&(e>0&&(t.resource[a].crates++,e--),r>0&&(t.resource[a].containers++,r--))}));t.resource.Crates.amount=e,t.resource.Containers.amount=r,i&&(t.resource.Crates.max-=a,t.resource.Containers.max-=s)}}},assemble:{name:F("gov_task_assemble"),req:()=>!(!t.race.artifical||t.tech.focus_cure&&!(t.tech.focus_cure<7)),task(){$(this)[0].req()&&t.resource[t.race.species].max>t.resource[t.race.species].amount&&Qr.city.assembly.action()}},clone:{name:F("gov_task_clone"),req:()=>!!t.tech.cloning,task(){$(this)[0].req()&&t.resource[t.race.species].max>t.resource[t.race.species].amount&&Qr.tauceti.tau_home.cloning_facility.action()}},merc:{name:F("gov_task_merc"),req:()=>!(!ns("garrison")||!t.tech.mercs),task(){if($(this)[0].req()){let e=t.resource.Money.max*(t.race.governor.config.merc.reserve/100);for(;t.civic.garrison.max>t.civic.garrison.workers+t.race.governor.config.merc.buffer&&t.resource.Money.amount>=he("m_cost")&&(t.resource.Money.amount+t.resource.Money.diff>=e||t.resource.Money.diff>=he("m_cost"));)he("m_buy")}}},spy:{name:F("gov_task_spy"),req:()=>!(t.tech.isolation||(!t.race.truepath||!t.tech.spy)&&(!t.tech.spy||t.tech.world_control||t.race.cataclysm)),task(){if($(this)[0].req()){let e=t.resource.Money.max*(t.race.governor.config.spy.reserve/100),a=t.race.truepath&&t.tech.rival?4:3;for(let r=t.tech.world_control?3:0;r=a&&(t.resource.Money.diff>=a||t.resource.Money.amount+t.resource.Money.diff>=e)&&he("t_spy",r)}}}},spyop:{name:F("gov_task_spyop"),req:()=>!(t.tech.isolation||!(t.race.truepath&&t.tech.spy&&t.tech.spy>=2)&&(!(t.tech.spy&&t.tech.spy>=2)||t.tech.world_control||t.race.cataclysm)),task(){if($(this)[0].req()){let e=t.race.truepath&&t.tech.rival?[0,1,2,3]:[0,1,2];t.tech.world_control&&(e=[3]),e.forEach((function(e){0===t.civic.foreign[`gov${e}`].sab&&t.civic.foreign[`gov${e}`].spy>0&&!t.civic.foreign[`gov${e}`].anx&&!t.civic.foreign[`gov${e}`].buy&&!t.civic.foreign[`gov${e}`].occ&&t.race.governor.config.spyop[`gov${e}`].every((function(a){switch(a){case"influence":if(t.civic.foreign[`gov${e}`].hstl>0&&t.civic.foreign[`gov${e}`].spy>1)return he("s_influence",e),!1;break;case"sabotage":if(t.civic.foreign[`gov${e}`].mil>50)return he("s_sabotage",e),!1;break;case"incite":if(t.civic.foreign[`gov${e}`].unrest<100&&t.civic.foreign[`gov${e}`].spy>2&&e<3)return he("s_incite",e),!1}return!0}))}))}}},slave:{name:F("gov_task_slave"),req:()=>!(t.race.orbit_decayed||!ns("slave_market")||!t.race.slaver||!t.city.slave_pen),task(){let e=t.resource.Money.max*(t.race.governor.config.slave.reserve/100),a=25e3;t.race.inflation&&(a*=1+t.race.inflation/100);let r=N("extravagant",0);r&&(a*=1+r/100),$(this)[0].req()&&t.resource.Money.amount>=a&&(t.resource.Money.diff>=a||t.resource.Money.amount+t.resource.Money.diff>=e)&&4*t.city.slave_pen.count>t.city.slave_pen.slaves&&Qr.city.slave_market.action()}},sacrifice:{name:F("gov_task_sacrifice"),req:()=>!!(ns("s_alter")&&t.city.hasOwnProperty("s_alter")&&t.city.s_alter.count>=1),task(){$(this)[0].req()&&t.resource[t.race.species].amount===t.resource[t.race.species].max&&(!t.race.kindling_kindred&&!t.race.smoldering&&t.city.s_alter.harvest<=1e4||t.city.s_alter.mind<=1e4||t.city.s_alter.mine<=1e4||t.city.s_alter.rage<=1e4||t.city.s_alter.regen<=1e4)&&Qr.city.s_alter.action()}},horseshoe:{name:()=>F(`city_${Bc(!0)}`,[Bc(!1)]),req:()=>!!t.race.hooved,task(){let e=Qr.city.horseshoe.cost;if($(this)[0].req()&&Cs(e)){e=gc(Qr.city.horseshoe);let a="Copper",r=10;Object.keys(e).forEach((function(t){e[t]()>0&&(a=t,r=e[t]())})),t.resource[a].amount>r&&(t.resource[a].diff>=r||t.resource[a].amount+t.resource[a].diff>=t.resource[a].max)&&Qr.city.horseshoe.action()}}},trash:{name:F("gov_task_trash"),req:()=>!!(t.interstellar.mass_ejector&&t.interstellar.mass_ejector.count>=1),task(){let e=function(e){return"magic"===t.race.universe?Va[e]:["Elerium","Infernite"].includes(e)?10*Va[e]:Va[e]},a=1e3*i.mass_ejector;Object.keys(Va).sort(((t,a)=>e(t)0&&(i=0),t.race.governor.config.trash[e]||t.interstellar.mass_ejector.hasOwnProperty(e)&&t.resource[e].display&&t.resource[e].max>0&&t.interstellar.mass_ejector[e]+t.resource[e].diff>0&&t.resource[e].amount+s-i>=.999*t.resource[e].max-1){let r=t.resource[e].amount+s-i>=.999*t.resource[e].max-1||t.race.governor.config.trash[e]&&!t.race.governor.config.trash[e].s?Math.floor(t.interstellar.mass_ejector[e]+t.resource[e].diff):0;t.race.governor.config.trash[e]&&r=.999*t.resource[e].max-1?r:r-Math.abs(t.race.governor.config.trash[e].v)),r>a&&(r=a),r<0&&(r=0),t.race.artifical&&"Food"===e&&(r=0),t.interstellar.mass_ejector[e]=r,a-=r}else t.interstellar.mass_ejector[e]=0})),t.interstellar.mass_ejector.total=1e3*i.mass_ejector-a}},mech:{name:F("gov_task_mech"),req:()=>!!(t.stats.achieve.hasOwnProperty("corrupted")&&t.stats.achieve.corrupted.l>0&&("prtl_spire","mechbay",Gt(ma,"prtl_spire","mechbay"))&&t.portal.hasOwnProperty("mechbay")),task(){if($(this)[0].req()){let e="large",a=ja(e,!1),r=a.c,s=a.s,i=Fa(e),c={type:{}};["small","medium","large","titan","collector"].forEach((function(e){c.type[e]=0,c[e]={chassis:{},weapon:{},equip:{}},["hover","spider","wheel","tread","biped","quad"].forEach((function(t){c[e].chassis[t]=0})),["plasma","laser","kinetic","shotgun","missile","flame","sonic","tesla"].map((e=>({sort:Math.random(),value:e}))).sort(((e,t)=>e.sort-t.sort)).map((e=>e.value)).forEach((function(t){c[e].weapon[t]=0})),["shields","flare","seals","grapple","sonar","ablative","radiator","infrared","coolant","stabilizer"].forEach((function(t){c[e].equip[t]=0}))})),t.portal.mechbay.mechs.forEach((function(e){c.type[e.size]++,c[e.size].chassis[e.chassis]++,e.hardpoint.forEach((function(t){c[e.size].weapon[t]++})),e.equip.forEach((function(t){c[e.size].equip[t]++}))})),c.type.large>=6&&c.type.small<12||c.type.large>=12&&c.type.titan>=2&&c.type.small<24?(e="small",a=ja(e,!1),r=a.c,s=a.s,i=Fa(e)):c.type.large>=6&&c.type.medium<12?(e="medium",a=ja(e,!1),r=a.c,s=a.s,i=Fa(e)):c.type.large>=12&&c.type.titan<2&&(a=ja("titan",!1),a.c<=t.portal.purifier.sup_max&&(e="titan",r=a.c,s=a.s,i=Fa(e)));let o=t.portal.mechbay.max-t.portal.mechbay.bay;if(o=3){if(t.queue.queue.some((e=>["portal-purifier","portal-port","portal-base_camp","portal-mechbay","portal-waygate"].includes(e.id))))return;for(let i=0;it.portal.purifier.sup_max&&(l=t.portal.purifier.sup_max),l>=r&&t.resource.Soul_Gem.amount+n>=s){if(t.resource.Soul_Gem.amount+=n,t.resource.Soul_Gem.amount-=s,t.portal.purifier.supply=l,t.portal.purifier.supply-=r,t.portal.mechbay.mechs[i].infernal=!0,"small"===o.size&&0===o.equip.length)t.portal.mechbay.mechs[i].equip.push("special");else if("medium"===o.size&&1===o.equip.length||"large"===o.size&&2===o.equip.length||"titan"===o.size&&o.equip.length<5){let a="???";Object.keys(c[e].equip).forEach((function(t){("???"===a||c[e].equip[t]=r&&o>=i&&t.resource.Soul_Gem.amount>=s){let a=99,o="hover";Object.keys(c[e].chassis).forEach((function(t){c[e].chassis[t]!(!t.tech.replicator||!t.race.replicator),task(){if(t.race.governor.config.replicate.pow.on){let e=t.race.governor.config.replicate.pow.cap,a=t.race.governor.config.replicate.pow.buffer;if(t.city.power0){let e=t.city.power<0?Math.abs(t.city.power)+a:a-t.city.power;t.race.replicator.pow-=e,t.race.replicator.pow<0&&(t.race.replicator.pow=0)}else t.city.power>a&&t.race.replicator.powe&&(t.race.replicator.pow=e)):t.race.replicator.pow>e&&(t.race.replicator.pow=e);t.race.replicator.pow=Math.floor(t.race.replicator.pow)}let e=!1;for(let a=0;t.race.governor.config.replicate.res.que&&at.resource[e].display)),t.race.governor.config.replicate.res.neg&&t.resource[a[0]].diff<0&&(t.resource[a[0]].amount<=.95*t.resource[a[0]].max||-1===t.resource[a[0]].max))t.race.replicator.res=a[0];else if(-1!==t.resource[t.race.replicator.res].max&&t.race.governor.config.replicate.res.cap&&t.resource[t.race.replicator.res].amount>=t.resource[t.race.replicator.res].max){let r=a.filter((e=>t.resource[e].max>0));for(let a=0;a-1===t.resource[e].max));e.length>0&&(t.race.replicator.res=e[0])}}}}}};function G(){switch(t.city.calendar.moon){case 0:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-1"):$("#moon").removeClass("wi-moon-waning-crescent-6"),$("#moon").addClass("wi-moon-new");break;case 1:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-2"):$("#moon").removeClass("wi-moon-new"),$("#moon").addClass("wi-moon-waxing-crescent-1");break;case 2:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-3"):$("#moon").removeClass("wi-moon-waxing-crescent-1"),$("#moon").addClass("wi-moon-waxing-crescent-2");break;case 3:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-4"):$("#moon").removeClass("wi-moon-waxing-crescent-2"),$("#moon").addClass("wi-moon-waxing-crescent-3");break;case 4:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-5"):$("#moon").removeClass("wi-moon-waxing-crescent-3"),$("#moon").addClass("wi-moon-waxing-crescent-4");break;case 5:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-6"):$("#moon").removeClass("wi-moon-waxing-crescent-4"),$("#moon").addClass("wi-moon-waxing-crescent-5");break;case 6:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-first-quarter"):$("#moon").removeClass("wi-moon-waxing-crescent-5"),$("#moon").addClass("wi-moon-waxing-crescent-6");break;case 7:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-1"):$("#moon").removeClass("wi-moon-waxing-crescent-6"),$("#moon").addClass("wi-moon-first-quarter");break;case 8:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-2"):$("#moon").removeClass("wi-moon-first-quarter"),$("#moon").addClass("wi-moon-waxing-gibbous-1");break;case 9:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-3"):$("#moon").removeClass("wi-moon-waxing-gibbous-1"),$("#moon").addClass("wi-moon-waxing-gibbous-2");break;case 10:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-4"):$("#moon").removeClass("wi-moon-waxing-gibbous-2"),$("#moon").addClass("wi-moon-waxing-gibbous-3");break;case 11:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-5"):$("#moon").removeClass("wi-moon-waxing-gibbous-3"),$("#moon").addClass("wi-moon-waxing-gibbous-4");break;case 12:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-6"):$("#moon").removeClass("wi-moon-waxing-gibbous-4"),$("#moon").addClass("wi-moon-waxing-gibbous-5");break;case 13:rc($("#moon")),t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-full"):$("#moon").removeClass("wi-moon-waxing-gibbous-5"),$("#moon").addClass("wi-moon-waxing-gibbous-6");break;case 14:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-1"):$("#moon").removeClass("wi-moon-waxing-gibbous-6");let e=$c(2);e.length>0?$("#moon").append(e):$("#moon").addClass("wi-moon-full");break;case 15:rc($("#moon")),t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-2"):$("#moon").removeClass("wi-moon-full"),$("#moon").addClass("wi-moon-waning-gibbous-1");break;case 16:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-3"):$("#moon").removeClass("wi-moon-waning-gibbous-1"),$("#moon").addClass("wi-moon-waning-gibbous-2");break;case 17:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-4"):$("#moon").removeClass("wi-moon-waning-gibbous-2"),$("#moon").addClass("wi-moon-waning-gibbous-3");break;case 18:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-5"):$("#moon").removeClass("wi-moon-waning-gibbous-3"),$("#moon").addClass("wi-moon-waning-gibbous-4");break;case 19:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-6"):$("#moon").removeClass("wi-moon-waning-gibbous-4"),$("#moon").addClass("wi-moon-waning-gibbous-5");break;case 20:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-third-quarter"):$("#moon").removeClass("wi-moon-waning-gibbous-5"),$("#moon").addClass("wi-moon-waning-gibbous-6");break;case 21:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-1"):$("#moon").removeClass("wi-moon-waning-gibbous-6"),$("#moon").addClass("wi-moon-third-quarter");break;case 22:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-2"):$("#moon").removeClass("wi-moon-third-quarter"),$("#moon").addClass("wi-moon-waning-crescent-1");break;case 23:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-3"):$("#moon").removeClass("wi-moon-waning-crescent-1"),$("#moon").addClass("wi-moon-waning-crescent-2");break;case 24:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-4"):$("#moon").removeClass("wi-moon-waning-crescent-2"),$("#moon").addClass("wi-moon-waning-crescent-3");break;case 25:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-5"):$("#moon").removeClass("wi-moon-waning-crescent-3"),$("#moon").addClass("wi-moon-waning-crescent-4");break;case 26:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-6"):$("#moon").removeClass("wi-moon-waning-crescent-4"),$("#moon").addClass("wi-moon-waning-crescent-5");break;case 27:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-new"):$("#moon").removeClass("wi-moon-waning-crescent-5"),$("#moon").addClass("wi-moon-waning-crescent-6")}let e;$("#temp").removeClass("wi-thermometer"),$("#temp").removeClass("wi-thermometer-exterior"),0===t.city.calendar.temp?$("#temp").addClass("wi-thermometer-exterior"):2===t.city.calendar.temp&&$("#temp").addClass("wi-thermometer"),$("#weather").removeClass("wi-day-sunny"),$("#weather").removeClass("wi-day-windy"),$("#weather").removeClass("wi-cloud"),$("#weather").removeClass("wi-cloudy-gusts"),$("#weather").removeClass("wi-rain"),$("#weather").removeClass("wi-storm-showers"),$("#weather").removeClass("wi-snow"),$("#weather").removeClass("wi-snow-wind"),0===t.city.calendar.weather?e=0===t.city.calendar.temp?0===t.city.calendar.wind?"wi-snow":"wi-snow-wind":0===t.city.calendar.wind?"wi-rain":"wi-storm-showers":1===t.city.calendar.weather?e=0===t.city.calendar.wind?"wi-cloud":"wi-cloudy-gusts":2===t.city.calendar.weather&&(e=0===t.city.calendar.wind?"wi-day-sunny":"wi-day-windy"),$("#weather").addClass(e)}function R(e){switch(e){case"moon":return t.race.orbit_decayed?F("moon0"):0===t.city.calendar.moon?F("moon1"):t.city.calendar.moon>0&&t.city.calendar.moon<7?F("moon2"):7===t.city.calendar.moon?F("moon3"):t.city.calendar.moon>7&&t.city.calendar.moon<14?F("moon4"):14===t.city.calendar.moon?F("moon5"):t.city.calendar.moon>14&&t.city.calendar.moon<21?F("moon6"):21===t.city.calendar.moon?F("moon7"):t.city.calendar.moon>21?F("moon8"):void 0;case"weather":return function(){switch(t.city.calendar.weather){case 0:return 0===t.city.calendar.temp?1===t.city.calendar.wind?F("snowstorm"):F("snow"):1===t.city.calendar.wind?F("thunderstorm"):F("rain");case 1:return 1===t.city.calendar.wind?F("cloudy_windy"):F("cloudy");case 2:return 1===t.city.calendar.wind?F("sunny_windy"):F("sunny")}}();case"temp":return function(){switch(t.city.calendar.temp){case 0:return F("cold");case 1:return F("moderate");case 2:return F("hot")}}();case"sign":return function(){let e=U(),t=`
    ${F("sign_description",[F(`sign_${e}`),F(`sign_${e}_desc`)])}
    `;return t+=`
    ${function(e){return"pisces"===e||"cancer"===e?F(`sign_${e}_effect`):F(`sign_${e}_effect`,[H(e)[0]])}(e)}
    `,t}();case"astrology":return F(`sign_${U()}_symbol`)}}function H(e){switch(e){case"aries":case"capricorn":return[10];case"taurus":return[2];case"gemini":case"aquarius":return[20];case"cancer":case"sagittarius":return[5];case"leo":return[4];case"virgo":return[15];case"libra":return[25];case"scorpio":return[12,1];case"pisces":return[49,25]}}function U(){const e=new Date;return 0===e.getMonth()&&e.getDate()>=20||1===e.getMonth()&&e.getDate()<=18?"aquarius":1===e.getMonth()&&e.getDate()>=19||2===e.getMonth()&&e.getDate()<=20?"pisces":2===e.getMonth()&&e.getDate()>=21||3===e.getMonth()&&e.getDate()<=19?"aries":3===e.getMonth()&&e.getDate()>=20||4===e.getMonth()&&e.getDate()<=20?"taurus":4===e.getMonth()&&e.getDate()>=21||5===e.getMonth()&&e.getDate()<=21?"gemini":5===e.getMonth()&&e.getDate()>=22||6===e.getMonth()&&e.getDate()<=22?"cancer":6===e.getMonth()&&e.getDate()>=23||7===e.getMonth()&&e.getDate()<=22?"leo":7===e.getMonth()&&e.getDate()>=23||8===e.getMonth()&&e.getDate()<=22?"virgo":8===e.getMonth()&&e.getDate()>=23||9===e.getMonth()&&e.getDate()<=22?"libra":9===e.getMonth()&&e.getDate()>=23||10===e.getMonth()&&e.getDate()<=22?"scorpio":10===e.getMonth()&&e.getDate()>=23||11===e.getMonth()&&e.getDate()<=21?"sagittarius":11===e.getMonth()&&e.getDate()>=22||0===e.getMonth()&&e.getDate()<=19?"capricorn":"time itself is broken"}function W(){M.w&&M.w.terminate(),O(),Zi("reset",{end:"descension"}),Xc("squished",!0),Xc(`extinct_${t.race.species}`),t.race.witch_hunter&&"magic"===t.race.universe?Xc("nightmare"):Xc("corrupted"),"angelic"===di[t.race.species].type&&eo("twisted"),t.race.junker&&"junker"===t.race.species&&eo("the_misery"),!t.race.modified&&t.race.junker&&"junker"===t.race.species&&eo("garbage_pie"),t.race.cataclysm&&eo("finish_line"),t.race.ooze&&"sludge"===t.race.species&&eo("slime_lord");let a=mc("descend");t.prestige.Artifact.count+=a.artifact,t.stats.artifact+=a.artifact;let r=Yc();t.stats.spire.hasOwnProperty(r)&&(t.stats.spire[r].hasOwnProperty("lord")?t.stats.spire[r].lord++:t.stats.spire[r].lord=1,t.tech.dl_reset?t.stats.spire[r].dlstr=0:t.stats.spire[r].hasOwnProperty("dlstr")?t.stats.spire[r].dlstr++:t.stats.spire[r].dlstr=1);let s=t.race.species,i=t.race.gods,c=t.city.calendar.orbit,o=t.city.biome,n=t.city.ptrait,l=t.city.geology;t.stats.descend++,Fc(),so();let u=!!t.race.hasOwnProperty("srace")&&t.race.srace;t.race={species:"protoplasm",gods:s,old_gods:i,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),corruption:5,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},u&&(t.race.srace=u),Q({orbit:c,biome:o,ptrait:n,geology:l}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}function Q(e){t.city={calendar:{day:0,year:0,weather:2,temp:1,moon:0,wind:0,orbit:e.orbit},biome:e.biome,ptrait:e.ptrait},e.geology&&(t.city.geology=e.geology),t.tech={theology:1},j(),t.new=!0,t.seed=Math.rand(0,1e4)}function Z(){let e=Yc();t.race.womling_friend?("m"!==e&&t.stats.womling.friend.l++,"l"!==e&&(t.stats.womling.friend.hasOwnProperty(e)||(t.stats.womling.friend[e]=0),t.stats.womling.friend[e]++)):t.race.womling_lord?("m"!==e&&t.stats.womling.lord.l++,"l"!==e&&(t.stats.womling.lord.hasOwnProperty(e)||(t.stats.womling.lord[e]=0),t.stats.womling.lord[e]++)):t.race.womling_god&&("m"!==e&&t.stats.womling.god.l++,"l"!==e&&(t.stats.womling.god.hasOwnProperty(e)||(t.stats.womling.god[e]=0),t.stats.womling.god[e]++)),t.stats.womling.friend.l>0&&t.stats.womling.lord.l>0&&t.stats.womling.god.l>0&&Xc("overlord","m"===e,ro(),"l"),t.stats.womling.friend[e]>0&&t.stats.womling.lord[e]>0&&t.stats.womling.god[e]>0&&Xc("overlord","m"===e,ro(),e)}function V(e){if(t.civic.taxes||(t.civic.taxes={tax_rate:20,display:!1}),!e&&(t.settings.tabLoad||2===t.settings.civTabs&&0===t.settings.govTabs)){var a=$('
    '),r=$(`\n \n \n \n \n \n \n `);a.append(r),$("#r_civics").append(a),sc({el:"#government .govTabs2",data:{t:t.civic.taxes,s:t.settings},methods:{vis:()=>!!t.tech.govern}}),function(e){var a=$('
    ');e.append(a);var r=$(`
    ${F("civics_government_type")} {{ type | govern }}
    `);a.append(r);var s=$("
    ");a.append(s);var i=$('');s.append(i);var c={template:''};sc({el:"#govType",data:t.civic.govern,filters:{govern:e=>F(`govern_${e}`),set:e=>F("anarchy"===e?"civics_set_gov":"civics_revolution")},methods:{trigModal(){this.$buefy.modal.open({parent:this,component:c});var e=setInterval((function(){$("#modalBox").length>0&&(clearInterval(e),function(){$("#modalBox").append($(`

    ${F("civics_government_type")}

    `));let e=$c(6,10);e.length>0&&$("#modalBoxTitle").append(e);let a=kc(6,14,!1);a.length>0&&$("#modalBoxTitle").append(a);var r=$('
    ');$("#modalBox").append(r),t.tech.govern&&("autocracy"!==t.civic.govern.type&&r.append($(``)),"democracy"!==t.civic.govern.type&&r.append($(``)),"oligarchy"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_theo&&"theocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.govern>=2&&"republic"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_soc&&"socialist"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_corp&&"corpocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.govern>=3&&"technocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_fed&&"federation"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_mage&&"magocracy"!==t.civic.govern.type&&r.append($(``))),sc({el:"#govModal",data:t.civic.govern,methods:{setGov(e){if(0===t.civic.govern.rev){let a=t.genes.governor&&"anarchy"===t.civic.govern.type;t.civic.govern.type=e;let r=1e3;t.tech.high_tech&&(r+=250,t.tech.high_tech>=3&&(r+=250),t.tech.high_tech>=6&&(r+=250)),t.tech.space_explore&&t.tech.space_explore>=3&&(r+=250),t.race.unorganized&&(r=Math.round(r*(1+ui.unorganized.vars()[0]/100))),t.stats.achieve.anarchist&&(r=Math.round(r*(1-t.stats.achieve.anarchist.l/10))),t.race.lawless&&(r=Math.round(r/(100-ui.lawless.vars()[0])));let s=Pi("tuskin");s>0&&(r=Math.round(r/(100-ui.lawless.vars(1)[0]*s)));let i=N("aristocrat",0);i&&(r=Math.round(r*(1-i/100))),t.civic.govern.rev=r+t.civic.govern.fr,a&&ms(),sc({el:"#govModal"},"destroy"),$(".modal-background").click(),Ei()}}}}),Ti("GovPop",(function(e){let a=$(e.this).data("gov"),r=t.tech.unify&&t.tech.unify>=2&&"federation"===a?"federation_alt":a;return"theocracy"===r&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display&&(r="theocracy_alt"),$(`
    ${re(a)}
    ${te()[r]}
    `)}),{elm:"#govModal button",self:!0,classes:"has-background-light has-text-dark"})}())}),50)},startrev(){t.civic.govern.fr=t.civic.govern.rev,t.civic.govern.rev=0},force:()=>t.civic.govern.rev>0?F("civics_force_rev_desc"):F("civics_force_rev_desc2"),vis:()=>!!t.tech.govern}}),Ti("govLabel",(function(){let e=t.tech.unify&&t.tech.unify>=2&&"federation"===t.civic.govern.type?"federation_alt":t.civic.govern.type;return"theocracy"===e&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display&&(e="theocracy_alt"),$(`
    ${re(t.civic.govern.type)}
    ${te()[e]}
    `)})),Ti("govTypeChange",(function(){return t.civic.govern.rev>0?F("civics_change_desc",[t.civic.govern.rev]):F("civics_change_desc2")}),{elm:"#govType .change"})}($("#r_govern0")),function(e){var a=$('
    ');e.append(a);var r=$(`

    ${F("civics_tax_rates")}

    `);a.append(r);var s=$(''),i=$('«'),c=$('»');a.append(i),a.append(s),a.append(c),sc({el:"#tax_rates",data:t.civic.taxes,filters:{tax_level(e){let a=$c(11,14),r=kc(2,14,!1);return a.length>0&&(0===e&&!t.race.noble||10===e&&t.race.noble)?a:13===e&&r.length>0?r:`${e}%`}},methods:{add(){pe("add")},sub(){pe("sub")}}}),Ti("taxRateLabel",(function(){return F("civics_tax_rates_desc")}),{classes:"has-background-light has-text-dark"})}($("#r_govern0"));var s=$('
    ');$("#r_govern0").append(s),K()}}function J(){if(Y(),t.settings.tabLoad||2===t.settings.civTabs&&3===t.settings.govTabs){var a=$('
    ');$("#military").append(a),$("#military").append($('
    ')),fe(a,!0),function(){if(t.race.sludge)return!1;if(0===$("#mad").length){let s="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");var a=$('
    ');$("#military").append(a);var r=$('
    ');a.append(r),r.append($(`
    ${F("civics_mad_reset_desc",[s])}
    `));let i=!(!t.race.hrt||!["wolven","vulpine"].includes(t.race.hrt));r.append($(`
    `)),r.append($(`
    `)),t.civic.mad.armed||($("#mad").addClass("armed"),$("#mad .arm").html(F(i?"civics_mad_disarm_grenades":"civics_mad_disarm_missiles"))),sc({el:"#mad",data:t.civic.mad,methods:{launch(){if(!t.civic.mad.armed&&!t.race.cataclysm){$("body").addClass("nuke");let a=$('
    ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),500),setTimeout((function(){a.addClass("b")}),600),setTimeout((function(){!function(){if(!t.civic.mad.armed&&!t.race.cataclysm){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"mad"});let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=t.city.geology,n=mc("mad");t.stats.mad++,Fc(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=n.plasmid,t.stats.antiplasmid+=n.plasmid):(t.prestige.Plasmid.count+=n.plasmid,t.stats.plasmid+=n.plasmid),Xc("apocalypse"),Xc("squished",!0),Xc(`extinct_${a}`),"anarchy"===t.civic.govern.type&&Xc("anarchist"),"hellscape"===t.city.biome&&"demonic"!==di[t.race.species].type&&eo("take_no_advice"),t.race.truepath&&Xc("ashanddust"),so();let l=!!t.race.hasOwnProperty("srace")&&t.race.srace,u=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,rapid_mutation:1,ancient_ruins:1,universe:t.race.universe,seeded:!1,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},u>0&&(t.race.corruption=u),l&&(t.race.srace=l),Q({orbit:s,biome:i,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}}()}),4e3)}},arm(){t.civic.mad.armed?($("#mad .arm").html(F(i?"civics_mad_disarm_grenades":"civics_mad_disarm_missiles")),t.civic.mad.armed=!1,$("#mad").addClass("armed")):($("#mad .arm").html(F(i?"civics_mad_arm_grenades":"civics_mad_arm_missiles")),t.civic.mad.armed=!0,$("#mad").removeClass("armed"))}}}),["mdarm","mdlaunch"].forEach((function(e){Ti(`mad${e}`,(function(){return"{{ label() }}"}),{elm:`#mad .${e}`,in:function(a){sc({el:`#${a.id} > span`,data:{test:"val"},methods:{label(){switch(e){case"mdarm":return t.tech.world_control&&!t.race.truepath?F("civics_mad_missiles_world_control_desc"):F(i?"civics_mad_missiles_desc_easter":"civics_mad_missiles_desc");case"mdlaunch":{let e=mc("mad"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return F("civics_mad_missiles_warning",[e.plasmid,a])}}}}})},out:function(e){sc({el:`#${e.id} > span`},"destroy")}})}))}}()}}function Y(){t.civic.garrison||(t.civic.garrison={display:!1,disabled:!1,rate:0,progress:0,tactic:0,workers:0,wounded:0,raid:0,max:0}),t.civic.garrison.mercs||(t.civic.garrison.mercs=!1),t.civic.garrison.fatigue||(t.civic.garrison.fatigue=0),t.civic.garrison.protest||(t.civic.garrison.protest=0),t.civic.garrison.m_use||(t.civic.garrison.m_use=0),t.civic.garrison.crew||(t.civic.garrison.crew=0),t.civic.mad||(t.civic.mad={display:!1,armed:!0})}function X(e){if(t.race.truepath){if(t.civic.foreign[`gov${e}`].hstl<10)return 1+(10-t.civic.foreign[`gov${e}`].hstl)/40;if(t.civic.foreign[`gov${e}`].hstl>60)return 1-(-60+t.civic.foreign[`gov${e}`].hstl)/160}return 1}function ee(e){if(void 0===t.civic.foreign[`gov${e}`].name){let a=Ji();t.civic.foreign[`gov${e}`].name={s0:a.s0,s1:a.s1}}return F(`civics_gov${t.civic.foreign[`gov${e}`].name.s0}`,[t.civic.foreign[`gov${e}`].name.s1])}const te=function(){return{anarchy:F("govern_anarchy_effect"),autocracy:F("govern_autocracy_effect",ae.autocracy()),democracy:F("govern_democracy_effect",ae.democracy()),oligarchy:t.tech.high_tech&&t.tech.high_tech>=12?F("govern_oligarchy_effect_alt",[ae.oligarchy()[1]]):F("govern_oligarchy_effect",[ae.oligarchy()[0],ae.oligarchy()[1]]),theocracy:F("govern_theocracy_effect",ae.theocracy()),theocracy_alt:F("govern_theocracy_effect_alt",ae.theocracy()),republic:F("govern_republic_effect",ae.republic()),socialist:F("govern_socialist_effect",ae.socialist()),corpocracy:F("govern_corpocracy_effect",ae.corpocracy()),technocracy:t.tech.high_tech&&t.tech.high_tech>=16?F("govern_technocracy_effect_alt",[ae.technocracy()[0],ae.technocracy()[2]]):F("govern_technocracy_effect",ae.technocracy()),federation:F("govern_federation_effect",[ae.federation()[0],ae.federation()[1]]),federation_alt:F("govern_federation_effect_alt",[25,ae.federation()[2],ae.federation()[1]]),magocracy:F("govern_magocracy_effect",ae.magocracy())}},ae={autocracy:()=>[t.tech.high_tech&&t.tech.high_tech>=2?t.tech.high_tech>=12?10:18:25,N("organizer",0)?40:35],democracy:()=>[t.tech.high_tech&&t.tech.high_tech>=2?t.tech.high_tech>=12?30:25:20,N("organizer",0)?1:5],oligarchy:()=>[t.tech.high_tech&&t.tech.high_tech>=12?0:t.tech.high_tech&&t.tech.high_tech>=2?2:5,N("organizer",0)?25:20],theocracy:()=>[12,N("organizer",0)?10:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?25:40:50],republic:()=>[N("organizer",0)?30:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?40:30:20],socialist:()=>[t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?50:42:35,N("organizer",0)?12:10,10,N("organizer",0)?10:20],corpocracy:()=>[N("organizer",0)?220:200,N("organizer",0)?175:150,N("organizer",0)?110:100,t.tech.high_tech&&t.tech.high_tech>=12?5:10,t.tech.high_tech&&t.tech.high_tech>=16?40:30],technocracy:()=>[8,t.tech.high_tech&&t.tech.high_tech>=16?0:t.tech.high_tech&&t.tech.high_tech>=12?1:2,N("organizer",0)?18:10],federation:()=>[3,N("organizer",0)?12:10,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?40:36:32],magocracy:()=>[N("organizer",0)?30:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?50:40:25]};function re(e){return t.race.witch_hunter&&"magocracy"===e?F("witch_hunter_magocracy"):F(`govern_${e}_desc`)}function se(){if(0===$("#foreign").length&&!t.race.cataclysm&&(!t.tech.world_control||t.race.truepath)&&!t.tech.isolation){let a=$('
    ');a.append($(`

    ${F("civics_foreign")}

    `)),$("#r_govern0").append(a);var e={template:''};let r=t.race.truepath?5:3;for(let e=0;e{{ '${e}' | gov }} - ${F("civics_garrison_occupy")} - ${F("civics_garrison_annex")} - ${F("civics_garrison_purchase")}
    `);a.append(t);let r=$("
    ");r.append($(``)),r.append($(``)),r.append($(``)),t.append(r),t.append($(`
    ${F("civics_gov_mil_rate")}: {{ f${e}.mil | military(${e}) }} ({{ f${e}.mil }})
    `)),t.append($(`
    ${F("civics_gov_relations")}: {{ f${e}.hstl | relation }} ({{ f${e}.hstl | hate }})
    `)),t.append($(`
    ${F("civics_gov_eco_rate")}: {{ f${e}.eco | eco(${e}) }} ({{ f${e}.eco }})
    `)),t.append($(`
    ${F("civics_gov_unrest")}: {{ f${e}.unrest | discontent(${e}) }} ({{ f${e}.unrest | turmoil }})
    `))}let s={f0:t.civic.foreign.gov0,f1:t.civic.foreign.gov1,f2:t.civic.foreign.gov2,t:t.tech};t.race.truepath&&(s.f3=t.civic.foreign.gov3,s.f4=t.civic.foreign.gov4),sc({el:"#foreign",data:s,filters:{military:(e,a)=>t.civic.foreign[`gov${a}`].spy>=1?F(e<50?"civics_gov_v_weak":e<75?"civics_gov_weak":e>300?"civics_gov_superpower":e>200?"civics_gov_v_strong":e>160?"civics_gov_strong":e>125?"civics_gov_above_average":"civics_gov_average"):"???",relation:e=>F(e>80?"civics_gov_hated":e>60?"civics_gov_hostile":e>40?"civics_gov_poor":e>25?"civics_gov_neutral":e>10?"civics_gov_liked":"civics_gov_good"),eco:(e,a)=>t.civic.foreign[`gov${a}`].spy>=2?F(e<60?"civics_gov_weak":e<80?"civics_gov_recession":e>120?"civics_gov_strong":"civics_gov_average"):"???",discontent:(e,a)=>t.civic.foreign[`gov${a}`].spy>=3?F(e<=0?"civics_gov_none":e<30?"civics_gov_low":e<60?"civics_gov_medium":e<90?"civics_gov_high":"civics_gov_extreme"):"???",gov:e=>ee(e),sab:e=>"none"===e?"":F(`civics_spy_${e}`),hate:e=>100-e+"%",turmoil:e=>`${e}%`},methods:{campaign(e){be(e)},battleAssessment:e=>ye(e),trigModal(a){this.$buefy.modal.open({parent:this,component:e});var r=setInterval((function(){$("#modalBox").length>0&&(clearInterval(r),function(e){$("#modalBox").append($(`

    ${F("civics_espionage_actions")}

    `));var a=$('
    ');$("#modalBox").append(a),t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(a.append($(``)),a.append($(``)),e<3&&a.append($(``)),e<3&&t.civic.foreign[`gov${e}`].hstl<=50&&t.civic.foreign[`gov${e}`].unrest>=50&&a.append($(``)),e<3&&t.civic.foreign[`gov${e}`].spy>=3&&a.append($(``))),sc({el:"#espModal",data:t.civic.foreign[`gov${e}`],methods:{influence(e){t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(de("influence",e),sc({el:"#espModal"},"destroy"),$(".modal-background").click(),Ei())},sabotage(e){t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(de("sabotage",e),sc({el:"#espModal"},"destroy"),$(".modal-background").click(),$("#popGov").hide(),Ei())},incite(e){e>=3||t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(de("incite",e),sc({el:"#espModal"},"destroy"),$(".modal-background").click(),Ei())},annex(a){if(!(a>=3)&&t.civic.foreign[`gov${e}`].hstl<=50&&t.civic.foreign[`gov${e}`].unrest>=50&&t.city.morale.current>=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest&&t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&0===t.civic.foreign[`gov${a}`].sab){let e=t.tech.spy>=4?150:300;t.race.befuddle&&(e=Math.round(e*(1-ui.befuddle.vars()[0]/100)));let r=Pi("dryad");r>0&&(e=Math.round(e*(1-ui.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="annex",sc({el:"#espModal"},"destroy"),$(".modal-background").click(),Ei()}},purchase(e){if(e>=3)return;let a=le(e);if(a<=t.resource.Money.amount&&t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=3&&0===t.civic.foreign[`gov${e}`].sab){t.resource.Money.amount-=a;let r=t.tech.spy>=4?150:300;t.race.befuddle&&(r=Math.round(r*(1-ui.befuddle.vars()[0]/100)));let s=Pi("dryad");s>0&&(r=Math.round(r*(1-ui.befuddle.vars(1)[0]/100*s))),t.civic.foreign[`gov${e}`].sab=r,t.civic.foreign[`gov${e}`].act="purchase",sc({el:"#espModal"},"destroy"),$(".modal-background").click(),Ei()}}}}),Ti("GovLabel",(function(a){let r=$(a.this).data("esp"),s="";if("purchase"===r){let t=le(e).toLocaleString();s=F(`civics_spy_${r}_desc`,[ee(e),t])}else if("annex"===r)if(t.city.morale.current>=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest)s=F(`civics_spy_${r}_desc`,[ee(e)]);else{let a=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest;s=F(`civics_spy_${r}_goal`,[ee(e),a])}else s=F(`civics_spy_${r}_desc`,[ee(e)]);let i="";return("influence"===r&&0===t.civic.foreign[`gov${e}`].hstl||"sabotage"===r&&t.civic.foreign[`gov${e}`].spy>=2&&50===t.civic.foreign[`gov${e}`].mil||"incite"===r&&t.civic.foreign[`gov${e}`].spy>=4&&100===t.civic.foreign[`gov${e}`].unrest)&&(i=`
    ${F("civics_spy_warning")}
    `),$(`${i}
    ${s}
    `)}),{elm:"#espModal button",self:!0,classes:"has-background-light has-text-dark"})}(a))}),50)},spy_disabled:e=>t.civic.foreign[`gov${e}`].trn>0||oe(e)>t.resource.Money.amount,spy(e){ne(e)},spyDesc:e=>ie(e),espDesc:()=>ce(),vis:()=>!(!t.civic.garrison.display||t.tech.world_control&&!t.race.truepath||t.race.cataclysm||t.tech.isolation),gvis:e=>!t.tech.isolation&&(e<=2?!t.tech.world_control:3===e&&!!t.tech.rival)}});for(let e=0;e{{ label() }}"}),{elm:`#gov${e} .attack`,in:function(t){sc({el:`#${t.id} > span`,data:{test:"val"},methods:{label:()=>ye(e)}})},out:function(e){sc({el:e.id},"destroy")}}),Ti(`gov${e}ts`,(function(){return"{{ label() }}"}),{elm:`#gov${e} .tspy`,in:function(t){sc({el:`#${t.id} > span`,data:{test:"val"},methods:{label:()=>ie(e)}})},out:function(e){sc({el:e.id},"destroy")}}),Ti(`gov${e}s`,(function(){return ce()}),{elm:`#gov${e} .sspy`});t.race.truepath&&Ti("garRivaldesc1",(function(){return F("civics_gov_tp_rival",[ee(3),di[t.race.species].home])}),{elm:"#gov3 > span"})}}function ie(e){return t.civic.foreign[`gov${e}`].trn>0?F("civics_progress"):F("civics_gov_spy_desc",[k(oe(e))])}function ce(){return F("civics_gov_esp_desc")}function oe(e){let a=Math.round(t.civic.foreign[`gov${e}`].mil/2+t.civic.foreign[`gov${e}`].hstl/2-t.civic.foreign[`gov${e}`].unrest)+10;return a<50&&(a=50),t.race.infiltrator&&(a/=3),"scorpio"===U()&&(a*=1-H("scorpio")[0]/100),Math.round(a**(t.civic.foreign[`gov${e}`].spy+1))+500}function ne(e){if(t.tech.spy&&0===t.civic.foreign[`gov${e}`].trn){let a=oe(e);if(t.resource.Money.amount>=a){t.resource.Money.amount-=a;let r=300;t.tech.spy>=3&&t.city.boot_camp&&(r-=10*(t.race.orbit_decayed&&t.space.space_barracks?t.space.space_barracks.on:t.city.boot_camp.count),r<10&&(r=10)),t.race.infiltrator&&(r=Math.round(r/2)),t.civic.foreign[`gov${e}`].trn=r}}}function le(e){let a=15384*t.civic.foreign[`gov${e}`].eco;return a*=1+1.6*t.civic.foreign[`gov${e}`].hstl/100,a*=1-.25*t.civic.foreign[`gov${e}`].unrest/100,+a.toFixed(0)}function ue(e){return e?t.tech.world_control||t.civic.foreign[e].occ||t.civic.foreign[e].anx||t.civic.foreign[e].buy:t.civic.foreign.gov0.occ||t.civic.foreign.gov1.occ||t.civic.foreign.gov2.occ||t.civic.foreign.gov0.anx||t.civic.foreign.gov1.anx||t.civic.foreign.gov2.anx||t.civic.foreign.gov0.buy||t.civic.foreign.gov1.buy||t.civic.foreign.gov2.buy}function de(e,a){switch(e){case"influence":if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&0===t.civic.foreign[`gov${a}`].sab){let e=t.tech.spy>=4?200:300;t.race.befuddle&&(e=Math.round(e*(1-ui.befuddle.vars()[0]/100)));let r=Pi("dryad");r>0&&(e=Math.round(e*(1-ui.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="influence"}break;case"sabotage":if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&0===t.civic.foreign[`gov${a}`].sab){let e=t.tech.spy>=4?400:600;t.race.befuddle&&(e=Math.round(e*(1-ui.befuddle.vars()[0]/100)));let r=Pi("dryad");r>0&&(e=Math.round(e*(1-ui.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="sabotage"}break;case"incite":if(a>=3)break;if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&0===t.civic.foreign[`gov${a}`].sab){let e=t.tech.spy>=4?600:900;t.race.befuddle&&(e=Math.round(e*(1-ui.befuddle.vars()[0]/100)));let r=Pi("dryad");r>0&&(e=Math.round(e*(1-ui.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="incite"}}}function _e(e){let a=!!(t.tech.currency&&t.tech.currency>=5);if(e)return!a&&!t.race.terrifying||t.race.noble?t.race.noble?ui.noble.vars()[0]:10:0;{let e=30;t.race.noble?e=ui.noble.vars()[1]:(a||t.race.terrifying)&&(e+=20),"oligarchy"===t.civic.govern.type&&(e+=ae.oligarchy()[1]);let r=N("aristocrat",1);return r&&(e+=r),e}}function pe(e,a){switch(e){case"add":{let e=a||y(),r=_e(!1);t.race.noble?(t.civic.taxes.tax_rate+=e,t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?40:20)&&(t.civic.taxes.tax_rate="oligarchy"===t.civic.govern.type?40:20)):t.civic.taxes.tax_rater&&(t.civic.taxes.tax_rate=r))}break;case"sub":{let e=a||y(),r=_e(!0);t.civic.taxes.tax_rate>r&&(t.civic.taxes.tax_rate-=e,t.civic.taxes.tax_rate25e3&&(e=25e3),t.civic.garrison.m_use>0&&(e*=1.1**t.civic.garrison.m_use),t.race.brute&&(e*=1-ui.brute.vars()[0]/100);let a=Pi("orc");return a>0&&(e*=1-ui.brute.vars(1)[0]/100*a),t.race.inflation&&(e*=1+t.race.inflation/500),t.race.high_pop&&(e*=ui.high_pop.vars()[1]/100),Math.round(e)}function ge(e){if(t.tech.mercs){let a=e||y(),r=!0;for(;r&&a>0;){let e=me();t.civic.garrison.workers=e?(t.resource.Money.amount-=e,t.civic.garrison.workers++,t.civic.garrison.m_use++):r=!1,a--}}}function fe(e,a){rc(e),t.tech.world_control&&!t.race.truepath?e.append($(`

    ${F("civics_garrison")}

    - ${F("rating")} {{ g.workers | hell | rating }}
    `)):e.append($(`

    ${F("civics_garrison")}

    - ${F("rating")} {{ g.workers | hell | rating }} / {{ g.raid | rating }}
    `));var r=$('
    ');e.append(r);var s=$('
    ');r.append(s);let i=t.tech.world_control&&!t.race.truepath?F("civics_garrison_peacekeepers"):F("civics_garrison_soldiers");if(t.tech.isolation||(s.append($(`
    ${i} / {{ g.max | s_max }}
    `)),s.append($(`
    ${F("civics_garrison_crew")} {{ g.crew }}
    `)),s.append($(`
    ${F("civics_garrison_wounded")}
    `)),r.append($(`
    `))),a){let a="";t.tech.isolation&&(a=$c(8,12)),e.append($(`
    ${F("civics_garrison_training")} - ${F("arpa_to_complete")} {{ g.rate, g.progress | trainTime }}${a} {{ g.progress }}%
    `))}var c=$('
    ');e.append(c);var o=$('
    ');if(c.append(o),(!t.tech.world_control||t.race.truepath)&&!t.race.cataclysm&&!t.tech.isolation){var n=$(`
    ${F("civics_garrison_campaign")}
    `);o.append(n);var l=$('{{ g.tactic | tactics }}'),u=$('«'),d=$('»');n.append(u),n.append(l),n.append(d);var _=$(`
    ${F("civics_garrison_battalion")}
    `);o.append(_);var p=$('{{ g.raid }}'),h=$('«'),m=$('»');_.append(h),_.append(p),_.append(m),a&&(t.race.truepath&&t.tech.rival&&c.append($(`
    ${ee(3)}
    `)),t.tech.world_control||(c.append($(`
    ${ee(0)}
    `)),c.append($(`
    ${ee(1)}
    `)),c.append($(`
    ${ee(2)}
    `))))}let g={g:t.civic.garrison,g0:t.civic.foreign.gov0,g1:t.civic.foreign.gov1,g2:t.civic.foreign.gov2};if(t.race.truepath&&(g.g3=t.civic.foreign.gov3,g.g4=t.civic.foreign.gov4),sc({el:a?"#garrison":"#c_garrison",data:g,methods:{hire(){ge()},campaign(e){be(e)},next(){t.civic.garrison.tactic<4&&t.civic.garrison.tactic++},last(){t.civic.garrison.tactic>0&&t.civic.garrison.tactic--},aNext(){let e=y();t.civic.garrison.raidqe()&&(t.civic.garrison.raid=qe()))},aLast(){let e=y();t.civic.garrison.raid>0&&(t.civic.garrison.raid-=e,t.civic.garrison.raid<0&&(t.civic.garrison.raid=0))},vis:()=>t.civic.garrison.display,rvis:()=>!(!t.tech.rival||t.tech.isolation)},filters:{tactics(e){switch(e){case 0:return F("civics_garrison_tactic_ambush");case 1:return F("civics_garrison_tactic_raid");case 2:return F("civics_garrison_tactic_pillage");case 3:return F("civics_garrison_tactic_assault");case 4:return F("civics_garrison_tactic_siege")}},rating:e=>+ke(e,"army").toFixed(1),hell:e=>qe(),stationed(e){let r=qe(),s=t.race.cataclysm?13:31,i=r===s&&!a&&kc(2,14,!0);return r===s&&i.length>0?i:r},s_max:e=>qe(!0),wounded(e){let t=$c(8,12);return a&&0===e&&t.length>0?t:Tc("fool",2021)?qe()-e:e},trainTime:(e,t)=>ic(0===e?-1:(100-t)/(4*e))}}),["tactic","bat","soldier","crew","wounded","hmerc","defenseRating","offenseRating"].forEach((function(e){Ti(a?`garrison${e}`:`cGarrison${e}`,(function(){return"{{ label() }}"}),{elm:`${a?"#garrison":"#c_garrison"} .${e}`,in:function(a){sc({el:`#${a.id} > span`,data:{test:"val"},methods:{label(){switch(e){case"tactic":switch(t.civic.garrison.tactic){case 0:return F("civics_garrison_tactic_ambush_desc");case 1:return F("civics_garrison_tactic_raid_desc");case 2:return F("civics_garrison_tactic_pillage_desc");case 3:return F("civics_garrison_tactic_assault_desc");case 4:return F("civics_garrison_tactic_siege_desc",[la("federation"===t.civic.govern.type?15:20)])}case"bat":return F("civics_garrison_army_label");case"soldier":return ve();case"crew":return F("civics_garrison_crew_desc");case"wounded":return F("civics_garrison_wounded_desc");case"hmerc":return F("civics_garrison_hire_mercenary_cost",[Math.round(me()).toLocaleString()]);case"defenseRating":return F("civics_garrison_defensive_rate");case"offenseRating":return F("civics_garrison_offensive_rate")}}}})},out:function(e){sc({el:e.id},"destroy")}})})),a){let e=t.race.truepath?4:3;for(let t=0;t{{ label() }}"}),{elm:`#garrison .gov${t} button`,in:function(e){sc({el:`#${e.id} > span`,data:{test:"val"},methods:{label:()=>ye(t)}})},out:function(e){sc({el:e.id},"destroy")}});t.race.truepath&&!t.tech.isolation&&Ti("garRivaldesc2",(function(){return F("civics_gov_tp_rival",[ee(3),di[t.race.species].home])}),{elm:"#garrison .gov3 > div"})}}function ve(){let e=ke(qe(),"hunting"),a=[];if((!t.race.herbivore||t.race.carnivore)&&!t.race.artifical){let r=+(e/3).toFixed(2);a.push(r,t.resource.Food.name)}let r=+(e/10).toFixed(2);if(a.push(r,t.resource.Furs.name),t.race.evil&&!t.race.kindling_kindred&&!t.race.smoldering){let r=+(e/(t.race.soul_eater?3:5)).toFixed(2);a.push(r,t.resource.Lumber.name)}let s="civics_garrison_soldier_loot"+a.length/2;return F(t.race.evil&&t.race.soul_eater?"civics_garrison_soldier_evil_desc":"civics_garrison_soldier_desc")+F(s,a)}function ye(e){if(t.civic.foreign[`gov${e}`].occ)return F("civics_garrison_deoccupy_desc");if(t.civic.foreign[`gov${e}`].buy||t.civic.foreign[`gov${e}`].anx)return F("civics_garrison_secede_desc");if(t.civic.garrison.tactic<=1&&t.civic.foreign[`gov${e}`].spy<1||t.civic.garrison.tactic>=2&&t.civic.garrison.tactic<=3&&t.civic.foreign[`gov${e}`].spy<2||4===t.civic.garrison.tactic&&t.civic.foreign[`gov${e}`].spy<3)return F("civics_garrison_no_spy");let a=ke(t.civic.garrison.raid,"army"),r=0;switch(t.civic.garrison.tactic){case 0:r=5;break;case 1:r=27.5;break;case 2:r=62.5;break;case 3:r=125;break;case 4:r=300}return r*=t.civic.foreign[`gov${e}`].mil/100,t.race.banana&&(r*=2),"swamp"===t.city.biome&&(r*=ji.swamp.vars()[0]),Tc("fool",2021)&&(r/=1.25),aqe()?t.civic.garrison.raid=qe():t.civic.garrison.raid<0&&(t.civic.garrison.raid=0),0===t.civic.garrison.raid)return void Di(F("civics_garrison_campaign_no_soldier"),"warning",!1,["combat"]);t.stats.attacks++;let a=t.race.claws?20:16,r=t.race.puny?3:5,s=Math.floor(m(r,a,!0))/10,i=ke(t.civic.garrison.raid,"army")*s,c=0;switch(t.civic.garrison.tactic){case 0:c=m(0,10,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(0,2,!0));break;case 1:c=m(5,50,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(0,3,!0));break;case 2:c=m(25,100,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(1,5,!0));break;case 3:c=m(50,200,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(4,12,!0));break;case 4:c=m(100,500,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(10,25,!0))}c=Math.floor(c*t.civic.foreign[`gov${e}`].mil/100),t.race.banana&&(c*=2),"swamp"===t.city.biome&&(c*=ji.swamp.vars()[0]),t.race.mistrustful&&(t.civic.foreign[`gov${e}`].hstl+=ui.mistrustful.vars()[0]),t.civic.foreign[`gov${e}`].hstl>100&&(t.civic.foreign[`gov${e}`].hstl=100),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(c/5),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0]));let o=0;if(t.civic.garrison.raid>t.civic.garrison.workers-t.civic.garrison.crew-t.civic.garrison.wounded&&(o=t.civic.garrison.raid-(t.civic.garrison.workers-t.civic.garrison.crew-t.civic.garrison.wounded)),t.civic.garrison.fatigue++,i>c){let a=Math.floor(t.civic.garrison.raid/(5-t.civic.garrison.tactic));a+=o,t.city.ptrait.includes("rage")&&(a+=Si.rage.vars()[2]),a<1&&(a=1),a>we()&&(a=we());let r=Math.floor(m(0,a,!0));t.race.frail&&(r+=ui.frail.vars()[0]);let s=0;if(t.race.scales&&(s+=ui.scales.vars()[0]),t.tech.armor&&(s+=t.tech.armor),t.race.high_pop&&(s+=Math.floor(m(0,s*ui.high_pop.vars()[0],!0))),t.race.armored){let e=1-ui.armored.vars()[0]/100;s+=Math.floor(r*e)}let i=Pi("tortoisan");if(i>0){let e=1-ui.armored.vars(1)[0]/100*i;s+=Math.floor(r*e)}if(t.civic.garrison.raid>o&&(r-=s),r<0&&(r=0),r>t.civic.garrison.raid&&(r=t.civic.garrison.raid),t.race.instinct){let e=Math.floor(r*(ui.instinct.vars()[1]/100));r-=e,o+=e}t.civic.garrison.workers-=r,t.stats.died+=r,t.civic.garrison.protest+=r,r>o?(t.civic.garrison.wounded-=o,o=0):(t.civic.garrison.wounded-=r,o-=r),t.civic.garrison.wounded+=Math.floor(m(o,t.civic.garrison.raid-r,!0));let c={Money:0,Food:0,Lumber:0,Stone:0,Copper:0,Iron:0,Aluminium:0,Coal:0,Cement:0,Steel:0,Titanium:0,Crystal:0,Chrysotile:0,Furs:0,Iridium:0,Alloy:0,Polymer:0,Oil:0},n=3===e&&t.race.truepath?["Food","Lumber","Stone","Copper","Iron"]:["Food","Lumber","Stone"],l=3===e&&t.race.truepath?["Aluminium","Coal","Cement","Steel","Furs"]:["Copper","Iron","Aluminium","Coal"],u=3===e&&t.race.truepath?["Titanium","Oil","Iridium","Alloy","Polymer"]:["Cement","Steel"];t.race.artifical&&n.shift(),t.race.smoldering&&n.push("Chrysotile"),t.race.terrifying&&3!==e&&u.push("Titanium"),t.tech.magic&&u.push("Crystal");let d=["Money"];switch(t.civic.garrison.tactic){case 0:{let e=["Money"].concat(n,l);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))]),t.resource.Steel.amount<25&&t.tech.smelting&&1===t.tech.smelting&&0===Math.floor(m(0,20,!0))&&d.push("Steel")}break;case 1:{let e=["Money"].concat(n,l,u);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 2:{let e=["Money"].concat(n,l,u),a=l.concat(u);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),d.push(a[Math.floor(m(0,a.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 3:{let e=["Money"].concat(n,l,u);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(u[Math.floor(m(0,u.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 4:{let e=["Money"].concat(n,l,u);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(u[Math.floor(m(0,u.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}}let _=t.race.terrifying&&3!==e?ui.terrifying.vars()[0]:12,p=t.race.terrifying&&3!==e?ui.terrifying.vars()[1]:32;d.forEach((function(e){switch(e){case"Money":c[e]+=Math.floor(m(100,375,!0));break;case"Food":c[e]+=Math.floor(m(40,175,!0));break;case"Lumber":case"Stone":c[e]+=Math.floor(m(50,250,!0));break;case"Copper":case"Iron":case"Aluminium":c[e]+=Math.floor(m(35,125,!0));break;case"Coal":case"Cement":c[e]+=Math.floor(m(25,100,!0));break;case"Steel":case"Chrysotile":c[e]+=Math.floor(m(20,65,!0));break;case"Titanium":c[e]+=Math.floor(m(_,p,!0));break;case"Crystal":c[e]+=Math.floor(m(1,5,!0));break;case"Oil":c[e]+=Math.floor(m(20,50,!0));break;case"Iridium":c[e]+=Math.floor(m(2,30,!0));break;case"Alloy":case"Polymer":c[e]+=Math.floor(m(5,38,!0))}}));let h=F("civics_garrison_gained");t.resource.Money.display&&c.Money>0&&(c.Money=$e(c.Money,e),h+=F("civics_garrison_quant_money",[c.Money]),Vi("Money",c.Money)),n.concat(l,u).forEach((function(a){c[a]>0&&(t.resource[a].display||"Steel"===a||"Titanium"===a)&&(c[a]=$e(c[a],e),h+=F("civics_garrison_quant_res",[c[a],t.resource[a].name]),Vi(a,c[a]),"Steel"!==a&&"Titanium"!==a||(t.resource[a].display=!0))})),h=h.slice(0,-2),h+=".",Di(h,"warning",!1,["combat"]);let g=0;if(t.race.revive){switch(t.city.calendar.temp){case 0:g=Math.floor(m(0,Math.floor(r/ui.revive.vars()[0]),!0));break;case 1:g=Math.floor(m(0,Math.floor(r/ui.revive.vars()[1]),!0));break;case 2:g=Math.floor(m(0,Math.floor(r/ui.revive.vars()[2]),!0))}t.civic.garrison.workers+=g}if(Di(g>0?F("civics_garrison_victorious_revive",[r,g]):F("civics_garrison_victorious",[r]),"success",!1,["combat"]),t.race.slaver&&t.city.slave_pen){let e=4*t.city.slave_pen.count;if(e>t.city.slave_pen.slaves){let a=Math.floor(m(0,t.civic.garrison.tactic+2,!0));a+t.city.slave_pen.slaves>e&&(a=e-t.city.slave_pen.slaves),a>0&&(t.city.slave_pen.slaves+=a,t.resource.Slave.amount=t.city.slave_pen.slaves,Di(F("civics_garrison_capture",[a]),"success",!1,["combat"]))}}if(t.race.infectious){let e=0;switch(t.civic.garrison.tactic){case 0:e=Math.floor(m(0,ui.infectious.vars()[0],!0));break;case 1:e=Math.floor(m(0,ui.infectious.vars()[1],!0));break;case 2:e=Math.floor(m(0,ui.infectious.vars()[2],!0));break;case 3:e=Math.floor(m(0,ui.infectious.vars()[3],!0));break;case 4:e=Math.floor(m(0,ui.infectious.vars()[4],!0))}t.resource[t.race.species].amount+e>t.resource[t.race.species].max&&(e=t.resource[t.race.species].max-t.resource[t.race.species].amount),e>0&&(t.resource[t.race.species].amount+=e,"unemployed"!==t.civic.d_job&&(t.civic[t.civic.d_job].workers+=e),Di(1===e?F("civics_garrison_soldier_infected"):F("civics_garrison_soldiers_infected",[e]),"special",!1,["combat"]))}let f=la("federation"===t.civic.govern.type?15:20);if(e<=2&&4===t.civic.garrison.tactic&&t.civic.garrison.workers>=f){let a=!t.tech.gov_fed&&!ue();if(t.civic.garrison.workers-=f,t.civic.foreign[`gov${e}`].occ=!0,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none",a&&ms(),t.race.banana){let e=Yc();t.stats.banana.b1[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b1.l=!0)}}}else{let e=t.civic.garrison.raid;e+=o,0===t.civic.garrison.tactic&&(e=Math.floor(e/2)),t.city.ptrait.includes("rage")&&(e+=Si.rage.vars()[2]),e<1&&(e=1),e>we()&&(e=we());let a=Math.floor(m(1,e,!0));t.race.frail&&(a+=t.civic.garrison.tactic+ui.frail.vars()[1]);let r=0;if(t.race.scales&&(r+=ui.scales.vars()[1]),t.tech.armor&&(r+=t.tech.armor),t.race.high_pop&&(r+=Math.floor(m(0,Math.floor(r*ui.high_pop.vars()[0]/2),!0))),t.race.armored){let e=ui.armored.vars()[0]/100;r+=Math.floor(a*e)}let s=Pi("tortoisan");if(s>0){let e=ui.armored.vars(1)[0]/100*s;r+=Math.floor(a*e)}if(t.civic.garrison.raid>o&&(a-=r),t.race.instinct){let e=Math.floor(a*(ui.instinct.vars()[1]/100));a-=e,o+=e}a<1&&(a=1),a>t.civic.garrison.raid&&(a=t.civic.garrison.raid),t.civic.garrison.workers-=a,t.stats.died+=a,t.civic.garrison.protest+=a,a>o?(t.civic.garrison.wounded-=o,o=0):(t.civic.garrison.wounded-=a,o-=a),t.civic.garrison.wounded+=1+Math.floor(m(o,t.civic.garrison.raid-a,!0));let i=0;if(t.race.revive){switch(t.city.calendar.temp){case 0:i=Math.floor(m(0,Math.floor(a/ui.revive.vars()[3]),!0));break;case 1:i=Math.floor(m(0,Math.floor(a/ui.revive.vars()[4]),!0));break;case 2:i=Math.floor(m(0,Math.floor(a/ui.revive.vars()[5]),!0))}t.civic.garrison.workers+=i}Di(i>0?F("civics_garrison_defeat_revive",[a,i]):F("civics_garrison_defeat",[a]),"danger",!1,["combat"])}t.civic.garrison.wounded>t.civic.garrison.workers-t.civic.garrison.crew?t.civic.garrison.wounded=t.civic.garrison.workers-t.civic.garrison.crew:t.civic.garrison.wounded<0&&(t.civic.garrison.wounded=0)}function we(){let e=0,a=t.civic.garrison.raid;switch(t.civic.garrison.tactic){case 0:e=5;break;case 1:e=10;break;case 2:e=25;break;case 3:e=50;break;case 4:e=999}return t.race.high_pop&&(e=la(e)),a>e&&(a=e),a}function $e(e,a){let r=we();t.race.high_pop&&(r/=la(1));let s=e*Math.log(r+1);switch(t.race.invertebrate&&(s*=1-ui.invertebrate.vars()[0]/100),"evil"===t.race.universe&&(s*=nc("evil")),t.civic.garrison.tactic){case 1:s*=4;break;case 2:s*=30;break;case 3:s*=100;break;case 4:s*=400}return t.race.banana&&(s*=.5),"swamp"===t.city.biome&&(s*=ji.swamp.vars()[1]),Math.floor(s*t.civic.foreign[`gov${a}`].eco/100)}function xe(){let e=t.tech.military?t.tech.military>=5?t.tech.military-1:t.tech.military:1;if(t.tech.military&&t.tech.military>1){e-=t.tech.military>=11?2:1,t.race.sniper&&(e*=1+ui.sniper.vars()[0]/100*e);let a=Pi("centaur");a>0&&(e*=1+ui.sniper.vars(1)[0]/100*e*a),e+=t.tech.military>=11?2:1}return e}function ke(e,a,r){if(!t.civic.hasOwnProperty("garrison"))return 1;let s=0;"number"==typeof r?s=r:e>t.civic.garrison.workers-t.civic.garrison.wounded&&(s=e-(t.civic.garrison.workers-t.civic.garrison.wounded));let i=xe(),c=Pi("rhinotaur"),o=e-s/2;(t.race.rage||c>0)&&(o=e+(t.race.rage?s*ui.rage.vars()[1]/100:0)+(c>0?s*ui.rage.vars(1)[1]/100*c:0));let n=t.tech.military?o*i:o;if("army"===a||"hellArmy"===a){t.race.rage&&(n*=1+ui.rage.vars()[0]/100*(t.civic.garrison.wounded||0)),c>0&&(n*=1+ui.rage.vars(1)[0]/100*c*(t.civic.garrison.wounded||0)),t.race.puny&&(n*=1-ui.puny.vars()[0]/100),t.race.claws&&(n*=1+ui.claws.vars()[0]/100);let r=Pi("scorpid");r>0&&(n*=1+ui.claws.vars(1)[0]/100*r),t.race.chameleon&&(n*=1+ui.chameleon.vars()[0]/100),t.race.cautious&&0===t.city.calendar.weather&&(n*=1-ui.cautious.vars()[0]/100),t.race.apex_predator&&(n*=1+ui.apex_predator.vars()[0]/100);let s=Pi("sharkin");s>0&&(n*=1+ui.apex_predator.vars(1)[0]/100*s),t.race.swift&&(n*=1+ui.swift.vars()[0]/100),t.race.fiery&&(n*=1+ui.fiery.vars()[0]/100);let i=Pi("balorg");i>0&&(n*=1+ui.fiery.vars(1)[0]/100*i),t.race.sticky&&(n*=1+ui.sticky.vars()[1]/100);let o=Pi("pinguicula");o>0&&(n*=1+ui.sticky.vars(1)[1]/100*o),t.race.pathetic&&(n*=1-ui.pathetic.vars()[0]/100),t.race.tactical&&(n*=1+ui.tactical.vars()[0]*t.race.tactical/100),t.tech.fanaticism&&t.tech.fanaticism>=4&&(n*=1+.01*t.city.temple.count),t.race.holy&&"hellArmy"===a&&(n*=1+ui.holy.vars()[0]/100);let l=Pi("unicorn");l>0&&"hellArmy"===a&&(n*=1+ui.holy.vars(1)[0]/100*l),t.race.banana&&"hellArmy"===a&&(n*=.8),"aries"===U()&&(n*=1+H("aries")[0]/100);let u=N("tactician",0);if(u&&(n*=1+u/100),t.city.ptrait.includes("rage")&&(n*=Si.rage.vars()[0]),t.race.parasite&&(1===e?n+=2:e>1&&(n+=4)),t.tech.psychic&&t.race.psychicPowers&&t.race.psychicPowers.hasOwnProperty("assaultTime")){let e=0;if(t.race.psychicPowers.assaultTime>0&&(e+=ui.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(ui.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.assault).toFixed(3)}n*=1+e}}return"hunting"===a&&t.race.unfathomable&&(n*=.66),t.race.rejuvenated&&(n*=1.05),"autocracy"===t.civic.govern.type&&(n*=1+ae.autocracy()[1]/100),n=Math.floor(n),n*pi(e,a)}function qe(e,a){if(!t.civic.garrison)return 0;let r=e?"max":"workers",s=t.portal.fortress?t.portal.fortress.garrison:0,i=t.space.fob&&!a?t.space.fob.troops:0;return t.civic.garrison[r]-t.civic.garrison.crew-s-i}function Me(e){return t.race.high_pop&&(e*=ui.high_pop.vars()[1]/100),e}function Pe(e,a){switch(e){case"transmitter":return 2.5;case"oil_well":{let e=t.tech.oil>=4?.48:.4;t.tech.oil>=7?e*=2:t.tech.oil>=5&&(e*=t.tech.oil>=6?1.75:1.25),t.city.geology.Oil&&(e*=t.city.geology.Oil+1),"desert"===t.city.biome?e*=ji.desert.vars()[1]:"tundra"===t.city.biome?e*=ji.tundra.vars()[1]:"taiga"===t.city.biome&&(e*=ji.taiga.vars()[2]);let a=N("dirty_jobs",2);return a&&(e*=1+a/100),e}case"iridium_mine":switch(a){case"iridium":{let e=.035;t.city.geology.Iridium&&(e*=t.city.geology.Iridium+1);let a=e,r=X(3);return{b:a,g:r-1,f:a*r}}case"coal":return.55}case"helium_mine":{let e=.18,t=X(3);return{b:e,g:t-1,f:e*t}}case"red_mine":switch(a){case"copper":{let e=Me(.25),t=X(3);return{b:e,g:t-1,f:e*t}}case"titanium":{let e=Me(.02),t=X(3);return{b:e,g:t-1,f:e*t}}case"stone":return Me(.75);case"asbestos":return Me(1.25);case"aluminium":return Me(.066)}case"biodome":switch(a){case"food":return Me(.25);case"cat_food":return 2;case"lumber":return Me(1.5)}case"gas_mining":return t.tech.helium?.65:.5;case"outpost":{let e={b:.025,d:0,n:0};if(t.tech.drone){let a=t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3?.12:.06;e.d=t.space.drone.count*a,e.n=e.b*(1+e.d)}else e.n=e.b;return a?e:e.n}case"oil_extractor":{let e=t.tech.oil>=4?.48:.4;return t.tech.oil>=7?e*=2:t.tech.oil>=5&&(e*=t.tech.oil>=6?1.75:1.25),e}case"elerium_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?.009:.0075:.005;case"iridium_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?.1:.08:.055;case"iron_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?4:3:2;case"g_factory":if(t.race.truepath){if(t.tech.isolation)return 1.8;{let e=.05*(i.ai_colonist?t.civic.titan_colonist.workers+la(i.ai_colonist):t.civic.titan_colonist.workers);return t.race.high_pop&&(e=Me(e)),e}}return.6;case"harvester":switch(a){case"helium":return.85;case"deuterium":return.15}case"elerium_prospector":return.014;case"neutron_miner":return.055;case"bolognium_ship":return.008;case"excavator":return.2;case"vitreloy_plant":{let e=.18;return"corpocracy"===t.civic.govern.type&&(e*=t.tech.high_tech&&t.tech.high_tech>=16?1.4:1.3),"socialist"===t.civic.govern.type&&(e*=1.1),e}case"infernite_mine":return.5*Oa("gate").supress;case"water_freighter":return 1.25;case"titan_mine":switch(a){case"adamantite":return Me(.02)*(t.space.titan_mine?t.space.titan_mine.ratio:50)/100;case"aluminium":return Me(.12)*(100-(t.space.titan_mine?t.space.titan_mine.ratio:50))/100}case"lander":return 100===t.space.crashed_ship.count?.005:0;case"orichalcum_mine":return.08;case"uranium_mine":return.025;case"neutronium_mine":return.04;case"elerium_mine":return.009;case"shock_trooper":case"tank":return 100===t.space.digsite.count?.0018:0;case"mining_pit":{let e=0;switch(a){case"materials":e=t.tech.isolation?.12:.09;break;case"bolognium":e=t.tech.isolation?.0288:.0216;break;case"stone":e=t.tech.isolation?.8:.6;break;case"adamantite":e=t.tech.isolation?.448:.336;break;case"copper":e=.58;break;case"coal":e=.13;break;case"iron":e=.74;break;case"aluminium":e=.88;break;case"chrysotile":e=1.44}t.race.tough&&(e*=1+ui.tough.vars()[0]/100);let r=Pi("ogre");return r>0&&(e*=1+ui.tough.vars(1)[0]/100*r),t.tech.tau_pit_mining&&(e*=1.18),e}case"tau_farm":switch(a){case"food":return t.tech.isolation?15:9;case"lumber":return t.tech.isolation?12:5.5;case"water":return.35}case"womling_mine":{let e=1;switch(t.tech.womling_mining&&(e+=.15*t.tech.womling_mining),t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5&&(e*=1.1),t.tech.womling_gene&&(e*=1.25),a){case"unobtainium":return.0305*e;case"uranium":return.047*e;case"titanium":return.616*e;case"copper":return 1.191*e;case"iron":return 1.377*e;case"aluminium":return 1.544*e;case"neutronium":return.382*e;case"iridium":return.535*e}}case"refueling_station":return t.tech.isolation?18.5:9.35;case"ore_refinery":return t.tech.tau_ore_mining?40:25;case"whaling_station":return 12;case"mining_ship":if(t.tauceti.patrol_ship){let e=1;return t.tauceti.patrol_ship.support>t.tauceti.patrol_ship.s_max&&(e=Ac("curve",t.tauceti.patrol_ship.s_max/t.tauceti.patrol_ship.support,1.4)),(t.tech.tau_ore_mining&&t.tech.tau_ore_mining>=2?12:10)*e}return 0;case"mining_ship_ore":switch(a){case"iron":case"aluminium":return t.tech.isolation?2.22:1.85;case"iridium":case"neutronium":return t.tech.isolation?.42:.35;case"orichalcum":return t.tech.isolation?.3:.25;case"elerium":return t.tech.isolation?.024:.02}case"whaling_ship":if(t.tauceti.patrol_ship){let e=1;return t.tauceti.patrol_ship.support>t.tauceti.patrol_ship.s_max&&(e=Ac("curve",t.tauceti.patrol_ship.s_max/t.tauceti.patrol_ship.support,1.4)),8*e}return 0;case"whaling_ship_oil":return t.tech.isolation?.78:.42;case"alien_outpost":return.01;case"psychic_boost":if(t.tech.psychic&&t.race.psychic&&t.race.psychicPowers&&t.race.psychicPowers.boost.r===a&&t.race.psychicPowers.hasOwnProperty("boostTime")){let e=0;if(t.race.psychicPowers.boostTime>0&&(e+=ui.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(ui.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.boost).toFixed(3)}return 1+e}return 1;case"psychic_cash":if(t.tech.psychic&&t.race.psychic&&t.race.psychicPowers&&t.race.psychicPowers.hasOwnProperty("cash")){let e=0;if(t.race.psychicPowers.cash>0&&(e+=ui.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(ui.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.cash).toFixed(3)}return 1+e}return 1}}function Oe(e){switch(e){case"Physics":Ne();break;case"Genetics":Be();break;case"Monument":return Te();case"PhysicsTech":return Ce;case"GeneTech":return Se;case"BloodTech":return Fe;case"Crispr":Ge();break;case"Blood":Re()}}const Ce={lhc:{title:()=>Tc("fool",2022)?F("arpa_projects_railway_title"):F("arpa_projects_lhc_title"),desc:()=>Tc("fool",2022)?F("arpa_projects_railway_desc"):F("arpa_projects_lhc_desc"),reqs:{high_tech:6},grant:"supercollider",effect(e){if(Tc("fool",2022)&&!e)return Ce.railway.effect(!0);let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?t.race.cataclysm?20:8:t.race.cataclysm?10:4;return t.tech.storage>=6?t.tech.particles&&t.tech.particles>=4?t.race.cataclysm?F("arpa_projects_lhc_cataclysm3",[a]):F("arpa_projects_lhc_effect3",[a,t.race.orbit_decayed?F("space_home_satellite_title"):Ts()]):t.race.cataclysm?F("arpa_projects_lhc_cataclysm2",[a]):F("arpa_projects_lhc_effect2",[a,t.race.orbit_decayed?F("space_home_satellite_title"):Ts()]):t.race.cataclysm?F("arpa_projects_lhc_cataclysm1",[a]):t.tech.isolation?F("arpa_projects_lhc_iso1",[a,F("tech_infectious_disease_lab_alt")]):F("arpa_projects_lhc_effect1",[a,t.race.orbit_decayed?F("space_home_satellite_title"):Ts()])},cost:{Money:(e,t)=>Le("lhc",e,25e5,1.05,t),Knowledge:(e,t)=>Le("lhc",e,5e5,1.05,t),Copper:(e,t)=>Le("lhc",e,125e3,1.05,t),Cement:(e,t)=>Le("lhc",e,25e4,1.05,t),Aluminium:(e,t)=>Le("lhc",e,35e4,1.05,t),Titanium:(e,t)=>Le("lhc",e,5e4,1.05,t),Polymer:(e,t)=>Le("lhc",e,12e3,1.05,t)}},stock_exchange:{title:F("arpa_projects_stock_exchange_title"),desc:F("arpa_projects_stock_exchange_desc"),reqs:{banking:9},grant:"stock_exchange",effect:()=>t.tech.banking>=10?t.race.cataclysm?t.tech.gambling&&t.tech.gambling>=4?F("arpa_projects_stock_exchange_cataclysm2"):F("arpa_projects_stock_exchange_cataclysm1"):t.tech.gambling&&t.tech.gambling>=4?F("arpa_projects_stock_exchange_effect3"):F("arpa_projects_stock_exchange_effect2"):F("arpa_projects_stock_exchange_effect1"),cost:{Money:(e,t)=>Le("stock_exchange",e,3e6,1.06,t),Plywood:(e,t)=>Le("stock_exchange",e,25e3,1.06,t),Brick:(e,t)=>Le("stock_exchange",e,2e4,1.06,t),Wrought_Iron:(e,t)=>Le("stock_exchange",e,1e4,1.06,t)}},tp_depot:{title:F("galaxy_gateway_depot"),desc:F("arpa_projects_depot_desc"),reqs:{high_tech:6,storage:4},grant:"tp_depot",path:["truepath"],effect:()=>F(t.tech.isolation?"arpa_projects_depot_effect_iso":"arpa_projects_depot_effect",[5,50]),cost:{Money:(e,t)=>Le("tp_depot",e,18e5,1.08,t),Stone:(e,t)=>Le("tp_depot",e,75e4,1.08,t),Iron:(e,t)=>Le("tp_depot",e,25e4,1.08,t),Alloy:(e,t)=>Le("tp_depot",e,3e4,1.08,t)}},launch_facility:{id:"arpalaunch_facility",title:F("arpa_projects_launch_facility_title"),desc:F("arpa_projects_launch_facility_desc"),reqs:{high_tech:7},condition:()=>!t.race.cataclysm&&!t.race.lone_survivor,grant:"launch_facility",rank:1,queue_complete:()=>t.tech.space>=1?0:1,effect:()=>F("arpa_projects_launch_facility_effect1"),cost:{Money:e=>Le("launch_facility",e,2e6,1.1),Knowledge:e=>Le("launch_facility",e,5e5,1.1),Cement:e=>Le("launch_facility",e,15e4,1.1),Oil:e=>Le("launch_facility",e,2e4,1.1),Sheet_Metal:e=>Le("launch_facility",e,15e3,1.1),Alloy:e=>Le("launch_facility",e,25e3,1.1)}},monument:{title(e){if(e)return F("arpa_project_monument_title");switch(t.arpa.m_type){case"Obelisk":return F("arpa_project_monument_obelisk");case"Statue":return F("arpa_project_monument_statue");case"Sculpture":return F("arpa_project_monument_sculpture");case"Monolith":return F("arpa_project_monument_monolith");case"Pillar":return F("arpa_project_monument_pillar");case"Megalith":return F("arpa_project_monument_megalith")}},desc:F("arpa_projects_monument_desc"),reqs:{monument:1},grant:"monuments",effect(){let e=N("gaslighter",2);return F("arpa_projects_monument_effect1",[e?2-e:2])},cost:{Stone:(e,t)=>Ee("Stone",e,t),Aluminium:(e,t)=>Ee("Aluminium",e,t),Cement:(e,t)=>Ee("Cement",e,t),Steel:(e,t)=>Ee("Steel",e,t),Lumber:(e,t)=>Ee("Lumber",e,t),Crystal:(e,t)=>Ee("Crystal",e,t)}},railway:{title:()=>Tc("fool",2022)?F("arpa_projects_lhc_title"):F("arpa_projects_railway_title"),desc:()=>Tc("fool",2022)?F("arpa_projects_lhc_desc"):F("arpa_projects_railway_desc"),reqs:{high_tech:6,trade:3},grant:"railway",effect(e){if(Tc("fool",2022)&&!e)return Ce.lhc.effect(!0);let a=t.stats.achieve.banana&&t.stats.achieve.banana.l>=2?1:0,r=t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?3:2;return t.race.cataclysm||t.race.orbit_decayed?(a+=t.space.gps?Math.floor(t.space.gps.count/3):0,F("arpa_projects_railway_cataclysm1",[a,r,3,1])):(a+=t.city.storage_yard?Math.floor(t.city.storage_yard.count/6):0,F("arpa_projects_railway_effect1",[a,r,6,1]))},cost:{Money:(e,t)=>Le("railway",e,25e5,1.08,t),Lumber:(e,t)=>Le("railway",e,75e4,1.08,t),Iron:(e,t)=>Le("railway",e,3e5,1.08,t),Steel:(e,t)=>Le("railway",e,45e4,1.08,t)}},roid_eject:{title:()=>F("arpa_projects_roid_eject_title",[je()]),desc:()=>F(t.tech.roid_eject<=10?"arpa_projects_roid_eject_desc":"arpa_projects_roid_eject_desc2",[je()]),reqs:{blackhole:6,gateway:3},grant:"roid_eject",effect(){let e=0,a=0;return t.tech.roid_eject&&(e+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12),a=.225*(t.tech.roid_eject+1)*(1+(t.tech.roid_eject+1)/12)-e),`
    ${F("arpa_projects_roid_eject_effect1")}
    ${F("arpa_projects_roid_eject_effect2",[+e.toFixed(3),+a.toFixed(3),je()])}
    `},cost:{Money:(e,t)=>Le("roid_eject",e,1875e4,1.075,t),Deuterium:(e,t)=>Le("roid_eject",e,375e3,1.075,t),Bolognium:(e,t)=>Le("roid_eject",e,15e3,1.075,t)}},nexus:{title:F("arpa_projects_nexus_title"),desc:F("arpa_projects_nexus_desc"),reqs:{magic:5},grant:"nexus",effect:()=>t.tech.roguemagic&&t.tech.roguemagic>=7?`
    ${F("arpa_projects_nexus_effect1",[5])}
    ${F("witch_hunter_nexus",[8])}
    `:F("arpa_projects_nexus_effect1",[5]),cost:{Money:(e,t)=>Le("nexus",e,5e6,1.12,t),Crystal:(e,t)=>Le("nexus",e,6e4,1.12,t),Iridium:(e,t)=>Le("nexus",e,35e3,1.12,t)}},syphon:{title:F("arpa_syphon_title"),desc(){let e="";return e=t.tech.syphon&&t.tech.syphon>=0?`
    ${F("arpa_syphon_desc")}
    ${F("arpa_syphon_desc_warn2")}
    `:`
    ${F("arpa_syphon_desc")}
    ${F("arpa_syphon_desc_warn1")}
    `,t.race.witch_hunter&&(e+=`
    ${F("witch_hunter_suspicion")}
    `),e},reqs:{veil:2},grant:"syphon",effect(){let e=+(1/3*nc("magic")).toFixed(3);if(t.tech.syphon&&t.tech.syphon>=60){let t=mc("vacuum"),a=F("resource_Plasmid_plural_name");return`
    ${F("arpa_syphon_effect_main",[e])}
    ${F("arpa_syphon_effect4")}
    ${F("arpa_syphon_effect_reward",[t.plasmid,t.phage,t.dark,a,80])}
    `}return t.tech.syphon&&t.tech.syphon>=40?`
    ${F("arpa_syphon_effect_main",[e])}
    ${F("arpa_syphon_effect3")}
    `:t.tech.syphon&&t.tech.syphon>=20?`
    ${F("arpa_syphon_effect_main",[e])}
    ${F("arpa_syphon_effect2")}
    `:`
    ${F("arpa_syphon_effect_main",[e])}
    ${F("arpa_syphon_effect1")}
    `},cost:{Money:(e,t)=>Le("syphon",e,75e5,1.025,t),Mana:(e,t)=>Le("syphon",e,5e3,1.025,t),Crystal:(e,t)=>Le("syphon",e,1e5,1.025,t),Infernite:(e,t)=>Le("syphon",e,1e4,1.025,t)}}};function je(){return!t.tech.roid_eject||t.tech.roid_eject<=10?F("arpa_projects_roid_eject_asteroid"):t.tech.roid_eject<=25?F("arpa_projects_roid_eject_moon"):t.tech.roid_eject<=40?F("arpa_projects_roid_eject_dwarf"):t.tech.roid_eject<=60?F("arpa_projects_roid_eject_planet"):F("arpa_projects_roid_eject_remnant")}const Se={genetic_memory:{id:"genes-genetic_memory",title:F("arpa_genepool_genetic_memory_title"),desc:F("arpa_genepool_genetic_memory_desc"),reqs:{},grant:["creep",1],cost:{Plasmid:()=>25},action:()=>!!ze("genetic_memory")},animus:{id:"genes-animus",title:F("arpa_genepool_animus_title"),desc:F("arpa_genepool_animus_desc"),reqs:{creep:1},grant:["creep",2],cost:{Plasmid:()=>75},action:()=>!!ze("animus")},divine_remembrance:{id:"genes-divine_remembrance",title:F("arpa_genepool_divine_remembrance_title"),desc:F("arpa_genepool_divine_remembrance_desc"),reqs:{creep:2},grant:["creep",3],cost:{Plasmid:()=>225},action:()=>!!ze("divine_remembrance")},divine_proportion:{id:"genes-divine_proportion",title:F("arpa_genepool_divine_proportion_title"),desc:F("arpa_genepool_divine_proportion_desc"),reqs:{creep:3},grant:["creep",4],cost:{Plasmid:()=>618},action:()=>!!ze("divine_proportion")},genetic_repository:{id:"genes-genetic_repository",title:F("arpa_genepool_genetic_repository_title"),desc:F("arpa_genepool_genetic_repository_desc"),reqs:{creep:4},grant:["creep",5],cost:{Plasmid:()=>999},action:()=>!!ze("genetic_repository")},spatial_reasoning:{id:"genes-spatial_reasoning",title:F("arpa_genepool_spatial_reasoning_title"),desc:F("arpa_genepool_spatial_reasoning_desc"),reqs:{},grant:["store",1],cost:{Plasmid:()=>50},action:()=>!!ze("spatial_reasoning")},spatial_superiority:{id:"genes-spatial_superiority",title:F("arpa_genepool_spatial_superiority_title"),desc:F("arpa_genepool_spatial_superiority_desc"),reqs:{store:1},grant:["store",2],cost:{Plasmid:()=>125},action:()=>!!ze("spatial_superiority")},spatial_supremacy:{id:"genes-spatial_supremacy",title:F("arpa_genepool_spatial_supremacy_title"),desc:F("arpa_genepool_spatial_supremacy_desc"),reqs:{store:2},grant:["store",3],cost:{Plasmid:()=>325},action:()=>!!ze("spatial_supremacy")},dimensional_warping:{id:"genes-dimensional_warping",title:F("arpa_genepool_dimensional_warping_title"),desc:F("arpa_genepool_dimensional_warping_desc"),reqs:{store:3},grant:["store",4],cost:{Plasmid:()=>500},action:()=>!!ze("dimensional_warping")},enhanced_muscle_fiber:{id:"genes-enhanced_muscle_fiber",title:F("arpa_genepool_enhanced_muscle_fiber_title"),desc:F("arpa_genepool_enhanced_muscle_fiber_desc"),reqs:{},grant:["enhance",1],cost:{Plasmid:()=>25},action:()=>!!ze("enhanced_muscle_fiber")},morphogenesis:{id:"genes-morphogenesis",title:F("arpa_genepool_morphogenesis_title"),desc:F("arpa_genepool_morphogenesis_desc"),reqs:{},grant:["evolve",1],cost:{Plasmid:()=>10},action:()=>!!ze("morphogenesis")},recombination:{id:"genes-recombination",title:F("arpa_genepool_recombination_title"),desc:F("arpa_genepool_recombination_desc"),reqs:{evolve:1},grant:["evolve",2],cost:{Plasmid:()=>35},action:()=>!!ze("recombination")},homologous_recombination:{id:"genes-homologous_recombination",title:F("arpa_genepool_homologous_recombination_title"),desc:F("arpa_genepool_homologous_recombination_desc"),reqs:{evolve:2},grant:["evolve",3],cost:{Plasmid:()=>70},action:()=>!!ze("homologous_recombination")},genetic_reshuffling:{id:"genes-genetic_reshuffling",title:F("arpa_genepool_genetic_reshuffling_title"),desc:F("arpa_genepool_genetic_reshuffling_desc"),reqs:{evolve:3},grant:["evolve",4],cost:{Plasmid:()=>175},action:()=>!!ze("genetic_reshuffling")},recombinant_dna:{id:"genes-recombinant_dna",title:F("arpa_genepool_recombinant_dna_title"),desc:F("arpa_genepool_recombinant_dna_desc"),reqs:{evolve:4},grant:["evolve",5],cost:{Plasmid:()=>440},action:()=>!!ze("recombinant_dna")},chimeric_dna:{id:"genes-chimeric_dna",title:F("arpa_genepool_chimeric_dna_title"),desc:F("arpa_genepool_chimeric_dna_desc"),reqs:{evolve:5},grant:["evolve",6],cost:{Plasmid:()=>1100},action:()=>!!ze("chimeric_dna")},molecular_cloning:{id:"genes-molecular_cloning",title:F("arpa_genepool_molecular_cloning_title"),desc:F("arpa_genepool_molecular_cloning_desc"),reqs:{evolve:6},grant:["evolve",7],cost:{Plasmid:()=>2750},action:()=>!!ze("molecular_cloning")},transgenes:{id:"genes-transgenes",title:F("arpa_genepool_transgenes_title"),desc:F("arpa_genepool_transgenes_desc"),reqs:{evolve:7},grant:["evolve",8],cost:{Plasmid:()=>6875},action:()=>!!ze("transgenes")},synthesis:{id:"genes-synthesis",title:F("arpa_genepool_synthesis_title"),desc:F("arpa_genepool_synthesis_desc",[2,10]),reqs:{evolve:1},grant:["synthesis",1],cost:{Plasmid:()=>25},action:()=>!!ze("synthesis")},karyokinesis:{id:"genes-karyokinesis",title:F("arpa_genepool_karyokinesis_title"),desc:F("arpa_genepool_synthesis_desc",[3,25]),reqs:{synthesis:1},grant:["synthesis",2],cost:{Plasmid:()=>40},action:()=>!!ze("karyokinesis")},cytokinesis:{id:"genes-cytokinesis",title:F("arpa_genepool_cytokinesis_title"),desc:F("arpa_genepool_synthesis_desc",[4,50]),reqs:{synthesis:2},grant:["synthesis",3],cost:{Plasmid:()=>55},action:()=>!!ze("cytokinesis")},mitosis:{id:"genes-mitosis",title:F("arpa_genepool_mitosis_title"),desc:F("arpa_genepool_mitosis_desc",[3]),reqs:{synthesis:3,evolve:2},grant:["plasma",1],cost:{Plasmid:()=>90},action:()=>!!ze("mitosis")},metaphase:{id:"genes-metaphase",title:F("arpa_genepool_metaphase_title"),desc:F("arpa_genepool_mitosis_desc",[5]),reqs:{plasma:1},grant:["plasma",2],cost:{Plasmid:()=>165},action:()=>!!ze("mitosis")},mutation:{id:"genes-mutation",title:F("arpa_genepool_mutation_title"),desc:F("arpa_genepool_mutation_desc"),reqs:{synthesis:3,creep:5},grant:["mutation",1],cost:{Plasmid:()=>1250},action:()=>!!ze("mutation")&&(t.genes.mutation=1,Be(),!0)},transformation:{id:"genes-transformation",title:F("arpa_genepool_transformation_title"),desc:F("arpa_genepool_transformation_desc"),reqs:{mutation:1},grant:["mutation",2],cost:{Plasmid:()=>1500},action:()=>!!ze("transformation")&&(t.genes.mutation=2,Be(),!0)},metamorphosis:{id:"genes-metamorphosis",title:F("arpa_genepool_metamorphosis_title"),desc:F("arpa_genepool_metamorphosis_desc"),reqs:{mutation:2},grant:["mutation",3],cost:{Plasmid:()=>1750},action:()=>!!ze("metamorphosis")&&(t.genes.mutation=3,Be(),!0)},replication:{id:"genes-replication",title:F("arpa_genepool_replication_title"),desc:F("arpa_genepool_replication_desc"),reqs:{evolve:1},grant:["birth",1],cost:{Plasmid:()=>65},action:()=>!!ze("replication")},artificer:{id:"genes-artificer",title:F("arpa_genepool_artificer_title"),desc:F("arpa_genepool_artificer_desc"),reqs:{evolve:1},grant:["crafty",1],cost:{Plasmid:()=>45},action:()=>!!ze("artificer")},detail_oriented:{id:"genes-detail_oriented",title:F("arpa_genepool_detail_oriented_title"),desc:F("arpa_genepool_crafting_desc",["50"]),reqs:{crafty:1},grant:["crafty",2],cost:{Plasmid:()=>90},action:()=>!!ze("detail_oriented")},rigorous:{id:"genes-rigorous",title:F("arpa_genepool_rigorous_title"),desc:F("arpa_genepool_crafting_desc",["100"]),reqs:{crafty:2},grant:["crafty",3],cost:{Plasmid:()=>135},action:()=>!!ze("rigorous")},geographer:{id:"genes-geographer",title:F("arpa_genepool_geographer_title"),desc:F("arpa_genepool_geographer_desc"),reqs:{store:1},grant:["queue",1],cost:{Plasmid:()=>75},action:()=>!!ze("geographer")},architect:{id:"genes-architect",title:F("arpa_genepool_architect_title"),desc:F("arpa_genepool_architect_desc"),reqs:{queue:1},grant:["queue",2],cost:{Plasmid:()=>160},action:()=>!!ze("architect"),post(){Ri(),Hi()}},precognition:{id:"genes-precognition",title:F("arpa_genepool_precognition_title"),desc:F("arpa_genepool_precognition_desc"),reqs:{queue:2},grant:["queue",3],condition:()=>t.stats.aiappoc>0,cost:{Plasmid:()=>3500,Phage:()=>100,AICore:()=>1},action:()=>!!ze("precognition")},governance:{id:"genes-governance",title:F("arpa_genepool_governance_title"),desc:F("arpa_genepool_governance_desc"),reqs:{queue:2},grant:["governor",1],cost:{Plasmid:()=>300,Phage:()=>25},action:()=>!!ze("governance")},civil_service:{id:"genes-civil_service",title:F("arpa_genepool_civil_service_title"),desc:F("arpa_genepool_civil_service_desc"),reqs:{governor:1},grant:["governor",2],cost:{Plasmid:()=>1e3,Harmony:()=>1},action:()=>!!ze("civil_service"),post(){if(t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks"))for(let e=0;e<6;e++)t.race.governor.tasks.hasOwnProperty(`t${e}`)||(t.race.governor.tasks[`t${e}`]="none");K()}},hardened_genes:{id:"genes-hardened_genes",title:F("arpa_genepool_hardened_genes_title"),desc:F("arpa_genepool_hardened_genes_desc"),reqs:{},grant:["challenge",1],cost:{Plasmid:()=>5},action:()=>!!ze("hardened_genes")},unlocked:{id:"genes-unlocked",title:F("arpa_genepool_unlocked_title"),desc:F("arpa_genepool_unlocked_desc"),reqs:{challenge:1},grant:["challenge",2],cost:{Plasmid:()=>50},action:()=>!!ze("unlocked"),post(){lc(!0)}},universal:{id:"genes-universal",title:F("arpa_genepool_universal_title"),desc:F("arpa_genepool_universal_desc"),reqs:{challenge:2},grant:["challenge",3],condition:()=>"standard"!==t.race.universe,cost:{Plasmid:()=>400},action:()=>!!ze("universal"),post(){lc(!0)}},standard:{id:"genes-standard",title:F("arpa_genepool_standard_title"),desc:F("arpa_genepool_standard_desc"),reqs:{challenge:3},grant:["challenge",4],condition:()=>"standard"!==t.race.universe,cost:{Plasmid:()=>2500},action:()=>!!ze("standard"),post(){lc(!0)}},mastered:{id:"genes-mastered",title:F("arpa_genepool_mastered_title"),desc:F("arpa_genepool_mastered_desc"),reqs:{challenge:4},grant:["challenge",5],cost:{Plasmid:()=>4e3},action:()=>!!ze("mastered")},negotiator:{id:"genes-negotiator",title:F("arpa_genepool_negotiator_title"),desc:F("arpa_genepool_negotiator_desc"),reqs:{challenge:2},grant:["trader",1],cost:{Plasmid:()=>750},action:()=>!!ze("negotiator")&&(t.genes.trader=1,We(),!0)},ancients:{id:"genes-ancients",title:F("arpa_genepool_ancients_title"),desc:F("arpa_genepool_ancients_desc"),reqs:{evolve:2},condition:()=>!!t.genes.old_gods,grant:["ancients",1],cost:{Plasmid:()=>120},action:()=>!!ze("ancients")&&(t.genes.ancients=1,ms(),!0)},faith:{id:"genes-faith",title:F("arpa_genepool_faith_title"),desc:F("arpa_genepool_faith_desc"),reqs:{ancients:1},grant:["ancients",2],cost:{Plasmid:()=>300},action:()=>!!ze("faith")&&(t.civic.priest.display=!0,!0)},devotion:{id:"genes-devotion",title:F("arpa_genepool_devotion_title"),desc:F("arpa_genepool_devotion_desc"),reqs:{ancients:2},grant:["ancients",3],cost:{Plasmid:()=>600},action:()=>!!ze("devotion")},acolyte:{id:"genes-acolyte",title:F("arpa_genepool_acolyte_title"),desc:F("arpa_genepool_acolyte_desc"),reqs:{ancients:3},grant:["ancients",4],cost:{Plasmid:()=>1e3},action:()=>!!ze("acolyte")},conviction:{id:"genes-conviction",title:F("arpa_genepool_conviction_title"),desc:F("arpa_genepool_conviction_desc"),reqs:{ancients:4},grant:["ancients",5],cost:{Plasmid:()=>1500},action:()=>!!ze("conviction")},transcendence:{id:"genes-transcendence",title:F("arpa_genepool_transcendence_title"),desc:F("arpa_genepool_transcendence_desc"),reqs:{ancients:1,mutation:3},grant:["transcendence",1],cost:{Plasmid:()=>3e3},action:()=>!!ze("transcendence")&&(t.genes.transcendence=1,ms(),!0)},bleeding_effect:{id:"genes-bleeding_effect",title:F("arpa_genepool_bleeding_effect_title"),desc:F("arpa_genepool_bleeding_effect_desc",[2.5]),reqs:{creep:2},grant:["bleed",1],condition:()=>"antimatter"===t.race.universe,cost:{Plasmid:()=>100},action:()=>!!ze("bleeding_effect")},synchronicity:{id:"genes-synchronicity",title:F("arpa_genepool_synchronicity_title"),desc:F("arpa_genepool_synchronicity_desc",[25]),reqs:{bleed:1},grant:["bleed",2],cost:{Plasmid:()=>500},action:()=>!!ze("synchronicity")},astral_awareness:{id:"genes-astral_awareness",title:F("arpa_genepool_astral_awareness_title"),desc:F("arpa_genepool_astral_awareness_desc"),reqs:{bleed:2},grant:["bleed",3],cost:{Plasmid:()=>1e3},action:()=>!!ze("astral_awareness")},blood_remembrance:{id:"genes-blood_remembrance",title:F("arpa_genepool_blood_remembrance_title"),desc:F("arpa_genepool_blood_remembrance_desc"),reqs:{},grant:["blood",1],condition:()=>t.prestige.Blood_Stone.count>=1,cost:{Plasmid:()=>1e3,Phage:()=>10},action:()=>!!ze("blood_remembrance")},blood_sacrifice:{id:"genes-blood_sacrifice",title:F("arpa_genepool_blood_sacrifice_title"),desc:F("arpa_genepool_blood_sacrifice_desc"),reqs:{blood:1},grant:["blood",2],cost:{Plasmid:()=>3e3,Phage:()=>100,Artifact:()=>1},action:()=>!!ze("blood_sacrifice")},essence_absorber:{id:"genes-essence_absorber",title:F("arpa_genepool_essence_absorber_title"),desc:F("arpa_genepool_essence_absorber_desc"),reqs:{blood:2},grant:["blood",3],cost:{Plasmid:()=>7500,Phage:()=>250,Artifact:()=>1},action:()=>!!ze("essence_absorber"),post(){Re()}}},Fe={purify:{id:"blood-purify",title:F("arpa_blood_purify_title"),desc:F("arpa_blood_purify_desc"),reqs:{},grant:["spire",1],cost:{Blood_Stone:()=>10},action(){return!!Ae($(this)[0].cost)}},chum:{id:"blood-chum",title:F("arpa_blood_chum_title"),desc:F("arpa_blood_chum_desc"),reqs:{spire:1},grant:["spire",2],cost:{Blood_Stone:()=>25},action(){return!!Ae($(this)[0].cost)}},lust:{id:"blood-lust",title:F("arpa_blood_lust_title"),desc:F("arpa_blood_lust_desc"),reqs:{},grant:["lust","*"],cost:{Blood_Stone:e=>15*((e||0)+(t.blood.lust||0))+15,Artifact:e=>((e||0)+(t.blood.lust||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},illuminate:{id:"blood-illuminate",title:F("arpa_blood_illuminate_title"),desc:F("arpa_blood_illuminate_desc"),reqs:{},grant:["illuminate","*"],cost:{Blood_Stone:e=>12*((e||0)+(t.blood.illuminate||0))+12,Artifact:e=>((e||0)+(t.blood.illuminate||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},greed:{id:"blood-greed",title:F("arpa_blood_greed_title"),desc:F("arpa_blood_greed_desc"),reqs:{},grant:["greed","*"],cost:{Blood_Stone:e=>16*((e||0)+(t.blood.greed||0))+16,Artifact:e=>((e||0)+(t.blood.greed||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},hoarder:{id:"blood-hoarder",title:F("arpa_blood_hoarder_title"),desc:F("arpa_blood_hoarder_desc"),reqs:{},grant:["hoarder","*"],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:e=>14*((e||0)+(t.blood.hoarder||0))+14,Artifact:e=>((e||0)+(t.blood.hoarder||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},artisan:{id:"blood-artisan",title:F("arpa_blood_artisan_title"),desc:F("arpa_blood_artisan_desc"),reqs:{},grant:["artisan","*"],cost:{Blood_Stone:e=>8*((e||0)+(t.blood.artisan||0))+8,Artifact:e=>((e||0)+(t.blood.artisan||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},attract:{id:"blood-attract",title:F("arpa_blood_attract_title"),desc:F("arpa_blood_attract_desc"),reqs:{},grant:["attract","*"],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:e=>4*((e||0)+(t.blood.attract||0))+4,Artifact:e=>((e||0)+(t.blood.attract||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},wrath:{id:"blood-wrath",title:F("arpa_blood_wrath_title"),desc:F("arpa_blood_wrath_desc"),reqs:{},grant:["wrath","*"],cost:{Blood_Stone:e=>2*((e||0)+(t.blood.wrath||0))+2,Artifact:()=>1},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},prepared:{id:"blood-prepared",title:F("arpa_blood_prepared_title"),desc:F("arpa_blood_prepared_desc"),reqs:{},grant:["prepared",1],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>50},action(){return!!Ae($(this)[0].cost)},post(){Sa()}},compact:{id:"blood-compact",title:F("arpa_blood_compact_title"),desc:F("arpa_blood_compact_desc"),reqs:{prepared:1},grant:["prepared",2],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>75},action(){return!!Ae($(this)[0].cost)}},infernal:{id:"blood-infernal",title:F("arpa_blood_infernal_title"),desc:F("arpa_blood_infernal_desc"),reqs:{prepared:2},grant:["prepared",3],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>125,Artifact:()=>1},action(){return!!Ae($(this)[0].cost)}},unbound:{id:"blood-unbound",title:F("arpa_blood_unbound_title"),desc:F("arpa_blood_unbound_desc"),reqs:{},grant:["unbound",1],cost:{Blood_Stone:()=>50},action(){return!!Ae($(this)[0].cost)}},unbound_resistance:{id:"blood-unbound_resistance",title:F("arpa_blood_unbound_resistance_title"),desc:F("arpa_blood_unbound_resistance_desc"),reqs:{unbound:1},grant:["unbound",2],cost:{Blood_Stone:()=>100},action(){return!!Ae($(this)[0].cost)}},shadow_war:{id:"blood-shadow_war",title:F("arpa_blood_shadow_war_title"),desc:F("arpa_blood_shadow_war_desc"),reqs:{unbound:2},grant:["unbound",3],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>250,Artifact:()=>2},action(){return!!Ae($(this)[0].cost)}},unbound_immunity:{id:"blood-unbound_immunity",title:F("arpa_blood_unbound_immunity_title"),desc:F("arpa_blood_unbound_immunity_desc"),reqs:{unbound:3},grant:["unbound",4],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>500},action(){return!!Ae($(this)[0].cost)}},blood_aware:{id:"blood-blood_aware",title:F("arpa_blood_blood_aware_title"),desc:F("arpa_blood_blood_aware_desc"),reqs:{},grant:["aware",1],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>10},action(){return!!Ae($(this)[0].cost)}}};function ze(e){let a=!0,r=Se[e].cost;return Object.keys(r).forEach((function(e){let s=e;"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].countNumber(t.resource[r].amount))return a=!1,!1})),a}(e=Ke(e))&&(Object.keys(e).forEach((function(a){t.resource[a].amount-=e[a]()/100})),!0)}function Ke(e,a,r){return e=function(e,a,r){if(r&&r.creative||!r&&t.race.creative){var s={};let t=Pi("human");return Object.keys(e).forEach((function(i){s[i]=function(){let s=e[i](a,r);return s*=1-ui.creative.vars()[1]/100,t>0&&(s*=1-ui.creative.vars(1)[1]/100*t),s}})),s}return e}(e,a,r),gc({cost:e},a,r)}function Le(e,a,r,s,i){var c=t.arpa[e]?t.arpa[e].rank:0;return(i&&i.creative||!i&&t.race.creative)&&"syphon"!==e&&(s-=ui.creative.vars()[0]),a&&(c+=a),Math.round(s**c*r)}function Ne(){if(t.tech.high_tech&&t.tech.high_tech>=6){let e=$("#arpaPhysics");rc(e),Object.keys(Ce).forEach((function(a){!function(e,a){if(function(e){if(Ce[e].condition&&!Ce[e].condition())return!1;let a=t.race.truepath?"truepath":"standard";if(Ce[e].hasOwnProperty("path")&&!Ce[e].path.includes(a))return!1;var r=!0;return Object.keys(Ce[e].reqs).forEach((function(a){(!t.tech[a]||t.tech[a]=Ce[a].rank)return;let r=$(`
    `);e.append(r);let s="string"==typeof Ce[a].title?Ce[a].title:Ce[a].title(),i=$(`
    ${s}{{ rank | level }}
    `);r.append(i);let c=$('
    {{ complete }}%
    ');i.append(c);let o=$('
    ');r.append(o),o.append($(``)),o.append($(``)),o.append($(``)),o.append($(``)),o.append($(``)),sc({el:`#arpa${a}`,data:t.arpa[a],methods:{queue(e){if(t.tech.queue){let r=y();for(let s=0;s0))break;if("merge_never"!==t.settings.q_merge&&t.queue.queue.length>0&&t.queue.queue[t.queue.queue.length-1].id===r)t.queue.queue[t.queue.queue.length-1].q++;else{let a="string"==typeof Ce[e].title?Ce[e].title:Ce[e].title();t.queue.queue.push({id:r,action:"arpa",type:e,label:a,cna:!1,time:0,q:1,qs:1,t_max:0})}Ui()}}},build(e,t){He(e,t,!0)},srDesc:()=>q(Ce[a].desc),srLevel:()=>q(Ce[a].effect()),arpaProjectSRCosts(e,a){let r="100"===e?100-t.arpa[a].complete:e;var s=`Construct ${r}%. Costs:`,i=Ke(Ce[a].cost);return Object.keys(i).forEach((function(e){var a=+(i[e]()*(r/100)).toFixed(0);if(a>0){var c="Money"===e?"$":t.resource[e].name+": ",o=t.resource[e].amount>=a?"":` ${F("insufficient")} ${t.resource[e].name}.`;s+=` ${c} ${k(a,2)}.${o}`}})),s}},filters:{remain:e=>100-e,level:e=>F("arpa_level",[e])}}),Ti(`popArpa${a}`,(function(){return Ce[a].desc}),{elm:`#arpa${a} .head .desc`,classes:"has-background-light has-text-dark"}),Ti(`popArpa${a}`,(function(){return Ce[a].effect()}),{elm:`#arpa${a} .head .rank`,classes:"has-background-light has-text-dark"});let n=[1,10,25,100];for(let e=0;e1){let a=$('
    ');e.append(a);let r=t.tech.genetics>2?F("arpa_gene_mutation"):F("arpa_sequence_genome");t.race.artifical&&(r=t.tech.genetics>2?F("arpa_code_modification"):F("arpa_decompile_source"));let s=$(`
    ${r} - ${F("arpa_to_complete")}
    `);a.append(s);let i=$(`{{ progress }}%`);a.append(i);let c=t.tech.genetics>2?F("arpa_mutate"):F("arpa_sequence");t.race.artifical&&(c=t.tech.genetics>2?F("arpa_modify"):F("arpa_decompile"));let o=$(``);if(a.append(o),t.tech.genetics>=5){let e=$(``);a.append(e)}if(t.tech.genetics>=6){let e=$(``);a.append(e)}if(t.tech.genetics>=7){let e=$(``);a.append(e)}t.arpa.sequence.on&&$("#arpaSequence button.seq").addClass("has-text-success"),t.arpa.sequence.boost&&$("#arpaSequence button.boost").addClass("has-text-success"),t.arpa.sequence.auto&&$("#arpaSequence button.auto").addClass("has-text-success"),sc({el:"#arpaSequence",data:t.arpa.sequence,methods:{toggle(){t.arpa.sequence.on?(t.arpa.sequence.on=!1,$("#arpaSequence button.seq").removeClass("has-text-success")):(t.arpa.sequence.on=!0,$("#arpaSequence button.seq").addClass("has-text-success"))},booster(){t.arpa.sequence.boost?(t.arpa.sequence.boost=!1,$("#arpaSequence button.boost").removeClass("has-text-success")):(t.arpa.sequence.boost=!0,$("#arpaSequence button.boost").addClass("has-text-success"))},boostLabel:e=>F(t.race.artifical?"arpa_boost_artifical_label":"arpa_boost_label")+(e?t.arpa.sequence.boost?F("city_on"):F("city_off"):""),novo(){let e=y();for(let a=0;a=2e5;a++)t.resource.Knowledge.amount-=2e5,t.resource.Genes.amount++},novoLabel:()=>F(t.race.artifical?"arpa_novo_artifical_label":"arpa_novo_label",["200k"]),auto_seq(){t.arpa.sequence.auto?(t.arpa.sequence.auto=!1,$("#arpaSequence button.auto").removeClass("has-text-success")):(t.arpa.sequence.auto=!0,$("#arpaSequence button.auto").addClass("has-text-success"))},autoLabel:e=>F(t.race.artifical?"arpa_auto_compile_label":"arpa_auto_seq_label")+(e?t.arpa.sequence.boost?F("city_on"):F("city_off"):"")},filters:{timer(e){if(t.arpa.sequence.on&&t.arpa.sequence.labs>0)return t.arpa.sequence.boost?ic(e/(2*t.arpa.sequence.labs)):ic(e/t.arpa.sequence.labs);{let e=$c(14,12);return e.length>0?e:F("time_never")}}}}),Ti("popArpaSeq",(function(){return t.tech.genetics>2?t.race.artifical?F("arpa_modify_desc"):F("arpa_mutate_desc"):t.race.artifical?F("arpa_decompile_desc"):F("arpa_sequence_desc")}),{elm:"#arpaSequence .seqlbl",classes:"has-background-light has-text-dark"})}if(t.tech.genetics>2){let e=$('
    ');$("#arpaGenetics").append(e);let a=$('
    ');e.append(a),t.tech.decay&&t.tech.decay>=2&&(t.settings.mtorder.includes("fortify")||t.settings.mtorder.push("fortify")),Object.keys(t.race).forEach((function(e){ui[e]&&"minor"===ui[e].type&&(t.settings.mtorder.includes(e)||t.settings.mtorder.push(e))})),t.genes.challenge&&t.genes.challenge>=5&&(t.settings.mtorder.includes("mastery")||t.settings.mtorder.push("mastery"));let r=!1,s=[];t.settings.mtorder.forEach((function(e){(ui[e]&&"minor"===ui[e].type||"mastery"===e||"fortify"===e)&&("fortify"!==e||t.tech.decay&&t.tech.decay>=2)&&(!["promiscuous","content","resilient","industrious","tactical","fibroblast"].includes(e)&&t.race.lone_survivor||!t.race.lone_survivor)&&(r=!0,function(e,a){let r=$(`
    `),s=$(`${t.resource.Genes.name} (${t.race.minor[a]||0})`);if(r.append(s),t.prestige.Phage.count>0){let e=$(`${F("resource_Phage_name")} (${t.genes.minor[a]||0})`);r.append(e)}let i=t.race[a]>1?`(${t.race[a]}) `:"";r.append(`${i}${Oi("name",a)}`),e.append(r)}(a,e),s.push(e))})),e.append(`
    ${F("arpa_race_genetic_traids",[Ac("name")])}
    `);let i=Oi("name"),c=[],o=[],n=$('
    ');e.append(n);let l=zc(t.race);Tc("fool",2023)&&(l.hooved=1),Object.keys(l).forEach((function(e){if(ui[e]&&"minor"!==ui[e].type&&"special"!==ui[e].type&&"evil"!==e&&"soul_eater"!==e&&"artifical"!==e){let a=!1;if(t.race.ss_traits&&t.race.ss_traits.includes(e)||t.race.iTraits&&t.race.iTraits.hasOwnProperty(e)?a=!0:("sludge"!==t.race.species||"ooze"!==e&&!t.race.modified)&&t.race.hasOwnProperty(e)||(a=!0),!a&&("major"===ui[e].type&&t.genes.mutation||"genus"===ui[e].type&&t.genes.mutation&&t.genes.mutation>=2)){let t=$('
    '),a=$(`${F("arpa_remove_button")}`);c.push(e),t.append(a),t.append($(`${i[e]?i[e]:ui[e].name} (${F("arpa_genepool_rank",[l[e]])})`)),n.append(t)}else o.push(e),n.append(`
    ${i[e]?i[e]:ui[e].name} (${F("arpa_genepool_rank",[l[e]])})
    `)}}));let u=[];if(t.genes.mutation&&t.genes.mutation>=3&&("sludge"!==t.race.species||!t.race.modified)){e.append(`
    ${F("arpa_race_genetic_gain")}
    `);let a=["dumb","smart"];Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&"custom"!==e&&di[e].type===di[t.race.species].type&&Object.keys(di[e].traits).forEach((function(e){if(!t.race[e]&&"soul_eater"!==e){let r=a.indexOf(e);if(-1===r)u.push(e);else{let s=!1;switch(r%2){case 0:t.race[a[r+1]]&&(s=!0);break;case 1:t.race[a[r-1]]&&(s=!0)}s||u.push(e)}}}))}));let r=$('
    ');e.append(r);for(let e=0;e
    '),s=$(`${F("arpa_gain_button")}`);a.append(s),a.append($(`${i[t]?i[t]:ui[t].name}`)),r.append(a)}}r&&e.prepend(`
    ${F("arpa_race_genetic_minor_traits",[Ac("name")])}
    `);let d=function(e){let a=5*ui[e].val;return"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1),F("arpa_remove",[Oi("name",e),a,"antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name")])},_=function(e){let a=5*ui[e].val;return"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1),F("arpa_gain",[Oi("name",e),a,"antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name")])},p=function(e){let a=Oc(t.race.minor[e]?t.race.minor[e]+4:4);return"mastery"===e&&(a*=5),F("arpa_gene_buy",[Oi("name",e),k(a),t.resource.Genes.name])},h=function(e){let a=Oc(t.genes.minor[e]?t.genes.minor[e]+4:4);return"mastery"===e&&(a*=2),F("arpa_phage_buy",[Oi("name",e),k(a),F("resource_Phage_name")])};sc({el:"#geneticBreakdown",data:{genes:t.genes,race:t.race},methods:{gene(e){let a=0,r=y(),s=!0,i=!1;for(;a=r?(t.resource.Genes.amount-=r,t.race.minor[e]?t.race.minor[e]++:t.race.minor[e]=1,t.race[e]?t.race[e]++:t.race[e]=1,i=!0):s=!1,a++}i&&("mastery"===e&&lc(!0),Be(),"persuasive"===e&&We())},phage(e){let a=0,r=y(),s=!0,i=!1;for(;a=r?(t.prestige.Phage.count-=r,t.genes.minor[e]?t.genes.minor[e]++:t.genes.minor[e]=1,t.race[e]?t.race[e]++:t.race[e]=1,i=!0):s=!1,a++}i&&("mastery"===e&&lc(!0),Be(),"persuasive"===e&&We())},purge(e){if("sludge"===t.race.species&&(t.race.modified||"ooze"===e))return;let a=5*ui[e].val;"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1);let r="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";if(t.prestige[r].count>=a){t.prestige[r].count-=a;let s=t.race[e];delete t.race[e],t.race.modified?t.race.modified++:t.race.modified=1,xi(e,s),Be(),ms(),hs();let i=0;Object.keys(t.race).forEach((function(e){!ui[e]||"major"!=ui[e].type&&"genus"!=ui[e].type||"evil"===e||i++})),0===i&&eo("blank_slate")}},gain(e){if("sludge"===t.race.species&&t.race.modified)return;let a=5*ui[e].val;"sludge"===t.race.species&&(a*=2),"custom"===t.race.species&&(a*=10),a<0&&(a*=-1);let r="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";t.prestige[r].count>=a&&(t.prestige[r].count-=a,t.race[e]=1,t.race.modified?t.race.modified++:t.race.modified=1,$i(e),Be(),ms(),hs())},geneCost:e=>p(e),phageCost:e=>h(e),traitEffect:e=>F(`trait_${e}_effect`),removeCost:e=>d(e),addCost:e=>_(e),genePurchasable(e){let a=Oc(t.race.minor[e]?t.race.minor[e]+4:4);return"mastery"===e&&(a*=5),t.resource.Genes.amount>=a},phagePurchasable(e){let a=Oc(t.genes.minor[e]?t.genes.minor[e]+4:4);return"mastery"===e&&(a*=2),t.prestige.Phage.count>=a}}}),s.forEach((function(e){Ti(`popGenetrait${e}`,(function(){return p(e)}),{elm:`#geneticBreakdown .t-${e} .gbuy`,classes:"has-background-light has-text-dark"}),t.prestige.Phage.count>0&&Ti(`popGenetrait${e}`,(function(){return h(e)}),{elm:`#geneticBreakdown .t-${e} .pbuy`,classes:"has-background-light has-text-dark"}),Ti(`popGenetrait${e}`,(function(){return t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0?`
    ${Oi("desc",e)}
    ${F(`trait_${e}_effect`)}
    `:Oi("desc",e)}),{elm:`#geneticBreakdown .t-${e} .name`,classes:"has-background-light has-text-dark"})})),c.forEach((function(e){Ti(`popRemoveBkdwn${e}`,(function(){return d(e)}),{elm:`#geneticBreakdown .remove${e}`,classes:"has-background-light has-text-dark"});let a=`raceTrait${e}`,r=$("
    ");Hc(r,e,{trank:t.race[e]}),Ti(a,r,{wide:!0,classes:"w30"})})),o.forEach((function(e){let a=`raceTrait${e}`,r=$("
    ");Hc(r,e,{trank:t.race[e]}),Ti(a,r,{elm:`#geneticBreakdown .trait${e}`,wide:!0,classes:"w30"})})),u.forEach((function(e){Ti(`popAddBkdwn${e}`,(function(){return _(e)}),{elm:`#geneticBreakdown .add${e}`,classes:"has-background-light has-text-dark"});let a=`raceTrait${e}`,r=$("
    ");Hc(r,e,{trank:t.race[e]}),Ti(a,r,{wide:!0,classes:"w30"})})),function(){let e=$("#geneticMinor")[0];e&&Sortable.create(e,{onEnd(e){let a=t.settings.mtorder;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.settings.mtorder=a,Be()}})}()}}function Ge(){(t.tech.genetics&&t.tech.genetics>3||t.sim)&&(rc($("#arpaCrispr")),$("#arpaCrispr").append(`
    ${F("arpa_crispr_desc")}
    `),$("#arpaCrispr").append('
    '),Object.keys(Qr.genes).forEach((function(e){Ms(Qr.genes[e].id),function(e){var a=!0;return Object.keys(Qr.genes[e].reqs).forEach((function(r){(!t.genes[r]||t.genes[r]=2&&(rc($("#arpaBlood")),$("#arpaBlood").append(`
    ${F("arpa_blood_desc")}
    `),$("#arpaBlood").append('
    '),Object.keys(Qr.blood).forEach((function(e){Ms(Qr.blood[e].id),function(e){var a=!0;return Object.keys(Qr.blood[e].reqs).forEach((function(r){(!t.blood[r]||t.blood[r]=100&&(t.arpa[e].rank++,t.arpa[e].complete=0,t.tech[Ce[e].grant]=t.arpa[e].rank,i=!0,"monument"===e&&(t.arpa.m_type=Te(),$(`#arpa${e} .head .desc`).html(Ce[e].title()),Ks(!1,["arpamonument"])),"roid_eject"===e&&($(`#arpa${e} .head .desc`).html(Ce[e].title()),Ks(!1,["arparoid_eject"])),"launch_facility"===e&&(t.settings.showSpace=!0,t.tech.space=1,Ei("popArpalaunch_facility"),[1,10,25,100].forEach((function(e){Ei(`popArpalaunch_facility${e}`)})),s||Bi(["arpalaunch_facility"]),Ne(),Rt(),Di(F("arpa_projects_launch_facility_msg"),"info",!1,["progress"])),t.race.inflation&&(t.race.inflation+=10),ms()));if(r){let t=[1,10,25,100],a=$("#popper"),r=a.data("id");for(let s=0;s
    "),i=Ke(Ce[a].cost);let c=ac(Ce[a],r/100,!1,!0);return Object.keys(i).forEach((function(e){var a=+(i[e]()*(r/100)).toFixed(0);if(a>0){var o="Money"===e?"$":t.resource[e].name+": ",n=t.resource[e].amount>=a?"has-text-dark":e===c.r?"has-text-danger":"has-text-alert";s.append($(`
    ${o}${k(a,2)}
    `))}})),s}function We(){Object.keys(t.resource).forEach((function(e){sc({el:`#market-${e}`},"update")})),sc({el:"#galaxyTrade"},"update")}const Qe={spc_titan:{info:{name:()=>Xt().titan,desc:()=>F("space_titan_info_desc",[Xt().titan,di[t.race.species].home]),support:"electrolysis",zone:"outer",syndicate:()=>!!(t.tech.titan&&t.tech.titan>=3&&t.tech.enceladus&&t.tech.enceladus>=2),syndicate_cap:()=>t.tech.triton?t.tech.outer>=4?2e3:1e3:600},titan_mission:{id:"space-titan_mission",title:()=>F("space_mission_title",[Xt().titan]),desc:()=>F("space_mission_desc",[Xt().titan]),reqs:{outer:1},grant:["titan",1],path:["truepath"],queue_complete:()=>t.tech.titan>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(25e4,!1,t).toFixed(0),Elerium:()=>100},effect:()=>F("space_titan_mission_effect",[Xt().titan]),action(){return!!Os($(this)[0])&&(Di(F("space_titan_mission_action",[Xt().titan,di[t.race.species].home]),"info",!1,["progress"]),!0)}},titan_spaceport:{id:"space-titan_spaceport",title:F("space_red_spaceport_title"),desc:`
    ${F("space_red_spaceport_desc")}
    ${F("requires_power")}
    `,reqs:{titan:1},path:["truepath"],cost:{Money:e=>Xi("titan_spaceport",e,25e5,1.32),Lumber:e=>Xi("titan_spaceport",e,75e4,1.32),Cement:e=>Xi("titan_spaceport",e,35e4,1.32),Mythril:e=>Xi("titan_spaceport",e,1e4,1.32)},effect(){let e=t.resource.Water.display?`
    ${F("plus_max_resource",[k(Lr(250)),t.resource.Water.name])}
    `:"";return`${t.tech.enceladus&&t.tech.enceladus>=2?`
    +${F("galaxy_alien2_support",[$(this)[0].support(),Xt().enceladus])}
    `:""}${e}${t.tech.titan&&t.tech.titan>=5?`
    ${F("space_titan_spaceport_storage",[25])}
    `:""}
    ${F("minus_power",[$(this)[0].powered()])}
    `},support:()=>2,powered:()=>oc(10),action(){return!!Os($(this)[0])&&(t.space.titan_spaceport.count++,xs($(this)[0]),!0)},post(){1===t.tech.titan&&(t.tech.titan=2,ms())}},electrolysis:{id:"space-electrolysis",title:F("space_electrolysis_title"),desc:()=>`
    ${F("space_electrolysis_title")}
    ${F("space_electrolysis_req",[t.resource.Water.name])}
    `,reqs:{titan:3},path:["truepath"],cost:{Money:e=>Xi("electrolysis",e,1e6,1.25),Copper:e=>Xi("electrolysis",e,185e3,1.25),Steel:e=>Xi("electrolysis",e,22e4,1.25),Polymer:e=>Xi("electrolysis",e,38e4,1.25)},effect(){return`
    +${F("galaxy_alien2_support",[$(this)[0].support(),Xt().titan])}
    ${F("space_electrolysis_use",[$(this)[0].support_fuel().a,t.resource.Water.name,$(this)[0].powered()])}
    `},support:()=>t.tech.titan_ai_core&&t.tech.titan_ai_core>=2&&i.ai_core2?3:2,support_fuel:()=>({r:"Water",a:35}),powered:()=>oc(8),action(){return!!Os($(this)[0])&&(t.space.electrolysis.count++,xs($(this)[0]),!0)},post(){3===t.tech.titan&&(t.tech.titan=4,ms())}},hydrogen_plant:{id:"space-hydrogen_plant",title:F("space_hydrogen_plant_title"),desc:()=>`
    ${F("space_hydrogen_plant_title")}
    ${F("space_hydrogen_plant_req")}
    `,reqs:{titan_power:1},path:["truepath"],cost:{Money:e=>Xi("hydrogen_plant",e,15e5,1.28),Iridium:e=>Xi("hydrogen_plant",e,292e3,1.28),Stanene:e=>Xi("hydrogen_plant",e,599e3,1.28),Cement:e=>Xi("hydrogen_plant",e,18e4,1.28)},effect(){return`${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${F("space_hydrogen_plant_effect",[1,F("space_electrolysis_title")])}`},support:()=>2,powered:()=>cc(-22),action(){return!!Os($(this)[0])&&(t.space.hydrogen_plant.count++,t.space.electrolysis.on>t.space.hydrogen_plant.on&&t.space.hydrogen_plant.on++,!0)}},titan_quarters:{id:"space-titan_quarters",title:F("interstellar_habitat_title"),desc:()=>`
    ${F("interstellar_habitat_title")}
    ${F("space_habitat_req",[Xt().titan,t.resource.Food.name,t.resource.Water.name])}
    `,reqs:{titan:4},path:["truepath"],cost:{Money:e=>Xi("titan_quarters",e,12e5,1.28),Furs:e=>Xi("titan_quarters",e,85e3,1.28),Plywood:e=>Xi("titan_quarters",e,1e5,1.28),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=la(1);return`
    ${F("space_used_support",[Xt().titan])}
    ${F("plus_max_resource",[la(1),t.race.truepath?F("job_colonist_tp",[Xt().titan]):F("colonist")])}
    ${F("plus_max_resource",[e,F("citizen")])}
    ${F("spend",[$(this)[0].support_fuel()[0].a,t.resource[$(this)[0].support_fuel()[0].r].name])}
    ${F("spend",[$(this)[0].support_fuel()[1].a,t.resource[$(this)[0].support_fuel()[1].r].name])}
    `},support:()=>-1,support_fuel:()=>[{r:"Water",a:12},{r:"Food",a:500}],powered:()=>oc(1),action(){if(Os($(this)[0])){if(t.space.titan_quarters.count++,t.civic.titan_colonist.display=!0,t.space.electrolysis.support0)){let e=t.civic[t.civic.d_job].workers-la(1)<0?t.civic[t.civic.d_job].workers:la(1);t.civic[t.civic.d_job].workers-=e,t.civic.titan_colonist.workers+=e}return!0}return!1},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},titan_mine:{id:"space-titan_mine",title:F("space_red_mine_title"),desc:()=>`
    ${F("space_red_mine_desc")}
    ${F("space_support",[Xt().titan])}
    `,reqs:{titan:4},condition:()=>!!(t.space.titan_quarters&&t.space.titan_quarters.count>0),path:["truepath"],cost:{Money:e=>Xi("titan_mine",e,475e3,1.28),Lumber:e=>Xi("titan_mine",e,568e3,1.28),Wrought_Iron:e=>Xi("titan_mine",e,25e4,1.28)},effect(){let e=Pe("titan_mine","adamantite"),a=Pe("titan_mine","aluminium"),r=+e.toFixed(3),s=+a.toFixed(3);return`
    ${F("space_used_support",[Xt().titan])}
    ${F("space_red_mine_effect",[r,t.resource.Adamantite.name])}
    ${F("space_red_mine_effect",[s,t.resource.Aluminium.name])}
    `},support:()=>-1,powered:()=>oc(1),special:()=>!0,action(){return!!Os($(this)[0])&&(t.space.titan_mine.count++,t.resource.Adamantite.display=!0,t.space.electrolysis.supportXi("storehouse",e,175e3,1.28),Lumber:e=>Xi("storehouse",e,1e5,1.28),Aluminium:e=>Xi("storehouse",e,12e4,1.28),Cement:e=>Xi("storehouse",e,45e3,1.28)},wide:!0,res:()=>["Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Alloy","Polymer","Iridium","Chrysotile","Nano_Tube","Neutronium","Adamantite"],heavy:e=>!!["Copper","Iron","Steel","Titanium","Iridium","Neutronium","Adamantite"].includes(e),val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 3e3;case"Furs":return 1700;case"Copper":return 1520;case"Iron":return 1400;case"Aluminium":return 1280;case"Cement":return 1120;case"Coal":return 480;case"Steel":return 240;case"Titanium":return 160;case"Alloy":return 180;case"Polymer":return 150;case"Iridium":return 175;case"Nano_Tube":return 120;case"Neutronium":return 64;case"Adamantite":return 72;default:return 0}},effect(){let e='
    ',a=bt("storehouse",!1),r=bt("storehouse",!0);for(const s of $(this)[0].res())if(t.resource[s].display){let i=$(this)[0].heavy(s);e+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(s))*(i?r:a)).toFixed(0),1),t.resource[s].name])}`}return e+="
    ",e},action(){if(Os($(this)[0])){t.space.storehouse.count++;let e=bt("storehouse",!1),a=bt("storehouse",!0);for(const r of $(this)[0].res())if(t.resource[r].display){let s=$(this)[0].heavy(r);t.resource[r].max+=Lr($(this)[0].val(r))*(s?a:e)}return!0}return!1}},titan_bank:{id:"space-titan_bank",title:F("city_bank"),desc:()=>F("city_bank_desc",[Xt().titan]),reqs:{titan:6},path:["truepath"],cost:{Money:e=>Xi("titan_bank",e,25e5,1.32),Titanium:e=>Xi("titan_bank",e,38e4,1.32),Neutronium:e=>Xi("titan_bank",e,5e3,1.32)},effect(){let e=2*Hs();return e=Lr(e),e=(+e.toFixed(0)).toLocaleString(),F("plus_max_resource",[`$${e}`,F("resource_Money_name")])},action(){return!!Os($(this)[0])&&(t.resource.Money.max+=Lr(1800),t.space.titan_bank.count++,!0)}},g_factory:{id:"space-g_factory",title:F("interstellar_g_factory_title"),desc:()=>`
    ${F("interstellar_g_factory_title")}
    ${F("space_support",[Xt().titan])}
    `,reqs:{graphene:1},path:["truepath"],cost:{Money:e=>Xi("g_factory",e,95e4,1.28),Copper:e=>Xi("g_factory",e,165e3,1.28),Stone:e=>Xi("g_factory",e,22e4,1.28),Adamantite:e=>Xi("g_factory",e,12500,1.28)},effect(){let e=.05;return t.race.high_pop&&(e=+Me(e).toFixed(3)),`
    ${F("space_used_support",[Xt().titan])}
    ${F("space_red_mine_effect",[e,t.resource.Graphene.name])}
    ${F("interstellar_g_factory_effect")}
    `},support:()=>-1,powered:()=>oc(1),special:!0,action(){return!!Os($(this)[0])&&(t.space.g_factory.count++,t.resource.Graphene.display=!0,t.space.electrolysis.support`
    ${F("space_sam_desc")}
    ${F("requires_power")}
    `,reqs:{titan:7},path:["truepath"],cost:{Money:e=>Xi("sam",e,25e5,1.28),Steel:e=>Xi("sam",e,45e4,1.28),Elerium:e=>Xi("sam",e,120,1.28),Brick:e=>Xi("sam",e,16e4,1.28)},effect(){return`
    ${F("galaxy_defense_platform_effect",[25])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(5),action(){return!!Os($(this)[0])&&(t.space.sam.count++,xs($(this)[0]),!0)},post(){sc({el:"#spc_titansynd"},"update")}},decoder:{id:"space-decoder",title:F("space_decoder_title"),desc:()=>`
    ${F("space_decoder_title")}
    ${F("requires_power_support_combo",[Xt().titan,t.resource.Cipher.name])}
    `,reqs:{titan:8},path:["truepath"],cost:{Money:e=>Xi("decoder",e,125e5,1.275),Elerium:e=>Xi("decoder",e,750,1.275),Orichalcum:e=>Xi("decoder",e,33e4,1.275),Quantium:e=>Xi("decoder",e,18e4,1.275)},effect(){let e=$(this)[0].support_fuel().a,a=2500;t.race.high_pop&&(a=Me(a)),i.ai_core2&&(a*=1.25);let r=`
    ${F("space_used_support",[Xt().titan])}
    `;return r+=`
    ${F("space_red_exotic_lab_effect1",[a])}
    `,r+`
    ${F("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
    `},support:()=>-1,powered:()=>oc(1),support_fuel:()=>({r:"Cipher",a:.06}),action(){return!!Os($(this)[0])&&(t.space.decoder.count++,t.space.electrolysis.support!t.space.hasOwnProperty("ai_core")||t.space.ai_core.count<100||e?`
    ${F("space_ai_core")}
    ${F("requires_segmemts",[100])}
    `+(t.space.hasOwnProperty("ai_core")&&t.space.ai_core.count>=100?`
    ${F("requires_power")}
    `:""):`
    ${F("space_ai_core")}
    `,reqs:{titan:9},path:["truepath"],condition:()=>!(t.space.ai_core.count>=100),queue_size:10,queue_complete:()=>100-t.space.ai_core.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?25e5:0,Cement:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?18e4:0,Aluminium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?25e4:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?250:0,Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?125e3:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?5e4:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?1e5:0,Cipher:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?750:0},effect(e){let a=`
    ${F("space_ai_core_effect")}
    `,r=(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0);return r<100?(a+=`
    ${F("space_dwarf_collider_effect2",[100-r])}
    `,a):Qe.spc_titan.ai_core2.effect()},action(){return!!(Os($(this)[0])&&t.space.ai_core.count<100)&&(t.space.ai_core.count++,t.space.ai_core.count>=100&&(t.tech.titan_ai_core=1,t.space.ai_core2={count:1,on:0},t.city.power>=Qe.spc_titan.ai_core2.powered()&&t.space.ai_core2.on++,Rt(),ms()),!0)}},ai_core2:{id:"space-ai_core2",title:F("space_ai_core"),desc(){return`
    ${F("space_ai_core")}
    ${F("space_electrolysis_req",[t.resource[$(this)[0].p_fuel().r].name])}
    `},reqs:{titan_ai_core:1},path:["truepath"],condition:()=>!!(t.space.hasOwnProperty("ai_core")&&t.space.ai_core.count>=100),wiki:!1,queue_complete:()=>0,cost:{},powered:()=>oc(100),p_fuel:()=>({r:"Water",a:1e3}),effect(){let e=`
    ${F("interstellar_citadel_stat",[+u.toFixed(1)])}
    `;return e+=`
    ${F("interstellar_citadel_effect",[25])}
    ${F("space_ai_core_effect2",[25])}
    `,t.tech.titan_ai_core&&t.tech.titan_ai_core>=2&&(e+=`
    ${F("space_ai_core_effect3",[50])}
    `),e+=`
    ${F("space_electrolysis_use",[$(this)[0].p_fuel().a,t.resource[$(this)[0].p_fuel().r].name,$(this)[0].powered()])}
    `,t.tech.titan_ai_core&&t.tech.titan_ai_core>=3&&(e+=`
    ${F("space_ai_core_effect4",[+wt().toFixed(1)])}
    `),e},action:()=>!1,flair:()=>t.space.hasOwnProperty("ai_core2")&&t.space.ai_core2.on>=1?F("space_ai_core_flair"):F("space_ai_core_flair2")},ai_colonist:{id:"space-ai_colonist",title:F("space_ai_colonist_title"),desc:()=>`
    ${F("space_ai_colonist_title")}
    ${F("requires_power")}
    `,reqs:{titan_ai_core:3},path:["truepath"],cost:{Money:e=>Xi("ai_colonist",e,112e6,1.35),Alloy:e=>Xi("ai_colonist",e,75e4,1.35),Elerium:e=>Xi("ai_colonist",e,500,1.35),Nano_Tube:e=>Xi("ai_colonist",e,525e3,1.35),Quantium:e=>Xi("ai_colonist",e,15e4,1.35),Cipher:e=>Xi("ai_colonist",e,1e4,1.35)},effect(){return`
    ${F("plus_max_resource",[la(1),t.race.truepath?F("job_colonist_tp",[Xt().titan]):F("colonist")])}
    ${F("space_ai_colonist_effect",[la(1),Xt().titan])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(10),action(){return!!Os($(this)[0])&&(t.space.ai_colonist.count++,xs($(this)[0]),!0)},flair:F("tech_combat_droids_flair")}},spc_enceladus:{info:{name:()=>Xt().enceladus,desc:()=>F("space_enceladus_info_desc",[Xt().enceladus,di[t.race.species].home]),support:"titan_spaceport",zone:"outer",syndicate:()=>!!(t.tech.titan&&t.tech.titan>=3&&t.tech.enceladus&&t.tech.enceladus>=2),syndicate_cap:()=>t.tech.triton?t.tech.outer>=4?1500:1e3:600},enceladus_mission:{id:"space-enceladus_mission",title:()=>F("space_mission_title",[Xt().enceladus]),desc:()=>F("space_mission_desc",[Xt().enceladus]),reqs:{outer:1},grant:["enceladus",1],path:["truepath"],queue_complete:()=>t.tech.enceladus>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(25e4,!1,t).toFixed(0),Elerium:()=>100},effect:()=>F("space_titan_mission_effect",[Xt().enceladus]),action(){return!!Os($(this)[0])&&(Di(F("space_enceladus_mission_action",[Xt().enceladus]),"info",!1,["progress"]),t.resource.Water.display=!0,!0)}},water_freighter:{id:"space-water_freighter",title:F("space_water_freighter_title"),desc:()=>`
    ${F("space_water_freighter_title")}
    ${F("space_support",[Xt().enceladus])}
    `,reqs:{enceladus:2},path:["truepath"],cost:{Money:e=>Xi("water_freighter",e,45e4,1.25),Iron:e=>Xi("water_freighter",e,362e3,1.25),Nano_Tube:e=>Xi("water_freighter",e,125e3,1.25),Sheet_Metal:e=>Xi("water_freighter",e,75e3,1.25)},effect(e){let a=+Jt(5,!0,e).toFixed(2),r=+Pe("water_freighter").toFixed(2);return`
    ${F("space_used_support",[Xt().enceladus])}
    ${F("produce",[r,t.resource.Water.name])}
    ${F("space_belt_station_effect3",[a])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.space.water_freighter.count++,t.space.titan_spaceport.support`
    ${F("tech_zero_g_lab")}
    ${F("requires_power_support",[Xt().enceladus])}
    `,reqs:{enceladus:3},path:["truepath"],cost:{Money:e=>Xi("zero_g_lab",e,5e6,1.25),Alloy:e=>Xi("zero_g_lab",e,125e3,1.25),Graphene:e=>Xi("zero_g_lab",e,225e3,1.25),Stanene:e=>Xi("zero_g_lab",e,6e5,1.25)},effect(){let e=ht("spc_enceladus"),a=Math.round(1e4*e),r=`
    ${F("space_used_support",[Xt().enceladus])}
    ${F("city_max_knowledge",[a])}
    `;return t.resource.Quantium.display&&(r+=`
    ${F("space_zero_g_lab_effect",[la(1)])}
    `),t.resource.Cipher.display&&(r+=`
    ${F("plus_max_resource",[1e4,t.resource.Cipher.name])}
    `),r+`
    ${F("minus_power",[$(this)[0].powered()])}
    `},support:()=>-1,powered:()=>oc(12),action(){return!!Os($(this)[0])&&(t.space.zero_g_lab.count++,t.space.titan_spaceport.support`
    ${F("tech_operating_base")}
    ${F("requires_power_support",[Xt().enceladus])}
    `,reqs:{enceladus:4},path:["truepath"],cost:{Money:e=>Xi("operating_base",e,75e5,1.3),Furs:e=>Xi("operating_base",e,5e5,1.3),Adamantite:e=>Xi("operating_base",e,375e3,1.3),Stanene:e=>Xi("operating_base",e,75e4,1.3),Mythril:e=>Xi("operating_base",e,225e3,1.3),Horseshoe:()=>t.race.hooved?4:0},effect(){let e=`
    ${F("space_used_support",[Xt().enceladus])}
    `;return e+=`
    ${F("galaxy_defense_platform_effect",[50])}
    `,e+=F("plus_max_resource",[la(4),F("civics_garrison_soldiers")]),t.race.orbit_decayed&&(e+=`
    ${F("city_hospital_effect",[5*t.tech.medic])}
    `),e+`
    ${F("minus_power",[$(this)[0].powered()])}
    `},support:()=>-1,powered:()=>oc(10),action(){return!!Os($(this)[0])&&(t.space.operating_base.count++,t.space.titan_spaceport.supportXi("munitions_depot",e,5e6,1.22),Iron:e=>Xi("munitions_depot",e,185e3,1.22),Sheet_Metal:e=>Xi("munitions_depot",e,1e5,1.22)},effect:()=>`
    ${F("plus_max_crates",[25])}
    ${F("plus_max_containers",[25])}
    `,action(){return!!Os($(this)[0])&&(t.space.munitions_depot.count++,t.resource.Crates.max+=25,t.resource.Containers.max+=25,!0)}}},spc_triton:{info:{name:()=>Xt().triton,desc:()=>F("space_triton_info_desc",[Xt().triton,di[t.race.species].home]),zone:"outer",syndicate:()=>!!(t.tech.triton&&t.tech.triton>=2),syndicate_cap:()=>t.tech.outer&&t.tech.outer>=4?5e3:3e3,extra(e){t.tech.triton&&t.tech.triton>=3&&($(`#${e}`).append(`
    ${F("space_ground_resist")}
    `),sc({el:`#${e}resist`,data:t.space.fob,methods:{threat(e,a){let r=t.civic.garrison.wounded-qe();r<0&&(r=0);let s=+(e-ke(a,"army",r)).toFixed(0);return s<0?0:s}}}))}},triton_mission:{id:"space-triton_mission",title:()=>F("space_mission_title",[Xt().triton]),desc:()=>F("space_mission_desc",[Xt().triton]),reqs:{outer:2},grant:["triton",1],path:["truepath"],queue_complete:()=>t.tech.triton>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(6e5,!1,t).toFixed(0),Elerium:()=>2500},effect:()=>F("space_triton_mission_effect",[Xt().triton]),action(){return!!Os($(this)[0])&&(Di(F("space_triton_mission_action",[Xt().triton]),"info",!1,["progress"]),t.space.syndicate.spc_triton=1250,t.space.syndicate.spc_titan+=250,t.space.syndicate.spc_enceladus+=250,!0)}},fob:{id:"space-fob",title:F("space_fob_title"),desc:()=>`
    ${F("tech_fob")}
    ${F("requires_power_combo",[t.resource.Helium_3.name])}
    `,reqs:{triton:2},path:["truepath"],queue_complete:()=>1-t.space.fob.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,25e7,1.1),Copper:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,8e6,1.1),Uranium:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,5e4,1.1),Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,25e5,1.1),Graphene:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,3e6,1.1),Sheet_Metal:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,75e5,1.1),Quantium:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,5e5,1.1),Horseshoe:e=>t.race.hooved&&(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)<1?10:0},effect(e){let a=qe(),r=qe(!0),s=`
    ${F("galaxy_defense_platform_effect",[500])}
    `;s+=F("plus_max_resource",[la(10),F("civics_garrison_soldiers")]),s+=`
    ${F("civics_garrison_soldiers")}: ${a} / ${r}
    `,s+=`
    ${F("civics_garrison_wounded")}: ${t.civic.garrison?t.civic.garrison.wounded:0}
    `,s+=`
    ${F("space_fob_landed",[t.space.fob?t.space.fob.troops:0])}
    `;let i=+Jt(125,!0,e).toFixed(2);return s+`
    ${F("requires_power_combo_effect",[$(this)[0].powered(),i,t.resource.Helium_3.name])}
    `},powered:()=>oc(50),action(){return!!(t.space.fob.count<1&&Os($(this)[0]))&&(t.space.fob.count++,xs($(this)[0]),!0)},post(){2===t.tech.triton&&(t.tech.triton=3,ms(),Rt(),Di(F("space_fob_msg"),"info",!1,["progress"]))}},lander:{id:"space-lander",title:F("space_lander_title"),desc:()=>`
    ${F("space_lander_title")}
    ${F("requires_soldiers")}
    ${F("space_red_space_barracks_desc_req")}
    `,reqs:{triton:3},path:["truepath"],cost:{Money:e=>Xi("lander",e,24e5,1.15),Aluminium:e=>Xi("lander",e,185e3,1.15),Neutronium:e=>Xi("lander",e,1e4,1.15),Nano_Tube:e=>Xi("lander",e,158e3,1.15)},powered:()=>oc(1),effect(e){let a=+Jt(50,!0,e).toFixed(2),r="";return t.space.crashed_ship&&100===t.space.crashed_ship.count&&(r=`
    ${F("space_lander_effect3",[Pe("lander"),t.resource.Cipher.name])}
    `),`
    ${F("space_lander_effect",[Xt().triton])}
    ${r}
    ${F("space_lander_effect2",[la(3)])}
    ${F("space_red_space_barracks_effect2",[a])}
    `},action(){return!!Os($(this)[0])&&(t.space.lander.count++,t.space.lander.on++,!0)}},crashed_ship:{id:"space-crashed_ship",title:F("space_crashed_ship_title"),desc:()=>`
    ${F("space_crashed_ship_title")}
    `,reqs:{triton:3},path:["truepath"],queue_complete:()=>0,cost:{},effect:()=>`
    ${F("space_crashed_ship_effect",[t.space.crashed_ship?t.space.crashed_ship.count:0])}
    `,action:()=>!1}},spc_kuiper:{info:{name:()=>F("space_kuiper_title"),desc:()=>F("space_kuiper_desc"),zone:"outer",syndicate:()=>!!t.tech.kuiper,syndicate_cap:()=>2500},kuiper_mission:{id:"space-kuiper_mission",title:()=>F("space_mission_title",[F("space_kuiper_title")]),desc:()=>F("space_mission_desc",[F("space_kuiper_title")]),reqs:{outer:7},grant:["kuiper",1],path:["truepath"],queue_complete:()=>t.tech.kuiper>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(1e6,!1,t).toFixed(0),Elerium:()=>1e3},effect:()=>F("space_kuiper_mission_effect"),action(){return!!Os($(this)[0])&&(t.space.orichalcum_mine={count:0,on:0},t.space.uranium_mine={count:0,on:0},t.space.neutronium_mine={count:0,on:0},t.space.syndicate.spc_kuiper=500,Di(F("space_kuiper_mission_action"),"info",!1,["progress"]),!0)}},orichalcum_mine:{id:"space-orichalcum_mine",title:()=>F("space_kuiper_mine",[t.resource.Orichalcum.name]),desc:()=>`
    ${F("space_kuiper_mine",[t.resource.Orichalcum.name])}
    ${F("requires_power_combo",[t.resource.Oil.name])}
    `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Xi("orichalcum_mine",e,25e6,1.25),Graphene:e=>Xi("orichalcum_mine",e,9e5,1.25),Elerium:e=>Xi("orichalcum_mine",e,200,1.25),Mythril:e=>Xi("orichalcum_mine",e,45e4,1.25),Quantium:e=>Xi("orichalcum_mine",e,15e4,1.25)},effect(e){let a=+Pe("orichalcum_mine").toFixed(3),r=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
    ${F("gain",[a,F("resource_Orichalcum_name")])}
    ${F("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
    `},powered:()=>oc(10),p_fuel:()=>({r:"Oil",a:200}),action(){return!!Os($(this)[0])&&(t.space.orichalcum_mine.count++,t.resource.Orichalcum.display=!0,xs($(this)[0]),!0)}},uranium_mine:{id:"space-uranium_mine",title:()=>F("space_kuiper_mine",[t.resource.Uranium.name]),desc:()=>`
    ${F("space_kuiper_mine",[t.resource.Uranium.name])}
    ${F("requires_power_combo",[t.resource.Oil.name])}
    `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Xi("uranium_mine",e,5e6,1.25),Iridium:e=>Xi("uranium_mine",e,25e4,1.25),Steel:e=>Xi("uranium_mine",e,62e4,1.25)},effect(e){let a=+Pe("uranium_mine").toFixed(3),r=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
    ${F("gain",[a,F("resource_Uranium_name")])}
    ${F("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
    `},powered:()=>oc(5),p_fuel:()=>({r:"Oil",a:60}),action(){return!!Os($(this)[0])&&(t.space.uranium_mine.count++,xs($(this)[0]),!0)}},neutronium_mine:{id:"space-neutronium_mine",title:()=>F("space_kuiper_mine",[t.resource.Neutronium.name]),desc:()=>`
    ${F("space_kuiper_mine",[t.resource.Neutronium.name])}
    ${F("requires_power_combo",[t.resource.Oil.name])}
    `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Xi("neutronium_mine",e,8e6,1.25),Adamantite:e=>Xi("neutronium_mine",e,65e4,1.25),Stanene:e=>Xi("neutronium_mine",e,125e4,1.25)},effect(e){let a=+Pe("neutronium_mine").toFixed(3),r=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
    ${F("gain",[a,F("resource_Neutronium_name")])}
    ${F("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
    `},powered:()=>oc(8),p_fuel:()=>({r:"Oil",a:60}),action(){return!!Os($(this)[0])&&(t.space.neutronium_mine.count++,xs($(this)[0]),!0)}},elerium_mine:{id:"space-elerium_mine",title:()=>F("space_kuiper_mine",[t.resource.Elerium.name]),desc:()=>`
    ${F("space_kuiper_mine",[t.resource.Elerium.name])}
    ${F("requires_power_combo",[t.resource.Oil.name])}
    `,reqs:{kuiper:2},path:["truepath"],cost:{Money:e=>Xi("elerium_mine",e,2e7,1.25),Titanium:e=>Xi("elerium_mine",e,25e4,1.25),Neutronium:e=>Xi("elerium_mine",e,12e4,1.25),Orichalcum:e=>Xi("elerium_mine",e,175e3,1.25)},effect(e){let a=+Pe("elerium_mine").toFixed(3),r=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
    ${F("gain",[a,F("resource_Elerium_name")])}
    ${F("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
    `},powered:()=>oc(12),p_fuel:()=>({r:"Oil",a:125}),action(){return!!Os($(this)[0])&&(t.space.elerium_mine.count++,xs($(this)[0]),!0)}}},spc_eris:{info:{name:()=>Xt().eris,desc:()=>F("space_eris_info_desc",[Xt().eris]),support:"drone_control",zone:"outer",syndicate:()=>!!t.tech.eris,syndicate_cap:()=>7500,extra(e){t.tech.eris&&1===t.tech.eris&&($(`#${e}`).append(`
    ${F("space_scanned")} {{ eris_scan }}%
    `),sc({el:`#${e}scanned`,data:t.tech}))}},eris_mission:{id:"space-eris_mission",title:()=>F("space_mission_title",[Xt().eris]),desc:()=>F("space_mission_desc",[Xt().eris]),reqs:{outer:7},grant:["eris",1],path:["truepath"],queue_complete:()=>t.tech.eris>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(125e4,!1,t).toFixed(0),Elerium:()=>1250},effect:()=>F("space_eris_mission_effect",[Xt().eris]),action(){return!!Os($(this)[0])&&(t.space.syndicate.spc_eris=4e3,Di(F("space_eris_mission_action",[Xt().eris]),"info",!1,["progress"]),!0)}},drone_control:{id:"space-drone_control",title:()=>F("space_drone_control",[Xt().titan]),desc(){return`
    ${F("space_drone_control",[Xt().titan])}
    ${F("requires_power_combo",[t.resource[$(this)[0].p_fuel().r].name])}
    `},reqs:{eris:3},path:["truepath"],cost:{Money:e=>Xi("drone_control",e,75e6,1.3),Neutronium:e=>Xi("drone_control",e,1e5,1.3),Stanene:e=>Xi("drone_control",e,45e4,1.3),Quantium:e=>Xi("drone_control",e,3e5,1.3)},effect(){let e=$(this)[0].p_fuel().a;return`
    +${F("galaxy_alien2_support",[$(this)[0].support(),Xt().eris])}
    ${F("requires_power_combo_effect",[$(this)[0].powered(),e,t.resource[$(this)[0].p_fuel().r].name])}
    `},support:()=>5,powered:()=>oc(25),p_fuel:()=>({r:"Uranium",a:5}),action(){return!!Os($(this)[0])&&(t.space.drone_control.count++,xs($(this)[0]),!0)}},shock_trooper:{id:"space-shock_trooper",title:F("space_shock_trooper_title"),desc:()=>`
    ${F("space_shock_trooper_title")}
    ${F("space_support",[Xt().eris])}
    `,reqs:{eris:3},path:["truepath"],cost:{Money:e=>Xi("shock_trooper",e,425e4,1.225),Polymer:e=>Xi("shock_trooper",e,375e3,1.225),Adamantite:e=>Xi("shock_trooper",e,5e5,1.225),Graphene:e=>Xi("shock_trooper",e,22e4,1.225),Elerium:e=>Xi("shock_trooper",e,350,1.225)},effect(){let e=Math.round(ke(1,"army",0)*ht("spc_eris")),a=`
    ${F("space_used_support",[Xt().eris])}
    `;return t.space.digsite&&100===t.space.digsite.count&&(a=`
    ${F("space_lander_effect3",[Pe("shock_trooper"),t.resource.Cipher.name])}
    `),a+`
    ${F("space_digsite_offense",[e])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.space.shock_trooper.count++,t.space.drone_control.support`
    ${F("space_tank_title")}
    ${F("space_support",[Xt().eris])}
    `,reqs:{eris:4},path:["truepath"],cost:{Money:e=>Xi("tank",e,1e8,1.25),Alloy:e=>Xi("tank",e,125e4,1.25),Orichalcum:e=>Xi("tank",e,6e5,1.25),Mythril:e=>Xi("tank",e,5e5,1.25),Uranium:e=>Xi("tank",e,25e3,1.25)},effect(){let e=Math.round(100*ht("spc_eris")),a=`
    ${F("space_used_support",[Xt().eris])}
    `;return t.space.digsite&&100===t.space.digsite.count&&(a=`
    ${F("space_lander_effect3",[Pe("tank"),t.resource.Cipher.name])}
    `),a+`
    ${F("space_digsite_offense",[e])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.space.tank.count++,t.space.drone_control.support`
    ${F("space_digsite_title")}
    `,reqs:{eris:3},path:["truepath"],queue_complete:()=>0,cost:{},effect:()=>`
    ${F("space_crashed_ship_effect",[t.space.digsite?t.space.digsite.count:0])}
    `,action:()=>!1}}},Ze={tau_star:{info:{name:()=>F("tab_tauceti"),desc:()=>F("tau_star",[F("tab_tauceti"),F("space_sun_info_name")])},ringworld:{id:"tauceti-ringworld",title:F("tau_star_ringworld"),desc:e=>!t.tauceti.hasOwnProperty("ringworld")||t.tauceti.ringworld.count<1e3||e?`
    ${F("tau_star_ringworld")}
    ${F("requires_segmemts",[1e3])}
    `:`
    ${F("tau_star_ringworld")}
    `,reqs:{matrix:2},path:["truepath"],queue_size:50,queue_complete:()=>1e3-t.tauceti.ringworld.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?1e7:1e8:0,Neutronium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?2e4:1e5:0,Nano_Tube:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?7e4:35e4:0,Adamantite:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?2e5:1e6:0,Bolognium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?17600:88e3:0,Orichalcum:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?25e3:125e3:0,Unobtainium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?360:1800:0,Quantium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?Ye(t.race.lone_survivor?10100:101e3):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0);if(r<1e3){let e=1e3-r;a+=`
    ${F("tau_star_ringworld_effect")}
    `,a+=`
    ${F("space_dwarf_collider_effect2",[e])}
    `}else a+=`
    ${F("space_dwarf_reactor_effect1",[t.race.lone_survivor?100:1e4])}
    `;return a},action(){return!!(Os($(this)[0])&&t.tauceti.ringworld.count<1e3)&&(t.tauceti.ringworld.count++,t.tauceti.ringworld.count>=1e3&&(t.race.lone_survivor?t.tech.eden=1:(t.tech.matrix=3,t.tauceti.matrix={count:1,on:0}),tt(),Ei()),!0)}},matrix:{id:"tauceti-matrix",title:F("tau_star_matrix"),desc:()=>`
    ${F("tau_star_matrix")}
    ${F("requires_power")}
    `,reqs:{matrix:3},condition:()=>t.tauceti.ringworld.count>=1e3,queue_complete:()=>0,cost:{},powered:()=>1e4,postPower(e){e?setTimeout((function(){t.tech.matrix=i.matrix?4:3,tt()}),250):(t.tech.matrix=3,tt())},effect(){let e=Ve(),t=$(this)[0].powered(),a=t>0?`
    ${F("minus_power",[t])}
    `:"";return`
    ${F("tau_star_matrix_effect")}
    ${e}${a}`},action:()=>!1},blue_pill:{id:"tauceti-blue_pill",title:F("tau_star_blue_pill"),desc:F("tau_star_blue_pill"),wiki:!1,reqs:{matrix:4},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=Ve();return`
    ${F("tau_star_blue_pill_effect")}
    ${e}`},action(){if(Os($(this)[0])){$("body").append('');const a=document.getElementById("matrix"),r=a.getContext("2d"),s=a.width=document.body.offsetWidth,i=a.height=document.body.offsetHeight,c=Math.floor(s/20)+1,o=Array(c).fill(0);function n(){r.fillStyle="#0001",r.fillRect(0,0,s,i),r.fillStyle="#0f0",r.font="15pt monospace",o.forEach(((e,t)=>{const a=String.fromCharCode(Math.rand(65382,65438)),s=20*t;r.fillText(a,s,e),e>100+1e4*Math.random()?o[t]=0:o[t]=e+20}))}return setInterval(n,50),setTimeout((function(){!function(){M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"matrix"});let a=t.race.species,r=t.race.gods,s=di[a].type,i=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,n=t.city.geology,l=mc("matrix");Xc(`biome_${c}`),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),Xc(`genus_${s}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),Xc("bluepill"),Z(),so(),t.stats.matrix++,Fc(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let u=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),u&&(t.race.srace=u),Q({orbit:i,biome:c,ptrait:o,geology:n}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),5e3),!0}return!1}},goe_facility:{id:"tauceti-goe_facility",title:F("tau_star_goe_facility"),desc:()=>`
    ${F("tau_star_goe_facility")}
    `,reqs:{eden:2},condition:()=>t.tauceti.ringworld.count>=1e3,queue_complete:()=>0,cost:{Money:e=>1e6,Copper:e=>1e7,Graphene:e=>5e6,Stanene:e=>8e6,Elerium:e=>1e4},effect(){let e=function(){let e=mc("eden"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
    ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
    ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
    ${F("tau_star_matrix_servants",[1])}
    `}();return`
    ${F("tau_star_goe_facility_effect")}
    ${e}`},action(){if(Os($(this)[0])){let a=gc(Ze.tau_star.goe_facility);return Object.keys(a).forEach((function(e){t.resource[e].amount+=a[e]()})),function(){M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"eden"});let a=t.race.species,r=t.race.gods,s=di[a].type,i=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,n=t.city.geology,l=mc("eden");Xc(`biome_${c}`),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),Xc(`genus_${s}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),Xc("adam_eve"),Z(),so(),t.stats.eden++,Fc(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let u=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),u&&(t.race.srace=u),Q({orbit:i,biome:c,ptrait:o,geology:n}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),!1}return!1}}},tau_home:{info:{name:()=>F("tau_planet",[di[t.race.species].home]),desc:()=>F("tau_home",[di[t.race.species].home]),support:"orbital_station",extra(e){t.tech.tau_home&&t.tech.tau_home>=2&&!et()&&($(`#${e}`).append(`
    ${F("resource_Materials_name")} {{ amount | round }} / {{ max }}
    `),sc({el:`#${e}Mats`,data:t.resource.Materials,methods:{tauShow:()=>!et()},filters:{round:e=>+e.toFixed(0)}}))}},home_mission:{id:"tauceti-home_mission",title:()=>F("tau_new_mission_title",[di[t.race.species].home]),desc:()=>F("tau_new_mission_title",[di[t.race.species].home]),reqs:{tauceti:2},grant:["tau_home",1],path:["truepath"],queue_complete:()=>t.tech.tau_home>=1?0:1,cost:{Money:()=>1e9},effect:()=>F("tau_new_mission_effect",[di[t.race.species].home]),action(){return!!Os($(this)[0])&&(t.tauceti.colony={count:0,on:0},t.tauceti.mining_pit={count:0,on:0},Di(F("tau_home_mission_result",[di[t.race.species].home]),"info",!1,["progress"]),!0)}},dismantle:{id:"tauceti-dismantle",title:()=>F("tau_home_dismantle"),desc:()=>F("tau_home_dismantle"),reqs:{tau_home:1},grant:["tau_home",2],path:["truepath"],queue_complete:()=>t.tech.tau_home>=2?0:1,cost:{Money:()=>1e8},effect(){let e="Explorer";if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let a=t.space.shipyard.ships.findIndex((e=>"tauceti"===e.location&&"explorer"===e.class));-1!==a&&(e=t.space.shipyard.ships[a].name)}return F("tau_home_dismantle_effect",[e])},action(){let e=-1;if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")&&(e=t.space.shipyard.ships.findIndex((e=>"tauceti"===e.location&&"explorer"===e.class))),e>=0&&Os($(this)[0])){if(t.space.shipyard.ships.splice(e,1),t.tauceti.orbital_station.count++,t.tauceti.colony.count++,t.tauceti.mining_pit.count++,t.civic.pit_miner.display=!0,t.resource.Materials.display=!0,t.city.powered&&t.city.power>=Ze.tau_home.orbital_station.powered()){t.tauceti.orbital_station.on++,t.tauceti.colony.on++,t.tauceti.mining_pit.on++;let e=la(4);t.civic[t.civic.d_job].workers${F("tau_home_orbital_station")}
    ${F("requires_power")}
    `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Xi("orbital_station",e,8e7,1.3,"tauceti"),Materials:e=>et()?0:Xi("orbital_station",e,5e5,1.3,"tauceti"),Helium_3:e=>et()?Xi("orbital_station",e,Yt(25e4),1.3,"tauceti"):0,Copper:e=>et()?Xi("orbital_station",e,125e4,1.3,"tauceti"):0,Adamantite:e=>et()?Xi("orbital_station",e,9e5,1.3,"tauceti"):0},effect(){let e=Lr(15e3),a=+Yt($(this)[0].support_fuel().a).toFixed(1),r=`
    ${F("space_red_spaceport_effect1",[F("tau_planet",[di[t.race.species].home]),$(this)[0].support()])}
    `;return r+=`
    ${F("plus_max_resource",[e.toLocaleString(),t.resource.Helium_3.name])}
    `,r+=`
    ${F("spend_power",[a,t.resource[$(this)[0].support_fuel().r].name,$(this)[0].powered()])}
    `,r},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?t.race.lone_survivor?5:25:400}),support:()=>3,powered:()=>oc(t.tech.isolation?t.race.lone_survivor?4:6:30),refresh:!0,action(){return!!Os($(this)[0])&&(t.tauceti.orbital_station.count++,xs($(this)[0]),!0)}},colony:{id:"tauceti-colony",title:F("tau_home_colony"),desc:()=>`
    ${F("tau_home_colony_desc",[di[t.race.species].home])}
    ${F("requires_power_support_combo",[di[t.race.species].home,t.resource.Food.name])}
    `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Xi("colony",e,1575e4,1.225,"tauceti"),Materials:e=>et()?0:Xi("colony",e,65e4,1.225,"tauceti"),Furs:e=>et()?Xi("colony",e,72e4,1.225,"tauceti"):0,Graphene:e=>et()?Xi("colony",e,485e3,1.225,"tauceti"):0,Brick:e=>et()?Xi("colony",e,Ye(88e4),1.225,"tauceti"):0},effect(){let e=$(this)[0].citizens(),a=t.tech.isolation?900:250,r=+$(this)[0].support_fuel().a.toFixed(1),s=`
    ${F("tau_new_support",[$(this)[0].support(),di[t.race.species].home])}
    `;if(t.race.lone_survivor||(s+=`
    ${F("plus_max_citizens",[e])}
    `),t.tech.isolation){let e=25*Hs();e=Lr(e),e=(+e.toFixed(0)).toLocaleString(),s+=`
    ${F("plus_max_resource",[`$${e}`,F("resource_Money_name")])}
    `}if(s+=`
    ${F("tau_home_colony_effect",[50,di[t.race.species].home])}
    `,t.tech.isolation){let e=N("gaslighter",0);s+=`
    ${F("space_red_vr_center_effect1",[2*(e?e+t.tech.broadcast:t.tech.broadcast)])}
    `}return s+=`
    ${F("plus_max_resource",[a,F("resource_Crates_name")])}
    ${F("plus_max_resource",[a,F("resource_Containers_name")])}
    `,t.race.lone_survivor?s+=`
    ${F("gain",[-r,t.resource[$(this)[0].support_fuel().r].name])}
    `:s+=`
    ${F("spend",[r,t.resource[$(this)[0].support_fuel().r].name])}
    `,s},support:()=>-2,support_fuel:()=>({r:"Food",a:t.tech.isolation?t.race.lone_survivor?-2:75:1e3}),powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.colony.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.colony.on++,!0)},citizens(){let e=t.tech.isolation?8:5;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),t.race.lone_survivor?0:e}},tau_housing:{id:"tauceti-tau_housing",title:()=>Is("small"),desc:F("city_basic_housing_desc"),desc(){return 1===$(this)[0].citizens()?F("city_basic_housing_desc"):F("city_basic_housing_desc_plural",[$(this)[0].citizens()])},category:"residential",reqs:{housing:1,isolation:1},condition:()=>!t.race.lone_survivor,cost:{Money:e=>Xi("tau_housing",e,15e4,1.15,"tauceti"),Lumber:e=>t.race.kindling_kindred||t.race.smoldering?0:Xi("tau_housing",e,125e3,1.25,"tauceti"),Stone:e=>t.race.kindling_kindred?Xi("tau_housing",e,125e3,1.25,"tauceti"):0,Chrysotile:e=>t.race.smoldering?Xi("tau_housing",e,5e4,1.25,"tauceti"):0,Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.sappy?`
    ${F("plus_max_resource",[e,F("citizen")])}
    ${F("city_grove_effect",[2.5])}
    `:F("plus_max_resource",[e,F("citizen")])},action(){return!!Os($(this)[0])&&(t.tauceti.tau_housing.count++,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},captive_housing:Vr("captive_housing","tauceti"),pylon:{id:"tauceti-pylon",title:F("tau_home_pylon"),desc:F("tau_home_pylon"),reqs:{magic:2},condition:()=>!(!t.tech.isolation||!t.tauceti.hasOwnProperty("pylon")),cost:{Money:e=>Xi("pylon",e,50,1.48,"tauceti"),Stone:e=>Xi("pylon",e,100,1.42,"tauceti"),Crystal:e=>Xi("pylon",e,8,1.42,"tauceti")-3},effect(){let e=Lr(2);return`
    ${F("gain",[+(.0125*nc("magic")).toFixed(3),t.resource.Mana.name])}
    ${F("plus_max_resource",[e,t.resource.Mana.name])}
    `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!Os($(this)[0])&&(t.tauceti.pylon.count++,t.resource.Mana.max+=Lr(2),!0)}},cloning_facility:{id:"tauceti-cloning_facility",title:F("tau_home_cloning"),desc:()=>F("tau_home_cloning_desc",[di[t.race.species].name]),category:"military",reqs:{cloning:1},path:["truepath"],queue_complete:()=>t.resource[t.race.species].max-t.resource[t.race.species].amount,cost:{Money:e=>t.resource[t.race.species].amount?Xi("citizen",e,Math.round((t.race.high_pop?1e5:125e3)/la(1)),t.race.high_pop?1.01:1.02,"tauceti",t.race.high_pop?1.003:1.005):0,Copper:e=>!t.race.artifical||t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Xi("citizen",e,Math.round(50/la(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0,Aluminium:e=>!t.race.artifical||t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Xi("citizen",e,Math.round(50/la(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0,Nanite:e=>t.race.deconstructor&&t.resource[t.race.species].amount>=3?Xi("citizen",e,Math.round(500/la(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0},effect(){let e="";return t.resource[t.race.species].max===t.resource[t.race.species].amount&&(e=`
    ${F("city_assembly_effect_warn")}
    `),`
    ${F("tau_home_cloning_effect",[di[t.race.species].name])}
    ${e}`},action(){return!!(t.resource[t.race.species].max>t.resource[t.race.species].amount&&Os($(this)[0]))&&(t.resource[t.race.species].amount++,!0)}},horseshoe:Vr("horseshoe","tauceti"),bonfire:Vr("bonfire","tauceti"),firework:Vr("firework","tauceti"),assembly:Vr("assembly","tauceti"),nanite_factory:Vr("nanite_factory","tauceti"),tau_farm:{id:"tauceti-tau_farm",title:F("tau_home_tau_farm"),desc:()=>`
    ${F("tau_home_tau_farm")}
    ${F("requires_power")}
    `,reqs:{tau_home:7},path:["truepath"],cost:{Money:e=>Xi("tau_farm",e,135e6,1.25,"tauceti"),Stone:e=>Xi("tau_farm",e,921e4,1.25,"tauceti"),Steel:e=>Xi("tau_farm",e,6295e3,1.25,"tauceti"),Water:e=>Xi("tau_farm",e,1e4,1.25,"tauceti")},effect(){let e=`
    ${F("space_red_spaceport_effect1",[F("tau_planet",[di[t.race.species].home]),$(this)[0].support()])}
    `;return e+=`
    ${F("produce",[+Pe("tau_farm","food").toFixed(2),t.resource.Food.name])}
    `,t.race.kindling_kindred||t.race.smoldering||(e+=`
    ${F("produce",[+Pe("tau_farm","lumber").toFixed(2),t.resource.Lumber.name])}
    `),t.tech.isolation&&(e+=`
    ${F("produce",[+Pe("tau_farm","water").toFixed(2),t.resource.Water.name])}
    `,t.race.artifical&&(e+=`
    ${F("city_transmitter_effect",[Lr(350)])}
    `)),e+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,e},support:()=>1,powered:()=>cc(t.tech.isolation?1:4),action(){return!!Os($(this)[0])&&(t.tauceti.tau_farm.count++,xs($(this)[0]),!0)}},mining_pit:{id:"tauceti-mining_pit",title:F("tau_home_mining_pit"),desc:()=>`
    ${F("tau_home_mining_pit")}
    ${F("space_support",[di[t.race.species].home])}
    `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Xi("mining_pit",e,425e4,1.225,"tauceti"),Materials:e=>et()?0:Xi("mining_pit",e,35e4,1.225,"tauceti"),Lumber:e=>et()?Xi("mining_pit",e,235e4,1.225,"tauceti"):0,Iron:e=>et()?Xi("mining_pit",e,835e3,1.225,"tauceti"):0},effect(){let e=`
    ${F("tau_new_support",[$(this)[0].support(),di[t.race.species].home])}
    `;if(e+=`
    ${F("plus_max_resource",[la(t.tech.isolation?6:8),F("job_pit_miner")])}
    `,et())if(t.tech.isolation){if(t.race.lone_survivor){let a=[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name,t.resource.Copper.name,t.resource.Iron.name,t.resource.Aluminium.name,t.resource.Coal.name];t.race.smoldering?(a.push(t.resource.Chrysotile.name),e+=`
    ${F("tau_home_mining_pit_effect2cs",a)}
    `):e+=`
    ${F("tau_home_mining_pit_effect2c",a)}
    `}else{let a=[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name,t.resource.Copper.name,t.resource.Coal.name];t.race.smoldering?(a.push(t.resource.Chrysotile.name),e+=`
    ${F("tau_home_mining_pit_effect2bs",a)}
    `):e+=`
    ${F("tau_home_mining_pit_effect2b",a)}
    `}e+=`
    ${F("tau_gas_womling_station_effect",[8,t.resource.Cement.name])}
    `}else e+=`
    ${F("tau_home_mining_pit_effect2",[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name])}
    `;else e+=`
    ${F("plus_max_resource",[1e6,F("resource_Materials_name")])}
    `,e+=`
    ${F("tau_home_mining_pit_effect",[t.resource.Materials.name])}
    `;return e},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.mining_pit.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.mining_pit.on++,!0)}},excavate:{id:"tauceti-excavate",title:F("tau_home_excavate"),desc:()=>`
    ${F("tau_home_excavate")}
    `,reqs:{tau_home:2},grant:["tau_home",3],path:["truepath"],cost:{Money:e=>165e7,Materials:e=>75e4},effect:()=>F("tau_home_excavate_effect"),action(){return!!Os($(this)[0])&&(Di(F("tau_home_excavate_msg"),"info",!1,["progress"]),!0)}},alien_outpost:{id:"tauceti-alien_outpost",title:F("tech_alien_outpost"),desc:()=>`
    ${F("tech_alien_outpost")}
    ${F("requires_power")}
    `,reqs:{tau_home:4},path:["truepath"],cost:{},queue_complete:()=>0,effect(){let e=`
    ${F("plus_max_resource",["20%",F("resource_Knowledge_name")])}
    `;return t.tech.isolation&&(e+=`
    ${F("plus_max_resource",[(t.race.lone_survivor?35e5:65e5).toLocaleString(),F("resource_Knowledge_name")])}
    `,e+=`
    ${F("plus_max_resource",[2e5.toLocaleString(),t.resource.Cipher.name])}
    `,e+=`
    ${F("space_lander_effect3",[Pe("alien_outpost"),t.resource.Cipher.name])}
    `),t.tech.outpost_boost&&(e+=`
    ${F("tech_alien_outpost_effect2")}
    `),t.race.lone_survivor&&(e+=`
    ${F("city_wardenclyffe_effect1",[la(1),t.civic.professor.name])}
    `),e+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,e},powered:()=>oc(t.tech.isolation?t.race.lone_survivor?8:25:100),special:()=>!!t.tech.replicator,action:()=>!1},jump_gate:{id:"tauceti-jump_gate",title:F("tau_jump_gate"),desc:e=>!t.tauceti.hasOwnProperty("jump_gate")||t.tauceti.jump_gate.count<100||e?`
    ${F("tau_jump_gate")}
    ${F("requires_segmemts",[100])}
    `:`
    ${F("tau_jump_gate")}
    `,reqs:{tauceti:3},condition:()=>t.tech.isolation?0:1,path:["truepath"],queue_size:10,queue_complete:()=>100-t.tauceti.jump_gate.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0)<100?1e6:0,Materials:e=>(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0)<100?12500:0},effect(e){let a=(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0);if(a<100){let e=100-a;return`
    ${F("tau_jump_gate_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    `}return F("tau_jump_gate_effect")},action(){return!!(Os($(this)[0])&&t.tauceti.jump_gate.count<100)&&(t.tauceti.jump_gate.count++,!0)}},fusion_generator:{id:"tauceti-fusion_generator",title:F("tech_fusion_generator"),desc:()=>`
    ${F("tech_fusion_generator")}
    ${F("requires_res",[t.resource.Helium_3.name])}
    `,reqs:{tau_home:6},path:["truepath"],cost:{Money:e=>Xi("fusion_generator",e,188e6,1.25,"tauceti"),Iridium:e=>Xi("fusion_generator",e,555e4,1.25,"tauceti"),Stanene:e=>Xi("fusion_generator",e,7003500,1.25,"tauceti"),Sheet_Metal:e=>Xi("fusion_generator",e,Ye(95e3),1.25,"tauceti")},effect(){let e=+Yt($(this)[0].p_fuel().a).toFixed(1),a=`
    ${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
    `;return t.race.lone_survivor?a+=`
    ${F("gain",[-e,t.resource[$(this)[0].p_fuel().r].name])}
    `:a+=`
    ${F("spend",[e,t.resource[$(this)[0].p_fuel().r].name])}
    `,a},p_fuel:()=>({r:"Helium_3",a:t.tech.isolation?t.race.lone_survivor?-15:75:500}),powered:()=>cc(-32),action(){return!!Os($(this)[0])&&(t.tauceti.fusion_generator.count++,t.tauceti.fusion_generator.on++,!0)}},repository:{id:"tauceti-repository",title:F("tech_repository"),desc:F("tech_repository"),reqs:{tau_home:5},path:["truepath"],cost:{Money:e=>Xi("repository",e,1028e4,1.28,"tauceti"),Iron:e=>Xi("repository",e,18e5,1.28,"tauceti"),Cement:e=>Xi("repository",e,15e5,1.28,"tauceti"),Neutronium:e=>Xi("repository",e,215e3,1.28,"tauceti")},wide:!0,res(){let e=["Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Crystal","Alloy","Polymer","Iridium","Chrysotile","Nano_Tube","Neutronium","Adamantite","Unobtainium"];return t.tech.isolation&&(e.push("Oil"),e.push("Helium_3"),e.push("Uranium"),e.push("Water")),e},val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 3e4;case"Crystal":return 10;case"Furs":return 17e3;case"Copper":return 15200;case"Iron":return 14e3;case"Aluminium":return 12800;case"Cement":return 11200;case"Coal":return 4800;case"Steel":return 2400;case"Titanium":return 1600;case"Alloy":return 1800;case"Polymer":return 1500;case"Iridium":return 1750;case"Nano_Tube":return 1200;case"Neutronium":return 640;case"Adamantite":return 720;case"Unobtainium":return 1e3;case"Oil":return 680;case"Helium_3":return 575;case"Uranium":return 125;case"Water":return 15;case"Elerium":return 3;default:return 0}},effect(){let e='
    ',a=bt("repository");for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return t.tech.isolation&&(e+=`${F("plus_max_resource",[250,F("resource_Crates_name")])}${F("plus_max_resource",[250,F("resource_Containers_name")])}`),e+="
    ",e},action(){if(Os($(this)[0])){t.tauceti.repository.count++;let e=bt("repository");for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=Lr($(this)[0].val(a))*e);return!0}return!1}},tau_factory:{id:"tauceti-tau_factory",title:F("tau_home_tau_factory"),desc:()=>`
    ${F("tau_home_tau_factory")}
    ${F("requires_power_support",[di[t.race.species].home])}
    `,reqs:{tau_home:8},path:["truepath"],cost:{Money:e=>Xi("tau_factory",e,269e6,1.25,"tauceti"),Titanium:e=>Xi("tau_factory",e,3e6,1.25,"tauceti"),Elerium:e=>Xi("tau_factory",e,850,1.25,"tauceti"),Bolognium:e=>Xi("tau_factory",e,25e4,1.25,"tauceti"),Quantium:e=>Xi("tau_factory",e,Ye(425e3),1.25,"tauceti")},effect(){let e=`
    ${F("tau_new_support",[$(this)[0].support(),di[t.race.species].home])}
    `;return e+=`
    ${F("tau_home_tau_factory_effect",[t.tech.isolation?5:3])}
    `,t.tech.isolation&&(t.race.flier||(e+=`
    ${F("city_cement_plant_effect1",[la(2)])}
    `),e+=`
    ${F("space_red_fabrication_effect1",[la(5)])}
    `),e+=`
    ${F("city_crafted_mats",[t.tech.isolation?275:90])}
    `,e+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,e},special:!0,support:()=>-1,powered:()=>oc(t.tech.isolation?2:5),action(){return!!Os($(this)[0])&&(t.tauceti.tau_factory.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.tau_factory.on++,!0)}},infectious_disease_lab:{id:"tauceti-infectious_disease_lab",title:()=>t.tech.isolation?F("tech_infectious_disease_lab_alt"):F(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),desc(){return`
    ${$(this)[0].title()}
    ${F("requires_power_support",[di[t.race.species].home])}
    `},reqs:{disease:1},path:["truepath"],cost:{Money:e=>Xi("infectious_disease_lab",e,1e9,1.25,"tauceti"),Alloy:e=>Xi("infectious_disease_lab",e,325e5,1.25,"tauceti"),Polymer:e=>Xi("infectious_disease_lab",e,5e7,1.25,"tauceti"),Bolognium:e=>Xi("infectious_disease_lab",e,25e5,1.25,"tauceti"),Unobtainium:e=>Xi("infectious_disease_lab",e,64e3,1.25,"tauceti")},effect(){let e=39616;if(t.tech.supercollider&&t.tech.isolation){let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}let a=`
    ${F("tau_new_support",[$(this)[0].support(),di[t.race.species].home])}
    `;return a+=`
    ${F("city_max_knowledge",[Math.round(e).toLocaleString()])}
    `,t.tech.isolation&&(a+=`
    ${F("plus_max_resource",[Lr(375),F("resource_Elerium_name")])}
    `,a+=`
    ${F("city_wardenclyffe_effect1",[la(2),t.civic.professor.name])}
    `,a+=`
    ${F("city_wardenclyffe_effect1",[la(1),t.civic.scientist.name])}
    `,a+=`
    ${F("space_zero_g_lab_effect",[la(1)])}
    `,a+=`
    ${F("city_library_effect",[75])}
    `),t.tech.alien_crafting&&(a+=`
    ${F("tau_gas_womling_station_effect",[65,t.resource.Quantium.name])}
    `),t.tech.focus_cure&&(a+=`
    ${F("tau_home_disease_lab_cure",[+t.tauceti.infectious_disease_lab.cure.toFixed(1)])}
    `,t.race.hasOwnProperty("vax")&&(a+=`
    ${F("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
    `)),a+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,a},support:()=>-1,powered:()=>oc(t.tech.isolation?t.race.lone_survivor?2:8:35),action(){return!!Os($(this)[0])&&(t.tauceti.infectious_disease_lab.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.infectious_disease_lab.on++,!0)},post(){1===t.tech.disease&&(t.tech.disease=2,Di(F("tau_plague4",[F("tab_tauceti")]),"info",!1,["progress"]),ms())}},tauceti_casino:{id:"tauceti-tauceti_casino",title:F("city_casino"),desc:F("city_casino"),category:"commercial",reqs:{gambling:1,isolation:1},cost:{Money:e=>Xi("tauceti_casino",e,145e4,1.35,"tauceti"),Furs:e=>Xi("tauceti_casino",e,95e3,1.35,"tauceti"),Cement:e=>Xi("tauceti_casino",e,12e4,1.35,"tauceti"),Plywood:e=>Xi("tauceti_casino",e,Ye(55e3),1.35,"tauceti")},effect(){let e=$(this)[0].citizens(),a=t.race.lone_survivor?"":`
    ${F("plus_max_resource",[e,F("citizen")])}
    `;return a+=ss(),a+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,a},powered:()=>oc(t.race.lone_survivor?1:2),action(){return!!Os($(this)[0])&&(t.tauceti.tauceti_casino.count++,t.race.joyless||(t.civic.entertainer.max+=la(1),t.civic.entertainer.display=!0),xs($(this)[0]),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),t.race.lone_survivor?0:e},flair:F("city_casino_flair")},tau_cultural_center:{id:"tauceti-tau_cultural_center",title:F("tech_cultural_center"),desc(){return`
    ${F("tech_cultural_center")}
    ${F("space_electrolysis_req",[t.resource[$(this)[0].p_fuel().r].name])}
    `},category:"commercial",reqs:{tau_culture:1},path:["truepath"],cost:{Money:e=>Xi("tau_cultural_center",e,9145e4,1.35,"tauceti"),Copper:e=>Xi("tau_cultural_center",e,585e4,1.35,"tauceti"),Coal:e=>Xi("tau_cultural_center",e,465e3,1.35,"tauceti"),Polymer:e=>Xi("tau_cultural_center",e,3792e3,1.35,"tauceti")},effect(){let e=1;"corpocracy"===t.civic.govern.type?e=2:"socialist"===t.civic.govern.type&&(e=.8);let a=20*e,r=5*e,s=15*e,i=`
    ${F("tau_home_cultureal_effect1",[$(this)[0].p_fuel().a,t.resource[$(this)[0].p_fuel().r].name,$(this)[0].title])}
    `;return i+=`
    ${F("city_tourist_center_effect3",[a])}
    `,i+=`
    ${F("city_tourist_center_effect4",[r])}
    `,i+=`
    ${F("tau_home_cultureal_effect2",[8,F("tau_red_womlings")])}
    `,t.tech.tau_culture>=2&&(i+=`
    ${F("tau_home_cultureal_effect3",[s,F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)])}
    `),i+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,i},powered:()=>oc(1),p_fuel:()=>({r:"Food",a:t.race.lone_survivor?25:500}),action(){return!!Os($(this)[0])&&(t.tauceti.tau_cultural_center.count++,t.tauceti.tau_cultural_center.on++,!0)}}},tau_red:{info:{name:()=>F("tau_planet",[Xt().red]),desc:()=>F("tau_red",[Xt().red]),support:"orbital_platform",extra(e){t.tech.tau_red&&t.tech.tau_red>=5&&($(`#${e}`).append(`
    ${F("tau_red_womling_prod")} {{ prod }}%
    `),sc({el:`#${e}Womlings`,data:t.tauceti.overseer}))}},red_mission:{id:"tauceti-red_mission",title:()=>F("tau_new_mission_title",[Xt().red]),desc:()=>F("tau_new_mission_title",[Xt().red]),reqs:{tauceti:2},grant:["tau_red",1],path:["truepath"],queue_complete:()=>t.tech.tau_red>=1?0:1,cost:{Money:()=>1e9},effect:()=>F("tau_new_mission_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.tauceti.settlement={count:0,on:0},Di(F("tau_red_mission_result",[Xt().red]),"info",!1,["progress"]),!0)}},orbital_platform:{id:"tauceti-orbital_platform",title:F("tau_red_orbital_platform"),desc:`
    ${F("tau_red_orbital_platform")}
    ${F("requires_power")}
    `,reqs:{tau_red:1,tauceti:4},path:["truepath"],cost:{Money:e=>Xi("orbital_platform",e,5e7,1.3,"tauceti"),Oil:e=>{return et()?Xi("orbital_platform",e,Yt((a=275e3,t.tech.womling_tech&&t.tech.womling_logistics&&t.tech.womling_logistics>=2&&(a*=.94**t.tech.womling_tech),a)),1.3,"tauceti"):0;var a},Aluminium:e=>Xi("orbital_platform",e,178e4,1.3,"tauceti"),Bolognium:e=>Xi("orbital_platform",e,45e4,1.3,"tauceti")},effect(){let e=Lr(17500),a=+Yt($(this)[0].support_fuel().a).toFixed(1),r=`
    ${F("space_red_spaceport_effect1",[F("tau_planet",[Xt().red]),$(this)[0].support()])}
    `;return r+=`
    ${F("plus_max_resource",[e.toLocaleString(),t.resource.Oil.name])}
    `,r+=`
    ${F("spend_power",[a,t.resource[$(this)[0].support_fuel().r].name,$(this)[0].powered()])}
    `,r},support_fuel:()=>({r:t.race.lone_survivor?"Helium_3":"Oil",a:t.tech.isolation?t.race.lone_survivor?8:32:125}),support(){let e=t.tech.womling_logistics?2.5:2;return t.race.lone_survivor&&(e*=2),e},powered:()=>oc(t.tech.isolation?t.race.lone_survivor?2:3:18),refresh:!0,action(){return!(!et()||!Os($(this)[0])||(t.tauceti.orbital_platform.count++,xs($(this)[0]),1===t.tech.tau_red&&(t.tech.tau_red=2,Di(F("tau_red_orbital_platform_msg",[F("tau_planet",[Xt().red]),F("tau_planet",[di[t.race.species].home])]),"info",!1,["progress"])),0))}},contact:{id:"tauceti-contact",title:()=>F("tau_red_contact"),desc:()=>F("tau_red_contact"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Money:()=>6e8,Food:()=>t.race.lone_survivor&&t.race.artifical?62e3:25e5},effect:()=>F("tau_red_contact_effect"),action(){return!!Os($(this)[0])&&(t.race.womling_friend=1,Je(),!0)}},introduce:{id:"tauceti-introduce",title:()=>F("tau_red_introduce"),desc:()=>F("tau_red_introduce"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Knowledge:()=>7e6},effect:()=>F("tau_red_introduce_effect"),action(){return!!Os($(this)[0])&&(t.race.womling_god=1,Je(),!0)}},subjugate:{id:"tauceti-subjugate",title:()=>F("tau_red_subjugate"),desc:()=>F("tau_red_subjugate"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Money:()=>285e7},effect:()=>F("tau_red_subjugate_effect"),action(){return!!Os($(this)[0])&&(t.race.womling_lord=1,Je(),!0)}},jeff:{id:"tauceti-jeff",title:()=>F("tau_red_jeff"),desc:()=>F("tau_red_jeff"),reqs:{tau_red:5},path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{},effect(){let e=t.tauceti.overseer?t.tauceti.overseer.injured:0;t.tauceti.overseer&&t.tauceti.overseer.pop${F("tau_red_jeff_effect1",[t.tauceti.overseer?t.tauceti.overseer.pop:0])}
    `;return a+=`
    ${F("tau_red_jeff_effect2",[t.tauceti.overseer?t.tauceti.overseer.working:0])}
    `,a+=`
    ${F("tau_red_jeff_effect3",[e])}
    `,a+=`
    ${F("tau_red_jeff_effect4",[t.tauceti.overseer?t.tauceti.overseer.loyal:0])}
    `,a+=`
    ${F("tau_red_jeff_effect5",[t.tauceti.overseer?t.tauceti.overseer.morale:0])}
    `,t.tech.hasOwnProperty("womling_tech")&&(a+=`
    ${F("tau_red_jeff_effect6",[t.tech.womling_tech])}
    `),a+=`
    ${F("job_farmer")}: ${t.tauceti.womling_farm?t.tauceti.womling_farm.farmers:0}
    `,a+=`
    ${F("job_miner")}: ${t.tauceti.womling_mine?t.tauceti.womling_mine.miners:0}
    `,t.tauceti.womling_lab&&(a+=`
    ${F("job_scientist")}: ${t.tauceti.womling_lab?t.tauceti.womling_lab.scientist:0}
    `),a},action:()=>!1},overseer:{id:"tauceti-overseer",title(){return $(this)[0].name()},desc(){return`
    ${$(this)[0].name()}
    ${F("space_support",[Xt().red])}
    `},name:()=>t.race.womling_lord?F("tau_red_overseer"):t.race.womling_god?F("tau_red_womgod"):F("tau_red_womally"),reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Xi("overseer",e,6e6,1.28,"tauceti"),Cement:e=>Xi("overseer",e,245e4,1.28,"tauceti"),Alloy:e=>t.race.womling_friend?Xi("overseer",e,185e4,1.28,"tauceti"):0,Neutronium:e=>t.race.womling_lord?Xi("overseer",e,165e3,1.28,"tauceti"):0,Titanium:e=>t.race.womling_god?Xi("overseer",e,225e4,1.28,"tauceti"):0},effect(){let e=`
    ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
    `;return e+=`
    ${F("tau_red_overseer_effect",[$(this)[0].val()])}
    `,e},val(){let e=0;return t.race.womling_lord?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?12:10:t.race.womling_god?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?6:5:t.race.womling_friend&&(e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?10:8),t.race.lone_survivor&&(e*=2),e},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.overseer.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.overseer.on++,!0)}},womling_village:{id:"tauceti-womling_village",title:F("tau_red_womling_village"),desc:()=>`
    ${F("tau_red_womling_village")}
    ${F("space_support",[Xt().red])}
    `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Xi("womling_village",e,1e7,1.28,"tauceti"),Stone:e=>Xi("womling_village",e,225e4,1.28,"tauceti"),Plywood:e=>Xi("womling_village",e,Ye(125e4),1.28,"tauceti"),Wrought_Iron:e=>Xi("womling_village",e,Ye(4e5),1.28,"tauceti")},effect(){let e=t.tech.womling_pop&&t.tech.womling_pop>=2?6:5,a=`
    ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
    `;return a+=`
    ${F("tau_red_womling_village_effect",[e])}
    `,t.tech.tau_junksale&&(a+=`
    ${F("tau_red_womling_village_effect2",[40,F(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`)])}
    `),a},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_village.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_village.on++,!0)}},womling_farm:{id:"tauceti-womling_farm",title:F("tau_red_womling_farm"),desc:()=>`
    ${F("tau_red_womling_farm")}
    ${F("space_support",[Xt().red])}
    `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Xi("womling_farm",e,24e6,1.28,"tauceti"),Iron:e=>Xi("womling_farm",e,95e5,1.28,"tauceti"),Water:e=>Xi("womling_farm",e,5e3,1.28,"tauceti")},effect(){let e=t.tech.womling_pop?16:12;t.tech.womling_gene&&(e+=4);let a=t.tauceti.hasOwnProperty("womling_farm")?t.tauceti.womling_farm.farmers:0,r=`
    ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
    `;return r+=`
    ${F("tau_red_womling_farm_effect",[e])}
    `,r+=`
    ${F("tau_red_womling_employ",[2])}
    `,t.tech.isolation&&(r+=`
    ${F("tau_red_womling_generate",[t.resource.Furs.name])}
    `),r+=`
    ${F("tau_red_womling_farm_effect2",[e/2*a])}
    `,r},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_farm.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_farm.on++,!0)}},womling_mine:{id:"tauceti-womling_mine",title:F("tau_red_womling_mine"),desc:()=>`
    ${F("tau_red_womling_mine")}
    ${F("space_support",[Xt().red])}
    `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Xi("womling_mine",e,125e5,1.28,"tauceti"),Lumber:e=>Xi("womling_mine",e,128e5,1.28,"tauceti"),Steel:e=>Xi("womling_mine",e,45e5,1.28,"tauceti")},effect(){let e=`
    ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
    `;return t.tech.isolation?t.race.lone_survivor?e+=`
    ${F("tau_red_womling_mine_effect_c",[t.resource.Unobtainium.name,t.resource.Uranium.name,t.resource.Titanium.name,t.resource.Iron.name,t.resource.Copper.name,t.resource.Aluminium.name,t.resource.Neutronium.name,t.resource.Iridium.name])}
    `:e+=`
    ${F("tau_red_womling_mine_effect_b",[t.resource.Unobtainium.name,t.resource.Uranium.name,t.resource.Titanium.name])}
    `:e+=`
    ${F("tau_red_womling_mine_effect_a",[t.resource.Unobtainium.name])}
    `,e+=`
    ${F("tau_red_womling_employ",[6])}
    `,e},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_mine.count++,t.resource.Unobtainium.display=!0,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_mine.on++,!0)},flair:()=>F("tau_red_womling_mine_flair")},womling_fun:{id:"tauceti-womling_fun",title(){return $(this)[0].name()},desc(){return`
    ${$(this)[0].name()}
    ${F("space_support",[Xt().red])}
    `},name:()=>t.race.womling_lord?F("tau_red_womling_fun1"):t.race.womling_god?F("tau_red_womling_fun2"):F("tau_red_womling_fun3"),reqs:{tau_red:6},path:["truepath"],cost:{Money:e=>Xi("womling_fun",e,38e5,1.28,"tauceti"),Food:e=>t.race.womling_friend?Xi("womling_fun",e,175e3,1.28,"tauceti"):0,Lumber:e=>Xi("womling_fun",e,5e5,1.28,"tauceti"),Stone:e=>Xi("womling_fun",e,5e5,1.28,"tauceti"),Furs:e=>t.race.womling_lord||t.race.womling_god?Xi("womling_fun",e,835e3,1.28,"tauceti"):0,Copper:e=>t.race.womling_lord?Xi("womling_fun",e,1125e3,1.28,"tauceti"):0,Alloy:e=>t.race.womling_god?Xi("womling_fun",e,656e3,1.28,"tauceti"):0,Water:e=>t.race.womling_friend?Xi("womling_fun",e,3500,1.28,"tauceti"):0},effect(){let e=`
    ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
    `;return e+=`
    ${F("tau_red_womling_fun_effect",[$(this)[0].val()])}
    `,e},val(){let e=0;return t.race.womling_lord?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?24:20:t.race.womling_god?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?12:10:t.race.womling_friend&&(e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?18:15),t.race.lone_survivor&&(e*=2),e},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_fun.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_fun.on++,!0)}},womling_lab:{id:"tauceti-womling_lab",title:F("interstellar_laboratory_title"),desc:()=>`
    ${F("interstellar_laboratory_title")}
    ${F("space_support",[Xt().red])}
    `,reqs:{tau_red:7},path:["truepath"],cost:{Money:e=>Xi("womling_lab",e,65e6,1.28,"tauceti"),Elerium:e=>Xi("womling_lab",e,1200,1.28,"tauceti"),Orichalcum:e=>Xi("womling_lab",e,25e5,1.28,"tauceti"),Unobtainium:e=>Xi("womling_lab",e,1e4,1.28,"tauceti"),Quantium:e=>Xi("womling_lab",e,Ye(95e3),1.28,"tauceti")},effect(){let e=t.tauceti.hasOwnProperty("overseer")?t.tauceti.overseer.prod:100,a=Math.round(25e3*e/100),r=`
    ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
    `;return r+=`
    ${F("tau_red_womling_lab_effect",[a])}
    `,r+=`
    ${F("tau_red_womling_employ_single",[1])}
    `,r},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_lab.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_lab.on++,!0)}}},tau_gas:{info:{name(e,a){let r=a||"gas_name",s="gas_name"===r?0:1;if(e||t.race[r])switch(e||t.race[r]){case 1:{let e="antimatter"===t.race.universe?"plasmid":"antiplasmid";switch(Math.round(t.stats[e]+s)%3){case 1:return F("tau_planet",[Xt().gas]);case 2:return F("tau_gas_title0a",[Xt().gas]);default:return F("tau_gas_title0b",[Xt().gas])}}case 2:switch(Math.round(t.stats.reset+s)%3){case 1:return F("tau_gas_title1a");case 2:return F("tau_gas_title1b");default:return F("tau_gas_title1c")}case 3:switch(Math.round(t.stats.mad+s)%3){case 1:return F("tau_gas_title2a");case 2:return F("tau_gas_title2b");default:return F("tau_gas_title2c")}case 4:switch(Math.round(t.stats.bioseed+s)%3){case 1:return F("tau_gas_title3a",[di[t.race.gods].solar.gas]);case 2:return F("tau_gas_title3b",[di[t.race.old_gods].name]);default:return F("tau_gas_title3c",[di[t.race.species].name])}case 5:switch(Math.round(t.stats.portals+s)%3){case 1:return F("tau_gas_title4a",[Xt().gas]);case 2:return F("tau_gas_title4b",[Ac("reverse",Xt().gas)]);default:return F("tau_gas_title4c")}case 6:switch(Math.round(t.stats.womling.friend.l+t.stats.womling.lord.l+t.stats.womling.god.l+s)%3){case 1:return F("tau_gas_title5a");case 2:return F("tau_gas_title5b");default:return F("tau_gas_title5c")}case 7:switch(Math.round(t.stats.tdays+s)%3){case 1:return F("tau_gas_title6a");case 2:return F("tau_gas_title6b");default:return F("tau_gas_title6c")}default:return F("gas_name"===r?"tau_gas_title":"tau_gas2_title")}return F("gas_name"===r?"tau_gas_title":"tau_gas2_title")},desc:()=>F("tau_gas_desc")},gas_contest:{id:"tauceti-gas_contest",title:()=>F("tau_gas_contest_title"),desc:()=>F("tau_gas_contest_title"),reqs:{tauceti:5},grant:["tau_gas",1],path:["truepath"],queue_complete:()=>t.tech.tau_gas>=1?0:1,cost:{Money:()=>1e7},effect:()=>t.race.lone_survivor?F("tau_gas_contest_effect_alt"):F("tau_gas_contest_effect"),action(){return!!Os($(this)[0])}},refueling_station:{id:"tauceti-refueling_station",title:()=>F("tau_gas_refueling_station_title"),desc:()=>`
    ${F("tau_gas_refueling_station_title")}
    ${F("requires_power")}
    `,reqs:{tau_gas:2},path:["truepath"],cost:{Money:e=>Xi("refueling_station",e,68e6,1.28,"tauceti"),Graphene:e=>Xi("refueling_station",e,25e5,1.28,"tauceti"),Unobtainium:e=>Xi("refueling_station",e,5500,1.28,"tauceti"),Mythril:e=>Xi("refueling_station",e,Ye(6e4),1.28,"tauceti")},powered:()=>oc(t.tech.isolation?2:5),effect(){let e=+Pe("refueling_station").toFixed(2),a=Lr(1e4),r=`
    ${F("space_gas_mining_effect1",[e])}
    `;return r+=`
    ${F("plus_max_resource",[a.toLocaleString(),t.resource.Helium_3.name])}
    `,t.tech.tau_whale>=2&&(r+=`
    ${F("plus_max_resource",[Lr(6500).toLocaleString(),t.resource.Oil.name])}
    `),t.tech.isolation&&(r+=`
    ${F("interstellar_g_factory_effect")}
    `),r+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,r},special:()=>!!t.tech.isolation,action(){return!!Os($(this)[0])&&(t.tauceti.refueling_station.count++,xs($(this)[0]),!0)},post(){2===t.tech.tau_gas&&(t.tech.tau_gas=3,ms())}},ore_refinery:{id:"tauceti-ore_refinery",title:()=>F("tau_gas_ore_refinery_title"),desc:()=>`
    ${F("tau_gas_ore_refinery_title")}
    ${F("requires_power")}
    `,reqs:{tau_gas:4},path:["truepath"],cost:{Money:e=>Xi("ore_refinery",e,52e6,1.28,"tauceti"),Iridium:e=>Xi("ore_refinery",e,16e5,1.28,"tauceti"),Unobtainium:e=>Xi("ore_refinery",e,800,1.28,"tauceti"),Sheet_Metal:e=>Xi("ore_refinery",e,Ye(118e3),1.28,"tauceti")},powered:()=>oc(t.tech.isolation?2:8),effect(){let e=t.tauceti.hasOwnProperty("ore_refinery")?t.tauceti.ore_refinery.fill:0,a=t.tauceti.hasOwnProperty("ore_refinery")?t.tauceti.ore_refinery.max:0,r=+Pe("ore_refinery").toFixed(2),s=`
    ${F("tau_gas_ore_refinery_effect",[+e.toFixed(2)])}
    `;return s+=`
    ${F("tau_gas_ore_refinery_effect2",[a])}
    `,s+=`
    ${F("tau_gas_ore_refinery_effect3",[r])}
    `,s+=`
    ${F("interstellar_stellar_forge_effect3",[t.tech.isolation?12:4])}
    `,s+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,s},special:!0,action(){return!!Os($(this)[0])&&(t.tauceti.ore_refinery.count++,t.city.powered&&t.city.power>=$(this)[0].powered()&&(t.tauceti.ore_refinery.on++,t.city.smelter.cap+=t.tech.isolation?12:2,t.city.smelter.Steel+=t.tech.isolation?12:2,t.race.evil?t.city.smelter.Wood+=t.tech.isolation?12:2:t.city.smelter.Oil+=t.tech.isolation?12:2),!0)},post(){3===t.tech.tau_roid&&(t.tech.tau_roid=4,tt(),ms())}},whaling_station:{id:"tauceti-whaling_station",title:()=>F("tau_gas_whaling_station_title"),desc:()=>`
    ${F("tau_gas_whaling_station_title")}
    ${F("requires_power")}
    `,reqs:{tau_whale:1},path:["truepath"],cost:{Money:e=>Xi("whaling_station",e,72e6,1.28,"tauceti"),Steel:e=>Xi("whaling_station",e,18e5,1.28,"tauceti"),Polymer:e=>Xi("whaling_station",e,955e3,1.28,"tauceti"),Orichalcum:e=>Xi("whaling_station",e,268e3,1.28,"tauceti")},powered:()=>oc(t.tech.isolation?2:6),effect(){let e=t.tauceti.hasOwnProperty("whaling_station")?t.tauceti.whaling_station.fill:0,a=t.tauceti.hasOwnProperty("whaling_station")?t.tauceti.whaling_station.max:0,r=+Pe("whaling_station").toFixed(2),s=`
    ${F("tau_gas_whaling_station_effect",[+e.toFixed(2)])}
    `;return s+=`
    ${F("tau_gas_whaling_station_effect2",[a])}
    `,s+=`
    ${F("tau_gas_whaling_station_effect3",[r])}
    `,s+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,s},action(){return!!Os($(this)[0])&&(t.tauceti.whaling_station.count++,xs($(this)[0]),!0)},post(){1===t.tech.tau_whale&&(t.tech.tau_whale=2,tt())}},womling_station:{id:"tauceti-womling_station",title:()=>F("tau_gas_womling_station_title"),desc:()=>`
    ${F("tau_gas_womling_station_desc")}
    ${F("requires_power")}
    `,reqs:{womling_technicians:1},path:["truepath"],cost:{Money:e=>Xi("womling_station",e,1334e5,1.26,"tauceti"),Furs:e=>Xi("womling_station",e,3805e3,1.26,"tauceti"),Aluminium:e=>Xi("womling_station",e,85e5,1.26,"tauceti"),Nano_Tube:e=>Xi("womling_station",e,909e3,1.26,"tauceti")},powered:()=>oc(t.tech.isolation?3:6),effect(){let e=t.tech.isolation?30:8;t.tech.womling_gene&&(e*=1.25);let a=`
    ${F("tau_gas_womling_station_effect",[e,Ze.tau_gas.info.name()])}
    `;return t.race.flier||(a+=`
    ${F("city_cement_plant_effect1",[la(1)])}
    `),a+=`
    ${F("space_red_fabrication_effect1",[la(1)])}
    `,a+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,a},action(){return!!Os($(this)[0])&&(t.tauceti.womling_station.count++,xs($(this)[0]),!0)}}},tau_roid:{info:{name:()=>F("tau_roid_title"),desc:()=>F("tau_roid_desc"),support:"patrol_ship"},roid_mission:{id:"tauceti-roid_mission",title:()=>F("space_mission_title",[F("tau_roid_title")]),desc:()=>F("space_mission_desc",[F("tau_roid_title")]),reqs:{tauceti:5},grant:["tau_roid",1],path:["truepath"],queue_complete:()=>t.tech.tau_roid>=1?0:1,cost:{Helium_3:(e,t)=>+Yt(125e4).toFixed(0)},effect:()=>F("tau_roid_mission_effect",[F("tau_roid_title")]),action(){return!!Os($(this)[0])&&(Di(F("tau_roid_mission_result"),"info",!1,["progress"]),!0)}},patrol_ship:{id:"tauceti-patrol_ship",title:F("tau_roid_patrol_ship"),desc:()=>`
    ${F("tau_roid_patrol_ship")}
    ${F("requires_res",[t.resource.Helium_3.name])}
    `,reqs:{tau_roid:3},path:["truepath"],cost:{Money:e=>Xi("patrol_ship",e,45e6,1.25,"tauceti"),Adamantite:e=>Xi("patrol_ship",e,18e5,1.25,"tauceti"),Elerium:e=>Xi("patrol_ship",e,520,1.25,"tauceti"),Stanene:e=>Xi("patrol_ship",e,2675e3,1.25,"tauceti"),Bolognium:e=>Xi("patrol_ship",e,115e4,1.25,"tauceti")},effect(){let e=+Yt($(this)[0].support_fuel().a).toFixed(1),a=`
    ${F("tau_roid_patrol_ship_security",[$(this)[0].support()])}
    `;return a+=`
    ${F("tau_roid_patrol_ship_effect")}
    `,a+=`
    ${F("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
    `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?15:250}),support:()=>1,powered:()=>oc(1),refresh:!0,action(){return!!Os($(this)[0])&&(t.tauceti.patrol_ship.count++,t.tauceti.patrol_ship.on++,!0)}},mining_ship:{id:"tauceti-mining_ship",title:F("tau_roid_mining_ship"),desc:()=>`
    ${F("tau_roid_mining_ship")}
    `,reqs:{tau_roid:4},path:["truepath"],cost:{Money:e=>Xi("mining_ship",e,28e6,1.28,"tauceti"),Uranium:e=>Xi("mining_ship",e,12500,1.28,"tauceti"),Titanium:e=>Xi("mining_ship",e,22e5,1.28,"tauceti"),Alloy:e=>Xi("mining_ship",e,175e4,1.28,"tauceti")},effect(){let e=+Yt($(this)[0].support_fuel().a).toFixed(1),a=`
    ${F("tau_roid_mining_ship_effect",[+Pe("mining_ship").toFixed(2)])}
    `;return a+=`
    ${F("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
    `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?12:75}),support:()=>-1,powered:()=>oc(1),special:!0,action(){return!!Os($(this)[0])&&(t.tauceti.mining_ship.count++,t.tauceti.mining_ship.on++,!0)}},whaling_ship:{id:"tauceti-whaling_ship",title:F("tau_roid_whaling_ship"),desc:()=>`
    ${F("tau_roid_whaling_ship")}
    `,reqs:{tau_whale:2},path:["truepath"],cost:{Money:e=>Xi("whaling_ship",e,35e6,1.28,"tauceti"),Aluminium:e=>Xi("whaling_ship",e,34e5,1.28,"tauceti"),Neutronium:e=>Xi("whaling_ship",e,168e3,1.28,"tauceti"),Nano_Tube:e=>Xi("whaling_ship",e,8e5,1.28,"tauceti")},effect(){let e=+Yt($(this)[0].support_fuel().a).toFixed(1),a=`
    ${F("tau_roid_whaling_ship_effect",[+Pe("whaling_ship").toFixed(2)])}
    `;return a+=`
    ${F("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
    `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?14:90}),support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.whaling_ship.count++,t.tauceti.whaling_ship.on++,!0)}}},tau_gas2:{info:{name:e=>Ze.tau_gas.info.name(e||t.race.gas_name2||!1,"gas_name2"),desc:()=>F("tau_gas2_desc",[Ze.tau_gas.info.name()])},gas_contest2:{id:"tauceti-gas_contest2",title:()=>F("tau_gas2_contest_title"),desc:()=>F("tau_gas2_contest_title"),reqs:{tau_gas2:1},grant:["tau_gas2",2],path:["truepath"],queue_complete:()=>t.tech.tau_gas2>=1?0:1,cost:{Money:()=>25e6},effect:()=>F("tau_gas2_contest_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tau_gas2_contest_flair")},alien_station_survey:{id:"tauceti-alien_station_survey",title:F("tau_gas2_alien_station"),desc:F("tau_gas2_alien_station"),reqs:{tau_gas2:3},grant:["tau_gas2",4],path:["truepath"],queue_complete:()=>t.tech.tau_gas3>=4?0:1,cost:{Money:()=>t.race.lone_survivor?15e8:3e9,Helium_3:()=>5e6},effect:()=>F("tau_gas2_alien_station_repair_effect",[Ze.tau_gas2.info.name()]),action(){return!!Os($(this)[0])&&(t.tauceti.alien_station={count:0},Di(F("tau_gas2_alien_station_msg",[Ze.tau_gas2.info.name()]),"info",!1,["progress"]),!0)}},alien_station:{id:"tauceti-alien_station",title:F("tau_gas2_alien_station"),desc:e=>!t.tauceti.hasOwnProperty("alien_station")||t.tauceti.alien_station.count<100||e?`
    ${F("tau_gas2_alien_station")}
    `+(t.tauceti.hasOwnProperty("alien_station")&&t.tauceti.alien_station.count>=100?`
    ${F("space_dwarf_reactor_desc_req")}
    `:`
    ${F("tau_gas2_alien_station_repair")}
    `):`
    ${F("tau_gas2_alien_station")}
    `,reqs:{tau_gas2:4},condition:()=>t.tauceti.alien_station.count<100,path:["truepath"],queue_size:5,queue_complete:()=>100-t.tauceti.alien_station.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?12e6:5e7:0,Aluminium:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?256e3:256e4:0,Polymer:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?198900:989e3:0,Mythril:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?Ye(125e3):0,Cipher:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?256:2001:0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0);return r<100?(a+=`
    ${F("tau_gas2_alien_station_repaired",[r])}
    `,a):Ze.tau_gas2.alien_space_station.effect(e)},action(){return!!(Os($(this)[0])&&t.tauceti.alien_station.count<100)&&(t.tauceti.alien_station.count++,t.tauceti.alien_station.count>=100&&(t.tech.tau_gas2=5,t.tauceti.alien_space_station={count:1,on:0}),!0)},post(){t.resource.Elerium.diff>=10&&(t.tauceti.alien_space_station.on=1),tt()}},alien_space_station:{id:"tauceti-alien_space_station",title:F("tau_gas2_alien_station"),desc:()=>`
    ${F("tau_gas2_alien_station")}
    ${F("space_dwarf_reactor_desc_req")}
    `,reqs:{tau_gas2:5},path:["truepath"],cost:{},queue_complete:()=>0,special:()=>!(!t.tech.tau_gas2||6!==t.tech.tau_gas2||t.tech.alien_data&&!(t.tech.alien_data<6)),wiki:!1,effect(){let e=$(this)[0].p_fuel().a,a=`
    ${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
    `;if(t.tech.tau_gas2&&t.tech.tau_gas2>=6&&t.tauceti.alien_space_station.hasOwnProperty("decrypted")){let e=t.race.lone_survivor?1e5:25e6,r=+(t.tauceti.alien_space_station.decrypted/e).toFixed(2);r>100&&(r=100),a+=`
    ${F("tau_gas2_alien_station_effect",[r])}
    `}return a+=`
    ${F("spend",[e,t.resource[$(this)[0].p_fuel().r].name])}
    `,a},p_fuel:()=>({r:"Elerium",a:t.race.lone_survivor?1:10}),powered:()=>cc(-75),action:()=>!1},matrioshka_brain:{id:"tauceti-matrioshka_brain",title:F("tech_matrioshka_brain"),desc:e=>!t.tauceti.hasOwnProperty("matrioshka_brain")||t.tauceti.matrioshka_brain.count<1e3||e?`
    ${F("tech_matrioshka_brain")}
    ${F("requires_segmemts",[1e3])}
    `:`
    ${F("tech_matrioshka_brain")}
    `,reqs:{tau_gas2:7},condition:()=>!!t.tauceti.matrioshka_brain,path:["truepath"],queue_size:50,queue_complete:()=>1e3-t.tauceti.matrioshka_brain.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?2e7:0,Neutronium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?45e3:0,Nano_Tube:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?16e4:0,Adamantite:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?666e3:0,Stanene:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?61600:0,Bolognium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?44e3:0,Unobtainium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?1200:0,Mythril:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?Ye(64e3):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0);return r<1e3&&(a+=`
    ${F("tau_gas2_matrioshka_brain_seg",[1e3-r])}
    `),a},action(){return!!(Os($(this)[0])&&t.tauceti.matrioshka_brain.count<1e3)&&(t.tauceti.matrioshka_brain.count++,t.tauceti.matrioshka_brain.count>=1e3&&(t.tech.m_brain=1),!0)}},ignition_device:{id:"tauceti-ignition_device",title:F("tech_ignition_device"),desc:e=>!t.tauceti.hasOwnProperty("ignition_device")||t.tauceti.ignition_device.count<10||e?`
    ${F("tech_ignition_device")}
    ${F("requires_segmemts",[10])}
    `:`
    ${F("tech_ignition_device")}
    `,reqs:{tau_gas2:8},condition:()=>!!(t.tauceti.ignition_device&&t.tauceti.ignition_device.count<10),path:["truepath"],queue_size:1,queue_complete:()=>10-t.tauceti.ignition_device.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?25e7:0,Uranium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?5e4:0,Elerium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?25e3:0,Graphene:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?225e5:0,Orichalcum:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?15e6:0,Quantium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?Ye(8e6):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0);return r<10&&(a+=`
    ${F("tau_gas2_ignition_device_seg",[10-r])}
    `),a},action(){return!!(Os($(this)[0])&&t.tauceti.ignition_device.count<10)&&(t.tauceti.ignition_device.count++,t.tauceti.ignition_device.count>=10&&(t.tech.m_ignite=1),!0)}},ignite_gas_giant:{id:"tauceti-ignite_gas_giant",title:()=>F("tau_gas2_ignite_gas_giant",[Ze.tau_gas2.info.name()]),desc:()=>F("tau_gas2_ignite_gas_giant",[Ze.tau_gas2.info.name()]),reqs:{tau_gas2:8,m_ignite:1},grant:["m_ignite",2],queue_size:1,queue_complete:()=>!1,path:["truepath"],cost:{Helium_3:()=>75e5},effect(){let e=`
    ${F("tau_gas2_ignite_gas_giant_effect",[F("tech_matrioshka_brain")])}
    `;return t.tech.m_brain?(e+=`
    ${F("tau_gas2_ignite_gas_giant_effect3")}
    `,e+=function(){let e=mc("retire"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name"),r=t.stats.retire+1===t.stats.matrix?`
    ${F("tau_star_matrix_skilled",[1])}
    `:"";return`
    ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
    ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
    ${F("tau_star_matrix_servants",[1])}
    ${r}`}()):e+=`
    ${F("tau_gas2_ignite_gas_giant_effect2",[F("tech_matrioshka_brain")])}
    `,e},action(){return!(!t.tech.m_brain||!Os($(this)[0])||(function(){M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"retire"});let a=t.race.species,r=t.race.gods,s=di[a].type,i=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,n=t.city.geology,l=mc("retire");Xc(`biome_${c}`),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),Xc(`genus_${s}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),Xc("retired"),Z(),so(),t.stats.retire++,Fc(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let u=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),u&&(t.race.srace=u),Q({orbit:i,biome:c,ptrait:o,geology:n}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),0))}}}};for(let e=1;e<9;e++)Ze.tau_gas[`gas_contest-a${e}`]={id:`tauceti-gas_contest-a${e}`,title:()=>Ze.tau_gas.info.name(e),desc:()=>Ze.tau_gas.info.name(e),reqs:{tau_gas:1},grant:["tau_gas",2],path:["truepath"],wiki:!1,queue_complete:()=>t.tech.tau_gas>=2?0:1,cost:{},effect:()=>F(8===e?"tau_gas_contest_reject":"tau_gas_contest_pick",[Ze.tau_gas.info.name(e)]),action(){return!!Os($(this)[0])&&(t.race.gas_name=e,t.tauceti.refueling_station={count:0,on:0},!0)}},Ze.tau_gas2[`gas_contest-b${e}`]={id:`tauceti-gas_contest-b${e}`,title:()=>Ze.tau_gas2.info.name(e),desc:()=>Ze.tau_gas2.info.name(e),reqs:{tau_gas2:2},grant:["tau_gas2",3],path:["truepath"],wiki:!1,queue_complete:()=>t.tech.tau_gas2>=3?0:1,cost:{},effect:()=>F(8===e?"tau_gas2_contest_reject":"tau_gas_contest_pick",[Ze.tau_gas2.info.name(e)]),action(){return!!Os($(this)[0])&&(t.race.gas_name2=e,!0)}};function Ve(){let e=mc("matrix"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name"),r=t.stats.retire===t.stats.matrix+1?`
    ${F("tau_star_matrix_skilled",[1])}
    `:"";return`
    ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
    ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
    ${F("tau_star_matrix_servants",[1])}
    ${r}`}function Je(){t.tauceti.overseer={count:0,on:0,pop:0,working:0,injured:0,morale:0,loyal:0,prod:0},t.tauceti.womling_village=t.race.lone_survivor?{count:2,on:2}:{count:1,on:1},t.tauceti.womling_mine=t.race.lone_survivor?{count:1,on:1,miners:0}:{count:0,on:0,miners:0},t.tauceti.womling_farm={count:1,on:1,farmers:0},t.tauceti.womling_fun={count:0,on:0}}function Ye(e){return t.tech.womling_tech&&t.tech.womling_recycling&&t.tech.womling_recycling>=1&&(e*=(t.tech.isolation?.97:.98)**t.tech.womling_tech),e}function Xe(){return Qe}function et(){return!!(t.tech.tauceti&&t.tech.tauceti>=4)}function tt(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||6!==t.settings.spaceTabs))return;let e=$("#tauceti");rc(e),e.append($(`

    ${F("tab_tauceti")}

    `)),!t.tech.tauceti||t.tech.tauceti<2||Object.keys(Ze).forEach((function(a){let r=a.replace("tau_","");if(t.settings.tau[`${r}`]){let r="string"==typeof Ze[a].info.name?Ze[a].info.name:Ze[a].info.name(),s="";if(Ze[a].info.hasOwnProperty("prop")&&(s=Ze[a].info.prop()),Ze[a].info.support){let i=Ze[a].info.support;Ze[a].info.hide_support?e.append(`

    ${r}

    ${s}
    `):e.append(`

    ${r}

    {{ support }}/{{ s_max }}${s}
    `),sc({el:`#sr${a}`,data:t.tauceti[i],filters:{filter(){return Ze[a].info.filter(...arguments)}}})}else e.append(`

    ${r}

    ${s}
    `);Ti(a,(function(){return"string"==typeof Ze[a].info.desc?Ze[a].info.desc:Ze[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(Ze[a]).forEach((function(e){"info"!==e&&Gt(Ze,a,e)&&fs(Ze[a][e],"tauceti",e)})),Ze[a].info.hasOwnProperty("extra")&&Ze[a].info.extra(a)}}))}function at(){if((t.settings.tabLoad||2===t.settings.civTabs&&5===t.settings.govTabs)&&(ft(),dt(),rc($("#dwarfShipYard")),t.space.hasOwnProperty("shipyard")&&t.settings.showShipYard)){let e=$("#dwarfShipYard");t.space.shipyard.hasOwnProperty("blueprint")||(t.space.shipyard.blueprint={class:"corvette",armor:"steel",weapon:"railgun",engine:"ion",power:"diesel",sensor:"radar",name:rt()});let a=$('
    ');e.append(a);let r=$('
    ');a.append(r),r.append(`
    ${F("outer_shipyard_registry")}:
    `),r.append(`
    ${F("crew")}
    `),r.append(`
    ${F("power")}
    `),r.append(`
    ${F("firepower")}
    `),r.append(`
    ${F("outer_shipyard_sensors")}
    `),r.append(`
    ${F("speed")}
    `),r.append(`
    ${F("outer_shipyard_fuel")}
    `),a.append('
    ');let s=$('
    ');a.append(s);let i={class:["corvette","frigate","destroyer","cruiser","battlecruiser","dreadnought","explorer"],power:["solar","diesel","fission","fusion","elerium"],weapon:["railgun","laser","p_laser","plasma","phaser","disruptor"],armor:["steel","alloy","neutronium"],engine:["ion","tie","pulse","photon","vacuum","emdrive"],sensor:["visual","radar","lidar","quantum"]};Object.keys(i).forEach((function(e){let t="";i[e].forEach((function(a,r){t+=`${F(`outer_shipyard_${e}_${a}`)}`})),s.append(`\n ${t}\n `)}));let c=$('
    ');c.append(``),c.append(`${F("outer_shipyard_fleet_details")}`),c.append(`${F("outer_shipyard_fleet_sort")}`),a.append(c),c.append(`
    ${F("outer_shipyard_park",[Xt().dwarf])}${F("outer_shipyard_map")}`),st();let o={template:''};sc({el:"#shipPlans",data:{b:t.space.shipyard.blueprint,s:t.space.shipyard},methods:{setVal(e,a){"class"===e&&"explorer"===a?(t.space.shipyard.blueprint.engine="emdrive",t.space.shipyard.blueprint.weapon="railgun",t.tech.syard_armor>=3&&(t.space.shipyard.blueprint.armor="neutronium"),t.tech.syard_sensor>=4&&(t.space.shipyard.blueprint.sensor="quantum"),t.tech.syard_power>=4&&(t.space.shipyard.blueprint.power="elerium")):"class"===e&&"explorer"!==a&&"explorer"===t.space.shipyard.blueprint.class&&(t.space.shipyard.blueprint.engine="ion"),t.space.shipyard.blueprint[e]=a,st()},avail(e,a,r){if(!("class"!==e&&"engine"!==e||!t.tech.tauceti||"emdrive"!==r&&"explorer"!==r))return!0;if("explorer"===t.space.shipyard.blueprint.class){if("weapon"===e)return 1===a;if("engine"===e)return 6===a;if("sensor"===e)return 4===a}return t.tech[`syard_${e}`]>a},crewText:()=>it(t.space.shipyard.blueprint),powerText(){let e=ct(t.space.shipyard.blueprint);return e<0?`${e}kW`:`${e}kW`},fireText:()=>ot(t.space.shipyard.blueprint),sensorText:()=>mt(t.space.shipyard.blueprint)+"km",speedText(){let e=7.695363719135802*nt(t.space.shipyard.blueprint);return Math.round(e)+"km/s"},fuelText(){let e=lt(t.space.shipyard.blueprint);return e.res?`-${e.burn} ${t.resource[e.res].name}`:"N/A"},build(){if(ct(t.space.shipyard.blueprint)>=0){let e=ut(t.space.shipyard.blueprint),a={};if(Object.keys(e).forEach((function(t){a[t]=function(){return e[t]}})),Os(!1,a)){let e=zc(t.space.shipyard.blueprint);e.location="spc_dwarf",e.xy=vt("spc_dwarf"),e.origin=zc(e.xy),e.destination=zc(e.xy),e.transit=0,e.dist=0,e.damage=0,e.fueled=!1,0===e.name.length&&(e.name=rt());let a=1,r=e.name;for(;t.space.shipyard.ships.filter((e=>e.name===r)).length>0;)a++,r=e.name+` ${a}`;e.name=r,t.space.shipyard.ships.push(e),_t(),st(),t.space.shipyard.blueprint.name=rt()}}},trigModal(){this.$buefy.modal.open({parent:this,component:o});let e=setInterval((function(){$("#modalBox").length>0&&(clearInterval(e),$("#modalBox").append($('

    Solar System

    ')),function(e){let t=$('
    ').appendTo(e),a={},r={},s=!1;qt={},kt=20,t.append($('').on("mouseup mouseover mouseout",(()=>s=!1)).on("mousedown",(e=>{s=!0,r.x=e.clientX-qt.x,r.y=e.clientY-qt.y})).on("mousemove",(e=>{s&&(qt.x=e.clientX-r.x,qt.y=e.clientY-r.y,Mt())})).on("wheel",(e=>(e.originalEvent.deltaY<0?(kt/=.8,qt.x=a.x+(qt.x-a.x)/.8,qt.y=a.y+(qt.y-a.y)/.8,Mt()):(kt*=.8,qt.x=a.x+.8*(qt.x-a.x),qt.y=a.y+.8*(qt.y-a.y),Mt()),!1))),$('').on("click",(()=>{kt/=.8,qt.x=a.x+(qt.x-a.x)/.8,qt.y=a.y+(qt.y-a.y)/.8,Mt()})),$('').on("click",(()=>{kt*=.8,qt.x=a.x+.8*(qt.x-a.x),qt.y=a.y+.8*(qt.y-a.y),Mt()})));let i=document.getElementById("mapCanvas").getBoundingClientRect();a.x=i.width/2,a.y=i.height/2,qt.x=a.x,qt.y=a.y,Mt()}($("#modalBox")))}),50)},redraw(){_t()}},filters:{lbl:(e,t)=>F(`outer_shipyard_${t}_${e}`)}}),Object.keys(i).forEach((function(e){for(let t=0;t<$(`#shipPlans .${e}`).length;t++)Ti(`shipPlans${e}${t}`,(function(t){let a=$(t.this).attr("data-val");return F(`outer_shipyard_${e}_${a}_desc`)}),{elm:`#shipPlans .${e}.a${t}`,placement:"right"})})),e.append($('
    ')),_t()}}function rt(){let e=["Trident","Spacewolf","Excalibur","Neptune","Deimos","Phobos","Enterprise","Intrepid","Daedalus","Odyssey","Endurance","Horizon","Hyperion","Icarus","Aurora","Axiom","Nemesis","Normandy","Orion","Prometheus","Vanguard","Discovery","Voyager","Defiant","Titan","Liberty","Destiny","Phoenix","Nautilus","Barracuda","Dolphin","Cuttlefish","Tiger Shark","Stingray","Swordfish","Triton","Dragon","Scorpion","Hagfish","Marlin","Galileo","Raven","Sarcophagus","Excelsior","Scimitar","Vengeance","Nomad","Nova","Olympus","Aegis","Agamemnon","Charon","Achilles","Apollo","Hermes","Hydra","Medusa","Talos","Zeus","Heracles","Cerberus","Acheron","Damocles","Juno","Persephone","Solaris","Victory","Hawk","Fury","Razor","Stinger","Outrider","Falcon","Vulture","Nirvana","Retribution","Swordbreaker","Valkyrie","Athena","Avalon","Merlin","Argonaut","Serenity","Gunstar","Ranger","Tantive","Cygnus","Nostromo","Reliant","Narcissus","Liberator","Sulaco","Infinity","Resolute","Wasp","Hornet","Independence","Gilgamesh","Midway","Concordia","Goliath","Cosmos","Express","Tigers Claw","Oberon","Minnow","Majestic","Spartacus","Colossi","Vigilant","Remorseless","Caelestis","Inquisitor","Atlas","Avenger","Dauntless","Nihilus","Thanatos","Stargazer","Xyzzy","Kraken","Xerxes","Spitfire","McShipFace","Monitor","Merrimack","Constitution","Ghost","Pequod","Arcadia","Corsair","Inferno","Jenny","Revenge","Red October","Jackdaw","Thorn","Caleuche","Valencia","Ourang","Deering","Baychimo","Octavius","Joyita","Lovibond","Celeste","Dutchman"],a=e[Math.rand(0,e.length)];return t.space.shipyard.ships.filter((e=>e.name===a)).length>0&&(a=function(){let e=["al","an","ar","as","at","ea","ed","en","er","es","ha","he","hi","in","is","it","le","me","nd","ne","ng","nt","on","or","ou","re","se","st","te","th","ti","to","ve","wa","all","and","are","but","ent","era","ere","eve","for","had","hat","hen","her","hin","his","ing","ion","ith","not","ome","oul","our","sho","ted","ter","tha","the","thi","tio","uld","ver","was","wit","you"],t=Math.rand(2,5),a="";for(let r=0;r${t.resource[a].name}${k(e[a])}`):$("#shipYardCosts").append(` | ${t.resource[a].name} ${k(e[a])}`)}))}function it(e){switch(e.class){case"corvette":return la(2);case"frigate":return la(3);case"destroyer":return la(4);case"cruiser":return la(6);case"battlecruiser":return la(8);case"dreadnought":case"explorer":return la(10)}}function ct(e,t){let a=0,r=1,s=1;switch(e.class){case"frigate":r=1.1,s=1.2;break;case"destroyer":r=1.5,s=1.65;break;case"cruiser":r=2,s=2.5;break;case"battlecruiser":r=2.5,s=3.5;break;case"dreadnought":r=5,s=6.5;break;case"explorer":r=6,s=2}switch(e.power){case"solar":a=Math.round(50*r);break;case"diesel":a=Math.round(100*r);break;case"fission":a=Math.round(150*r);break;case"fusion":a=Math.round(("explorer"===e.class||t?174:175)*r);break;case"elerium":a=Math.round(200*r)}switch(a=Math.round(cc(a)),e.weapon){case"railgun":a-=Math.round(10*s);break;case"laser":a-=Math.round(30*s);break;case"p_laser":a-=Math.round(18*s);break;case"plasma":a-=Math.round(50*s);break;case"phaser":a-=Math.round(65*s);break;case"disruptor":a-=Math.round(100*s)}switch(e.engine){case"ion":a-=Math.round(25*s);break;case"tie":a-=Math.round(50*s);break;case"pulse":a-=Math.round(40*s);break;case"photon":a-=Math.round(75*s);break;case"vacuum":a-=Math.round(120*s);break;case"emdrive":a-=Math.round(("explorer"===e.class||t?515:1024)*s)}switch(e.sensor){case"radar":a-=Math.round(10*s);break;case"lidar":a-=Math.round(25*s);break;case"quantum":a-=Math.round(75*s)}return a}function ot(e){let t=0;switch(e.weapon){case"railgun":t=36;break;case"laser":t=64;break;case"p_laser":t=54;break;case"plasma":t=90;break;case"phaser":t=114;break;case"disruptor":t=156}switch(e.class){case"corvette":return t;case"frigate":return Math.round(1.5*t);case"destroyer":return Math.round(2.75*t);case"cruiser":return Math.round(5.5*t);case"battlecruiser":return Math.round(10*t);case"dreadnought":return Math.round(22*t);case"explorer":return Math.round(1.2*t)}}function nt(e){let a=1;switch(e.class){case"corvette":a="neutronium"===e.armor?1.1:1;break;case"frigate":a="neutronium"===e.armor?1.35:1.25;break;case"destroyer":a="neutronium"===e.armor?1.95:1.8;break;case"cruiser":a="neutronium"===e.armor?3.5:3;break;case"battlecruiser":a="neutronium"===e.armor?4.8:4;break;case"dreadnought":a="neutronium"===e.armor?7.5:6;break;case"explorer":a=1}let r="spc_dwarf"===e.location&&i.m_relay&&0===e.transit&&t.space.m_relay&&t.space.m_relay.charged>=1e4?3:1;switch(e.engine){case"ion":return 12/a*r;case"tie":return 22/a*r;case"pulse":return 18/a*r;case"photon":return 30/a*r;case"vacuum":return 42/a*r;case"emdrive":return 37500/a*r}}function lt(e){let t=!1,a=0;switch(e.power){case"diesel":t="Oil",a=8;break;case"fission":t="Uranium",a=.5;break;case"fusion":t="Helium_3",a=12;break;case"elerium":t="Elerium",a=1}switch(e.class){case"frigate":a*=1.25;break;case"destroyer":a*=1.5;break;case"cruiser":a*=2;break;case"battlecruiser":a*=3;break;case"dreadnought":a*=5;break;case"explorer":a*=25}return{res:t,burn:+a.toFixed(2)}}function ut(e){let a={},r=1,s=1,i=1;switch(e.class){case"corvette":a.Money=25e5,a.Aluminium=5e5,r=1,s=1,i=2;break;case"frigate":a.Money=5e6,a.Aluminium=125e4,r=1.1,s=1.09,i=1.5;break;case"destroyer":a.Money=15e6,a.Aluminium=35e5,r=1.2,s=1.18,i=1.2;break;case"cruiser":a.Money=5e7,a.Adamantite=1e6,r=1.3,s=1.25;break;case"battlecruiser":a.Money=125e6,a.Adamantite=26e5,r=1.35,s=1.3,i=.8;break;case"dreadnought":a.Money=5e8,a.Adamantite=8e6,r=1.4,s=1.35,i=.5;break;case"explorer":a.Money=8e8,a.Adamantite=95e5,r=1.45,s=1}switch(e.armor){case"steel":a.Steel=Math.round(35e4**r);break;case"alloy":a.Alloy=Math.round(25e4**r);break;case"neutronium":a.Neutronium=Math.round(1e4**r)}switch(e.engine){case"ion":a.Titanium=Math.round(75e3**s);break;case"tie":a.Titanium=Math.round(15e4**s);break;case"pulse":a.Titanium=Math.round(125e3**s);break;case"photon":a.Titanium=Math.round(21e4**s);break;case"vacuum":a.Titanium=Math.round(3e5**s);break;case"emdrive":a.Titanium=Math.round(125e4**s)}let c=!!["dreadnought","explorer"].includes(e.class);switch(e.power){case"solar":case"diesel":a[c?"Orichalcum":"Copper"]=Math.round(4e4**r),a.Iridium=Math.round(15e3**s);break;case"fission":a[c?"Orichalcum":"Copper"]=Math.round(5e4**r),a.Iridium=Math.round(3e4**s);break;case"fusion":a[c?"Orichalcum":"Copper"]=Math.round(5e4**r),a.Iridium=Math.round(4e4**s);break;case"elerium":a[c?"Orichalcum":"Copper"]=Math.round(6e4**r),a.Iridium=Math.round(55e3**s)}if("explorer"!==e.class)switch(e.sensor){case"radar":a.Money=Math.round(a.Money**1.04);break;case"lidar":a.Money=Math.round(a.Money**1.08);break;case"quantum":a.Money=Math.round(a.Money**1.12)}switch(e.weapon){case"railgun":a.Iron=Math.round(25e3**r);break;case"laser":a.Iridium=Math.round(a.Iridium**1.05),a.Nano_Tube=Math.round(12e3**r);break;case"p_laser":a.Iridium=Math.round(a.Iridium**1.035),a.Nano_Tube=Math.round(12e3**r);break;case"plasma":a.Iridium=Math.round(a.Iridium**1.1),a.Nano_Tube=Math.round(2e4**r);break;case"phaser":a.Iridium=Math.round(a.Iridium**1.15),a.Quantium=Math.round(18e3**r);break;case"disruptor":a.Iridium=Math.round(a.Iridium**1.2),a.Quantium=Math.round(35e3**r)}"explorer"===e.class&&(a.Iron*=10,a.Titanium*=5,a.Iridium*=50);let o=0;t.space.shipyard.ships.forEach((function(t){t.class===e.class&&o++}));let n=1+(o-2)/25*i;return Object.keys(a).forEach((function(t){"explorer"===e.class?a[t]=Math.ceil(a[t]*(3*(o+1))):o<2?a[t]=Math.ceil(a[t]*(0===o?.75:.9)):o>2&&(a[t]=Math.ceil(a[t]*n))})),a}function dt(){let e=$("#shipList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}function _t(){if(dt(),rc($("#shipList")),t.tech.isolation)return;let e=$("#shipList");if(t.space.shipyard.sort){let e={spc_dwarf:"a"};t.space.shipyard.ships=t.space.shipyard.ships.sort(((t,a)=>(e[t.location]?e[t.location]:t.location).localeCompare(e[a.location]?e[a.location]:a.location)))}const a=Dt();for(let r=0;r${e}`}}else Object.keys(a).forEach((function(e){if(s.location!==e&&(a[e].info.syndicate()||"spc_dwarf"===e)&&(!t.race.orbit_decayed||t.race.orbit_decayed&&"spc_moon"!==e)){let t="string"==typeof a[e].info.name?a[e].info.name:a[e].info.name();i+=`${t}`}}));let c="tauceti"===s.location?F("tech_era_tauceti"):"string"==typeof a[s.location].info.name?a[s.location].info.name:a[s.location].info.name(),o=`\n ${i}\n `;if(t.space.shipyard.expand){let t=`${F(`outer_shipyard_engine_${s.engine}`)} ${F(`outer_shipyard_class_${s.class}`)}`,a=$(`
    `),i=$(`
    ${s.name} | ${F("outer_shipyard_scrap")} | ${t} | ${F(`outer_shipyard_weapon_${s.weapon}`)} | ${F(`outer_shipyard_power_${s.power}`)} | ${F(`outer_shipyard_armor_${s.armor}`)} | ${F(`outer_shipyard_sensor_${s.sensor}`)}
    `),c=$('
    '),n=$('
    '),l=$(`
    ${o}
    `);c.append(`${F("crew")} `),c.append(`${F("firepower")} `),c.append(`${F("outer_shipyard_sensors")} `),c.append(`${F("speed")} `),c.append(`${F("outer_shipyard_fuel")} `),c.append(`${F("outer_shipyard_hull")} `),n.append(``),a.append(i),a.append(c),a.append(n),a.append(l),e.append(a)}else{let t=$(`
    `),a=$('
    '),i=$('
    '),c=$(`
    ${o}
    `);a.append(`${s.name} | `),a.append(`${F("firepower")} `),a.append(`${F("outer_shipyard_sensors")} `),a.append(`${F("speed")} `),a.append(`${F("outer_shipyard_fuel")} `),a.append(`${F("outer_shipyard_hull")} `),i.append(``),t.append(a),t.append(i),t.append(c),e.append(t)}sc({el:`#shipReg${r}`,data:t.space.shipyard.ships[r],methods:{scrap(e){t.space.shipyard.ships[e]&&"spc_dwarf"===t.space.shipyard.ships[e].location&&(t.space.shipyard.ships.splice(e,1),_t(),st())},scrapAllowed:e=>!(!t.space.shipyard.ships[e]||"spc_dwarf"!==t.space.shipyard.ships[e].location),setLoc(e,a){let r=t.space.shipyard.ships[a];if(e!==r.location){let s=it(r),i=r.transit>0||"spc_dwarf"!==r.location;if(i||t.civic.garrison.workers-t.civic.garrison.crew>=s){let c=pt(r,e),o=yt(r.xy,c),n=nt(r);r.location=e,r.transit=Math.round(o/n),r.dist=Math.round(o/n),r.origin=zc(r.xy),r.destination={x:c.x,y:c.y},i||(t.civic.garrison.crew+=s),_t(),Ei(`ship${a}loc${e}`)}}},crewText:e=>it(t.space.shipyard.ships[e]),fireText:e=>ot(t.space.shipyard.ships[e]),sensorText:e=>mt(t.space.shipyard.ships[e])+"km",speedText(e){let a=7.695363719135802*nt(t.space.shipyard.ships[e]);return Math.round(a)+"km/s"},fuelText(e){let a=lt(t.space.shipyard.ships[e]);return a.res?`${a.burn} ${t.resource[a.res].name}/s`:"N/A"},hullText:e=>100-t.space.shipyard.ships[e].damage+"%",hullDamage:e=>t.space.shipyard.ships[e].damage<=10?"has-text-success":t.space.shipyard.ships[e].damage>=40&&t.space.shipyard.ships[e].damage<65?"has-text-caution":t.space.shipyard.ships[e].damage>=65?"has-text-danger":"",dest(e){let r="explorer"===s.class?F("tech_era_tauceti"):"string"==typeof a[t.space.shipyard.ships[e].location].info.name?a[t.space.shipyard.ships[e].location].info.name:a[t.space.shipyard.ships[e].location].info.name();return F("outer_shipyard_arrive",[r,t.space.shipyard.ships[e].transit])},show:e=>t.space.shipyard.ships[e].transit>0}}),"explorer"===s.class?"tauceti"!==s.location&&Ti(`ship${r}loctauceti`,(function(){return F("transit_time",[Math.round(yt(s.xy,pt(s,"tauceti"))/nt(s))])}),{elm:`#ship${r}loc .tauceti`,placement:"left"}):Object.keys(a).forEach((function(e){(a[e].info.syndicate()||"spc_dwarf"===e)&&s.location!==e&&Ti(`ship${r}loc${e}`,(function(){return F("transit_time",[Math.round(yt(s.xy,pt(s,e))/nt(s))])}),{elm:`#ship${r}loc .${e}`,placement:"left"})}))}!function(){let e=$("#shipList")[0];Sortable.create(e,{onEnd(e){let a=t.space.shipyard.ships;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.space.shipyard.ships=a,_t()}})}()}function pt(e,a){if(-2===gt[a].orbit)return vt(a);let r=Math.sqrt((e.xy.x-xt(a))**2+e.xy.y**2),s=nt(e)/225,i=$t(1,a),c=Math.abs(r-gt[a].dist),o=Math.abs(r+gt[a].dist),n=Math.abs(r-gt[a].dist*i),l=Math.abs(r+gt[a].dist*i),u=Math.floor(Math.min(c,n,o,l)/s),d=Math.ceil(Math.max(c,n,o,l)/s);r>=gt[a].dist&&r<=gt[a].dist*i&&(u=0);let _=360/(-1===gt[a].orbit?t.city.calendar.orbit:gt[a].orbit),p=(t.space.position[a]+u*_)%360,h=Math.PI/180;for(let t=u;t<=d;t++){let r=$t(Math.cos(p*h)*gt[a].dist,a);r+=xt(a);let i=Math.sin(p*h)*gt[a].dist;if(Math.sqrt((r-e.xy.x)**2+(i-e.xy.y)**2)/s<=t)return{x:r,y:i};p=(p+_)%360}return vt(a)}function ht(e,a){if(!t.tech.isolation&&t.tech.syndicate&&t.race.truepath&&t.space.syndicate&&t.space.syndicate.hasOwnProperty(e)){let r=1e3,s=0;switch(t.civic.foreign.gov3.hstl<10?s=250-25*t.civic.foreign.gov3.hstl:t.civic.foreign.gov3.hstl>60&&(s=-13*(t.civic.foreign.gov3.hstl-60)),e){case"spc_home":case"spc_moon":case"spc_red":case"spc_hell":r=1250+s;break;case"spc_gas":case"spc_gas_moon":case"spc_belt":r=1020+s;break;case"spc_titan":case"spc_enceladus":case"spc_triton":case"spc_kuiper":case"spc_eris":r=Qr.space[e].info.syndicate_cap()}let o=t.space.syndicate[e],n=0,l=0,u=0;if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){if(t.space.shipyard.ships.forEach((function(t){if(t.location===e&&0===t.transit&&t.fueled){let e=ot(t);n+=t.damage>0?Math.round(e*(100-t.damage)/100):e,l+=mt(t)}})),"spc_enceladus"===e&&Math.min(c.operating_base,i.operating_base)>0){let e=Math.min(c.operating_base,i.operating_base);n+=50*e}else"spc_titan"===e&&i.sam>0?n+=25*i.sam:"spc_triton"===e&&i.fob>0&&(n+=500,l+=10);l>100&&(l=Math.round((l-100)/(l-100+200)*100)+100),n=Math.round(n*((l+25)/125)),n>o&&(u=n-o),o=o-n>0?o-n:0}return a?{p:1-+(o/r).toFixed(4),r:o,s:l,o:u}:1-+(o/r).toFixed(4)}return a?{p:1,r:0,s:0,o:0}:1}function mt(e){let t=1;switch(e.class){case"corvette":case"frigate":t=2;break;case"destroyer":case"cruiser":t=1.5;break;case"explorer":t=5;break;default:t=1}switch(e.sensor){case"visual":return 1;case"radar":return 10*t;case"lidar":return 18*t;case"quantum":return 32*t}}const gt={spc_sun:{dist:0,orbit:0,size:2},spc_home:{dist:1,orbit:-1,size:.6},spc_moon:{dist:1.01,orbit:-1,size:.1,moon:!0},spc_red:{dist:1.524,orbit:687,size:.5},spc_hell:{dist:.4,orbit:88,size:.4},spc_venus:{dist:.7,orbit:225,size:.5},spc_gas:{dist:5.203,orbit:4330,size:1.25},spc_gas_moon:{dist:5.204,orbit:4330,size:.2,moon:!0},spc_belt:{dist:2.7,orbit:1642,size:.5,belt:!0},spc_dwarf:{dist:2.77,orbit:1682,size:.5},spc_saturn:{dist:9.539,orbit:10751,size:1.1},spc_titan:{dist:9.536,orbit:10751,size:.2,moon:!0},spc_enceladus:{dist:9.542,orbit:10751,size:.1,moon:!0},spc_uranus:{dist:19.8,orbit:30660,size:1},spc_neptune:{dist:30.08,orbit:60152,size:1},spc_triton:{dist:30.1,orbit:60152,size:.1,moon:!0},spc_kuiper:{dist:39.5,orbit:90498,size:.5,belt:!0},spc_eris:{dist:68,orbit:204060,size:.5,size:.5},tauceti:{dist:752568.8,orbit:-2,size:2}};function ft(){t.space.position||(t.space.position={}),Object.keys(gt).forEach((function(e){t.space.position.hasOwnProperty(e)||(t.space.position[e]=Math.rand(0,360))})),t.space.position.spc_home=t.space.position.spc_moon,t.space.position.spc_gas_moon=t.space.position.spc_gas,t.space.position.spc_titan=t.space.position.spc_enceladus,t.space.position.spc_saturn=t.space.position.spc_titan,t.space.position.spc_neptune=t.space.position.spc_triton}function vt(e){let a=$t(+Math.cos(t.space.position[e]*(Math.PI/180)).toFixed(5)*gt[e].dist,e),r=+Math.sin(t.space.position[e]*(Math.PI/180)).toFixed(5)*gt[e].dist;return a+=xt(e),{x:a,y:r}}function yt(e,t){return Math.ceil(225*Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2))}function bt(e,a){let r=1;switch(t.race.pack_rat&&(r*=1+ui.pack_rat.vars()[1]/100),t.stats.achieve.blackhole&&(r*=1+.05*t.stats.achieve.blackhole.l),t.tech.world_control&&(r*=3),e){case"storehouse":i.titan_spaceport&&(r*=1+.25*i.titan_spaceport),a&&t.tech.shelving&&(r*=2),t.tech.shelving&&t.tech.shelving>=3&&(r*=1.5);case"repository":t.tech.isolation&&(r*=3,t.tech.tp_depot&&(r*=1+t.tech.tp_depot/20))}return r}function wt(){let e=0;return i.ai_colonist&&c.decoder&&(e+=i.ai_colonist*c.decoder*.35),c.shock_trooper&&(e+=2*c.shock_trooper),c.tank&&(e+=2*c.tank),e>100&&(e=100),e}function $t(e,a){if(-2!==gt[a].orbit){let r=1.075+gt[a].dist/100;t.city.ptrait.includes("elliptical")&&(r="spc_home"===a?1.5:1.275+gt[a].dist/100),e*=r}return e}function xt(e){if(-2!==gt[e].orbit){let a=gt[e].dist/3;return t.city.ptrait.includes("elliptical")&&"spc_home"===e&&(a+=.15),"spc_eris"===e&&(a+=25),a}return 0}var kt,qt;function Mt(){let e=document.getElementById("mapCanvas"),a=e.getContext("2d");e.width=e.getBoundingClientRect().width,e.height=e.getBoundingClientRect().height,a.save(),a.fillStyle="#000000",a.fillRect(0,0,e.width,e.height),a.translate(qt.x,qt.y),a.scale(kt,kt);let r={};for(let[e,t]of Object.entries(gt))r[e]=vt(e);a.lineWidth=1/kt,a.strokeStyle="#c0c0c0";for(let[e,r]of Object.entries(gt))if(!r.moon&&-2!==r.orbit){a.beginPath(),r.belt||t.race.orbit_decayed&&"spc_home"===e?a.setLineDash([.01,.01]):a.setLineDash([]);let s=xt(e);a.ellipse(s,0,$t(r.dist,e),r.dist,0,0,2*Math.PI,!0),a.stroke()}a.fillStyle="#0000ff",a.strokeStyle="#0000ff";for(let e of t.space.shipyard.ships)e.transit>0&&(a.beginPath(),a.setLineDash([.1,.4]),a.moveTo(e.xy.x,e.xy.y),a.lineTo(e.destination.x,e.destination.y),a.stroke());for(let[e,s]of Object.entries(gt)){if(t.race.orbit_decayed&&["spc_home","spc_moon"].includes(e))continue;let i="558888";if(Qr.space[e]&&Qr.space[e].info.syndicate()&&t.settings.space[e.substring(4)]){let t=ht(e);i=((Math.round(255*(1-t))<<16)+(Math.round(255*t)<<8)).toString(16).padStart(6,0)}"spc_dwarf"===e?i="7132a8":"spc_sun"!==e&&"tauceti"!==e||(i="f8ff2b"),a.fillStyle="#"+i,a.beginPath();let c=s.size/10;if(s.moon)switch(e){case"spc_moon":a.arc(r[e].x+.05,r[e].y+.05,c,0,2*Math.PI,!0);break;case"spc_titan":a.arc(r[e].x-.2,r[e].y-.2,c,0,2*Math.PI,!0);break;default:a.arc(r[e].x+.2,r[e].y+.2,c,0,2*Math.PI,!0)}else{let t=s.size/10;a.arc(r[e].x,r[e].y,t,0,2*Math.PI,!0)}a.fill()}a.fillStyle="#0000ff",a.strokeStyle="#0000ff";for(let e of t.space.shipyard.ships)e.transit>0&&(a.beginPath(),a.arc(e.xy.x,e.xy.y,.1,0,2*Math.PI,!0),a.fill());a.shadowOffsetX=2,a.shadowOffsetY=2,a.shadowBlur=2,a.shadowColor="rgba(0, 0, 0, 0.5)",a.fillStyle="#009aff",a.font=20/kt+"px serif";for(let e of t.space.shipyard.ships)e.transit>0&&a.fillText(e.name,e.xy.x+.15,e.xy.y-.15);a.fillStyle="#ffa500",a.font=25/kt+"px serif";for(let[e,s]of Object.entries(gt))if(Qr.space[e]&&t.settings.space[e.substring(4)]){if(t.race.orbit_decayed&&["spc_home"].includes(e))continue;let i=Qr.space[e].info.name,c="function"==typeof i?i():i;if(s.moon)switch(e){case"spc_moon":a.fillText(c,r[e].x+.1,r[e].y+.1);break;case"spc_titan":a.fillText(c,r[e].x-.3,r[e].y-.3);break;default:a.fillText(c,r[e].x+.25,r[e].y+.2)}else"spc_sun"===e||a.fillText(c,r[e].x,r[e].y-.2*s.size)}a.restore()}function Pt(e){switch(e){case"city":return t.resource[t.race.species]?t.resource[t.race.species].amount<=5?F("tab_city1"):t.resource[t.race.species].amount<=20?F("tab_city2"):t.resource[t.race.species].amount<=75?F("tab_city3"):t.resource[t.race.species].amount<=250?F("tab_city4"):t.resource[t.race.species].amount<=600?F("tab_city5"):t.resource[t.race.species].amount<=1200?F("tab_city6"):t.resource[t.race.species].amount<=2500?F("tab_city7"):F("tab_city8"):F("tab_city1");case"local_space":return F("sol_system",[t.race.truepath?di[t.race.species].home:Ac("name")]);case"outer_local_space":return F("outer_sol_system",[t.race.truepath?di[t.race.species].home:Ac("name")]);case"old":return F("tab_old_res");case"new":return F("tab_new_res");case"old_sr":return F("tab_old_sr_res");case"new_sr":return F("tab_new_sr_res");default:return F(e)}}function Ot(){t.settings.tabLoad?(Ct("mTabCivil"),Ct("mTabCivic"),Ct("mTabResearch"),Ct("mTabResource"),Ct("mTabArpa"),Ct("mTabStats"),Ct("mTabObserve")):Ct(t.settings.civTabs)}function Ct(e){switch(t.settings.tabLoad?Zi("page_view",{page_title:"Evolve - All Tabs"}):(Gs(),ri(),za(),De(),L(),dt(),rc($("#mTabCivil")),rc($("#mTabCivic")),rc($("#mTabResearch")),rc($("#mTabResource")),rc($("#mTabArpa")),rc($("#mTabStats")),rc($("#mTabObserve"))),e){case 0:t.settings.tabLoad||(Zi("page_view",{page_title:"Evolve - Evolution"}),ts());break;case 1:case"mTabCivil":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Civilization"}),$("#mTabCivil").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),sc({el:"#mTabCivil",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(rc($("#city")),rc($("#space")),rc($("#interstellar")),rc($("#galaxy")),rc($("#portal")),rc($("#outerSol")),rc($("#tauCeti")),e){case 0:hs();break;case 1:case 2:case 3:case 5:Rt();break;case 4:$a();break;case 6:tt()}return e}},filters:{label:e=>Pt(e)}}),"protoplasm"!==t.race.species&&(hs(),Rt(),$a(),tt()),t.race.noexport&&("Race"===t.race.noexport?(rc($("#city")),ra()):"Planet"===t.race.noexport&&(rc($("#city")),sa()));break;case 2:case"mTabCivic":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Civics"}),$("#mTabCivic").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),sc({el:"#mTabCivic",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(ri(),L(),za(),dt(),rc($("#civic")),rc($("#industry")),rc($("#powerGrid")),rc($("#military")),rc($("#mechLab")),rc($("#dwarfShipYard")),rc($("#psychicPowers")),e){case 0:$("#civic").append($('
    ')),oa(),$("#civics").append($('
    ')),V(),"protoplasm"===t.race.species||t.race.start_cataclysm||(Y(),fe($("#c_garrison"),!1),se()),t.race.shapeshifter&&qi(!1,!0);break;case 1:Ws();break;case 2:Object.keys(ai()).forEach((function(e){Li(e)})),ti();break;case 3:"protoplasm"===t.race.species||t.race.start_cataclysm||(J(),ka($("#fortress"),!1));break;case 4:"protoplasm"===t.race.species||t.race.start_cataclysm||Sa();break;case 5:t.race.truepath&&"protoplasm"!==t.race.species&&!t.race.start_cataclysm&&at();break;case 6:t.race.psychic&&t.tech.psychic&&"protoplasm"!==t.race.species&&zi()}return e}},filters:{label:e=>Pt(e)}}),Object.keys(ai()).forEach((function(e){Li(e)})),ti(),$("#civic").append($('
    ')),oa(),$("#civics").append($('
    ')),V(),"protoplasm"===t.race.species||t.race.start_cataclysm||(J(),fe($("#c_garrison"),!1),ka($("#fortress"),!1),se(),Sa(),t.race.truepath&&at(),t.race.psychic&&t.tech.psychic&&zi()),t.race.shapeshifter&&qi(!1,!0),Ws();break;case 3:case"mTabResearch":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Research"}),$("#mTabResearch").append('
    \n \n \n \n \n \n \n \n '),sc({el:"#mTabResearch",data:{s:t.settings,rq:t.r_queue},filters:{label:e=>Pt(e)}}),Bs(),"protoplasm"!==t.race.species&&ms();break;case 4:case"mTabResource":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Resources"}),$("#mTabResource").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),sc({el:"#mTabResource",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(rc($("#market")),rc($("#resStorage")),rc($("#resEjector")),rc($("#resCargo")),rc($("#resAlchemy")),e){case 0:ar("market");break;case 1:ar("storage");break;case 2:ar("ejector");break;case 3:ar("supply");break;case 4:ar("alchemy")}return e}},filters:{label:e=>Pt(e)}}),tr(),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let r=a.resource[e].color,s=a.resource[e].tradable;if(a.resource[e].stackable){var i=$(`
    `);$("#resStorage").append(i),fr(`#stack-${e}`,i,e,r)}s&&(i=$(`
    `),$("#market").append(i),ur(`#market-${e}`,i,e,r,!0)),Va[e]&&Ar(e,r),Ja[e]&&Er(e,r),Za[e]&&"magic"===t.race.universe&&(t.resource[e].basic=s,Kr(e,r,s))})),sr();break;case 5:case"mTabArpa":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Arpa"}),$("#mTabArpa").append(`
    \n \n \n \n \n \n \n
    `),sc({el:"#mTabArpa",data:{s:t.settings},filters:{label:e=>Pt(e)}}),Oe("Physics"),Oe("Genetics"),Oe("Crispr"),Oe("Blood");break;case 6:case"mTabStats":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Stats"}),$("#mTabStats").append('\n \n \n \n \n \n \n \n \n \n '),sc({el:"#mTabStats",data:{s:t.settings},filters:{label:e=>Pt(e)}}),function(){rc($("#achieve")),rc($("#stats"));let e=$('
    ');$("#stats").append(e);let a=$('
    ');$("#perks").append(a);let r=$('
    ');$("#achieve").append(r),function(){rc($("#statsPanel"));let e=$("#statsPanel");if(e.append(`
    ${F("achieve_stats_overall")}
    `),e.append(`
    ${F("achieve_stats_plasmid_earned")} {{ s.plasmid | format }}
    `),t.stats.antiplasmid>0&&e.append(`
    ${F("achieve_stats_antiplasmid_earned")} {{ s.antiplasmid | format }}
    `),t.stats.phage>0&&e.append(`
    ${F("achieve_stats_phage_earned")} {{ s.phage | format }}
    `),t.stats.dark>0&&e.append(`
    ${F("achieve_stats_dark_earned")} {{ s.dark | format }}
    `),t.stats.harmony>0&&e.append(`
    ${F("achieve_stats_harmony_earned")} {{ s.harmony | format }}
    `),t.stats.blood>0&&e.append(`
    ${F("achieve_stats_blood_earned")} {{ s.blood | format }}
    `),t.stats.artifact>0&&e.append(`
    ${F("achieve_stats_artifact_earned")} {{ s.artifact | format }}
    `),e.append(`
    ${F("achieve_stats_knowledge_spent")} {{ s.know | t_know | format }}
    `),e.append(`
    ${F("achieve_stats_starved_to_death")} {{ s.starved | t_starved | format }}
    `),e.append(`
    ${F("achieve_stats_died_in_combat")} {{ s.died | t_died | format }}
    `),e.append(`
    ${F("achieve_stats_game_days_played")} {{ s.days | played | format }}
    `),t.stats.portals>0&&e.append(`
    ${F("achieve_stats_portals")} {{ s.portals | format }}
    `),e.append(`
    ${F("achieve_stats_total_resets")} {{ s.reset | format }}
    `),t.stats.mad>0&&e.append(`
    ${F("achieve_stats_mad_resets")} {{ s.mad | format }}
    `),t.stats.bioseed>0&&e.append(`
    ${F("achieve_stats_bioseed_resets")} {{ s.bioseed | format }}
    `),t.stats.cataclysm>0&&e.append(`
    ${F("achieve_stats_cataclysm_resets")} {{ s.cataclysm | format }}
    `),t.stats.blackhole>0&&e.append(`
    ${F("achieve_stats_blackhole_resets")} {{ s.blackhole | format }}
    `),t.stats.ascend>0&&e.append(`
    ${F("achieve_stats_ascension_resets")} {{ s.ascend | format }}
    `),t.stats.descend>0&&e.append(`
    ${F("achieve_stats_descension_resets")} {{ s.descend | format }}
    `),t.stats.aiappoc>0&&e.append(`
    ${F("achieve_stats_aiappoc_resets")} {{ s.aiappoc | format }}
    `),t.stats.matrix>0&&e.append(`
    ${F("achieve_stats_matrix_resets")} {{ s.matrix | format }}
    `),t.stats.retire>0&&e.append(`
    ${F("achieve_stats_retire_resets")} {{ s.retire | format }}
    `),t.stats.eden>0&&e.append(`
    ${F("achieve_stats_eden_resets")} {{ s.eden | format }}
    `),t.stats.terraform>0&&e.append(`
    ${F("achieve_stats_terraform_resets")} {{ s.terraform | format }}
    `),t.stats.geck>0&&e.append(`
    ${F("achieve_stats_gecks")} {{ s.geck | format }}
    `),e.append(`
    ${F("achieve_stats_current_game")}
    `),e.append(`
    ${F("achieve_stats_knowledge_spent")} {{ s.know | format }}
    `),e.append(`
    ${F("achieve_stats_starved_to_death")} {{ s.starved | format }}
    `),e.append(`
    ${F("achieve_stats_died_in_combat")} {{ s.died | format }}
    `),e.append(`
    ${F("achieve_stats_attacks_made")} {{ s.attacks | format }}
    `),e.append(`
    ${F("achieve_stats_game_days_played")} {{ s.days | format }}
    `),t.stats.dkills>0&&e.append(`
    ${F("achieve_stats_demons_kills")} {{ s.dkills | format }}
    `),t.stats.sac>0&&e.append(`
    ${F("achieve_stats_sacrificed")} {{ s.sac | format }}
    `),t.stats.murders>0&&e.append(`
    ${F("achieve_stats_murders")} {{ s.murders | format }}
    `),t.stats.psykill>0&&e.append(`
    ${F("achieve_stats_psymurders")} {{ s.psykill | format }}
    `),t.resource.hasOwnProperty("Thermite")&&t.resource.Thermite.amount>0&&e.append(`
    ${F("achieve_stats_thermite")} {{ r.Thermite.amount | res }}
    `),Ic().active){let a="";(t.stats.cfood>=13||t.race.cataclysm||t.race.orbit_decayed)&&(a=`${kc(7,12,!0)}`),e.append(`
    ${F("achieve_stats_trickortreat")} {{ s.cfood | format }} ${a}
    `)}sc({el:"#statsPanel",data:{s:t.stats,r:t.resource},filters:{played:e=>e+t.stats.tdays,t_know:e=>e+t.stats.tknow,t_starved:e=>e+t.stats.tstarved,t_died:e=>e+t.stats.tdied,format:e=>e.toLocaleString(),res:e=>(+e.toFixed(2)).toLocaleString()}})}(),no(),$("body").hasClass("fool")?to({fool:!0}):to()}();break;case 7:t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Settings"});break;default:t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Hell Observation"}),t.portal.observe&&Ga(!0)}$("#popper").length>0&&0===$(`#${$("#popper").data("id")}`).length&&Ei()}const jt={spc_home:{info:{name:()=>di[t.race.species].home,desc:F("space_home_info_desc"),zone:"inner",syndicate:()=>!1},test_launch:{id:"space-test_launch",title:F("space_home_test_launch_title"),desc:F("space_home_test_launch_desc"),reqs:{space:1},grant:["space",2],queue_complete:()=>t.tech.space>=2?0:1,cost:{Money:()=>1e5,Oil:(e,t)=>Jt(7500,!1,t)},effect:F("space_home_test_launch_effect"),action(){if(Os($(this)[0])){if(t.race.truepath){let e=1;if(ue("gov0")||e++,ue("gov1")||e++,ue("gov2")||e++,0!==Math.floor(m(0,e)))return Di(F("space_home_test_launch_action_fail"),"danger",!1,["progress"]),0}return t.space.satellite={count:0},Di(F("space_home_test_launch_action"),"info",!1,["progress"]),!0}return!1}},satellite:{id:"space-satellite",title:F("space_home_satellite_title"),desc:F("space_home_satellite_desc"),reqs:{space:2},cost:{Money:e=>Xi("satellite",e,72e3,1.22),Knowledge:e=>Xi("satellite",e,28e3,1.22),Oil:(e,t)=>Xi("satellite",e,Jt(3200,!1,t),1.22),Alloy:e=>Xi("satellite",e,8e3,1.22)},effect(){let e=t.race.cataclysm||t.race.orbit_decayed?2e3:750;if((t.race.cataclysm||t.race.orbit_decayed)&&t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?5:10;e*=t.tech.supercollider/a+1}let a=t.race.cataclysm?F("space_moon_observatory_title"):t.race.orbit_decayed?F("city_university"):Ts(),r=`
    ${F("space_home_satellite_effect2",[a,t.race.cataclysm?25:t.race.orbit_decayed?12:4])}
    `;return`
    ${F("plus_max_resource",[e,F("resource_Knowledge_name")])}
    ${r}
    ${F("space_home_satellite_effect3",[t.civic.scientist?t.civic.scientist.name:F("job_scientist")])}
    `},action(){return!!Os($(this)[0])&&(Nt("satellite"),t.resource.Knowledge.max+=750,!0)}},gps:{id:"space-gps",title:F("space_home_gps_title"),desc:()=>t.space.hasOwnProperty("gps")&&t.space.gps.count<4?`
    ${F("space_home_gps_desc")}
    ${F("space_home_gps_desc_req")}
    `:`
    ${F("space_home_gps_desc")}
    `,reqs:{satellite:1},not_trait:["terrifying"],cost:{Money:e=>Xi("gps",e,75e3,1.18),Knowledge:e=>Xi("gps",e,5e4,1.18),Copper:e=>Xi("gps",e,6500,1.18),Oil:(e,t)=>Xi("gps",e,Jt(3500,!1,t),1.18),Titanium:e=>Xi("gps",e,8e3,1.18)},effect:e=>(e||0)+(t.space.hasOwnProperty("gps")?t.space.gps.count:0)<4?F("space_home_gps_effect_req"):`
    ${F("space_home_gps_effect")}
    ${F("space_home_gps_effect2",[2])}
    `,action(){return!!Os($(this)[0])&&(Nt("gps"),!0)}},propellant_depot:{id:"space-propellant_depot",title:F("space_home_propellant_depot_title"),desc:F("space_home_propellant_depot_desc"),reqs:{space_explore:1},cost:{Money:e=>Xi("propellant_depot",e,55e3,1.35),Aluminium:e=>Xi("propellant_depot",e,22e3,1.35),Oil:(e,t)=>Xi("propellant_depot",e,Jt(5500,!1,t),1.35)},effect(){let e=Lr(1250)*(t.tech.world_control?1.5:1);if(t.resource.Helium_3.display){let a=Lr(1e3)*(t.tech.world_control?1.5:1);return`
    ${F("plus_max_resource",[e,F("resource_Oil_name")])}
    ${F("plus_max_resource",[a,F("resource_Helium_3_name")])}
    `}return`
    ${F("plus_max_resource",[e,F("resource_Oil_name")])}
    `},action(){return!!Os($(this)[0])&&(Nt("propellant_depot"),t.resource.Oil.max+=Lr(1250)*(t.tech.world_control?1.5:1),t.resource.Helium_3.display&&(t.resource.Helium_3.max+=Lr(1e3)*(t.tech.world_control?1.5:1)),!0)}},nav_beacon:{id:"space-nav_beacon",title:()=>t.race.orbit_decayed?F("space_home_broadcast_beacon_title"):F("space_home_nav_beacon_title"),desc:`
    ${F("space_home_nav_beacon_desc")}
    ${F("requires_power")}
    `,reqs:{luna:2},cost:{Money:e=>Xi("nav_beacon",e,75e3,1.32),Copper:e=>Xi("nav_beacon",e,38e3,1.32),Aluminium:e=>Xi("nav_beacon",e,44e3,1.32),Oil:(e,t)=>Xi("nav_beacon",e,Jt(12500,!1,t),1.32),Iridium:e=>Xi("nav_beacon",e,1200,1.32)},powered:()=>oc(2),powerBalancer:()=>t.tech.luna&&t.tech.luna>=3?[{s:t.space.moon_base.s_max-t.space.moon_base.support},{s:t.space.spaceport.s_max-t.space.spaceport.support}]:[{s:t.space.moon_base.s_max-t.space.moon_base.support}],support:()=>1,effect(){let e="";return t.race.orbit_decayed&&t.tech.broadcast&&(e=`
    ${F("space_red_vr_center_effect1",[t.tech.broadcast/2])}
    `),`${t.race.orbit_decayed?"":`
    ${F("space_home_nav_beacon_effect1")}
    `}${t.tech.luna>=3?`
    ${F("space_red_spaceport_effect1",[Xt().red,1])}
    `:""}${e}
    ${F("space_home_nav_beacon_effect2",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("nav_beacon"),xs($(this)[0]),!0)}}},spc_moon:{info:{name:F("space_moon_info_name"),desc:()=>F("space_moon_info_desc",[di[t.race.species].home]),support:"moon_base",zone:"inner",syndicate:()=>!0},moon_mission:{id:"space-moon_mission",title:F("space_moon_mission_title"),desc:F("space_moon_mission_desc"),reqs:{space:2,space_explore:2},grant:["space",3],queue_complete:()=>t.tech.space>=3?0:1,cost:{Oil:(e,t)=>+Jt(12e3,!1,t).toFixed(0)},effect:F("space_moon_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("space_moon_mission_action"),"info",!1,["progress"]),t.space.iridium_mine={count:0,on:0},t.space.helium_mine={count:0,on:0},!0)}},moon_base:{id:"space-moon_base",title:F("space_moon_base_title"),desc:()=>`
    ${F("space_moon_base_desc")}
    ${F("requires_power_combo",[t.resource.Oil.name])}
    `,reqs:{space:3},cost:{Money:e=>Xi("moon_base",e,22e3,1.32),Cement:e=>Xi("moon_base",e,18e3,1.32),Alloy:e=>Xi("moon_base",e,7800,1.32),Polymer:e=>Xi("moon_base",e,12500,1.32)},effect(e){let t=Lr(500),a=+Jt($(this)[0].support_fuel().a,!0,e).toFixed(2);return`
    ${F("space_moon_base_effect1")}
    ${F("plus_max_resource",[t,F("resource_Iridium_name")])}
    ${F("space_moon_base_effect3",[a,$(this)[0].powered()])}
    `},support:()=>2,support_fuel:()=>({r:"Oil",a:2}),powered:()=>oc(4),powerBalancer:()=>[{s:t.space.moon_base.s_max-t.space.moon_base.support}],refresh:!0,action(){if(Os($(this)[0])){if(Nt("moon_base"),xs($(this)[0]),1===t.space.moon_base.count&&(t.tech.moon=1),!t.tech.luna&&(t.tech.luna=1,t.race.truepath)){let e=F("space_moon_base_msg",[ee(3)]);t.civic.foreign.gov3.hstl<10?e=`${e} ${F("space_moon_base_msg_ally")}`:t.civic.foreign.gov3.hstl>60&&(e=`${e} ${F("space_moon_base_msg_hstl")}`),Di(e,"info",!1,["progress"])}return t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+2500&&(t.race.orbit_decay=t.stats.days+2500,Di(F("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0}return!1}},iridium_mine:{id:"space-iridium_mine",title:F("space_moon_iridium_mine_title"),desc:`
    ${F("space_moon_iridium_mine_desc")}
    ${F("space_support",[F("space_moon_info_name")])}
    `,reqs:{space:3,luna:1},cost:{Money:e=>Xi("iridium_mine",e,42e3,1.35),Lumber:e=>Xi("iridium_mine",e,9e3,1.35),Titanium:e=>Xi("iridium_mine",e,17500,1.35)},effect(){let e=Pe("iridium_mine","iridium"),a=+e.b.toFixed(3),r="";t.race.truepath&&(t.civic.foreign.gov3.hstl<10?r=`
    ${F("space_rival_ally",[+(100*e.g).toFixed(1)])}
    `:t.civic.foreign.gov3.hstl>60&&(r=`
    ${F("space_rival_war",[+(100*e.g).toFixed(1)])}
    `));let s=t.race.cataclysm?`
    ${F("produce",[+Pe("iridium_mine","coal").toFixed(2),t.resource.Coal.name])}
    `:"",i=t.race.cataclysm?`
    ${F("produce",[+(Pe("iridium_mine","coal")/48).toFixed(3),t.resource.Uranium.name])}
    `:"";return`
    ${F("space_used_support",[F("space_moon_info_name")])}
    ${F("space_moon_iridium_mine_effect",[a])}
    ${r}${s}${i}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.resource.Iridium.display=!0,Nt("iridium_mine"),t.resource.Mythril.display||(t.resource.Mythril.display=!0,ha()),t.space.moon_base.support${F("space_moon_helium_mine_desc")}
    ${F("space_support",[F("space_moon_info_name")])}
    `,reqs:{space:3,luna:1},cost:{Money:e=>Xi("helium_mine",e,38e3,1.35),Aluminium:e=>Xi("helium_mine",e,9e3,1.35),Steel:e=>Xi("helium_mine",e,17500,1.35)},effect(){let e=Lr(100),a=Pe("helium_mine"),r=+a.b.toFixed(3),s="";return t.race.truepath&&(t.civic.foreign.gov3.hstl<10?s=`
    ${F("space_rival_ally",[+(100*a.g).toFixed(1)])}
    `:t.civic.foreign.gov3.hstl>60&&(s=`
    ${F("space_rival_war",[+(100*a.g).toFixed(1)])}
    `)),`
    ${F("space_used_support",[F("space_moon_info_name")])}
    ${F("space_moon_helium_mine_effect",[r])}
    ${s}
    ${F("plus_max_resource",[e,F("resource_Helium_3_name")])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.resource.Helium_3.display=!0,Nt("helium_mine"),t.space.moon_base.support${F("space_moon_observatory_desc")}
    ${F("space_support",[F("space_moon_info_name")])}
    `,reqs:{science:9,luna:1},cost:{Money:e=>Xi("observatory",e,2e5,1.28),Knowledge:e=>Xi("observatory",e,69e3,1.28),Stone:e=>Xi("observatory",e,125e3,1.28),Iron:e=>Xi("observatory",e,65e3,1.28),Iridium:e=>Xi("observatory",e,1250,1.28)},effect(){let e="";t.race.cataclysm&&(e=`
    ${F("city_university_effect",[la(1)])}
    `);let a=5e3;t.race.cataclysm&&t.space.satellite&&t.space.satellite.count>0&&(a*=1+.25*t.space.satellite.count);let r=t.race.cataclysm?`
    ${F("space_moon_observatory_cata_effect",[25])}
    `:`
    ${F("space_moon_observatory_effect",[5])}
    `;return`
    ${F("space_used_support",[F("space_moon_info_name")])}
    ${e}
    ${F("plus_max_resource",[a,F("resource_Knowledge_name")])}
    ${r}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("observatory"),t.space.moon_base.supportXt().red,desc:()=>F("space_red_info_desc",[Xt().red]),support:"spaceport",zone:"inner",syndicate:()=>!0},red_mission:{id:"space-red_mission",title:()=>F("space_mission_title",[Xt().red]),desc:()=>F("space_mission_desc",[Xt().red]),reqs:{space:3,space_explore:3},grant:["space",4],queue_complete:()=>t.tech.space>=4?0:1,cost:{Helium_3:(e,t)=>+Jt(4500,!1,t).toFixed(0)},effect:()=>F("space_red_mission_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(Di(F("space_red_mission_action",[Xt().red]),"info",!1,["progress"]),t.space.living_quarters={count:0,on:0},t.space.garage={count:0},t.space.red_mine={count:0,on:0},t.space.fabrication={count:0,on:0},!0)}},spaceport:{id:"space-spaceport",title:F("space_red_spaceport_title"),desc:()=>`
    ${F("space_red_spaceport_desc")}
    ${F("requires_power_space",[t.resource.Food.name])}
    `,reqs:{space:4},cost:{Money:e=>Xi("spaceport",e,47500,1.32),Iridium:e=>Xi("spaceport",e,1750,1.32),Mythril:e=>Xi("spaceport",e,25,1.32),Titanium:e=>Xi("spaceport",e,22500,1.32)},effect(e){let a=+Jt($(this)[0].support_fuel().a,!0,e).toFixed(2),r="";return(t.race.cataclysm||t.race.orbit_decayed)&&(r=`
    ${F("plus_max_resource",[`$${Lr(4*Hs())}`,F("resource_Money_name")])}
    `),`
    ${F("space_red_spaceport_effect1",[Xt().red,$(this)[0].support()])}
    ${r}
    ${F("space_red_spaceport_effect2",[a,$(this)[0].powered()])}
    ${F("spend",[t.race.cataclysm?2:25,t.resource.Food.name])}
    `},support(){let e=t.race.cataclysm||t.race.orbit_decayed?4:3;return t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=4&&e++,e},support_fuel:()=>({r:"Helium_3",a:1.25}),powered:()=>oc(5),powerBalancer:()=>[{s:t.space.spaceport.s_max-t.space.spaceport.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("spaceport"),xs($(this)[0]),t.tech.mars||(t.tech.mars=1),t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+1e3&&(t.race.orbit_decay=t.stats.days+1e3,Di(F("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0)}},red_tower:{id:"space-red_tower",title:F("space_red_tower_title"),desc:()=>`
    ${F("space_red_tower_desc")}
    ${F("requires_power")}
    `,reqs:{mars:3},cost:{Money:e=>Xi("red_tower",e,225e3,1.28),Iron:e=>Xi("red_tower",e,22e3,1.28),Cement:e=>Xi("red_tower",e,15e3,1.28),Alloy:e=>Xi("red_tower",e,8e3,1.28)},effect(){return`
    ${F("space_red_spaceport_effect1",[Xt().red,t.race.cataclysm?2:1])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(2),powerBalancer:()=>[{s:t.space.spaceport.s_max-t.space.spaceport.support}],support:()=>t.race.cataclysm?2:1,action(){return!!Os($(this)[0])&&(Nt("red_tower"),xs($(this)[0]),!0)}},captive_housing:Vr("captive_housing","space"),terraformer:{id:"space-terraformer",title:F("space_terraformer"),desc:e=>!t.space.hasOwnProperty("terraformer")||t.space.terraformer.count<100||e?`
    ${F("space_terraformer")}
    ${F("requires_segmemts",[100])}
    `+(t.space.hasOwnProperty("terraformer")&&t.space.terraformer.count>=100?`
    ${F("requires_power")}
    `:""):`
    ${F("space_terraformer")}
    `,reqs:{terraforming:1},condition:()=>!(t.space.terraformer.count>=100),queue_size:5,queue_complete:()=>100-t.space.terraformer.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?75e5:75e6:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?25e4:75e4:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?1e3:0,Bolognium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:1e5:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?12e3:25e4:0,Soul_Gem:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:1:0,Nanoweave:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:75e3:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100&&t.race.truepath?75e3:0,Cipher:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100&&t.race.truepath?1e3:0},effect(e){let a=(e?e.count:0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0);if(a<100){let e=100-a;return`
    ${F("space_terraformer_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    `}return jt.spc_red.atmo_terraformer.effect(e)},action(){return!!(Os($(this)[0])&&t.space.terraformer.count<100)&&(Nt("terraformer","space"),t.space.terraformer.count>=100&&(t.tech.terraforming=2,t.space.atmo_terraformer={count:1,on:0},Rt(),Ei()),!0)}},atmo_terraformer:{id:"space-atmo_terraformer",title:F("space_terraformer"),desc:()=>`
    ${F("space_terraformer")}
    ${F("requires_power")}
    `,wiki:!1,reqs:{terraforming:2},condition:()=>t.space.terraformer.count>=100,queue_complete:()=>0,cost:{},powered:e=>oc((e?e.truepath:t.race.truepath)?500:5e3),postPower(e){e?setTimeout((function(){t.tech.terraforming=i.atmo_terraformer?3:2,Rt()}),250):(t.tech.terraforming=2,Rt())},effect(e){let t=zt(),a=$(this)[0].powered(e),r=a>0?`
    ${F("minus_power",[a])}
    `:"";return`
    ${F("space_terraformer_effect2")}
    ${t}${r}`},action:()=>!1},terraform:{id:"space-terraform",title:F("space_terraform"),desc:F("space_terraform"),reqs:{terraforming:3},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=zt();return`
    ${F("space_terraform_effect")}
    ${e}`},action(){return!!Os($(this)[0])&&(sa(),!0)}},assembly:Vr("assembly","space"),living_quarters:{id:"space-living_quarters",title:F("space_red_living_quarters_title"),desc:()=>`
    ${F("space_red_living_quarters_desc")}
    ${F("space_support",[Xt().red])}
    `,reqs:{mars:1},cost:{Money:e=>Xi("living_quarters",e,Qt(38e3),1.28),Steel:e=>Xi("living_quarters",e,Qt(15e3),1.28),Polymer:e=>Xi("living_quarters",e,Qt(9500),1.28),Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens(),a="";return(t.race.cataclysm||t.race.orbit_decayed)&&(a=`
    ${F("plus_max_resource",[`$${Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?"100000":"50000":"25000")}`,F("resource_Money_name")])}
    `),`
    ${F("space_used_support",[Xt().red])}
    ${a}
    ${F("plus_max_resource",[la(1),t.race.truepath?F("job_colonist_tp",[Xt().red]):F("colonist")])}
    ${F("plus_max_resource",[e,F("citizen")])}
    `},support:()=>-1,powered:()=>oc(1),action(){if(Os($(this)[0])){if(Nt("living_quarters"),t.civic.colonist.display=!0,t.space.spaceport.support0)){let e=t.civic[t.civic.d_job].workers-la(1)<0?t.civic[t.civic.d_job].workers:la(1);t.civic[t.civic.d_job].workers-=e,t.civic.colonist.workers+=e}return!0}return!1},citizens(){let e=t.race.cataclysm||t.race.orbit_decayed?2:1;return c.biodome&&(e+=(t.tech.mars>=6?.1:.05)*c.biodome),+la(e).toFixed(2)}},pylon:{id:"space-pylon",title:F("space_red_pylon"),desc:F("space_red_pylon"),reqs:{magic:2},condition:()=>!(!t.race.cataclysm&&!t.race.orbit_decayed),cost:{Money:e=>Xi("pylon",e,10,1.48),Stone:e=>Xi("pylon",e,12,1.42),Crystal:e=>Xi("pylon",e,8,1.42)-3},effect(){let e=Lr(2);return`
    ${F("gain",[+(.005*nc("magic")).toFixed(3),t.resource.Mana.name])}
    ${F("plus_max_resource",[e,t.resource.Mana.name])}
    `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!Os($(this)[0])&&(t.space.pylon.count++,t.resource.Mana.max+=Lr(2),!0)}},vr_center:{id:"space-vr_center",title:F("space_red_vr_center_title"),desc:()=>`
    ${F("space_red_vr_center_desc")}
    ${F("space_support",[Xt().red])}
    `,reqs:{mars:1,broadcast:3},cost:{Money:e=>Xi("vr_center",e,38e4,1.25),Copper:e=>Xi("vr_center",e,55e3,1.25),Stanene:e=>Xi("vr_center",e,1e5,1.25),Soul_Gem:e=>Xi("vr_center",e,1,1.25)},effect(){let e=N("gaslighter",1),a=e?e+1:1;return t.race.orbit_decayed&&(a+=2),`
    ${F("space_used_support",[Xt().red])}
    ${F("space_red_vr_center_effect1",[a])}
    ${F("space_red_vr_center_effect2",[2])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("vr_center"),t.space.spaceport.support`
    ${F("space_red_garage_desc")}
    `,reqs:{mars:1},cost:{Money:e=>Xi("garage",e,75e3,1.28),Iron:e=>Xi("garage",e,12e3,1.28),Brick:e=>Xi("garage",e,3e3,1.28),Sheet_Metal:e=>Xi("garage",e,1500,1.28)},wide:!0,res(){let e=["Copper","Iron","Cement","Steel","Titanium","Alloy","Nano_Tube","Neutronium","Infernite"];return(t.race.cataclysm||t.race.orbit_decayed)&&(e.push("Polymer"),e.push("Coal"),e.push("Lumber"),e.push("Chrysotile"),e.push("Stone"),e.push("Furs")),e},heavy:e=>!!["Copper","Iron","Steel","Titanium","Neutronium","Infernite"].includes(e),val(e){switch(e){case"Copper":return 6500;case"Iron":return 5500;case"Cement":return t.race.cataclysm?10500:6e3;case"Steel":return 4500;case"Titanium":return 3500;case"Alloy":case"Polymer":return 2500;case"Nano_Tube":return 25e3;case"Neutronium":return 125;case"Infernite":return 75;case"Coal":return 1500;case"Lumber":case"Chrysotile":case"Stone":return 7500;case"Furs":return 2200;default:return 0}},multiplier(e){let a=t.tech.particles>=4?1+t.tech.supercollider/20:1;return(t.tech.world_control||t.race.cataclysm||t.race.orbit_decayed)&&(a*=2),t.tech.shelving&&t.tech.shelving>=3&&(a*=1.5),a*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,e&&t.tech.shelving&&t.tech.shelving>=2?3*a:a},effect(){let e=$(this)[0].multiplier(!1),a=$(this)[0].multiplier(!0),r=t.tech.particles>=4?20+t.tech.supercollider:20;(t.tech.world_control||t.race.cataclysm||t.race.orbit_decayed)&&(r+=10);let s=t.race.cataclysm||t.race.orbit_decayed?`${F("plus_max_resource",[r,F("resource_Crates_name")])}`:"",i='
    ';i+=`${F("plus_max_resource",[r,F("resource_Containers_name")])}${s}`;for(const r of $(this)[0].res())if(t.resource[r].display){let s=$(this)[0].heavy(r);i+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(r))*(s?a:e)).toFixed(0),1),t.resource[r].name])}`}return i+="
    ",i},action(){if(Os($(this)[0])){Nt("garage");let e=$(this)[0].multiplier(!1),a=$(this)[0].multiplier(!0);for(const r of $(this)[0].res())if(t.resource[r].display){let s=$(this)[0].heavy(r);t.resource[r].max+=Lr($(this)[0].val(r))*(s?a:e)}return!0}return!1}},red_mine:{id:"space-red_mine",title:F("space_red_mine_title"),desc:()=>`
    ${F("space_red_mine_desc")}
    ${F("space_support",[Xt().red])}
    `,reqs:{mars:1},cost:{Money:e=>Xi("red_mine",e,5e4,1.32),Lumber:e=>Xi("red_mine",e,65e3,1.32),Iron:e=>Xi("red_mine",e,33e3,1.32)},effect(){let e=Pe("red_mine","copper"),a=Pe("red_mine","titanium"),r=+e.b.toFixed(3),s=+a.b.toFixed(3),i="";t.race.truepath&&(t.civic.foreign.gov3.hstl<10?i=`
    ${F("space_rival_ally",[+(100*e.g).toFixed(1)])}
    `:t.civic.foreign.gov3.hstl>60&&(i=`
    ${F("space_rival_war",[+(100*e.g).toFixed(1)])}
    `));let c=t.race.orbit_decayed?`
    ${F("city_mine_effect1",[la(1)])}
    ${F("city_coal_mine_effect1",[la(1)])}
    `:"",o=t.race.cataclysm||t.race.orbit_decayed&&!t.race.sappy?`
    ${F("space_red_mine_effect",[+Pe("red_mine","stone").toFixed(2),t.resource.Stone.name])}
    `:"",n=t.race.cataclysm||t.race.orbit_decayed&&t.race.smoldering?`
    ${F("space_red_mine_effect",[+Pe("red_mine","asbestos").toFixed(2),t.resource.Chrysotile.name])}
    `:"",l=t.race.cataclysm||t.race.orbit_decayed?`
    ${F("space_red_mine_effect",[+Pe("red_mine","aluminium").toFixed(2),t.resource.Aluminium.name])}
    `:"";return`
    ${F("space_used_support",[Xt().red])}
    ${c}
    ${F("space_red_mine_effect",[r,t.resource.Copper.name])}
    ${F("space_red_mine_effect",[s,t.resource.Titanium.name])}
    ${i}${n}${o}${l}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("red_mine"),t.space.spaceport.support`
    ${F("space_red_fabrication_desc")}
    ${F("space_support",[Xt().red])}
    `,reqs:{mars:1},cost:{Money:e=>Xi("fabrication",e,9e4,1.32),Copper:e=>Xi("fabrication",e,25e3,1.32),Cement:e=>Xi("fabrication",e,12e3,1.32),Wrought_Iron:e=>Xi("fabrication",e,1200,1.32)},effect(){let e=t.race.cataclysm&&!t.race.flier?`
    ${F("city_cement_plant_effect1",[la(1)])}
    `:"",a=t.race.cataclysm||t.race.orbit_decayed?5:2;return t.race.high_pop&&(a=Me(a)),`
    ${F("space_used_support",[Xt().red])}
    ${F("space_red_fabrication_effect1",[la(1)])}
    ${e}
    ${F("space_red_fabrication_effect2",[a])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("fabrication"),t.space.spaceport.support`
    ${F("space_red_factory_desc")}
    ${F("requires_power_combo",[t.resource.Helium_3.name])}
    `,reqs:{mars:4},cost:{Money:e=>Xi("red_factory",e,75e3,1.32),Brick:e=>Xi("red_factory",e,1e4,1.32),Coal:e=>Xi("red_factory",e,7500,1.32),Mythril:e=>Xi("red_factory",e,50,1.32)},effect(e){let a=`
    ${F("space_red_factory_effect1")}
    `;return t.tech.foundry>=7&&(a+=`
    ${F("space_red_factory_effect2")}
    `),t.race.orbit_decayed&&!t.race.flier&&(a+=`
    ${F("city_cement_plant_effect1",[la(1)])}
    `),a+=`
    ${F("space_red_factory_effect3",[+Jt(1,!0,e).toFixed(2),$(this)[0].powered()])}
    `,a},powered:()=>oc(3),special:!0,action(){return!!Os($(this)[0])&&(t.space.red_factory.count++,xs($(this)[0])&&t.city.factory.Alloy++,t.settings.showIndustry=!0,Ws(),!0)}},nanite_factory:Vr("nanite_factory","space"),biodome:{id:"space-biodome",title:()=>t.race.artifical?F("space_red_signal_tower_title"):t.race.soul_eater?F("space_red_asphodel_title"):F("space_red_biodome_title"),desc(){let e;return e=t.race.artifical?`
    ${F("space_red_signal_tower_title")}
    `:t.race.soul_eater?`
    ${F("space_red_asphodel_desc")}
    `:t.race.carnivore?`
    ${F("space_red_biodome_desc_carn")}
    `:`
    ${F("space_red_biodome_desc",[Xt().red])}
    `,`
    ${e}
    ${F("space_support",[Xt().red])}
    `},reqs:{mars:2},cost:{Money:e=>Xi("biodome",e,45e3,1.28),Lumber:e=>Xi("biodome",e,65e3,1.28),Brick:e=>Xi("biodome",e,1e3,1.28),Nanite:e=>t.race.deconstructor?Xi("biodome",e,75,1.28):0},effect(){let e=+Pe("biodome","food").toFixed(2),a=t.race.cataclysm||t.race.orbit_decayed?`
    ${F("produce",[+Pe("biodome","cat_food").toFixed(2),t.resource.Food.name])}
    `:"",r=!t.race.cataclysm&&!t.race.orbit_decayed||t.race.kindling_kindred?"":`
    ${F("space_red_mine_effect",[+Pe("biodome","lumber").toFixed(2),t.resource.Lumber.name])}
    `,s=t.tech.mars>=6?.1:.05,i=t.race.artifical?F("city_transmitter_effect",[Lr(500)]):F("plus_max_resource",[Lr(100),F("resource_Food_name")]),c=t.race.artifical||t.race.orbit_decayed?`
    ${i}${F("space_used_support",[Xt().red])}
    ${a}
    ${F("space_red_biodome_effect",[e,t.resource.Food.name])}
    ${F("space_red_biodome_effect2",[+la(s).toFixed(2)])}
    ${r}${c}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("biodome"),t.race.cataclysm||(Xc("colonist"),t.race.joyless&&(Xc("joyless"),delete t.race.joyless,ms())),t.space.spaceport.supportt.race.artifical?F("space_red_signal_tower_flair"):t.race.soul_eater?F("space_red_asphodel_flair"):t.race.carnivore?F("space_red_biodome_flair_carn"):F("space_red_biodome_flair")},red_university:{id:"space-red_university",title:F("city_university"),desc:()=>F("city_university_desc",[Xt().red]),reqs:{mars:1},trait:["orbit_decayed"],cost:{Money:e=>Xi("university",e,900,1.5,"city")-500,Lumber:e=>Xi("university",e,500,1.36,"city")-200,Stone:e=>Xi("university",e,750,1.36,"city")-350,Crystal:e=>"magic"===t.race.universe?Xi("university",e,5,1.36,"city"):0},wiki:!1,effect:()=>Qr.city.university.effect(),action(){if(Os($(this)[0])){let e=t.tech.science&&t.tech.science>=8?700:500;if(t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,t.city.university.count++,t.space.red_university.count=t.city.university.count,t.civic.professor.display=!0,t.civic.professor.max=t.city.university.count,!0}return!1}},exotic_lab:{id:"space-exotic_lab",title:F("space_red_exotic_lab_title"),desc:()=>`
    ${F("space_red_exotic_lab_desc")}
    ${F("space_support",[Xt().red])}
    `,reqs:{mars:5},cost:{Money:e=>Xi("exotic_lab",e,75e4,1.28),Steel:e=>Xi("exotic_lab",e,1e5,1.28),Mythril:e=>Xi("exotic_lab",e,1e3,1.28),Elerium:e=>Xi("exotic_lab",e,20,1.28)-4},effect(){let e=500;t.tech.science>=13&&t.interstellar.laboratory&&o.laboratory&&(e+=25*o.laboratory),t.tech.ancient_study&&t.tech.ancient_study>=2&&(e+=15*t.space.ziggurat.count),t.tech.mass>=2&&i.mass_driver&&(e+=Me(i.mass_driver*t.civic.scientist.workers)),t.tech.science>=21&&(e*=1.45),t.race.high_pop&&(e=Me(e));let a=Lr(10),r="",s="";return(t.race.cataclysm||t.race.orbit_decayed)&&(r=`
    ${F("city_wardenclyffe_effect1",[la(1),t.civic.scientist.name])}
    `,e*=1+.25*c.observatory,t.tech.science>=15&&(s=`
    ${F("city_wardenclyffe_effect4",[2])}
    `)),`
    ${F("space_used_support",[Xt().red])}
    ${r}${s}
    ${F("space_red_exotic_lab_effect1",[+e.toFixed(0)])}
    ${F("plus_max_resource",[a,F("resource_Elerium_name")])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("exotic_lab"),t.space.spaceport.support`
    ${F("space_red_exotic_lab_flair1")}
    ${F("space_red_exotic_lab_flair2")}
    `},ziggurat:{id:"space-ziggurat",title:F("space_red_ziggurat_title"),desc:()=>`
    ${F("space_red_ziggurat_desc",["none"!==t.race.old_gods?di[t.race.old_gods.toLowerCase()].entity:di[t.race.species].entity])}
    `,reqs:{theology:4},cost:{Money:e=>Xi("ziggurat",e,6e5,1.28),Stone:e=>Xi("ziggurat",e,25e4,1.28),Aluminium:e=>Xi("ziggurat",e,7e4,1.28),Mythril:e=>Xi("ziggurat",e,250,1.28)},effect(){let e=t.tech.ancient_study?.6:.4;if(t.tech.ancient_deify&&t.tech.ancient_deify>=2&&c.exotic_lab&&(e+=.01*c.exotic_lab),"theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let a=.002;t.race.high_pop&&(a=Me(a)),e+=a*t.civic.priest.workers}t.race.ooze&&(e*=1-ui.ooze.vars()[1]/100),t.race.high_pop&&(e=Me(e)),e=+e.toFixed(2);let a=t.race.truepath?[e,di[t.race.species].home]:[e],r=`
    ${F(t.race.truepath?"space_red_ziggurat_effect_tp":"space_red_ziggurat_effect",a)}
    `;return t.tech.ancient_study&&t.tech.ancient_study>=2&&(r+=`
    ${F("interstellar_laboratory_effect",[3])}
    `),(t.race.cataclysm||t.race.orbit_decayed)&&(r+=rs()),t.genes.ancients&&t.genes.ancients>=4&&(r+=`
    ${F("city_temple_effect6",[la(1)])}
    `),r},action(){return!!Os($(this)[0])&&(Nt("ziggurat"),t.genes.ancients&&t.genes.ancients>=4&&(t.civic.priest.display=!0),t.race.cataclysm&&Xc("iron_will",!1,1),!0)}},space_barracks:{id:"space-space_barracks",title:F("space_red_space_barracks_title"),desc:()=>`
    ${F("space_red_space_barracks_desc")}
    ${F("space_red_space_barracks_desc_req")}
    `,reqs:{marines:1},cost:{Money:e=>Xi("space_barracks",e,35e4,1.28),Alloy:e=>Xi("space_barracks",e,65e3,1.28),Iridium:e=>Xi("space_barracks",e,22500,1.28),Wrought_Iron:e=>Xi("space_barracks",e,12500,1.28),Horseshoe:()=>t.race.hooved?2:0},effect(e){let a=t.race.orbit_decayed?Qr.city.boot_camp.effect():"",r=+Jt(2,!0,e).toFixed(2),s=t.tech.marines>=2?la(4):la(2),i=t.race.cataclysm?"":`
    ${F("space_red_space_barracks_effect3",[t.resource.Food.name])}
    `;return`
    ${F("plus_max_soldiers",[s])}
    ${a}
    ${F("space_red_space_barracks_effect2",[r])}
    ${i}`},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("space_barracks"),t.space.space_barracks.on++,!0)},flair:()=>F("space_red_space_barracks_flair")},bonfire:Vr("bonfire","space"),horseshoe:Vr("horseshoe","space")},spc_hell:{info:{name:()=>Xt().hell,desc:()=>F("space_hell_info_desc",[Xt().hell]),zone:"inner",syndicate:()=>!1},hell_mission:{id:"space-hell_mission",title:()=>F("space_mission_title",[Xt().hell]),desc:()=>F("space_mission_desc",[Xt().hell]),reqs:{space:3,space_explore:3},grant:["hell",1],queue_complete:()=>t.tech.hell>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(6500,!1,t).toFixed(0)},effect:()=>F("space_hell_mission_effect1",[Xt().hell]),action(){return!!Os($(this)[0])&&(Di(F("space_hell_mission_action",[Xt().hell]),"info",!1,["progress"]),t.space.geothermal={count:0,on:0},!0)}},geothermal:{id:"space-geothermal",title:F("space_hell_geothermal_title"),desc:()=>`
    ${F("space_hell_geothermal_desc")}
    ${F("space_hell_geothermal_desc_req")}
    `,reqs:{hell:1},cost:{Money:e=>Xi("geothermal",e,38e3,1.35),Steel:e=>Xi("geothermal",e,15e3,1.35),Polymer:e=>Xi("geothermal",e,9500,1.35)},effect(e){let a=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(2);return`${t.race.cataclysm||t.race.orbit_decayed?`
    ${F("interstellar_stellar_forge_effect3",[1])}
    `:""}${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${F("space_belt_station_effect3",[a])}`},special:()=>!(!t.race.cataclysm&&!t.race.orbit_decayed),powered(){let e=-8;return t.race.forge&&(e-=ui.forge.vars()[0]),t.stats.achieve.failed_history&&t.stats.achieve.failed_history.l>=5&&(e-=2),cc(e)},p_fuel:()=>({r:"Helium_3",a:.5}),action(){return!!Os($(this)[0])&&(Nt("geothermal"),t.space.geothermal.on++,!0)}},hell_smelter:{id:"space-hell_smelter",title:()=>F("space_hell_smelter_title",[Xt().hell]),desc:()=>F("space_hell_smelter_title",[Xt().hell]),reqs:{hell:1,m_smelting:1},path:["truepath"],cost:{Money:e=>Xi("hell_smelter",e,25e4,1.24),Adamantite:e=>Xi("hell_smelter",e,15e3,1.24)},effect:()=>`
    ${F("interstellar_stellar_forge_effect3",[2])}
    `,special:!0,action(){return!!Os($(this)[0])&&(Nt("hell_smelter"),t.city.smelter.cap+=2,t.city.smelter.Steel+=2,t.city.smelter.Oil+=2,!0)}},spc_casino:{id:"space-spc_casino",title:F("city_casino"),desc:F("city_casino"),category:"commercial",reqs:{hell:1,gambling:1},condition:()=>!!(t.race.cataclysm||t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=5),cost:{Money:e=>Xi("spc_casino",e,4e5,1.35),Furs:e=>Xi("spc_casino",e,75e3,1.35),Cement:e=>Xi("spc_casino",e,1e5,1.35),Plywood:e=>Xi("spc_casino",e,2e4,1.35)},effect(){let e=ss();return e+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,e},powered:()=>oc(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2?2:3),action(){return!!Os($(this)[0])&&(t.space.spc_casino.count++,t.race.joyless||(t.civic.entertainer.max+=la(1),t.civic.entertainer.display=!0),xs($(this)[0]),!0)},flair:F("city_casino_flair")},swarm_plant:{id:"space-swarm_plant",title:F("space_hell_swarm_plant_title"),desc:()=>`
    ${F("space_hell_swarm_plant_desc")}
    `,reqs:{solar:4,hell:1},cost:{Money:e=>Xi("swarm_plant",e,Zt(75e3),1.28),Iron:e=>Xi("swarm_plant",e,Zt(65e3),1.28),Neutronium:e=>Xi("swarm_plant",e,Zt(75),1.28),Brick:e=>Xi("swarm_plant",e,Zt(2500),1.28),Mythril:e=>Xi("swarm_plant",e,Zt(100),1.28)},effect(){let e=t.tech.swarm?.88:.94;return t.tech.swarm>=3&&(e-=u/100),e<.05&&(e=.05),e=+(100*(1-e)).toFixed(2),F("space_hell_swarm_plant_effect1",[e])},action(){return!!Os($(this)[0])&&(Nt("swarm_plant"),!0)}},firework:Vr("firework","space")},spc_sun:{info:{name:()=>F("space_sun_info_name"),desc:()=>F("space_sun_info_desc",[di[t.race.species].home]),support:"swarm_control",zone:"inner",syndicate:()=>!1},sun_mission:{id:"space-sun_mission",title:()=>F("space_sun_mission_title"),desc:()=>F("space_sun_mission_desc"),reqs:{space_explore:4},grant:["solar",1],queue_complete:()=>t.tech.solar>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(15e3,!1,t).toFixed(0)},effect:()=>F("space_sun_mission_effect1"),action(){return!!Os($(this)[0])}},swarm_control:{id:"space-swarm_control",title:F("space_sun_swarm_control_title"),desc:()=>`
    ${F("space_sun_swarm_control_desc")}
    `,reqs:{solar:3},cost:{Money:e=>Xi("swarm_control",e,1e5,1.3),Knowledge:e=>Xi("swarm_control",e,6e4,1.3),Alloy:e=>Xi("swarm_control",e,7500,1.3),Helium_3:(e,t)=>Xi("swarm_control",e,Jt(2e3,!1,t),1.3),Mythril:e=>Xi("swarm_control",e,250,1.3)},effect(){return F("space_sun_swarm_control_effect1",[$(this)[0].support()])},support:()=>t.tech.swarm&&t.tech.swarm>=2?t.tech.high_tech>=11?11+Math.round(u):12:10,action(){return!!Os($(this)[0])&&(Nt("swarm_control"),t.space.swarm_control.s_max+=$(this)[0].support(),!0)}},swarm_satellite:{id:"space-swarm_satellite",title:F("space_sun_swarm_satellite_title"),desc:()=>`
    ${F("space_sun_swarm_satellite_desc")}
    ${F("space_sun_swarm_satellite_desc_req")}
    `,reqs:{solar:3},cost:{Money:e=>Xi("swarm_satellite",e,Vt(5e3),1.1),Copper:e=>Xi("swarm_satellite",e,Vt(2500),1.1),Iridium:e=>Xi("swarm_satellite",e,Vt(150),1.1),Helium_3:(e,t)=>Xi("swarm_satellite",e,Vt(Jt(50,!1,t)),1.1)},effect(){let e=.35;return t.tech.swarm>=4&&(e+=.15*(t.tech.swarm-3)),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1&&(e+=.15),t.blood.illuminate&&(e+=.01*t.blood.illuminate),e=+e.toFixed(2),`${F("space_dwarf_reactor_effect1",[cc(e)])}, ${F("space_sun_swarm_satellite_effect1",[1])}`},support:()=>-1,action(){return!!Os($(this)[0])&&(Nt("swarm_satellite"),t.space.swarm_control.support++,!0)}},jump_gate:{id:"space-jump_gate",title:F("tau_jump_gate"),desc:e=>!t.space.hasOwnProperty("jump_gate")||t.space.jump_gate.count<100||e?`
    ${F("tau_jump_gate")}
    ${F("requires_segmemts",[100])}
    `:`
    ${F("tau_jump_gate")}
    `,reqs:{tauceti:3},path:["truepath"],queue_size:10,queue_complete:()=>100-t.space.jump_gate.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?1e6:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?5e4:0,Adamantite:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?12500:0,Graphene:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?42e3:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?35e3:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?25e3:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0);if(a<100){let e=100-a;return`
    ${F("tau_jump_gate_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    `}return F("tau_jump_gate_effect")},action(){return!!(Os($(this)[0])&&t.space.jump_gate.count<100)&&(t.space.jump_gate.count++,!0)}}},spc_gas:{info:{name:()=>Xt().gas,desc:()=>F("space_gas_info_desc",[Xt().gas,di[t.race.species].home]),zone:"outer",syndicate:()=>!0},gas_mission:{id:"space-gas_mission",title:()=>F("space_mission_title",[Xt().gas]),desc:()=>F("space_mission_desc",[Xt().gas]),reqs:{space:4,space_explore:4},grant:["space",5],queue_complete:()=>t.tech.space>=5?0:1,cost:{Helium_3:(e,t)=>+Jt(12500,!1,t).toFixed(0)},effect:()=>F("space_gas_mission_effect",[Xt().gas]),action(){return!!Os($(this)[0])&&(Di(F("space_gas_mission_action",[Xt().gas]),"info",!1,["progress"]),t.settings.space.gas_moon=!0,t.settings.space.belt=!0,t.space.space_station={count:0,on:0,support:0,s_max:0},!0)}},gas_mining:{id:"space-gas_mining",title:F("space_gas_mining_title"),desc:()=>`
    ${F("space_gas_mining_desc")}
    ${F("requires_power")}
    `,reqs:{gas_giant:1},cost:{Money:e=>Xi("gas_mining",e,25e4,1.32),Uranium:e=>Xi("gas_mining",e,500,1.32),Alloy:e=>Xi("gas_mining",e,1e4,1.32),Helium_3:(e,t)=>Xi("gas_mining",e,Jt(2500,!1,t),1.32),Mythril:e=>Xi("gas_mining",e,25,1.32)},effect(){return`
    ${F("space_gas_mining_effect1",[+Pe("gas_mining").toFixed(2)])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(2),action(){return!!Os($(this)[0])&&(Nt("gas_mining"),xs($(this)[0]),!0)}},gas_storage:{id:"space-gas_storage",title:()=>F("space_gas_storage_title",[Xt().gas]),desc:()=>`
    ${F("space_gas_storage_desc")}
    `,reqs:{gas_giant:1},cost:{Money:e=>Xi("gas_storage",e,125e3,1.32),Iridium:e=>Xi("gas_storage",e,3e3,1.32),Sheet_Metal:e=>Xi("gas_storage",e,2e3,1.32),Helium_3:(e,t)=>Xi("gas_storage",e,Jt(1e3,!1,t),1.32)},effect(){let e=Lr(3500)*(t.tech.world_control?1.5:1),a=Lr(2500)*(t.tech.world_control?1.5:1),r=Lr(1e3)*(t.tech.world_control?1.5:1);return`
    ${F("plus_max_resource",[e,F("resource_Oil_name")])}
    ${F("plus_max_resource",[a,F("resource_Helium_3_name")])}
    ${F("plus_max_resource",[r,F("resource_Uranium_name")])}
    `},action(){return!!Os($(this)[0])&&(Nt("gas_storage"),!0)}},star_dock:{id:"space-star_dock",title:()=>F("space_gas_star_dock_title"),desc:()=>`
    ${F("space_gas_star_dock_title")}
    ${F("space_gas_star_dock_desc_req")}
    `,reqs:{genesis:3},queue_complete:()=>1-t.space.star_dock.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?15e5:0,Steel:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?5e5:0,Helium_3:(e,a)=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?Math.round(Jt(1e4,!1,a)):0,Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?25e4:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?1e4:0},effect:()=>`
    ${F("space_gas_star_dock_effect1")}
    `,special:!0,action(){return!(0!==t.space.star_dock.count||!Os($(this)[0])||(Nt("star_dock"),0))}}},spc_gas_moon:{info:{name:()=>Xt().gas_moon,desc:()=>F("space_gas_moon_info_desc",[Xt().gas_moon,Xt().gas]),zone:"outer",syndicate:()=>!0},gas_moon_mission:{id:"space-gas_moon_mission",title:()=>F("space_mission_title",[Xt().gas_moon]),desc:()=>F("space_mission_desc",[Xt().gas_moon]),reqs:{space:5},grant:["space",6],queue_complete:()=>t.tech.space>=6?0:1,cost:{Helium_3:(e,t)=>+Jt(3e4,!1,t).toFixed(0)},effect:()=>F("space_gas_moon_mission_effect",[Xt().gas_moon]),action(){return!!Os($(this)[0])&&(Di(F("space_gas_moon_mission_action",[Xt().gas_moon]),"info",!1,["progress"]),t.space.outpost={count:0,on:0},t.tech.gas_moon=1,!0)}},outpost:{id:"space-outpost",title:F("space_gas_moon_outpost_title"),desc:()=>`
    ${F("space_gas_moon_outpost_desc")}
    ${F("requires_power_combo",[t.resource.Oil.name])}
    `,reqs:{gas_moon:1},cost:{Money:e=>Xi("outpost",e,666e3,1.3),Titanium:e=>Xi("outpost",e,18e3,1.3),Iridium:e=>Xi("outpost",e,2500,1.3),Helium_3:(e,t)=>Xi("outpost",e,Jt(6e3,!1,t),1.3),Mythril:e=>Xi("outpost",e,300,1.3)},effect(e){let t=+Pe("outpost").toFixed(3),a=Lr(500),r=+Jt(2,!0,e).toFixed(2);return`
    ${F("space_gas_moon_outpost_effect1",[t])}
    ${F("plus_max_resource",[a,F("resource_Neutronium_name")])}
    ${F("space_gas_moon_outpost_effect3",[r,$(this)[0].powered()])}
    `},powered:()=>oc(3),powerBalancer:()=>[{r:"Neutronium",k:"lpmod"}],action(){return!!Os($(this)[0])&&(Nt("outpost"),t.resource.Neutronium.display=!0,xs($(this)[0]),!0)}},drone:{id:"space-drone",title:F("space_gas_moon_drone_title"),desc:()=>`
    ${F("space_gas_moon_drone_desc")}
    `,reqs:{gas_moon:1,drone:1},cost:{Money:e=>Xi("drone",e,25e4,1.3),Steel:e=>Xi("drone",e,2e4,1.3),Neutronium:e=>Xi("drone",e,500,1.3),Elerium:e=>Xi("drone",e,25,1.3),Nano_Tube:e=>Xi("drone",e,45e3,1.3)},effect:()=>`
    ${F("space_gas_moon_drone_effect1",[t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3?12:6])}
    `,action(){return!!Os($(this)[0])&&(Nt("drone"),!0)}},oil_extractor:{id:"space-oil_extractor",title:F("space_gas_moon_oil_extractor_title"),desc:()=>`
    ${F("space_gas_moon_oil_extractor_title")}
    ${F("requires_power")}
    `,reqs:{gas_moon:2},cost:{Money:e=>Xi("oil_extractor",e,666e3,1.3),Polymer:e=>Xi("oil_extractor",e,7500,1.3),Helium_3:(e,t)=>Xi("oil_extractor",e,Jt(2500,!1,t),1.3),Wrought_Iron:e=>Xi("oil_extractor",e,5e3,1.3)},effect(){return`${F("space_gas_moon_oil_extractor_effect1",[+Pe("oil_extractor").toFixed(2)])}, ${F("minus_power",[$(this)[0].powered()])}`},powered:()=>oc(1),powerBalancer:()=>[{r:"Oil",k:"lpmod"}],action(){return!!Os($(this)[0])&&(Nt("oil_extractor"),xs($(this)[0]),!0)}}},spc_belt:{info:{name:()=>F("space_belt_info_name"),desc:()=>t.space.space_station&&t.space.space_station.count>0?`
    ${F("space_belt_info_desc",[Xt().red,Xt().gas])}
    ${F("space_belt_info_desc2")}
    `:F("space_belt_info_desc",[Xt().red,Xt().gas]),support:"space_station",zone:"inner",syndicate:()=>!0},belt_mission:{id:"space-belt_mission",title:()=>F("space_belt_mission_title"),desc:()=>F("space_belt_mission_desc"),reqs:{space:5},grant:["asteroid",1],queue_complete:()=>t.tech.asteroid>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(25e3,!1,t).toFixed(0)},effect:()=>F("space_belt_mission_effect1"),action(){return!!Os($(this)[0])&&(Di(F("space_belt_mission_action"),"info",!1,["progress"]),t.settings.space.dwarf=!0,!0)}},space_station:{id:"space-space_station",title:F("space_belt_station_title"),desc:()=>`
    ${F("space_belt_station_desc")}
    ${F("requires_power_space",[t.resource.Food.name])}
    `,reqs:{asteroid:2},cost:{Money:e=>Xi("space_station",e,25e4,1.3),Iron:e=>Xi("space_station",e,85e3,1.3),Polymer:e=>Xi("space_station",e,18e3,1.3),Iridium:e=>Xi("space_station",e,2800,1.28),Helium_3:(e,t)=>Xi("space_station",e,Jt(2e3,!1,t),1.3),Mythril:e=>Xi("space_station",e,75,1.25)},effect(e){let a=+Jt(2.5,!0,e).toFixed(2),r=t.race.cataclysm?1:10,s=Lr(5),i=t.tech.asteroid>=5?`
    ${F("plus_max_resource",[s,F("resource_Elerium_name")])}
    `:"";return`
    ${F("plus_max_space_miners",[la(3)])}
    ${i}
    ${F("space_belt_station_effect3",[a])}
    ${F("space_belt_station_effect4",[r,$(this)[0].powered(),t.resource.Food.name])}
    `},support:()=>la(3),powered:()=>oc(3),refresh:!0,action(){if(Os($(this)[0])){if(Nt("space_station"),t.civic.space_miner.display=!0,t.tech.asteroid<3&&(t.tech.asteroid=3),xs($(this)[0])&&t.civic[t.civic.d_job].workers>0){let e=la(3);t.civic[t.civic.d_job].workers-e<0&&(e=t.civic[t.civic.d_job].workers),t.civic[t.civic.d_job].workers-=e,t.civic.space_miner.workers+=e}return t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+1e3&&(t.race.orbit_decay=t.stats.days+1e3,Di(F("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0}return!1}},elerium_ship:{id:"space-elerium_ship",title:F("space_belt_elerium_ship_title"),desc:()=>F("space_belt_elerium_ship_title"),reqs:{asteroid:5},cost:{Money:e=>Xi("elerium_ship",e,5e5,1.3),Uranium:e=>Xi("elerium_ship",e,2500,1.3),Titanium:e=>Xi("elerium_ship",e,1e4,1.3),Mythril:e=>Xi("elerium_ship",e,500,1.3),Helium_3:(e,t)=>Xi("elerium_ship",e,Jt(5e3,!1,t),1.3)},effect(){let e=+Pe("elerium_ship").toFixed(4);return`
    ${F("space_belt_elerium_ship_effect1",[la(2)])}
    ${F("space_belt_elerium_ship_effect2",[e])}
    `},support:()=>la(-2),powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("elerium_ship"),t.space.space_station.support+1F("space_belt_iridium_ship_title"),reqs:{asteroid:3},cost:{Money:e=>Xi("iridium_ship",e,12e4,1.3),Uranium:e=>Xi("iridium_ship",e,1e3,1.3),Alloy:e=>Xi("iridium_ship",e,48e3,1.3),Iridium:e=>Xi("iridium_ship",e,2800,1.3),Helium_3:(e,t)=>Xi("iridium_ship",e,Jt(1800,!1,t),1.3)},effect(){let e=+Pe("iridium_ship").toFixed(3);return`
    ${F("space_belt_iridium_ship_effect1",[la(1)])}
    ${F("space_belt_iridium_ship_effect2",[e])}
    `},support:()=>la(-1),powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("iridium_ship"),t.space.space_station.supportF("space_belt_iron_ship_title"),reqs:{asteroid:3},cost:{Money:e=>Xi("iron_ship",e,8e4,1.3),Steel:e=>Xi("iron_ship",e,42e3,1.3),Aluminium:e=>Xi("iron_ship",e,38e3,1.3),Polymer:e=>Xi("iron_ship",e,16e3,1.3),Helium_3:(e,t)=>Xi("iron_ship",e,Jt(1200,!1,t),1.3)},effect(){let e=+Pe("iron_ship").toFixed(2);return t.tech.solar&&t.tech.solar>=5?`
    ${F("space_belt_iron_ship_effect1",[la(1)])}
    ${F("space_belt_iron_ship_effect2",[e])}
    ${F("space_belt_iron_ship_effect3")}
    `:`
    ${F("space_belt_iron_ship_effect1",[la(1)])}
    ${F("space_belt_iron_ship_effect2",[e])}
    `},support:()=>la(-1),powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("iron_ship"),t.space.space_station.supportXt().dwarf,desc:()=>F("space_dwarf_info_desc",[Xt().dwarf]),zone:"inner",syndicate:()=>!1},dwarf_mission:{id:"space-dwarf_mission",title:()=>F("space_mission_title",[Xt().dwarf]),desc:()=>F("space_mission_desc",[Xt().dwarf]),reqs:{asteroid:1,elerium:1},grant:["dwarf",1],queue_complete:()=>t.tech.dwarf>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(45e3,!1,t).toFixed(0)},effect:()=>F("space_dwarf_mission_effect1",[Xt().dwarf]),action(){return!!Os($(this)[0])&&(Di(F("space_dwarf_mission_action",[Xt().dwarf]),"info",!1,["progress"]),t.space.elerium_contain={count:0,on:0},!0)}},elerium_contain:{id:"space-elerium_contain",title:F("space_dwarf_elerium_contain_title"),desc:()=>`
    ${F("space_dwarf_elerium_contain_title")}
    ${F("requires_power")}
    `,reqs:{dwarf:1},cost:{Money:e=>Xi("elerium_contain",e,8e5,1.28),Cement:e=>Xi("elerium_contain",e,12e4,1.28),Iridium:e=>Xi("elerium_contain",e,5e4,1.28),Neutronium:e=>Xi("elerium_contain",e,250,1.28)},effect(){return`
    ${F("plus_max_resource",[Lr(100),F("resource_Elerium_name")])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(6),action(){return!!Os($(this)[0])&&(Nt("elerium_contain"),xs($(this)[0]),!0)}},e_reactor:{id:"space-e_reactor",title:F("space_dwarf_reactor_title"),desc:()=>`
    ${F("space_dwarf_reactor_title")}
    ${F("space_dwarf_reactor_desc_req")}
    `,reqs:{elerium:2},cost:{Money:e=>Xi("e_reactor",e,125e4,1.28),Steel:e=>Xi("e_reactor",e,35e4,1.28),Neutronium:e=>Xi("e_reactor",e,1250,1.28),Mythril:e=>Xi("e_reactor",e,2500,1.28)},effect(){let e=$(this)[0].p_fuel().a;return`
    ${F("space_dwarf_reactor_effect1",[-1*$(this)[0].powered()])}
    ${F("space_dwarf_reactor_effect2",[e])}
    `},powered:()=>cc(-25),p_fuel:()=>({r:"Elerium",a:.05}),action(){return!!Os($(this)[0])&&(Nt("e_reactor"),t.space.e_reactor.on++,!0)}},world_collider:{id:"space-world_collider",title:F("space_dwarf_collider_title"),desc(e){if(!t.space.hasOwnProperty("world_collider")||t.space.world_collider.count<1859||e)return`
    ${F("space_dwarf_collider_desc")}
    ${F("space_dwarf_collider_desc_req")}
    `+(t.space.hasOwnProperty("world_collider")&&t.space.world_collider.count>=1859?`
    ${F("requires_power")}
    `:"")},reqs:{science:10},path:["standard"],condition:()=>t.space.world_collider.count<1859,queue_size:100,queue_complete:()=>1859-t.space.world_collider.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?25e3:0,Copper:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?750:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?125:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?12:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?1:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?10:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0);if(a<1859){let e=1859-a;return`
    ${F("space_dwarf_collider_effect1")}
    ${F("space_dwarf_collider_effect2",[e])}
    `}return jt.spc_dwarf.world_controller.effect()},action(){if(t.space.world_collider.count<1859&&Os($(this)[0])){if(Nt("world_collider"),t.space.world_collider.count>=1859){if(t.tech.science=11,t.space.world_controller={count:1,on:0},ms(),Rt(),t.race.banana){let e=Yc();t.stats.banana.b2[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b2.l=!0)}Ei()}return!0}return!1},flair:F("space_dwarf_collider_flair")},world_controller:{id:"space-world_controller",title:F("space_dwarf_collider_title"),desc:()=>`
    ${F("space_dwarf_collider_title")}
    ${F("requires_power")}
    `,wiki:!1,reqs:{science:11},path:["standard"],condition:()=>!(t.space.world_collider.count<1859),queue_complete:()=>0,cost:{},effect(){let e=25;return t.interstellar.far_reach&&i.far_reach>0&&(e+=1*i.far_reach),t.tech.science>=19&&(e+=15),`
    ${F("plus_max_resource",[e+"%",F("resource_Knowledge_name")])}
    ${F("space_dwarf_controller_effect3")}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(20),action:()=>!1,flair:F("space_dwarf_controller_flair")},shipyard:{id:"space-shipyard",title:F("outer_shipyard_title"),desc:()=>`
    ${F("outer_shipyard_title")}
    ${F("requires_power")}
    `,reqs:{shipyard:1},path:["truepath"],cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e7:0,Aluminium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e6:0,Titanium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?65e4:0,Iridium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?25e4:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e4:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?5e5:0},queue_complete:()=>1-t.space.shipyard.count,effect(){return`
    ${F("outer_shipyard_effect")}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(50),special:!0,sAction(){i.shipyard&&(t.settings.civTabs=2,t.settings.govTabs=5,t.settings.tabLoad||(Ct("mTabCivic"),Ei("space-shipyard")))},action(){return!!(t.space.shipyard.count<1&&Os($(this)[0]))&&(Nt("shipyard"),xs($(this)[0])&&(t.settings.showShipYard=!0),t.tech.syard_class=2,t.tech.syard_armor=3,t.tech.syard_weapon=1,t.tech.syard_engine=2,t.tech.syard_power=3,t.tech.syard_sensor=3,!0)}},mass_relay:{id:"space-mass_relay",title:F("space_dwarf_mass_relay_title"),desc(e){if(!t.space.hasOwnProperty("mass_relay")||t.space.mass_relay.count<100||e)return`
    ${F("space_dwarf_mass_relay_title")}
    ${F("requires_segmemts",[100])}
    `},reqs:{outer:5},path:["truepath"],condition:()=>t.space.mass_relay.count<100,queue_size:5,queue_complete:()=>100-t.space.mass_relay.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?1e7:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?7500:0,Adamantite:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?18e3:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?125:0,Stanene:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?1e5:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?25e3:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0);if(a<100){let e=100-a;return`
    ${F("space_dwarf_mass_relay_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    `}return jt.spc_dwarf.m_relay.effect()},action(){return!!(t.space.mass_relay.count<100&&Os($(this)[0]))&&(t.space.mass_relay.count++,t.space.mass_relay.count>=100&&(t.tech.outer=6,t.space.m_relay={count:1,on:1,charged:0},ms(),Rt(),Ei()),!0)}},m_relay:{id:"space-m_relay",title:F("space_dwarf_mass_relay_title"),desc:()=>`
    ${F("space_dwarf_mass_relay_title")}
    ${F("requires_power")}
    `,reqs:{outer:6},path:["truepath"],condition:()=>t.space.mass_relay.count>=100,wiki:!1,queue_complete:()=>0,cost:{},powered:()=>oc(100),effect(){let e=Math.floor(t.space.m_relay.charged/10)/10;return`
    ${F("space_dwarf_mass_relay_effect2",[Xt().dwarf])}
    ${F("minus_power",[$(this)[0].powered()])}
    ${F("space_dwarf_mass_relay_charged",[e])}
    `},action:()=>!1}},spc_titan:Xe().spc_titan,spc_enceladus:Xe().spc_enceladus,spc_triton:Xe().spc_triton,spc_kuiper:Xe().spc_kuiper,spc_eris:Xe().spc_eris},St={int_alpha:{info:{name:F("interstellar_alpha_name"),desc:()=>t.tech.alpha?F("interstellar_alpha_desc2",[di[t.race.species].home]):F("interstellar_alpha_desc1",[di[t.race.species].home]),support:"starport"},alpha_mission:{id:"interstellar-alpha_mission",title:F("space_mission_title",[F("interstellar_alpha_name")]),desc:F("space_mission_desc",[F("interstellar_alpha_name")]),reqs:{ftl:2},grant:["alpha",1],queue_complete:()=>t.tech.alpha>=1?0:1,cost:{Helium_3:()=>+Yt(4e4).toFixed(0)},effect:F("interstellar_alpha_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("interstellar_alpha_mission_result"),"info",!1,["progress"]),t.interstellar.nexus={count:0,on:0,support:0,s_max:0},t.interstellar.warehouse={count:0},!0)}},starport:{id:"interstellar-starport",title:F("interstellar_alpha_starport_title"),desc:()=>`
    ${F("interstellar_alpha_starport_desc")}
    ${F("requires_power_space",[t.resource.Food.name])}
    `,reqs:{alpha:1},cost:{Money:e=>Xi("starport",e,1e6,1.3,"interstellar"),Aluminium:e=>Xi("starport",e,4e5,1.3,"interstellar"),Neutronium:e=>Xi("starport",e,1e3,1.3,"interstellar"),Elerium:e=>Xi("starport",e,100,1.3,"interstellar")},effect(){let e=+Yt(5).toFixed(2);return`
    ${F("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
    ${F("interstellar_alpha_starport_effect2",[e,$(this)[0].powered()])}
    ${F("interstellar_alpha_starport_effect3",[100,t.resource.Food.name])}
    `},support:()=>5,powered:()=>oc(10),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("starport","interstellar"),t.settings.space.proxima=!0,t.settings.space.nebula=!0,xs($(this)[0]),1===t.tech.alpha&&(t.tech.alpha=2,t.interstellar.mining_droid={count:0,on:0,adam:0,uran:0,coal:0,alum:0}),t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+100&&(t.race.orbit_decay=t.stats.days+100,Di(F("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0)}},habitat:{id:"interstellar-habitat",title:F("interstellar_habitat_title"),desc:`
    ${F("interstellar_habitat_desc")}
    ${F("requires_power")}
    `,reqs:{alpha:3},cost:{Money:e=>Xi("habitat",e,8e5,1.25,"interstellar"),Furs:e=>Xi("habitat",e,38e3,1.25,"interstellar"),Adamantite:e=>Xi("habitat",e,3200,1.25,"interstellar"),Plywood:e=>Xi("habitat",e,1e4,1.25,"interstellar"),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return`
    ${F("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
    ${F("plus_max_citizens",[e])}, ${F("minus_power",[$(this)[0].powered()])}
    `},support:()=>1,powered:()=>oc(2),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],action(){return!!Os($(this)[0])&&(Nt("habitat","interstellar"),xs($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens()),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},mining_droid:{id:"interstellar-mining_droid",title:F("interstellar_mining_droid_title"),desc:`
    ${F("interstellar_mining_droid_title")}
    ${F("space_support",[F("interstellar_alpha_name")])}
    `,reqs:{alpha:2},cost:{Money:e=>Xi("mining_droid",e,65e4,1.28,"interstellar"),Steel:e=>Xi("mining_droid",e,12e4,1.28,"interstellar"),Nano_Tube:e=>Xi("mining_droid",e,75e3,1.28,"interstellar"),Elerium:e=>Xi("mining_droid",e,50,1.28,"interstellar")},effect:()=>`
    ${F("space_used_support",[F("interstellar_alpha_name")])}
    ${F("interstellar_mining_droid_effect")}
    `,support:()=>-1,powered:()=>oc(1),special:!0,refresh:!0,action(){return!!Os($(this)[0])&&(Nt("mining_droid","interstellar"),t.resource.Adamantite.display=!0,t.interstellar.starport.support${F("interstellar_processing_title")}
    ${F("space_support",[F("interstellar_alpha_name")])}
    `,reqs:{droids:1},cost:{Money:e=>Xi("processing",e,35e4,1.28,"interstellar"),Iron:e=>Xi("processing",e,18e4,1.28,"interstellar"),Aluminium:e=>Xi("processing",e,6e4,1.28,"interstellar"),Iridium:e=>Xi("processing",e,5e3,1.28,"interstellar")},effect(){let e=12;return t.tech.ai_core&&t.tech.ai_core>=2&&i.citadel>0&&(e+=2*i.citadel),`
    ${F("space_used_support",[F("interstellar_alpha_name")])}
    ${F("interstellar_processing_effect",[e])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("processing","interstellar"),t.interstellar.starport.support`
    ${F("interstellar_fusion_title")}
    ${F("requires_power_support_combo",[F("interstellar_alpha_name"),t.resource.Deuterium.name])}
    `,reqs:{fusion:1},cost:{Money:e=>Xi("fusion",e,99e4,1.28,"interstellar"),Iridium:e=>Xi("fusion",e,44e3,1.28,"interstellar"),Infernite:e=>Xi("fusion",e,350,1.28,"interstellar"),Brick:e=>Xi("fusion",e,18e3,1.28,"interstellar")},effect(){return`
    ${F("space_used_support",[F("interstellar_alpha_name")])}
    ${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${F("interstellar_fusion_effect",[1.25])}
    `},support:()=>-1,powered:()=>cc(-22),p_fuel:()=>({r:"Deuterium",a:1.25}),action(){return!!Os($(this)[0])&&(Nt("fusion","interstellar"),t.interstellar.starport.support"magic"===t.race.universe?F("tech_sanctum"):F("interstellar_laboratory_title"),desc:`
    ${F("magic"===t.race.universe?"tech_sanctum":"interstellar_laboratory_title")}
    ${F("space_support",[F("interstellar_alpha_name")])}
    `,reqs:{science:12},cost:{Money:e=>Xi("laboratory",e,75e4,1.28,"interstellar"),Crystal:e=>"magic"===t.race.universe?Xi("laboratory",e,1200,1.28,"interstellar"):0,Titanium:e=>Xi("laboratory",e,12e4,1.28,"interstellar"),Alloy:e=>Xi("laboratory",e,95e3,1.28,"interstellar"),Mythril:e=>Xi("laboratory",e,8500,1.28,"interstellar")},effect(){let e=1e4;t.tech.science>=15&&(e*=1+.02*(t.race.cataclysm||t.race.orbit_decayed?c.exotic_lab:t.city.wardenclyffe.count)),(t.race.cataclysm||t.race.orbit_decayed&&i.s_gate&&n.scavenger)&&(e*=1+n.scavenger*+(.75*Et("gxy_alien2")).toFixed(1)),t.tech.science>=21&&(e*=1.45),e=Math.round(e);let a="";t.tech.science>=16&&(a=`
    ${F("city_wardenclyffe_effect1",[la(1),t.civic.scientist.name])}
    `);let r=`
    ${F("space_used_support",[F("interstellar_alpha_name")])}
    ${a}
    ${F("city_max_knowledge",[e])}
    `;return t.tech.science>=13&&(r+=`
    ${F("interstellar_laboratory_effect",[5])}
    `),"magic"===t.race.universe&&(r+=`
    ${F("plus_max_resource",[Lr(12),t.resource.Mana.name])}
    `),r},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("laboratory","interstellar"),t.interstellar.starport.support${F("interstellar_exchange_title")}
    ${F("space_support",[F("interstellar_alpha_name")])}
    `,reqs:{banking:12},cost:{Money:e=>Xi("exchange",e,68e4,1.28,"interstellar"),Stone:e=>Xi("exchange",e,115e3,1.28,"interstellar"),Adamantite:e=>Xi("exchange",e,55e3,1.28,"interstellar"),Graphene:e=>Xi("exchange",e,78e3,1.28,"interstellar")},effect(){let e=t.race.cataclysm||t.race.orbit_decayed?i.spaceport:t.city.bank?t.city.bank.count:0,a=t.race.cataclysm||t.race.orbit_decayed?4*Hs():Hs(),r=Lr(t.city.bank?a*e/18:0);return t.race.inflation&&(r*=2),t.tech.banking>=13&&(t.galaxy.freighter&&(r*=1+.03*n.freighter),t.galaxy.super_freighter&&(r*=1+.08*n.super_freighter)),r=+r.toFixed(0),`
    ${F("space_used_support",[F("interstellar_alpha_name")])}
    ${F("plus_max_resource",[`$${r.toLocaleString()}`,F("resource_Money_name")])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("exchange","interstellar"),t.interstellar.starport.support${F("interstellar_g_factory_title")}
    ${F("space_support",[F("interstellar_alpha_name")])}
    `,reqs:{graphene:1},cost:{Money:e=>Xi("g_factory",e,95e4,1.28,"interstellar"),Copper:e=>Xi("g_factory",e,165e3,1.28,"interstellar"),Cement:e=>Xi("g_factory",e,22e4,1.28,"interstellar"),Infernite:e=>Xi("g_factory",e,750,1.28,"interstellar")},effect:()=>`
    ${F("space_used_support",[F("interstellar_alpha_name")])}
    ${F("interstellar_g_factory_effect")}
    `,support:()=>-1,powered:()=>oc(1),special:!0,action(){return!!Os($(this)[0])&&(Nt("g_factory","interstellar"),t.resource.Graphene.display=!0,t.interstellar.starport.support`
    ${F("interstellar_int_factory_title")}
    ${F("requires_power_combo",[t.resource.Deuterium.name])}
    `,reqs:{alpha:4},cost:{Money:e=>Xi("int_factory",e,25e6,1.26,"interstellar"),Coal:e=>Xi("int_factory",e,1e7,1.26,"interstellar"),Brick:e=>Xi("int_factory",e,75e4,1.26,"interstellar"),Bolognium:e=>Xi("int_factory",e,5e4,1.26,"interstellar")},effect(){let e=+Yt(5).toFixed(2);return`
    ${F("interstellar_int_factory_effect")}
    ${F("city_crafted_mats",[10])}
    ${F("interstellar_fusion_effect",[e])} ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(5),special:!0,action(){return!!Os($(this)[0])&&(Nt("int_factory","interstellar"),xs($(this)[0])&&(t.city.factory.Alloy+=2,Ws()),!0)}},luxury_condo:{id:"interstellar-luxury_condo",title:F("tech_luxury_condo"),desc:`
    ${F("tech_luxury_condo")}
    ${F("requires_power")}
    `,reqs:{alpha:5},cost:{Money:e=>Xi("luxury_condo",e,25e6,1.25,"interstellar"),Neutronium:e=>Xi("luxury_condo",e,75e3,1.25,"interstellar"),Stanene:e=>Xi("luxury_condo",e,23e4,1.25,"interstellar"),Orichalcum:e=>Xi("luxury_condo",e,65e3,1.25,"interstellar"),Nanoweave:e=>Xi("luxury_condo",e,12500,1.25,"interstellar"),Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens(),t=Lr(75e4);return`
    ${F("plus_max_citizens",[e])}, ${F("minus_power",[$(this)[0].powered()])}
    ${F("plus_max_resource",[`$${t.toLocaleString()}`,F("resource_Money_name")])}
    `},powered:()=>oc(3),action(){return!!Os($(this)[0])&&(Nt("luxury_condo","interstellar"),xs($(this)[0])&&(t.resource[t.race.species].max+=2),!0)},citizens(){let e=2;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},zoo:{id:"interstellar-zoo",title:F("tech_zoo"),desc:()=>`
    ${F("tech_zoo")}
    ${F("requires_power_support_combo",[F("interstellar_alpha_name"),t.resource.Food.name])}
    `,reqs:{zoo:1},cost:{Money:e=>Xi("zoo",e,5e7,1.24,"interstellar"),Polymer:e=>Xi("zoo",e,6e6,1.24,"interstellar"),Infernite:e=>Xi("zoo",e,75e3,1.24,"interstellar"),Brick:e=>Xi("zoo",e,2e6,1.24,"interstellar")},effect:()=>`
    ${F("space_used_support",[F("interstellar_alpha_name")])}
    ${F("space_red_vr_center_effect1",[5])}
    ${F("space_red_vr_center_effect2",[2])}
    ${F("interstellar_alpha_starport_effect3",[12e3,t.resource.Food.name])}
    `,powered:()=>oc(3),action(){return!!Os($(this)[0])&&(Nt("zoo","interstellar"),t.interstellar.starport.supportt.tech.storage<=2?F("city_shed_title1"):t.tech.storage>=4?F("city_shed_title3"):F("city_shed_title2"),desc(){let e=t.tech.storage>=3?t.tech.storage>=4?F("city_shed_desc_size3"):F("city_shed_desc_size2"):F("city_shed_desc_size1");return F("city_shed_desc",[e])},reqs:{alpha:2},cost:{Money:e=>Xi("warehouse",e,175e3,1.28,"interstellar"),Lumber:e=>Xi("warehouse",e,1e5,1.28,"interstellar"),Aluminium:e=>Xi("warehouse",e,12e4,1.28,"interstellar"),Cement:e=>Xi("warehouse",e,45e3,1.28,"interstellar")},res(){let e=["Lumber","Stone","Chrysotile","Furs","Copper","Iron","Aluminium","Cement","Coal","Nano_Tube","Neutronium","Adamantite","Infernite"];return t.tech.storage>=3&&t.resource.Steel.display&&e.push("Steel"),t.tech.storage>=4&&t.resource.Titanium.display&&e.push("Titanium"),e},val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 750;case"Furs":return 425;case"Copper":return 380;case"Iron":return 350;case"Aluminium":return 320;case"Cement":return 280;case"Coal":return 120;case"Steel":return 60;case"Titanium":return 40;case"Nano_Tube":return 30;case"Neutronium":return 8;case"Adamantite":return 18;case"Infernite":return 5;default:return 0}},wide:!0,effect(){let e='
    ',a=os();for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return e+="
    ",e},action(){if(Os($(this)[0])){Nt("warehouse","interstellar");let e=os();for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=Lr($(this)[0].val(a)*e));return!0}return!1}}},int_proxima:{info:{name:F("interstellar_proxima_name"),desc:()=>t.tech.proxima?F("interstellar_proxima_desc2"):F("interstellar_proxima_desc1")},proxima_mission:{id:"interstellar-proxima_mission",title:F("space_mission_title",[F("interstellar_proxima_name")]),desc:F("space_mission_desc",[F("interstellar_proxima_name")]),reqs:{alpha:1},grant:["proxima",1],queue_complete:()=>t.tech.proxima>=1?0:1,cost:{Helium_3:()=>+Yt(42e3).toFixed(0)},effect:F("interstellar_proxima_mission_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.xfer_station={count:0,on:0},Di(F("interstellar_proxima_mission_result"),"info",!1,["progress"]),!0)}},xfer_station:{id:"interstellar-xfer_station",title:F("interstellar_xfer_station_title"),desc:()=>`
    ${F("interstellar_xfer_station_desc")}
    ${F("requires_power_combo",[t.resource.Uranium.name])}
    `,reqs:{proxima:1},cost:{Money:e=>Xi("xfer_station",e,12e5,1.28,"interstellar"),Neutronium:e=>Xi("xfer_station",e,1500,1.28,"interstellar"),Adamantite:e=>Xi("xfer_station",e,6e3,1.28,"interstellar"),Polymer:e=>Xi("xfer_station",e,12e3,1.28,"interstellar"),Wrought_Iron:e=>Xi("xfer_station",e,3500,1.28,"interstellar")},effect(){let e=Lr(5e3),a=Lr(4e3),r=Lr(2500),s="";return t.resource.Deuterium.display&&(s=`
    ${F("plus_max_resource",[Lr(2e3),F("resource_Deuterium_name")])}
    `),`
    ${F("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
    ${F("plus_max_resource",[a,F("resource_Oil_name")])}
    ${F("plus_max_resource",[e,F("resource_Helium_3_name")])}
    ${F("plus_max_resource",[r,F("resource_Uranium_name")])}
    ${s}
    ${F("city_fission_power_effect",[.28])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},support:()=>1,powered:()=>oc(1),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("xfer_station","interstellar"),xs($(this)[0])&&(t.resource.Uranium.max+=Lr(2500),t.resource.Helium_3.max+=Lr(5e3),t.resource.Oil.max+=Lr(4e3),t.resource.Deuterium.max+=Lr(2e3)),1===t.tech.proxima&&(t.tech.proxima=2,t.interstellar.cargo_yard={count:0}),!0)}},cargo_yard:{id:"interstellar-cargo_yard",title:F("interstellar_cargo_yard_title"),desc:F("interstellar_cargo_yard_title"),reqs:{proxima:2},cost:{Money:e=>Xi("cargo_yard",e,275e3,1.28,"interstellar"),Graphene:e=>Xi("cargo_yard",e,7500,1.28,"interstellar"),Mythril:e=>Xi("cargo_yard",e,6e3,1.28,"interstellar")},effect(){let e=Lr(200),a=Lr(150),r=`
    ${F("plus_max_resource",[50,F("resource_Crates_name")])}
    ${F("plus_max_resource",[50,F("resource_Containers_name")])}
    `;return r+=`
    ${F("plus_max_resource",[e,F("resource_Neutronium_name")])}
    ${F("plus_max_resource",[a,F("resource_Infernite_name")])}
    `,t.tech.storage>=7&&(r+=`
    ${F("interstellar_cargo_yard_effect",[+u.toFixed(3)])}
    `),r},action(){return!!Os($(this)[0])&&(Nt("cargo_yard","interstellar"),!0)}},cruiser:{id:"interstellar-cruiser",title:F("interstellar_cruiser_title"),desc:F("interstellar_cruiser_title"),reqs:{cruiser:1},cost:{Money:e=>Xi("cruiser",e,875e3,1.28,"interstellar"),Aluminium:e=>Xi("cruiser",e,195e3,1.28,"interstellar"),Deuterium:e=>Xi("cruiser",e,+Yt(1500).toFixed(0),1.28,"interstellar"),Neutronium:e=>Xi("cruiser",e,2e3,1.28,"interstellar"),Aerogel:e=>Xi("cruiser",e,250,1.28,"interstellar"),Horseshoe:()=>t.race.hooved?3:0},powered:()=>oc(1),effect(){let e=+Yt(6).toFixed(2);return`
    ${F("plus_max_soldiers",[la(3)])}
    ${F("space_belt_station_effect3",[e])}
    `},action(){return!!Os($(this)[0])&&(Nt("cruiser","interstellar"),t.interstellar.cruiser.on++,!0)}},dyson:{id:"interstellar-dyson",title:F("interstellar_dyson_title"),desc:e=>!t.interstellar.hasOwnProperty("dyson")||t.interstellar.dyson.count<100||e?`
    ${F("interstellar_dyson_title")}
    ${F("requires_segmemts",[100])}
    `:`
    ${F("interstellar_dyson_title")}
    `,reqs:{proxima:3},queue_size:10,queue_complete:()=>100-t.interstellar.dyson.count,condition:()=>!(t.interstellar.dyson.count>=100&&t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?25e4:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?1e4:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?25:0,Stanene:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?1e5:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0);if(a<100){let e=a>0?`
    ${F("space_dwarf_reactor_effect1",[cc(1.25*a)])}
    `:"",t=100-a;return`
    ${F("interstellar_dyson_effect")}
    ${e}
    ${F("space_dwarf_collider_effect2",[t])}
    `}return F("interstellar_dyson_complete",[cc(175)])},action(){return!!(Os($(this)[0])&&t.interstellar.dyson.count<100)&&(Nt("dyson","interstellar"),t.interstellar.dyson.count>=100&&ms(),!0)}},dyson_sphere:{id:"interstellar-dyson_sphere",title:F("interstellar_dyson_sphere_title"),desc:e=>!t.interstellar.hasOwnProperty("dyson_sphere")||t.interstellar.dyson_sphere.count<100||e?`
    ${F("interstellar_dyson_sphere_title")}
    ${F("requires_segmemts",[100])}
    `:`
    ${F("interstellar_dyson_sphere_title")}
    `,reqs:{proxima:3,dyson:1},queue_size:10,queue_complete:()=>100-t.interstellar.dyson_sphere.count,condition:()=>!!(t.interstellar.dyson.count>=100&&t.tech.dyson&&1===t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?5e6:0,Bolognium:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?25e3:0,Vitreloy:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?1250:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0);if(a<100){let e=175+5*a,t=100-a;return`
    ${F("interstellar_dyson_sphere_effect")}
    ${F("space_dwarf_reactor_effect1",[cc(e)])}
    ${F("space_dwarf_collider_effect2",[t])}
    `}return F("interstellar_dyson_sphere_complete",[cc(750)])},action(){return!!(Os($(this)[0])&&t.interstellar.dyson_sphere.count<100)&&(Nt("dyson_sphere","interstellar"),t.interstellar.dyson_sphere.count>=100&&ms(),!0)}},orichalcum_sphere:{id:"interstellar-orichalcum_sphere",title:F("interstellar_dyson_sphere_title"),desc:e=>!t.interstellar.hasOwnProperty("orichalcum_sphere")||t.interstellar.orichalcum_sphere.count<100||e?`
    ${F("interstellar_orichalcum_sphere_desc")}
    ${F("requires_segmemts",[100])}
    `:`
    ${F("interstellar_orichalcum_sphere_desc")}
    `,reqs:{proxima:3,dyson:2},queue_size:10,queue_complete:()=>100-t.interstellar.orichalcum_sphere.count,condition:()=>!!(t.interstellar.dyson_sphere.count>=100&&t.tech.dyson&&2===t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0)<100?25e6:0,Orichalcum:e=>(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0);if(a<100){let e=750+8*a,t=100-a;return`
    ${F("interstellar_orichalcum_sphere_effect")}
    ${F("space_dwarf_reactor_effect1",[cc(e)])}
    ${F("space_dwarf_collider_effect2",[t])}
    `}return F("interstellar_dyson_sphere_complete",[cc(1750)])},action(){return!!(Os($(this)[0])&&t.interstellar.orichalcum_sphere.count<100)&&(Nt("orichalcum_sphere","interstellar"),t.interstellar.orichalcum_sphere.count>=100&&Xc("blacken_the_sun"),!0)}}},int_nebula:{info:{name:F("interstellar_nebula_name"),desc:()=>t.tech.nebula?F("interstellar_nebula_desc2"):F("interstellar_nebula_desc1"),support:"nexus"},nebula_mission:{id:"interstellar-nebula_mission",title:F("space_mission_title",[F("interstellar_nebula_name")]),desc:F("space_mission_desc",[F("interstellar_nebula_name")]),reqs:{alpha:1},grant:["nebula",1],queue_complete:()=>t.tech.nebula>=1?0:1,cost:{Helium_3:()=>+Yt(55e3).toFixed(0)},effect:F("interstellar_nebula_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("interstellar_nebula_mission_result"),"info",!1,["progress"]),!0)}},nexus:{id:"interstellar-nexus",title:F("interstellar_nexus_title"),desc:()=>`
    ${F("interstellar_nexus_title")}
    ${F("requires_power_combo",[t.resource.Money.name])}
    `,reqs:{nebula:1},cost:{Money:e=>Xi("nexus",e,9e5,1.24,"interstellar"),Adamantite:e=>Xi("nexus",e,7500,1.24,"interstellar"),Infernite:e=>Xi("nexus",e,250,1.24,"interstellar"),Sheet_Metal:e=>Xi("nexus",e,14e3,1.24,"interstellar"),Nano_Tube:e=>Xi("nexus",e,17500,1.24,"interstellar")},effect(){let e=Lr(3500),t=Lr(4e3),a=Lr(3e3),r=Lr(25);return`
    ${F("interstellar_nexus_effect1",[$(this)[0].support()])}
    ${F("plus_max_resource",[e,F("resource_Oil_name")])}
    ${F("plus_max_resource",[t,F("resource_Helium_3_name")])}
    ${F("plus_max_resource",[a,F("resource_Deuterium_name")])}
    ${F("plus_max_resource",[r,F("resource_Elerium_name")])}
    ${F("interstellar_nexus_effect2",[$(this)[0].powered(),350])}
    `},support:()=>2,powered:()=>oc(8),powerBalancer:()=>[{s:t.interstellar.nexus.s_max-t.interstellar.nexus.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("nexus","interstellar"),t.resource.Deuterium.display=!0,1===t.tech.nebula&&(t.interstellar.harvester={count:0,on:0},t.tech.nebula=2),xs($(this)[0])&&(t.resource.Oil.max+=Lr(2500),t.resource.Helium_3.max+=Lr(4e3),t.resource.Deuterium.max+=Lr(3e3),t.resource.Elerium.max+=Lr(25)),!0)}},harvester:{id:"interstellar-harvester",title:F("interstellar_harvester_title"),desc:`
    ${F("interstellar_harvester_title")}
    ${F("space_support",[F("interstellar_nebula_name")])}
    `,reqs:{nebula:2},cost:{Money:e=>Xi("harvester",e,65e4,1.28,"interstellar"),Copper:e=>Xi("harvester",e,8e4,1.28,"interstellar"),Alloy:e=>Xi("harvester",e,45e3,1.28,"interstellar"),Iridium:e=>Xi("harvester",e,8e3,1.28,"interstellar")},effect(){let e=+Pe("harvester","helium").toFixed(3),a=+Pe("harvester","deuterium").toFixed(3),r=t.tech.ram_scoop?`
    ${F("interstellar_harvester_effect",[a])}
    `:"";return`
    ${F("space_used_support",[F("interstellar_nebula_name")])}
    ${F("space_gas_mining_effect1",[e])}
    ${r}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("harvester","interstellar"),t.interstellar.nexus.support${F("interstellar_elerium_prospector_title")}
    ${F("space_support",[F("interstellar_nebula_name")])}
    `,reqs:{nebula:3},cost:{Money:e=>Xi("elerium_prospector",e,825e3,1.28,"interstellar"),Steel:e=>Xi("elerium_prospector",e,18e3,1.28,"interstellar"),Polymer:e=>Xi("elerium_prospector",e,22e3,1.28,"interstellar"),Graphene:e=>Xi("elerium_prospector",e,82e3,1.28,"interstellar"),Stanene:e=>Xi("elerium_prospector",e,57e3,1.28,"interstellar")},effect(){let e=+Pe("elerium_prospector").toFixed(3);return`
    ${F("space_used_support",[F("interstellar_nebula_name")])}
    ${F("space_belt_elerium_ship_effect2",[e])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("elerium_prospector","interstellar"),t.interstellar.nexus.supportt.tech.neutron?F("interstellar_neutron_desc2",[di[t.race.species].home]):F("interstellar_neutron_desc1")},neutron_mission:{id:"interstellar-neutron_mission",title:F("space_mission_title",[F("interstellar_neutron_name")]),desc:F("space_mission_desc",[F("interstellar_neutron_name")]),reqs:{nebula:1,high_tech:14},grant:["neutron",1],queue_complete:()=>t.tech.neutron>=1?0:1,cost:{Helium_3:()=>+Yt(6e4).toFixed(0),Deuterium:()=>+Yt(1e4).toFixed(0)},effect:F("interstellar_neutron_mission_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.neutron_miner={count:0,on:0},Di(F("interstellar_neutron_mission_result"),"info",!1,["progress"]),!0)}},neutron_miner:{id:"interstellar-neutron_miner",title:F("interstellar_neutron_miner_title"),desc:()=>`
    ${F("interstellar_neutron_miner_desc")}
    ${F("requires_power_combo",[t.resource.Helium_3.name])}
    `,reqs:{neutron:1},cost:{Money:e=>Xi("neutron_miner",e,1e6,1.32,"interstellar"),Titanium:e=>Xi("neutron_miner",e,45e3,1.32,"interstellar"),Stanene:e=>Xi("neutron_miner",e,88e3,1.32,"interstellar"),Elerium:e=>Xi("neutron_miner",e,20,1.32,"interstellar"),Aerogel:e=>Xi("neutron_miner",e,50,1.32,"interstellar")},effect(){let e=+Pe("neutron_miner").toFixed(3),t=Lr(500),a=+Yt(3).toFixed(2);return`
    ${F("space_gas_moon_outpost_effect1",[e])}
    ${F("plus_max_resource",[t,F("resource_Neutronium_name")])}
    ${F("interstellar_alpha_starport_effect2",[a,$(this)[0].powered()])}
    `},powered:()=>oc(6),powerBalancer:()=>[{r:"Neutronium",k:"lpmod"}],action(){return!!Os($(this)[0])&&(Nt("neutron_miner","interstellar"),xs($(this)[0]),!0)}},citadel:{id:"interstellar-citadel",title:F("interstellar_citadel_title"),desc:`
    ${F("interstellar_citadel_desc")}
    ${F("requires_power")}
    `,reqs:{neutron:1,high_tech:15},cost:{Money:e=>Xi("citadel",e,5e6,1.25,"interstellar"),Knowledge:e=>Xi("citadel",e,15e5,1.15,"interstellar"),Graphene:e=>Xi("citadel",e,5e4,1.25,"interstellar"),Stanene:e=>Xi("citadel",e,1e5,1.25,"interstellar"),Elerium:e=>Xi("citadel",e,250,1.25,"interstellar"),Soul_Gem:e=>Xi("citadel",e,1,1.25,"interstellar")},wide:!0,effect(){let e=`
    ${F("interstellar_citadel_stat",[+u.toFixed(1)])}
    ${F("interstellar_citadel_effect",[5])}
    `;if(t.tech.ai_core){let a=+(u/1.75).toFixed(1);t.race.flier||(e+=`
    ${F("interstellar_citadel_effect2",[a])}
    `),t.tech.ai_core>=2&&(e+=`
    ${F("interstellar_citadel_effect3",[2])}
    `),t.tech.ai_core>=3&&(e+=`
    ${F("interstellar_citadel_effect4",[+(u/5).toFixed(1)])}
    `)}return`${e}
    ${F("interstellar_citadel_power",[$(this)[0].powered(),oc(2.5)])}
    `},powered:()=>i.citadel&&i.citadel>1?oc(30+2.5*(i.citadel-1)):oc(30),action(){return!!Os($(this)[0])&&(Nt("citadel","interstellar"),xs($(this)[0]),!0)},flair:()=>F("interstellar_citadel_flair")},stellar_forge:{id:"interstellar-stellar_forge",title:F("interstellar_stellar_forge_title"),desc:`
    ${F("interstellar_stellar_forge_title")}
    ${F("requires_power")}
    `,reqs:{star_forge:1},cost:{Money:e=>Xi("stellar_forge",e,12e5,1.25,"interstellar"),Iridium:e=>Xi("stellar_forge",e,25e4,1.25,"interstellar"),Bolognium:e=>Xi("stellar_forge",e,35e3,1.25,"interstellar"),Aerogel:e=>Xi("stellar_forge",e,75e3,1.25,"interstellar")},effect(){let e=`
    ${F("city_foundry_effect1",[la(2)])}
    ${F("interstellar_stellar_forge_effect",[10])}
    ${F("interstellar_stellar_forge_effect2",[5])}
    `;return t.tech.star_forge&&t.tech.star_forge>=2&&(e+=`
    ${F("interstellar_stellar_forge_effect3",[2])}
    `),`${e}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(3),special:!0,action(){return!!Os($(this)[0])&&(Nt("stellar_forge","interstellar"),xs($(this)[0])&&t.tech.star_forge>=2&&(t.city.smelter.cap+=2,t.city.smelter.Star+=2,t.city.smelter.StarCap+=2,t.city.smelter.Iron+=2),!0)},flair:()=>F("interstellar_stellar_forge_flair")}},int_blackhole:{info:{name:F("interstellar_blackhole_name"),desc(){let e=di[t.race.species].home;if(t.tech.blackhole>=5){let a=+t.interstellar.stellar_engine.mass.toFixed(10),r=+t.interstellar.stellar_engine.exotic.toFixed(10);if(t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12)),t.tech.whitehole){let s=mc("bigbang"),i="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
    ${F("interstellar_blackhole_desc4",[e,a,r])}
    ${F("interstellar_blackhole_desc5",[s.plasmid,s.phage,s.dark,i])}
    `}return t.interstellar.stellar_engine.exotic>0?F("interstellar_blackhole_desc4",[e,a,r]):F("interstellar_blackhole_desc3",[e,a])}return t.tech.blackhole?F("interstellar_blackhole_desc2",[e]):F("interstellar_blackhole_desc1",[e])}},blackhole_mission:{id:"interstellar-blackhole_mission",title:F("space_mission_title",[F("interstellar_blackhole_name")]),desc:F("space_mission_desc",[F("interstellar_blackhole_name")]),reqs:{nebula:1},grant:["blackhole",1],queue_complete:()=>t.tech.blackhole>=1?0:1,cost:{Helium_3:()=>+Yt(75e3).toFixed(0),Deuterium:()=>+Yt(25e3).toFixed(0)},effect:F("interstellar_blackhole_mission_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.far_reach={count:0,on:0},Di(F("interstellar_blackhole_mission_result"),"info",!1,["progress"]),!0)}},far_reach:{id:"interstellar-far_reach",title:F("interstellar_far_reach"),desc:`
    ${F("interstellar_far_reach_desc")}
    ${F("requires_power")}
    `,reqs:{blackhole:1},cost:{Money:e=>Xi("far_reach",e,1e6,1.32,"interstellar"),Knowledge:e=>Xi("far_reach",e,1e5,1.32,"interstellar"),Neutronium:e=>Xi("far_reach",e,2500,1.32,"interstellar"),Elerium:e=>Xi("far_reach",e,100,1.32,"interstellar"),Aerogel:e=>Xi("far_reach",e,1e3,1.32,"interstellar")},effect(){return`
    ${F("interstellar_far_reach_effect",[1])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(5),action(){return!!Os($(this)[0])&&(Nt("far_reach","interstellar"),xs($(this)[0]),1===t.tech.blackhole&&(t.tech.blackhole=2,ms()),!0)},flair:F("interstellar_far_reach_flair")},stellar_engine:{id:"interstellar-stellar_engine",title:F("interstellar_stellar_engine"),desc:e=>!t.interstellar.hasOwnProperty("stellar_engine")||t.interstellar.stellar_engine.count<100||e?`
    ${F("interstellar_stellar_engine")}
    ${F("requires_segmemts",[100])}
    `:`
    ${F("interstellar_stellar_engine")}
    `,reqs:{blackhole:3},queue_size:10,queue_complete:()=>100-t.interstellar.stellar_engine.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?5e5:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?450:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?17500:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?225:0,Graphene:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?45e3:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?250:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?75:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0);if(a<100){let e=100-a;return`
    ${F("interstellar_stellar_engine_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    `}{let e=t.tech.gravity&&t.tech.gravity>=2?13.5:7.5,a=t.interstellar.stellar_engine?t.interstellar.stellar_engine.mass:8;t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12));let r=cc(+(20+(a-8)*e+(t.interstellar.stellar_engine?t.interstellar.stellar_engine.exotic:0)*e*10).toFixed(2));if(t.tech.blackhole>=5){let e=+t.interstellar.stellar_engine.exotic.toFixed(10),s=t.interstellar.stellar_engine.exotic>0?F("interstellar_stellar_engine_effect3",[a,e]):F("interstellar_stellar_engine_effect2",[a]);return`
    ${F("interstellar_stellar_engine_complete",[r])}
    ${s}
    `}return F("interstellar_stellar_engine_complete",[r])}},action(){return!!(Os($(this)[0])&&t.interstellar.stellar_engine.count<100)&&(Nt("stellar_engine","interstellar"),t.interstellar.stellar_engine.count>=100&&3===t.tech.blackhole&&(t.tech.blackhole=4,ms()),!0)}},mass_ejector:{id:"interstellar-mass_ejector",title:F("interstellar_mass_ejector"),desc:`
    ${F("interstellar_mass_ejector")}
    ${F("requires_power")}
    `,reqs:{blackhole:5},cost:{Money:e=>Xi("mass_ejector",e,75e4,1.25,"interstellar"),Adamantite:e=>Xi("mass_ejector",e,125e3,1.25,"interstellar"),Infernite:e=>Xi("mass_ejector",e,275,1.25,"interstellar"),Elerium:e=>Xi("mass_ejector",e,100,1.25,"interstellar"),Mythril:e=>Xi("mass_ejector",e,1e4,1.25,"interstellar")},effect(){return`
    ${F("interstellar_mass_ejector_effect")}, ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(3),special:!0,sAction(){t.settings.civTabs=4,t.settings.marketTabs=2,t.settings.tabLoad||(Ct("mTabResource"),Ei("interstellar-mass_ejector"))},action(){return!!Os($(this)[0])&&(0===t.interstellar.mass_ejector.count&&Di(F("interstellar_mass_ejector_msg"),"info",!1,["progress"]),t.settings.showEjector=!0,Nt("mass_ejector","interstellar"),xs($(this)[0]),rc($("#resources")),rr(),!0)},flair:()=>F("interstellar_mass_ejector_flair")},jump_ship:{id:"interstellar-jump_ship",title:F("interstellar_jump_ship"),desc:F("interstellar_jump_ship_desc"),reqs:{stargate:1},grant:["stargate",2],queue_complete:()=>t.tech.stargate>=2?0:1,cost:{Money:()=>2e7,Copper:()=>24e5,Aluminium:()=>4e6,Titanium:()=>125e4,Adamantite:()=>75e4,Stanene:()=>9e5,Aerogel:()=>1e5},effect:F("interstellar_jump_ship_effect"),action(){return!!Os($(this)[0])}},wormhole_mission:{id:"interstellar-wormhole_mission",title:F("space_mission_title",[F("interstellar_wormhole_name")]),desc:F("space_mission_desc",[F("interstellar_wormhole_name")]),reqs:{stargate:2},grant:["stargate",3],queue_complete:()=>t.tech.stargate>=3?0:1,cost:{Helium_3:()=>+Yt(15e4).toFixed(0),Deuterium:()=>+Yt(75e3).toFixed(0)},effect:F("interstellar_wormhole_mission_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.stargate={count:0},t.galaxy.gateway_station={count:0,on:0},Di(F("interstellar_wormhole_mission_result"),"info",!1,["progress"]),!0)}},stargate:{id:"interstellar-stargate",title:F("interstellar_stargate"),desc:e=>!t.interstellar.hasOwnProperty("stargate")||t.interstellar.stargate.count<200||e?`
    ${F("interstellar_stargate")}
    ${F("requires_segmemts",[200])}
    `+(t.interstellar.hasOwnProperty("stargate")&&t.interstellar.stargate.count>=200?`
    ${F("requires_power")}
    `:""):`
    ${F("interstellar_stargate")}
    `,reqs:{stargate:3},condition:()=>!(t.interstellar.stargate.count>=200),queue_size:10,queue_complete:()=>200-t.interstellar.stargate.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?1e6:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?4800:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?666:0,Elerium:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?75:0,Nano_Tube:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?12e3:0,Stanene:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?6e4:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?3200:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0);if(a<200){let e=200-a;return`
    ${F("interstellar_stargate_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    `}return St.int_blackhole.s_gate.effect()},action(){return!!(Os($(this)[0])&&t.interstellar.stargate.count<200)&&(Nt("stargate","interstellar"),t.interstellar.stargate.count>=200&&(t.tech.stargate=4,t.interstellar.s_gate={count:1,on:0},t.city.power>=St.int_blackhole.s_gate.powered()&&t.interstellar.s_gate.on++,Ut(),Ei()),!0)}},s_gate:{id:"interstellar-s_gate",title:F("interstellar_stargate"),desc:()=>`
    ${F("interstellar_stargate")}
    ${F("requires_power")}
    `,reqs:{stargate:4},condition:()=>t.interstellar.stargate.count>=200,wiki:!1,queue_complete:()=>0,cost:{},powered:()=>oc(250),effect(){return`
    ${F("interstellar_s_gate_effect")}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action:()=>!1}},int_sirius:{info:{name:()=>t.tech.ascension>=3?F("interstellar_sirius_b_name"):F("interstellar_sirius_name"),desc:()=>t.tech.ascension>=3?F("interstellar_sirius_b_desc"):F("interstellar_sirius_desc",[di[t.race.species].home])},sirius_mission:{id:"interstellar-sirius_mission",title:F("space_mission_title",[F("interstellar_sirius_name")]),desc:F("space_mission_desc",[F("interstellar_sirius_name")]),reqs:{ascension:2},grant:["ascension",3],queue_complete:()=>t.tech.ascension>=3?0:1,cost:{Helium_3:()=>+Yt(48e4).toFixed(0),Deuterium:()=>+Yt(225e3).toFixed(0)},effect:()=>F("interstellar_sirius_mission_effect",[Ac("name"),di[t.race.species].home]),action(){return!!Os($(this)[0])}},sirius_b:{id:"interstellar-sirius_b",title:F("interstellar_sirius_b"),desc:F("interstellar_sirius_b"),reqs:{ascension:3},grant:["ascension",4],queue_complete:()=>t.tech.ascension>=4?0:1,cost:{Knowledge:()=>2e7},effect:()=>F("interstellar_sirius_b_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.space_elevator={count:0},!0)}},space_elevator:{id:"interstellar-space_elevator",title:F("interstellar_space_elevator"),desc:e=>!t.interstellar.hasOwnProperty("space_elevator")||t.interstellar.space_elevator.count<100||e?`
    ${F("interstellar_space_elevator")}
    ${F("requires_segmemts",[100])}
    `:`
    ${F("interstellar_space_elevator")}
    `,reqs:{ascension:4},condition:()=>!(t.interstellar.space_elevator.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.space_elevator.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?2e7:0,Nano_Tube:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?5e5:0,Bolognium:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?1e5:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?125e3:0},effect(e){let a=`
    ${F("interstellar_space_elevator_effect")}
    `,r=(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0);return r<100&&(a+=`
    ${F("space_dwarf_collider_effect2",[100-r])}
    `),a},action(){return!!(Os($(this)[0])&&t.interstellar.space_elevator.count<100)&&(Nt("space_elevator","interstellar"),t.interstellar.space_elevator.count>=100&&(t.tech.ascension=5,t.interstellar.gravity_dome={count:0},Ut(),Ei()),!0)}},gravity_dome:{id:"interstellar-gravity_dome",title:F("interstellar_gravity_dome"),desc:e=>!t.interstellar.hasOwnProperty("gravity_dome")||t.interstellar.gravity_dome.count<100||e?`
    ${F("interstellar_gravity_dome")}
    ${F("requires_segmemts",[100])}
    `:`
    ${F("interstellar_gravity_dome")}
    `,reqs:{ascension:5},condition:()=>!(t.interstellar.gravity_dome.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.gravity_dome.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?35e6:0,Cement:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?125e4:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?65e4:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?18e4:0},effect(e){let a=`
    ${F("interstellar_gravity_dome_effect",[di[t.race.species].home])}
    `,r=(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0);return r<100&&(a+=`
    ${F("space_dwarf_collider_effect2",[100-r])}
    `),a},action(){return!!(Os($(this)[0])&&t.interstellar.gravity_dome.count<100)&&(Nt("gravity_dome","interstellar"),t.interstellar.gravity_dome.count>=100&&(t.tech.ascension=6,t.interstellar.ascension_machine={count:0},t.interstellar.thermal_collector={count:0},Ut(),Ei()),!0)}},ascension_machine:{id:"interstellar-ascension_machine",title:F("interstellar_ascension_machine"),desc:e=>!t.interstellar.hasOwnProperty("ascension_machine")||t.interstellar.ascension_machine.count<100||e?`
    ${F("interstellar_ascension_machine")}
    ${F("requires_segmemts",[100])}
    `+(t.interstellar.hasOwnProperty("ascension_machine")&&t.interstellar.ascension_machine.count>=100?`
    ${F("requires_power")}
    `:""):`
    ${F("interstellar_ascension_machine")}
    `,reqs:{ascension:6},condition:()=>!(t.interstellar.ascension_machine.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.ascension_machine.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e6:0,Alloy:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e4:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?1e3:0,Orichalcum:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?25e4:0,Nanoweave:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0);if(a<100){let e=100-a;return`
    ${F("interstellar_ascension_machine_effect",[Ac("name")])}
    ${F("space_dwarf_collider_effect2",[e])}
    `}return St.int_sirius.ascension_trigger.effect()},action(){return!!(Os($(this)[0])&&t.interstellar.ascension_machine.count<100)&&(Nt("ascension_machine","interstellar"),t.interstellar.ascension_machine.count>=100&&(t.tech.ascension=7,t.interstellar.ascension_trigger={count:1,on:0},Ut(),Ei()),!0)}},ascension_trigger:{id:"interstellar-ascension_trigger",title:F("interstellar_ascension_machine"),desc:()=>`
    ${F("interstellar_ascension_machine")}
    ${F("requires_power")}
    `,wiki:!1,reqs:{ascension:7},condition:()=>t.interstellar.ascension_machine.count>=100,queue_complete:()=>0,cost:{},powered(){let e=100;if(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2){e+=t.stats.achieve.technophobe.l>=4?25:10;for(let a=1;a=5&&(e+=5)}let a=Math.round(oc(1e4)-e*(t.interstellar.hasOwnProperty("thermal_collector")?t.interstellar.thermal_collector.count:0));return a<0&&(a=0),a},postPower(e){e?setTimeout((function(){t.tech.ascension=i.ascension_trigger?8:7,Ut()}),250):(t.tech.ascension=7,Ut())},effect(){let e=Ft(),t=$(this)[0].powered(),a=t>0?`
    ${F("minus_power",[t])}
    `:"";return`
    ${F("interstellar_ascension_trigger_effect")}
    ${e}${a}`},action:()=>!1},ascend:{id:"interstellar-ascend",title:F("interstellar_ascend"),desc:F("interstellar_ascend"),reqs:{ascension:8},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=Ft();return`
    ${F("interstellar_ascend_effect")}
    ${e}`},action(){return!!Os($(this)[0])&&(ra(),!0)}},thermal_collector:{id:"interstellar-thermal_collector",title:F("interstellar_thermal_collector"),desc:F("interstellar_thermal_collector"),reqs:{ascension:6},cost:{Money:e=>Xi("thermal_collector",e,5e6,1.08,"interstellar"),Infernite:e=>Xi("thermal_collector",e,25e3,1.08,"interstellar"),Stanene:e=>Xi("thermal_collector",e,1e6,1.08,"interstellar"),Vitreloy:e=>Xi("thermal_collector",e,1e5,1.08,"interstellar")},effect(){let e=100;if(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2){e+=t.stats.achieve.technophobe.l>=4?25:10;for(let a=1;a=5&&(e+=5)}return F("interstellar_thermal_collector_effect",[e])},action(){return!!Os($(this)[0])&&(Nt("thermal_collector","interstellar"),!0)}}}};function Ft(){let e=mc("ascend"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
    ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
    ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
    ${F("interstellar_ascension_trigger_effect2",[e.harmony,F("resource_Harmony_name")])}
    ${F("interstellar_ascension_trigger_effect3")}
    `}function zt(){let e=mc("terraform"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
    ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
    ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
    ${F("interstellar_ascension_trigger_effect2",[e.harmony,F("resource_Harmony_name")])}
    ${F("space_terraformer_effect3")}
    `}const At={gxy_gateway:{info:{name:F("galaxy_gateway"),desc:()=>F("galaxy_gateway_desc"),control:()=>({name:Ac("name"),color:"success"}),support:"starbase"},gateway_mission:{id:"galaxy-gateway_mission",title:F("galaxy_gateway_mission"),desc:F("galaxy_gateway_mission"),reqs:{gateway:1},grant:["gateway",2],queue_complete:()=>t.tech.gateway>=2?0:1,cost:{Helium_3:()=>+Yt(212e3).toFixed(0),Deuterium:()=>+Yt(11e4).toFixed(0)},effect:F("galaxy_gateway_mission_effect"),action(){return!!Os($(this)[0])&&(It(),t.galaxy.defense={gxy_stargate:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_gateway:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_gorddon:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_alien1:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_alien2:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_chthonian:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0}},!0)}},starbase:{id:"galaxy-starbase",title:F("galaxy_starbase"),desc:()=>`
    ${F("galaxy_starbase")}
    ${F("requires_power_space",[t.resource.Food.name])}
    `,reqs:{gateway:2},cost:{Money:e=>Xi("starbase",e,42e5,1.25,"galaxy"),Elerium:e=>Xi("starbase",e,1e3,1.25,"galaxy"),Mythril:e=>Xi("starbase",e,9e4,1.25,"galaxy"),Graphene:e=>Xi("starbase",e,32e4,1.25,"galaxy"),Horseshoe:()=>t.race.hooved?5:0},effect(){let e=+Yt(25).toFixed(2),a=t.tech.marines>=2?la(8):la(5);return`
    ${F("galaxy_defense_platform_effect",[25])}
    ${F("galaxy_gateway_support",[$(this)[0].support()])}
    ${F("plus_max_soldiers",[a])}
    ${F("interstellar_alpha_starport_effect2",[e,$(this)[0].powered()])}
    ${F("interstellar_alpha_starport_effect3",[250,t.resource.Food.name])}
    `},support:()=>2,powered:()=>oc(i.s_gate?12:0),powerBalancer:()=>[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("starbase","galaxy"),xs($(this)[0]),2===t.tech.gateway&&(t.galaxy.bolognium_ship={count:0,on:0,crew:0},t.tech.gateway=3),!0)}},ship_dock:{id:"galaxy-ship_dock",title:F("galaxy_ship_dock"),desc:`
    ${F("galaxy_ship_dock")}
    ${F("requires_power")}
    `,reqs:{gateway:4},cost:{Money:e=>Xi("ship_dock",e,36e5,1.25,"galaxy"),Steel:e=>Xi("ship_dock",e,88e4,1.25,"galaxy"),Aluminium:e=>Xi("ship_dock",e,12e5,1.25,"galaxy"),Bolognium:e=>Xi("ship_dock",e,75e3,1.25,"galaxy")},effect(){return`
    ${F("galaxy_ship_dock_effect",[.25])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},support:()=>i.starbase?.25*i.starbase:0,powered:()=>oc(i.s_gate?4:0),powerBalancer:()=>[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],action(){return!!Os($(this)[0])&&(Nt("ship_dock","galaxy"),xs($(this)[0]),!0)}},bolognium_ship:{id:"galaxy-bolognium_ship",title:F("galaxy_bolognium_ship"),desc:()=>`
    ${F("galaxy_bolognium_ship_desc")}
    ${F("galaxy_starbase_support",[F("resource_Helium_3_name")])}
    `,reqs:{gateway:3},cost:{Money:e=>Xi("bolognium_ship",e,14e5,1.22,"galaxy"),Iron:e=>Xi("bolognium_ship",e,56e4,1.22,"galaxy"),Infernite:e=>Xi("bolognium_ship",e,1800,1.22,"galaxy"),Nano_Tube:e=>Xi("bolognium_ship",e,475e3,1.22,"galaxy")},effect(){let e=+Pe("bolognium_ship").toFixed(3),a=+Yt($(this)[0].ship.helium).toFixed(2);return`
    ${F("gain",[e,F("resource_Bolognium_name")])}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
    ${F("spend",[a,t.resource.Helium_3.name])}
    `},support:()=>-1,ship:{civ:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2,mil:()=>0,helium:5},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("bolognium_ship","galaxy"),t.resource.Bolognium.display=!0,t.civic.crew.display=!0,t.galaxy.starbase.support`
    ${F("galaxy_scout_ship")}
    ${F("galaxy_starbase_support",[F("resource_Helium_3_name")])}
    `,reqs:{andromeda:1},cost:{Money:e=>Xi("scout_ship",e,16e5,1.25,"galaxy"),Titanium:e=>Xi("scout_ship",e,325e3,1.25,"galaxy"),Graphene:e=>Xi("scout_ship",e,118e3,1.25,"galaxy"),Soul_Gem:e=>Xi("scout_ship",e,1,1.02,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2),a=t.tech.science>=17?`
    ${F("galaxy_scout_ship_effect2",[25])}
    `:"";return`
    ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
    ${F("galaxy_scout_ship_effect")}
    ${a}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
    ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
    ${F("spend",[e,t.resource.Helium_3.name])}
    `},support:()=>-1,ship:{civ:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,mil:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,helium:6,rating:()=>t.race.banana?7:10},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("scout_ship","galaxy"),t.galaxy.defense.gxy_gateway.scout_ship++,t.galaxy.starbase.support`
    ${F("galaxy_corvette_ship")}
    ${F("galaxy_starbase_support",[F("resource_Helium_3_name")])}
    `,reqs:{andromeda:2},cost:{Money:e=>Xi("corvette_ship",e,45e5,1.25,"galaxy"),Steel:e=>Xi("corvette_ship",e,175e4,1.25,"galaxy"),Infernite:e=>Xi("corvette_ship",e,16e3,1.25,"galaxy"),Bolognium:e=>Xi("corvette_ship",e,35e3,1.25,"galaxy"),Soul_Gem:e=>Xi("corvette_ship",e,1,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return`
    ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
    ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
    ${F("spend",[e,t.resource.Helium_3.name])}
    `},support:()=>-1,ship:{civ:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2,mil:()=>t.race.high_pop?3*ui.high_pop.vars()[0]:3,helium:10,rating:()=>t.race.banana?21:30},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("corvette_ship","galaxy"),t.galaxy.defense.gxy_gateway.corvette_ship++,t.galaxy.starbase.support`
    ${F("galaxy_frigate_ship")}
    ${F("galaxy_starbase_support",[F("resource_Helium_3_name")])}
    `,reqs:{andromeda:3},cost:{Money:e=>Xi("frigate_ship",e,18e6,1.25,"galaxy"),Elerium:e=>Xi("frigate_ship",e,1250,1.25,"galaxy"),Mythril:e=>Xi("frigate_ship",e,35e4,1.25,"galaxy"),Sheet_Metal:e=>Xi("frigate_ship",e,8e5,1.25,"galaxy"),Soul_Gem:e=>Xi("frigate_ship",e,2,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return`
    ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
    ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
    ${F("spend",[e,t.resource.Helium_3.name])}
    `},support:()=>-2,ship:{civ:()=>t.race.high_pop?3*ui.high_pop.vars()[0]:3,mil:()=>t.race.high_pop?5*ui.high_pop.vars()[0]:5,helium:25,rating:()=>t.race.banana?56:80},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("frigate_ship","galaxy"),t.galaxy.defense.gxy_gateway.frigate_ship++,t.galaxy.starbase.support+1`
    ${F("galaxy_cruiser_ship")}
    ${F("galaxy_starbase_support",[F("resource_Deuterium_name")])}
    `,reqs:{andromeda:4},cost:{Money:e=>Xi("cruiser_ship",e,75e6,1.25,"galaxy"),Copper:e=>Xi("cruiser_ship",e,6e6,1.25,"galaxy"),Adamantite:e=>Xi("cruiser_ship",e,1e6,1.25,"galaxy"),Vitreloy:e=>Xi("cruiser_ship",e,75e4,1.25,"galaxy"),Elerium:e=>Xi("cruiser_ship",e,1800,1.25,"galaxy"),Soul_Gem:e=>Xi("cruiser_ship",e,5,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.deuterium).toFixed(2);return`
    ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
    ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
    ${F("spend",[e,t.resource.Deuterium.name])}
    `},support:()=>-3,ship:{civ:()=>t.race.high_pop?6*ui.high_pop.vars()[0]:6,mil:()=>t.race.high_pop?10*ui.high_pop.vars()[0]:10,deuterium:25,rating:()=>t.race.banana?175:250},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("cruiser_ship","galaxy"),t.galaxy.defense.gxy_gateway.cruiser_ship++,t.galaxy.starbase.support+2`
    ${F("galaxy_dreadnought")}
    ${F("galaxy_starbase_support",[F("resource_Deuterium_name")])}
    `,reqs:{andromeda:5},cost:{Money:e=>Xi("dreadnought",e,225e6,1.25,"galaxy"),Neutronium:e=>Xi("dreadnought",e,25e4,1.25,"galaxy"),Bolognium:e=>Xi("dreadnought",e,15e5,1.25,"galaxy"),Vitreloy:e=>Xi("dreadnought",e,1e6,1.25,"galaxy"),Infernite:e=>Xi("dreadnought",e,4e5,1.25,"galaxy"),Aerogel:e=>Xi("dreadnought",e,8e5,1.25,"galaxy"),Soul_Gem:e=>Xi("dreadnought",e,25,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.deuterium).toFixed(2);return`
    ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
    ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
    ${F("spend",[e,t.resource.Deuterium.name])}
    `},support:()=>-5,ship:{civ:()=>t.race.high_pop?10*ui.high_pop.vars()[0]:10,mil:()=>t.race.high_pop?20*ui.high_pop.vars()[0]:20,deuterium:80,rating:()=>t.race.banana?1260:1800},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("dreadnought","galaxy"),t.galaxy.defense.gxy_gateway.dreadnought++,t.galaxy.starbase.support+2t.tech.piracy?F("galaxy_stargate_desc_alt"):F("galaxy_stargate_desc"),control:()=>({name:Ac("name"),color:"success"})},gateway_station:{id:"galaxy-gateway_station",title:F("galaxy_gateway_station"),desc:()=>`
    ${F("galaxy_gateway_station_desc")}
    ${F("requires_power")}
    `,reqs:{stargate:4},cost:{Money:e=>Xi("gateway_station",e,5e6,1.25,"galaxy"),Aluminium:e=>Xi("gateway_station",e,52e4,1.25,"galaxy"),Polymer:e=>Xi("gateway_station",e,35e4,1.25,"galaxy"),Neutronium:e=>Xi("gateway_station",e,17500,1.25,"galaxy")},effect(){let e=Lr(2e3),a=Lr(4500),r=Lr(50),s="";return t.tech.gateway&&t.tech.gateway>=2&&(s=`
    ${F("galaxy_gateway_support",[$(this)[0].support()])}
    `),`${s}
    ${F("plus_max_resource",[e,F("resource_Helium_3_name")])}
    ${F("plus_max_resource",[a,F("resource_Deuterium_name")])}
    ${F("plus_max_resource",[r,F("resource_Elerium_name")])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},support:()=>.5,powered:()=>oc(i.s_gate?4:0),powerBalancer:()=>!t.galaxy.hasOwnProperty("starbase")&&[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("gateway_station","galaxy"),t.resource.Helium_3.max+=Lr(2e3),t.resource.Deuterium.max+=Lr(4500),4===t.tech.stargate&&(t.galaxy.telemetry_beacon={count:0,on:0},t.tech.stargate=5),xs($(this)[0]),!0)}},telemetry_beacon:{id:"galaxy-telemetry_beacon",title:F("galaxy_telemetry_beacon"),desc:()=>`
    ${F("galaxy_telemetry_beacon")}
    ${F("requires_power")}
    `,reqs:{stargate:5},cost:{Money:e=>Xi("telemetry_beacon",e,225e4,1.25,"galaxy"),Copper:e=>Xi("telemetry_beacon",e,685e3,1.25,"galaxy"),Alloy:e=>Xi("telemetry_beacon",e,425e3,1.25,"galaxy"),Iridium:e=>Xi("telemetry_beacon",e,177e3,1.25,"galaxy")},effect(){let e=t.tech.telemetry?1200:800;t.tech.science>=17&&(e+=25*n.scout_ship);let a=i.telemetry_beacon?e*i.telemetry_beacon:0,r="";return t.tech.gateway&&t.tech.gateway>=2&&(r=`
    ${F("galaxy_gateway_support",[$(this)[0].support()])}
    `),`${r}
    ${F("galaxy_telemetry_beacon_effect1",[e])}
    ${F("galaxy_telemetry_beacon_effect2",[a])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},support:()=>t.tech.telemetry?.75:.5,powered:()=>oc(i.s_gate?4:0),powerBalancer:()=>!t.galaxy.hasOwnProperty("starbase")&&[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],postPower(e){let a=e?i.telemetry_beacon+y():i.telemetry_beacon-y();a>t.galaxy.telemetry_beacon.count?a=t.galaxy.telemetry_beacon.count:a<0&&(a=0),i.telemetry_beacon=a,Ps($(this)[0],"galaxy","telemetry_beacon")},action(){return!!Os($(this)[0])&&(Nt("telemetry_beacon","galaxy"),xs($(this)[0])&&(t.resource.Knowledge.max+=1750),t.tech.gateway||(t.galaxy.starbase={count:0,on:0,support:0,s_max:0},t.settings.space.gateway=!0,t.tech.gateway=1,Wt()),!0)}},gateway_depot:{id:"galaxy-gateway_depot",title:F("galaxy_gateway_depot"),desc:`
    ${F("galaxy_gateway_depot")}
    `,reqs:{gateway:5},cost:{Money:e=>Xi("gateway_depot",e,4e6,1.25,"galaxy"),Neutronium:e=>Xi("gateway_depot",e,8e4,1.25,"galaxy"),Stanene:e=>Xi("gateway_depot",e,5e5,1.25,"galaxy"),Vitreloy:e=>Xi("gateway_depot",e,2500,1.25,"galaxy")},wide:!0,effect(){let e=t.tech.world_control?150:100,a=Lr(200),r=Kt(),s=k(+Lr(3e3*r).toFixed(0),1),i=k(+Lr(25e4*r).toFixed(0),1),c=k(+Lr(9001*r).toFixed(0),1),o=k(+Lr(6660*r).toFixed(0),1),n='
    ';return n+=`${F("plus_max_crates",[e])}${F("plus_max_containers",[e])}`,n+=`${F("plus_max_resource",[s,t.resource.Uranium.name])}`,n+=`${F("plus_max_resource",[i,t.resource.Nano_Tube.name])}`,n+=`${F("plus_max_resource",[c,t.resource.Neutronium.name])}`,n+=`${F("plus_max_resource",[o,t.resource.Infernite.name])}`,n+="
    ",`${n}
    ${F("galaxy_gateway_depot_effect",[a,F("resource_Elerium_name")])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(i.s_gate?10:0),action(){if(Os($(this)[0])){Nt("gateway_depot","galaxy");let e=Kt();return t.resource.Uranium.max+=Lr(3e3*e),t.resource.Nano_Tube.max+=Lr(25e4*e),t.resource.Neutronium.max+=Lr(9001*e),t.resource.Infernite.max+=Lr(6660*e),xs($(this)[0]),!0}return!1}},defense_platform:{id:"galaxy-defense_platform",title:F("galaxy_defense_platform"),desc:()=>`
    ${F("galaxy_defense_platform")}
    ${F("requires_power")}
    `,reqs:{stargate:6},cost:{Money:e=>Xi("defense_platform",e,75e4,1.25,"galaxy"),Adamantite:e=>Xi("defense_platform",e,425e3,1.25,"galaxy"),Elerium:e=>Xi("defense_platform",e,800,1.25,"galaxy"),Vitreloy:e=>Xi("defense_platform",e,1250,1.25,"galaxy"),Wrought_Iron:e=>Xi("defense_platform",e,75e3,1.25,"galaxy")},effect(){return`
    ${F("galaxy_defense_platform_effect",[20])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(i.s_gate?5:0),postPower(e){sc({el:"#gxy_stargate"},"update")},action(){return!!Os($(this)[0])&&(Nt("defense_platform","galaxy"),xs($(this)[0]),!0)},post(){sc({el:"#gxy_stargate"},"update")}}},gxy_gorddon:{info:{name:F("galaxy_gorddon"),desc:()=>F("galaxy_gorddon_desc"),control:()=>({name:di[t.galaxy.alien1.id].name,color:"advanced"})},gorddon_mission:{id:"galaxy-gorddon_mission",title:F("galaxy_gorddon_mission"),desc:F("galaxy_gorddon_mission_desc"),reqs:{xeno:2},grant:["xeno",3],queue_complete:()=>t.tech.xeno>=3?0:1,cost:{Structs:()=>({galaxy:{scout_ship:{s:"gxy_gateway",count:2,on:2},corvette_ship:{s:"gxy_gateway",count:1,on:1}}}),Helium_3:()=>+Yt(23e4).toFixed(0),Deuterium:()=>+Yt(125e3).toFixed(0)},effect:F("galaxy_gorddon_mission_effect"),action(){if(Os($(this)[0])){It(),t.galaxy.defense.gxy_gateway.scout_ship-=2,t.galaxy.defense.gxy_gorddon.scout_ship+=2,t.galaxy.defense.gxy_gateway.corvette_ship--,t.galaxy.defense.gxy_gorddon.corvette_ship++;let e=di[t.galaxy.alien1.id].name,a=di[t.galaxy.alien1.id].entity,r=di[t.galaxy.alien2.id].name;return Di(F("galaxy_gorddon_mission_result",[a,e,di[t.galaxy.alien2.id].entity,r]),"info",!1,["progress"]),!0}return!1}},embassy:{id:"galaxy-embassy",title:F("galaxy_embassy"),desc:()=>`
    ${F("galaxy_embassy")}
    ${F("requires_power_combo",[t.resource.Food.name])}
    `,reqs:{xeno:4},queue_complete:()=>1-t.galaxy.embassy.count,cost:{Money:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?3e7:0,Lumber:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?38e6:0,Stone:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?32e6:0,Furs:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?18e6:0,Wrought_Iron:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?6e6:0},effect(){let e="";return t.tech.xeno>=11&&(e=`
    ${F("plus_max_citizens",[$(this)[0].citizens()])}
    `),`
    ${F("galaxy_embassy_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
    ${e}
    ${F("interstellar_alpha_starport_effect3",[7500,t.resource.Food.name])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(i.s_gate?25:0),refresh:!0,action(){return!!(t.galaxy.embassy.count<1&&Os($(this)[0]))&&(Nt("embassy","galaxy"),xs($(this)[0]),4===t.tech.xeno&&(t.tech.xeno=5,t.galaxy.freighter={count:0,on:0,crew:0},t.galaxy.trade={max:0,cur:0,f0:0,f1:0,f2:0,f3:0,f4:0,f5:0,f6:0,f7:0,f8:0},rc($("#resources")),rr(),Di(F("galaxy_embassy_complete",[di[t.galaxy.alien1.id].name,di[t.galaxy.alien2.id].name]),"info",!1,["progress"])),!0)},citizens(){let e=20;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},dormitory:{id:"galaxy-dormitory",title:F("galaxy_dormitory"),desc:()=>`
    ${F("galaxy_dormitory")}
    ${F("requires_power")}
    `,reqs:{xeno:6},cost:{Money:e=>Xi("dormitory",e,1e7,1.25,"galaxy"),Furs:e=>Xi("dormitory",e,7e5,1.25,"galaxy"),Cement:e=>Xi("dormitory",e,12e5,1.25,"galaxy"),Plywood:e=>Xi("dormitory",e,85e3,1.25,"galaxy"),Horseshoe:()=>t.race.hooved?3:0},effect(){return`
    ${F("requires_res",[F("galaxy_embassy")])}
    ${F("plus_max_citizens",[$(this)[0].citizens()])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(3),action(){return!!Os($(this)[0])&&(Nt("dormitory","galaxy"),xs($(this)[0]),!0)},citizens(){let e=3;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},symposium:{id:"galaxy-symposium",title:F("galaxy_symposium"),desc:()=>`
    ${F("galaxy_symposium")}
    ${F("requires_power")}
    `,reqs:{xeno:6},cost:{Money:e=>Xi("symposium",e,8e6,1.25,"galaxy"),Food:e=>t.race.ravenous?0:Xi("symposium",e,t.race.artifical?45e3:125e3,1.25,"galaxy"),Lumber:e=>Xi("symposium",e,46e4,1.25,"galaxy"),Brick:e=>Xi("symposium",e,261600,1.25,"galaxy")},effect(){let e="";return t.tech.xeno>=7&&(e=`
    ${F("galaxy_symposium_effect3",[+Me(300).toFixed(2)])}
    `),`
    ${F("galaxy_symposium_effect",[1750])}
    ${F("galaxy_symposium_effect2",[650])}
    ${e}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(4),action(){return!!Os($(this)[0])&&(Nt("symposium","galaxy"),xs($(this)[0]),!0)}},freighter:{id:"galaxy-freighter",title:F("galaxy_freighter"),desc:()=>`
    ${F("galaxy_freighter")}
    ${F("galaxy_crew_fuel",[F("resource_Helium_3_name")])}
    `,reqs:{xeno:5},cost:{Money:e=>Xi("freighter",e,6e6,1.2,"galaxy"),Uranium:e=>Xi("freighter",e,1e4,1.2,"galaxy"),Adamantite:e=>Xi("freighter",e,46e4,1.2,"galaxy"),Stanene:e=>Xi("freighter",e,261600,1.2,"galaxy"),Bolognium:e=>Xi("freighter",e,66e3,1.2,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2),a="";return t.tech.banking>=13&&(a=`
    ${F("interstellar_exchange_boost",[3])}
    `),`
    ${F("galaxy_freighter_effect",[2,di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
    ${a}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("spend",[e,t.resource.Helium_3.name])}
    `},ship:{civ:()=>t.race.high_pop?3*ui.high_pop.vars()[0]:3,mil:()=>0,helium:12},special:!0,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("freighter","galaxy"),t.galaxy.freighter.on++,t.resource.Vitreloy.display=!0,!0)}}},gxy_alien1:{info:{name:()=>F("galaxy_alien",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),desc:()=>F("galaxy_alien1_desc",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home,di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),control:()=>({name:di[t.galaxy.alien1.id].name,color:"advanced"})},consulate:{id:"galaxy-consulate",title:F("galaxy_consulate"),desc:()=>F("galaxy_consulate_desc",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),reqs:{xeno:8},queue_complete:()=>1-t.galaxy.consulate.count,cost:{Money:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?9e7:0,Stone:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?75e6:0,Furs:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?3e7:0,Iron:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?45e6:0,Horseshoe:e=>t.race.hooved&&(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?10:0},effect(){return F("plus_max_citizens",[$(this)[0].citizens()])},refresh:!0,action(){return!!(Os($(this)[0])&&t.galaxy.consulate.count<1)&&(Nt("consulate","galaxy"),t.galaxy.resort={count:0,on:0},t.galaxy.super_freighter={count:0,on:0,crew:0},t.tech.xeno=9,!0)},citizens(){let e=10;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},resort:{id:"galaxy-resort",title:F("galaxy_resort"),desc:()=>`
    ${F("galaxy_resort")}
    ${F("requires_power")}
    `,reqs:{xeno:9},cost:{Money:e=>Xi("resort",e,33e6,1.25,"galaxy"),Stone:e=>Xi("resort",e,25e6,1.25,"galaxy"),Furs:e=>Xi("resort",e,1e7,1.25,"galaxy"),Oil:e=>Xi("resort",e,Yt(125e3),1.25,"galaxy")},effect(){return`
    ${F("plus_max_citizens",[3])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},effect(){let e=Lr(t.tech.world_control?1875e3:15e5),a=t.race.joyless?"":`
    ${F("city_max_entertainer",[la(2)])}
    `;return`
    ${F("plus_max_resource",[`$${e.toLocaleString()}`,F("resource_Money_name")])}
    ${a}
    ${F("space_red_vr_center_effect2",[2])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(5),action(){return!!Os($(this)[0])&&(Nt("resort","galaxy"),xs($(this)[0]),!0)}},vitreloy_plant:{id:"galaxy-vitreloy_plant",title:F("galaxy_vitreloy_plant"),desc:()=>`
    ${F("galaxy_vitreloy_plant")}
    ${F("galaxy_vitreloy_plant_desc")}
    `,reqs:{xeno:10},cost:{Money:e=>Xi("vitreloy_plant",e,35e6,1.25,"galaxy"),Cement:e=>Xi("vitreloy_plant",e,18e5,1.25,"galaxy"),Neutronium:e=>Xi("vitreloy_plant",e,25e4,1.25,"galaxy"),Iridium:e=>Xi("vitreloy_plant",e,85e4,1.25,"galaxy"),Aerogel:e=>Xi("vitreloy_plant",e,4e5,1.25,"galaxy")},effect(){return`
    ${F("galaxy_vitreloy_plant_effect",[+Pe("vitreloy_plant").toFixed(2)])}
    ${F("galaxy_vitreloy_plant_effect2",[2.5,100])}
    ${F("galaxy_vitreloy_plant_effect3",[5e4,$(this)[0].powered()])}
    `},powered:()=>oc(10),action(){return!!Os($(this)[0])&&(Nt("vitreloy_plant","galaxy"),xs($(this)[0]),!0)}},super_freighter:{id:"galaxy-super_freighter",title:F("galaxy_super_freighter"),desc:()=>`
    ${F("galaxy_super_freighter")}
    ${F("galaxy_crew_fuel",[F("resource_Helium_3_name")])}
    `,reqs:{xeno:9},cost:{Money:e=>Xi("super_freighter",e,28e6,1.2,"galaxy"),Aluminium:e=>Xi("super_freighter",e,35e5,1.2,"galaxy"),Alloy:e=>Xi("super_freighter",e,1e6,1.2,"galaxy"),Graphene:e=>Xi("super_freighter",e,75e4,1.2,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2),a="";return t.tech.banking>=13&&(a=`
    ${F("interstellar_exchange_boost",[8])}
    `),`
    ${F("galaxy_freighter_effect",[5,di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
    ${a}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("spend",[e,t.resource.Helium_3.name])}
    `},ship:{civ:()=>t.race.high_pop?5*ui.high_pop.vars()[0]:5,mil:()=>0,helium:25},special:!0,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("super_freighter","galaxy"),t.galaxy.super_freighter.on++,!0)}}},gxy_alien2:{info:{name:()=>F("galaxy_alien",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),desc:()=>F("galaxy_alien2_desc",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red,di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),control:()=>({name:di[t.galaxy.alien2.id].name,color:"danger"}),support:"foothold"},alien2_mission:{id:"galaxy-alien2_mission",title:()=>F("galaxy_alien2_mission",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),desc:()=>F("galaxy_alien2_mission_desc",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),reqs:{andromeda:4},grant:["conflict",1],queue_complete:()=>t.tech.conflict>=1?0:1,cost:{Custom(){if(t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_alien2")){let e=0;return Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]})),{label:F("galaxy_fleet_rating",[`400`]),met:!(e<400)}}return{label:F("galaxy_fleet_rating",['400']),met:!1}}},effect(){let e=0;t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_alien2")&&Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]}));let a=e>=650?`${F("galaxy_piracy_low")}`:`${F("galaxy_piracy_avg")}`;return`
    ${F("galaxy_alien2_mission_effect2",[e])}
    ${F("galaxy_alien2_mission_effect3",[a])}
    ${F("galaxy_alien2_mission_effect",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name])}
    `},action(){if(Os($(this)[0])){let e=0;if(Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]})),e>=400){if(Di(F("galaxy_alien2_mission_result2",[di[t.galaxy.alien2.id].solar.red]),"info",!1,["progress"]),e<650){let e=80;t.race.instinct&&(e/=2);let a=[];Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(r){for(let s=0;s0&&(e-=At.gxy_gateway[r].ship.rating(),a.push(r))})),Di(F("galaxy_chthonian_mission_result_losses",[a.map((e=>F(`galaxy_${e}`))).join(", ")]),"danger",!1,["progress"]);for(let e=0;e`
    ${F("galaxy_foothold")}
    ${F("requires_power_combo",[t.resource.Elerium.name])}
    `,reqs:{conflict:1},cost:{Money:e=>Xi("foothold",e,25e6,1.25,"galaxy"),Titanium:e=>Xi("foothold",e,3e6,1.25,"galaxy"),Polymer:e=>Xi("foothold",e,175e4,1.25,"galaxy"),Iridium:e=>Xi("foothold",e,9e5,1.25,"galaxy"),Bolognium:e=>Xi("foothold",e,5e4,1.25,"galaxy")},effect(){return`
    ${F("galaxy_defense_platform_effect",[50])}
    ${F("galaxy_foothold_effect",[$(this)[0].support(),di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
    ${F("galaxy_foothold_effect2",[2.5,$(this)[0].powered()])}
    `},support:()=>4,powered:()=>oc(i.s_gate?20:0),powerBalancer:()=>[{s:t.galaxy.foothold.s_max-t.galaxy.foothold.support}],action(){return!!Os($(this)[0])&&(Nt("foothold","galaxy"),xs($(this)[0]),1===t.tech.conflict&&(t.galaxy.armed_miner={count:0,on:0,crew:0,mil:0},t.tech.conflict=2,Wt(),ms()),!0)}},armed_miner:{id:"galaxy-armed_miner",title:F("galaxy_armed_miner"),desc:()=>`
    ${F("galaxy_armed_miner")}
    `,reqs:{conflict:2},cost:{Money:e=>Xi("armed_miner",e,5e6,1.25,"galaxy"),Steel:e=>Xi("armed_miner",e,18e5,1.25,"galaxy"),Stanene:e=>Xi("armed_miner",e,1975e3,1.25,"galaxy"),Vitreloy:e=>Xi("armed_miner",e,2e4,1.25,"galaxy"),Soul_Gem:e=>Xi("armed_miner",e,1,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return`
    ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
    ${F("gain",[.032,F("resource_Bolognium_name")])}
    ${F("gain",[.23,F("resource_Adamantite_name")])}
    ${F("gain",[.65,F("resource_Iridium_name")])}
    ${F("galaxy_alien2_support",[$(this)[0].support(),di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
    ${F("spend",[e,t.resource.Helium_3.name])}
    `},ship:{civ:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2,mil:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,helium:10,rating:()=>t.race.banana?4:5},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("armed_miner","galaxy"),t.galaxy.foothold.support`
    ${F("galaxy_ore_processor")}
    `,reqs:{conflict:3},cost:{Money:e=>Xi("ore_processor",e,3e6,1.25,"galaxy"),Iron:e=>Xi("ore_processor",e,5e6,1.25,"galaxy"),Coal:e=>Xi("ore_processor",e,375e4,1.25,"galaxy"),Graphene:e=>Xi("ore_processor",e,225e4,1.25,"galaxy")},effect(){return`
    ${F("galaxy_ore_processor_effect",[10])}
    ${F("galaxy_alien2_support",[$(this)[0].support(),di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
    `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("ore_processor","galaxy"),t.galaxy.foothold.supportXi("scavenger",e,75e5,1.25,"galaxy"),Alloy:e=>Xi("scavenger",e,125e4,1.25,"galaxy"),Aluminium:e=>Xi("scavenger",e,68e5,1.25,"galaxy"),Neutronium:e=>Xi("scavenger",e,75e3,1.25,"galaxy"),Elerium:e=>Xi("scavenger",e,750,1.25,"galaxy")},effect(){let e=Et("gxy_alien2"),a=Math.round(25e3*e),r=+Yt($(this)[0].ship.helium).toFixed(2),s=t.race.cataclysm?`
    ${F("galaxy_scavenger_effect2_cata",[+(100*e*.75).toFixed(1)])}
    `:`
    ${F("galaxy_scavenger_effect2",[+(100*e/4).toFixed(1)])}
    `;return`
    ${F("galaxy_scavenger_effect",[a])}
    ${s}
    ${F("galaxy_alien2_support",[$(this)[0].support(),di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    ${F("spend",[r,t.resource.Helium_3.name])}
    `},ship:{civ:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,mil:()=>0,helium:12},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("scavenger","galaxy"),t.galaxy.foothold.supportF("galaxy_chthonian"),desc:()=>F("galaxy_chthonian_desc",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),control:()=>({name:di[t.galaxy.alien2.id].name,color:"danger"})},chthonian_mission:{id:"galaxy-chthonian_mission",title:()=>F("galaxy_alien2_mission",[F("galaxy_chthonian")]),desc:()=>F("galaxy_alien2_mission_desc",[F("galaxy_chthonian")]),reqs:{chthonian:1},grant:["chthonian",2],queue_complete:()=>t.tech.chthonian>=2?0:1,cost:{Custom(){if(t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_chthonian")){let e=0;return Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]})),{label:F("galaxy_fleet_rating",[`1250`]),met:!(e<1250)}}return{label:F("galaxy_fleet_rating",['1250']),met:!1}}},effect(){let e=0;t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_chthonian")&&Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]}));let a=e>=4500?`${F("galaxy_piracy_low")}`:e>=2500?`${F("galaxy_piracy_avg")}`:`${F("galaxy_piracy_high")}`;return`
    ${F("galaxy_alien2_mission_effect2",[e])}
    ${F("galaxy_alien2_mission_effect3",[a])}
    ${F("galaxy_alien2_mission_effect",[F("galaxy_chthonian")])}
    `},action(){if(Os($(this)[0])){let e=0;if(Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]})),e>=1250){let a=500,r=[];Di(F("galaxy_chthonian_mission_result"),"info",!1,["progress"]),e>=2500&&(a=e>=4500?80:160),t.race.instinct&&(a/=2),Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(e){for(let s=0;s0&&(a-=At.gxy_gateway[e].ship.rating(),r.push(e))})),Di(F("galaxy_chthonian_mission_result_losses",[r.map((e=>F(`galaxy_${e}`))).join(", ")]),"danger",!1,["progress"]);for(let e=0;e`
    ${F("galaxy_minelayer")}
    `,reqs:{chthonian:2},cost:{Money:e=>Xi("minelayer",e,9e6,1.25,"galaxy"),Iron:e=>Xi("minelayer",e,48e5,1.25,"galaxy"),Nano_Tube:e=>Xi("minelayer",e,125e4,1.25,"galaxy"),Nanoweave:e=>Xi("minelayer",e,1e5,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return`
    ${F("galaxy_defense_platform_effect",[$(this)[0].ship.rating()])}
    ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
    ${F("spend",[e,t.resource.Helium_3.name])}
    `},ship:{civ:()=>0,mil:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,helium:8,rating:()=>t.race.banana?35:50},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("minelayer","galaxy"),t.galaxy.minelayer.on++,!0)},postPower(){sc({el:"#gxy_chthonian"},"update")},post(){sc({el:"#gxy_chthonian"},"update")}},excavator:{id:"galaxy-excavator",title:F("galaxy_excavator"),desc:()=>`
    ${F("galaxy_excavator")}
    `,reqs:{chthonian:3},cost:{Money:e=>Xi("excavator",e,12e6,1.25,"galaxy"),Polymer:e=>Xi("excavator",e,44e5,1.25,"galaxy"),Iridium:e=>Xi("excavator",e,36e5,1.25,"galaxy"),Mythril:e=>Xi("excavator",e,18e4,1.25,"galaxy")},effect(){return`
    ${F("gain",[+Pe("excavator").toFixed(3),F("resource_Orichalcum_name")])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(8),powerBalancer:()=>[{r:"Orichalcum",p:Pe("excavator")}],action(){return!!Os($(this)[0])&&(Nt("excavator","galaxy"),xs($(this)[0]),!0)}},raider:{id:"galaxy-raider",title:F("galaxy_raider"),desc:()=>`
    ${F("galaxy_raider")}
    `,reqs:{chthonian:3},cost:{Money:e=>Xi("raider",e,12e6,1.25,"galaxy"),Titanium:e=>Xi("raider",e,125e4,1.25,"galaxy"),Bolognium:e=>Xi("raider",e,6e5,1.25,"galaxy"),Vitreloy:e=>Xi("raider",e,125e3,1.25,"galaxy"),Stanene:e=>Xi("raider",e,825e3,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return Et("gxy_chthonian"),`
    ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
    ${F("gain",[.65,F("resource_Deuterium_name")])}
    ${F("gain",[.05,F("resource_Vitreloy_name")])}
    ${F("gain",[2.3,F("resource_Polymer_name")])}
    ${F("gain",[.8,F("resource_Neutronium_name")])}
    ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
    ${F("spend",[e,t.resource.Helium_3.name])}
    `},ship:{civ:()=>0,mil:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2,helium:18,rating:()=>t.race.banana?9:12},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("raider","galaxy"),t.galaxy.raider.on++,!0)},postPower(){sc({el:"#gxy_chthonian"},"update")},post(){sc({el:"#gxy_chthonian"},"update")}}}};function Tt(e){let t="space";return"int_"===e.substr(0,4)?t="interstellar":"prtl_"===e.substr(0,5)?t="portal":"gxy_"===e.substr(0,4)?t="galaxy":"tau_"===e.substr(0,4)&&(t="tauceti"),t}function Et(e,a,r){if(t.tech.piracy&&!t.race.truepath){let s=0,c=["dreadnought","cruiser_ship","frigate_ship","corvette_ship","scout_ship"];for(let a=0;ao?o:s))/o)*l+(1-l))*(a?1:Et("gxy_stargate")):(1-(o-(s>o?o:s))/o)*l+(1-l)}return 1}function It(){let e=["protoplasm",t.race.species];t.city.hasOwnProperty("surfaceDwellers")&&e.push(...t.city.surfaceDwellers),t.custom.hasOwnProperty("race0")||e.push("custom");let a=Object.keys(di).filter((function(t){return!["demonic","eldritch"].includes(di[t].type)&&!e.includes(t)})),r=Cc(a);t.galaxy.alien1={id:a[r]},e.push(a[r]),a=Object.keys(di).filter((function(t){return!["angelic"].includes(di[t].type)&&!e.includes(t)}));let s=Cc(a);t.galaxy.alien2={id:a[s]}}function Kt(){let e=1;return t.race.pack_rat&&(e*=1.05),t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),e*=t.tech.world_control?2:1,e}const Lt={satellite:{count:0},propellant_depot:{count:0},gps:{count:0},nav_beacon:{count:0,on:0},moon_base:{count:0,on:0,support:0,s_max:0},iridium_mine:{count:0,on:0},helium_mine:{count:0,on:0},observatory:{count:0,on:0},spaceport:{count:0,on:0,support:0,s_max:0},red_tower:{count:0,on:0},living_quarters:{count:0,on:0},vr_center:{count:0,on:0},garage:{count:0},red_mine:{count:0,on:0},fabrication:{count:0,on:0},red_factory:{count:0,on:0},exotic_lab:{count:0,on:0},ziggurat:{count:0},space_barracks:{count:0,on:0},biodome:{count:0,on:0},laboratory:{count:0,on:0},geothermal:{count:0,on:0},swarm_plant:{count:0},swarm_control:{count:0,support:0,s_max:0},swarm_satellite:{count:0},gas_mining:{count:0,on:0},gas_storage:{count:0},star_dock:{count:0,ship:0,probe:0,template:"human"},outpost:{count:0,on:0},drone:{count:0},oil_extractor:{count:0,on:0},space_station:{count:0,on:0,support:0,s_max:0},iridium_ship:{count:0,on:0},elerium_ship:{count:0,on:0},elerium_prospector:{count:0,on:0},iron_ship:{count:0,on:0},elerium_contain:{count:0,on:0},e_reactor:{count:0,on:0},world_collider:{count:0},world_controller:{count:0,on:0},starport:{count:0,on:0,support:0,s_max:0},mining_droid:{count:0,on:0,adam:0,uran:0,coal:0,alum:0},processing:{count:0,on:0},habitat:{count:0,on:0},fusion:{count:0,on:0},laboratory:{count:0,on:0},exchange:{count:0,on:0},warehouse:{count:0},xfer_station:{count:0,on:0},cargo_yard:{count:0},cruiser:{count:0,on:0},dyson:{count:0},nexus:{count:0,on:0,support:0,s_max:0},harvester:{count:0,on:0},far_reach:{count:0,on:0},stellar_engine:{count:0,mass:8,exotic:0},mass_ejector:{count:0,on:0,total:0,mass:0,Food:0,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0},stargate:{count:0},gateway_station:{count:0,on:0},s_gate:{count:0,on:0},starbase:{count:0,on:0,support:0,s_max:0},bolognium_ship:{count:0,on:0,crew:0},scout_ship:{count:0,on:0,crew:0,mil:0},corvette_ship:{count:0,on:0,crew:0,mil:0},frigate_ship:{count:0,on:0,crew:0,mil:0},cruiser_ship:{count:0,on:0,crew:0,mil:0},dreadnought:{count:0,on:0,crew:0,mil:0},foothold:{count:0,on:0,support:0,s_max:0},turret:{count:0,on:0},carport:{count:0,damaged:0,repair:0},war_droid:{count:0,on:0},repair_droid:{count:0,on:0},war_drones:{count:0,on:0},sensor_drone:{count:0,on:0},attractor:{count:0,on:0}};function Nt(e,a){a||(a="space"),t[a][e]||(t[a][e]=Lt[e]),t[a][e].count++}function Dt(e,t){return e&&t?jt[e][t]:jt}function Bt(e,t,a){switch(e){case"space":return Gt(jt,t,a);case"interstellar":return Gt(St,t,a);case"galaxy":return Gt(At,t,a)}}function Gt(e,a,r){let s=t.race.truepath?"truepath":"standard";if(e[a][r].hasOwnProperty("path")&&!e[a][r].path.includes(s))return!1;var i=!0;return Object.keys(e[a][r].reqs).forEach((function(s){(!t.tech[s]||t.tech[s]=e[a][r].grant[1]&&(i=!1),i}function Rt(){(t.settings.tabLoad||1===t.settings.civTabs)&&(Ht("inner"),t.race.truepath&&Ht("outer"),Ut(),Wt())}function Ht(e){if(e||(e=5===t.settings.spaceTabs?"outer":"inner"),!t.settings.tabLoad&&(1!==t.settings.civTabs||![1,5].includes(t.settings.spaceTabs)||1===t.settings.civTabs&&1===t.settings.spaceTabs&&"inner"!==e||5===t.settings.spaceTabs&&"outer"!==e))return;let a="inner"===e?$("#space"):$("#outerSol");if(rc(a),a.append($(`

    ${F("inner"===e?"tab_space":"tab_outer_space")}

    `)),!t.settings.showSpace)return!1;let r=[];Object.keys(jt).forEach((function(e){t.race.orbit_decayed||t.race.cataclysm?"spc_home"!==e&&(r.push(e),(t.race.orbit_decayed&&"spc_red"===e||t.race.cataclysm&&"spc_moon"===e)&&r.push("spc_home")):r.push(e)})),r.forEach((function(r){let s=r.replace("spc_","");if(t.settings.space[`${s}`]){if(t.race.truepath&&jt[r].info.zone!==e)return;let s="string"==typeof jt[r].info.name?jt[r].info.name:jt[r].info.name(),i=!(!t.race.orbit_decayed&&!t.race.cataclysm);if(i&&"spc_home"!==r||!i){if(jt[r].info.support){let e=jt[r].info.support;t.space[e].hasOwnProperty("support")||(t.space[e].support=0,t.space[e].s_max=0),a.append(`

    ${s}

    {{ support }}/{{ s_max }}
    `),sc({el:`#sr${r}`,data:t.space[e]})}else a.append(`

    ${s}

    `);t.race.truepath&&jt[r].info.hasOwnProperty("syndicate")&&jt[r].info.syndicate()&&t.tech.syndicate&&($(`#${r}`).append(`
    `),$(`#${r}synd`).append(`${F("space_syndicate")} `),$(`#${r}synd`).append(`${F("space_scan_effectiveness")} `),$(`#${r}synd`).append(`${F("space_overkill")} `),sc({el:`#${r}synd`,data:t.space.syndicate,methods:{threat(e){if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let t=ht(e,!0);if(t.s>=10)return t.s>=50?t.r:Math.round(t.r*t.s*.02)}return"???"},scan:e=>t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")?+((ht(e,!0).s+25)/1.25).toFixed(1)+"%":F("galaxy_piracy_none"),overkill(e){if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let t=ht(e,!0);return t.s>=100?t.o:0}return 0}}}),jt[r].info.hasOwnProperty("extra")&&jt[r].info.extra(r))}Ti(r,(function(){return"string"==typeof jt[r].info.desc?jt[r].info.desc:jt[r].info.desc()}),{elm:`#${r} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(jt[r]).forEach((function(t){"info"!==t&&Gt(jt,r,t)&&fs(jt[r][t],"inner"===e?"space":"outerSol",t)}))}}))}function Ut(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||2!==t.settings.spaceTabs))return;let e=$("#interstellar");if(rc(e),e.append($(`

    ${F("tab_interstellar")}

    `)),!t.settings.showDeep)return!1;Object.keys(St).forEach((function(a){let r=a.replace("int_","");if(t.settings.space[`${r}`]){let r="string"==typeof St[a].info.name?St[a].info.name:St[a].info.name();if(St[a].info.support){let s=St[a].info.support;t.interstellar[s].hasOwnProperty("support")||(t.interstellar[s].support=0,t.interstellar[s].s_max=0),e.append(`

    ${r}

    {{ support }}/{{ s_max }}
    `),sc({el:`#sr${a}`,data:t.interstellar[s]})}else e.append(`

    ${r}

    `);Ti(a,(function(){return"string"==typeof St[a].info.desc?St[a].info.desc:St[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(St[a]).forEach((function(e){"info"!==e&&Gt(St,a,e)&&fs(St[a][e],"interstellar",e)}))}}))}function Wt(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||3!==t.settings.spaceTabs))return;let e=$("#galaxy");if(rc(e),e.append($(`

    ${F("tab_galactic")}

    `)),!t.settings.showGalactic)return!1;!function(e,a){if(t.tech.piracy&&!t.race.truepath){let r=$(`

    ${F("galaxy_armada")}

    `);e.append(r);let s=t.tech.world_control?F("civics_garrison_peacekeepers"):F("civics_garrison_soldiers");r.append($("|")),r.append($(`${s} {{ g.workers | stationed }} / {{ g.max | s_max }}`)),r.append($("|")),r.append($(`${F("job_crew_mil")} {{ g.crew }}`)),r.append($("|")),r.append($(`${F("job_crew_civ")} {{ c.workers }} / {{ c.max }}`)),sc({el:`#h${a}`,data:{g:t.civic.garrison,c:t.civic.crew},filters:{stationed:e=>qe(),s_max:e=>qe(!0)}}),["soldier","crew1","crew2"].forEach((function(e){Ti(`h${a}${e}`,(function(){switch(e){case"soldier":return ve();case"crew1":return F("civics_garrison_crew_desc");case"crew2":return F("job_crew_desc")}}),{elm:`#h${a} span.${e}`})}));let i=$(`
    `);e.append(i);let c=["scout_ship","corvette_ship","frigate_ship","cruiser_ship","dreadnought"],o=[];for(let e=0;e<6;e++){let e=$('
    ');o.push(e),i.append(e)}for(let e=0;e${At.gxy_gateway[c[e]].title}`);o[e+1].append(t)}o[0].append($("")),o[0].append($(`${At.gxy_gateway.info.name}`));for(let e=0;e{{ gateway.${c[e]} }}`);o[e+1].append(t)}Object.keys(t.galaxy.defense).forEach((function(e){let a=e.substring(4);if(t.settings.space[a]&&"gateway"!==a){let r=$(`${"string"==typeof At[e].info.name?At[e].info.name:At[e].info.name()}`);o[0].append(r);for(let r=0;r'),s=$(`«`),i=$(`{{ ${a}.${c[r]} }}`),n=$(`»`);o[r+1].append(t),t.append(s),t.append(i),t.append(n)}}})),sc({el:`#${a}`,data:{stargate:t.galaxy.defense.gxy_stargate,gateway:t.galaxy.defense.gxy_gateway,gorddon:t.galaxy.defense.gxy_gorddon,alien1:t.galaxy.defense.gxy_alien1,alien2:t.galaxy.defense.gxy_alien2,chthonian:t.galaxy.defense.gxy_chthonian,t:t.tech},methods:{sub(e,a){if(t.galaxy.defense[e][a]>0){let r=y();r>t.galaxy.defense[e][a]&&(r=t.galaxy.defense[e][a]),t.galaxy.defense.gxy_gateway[a]+=r,t.galaxy.defense[e][a]-=r}},add(e,a){if(t.galaxy.defense.gxy_gateway[a]>0){let r=y();r>t.galaxy.defense.gxy_gateway[a]&&(r=t.galaxy.defense.gxy_gateway[a]),t.galaxy.defense.gxy_gateway[a]-=r,t.galaxy.defense[e][a]+=r}}}}),Object.keys(t.galaxy.defense).forEach((function(e){let a=e.substring(4);t.settings.space[a]&&Ti(`armada${a}`,(function(){return`
    ${"string"==typeof At[e].info.desc?At[e].info.desc:At[e].info.desc()}
    `}))}));for(let e=0;e`);e.append(s);let i=$(`

    ${r}

    `);s.append(i),t.tech.xeno&&t.tech.xeno>=3&&s.append(`{{ r.control().name }}`);let c={el:`#${a}`,data:{r:At[a].info},methods:{threat(e){let a=t.race.infiltrator?1:2;if(t.galaxy.defense[e].scout_ship>=a){let t=100*(1-Et(e,!0));return t=t<1?Math.ceil(t):Math.round(t),0===t?"has-text-success":t<=20?"has-text-advanced":t<=40?"has-text-info":t<=60?"has-text-warning":t<=80?"has-text-caution":"has-text-danger"}return"has-text-danger"}},filters:{pirate(e){let a=t.race.infiltrator?1:2;if(t.galaxy.defense[e].scout_ship>=a){let a=100*(1-Et(e,!0));a=a<1?Math.ceil(a):Math.round(a);let r=t.race.infiltrator?3:4;return t.galaxy.defense[e].scout_ship>=r?`${a}%`:F(0===a?"galaxy_piracy_none":a<=20?"galaxy_piracy_vlow":a<=40?"galaxy_piracy_low":a<=60?"galaxy_piracy_avg":a<=80?"galaxy_piracy_high":"galaxy_piracy_vhigh")}return"???"},defense:e=>Et(e,!0,!0)}};if(At[a].info.support){let e=At[a].info.support;t.galaxy[e]&&(t.galaxy[e].hasOwnProperty("support")||(t.galaxy[e].support=0,t.galaxy[e].s_max=0),s.append('{{ s.support }}/{{ s.s_max }}'),c.data.s=t.galaxy[e])}t.tech.piracy&&s.append(`
    ${F("galaxy_piracy_threat",[di[t.galaxy.alien2.id].name])}{{ '${a}' | pirate }}|${F("galaxy_armada")}: {{ '${a}' | defense }}
    `),sc(c),Ti(a,(function(){return"string"==typeof At[a].info.desc?At[a].info.desc:At[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Ti(a,(function(){return F("galaxy_control",[At[a].info.control().name,r])}),{elm:`#${a} .regionControl`,classes:"has-background-light has-text-dark"}),Object.keys(At[a]).forEach((function(e){"info"!==e&&Gt(At,a,e)&&fs(At[a][e],"galaxy",e)}))}}))}function Qt(e){return t.tech.space_housing&&(e*=.8**t.tech.space_housing),e}function Zt(e){return t.tech.solar&&t.tech.solar>=5&&c.iron_ship&&(e*=.95**c.iron_ship),e}function Vt(e){if(t.space.swarm_plant){let a=t.tech.swarm?.88:.94;t.tech.swarm>=3&&(a-=u/100),a<.05&&(a=.05),e*=a**t.space.swarm_plant.count}return e}function Jt(e,a,r){return r=r||{},"heavy"===t.race.universe&&(e*=1.25+.5*nc("heavy")),t.race.truepath&&(e*=a?2.5:1.25),t.city.mass_driver&&i.mass_driver?e*=(t.race.truepath?.94:.95)**i.mass_driver:r.mass_driver&&(e*=.95**r.mass_driver),t.stats.achieve.heavyweight&&(e*=.96**t.stats.achieve.heavyweight.l),t.city.ptrait.includes("dense")&&(e*=Si.dense.vars()[2]),t.race.cataclysm&&(e*=.2),t.race.heavy&&(e*=1+ui.heavy.vars()[0]/100),Tc("launch_day")&&(e*=.95),e}function Yt(e){return"heavy"===t.race.universe&&(e*=1.2+.3*nc("heavy")),t.stats.achieve.heavyweight&&(e*=.96**t.stats.achieve.heavyweight.l),t.race.heavy&&(e*=1+ui.heavy.vars()[0]/100),Tc("launch_day")&&(e*=.95),e}function Xt(){let e={red:di[t.race.species].solar.red,hell:di[t.race.species].solar.hell,gas:di[t.race.species].solar.gas,gas_moon:di[t.race.species].solar.gas_moon,dwarf:di[t.race.species].solar.dwarf,titan:_i[di[t.race.species].type].solar.titan,enceladus:_i[di[t.race.species].type].solar.enceladus,triton:_i[di[t.race.species].type].solar.triton,eris:_i[di[t.race.species].type].solar.eris};if("custom"===t.race.species)for(let a of["titan","enceladus","triton","eris"])t.custom.race0.hasOwnProperty(a)&&(e[a]=t.custom.race0[a]);return e}const ea=["l","h","a","e","m","mg"],ta={standard:{name:F("universe_standard"),desc:F("universe_standard_desc"),effect:F("universe_standard_effect")},heavy:{name:F("universe_heavy"),desc:F("universe_heavy_desc"),effect:F("universe_heavy_effect",[5])},antimatter:{name:F("universe_antimatter"),desc:F("universe_antimatter_desc"),effect:F("universe_antimatter_effect")},evil:{name:F("universe_evil"),desc:F("universe_evil_desc"),effect:F("universe_evil_effect")},micro:{name:F("universe_micro"),desc:F("universe_micro_desc"),effect:F("universe_micro_effect",[75])},magic:{name:F("universe_magic"),desc:F("universe_magic_desc"),effect:F("universe_magic_effect")}};function aa(){let e=[];if(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=4&&t.custom.hasOwnProperty("planet")&&Object.keys(ta).forEach((function(a){let r=Yc(a);t.custom.planet.hasOwnProperty(r)&&t.custom.planet[r].s&&e.push(`${r}:s`)})),t.race.geck&&t.race.geck>0){let e=$(`
    ${F("gecks_remaining")}: {{ geck }}
    `);$("#evolution").append(e),sc({el:"#geck",data:t.race})}if(0===t.race.probes)bs({custom:e});else{let a=!1;for(let r=0;r'),s={ascended:{},technophobe:t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l?t.stats.achieve.technophobe.l:0};if(a?a.append(r):$("#city").append(r),r.append(`

    ${F("genelab_title")}

    - ${F("genelab_genes")} {{ g.genes }} - ${F("trait_untapped_name")}: {{ g.genes | untapped }}
    `),a){r.append(`\n
    ${F("achieve_ascended_name")}
    \n `);let e=$("
    ");r.append(e),Object.keys(ta).forEach((function(a){s.ascended[a]=t.stats.achieve.ascended&&t.stats.achieve.ascended.hasOwnProperty(Yc(a))?t.stats.achieve.ascended[Yc(a)]:0,e.append(`\n
    ${F("universe_"+a)}
    \n `)})),r.append(`\n
    ${F("achieve_technophobe_name")}
    \n
    \n
    \n
    \n `)}let i=$(`
    ${F("genelab_name")}
    ${F("genelab_entity")}
    ${F("genelab_home")}
    ${F("genelab_desc")}
    `);r.append(i);let c=$(`
    \n
    ${F("genelab_red")}
    \n
    ${F("genelab_hell")}
    \n
    ${F("genelab_gas")}
    \n
    ${F("genelab_gas_moon")}
    \n
    ${F("genelab_dwarf")}
    `);r.append(c);let o=$(`
    \n
    ${F("genelab_titan")}
    \n
    ${F("genelab_enceladus")}
    \n
    ${F("genelab_triton")}
    \n
    ${F("genelab_eris")}
    `);r.append(o);let n=$('
    ');r.append(n);let l=!1,u=`
    ${F("genelab_genus")}
    ",n.append($(u));let d=`
    ${F("genelab_traits")}
    ",n.append($(d));let h=`\n
    \n \n
    \n
    \n
    \n \n \n \n
    \n
    \n {{ err.msg }}\n
    \n `;a||(h+=`\n
    \n \n
    \n `),r.append(h);var g=t.hasOwnProperty("custom")&&t.custom.hasOwnProperty("race0")?{name:t.custom.race0.name,desc:t.custom.race0.desc,entity:t.custom.race0.entity,home:t.custom.race0.home,red:t.custom.race0.red,hell:t.custom.race0.hell,gas:t.custom.race0.gas,gas_moon:t.custom.race0.gas_moon,dwarf:t.custom.race0.dwarf,titan:t.custom.race0.titan||Xt().titan,enceladus:t.custom.race0.enceladus||Xt().enceladus,triton:t.custom.race0.triton||Xt().triton,eris:t.custom.race0.eris||Xt().eris,genes:0,genus:t.custom.race0.genus,traitlist:t.custom.race0.traits}:{name:"Zombie",desc:"Zombies aren't so much a species as they are the shambling remains of a race who succumbed to a nightmarish virus. Yet somehow they continue to drone on.",entity:"rotting bipedal creatures",home:"Grave",red:"Brains",hell:"Rigor Mortis",gas:"Decompose",gas_moon:"Bones",dwarf:"Double Tap",titan:"Necromancer",enceladus:"Skeleton",triton:"Rot",eris:"Zombieland",genes:10,genus:l,traitlist:[]};for(let e=g.traitlist.length-1;e>=0;e--)ui.hasOwnProperty(g.traitlist[e])&&"major"===ui[g.traitlist[e]].type||g.traitlist.splice(e,1);g.genes=Sc(g,!!a&&s);let f={msg:""};sc({el:"#celestialLab",data:{g,w:s,err:f},methods:{val(e){"technophobe"===e?s.technophobe<0?s.technophobe=0:s.technophobe>5&&(s.technophobe=5):s.ascended[e]<0?s.ascended[e]=0:s.ascended[e]>5&&(s.ascended[e]=5)},geneEdit(){g.genes=Sc(g,!!a&&s)},setRace(){Sc(g)>=0&&g.name.length>0&&g.desc.length>0&&g.entity.length>0&&g.home.length>0&&g.red.length>0&&g.hell.length>0&&g.gas.length>0&&g.gas_moon.length>0&&g.dwarf.length>0&&(t.custom.race0={name:g.name,desc:g.desc,entity:g.entity,home:g.home,red:g.red,hell:g.hell,gas:g.gas,gas_moon:g.gas_moon,dwarf:g.dwarf,titan:g.titan,enceladus:g.enceladus,triton:g.triton,eris:g.eris,genus:g.genus,traits:g.traitlist},function(){O(),Zi("reset",{end:"ascend"});let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=t.city.geology,n=mc("ascend");t.stats.ascend++,Fc(),t.prestige.Phage.count+=n.phage,t.stats.phage+=n.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=n.plasmid,t.stats.antiplasmid+=n.plasmid):(t.prestige.Plasmid.count+=n.plasmid,t.stats.plasmid+=n.plasmid),t.prestige.Harmony.count=parseFloat((t.prestige.Harmony.count+n.harmony).toFixed(2)),t.stats.harmony=parseFloat((t.stats.harmony+n.harmony).toFixed(2)),c.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),void 0===t.tech.world_control&&Xc("cult_of_personality");let l=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0&&l++})),l>=4&&Xc("miners_dream"),t.galaxy.hasOwnProperty("dreadnought")&&0!==t.galaxy.dreadnought.count||Xc("dreaded"),t.race.modified||"synth"!==t.race.species&&"nano"!==t.race.species||!t.race.emfield||eo("digital_ascension"),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),so();let u=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!0},d>0&&(t.race.corruption=d),u&&(t.race.srace=u),Object.keys(o).forEach((function(e){o[e]+=.02})),Q({orbit:s,biome:i,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}())},allowed:e=>!("synthetic"===g.genus||!["deconstructor","imitation"].includes(e)||(g.traitlist.includes(e)&&g.traitlist.splice(g.traitlist.indexOf(e),1),0)),reset(){g.name="",g.desc="",g.entity="",g.home="",g.red="",g.hell="",g.gas="",g.gas_moon="",g.dwarf="",g.titan="",g.enceladus="",g.triton="",g.eris="",g.genus=l,g.traitlist=[],g.genes=Sc(g,!!a&&s)},customImport(){let e=document.getElementById("customFile").files[0];if(e){let r=new FileReader;r.readAsText(e,"UTF-8"),r.onload=function(r){let i="";try{i=JSON.parse(r.target.result)}catch{return void(f.msg=F("string_pack_error",[e.name]))}let c=!1;if(Object.keys(g).forEach((function(e){i[e]&&typeof g[e]!=typeof i[e]&&(c=!0)})),c)return f.msg=F("string_pack_error",[e.name]),void console.log("format fail");Object.keys(g).forEach((function(e){i[e]&&(g[e]=i[e])})),["name","home","red","hell","gas","gas_moon","dwarf","titan","enceladus","triton","eris"].forEach((function(e){!i[e]&&["titan","enceladus","triton","eris"].includes(e)?g[e]=F(`genus_${g.genus}_solar_${e}`):g[e].length>20&&(g[e]=g[e].substring(0,20))})),g.entity.length>40&&(g.entity=g.entity.substring(0,40)),g.desc.length>255&&(g.desc=g.desc.substring(0,255)),a||t.stats.achieve[`genus_${g.genus}`]&&t.stats.achieve[`genus_${g.genus}`].l>0||(g.genus=l);let o=[];for(let e=0;e{const r=document.createElement("a"),s=new Blob([e],{type:"text/plain"});r.href=URL.createObjectURL(s),r.download=t,r.click(),URL.revokeObjectURL(r.href)})(JSON.stringify(g,null,4),`evolve-custom-${g.name}.txt`)}},filters:{cost(e){if(ui[e].val>=0){let r=2;a?r+=s.technophobe:t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1&&(r+=t.stats.achieve.technophobe.l);let i=ui[e].val,c=0;for(let e=0;e=0&&c++;return g.traitlist.includes(e)&&c--,c>r&&(i+=c-r),i}return ui[e].val},untapped:e=>`+${e>0?+(100*(e/(e+20)/10+24e-5)).toFixed(3):0}%`}}),Object.keys(li).forEach((function(e){t.stats.achieve[`genus_${e}`]&&t.stats.achieve[`genus_${e}`].l>0&&Ti(`celestialLabgenusSelection${e}`,(function(){let t=$(`
    ${F(`genelab_genus_${e}_desc`)}
    `);return Object.keys(li[e]).forEach((function(e){if(ui[e]){let a=$("
    ");Hc(a,e,{trank:1}),t.append(a)}})),t}),{elm:`#celestialLab .genus_selection .${e}`,classes:"w30",wide:!0})})),Object.keys(p).sort().forEach((function(e){ui.hasOwnProperty(e)&&"major"===ui[e].type&&Ti(`celestialLabtraitSelection${e}`,(function(){let t=$("
    ");return Hc(t,e,{trank:1}),t}),{elm:`#celestialLab .trait_selection .t${e}`,classes:"w30",wide:!0})}))}function sa(a){a||t.race.noexport||(M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),Xc(`biome_${t.city.biome}`),Xc(`genus_${di[t.race.species].type}`),Xc("lamentis"),"junker"===t.race.species&&eo("the_misery"),t.race.noexport="Planet",rc($("#city")),t.settings.showCity=!0,t.settings.showCivic=!1,t.settings.showResearch=!1,t.settings.showResources=!1,t.settings.showGenetics=!1,t.settings.showSpace=!1,t.settings.showDeep=!1,t.settings.showGalactic=!1,t.settings.showPortal=!1,t.settings.spaceTabs=0);let r=$('
    '),s={ascended:{},lamentis:t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l?t.stats.achieve.lamentis.l:0};a?a.append(r):$("#city").append(r),r.append(`

    ${F("planetlab_title")}

    - ${F("planetlab_points")} {{ p.pts }}
    `);let i=$('
    ');r.append(i);let c=!1,o=`
    ${F("wiki_planet_biome")}
    ",i.append($(o));let n=`
    ${F("wiki_planet_trait")}
    ",i.append($(n));let l={},u=["Copper","Iron","Aluminium","Coal","Oil","Titanium","Uranium"];t.stats.achieve.whitehole&&u.push("Iridium");let d=`
    ${F("planetlab_res")}
    ",i.append($(d));let _={biome:c,pts:0,traitlist:[],geology:l,orbit:t.city.calendar.orbit};if(t.custom.hasOwnProperty("planet")){let e=Yc();if(t.custom.planet.hasOwnProperty(e)){let a="s";t.custom.planet[e][a]&&(_=zc(t.custom.planet[e][a]),_.orbit=t.city.calendar.orbit,u.forEach((function(e){_.geology.hasOwnProperty(e)?_.geology[e]*=100:_.geology[e]=0})))}}_.pts=ia(_);let p=`
    \n
    \n \n
    \n `;a||(p+=`\n
    \n \n
    \n `),p+="
    ",r.append(p),sc({el:"#celestialLab",data:{p:_,w:s},methods:{pEdit(){_.pts=ia(_)},setPlanet(){if(ia(_)>=0){Object.keys(_.geology).forEach((function(e){0===_.geology[e]?delete _.geology[e]:_.geology[e]/=100})),t.custom.hasOwnProperty("planet")||(t.custom.planet={});let a=Yc();t.custom.planet.hasOwnProperty(a)||(t.custom.planet[a]={s:!1});let r="s";t.custom.planet[a][r]=zc(_),delete t.custom.planet[a][r].pts,function(a){O(),Zi("reset",{end:"terraform"});let r=t.race.species,s=t.race.gods,i=t.city.calendar.orbit,c=a.biome,o=a.traitlist,n=a.geology,l=mc("terraform");t.stats.terraform++,Fc(),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Harmony.count=parseFloat((t.prestige.Harmony.count+l.harmony).toFixed(2)),t.stats.harmony=parseFloat((t.stats.harmony+l.harmony).toFixed(2)),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),void 0===t.tech.world_control&&Xc("cult_of_personality");let u=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0&&u++})),u>=4&&Xc("miners_dream"),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),so();let d=!!t.race.hasOwnProperty("srace")&&t.race.srace,_=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:r,old_gods:s,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended,rejuvenated:!0},_>0&&(t.race.corruption=_),d&&(t.race.srace=d),Q({orbit:i,biome:c,ptrait:o,geology:n}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(_)}},reset(){_.traitlist=[],Object.keys(_.geology).forEach((function(e){_.geology[e]=0})),_.pts=ia(_)},less(e){_.geology[e]-=y(),_.geology[e]<-20&&(_.geology[e]=-20)},more(e){_.geology[e]+=y();let a=30;t.stats.achieve.whitehole&&(a+=5*t.stats.achieve.whitehole.l),"eden"===_.biome&&(a+=5),_.geology[e]>a&&(_.geology[e]=a)}},filters:{res:e=>_.geology[e]}})}function ia(e,a){let r=("eden"===e.biome?0:10)+(t.stats.achieve.lamentis?10*t.stats.achieve.lamentis.l:0);t.race.truepath&&(r*=2),r-=e.traitlist.length**3;let s=0;return Object.keys(e.geology).forEach((function(t){0!==e.geology[t]&&(r-=e.geology[t],s++)})),s>3&&(r-=(s-3)**2),r}const ca={unemployed:function(e){let a=F("job_unemployed_desc");return"unemployed"!==t.civic.d_job||e||(a=a+" "+F("job_default",[F("job_unemployed")])),a},hunter:function(e){let a=F("job_hunter_desc",[t.resource.Food.name]);return t.race.unfathomable&&(a=F("job_eld_hunter_desc")),t.race.artifical?a=t.race.soul_eater?F("job_art_demon_hunter_desc",[t.resource.Furs.name,t.resource.Lumber.name]):F("job_art_hunter_desc",[t.resource.Furs.name]):t.race.soul_eater&&"wendigo"!==t.race.species&&(a=F(t.race.evil?"job_evil_hunter_desc":"job_not_evil_hunter_desc",[t.resource.Food.name,t.resource.Lumber.name,t.resource.Furs.name])),"hunter"!==t.civic.d_job||e||(a=a+" "+F("job_default",[t.race.unfathomable?F("job_raider"):F("job_hunter")])),a},forager:function(e){let a=F("job_forager_desc");return"forager"!==t.civic.d_job||e||(a=a+" "+F("job_default",[F("job_forager")])),a},farmer:function(e){let a=+pa(!0,e).toFixed(2),r=+pa(!1,e).toFixed(2);e||(a=+na(a,"farmer").toFixed(2),r=+na(r,"farmer").toFixed(2));let s=t.race.high_pop&&!e?F("job_farmer_desc_hp",[a,t.resource.Food.name,la(1),r,la(1)*t.city.farm.count]):F("job_farmer_desc",[a,t.resource.Food.name,t.city.farm.count,r]);return"farmer"!==t.civic.d_job||e||(s=s+" "+F("job_default",[F("job_farmer")])),s},lumberjack:function(e){let a=e&&t.race.servants?t.race.servants.jobs.lumberjack:t.civic.lumberjack.workers,r=t.civic.lumberjack.impact;if(e||(a=+na(a,"lumberjack").toFixed(2),r=+na(r,"lumberjack").toFixed(2)),!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species){let s=1+(t.tech.axe&&t.tech.axe>0?.35*(t.tech.axe-1):0);e||(s*=pi(a,"lumberjack")),"forest"===t.city.biome&&(r*=ji.forest.vars()[0]),"savanna"===t.city.biome&&(r*=ji.savanna.vars()[2]),"desert"===t.city.biome&&(r*=ji.desert.vars()[2]),"swamp"===t.city.biome&&(r*=ji.swamp.vars()[2]),"taiga"===t.city.biome&&(r*=ji.taiga.vars()[0]);let i=F("job_lumberjack_desc",[+(r*s).toFixed(2),t.resource.Lumber.name]);return"lumberjack"!==t.civic.d_job||e||(i=i+" "+F("job_default",[F("job_lumberjack")])),i}{let s=1;e||(s*=pi(a,"lumberjack"));let i=+(r*s).toFixed(2),c=+(r/4*s).toFixed(2),o="wendigo"===t.race.species?F("job_reclaimer_desc2",[i]):F("job_reclaimer_desc",[i,c]);return"lumberjack"!==t.civic.d_job||e||(o=o+" "+F("job_default",[F("job_reclaimer")])),o}},quarry_worker:function(e){let a=e&&t.race.servants?t.race.servants.jobs.quarry_worker:t.civic.quarry_worker.workers,r=t.civic.quarry_worker.impact;e||(a=+na(a,"quarry_worker").toFixed(2),r=+na(r,"quarry_worker").toFixed(2));let s=1+(t.tech.hammer&&t.tech.hammer>0?.4*t.tech.hammer:0);e||(s*=pi(a,"miner")),"desert"===t.city.biome&&(s*=ji.desert.vars()[0]),"swamp"===t.city.biome&&(s*=ji.swamp.vars()[3]),t.tech.explosives&&t.tech.explosives>=2&&(s*=t.tech.explosives>=3?1.75:1.5);let i=+(r*s).toFixed(1),c=t.resource.Aluminium.display?F("job_quarry_worker_desc2",[i,t.resource.Stone.name,t.resource.Aluminium.name]):F("job_quarry_worker_desc1",[i,t.resource.Stone.name]);return t.race.smoldering&&(c=c+" "+F("job_quarry_worker_smoldering",[t.resource.Chrysotile.name])),"quarry_worker"!==t.civic.d_job||e||(c=c+" "+F("job_default",[F("job_quarry_worker")])),c},crystal_miner:function(e){let a=e&&t.race.servants?t.race.servants.jobs.crystal_miner:t.civic.crystal_miner.workers,r=t.civic.crystal_miner.impact,s=1;e||(a=+na(a,"crystal_miner").toFixed(2),r=+na(r,"crystal_miner").toFixed(2),s*=pi(a,"miner"));let i=F("job_crystal_miner_desc",[+(r*s).toFixed(2),t.resource.Crystal.name]);return"crystal_miner"!==t.civic.d_job||e||(i=i+" "+F("job_default",[F("job_crystal_miner")])),i},scavenger:function(e){let a=ui.scavenger.vars()[0];t.city.ptrait.includes("trashed")&&t.race.scavenger&&(a*=1+ui.scavenger.vars()[1]/100),t.race.high_pop&&!e&&(a*=ui.high_pop.vars()[1]/100),e||(a=+na(a,"scavenger").toFixed(2));let r=F("job_scavenger_desc",[di[t.race.species].home,a]);return"scavenger"!==t.civic.d_job||e||(r=r+" "+F("job_default",[F("job_scavenger")])),r},torturer:function(){return F("job_torturer_desc")},miner:function(){return t.tech.mining>=3?t.race.sappy&&t.tech.alumina?F("job_miner_desc2_amber"):F("job_miner_desc2"):F("job_miner_desc1")},coal_miner:function(){return t.tech.uranium?F("job_coal_miner_desc2"):F("job_coal_miner_desc1")},craftsman:function(){return F("job_craftsman_desc")},cement_worker:function(){let e=t.race.high_pop?3/ui.high_pop.vars()[0]:3;"ashland"===t.city.biome&&(e*=ji.ashland.vars()[1]),e=+na(e,"cement_worker").toFixed(2);let a=+na(t.civic.cement_worker.impact,"cement_worker").toFixed(2)*(t.tech.cement>=4?1.2:1)*pi(t.civic.cement_worker.workers,"factory");return"ashland"===t.city.biome&&(a*=ji.ashland.vars()[1]),a=+a.toFixed(2),t.race.sappy?F("job_cement_worker_amber_desc",[a]):F("job_cement_worker_desc",[a,e])},banker:function(){let e=100*+na(t.civic.banker.impact,"banker").toFixed(2);return t.tech.banking>=10&&(e+=2*t.tech.stock_exchange),t.race.truthful&&(e*=1-ui.truthful.vars()[0]/100),"republic"===t.civic.govern.type&&(e*=1.25),t.race.high_pop&&(e*=ui.high_pop.vars()[1]/100),e=+e.toFixed(0),F("job_banker_desc",[e])},entertainer:function(){let e=t.tech.theatre;t.race.musical&&(e+=ui.musical.vars()[0]),t.race.emotionless&&(e*=1-ui.emotionless.vars()[0]/100),t.race.high_pop&&(e*=ui.high_pop.vars()[1]/100),e=+na(e,"entertainer").toFixed(2);let a=t.race.high_pop?ui.high_pop.vars()[1]/100:1;return a=+na(a,"entertainer").toFixed(2),t.tech.superstar?F("job_entertainer_desc2",[e,a]):F("job_entertainer_desc",[+e.toFixed(2)])},priest:function(){let e="";return e="theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display?F("job_priest_desc2"):F("job_priest_desc"),t.tech.cleric&&(e+=` ${F("job_priest_desc3")}`),e},professor:function(){let e=+na(1,"professor"),a=+(t.race.studious?t.civic.professor.impact+ui.studious.vars()[0]:t.civic.professor.impact),r=Pi("elven");return r>0&&(a+=ui.studious.vars(1)[0]*r),e*=a,e*=t.race.pompous?1-ui.pompous.vars()[0]/100:1,e*=pi(t.civic.professor.workers,"science"),t.tech.anthropology&&t.tech.anthropology>=3&&(e*=1+.05*t.city.temple.count),"theocracy"===t.civic.govern.type&&(e*=.75),e=+e.toFixed(2),F("job_professor_desc",[e])},scientist:function(){let e=+na(t.civic.scientist.impact,"scientist").toFixed(2);return e*=pi(t.civic.scientist.workers,"science"),t.tech.science>=6&&t.city.wardenclyffe&&(e*=1+t.civic.professor.workers*t.city.wardenclyffe.on*.01),t.space.satellite&&(e*=1+.01*t.space.satellite.count),"theocracy"===t.civic.govern.type&&(e*=t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?.75:.6:.5),e=+e.toFixed(2),"magic"===t.race.universe?F("job_wizard_desc",[e,+(.025*nc("magic")).toFixed(4)]):F("job_scientist_desc",[e])},colonist:()=>F(t.race.truepath?"job_colonist_desc_tp":"job_colonist_desc",[Xt().red]),titan_colonist:()=>F("job_colonist_desc_tp",[Xt().titan]),space_miner:()=>F("job_space_miner_desc"),hell_surveyor:()=>F("job_hell_surveyor_desc"),archaeologist(){let e=75*(i.arcology||0),a=(ke(t.portal.guard_post.on,"hellArmy",0)+e)/5e3;a=a>1?1:a;let r=25e4;return t.race.high_pop&&(r*=ui.high_pop.vars()[1]/100),F("job_archaeologist_desc",[Math.round(r*a).toLocaleString()])},pit_miner:()=>F("job_pit_miner_desc",[F("tau_planet",[di[t.race.species].home])]),crew:()=>F("job_crew_desc")};function oa(e){e||$("#civics").append($(`

    ${F("civics_jobs")}

    `)),da("unemployed",e,0,0,"warning"),da("hunter",e,0,0),da("forager",e,0,0),da("farmer",e,.82,5),da("lumberjack",e,1,5),da("quarry_worker",e,1,5),da("crystal_miner",e,.1,5),da("scavenger",e,.12,5),da("torturer",e,1,3,"advanced"),da("miner",e,1,4,"advanced"),da("coal_miner",e,.2,4,"advanced"),da("craftsman",e,1,5,"advanced"),da("cement_worker",e,.4,5,"advanced"),da("entertainer",e,1,10,"advanced"),da("priest",e,1,3,"advanced"),da("professor",e,.5,6,"advanced"),da("scientist",e,1,5,"advanced"),da("banker",e,.1,6,"advanced"),da("colonist",e,1,5,"advanced"),da("titan_colonist",e,1,5,"advanced"),da("space_miner",e,1,5,"advanced"),da("hell_surveyor",e,1,1,"advanced"),da("archaeologist",e,1,1,"advanced"),da("pit_miner",e,1,4.5,"advanced"),da("crew",e,1,4,"alert"),e||t.race.start_cataclysm||(ha(),t.race.servants&&_a())}function na(e,a){return t.race.strong&&["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(a)&&(e*=ui.strong.vars()[1]),(t.race.swift||t.race.living_tool)&&["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(a)&&(e*=ui.strong.vars(.25)[1]),t.race.lone_survivor&&(["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(a)?e*=80:["craftsman"].includes(a)?e*=60:["miner","coal_miner","cement_worker","banker","entertainer","priest","pit_miner"].includes(a)?e*=45:["professor","scientist"].includes(a)&&(e*=125)),e}function la(e){return t.race.high_pop?e*ui.high_pop.vars()[0]:e}function ua(e){let a="";a=t.race.unfathomable&&"hunter"===e?F("job_raider"):"magic"===t.race.universe&&"scientist"===e?F("job_wizard"):t.race.truepath&&"colonist"===e?F("job_colonist_tp",[Xt().red]):"titan_colonist"===e?F("job_colonist_tp",[Xt().titan]):"lumberjack"!==e||!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species?F("job_"+e):F("job_reclaimer"),t.civic[e].name=a}function da(e,a,r,s,c){let o=!1;if("servant"===a&&(o=!0,a=!1),t.civic[e]||(t.civic[e]={job:e,display:!1,workers:0,max:0,impact:r}),ua(e),t.civic[e].assigned||(t.civic[e].assigned="craftsman"===e?0:t.civic[e].workers),o||(t.civic[e].stress=s,t.civic[e].impact=r),"craftsman"!==e&&!a){var n=o?"servant-"+e:"civ-"+e,l=$(`
    `),u=o?$('
    '):$(`
    `);if(c&&"unemployed"!==e){let t=$(`

    {{ civic.${e}.name }}

    {{ civic.${e}.workers | adjust('${e}') }} / {{ civic.${e}.max | adjust('${e}') }}
    `);l.append(t)}else{c=c||"info";let t=o?$(`

    {{ civic.${e}.name }}

    {{ sjob.${e} }}
    `):$(``);l.append(t)}if(l.append(u),$(o?"#servants":"#jobs").append(l),"crew"!==e){var d=$(`«`),_=$(`»`);u.append(d),u.append(_)}sc(o?{el:`#${n}`,data:{civic:t.civic,sjob:t.race.servants.jobs},methods:{showJob:e=>t.civic[e].display||"scavenger"===e&&t.race.servants.force_scavenger,add(){let a=y();for(let r=0;rt.race.servants.used;r++)t.race.servants.jobs[e]++,t.race.servants.used++},sub(){let a=y();for(let r=0;r0;r++)t.race.servants.jobs[e]--,t.race.servants.used--}}}:{el:`#${n}`,data:{civic:t.civic},methods:{showJob:e=>t.civic[e].display,add(){let a=y();for(let r=0;r0;r++)t.civic[e].workers++,t.civic[t.civic.d_job].workers--,t.civic[e].assigned=t.civic[e].workers},sub(){let a=y();for(let r=0;r0;r++)t.civic[e].workers--,t.civic[t.civic.d_job].workers++,t.civic[e].assigned=t.civic[e].workers},level:e=>0===t.civic[e].workers?"count has-text-danger":t.civic[e].workers===t.civic[e].max?"count has-text-success":t.civic[e].workers<=t.civic[e].max/3?"count has-text-caution":t.civic[e].workers<=.66*t.civic[e].max?"count has-text-warning":t.civic[e].workerst.civic.d_job===e},filters:{d_state:e=>t.civic.d_job===e?"*":"",event(a){if("unemployed"===e&&t.civic.unemployed.display||"hunter"===e&&!t.civic.unemployed.display){let e=$c(3,14);if(0===a&&e.length>0)return e}return a},adjust:(e,t)=>"titan_colonist"===t&&i.ai_colonist?e+la(i.ai_colonist):e}}),Ti(n,(function(){return ca[e](o)}),{elm:`#${n} .job_label`,classes:"has-background-light has-text-dark"})}}function _a(){if(rc($("#servants")),t.race.servants){var e=$(`

    ${F("civics_servants")}

    {{ s.used }} / {{ s.max }}
    `);$("#servants").append(e),["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].forEach((function(e){da(e,"servant")})),sc({el:"#servantList",data:{s:t.race.servants},methods:{level:()=>0===t.race.servants.used?"count has-text-danger":t.race.servants.used===t.race.servants.max?"count has-text-success":t.race.servants.used<=t.race.servants.max/3?"count has-text-caution":t.race.servants.used<=.66*t.race.servants.max?"count has-text-warning":t.race.servants.used=2?1.15:.65),t.race.living_tool&&!a?r*=1+(t.tech.science&&t.tech.science>0?t.tech.science/5:0):r*=1+(t.tech.hoe&&t.tech.hoe>0?t.tech.hoe/3:0),r*="grassland"===t.city.biome?ji.grassland.vars()[0]:1,r*="savanna"===t.city.biome?ji.savanna.vars()[0]:1,r*="ashland"===t.city.biome?ji.ashland.vars()[0]:1,r*="volcanic"===t.city.biome?ji.volcanic.vars()[0]:1,r*="hellscape"===t.city.biome?ji.hellscape.vars()[0]:1,r*=t.city.ptrait.includes("trashed")?Si.trashed.vars()[0]:1,a||(r*=pi(t.civic.farmer.workers,"farmer")),r*=t.tech.agriculture>=7?1.1:1,r*=t.race.low_light?1-ui.low_light.vars()[0]/100:1,a&&(r*=la(1)),r}function ha(e){if(rc($(e?"#skilledServants":"#foundry")),t.city.foundry&&t.city.foundry.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation){let a=$(e?"#skilledServants":"#foundry"),r=e?"{{ s.sused }} / {{ s.smax }}":"{{ f.crafting }} / {{ c.max }}",s=$(`

    ${F(e?"civics_skilled_servants":"craftsman_assigned")}

    ${r}
    `);a.append(s);let o=Tc("summer"),n=["Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Aerogel","Nanoweave"];e||(n.push("Scarletite"),n.push("Quantium")),o&&!e&&n.push("Thermite");for(let r=0;r');a.append(i);let c,o=$('
    ');c="Scarletite"===s&&t.portal.hasOwnProperty("hell_forge")?$(`

    ${r}

    {{ f.${s} }} / {{ p.on | maxScar }}
    `):"Quantium"===s&&(t.space.hasOwnProperty("zero_g_lab")||t.tauceti.hasOwnProperty("infectious_disease_lab"))?$(`

    ${r}

    {{ f.${s} }} / {{ e.on | maxQuantium }}
    `):$(`

    ${r}

    ${e?`{{ s.sjobs.${s} }}`:`{{ f.${s} }}`}
    `),i.append(c),i.append(o),a.append(i);let n=$(`«`),l=$(`»`);o.append(n),o.append(l)}}let l=t.portal.hasOwnProperty("hell_forge")?{c:t.civic.craftsman,p:t.portal.hell_forge}:{c:t.civic.craftsman,e:t.space.hasOwnProperty("zero_g_lab")||t.tauceti.hasOwnProperty("infectious_disease_lab")?t.tech.isolation?t.tauceti.infectious_disease_lab:t.space.zero_g_lab:{count:0,on:0}};e?l.s=t.race.servants:l.f=t.city.foundry,sc({el:e?"#skilledServants":"#foundry",data:l,methods:{add(a){let r=y(),s=-1;"Scarletite"===a?(s=i.hell_forge||0,t.race.high_pop&&(s*=ui.high_pop.vars()[0])):"Quantium"===a&&(s=t.tech.isolation?Math.min(c.infectious_disease_lab,i.infectious_disease_lab)||0:Math.min(c.zero_g_lab,i.zero_g_lab)||0,t.race.high_pop&&(s*=ui.high_pop.vars()[0]));for(let i=0;i0&&(-1===s||s>t.city.foundry[a])))break;t.civic.craftsman.workers++,t.city.foundry.crafting++,t.city.foundry[a]++,t.civic[t.civic.d_job].workers--}},sub(a){let r=y();for(let s=0;s0))break;t.race.servants.sjobs[a]--,t.race.servants.sused--}else{if(!(t.city.foundry[a]>0))break;t.city.foundry[a]--,t.civic.craftsman.workers--,t.city.foundry.crafting--,t.civic[t.civic.d_job].workers++}},level(){let a=e?t.race.servants.sused:t.civic.craftsman.workers,r=e?t.race.servants.smax:t.civic.craftsman.max;return 0===a?"count has-text-danger":a===r?"count has-text-success":a<=r/3?"count has-text-caution":a<=.66*r?"count has-text-warning":a"),a=t.resource[r].name,s=Xa(r,"auto").multiplier,i=t.genes.crafty?2:1,c=+t.resource[r].diff.toFixed(2),o=+(100*s).toFixed(0);e.append($(`
    ${F("craftsman_hover_bonus",[o.toLocaleString(),a])}
    `)),e.append($(`
    ${F("craftsman_hover_prod",[c.toLocaleString(),a])}
    `));let n=Ya();for(let a=0;a${F("craftsman_hover_cost",[s,t.resource[n[r][a].r].name])}
    `))}return e};br(e?`scraft${r}`:`craft${r}`,r,"auto",a)}}e?Ti("servantFoundry",(function(){return F("civics_skilled_servants_desc")}),{elm:"#skilledServants .foundry",classes:"has-background-light has-text-dark"}):Ti("craftsmenFoundry",(function(){return F("job_craftsman_hover")}),{elm:"#foundry .foundry",classes:"has-background-light has-text-dark"}),t.race.servants&&!e&&t.race.servants.smax>0&&ha(!0)}}const ma={prtl_fortress:{info:{name:F("portal_fortress_name"),desc:F("portal_fortress_desc"),repair(){let e=200;return i.repair_droid&&(e*=.95**i.repair_droid),Math.round(e)}},turret:{id:"portal-turret",title:()=>F(t.tech.turret?t.tech.turret>=2?"portal_turret_title3":"portal_turret_title2":"portal_turret_title1"),desc:()=>`
    ${F(t.tech.turret?t.tech.turret>=2?"portal_turret_title3":"portal_turret_title2":"portal_turret_title1")}
    ${F("requires_power")}
    `,reqs:{portal:2},cost:{Money:e=>Xi("turret",e,35e4,1.28,"portal"),Copper:e=>Xi("turret",e,5e4,1.28,"portal"),Adamantite:e=>Xi("turret",e,8e3,1.28,"portal"),Elerium:e=>Xi("turret",e,15,1.28,"portal"),Nano_Tube:e=>Xi("turret",e,28e3,1.28,"portal")},powered:()=>oc(t.tech.turret?4+t.tech.turret:4),postPower(e){i.turret=t.portal.turret.on,sc({el:"#fort"},"update")},effect(){let e=t.tech.turret?t.tech.turret>=2?70:50:35,a=$(this)[0].powered();return`
    ${F("portal_turret_effect",[e])}
    ${F("minus_power",[a])}
    `},action(){return!!Os($(this)[0])&&(Nt("turret","portal"),xs($(this)[0])&&(i.turret++,sc({el:"#fort"},"update")),!0)}},carport:{id:"portal-carport",title:F("portal_carport_title"),desc:()=>F("portal_carport_desc",[1]),reqs:{portal:2},cost:{Money:e=>Xi("carport",e,25e4,1.3,"portal"),Cement:e=>Xi("carport",e,18e3,1.3,"portal"),Oil:e=>Xi("carport",e,6500,1.3,"portal"),Plywood:e=>Xi("carport",e,8500,1.3,"portal")},repair(){let e=180;return i.repair_droid&&(e*=.92**i.repair_droid),Math.round(e)},effect:()=>`${F("portal_carport_effect",[1])}`,action(){return!!Os($(this)[0])&&(Nt("carport","portal"),t.civic.hell_surveyor.display=!0,t.resource.Infernite.display=!0,t.tech.infernite||(t.tech.infernite=1,ms()),!0)}},war_droid:{id:"portal-war_droid",title:F("portal_war_droid_title"),desc:()=>`
    ${F("portal_war_droid_title")}
    ${F("requires_power")}
    `,reqs:{portal:5},cost:{Money:e=>Xi("war_droid",e,495e3,1.26,"portal"),Neutronium:e=>Xi("war_droid",e,1250,1.26,"portal"),Elerium:e=>Xi("war_droid",e,18,1.26,"portal"),Stanene:e=>Xi("war_droid",e,37500,1.26,"portal"),Soul_Gem:e=>Xi("war_droid",e,1,1.26,"portal")},powered:()=>oc(2),effect(){return`
    ${F("portal_war_droid_effect")}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("war_droid","portal"),xs($(this)[0]),!0)},flair:F("portal_war_droid_flair")},repair_droid:{id:"portal-repair_droid",title:F("portal_repair_droid_title"),desc:()=>`
    ${F("portal_repair_droid_title")}
    ${F("requires_power")}
    `,reqs:{portal:6},cost:{Money:e=>Xi("repair_droid",e,444e3,1.26,"portal"),Iron:e=>Xi("repair_droid",e,88e3,1.26,"portal"),Iridium:e=>Xi("repair_droid",e,17616,1.26,"portal"),Infernite:e=>Xi("repair_droid",e,666,1.26,"portal"),Soul_Gem:e=>Xi("repair_droid",e,1,1.15,"portal")},powered:()=>oc(3),effect(){return`
    ${F("portal_repair_droid_effect",[5])}
    ${F("portal_repair_droid_effect2",[8])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("repair_droid","portal"),xs($(this)[0]),!0)},flair:F("portal_repair_droid_flair")}},prtl_badlands:{info:{name:F("portal_badlands_name"),desc:F("portal_badlands_desc")},war_drone:{id:"portal-war_drone",title:F("portal_war_drone_title"),desc:()=>`
    ${F("portal_war_drone_title")}
    ${F("requires_power")}
    `,reqs:{portal:3},powered:()=>oc(5),cost:{Money:e=>Xi("war_drone",e,65e4,1.28,"portal"),Alloy:e=>Xi("war_drone",e,6e4,1.28,"portal"),Graphene:e=>Xi("war_drone",e,1e5,1.28,"portal"),Elerium:e=>Xi("war_drone",e,25,1.28,"portal"),Soul_Gem:e=>Xi("war_drone",e,1,1.28,"portal")},effect(){return`
    ${F("portal_war_drone_effect")}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("war_drone","portal"),xs($(this)[0]),!0)},flair:F("portal_war_drone_flair")},sensor_drone:{id:"portal-sensor_drone",title:F("portal_sensor_drone_title"),desc:()=>`
    ${F("portal_sensor_drone_title")}
    ${F("requires_power")}
    `,reqs:{infernite:2},powered:()=>oc(3),cost:{Money:e=>Xi("sensor_drone",e,5e5,1.25,"portal"),Polymer:e=>Xi("sensor_drone",e,25e3,1.25,"portal"),Adamantite:e=>Xi("sensor_drone",e,12500,1.25,"portal"),Infernite:e=>Xi("sensor_drone",e,100,1.25,"portal")},effect(){let e=t.tech.infernite>=4?t.tech.infernite>=6?50:20:10,a=t.tech.infernite>=6?2500:1e3,r=t.race.cataclysm?`
    ${F("space_moon_observatory_cata_effect",[2])}
    `:`
    ${F("space_moon_observatory_effect",[2])}
    ${F("portal_sensor_drone_effect2",[2])}
    `,s=t.tech.science>=14?`
    ${F("city_max_knowledge",[a])}
    ${r}`:"";return`
    ${F("portal_sensor_drone_effect",[e])}
    ${s}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("sensor_drone","portal"),xs($(this)[0]),!0)}},attractor:{id:"portal-attractor",title:F("portal_attractor_title"),desc:()=>`
    ${F("portal_attractor_title")}
    ${F("requires_power")}
    `,reqs:{portal:4},powered:()=>oc(3),cost:{Money:e=>Xi("attractor",e,35e4,1.25,"portal"),Aluminium:e=>Xi("attractor",e,175e3,1.25,"portal"),Stanene:e=>Xi("attractor",e,9e4,1.25,"portal")},effect(){return`
    ${F("portal_attractor_effect1")}
    ${F("portal_attractor_effect2",[t.resource.Soul_Gem.name])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("attractor","portal"),xs($(this)[0]),!0)}}},prtl_pit:{info:{name:F("portal_pit_name"),desc:F("portal_pit_desc")},pit_mission:{id:"portal-pit_mission",title:F("portal_pit_mission_title"),desc:F("portal_pit_mission_title"),reqs:{hell_pit:1},grant:["hell_pit",2],queue_complete:()=>t.tech.hell_pit>=2?0:1,cost:{Money:()=>5e6,Helium_3:()=>3e5,Deuterium:()=>2e5},effect:F("portal_pit_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_pit_mission_result"),"info",!1,["progress","hell"]),!0)}},assault_forge:{id:"portal-assault_forge",title:F("portal_assault_forge_title"),desc:F("portal_assault_forge_title"),reqs:{hell_pit:2},grant:["hell_pit",3],queue_complete:()=>t.tech.hell_pit>=3?0:1,cost:{Money:()=>1e7,HellArmy:()=>Math.round(650/ke(1,"hellArmy")),Cement:()=>1e7,Adamantite:()=>125e4,Elerium:()=>2400,Stanene:()=>9e5},effect:F("portal_assault_forge_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_assault_forge_result"),"info",!1,["progress","hell"]),!0)}},soul_forge:{id:"portal-soul_forge",title:F("portal_soul_forge_title"),desc:()=>`
    ${F("portal_soul_forge_desc")}
    ${F("requires_power")}
    `,reqs:{hell_pit:4},queue_complete:()=>1-t.portal.soul_forge.count,powered:()=>oc(30),postPower(e){sc({el:"#fort"},"update")},cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?25e6:0,Graphene:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?15e5:0,Infernite:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?25e3:0,Bolognium:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?1e5:0},effect(e){let a=`
    ${F("portal_soul_forge_effect",[t.resource.Soul_Gem.name])}
    `;if((e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)>=1){let e=t.tech.hell_pit>=6?75e4:1e6;t.tech.hell_pit>=7&&i.soul_attractor>0&&(e*=.97**i.soul_attractor),a+=`
    ${F("portal_soul_forge_effect2",[t.portal.soul_forge?t.portal.soul_forge.kills.toLocaleString():0,Math.round(e).toLocaleString()])}
    `}return`${a}
    ${F("portal_soul_forge_soldiers",[ba()])}, ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!(Os($(this)[0])&&t.portal.soul_forge.count<1)&&(Nt("soul_forge","portal"),xs($(this)[0]),!0)}},gun_emplacement:{id:"portal-gun_emplacement",title:F("portal_gun_emplacement_title"),desc:()=>`
    ${F("portal_gun_emplacement_title")}
    ${F("requires_power")}
    `,reqs:{hell_gun:1},powered:()=>oc(3),cost:{Money:e=>Xi("gun_emplacement",e,4e6,1.25,"portal"),Coal:e=>Xi("gun_emplacement",e,25e4,1.25,"portal"),Steel:e=>Xi("gun_emplacement",e,12e5,1.25,"portal"),Wrought_Iron:e=>Xi("gun_emplacement",e,2e5,1.25,"portal")},effect(){let e=t.tech.hell_gun>=2?2:1,a=t.tech.hell_gun>=2?35:20,r=t.tech.hell_gun>=2?75:40;return`
    ${F("portal_gun_emplacement_effect",[e])}
    ${F("portal_gun_emplacement_effect2",[a,r])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("gun_emplacement","portal"),xs($(this)[0]),!0)}},soul_attractor:{id:"portal-soul_attractor",title:F("portal_soul_attractor_title"),desc:()=>`
    ${F("portal_soul_attractor_title")}
    ${F("requires_power")}
    `,reqs:{hell_pit:5},powered:()=>oc(4),cost:{Money:e=>Xi("soul_attractor",e,12e6,1.25,"portal"),Stone:e=>Xi("soul_attractor",e,23e6,1.25,"portal"),Nano_Tube:e=>Xi("soul_attractor",e,314159,1.25,"portal"),Vitreloy:e=>Xi("soul_attractor",e,1618,1.25,"portal"),Aerogel:e=>Xi("soul_attractor",e,18e4,1.25,"portal")},effect(){let e=t.tech.hell_pit>=7?`
    ${F("portal_soul_attractor_effect2",[3])}
    `:"",a=t.blood.attract?5*t.blood.attract:0;return`
    ${F("portal_soul_attractor_effect",[40+a,120+a])}
    ${e}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("soul_attractor","portal"),xs($(this)[0]),!0)}},soul_capacitor:{id:"portal-soul_capacitor",title:F("portal_soul_capacitor_title"),desc:()=>`
    ${F("portal_soul_capacitor_desc")}
    ${F("requires_power")}
    `,reqs:{forbidden:2},powered:()=>oc(125),queue_complete:()=>40-t.portal.soul_capacitor.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,75e7,1.01,"portal"),Crystal:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,125e4,1.01,"portal"),Adamantite:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,65e5,1.01,"portal"),Infernite:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,1e4,1.01,"portal"),Stanene:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,25e5,1.01,"portal"),Bolognium:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,1e6,1.01,"portal"),Soul_Gem:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,3,1.01,"portal"),Mythril:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,125e4,1.01,"portal")},effect(){let e=t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.ecap:0,a=`
    ${F("portal_soul_capacitor_effect",[(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.energy:0).toLocaleString()])}
    `;return a+=`
    ${F("portal_soul_capacitor_effect2",[e.toLocaleString()])}
    `,a+=`
    ${F("portal_soul_capacitor_effect3",[25e5.toLocaleString()])}
    `,a+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,a},action(){return!!(t.portal.soul_capacitor.count<40&&Os($(this)[0]))&&(t.portal.soul_capacitor.count++,xs($(this)[0]),!0)},postPower(){Ps($(this)[0],"portal","soul_capacitor")}},absorption_chamber:{id:"portal-absorption_chamber",title:F("portal_absorption_chamber_title"),desc:e=>!t.interstellar.hasOwnProperty("absorption_chamber")||t.portal.absorption_chamber.count<100||e?`
    ${F("portal_absorption_chamber_title")}
    ${F("requires_segmemts",[100])}
    `:`
    ${F("portal_absorption_chamber_title")}
    `,reqs:{forbidden:3},queue_size:5,queue_complete:()=>100-t.portal.absorption_chamber.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e6:0,Alloy:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e4:0,Neutronium:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?1e3:0,Orichalcum:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?25e4:0,Nanoweave:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0);if(a<100){let e=100-a;return`
    ${F("portal_absorption_chamber_incomplete")}
    ${F("space_dwarf_collider_effect2",[e])}
    `}if(5===t.tech.forbidden)return`
    ${F("portal_absorption_chamber_effect_eld",[1e8.toLocaleString()])}
    ${F("tech_demonic_infusion_effect2",[mc("descend").artifact])}
    `;{let e=Ft();return`
    ${F("portal_absorption_chamber_effect",[1e8.toLocaleString()])}
    ${e}
    `}},action(){if(Os($(this)[0])){if(t.portal.absorption_chamber.count<100)return Nt("absorption_chamber","portal"),t.portal.absorption_chamber.count>=100&&(t.tech.forbidden=4),!0;if(t.portal.soul_capacitor.energy>=1e8)return 5===t.tech.forbidden?W():ra(),!0}return!1}}},prtl_ruins:{info:{name:F("portal_ruins_name"),desc:F("portal_ruins_desc"),support:"guard_post",prop(){let e=` - ${F("portal_ruins_security")}: {{ on | filter('army') }}`;return e+=` - ${F("portal_ruins_supressed")}: {{ on | filter('sup') }}`,e},filter(e,t){let a=Oa("ruins");switch(t){case"army":return Math.round(a.rating);case"sup":return+(100*a.supress).toFixed(2)+"%"}}},ruins_mission:{id:"portal-ruins_mission",title:F("portal_ruins_mission_title"),desc:F("portal_ruins_mission_title"),reqs:{hell_ruins:1},grant:["hell_ruins",2],queue_complete:()=>t.tech.hell_ruins>=2?0:1,cost:{Money:()=>1e8,Oil:()=>5e5,Helium_3:()=>5e5},effect:F("portal_ruins_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_ruins_mission_result"),"info",!1,["progress","hell"]),t.portal.vault={count:0},t.portal.stonehedge={count:0},t.portal.archaeology={count:0,on:0},!0)}},guard_post:{id:"portal-guard_post",title:F("portal_guard_post_title"),desc:()=>`
    ${F("portal_guard_post_title")}
    ${F("requires_soldiers")}
    ${F("requires_power")}
    `,reqs:{hell_ruins:2},cost:{Money:e=>Xi("guard_post",e,8e6,1.06,"portal"),Lumber:e=>Xi("guard_post",e,65e5,1.06,"portal"),Sheet_Metal:e=>Xi("guard_post",e,3e5,1.06,"portal")},powered:()=>oc(5),support:()=>1,effect(){let e=t.race.holy?1+ui.holy.vars()[1]/100:1,a=Pi("unicorn");return a>0&&(e*=1+ui.holy.vars(1)[1]/100*a),`
    ${F("portal_guard_post_effect1",[Math.round(e*ke(la(1),"hellArmy",0))])}
    ${F("portal_guard_post_effect2",[la(1),$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("guard_post","portal"),t.portal.guard_post.on++,!0)},postPower(){sc({el:"#srprtl_ruins"},"update"),sc({el:"#srprtl_gate"},"update")}},vault:{id:"portal-vault",title:F("portal_vault_title"),desc:F("portal_vault_title"),reqs:{hell_ruins:2,hell_vault:1},condition:()=>!(t.portal.vault.count>=2),queue_complete:()=>2-t.portal.vault.count,cost:{Soul_Gem:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===0?100:0,Money:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?25e7:0,Adamantite:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?125e5:0,Orichalcum:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?3e7:0},effect:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)<1?F("portal_vault_effect",[100]):F("portal_vault_effect2"),action(){return!!(t.portal.vault.count<2&&Os($(this)[0]))&&(Nt("vault","portal"),2===t.portal.vault.count&&(t.tech.hell_ruins=3,t.resource.Codex.display=!0,t.resource.Codex.amount=1,Di(F("portal_vault_result"),"info",!1,["progress","hell"])),!0)},post(){2===t.portal.vault.count&&(ms(),$a(),Ei())}},archaeology:{id:"portal-archaeology",title:F("portal_archaeology_title"),desc:()=>`
    ${F("portal_archaeology_title")}
    ${F("requires_security")}
    ${F("requires_power")}
    `,reqs:{hell_ruins:2},cost:{Money:e=>Xi("archaeology",e,1e8,1.25,"portal"),Titanium:e=>Xi("archaeology",e,375e4,1.25,"portal"),Mythril:e=>Xi("archaeology",e,125e4,1.25,"portal")},powered:()=>oc(8),effect(){return`
    ${F("portal_archaeology_effect",[la(2)])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){if(Os($(this)[0])){if(Nt("archaeology","portal"),t.civic.archaeologist.display=!0,xs($(this)[0])&&t.civic[t.civic.d_job].workers>0){let e=t.civic[t.civic.d_job].workers-la(2)<0?t.civic[t.civic.d_job].workers:la(2);t.civic[t.civic.d_job].workers-=e,t.civic.archaeologist.workers+=e}return!0}return!1}},arcology:{id:"portal-arcology",title:F("portal_arcology_title"),desc:()=>`
    ${F("portal_arcology_title")}
    ${F("requires_security")}
    ${F("requires_power")}
    `,reqs:{housing:4},cost:{Money:e=>Xi("arcology",e,18e7,1.22,"portal"),Graphene:e=>Xi("arcology",e,75e5,1.22,"portal"),Bolognium:e=>Xi("arcology",e,28e5,1.22,"portal"),Orichalcum:e=>Xi("arcology",e,55e5,1.22,"portal"),Nanoweave:e=>Xi("arcology",e,65e4,1.22,"portal"),Horseshoe:()=>t.race.hooved?13:0},powered:()=>oc(25),effect(){let e=Oa("ruins"),t=Lr(8*Hs()*e.supress);t=+t.toFixed(0);let a=10*Math.round(u),r=`
    ${F("plus_max_resource",[a,F("resource_Crates_name")])}
    ${F("plus_max_resource",[a,F("resource_Containers_name")])}
    `;return`
    ${F("plus_max_resource",[`$${t.toLocaleString()}`,F("resource_Money_name")])}
    ${F("plus_max_citizens",[$(this)[0].citizens()])}
    ${F("plus_max_resource",[la(5),F("civics_garrison_soldiers")])}
    ${F("portal_guard_post_effect1",[75])}
    ${r}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("arcology","portal"),xs($(this)[0])&&(t.resource[t.race.species].max+=8),!0)},post(){sc({el:"#srprtl_ruins"},"update"),ms()},postPower(){sc({el:"#srprtl_ruins"},"update"),sc({el:"#srprtl_gate"},"update")},citizens(){let e=8;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},hell_forge:{id:"portal-hell_forge",title:F("portal_hell_forge_title"),desc:()=>`
    ${F("portal_hell_forge_title")}
    ${F("requires_security")}
    ${F("requires_power")}
    `,reqs:{scarletite:1},cost:{Money:e=>Xi("hell_forge",e,25e7,1.15,"portal"),Coal:e=>Xi("hell_forge",e,165e4,1.22,"portal"),Steel:e=>Xi("hell_forge",e,38e5,1.22,"portal"),Iridium:e=>Xi("hell_forge",e,12e5,1.22,"portal"),Neutronium:e=>Xi("hell_forge",e,28e4,1.22,"portal"),Soul_Gem:e=>Xi("hell_forge",e,5,1.22,"portal")},powered:()=>oc(12),special:!0,effect(){let e=+(75*Oa("ruins").supress).toFixed(1),a=t.tech.inferno_power?`
    ${F("portal_hell_forge_effect2",[10,F("portal_inferno_power_title")])}
    `:"";return`
    ${F("portal_hell_forge_effect",[la(1)])}
    ${a}
    ${F("interstellar_stellar_forge_effect3",[3])}
    ${F("interstellar_stellar_forge_effect",[e])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("hell_forge","portal"),xs($(this)[0])&&(t.city.smelter.cap+=3,t.city.smelter.Oil+=3,t.city.smelter.Iron+=3),!0)},post(){ha()},postPower(e){if(!e&&t.portal.hell_forge.on`
    ${F("portal_inferno_power_title")}
    `,reqs:{inferno_power:1},cost:{Money:e=>Xi("inferno_power",e,275e6,1.16,"portal"),Neutronium:e=>Xi("inferno_power",e,375e4,1.18,"portal"),Stanene:e=>Xi("inferno_power",e,12e6,1.18,"portal"),Bolognium:e=>Xi("inferno_power",e,8e6,1.18,"portal")},powered(){let e=20;return i.hasOwnProperty("hell_forge")&&(e+=10*i.hell_forge),cc(-e)},fuel:{Infernite:5,Coal:100,Oil:80},effect(){let e=$(this)[0].fuel;return`
    ${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
    ${F("portal_inferno_power_effect",[e.Infernite,t.resource.Infernite.name,e.Coal,t.resource.Coal.name,e.Oil,t.resource.Oil.name])}
    `},action(){return!!Os($(this)[0])&&(Nt("inferno_power","portal"),t.portal.inferno_power.on++,!0)},post(){sc({el:"#foundry"},"update")}},ancient_pillars:{id:"portal-ancient_pillars",title:F("portal_ancient_pillars_title"),desc:F("portal_ancient_pillars_desc"),reqs:{hell_ruins:2},queue_complete:()=>t.tech.pillars&&1===t.tech.pillars&&"micro"!==t.race.universe?1:0,cost:{Harmony:e=>void 0!==e?e+Object.keys(t.pillars).lengthObject.keys(di).length-1,on:()=>Object.keys(t.pillars).length,effect(e){let a=(e||0)+Object.keys(t.pillars).length;return a>=1?`
    ${F("portal_ancient_pillars_effect2",[Object.keys(di).length-1,a])}
    `:`
    ${F("portal_ancient_pillars_effect",[Object.keys(di).length-1])}
    `},action(){return!(!t.tech.pillars||1!==t.tech.pillars||"micro"===t.race.universe||!Os($(this)[0])||(t.pillars[t.race.species]=ro(),t.tech.pillars=2,Lr(0,!1,!0),_c(!0),fa(!0),Xc("resonance"),sc({el:"#portal-ancient_pillars"},"update"),0))}}},prtl_gate:{info:{name:F("portal_gate_name"),desc:()=>`${F("portal_gate_desc")} ${F(t.tech.wtower&&t.tech.etower?"portal_gate_open":"portal_gate_closed")}`,support:"guard_post",hide_support:!0,prop(){let e=` - ${F("portal_ruins_security")}: {{ on | filter('army') }}`;return e+=` - ${F("portal_ruins_supressed")}: {{ on | filter('sup') }}`,e},filter(e,t){let a=Oa("gate");switch(t){case"army":return Math.round(a.rating);case"sup":return+(100*a.supress).toFixed(2)+"%"}}},gate_mission:{id:"portal-gate_mission",title:F("portal_gate_mission_title"),desc:F("portal_gate_mission_title"),reqs:{high_tech:18},grant:["hell_gate",1],queue_complete:()=>t.tech.hell_gate>=1?0:1,cost:{Money:()=>25e7,Knowledge:()=>275e5},effect:F("portal_gate_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_gate_mission_result"),"info",!1,["progress","hell"]),!0)}},west_tower:{id:"portal-west_tower",title:F("portal_west_tower"),desc(e){let a=fa();return!t.portal.hasOwnProperty("west_tower")||t.portal.west_tower.count${F("portal_west_tower")}
    ${F("requires_segmemts",[a])}
    `:`
    ${F("portal_west_tower")}
    `},reqs:{hell_gate:2},queue_size:25,queue_complete:()=>fa()-t.portal.west_tower.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)${F("portal_tower_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    ${F("portal_tower_effect2")}
    `}return F("portal_tower_effect")},action(){return!!(t.portal.west_tower.count=fa()&&(t.tech.wtower=1,t.tech.wtower&&t.tech.etower&&!t.tech.hell_lake&&(t.tech.hell_lake=1,t.settings.portal.lake=!0,t.portal.harbour={count:0,on:0,support:0,s_max:0},Di(F("portal_gate_open"),"info",!1,["progress","hell"]),$a()))}},east_tower:{id:"portal-east_tower",title:F("portal_east_tower"),desc(e){let a=fa();return!t.portal.hasOwnProperty("east_tower")||t.portal.east_tower.count${F("portal_east_tower")}
    ${F("requires_segmemts",[a])}
    `:`
    ${F("portal_east_tower")}
    `},reqs:{hell_gate:2},queue_size:25,queue_complete:()=>fa()-t.portal.east_tower.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)${F("portal_tower_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    ${F("portal_tower_effect2")}
    `}return F("portal_tower_effect")},action(){return!!(t.portal.east_tower.count=fa()&&(t.tech.etower=1,t.tech.wtower&&t.tech.etower&&!t.tech.hell_lake&&(t.tech.hell_lake=1,t.settings.portal.lake=!0,t.portal.harbour={count:0,on:0,support:0,s_max:0},Di(F("portal_gate_open"),"info",!1,["progress","hell"]),$a()))}},gate_turret:{id:"portal-gate_turret",title:F("portal_gate_turret_title"),desc:()=>`
    ${F("portal_gate_turret_title")}
    ${F("requires_power")}
    `,reqs:{hell_gate:3},powered:()=>oc(6),cost:{Money:e=>Xi("gate_turret",e,375e4,1.22,"portal"),Iron:e=>Xi("gate_turret",e,425e4,1.22,"portal"),Elerium:e=>Xi("gate_turret",e,275,1.22,"portal"),Stanene:e=>Xi("gate_turret",e,85e4,1.22,"portal")},effect(){let e=100;t.race.holy&&(e*=1+ui.holy.vars()[1]/100);let a=Pi("unicorn");a>0&&(e*=1+ui.holy.vars(1)[1]/100*a);let r=t.tech.hell_gun>=2?65:40,s=t.tech.hell_gun>=2?100:60;return`
    ${F("portal_gate_turret_effect",[Math.round(e)])}
    ${F("portal_gate_turret_effect2",[r,s])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("gate_turret","portal"),xs($(this)[0]),!0)},postPower(){sc({el:"#srprtl_gate"},"update")}},infernite_mine:{id:"portal-infernite_mine",title:F("portal_infernite_mine_title"),desc:()=>`
    ${F("portal_infernite_mine_title")}
    ${F("requires_security")}
    ${F("requires_power")}
    `,reqs:{hell_gate:4},powered:()=>oc(5),powerBalancer:()=>[{r:"Infernite",k:"lpmod"}],cost:{Money:e=>Xi("infernite_mine",e,75e6,1.26,"portal"),Alloy:e=>Xi("infernite_mine",e,245e4,1.26,"portal"),Orichalcum:e=>Xi("infernite_mine",e,165e4,1.26,"portal"),Wrought_Iron:e=>Xi("infernite_mine",e,68e4,1.26,"portal")},effect(){return`
    ${F("portal_infernite_mine_effect",[+Pe("infernite_mine").toFixed(3)])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("infernite_mine","portal"),xs($(this)[0]),!0)}}},prtl_lake:{info:{name:F("portal_lake_name"),desc:F("portal_lake_desc"),support:"harbour"},lake_mission:{id:"portal-lake_mission",title:F("portal_lake_mission_title"),desc:F("portal_lake_mission_title"),reqs:{hell_lake:1},grant:["hell_lake",2],queue_complete:()=>t.tech.hell_lake>=2?0:1,cost:{Money:()=>5e8,Oil:()=>75e4,Helium_3:()=>6e5},effect:F("portal_lake_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_lake_mission_result"),"info",!1,["progress","hell"]),!0)}},harbour:{id:"portal-harbour",title:F("portal_harbour_title"),desc:()=>`
    ${F("portal_harbour_title")}
    ${F("requires_power")}
    `,reqs:{hell_lake:3},powered:()=>+oc(500*.92**(i.cooling_tower||0)).toFixed(2),support:()=>1,cost:{Money:e=>Xi("harbour",e,225e6,ga(1.18),"portal"),Cement:e=>Xi("harbour",e,5e7,ga(1.18),"portal"),Iridium:e=>Xi("harbour",e,75e5,ga(1.18),"portal"),Infernite:e=>Xi("harbour",e,8e5,ga(1.18),"portal"),Stanene:e=>Xi("harbour",e,175e5,ga(1.18),"portal")},wide:!0,res:()=>["Oil","Alloy","Polymer","Iridium","Helium_3","Deuterium","Neutronium","Adamantite","Infernite","Nano_Tube","Graphene","Stanene","Bolognium","Orichalcum"],val(e){switch(e){case"Oil":return 3e4;case"Alloy":case"Polymer":return 25e4;case"Iridium":return 2e5;case"Helium_3":return 18e3;case"Deuterium":return 12e3;case"Neutronium":return 18e4;case"Adamantite":return 15e4;case"Infernite":return 75e3;case"Nano_Tube":return 75e4;case"Graphene":case"Stanene":return 12e5;case"Bolognium":case"Orichalcum":return 13e4;default:return 0}},effect(){let e='
    ';for(const a of $(this)[0].res())t.resource[a].display&&(e+=`${F("plus_max_resource",[k(+Lr($(this)[0].val(a)).toFixed(0),1),t.resource[a].name])}`);return e+="
    ",`
    ${F("portal_harbour_effect",[1])}
    ${e}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){if(Os($(this)[0])){if(Nt("harbour","portal"),xs($(this)[0]))for(const e of $(this)[0].res())t.resource[e].display&&(t.resource[e].max+=Lr($(this)[0].val(e)));return!0}return!1}},cooling_tower:{id:"portal-cooling_tower",title:F("portal_cooling_tower_title"),desc:()=>`
    ${F("portal_cooling_tower_title")}
    ${F("requires_power")}
    `,reqs:{hell_lake:6},powered:()=>oc(10),cost:{Money:e=>Xi("cooling_tower",e,25e7,1.2,"portal"),Polymer:e=>Xi("cooling_tower",e,12e6,1.2,"portal"),Orichalcum:e=>Xi("cooling_tower",e,85e5,1.2,"portal"),Brick:e=>Xi("cooling_tower",e,25e4,1.2,"portal")},effect(){return`
    ${F("portal_cooling_tower_effect",[8])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("cooling_tower","portal"),xs($(this)[0]),!0)}},bireme:{id:"portal-bireme",title:F("portal_bireme_title"),desc:()=>`
    ${F("portal_bireme_title")}
    ${F("space_support",[F("lake")])}
    `,reqs:{hell_lake:4},powered:()=>oc(1),support:()=>-1,cost:{Money:e=>Xi("bireme",e,19e7,1.24,"portal"),Helium_3:e=>Xi("bireme",e,225e3,1.24,"portal"),Adamantite:e=>Xi("bireme",e,15e6,1.24,"portal"),Nano_Tube:e=>Xi("bireme",e,18e6,1.24,"portal"),Soul_Gem:e=>Xi("bireme",e,10,1.24,"portal"),Scarletite:e=>Xi("bireme",e,125e3,1.24,"portal")},effect(){let e=t.blood.spire&&t.blood.spire>=2?20:15;return`
    ${F("space_used_support",[F("lake")])}
    ${F("portal_bireme_effect",[e])}
    ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
    `},ship:{civ:()=>0,mil:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2},action(){return!!Os($(this)[0])&&(Nt("bireme","portal"),t.portal.harbour.support`
    ${F("portal_transport_title")}
    ${F("space_support",[F("lake")])}
    `,reqs:{hell_lake:5},powered:()=>oc(1),support:()=>-1,cost:{Money:e=>Xi("transport",e,3e8,1.22,"portal"),Oil:e=>Xi("transport",e,18e4,1.22,"portal"),Alloy:e=>Xi("transport",e,18e6,1.22,"portal"),Graphene:e=>Xi("transport",e,125e5,1.22,"portal"),Soul_Gem:e=>Xi("transport",e,5,1.22,"portal"),Scarletite:e=>Xi("transport",e,25e4,1.22,"portal")},effect(){let e=+((t.blood.spire&&t.blood.spire>=2?.8:.85)**(n.bireme||0)*100).toFixed(1);return`
    ${F("space_used_support",[F("lake")])}
    ${F("portal_transport_effect",[5])}
    ${F("portal_transport_effect2",[e])}
    ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
    `},special:!0,sAction(){t.settings.civTabs=4,t.settings.marketTabs=3,t.settings.tabLoad||(Ct("mTabResource"),Ei("portal-transport"))},ship:{civ:()=>t.race.high_pop?3*ui.high_pop.vars()[0]:3,mil:()=>0},action(){return!!Os($(this)[0])&&(Nt("transport","portal"),t.portal.harbour.support` - ${F("portal_spire_supply")}: {{ supply | filter }} / {{ sup_max }} (+{{ diff | filter(2) }}/s)`,filter:(e,t)=>t?+e.toFixed(t):Math.floor(e)},spire_mission:{id:"portal-spire_mission",title:F("portal_spire_mission_title"),desc:F("portal_spire_mission_title"),reqs:{hell_spire:1},grant:["hell_spire",2],queue_complete:()=>t.tech.hell_spire>=2?0:1,cost:{Species:()=>fc(50),Oil:()=>9e5,Helium_3:()=>75e4,Structs:()=>({portal:{bireme:{s:"prtl_lake",count:1,on:1},transport:{s:"prtl_lake",count:1,on:1}}})},effect:F("portal_spire_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_spire_mission_result"),"info",!1,["progress","hell"]),!0)},flair:F("portal_spire_mission_flair")},purifier:{id:"portal-purifier",title:F("portal_purifier_title"),desc:()=>`
    ${F("portal_purifier_desc")}
    ${F("requires_power")}
    `,reqs:{hell_spire:3},cost:{Money:e=>Xi("purifier",e,85e6,ga(1.15),"portal"),Supply:e=>t.portal.purifier&&0===t.portal.purifier.count?100:Xi("purifier",e,4200,ga(1.2),"portal")},powered:()=>oc(125),support:()=>t.tech.b_stone&&t.tech.b_stone>=3?1.25:1,effect(){return`
    ${F("portal_purifier_effect",[$(this)[0].support()])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(Nt("purifier","portal"),xs($(this)[0]),!0)}},port:{id:"portal-port",title:F("portal_port_title"),desc:()=>`
    ${F("portal_port_title")}
    ${F("portal_spire_support")}
    `,reqs:{hell_spire:3},cost:{Money:e=>Xi("port",e,135e6,ga(1.2),"portal"),Supply:e=>t.portal.hasOwnProperty("port")&&0===t.portal.port.count?100:Xi("port",e,6250,ga(1.2),"portal")},powered:()=>oc(1),support:()=>-1,effect(){let e=1e4;return l.base_camp&&(e*=1+.4*l.base_camp),`
    ${F("portal_port_effect1",[$(this)[0].support()])}
    ${F("portal_port_effect2",[Math.round(e)])}
    `},action(){return!!Os($(this)[0])&&(Nt("port","portal"),t.portal.purifier.support`
    ${F("portal_base_camp_title")}
    ${F("portal_spire_support")}
    `,reqs:{hell_spire:4},cost:{Money:e=>Xi("base_camp",e,425e6,ga(1.2),"portal"),Supply:e=>Xi("base_camp",e,5e4,ga(1.2),"portal")},powered:()=>oc(1),support:()=>-1,effect(){return`
    ${F("portal_port_effect1",[$(this)[0].support()])}
    ${F("portal_base_camp_effect",[40])}
    `},action(){return!!Os($(this)[0])&&(Nt("base_camp","portal"),t.portal.purifier.support!t.portal.hasOwnProperty("bridge")||t.portal.bridge.count<10||e?`
    ${F("portal_bridge_title")}
    ${F("requires_segmemts",[10])}
    `:`
    ${F("portal_bridge_title")}
    `,reqs:{hell_spire:5},queue_size:1,queue_complete:()=>10-t.portal.bridge.count,cost:{Species:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?fc(10):0,Money:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?5e8:0,Supply:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?1e5:0},effect(e){let a=(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0);if(a<10){let e=10-a;return`
    ${F("portal_bridge_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    ${F("portal_bridge_effect2")}
    `}return F("portal_bridge_complete")},action(){return!!(t.portal.bridge.count<10&&Os($(this)[0]))&&(Nt("bridge","portal"),t.portal.bridge.count>=10&&(t.portal.sphinx={count:0},t.tech.hell_spire=6,$a()),!0)}},sphinx:{id:"portal-sphinx",title:()=>7===t.tech.hell_spire?F("portal_sphinx_solve"):F("portal_sphinx_title"),desc:F("portal_sphinx_desc"),reqs:{hell_spire:6},queue_complete:()=>8-t.tech.hell_spire,cost:{Knowledge(e){let a=(e||0)+(!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2);return 1===a?5e7:0===a?4e7:0}},effect(e){let a=(e||0)+(!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2);return F(1===a?"portal_sphinx_effect2":2===a?"portal_sphinx_effect3":"portal_sphinx_effect")},action(){if(Os($(this)[0])){if(6===t.tech.hell_spire)return t.tech.hell_spire=7,Di(F("portal_sphinx_msg"),"info",!1,["progress","hell"]),$a(),!0;if(7===t.tech.hell_spire)return t.tech.hell_spire=8,$a(),Di(F("portal_sphinx_answer_msg"),"info",!1,["progress","hell"]),!0}return!1}},bribe_sphinx:{id:"portal-bribe_sphinx",title:F("portal_sphinx_bribe"),desc:F("portal_sphinx_desc"),reqs:{hell_spire:7},condition:()=>!(!t.tech.hell_spire||7!==t.tech.hell_spire||t.tech.sphinx_bribe),cost:{Soul_Gem:()=>250,Supply:()=>5e5},effect:()=>F("portal_sphinx_bribe_effect"),action(){return!(!Os($(this)[0])||7!==t.tech.hell_spire||t.tech.sphinx_bribe||(t.tech.sphinx_bribe=1,t.resource.Codex.display=!0,t.resource.Codex.amount=1,Di(F("portal_sphinx_bribe_msg"),"info",!1,["progress","hell"]),0))},post(){t.tech.sphinx_bribe&&(ms(),$a(),Ei("portal-bribe_sphinx"))}},spire_survey:{id:"portal-spire_survey",title:F("portal_spire_survey_title"),desc:F("portal_spire_survey_title"),reqs:{hell_spire:8},grant:["hell_spire",9],queue_complete:()=>t.tech.hell_spire>=9?0:1,cost:{Oil:()=>12e5,Helium_3:()=>9e5},effect:F("portal_spire_survey_effect"),action(){return!!Os($(this)[0])&&(t.portal.mechbay={count:0,on:0,bay:0,max:0,active:0,scouts:0,mechs:[]},t.portal.spire={count:1,progress:0,boss:"",type:"",status:{}},Ta(),Di(F("portal_spire_survey_msg"),"info",!1,["progress","hell"]),!0)},post(){t.tech.hell_spire&&9===t.tech.hell_spire&&($a(),Ei("portal-spire_survey"))}},mechbay:{id:"portal-mechbay",title:F("portal_mechbay_title"),desc:()=>`
    ${F("portal_mechbay_title")}
    ${F("portal_spire_support")}
    `,reqs:{hell_spire:9},cost:{Money:e=>Xi("mechbay",e,1e8,1.2,"portal"),Supply:e=>Xi("mechbay",e,25e4,1.2,"portal")},powered:()=>oc(1),support:()=>-1,special:!0,sAction(){t.settings.civTabs=2,t.settings.govTabs=4,t.settings.tabLoad||(Ct("mTabCivic"),Ei("portal-mechbay"))},effect(){let e=t.portal.hasOwnProperty("mechbay")?t.portal.mechbay.bay:0,a=t.portal.hasOwnProperty("mechbay")?t.portal.mechbay.max:0;return`
    ${F("portal_port_effect1",[$(this)[0].support()])}
    ${F("portal_mechbay_effect")}
    ${F("portal_mechbay_effect2",[e,a])}
    `},action(){return!!Os($(this)[0])&&(Nt("mechbay","portal"),t.portal.purifier.support0,cost:{},effect(){let e=t.portal.hasOwnProperty("spire")?t.portal.spire.count:0,a=t.portal.hasOwnProperty("spire")?`${F(`portal_spire_type_${t.portal.spire.type}`)}`:"?",r="";t.portal.hasOwnProperty("spire")&&Object.keys(t.portal.spire.status).length>0&&(r=`
    ${F("portal_spire_hazard",[Object.keys(t.portal.spire.status).map((e=>`${F(`portal_spire_status_${e}`)}`)).join(", ")])}
    `);let s=t.portal.hasOwnProperty("spire")?`${+t.portal.spire.progress.toFixed(3)}%`:"0%",i=`
    ${F("portal_spire_effect",[e])}
    ${F("portal_spire_type",[a])}
    ${r}
    ${F("portal_spire_progress",[s])}
    `,c=t.portal.hasOwnProperty("spire")?t.portal.spire.boss:"crazed",o=`
    ${F("portal_spire_mob",[`${F(`portal_mech_boss_${c}`)}`])}
    `,n="???",l="???";if(t.stats.spire){let e=function(e){let t="laser",a="laser";return Object.keys(Ca[e].weapon).forEach((function(r){Ca[e].weapon[r]>Ca[e].weapon[t]&&(t=r),Ca[e].weapon[r]0&&(n=F(`portal_mech_weapon_${e.w}`)),t>=5&&(l=F(`portal_mech_weapon_${e.r}`))}return`
    ${i}
    ${o}
    ${F("portal_spire_mob_weak",[`${n}`])}
    ${F("portal_spire_mob_resist",[`${l}`])}
    `},mscan(){let e=0;return Object.keys(t.stats.spire).forEach((function(a){let r=t.portal.hasOwnProperty("spire")?t.portal.spire.boss:"crazed";t.stats.spire.hasOwnProperty(a)&&t.stats.spire[a].hasOwnProperty(r)&&t.stats.spire[a][r]>e&&(e=t.stats.spire[a][r])})),e},wide:!0,action:()=>!1},waygate:{id:"portal-waygate",title:F("portal_waygate_title"),desc:e=>!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2||e?`
    ${F("portal_waygate_title")}
    ${F("requires_segmemts",[10])}
    `:`
    ${F("portal_waygate_title")}
    `,reqs:{waygate:1},queue_size:1,queue_complete:()=>t.tech.waygate>=2?0:10-t.portal.waygate.count,cost:{Species:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?fc(25):0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?fc(25):0,Money:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?1e9:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?1e9:0,Supply:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?5e5:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?5e5:0,Blood_Stone:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?5:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?5:0},powered:()=>t.portal.hasOwnProperty("waygate")&&t.portal.waygate.count>=10?1:0,power_reqs:{waygate:2},effect(e){let a=(e||0)+(t.tech.waygate&&t.tech.waygate>=2?10:t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0);if(a>=10){let e=t.portal.hasOwnProperty("waygate")?`${+t.portal.waygate.progress.toFixed(3)}%`:"0%";return`
    ${F("portal_waygate_open")}
    ${F("portal_waygate_progress",[e])}
    `}{let e=10-a;return`
    ${F("portal_waygate_effect")}
    ${F("space_dwarf_collider_effect2",[e])}
    `}},action(){return!!(t.portal.waygate.count<10&&t.tech.waygate&&1===t.tech.waygate&&Os($(this)[0]))&&(Nt("waygate","portal"),t.portal.waygate.count>=10&&(t.tech.waygate=2,t.portal.waygate.count=1,$a()),!0)}}}};function ga(e){let a=t.portal.hasOwnProperty("spire")&&t.blood.spire?e-(t.portal.spire.count-1)/2500:e;return a>=1.01?a:1.01}const fa=function(e){return va&&!e||(va=1e3,t.hasOwnProperty("pillars")&&Object.keys(t.pillars).forEach((function(e){t.pillars[e]&&(va-=12)}))),va};var va;function ya(e){let t=Oa("gate");return Math.round(e/(t.supress>.01?t.supress:.01))}function ba(){let e=Math.round(650/ke(1,"hellArmy"));return i.gun_emplacement&&(e-=i.gun_emplacement*(t.tech.hell_gun>=2?2:1),e<0&&(e=0)),e}function wa(){return ma}function $a(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||4!==t.settings.spaceTabs))return;let e=$("#portal");rc(e),e.append($(`

    ${F("tab_portal")}

    `)),!t.tech.portal||t.tech.portal<2||Object.keys(ma).forEach((function(a){let r=a.replace("prtl_","");if(t.settings.portal[`${r}`]){let r="string"==typeof ma[a].info.name?ma[a].info.name:ma[a].info.name(),s="";if(ma[a].info.hasOwnProperty("prop")&&(s=ma[a].info.prop()),ma[a].info.support){let i=ma[a].info.support;ma[a].info.hide_support?e.append(`

    ${r}

    ${s}
    `):e.append(`

    ${r}

    {{ support }}/{{ s_max }}${s}
    `),sc({el:`#sr${a}`,data:t.portal[i],filters:{filter(){return ma[a].info.filter(...arguments)}}})}else e.append(`

    ${r}

    ${s}
    `);Ti(a,(function(){return"string"==typeof ma[a].info.desc?ma[a].info.desc:ma[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),"prtl_fortress"===a&&ka(e,!0),Object.keys(ma[a]).forEach((function(e){"info"!==e&&Gt(ma,a,e)&&fs(ma[a][e],"portal",e)}))}}))}function xa(e){switch(e){case"hostiles":return t.portal.fortress.threat>=2e3?`${F("fortress_threat",[t.portal.fortress.threat])} ${F("fortress_threat_high")}`:t.portal.fortress.threat<1e3?`${F("fortress_threat",[t.portal.fortress.threat])} ${F("fortress_threat_low")}`:`${F("fortress_threat",[t.portal.fortress.threat])} ${F("fortress_threat_medium")}`;case"threatLevel":{let e=t.portal.fortress.threat;return e<1e3?`${F("fortress_threat_level")} ${F("fortress_threat_level1")}`:e<1500?`${F("fortress_threat_level")} ${F("fortress_threat_level2")}`:e>=5e3?`${F("fortress_threat_level")} ${F("fortress_threat_level6")}`:e>=3e3?`${F("fortress_threat_level")} ${F("fortress_threat_level5")}`:e>=2e3?`${F("fortress_threat_level")} ${F("fortress_threat_level4")}`:`${F("fortress_threat_level")} ${F("fortress_threat_level3")}`}case"hireLabel":return F("civics_garrison_hire_mercenary_cost",[Math.round(he("m_cost")).toLocaleString()])}}function ka(e,a){if(!t.settings.tabLoad)switch(t.settings.civTabs){case 1:if(4!==t.settings.spaceTabs)return;break;case 2:if(3!==t.settings.govTabs)return;break;default:return}if(!t.tech.portal||t.tech.portal<2)return;let r=a?"fort":"gFort",s=a?$(`
    `):$("#gFort");a?e.append(s):(s.length>0?rc(s):(s=$(`
    `),e.append(s)),s.append(`

    ${F("portal_fortress_name")}

    `));let c=$("
    ");s.append(c);let o=$(`${F("fortress_defense")} {{ f.garrison | defensive }}`);c.append(o);let n=$(`${F("fortress_spotted")} {{ f.threat }}`);c.append(n);let l=$('{{ f.threat | threat }}');c.append(l);let u=$("
    ");s.append(u),u.append($(`${F("fortress_wall")} {{ f.walls }}%`));let d=$("
    ");s.append(d),d.append($(`${F("fortress_army")}`)),d.append($('«')),d.append($('{{ f.garrison | patrolling }}')),d.append($('»')),d.append($(`${F("fortress_patrol")}`)),d.append($('«')),d.append($('{{ f.patrols }}')),d.append($('»')),d.append($(`${F("fortress_patrol_size")}`)),d.append($('«')),d.append($('{{ f.patrol_size }}')),d.append($('»')),d.append($(``));let _="light"===t.settings.theme?' type="is-light"':' type="is-dark"',p=$("
    ");d.append(p),p.append($(`${F("fortress_patrol_reports")}`)),p.append($(`${F("fortress_surv_reports")}`)),p.append($(`${F("fortress_nocrew")}`)),a&&s.append($(`
    ${F("civics_garrison_training")} - ${F("arpa_to_complete")} {{ g.rate, g.progress | trainTime }} {{ g.progress }}%
    `)),sc({el:`#${r}`,data:{f:t.portal.fortress,g:t.civic.garrison,s:t.settings},methods:{defense:()=>F("fortress_defense"),hostiles:()=>xa("hostiles"),threatLevel:()=>xa("threatLevel"),aNext(){let e=y();t.portal.fortress.garrisont.civic.garrison.workers&&(t.portal.fortress.garrison=t.civic.garrison.workers),t.portal.fortress.assigned=t.portal.fortress.garrison,sc({el:"#garrison"},"update"))},aLast(){let e=y(),a=t.portal.fortress.patrols*t.portal.fortress.patrol_size;i.soul_forge&&(a+=ba()),t.portal.hasOwnProperty("guard_post")&&(a+=la(t.portal.guard_post.on)),t.portal.fortress.garrison>a&&(t.portal.fortress.garrison-=e,t.portal.fortress.garrison0&&(t.portal.fortress.patrols-=e,t.portal.fortress.patrols<0&&(t.portal.fortress.patrols=0))},patSizeInc(){let e=y();t.portal.fortress.patrol_size1&&(t.portal.fortress.patrol_size-=e,t.portal.fortress.patrol_size<1&&(t.portal.fortress.patrol_size=1))},wall(){let e=t.portal.fortress.walls;return e>=75?"has-text-success":e<=25?"has-text-danger":"has-text-warning"},threaten(){let e=t.portal.fortress.threat;return e<1e3?"has-text-success":e>=2e3?"has-text-danger":"has-text-warning"},hire(){let e=y(),a=!0;for(;a&&e>0;){let r=Math.round(1.24**t.civic.garrison.workers*75)-50;r>25e3&&(r=25e3),t.civic.garrison.m_use>0&&(r*=1.1**t.civic.garrison.m_use),t.race.brute&&(r/=2),r=Math.round(r),t.civic.garrison.workers=r?(t.resource.Money.amount-=r,t.civic.garrison.workers++,t.civic.garrison.m_use++,t.portal.fortress.garrison++,t.portal.fortress.assigned=t.portal.fortress.garrison,sc({el:"#garrison"},"update")):a=!1,e--}},hireLabel:()=>xa("hireLabel"),observation(){t.settings.civTabs=$("#mainTabs > nav ul li").length-1,t.settings.tabLoad||Ga()}},filters:{defensive:e=>qa(e),patrolling(e){let a=e-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(i.soul_forge){let e=ba();e<=a&&(a-=e)}return t.portal.hasOwnProperty("guard_post")&&(a-=la(t.portal.guard_post.on)),a},threat:e=>F(e<1e3?"fortress_threat_level1":e<1500?"fortress_threat_level2":e>=5e3?"fortress_threat_level6":e>=3e3?"fortress_threat_level5":e>=2e3?"fortress_threat_level4":"fortress_threat_level3"),trainTime:(e,t)=>ic(0===e?-1:(100-t)/(4*e))}}),["hostiles","threatLevel","armyLabel","patLabel","patSizeLabel","hireLabel"].forEach((function(e){Ti(`hf${r}${e}`,(function(){switch(e){case"hostiles":case"threatLevel":return xa("hostiles");case"armyLabel":return F("fortress_stationed");case"patLabel":return F("fortress_patrol_desc",[t.portal.fortress.patrols]);case"patSizeLabel":return F("fortress_patrol_size_desc",[t.portal.fortress.patrol_size]);case"hireLabel":return xa("hireLabel")}}),{elm:`#${r} span.${e}`})})),Ti(`hf${r}observe`,(function(){return F("hell_observation_tooltip")}),{elm:`#${r} button.observe`})}function qa(e){let a=e-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(i.soul_forge){let e=ba();e<=a&&(a-=e)}t.portal.hasOwnProperty("guard_post")&&(a-=la(t.portal.guard_post.on));let r=0;if(t.civic.garrison.wounded>t.civic.garrison.workers-t.portal.fortress.garrison&&(r=t.civic.garrison.wounded-(t.civic.garrison.workers-t.portal.fortress.garrison),r>a&&(r=a)),i.war_droid){let e=i.war_droid-t.portal.fortress.patrols>0?i.war_droid-t.portal.fortress.patrols:0;a+=t.tech.hdroid?la(2*e):la(e)}let s=t.tech.turret?t.tech.turret>=2?70:50:35;return Math.round(ke(a,"hellArmy",r))+(i.turret?i.turret*s:0)}function Ma(e,a,r,s){let i=Math.round(Math.log2(e/t.portal.fortress.patrol_size/(a||1)))-Math.rand(0,a),c=0;if(i>0){i>t.portal.fortress.patrol_size&&(i=t.portal.fortress.patrol_size),i=Math.rand(r?1:0,i+1),c=Math.rand(0,i+1);let e=i-c;if(t.race.instinct){let t=Math.floor(c*(ui.instinct.vars()[1]/100));c-=t,e+=t}s.wounded=e,s.died=c,t.civic.garrison.wounded+=e,t.civic.garrison.workers-=c,t.stats.died+=c}return c}function Pa(e){t.race.witch_hunter&&t.portal.hasOwnProperty("soul_capacitor")&&i.soul_capacitor>0&&(t.portal.soul_capacitor.energy+=e,t.portal.soul_capacitor.energy>t.portal.soul_capacitor.ecap&&(t.portal.soul_capacitor.energy=t.portal.soul_capacitor.ecap))}function Oa(e,a){switch(e){case"ruins":{let e=a||la(i.guard_post),r=75*(i.arcology||0),s=ke(e,"hellArmy",0);t.race.holy&&(s*=1+ui.holy.vars()[1]/100);let c=Pi("unicorn");c>0&&(s*=1+ui.holy.vars(1)[1]/100*c);let o=(s+r)/5e3;return{supress:o>1?1:o,rating:s+r}}case"gate":{let e=Oa("ruins",a),r=100*(i.gate_turret||0);t.race.holy&&(r*=1+ui.holy.vars()[1]/100);let s=Pi("unicorn");s>0&&(r*=1+ui.holy.vars(1)[1]/100*s);let c=(e.rating+r)/7500;return{supress:c>1?1:c,rating:e.rating+r}}default:return 0}}const Ca={fire_elm:{weapon:{laser:1.05,flame:0,plasma:.25,kinetic:.5,missile:.5,sonic:1,shotgun:.75,tesla:.65},nozone:{freeze:!0,flooded:!0},amp:{hot:1.75,humid:.8,steam:.9}},water_elm:{weapon:{laser:.65,flame:.5,plasma:1,kinetic:.2,missile:.5,sonic:.5,shotgun:.25,tesla:.75},nozone:{hot:!0,freeze:!0},amp:{steam:1.5,river:1.1,flooded:2,rain:1.75,humid:1.25}},rock_golem:{weapon:{laser:1,flame:.5,plasma:1,kinetic:.65,missile:.95,sonic:.75,shotgun:.35,tesla:0},nozone:{},amp:{}},bone_golem:{weapon:{laser:.45,flame:.35,plasma:.55,kinetic:1,missile:1,sonic:.75,shotgun:.75,tesla:.15},nozone:{},amp:{}},mech_dino:{weapon:{laser:.85,flame:.05,plasma:.55,kinetic:.45,missile:.5,sonic:.35,shotgun:.5,tesla:1},nozone:{},amp:{}},plant:{weapon:{laser:.42,flame:1,plasma:.65,kinetic:.2,missile:.25,sonic:.75,shotgun:.35,tesla:.38},nozone:{},amp:{}},crazed:{weapon:{laser:.5,flame:.85,plasma:.65,kinetic:1,missile:.35,sonic:.15,shotgun:.95,tesla:.6},nozone:{},amp:{}},minotaur:{weapon:{laser:.32,flame:.5,plasma:.82,kinetic:.44,missile:1,sonic:.15,shotgun:.2,tesla:.35},nozone:{},amp:{}},ooze:{weapon:{laser:.2,flame:.65,plasma:1,kinetic:0,missile:0,sonic:.85,shotgun:0,tesla:.15},nozone:{},amp:{}},zombie:{weapon:{laser:.35,flame:1,plasma:.45,kinetic:.08,missile:.8,sonic:.18,shotgun:.95,tesla:.05},nozone:{},amp:{}},raptor:{weapon:{laser:.68,flame:.55,plasma:.85,kinetic:1,missile:.44,sonic:.22,shotgun:.33,tesla:.66},nozone:{},amp:{}},frost_giant:{weapon:{laser:.9,flame:.82,plasma:1,kinetic:.25,missile:.08,sonic:.45,shotgun:.28,tesla:.5},nozone:{hot:!0},amp:{freeze:2.5,hail:1.65}},swarm:{weapon:{laser:.02,flame:1,plasma:.04,kinetic:.01,missile:.08,sonic:.66,shotgun:.38,tesla:.45},nozone:{},amp:{}},dragon:{weapon:{laser:.18,flame:0,plasma:.12,kinetic:.35,missile:1,sonic:.22,shotgun:.65,tesla:.15},nozone:{},amp:{}},mech_dragon:{weapon:{laser:.84,flame:.1,plasma:.68,kinetic:.18,missile:.75,sonic:.22,shotgun:.28,tesla:1},nozone:{},amp:{}},construct:{weapon:{laser:.5,flame:.2,plasma:.6,kinetic:.34,missile:.9,sonic:.08,shotgun:.28,tesla:1},nozone:{},amp:{}},beholder:{weapon:{laser:.75,flame:.15,plasma:1,kinetic:.45,missile:.05,sonic:.01,shotgun:.12,tesla:.3},nozone:{},amp:{}},worm:{weapon:{laser:.55,flame:.38,plasma:.45,kinetic:.2,missile:.05,sonic:1,shotgun:.02,tesla:.01},nozone:{},amp:{}},hydra:{weapon:{laser:.85,flame:.75,plasma:.85,kinetic:.25,missile:.45,sonic:.5,shotgun:.6,tesla:.65},nozone:{},amp:{}},colossus:{weapon:{laser:1,flame:.05,plasma:.75,kinetic:.45,missile:1,sonic:.35,shotgun:.35,tesla:.5},nozone:{},amp:{}},lich:{weapon:{laser:.1,flame:.1,plasma:.1,kinetic:.45,missile:.75,sonic:.35,shotgun:.75,tesla:.5},nozone:{},amp:{}},ape:{weapon:{laser:1,flame:.95,plasma:.85,kinetic:.5,missile:.5,sonic:.05,shotgun:.35,tesla:.68},nozone:{},amp:{}},bandit:{weapon:{laser:.65,flame:.5,plasma:.85,kinetic:1,missile:.5,sonic:.25,shotgun:.75,tesla:.25},nozone:{},amp:{}},croc:{weapon:{laser:.65,flame:.05,plasma:.6,kinetic:.5,missile:.5,sonic:1,shotgun:.2,tesla:.75},nozone:{},amp:{}},djinni:{weapon:{laser:0,flame:.35,plasma:1,kinetic:.15,missile:0,sonic:.65,shotgun:.22,tesla:.4},nozone:{},amp:{}},snake:{weapon:{laser:.5,flame:.5,plasma:.5,kinetic:.5,missile:.5,sonic:.5,shotgun:.5,tesla:.5},nozone:{},amp:{}},centipede:{weapon:{laser:.5,flame:.85,plasma:.95,kinetic:.65,missile:.6,sonic:0,shotgun:.5,tesla:.01},nozone:{},amp:{}},spider:{weapon:{laser:.65,flame:1,plasma:.22,kinetic:.75,missile:.15,sonic:.38,shotgun:.9,tesla:.18},nozone:{},amp:{}},manticore:{weapon:{laser:.05,flame:.25,plasma:.95,kinetic:.5,missile:.15,sonic:.48,shotgun:.4,tesla:.6},nozone:{},amp:{}},fiend:{weapon:{laser:.75,flame:.25,plasma:.5,kinetic:.25,missile:.75,sonic:.25,shotgun:.5,tesla:.5},nozone:{},amp:{}},bat:{weapon:{laser:.16,flame:.18,plasma:.12,kinetic:.25,missile:.02,sonic:1,shotgun:.9,tesla:.58},nozone:{},amp:{}},medusa:{weapon:{laser:.35,flame:.1,plasma:.3,kinetic:.95,missile:1,sonic:.15,shotgun:.88,tesla:.26},nozone:{},amp:{}},ettin:{weapon:{laser:.5,flame:.35,plasma:.8,kinetic:.5,missile:.25,sonic:.3,shotgun:.6,tesla:.09},nozone:{},amp:{}},faceless:{weapon:{laser:.6,flame:.28,plasma:.6,kinetic:0,missile:.05,sonic:.8,shotgun:.15,tesla:1},nozone:{},amp:{}},enchanted:{weapon:{laser:1,flame:.02,plasma:.95,kinetic:.2,missile:.7,sonic:.05,shotgun:.65,tesla:.01},nozone:{},amp:{}},gargoyle:{weapon:{laser:.15,flame:.4,plasma:.3,kinetic:.5,missile:.5,sonic:.85,shotgun:1,tesla:.2},nozone:{},amp:{}},chimera:{weapon:{laser:.38,flame:.6,plasma:.42,kinetic:.85,missile:.35,sonic:.5,shotgun:.65,tesla:.8},nozone:{},amp:{}},gorgon:{weapon:{laser:.65,flame:.65,plasma:.65,kinetic:.65,missile:.65,sonic:.65,shotgun:.65,tesla:.65},nozone:{},amp:{}},kraken:{weapon:{laser:.75,flame:.35,plasma:.75,kinetic:.35,missile:.5,sonic:.18,shotgun:.05,tesla:.85},nozone:{},amp:{}},homunculus:{weapon:{laser:.05,flame:1,plasma:.1,kinetic:.85,missile:.65,sonic:.5,shotgun:.75,tesla:.2},nozone:{},amp:{}}};function ja(e,a){let r=9999,s=1e7;switch(e){case"small":{let e=t.blood.prepared&&t.blood.prepared>=2?5e4:75e3;s=a?2.5*e:e,r=a?20:1}break;case"medium":s=a?45e4:18e4,r=a?100:4;break;case"large":s=a?925e3:375e3,r=a?500:20;break;case"titan":s=a?15e5:75e4,r=a?1500:75;break;case"collector":{let e=t.blood.prepared&&t.blood.prepared>=2?8e3:1e4;s=a?2.5*e:e,r=1}}return{s:r,c:s}}function Sa(){if((t.settings.tabLoad||2===t.settings.civTabs&&4===t.settings.govTabs)&&(rc($("#mechLab")),t.portal.hasOwnProperty("mechbay")&&t.settings.showMechLab)){let e=$("#mechLab");t.portal.mechbay.hasOwnProperty("blueprint")||(t.portal.mechbay.blueprint={size:"small",hardpoint:["laser"],chassis:"tread",equip:[],infernal:!1});let a=$('
    ');e.append(a);let r=$(`
    ${F("portal_mech_assembly")} - {{ b.size | slabel }} {{ b.chassis | clabel }}
    `);a.append(r),r.append(` | ${F("portal_mech_bay_space")}: {{ m.bay }} / {{ m.max }}`),r.append(` | ${F("portal_mech_sup_avail")}: {{ p.supply | round }} / {{ p.sup_max }}`);let s=t.blood.prepared&&t.blood.prepared>=3?`${F("portal_mech_infernal")} (${F("portal_mech_infernal_effect",[25])})`:"";a.append(`
    ${F("portal_mech_space")} {{ b.size | bay }} | ${F("portal_mech_cost")} {{ b.size | price }} | ${F("portal_mech_soul",[t.resource.Soul_Gem.name])} {{ b.size | soul }}${s}
    `),a.append("
    {{ b.size | desc }}
    ");let i=$('
    ');a.append(i);let c="";["small","medium","large","titan","collector"].forEach((function(e,t){c+=`${F(`portal_mech_size_${e}`)}`})),i.append(`\n ${c}\n `);let o="";["wheel","tread","biped","quad","spider","hover"].forEach((function(e,t){o+=`${F(`portal_mech_chassis_${e}`)}`})),i.append(`\n ${o}\n `);for(let e=0;e<4;e++){let t="";["laser","kinetic","shotgun","missile","flame","plasma","sonic","tesla"].forEach((function(a,r){t+=`${F(`portal_mech_weapon_${a}`)}`})),i.append(`\n ${t}\n `)}let n=t.blood.prepared?5:4;for(let e=0;e{{ '${a}' | equipment }}`})),i.append(`\n ${t}\n `)}a.append(`
    `),sc({el:"#mechAssembly",data:{p:t.portal.purifier,m:t.portal.mechbay,b:t.portal.mechbay.blueprint},methods:{build(){let e=ja(t.portal.mechbay.blueprint.size,t.portal.mechbay.blueprint.infernal),a=e.c,r=e.s,s=Fa(t.portal.mechbay.blueprint.size),i=t.portal.mechbay.max-t.portal.mechbay.bay;if(t.portal.purifier.supply>=a&&i>=s&&t.resource.Soul_Gem.amount>=r){t.portal.purifier.supply-=a,t.resource.Soul_Gem.amount-=r;let e=zc(t.portal.mechbay.blueprint);t.portal.mechbay.mechs.push(e),t.portal.mechbay.bay+=s,t.portal.mechbay.active++}},setSize(e){switch(t.portal.mechbay.blueprint.size=e,"collector"===e?t.portal.mechbay.blueprint.hardpoint.length=0:"small"===e||"medium"===e?(0===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push("laser"),t.portal.mechbay.blueprint.hardpoint.length=1):(0===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push("laser"),1===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"plasma":"laser"),"titan"===e?2===t.portal.mechbay.blueprint.hardpoint.length&&(t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"shotgun":"laser"),t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"kinetic":"laser")):t.portal.mechbay.blueprint.hardpoint.length=2),e){case"small":t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?1:0;break;case"medium":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("shields"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?2:1;break;case"collector":case"large":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length<2&&t.portal.mechbay.blueprint.equip.push("shields"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("grapple"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?3:2;break;case"titan":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length<2&&t.portal.mechbay.blueprint.equip.push("shields"),t.portal.mechbay.blueprint.equip.length<3&&t.portal.mechbay.blueprint.equip.push("grapple"),t.portal.mechbay.blueprint.equip.length<4&&t.portal.mechbay.blueprint.equip.push("seals"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("stabilizer"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?5:4}},setType(e){t.portal.mechbay.blueprint.chassis=e},setWep(e,a){t.portal.mechbay.blueprint.hardpoint[a]=e,sc({el:"#mechAssembly"},"update")},setEquip(e,a){t.portal.mechbay.blueprint.equip[a]=e,sc({el:"#mechAssembly"},"update")},vis:e=>"collector"!==t.portal.mechbay.blueprint.size&&(0===e||"large"===t.portal.mechbay.blueprint.size&&e<2||"titan"===t.portal.mechbay.blueprint.size),eVis(e){let a=t.blood.prepared?1:0;switch(t.portal.mechbay.blueprint.size){case"small":return 1===a&&0===e;case"medium":return e<=0+a;case"collector":case"large":return e<=1+a;case"titan":return!0}}},filters:{bay:e=>Fa(e),price:e=>ja(e,t.portal.mechbay.blueprint.infernal).c,soul:e=>ja(e,t.portal.mechbay.blueprint.infernal).s,slabel:e=>F(`portal_mech_size_${e}`),clabel:e=>F(`portal_mech_chassis_${e}`),wlabel:e=>F(`portal_mech_weapon_${e}`),desc:e=>F(`portal_mech_size_${e}_desc`),round:e=>Math.round(e),equipment(e){if("special"!==e)return F(`portal_mech_equip_${e}`);let a="jumpjet";switch(t.portal.mechbay.blueprint.size){case"large":a="battery";break;case"titan":a="target"}return F(`portal_mech_equip_${a}`)}}}),["size","chassis","weapon","equip"].forEach((function(e){let a=1;"weapon"===e?a=4:"equip"===e&&(a=n);for(let r=0;r');e.append(l),za(),rc($("#mechList")),$("#mechList").append(`\n
    \n ${F("portal_mech_scrap")}\n | ${F("portal_mech")} #{{index + 1}}: \n {{ mech.infernal ? "${F("portal_mech_infernal")} " : "" }}{{ mech | size }} {{ mech | chassis }}\n
    \n
    \n \n
    \n
    \n \n
    \n
    \n
    `),sc({el:"#mechList",data:t.portal.mechbay,methods:{scrap(e){if(t.portal.mechbay.mechs[e]){let a=ja(t.portal.mechbay.mechs[e].size,t.portal.mechbay.mechs[e].infernal),r=Fa(t.portal.mechbay.mechs[e].size);t.portal.purifier.supply+=Math.floor(a.c/3),t.resource.Soul_Gem.amount+=Math.floor(a.s/2),t.portal.purifier.supply>t.portal.purifier.sup_max&&(t.portal.purifier.supply=t.portal.purifier.sup_max),t.portal.mechbay.mechs.splice(e,1),t.portal.mechbay.bay-=r,t.portal.mechbay.active--}}},filters:{equipment(e,t){if("special"!==e)return F(`portal_mech_equip_${e}`);let a="jumpjet";switch(t){case"large":a="battery";break;case"titan":a="target"}return F(`portal_mech_equip_${a}`)},weapon:e=>F(`portal_mech_weapon_${e}`),size:e=>F(`portal_mech_size_${e.size}`),chassis:e=>F(`portal_mech_chassis_${e.chassis}`)}}),function(){let e=$("#mechList")[0];Sortable.create(e,{onEnd(e){let a=e.from.querySelectorAll(":scope > .mechRow");e.from.insertBefore(e.item,a[e.oldIndex+(e.oldIndex>e.newIndex)]);let r=t.portal.mechbay.mechs;r.splice(e.newDraggableIndex,0,r.splice(e.oldDraggableIndex,1)[0]),Aa()}})}(),$("#mechList .scrap").each((function(e,a){Ti(`mechList-scrap${e}`,(function(){let a=ja(t.portal.mechbay.mechs[e].size,t.portal.mechbay.mechs[e].infernal);return F("portal_mech_scrap_refund",[Math.floor(a.c/3),Math.floor(a.s/2)])}),{elm:a})}))}}function Fa(e){switch(e){case"small":return 2;case"medium":return t.blood.prepared&&t.blood.prepared>=2?4:5;case"large":return t.blood.prepared&&t.blood.prepared>=2?8:10;case"titan":return t.blood.prepared&&t.blood.prepared>=2?20:25;case"collector":return 1;case"default":return 25}}function za(){let e=$("#mechList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}function Aa(){let e=25*(l.mechbay||0),a=0,r=0,s=0;for(let i of t.portal.mechbay.mechs)a+=Fa(i.size),a<=e&&(r++,"small"===i.size&&s++);t.portal.mechbay.bay=a,t.portal.mechbay.max=e,t.portal.mechbay.active=r,t.portal.mechbay.scouts=s}function Ta(){let e=["sand","swamp","forest","jungle","rocky","gravel","muddy","grass","brush","concrete"];if(t.portal.spire.type=e[Math.floor(m(0,e.length))],t.portal.spire.count>=10){t.portal.spire.status={};let e=["freeze","hot","corrosive","humid","windy","hilly","mountain","radioactive","quake","dust","river","tar","steam","flooded","fog","rain","hail","chasm","dark","gravity"];if(Ea(e[Math.floor(m(0,e.length))]),t.portal.spire.count>=25&&t.portal.spire.count<=100){let a=105-t.portal.spire.count;Math.floor(m(0,a)<=5)&&Ea(e[Math.floor(m(0,e.length))])}else if(t.portal.spire.count>100&&t.portal.spire.count<=250){Ea(e[Math.floor(m(0,e.length))]);let a=260-t.portal.spire.count;Math.floor(m(0,a)<=10)&&Ea(e[Math.floor(m(0,e.length))])}else if(t.portal.spire.count>250&&t.portal.spire.count<=1e3){Ea(e[Math.floor(m(0,e.length))]),Ea(e[Math.floor(m(0,e.length))]);let a=1025-t.portal.spire.count;Math.floor(m(0,a)<=25)&&Ea(e[Math.floor(m(0,e.length))])}else t.portal.spire.count>1e3&&(Ea(e[Math.floor(m(0,e.length))]),Ea(e[Math.floor(m(0,e.length))]),Ea(e[Math.floor(m(0,e.length))]))}let a=Object.keys(Ca).filter((function(e){let a=Object.keys(Ca[e].nozone);return!a.some((e=>Object.keys(t.portal.spire.status).includes(e)))&&!a.includes(t.portal.spire.type)}));t.portal.spire.boss=a[Math.floor(m(0,a.length))]}function Ea(e){t.portal.spire.status.freeze||t.portal.spire.status.hot?"freeze"!==e&&"hot"!==e&&(t.portal.spire.status[e]=!0):t.portal.spire.status.rain||t.portal.spire.status.hail?"rain"!==e&&"hail"!==e&&(t.portal.spire.status[e]=!0):t.portal.spire.status[e]=!0}function Ia(e,a,r){return!e.equip.includes("special")||"small"!==e.size&&"medium"!==e.size&&"collector"!==e.size||a<1&&(a+=(1-a)*(r.includes("gravity")?.1:.2)),"small"!==e.size&&a<1&&(a+=(r.includes("fog")||r.includes("dark")?.005:.01)*t.portal.mechbay.scouts)>1&&(a=1),a}function Ka(e,t){return t<1&&0!==t&&e.equip.includes("special")&&"titan"===e.size&&(t+=.25*(1-t)),e.equip.includes("special")&&"large"===e.size&&(t*=1.02),t}function La(e,t){let a=1;switch(t){case"freeze":e.equip.includes("radiator")||(a=.25);break;case"hot":e.equip.includes("coolant")||(a=.25);break;case"corrosive":e.equip.includes("ablative")||(a=e.equip.includes("shields")?.75:.25);break;case"humid":case"rain":e.equip.includes("seals")||(a=.75);break;case"windy":"hover"===e.chassis&&(a=.5);break;case"hilly":"spider"!==e.chassis&&(a=.75);break;case"mountain":"spider"===e.chassis||e.equip.includes("grapple")||(a=e.equip.includes("flare")?.75:.5);break;case"radioactive":e.equip.includes("shields")||(a=.5);break;case"quake":e.equip.includes("stabilizer")||(a=.25);break;case"dust":e.equip.includes("seals")||(a=.5);break;case"river":"hover"!==e.chassis&&(a=.65);break;case"tar":"quad"!==e.chassis&&(a="tread"===e.chassis||"wheel"===e.chassis?.5:.75);break;case"steam":e.equip.includes("shields")||(a=.75);break;case"flooded":"hover"!==e.chassis&&(a=.35);break;case"fog":e.equip.includes("sonar")||(a=.2);break;case"hail":e.equip.includes("ablative")||e.equip.includes("shields")||(a=.75);break;case"chasm":e.equip.includes("grapple")||(a=.1);break;case"dark":e.equip.includes("infrared")||(a=e.equip.includes("flare")?.25:.1);break;case"gravity":switch(e.size){case"medium":a=.8;break;case"large":a=.45;break;case"titan":a=.25}}return a}function Na(e,a){let r=a||t.portal.spire.type,s=1;switch(e.chassis){case"wheel":switch(r){case"sand":s=["small","medium"].includes(e.size)?.9:.85;break;case"swamp":s=["small","medium"].includes(e.size)?.35:.18;break;case"jungle":s=["small","medium"].includes(e.size)?.92:.85;break;case"rocky":s=["small","medium"].includes(e.size)?.65:.5;break;case"gravel":s=["small","medium"].includes(e.size)?1:.95;break;case"muddy":s=["small","medium"].includes(e.size)?.85:.58;break;case"grass":s=["small","medium"].includes(e.size)?1.3:1.2;break;case"brush":s=["small","medium"].includes(e.size)?.9:.8;break;case"concrete":s=["small","medium"].includes(e.size)?1.1:1}break;case"tread":switch(r){case"sand":s=["small","medium"].includes(e.size)?1.15:1.1;break;case"swamp":s=["small","medium"].includes(e.size)?.55:.4;break;case"forest":s=["small","medium"].includes(e.size)?1:.95;break;case"jungle":s=["small","medium"].includes(e.size)?.95:.9;break;case"rocky":s=["small","medium"].includes(e.size)?.65:.5;break;case"gravel":s=["small","medium"].includes(e.size)?1.3:1.2;break;case"muddy":s=["small","medium"].includes(e.size)?.88:.72}break;case"biped":switch(r){case"sand":s=["small","medium"].includes(e.size)?.78:.65;break;case"swamp":s=["small","medium"].includes(e.size)?.68:.5;break;case"forest":s=["small","medium"].includes(e.size)?1:.95;break;case"jungle":s=["small","medium"].includes(e.size)?.82:.7;break;case"rocky":s=["small","medium"].includes(e.size)?.48:.4;break;case"muddy":s=["small","medium"].includes(e.size)?.85:.7;break;case"grass":s=["small","medium"].includes(e.size)?1.25:1.2;break;case"brush":s=["small","medium"].includes(e.size)?.92:.85}break;case"quad":switch(r){case"sand":s=["small","medium"].includes(e.size)?.86:.75;break;case"swamp":s=["small","medium"].includes(e.size)?.58:.42;break;case"forest":s=["small","medium"].includes(e.size)?1.25:1.2;break;case"rocky":case"brush":s=["small","medium"].includes(e.size)?.95:.9;break;case"gravel":s=["small","medium"].includes(e.size)?.9:.8;break;case"muddy":s=["small","medium"].includes(e.size)?.68:.5;break;case"grass":s=["small","medium"].includes(e.size)?1:.95}break;case"spider":switch(r){case"sand":s=["small","medium"].includes(e.size)?.75:.65;break;case"swamp":s=["small","medium"].includes(e.size)?.9:.78;break;case"forest":s=["small","medium"].includes(e.size)?.82:.75;break;case"jungle":s=["small","medium"].includes(e.size)?.77:.65;break;case"rocky":s=["small","medium"].includes(e.size)?1.25:1.2;break;case"gravel":s=["small","medium"].includes(e.size)?.86:.75;break;case"muddy":s=["small","medium"].includes(e.size)?.92:.82;break;case"brush":s=["small","medium"].includes(e.size)?1:.95}break;case"hover":switch(r){case"swamp":s=["small","medium"].includes(e.size)?1.35:1.2;break;case"forest":s=["small","medium"].includes(e.size)?.65:.48;break;case"jungle":s=["small","medium"].includes(e.size)?.55:.35;break;case"rocky":s=["small","medium"].includes(e.size)?.82:.68;break;case"muddy":s=["small","medium"].includes(e.size)?1.15:1.08;break;case"brush":s=["small","medium"].includes(e.size)?.78:.7}}return s}function Da(e){let a=e.infernal?31.25:25,r=Na(e),s=[];return Object.keys(t.portal.spire.status).forEach((function(t){s.push(t),a*=La(e,t)})),a*=Ia(e,r,s),a}function Ba(e,a){let r=function(e){switch(e){case"small":return.0025;case"medium":return.0075;case"large":return.01;case"titan":return.012;default:return 0}}(e.size);if(0===r)return 0;if(e.hasOwnProperty("infernal")&&e.infernal&&t.blood.prepared&&t.blood.prepared>=3&&(r*=1.25),a){t.stats.achieve.gladiator&&t.stats.achieve.gladiator.l>0&&(r*=1+.1*t.stats.achieve.gladiator.l),t.blood.wrath&&(r*=1+t.blood.wrath/20),"titan"===e.size&&(r*=1.1);let a=Yc();t.stats.spire.hasOwnProperty(a)&&t.stats.spire[a].hasOwnProperty("dlstr")?r/=100+25*t.stats.spire[a].dlstr:r/=100;let s=0;for(let t=0;t0&&(r*=1+.2*t.stats.achieve.gladiator.l),t.blood.wrath&&(r*=1+t.blood.wrath/20),"concrete"===t.portal.spire.type)switch(e.size){case"small":r*=.92;break;case"medium":r*=.95;break;case"titan":r*=1.25}let a=Na(e),s=[];Object.keys(t.portal.spire.status).forEach((function(t){s.push(t),r*=La(e,t)})),r*=Ia(e,a,s),r/=t.portal.spire.count;let i=0;for(let a=0;a nav ul li").length-1&&!e)return;let a=$("#mTabObserve");rc(a);let r=$('
    ');if(a.append(r),r.append(`\n \n \n \n \n \n \n `),sc({el:"#hellObservations",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(rc($("#h_Report")),rc($("#h_Analysis")),e){case 0:Ua();break;case 1:Ra()}return e}}}),t.settings.tabLoad)Ua(),Ra();else switch(t.settings.hellTabs){case 0:Ua();break;case 1:Ra()}}function Ra(){if(!t.settings.tabLoad&&1!==t.settings.hellTabs)return;let e=$("#h_Analysis"),a=$('
    ');e.append(a);let r=$("
    ");a.append(r);let s=$('
    ');a.append(s);let i=$('
    ');s.append(i);let c=$('
    '),o=$('
    ');i.append(c),i.append(o),r.append(`\n
    \n

    ${F("tab_settings")}

    \n
    \n
    \n ${F("hell_analysis_expanded")}\n ${F("hell_analysis_average")}\n ${F("hell_analysis_hyperSlow")}\n
    \n
    \n ${F("hell_analysis_time_game_days")}\n ${F("hell_analysis_time_seconds")}\n ${F("hell_analysis_time_minutes")}\n ${F("hell_analysis_time_hours")}\n ${F("hell_analysis_time_days")}\n
    \n `),sc({el:"#hellAnalysis",data:{s:t.portal.observe.settings,r:t.race}});let n=function(e,t){e=e.toFixed(t);let a=Math.floor(e),r=(+(e-a).toFixed(t)).toString().substring(1);return a.toLocaleString()+r},l=function(e,a,r){if(e){switch("game_days"!==r&&t.portal.observe.settings.hyperSlow&&(t.race.slow&&(a*=1+ui.slow.vars()[0]/100),t.race.hyper&&(a*=1-ui.hyper.vars()[0]/100)),e/=a,r){case"seconds":e/=5;break;case"minutes":e*=12;break;case"hours":e*=720;break;case"days":e*=17280}e=t.portal.observe.settings.expanded?n(e,5):k(e,5,!0)}return F("hell_analysis_time_average",[e,F(`hell_analysis_time_${r}_abbr`)])},u=function(e,a){if(!e)return;let r=$(`#${e}`);rc(r),r.append(`\n

    ${F("hell_analysis_"+a)}

    ${"period"===a?'

    {{ | resetLabel }}

    ':""}
    \n

    {{ st.${a}.start | startLabel }}

    \n

    {{ st.${a}.days, s.display | time }}

    \n

    {{ st.${a}.kills, 'kills', s.average | genericMulti }}

    {{ s.dropKills | dropdownLabel }}

    \n
    \n

    {{ st.${a}.kills.drones, 'kills_drones', s.average | genericSub }}

    \n

    {{ st.${a}.kills.patrols, 'kills_patrols', s.average | genericSub }}

    \n

    {{ st.${a}.kills.sieges, 'kills_sieges', s.average | genericSub }}

    \n

    {{ st.${a}.kills.guns, 'kills_guns', s.average | genericSub }}

    \n

    {{ st.${a}.kills.soul_forge, 'kills_soul_forge', s.average | genericSub }}

    \n

    {{ st.${a}.kills.turrets, 'kills_turrets', s.average | genericSub }}

    \n
    \n

    {{ st.${a}.gems, 'gems', s.average | genericMulti }}

    {{ s.dropGems | dropdownLabel }}

    \n
    \n

    {{ st.${a}.gems.patrols, 'gems_patrols', s.average | genericSub }}

    \n

    {{ st.${a}.gems.guns, 'gems_guns', s.average | genericSub }}

    \n

    {{ st.${a}.gems.soul_forge, 'gems_soul_forge', s.average | genericSub }}

    \n

    {{ st.${a}.gems.crafted, 'gems_crafted', s.average | genericSub }}

    \n

    {{ st.${a}.gems.turrets, 'gems_turrets', s.average | genericSub }}

    \n

    {{ st.${a}.gems.surveyors, 'gems_surveyors', s.average | genericSub }}

    \n
    \n

    {{ st.${a}.wounded, 'wounded', s.average | generic }}

    \n

    {{ st.${a}.died, 'died', s.average | generic }}

    \n

    {{ st.${a}.revived, 'revived', s.average | generic }}

    \n

    {{ st.${a}.surveyors, 'surveyors', s.average | generic }}

    \n

    {{ st.${a}.sieges, 'sieges', s.average | generic }}

    \n `),sc({el:`#${e}`,data:{st:t.portal.observe.stats,s:t.portal.observe.settings,p:t.portal,r:t.race,sg:t.resource.Soul_Gem},methods:{resetObservations(){Object.keys(t.portal.observe.stats.period).forEach((function(e){["kills","gems"].includes(e)?Object.keys(t.portal.observe.stats.period[e]).forEach((function(a){t.portal.observe.stats.period[e][a]=0})):"start"===e?t.portal.observe.stats.period.start={year:t.city.calendar.year,day:t.city.calendar.day}:t.portal.observe.stats.period[e]=0}))},toggleDropdown(e){t.portal.observe.settings[e]=!t.portal.observe.settings[e]}},filters:{generic:(e,r,s)=>F("hell_analysis_number_display",s?[F(`hell_analysis_${r}`),l(e,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]:[F(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+e.toFixed(5)).toLocaleString():k(e,5,!0)]),genericSub:(e,r,s)=>s?"ᄂ"+F("hell_analysis_number_display",[F(`hell_analysis_${r}`),l(e,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]):"ᄂ"+F("hell_analysis_number_display",[F(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+e.toFixed(5)).toLocaleString():k(e,5,!0)]),genericMulti(e,r,s){let i=0;return Object.keys(e).forEach((function(t){i+=e[t]})),F("hell_analysis_number_display",s?[F(`hell_analysis_${r}`),l(i,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]:[F(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+i.toFixed(5)).toLocaleString():k(i,5,!0)])},time(e,a){switch("game_days"!==a&&t.portal.observe.settings.hyperSlow&&(t.race.slow&&(e*=1+ui.slow.vars()[0]/100),t.race.hyper&&(e*=1-ui.hyper.vars()[0]/100)),a){case"seconds":e*=5;break;case"minutes":e/=12;break;case"hours":e/=720;break;case"days":e/=17280}return F("hell_analysis_time",[F(`hell_analysis_time_${a}`),t.portal.observe.settings.expanded?n(e,8):k(e,5,!0)])},resetLabel:()=>F("hell_analysis_period_reset"),startLabel:e=>F("hell_analysis_start",[e.year,e.day]),dropdownLabel:e=>e?"⮝":"⮟"}})};u("hellAnalysisTotal","total"),u("hellAnalysisPeriod","period"),a=$("#hellAnalysis");let d=$("
    ");a.append(d),d.append(`

    ${F("hell_graph_create")}

    `);let _=$('
    ');d.append(_),sc({el:"#hellGraphCreator",methods:{createGraph(){this.$buefy.modal.open({parent:this,component:{template:''}});let e=setInterval((function(){if($("#modalBox").length>0){clearInterval(e),$("#modalBox").append($(`

    ${F("hell_graph_title")}

    `));var a=$('
    ');$("#modalBox").append(a);let r=$('
    ');a.append(r);let s={chartType:"pie",name:"",chartName:"",data:[],radioFake:"",showGroups:!0},i={show:!1,message:""};r.append(`\n

    ${F("hell_graph_name")}

    \n `),r.append(`\n
    \n
    \n

    ${F("hell_graph_type")}

    \n
    \n
    \n ${F("hell_graph_pie")}\n
    \n
    \n `);let c=$('
    ');r.append(c),c.append(`

    ${F("hell_graph_data")}

    `),Object.keys(t.portal.observe.stats).forEach((function(e){["kills","gems"].forEach((function(t){c.append(`
    \n ${F("hell_graph_datapoint",[F(`hell_analysis_${e}`),F(`hell_analysis_${t}`)])}\n
    `)}))})),r.append(`\n
    \n
    \n

    {{ e.message }}

    \n
    \n
    \n \n
    \n
    \n `),sc({el:"#specialModal",data:{s,e:i,sg:t.resource.Soul_Gem},methods:{nameUpdate(e){s.chartName!==e&&(i.show=!1,s.chartName=e)},dataOptions(e){switch(e){case"pie":s.showGroups=!0;break;case"bar":s.showGroups=!1}},setData(e,t){i.show=!1,s.data=[e,t]},createGraph(){if(!s.name)return i.show=!0,void(i.message=F("hell_graph_error_name_blank"));if(0===s.data.length)return i.show=!0,void(i.message=F("hell_graph_error_data_missing"));let e=[],a=[];"pie"===s.chartType&&Object.keys(t.portal.observe.stats[s.data[0]][s.data[1]]).forEach((function(t){e.push(F(`hell_analysis_${s.data[1]}_${t}`)),a.push([s.data[0],s.data[1],t])}));let r=function(e,a,r,s,i){let c=`hellGraph-${t.portal.observe.graphID}`;return t.portal.observe.graphID++,t.portal.observe.graphs[c]={id:c,chartID:`${c}-chart`,name:e,type:a,labels:r,data:s,settings:i},c}(s.chartName,s.chartType,e,a,{title:s.chartName});Ha(_,t.portal.observe.graphs[r]),document.dispatchEvent(new KeyboardEvent("keydown",{key:"Escape"})),document.dispatchEvent(new KeyboardEvent("keyup",{key:"Escape"}))}}})}}),50)}}}),Object.keys(t.portal.observe.graphs).forEach((function(e){Ha(_,t.portal.observe.graphs[e])}))}function Ha(e,a){let r=a.id;_[r]&&_[r].graph.destroy();let s=$(`
    `);e.append(s),s.append(`
    \n
    \n

    \n

    Delete

    \n
    \n
    \n

    ${a.name}

    \n
    \n
    `);let i=$('
    ');s.append(i),sc({el:`#graph-${r}-controls`,methods:{deleteGraph(){_[r].graph.destroy(),delete _[r],delete t.portal.observe.graphs[r],rc($(`#graph-${r}-container`),!0)}}});let c=$(``);i.append(c),_[r]={data:a.data},"pie"===a.type&&(_[r].graph=function(e,a,r,s){let i=[];return r.forEach((function(e){i.push(3===e.length?t.portal.observe.stats[e[0]][e[1]][e[2]]:t.portal.observe.stats[e[0]][e[1]])})),new Chart(e,{type:"pie",data:{labels:a,datasets:[{data:i,backgroundColor:["rgb(255, 99, 132)","rgb(54, 162, 235)","rgb(255, 205, 86)","rgb(201, 203, 207)","rgb(75, 192, 192)","#B86BFF","#48c774"],hoverOffset:4}]},options:{plugins:{legend:{display:!1}}}})}(c,a.labels,a.data,a.settings))}function Ua(){if(!t.settings.tabLoad&&0!==t.settings.hellTabs)return;Wa();let e="",a=$("#h_Report"),r=$('
    ');a.append(r);let s=$('
    ');r.append(s),s.append(`

    ${F("hell_report_log")}

    \n \n \n\t\t \n \n
    `);let i=$('
    ');s.append(i),r.append($('
    '));let c={year:0,day:0};Object.keys(d).length&&(c.year=Object.keys(d)[0].split("-")[1],c.day=Object.keys(d[`year-${c.year}`])[0].split("-")[1]);let o=function(a,r){for(Wa(!0)&&(e="",a=Object.keys(d)[0].split("-")[1],r=Object.keys(d[`year-${c.year}`])[0].split("-")[1]);a${F("year")+" "+a+" | "+F("day")+" "+r}${d[`year-${a}`][`day-${r}`].foundGem?'':""}\n `+e;r=1}for(;r${F("year")+" "+a+" | "+F("day")+" "+r}${d[`year-${a}`][`day-${r}`].foundGem?``:""}\n `+e;c.year=a,c.day=r;let s=$("#hellReportList");rc(s),s.append(e),sc({el:"#hellReportList",methods:{reportLoad(e,t){n(e,t)}}})},n=function(e,a){if(!e||!a)return;let r=$("#hellReportDisplay");rc(r);let s=d[`year-${e}`][`day-${a}`],i=$('
    ');r.append(i);let c=0,o=0;if(Object.keys(s.stats.kills).forEach((function(e){c+=s.stats.kills[e]})),Object.keys(s.stats.gems).forEach((function(e){o+=s.stats.gems[e]})),i.append(`

    ${F("hell_report_log_stats",[e,a])}

    `),i.append(`
    \n

    ${F("hell_report_log_stats_kills",[c])}

    \n

    ${F("hell_report_log_stats_gems",[o])}

    \n

    ${F("hell_report_log_stats_wounded",[s.stats.wounded])}

    \n

    ${F("hell_report_log_stats_died",[s.stats.died])}

    \n
    `),r.append(`

    ${F("hell_report_log_report",[e,a])}

    `),r.append(`

    ${F("hell_report_log_start",[s.start])}

    `),s.drones&&Object.keys(s.drones).forEach((function(e){let t=s.drones[e],a=F("hell_report_log_obj_counter",[F("portal_war_drone_title"),e]);t.encounter?r.append(`

    ${F("hell_report_log_encounter",[a,t.kills])}

    `):r.append(`

    ${F("hell_report_log_encounter_fail",[a])}

    `)})),s.patrols&&Object.keys(s.patrols).forEach((function(e){let a=s.patrols[e],i=F("hell_report_log_obj_counter",[F("hell_report_log_patrol"),e]);if(i=a.droid?F("hell_report_log_patrol_droid",[i]):i,a.encounter){let e=$("

    ");a.ambush?e.append(`${F("hell_report_log_patrol_ambush",[i,a.kills])}`):e.append(`${F("hell_report_log_encounter",[i,a.kills])}`),a.wounded&&e.append(`${a.wounded>1?F("hell_report_log_patrol_wounded_plural",[a.wounded]):F("hell_report_log_patrol_wounded")}`),a.died&&e.append(`${a.died>1?F("hell_report_log_patrol_killed_plural",[a.died]):F("hell_report_log_patrol_killed")}`),a.gem>0&&e.append(`${F("hell_report_log_soul_find",[t.resource.Soul_Gem.name,a.gem])}`),r.append(e)}else r.append(`

    ${F("hell_report_log_encounter_fail",[i])}

    `)})),s.surveyor_finds&&Object.keys(s.surveyor_finds).forEach((function(e){let a=s.surveyor_finds[e],i=F("hell_report_log_obj_counter",[F("job_hell_surveyor"),e]),c=$("

    ");c.append(`${F("hell_report_log_search",[i,a.bodies])}`),a.gem>0&&c.append(`${F("hell_report_log_soul_search",[t.resource.Soul_Gem.name,a.gem])}`),r.append(c)})),s.revived&&r.append(`

    ${s.revived>1?F("hell_report_log_revived_plural",[s.revived]):F("hell_report_log_revived")}

    `),s.patrols_lost&&r.append(`

    ${F("hell_report_log_patrols_lost",[s.patrols_lost])}

    `),s.siege&&(s.siege.destroyed?r.append(`

    ${F("hell_report_log_siege",[s.siege.surveyors,s.siege.soldiers,s.siege.kills])}

    `):r.append(`

    ${F("hell_report_log_siege_fail",[s.siege.damage,s.siege.kills])}

    `)),s.demons&&r.append(`

    ${F("hell_report_log_demons",[s.demons])}

    `),s.surveyors&&r.append(`

    ${s.surveyors>1?F("hell_report_log_surveyors_plural",[s.surveyors]):F("hell_report_log_surveyors")}

    `),s.soul_attractors&&r.append(`

    ${F("hell_report_log_soul_attractors",[s.soul_attractors])}

    `),s.gun_emplacements&&Object.keys(s.gun_emplacements).forEach((function(e){let a=$("

    "),i=s.gun_emplacements[e],c=F("hell_report_log_obj_counter",[F("portal_gun_emplacement_title"),e]);a.append($(`${F("hell_report_log_misc_kills",[c,i.kills,F("portal_pit_name")])}`)),i.gem&&a.append(`${F("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),r.append(a)})),s.soul_forge){let e=$("

    ");e.append(`${F("hell_report_log_soul_forge",[s.soul_forge.kills])}`),s.soul_forge.gem&&e.append(`${F("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),s.soul_forge.gem_craft&&e.append(`${F("hell_report_log_soul_craft",[s.soul_forge.corrupt?F("resource_Corrupt_Gem_name"):t.resource.Soul_Gem.name])}`),r.append(e)}s.gate_turrets&&Object.keys(s.gate_turrets).forEach((function(e){let a=$("

    "),i=s.gate_turrets[e],c=F("hell_report_log_obj_counter",[F("portal_gate_turret_title"),e]);a.append(`${F("hell_report_log_misc_kills",[c,i.kills,F("portal_gate_name")])}`),i.gem&&a.append(`${F("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),r.append(a)})),sc({el:"#hellReportDisplay",data:{g:t.resource.Soul_Gem}})};if(0!==c.day){o(c.year,c.day);let e=c.year,a=c.day;a-1==0?(e--,a=t.city.calendar.orbit):a--,n(e,a)}else c.year=t.city.calendar.year,c.day=t.city.calendar.day;sc({el:"#hellReportLogTitle",methods:{updateList(){o(c.year,c.day)}}}),Ti("hellReportLogs",(function(){return F("hell_report_log_tooltip",[2500])}),{elm:"#hellReport .reportList div:first-child h2"})}function Wa(e){if(!document.getElementById("hellReportList")||e){let e=!1,a=2500,r=(Object.keys(d).length-1)*t.city.calendar.orbit+t.city.calendar.day;if(r>a){let s=Object.keys(d[Object.keys(d)[0]]).length;for(r-t.city.calendar.orbit+s>a&&(e=!0,r-=s,delete d[Object.keys(d)[0]]);r>a;)r-=t.city.calendar.orbit,delete d[Object.keys(d)[0]]}return e}}const Qa={Food:5,Lumber:5,Chrysotile:5,Stone:5,Crystal:6,Furs:8,Copper:25,Iron:40,Aluminium:50,Cement:15,Coal:20,Oil:75,Uranium:550,Steel:100,Titanium:150,Alloy:350,Polymer:250,Iridium:420,Helium_3:620,Deuterium:950,Elerium:2e3,Water:2,Neutronium:1500,Adamantite:2250,Infernite:2750,Nano_Tube:750,Graphene:3e3,Stanene:3600,Bolognium:9e3,Vitreloy:10200,Orichalcum:99e3,Horseshoe:0,Nanite:0,Genes:0,Soul_Gem:0,Corrupt_Gem:0,Codex:0,Cipher:0,Demonic_Essence:0},Za={Food:2,Lumber:2,Chrysotile:1,Stone:2,Crystal:.4,Furs:1,Copper:1,Iron:1,Aluminium:1,Cement:1,Coal:1,Oil:.5,Uranium:.12,Steel:.5,Titanium:.25,Alloy:.2,Polymer:.2,Iridium:.1,Helium_3:.1,Deuterium:.1,Elerium:.02,Water:2,Neutronium:.05,Adamantite:.05,Infernite:.01,Nano_Tube:.1,Graphene:.1,Stanene:.1,Bolognium:.12,Vitreloy:.12,Orichalcum:.05},Va={Food:4.355,Lumber:7.668,Chrysotile:15.395,Stone:20.017,Crystal:5.062,Furs:13.009,Copper:63.546,Iron:55.845,Aluminium:26.9815,Cement:20.009,Coal:12.0107,Oil:5.342,Uranium:238.0289,Steel:55.9,Titanium:47.867,Alloy:45.264,Polymer:120.054,Iridium:192.217,Helium_3:3.0026,Deuterium:2.014,Neutronium:248.74,Adamantite:178.803,Infernite:222.666,Elerium:297.115,Nano_Tube:15.083,Graphene:26.9615,Stanene:33.9615,Bolognium:75.898,Unobtainium:168.59,Vitreloy:41.08,Orichalcum:237.8,Water:18.01,Plywood:7.666,Brick:20.009,Wrought_Iron:55.845,Sheet_Metal:26.9815,Mythril:94.239,Aerogel:7.84,Nanoweave:23.71,Scarletite:188.6,Quantium:241.35},Ja={Lumber:{in:.5,out:25e3},Chrysotile:{in:.5,out:25e3},Stone:{in:.5,out:25e3},Crystal:{in:3,out:25e3},Furs:{in:3,out:25e3},Copper:{in:1.5,out:25e3},Iron:{in:1.5,out:25e3},Aluminium:{in:2.5,out:25e3},Cement:{in:3,out:25e3},Coal:{in:1.5,out:25e3},Oil:{in:2.5,out:12e3},Uranium:{in:5,out:300},Steel:{in:3,out:25e3},Titanium:{in:3,out:25e3},Alloy:{in:6,out:25e3},Polymer:{in:6,out:25e3},Iridium:{in:8,out:25e3},Helium_3:{in:4.5,out:12e3},Deuterium:{in:4,out:1e3},Neutronium:{in:15,out:1e3},Adamantite:{in:12.5,out:1e3},Infernite:{in:25,out:250},Elerium:{in:30,out:250},Nano_Tube:{in:6.5,out:1e3},Graphene:{in:5,out:1e3},Stanene:{in:4.5,out:1e3},Bolognium:{in:18,out:1e3},Vitreloy:{in:14,out:1e3},Orichalcum:{in:10,out:1e3},Plywood:{in:10,out:250},Brick:{in:10,out:250},Wrought_Iron:{in:10,out:250},Sheet_Metal:{in:10,out:250},Mythril:{in:12.5,out:250},Aerogel:{in:16.5,out:250},Nanoweave:{in:18,out:250},Scarletite:{in:35,out:250}};function Ya(){let e={Plywood:[{r:"Lumber",a:100}],Brick:t.race.flier?[{r:"Stone",a:60}]:[{r:"Cement",a:40}],Wrought_Iron:[{r:"Iron",a:80}],Sheet_Metal:[{r:"Aluminium",a:120}],Mythril:[{r:"Iridium",a:100},{r:"Alloy",a:250}],Aerogel:[{r:"Graphene",a:2500},{r:"Infernite",a:50}],Nanoweave:[{r:"Nano_Tube",a:1e3},{r:"Vitreloy",a:40}],Scarletite:[{r:"Iron",a:25e4},{r:"Adamantite",a:7500},{r:"Orichalcum",a:500}],Quantium:[{r:"Nano_Tube",a:1e3},{r:"Graphene",a:1e3},{r:"Elerium",a:25}],Thermite:[{r:"Iron",a:180},{r:"Aluminium",a:60}]};if(t.race.wasteful){let t=1+ui.wasteful.vars()[0]/100;Object.keys(e).forEach((function(a){for(let r=0;r=2){let e=t.tech.foundry>=5?t.tech.foundry>=8?.08:.05:.03;er.general.add.push({name:F("city_foundry"),manual:t.city.foundry.count*e,auto:t.city.foundry.count*e})}if(t.tech.foundry>=3&&Object.keys(er).forEach((function(e){t.city.foundry[e]&&t.city.foundry[e]>1&&er[e].add.push({name:F("tech_apprentices"),manual:(t.city.foundry[e]-1)*Me(.03),auto:(t.city.foundry[e]-1)*Me(.03)})})),t.tech.foundry>=4&&t.city.sawmill&&er.Plywood.add.push({name:F("city_sawmill"),manual:.02*t.city.sawmill.count,auto:.02*t.city.sawmill.count}),t.tech.foundry>=6&&er.Brick.add.push({name:F("city_foundry"),manual:.02*t.city.foundry.count,auto:.02*t.city.foundry.count}),t.tech.foundry>=7&&(er.general.add.push({name:F("city_factory")+` (${F("tab_city5")})`,manual:.05*i.factory,auto:.05*i.factory}),t.tech.mars>=4&&er.general.add.push({name:F("city_factory")+` (${F("tab_space")})`,manual:.05*i.red_factory,auto:.05*i.red_factory}),t.interstellar.int_factory&&i.int_factory&&er.general.add.push({name:F("interstellar_int_factory_title"),manual:.1*i.int_factory,auto:.1*i.int_factory})),t.space.fabrication&&c.fabrication&&er.general.add.push({name:F("space_red_fabrication_title"),manual:c.fabrication*t.civic.colonist.workers*Me(e?.05:.02),auto:c.fabrication*t.civic.colonist.workers*Me(e?.05:.02)}),i.stellar_forge&&(er.Mythril.add.push({name:F("interstellar_stellar_forge_title"),manual:.05*i.stellar_forge,auto:.05*i.stellar_forge}),er.general.add.push({name:F("interstellar_stellar_forge_title"),manual:0,auto:.1*i.stellar_forge})),i.hell_forge){let e=Oa("ruins");er.general.add.push({name:F("portal_hell_forge_title"),manual:0,auto:.75*i.hell_forge*e.supress}),er.Scarletite.multi.push({name:F("portal_ruins_supressed"),manual:1,auto:e.supress})}if(t.tauceti.tau_factory&&c.tau_factory&&er.general.add.push({name:F("tau_home_tau_factory"),manual:0,auto:c.tau_factory*(t.tech.isolation?2.75:.9)}),t.tech.isolation&&t.tauceti.colony&&c.colony&&er.general.add.push({name:F("tau_home_colony"),manual:.5*c.colony,auto:.5*c.colony}),c.zero_g_lab&&i.zero_g_lab||c.infectious_disease_lab&&i.infectious_disease_lab){let e=ht("spc_enceladus");er.Quantium.multi.push({name:F("space_syndicate"),manual:1,auto:e})}if(t.tech.alien_crafting&&c.infectious_disease_lab&&i.infectious_disease_lab){let e=1+.65*Math.min(c.infectious_disease_lab,i.infectious_disease_lab);er.Quantium.multi.push({name:F("tech_infectious_disease_lab_alt"),manual:1,auto:e})}if(t.race.crafty&&er.general.add.push({name:F("wiki_arpa_crispr_crafty"),manual:.03,auto:.03}),t.race.ambidextrous&&er.general.add.push({name:F("trait_ambidextrous_name"),manual:ui.ambidextrous.vars()[0]*t.race.ambidextrous/100,auto:ui.ambidextrous.vars()[0]*t.race.ambidextrous/100}),t.race.rigid&&er.general.add.push({name:F("trait_rigid_name"),manual:-ui.rigid.vars()[0]/100,auto:-ui.rigid.vars()[0]/100}),"socialist"===t.civic.govern.type&&er.general.multi.push({name:F("govern_socialist"),manual:1+ae.socialist()[0]/100,auto:1+ae.socialist()[0]/100}),t.race.casting&&t.race.casting.crafting){let e=1+t.race.casting.crafting/(t.race.casting.crafting+75),a=1+2*t.race.casting.crafting/(2*t.race.casting.crafting+75);er.general.multi.push({name:F("modal_pylon_casting"),manual:e,auto:a})}"magic"===t.race.universe&&er.general.multi.push({name:F("universe_magic"),manual:.8,auto:.8}),t.tech.v_train&&er.general.multi.push({name:F("tech_vocational_training"),manual:1,auto:2}),t.genes.crafty&&er.general.multi.push({name:F("tab_arpa_crispr")+" "+F("wiki_arpa_crispr_crafty"),manual:1,auto:1+.5*(t.genes.crafty-1)}),t.race.living_tool&&er.general.multi.push({name:F("trait_living_tool_name"),manual:1,auto:1+ui.living_tool.vars()[1]/100}),t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=1&&er.general.multi.push({name:F("evo_challenge_orbit_decay"),manual:1,auto:1.1}),t.race.ambidextrous&&er.general.multi.push({name:F("trait_ambidextrous_name"),manual:1,auto:1+ui.ambidextrous.vars()[1]*t.race.ambidextrous/100}),t.blood.artisan&&er.general.multi.push({name:F("tab_arpa_blood")+" "+F("arpa_blood_artisan_title"),manual:1,auto:1+t.blood.artisan/100});let a=Dr();a>0&&er.general.multi.push({name:F("faith"),manual:1,auto:1+a/("antimatter"===t.race.universe?1.5:3)}),t.prestige.Plasmid.count>0&&er.general.multi.push({name:F("resource_Plasmid_plural_name"),manual:Br()/8+1,auto:Br()/8+1}),t.genes.challenge&&t.genes.challenge>=2&&er.general.multi.push({name:F("mastery"),manual:1+lc()/(t.race.weak_mastery?50:100),auto:1+lc()/(t.race.weak_mastery?50:100)})}});var er;function tr(e){if(e)switch(e){case"market":jr();break;case"storage":Sr();break;case"ejector":zr();break;case"supply":Tr();break;case"alchemy":Ir()}else jr(),Sr(),zr(),Tr(),Ir()}function ar(e){"market"===e?(tr("market"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;if(a.resource[e].tradable){var r=$(`
    `);$("#market").append(r),ur(`#market-${e}`,r,e,t,!0)}})),sr()):"storage"===e?(tr("storage"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;if(a.resource[e].stackable){var r=$(`
    `);$("#resStorage").append(r),fr(`#stack-${e}`,r,e,t)}})),sr()):"ejector"===e?(tr("ejector"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;Va[e]&&Ar(e,t)}))):"supply"===e?(tr("supply"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;Ja[e]&&Er(e,t)}))):"alchemy"===e&&(tr("alchemy"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let r=a.resource[e].color,s=a.resource[e].tradable;Za[e]&&"magic"===t.race.universe&&(t.resource[e].basic=s,Kr(e,r,s))})))}function rr(e){if("protoplasm"===t.race.species){let a=100;t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1&&(a+=50*(t.stats.achieve.mass_extinction.l-1)),ir("RNA",e,a,1,!1),ir("DNA",e,a,1,!1)}ir("Money",e,1e3,1,!1,!1,"success"),ir(t.race.species,e,0,0,!1,!1,"warning"),ir("Slave",e,0,0,!1,!1,"warning"),ir("Mana",e,0,1,!1,!1,"warning"),ir("Energy",e,0,0,!1,!1,"warning"),ir("Sus",e,0,0,!1,!1,"warning"),ir("Knowledge",e,100,1,!1,!1,"warning"),ir("Zen",e,0,0,!1,!1,"warning"),ir("Crates",e,0,0,!1,!1,"warning"),ir("Containers",e,0,0,!1,!1,"warning"),ir("Food",e,250,1,!0,!0),ir("Lumber",e,200,1,!0,!0),ir("Chrysotile",e,200,1,!0,!0),ir("Stone",e,200,1,!0,!0),ir("Crystal",e,200,1,!0,!0),ir("Furs",e,100,1,!0,!0),ir("Copper",e,100,1,!0,!0),ir("Iron",e,100,1,!0,!0),ir("Aluminium",e,50,1,!0,!0),ir("Cement",e,100,1,!0,!0),ir("Coal",e,50,1,!0,!0),ir("Oil",e,0,1,!0,!1),ir("Uranium",e,10,1,!0,!1),ir("Steel",e,50,1,!0,!0),ir("Titanium",e,50,1,!0,!0),ir("Alloy",e,50,1,!0,!0),ir("Polymer",e,50,1,!0,!0),ir("Iridium",e,0,1,!0,!0),ir("Helium_3",e,0,1,!0,!1),ir("Water",e,0,1,!1,!1,"advanced"),ir("Deuterium",e,0,1,!1,!1,"advanced"),ir("Neutronium",e,0,1,!1,!1,"advanced"),ir("Adamantite",e,0,1,!1,!0,"advanced"),ir("Infernite",e,0,1,!1,!1,"advanced"),ir("Elerium",e,1,1,!1,!1,"advanced"),ir("Nano_Tube",e,0,1,!1,!1,"advanced"),ir("Graphene",e,0,1,!1,!0,"advanced"),ir("Stanene",e,0,1,!1,!0,"advanced"),ir("Bolognium",e,0,1,!1,!0,"advanced"),ir("Vitreloy",e,0,1,!1,!0,"advanced"),ir("Orichalcum",e,0,1,!1,!0,"advanced"),ir("Unobtainium",e,0,1,!1,!1,"advanced"),ir("Materials",e,0,1,!1,!1,"advanced"),ir("Horseshoe",e,-2,0,!1,!1,"advanced"),ir("Nanite",e,0,1,!1,!1,"advanced"),ir("Genes",e,-2,0,!1,!1,"advanced"),ir("Soul_Gem",e,-2,0,!1,!1,"advanced"),ir("Plywood",e,-1,0,!1,!1,"danger"),ir("Brick",e,-1,0,!1,!1,"danger"),ir("Wrought_Iron",e,-1,0,!1,!1,"danger"),ir("Sheet_Metal",e,-1,0,!1,!1,"danger"),ir("Mythril",e,-1,0,!1,!1,"danger"),ir("Aerogel",e,-1,0,!1,!1,"danger"),ir("Nanoweave",e,-1,0,!1,!1,"danger"),ir("Scarletite",e,-1,0,!1,!1,"danger"),ir("Quantium",e,-1,0,!1,!1,"danger"),ir("Corrupt_Gem",e,-2,0,!1,!1,"caution"),ir("Codex",e,-2,0,!1,!1,"caution"),ir("Cipher",e,0,1,!1,!1,"caution"),ir("Demonic_Essence",e,-2,0,!1,!1,"caution"),e||(or("Blood_Stone","caution"),or("Artifact","caution"),or("Plasmid"),or("AntiPlasmid"),or("Phage"),or("Dark"),or("Harmony"),or("AICore"))}function sr(){"protoplasm"!==t.race.species&&(function(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=t.race.no_trade?" nt":"";var a=$(`
    ${F("resource_market_trade_routes")} / {{ mtrade }}
    `);a.append($(`${F("cancel_all_routes")}`)),$("#market").append(a),sc({el:"#tradeTotal",data:t.city.market,methods:{zero(){Object.keys(t.resource).forEach((function(e){t.resource[e].trade&&(t.city.market.trade-=Math.abs(t.resource[e].trade),t.resource[e].trade=0,$r(e))}))}},filters:{tdeCnt(e){let a=$c(17,11);return(100===e&&!t.tech.isolation&&!t.race.cataclysm||10===e&&(t.tech.isolation||t.race.cataclysm))&&a.length>0?"10"+a:e}}}),Ti("tradeTotalPopover",(function(){let e=$('
    ');return r.hasOwnProperty("t_route")&&Object.keys(r.t_route).forEach((function(t){r.t_route[t]>0&&e.append(``)})),e.append(``),e}),{elm:"#tradeTotalPopover > span"})}(),(t.settings.tabLoad||4===t.settings.civTabs&&0===t.settings.marketTabs)&&($("#market").append($(`

    ${F("galaxy_trade")}

    `)),_r()),function(){if(t.settings.tabLoad||4===t.settings.civTabs&&1===t.settings.marketTabs){var e=$(`
    ${F("resource_Crates_name")}{{ cr.amount }} / {{ cr.max }}${F("resource_Containers_name")}{{ cn.amount }} / {{ cn.max }}
    `);$("#resStorage").append(e),sc({el:"#crateTotal",data:{cr:t.resource.Crates,cn:t.resource.Containers}})}}())}function ir(e,r,s,i,c,o,n){if(n=n||"info",t.resource[e]||(t.resource[e]={}),cr(e),t.race.artifical&&"Food"===e&&(o=!1),r)return;var l;t.resource[e].hasOwnProperty("display")||(t.resource[e].display=!1),t.resource[e].hasOwnProperty("value")||(t.resource[e].value=t.race.truepath?2*Qa[e]:Qa[e]),t.resource[e].hasOwnProperty("amount")||(t.resource[e].amount=0),t.resource[e].hasOwnProperty("max")||(t.resource[e].max=s),t.resource[e].hasOwnProperty("diff")||(t.resource[e].diff=0),t.resource[e].hasOwnProperty("delta")||(t.resource[e].delta=0),t.resource[e].hasOwnProperty("rate")||(t.resource[e].rate=i),"Mana"===e&&(t.resource[e].gen=0,t.resource[e].gen_d=0),t.resource[e].stackable=o,t.resource[e].crates||(t.resource[e].crates=0),t.resource[e].containers||(t.resource[e].containers=0),!t.resource[e].trade&&c&&(t.resource[e].trade=0),l=-1===t.resource[e].max||-2===t.resource[e].max?$(`

    {{ name | namespace }}

    {{ amount | diffSize }}
    `):$(`

    {{ name | namespace }}

    {{ amount | size }} / {{ max | size }}
    `),o?l.append($(`+`)):(-1!==s||-1===s&&0===i&&t.race.no_craft||"Scarletite"===e||"Quantium"===e)&&l.append($(""));let u=!1;if(0!==i||-1===s&&0===i&&t.race.no_craft||"Scarletite"===e||"Quantium"===e)l.append($(`{{ diff | diffSize }} /s`));else if(-1!==s||t.race.no_craft||"Scarletite"===e||"Quantium"===e)l.append($(""));else{let t=$('');l.append(t);let a=[1,5];for(let r=0;r+${a[r]}`));t.append($(`+A`)),u=!0}$("#resources").append(l);var d={template:''};if(sc({el:`#res${e}`,data:t.resource[e],filters:{size:function(e){return e?k(e,0):e},diffSize:function(a){return"Horseshoe"===e&&!t.race.hooved&&Tc("fool",2023)&&(a=5),k(a,2)},namespace:e=>e.replace("_"," ")},methods:{resRate:e=>`${e} ${k(t.resource[e].diff,2)} per second`,trigModal(){this.$buefy.modal.open({parent:this,component:d});var a=setInterval((function(){$("#modalBox").length>0&&(clearInterval(a),function(e){$("#modalBox").append($('

    {{ name }} - {{ amount | size }}/{{ max | size }}

    '));let a=$('
    ');if($("#modalBox").append(a),"Food"===e&&!t.race.artifical||t.race.artifical&&"Coal"===e){let e=$c(7,10);e.length>0&&$("#modalBoxTitle").prepend(e)}if("Stone"===e){let e=kc(1,12,!1);e.length>0&&$("#modalBoxTitle").prepend(e)}let r=$('
    ');a.append(r),r.append($(`
    ${F("resource_modal_crate_owned")} {{ crates.amount }}/{{ crates.max }}${F("resource_modal_crate_assigned")} {{ res.crates }}
    `));let s=$(``),i=$(``),c=$(``);if(r.append(s),r.append(i),r.append(c),sc({el:"#modalCrates",data:{crates:t.resource.Crates,res:t.resource[e]},methods:{buildCrate(){Mr()},subCrate(e){pr(e)},addCrate(e){hr(e)}}}),t.resource.Containers.display){let r=$('
    ');a.append(r),r.append($(`
    ${F("resource_modal_container_owned")} {{ containers.amount }}/{{ containers.max }}${F("resource_modal_container_assigned")} {{ res.containers }}
    `));let s=$(``),i=$(``),c=$(``);r.append(s),r.append(i),r.append(c),sc({el:"#modalContainers",data:{containers:t.resource.Containers,res:t.resource[e]},methods:{buildContainer(){Pr()},removeContainer(e){mr(e)},addContainer(e){gr(e)}}})}sc({el:"#modalBoxTitle",data:t.resource[e],filters:{size:function(e){return k(e,0)},diffSize:function(e){return k(e,2)}}}),["modalCrates","modalContainers"].forEach((function(e){["assign","unassign","construct"].forEach((function(t){Ti(`${e}${t}`,function(e,t){if("modalContainers"===e){let e=Cr();switch(t){case"assign":return F("resource_modal_container_assign_desc",[e]);case"unassign":return F("resource_modal_container_unassign_desc",[e]);case"construct":return kr()}}else{let e=Or();switch(t){case"assign":return F("resource_modal_crate_assign_desc",[e]);case"unassign":return F("resource_modal_crate_unassign_desc",[e]);case"construct":return xr()}}}(e,t),{elm:$(`#${e} > .${t}`),attach:"#main"})}))}))}(e))}),50)},showTrigger:()=>t.resource.Crates.display,craft(e,a){if(!t.race.no_craft){let r=Xa(e,"manual").multiplier,s=Ya(),i=Math.floor(t.resource[s[e][0].r].amount/s[e][0].a);for(let a=1;a${t.resource[s[e][i].r].name} ${c}`}return r}}}),wr(`cnt${e}`,e,"c"),u){let a=[1,5,"A"];for(let r=0;r"),i=e,c=a[r],o=+(100*Xa(i,"manual").multiplier).toFixed(0);s.append($(`
    ${F("manual_crafting_hover_bonus",[o.toLocaleString(),t.resource[i].name])}
    `));let n=Ya(),l=$(`
    ${F("manual_crafting_hover_craft")}
    `),u=0;if("number"!=typeof c){if(u=t.resource[n[i][0].r].amount/n[i][0].a,n[i].length>1)for(let e=1;e${k(o/100*u,1)} ${t.resource[i].name}`))}else{u=y()*c;let e=k(o/100*u,1);l.append($(`${e} ${t.resource[i].name}`))}let d=$(`
    ${F("manual_crafting_hover_use")}
    `);for(let e=0;e${k(u*n[i][e].a,1)} ${t.resource[n[i][e].r].name}`)),e+1, "));return s.append(l),s.append(d),s};br(`inc${e}${a[r]}`,e,"manual",s)}}o&&Ti(`con${e}`,(function(){var a=$(`
    ${F("resource_Crates_plural")} ${t.resource[e].crates}
    `);return t.tech.steel_container&&a.append($(`
    ${F("resource_Containers_plural")} ${t.resource[e].containers}
    `)),a})),e!==t.race.species&&"Crates"!==e&&"Containers"!==e&&-1!==s?wr(`inc${e}`,e,"p"):-1===s&&br(`inc${e}`,e,"auto"),$(`#res${e}`).on("mouseover",(function(){$(`.res-${e}`).each((function(){t.resource[e].amount>=$(this).attr(`data-${e}`)?$(this).addClass("hl-ca"):$(this).addClass("hl-cna")}))})),$(`#res${e}`).on("mouseout",(function(){$(`.res-${e}`).each((function(){$(this).removeClass("hl-ca"),$(this).removeClass("hl-cna")}))})),void 0===a.resource&&(a.resource={}),a.resource[e]={color:n,tradable:c,stackable:o}}function cr(e){if(e===t.race.species?t.resource[e].name=Ac("name"):t.resource[e].name="Money"===e?"$":F(`resource_${e}_name`),Tc("fool",2022))switch(e){case"Lumber":t.resource[e].name=F("resource_Stone_name");break;case"Stone":t.resource[e].name=F("resource_Lumber_name");break;case"Copper":t.resource[e].name=F("resource_Iron_name");break;case"Iron":t.resource[e].name=F("resource_Copper_name");break;case"Steel":t.resource[e].name=F("resource_Titanium_name");break;case"Titanium":t.resource[e].name=F("resource_Steel_name");break;case"Coal":t.resource[e].name=F("resource_Oil_name");break;case"Oil":t.resource[e].name=F("resource_Coal_name");break;case"Alloy":t.resource[e].name=F("resource_Polymer_name");break;case"Polymer":t.resource[e].name=F("resource_Alloy_name");break;case"Graphene":t.resource[e].name=F("resource_Stanene_name");break;case"Stanene":t.resource[e].name=F("resource_Graphene_name");break;case"Plywood":t.resource[e].name=F("resource_Brick_name");break;case"Brick":t.resource[e].name=F("resource_Plywood_name");break;case"Genes":t.resource[e].name=F("resource_Soul_Gem_name");break;case"Soul_Gem":t.resource[e].name=F("resource_Genes_name");break;case"Slave":t.resource[e].name=F("resource_Peon_name")}if("Horseshoe"===e&&(t.resource[e].name=Bc()),t.race.artifical&&"Genes"===e&&(t.resource[e].name=F("resource_Program_name")),t.race.sappy)"Stone"===e&&(t.resource[e].name=F("resource_Amber_name"));else if(t.race.flier)switch(e){case"Stone":t.resource[e].name=F("resource_Clay_name");break;case"Brick":t.resource[e].name=F("resource_Mud_Brick_name")}if(t.race.soul_eater&&"Food"===e&&(t.resource[e].name=F("resource_Souls_name")),t.race.evil)switch(e){case"Lumber":t.resource[e].name=F("resource_Bones_name");break;case"Furs":t.resource[e].name=F("resource_Flesh_name");break;case"Plywood":t.resource[e].name=F("resource_Boneweave_name")}if(t.race.artifical&&"Food"===e&&(t.resource[e].name=F("resource_Signal_name")),Tc("halloween").active)switch(e){case"Food":t.resource[e].name=F("resource_Candy_name");break;case"Lumber":t.resource[e].name=F("resource_Bones_name");break;case"Stone":t.resource[e].name=F("resource_RockCandy_name");break;case"Furs":t.resource[e].name=F("resource_Webs_name");break;case"Plywood":t.resource[e].name=F("resource_Boneweave_name");break;case"Brick":t.resource[e].name=F("resource_Tombstone_name");break;case"Soul_Gem":t.resource[e].name=F("resource_CandyCorn_name")}}function or(e,a){if($(`#res${e}`).length){let t=$(`#res${e}`);return t.detach(),void $("#resources").append(t)}a=a||"special";var r=$(`
    ${F(`resource_${e}_name`)}{{ count | round }}
    `);$("#resources").append(r),sc({el:`#res${e}`,data:t.prestige[e],filters:{round:e=>+e.toFixed(3)}}),"Artifact"!==e&&"Blood_Stone"!==e&&Ti(`res${e}`,(function(){let a=$("
    ");switch(e){case"Plasmid":let r=t.race.no_plasmid?Math.min(t.race.p_mutation,t.prestige.Plasmid.count):t.prestige.Plasmid.count;if(a.append($(`${F(`resource_${e}_desc`,[r,+(100*Br("plasmid")).toFixed(2)])}`)),t.genes.store&&("antimatter"!==t.race.universe||t.genes.bleed>=3)){let e=Lr(1,"plasmid");e>1&&a.append($(` ${F("resource_Plasmid_desc2",[+(100*(e-1)).toFixed(2)])}`))}break;case"AntiPlasmid":a.append($(`${F(`resource_${e}_desc`,[t.prestige.AntiPlasmid.count,+(100*Br("antiplasmid")).toFixed(2)])}`));let s=Lr(1,"anti");t.genes.store&&("antimatter"===t.race.universe||t.genes.bleed>=3)&&s>1&&a.append($(` ${F("resource_Plasmid_desc2",[+(100*(s-1)).toFixed(2)])}`));break;case"Phage":a.append($(`${F(t.prestige.AntiPlasmid.count>0?"resource_Phage_desc2":"resource_Phage_desc",[250+t.prestige.Phage.count])}`));let i=Lr(1,"phage");t.genes.store&&t.genes.store>=4&&i>1&&a.append($(` ${F("resource_Plasmid_desc2",[+(100*(i-1)).toFixed(2)])}`));break;case"Dark":switch(t.race.universe){case"standard":a.append($(`${F(`resource_${e}_desc_s`,[+(100*(nc("standard")-1)).toFixed(2)])}`));break;case"evil":a.append($(`${F(`resource_${e}_desc_e`,[+(100*(nc("evil")-1)).toFixed(2)])}`));break;case"micro":a.append($(`${F(`resource_${e}_desc_m`,[nc("micro",!1),nc("micro",!0)])}`));break;case"heavy":let t=nc("heavy"),r=.25+.5*t,s=.2+.3*t;a.append($(`${F(`resource_${e}_desc_h`,[+(100*r).toFixed(4),+(100*s).toFixed(4)])}`));break;case"antimatter":a.append($(`${F(`resource_${e}_desc_a`,[+(100*(nc("antimatter")-1)).toFixed(2)])}`));break;case"magic":a.append($(`${F(`resource_${e}_desc_mg`,[F("resource_Mana_name"),+(100*(nc("magic")-1)).toFixed(2)])}`))}break;case"Harmony":a.append($(`${F(`resource_${e}_desc`,["standard"===t.race.universe?.1:1,ec()])}`));break;case"AICore":let c=+(100*(1-.99**t.prestige.AICore.count)).toFixed(2);a.append($(`${F(`resource_${e}_desc`,[c])}`))}return a}))}function nr(e){let a=t.tech.currency>=6?-1e6:t.tech.currency>=4?-100:-25;if(t.race.banana){let r=!1;if(Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&t.resource[e].trade<0&&(r=e)})),r&&r!==e)return!1;a=t.tech.currency>=6?-1e6:t.tech.currency>=4?-25:-10}return!(t.resource[e].trade<=a)}function lr(e){let a=t.tech.currency>=6?1e6:t.tech.currency>=4?100:25;return!(t.resource[e].trade>=a)}function ur(e,a,r,s,i){if((t.settings.tabLoad||4===t.settings.civTabs&&0===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==r)){if(i&&a.append($(`

    {{ r.name | namespace }}

    `)),t.race.no_trade||(a.append($(`${F("resource_market_buy")}`)),a.append($(`\${{ r.value | buy }}`)),a.append($(`${F("resource_market_sell")}`)),a.append($(`\${{ r.value | sell }}`))),i&&(t.race.banana&&"Food"===r||t.tech.trade&&!t.race.terrifying)){let e=$(`${F("resource_market_routes")}`);a.append(e),e.append($(`-`)),e.append($('')),e.append($(`+`)),e.append($(`${F("cancel_routes")}`)),$r(r)}sc({el:e,data:{r:t.resource[r],m:t.city.market},methods:{aSell(e){let a=1===Za[e]?F("resource_market_unit"):F("resource_market_units"),r=vr(e),s=Za[e];if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),s*=1-e/100}return s=+s.toFixed(3),F("resource_market_auto_sell_desc",[s,a,r])},aBuy(e){let a=Za[e],r=N("dealmaker",0);r&&(a*=1+r/100),t.race.persuasive&&(a*=1+t.race.persuasive/100),t.race.merchant&&(a*=1+ui.merchant.vars()[1]/100);let s=Pi("goblin");if(s>0&&(a*=1+ui.merchant.vars(1)[1]/100*s),t.genes.trader&&(a*=1+lc()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1+e/50}t.race.truepath&&(a*=1-t.civic.foreign.gov3.hstl/101),a=+a.toFixed(3);let i=F(1===a?"resource_market_unit":"resource_market_units");return F("resource_market_auto_buy_desc",[a,i,yr(e)])},purchase(e){if(!t.race.no_trade&&!t.settings.pause){let a=t.city.market.qty,r=t.resource[e].value;t.race.arrogant&&(r*=1+ui.arrogant.vars()[0]/100),t.race.conniving&&(r*=1-ui.conniving.vars()[0]/100);let s=Pi("imp");s>0&&(r*=1-ui.conniving.vars(1)[0]/100*s);let i=Math.floor(Math.min(a,t.resource.Money.amount/r,t.resource[e].max-t.resource[e].amount));i>0&&(t.resource[e].amount+=i,t.resource.Money.amount-=Math.round(r*i),t.resource[e].value+=Number((i/Math.rand(1e3,1e4)).toFixed(2)))}},sell(e){if(!t.race.no_trade&&!t.settings.pause){let a=t.city.market.qty,r=4;t.race.merchant&&(r*=1-ui.merchant.vars()[0]/100);let s=Pi("goblin");s>0&&(r*=1-ui.merchant.vars(1)[0]/100*s),t.race.asymmetrical&&(r*=1+ui.asymmetrical.vars()[0]/100),t.race.conniving&&(r*=1-ui.conniving.vars()[1]/100);let i=Pi("imp");i>0&&(r*=1-ui.conniving.vars(1)[1]/100*i);let c=t.resource[e].value/r,o=Math.floor(Math.min(a,t.resource[e].amount,(t.resource.Money.max-t.resource.Money.amount)/c));o>0&&(t.resource[e].amount-=o,t.resource.Money.amount+=Math.round(c*o),t.resource[e].value-=Number((o/Math.rand(1e3,1e4)).toFixed(2)),t.resource[e].value0&&(a+=t.resource[r].trade)})),e<=a)break}if(t.resource[e].trade>=0){if(!(lr(e)&&t.city.market.trade(t.race.arrogant&&(e*=1+ui.arrogant.vars()[0]/100),k(e*t.city.market.qty,0)),sell(e){let a=4;t.race.merchant&&(a*=1-ui.merchant.vars()[0]/100);let r=Pi("goblin");return r>0&&(a*=1-ui.merchant.vars(1)[0]/100*r),t.race.asymmetrical&&(a*=1+ui.asymmetrical.vars()[0]/100),k(e*t.city.market.qty/a,0)},trade(e){if("Stone"===r&&(31===e||-31===e)){let e=kc(3,12,!1);if(e.length>0)return e}return e<0?"-"+(e=0-e):e>0?`+${e}`:0},namespace:e=>e.replace("_"," ")}})}}function dr(){return[{buy:{res:"Deuterium",vol:5},sell:{res:"Helium_3",vol:25}},{buy:{res:"Neutronium",vol:2.5},sell:{res:"Copper",vol:200}},{buy:{res:"Adamantite",vol:3},sell:{res:"Iron",vol:300}},{buy:{res:"Elerium",vol:1},sell:{res:"Oil",vol:125}},{buy:{res:"Nano_Tube",vol:10},sell:{res:"Titanium",vol:20}},{buy:{res:"Graphene",vol:25},sell:{res:t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Lumber",vol:1e3}},{buy:{res:"Stanene",vol:40},sell:{res:"Aluminium",vol:800}},{buy:{res:"Bolognium",vol:.75},sell:{res:"Uranium",vol:4}},{buy:{res:"Vitreloy",vol:1},sell:{res:"Infernite",vol:1}}]}function _r(e){let a=e||$("#galaxyTrade");if(e||rc($("#galaxyTrade")),t.galaxy.trade){a.append($(`
    ${F("galaxy_trade")}
    `));let e=dr();for(let r=0;r');a.append(s),s.append($(`${t.resource[e[r].buy.res].name}`)),s.append($(`+{{ '${r}' | t_vol }}/s`)),s.append($(`${t.resource[e[r].sell.res].name}`)),s.append($(`-{{ '${r}' | s_vol }}/s`));let i=$(`${F("resource_market_routes")}`);s.append(i);let c=F("galaxy_freighter_assign",[t.resource[e[r].buy.res].name,t.resource[e[r].sell.res].name]),o=F("galaxy_freighter_unassign",[t.resource[e[r].buy.res].name,t.resource[e[r].sell.res].name]);i.append($(`-`)),i.append($(`{{ g.f${r} }}`)),i.append($(`+`)),i.append($(`${F("cancel_routes")}`))}let r=$(`
    ${F("resource_market_galactic_trade_routes")} {{ g.cur }} / {{ g.max }}
    `);r.append($(`${F("cancel_all_routes")}`)),a.append(r)}sc({el:e?"#specialModal":"#galaxyTrade",data:{g:t.galaxy.trade,t:t.tech},methods:{less(e){let a=y();t.galaxy.trade[`f${e}`]>=a?(t.galaxy.trade[`f${e}`]-=a,t.galaxy.trade.cur-=a):(t.galaxy.trade.cur-=t.galaxy.trade[`f${e}`],t.galaxy.trade[`f${e}`]=0)},more(e){let a=y();t.galaxy.trade.curt.galaxy.trade.max-t.galaxy.trade.cur&&(a=t.galaxy.trade.max-t.galaxy.trade.cur),t.galaxy.trade[`f${e}`]+=a,t.galaxy.trade.cur+=a)},zero(e){if(e)t.galaxy.trade.cur-=t.galaxy.trade[`f${e}`],t.galaxy.trade[`f${e}`]=0;else{let e=dr();for(let a=0;ae},filters:{t_vol(e){let a=dr()[e].buy.vol;t.race.persuasive&&(a*=1+t.race.persuasive/100),t.race.merchant&&(a*=1+ui.merchant.vars()[1]/100);let r=Pi("goblin");if(r>0&&(a*=1+ui.merchant.vars(1)[1]/100*r),t.genes.trader&&(a*=1+lc()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1+e/50}return a=+a.toFixed(2),a},s_vol(e){let a=dr()[e].sell.vol;if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1-e/100}return a=+a.toFixed(2),a}}}),Ti("galacticTradeTotal",(function(){let e=$('
    ');return r.hasOwnProperty("gt_route")&&Object.keys(r.gt_route).forEach((function(t){r.gt_route[t]>0&&e.append(``)})),e.append(``),e}),{elm:"#galacticTradeTotal > span"})}function pr(e){let a=y(),r=Or();a>t.resource[e].crates&&(a=t.resource[e].crates),a>0&&(t.resource.Crates.amount+=a,t.resource.Crates.max+=a,t.resource[e].crates-=a,t.resource[e].max-=r*a)}function hr(e){let a=y(),r=Or();a>t.resource.Crates.amount&&(a=t.resource.Crates.amount),a>0&&(t.resource.Crates.amount-=a,t.resource.Crates.max-=a,t.resource[e].crates+=a,t.resource[e].max+=r*a)}function mr(e){let a=y(),r=Cr();a>t.resource[e].containers&&(a=t.resource[e].containers),a>0&&(t.resource.Containers.amount+=a,t.resource.Containers.max+=a,t.resource[e].containers-=a,t.resource[e].max-=r*a)}function gr(e){let a=y(),r=Cr();a>t.resource.Containers.amount&&(a=t.resource.Containers.amount),a>0&&(t.resource.Containers.amount-=a,t.resource.Containers.max-=a,t.resource[e].containers+=a,t.resource[e].max+=r*a)}function fr(e,a,r,s){if(t.settings.tabLoad||4===t.settings.civTabs&&1===t.settings.marketTabs){if(a.append($(`

    {{ name }}

    `)),t.resource.Crates.display){let e=$(`${F("resource_Crates_name")}`);a.append(e),e.append($(`«`)),e.append($(``)),e.append($(`»`))}if(t.resource.Containers.display){let e=$(`${F("resource_Containers_name")}`);a.append(e),e.append($(`«`)),e.append($('')),e.append($(`»`))}sc({el:e,data:t.resource[r],methods:{addCrate(e){hr(e)},subCrate(e){pr(e)},addCon(e){gr(e)},subCon(e){mr(e)}},filters:{trick(e){if("Stone"===r&&10===t.resource[r].crates&&31===t.resource[r].containers){let e=kc(4,13,!0);if(e.length>0)return e}return e},cCnt(e,a){if("Food"===a&&!t.race.artifical||t.race.artifical&&"Coal"===a){let t=$c(13,10);if(10===e&&t.length>0)return"1"+t}return e}}})}}function vr(e){let a=4;t.race.merchant&&(a*=1-ui.merchant.vars()[0]/100);let r=Pi("goblin");r>0&&(a*=1-ui.merchant.vars(1)[0]/100*r),t.race.asymmetrical&&(a*=1+ui.asymmetrical.vars()[0]/100),t.race.conniving&&a--;let s=t.resource[e].value*Za[e]/a;if(t.city.wharf&&(s*=1+.01*t.city.wharf.count),t.space.gps&&t.space.gps.count>3&&(s*=1+.01*t.space.gps.count),t.tech.railway){let e=t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?.03:.02;s*=1+t.tech.railway*e}return t.race.truepath&&!t.race.lone_survivor&&(s*=1-t.civic.foreign.gov3.hstl/101),t.race.inflation&&(s*=1+t.race.inflation/500),t.race.witch_hunter&&t.resource.Sus.amount>50&&(s*=1-(t.resource.Sus.amount-50)/52),s*=Pe("psychic_cash"),s=+s.toFixed(1),s}function yr(e){let a=t.resource[e].value;t.race.arrogant&&(a*=1+ui.arrogant.vars()[0]/100),t.race.conniving&&(a*=1-ui.conniving.vars()[0]/100);let r=Pi("imp");r>0&&(a*=1-ui.conniving.vars(1)[0]/100*r);let s=a*Za[e];return t.city.wharf&&(s*=.99**t.city.wharf.count),t.space.gps&&t.space.gps.count>3&&(s*=.99**t.space.gps.count),t.tech.railway&&(s*=(t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?.97:.98)**t.tech.railway),t.race.truepath&&!t.race.lone_survivor&&(s*=1+t.civic.foreign.gov3.hstl/101),t.race.inflation&&(s*=1+t.race.inflation/300),t.race.quarantine&&(s*=1+Math.round(t.race.quarantine**3.5)),t.race.witch_hunter&&t.resource.Sus.amount>50&&(s*=1+(t.resource.Sus.amount-50)/8),s=+s.toFixed(1),s}function br(e,a,s,i){Ti(`${e}`,(function(){let e=$('
    {{ res.name | namespace }}
    '),c=$('
    ');e.append(c);let o=Xa(a,s),n=$("
    ");c.append(n),"auto"===s&&r.p[a]&&Object.keys(r.p[a]).forEach((function(e){let t=r.p[a][e],s=parseFloat(t.slice(0,-1));if(0!=s&&!isNaN(s)){let t=s>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),n.append(``)}})),Object.keys(o.multi_bd).forEach((function(e){let t=o.multi_bd[e],a=parseFloat(t.slice(0,-1));if(0!=a&&!isNaN(a)){let t=a>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),n.append(``)}}));let l=$('
    '),u=$(`
    ${F("craft_tools_multi")}
    `);l.append(u);let d=0;if(Object.keys(o.add_bd).forEach((function(e){let t=o.add_bd[e],a=parseFloat(t.slice(0,-1));if(0!=a&&!isNaN(a)){d++;let t=a>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),l.append(``)}})),d>0&&c.append(l),r.p.consume&&r.p.consume[a]){let e=$('
    '),t=0;Object.keys(r.p.consume[a]).forEach((function(s){let i=r.p.consume[a][s];if(0!=i&&!isNaN(i)){t++;let r=i>0?"success":"danger",c=s.replace(/\+.+$/,"");s=s.replace(/'/g,"\\'"),e.append(``)}})),t>0&&c.append(e)}return t.resource[a].diff<0&&t.resource[a].amount>0&&e.append(``),i&&(e.append(''),e.append(i)),e}),{in:function(){sc({el:"#popper > div",data:{[a]:r.p[a],res:t.resource[a],consume:r.p.consume,craft:Xa(a,s)},filters:{translate(e){let t=e[e.length-1],a=parseFloat(e.slice(0,-1)),r=a>0&&a<1||a<0&&a>-1?4:a>0&&a<10||a<0&&a>-10?3:2;a=+a.toFixed(r);let s="%"===t?"%":"";return a>0?"+"+k(a,r)+s:a<0?k(a,r)+s:void 0},fix:e=>e+"v",counter(e){let r=+(e/-t.resource[a].diff).toFixed(0);if(r>60){let e=r%60,t=(r-e)/60;if(t>=60){let e=t%60;return`${(t-e)/60}h ${e}m`}return`${t}m ${e}s`}return`${r}s`},namespace:e=>e.replace("_"," ")}})},out:function(){sc({el:"#popper > div"},"destroy")},classes:"breakdown has-background-light has-text-dark",prop:{modifiers:{preventOverflow:{enabled:!1},hide:{enabled:!1}}}})}function wr(e,a,s){Ti(`${e}`,(function(){let e=$('
    {{ res.name | namespace }}
    '),i=$('
    ');e.append(i);let c=!1;if(r[s][a]){let e=$("
    ");i.append(e);let t=[a];t.push("Global");for(var o=0;o0?"success":"danger",s=t.replace(/\+.+$/,"");t=t.replace(/'/g,"\\'"),e.append(``)}}))}}if(r[s].consume&&r[s].consume[a]){let e=$(`
    `),t=0;Object.keys(r[s].consume[a]).forEach((function(i){let c=r[s].consume[a][i];if(0!=c&&!isNaN(c)){t++;let r=c>0?"success":"danger",s=i.replace(/\+.+$/,"");i=i.replace(/'/g,"\\'"),e.append(``)}})),t>0&&i.append(e)}if("p"===s){let r=t.resource[a].diff>0?"success":"danger";e.append(``)}return e}),{in:function(){sc({el:"#popper > div",data:{Global:r[s].Global,[a]:r[s][a],consume:r[s].consume,res:t.resource[a]},filters:{translate(e){let t=e[e.length-1],a=parseFloat(e.slice(0,-1)),r=a>0&&a<1||a<0&&a>-1?4:a>0&&a<10||a<0&&a>-10?3:2,s="%"===t?"%":"";return a>0?"+"+k(a,r)+s:a<0?k(a,r)+s:void 0},fix:e=>e+"v",counter(e){let r=t.resource[a].diff,s=0;if(r<0?(r*=-1,s=+(e/r).toFixed(0)):s=+((t.resource[a].max-e)/r).toFixed(0),s===1/0||Number.isNaN(s))return"Never";if(s>60){let e=s%60,t=(s-e)/60;if(t>=60){let e=t%60;return`${(t-e)/60}h ${e}m`}return`${t}m ${e}s`}return`${s}s`},direction:e=>F(e>=0?"to_full":"to_empty"),namespace:e=>e.replace("_"," ")}})},out:function(){sc({el:"#popper > div"},"destroy")},classes:"breakdown has-background-light has-text-dark",prop:{modifiers:{preventOverflow:{enabled:!1},hide:{enabled:!1}}}})}function $r(e){$(`#market-${e} .trade .current`).removeClass("has-text-warning"),$(`#market-${e} .trade .current`).removeClass("has-text-danger"),$(`#market-${e} .trade .current`).removeClass("has-text-success"),t.resource[e].trade>0?$(`#market-${e} .trade .current`).addClass("has-text-success"):t.resource[e].trade<0?$(`#market-${e} .trade .current`).addClass("has-text-danger"):$(`#market-${e} .trade .current`).addClass("has-text-warning")}function xr(){let e=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?t.resource.Chrysotile.name:t.resource.Stone.name:t.resource.Plywood?t.resource.Plywood.name:F("resource_Plywood_name");return F("resource_modal_crate_construct_desc",[t.race.kindling_kindred||t.race.smoldering?200:10,e,Or()])}function kr(){return F("resource_modal_container_construct_desc",[125,Cr()])}function qr(e,t){switch(e){case"crate":Mr(t);break;case"container":Pr(t)}}function Mr(e){let a=e||y(),r=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood",s=t.race.kindling_kindred||t.race.smoldering?200:10;a+t.resource.Crates.amount>t.resource.Crates.max&&(a=t.resource.Crates.max-t.resource.Crates.amount),t.resource[r].amount=s*a&&t.resource.Crates.amountt.resource.Containers.max&&(a=t.resource.Containers.max-t.resource.Containers.amount),t.resource.Steel.amount<125*a&&(a=Math.floor(t.resource.Steel.amount/125)),t.resource.Steel.amount>=125*a&&t.resource.Containers.amount=2?500:350;t.tech.container&&t.tech.container>=4&&(e+=t.tech.container>=5?500:250),t.tech.container&&t.tech.container>=6&&(e+=t.tech.container>=7?1200:500),t.tech.container&&t.tech.container>=8&&(e+=4e3),t.race.pack_rat&&(e*=1+ui.pack_rat.vars()[0]/100);let a=Pi("kobold");return a>0&&(e*=1+ui.pack_rat.vars(1)[0]/100*a),t.stats.achieve.banana&&t.stats.achieve.banana.l>=3&&(e*=1.1),e*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,Math.round(Lr(e))}function Cr(){let e=t.tech.steel_container&&t.tech.steel_container>=3?1200:800;t.tech.steel_container&&t.tech.steel_container>=4&&(e+=t.tech.steel_container>=5?1e3:400),t.tech.steel_container&&t.tech.steel_container>=6&&(e+=t.tech.steel_container>=7?7500:1e3),t.tech.steel_container&&t.tech.steel_container>=8&&(e+=8e3),t.race.pack_rat&&(e*=1+ui.pack_rat.vars()[0]/100);let a=Pi("kobold");return a>0&&(e*=1+ui.pack_rat.vars(1)[0]/100*a),e*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,Math.round(Lr(e))}function jr(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=$(`

    ${F("resource_market")}

    `);rc($("#market")),$("#market").append(e),function(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=$("#market-qty");rc(e),t.race.no_trade||(e.append($(`

    ${F("resource_trade_qty")}

    `)),e.append($('-+'))),sc({el:"#market-qty",data:t.city.market,methods:{val(){t.city.market.qty<1?t.city.market.qty=1:t.city.market.qty>Fr()&&(t.city.market.qty=Fr())},limit:()=>Fr(),less(){t.city.market.qty-=y()},more(){t.city.market.qty+=y()}}})}()}function Sr(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||1!==t.settings.marketTabs))return;let e=$(`

    ${F("tab_storage")}

    `);rc($("#resStorage")),$("#resStorage").append(e),t.resource.Crates&&t.resource.Containers&&(e.append($(``)),e.append($(``)),sc({el:"#createHead",data:{cr:t.resource.Crates,cn:t.resource.Containers},methods:{crate(){Mr()},container(){Pr()},buildCrateDesc:()=>xr(),buildContainerDesc:()=>kr()}}))}function Fr(){return t.tech.currency>=6?1e6:t.tech.currency>=4?5e3:100}function zr(){if((t.settings.tabLoad||4===t.settings.civTabs&&2===t.settings.marketTabs)&&(rc($("#resEjector")),t.interstellar.mass_ejector)){let e=$(`

    ${F("interstellar_mass_ejector_vol")}

    `);$("#resEjector").append(e);let a=$('');e.append(a),a.append($(`{{ total }} / {{ on | max }}{{ on | real }}${F("interstellar_mass_ejector_mass")}: {{ mass | approx }} kt/s`)),sc({el:"#eject",data:t.interstellar.mass_ejector,filters:{max:e=>1e3*e,real:e=>i.mass_ejectork(e,2)}})}}function Ar(e,a){if((t.settings.tabLoad||4===t.settings.civTabs&&2===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==e)&&Va[e]&&t.interstellar.mass_ejector){"magic"===t.race.universe||"Elerium"!==e&&"Infernite"!==e||(a="caution");let r=$(`

    ${t.resource[e].name}

    `);$("#resEjector").append(r);let s=$('');r.append(s),s.append($(`«`)),s.append($(`{{ e.${e} }}`)),s.append($(`»`)),s.append($(`${F("interstellar_mass_ejector_per")}: ${Va[e]} kt`)),t.interstellar.mass_ejector.hasOwnProperty(e)||(t.interstellar.mass_ejector[e]=0),sc({el:`#eject${e}`,data:{r:t.resource[e],e:t.interstellar.mass_ejector},methods:{ejectMore(e){let a=y();a+t.interstellar.mass_ejector.total>1e3*i.mass_ejector&&(a=1e3*i.mass_ejector-t.interstellar.mass_ejector.total),t.interstellar.mass_ejector[e]+=a,t.interstellar.mass_ejector.total+=a},ejectLess(e){let a=y();a>t.interstellar.mass_ejector[e]&&(a=t.interstellar.mass_ejector[e]),t.interstellar.mass_ejector[e]>0&&(t.interstellar.mass_ejector[e]-=a,t.interstellar.mass_ejector.total-=a)}}})}}function Tr(){if((t.settings.tabLoad||4===t.settings.civTabs&&3===t.settings.marketTabs)&&(rc($("#resCargo")),t.portal.transport)){let e=$(`

    ${F("portal_transport_supply")}

    `);$("#resCargo").append(e);let a=$('{{ used }} / {{ max }}');e.append(a),sc({el:"#spireSupply",data:t.portal.transport.cargo})}}function Er(e,a){if((t.settings.tabLoad||4===t.settings.civTabs&&3===t.settings.marketTabs)&&Ja[e]&&t.portal.transport){let r=$(`

    ${t.resource[e].name}

    `);$("#resCargo").append(r);let s=$('');r.append(s),s.append($(`«`)),s.append($(`{{ e.${e} }}`)),s.append($(`»`));let i=k(Ja[e].out);s.append($(`${F("portal_transport_item",[`${i}`,`${Ja[e].in}`])}`)),t.portal.transport.cargo.hasOwnProperty(e)||(t.portal.transport.cargo[e]=0),sc({el:`#supply${e}`,data:{r:t.resource[e],e:t.portal.transport.cargo},methods:{supplyMore(e){let a=y();a+t.portal.transport.cargo.used>t.portal.transport.cargo.max&&(a=t.portal.transport.cargo.max-t.portal.transport.cargo.used,t.portal.transport.cargo[e]+a<0&&(a=-t.portal.transport.cargo[e])),t.portal.transport.cargo[e]+=a,t.portal.transport.cargo.used+=a},supplyLess(e){let a=y();a>t.portal.transport.cargo[e]&&(a=t.portal.transport.cargo[e]),t.portal.transport.cargo[e]>0&&(t.portal.transport.cargo[e]-=a,t.portal.transport.cargo.used-=a)}}})}}function Ir(){(t.settings.tabLoad||4===t.settings.civTabs&&4===t.settings.marketTabs)&&rc($("#resAlchemy"))}function Kr(e,a,r){if((t.settings.tabLoad||4===t.settings.civTabs&&4===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==e)&&t.tech.alchemy&&(r||t.tech.alchemy>=2)&&"Crystal"!==e){let s=$(`

    ${t.resource[e].name}

    `);$("#resAlchemy").append(s);let i=$('');s.append(i),i.append($(`«`)),i.append($(`{{ a.${e} }}`)),i.append($(`»`)),t.race.alchemy.hasOwnProperty(e)||(t.race.alchemy[e]=0),sc({el:`#alchemy${e}`,data:{r:t.resource[e],a:t.race.alchemy},methods:{addSpell(e){let a=y();for(let r=0;r=1;r++)t.race.alchemy[e]++,t.resource.Mana.diff--},subSpell(e){let a=y();for(let r=0;r0;r++)t.race.alchemy[e]--,t.resource.Mana.diff++}}}),Ti(`alchemy${e}`,(function(){let a=r&&t.tech.alchemy>=2?8*Za[e]:2*Za[e];return t.race.witch_hunter&&(a*=3),t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg&&(a*=t.stats.achieve.soul_sponge.mg+1),$(`
    ${F("resource_alchemy",[1,F("resource_Mana_name"),.15,F("resource_Crystal_name"),+a.toFixed(2),t.resource[e].name])}
    `)}),{elm:`#alchemy${e} h3`})}}const Lr=(Nr={},function(e,a,r){let s=a||"a",i=[t.race.universe,t.prestige.Plasmid.count,t.prestige.AntiPlasmid.count,t.prestige.Phage.count,t.race.no_plasmid||"0",t.race.p_mutation||"0",t.race.nerfed||"0",t.genes.store||"0",t.genes.bleed||"0",t.city.temple?t.city.temple.count:"0",t.space.ziggurat?t.space.ziggurat.count:"0",t.race.cataclysm?t.race.cataclysm:"0",t.race.orbit_decayed?t.race.orbit_decayed:"0",t.genes.ancients||"0",t.civic.priest?t.civic.priest.workers:"0"].join("-");if(Nr[s]||(Nr[s]={}),!Nr[s][i]||r){let e=1,r=!(!t.race.cataclysm&&!t.race.orbit_decayed);if(t.genes.store){let r=0;if(!a||a&&("plasmid"===a&&"antimatter"!==t.race.universe||"anti"===a&&"antimatter"===t.race.universe)){r="antimatter"===t.race.universe?t.prestige.AntiPlasmid.count:t.prestige.Plasmid.count;let e=r;t.race.no_plasmid?e=Math.min(t.race.p_mutation,r):t.race.nerfed&&(e=Math.floor(r/("antimatter"===t.race.universe?2:5))),r=Math.round(e*(t.race.nerfed?.5:1))}(!a||a&&"phage"===a)&&t.genes.store>=4&&(r+=Math.round(t.prestige.Phage.count*(t.race.nerfed?1/3:1)));let s=t.genes.store>=2?t.genes.store>=3?1250:1666:2500;if("antimatter"===t.race.universe&&(s*=2),t.genes.bleed&&t.genes.bleed>=3&&(!a||a&&("plasmid"===a&&"antimatter"===t.race.universe||"anti"===a&&"antimatter"!==t.race.universe))){let e="antimatter"===t.race.universe?t.prestige.Plasmid.count/5:t.prestige.AntiPlasmid.count/10;r+=Math.round(e*(t.race.nerfed?.5:1))}e*=1+r/s}if("standard"===t.race.universe&&(e*=nc("standard")),"antimatter"===t.race.universe&&(!r&&t.city.temple&&t.city.temple.count||r&&t.space.ziggurat&&t.space.ziggurat.count)){let a=.06;if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.0012:t.genes.ancients>=3?.001:8e-4;t.race.high_pop&&(e=Me(e)),a+=e*t.civic.priest.workers}e*=1+(r?t.space.ziggurat.count:t.city.temple.count)*a}!a&&t.pillars&&(e*=_c()[1]),Nr[s]={},Nr[s][i]=e}return a?Nr[s][i]*e:Math.round(Nr[s][i]*e)});var Nr;function Dr(){if(t.race.no_plasmid||"antimatter"===t.race.universe){let e=!(!t.race.cataclysm&&!t.race.orbit_decayed);if(e&&t.space.ziggurat&&t.space.ziggurat.count||t.city.temple&&t.city.temple.count){let a=t.tech.anthropology&&t.tech.anthropology>=1?.016:.01;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=t.civic.professor.workers*("antimatter"===t.race.universe?2e-4:4e-4);t.race.high_pop&&(e=Me(e)),a+=e}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?15e-5:t.genes.ancients>=3?125e-6:1e-4;t.race.high_pop&&(e=Me(e)),a+=e*t.civic.priest.workers}"antimatter"===t.race.universe?a/=t.race.nerfed?3:2:t.race.nerfed&&(a/=2),t.race.spiritual&&(a*=1+ui.spiritual.vars()[0]/100);let r=Pi("seraph");return r>0&&(a*=1+ui.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1.12),t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),(e?t.space.ziggurat.count:t.city.temple.count)*a}}return 0}const Br=(Gr={},function(e){let a=[t.race.universe,t.prestige.Plasmid.count,t.prestige.AntiPlasmid.count,t.prestige.Phage.count,t.civic.govern.type,t.civic.professor.assigned,t.genes.bleed||"0",t.race.decayed||"0",t.race.gene_fortify||"0",t.tech.anthropology||"0",t.tech.fanaticism||"0",t.race.nerfed||"0",t.race.no_plasmid||"0",t.genes.ancients||"0",t.city.temple?t.city.temple.count:"0",t.space.ziggurat?t.space.ziggurat.count:"0",t.civic.priest?t.civic.priest.workers:"0",t.race.orbit_decayed?t.race.orbit_decayed:"0",t.race.spiritual||"0",t.tech.outpost_boost||"0",i.alien_outpost||"0"].join("-");if(!Gr[a]){let e=0,r=0;if("antimatter"!==t.race.universe||t.genes.bleed){let a=t.race.no_plasmid?Math.min(t.race.p_mutation,t.prestige.Plasmid.count):t.prestige.Plasmid.count;"antimatter"===t.race.universe&&t.genes.bleed&&(a*=.025),t.race.decayed&&(a-=Math.round((t.stats.days-t.race.decayed)/(300+6*t.race.gene_fortify)));let r=250+t.prestige.Phage.count;e=a>r?+(Math.log(r+50)-3.91202).toFixed(5)/2.888+Math.log(a+1-r)/Math.LN2/250:a<0?0:+(Math.log(a+50)-3.91202).toFixed(5)/2.888,t.tech.outpost_boost&&t.race.truepath&&i.alien_outpost&&(e*=2);let s=0;if(t.race.orbit_decayed&&t.space.ziggurat?s=t.space.ziggurat.count:t.city.temple&&(s=t.city.temple.count),s>0&&!t.race.no_plasmid&&"antimatter"!==t.race.universe){let a=t.tech.anthropology&&t.tech.anthropology>=1?.08:.05;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=.002*t.civic.professor.workers;t.race.high_pop&&(e=Me(e)),a+=e}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.0015:t.genes.ancients>=3?.00125:.001;t.race.high_pop&&(e=Me(e)),a+=e*t.civic.priest.workers}t.race.spiritual&&(a*=1+ui.spiritual.vars()[0]/100);let r=Pi("seraph");r>0&&(a*=1+ui.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1.12),t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),t.race.orbit_decayed&&t.race.truepath&&(a*=.1),e*=1+s*a}}if("antimatter"===t.race.universe||t.genes.bleed&&t.genes.bleed>=2){let e=t.prestige.AntiPlasmid.count;"antimatter"!==t.race.universe&&t.genes.bleed&&t.genes.bleed>=2&&(e*=.25),t.race.decayed&&(e-=Math.round((t.stats.days-t.race.decayed)/(300+6*t.race.gene_fortify)));let a=250+t.prestige.Phage.count;r=e>a?+(Math.log(a+50)-3.91202).toFixed(5)/2.888+Math.log(e+1-a)/Math.LN2/250:e<0?0:+(Math.log(e+50)-3.91202).toFixed(5)/2.888,t.tech.outpost_boost&&t.race.truepath&&i.alien_outpost&&(r*=2),r/=3}t.race.nerfed&&("antimatter"===t.race.universe?(e/=2,r/=2):(e/=5,r/=5)),(Gr={})[a]=[(1+e)*(1+r)-1,e,r]}return e&&"raw"===e?Gr[a]:e&&"plasmid"===e?Gr[a][1]:e&&"antiplasmid"===e?Gr[a][2]:Gr[a][0]});var Gr;const Rr={club:{id:"tech-club",title:F("tech_club"),desc:F("tech_club_desc"),category:"agriculture",era:"primitive",reqs:{},grant:["primitive",1],cost:{Lumber:()=>t.race.kindling_kindred||t.race.smoldering?0:5,Stone:()=>t.race.kindling_kindred||t.race.smoldering?5:0},action(){return!!Os($(this)[0])&&(t.resource.Food.display=!0,!0)}},bone_tools:{id:"tech-bone_tools",title:F("tech_bone_tools"),desc:F("tech_bone_tools_desc"),category:"stone_gathering",era:"primitive",reqs:{primitive:1},grant:["primitive",2],condition:()=>!(t.race.soul_eater&&!t.race.evil),cost:{Food:()=>t.race.evil&&!t.race.smoldering?0:10,Lumber:()=>t.race.evil&&!t.race.smoldering?10:0},action(){return!!Os($(this)[0])&&(t.resource.Stone.display=!0,t.race.smoldering&&(t.resource.Chrysotile.display=!0),!0)}},wooden_tools:{id:"tech-wooden_tools",title:()=>t.race.kindling_kindred?F("tech_bone_tools"):F("tech_wooden_tools"),desc:()=>t.race.kindling_kindred?F("tech_bone_tools_desc"):F("tech_wooden_tools_desc"),category:"stone_gathering",era:"primitive",reqs:{primitive:1},grant:["primitive",2],condition:()=>!(!t.race.soul_eater||t.race.evil),cost:{Lumber:()=>10},action(){return!!Os($(this)[0])&&(t.resource.Stone.display=!0,t.race.smoldering&&(t.resource.Chrysotile.display=!0),!0)}},sundial:{id:"tech-sundial",title:()=>t.race.unfathomable?F("tech_moondial"):F("tech_sundial"),desc:()=>t.race.unfathomable?F("tech_moondial_desc"):F("tech_sundial_desc"),category:"science",era:"primitive",reqs:{primitive:2},grant:["primitive",3],cost:{Lumber:()=>8,Stone:()=>10},effect:()=>t.race.unfathomable?F("tech_moondial_effect"):F("tech_sundial_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_sundial_msg"),"info",!1,["progress"]),t.resource.Knowledge.display=!0,t.city.calendar.day++,t.race.infectious&&(t.civic.garrison.display=!0,t.settings.showCivic=!0,t.city.garrison={count:0,on:0}),t.race.banana&&!t.race.terrifying&&(t.settings.showResources=!0,t.settings.showMarket=!0,t.resource.Money.display=!0,t.city.market.active=!0,t.tech.currency=2),t.race.calm&&(t.resource.Zen.display=!0,t.city.meditation={count:0}),!0)}},housing:{id:"tech-housing",title:F("tech_housing"),desc:F("tech_housing_desc"),category:"housing",era:"civilized",reqs:{primitive:3},grant:["housing",1],cost:{Knowledge:()=>10},effect:F("tech_housing_effect"),action(){return!!Os($(this)[0])&&(t.city.basic_housing={count:0},!0)}},cottage:{id:"tech-cottage",title:()=>Is("medium"),desc:F("tech_cottage_desc"),category:"housing",era:"civilized",reqs:{housing:1,cement:1,mining:3},grant:["housing",2],cost:{Knowledge:()=>3600},effect:F("tech_cottage_effect"),action(){return!!Os($(this)[0])&&(t.city.cottage={count:0},!0)}},apartment:{id:"tech-apartment",title:()=>Is("large"),desc:()=>Is("large"),category:"housing",era:"discovery",reqs:{housing:2,high_tech:2},grant:["housing",3],cost:{Knowledge:()=>15750},effect:F("tech_apartment_effect"),action(){return!!Os($(this)[0])&&(t.city.apartment={count:0,on:0},!0)}},arcology:{id:"tech-arcology",title:F("tech_arcology"),desc:F("tech_arcology"),category:"housing",era:"dimensional",reqs:{hell_ruins:4,housing:3,high_tech:17},grant:["housing",4],cost:{Knowledge:()=>25e6},effect:()=>F("tech_arcology_effect"),action(){return!!Os($(this)[0])&&(t.portal.arcology={count:0,on:0},!0)}},steel_beams:{id:"tech-steel_beams",title:F("tech_steel_beams"),desc:F("tech_housing_cost"),category:"housing",era:"discovery",reqs:{housing:2,smelting:2},not_trait:["cataclysm","lone_survivor"],grant:["housing_reduction",1],cost:{Knowledge:()=>11250,Steel:()=>2500},effect:()=>F("tech_steel_beams_effect",[Is("small"),Is("medium")]),action(){return!!Os($(this)[0])}},mythril_beams:{id:"tech-mythril_beams",title:F("tech_mythril_beams"),desc:F("tech_housing_cost"),category:"housing",era:"early_space",reqs:{housing_reduction:1,space:3},grant:["housing_reduction",2],cost:{Knowledge:()=>175e3,Mythril:()=>1e3},effect:()=>F("tech_mythril_beams_effect",[Is("small"),Is("medium")]),action(){return!!Os($(this)[0])}},neutronium_walls:{id:"tech-neutronium_walls",title:F("tech_neutronium_walls"),desc:F("tech_housing_cost"),category:"housing",era:"deep_space",reqs:{housing_reduction:2,gas_moon:1},grant:["housing_reduction",3],cost:{Knowledge:()=>3e5,Neutronium:()=>850},effect:()=>F("tech_neutronium_walls_effect",[Is("small"),Is("medium")]),action(){return!!Os($(this)[0])}},bolognium_alloy_beams:{id:"tech-bolognium_alloy_beams",title:F("tech_bolognium_alloy_beams"),desc:F("tech_housing_cost"),category:"housing",era:"intergalactic",reqs:{housing_reduction:3,gateway:3},grant:["housing_reduction",4],cost:{Knowledge:()=>375e4,Adamantite:()=>25e5,Bolognium:()=>1e5},effect:()=>F("tech_bolognium_alloy_beams_effect",[Is("small"),Is("medium")]),action(){return!!Os($(this)[0])}},aphrodisiac:{id:"tech-aphrodisiac",title:F("tech_aphrodisiac"),desc:F("tech_aphrodisiac_desc"),category:"housing",era:"civilized",reqs:{housing:2},grant:["reproduction",1],not_trait:["artifical"],cost:{Knowledge:()=>4500},effect:F("tech_aphrodisiac_effect"),action(){return!!Os($(this)[0])}},fertility_clinic:{id:"tech-fertility_clinic",title:F("tech_fertility_clinic"),desc:F("tech_fertility_clinic"),category:"housing",era:"intergalactic",reqs:{reproduction:1,xeno:6},not_trait:["cataclysm"],grant:["reproduction",2],cost:{Knowledge:()=>45e5},effect:F("tech_fertility_clinic_effect"),action(){return!!Os($(this)[0])}},captive_housing:{id:"tech-captive_housing",title:F("tech_captive_housing"),desc:F("tech_captive_housing"),category:"eldritch",era:"civilized",reqs:{housing:1},trait:["unfathomable"],grant:["unfathomable",1],cost:{Knowledge:()=>12},effect:F("tech_captive_housing_effect"),action(){return!!Os($(this)[0])&&(t.city.captive_housing={count:0,cattle:0,cattleCatch:0,race0:0,jailrace0:0,race1:0,jailrace1:0,race2:0,jailrace2:0,raceCap:0,cattleCap:0},!0)}},torture:{id:"tech-torture",title:F("tech_torture"),desc:F("tech_torture"),category:"eldritch",era:"civilized",reqs:{unfathomable:1},trait:["unfathomable"],grant:["unfathomable",2],cost:{Knowledge:()=>25},effect:F("tech_torture_effect"),action(){return!!Os($(this)[0])&&(t.civic.torturer.display=!0,!0)}},thrall_quarters:{id:"tech-thrall_quarters",title:F("tech_thrall_quarters"),desc:F("tech_thrall_quarters"),category:"eldritch",era:"civilized",reqs:{unfathomable:2,high_tech:6},trait:["unfathomable"],grant:["unfathomable",3],cost:{Knowledge:()=>95e3,Cement:()=>5e4,Wrought_Iron:()=>12500},effect:F("tech_thrall_quarters_effect"),action(){return!!Os($(this)[0])&&(t.civic.torturer.display=!0,!0)}},psychic_energy:{id:"tech-psychic_energy",title:F("tech_psychic_energy"),desc:F("tech_psychic_energy"),category:"eldritch",era:"civilized",reqs:{housing:1},condition:()=>t.settings.showCivic,trait:["psychic"],grant:["psychic",1],cost:{Knowledge:()=>15},effect:F("tech_psychic_energy_effect"),action(){return!!Os($(this)[0])&&(t.resource.Energy.display=!0,t.settings.showPsychic=!0,t.race.psychicPowers={boost:{r:"Food"},boostTime:0},!0)},post(){zi()}},psychic_attack:{id:"tech-psychic_attack",title:F("tech_psychic_attack"),desc:F("tech_psychic_attack"),category:"eldritch",era:"civilized",reqs:{psychic:1,military:1},condition:()=>t.stats.psykill>=10,trait:["psychic"],grant:["psychic",2],cost:{Knowledge:()=>100},effect:F("tech_psychic_attack_effect"),action(){return!!Os($(this)[0])&&(t.race.psychicPowers.assaultTime=0,!0)},post(){zi()}},psychic_finance:{id:"tech-psychic_finance",title:F("tech_psychic_finance"),desc:F("tech_psychic_finance"),category:"eldritch",era:"civilized",reqs:{psychic:2,high_tech:4},trait:["psychic"],grant:["psychic",3],cost:{Knowledge:()=>65e3},effect:F("tech_psychic_finance_effect"),action(){return!!Os($(this)[0])&&(t.race.psychicPowers.cash=0,!0)},post(){zi()}},psychic_channeling:{id:"tech-psychic_channeling",title:F("tech_psychic_channeling"),desc:F("tech_psychic_channeling"),category:"eldritch",era:"deep_space",reqs:{psychic:3,high_tech:10},trait:["psychic"],grant:["psychic",4],cost:{Knowledge:()=>36e4},effect:F("tech_psychic_channeling_effect"),action(){return!!Os($(this)[0])&&(t.race.psychicPowers.channel={cash:0,assault:0,boost:0},!0)},post(){zi()}},psychic_efficiency:{id:"tech-psychic_efficiency",title:F("tech_psychic_efficiency"),desc:F("tech_psychic_efficiency"),category:"eldritch",era:"intergalactic",reqs:{psychic:4,high_tech:16},trait:["psychic"],grant:["psychic",5],cost:{Knowledge:()=>525e4},effect:F("tech_psychic_efficiency_effect"),action(){return!!Os($(this)[0])},post(){zi()}},mind_break:{id:"tech-mind_break",title:F("tech_mind_break"),desc:F("tech_mind_break"),category:"eldritch",era:"civilized",reqs:{psychic:2,high_tech:1,unfathomable:2},trait:["psychic"],grant:["psychicthrall",1],cost:{Knowledge:()=>7e3},effect:F("tech_mind_break_effect"),action(){return!!Os($(this)[0])},post(){zi()}},psychic_stun:{id:"tech-psychic_stun",title:F("tech_psychic_stun"),desc:F("tech_psychic_stun"),category:"eldritch",era:"civilized",reqs:{psychicthrall:1,high_tech:3,unfathomable:2},trait:["psychic"],grant:["psychicthrall",2],cost:{Knowledge:()=>32e3},effect:F("tech_psychic_stun_effect"),action(){return!!Os($(this)[0])},post(){zi()}},spear:{id:"tech-spear",title:F("tech_spear"),desc:F("tech_spear_desc"),category:"foraging",era:"civilized",reqs:{primitive:3,storage:1},trait:["forager"],grant:["foraging",1],cost:{Knowledge:()=>110,Stone:()=>75},effect:F("tech_spear_effect"),action(){return!!Os($(this)[0])}},bronze_spear:{id:"tech-bronze_spear",title:F("tech_bronze_spear"),desc:F("tech_bronze_spear_desc"),category:"foraging",era:"civilized",reqs:{foraging:1,mining:2},trait:["forager"],grant:["foraging",2],cost:{Knowledge:()=>525,Copper:()=>50},effect:F("tech_bronze_spear_effect"),action(){return!!Os($(this)[0])}},iron_spear:{id:"tech-iron_spear",title:F("tech_iron_spear"),desc:F("tech_iron_spear_desc"),category:"foraging",era:"civilized",reqs:{foraging:2,mining:3},trait:["forager"],grant:["foraging",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1650:3300,Iron:()=>375},effect:F("tech_bronze_spear_effect"),action(){return!!Os($(this)[0])}},dowsing_rod:{id:"tech-dowsing_rod",title:F("tech_dowsing_rod"),desc:F("tech_dowsing_rod_desc"),category:"foraging",era:"civilized",reqs:{foraging:1,mining:2},trait:["forager"],grant:["dowsing",1],cost:{Knowledge:()=>450,Lumber:()=>750},effect:F("tech_dowsing_rod_effect"),action(){return!!Os($(this)[0])}},metal_detector:{id:"tech-metal_detector",title:F("tech_metal_detector"),desc:F("tech_metal_detector_desc"),category:"foraging",era:"civilized",reqs:{dowsing:1,high_tech:4},trait:["forager"],grant:["dowsing",2],cost:{Knowledge:()=>65e3},effect:F("tech_metal_detector_effect"),action(){return!!Os($(this)[0])}},smokehouse:{id:"tech-smokehouse",title:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("city_smokehouse_easter"):F("tech_smokehouse"),desc:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("tech_smokehouse_easter_desc"):F("tech_smokehouse_desc"),category:"storage",era:"civilized",reqs:{primitive:3,storage:1},trait:["carnivore"],not_trait:["cataclysm","artifical","soul_eater","herbivore","lone_survivor"],grant:["hunting",1],cost:{Knowledge:()=>80},effect:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("tech_smokehouse_easter_effect"):F("tech_smokehouse_effect"),action(){return!!Os($(this)[0])&&(gi("city","smokehouse","silo",{count:0}),!0)},post(){t.tech.s_lodge&&(t.tech.hunting=2)}},lodge:{id:"tech-lodge",title:F("tech_lodge"),desc:F("tech_lodge"),wiki:!!t.race.carnivore,category:"agriculture",era:"civilized",reqs:{hunting:1,housing:1,currency:1},condition:()=>!t.tech.s_lodge,grant:["hunting",2],cost:{Knowledge:()=>180},effect:F("tech_lodge_effect"),action(){return!!Os($(this)[0])&&(gi("city","lodge","farm",{count:0}),!0)}},alt_lodge:{id:"tech-alt_lodge",title(){return this.condition()?F("tech_lodge_alt"):F("tech_lodge")},desc(){return this.condition()?F("tech_lodge_alt"):F("tech_lodge")},wiki:!t.race.carnivore,category:"housing",era:"civilized",reqs:{housing:1,currency:1},grant:["s_lodge",1],condition:()=>!!(("wendigo"===t.race.species||t.race.detritivore)&&!t.race.carnivore&&!t.race.herbivore||t.race.carnivore&&t.race.soul_eater||t.race.artifical||t.race.unfathomable),cost:{Knowledge:()=>t.race.artifical?1e4:180},effect(){return this.condition()?F("tech_lodge_effect_alt"):F("tech_lodge_effect")},action(){return!!Os($(this)[0])&&(gi("city","lodge","farm",{count:0}),!0)}},soul_well:{id:"tech-soul_well",title:F("tech_soul_well"),desc:F("tech_soul_well"),category:"souls",era:"civilized",reqs:{primitive:3},trait:["soul_eater"],not_trait:["cataclysm","artifical","lone_survivor"],grant:["soul_eater",1],cost:{Knowledge:()=>10},effect:F("tech_soul_well_effect"),action(){return!!Os($(this)[0])&&(t.city.soul_well={count:0},!0)}},compost:{id:"tech-compost",title:F("tech_compost"),desc:F("tech_compost_desc"),category:"compost",era:"civilized",reqs:{primitive:3},trait:["detritivore"],not_trait:["cataclysm","artifical","lone_survivor"],grant:["compost",1],cost:{Knowledge:()=>10},effect:F("tech_compost_effect"),action(){return!!Os($(this)[0])&&(t.city.compost={count:0,on:0},!0)}},hot_compost:{id:"tech-hot_compost",title:F("tech_hot_compost"),desc:F("tech_hot_compost"),category:"compost",era:"civilized",reqs:{compost:1},trait:["detritivore"],grant:["compost",2],cost:{Knowledge:()=>100},effect:F("tech_hot_compost_effect"),action(){return!!Os($(this)[0])}},mulching:{id:"tech-mulching",title:F("tech_mulching"),desc:F("tech_mulching"),category:"compost",era:"civilized",reqs:{compost:2,mining:3},trait:["detritivore"],grant:["compost",3],cost:{Knowledge:()=>3200},effect:F("tech_mulching_effect"),action(){return!!Os($(this)[0])}},adv_mulching:{id:"tech-adv_mulching",title:F("tech_adv_mulching"),desc:F("tech_adv_mulching"),category:"compost",era:"discovery",reqs:{compost:3,high_tech:2},trait:["detritivore"],grant:["compost",4],cost:{Knowledge:()=>16e3},effect:F("tech_adv_mulching_effect"),action(){return!!Os($(this)[0])}},agriculture:{id:"tech-agriculture",title:F("tech_agriculture"),desc:F("tech_agriculture_desc"),category:"agriculture",era:"civilized",reqs:{primitive:3},condition:()=>!(!t.race.herbivore&&(t.race.carnivore||t.race.detritivore||t.race.soul_eater)),not_trait:["cataclysm","artifical","lone_survivor","unfathomable"],grant:["agriculture",1],cost:{Knowledge:()=>10},effect:F("tech_agriculture_effect"),action(){return!!Os($(this)[0])&&(gi("city","farm","lodge",{count:0}),!0)}},farm_house:{id:"tech-farm_house",title:F("tech_farm_house"),desc:F("tech_farm_house_desc"),category:"housing",era:"civilized",reqs:{agriculture:1,housing:1,currency:1},grant:["farm",1],cost:{Money:()=>50,Knowledge:()=>180},effect:F("tech_farm_house_effect"),action(){return!!Os($(this)[0])}},irrigation:{id:"tech-irrigation",title:F("tech_irrigation"),desc:F("tech_irrigation_desc"),category:"agriculture",era:"civilized",reqs:{agriculture:1},grant:["agriculture",2],cost:{Knowledge:()=>55},effect:F("tech_irrigation_effect"),action(){return!!Os($(this)[0])}},silo:{id:"tech-silo",title:F("tech_silo"),desc:F("tech_silo_desc"),category:"storage",era:"civilized",reqs:{agriculture:2,storage:1},grant:["agriculture",3],cost:{Knowledge:()=>80},effect:F("tech_silo_effect"),action(){return!!Os($(this)[0])&&(gi("city","silo","smokehouse",{count:0}),!0)}},mill:{id:"tech-mill",title:F("tech_mill"),desc:F("tech_mill_desc"),category:"agriculture",era:"civilized",reqs:{agriculture:3,mining:3},grant:["agriculture",4],cost:{Knowledge:()=>5400},effect:F("tech_mill_effect"),action(){return!!Os($(this)[0])&&(gi("city","mill","windmill",{count:0,on:0}),!0)}},windmill:{id:"tech-windmill",title:F("tech_windmill"),desc:F("tech_windmill_desc"),category:"agriculture",era:"discovery",reqs:{agriculture:4,high_tech:1},grant:["agriculture",5],cost:{Knowledge:()=>16200},effect:F("tech_windmill_effect"),action(){return!!Os($(this)[0])}},windturbine:{id:"tech-windturbine",title:F("tech_windturbine"),desc:F("tech_windturbine"),category:"power_generation",era:"globalized",reqs:{agriculture:5,high_tech:4},grant:["agriculture",6],cost:{Knowledge:()=>66e3},effect:F("tech_windturbine_effect"),action(){return!!Os($(this)[0])}},wind_plant:{id:"tech-wind_plant",title:()=>t.race.unfathomable?F("tech_watermill"):F("tech_windmill"),desc:()=>t.race.unfathomable?F("tech_watermill"):F("tech_windmill"),category:"power_generation",era:"globalized",reqs:{high_tech:4},condition:()=>!!(t.race.carnivore||t.race.detritivore||t.race.artifical||t.race.soul_eater||t.race.unfathomable),not_trait:["herbivore"],grant:["wind_plant",1],cost:{Knowledge:()=>66e3},effect:()=>t.race.unfathomable?F("tech_watermill_effect"):F("tech_wind_plant_effect"),action(){return!!Os($(this)[0])&&(gi("city","windmill","mill",{count:0,on:0}),!0)}},gmfood:{id:"tech-gmfood",title:F("tech_gmfood"),desc:F("tech_gmfood_desc"),category:"agriculture",era:"globalized",reqs:{agriculture:6,genetics:1},grant:["agriculture",7],cost:{Knowledge:()=>95e3},effect:F("tech_gmfood_effect"),action(){return!!Os($(this)[0])}},foundry:{id:"tech-foundry",title:F("tech_foundry"),desc:F("tech_foundry"),category:"crafting",era:"civilized",reqs:{mining:2},grant:["foundry",1],cost:{Knowledge:()=>650},effect:F("tech_foundry_effect"),action(){return!!Os($(this)[0])&&(t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},!0)}},artisans:{id:"tech-artisans",title:F("tech_artisans"),desc:F("tech_artisans"),category:"crafting",era:"civilized",reqs:{foundry:1},grant:["foundry",2],cost:{Knowledge:()=>1500},effect:F("tech_artisans_effect"),action(){return!!Os($(this)[0])}},apprentices:{id:"tech-apprentices",title:F("tech_apprentices"),desc:F("tech_apprentices"),category:"crafting",era:"civilized",reqs:{foundry:2},grant:["foundry",3],cost:{Knowledge:()=>3200},effect:F("tech_apprentices_effect"),action(){return!!Os($(this)[0])}},carpentry:{id:"tech-carpentry",title:F("tech_carpentry"),desc:F("tech_carpentry"),category:"crafting",era:"civilized",reqs:{foundry:3,saw:1},grant:["foundry",4],not_trait:["evil"],cost:{Knowledge:()=>5200},effect:F("tech_carpentry_effect"),action(){return!!Os($(this)[0])}},demonic_craftsman:{id:"tech-demonic_craftsman",title:F("tech_master_craftsman"),desc:F("tech_master_craftsman"),category:"crafting",era:"discovery",wiki:!!t.race.evil,reqs:{foundry:3},grant:["foundry",5],trait:["evil"],cost:{Knowledge:()=>12e3},effect:F("tech_master_craftsman_effect"),action(){return!!Os($(this)[0])}},master_craftsman:{id:"tech-master_craftsman",title:F("tech_master_craftsman"),desc:F("tech_master_craftsman"),category:"crafting",era:"discovery",wiki:!t.race.evil,reqs:{foundry:4},grant:["foundry",5],not_trait:["evil"],cost:{Knowledge:()=>12e3},effect:F("tech_master_craftsman_effect"),action(){return!!Os($(this)[0])}},brickworks:{id:"tech-brickworks",title:F("tech_brickworks"),desc:F("tech_brickworks"),category:"crafting",era:"discovery",reqs:{foundry:5},grant:["foundry",6],cost:{Knowledge:()=>18500},effect:F("tech_brickworks_effect"),action(){return!!Os($(this)[0])}},machinery:{id:"tech-machinery",title:F("tech_machinery"),desc:F("tech_machinery"),category:"crafting",era:"globalized",reqs:{foundry:6,high_tech:4},grant:["foundry",7],cost:{Knowledge:()=>66e3},effect:F("tech_machinery_effect"),action(){return!!Os($(this)[0])}},cnc_machine:{id:"tech-cnc_machine",title:F("tech_cnc_machine"),desc:F("tech_cnc_machine"),category:"crafting",era:"globalized",reqs:{foundry:7,high_tech:8},grant:["foundry",8],cost:{Knowledge:()=>132e3},effect:F("tech_cnc_machine_effect"),action(){return!!Os($(this)[0])}},vocational_training:{id:"tech-vocational_training",title:F("tech_vocational_training"),desc:F("tech_vocational_training"),category:"crafting",era:"industrialized",reqs:{foundry:1,high_tech:3},grant:["v_train",1],cost:{Knowledge:()=>3e4},effect:F("tech_vocational_training_effect"),action(){return!!Os($(this)[0])}},stellar_forge:{id:"tech-stellar_forge",title:F("tech_stellar_forge"),desc:F("tech_stellar_forge"),category:"crafting",era:"intergalactic",reqs:{foundry:8,high_tech:15,gateway:3,neutron:1},grant:["star_forge",1],cost:{Knowledge:()=>45e5},effect:F("tech_stellar_forge_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.stellar_forge={count:0,on:0},!0)}},stellar_smelting:{id:"tech-stellar_smelting",title:F("tech_stellar_smelting"),desc:F("tech_stellar_smelting"),category:"crafting",era:"intergalactic",reqs:{star_forge:1,xeno:4},grant:["star_forge",2],cost:{Knowledge:()=>5e6,Vitreloy:()=>1e4},effect:F("tech_stellar_smelting_effect"),action(){return!!Os($(this)[0])},post(){Ws()}},assembly_line:{id:"tech-assembly_line",title:F("tech_assembly_line"),desc:F("tech_assembly_line"),category:"crafting",era:"globalized",reqs:{high_tech:4},grant:["factory",1],cost:{Knowledge:()=>72e3,Copper:()=>125e3},effect:`${F("tech_assembly_line_effect")} ${F("tech_factory_warning")}`,action(){return!!Os($(this)[0])}},automation:{id:"tech-automation",title:F("tech_automation"),desc:F("tech_automation"),category:"crafting",era:"early_space",reqs:{high_tech:8,factory:1},grant:["factory",2],cost:{Knowledge:()=>165e3},effect:`${F("tech_automation_effect")} ${F("tech_factory_warning")}`,action(){return!!Os($(this)[0])}},laser_cutters:{id:"tech-laser_cutters",title:F("tech_laser_cutters"),desc:F("tech_laser_cutters"),category:"crafting",era:"deep_space",reqs:{high_tech:9,factory:2},grant:["factory",3],cost:{Knowledge:()=>3e5,Elerium:()=>200},effect:`${F("tech_laser_cutters_effect")} ${F("tech_factory_warning")}`,action(){return!!Os($(this)[0])}},high_tech_factories:{id:"tech-high_tech_factories",title:F("tech_high_tech_factories"),desc:F("tech_high_tech_factories"),category:"crafting",era:"intergalactic",reqs:{high_tech:17,alpha:4,factory:3},grant:["factory",4],cost:{Knowledge:()=>135e5,Vitreloy:()=>5e5,Orichalcum:()=>3e5},effect:`${F("tech_high_tech_factories_effect")} ${F("tech_factory_warning")}`,action(){return!!Os($(this)[0])}},theatre:{id:"tech-theatre",title:F("tech_theatre"),desc:F("tech_theatre"),category:"entertainment",era:"civilized",reqs:{housing:1,currency:1,cement:1},grant:["theatre",1],not_trait:["joyless"],cost:{Knowledge:()=>750},effect:F("tech_theatre_effect"),action(){return!!Os($(this)[0])&&(t.city.amphitheatre={count:0},!0)}},playwright:{id:"tech-playwright",title:F("tech_playwright"),desc:F("tech_playwright"),category:"entertainment",era:"civilized",reqs:{theatre:1,science:2},grant:["theatre",2],cost:{Knowledge:()=>1080},effect:F("tech_playwright_effect"),action(){return!!Os($(this)[0])}},magic:{id:"tech-magic",title:()=>"magic"===t.race.universe?F("tech_illusionist"):F("tech_magic"),desc:()=>"magic"===t.race.universe?F("tech_illusionist"):F("tech_magic"),category:"entertainment",era:"discovery",reqs:{theatre:2,high_tech:1},grant:["theatre",3],cost:{Knowledge:()=>7920},effect:F("tech_magic_effect"),effect:()=>"magic"===t.race.universe?F("tech_illusionist_effect"):F("tech_magic_effect"),action(){return!!Os($(this)[0])}},superstars:{id:"tech-superstars",title:F("tech_superstars"),desc:F("tech_superstars"),category:"entertainment",era:"interstellar",reqs:{theatre:3,high_tech:12},grant:["superstar",1],cost:{Knowledge:()=>66e4},effect:F("tech_superstars_effect"),action(){return!!Os($(this)[0])}},radio:{id:"tech-radio",title:F("tech_radio"),desc:F("tech_radio"),category:"entertainment",era:"discovery",reqs:{theatre:3,high_tech:2},grant:["broadcast",1],cost:{Knowledge:()=>16200},effect:()=>F("tech_radio_effect",[Ts()]),action(){return!!Os($(this)[0])}},tv:{id:"tech-tv",title:F("tech_tv"),desc:F("tech_tv"),category:"entertainment",era:"globalized",reqs:{broadcast:1,high_tech:4},grant:["broadcast",2],cost:{Knowledge:()=>67500},effect:()=>F("tech_tv_effect",[Ts()]),action(){return!!Os($(this)[0])}},vr_center:{id:"tech-vr_center",title:F("tech_vr_center"),desc:F("tech_vr_center"),category:"entertainment",era:"interstellar",reqs:{broadcast:2,high_tech:12,stanene:1},grant:["broadcast",3],cost:{Knowledge:()=>62e4},effect:()=>F("tech_vr_center_effect"),action(){return!!Os($(this)[0])&&(t.space.vr_center={count:0,on:0},!0)}},zoo:{id:"tech-zoo",title:F("tech_zoo"),desc:F("tech_zoo"),category:"entertainment",era:"dimensional",reqs:{hell_ruins:2},grant:["zoo",1],cost:{Knowledge:()=>225e5},effect:()=>F("tech_zoo_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.zoo={count:0,on:0},!0)}},casino:{id:"tech-casino",title:F("tech_casino"),desc:F("tech_casino"),category:"entertainment",era:"globalized",reqs:{high_tech:4,currency:5},grant:["gambling",1],cost:{Knowledge:()=>95e3},effect:F("tech_casino_effect"),action(){return!!Os($(this)[0])&&(t.city.casino={count:0,on:0},t.space.spc_casino={count:0,on:0},!0)}},dazzle:{id:"tech-dazzle",title:F("tech_dazzle"),desc:F("tech_dazzle"),category:"banking",era:"globalized",reqs:{gambling:1},grant:["gambling",2],cost:{Knowledge:()=>125e3},effect:F("tech_dazzle_effect"),action(){return!!Os($(this)[0])}},casino_vault:{id:"tech-casino_vault",title:F("tech_casino_vault"),desc:F("tech_casino_vault"),category:"banking",era:"early_space",reqs:{gambling:2,space:3},grant:["gambling",3],cost:{Knowledge:()=>145e3,Iridium:()=>2500},effect:F("tech_casino_vault_effect"),action(){return!!Os($(this)[0])}},otb:{id:"tech-otb",title:F("tech_otb"),desc:F("tech_otb"),category:"banking",era:"deep_space",reqs:{gambling:3,banking:10,high_tech:10},grant:["gambling",4],cost:{Knowledge:()=>39e4},effect:F("tech_otb_effect"),action(){return!!Os($(this)[0])}},online_gambling:{id:"tech-online_gambling",title:F("tech_online_gambling"),desc:F("tech_online_gambling"),category:"banking",era:"interstellar",reqs:{gambling:4,banking:12},grant:["gambling",5],cost:{Knowledge:()=>8e5},effect:F("tech_online_gambling_effect"),action(){return!!Os($(this)[0])}},bolognium_vaults:{id:"tech-bolognium_vaults",title:F("tech_bolognium_vaults"),desc:F("tech_bolognium_vaults"),category:"banking",era:"intergalactic",reqs:{gambling:5,gateway:3},grant:["gambling",6],cost:{Knowledge:()=>39e5,Bolognium:()=>18e4},effect:F("tech_bolognium_vaults_effect"),action(){return!!Os($(this)[0])}},mining:{id:"tech-mining",title:()=>t.race.sappy?F("tech_amber"):F("tech_mining"),desc:()=>t.race.sappy?F("tech_amber"):F("tech_mining_desc"),category:"mining",era:"civilized",reqs:{primitive:3},grant:["mining",1],cost:{Knowledge:()=>45},effect:()=>t.race.sappy?F("tech_amber_effect"):F(t.race.flier?"tech_mining_effect_alt":"tech_mining_effect"),action(){return!!Os($(this)[0])&&(t.city.rock_quarry={count:0,on:0,asbestos:50},t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),!0)}},bayer_process:{id:"tech-bayer_process",title:F("tech_bayer_process"),desc:F("tech_bayer_process_desc"),category:"mining",era:"civilized",reqs:{smelting:2},grant:["alumina",1],cost:{Knowledge:()=>4500},effect:()=>t.race.sappy?F("tech_bayer_process_effect_alt"):F("tech_bayer_process_effect"),action(){return!!Os($(this)[0])&&(t.city.metal_refinery={count:0,on:0},ha(),!0)}},elysis_process:{id:"tech-elysis_process",title:F("tech_elysis_process"),desc:F("tech_elysis_process"),category:"mining",era:"interstellar",reqs:{alumina:1,stanene:1,graphene:1},path:["standard","truepath"],not_trait:["cataclysm","lone_survivor"],grant:["alumina",2],cost:{Knowledge:()=>675e3,Graphene:()=>45e3,Stanene:()=>75e3},effect:F("tech_elysis_process_effect"),action(){return!!Os($(this)[0])}},smelting:{id:"tech-smelting",title:F("tech_smelting"),desc:F("tech_smelting_desc"),category:"mining",era:"civilized",reqs:{mining:3},grant:["smelting",1],cost:{Knowledge:()=>4050},effect:F("tech_smelting_effect"),action(){return!!Os($(this)[0])&&(t.city.smelter={count:0,cap:0,Wood:0,Coal:0,Oil:0,Star:0,StarCap:0,Inferno:0,Iron:0,Steel:0,Iridium:0},!0)},post(){t.race.steelen&&(t.tech.smelting=2,ms())}},steel:{id:"tech-steel",title:F("tech_steel"),desc:F("tech_steel_desc"),category:"mining",era:"civilized",reqs:{smelting:1,mining:4},grant:["smelting",2],condition:()=>!t.race.steelen,cost:{Knowledge:()=>4950,Steel:()=>25},effect:F("tech_steel_effect"),action(){return!!Os($(this)[0])&&(t.resource.Steel.display=!0,!0)},post(){Ws(),zi()}},blast_furnace:{id:"tech-blast_furnace",title:F("tech_blast_furnace"),desc:F("tech_blast_furnace"),category:"mining",era:"discovery",reqs:{smelting:2},grant:["smelting",3],cost:{Knowledge:()=>13500,Coal:()=>2e3},effect:F("tech_blast_furnace_effect"),action(){return!!Os($(this)[0])},post(){t.race.steelen&&(t.tech.smelting=6,ms())}},bessemer_process:{id:"tech-bessemer_process",title:F("tech_bessemer_process"),desc:F("tech_bessemer_process"),category:"mining",era:"discovery",reqs:{smelting:3},grant:["smelting",4],condition:()=>!t.race.steelen,cost:{Knowledge:()=>19800,Coal:()=>5e3},effect:F("tech_bessemer_process_effect"),action(){return!!Os($(this)[0])}},oxygen_converter:{id:"tech-oxygen_converter",title:F("tech_oxygen_converter"),desc:F("tech_oxygen_converter"),category:"mining",era:"industrialized",reqs:{smelting:4,high_tech:3},grant:["smelting",5],condition:()=>!t.race.steelen,cost:{Knowledge:()=>46800,Coal:()=>1e4},effect:F("tech_oxygen_converter_effect"),action(){return!!Os($(this)[0])}},electric_arc_furnace:{id:"tech-electric_arc_furnace",title:F("tech_electric_arc_furnace"),desc:F("tech_electric_arc_furnace"),category:"mining",era:"globalized",reqs:{smelting:5,high_tech:4},grant:["smelting",6],condition:()=>!t.race.steelen,cost:{Knowledge:()=>85500,Copper:()=>25e3},effect:F("tech_electric_arc_furnace_effect"),action(){return!!Os($(this)[0])}},hellfire_furnace:{id:"tech-hellfire_furnace",title:F("tech_hellfire_furnace"),desc:F("tech_hellfire_furnace"),category:"mining",era:"interstellar",reqs:{smelting:6,infernite:1},grant:["smelting",7],cost:{Knowledge:()=>615e3,Infernite:()=>2e3,Soul_Gem:()=>2},effect:F("tech_hellfire_furnace_effect"),action(){return!!Os($(this)[0])}},infernium_fuel:{id:"tech-infernium_fuel",title:F("tech_infernium_fuel"),desc:F("tech_infernium_fuel"),category:"mining",era:"dimensional",reqs:{smelting:7,hell_ruins:4},grant:["smelting",8],cost:{Knowledge:()=>275e5,Coal:()=>45e6,Oil:()=>5e5,Infernite:()=>75e4},effect:F("tech_infernium_fuel_effect"),action(){return!!Os($(this)[0])},post(){Ws()}},iridium_smelting_perk:{id:"tech-iridium_smelting_perk",title:F("tech_iridium_smelting"),desc:F("tech_iridium_smelting"),category:"mining",era:"early_space",path:["standard"],reqs:{smelting:6,space:3},condition:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=3),grant:["irid_smelting",1],cost:{Knowledge:()=>35e4,Mythril:()=>2500},effect:F("tech_iridium_smelting_effect"),action(){return!!Os($(this)[0])}},rotary_kiln:{id:"tech-rotary_kiln",title:F("tech_rotary_kiln"),desc:F("tech_rotary_kiln"),category:"mining",era:"industrialized",reqs:{smelting:3,high_tech:3},grant:["copper",1],cost:{Knowledge:()=>57600,Coal:()=>8e3},effect:F("tech_rotary_kiln_effect"),action(){return!!Os($(this)[0])}},metal_working:{id:"tech-metal_working",title:F("tech_metal_working"),desc:F("tech_metal_working_desc"),category:"mining",era:"civilized",reqs:{mining:1},grant:["mining",2],cost:{Knowledge:()=>350},effect:F("tech_metal_working_effect"),action(){return!!Os($(this)[0])&&(t.city.mine={count:0,on:0},!0)}},iron_mining:{id:"tech-iron_mining",title:F("tech_iron_mining"),desc:F("tech_iron_mining_desc"),category:"mining",era:"civilized",reqs:{mining:2},grant:["mining",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?500:2500},effect:F("tech_iron_mining_effect"),action(){return!!Os($(this)[0])&&(t.resource.Iron.display=!0,t.city.foundry&&t.city.foundry.count>0&&(t.resource.Wrought_Iron.display=!0,ha()),!0)},post(){zi()}},coal_mining:{id:"tech-coal_mining",title:F("tech_coal_mining"),desc:F("tech_coal_mining_desc"),category:"power_generation",era:"civilized",reqs:{mining:3},grant:["mining",4],cost:{Knowledge:()=>4320},effect:F("tech_coal_mining_effect"),action(){return!!Os($(this)[0])&&(t.city.coal_mine={count:0,on:0},t.resource.Coal.display=!0,!0)},post(){zi()}},storage:{id:"tech-storage",title:F("tech_storage"),desc:F("tech_storage_desc"),category:"storage",era:"civilized",reqs:{primitive:3,currency:1},grant:["storage",1],cost:{Knowledge:()=>20},effect:F("tech_storage_effect"),action(){return!!Os($(this)[0])&&(t.city.shed={count:0},!0)}},reinforced_shed:{id:"tech-reinforced_shed",title:F("tech_reinforced_shed"),desc:F("tech_reinforced_shed_desc"),category:"storage",era:"civilized",reqs:{storage:1,cement:1,mining:3},grant:["storage",2],cost:{Money:()=>3750,Knowledge:()=>2550,Iron:()=>750,Cement:()=>500},effect:F("tech_reinforced_shed_effect"),action(){return!!Os($(this)[0])}},barns:{id:"tech-barns",title:F("tech_barns"),desc:F("tech_barns_desc"),category:"storage",era:"discovery",reqs:{storage:2,smelting:2,alumina:1},grant:["storage",3],cost:{Knowledge:()=>15750,Aluminium:()=>3e3,Steel:()=>3e3},effect:F("tech_barns_effect"),action(){return!!Os($(this)[0])},post(){Ks(!1,["city-shed"])}},warehouse:{id:"tech-warehouse",title:F("tech_warehouse"),desc:F("tech_warehouse_desc"),category:"storage",era:"industrialized",reqs:{storage:3,high_tech:3,smelting:2},grant:["storage",4],cost:{Knowledge:()=>40500,Titanium:()=>3e3},effect:F("tech_warehouse_effect"),action(){return!!Os($(this)[0])},post(){Ks(!1,["city-shed"])}},cameras:{id:"tech-cameras",title:F("tech_cameras"),desc:F("tech_cameras_desc"),category:"storage",era:"globalized",reqs:{storage:4,high_tech:4},grant:["storage",5],cost:{Money:()=>9e4,Knowledge:()=>65e3},effect:F("tech_cameras_effect"),action(){return!!Os($(this)[0])}},pocket_dimensions:{id:"tech-pocket_dimensions",title:F("tech_pocket_dimensions"),desc:F("tech_pocket_dimensions_desc"),category:"storage",era:"early_space",path:["standard"],reqs:{particles:1,storage:5},grant:["storage",6],cost:{Knowledge:()=>108e3},effect:F("tech_pocket_dimensions_effect"),action(){return!!Os($(this)[0])}},ai_logistics:{id:"tech-ai_logistics",title:F("tech_ai_logistics"),desc:F("tech_ai_logistics"),category:"storage",era:"interstellar",reqs:{storage:6,proxima:2,science:13},grant:["storage",7],cost:{Knowledge:()=>65e4},effect:F("tech_ai_logistics_effect"),action(){return!!Os($(this)[0])}},containerization:{id:"tech-containerization",title:F("tech_containerization"),desc:F("tech_containerization_desc"),category:"storage",era:"civilized",reqs:{cement:1,mining:1,storage:1,science:1},grant:["container",1],cost:{Knowledge:()=>2700},effect:F("tech_containerization_effect"),action(){return!!Os($(this)[0])&&(t.city.storage_yard={count:0},!0)}},reinforced_crates:{id:"tech-reinforced_crates",title:F("tech_reinforced_crates"),desc:F("tech_reinforced_crates"),category:"storage",era:"civilized",reqs:{container:1,smelting:2},grant:["container",2],cost:{Knowledge:()=>6750,Sheet_Metal:()=>100},effect(){if(t.race.smoldering||t.race.kindling_kindred||t.race.evil){let e=F("resource_Bones_name");return t.race.smoldering?e=F("resource_Chrysotile_name"):t.race.kindling_kindred&&(e=F("resource_Stone_name")),F("tech_reinforced_crates_alt_effect",[e])}return F("tech_reinforced_crates_effect")},action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},cranes:{id:"tech-cranes",title:F("tech_cranes"),desc:F("tech_cranes_desc"),category:"storage",era:"discovery",reqs:{container:2,high_tech:2},grant:["container",3],cost:{Knowledge:()=>18e3,Copper:()=>1e3,Steel:()=>2500},effect:F("tech_cranes_effect"),action(){return!!Os($(this)[0])}},titanium_crates:{id:"tech-titanium_crates",title:()=>F("tech_titanium_crates",[t.resource.Titanium.name]),desc:()=>F("tech_titanium_crates",[t.resource.Titanium.name]),category:"storage",era:"globalized",reqs:{container:3,titanium:1},grant:["container",4],cost:{Knowledge:()=>67500,Titanium:()=>1e3},effect:()=>F("tech_titanium_crates_effect",[t.resource.Titanium.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},mythril_crates:{id:"tech-mythril_crates",title:()=>F("tech_mythril_crates",[t.resource.Mythril.name]),desc:()=>F("tech_mythril_crates",[t.resource.Mythril.name]),category:"storage",era:"early_space",reqs:{container:4,space:3},grant:["container",5],cost:{Knowledge:()=>145e3,Mythril:()=>350},effect:()=>F("tech_mythril_crates_effect",[t.resource.Mythril.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},infernite_crates:{id:"tech-infernite_crates",title:()=>F("tech_crates",[t.resource.Infernite.name]),desc:()=>F("tech_infernite_crates_desc",[t.resource.Infernite.name]),category:"storage",era:"interstellar",reqs:{container:5,infernite:1},grant:["container",6],cost:{Knowledge:()=>575e3,Infernite:()=>1e3},effect:()=>F("tech_infernite_crates_effect",[t.resource.Infernite.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},graphene_crates:{id:"tech-graphene_crates",title:()=>F("tech_crates",[t.resource.Graphene.name]),desc:()=>F("tech_crates",[t.resource.Graphene.name]),category:"storage",era:"interstellar",path:["standard","truepath"],reqs:{container:6,graphene:1},grant:["container",7],cost:{Knowledge:()=>725e3,Graphene:()=>75e3},effect:()=>F("tech_graphene_crates_effect",[t.resource.Graphene.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},bolognium_crates:{id:"tech-bolognium_crates",title:()=>F("tech_crates",[t.resource.Bolognium.name]),desc:()=>F("tech_crates",[t.resource.Bolognium.name]),category:"storage",era:"intergalactic",reqs:{container:7,gateway:3},grant:["container",8],cost:{Knowledge:()=>342e4,Bolognium:()=>9e4},effect:()=>F("tech_bolognium_crates_effect",[t.resource.Bolognium.name]),action(){return!!Os($(this)[0])}},steel_containers:{id:"tech-steel_containers",title:()=>F("tech_containers",[t.resource.Steel.name]),desc:()=>F("tech_steel_containers_desc",[t.resource.Steel.name]),category:"storage",era:"discovery",reqs:{smelting:2,container:1},grant:["steel_container",1],cost:{Knowledge:()=>9e3,Steel:()=>250},effect(){if(t.race.smoldering||t.race.kindling_kindred||t.race.evil){let e=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood";return F("tech_steel_containers_alt_effect",[t.resource[e].name,t.resource.Steel.name])}return F("tech_steel_containers_effect",[t.resource.Steel.name])},action(){return!!Os($(this)[0])&&(t.city.warehouse={count:0},!0)}},gantry_crane:{id:"tech-gantry_crane",title:F("tech_gantry_crane"),desc:F("tech_gantry_crane_desc"),category:"storage",era:"discovery",reqs:{steel_container:1,high_tech:2},grant:["steel_container",2],cost:{Knowledge:()=>22500,Steel:()=>5e3},effect:F("tech_gantry_crane_effect"),action(){return!!Os($(this)[0])}},alloy_containers:{id:"tech-alloy_containers",title:()=>F("tech_containers",[t.resource.Alloy.name]),desc:()=>F("tech_alloy_containers_desc",[t.resource.Alloy.name]),category:"storage",era:"industrialized",reqs:{steel_container:2,storage:4},grant:["steel_container",3],cost:{Knowledge:()=>49500,Alloy:()=>2500},effect:()=>F("tech_alloy_containers_effect",[t.resource.Alloy.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},mythril_containers:{id:"tech-mythril_containers",title:()=>F("tech_containers",[t.resource.Mythril.name]),desc:()=>F("tech_mythril_containers_desc",[t.resource.Mythril.name]),category:"storage",era:"early_space",reqs:{steel_container:3,space:3},grant:["steel_container",4],cost:{Knowledge:()=>165e3,Mythril:()=>500},effect:()=>F("tech_mythril_containers_effect",[t.resource.Mythril.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},adamantite_containers:{id:"tech-adamantite_containers",title:()=>F("tech_containers",[t.resource.Adamantite.name]),desc:()=>F("tech_adamantite_containers_desc",[t.resource.Adamantite.name]),category:"storage",era:"interstellar",reqs:{steel_container:4,alpha:2},grant:["steel_container",5],cost:{Knowledge:()=>525e3,Adamantite:()=>17500},effect:()=>F("tech_adamantite_containers_effect",[t.resource.Adamantite.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},aerogel_containers:{id:"tech-aerogel_containers",title:()=>F("tech_containers",[t.resource.Aerogel.name]),desc:()=>F("tech_containers",[t.resource.Aerogel.name]),category:"storage",era:"interstellar",reqs:{steel_container:5,aerogel:1},grant:["steel_container",6],cost:{Knowledge:()=>775e3,Aerogel:()=>500},effect:()=>F("tech_aerogel_containers_effect",[t.resource.Aerogel.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},bolognium_containers:{id:"tech-bolognium_containers",title:()=>F("tech_containers",[t.resource.Bolognium.name]),desc:()=>F("tech_containers",[t.resource.Bolognium.name]),category:"storage",era:"intergalactic",reqs:{steel_container:6,gateway:3},grant:["steel_container",7],cost:{Knowledge:()=>35e5,Bolognium:()=>125e3},effect:()=>F("tech_bolognium_containers_effect",[t.resource.Bolognium.name]),action(){return!!Os($(this)[0])}},nanoweave_containers:{id:"tech-nanoweave_containers",title:()=>F("tech_nanoweave_containers",[t.resource.Nanoweave.name]),desc:()=>F("tech_nanoweave_containers",[t.resource.Nanoweave.name]),category:"storage",era:"intergalactic",reqs:{steel_container:7,nanoweave:1},grant:["steel_container",8],cost:{Knowledge:()=>9e6,Nanoweave:()=>5e4},effect:()=>F("tech_nanoweave_containers_effect",[t.resource.Nanoweave.name]),action(){return!!Os($(this)[0])}},evil_planning:{id:"tech-evil_planning",title:F("tech_urban_planning"),desc:F("tech_urban_planning"),category:"queues",era:"civilized",wiki:!!t.race.terrifying,reqs:{banking:2},grant:["queue",1],trait:["terrifying"],cost:{Knowledge:()=>2500},effect:F("tech_urban_planning_effect"),action(){return!!Os($(this)[0])&&(t.queue.display=!0,!0)},post(){Ri()}},urban_planning:{id:"tech-urban_planning",title:F("tech_urban_planning"),desc:F("tech_urban_planning"),category:"queues",era:"civilized",wiki:!t.race.terrifying,reqs:{banking:2,currency:2},grant:["queue",1],not_trait:["terrifying"],cost:{Knowledge:()=>2500},effect:F("tech_urban_planning_effect"),action(){return!!Os($(this)[0])&&(t.queue.display=!0,t.settings.msgFilters.queue.unlocked||(t.settings.msgFilters.queue.unlocked=!0,t.settings.msgFilters.queue.vis=!0),!0)},post(){Ri()}},zoning_permits:{id:"tech-zoning_permits",title:F("tech_zoning_permits"),desc:F("tech_zoning_permits"),category:"queues",era:"industrialized",reqs:{queue:1,high_tech:3},grant:["queue",2],cost:{Knowledge:()=>28e3},effect:()=>F("tech_zoning_permits_effect",[t.genes.queue&&t.genes.queue>=2?4:2]),action(){return!!Os($(this)[0])},post(){Ri()}},urbanization:{id:"tech-urbanization",title:F("tech_urbanization"),desc:F("tech_urbanization"),category:"queues",era:"globalized",reqs:{queue:2,high_tech:6},grant:["queue",3],cost:{Knowledge:()=>95e3},effect:()=>F("tech_urbanization_effect",[t.genes.queue&&t.genes.queue>=2?6:3]),action(){return!!Os($(this)[0])},post(){Ri()}},assistant:{id:"tech-assistant",title:F("tech_assistant"),desc:F("tech_assistant"),category:"queues",era:"civilized",reqs:{queue:1,science:4},grant:["r_queue",1],cost:{Knowledge:()=>5e3},effect:F("tech_assistant_effect"),action(){return!!Os($(this)[0])&&(t.r_queue.display=!0,t.settings.msgFilters.building_queue.unlocked||(t.settings.msgFilters.building_queue.unlocked=!0,t.settings.msgFilters.building_queue.vis=!0,t.settings.msgFilters.research_queue.unlocked=!0,t.settings.msgFilters.research_queue.vis=!0),!0)},post(){Hi(),t.settings.tabLoad&&$("#resQueue").removeAttr("style")}},government:{id:"tech-government",title:F("tech_government"),desc:F("tech_government_desc"),category:"government",era:"civilized",reqs:{currency:1},grant:["govern",1],cost:{Knowledge:()=>750},effect:F("tech_government_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#govType"},"update"),sc({el:"#foreign"},"update"),sc({el:"#government .govTabs2"},"update"),t.settings.tabLoad&&$("#government .govTabs2").removeAttr("style")}},theocracy:{id:"tech-theocracy",title:F("govern_theocracy"),desc:F("govern_theocracy"),category:"government",era:"civilized",reqs:{govern:1,theology:2},grant:["gov_theo",1],cost:{Knowledge:()=>1200},effect:F("tech_theocracy_effect"),action(){return!!Os($(this)[0])}},republic:{id:"tech-republic",title:F("govern_republic"),desc:F("govern_republic"),category:"government",era:"discovery",reqs:{govern:1},condition:()=>!!(t.tech.trade&&t.tech.trade>=2||t.race.terrifying),grant:["govern",2],cost:{Knowledge:()=>17e3},effect:F("tech_republic_effect"),action(){return!!Os($(this)[0])}},socialist:{id:"tech-socialist",title:F("govern_socialist"),desc:F("govern_socialist"),category:"government",era:"discovery",reqs:{govern:1},condition:()=>!!(t.tech.trade&&t.tech.trade>=2||t.race.terrifying),grant:["gov_soc",1],cost:{Knowledge:()=>17e3},effect:F("tech_socialist_effect"),action(){return!!Os($(this)[0])}},corpocracy:{id:"tech-corpocracy",title:F("govern_corpocracy"),desc:F("govern_corpocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},grant:["gov_corp",1],cost:{Knowledge:()=>26e3},effect:F("tech_corpocracy_effect"),action(){return!!Os($(this)[0])}},technocracy:{id:"tech-technocracy",title:F("govern_technocracy"),desc:F("govern_technocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},grant:["govern",3],cost:{Knowledge:()=>26e3},effect:F("tech_technocracy_effect"),action(){return!!Os($(this)[0])}},federation:{id:"tech-federation",title:F("govern_federation"),desc:F("govern_federation"),category:"government",era:"early_space",reqs:{govern:2},condition:()=>t.tech.unify&&t.tech.unify>=2||ue(),grant:["gov_fed",1],cost:{Knowledge:()=>3e4},effect:F("tech_federation_effect"),action(){return!!Os($(this)[0])}},magocracy:{id:"tech-magocracy",title:F("govern_magocracy"),desc:F("govern_magocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},condition:()=>"magic"===t.race.universe,grant:["gov_mage",1],cost:{Knowledge:()=>26e3},effect:F("tech_magocracy_effect"),action(){return!!Os($(this)[0])}},governor:{id:"tech-governor",title:F("tech_governor"),desc:F("tech_governor"),category:"government",era:"civilized",reqs:{govern:1},condition:()=>!(!t.genes.governor||"anarchy"===t.civic.govern.type),grant:["governor",1],cost:{Knowledge:()=>1e3},effect:F("tech_governor_effect"),action(){return!!Os($(this)[0])&&(t.settings.showGovernor=!0,!0)},post(){K()}},spy:{id:"tech-spy",title:F("tech_spy"),desc:F("tech_spy"),category:"spies",era:"civilized",reqs:{govern:1},grant:["spy",1],cost:{Knowledge:()=>1250},effect:F("tech_spy_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#foreign"},"update")}},espionage:{id:"tech-espionage",title:F("tech_espionage"),desc:F("tech_espionage"),category:"spies",era:"discovery",reqs:{spy:1,high_tech:1},grant:["spy",2],cost:{Knowledge:()=>7500},effect:F("tech_espionage_effect"),action(){return!!Os($(this)[0])&&(t.settings.msgFilters.spy.unlocked||(t.settings.msgFilters.spy.unlocked=!0,t.settings.msgFilters.spy.vis=!0),!0)},post(){sc({el:"#foreign"},"update")}},spy_training:{id:"tech-spy_training",title:F("tech_spy_training"),desc:F("tech_spy_training"),category:"spies",era:"discovery",reqs:{spy:2,boot_camp:1},grant:["spy",3],cost:{Knowledge:()=>1e4},effect:F("tech_spy_training_effect"),action(){return!!Os($(this)[0])}},spy_gadgets:{id:"tech-spy_gadgets",title:F("tech_spy_gadgets"),desc:F("tech_spy_gadgets"),category:"spies",era:"discovery",reqs:{spy:3,high_tech:2},grant:["spy",4],cost:{Knowledge:()=>15e3},effect:F("tech_spy_gadgets_effect"),action(){return!!Os($(this)[0])}},code_breakers:{id:"tech-code_breakers",title:F("tech_code_breakers"),desc:F("tech_code_breakers"),category:"spies",era:"industrialized",reqs:{spy:4,high_tech:4},grant:["spy",5],cost:{Knowledge:()=>55e3},effect:F("tech_code_breakers_effect"),action(){return!!Os($(this)[0])}},currency:{id:"tech-currency",title:F("tech_currency"),desc:F("tech_currency_desc"),category:"banking",era:"civilized",reqs:{housing:1},grant:["currency",1],cost:{Knowledge:()=>22,Lumber:()=>10},effect:F("tech_currency_effect"),action(){return!!Os($(this)[0])&&(t.resource.Money.display=!0,!0)}},market:{id:"tech-market",title:F("tech_market"),desc:F("tech_market_desc"),category:"banking",era:"civilized",reqs:{banking:1,govern:1},not_trait:["terrifying"],grant:["currency",2],cost:{Knowledge:()=>t.race.banana?300:1800},effect:F("tech_market_effect"),action(){return!!Os($(this)[0])&&(t.settings.showResources=!0,t.settings.showMarket=!0,!0)}},tax_rates:{id:"tech-tax_rates",title:F("tech_tax_rates"),desc:F("tech_tax_rates_desc"),category:"banking",era:"civilized",reqs:{banking:2,currency:2,queue:1},not_trait:["terrifying"],grant:["currency",3],cost:{Knowledge:()=>3375},effect:F("tech_tax_rates_effect"),action(){return!!Os($(this)[0])&&(t.civic.taxes.display=!0,!0)}},large_trades:{id:"tech-large_trades",title:F("tech_large_trades"),desc:F("tech_large_trades_desc"),category:"market",era:"civilized",reqs:{currency:3},not_trait:["terrifying"],grant:["currency",4],cost:{Knowledge:()=>6750},effect:F("tech_large_trades_effect"),action(){return!!Os($(this)[0])},post(){t.race.noble&&(t.tech.currency=5,ms())}},corruption:{id:"tech-corruption",title:F("tech_corruption"),desc:F("tech_corruption_desc"),category:"banking",era:"industrialized",reqs:{currency:4,high_tech:3},not_trait:["terrifying","noble"],grant:["currency",5],cost:{Knowledge:()=>36e3},effect:F("tech_corruption_effect"),action(){return!!Os($(this)[0])}},massive_trades:{id:"tech-massive_trades",title:F("tech_massive_trades"),desc:F("tech_massive_trades_desc"),category:"market",era:"globalized",reqs:{currency:5,high_tech:4},not_trait:["terrifying"],grant:["currency",6],cost:{Knowledge:()=>108e3},effect:F("tech_massive_trades_effect"),action(){return!!Os($(this)[0])}},trade:{id:"tech-trade",title:F("tech_trade"),desc:F("tech_trade_desc"),category:"market",era:"civilized",reqs:{currency:2,military:1},not_trait:["terrifying"],grant:["trade",1],cost:{Knowledge:()=>t.race.banana?1200:4500},effect:F("tech_trade_effect"),action(){return!!Os($(this)[0])&&(t.city.trade={count:0},t.city.market.active=!0,!0)}},diplomacy:{id:"tech-diplomacy",title:F("tech_diplomacy"),desc:F("tech_diplomacy_desc"),category:"market",era:"discovery",reqs:{trade:1,high_tech:1},not_trait:["terrifying"],grant:["trade",2],cost:{Knowledge:()=>16200},effect:F("tech_diplomacy_effect"),action(){return!!Os($(this)[0])}},freight:{id:"tech-freight",title:F("tech_freight"),desc:F("tech_freight_desc"),category:"market",era:"industrialized",reqs:{trade:2,high_tech:3},not_trait:["terrifying"],grant:["trade",3],cost:{Knowledge:()=>37800},effect:F("tech_freight_effect"),action(){return!!Os($(this)[0])},post(){t.tech.high_tech>=6&&Oe("Physics")}},wharf:{id:"tech-wharf",title:F("tech_wharf"),desc:F("tech_wharf_desc"),category:"market",era:"industrialized",reqs:{trade:1,high_tech:3,oil:1},not_trait:["thalassophobia"],grant:["wharf",1],cost:{Knowledge:()=>44e3},effect:F("tech_wharf_effect"),action(){return!!Os($(this)[0])&&(t.city.wharf={count:0},!0)}},banking:{id:"tech-banking",title:F("tech_banking"),desc:F("tech_banking_desc"),category:"banking",era:"civilized",reqs:{currency:1},grant:["banking",1],cost:{Knowledge:()=>90},effect:F("tech_banking_effect"),action(){return!!Os($(this)[0])&&(t.city.bank={count:0},!0)}},investing:{id:"tech-investing",title:F("tech_investing"),desc:F("tech_investing_desc"),category:"banking",era:"civilized",reqs:{banking:1},grant:["banking",2],cost:{Money:()=>2500,Knowledge:()=>900},effect:F("tech_investing_effect"),action(){return!!Os($(this)[0])&&(t.civic.banker.display=!0,!0)}},vault:{id:"tech-vault",title:F("tech_vault"),desc:F("tech_vault_desc"),category:"banking",era:"civilized",reqs:{banking:2,cement:1},grant:["banking",3],cost:{Money:()=>2e3,Knowledge:()=>3600,Iron:()=>500,Cement:()=>750},effect:F("tech_vault_effect"),action(){return!!Os($(this)[0])}},bonds:{id:"tech-bonds",title:F("tech_bonds"),desc:F("tech_bonds"),category:"banking",era:"civilized",reqs:{banking:3},grant:["banking",4],cost:{Money:()=>2e4,Knowledge:()=>5e3},effect:F("tech_bonds_effect"),action(){return!!Os($(this)[0])}},steel_vault:{id:"tech-steel_vault",title:F("tech_steel_vault"),desc:F("tech_steel_vault"),category:"banking",era:"civilized",reqs:{banking:4,smelting:2},grant:["banking",5],cost:{Money:()=>3e4,Knowledge:()=>6750,Steel:()=>3e3},effect:F("tech_steel_vault_effect"),action(){return!!Os($(this)[0])}},eebonds:{id:"tech-eebonds",title:F("tech_eebonds"),desc:F("tech_eebonds"),category:"banking",era:"discovery",reqs:{banking:5,high_tech:1},grant:["banking",6],cost:{Money:()=>75e3,Knowledge:()=>18e3},effect:F("tech_eebonds_effect"),action(){return!!Os($(this)[0])}},swiss_banking:{id:"tech-swiss_banking",title:Ur(),desc:Ur(),category:"banking",era:"industrialized",reqs:{banking:6},grant:["banking",7],cost:{Money:()=>125e3,Knowledge:()=>45e3},effect:F("tech_swiss_banking_effect"),action(){return!!Os($(this)[0])}},safety_deposit:{id:"tech-safety_deposit",title:F("tech_safety_deposit"),desc:F("tech_safety_deposit"),category:"banking",era:"globalized",reqs:{banking:7,high_tech:4},grant:["banking",8],cost:{Money:()=>25e4,Knowledge:()=>67500},effect:F("tech_safety_deposit_effect"),action(){return!!Os($(this)[0])}},stock_market:{id:"tech-stock_market",title:F("tech_stock_market"),desc:F("tech_stock_market"),category:"arpa",era:"globalized",reqs:{banking:8,high_tech:6},grant:["banking",9],cost:{Money:()=>325e3,Knowledge:()=>108e3},effect:F("tech_stock_market_effect"),action(){return!!Os($(this)[0])},post(){Oe("Physics")}},hedge_funds:{id:"tech-hedge_funds",title:F("tech_hedge_funds"),desc:F("tech_hedge_funds"),category:"banking",era:"early_space",reqs:{banking:9,stock_exchange:1},grant:["banking",10],cost:{Money:()=>375e3,Knowledge:()=>126e3},effect:F("tech_hedge_funds_effect"),action(){return!!Os($(this)[0])}},four_oh_one:{id:"tech-four_oh_one",title:F("tech_four_oh_one"),desc:F("tech_four_oh_one"),category:"banking",era:"early_space",reqs:{banking:10},grant:["banking",11],cost:{Money:()=>425e3,Knowledge:()=>144e3},effect:F("tech_four_oh_one_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_four_oh_one_flair")},exchange:{id:"tech-exchange",title:F("tech_exchange"),desc:F("tech_exchange"),category:"banking",era:"interstellar",reqs:{banking:11,alpha:2,graphene:1},grant:["banking",12],cost:{Money:()=>1e6,Knowledge:()=>675e3},effect:F("tech_exchange_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.exchange={count:0,on:0},!0)}},foreign_investment:{id:"tech-foreign_investment",title:F("tech_foreign_investment"),desc:F("tech_foreign_investment"),category:"banking",era:"intergalactic",reqs:{banking:12,xeno:10},grant:["banking",13],cost:{Money:()=>1e8,Knowledge:()=>8e6},effect:F("tech_foreign_investment_effect"),action(){return!!Os($(this)[0])}},mythril_vault:{id:"tech-mythril_vault",title:F("tech_mythril_vault"),desc:F("tech_mythril_vault"),category:"banking",era:"early_space",reqs:{banking:5,space:3},grant:["vault",1],cost:{Money:()=>5e5,Knowledge:()=>15e4,Mythril:()=>750},effect:F("tech_mythril_vault_effect"),action(){return!!Os($(this)[0])}},neutronium_vault:{id:"tech-neutronium_vault",title:F("tech_neutronium_vault"),desc:F("tech_neutronium_vault"),category:"banking",era:"deep_space",reqs:{vault:1,gas_moon:1},grant:["vault",2],cost:{Money:()=>75e4,Knowledge:()=>28e4,Neutronium:()=>650},effect:F("tech_neutronium_vault_effect"),action(){return!!Os($(this)[0])}},adamantite_vault:{id:"tech-adamantite_vault",title:F("tech_adamantite_vault"),desc:F("tech_adamantite_vault"),category:"banking",era:"interstellar",reqs:{vault:2,alpha:2},grant:["vault",3],cost:{Money:()=>2e6,Knowledge:()=>56e4,Adamantite:()=>2e4},effect:F("tech_adamantite_vault_effect"),action(){return!!Os($(this)[0])}},graphene_vault:{id:"tech-graphene_vault",title:F("tech_graphene_vault"),desc:F("tech_graphene_vault"),category:"banking",era:"interstellar",path:["standard","truepath"],reqs:{vault:3,graphene:1},grant:["vault",4],cost:{Money:()=>3e6,Knowledge:()=>75e4,Graphene:()=>4e5},effect:F("tech_graphene_vault_effect"),action(){return!!Os($(this)[0])}},home_safe:{id:"tech-home_safe",title:F("tech_home_safe"),desc:F("tech_home_safe"),category:"banking",era:"discovery",reqs:{banking:5},grant:["home_safe",1],cost:{Money:()=>42e3,Knowledge:()=>8e3,Steel:()=>4500},effect:F("tech_home_safe_effect"),action(){return!!Os($(this)[0])}},fire_proof_safe:{id:"tech-fire_proof_safe",title:F("tech_fire_proof_safe"),desc:F("tech_fire_proof_safe"),category:"banking",era:"early_space",reqs:{home_safe:1,space:3},grant:["home_safe",2],cost:{Money:()=>25e4,Knowledge:()=>12e4,Iridium:()=>1e3},effect:F("tech_fire_proof_safe_effect"),action(){return!!Os($(this)[0])}},tamper_proof_safe:{id:"tech-tamper_proof_safe",title:F("tech_tamper_proof_safe"),desc:F("tech_tamper_proof_safe"),category:"banking",era:"interstellar",reqs:{home_safe:2,infernite:1},grant:["home_safe",3],cost:{Money:()=>25e5,Knowledge:()=>6e5,Infernite:()=>800},effect:F("tech_tamper_proof_safe_effect"),action(){return!!Os($(this)[0])}},monument:{id:"tech-monument",title:F("tech_monument"),desc:F("tech_monument"),category:"arpa",era:"globalized",reqs:{high_tech:6},grant:["monument",1],cost:{Knowledge:()=>12e4},effect:F("tech_monument_effect"),action(){return!!Os($(this)[0])&&(t.arpa.m_type=Oe("Monument"),!0)},post(){Oe("Physics")}},tourism:{id:"tech-tourism",title:F("tech_tourism"),desc:F("tech_tourism"),category:"banking",era:"early_space",reqs:{monuments:2,monument:1},not_trait:["cataclysm","lone_survivor"],grant:["monument",2],cost:{Knowledge:()=>15e4},effect:F("tech_tourism_effect"),action(){return!!Os($(this)[0])&&(t.city.tourist_center={count:0,on:0},!0)}},xeno_tourism:{id:"tech-xeno_tourism",title:F("tech_xeno_tourism"),desc:F("tech_xeno_tourism"),category:"banking",era:"intergalactic",reqs:{monument:2,xeno:10,monuments:10},not_trait:["cataclysm"],grant:["monument",3],cost:{Knowledge:()=>8e6},effect:F("tech_xeno_tourism_effect"),action(){return!!Os($(this)[0])}},science:{id:"tech-science",title:F("tech_science"),desc:F("tech_science_desc"),category:"science",era:"civilized",reqs:{housing:1},grant:["science",1],cost:{Knowledge:()=>65},effect:F("tech_science_effect"),action(){return!!Os($(this)[0])&&(t.city.university={count:0},!0)}},library:{id:"tech-library",title:F("tech_library"),desc:F("tech_library_desc"),category:"science",era:"civilized",reqs:{science:1,cement:1},grant:["science",2],cost:{Knowledge:()=>720},effect:F("tech_library_effect"),action(){return!!Os($(this)[0])&&(t.city.library={count:0},!0)}},thesis:{id:"tech-thesis",title:F("tech_thesis"),desc:F("tech_thesis_desc"),category:"science",era:"civilized",reqs:{science:2},grant:["science",3],cost:{Knowledge:()=>1125},effect:F("tech_thesis_effect"),action(){return!!Os($(this)[0])}},research_grant:{id:"tech-research_grant",title:F("tech_research_grant"),desc:F("tech_research_grant_desc"),category:"science",era:"civilized",reqs:{science:3},grant:["science",4],cost:{Knowledge:()=>3240},effect:F("tech_research_grant_effect"),action(){return!!Os($(this)[0])}},scientific_journal:{id:"tech-scientific_journal",title:()=>"magic"===t.race.universe?F("tech_magic_tomes"):F("tech_scientific_journal"),desc:()=>"magic"===t.race.universe?F("tech_magic_tomes_desc"):F("tech_scientific_journal_desc"),category:"science",era:"industrialized",reqs:{science:4,high_tech:3},grant:["science",5],cost:{Knowledge:()=>27e3},effect:()=>"magic"===t.race.universe?F("tech_magic_tomes_effect"):F("tech_scientific_journal_effect"),action(){return!!Os($(this)[0])}},adjunct_professor:{id:"tech-adjunct_professor",title:F("tech_adjunct_professor"),desc:F("tech_adjunct_professor"),category:"science",era:"industrialized",reqs:{science:5},grant:["science",6],cost:{Knowledge:()=>36e3},effect:()=>F("tech_adjunct_professor_effect",[Ts(),t.civic.scientist?t.civic.scientist.name:F("job_scientist")]),action(){return!!Os($(this)[0])}},tesla_coil:{id:"tech-tesla_coil",title:F("tech_tesla_coil"),desc:F("tech_tesla_coil_desc"),category:"science",era:"industrialized",reqs:{science:6,high_tech:3},grant:["science",7],cost:{Knowledge:()=>51750},effect:()=>F("tech_tesla_coil_effect",[Ts()]),action(){return!!Os($(this)[0])}},internet:{id:"tech-internet",title:F("tech_internet"),desc:F("tech_internet"),category:"science",era:"globalized",reqs:{science:7,high_tech:4},grant:["science",8],cost:{Knowledge:()=>61200},effect:F("tech_internet_effect"),action(){return!!Os($(this)[0])&&(t.race.toxic&&"troll"===t.race.species&&Xc("godwin"),!0)}},observatory:{id:"tech-observatory",title:F("tech_observatory"),desc:F("tech_observatory"),category:"science",era:"early_space",reqs:{science:8,space:3,luna:1},grant:["science",9],cost:{Knowledge:()=>148e3},effect:F("tech_observatory_effect"),action(){return!!Os($(this)[0])&&(t.space.observatory={count:0,on:0},!0)}},world_collider:{id:"tech-world_collider",title:F("tech_world_collider"),desc:F("tech_world_collider"),category:"science",era:"deep_space",path:["standard"],reqs:{science:9,elerium:2},grant:["science",10],cost:{Knowledge:()=>35e4},effect:()=>F("tech_world_collider_effect",[Xt().dwarf]),action(){return!!Os($(this)[0])&&(t.space.world_collider={count:0},t.space.world_controller={count:0,on:0},!0)},flair:`
    ${F("tech_world_collider_flair1")}
    ${F("tech_world_collider_flair2")}
    `},laboratory:{id:"tech-laboratory",title:()=>"magic"===t.race.universe?F("tech_sanctum"):F("tech_laboratory"),desc:()=>"magic"===t.race.universe?F("tech_sanctum"):F("tech_laboratory_desc"),category:"science",era:"interstellar",reqs:{science:11,alpha:2},grant:["science",12],cost:{Knowledge:()=>5e5},effect:()=>"magic"===t.race.universe?F("tech_sanctum_effect"):F("tech_laboratory_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.laboratory={count:0,on:0},!0)},flair:()=>"magic"===t.race.universe?F("tech_sanctum_flair"):F("tech_laboratory_flair")},virtual_assistant:{id:"tech-virtual_assistant",title:F("tech_virtual_assistant"),desc:F("tech_virtual_assistant"),category:"science",era:"interstellar",reqs:{science:12,high_tech:12},grant:["science",13],cost:{Knowledge:()=>635e3},effect:()=>"magic"===t.race.universe?F("tech_virtual_assistant_magic_effect"):F("tech_virtual_assistant_effect"),action(){return!!Os($(this)[0])}},dimensional_readings:{id:"tech-dimensional_readings",title:F("tech_dimensional_readings"),desc:F("tech_dimensional_readings"),category:"science",era:"interstellar",reqs:{science:13,infernite:2},grant:["science",14],cost:{Knowledge:()=>75e4},effect:()=>F("tech_dimensional_readings_effect"),action(){return!!Os($(this)[0])}},quantum_entanglement:{id:"tech-quantum_entanglement",title:F("tech_quantum_entanglement"),desc:F("tech_quantum_entanglement"),category:"science",era:"interstellar",reqs:{science:14,neutron:1},grant:["science",15],cost:{Knowledge:()=>85e4,Neutronium:()=>7500,Soul_Gem:()=>2},effect:()=>F("tech_quantum_entanglement_effect",[2,"magic"===t.race.universe?F("tech_sanctum"):F("interstellar_laboratory_title"),Ts()]),action(){return!!Os($(this)[0])}},expedition:{id:"tech-expedition",title:()=>"magic"===t.race.universe?F("tech_expedition_wiz"):F("tech_expedition"),desc:()=>"magic"===t.race.universe?F("tech_expedition_wiz"):F("tech_expedition"),category:"science",era:"intergalactic",reqs:{science:15,xeno:4},grant:["science",16],cost:{Knowledge:()=>535e4},effect:()=>"magic"===t.race.universe?F("tech_expedition_wiz_effect"):F("tech_expedition_effect"),action(){return!!Os($(this)[0])}},subspace_sensors:{id:"tech-subspace_sensors",title:F("tech_subspace_sensors"),desc:F("tech_subspace_sensors"),category:"science",era:"intergalactic",reqs:{science:16,high_tech:16},grant:["science",17],cost:{Knowledge:()=>6e6},effect:()=>F("tech_subspace_sensors_effect"),action(){return!!Os($(this)[0])}},alien_database:{id:"tech-alien_database",title:F("tech_alien_database"),desc:F("tech_alien_database"),category:"progress",era:"intergalactic",reqs:{science:17,conflict:5},grant:["science",18],cost:{Knowledge:()=>825e4},effect:()=>F("tech_alien_database_effect"),action(){return!!Os($(this)[0])}},orichalcum_capacitor:{id:"tech-orichalcum_capacitor",title:F("tech_orichalcum_capacitor"),desc:F("tech_orichalcum_capacitor"),category:"science",era:"intergalactic",reqs:{science:18,high_tech:17},grant:["science",19],cost:{Knowledge:()=>125e5,Orichalcum:()=>25e4},effect:()=>F("tech_orichalcum_capacitor_effect"),action(){return!!Os($(this)[0])}},advanced_biotech:{id:"tech-advanced_biotech",title:F("tech_advanced_biotech"),desc:F("tech_advanced_biotech"),category:"science",era:"dimensional",reqs:{science:19,high_tech:18},grant:["science",20],cost:{Knowledge:()=>255e5},effect:()=>F("tech_advanced_biotech_effect"),action(){return!!Os($(this)[0])}},codex_infinium:{id:"tech-codex_infinium",title:F("tech_codex_infinium"),desc:F("tech_codex_infinium"),category:"science",era:"dimensional",reqs:{science:20,sphinx_bribe:1},grant:["science",21],cost:{Knowledge:()=>401e5,Codex:()=>1},effect:()=>F("tech_codex_infinium_effect"),action(){return!!Os($(this)[0])&&(t.resource.Codex.display=!1,!0)}},bioscience:{id:"tech-bioscience",title:F("tech_bioscience"),desc:F("tech_bioscience_desc"),category:"science",era:"globalized",reqs:{science:8},grant:["genetics",1],cost:{Knowledge:()=>67500},effect:F("tech_bioscience_effect"),action(){return!!Os($(this)[0])&&(t.city.biolab={count:0},!0)}},genetics:{id:"tech-genetics",title:F("tech_genetics"),desc:F("tech_genetics"),category:"arpa",era:"globalized",reqs:{genetics:1,high_tech:6},grant:["genetics",2],cost:{Knowledge:()=>108e3},effect:F("tech_genetics_effect"),action(){return!!Os($(this)[0])&&(t.settings.arpa.genetics=!0,t.arpa.sequence||(t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!t.race.cataclysm&&!t.race.orbit_decayed,boost:!1,auto:!1,labs:0}),!0)},post(){Oe("Genetics")}},crispr:{id:"tech-crispr",title:F("tech_crispr"),desc:F("tech_crispr"),category:"genes",era:"globalized",reqs:{genetics:3},grant:["genetics",4],cost:{Knowledge:()=>125e3},effect:()=>t.race.artifical?F("tech_crispr_effect_artifical"):F("tech_crispr_effect"),action(){return!!Os($(this)[0])&&(t.settings.arpa.crispr=!0,t.settings.arpa.arpaTabs=2,!0)},post(){Oe("Genetics"),Oe("Crispr")}},shotgun_sequencing:{id:"tech-shotgun_sequencing",title:F("tech_shotgun_sequencing"),desc:()=>t.race.artifical?F("tech_shotgun_sequencing_desc_artifical"):F("tech_shotgun_sequencing_desc"),category:"genes",era:"early_space",reqs:{genetics:4},grant:["genetics",5],cost:{Knowledge:()=>165e3},effect:()=>t.race.artifical?F("tech_shotgun_sequencing_effect_artifical"):F("tech_shotgun_sequencing_effect"),action(){return!!Os($(this)[0])&&(t.arpa.sequence.boost=!0,!0)},post(){Oe("Genetics")}},de_novo_sequencing:{id:"tech-de_novo_sequencing",title:F("tech_de_novo_sequencing"),desc:F("tech_de_novo_sequencing"),category:"genes",era:"early_space",reqs:{genetics:5},grant:["genetics",6],cost:{Knowledge:()=>22e4},effect:()=>t.race.artifical?F("tech_de_novo_sequencing_effect_artifical"):F("tech_de_novo_sequencing_effect"),action(){return!!Os($(this)[0])&&(t.resource.Genes.display=!0,!0)},post(){Oe("Genetics")}},dna_sequencer:{id:"tech-dna_sequencer",title:()=>t.race.artifical?F("tech_code_sequencer"):F("tech_dna_sequencer"),desc:()=>t.race.artifical?F("tech_code_sequencer"):F("tech_dna_sequencer"),category:"genes",era:"deep_space",reqs:{genetics:6},grant:["genetics",7],cost:{Knowledge:()=>3e5},effect:()=>t.race.artifical?F("tech_code_sequencer_effect"):F("tech_dna_sequencer_effect"),action(){return!!Os($(this)[0])&&(t.arpa.sequence.auto=!0,!0)},post(){Oe("Genetics")}},rapid_sequencing:{id:"tech-rapid_sequencing",title:()=>t.race.artifical?F("tech_agile_development"):F("tech_rapid_sequencing"),desc:()=>t.race.artifical?F("tech_agile_development"):F("tech_rapid_sequencing"),category:"genes",era:"interstellar",path:["standard","truepath"],reqs:{genetics:7,high_tech:12},grant:["genetics",8],cost:{Knowledge:()=>8e5},effect:()=>t.race.artifical?F("tech_agile_development_effect"):F("tech_rapid_sequencing_effect"),action(){return!!Os($(this)[0])}},mad_science:{id:"tech-mad_science",title:()=>"magic"===t.race.universe?F("tech_sages"):F("tech_mad_science"),desc:()=>"magic"===t.race.universe?F("tech_sages"):F("tech_mad_science"),category:"science",era:"discovery",reqs:{science:2,smelting:2},grant:["high_tech",1],cost:{Money:()=>1e4,Mana:()=>"magic"===t.race.universe?50:0,Knowledge:()=>6750,Crystal:()=>"magic"===t.race.universe?1e3:0,Aluminium:()=>750},effect:()=>"magic"===t.race.universe?F("tech_sages_effect"):F("tech_mad_science_effect"),action(){return!!Os($(this)[0])&&(t.race.terrifying&&(t.civic.taxes.display=!0),t.city.wardenclyffe={count:0,on:0},!0)}},electricity:{id:"tech-electricity",title:F("tech_electricity"),desc:F("tech_electricity"),category:"power_generation",era:"discovery",reqs:{high_tech:1},grant:["high_tech",2],cost:{Knowledge:()=>13500,Copper:()=>1e3},effect:F("tech_electricity_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_electricity_msg"),"info",!1,["progress"]),t.city.power=0,t.city.powered=!0,t.city.coal_power={count:0,on:0},t.settings.showPowerGrid=!0,ti(),!0)}},matter_replicator:{id:"tech-matter_replicator",title:()=>"antimatter"!==t.race.universe||t.race.amexplode?F("tech_replicator"):F("tech_antireplicator"),desc:()=>"antimatter"!==t.race.universe||t.race.amexplode?F("tech_replicator"):F("tech_antireplicator"),category:"special",era:"discovery",reqs:{high_tech:2},condition:()=>!!(t.stats.achieve.adam_eve&&t.stats.achieve.adam_eve.l>=5),not_trait:["lone_survivor"],grant:["replicator",1],cost:{Knowledge:()=>25e3},effect:()=>"antimatter"!==t.race.universe||t.race.amexplode?F("tech_replicator_effect_alt"):F("tech_antireplicator_effect_alt"),action(){if(Os($(this)[0])){if("antimatter"===t.race.universe&&t.race.amexplode){eo("annihilation"),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),$("body").addClass("nuke");let a=$('
    ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),500),setTimeout((function(){a.addClass("b")}),600),setTimeout((function(){window.soft_reset()}),4e3)}else t.race.replicator={res:"Stone",pow:1};return!0}return!1},post(){K()}},industrialization:{id:"tech-industrialization",title:F("tech_industrialization"),desc:F("tech_industrialization"),category:"progress",era:"industrialized",reqs:{high_tech:2,cement:2,steel_container:1},grant:["high_tech",3],cost:{Knowledge:()=>25200},effect:F("tech_industrialization_effect"),action(){return!!Os($(this)[0])&&(t.resource.Titanium.display=!0,t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:0,Nano:0,Stanene:0},!0)},post(){zi()}},electronics:{id:"tech-electronics",title:F("tech_electronics"),desc:F("tech_electronics"),category:"progress",era:"industrialized",reqs:{high_tech:3,titanium:1},grant:["high_tech",4],cost:{Knowledge:()=>5e4},effect:F("tech_electronics_effect"),action(){return!!Os($(this)[0])&&(t.race.terrifying&&(t.tech.gambling=1,t.city.casino={count:0,on:0},t.space.spc_casino={count:0,on:0}),!0)}},fission:{id:"tech-fission",title:F("tech_fission"),desc:F("tech_fission"),category:"progress",era:"globalized",reqs:{high_tech:4,uranium:1},grant:["high_tech",5],cost:{Knowledge:()=>77400,Uranium:()=>10},effect:F("tech_fission_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_fission_msg"),"info",!1,["progress"]),t.city.fission_power={count:0,on:0},!0)}},arpa:{id:"tech-arpa",title:F("tech_arpa"),desc:F("tech_arpa_desc"),category:"arpa",era:"globalized",reqs:{high_tech:5},grant:["high_tech",6],cost:{Knowledge:()=>9e4},effect:F("tech_arpa_effect"),action(){return!!Os($(this)[0])&&(t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.race.truepath&&!t.tech.unify&&(t.tech.unify=1),!0)},post(){Oe("Physics")}},rocketry:{id:"tech-rocketry",title:F("tech_rocketry"),desc:F("tech_rocketry"),category:"arpa",era:"globalized",reqs:{high_tech:6},grant:["high_tech",7],cost:{Knowledge:()=>112500,Oil:()=>t.city.ptrait.includes("dense")?8e3:6800},effect:F("tech_rocketry_effect"),action(){return!!Os($(this)[0])&&(t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,Di(F("civics_rival_unlocked",[ee(3)]),"info",!1,["progress","combat"])),!0)},post(){Oe("Physics")}},robotics:{id:"tech-robotics",title:F("tech_robotics"),desc:F("tech_robotics"),category:"progress",era:"globalized",reqs:{high_tech:7},grant:["high_tech",8],cost:{Knowledge:()=>125e3},effect:F("tech_robotics_effect"),action(){return!!Os($(this)[0])}},lasers:{id:"tech-lasers",title:F("tech_lasers"),desc:F("tech_lasers_desc"),category:"progress",era:"deep_space",reqs:{high_tech:8,space:3,supercollider:1,elerium:1},grant:["high_tech",9],cost:{Knowledge:()=>28e4,Elerium:()=>100},effect:F("tech_lasers_effect"),action(){return!!Os($(this)[0])&&(t.race.cataclysm&&Xc("iron_will",!1,3),!0)}},artifical_intelligence:{id:"tech-artifical_intelligence",title:F("tech_artificial_intelligence"),desc:F("tech_artificial_intelligence"),category:"progress",era:"deep_space",reqs:{high_tech:9},grant:["high_tech",10],cost:{Knowledge:()=>325e3},effect:F("tech_artificial_intelligence_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_artificial_intelligence_flair")},quantum_computing:{id:"tech-quantum_computing",title:F("tech_quantum_computing"),desc:F("tech_quantum_computing"),category:"progress",era:"deep_space",reqs:{high_tech:10,nano:1},grant:["high_tech",11],cost:{Knowledge:()=>435e3,Elerium:()=>250,Nano_Tube:()=>1e5},effect:F("tech_quantum_computing_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_quantum_computing_flair")},virtual_reality:{id:"tech-virtual_reality",title:F("tech_virtual_reality"),desc:F("tech_virtual_reality"),category:"progress",era:"interstellar",reqs:{high_tech:11,alpha:2,infernite:1,stanene:1},grant:["high_tech",12],cost:{Knowledge:()=>6e5,Stanene:()=>1250,Soul_Gem:()=>1},effect:F("tech_virtual_reality_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_virtual_reality_flair")},plasma:{id:"tech-plasma",title:F("tech_plasma"),desc:F("tech_plasma"),category:"progress",era:"interstellar",path:["standard","truepath"],reqs:{high_tech:12},grant:["high_tech",13],cost:{Knowledge:()=>755e3,Infernite:()=>t.race.truepath?0:1e3,Stanene:()=>t.race.truepath?1e6:25e4},effect:F("tech_plasma_effect"),action(){return!!Os($(this)[0])}},shields:{id:"tech-shields",title:F("tech_shields"),desc:F("tech_shields"),category:"stellar_engine",era:"interstellar",reqs:{high_tech:13},grant:["high_tech",14],cost:{Knowledge:()=>85e4},effect:F("tech_shields_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.neutron=!0,t.settings.space.blackhole=!0,!0)}},ai_core:{id:"tech-ai_core",title:F("tech_ai_core"),desc:F("tech_ai_core"),category:"ai_core",era:"interstellar",reqs:{high_tech:14,science:15,blackhole:3},grant:["high_tech",15],cost:{Knowledge:()=>15e5},effect:F("tech_ai_core_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.citadel={count:0,on:0},!0)}},metaphysics:{id:"tech-metaphysics",title:F("tech_metaphysics"),desc:F("tech_metaphysics"),category:"progress",era:"intergalactic",reqs:{high_tech:15,xeno:5},grant:["high_tech",16],cost:{Knowledge:()=>5e6,Vitreloy:()=>1e4,Soul_Gem:()=>10},effect:()=>F("tech_metaphysics_effect"),action(){return!!Os($(this)[0])}},orichalcum_analysis:{id:"tech-orichalcum_analysis",title:F("tech_orichalcum_analysis"),desc:F("tech_orichalcum_analysis"),category:"progress",era:"intergalactic",reqs:{high_tech:16,chthonian:3},grant:["high_tech",17],cost:{Knowledge:()=>122e5,Orichalcum:()=>1e5},effect:()=>F("tech_orichalcum_analysis_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_orichalcum_analysis_result"),"info",!1,["progress"]),!0)}},cybernetics:{id:"tech-cybernetics",title:F("tech_cybernetics"),desc:F("tech_cybernetics"),category:"progress",era:"dimensional",reqs:{high_tech:17,hell_ruins:4},grant:["high_tech",18],cost:{Knowledge:()=>25e6,Adamantite:()=>125e5,Stanene:()=>5e7,Vitreloy:()=>1e7},effect:()=>F("tech_cybernetics_effect"),action(){return!!Os($(this)[0])}},blood_pact:{id:"tech-blood_pact",title:F("tech_blood_pact"),desc:F("tech_blood_pact"),category:"hell_dimension",era:"dimensional",reqs:{high_tech:18,b_stone:1},grant:["b_stone",2],cost:{Knowledge:()=>52e6,Blood_Stone:()=>1},effect:()=>F("tech_blood_pact_effect"),action(){return!!Os($(this)[0])&&(t.settings.arpa.blood=!0,Oe("Crispr"),!0)},post(){Oe("Blood")}},purify:{id:"tech-purify",title:F("tech_purify"),desc:F("tech_purify"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:3,b_stone:2},grant:["b_stone",3],cost:{Knowledge:()=>525e5,Blood_Stone:()=>1},effect:()=>F("tech_purify_effect"),action(){return!!Os($(this)[0])}},waygate:{id:"tech-waygate",title:F("tech_waygate"),desc:F("tech_waygate"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:10,b_stone:2},grant:["waygate",1],cost:{Knowledge:()=>55e6},effect:()=>F("tech_waygate_effect"),action(){return!!Os($(this)[0])&&(t.portal.waygate={count:0,progress:0,on:0},!0)}},demonic_infusion:{id:"tech-demonic_infusion",title:F("tech_demonic_infusion"),desc:F("tech_demonic_infusion"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:10,b_stone:2,waygate:3},grant:["waygate",4],not_trait:["witch_hunter"],cost:{Species:()=>fc(1e3),Knowledge:()=>55e6,Demonic_Essence:()=>1},effect:()=>`
    ${F("tech_demonic_infusion_effect")}
    ${F("tech_demonic_infusion_effect2",[mc("descend").artifact])}
    `,action(){return t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),Os($(this)[0])&&W(),!1}},gate_key:{id:"tech-gate_key",title:F("tech_gate_key"),desc:F("tech_gate_key"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:1},grant:["hell_gate",2],cost:{Knowledge:()=>3e7},effect:()=>F("tech_gate_key_effect"),action(){return!!Os($(this)[0])&&(t.portal.west_tower={count:0,on:0},t.portal.east_tower={count:0,on:0},!0)}},gate_turret:{id:"tech-gate_turret",title:F("tech_gate_turret"),desc:F("tech_gate_turret"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:2},grant:["hell_gate",3],cost:{Knowledge:()=>32e6},effect:()=>F("tech_gate_turret_effect"),action(){return!!Os($(this)[0])&&(t.portal.gate_turret={count:0,on:0},!0)}},infernite_mine:{id:"tech-infernite_mine",title:F("tech_infernite_mine"),desc:F("tech_infernite_mine"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:3},grant:["hell_gate",4],cost:{Knowledge:()=>325e5},effect:()=>F("tech_infernite_mine_effect"),action(){return!!Os($(this)[0])&&(t.portal.infernite_mine={count:0,on:0},!0)}},study_corrupt_gem:{id:"tech-study_corrupt_gem",title:F("tech_study_corrupt_gem"),desc:F("tech_study_corrupt_gem"),category:"hell_dimension",era:"intergalactic",reqs:{high_tech:16,corrupt:1},grant:["corrupt",2],trait:["witch_hunter"],cost:{Mana:()=>t.race.no_plasmid?1e4:5e4,Knowledge:()=>185e5,Corrupt_Gem:()=>1},effect:()=>F("tech_study_corrupt_gem_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_study_corrupt_gem_result"),"info",!1,["progress","hell"]),t.resource.Corrupt_Gem.display=!1,!0)}},soul_binding:{id:"tech-soul_binding",title:F("tech_soul_binding"),desc:F("tech_soul_binding"),category:"hell_dimension",era:"intergalactic",reqs:{corrupt:2,science:19},grant:["forbidden",1],trait:["witch_hunter"],cost:{Knowledge:()=>19e6},effect:()=>F("tech_soul_binding_effect"),action(){return!!Os($(this)[0])}},soul_capacitor:{id:"tech-soul_capacitor",title:F("tech_soul_capacitor"),desc:F("tech_soul_capacitor"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:1},grant:["forbidden",2],trait:["witch_hunter"],cost:{Knowledge:()=>195e5},effect:()=>F("tech_soul_capacitor_effect"),action(){return!!Os($(this)[0])&&(t.portal.soul_capacitor={count:0,on:0,energy:0,ecap:0},!0)}},soul_capacitor:{id:"tech-soul_capacitor",title:F("tech_soul_capacitor"),desc:F("tech_soul_capacitor"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:1},grant:["forbidden",2],trait:["witch_hunter"],cost:{Knowledge:()=>195e5},effect:()=>F("tech_soul_capacitor_effect"),action(){return!!Os($(this)[0])&&(t.portal.soul_capacitor={count:0,on:0,energy:0,ecap:0},!0)}},absorption_chamber:{id:"tech-absorption_chamber",title:F("tech_absorption_chamber"),desc:F("tech_absorption_chamber"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:2},grant:["forbidden",3],trait:["witch_hunter"],cost:{Knowledge:()=>2e7},effect:()=>F("tech_absorption_chamber_effect"),action(){return!!Os($(this)[0])&&(t.portal.absorption_chamber={count:0},!0)}},corrupt_gem_analysis:{id:"tech-corrupt_gem_analysis",title:F("tech_corrupt_gem_analysis"),desc:F("tech_corrupt_gem_analysis"),category:"hell_dimension",era:"dimensional",reqs:{high_tech:16,corrupt:1},grant:["corrupt",2],not_trait:["witch_hunter"],cost:{Species:()=>1,Knowledge:()=>22e6,Corrupt_Gem:()=>1},effect:()=>F("tech_corrupt_gem_analysis_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_corrupt_gem_analysis_result"),"info",!1,["progress","hell"]),t.resource.Corrupt_Gem.display=!1,!0)}},hell_search:{id:"tech-hell_search",title:F("tech_hell_search"),desc:F("tech_hell_search"),category:"hell_dimension",era:"dimensional",reqs:{corrupt:2},grant:["hell_ruins",1],cost:{Knowledge:()=>221e5,Structs:()=>({portal:{sensor_drone:{s:"prtl_badlands",count:25,on:25}}})},effect:()=>F("tech_hell_search_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_hell_search_result"),"info",!1,["progress","hell"]),t.settings.portal.ruins=!0,t.settings.portal.gate=!0,t.portal.guard_post={count:0,on:0,support:0,s_max:0},!0)}},codex_infernium:{id:"tech-codex_infernium",title:F("tech_codex_infernium"),desc:F("tech_codex_infernium"),category:"progress",era:"dimensional",reqs:{hell_ruins:3},grant:["hell_ruins",4],cost:{Knowledge:()=>235e5,Codex:()=>1},effect:()=>F("tech_codex_infernium_effect"),action(){return!!Os($(this)[0])&&(t.resource.Codex.display=!1,!0)}},lake_analysis:{id:"tech-lake_analysis",title:F("tech_lake_analysis"),desc:F("tech_lake_analysis"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:2},grant:["hell_lake",3],cost:{Knowledge:()=>34e6},effect:()=>F("tech_lake_analysis_effect"),action(){return!!Os($(this)[0])}},lake_threat:{id:"tech-lake_threat",title:F("tech_lake_threat"),desc:F("tech_lake_threat"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:3},grant:["hell_lake",4],cost:{Knowledge:()=>345e5},effect:()=>F("tech_lake_threat_effect"),action(){return!!Os($(this)[0])&&(t.portal.bireme={count:0,on:0,crew:0,mil:0},Di(F("tech_lake_threat_result"),"info",!1,["progress","hell"]),!0)}},lake_transport:{id:"tech-lake_transport",title:F("tech_lake_transport"),desc:F("tech_lake_transport"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:4},grant:["hell_lake",5],cost:{Knowledge:()=>35e6},effect:()=>F("tech_lake_transport_effect"),action(){return!!Os($(this)[0])&&(t.portal.transport={count:0,on:0,crew:0,mil:0,cargo:{used:0,max:0,Crystal:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0}},!0)}},cooling_tower:{id:"tech-cooling_tower",title:F("tech_cooling_tower"),desc:F("tech_cooling_tower"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:5},grant:["hell_lake",6],cost:{Knowledge:()=>375e5},effect:()=>F("tech_cooling_tower_effect"),action(){return!!Os($(this)[0])&&(t.portal.cooling_tower={count:0,on:0},!0)}},miasma:{id:"tech-miasma",title:F("tech_miasma"),desc:F("tech_miasma"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:2},grant:["hell_spire",3],cost:{Knowledge:()=>3825e4},effect:()=>F("tech_miasma_effect"),action(){return!!Os($(this)[0])&&(t.portal.port={count:0},!0)}},incorporeal:{id:"tech-incorporeal",title:F("tech_incorporeal"),desc:F("tech_incorporeal"),category:"special",era:"intergalactic",reqs:{science:19},grant:["ascension",1],not_trait:["orbit_decay","witch_hunter"],cost:{Knowledge:()=>175e5,Phage:()=>25},effect:()=>F("tech_incorporeal_effect"),action(){return!!Os($(this)[0])}},tech_ascension:{id:"tech-tech_ascension",title:F("tech_ascension"),desc:F("tech_ascension"),category:"special",era:"intergalactic",reqs:{ascension:1},grant:["ascension",2],not_trait:["orbit_decay","witch_hunter"],cost:{Knowledge:()=>185e5,Plasmid:()=>100},effect:()=>F("tech_ascension_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.sirius=!0,!0)}},terraforming:{id:"tech-terraforming",title:F("tech_terraforming"),desc:F("tech_terraforming"),category:"special",era:"intergalactic",reqs:{science:19},path:["standard"],grant:["terraforming",1],trait:["orbit_decay"],cost:{Knowledge:()=>18e6},effect:()=>F("tech_terraforming_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.terraformer={count:0},!0)}},cement_processing:{id:"tech-cement_processing",title:F("tech_cement_processing"),desc:F("tech_cement_processing"),category:"ai_core",era:"interstellar",reqs:{high_tech:15},not_trait:["flier"],grant:["ai_core",1],cost:{Knowledge:()=>175e4},effect:F("tech_cement_processing_effect"),action(){return!!Os($(this)[0])}},adamantite_processing_flier:{id:"tech-adamantite_processing_flier",title:F("tech_adamantite_processing"),desc:F("tech_adamantite_processing"),category:"ai_core",era:"interstellar",reqs:{high_tech:15},trait:["flier"],grant:["ai_core",2],cost:{Knowledge:()=>2e6},effect:F("tech_adamantite_processing_effect"),action(){return!!Os($(this)[0])}},adamantite_processing:{id:"tech-adamantite_processing",title:F("tech_adamantite_processing"),desc:F("tech_adamantite_processing"),category:"ai_core",era:"interstellar",reqs:{ai_core:1},not_trait:["flier"],grant:["ai_core",2],cost:{Knowledge:()=>2e6},effect:F("tech_adamantite_processing_effect"),action(){return!!Os($(this)[0])}},graphene_processing:{id:"tech-graphene_processing",title:F("tech_graphene_processing"),desc:F("tech_graphene_processing"),category:"ai_core",era:"intergalactic",reqs:{ai_core:2},grant:["ai_core",3],cost:{Knowledge:()=>25e5},effect:F("tech_graphene_processing_effect"),action(){return!!Os($(this)[0])}},fusion_power:{id:"tech-fusion_power",title:F("tech_fusion_power"),desc:F("tech_fusion_power"),category:"power_generation",era:"interstellar",reqs:{ram_scoop:1},grant:["fusion",1],cost:{Knowledge:()=>64e4},effect:F("tech_fusion_power_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.fusion={count:0,on:0},!0)}},infernium_power:{id:"tech-infernium_power",title:F("tech_infernium_power"),desc:F("tech_infernium_power"),category:"power_generation",era:"dimensional",reqs:{smelting:8,hell_ruins:4},grant:["inferno_power",1],cost:{Knowledge:()=>3e7},effect:F("tech_infernium_power_effect"),action(){return!!Os($(this)[0])&&(t.portal.inferno_power={count:0,on:0},!0)}},thermomechanics:{id:"tech-thermomechanics",title:F("tech_thermomechanics"),desc:F("tech_thermomechanics_desc"),category:"crafting",era:"industrialized",reqs:{high_tech:4},grant:["alloy",1],cost:{Knowledge:()=>6e4},effect:()=>F("tech_thermomechanics_effect"),action(){return!!Os($(this)[0])}},quantum_manufacturing:{id:"tech-quantum_manufacturing",title:F("tech_quantum_manufacturing"),desc:F("tech_quantum_manufacturing"),category:"crafting",era:"deep_space",reqs:{high_tech:11},grant:["q_factory",1],cost:{Knowledge:()=>465e3},effect:F("tech_quantum_manufacturing_effect"),action(){return!!Os($(this)[0])}},worker_drone:{id:"tech-worker_drone",title:F("tech_worker_drone"),desc:F("tech_worker_drone"),category:"mining",era:"deep_space",reqs:{nano:1},grant:["drone",1],cost:{Knowledge:()=>4e5},effect:()=>F("tech_worker_drone_effect",[Xt().gas_moon]),action(){return!!Os($(this)[0])&&(t.space.drone={count:0},!0)}},uranium:{id:"tech-uranium",title:F("tech_uranium"),desc:F("tech_uranium"),category:"power_generation",era:"globalized",reqs:{high_tech:4},grant:["uranium",1],cost:{Knowledge:()=>72e3},effect:F("tech_uranium_effect"),action(){return!!Os($(this)[0])&&(t.resource.Uranium.display=!0,!0)},post(){zi()}},uranium_storage:{id:"tech-uranium_storage",title:F("tech_uranium_storage"),desc:F("tech_uranium_storage"),category:"storage",era:"globalized",reqs:{uranium:1},grant:["uranium",2],cost:{Knowledge:()=>75600,Alloy:()=>2500},effect:F("tech_uranium_storage_effect"),action(){return!!Os($(this)[0])}},uranium_ash:{id:"tech-uranium_ash",title:F("tech_uranium_ash"),desc:F("tech_uranium_ash"),category:"power_generation",era:"globalized",reqs:{uranium:2},grant:["uranium",3],cost:{Knowledge:()=>122e3},effect:F("tech_uranium_ash_effect"),action(){return!!Os($(this)[0])}},breeder_reactor:{id:"tech-breeder_reactor",title:F("tech_breeder_reactor"),desc:F("tech_breeder_reactor"),category:"power_generation",era:"early_space",reqs:{high_tech:5,uranium:3,space:3},grant:["uranium",4],cost:{Knowledge:()=>16e4,Uranium:()=>250,Iridium:()=>1e3},effect:F("tech_breeder_reactor_effect"),action(){return!!Os($(this)[0])}},mine_conveyor:{id:"tech-mine_conveyor",title:F("tech_mine_conveyor"),desc:F("tech_mine_conveyor"),category:"mining",era:"discovery",reqs:{high_tech:2},grant:["mine_conveyor",1],cost:{Knowledge:()=>16200,Copper:()=>2250,Steel:()=>1750},effect:F("tech_mine_conveyor_effect"),action(){return!!Os($(this)[0])}},oil_well:{id:"tech-oil_well",title:F("tech_oil_well"),desc:F("tech_oil_well"),category:"power_generation",era:"industrialized",reqs:{high_tech:3},grant:["oil",1],cost:{Knowledge:()=>27e3},effect:F("tech_oil_well_effect"),action(){return!!Os($(this)[0])&&(t.city.oil_well={count:0},!0)}},oil_depot:{id:"tech-oil_depot",title:F("tech_oil_depot"),desc:F("tech_oil_depot"),category:"storage",era:"industrialized",reqs:{oil:1},grant:["oil",2],cost:{Knowledge:()=>32e3},effect:F("tech_oil_depot_effect"),action(){return!!Os($(this)[0])&&(t.city.oil_depot={count:0},!0)}},oil_power:{id:"tech-oil_power",title:()=>t.race.environmentalist?F("city_wind_power"):F("tech_oil_power"),desc:()=>t.race.environmentalist?F("city_wind_power"):F("tech_oil_power"),category:"power_generation",era:"industrialized",reqs:{oil:2},grant:["oil",3],cost:{Knowledge:()=>44e3},effect:()=>t.race.environmentalist?F("tech_wind_power_effect"):F("tech_oil_power_effect"),action(){return!!Os($(this)[0])&&(t.city.oil_power={count:0,on:0},!0)}},titanium_drills:{id:"tech-titanium_drills",title:F("tech_titanium_drills"),desc:F("tech_titanium_drills"),category:"power_generation",era:"industrialized",reqs:{oil:3},grant:["oil",4],cost:{Knowledge:()=>54e3,Titanium:()=>3500},effect:F("tech_titanium_drills_effect"),action(){return!!Os($(this)[0])}},alloy_drills:{id:"tech-alloy_drills",title:F("tech_alloy_drills"),desc:F("tech_alloy_drills"),category:"power_generation",era:"globalized",reqs:{oil:4},grant:["oil",5],cost:{Knowledge:()=>77e3,Alloy:()=>1e3},effect:F("tech_alloy_drills_effect"),action(){return!!Os($(this)[0])}},fracking:{id:"tech-fracking",title:F("tech_fracking"),desc:F("tech_fracking"),category:"power_generation",era:"globalized",reqs:{oil:5,high_tech:6},grant:["oil",6],cost:{Knowledge:()=>132e3},effect:F("tech_fracking_effect"),action(){return!!Os($(this)[0])}},mythril_drills:{id:"tech-mythril_drills",title:F("tech_mythril_drills"),desc:F("tech_mythril_drills"),category:"power_generation",era:"early_space",reqs:{oil:6,space:3},grant:["oil",7],cost:{Knowledge:()=>165e3,Mythril:()=>100},effect:F("tech_mythril_drills_effect"),action(){return!!Os($(this)[0])}},mass_driver:{id:"tech-mass_driver",title:F("tech_mass_driver"),desc:F("tech_mass_driver"),category:"power_generation",era:"early_space",reqs:{oil:6,space:3},grant:["mass",1],cost:{Knowledge:()=>16e4},effect:F("tech_mass_driver_effect"),action(){return!!Os($(this)[0])&&(t.city.mass_driver={count:0,on:0},!0)}},orichalcum_driver:{id:"tech-orichalcum_driver",title:F("tech_orichalcum_driver"),desc:F("tech_orichalcum_driver"),category:"science",era:"intergalactic",reqs:{mass:1,science:19},grant:["mass",2],not_trait:["orbit_decayed"],cost:{Knowledge:()=>14e6,Orichalcum:()=>4e5},effect:()=>F("tech_orichalcum_driver_effect"),action(){return!!Os($(this)[0])&&(t.space.terraformer={count:0},!0)}},polymer:{id:"tech-polymer",title:F("tech_polymer"),desc:F("tech_polymer"),category:"crafting",era:"globalized",reqs:{genetics:1},grant:["polymer",1],cost:{Knowledge:()=>8e4,Oil:()=>5e3,Alloy:()=>450},effect:F("tech_polymer_effect"),action(){return!!Os($(this)[0])&&(t.resource.Polymer.display=!0,Di(F("tech_polymer_avail"),"info",!1,["progress"]),!0)},post(){Ws(),zi()}},fluidized_bed_reactor:{id:"tech-fluidized_bed_reactor",title:F("tech_fluidized_bed_reactor"),desc:F("tech_fluidized_bed_reactor"),category:"crafting",era:"globalized",reqs:{polymer:1,high_tech:6},grant:["polymer",2],cost:{Knowledge:()=>99e3},effect:F("tech_fluidized_bed_reactor_effect"),action(){return!!Os($(this)[0])}},synthetic_fur:{id:"tech-synthetic_fur",title:()=>t.race.evil?F("tech_faux_leather"):F("tech_synthetic_fur"),desc:()=>t.race.evil?F("tech_faux_leather"):F("tech_synthetic_fur"),category:"crafting",era:"globalized",reqs:{polymer:1},grant:["synthetic_fur",1],cost:{Knowledge:()=>1e5,Polymer:()=>2500},effect:()=>t.race.evil?F("tech_faux_leather_effect"):F("tech_synthetic_fur_effect"),action(){return!!Os($(this)[0])},post(){Ws()}},nanoweave:{id:"tech-nanoweave",title:F("tech_nanoweave"),desc:F("tech_nanoweave"),category:"crafting",era:"intergalactic",reqs:{science:18},grant:["nanoweave",1],cost:{Knowledge:()=>85e5,Nano_Tube:()=>5e6,Vitreloy:()=>25e4},effect:F("tech_nanoweave_effect"),action(){return!!Os($(this)[0])&&(t.resource.Nanoweave.display=!0,Di(F("tech_nanoweave_avail"),"info",!1,["progress"]),ha(),!0)},post(){zi()}},stanene:{id:"tech-stanene",title:F("tech_stanene"),desc:F("tech_stanene"),category:"crafting",era:"interstellar",reqs:{infernite:1},grant:["stanene",1],cost:{Knowledge:()=>59e4,Aluminium:()=>5e5,Infernite:()=>1e3},effect:F("tech_stanene_effect"),action(){return!!Os($(this)[0])&&(t.resource.Stanene.display=!0,Di(F("tech_stanene_avail"),"info",!1,["progress"]),!0)},post(){Ws(),zi()}},nano_tubes:{id:"tech-nano_tubes",title:F("tech_nano_tubes"),desc:F("tech_nano_tubes"),category:"crafting",era:"deep_space",reqs:{high_tech:10},grant:["nano",1],cost:{Knowledge:()=>375e3,Coal:()=>1e5,Neutronium:()=>1e3},effect:F("tech_nano_tubes_effect"),action(){return!!Os($(this)[0])&&(t.resource.Nano_Tube.display=!0,Di(F("tech_nano_tubes_msg"),"info",!1,["progress"]),!0)},post(){Ws(),zi()}},scarletite:{id:"tech-scarletite",title:F("tech_scarletite"),desc:F("tech_scarletite"),category:"crafting",era:"dimensional",reqs:{hell_ruins:4},grant:["scarletite",1],cost:{Knowledge:()=>2675e4,Iron:()=>1e8,Adamantite:()=>15e6,Orichalcum:()=>8e6},effect:F("tech_scarletite_effect"),action(){if(Os($(this)[0])){if(t.resource.Scarletite.display=!0,t.portal.hell_forge={count:0,on:0},Di(F("tech_scarletite_avail"),"info",!1,["progress"]),ha(),"micro"===t.race.universe||t.pillars[t.race.species]){let e=ro();e>t.pillars[t.race.species]&&(t.pillars[t.race.species]=e),t.tech.pillars=2}else t.tech.fusable=1;return!0}return!1},post(){zi()}},pillars:{id:"tech-pillars",title:F("tech_pillars"),desc:F("tech_pillars"),category:"hell_dimension",era:"dimensional",reqs:{scarletite:1,fusable:1},grant:["pillars",1],cost:{Knowledge:()=>3e7},effect:F("tech_pillars_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_pillars_msg",[di[t.race.species].entity]),"info",!1,["progress","hell"]),!0)}},reclaimer:{id:"tech-reclaimer",title:F("tech_reclaimer"),desc:F("tech_reclaimer_desc"),category:"reclaimer",era:"civilized",reqs:{primitive:3},grant:["reclaimer",1],trait:["evil"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>45,Lumber:()=>20,Stone:()=>20},effect:F("tech_reclaimer_effect"),action(){return!!Os($(this)[0])&&(t.civic.lumberjack.name=F("job_reclaimer"),t.civic.lumberjack.display=!0,t.city.graveyard={count:0},!0)}},shovel:{id:"tech-shovel",title:F("tech_shovel"),desc:F("tech_shovel"),category:"reclaimer",era:"civilized",reqs:{reclaimer:1,mining:2},grant:["reclaimer",2],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>540,Copper:()=>25},effect:F("tech_shovel_effect"),action(){return!!Os($(this)[0])}},iron_shovel:{id:"tech-iron_shovel",title:F("tech_iron_shovel"),desc:F("tech_iron_shovel"),category:"reclaimer",era:"civilized",reqs:{reclaimer:2,mining:3},grant:["reclaimer",3],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>2700,Iron:()=>250},effect:F("tech_iron_shovel_effect"),action(){return!!Os($(this)[0])}},steel_shovel:{id:"tech-steel_shovel",title:F("tech_steel_shovel"),desc:F("tech_steel_shovel"),category:"reclaimer",era:"discovery",reqs:{reclaimer:3,smelting:2},grant:["reclaimer",4],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>9e3,Steel:()=>250},effect:F("tech_steel_shovel_effect"),action(){return!!Os($(this)[0])}},titanium_shovel:{id:"tech-titanium_shovel",title:F("tech_titanium_shovel"),desc:F("tech_titanium_shovel"),category:"reclaimer",era:"industrialized",reqs:{reclaimer:4,high_tech:3},grant:["reclaimer",5],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>38e3,Titanium:()=>350},effect:F("tech_titanium_shovel_effect"),action(){return!!Os($(this)[0])}},alloy_shovel:{id:"tech-alloy_shovel",title:F("tech_alloy_shovel"),desc:F("tech_alloy_shovel"),category:"reclaimer",era:"globalized",reqs:{reclaimer:5,high_tech:4},grant:["reclaimer",6],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>67500,Alloy:()=>750},effect:F("tech_alloy_shovel_effect"),action(){return!!Os($(this)[0])}},mythril_shovel:{id:"tech-mythril_shovel",title:F("tech_mythril_shovel"),desc:F("tech_mythril_shovel"),category:"reclaimer",era:"early_space",reqs:{reclaimer:6,space:3},grant:["reclaimer",7],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>16e4,Mythril:()=>880},effect:F("tech_mythril_shovel_effect"),action(){return!!Os($(this)[0])}},adamantite_shovel:{id:"tech-adamantite_shovel",title:F("tech_adamantite_shovel"),desc:F("tech_adamantite_shovel"),category:"reclaimer",era:"interstellar",reqs:{reclaimer:7,alpha:2},grant:["reclaimer",8],trait:["evil"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>525e3,Adamantite:()=>1e4},effect:F("tech_adamantite_shovel_effect"),action(){return!!Os($(this)[0])}},stone_axe:{id:"tech-stone_axe",title:()=>F("tech_stone_axe"),desc:()=>F("tech_stone_axe_desc"),category:"lumber_gathering",reqs:{primitive:3},era:"civilized",grant:["axe",1],not_trait:["kindling_kindred","smoldering","evil","cataclysm"],cost:{Knowledge:()=>45,Lumber:()=>20,Stone:()=>20},effect:()=>t.race.living_tool?F("tech_basic_livingtools"):t.race.sappy?F("tech_amber_axe_effect"):F("tech_stone_axe_effect"),action(){return!!Os($(this)[0])&&(t.civic.lumberjack.display=!0,t.city.lumber_yard={count:0},!0)}},copper_axes:{id:"tech-copper_axes",title:F("tech_copper_axes"),desc:F("tech_copper_axes_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:1,mining:2},not_trait:["living_tool"],grant:["axe",2],cost:{Knowledge:()=>540,Copper:()=>25},effect:F("tech_copper_axes_effect"),action(){return!!Os($(this)[0])}},iron_saw:{id:"tech-iron_saw",title:F("tech_iron_saw"),desc:F("tech_iron_saw_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:1,mining:3},grant:["saw",1],not_trait:["lone_survivor"],cost:{Knowledge:()=>3375,Iron:()=>400},effect:F("tech_iron_saw_effect"),action(){return!!Os($(this)[0])&&(t.city.sawmill={count:0,on:0},!0)}},steel_saw:{id:"tech-steel_saw",title:F("tech_steel_saw"),desc:F("tech_steel_saw_desc"),category:"lumber_gathering",era:"discovery",reqs:{smelting:2,saw:1},grant:["saw",2],cost:{Knowledge:()=>10800,Steel:()=>400},effect:F("tech_steel_saw_effect"),action(){return!!Os($(this)[0])}},iron_axes:{id:"tech-iron_axes",title:F("tech_iron_axes"),desc:F("tech_iron_axes_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:2,mining:3},not_trait:["living_tool"],grant:["axe",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1350:2700,Iron:()=>250},effect:F("tech_iron_axes_effect"),action(){return!!Os($(this)[0])}},steel_axes:{id:"tech-steel_axes",title:F("tech_steel_axes"),desc:F("tech_steel_axes_desc"),category:"lumber_gathering",era:"discovery",reqs:{axe:3,smelting:2},not_trait:["living_tool"],grant:["axe",4],cost:{Knowledge:()=>9e3,Steel:()=>250},effect:F("tech_steel_axes_effect"),action(){return!!Os($(this)[0])}},titanium_axes:{id:"tech-titanium_axes",title:F("tech_titanium_axes"),desc:F("tech_titanium_axes_desc"),category:"lumber_gathering",era:"industrialized",reqs:{axe:4,high_tech:3},not_trait:["living_tool"],grant:["axe",5],cost:{Knowledge:()=>38e3,Titanium:()=>350},effect:F("tech_titanium_axes_effect"),action(){return!!Os($(this)[0])}},chainsaws:{id:"tech-chainsaws",title:F("tech_chainsaws"),desc:F("tech_chainsaws_desc"),category:"lumber_gathering",era:"interstellar",reqs:{axe:5,alpha:2},not_trait:["living_tool"],grant:["axe",6],cost:{Knowledge:()=>56e4,Oil:()=>1e4,Adamantite:()=>2e3},effect:F("tech_chainsaws_effect"),action(){return!!Os($(this)[0])},flair:()=>`
    ${F("tech_chainsaws_flair1")}
    ${F("tech_chainsaws_flair2")}
    `},copper_sledgehammer:{id:"tech-copper_sledgehammer",title:F("tech_copper_sledgehammer"),desc:F("tech_copper_sledgehammer_desc"),category:"stone_gathering",era:"civilized",reqs:{mining:2},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",1],cost:{Knowledge:()=>540,Copper:()=>25},effect:F("tech_copper_sledgehammer_effect"),action(){return!!Os($(this)[0])}},iron_sledgehammer:{id:"tech-iron_sledgehammer",title:F("tech_iron_sledgehammer"),desc:F("tech_iron_sledgehammer_desc"),category:"stone_gathering",era:"civilized",reqs:{hammer:1,mining:3},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1350:2700,Iron:()=>250},effect:F("tech_iron_sledgehammer_effect"),action(){return!!Os($(this)[0])}},steel_sledgehammer:{id:"tech-steel_sledgehammer",title:F("tech_steel_sledgehammer"),desc:F("tech_steel_sledgehammer_desc"),category:"stone_gathering",era:"discovery",reqs:{hammer:2,smelting:2},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",3],cost:{Knowledge:()=>7200,Steel:()=>250},effect:F("tech_steel_sledgehammer_effect"),action(){return!!Os($(this)[0])}},titanium_sledgehammer:{id:"tech-titanium_sledgehammer",title:F("tech_titanium_sledgehammer"),desc:F("tech_titanium_sledgehammer_desc"),category:"stone_gathering",era:"industrialized",reqs:{hammer:3,high_tech:3},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",4],cost:{Knowledge:()=>4e4,Titanium:()=>400},effect:F("tech_titanium_sledgehammer_effect"),action(){return!!Os($(this)[0])}},copper_pickaxe:{id:"tech-copper_pickaxe",title:F("tech_copper_pickaxe"),desc:F("tech_copper_pickaxe_desc"),category:"mining",era:"civilized",reqs:{mining:2},not_trait:["cataclysm","living_tool"],grant:["pickaxe",1],cost:{Knowledge:()=>675,Copper:()=>25},effect:F("tech_copper_pickaxe_effect"),action(){return!!Os($(this)[0])}},iron_pickaxe:{id:"tech-iron_pickaxe",title:F("tech_iron_pickaxe"),desc:F("tech_iron_pickaxe_desc"),category:"mining",era:"civilized",reqs:{pickaxe:1,mining:3},not_trait:["cataclysm","living_tool"],grant:["pickaxe",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1600:3200,Iron:()=>250},effect:F("tech_iron_pickaxe_effect"),action(){return!!Os($(this)[0])}},steel_pickaxe:{id:"tech-steel_pickaxe",title:F("tech_steel_pickaxe"),desc:F("tech_steel_pickaxe_desc"),category:"mining",era:"discovery",reqs:{pickaxe:2,smelting:2},not_trait:["living_tool"],grant:["pickaxe",3],cost:{Knowledge:()=>9e3,Steel:()=>250},effect:F("tech_steel_pickaxe_effect"),action(){return!!Os($(this)[0])}},jackhammer:{id:"tech-jackhammer",title:F("tech_jackhammer"),desc:F("tech_jackhammer_desc"),category:"mining",era:"discovery",reqs:{pickaxe:3,high_tech:2},not_trait:["living_tool"],grant:["pickaxe",4],cost:{Knowledge:()=>22500,Copper:()=>5e3},effect:F("tech_jackhammer_effect"),action(){return!!Os($(this)[0])}},jackhammer_mk2:{id:"tech-jackhammer_mk2",title:F("tech_jackhammer_mk2"),desc:F("tech_jackhammer_mk2"),category:"mining",era:"globalized",reqs:{pickaxe:4,high_tech:4},not_trait:["living_tool"],grant:["pickaxe",5],cost:{Knowledge:()=>67500,Titanium:()=>2e3,Alloy:()=>500},effect:F("tech_jackhammer_mk2_effect"),action(){return!!Os($(this)[0])}},adamantite_hammer:{id:"tech-adamantite_hammer",title:F("tech_adamantite_hammer"),desc:F("tech_adamantite_hammer"),category:"mining",era:"interstellar",reqs:{pickaxe:5,alpha:2},not_trait:["living_tool"],grant:["pickaxe",6],cost:{Knowledge:()=>535e3,Adamantite:()=>12500},effect:F("tech_adamantite_hammer_effect"),action(){return!!Os($(this)[0])}},copper_hoe:{id:"tech-copper_hoe",title:F("tech_copper_hoe"),desc:F("tech_copper_hoe_desc"),category:"agriculture",era:"civilized",reqs:{mining:2,agriculture:1},not_trait:["cataclysm","living_tool"],grant:["hoe",1],cost:{Knowledge:()=>720,Copper:()=>50},effect:F("tech_copper_hoe_effect"),action(){return!!Os($(this)[0])}},iron_hoe:{id:"tech-iron_hoe",title:F("tech_iron_hoe"),desc:F("tech_iron_hoe_desc"),category:"agriculture",era:"civilized",reqs:{hoe:1,mining:3,agriculture:1},not_trait:["living_tool"],grant:["hoe",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1800:3600,Iron:()=>500},effect:F("tech_iron_hoe_effect"),action(){return!!Os($(this)[0])}},steel_hoe:{id:"tech-steel_hoe",title:F("tech_steel_hoe"),desc:F("tech_steel_hoe_desc"),category:"agriculture",era:"discovery",reqs:{hoe:2,smelting:2,agriculture:1},not_trait:["living_tool"],grant:["hoe",3],cost:{Knowledge:()=>12600,Steel:()=>500},effect:F("tech_steel_hoe_effect"),action(){return!!Os($(this)[0])}},titanium_hoe:{id:"tech-titanium_hoe",title:F("tech_titanium_hoe"),desc:F("tech_titanium_hoe_desc"),category:"agriculture",era:"industrialized",reqs:{hoe:3,high_tech:3,agriculture:1},not_trait:["living_tool"],grant:["hoe",4],cost:{Knowledge:()=>44e3,Titanium:()=>500},effect:F("tech_titanium_hoe_effect"),action(){return!!Os($(this)[0])}},adamantite_hoe:{id:"tech-adamantite_hoe",title:F("tech_adamantite_hoe"),desc:F("tech_adamantite_hoe_desc"),category:"agriculture",era:"interstellar",reqs:{hoe:4,alpha:2},not_trait:["living_tool"],grant:["hoe",5],cost:{Knowledge:()=>53e4,Adamantite:()=>1e3},effect:F("tech_adamantite_hoe_effect"),action(){return!!Os($(this)[0])}},cyber_limbs:{id:"tech-cyber_limbs",title:F("tech_cyber_limbs"),desc:F("tech_cyber_limbs"),category:"mining",era:"dimensional",reqs:{high_tech:18},grant:["cyber_worker",1],cost:{Knowledge:()=>27e6},effect:F("tech_cyber_limbs_effect"),action(){return!!Os($(this)[0])}},slave_pens:{id:"tech-slave_pens",title:F("tech_slave_pens"),desc:F("tech_slave_pens"),category:"slaves",era:"civilized",reqs:{military:1,mining:1},not_trait:["cataclysm","lone_survivor"],grant:["slaves",1],trait:["slaver"],cost:{Knowledge:()=>150},effect:F("tech_slave_pens_effect"),action(){return!!Os($(this)[0])&&(t.city.slave_pen={count:0,slaves:0},!0)}},slave_market:{id:"tech-slave_market",title:F("tech_slave_market"),desc:F("tech_slave_market"),category:"slaves",era:"discovery",reqs:{slaves:1,high_tech:1},grant:["slaves",2],trait:["slaver"],cost:{Knowledge:()=>8e3},effect:F("tech_slave_market_effect"),action(){return!!Os($(this)[0])}},ceremonial_dagger:{id:"tech-ceremonial_dagger",title:F("tech_ceremonial_dagger"),desc:F("tech_ceremonial_dagger"),category:"sacrifice",era:"civilized",reqs:{mining:1},grant:["sacrifice",1],trait:["cannibalize"],not_trait:["cataclysm","lone_survivor"],cost:{Knowledge:()=>60},effect:F("tech_ceremonial_dagger_effect"),action(){return!!Os($(this)[0])}},last_rites:{id:"tech-last_rites",title:F("tech_last_rites"),desc:F("tech_last_rites"),category:"sacrifice",era:"civilized",reqs:{sacrifice:1,theology:2},grant:["sacrifice",2],trait:["cannibalize"],cost:{Knowledge:()=>1e3},effect:F("tech_last_rites_effect"),action(){return!!Os($(this)[0])}},ancient_infusion:{id:"tech-ancient_infusion",title:F("tech_ancient_infusion"),desc:F("tech_ancient_infusion"),category:"sacrifice",era:"early_space",reqs:{sacrifice:2,theology:4},grant:["sacrifice",3],trait:["cannibalize"],cost:{Knowledge:()=>182e3},effect:F("tech_ancient_infusion_effect"),action(){return!!Os($(this)[0])}},garrison:{id:"tech-garrison",title:F("tech_garrison"),desc:F("tech_garrison_desc"),category:"military",era:"civilized",reqs:{science:1,housing:1},grant:["military",1],cost:{Knowledge:()=>70},effect:F("tech_garrison_effect"),action(){return!!Os($(this)[0])&&(t.city.garrison={count:0,on:0},!0)}},mercs:{id:"tech-mercs",title:F("tech_mercs"),desc:F("tech_mercs_desc"),category:"military",era:"civilized",reqs:{military:1},grant:["mercs",1],not_trait:["lone_survivor"],cost:{Money:()=>1e4,Knowledge:()=>4500},effect:F("tech_mercs_effect"),action(){return!!Os($(this)[0])&&(t.civic.garrison.mercs=!0,!0)}},signing_bonus:{id:"tech-signing_bonus",title:F("tech_signing_bonus"),desc:F("tech_signing_bonus_desc"),category:"military",era:"industrialized",reqs:{mercs:1,high_tech:3},grant:["mercs",2],cost:{Money:()=>5e4,Knowledge:()=>32e3},effect:F("tech_signing_bonus_effect"),action(){return!!Os($(this)[0])}},hospital:{id:"tech-hospital",title:F("tech_hospital"),desc:F("tech_hospital"),category:"military",era:"civilized",reqs:{military:1,alumina:1},grant:["medic",1],not_trait:["artifical"],cost:{Knowledge:()=>5e3},effect:F("tech_hospital_effect"),action(){return!!Os($(this)[0])&&(t.city.hospital={count:0},!0)}},bac_tanks:{id:"tech-bac_tanks",title:()=>t.race.artifical?F("tech_repair_subroutines"):F("tech_bac_tanks"),desc:()=>t.race.artifical?F("tech_repair_subroutines"):F("tech_bac_tanks_desc"),category:"military",era:"interstellar",reqs:{medic:1,infernite:1},grant:["medic",2],cost:{Knowledge:()=>6e5,Infernite:()=>250},effect:()=>t.race.artifical?F("tech_repair_subroutines_effect"):F("tech_bac_tanks_effect"),action(){return!!Os($(this)[0])}},boot_camp:{id:"tech-boot_camp",title:F("tech_boot_camp"),desc:F("tech_boot_camp_desc"),category:"military",era:"discovery",reqs:{high_tech:1},grant:["boot_camp",1],cost:{Knowledge:()=>8e3},effect:F("tech_boot_camp_effect"),action(){return!!Os($(this)[0])&&(t.city.boot_camp={count:0},!0)}},vr_training:{id:"tech-vr_training",title:F("tech_vr_training"),desc:F("tech_vr_training"),category:"military",era:"interstellar",path:["standard","truepath"],reqs:{boot_camp:1,high_tech:12},not_trait:["cataclysm","lone_survivor"],grant:["boot_camp",2],cost:{Knowledge:()=>625e3},effect:()=>F("tech_vr_training_effect"),action(){return!!Os($(this)[0])}},bows:{id:"tech-bows",title:F("tech_bows"),desc:F("tech_bows_desc"),category:"military",era:"civilized",reqs:{military:1},grant:["military",2],cost:{Knowledge:()=>225,Lumber:()=>250},effect:F("tech_bows_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},flintlock_rifle:{id:"tech-flintlock_rifle",title:()=>"magic"===t.race.universe?F("tech_magic_arrow"):F("tech_flintlock_rifle"),desc:()=>"magic"===t.race.universe?F("tech_magic_arrow"):F("tech_flintlock_rifle"),category:"military",era:"civilized",reqs:{military:2,explosives:1},grant:["military",3],cost:{Knowledge:()=>5400,Coal:()=>"magic"===t.race.universe?0:750,Mana:()=>"magic"===t.race.universe?100:0},effect:()=>"magic"===t.race.universe?F("tech_magic_arrow_effect"):F("tech_flintlock_rifle_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},machine_gun:{id:"tech-machine_gun",title:()=>"magic"===t.race.universe?F("tech_fire_mage"):F("tech_machine_gun"),desc:()=>"magic"===t.race.universe?F("tech_fire_mage"):F("tech_machine_gun"),category:"military",era:"industrialized",reqs:{military:3,oil:1},grant:["military",4],cost:{Mana:()=>"magic"===t.race.universe?300:0,Knowledge:()=>33750,Oil:()=>1500},effect:F("tech_machine_gun_effect"),effect:()=>"magic"===t.race.universe?F("tech_fire_mage_effect"):F("tech_machine_gun_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},bunk_beds:{id:"tech-bunk_beds",title:F("tech_bunk_beds"),desc:F("tech_bunk_beds"),category:"military",era:"globalized",reqs:{military:4,high_tech:4},grant:["military",5],cost:{Knowledge:()=>76500,Furs:()=>25e3,Alloy:()=>3e3},effect:F("tech_bunk_beds_effect"),action(){return!!Os($(this)[0])}},rail_guns:{id:"tech-rail_guns",title:()=>"magic"===t.race.universe?F("tech_lightning_caster"):F("tech_rail_guns"),desc:()=>"magic"===t.race.universe?F("tech_lightning_caster"):F("tech_rail_guns"),category:"military",era:"early_space",reqs:{military:5,mass:1},grant:["military",6],cost:{Mana:()=>"magic"===t.race.universe?450:0,Knowledge:()=>2e5,Iridium:()=>2500},effect:()=>"magic"===t.race.universe?F("tech_lightning_caster_effect"):F("tech_rail_guns_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},laser_rifles:{id:"tech-laser_rifles",title:()=>"magic"===t.race.universe?F("tech_mana_rifles"):F("tech_laser_rifles"),desc:()=>"magic"===t.race.universe?F("tech_mana_rifles"):F("tech_laser_rifles"),category:"military",era:"deep_space",reqs:{military:6,high_tech:9,elerium:1},grant:["military",7],cost:{Knowledge:()=>325e3,Elerium:()=>250},effect:()=>"magic"===t.race.universe?F("tech_mana_rifles_effect"):F("tech_laser_rifles_effect"),action(){return!!Os($(this)[0])&&("sharkin"===t.race.species&&Xc("laser_shark"),!0)},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},plasma_rifles:{id:"tech-plasma_rifles",title:()=>"magic"===t.race.universe?F("tech_focused_rifles"):F("tech_plasma_rifles"),desc:()=>"magic"===t.race.universe?F("tech_focused_rifles"):F("tech_plasma_rifles"),category:"military",era:"interstellar",reqs:{military:7,high_tech:13},grant:["military",8],path:["standard","truepath"],cost:{Knowledge:()=>78e4,Elerium:()=>t.race.truepath?1e3:500},effect:()=>"magic"===t.race.universe?F("tech_focused_rifles_effect"):F("tech_plasma_rifles_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},disruptor_rifles:{id:"tech-disruptor_rifles",title:()=>"magic"===t.race.universe?F("tech_magic_missile"):F("tech_disruptor_rifles"),desc:()=>"magic"===t.race.universe?F("tech_magic_missile"):F("tech_disruptor_rifles"),category:"military",era:"interstellar",reqs:{military:8,high_tech:14,science:15,infernite:1},grant:["military",9],cost:{Knowledge:()=>1e6,Infernite:()=>1e3},effect:()=>"magic"===t.race.universe?F("tech_magic_missile_effect"):F("tech_disruptor_rifles_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},gauss_rifles:{id:"tech-gauss_rifles",title:()=>"magic"===t.race.universe?F("tech_magicword_kill"):F("tech_gauss_rifles"),desc:()=>"magic"===t.race.universe?F("tech_magicword_kill"):F("tech_gauss_rifles"),category:"military",era:"intergalactic",reqs:{military:9,science:18},grant:["military",10],cost:{Knowledge:()=>95e5,Bolognium:()=>1e5},effect:()=>"magic"===t.race.universe?F("tech_magicword_kill_effect"):F("tech_gauss_rifles_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},cyborg_soldiers:{id:"tech-cyborg_soldiers",title:F("tech_cyborg_soldiers"),desc:F("tech_cyborg_soldiers"),category:"military",era:"dimensional",reqs:{military:10,high_tech:18},grant:["military",11],cost:{Knowledge:()=>26e6,Adamantite:()=>8e6,Bolognium:()=>4e6,Orichalcum:()=>6e6},effect:F("tech_cyborg_soldiers_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},space_marines:{id:"tech-space_marines",title:F("tech_space_marines"),desc:F("tech_space_marines_desc"),category:"military",era:"early_space",reqs:{space:3,mars:2},grant:["marines",1],cost:{Knowledge:()=>21e4},effect:()=>`
    ${F("tech_space_marines_effect",[Xt().red])}
    `,action(){return!!Os($(this)[0])&&(t.space.space_barracks={count:0,on:0},!0)},flair:F("tech_space_marines_flair")},hammocks:{id:"tech-hammocks",title:F("tech_hammocks"),desc:F("tech_hammocks"),category:"military",era:"intergalactic",reqs:{marines:1,nanoweave:1},grant:["marines",2],cost:{Knowledge:()=>89e5,Nanoweave:()=>3e4},effect:()=>F("tech_hammocks_effect"),action(){return!!Os($(this)[0])}},cruiser:{id:"tech-cruiser",title:F("tech_cruiser"),desc:F("tech_cruiser"),category:"military",era:"interstellar",reqs:{high_tech:14,proxima:2,aerogel:1},grant:["cruiser",1],cost:{Knowledge:()=>86e4},effect:F("tech_cruiser_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.cruiser={count:0,on:0},!0)}},armor:{id:"tech-armor",title:F("tech_armor"),desc:F("tech_armor_desc"),category:"military",era:"civilized",reqs:{military:1},not_trait:["apex_predator"],grant:["armor",1],cost:{Money:()=>250,Knowledge:()=>225,Furs:()=>250},effect:F("tech_armor_effect"),action(){return!!Os($(this)[0])}},plate_armor:{id:"tech-plate_armor",title:F("tech_plate_armor"),desc:F("tech_plate_armor_desc"),category:"military",era:"civilized",reqs:{armor:1,mining:3},grant:["armor",2],cost:{Knowledge:()=>3400,Iron:()=>600},effect:F("tech_plate_armor_effect"),action(){return!!Os($(this)[0])}},kevlar:{id:"tech-kevlar",title:F("tech_kevlar"),desc:F("tech_kevlar_desc"),category:"military",era:"globalized",reqs:{armor:2,polymer:1},grant:["armor",3],cost:{Knowledge:()=>86e3,Polymer:()=>750},effect:F("tech_kevlar_effect"),action(){return!!Os($(this)[0])}},nanoweave_vest:{id:"tech-nanoweave_vest",title:F("tech_nanoweave_vest"),desc:F("tech_nanoweave_vest"),category:"military",era:"intergalactic",reqs:{armor:3,nanoweave:1},grant:["armor",4],cost:{Knowledge:()=>925e4,Nanoweave:()=>75e3},effect:F("tech_nanoweave_vest_effect"),action(){return!!Os($(this)[0])}},laser_turret:{id:"tech-laser_turret",title:F("tech_laser_turret"),desc:F("tech_laser_turret"),category:"hell_dimension",era:"interstellar",reqs:{high_tech:9,portal:2},grant:["turret",1],cost:{Knowledge:()=>6e5,Elerium:()=>100},effect:()=>`
    ${F("tech_laser_turret_effect1")}
    ${F("tech_laser_turret_effect2")}
    `,action(){return!!Os($(this)[0])},post(){sc({el:"#fort"},"update"),Ks(!1,["portal-turret"])}},plasma_turret:{id:"tech-plasma_turret",title:F("tech_plasma_turret"),desc:F("tech_plasma_turret"),category:"hell_dimension",era:"interstellar",reqs:{high_tech:13,turret:1},grant:["turret",2],cost:{Knowledge:()=>76e4,Elerium:()=>350},effect:()=>`
    ${F("tech_plasma_turret_effect")}
    ${F("tech_laser_turret_effect2")}
    `,action(){return!!Os($(this)[0])},post(){sc({el:"#fort"},"update"),Ks(!1,["portal-turret"])}},black_powder:{id:"tech-black_powder",title:()=>"magic"===t.race.universe?F("tech_magic_powder"):F("tech_black_powder"),desc:()=>"magic"===t.race.universe?F("tech_magic_powder_desc"):F("tech_black_powder_desc"),category:"progress",era:"civilized",reqs:{mining:4},grant:["explosives",1],cost:{Knowledge:()=>4500,Mana:()=>"magic"===t.race.universe?100:0,Crystal:()=>"magic"===t.race.universe?250:0,Coal:()=>"magic"===t.race.universe?300:500},effect:()=>"magic"===t.race.universe?F("tech_magic_powder_effect"):F("tech_black_powder_effect"),action(){return!!Os($(this)[0])}},dynamite:{id:"tech-dynamite",title:F("tech_dynamite"),desc:F("tech_dynamite"),category:"mining",era:"civilized",reqs:{explosives:1},grant:["explosives",2],cost:{Knowledge:()=>4800,Coal:()=>750},effect:F("tech_dynamite_effect"),action(){return!!Os($(this)[0])}},anfo:{id:"tech-anfo",title:F("tech_anfo"),desc:F("tech_anfo"),category:"mining",era:"industrialized",reqs:{explosives:2,oil:1},grant:["explosives",3],cost:{Knowledge:()=>42e3,Oil:()=>2500},effect:F("tech_anfo_effect"),action(){return!!Os($(this)[0])}},mad:{id:"tech-mad",title:F("tech_mad"),desc:F("tech_mad_desc"),category:"special",era:"globalized",reqs:{uranium:1,explosives:3,high_tech:7},not_trait:["cataclysm","lone_survivor"],grant:["mad",1],condition:()=>!(t.race.sludge||t.race.truepath&&!t.tech.world_control),cost:{Knowledge:()=>12e4,Oil:()=>t.city.ptrait.includes("dense")?1e4:8500,Uranium:()=>1250},effect:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("tech_mad_effect_easter"):F("tech_mad_effect"),action(){return!!Os($(this)[0])&&(t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?Di(F("tech_mad_info_easter"),"info",!1,["progress"]):Di(F("tech_mad_info"),"info",!1,["progress"]),t.civic.mad.display=!0,!0)}},cement:{id:"tech-cement",title:F("tech_cement"),desc:F("tech_cement_desc"),category:"cement",era:"civilized",reqs:{mining:1,storage:1,science:1},not_trait:["flier"],grant:["cement",1],cost:{Knowledge:()=>500},effect:F("tech_cement_effect"),action(){return!!Os($(this)[0])&&(t.city.cement_plant={count:0,on:0},!0)}},rebar:{id:"tech-rebar",title:F("tech_rebar"),desc:F("tech_rebar"),category:"cement",era:"civilized",reqs:{mining:3,cement:1},not_trait:["flier"],grant:["cement",2],cost:{Knowledge:()=>3200,Iron:()=>750},effect:F("tech_rebar_effect"),action(){return!!Os($(this)[0])}},steel_rebar:{id:"tech-steel_rebar",title:F("tech_steel_rebar"),desc:F("tech_steel_rebar"),category:"cement",era:"civilized",reqs:{smelting:2,cement:2},not_trait:["flier"],grant:["cement",3],cost:{Knowledge:()=>6750,Steel:()=>750},effect:F("tech_steel_rebar_effect"),action(){return!!Os($(this)[0])}},portland_cement:{id:"tech-portland_cement",title:F("tech_portland_cement"),desc:F("tech_portland_cement"),category:"cement",era:"industrialized",reqs:{cement:3,high_tech:3},not_trait:["flier"],grant:["cement",4],cost:{Knowledge:()=>32e3},effect:F("tech_portland_cement_effect"),action(){return!!Os($(this)[0])}},screw_conveyor:{id:"tech-screw_conveyor",title:F("tech_screw_conveyor"),desc:F("tech_screw_conveyor"),category:"cement",era:"globalized",reqs:{cement:4,high_tech:4},not_trait:["flier"],grant:["cement",5],cost:{Knowledge:()=>72e3},effect:F("tech_screw_conveyor_effect"),action(){return!!Os($(this)[0])}},adamantite_screws:{id:"tech-adamantite_screws",title:F("tech_adamantite_screws"),desc:F("tech_adamantite_screws"),category:"cement",era:"interstellar",reqs:{cement:5,alpha:2},not_trait:["cataclysm","flier"],grant:["cement",6],cost:{Knowledge:()=>5e5,Adamantite:()=>1e4},effect:F("tech_adamantite_screws_effect",[3]),action(){return!!Os($(this)[0])}},hunter_process:{id:"tech-hunter_process",title:F("tech_hunter_process"),desc:F("tech_hunter_process"),category:"mining",era:"industrialized",reqs:{high_tech:3,smelting:2},grant:["titanium",1],cost:{Knowledge:()=>45e3,Titanium:()=>1e3},effect:F("tech_hunter_process_effect"),action(){return!!Os($(this)[0])&&(t.resource.Titanium.value=Qa.Titanium,!0)}},kroll_process:{id:"tech-kroll_process",title:F("tech_kroll_process"),desc:F("tech_kroll_process"),category:"mining",era:"globalized",reqs:{titanium:1,high_tech:4},grant:["titanium",2],cost:{Knowledge:()=>78e3,Titanium:()=>1e4},effect:F("tech_kroll_process_effect"),action(){return!!Os($(this)[0])}},cambridge_process:{id:"tech-cambridge_process",title:F("tech_cambridge_process"),desc:F("tech_cambridge_process"),category:"mining",era:"early_space",reqs:{titanium:2,supercollider:1},grant:["titanium",3],cost:{Knowledge:()=>135e3,Titanium:()=>17500},effect:F("tech_cambridge_process_effect"),action(){return!!Os($(this)[0])}},pynn_partical:{id:"tech-pynn_partical",title:F("tech_pynn_partical"),desc:F("tech_pynn_partical"),category:"progress",era:"early_space",path:["standard"],reqs:{supercollider:1},grant:["particles",1],cost:{Knowledge:()=>1e5},effect:F("tech_pynn_partical_effect"),action(){return!!Os($(this)[0])}},matter_compression:{id:"tech-matter_compression",title:F("tech_matter_compression"),desc:F("tech_matter_compression"),category:"storage",era:"early_space",path:["standard"],reqs:{particles:1},grant:["particles",2],cost:{Knowledge:()=>112500},effect:F("tech_matter_compression_effect"),action(){return!!Os($(this)[0])}},higgs_boson:{id:"tech-higgs_boson",title:F("tech_higgs_boson"),desc:F("tech_higgs_boson"),category:"science",era:"early_space",path:["standard"],reqs:{particles:2,supercollider:2},grant:["particles",3],cost:{Knowledge:()=>125e3},effect:F("tech_higgs_boson_effect"),action(){return!!Os($(this)[0])}},dimensional_compression:{id:"tech-dimensional_compression",title:F("tech_dimensional_compression"),desc:F("tech_dimensional_compression"),category:"storage",era:"interstellar",reqs:{particles:3,science:11,supercollider:3},grant:["particles",4],cost:{Knowledge:()=>425e3},effect:F("tech_dimensional_compression_effect"),action(){return!!Os($(this)[0])}},theology:{id:"tech-theology",title:F("tech_theology"),desc:F("tech_theology"),category:"religion",era:"civilized",reqs:{theology:1,housing:1,cement:1},grant:["theology",2],cost:{Knowledge:()=>900},effect:F("tech_theology_effect"),action(){return!!Os($(this)[0])&&(t.city.temple={count:0},t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0}),t.genes.ancients&&t.genes.ancients>=2&&(t.civic.priest.display=!0),!0)}},fanaticism:{id:"tech-fanaticism",title:F("tech_fanaticism"),desc:F("tech_fanaticism"),category:"religion",era:"civilized",wiki:!t.genes.transcendence,reqs:{theology:2},grant:["theology",3],not_gene:["transcendence"],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-anthropology"===e.id)),cost:{Knowledge:()=>2500},effect:`
    ${F("tech_fanaticism_effect")}
    ${F("tech_fanaticism_warning")}
    `,action(){return!!Os($(this)[0])&&(t.tech.fanaticism=1,t.race.gods===t.race.species&&Xc("second_evolution"),Ns(t.race.gods),!0)}},alt_fanaticism:{id:"tech-alt_fanaticism",title:F("tech_fanaticism"),desc:F("tech_fanaticism"),category:"religion",era:"civilized",wiki:!!t.genes.transcendence,reqs:{theology:2},grant:["fanaticism",1],gene:["transcendence"],cost:{Knowledge:()=>2500},effect:`
    ${F("tech_fanaticism_effect")}
    `,action(){return!!Os($(this)[0])&&(2===t.tech.theology&&(t.tech.theology=3),t.race.gods===t.race.species&&Xc("second_evolution"),Ns(t.race.gods),!0)}},ancient_theology:{id:"tech-ancient_theology",title:F("tech_ancient_theology"),desc:F("tech_ancient_theology"),category:"religion",era:"early_space",reqs:{theology:3,mars:2},grant:["theology",4],condition:()=>!!t.genes.ancients,cost:{Knowledge:()=>18e4},effect:()=>F("tech_ancient_theology_effect",["none"!==t.race.old_gods?di[t.race.old_gods.toLowerCase()].entity:di[t.race.species].entity,"none"!==t.race.gods?di[t.race.gods.toLowerCase()].entity:di[t.race.species].entity]),action(){return!!Os($(this)[0])&&(t.space.ziggurat={count:0},!0)}},study:{id:"tech-study",title:F("tech_study"),desc:F("tech_study_desc"),category:"religion",era:"early_space",reqs:{theology:4},grant:["theology",5],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-deify"===e.id)),cost:{Knowledge:()=>195e3},effect:()=>`
    ${F("tech_study_effect",["none"!==t.race.old_gods?di[t.race.old_gods.toLowerCase()].entity:di[t.race.species].entity])}
    ${F("tech_study_warning")}
    `,action(){return!!Os($(this)[0])&&(t.tech.ancient_study=1,!0)}},encoding:{id:"tech-encoding",title:F("tech_encoding"),desc:F("tech_encoding_desc"),category:"religion",era:"deep_space",reqs:{ancient_study:1,mars:5},grant:["ancient_study",2],cost:{Knowledge:()=>268e3},effect:()=>`
    ${F("tech_encoding_effect")}
    `,action(){return!!Os($(this)[0])}},deify:{id:"tech-deify",title:F("tech_deify"),desc:F("tech_deify_desc"),category:"religion",era:"early_space",reqs:{theology:4},grant:["theology",5],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-study"===e.id)),cost:{Knowledge:()=>195e3},effect:()=>`
    ${F("tech_deify_effect",["none"!==t.race.old_gods?di[t.race.old_gods.toLowerCase()].entity:di[t.race.species].entity])}
    ${F("tech_deify_warning")}
    `,action(){return!!Os($(this)[0])&&(t.tech.ancient_deify=1,Ns(t.race.old_gods),Oe("Genetics"),!0)}},infusion:{id:"tech-infusion",title:F("tech_infusion"),desc:F("tech_infusion_desc"),category:"religion",era:"deep_space",reqs:{ancient_deify:1,mars:5},grant:["ancient_deify",2],cost:{Knowledge:()=>268e3},effect:()=>`
    ${F("tech_infusion_effect")}
    `,action(){return!!Os($(this)[0])}},indoctrination:{id:"tech-indoctrination",title:F("tech_indoctrination"),desc:F("tech_indoctrination"),category:"religion",era:"civilized",reqs:{fanaticism:1},grant:["fanaticism",2],cost:{Knowledge:()=>5e3},effect:F("tech_indoctrination_effect"),action(){return!!Os($(this)[0])},post(){t.race.terrifying&&(t.tech.fanaticism=3,ms())}},missionary:{id:"tech-missionary",title:F("tech_missionary"),desc:F("tech_missionary"),category:"religion",era:"discovery",reqs:{fanaticism:2},not_trait:["terrifying"],grant:["fanaticism",3],cost:{Knowledge:()=>1e4},effect:F("tech_missionary_effect"),action(){return!!Os($(this)[0])}},zealotry:{id:"tech-zealotry",title:F("tech_zealotry"),desc:F("tech_zealotry"),category:"religion",era:"discovery",reqs:{fanaticism:3},grant:["fanaticism",4],cost:{Knowledge:()=>25e3},effect:F("tech_zealotry_effect"),action(){return!!Os($(this)[0])}},anthropology:{id:"tech-anthropology",title:F("tech_anthropology"),desc:F("tech_anthropology"),category:"religion",era:"civilized",wiki:!t.genes.transcendence,reqs:{theology:2},grant:["theology",3],not_gene:["transcendence"],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-fanaticism"===e.id)),cost:{Knowledge:()=>2500},effect:`
    ${F("tech_anthropology_effect")}
    ${F("tech_anthropology_warning")}
    `,action(){return!!Os($(this)[0])&&(t.tech.anthropology=1,!0)}},alt_anthropology:{id:"tech-alt_anthropology",title:F("tech_anthropology"),desc:F("tech_anthropology"),category:"religion",era:"civilized",wiki:!!t.genes.transcendence,reqs:{theology:2},grant:["anthropology",1],gene:["transcendence"],cost:{Knowledge:()=>2500},effect:`
    ${F("tech_anthropology_effect")}
    `,action(){return!!Os($(this)[0])&&(2===t.tech.theology&&(t.tech.theology=3),!0)}},mythology:{id:"tech-mythology",title:F("tech_mythology"),desc:F("tech_mythology"),category:"religion",era:"civilized",reqs:{anthropology:1},grant:["anthropology",2],cost:{Knowledge:()=>5e3},effect:F("tech_mythology_effect"),action(){return!!Os($(this)[0])}},archaeology:{id:"tech-archaeology",title:F("tech_archaeology"),desc:F("tech_archaeology"),category:"science",era:"discovery",reqs:{anthropology:2},grant:["anthropology",3],cost:{Knowledge:()=>1e4},effect:F("tech_archaeology_effect"),action(){return!!Os($(this)[0])}},merchandising:{id:"tech-merchandising",title:F("tech_merchandising"),desc:F("tech_merchandising"),category:"banking",era:"discovery",reqs:{anthropology:3},grant:["anthropology",4],cost:{Knowledge:()=>25e3},effect:()=>t.race.truepath?F("tech_merchandising_effect_tp"):F("tech_merchandising_effect"),action(){return!!Os($(this)[0])}},astrophysics:{id:"tech-astrophysics",title:F("tech_astrophysics"),desc:F("tech_astrophysics_desc"),category:"storage",era:"early_space",reqs:{space:2},grant:["space_explore",1],cost:{Knowledge:()=>125e3},effect:F("tech_astrophysics_effect"),action(){return!!Os($(this)[0])&&(t.space.propellant_depot={count:0},!0)}},rover:{id:"tech-rover",title:F("tech_rover"),desc:F("tech_rover"),category:"space_exploration",era:"early_space",reqs:{space_explore:1},grant:["space_explore",2],cost:{Knowledge:()=>135e3,Alloy:()=>22e3,Polymer:()=>18e3,Uranium:()=>750},effect:F("tech_rover_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.moon=!0,t.space.moon_base={count:0,on:0,support:0,s_max:0},!0)}},probes:{id:"tech-probes",title:F("tech_probes"),desc:F("tech_probes"),category:"space_exploration",era:"early_space",reqs:{space_explore:2},grant:["space_explore",3],cost:{Knowledge:()=>168e3,Steel:()=>1e5,Iridium:()=>5e3,Uranium:()=>2250,Helium_3:()=>3500},effect:F("tech_probes_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.red=!0,t.settings.space.hell=!0,t.space.spaceport={count:0,on:0,support:0,s_max:0},!0)}},starcharts:{id:"tech-starcharts",title:F("tech_starcharts"),desc:F("tech_starcharts"),category:"space_exploration",era:"early_space",reqs:{space_explore:3,science:9},grant:["space_explore",4],cost:{Knowledge:()=>185e3},effect:F("tech_starcharts_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.gas=!0,t.settings.space.sun=!0,t.race.truepath&&(t.settings.showOuter=!0),t.space.swarm_control={count:0,support:0,s_max:0},!0)}},colonization:{id:"tech-colonization",title:F("tech_colonization"),desc:()=>F("tech_colonization_desc",[Xt().red]),category:"agriculture",era:"early_space",reqs:{space:4,mars:1},grant:["mars",2],cost:{Knowledge:()=>172e3},effect:()=>F(t.race.artifical?"tech_colonization_artifical_effect":"tech_colonization_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.biodome={count:0,on:0},!0)}},red_tower:{id:"tech-red_tower",title:()=>F("tech_red_tower",[Xt().red]),desc:()=>F("tech_red_tower",[Xt().red]),category:"space_exploration",era:"early_space",reqs:{mars:2},grant:["mars",3],cost:{Knowledge:()=>195e3},effect:()=>F("tech_red_tower_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.red_tower={count:0,on:0},!0)}},space_manufacturing:{id:"tech-space_manufacturing",title:F("tech_space_manufacturing"),desc:F("tech_space_manufacturing_desc"),category:"crafting",era:"early_space",reqs:{mars:3},grant:["mars",4],cost:{Knowledge:()=>22e4},effect:()=>F("tech_space_manufacturing_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.red_factory={count:0,on:0},!0)}},exotic_lab:{id:"tech-exotic_lab",title:F("tech_exotic_lab"),desc:F("tech_exotic_lab_desc"),category:"science",era:"deep_space",reqs:{mars:4,asteroid:5},grant:["mars",5],cost:{Knowledge:()=>25e4},effect:F("tech_exotic_lab_effect"),action(){return!!Os($(this)[0])&&(t.space.exotic_lab={count:0,on:0},!0)}},hydroponics:{id:"tech-hydroponics",title:F("tech_hydroponics"),desc:()=>F("tech_hydroponics"),category:"agriculture",era:"intergalactic",reqs:{mars:5,gateway:3},grant:["mars",6],cost:{Knowledge:()=>3e6,Bolognium:()=>5e5},effect:()=>F("tech_hydroponics_effect"),action(){return!!Os($(this)[0])}},dyson_sphere:{id:"tech-dyson_sphere",title:F("tech_dyson_sphere"),desc:F("tech_dyson_sphere"),category:"power_generation",era:"early_space",reqs:{solar:1},grant:["solar",2],cost:{Knowledge:()=>195e3},effect:F("tech_dyson_sphere_effect"),action(){return!!Os($(this)[0])}},dyson_swarm:{id:"tech-dyson_swarm",title:F("tech_dyson_swarm"),desc:F("tech_dyson_swarm"),category:"power_generation",era:"early_space",reqs:{solar:2},grant:["solar",3],cost:{Knowledge:()=>21e4},effect:F("tech_dyson_swarm_effect"),action(){return!!Os($(this)[0])&&(t.space.swarm_satellite={count:0},!0)}},swarm_plant:{id:"tech-swarm_plant",title:F("tech_swarm_plant"),desc:F("tech_swarm_plant"),category:"power_generation",era:"deep_space",reqs:{solar:3,hell:1,gas_moon:1},grant:["solar",4],cost:{Knowledge:()=>25e4},effect:()=>F("tech_swarm_plant_effect",[di[t.race.species].home,Xt().hell]),action(){return!!Os($(this)[0])&&(t.space.swarm_plant={count:0},!0)}},space_sourced:{id:"tech-space_sourced",title:F("tech_space_sourced"),desc:F("tech_space_sourced_desc"),category:"power_generation",era:"deep_space",reqs:{solar:4,asteroid:3},grant:["solar",5],cost:{Knowledge:()=>3e5},effect:F("tech_space_sourced_effect"),action(){return!!Os($(this)[0])}},swarm_plant_ai:{id:"tech-swarm_plant_ai",title:F("tech_swarm_plant_ai"),desc:F("tech_swarm_plant_ai"),category:"power_generation",era:"deep_space",reqs:{solar:4,high_tech:10},grant:["swarm",1],cost:{Knowledge:()=>335e3},effect:F("tech_swarm_plant_ai_effect"),action(){return!!Os($(this)[0])}},swarm_control_ai:{id:"tech-swarm_control_ai",title:F("tech_swarm_control_ai"),desc:F("tech_swarm_control_ai"),category:"power_generation",era:"deep_space",reqs:{swarm:1},grant:["swarm",2],cost:{Knowledge:()=>36e4},effect:F("tech_swarm_control_ai_effect"),action(){return!!Os($(this)[0])}},quantum_swarm:{id:"tech-quantum_swarm",title:F("tech_quantum_swarm"),desc:F("tech_quantum_swarm"),category:"power_generation",era:"deep_space",reqs:{swarm:2,high_tech:11},grant:["swarm",3],cost:{Knowledge:()=>45e4},effect:F("tech_quantum_swarm_effect"),action(){return!!Os($(this)[0])}},perovskite_cell:{id:"tech-perovskite_cell",title:F("tech_perovskite_cell"),desc:F("tech_perovskite_cell"),category:"power_generation",era:"interstellar",reqs:{swarm:3},grant:["swarm",4],path:["standard","truepath"],cost:{Knowledge:()=>525e3,Titanium:()=>1e5},effect:F("tech_perovskite_cell_effect"),action(){return!!Os($(this)[0])}},swarm_convection:{id:"tech-swarm_convection",title:F("tech_swarm_convection"),desc:F("tech_swarm_convection"),category:"power_generation",era:"interstellar",reqs:{swarm:4,stanene:1},grant:["swarm",5],path:["standard","truepath"],cost:{Knowledge:()=>725e3,Stanene:()=>1e5},effect:F("tech_swarm_convection_effect"),action(){return!!Os($(this)[0])}},orichalcum_panels:{id:"tech-orichalcum_panels",title:F("tech_orichalcum_panels"),desc:F("tech_orichalcum_panels"),category:"power_generation",era:"intergalactic",reqs:{high_tech:17,swarm:5},grant:["swarm",6],cost:{Knowledge:()=>14e6,Orichalcum:()=>125e3},effect:()=>F("tech_orichalcum_panels_effect"),action(){return!!Os($(this)[0])}},dyson_net:{id:"tech-dyson_net",title:F("tech_dyson_net"),desc:F("tech_dyson_net"),category:"power_generation",era:"interstellar",reqs:{solar:3,proxima:2,stanene:1},grant:["proxima",3],cost:{Knowledge:()=>8e5},effect:F("tech_dyson_net_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.dyson={count:0},!0)}},dyson_sphere2:{id:"tech-dyson_sphere2",title:F("tech_dyson_sphere"),desc:F("tech_dyson_sphere"),category:"power_generation",era:"intergalactic",reqs:{proxima:3,piracy:1},grant:["dyson",1],cost:{Knowledge:()=>5e6},effect:F("tech_dyson_sphere2_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.dyson_sphere={count:0},!0)}},orichalcum_sphere:{id:"tech-orichalcum_sphere",title:F("tech_orichalcum_sphere"),desc:F("tech_orichalcum_sphere"),category:"power_generation",era:"intergalactic",reqs:{dyson:1,science:19},condition:()=>!!(t.interstellar.dyson_sphere&&t.interstellar.dyson_sphere.count>=100),grant:["dyson",2],cost:{Knowledge:()=>175e5,Orichalcum:()=>25e4},effect:F("tech_orichalcum_sphere_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.orichalcum_sphere={count:0},!0)}},gps:{id:"tech-gps",title:F("tech_gps"),desc:F("tech_gps"),category:"market",era:"early_space",reqs:{space_explore:1},not_trait:["terrifying"],grant:["satellite",1],cost:{Knowledge:()=>15e4},effect:F("tech_gps_effect"),action(){return!!Os($(this)[0])&&(t.space.gps={count:0},!0)}},nav_beacon:{id:"tech-nav_beacon",title:F("tech_nav_beacon"),desc:F("tech_nav_beacon"),category:"space_exploration",era:"early_space",reqs:{luna:1},grant:["luna",2],cost:{Knowledge:()=>18e4},effect:F("tech_nav_beacon_effect"),action(){return!!Os($(this)[0])&&(t.space.nav_beacon={count:0,on:0},!0)}},subspace_signal:{id:"tech-subspace_signal",title:F("tech_subspace_signal"),desc:F("tech_subspace_signal"),category:"space_exploration",era:"interstellar",reqs:{science:13,luna:2,stanene:1},grant:["luna",3],cost:{Knowledge:()=>7e5,Stanene:()=>125e3},effect:()=>F("tech_subspace_signal_effect",[Xt().red]),action(){return!!Os($(this)[0])}},atmospheric_mining:{id:"tech-atmospheric_mining",title:F("tech_atmospheric_mining"),desc:F("tech_atmospheric_mining"),category:"power_generation",era:"early_space",reqs:{space:5},grant:["gas_giant",1],cost:{Knowledge:()=>19e4},effect:F("tech_atmospheric_mining_effect"),action(){return!!Os($(this)[0])&&(t.space.gas_mining={count:0,on:0},t.space.gas_storage={count:0},!0)}},helium_attractor:{id:"tech-helium_attractor",title:F("tech_helium_attractor"),desc:F("tech_helium_attractor"),category:"power_generation",era:"deep_space",reqs:{gas_giant:1,elerium:1},grant:["helium",1],cost:{Knowledge:()=>29e4,Elerium:()=>250},effect:()=>F("tech_helium_attractor_effect",[Xt().gas]),action(){return!!Os($(this)[0])}},ram_scoops:{id:"tech-ram_scoops",title:F("tech_ram_scoops"),desc:F("tech_ram_scoops"),category:"power_generation",era:"interstellar",reqs:{nebula:2},grant:["ram_scoop",1],cost:{Knowledge:()=>58e4},effect:()=>F("tech_ram_scoops_effect"),action(){return!!Os($(this)[0])}},elerium_prospecting:{id:"tech-elerium_prospecting",title:F("tech_elerium_prospecting"),desc:F("tech_elerium_prospecting"),category:"space_mining",era:"interstellar",reqs:{nebula:2},grant:["nebula",3],cost:{Knowledge:()=>61e4},effect:()=>F("tech_elerium_prospecting_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.elerium_prospector={count:0,on:0},!0)}},zero_g_mining:{id:"tech-zero_g_mining",title:F("tech_zero_g_mining"),desc:F("tech_zero_g_mining"),category:"space_mining",era:"early_space",reqs:{asteroid:1,high_tech:8},grant:["asteroid",2],cost:{Knowledge:()=>21e4},effect:F("tech_zero_g_mining_effect"),action(){return!!Os($(this)[0])&&(t.space.space_station={count:0,on:0,support:0,s_max:0},t.space.iridium_ship={count:0,on:0},t.space.iron_ship={count:0,on:0},!0)}},elerium_mining:{id:"tech-elerium_mining",title:F("tech_elerium_mining"),desc:F("tech_elerium_mining"),category:"space_mining",era:"deep_space",reqs:{asteroid:4},grant:["asteroid",5],cost:{Knowledge:()=>235e3,Elerium:()=>t.race.truepath?.5:1},effect:F("tech_elerium_mining_effect"),action(){return!!Os($(this)[0])&&(t.space.elerium_ship={count:0,on:0},t.race.cataclysm&&Xc("iron_will",!1,2),!0)}},laser_mining:{id:"tech-laser_mining",title:F("tech_laser_mining"),desc:F("tech_laser_mining"),category:"space_mining",era:"deep_space",reqs:{asteroid:5,elerium:1,high_tech:9},grant:["asteroid",6],cost:{Knowledge:()=>35e4},effect:F("tech_laser_mining_effect"),action(){return!!Os($(this)[0])}},plasma_mining:{id:"tech-plasma_mining",title:F("tech_plasma_mining"),desc:F("tech_plasma_mining"),category:"space_mining",era:"interstellar",reqs:{asteroid:6,high_tech:13},grant:["asteroid",7],path:["standard","truepath"],cost:{Knowledge:()=>825e3},effect:F("tech_plasma_mining_effect"),action(){return!!Os($(this)[0])}},elerium_tech:{id:"tech-elerium_tech",title:F("tech_elerium_tech"),desc:F("tech_elerium_tech"),category:"space_mining",era:"deep_space",reqs:{asteroid:5},grant:["elerium",1],cost:{Knowledge:()=>275e3,Elerium:()=>20},effect:F("tech_elerium_tech_effect"),action(){return!!Os($(this)[0])}},elerium_reactor:{id:"tech-elerium_reactor",title:F("tech_elerium_reactor"),desc:F("tech_elerium_reactor"),category:"power_generation",era:"deep_space",reqs:{dwarf:1,elerium:1},grant:["elerium",2],cost:{Knowledge:()=>325e3,Elerium:()=>180},effect:F("tech_elerium_reactor_effect"),action(){return!!Os($(this)[0])&&(t.space.e_reactor={count:0,on:0},!0)}},neutronium_housing:{id:"tech-neutronium_housing",title:F("tech_neutronium_housing"),desc:F("tech_neutronium_housing"),category:"housing",era:"deep_space",reqs:{gas_moon:1},grant:["space_housing",1],cost:{Knowledge:()=>275e3,Neutronium:()=>350},effect:()=>F("tech_neutronium_housing_effect",[Xt().red]),action(){return!!Os($(this)[0])}},unification:{id:"tech-unification",title:F("tech_unification"),desc:()=>F("tech_unification_desc",[di[t.race.species].home]),category:"special",era:"early_space",path:["standard"],reqs:{mars:2},grant:["unify",1],cost:{Knowledge:()=>2e5},effect:F("tech_unification_effect"),action(){return!!Os($(this)[0])}},unification2:{id:"tech-unification2",title:F("tech_unification"),desc:()=>F("tech_unification_desc",[di[t.race.species].home]),category:"special",era:"early_space",path:["standard"],reqs:{unify:1},grant:["unify",2],cost:{Bool(){let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].buy||t.civic.foreign[`gov${a}`].anx)&&e++;return 3===e}},effect(){let e=t.race.banana?`
    ${F("tech_unification_banana")}
    `:"";return`
    ${F("tech_unification_effect2")}
    ${F("tech_unification_warning")}
    ${e}`},action(){return!!Os($(this)[0])&&(t.race.banana&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),delete t.race.banana),t.civic.foreign.gov0.occ&&t.civic.foreign.gov1.occ&&t.civic.foreign.gov2.occ&&Xc("world_domination"),t.civic.foreign.gov0.anx&&t.civic.foreign.gov1.anx&&t.civic.foreign.gov2.anx&&Xc("illuminati"),t.civic.foreign.gov0.buy&&t.civic.foreign.gov1.buy&&t.civic.foreign.gov2.buy&&Xc("syndicate"),0===t.stats.attacks&&Xc("pacifist"),Hr(),!0)}},unite:{id:"tech-unite",title:F("tech_unite"),desc:()=>F("tech_unite_desc"),category:"special",era:"globalized",path:["truepath"],reqs:{unify:1},grant:["unify",2],cost:{Bool(){let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].buy||t.civic.foreign[`gov${a}`].anx)&&e++;return 3===e}},effect:()=>`
    ${F("tech_unite_effect")}
    ${F("tech_unification_effect2")}
    `,action(){return!!Os($(this)[0])&&(t.race.banana&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),delete t.race.banana),t.civic.foreign.gov0.occ&&t.civic.foreign.gov1.occ&&t.civic.foreign.gov2.occ&&Xc("world_domination"),t.civic.foreign.gov0.anx&&t.civic.foreign.gov1.anx&&t.civic.foreign.gov2.anx&&Xc("illuminati"),t.civic.foreign.gov0.buy&&t.civic.foreign.gov1.buy&&t.civic.foreign.gov2.buy&&Xc("syndicate"),0===t.stats.attacks&&Xc("pacifist"),Hr(),t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,Di(F("civics_rival_unlocked",[ee(3)]),"info",!1,["progress","combat"])),!0)}},genesis:{id:"tech-genesis",title:F("tech_genesis"),desc:F("tech_genesis"),category:"special",era:"deep_space",reqs:{high_tech:10,genesis:1},grant:["genesis",2],cost:{Knowledge:()=>35e4},effect:F("tech_genesis_effect"),action(){return!!Os($(this)[0])}},star_dock:{id:"tech-star_dock",title:F("tech_star_dock"),desc:F("tech_star_dock"),category:"special",era:"deep_space",reqs:{genesis:2,space:5,high_tech:10},grant:["genesis",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>38e4},effect:F("tech_star_dock_effect"),action(){return!!Os($(this)[0])&&(t.space.star_dock={count:0,ship:0,probe:0,template:t.race.species},!0)}},interstellar:{id:"tech-interstellar",title:F("tech_interstellar"),desc:F("tech_interstellar"),category:"space_exploration",era:"deep_space",reqs:{genesis:3},grant:["genesis",4],cost:{Knowledge:()=>4e5},effect:F("tech_interstellar_effect"),action(){return!!Os($(this)[0])&&(t.starDock.probes={count:0},!0)}},genesis_ship:{id:"tech-genesis_ship",title:()=>t.race.cataclysm?F("tech_generational_ship"):F("tech_genesis_ship"),desc:()=>t.race.cataclysm?F("tech_generational_ship"):F("tech_genesis_ship"),category:"special",era:"deep_space",reqs:{genesis:4},grant:["genesis",5],cost:{Knowledge:()=>425e3},effect:()=>t.race.cataclysm?F("tech_generational_effect"):F("tech_genesis_ship_effect"),action(){return!!Os($(this)[0])&&(t.starDock.seeder={count:0},t.race.cataclysm&&Xc("iron_will",!1,4),!0)}},geck:{id:"tech-geck",title:()=>F("tech_geck"),desc:()=>F("tech_geck_desc"),category:"special",era:"deep_space",reqs:{genesis:5},grant:["geck",1],condition:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5),cost:{Knowledge:()=>5e5},effect:()=>F("tech_geck_effect"),action(){return!!Os($(this)[0])&&(t.starDock.geck={count:0},!0)}},genetic_decay:{id:"tech-genetic_decay",title:F("tech_genetic_decay"),desc:F("tech_genetic_decay"),category:"genes",era:"early_space",reqs:{decay:1},grant:["decay",2],cost:{Knowledge:()=>2e5},effect:F("tech_genetic_decay_effect"),action(){return!!Os($(this)[0])}},stabilize_decay:{id:"tech-stabilize_decay",title:F("tech_stabilize_decay"),desc:F("tech_stabilize_decay"),category:"genes",era:"dimensional",reqs:{decay:2,high_tech:18},grant:["decay",3],cost:{Knowledge:()=>5e7,Blood_Stone:()=>1},effect:F("tech_stabilize_decay_effect"),action(){return!!Os($(this)[0])}},tachyon:{id:"tech-tachyon",title:F("tech_tachyon"),desc:F("tech_tachyon"),category:"progress",era:"interstellar",reqs:{wsc:1},grant:["ftl",1],cost:{Knowledge:()=>435e3},effect:F("tech_tachyon_effect"),action(){return!!Os($(this)[0])}},warp_drive:{id:"tech-warp_drive",title:F("tech_warp_drive"),desc:F("tech_warp_drive"),category:"space_exploration",era:"interstellar",reqs:{ftl:1},grant:["ftl",2],cost:{Knowledge:()=>45e4},effect:F("tech_warp_drive_effect"),action(){return!!Os($(this)[0])&&(t.settings.showDeep=!0,t.settings.space.alpha=!0,t.interstellar.starport={count:0,on:0,support:0,s_max:0},!0)}},habitat:{id:"tech-habitat",title:F("tech_habitat"),desc:F("tech_habitat_desc"),category:"housing",era:"interstellar",reqs:{alpha:2,droids:1},grant:["alpha",3],cost:{Knowledge:()=>48e4},effect:F("tech_habitat_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.habitat={count:0,on:0},!0)}},graphene:{id:"tech-graphene",title:F("tech_graphene"),desc:F("tech_graphene"),category:"crafting",era:"interstellar",reqs:{alpha:3,infernite:1},grant:["graphene",1],cost:{Knowledge:()=>54e4,Adamantite:()=>1e4},effect:F("tech_graphene_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},!0)}},aerogel:{id:"tech-aerogel",title:F("tech_aerogel"),desc:F("tech_aerogel"),category:"crafting",era:"interstellar",reqs:{graphene:1,science:13},grant:["aerogel",1],cost:{Knowledge:()=>75e4,Graphene:()=>5e4,Infernite:()=>500},effect:F("tech_aerogel_effect"),action(){return!!Os($(this)[0])&&(t.resource.Aerogel.display=!0,ha(),!0)},post(){zi()}},mega_manufacturing:{id:"tech-mega_manufacturing",title:F("tech_mega_manufacturing"),desc:F("tech_mega_manufacturing"),category:"crafting",era:"intergalactic",reqs:{high_tech:16,alpha:3},grant:["alpha",4],cost:{Knowledge:()=>565e4},effect:()=>F("tech_mega_manufacturing_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.int_factory={count:0,on:0},!0)}},luxury_condo:{id:"tech-luxury_condo",title:F("tech_luxury_condo"),desc:F("tech_luxury_condo"),category:"housing",era:"intergalactic",reqs:{high_tech:17,alpha:4},grant:["alpha",5],cost:{Knowledge:()=>15e6},effect:()=>F("tech_luxury_condo_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.luxury_condo={count:0,on:0},!0)}},stellar_engine:{id:"tech-stellar_engine",title:F("tech_stellar_engine"),desc:F("tech_stellar_engine"),category:"stellar_engine",era:"interstellar",reqs:{blackhole:2},grant:["blackhole",3],cost:{Knowledge:()=>1e6},effect:F("tech_stellar_engine_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.stellar_engine={count:0,mass:8,exotic:0},!0)}},mass_ejector:{id:"tech-mass_ejector",title:F("tech_mass_ejector"),desc:F("tech_mass_ejector"),category:"stellar_engine",era:"interstellar",reqs:{blackhole:4},grant:["blackhole",5],cost:{Knowledge:()=>11e5},effect:F("tech_mass_ejector_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.mass_ejector={count:0,on:0,total:0,mass:0,Food:0,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0},!0)}},asteroid_redirect:{id:"tech-asteroid_redirect",title:F("tech_asteroid_redirect"),desc:F("tech_asteroid_redirect"),category:"stellar_engine",era:"intergalactic",reqs:{blackhole:5,gateway:3},grant:["blackhole",6],cost:{Knowledge:()=>35e5},effect:F("tech_asteroid_redirect_effect"),action(){return!!Os($(this)[0])},post(){Oe("Physics")}},exotic_infusion:{id:"tech-exotic_infusion",title:F("tech_exotic_infusion"),desc:F("tech_exotic_infusion"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:1},grant:["whitehole",2],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect:()=>`
    ${F("tech_exotic_infusion_effect",[t.resource.Soul_Gem.name])}
    ${F("tech_exotic_infusion_effect2")}
    `,action(){return!!Cs($(this)[0])},flair:()=>F("tech_exotic_infusion_flair")},infusion_check:{id:"tech-infusion_check",title:F("tech_infusion_check"),desc:F("tech_infusion_check"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:2},grant:["whitehole",3],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect:()=>`
    ${F("tech_infusion_check_effect")}
    ${F("tech_exotic_infusion_effect2")}
    `,action(){return!!Cs($(this)[0])},flair:()=>F("tech_infusion_check_flair")},infusion_confirm:{id:"tech-infusion_confirm",title:F("tech_infusion_confirm"),desc:F("tech_infusion_confirm"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:3},grant:["whitehole",4],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect(){let e=mc("bigbang"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name"),r=`
    ${F("wiki_tech_infusion_confirm_gains",[e.plasmid,e.phage,e.dark,a])}
    `;return`
    ${F("tech_infusion_confirm_effect")}
    ${F("tech_exotic_infusion_effect2")}
    ${r}`},action(){if(Os($(this)[0])){if(t.tech.whitehole>=4)return;t.tech.whitehole=4;let a=$('
    ');return $("body").append(a),setTimeout((function(){a.addClass("burn")}),125),setTimeout((function(){a.addClass("b")}),150),setTimeout((function(){a.addClass("c")}),2e3),setTimeout((function(){!function(){switch(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"blackhole"}),Xc(`extinct_${t.race.species}`),t.race.universe){case"heavy":Xc("heavy");break;case"antimatter":Xc("canceled");break;case"evil":Xc("eviltwin");break;case"micro":Xc("microbang",!0);break;case"standard":Xc("whitehole")}t.space.hasOwnProperty("spaceport")&&0===t.space.spaceport.count&&Xc("red_dead"),Xc("squished",!0),"evil"===t.race.universe&&"angelic"===di[t.race.species].type&&eo("nephilim"),t.race.junker&&"junker"===t.race.species&&eo("the_misery"),t.race.decay&&Xc("dissipated"),t.race.steelen&&eo("steelem");let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=mc("bigbang");so(),t.stats.blackhole++,Fc(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),t.prestige.Dark.count=+(t.prestige.Dark.count+o.dark).toFixed(3),t.stats.dark=+(t.stats.dark+o.dark).toFixed(3),t.stats.universes++;let n=!!t.race.hasOwnProperty("srace")&&t.race.srace,l=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:"bigbang",seeded:!0,bigbang:!0,probes:4,seed:Math.floor(m(1e4)),ascended:!1},l>0&&(t.race.corruption=l),n&&(t.race.srace=n),Q({orbit:s,biome:i,ptrait:c,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),4e3),!1}return!1},flair:()=>F("tech_infusion_confirm_flair")},stabilize_blackhole:{id:"tech-stabilize_blackhole",title:F("tech_stabilize_blackhole"),desc:()=>`
    ${F("tech_stabilize_blackhole")}
    ${F("tech_stabilize_blackhole2")}
    `,category:"stellar_engine",era:"interstellar",reqs:{whitehole:1},grant:["stablized",1],cost:{Knowledge:()=>15e5,Neutronium:()=>2e4},effect:F("tech_stabilize_blackhole_effect"),action(){if(Os($(this)[0])){if(t.interstellar.stellar_engine.mass+=2e4*Va.Neutronium/1e10,t.interstellar.stellar_engine.mass+=40*t.interstellar.stellar_engine.exotic,t.interstellar.stellar_engine.exotic=0,delete t.tech.whitehole,t.race.banana&&t.interstellar.stellar_engine.mass>=12){let e=Yc();t.stats.banana.b3[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b3.l=!0)}return!0}return!1}},veil:{id:"tech-veil",title:F("tech_veil"),desc:F("tech_veil"),category:"magic",era:"interstellar",reqs:{blackhole:2},condition:()=>"magic"===t.race.universe,grant:["veil",1],cost:{Knowledge:()=>125e4},effect:F("tech_veil_effect"),action(){return!!Os($(this)[0])}},mana_syphon:{id:"tech-mana_syphon",title:F("tech_mana_syphon"),desc:F("tech_mana_syphon"),category:"magic",era:"interstellar",reqs:{veil:1},condition:()=>"magic"===t.race.universe,grant:["veil",2],cost:{Knowledge:()=>15e5},effect:F("tech_mana_syphon_effect"),action(){return!!Os($(this)[0])},post(){Oe("Physics")}},gravitational_waves:{id:"tech-gravitational_waves",title:F("tech_gravitational_waves"),desc:F("tech_gravitational_waves"),category:"power_generation",era:"interstellar",reqs:{blackhole:4},grant:["gravity",1],cost:{Knowledge:()=>125e4},effect:F("tech_gravitational_waves_effect"),action(){return!!Os($(this)[0])}},gravity_convection:{id:"tech-gravity_convection",title:F("tech_gravity_convection"),desc:F("tech_gravity_convection"),category:"power_generation",era:"interstellar",reqs:{gravity:1},grant:["gravity",2],cost:{Knowledge:()=>135e4},effect:F("tech_gravity_convection_effect"),action(){return!!Os($(this)[0])}},wormholes:{id:"tech-wormholes",title:F("tech_wormholes"),desc:F("tech_wormholes"),category:"space_exploration",era:"intergalactic",reqs:{gravity:1,science:15},grant:["stargate",1],cost:{Knowledge:()=>225e4},effect:F("tech_wormholes_effect"),action(){return!!Os($(this)[0])}},portal:{id:"tech-portal",title:F("tech_portal"),desc:F("tech_portal_desc"),category:"hell_dimension",era:"interstellar",reqs:{wsc:1},grant:["portal",1],cost:{Knowledge:()=>5e5},effect:F("tech_portal_effect"),action(){return!!Os($(this)[0])}},fortifications:{id:"tech-fortifications",title:F("tech_fort"),desc:F("tech_fort_desc"),category:"hell_dimension",era:"interstellar",reqs:{portal:1},grant:["portal",2],cost:{Knowledge:()=>55e4,Stone:()=>1e6},effect:F("tech_fort_effect"),action(){return!!Os($(this)[0])&&(t.settings.showPortal=!0,t.settings.portal.fortress=!0,t.settings.msgFilters.hell.unlocked||(t.settings.msgFilters.hell.unlocked=!0,t.settings.msgFilters.hell.vis=!0),t.portal.fortress={threat:1e4,garrison:0,walls:100,repair:0,patrols:0,patrol_size:10,siege:999,notify:"Yes",s_ntfy:"Yes",nocrew:!1},t.portal.turret={count:0,on:0},t.portal.carport={count:0,damaged:0,repair:0},"demonic"===di[t.race.species].type?Xc("blood_war"):Xc("pandemonium"),t.portal.observe={settings:{expanded:!1,average:!1,hyperSlow:!1,display:"game_days",dropKills:!0,dropGems:!0},stats:{total:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}},period:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}}},graphID:0,graphs:{}},!0)},post(){Ga()}},war_drones:{id:"tech-war_drones",title:F("tech_war_drones"),desc:F("tech_war_drones"),category:"hell_dimension",era:"interstellar",reqs:{portal:2,graphene:1},grant:["portal",3],cost:{Knowledge:()=>7e5},effect:F("tech_war_drones_effect"),action(){return!!Os($(this)[0])&&(t.settings.portal.badlands=!0,t.portal.war_drone={count:0,on:0},!0)}},demon_attractor:{id:"tech-demon_attractor",title:F("tech_demon_attractor"),desc:F("tech_demon_attractor"),category:"hell_dimension",era:"interstellar",reqs:{portal:3,stanene:1},grant:["portal",4],cost:{Knowledge:()=>745e3},effect:F("tech_demon_attractor_effect"),action(){return!!Os($(this)[0])&&(t.portal.attractor={count:0,on:0},!0)}},combat_droids:{id:"tech-combat_droids",title:F("tech_combat_droids"),desc:F("tech_combat_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:4},grant:["portal",5],cost:{Knowledge:()=>762e3,Soul_Gem:()=>1},effect:F("tech_combat_droids_effect"),action(){return!!Os($(this)[0])&&(t.portal.war_droid={count:0,on:0},!0)},flair:()=>F("tech_combat_droids_flair")},repair_droids:{id:"tech-repair_droids",title:F("tech_repair_droids"),desc:F("tech_repair_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:5},grant:["portal",6],cost:{Knowledge:()=>794e3,Soul_Gem:()=>1},effect:F("tech_repair_droids_effect"),action(){return!!Os($(this)[0])&&(t.portal.repair_droid={count:0,on:0},!0)}},advanced_predators:{id:"tech-advanced_predators",title:F("tech_advanced_predators"),desc:F("tech_advanced_predators"),category:"hell_dimension",era:"intergalactic",reqs:{portal:6,xeno:4},grant:["portal",7],cost:{Knowledge:()=>5e6,Bolognium:()=>5e5,Vitreloy:()=>25e4},effect:F("tech_advanced_predators_effect"),action(){return!!Os($(this)[0])}},enhanced_droids:{id:"tech-enhanced_droids",title:F("tech_enhanced_droids"),desc:F("tech_enhanced_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:5,military:9},grant:["hdroid",1],cost:{Knowledge:()=>105e4},effect:F("tech_enhanced_droids_effect"),action(){return!!Os($(this)[0])}},sensor_drone:{id:"tech-sensor_drone",title:F("tech_sensor_drone"),desc:F("tech_sensor_drone"),category:"hell_dimension",era:"interstellar",reqs:{portal:3,infernite:1,stanene:1,graphene:1},grant:["infernite",2],cost:{Knowledge:()=>725e3},effect:F("tech_sensor_drone_effect"),action(){return!!Os($(this)[0])&&(t.portal.sensor_drone={count:0,on:0},!0)}},map_terrain:{id:"tech-map_terrain",title:F("tech_map_terrain"),desc:F("tech_map_terrain"),category:"hell_dimension",era:"interstellar",reqs:{infernite:2},grant:["infernite",3],cost:{Knowledge:()=>948e3},effect:()=>F("tech_map_terrain_effect"),action(){return!!Os($(this)[0])}},calibrated_sensors:{id:"tech-calibrated_sensors",title:F("tech_calibrated_sensors"),desc:F("tech_calibrated_sensors"),category:"hell_dimension",era:"interstellar",reqs:{infernite:3},grant:["infernite",4],cost:{Knowledge:()=>1125e3,Infernite:()=>3500},effect:()=>F("tech_calibrated_sensors_effect"),action(){return!!Os($(this)[0])}},shield_generator:{id:"tech-shield_generator",title:F("tech_shield_generator"),desc:F("tech_shield_generator"),category:"hell_dimension",era:"intergalactic",reqs:{high_tech:14,gateway:3,infernite:4},grant:["infernite",5],cost:{Knowledge:()=>268e4,Bolognium:()=>75e3},effect:()=>F("tech_shield_generator_effect"),action(){return!!Os($(this)[0])}},enhanced_sensors:{id:"tech-enhanced_sensors",title:F("tech_enhanced_sensors"),desc:F("tech_enhanced_sensors"),category:"hell_dimension",era:"intergalactic",reqs:{infernite:5,xeno:4},grant:["infernite",6],cost:{Knowledge:()=>475e4,Vitreloy:()=>25e3},effect:()=>F("tech_enhanced_sensors_effect"),action(){return!!Os($(this)[0])}},xeno_linguistics:{id:"tech-xeno_linguistics",title:F("tech_xeno_linguistics"),desc:F("tech_xeno_linguistics"),category:"andromeda",era:"intergalactic",reqs:{xeno:1},grant:["xeno",2],cost:{Knowledge:()=>3e6},effect:()=>F("tech_xeno_linguistics_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.gorddon=!0,!0)}},xeno_culture:{id:"tech-xeno_culture",title:F("tech_xeno_culture"),desc:F("tech_xeno_culture"),category:"progress",era:"intergalactic",reqs:{xeno:3},grant:["xeno",4],cost:{Knowledge:()=>34e5},effect:()=>F("tech_xeno_culture_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name,di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].entity]),action(){return!!Os($(this)[0])&&(t.galaxy.embassy={count:0,on:0},!0)}},cultural_exchange:{id:"tech-cultural_exchange",title:F("tech_cultural_exchange"),desc:F("tech_cultural_exchange"),category:"andromeda",era:"intergalactic",reqs:{xeno:5},grant:["xeno",6],cost:{Knowledge:()=>355e4},effect:()=>F("tech_cultural_exchange_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!Os($(this)[0])&&(t.galaxy.symposium={count:0,on:0},t.galaxy.dormitory={count:0,on:0},!0)}},shore_leave:{id:"tech-shore_leave",title:F("tech_shore_leave"),desc:F("tech_shore_leave"),category:"science",era:"intergalactic",reqs:{andromeda:3,xeno:6},grant:["xeno",7],cost:{Knowledge:()=>46e5},effect:()=>F("tech_shore_leave_effect"),action(){return!!Os($(this)[0])}},xeno_gift:{id:"tech-xeno_gift",title:F("tech_xeno_gift"),desc:F("tech_xeno_gift"),category:"andromeda",era:"intergalactic",reqs:{high_tech:16,xeno:7},grant:["xeno",8],cost:{Knowledge:()=>65e5,Infernite:()=>125e3},effect:()=>F("tech_xeno_gift_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.consulate={count:0},t.settings.space.alien1=!0,Di(F("tech_xeno_gift_msg",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),"info",!1,["progress"]),!0)}},industrial_partnership:{id:"tech-industrial_partnership",title:F("tech_industrial_partnership"),desc:()=>F("tech_industrial_partnership"),category:"andromeda",era:"intergalactic",reqs:{xeno:9},grant:["xeno",10],cost:{Knowledge:()=>725e4},effect:()=>F("tech_industrial_partnership_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!Os($(this)[0])&&(t.galaxy.vitreloy_plant={count:0,on:0},!0)}},embassy_housing:{id:"tech-embassy_housing",title:F("tech_embassy_housing"),desc:()=>F("tech_embassy_housing"),category:"andromeda",era:"intergalactic",reqs:{xeno:10,science:18},grant:["xeno",11],cost:{Knowledge:()=>1075e4},effect:()=>F("tech_embassy_housing_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!Os($(this)[0])}},advanced_telemetry:{id:"tech-advanced_telemetry",title:F("tech_advanced_telemetry"),desc:F("tech_advanced_telemetry"),category:"science",era:"intergalactic",reqs:{xeno:5},grant:["telemetry",1],cost:{Knowledge:()=>42e5,Vitreloy:()=>1e4},effect:()=>F("tech_advanced_telemetry_effect"),action(){return!!Os($(this)[0])}},defense_platform:{id:"tech-defense_platform",title:F("galaxy_defense_platform"),desc:F("galaxy_defense_platform"),category:"andromeda",era:"intergalactic",reqs:{stargate:5,piracy:1},grant:["stargate",6],cost:{Knowledge:()=>485e4},effect:F("tech_defense_platform_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.defense_platform={count:0,on:0},!0)}},scout_ship:{id:"tech-scout_ship",title:F("galaxy_scout_ship"),desc:F("galaxy_scout_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{gateway:3},grant:["andromeda",1],cost:{Knowledge:()=>26e5},effect:()=>F("tech_scout_ship_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.scout_ship={count:0,on:0,crew:0,mil:0},!0)}},corvette_ship:{id:"tech-corvette_ship",title:F("galaxy_corvette_ship"),desc:F("galaxy_corvette_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:1,xeno:1},grant:["andromeda",2],cost:{Knowledge:()=>32e5},effect:()=>F("tech_corvette_ship_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.corvette_ship={count:0,on:0,crew:0,mil:0},!0)}},frigate_ship:{id:"tech-frigate_ship",title:F("galaxy_frigate_ship"),desc:F("galaxy_frigate_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:2,xeno:6},grant:["andromeda",3],cost:{Knowledge:()=>4e6},effect:()=>F("tech_frigate_ship_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.frigate_ship={count:0,on:0,crew:0,mil:0},Rt(),!0)}},cruiser_ship:{id:"tech-cruiser_ship",title:F("galaxy_cruiser_ship"),desc:F("galaxy_cruiser_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:3,xeno:10},grant:["andromeda",4],cost:{Knowledge:()=>75e5},effect:()=>F("tech_cruiser_ship_effect",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),action(){return!!Os($(this)[0])&&(t.galaxy.cruiser_ship={count:0,on:0,crew:0,mil:0},t.galaxy.foothold={count:0,on:0,support:0,s_max:0},t.settings.space.alien2=!0,Rt(),!0)}},dreadnought:{id:"tech-dreadnought",title:F("galaxy_dreadnought"),desc:F("galaxy_dreadnought"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:4,science:18},grant:["andromeda",5],cost:{Knowledge:()=>1e7},effect:()=>F("tech_dreadnought_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.dreadnought={count:0,on:0,crew:0,mil:0},Rt(),!0)}},ship_dock:{id:"tech-ship_dock",title:F("galaxy_ship_dock"),desc:F("galaxy_ship_dock"),category:"andromeda_ships",era:"intergalactic",reqs:{gateway:3,xeno:6},grant:["gateway",4],cost:{Knowledge:()=>39e5},effect:()=>F("tech_ship_dock_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.ship_dock={count:0,on:0},!0)}},ore_processor:{id:"tech-ore_processor",title:F("galaxy_ore_processor"),desc:F("galaxy_ore_processor"),category:"space_mining",era:"intergalactic",reqs:{conflict:2},grant:["conflict",3],cost:{Knowledge:()=>75e5},effect:()=>F("tech_ore_processor_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.ore_processor={count:0,on:0},!0)}},scavenger:{id:"tech-scavenger",title:F("galaxy_scavenger"),desc:F("galaxy_scavenger"),category:"science",era:"intergalactic",reqs:{conflict:3},grant:["conflict",4],cost:{Knowledge:()=>8e6},effect:()=>F("tech_scavenger_effect",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),action(){return!!Os($(this)[0])&&(t.galaxy.scavenger={count:0,on:0,crew:0},!0)}},coordinates:{id:"tech-coordinates",title:F("tech_coordinates"),desc:F("tech_coordinates"),category:"andromeda",era:"intergalactic",reqs:{science:18,conflict:5},grant:["chthonian",1],cost:{Knowledge:()=>1e7},effect:()=>F("tech_coordinates_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.minelayer={count:0,on:0,crew:0,mil:0},t.settings.space.chthonian=!0,!0)}},chthonian_survey:{id:"tech-chthonian_survey",title:F("tech_chthonian_survey"),desc:F("tech_chthonian_survey"),category:"space_mining",era:"intergalactic",reqs:{chthonian:2},grant:["chthonian",3],cost:{Knowledge:()=>118e5},effect:()=>F("tech_chthonian_survey_effect"),action(){return!!Os($(this)[0])&&(t.resource.Orichalcum.display=!0,t.galaxy.excavator={count:0,on:0},t.galaxy.raider={count:0,on:0,crew:0,mil:0},Di(F("tech_chthonian_survey_result"),"info",!1,["progress"]),!0)},post(){zi()}},gateway_depot:{id:"tech-gateway_depot",title:F("galaxy_gateway_depot"),desc:F("galaxy_gateway_depot"),category:"storage",era:"intergalactic",reqs:{gateway:4},grant:["gateway",5],cost:{Knowledge:()=>435e4},effect:()=>F("tech_gateway_depot_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.gateway_depot={count:0,on:0},!0)}},soul_forge:{id:"tech-soul_forge",title:F("portal_soul_forge_title"),desc:F("portal_soul_forge_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:3},grant:["hell_pit",4],cost:{Knowledge:()=>275e4},effect:()=>F("tech_soul_forge_effect"),action(){return!!Os($(this)[0])&&(t.portal.soul_forge={count:0,on:0,kills:0},!0)}},soul_attractor:{id:"tech-soul_attractor",title:F("portal_soul_attractor_title"),desc:F("portal_soul_attractor_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:4,high_tech:16},grant:["hell_pit",5],cost:{Knowledge:()=>55e5},effect:()=>F("tech_soul_attractor_effect"),action(){return!!Os($(this)[0])&&(t.portal.soul_attractor={count:0,on:0},!0)}},soul_absorption:{id:"tech-soul_absorption",title:F("tech_soul_absorption"),desc:F("tech_soul_absorption"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:5},grant:["hell_pit",6],cost:{Knowledge:()=>6e6,Infernite:()=>25e4},effect:()=>F("tech_soul_absorption_effect"),action(){return!!Os($(this)[0])}},soul_link:{id:"tech-soul_link",title:F("tech_soul_link"),desc:F("tech_soul_link"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:6},grant:["hell_pit",7],cost:{Knowledge:()=>75e5,Vitreloy:()=>25e4},effect:()=>F("tech_soul_link_effect"),action(){return!!Os($(this)[0])}},gun_emplacement:{id:"tech-gun_emplacement",title:F("portal_gun_emplacement_title"),desc:F("portal_gun_emplacement_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:4},grant:["hell_gun",1],cost:{Knowledge:()=>3e6},effect:()=>F("tech_gun_emplacement_effect"),action(){return!!Os($(this)[0])&&(t.portal.gun_emplacement={count:0,on:0},!0)}},advanced_emplacement:{id:"tech-advanced_emplacement",title:F("tech_advanced_emplacement"),desc:F("tech_advanced_emplacement"),category:"hell_dimension",era:"intergalactic",reqs:{hell_gun:1,high_tech:17},grant:["hell_gun",2],cost:{Knowledge:()=>125e5,Orichalcum:()=>18e4},effect:()=>F("tech_advanced_emplacement_effect"),action(){return!!Os($(this)[0])}},dial_it_to_11:{id:"tech-dial_it_to_11",title:F("tech_dial_it_to_11"),desc:F("tech_dial_it_to_11"),category:"science",wiki:!1,era:"deep_space",reqs:{quaked:1},grant:["quaked",2],cost:{Knowledge:()=>5e5},condition:()=>!(t.race.sludge&&!t.race.cataclysm),effect(){let e=mc("cataclysm"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
    ${F("tech_dial_it_to_11_effect",[Xt().dwarf,t.race.cataclysm?Xt().red:di[t.race.species].home])}
    ${F("tech_dial_it_to_11_effect2")}
    ${F("star_dock_genesis_effect2",[e.plasmid,a])}
    ${F("star_dock_genesis_effect3",[e.phage])}
    `},action(){return!!Os($(this)[0])&&($("#main").addClass("earthquake"),setTimeout((function(){$("#main").removeClass("earthquake"),function(){if(t.city.ptrait.includes("unstable")&&t.tech.quaked){M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),Zi("reset",{end:"cataclysm"}),O();let a=mc("cataclysm");t.stats.cataclysm++,Fc(),t.prestige.Phage.count+=a.phage,t.stats.phage+=a.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=a.plasmid,t.stats.antiplasmid+=a.plasmid):(t.prestige.Plasmid.count+=a.plasmid,t.stats.plasmid+=a.plasmid),Xc("squished",!0),Xc(`extinct_${t.race.species}`),"hellscape"===t.city.biome&&"demonic"!==di[t.race.species].type&&eo("take_no_advice"),so(),Xc("shaken"),t.race.cataclysm&&Xc("failed_history");let r=!!t.race.hasOwnProperty("srace")&&t.race.srace,s=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:t.race.species,gods:t.race.gods,old_gods:t.race.old_gods,universe:t.race.universe,seeded:!1,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},s>0&&(t.race.corruption=s),r&&(t.race.srace=r),Q({orbit:t.city.calendar.orbit,biome:t.city.biome,ptrait:t.city.ptrait,geology:t.city.geology}),"antimatter"===t.race.universe?t.race.weak_mastery=1:t.race.no_plasmid=1;let i=["crispr","trade","craft"];for(let e=0;eF("tech_dial_it_to_11_flair")},limit_collider:{id:"tech-limit_collider",title:F("tech_limit_collider"),desc:F("tech_limit_collider"),category:"science",wiki:!1,era:"deep_space",reqs:{quaked:1},grant:["quaked",2],cost:{Knowledge:()=>5e5},effect:()=>F("tech_limit_collider_effect"),action(){return!!Os($(this)[0])}},mana:{id:"tech-mana",title:F("tech_mana"),desc:F("tech_mana"),category:"magic",era:"civilized",reqs:{primitive:3},grant:["magic",1],condition:()=>"magic"===t.race.universe,cost:{Knowledge:()=>25},effect:()=>F("tech_mana_effect"),action(){return!!Os($(this)[0])&&(t.resource.Mana.display=!0,t.resource.Crystal.display=!0,t.civic.crystal_miner.display=!0,t.race.witch_hunter&&(t.resource.Sus.display=!0),!0)},flair:F("tech_mana_flair"),post(){zi()}},ley_lines:{id:"tech-ley_lines",title:F("tech_ley_lines"),desc:F("tech_ley_lines"),category:"magic",era:"civilized",reqs:{magic:1},grant:["magic",2],condition:()=>"magic"===t.race.universe,cost:{Knowledge:()=>40},effect:()=>F("tech_ley_lines_effect"),action(){return!!Os($(this)[0])&&(t.tech.isolation?t.tauceti.pylon={count:0}:t.race.cataclysm||t.race.orbit_decayed?t.space.pylon={count:0}:t.city.pylon={count:0},!0)}},rituals:{id:"tech-rituals",title:F("tech_rituals"),desc:F("tech_rituals"),category:"magic",era:"civilized",reqs:{magic:2},grant:["magic",3],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>25,Knowledge:()=>750,Crystal:()=>50},effect:()=>F("tech_rituals_effect"),action(){return!!Os($(this)[0])&&(t.race.casting={farmer:0,miner:0,lumberjack:0,science:0,factory:0,army:0,hunting:0,crafting:0,total:0},t.settings.showIndustry=!0,!0)},post(){Ws()}},crafting_ritual:{id:"tech-crafting_ritual",title:F("tech_crafting_ritual"),desc:F("tech_crafting_ritual"),category:"magic",era:"discovery",reqs:{magic:3,foundry:5},grant:["magic",4],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>100,Knowledge:()=>15e3,Crystal:()=>2500},effect:()=>F("tech_crafting_ritual_effect"),action(){return!!Os($(this)[0])&&(t.race.casting.crafting=0,!0)},post(){Ws()}},mana_nexus:{id:"tech-mana_nexus",title:F("tech_mana_nexus"),desc:F("tech_mana_nexus"),category:"magic",era:"early_space",reqs:{magic:4,space:3,luna:1},grant:["magic",5],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>500,Knowledge:()=>16e4,Crystal:()=>2500},effect:()=>F("tech_mana_nexus_effect"),action(){return!!Os($(this)[0])},post(){Oe("Physics")}},clerics:{id:"tech-clerics",title:F("tech_clerics"),desc:F("tech_clerics"),category:"magic",era:"civilized",reqs:{magic:3},grant:["cleric",1],condition:()=>!!("magic"===t.race.universe&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display),cost:{Mana:()=>100,Knowledge:()=>2e3,Crystal:()=>100},effect:()=>F("tech_clerics_effect"),action(){return!!Os($(this)[0])}},conjuring:{id:"tech-conjuring",title:F("tech_conjuring"),desc:F("tech_conjuring_desc"),category:"magic",era:"civilized",reqs:{magic:1},grant:["conjuring",1],not_trait:["cataclysm"],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>2,Crystal:()=>5},effect:()=>F("tech_conjuring_effect"),action(){return!!Os($(this)[0])}},res_conjuring:{id:"tech-res_conjuring",title:F("tech_res_conjuring"),desc:F("tech_res_conjuring"),category:"magic",era:"civilized",reqs:{conjuring:1},grant:["conjuring",2],not_trait:["cataclysm"],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>5,Crystal:()=>10},effect:()=>F("tech_res_conjuring_effect"),action(){return!!Os($(this)[0])}},alchemy:{id:"tech-alchemy",title:F("tech_alchemy"),desc:F("tech_alchemy"),category:"magic",era:"discovery",reqs:{magic:3,high_tech:1},grant:["alchemy",1],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>100,Knowledge:()=>1e4,Crystal:()=>250},effect:()=>F("tech_alchemy_effect"),action(){return!!Os($(this)[0])&&(t.race.alchemy={Food:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0},t.settings.showAlchemy=!0,!0)},post(){rc($("#resources")),rr(),t.settings.tabLoad&&ar("alchemy")}},transmutation:{id:"tech-transmutation",title:F("tech_transmutation"),desc:F("tech_transmutation"),category:"magic",era:"intergalactic",reqs:{alchemy:1,high_tech:16},grant:["alchemy",2],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>1250,Knowledge:()=>55e5,Crystal:()=>1e6},effect:()=>F("tech_transmutation_effect"),action(){return!!Os($(this)[0])},post(){rc($("#resources")),rr()}},secret_society:{id:"tech-secret_society",title:F("tech_secret_society"),desc:F("tech_secret_society"),category:"magic",era:"civilized",reqs:{magic:1},grant:["roguemagic",1],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>10,Knowledge:()=>45},effect:()=>F("tech_secret_society_effect"),action(){return!!Os($(this)[0])}},cultists:{id:"tech-cultists",title:F("tech_cultists"),desc:F("tech_cultists"),category:"magic",era:"civilized",reqs:{roguemagic:1,cleric:1},grant:["roguemagic",2],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>250,Knowledge:()=>2125},effect:()=>F("tech_cultists_effect"),action(){return!!Os($(this)[0])}},conceal_ward:{id:"tech-conceal_ward",title:F("tech_conceal_ward"),desc:F("tech_conceal_ward"),category:"magic",era:"discovery",reqs:{roguemagic:2,theatre:3},grant:["roguemagic",3],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>500,Knowledge:()=>8200,Crystal:()=>1e3},effect:()=>F("tech_conceal_ward_effect"),action(){return!!Os($(this)[0])&&(t.city.conceal_ward={count:0},t.space.conceal_ward={count:0},!0)}},subtle_rituals:{id:"tech-subtle_rituals",title:F("tech_subtle_rituals"),desc:F("tech_subtle_rituals"),category:"magic",era:"discovery",reqs:{roguemagic:3,magic:4},grant:["roguemagic",4],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>100,Knowledge:()=>15e3,Crystal:()=>2500},effect:()=>F("tech_subtle_rituals_effect"),action(){return!!Os($(this)[0])}},pylon_camouflage:{id:"tech-pylon_camouflage",title:F("tech_pylon_camouflage"),desc:F("tech_pylon_camouflage"),category:"magic",era:"industrialized",reqs:{roguemagic:4,high_tech:3},grant:["roguemagic",5],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>1e3,Knowledge:()=>3e4,Crystal:()=>3750},effect:()=>F("tech_pylon_camouflage_effect"),action(){return!!Os($(this)[0])}},fake_tech:{id:"tech-fake_tech",title:F("tech_fake_tech"),desc:F("tech_fake_tech"),category:"magic",era:"industrialized",reqs:{roguemagic:5,high_tech:4},grant:["roguemagic",6],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>2250,Knowledge:()=>6e4},effect:()=>F("tech_fake_tech_effect"),action(){return!!Os($(this)[0])}},concealment:{id:"tech-concealment",title:F("tech_concealment"),desc:F("tech_concealment"),category:"magic",era:"early_space",reqs:{roguemagic:6,magic:5},grant:["roguemagic",7],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>3e3,Knowledge:()=>185e3},effect:()=>F("tech_concealment_effect"),action(){return!!Os($(this)[0])}},improved_concealment:{id:"tech-improved_concealment",title:F("tech_improved_concealment"),desc:F("tech_improved_concealment"),category:"magic",era:"intergalactic",reqs:{roguemagic:7,forbidden:1},grant:["roguemagic",8],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>t.race.no_plasmid?6e3:25e3,Knowledge:()=>2e7},effect:()=>F("tech_improved_concealment_effect"),action(){return!!Os($(this)[0])}},outerplane_summon:{id:"tech-outerplane_summon",title:F("tech_outerplane_summon"),desc:F("tech_outerplane_summon"),category:"magic",era:"dimensional",reqs:{roguemagic:8,forbidden:4,hell_spire:10,b_stone:2,waygate:3},grant:["forbidden",5],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>t.race.no_plasmid?12e3:6e4,Knowledge:()=>6e7,Demonic_Essence:()=>1},effect:()=>F("tech_outerplane_summon_effect"),action(){return!!Os($(this)[0])}},dark_bomb:{id:"tech-dark_bomb",title:F("tech_dark_bomb"),desc:F("tech_dark_bomb"),category:"hell_dimension",era:"dimensional",reqs:{},reqs:{hell_spire:10,b_stone:2,waygate:2,sphinx_bribe:1},condition(){let e=Yc();return!!(t.stats.spire.hasOwnProperty(e)&&t.stats.spire[e].hasOwnProperty("dlstr")&&t.stats.spire[e].dlstr>0)},grant:["dl_reset",1],cost:{Knowledge:()=>65e6,Soul_Gem:()=>5e3,Blood_Stone:()=>25,Dark:()=>1,Supply:()=>1e6},effect:()=>F("tech_dark_bomb_effect"),action(){return!!Os($(this)[0])&&(t.portal.waygate.progress=100,t.portal.waygate.on=0,t.tech.waygate=3,t.resource.Demonic_Essence.display=!0,t.resource.Demonic_Essence.amount=1,!0)},flair:()=>F("tech_dark_bomb_flair")},bribe_sphinx:{id:"tech-bribe_sphinx",title:F("portal_sphinx_bribe"),desc:F("portal_sphinx_bribe"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:8},grant:["sphinx_bribe",1],cost:{Soul_Gem:()=>250,Supply:()=>5e5},effect:()=>F("tech_bribe_sphinx_effect"),action(){return!!Os($(this)[0])&&(t.resource.Codex.display=!0,t.resource.Codex.amount=1,Di(F("tech_bribe_sphinx_msg"),"info",!1,["progress","hell"]),!0)}},alien_biotech:{id:"tech-alien_biotech",title:F("tech_alien_biotech"),desc:F("tech_alien_biotech"),category:"science",era:"solar",reqs:{genetics:8,kuiper:1},grant:["biotech",1],path:["truepath"],cost:{Knowledge:()=>24e5,Orichalcum:()=>125e3,Cipher:()=>15e3},effect:()=>F(t.race.orbit_decayed?"tech_alien_biotech_effect_alt":"tech_alien_biotech_effect"),action(){return!!Os($(this)[0])}},zero_g_lab:{id:"tech-zero_g_lab",title:F("tech_zero_g_lab"),desc:F("tech_zero_g_lab"),category:"science",era:"solar",path:["truepath"],reqs:{high_tech:13,graphene:1,enceladus:2},grant:["enceladus",3],cost:{Knowledge:()=>9e5},effect:F("tech_zero_g_lab_effect"),action(){return!!Os($(this)[0])&&(t.space.zero_g_lab={count:0,on:0},!0)}},operating_base:{id:"tech-operating_base",title:F("tech_operating_base"),desc:F("tech_operating_base"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{enceladus:3,triton:1},grant:["enceladus",4],cost:{Knowledge:()=>14e5},effect:()=>F("tech_operating_base_effect",[Xt().enceladus]),action(){return!!Os($(this)[0])&&(t.space.operating_base={count:0,on:0},!0)}},munitions_depot:{id:"tech-munitions_depot",title:F("tech_munitions_depot"),desc:F("tech_munitions_depot"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{enceladus:4},grant:["enceladus",5],cost:{Knowledge:()=>15e5},effect:()=>F("tech_munitions_depot_effect"),action(){return!!Os($(this)[0])&&(t.space.munitions_depot={count:0},!0)}},fob:{id:"tech-fob",title:F("tech_fob"),desc:F("tech_fob"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{triton:1},grant:["triton",2],cost:{Knowledge:()=>145e4},effect:()=>F("tech_fob_effect",[Xt().triton]),action(){return!!Os($(this)[0])&&(t.space.fob={count:0,on:0,troops:0,enemy:0},t.space.lander={count:0,on:0},t.space.crashed_ship={count:0},!0)}},bac_tanks_tp:{id:"tech-bac_tanks_tp",title:F("tech_bac_tanks"),desc:F("tech_bac_tanks_desc"),category:"military",era:"solar",path:["truepath"],reqs:{medic:1,triton:2},grant:["medic",2],cost:{Knowledge:()=>175e4},effect:F("tech_bac_tanks_effect"),action(){return!!Os($(this)[0])}},medkit:{id:"tech-medkit",title:F("tech_medkit"),desc:F("tech_medkit"),category:"military",era:"solar",path:["truepath"],reqs:{medic:2,outer:4},grant:["medic",3],cost:{Knowledge:()=>225e4,Quantium:()=>25e4,Cipher:()=>8e3},effect:F("tech_medkit_effect"),action(){return!!Os($(this)[0])}},sam_site:{id:"tech-sam_site",title:F("tech_sam_site"),desc:F("tech_sam_site"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{titan:6,triton:1},grant:["titan",7],cost:{Knowledge:()=>1475e3},effect:()=>F("tech_sam_site_effect",[Xt().titan]),action(){return!!Os($(this)[0])&&(t.space.sam={count:0,on:0},!0)}},data_cracker:{id:"tech-data_cracker",title:F("tech_data_cracker"),desc:F("tech_data_cracker"),category:"science",era:"solar",path:["truepath"],reqs:{titan:7,kuiper:1},grant:["titan",8],cost:{Knowledge:()=>275e4,Cipher:()=>25e3},effect:()=>F("tech_data_cracker_effect",[t.resource.Cipher.name]),action(){return!!Os($(this)[0])&&(t.space.decoder={count:0,on:0},!0)}},ai_core_tp:{id:"tech-ai_core_tp",title:F("tech_ai_core"),desc:F("tech_ai_core"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan:8},grant:["titan",9],cost:{Knowledge:()=>3e6,Cipher:()=>1e5},effect:F("tech_ai_core_effect"),action(){return!!Os($(this)[0])&&(t.space.ai_core={count:0},!0)}},ai_optimizations:{id:"tech-ai_optimizations",title:F("tech_ai_optimizations"),desc:F("tech_ai_optimizations"),category:"ai_core",era:"solar",path:["truepath"],reqs:{eris:3,titan:9,titan_ai_core:1,dig_control:1},grant:["titan_ai_core",2],cost:{Knowledge:()=>375e4,Cipher:()=>75e3},effect:F("tech_ai_optimizations_effect"),action(){return!!Os($(this)[0])},class:"synth"},synthetic_life:{id:"tech-synthetic_life",title:F("tech_synthetic_life"),desc:F("tech_synthetic_life"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:2},grant:["titan_ai_core",3],cost:{Knowledge:()=>4e6,Cipher:()=>75e3},effect:F("tech_synthetic_life_effect"),action(){return!!Os($(this)[0])&&(t.space.ai_colonist={count:0,on:0},!0)},class:"synth"},protocol66:{id:"tech-protocol66",title:F("tech_protocol66"),desc:F("tech_protocol66"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:3,corrupted_ai:1},grant:["corrupted_ai",2],cost:{Knowledge:()=>5e6},effect:F("tech_protocol66_effect"),action(){return!!Cs($(this)[0])},flair:F("tech_protocol66_flair"),class:"synth"},protocol66a:{id:"tech-protocol66a",title:F("tech_protocol66"),desc:F("tech_protocol66"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:3,corrupted_ai:2},wiki:!1,grant:["corrupted_ai",3],cost:{Knowledge:()=>5e6},effect(){let e=mc("ai"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name"),r=`
    ${F("tech_protocol66a_effect_gains",[e.plasmid,a,e.phage,e.cores])}
    `;return`
    ${F("tech_protocol66a_effect")}
    ${r}`},action(){return!!Os($(this)[0])&&(M.w&&M.w.terminate(),Ei(),$("body").append('
    '),$("#aiAppoc").addClass("noise-wrapper"),$("#aiAppoc > div").addClass("noise"),setTimeout((function(){$("body").append('
    '),$("body").append('
    '),$("#deadAirTop").animate({height:"50%",opacity:1},400),$("#deadAirBottom").animate({height:"50%",opacity:1},400)}),3e3),setTimeout((function(){!function(){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"ai apocalypse"}),Xc(`extinct_${t.race.species}`),Xc("obsolete"),Xc("squished",!0),t.race.junker&&"junker"===t.race.species&&eo("the_misery");let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=t.city.geology,n=mc("ai");so(),t.stats.aiappoc++,Fc(),t.prestige.Phage.count+=n.phage,t.stats.phage+=n.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=n.plasmid,t.stats.antiplasmid+=n.plasmid):(t.prestige.Plasmid.count+=n.plasmid,t.stats.plasmid+=n.plasmid),t.prestige.AICore.count+=n.cores,t.stats.cores+=n.cores;let l="synthetic"!==di[a].type?a:t.race.hasOwnProperty("srace")?t.race.srace:a;t.stats.synth[l]=!0;let u=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,srace:l,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},u>0&&(t.race.corruption=u),Q({orbit:s,biome:i,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),4e3),!0)},flair:F("tech_protocol66a_flair"),class:"synth"},terraforming_tp:{id:"tech-terraforming_tp",title:F("tech_terraforming"),desc:F("tech_terraforming"),category:"special",era:"solar",reqs:{dig_control:1,eris:2,titan_ai_core:2},path:["truepath"],grant:["terraforming",1],trait:["orbit_decay"],cost:{Knowledge:()=>5e6},effect:()=>F("tech_terraforming_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.terraformer={count:0},!0)}},quantium:{id:"tech-quantium",title:F("tech_quantium"),desc:F("tech_quantium"),category:"crafting",era:"solar",path:["truepath"],reqs:{supercollider:10,enceladus:3},grant:["quantium",1],cost:{Knowledge:()=>1e6,Elerium:()=>1e3,Nano_Tube:()=>1e6,Graphene:()=>1e6},effect:F("tech_quantium_effect"),action(){return!!Os($(this)[0])&&(t.resource.Quantium.display=!0,!0)},post(){zi()}},anitgrav_bunk:{id:"tech-anitgrav_bunk",title:F("tech_anitgrav_bunk"),desc:F("tech_anitgrav_bunk"),category:"military",era:"solar",path:["truepath"],reqs:{marines:1,quantium:1},grant:["marines",2],cost:{Knowledge:()=>125e4,Quantium:()=>5e5},effect:()=>F("tech_anitgrav_bunk_effect",[F("space_red_space_barracks_title")]),action(){return!!Os($(this)[0])}},higgs_boson_tp:{id:"tech-higgs_boson_tp",title:F("tech_higgs_boson"),desc:F("tech_higgs_boson"),category:"science",era:"early_space",path:["truepath"],reqs:{supercollider:2},grant:["tp_particles",1],cost:{Knowledge:()=>125e3},effect:F("tech_higgs_boson_effect"),action(){return!!Os($(this)[0])}},long_range_probes:{id:"tech-long_range_probes",title:F("tech_long_range_probes"),desc:F("tech_long_range_probes"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{high_tech:10,elerium:1},grant:["outer",1],cost:{Knowledge:()=>4e5,Uranium:()=>2e4,Iridium:()=>25e4,Neutronium:()=>3e3,Elerium:()=>350},effect:F("tech_long_range_probes_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.titan=!0,t.settings.space.enceladus=!0,t.space.titan_spaceport={count:0,on:0,support:0,s_max:0},t.space.electrolysis={count:0,on:0,support:0,s_max:0},!0)}},strange_signal:{id:"tech-strange_signal",title:F("tech_strange_signal"),desc:F("tech_strange_signal"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:1,syard_sensor:4},grant:["outer",2],cost:{Knowledge:()=>135e4},effect:F("tech_strange_signal_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.triton=!0,!0)}},data_analysis:{id:"tech-data_analysis",title:F("tech_data_analysis"),desc:F("tech_data_analysis"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:3},grant:["outer",4],cost:{Knowledge:()=>18e5,Cipher:()=>12500},effect:F("tech_data_analysis_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_data_analysis_result"),"info",!1,["progress"]),t.space.syndicate.spc_titan+=500,t.space.syndicate.spc_enceladus+=250,t.space.syndicate.spc_triton+=1e3,!0)}},mass_relay:{id:"tech-mass_relay",title:F("tech_mass_relay"),desc:F("tech_mass_relay"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:4},grant:["outer",5],cost:{Knowledge:()=>22e5,Cipher:()=>4e4},effect:F("tech_mass_relay_effect"),action(){return!!Os($(this)[0])&&(t.space.mass_relay={count:0},!0)}},nav_data:{id:"tech-nav_data",title:F("tech_nav_data"),desc:F("tech_nav_data"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:6},grant:["outer",7],cost:{Knowledge:()=>225e4,Cipher:()=>6e4},effect:F("tech_nav_data_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.eris=!0,t.settings.space.kuiper=!0,t.tech.eris_scan=0,t.space.drone_control={count:0,on:0,support:0,s_max:0},Di(F("tech_nav_data_result",[Xt().eris]),"info",!1,["progress"]),!0)}},sensor_logs:{id:"tech-sensor_logs",title:F("tech_sensor_logs"),desc:F("tech_sensor_logs"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:7},grant:["outer",8],cost:{Knowledge:()=>35e5,Cipher:()=>65e3},effect:F("tech_sensor_logs_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_sensor_logs_result"),"info",!1,["progress"]),!0)}},dronewar:{id:"tech-dronewar",title:F("tech_dronewar"),desc:F("tech_dronewar"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{eris:2,titan_ai_core:1},grant:["eris",3],cost:{Knowledge:()=>32e5,Cipher:()=>25e3},effect:()=>F("tech_dronewar_effect",[Xt().eris]),action(){return!!Os($(this)[0])&&(t.space.shock_trooper={count:0,on:0},t.space.digsite={count:0,enemy:1e4},!0)}},drone_tank:{id:"tech-drone_tank",title:F("tech_drone_tank"),desc:F("tech_drone_tank"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{eris:3},grant:["eris",4],cost:{Knowledge:()=>34e5,Cipher:()=>5e4},effect:F("tech_drone_tank_effect"),action(){return!!Os($(this)[0])&&(t.space.tank={count:0,on:0},!0)}},stanene_tp:{id:"tech-stanene_tp",title:F("tech_stanene"),desc:F("tech_stanene"),category:"crafting",era:"solar",path:["truepath"],reqs:{titan:1,enceladus:1},grant:["stanene",1],cost:{Knowledge:()=>525e3,Aluminium:()=>5e5,Nano_Tube:()=>1e5},effect:F("tech_stanene_effect"),action(){return!!Os($(this)[0])&&(t.resource.Stanene.display=!0,Di(F("tech_stanene_avail"),"info",!1,["progress"]),!0)},post(){Ws(),zi()}},graphene_tp:{id:"tech-graphene_tp",title:F("tech_graphene"),desc:F("tech_graphene"),category:"crafting",era:"solar",path:["truepath"],reqs:{titan:5},grant:["graphene",1],cost:{Knowledge:()=>64e4,Adamantite:()=>25e3},effect:F("tech_graphene_effect"),action(){return!!Os($(this)[0])&&(t.space.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},!0)}},virtual_reality_tp:{id:"tech-virtual_reality_tp",title:F("tech_virtual_reality"),desc:F("tech_virtual_reality"),category:"progress",era:"solar",path:["truepath"],reqs:{high_tech:11,titan:4,stanene:1},grant:["high_tech",12],cost:{Knowledge:()=>616e3,Nano_Tube:()=>1e6,Stanene:()=>125e3},effect:F("tech_virtual_reality_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_virtual_reality_flair")},electrolysis:{id:"tech-electrolysis",title:F("tech_electrolysis"),desc:F("tech_electrolysis"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:2,enceladus:1},grant:["titan",3],cost:{Knowledge:()=>465e3},effect:()=>F("tech_electrolysis_effect",[Xt().titan,t.resource.Water.name]),action(){return!!Os($(this)[0])&&(t.space.titan_quarters={count:0,on:0},t.space.titan_mine={count:0,on:0,ratio:90},!0)}},storehouse:{id:"tech-storehouse",title:()=>F("tech_storehouse",[Xt().titan]),desc:()=>F("tech_storehouse",[Xt().titan]),category:"storage",era:"solar",path:["truepath"],reqs:{titan:4},grant:["titan",5],cost:{Knowledge:()=>5e5},effect:()=>F("tech_storehouse_effect",[Xt().titan]),action(){return!!Os($(this)[0])&&(t.space.storehouse={count:0},!0)}},adamantite_vault_tp:{id:"tech-adamantite_vault_tp",title:F("tech_adamantite_vault"),desc:F("tech_adamantite_vault"),category:"banking",era:"solar",path:["truepath"],reqs:{vault:2,titan:4},grant:["vault",3],cost:{Money:()=>2e6,Knowledge:()=>56e4,Adamantite:()=>2e4},effect:F("tech_adamantite_vault_effect"),action(){return!!Os($(this)[0])}},titan_bank:{id:"tech-titan_bank",title:()=>F("tech_titan_bank",[Xt().titan]),desc:()=>F("tech_titan_bank",[Xt().titan]),category:"storage",era:"solar",path:["truepath"],reqs:{titan:5},grant:["titan",6],cost:{Knowledge:()=>6e5},effect:()=>F("tech_titan_bank_effect",[Xt().titan]),action(){return!!Os($(this)[0])&&(t.space.titan_bank={count:0},!0)}},hydrogen_plant:{id:"tech-hydrogen_plant",title:F("tech_hydrogen_plant"),desc:F("tech_hydrogen_plant"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:4,stanene:1},grant:["titan_power",1],cost:{Knowledge:()=>55e4},effect:()=>F("tech_hydrogen_plant_effect"),action(){return!!Os($(this)[0])&&(t.space.hydrogen_plant={count:0,on:0},!0)}},water_mining:{id:"tech-water_mining",title:F("tech_water_mining"),desc:F("tech_water_mining"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:2,enceladus:1},grant:["enceladus",2],cost:{Knowledge:()=>45e4},effect:()=>F("tech_water_mining_effect",[Xt().enceladus,di[t.race.species].home,t.resource.Water.name]),action(){return!!Os($(this)[0])&&(t.space.water_freighter={count:0,on:0},!0)}},mercury_smelting:{id:"tech-mercury_smelting",title:F("tech_mercury_smelting"),desc:F("tech_mercury_smelting"),category:"mining",era:"solar",path:["truepath"],reqs:{hell:1,titan:4,smelting:6},grant:["m_smelting",1],cost:{Knowledge:()=>625e3,Adamantite:()=>5e4},effect:()=>F("tech_mercury_smelting_effect",[Xt().hell]),action(){return!!Os($(this)[0])&&(t.space.hell_smelter={count:0},!0)}},iridium_smelting:{id:"tech-iridium_smelting",title:F("tech_iridium_smelting"),desc:F("tech_iridium_smelting"),category:"mining",era:"solar",path:["truepath"],reqs:{m_smelting:1,graphene:1},grant:["m_smelting",2],cost:{Knowledge:()=>825e3,Graphene:()=>125e3},effect:F("tech_iridium_smelting_effect"),action(){return!!Os($(this)[0])}},adamantite_crates:{id:"tech-adamantite_crates",title:F("tech_adamantite_crates"),desc:F("tech_adamantite_crates_desc"),category:"storage",era:"solar",path:["truepath"],reqs:{container:5,titan:4},grant:["container",6],cost:{Knowledge:()=>525e3,Adamantite:()=>12500},effect:F("tech_adamantite_crates_effect"),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},bolognium_crates_tp:{id:"tech-bolognium_crates_tp",title:()=>F("tech_crates",[t.resource.Bolognium.name]),desc:()=>F("tech_crates",[t.resource.Bolognium.name]),category:"storage",era:"tauceti",path:["truepath"],reqs:{container:7,tauceti:4},grant:["container",8],cost:{Knowledge:()=>616e4,Bolognium:()=>75e4},effect:()=>F("tech_bolognium_crates_effect",[t.resource.Bolognium.name]),action(){return!!Os($(this)[0])}},adamantite_containers_tp:{id:"tech-adamantite_containers_tp",title:()=>F("tech_containers",[t.resource.Adamantite.name]),desc:()=>F("tech_adamantite_containers_desc",[t.resource.Adamantite.name]),category:"storage",era:"solar",path:["truepath"],reqs:{steel_container:4,titan:4},grant:["steel_container",5],cost:{Knowledge:()=>575e3,Adamantite:()=>17500},effect:()=>F("tech_adamantite_containers_effect",[t.resource.Adamantite.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},quantium_containers:{id:"tech-quantium_containers",title:()=>F("tech_containers",[t.resource.Quantium.name]),desc:()=>F("tech_containers",[t.resource.Quantium.name]),category:"storage",era:"solar",path:["truepath"],reqs:{steel_container:5,quantium:1},grant:["steel_container",6],cost:{Knowledge:()=>115e4,Quantium:()=>1e5},effect:()=>F("tech_quantium_containers_effect",[t.resource.Quantium.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},unobtainium_containers:{id:"tech-unobtainium_containers",title:()=>F("tech_containers",[t.resource.Unobtainium.name]),desc:()=>F("tech_containers",[t.resource.Unobtainium.name]),category:"storage",era:"tauceti",path:["truepath"],reqs:{steel_container:6,tau_red:7},grant:["steel_container",7],cost:{Knowledge:()=>725e4,Unobtainium:()=>7500},effect:()=>F("tech_bolognium_containers_effect",[t.resource.Unobtainium.name]),action(){return!!Os($(this)[0])}},reinforced_shelving:{id:"tech-reinforced_shelving",title:F("tech_reinforced_shelving"),desc:F("tech_reinforced_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{graphene:1,titan:5},grant:["shelving",1],cost:{Knowledge:()=>85e4,Adamantite:()=>35e4,Graphene:()=>25e4},effect:F("tech_reinforced_shelving_effect"),action(){return!!Os($(this)[0])}},garage_shelving:{id:"tech-garage_shelving",title:F("tech_garage_shelving"),desc:F("tech_garage_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{shelving:1,quantium:1},grant:["shelving",2],cost:{Knowledge:()=>125e4,Quantium:()=>75e3},effect:F("tech_garage_shelving_effect"),action(){return!!Os($(this)[0])}},warehouse_shelving:{id:"tech-warehouse_shelving",title:F("tech_warehouse_shelving"),desc:F("tech_warehouse_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{shelving:2,quantium:1,outer:4},grant:["shelving",3],cost:{Knowledge:()=>225e4,Quantium:()=>1e6,Cipher:()=>25e3},effect:F("tech_warehouse_shelving_effect"),action(){return!!Os($(this)[0])}},elerium_extraction:{id:"tech-elerium_extraction",title:F("tech_elerium_extraction"),desc:F("tech_elerium_extraction"),category:"mining",era:"solar",path:["truepath"],reqs:{kuiper:1},grant:["kuiper",2],cost:{Knowledge:()=>25e5,Orichalcum:()=>1e5,Cipher:()=>12e3},effect:()=>F("tech_elerium_extraction_effect"),action(){return!!Os($(this)[0])&&(t.space.elerium_mine={count:0,on:0},!0)}},orichalcum_panels_tp:{id:"tech-orichalcum_panels_tp",title:F("tech_orichalcum_panels"),desc:F("tech_orichalcum_panels"),category:"power_generation",era:"solar",path:["truepath"],reqs:{kuiper:1,swarm:5},grant:["swarm",6],cost:{Knowledge:()=>24e5,Orichalcum:()=>125e3},effect:()=>F("tech_orichalcum_panels_effect"),action(){return!!Os($(this)[0])}},shipyard:{id:"tech-shipyard",title:()=>F("tech_shipyard",[Xt().dwarf]),desc:()=>F("tech_shipyard",[Xt().dwarf]),category:"space_militarization",era:"solar",path:["truepath"],reqs:{outer:1,syndicate:1},grant:["shipyard",1],cost:{Knowledge:()=>42e4},effect:()=>F("tech_shipyard_effect",[Xt().dwarf]),action(){return!!Os($(this)[0])&&(t.space.shipyard={count:0,on:0,ships:[],expand:!0,sort:!0},ft(),!0)}},ship_lasers:{id:"tech-ship_lasers",title:F("tech_ship_lasers"),desc:F("tech_ship_lasers"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{military:7,syard_weapon:1},grant:["syard_weapon",2],cost:{Knowledge:()=>425e3,Elerium:()=>500},effect:F("tech_ship_lasers_effect"),action(){return!!Os($(this)[0])}},pulse_lasers:{id:"tech-pulse_lasers",title:F("tech_pulse_lasers"),desc:F("tech_pulse_lasers"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:2},grant:["syard_weapon",3],cost:{Knowledge:()=>5e5,Elerium:()=>750},effect:F("tech_pulse_lasers_effect"),action(){return!!Os($(this)[0])}},ship_plasma:{id:"tech-ship_plasma",title:F("tech_ship_plasma"),desc:F("tech_ship_plasma"),category:"space_militarization",era:"solar",reqs:{high_tech:13,syard_weapon:3},grant:["syard_weapon",4],path:["truepath"],cost:{Knowledge:()=>88e4,Elerium:()=>2500},effect:F("tech_ship_plasma_effect"),action(){return!!Os($(this)[0])}},ship_phaser:{id:"tech-ship_phaser",title:F("tech_ship_phaser"),desc:F("tech_ship_phaser"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:4,quantium:1},grant:["syard_weapon",5],cost:{Knowledge:()=>1225e3,Quantium:()=>75e3},effect:F("tech_ship_phaser_effect"),action(){return!!Os($(this)[0])}},ship_disruptor:{id:"tech-ship_disruptor",title:F("tech_ship_disruptor"),desc:F("tech_ship_disruptor"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:5,outer:4},grant:["syard_weapon",6],cost:{Knowledge:()=>2e6,Cipher:()=>25e3},effect:F("tech_ship_disruptor_effect"),action(){return!!Os($(this)[0])}},destroyer_ship:{id:"tech-destroyer_ship",title:F("tech_destroyer_ship"),desc:F("tech_destroyer_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:2},grant:["syard_class",3],cost:{Knowledge:()=>465e3},effect:F("tech_destroyer_ship_effect"),action(){return!!Os($(this)[0])}},cruiser_ship_tp:{id:"tech-cruiser_ship_tp",title:F("tech_cruiser_ship"),desc:F("tech_cruiser_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:3,titan:4},grant:["syard_class",4],cost:{Knowledge:()=>75e4,Adamantite:()=>5e4},effect:F("tech_cruiser_ship_tp"),action(){return!!Os($(this)[0])}},h_cruiser_ship:{id:"tech-h_cruiser_ship",title:F("tech_h_cruiser_ship"),desc:F("tech_h_cruiser_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:4,triton:1},grant:["syard_class",5],cost:{Knowledge:()=>15e5},effect:F("tech_h_cruiser_ship_effect"),action(){return!!Os($(this)[0])}},dreadnought_ship:{id:"tech-dreadnought_ship",title:F("tech_dreadnought_ship"),desc:F("tech_dreadnought_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:5,kuiper:1},grant:["syard_class",6],cost:{Knowledge:()=>25e5,Cipher:()=>1e4},effect:F("tech_dreadnought_ship_effect"),action(){return!!Os($(this)[0])}},pulse_engine:{id:"tech-pulse_engine",title:F("outer_shipyard_engine_pulse"),desc:F("outer_shipyard_engine_pulse"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:2,stanene:1},grant:["syard_engine",3],cost:{Knowledge:()=>555e3,Stanene:()=>25e4},effect:F("tech_pulse_engine_effect"),action(){return!!Os($(this)[0])}},photon_engine:{id:"tech-photon_engine",title:F("outer_shipyard_engine_photon"),desc:F("outer_shipyard_engine_photon"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:3,quantium:1},grant:["syard_engine",4],cost:{Knowledge:()=>115e4,Quantium:()=>5e4},effect:F("tech_photon_engine_effect"),action(){return!!Os($(this)[0])}},vacuum_drive:{id:"tech-vacuum_drive",title:F("outer_shipyard_engine_vacuum"),desc:F("outer_shipyard_engine_vacuum"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:4,outer:4},grant:["syard_engine",5],cost:{Knowledge:()=>185e4,Cipher:()=>1e4},effect:F("outer_shipyard_engine_vacuum_desc"),action(){return!!Os($(this)[0])}},ship_fusion:{id:"tech-ship_fusion",title:F("tech_fusion_generator"),desc:F("tech_fusion_generator"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_power:3,quantium:1},grant:["syard_power",4],cost:{Knowledge:()=>11e5,Quantium:()=>65e3},effect:F("tech_fusion_generator_effect"),action(){return!!Os($(this)[0])}},ship_elerium:{id:"tech-ship_elerium",title:F("tech_elerium_generator"),desc:F("tech_elerium_generator"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_power:4,outer:4},grant:["syard_power",5],cost:{Knowledge:()=>19e5,Cipher:()=>18e3},effect:F("tech_elerium_generator_effect"),action(){return!!Os($(this)[0])}},quantum_signatures:{id:"tech-quantum_signatures",title:F("tech_quantum_signatures"),desc:F("tech_quantum_signatures"),category:"progress",era:"solar",path:["truepath"],reqs:{quantium:1,syard_sensor:3},grant:["syard_sensor",4],cost:{Knowledge:()=>105e4,Quantium:()=>1e4},effect:F("tech_quantum_signatures_effect"),action(){return!!Os($(this)[0])}},interstellar_drive:{id:"tech-interstellar_drive",title:F("tech_interstellar_drive"),desc:F("tech_interstellar_drive"),category:"progress",era:"tauceti",path:["truepath"],reqs:{outer:8,titan_ai_core:2,syard_sensor:4},grant:["tauceti",1],cost:{Knowledge:()=>45e5,Quantium:()=>25e4,Cipher:()=>75e3},effect:F("tech_interstellar_drive_effect"),action(){return!!Os($(this)[0])}},alien_outpost:{id:"tech-alien_outpost",title:F("tech_alien_outpost"),desc:F("tech_alien_outpost"),category:"science",era:"tauceti",path:["truepath"],reqs:{tauceti:2,tau_home:3},grant:["tau_home",4],cost:{Knowledge:()=>5e6,Cipher:()=>1e5},effect:F("tech_alien_outpost_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.alien_outpost={count:1,on:0},t.tauceti.jump_gate={count:0},t.space.jump_gate={count:0},Di(F("tech_alien_outpost_msg"),"info",!1,["progress"]),!0)}},jumpgates:{id:"tech-jumpgates",title:F("tech_jumpgates"),desc:F("tech_jumpgates"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tauceti:2,tau_home:4},grant:["tauceti",3],cost:{Knowledge:()=>6e6},effect:F("tech_jumpgates_effect"),action(){return!!Os($(this)[0])}},system_survey:{id:"tech-system_survey",title:F("tech_system_survey"),desc:F("tech_system_survey"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tauceti:4,womling_tech:1},grant:["tauceti",5],cost:{Knowledge:()=>7e6},effect:F("tech_system_survey_effect"),action(){return!!Os($(this)[0])&&(t.settings.tau.roid=!0,t.settings.tau.gas=!0,t.tauceti.patrol_ship={count:0,on:0,support:0,s_max:0},!0)}},repository:{id:"tech-repository",title:F("tech_repository"),desc:F("tech_repository"),category:"storage",era:"tauceti",path:["truepath"],reqs:{tauceti:4,tau_home:4},grant:["tau_home",5],cost:{Knowledge:()=>65e5},effect:F("tech_repository_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.repository={count:0},!0)}},fusion_generator:{id:"tech-fusion_generator",title:F("tech_fusion_power"),desc:F("tech_fusion_power"),category:"power_generation",era:"tauceti",path:["truepath"],reqs:{tau_home:5},grant:["tau_home",6],cost:{Knowledge:()=>675e4},effect:F("tech_tau_fusion_power_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.fusion_generator={count:0,on:0},!0)}},tau_cultivation:{id:"tech-tau_cultivation",title:F("tech_tau_cultivation"),desc:F("tech_tau_cultivation"),category:"agriculture",era:"tauceti",path:["truepath"],reqs:{tau_home:6},grant:["tau_home",7],cost:{Knowledge:()=>69e5},effect:()=>F("tech_tau_cultivation_effect",[di[t.race.species].home]),action(){return!!Os($(this)[0])&&(t.tauceti.tau_farm={count:0,on:0},!0)}},tau_manufacturing:{id:"tech-tau_manufacturing",title:F("tech_tau_manufacturing"),desc:F("tech_tau_manufacturing"),category:"crafting",era:"tauceti",path:["truepath"],reqs:{tau_home:7},grant:["tau_home",8],cost:{Knowledge:()=>725e4},effect:()=>F("tech_tau_manufacturing_effect",[di[t.race.species].home]),action(){return!!Os($(this)[0])&&(t.tauceti.tau_factory={count:0,on:0},!0)}},weasels:{id:"tech-weasels",title:F("tech_weasels"),desc:F("tech_weasels"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:2},grant:["tau_red",3],cost:{Knowledge:()=>625e4},effect:()=>F("tech_weasels_effect",[F("tau_planet",[Xt().red])]),action(){return!!Os($(this)[0])&&(Di(F("tech_weasels_msg",[F("tau_planet",[Xt().red])]),"info",!1,["progress"]),!0)}},jeff:{id:"tech-jeff",title:F("tech_jeff"),desc:F("tech_jeff"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:3},grant:["tau_red",4],cost:{Knowledge:()=>638e4},effect:()=>F("tech_jeff_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_jeff_effect_msg",[]),"info",!1,["progress"]),!0)}},womling_fun:{id:"tech-womling_fun",title:F("tech_womling_fun"),desc:F("tech_womling_fun"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:5},grant:["tau_red",6],cost:{Knowledge:()=>665e4},effect:()=>F("tech_womling_fun_effect"),action(){return!!Os($(this)[0])}},womling_lab:{id:"tech-womling_lab",title:F("tech_womling_lab"),desc:F("tech_womling_lab"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:6},grant:["tau_red",7],cost:{Knowledge:()=>69e5},effect:()=>F("tech_womling_lab_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.womling_lab={count:0,on:0,scientist:0,tech:0},t.tech.womling_tech=0,!0)}},womling_mining:{id:"tech-womling_mining",title:F("tech_womling_mining"),desc:F("tech_womling_mining"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:1},grant:["womling_mining",1],cost:{Knowledge:()=>71e5},effect:()=>F("tech_womling_mining_effect"),action(){return!!Os($(this)[0])}},womling_firstaid:{id:"tech-womling_firstaid",title:F("tech_womling_firstaid"),desc:F("tech_womling_firstaid"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:2},grant:["womling_firstaid",1],cost:{Knowledge:()=>735e4},effect:()=>F("tech_womling_firstaid_effect"),action(){return!!Os($(this)[0])}},womling_logistics:{id:"tech-womling_logistics",title:F("tech_womling_logistics"),desc:F("tech_womling_logistics"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:3},grant:["womling_logistics",1],cost:{Knowledge:()=>765e4},effect:()=>F("tech_womling_logistics_effect",[F("tau_red_orbital_platform")]),action(){return!!Os($(this)[0])}},womling_repulser:{id:"tech-womling_repulser",title:F("tech_womling_repulser"),desc:F("tech_womling_repulser"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:4,womling_logistics:1},grant:["womling_logistics",2],cost:{Knowledge:()=>79e5},effect:()=>F("tech_womling_repulser_effect",[t.resource.Oil.name,F("tau_red_orbital_platform")]),action(){return!!Os($(this)[0])}},womling_farming:{id:"tech-womling_farming",title:F("tech_womling_farming"),desc:F("tech_womling_farming"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:5},grant:["womling_pop",1],cost:{Knowledge:()=>82e5},effect:()=>F("tech_womling_farming_effect"),action(){return!!Os($(this)[0])}},womling_housing:{id:"tech-womling_housing",title:F("tech_womling_housing"),desc:F("tech_womling_housing"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:6,womling_pop:1},grant:["womling_pop",2],cost:{Knowledge:()=>85e5},effect:()=>F("tech_womling_housing_effect"),action(){return!!Os($(this)[0])}},womling_support:{id:"tech-womling_support",title:F("tech_womling_support"),desc:F("tech_womling_support"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:7,tau_gas:4},grant:["womling_technicians",1],cost:{Knowledge:()=>885e4},effect:()=>`
    ${F("tech_womling_support_effect")}
    `,action(){return!!Os($(this)[0])&&(t.tauceti.womling_station={count:0,on:0},!0)}},womling_recycling:{id:"tech-womling_recycling",title:F("tech_womling_recycling"),desc:F("tech_womling_recycling"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:8},grant:["womling_recycling",1],cost:{Knowledge:()=>955e4},effect:()=>`
    ${F("tech_womling_recycling_effect")}
    `,action(){return!!Os($(this)[0])}},asteroid_analysis:{id:"tech-asteroid_analysis",title:F("tech_asteroid_analysis"),desc:F("tech_asteroid_analysis"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_roid:1},grant:["tau_roid",2],cost:{Knowledge:()=>735e4},effect:()=>F("tech_asteroid_analysis_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_asteroid_analysis_msg"),"info",!1,["progress"]),!0)}},shark_repellent:{id:"tech-shark_repellent",title:F("tech_shark_repellent"),desc:F("tech_shark_repellent"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_roid:2},grant:["tau_roid",3],cost:{Knowledge:()=>74e5},effect:()=>F("tech_shark_repellent_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_shark_repellent_msg"),"info",!1,["progress"]),!0)}},belt_mining:{id:"tech-belt_mining",title:F("tech_belt_mining"),desc:F("tech_belt_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{tau_gas:3,tau_roid:3},grant:["tau_gas",4],cost:{Knowledge:()=>765e4},effect:()=>F("tech_belt_mining_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.ore_refinery={count:0,on:0,max:0,fill:0},t.tauceti.mining_ship={count:0,on:0,common:50,uncommon:50,rare:50},!0)}},adv_belt_mining:{id:"tech-adv_belt_mining",title:F("tech_adv_belt_mining"),desc:F("tech_adv_belt_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{tau_roid:4},grant:["tau_roid",5],cost:{Knowledge:()=>79e5},effect:()=>F("tech_adv_belt_mining_effect"),action(){return!!Os($(this)[0])}},space_whaling:{id:"tech-space_whaling",title:F("tech_space_whaling"),desc:F("tech_space_whaling"),category:"whaling",era:"tauceti",path:["truepath"],reqs:{tau_gas:3,tau_roid:3},grant:["tau_whale",1],cost:{Knowledge:()=>75e5},effect:()=>F("tech_space_whaling_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.whaling_station={count:0,on:0,max:0,fill:0},t.tauceti.whaling_ship={count:0,on:0},!0)}},infectious_disease_lab:{id:"tech-infectious_disease_lab",title:()=>F(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),desc:()=>F(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),category:"science",era:"tauceti",path:["truepath"],reqs:{plague:2},grant:["disease",1],cost:{Knowledge:()=>825e4},effect:()=>F(t.race.artifical?"tech_infectious_disease_lab_effect_s":"tech_infectious_disease_lab_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.infectious_disease_lab={count:0,on:0,cure:0},!0)}},isolation_protocol:{id:"tech-isolation_protocol",title:F("tech_isolation_protocol"),desc:F("tech_isolation_protocol"),category:"plague",era:"tauceti",path:["truepath"],reqs:{disease:2},grant:["disease",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>85e5},effect:()=>`
    ${F("tech_isolation_protocol_effect",[F("tab_tauceti")])}
    ${F("tech_isolation_protocol_warning")}
    `,action(){return!!Os($(this)[0])&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),t.tech.isolation=1,function(){let e={city:{},space:{},ships:[]};e.ships=[...t.space.shipyard.ships],t.space.shipyard.ships=[],t.settings.spaceTabs=6,t.settings.showSpace=!1,t.settings.showOuter=!1,t.settings.showCity=!1,t.settings.showShipYard=!1,5===t.settings.govTabs&&(t.settings.govTabs=0),dt(),rc($("#shipList")),Object.keys(Qr.city).forEach((function(a){t.city.hasOwnProperty(a)&&t.city[a].hasOwnProperty("count")&&(t.race.hooved&&Qr.city[a].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Qr.city[a].cost.Horseshoe()*t.city[a].count),e.city[a]={c:t.city[a].count},t.city[a].count=0,t.city[a].hasOwnProperty("on")&&(e.city[a].o=t.city[a].on,t.city[a].on=0))})),["spc_home","spc_moon","spc_red","spc_hell","spc_sun","spc_gas","spc_gas_moon","spc_belt","spc_dwarf","spc_titan","spc_enceladus","spc_triton","spc_kuiper","spc_eris"].forEach((function(a){Object.keys(Qr.space[a]).forEach((function(r){t.space.hasOwnProperty(r)&&t.space[r].hasOwnProperty("count")&&(t.race.hooved&&Qr.space[a][r].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Qr.space[a][r].cost.Horseshoe()*t.space[r].count),e.space[r]={c:t.space[r].count},t.space[r].count=0,t.space[r].hasOwnProperty("on")&&(e.space[r].o=t.space[r].on,t.space[r].on=0))}))})),t.race.hooved&&t.race.shoecnt<5&&(t.race.shoecnt=5),t.resource.Zen.display&&(t.resource.Zen.display=!1),t.resource.Slave.display&&(t.resource.Slave.display=!1,t.resource.Slave.amount=0,D("slave")),t.race.deconstructor&&Vs.forEach((function(e){t.city.nanite_factory[e]=0})),Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),Object.keys(ca).forEach((function(e){["professor","scientist","pit_miner","cement_worker","craftsman"].includes(e)||(t.civic[e].workers=0,t.civic[e].assigned=0)})),["forager","farmer","lumberjack","quarry_worker","miner","coal_miner","priest","colonist","titan_colonist","space_miner"].forEach((function(e){t.civic[e].display=!1})),t.civic.hunter.display?t.civic.d_job="hunter":t.civic.d_job="unemployed",t.arpa.sequence&&(t.arpa.sequence.on=!1,t.arpa.sequence.boost=!1);for(let e of Object.values(t.race.purgatory.city))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);for(let e of Object.values(t.race.purgatory.space))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);if(t.queue.hasOwnProperty("queue"))for(let e=t.queue.queue.length-1;e>=0;e--){let a=t.queue.queue[e];"city"!==a.action&&"space"!==a.action&&"starDock"!==a.action||t.queue.queue.splice(e,1)}t.tech.magic&&t.tech.magic>=2&&(t.tauceti.pylon={count:0},t.race.casting&&Object.keys(t.race.casting).forEach((function(e){t.race.casting[0]=0}))),t.tauceti.tauceti_casino={count:0,on:0},t.tauceti.tau_housing={count:0};let a=c.colony*Ze.tau_home.colony.citizens();t.resource[t.race.species].amount>a&&(t.resource[t.race.species].amount=a),D("spy"),D("spyop"),rc($("#infoTimer")),t.race.inactive=e}(),!0)}},focus_cure:{id:"tech-focus_cure",title:F("tech_focus_cure"),desc:F("tech_focus_cure"),category:"plague",era:"tauceti",path:["truepath"],reqs:{disease:2},grant:["disease",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>85e5},effect:()=>`
    ${F("tech_focus_cure_effect",[F("tab_tauceti")])}
    ${F("tech_focus_cure_warning")}
    `,action(){return!!Os($(this)[0])&&(t.tech.focus_cure=1,!0)}},decode_virus:{id:"tech-decode_virus",title:F("tech_decode_virus"),desc:F("tech_decode_virus"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:1},grant:["focus_cure",2],cost:{Knowledge:()=>9e6},effect:()=>`
    ${F(t.race.artifical?"tech_decode_virus_effect_s":"tech_decode_virus_effect")}
    `,action(){return!!Os($(this)[0])&&(t.race.artifical?Di(F("tech_decode_virus_msg1s",[Qr.tauceti.tau_home.infectious_disease_lab.title()]),"info",!1,["progress"]):Di(F("tech_decode_virus_msg1",[Qr.tauceti.tau_home.infectious_disease_lab.title()]),"info",!1,["progress"]),!0)}},vaccine_campaign:{id:"tech-vaccine_campaign",title:F("tech_vaccine_campaign"),desc:F("tech_vaccine_campaign"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:3},grant:["focus_cure",4],cost:{Knowledge:()=>925e4},effect:()=>`
    ${F("tech_vaccine_campaign_effect",[t.race.artifical?Qr.city.boot_camp.title():Qr.city.hospital.title])}
    `,action(){return!!Os($(this)[0])&&(t.race.vax=0,!0)}},vax_strat1:{id:"tech-vax_strat1",title:F("tech_vax_strat1"),desc:F("tech_vax_strat1"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
    ${F("tech_vax_strat1_effect")}
    ${F("tech_vax_warning")}
    `,action(){return!!Os($(this)[0])&&(t.tech.vax_p=1,Di(F("tech_vax_strat1_msg"),"info",!1,["progress"]),!0)}},vax_strat2:{id:"tech-vax_strat2",title:F("tech_vax_strat2"),desc:F("tech_vax_strat2"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
    ${F("tech_vax_strat2_effect")}
    ${F("tech_vax_warning")}
    `,action(){return!!Os($(this)[0])&&(t.tech.vax_f=1,Di(F("tech_vax_strat2_msg"),"info",!1,["progress"]),!0)}},vax_strat3:{id:"tech-vax_strat3",title:F("tech_vax_strat3"),desc:F("tech_vax_strat3"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
    ${F("tech_vax_strat3_effect")}
    ${F("tech_vax_warning")}
    `,action(){return!!Os($(this)[0])&&(t.tech.vax_s=1,Di(F("tech_vax_strat3_msg"),"info",!1,["progress"]),!0)}},vax_strat4:{id:"tech-vax_strat4",title:F("tech_vax_strat4"),desc:F("tech_vax_strat4"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
    ${F("tech_vax_strat4_effect")}
    ${F("tech_vax_warning")}
    `,action(){return!!Os($(this)[0])&&(t.tech.vax_c=1,Di(F("tech_vax_strat4_msg"),"info",!1,["progress"]),!0)}},cloning:{id:"tech-cloning",title:F("tech_cloning"),desc:F("tech_cloning"),category:"housing",era:"tauceti",path:["truepath"],reqs:{focus_cure:7},grant:["cloning",1],cost:{Knowledge:()=>975e4},effect:()=>`
    ${F(t.race.artifical?"tech_cloning_effect_s":"tech_cloning_effect")}
    `,action(){return!!Os($(this)[0])&&(t.tauceti.cloning_facility={count:0,on:0},!0)}},clone_degradation:{id:"tech-clone_degradation",title:F("tech_clone_degradation"),desc:F("tech_clone_degradation"),category:"progress",era:"tauceti",path:["truepath"],reqs:{cloning:1},grant:["cloning",2],cost:{Knowledge:()=>1e7},effect:()=>`
    ${F("tech_clone_degradation_effect")}
    `,action(){return!!Os($(this)[0])&&(Di(F("tech_clone_degradation_msg"),"info",!1,["progress"]),!0)}},digital_paradise:{id:"tech-digital_paradise",title:F("tech_digital_paradise"),desc:F("tech_digital_paradise"),category:"progress",era:"tauceti",path:["truepath"],reqs:{cloning:2},grant:["matrix",1],cost:{Knowledge:()=>105e5,Cipher:()=>2e5},effect:()=>`
    ${F("tech_digital_paradise_effect")}
    `,action(){return!!Os($(this)[0])}},ringworld:{id:"tech-ringworld",title:F("tech_ringworld"),desc:F("tech_ringworld"),category:"progress",era:"tauceti",path:["truepath"],reqs:{matrix:1},grant:["matrix",2],cost:{Money:()=>3e9,Knowledge:()=>11e6},effect:()=>`
    ${F("tech_ringworld_effect")}
    `,action(){return!!Os($(this)[0])&&(t.settings.tau.star=!0,t.tauceti.ringworld={count:0},!0)}},iso_gambling:{id:"tech-iso_gambling",title:F("tech_iso_gambling"),desc:F("tech_iso_gambling"),category:"banking",era:"tauceti",reqs:{gambling:4,isolation:1},grant:["iso_gambling",1],cost:{Knowledge:()=>865e4},effect:F("tech_iso_gambling_effect",[5]),action(){return!!Os($(this)[0])}},outpost_boost:{id:"tech-outpost_boost",title:()=>F("tech_outpost_boost"),desc:()=>F("tech_outpost_boost"),category:"special",era:"tauceti",path:["truepath"],reqs:{tau_home:4,isolation:1},grant:["outpost_boost",1],cost:{Knowledge:()=>89e5},effect:()=>F("tech_outpost_boost_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_outpost_boost_flair")},cultural_center:{id:"tech-cultural_center",title:F("tech_cultural_center"),desc:F("tech_cultural_center"),category:"banking",era:"tauceti",path:["truepath"],reqs:{iso_gambling:1,isolation:1},grant:["tau_culture",1],cost:{Knowledge:()=>885e4},effect:F("tech_cultural_center_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.tau_cultural_center={count:0,on:0},!0)},flair:()=>F("tech_cultural_center_flair")},outer_tau_survey:{id:"tech-outer_tau_survey",title:F("tech_outer_tau_survey"),desc:F("tech_outer_tau_survey"),category:"progress",era:"tauceti",path:["truepath"],reqs:{outpost_boost:1,plague:5},grant:["tau_gas2",1],cost:{Knowledge:()=>91e5,Helium_3:()=>+Yt(5e6).toFixed(0)},effect:F("tech_outer_tau_survey_effect"),action(){return!!Os($(this)[0])&&(t.settings.tau.gas2=!0,!0)}},alien_research:{id:"tech-alien_research",title:F("tech_alien_research"),desc:F("tech_alien_research"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_gas2:5},grant:["tau_gas2",6],cost:{Knowledge:()=>935e4},effect:F("tech_alien_research_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.alien_space_station.decrypted=0,t.tauceti.alien_space_station.focus=95,Di(F("tech_alien_research_msg"),"info",!1,["progress"]),!0)}},womling_gene_therapy:{id:"tech-womling_gene_therapy",title:F("tech_womling_gene_therapy"),desc:F("tech_womling_gene_therapy"),category:"womling",era:"tauceti",path:["truepath"],reqs:{alien_data:1},grant:["womling_gene",1],cost:{Knowledge:()=>952e4},effect:F("tech_womling_gene_therapy_effect"),action(){return!!Os($(this)[0])}},food_culture:{id:"tech-food_culture",title:()=>F("tech_food_culture",[F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),desc:()=>F("tech_food_culture",[F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),category:"banking",era:"tauceti",path:["truepath"],reqs:{alien_data:2,tau_culture:1},grant:["tau_culture",2],cost:{Knowledge:()=>941e4},effect:()=>F("tech_food_culture_effect",[F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`),F("tech_cultural_center")]),action(){return!!Os($(this)[0])}},advanced_refinery:{id:"tech-advanced_refinery",title:F("tech_advanced_refinery"),desc:F("tech_advanced_refinery"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:3},grant:["tau_ore_mining",1],cost:{Knowledge:()=>968e4},effect:()=>F("tech_advanced_refinery_effect"),action(){return!!Os($(this)[0])}},advanced_pit_mining:{id:"tech-advanced_pit_mining",title:F("tech_advanced_pit_mining"),desc:F("tech_advanced_pit_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:3},grant:["tau_pit_mining",1],cost:{Knowledge:()=>972e4},effect:()=>F("tech_advanced_pit_mining_effect"),action(){return!!Os($(this)[0])}},useless_junk:{id:"tech-useless_junk",title:F("tech_useless_junk"),desc:F("tech_useless_junk"),category:"womling",era:"tauceti",path:["truepath"],reqs:{alien_data:4},grant:["tau_junksale",1],cost:{Knowledge:()=>955e4},effect:()=>F("tech_useless_junk_effect",[F(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`),F("tau_red_womlings")]),action(){return!!Os($(this)[0])}},advanced_asteroid_mining:{id:"tech-advanced_asteroid_mining",title:F("tech_advanced_asteroid_mining"),desc:F("tech_advanced_asteroid_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:5,tau_ore_mining:1},grant:["tau_ore_mining",2],cost:{Knowledge:()=>975e4},effect:()=>F("tech_advanced_asteroid_mining_effect",[F("tau_roid_mining_ship")]),action(){return!!Os($(this)[0])}},advanced_material_synthesis:{id:"tech-advanced_material_synthesis",title:F("tech_advanced_material_synthesis"),desc:F("tech_advanced_material_synthesis"),category:"crafting",era:"tauceti",path:["truepath"],reqs:{alien_data:5,disease:1},grant:["alien_crafting",1],cost:{Knowledge:()=>988e4},effect:()=>F("tech_advanced_material_synthesis_effect",[t.resource.Quantium.name]),action(){return!!Os($(this)[0])}},matrioshka_brain:{id:"tech-matrioshka_brain",title:F("tech_matrioshka_brain"),desc:F("tech_matrioshka_brain"),category:"progress",era:"tauceti",path:["truepath"],reqs:{alien_data:6,tau_gas2:6},grant:["tau_gas2",7],not_trait:["lone_survivor"],cost:{Knowledge:()=>1e7},effect:()=>F("tech_matrioshka_brain_effect",[Qr.tauceti.tau_gas2.info.name()]),action(){return!!Os($(this)[0])&&(t.tauceti.matrioshka_brain={count:0},!0)}},ignition_device:{id:"tech-ignition_device",title:F("tech_ignition_device"),desc:F("tech_ignition_device"),category:"progress",era:"tauceti",path:["truepath"],reqs:{alien_data:6,tau_gas2:7},grant:["tau_gas2",8],cost:{Knowledge:()=>105e5},effect:()=>F("tech_ignition_device_effect",[Qr.tauceti.tau_gas2.info.name()]),action(){return!!Os($(this)[0])&&(t.tauceti.ignition_device={count:0},t.tauceti.hasOwnProperty("matrioshka_brain")||(t.tauceti.matrioshka_brain={count:0}),!0)}},replicator:{id:"tech-replicator",title:()=>"antimatter"===t.race.universe?F("tech_antireplicator"):F("tech_replicator"),desc:()=>"antimatter"===t.race.universe?F("tech_antireplicator"):F("tech_replicator"),category:"special",era:"tauceti",path:["truepath"],reqs:{tau_home:4,isolation:1},trait:["lone_survivor"],grant:["replicator",1],cost:{Knowledge:()=>625e4},effect:()=>"antimatter"===t.race.universe?F("tech_antireplicator_effect"):F("tech_replicator_effect"),action(){return!!Os($(this)[0])&&(t.race.replicator={res:"Unobtainium",pow:1},!0)}},womling_unlock:{id:"tech-womling_unlock",title:F("tech_womling_unlock"),desc:F("tech_womling_unlock"),category:"womling",era:"tauceti",path:["truepath"],reqs:{replicator:1},trait:["lone_survivor"],grant:["tau_red",4],cost:{Knowledge:()=>65e5},effect:()=>F("tech_womling_unlock_effect",[F("tau_planet",[Xt().red])]),action(){return!!Os($(this)[0])&&(t.settings.tau.red=!0,t.tauceti.orbital_platform.count=1,t.tauceti.orbital_platform.on=1,!0)}},garden_of_eden:{id:"tech-garden_of_eden",title:F("tech_garden_of_eden"),desc:F("tech_garden_of_eden"),category:"special",era:"tauceti",path:["truepath"],reqs:{eden:1},grant:["eden",2],cost:{Knowledge:()=>1e7},effect:()=>F("tech_garden_of_eden_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.goe_facility={count:0},!0)}}};function Hr(){t.tech.world_control=1,rc($("#garrison")),rc($("#c_garrison")),fe($("#garrison"),!0),fe($("#c_garrison"),!1);for(let e=0;e<3;e++){if(t.civic.foreign[`gov${e}`].occ){let a=la("federation"===t.civic.govern.type?15:20);t.civic.garrison.max+=a,t.civic.garrison.workers+=a,t.civic.foreign[`gov${e}`].occ=!1}t.civic.foreign[`gov${e}`].buy=!1,t.civic.foreign[`gov${e}`].anx=!1,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none"}D("spy"),D("spyop")}function Ur(e,a){let r=["swiss","gouda","cheddar","brie","feta","ricotta","goat","mascarpone","bleu","colby_jack","camembert","gorgonzola","mozzarella","roquefort","provolone","monterey_jack","muenster","cambozola","jarlsberg","bocconcini","cantal","emmental","havarti","burrata","cottage","asiago","wensleydale","pepper_jack","queso_blanco","pecorino","raclette","fontina","reblochon","port_salut","brillat_savarin","cream","stilton","taleggio","manchego","edam","gruyeye","parmigiano_reggiano","epoisses","comte","caciocavallo","teleme","grana_padano","chaumes","morbier","halloumi","lancashire","bleu_de_gex","fourme_d_ambert","fromage_blanc","red_leicester","bleu_d_auvergne","pont_l_eveque","jl_grubb","castello_blue","wagasi","ayibe","caravane","limburger","herve","kashkaval","sirene","paski_sir","akkawi","olomoucke_syrecky","anari","danbo","hermelín","trappista","stinking_bishop","banbury","sulguni","hofoingi","urda","golka","rokpol","telemea","bryndza","parenica","kackavalj","liptauer","greve","korbaciky","herrgardsost","vasterbottensost","mish","anejo","quesillo","nacho","reggianito","catupiry","queso_paipa","canastra","port_wine","cados","brie_de_meaux"];if(a)return r;let s=(t.stats.hasOwnProperty("reset")?t.stats.reset:0)%r.length;return e?F(`cheese_${r[s]}`):F("tech_swiss_bank",[F(`cheese_${r[s]}`)])}const Wr={standard:["primitive","discovery","civilized","industrialized","globalized","early_space","deep_space","interstellar","intergalactic","dimensional"],truepath:["primitive","discovery","civilized","industrialized","globalized","early_space","deep_space","solar","tauceti"]},Qr={evolution:{rna:{id:"evolution-rna",title:F("resource_RNA_name"),desc:()=>F("evo_rna",[t.race.rapid_mutation?2:1]),condition:()=>t.resource.hasOwnProperty("RNA")&&t.resource.RNA.display&&!t.race.evoFinalMenu,action:()=>(t.resource.RNA.amount0},dna:{id:"evolution-dna",title:F("evo_dna_title"),desc:F("evo_dna_desc"),condition:()=>t.resource.hasOwnProperty("DNA")&&t.resource.DNA.display&&!t.race.evoFinalMenu,cost:{RNA:()=>2},action:()=>(t.resource.RNA.amount>=2&&t.resource.DNA.amount0},membrane:{id:"evolution-membrane",title:F("evo_membrane_title"),desc:F("evo_membrane_desc"),condition:()=>t.evolution.hasOwnProperty("membrane")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("membrane",2,2,e)},effect:()=>F("evo_membrane_effect",[t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5]),action(){return!!Os($(this)[0])&&(t.resource.RNA.max+=t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5,t.evolution.membrane.count++,!0)}},organelles:{id:"evolution-organelles",title:F("evo_organelles_title"),desc:F("evo_organelles_desc"),condition:()=>t.evolution.hasOwnProperty("organelles")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("organelles",12,8,e),DNA:e=>is("organelles",4,4,e)},effect(){let e=t.race.rapid_mutation?2:1;return t.evolution.sexual_reproduction&&t.evolution.sexual_reproduction.count>0&&e++,F("evo_organelles_effect",[e])},action(){return!!Os($(this)[0])&&(t.evolution.organelles.count++,!0)}},nucleus:{id:"evolution-nucleus",title:F("evo_nucleus_title"),desc:F("evo_nucleus_desc"),condition:()=>t.evolution.hasOwnProperty("nucleus")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("nucleus",38,t.tech.evo&&t.tech.evo>=4?16:32,e),DNA:e=>is("nucleus",18,t.tech.evo&&t.tech.evo>=4?12:16,e)},effect:()=>F("evo_nucleus_effect",[t.evolution.bilateral_symmetry&&t.evolution.bilateral_symmetry.count>0||t.evolution.poikilohydric&&t.evolution.poikilohydric.count>0||t.evolution.spores&&t.evolution.spores.count>0?2:1]),action(){return!!Os($(this)[0])&&(t.evolution.nucleus.count++,!0)}},eukaryotic_cell:{id:"evolution-eukaryotic_cell",title:F("evo_eukaryotic_title"),desc:F("evo_eukaryotic_desc"),condition:()=>t.evolution.hasOwnProperty("eukaryotic_cell")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("eukaryotic_cell",20,20,e),DNA:e=>is("eukaryotic_cell",40,12,e)},effect:()=>F("evo_eukaryotic_effect",[t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10]),action(){return!!Os($(this)[0])&&(t.evolution.eukaryotic_cell.count++,t.resource.DNA.max+=t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10,!0)}},mitochondria:{id:"evolution-mitochondria",title:F("evo_mitochondria_title"),desc:F("evo_mitochondria_desc"),condition:()=>t.evolution.hasOwnProperty("mitochondria")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("mitochondria",75,50,e),DNA:e=>is("mitochondria",65,35,e)},effect:F("evo_mitochondria_effect"),action(){return!!Os($(this)[0])&&(t.evolution.mitochondria.count++,!0)}},sexual_reproduction:{id:"evolution-sexual_reproduction",title:F("evo_sexual_reproduction_title"),desc:F("evo_sexual_reproduction_desc"),reqs:{evo:1},grant:["evo",2],condition:()=>t.tech.evo&&1===t.tech.evo,cost:{DNA:()=>150},effect:F("evo_sexual_reproduction_effect"),action(){return!!Os($(this)[0])&&(t.evolution.final=20,!0)},queue_complete:()=>t.tech.evo&&1===t.tech.evo?1:0},phagocytosis:{id:"evolution-phagocytosis",title:F("evo_phagocytosis_title"),desc:F("evo_phagocytosis_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>t.tech.evo&&2===t.tech.evo,cost:{DNA:()=>175},effect:F("evo_phagocytosis_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_animal=1,t.evolution.final=40,!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0},chloroplasts:{id:"evolution-chloroplasts",title:()=>t.evolution.gselect?F("genelab_genus_plant"):F("evo_chloroplasts_title"),desc:F("evo_chloroplasts_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>Jr(2),cost:{DNA:()=>175},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_chloroplasts_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_chloroplasts_effect"),action(){return!!Os($(this)[0])&&(t.evolution.gselect?(t.tech.evo=7,t.tech.evo_plant=2,t.evolution.final=100):(t.tech.evo_plant=1,t.evolution.final=40),!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Pc("genus_plant")},chitin:{id:"evolution-chitin",title:()=>t.evolution.gselect?F("genelab_genus_fungi"):F("evo_chitin_title"),desc:F("evo_chitin_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>Jr(2),cost:{DNA:()=>175},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_chitin_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_chitin_effect"),action(){return!!Os($(this)[0])&&(t.evolution.gselect?(t.tech.evo=7,t.tech.evo_fungi=2,t.evolution.final=100):(t.tech.evo_fungi=1,t.evolution.final=40),!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Pc("genus_fungi")},exterminate:{id:"evolution-exterminate",title:()=>t.evolution.gselect?F("genelab_genus_synthetic"):F("evo_exterminate_title"),desc:F("evo_exterminate_desc"),reqs:{evo:2},grant:["evo",7],condition:()=>Jr(2)&&t.stats.achieve.obsolete&&t.stats.achieve.obsolete.l>=5,cost:{DNA:()=>200},effect:()=>F("evo_exterminate_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_synthetic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Pc("genus_synthetic")},multicellular:{id:"evolution-multicellular",title:F("evo_multicellular_title"),desc:F("evo_multicellular_desc"),reqs:{evo:3},grant:["evo",4],condition:()=>t.tech.evo&&3===t.tech.evo,cost:{DNA:()=>200},effect:F("evo_multicellular_effect"),action(){return!!Os($(this)[0])&&(t.evolution.final=60,!0)},queue_complete:()=>t.tech.evo&&3===t.tech.evo?1:0},spores:{id:"evolution-spores",title:F("evo_spores_title"),desc:F("evo_spores_desc"),reqs:{evo:4,evo_fungi:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:F("evo_nucleus_boost"),action(){return!!Os($(this)[0])&&(t.evolution.final=80,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},poikilohydric:{id:"evolution-poikilohydric",title:F("evo_poikilohydric_title"),desc:F("evo_poikilohydric_desc"),reqs:{evo:4,evo_plant:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:F("evo_nucleus_boost"),action(){return!!Os($(this)[0])&&(t.evolution.final=80,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},bilateral_symmetry:{id:"evolution-bilateral_symmetry",title:F("evo_bilateral_symmetry_title"),desc:F("evo_bilateral_symmetry_desc"),reqs:{evo:4,evo_animal:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:F("evo_nucleus_boost"),action(){return!!Os($(this)[0])&&(t.evolution.final=80,t.tech.evo_insectoid=1,t.tech.evo_mammals=1,t.tech.evo_eggshell=1,t.tech.evo_eldritch=1,t.tech.evo_aquatic=1,t.tech.evo_fey=1,t.tech.evo_sand=1,t.tech.evo_heat=1,t.tech.evo_polar=1,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},bryophyte:{id:"evolution-bryophyte",title:F("evo_bryophyte_title"),desc:F("evo_bryophyte_desc"),reqs:{evo:5},grant:["evo",7],condition:()=>!(!t.tech.evo_plant&&!t.tech.evo_fungi)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_bryophyte_effect"),action(){return!!Os($(this)[0])&&(t.evolution.final=100,t.tech.evo_fungi&&(t.tech.evo_fungi=2),t.tech.evo_plant&&(t.tech.evo_plant=2),!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},athropods:{id:"evolution-athropods",title:F("evo_athropods_title"),desc:F("evo_athropods_desc"),reqs:{evo:5,evo_insectoid:1},grant:["evo",7],condition:()=>Jr(5),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_athropods_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_athropods_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_insectoid=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_insectoid")},mammals:{id:"evolution-mammals",title:F("evo_mammals_title"),desc:F("evo_mammals_desc"),reqs:{evo:5,evo_mammals:1},grant:["evo",6],condition:()=>t.tech.evo&&5===t.tech.evo,cost:{DNA:()=>245},effect:F("evo_mammals_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_humanoid=1,t.tech.evo_giant=1,t.tech.evo_small=1,t.tech.evo_animalism=1,t.tech.evo_demonic=1,t.tech.evo_angelic=1,t.evolution.final=90,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},humanoid:{id:"evolution-humanoid",title:F("evo_humanoid_title"),desc:F("evo_humanoid_desc"),reqs:{evo:6,evo_humanoid:1},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_humanoid_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_humanoid_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_humanoid=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_humanoid")},gigantism:{id:"evolution-gigantism",title:F("evo_gigantism_title"),desc:F("evo_gigantism_desc"),reqs:{evo:6,evo_giant:1},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_gigantism_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_gigantism_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_giant=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_giant")},dwarfism:{id:"evolution-dwarfism",title:F("evo_dwarfism_title"),desc:F("evo_dwarfism_desc"),reqs:{evo:6,evo_small:1},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_dwarfism_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_dwarfism_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_small=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_small")},animalism:{id:"evolution-animalism",title:F("evo_animalism_title"),desc:F("evo_animalism_desc"),reqs:{evo:6,evo_animalism:1},grant:["evo",7],condition:()=>Jr(6)&&t.tech.evo_animalism&&1===t.tech.evo_animalism,cost:{DNA:()=>250},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_animalism_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_animalism_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_animalism=2,t.evolution.final=95,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo&&1===t.tech.evo_animalism?1:0},carnivore:{id:"evolution-carnivore",title:F("evo_carnivore_title"),desc:F("evo_carnivore_desc"),reqs:{evo_animalism:2},grant:["evo_animalism",3],condition:()=>Jr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_carnivore_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_carnivore_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo=7,t.tech.evo_carnivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Pc("genus_carnivore")},herbivore:{id:"evolution-herbivore",title:F("evo_herbivore_title"),desc:F("evo_herbivore_desc"),reqs:{evo_animalism:2},grant:["evo_animalism",3],condition:()=>Jr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_herbivore_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_herbivore_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo=7,t.tech.evo_herbivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Pc("genus_herbivore")},omnivore:{id:"evolution-omnivore",title:F("evo_omnivore_title"),desc:F("evo_omnivore_desc"),reqs:{evo_animalism:2,locked:1},grant:["evo_animalism",3],condition:()=>Jr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},wiki:!1,effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_omnivore_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_omnivore_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_omnivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Pc("genus_omnivore")},celestial:{id:"evolution-celestial",title:F("evo_celestial_title"),desc:F("evo_celestial_desc"),reqs:{evo:6,evo_angelic:1},grant:["evo",7],condition:()=>!!("eden"===t.city.biome||t.blood.unbound&&t.blood.unbound>=3)&&Jr(6),cost:{DNA:()=>260},effect:()=>F("evo_celestial_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_angelic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_angelic")},demonic:{id:"evolution-demonic",title:F("evo_demonic_title"),desc:F("evo_demonic_desc"),reqs:{evo:6,evo_demonic:1},grant:["evo",7],condition:()=>!!("hellscape"===t.city.biome||t.blood.unbound&&t.blood.unbound>=3)&&Jr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"===t.race.universe?`
    ${F("evo_demonic_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_demonic_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_demonic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_demonic")},eldritch:{id:"evolution-eldritch",title:F("evo_eldritch_title"),desc:F("evo_eldritch_desc"),reqs:{evo:5,evo_eldritch:1},grant:["evo",7],condition:()=>!(!t.stats.achieve.nightmare||!t.stats.achieve.nightmare.mg)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_eldritch_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_eldritch=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_eldritch")},aquatic:{id:"evolution-aquatic",title:F("evo_aquatic_title"),desc:F("evo_aquatic_desc"),reqs:{evo:5,evo_aquatic:1},grant:["evo",7],condition:()=>!(!["oceanic","swamp"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_aquatic_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_aquatic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_aquatic")},fey:{id:"evolution-fey",title:F("evo_fey_title"),desc:F("evo_fey_desc"),reqs:{evo:5,evo_fey:1},grant:["evo",7],condition:()=>!(!["forest","swamp","taiga"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_fey_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_fey=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_fey")},heat:{id:"evolution-heat",title:F("evo_heat_title"),desc:F("evo_heat_desc"),reqs:{evo:5,evo_heat:1},grant:["evo",7],condition:()=>!(!["volcanic","ashland"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_heat_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_heat=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_heat")},polar:{id:"evolution-polar",title:F("evo_polar_title"),desc:F("evo_polar_desc"),reqs:{evo:5,evo_polar:1},grant:["evo",7],condition:()=>!(!["tundra","taiga"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_polar_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_polar=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_polar")},sand:{id:"evolution-sand",title:F("evo_sand_title"),desc:F("evo_sand_desc"),reqs:{evo:5,evo_sand:1},grant:["evo",7],condition:()=>!(!["desert","ashland"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_sand_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_sand=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_sand")},eggshell:{id:"evolution-eggshell",title:F("evo_eggshell_title"),desc:F("evo_eggshell_desc"),reqs:{evo:5,evo_eggshell:1},grant:["evo",6],condition:()=>t.tech.evo&&5===t.tech.evo&&!t.evolution.gselect,cost:{DNA:()=>245},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_eggshell_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_eggshell_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_eggshell=2,t.evolution.final=90,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},endothermic:{id:"evolution-endothermic",title:()=>t.evolution.gselect?F("genelab_genus_avian"):F("evo_endothermic_title"),desc:F("evo_endothermic_desc"),reqs:{evo:6,evo_eggshell:2},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:F("evo_endothermic_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_avian=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_avian")},ectothermic:{id:"evolution-ectothermic",title:()=>t.evolution.gselect?F("genelab_genus_reptilian"):F("evo_ectothermic_title"),desc:F("evo_ectothermic_desc"),reqs:{evo:6,evo_eggshell:2},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:F("evo_ectothermic_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_reptilian=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_reptilian")},sentience:{id:"evolution-sentience",title:F("evo_sentience_title"),desc:F("evo_sentience_desc"),reqs:{evo:7},grant:["evo",8],condition:()=>t.tech.evo&&7===t.tech.evo&&100===t.evolution.final,cost:{RNA:()=>300,DNA:()=>300},effect:()=>t.evolution.exterminate?F("evo_sentience_ai_effect"):F("evo_sentience_effect"),action(){if(Os($(this)[0])){let e=[],a="humanoid";for(let e in li)if(t.tech[`evo_${e}`]&&t.tech[`evo_${e}`]>=2){a=e;break}if(t.race.junker||t.race.sludge){let r=t.race.sludge?"sludge":"junker";t.race.jtype=a,e.push(r)}else for(let t in Yr){let r=Yr[t];di[r].type===a&&e.push(r)}t.race.species=e[Math.floor(m(0,e.length))],t.stats.achieve[`extinct_${t.race.species}`]&&t.stats.achieve[`extinct_${t.race.species}`].l>=1&&(t.race.species=e[Math.floor(m(0,e.length))]),Ls()}return!1},emblem(){for(let e in Yr){let a=Yr[e];if(t.tech[`evo_${di[a].type}`]&&t.tech[`evo_${di[a].type}`]>=2)return Pc(`genus_${di[a].type}`)}return""},queue_complete:()=>t.tech.evo&&7===t.tech.evo?1:0}},city:{gift:{id:"city-gift",title:F("city_gift"),desc:F("city_gift_desc"),wiki:!1,category:"outskirts",reqs:{primitive:1},queue_complete:()=>0,not_tech:["santa"],not_trait:["cataclysm","lone_survivor"],class:["hgift"],condition(){const e=new Date;if(11!==e.getMonth()||11===e.getMonth()&&(e.getDate()<=16||e.getDate()>=25)){let e=!1;return t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(a){t.special.gift[a]&&(e=!0)})),e}return!1},count(){let e=0;return t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(a){t.special.gift[a]&&e++})),e},action(){if(!t.settings.pause){const e=new Date;let a=!1;if(t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(e){t.special.gift[e]&&(a=e)})),11!==e.getMonth()||11===e.getMonth()&&(e.getDate()<=16||e.getDate()>=25))if("g2019"===a)t.special&&t.special.gift&&(delete t.special.gift[a],"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=100,t.stats.antiplasmid+=100,Di(F("city_gift_msg",[100,F("arpa_genepool_effect_antiplasmid")]),"info",!1,["events"])):(t.prestige.Plasmid.count+=100,t.stats.plasmid+=100,Di(F("city_gift_msg",[100,F("arpa_genepool_effect_plasmid")]),"info",!1,["events"])),hs());else if(t.special&&t.special.gift){delete t.special.gift[a];let e=100+(t.stats.hasOwnProperty("reset")?t.stats.reset:0)+(t.stats.hasOwnProperty("mad")?t.stats.mad:0),r=(t.stats.hasOwnProperty("bioseed")?t.stats.bioseed:0)+(t.stats.hasOwnProperty("cataclysm")?t.stats.cataclysm:0),s=[];if(t.stats.died+t.stats.tdied>0){let e=t.stats.died+t.stats.tdied;t.resource.Coal.amount+=e,s.push(`${e.toLocaleString()} ${F("resource_Coal_name")}`)}if("antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=e,t.stats.antiplasmid+=e,s.push(`${e.toLocaleString()} ${F("resource_AntiPlasmid_plural_name")}`)):(t.prestige.Plasmid.count+=e,t.stats.plasmid+=e,s.push(`${e.toLocaleString()} ${F("resource_Plasmid_plural_name")}`)),r>0&&(t.prestige.Phage.count+=r,t.stats.phage+=r,s.push(`${r.toLocaleString()} ${F("resource_Phage_name")}`)),t.stats.hasOwnProperty("achieve")){let e=t.stats.achieve.whitehole?t.stats.achieve.whitehole.l:0;e+=t.stats.achieve.heavy?t.stats.achieve.heavy.l:0,e+=t.stats.achieve.canceled?t.stats.achieve.canceled.l:0,e+=t.stats.achieve.eviltwin?t.stats.achieve.eviltwin.l:0,e+=t.stats.achieve.microbang?t.stats.achieve.microbang.l:0,e+=t.stats.achieve.pw_apocalypse?t.stats.achieve.pw_apocalypse.l:0;let r=t.stats.achieve.ascended?t.stats.achieve.ascended.l:0,i=t.stats.achieve.corrupted?t.stats.achieve.corrupted.l:0,c=t.stats.achieve.obsolete?t.stats.achieve.obsolete.l:0;if(e>30&&(e=30),r>5&&(r=5),i>5&&(i=5),e>0){let a=+(e/7.5).toFixed(2);t.prestige.Dark.count+=a,t.stats.dark+=a,s.push(`${a} ${F("resource_Dark_name")}`)}if(r>0&&(t.prestige.Harmony.count+=r,t.stats.harmony+=r,s.push(`${r} ${F("resource_Harmony_name")}`)),i>0){let e=5*i,a=i;t.prestige.Blood_Stone.count+=e,t.stats.blood+=e,t.prestige.Artifact.count+=a,t.stats.artifact+=a,s.push(`${e} ${F("resource_Blood_Stone_name")}`),s.push(`${a} ${F("resource_Artifact_name")}`)}"g2020"!==a&&c>0&&(t.prestige.AICore.count+=c,t.stats.cores+=c,s.push(`${c} ${F("resource_AICore_name")}`))}Di(F("city_gift2_msg",[s.join(", ")]),"info",!1,["events"]),hs()}}return!1},touchlabel:F("open")},food:{id:"city-food",title:()=>Ic().active?t.tech.conjuring?F("city_trick_conjure"):F("city_trick"):t.tech.conjuring?F("city_food_conjure"):F("city_food"),desc(){let e=$(this)[0].val(!1);return Ic().active?t.tech.conjuring?F("city_trick_conjure_desc",[e]):F("city_trick_desc",[e]):t.tech.conjuring?F("city_food_conjure_desc",[e]):F("city_food_desc",[e])},category:"outskirts",reqs:{primitive:1},not_trait:["soul_eater","cataclysm","artifical"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring?1:0},action(){return t.settings.pause||(t.resource.Food.amount=1&&(a*=10,t.resource.Food.amountIc().active?t.tech.conjuring&&t.tech.conjuring>=2?F("city_dig_conjour"):F("city_dig"):t.tech.conjuring&&t.tech.conjuring>=2?F("city_lumber_conjure"):F("city_lumber"),desc(){let e=$(this)[0].val(!1);return Ic().active?t.tech.conjuring&&t.tech.conjuring>=2?F("city_dig_conjour_desc",[e]):F("city_dig_desc",[e]):t.tech.conjuring&&t.tech.conjuring>=2?F("city_lumber_conjure_desc",[e]):F("city_lumber_desc",[e])},category:"outskirts",reqs:{},not_trait:["evil","cataclysm"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||(t.resource.Lumber.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Lumber.amountt.tech.conjuring&&t.tech.conjuring>=2?F("city_conjour",[t.resource.Stone.name]):F("city_gather",[t.resource.Stone.name]),desc(){let e=$(this)[0].val(!1);return t.tech.conjuring&&t.tech.conjuring>=2?F("city_stone_conjour_desc",[e,t.resource.Stone.name]):F(t.race.sappy?"city_amber_desc":"city_stone_desc",[e,t.resource.Stone.name])},category:"outskirts",reqs:{primitive:2},not_trait:["cataclysm","lone_survivor"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||(t.resource.Stone.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Stone.amountt.tech.conjuring&&t.tech.conjuring>=2?F("city_chrysotile_conjour"):F("city_gather",[t.resource.Chrysotile.name]),desc(){let e=$(this)[0].val(!1);return t.tech.conjuring&&t.tech.conjuring>=2?F("city_stone_conjour_desc",[e,t.resource.Chrysotile.name]):F("city_stone_desc",[e,t.resource.Chrysotile.name])},category:"outskirts",reqs:{primitive:2},trait:["smoldering"],not_trait:["cataclysm","lone_survivor"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||t.resource.Chrysotile.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Chrysotile.amountt.race.soul_eater?t.tech.primitive?t.resource.hasOwnProperty("furs")&&t.resource.Furs.display?F("city_evil_desc3"):F("city_evil_desc2"):F("city_evil_desc1"):t.resource.hasOwnProperty("furs")&&t.resource.Furs.display?F("city_evil_desc4"):F("city_evil_desc1"),category:"outskirts",reqs:{},trait:["evil"],not_trait:["kindling_kindred","smoldering","cataclysm"],queue_complete:()=>0,action(){if(!t.settings.pause){let e=t.race.strong?ui.strong.vars()[0]:1;t.genes.enhance&&(e*=2),t.race.smoldering||(t.resource.Lumber.amount25e3},queue_complete:()=>t.city.slave_pen?4*t.city.slave_pen.count-t.city.slave_pen.slaves:0,action(){return!!(t.city.slave_pen&&4*t.city.slave_pen.count>t.city.slave_pen.slaves&&Os($(this)[0]))&&(t.city.slave_pen.slaves++,t.resource.Slave.amount=t.city.slave_pen.slaves,!0)},touchlabel:F("purchase")},s_alter:{id:"city-s_alter",title:F("city_s_alter"),desc:()=>t.city.hasOwnProperty("s_alter")&&t.city.s_alter.count>=1?`
    ${F("city_s_alter")}
    ${F("city_s_alter_desc")}
    `:F("city_s_alter"),category:"outskirts",reqs:{mining:1},trait:["cannibalize"],not_trait:["cataclysm","lone_survivor"],inflation:!1,cost:{Stone:e=>(e||0)+(t.city.hasOwnProperty("s_alter")?t.city.s_alter.count:0)>=1?0:100},effect(){let e=`
    ${F("city_s_alter_sacrifice",[t.civic[t.civic.d_job]?t.civic[t.civic.d_job].workers:0])}
    `;if(t.city.hasOwnProperty("s_alter")&&t.city.s_alter.rage>0&&(e+=`
    ${F("city_s_alter_rage",[ui.cannibalize.vars()[0],ic(t.city.s_alter.rage)])}
    `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.regen>0&&(e+=`
    ${F("city_s_alter_regen",[ui.cannibalize.vars()[0],ic(t.city.s_alter.regen)])}
    `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.mind>0&&(e+=`
    ${F("city_s_alter_mind",[ui.cannibalize.vars()[0],ic(t.city.s_alter.mind)])}
    `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.mine>0&&(e+=`
    ${F("city_s_alter_mine",[ui.cannibalize.vars()[0],ic(t.city.s_alter.mine)])}
    `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.harvest>0){let a=t.race.evil&&!t.race.soul_eater?F("job_reclaimer"):F("job_lumberjack");e+=`
    ${F("city_s_alter_harvest",[ui.cannibalize.vars()[0],ic(t.city.s_alter.harvest),a])}
    `}return e},action(){if(Os($(this)[0])){if(0===t.city.s_alter.count)t.city.s_alter.count++;else if(t.civic[t.civic.d_job].workers>0){t.resource[t.race.species].amount--,t.civic[t.civic.d_job].workers--,t.stats.sac++,t.resource.Food.amount+=Math.rand(250,1e3);let e=300,a=600;if(t.tech.sacrifice)switch(t.tech.sacrifice){case 1:e=600,a=1500;break;case 2:e=1800,a=3600;break;case 3:e=5400,a=16200}switch(t.race.kindling_kindred||t.race.smoldering?Math.rand(0,4):Math.rand(0,5)){case 0:t.city.s_alter.rage+=Math.rand(e,a);break;case 1:t.city.s_alter.mind+=Math.rand(e,a);break;case 2:t.city.s_alter.regen+=Math.rand(e,a);break;case 3:t.city.s_alter.mine+=Math.rand(e,a);break;case 4:t.city.s_alter.harvest+=Math.rand(e,a)}}return!0}return!1},touchlabel:F("tech_dist_sacrifice")},basic_housing:{id:"city-basic_housing",title:()=>Es(),desc:F("city_basic_housing_desc"),desc(){return 1===$(this)[0].citizens()?F("city_basic_housing_desc"):F("city_basic_housing_desc_plural",[$(this)[0].citizens()])},category:"residential",reqs:{housing:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.basic_housing?t.city.basic_housing.count:0)+e>=5?Yi("basic_housing",e,20,1.17):0),Lumber:e=>t.race.kindling_kindred||t.race.smoldering?0:Yi("basic_housing",e,10,1.23),Stone:e=>t.race.kindling_kindred?Yi("basic_housing",e,10,1.23):0,Chrysotile:e=>t.race.smoldering?Yi("basic_housing",e,10,1.23):0,Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.sappy?`
    ${F("plus_max_resource",[e,F("citizen")])}
    ${F("city_grove_effect",[2.5])}
    `:F("plus_max_resource",[e,F("citizen")])},action(){return!!Os($(this)[0])&&(t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=$(this)[0].citizens(),t.city.basic_housing.count++,t.settings.showCivic=!0,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},cottage:{id:"city-cottage",title:()=>Is("medium"),desc(){return F("city_cottage_desc",[$(this)[0].citizens()])},category:"residential",reqs:{housing:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("cottage",e,900,1.15),Plywood:e=>Yi("cottage",e,25,1.25),Brick:e=>Yi("cottage",e,20,1.25),Wrought_Iron:e=>Yi("cottage",e,15,1.25),Iron:e=>t.city.ptrait.includes("unstable")?Yi("cottage",e,5,1.25):0,Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens();if(t.tech.home_safe){let a=Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?5e3:2e3:1e3);return`
    ${F("plus_max_citizens",[e])}
    ${F("plus_max_resource",[`$${a.toLocaleString()}`,F("resource_Money_name")])}
    `}return F("plus_max_citizens",[e])},action(){return!!Os($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens(),t.city.cottage.count++,!0)},citizens(){let e=2;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},apartment:{id:"city-apartment",title:()=>Is("large"),desc(){return`
    ${F("city_apartment_desc",[$(this)[0].citizens()])}
    ${F("requires_power")}
    `},category:"residential",reqs:{housing:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("apartment",e,1750,1.26)-500,Crystal:e=>"magic"===t.race.universe?Yi("apartment",e,25,1.22):0,Furs:e=>Yi("apartment",e,725,1.32)-500,Copper:e=>Yi("apartment",e,650,1.32)-500,Cement:e=>Yi("apartment",e,700,1.32)-500,Steel:e=>Yi("apartment",e,800,1.32)-500,Horseshoe:()=>t.race.hooved?5:0},effect(){let e=N("extravagant",2),a=$(this)[0].citizens();if(t.tech.home_safe){let r=Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?1e4:5e3:2e3);return e&&(r*=2),`
    ${F("plus_max_citizens",[a])}. ${F("minus_power",[$(this)[0].powered()])}
    ${F("plus_max_resource",[`$${r.toLocaleString()}`,F("resource_Money_name")])}
    `}return`${F("plus_max_citizens",[a])}. ${F("minus_power",[$(this)[0].powered()])}`},powered:()=>oc(N("extravagant",1)||1),action(){return!!Os($(this)[0])&&(t.city.apartment.count++,xs($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens()),!0)},citizens(){let e=N("extravagant",2),a=e?5+e:5;return t.race.high_pop&&(a*=ui.high_pop.vars()[0]),a}},lodge:{id:"city-lodge",title:F("city_lodge"),desc:()=>t.race.detritivore?F("city_lodge_desc_alt"):F("city_lodge_desc"),category:"residential",reqs:{housing:1,currency:1},not_trait:["cataclysm","lone_survivor"],condition:()=>!!((t.race.soul_eater||t.race.detritivore||t.race.artifical||t.race.unfathomable)&&t.tech.s_lodge||t.tech.hunting&&t.tech.hunting>=2),cost:{Money:e=>Yi("lodge",e,50,1.32),Lumber:e=>Yi("lodge",e,20,1.36),Stone:e=>Yi("lodge",e,10,1.36),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.carnivore&&!t.race.artifical?`
    ${F("plus_max_resource",[e,F("citizen")])}
    ${F("city_lodge_effect",[5])}
    `:F("plus_max_resource",[e,F("citizen")])},action(){return!!Os($(this)[0])&&(t.city.lodge.count++,t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=1,t.settings.showCivic=!0,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},smokehouse:{id:"city-smokehouse",title:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("city_smokehouse_easter"):F("city_smokehouse"),desc:F("city_smokehouse_desc"),category:"trade",reqs:{hunting:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("smokehouse",e,85,1.32),Lumber:e=>Yi("smokehouse",e,65,1.36),Stone:e=>Yi("smokehouse",e,50,1.36)},effect:()=>`
    ${F("plus_max_resource",[cs(Lr(100)),F("resource_Food_name")])}
    ${F("city_smokehouse_effect",[10])}
    `,action(){return!!Os($(this)[0])&&(t.city.smokehouse.count++,t.resource.Food.max+=cs(Lr(100)),!0)}},soul_well:{id:"city-soul_well",title:F("city_soul_well"),desc:F("city_soul_well_desc"),category:"trade",reqs:{soul_eater:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.soul_well?t.city.soul_well.count:0)+e>=3?Yi("soul_well",e,50,1.32):0),Lumber:e=>Yi("soul_well",e,20,1.36),Stone:e=>Yi("soul_well",e,10,1.36)},effect(){let e=cs(Lr(500));return`
    ${F("city_soul_well_effect",[t.race.ghostly?2+ui.ghostly.vars()[1]:2])}
    ${F("plus_max_resource",[e,F("resource_Souls_name")])}
    `},action(){return!!Os($(this)[0])&&(t.city.soul_well.count++,t.resource.Food.max+=cs(Lr(500)),!0)}},slave_pen:{id:"city-slave_pen",title:F("city_slave_pen"),desc:F("city_slave_pen"),category:"commercial",reqs:{slaves:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("slave_pen",e,250,1.32),Lumber:e=>Yi("slave_pen",e,100,1.36),Stone:e=>Yi("slave_pen",e,75,1.36),Copper:e=>Yi("slave_pen",e,10,1.36),Nanite:e=>t.race.deconstructor?Yi("slave_pen",e,4,1.36):0},effect(){let e=t.city.slave_pen?4*t.city.slave_pen.count:4,a=t.city.slave_pen?t.city.slave_pen.slaves:0;return`
    ${F("city_slave_pen_effect",[4])}
    ${F("city_slave_pen_effect2",[a,e])}
    `},action(){return!!Os($(this)[0])&&(t.city.slave_pen.count++,t.resource.Slave.display=!0,t.resource.Slave.amount=t.city.slave_pen.slaves,t.resource.Slave.max=4*t.city.slave_pen.count,!0)}},transmitter:{id:"city-transmitter",title:F("city_transmitter"),desc:()=>`
    ${F("city_transmitter_desc")}
    ${F("requires_power")}
    `,category:"residential",reqs:{high_tech:4},trait:["artifical"],cost:{Money:e=>t.city.transmitter&&t.city.transmitter.count>=3?Yi("transmitter",e,50,1.32):0,Copper:e=>Yi("transmitter",e,20,1.36),Steel:e=>Yi("transmitter",e,10,1.36)},effect(){let e=+Pe("transmitter").toFixed(2),a=Lr(100);return`
    ${F("gain",[e,t.resource.Food.name])}
    ${F("city_transmitter_effect",[a])}
    ${F("minus_power",[$(this)[0].powered()])}
    `},powered:()=>oc(.5),powerBalancer:()=>[{r:"Food",k:"lpmod"}],action(){return!!Os($(this)[0])&&(t.city.transmitter.count++,xs($(this)[0]),!0)}},captive_housing:Vr("captive_housing","city"),farm:{id:"city-farm",title:F("city_farm"),desc:F("city_farm_desc"),category:"residential",reqs:{agriculture:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.farm?t.city.farm.count:0)+e>=3?Yi("farm",e,50,1.32):0),Lumber:e=>Yi("farm",e,20,1.36),Stone:e=>Yi("farm",e,10,1.36),Horseshoe:e=>t.race.hooved&&(t.city.farm?t.city.farm.count:0)+(e||0)>=2?1:0},effect(){let e=$(this)[0].citizens();return t.tech.farm?`
    ${F("city_farm_effect")}
    ${F("plus_max_resource",[e,F("citizen")])}
    `:F("city_farm_effect")},action(){return!!Os($(this)[0])&&(t.city.farm.count++,t.civic.farmer.display=!0,t.tech.farm&&(t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=$(this)[0].citizens(),t.settings.showCivic=!0),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e},flair:()=>t.tech.agriculture>=7?F("city_farm_flair2"):F("city_farm_flair1")},compost:{id:"city-compost",title:F("city_compost_heap"),desc:F("city_compost_heap_desc"),category:"residential",reqs:{compost:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.compost?t.city.compost.count:0)+e>=3?Yi("compost",e,50,1.32):0),Lumber:e=>Yi("compost",e,12,1.36),Stone:e=>Yi("compost",e,12,1.36)},effect(){let e=1.2+.8*(t.tech.compost?t.tech.compost:0);e*="grassland"===t.city.biome?ji.grassland.vars()[0]:1,e*="savanna"===t.city.biome?ji.savanna.vars()[0]:1,e*="ashland"===t.city.biome?ji.ashland.vars()[0]:1,e*="volcanic"===t.city.biome?ji.volcanic.vars()[0]:1,e*="hellscape"===t.city.biome?ji.hellscape.vars()[0]:1,e*=t.city.ptrait.includes("trashed")?Si.trashed.vars()[0]:1,e=+e.toFixed(2);let a=cs(Lr(200)),r=t.race.kindling_kindred?"":`
    ${F("city_compost_heap_effect2",[.5,t.resource.Lumber.name])}
    `;return`
    ${F("city_compost_heap_effect",[e])}
    ${F("city_compost_heap_effect3",[a])}
    ${r}`},switchable:()=>!0,action(){return!!Os($(this)[0])&&(t.city.compost.count++,t.city.compost.on++,t.resource.Food.max+=cs(Lr(200)),!0)}},mill:{id:"city-mill",title:()=>t.tech.agriculture>=5?F("city_mill_title2"):F("city_mill_title1"),desc(){let e=t.tech.agriculture>=5?5:3;return t.tech.agriculture>=6?F("city_mill_desc2",[e,-1*$(this)[0].powered()]):F("city_mill_desc1",[e])},category:"utility",reqs:{agriculture:4},not_tech:["wind_plant"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("mill",e,1e3,1.31),Lumber:e=>Yi("mill",e,600,1.33),Iron:e=>Yi("mill",e,150,1.33),Cement:e=>Yi("mill",e,125,1.33)},powered:()=>t.race.environmentalist?-1.5:-1,power_reqs:{agriculture:6},effect:()=>t.tech.agriculture>=6&&`${F("city_on")} ${F("city_mill_effect1")} ${F("city_off")} ${F("city_mill_effect2")}`,action(){return!!Os($(this)[0])&&(t.city.mill.count++,!0)}},windmill:{id:"city-windmill",title:()=>t.race.unfathomable?F("tech_watermill"):F("city_mill_title2"),desc:()=>t.race.unfathomable?F("tech_watermill"):F("city_mill_title2"),wiki:!1,category:"utility",reqs:{wind_plant:1},not_trait:["cataclysm","lone_survivor"],powered:()=>t.race.environmentalist?-1.5:-1,power_reqs:{false:1},cost:{Money:e=>Yi("windmill",e,1e3,1.31),Lumber:e=>Yi("windmill",e,600,1.33),Iron:e=>Yi("windmill",e,150,1.33),Cement:e=>Yi("windmill",e,125,1.33)},effect(){return`
    ${F("space_dwarf_reactor_effect1",[-1*$(this)[0].powered()])}
    `},action(){return!!Os($(this)[0])&&(t.city.windmill.count++,!0)}},silo:{id:"city-silo",title:F("city_silo"),desc:F("city_food_storage"),category:"trade",reqs:{agriculture:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("silo",e,85,1.32),Lumber:e=>Yi("silo",e,65,1.36),Stone:e=>Yi("silo",e,50,1.36),Iron:e=>(t.city.silo?t.city.silo.count:0)+(e||0)>=4&&t.city.ptrait.includes("unstable")?Yi("silo",e,10,1.36):0},effect:()=>F("plus_max_resource",[cs(Lr(500)),F("resource_Food_name")]),action(){return!!Os($(this)[0])&&(t.city.silo.count++,t.resource.Food.max+=cs(Lr(500)),!0)}},assembly:Vr("assembly","city"),garrison:{id:"city-garrison",title:()=>t.race.flier?F("city_garrison_flier"):F("city_garrison"),desc:F("city_garrison_desc"),category:"military",reqs:{military:1,housing:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("garrison",e,240,1.5),Stone:e=>Yi("garrison",e,260,1.46),Iron:e=>(t.city.garrison?t.city.garrison.count:0)+(e||0)>=4&&t.city.ptrait.includes("unstable")?Yi("garrison",e,50,1.4):0,Horseshoe:()=>t.race.hooved?t.race.chameleon?1:2:0},effect(){let e=t.tech.military>=5?la(3):la(2);return t.race.chameleon&&e--,F("plus_max_resource",[e,F("civics_garrison_soldiers")])},switchable:()=>!0,action(){if(Os($(this)[0])){t.settings.showMil=!0,t.settings.msgFilters.combat.unlocked||(t.settings.msgFilters.combat.unlocked=!0,t.settings.msgFilters.combat.vis=!0),t.civic.garrison.display||(t.civic.garrison.display=!0,sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update"));let e=t.tech.military>=5?3:2;return t.race.chameleon&&(e-=t.city.garrison.count),t.civic.garrison.max+=e,t.city.garrison.count++,t.city.garrison.on++,t.resource.Furs.display=!0,!0}return!1}},hospital:{id:"city-hospital",title:F("city_hospital"),desc:F("city_hospital_desc"),category:"military",reqs:{medic:1},not_trait:["cataclysm","artifical"],cost:{Money:e=>Yi("hospital",e,22e3,1.32),Furs:e=>Yi("hospital",e,4e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?Yi("hospital",e,500,1.32):0,Aluminium:e=>Yi("hospital",e,1e4,1.32)},effect(){let e=t.tech.reproduction&&t.tech.reproduction>=2?`
    ${F("city_hospital_effect2")}
    `:"",a=`
    ${F("city_hospital_effect",[5*t.tech.medic])}
    ${e}`;return!t.race.artifical&&t.race.hasOwnProperty("vax")&&(a+=`
    ${F("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
    `),a},action(){return!!Os($(this)[0])&&(t.city.hospital.count++,!0)}},boot_camp:{id:"city-boot_camp",title:()=>t.race.artifical?F("city_boot_camp_art"):F("city_boot_camp"),desc:()=>t.race.artifical?F("city_boot_camp_art_desc",[di[t.race.species].name]):F("city_boot_camp_desc"),category:"military",reqs:{boot_camp:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("boot_camp",e,5e4,1.32),Lumber:e=>Yi("boot_camp",e,21500,1.32),Iron:e=>t.city.ptrait.includes("unstable")?Yi("boot_camp",e,300,1.32):0,Aluminium:e=>Yi("boot_camp",e,12e3,1.32),Brick:e=>Yi("boot_camp",e,1400,1.32)},effect(){let e=t.tech.boot_camp>=2?8:5;t.blood.lust&&(e+=.2*t.blood.lust);let a=N("militant",0);a&&(e*=1+a/100);let r=t.tech.spy&&t.tech.spy>=3?`
    ${F("city_boot_camp_effect",[e])}
    ${F("city_boot_camp_effect2",[10])}
    `:`
    ${F("city_boot_camp_effect",[e])}
    `;return t.race.artifical&&!t.race.orbit_decayed&&(r+=`
    ${F("city_boot_camp_art_effect",[5*(t.tech.medic||1)])}
    `),t.race.artifical&&t.race.hasOwnProperty("vax")&&(desc+=`
    ${F("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
    `),r},action(){return!!Os($(this)[0])&&(t.city.boot_camp.count++,!0)}},shed:{id:"city-shed",title:()=>t.tech.storage<=2?F("city_shed_title1"):t.tech.storage>=4?F("city_shed_title3"):F("city_shed_title2"),desc(){let e=t.tech.storage>=3?t.tech.storage>=4?F("city_shed_desc_size3"):F("city_shed_desc_size2"):F("city_shed_desc_size1");return F("city_shed_desc",[e])},category:"trade",reqs:{storage:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("shed",e,75,1.22),Lumber:e=>t.tech.storage&&t.tech.storage<4?Yi("shed",e,55,1.32):0,Stone:e=>t.tech.storage&&t.tech.storage<3?Yi("shed",e,45,1.32):0,Iron:e=>t.tech.storage&&t.tech.storage>=4?Yi("shed",e,22,1.32):0,Cement:e=>t.tech.storage&&t.tech.storage>=3?Yi("shed",e,18,1.32):0},res(){let e=["Lumber","Stone","Chrysotile","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal"];return t.tech.storage>=3&&t.resource.Steel.display&&e.push("Steel"),t.tech.storage>=4&&t.resource.Titanium.display&&e.push("Titanium"),t.tech.shelving&&t.tech.shelving>=3&&t.resource.Graphene.display&&e.push("Graphene"),t.tech.shelving&&t.tech.shelving>=3&&t.resource.Stanene.display&&e.push("Stanene"),t.race.unfathomable&&e.push("Food"),e},val(e){switch(e){case"Food":return 50;case"Lumber":case"Stone":case"Chrysotile":return 300;case"Crystal":return 8;case"Furs":case"Iron":return 125;case"Copper":case"Aluminium":return 90;case"Cement":return 100;case"Coal":return 75;case"Steel":return 40;case"Titanium":return 20;case"Graphene":return 15;case"Stanene":return 25;default:return 0}},effect(){let e='
    ',a=os();for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return e+="
    ",e},wide:!0,action(){if(Os($(this)[0])){t.city.shed.count++;let e=os();for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=Lr($(this)[0].val(a)*e));return!0}return!1}},storage_yard:{id:"city-storage_yard",title:F("city_storage_yard"),desc:F("city_storage_yard_desc"),category:"trade",reqs:{container:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("storage_yard",e,10,Rs(1.36)),Brick:e=>Yi("storage_yard",e,3,Rs(1.35)),Wrought_Iron:e=>Yi("storage_yard",e,5,Rs(1.35))},effect(){let e=t.tech.container>=3?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.tech.trade&&t.tech.trade>=3?`
    ${F("plus_max_resource",[e,F("resource_Crates_name")])}
    ${F("city_trade_effect",[1])}
    `:F("plus_max_resource",[e,F("resource_Crates_name")])},action(){if(Os($(this)[0])){!1===t.resource.Crates.display&&Di(F("city_storage_yard_msg"),"info",!1,["progress"]),t.city.storage_yard.count++,t.settings.showResources=!0,t.settings.showStorage=!0,t.settings.showMarket||(t.settings.marketTabs=1);let e=t.tech.container>=3?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Crates.max+=e,t.resource.Crates.display||(t.resource.Crates.display=!0,rc($("#resources")),rr(),t.settings.tabLoad&&(ar("storage"),K())),!0}return!1}},warehouse:{id:"city-warehouse",title:F("city_warehouse"),desc:F("city_warehouse_desc"),category:"trade",reqs:{steel_container:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("warehouse",e,400,Rs(1.26)),Cement:e=>Yi("warehouse",e,75,Rs(1.26)),Sheet_Metal:e=>Yi("warehouse",e,25,Rs(1.25))},effect(){let e=t.tech.steel_container>=2?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),F("plus_max_resource",[e,F("resource_Containers_name")])},action(){if(Os($(this)[0])){!1===t.resource.Containers.display&&Di(F("city_warehouse_msg"),"info",!1,["progress"]),t.city.warehouse.count++,t.settings.showResources=!0,t.settings.showStorage=!0;let e=t.tech.steel_container>=2?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Containers.max+=e,t.resource.Containers.display||(t.resource.Containers.display=!0,rc($("#resources")),rr(),t.settings.tabLoad&&ar("storage")),!0}return!1}},bank:{id:"city-bank",title:F("city_bank"),desc:()=>F("city_bank_desc",[di[t.race.species].home]),category:"commercial",reqs:{banking:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("bank",e,250,1.35),Lumber:e=>Yi("bank",e,75,1.32),Stone:e=>Yi("bank",e,100,1.35),Iron:e=>(t.city.bank?t.city.bank.count:0)+(e||0)>=2&&t.city.ptrait.includes("unstable")?Yi("bank",e,30,1.3):0},effect(){let e=Hs();return e=Lr(e),e=(+e.toFixed(0)).toLocaleString(),t.tech.banking>=2?`
    ${F("plus_max_resource",[`$${e}`,F("resource_Money_name")])}
    ${F("plus_max_resource",[la(1),F("banker_name")])}
    `:F("plus_max_resource",[`$${e}`,F("resource_Money_name")])},action(){return!!Os($(this)[0])&&(t.resource.Money.max+=Lr(1800),t.city.bank.count++,t.civic.banker.max=la(t.city.bank.count),!0)}},pylon:{id:"city-pylon",title:F("city_pylon"),desc:F("city_pylon"),category:"industrial",reqs:{magic:2},not_trait:["cataclysm","orbit_decayed"],cost:{Money:e=>(e=e||0,(t.city.pylon?t.city.pylon.count:0)+e>=2?Yi("pylon",e,10,1.48):0),Stone:e=>Yi("pylon",e,12,1.42),Crystal:e=>Yi("pylon",e,8,1.42)-3},effect(){let e=Lr(5);return`
    ${F("gain",[+(.01*nc("magic")).toFixed(3),t.resource.Mana.name])}
    ${F("plus_max_resource",[e,t.resource.Mana.name])}
    `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!Os($(this)[0])&&(t.city.pylon.count++,t.resource.Mana.max+=Lr(5),!0)}},conceal_ward:{id:"city-conceal_ward",title:F("city_conceal_ward"),desc:F("city_conceal_ward"),category:"industrial",reqs:{roguemagic:3},not_trait:["cataclysm","orbit_decayed"],cost:{Money:e=>Yi("conceal_ward",e,500,1.25),Mana:e=>{return Yi("conceal_ward",e,(a=42,t.tech.nexus&&t.tech.roguemagic&&t.tech.roguemagic>=7&&(a*=.92**t.tech.nexus),a),1.25);var a},Crystal:e=>Yi("conceal_ward",e,5,1.25)},effect:()=>`
    ${F("city_conceal_ward_effect",[t.tech.roguemagic&&t.tech.roguemagic>=8?1.25:1])}
    `,action(){return!!Os($(this)[0])&&(t.city.conceal_ward.count++,!0)}},graveyard:{id:"city-graveyard",title:F("city_graveyard"),desc:F("city_graveyard_desc"),category:"industrial",reqs:{reclaimer:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.graveyard?t.city.graveyard.count:0)+e>=5?Yi("graveyard",e,5,1.85):0),Lumber:e=>Yi("graveyard",e,2,1.95),Stone:e=>Yi("graveyard",e,6,1.9)},effect(){let e=cs(Lr(100));return`
    ${F("city_graveyard_effect",[8])}
    ${F("plus_max_resource",[e,t.resource.Lumber.name])}
    `},action(){return!!Os($(this)[0])&&(t.city.graveyard.count++,t.resource.Lumber.max+=cs(Lr(100)),!0)}},lumber_yard:{id:"city-lumber_yard",title:F("city_lumber_yard"),desc:F("city_lumber_yard_desc"),category:"industrial",reqs:{axe:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.lumber_yard?t.city.lumber_yard.count:0)+e>=5?Yi("lumber_yard",e,5,1.85):0),Lumber:e=>Yi("lumber_yard",e,6,1.9),Stone:e=>Yi("lumber_yard",e,2,1.95)},effect(){let e=cs(Lr(100));return`
    ${F("city_lumber_yard_effect",[2])}
    ${F("plus_max_resource",[e,t.resource.Lumber.name])}
    `},action(){return!!Os($(this)[0])&&(t.city.lumber_yard.count++,t.civic.lumberjack.display=!0,t.resource.Lumber.max+=cs(Lr(100)),!0)}},sawmill:{id:"city-sawmill",title:F("city_sawmill"),desc:F("city_sawmill_desc"),category:"industrial",reqs:{saw:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("sawmill",e,3e3,1.26),Iron:e=>Yi("sawmill",e,400,1.26),Cement:e=>Yi("sawmill",e,420,1.26)},effect(){let e=t.tech.saw>=2?8:5,a=`
    ${F("plus_max_resource",[cs(Lr(200)),t.resource.Lumber.name])}
    ${F("city_lumber_yard_effect",[e])}
    `;return t.tech.foundry&&t.tech.foundry>=4&&(a+=`
    ${F("city_sawmill_effect2",[2])}
    `),t.city.powered&&(a+=`
    ${F("city_sawmill_effect3",[4,$(this)[0].powered()])}
    `),a},powered:()=>oc(1),powerBalancer:()=>!!t.city.sawmill.hasOwnProperty("psaw")&&[{r:"Lumber",k:"psaw"}],action(){return!!Os($(this)[0])&&(t.city.sawmill.count++,t.resource.Lumber.max+=cs(Lr(200)),xs($(this)[0]),!0)}},rock_quarry:{id:"city-rock_quarry",title:()=>t.race.flier?F("city_rock_quarry_alt"):F("city_rock_quarry"),desc:()=>t.race.flier?F("city_rock_quarry_desc_alt",[t.resource.Stone.name]):F("city_rock_quarry_desc"),category:"industrial",reqs:{mining:1},not_trait:["cataclysm","sappy"],cost:{Money:e=>(e=e||0,(t.city.rock_quarry?t.city.rock_quarry.count:0)+e>=2?Yi("rock_quarry",e,20,1.45):0),Lumber:e=>Yi("rock_quarry",e,50,1.36),Stone:e=>Yi("rock_quarry",e,10,1.36)},effect(){let e=cs(Lr(100)),a=t.race.smoldering?`
    ${F("plus_max_resource",[e,t.resource.Chrysotile.name])}
    `:"";return t.tech.mine_conveyor?`
    ${F("city_rock_quarry_effect1",[2])}
    ${F("plus_max_resource",[e,t.resource.Stone.name])}
    ${a}
    ${F("city_rock_quarry_effect2",[4,$(this)[0].powered()])}
    `:`
    ${F("city_rock_quarry_effect1",[2])}
    ${F("plus_max_resource",[e,t.resource.Stone.name])}
    ${a}`},special:()=>!!t.race.smoldering,powered:()=>oc(1),powerBalancer:()=>!!t.city.rock_quarry.hasOwnProperty("cnvay")&&(t.city.hasOwnProperty("metal_refinery")&&t.city.rock_quarry.hasOwnProperty("almcvy")?[{r:"Stone",k:"cnvay"},{r:"Aluminium",k:"almcvy"}]:[{r:"Stone",k:"cnvay"}]),power_reqs:{mine_conveyor:1},action(){if(Os($(this)[0])){t.city.rock_quarry.count++,t.civic.quarry_worker.display=!0;let e=cs(Lr(100));return t.resource.Stone.max+=e,t.race.smoldering&&t.resource.Chrysotile.display&&(t.settings.showCivic=!0,t.settings.showIndustry=!0,t.resource.Chrysotile.max+=e),t.tech.mine_conveyor&&xs($(this)[0]),!0}return!1}},cement_plant:{id:"city-cement_plant",title:F("city_cement_plant"),desc:F("city_cement_plant_desc"),category:"industrial",reqs:{cement:1},not_trait:["cataclysm","lone_survivor","flier"],cost:{Money:e=>Yi("cement_plant",e,3e3,1.5),Lumber:e=>Yi("cement_plant",e,1800,1.36),Stone:e=>Yi("cement_plant",e,2e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?Yi("cement_plant",e,275,1.32):0},effect(){if(t.tech.cement>=5){let e=t.tech.cement>=6?8:5;return`
    ${F("city_cement_plant_effect1",[la(2)])}
    ${F("city_cement_plant_effect2",[$(this)[0].powered(),e])}
    `}return F("city_cement_plant_effect1",[la(2)])},powered:()=>oc(2),powerBalancer:()=>!!t.city.cement_plant.hasOwnProperty("cnvay")&&[{r:"Cement",k:"cnvay"}],power_reqs:{cement:5},action(){return!!Os($(this)[0])&&(t.resource.Cement.display=!0,t.city.cement_plant.count++,t.civic.cement_worker.display=!0,t.civic.cement_worker.max=t.city.cement_plant.count*la(2),t.tech.cement&&t.tech.cement>=5&&xs($(this)[0]),!0)}},foundry:{id:"city-foundry",title:F("city_foundry"),desc:F("city_foundry_desc"),category:"industrial",reqs:{foundry:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("foundry",e,750,1.36),Stone:e=>Yi("foundry",e,100,1.36),Copper:e=>Yi("foundry",e,250,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("foundry",e,40,1.36):0},effect(){let e=`
    ${F("city_foundry_effect1",[la(1)])}
    `;return t.tech.foundry>=2&&(e+=`
    ${F("city_crafted_mats",[t.tech.foundry>=5?t.tech.foundry>=8?8:5:3])}
    `),t.tech.foundry>=6&&(e+=`
    ${F("city_foundry_effect2",[2])}
    `),e},action(){return!!Os($(this)[0])&&(0===t.city.foundry.count&&(t.race.no_craft?Di(F("city_foundry_msg2"),"info",!1,["progress"]):Di(F("city_foundry_msg1"),"info",!1,["progress"])),t.city.foundry.count++,t.civic.craftsman.max+=la(1),t.civic.craftsman.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.resource.Plywood.display=!0),t.resource.Brick.display=!0,t.resource.Iron.display&&(t.resource.Wrought_Iron.display=!0),t.resource.Aluminium.display&&(t.resource.Sheet_Metal.display=!0),ha(),!0)}},factory:{id:"city-factory",title:F("city_factory"),desc:`
    ${F("city_factory_desc")}
    ${F("requires_power")}
    `,category:"industrial",reqs:{high_tech:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("factory",e,25e3,Fs(1.32)),Cement:e=>Yi("factory",e,1e3,Fs(1.32)),Steel:e=>Yi("factory",e,7500,Fs(1.32)),Titanium:e=>Yi("factory",e,2500,Fs(1.32))},effect(){let e=`
    ${F("city_factory_effect")}
    ${F("minus_power",[$(this)[0].powered()])}
    `;return t.tech.foundry>=7&&(e+=`
    ${F("city_crafted_mats",[5])}
    `),e},powered:()=>oc(3),special:!0,action(){return!!Os($(this)[0])&&(t.city.factory.count++,t.resource.Alloy.display=!0,t.tech.polymer&&(t.resource.Polymer.display=!0),xs($(this)[0])&&t.city.factory.Alloy++,t.settings.showIndustry=!0,Ws(),!0)}},nanite_factory:Vr("nanite_factory","city"),smelter:{id:"city-smelter",title:F("city_smelter"),desc:F("city_smelter_desc"),category:"industrial",reqs:{smelting:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("smelter",e,1e3,Fs(1.32)),Iron:e=>Yi("smelter",e,500,Fs(1.33))},effect(){var e=t.tech.smelting>=3?t.tech.smelting>=7?15:12:10;return t.race.pyrophobia&&(e*=.9),t.tech.smelting>=2&&!t.race.steelen?F("city_smelter_effect2",[e]):F("city_smelter_effect1",[e])},special:!0,action(){return!!Os($(this)[0])&&(t.city.smelter.count++,t.race.kindling_kindred||t.race.smoldering||t.race.artifical?t.race.artifical?t.city.smelter.Oil++:t.race.evil?t.city.smelter.Wood++:t.city.smelter.Coal++:t.city.smelter.Wood++,t.city.smelter.Iron++,t.settings.showIndustry=!0,Ws(),!0)},flair:`
    ${F("city_smelter_flair1")}
    ${F("city_smelter_flair2")}
    `},metal_refinery:{id:"city-metal_refinery",title:F("city_metal_refinery"),desc:F("city_metal_refinery_desc"),category:"industrial",reqs:{alumina:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("metal_refinery",e,2500,1.35),Iron:e=>t.city.ptrait.includes("unstable")?Yi("metal_refinery",e,125,1.35):0,Steel:e=>Yi("metal_refinery",e,350,1.35)},powered:()=>oc(2),powerBalancer:()=>!!t.city.metal_refinery.hasOwnProperty("pwr")&&[{r:"Aluminium",k:"cnvay"}],power_reqs:{alumina:2},effect(){let e=t.race.sappy?"city_metal_refinery_effect_alt":"city_metal_refinery_effect";return t.tech.alumina>=2?`${F(e,[6])} ${F("city_metal_refinery_effect2",[6,12,$(this)[0].powered()])}`:F(e,[6])},action(){return!!Os($(this)[0])&&(t.city.metal_refinery.count++,t.resource.Aluminium.display=!0,t.city.foundry&&t.city.foundry.count>0&&!t.resource.Sheet_Metal.display&&(t.resource.Sheet_Metal.display=!0,ha()),t.tech.alumina>=2&&xs($(this)[0]),!0)}},mine:{id:"city-mine",title:F("city_mine"),desc:F("city_mine_desc"),category:"industrial",reqs:{mining:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("mine",e,60,Fs(1.6)),Lumber:e=>Yi("mine",e,175,Fs(1.38))},effect(){return t.tech.mine_conveyor?`
    ${F("city_mine_effect1",[la(1)])}
    ${F("city_mine_effect2",[$(this)[0].powered(),5])}
    `:F("city_mine_effect1",[la(1)])},powered:()=>oc(1),powerBalancer:()=>!(!t.city.mine.hasOwnProperty("cpow")||!t.city.mine.hasOwnProperty("ipow"))&&[{r:"Copper",k:"cpow"},{r:"Iron",k:"ipow"}],power_reqs:{mine_conveyor:1},action(){return!!Os($(this)[0])&&(t.city.mine.count++,t.resource.Copper.display=!0,t.civic.miner.display=!0,t.civic.miner.max=la(t.city.mine.count),t.tech.mine_conveyor&&xs($(this)[0]),!0)},flair:()=>"avian"===di[t.race.species].type?F("city_mine_flair_avian"):""},coal_mine:{id:"city-coal_mine",title:F("city_coal_mine"),desc:F("city_coal_mine_desc"),category:"industrial",reqs:{mining:4},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("coal_mine",e,480,Fs(1.4)),Lumber:e=>Yi("coal_mine",e,250,Fs(1.36)),Iron:e=>t.city.ptrait.includes("unstable")?Yi("coal_mine",e,28,Fs(1.36)):0,Wrought_Iron:e=>Yi("coal_mine",e,18,Fs(1.36))},effect(){return t.tech.mine_conveyor?`
    ${F("city_coal_mine_effect1",[la(1)])}
    ${F("city_coal_mine_effect2",[$(this)[0].powered(),5])}
    `:F("city_coal_mine_effect1",[la(1)])},powered:()=>oc(1),powerBalancer:()=>t.city.coal_mine.hasOwnProperty("cpow")&&t.city.coal_mine.hasOwnProperty("upow")&&t.resource.Uranium.display?[{r:"Coal",k:"cpow"},{r:"Uranium",k:"upow"}]:!!t.city.coal_mine.hasOwnProperty("cpow")&&[{r:"Coal",k:"cpow"}],power_reqs:{mine_conveyor:1},action(){return!!Os($(this)[0])&&(t.city.coal_mine.count++,t.resource.Coal.display=!0,t.civic.coal_miner.display=!0,t.civic.coal_miner.max=la(t.city.coal_mine.count),t.tech.mine_conveyor&&xs($(this)[0]),!0)}},oil_well:{id:"city-oil_well",title:F("city_oil_well"),desc:F("city_oil_well_desc"),category:"industrial",reqs:{oil:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("oil_well",e,5e3,Fs(1.5)),Iron:e=>t.city.ptrait.includes("unstable")?Yi("oil_well",e,450,Fs(1.5)):0,Cement:e=>Yi("oil_well",e,5250,Fs(1.5)),Steel:e=>Yi("oil_well",e,6e3,Fs(1.5))},effect:()=>F("city_oil_well_effect",[+Pe("oil_well").toFixed(2),Lr(500)]),action(){return!!Os($(this)[0])&&(t.city.oil_well.count++,t.resource.Oil.max+=Lr(500),1===t.city.oil_well.count&&(t.resource.Oil.display=!0,Ws()),!0)},flair:F("city_oil_well_flair")},oil_depot:{id:"city-oil_depot",title:F("city_oil_depot"),desc:F("city_oil_depot_desc"),category:"trade",reqs:{oil:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("oil_depot",e,2500,Fs(1.46)),Iron:e=>t.city.ptrait.includes("unstable")?Yi("oil_depot",e,325,Fs(1.36)):0,Cement:e=>Yi("oil_depot",e,3750,Fs(1.46)),Sheet_Metal:e=>Yi("oil_depot",e,100,Fs(1.45))},effect(){let e=Lr(1e3);e*=t.tech.world_control?1.5:1;let a=`
    ${F("plus_max_resource",[e,t.resource.Oil.name])}.
    `;if(t.resource.Helium_3.display){let e=Lr(400);e*=t.tech.world_control?1.5:1,a+=`
    ${F("plus_max_resource",[e,t.resource.Helium_3.name])}.
    `}if(t.tech.uranium>=2){let e=Lr(250);e*=t.tech.world_control?1.5:1,a+=`
    ${F("plus_max_resource",[e,t.resource.Uranium.name])}.
    `}return a},action(){return!!Os($(this)[0])&&(t.city.oil_depot.count++,t.resource.Oil.max+=Lr(1e3)*(t.tech.world_control?1.5:1),t.resource.Helium_3.display&&(t.resource.Helium_3.max+=Lr(400)*(t.tech.world_control?1.5:1)),t.tech.uranium>=2&&(t.resource.Uranium.max+=Lr(250)*(t.tech.world_control?1.5:1)),!0)}},trade:{id:"city-trade",title:F("city_trade"),desc:F("city_trade_desc"),category:"trade",reqs:{trade:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("trade",e,500,1.36),Lumber:e=>Yi("trade",e,125,1.36),Stone:e=>Yi("trade",e,50,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("trade",e,15,1.36):0,Furs:e=>Yi("trade",e,65,1.36)},effect(){let e=t.race.xenophobic||t.race.nomadic?t.tech.trade:t.tech.trade+1;return t.tech.trade&&t.tech.trade>=3&&e--,t.race.flier&&(e+=ui.flier.vars()[1]),F("city_trade_effect",[e])},action(){if(Os($(this)[0])){t.city.trade.count++;let e=t.race.xenophobic||t.race.nomadic?t.tech.trade:t.tech.trade+1;return t.tech.trade&&t.tech.trade>=3&&e--,t.city.market.mtrade+=e,!0}return!1}},wharf:{id:"city-wharf",title:F("city_wharf"),desc:F("city_wharf_desc"),category:"trade",era:"industrialized",reqs:{wharf:1},not_trait:["thalassophobia","cataclysm"],cost:{Money:e=>Yi("wharf",e,62e3,1.32),Lumber:e=>Yi("wharf",e,44e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?Yi("wharf",e,200,1.32):0,Cement:e=>Yi("wharf",e,3e3,1.32),Oil:e=>Yi("wharf",e,750,1.32)},effect(){let e=t.tech.world_control?15:10;return t.tech.particles&&t.tech.particles>=2&&(e*=2),`
    ${F("city_trade_effect",[2])}
    ${F("city_wharf_effect")}
    ${F("plus_max_crates",[e])}
    ${F("plus_max_containers",[e])}
    `},action(){if(Os($(this)[0])){!1===t.resource.Containers.display&&(Di(F("city_warehouse_msg"),"info",!1,["progress"]),t.resource.Containers.display=!0,rc($("#resources")),rr()),t.city.wharf.count++,t.city.market.mtrade+=2;let e=t.tech.world_control?15:10;return t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Crates.max+=e,t.resource.Containers.max+=e,!0}return!1}},tourist_center:{id:"city-tourist_center",title:F("city_tourist_center"),desc:F("city_tourist_center_desc"),category:"commercial",reqs:{monument:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("tourist_center",e,1e5,1.36),Stone:e=>Yi("tourist_center",e,25e3,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("tourist_center",e,1e3,1.36):0,Furs:e=>Yi("tourist_center",e,7500,1.36),Plywood:e=>Yi("tourist_center",e,5e3,1.36)},effect(){let e=t.tech.monument&&t.tech.monument>=3&&i.s_gate?3:1,a=("corpocracy"===t.civic.govern.type?2:1)*e,r=("corpocracy"===t.civic.govern.type?10:5)*e,s=("corpocracy"===t.civic.govern.type?4:2)*e,c="";t.stats.achieve.banana&&t.stats.achieve.banana.l>=4&&(c=`
    ${F("city_tourist_center_effect5",[("corpocracy"===t.civic.govern.type?6:3)*e])}
    `);let o="",n=N("pious",1);return n&&(o=`
    ${F("city_tourist_center_effect6",[("corpocracy"===t.civic.govern.type?2*n:n)*e])}
    `),`
    ${F("city_tourist_center_effect1",[t.resource.Food.name])}
    ${F("city_tourist_center_effect2",[a,Qr.city.amphitheatre.title()])}
    ${F("city_tourist_center_effect3",[r])}
    ${F("city_tourist_center_effect4",[s])}
    ${c}${o}`},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.city.tourist_center.count++,t.city.tourist_center.on++,!0)}},amphitheatre:{id:"city-amphitheatre",title:()=>F(N("athleticism",0)?"city_stadium":"city_amphitheatre"),desc:()=>F(N("athleticism",0)?"city_stadium":"city_amphitheatre_desc"),category:"commercial",reqs:{theatre:1},not_trait:["joyless","cataclysm"],cost:{Money:e=>Yi("amphitheatre",e,500,1.55),Lumber:e=>Yi("amphitheatre",e,50,1.75),Stone:e=>Yi("amphitheatre",e,200,1.75),Iron:e=>t.city.ptrait.includes("unstable")?Yi("amphitheatre",e,18,1.36):0},effect(){let e=N("athleticism",0);return`
    ${F("city_max_entertainer",[la(N("athleticism",1)||1)])}
    ${F("city_max_morale",[e||1])}
    `},action(){return!!Os($(this)[0])&&(t.city.amphitheatre.count++,t.civic.entertainer.max+=la(1),t.civic.entertainer.display=!0,!0)},flair:()=>F(N("athleticism",0)?"city_stadium_flair":"city_amphitheatre_flair")},casino:{id:"city-casino",title:F("city_casino"),desc:F("city_casino"),category:"commercial",reqs:{gambling:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("casino",e,35e4,1.35),Iron:e=>t.city.ptrait.includes("unstable")?Yi("casino",e,2e3,1.35):0,Furs:e=>Yi("casino",e,6e4,1.35),Plywood:e=>Yi("casino",e,1e4,1.35),Brick:e=>Yi("casino",e,6e3,1.35)},effect(){let e=ss();return e+=`
    ${F("minus_power",[$(this)[0].powered()])}
    `,e},powered:()=>oc(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2?2:3),action(){return!!Os($(this)[0])&&(t.city.casino.count++,t.race.joyless||(t.civic.entertainer.max+=la(1),t.civic.entertainer.display=!0),xs($(this)[0]),!0)},flair:F("city_casino_flair")},temple:{id:"city-temple",title:F("city_temple"),desc:()=>F("city_temple_desc",["none"!==t.race.gods?di[t.race.gods.toLowerCase()].entity:di[t.race.species].entity]),category:"commercial",reqs:{theology:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("temple",e,50,1.36),Lumber:e=>Yi("temple",e,25,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("temple",e,6,1.36):0,Furs:e=>Yi("temple",e,15,1.36),Cement:e=>Yi("temple",e,10,1.36)},effect(){let e=rs();return t.genes.ancients&&t.genes.ancients>=2&&(e+=`
    ${F("city_temple_effect6",[la(1)])}
    `),e},action(){return!!Os($(this)[0])&&(t.genes.ancients&&t.genes.ancients>=2&&(t.civic.priest.display=!0),t.city.temple.count++,!0)}},shrine:{id:"city-shrine",title:F("city_shrine"),desc:()=>F("city_shrine_desc"),category:"commercial",reqs:{theology:2},trait:["magnificent"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("shrine",e,75,1.32),Stone:e=>Yi("shrine",e,65,1.32),Furs:e=>Yi("shrine",e,10,1.32),Copper:e=>Yi("shrine",e,15,1.32)},effect(){let e=`
    ${F("city_shrine_effect")}
    `;if(t.city.shrine&&t.city.shrine.morale>0&&(e+=`
    ${F("city_shrine_morale",[+Lc("morale").add.toFixed(1)])}
    `),t.city.shrine&&t.city.shrine.metal>0&&(e+=`
    ${F("city_shrine_metal",[+(100*(Lc("metal").mult-1)).toFixed(1)])}
    `),t.city.shrine&&t.city.shrine.know>0){let t=Lc("know");e+=`
    ${F("city_shrine_know",[(+t.add.toFixed(1)).toLocaleString()])}
    `,e+=`
    ${F("city_shrine_know2",[+(100*(t.mult-1)).toFixed(1)])}
    `}return t.city.shrine&&t.city.shrine.tax>0&&(e+=`
    ${F("city_shrine_tax",[+(100*(Lc("tax").mult-1)).toFixed(1)])}
    `),e},action(){if(Os($(this)[0])){if(t.city.shrine.count++,t.city.calendar.moon>0&&t.city.calendar.moon<7)t.city.shrine.morale++;else if(t.city.calendar.moon>7&&t.city.calendar.moon<14)t.city.shrine.metal++;else if(t.city.calendar.moon>14&&t.city.calendar.moon<21)t.city.shrine.know++;else if(t.city.calendar.moon>21)t.city.shrine.tax++;else switch(Math.floor(m(0,4))){case 0:t.city.shrine.morale++;break;case 1:t.city.shrine.metal++;break;case 2:t.city.shrine.know++;break;case 3:t.city.shrine.tax++}return!0}return!1}},meditation:{id:"city-meditation",title:F("city_meditation"),desc:F("city_meditation"),category:"commercial",reqs:{primitive:3},trait:["calm"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("meditation",e,50,1.2),Stone:e=>Yi("meditation",e,25,1.2),Furs:e=>Yi("meditation",e,8,1.2)},effect(){let e=t.resource.Zen.amount/(t.resource.Zen.amount+5e3);return`
    ${F("city_meditation_effect",[ui.calm.vars()[0]])}
    ${F("city_meditation_effect2",[2])}
    ${F("city_meditation_effect3",[1])}
    ${F("city_meditation_effect4",[`${(100*e).toFixed(2)}%`])}
    `},action(){return!!Os($(this)[0])&&(t.city.meditation.count++,t.resource.Zen.max+=ui.calm.vars()[0],!0)}},university:{id:"city-university",title:F("city_university"),desc:()=>F("city_university_desc",[di[t.race.species].home]),category:"science",reqs:{science:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("university",e,900,1.5)-500,Lumber:e=>Yi("university",e,500,1.36)-200,Stone:e=>Yi("university",e,750,1.36)-350,Crystal:e=>"magic"===t.race.universe?Yi("university",e,5,1.36):0,Iron:e=>(t.city.university?t.city.university.count:0)+(e||0)>=3&&t.city.ptrait.includes("unstable")?Yi("university",e,25,1.36):0},effect(){let e=+$(this)[0].knowVal().toFixed(0);return`
    ${F("city_university_effect",[la(1)])}
    ${F("city_max_knowledge",[e.toLocaleString()])}
    `},knowVal(){let e=1,a=t.tech.science&&t.tech.science>=8?700:500;t.city.ptrait.includes("permafrost")&&(a+=Si.permafrost.vars()[1]),t.tech.science>=4&&(e+=.02*t.city.library.count),t.space.observatory&&t.space.observatory.count>0&&(e+=.05*c.observatory),t.portal.sensor_drone&&t.tech.science>=14&&(e+=.02*i.sensor_drone),t.race.hard_of_hearing&&(e*=1-ui.hard_of_hearing.vars()[0]/100),t.race.curious&&(e*=1+ui.curious.vars()[0]/100*t.resource[t.race.species].amount);let r=Pi("cath");if(r>0&&(e*=1+ui.curious.vars(3)[0]*r),i.s_gate&&n.scavenger){let t=Et("gxy_alien2");e*=1+n.scavenger*t/4}let s=N("teacher",0);s&&(e*=1+s/100);let o=N("athleticism",2);o&&(e*=1-o/100),Kc()&&(e*=Lc("know").mult);let l=a*e;if(t.tech.supercollider){let e=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;l*=t.tech.supercollider/e+1}return t.race.orbit_decayed&&(t.space.satellite&&(l*=1+.12*t.space.satellite.count),t.tech.biotech&&t.tech.biotech>=1&&(l*=2)),l},action(){if(Os($(this)[0])){let e=t.tech.science&&t.tech.science>=8?700:500;if(t.tech.science>=4&&(e*=1+.02*t.city.library.count),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,t.city.university.count++,t.civic.professor.display=!0,t.civic.professor.max=t.city.university.count,!0}return!1}},library:{id:"city-library",title:F("city_library"),desc:()=>F("city_library_desc",[di[t.race.species].home]),category:"science",reqs:{science:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("library",e,45,1.2),Crystal:e=>"magic"===t.race.universe?Yi("library",e,2,1.2):0,Iron:e=>t.city.ptrait.includes("unstable")?Yi("library",e,4,1.2):0,Furs:e=>Yi("library",e,22,1.2),Plywood:e=>Yi("library",e,20,1.2),Brick:e=>Yi("library",e,15,1.2)},effect(){let e=125;t.race.nearsighted&&(e*=1-ui.nearsighted.vars()[0]/100),t.race.studious&&(e*=1+ui.studious.vars()[1]/100);let a=Pi("elven");if(a>0&&(e*=1+ui.studious.vars(1)[1]/100*a),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*t.city.temple.count),t.tech.science&&t.tech.science>=5){let a=na(t.civic.scientist.workers,"scientist");t.race.high_pop&&(a=Me(a)),e*=1+.12*a}let r=N("teacher",0);r&&(e*=1+r/100);let s=N("athleticism",2);s&&(e*=1-s/100);let i=N("muckraker",1);i&&(e*=1+i/100),e=+e.toFixed(0);let c=N("muckraker",2),o=c?5-c:5;return t.race.autoignition&&(o-=ui.autoignition.vars()[0],o<0&&(o=0)),`
    ${F("city_max_knowledge",[e.toLocaleString()])}
    ${F("city_library_effect",[o])}
    `},action(){if(Os($(this)[0])){let e=125;return t.race.nearsighted&&(e*=1-ui.nearsighted.vars()[0]/100),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*t.city.temple.count),t.tech.science&&t.tech.science>=5&&(e*=1+.12*na(t.civic.scientist.workers,"scientist")),e=+e.toFixed(1),t.resource.Knowledge.max+=e,t.city.library.count++,t.tech.science&&t.tech.science>=3&&(t.civic.professor.impact=.5+.01*t.city.library.count),!0}return!1},flair:F("city_library_flair")},wardenclyffe:{id:"city-wardenclyffe",title:()=>Ts(),desc:F("city_wardenclyffe_desc"),category:"science",reqs:{high_tech:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("wardenclyffe",e,5e3,1.22),Knowledge:e=>Yi("wardenclyffe",e,t.race.logical?1e3-ui.logical.vars()[0]:1e3,1.22),Crystal:e=>"magic"===t.race.universe?Yi("wardenclyffe",e,100,1.22):0,Copper:e=>Yi("wardenclyffe",e,500,1.22),Iron:e=>t.city.ptrait.includes("unstable")?Yi("wardenclyffe",e,75,1.22):0,Cement:e=>Yi("wardenclyffe",e,350,1.22),Sheet_Metal:e=>Yi("wardenclyffe",e,125,1.2),Nanite:e=>t.race.deconstructor?Yi("wardenclyffe",e,50,1.18):0},effect(){let e=1e3;if(t.city.ptrait.includes("magnetic")&&(e+=Si.magnetic.vars()[1]),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}t.space.satellite&&(e*=1+.04*t.space.satellite.count);let a=N("athleticism",2);a&&(e*=1-a/100),e=+e.toFixed(0);let r=`
    ${F("city_wardenclyffe_effect1",[la(1),t.civic.scientist?t.civic.scientist.name:F("job_scientist")])}
    ${F("city_max_knowledge",[e.toLocaleString()])}
    `;if(t.city.powered){let e=t.tech.science>=7?2500:2e3;if(t.city.ptrait.includes("magnetic")&&(e+=Si.magnetic.vars()[1]),t.space.satellite&&(e*=1+.04*t.space.satellite.count),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}let a=N("athleticism",2);if(a&&(e*=1-a/100),e=+e.toFixed(1),t.tech.science>=15&&(r+=`
    ${F("city_wardenclyffe_effect4",[2])}
    `),"magic"===t.race.universe&&(r+=`
    ${F("plus_max_resource",[Lr(8),t.resource.Mana.name])}
    `),t.tech.broadcast){let a=t.tech.broadcast;r+=`
    ${F("city_wardenclyffe_effect3",[$(this)[0].powered(),e.toLocaleString(),a])}
    `}else r+=`
    ${F("city_wardenclyffe_effect2",[$(this)[0].powered(),e.toLocaleString()])}
    `;t.race.artifical&&(r+=`
    ${F("city_transmitter_effect",[Lr(250)])}oc(2),action(){if(Os($(this)[0])){let e=1e3;if(t.city.wardenclyffe.count++,t.civic.scientist.display=!0,t.civic.scientist.max=t.city.wardenclyffe.count,xs($(this)[0])&&(e=t.tech.science>=7?2500:2e3),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,!0}return!1},flair:()=>"magic"===t.race.universe?`
    ${F("city_wizard_tower_flair")}
    `:t.race.evil?`
    ${F("city_babel_flair")}
    `:`
    ${F("city_wardenclyffe_flair1")}
    ${F("city_wardenclyffe_flair2")}
    `},biolab:{id:"city-biolab",title:F("city_biolab"),desc:`
    ${F("city_biolab_desc")}
    ${F("requires_power")}
    `,category:"science",reqs:{genetics:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("biolab",e,25e3,1.3),Knowledge:e=>Yi("biolab",e,5e3,1.3),Copper:e=>Yi("biolab",e,1250,1.3),Iron:e=>t.city.ptrait.includes("unstable")?Yi("biolab",e,160,1.3):0,Alloy:e=>Yi("biolab",e,350,1.3)},effect(){let e=3e3;return t.portal.sensor_drone&&t.tech.science>=14&&(e*=1+.02*i.sensor_drone),t.tech.science>=20&&(e*=3),t.tech.science>=21&&(e*=1.45),t.tech.biotech>=1&&(e*=2.5),e=+e.toFixed(0),`${F("city_max_knowledge",[e.toLocaleString()])}, ${F("minus_power",[$(this)[0].powered()])}`},powered:()=>oc(2),action(){return!!Os($(this)[0])&&(t.city.biolab.count++,xs($(this)[0])&&(t.resource.Knowledge.max+=3e3),!0)}},coal_power:{id:"city-coal_power",title:()=>t.race.environmentalist?F("city_hydro_power"):F("magic"===t.race.universe?"city_mana_engine":"city_coal_power"),desc:()=>t.race.environmentalist?`
    ${F("city_hydro_power_desc")}
    `:`
    ${F("magic"===t.race.universe?"city_mana_engine_desc":"city_coal_power_desc")}
    ${F("requires_res",[F("magic"===t.race.universe?"resource_Mana_name":"resource_Coal_name")])}
    `,category:"utility",reqs:{high_tech:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("coal_power",e,1e4,Fs(1.22)),Crystal:e=>"magic"===t.race.universe?Yi("coal_power",e,125,Fs(1.22)):0,Copper:e=>Yi("coal_power",e,1800,Fs(1.22))-1e3,Iron:e=>t.city.ptrait.includes("unstable")?Yi("coal_power",e,175,Fs(1.22)):0,Cement:e=>Yi("coal_power",e,600,Fs(1.22)),Steel:e=>Yi("coal_power",e,2e3,Fs(1.22))-1e3},effect(){let e="magic"===t.race.universe?.05:.35,a=-$(this)[0].powered();return t.race.environmentalist?`+${a}MW`:`+${a}MW. ${F("magic"===t.race.universe?"city_mana_engine_effect":"city_coal_power_effect",[e])}`},powered(){let e=t.race.environmentalist?t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1?-5:-4:t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1?-6:-5,a=N("dirty_jobs",1);return a&&(e-=a),cc(e)},p_fuel:()=>"magic"===t.race.universe?{r:"Mana",a:t.race.environmentalist?0:.05}:{r:"Coal",a:t.race.environmentalist?0:.35},action(){return!!Os($(this)[0])&&(t.city.coal_power.count++,t.city.coal_power.on++,t.city.power+=5,!0)}},oil_power:{id:"city-oil_power",title:()=>t.race.environmentalist?F("city_wind_power"):F("city_oil_power"),desc:()=>t.race.environmentalist?`
    ${F("city_wind_power_desc")}
    `:`
    ${F("city_oil_power_desc")}
    ${F("requires_res",[F("resource_Oil_name")])}
    `,category:"utility",reqs:{oil:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("oil_power",e,5e4,Fs(1.22)),Copper:e=>Yi("oil_power",e,6500,Fs(1.22))+1e3,Iron:e=>t.city.ptrait.includes("unstable")?Yi("oil_power",e,180,Fs(1.22)):0,Aluminium:e=>Yi("oil_power",e,12e3,Fs(1.22)),Cement:e=>Yi("oil_power",e,5600,Fs(1.22))+1e3},effect(){let e=-$(this)[0].powered();return t.race.environmentalist?`+${e}MW`:`+${e}MW. ${F("city_oil_power_effect",[.65])}`},powered(){let e=0;if(t.race.environmentalist)if(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3){let a=1===t.city.calendar.wind?-7:-5;e=t.stats.achieve.dissipated.l>=5?a-2:a-1}else e=1===t.city.calendar.wind?-7:-5;else e=t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3?t.stats.achieve.dissipated.l>=5?-8:-7:-6;let a=N("dirty_jobs",1);return a&&(e-=a),cc(e)},p_fuel:()=>({r:"Oil",a:t.race.environmentalist?0:.65}),action(){return!!Os($(this)[0])&&(t.city.oil_power.count++,t.city.oil_power.on++,t.city.power+=6,!0)}},fission_power:{id:"city-fission_power",title:F("city_fission_power"),desc:`
    ${F("city_fission_power_desc")}
    ${F("requires_res",[F("resource_Uranium_name")])}
    `,category:"utility",reqs:{high_tech:5},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("fission_power",e,25e4,1.36),Copper:e=>Yi("fission_power",e,13500,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("fission_power",e,1750,1.36):0,Cement:e=>Yi("fission_power",e,10800,1.36),Titanium:e=>Yi("fission_power",e,7500,1.36)},effect(){return`+${-$(this)[0].powered()}MW. ${F("city_fission_power_effect",[.1])}`},powered:()=>cc(t.tech.uranium>=4?-18:-14),p_fuel:()=>({r:"Uranium",a:.1}),action(){return!!Os($(this)[0])&&(t.city.fission_power.count++,t.city.fission_power.on++,t.city.power+=14,!0)}},mass_driver:{id:"city-mass_driver",title:F("city_mass_driver"),desc:`
    ${F("city_mass_driver_desc")}
    ${F("requires_power")}
    `,category:"utility",reqs:{mass:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("mass_driver",e,375e3,1.32),Copper:e=>Yi("mass_driver",e,33e3,1.32),Iron:e=>Yi("mass_driver",e,42500,1.32),Iridium:e=>Yi("mass_driver",e,2200,1.32)},effect(){return`${t.tech.mass>=2?`
    ${F("city_mass_driver_effect2",[1,t.civic.scientist.name])}
    `:""}${F("city_mass_driver_effect",[t.race.truepath?6:5,Ac("name")])} ${F("minus_power",[$(this)[0].powered()])}`},powered(){let e=t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=4?4:5;return oc(t.tech.mass>=2?e-1:e)},action(){return!!Os($(this)[0])&&(t.city.mass_driver.count++,xs($(this)[0]),!0)}},replicator:{id:"city-replicator",title:F("tech_replicator"),desc:F("tech_replicator"),category:"utility",reqs:{special_hack:1},cost:{},wiki:!1,effect:()=>"fake structure",powered:()=>1,action:()=>!1}},tech:Rr,arpa:Oe("PhysicsTech"),genes:Oe("GeneTech"),blood:Oe("BloodTech"),space:Dt(),interstellar:St,galaxy:At,starDock:{probes:{id:"starDock-probes",title:F("star_dock_probe"),desc:()=>`
    ${F("star_dock_probe_desc")}
    `,reqs:{genesis:4},cost:{Money:e=>Yi("probes",e,35e4,t.race.truepath?1.125:1.25,"starDock"),Alloy:e=>Yi("probes",e,75e3,t.race.truepath?1.125:1.25,"starDock"),Polymer:e=>Yi("probes",e,85e3,t.race.truepath?1.125:1.25,"starDock"),Iridium:e=>Yi("probes",e,12e3,t.race.truepath?1.125:1.25,"starDock"),Mythril:e=>Yi("probes",e,3500,t.race.truepath?1.125:1.25,"starDock")},effect:()=>`
    ${F("star_dock_probe_effect")}
    `,action(){return!!Os($(this)[0])&&(t.starDock.probes.count++,!0)}},geck:{id:"starDock-geck",title:F("tech_geck"),desc:()=>`
    ${F("tech_geck_desc")}
    `,reqs:{geck:1},condition:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5),queue_complete:()=>0,no_multi:!0,cost:{Money:e=>Yi("geck",e,1e6,1.25,"starDock"),Elerium:e=>Yi("geck",e,1e3,1.25,"starDock"),Plasmid:e=>Yi("geck",e,25,1.4,"starDock")},effect:()=>`
    ${F("star_dock_geck_effect")}
    `,action(){return!!Os($(this)[0])&&(t.starDock.geck.count++,!0)}},seeder:{id:"starDock-seeder",title:()=>t.race.cataclysm?F("star_dock_exodus"):F("star_dock_seeder"),desc(){let e=t.race.cataclysm?F("star_dock_exodus"):F("star_dock_seeder");return t.starDock.seeder&&t.starDock.seeder.count>=100?`
    ${e}
    ${F("star_dock_seeder_desc2")}
    `:`
    ${e}
    ${F("star_dock_seeder_desc1")}
    `},reqs:{genesis:5},queue_size:10,queue_complete:()=>100-t.starDock.seeder.count,cost:{Money:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?1e5:0,Steel:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?25e3:0,Neutronium:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?240:0,Elerium:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?10:0,Nano_Tube:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?12e3:0},effect(e){let a=(e||0)+(t.starDock.seeder?t.starDock.seeder.count:0),r=a<100?F("star_dock_seeder_status1",[100-a]):F("star_dock_seeder_status2");return`
    ${t.race.cataclysm?F("star_dock_exodus_effect"):F("star_dock_seeder_effect")}
    ${r}
    `},action(){return!!(t.starDock.seeder.count<100&&Os($(this)[0]))&&(t.starDock.seeder.count++,t.starDock.seeder.count>=100&&(t.tech.genesis=6,Ei("starDock-seeder"),rc($("#modalBox")),zs(Qr.space.spc_gas.star_dock,"star_dock")),!0)}},prep_ship:{id:"starDock-prep_ship",title:F("star_dock_prep"),desc:()=>`
    ${t.race.cataclysm?F("star_dock_prep_cata_desc"):F("star_dock_prep_desc")}
    ${F("star_dock_genesis_desc2")}
    `,reqs:{genesis:6},queue_complete:()=>0,cost:{},effect(){let e=mc("bioseed"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
    ${t.race.cataclysm?F("star_dock_prep_cata_effect"):F("star_dock_prep_effect")}
    ${F("star_dock_genesis_effect2",[e.plasmid,a])}
    ${F("star_dock_genesis_effect3",[e.phage])}
    `},action:()=>(t.tech.genesis=7,Ei("starDock-prep_ship"),rc($("#modalBox")),zs(Qr.space.spc_gas.star_dock,"star_dock"),!0)},launch_ship:{id:"starDock-launch_ship",title:F("star_dock_genesis"),desc:()=>`
    ${t.race.cataclysm?F("star_dock_prep_cata_effect"):F("star_dock_genesis_desc1")}
    ${F("star_dock_genesis_desc2")}
    `,reqs:{genesis:7},queue_complete:()=>0,cost:{},effect(){let e=mc("bioseed"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
    ${t.race.cataclysm?F("star_dock_genesis_cata_effect1"):F("star_dock_genesis_effect1")}
    ${F("star_dock_genesis_effect2",[e.plasmid,a])}
    ${F("star_dock_genesis_effect3",[e.phage])}
    `},action:()=>(function(){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"bioseed"});let a=t.race.species,r=t.race.gods,s=di[a].type,i=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,n=mc("bioseed");t.stats.bioseed++,Fc(),t.prestige.Phage.count+=n.phage,t.stats.phage+=n.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=n.plasmid,t.stats.antiplasmid+=n.plasmid):(t.prestige.Plasmid.count+=n.plasmid,t.stats.plasmid+=n.plasmid),Xc("seeder"),Xc(`biome_${c}`),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),Xc(`genus_${s}`),t.race.truepath&&Xc("exodus"),o.includes("dense")&&"heavy"===t.race.universe&&Xc("double_density"),t.race.junker&&"junker"===t.race.species&&eo("organ_harvester"),"hellscape"===t.city.biome&&"demonic"!==di[t.race.species].type&&eo("ill_advised"),void 0===t.tech.world_control&&Xc("cult_of_personality"),t.race.cataclysm&&Xc("iron_will",!1,5),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross");let l=0,u=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0?l++:t.city.geology[e]<0&&u++})),l>=4&&Xc("miners_dream"),u>=3&&eo("rocky_road"),t.race.steelen&&t.race.steelen>=1&&Xc("steelen"),"micro"===t.race.universe&&(t.race.small||t.race.compact?Xc("macro",!0):Xc("marble",!0)),so();let d=!!t.race.hasOwnProperty("srace")&&t.race.srace,_=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0,p=t.starDock.probes.count+1,h=t.starDock.hasOwnProperty("geck")?t.starDock.geck.count:0;t.stats.achieve.explorer&&(p+=t.stats.achieve.explorer.l),t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!0,probes:p,geck:h,seed:Math.floor(m(1e4)),ascended:!1},_>0&&(t.race.corruption=_),d&&(t.race.srace=d),Q({orbit:i,biome:c,ptrait:o,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),!1)}},portal:wa(),tauceti:Ze};function Zr(){let a=$("#evolution .evolving").nextAll();Object.values(a).forEach((function(e){rc($(e),!0)})),rc($("#evolution .evolving"),!0),t.evolution.bunker={count:1},Ms(Qr.evolution.bunker.id),As(),t.race.truepath||t.race.lone_survivor?(t.evolution.nerfed={count:0},t.evolution.badgenes={count:0}):("antimatter"===t.race.universe?t.evolution.mastery={count:0}:t.evolution.plasmid={count:0},t.evolution.crispr={count:0}),t.evolution.trade={count:0},t.evolution.craft={count:0},t.evolution.junker={count:0},t.evolution.joyless={count:0},t.evolution.steelen={count:0},(t.stats.achieve.whitehole||t.sim)&&(t.evolution.decay={count:0}),(t.stats.achieve.ascended||t.sim)&&(t.evolution.emfield={count:0}),(t.stats.achieve.scrooge||t.sim)&&(t.evolution.inflation={count:0}),(t.stats.achieve.shaken||t.sim)&&(t.evolution.cataclysm={count:0}),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&(t.evolution.banana={count:0},t.evolution.orbit_decay={count:0}),"standard"===t.race.universe&&(t.stats.achieve.whitehole||t.sim),"heavy"===t.race.universe&&(t.stats.achieve.seeder&&t.stats.achieve.seeder.h||t.sim),"magic"===t.race.universe&&(t.stats.achieve.ascended&&t.stats.achieve.ascended.mg||t.sim)&&(t.evolution.witch_hunter={count:0}),"evil"===t.race.universe&&(t.stats.achieve.corrupted&&t.stats.achieve.corrupted.e||t.sim),(t.stats.achieve.ascended||t.stats.achieve.corrupted||t.sim)&&(t.evolution.truepath={count:0}),((t.stats.achieve.ascended||t.stats.achieve.corrupted)&&t.stats.achieve.extinct_junker||t.sim)&&(t.evolution.sludge={count:0}),(t.stats.achieve.bluepill||t.sim)&&(t.evolution.simulation={count:0}),(t.stats.achieve.retired||t.sim)&&(t.evolution.lone_survivor={count:0}),function(){let e=$('
    ');$("#evolution").append(e),e.append($(`

    ${F("evo_challenge_genes")}

    `)),e.append($(`
    ${F("evo_challenge_genes_desc")}
    `)),t.genes.challenge&&t.genes.challenge>=2&&e.append($(`
    ${F("evo_challenge_genes_mastery")}
    `))}(),t.race.truepath||t.race.lone_survivor?gs("evolution","nerfed"):"antimatter"===t.race.universe?gs("evolution","mastery"):gs("evolution","plasmid"),gs("evolution","trade"),gs("evolution","craft"),t.race.truepath||t.race.lone_survivor?gs("evolution","badgenes"):gs("evolution","crispr"),function(){let e=$('
    ');$("#evolution").append(e),e.append($(`

    ${F("evo_challenge_run")}

    `)),e.append($(`
    ${F("evo_challenge_run_desc")}
    `))}(),gs("evolution","joyless"),gs("evolution","steelen"),(t.stats.achieve.whitehole||t.sim)&&gs("evolution","decay"),(t.stats.achieve.ascended||t.sim)&&gs("evolution","emfield"),(t.stats.achieve.scrooge||t.sim)&&gs("evolution","inflation"),((t.stats.achieve.ascended||t.stats.achieve.corrupted)&&t.stats.achieve.extinct_junker||t.sim)&&gs("evolution","sludge"),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&gs("evolution","orbit_decay"),"standard"===t.race.universe&&(t.stats.achieve.whitehole||t.sim),"heavy"===t.race.universe&&(t.stats.achieve.seeder&&t.stats.achieve.seeder.h||t.sim),"magic"===t.race.universe&&(t.stats.achieve.ascended&&t.stats.achieve.ascended.mg||t.sim)&&gs("evolution","witch_hunter"),"evil"===t.race.universe&&(t.stats.achieve.corrupted&&t.stats.achieve.corrupted.e||t.sim),t.hasOwnProperty("beta")&&!t.sim&&gs("evolution","simulation"),function(){let e=$('
    ');$("#evolution").append(e),e.append($(`

    ${F("evo_scenario")}

    `)),e.append($(`
    ${F("evo_scenario_desc")}
    `))}(),gs("evolution","junker"),(t.stats.achieve.shaken||t.sim)&&gs("evolution","cataclysm"),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&gs("evolution","banana"),(t.stats.achieve.ascended||t.stats.achieve.corrupted||t.sim)&&gs("evolution","truepath"),(t.stats.achieve.retired||t.sim)&&gs("evolution","lone_survivor"),t.sim?function(){let a=$('
    ');$("#evolution").append(a),a.append($(`

    ${F("evo_challenge_simulation")}

    `)),a.append($(`
    ${F("evo_challenge_simulation_desc")}
    `)),a.append($(``)),sc({el:"#simSection",data:{},methods:{exitsim(){t.hasOwnProperty("sim")&&(t.stats=zc(t.sim.stats),t.prestige=zc(t.sim.prestige),t.genes=zc(t.sim.genes),t.blood=zc(t.sim.blood),t.pillars=zc(t.sim.pillars),t.race=zc(t.sim.race),delete t.sim,t.race.species="protoplasm",delete t.race.simulation,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload())}}})}():t.race.simulation&&function(){let e=$('
    ');$("#evolution").append(e),e.append($(`

    ${F("evo_challenge_simulation")}

    `)),e.append($(`
    ${F("evo_challenge_simulation_desc")}
    `));let a=$($('
    '));e.append(a),t.race.simConfig||(t.race.simConfig={}),["Plasmid","AntiPlasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone"].forEach((function(e){t.race.simConfig[e]=t.race.simConfig[e]||0,a.append($(`
    ${F(`resource_${e}_name`)}
    `))})),sc({el:"#simSection",data:t.race.simConfig})}()}function Vr(e,a){let r=t.race.orbit_decay?"orbit_decayed":"cataclysm",s=function(e,t,a){return"space"===a?e.hasOwnProperty("trait")?e.trait.push(t):e.trait=[t]:"tauceti"===a?e.reqs.isolation=1:e.hasOwnProperty("not_trait")?e.not_trait.push(t):e.not_trait=[t],e};switch(e){case"bonfire":return s({id:`${a}-bonfire`,title:F("city_bonfire"),desc:F("city_bonfire_desc"),category:"outskirts",wiki:!1,reqs:{primitive:3},condition:()=>Tc("summer"),queue_complete:()=>0,effect(){let e=2.5*t.resource.Thermite.diff/(2.5*t.resource.Thermite.diff+500)*500,a=1e5+9e3*t.stats.reset;a>1e6&&(a=1e6);let r=t.resource.Thermite.amount${F("city_bonfire_effect3",[a.toLocaleString()])}
    ${F("city_bonfire_effect4",[(+t.resource.Thermite.amount.toFixed(0)).toLocaleString(),a.toLocaleString()])}
    `:"";return`
    ${F("city_bonfire_effect",[t.resource.Thermite.diff])}
    ${F("city_bonfire_effect2",[+e.toFixed(1)])}
    ${r}`},action:()=>!1,flair:()=>F("city_bonfire_flair")},r,a);case"firework":return s({id:`${a}-firework`,title:F("city_firework"),desc:F("city_firework"),category:"outskirts",wiki:!1,reqs:{mining:3},condition:()=>Tc("firework")&&(t.tech.cement||t.race.flier),cost:{Money:()=>0===t[a].firework.count?5e4:0,Iron:()=>0===t[a].firework.count?7500:0,Cement:()=>0===t[a].firework.count?1e4:0},queue_complete:()=>1-t[a].firework.count,switchable:()=>!0,effect:()=>0===t[a].firework.count?F("city_firework_build"):F("city_firework_effect"),action(){return!(0!==t[a].firework.count||!Os($(this)[0])||(t[a].firework.count=1,0))}},r,a);case"assembly":{let e=function(e){let a=Me(e);return t.race.promiscuous&&(a/=1+ui.promiscuous.vars()[1]*t.race.promiscuous),Math.round(a)};return s({id:`${a}-assembly`,title:F("city_assembly"),desc:()=>F("city_assembly_desc",[di[t.race.species].name]),category:"military",reqs:{},trait:["artifical"],queue_complete:()=>t.resource[t.race.species].max-t.resource[t.race.species].amount,cost:{Money:a=>t.resource[t.race.species].amount?Yi("citizen",a,e(125),1.01):0,Copper:a=>t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Yi("citizen",a,e(50),1.01):0,Aluminium:a=>t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Yi("citizen",a,e(50),1.01):0,Nanite:a=>t.race.deconstructor&&t.resource[t.race.species].amount>=3?Yi("citizen",a,e(500),1.01):0},effect(){let e="";return t.resource[t.race.species].max===t.resource[t.race.species].amount&&(e=`
    ${F("city_assembly_effect_warn")}
    `),`
    ${F("city_assembly_effect",[di[t.race.species].name])}
    ${e}`},action(){return!!(t.race.vax&&t.race.vax>=100)||!!(t.resource[t.race.species].max>t.resource[t.race.species].amount&&Os($(this)[0]))&&(t.resource[t.race.species].amount++,!0)}},r,a)}case"nanite_factory":return s({id:`${a}-nanite_factory`,title:F("city_nanite_factory"),desc:F("city_nanite_factory"),category:"industrial",reqs:{},trait:["deconstructor"],region:"city",cost:{Money:e=>Yi("nanite_factory",e,25e3,Fs(1.25)),Copper:e=>Yi("nanite_factory",e,1200,Fs(1.25)),Steel:e=>Yi("nanite_factory",e,1e3,Fs(1.25))},effect(){let e=Lr(2500);return`
    ${F("city_nanite_factory_effect",[t.resource.Nanite.name])}
    ${F("plus_max_resource",[e,t.resource.Nanite.name])}.
    `},special:!0,action(){return!!Os($(this)[0])&&(t.city.nanite_factory.count++,t.settings.showIndustry=!0,Ws(),!0)},flair:F("city_nanite_factory_flair")},r,a);case"captive_housing":return s({id:`${a}-captive_housing`,title:F("city_captive_housing"),desc:F("city_captive_housing_desc"),category:"residential",reqs:{unfathomable:1},trait:["unfathomable"],region:"city",cost:{Money:e=>Yi("captive_housing",e,40,1.35),Lumber:e=>Yi("captive_housing",e,30,1.35),Stone:e=>Yi("captive_housing",e,18,1.35)},effect(){let e="";t.race.artifical||t.race.detritivore||t.race.carnivore||t.race.soul_eater||(e+=`
    ${F("city_captive_housing_cattle",[t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.cattle:0,t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.cattleCap:0])}
    `);let a=0;if(t.city.hasOwnProperty("surfaceDwellers"))for(let r=0;r${F("city_captive_housing_broken",[di[s].name,i])}`,e+=`
    ${F("city_captive_housing_untrained",[di[s].name,c])}
    `}return e+=`
    ${F("city_captive_housing_capacity",[a,t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.raceCap:0])}
    `,t.tech.unfathomable&&t.tech.unfathomable>=2&&(e+=`
    ${F("plus_max_resource",[1,F("job_torturer")])}
    `),e},action(){if(Os($(this)[0])){t.city.captive_housing.count++;let e=t.city.captive_housing.count;return t.city.captive_housing.raceCap=e*(t.tech.unfathomable&&t.tech.unfathomable>=3?3:2),t.city.captive_housing.cattleCap=5*e,!0}return!1}},r,a);case"horseshoe":return s({id:`${a}-horseshoe`,title:()=>F(`city_${Bc(!0)}`,[Bc(!1)]),desc:()=>F(`city_${Bc(!0)}_desc`,[Bc(!1)]),category:"outskirts",reqs:{primitive:3},condition:()=>t.race.hooved||Tc("fool",2023),inflation:!1,cost:{Lumber(e){let a=(t.race.shoecnt||0)+(e||0);return t.race.kindling_kindred||t.race.smoldering||t.resource.Copper.display&&!(a<=12)?0:Math.round((a>12?25:5)*(a<=5?1:a-4)*(ui.hooved.vars()[0]/100))},Copper(e){let a=(t.race.shoecnt||0)+(e||0),r=!t.race.kindling_kindred&&!t.race.smoldering;return(!r||r&&a>12&&t.resource.Copper.display)&&(!t.resource.Iron.display||a<=75)?Math.round((a>75?20:5)*(a<=12?1:a-11)*(ui.hooved.vars()[0]/100)):0},Iron(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Iron.display&&a>75&&(!t.resource.Steel.display||a<=150)?Math.round((a<=150?12:28)*a*(ui.hooved.vars()[0]/100)):0},Steel(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Steel.display&&a>150&&(!t.resource.Adamantite.display||a<=500)?Math.round((a<=500?40:100)*a*(ui.hooved.vars()[0]/100)):0},Adamantite(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Adamantite.display&&a>500&&(!t.resource.Orichalcum.display||a<=5e3)?Math.round((a<=5e3?5:25)*a*(ui.hooved.vars()[0]/100)):0},Orichalcum(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Orichalcum.display&&a>5e3?Math.round((25*a-12e4)*(ui.hooved.vars()[0]/100)):0}},action(){return!(t.race.hooved||!Tc("fool",2023))||!(!t.resource.Horseshoe.display||!Os($(this)[0]))&&(t.resource.Horseshoe.amount++,t.race.shoecnt++,!(5001===t.race.shoecnt&&t.resource.Orichalcum.display||501===t.race.shoecnt&&t.resource.Adamantite.display||151===t.race.shoecnt&&t.resource.Steel.display||76===t.race.shoecnt&&t.resource.Iron.display||13===t.race.shoecnt&&t.resource.Copper.display&&t.resource.Lumber.display)||0)}},r,a)}}function Jr(e,a){a=a||"evo";let r=t.evolution.final||0;return(t.tech[a]&&t.tech[a]===e||t.evolution.gselect)&&r<100}const Yr=["human","orc","elven","troll","ogre","cyclops","kobold","goblin","gnome","cath","wolven","vulpine","centaur","rhinotaur","capybara","tortoisan","gecko","slitheryn","arraak","pterodacti","dracnid","sporgar","shroomi","moldling","mantis","scorpid","antid","entish","cacti","pinguicula","sharkin","octigoran","dryad","satyr","phoenix","salamander","yeti","wendigo","tuskin","kamel","imp","balorg","seraph","unicorn","synth","nano","ghast","shoggoth","custom"];if(Yr.forEach((e=>Qr.evolution[e]={id:`evolution-${e}`,title:()=>di[e].name,desc:()=>`${F("evo_evolve")} ${di[e].name}`,reqs:{evo:7},grant:["evo",8],condition:()=>(t.race.seeded||t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>=1||t.stats.achieve[`extinct_${e}`]&&t.stats.achieve[`extinct_${e}`].l>=1)&&t.tech[`evo_${di[e].type}`]>=2&&100===t.evolution.final&&!t.race.evoFinalMenu,cost:{RNA:()=>320,DNA:()=>320},race:!0,effect:()=>`${"string"==typeof di[e].desc?di[e].desc:di[e].desc()} ${F("evo_complete")}`,action(){if(Os($(this)[0])){if(["synth","custom"].includes(e))return function(e){if(("synth"===e||"custom"===e&&t.custom.race0.traits.includes("imitation"))&&Object.keys(t.stats.synth).length>1)return t.race.evoFinalMenu=e,ts(),!0;t.race.species=e,Ls()}(e);t.race.species=e,Ls()}return!1},queue_complete:()=>t.tech.evo&&7===t.tech.evo?1:0,emblem:()=>Pc(`extinct_${e}`)})),Object.keys(t.stats.synth).length>1){let e=zc(Yr);e.push("junker"),e.push("sludge"),e.forEach((e=>Qr.evolution[`s-${e}`]={id:`evolution-s-${e}`,title:()=>di[e].name,desc:()=>`${F("evo_imitate")} ${di[e].name}`,reqs:{evo:8},grant:["evo",9],condition:()=>t.stats.synth[e]&&t.race.evoFinalMenu,cost:{},race:!0,effect:()=>F("evo_imitate_race",[di[e].name]),action:()=>(t.stats.synth[e]&&(t.race.species=t.race.evoFinalMenu,t.race.srace=e,Ls()),!1),queue_complete:()=>t.tech.evo&&8===t.tech.evo?1:0}))}const Xr={plasmid:"no_plasmid",mastery:"weak_mastery",trade:"no_trade",craft:"no_craft",crispr:"no_crispr",nerfed:"nerfed",badgenes:"badgenes"};Object.keys(Xr).forEach((e=>Qr.evolution[e]={id:`evolution-${e}`,title:F(`evo_challenge_${e}`),desc:F(`evo_challenge_${e}`),condition:()=>t.evolution.hasOwnProperty(e),cost:{DNA:()=>10},challenge:!0,effect:()=>as(e),action(){return Os($(this)[0])&&(t.race[Xr[e]]?(delete t.race[Xr[e]],$(`#${$(this)[0].id}`).removeClass("hl"),(t.race.truepath||t.race.lone_survivor)&&(delete t.race.nerfed,delete t.race.badgenes),["junker","cataclysm","banana","truepath","lone_survivor"].forEach((function(e){delete t.race[e],$(`#evolution-${e}`).removeClass("hl")}))):(t.race[Xr[e]]=1,$(`#${$(this)[0].id}`).addClass("hl")),Zr(),ao()),!1},highlight:()=>!!t.race[Xr[e]],queue_complete:()=>0}));const es={joyless:{t:"c",e:"joyless"},steelen:{t:"c",e:"steelen"},decay:{t:"c",e:"dissipated"},emfield:{t:"c",e:"technophobe"},inflation:{t:"c",e:"wheelbarrow"},sludge:{t:"c",e:"extinct_sludge"},orbit_decay:{t:"c",e:"lamentis"},witch_hunter:{t:"c",e:"soul_sponge"},simulation:{t:"c",e:"thereisnospoon"},junker:{t:"s",e:"extinct_junker"},cataclysm:{t:"s",e:"iron_will"},banana:{t:"s",e:"banana"},truepath:{t:"s",e:"pathfinder"},lone_survivor:{t:"s",e:"adam_eve"}};function ts(){if((t.settings.tabLoad||0===t.settings.civTabs)&&"bigbang"!==t.race.universe&&(!t.race.seeded||t.race.chose)){if(t.tech.evo_challenge){let e=$("#evolution .evolving").nextAll();Object.values(e).forEach((function(e){rc($(e),!0)})),rc($("#evolution .evolving"),!0)}Object.keys(Qr.evolution).forEach((function(e){if(!Qr.evolution[e].challenge){Ms(Qr.evolution[e].id);var a=!0;Qr.evolution[e].hasOwnProperty("reqs")&&Object.keys(Qr.evolution[e].reqs).forEach((function(r){(!t.tech[r]||t.tech[r]=2&&As(),t.tech.evo_challenge&&Zr())}}function as(e){switch(e){case"nerfed":return F(`evo_challenge_${e}_effect`,"antimatter"===t.race.universe?["20%","50%","50%","33%"]:["50%","20%","50%","33%"]);case"badgenes":return F(`evo_challenge_${e}_effect`,[1,2]);case"orbit_decay":return lc()>=100?`
    ${F("evo_challenge_orbit_decay_effect",[5e3])}
    ${F("evo_challenge_scenario_failwarn")}
    `:`
    ${F("evo_challenge_orbit_decay_effect",[5e3])}
    ${F("evo_challenge_scenario_failwarn")}
    ${F("evo_challenge_scenario_warn")}
    `;case"junker":return"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
    ${F("evo_challenge_junker_effect")}
    ${F("evo_warn_unwise")}
    `:F("evo_challenge_junker_effect");case"cataclysm":return lc()>=50?`
    ${F("evo_challenge_cataclysm_effect")}
    ${F("evo_challenge_cataclysm_warn")}
    `:`
    ${F("evo_challenge_cataclysm_effect")}
    ${F("evo_challenge_scenario_warn")}
    `;default:return F(`evo_challenge_${e}_effect`)}}function rs(){let e;if("antimatter"===t.race.universe||t.race.no_plasmid){let a=t.tech.anthropology&&t.tech.anthropology>=1?1.6:1;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=na(t.civic.professor.workers,"professor")*("antimatter"===t.race.universe?.02:.04);t.race.high_pop&&(e=Me(e)),a+=+e.toFixed(2)}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.015:t.genes.ancients>=3?.0125:.01;t.race.high_pop&&(e=Me(e)),a+=e*na(t.civic.priest.workers,"priest")}"antimatter"===t.race.universe&&(a/=2),t.race.spiritual&&(a*=1+ui.spiritual.vars()[0]/100);let r=Pi("seraph");if(r>0&&(a*=1+ui.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1+ae.theocracy()[0]/100),t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),a=+a.toFixed(3),e=`
    ${F("city_temple_effect1",[a])}
    `,"antimatter"===t.race.universe){let a=6;if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.12:t.genes.ancients>=3?.1:.08;t.race.high_pop&&(e=Me(e)),a+=e*na(t.civic.priest.workers,"priest")}e+=`
    ${F("city_temple_effect5",[a.toFixed(2)])}
    `}}else{let a=t.tech.anthropology&&t.tech.anthropology>=1?8:5;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=.2*na(t.civic.professor.workers,"professor");t.race.high_pop&&(e=Me(e)),a+=+e.toFixed(1)}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.15:t.genes.ancients>=3?.125:.1;t.race.high_pop&&(e=Me(e)),a+=e*na(t.civic.priest.workers,"priest")}t.race.spiritual&&(a*=1+ui.spiritual.vars()[0]/100);let r=Pi("seraph");r>0&&(a*=1+ui.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1+ae.theocracy()[0]/100),t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),t.race.orbit_decayed&&t.race.truepath&&(a*=.1),a=+a.toFixed(3),e=`
    ${F("city_temple_effect2",[a])}
    `}return t.tech.fanaticism&&t.tech.fanaticism>=3&&(e+=`
    ${F("city_temple_effect3")}
    `),t.tech.anthropology&&t.tech.anthropology>=4&&(e+=`
    ${t.race.truepath?F("city_temple_effect_tp",[2,25]):F("city_temple_effect4")}
    `),e}function ss(){let e=t.tech.gambling>=3?6e4:4e4;t.tech.gambling>=5&&(e+=t.tech.gambling>=6?24e4:6e4),e=Lr(e),t.race.gambler&&(e*=1+.04*t.race.gambler),t.tech.world_control&&(e*=1.25),t.race.truepath&&(e*=1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(e*=1+.05*t.tech.stock_exchange),t.race.inflation&&(e*=1+t.race.inflation/100),t.tech.isolation&&(e*=5.5),e=Math.round(e);let a=t.race.joyless?"":`
    ${F("city_max_entertainer",[la(1)])}
    `,r=t.race.orbit_decayed||t.tech.isolation?`
    ${F("plus_max_resource",[la(1),F("banker_name")])}
    `:"",s=`
    ${F("plus_max_resource",[`$${e.toLocaleString()}`,F("resource_Money_name")])}
    ${a}${r}
    ${F("city_max_morale",[1])}
    `,i=Math.log2(1+t.resource[t.race.species].amount)*(t.race.gambler?2.5+t.race.gambler/10:2.5);return t.tech.gambling&&t.tech.gambling>=2&&(i*=t.tech.gambling>=5?2:1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(i*=1+.01*t.tech.stock_exchange),"corpocracy"===t.civic.govern.type&&(i*=3),"socialist"===t.civic.govern.type&&(i*=.8),t.race.inflation&&(i*=1+t.race.inflation/1250),t.tech.isolation&&(i*=1.25,t.tech.iso_gambling&&(i*=1+.05*na(t.civic.banker.workers,"banker"))),i=+i.toFixed(2),s+=`
    ${F("tech_casino_effect2",[i])}
    `,s}function is(e,a,r,s){return((t.evolution.hasOwnProperty(e)?t.evolution[e].count:0)+(s||0))*r+a}function cs(e){return t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),Math.round(e)}function os(){let e=1.25*(t.tech.storage-1)+1;t.tech.storage>=3&&(e*=t.tech.storage>=4?3:1.5),t.race.pack_rat&&(e*=1+ui.pack_rat.vars()[1]/100);let a=Pi("kobold");return a>0&&(e*=1+ui.pack_rat.vars(1)[1]/100*a),t.tech.storage>=6&&(e*=1+t.tech.supercollider/20),t.tech.tp_depot&&(e*=1+t.tech.tp_depot/20),t.tech.shelving&&t.tech.shelving>=3&&(e*=1.5),t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),e*=t.tech.world_control?3:1,t.race.ascended&&(e*=1.1),t.blood.hoarder&&(e*=1+t.blood.hoarder/100),t.tech.storage>=7&&t.interstellar.cargo_yard&&(e*=1+t.interstellar.cargo_yard.count*u/100),e}function ns(e){if((t.race.kindling_kindred||t.race.smoldering)&&"lumber"===e)return!1;if((t.race.kindling_kindred||t.race.smoldering)&&"stone"===e)return!0;let a=t.race.truepath?"truepath":"standard";if(Qr.city[e].hasOwnProperty("path")&&!Qr.city[e].path.includes(a))return!1;var r=!0;return Object.keys(Qr.city[e].reqs).forEach((function(a){(!t.tech[a]||t.tech[a]=3&&(s=!0,t.r_queue.queue.forEach((function(e){us(e.type,!1)&&(a[Qr[e.action][e.type].grant[0]]={v:Qr[e.action][e.type].grant[1],a:e.type})})),Object.keys(i).forEach((function(r){let i=t.tech[r]||0;ls(r,t.tech[r])||(!a[r]||a[r].vi+1)&&(s=!1)}))),!(!r&&!s||t.tech[Qr.tech[e].grant[0]]&&!(t.tech[Qr.tech[e].grant[0]]`).appendTo("#city").append(`

    ${F(`city_dist_${a}`)}

    `),e[a].forEach((function(e){gs("city",e)})),Ti(`dist-${a}`,(function(){return F(`city_dist_${a}_desc`)}),{elm:`#city-dist-${a} h3`,classes:"has-background-light has-text-dark"})}}))}function ms(){if(!t.settings.tabLoad&&3!==t.settings.civTabs)return;let e={},a={},r={},s=[],i=[],c=[];["primitive","civilized","discovery","industrialized","globalized","early_space","deep_space","interstellar","intergalactic"].forEach((function(e){r[e]=[]}));const o={interstellar:"solar"};let n={};Object.keys(Qr.tech).forEach((function(l){if(!function(e){let a=t.race.truepath?"truepath":"standard";return!(!Wr[a].includes(Qr.tech[e].era)&&!Qr.tech[e].hasOwnProperty("path")||Qr.tech[e].hasOwnProperty("path")&&!Qr.tech[e].path.includes(a))}(l))return;Ms(Qr.tech[l].id);let u=function(e){let a=Qr.tech[e].grant[0];if(t.tech[a]&&t.tech[a]>=Qr.tech[e].grant[1]){if("fanaticism"!==e&&"anthropology"!==e&&"deify"!==e&&"study"!==e)return!0;if("fanaticism"===e&&t.tech.fanaticism)return!0;if("anthropology"===e&&t.tech.anthropology)return!0;if("deify"===e&&t.tech.ancient_deify)return!0;if("study"===e&&t.tech.ancient_study)return!0}return!1}(l),d=Qr.tech[l],_="category"in d?d.category:"research";if(u||-1!==s.indexOf(_)||s.push(_),u&&-1===i.indexOf(_)&&i.push(_),-1===c.indexOf(_)&&c.push(_),!0===u)_ in a||(a[_]=[]),a[_].push(l);else{let a=Qr.tech[l];if(!ds(a))return;let s=us(l,n);if(!s)return;_ in e||(e[_]=[]);let i=t.race.truepath&&o[a.era]?o[a.era]:a.era;r.hasOwnProperty(i)||(r[i]=[]),r[i].push({t:l,p:"precog"===s})}})),rc($("#tech")),Object.keys(r).forEach((function(e){r[e].length>0&&($("#tech").append(`

    ${F(`tech_era_${e}`)}

    `),r[e].sort((function(e,t){return null==Qr.tech[e.t].cost.Knowledge?-1:null==Qr.tech[t.t].cost.Knowledge||Qr.tech[e.t].cost.Knowledge()>Qr.tech[t.t].cost.Knowledge()?1:-1})),r[e].forEach((function(e){gs("tech",e.t,!1,!!e.p&&n)})))})),c.forEach((function(e){rc($(`#tech-dist-${e}`),!0),rc($(`#tech-dist-old-${e}`),!0)})),i.forEach((function(e){if(!(e in a))return;$(`
    `).appendTo("#oldTech").append(`

    ${F(`tech_dist_${e}`)}

    `);let t=kc(4,12,!1);t.length>0&&"science"===e&&$("#tech-dist-old-science h3").append(t),a[e].forEach((function(e){gs("tech",e,!0,!1)}))}))}function gs(e,t,a,r){fs(Qr[e][t],e,t,a,r)}function fs(e,a,r,s,i){if(!1===ds(e))return;let c=a;"outerSol"===a&&(a="space"),e.region&&(a=e.region),e.powered&&!t[a][r].on&&(t[a][r].on=0);let o=e.id;Ms(o);let n="";i&&e&&e.reqs&&Object.keys(e.reqs).forEach((function(e){i[e]&&(n+=` data-req-${e}="${i[e].a}"`)}));let l,u=e.highlight&&e.highlight()?$(`
    `):$(`
    `);if(Cs(e,!1,["genes","blood"].includes(a))||u.addClass("cna"),Cs(e,!0,["genes","blood"].includes(a))||u.addClass("cnam"),s)l=$('{{ title }}');else{let t="",r="";if(e.cost){let s="genes"!==a&&"blood"!==a?gc(e):e.cost;Object.keys(s).forEach((function(e){let a=s[e]();a>0&&(t+=` res-${e}`,r+=` data-${e}="${a}"`)}))}let s="";e.class&&(s="function"==typeof e.class?` ${e.class()}`:` ${e.class}`),i&&(s=" precog");let c=e.highlight?e.highlight()?`${F("active")}`:`${F("not_active")}`:"";l=$(`${c}{{ title }} description`)}if(u.append(l),e.hasOwnProperty("special")&&("function"==typeof e.special&&e.special()||!0===e.special)){let e=$('
    \n \n
    ');u.append(e)}if(e.on||e.off){if(e.on){let e=$('');u.append(e)}if(e.off){let e=$('');u.append(e)}}else if(e.powered&&t.tech.high_tech&&t.tech.high_tech>=2&&_s(e)||e.switchable&&e.switchable()){let t=$(``),a=$(``);u.append(t),u.append(a)}if(e.count){let t=e.count();t>1&&l.append($(`${t}`))}else"tech"!==a&&t[a]&&t[a][r]&&t[a][r].count>=0?l.append($('{{ act.count }}')):"blood"===a&&t[a]&&t[a][e.grant[0]]&&t[a][e.grant[0]]>0&&"*"===e.grant[1]&&l.append($(` ${t[a][e.grant[0]]} `));if("tech"!==a&&t[a]&&t[a][r]&&void 0!==t[a][r].repair&&l.append($('
    ')),s?$("#oldTech").append(u):$("#"+c).append(u),"tech"!==a&&t[a]&&t[a][r]&&0===t[a][r].count&&($(`#${o} .count`).css("display","none"),$(`#${o} .special`).css("display","none"),$(`#${o} .on`).css("display","none"),$(`#${o} .off`).css("display","none")),e.emblem){let t=e.emblem();u.append($(t))}let d={template:''};sc({el:"#"+o,data:{title:"string"==typeof e.title?e.title:e.title(),act:t[a][r]},methods:{action(){"ontouchstart"in document.documentElement&&navigator.userAgent.match(t.settings.touch)||vs(e,a,r)},describe(){q(function(e,a){let r="string"==typeof e.desc?e.desc:e.desc();if(r+=". ",e.cost&&!a){r=Cs(e)?r+F("affordable")+". ":r+F("not_affordable")+". ",r+="Costs: ";let a=e.id.split("-")[0];var s="genes"!==a&&"blood"!==a?gc(e):e.cost;Object.keys(s).forEach((function(e){if("Custom"===e){let t=s[e]();r+=t.label}else if("Structs"===e){let a=s[e]();Object.keys(a).forEach((function(e){Object.keys(a[e]).forEach((function(s){let i="";if(a[e][s].hasOwnProperty("s")){let t=a[e][s].s;i="string"==typeof Qr[e][t][s].title?Qr[e][t][s].title:Qr[e][t][s].title()}else i="string"==typeof Qr[e][s].title?Qr[e][s].title:Qr[e][s].title();r+=`${i}. `,t[e][s]?a[e][s].count>t[e][s].count?r+=`${F("insufficient")} ${i}. `:a[e][s].hasOwnProperty("on")&&a[e][s].on>t[e][s].on&&(r+=`${F("insufficient")} ${i} enabled. `):r+=`${F("insufficient")} ${i}. `}))}))}else if(t.prestige.hasOwnProperty(e)){let a=s[e]();if(a>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let s=F(`resource_${e}_name`);r+=`${s}: ${a}. `,t.prestige[e].count0){let s=F(`resource_${e}_name`);r+=`${s}: ${a}. `,t.portal.purifier.supply0){let e="Money"===i?"$":t.resource[i].name+": ";e=e.replace("_"," ");let s=k(a,1);r+=`${e}${s}. `,t.resource[i].amount0&&(clearInterval(t),zs(e,r))}),50)}},on_label:()=>`on: ${t[a][r].on}`,off_label:()=>"off: "+(t[a][r].count-t[a][r].on),power_on(){let s=y();for(let e=0;e0;e++)t[a][r].on--;e.postPower&&setTimeout((function(){e.postPower(!1)}),250)},repair:()=>t[a][r].repair,repairMax:()=>e.repair()},filters:{val(t){switch(t){case"on":return e.on();case"off":return e.off()}},p_off(e,s){let i=t[a][r].count-e;if("city-casino"===s&&!t.race.cataclysm&&!t.race.orbit_decayed||"space-spc_casino"===s&&(t.race.cataclysm||t.race.orbit_decayed)||"tauceti-tauceti_casino"===s&&t.tech.isolation){let e=$c(5,12);if(0===i&&e.length>0)return e}return i},p_on(e,a){if("city-biolab"===a&&!t.race.cataclysm&&!t.race.orbit_decayed||(t.race.cataclysm||t.race.orbit_decayed)&&"space-exotic_lab"===a||t.tech.isolation&&"tauceti-infectious_disease_lab"===a){let t=$c(12,12);if(0===e&&t.length>0)return t}else if("city-garrison"===a||"space-space_barracks"===a){let t=kc(1,14,!0);if(e===("city-garrison"===a?13:0)&&t.length>0)return t}return e},title:e=>e,options:e=>F("action_options",[e])}}),Ti(o,(function(){}),{in:function(i){qs(i.popper,e,t[a][r],s,a,r)},out:function(){sc({el:"#popTimer"},"destroy")},attach:"starDock"===a?"body .modal":"#main",wide:e.wide})}function vs(e,a,r){if("spcdock-launch_ship"===e.id)e.action();else switch(a){case"tech":if(t.settings.qKey&&v.q||!us(r,!1)||!e.action()){if((!e.no_queue||!e.no_queue())&&t.tech.r_queue&&t.r_queue.queue.length0){let n=t.settings.qKey?s:1;n>t.queue.max-i&&(n=t.queue.max-i);let l=e.queue_size?e.queue_size:1;if(e.region&&(a=e.id.split("-")[0]),"merge_never"!==t.settings.q_merge)t.queue.queue.length>0&&t.queue.queue[t.queue.queue.length-1].id===e.id?t.queue.queue[t.queue.queue.length-1].q+=Math.min(o,l*n):t.queue.queue.push({id:e.id,action:a,type:r,label:"string"==typeof e.title?e.title:e.title(),cna:!1,time:0,q:Math.min(o,l*n),qs:l,t_max:0,bres:!1});else for(let s=0;s0;s++)t.queue.queue.push({id:e.id,action:a,type:r,label:"string"==typeof e.title?e.title:e.title(),cna:!1,time:0,q:Math.min(o,l),qs:l,t_max:0,bres:!1}),o-=l;c=!0}}break}t.race.inflation&&t.tech.primitive&&(e.hasOwnProperty("inflation")&&!e.inflation||t.race.inflation++),i=!0}if(i&&(ys(e,a,r),t.tech.queue&&e.queue_complete)){let a=e.queue_complete();for(let r=0,s=0;sa?(i.q=a,a=0):a-=i.q)}}c&&Ui();break}}}function ys(e,a,r){if(!Cs(e)){let t=e.id;$(`#${t}`).addClass("cna")}if(e.grant){let a=e.grant[0];(!t.tech[a]||t.tech[a]=4&&t.custom.planet&&e.custom&&e.custom.length>0&&0===Math.floor(m(0,10))){c=e.custom[Math.floor(m(0,e.custom.length))];let o=c.split(":");if(t.custom.planet[o[0]]&&t.custom.planet[o[0]][o[1]]){let e=zc(t.custom.planet[o[0]][o[1]]);a=e.biome,r=e.traitlist,s=e.orbit,i=e.geology,r.sort()}else c=!1}if(!c){a=$s("biome",e),r=$s("trait",e,{biome:a}),r.sort();let c=Math.floor(m(0,3)),o=30;t.stats.achieve.whitehole&&(o+=5*t.stats.achieve.whitehole.l,c+=t.stats.achieve.whitehole.l),"eden"===a&&(o+=5);for(let e=0;e`),_=$(`${u}`);d.append(_),$("#evolution").append(d);let p=!1,h=0;return Ti(n,(function(e){p=e,ws(e,u,a,s,r,i,h)}),{classes:"has-background-light has-text-dark"}),$("#"+n).on("click",(function(){if(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5&&t.race.hasOwnProperty("geck")&&t.race.geck>0){if(Object.keys(i).forEach((function(e){i[e]+=Math.floor(m(0,7))/100})),h>0){let t=8-h;t<1&&(t=1),0===Math.floor(m(0,t))&&(a=$s("biome",e))}if(0===Math.floor(m(0,2))){let t=$s("trait",e,{biome:a,cap:1});if(t.length>0){if(r.includes(t[0])){let e=r.indexOf(t[0]);r.splice(e,1)}else void 0!==t[0]&&r.push(t[0]);l="",r.forEach((function(e){Si.hasOwnProperty(e)&&(l+=`${Si[e].label} `)}))}}u=`${l}${ji[a].label} ${o}`,$(`#${n} .aTitle`).html(u),h++,t.race.geck--,t.race.hasOwnProperty("gecked")||(t.race.gecked=0),t.race.gecked++,rc(p.popper),ws(p,u,a,s,r,i,h)}else delete t.race.geck,t.race.gecked&&(t.stats.geck+=t.race.gecked),t.race.chose=n,t.city.biome=a,t.city.calendar.orbit=s,t.city.geology=i,t.city.ptrait=r,h>0&&(t.race.rejuvenated=!0),rc($("#evolution")),Ei(),ts()})),c||("eden"===a?"hellscape":a)}function ws(e,t,a,r,s,i,c){e.popper.append($(`
    ${F("set_planet",[t,ji[a].label,r])}
    `)),e.popper.append($(`
    ${ji[a].desc}
    `)),s.length>0&&s.forEach((function(t){e.popper.append($(`
    ${Si[t].desc}
    `))}));let o=ks(i);o.length>0&&e.popper.append($(`
    ${o}
    `)),c&&c>0&&e.popper.append($(`
    ${F("rejuvenated")}
    `))}function $s(e,a,r){if(r=r||{},"biome"===e){let e="grassland",r=!a.hell&&t.stats.portals>=1?7:6,s=0===Math.floor(m(0,3)),i=Yc();switch(Math.floor(m(0,r))){case 0:e=s&&t.stats.achieve.biome_grassland&&t.stats.achieve.biome_grassland[i]&&t.stats.achieve.biome_grassland[i]>0?"savanna":"grassland";break;case 1:e=s&&t.stats.achieve.biome_oceanic&&t.stats.achieve.biome_oceanic[i]&&t.stats.achieve.biome_oceanic[i]>0?"swamp":"oceanic";break;case 2:e=s&&t.stats.achieve.biome_forest&&t.stats.achieve.biome_forest[i]&&t.stats.achieve.biome_forest[i]>0?0===Math.floor(m(0,2))?"taiga":"swamp":"forest";break;case 3:e=s&&t.stats.achieve.biome_desert&&t.stats.achieve.biome_desert[i]&&t.stats.achieve.biome_desert[i]>0?"ashland":"desert";break;case 4:e=s&&t.stats.achieve.biome_volcanic&&t.stats.achieve.biome_volcanic[i]&&t.stats.achieve.biome_volcanic[i]>0?"ashland":"volcanic";break;case 5:e=s&&t.stats.achieve.biome_tundra&&t.stats.achieve.biome_tundra[i]&&t.stats.achieve.biome_tundra[i]>0?"taiga":"tundra";break;case 6:e="evil"===t.race.universe?"eden":"hellscape";break;default:e="grassland"}return e}if("trait"===e){let e=[],t=r.cap||2;for(let a=0;a0&&(s+=t.race.replicator.pow),!(t.city.hasOwnProperty("powered")&&s>=e.powered()&&(t[r[0]][r[1]].on++,t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks")&&t.race.hasOwnProperty("replicator")&&Object.values(t.race.governor.tasks).includes("replicate")&&t.race.governor.config.replicate.pow.on&&t.race.replicator.pow>0&&(t.city.power-=e.powered(),B.replicate.task()),a&&"function"==typeof a))||a(e)}return!1}function ks(e){let a="";if(Object.keys(e).length>0){let r="",s="",i=t.stats.achieve.miners_dream?t.stats.achieve.miners_dream.l>=4?2*t.stats.achieve.miners_dream.l-3:t.stats.achieve.miners_dream.l:0;t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=0&&i++;for(let t in e)if(0!==t)if(e[t]>0){let a=`
    ${F(`resource_${t}_name`)}`;i>0?(a+=`: +${Math.round(100*(e[t]+1)-100)}%`,i--):a+=`: ${F("bonus")}`,a+="
    ",r+=a}else if(e[t]<0){let a=`
    ${F(`resource_${t}_name`)}`;i>0?(a+=`: ${Math.round(100*(e[t]+1)-100)}%`,i--):a+=`: ${F("malus")}`,a+="
    ",s+=a}a=`
    ${r}${s}
    `}return a}function qs(e,a,r,s,i,c,o){rc(e);var n="string"==typeof a.desc?a.desc:a.desc();o=o||!1;let l=!1;!(i&&c&&"ontouchstart"in document.documentElement&&navigator.userAgent.match(/Mobi/)&&t.settings.touch)||(l=$(`${a.hasOwnProperty("touchlabel")?a.touchlabel:F("construct")}`),e.append(l),$("#touchButton").on("touchstart",(function(){vs(a,i,c)}))),e.append($(`
    ${n}
    `));let u=a.id.split("-")[0];a.category&&"tech"===u&&!s&&e.append($(`
    ${F("tech_dist_category")}: ${F(`tech_dist_${a.category}`)}
    `));let d=tc(a,!1,!0);if(a.cost&&!s){let r=!0;var _=$('
    '),p="genes"!==u&&"blood"!==u?gc(a):a.cost;Object.keys(p).forEach((function(e){if("Custom"===e){let t=p[e]();_.append($(`
    ${t.label}
    `)),r=!1}else if("Structs"===e){let a=p[e]();Object.keys(a).forEach((function(e){Object.keys(a[e]).forEach((function(s){let i=a[e][s].hasOwnProperty("on")?a[e][s].on:a[e][s].count,c="has-text-dark",o="";t[e][s]?a[e][s].count>t[e][s].count?(c="has-text-danger",o=' (blocking resource)'):a[e][s].hasOwnProperty("on")&&a[e][s].on>t[e][s].on&&(c="has-text-alert"):(c="has-text-danger",o=' (blocking resource)');let n="";if(a[e][s].hasOwnProperty("s")){let t=a[e][s].s;n="string"==typeof Qr[e][t][s].title?Qr[e][t][s].title:Qr[e][t][s].title()}else n="string"==typeof Qr[e][s].title?Qr[e][s].title:Qr[e][s].title();r=!1,_.append($(`
    ${n}: ${i}${o}
    `))}))}))}else if(t.prestige.hasOwnProperty(e)){let a=p[e]();if(a>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let s=F(`resource_${e}_name`),i="has-text-dark",c="";t.prestige[e].count(blocking resource)'),r=!1,_.append($(`
    ${s}: ${a}${c}
    `))}}else if("Supply"===e){let a=p[e]();if(a>0){let s=F(`resource_${e}_name`),i="has-text-dark",c="";t.portal.purifier.supply(blocking resource)'),r=!1,_.append($(`
    ${s}: ${a}${c}
    `))}}else if("Morale"!==e&&"Army"!==e&&"Bool"!==e){let a=p[e]();if(a>0){let s="",i="Species"===e?t.race.species:e;if("HellArmy"===e){let c=F("fortress_troops"),o="has-text-dark";t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size(blocking resource)'):o="has-text-alert"),r=!1,_.append($(`
    ${c}: ${a}${s}
    `))}else{let s="Money"===i?"$":t.resource[i].name+": ";s=s.replace("_"," ");let c="has-text-dark",n="";t.resource[i].amount(blocking resource)'):c="has-text-alert",o&&o!==e&&d.r===i?(c+=" grad-from-left",n=' (first blocking resource)'):o&&o===e&&d.r!==i&&(c+=" grad-from-left-warn")):o&&o===e&&(c+=" grad-from-right",n=' (last blocking resource)');let l=k(a,1);r=!1,_.append($(`
    ${s}${l}${n}
    `))}}}})),r||e.append(_)}if(a.effect){var h="string"==typeof a.effect?a.effect:a.effect();h&&e.append($(`
    ${h}
    `))}if(a.flair){var m="string"==typeof a.flair?a.flair:a.flair();e.append($(`
    ${m}
    `)),e.addClass("flair")}if(a.reqs){let t=[];if(Object.keys(a.reqs).forEach((function(e){let r=$(`#${a.id}`).attr(`data-req-${e}`);r&&t.push("string"==typeof Qr.tech[r].title?Qr.tech[r].title:Qr.tech[r].title())})),t.length>0){let a=t.join(", ");e.append($(`
    ${F("requires_tech",[a])}
    `))}}if(!s&&"blood"!==a.id.substring(0,5)&&!Cs(a)&&Cs(a,!0)){if("string"==typeof r&&"notimer"===r)return;if(r&&r.time)e.append($('
    {{ time | timer }}
    ')),sc({el:"#popTimer",data:r,filters:{timer:e=>F("action_ready",[e])}});else{let t=ic(d.t);e.append($(`
    ${F("action_ready",[t])}
    `))}}("portal-spire"===a.id||"portal-waygate"===a.id&&t.tech.waygate>=2)&&r&&r.time&&(e.append($('
    {{ time | timer }}
    ')),sc({el:"#popTimer",data:r,filters:{timer:e=>F("floor_clearing",[!a.hasOwnProperty("mscan")||a.hasOwnProperty("mscan")&&a.mscan()>0?e:"???"])}}))}function Ms(e){rc($(`#${e}`),!0),Ei(e)}function Ps(e,a,r){var s=e.id;t[a]&&t[a][r]&&t[a][r].count&&($(`#${s} .count`).html(t[a][r].count),t[a][r]&&t[a][r].count>0&&($(`#${s} .count`).css("display","inline-block"),$(`#${s} .special`).css("display","block"),$(`#${s} .on`).css("display","block"),$(`#${s} .off`).css("display","block"))),$("#popper").data("id")===s&&qs($("#popper"),e,t[a][r],!1,a,r)}function Os(e,a){return!!js(a=a||gc(e))&&(Object.keys(a).forEach((function(e){if(t.prestige.hasOwnProperty(e)){let r=a[e]();"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].count-=r}else if("Supply"===e){let r=a[e]();t.portal.purifier.supply-=r}else if("Morale"!==e&&"Army"!==e&&"HellArmy"!==e&&"Structs"!==e&&"Bool"!==e&&"Custom"!==e){let r=a[e](),s="Species"===e?t.race.species:e;t.resource[s].amount-=r,"Knowledge"===s&&(t.stats.know+=r)}})),!0)}function Cs(e,a,r){if(e.cost){let c=r?e.cost:gc(e);return a?(s=c,i=!0,Object.keys(s).forEach((function(e){if("Custom"===e);else if("Structs"===e){if(!Ss(s[e]()))return void(i=!1)}else if(t.prestige.hasOwnProperty(e)){let a=e;if("Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].count0||t.resource[r].max>=0&&a>Number(t.resource[r].max)&&-1!==Number(t.resource[r].max))return void(i=!1)}})),i):js(c)}var s,i;return!0}function js(e){var a=!0;return Object.keys(e).forEach((function(r){if("Custom"===r){if(!e[r]().met)return void(a=!1)}else if("Structs"===r){if(!Ss(e[r]()))return void(a=!1)}else if(t.prestige.hasOwnProperty(r)){let s=r;if("Plasmid"===r&&"antimatter"===t.race.universe&&(r="AntiPlasmid"),t.prestige[r].count=0&&s>t.resource[i].max;if(s>Number(t.resource[i].amount)+t.resource[i].diff||c)return void(a=!1)}})),a}function Ss(e){let a=!0;return Object.keys(e).forEach((function(r){t.hasOwnProperty(r)?Object.keys(e[r]).forEach((function(s){t[r].hasOwnProperty(s)?(t[r][s].count${r}

    `));var s=$('
    ');switch($("#modalBox").append(s),a){case"smelter":case"hell_smelter":case"stellar_forge":case"hell_forge":case"geothermal":case"ore_refinery":Us("smelter",s);break;case"factory":case"red_factory":case"int_factory":case"tau_factory":Us("factory",s);break;case"star_dock":!function(e){if(t.tech.genesis<4){let t=$(`
    ${F("stardock_warn")}
    `);return void e.append(t)}let a=$('
    ');e.append(a),fs(Qr.starDock.probes,"starDock","probes"),t.tech.geck&&t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5&&fs(Qr.starDock.geck,"starDock","geck"),t.tech.genesis>=5&&fs(Qr.starDock.seeder,"starDock","seeder"),6===t.tech.genesis&&fs(Qr.starDock.prep_ship,"starDock","prep_ship"),t.tech.genesis>=7&&fs(Qr.starDock.launch_ship,"starDock","launch_ship")}(s);break;case"mining_droid":Us("droid",s);break;case"g_factory":case"refueling_station":Us("graphene",s);break;case"freighter":case"super_freighter":_r(s);break;case"pylon":Us("pylon",s);break;case"rock_quarry":Us("rock_quarry",s);break;case"titan_mine":Us("titan_mine",s);break;case"mining_ship":Us("mining_ship",s);break;case"alien_space_station":Us("alien_space_station",s);break;case"nanite_factory":Us("nanite_factory",s);break;case"alien_outpost":Us("replicator",s)}}function As(){rc($("#evolution .evolving"),!0);let e=$(`
    ${t.evolution.final}%
    `);$("#evolution").append(e)}function Ts(){return"magic"===t.race.universe?F("city_wizard_tower_title"):t.race.evil?F("city_babel_title"):F("city_wardenclyffe")}function Es(){switch(t.race.species){case"orc":return F("city_basic_housing_orc_title");case"wolven":return F("city_basic_housing_wolven_title");case"sporgar":return F("city_basic_housing_sporgar_title");case"dracnid":case"balorg":return F("city_basic_housing_title7");case"imp":return F("city_basic_housing_title8");case"seraph":return F("city_basic_housing_seraph_title");case"unicorn":return F("city_basic_housing_unicorn_title")}switch(di[t.race.species].type){case"avian":return F("city_basic_housing_nest_title");case"plant":return F("city_basic_housing_entish_title");case"sand":return F("city_basic_housing_sand_title");case"polar":return F("city_basic_housing_polar_title");case"eldritch":return F("city_basic_housing_eldritch_title")}return t.city.ptrait.includes("trashed")?F("city_basic_housing_trash_title"):F("city_basic_housing_title")}function Is(e,a){switch(e){case"small":return Es();case"medium":return function(){switch(t.race.species){case"sporgar":return F("city_cottage_title2");case"balorg":return F("city_cottage_title3");case"imp":return F("city_basic_housing_title7");case"seraph":return F("city_cottage_title4");case"unicorn":return F("city_cottage_title5");case"dracnid":return F("city_cottage_title7")}switch(di[t.race.species].type){case"avian":return F("city_cottage_title6");case"eldritch":return F("city_cottage_title8")}return F("city_cottage_title1")}();case"large":return function(e){if(!e&&N("extravagant",0))return F("city_mansion");if("sporgar"===t.race.species)return F("city_apartment_title2");switch(di[t.race.species].type){case"avian":return F("city_apartment_title5");case"sand":return F("city_apartment_title6");case"demonic":return F("city_apartment_title3");case"angelic":return F("city_apartment_title4");case"giant":return F("city_apartment_title7");case"eldritch":return F("city_apartment_title8")}return F("city_apartment_title1")}(a)}}function Ks(e,a){if(t.tech.queue&&t.queue.display){let e=["space","interstellar","galaxy","portal","tauceti"];for(let r=0;r-1)if(e.includes(s.action)){let e=!0;Object.keys(Qr[s.action]).forEach((function(a){Qr[s.action][a][s.type]&&e&&(t.queue.queue[r].label="string"==typeof Qr[s.action][a][s.type].title?Qr[s.action][a][s.type].title:Qr[s.action][a][s.type].title(),e=!1)}))}else Qr[s.action][s.type]&&(t.queue.queue[r].label="string"==typeof Qr[s.action][s.type].title?Qr[s.action][s.type].title:Qr[s.action][s.type].title())}}if(e&&t.tech.r_queue&&t.r_queue.display)for(let e=0;e=4&&Mi(e)})),Object.keys(di[t.race.species].traits).forEach((function(e){Mi(e,{set:di[t.race.species].traits[e]})})),t.race.imitation&&t.race.srace&&ki(!1),Object.keys(t.tech).forEach((function(e){"evo_"===e.substring(0,4)&&delete t.tech[e]})),delete t.tech.evo,t.evolution={};const i=new Date;!t.settings.boring&&11===i.getMonth()&&i.getDate()>=17&&("elven"===t.race.species?(Mi("slaver",{set:2}),Mi("resourceful",{set:.5}),Mi("small",{set:.25})):"capybara"===t.race.species?(Mi("beast_of_burden",{set:1}),Mi("pack_rat",{set:.5}),Mi("musical",{set:.25})):"centaur"===t.race.species?(Mi("beast_of_burden",{set:1}),Mi("curious",{set:.5}),Mi("blissful",{set:.25})):"wendigo"===t.race.species?(Mi("immoral",{set:3}),Mi("cannibalize",{set:.5}),Mi("claws",{set:.25})):"yeti"===t.race.species?(Mi("scavenger",{set:3}),Mi("regenerative",{set:.5}),Mi("musical",{set:.25})):"entish"===t.race.species&&(Mi("photosynth",{set:3}),Mi("optimistic",{set:.5}),Mi("armored",{set:.25})));const c=Tc("easter");if("wolven"===t.race.species&&c.active?(Mi("hyper",{set:1}),Mi("fast_growth",{set:1}),Mi("rainbow",{set:1}),Mi("optimistic",{set:1})):"vulpine"===t.race.species&&c.active&&(Mi("cannibalize",{set:2}),Mi("rage",{set:1}),Mi("blood_thirst",{set:1}),Mi("sticky",{set:1})),t.race.no_crispr||t.race.badgenes){let e=t.race.badgenes?3:1;for(let a=0;a=2)for(let e=1;e<8;e++)t.genes.evolve>=e+1&&hi(e);let l=Ji();t.civic.foreign.gov0.name={s0:l.s0,s1:l.s1};let u=Ji();for(;l.s0===u.s0&&l.s1===u.s1;)u=Ji();t.civic.foreign.gov1.name={s0:u.s0,s1:u.s1};let d=Ji();for(;l.s0===d.s0&&l.s1===d.s1||u.s0===d.s0&&u.s1===d.s1;)d=Ji();if(t.civic.foreign.gov2.name={s0:d.s0,s1:d.s1},t.race.truepath||t.race.lone_survivor){t.civic.foreign.gov0.mil=Math.round(1.5*t.civic.foreign.gov0.mil),t.civic.foreign.gov1.mil=Math.round(1.4*t.civic.foreign.gov1.mil),t.civic.foreign.gov2.mil=Math.round(1.25*t.civic.foreign.gov2.mil),t.civic.foreign.gov3={unrest:0,hstl:Math.floor(m(20,40)),mil:Math.floor(m(650,750)),eco:Math.floor(m(250,300)),spy:0,esp:0,trn:0,sab:0,act:"none"};let e=Ji(!0);t.civic.foreign.gov3.name={s0:e.s0,s1:e.s1},t.civic.foreign.gov4={unrest:0,hstl:100,mil:300,eco:100,spy:0,esp:0,trn:0,sab:0,act:"none"};let a=Ji(!0);for(;a.s1===e.s1;)a=Ji(!0);t.civic.foreign.gov4.name={s0:99,s1:a.s1}}if(t.race.cataclysm?Di(F("cataclysm_sentience",[di[t.race.species].home,Ac("name")]),"info",!1,["progress"]):Di(F("sentience",[F("genelab_genus_"+di[t.race.species].type),di[t.race.species].entity,Ac("name")]),"info",!1,["progress"]),t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1&&(t.resource.Steel.display=!0,t.resource.Steel.amount=25,t.stats.achieve.technophobe.l>=3)){t.race.truepath||(t.resource.Soul_Gem.display=!0);let e=1;for(let a=1;a=5&&e++;t.resource.Soul_Gem.amount=e}if("tortoisan"===t.race.species){let e=Math.floor(m(100));t.race.shell_color=99===e?"rainbow":e>=97&&e<=98?"white":e>=93&&e<=96?"red":e>=89&&e<=92?"orange":e>=85&&e<=88?"yellow":e>=75&&e<=84?"purple":e>=65&&e<=74?"blue":"green"}if("vulpine"===t.race.species){let e=Math.floor(m(100));t.race.fox_color=e>=85?"white":e>=70&&e<=84?"tan":e>=55&&e<=69?"silver":e>=35&&e<=54?"grey":"red"}if(_c(!0),t.blood.aware&&(t.settings.arpa.blood=!0,t.tech.b_stone=2),oa(!0),Y(),V(!0),t.race.shapeshifter&&qi(!1,!0),t.race.carnivore||t.race.soul_eater||t.race.unfathomable?(t.civic.d_job="hunter",t.civic.hunter.display=!0):t.race.forager?(t.civic.d_job="forager",t.civic.forager.display=!0):(t.civic.d_job="unemployed",t.civic.unemployed.display=!0),t.race.hooved&&(t.resource.Horseshoe.display=!0,t.resource.Horseshoe.amount=5,t.race.shoecnt=5),t.race.deconstructor&&(t.resource.Nanite.display=!0,t.city.nanite_factory={count:1,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Bolognium:0,Orichalcum:0},t.settings.showIndustry=!0),lc(!0),(t.race.truepath||t.race.lone_survivor)&&Object.keys(Qa).forEach((function(e){t.resource.hasOwnProperty(e)&&(t.resource[e].value=2*Qa[e])})),ni(t.race.species,!0),Zi("sentience",{species:t.race.species,challenge:ro()-1}),t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0){let e=Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept);t.resource.Food.amount+=100*e,t.resource.Stone.max+=60*e,t.resource.Stone.amount+=100*e,t.race.smoldering?(t.resource.Chrysotile.max+=60*e,t.resource.Chrysotile.amount+=100*e):(t.resource.Lumber.max+=60*e,t.resource.Lumber.amount+=100*e)}t.race.cataclysm?t.race.cataclysm&&(t.tech.unify=2,t.tech.spy=5,t.tech.primitive=3,t.tech.currency=6,t.tech.govern=3,t.tech.boot_camp=1,t.tech.medic=1,t.tech.military=5,t.tech.marines=1,t.tech.explosives=3,t.tech.trade=3,t.tech.wharf=1,t.tech.banking=6,t.tech.gambling=1,t.tech.home_safe=1,t.tech.housing=3,t.tech.smelting=3,t.tech.copper=1,t.tech.storage=5,t.tech.container=4,t.tech.steel_container=3,t.tech.mining=4,t.tech.oil=7,t.tech.mass=1,t.tech.alumina=1,t.tech.titanium=2,t.tech.polymer=2,t.tech.uranium=4,t.tech.foundry=7,t.tech.factory=1,t.tech.theatre=3,t.tech.broadcast=2,t.tech.mine_conveyor=1,t.tech.science=9,t.tech.high_tech=7,t.tech.genetics=1,t.tech.theology=2,t.tech.space=6,t.tech.solar=3,t.tech.luna=2,t.tech.hell=1,t.tech.mars=5,t.tech.gas_giant=1,t.tech.gas_moon=2,t.tech.asteroid=3,t.tech.satellite=1,t.tech.space_explore=4,t.tech.genesis=2,t.settings.showSpace=!0,t.settings.space.home=!0,t.settings.space.moon=!0,t.settings.space.red=!0,t.settings.space.hell=!0,t.settings.space.sun=!0,t.settings.space.gas=!0,t.settings.space.gas_moon=!0,t.settings.space.belt=!0,t.settings.space.dwarf=!0,t.settings.showCity=!1,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.settings.civTabs=1,t.settings.spaceTabs=1,t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Food.display=!0,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Cement.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Uranium.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Alloy.display=!0,t.resource.Polymer.display=!0,t.resource.Iridium.display=!0,t.resource.Helium_3.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Mythril.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.resource.Lumber.max=9e4,t.resource.Lumber.amount=9e4,t.resource.Plywood.amount=5e4),t.race.smoldering&&(t.resource.Chrysotile.display=!0,t.resource.Chrysotile.max=9e4,t.resource.Chrysotile.amount=9e4),t.resource[t.race.species].max=8,t.resource[t.race.species].amount=8,t.resource.Crates.amount=20,t.resource.Containers.amount=20,t.resource.Money.max=225e3,t.resource.Money.amount=225e3,t.resource.Food.max=1e3,t.resource.Food.amount=1e3,t.resource.Oil.max=1e3,t.resource.Oil.amount=1e3,t.resource.Helium_3.max=1e3,t.resource.Helium_3.amount=1e3,t.resource.Uranium.max=1e3,t.resource.Uranium.amount=1e3,t.resource.Stone.max=9e4,t.resource.Stone.amount=9e4,t.resource.Furs.max=4e4,t.resource.Furs.amount=4e4,t.resource.Copper.max=75e3,t.resource.Copper.amount=75e3,t.resource.Iron.max=75e3,t.resource.Iron.amount=75e3,t.resource.Steel.max=75e3,t.resource.Steel.amount=75e3,t.resource.Aluminium.max=75e3,t.resource.Aluminium.amount=75e3,t.resource.Cement.max=75e3,t.resource.Cement.amount=75e3,t.resource.Titanium.max=75e3,t.resource.Titanium.amount=75e3,t.resource.Coal.max=1e4,t.resource.Coal.amount=1e4,t.resource.Alloy.max=2e4,t.resource.Alloy.amount=2e4,t.resource.Polymer.max=2e4,t.resource.Polymer.amount=2e4,t.resource.Iridium.max=1e3,t.resource.Iridium.amount=1e3,t.resource.Brick.amount=5e4,t.resource.Wrought_Iron.amount=5e4,t.resource.Sheet_Metal.amount=5e4,t.resource.Mythril.amount=8e3,t.resource.Iridium.crates=5,t.resource.Iridium.containers=5,t.civic.taxes.display=!0,t.civic.professor.display=!0,t.civic.scientist.display=!0,t.civic.colonist.display=!0,t.civic.space_miner.display=!0,t.race.flier||(t.tech.cement=5,t.civic.cement_worker.display=!0,t.civic.cement_worker.max=1,t.civic.cement_worker.workers=1),t.civic.colonist.max=4,t.civic.colonist.workers=4,t.civic.space_miner.max=3,t.civic.space_miner.workers=2,t.civic.professor.max=1,t.civic.professor.workers=1,t.city.calendar.day++,t.city.market.active=!0,t.city.power=0,t.city.powered=!0,t.race.artifical&&(t.city.transmitter={count:0,on:0}),t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:0,cap:2,Wood:0,Coal:0,Oil:2,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:1,Iridium:0},t.city.fission_power={count:0,on:0},t.city.oil_power={count:0,on:0},t.city.coal_power={count:0,on:0},t.city.mass_driver={count:0,on:0},t.city.mine={count:0,on:0},t.city.coal_mine={count:0,on:0},t.city.oil_well={count:0},t.city.oil_depot={count:0},t.city.garrison={count:0,on:0},t.city.basic_housing={count:0},t.city.cottage={count:0},t.city.apartment={count:0,on:0},t.city.amphitheatre={count:0},t.city.casino={count:0,on:0},t.city.rock_quarry={count:0,on:0,asbestos:50},t.city.metal_refinery={count:0,on:0},t.city.storage_yard={count:0},t.city.warehouse={count:0},t.city.trade={count:0},t.city.wharf={count:0},t.city.bank={count:0},t.city.tourist_center={count:0,on:0},t.city.university={count:0},t.city.library={count:0},t.city.wardenclyffe={count:0,on:0},t.city.biolab={count:0,on:0},t.city.lumber_yard={count:0},t.city.sawmill={count:0,on:0},t.city.temple={count:0},t.space.satellite={count:1},t.space.propellant_depot={count:1},t.space.gps={count:4},t.space.nav_beacon={count:1,on:1},t.space.moon_base={count:1,on:1,support:3,s_max:3},t.space.iridium_mine={count:1,on:1},t.space.helium_mine={count:1,on:1},t.space.observatory={count:1,on:1},t.space.spaceport={count:2,on:2,support:8,s_max:10},t.space.red_tower={count:1,on:1},t.space.living_quarters={count:4,on:4},t.space.vr_center={count:0,on:0},t.space.garage={count:1},t.space.red_mine={count:1,on:1},t.space.fabrication={count:1,on:1},t.space.red_factory={count:1,on:1},t.space.exotic_lab={count:1,on:1},t.space.ziggurat={count:0},t.space.space_barracks={count:1,on:1},t.space.biodome={count:2,on:2},t.space.laboratory={count:0,on:0},t.space.geothermal={count:2,on:2},t.space.spc_casino={count:0,on:0},t.space.swarm_plant={count:0},t.space.swarm_control={count:5,support:40,s_max:50},t.space.swarm_satellite={count:40},t.space.gas_mining={count:2,on:2},t.space.gas_storage={count:1},t.space.outpost={count:0,on:0},t.space.drone={count:0},t.space.oil_extractor={count:2,on:2},t.space.space_station={count:1,on:1,support:0,s_max:3},t.space.iridium_ship={count:1,on:1},t.space.elerium_ship={count:0,on:0},t.space.elerium_prospector={count:0,on:0},t.space.iron_ship={count:1,on:1},t.space.elerium_contain={count:0,on:0},t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:2,wounded:0,raid:0,max:2},hs(),ms(),Rt(),Oe("Physics"),ha()):t.race.lone_survivor?t.race.lone_survivor&&(t.tech.alloy=1,t.tech.alumina=2,t.tech.asteroid=7,t.tech.banking=11,t.tech.biotech=1,t.tech.boot_camp=2,t.tech.broadcast=2,t.tech.container=7,t.tech.copper=1,t.tech.currency=6,t.tech.disease=2,t.tech.drone=1,t.tech.elerium=2,t.tech.explosives=3,t.tech.factory=3,t.tech.foundry=8,t.tech.gambling=4,t.tech.gas_giant=1,t.tech.gas_moon=2,t.tech.genesis=2,t.tech.genetics=2,t.tech.gov_corp=1,t.tech.gov_fed=1,t.tech.gov_soc=1,t.tech.gov_theo=1,t.tech.govern=3,t.tech.graphene=1,t.tech.helium=1,t.tech.hell=1,t.tech.high_tech=13,t.tech.home_safe=2,t.tech.housing=3,t.tech.housing_reduction=3,t.tech.kuiper=2,t.tech.launch_facility=1,t.tech.luna=2,t.tech.m_smelting=2,t.tech.marines=2,t.tech.mars=5,t.tech.mass=1,t.tech.medic=3,t.tech.military=8,t.tech.mine_conveyor=1,t.tech.mining=4,t.tech.monument=1,t.tech.nano=1,t.tech.oil=7,t.tech.outer=8,t.tech.pickaxe=5,t.tech.polymer=2,t.tech.primitive=3,t.tech.q_factory=1,t.tech.quantium=1,t.tech.queue=3,t.tech.r_queue=1,t.tech.reproduction=1,t.tech.rival=1,t.tech.satellite=1,t.tech.science=9,t.tech.shelving=3,t.tech.shipyard=1,t.tech.smelting=6,t.tech.solar=5,t.tech.space=6,t.tech.space_explore=4,t.tech.space_housing=1,t.tech.spy=5,t.tech.stanene=1,t.tech.steel_container=6,t.tech.storage=5,t.tech.swarm=6,t.tech.syard_armor=3,t.tech.syard_class=6,t.tech.syard_engine=5,t.tech.syard_power=5,t.tech.syard_sensor=4,t.tech.syard_weapon=6,t.tech.syndicate=0,t.tech.synthetic_fur=1,t.tech.tau_home=6,t.tech.tauceti=4,t.tech.theatre=3,t.tech.theology=2,t.tech.titan=9,t.tech.titan_ai_core=3,t.tech.titan_power=1,t.tech.titanium=3,t.tech.trade=3,t.tech.unify=2,t.tech.uranium=4,t.tech.v_train=1,t.tech.vault=4,t.tech.wharf=1,t.tech.world_control=1,t.tech.wsc=0,t.race.flier||(t.tech.cement=5,t.resource.Cement.display=!0),"magic"===t.race.universe&&(t.tech.gov_mage=1,t.tech.magic=4,t.tech.conjuring=2,t.resource.Mana.display=!0,t.resource.Crystal.display=!0,t.civic.crystal_miner.display=!0,t.tauceti.pylon={count:0},t.race.casting={farmer:0,miner:0,lumberjack:0,science:0,factory:0,army:0,hunting:0,crafting:0,total:0,crafting:0}),t.settings.showSpace=!1,t.settings.showTau=!0,t.settings.tau.home=!0,t.settings.showCity=!1,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.settings.civTabs=1,t.settings.spaceTabs=6,t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.settings.arpa.genetics=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.resource.Food.display=!0,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Uranium.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Alloy.display=!0,t.resource.Polymer.display=!0,t.resource.Iridium.display=!0,t.resource.Helium_3.display=!0,t.resource.Water.display=!0,t.resource.Neutronium.display=!0,t.resource.Adamantite.display=!0,t.resource.Elerium.display=!0,t.resource.Nano_Tube.display=!0,t.resource.Graphene.display=!0,t.resource.Stanene.display=!0,t.resource.Orichalcum.display=!0,t.resource.Bolognium.display=!0,t.resource.Unobtainium.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Mythril.display=!0,t.resource.Quantium.display=!0,t.resource.Cipher.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.civic.lumberjack.display=!0,t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.resource.Lumber.max=1e7,t.resource.Lumber.amount=1e7,t.resource.Plywood.amount=25e5,t.resource.Lumber.crates=25,t.resource.Lumber.containers=25,t.tech.axe=5),t.race.smoldering&&(t.resource.Chrysotile.display=!0,t.resource.Chrysotile.max=5e6,t.resource.Chrysotile.amount=5e6),t.race.sappy||(t.tech.hammer=4),t.race.apex_predator||(t.tech.armor=3),t.resource[t.race.species].max=1,t.resource[t.race.species].amount=1,t.resource.Crates.amount=1e3,t.resource.Containers.amount=1e3,t.resource.Money.max=1e9,t.resource.Money.amount=1e9,t.resource.Knowledge.max=8e6,t.resource.Knowledge.amount=8e6,t.resource.Food.max=1e4,t.resource.Food.amount=1e4,t.resource.Oil.max=5e5,t.resource.Oil.amount=5e5,t.resource.Helium_3.max=5e5,t.resource.Helium_3.amount=5e5,t.resource.Water.max=25e3,t.resource.Water.amount=25e3,t.resource.Uranium.max=5e5,t.resource.Uranium.amount=5e5,t.resource.Stone.max=1e7,t.resource.Stone.amount=1e7,t.resource.Furs.max=5e6,t.resource.Furs.amount=5e6,t.resource.Copper.max=5e6,t.resource.Copper.amount=5e6,t.resource.Iron.max=5e6,t.resource.Iron.amount=5e6,t.resource.Steel.max=5e6,t.resource.Steel.amount=5e6,t.resource.Aluminium.max=5e6,t.resource.Aluminium.amount=5e6,t.resource.Cement.max=5e6,t.resource.Cement.amount=5e6,t.resource.Titanium.max=5e6,t.resource.Titanium.amount=5e6,t.resource.Coal.max=5e6,t.resource.Coal.amount=5e6,t.resource.Alloy.max=5e6,t.resource.Alloy.amount=5e6,t.resource.Polymer.max=5e6,t.resource.Polymer.amount=5e6,t.resource.Iridium.max=5e6,t.resource.Iridium.amount=5e6,t.resource.Neutronium.max=5e5,t.resource.Neutronium.amount=5e5,t.resource.Adamantite.max=5e6,t.resource.Adamantite.amount=5e6,t.resource.Elerium.max=1e3,t.resource.Elerium.amount=1e3,t.resource.Nano_Tube.max=5e6,t.resource.Nano_Tube.amount=5e6,t.resource.Graphene.max=5e6,t.resource.Graphene.amount=5e6,t.resource.Stanene.max=5e6,t.resource.Stanene.amount=5e6,t.resource.Bolognium.max=5e6,t.resource.Bolognium.amount=5e6,t.resource.Orichalcum.max=5e6,t.resource.Orichalcum.amount=5e6,t.resource.Brick.amount=25e5,t.resource.Wrought_Iron.amount=25e5,t.resource.Sheet_Metal.amount=25e5,t.resource.Mythril.amount=25e5,t.resource.Quantium.amount=25e5,t.race.artifical||(t.resource.Food.crates=10,t.resource.Food.containers=10),t.resource.Stone.crates=25,t.resource.Stone.containers=25,t.resource.Furs.crates=25,t.resource.Furs.containers=25,t.resource.Coal.crates=10,t.resource.Coal.containers=10,t.resource.Copper.crates=25,t.resource.Copper.containers=25,t.resource.Iron.crates=25,t.resource.Iron.containers=25,t.resource.Aluminium.crates=25,t.resource.Aluminium.containers=25,t.resource.Steel.crates=25,t.resource.Steel.containers=25,t.resource.Titanium.crates=25,t.resource.Titanium.containers=25,t.resource.Alloy.crates=25,t.resource.Alloy.containers=25,t.resource.Polymer.crates=25,t.resource.Polymer.containers=25,t.resource.Iridium.crates=25,t.resource.Iridium.containers=25,t.resource.Adamantite.crates=25,t.resource.Adamantite.containers=25,t.resource.Graphene.crates=25,t.resource.Graphene.containers=25,t.resource.Stanene.crates=25,t.resource.Stanene.containers=25,t.resource.Bolognium.crates=25,t.resource.Bolognium.containers=25,t.resource.Orichalcum.crates=25,t.resource.Orichalcum.containers=25,t.civic.taxes.display=!0,t.race.flier||(t.civic.cement_worker.display=!0,t.resource.Cement.crates=25,t.resource.Cement.containers=25),t.race.sappy||(t.civic.quarry_worker.display=!0),t.civic.professor.display=!0,t.civic.scientist.display=!0,t.civic.banker.display=!0,t.civic.pit_miner.display=!0,t.civic.professor.max=1,t.civic.professor.workers=1,t.city.calendar.day++,t.city.market.active=!0,t.city.power=0,t.city.powered=!0,t.race.artifical&&(t.city.transmitter={count:0,on:0}),t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:0,cap:2,Wood:0,Coal:0,Oil:2,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:1,Iridium:0},t.city.amphitheatre={count:0},t.city.apartment={count:0,on:0},t.city.bank={count:0},t.city.basic_housing={count:0},t.city.biolab={count:0,on:0},t.city.boot_camp={count:0},t.city.casino={count:0,on:0},t.city.cement_plant={count:0,on:0},t.city.coal_mine={count:0,on:0},t.city.coal_power={count:0,on:0},t.city.cottage={count:0},t.city.fission_power={count:0,on:0},t.city.garrison={count:0,on:0},t.city.hospital={count:0},t.city.library={count:0},t.city.lumber_yard={count:0},t.city.mass_driver={count:0,on:0},t.city.metal_refinery={count:0,on:0},t.city.mine={count:0,on:0},t.city.oil_depot={count:0},t.city.oil_power={count:0,on:0},t.city.oil_well={count:0},t.city.rock_quarry={count:0,on:0,asbestos:50},t.city.sawmill={count:0,on:0},t.city.shed={count:0,on:0},t.city.storage_yard={count:0},t.city.temple={count:0},t.city.tourist_center={count:0,on:0},t.city.trade={count:0},t.city.university={count:0},t.city.wardenclyffe={count:0,on:0},t.city.warehouse={count:0},t.city.wharf={count:0},t.space.ai_colonist={count:0,on:0},t.space.ai_core={count:100},t.space.ai_core2={count:0,on:0},t.space.biodome={count:0,on:0},t.space.crashed_ship={count:100},t.space.decoder={count:0,on:0},t.space.digsite={count:0},t.space.drone={count:0},t.space.drone_control={count:0,on:0},t.space.e_reactor={count:0,on:0},t.space.electrolysis={count:0,on:0,support:0,s_max:0},t.space.elerium_contain={count:0,on:0},t.space.elerium_mine={count:0,on:0},t.space.elerium_ship={count:0,on:0},t.space.exotic_lab={count:0,on:0},t.space.fabrication={count:0,on:0},t.space.fob={count:0,on:0,troops:0,enemy:0},t.space.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},t.space.garage={count:0},t.space.gas_mining={count:0,on:0},t.space.gas_storage={count:0},t.space.geothermal={count:0,on:0},t.space.gps={count:0},t.space.helium_mine={count:0,on:0},t.space.hell_smelter={count:0,on:0},t.space.hydrogen_plant={count:0,on:0},t.space.iridium_mine={count:0,on:0},t.space.iridium_ship={count:0,on:0},t.space.iron_ship={count:0,on:0},t.space.lander={count:0,on:0},t.space.living_quarters={count:0,on:0},t.space.m_relay={count:0,on:0},t.space.mass_relay={count:100},t.space.moon_base={count:0,on:0,support:0,s_max:0},t.space.munitions_depot={count:0},t.space.nav_beacon={count:0,on:0},t.space.neutronium_mine={count:0,on:0},t.space.observatory={count:0,on:0},t.space.oil_extractor={count:0,on:0},t.space.operating_base={count:0,on:0},t.space.orichalcum_mine={count:0,on:0},t.space.outpost={count:0,on:0},t.space.propellant_depot={count:0},t.space.red_factory={count:0,on:0},t.space.red_mine={count:0,on:0},t.space.red_tower={count:0,on:0},t.space.satellite={count:0},t.space.shipyard={count:0,on:0,ships:[],expand:!1,sort:!0},t.space.shock_trooper={count:0,on:0},t.space.space_barracks={count:0,on:0},t.space.space_station={count:0,on:0,support:0,s_max:0},t.space.spaceport={count:0,on:0,support:0,s_max:0},t.space.spc_casino={count:0,on:0},t.space.storehouse={count:0},t.space.swarm_control={count:0,support:0,s_max:0},t.space.swarm_plant={count:0},t.space.swarm_satellite={count:0},t.space.tank={count:0,on:0},t.space.titan_bank={count:0},t.space.titan_mine={count:0,on:0},t.space.titan_quarters={count:0,on:0},t.space.titan_spaceport={count:0,on:0,support:0,s_max:0},t.space.uranium_mine={count:0,on:0},t.space.vr_center={count:0,on:0},t.space.water_freighter={count:0,on:0},t.space.zero_g_lab={count:0,on:0},t.space.ziggurat={count:0},t.tauceti.alien_outpost={count:1,on:1},t.tauceti.colony={count:1,on:1},t.tauceti.fusion_generator={count:1,on:1},t.tauceti.infectious_disease_lab={count:0,on:0,cure:0},t.tauceti.mining_pit={count:1,on:1},t.tauceti.orbital_platform={count:0,on:0,support:0,s_max:0},t.tauceti.orbital_station={count:1,on:1,support:0,s_max:0},t.tauceti.refueling_station={count:0,on:0},t.tauceti.repository={count:2},t.tauceti.tauceti_casino={count:0,on:0},t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:2,wounded:0,raid:0,max:2},t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!0,boost:!1,auto:!1,labs:0},t.tech.stock_exchange=0,t.tech.monuments=0,t.tech.supercollider=0,t.tech.tp_depot=0,t.tech.railway=0,t.tech.isolation=1,t.race.truepath=1,t.arpa.m_type=Oe("Monument"),ms(),tt(),Oe("Physics"),ha()):t.race.artifical&&t.race.artifical&&(t.tech.spy=5,t.tech.primitive=3,t.tech.currency=6,t.tech.govern=3,t.tech.boot_camp=1,t.tech.medic=1,t.tech.military=5,t.tech.explosives=3,t.tech.trade=3,t.tech.banking=6,t.tech.home_safe=1,t.tech.housing=3,t.tech.smelting=3,t.tech.copper=1,t.tech.storage=5,t.tech.container=4,t.tech.steel_container=3,t.tech.mining=4,t.tech.pickaxe=2,t.tech.hammer=2,t.tech.oil=3,t.tech.alumina=1,t.tech.titanium=1,t.tech.foundry=7,t.tech.factory=1,t.tech.theatre=3,t.tech.broadcast=1,t.tech.science=7,t.tech.high_tech=4,t.tech.theology=2,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Food.display=!0,t.resource.Money.amount=1e3,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.race.flier||(t.tech.cement=5,t.resource.Cement.display=!0),t.race.kindling_kindred||t.race.smoldering||(t.race.evil?(t.tech.reclaimer=3,t.city.graveyard={count:1}):(t.tech.axe=3,t.tech.saw=2,t.city.lumber_yard={count:1},t.city.sawmill={count:0,on:0}),t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.civic.lumberjack.display=!0),t.race.smoldering&&(t.resource.Chrysotile.display=!0),t.resource[t.race.species].max=0,t.resource[t.race.species].amount=0,t.resource.Crates.amount=10,t.resource.Containers.amount=10,t.civic.taxes.display=!0,t.civic.miner.display=!0,t.civic.coal_miner.display=!0,t.civic.quarry_worker.display=!0,t.civic.professor.display=!0,t.civic.scientist.display=!0,t.race.flier||(t.civic.cement_worker.display=!0),t.civic.banker.display=!0,t.city.calendar.day++,t.city.market.active=!0,t.city.power=7.5,t.city.powered=!0,t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:1,cap:0,Wood:0,Coal:0,Oil:1,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:0,Iridium:0},t.city.oil_power={count:1,on:1},t.city.coal_power={count:0,on:0},t.city.transmitter={count:1,on:1},t.city.mine={count:1,on:0},t.city.coal_mine={count:1,on:0},t.city.oil_well={count:1},t.city.oil_depot={count:1},t.city.cement_plant={count:1,on:0},t.city.garrison={count:0,on:0},t.city.boot_camp={count:0},t.city.basic_housing={count:0},t.city.cottage={count:0},t.city.apartment={count:0,on:0},t.city.amphitheatre={count:0},t.city.rock_quarry={count:1,on:0,asbestos:50},t.city.metal_refinery={count:1,on:0},t.city.shed={count:2},t.city.storage_yard={count:1},t.city.warehouse={count:1},t.city.trade={count:0},t.city.wharf={count:0},t.city.bank={count:1},t.city.university={count:1},t.city.library={count:1},t.city.wardenclyffe={count:0,on:0},t.city.temple={count:0},t.race.calm&&(t.resource.Zen.display=!0,t.city.meditation={count:0}),t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0}),t.civic.govern.type="technocracy",t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:0,wounded:0,raid:0,max:0},hs(),ms(),ha()),t.settings.tabLoad?(hs(),J(),fe($("#c_garrison"),!1),se(),t.race.cataclysm||t.race.lone_survivor?(rc($("#r_civics")),V(),Ws(),tr("market"),tr("storage"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color,r=a.resource[e].tradable;if(a.resource[e].stackable){var s=$(`
    `);$("#resStorage").append(s),fr(`#stack-${e}`,s,e,t)}r&&(s=$(`
    `),$("#market").append(s),ur(`#market-${e}`,s,e,t,!0))})),sr(),Oe("Genetics"),Oe("Crispr"),Oe("Blood")):t.sim&&(Oe("Crispr"),Oe("Blood"))):Ct("mTabCivil"),t.queue.hasOwnProperty("queue")&&(t.queue.queue=[]),(t.race.slow||t.race.hyper||"junker"===t.race.species)&&(e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload())}function Ns(e){switch(di[e].fanaticism){case"smart":t.race.dumb?(hi(5),Oe("Genetics")):Ds("smart");break;case"infectious":Ds("infectious"),"human"===t.race.species&&Xc("infested");break;case"blood_thirst":Ds("blood_thirst"),"entish"===t.race.species&&Xc("madagascar_tree");break;case"none":hi(5),Oe("Genetics");break;default:Ds(di[e].fanaticism)}}function Ds(e){t.race[e]?Mi(e)?"imitation"===e?ki(!0):"shapeshifter"===e&&qi(t.race.ss_genus):(hi(5),Oe("Genetics")):(t.race[e]=1,$i(e))}function Bs(){if(!t.settings.tabLoad&&3!==t.settings.civTabs)return;Gs(),rc($("#resQueue")),$("#resQueue").append($(`\n

    ${F("research_queue")} ({{ queue.length }}/{{ max }})

    \n \n `));let e=$('
      ');$("#resQueue").append(e),e.append($('
    • {{ item.label }} [{{ item.time | time }}]
    • '));try{sc({el:"#resQueue",data:t.r_queue,methods:{remove(e){Ei(`rq${t.r_queue.queue[e].id}`),t.r_queue.queue.splice(e,1),Bs(),ms()},setID:e=>`rq${t.r_queue.queue[e].id}`,pauseRQueue(){$("#pauserqueue").removeClass("play"),$("#pauserqueue").removeClass("pause"),t.r_queue.pause?(t.r_queue.pause=!1,$("#pauserqueue").addClass("play")):(t.r_queue.pause=!0,$("#pauserqueue").addClass("pause"))},pausedesc:()=>t.r_queue.pause?F("r_queue_play"):F("r_queue_pause")},filters:{time:e=>ic(e)}}),function(){let e=$("#resQueue .buildList")[0];Sortable.create(e,{onEnd(e){let a=t.r_queue.queue;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.r_queue.queue=a,Bs()}}),function(){for(let e=0;e=5?e-.01:e}function Hs(){let e=1800;t.tech.vault>=1?e=7500*(t.tech.vault+1):t.tech.banking>=5?e=9e3:t.tech.banking>=3&&(e=4e3),t.race.paranoid&&(e*=1-ui.paranoid.vars()[0]/100),t.race.hoarder&&(e*=1+ui.hoarder.vars()[0]/100);let a=Pi("dracnid");a>0&&(e*=1+ui.hoarder.vars(1)[0]/100*a),t.tech.banking>=7&&(e*=1+Me(.05*na(t.civic.banker.workers,"banker"))),t.tech.banking>=8&&(e+=Me(25*t.resource[t.race.species].amount)),t.tech.stock_exchange&&(e*=1+.1*t.tech.stock_exchange),t.tech.world_control&&(e*=1.25),t.race.truepath&&(e*=1.25),t.blood.greed&&(e*=1+t.blood.greed/100),t.stats.achieve.wheelbarrow&&(e*=1+t.stats.achieve.wheelbarrow.l/50),t.race.inflation&&(e*=1+t.race.inflation/125);let r=N("risktaker",0);return r&&(e*=1+r/100),e}function Us(e,a,r){switch(e){case"smelter":!function(e,a){let r=$(`
      ${F("modal_smelter_fuel")}: {{s.count | on}}/{{ s.cap }}
      `);if(e.append(r),e.hasClass("modalBody")){let e=$c(10);e.length>0&&r.prepend(e)}if(a&&t.race.forge&&t.race.steelen){let e=kc(3,12,!0);e.length>0&&r.prepend(e)}let s=e.hasClass("modalBody")?"mSmelterFuels":"smelterFuels",i=$(`
      `);if(e.append(i),!t.race.forge){if(!t.race.kindling_kindred&&!t.race.smoldering||t.race.evil){let e=t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?t.resource.Food.name:t.resource.Furs.name:t.resource.Lumber.name,a=$(`${e} {{ s.Wood }}`),r=$('«'),s=$('»');i.append(r),i.append(a),i.append(s)}if(t.resource.Coal.display){let e=$(`${t.resource.Coal.name} `),a=$('«'),r=$('»');i.append(a),i.append(e),i.append(r)}}if(t.race.forge){let e=$(`${F("trait_forge_name")} {{ s.Oil }}`);i.append(e)}else if(t.resource.Oil.display){let e=$(`${t.resource.Oil.name} {{ s.Oil }}`),a=$('«'),r=$('»');i.append(a),i.append(e),i.append(r)}if(t.tech.star_forge&&t.tech.star_forge>=2){let e=$(`${F("star")} {{ s.Star }}`);i.append(e)}if(t.tech.smelting&&t.tech.smelting>=8){let e=$(`${F("modal_smelter_inferno")} {{ s.Inferno }}`),t=$('«'),a=$('»');i.append(t),i.append(e),i.append(a)}let c=$('
      ');e.append(c);let o=!!(t.tech.irid_smelting||t.tech.m_smelting&&t.tech.m_smelting>=2);if(t.resource.Iridium.display&&o||t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen){let a=$(`
      `);e.append(a),a.append(`
      ${F("modal_smelter_type")}: {{s.count | son}}/{{ s.cap | on }}
      `);let r=$('
      ');a.append(r);let s=$(`${t.resource.Iron.name} {{ s.Iron }}`),i=$('«'),c=$('»');if(r.append(i),r.append(s),r.append(c),t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen){let e=$(`${t.resource.Steel.name} {{ s.Steel }}`),a=$('«'),s=$('»');r.append(a),r.append(e),r.append(s)}if(t.resource.Iridium.display&&o){let e=$(`${t.resource.Iridium.name} {{ s.Iridium }}`),a=$('«'),s=$('»');r.append(a),r.append(e),r.append(s)}}function n(e){switch(e){case"wood":return F("modal_build_wood",[t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?t.resource.Food.name:t.resource.Furs.name:t.resource.Lumber.name,t.race.evil&&!t.race.soul_eater||"wendigo"===t.race.species?1:3]);case"coal":{let e=t.race.kindling_kindred?.15:.25;return t.tech.uranium&&t.tech.uranium>=3?F("modal_build_coal2",[e,F("resource_Coal_name"),F("resource_Uranium_name")]):F("modal_build_coal1",[e,F("resource_Coal_name")])}case"oil":return t.race.forge?F("modal_build_forge"):F("modal_build_oil",["0.35",F("resource_Oil_name")]);case"star":return t.tech.irid_smelting?F("modal_build_star2",[F("resource_Titanium_name"),F("resource_Iridium_name")]):F("modal_build_star",[F("resource_Titanium_name")]);case"inferno":{let e=35,t=.5;return F("modal_build_inferno",[50,F("resource_Coal_name"),e,F("resource_Oil_name"),t,F("resource_Infernite_name")])}}}function l(e){if("steel"===e){let e=t.tech.smelting>=4?1.2:1;return t.tech.smelting>=5&&(e*=1.2),t.tech.smelting>=6&&(e*=1.2),t.tech.smelting>=7&&(e*=1.25),t.race.pyrophobia&&(e*=.9),F("modal_smelter_steel",[+e.toFixed(3),F("resource_Steel_name"),F("resource_Coal_name"),F("resource_Iron_name")])}if("iridium"===e){let e=t.tech.smelting>=7?6.25:5;return t.race.pyrophobia&&(e*=.9),F("modal_smelter_iron",[+e.toFixed(3),F("resource_Iridium_name")])}{let e=t.tech.smelting>=3?t.tech.smelting>=7?15:12:10;return t.race.pyrophobia&&(e*=.9),F("modal_smelter_iron",[+e.toFixed(3),F("resource_Iron_name")])}}sc({el:a||"#specialModal",data:{s:t.city.smelter,lum:t.resource.Lumber,coal:t.resource.Coal,oil:t.resource.Oil,food:t.resource.Food,fur:t.resource.Furs},methods:{addFuel(e){let a=y();for(let r=0;r=t.city.smelter.StarCap)break;if(a0))break;"Wood"!==e&&t.city.smelter.Wood>0?(t.city.smelter.Wood--,t.city.smelter[e]++):"Coal"!==e&&t.city.smelter.Coal>0?(t.city.smelter.Coal--,t.city.smelter[e]++):"Oil"!==e&&t.city.smelter.Oil>0?(t.city.smelter.Oil--,t.city.smelter[e]++):"Inferno"!==e&&t.city.smelter.Inferno>0&&(t.city.smelter.Inferno--,t.city.smelter[e]++)}}},subFuel(e){let a=y();for(let r=0;r0;r++){t.city.smelter[e]--,t.race.forge&&"Inferno"===e&&t.city.smelter.Oil++;let a=t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno;t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium>a&&(t.city.smelter.Iron>0?t.city.smelter.Iron--:t.city.smelter.Steel>0?t.city.smelter.Steel--:t.city.smelter.Iridium>0&&t.city.smelter.Iridium--)}},mLabel:e=>l(e),addMetal(e){let a=y();for(let r=0;r0&&"Iron"!==e)t.city.smelter.Iron--,t.city.smelter[e]++;else if(t.city.smelter.Steel>0&&"Steel"!==e)t.city.smelter.Steel--,t.city.smelter[e]++;else{if(!(t.city.smelter.Iridium>0&&"Iridium"!==e))break;t.city.smelter.Iridium--,t.city.smelter[e]++}}},subMetal(e){let a=y();t.city.smelter[e]-=a,t.city.smelter[e]<0&&(t.city.smelter[e]=0)},buildLabel:e=>n(e),ariaCount:e=>` ${t.city.smelter[e]} ${e} fueled.`,ariaProd:e=>`. ${t.city.smelter[e]} producing ${e}.`,net:e=>t.resource[e].diff>=0?"has-text-success":"has-text-danger",level:()=>Xs(t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,t.city.smelter.count)},filters:{on:e=>t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,son:e=>t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium,diffSize:e=>e>0?`+${k(e,2)}`:k(e,2),spook(e){if(a&&((t.race.kindling_kindred||t.race.smoldering)&&(6===t.city.smelter.Steel||6===t.city.smelter.Iron)||6===t.city.smelter.Wood)&&6===t.city.smelter.Coal&&6===t.city.smelter.Oil){let e=kc(3,12,!0);if(e.length>0)return e}return e},altspook(e){if(a&&t.race.forge&&6===t.city.smelter.Steel){let e=kc(3,12,!0);if(e.length>0)return e}return e}}});let u=e.hasClass("modalBody")?"mSmelterFuels":"smelterFuels";if(["wood","coal","oil","star","inferno"].forEach((function(e){Ti(`${u}${e}`,(function(){return n(e)}),{elm:$(`#${u} > .${e}`),attach:"#main"})})),t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen||t.resource.Iridium.display&&o){let a=e.hasClass("modalBody")?"mSmelterMats":"smelterMats";["iron","steel","iridium"].forEach((function(e){("steel"!==e||t.resource.Steel.display&&!t.race.steelen)&&("iridium"!==e||t.resource.Iridium.display&&o)&&Ti(`${a}${e}`,(function(){return l(e)}),{elm:$(`#${a} span.${e}`),attach:"#main"})}))}}(a,r);break;case"factory":!function(e,a){let r=$(`
      ${F("modal_factory_operate")}: {{count | on}}/{{ on | max }}
      `);e.append(r);let s=$(`
      ${F("modal_factory_lux")}
      `);e.append(s);let o=$(''),n=$('«'),l=$('»');if(s.append(n),s.append(o),s.append(l),t.tech.synthetic_fur){let a=$(`
      ${t.race.evil?F("resource_Flesh_name"):F("resource_Furs_name")}
      `);e.append(a);let r=$('{{ Furs }}'),s=$('«'),i=$('»');a.append(s),a.append(r),a.append(i)}let u=$(`
      ${F("resource_Alloy_name")}
      `);e.append(u);let d=$('{{ Alloy }}'),_=$('«'),p=$('»');if(u.append(_),u.append(d),u.append(p),t.tech.polymer){let t=$(`
      ${F("resource_Polymer_name")}
      `);e.append(t);let a=$('{{ Polymer }}'),r=$('«'),s=$('»');t.append(r),t.append(a),t.append(s)}if(t.tech.nano){let t=$(`
      ${F("resource_Nano_Tube_name")}
      `);e.append(t);let a=$('{{ Nano }}'),r=$('«'),s=$('»');t.append(r),t.append(a),t.append(s)}if(t.tech.stanene){let t=$(`
      ${F("resource_Stanene_name")}
      `);e.append(t);let a=$('{{ Stanene }}'),r=$('«'),s=$('»');t.append(r),t.append(a),t.append(s)}function h(e){let a=!!t.tech.factory;switch(e){case"Lux":{let e=+t.resource[t.race.species].amount*(a?Qs.Lux.demand[t.tech.factory]:Qs.Lux.demand[0]);return e=Zs(e).toFixed(2),F("modal_factory_lux_label",[a?Qs.Lux.fur[t.tech.factory]:Qs.Lux.fur[0],t.resource.Furs.name,e])}case"Furs":{let e=a?Qs.Furs.money[t.tech.factory]:Qs.Furs.money[0],r=a?Qs.Furs.polymer[t.tech.factory]:Qs.Furs.polymer[0];return F("modal_factory_alloy_label",[e,F("resource_Money_name"),r,F("resource_Polymer_name"),t.race.evil?F("resource_Flesh_name"):F("resource_Furs_name")])}case"Alloy":{let e=a?Qs.Alloy.copper[t.tech.factory]:Qs.Alloy.copper[0],r=a?Qs.Alloy.aluminium[t.tech.factory]:Qs.Alloy.aluminium[0];return F("modal_factory_alloy_label",[e,F("resource_Copper_name"),r,F("resource_Aluminium_name"),F("resource_Alloy_name")])}case"Polymer":if(t.race.kindling_kindred||t.race.smoldering)return F("modal_factory_polymer_label2",[a?Qs.Polymer.oil_kk[t.tech.factory]:Qs.Polymer.oil_kk[0],F("resource_Oil_name"),F("resource_Polymer_name")]);{let e=a?Qs.Polymer.oil[t.tech.factory]:Qs.Polymer.oil[0],r=a?Qs.Polymer.lumber[t.tech.factory]:Qs.Polymer.lumber[0];return F("modal_factory_polymer_label1",[e,F("resource_Oil_name"),r,t.resource.Lumber.name,F("resource_Polymer_name")])}case"Nano":{let e=a?Qs.Nano_Tube.coal[t.tech.factory]:Qs.Nano_Tube.coal[0],r=a?Qs.Nano_Tube.neutronium[t.tech.factory]:Qs.Nano_Tube.neutronium[0];return F("modal_factory_nano_label",[e,F("resource_Coal_name"),r,F("resource_Neutronium_name"),F("resource_Nano_Tube_name")])}case"Stanene":{let e=a?Qs.Stanene.aluminium[t.tech.factory]:Qs.Stanene.aluminium[0],r=a?Qs.Stanene.nano[t.tech.factory]:Qs.Stanene.nano[0];return F("modal_factory_stanene_label",[e,F("resource_Aluminium_name"),r,F("resource_Nano_Tube_name"),F("resource_Stanene_name")])}}}sc({el:a||"#specialModal",data:t.city.factory,methods:{subItem:function(e){let a=y();for(var r=0;r0;r++)t.city.factory[e]--},addItem:function(e){let a=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;t.interstellar.int_factory&&i.int_factory&&(a+=2*i.int_factory),t.tauceti.tau_factory&&c.tau_factory&&(a+=c.tau_factory*(t.tech.isolation?5:3));let r=y();for(var s=0;s0))break;t.city.factory.Alloy--,t.city.factory[e]++}}},buildLabel:function(e){return h(e)},ariaProd:e=>`. ${t.city.factory[e]} factories producing ${e}.`,level(){let e=t.city.factory.Lux+t.city.factory.Furs+t.city.factory.Alloy+t.city.factory.Polymer+t.city.factory.Nano+t.city.factory.Stanene,a=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;return t.interstellar.int_factory&&i.int_factory&&(a+=2*i.int_factory),t.tauceti.tau_factory&&c.tau_factory&&(a+=c.tau_factory*(t.tech.isolation?5:3)),Xs(e,a)}},filters:{on:()=>t.city.factory.Lux+t.city.factory.Furs+t.city.factory.Alloy+t.city.factory.Polymer+t.city.factory.Nano+t.city.factory.Stanene,max(){let e=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;return t.interstellar.int_factory&&i.int_factory&&(e+=2*i.int_factory),t.tauceti.tau_factory&&c.tau_factory&&(e+=c.tau_factory*(t.tech.isolation?5:3)),e},spook(e){if(3===t.city.factory.Lux&&a){let e=kc(6,12,!0);if(e.length>0)return e}return e}}}),["Lux","Furs","Alloy","Polymer","Nano","Stanene"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iFactory";Ti(`${a}${t}`,(function(){return h(t)}),{elm:$(`#${a} .factory > .${t}`),attach:"#main"})}))}(a,r);break;case"droid":!function(e,a){let r=$(`
      ${F("modal_factory_operate")}: {{count | on}}/{{ on | max }}
      `);e.append(r);let s=$(`
      ${F("resource_Adamantite_name")}
      `);e.append(s);let i=$('{{ adam }}'),c=$('«'),o=$('»');s.append(c),s.append(i),s.append(o);let n=$(`
      ${F("resource_Uranium_name")}
      `);e.append(n);let l=$('{{ uran }}'),u=$('«'),d=$('»');n.append(u),n.append(l),n.append(d);let _=$(`
      ${F("resource_Coal_name")}
      `);e.append(_);let p=$('{{ coal }}'),h=$('«'),m=$('»');_.append(h),_.append(p),_.append(m);let g=$(`
      ${F("resource_Aluminium_name")}
      `);e.append(g);let f=$('{{ alum }}'),v=$('«'),b=$('»');function w(e){switch(e){case"adam":return F("modal_droid_res_label",[F("resource_Adamantite_name")]);case"uran":return F("modal_droid_res_label",[F("resource_Uranium_name")]);case"coal":return F("modal_droid_res_label",[F("resource_Coal_name")]);case"alum":return F("modal_droid_res_label",[F("resource_Aluminium_name")])}}g.append(v),g.append(f),g.append(b),sc({el:a||"#specialModal",data:t.interstellar.mining_droid,methods:{subItem:function(e){let a=y();for(var r=0;r0;r++)t.interstellar.mining_droid[e]--},addItem:function(e){let a=y();for(var r=0;r`. ${t.interstellar.mining_droid[e]} driod mining ${e}.`,level:()=>Xs(t.interstellar.mining_droid.adam+t.interstellar.mining_droid.uran+t.interstellar.mining_droid.coal+t.interstellar.mining_droid.alum,t.interstellar.mining_droid.on)},filters:{on:()=>t.interstellar.mining_droid.adam+t.interstellar.mining_droid.uran+t.interstellar.mining_droid.coal+t.interstellar.mining_droid.alum,max:()=>t.interstellar.mining_droid.on}}),["adam","uran","coal","alum"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iDroid";Ti(`${a}${t}`,(function(){return w(t)}),{elm:$(`#${a} .factory > .${t}`),attach:"#main"})}))}(a,r);break;case"graphene":!function(e,a){let r=t.race.truepath?"space":"interstellar",s=$(`
      ${F("modal_smelter_fuel")}: {{count | on}}/{{ on | max }}
      `);e.append(s);let i=$("
      ");if(e.append(i),!t.race.kindling_kindred&&!t.race.smoldering){let e=t.resource.Lumber.name,a=$(`${e} {{ Lumber }}`),r=$('«'),s=$('»');i.append(r),i.append(a),i.append(s)}if(t.resource.Coal.display){let e=$(`${t.resource.Coal.name} {{ Coal }}`),a=$('«'),r=$('»');i.append(a),i.append(e),i.append(r)}if(t.resource.Oil.display){let e=$(`${t.resource.Oil.name} {{ Oil }}`),a=$('«'),r=$('»');i.append(a),i.append(e),i.append(r)}function c(e){switch(e){case"wood":return F("modal_graphene_produce",[350,t.race.evil?F("resource_Bones_name"):F("resource_Lumber_name"),F("resource_Graphene_name")]);case"coal":return F("modal_graphene_produce",[25,F("resource_Coal_name"),F("resource_Graphene_name")]);case"oil":return F("modal_graphene_produce",[15,F("resource_Oil_name"),F("resource_Graphene_name")])}}sc({el:a||"#specialModal",data:t[r].g_factory,methods:{subWood(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Lumber--},addWood(){let e=y();for(let a=0;a0))break;t[r].g_factory.Oil>t[r].g_factory.Coal?t[r].g_factory.Coal>0?t[r].g_factory.Coal--:t[r].g_factory.Oil--:t[r].g_factory.Oil>0?t[r].g_factory.Oil--:t[r].g_factory.Coal--,t[r].g_factory.Lumber++}},subCoal(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Coal--},addCoal(){let e=y();for(let a=0;a0))break;t[r].g_factory.Lumber>0?t[r].g_factory.Lumber--:t[r].g_factory.Oil--,t[r].g_factory.Coal++}},subOil(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Oil--},addOil(){let e=y();for(let a=0;a0))break;t[r].g_factory.Lumber>0?t[r].g_factory.Lumber--:t[r].g_factory.Coal--,t[r].g_factory.Oil++}},buildLabel:e=>c(e),ariaCount:e=>` ${t[r].g_factory[e]} ${e} fueled.`,ariaProd:e=>`. ${t[r].g_factory[e]} producing ${e}.`,level:()=>Xs(t[r].g_factory.Lumber+t[r].g_factory.Coal+t[r].g_factory.Oil,t[r].g_factory.on)},filters:{on:function(e){return t[r].g_factory.Lumber+t[r].g_factory.Coal+t[r].g_factory.Oil}}}),["wood","coal","oil"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iGraphene";Ti(`${a}${t}`,(function(){return c(t)}),{elm:$(`#${a} > div > .${t}`),attach:"#main"})}))}(a,r);break;case"pylon":!function(e,a){let r=$(`
      ${F("modal_pylon_casting")}: {{total | drain}}
      `);e.append(r);let s=$('
      ');e.append(s);let i=[];function c(e){let a=+Ys(t.race.casting[e]).toFixed(4),r=+(Ys(t.race.casting[e]+1)-Ys(t.race.casting[e])).toFixed(4),s=+(t.race.casting[e]/(t.race.casting[e]+75)*100).toFixed(2);return"crafting"===e?F("modal_pylon_casting_label_crafting",[a,s,+(2*t.race.casting[e]/(2*t.race.casting[e]+75)*100).toFixed(2),r]):F("modal_pylon_casting_label",[F(`modal_pylon_spell_${e}`),a,r,s])}i=t.race.orbit_decayed?["miner","science","factory","army","hunting","crafting"]:t.race.cataclysm?["science","factory","army","hunting","crafting"]:t.race.unfathomable?["miner","lumberjack","science","factory","army","hunting","crafting"]:["farmer","miner","lumberjack","science","factory","army","hunting","crafting"],t.tech.magic&&t.tech.magic>=3&&i.forEach((function(e){if("crafting"!==e&&"lumberjack"!==e&&"farmer"!==e||"farmer"===e&&!t.race.detritivore&&!t.race.carnivore&&!t.race.soul_eater&&!t.race.artifical||"lumberjack"===e&&!t.race.kindling_kindred&&!t.race.smoldering&&!t.race.evil||"crafting"===e&&t.tech.magic>=4){let t=$(`${F(`modal_pylon_spell_${e}`)} {{ ${e} }}`),a=$(`«`),r=$(`»`);s.append(a),s.append(t),s.append(r)}})),sc({el:a||"#specialModal",data:t.race.casting,methods:{buildLabel:e=>c(e),addSpell(e){let a=y();for(let r=0;r=a))break;t.race.casting[e]++,t.race.casting.total++,t.resource.Mana.diff-=a}},subSpell(e){let a=y();for(let r=0;r0;r++)t.race.casting[e]--,t.race.casting.total--},ariaCount:e=>` ${e} casting.`,level:()=>Xs(t.race.casting.total,t.resource.Mana.gen,!0)},filters:{drain:function(e){let a=0;return i.forEach((function(e){t.race.casting[e]&&t.race.casting[e]>0&&(a+=Ys(t.race.casting[e]))})),F("modal_pylon_casting_cost",[+a.toFixed(3)])}}}),i.forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iPylon";Ti(`${a}${t}`,(function(){return c(t)}),{elm:$(`#${a} > .pylon > .${t}`),attach:"#main"})}))}(a,r);break;case"rock_quarry":!function(e,a){e.append($(`
      ${F("modal_quarry_ratio",[t.resource.Chrysotile.name])}
      `));let r=$('
      «»
      ');e.append(r),sc({el:a||"#specialModal",data:t.city.rock_quarry,methods:{sub(){let e=y();t.city.rock_quarry.asbestos>0&&(t.city.rock_quarry.asbestos-=e,t.city.rock_quarry.asbestos<0&&(t.city.rock_quarry.asbestos=0))},add(){let e=y();t.city.rock_quarry.asbestos<100&&(t.city.rock_quarry.asbestos+=e,t.city.rock_quarry.asbestos>100&&(t.city.rock_quarry.asbestos=100))}}})}(a,r);break;case"titan_mine":!function(e,a){e.append($(`
      ${F("modal_quarry_ratio",[t.resource.Adamantite.name])}
      `));let r=$('
      «»
      ');e.append(r),sc({el:a||"#specialModal",data:t.space.titan_mine,methods:{sub(){let e=y();t.space.titan_mine.ratio>0&&(t.space.titan_mine.ratio-=e,t.space.titan_mine.ratio<0&&(t.space.titan_mine.ratio=0))},add(){let e=y();t.space.titan_mine.ratio<100&&(t.space.titan_mine.ratio+=e,t.space.titan_mine.ratio>100&&(t.space.titan_mine.ratio=100))}}})}(a,r);break;case"nanite_factory":!function(e,a){let r=$(`
      ${F("modal_factory_operate")}: {{count | on}}/{{ count | max }}
      `);e.append(r);let s=e.hasClass("modalBody")?"mNFactoryRes":"NFactoryRes",i=$(`
      `);e.append(i),Vs.forEach((function(e){if(t.resource[e].display){let a=$(`${t.resource[e].name} {{ ${e} }}`),r=$(`«`),s=$(`»`);i.append(r),i.append(a),i.append(s)}})),sc({el:a||"#specialModal",data:t.city.nanite_factory,methods:{subItem:function(e){let a=y();t.city.nanite_factory[e]-=a,t.city.nanite_factory[e]<0&&(t.city.nanite_factory[e]=0)},addItem:function(e){let a=y(),r=0;Vs.forEach((function(e){r+=t.city.nanite_factory[e]}));let s=50*t.city.nanite_factory.count-r;a>s&&(a=s),a>0&&(t.city.nanite_factory[e]+=a)},eatLabel:e=>`Consume ${e} to produce ${t.resource.Nanite.name}`,level(){let e=0;Vs.forEach((function(a){e+=t.city.nanite_factory[a]}));let a=t.city.nanite_factory.count;return Xs(e,a)}},filters:{on(){let e=0;return Vs.forEach((function(a){e+=t.city.nanite_factory[a]})),e},max:()=>50*t.city.nanite_factory.count}}),Vs.forEach((function(a){let r=e.hasClass("modalBody")?"specialModal":"iNFactory";Ti(`${r}${a}`,(function(){return function(e){let a=+(Va[e]/100*(ui.deconstructor.vars()[0]/100)).toFixed(4),r=+(t.city.nanite_factory[e]*a).toFixed(4);return F("modal_nfactory_resource_label",[1,t.resource[e].name,a,t.resource.Nanite.name,t.city.nanite_factory[e],r])}(a)}),{elm:$(`#${r} > .fuels > .${a}`),attach:"#main"})}))}(a,r);break;case"mining_ship":!function(e,a){e.append($(`
      ${F("tau_roid_mining_ship_ratio",[t.resource.Iron.name,t.resource.Aluminium.name])}
      `));let r=$('
      «»
      ');e.append(r),e.append($(`
      ${F("tau_roid_mining_ship_ratio",[t.resource.Iridium.name,t.resource.Neutronium.name])}
      `));let s=$('
      «»
      ');if(e.append(s),t.tech.tau_roid>=5){e.append($(`
      ${F("tau_roid_mining_ship_ratio",[t.resource.Orichalcum.name,t.resource.Elerium.name])}
      `));let a=$('
      «»
      ');e.append(a)}sc({el:a||"#specialModal",data:t.tauceti.mining_ship,methods:{sub(e){let a=y();t.tauceti.mining_ship[e]>0&&(t.tauceti.mining_ship[e]-=a,t.tauceti.mining_ship[e]<0&&(t.tauceti.mining_ship[e]=0))},add(e){let a=y();t.tauceti.mining_ship[e]<100&&(t.tauceti.mining_ship[e]+=a,t.tauceti.mining_ship[e]>100&&(t.tauceti.mining_ship[e]=100))}}})}(a,r);break;case"alien_space_station":!function(e,a){e.append($(`
      ${F("tau_gas2_alien_station_focus",[t.resource.Knowledge.name])}
      `));let r=$('
      «»
      ');e.append(r),sc({el:a||"#specialModal",data:t.tauceti.alien_space_station,methods:{sub(e){let a=y();t.tauceti.alien_space_station[e]>0&&(t.tauceti.alien_space_station[e]-=a,t.tauceti.alien_space_station[e]<0&&(t.tauceti.alien_space_station[e]=0))},add(e){let a=y();t.tauceti.alien_space_station[e]<100&&(t.tauceti.alien_space_station[e]+=a,t.tauceti.alien_space_station[e]>100&&(t.tauceti.alien_space_station[e]=100))}}})}(a,r);break;case"replicator":!function(e,a){if(t.race.replicator){e.append($(`
      ${"antimatter"===t.race.universe?F("tech_antireplicator"):F("tech_replicator")}
      `));let r=$('
      ');if(e.append(r),a){let e="";Object.keys(Va).forEach((function(a){e+=`${t.resource[a].name}`})),r.append(`
      \n ${e}\n
      `)}else{let e="";Object.keys(Va).forEach((function(a){t.resource[a].display&&(e+=`${t.resource[a].name}`)})),r.append(`
      ${e}
      `)}let s=a?$("
      "):$('
      ');r.append(s);let i=$('{{ pow }}MW'),c=$('«'),o=$('»');if(s.append(c),s.append(i),s.append(o),e.append('
      {{ res | result }}
      '),sc({el:a||"#specialModal",data:t.race.replicator,methods:{less(){let e=y();t.race.replicator.pow>0&&(t.race.replicator.pow-=e,t.race.replicator.pow<0&&(t.race.replicator.pow=0))},more(){let e=y();t.race.replicator.pow+=e},setVal(e){t.resource[e].display&&(t.race.replicator.res=e)},avail:e=>t.resource[e].display,aria:()=>t.race.replicator.pow+"MW"},filters:{resName:e=>t.resource[e].name,result:e=>F("tau_replicator",[Js(e,t.race.replicator.pow).toFixed(3),t.resource[e].name])}}),!a){const e=document.getElementById("hscrolltarget");e.addEventListener("wheel",(t=>{t.preventDefault(),e.scrollLeft+=t.deltaY}))}}}(a,r)}}function Ws(){if(t.settings.tabLoad||2===t.settings.civTabs&&1===t.settings.govTabs){if(rc($("#industry")),t.city.smelter&&(t.city.smelter.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation)){var e=$(`

      ${F("city_smelter")}

      `);$("#industry").append(e),Us("smelter",e,"#iSmelter")}if(t.city.factory&&t.city.factory.count>0||t.space.red_factory&&t.space.red_factory.count>0||t.tauceti.tau_factory&&t.tauceti.tau_factory.count>0){var a=$(`

      ${F("city_factory")}

      `);$("#industry").append(a),Us("factory",a,"#iFactory")}if(t.interstellar.mining_droid&&t.interstellar.mining_droid.count>0){var r=$(`

      ${F("interstellar_mining_droid_title")}

      `);$("#industry").append(r),Us("droid",r,"#iDroid")}if(t.interstellar.g_factory&&t.interstellar.g_factory.count>0||t.space.g_factory&&(t.space.g_factory.count>0||t.tauceti.refueling_station&&t.tauceti.refueling_station.count>0)){var s=$(`

      ${F("interstellar_g_factory_title")}

      `);$("#industry").append(s),Us("graphene",s,"#iGraphene")}if(t.race.casting&&(t.city.pylon||t.space.pylon||t.tauceti.pylon)){var i=$(`

      ${F("city_pylon")}

      `);$("#industry").append(i),Us("pylon",i,"#iPylon")}if(t.race.smoldering&&t.city.rock_quarry&&!t.race.cataclysm&&!t.race.orbit_decayed&&!t.tech.isolation){var c=$(`

      ${F("city_rock_quarry")}

      `);$("#industry").append(c),Us("rock_quarry",c,"#iQuarry")}if(t.space.titan_mine&&t.space.titan_mine.count>0&&(c=$(`

      ${F("city_mine")}

      `),$("#industry").append(c),Us("titan_mine",c,"#iTMine")),t.tech.tau_roid&&t.tech.tau_roid>=4&&t.tauceti.mining_ship){var o=$(`

      ${F("tau_roid_mining_ship")}

      `);$("#industry").append(o),Us("mining_ship",o,"#iMiningShip")}if(t.tech.tau_gas2&&6===t.tech.tau_gas2&&t.tauceti.alien_space_station&&(!t.tech.alien_data||t.tech.alien_data<6)){var n=$(`

      ${F("tau_gas2_alien_station")}

      `);$("#industry").append(n),Us("alien_space_station",n,"#iAlienSpaceStation")}if(t.race.deconstructor&&t.city.nanite_factory){var l=$(`

      ${F("city_nanite_factory")}

      `);$("#industry").append(l),Us("nanite_factory",l,"#iNFactory")}if(t.race.replicator&&t.tech.replicator){var u=$(`

      ${"antimatter"===t.race.universe?F("tech_antireplicator"):F("tech_replicator")}

      `);$("#industry").append(u),Us("replicator",u,"#iReplicator")}}}Object.keys(es).forEach((e=>Qr.evolution[e]={id:`evolution-${e}`,title:F(`evo_challenge_${e}`),desc(){let a="";return"micro"===t.race.universe&&(a+=`
      ${F("evo_challenge_micro_warn")}
      `),a+=`
      ${F(`evo_challenge_${e}_desc`)}
      `,["sludge","junker"].includes(e)&&(a+=`
      ${F("evo_start")}
      `),a},condition:()=>t.evolution.hasOwnProperty(e),cost:{DNA:()=>"c"===es[e].t?25:50},challenge:!0,effect:()=>as(e),action(){return Os($(this)[0])&&("c"===es[e].t?function(e){t.race[e]?(delete t.race[e],$(`#evolution-${e}`).removeClass("hl"),"sludge"===e&&Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).removeClass("is-hidden")}))):(t.race[e]=1,$(`#evolution-${e}`).addClass("hl"),"sludge"===e&&(Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).addClass("is-hidden")})),t.race.junker&&delete t.race.junker),"orbit_decay"===e&&(delete t.race.cataclysm,t.race.lone_survivor&&(delete t.race.lone_survivor,["nerfed","badgenes"].forEach((function(e){delete t.race[Xr[e]]}))))),Zr(),ao()}(e):function(e){if(t.race.sludge||Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).removeClass("is-hidden")})),t.race[e])delete t.race[e],$(`#evolution-${e}`).removeClass("hl"),["nerfed","badgenes"].forEach((function(e){delete t.race[Xr[e]]}));else{["junker","cataclysm","banana","truepath","lone_survivor"].forEach((function(e){delete t.race[e],$(`#evolution-${e}`).removeClass("hl")})),t.race[e]=1,$(`#evolution-${e}`).addClass("hl"),"junker"===e&&(Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).addClass("is-hidden")})),t.race.sludge&&delete t.race.sludge),"cataclysm"!==e&&"lone_survivor"!==e||delete t.race.orbit_decay,"truepath"===e||"lone_survivor"===e?(t.race.nerfed=1,["crispr","plasmid","mastery"].forEach((function(e){delete t.race[Xr[e]]}))):(["nerfed","badgenes"].forEach((function(e){delete t.race[Xr[e]]})),"antimatter"===t.race.universe?(t.race.weak_mastery=1,$("#evolution-mastery").hasClass("hl")||$("#evolution-mastery").addClass("hl")):(t.race.no_plasmid=1,$("#evolution-plasmid").hasClass("hl")||$("#evolution-plasmid").addClass("hl")));let a="truepath"===e||"lone_survivor"===e?["badgenes","trade","craft"]:["crispr","trade","craft"];for(let e=0;ePc(es[e].e),highlight:()=>!!t.race[e],queue_complete:()=>0})),Qr.evolution.bunker={id:"evolution-bunker",title:F("evo_bunker"),desc:()=>`
      ${F("evo_bunker")}
      ${F("evo_challenge")}
      `,reqs:{evo:6},grant:["evo_challenge",1],condition:()=>t.genes.challenge&&100===t.evolution.final&&!t.race.evoFinalMenu,cost:{DNA:()=>10},effect:F("evo_bunker_effect"),action(){return!!Os($(this)[0])},queue_complete:()=>t.tech.evo_challenge?0:1,flair:F("evo_bunker_flair")};const Qs={Lux:{demand:[.14,.21,.28,.35,.42],fur:[2,3,4,5,6]},Furs:{money:[10,15,20,25,30],polymer:[1.5,2.25,3,3.75,4.5],output:[1,1.5,2,2.5,3]},Alloy:{copper:[.75,1.12,1.49,1.86,2.23],aluminium:[1,1.5,2,2.5,3],output:[.075,.112,.149,.186,.223]},Polymer:{oil_kk:[.22,.33,.44,.55,.66],oil:[.18,.27,.36,.45,.54],lumber:[15,22,29,36,43],output:[.125,.187,.249,.311,.373]},Nano_Tube:{coal:[8,12,16,20,24],neutronium:[.05,.075,.1,.125,.15],output:[.2,.3,.4,.5,.6]},Stanene:{aluminium:[30,45,60,75,90],nano:[.02,.03,.04,.05,.06],output:[.6,.9,1.2,1.5,1.8]}};function Zs(e){t.race.toxic&&(e*=1+ui.toxic.vars()[0]/100);let a=Pi("shroomi");return a>0&&(e*=1+ui.toxic.vars(1)[0]/100*a),"corpocracy"===t.civic.govern.type&&(e*=2.5),"socialist"===t.civic.govern.type&&(e*=.8),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(e*=1.1),t.race.inflation&&(e*=1+t.race.inflation/1250),t.tech.isolation&&(e*=1+.5*(c.colony||0)),e*Pe("psychic_cash")}const Vs=["Lumber","Chrysotile","Stone","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal","Oil","Uranium","Steel","Titanium","Alloy","Polymer","Iridium","Helium_3","Water","Deuterium","Neutronium","Adamantite","Bolognium","Orichalcum"];function Js(e,a){return t.race.lone_survivor?17.5*u/Va[e]*a:12.5*(u||1)/Va[e]*a**.75}function Ys(e,t){return e*((1+(t=void 0===t?.0025:t))**e-1)}function Xs(e,t,a){return e<=0?a?"has-text-success":"has-text-danger":e>=t?a?"has-text-danger":"has-text-success":e<=t/3?a?"has-text-info":"has-text-caution":e<=.66*t?"has-text-warning":e
      ${F("power_grid_header")}
      Distribute Low Power
      `),sc({el:"#powerModeSwitch",data:t.settings}),Object.keys(e).forEach((function(a){if(!e[a].s)return;let r="";"power"===a&&(r=kc(7,12,!1)),e[a].r&&e[a].rs&&t[e[a].r][e[a].rs]?($("#powerGrid").append(`
      ${e[a].n} {{ support }}/{{ s_max }}
      `),sc({el:`#pg${a}sup`,data:t[e[a].r][e[a].rs]})):$("#powerGrid").append(`
      ${e[a].n}${r}
      `);let s=$(`
      `);$("#powerGrid").append(s);let i=0;for(let r=0;r`);o.append(` ${u}${d}`),o.append('{{ on | off }} {{ on }}'),o.append('« »'),s.append(o),sc({el:`#pg${l.id}${a}`,data:t[n][c[1]],methods:{power_on(){let e=y();for(let a=0;a0;a++)t[n][c[1]].on--;l.postPower&&setTimeout((function(){l.postPower(!1)}),250)},higher(){let t=$(`#pg${l.id}${a}`).attr("data-idx"),r=$(`#pg${l.id}${a}`).prevAll('.circuit:not(".inactive")').attr("data-idx");if(r>=0){let s=e[a].l;s.splice(r,0,s.splice(t,1)[0]),e[a].l=s,ti()}},lower(){let t=$(`#pg${l.id}${a}`).attr("data-idx"),r=$(`#pg${l.id}${a}`).nextAll('.circuit:not(".inactive")').attr("data-idx");if(rt[n][c[1]].count-e,idx(e){let t=$c(18,11);return 10===e&&t.length>0?"1"+t:e}}})}else{let e=$(`
      `);e.append(`${u}${d}`),s.append(e)}}!function(e){let t=$(`#grid${e}`)[0],a=ai();Sortable.create(t,{onEnd(t){let r=a[e].l;r.splice(t.newDraggableIndex,0,r.splice(t.oldDraggableIndex,1)[0]),a[e].l=r,ti()}})}(a);let c=$(`
      `);$("#powerGrid").append(c),sc({el:`#${a}GridReset`,data:{},methods:{resetGrid(e){Li(e,!0),ti()}}})}))}function ai(){return{power:{l:t.power,n:F("power"),s:!0,r:!1,rs:!1},moon:{l:t.support.moon,n:F("space_moon_info_name"),s:t.settings.space.moon,r:"space",rs:"moon_base"},red:{l:t.support.red,n:Xt().red,s:t.settings.space.red,r:"space",rs:"spaceport"},belt:{l:t.support.belt,n:F("space_belt_info_name"),s:t.settings.space.belt,r:"space",rs:"space_station"},alpha:{l:t.support.alpha,n:F("interstellar_alpha_name"),s:t.settings.space.alpha,r:"interstellar",rs:"starport"},nebula:{l:t.support.nebula,n:F("interstellar_nebula_name"),s:t.settings.space.nebula,r:"interstellar",rs:"nexus"},gateway:{l:t.support.gateway,n:F("galaxy_gateway"),s:t.settings.space.gateway,r:"galaxy",rs:"starbase"},alien2:{l:t.support.alien2,n:F("galaxy_alien",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),s:t.settings.space.alien2,r:"galaxy",rs:"foothold"},lake:{l:t.support.lake,n:F("portal_lake_name"),s:t.settings.portal.lake,r:"portal",rs:"harbour"},spire:{l:t.support.spire,n:F("portal_spire_name"),s:t.settings.portal.spire,r:"portal",rs:"purifier"},titan:{l:t.support.titan,n:Xt().titan,s:t.settings.space.titan,r:"space",rs:"electrolysis"},enceladus:{l:t.support.enceladus,n:Xt().enceladus,s:t.settings.space.enceladus,r:"space",rs:"titan_spaceport"},eris:{l:t.support.eris,n:Xt().eris,s:t.settings.space.eris,r:"space",rs:"drone_control"},tau_home:{l:t.support.tau_home,n:F("tau_planet",[di[t.race.species].home]),s:t.settings.tau.home,r:"tauceti",rs:"orbital_station"},tau_red:{l:t.support.tau_red,n:F("tau_planet",[Xt().red]),s:t.settings.tau.red,r:"tauceti",rs:"orbital_platform"},tau_roid:{l:t.support.tau_roid,n:F("tau_roid_title"),s:t.settings.tau.roid,r:"tauceti",rs:"patrol_ship"}}}function ri(e){e=e||ai(),Object.keys(e).forEach((function(e){let t=$(`#grid${e}`)[0];if(t){let e=Sortable.get(t);e&&e.destroy()}}))}const si=new Date,ii=Ec(),ci=Ic(),oi=["diverse","arrogant","angry","lazy","paranoid","greedy","puny","dumb","nearsighted","gluttony","slow","hard_of_hearing","pessimistic","solitary","pyrophobia","skittish","nyctophilia","frail","atrophy","invertebrate","pathetic","invertebrate","unorganized","slow_regen","snowy","mistrustful","fragrant","freespirit","hooved","heavy","gnawer"];function ni(e,a){if(t.settings.boring)return t.race.hrt&&delete t.race.hrt,!1;switch(e){case"elven":case"capybara":case"centaur":case"wendigo":case"entish":case"yeti":return!!(11===si.getMonth()&&si.getDate()>=17||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"wolven":case"vulpine":return!!(ii.active||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"arraak":return!!(10===si.getMonth()&&si.getDate()>=22&&si.getDate()<=28||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"seraph":return!!(1===si.getMonth()&&14===si.getDate()||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"junker":return!!(ci.active||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0)}return!1}const li={humanoid:{adaptable:1,wasteful:1},carnivore:{carnivore:1,beast:1,cautious:1},herbivore:{herbivore:1,instinct:1},small:{small:1,weak:1},giant:{large:1,strong:1},reptilian:{cold_blooded:1,scales:1},avian:{flier:1,hollow_bones:1,sky_lover:1},insectoid:{high_pop:1,fast_growth:1,high_metabolism:1},plant:{sappy:1,asymmetrical:1},fungi:{detritivore:1,spongy:1},aquatic:{submerged:1,low_light:1},fey:{elusive:1,iron_allergy:1},heat:{smoldering:1,cold_intolerance:1},polar:{chilled:1,heat_intolerance:1},sand:{scavenger:1,nomadic:1},demonic:{immoral:1,evil:1,soul_eater:1},angelic:{blissful:1,pompous:1,holy:1},synthetic:{artifical:1,powered:1},eldritch:{psychic:1,tormented:1,darkness:1,unfathomable:1}},ui={adaptable:{name:F("trait_adaptable_name"),desc:F("trait_adaptable"),type:"genus",val:3,vars(e){switch(e||t.race.adaptable||1){case.25:return[3];case.5:return[5];case 1:return[10];case 2:return[15];case 3:return[20]}}},wasteful:{name:F("trait_wasteful_name"),desc:F("trait_wasteful"),type:"genus",val:-3,vars(e){switch(e||t.race.wasteful||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[6];case 3:return[4]}}},xenophobic:{name:F("trait_xenophobic_name"),desc:F("trait_xenophobic"),type:"genus",val:-5},carnivore:{name:F("trait_carnivore_name"),desc:F("trait_carnivore"),type:"genus",val:3,vars(e){switch(e||t.race.carnivore||1){case.25:return[65];case.5:return[60];case 1:return[50];case 2:return[40];case 3:return[35]}}},beast:{name:F("trait_beast_name"),desc:F("trait_beast"),type:"genus",val:2,vars(e){switch(e||t.race.beast||1){case.25:return[4,8,4];case.5:return[5,10,5];case 1:return[8,15,10];case 2:return[10,20,15];case 3:return[12,24,20]}}},cautious:{name:F("trait_cautious_name"),desc:F("trait_cautious"),type:"genus",val:-2,vars(e){switch(e||t.race.cautious||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},herbivore:{name:F("trait_herbivore_name"),desc:F("trait_herbivore"),type:"genus",val:-7},instinct:{name:F("trait_instinct_name"),desc:F("trait_instinct"),type:"genus",val:5,vars(e){switch(e||t.race.instinct||1){case.25:return[3,15];case.5:return[5,25];case 1:return[10,50];case 2:return[15,60];case 3:return[20,65]}}},small:{name:F("trait_small_name"),desc:F("trait_small"),type:"genus",val:6,vars(e){switch(e||t.race.small||1){case.25:return[.0025,.0015];case.5:return[.005,.0025];case 1:return[.01,.005];case 2:return[.0125,.006];case 3:return[.015,.0075]}}},weak:{name:F("trait_weak_name"),desc:F("trait_weak"),type:"genus",val:-3,vars(e){switch(e||t.race.weak||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},large:{name:F("trait_large_name"),desc:F("trait_large"),type:"genus",val:-5,vars(e){switch(e||t.race.large||1){case.25:return[.007];case.5:return[.006];case 1:return[.005];case 2:return[.004];case 3:return[.003]}}},strong:{name:F("trait_strong_name"),desc:F("trait_strong"),type:"genus",val:5,vars(e){switch(e||t.race.strong||1){case.25:return[2,1.25];case.5:return[3,1.5];case 1:return[4,2];case 2:return[5,2.25];case 3:return[6,2.5]}}},cold_blooded:{name:F("trait_cold_blooded_name"),desc:F("trait_cold_blooded"),type:"genus",val:-2,vars(e){switch(e||t.race.cold_blooded||1){case.25:return[30,6];case.5:return[25,8];case 1:return[20,10];case 2:return[15,15];case 3:return[12,18]}}},scales:{name:F("trait_scales_name"),desc:F("trait_scales"),type:"genus",val:5,vars(e){switch(e||t.race.scales||1){case.25:return[1,0,1];case.5:return[1,1,1];case 1:return[2,1,1];case 2:return[2,2,1];case 3:return[2,2,2]}}},flier:{name:F("trait_flier_name"),desc:F("trait_flier"),type:"genus",val:3,vars(e){switch(e||t.race.flier||1){case.25:return[10,0];case.5:return[15,0];case 1:return[25,1];case 2:return[40,1];case 3:return[50,2]}}},hollow_bones:{name:F("trait_hollow_bones_name"),desc:F("trait_hollow_bones"),type:"genus",val:2,vars(e){switch(e||t.race.hollow_bones||1){case.25:return[1];case.5:return[2];case 1:return[5];case 2:return[8];case 3:return[10]}}},sky_lover:{name:F("trait_sky_lover_name"),desc:F("trait_sky_lover"),type:"genus",val:-2,vars(e){switch(e||t.race.sky_lover||1){case.25:return[40];case.5:return[30];case 1:return[20];case 2:return[15];case 3:return[10]}}},rigid:{name:F("trait_rigid_name"),desc:F("trait_rigid"),type:"genus",val:-2,vars(e){switch(e||t.race.rigid||1){case.25:return[3];case.5:return[2];case 1:return[1];case 2:return[.5];case 3:return[.4]}}},high_pop:{name:F("trait_high_pop_name"),desc:F("trait_high_pop"),type:"genus",val:3,vars(e){switch(e||t.race.high_pop||1){case.25:return[2,50,1.5];case.5:return[3,34,2.5];case 1:return[4,26,3.5];case 2:return[5,21.2,4.5];case 3:return[6,18,5.5]}}},fast_growth:{name:F("trait_fast_growth_name"),desc:F("trait_fast_growth"),type:"genus",val:2,vars(e){switch(e||t.race.fast_growth||1){case.25:return[1.5,1];case.5:return[2,1];case 1:return[2,2];case 2:return[2.5,3];case 3:return[3,3]}}},high_metabolism:{name:F("trait_high_metabolism_name"),desc:F("trait_high_metabolism"),type:"genus",val:-1,vars(e){switch(e||t.race.high_metabolism||1){case.25:return[10];case.5:return[8];case 1:return[5];case 2:return[2];case 3:return[1]}}},photosynth:{name:F("trait_photosynth_name"),desc:F("trait_photosynth"),type:"genus",val:3,vars(e){switch(e||t.race.photosynth||1){case.25:return[10,5,4];case.5:return[20,10,5];case 1:return[40,20,10];case 2:return[50,30,15];case 3:return[60,35,20]}}},sappy:{name:F("trait_sappy_name"),desc:F("trait_sappy",[F("resource_Amber_name")]),type:"genus",val:4,vars(e){switch(e||t.race.sappy||1){case.25:return[.4];case.5:return[.5];case 1:return[.6];case 2:return[.65];case 3:return[.7]}}},asymmetrical:{name:F("trait_asymmetrical_name"),desc:F("trait_asymmetrical"),type:"genus",val:-3,vars(e){switch(e||t.race.asymmetrical||1){case.25:return[30];case.5:return[25];case 1:return[20];case 2:return[15];case 3:return[10]}}},detritivore:{name:F("trait_detritivore_name"),desc:F("trait_detritivore"),type:"genus",val:2,vars(e){switch(e||t.race.detritivore||1){case.25:return[65];case.5:return[72];case 1:return[80];case 2:return[85];case 3:return[90]}}},spores:{name:F("trait_spores_name"),desc:F("trait_spores"),type:"genus",val:2,vars(e){switch(e||t.race.spores||1){case.25:return[1,1.5,1];case.5:return[2,1.5,1];case 1:return[2,2,1];case 2:return[2,2.5,2];case 3:return[2,3,2]}}},spongy:{name:F("trait_spongy_name"),desc:F("trait_spongy"),type:"genus",val:-2},submerged:{name:F("trait_submerged_name"),desc:F("trait_submerged"),type:"genus",val:3},low_light:{name:F("trait_low_light_name"),desc:F("trait_low_light"),type:"genus",val:-2,vars(e){switch(e||t.race.low_light||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},elusive:{name:F("trait_elusive_name"),desc:F("trait_elusive"),type:"genus",val:7,vars(e){switch(e||t.race.elusive||1){case.25:return[10];case.5:return[15];case 1:return[20];case 2:return[25];case 3:return[30]}}},iron_allergy:{name:F("trait_iron_allergy_name"),desc:F("trait_iron_allergy"),type:"genus",val:-4,vars(e){switch(e||t.race.iron_allergy||1){case.25:return[40];case.5:return[35];case 1:return[25];case 2:return[18];case 3:return[15]}}},smoldering:{name:F("trait_smoldering_name"),desc:F("trait_smoldering"),type:"genus",val:7,vars(e){switch(e||t.race.smoldering||1){case.25:return[3,.14,.08];case.5:return[4,.18,.1];case 1:return[5,.35,.2];case 2:return[10,.38,.22];case 3:return[12,.4,.24]}}},cold_intolerance:{name:F("trait_cold_intolerance_name"),desc:F("trait_cold_intolerance"),type:"genus",val:-4,vars(e){switch(e||t.race.cold_intolerance||1){case.25:return[.35];case.5:return[.3];case 1:return[.25];case 2:return[.2];case 3:return[.18]}}},chilled:{name:F("trait_chilled_name"),desc:F("trait_chilled"),type:"genus",val:7,vars(e){switch(e||t.race.chilled||1){case.25:return[1,.14,.08,5,2,20];case.5:return[2,.18,.1,10,5,18];case 1:return[5,.35,.2,20,10,15];case 2:return[10,.38,.22,25,12,10];case 3:return[12,.4,.24,30,14,8]}}},heat_intolerance:{name:F("trait_heat_intolerance_name"),desc:F("trait_heat_intolerance"),type:"genus",val:-4,vars(e){switch(e||t.race.heat_intolerance||1){case.25:return[.35];case.5:return[.3];case 1:return[.25];case 2:return[.2];case 3:return[.18]}}},scavenger:{name:F("trait_scavenger_name"),desc:F("trait_scavenger"),type:"genus",val:3,vars(e){switch(e||t.race.scavenger||1){case.25:return[.08,20];case.5:return[.1,22];case 1:return[.12,25];case 2:return[.14,30];case 3:return[.16,32]}}},nomadic:{name:F("trait_nomadic_name"),desc:F("trait_nomadic"),type:"genus",val:-5},immoral:{name:F("trait_immoral_name"),desc:F("trait_immoral"),type:"genus",val:4,vars(e){switch(e||t.race.immoral||1){case.25:return[-30];case.5:return[-20];case 1:return[0];case 2:return[20];case 3:return[30]}}},evil:{name:F("trait_evil_name"),desc:F("trait_evil"),type:"genus",val:0},blissful:{name:F("trait_blissful_name"),desc:F("trait_blissful"),type:"genus",val:3,vars(e){switch(e||t.race.blissful||1){case.25:return[70];case.5:return[60];case 1:return[50];case 2:return[40];case 3:return[30]}}},pompous:{name:F("trait_pompous_name"),desc:F("trait_pompous"),type:"genus",val:-6,vars(e){switch(e||t.race.pompous||1){case.25:return[85];case.5:return[80];case 1:return[75];case 2:return[65];case 3:return[60]}}},holy:{name:F("trait_holy_name"),desc:F("trait_holy"),type:"genus",val:4,vars(e){switch(e||t.race.holy||1){case.25:return[25,10];case.5:return[30,15];case 1:return[50,25];case 2:return[60,35];case 3:return[65,40]}}},artifical:{name:F("trait_artifical_name"),desc:F("trait_artifical"),type:"genus",val:5,vars(e){switch(e||t.race.artifical||1){case.25:return[5];case.5:return[10];case 1:return[20];case 2:return[25];case 3:return[30]}}},powered:{name:F("trait_powered_name"),desc:F("trait_powered"),type:"genus",val:-6,vars(e){switch(e||t.race.powered||1){case.25:return[.35,5];case.5:return[.3,8];case 1:return[.2,16];case 2:return[.1,20];case 3:return[.05,24]}}},psychic:{name:F("trait_psychic_name"),desc:F("trait_psychic"),type:"genus",val:10,vars(e){switch(e||t.race.psychic||1){case.25:return[.35,5,.01,20];case.5:return[.65,10,.025,30];case 1:return[1,15,.05,40];case 2:return[1.25,20,.075,50];case 3:return[1.5,25,.1,60]}}},tormented:{name:F("trait_tormented_name"),desc:F("trait_tormented"),type:"genus",val:-25,vars(e){switch(e||t.race.tormented||1){case.25:return[99];case.5:return[95];case 1:return[90];case 2:return[80];case 3:return[75]}}},darkness:{name:F("trait_darkness_name"),desc:F("trait_darkness"),type:"genus",val:1,vars(e){switch(e||t.race.darkness||1){case.25:return[1];case.5:return[2];case 1:return[3];case 2:return[4];case 3:return[5]}}},unfathomable:{name:F("trait_unfathomable_name"),desc:F("trait_unfathomable"),type:"genus",val:15,vars(e){switch(e||t.race.unfathomable||1){case.25:return[1,.5,.05];case.5:return[1,.65,.08];case 1:return[2,.8,.1];case 2:return[2,.9,.12];case 3:return[3,1,.13]}}},creative:{name:F("trait_creative_name"),desc:F("trait_creative"),type:"major",val:8,vars(e){switch(e||t.race.creative||1){case.25:return[.0015,5];case.5:return[.0025,10];case 1:return[.005,20];case 2:return[.006,22];case 3:return[.0065,24]}}},diverse:{name:F("trait_diverse_name"),desc:F("trait_diverse"),type:"major",val:-4,vars(e){switch(e||t.race.diverse||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},studious:{name:F("trait_studious_name"),desc:F("trait_studious"),type:"major",val:2,vars(e){switch(e||t.race.studious||1){case.25:return[.1,6];case.5:return[.15,8];case 1:return[.25,10];case 2:return[.35,12];case 3:return[.4,14]}}},arrogant:{name:F("trait_arrogant_name"),desc:F("trait_arrogant"),type:"major",val:-2,vars(e){switch(e||t.race.arrogant||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},brute:{name:F("trait_brute_name"),desc:F("trait_brute"),type:"major",val:7,vars(e){switch(e||t.race.brute||1){case.25:return[20,50];case.5:return[25,60];case 1:return[50,100];case 2:return[60,120];case 3:return[65,140]}}},angry:{name:F("trait_angry_name"),desc:F("trait_angry"),type:"major",val:-1,vars(e){switch(e||t.race.angry||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},lazy:{name:F("trait_lazy_name"),desc:F("trait_lazy"),type:"major",val:-4,vars(e){switch(e||t.race.lazy||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},curious:{name:F("trait_curious_name"),desc:F("trait_curious"),type:"major",val:4,vars(e){switch(e||t.race.curious||1){case.25:return[.03];case.5:return[.05];case 1:return[.1];case 2:return[.12];case 3:return[.13]}}},pack_mentality:{name:F("trait_pack_mentality_name"),desc:F("trait_pack_mentality"),type:"major",val:4,vars(e){switch(e||t.race.pack_mentality||1){case.25:return[.04,.016];case.5:return[.035,.018];case 1:return[.03,.02];case 2:return[.026,.022];case 3:return[.024,.023]}}},tracker:{name:F("trait_tracker_name"),desc:F("trait_tracker"),type:"major",val:2,vars(e){switch(e||t.race.tracker||1){case.25:return[10];case.5:return[15];case 1:return[20];case 2:return[25];case 3:return[30]}}},playful:{name:F("trait_playful_name"),desc:F("trait_playful"),type:"major",val:5,vars(e){switch(e||t.race.playful||1){case.25:return[.3];case.5:return[.4];case 1:return[.5];case 2:return[.6];case 3:return[.7]}}},freespirit:{name:F("trait_freespirit_name"),desc:F("trait_freespirit"),type:"major",val:-3,vars(e){switch(e||t.race.freespirit||1){case.25:return[65];case.5:return[60];case 1:return[50];case 2:return[35];case 3:return[25]}}},beast_of_burden:{name:F("trait_beast_of_burden_name"),desc:F("trait_beast_of_burden"),type:"major",val:3},sniper:{name:F("trait_sniper_name"),desc:F("trait_sniper"),type:"major",val:6,vars(e){switch(e||t.race.sniper||1){case.25:return[4];case.5:return[6];case 1:return[8];case 2:return[9];case 3:return[10]}}},hooved:{name:F("trait_hooved_name"),desc:F("trait_hooved"),type:"major",val:-4,vars(e){switch(e||t.race.hooved||1){case.25:return[130];case.5:return[120];case 1:return[100];case 2:return[80];case 3:return[70]}}},rage:{name:F("trait_rage_name"),desc:F("trait_rage"),type:"major",val:4,vars(e){switch(e||t.race.rage||1){case.25:return[.3,20];case.5:return[.5,30];case 1:return[1,50];case 2:return[1.25,60];case 3:return[1.4,65]}}},heavy:{name:F("trait_heavy_name"),desc:F("trait_heavy"),type:"major",val:-4,vars(e){switch(e||t.race.heavy||1){case.25:return[18,10];case.5:return[15,8];case 1:return[10,5];case 2:return[8,4];case 3:return[6,3]}}},gnawer:{name:F("trait_gnawer_name"),desc:F("trait_gnawer"),type:"major",val:-1,vars(e){switch(e||t.race.gnawer||1){case.25:return[.5];case.5:return[.4];case 1:return[.25];case 2:return[.2];case 3:return[.15]}}},calm:{name:F("trait_calm_name"),desc:F("trait_calm"),type:"major",val:6,vars(e){switch(e||t.race.calm||1){case.25:return[7];case.5:return[8];case 1:return[10];case 2:return[12];case 3:return[13]}}},pack_rat:{name:F("trait_pack_rat_name"),desc:F("trait_pack_rat"),type:"major",val:3,vars(e){switch(e||t.race.pack_rat||1){case.25:return[5,2];case.5:return[6,3];case 1:return[10,5];case 2:return[15,8];case 3:return[20,10]}}},paranoid:{name:F("trait_paranoid_name"),desc:F("trait_paranoid"),type:"major",val:-3,vars(e){switch(e||t.race.paranoid||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},greedy:{name:F("trait_greedy_name"),desc:F("trait_greedy"),type:"major",val:-5,vars(e){switch(e||t.race.greedy||1){case.25:return[17.5];case.5:return[15];case 1:return[12.5];case 2:return[10];case 3:return[8]}}},merchant:{name:F("trait_merchant_name"),desc:F("trait_merchant"),type:"major",val:3,vars(e){switch(e||t.race.merchant||1){case.25:return[10,3];case.5:return[15,5];case 1:return[25,10];case 2:return[35,12];case 3:return[40,13]}}},smart:{name:F("trait_smart_name"),desc:F("trait_smart"),type:"major",val:6,vars(e){switch(e||t.race.smart||1){case.25:return[3];case.5:return[5];case 1:return[10];case 2:return[12];case 3:return[13]}}},puny:{name:F("trait_puny_name"),desc:F("trait_puny"),type:"major",val:-4,vars(e){switch(e||t.race.puny||1){case.25:return[18];case.5:return[15];case 1:return[10];case 2:return[6];case 3:return[4]}}},dumb:{name:F("trait_dumb_name"),desc:F("trait_dumb"),type:"major",val:-5,vars(e){switch(e||t.race.dumb||1){case.25:return[7];case.5:return[6];case 1:return[5];case 2:return[4];case 3:return[3]}}},tough:{name:F("trait_tough_name"),desc:F("trait_tough"),type:"major",val:4,vars(e){switch(e||t.race.tough||1){case.25:return[10];case.5:return[15];case 1:return[25];case 2:return[35];case 3:return[40]}}},nearsighted:{name:F("trait_nearsighted_name"),desc:F("trait_nearsighted"),type:"major",val:-4,vars(e){switch(e||t.race.nearsighted||1){case.25:return[18];case.5:return[15];case 1:return[12];case 2:return[10];case 3:return[8]}}},intelligent:{name:F("trait_intelligent_name"),desc:F("trait_intelligent"),type:"major",val:7,vars(e){switch(e||t.race.intelligent||1){case.25:return[.08,.15];case.5:return[.1,.2];case 1:return[.125,.25];case 2:return[.14,.3];case 3:return[.15,.32]}}},regenerative:{name:F("trait_regenerative_name"),desc:F("trait_regenerative"),type:"major",val:8,vars:e=>[4],vars(e){switch(e||t.race.regenerative||1){case.25:return[2];case.5:return[3];case 1:return[4];case 2:return[5];case 3:return[6]}}},gluttony:{name:F("trait_gluttony_name"),desc:F("trait_gluttony"),type:"major",val:-2,vars(e){switch(e||t.race.gluttony||1){case.25:return[20];case.5:return[15];case 1:return[10];case 2:return[8];case 3:return[6]}}},slow:{name:F("trait_slow_name"),desc:F("trait_slow"),type:"major",val:-5,vars(e){switch(e||t.race.slow||1){case.25:return[13];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},armored:{name:F("trait_armored_name"),desc:F("trait_armored"),type:"major",val:4,vars(e){switch(e||t.race.armored||1){case.25:return[15,1];case.5:return[25,1];case 1:return[50,2];case 2:return[70,2];case 3:return[80,2]}}},optimistic:{name:F("trait_optimistic_name"),desc:F("trait_optimistic"),type:"major",val:5,vars(e){switch(e||t.race.optimistic||1){case.25:return[4,6];case.5:return[5,8];case 1:return[10,10];case 2:return[15,13];case 3:return[18,15]}}},chameleon:{name:F("trait_chameleon_name"),desc:F("trait_chameleon"),type:"major",val:6,vars(e){switch(e||t.race.chameleon||1){case.25:return[5,10];case.5:return[10,15];case 1:return[20,20];case 2:return[25,25];case 3:return[30,30]}}},slow_digestion:{name:F("trait_slow_digestion_name"),desc:F("trait_slow_digestion"),type:"major",val:1,vars(e){switch(e||t.race.slow_digestion||1){case.25:return[.3];case.5:return[.5];case 1:return[.75];case 2:return[1];case 3:return[1.25]}}},hard_of_hearing:{name:F("trait_hard_of_hearing_name"),desc:F("trait_hard_of_hearing"),type:"major",val:-3,vars(e){switch(e||t.race.hard_of_hearing||1){case.25:return[7];case.5:return[6];case 1:return[5];case 2:return[4];case 3:return[3]}}},resourceful:{name:F("trait_resourceful_name"),desc:F("trait_resourceful"),type:"major",val:4,vars(e){switch(e||t.race.resourceful||1){case.25:return[6];case.5:return[8];case 1:return[12];case 2:return[16];case 3:return[18]}}},selenophobia:{name:F("trait_selenophobia_name"),desc:F("trait_selenophobia"),type:"major",val:-6,vars(e){switch(e||t.race.selenophobia||1){case.25:return[2];case.5:return[3];case 1:return[4];case 2:return[5];case 3:return[6]}}},leathery:{name:F("trait_leathery_name"),desc:F("trait_leathery"),type:"major",val:2,vars(e){switch(e||t.race.leathery||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:return[1];case 3:return[0]}}},pessimistic:{name:F("trait_pessimistic_name"),desc:F("trait_pessimistic"),type:"major",val:-1,vars(e){switch(e||t.race.pessimistic||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:case 3:return[1]}}},hoarder:{name:F("trait_hoarder_name"),desc:F("trait_hoarder"),type:"major",val:4,vars(e){switch(e||t.race.hoarder||1){case.25:return[5];case.5:return[10];case 1:return[20];case 2:return[25];case 3:return[30]}}},solitary:{name:F("trait_solitary_name"),desc:F("trait_solitary"),type:"major",val:-1,vars(e){switch(e||t.race.solitary||1){case.25:return[.01,.025];case.5:return[.01,.02];case 1:return[.02,.02];case 2:return[.025,.02];case 3:return[.025,.015]}}},kindling_kindred:{name:F("trait_kindling_kindred_name"),desc:F("trait_kindling_kindred"),type:"major",val:8,vars(e){switch(e||t.race.kindling_kindred||1){case.25:return[10];case.5:return[8];case 1:return[5];case 2:return[4];case 3:return[3]}}},pyrophobia:{name:F("trait_pyrophobia_name"),desc:F("trait_pyrophobia"),type:"major",val:-4,vars(e){switch(e||t.race.pyrophobia||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},hyper:{name:F("trait_hyper_name"),desc:F("trait_hyper"),type:"major",val:4,vars(e){switch(e||t.race.hyper||1){case.25:return[2];case.5:return[3];case 1:return[5];case 2:return[6];case 3:return[7]}}},skittish:{name:F("trait_skittish_name"),desc:F("trait_skittish"),type:"major",val:-4,vars(e){switch(e||t.race.skittish||1){case.25:return[18];case.5:return[15];case 1:return[12];case 2:return[8];case 3:return[6]}}},fragrant:{name:F("trait_fragrant_name"),desc:F("trait_fragrant"),type:"major",val:-3,vars(e){switch(e||t.race.fragrant||1){case.25:return[35];case.5:return[30];case 1:return[20];case 2:return[15];case 3:return[12]}}},sticky:{name:F("trait_sticky_name"),desc:F("trait_sticky"),type:"major",val:3,vars(e){switch(e||t.race.sticky||1){case.25:return[5,5];case.5:return[10,8];case 1:return[20,15];case 2:return[25,18];case 3:return[30,20]}}},infectious:{name:F("trait_infectious_name"),desc:F("trait_infectious"),type:"major",val:4,vars(e){switch(e||t.race.infectious||1){case.25:return[1,2,3,7,18];case.5:return[1,2,4,8,20];case 1:return[2,3,5,10,25];case 2:return[2,4,6,12,30];case 3:return[3,4,7,13,32]}}},parasite:{name:F("trait_parasite_name"),desc:F("trait_parasite"),type:"major",val:-4},toxic:{name:F("trait_toxic_name"),desc:F("trait_toxic"),type:"major",val:5,vars(e){switch(e||t.race.toxic||1){case.25:return[5,3,10];case.5:return[10,5,15];case 1:return[20,8,30];case 2:return[25,10,40];case 3:return[30,12,45]}}},nyctophilia:{name:F("trait_nyctophilia_name"),desc:F("trait_nyctophilia"),type:"major",val:-3,vars(e){switch(e||t.race.nyctophilia||1){case.25:return[10,6];case.5:return[8,5];case 1:return[5,2];case 2:return[3,1];case 3:return[2,1]}}},infiltrator:{name:F("trait_infiltrator_name"),desc:F("trait_infiltrator"),type:"major",val:4,vars(e){switch(e||t.race.infiltrator||1){case.25:return[110];case.5:return[100];case 1:return[90];case 2:return[85];case 3:return[80]}}},hibernator:{name:F("trait_hibernator_name"),desc:F("trait_hibernator"),type:"major",val:-3,vars(e){switch(e||t.race.hibernator||1){case.25:return[15,8];case.5:return[20,8];case 1:return[25,8];case 2:return[30,6];case 3:return[35,5]}}},cannibalize:{name:F("trait_cannibalize_name"),desc:F("trait_cannibalize"),type:"major",val:5,vars(e){switch(e||t.race.cannibalize||1){case.25:return[8];case.5:return[10];case 1:return[15];case 2:return[20];case 3:return[22]}}},frail:{name:F("trait_frail_name"),desc:F("trait_frail"),type:"major",val:-5,vars(e){switch(e||t.race.frail||1){case.25:return[2,2];case.5:return[1,2];case 1:return[1,1];case 2:case 3:return[1,0]}}},malnutrition:{name:F("trait_malnutrition_name"),desc:F("trait_malnutrition"),type:"major",val:1,vars(e){switch(e||t.race.malnutrition||1){case.25:return[10];case.5:return[12];case 1:return[25];case 2:return[40];case 3:return[50]}}},claws:{name:F("trait_claws_name"),desc:F("trait_claws"),type:"major",val:5,vars(e){switch(e||t.race.claws||1){case.25:return[8];case.5:return[12];case 1:return[25];case 2:return[32];case 3:return[35]}}},atrophy:{name:F("trait_atrophy_name"),desc:F("trait_atrophy"),type:"major",val:-1,vars(e){switch(e||t.race.atrophy||1){case.25:return[.35];case.5:return[.25];case 1:return[.15];case 2:return[.1];case 3:return[.08]}}},hivemind:{name:F("trait_hivemind_name"),desc:F("trait_hivemind"),type:"major",val:9,vars(e){switch(e||t.race.hivemind||1){case.25:return[12];case.5:return[11];case 1:return[10];case 2:return[8];case 3:return[7]}}},tunneler:{name:F("trait_tunneler_name"),desc:F("trait_tunneler"),type:"major",val:2,vars(e){switch(e||t.race.tunneler||1){case.25:return[.002];case.5:return[.005];case 1:return[.01];case 2:return[.015];case 3:return[.018]}}},blood_thirst:{name:F("trait_blood_thirst_name"),desc:F("trait_blood_thirst"),type:"major",val:5,vars(e){switch(e||t.race.blood_thirst||1){case.25:return[25e4];case.5:return[5e5];case 1:return[1e6];case 2:return[2e6];case 3:return[4e6]}}},apex_predator:{name:F("trait_apex_predator_name"),desc:F("trait_apex_predator"),type:"major",val:6,vars(e){switch(e||t.race.apex_predator||1){case.25:return[15,20];case.5:return[20,30];case 1:return[30,50];case 2:return[40,60];case 3:return[45,65]}}},invertebrate:{name:F("trait_invertebrate_name"),desc:F("trait_invertebrate"),type:"major",val:-2,vars(e){switch(e||t.race.invertebrate||1){case.25:return[25];case.5:return[20];case 1:return[10];case 2:return[8];case 3:return[5]}}},suction_grip:{name:F("trait_suction_grip_name"),desc:F("trait_suction_grip"),type:"major",val:4,vars(e){switch(e||t.race.suction_grip||1){case.25:return[5];case.5:return[6];case 1:return[8];case 2:return[12];case 3:return[14]}}},befuddle:{name:F("trait_befuddle_name"),desc:F("trait_befuddle"),type:"major",val:4,vars(e){switch(e||t.race.befuddle||1){case.25:return[20];case.5:return[30];case 1:return[50];case 2:return[75];case 3:return[85]}}},environmentalist:{name:F("trait_environmentalist_name"),desc:F("trait_environmentalist"),type:"major",val:-5},unorganized:{name:F("trait_unorganized_name"),desc:F("trait_unorganized"),type:"major",val:-2,vars(e){switch(e||t.race.unorganized||1){case.25:return[90];case.5:return[80];case 1:return[50];case 2:return[40];case 3:return[30]}}},musical:{name:F("trait_musical_name"),desc:F("trait_musical"),type:"major",val:5,vars(e){switch(e||t.race.musical||1){case.25:return[.25];case.5:return[.5];case 1:return[1];case 2:return[1.1];case 3:return[1.2]}}},revive:{name:F("trait_revive_name"),desc:F("trait_revive"),type:"major",val:4,vars(e){switch(e||t.race.revive||1){case.25:return[7,5,2,8,6,3,4];case.5:return[6,4,2,7,5,2.5,4];case 1:return[5,3,1.5,6,4,2,3];case 2:return[4,2,1,5,3,1.5,2];case 3:return[3,1.5,1,4,2.5,1,2]}}},slow_regen:{name:F("trait_slow_regen_name"),desc:F("trait_slow_regen"),type:"major",val:-4,vars(e){switch(e||t.race.slow_regen||1){case.25:return[40];case.5:return[35];case 1:return[25];case 2:return[20];case 3:return[15]}}},forge:{name:F("trait_forge_name"),desc:F("trait_forge"),type:"major",val:4,vars(e){switch(e||t.race.forge||1){case.25:return[.5];case.5:return[1];case 1:return[2];case 2:return[2.5];case 3:return[3]}}},autoignition:{name:F("trait_autoignition_name"),desc:F("trait_autoignition"),type:"major",val:-4,vars(e){switch(e||t.race.autoignition||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:return[1.5];case 3:return[1]}}},blurry:{name:F("trait_blurry_name"),desc:F("trait_blurry"),type:"major",val:5,vars(e){switch(e||t.race.blurry||1){case.25:return[10];case.5:return[15];case 1:return[25];case 2:return[35];case 3:return[40]}}},snowy:{name:F("trait_snowy_name"),desc:F("trait_snowy"),type:"major",val:-3,vars(e){switch(e||t.race.snowy||1){case.25:return[4,10];case.5:return[3,8];case 1:return[2,5];case 2:return[2,4];case 3:return[1,3]}}},ravenous:{name:F("trait_ravenous_name"),desc:F("trait_ravenous"),type:"major",val:-5,vars(e){switch(e||t.race.ravenous||1){case.25:return[30,2];case.5:return[25,2];case 1:return[20,3];case 2:return[15,4];case 3:return[10,4]}}},ghostly:{name:F("trait_ghostly_name"),desc:F("trait_ghostly"),type:"major",val:5,vars(e){switch(e||t.race.ghostly||1){case.25:return[20,1.2,5];case.5:return[25,1.25,10];case 1:return[50,1.5,15];case 2:return[60,1.6,20];case 3:return[65,1.7,22]}}},lawless:{name:F("trait_lawless_name"),desc:F("trait_lawless"),type:"major",val:3,vars(e){switch(e||t.race.lawless||1){case.25:return[30];case.5:return[50];case 1:return[90];case 2:return[95];case 3:return[98]}}},mistrustful:{name:F("trait_mistrustful_name"),desc:F("trait_mistrustful"),type:"major",val:-1,vars(e){switch(e||t.race.mistrustful||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:case 3:return[1]}}},humpback:{name:F("trait_humpback_name"),desc:F("trait_humpback"),type:"major",val:4,vars(e){switch(e||t.race.humpback||1){case.25:return[.2,8];case.5:return[.25,10];case 1:return[.5,20];case 2:return[.75,25];case 3:return[.8,30]}}},thalassophobia:{name:F("trait_thalassophobia_name"),desc:F("trait_thalassophobia"),type:"major",val:-4},fiery:{name:F("trait_fiery_name"),desc:F("trait_fiery"),type:"major",val:10,vars(e){switch(e||t.race.fiery||1){case.25:return[30,15];case.5:return[40,18];case 1:return[65,25];case 2:return[70,35];case 3:return[72,38]}}},terrifying:{name:F("trait_terrifying_name"),desc:F("trait_terrifying"),type:"major",val:6,vars(e){switch(e||t.race.terrifying||1){case.25:return[8,20];case.5:return[10,25];case 1:return[12,32];case 2:return[12,34];case 3:return[12,36]}}},slaver:{name:F("trait_slaver_name"),desc:F("trait_slaver"),type:"major",val:12,vars(e){switch(e||t.race.slaver||1){case.25:return[.1];case.5:return[.14];case 1:return[.28];case 2:return[.3];case 3:return[.32]}}},compact:{name:F("trait_compact_name"),desc:F("trait_compact"),type:"major",val:10,vars(e){switch(e||t.race.compact||1){case.25:return[.005,.003];case.5:return[.01,.005];case 1:return[.015,.0075];case 2:return[.018,.0085];case 3:return[.02,.009]}}},conniving:{name:F("trait_conniving_name"),desc:F("trait_conniving"),type:"major",val:4,vars(e){switch(e||t.race.conniving||1){case.25:return[2,8];case.5:return[3,10];case 1:return[5,15];case 2:return[8,20];case 3:return[10,24]}}},pathetic:{name:F("trait_pathetic_name"),desc:F("trait_pathetic"),type:"major",val:-5,vars(e){switch(e||t.race.pathetic||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},spiritual:{name:F("trait_spiritual_name"),desc:F("trait_spiritual"),type:"major",val:4,vars(e){switch(e||t.race.spiritual||1){case.25:return[8];case.5:return[10];case 1:return[13];case 2:return[15];case 3:return[18]}}},truthful:{name:F("trait_truthful_name"),desc:F("trait_truthful"),type:"major",val:-7,vars(e){switch(e||t.race.truthful||1){case.25:return[75];case.5:return[65];case 1:return[50];case 2:return[30];case 3:return[20]}}},unified:{name:F("trait_unified_name"),desc:F("trait_unified"),type:"major",val:4,vars(e){switch(e||t.race.unified||1){case.25:return[0];case.5:return[1];case 1:return[3];case 2:return[5];case 3:return[7]}}},rainbow:{name:F("trait_rainbow_name"),desc:F("trait_rainbow"),type:"major",val:3,vars(e){switch(e||t.race.rainbow||1){case.25:return[20];case.5:return[30];case 1:return[50];case 2:return[80];case 3:return[100]}}},magnificent:{name:F("trait_magnificent_name"),desc:F("trait_magnificent"),type:"major",val:6,vars(e){switch(e||t.race.magnificent||1){case.25:return[300,1,.5,.75,1];case.5:return[350,2,.75,.8,1];case 1:return[400,3,1,1,1];case 2:return[450,3,1.5,1.5,1.5];case 3:return[500,3,2,2,2]}}},noble:{name:F("trait_noble_name"),desc:F("trait_noble"),type:"major",val:-3,vars(e){switch(e||t.race.noble||1){case.25:return[15,20];case.5:return[12,20];case 1:return[10,20];case 2:return[10,24];case 3:return[10,28]}}},imitation:{name:F("trait_imitation_name"),desc:F("trait_imitation"),type:"major",val:6,vars(e){switch(e||t.race.imitation||1){case.25:return[.25,.5];case.5:return[.25,1];case 1:return[.5,1];case 2:return[.5,2];case 3:return[1,2]}}},emotionless:{name:F("trait_emotionless_name"),desc:F("trait_emotionless"),type:"major",val:-4,vars(e){switch(e||t.race.emotionless||1){case.25:return[50,10];case.5:return[45,10];case 1:return[35,13];case 2:return[25,15];case 3:return[20,15]}}},logical:{name:F("trait_logical_name"),desc:F("trait_logical"),type:"major",val:6,vars(e){switch(e||t.race.logical||1){case.25:return[25,10];case.5:return[50,15];case 1:return[100,25];case 2:return[125,30];case 3:return[150,32]}}},shapeshifter:{name:F("trait_shapeshifter_name"),desc:F("trait_shapeshifter"),type:"major",val:10,vars(e){switch(e||t.race.shapeshifter||1){case.25:return[.25,.5];case.5:return[.25,1];case 1:return[.5,1];case 2:return[.5,2];case 3:return[1,2]}}},deconstructor:{name:F("trait_deconstructor_name"),desc:F("trait_deconstructor"),type:"major",val:-4,vars(e){switch(e||t.race.deconstructor||1){case.25:return[40];case.5:return[60];case 1:return[100];case 2:return[125];case 3:return[140]}}},linked:{name:F("trait_linked_name"),desc:F("trait_linked"),type:"major",val:4,vars(e){switch(e||t.race.linked||1){case.25:return[.03,40];case.5:return[.05,40];case 1:return[.1,80];case 2:return[.12,100];case 3:return[.14,100]}}},dark_dweller:{name:F("trait_dark_dweller_name"),desc:F("trait_dark_dweller"),type:"major",val:-3,vars(e){switch(e||t.race.dark_dweller||1){case.25:return[90];case.5:return[75];case 1:return[60];case 2:return[45];case 3:return[30]}}},swift:{name:F("trait_swift_name"),desc:F("trait_swift"),type:"major",val:10,vars(e){switch(e||t.race.swift||1){case.25:return[35,15];case.5:return[55,30];case 1:return[75,45];case 2:return[85,55];case 3:return[90,65]}}},anthropophagite:{name:F("trait_anthropophagite_name"),desc:F("trait_anthropophagite"),type:"major",val:-2,vars(e){switch(e||t.race.anthropophagite||1){case.25:return[.4];case.5:return[.65];case 1:return[1];case 2:return[1.5];case 3:return[2]}}},living_tool:{name:F("trait_living_tool_name"),desc:F("trait_living_tool"),type:"major",val:12,vars(e){switch(e||t.race.living_tool||1){case.25:return[.65,5];case.5:return[.8,12];case 1:return[1,25];case 2:return[1.1,35];case 3:return[1.2,42]}}},bloated:{name:F("trait_bloated_name"),desc:F("trait_bloated"),type:"major",val:-10,vars(e){switch(e||t.race.bloated||1){case.25:return[25];case.5:return[20];case 1:return[15];case 2:return[10];case 3:return[5]}}},ooze:{name:F("trait_ooze_name"),desc:F("trait_ooze"),type:"major",val:-50,vars(e){switch(e||t.race.ooze||1){case.25:return[20,25,40];case.5:return[15,20,35];case 1:return[12,15,30];case 2:return[10,12,25];case 3:return[8,10,20]}}},soul_eater:{name:F("trait_soul_eater_name"),desc:F("trait_soul_eater"),type:"special",val:0},untapped:{name:F("trait_untapped_name"),desc:F("trait_untapped"),type:"special",val:0},emfield:{name:F("trait_emfield_name"),desc:F("trait_emfield"),type:"special",val:-20},tactical:{name:F("trait_tactical_name"),desc:F("trait_tactical"),type:"minor",vars:e=>[5]},analytical:{name:F("trait_analytical_name"),desc:F("trait_analytical"),type:"minor",vars:e=>[1]},promiscuous:{name:F("trait_promiscuous_name"),desc:F("trait_promiscuous"),type:"minor",vars:e=>[1,.02]},resilient:{name:F("trait_resilient_name"),desc:F("trait_resilient"),type:"minor",vars:e=>[2]},cunning:{name:F("trait_cunning_name"),desc:F("trait_cunning"),type:"minor",vars:e=>[5]},hardy:{name:F("trait_hardy_name"),desc:F("trait_hardy"),type:"minor",vars:e=>[1]},ambidextrous:{name:F("trait_ambidextrous_name"),desc:F("trait_ambidextrous"),type:"minor",vars:e=>[3,2]},industrious:{name:F("trait_industrious_name"),desc:F("trait_industrious"),type:"minor",vars:e=>[2]},content:{name:F("trait_content_name"),desc:F("trait_content"),type:"minor"},fibroblast:{name:F("trait_fibroblast_name"),desc:F("trait_fibroblast"),type:"minor",vars:e=>[2]},metallurgist:{name:F("trait_metallurgist_name"),desc:F("trait_metallurgist"),type:"minor",vars:e=>[4]},gambler:{name:F("trait_gambler_name"),desc:F("trait_gambler"),type:"minor",vars:e=>[4]},persuasive:{name:F("trait_persuasive_name"),desc:F("trait_persuasive"),type:"minor",vars:e=>[1]},fortify:{name:F("trait_fortify_name"),desc:F("trait_fortify"),type:"special"},mastery:{name:F("trait_mastery_name"),desc:F("trait_mastery"),type:"special",vars:e=>[1]}},di={protoplasm:{name:F("race_protoplasm"),desc:F("race_protoplasm_desc"),type:"organism",home:F("race_prehistoric"),entity:"ooze",traits:{},solar:{red:F("race_human_solar_red"),hell:F("race_human_solar_hell"),gas:F("race_human_solar_gas"),gas_moon:F("race_human_solar_gas_moon"),dwarf:F("race_human_solar_dwarf")},fanaticism:"none",basic:()=>!1},human:{name:F("race_human"),desc:F("race_human_desc"),type:"humanoid",home:F("race_human_home"),entity:F("race_human_entity"),traits:{creative:1,diverse:1},solar:{red:F("race_human_solar_red"),hell:F("race_human_solar_hell"),gas:F("race_human_solar_gas"),gas_moon:F("race_human_solar_gas_moon"),dwarf:F("race_human_solar_dwarf")},fanaticism:"creative",basic:()=>!0},elven:{name:F("race_elven"),desc:F(ni("elven")?"race_xmas_elf_desc":"race_elven_desc"),type:"humanoid",home:F(ni("elven")?"race_xmas_elf_home":"race_elven_home"),entity:F("race_elven_entity"),traits:{studious:1,arrogant:1},solar:{red:F(ni("elven")?"race_xmas_elf_solar_red":"race_elven_solar_red"),hell:F(ni("elven")?"race_xmas_elf_solar_hell":"race_elven_solar_hell"),gas:F(ni("elven")?"race_xmas_elf_solar_gas":"race_elven_solar_gas"),gas_moon:F(ni("elven")?"race_xmas_elf_solar_gas_moon":"race_elven_solar_gas_moon"),dwarf:F(ni("elven")?"race_xmas_elf_solar_dwarf":"race_elven_solar_dwarf")},fanaticism:"studious",basic:()=>!0},orc:{name:F("race_orc"),desc:F("race_orc_desc"),type:"humanoid",home:F("race_orc_home"),entity:F("race_orc_entity"),traits:{brute:1,angry:1},solar:{red:F("race_orc_solar_red"),hell:F("race_orc_solar_hell"),gas:F("race_orc_solar_gas"),gas_moon:F("race_orc_solar_gas_moon"),dwarf:F("race_orc_solar_dwarf")},fanaticism:"brute",basic:()=>!0},cath:{name:F("race_cath"),desc:F("race_cath_desc"),type:"carnivore",home:F("race_cath_home"),entity:F("race_cath_entity"),traits:{lazy:1,curious:1},solar:{red:F("race_cath_solar_red"),hell:F("race_cath_solar_hell"),gas:F("race_cath_solar_gas"),gas_moon:F("race_cath_solar_gas_moon"),dwarf:F("race_cath_solar_dwarf")},fanaticism:"curious",basic:()=>!0},wolven:{name:ni("wolven")?F("race_rabbit"):F("race_wolven"),desc:ni("wolven")?F("race_rabbit_desc"):F("race_wolven_desc"),type:"carnivore",home:ni("wolven")?F("race_rabbit_home"):F("race_wolven_home"),entity:ni("wolven")?F("race_rabbit_entity"):F("race_wolven_entity"),traits:{pack_mentality:1,tracker:1},solar:{red:ni("wolven")?F("race_rabbit_solar_red"):F("race_wolven_solar_red"),hell:ni("wolven")?F("race_rabbit_solar_hell"):F("race_wolven_solar_hell"),gas:ni("wolven")?F("race_rabbit_solar_gas"):F("race_wolven_solar_gas"),gas_moon:ni("wolven")?F("race_rabbit_solar_gas_moon"):F("race_wolven_solar_gas_moon"),dwarf:ni("wolven")?F("race_rabbit_solar_dwarf"):F("race_wolven_solar_dwarf")},fanaticism:"tracker",basic:()=>!0},vulpine:{name:ni("vulpine")?F("race_chocolate_rabbit"):F("magic"===t.race.universe?"race_kitsune":"race_vulpine"),desc:()=>ni("vulpine")?F("race_chocolate_rabbit_desc"):F("race_vulpine_desc",[F("magic"===t.race.universe?"race_kitsune":"race_vulpine"),t.race.hasOwnProperty("fox_color")?F(`color_${t.race.fox_color}`):F("color_red")]),type:"carnivore",home:ni("vulpine")?F("race_chocolate_rabbit_home"):F("race_vulpine_home"),entity:F("race_vulpine_entity"),traits:{playful:1,freespirit:1},solar:{red:ni("vulpine")?F("race_chocolate_rabbit_solar_red"):F("race_vulpine_solar_red"),hell:ni("vulpine")?F("race_chocolate_rabbit_solar_hell"):F("race_vulpine_solar_hell"),gas:ni("vulpine")?F("race_chocolate_rabbit_solar_gas"):F("race_vulpine_solar_gas"),gas_moon:ni("vulpine")?F("race_chocolate_rabbit_solar_gas_moon"):F("race_vulpine_solar_gas_moon"),dwarf:ni("vulpine")?F("race_chocolate_rabbit_solar_dwarf"):F("race_vulpine_solar_dwarf")},fanaticism:"playful",basic:()=>!0},centaur:{name:F(ni("centaur")?"race_reindeer":"race_centaur"),desc:F(ni("centaur")?"race_reindeer_desc":"race_centaur_desc"),type:"herbivore",home:F(ni("centaur")?"race_reindeer_home":"race_centaur_home"),entity:F(ni("centaur")?"race_reindeer_entity":"race_centaur_entity"),traits:{sniper:1,hooved:1},solar:{red:F(ni("centaur")?"race_reindeer_solar_red":"race_centaur_solar_red"),hell:F(ni("centaur")?"race_reindeer_solar_hell":"race_centaur_solar_hell"),gas:F(ni("centaur")?"race_reindeer_solar_gas":"race_centaur_solar_gas"),gas_moon:F(ni("centaur")?"race_reindeer_solar_gas_moon":"race_centaur_solar_gas_moon"),dwarf:F(ni("centaur")?"race_reindeer_solar_dwarf":"race_centaur_solar_dwarf")},fanaticism:"sniper",basic:()=>!0},rhinotaur:{name:F("race_rhinotaur"),desc:F("race_rhinotaur_desc"),type:"herbivore",home:F("race_rhinotaur_home"),entity:F("race_rhinotaur_entity"),traits:{rage:1,heavy:1},solar:{red:F("race_rhinotaur_solar_red"),hell:F("race_rhinotaur_solar_hell"),gas:F("race_rhinotaur_solar_gas"),gas_moon:F("race_rhinotaur_solar_gas_moon"),dwarf:F("race_rhinotaur_solar_dwarf")},fanaticism:"rage",basic:()=>!0},capybara:{name:F(ni("capybara")?"race_donkey":"race_capybara"),desc:F(ni("capybara")?"race_donkey_desc":"race_capybara_desc"),type:"herbivore",home:F(ni("capybara")?"race_donkey_home":"race_capybara_home"),entity:F(ni("capybara")?"race_donkey_entity":"race_capybara_entity"),traits:{gnawer:1,calm:1},solar:{red:F(ni("capybara")?"race_donkey_solar_red":"race_capybara_solar_red"),hell:F(ni("capybara")?"race_donkey_solar_hell":"race_capybara_solar_hell"),gas:F(ni("capybara")?"race_donkey_solar_gas":"race_capybara_solar_gas"),gas_moon:F(ni("capybara")?"race_donkey_solar_gas_moon":"race_capybara_solar_gas_moon"),dwarf:F(ni("capybara")?"race_donkey_solar_dwarf":"race_capybara_solar_dwarf")},fanaticism:"calm",basic:()=>!0},kobold:{name:F("race_kobold"),desc:F("race_kobold_desc"),type:"small",home:F("race_kobold_home"),entity:F("race_kobold_entity"),traits:{pack_rat:1,paranoid:1},solar:{red:F("race_kobold_solar_red"),hell:F("race_kobold_solar_hell"),gas:F("race_kobold_solar_gas"),gas_moon:F("race_kobold_solar_gas_moon"),dwarf:F("race_kobold_solar_dwarf")},fanaticism:"pack_rat",basic:()=>!0},goblin:{name:F("race_goblin"),desc:F("race_goblin_desc"),type:"small",home:F("race_goblin_home"),entity:F("race_goblin_entity"),traits:{greedy:1,merchant:1},solar:{red:F("race_goblin_solar_red"),hell:F("race_goblin_solar_hell"),gas:F("race_goblin_solar_gas"),gas_moon:F("race_goblin_solar_gas_moon"),dwarf:F("race_goblin_solar_dwarf")},fanaticism:"merchant",basic:()=>!0},gnome:{name:F("race_gnome"),desc:F("race_gnome_desc"),type:"small",home:F("race_gnome_home"),entity:F("race_gnome_entity"),traits:{smart:1,puny:1},solar:{red:F("race_gnome_solar_red"),hell:F("race_gnome_solar_hell"),gas:F("race_gnome_solar_gas"),gas_moon:F("race_gnome_solar_gas_moon"),dwarf:F("race_gnome_solar_dwarf")},fanaticism:"smart",basic:()=>!0},ogre:{name:F("race_ogre"),desc:F("race_ogre_desc"),type:"giant",home:F("race_ogre_home"),entity:F("race_ogre_entity"),traits:{dumb:1,tough:1},solar:{red:F("race_ogre_solar_red"),hell:F("race_ogre_solar_hell"),gas:F("race_ogre_solar_gas"),gas_moon:F("race_ogre_solar_gas_moon"),dwarf:F("race_ogre_solar_dwarf")},fanaticism:"tough",basic:()=>!0},cyclops:{name:F("race_cyclops"),desc:F("race_cyclops_desc"),type:"giant",home:F("race_cyclops_home"),entity:F("race_cyclops_entity"),traits:{nearsighted:1,intelligent:1},solar:{red:F("race_cyclops_solar_red"),hell:F("race_cyclops_solar_hell"),gas:F("race_cyclops_solar_gas"),gas_moon:F("race_cyclops_solar_gas_moon"),dwarf:F("race_cyclops_solar_dwarf")},fanaticism:"intelligent",basic:()=>!0},troll:{name:F("race_troll"),desc:F("race_troll_desc"),type:"giant",home:F("race_troll_home"),entity:F("race_troll_entity"),traits:{regenerative:1,gluttony:1},solar:{red:F("race_troll_solar_red"),hell:F("race_troll_solar_hell"),gas:F("race_troll_solar_gas"),gas_moon:F("race_troll_solar_gas_moon"),dwarf:F("race_troll_solar_dwarf")},fanaticism:"regenerative",basic:()=>!0},tortoisan:{name:F("race_tortoisan"),desc:()=>F("race_tortoisan_desc",[t.race.hasOwnProperty("shell_color")?F(`color_${t.race.shell_color}`):F("color_green")]),type:"reptilian",home:F("race_tortoisan_home"),entity:F("race_tortoisan_entity"),traits:{slow:1,armored:1},solar:{red:F("race_tortoisan_solar_red"),hell:F("race_tortoisan_solar_hell"),gas:F("race_tortoisan_solar_gas"),gas_moon:F("race_tortoisan_solar_gas_moon"),dwarf:F("race_tortoisan_solar_dwarf")},fanaticism:"armored",basic:()=>!0},gecko:{name:F("race_gecko"),desc:F("race_gecko_desc"),type:"reptilian",home:F("race_gecko_home"),entity:F("race_gecko_entity"),traits:{optimistic:1,chameleon:1},solar:{red:F("race_gecko_solar_red"),hell:F("race_gecko_solar_hell"),gas:F("race_gecko_solar_gas"),gas_moon:F("race_gecko_solar_gas_moon"),dwarf:F("race_gecko_solar_dwarf")},fanaticism:"optimistic",basic:()=>!0},slitheryn:{name:F("race_slitheryn"),desc:F("race_slitheryn_desc"),type:"reptilian",home:F("race_slitheryn_home"),entity:F("race_slitheryn_entity"),traits:{slow_digestion:1,hard_of_hearing:1},solar:{red:F("race_slitheryn_solar_red"),hell:F("race_slitheryn_solar_hell"),gas:F("race_slitheryn_solar_gas"),gas_moon:F("race_slitheryn_solar_gas_moon"),dwarf:F("race_slitheryn_solar_dwarf")},fanaticism:"slow_digestion",basic:()=>!0},arraak:{name:F(ni("arraak")?"race_turkey":"race_arraak"),desc:F(ni("arraak")?"race_turkey_desc":"race_arraak_desc"),type:"avian",home:F(ni("arraak")?"race_turkey_home":"race_arraak_home"),entity:F("race_arraak_entity"),traits:{resourceful:1,selenophobia:1},solar:{red:F(ni("arraak")?"race_turkey_solar_red":"race_arraak_solar_red"),hell:F(ni("arraak")?"race_turkey_solar_hell":"race_arraak_solar_hell"),gas:F(ni("arraak")?"race_turkey_solar_gas":"race_arraak_solar_gas"),gas_moon:F(ni("arraak")?"race_turkey_solar_gas_moon":"race_arraak_solar_gas_moon"),dwarf:F(ni("arraak")?"race_turkey_solar_dwarf":"race_arraak_solar_dwarf")},fanaticism:"resourceful",basic:()=>!0},pterodacti:{name:F("race_pterodacti"),desc:F("race_pterodacti_desc"),type:"avian",home:F("race_pterodacti_home"),entity:F("race_pterodacti_entity"),traits:{leathery:1,pessimistic:1},solar:{red:F("race_pterodacti_solar_red"),hell:F("race_pterodacti_solar_hell"),gas:F("race_pterodacti_solar_gas"),gas_moon:F("race_pterodacti_solar_gas_moon"),dwarf:F("race_pterodacti_solar_dwarf")},fanaticism:"leathery",basic:()=>!0},dracnid:{name:F("race_dracnid"),desc:F("race_dracnid_desc"),type:"avian",home:F("race_dracnid_home"),entity:F("race_dracnid_entity"),traits:{hoarder:1,solitary:1},solar:{red:F("race_dracnid_solar_red"),hell:F("race_dracnid_solar_hell"),gas:F("race_dracnid_solar_gas"),gas_moon:F("race_dracnid_solar_gas_moon"),dwarf:F("race_dracnid_solar_dwarf")},fanaticism:"hoarder",basic:()=>!0},entish:{name:F(ni("entish")?"race_spruce":"race_entish"),desc:F(ni("entish")?"race_spruce_desc":"race_entish_desc"),type:"plant",home:F(ni("entish")?"race_spruce_home":"race_entish_home"),entity:F(ni("entish")?"race_spruce_entity":"race_entish_entity"),traits:{kindling_kindred:1,pyrophobia:1},solar:{red:F(ni("entish")?"race_spruce_solar_red":"race_entish_solar_red"),hell:F(ni("entish")?"race_spruce_solar_hell":"race_entish_solar_hell"),gas:F(ni("entish")?"race_spruce_solar_gas":"race_entish_solar_gas"),gas_moon:F(ni("entish")?"race_spruce_solar_gas_moon":"race_entish_solar_gas_moon"),dwarf:F(ni("entish")?"race_spruce_solar_dwarf":"race_entish_solar_dwarf")},fanaticism:"kindling_kindred",basic:()=>!0},cacti:{name:F("race_cacti"),desc:F("race_cacti_desc"),type:"plant",home:F("race_cacti_home"),entity:F("race_cacti_entity"),traits:{hyper:1,skittish:1},solar:{red:F("race_cacti_solar_red"),hell:F("race_cacti_solar_hell"),gas:F("race_cacti_solar_gas"),gas_moon:F("race_cacti_solar_gas_moon"),dwarf:F("race_cacti_solar_dwarf")},fanaticism:"hyper",basic:()=>!0},pinguicula:{name:F("race_pinguicula"),desc:F("race_pinguicula_desc"),type:"plant",home:F("race_pinguicula_home"),entity:F("race_pinguicula_entity"),traits:{fragrant:1,sticky:1},solar:{red:F("race_pinguicula_solar_red"),hell:F("race_pinguicula_solar_hell"),gas:F("race_pinguicula_solar_gas"),gas_moon:F("race_pinguicula_solar_gas_moon"),dwarf:F("race_pinguicula_solar_dwarf")},fanaticism:"sticky",basic:()=>!0},sporgar:{name:F("race_sporgar"),desc:F("race_sporgar_desc"),type:"fungi",home:F("race_sporgar_home"),entity:F("race_sporgar_entity"),traits:{infectious:1,parasite:1},solar:{red:F("race_sporgar_solar_red"),hell:F("race_sporgar_solar_hell"),gas:F("race_sporgar_solar_gas"),gas_moon:F("race_sporgar_solar_gas_moon"),dwarf:F("race_sporgar_solar_dwarf")},fanaticism:"infectious",basic:()=>!1},shroomi:{name:F("race_shroomi"),desc:F("race_shroomi_desc"),type:"fungi",home:F("race_shroomi_home"),entity:F("race_shroomi_entity"),traits:{toxic:1,nyctophilia:1},solar:{red:F("race_shroomi_solar_red"),hell:F("race_shroomi_solar_hell"),gas:F("race_shroomi_solar_gas"),gas_moon:F("race_shroomi_solar_gas_moon"),dwarf:F("race_shroomi_solar_dwarf")},fanaticism:"toxic",basic:()=>!0},moldling:{name:F("race_moldling"),desc:F("race_moldling_desc"),type:"fungi",home:F("race_moldling_home"),entity:F("race_moldling_entity"),traits:{infiltrator:1,hibernator:1},solar:{red:F("race_moldling_solar_red"),hell:F("race_moldling_solar_hell"),gas:F("race_moldling_solar_gas"),gas_moon:F("race_moldling_solar_gas_moon"),dwarf:F("race_moldling_solar_dwarf")},fanaticism:"infiltrator",basic:()=>!0},mantis:{name:F("race_mantis"),desc:F("race_mantis_desc"),type:"insectoid",home:F("race_mantis_home"),entity:F("race_mantis_entity"),traits:{cannibalize:1,malnutrition:1},solar:{red:F("race_mantis_solar_red"),hell:F("race_mantis_solar_hell"),gas:F("race_mantis_solar_gas"),gas_moon:F("race_mantis_solar_gas_moon"),dwarf:F("race_mantis_solar_dwarf")},fanaticism:"cannibalize",basic:()=>!0},scorpid:{name:F("race_scorpid"),desc:F("race_scorpid_desc"),type:"insectoid",home:F("race_scorpid_home"),entity:F("race_scorpid_entity"),traits:{claws:1,atrophy:1},solar:{red:F("race_scorpid_solar_red"),hell:F("race_scorpid_solar_hell"),gas:F("race_scorpid_solar_gas"),gas_moon:F("race_scorpid_solar_gas_moon"),dwarf:F("race_scorpid_solar_dwarf")},fanaticism:"claws",basic:()=>!0},antid:{name:F("race_antid"),desc:F("race_antid_desc"),type:"insectoid",home:F("race_antid_home"),entity:F("race_antid_entity"),traits:{hivemind:1,tunneler:1},solar:{red:F("race_antid_solar_red"),hell:F("race_antid_solar_hell"),gas:F("race_antid_solar_gas"),gas_moon:F("race_antid_solar_gas_moon"),dwarf:F("race_antid_solar_dwarf")},fanaticism:"hivemind",basic:()=>!0},sharkin:{name:F("race_sharkin"),desc:F("race_sharkin_desc"),type:"aquatic",home:F("race_sharkin_home"),entity:F("race_sharkin_entity"),traits:{blood_thirst:1,apex_predator:1},solar:{red:F("race_sharkin_solar_red"),hell:F("race_sharkin_solar_hell"),gas:F("race_sharkin_solar_gas"),gas_moon:F("race_sharkin_solar_gas_moon"),dwarf:F("race_sharkin_solar_dwarf")},fanaticism:"blood_thirst",basic:()=>!!["oceanic","swamp"].includes(t.city.biome)},octigoran:{name:F("race_octigoran"),desc:F("race_octigoran_desc"),type:"aquatic",home:F("race_octigoran_home"),entity:F("race_octigoran_entity"),traits:{invertebrate:1,suction_grip:1},solar:{red:F("race_octigoran_solar_red"),hell:F("race_octigoran_solar_hell"),gas:F("race_octigoran_solar_gas"),gas_moon:F("race_octigoran_solar_gas_moon"),dwarf:F("race_octigoran_solar_dwarf")},fanaticism:"suction_grip",basic:()=>!!["oceanic","swamp"].includes(t.city.biome)},dryad:{name:F("race_dryad"),desc:F("race_dryad_desc"),type:"fey",home:F("race_dryad_home"),entity:F("race_dryad_entity"),traits:{befuddle:1,environmentalist:1,kindling_kindred:1},solar:{red:F("race_dryad_solar_red"),hell:F("race_dryad_solar_hell"),gas:F("race_dryad_solar_gas"),gas_moon:F("race_dryad_solar_gas_moon"),dwarf:F("race_dryad_solar_dwarf")},fanaticism:"befuddle",basic:()=>!!["forest","swamp","taiga"].includes(t.city.biome)},satyr:{name:F("race_satyr"),desc:F("race_satyr_desc"),type:"fey",home:F("race_satyr_home"),entity:F("race_satyr_entity"),traits:{unorganized:1,musical:1},solar:{red:F("race_satyr_solar_red"),hell:F("race_satyr_solar_hell"),gas:F("race_satyr_solar_gas"),gas_moon:F("race_satyr_solar_gas_moon"),dwarf:F("race_satyr_solar_dwarf")},fanaticism:"musical",basic:()=>!!["forest","swamp","taiga"].includes(t.city.biome)},phoenix:{name:F("race_phoenix"),desc:F("race_phoenix_desc"),type:"heat",home:F("race_phoenix_home"),entity:F("race_phoenix_entity"),traits:{revive:1,slow_regen:1},solar:{red:F("race_phoenix_solar_red"),hell:F("race_phoenix_solar_hell"),gas:F("race_phoenix_solar_gas"),gas_moon:F("race_phoenix_solar_gas_moon"),dwarf:F("race_phoenix_solar_dwarf")},fanaticism:"revive",basic:()=>!!["volcanic","ashland"].includes(t.city.biome)},salamander:{name:F("race_salamander"),desc:F("race_salamander_desc"),type:"heat",home:F("race_salamander_home"),entity:F("race_salamander_entity"),traits:{forge:1,autoignition:1},solar:{red:F("race_salamander_solar_red"),hell:F("race_salamander_solar_hell"),gas:F("race_salamander_solar_gas"),gas_moon:F("race_salamander_solar_gas_moon"),dwarf:F("race_salamander_solar_dwarf")},fanaticism:"forge",basic:()=>!!["volcanic","ashland"].includes(t.city.biome)},yeti:{name:F(ni("yeti")?"race_snowman":"race_yeti"),desc:F(ni("yeti")?"race_snowman_desc":"race_yeti_desc"),type:"polar",home:F(ni("yeti")?"race_snowman_home":"race_yeti_home"),entity:F(ni("yeti")?"race_snowman_entity":"race_yeti_entity"),traits:{blurry:1,snowy:1},solar:{red:F(ni("yeti")?"race_snowman_solar_red":"race_yeti_solar_red"),hell:F(ni("yeti")?"race_snowman_solar_hell":"race_yeti_solar_hell"),gas:F(ni("yeti")?"race_snowman_solar_gas":"race_yeti_solar_gas"),gas_moon:F(ni("yeti")?"race_snowman_solar_gas_moon":"race_yeti_solar_gas_moon"),dwarf:F(ni("yeti")?"race_snowman_solar_dwarf":"race_yeti_solar_dwarf")},fanaticism:"blurry",basic:()=>!!["tundra","taiga"].includes(t.city.biome)},wendigo:{name:F(ni("wendigo")?"race_krampus":"race_wendigo"),desc:F(ni("wendigo")?"race_krampus_desc":"race_wendigo_desc"),type:"polar",home:F(ni("wendigo")?"race_krampus_home":"race_wendigo_home"),entity:F(ni("wendigo")?"race_krampus_entity":"race_wendigo_entity"),traits:{ravenous:1,ghostly:1,soul_eater:1},solar:{red:F(ni("wendigo")?"race_krampus_solar_red":"race_wendigo_solar_red"),hell:F(ni("wendigo")?"race_krampus_solar_hell":"race_wendigo_solar_hell"),gas:F(ni("wendigo")?"race_krampus_solar_gas":"race_wendigo_solar_gas"),gas_moon:F(ni("wendigo")?"race_krampus_solar_gas_moon":"race_wendigo_solar_gas_moon"),dwarf:F(ni("wendigo")?"race_krampus_solar_dwarf":"race_wendigo_solar_dwarf")},fanaticism:"ghostly",basic:()=>!!["tundra","taiga"].includes(t.city.biome)},tuskin:{name:F("race_tuskin"),desc:F("race_tuskin_desc"),type:"sand",home:F("race_tuskin_home"),entity:F("race_tuskin_entity"),traits:{lawless:1,mistrustful:1},solar:{red:F("race_tuskin_solar_red"),hell:F("race_tuskin_solar_hell"),gas:F("race_tuskin_solar_gas"),gas_moon:F("race_tuskin_solar_gas_moon"),dwarf:F("race_tuskin_solar_dwarf")},fanaticism:"lawless",basic:()=>!!["desert","ashland"].includes(t.city.biome)},kamel:{name:F("race_kamel"),desc:F("race_kamel_desc"),type:"sand",home:F("race_kamel_home"),entity:F("race_kamel_entity"),traits:{humpback:1,thalassophobia:1},solar:{red:F("race_kamel_solar_red"),hell:F("race_kamel_solar_hell"),gas:F("race_kamel_solar_gas"),gas_moon:F("race_kamel_solar_gas_moon"),dwarf:F("race_kamel_solar_dwarf")},fanaticism:"humpback",basic:()=>!!["desert","ashland"].includes(t.city.biome)},balorg:{name:F("race_balorg"),desc:F("race_balorg_desc"),type:"demonic",home:F("race_balorg_home"),entity:F("race_balorg_entity"),traits:{fiery:1,terrifying:1,slaver:1},solar:{red:F("race_balorg_solar_red"),hell:F("race_balorg_solar_hell"),gas:F("race_balorg_solar_gas"),gas_moon:F("race_balorg_solar_gas_moon"),dwarf:F("race_balorg_solar_dwarf")},fanaticism:"fiery",basic:()=>"hellscape"===t.city.biome},imp:{name:F("race_imp"),desc:F("race_imp_desc"),type:"demonic",home:F("race_imp_home"),entity:F("race_imp_entity"),traits:{compact:1,conniving:1,pathetic:1},solar:{red:F("race_imp_solar_red"),hell:F("race_imp_solar_hell"),gas:F("race_imp_solar_gas"),gas_moon:F("race_imp_solar_gas_moon"),dwarf:F("race_imp_solar_dwarf")},fanaticism:"conniving",basic:()=>"hellscape"===t.city.biome},seraph:{name:F(ni("seraph")?"race_cherub":"race_seraph"),desc:F(ni("seraph")?"race_cherub_desc":"race_seraph_desc"),type:"angelic",home:F(ni("seraph")?"race_cherub_home":"race_seraph_home"),entity:F(ni("seraph")?"race_cherub_entity":"race_seraph_entity"),traits:{unified:1,spiritual:1,truthful:1},solar:{red:F(ni("seraph")?"race_cherub_solar_red":"race_seraph_solar_red"),hell:F(ni("seraph")?"race_cherub_solar_hell":"race_seraph_solar_hell"),gas:F(ni("seraph")?"race_cherub_solar_gas":"race_seraph_solar_gas"),gas_moon:F(ni("seraph")?"race_cherub_solar_gas_moon":"race_seraph_solar_gas_moon"),dwarf:F(ni("seraph")?"race_cherub_solar_dwarf":"race_seraph_solar_dwarf")},fanaticism:"spiritual",basic:()=>"eden"===t.city.biome},unicorn:{name:F("race_unicorn"),desc:F("race_unicorn_desc"),type:"angelic",home:F("race_unicorn_home"),entity:F("race_unicorn_entity"),traits:{rainbow:1,magnificent:1,noble:1},solar:{red:F("race_unicorn_solar_red"),hell:F("race_unicorn_solar_hell"),gas:F("race_unicorn_solar_gas"),gas_moon:F("race_unicorn_solar_gas_moon"),dwarf:F("race_unicorn_solar_dwarf")},fanaticism:"magnificent",basic:()=>"eden"===t.city.biome},synth:{name:F("race_synth"),desc(){let e=t.race.hasOwnProperty("srace")?t.race.srace:"human";return F("race_synth_desc",[di[e].name])},type:"synthetic",home:F("race_synth_home"),entity:F("race_synth_entity"),traits:{imitation:1,emotionless:1,logical:1},solar:{red:F("race_synth_solar_red"),hell:F("race_synth_solar_hell"),gas:F("race_synth_solar_gas"),gas_moon:F("race_synth_solar_gas_moon"),dwarf:F("race_synth_solar_dwarf")},fanaticism:"logical",basic:()=>!1},nano:{name:F("race_nano"),desc:F("race_nano_desc"),type:"synthetic",home:F("race_nano_home"),entity:F("race_nano_entity"),traits:{deconstructor:1,linked:1,shapeshifter:1},solar:{red:F("race_nano_solar_red"),hell:F("race_nano_solar_hell"),gas:F("race_nano_solar_gas"),gas_moon:F("race_nano_solar_gas_moon"),dwarf:F("race_nano_solar_dwarf")},fanaticism:"shapeshifter",basic:()=>!1},ghast:{name:F("race_ghast"),desc:F("race_ghast_desc"),type:"eldritch",home:F("race_ghast_home"),entity:F("race_ghast_entity"),traits:{dark_dweller:1,swift:1,anthropophagite:1},solar:{red:F("race_ghast_solar_red"),hell:F("race_ghast_solar_hell"),gas:F("race_ghast_solar_gas"),gas_moon:F("race_ghast_solar_gas_moon"),dwarf:F("race_ghast_solar_dwarf")},fanaticism:"swift",basic:()=>!1},shoggoth:{name:F("race_shoggoth"),desc:F("race_shoggoth_desc"),type:"eldritch",home:F("race_shoggoth_home"),entity:F("race_shoggoth_entity"),traits:{living_tool:1,bloated:1},solar:{red:F("race_shoggoth_solar_red"),hell:F("race_shoggoth_solar_hell"),gas:F("race_shoggoth_solar_gas"),gas_moon:F("race_shoggoth_solar_gas_moon"),dwarf:F("race_shoggoth_solar_dwarf")},fanaticism:"living_tool",basic:()=>!1},junker:{name:ni("junker")?F("race_ghoul"):F("race_junker"),desc:ni("junker")?F("race_ghoul_desc"):F("race_junker_desc"),type:t.race.hasOwnProperty("jtype")?t.race.jtype:"humanoid",home:ni("junker")?F("race_ghoul_home"):F("race_junker_home"),entity:ni("junker")?F("race_ghoul_entity"):F("race_junker_entity"),traits:{diverse:1,arrogant:1,angry:1,lazy:1,paranoid:1,greedy:1,puny:1,dumb:1,nearsighted:1,gluttony:1,slow:1,hard_of_hearing:1,pessimistic:1,solitary:1,pyrophobia:1,skittish:1,nyctophilia:1,frail:1,atrophy:1,invertebrate:1,pathetic:1,hibernator:1,freespirit:1,heavy:1,gnawer:1,hooved:1},solar:{red:ni("junker")?F("race_ghoul_solar_red"):F("race_junker_solar_red"),hell:ni("junker")?F("race_ghoul_solar_hell"):F("race_junker_solar_hell"),gas:ni("junker")?F("race_ghoul_solar_gas"):F("race_junker_solar_gas"),gas_moon:ni("junker")?F("race_ghoul_solar_gas_moon"):F("race_junker_solar_gas_moon"),dwarf:ni("junker")?F("race_ghoul_solar_dwarf"):F("race_junker_solar_dwarf")},fanaticism:"none",basic:()=>!1},sludge:{name:F("race_sludge"),desc:F("race_sludge_desc"),type:t.race.hasOwnProperty("jtype")?t.race.jtype:"humanoid",home:F("race_sludge_home"),entity:F("race_sludge_entity"),traits:{ooze:.25,diverse:.25,arrogant:.25,angry:.25,lazy:.25,hooved:.25,freespirit:.25,heavy:.25,gnawer:.25,paranoid:.25,greedy:.25,puny:.25,dumb:.25,nearsighted:.25,gluttony:.25,slow:.25,hard_of_hearing:.25,selenophobia:.25,pessimistic:.25,solitary:.25,pyrophobia:.25,skittish:.25,fragrant:.25,nyctophilia:.25,hibernator:.25,frail:.25,atrophy:.25,invertebrate:.25,unorganized:.25,slow_regen:.25,autoignition:.25,snowy:.25,mistrustful:.25,thalassophobia:.25,pathetic:.25,truthful:.25},solar:{red:F("race_sludge_solar_red"),hell:F("race_sludge_solar_hell"),gas:F("race_sludge_solar_gas"),gas_moon:F("race_sludge_solar_gas_moon"),dwarf:F("race_sludge_solar_dwarf")},fanaticism:"ooze",basic:()=>!1},custom:function(){if(t.hasOwnProperty("custom")&&t.custom.hasOwnProperty("race0")){let e={};for(let a=0;aui[a].val&&(a=t.custom.race0.traits[e]);return{name:t.custom.race0.name,desc:t.custom.race0.desc,type:t.custom.race0.genus,home:t.custom.race0.home,entity:t.custom.race0.entity,traits:e,solar:{red:t.custom.race0.red,hell:t.custom.race0.hell,gas:t.custom.race0.gas,gas_moon:t.custom.race0.gas_moon,dwarf:t.custom.race0.dwarf},fanaticism:a,basic:()=>!1}}return{}}()},_i={organism:{},humanoid:{},carnivore:{},herbivore:{},omnivore:{},small:{},giant:{},reptilian:{},avian:{},insectoid:{},plant:{},fungi:{},aquatic:{},fey:{},heat:{},polar:{},sand:{},demonic:{},angelic:{},synthetic:{},eldritch:{}};function pi(e,a){let r=1,s=N("theorist",1);!s||"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1-s/100);let i=N("inspirational",0);!i||"farmer"!==a&&"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1+i/100);let c=N("dirty_jobs",2);if(c&&"miner"===a&&(r*=1+c/100),t.race.rejuvenated&&["lumberjack","miner","factory"].includes(a)&&(r*=1.1),"lumberjack"===a&&t.race.evil&&!t.race.soul_eater&&(t.race.living_tool?r*=1+ui.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.3*t.tech.science:0):r*=1+.4*(t.tech.reclaimer-1)),!t.race.powered||"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1+ui.powered.vars()[1]/100),t.race.artifical&&"science"===a&&(r*=1+ui.artifical.vars()[0]/100),t.race.hivemind&&"farmer"!==a&&!t.race.lone_survivor){let s=ui.hivemind.vars()[0],i=.05;t.race.high_pop&&"army"!==a&&"hellArmy"!==a&&(s*=ui.high_pop.vars()[0],i=.5/(ui.hivemind.vars()[0]*ui.high_pop.vars()[0])),r*=e<=s?e*i+(1-s*i):1-("army"===a||"hellArmy"===a?.99:t.race.high_pop?.985:.98)**(e-s)+1}let o=Pi("antid");if(o>0&&(r*=1+(1-("army"===a||"hellArmy"===a?.99:t.race.high_pop?.985:.98)**(e*o/4))/2),t.race.cold_blooded&&"army"!==a&&"hellArmy"!==a&&"factory"!==a&&"science"!==a){switch(t.city.calendar.temp){case 0:r*=1-ui.cold_blooded.vars()[0]/100;break;case 2:r*=1+ui.cold_blooded.vars()[1]/100;break;default:r*=1}switch(t.city.calendar.weather){case 0:r*=1-ui.cold_blooded.vars()[0]/100;break;case 2:r*=1+ui.cold_blooded.vars()[1]/100;break;default:r*=1}}t.race.cannibalize&&t.city.s_alter&&t.city.s_alter.count>0&&("miner"===a&&t.city.s_alter.mine>0&&(r*=1+ui.cannibalize.vars()[0]/100),"lumberjack"===a&&t.city.s_alter.harvest>0&&(r*=1+ui.cannibalize.vars()[0]/100),("army"===a||"hellArmy"===a)&&t.city.s_alter.rage>0&&(r*=1+ui.cannibalize.vars()[0]/100),"science"===a&&t.city.s_alter.mind>0&&(r*=1+ui.cannibalize.vars()[0]/100));let n=Pi("mantis");n>0&&("miner"===a&&(r*=1+ui.cannibalize.vars(1)[0]/100*n),"lumberjack"===a&&(r*=1+ui.cannibalize.vars(1)[0]/100*n),"army"!==a&&"hellArmy"!==a||(r*=1+ui.cannibalize.vars(1)[0]/100*n),"science"===a&&(r*=1+ui.cannibalize.vars(1)[0]/100*n)),!t.race.humpback||"miner"!==a&&"lumberjack"!==a||(r*=1+ui.humpback.vars()[0]/100);let l=Pi("kamel");l>0&&("miner"===a||"lumberjack"===a)&&(r*=1+ui.humpback.vars(1)[0]/100*l),t.city.ptrait.includes("magnetic")&&"miner"===a&&(r*=Si.magnetic.vars()[2]),!t.race.weak||"miner"!==a&&"lumberjack"!==a||(r*=1-ui.weak.vars()[0]/100),t.race.hydrophilic&&0===t.city.calendar.weather&&t.city.calendar.temp>0&&"factory"!==a&&(r*=.75),t.race.toxic&&"factory"===a&&(r*=1+ui.toxic.vars()[2]/100);let u=Pi("shroomi");if(u>0&&"factory"===a&&(r*=1+ui.toxic.vars(1)[2]/100*u),t.race.hardy&&"factory"===a&&(r*=1+ui.hardy.vars()[0]*t.race.hardy/100),t.race.analytical&&"science"===a&&(r*=1+ui.analytical.vars()[0]*t.race.analytical/100),t.race.ooze&&(r*=1-ui.ooze.vars()[0]/100),"democracy"===t.civic.govern.type&&(r*=1-ae.democracy()[1]/100),!t.tech.cyber_worker||"lumberjack"!==a&&"miner"!==a||(r*=1.25),"hunting"===a){t.race.tracker&&(r*=1+ui.tracker.vars()[0]/100);let e=Pi("wolven");e>0&&(r*=1+ui.tracker.vars(1)[0]/100*e),t.race.beast&&(r*=1+(1===t.city.calendar.wind?ui.beast.vars()[1]:ui.beast.vars()[0])/100),t.race.apex_predator&&(r*=1+ui.apex_predator.vars()[1]/100);let a=Pi("sharkin");a>0&&(r*=1+ui.apex_predator.vars(1)[1]/100*a),t.race.fiery&&(r*=1+ui.fiery.vars()[1]/100);let s=Pi("balorg");s>0&&(r*=1+ui.fiery.vars(1)[1]/100*s),t.race.fragrant&&(r*=1-ui.fragrant.vars()[0]/100),t.city.ptrait.includes("rage")&&(r*=Si.rage.vars()[1]),t.race.cunning&&(r*=1+ui.cunning.vars()[0]*t.race.cunning/100),"savanna"===t.city.biome&&(r*=ji.savanna.vars()[1]),t.race.dark_dweller&&2===t.city.calendar.weather&&(r*=1-ui.dark_dweller.vars()[0]/100)}if("magic"===t.race.universe&&(r*="science"===a?.6:"army"===a||"hellArmy"===a?.75:.8,t.race.witch_hunter&&(r*=.75),t.race.hasOwnProperty("casting")&&t.race.casting["hellArmy"===a?"army":a])){let e=t.race.casting["hellArmy"===a?"army":a];t.race.witch_hunter?r*=1+e/(e+75)*2.5:r*=1+e/(e+75)}return t.race.living_tool&&"miner"===a&&(r*=1+ui.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.12*t.tech.science:0)),t.race.high_pop&&(r=Me(r)),r}function hi(e){let a=[];Object.keys(ui).forEach((function(e){"minor"!==ui[e].type||t.race[e]||a.push(e)})),0===a.length&&Object.keys(ui).forEach((function(e){"minor"===ui[e].type&&a.push(e)}));let r=a[Math.floor(m(0,a.length))];return t.race[r]?t.race[r]+=e:t.race[r]=e,r}function mi(e,a,r){t.race.purgatory[e].hasOwnProperty(a)?(t[e][a]=t.race.purgatory[e][a],delete t.race.purgatory[e][a]):r&&(t[e][a]=r)}function gi(e,a,r,s){t.race.purgatory[e].hasOwnProperty(a)?(t[e][a]=t.race.purgatory[e][a],delete t.race.purgatory[e][a]):t.race.purgatory[e].hasOwnProperty(r)?(t[e][a]=t.race.purgatory[e][r],delete t.race.purgatory[e][r]):s&&(t[e][a]=s)}function fi(e,a){t[e].hasOwnProperty(a)&&(t.race.purgatory[e][a]=t[e][a],delete t[e][a])}function vi(e,a){if(t.race.purgatory[e].hasOwnProperty(a))return t.race.purgatory[e][a]}function yi(){bi("Lumber"),bi("Plywood"),Bi(["city-graveyard","city-lumber_yard","city-sawmill"]),Gi(["reclaimer","axe","saw"]),fi("city","sawmill"),fi("city","graveyard"),fi("city","lumber_yard"),fi("tech","axe"),fi("tech","reclaimer"),fi("tech","saw"),t.civic.lumberjack.display=!1,t.civic.lumberjack.workers=0,"lumberjack"===t.civic.d_job&&(t.civic.d_job=t.race.carnivore||t.race.soul_eater?"hunter":"unemployed"),t.race.casting&&(t.race.casting.total-=t.race.casting.lumberjack,t.race.casting.lumberjack=0,Ws()),t.city.s_alter&&(t.city.s_alter.harvest=0)}function bi(e){t.resource[e].display=!1,t.race.alchemy&&t.race.alchemy.hasOwnProperty(e)&&(t.resource.Mana.diff+=t.race.alchemy[e],t.race.alchemy[e]=0),t.interstellar.mass_ejector&&t.interstellar.mass_ejector.hasOwnProperty(e)&&(t.interstellar.mass_ejector.total-=t.interstellar.mass_ejector[e],t.interstellar.mass_ejector[e]=0),t.city.nanite_factory&&t.city.nanite_factory.hasOwnProperty(e)&&(t.city.nanite_factory[e]=0),t.portal.transport&&t.portal.transport.cargo.hasOwnProperty(e)&&(t.portal.transport.cargo.used-=t.portal.transport.cargo[e],t.portal.transport.cargo[e]=0),t.tech.foundry&&t.city.foundry.hasOwnProperty(e)&&(t.civic.craftsman.workers-=t.city.foundry[e],t.city.foundry.crafting-=t.city.foundry[e],t.city.foundry[e]=0,ha()),t.resource[e].hasOwnProperty("trade")&&(t.city.market.trade-=Math.abs(t.resource[e].trade),t.resource[e].trade=0),t.resource.Crates.amount+=t.resource[e].crates,t.resource[e].crates=0,t.resource.Containers.amount+=t.resource[e].containers,t.resource[e].containers=0}function wi(){let e=ds(Qr.tech.agriculture),a=ds(Qr.tech.smokehouse),r=ds(Qr.tech.reclaimer)||ds(Qr.tech.stone_axe),i=ds(Qr.tech.alt_lodge),c=ds(Qr.tech.wind_plant),o=[],n=[];if(!t.race.artifical){if(["agriculture","farm","hunting","s_lodge","wind_plant","compost","soul_eater"].forEach((function(e){fi("tech",e)})),["silo","farm","mill","windmill","smokehouse","lodge","compost","soul_well"].forEach((function(e){fi("city",e)})),i){mi("tech","s_lodge");let e=vi("tech","farm")>=1||vi("tech","hunting")>=2?1:0;e>0&&(!t.tech.s_lodge||t.tech.s_lodge=1&&gi("city","lodge","farm",{count:0})}if(a){mi("tech","hunting");let e=vi("tech","farm")>=1||vi("tech","s_lodge")>=1?2:vi("tech","agriculture")>=3?1:0;e>0&&(!t.tech.hunting||t.tech.hunting=1&&gi("city","smokehouse","silo",{count:0}),t.tech.hunting>=2&&!i&&gi("city","lodge","farm",{count:0})}else n.push("hunting"),o.push("city-smokehouse"),i||n.push("city-lodge");if(e){mi("tech","farm");let e=vi("tech","hunting")>=2||vi("tech","s_lodge")>=1?1:0;e>0&&(!t.tech.farm||t.tech.farm=1?3:vi("tech","s_lodge")>=1?1:0;a>0&&(!t.tech.agriculture||t.tech.agriculture=1&&gi("city","farm","lodge",{count:0}),t.tech.agriculture>=3&&gi("city","silo","smokehouse",{count:0}),t.tech.agriculture>=4&&!c&&gi("city","mill","windmill",{count:0,on:0})}else n.push("agriculture","farm"),o.push("city-farm","city-silo","city-mill");t.race.soul_eater?(mi("tech","soul_eater"),mi("city","soul_well")):(o.push("city-soul_well"),n.push("soul_eater")),t.race.detritivore?(mi("tech","compost"),mi("city","compost")):(n.push("compost"),o.push("city-compost")),c?(mi("tech","wind_plant"),t.tech.wind_plant>=1&&gi("city","windmill","mill",{count:0,on:0})):(n.push("wind_plant"),o.push("city-windmill"),delete s[F("city_mill_title2")])}let l=[],u=[];!t.race.orbit_decayed&&e&&t.tech.agriculture>=1&&t.city.farm.count>0?l.push("farmer"):u.push("farmer"),t.race.carnivore&&!t.race.herbivore||t.race.soul_eater||t.race.unfathomable?(l.push("hunter"),u.push("unemployed")):(u.push("hunter"),l.push("unemployed")),!t.race.orbit_decayed&&r?l.push("lumberjack"):u.push("lumberjack"),l.forEach((function(e){t.civic[e].display||(t.civic[e].workers=0,t.civic[e].display=!0)})),u.forEach((function(e){t.civic[e].display&&(t.civic.d_job===e&&(t.civic.d_job=l[0]),t.civic[l[0]].workers+=t.civic[e].workers,t.civic[e].workers=0,t.civic[e].display=!1)})),t.race.casting&&(e||(t.race.casting.total-=t.race.casting.farmer,t.race.casting.farmer=0),Ws()),Bi(o),Gi(n),cr("Food")}function $i(a){switch(a){case"high_pop":t.resource[t.race.species].amount=Math.round(t.resource[t.race.species].amount*ui.high_pop.vars()[0]),t.civic.hasOwnProperty("garrison")&&(t.civic.garrison.workers=Math.round(t.civic.garrison.workers*ui.high_pop.vars()[0]));break;case"kindling_kindred":if(t.race.smoldering)break;yi();break;case"smoldering":if(t.resource.Chrysotile.display=!0,t.race.kindling_kindred)break;yi();break;case"forge":Ws();break;case"soul_eater":ua("lumberjack");case"detritivore":case"carnivore":case"herbivore":wi();break;case"unfathomable":for(wi(),t.city.hasOwnProperty("surfaceDwellers")||(t.city.surfaceDwellers=[]);t.city.surfaceDwellers.lengthui.unfathomable.vars()[0]&&(t.city.surfaceDwellers.length=ui.unfathomable.vars()[0]),t.race.psychic&&zi();break;case"flier":cr("Stone"),cr("Brick"),t.resource.Cement.display=!1,t.civic.cement_worker.display=!1,t.civic.cement_worker.workers=0,fi("tech","cement"),fi("city","cement_plant");break;case"sappy":"quarry_worker"===t.civic.d_job&&(t.civic.d_job="unemployed"),t.civic.quarry_worker.display=!1,t.civic.quarry_worker.workers=0,cr("Stone"),fi("tech","hammer"),fi("city","rock_quarry");break;case"apex_predator":Gi(["armor"]),fi("tech","armor");break;case"environmentalist":delete s[F("city_coal_power")],delete s[F("city_mana_engine")],delete s[F("city_oil_power")];break;case"terrifying":Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),t.settings.showMarket=!1,0===t.settings.marketTabs&&(t.settings.marketTabs=1),Bi(["city-trade"]),Gi(["trade"]),fi("tech","trade"),fi("city","trade");break;case"slaver":mi("tech","slaves"),t.tech.slaves>=1&&(mi("city","slave_pen",{count:0,slaves:0}),t.city.slave_pen.count>0&&!t.race.orbit_decayed&&(t.resource.Slave.display=!0));break;case"cannibalize":mi("tech","sacrifice"),t.tech.mining&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0});break;case"magnificent":t.tech.theology>=2&&mi("city","shrine",{count:0,morale:0,metal:0,know:0,tax:0});break;case"unified":t.tech.world_control=1,t.tech.unify=2,rc($("#garrison")),rc($("#c_garrison")),fe($("#garrison"),!0),fe($("#c_garrison"),!1);for(let e=0;e<3;e++){if(t.civic.foreign[`gov${e}`].occ){let a=la("federation"===t.civic.govern.type?15:20);t.civic.garrison.max+=a,t.civic.garrison.workers+=a,t.civic.foreign[`gov${e}`].occ=!1}t.civic.foreign[`gov${e}`].buy=!1,t.civic.foreign[`gov${e}`].anx=!1,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none"}D("spy"),D("spyop");break;case"noble":t.civic.taxes.tax_rate<10?t.civic.taxes.tax_rate=10:t.civic.taxes.tax_rate>20&&(t.civic.taxes.tax_rate=20);break;case"toxic":"troll"===t.race.species&&t.tech.science&&t.tech.science>=8&&Xc("godwin");break;case"thalassophobia":Bi(["city-wharf"]),Gi(["wharf"]),fi("city","wharf");break;case"hooved":t.resource.Horseshoe.display=!0,t.race.hasOwnProperty("shoecnt")||(t.race.shoecnt=0);break;case"slow":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w?(Ii("stop"),Ii("start")):window.location.reload();case"hyper":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w?(Ii("stop"),Ii("start")):window.location.reload();case"calm":t.tech.primitive>=3&&(mi("city","meditation",{count:0}),t.race.orbit_decayed||(t.resource.Zen.display=!0));break;case"blood_thirst":t.race.blood_thirst_count=1;break;case"deconstructor":t.resource.Nanite.display=!0,mi("city","nanite_factory",{count:1,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Bolognium:0,Orichalcum:0});break;case"shapeshifter":qi(!1,!0);break;case"imitation":ki(!0);break;case"evil":cr("Lumber"),cr("Furs"),cr("Plywood");break;case"psychic":t.tech.psychic&&(t.resource.Energy.display=!0,t.settings.showPsychic=!0);break;case"ooze":t.tech.high_tech||"custom"===t.race.species||"sludge"===t.race.species||(t.race.gross_enabled=1),lc(!0)}}function xi(a,r){switch(a){case"high_pop":t.resource[t.race.species].amount=Math.round(t.resource[t.race.species].amount/ui.high_pop.vars(r)[0]),t.civic.hasOwnProperty("garrison")&&(t.civic.garrison.workers=Math.round(t.civic.garrison.workers/ui.high_pop.vars(r)[0]));break;case"kindling_kindred":if(t.race.smoldering)break;t.resource.Lumber.display=!0,t.tech.foundry&&(t.resource.Plywood.display=!0),t.race.casting&&Ws(),mi("city","sawmill"),mi("city","graveyard"),mi("city","lumber_yard"),mi("tech","axe"),mi("tech","reclaimer"),mi("tech","saw"),!t.tech.axe&&!t.tech.reclaimer||t.race.orbit_decayed||(t.civic.lumberjack.display=!0);break;case"smoldering":if(bi("Chrysotile"),t.race.kindling_kindred)break;t.resource.Lumber.display=!0,t.tech.foundry&&(t.resource.Plywood.display=!0),t.race.casting&&Ws(),mi("city","sawmill"),mi("city","graveyard"),mi("city","lumber_yard"),mi("tech","axe"),mi("tech","reclaimer"),mi("tech","saw"),!t.tech.axe&&!t.tech.reclaimer||t.race.orbit_decayed||(t.civic.lumberjack.display=!0);break;case"forge":Ws();break;case"soul_eater":ua("lumberjack");case"detritivore":case"carnivore":case"herbivore":case"unfathomable":wi(),t.race.psychic&&zi();break;case"flier":cr("Stone"),cr("Brick"),mi("tech","cement"),t.tech.cement&&(mi("city","cement_plant"),t.resource.Cement.display=!0,t.civic.cement_worker.display=!0);break;case"sappy":cr("Stone"),mi("tech","hammer"),t.tech.mining>=1&&(mi("city","rock_quarry",{count:0,asbestos:0}),(t.city.rock_quarry&&t.city.rock_quarry.count>0||t.race.lone_survivor)&&(t.civic.quarry_worker.display=!0));break;case"apex_predator":mi("tech","armor");break;case"environmentalist":delete s[F("city_hydro_power")],delete s[F("city_wind_power")];break;case"terrifying":t.settings.showMarket=!0,mi("tech","trade"),mi("city","trade");break;case"slaver":Bi(["city-slave_pen"]),Gi(["slaves"]),fi("city","slave_pen"),fi("tech","slaves"),t.resource.Slave.amount=0,t.resource.Slave.max=0,t.resource.Slave.display=!1,D("slave");break;case"cannibalize":Bi(["city-s_alter"]),Gi(["sacrifice"]),fi("tech","sacrifice"),delete t.city.s_alter,D("sacrifice");break;case"magnificent":Bi(["city-shrine"]),fi("city","shrine");break;case"thalassophobia":t.tech.wharf&&mi("city","wharf",{count:0});break;case"hooved":Bi(["city-horseshoe","space-horseshoe"]),t.resource.Horseshoe.display=!1,D("horseshoe");break;case"slow":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w?(Ii("stop"),Ii("start")):window.location.reload();case"hyper":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w?(Ii("stop"),Ii("start")):window.location.reload();case"calm":Bi(["city-meditation"]),t.resource.Zen.display=!1,fi("city","meditation");break;case"blood_thirst":delete t.race.blood_thirst_count;break;case"deconstructor":Bi(["city-nanite_factory"]),t.resource.Nanite.display=!1,fi("city","nanite_factory");break;case"shapeshifter":rc($("#sshifter")),qi();break;case"imitation":t.race.iTraits&&(Object.keys(t.race.iTraits).forEach((function(e){if("imitation"!==e)if(0===t.race.iTraits[e]){let a=t.race[e];delete t.race[e],xi(e,a)}else t.race[e]=t.race.iTraits[e]})),delete t.race.iTraits);break;case"evil":cr("Lumber"),cr("Furs"),cr("Plywood");break;case"psychic":t.resource.Energy.display=!1,t.settings.showPsychic=!1;break;case"ooze":delete t.race.gross_enabled,lc(!0)}}function ki(e){if(t.race.imitation&&t.race.srace){t.race.iTraits||(t.race.iTraits={}),t.race.shapeshifter&&qi(t.race.ss_genus===di[t.race.srace].type&&"none",!0);let a=[];if(Object.keys(li[di[t.race.srace].type]).forEach((function(e){t.race[e]||a.push(e)})),"custom"===t.race.srace){let e=["evil","evil"];Object.keys(di[t.race.srace].traits).forEach((function(t){ui[t].val>ui[e[0]].val?e[0]=t:ui[t].val=0?t.race[e]=ui.shapeshifter.vars()[0]:t.race[e]=ui.shapeshifter.vars()[1],$i(e),r.push(e))})),t.race.ss_genus=e),a){rc($("#sshifter")),t.race.ss_genus=t.race.hasOwnProperty("ss_genus")?t.race.ss_genus:"none";let e="";Object.keys(li).forEach((function(a){"synthetic"!==a&&"eldritch"!==a&&a!==di[t.race.species].type&&(!t.race.imitation||a!==di[t.race.srace].type)&&t.stats.achieve[`genus_${a}`]&&t.stats.achieve[`genus_${a}`].l>0&&(e+=`{{ '${a}' | genus }}`)})),$("#sshifter").append(`${F("trait_shapeshifter_name")}: \n \n {{ 'none' | genus }}${e}\n `),sc({el:"#sshifter",data:t.race,methods:{setShape(e){qi(e)}},filters:{genus:e=>F(`genelab_genus_${e}`)}})}t.race.ss_traits=r}function Mi(e,a){if(a=a||{},t.race[e]&&!a.force)switch(t.race[e]){case.25:return t.race[e]=a.down?.25:.5,!a.down;case.5:return t.race[e]=a.down?.25:1,!0;case 1:return t.race[e]=a.down?.5:2,!0;case 2:return t.race[e]=a.down?1:3,!0;case 3:return t.race[e]=a.down?2:3,!!a.down}else if(a.set)return t.race[e]=a.set,!0;return!1}function Pi(e){if(t.race.unfathomable&&t.city.surfaceDwellers&&t.city.surfaceDwellers.includes(e)&&t.city.captive_housing){let a=t.city.surfaceDwellers.indexOf(e),r=t.city.captive_housing[`race${a}`];if(r>100&&(r=100),r>t.civic.torturer.workers){let e=r-t.civic.torturer.workers;r-=Math.ceil(e/3)}return r/100*((t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0)/5)}return 0}function Oi(e,a){switch(e){case"name":{let e={hooved:Ci(!1),promiscuous:t.race.artifical?F("trait_promiscuous_synth_name"):ui.promiscuous.name};return a?e[a]?e[a]:ui[a].name:e}case"desc":{let e={hooved:Ci(!0),promiscuous:t.race.artifical?F("trait_promiscuous_synth"):ui.promiscuous.desc};return a?e[a]?e[a]:ui[a].desc:e}}}function Ci(e){return t.race.sludge?F(e?"trait_hooved_slime":"trait_hooved_slime_name"):["cath","wolven","dracnid","seraph","cyclops","kobold","tuskin","sharkin"].includes(t.race.species)?F(e?`trait_hooved_${t.race.species}`:`trait_hooved_${t.race.species}_name`):["humanoid","avian","plant","fungi","reptilian","fey","synthetic"].includes(di[t.race.species].type)?F(e?`trait_hooved_${di[t.race.species].type}`:`trait_hooved_${di[t.race.species].type}_name`):e?ui.hooved.desc:ui.hooved.name}Object.keys(_i).forEach((function(e){let t="organism"===e?"humanoid":e;_i[e].solar={titan:F(`genus_${t}_solar_titan`),enceladus:F(`genus_${t}_solar_enceladus`),triton:F(`genus_${t}_solar_triton`),eris:F(`genus_${t}_solar_eris`)}}));const ji={grassland:{label:F("biome_grassland_name"),desc:F("biome_grassland"),vars:()=>t.race.rejuvenated?[1.25]:[1.2],wiki:["%"]},oceanic:{label:F("biome_oceanic_name"),desc:F("biome_oceanic"),vars:()=>t.race.rejuvenated?[1.25,1.12,.92]:[1.12,1.06,.95],wiki:["%","%","%"]},forest:{label:F("biome_forest_name"),desc:F("biome_forest"),vars:()=>t.race.rejuvenated?[1.35]:[1.2],wiki:["%"]},desert:{label:F("biome_desert_name"),desc:F("biome_desert"),vars:()=>t.race.rejuvenated?[1.35,1.18,.6]:[1.2,1.1,.75],wiki:["%","%","%"]},volcanic:{label:F("biome_volcanic_name"),desc:F("biome_volcanic"),vars:()=>t.race.rejuvenated?[.8,1.25,1.15]:[.9,1.12,1.08],wiki:["%","%","%"]},tundra:{label:F("biome_tundra_name"),desc:F("biome_tundra"),vars:()=>t.race.rejuvenated?[1.5,.8]:[1.25,.9],wiki:["%","%"]},savanna:{label:F("biome_savanna_name"),desc:F("biome_savanna"),vars:()=>t.race.rejuvenated?[1.18,1.25,.75]:[1.1,1.18,.8],wiki:["%","%","%"]},swamp:{label:F("biome_swamp_name"),desc:F("biome_swamp"),vars:()=>t.race.rejuvenated?[1.6,1.35,1.15,.78]:[1.4,1.25,1.1,.88],wiki:["%","%","%","%"]},ashland:{label:F("biome_ashland_name"),desc:F("biome_ashland"),vars:()=>t.race.rejuvenated?[.55,1.35,1.2]:[.62,1.25,1.1],wiki:["%","%","%"]},taiga:{label:F("biome_taiga_name"),desc:F("biome_taiga"),vars:()=>t.race.rejuvenated?[1.2,1.65,.88]:[1.1,1.5,.92],wiki:["%","%","%"]},hellscape:{label:F("biome_hellscape_name"),desc:F("biome_hellscape"),vars:()=>t.race.rejuvenated?[.2]:[.25],wiki:["%"]},eden:{label:F("biome_eden_name"),desc:F("biome_eden")}},Si={toxic:{label:F("planet_toxic"),desc:F("planet_toxic_desc"),vars:()=>t.race.rejuvenated?[2,1.5]:[1,1.25],wiki:["A","-%"]},mellow:{label:F("planet_mellow"),desc:F("planet_mellow_desc"),vars:()=>t.race.rejuvenated?[2,3,.88]:[1.5,2,.9],wiki:["%","A","%"]},rage:{label:F("planet_rage"),desc:F("planet_rage_desc"),vars:()=>t.race.rejuvenated?[1.1,1.05,1]:[1.05,1.02,1],wiki:["%","%","A"]},stormy:{label:F("planet_stormy"),desc:F("planet_stormy_desc")},ozone:{label:F("planet_ozone"),desc:F("planet_ozone_desc"),vars:()=>t.race.rejuvenated?[.18]:[.25],wiki:["-A"]},magnetic:{label:F("planet_magnetic"),desc:F("planet_magnetic_desc"),vars:()=>t.race.rejuvenated?[2,150,.98]:[1,100,.985],wiki:["A","A","%"]},trashed:{label:F("planet_trashed"),desc:F("planet_trashed_desc"),vars:()=>t.race.rejuvenated?[.8,1.2]:[.75,1],wiki:["%","%"]},elliptical:{label:F("planet_elliptical"),desc:F("planet_elliptical_desc")},flare:{label:F("planet_flare"),desc:F("planet_flare_desc")},dense:{label:F("planet_dense"),desc:F("planet_dense_desc"),vars:()=>t.race.rejuvenated?[1.5,1.2,1.35]:[1.2,1,1.2],wiki:["%","A","%"]},unstable:{label:F("planet_unstable"),desc:F("planet_unstable_desc")},permafrost:{label:F("planet_permafrost"),desc:F("planet_permafrost_desc"),vars:()=>t.race.rejuvenated?[.7,125]:[.75,100],wiki:["%","A"]},retrograde:{label:F("planet_retrograde"),desc:F("planet_retrograde_desc")}};function Fi(e){e=e||[];let t=Object.keys(di).filter((function(t){return di[t].basic()&&!e.includes(t)}));return t[Cc(t)]}function zi(){if(!t.settings.tabLoad&&(2!==t.settings.civTabs||6!==t.settings.govTabs))return;let e=$("#psychicPowers");rc(e),t.race.psychic&&t.tech.psychic&&(function(e){let a=$('
      ');e.append(a),a.append($(`
      ${F("psychic_boost_title")}
      `));let r=$("
      ");a.append(r);let s="";if(Object.keys(Va).forEach((function(e){t.resource[e].display&&(s+=`${t.resource[e].name}`)})),r.append(`
      ${s}
      `),a.append('
      '),t.tech.psychic>=4){let e=$(`
      ${F("psychic_channel")}
      `),t=$('{{ c.boost }}'),r=$(`«`),s=$(`»`);e.append(r),e.append(t),e.append(s),a.append(e)}let i=t.tech.psychic>=5?60:75,c=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;sc({el:"#psychicBoost",data:{b:t.race.psychicPowers.boost,c:t.tech.psychic>=4?t.race.psychicPowers.channel:{}},methods:{boostVal(){t.resource.Energy.amount>=i&&(t.resource.Energy.amount-=i,t.race.psychicPowers.boostTime=72*c)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.boost--}},filters:{boost:e=>F("psychic_boost_button",[t.resource[e]?t.resource[e].name:"N/A",i]),boostTime:()=>t.race.psychicPowers.boostTime>0?F("psychic_boost_time",[t.race.psychicPowers.boostTime]):""}});const o=document.getElementById("psyhscrolltarget");o.addEventListener("wheel",(e=>{e.preventDefault(),o.scrollLeft+=e.deltaY})),Ti("psychicBoost",(function(){return F("psychic_boost_desc",[ui.psychic.vars()[3]])}),{elm:"#psychicBoost > div > button"})}(e),function(e){let a=$('
      ');e.append(a),a.append($(`
      ${F("psychic_murder_title")}
      `)),a.append('
      ');let r=t.tech.psychic>=5?8:10;sc({el:"#psychicKill",data:{},methods:{murder(){t.resource.Energy.amount>=r&&t.resource[t.race.species].amount>=1&&(t.resource.Energy.amount-=r,t.resource[t.race.species].amount--,t.stats.psykill++,t.race.anthropophagite&&Vi("Food",1e4*ui.anthropophagite.vars()[0]),10===t.stats.psykill&&zi())}},filters:{kill:()=>F("psychic_murder_button",[r])}}),Ti("psychicKill",(function(){return F("psychic_murder_desc")}),{elm:"#psychicKill > div > button"})}(e),t.tech.psychic>=2&&function(e){let a=$('
      ');if(e.append(a),a.append($(`
      ${F("psychic_assault_title")}
      `)),a.append('
      '),t.tech.psychic>=4){let e=$(`
      ${F("psychic_channel")}
      `),t=$('{{ assault }}'),r=$(`«`),s=$(`»`);e.append(r),e.append(t),e.append(s),a.append(e)}let r=t.tech.psychic>=5?36:45,s=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;sc({el:"#psychicAssault",data:t.tech.psychic>=4?t.race.psychicPowers.channel:{},methods:{boostVal(){t.resource.Energy.amount>=r&&(t.resource.Energy.amount-=r,t.race.psychicPowers.assaultTime=72*s)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.assault--}},filters:{boost:()=>F("psychic_boost_button",[F("psychic_attack"),r]),boostTime:()=>t.race.psychicPowers.assaultTime>0?F("psychic_boost_time",[t.race.psychicPowers.assaultTime]):""}}),Ti("psychicAssault",(function(){return F("psychic_assault_desc",[ui.psychic.vars()[3]])}),{elm:"#psychicAssault > div > button"})}(e),t.tech.psychic>=3&&(t.race.psychicPowers.cash||(t.race.psychicPowers.cash=0),function(e){let a=$('
      ');if(e.append(a),a.append($(`
      ${F("psychic_profit_title")}
      `)),a.append('
      '),t.tech.psychic>=4){let e=$(`
      ${F("psychic_channel")}
      `),t=$('{{ cash }}'),r=$(`«`),s=$(`»`);e.append(r),e.append(t),e.append(s),a.append(e)}let r=t.tech.psychic>=5?52:65,s=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;sc({el:"#psychicFinance",data:t.tech.psychic>=4?t.race.psychicPowers.channel:{},methods:{boostVal(){t.resource.Energy.amount>=r&&(t.resource.Energy.amount-=r,t.race.psychicPowers.cash=72*s)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.cash--}},filters:{boost:()=>F("psychic_boost_button",[F("psychic_profit"),r]),boostTime:()=>t.race.psychicPowers.cash>0?F("psychic_boost_time",[t.race.psychicPowers.cash]):""}}),Ti("psychicFinance",(function(){return F("psychic_profit_desc",[ui.psychic.vars()[3]])}),{elm:"#psychicFinance > div > button"})}(e)),t.tech.psychicthrall&&t.tech.unfathomable&&t.race.unfathomable&&(t.tech.psychicthrall>=2&&function(e){let a=$('
      ');e.append(a),a.append($(`
      ${F("psychic_stun_title")}
      `)),a.append('
      ');let r=t.tech.psychic>=5?80:100;sc({el:"#psychicCapture",data:{},methods:{stun(){if(t.resource.Energy.amount>=r&&t.tech.unfathomable){let e=0;if(t.city.hasOwnProperty("surfaceDwellers"))for(let a=0;aF("psychic_stun_button",[r])}}),Ti("psychicCapture",(function(){return F("psychic_stun_desc")}),{elm:"#psychicCapture > div > button"})}(e),function(e){let a=$('
      ');e.append(a),a.append($(`
      ${F("psychic_mind_break_title")}
      `)),a.append('
      ');let r=t.tech.psychic>=5?64:80;sc({el:"#psychicMindBreak",data:{},methods:{breakMind(){if(t.resource.Energy.amount>=r&&t.tech.unfathomable){let e=[];if(t.city.hasOwnProperty("surfaceDwellers"))for(let a=0;a0&&e.push(a);if(e.length>0){let a=e[Math.rand(0,e.length)];t.city.captive_housing[`jailrace${a}`]--,t.city.captive_housing[`race${a}`]++,t.resource.Energy.amount-=r}}}},filters:{break:()=>F("psychic_mind_break_button",[r])}}),Ti("psychicMindBreak",(function(){return F("psychic_mind_break_desc")}),{elm:"#psychicMindBreak > div > button"})}(e)))}var Ai=!1;function Ti(e,a,r){r||(r={}),r.hasOwnProperty("elm")||(r.elm="#"+e),r.hasOwnProperty("bind")||(r.bind=!0),r.hasOwnProperty("unbind")||(r.unbind=!0),r.hasOwnProperty("placement")||(r.placement="bottom"),r.bind&&$(r.elm).on(r.bind_mouse_enter?"mouseenter":"mouseover",(function(){(Ai||$("#popper").length>0)&&Ei();let s=r.wide?" wide":"",i=r.classes?r.classes:"has-background-light has-text-dark pop-desc";var c=$(`
      `);r.attach?$(r.attach).append(c):$("#main").append(c),a&&c.append("function"==typeof a?a({this:this,popper:c}):a),Ai=Popper.createPopper(r.self?this:$(r.elm)[0],document.querySelector("#popper"),{placement:r.placement,modifiers:[{name:"flip",enabled:!0},{name:"offset",options:{offset:r.offset?r.offset:[0,0]}}]}),c.show(),r.hasOwnProperty("in")&&"function"==typeof r.in&&r.in({this:this,popper:c,id:"popper"}),Tc("firework")&&t[t.race.cataclysm||t.race.orbit_decayed?"space":"city"].firework.on>0&&$(c).append('')})),r.unbind&&("ontouchstart"in document.documentElement&&navigator.userAgent.match(t.settings.touch)?$(r.elm).on("touchend",(function(e){Ei(),r.hasOwnProperty("out")&&"function"==typeof r.out&&r.out({this:this,popper:$("#popper"),id:"popper"})})):$(r.elm).on(r.bind_mouse_enter?"mouseleave":"mouseout",(function(){Ei(),r.hasOwnProperty("out")&&"function"==typeof r.out&&r.out({this:this,popper:$("#popper"),id:"popper"})})))}function Ei(e){e&&$("#popper").data("id")!==e||($("#popper").hide(),Ai&&(Ai.destroy(),Ai=!1),rc($("#popper"),!0))}function Ii(e){switch(e){case"stop":M.w?M.w.postMessage({loop:"clear"}):(clearInterval(P.main_loop),clearInterval(P.mid_loop),clearInterval(P.long_loop)),M.s=!1;break;case"start":if(M.resetTimers(),t.settings.gameSpeed=1,Ki(),t.settings.at>0&&(t.settings.gameSpeed*=t.settings.atMultiplier),t.race.slow){const e=1-ui.slow.vars()[0]/100;t.settings.gameSpeed*=e}if(t.race.hyper){const e=1+ui.hyper.vars()[0]/100;t.settings.gameSpeed*=e}for(let e in M.timers)M.timers[e]/=t.settings.gameSpeed;M.w?(M.w.postMessage({loop:"short",period:M.timers.main}),M.w.postMessage({loop:"mid",period:M.timers.mid}),M.w.postMessage({loop:"long",period:M.timers.long})):(P.main_loop=setInterval((function(){fastLoop()}),M.timers.main),P.mid_loop=setInterval((function(){midLoop()}),M.timers.mid),P.long_loop=setInterval((function(){longLoop()}),M.timers.long)),M.s=!0}}function Ki(){if(!t.stats.hasOwnProperty("current"))return;const e=Date.now()-t.stats.current;if(e>=12e4){const a=t.settings.at+2*e/3,r=288e5;t.settings.at=Math.min(a,r)}}function Li(e,t){let a=ai(),r=[];switch(e){case"power":r=["city:transmitter","prtl_ruins:arcology","city:apartment","int_alpha:habitat","int_alpha:luxury_condo","spc_red:spaceport","spc_titan:titan_spaceport","spc_titan:electrolysis","int_alpha:starport","spc_dwarf:shipyard","spc_titan:ai_core2","spc_eris:drone_control","spc_titan:ai_colonist","int_blackhole:s_gate","gxy_gateway:starbase","spc_triton:fob","spc_enceladus:operating_base","spc_enceladus:zero_g_lab","spc_titan:sam","gxy_gateway:ship_dock","prtl_ruins:hell_forge","int_neutron:stellar_forge","int_neutron:citadel","tau_home:orbital_station","tau_red:orbital_platform","tau_gas:refueling_station","tau_home:tau_farm","tau_gas:ore_refinery","tau_gas:whaling_station","city:coal_mine","spc_moon:moon_base","spc_red:red_tower","spc_home:nav_beacon","int_proxima:xfer_station","gxy_stargate:telemetry_beacon","int_nebula:nexus","gxy_stargate:gateway_depot","spc_dwarf:elerium_contain","spc_gas:gas_mining","spc_belt:space_station","spc_gas_moon:outpost","gxy_gorddon:embassy","gxy_gorddon:dormitory","gxy_alien1:resort","spc_gas_moon:oil_extractor","int_alpha:int_factory","city:factory","spc_red:red_factory","spc_dwarf:world_controller","prtl_fortress:turret","prtl_badlands:war_drone","city:wardenclyffe","city:biolab","city:mine","city:rock_quarry","city:cement_plant","city:sawmill","city:mass_driver","int_neutron:neutron_miner","prtl_fortress:war_droid","prtl_pit:soul_forge","gxy_chthonian:excavator","int_blackhole:far_reach","prtl_badlands:sensor_drone","prtl_badlands:attractor","city:metal_refinery","gxy_stargate:gateway_station","gxy_alien1:vitreloy_plant","gxy_alien2:foothold","gxy_gorddon:symposium","int_blackhole:mass_ejector","city:casino","spc_hell:spc_casino","tau_home:tauceti_casino","prtl_fortress:repair_droid","gxy_stargate:defense_platform","prtl_ruins:guard_post","prtl_lake:cooling_tower","prtl_lake:harbour","prtl_spire:purifier","prtl_ruins:archaeology","prtl_pit:gun_emplacement","prtl_gate:gate_turret","prtl_pit:soul_attractor","prtl_gate:infernite_mine","int_sirius:ascension_trigger","spc_kuiper:orichalcum_mine","spc_kuiper:elerium_mine","spc_kuiper:uranium_mine","spc_kuiper:neutronium_mine","spc_dwarf:m_relay","tau_home:tau_factory","tau_home:infectious_disease_lab","tau_home:alien_outpost","tau_gas:womling_station","spc_red:atmo_terraformer","tau_star:matrix","tau_home:tau_cultural_center","prtl_pit:soul_capacitor","city:replicator"];break;case"moon":r=["spc_moon:helium_mine","spc_moon:iridium_mine","spc_moon:observatory"];break;case"red":r=["spc_red:living_quarters","spc_red:exotic_lab","spc_red:red_mine","spc_red:fabrication","spc_red:biodome","spc_red:vr_center"];break;case"belt":r=["spc_belt:elerium_ship","spc_belt:iridium_ship","spc_belt:iron_ship"];break;case"alpha":r=["int_alpha:fusion","int_alpha:mining_droid","int_alpha:processing","int_alpha:laboratory","int_alpha:g_factory","int_alpha:exchange","int_alpha:zoo"];break;case"nebula":r=["int_nebula:harvester","int_nebula:elerium_prospector"];break;case"gateway":r=["gxy_gateway:bolognium_ship","gxy_gateway:dreadnought","gxy_gateway:cruiser_ship","gxy_gateway:frigate_ship","gxy_gateway:corvette_ship","gxy_gateway:scout_ship"];break;case"alien2":r=["gxy_alien2:armed_miner","gxy_alien2:ore_processor","gxy_alien2:scavenger"];break;case"lake":r=["prtl_lake:bireme","prtl_lake:transport"];break;case"spire":r=["prtl_spire:port","prtl_spire:base_camp","prtl_spire:mechbay"];break;case"titan":r=["spc_titan:titan_quarters","spc_titan:titan_mine","spc_titan:g_factory","spc_titan:decoder"];break;case"enceladus":r=["spc_enceladus:water_freighter","spc_enceladus:operating_base","spc_enceladus:zero_g_lab"];break;case"eris":r=["spc_eris:shock_trooper","spc_eris:tank"];break;case"tau_home":r=["tau_home:colony","tau_home:tau_factory","tau_home:mining_pit","tau_home:infectious_disease_lab"];break;case"tau_red":r=["tau_red:womling_village","tau_red:womling_farm","tau_red:overseer","tau_red:womling_mine","tau_red:womling_fun","tau_red:womling_lab"];break;case"tau_roid":r=["tau_roid:mining_ship","tau_roid:whaling_ship"]}t&&(a[e].l.length=0),r.forEach((function(t){a[e].l.includes(t)||a[e].l.push(t)})),a[e].l.length>r.length&&a[e].l.forEach((function(t){r.includes(t)||a[e].l.splice(a[e].l.indexOf(t),1)}))}function Ni(e){(e=e||h).forEach((function(e){p[e]=[],t.settings.msgFilters[p.view].vis||($(`#msgQueueFilter-${p.view}`).removeClass("is-active"),$(`#msgQueueFilter-${e}`).addClass("is-active"),p.view=e)}))}function Di(e,a,r,s,i){if(s=s||[],i||s.includes("all")||s.push("all"),a=a||"warning",s.includes(p.view)){let r=$('

      '+e+"

      ");$("#msgQueueLog").prepend(r),$("#msgQueueLog").children().length>t.settings.msgFilters[p.view].max&&$("#msgQueueLog").children().last().remove()}s.forEach((function(r){p[r].unshift({msg:e,color:a}),p[r].length>t.settings.msgFilters[r].max&&p[r].pop()})),r||s.forEach((function(r){t.lastMsg[r]&&(t.lastMsg[r].unshift({m:e,c:a}),t.lastMsg[r].length>t.settings.msgFilters[r].save&&t.lastMsg[r].splice(t.settings.msgFilters[r].save))}))}function Bi(e){for(let a=t.queue.queue.length-1;a>=0;a--)e.includes(t.queue.queue[a].id)&&t.queue.queue.splice(a,1)}function Gi(e){for(let a=t.r_queue.queue.length-1;a>=0;a--)e.includes(Qr.tech[t.r_queue.queue[a].type].grant[0])&&t.r_queue.queue.splice(a,1)}function Ri(){let e=t.tech.queue>=2?t.tech.queue>=3?8:5:3;t.stats.feat.journeyman&&t.stats.feat.journeyman>=2&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>=2&&(e+=Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman)>=4?2:1),t.genes.queue&&t.genes.queue>=2&&(e*=2);let a=N("pragmatist",0);a&&(e=Math.round(e*(1+a/100))),t.queue.max=e}function Hi(){let e=3;if(t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0){let a=Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman);e+=a>=3?a>=5?3:2:1}t.genes.queue&&t.genes.queue>=2&&(e*=2);let a=N("theorist",0);a&&(e=Math.round(e*(1+a/100))),t.r_queue.max=e}function Ui(){!function(){let e=$("#buildQueue .buildList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}(),rc($("#buildQueue")),$("#buildQueue").append($(`\n

      ${F("building_queue")} ({{ | used_q }}/{{ max }})

      \n \n `));let e=$('
        ');$("#buildQueue").append(e),e.append($('
      • {{ item.label }}{{ item.q | count }} [{{ item.time | time }}{{ item.t_max | max_t(item.time) }}]
      • '));try{sc({el:"#buildQueue",data:t.queue,methods:{remove(e){let a=y();for(let r=0;r0&&(t.queue.queue[e].q-=t.queue.queue[e].qs),t.queue.queue[e].q<=0){Ei(`q${t.queue.queue[e].id}${e}`),t.queue.queue.splice(e,1),Ui();break}},setID:e=>`q${t.queue.queue[e].id}${e}`,setData(e,a){let r,s=t.queue.queue[e].id.split("-");"arpa"===s[0].substring(0,4)?r=s[0].substring(4):"city"===s[0]||"evolution"===s[0]||"starDock"===s[0]?r=Qr[s[0]][s[1]]:Object.keys(Qr[s[0]]).forEach((function(e){Qr[s[0]][e].hasOwnProperty(s[1])&&(r=Qr[s[0]][e][s[1]])}));let i={};if(r.cost){let e=gc(r);Object.keys(e).forEach((function(t){let r=e[t]();r>0&&(i[`${a}-${t}`]=r)}))}return i},pauseQueue(){$("#pausequeue").removeClass("play"),$("#pausequeue").removeClass("pause"),t.queue.pause?(t.queue.pause=!1,$("#pausequeue").addClass("play")):(t.queue.pause=!0,$("#pausequeue").addClass("pause"))},pausedesc:()=>t.queue.pause?F("queue_play"):F("queue_pause")},filters:{time:e=>ic(e),count:e=>e>1?` (${e})`:"",max_t:(e,t)=>t===e||t<0?"":` / ${ic(e)}`,used_q(){let e=0;for(let a=0;a=4&&(r.tech.whitehole=3,r.resource.Soul_Gem.amount+=10,r.resource.Knowledge.amount+=15e5,r.stats.know-=15e5),r.tech.hasOwnProperty("quaked")&&2===r.tech.quaked&&(r.tech.quaked=1,r.resource.Knowledge.amount+=5e5,r.stats.know-=5e5),r.tech.hasOwnProperty("corrupted_ai")&&3===r.tech.corrupted_ai&&(r.tech.corrupted_ai=1,r.resource.Knowledge.amount+=5e6,r.stats.know-=5e6)),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(r))),window.location.reload())};const Qi=!1;function Zi(e,t){try{t.debug_mode=Qi,gtag("event",e,t)}catch(e){}}function Vi(e,a,r,s){let i=t.resource[e].amount+a,c=!0;return i>t.resource[e].max&&-1!=t.resource[e].max?i=t.resource[e].max:i<0&&((!s||s&&-1*i>s)&&(c=!1),i=0),Number.isNaN(i)||(t.resource[e].amount=i,r||(t.resource[e].delta+=a,"Mana"===e&&a>0&&(t.resource[e].gen_d+=a))),c}function Ji(e){let a=di[t.race.species].type;switch(a){case"animal":a="animalism";break;case"small":a="dwarfism";break;case"giant":a="gigantism";break;case"avian":case"reptilian":a="eggshell";break;case"fungi":a="chitin";break;case"insectoid":a="athropods";break;case"angelic":a="celestial";break;case"organism":a="sentience"}const r=e?[F("civics_gov_tp_name0"),F("civics_gov_tp_name1"),F("civics_gov_tp_name2"),F("civics_gov_tp_name3"),F("civics_gov_tp_name4"),F("civics_gov_tp_name5"),F("civics_gov_tp_name6"),F("civics_gov_tp_name7"),F("civics_gov_tp_name8"),F("civics_gov_tp_name9")]:[di[t.race.species].name,di[t.race.species].home,F(`biome_${t.city.biome}_name`),F(`evo_${a}_title`),F("civics_gov_name0"),F("civics_gov_name1"),F("civics_gov_name2"),F("civics_gov_name3"),F("civics_gov_name4"),F("civics_gov_name5"),F("civics_gov_name6"),F("civics_gov_name7"),F("civics_gov_name8"),F("civics_gov_name9"),F("civics_gov_name10"),F("civics_gov_name11")];return{s0:Math.rand(0,14),s1:r[Math.rand(0,r.length)]}}function Yi(e,a,r,s,i){i||(i="city"),"micro"===t.race.universe&&(s-=nc("micro",!1)),t.race.small?s-=ui.small.vars()[0]:t.race.large&&(s+=ui.large.vars()[0]),t.race.compact&&(s-=ui.compact.vars()[0]),!t.race.tunneler||"mine"!==e&&"coal_mine"!==e||(s-=ui.tunneler.vars()[0]),!t.tech.housing_reduction||"basic_housing"!==e&&"cottage"!==e||(s-=.02*t.tech.housing_reduction),t.tech.housing_reduction&&"captive_housing"===e&&(s-=.01*t.tech.housing_reduction),"basic_housing"===e&&(t.race.solitary&&(s-=ui.solitary.vars()[0]),t.race.pack_mentality&&(s+=ui.pack_mentality.vars()[0])),"cottage"===e&&(t.race.solitary&&(s+=ui.solitary.vars()[1]),t.race.pack_mentality&&(s-=ui.pack_mentality.vars()[1])),"apartment"===e&&t.race.pack_mentality&&(s-=ui.pack_mentality.vars()[1]),t.genes.creep&&!t.race.no_crispr?s-=.01*t.genes.creep:t.genes.creep&&t.race.no_crispr&&(s-=.002*t.genes.creep);let c=N("noquestions",0);c&&(s-=c),s<1.005&&(s=1.005);var o="citizen"===e?t.resource[t.race.species].amount:t[i][e]?t[i][e].count:0;return a&&(o+=a),Math.round(s**o*r)}function Xi(e,a,r,s,i,c){i||(i="space"),c=c||1.005,"micro"===t.race.universe&&(s-=nc("micro",!0)),t.genes.creep&&!t.race.no_crispr?s-=.01*t.genes.creep:t.genes.creep&&t.race.no_crispr&&(s-=.002*t.genes.creep),t.race.small&&(s-=ui.small.vars()[1]),t.race.compact&&(s-=ui.compact.vars()[1]),t.prestige.Harmony.count>0&&t.stats.achieve.ascended&&(s-=ec());let o=N("noquestions",0);o&&(s-=o),s0&&t.stats.achieve.ascended){let e=0;switch(t.race.universe){case"heavy":t.stats.achieve.ascended.hasOwnProperty("h")&&(e=t.stats.achieve.ascended.h*t.prestige.Harmony.count);break;case"antimatter":t.stats.achieve.ascended.hasOwnProperty("a")&&(e=t.stats.achieve.ascended.a*t.prestige.Harmony.count);break;case"evil":t.stats.achieve.ascended.hasOwnProperty("e")&&(e=t.stats.achieve.ascended.e*t.prestige.Harmony.count);break;case"micro":t.stats.achieve.ascended.hasOwnProperty("m")&&(e=t.stats.achieve.ascended.m*t.prestige.Harmony.count);break;case"magic":t.stats.achieve.ascended.hasOwnProperty("mg")&&(e=t.stats.achieve.ascended.mg*t.prestige.Harmony.count);break;default:t.stats.achieve.ascended.hasOwnProperty("l")&&(e=t.stats.achieve.ascended.l*t.prestige.Harmony.count)}if(e>0)return e=.01*(Math.log(50+e)-3.912023005428146),+e.toFixed(5)}return 0}function tc(e,a,r,s){if(s=void 0===s||s,e.cost){let i=0,c=!1,o=!(!a||!a.id[e.id])&&a.id[e.id],n=gc(e,o),l=!!a&&{},u=!!a&&{};a&&(Object.keys(a.r).forEach((function(e){l[e]=a.r[e]})),Object.keys(a.rr).forEach((function(e){u[e]=a.rr[e]})));let d=!1;t.interstellar.hasOwnProperty("mass_ejector")&&t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks&&Object.keys(t.race.governor.tasks).forEach((function(e){"trash"===t.race.governor.tasks[e]&&(d=!0)}));let _={};return Object.keys(n).forEach((function(e){if(i>=0&&!t.prestige.hasOwnProperty(e)&&!["Morale","HellArmy","Structs","Bool"].includes(e)){var r=Number(o?n[e](o):n[e]());if(r>0){let o="Species"===e?t.race.species:e,n="Supply"===e?t.portal.purifier.supply:Number(t.resource[o].amount),p="Supply"===e?t.portal.purifier.sup_max:t.resource[o].max,h="Supply"===e?t.portal.purifier.diff:t.resource[o].diff;if(d&&t.interstellar.mass_ejector[e]&&(h+=t.interstellar.mass_ejector[e],t.race.governor.config.trash.hasOwnProperty(e)&&(h-=Math.min(t.race.governor.config.trash[e].v,t.interstellar.mass_ejector[e]))),a&&(n+=h*(s?a.t.t:a.t.rt),a.r.hasOwnProperty(o)||(a.r[o]=0),a.rr.hasOwnProperty(o)||(a.rr[o]=0),s?(n-=Number(a.r[o]),a.r[o]+=r,a.rr[o]+=r):(n-=Number(a.rr[o]),a.rr[o]+=r),p>=0&&n>p&&(n=p)),r>n)if(h>0){let e=(r-n)/h;e>i&&(c=o,i=e),_[o]=e}else a&&(a.r=l,a.rr=u),i=-9999999,_[o]=99999999-h,(_[c]&&_[o]>_[c]||!_[c])&&(c=o)}}})),a&&i>=0&&(void 0===a.id[e.id]?a.id[e.id]=1:a.id[e.id]++,s&&(a.t.t+=i),a.t.rt+=i),r?{t:i,r:c,s:_}:i}return 0}function ac(e,a,r,s){let i=!(!r||!r.id[e.id])&&r.id[e.id],c=Ke(e.cost,i),o=0,n=!!r&&{},l=!!r&&{},u=!1;r&&(Object.keys(r.r).forEach((function(e){n[e]=r.r[e]})),Object.keys(r.rr).forEach((function(e){l[e]=r.rr[e]})));let d=!1;t.interstellar.hasOwnProperty("mass_ejector")&&t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks&&Object.keys(t.race.governor.tasks).forEach((function(e){"trash"===t.race.governor.tasks[e]&&(d=!0)}));let _={};return Object.keys(c).forEach((function(e){if(o>=0){let s=Number(c[e](i))*a;if(s>0){let a=Number(t.resource[e].amount),i=t.resource[e].diff;if(r&&(d&&t.interstellar.mass_ejector[e]&&(i+=t.interstellar.mass_ejector[e],t.race.governor.config.trash.hasOwnProperty(e)&&(i-=Math.min(t.race.governor.config.trash[e].v,t.interstellar.mass_ejector[e]))),a+=i*r.t.t,r.r[e]?(a-=Number(r.r[e]),r.r[e]+=s):r.r[e]=s,r.rr[e]?r.rr[e]+=s:r.rr[e]=s,t.resource[e].max>=0&&a>t.resource[e].max&&(a=t.resource[e].max)),s>a)if(i>0){let t=(s-a)/i;t>o&&(o=t,u=e),_[e]=t}else r&&(r.r=n,r.rr=l),o=-9999999,_[e]=99999999-i,(_[u]&&_[e]>_[u]||!_[u])&&(u=e)}}})),r&&o>=0&&(void 0===r.id[e.id]?r.id[e.id]=1:r.id[e.id]++,r.t.t+=o,r.t.rt+=o),s?{t:o,r:u,s:_}:o}function rc(e,t){if(e.find(".vb").each((function(){try{$(this)[0].__vue__.$destroy()}catch(e){}})),t){try{e[0].__vue__.$destroy()}catch(e){}e.remove()}else e.empty()}function sc(e,t){if(t=t||"create",$(e.el).length>0&&void 0!==$(e.el)[0].__vue__)try{"update"===t?$(e.el)[0].__vue__.$forceUpdate():$(e.el)[0].__vue__.$destroy()}catch(e){}"create"===t&&(new Vue(e),$(e.el).addClass("vb"))}function ic(e){let t;if(e<0)t=F("time_never");else if((e=+e.toFixed(0))>60){let a=e%60,r=(e-a)/60;if(r>=60){let e=r%60,a=(r-e)/60;a>24?(e=a%24,t=`${(a-e)/24}d ${e}h`):(e=("0"+e).slice(-2),t=`${a}h ${e}m`)}else a=("0"+a).slice(-2),t=`${r}m ${a}s`}else t=`${e}s`;return t}function cc(e){return"antimatter"===t.race.universe&&(e=+(e*=nc("antimatter")).toFixed(2)),"leo"===U()&&(e=+(e*=1+H("leo")[0]/100).toFixed(2)),e}function oc(e){return t.race.emfield?+(1.5*e).toFixed(2):e}function nc(e,a,r,s){s||(s={});let i=void 0!==s.dark?s.dark:t.prestige.Dark.count,c=void 0!==s.harmony?s.harmony:t.prestige.Harmony.count,o=void 0!==s.sludge?s.sludge:t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge[Yc(e)]?t.stats.achieve.extinct_sludge[Yc(e)]:0;switch(e){case"standard":return"standard"===t.race.universe||r?(c>0&&(i*=1+.001*c),o&&(i*=1+.03*o),1+i/200):0;case"evil":return"evil"===t.race.universe||r?(c>0&&(i*=1+.01*c),o&&(i*=1+.03*o),1+(Math.log2(10+i)-3.321928094887362)/5):1;case"micro":return"micro"===t.race.universe||r?a?(c>0&&(i*=1+.01*c),i=.01+(Math.log(100+i)-4.605170185988092)/35,o&&(i*=1+.03*o),i>.04&&(i=.04),+i.toFixed(5)):(c>0&&(i*=1+.01*c),i=.02+(Math.log(100+i)-4.605170185988092)/20,o&&(i*=1+.03*o),i>.06&&(i=.06),+i.toFixed(5)):0;case"heavy":return"heavy"===t.race.universe||r?(c>0&&(i*=1+.01*c),o&&(i*=1+.03*o),.995**i):1;case"antimatter":return"antimatter"===t.race.universe||r?(c>0&&(i*=1+.01*c),o&&(i*=1+.03*o),1+(Math.log(50+i)-3.912023005428146)/5):0;case"magic":return"magic"===t.race.universe||r?(c>0&&(i*=1+.01*c),o&&(i*=1+.03*o),1+(Math.log(50+i)-3.912023005428146)/3):0}return 0}const lc=function(e){return uc&&!e?uc:t.genes.challenge&&t.genes.challenge>=2?uc=dc(t.race.universe):0};var uc;function dc(e,a){if(t.genes.challenge&&t.genes.challenge>=2){let r=Jc(e=e||t.race.universe),s="standard"===e?.25:.15,i=t.genes.challenge>=3?.15:.1;t.genes.challenge>=4&&"standard"!==e&&(s+=.05,i-=.05),t.race.weak_mastery&&"antimatter"===e&&(s/=10,i/=10),t.race.nerfed&&(s/="antimatter"===e?5:2,i/="antimatter"===e?5:2),t.race.ooze&&(s*=1-ui.ooze.vars()[2]/100,i*=1-ui.ooze.vars()[2]/100);let c=t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):0;c>0&&(s*=1+c/100,i*=1+c/100);let o=r.aLvl*s,n=0;return"standard"!==e&&(n=r.uLvl*i),t.genes.challenge>=5&&t.race.hasOwnProperty("mastery")&&(o*=1+ui.mastery.vars()[0]*t.race.mastery/100,n*=1+ui.mastery.vars()[0]*t.race.mastery/100),a?{g:o,u:n,m:o+n}:o+n}return a?{g:0,u:0,m:0}:0}const _c=function(e){if(!pc||e){let e=0;Object.keys(t.pillars).forEach((function(a){di[a]&&t.race.species===a?e+=4:di[a]&&e++})),pc=[1+e/100,1+2*e/100]}return pc};var pc;function hc(e,a,r,s){r=r||0;let i=(s=s||{}).genes;void 0===i&&(i=ro()-1,i>4&&(i=4));let c=s.uni||t.race.universe;if("micro"===c&&(e*=.25),"antimatter"===c&&(e*=1.1),"heavy"===c&&"mad"!==a)switch(i){case 1:e*=1.1;break;case 2:e*=1.15;break;case 3:e*=1.2;break;case 4:e*=1.25;break;default:e*=1.05}switch((void 0!==s.tp?s.tp:t.race.truepath)&&(e*=1.1),i){case 1:return+(1.05*e).toFixed(r);case 2:return+(1.12*e).toFixed(r);case 3:return+(1.25*e).toFixed(r);case 4:return+(1.45*e).toFixed(r);default:return+e.toFixed(r)}}function mc(e,a){let r={plasmid:0,phage:0,dark:0,harmony:0,artifact:0,cores:0};a||(a={});let s=a.genes,i=a.uni;i=i||t.race.universe;let c=0;if(void 0===a.cit){let e=t.civic.hasOwnProperty("garrison")?t.civic.garrison.workers:0;for(let a=0;a<3;a++)t.civic.foreign[`gov${a}`].occ&&(e+=la("federation"===t.civic.govern.type?15:20));c=t.race.high_pop?Math.round(t.resource[t.race.species].amount/ui.high_pop.vars()[0])+Math.round(e/ui.high_pop.vars()[0]):t.resource[t.race.species].amount+e}else c=a.high_pop?Math.round(a.cit/ui.high_pop.vars(a.high_pop)[0])+Math.round(a.sol/ui.high_pop.vars(a.high_pop)[0]):a.cit+a.sol;let o=999,n=1e6,l=100,u=0,d=150;switch(e){case"mad":o=3,n=1e5,l=1.1,d=150,(void 0!==a.synth?a.synth:"synthetic"===di[t.race.species].type)&&(o=5,n=125e3,d=100);break;case"cataclysm":case"bioseed":o=3,n=5e4,l=1.015,u=1,d=400;break;case"ai":o=2.5,n=45e3,l=1.014,u=2,d=600;break;case"vacuum":case"bigbang":o=2.2,n=4e4,l=1.012,u=2.5,d=800;break;case"ascend":case"terraform":o=1.15,n=3e4,l=1.008,u=4,d=2e3;break;case"matrix":o=1.5,n=32e3,l=1.01,u=3.2,d=1800;break;case"retire":o=1.15,n=32e3,l=1.006,u=3.2,d=1800;break;case"eden":o=1,n=18e3,l=1.004,u=2.5,d=1800}if(d=void 0!==s?Math.floor(d*(1+(s+(a.tp?1:0))/8)):Math.floor(d*(1+(ro()-(t.race.truepath?0:1))/8)),void 0===a.plas){let s=void 0!==a.know?a.know:t.stats.know,i=Math.round(c/o);for(;s>n;)i++,s-=n,n*=l;if(t.race.cataclysm?i+=300:t.race.lone_survivor&&(i+=800),r.plasmid=hc(i,e,!1,a),!a.rawPlasmids&&r.plasmid>d){let e=r.plasmid-d;r.plasmid=d,e=Math.floor(e/(e+d)*d),r.plasmid+=e}}else r.plasmid=a.plas;if(r.phage=r.plasmid>0?hc(Math.floor(Math.log2(r.plasmid)*Math.E*u),e,!1,a):0,"bigbang"===e){let e=a.exotic,s=a.mass;void 0===e&&t.interstellar&&t.interstellar.stellar_engine&&(e=t.interstellar.stellar_engine.exotic,s=t.interstellar.stellar_engine.mass);let i=+Math.log(1+40*e).toFixed(3);i+=+(Math.log2(s-7)/2.5).toFixed(3),i=hc(i,"bigbang",3,a),r.dark=i}else if("vacuum"===e){let e=void 0!==a.mana?a.mana:t.resource.Mana.gen,s=+(Math.log2(e)/5).toFixed(3);s=hc(s,"vacuum",3,a),r.dark=s}if(["ascend","descend","terraform"].includes(e)){let c=1;if(void 0===s?(c=ro(),c>5&&(c=5)):c=s+1,"ascend"===e||"terraform"===e){switch(i){case"micro":c*=.25;break;case"heavy":c*=1.2;break;case"antimatter":c*=1.1}r.harmony=parseFloat(c.toFixed(2))}else if("descend"===e){let e="micro"===i?1:c,s=a.floor;void 0!==s?s++:s=t.portal.hasOwnProperty("spire")?t.portal.spire.count:0,[50,100].forEach((function(t){s>t&&e++})),r.artifact=e}}return"ai"===e&&(r.cores="micro"===i?2:5),r}function gc(e,a,r){let s=e.cost||{};if((s.RNA||s.DNA)&&t.genes.evolve){var i={};return Object.keys(s).forEach((function(e){"RNA"!==e&&"DNA"!==e||(i[e]=function(){return Math.round(.8*s[e](a,r))})})),i}return s=function(e,a,r){if(t.race.bloated){let t=1+ui.bloated.vars()[0]/100;var s={};return Object.keys(e).forEach((function(i){["Food","Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Alloy","Polymer","Iridium"].includes(i)?s[i]=function(){return e[i](a,r)*t}:s[i]=function(){return e[i](a,r)}})),s}return e}(s,a,r),s=function(e,a,r,s){if((s?s.truepath:t.race.truepath)&&(!a.hasOwnProperty("path")||!a.path.includes("truepath"))){var i={};return Object.keys(e).forEach((function(t){"Money"===t?i[t]=function(){return Math.round(3*e[t](r,s))}:["Structs","Knowledge","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe"].includes(t)?i[t]=function(){return e[t](r,s)}:i[t]=function(){return Math.round(2*e[t](r,s))}})),i}return e}(s,e,a,r),s=function(e,a,r){if(t.race.lone_survivor){var s={};return Object.keys(e).forEach((function(t){["Structs","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe"].includes(t)?s[t]=function(){return e[t](a,r)}:["Knowledge"].includes(t)?s[t]=function(){return Math.round(.5*e[t](a,r))}:["Money"].includes(t)?s[t]=function(){return Math.round(.22*e[t](a,r))}:["Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Quantium"].includes(t)?s[t]=function(){return Math.round(.14*e[t](a,r))}:s[t]=function(){return Math.round(.28*e[t](a,r))}})),s}return e}(s,a,r),s=function(e,a,r){if(t.race.inflation){var s={};return Object.keys(e).forEach((function(i){if("Money"===i){let c=1+t.race.inflation/75;s[i]=function(){return Math.round(e[i](a,r)*c)}}else s[i]=function(){return e[i](a,r)}})),s}return e}(s,a,r),s=function(e,a,r){if("technocracy"===t.civic.govern.type){let t=1+ae.technocracy()[1]/100;var s={};return Object.keys(e).forEach((function(i){if("Knowledge"===i){let t=1-ae.technocracy()[0]/100;s[i]=function(){return Math.round(e[i](a,r)*t)}}else s[i]="Money"===i||"Structs"===i||"Custom"===i?function(){return e[i](a,r)}:function(){return Math.round(e[i](a,r)*t)}})),s}return e}(s,a,r),s=function(e,a,r){if(t.race.flier&&(e.Stone||e.Cement)){var s={};let t=1-ui.flier.vars()[0]/100;return Object.keys(e).forEach((function(i){"Stone"!==i||e.Cement?"Cement"===i?e.Stone?s.Stone=function(){return Math.round(e.Stone(a,r)*t+1.8*e[i](a,r)*t)||0}:s.Stone=function(){return Math.round(1.75*e[i](a,r)*t)}:s[i]=function(){return e[i](a,r)}:s[i]=function(){return Math.round(e[i](a,r)*t)||0}})),s}return e}(s,a,r),s=function(e,a,r){if(t.race.kindling_kindred&&(e.Lumber||e.Plywood)){var s={};let t=1+ui.kindling_kindred.vars()[0]/100;return Object.keys(e).forEach((function(i){"Lumber"!==i&&"Plywood"!==i&&"Structs"!==i?s[i]=function(){return Math.round(e[i](a,r)*t)||0}:"Structs"===i&&(s[i]=function(){return e[i](a,r)})})),s}if(t.race.unfathomable&&t.city.captive_housing){let t=Pi("entish");if(t>0){s={};let i=1-.4*t;return Object.keys(e).forEach((function(t){s[t]="Lumber"===t&&"Plywood"===t?function(){return Math.round(e[t](a,r)*i)||0}:function(){return e[t](a,r)}})),s}}return e}(s,a,r),s=function(e,a,r){if(t.race.smoldering){let s={};return Object.keys(e).forEach((function(t){if("Lumber"===t||"Plywood"===t){let i="Plywood"===t?2:1;s.Chrysotile=function(){return Math.round(e[t](a,r)*i)||0}}else["HellArmy","Structs","Chrysotile","Knowledge","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe","Mana","Energy"].includes(t)?s[t]=function(){return e[t](a,r)}:s[t]=function(){return Math.round(.9*e[t](a,r))}})),!s.hasOwnProperty("Chrysotile")&&e.hasOwnProperty("Money")&&t.tech.primitive&&t.tech.primitive>=3&&(s.Chrysotile=function(){let t=e.Money(a,r)||0;return t>0?Math.round(t/50):0}),s}return e}(s,a,r),s=function(e,a,r){let s=N("pragmatist",1),i=Pi("gnome");if((t.race.smart||t.race.dumb||s||i>0)&&e.Knowledge){var c={};return Object.keys(e).forEach((function(o){c[o]="Knowledge"===o?function(){let c=e[o](a,r);return t.race.smart&&(c*=1-ui.smart.vars()[0]/100),i>0&&(c*=1-ui.smart.vars(1)[0]/100*i),t.race.dumb&&(c*=1+ui.dumb.vars()[0]/100),s&&(c*=1+s/100),Math.round(c)}:function(){return e[o](a,r)}})),c}return e}(s,a,r),s=function(e,a,r){if(e.Cement&&t.tech.cement&&t.tech.cement>=2){let i=t.tech.cement>=3?.8:.9;var s={};return Object.keys(e).forEach((function(t){s[t]="Cement"===t?function(){return Math.round(e[t](a,r)*i)||0}:function(){return e[t](a,r)}})),s}return e}(s,a,r),s=function(e,t,a){let r=N("extravagant",0);if(r){var s={};return Object.keys(e).forEach((function(i){if("Money"===i){let c=1+r/100;s[i]=function(){return Math.round(e[i](t,a)*c)}}else s[i]=function(){return e[i](t,a)}})),s}return e}(s,a,r),s=function(e,a,r){if(t.race.heavy){var s={};return Object.keys(e).forEach((function(t){s[t]="Stone"===t||"Cement"===t||"Wrought_Iron"===t?function(){return Math.round(e[t](a,r)*(1+ui.heavy.vars()[1]/100))}:function(){return e[t](a,r)}})),s}return e}(s,a,r),function(e,a,r){let s=Pi("pterodacti");if((t.race.hollow_bones||s>0)&&(e.Plywood||e.Brick||e.Wrought_Iron||e.Sheet_Metal||e.Mythril||e.Aerogel||e.Nanoweave||e.Scarletite||e.Quantium)){var i={};return Object.keys(e).forEach((function(c){i[c]="Plywood"===c||"Brick"===c||"Wrought_Iron"===c||"Sheet_Metal"===c||"Mythril"===c||"Aerogel"===c||"Nanoweave"===c||"Scarletite"===c||"Quantium"===c?function(){let i=e[c](a,r);return t.race.hollow_bones&&(i*=1-ui.hollow_bones.vars()[0]/100),s>0&&(i*=1-ui.hollow_bones.vars(3)[0]/100*s),Math.round(i)}:function(){return e[c](a,r)}})),i}return e}(s,a,r)}function fc(e){return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}function vc(e){switch(e){case"star":return'';case"atom":return'';case"heavy":return'';case"evil":return'';case"micro":return'';case"magic":return'';case"rocket":return'';case"heart":return'';case"clover":return'';case"candy":return'';case"ghost":return'';case"turkey":return'';case"present":return'';case"nuclear":return'';case"zombie":return'';case"fire":return'';case"mask":return'';case"skull":return'';case"taijitu":return'';case"trash":return'';case"martini":return'';case"lightbulb":return'';case"bunny":return'';case"egg":return'';case"turtle":return'';case"candycorn":return'';case"banana":return'\n ';case"sun":return'';case"firework":return'';case"floppy":return'';case"slime":return'';case"lightning":return'\n \n '}}function yc(e){switch(e){case"star":return"0 0 640 640";case"atom":return"0 0 100 88.379";case"heavy":case"mask":return"0 0 24 24";case"evil":return"0 0 240 240";case"micro":return"0 0 276 276";case"magic":return"0 0 2666 2666";case"rocket":return"0 0 165 173";case"sun":return"0 0 48 48";case"heart":return"0 0 20 16";case"clover":return"0 0 660.51 780.1";case"candy":return"0 0 200 200";case"ghost":return"0 0 399 432.23";case"turkey":return"0 0 250 300";case"present":return"0 0 410.98 434.75";case"nuclear":return"0 0 101.22 101.22";case"zombie":return"0 0 175 304";case"fire":return"0 0 615.18 879.36";case"skull":return"0 0 256.27 300.86";case"taijitu":return"0 -10 256 256 ";case"pizza":return"0 0 217.444 144.397";case"trash":case"martini":return"0 0 15 15";case"party":return"0 0 528.69 983.1";case"lightbulb":return"0 0 100 156";case"bunny":case"ant":return"0 0 128 128";case"egg":return"0 0 273.61 295.02";case"turtle":return"20 40 270 50";case"candycorn":return"0 0 325 449.98";case"banana":return"0 0 113.38582 111.81719";case"firework":return"0 10 12 35";case"floppy":return"0 0 60 60";case"slime":return"0 0 552 495";case"lightning":return"0 0 16 16"}}function bc(e,a){if("feat"===a)switch(e){case"steelem":return"nuclear";case"the_misery":return"zombie";case"ill_advised":return"fire";case"garbage_pie":return"trash";case"demon_slayer":return"skull";case"equilibrium":return"taijitu";case"utopia":return"martini";case"energetic":return"lightbulb";case"finish_line":return"turtle";case"banana":return"banana";case"digital_ascension":return"floppy";case"slime_lord":return"slime";case"annihilation":return"lightning";case"friday":return"mask";case"valentine":return"heart";case"leprechaun":return"clover";case"easter":return"bunny";case"launch_day":return"rocket";case"solstice":return"sun";case"firework":return"firework";case"egghunt":return"egg";case"halloween":return"ghost";case"trickortreat":return"candy";case"thanksgiving":return"turkey";case"xmas":return"present";default:return"star"}return t.settings.icon}function wc(e,t,a,r,s){let i="";return r&&(i=`id="${r}" `),`${vc(e)}`}function $c(e,a){let r=Ec();const s=new Date;return r.active&&!t.special.egg[s.getFullYear()][`egg${e}`]?wc("egg",a||16,2,`egg${e}`,'role="button" aria-label="Egg" '):""}function xc(e){$(`#egg${e}`).click((function(){let a=(new Date).getFullYear();t.special.egg[a][`egg${e}`]||(t.special.egg[a][`egg${e}`]=!0,e<=12?"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=9,t.stats.antiplasmid+=9,Di(F("city_egg_msg",[9,F("resource_AntiPlasmid_plural_name")]),"success",!1,["events"])):(t.prestige.Plasmid.count+=9,t.stats.plasmid+=9,Di(F("city_egg_msg",[9,F("resource_Plasmid_plural_name")]),"success",!1,["events"])):(t.prestige.Phage.count+=4,t.stats.phage+=4,Di(F("city_egg_msg",[4,F("resource_Phage_name")]),"success",!1,["events"])),$(`#egg${e}`).remove(),$(".popper").hide())}))}function kc(e,a,r){let s=Ic();const i=(new Date).getFullYear();let c=r?"trick":"treat";return s.active&&!t.special.trick[i][`${c}${e}`]?wc(r?"ghost":"candycorn",a||16,2,`${c}${e}`,`role="button" aria-label="${r?"Ghost":"Candy Corn"}" `):""}function qc(e,a){const r=(new Date).getFullYear();let s=a?"trick":"treat";$(`#${s}${e}`).click((function(){t.special.trick[r][`${s}${e}`]||(t.special.trick[r][`${s}${e}`]=!0,a?(t.prestige.Phage.count+=2,t.stats.phage+=2,Di(F("city_ghost_msg",[2,F("resource_Phage_name")]),"success",!1,["events"])):"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=13,t.stats.antiplasmid+=13,Di(F("city_trick_msg",[13,F("resource_AntiPlasmid_plural_name")]),"success",!1,["events"])):(t.prestige.Plasmid.count+=13,t.stats.plasmid+=13,Di(F("city_trick_msg",[13,F("resource_Plasmid_plural_name")]),"success",!1,["events"])),$(`#${s}${e}`).remove(),setTimeout((function(){1===e&&a&&$(".popper").hide()}),250))}))}function Mc(e,a,r,s,i,c){return t.stats.achieve[e]&&(i?t.stats.achieve[e][c]-1:t.stats.achieve[e][c])>0?`

        ${vc(r)}

        `:""}function Pc(e,a,r,s,i){a||(a=10),r||(r=bc(e,"achievement"));let c="";if(i)switch(i){case"standard":c+=Mc(e,a,r,F(t.settings.icon),s,"l");break;case"antimatter":c+=Mc(e,a,"atom",F("universe_antimatter"),s,"a");break;case"evil":c+=Mc(e,a,"evil",F("universe_evil"),s,"e");break;case"heavy":c+=Mc(e,a,"heavy",F("universe_heavy"),s,"h");break;case"micro":c+=Mc(e,a,"micro",F("universe_micro"),s,"m");break;case"magic":c+=Mc(e,a,"magic",F("universe_magic"),s,"mg")}else c+=Mc(e,a,r,F(t.settings.icon),s,"l"),c+=Mc(e,a,"atom",F("universe_antimatter"),s,"a"),c+=Mc(e,a,"evil",F("universe_evil"),s,"e"),c+=Mc(e,a,"heavy",F("universe_heavy"),s,"h"),c+=Mc(e,a,"micro",F("universe_micro"),s,"m"),c+=Mc(e,a,"magic",F("universe_magic"),s,"mg");return c}function Oc(e,t){return(t=t||{})[e]?t[e]:e<=1?1:t[e]=Oc(e-1,t)+Oc(e-2,t)}function Cc(e){var t=Object.keys(e);return t[t.length*Math.random()<<0]}function jc(e){switch(e){case 1:return F("basic");case 2:return F("plain");case 3:return F("bronze");case 4:return F("silver");case 5:return F("gold");default:return""}}function Sc(e,a){let r=0;if(a)Object.keys(a.ascended).forEach((function(e){r+=a.ascended[e]}));else if(t.stats.achieve.ascended)for(let e=0;e=1&&(s+=t.stats.achieve.technophobe.l);let i=0;for(let t=0;t=0&&(i>s&&(a-=s-i),i++),r-=a}return r}function Fc(){t.stats.reset++,t.stats.tdays+=t.stats.days,t.stats.days=0,t.stats.tknow+=t.stats.know,t.stats.know=0,t.stats.tstarved+=t.stats.starved,t.stats.starved=0,t.stats.tdied+=t.stats.died,t.stats.died=0,t.stats.tsac+=t.stats.sac,t.stats.sac=0,t.stats.tcattle+=t.stats.cattle,t.stats.cattle=0,t.stats.tmurders+=t.stats.murders,t.stats.murders=0,t.stats.tpsykill+=t.stats.psykill,t.stats.psykill=0}function zc(e){if(null===e||"object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());if(Array.isArray(e)){var t=[];return e.forEach((function(e){t.push(zc(e))})),t}let a=new e.constructor;for(var r in e)e.hasOwnProperty(r)&&(a[r]=zc(e[r]));return a}function Ac(e,a,r){switch(e){case"reverse":{let e=a.toLowerCase().split("").reverse().join("");return e.charAt(0).toUpperCase()+e.slice(1)}case"name":return Tc("fool",2021)?Ac("reverse",di[t.race.species].name):di[t.race.species].name;case"curve":return 1-(1-a)**(r||1.5)}return!1}function Tc(e,a){switch(e){case"easter":return Ec();case"halloween":return Ic();case"fool":{const e=new Date;return!(t.settings.boring||3!==e.getMonth()||1!==e.getDate()||a&&e.getFullYear()!==a)}case"launch_day":{const e=new Date;return!t.settings.boring&&4===e.getMonth()&&6===e.getDate()}case"summer":{const e=new Date;return!t.settings.boring&&5===e.getMonth()&&[20,21,22].includes(e.getDate())?(t.city.hasOwnProperty("foundry")&&!t.city.foundry.hasOwnProperty("Thermite")&&(t.city.foundry.Thermite=0),t.resource.hasOwnProperty("Thermite")||(t.resource.Thermite={name:F("resource_Thermite_name"),display:!1,value:0,amount:0,crates:0,diff:0,delta:0,max:-1,rate:0}),!0):(t.city.hasOwnProperty("foundry")&&t.city.foundry.hasOwnProperty("Thermite")&&(t.city.foundry.crafting-=t.city.foundry.Thermite,t.civic.craftsman.workers-=t.city.foundry.Thermite,t.civic[t.civic.d_job].workers+=t.city.foundry.Thermite,delete t.city.foundry.Thermite),!1)}case"firework":{const e=new Date;if(!t.settings.boring&&6===e.getMonth()&&[1,2,3,4].includes(e.getDate())){let e=t.race.cataclysm||t.race.orbit_decayed?"space":"city";return t[e].hasOwnProperty("firework")||(t[e].firework={count:0,on:0}),!0}return(t.city.hasOwnProperty("firework")||t.space.hasOwnProperty("firework"))&&(delete t.city.firework,delete t.space.firework),!1}}return!1}function Ec(){const e=new Date;let a=e.getFullYear();t.special.egg.hasOwnProperty(a)||(t.special.egg[a]={egg1:!1,egg2:!1,egg3:!1,egg4:!1,egg5:!1,egg6:!1,egg7:!1,egg8:!1,egg9:!1,egg10:!1,egg11:!1,egg12:!1}),t.special.egg.hasOwnProperty(a)&&!t.special.egg[a].hasOwnProperty("egg13")&&(t.special.egg[a].egg13=!1,t.special.egg[a].egg14=!1,t.special.egg[a].egg15=!1),t.special.egg.hasOwnProperty(a)&&!t.special.egg[a].hasOwnProperty("egg16")&&(t.special.egg[a].egg16=!1,t.special.egg[a].egg17=!1,t.special.egg[a].egg18=!1);let r=Math.floor,s=a%19,i=r(a/100),c=(i-r(i/4)-r((8*i+13)/25)+19*s+15)%30,o=c-r(c/28)*(1-r(29/(c+1))*r((21-s)/11)),n=o-(a+r(a/4)+o+2-i+r(i/4))%7,l=3+r((n+40)/44),u=n+28-31*r(l/4),d={date:[l-1,u],active:!1,endDate:[l-1,u],hint:!1,hintDate:[l-1,u],solve:!1,solveDate:[l-1,u]};return t.settings.boring||(d.endDate[1]+=10,(2===d.endDate[0]&&d.endDate[1]>31||3===d.endDate[0]&&d.endDate[1]>30)&&(d.endDate[1]-=2===d.endDate[0]?31:30,d.endDate[0]++),d.hintDate[1]+=1,(2===d.hintDate[0]&&d.hintDate[1]>31||3===d.hintDate[0]&&d.hintDate[1]>30)&&(d.hintDate[1]-=2===d.hintDate[0]?31:30,d.hintDate[0]++),d.solveDate[1]+=3,(2===d.solveDate[0]&&d.solveDate[1]>31||3===d.solveDate[0]&&d.solveDate[1]>30)&&(d.solveDate[1]-=2===d.solveDate[0]?31:30,d.solveDate[0]++),e.getMonth()>=d.date[0]&&e.getDate()>=d.date[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.active=!0,e.getMonth()>=d.hintDate[0]&&e.getDate()>=d.hintDate[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.hint=!0),e.getMonth()>=d.solveDate[0]&&e.getDate()>=d.solveDate[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.solve=!0))),d}function Ic(){const e=new Date;let a=e.getFullYear();t.special.trick.hasOwnProperty(a)||(t.special.trick[a]={trick1:!1,trick2:!1,trick3:!1,trick4:!1,trick5:!1,trick6:!1,trick7:!1,treat1:!1,treat2:!1,treat3:!1,treat4:!1,treat5:!1,treat6:!1,treat7:!1});let r={date:[9,28],active:!1,endDate:[10,4],hint:!1,hintDate:[9,29],solve:!1,solveDate:[9,31]};if(t.settings.boring)return r;let s=new Date(`${r.date[0]+1}/${r.date[1]}/${a}`),i=new Date(`${r.endDate[0]+1}/${r.endDate[1]}/${a}`);return e>=s&&e<=i&&(r.active=!0,e>=new Date(`${r.hintDate[0]+1}/${r.hintDate[1]}/${a}`)&&e<=i&&(r.hint=!0),e>=new Date(`${r.solveDate[0]+1}/${r.solveDate[1]}/${a}`)&&e<=i&&(r.solve=!0)),r}function Kc(){return t.race.magnificent&&t.city.hasOwnProperty("shrine")&&t.city.shrine.count>0}function Lc(e){let a={mult:1,add:0};if(Kc())switch(e){case"metal":a.mult+=+t.city.shrine.metal/100*ui.magnificent.vars()[3];break;case"tax":a.mult+=+t.city.shrine.tax/100*ui.magnificent.vars()[2];break;case"know":a.add+=+t.city.shrine.know*ui.magnificent.vars()[0],a.mult+=+t.city.shrine.know*ui.magnificent.vars()[1]/100;break;case"morale":a.add+=t.city.shrine.morale*ui.magnificent.vars()[4]}return a}const Nc={promiscuous:!1,revive:!1,fast_growth:!1,spores:!1,terrifying:!1,fibroblast:!0,hivemind:!0,imitation:!0,elusive:!0,chameleon:!0,blood_thirst:!0,selenophobia:!0,hooved:!0,anthropophagite:!0,unfathomable:!1,darkness:!1,living_tool:!1};function Dc(e,a){let r=ui[e].hasOwnProperty("vars")?ui[e].vars(a):[];return Nc.hasOwnProperty(e)&&("fibroblast"===e?r=[5*r[0]]:"hivemind"===e&&t.race.high_pop?r=[r[0]*ui.high_pop.vars()[0]]:"imitation"===e?r.push(di[t.race.srace||"protoplasm"].name):"elusive"===e?r=[Math.round(100*(1/30/(1/(30+r[0]))-1))]:"chameleon"===e?r=[r[0],Math.round(100*(1/30/(1/(30+r[1]))-1))]:"blood_thirst"===e?r=[Math.ceil(Math.log2(r[0]))]:"selenophobia"===e?r=[14-r[0],r[0]]:"hooved"===e?r.unshift(Bc()):"anthropophagite"===e?r=[1e4*r[0]]:Nc[e]||(r=[])),r}function Bc(e){return t.race.sludge?e?"craft":F("resource_Beaker_name"):"cath"===t.race.species?e?"craft":F("resource_Box_name"):"wolven"===t.race.species?e?"craft":F("resource_ChewToy_name"):"dracnid"===t.race.species?e?"craft":F("resource_Hoard_name"):"seraph"===t.race.species?e?"forge":F("resource_Halo_name"):"cyclops"===t.race.species?e?"craft":F("resource_Monocle_name"):"kobold"===t.race.species?e?"craft":F("resource_Candle_name"):"tuskin"===t.race.species?e?"craft":F("resource_Goggles_name"):"sharkin"===t.race.species?e?"craft":F("resource_ToothSharpener_name"):"humanoid"===di[t.race.species].type?e?"craft":F("resource_Sandals_name"):"avian"===di[t.race.species].type?e?"craft":F("resource_Perch_name"):"plant"===di[t.race.species].type?e?"craft":F("resource_Planter_name"):"fungi"===di[t.race.species].type?e?"craft":F("resource_DampCloth_name"):"reptilian"===di[t.race.species].type?e?"craft":F("resource_HeatRock_name"):"fey"===di[t.race.species].type?e?"craft":F("resource_PixieDust_name"):"synthetic"===di[t.race.species].type?e?"craft":F("resource_Battery_name"):e?"forge":F("resource_Horseshoe_name")}const Gc={infiltrator:[F("wiki_trait_effect_infiltrator_ex1"),F("wiki_trait_effect_infiltrator_ex2",[[`${F("tech_steel")}`,`${F("tech_electricity")}`,`${F("tech_electronics")}`,`${F("tech_fission")}`,`${F("tech_rocketry")}`,`${F("tech_artificial_intelligence")}`,`${F("tech_quantum_computing")}`,`${F("tech_virtual_reality")}`,`${F("tech_shields")}`,`${F("tech_ai_core")}`,`${F("tech_graphene_processing")}`,`${F("tech_nanoweave")}`,`${F("tech_orichalcum_analysis")}`,`${F("tech_infernium_fuel")}`].join(", ")])],heavy:[F("wiki_trait_effect_heavy_ex1",[Rc("Stone"),Rc("Cement"),Rc("Wrought_Iron")])],sniper:[F("wiki_trait_effect_sniper_ex1")],hooved:[F("wiki_trait_effect_hooved_ex1",[Bc(!1)]),F("wiki_trait_effect_hooved_ex2",[`${t.resource.hasOwnProperty("Lumber")?t.resource.Lumber.name:F("resource_Lumber_name")}`,`${t.resource.hasOwnProperty("Copper")?t.resource.Copper.name:F("resource_Copper_name")}`,`${t.resource.hasOwnProperty("Iron")?t.resource.Iron.name:F("resource_Iron_name")}`,`${t.resource.hasOwnProperty("Steel")?t.resource.Steel.name:F("resource_Steel_name")}`,`${t.resource.hasOwnProperty("Adamantite")?t.resource.Adamantite.name:F("resource_Adamantite_name")}`,`${t.resource.hasOwnProperty("Orichalcum")?t.resource.Orichalcum.name:F("resource_Orichalcum_name")}`,12,75,150,500,5e3]),F("wiki_trait_effect_hooved_ex3"),F("wiki_trait_effect_hooved_ex4",['5',Bc(!1)]),F("wiki_trait_effect_hooved_ex5",[`${t.resource.hasOwnProperty("Lumber")?t.resource.Lumber.name:F("resource_Lumber_name")}`,`${t.resource.hasOwnProperty("Copper")?t.resource.Copper.name:F("resource_Copper_name")}`])],instinct:[F("wiki_trait_effect_instinct_ex1",[6.67,F("galaxy_chthonian"),10])],logical:[F("wiki_trait_effect_logical_ex1",[t.tech.hasOwnProperty("science")?t.tech.science:0,t.tech.hasOwnProperty("high_tech")?t.tech.high_tech:0])],high_pop:[F("wiki_trait_effect_high_pop_ex1")],flier:[F("wiki_trait_effect_flier_ex1")],unfathomable:[F("wiki_trait_effect_unfathomable_ex1"),F("wiki_trait_effect_unfathomable_ex2")]};function Rc(e){return`${t.hasOwnProperty("resource")&&t.resource.hasOwnProperty(e)?t.resource[e].name:F(`resource_${e}_name`)}`}function Hc(e,a,r){let s=r.fanatic||!1,i=r.tpage||!1,c=r.trank||!1,o=r.wiki||!1,n="",l=Oi("name",a),u=Oi("desc",a);i&&["genus","major"].includes(ui[a].type)&&(n=`«${F("wiki_trait_rank")} {{ rank }}»`),o&&e.append(`

        ${l}

        ${n}
        `),o&&(i&&ui[a].hasOwnProperty("val")?e.append(`
        ${F(`wiki_trait_${ui[a].type}`)}${F("wiki_trait_value",[ui[a].val])}
        `):e.append(`
        ${F(`wiki_trait_${ui[a].type}`)}
        `)),s&&o&&e.append(`
        ${F("wiki_trait_fanaticism",[s])}
        `),e.append(`
        ${u}
        `);let d="warning";if(ui[a].hasOwnProperty("val")&&(d=ui[a].val>=0?"success":"danger"),i&&["genus","major"].includes(ui[a].type)?e.append(`
        `):(o||t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0)&&e.append(`
        ${F(`wiki_trait_effect_${a}`,Dc(a,c))}
        `),Gc[a]&&o&&Gc[a].forEach((function(t){e.append(`
        ${t}
        `)})),i&&["genus","major"].includes(ui[a].type)){let e={rank:t.race[a]||1};sc({el:`#${ui[a].type}_${a}`,data:e,methods:{getTraitDesc:e=>F(`wiki_trait_effect_${a}`,Dc(a,e)),up(){switch(e.rank){case.25:e.rank=.5;break;case.5:e.rank=1;break;case 1:e.rank=2;break;case 2:case 3:e.rank=3}},down(){switch(e.rank){case.25:case.5:e.rank=.25;break;case 1:e.rank=.5;break;case 2:e.rank=1;break;case 3:e.rank=2}}}})}}const Uc={misc:["apocalypse","ascended","dreaded","anarchist","second_evolution","blackhole","warmonger","red_tactics","pacifist","neutralized","paradise","scrooge","madagascar_tree","godwin","laser_shark","infested","mass_starvation","colonist","world_domination","illuminati","syndicate","cult_of_personality","doomed","pandemonium","blood_war","landfill","seeder","miners_dream","shaken","blacken_the_sun","trade","resonance","enlightenment","gladiator","corrupted","red_dead"],species:["mass_extinction","extinct_human","extinct_elven","extinct_orc","extinct_cath","extinct_wolven","extinct_vulpine","extinct_centaur","extinct_rhinotaur","extinct_capybara","extinct_kobold","extinct_goblin","extinct_gnome","extinct_ogre","extinct_cyclops","extinct_troll","extinct_tortoisan","extinct_gecko","extinct_slitheryn","extinct_arraak","extinct_pterodacti","extinct_dracnid","extinct_entish","extinct_cacti","extinct_pinguicula","extinct_sporgar","extinct_shroomi","extinct_moldling","extinct_mantis","extinct_scorpid","extinct_antid","extinct_sharkin","extinct_octigoran","extinct_dryad","extinct_satyr","extinct_phoenix","extinct_salamander","extinct_yeti","extinct_wendigo","extinct_tuskin","extinct_kamel","extinct_balorg","extinct_imp","extinct_seraph","extinct_unicorn","extinct_synth","extinct_nano","extinct_ghast","extinct_shoggoth","extinct_junker","extinct_sludge","extinct_custom"],genus:["creator","genus_humanoid","genus_carnivore","genus_herbivore","genus_small","genus_giant","genus_reptilian","genus_avian","genus_insectoid","genus_plant","genus_fungi","genus_aquatic","genus_fey","genus_heat","genus_polar","genus_sand","genus_demonic","genus_angelic","genus_synthetic","genus_eldritch"],planet:["explorer","biome_grassland","biome_oceanic","biome_forest","biome_desert","biome_volcanic","biome_tundra","biome_savanna","biome_swamp","biome_ashland","biome_taiga","biome_hellscape","biome_eden","atmo_toxic","atmo_mellow","atmo_rage","atmo_stormy","atmo_ozone","atmo_magnetic","atmo_trashed","atmo_elliptical","atmo_flare","atmo_dense","atmo_unstable","atmo_permafrost","atmo_retrograde"],universe:["vigilante","squished","double_density","cross","macro","marble","heavyweight","whitehole","heavy","canceled","eviltwin","microbang","pw_apocalypse","fullmetal","pass","soul_sponge","nightmare"],challenge:["joyless","steelen","dissipated","technophobe","wheelbarrow","iron_will","failed_history","banana","pathfinder","ashanddust","exodus","obsolete","bluepill","retired","gross","lamentis","overlord","adam_eve"]},Wc={colonist:[Ac("name")]},Qc={trade:[750,50]},Zc={};Object.keys(Uc).forEach((function(e){Uc[e].forEach((t=>Zc[t]={name:F(`achieve_${t}_name`),desc:Qc[t]?F(`achieve_${t}_desc`,Qc[t]):F(`achieve_${t}_desc`),flair:Wc[t]?F(`achieve_${t}_flair`,Wc[t]):F(`achieve_${t}_flair`),type:e}))}));const Vc={utopia:{name:F("feat_utopia_name"),desc:F("feat_utopia_desc"),flair:F("feat_utopia_flair")},take_no_advice:{name:F("feat_take_no_advice_name"),desc:F("feat_take_no_advice_desc"),flair:F("feat_take_no_advice_flair")},ill_advised:{name:F("feat_ill_advised_name"),desc:F("feat_ill_advised_desc"),flair:F("feat_ill_advised_flair")},organ_harvester:{name:F("feat_organ_harvester_name"),desc:F("feat_organ_harvester_desc"),flair:F("feat_organ_harvester_flair")},the_misery:{name:F("feat_the_misery_name"),desc:F("feat_the_misery_desc"),flair:F("feat_the_misery_flair")},energetic:{name:F("feat_energetic_name"),desc:F("feat_energetic_desc"),flair:F("feat_energetic_flair")},garbage_pie:{name:F("feat_garbage_pie_name"),desc:F("feat_garbage_pie_desc"),flair:F("feat_garbage_pie_flair")},finish_line:{name:F("feat_finish_line_name"),desc:F("feat_finish_line_desc"),flair:F("feat_finish_line_flair")},blank_slate:{name:F("feat_blank_slate_name"),desc:F("feat_blank_slate_desc"),flair:F("feat_blank_slate_flair")},supermassive:{name:F("feat_supermassive_name"),desc:F("feat_supermassive_desc"),flair:F("feat_supermassive_flair")},steelem:{name:F("feat_steelem_name"),desc:F("feat_steelem_desc"),flair:F("feat_steelem_flair")},banana:{name:F("feat_banana_name"),desc:F("feat_banana_desc",[500,500]),flair:F("feat_banana_flair")},rocky_road:{name:F("feat_rocky_road_name"),desc:F("feat_rocky_road_desc"),flair:F("feat_rocky_road_flair")},demon_slayer:{name:F("feat_demon_slayer_name"),desc:F("feat_demon_slayer_desc"),flair:F("feat_demon_slayer_flair")},equilibrium:{name:F("feat_equilibrium_name"),desc:F("feat_equilibrium_desc"),flair:F("feat_equilibrium_flair")},digital_ascension:{name:F("feat_digital_ascension_name"),desc:F("feat_digital_ascension_desc"),flair:F("feat_digital_ascension_flair")},novice:{name:F("feat_novice_name"),desc:F("feat_achievement_hunter_desc",[10]),flair:F("feat_novice_flair")},journeyman:{name:F("feat_journeyman_name"),desc:F("feat_achievement_hunter_desc",[25]),flair:F("feat_journeyman_flair")},adept:{name:F("feat_adept_name"),desc:F("feat_achievement_hunter_desc",[50]),flair:F("feat_adept_flair")},master:{name:F("feat_master_name"),desc:F("feat_achievement_hunter_desc",[75]),flair:F("feat_master_flair")},grandmaster:{name:F("feat_grandmaster_name"),desc:F("feat_achievement_hunter_desc",[100]),flair:F("feat_grandmaster_flair")},nephilim:{name:F("feat_nephilim_name"),desc:F("feat_nephilim_desc"),flair:F("feat_nephilim_flair")},twisted:{name:F("feat_twisted_name"),desc:F("feat_twisted_desc"),flair:F("feat_twisted_flair")},slime_lord:{name:F("feat_slime_lord_name"),desc:F("feat_slime_lord_desc"),flair:F("feat_slime_lord_flair")},annihilation:{name:F("feat_annihilation_name"),desc:F("feat_annihilation_desc"),flair:F("feat_annihilation_flair")},friday:{name:F("feat_friday_name"),desc:F("feat_friday_desc"),flair:F("feat_friday_flair")},valentine:{name:F("feat_love_name"),desc:F("feat_love_desc"),flair:F("feat_love_flair")},leprechaun:{name:F("feat_leprechaun_name"),desc:F("feat_leprechaun_desc"),flair:F("feat_leprechaun_flair")},easter:{name:F("feat_easter_name"),desc:F("feat_easter_desc"),flair:F("feat_easter_flair")},egghunt:{name:F("feat_egghunt_name"),desc:F("feat_egghunt_desc"),flair:F("feat_egghunt_flair")},launch_day:{name:F("feat_launch_day_name"),desc:F("feat_launch_day_desc"),flair:F("feat_launch_day_flair")},solstice:{name:F("feat_solstice_name"),desc:F("feat_solstice_desc"),flair:F("feat_solstice_flair")},firework:{name:F("feat_firework_name"),desc:F("feat_firework_desc"),flair:F("feat_firework_flair")},halloween:{name:F("feat_boo_name"),desc:F("feat_boo_desc"),flair:F("feat_boo_flair")},trickortreat:{name:F("feat_trickortreat_name"),desc:F("feat_trickortreat_desc"),flair:F("feat_trickortreat_flair")},thanksgiving:{name:F("feat_gobble_gobble_name"),desc:F("feat_gobble_gobble_desc"),flair:F("feat_gobble_gobble_flair")},xmas:{name:F("feat_xmas_name"),desc:F("feat_xmas_desc"),flair:F("feat_xmas_flair")},fool:{name:F("feat_fool_name"),desc:F("feat_fool_desc"),flair:F("feat_fool_flair")}};{let e=Jc();e.aLvl,e.uLvl}function Jc(e){let a=Yc(e=e||t.race.universe),r=0,s=0;return Object.keys(Zc).forEach((function(e){t.stats.achieve[e]&&(r+=t.stats.achieve[e].l>5?5:t.stats.achieve[e].l,t.stats.achieve[e][a]&&(s+=t.stats.achieve[e][a]>5?5:t.stats.achieve[e][a]))})),{aLvl:r,uLvl:s}}function Yc(e){switch(e=e||t.race.universe){case"evil":return"e";case"antimatter":return"a";case"heavy":return"h";case"micro":return"m";case"magic":return"mg";default:return"l"}}function Xc(e,a,r,s){if("micro"!==t.race.universe&&!0===a)return!1;t.settings.msgFilters.achievements.unlocked||(t.settings.msgFilters.achievements.unlocked=!0,t.settings.msgFilters.achievements.vis=!0);let i=ro(),c=!1,o=!1;(void 0===r||r>i)&&(r=i);let n=!0;if(void 0===t.stats.achieve[e]&&(t.stats.achieve[e]={l:0},n=!1),("micro"===t.race.universe&&!0===a||"micro"!==t.race.universe&&!0!==a)&&t.stats.achieve[e]&&t.stats.achieve[e].ls)&&(r=s),!t.stats.feat[e]||t.stats.feat[e]&&t.stats.feat[e]5?5:t.stats.achieve[e].l,t.stats.achieve[e][o]&&(c+=t.stats.achieve[e][o]>5?5:t.stats.achieve[e][o]);let s=Pc(e,16,l,n);n&&t.stats.achieve[e].l>1||!n?a.append($(`
        ${Zc[e].name}${Zc[e].desc}${s}
        `)):n&&1===t.stats.achieve[e].l&&r--}})),n&&!t.stats.feat.fool){let e=$(`
        ${Vc.fool.name}${F("feat_fool_spoof")}
        `);a.append(e)}else Object.keys(Vc).forEach((function(e){let r=bc(e,"feat");if(t.stats.feat[e]){let s=t.stats.feat[e]>1?`

        ${vc(r)}

        `:"";if("easter"===e){let e=$c(4,14);e.length>0&&(s=e)}a.append($(`
        ${Vc[e].name}${Vc[e].desc}${s}
        `))}}));let l=kc(5,12,!1);a.prepend(`
        ${F("achieve_draw_achieve_earned",[r,s])}${l}
        `),sc({el:"#achievePanel",methods:{flair:e=>Zc[e].flair,feat:e=>Vc[e].flair}}),n&&!t.stats.feat.fool&&$("#thefool").on("mouseover",(function(){"micro"===t.race.universe?eo("fool",!0):eo("fool"),to()}))}function ao(){let e=ro();$("#topBar span.flair")&&rc($("#topBar span.flair"),!0);let a=$c(1,14);if(a.length>0&&$("#topBar .planet").after($(a)),e>1&&0===$("#topBar .planet .flair").length){if(0===a.length){let t=bc("topbar","challenge");$("#topBar .planet").after(`${vc(t)}`)}let r="";t.race.no_plasmid&&(r+=`
        ${F("evo_challenge_plasmid")}
        `),t.race.weak_mastery&&(r+=`
        ${F("evo_challenge_mastery")}
        `),t.race.no_trade&&(r+=`
        ${F("evo_challenge_trade")}
        `),t.race.no_craft&&(r+=`
        ${F("evo_challenge_craft")}
        `),t.race.no_crispr&&(r+=`
        ${F("evo_challenge_crispr")}
        `),t.race.nerfed&&(r+=`
        ${F("evo_challenge_nerfed")}
        `),t.race.badgenes&&(r+=`
        ${F("evo_challenge_badgenes")}
        `),r.length>0&&$("#topBar .planetWrap .flair").append($(`
        Active Challenge Genes
        ${r}
        `)),Ti("topbarPlanet",(function(e){let t=$('
        ');e.popper.append(t),t.append($(r))}),{elm:"#topBar .planetWrap .flair",classes:"has-background-light has-text-dark"})}}function ro(){let e=1;return t.race.no_plasmid&&e++,t.race.no_trade&&e++,t.race.no_craft&&e++,t.race.no_crispr&&e++,t.race.weak_mastery&&e++,t.race.nerfed&&e++,t.race.badgenes&&e++,e>5&&(e=5),e}function so(){let e=ro();for(let a=e;a>=0;a--)io("extinct_","mass_extinction",25,a),"evil"===t.race.universe&&co("extinct_","vigilante",12,a),io("genus_","creator",9,a),io("biome_","explorer",6,a),"heavy"===t.race.universe&&co("genus_","heavyweight",8,a);if(t.tech.supercollider&&t.tech.supercollider>=99&&Xc("blackhole"),t.stats.starved>=100&&Xc("mass_starvation"),Math.round(Math.log2(t.civic.garrison.protest+t.civic.garrison.fatigue))>=8&&Xc("warmonger"),t.stats.died>=250&&Xc("red_tactics"),t.interstellar.stellar_engine&&t.interstellar.stellar_engine.mass>=12&&Xc("landfill"),t.interstellar.stellar_engine&&t.interstellar.stellar_engine.mass>=100&&eo("supermassive"),t.tech.piracy&&t.tech.chthonian&&t.tech.chthonian>=2&&t.galaxy&&1===Et("gxy_stargate")&&1===Et("gxy_gateway")&&1===Et("gxy_gorddon")&&1===Et("gxy_alien1")&&1===Et("gxy_alien2")&&1===Et("gxy_chthonian")&&Xc("neutralized"),Tc("summer")&&t.resource.hasOwnProperty("Thermite")){let e=1e5+9e3*t.stats.reset;e>1e6&&(e=1e6),t.resource.Thermite.amount>e&&eo("solstice","micro"===t.race.universe)}if(Tc("firework")&&t[t.race.cataclysm||t.race.orbit_decayed?"space":"city"].firework.on>0&&eo("firework","micro"===t.race.universe),t.city.morale.current>=200&&(Xc("paradise"),t.city.morale.current>=500&&eo("utopia")),t.resource.hasOwnProperty("Money")&&t.resource.Money.amount>=1e9&&Xc("scrooge"),t.resource.hasOwnProperty("Money")&&t.race.inflation&&t.resource.Money.amount>=25e10&&Xc("wheelbarrow"),t.civic.hasOwnProperty("govern")&&t.galaxy.hasOwnProperty("trade")&&t.city.hasOwnProperty("market")&&t.galaxy.trade.cur>=50&&t.city.market.trade>=750&&"federation"===t.civic.govern.type&&Xc("trade"),t.tech.pillars){let e={},a=0,r=5;if(Object.keys(t.pillars).forEach((function(s){di[s]&&((!e[di[s].type]||t.pillars[s]>e[di[s].type])&&(e[di[s].type]=t.pillars[s]),t.pillars[s]=Object.keys(li).length){let t=5;Object.keys(e).forEach((function(a){e[a]=Object.keys(di).length-1&&Xc("resonance"),a>=50&&eo("equilibrium",!1,r)}if(t.portal.hasOwnProperty("mechbay")&&t.tech.hasOwnProperty("hell_spire")&&t.tech.hell_spire>=9){let e=Object.keys(Ca).length,a={};Object.keys(t.stats.spire).forEach((function(r){let s={};Object.keys(t.stats.spire[r]).forEach((function(e){Ca[e]&&((!a.hasOwnProperty(e)||a[e]0&&(s[e]=t.stats.spire[r][e]))})),Object.keys(s).length===e&&Xc("gladiator",!1,Math.min(...Object.values(s)),r)})),Object.keys(a).length===e&&Xc("gladiator",!1,Math.min(...Object.values(a)),"l")}if(t.race.banana){let e=Yc();t.tech.hasOwnProperty("monuments")&&t.tech.monuments>=50&&(t.stats.banana.b5[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b5.l=!0));let a=0,r=0;["b1","b2","b3","b4","b5"].forEach((function(s){t.stats.banana[s].l&&a++,"l"!==e&&t.stats.banana[s][e]&&r++})),a>0&&Xc("banana",!1,a,"l"),r>0&&"l"!==e&&Xc("banana",!1,r,e),t.interstellar.hasOwnProperty("stellar_engine")&&t.interstellar.stellar_engine.mass>=12&&0===t.interstellar.stellar_engine.exotic&&(t.stats.banana.b3[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b3.l=!0))}["l",Yc()].forEach((function(e){let a=0;["ashanddust","exodus","obsolete","bluepill","retired"].forEach((function(r){t.stats.achieve[r]&&t.stats.achieve[r][e]&&t.stats.achieve[r][e]>=5&&a++})),a>0&&Xc("pathfinder",!1,a,e)}));const a=new Date;let r=Tc("easter"),s=Tc("halloween"),i=a.getFullYear();if(!t.settings.boring&&13===a.getDate()&&5===a.getDay()&&t.resource[t.race.species].amount>=1){let e=!1;e=eo("friday","micro"===t.race.universe),e&&t.resource[t.race.species].amount--}else if(t.settings.boring||1!==a.getMonth()||14!==a.getDate())if(t.settings.boring||2!==a.getMonth()||17!==a.getDate())if(r.active){eo("easter","micro"===t.race.universe);let e=0;for(let a=1;a<=18;a++)t.special.egg[i][`egg${a}`]&&e++;e>=12&&eo("egghunt","micro"===t.race.universe)}else if(Tc("launch_day"))eo("launch_day","micro"===t.race.universe);else if(s.active){let e=0;for(let a=1;a<=7;a++)t.special.trick[i][`trick${a}`]&&e++;for(let a=1;a<=7;a++)t.special.trick[i][`treat${a}`]&&e++;e>=12&&eo("trickortreat","micro"===t.race.universe),9===a.getMonth()&&31===a.getDate()&&eo("halloween","micro"===t.race.universe)}else!t.settings.boring&&10===a.getMonth()&&a.getDate()>=22&&a.getDate()<=28?eo("thanksgiving","micro"===t.race.universe):t.settings.boring||11!==a.getMonth()||25!=a.getDate()||eo("xmas","micro"===t.race.universe);else eo("leprechaun","micro"===t.race.universe);else eo("valentine","micro"===t.race.universe);!t.settings.boring&&3===a.getMonth()&&a.getDate()>=1&&a.getDate()<=3&&t.stats.feat.hasOwnProperty("fool")&&t.stats.feat.fool>0&&eo("fool","micro"===t.race.universe),t.stats.dkills>=666e6&&eo("demon_slayer");for(let a=e;a>=1;a--){let e=0;const r=Object.keys(Zc);for(const s of r)t.stats.achieve[s]&&t.stats.achieve[s].l>=a&&e++;let s=[{c:10,f:"novice"},{c:25,f:"journeyman"},{c:50,f:"adept"},{c:75,f:"master"},{c:100,f:"grandmaster"}];for(let r=0;r<5;r++)e>=s[r].c&&(!t.stats.feat[s[r].f]||t.stats.feat[s[r].f]=s&&i++;if(i>=r&&(Xc(a,!1,s),"standard"!==t.race.universe))switch(t.race.universe){case"evil":t.stats.achieve[a].e=void 0;break;case"antimatter":t.stats.achieve[a].a=void 0;break;case"heavy":t.stats.achieve[a].h=void 0;break;case"micro":t.stats.achieve[a].m=void 0;break;case"magic":t.stats.achieve[a].mg=void 0}}"standard"!==t.race.universe&&co(e,a,r,s)}function co(e,a,r,s){let i=!1;switch(t.race.universe){case"evil":(void 0===t.stats.achieve[a]||void 0===t.stats.achieve[a].e||t.stats.achieve[a].e=s&&i++;break;case"antimatter":t.stats.achieve[a]&&t.stats.achieve[a].a&&t.stats.achieve[a].a>=s&&i++;break;case"heavy":t.stats.achieve[a]&&t.stats.achieve[a].h&&t.stats.achieve[a].h>=s&&i++;break;case"micro":t.stats.achieve[a]&&t.stats.achieve[a].m&&t.stats.achieve[a].m>=s&&i++;break;case"magic":t.stats.achieve[a]&&t.stats.achieve[a].mg&&t.stats.achieve[a].mg>=s&&i++}i>=r&&Xc(a,!1,s)}}const oo={mastery:{name:F("mastery"),desc(){let e="";return Object.keys(ta).forEach((function(a){let r=dc(a,!0);"standard"===a?e+=`${ta[a].name}: ${F("perks_mastery_general",[`${+r.g.toFixed(2)}%`])}`:t.stats.achieve.whitehole&&(e+=`${ta[a].name}: ${F("perks_mastery_general",[`${+r.g.toFixed(2)}%`])}, ${F("perks_mastery_universe",[`${+r.u.toFixed(2)}%`])}`)})),e},active:()=>!!(t.genes.challenge&&t.genes.challenge>=2),notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_unlocked_title")}`])]},blackhole:{name:F("achieve_blackhole_name"),desc:e=>F("achieve_perks_blackhole",[e?"5/10/15/20/25":t.stats.achieve.blackhole?5*t.stats.achieve.blackhole.l:5]),active:()=>!!(t.stats.achieve.blackhole&&t.stats.achieve.blackhole.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_blackhole_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_blackhole_name")}`])]},trade:{name:F("achieve_trade_name"),desc:e=>F("achieve_perks_trade",[e?"2/4/6/8/10":t.stats.achieve.trade?2*t.stats.achieve.trade.l:2,e?"1/2/3/4/5":t.stats.achieve.trade?t.stats.achieve.trade.l:1]),active:()=>!!(t.stats.achieve.trade&&t.stats.achieve.trade.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_trade_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_trade_name")}`])]},creator:{name:F("achieve_creator_name"),desc:e=>F("achieve_perks_creator",[e?"1.5/2/2.5/3/3.5":1+(t.stats.achieve.creator?.5*t.stats.achieve.creator.l:.5)]),active:()=>!!(t.stats.achieve.creator&&t.stats.achieve.creator.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_creator_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_creator_name")}`])]},mass_extinction:{name:F("achieve_mass_extinction_name"),group:[{desc:()=>F("achieve_perks_mass_extinction"),active:()=>!!(t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>=1)},{desc(e){let a=t.stats.achieve.mass_extinction?t.stats.achieve.mass_extinction.l:1;return F("achieve_perks_mass_extinction2",[e?"0/50/100/150/200":50*(a-1)])},active:()=>!!(t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_mass_extinction_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_mass_extinction_name")}`])]},doomed:{name:F("achieve_doomed_name"),desc:e=>F("achieve_perks_doomed"),active:()=>t.stats.portals>=1,notes:[F("wiki_perks_achievement_note",[`${F("achieve_doomed_name")}`])]},explorer:{name:F("achieve_explorer_name"),desc:e=>F("achieve_perks_explorer",[e?"1/2/3/4/5":t.stats.achieve.explorer?t.stats.achieve.explorer.l:1]),active:()=>!!(t.stats.achieve.explorer&&t.stats.achieve.explorer.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_explorer_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_explorer_name")}`])]},miners_dream:{name:F("achieve_miners_dream_name"),desc:e=>F("achieve_perks_miners_dream",[e?"1/2/3/5/7":t.stats.achieve.miners_dream?t.stats.achieve.miners_dream.l>=4?2*t.stats.achieve.miners_dream.l-3:t.stats.achieve.miners_dream.l:0]),active:()=>!!(t.stats.achieve.miners_dream&&t.stats.achieve.miners_dream.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_miners_dream_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_miners_dream_name")}`])]},extinct_junker:{name:F("achieve_extinct_junker_name"),desc:()=>F("achieve_perks_enlightened"),active:()=>!!(t.stats.achieve.extinct_junker&&t.stats.achieve.extinct_junker.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_extinct_junker_name")}`])]},joyless:{name:F("achieve_joyless_name"),desc:e=>F("achieve_perks_joyless",[e?"2/4/6/8/10":t.stats.achieve.joyless?2*t.stats.achieve.joyless.l:2]),active:()=>!!(t.stats.achieve.joyless&&t.stats.achieve.joyless.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_joyless_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_joyless_name")}`])]},steelen:{name:F("achieve_steelen_name"),desc:e=>F("achieve_perks_steelen",[e?"2/4/6/8/10":t.stats.achieve.steelen?2*t.stats.achieve.steelen.l:2]),active:()=>!!(t.stats.achieve.steelen&&t.stats.achieve.steelen.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_steelen_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_steelen_name")}`])]},wheelbarrow:{name:F("achieve_wheelbarrow_name"),desc:e=>F("achieve_perks_wheelbarrow",[e?"2/4/6/8/10":t.stats.achieve.wheelbarrow?2*t.stats.achieve.wheelbarrow.l:2]),active:()=>!!(t.stats.achieve.wheelbarrow&&t.stats.achieve.wheelbarrow.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_wheelbarrow_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_wheelbarrow_name")}`])]},extinct_sludge:{name:F("achieve_extinct_sludge_name"),group:[{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.l:3,F("universe_standard")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.l>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.h:3,F("universe_heavy")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.h>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.a:3,F("universe_antimatter")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.a>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.e:3,F("universe_evil")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.e>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.m:3,F("universe_micro")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.m>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.mg:3,F("universe_magic")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.mg>=1)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_extinct_sludge_name")}`]),F("wiki_perks_achievement_note_universe_scale",[`${F("achieve_extinct_sludge_name")}`])]},whitehole:{name:F("achieve_whitehole_name"),group:[{desc:()=>F("achieve_perks_whitehole"),active:()=>!!t.stats.achieve.whitehole},{desc:e=>F("achieve_perks_whitehole2",[e?"5/10/15/20/25":t.stats.achieve.whitehole?5*t.stats.achieve.whitehole.l:5]),active:()=>!!t.stats.achieve.whitehole},{desc:e=>F("achieve_perks_whitehole3",[e?"1/2/3/4/5":t.stats.achieve.whitehole?t.stats.achieve.whitehole.l:1]),active:()=>!!t.stats.achieve.whitehole}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_whitehole_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_whitehole_name")}`])]},heavyweight:{name:F("achieve_heavyweight_name"),desc:e=>F("achieve_perks_heavyweight",[e?"4/8/12/16/20":t.stats.achieve.heavyweight?4*t.stats.achieve.heavyweight.l:4]),active:()=>!!t.stats.achieve.heavyweight,notes:[F("wiki_perks_achievement_note",[`${F("achieve_heavyweight_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_heavyweight_name")}`])]},dissipated:{name:F("achieve_dissipated_name"),group:[{desc:()=>F("achieve_perks_dissipated1",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1)},{desc:e=>F("achieve_perks_dissipated2",[e?"1/2":t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=5?2:1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3)},{desc:()=>F("achieve_perks_dissipated3",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2)},{desc:()=>F("achieve_perks_dissipated4",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=4)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_dissipated_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_dissipated_name")}`])]},banana:{name:F("achieve_banana_name"),group:[{desc:()=>F("achieve_perks_banana1",[50]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=1)},{desc:()=>F("achieve_perks_banana2",[1]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=2)},{desc:()=>F("achieve_perks_banana3",[10]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=3)},{desc:()=>F("achieve_perks_banana4",[3]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=4)},{desc:()=>F("achieve_perks_banana5",[.01]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=5)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_banana_name")}`]),F("wiki_perks_achievement_note_task",[`${F("achieve_banana_name")}`]),F("wiki_perks_achievement_note_task_num",[1,`${F("wiki_achieve_banana1")}`]),F("wiki_perks_achievement_note_task_num",[2,`${F("wiki_achieve_banana2")}`]),F("wiki_perks_achievement_note_task_num",[3,`${F("wiki_achieve_banana3")}`]),F("wiki_perks_achievement_note_task_num",[4,`${F("wiki_achieve_banana4",[500])}`]),F("wiki_perks_achievement_note_task_num",[5,`${F("wiki_achieve_banana5",[50])}`])]},anarchist:{name:F("achieve_anarchist_name"),desc:e=>F("achieve_perks_anarchist",[e?"10/20/30/40/50":t.stats.achieve.anarchist?10*t.stats.achieve.anarchist.l:10]),active:()=>!!(t.stats.achieve.anarchist&&t.stats.achieve.anarchist.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_anarchist_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_anarchist_name")}`])]},ascended:{name:F("achieve_ascended_name"),group:[{desc(e){let a;if(e)a="1-30";else if(a=0,t.stats.achieve.ascended)for(let e=0;e!!(t.stats.achieve.ascended&&t.stats.achieve.ascended.l>=1)},{desc:()=>F("achieve_perks_ascended2",[ec()]),active:()=>!!(t.stats.achieve.ascended&&t.stats.achieve.ascended[Yc()]>=1)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_ascended_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_ascended_name")}`]),F("wiki_perks_achievement_note_universe",[`${F("achieve_ascended_name")}`])]},technophobe:{name:F("achieve_technophobe_name"),group:[{desc:()=>F("achieve_perks_technophobe1",[25]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1)},{desc(e){let a;if(e)a="10/25/30/35/40/45/50";else{a=t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=4?25:10;for(let e=1;e=5&&(a+=5)}return F("achieve_perks_technophobe2",[a])},active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2)},{desc(e){let a;if(e)a="1/2/3/4/5/6";else{a=1;for(let e=1;e=5&&(a+=1)}return F(e||a>1?"achieve_perks_technophobe3a":"achieve_perks_technophobe3",[a])},active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=3)},{desc:()=>F("achieve_perks_technophobe4",[10]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=5)},{desc:e=>F("achieve_perks_technophobe5",[e?"1/2/3/4/5":t.stats.achieve.technophobe?t.stats.achieve.technophobe.l:0]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_technophobe_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_technophobe_name")}`]),F("wiki_perks_achievement_note_universe",[`${F("achieve_technophobe_name")}`])]},iron_will:{name:F("achieve_iron_will_name"),group:[{desc:()=>F("achieve_perks_iron_will1",[.15]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1)},{desc:()=>F("achieve_perks_iron_will2",[10]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2)},{desc:()=>F("achieve_perks_iron_will3",[6]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3)},{desc:()=>F("achieve_perks_iron_will4",[1]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=4)},{desc:()=>F("achieve_perks_iron_will5"),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=5)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_iron_will_name")}`]),F("wiki_perks_achievement_note_ironwill",[`${F("evo_challenge_cataclysm")}`]),F("wiki_perks_achievement_note_ironwill2",[1,`${F("space_red_ziggurat_title")}`]),F("wiki_perks_achievement_note_ironwill3",[2,`${F("tech_elerium_mining")}`]),F("wiki_perks_achievement_note_ironwill3",[3,`${F("tech_lasers")}`]),F("wiki_perks_achievement_note_ironwill3",[4,`${F("tech_generational_ship")}`]),F("wiki_perks_achievement_note_ironwill4",[5,`${F("wiki_resets_bioseed")}`])]},failed_history:{name:F("achieve_failed_history_name"),desc:()=>F("achieve_perks_failed_history",[2]),active:()=>!!(t.stats.achieve.failed_history&&t.stats.achieve.failed_history.l>=5),notes:[F("wiki_perks_achievement_note",[`${F("achieve_failed_history_name")}`]),F("wiki_perks_achievement_note_failed_history",[`${F("evo_challenge_cataclysm")}`])]},lamentis:{name:F("achieve_lamentis_name"),group:[{desc:()=>F("achieve_perks_lamentis1",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=1)},{desc:()=>F("achieve_perks_lamentis2",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=2)},{desc:()=>F("achieve_perks_lamentis3",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=3)},{desc:()=>F("achieve_perks_lamentis4"),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=4)},{desc:()=>F("achieve_perks_lamentis5"),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_lamentis_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_lamentis_name")}`])]},soul_sponge:{name:F("achieve_soul_sponge_name"),desc:e=>F("achieve_perks_soul_sponge",[e?"100/200/300/400/500":t.stats.achieve.soul_sponge?100*t.stats.achieve.soul_sponge.mg:100]),active:()=>!!(t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_soul_sponge_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_soul_sponge_name")}`])]},nightmare:{name:F("achieve_nightmare_name"),desc:()=>F("achieve_perks_nightmare"),active:()=>!!(t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_nightmare_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_nightmare_name")}`])]},gladiator:{name:F("achieve_gladiator_name"),desc:e=>F("achieve_perks_gladiator",[e?"20/40/60/80/100":t.stats.achieve.gladiator?20*t.stats.achieve.gladiator.l:20]),active:()=>!!(t.stats.achieve.gladiator&&t.stats.achieve.gladiator.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_gladiator_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_gladiator_name")}`])]},pathfinder:{name:F("achieve_pathfinder_name"),group:[{desc:()=>F("achieve_perks_pathfinder1",[10]),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1)},{desc:()=>F("achieve_perks_pathfinder2",[10]),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2)},{desc:()=>F("achieve_perks_pathfinder3"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=3)},{desc:()=>F("achieve_perks_pathfinder4"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=4)},{desc:()=>F("achieve_perks_pathfinder5"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=5)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_pathfinder_name")}`]),F("wiki_perks_achievement_note_pathfinder",[`${F("evo_challenge_truepath")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_mad")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_bioseed")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_ai")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_matrix")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_retired")}`])]},overlord:{name:F("achieve_overlord_name"),desc(){let e=`
        ${F("achieve_perks_overlord1",[10])}
        `;return e+=`
        ${F("achieve_perks_overlord2")}
        `,e+=`
        ${F("achieve_perks_overlord3")}
        `,e+=`
        ${F("achieve_perks_overlord4")}
        `,e},active:()=>!!(t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5),notes:[F("wiki_perks_achievement_note",[`${F("achieve_overlord_name")}`])]},adam_eve:{name:F("achieve_adam_eve_name"),desc:()=>F("achieve_perks_adam_eve"),active:()=>!!(t.stats.achieve.adam_eve&&t.stats.achieve.adam_eve.l>=5),notes:[]},creep:{name:F("wiki_arpa_crispr_creep"),desc:e=>F("arpa_perks_creep",[e?"0.01/0.02/0.03/0.04/0.05":t.genes.creep?.01*t.genes.creep:0]),active:()=>!!t.genes.creep,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_genetic_memory_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_animus_title")}`,`${F("arpa_genepool_divine_remembrance_title")}`,`${F("arpa_genepool_divine_proportion_title")}`,`${F("arpa_genepool_genetic_repository_title")}`].join(", ")])]},store:{name:F("wiki_arpa_crispr_store"),desc(e){let a=e?"0.04/0.06/0.08":t.genes.store&&t.genes.store>1?2===t.genes.store?.06:.08:.04;return F(t.genes.store&&t.genes.store>=4?"arpa_perks_store2":"arpa_perks_store1",[a])},active:()=>!!t.genes.store,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_spatial_reasoning_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_spatial_superiority_title")}`,`${F("arpa_genepool_spatial_supremacy_title")}`,`${F("arpa_genepool_dimensional_warping_title")}`].join(", ")])]},evolve:{name:F("wiki_arpa_crispr_evolve"),group:[{desc:()=>F("arpa_perks_evolve"),active:()=>!!t.genes.evolve},{desc:()=>F("arpa_genepool_recombination_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=2)},{desc:()=>F("arpa_genepool_homologous_recombination_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=3)},{desc:()=>F("arpa_genepool_genetic_reshuffling_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=4)},{desc:()=>F("arpa_genepool_recombinant_dna_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=5)},{desc:()=>F("arpa_genepool_chimeric_dna_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=6)},{desc:()=>F("arpa_genepool_molecular_cloning_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=7)},{desc:()=>F("arpa_genepool_transgenes_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=8)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_morphogenesis_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_recombination_title")}`,`${F("arpa_genepool_homologous_recombination_title")}`,`${F("arpa_genepool_genetic_reshuffling_title")}`,`${F("arpa_genepool_recombinant_dna_title")}`,`${F("arpa_genepool_chimeric_dna_title")}`,`${F("arpa_genepool_molecular_cloning_title")}`,`${F("arpa_genepool_transgenes_title")}`].join(", ")])]},birth:{name:F("wiki_arpa_crispr_birth"),desc:()=>F("arpa_perks_birth"),active:()=>!!t.genes.birth,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_replication_title")}`])]},enhance:{name:F("wiki_arpa_crispr_enhance"),desc:()=>F("arpa_perks_enhance"),active:()=>!!t.genes.enhance,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_enhanced_muscle_fiber_title")}`])]},crafty:{name:F("wiki_arpa_crispr_crafty"),group:[{desc:()=>F("arpa_genepool_artificer_desc"),active:()=>!!t.genes.crafty},{desc:e=>F("arpa_genepool_crafting_desc",[e?"50/100":t.genes.crafty&&t.genes.crafty>=3?100:50]),active:()=>!!(t.genes.crafty&&t.genes.crafty>=2)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_artificer_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_detail_oriented_title")}`,`${F("arpa_genepool_rigorous_title")}`].join(", ")])]},governor:{name:F("wiki_arpa_crispr_governor"),desc:()=>F("arpa_perks_governor"),active:()=>!!t.genes.governor,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_governance_title")}`])]},synthesis:{name:F("wiki_arpa_crispr_synthesis"),desc:e=>F("arpa_genepool_synthesis_desc",[e?"2/3/4":t.genes.synthesis&&t.genes.synthesis>=2?t.genes.synthesis>=3?4:3:2,e?"10/25/50":t.genes.synthesis&&t.genes.synthesis>=2?t.genes.synthesis>=3?50:25:10]),active:()=>!!t.genes.synthesis,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_synthesis_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_karyokinesis_title")}`,`${F("arpa_genepool_cytokinesis_title")}`].join(", ")])]},challenge:{name:F("wiki_arpa_crispr_challenge"),group:[{desc:()=>F("arpa_perks_challenge"),active:()=>!!t.genes.challenge},{desc:()=>F("arpa_genepool_unlocked_desc"),active:()=>!!(t.genes.challenge&&t.genes.challenge>=2)},{desc:e=>F("arpa_perks_challenge2",[e?"60/80":t.genes.challenge&&t.genes.challenge>=4?80:60,e?"60/40":t.genes.challenge&&t.genes.challenge>=4?40:60]),active:()=>!!(t.genes.challenge&&t.genes.challenge>=3)},{desc:()=>F("arpa_perks_challenge3"),active:()=>!!(t.genes.challenge&&t.genes.challenge>=5)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_hardened_genes_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_unlocked_title")}`,`${F("arpa_genepool_universal_title")}`,`${F("arpa_genepool_standard_title")}`,`${F("arpa_genepool_mastered_title")}`].join(", ")]),F("wiki_perks_crispr_note_challenge",[F("arpa_genepool_universal_title"),F("arpa_genepool_standard_title")])]},ancients:{name:F("wiki_arpa_crispr_ancients"),group:[{desc:()=>F("arpa_perks_ancients"),active:()=>!!t.genes.ancients},{desc:()=>t.genes.ancients&&t.genes.ancients>=4?F("arpa_perks_ancients3"):F("arpa_perks_ancients2"),active:()=>!!(t.genes.ancients&&t.genes.ancients>=2)},{desc:e=>F("arpa_perks_ancients4",[e?"25/50":t.genes.ancients&&t.genes.ancients>=5?50:25]),active:()=>!!(t.genes.ancients&&t.genes.ancients>=3)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_ancients_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_faith_title")}`,`${F("arpa_genepool_devotion_title")}`,`${F("arpa_genepool_acolyte_title")}`,`${F("arpa_genepool_conviction_title")}`].join(", ")])]},trader:{name:F("wiki_arpa_crispr_trader"),desc:()=>F("arpa_genepool_negotiator_desc"),active:()=>!!t.genes.trader,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_negotiator_title")}`])]},transcendence:{name:F("wiki_arpa_crispr_transcendence"),desc:()=>F("arpa_genepool_transcendence_desc"),active:()=>!!t.genes.transcendence,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_transcendence_title")}`])]},queue:{name:F("wiki_arpa_crispr_queue"),group:[{desc:()=>F("arpa_genepool_geographer_desc"),active:()=>!!t.genes.queue},{desc:()=>F("arpa_genepool_architect_desc"),active:()=>!!(t.genes.queue&&t.genes.queue>=2)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_geographer_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_architect_title")}`].join(", ")])]},plasma:{name:F("wiki_arpa_crispr_plasma"),desc:e=>F("arpa_genepool_mitosis_desc",[e?"3/5":t.genes.plasma>=2?5:3]),active:()=>!!t.genes.plasma,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_mitosis_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_metaphase_title")}`].join(", ")])]},mutation:{name:F("wiki_arpa_crispr_mutation"),group:[{desc:()=>t.genes.mutation&&t.genes.mutation>1?F("arpa_perks_mutation2"):F("arpa_perks_mutation1"),active:()=>!!t.genes.mutation},{desc:()=>F("arpa_perks_mutation3"),active:()=>!!(t.genes.mutation&&t.genes.mutation>=3)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_mutation_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_transformation_title")}`,`${F("arpa_genepool_metamorphosis_title")}`].join(", ")])]},bleed:{name:F("wiki_arpa_crispr_bleed"),group:[{desc:()=>F("arpa_genepool_bleeding_effect_desc",[2.5]),active:()=>!!t.genes.bleed},{desc:()=>F("arpa_genepool_synchronicity_desc",[25]),active:()=>!!(t.genes.bleed&&t.genes.bleed>=2)},{desc:()=>F("arpa_genepool_astral_awareness_desc"),active:()=>!!(t.genes.bleed&&t.genes.bleed>=3)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_bleeding_effect_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_synchronicity_title")}`,`${F("arpa_genepool_astral_awareness_title")}`].join(", ")]),F("wiki_perks_crispr_note_bleed",[`${F("arpa_genepool_bleeding_effect_title")}`])]},blood:{name:F("wiki_arpa_crispr_blood"),group:[{desc:()=>F("arpa_genepool_blood_remembrance_desc"),active:()=>!!t.genes.blood},{desc:()=>F("arpa_genepool_blood_sacrifice_desc"),active:()=>!!(t.genes.blood&&t.genes.blood>=2)},{desc:()=>F("arpa_genepool_essence_absorber_desc"),active:()=>!!(t.genes.blood&&t.genes.blood>=3)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_blood_remembrance_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_blood_sacrifice_title")}`,`${F("arpa_genepool_essence_absorber_title")}`].join(", ")]),F("wiki_perks_crispr_note_blood",[F("arpa_genepool_blood_remembrance_title")])]},spire:{name:F("wiki_arpa_blood_spire"),group:[{desc:()=>F("arpa_blood_purify_desc"),active:()=>!!t.blood.spire},{desc:()=>F("arpa_blood_chum_desc"),active:()=>!!(t.blood.spire&&t.blood.spire>=2)}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_purify_title")}`]),F("wiki_perks_blood_note_upgrade",[[`${F("arpa_blood_chum_title")}`].join(", ")])]},lust:{name:F("wiki_arpa_blood_lust"),group:[{desc:e=>F("arpa_perks_lust",[e?.2:.2*(t.blood.lust?t.blood.lust:1)]),active:()=>!!t.blood.lust}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_lust_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_lust_title")])]},illuminate:{name:F("wiki_arpa_blood_illuminate"),group:[{desc:e=>F("arpa_perks_illuminate",[e?.01:.01*(t.blood.illuminate?t.blood.illuminate:1)]),active:()=>!!t.blood.illuminate}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_illuminate_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_illuminate_title")])]},greed:{name:F("wiki_arpa_blood_greed"),group:[{desc:e=>F("arpa_perks_greed",[e?1:1*(t.blood.greed?t.blood.greed:1)]),active:()=>!!t.blood.greed}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_greed_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_greed_title")])]},hoarder:{name:F("wiki_arpa_blood_hoarder"),group:[{desc:e=>F("arpa_perks_hoarder",[e?1:1*(t.blood.hoarder?t.blood.hoarder:1)]),active:()=>!!t.blood.hoarder}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_hoarder_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_hoarder_title")])]},artisan:{name:F("wiki_arpa_blood_artisan"),group:[{desc:e=>F("arpa_perks_artisan",[e?1:1*(t.blood.artisan?t.blood.artisan:1)]),active:()=>!!t.blood.artisan}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_artisan_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_artisan_title")])]},attract:{name:F("wiki_arpa_blood_attract"),group:[{desc:e=>F("arpa_perks_attract",[e?5:5*(t.blood.attract?t.blood.attract:1)]),active:()=>!!t.blood.attract}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_attract_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_attract_title")])]},wrath:{name:F("wiki_arpa_blood_wrath"),group:[{desc:e=>F("arpa_perks_wrath",[e?5:5*(t.blood.wrath?t.blood.wrath:1)]),active:()=>!!t.blood.wrath}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_wrath_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_wrath_title")])]},prepared:{name:F("wiki_arpa_blood_prepared"),group:[{desc:()=>F("arpa_blood_prepared_desc"),active:()=>!!t.blood.prepared},{desc:()=>F("arpa_blood_compact_desc"),active:()=>!!(t.blood.prepared&&t.blood.prepared>=2)}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_prepared_title")}`]),F("wiki_perks_blood_note_upgrade",[[`${F("arpa_blood_compact_title")}`].join(", ")])]},unbound:{name:F("wiki_arpa_blood_unbound"),group:[{desc:()=>F("arpa_blood_unbound_desc"),active:()=>!!t.blood.unbound},{desc:()=>F("arpa_blood_shadow_war_desc"),active:()=>!!(t.blood.unbound&&t.blood.unbound>=3)},{desc:e=>F("arpa_perks_unbound_resist",[e?"10/5":t.blood.unbound&&t.blood.unbound>=4?5:10]),active:()=>!!(t.blood.unbound&&t.blood.unbound>=2)}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_unbound_title")}`]),F("wiki_perks_blood_note_upgrade",[[`${F("arpa_blood_unbound_resistance_title")}`,`${F("arpa_blood_shadow_war_title")}`,`${F("arpa_blood_unbound_immunity_title")}`].join(", ")])]},aware:{name:F("wiki_arpa_blood_aware"),group:[{desc:()=>F("arpa_blood_blood_aware_desc"),active:()=>!!t.blood.aware}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_blood_aware_title")}`])]},harmonic:{name:F("harmonic"),group:[{desc(e){let t=_c();return F("perks_harmonic",[e?`1-${Object.keys(di).length+2}`:+(100*(t[0]-1)).toFixed(0),e?"2-"+2*(Object.keys(di).length+2):+(100*(t[1]-1)).toFixed(0)])},active(){let e=_c();return!!(t.pillars&&e[0]>1)}},{desc:e=>(_c(),F("perks_harmonic2",[F("portal_west_tower"),F("portal_east_tower"),e?"12-"+12*(Object.keys(di).length-1):12*Object.keys(t.pillars).length])),active(){let e=_c();return!!(t.pillars&&e[0]>1)}}],notes:[F("wiki_perks_harmonic_note1"),F("wiki_perks_harmonic_note2")]},novice:{name:F("perk_novice"),desc(e){let a=t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0?Math.min(t.stats.achieve.apocalypse.l,t.stats.feat.novice):1;return`
        ${F("achieve_perks_novice",[e?"0.5/1/1.5/2/2.5":a/2,e?"0.25/0.5/0.75/1/1.25":a/4])}
        ${F("achieve_perks_novice2")}
        `},active:()=>!!(t.stats.feat.novice&&t.stats.mad>0),notes:[F("wiki_perks_progress_note1",[10,F("wiki_resets_mad")]),F("wiki_perks_progress_note2")]},journeyman:{name:F("perk_journeyman"),desc(e){let a=t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0?Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman):1;return e||a>1?`
        ${F("achieve_perks_journeyman2",[e?"1/2/3":a>=3?a>=5?3:2:1,e?"1/2":a>=4?2:1])}
        ${F("achieve_perks_journeyman3")}
        `:`
        ${F("achieve_perks_journeyman1",[1])}
        ${F("achieve_perks_journeyman3")}
        `},active:()=>!!(t.stats.feat.journeyman&&t.stats.bioseed>0),notes:[F("wiki_perks_progress_note1",[25,F("wiki_resets_bioseed")]),F("wiki_perks_progress_note2")]},adept:{name:F("perk_adept"),desc(e){let a=t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0?Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept):1;return F("achieve_perks_adept",[e?"100/200/300/400/500":100*a,e?"60/120/180/240/300":60*a])},active:()=>!!(t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0),notes:[F("wiki_perks_progress_note1",[50,F("wiki_resets_blackhole")]),F("wiki_perks_progress_note2")]},master:{name:F("perk_master"),desc(e){let a=t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0?Math.min(t.stats.achieve.ascended.l,t.stats.feat.master):1;return F("achieve_perks_master",[e?"1/2/3/4/5":a,e?"2/4/6/8/10":2*a,F("evo_mitochondria_title"),F("evo_eukaryotic_title"),F("evo_membrane_title"),F("evo_organelles_title"),F("evo_nucleus_title")])},active:()=>!!(t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0),notes:[F("wiki_perks_progress_note1",[75,F("wiki_resets_ascension")]),F("wiki_perks_progress_note2")]},grandmaster:{name:F("perk_grandmaster"),desc(e){let a=t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):1;return F("achieve_perks_grandmaster",[e?"1/2/3/4/5":a])},active:()=>!!(t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0),notes:[F("wiki_perks_progress_note1",[100,F("wiki_resets_infusion")]),F("wiki_perks_progress_note2")]}};function no(){rc($("#perksPanel"));let e=$("#perksPanel"),t=!1;Object.keys(oo).forEach((function(a){if(oo[a].hasOwnProperty("group")){let r=!1,s=$(`
        ${oo[a].name}
        `);oo[a].group.forEach((function(e){e.active()&&(r=!0,s.append($(`
        ${e.desc()}
        `)))})),r&&(t=!0,e.append(s))}else oo[a].active()&&(t=!0,e.append($(`
        ${oo[a].name}${oo[a].desc()}
        `)))})),t||e.append($(`
        ${F("perks_none")}
        `))}const lo={dna_replication:{reqs:{race:"protoplasm",resource:"DNA"},type:"major",effect(){var e=Math.rand(1,Math.round(t.resource.DNA.max/3)),a=t.resource.DNA.amount+e;return a>t.resource.DNA.max&&(a=t.resource.DNA.max),t.resource.DNA.amount=a,F("event_dna",[e.toLocaleString()])}},rna_meteor:{reqs:{race:"protoplasm",resource:"RNA"},type:"major",effect(){var e=Math.rand(1,Math.round(t.resource.RNA.max/2)),a=t.resource.RNA.amount+e;return a>t.resource.RNA.max&&(a=t.resource.RNA.max),t.resource.RNA.amount=a,F("event_rna",[e.toLocaleString()])}},inspiration:{reqs:{resource:"Knowledge"},type:"major",effect:()=>(t.race.inspired=Math.rand(300,600),F("event_inspiration"))},motivation:{reqs:{tech:"primitive"},type:"major",effect:()=>(t.race.motivated=Math.rand(300,600),F("event_motivation"))},fire:{reqs:{resource:"Lumber",nogenus:"aquatic",notrait:"evil"},type:"major",effect(){var e=Math.rand(1,Math.round(t.resource.Lumber.amount/4)),a=t.resource.Lumber.amount-e;return a<0&&(a=0),t.resource.Lumber.amount=a,F("event_fire",[e.toLocaleString()])}},flare:{reqs:{tech:"primitive"},type:"major",condition:()=>!!t.city.ptrait.includes("flare"),effect(){let e=0,a=di[t.race.species].home;t.race.cataclysm||t.race.orbit_decayed?(t.space.hasOwnProperty("living_quarters")&&(e+=Math.round(c.living_quarters*Qr.space.spc_red.living_quarters.citizens())),a=di[t.race.species].solar.red):(t.city.hasOwnProperty("basic_housing")&&(e+=t.city.basic_housing.count*Qr.city.basic_housing.citizens()),t.city.hasOwnProperty("cottage")&&(e+=t.city.cottage.count*Qr.city.cottage.citizens()),t.city.hasOwnProperty("apartment")&&(e+=i.apartment*Qr.city.apartment.citizens())),e>t.resource[t.race.species].amount&&(e=t.resource[t.race.species].amount),e=Math.floor(.1*e);let r=Math.rand(0,e);if(t.resource[t.race.species].amount-=r,t.civic[t.civic.d_job].workers-=r,t.civic[t.civic.d_job].workers<0&&(t.civic[t.civic.d_job].workers=0),"oceanic"!==t.city.biome){let e=400;"forest"===t.city.biome?e*=2:"desert"!==t.city.biome&&"volcanic"!==t.city.biome||(e/=2),t.city.firestorm=Math.rand(e,10*e)}return F("oceanic"===t.city.biome?"event_flare2":"event_flare",[a,r.toLocaleString()])}},raid:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(ue("gov0")&&ue("gov1")&&ue("gov2")||t.race.truepath||t.race.cataclysm||!(t.civic.foreign.gov0.hstl>60||t.civic.foreign.gov1.hstl>60||t.civic.foreign.gov2.hstl>60)),effect(){let e=ke(qe(),"army",t.civic.garrison.wounded),a=t.tech.high_tech?t.tech.high_tech+1:1,r=Math.rand(25,50)*a,s=t.civic.garrison.wounded>qe()?qe():t.civic.garrison.wounded,i=Math.floor(m(0,s)),c=Math.floor(m(0,qe()-s));if(t.race.instinct&&(i=Math.round(i/2),c=Math.round(c/2)),t.civic.garrison.workers-=i,t.civic.garrison.wounded+=c,t.stats.died+=i,t.civic.garrison.wounded>t.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(r/5),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0])),e>r)return F("event_raid1",[i.toLocaleString(),c.toLocaleString()]);{let e=Math.rand(1,Math.round(t.resource.Money.amount/4));if(e<=0)return F("event_raid1",[i.toLocaleString(),c.toLocaleString()]);{let a=t.resource.Money.amount-e;return a<0&&(a=0),t.resource.Money.amount=a,F("event_raid2",[e.toLocaleString(),i.toLocaleString(),c.toLocaleString()])}}}},siege:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(ue("gov0")||ue("gov1")||ue("gov2"))&&!t.race.truepath&&t.civic.foreign.gov0.hstl>80&&t.civic.foreign.gov1.hstl>80&&t.civic.foreign.gov2.hstl>80,effect(){let e=ke(qe(),"army",t.civic.garrison.wounded),a=t.tech.high_tech?t.tech.high_tech+1:1,r=(t.civic.foreign.gov0.mil+t.civic.foreign.gov1.mil+t.civic.foreign.gov2.mil)*a,s=t.civic.garrison.wounded>qe()?qe():t.civic.garrison.wounded,i=Math.floor(m(0,s)),c=Math.floor(m(0,qe()-s));if(t.race.instinct&&(i=Math.round(i/2),c=Math.round(c/2)),t.civic.garrison.workers-=i,t.civic.garrison.wounded+=c,t.stats.died+=i,t.civic.garrison.wounded>t.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(r/5),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0])),e>r)return F("event_siege1",[i.toLocaleString(),c.toLocaleString()]);var o=Math.rand(1,Math.round(t.resource.Money.amount/2)),n=t.resource.Money.amount-o;return n<0&&(n=0),t.resource.Money.amount=n,F("event_siege2",[o.toLocaleString(),i.toLocaleString(),c.toLocaleString()])}},pillage0:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(!t.race.truepath||t.tech.isolation||ue("gov0")||!(t.civic.foreign.gov0.hstl>60)),effect:()=>po("gov0")},pillage1:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(!t.race.truepath||t.tech.isolation||ue("gov1")||!(t.civic.foreign.gov1.hstl>60)),effect:()=>po("gov1")},pillage2:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(!t.race.truepath||t.tech.isolation||ue("gov2")||!(t.civic.foreign.gov2.hstl>60)),effect:()=>po("gov2")},pillage3:{reqs:{tech:"military"},type:"major",condition:()=>!!(t.race.truepath&&!t.tech.isolation&&t.tech.rival&&t.civic.foreign.gov3.hstl>60),effect:()=>po("gov3",!0)},witch_hunt_crusade:{reqs:{tech:"magic"},type:"major",condition:()=>!!(t.race.witch_hunter&&t.resource.Sus.amount>=100),effect:()=>po("witchhunt",!0)},terrorist:{reqs:{tech:"world_control",notrait:"truepath"},type:"major",effect(){let e=Math.floor(m(0,t.civic.garrison.wounded)),a=Math.floor(m(0,t.civic.garrison.workers-t.civic.garrison.wounded));return t.race.instinct&&(e=Math.round(e/2),a=Math.round(a/2)),t.civic.garrison.workers-=e,t.civic.garrison.wounded+=a,t.stats.died+=e,t.civic.garrison.wounded>t.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers),t.race.blood_thirst&&(t.race.blood_thirst_count+=1e3,t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0])),0===e?F("event_terrorist1",[a.toLocaleString()]):F("event_terrorist2",[a.toLocaleString(),e.toLocaleString()])}},quake:{reqs:{tech:"wsc",notech:"quaked"},type:"major",condition:()=>!!t.city.ptrait.includes("unstable"),effect:()=>(t.tech.quaked=1,ms(),F("event_quake",[t.race.cataclysm||t.race.orbit_decayed?di[t.race.species].solar.red:di[t.race.species].home]))},doom:{reqs:{tech:"wsc",notech:"portal_guard"},type:"major",condition:()=>!!(t.space.space_barracks&&t.space.space_barracks.on>0),effect:()=>(Xc("doomed"),t.stats.portals++,F(t.race.evil?"event_doom_alt":"event_doom",[di[t.race.species].solar.dwarf]))},demon_influx:{reqs:{tech:"portal_guard"},type:"major",effect(){let e=Math.rand(2500,5e3);return t.portal.fortress.threat+=e,F("event_demon_influx",[e.toLocaleString()])}},ruins:{reqs:{trait:"ancient_ruins",resource:"Knowledge"},type:"major",effect(){let e=["Iron","Copper","Steel","Cement"];for(var a=0;at.resource[r].max?t.resource[r].amount=t.resource[r].max:t.resource[r].amount+=e}}return F("event_ruins")}},tax_revolt:{reqs:{low_morale:99,notrait:"blissful",tech:"primitive"},type:"major",condition(){let e="oligarchy"===t.civic.govern.type?45:25,a=N("aristocrat",2);return a&&(e-=a),t.civic.taxes.tax_rate>e},effect:()=>function(){let e=["Soul_Gem","Corrupt_Gem","Codex","Demonic_Essence"],a="oligarchy"===t.civic.govern.type?45:25,r=N("aristocrat",2);r&&(a-=r);let s=.04*(t.civic.taxes.tax_rate-a);return Object.keys(t.resource).forEach((function(a){if(!e.includes(a)){let e=Math.rand(1,Math.round(t.resource[a].amount*s)),r=t.resource[a].amount-e;r<0&&(r=0),t.resource[a].amount=r}})),F("event_tax_revolt")}()},slave_death1:_o("major","death1"),slave_death2:_o("major","death2"),slave_death3:_o("major","death3"),protest:{reqs:{tech:"primitive"},type:"major",condition:()=>"republic"===t.civic.govern.type,effect(){switch(t.civic.govern.protest=Math.rand(30,60),Math.rand(0,10)){case 0:return F("event_protest0",[Is("small")]);case 1:return F("event_protest1");case 2:return F("event_protest2");case 3:return t.civic.govern.protest=Math.rand(45,75),F("event_protest3");case 4:return F("event_protest4");case 5:return t.civic.govern.protest=Math.rand(45,75),F("event_protest5");case 6:return F("event_protest6");case 7:return F("event_protest7");case 8:return F("event_protest8");case 9:return t.civic.govern.protest=Math.rand(60,90),F("event_protest9")}}},scandal:{reqs:{tech:"govern"},type:"major",condition:()=>!!N("muckraker",0),effect(){switch(t.civic.govern.scandal=Math.rand(15,90),Math.rand(0,10)){case 0:return F("event_scandal0");case 1:return F("event_scandal1");case 2:return F("event_scandal2");case 3:return F("event_scandal3");case 4:return F("event_scandal4");case 5:return F("event_scandal5");case 6:return F("event_scandal6");case 7:return F("event_scandal7");case 8:return F("event_scandal8");case 9:return F("event_scandal9")}}},spy:{reqs:{tech:"primitive",notech:"world_control"},type:"major",condition(){if(t.race.elusive)return!1;if(Pi("satyr")>.25)return!1;for(let e=0;e<3;e++)if(t.civic.foreign[`gov${e}`].spy>0&&!t.civic.foreign[`gov${e}`].occ&&!t.civic.foreign[`gov${e}`].anx&&!t.civic.foreign[`gov${e}`].buy)return!0;return!1},effect(){let e=[];for(let a=0;a<3;a++)t.civic.foreign[`gov${a}`].spy>0&&!t.civic.foreign[`gov${a}`].occ&&!t.civic.foreign[`gov${a}`].anx&&!t.civic.foreign[`gov${a}`].buy&&e.push(a);let a=e[Math.rand(0,e.length)];return t.civic.foreign[`gov${a}`].spy--,0===t.civic.foreign[`gov${a}`].spy&&(t.civic.foreign[`gov${a}`].act="none",t.civic.foreign[`gov${a}`].sab=0),F("event_spy",[ee(a)])}},mine_collapse:{reqs:{tech:"mining"},type:"major",condition:()=>t.resource[t.race.species].amount>0&&t.civic.miner.workers>0,effect:()=>(t.resource[t.race.species].amount--,t.civic.miner.workers--,F("event_mine_collapse"))},m_curious:{reqs:{tech:"primitive",trait:"curious"},condition:()=>t.resource[t.race.species].amount>=40,type:"major",effect(){switch(Math.rand(0,5)){case 0:{let e="Money",a=Math.rand(5e4,5e6);switch(Math.rand(0,5)){case 0:t.resource.Steel.display&&(e="Steel",a=Math.rand(100,1e5));break;case 1:t.resource.Bolognium.display&&(e="Bolognium",a=Math.rand(500,5e4));break;case 2:t.resource.Alloy.display&&(e="Alloy",a=Math.rand(250,1e6));break;case 3:t.resource.Adamantite.display&&(e="Adamantite",a=Math.rand(1e3,25e4));break;case 4:t.resource.Soul_Gem.display&&(e="Soul_Gem",a=1)}return t.resource[e].amount+=a,t.resource[e].max>=0&&t.resource[e].amount>t.resource[e].max&&(t.resource[e].amount=t.resource[e].max),F("event_m_curious0","Money"===e?[di[t.race.species].name,"$",a.toLocaleString()]:[di[t.race.species].name,a.toLocaleString(),t.resource[e].name])}case 1:return t.resource[t.race.species].amount-=10,t.civic[t.civic.d_job].workers-=10,t.civic[t.civic.d_job].workers<0&&(t.civic[t.civic.d_job].workers=0),F("event_m_curious1",[di[t.race.species].name]);case 2:return t.race.inspired=Math.rand(600,1200),F("event_m_curious2",[di[t.race.species].name]);case 3:return t.race.distracted=Math.rand(200,600),F("event_m_curious3",[di[t.race.species].name]);case 4:return"cath"===t.race.species?(t.race.stimulated=Math.rand(500,1e3),F("event_m_curious4a",[di[t.race.species].name])):F("event_m_curious4b",[di[t.race.species].name])}}},curious1:{reqs:{tech:"primitive",trait:"curious"},type:"minor",effect:()=>F(`event_curious${Math.rand(0,5)}`,[di[t.race.species].name])},curious2:{reqs:{tech:"primitive",trait:"curious"},type:"minor",effect:()=>F(`event_curious${Math.rand(5,10)}`,[di[t.race.species].name])},slave_escape1:_o("minor","escape1"),slave_escape2:_o("minor","escape2"),slave_escape3:_o("minor","death4"),shooting_star:uo("shooting_star","primitive"),tumbleweed:uo("tumbleweed","primitive"),flashmob:uo("flashmob","high_tech"),witch_hunt:{reqs:{tech:"magic"},type:"minor",condition:()=>!!(t.race.witch_hunter&&t.resource.Sus.amount>=50&&t.civic.scientist.workers>0),effect:()=>(t.resource[t.race.species].amount--,t.civic.scientist.workers--,t.civic.scientist.assigned--,F("witch_hunter_witch_hunt"))},heatwave:{reqs:{tech:"primitive"},type:"minor",condition:()=>!t.race.cataclysm&&!t.race.orbit_decayed&&2!==t.city.calendar.temp,effect:()=>(t.city.calendar.temp=2,t.city.cold=0,F("event_heatwave"))},coldsnap:{reqs:{tech:"primitive"},type:"minor",condition:()=>!t.race.cataclysm&&!t.race.orbit_decayed&&0!==t.city.calendar.temp,effect:()=>(t.city.calendar.temp=0,t.city.hot=0,F("event_coldsnap"))},cucumber:uo("cucumber","primitive"),planking:uo("planking","high_tech"),furryfish:uo("furryfish","primitive"),meteor_shower:uo("meteor_shower","primitive"),hum:uo("hum","high_tech"),bloodrain:uo("bloodrain","primitive"),haunting:uo("haunting","science"),mothman:uo("mothman","science"),dejavu:uo("dejavu","theology"),dollar:uo("dollar","currency",(function(){let e=Math.rand(1,10);return t.resource.Money.amount+=e,t.resource.Money.amount>t.resource.Money.max&&(t.resource.Money.amount=t.resource.Money.max),e})),pickpocket:uo("pickpocket","currency",(function(){let e=Math.rand(1,10);return t.resource.Money.amount-=e,t.resource.Money.amount<0&&(t.resource.Money.amount=0),e})),bird:uo("bird","primitive"),contest:{reqs:{tech:"science"},type:"minor",effect(){let e=Math.rand(0,3),t=Math.rand(0,10);return F("event_contest",[F(`event_contest_place${e}`),F(`event_contest_type${t}`)])}},cloud:uo("cloud","primitive",(function(){return F(`event_cloud_type${Math.rand(0,11)}`)})),dark_cloud:{reqs:{tech:"primitive"},type:"minor",condition:()=>!t.race.cataclysm&&!t.race.orbit_decayed&&0!==t.city.calendar.weather,effect:()=>(t.city.calendar.weather=0,F("event_dark_cloud"))},gloom:{reqs:{tech:"primitive"},type:"minor",condition:()=>!t.race.cataclysm&&!t.race.orbit_decayed&&1!==t.city.calendar.weather,effect:()=>(t.city.calendar.weather=1,F("event_gloom"))},tracks:uo("tracks","primitive"),hoax:uo("hoax","primitive"),burial:uo("burial","primitive"),artifacts:uo("artifacts","high_tech"),parade:uo("parade","world_control"),crop_circle:uo("crop_circle","agriculture"),llama:uo("llama","primitive",(function(){let e=Math.rand(25,100);return t.resource.Food.amount-=e,t.resource.Food.amount<0&&(t.resource.Food.amount=0),e}),(function(){return!(t.race.carnivore||t.race.soul_eater||t.race.detritivore||t.race.artifical)})),cat:uo("cat","primitive"),omen:uo("omen","primitive"),theft:uo("theft","primitive",(function(){return F(`event_theft_type${Math.rand(0,10)}`)})),compass:uo("compass","mining"),bone:uo("bone","primitive"),delicacy:uo("delicacy","high_tech"),prank:uo("prank","primitive",(function(){return F(`event_prank_type${Math.rand(0,10)}`)})),graffiti:uo("graffiti","science"),soul:uo("soul","soul_eater"),cheese:{reqs:{tech:"banking"},type:"minor",condition:()=>!!(t.tech.banking&&t.tech.banking>=7),effect(){let e=t.stats.hasOwnProperty("reset")?t.stats.reset+1:1;return t.race.cheese=Math.rand(10,10+e),F("event_cheese")}},tremor:uo("tremor","primitive"),rumor:uo("rumor","primitive",(function(){return F(`event_rumor_type${Math.rand(0,10)}`)}))};function uo(e,t,a,r){return{reqs:{tech:t},condition(){let e=!0;return"function"==typeof r&&(e=r()),e},type:"minor",effect(){let t=!1;return"function"==typeof a&&(t=a()),t?F(`event_${e}`,[t]):F(`event_${e}`)}}}function _o(e,a){return{reqs:{trait:"slaver",tech:"slaves"},condition:()=>!(t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation),type:e,effect:()=>t.city.slave_pen&&t.city.slave_pen.slaves>0?(t.city.slave_pen.slaves--,t.resource.Slave.amount=t.city.slave_pen.slaves,F(`event_slave_${a}`)):F("event_slave_none")}}function po(e,a){let r=ke(qe(),"army",t.civic.garrison.wounded),s=t.tech.high_tech?t.tech.high_tech+1:1,i=("witchhunt"===e?1e3:t.civic.foreign[e].mil)*(1+Math.floor(m(0,10)-5)/10)*s,c=t.civic.garrison.wounded>qe()?qe():t.civic.garrison.wounded,o=qe()>0?Math.floor(m(1,c)):0,n=Math.floor(m(0,qe()-c));t.race.instinct&&(o=Math.round(o/2),n=Math.round(n/2)),t.civic.garrison.workers-=o,t.civic.garrison.wounded+=n,t.stats.died+=o,t.civic.garrison.wounded>t.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(i/5),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0]));let l="witchhunt"===e?F("witch_hunter_crusade"):F(`civics_gov${t.civic.foreign[e].name.s0}`,[t.civic.foreign[e].name.s1]);if(r>i)return F("event_pillaged1",[l,o.toLocaleString(),n.toLocaleString()]);{let e=a?2:4,r=[],s=Object.keys(Za);return s.push("Money"),s.forEach((function(a){if(t.resource[a]&&t.resource[a].display&&t.resource[a].amount>0){let s=Math.rand(1,Math.round(t.resource[a].amount/e)),i=t.resource[a].amount-s;i<0&&(i=0),t.resource[a].amount=i,"Money"===a?r.push(`$${k(s)}`):r.push(`${k(s)} ${t.resource[a].name}`)}})),F("event_pillaged2",[l,o.toLocaleString(),n.toLocaleString(),r.join(", ")])}}function ho(e){let a=[];return Object.keys(lo).forEach((function(r){let s=!0;e!==lo[r].type&&(s=!1),("major"===e&&t.event.l===r||"minor"===e&&t.m_event.l===r)&&(s=!1),lo[r].reqs&&Object.keys(lo[r].reqs).forEach((function(e){switch(e){case"race":lo[r].reqs[e]!==t.race.species&&(s=!1);break;case"genus":lo[r].reqs[e]!==di[t.race.species].type&&(s=!1);break;case"nogenus":lo[r].reqs[e]===di[t.race.species].type&&(s=!1);break;case"resource":t.resource[lo[r].reqs[e]]&&t.resource[lo[r].reqs[e]].display||(s=!1);break;case"trait":t.race[lo[r].reqs[e]]||(s=!1);break;case"notrait":t.race[lo[r].reqs[e]]&&(s=!1);break;case"tech":t.tech[lo[r].reqs[e]]||(s=!1);break;case"notech":t.tech[lo[r].reqs[e]]&&(s=!1);break;case"high_tax_rate":t.civic.taxes.tax_rate<=lo[r].reqs[e]&&(s=!1);break;case"low_morale":t.city.morale.current>=lo[r].reqs[e]&&(s=!1);break;case"biome":t.city.biome!==lo[r].reqs[e]&&(s=!1);break;default:s=!1}})),s&&lo[r].condition&&!lo[r].condition()&&(s=!1),s&&a.push(r)})),a}const mo=[{version:"1.3.8",revision:"a",date:"6/1/2023",changes:["Fixed high pop scaling."]},{version:"1.3.8",date:"6/1/2023",changes:["Unfathomable bug fixes.","Psychic powers up time now scale with rank of Ancient Nightmare.","Additional Psychic power upgrades.","Intergalactic Raider renamed to Corsair."]},{version:"1.3.7",revision:"a",date:"5/30/2023",changes:["Fixed issue with drawing the same alien species twice in intergalactic content.","Adjusted Mana costs for some research techs in Witch Hunter."]},{version:"1.3.7",date:"5/29/2023",changes:["Added Magic universe exclusive challenge: Witch Hunter.","Reduced Encrypted Data cost of Data Analysis, Advanced Medkits, Automated Warehousing, Elerium Extraction, and Drone Warfare techs.","Star Forge smelting bonus rebalanced.","Antimatter Dark Energy effect now applies to Truepath Ship power generation.","Fixed Magocracy Crystal bonus.","Reduced Crystal cost of Alchemy.","Fixed Humpback trait rank scaling.","Infiltrator can now steal Alien Biotech on Truepath.","Fixed brownout issue with using Replicator Gov task when constructing a new powered building.","Fixed rejuvenated trashed planet bonus.","Fixed orbit period on reterraformed planets."]},{version:"1.3.6",date:"4/22/2023",changes:["Added Astrological signs.","Added Motivated Event.","Operating Bases now function as Hospitals in Orbit Decay scenario.","Stellar Forge is now locked to using Star Fuel for smelting.","Species with the Forge trait can now use Inferno Fuel and Star Fuel.","Reduced Wireless Signal needed to Contact womlings in Lone Survivor."]},{version:"1.3.5",revision:"c",date:"4/16/2023",changes:["Made Egg #17 easier to get in Cataclysm mode."]},{version:"1.3.5",revision:"b",date:"4/9/2023",changes:["Increased egg accessibility with certain traits or challenge modes."]},{version:"1.3.5",revision:"a",date:"4/8/2023",changes:["Fixed a bug that caused eggs 16-18 not to count for unlocking the egg hunt feat."]},{version:"1.3.5",date:"4/7/2023",changes:["Avian species now have the Flier trait.","Avian Rigid trait replaced with Sky Lover.","Added Wireless storage to High-Tech farm in isolation","Fixed truepath dreadnought power costs.","Fixed a bug that could assign extra challenge genes.","Fixed a bug with changing languages with active Tau Ceti content.","Fixed many issues with preload tab content in the early game."]},{version:"1.3.4",revision:"b",date:"3/30/2023",changes:["Prevented some bugs caused by distributed power mode from occurring.","You can now unlock World Domination, Illuminati, Syndicate, and Pacifist in Truepath."]},{version:"1.3.4",revision:"a",date:"3/25/2023",changes:["A restore point is now made if you select isolation protocol."]},{version:"1.3.4",date:"3/24/2023",changes:["Evolving Synth can now choose imitation race from any species killed by an AI Apocalypse.","Fixed issue with miscalculating low fuel usage for various power generating structures.","Extractor Ship Isolation output boosted by 20%.","Added additional Hooved reskins.","Fixed various issues with Preload Tab Content.","Explorer Ship config is now locked down for Engine, Sensor, and Weapon components.","Skilled Servants assigned to craft inactive resources will now be refunded."]},{version:"1.3.3",revision:"a",date:"3/20/2023",changes:["Fixed a bug that could cause the Test Launch to be unavailable."]},{version:"1.3.3",date:"3/15/2023",changes:["Rebalanced Soul Gem drop mechanics.","Added Annihilation Feat.","Added additional Mass Ejector Optimizer config mode.","Servants are no longer affected by most racial traits.","The Lone Survivor can no longer benefit from Hivemind.","Fixed High Pop issue with Pit Miners.","Fixed bug with unlocking Replicator without a Governor."]},{version:"1.3.2",revision:"c",date:"3/8/2023",changes:["Fixed cataclysm reset while having preload tab content enabled."]},{version:"1.3.2",revision:"b",date:"3/5/2023",changes:["Fixed Rock Quarry under industry tab for Smoldering players."]},{version:"1.3.2",revision:"a",date:"3/5/2023",changes:["Adjusted hell calculation."]},{version:"1.3.2",date:"3/4/2023",changes:["High-Tech Factory changed back to tool modifier, however value is increased from original 25% to 90%.","Advanced Material Synthesis increased from 50% to 65%.","Added new interaction between Hell Surveyors and Drone victims.","Fixed bug that would cause Replicator Governor task to swap resources when focusing a resource without a cap.","Fixed inability to produce Chrysotile in Isolation."]},{version:"1.3.1",date:"3/3/2023",changes:["Added Advanced Material Synthesis tech to Isolation path.","High-Tech Factory crafting bonus changed from a Tool modifier to a direct multiplier.","Updated Mass Ejector Optimizer logic.","Fixed a bug that broke Cataclysm reset.","Fixed fuel calculation bug with Moon Bases and Spaceports.","Fixed issue with self replicating Synth and Nano.","Fixed bugs with purchasing CRISPR techs in Antimatter universe."]},{version:"1.3.0",revision:"b",date:"3/1/2023",changes:["Fixed issue with Mass Ejector Optimizer gov task breaking the governor subtab."]},{version:"1.3.0",revision:"a",date:"3/1/2023",changes:["Fixed Antimatter universe."]},{version:"1.3.0",date:"3/1/2023",changes:["The True Path has been extended, explore Tau Ceti and expand your civilization.","Added Perks: Evolve Master and Evolve Grandmaster.","Added Distributed Low Power mode setting.","Added Precognition CRISPR upgrade.","Strong trait now buffs basic jobs but has a weaker effect on manual resource collection.","Ships in Truepath can now only be scrapped at the Shipyard.","Truepath Sensor Range and Costs adjusted. Range now depends partly on base ship class.","Queue stacks now indicate first block vs last blocking resource with a gradient indicator.","Added screen reader improvements for blocking resources.","You can no longer unlock Anarchist by Cataclysm.","Syndicate will now also steal food from Biodomes.","Reinforced Shed upgrade now requires unlocking Iron Mining.","You must now construct a Titan Habitat before a Titan Mine.","Removed dark background effect from modal popups.","Increased Entrepreneur Governor trade bonus from 75% to 125% and Bank capacity boost from 10% to 12%.","Increased Media Governor morale bonuses and Library bonus.","Increased Soldier Governor combat bonus from 5% to 25%.","Increased Educator Governor knowledge bonus from 5% to 6%.","Increased Spiritualist Governor worker bonus from 10% to 20% and tourism bonus from $2 to $5 per Temple.","Increased Noble Governor tax cap bonus from 10% to 20%.","Bluecollar Governor now increases output of Coal and Oil power plants and boosts Miners, Smelter, and Oil Derrick.","Bureaucrat Governor now provides a slight boost to government effects."]},{version:"1.2.21",date:"1/10/2023",changes:["New Achievement filtering options in Wiki.","Updated Chinese lang file.","Updated Korean lang file."]},{version:"1.2.20",date:"9/16/2022",changes:["New homelessness system.","Factory, Mining Droids, and Graphene Plants will remember resource assignment after a low power shutdown.","Terraforming and Ascension can no longer be queued or multi-clicked.","AI Cores show correct bonus in tooltip.","Stealing Rocketry will now unlock rival in Truepath.","Playful will no longer remove unemployed stress with no hunters.","Andromeda Citizens will no longer stick around if abandoned by a stargate shutdown.","Fixed various bugs with mutating in or out some traits.","Made some improvements for screen readers to determine active state of challenges."]},{version:"1.2.19",revision:"a",date:"8/21/2022",changes:["Home Planet Orbital structures are now merged with the Moon instead of Red Planet in Cataclysm."]},{version:"1.2.19",date:"8/20/2022",changes:["Added rank scaling effects to traits: Carnivore, Hooved, Leathery, Unified, & Magnificent.","Structures orbiting the home planet are now moved to the Red planet after Orbit Decay or during Cataclysm.","Fixed a bug with deactivating fuel consuming structures when fuel runs dry.","Already active Governor tasks will no longer display for assignment in other task slots.","Constructing a Stellar or Infernal Forge will now assign Iron as a default resource instead of nothing.","Buffed effects of Star Forge fueled smelting.","Fixed an incorrect source label for money storage in Orbit Decay."]},{version:"1.2.18",revision:"a",date:"8/14/2022",changes:["Fixed ARPA queueing."]},{version:"1.2.18",date:"8/14/2022",changes:["More accurate timers when using Governor Trash Management task.","Optimistic Min Morale effect now scales with trait rank.","Fixed TP loot table when Assaulting or Sieging rival."]},{version:"1.2.17",revision:"a",date:"8/10/2022",changes:["Cheese Event power is now scaled with your cheese level.","Fixed Soft Reset bug with Rejuvenated."]},{version:"1.2.17",date:"8/10/2022",changes:["New Hell stats tracking and analytics.","Fixed Genetics not unlocking in Cataclysm.","Fixed many High Pop scaling interactions.","Fixed some loading bugs with wiki when no save data is present.","Updated various wiki entries and calculators.","Updated Pig Latin."]},{version:"1.2.16",revision:"a",date:"8/8/2022",changes:["Fixed OD bugs with Ziggurat, Garage, and Fabrication.","Fixed Launch Facility sometimes getting stuck in queue."]},{version:"1.2.16",date:"8/4/2022",changes:["Added Orbit Decay Challenge.","Added Retrograde planetary trait.","New achievement: Better dead than red.","New CRISPR upgrade: Civil Service.","Other stuff the dev was too lazy to document."]},{version:"1.2.15",revision:"a",date:"7/1/2022",changes:["Fixed bug that prevented games without save data from loading."]},{version:"1.2.15",date:"7/1/2022",changes:["Firework Festival now starts on July 1st and ends July 4th.","Added Dracula theme by azzzertyy.","Fixed bug with Horseshoe governor and multiplier keys.","Fixed issues with starting Cataclysm as Synth.","Fixed bugs with wrong path techs being displayed.","Evil Synth now start with a Graveyard instead of a Lumberyard.","Deify and study can no longer be queued at same time.","Restore backup no longer requires double clicking to trigger confirmation box."]},{version:"1.2.14",revision:"a",date:"4/19/2022",changes:["Fixed some minor bugs.","Updated some translations."]},{version:"1.2.14",date:"4/1/2022",changes:["Added Titan Mine slider to Industry tab.","Added additional popup confirmation to Restore Backup.","Nanite Factory interface now has tooltips for each resource","The Vault Discovery event can no longer occur if there are 0 Archaeologists and/or if Suppression is at 0%","Fixed bugs related to unlocking the Fool feat.","Fixed bugs with Mass Ejector optimizor governor task."]},{version:"1.2.13",date:"3/31/2022",changes:["Restore Backup must now be clicked twice to trigger."]},{version:"1.2.12",revision:"c",date:"3/7/2022",changes:["Fixed Double Density achievement."]},{version:"1.2.12",revision:"b",date:"3/2/2022",changes:["Fixed logic fault with mech constructor inferno upgrades."]},{version:"1.2.12",revision:"a",date:"3/1/2022",changes:["Fixed some bugs with planet traits.","Fixed bug with attacking on Swamp planets."]},{version:"1.2.12",date:"2/28/2022",changes:["Planets can now have upto two traits.","Advanced Biomes: Savanna, Swamp, Ashland, and Taiga can now appear.","Added Permafrost planetary trait.","Forest Biome lumber bonus changed from 15% to 20%.","Exotic materials are now ranked higher by the Mass Optimizer governor task.","Repair droid effect on Carport repairs buffed from 5% to 8%.","You must now discover the Hell Vault through Archaeology.","Water now has Mass."]},{version:"1.2.11",date:"2/16/2022",changes:["Added Doomed achievement to the perks lists.","Added Governor CRISPR tree to perks list.","Updated prestige gain/bonus calculators.","Fixed Ritual Casting not showing up in Industry in Cataclysm.","Detritivores no longer see the Farming ritual.","Fixed Entertainer tooltip showing twice the effect of Musical.","Fixed Gauss Rifles showing the effect for Disruptor Rifles.","Fixed Water Freighter tooltip showing half the Helium-3 cost.","Fixed some affordability checks."]},{version:"1.2.10",date:"2/7/2022",changes:["Bioseed probes now have significantly less cost creep inside True Path scenario.","You can no longer manually buy or sell resources while the game is paused.","Fixed bug with High Pop trait and Savings Bonds granting too much money.","Minor bug fixes"]},{version:"1.2.9",date:"1/29/2022",changes:["Spies may now sell you out when caught or escape when failing a mission.","Infiltrator can now steal Quantium tech inside True Path.","Genetics Lab UI updated."]},{version:"1.2.8",revision:"a",date:"1/19/2022",changes:["Fixed Farmer per Farm scaling with High Pop trait.","Adjusted low end scaling of High Pop Hivemind trait.","Wireless Signal cost for Symposium lowered.","Added Anarchy scaling with High Pop"]},{version:"1.2.8",date:"1/19/2022",changes:["Insectoid genus redesigned with High Population trait.","Fixed bug that caused incorrect timer calculations when using Slow or Hyper trait at any rank other then 1."]},{version:"1.2.7",revision:"a",date:"1/11/2022",changes:["Fixed storage bug with standard universe."]},{version:"1.2.7",date:"1/11/2022",changes:["Failed Experiment Challenge mode.","Ziggurat bonus separated from base production of buildings.","Fixed bug that prevented smoldering races from being able to loot Chrysotile","Fixed bug that would cause Intergalactic Tech page in wiki not to load if you were playing in Antimatter universe."]},{version:"1.2.6",date:"12/24/2021",changes:["Fixed bug that prevented custom Synthetic race from showing if you refreshed the page.","Fixed bugs with Synthetic evolution and traits: Calm, Cannibalize, and Magnificent.","Fixed bugs with using the quick tab keys when preload tabs is enabled."]},{version:"1.2.5",date:"12/21/2021",changes:["Fixed bug that caused a planet to lose its geology traits after an AI reset.","Fixed bug with scavenger job description."]},{version:"1.2.4",date:"12/19/2021",changes:["Solar system now has elliptical orbits.","Fixed Evolve Adept Food bonus.","Rank of each aquired trait is now listed in genetics tab.","Crate/Container sources are now listed in resource popup.",'Manual buying/selling will auto scale down to prevent "waste".']},{version:"1.2.3",date:"12/16/2021",changes:["Expanded Festive Season to include additional species."]},{version:"1.2.2",date:"12/15/2021",changes:["Graphene Plants now show on industry tab for True Path.","Added entry for Festive Season into wiki.","The game wiki will now load without any game data."]},{version:"1.2.1",date:"12/14/2021",changes:["Smelter metals can now be reallocated without unassigning.","Increased accuracy of syndicate intel data","Fixed bug with removing Weak & Bad genes when toggling True Path.","Fixed bug with adding or removing Professors not updating indoctrination value.","Fixed bug with Planet Wiki entry that prevented some data from loading.","Added trait rankings to wiki."]},{version:"1.2.0",revision:"a",date:"12/12/2021",changes:["Fixed bug with Plasmid Storage.","Fixed bug with Befuddle trait and Espionage.","Fixed bug with Composting.","Updated Solar Map.","Added setting to enable mobile device support.","Minor buff to TP Frigate power."]},{version:"1.2.0",date:"12/12/2021",changes:["Unlock the True Path (Requires completion of Ascension or Demonic Infusion).","Using Fanaticism to gain an unempowered trait you already possess will now empower that trait.","Added option to Hell Fortress to prevent using ship crew as reinforcements.","Shrine Metal bonus now applies to Mining Droid Aluminium production.","Armored trait now prevents 50% of deaths.","Cannibalize healing now applies a percent based bonus instead of being equivalent to 3 5% Hospitals.","GruvBox Dark is now the default theme.","Added Evolve Adept Perk.","Themed several additional weapon techs in magic universe for immersion.","Smoldering and Chilled effects now display as Smoldering or Chilled in production breakdowns instead of Hot/Cold.","Improved touch device support."]},{version:"1.1.17",date:"11/28/2021",changes:["Job stress from Civilian Ship Crew is now calculated correctly.","Things will now show as unaffordable if they require a locked resource.","Added new entries to Mechanics section of Wiki: Job Stress, Cost Creep, and Warmonger.","Evolve Novice and Evolve Journeyman perk conditions updated."]},{version:"1.1.16",date:"10/30/2021",changes:["Ghost #3 can now be captured with Smoldering.","Ghost #7 can now be captured in Cataclysm mode.","Updated description of Trick or Treat feat.","Llamas will no longer harass carnivores, detritivores, and soul eaters by grazing their fields."]},{version:"1.1.15",date:"10/20/2021",changes:["Added buttons to pause queues.","Cracked Pylons now correctly add to Mana cap.","Pillar of Bones will no longer be rolled with the Smoldering trait.","Fixed bugs with removing Terrifying trait.","Fixed bug with items in queue blocking the next item when it couldn't be completed due to negative production of a resource.","The Tax-Morale governor task is now slightly smarter."]},{version:"1.1.14",revision:"a",date:"9/30/2021",changes:["Fixed Pylon bug with upgraded save games in Magic Cataclysm runs.","Fixed a Message Log filtering problem where some players might not unlock some options."]},{version:"1.1.14",date:"9/29/2021",changes:["New settings options for message log filters.","Added Cracked Pylons for Magic Cataclysm mode.","Conjuring is no longer researchable in Cataclysm mode.","Challenges section added to Wiki under Gameplay.","Smoldering Gnawer will now consume Stone instead of nothing."]},{version:"1.1.13",date:"9/5/2021",changes:["Expanded Mechanics entries in wiki.","Fixed some errors in wiki prestige calculators.","Added a Custom Lab calculator to wiki under species."]},{version:"1.1.12",date:"8/19/2021",changes:["Training Timer for Military tab.","Draggable config options for Spy Operator.","Bug fixes for log and queue windows."]},{version:"1.1.11",date:"8/12/2021",changes:["ARPA projects now contribute to inflation.","Mercenaries costs are now affected by inflation.","Trade is now affected by inflation.","Casino income is now affected by inflation.","Luxury Goods income is now affected by inflation.","Rescaled inflation levels.","Wheelbarrow achievement now requires $250 billion.","Inflation bug fixes.","New message log filters.","Fixed Luxury Goods tooltip money value."]},{version:"1.1.10",date:"8/8/2021",changes:["Added Inflation Challenge Mode. Requires Scrooge achievement to unlock.","Import/Export race feature added to Ascension lab.","Added merge options for queue.","Available space in queue is now shown.","Added Blackhole + Mass Ejector mechanic entry to wiki.","Fixed some display bugs with Alchemy.","Fixed bug where Protoplasm could be required by some structures late in hell phase."]},{version:"1.1.9",date:"7/7/2021",changes:["Firework festival bug fix for cataclysm mode."]},{version:"1.1.8",date:"7/3/2021",changes:["Added firework festival event (July 4th - July 8th).","Added Copper and Iron settings to Mass Ejector Optimizer task.","Current Quantum Level now shown on Citadel Stations.","Updated wiki prestige calculators.","Added a Quantum Level section to wiki."]},{version:"1.1.7",date:"6/29/2021",changes:["Added a Mass Ejector Optimizer governor task.","Fixed precision error with Tech Scavengers.","Prestige calculators added to wiki.","Progress related event section added to wiki.","Anti-plasmids gained from MAD in antimatter universe are now correctly calculated."]},{version:"1.1.6",date:"6/19/2021",changes:["Solstice event is now easier for less seasoned players.","Wharves are no longer affected by the Nomadic trait.","Decreased cost of Iron Horseshoes."]},{version:"1.1.5",date:"6/16/2021",changes:["Support for String Packs.","Separate research queue behavior option.","Balorg can now use the governor tax task."]},{version:"1.1.4",date:"6/11/2021",changes:["Fixed a bug that would sometimes cause mechs to be constructed without weapons.","Fixed a bug that would cause an open tooltip to change descriptions when a queue item completes."]},{version:"1.1.3",date:"6/7/2021",changes:["Improvements to tooltip reliability.","The first Horseshoes can now be constructed out of Lumber if available as a resource.","Horseshoe pacing updated, see Hooved entry in wiki for expanded information."]},{version:"1.1.2",date:"6/6/2021",changes:["Added Money Reserve % config value to Slave replacement task.","Various special buildings are now dropped from the queue if you remove their required trait.","Spy Operator will no longer attempt espionage against controlled cities.","Fixed many issues with labels not updating"]},{version:"1.1.1",date:"6/5/2021",changes:["Unifying during banana republic now triggers an automatic backup save.","Holding a key multiplier with the queue key will now queue mulitple of a building.","Dealmaker import bonus buffed from 40% to 75%.","Nerfed Beast trait to 8% hunting / 15% windy hunting / 10% soldier training.","Restored Cautious trait to Carnivore genus.","Added Money Reserve % config values to Merc and Spy recruiter tasks.","Horseshoes can now be queued.","Adamantite Horseshoes are now much cheaper.","Changed progression system for Horseshoe costs, will not change to next resource unless it's unlocked."]},{version:"1.1.0",date:"6/4/2021",changes:["Appoint a Governor to help run the everyday tasks, unlock in the CRISPR lab.","Animal genus split into 2 new beast genus: Carnivore & Herbivore.","Carnivore Species: Cath, Wolven, Vulpine.","Herbivore Species: Centaur, Rhinotaur, Capybara.","Cath, Wolven, and Centaur redesigned.","Spire Mech Combat rebalanced.","Titan mechs now have 4 weapon slots and an extra equipment slot.","New Equipment: Jump Jet (All but Heavy & Titan), Battery (Heavy Only), and Targeting Computer (Titan Only).","New Scavenger mech type","Reweighted Angelic genus trait costs.","Major event messages are now shown in a different color from minor ones.","Decreased frequency of minor events.","Smoldering no longer applies to a variety of special resources.","Frenzy renamed to Blood Thirst.","Madagascar Tree achievement now requires inheriting Blood Thirst instead of Carnivore.","Expanded Hell section of Wiki"]},{version:"1.0.43",date:"5/18/2021",changes:["Banana Smoothie will no longer unlock for free in alternate universes.","Added a Spire Floor clear timer for previously beaten monsters.","Gate Turrets now correctly contribute to demon kills."]},{version:"1.0.42",date:"5/4/2021",changes:["Minor bug fixes with new events."]},{version:"1.0.41",date:"5/3/2021",changes:["Added launch day event for May 6th.","New minor event system.","The same event can no longer trigger twice in a row."]},{version:"1.0.40",date:"4/11/2021",changes:["Special event race reskins will now persist after event ends until reset.","Added a warning to Unification tech if playing Banana Republic scenario."]},{version:"1.0.39",date:"4/9/2021",changes:["Added challenge win conditions to planet description popover."]},{version:"1.0.38",date:"4/4/2021",changes:["Fixed a bug that prevented some races from acquiring Egg #3."]},{version:"1.0.37",date:"4/3/2021",changes:["Fixed a bug with unlocking the Egg Hunt feat."]},{version:"1.0.36",date:"4/1/2021",changes:["Fool Feat will automatically upgrade to current challenge level for eligible players."]},{version:"1.0.35",date:"3/31/2021",changes:["Changed Blackhole objective of Banana Republic scenerio from stabilize a blackhole to Expand a blackhole to 12 solar mass without exotic matter.","Fixed Terrifying trade exploit in Banana Republic scenerio."]},{version:"1.0.34",date:"3/28/2021",changes:["Added the Banana Republic challenge.","Tax Riots will no longer cause loss of Artifacts, Blood Stones, and other key resources.","Cancel all routes option for trade screen.","Protests no longer apply their penalty twice.","Minor genetic traits can now be reordered by dragging.","Max trade routes per resource type are now governed by Large Trade and Massive Trade upgrades.","Misc minor bug fixes."]},{version:"1.0.33",date:"3/20/2021",changes:["Enhanced threat assessment for Spire.","Added a Save as File option for exporting game state."]},{version:"1.0.32",date:"3/19/2021",changes:["Unemployment Rework.","Fixed reactivity of some tooltips.","Fixed cut off tooltips on settings tab.","Xeno Tourism now requires 10 Monuments and Tourism."]},{version:"1.0.31",date:"3/15/2021",changes:["Alien 1 system is now named after their homeworld.","Alien 2 system is now named after their red planet.","Fixed various cut off tooltips."]},{version:"1.0.30",date:"3/4/2021",changes:["Wharves once again now grant the correct number of trade routes.","Fixed errors with Casino vault size.","Sacrificed Citizens stat for Mantis players.","Factory production can be assigned without first removing it from Alloy production."]},{version:"1.0.29",date:"2/25/2021",changes:["Evolved species will no longer be stuck in the queue after evolution.","Fixed potential viewport scrolling issues with Settings and Evolution tabs.","Added a warning for users running Evolve in multiple tabs.","The game will now remind players to backup their game data once every 100,000 game days."]},{version:"1.0.28",date:"2/21/2021",changes:["Queue can now be used during evolution stage if unlocked with CRISPR tech.","Fixed incorrect Scarletite costs with Wasteful trait.","Graphene Plants now default to Oil with Smoldering.","Fixed many string errors."]},{version:"1.0.27",date:"2/11/2021",changes:["Added Trade Federation achievement.","Added Mastery section to perks page.","Fixed aria label of jobs.","Squished achievement will now unlock from Blackhole or Demonic Infusion."]},{version:"1.0.26",date:"1/30/2021",changes:["Enhanced crafted material popovers.","Universe filters for wiki achievements page.","Cheese Guide."]},{version:"1.0.25",date:"1/23/2021",changes:["Added Piracy section to Wiki under Gameplay-Mechanics.","Numerous minor bug fixes."]},{version:"1.0.24",date:"1/17/2021",changes:["Evil Smoldering races can now research bone tools."]},{version:"1.0.23",date:"1/16/2021",changes:["Redesigned Heat based Genus mechanics.","Untapped Potential formula changed: now has diminishing returns for stacking unspent genes.","Faith now has an effect on auto crafting (Craftsmen Only).","Added new topics to Mechanics section of Wiki.","Minor bug fixes."]},{version:"1.0.22",date:"1/15/2021",changes:["Fixed Cataclysm mode game start."]},{version:"1.0.21",date:"1/10/2021",changes:["Gain upto 8 hours of accelerated time when game is stopped/closed.","Optimized tab content loading for performance.","Pause game feature."]},{version:"1.0.20",date:"12/29/2020",changes:["Fixed issue with keyup event not releasing multiplier keys."]},{version:"1.0.19",date:"12/28/2020",changes:["Studious now improves library knowledge by 10%.","Merchant now increases the amount of resources gained from trading by 10%.","Tracker raised from 10% to 20%.","Resourceful raised from 10% to 12%.","Claws raised from 20% to 25%.","Apex Predator combat bonus raised from 25% to 30%.","Forge Geothermal power boost raised from +1MW to +2MW.","Beast trait now boosts Hunting by 10% or 20% when windy and improves soldier training time by 20%.","Beast gene point cost changed from 2 to 3 points.","Top level tab quick selection key bindings (default 1-7)."]},{version:"1.0.18",date:"12/24/2020",changes:["Fixed issue with species costs on some techs requiring protoplasm without a reload."]},{version:"1.0.17",date:"12/19/2020",changes:["Larger font size modes.","Added descriptions for city sectors.","Last 3 event messages will now be preserved on reload.","Fixed Evolution bugs with Unbound Infusion active.","Improved timer accuracy of stacked queue items when No Queue Order is used."]},{version:"1.0.16",date:"12/16/2020",changes:["Dark Bomb: Kill and Reset the Demon Lord's accumulated strength using the new Dark Bomb.","Bonus Artifacts can now be earned during Demonic Infusion if Spire floor 50 or 100 are cleared.","Renamed the tech upgrade Purify to Enhanced Air Filters in order to prevent confusion with the Blood Infusion Purify."]},{version:"1.0.15",date:"12/12/2020",changes:["Redesigned Inferno Reactor, output is now tied to Infernal Forge.","Steel can once again be discovered by Ambush attacks.","Power Grid is now shown in Cataclysm.","Cataclysm reset no longer incorrectly grants Rapid Mutation or Ancient Ruins.","Many minor bug fixes."]},{version:"1.0.14",date:"12/8/2020",changes:["Vacuum Collapse no longer removes all charges of Corrupted bonus.","Vacuum Collapse now correctly increases Dark Energy earned on the stats page.","Lumber Ritual is no longer displayed to Evil races.","Multiplier keys now work when hiring mercenaries."]},{version:"1.0.13",date:"12/4/2020",changes:["Power Grid now correctly unlocks when gaining Electricity from Infiltrator trait.","Feats Garbage Pie and Finish Line can now be unlocked by Demonic Infusion."]},{version:"1.0.12",date:"12/4/2020",changes:["MechBay tab improvements.","Mechlist can now be reordered by dragging.","Power Grid can now control On/Off state.","Support type structures can now be controlled by the power grid."]},{version:"1.0.11",date:"12/2/2020",changes:["Fixed a memory leak.","Minor adjustments to GruvBox Dark theme.","Cheesy Goodness."]},{version:"1.0.10",date:"12/1/2020",changes:["Ascended buff now persists after Demonic Infusion.","New Themes: GruvBox Light, GruvBox Dark, and Orange Soda."]},{version:"1.0.9",date:"11/29/2020",changes:["Perks separated on to a separate tab under Stats.","Added Perks section to Wiki."]},{version:"1.0.8",date:"11/28/2020",changes:["Base Neutronium cost of Inferno Reactor lowered to 3,750,000.","Fixed Valdi genus traits after evolution.","Prepared rank 2 now correctly applies when building mechs.","Power Grid is now more strict in checking what is available.","Fixed bug that sometimes caused crafting to use a wrong Mastery value."]},{version:"1.0.7",date:"11/25/2020",changes:["Fixed a bug where Technocracy prevented Alien 2 & Chthonian invasions from working."]},{version:"1.0.6",date:"11/24/2020",changes:["Fixed Mechlab quick switch button.","Titan class mech power increased by 12.5%."]},{version:"1.0.5",date:"11/22/2020",changes:["Adjustable Power Grid","Light Theme bug fixes."]},{version:"1.0.4",date:"11/21/2020",changes:["Gains from Alchemy are now higher.","Any mixed fleet can now invade the Alien 2 and Chthonian systems as long as the invasion force is strong enough.","Alien 2 Invasion requires minimum of 400 fleet rating and at least 650 to take no losses.","Chthonian Invasion requires a minimum 1250 fleet rating, 2500 for average losses, and 4500 for minimum losses."]},{version:"1.0.3",date:"11/15/2020",changes:["Fixed compost heap values.","Added combat section to the wiki under gameplay.","Added Equilibrium feat for pillaring every species.","The Misery feat can now be earned from Demonic Infusion."]},{version:"1.0.2",date:"11/10/2020",changes:["Valdi now take your chosen Genus instead of humanoid.","Wrath Blood Infusion now properly applies to all Mech fights.","Artifacts can now be spent properly on the CRISPR tab.","Crystal trade prices adjusted.","Megalith base price reduced from 100k to 55k.","Many minor bug fixes."]},{version:"1.0.1",date:"11/08/2020",changes:["Fixed display bug with CRISPR costs and Technocracy.","Fixed issue with some Windmills not producing power.","The Resort now properly formats its vault size."]},{version:"1.0.0",date:"11/07/2020",changes:["Expanded Interdimensional content, delve deep into the hell dimension.","New Magic Universe.","Fling asteroids into the blackhole with the Asteroid Redirect ARPA project.","The same monument type will no longer be chosen twice in a row.","Evil races can now construct a Pillar of Bones monument type.","Democracy now only affects Entertainers.","Some government bonuses now scale with tech era.","Races with Detritivore can now build Windmills.","Base Aluminium income for plant based species is now roughly 10% higher.","Beast of Burden now grants an extra loot roll instead of a 10% boost.","Revamped combat loot formulas.","Build queue resource highlighting.","Low Contrast Dark Night Theme.","Ewnay igpay atinlay anguagelay."]},{version:"0.9.24",date:"11/1/2020",changes:["Holiday icons from feats earned with no stars can now be accessed.","Challenge feat icons still require at least 1 star."]},{version:"0.9.23",date:"10/30/2020",changes:["New settings option for people who hate fun.","Added ability for an obscure combination of settings and racial traits to get Ghost #3"]},{version:"0.9.22",date:"10/28/2020",changes:["Halloween cosmetic effects will now run for the duration of the Trick or Treat event instead of just on Halloween.","Ents, Dryads, and Salamanders can now find all the Ghosts.","A certain Ghost is now easier to obtain in Cataclysm.","Accessibility improvements for the event."]},{version:"0.9.21",date:"10/27/2020",changes:["Trick or Treat Event, runs from 10/28 - 11/4."]},{version:"0.9.20",date:"10/16/2020",changes:["Fixed bug with the holy trait that improperly applied its bonus."]},{version:"0.9.19",date:"9/1/2020",changes:["Swarm Control AI now provides a base increase of +2 before unlocking Quantum Computing.","Fixed bugs with manual crafting popover.","Fixed bug that stopped DNA & RNA generation during evolution if the Cataclysm scenario was toggled on."]},{version:"0.9.18",date:"8/28/2020",changes:["ARPA Queue timer fixes.","Swarm Control AI upgrade now make Control Stations scale with Quantum level."]},{version:"0.9.17",date:"8/22/2020",changes:["Fixed bug that prevented Cataclysm Ascension from completing.","Rank 1 sacrifice is slightly less effective","Rank 3 sacrifice is significantly more effective","New Research is now shown by Era."]},{version:"0.9.16",date:"8/12/2020",changes:["Bug Fixes by Beorseder:","Fixed issue where Exotic Materials Lab and Fortifications would clear current queue.","Fixed Scavengers not working during Cataclysm.","Fixed display bug with Galactic Exchange during Cataclysm.","Genomic Mutations no longer give the wrong number of Genes without Synthesis upgrades.","Genomic Mutations now tell how many Plasmids/Antiplasmids are gained from them.","Techs now display their requirements on the wiki."]},{version:"0.9.15",date:"8/10/2020",changes:["Tax revolts can no longer destroy Soul Gems.","If you lose your sample of Elerium before researching Elerium Mining it will now be replaced."]},{version:"0.9.14",date:"8/9/2020",changes:["Angelic races now have an innate bonus vs demonic creatures.","Enhanced Muscle Fibers added to perks page.","Genome sequencing will now be off by default in Cataclysm.","Reorganized achievements page in Wiki."]},{version:"0.9.13",date:"8/6/2020",changes:["Special resource descriptions now update."]},{version:"0.9.12",date:"8/3/2020",changes:["Added Crossed the Finish Line feat for Ascending with Cataclysm.","Adjusted many post World Collider Cataclysm things that referenced none existent planetary structures.","Added a fix for Stabilize Blackhole being stuck in an untriggerable state.","Upgrading achievements will now send a notification."]},{version:"0.9.11",date:"8/1/2020",changes:["Fixed a bug that caused Factories to charge the wrong amount of Polymer for producing Synthetic Furs."]},{version:"0.9.10",date:"7/30/2020",changes:["Expanded list of potential enemy city names.","Added Synthetic Fur option to Factories.","Restoring a backup after a Cataclysm will now allow you to Cataclysm again.","Fixed Lumber penalty on Desert worlds.","Many minor bug fixes."]},{version:"0.9.9",date:"7/21/2020",changes:["Added Devotion upgrade to ancients CRISPR line between Faith and Acolyte. The total cost is the same, it's just spread out more.","Players with Ancients 4 are granted Ancients 5 automatically, those with Ancients 3 are refunded 300 Plasmids.","Added Enhanced Muscle Fiber CRISPR upgrade.","High tax morale penalty under Oligarchy is now reduced.","Fixed bugs with Blackhole reset and restoring backups.","Fixed bug with adjusting taxes as a Noble race that would set it to the max."]},{version:"0.9.8",date:"7/18/2020",changes:["Czech translation by Mousesama","The slaves have staged a successful hunger strike to demand better living conditions, as a result slave pens can now only hold 4 slaves each.","Autocracy and Frenzy no longer block Immoral races from gaining a Warmonger bonus.","Geology traits now display under planet information.","Popovers added to building and research queues."]},{version:"0.9.7",date:"7/13/2020",changes:["Seasons no longer exist in Cataclysm mode.","It is no longer Sunny in Cataclysm mode.","Parasites are no longer unable to grow population in Cataclysm mode, but they do take a growth penalty.","Base Sawmill effect is now separated from lumberjack in production breakdown."]},{version:"0.9.6",date:"7/10/2020",changes:["Fixed bug with Infiltrator not unlocking Nanoweave.","Fixed bug with Railways not adding traderoutes correctly in Cataclysm mode."]},{version:"0.9.5",date:"7/6/2020",changes:["Fixed a bug that occurred when combining the Terrifying trait with the gold star Iron Will perk."]},{version:"0.9.4",date:"7/3/2020",changes:["Failed History perk raised from +1 Geothermal to +2 Geothermal energy.","Fixed Oligarchy tax riot immunity between 36%-45%.","Infiltrator can now steal Graphene Processing, Nanoweave, and Orichalcum Analysis techs."]},{version:"0.9.3",date:"7/1/2020",changes:["Increased base number of Plasmids earned in Cataclysm mode."]},{version:"0.9.2",date:"6/30/2020",changes:["Added Restore Backup option, restores game to just before your last prestige reset.","Extended Recombination CRISPR line.","When gaining a random minor trait from Fanaticism, you will now gain 5 ranks of it."]},{version:"0.9.1",date:"6/21/2020",changes:["Fixed Dyson Net."]},{version:"0.9.0",date:"6/21/2020",changes:["Added Scenarios Section to Evolution Challenges.","Added Cataclysm Scenario for those who value science over caution.","Genetic Dead End is now classified as a Scenario.","Plant genus redesign. Photosynth trait replaced with Sappy.","Added 3rd race option for Plant genus: Pinguicula.","Dyson Net now provides partial power as it is constructed.","Added Orichalcum upgrade for Dyson Sphere.","Added Xeno Tourism upgrade.","Added Fertility Clinic upgrade for Hospitals.","Added OTB, Online Gambling, & Bolognium Vault upgrade for Casinos.","Added Scrooge achievement.","Added Soul Link upgrade for Soul Forge/Soul Attractors.","Reduced Bolognium cost of Freighters & Corvette Ships.","Increased rating of Corvette Ships to 30.","Piracy will no longer start until after you construct the Embassy.","Reduced power requirement of Soul Forge and Soul Attractor.","Gun Emplacements and Soul Attractors are now more potent.","Reduced requirement of Demon Slayer feat to 666 Million demon kills."]},{version:"0.8.17",date:"5/30/2020",changes:["Added 3rd race option for Fungus genus: Moldling.","Fungi genus Spore trait replaced with Detritivore.","Casinos now start powered and generated money immediately.","Extreme Dazzle upgrade now boosts Casino income by 50%.","Reduced power requirement of Casino by 1.","Casino Max Morale boost no longer works unless casino is powered.","Occupation will now unlock Federation research.","Added Double Density achievement in heavyverse.","Stoned penalty on mellow planets raised to 10%.","Unemployed citizens on mellow planets no longer generate any stress (note: hunters are NOT unemployed).","Life on mellow planets is now overall less stressful.","Slaver trait rating raised to 12.","Barracks can now be switched off.","Space Stations will now automatically staff Space Miners from the default job when constructed.","Factories now default to producing Alloy instead of Nothing."]},{version:"0.8.16",date:"5/8/2020",changes:["Oceanic biome now applies a 6% bonus to Titanium from Steel smelting.","Oceanic biome now applies a 12% bonus to Titanium from Iron smelting.","Oceanic biome now applies a 5% penalty to Fur generation.","Tundra biome now applies a 25% bonus to Fur generation.","Tundra biome now applies a 10% penalty to Oil generation.","New planetary modifiers: Elliptical, Flare, Dense, and Unstable.","Oligarchy tax riot immunity raised from 35% to 45%."]},{version:"0.8.15",date:"5/2/2020",changes:["Grassland biome Food bonus raised to 20%.","Forest biome Lumber bonus raised to 15%.","Desert biome now applies a 25% Lumber penalty.","Desert biome now gives a 20% stone bonus and a 10% Oil bonus.","Volcanic biome now applies a 10% Food penalty.","Volcanic biome now gives an 8% Iron and 12% Copper bonus.","Added partial Korean translation.","Achievements in the wiki are now sorted Alphabetically.","Some achievements now show completion progress in the wiki."]},{version:"0.8.14",date:"4/30/2020",changes:["Post unification Federation now gives a 32% bonus (raised from 30%).","Federation now increases morale by 10%.","Socialist factory bonus is now 10% (raised from 5%).","Socialist crafting bonus is now 35% (raised from 25%).","Corpocracy factory bonus is now 30% (raised from 20%).","Corpocracy factory bonus now applies to Cement, Graphene, and Vitreloy.","Republic now increases morale by 20%.","Oligarchy tax revenue penalty is now 5% (lowered from 10%).","Oligarchy can now set taxes 20% higher then other governments (raised from 10%).","Technocracy now adds a 10% Knowledge gain bonus.","Autocracy governments are now immune to the warmonger penalty.","Priests now apply a bonus to Ziggurats under Theocracy.","Fixed display of Theocracy effect on temples. This gives a 12% bonus but was only displaying as a 5% increase.","Noble Oligarchy can now set their taxes as high as 40%."]},{version:"0.8.13",date:"4/29/2020",changes:["New research is now sorted by knowledge cost.","Added popover descriptions for prestige resources.","Harmony Crystals now boost standard Dark Energy by 0.1% instead of 0.01%.","Lots of minor bug fixes."]},{version:"0.8.12",date:"4/24/2020",changes:["Farming has been redesigned. Farms no longer directly generate food, Farmers now generate food in combination with Farms.","Added Energizer Feat for ascending without building any Thermal Collectors.","Bad traits no longer count for Ascension Species Creator complexity.","Dreaded Achievement will now unlock if you never researched dreadnoughts.","Fixed issue with some feats spamming the log due to micro achievements.","Fixed base training rate of soldiers.","Fixed bug with diverse trait that made it do the opposite of what it was suppose to do.",'Adjusted color of "purple" text on Night theme.',"Kilowatts are now Megawatts."]},{version:"0.8.11",date:"4/16/2020",changes:["Ascension reset no longer offers planet choices, instead your next race is created on the old planet with bonuses added to that planet.","Ascended planets now gain +2% to all geology deposits, +5% production, +10% storage, and +2 Sundial base Knowledge gain.","Unspent gene points in the Ascension Lab will be converted into Untapped Potential.","Ascension lab now has a complexity gene tax for adding more then 4 traits.","Technophobe perk now applies an additional bonus to custom race complexity.","Paranoid and Hoarder can now be combined.","Over capped slaves will now be released."]},{version:"0.8.10",date:"4/13/2020",changes:["Added EM (Electromagnetic) Field Challenge."]},{version:"0.8.9",date:"4/12/2020",changes:["Added a Feat for finding all the Eggs.","Current egg count can now be checked in the Wiki."]},{version:"0.8.8",date:"4/12/2020",changes:["Easter Event Activated","Event ends 10 days after the start of Easter."]},{version:"0.8.7",date:"4/11/2020",changes:["Fixed Pathetic trait."]},{version:"0.8.6",date:"4/11/2020",changes:["Fixed Brute trait.","Added section for Achievements and Feats to Wiki."]},{version:"0.8.5",date:"4/11/2020",changes:["Added New Work in Progress Game Wiki","Sentience is now more likely to grant a species where the extinction achievement has not yet been earned.","Sentience can now include custom races.","Incorporeal Existence research now costs Phage instead of Plasmids.","Ascension research now Plasmids instead of Phage.","The change log is now part of the Wiki."]},{version:"0.8.4",date:"4/4/2020",changes:["Fixed breaking bug with Rigid trait."]},{version:"0.8.3",date:"4/3/2020",changes:["Federation now reduces the soldier requirement of occupied cities by 5.","Fixed incorrect Industrious string."]},{version:"0.8.2",date:"3/30/2020",changes:["Piracy in the Gateway and Stargate regions ramp up more slowly as you explore Andromeda.","Fixed formatting of multiline Crafting Tooltip cost display.","Fixed incorrect string used by completed Dyson Sphere."]},{version:"0.8.1",date:"3/29/2020",changes:["Piracy now slowly takes effect in the Gateway System and Stargate region over 1000 days after piracy begins.","Purchasing Negotiator and levels of Persuasive will now update the regular Market as well as the Galactic Market.","Added new CRISPR upgrade effects from the Challenge, Ancients, and Trader trees to the perks list.","Queued Monuments will update their name in the queue when a Monument is constructed.","Fixed bug where ARPA projects at the end of the Queue while No Queue Order was active would cause No Queue Order to not work as intended.","The name of the trait gained from a Mutation in the message is now localized.","Adding Apex Predator will remove currently obtained Armor techs.",'Annexed/Purchased powers will now have a respective " - Annexed"/" - Purchased" tag next to their name, like Occupied powers do.',"Blackhole reset gives its proper reward again.","The amount of Gene/Phage levels of Minor Traits purchased is now affected by Multiplier Keys.","The amount of Ships moved from one area to another is now affected by Multiplier Keys.","Manual Crafting button tooltips are more informational.","Constructing the first Foundry of a game will log a message briefly explaining what Crafted Resources are and the ways to make them.","Informative messages (mission results, messages that explain newly unlocked mechanics, the Launch Facility message that informs the player of the space tab, etc.) are now displayed in blue, to separate them from less important messages.","Added the missing Wormhole Mission result string."]},{version:"0.8.0",date:"3/27/2020",changes:["Intergalactic Content.","Universe Mastery Rework.","-Each Universe now tracks its own mastery level responsible for 40% of the mastery bonus, the remaining 60% comes from the general mastery level.","-Standard Universe mastery rules remains unchanged.","Micro icons can now be earned for none Micro achievements. These will not count for standard mastery, only Micro mastery.","Unification 3.0, the unification system has been reworked.","Federation Government type.","New Faith CRISPR line of upgrades, unlocks priest job.","Universal, Standard and Mastered CRISPR Upgrades, for masters of the universes.","Added Negotiator CRISPR upgrade.","Added Persuasive Minor Gene.","Extended the Deify and Study Ancients tech trees.","Enhanced Droids upgrade for War Droids.","Repair Droids for Fortress.","Smoldering and Chilled now have reduced effectiveness after 100 stacks.","Removed Heavy Genus Feats, these were redundant with Universe Icons.","Blackhole reset now also grants species level extinction achievement.","Power cost of Mass Ejector increased to 3kW.","Genetics lab custom mutation costs rescaled to static values depending on the genetic trait.","Colonists will now be automatically assigned when a Living Quarter is completed if the default job has any available citizens.","Biodome redesigned, produces less food but increases living quarter capacity for Citizens.","More robust research categories.","Various racial traits now apply to ARPA projects.","Human Creative trait rescaled.","Large cost creep penalty reduced to 0.005 from 0.01.","Strong gathering bonus increased from 2 to 5.","Compact lowered from -0.02 to -0.015."]},{version:"0.7.28",date:"3/16/2020",changes:["Antimatter Universe now gives a 10% prestige bonus post MAD.","St. Patrick's Day event.","Blood War can no longer be earned by none demonic evil races.","Build Crate/Container buttons now update create/container values when upgraded by research."]},{version:"0.7.27",date:"3/10/2020",changes:["Memory leak fixes."]},{version:"0.7.26",date:"3/5/2020",changes:["Any race where the associated extinction achievement has been unlocked is now always available during evolution.","Joyless perk changed to +2% Max Morale per star level.","The effects of the Mass Extinction and Creator perks have been swapped.","Creator perk (old mass extinction) changed to 1.5x / 2x / 2.5x / 3x / 3.5x genes gained on mutation.","Minor traits bought with Phage now count twice when you complete evolution."]},{version:"0.7.25",date:"2/26/2020",changes:["Unicorn Shrine bonus is now determined by the moon phase when constructed.","Shrine Knowledge bonus now applies an additional affect to universities.","Smelters in Evil universe when using Kindling Kindred default to Flesh instead of Coal.","Evil Wendigo Smelters correctly display that they use 1 Flesh/s instead of 3 Souls/s. Also fixed the bug where they end up using 3 Flesh/s instead of 1.","Fixed bug where the Evil Wendigo Reclaimer description would show the Lumberjack description.","If Containers have not yet been unlocked as a resource, getting a Wharf will unlock it.","Fixed bug where, if Freight Trains was gotten after ARPA, the Railway project would need a refresh to appear."]},{version:"0.7.24",date:"2/12/2020",changes:["Special Prestige icons awarded to players from certain feats can now be set to replace the standard Star icon."]},{version:"0.7.23",date:"2/11/2020",changes:["Steelen Challenge now requires Bioseed as its win condition.","Added Feat for Blackhole reset with Steelen Challenge.","Added V-Day Event stuff."]},{version:"0.7.22",date:"2/9/2020",changes:["Steelen Challenge.","Graveyards are now removed upon gaining Kindling Kindred.","If Default job is set to Farmer/Lumberjack for Carnivore/Kindling Kindred, it will be changed to Unemployed upon adding those traits.","Fixed bug where gaining Carnivore and having no Grain Mills would make Smokehouses unpurchasable until refresh.","Cargo Yard now requires the construction of a Transfer Station to be unlocked.","Mitosis/Metaphase effect now appears on perks list."]},{version:"0.7.21",date:"1/28/2020",changes:["More bug fixes."]},{version:"0.7.20",date:"1/20/2020",changes:["Bug Fixes by Beorseder.","Fixed bug where purchasing Multicellular would double DNA generation from Nuclei instead of Bilateral Symmetry/Poikilohydric/Spores.","New population from the Infectious trait now go into the set Default job, instead of always Unemployed.","Controlled Mutation will no longer offer conflicting traits."]},{version:"0.7.19",date:"1/14/2020",changes:["Bug Fixes."]},{version:"0.7.18",date:"1/12/2020",changes:["Theocracy temple bonus raised from 5% to 12%.","Technocracy knowledge discount raised from 5% to 8%.","Corpocracy Casino Bonus raised from +100% to +200%.","Corpocracy Luxury Good Bonus raised from +50% to +150%.","Corpocracy Tourism Bonus raised from +50% to +100%.","Corpocracy morale penalty lowered from -15% to -10%.","Corpocracy Manufacturing Bonus raised from +15% to +20%.","Miner's Dream now scales the information that is revealed depending on the star level of the achievement.","Slaves now appear as a resource.","Alternate universes now award icons for complex achievements."]},{version:"0.7.17",date:"1/9/2020",changes:["Fixed an issue with displaying foreign powers in civics tab on unlock."]},{version:"0.7.16",date:"1/8/2020",changes:["Exploration Missions can be queued again.","The game will now notify the user if the current version is out of date.","Changes by Beorseder.","Geology deposit aesthetic changes on planet selection.","Miner's Dream Achievement & Perk."]},{version:"0.7.15",date:"1/7/2020",changes:["Queueing the World Collider will no longer lag the game.","Multi-segment projects will now have extra segments cleared from the queue on completion.","Spy and Government related popovers that would sometimes get stuck open will now clear.","Queued projects that will not complete due to lack of production will now display a green [Never] instead of -1 second timer.","Multi-segment projects no longer block queueing ARPA projects unless they consumed the entire queue space."]},{version:"0.7.14",date:"12/31/2019",changes:["Research Categorization option by Naryl."]},{version:"0.7.13",date:"12/30/2019",changes:["Gene decay will no longer result in a negative plasmid count.","Gene fortification is slightly more effective."]},{version:"0.7.12",date:"12/19/2019",changes:["Gene Fortification.","Fixed Cultural Supremacy popover."]},{version:"0.7.11",date:"12/15/2019",changes:["Decaying resources will now use a warning color if you are losing that resource but at a slower rate then the decay rate.","The most bottlenecked resource will now display in red while other trouble resources will be marked with an alert color.","CRISPR upgrades are now darkened when unaffordable.","Transfer Station now lists its uranium storage.","Wendigo bug fixes."]},{version:"0.7.10",date:"12/12/2019",changes:["Craftsman now continuously output product instead of once/twice a month.","Cumulative achievements now check for lower tier unlocks."]},{version:"0.7.9",date:"12/7/2019",changes:["Many bug fixes."]},{version:"0.7.8",date:"12/6/2019",changes:["The default job can now be set to: Unemployed, Farmer, Lumberjack, Quarry Worker, or Scavenger.","New line of feats for achievement hunting.","Novice Perk.","Journeyman Perk."]},{version:"0.7.7",date:"12/5/2019",changes:["Super projects now queue in larger batches.","Super projects now only report completion by the queue if actually complete instead of for each segment constructed."]},{version:"0.7.6",date:"12/2/2019",changes:["Adjacent queue items of the same type will now combine.","Architect now doubles queue sizes instead of adding a flat +2.","Misc minor bug fixes."]},{version:"0.7.5",date:"11/28/2019",changes:["Queueing 2x or more of the same building in a row will now stack them in the queue.","Queue timer now adjusts for cost creep.","ARPA Projects can now be queued.","Fixed a bug that could break the game when Yeti or Wendigo unlocked the genetics lab."]},{version:"0.7.4",date:"11/27/2019",changes:["Wendigo can now build hunting lodges.","Trade route prices are now tracked to 1 decimal.","Elusive spies will no longer be killed when they fail a mission.","Disruptor Rifles now require researching Quantum Entanglement."]},{version:"0.7.3",date:"11/26/2019",changes:["Night Theme trade volume control made more night theme friendly.","Contrast improvements for Night and R/G Theme."]},{version:"0.7.2",date:"11/24/2019",changes:["New market buy/sell volume control.","Large Trade upgrade now raises the buy/sell cap to 5,000.","Massive Trades upgrade now raises the buy/sell cap to 1,000,000.","Various bug fixes by Beorseder."]},{version:"0.7.1",date:"11/23/2019",changes:["Garrison controls reintegrated into government section.","Mutation plasmids now track correctly in no plasmid challenge runs.","Fixed many issues with foreign power name generation.","Feat star icon is no longer tiny."]},{version:"0.7.0",date:"11/21/2019",changes:["Establish a Government.","Battle rival cities.","Biome races added for Forest, Desert, Tundra, and Volcanic.","New ARPA Project: Railway.","New CRISPR upgrades: Mitosis & Metaphase.","Construct advanced AI stations in deep space.","Rapid Gene Sequencing upgrade.","Civics tab split into Government, Industry, and Military sections.","Inspiration no longer adds an upfront knowledge bonus.","Vigilante requirement lowered to 12.","Xenophobic replaced with Wasteful.","Added Rocky Road Feat.","Configurable number notations."]},{version:"0.6.27",date:"11/12/2019",changes:["Tundra planets are now always cold in winter.","Volcanic planets are now always hot in summer.","Stormy planets are now more likely to be windy.","Fixed issue with last rites not showing up as affordable.","2-4x Challenge Multipliers changed:.","2 Challenges: +12% Prestige.","3 Challenges: +25% Prestige.","4 Challenges: +45% Prestige.","Heavy Universe prestige bonus now scales with challenge level:.","0 Challenges: +5% Prestige.","1 Challenge: +10% Prestige.","2 Challenges: +15% Prestige.","3 Challenges: +20% Prestige.","4 Challenges: +25% Prestige."]},{version:"0.6.26",date:"11/7/2019",changes:["ARPA costs now update without mousing off and back on the buttons.","Fixed issues with incorrectly powering on newly built structures.","None-demonic evil smelters now correctly state they burn 1 flesh/s.","Added whitehole perk to stats page."]},{version:"0.6.25",date:"11/2/2019",changes:["Geology bonus is now preserved on MAD reset.","Key Mappings are now configurable for multiplier and queue keys."]},{version:"0.6.24",date:"10/31/2019",changes:["The Halloween feat will now unlock inside a micro universe."]},{version:"0.6.23",date:"10/28/2019",changes:["Exotic mass now counts towards Galactic Landfill and Supermassive.","Fixed issues with queue timers and kindling kindred trait.","Dark Energy now applies to windmills in antimatter universe."]},{version:"0.6.22",date:"10/26/2019",changes:["Game optimizations.","Bug fixes for queues.","Fixed bug with war droids."]},{version:"0.6.21",date:"10/24/2019",changes:["Freight Train upgrade now adds a trade route to freight yards instead of trade posts.","Toxic troll achievement.","Spatial reasoning rounding fix."]},{version:"0.6.20",date:"10/21/2019",changes:["Fixed application of plasmids with antiplasmids.","Updated description of bleeding effect.","Added achievement for synthesizing an anti-plasmid.","More readable achievement page."]},{version:"0.6.19",date:"10/20/2019",changes:["Fixed power errors with hell dimension turrets.","Crate/Container rounding is now applied after spatial reasoning.","Added extra text to the asteroid belt description to call out the necessity of assigning space miners.","Evil Ents can now burn flesh in the smelter."]},{version:"0.6.18",date:"10/16/2019",changes:["Swarm Satellite redesign.","Swarm Satellites cost and output decreased.","Control Stations can now control 10/18 swarm satellites.","Iron mining ship swarm plant discount now applies to all swarm plant costs.","New upgrades to increase output of swarm satellites."]},{version:"0.6.17",date:"10/14/2019",changes:['"Q" key now works with research queue.',"Added settings option to not enforce queue order.","Decay challenge no longer shows the star level for Joyless.","All universe types can now be seen on achievements.","Genus completion is now marked on sentience.","Challenges can now be toggled during evolution.","Inspiration event now gives a temporary buff to all science production.","Added Slave Market for slaver races to buy slaves as an alternative to catching them.","Added Crate/Container storage amount to the build crate/container tooltip.","Added a button to cancel all trade routes for each resource."]},{version:"0.6.16",date:"10/13/2019",changes:["Employment is now color coded depending on staffing levels.","GPS satellites now add additional trade routes.","Added stats tracking on reset mechanics used.","Added a message when completing the launch facility.","Added icons to challenges and races in evolution stage to indicate level of challenge completion."]},{version:"0.6.15",date:"10/11/2019",changes:["Added a settings option to disable the queue hot key.","The queue hot key is now disabled by default because it breaks the game for some users."]},{version:"0.6.14",date:"10/9/2019",changes:["Fixed several bugs with celestial races.","Only one demonic invasion event is now required to reach a hellscape planet.","New city categorization can now be switched off in the settings tab.","Holding Q while clicking a building will now queue it instead of constructing it."]},{version:"0.6.13",date:"10/7/2019",changes:["Fixed bioseed reset bug when seeding from a planet without a special property."]},{version:"0.6.12",date:"10/6/2019",changes:["Added a hire merc option to fortress, mercs hired here go directly to the fortress.","Default patrol size is now 10 instead of 4.","Adjusted margins in city tab/space tabs to slightly reduce vertical scrolling.","New Tower of Babel flair."]},{version:"0.6.11",date:"10/5/2019",changes:["New planetary modifiers: Toxic, Mellow, Rage, Stormy, Ozone, Magnetic, and Trashed.","City Categorization by NotOats.","Chinese Translation."]},{version:"0.6.10",date:"10/1/2019",changes:["Fixed issue with gene editing costing the wrong type of Plasmid.","Fixed Bone label in Graphene plant.","Fixed issue with Plywood not unlocking when removing Kindling Kindred trait."]},{version:"0.6.9",date:"9/30/2019",changes:["Antimatter Universe.","Bleeding Effect line of CRISPR upgrades, requires Anti-Plasmids to unlock.","Balorg can now unlock queues.","Fixed aria labels in mass ejector."]},{version:"0.6.8",date:"9/24/2019",changes:["Queue reordering no longer swaps the dragged item with the one in the target spot.","Added timers to research queue.","Cost adjustments are now applied to queue timers increasing their accuracy."]},{version:"0.6.7",date:"9/24/2019",changes:["Cath windmills now generate power instead of just looking pretty.","Fixed Spanish strings file, language now loads again."]},{version:"0.6.6",date:"9/23/2019",changes:["Added special tech tree to sacrificial altar to boost its effectiveness per sacrifice.","Restored windmills to cath.","Challenge Multiplier Dark Energy rounding calculation fixed.","Added extra information to blackhole description when it reaches destabilization point.","Added a warning to stabilize option that it will reset your exotic matter."]},{version:"0.6.5",date:"9/21/2019",changes:["Fixed display issue with frenzy appearing to never drop below 1%.","Updated the tooltip values on farms and farmers to include the hellscape penalty.","Fixed Evil Ents so they start with Gather Stone option."]},{version:"0.6.4",date:"9/19/2019",changes:["Fixed double windmill issue with evil universe races.","Spanish language updates.","Added warnings to challenge modes in micro universe that you will not receive credit."]},{version:"0.6.3",date:"9/17/2019",changes:["Restored broken perks."]},{version:"0.6.2",date:"9/17/2019",changes:["Bug Fixes."]},{version:"0.6.1",date:"9/17/2019",changes:["Universe Update, explore ~~ 4 ~~ 3 new universe types:.","Heavy Gravity Universe.","Micro Universe.","Evil Universe.","New Decay Challenge.","Antimatter universe is still forming, coming soon.","Dark Energy effects added, unique per universe type.","New Plasmid scaling formula.","Blackhole mass added to Stellar Engine.","Stuff I probably forgot about."]},{version:"0.5.18",date:"9/11/2019",changes:["Spanish translation provided by RanaPeluda.","Fixed Ent fanaticism.","Modals are no longer unnecessarily wide.","Smelter modal now shows the fuel production for each type."]},{version:"0.5.17",date:"9/5/2019",changes:["Mantis Frail trait replaced with new Cannibalize trait, eat your own citizens for buffs.","The Fortress will now remember the number of troops assigned to it and attempt to keep it at that level."]},{version:"0.5.16",date:"9/3/2019",changes:["Made some adjustments to Soul Gem drop odds.","Added a message when you discover your first Soul Gem."]},{version:"0.5.15",date:"9/1/2019",changes:["Portuguese translations updated by Rodrigodd."]},{version:"0.5.14",date:"9/1/2019",changes:["Buildings will no longer be added to the queue if holding down a multiplier key.","Fixed a problem with smelters that could cause their production to become stuck in a high state.","Fixed initial display state of containers in storage management tab."]},{version:"0.5.13",date:"8/30/2019",changes:["New layout for selecting challenge genes/modes during end of evolution stage.","Fixed bug with low support elerium miners that caused them to miscalculate miner outputs.","Added a threat level warning to fortress."]},{version:"0.5.12",date:"8/30/2019",changes:["Pacifist Achievement is now unlocked by unifying without ever initiating an attack."]},{version:"0.5.11",date:"8/28/2019",changes:["Fixed issue with nucleus DNA bonus not applying from correct cell stage evolutions.","Building timers now count down without refreshing the popover.","Long action titles will now wrap instead of overflowing the button.","Fixed a bug that could cause the research queue to clear items from the building queue."]},{version:"0.5.10",date:"8/28/2019",changes:["Fixed bug with some construction projects not refreshing the page after being built with the queue.","Space exploration missions can no longer be queued more then once at a time.","One off projects are now removed from the queue if completed manually.","Queue timers now track crafted resources.","Demonic attractor soul gem drop rate increase buffed from 5% to 8%.","Updated some fortress related tooltips.","Mousing over the star rating in the top left corner now lists which challenges are active.","Time until ready added to unaffordable actions."]},{version:"0.5.9",date:"8/27/2019",changes:["Active build queues wiped due do internal game breaking format change."]},{version:"0.5.8",date:"8/27/2019",changes:["Construction timers added to build queue.","Construction and research completed by queues are now logged to the message list.","Improved drag and drop support for queues."]},{version:"0.5.7",date:"8/25/2019",changes:["Drag support for queue sorting.","Fixed resource display bug that occurred when buying a mass ejector.","Minor traits now show the number of ranks from phage or genes spent."]},{version:"0.5.6",date:"8/23/2019",changes:["Building queue now works in space.","Added a separate research queue.","Fixed rock quarry awarding 4% stone bonus instead of the stated 2%.","Fixed rendering bugs with the blackhole and mass ejector."]},{version:"0.5.5",date:"8/22/2019",changes:["Bug Fixes for queueing system."]},{version:"0.5.4",date:"8/22/2019",changes:["Building Queue system v1.0.","Urban Planning, Zoning Permits, and Urbanization queue related techs.","New CRISPR upgrades for enhanced queueing."]},{version:"0.5.3",date:"8/20/2019",changes:["Stats and Achievements separated into separate sub tabs.","Disruptor rifle upgrade for soldiers.","Mass Ejector can no longer be unlocked before completing the Stellar Engine."]},{version:"0.5.2",date:"8/20/2019",changes:["Fixed misnamed mantis trait key.","Fixed Iron smelter paying out 10x intended amount."]},{version:"0.5.1",date:"8/20/2019",changes:["Disappearing craftsman fix."]},{version:"0.5.0",date:"8/19/2019",changes:["Interstellar space is now unlockable.","Interdimensional travel is now unlockable.","New management tab for Crates & Containers.","Power generation breakdown.","Improved resource breakdown layout.","Leathery trait buffed.","Chameleon trait now adds a combat rating bonus.","Optimistic now also applies to the minimum morale rating.","Smarter Smelter fuel switching.","New CRISPR unlocks."]},{version:"0.4.42",date:"8/16/2019",changes:["Fixed some screen reader issues with the crate modal launch button.","Added a warning to the Genetic Dead End challenge if you are on a hellscape planet."]},{version:"0.4.41",date:"8/15/2019",changes:["Joyless Challenge.","??? - Nothing to see here, move along."]},{version:"0.4.40",date:"8/9/2019",changes:["Changed No Crispr gene into the Weak Crispr gene."]},{version:"0.4.39",date:"8/6/2019",changes:["Genetic Disaster Challenge."]},{version:"0.4.38",date:"8/5/2019",changes:["Special action icon is now properly flagged as a button."]},{version:"0.4.37",date:"7/31/2019",changes:["ARIA Improvements for Factory and A.R.P.A."]},{version:"0.4.36",date:"7/27/2019",changes:["Slow and Hyper traits can now combine.","Added new achievements: Creator & Explorer.","Added perks for Mass Extinction, Creator, and Explorer."]},{version:"0.4.35",date:"7/25/2019",changes:["Centaur can now pick Fanaticism.","Challenge multiplier is now applied to phage gain."]},{version:"0.4.34",date:"7/23/2019",changes:["Fixed SR descriptions of buildings that lack affordability.","Fixed resource highlighting of buildings that have zero costs."]},{version:"0.4.33",date:"7/23/2019",changes:["Fixes for Ent Fanaticism not releasing some resources.","Aria improvements for the smelter modal.","Improved screen reader resource affordability description of buildings/research.","Resource highlighting on structures."]},{version:"0.4.32",date:"7/21/2019",changes:["Balorg slaver trait added.","Ziggurat bonus now applies to the oil extractor.","Geology Oil rich/poor no longer applies to oil extractor.","Added resource alternate row coloring.","Added an affordability hint for screen readers.","Fixed some bugs with awarding a random minor trait from fanaticism.","Dimensional Compression now charges the correct cost."]},{version:"0.4.31",date:"7/20/2019",changes:["Extreme Dazzle casino upgrade.","Metallurgist minor trait, buffs alloy.","Gambler minor trait, buffs casinos.","A.R.P.A. projects now use resource approximations for large numbers.","Cement Factory renamed to Cement Plant to reduce confusion with the regular Factory.","Key multipliers now work inside the factory modal.","Imps and Balorg now have access to advanced crafting tech.","Imps and Balorg now have access to windmills.","Balorg can now set their taxes below 10% and above 30%."]},{version:"0.4.30",date:"7/19/2019",changes:["Portuguese translation by Rodrigodd.","DNA Sequencer upgrade.","Gene Assembly cost increase to 200k.","Synthesis now applies a bonus to auto crafted genes.","Ambidextrous buffed.","Ambidextrous now has a greater effect on auto crafting."]},{version:"0.4.29",date:"7/18/2019",changes:["Genetic modification system, customize your race with minor traits.","Shotgun Sequencing upgrade for genome research.","Randomly gained minor traits will no longer stack unless they have all been unlocked.","Genes are now gained from random mutations.","Synthesis line of CRISPR upgrades.","Satellite and Observatory cost reductions.","Fibroblast minor trait.","Iridium is now unlocked by constructing an iridium mine instead of the moon base.","Helium-3 is now unlocked by constructing a helium-3 mine instead of the moon base.","Genome sequencing now defaults to on when first unlocked."]},{version:"0.4.28",date:"7/16/2019",changes:["Added missing hellscape achievement.","Fixed spatial reasoning and phage interaction.","Fixed warmonger unlocking requirement."]},{version:"0.4.27",date:"7/13/2019",changes:["Added special action description buttons for screen readers."]},{version:"0.4.26",date:"7/12/2019",changes:["Unlocked CRISPR upgrades are now listed as perks.","Control/Shift/Alt click now works with power on and off buttons."]},{version:"0.4.25",date:"7/11/2019",changes:["Quantum Manufacturing upgrade.","Quantum Swarm cost lowered from 465k to 450k."]},{version:"0.4.24",date:"7/10/2019",changes:["Thermomechanics upgrade for alloy production.","Ziggurats unlockable via ancients upgrade.","Cement factory has a more clear label in breakdown lists."]},{version:"0.4.23",date:"7/7/2019",changes:["Resources at the millions breakpoint and above are now shown with 2 significant decimal points.","Reduced the creep cost of Observatory.","Reduced the base knowledge cost of Observatory.","Reduced the Brick cost of Boot Camps.","Evil has been unleashed."]},{version:"0.4.22",date:"7/6/2019",changes:["Fixed issue with having exactly 251 Plasmids that would break your resources.","Fixed issue with planet generation that caused it to always use the same seed."]},{version:"0.4.21",date:"7/6/2019",changes:["Fixed unlocking of mass extinction achievement.","Fixed potential fuel consumption bug with power plants."]},{version:"0.4.20",date:"7/4/2019",changes:["Phage can now be earned from space resets, phage extends the plasmid diminishing return breakpoint.","Dimensional Warping crispr upgrade, applies phages to spatial reasoning.","Added special windmill tech for carnivore path to equalize power grid.","Space Stations now give 5 Elerium storage instead of 4."]},{version:"0.4.19",date:"7/2/2019",changes:["Fixed bugs with the hell planet and gas planet survey mission.","Fixed bug that prevented the planet description tooltip from triggering.","Aluminium now properly requires you to build a metal refinery."]},{version:"0.4.18",date:"7/1/2019",changes:["Planets choice now has more depth to it, each planet can be poor or rich in various resource types.","A mineral poor planet suffers anywhere from 1 to 10% penalty for that resource.","A mineral rich planet gains anywhere from 1 to 20% bonus for that resource.","The fire event no longer triggers for aquatic races.","The first interstellar probe now contributes to the number of potential target worlds.","All interstellar space probe costs are now cheaper."]},{version:"0.4.17",date:"6/29/2019",changes:["Added indication of current challenge level to top bar.","Added H tags for accessibility."]},{version:"0.4.16",date:"6/28/2019",changes:["New Hospital, heals wounded soldiers faster.","New Boot Camp, train new soldiers quicker.","Lowered research cost of Mass Driver from 170k to 160k.","Lowered Iridium cost of Mass Drivers.","Updated Mass Extinction unlock requirement."]},{version:"0.4.15",date:"6/28/2019",changes:["Global bonuses are now multiplicative instead of additive.","Decreased base Elerium cost of Exotic Lab by 4.","Creative trait decreases cost creep instead of providing a flat discount.","ARPA 100% button replaced with remaining percentage value.","New experimental military advice."]},{version:"0.4.14",date:"6/27/2019",changes:["Statues now cost Aluminium instead of Wrought Iron.","Nav Beacon now costs Aluminium instead of Iron.","Helium-3 Mine now costs Aluminium instead of Copper.","Elerium Mining Ship now costs Titanium instead of Iridium.","Iron Mining Ship now costs Aluminium instead of Titanium.","Dimension Compression upgrade now works correctly.","Aluminium can now be looted from battle."]},{version:"0.4.13",date:"6/26/2019",changes:["Aluminium resource added to the game, research Bayer Process to unlock Metal Refinery which in turn unlocks Aluminum.","New Metal Refinery structure for producing Aluminium.","Alloy is now made out of Aluminium and Copper.","Sheet Metal is now made out of Aluminium.","Oil Powerplant and Propellant Depot now cost Aluminium instead of Steel.","Some minor accessibility improvements."]},{version:"0.4.12",date:"6/24/2019",changes:["Blackhole achievement now gives a permanent perk for completing it, the perk strength depends on the achievement level.","Fixed issue with event timer being frozen after changing planets.","Fixed the unlocking of upgraded versions of some achievements.","Cost descriptions now show approximations above 10,000."]},{version:"0.4.11",date:"6/24/2019",changes:["Re-evaluated starvation breakpoint.","Added Infested Terran achievement.","Titanium price is now reset after unlocking Hunter Process.","Resources now have a 25% chance of their market price changing per day, up from 10%."]},{version:"0.4.10",date:"6/23/2019",changes:["Fixed stats tracking on demonic invasions so it actually tracks new invasions."]},{version:"0.4.9",date:"6/23/2019",changes:["Fabrication facilities now increase craftsman cap.","Added stats tracking on demonic invasions.","Detail Oriented buffed to 50% from 33%.","Rigorous buffed to 100% from 66%.","Crafting bonus now shown for each resource.","Temple Faith bonus now applies to crafting in no plasmid challenge mode.","Mastery bonus now applies to crafting."]},{version:"0.4.8",date:"6/22/2019",changes:["Fixed a bug that removed MAD when achieving unification.","Fixed missing options in evolution stage with picking avians after space reset."]},{version:"0.4.7",date:"6/21/2019",changes:["Activating challenge genes now provide a bonus to the number of plasmids earned."]},{version:"0.4.6",date:"6/21/2019",changes:["Reduced Nano Tube and Neutronium costs of bioseeder ship.","Reduced Mythril cost of Space Probes."]},{version:"0.4.5",date:"6/19/2019",changes:["Mastery Bonus now unlockable in CRISPR.","Fixed bug with elerium mining that could cause negative mining when you lacked asteroid miners.","Fixed low power warning not clearing when you have no buildings active.","Fixed Sporgar label of Cottages in Steel & Mythril Beams research.","Gene Mutation research will no longer turn off when you run out of knowledge, instead it will pause.","Human creative trait buffed from 2% to 5%.","Troll regenerative trait buffed to heal 4 wounded per day instead of 2.","Ogre tough trait buffed to 25% from 10%.","Gecko optimistic trait buffed to 10% from 2%.","Arraak resourceful trait buffed from 5% to 10%.","Dracnid hoarder trait buffed from 10% to 20%.","Shroomi toxic trait buffed from 10% to 25%.","Wolven pack mentality trait now applies to apartments.","Reduced Nano Tube cost of Mining Drones."]},{version:"0.4.4",date:"6/18/2019",changes:["Matter compression now applies to Wharves.","Xenophobia now applies to Wharves.","Plasmids earned by mutation now apply to no plasmid challenge run.","Reduced Nano Tube cost of Mining Drones."]},{version:"0.4.3",date:"6/17/2019",changes:["Challenge mode achievement tracking.","Vocational Training for craftsman.","Spelling and grammar fixes.","Fixed incorrect reject unity reward text."]},{version:"0.4.2",date:"6/16/2019",changes:["Added some clarification to breakdown of stress."]},{version:"0.4.1",date:"6/16/2019",changes:["Fixed a bug with factories converted from some pre 0.4.0 save files."]},{version:"0.4.0",date:"6/16/2019",changes:["Space reset option, control the destiny of your next race.","Challenge Modes.","New Stuff to discover.","New Achievements to unlock.","Added missing Cyclops racial trait.","World Domination, maybe.","Added soft reset option."]},{version:"0.3.12",date:"6/11/2019",changes:["Fixed bug with riot event that caused it to trigger on high morale instead of low morale."]},{version:"0.3.11",date:"6/10/2019",changes:["The Gas Moon and the Dwarf planets are now accessible.","New technologies based on new discoveries made in deep space.","Wharves can now be unlocked after discovering oil.","There is now an alternative method of unlocking steel.","Night Theme updated, popovers are no longer bright.","Trade route tooltips now include money being imported or exported.","New crispr upgrades for crafting.","Warmonger achievement requirement lowered from 10% to 8%."]},{version:"0.3.10",date:"6/9/2019",changes:["Added code to fix peculiar failed space launch game state."]},{version:"0.3.9",date:"6/8/2019",changes:["New official Evolve [Discord](https://discordapp.com/invite/dcwdQEr)."]},{version:"0.3.8",date:"6/7/2019",changes:["Fixed a problem with negative craftsman counts that could result from craftsman dying."]},{version:"0.3.7",date:"6/6/2019",changes:["Warmongering is now tracked and high casualties may impact morale.","Depleting the mercenary pool will temporarily increase their cost.","Three new achievements related to war."]},{version:"0.3.6",date:"6/5/2019",changes:["Fixed issue with production breakdowns not showing when income was only produced by trade.","Fixed issue that prevented affordability check from refreshing on space missions."]},{version:"0.3.5",date:"6/5/2019",changes:["Mythril Craftsman now unlock correctly.","Fixed a bug that could pause the game if you ran out of Titanium."]},{version:"0.3.4",date:"6/4/2019",changes:["The Asteroid Belt is now open for business.","Robotics Upgrades.","Automation renamed to Machinery.","Assembly Line upgrade for factory."]},{version:"0.3.3",date:"6/3/2019",changes:["New Orbit Structure: Navigation Beacon.","New Red Planet Structures: Space Control Tower and Space Factory.","Reduced number of monuments required to unlock tourism from 4 to 2.","Cement plant workers now round their contribution to 2 decimal places.","Red planet mining now correctly attributes to the red planet in breakdowns."]},{version:"0.3.2",date:"6/3/2019",changes:["Fixed bug that would let you launch the space missions without the proper resources, this would corrupt your game file and break the game.","Added code to detect games corrupted by the previous bug and fix them.","Fixed Fanaticism bug that wouldn't release lumberjacks when you have ent gods."]},{version:"0.3.1",date:"6/3/2019",changes:["Added building check redundancy to auto correct game states that shouldn't occur anyway."]},{version:"0.3.0",date:"6/2/2019",changes:["Space V1 Update.","This opens the first steps into space exploration, more to come... this is not the end.","Rebalanced storage caps to help the game feel more idle friendly."]},{version:"0.2.70",date:"6/2/2019",changes:["Fixed bug when picking Fanaticism with cath gods that wouldn't release your farmers.","Fixed bug when upgrading weapon technology that wouldn't immediately show the increase in army rating."]},{version:"0.2.69",date:"5/26/2019",changes:["Fixed bug which could let you get free barn or warehouse upgrade by essentially skipping over the tech.","Added aria button roles to many button like elements that were not technically buttons."]},{version:"0.2.68",date:"5/26/2019",changes:["Fixed bug with Rock Quarry that prevented the 2% bonus from working unless you had electricity unlocked."]},{version:"0.2.67",date:"5/24/2019",changes:["Revamp of farmer, lumberjack, and quarry worker jobs. These govern the most basic materials produced and can now assign as many workers as you like to these positions.","Farms now directly produce food instead of determining farmer cap.","Lumber Yards now increase lumber production instead of governing lumberjack cap.","Rock Quarry now increase stone production instead of governing quarry worker cap.","Sawmill powered on bonus reduced from 5% to 4%.","Rock Quarry powered on bonus reduced from 5% to 4%.","Stock Exchanges no longer cost Knowledge.","Fixed a display bug that could cause farmers to falsely show they produced more food then they actual did."]},{version:"0.2.66",date:"5/22/2019",changes:["Added alternate row coloring to the market to help distinguish rows."]},{version:"0.2.65",date:"5/21/2019",changes:["Sporgar race redesigned into a parasitic race that spreads through infecting victims."]},{version:"0.2.64",date:"5/20/2019",changes:["Currency is now required before unlocking Basic Storage.","Primitive Axes are no longer gated behind Basic Storage.","Foundry now requires Metal Working to unlock and no longer requires Cement.","Research tab now defaults back to new when resetting.","Fixed issue with not being able to buy something if you had consumption on a resource and the cost was the same as your max capacity.","Fixed issue with max affordability check not refreshing on evolution stage.","Experimental Red-Green color blind theme."]},{version:"0.2.63",date:"5/20/2019",changes:["Fixed an issue that accidentally set the default tax rate to 2% instead of 20% for new games."]},{version:"0.2.62",date:"5/19/2019",changes:["Tax system revamped. Taxes can now be adjusted more granularly and effect morale instead of production.","Cement is now a requirement for theology since cement is needed for temples."]},{version:"0.2.61",date:"5/19/2019",changes:["Every genus type now has its own evolution path."]},{version:"0.2.60",date:"5/18/2019",changes:["Rescaled crate/container volumes. There are now substantially less crates/containers but they do a lot more per crate/container.","Spatial Reasoning now correctly applies to crates & containers.","Increased base value of several major storage facilities.","Added storage timers.","A.R.P.A. costs in popover now update their affordability check.","Buildings and Research that can not be afforded due to low capacity are now marked in red text."]},{version:"0.2.59",date:"5/17/2019",changes:["Added additional validation to ensure save strings belong to evolve before importing.","Fixed army rating display when rating doesn't calculate to a whole number.","Fixed listing order of some resources.","Smelter Iron bonus breakdown fixed.","Added Selenophobia to breakdown lists."]},{version:"0.2.58",date:"5/15/2019",changes:["Settings option to disable multiplier keys."]},{version:"0.2.57",date:"5/15/2019",changes:["Added labor validation to coal miners.","Key Multipliers now work with job and trade route assignment."]},{version:"0.2.56",date:"5/15/2019",changes:["Added +- symbols to trade route to distinguish import vs export."]},{version:"0.2.55",date:"5/14/2019",changes:["Manually crafting resources now gets all the same bonuses as auto crafting.","Fixed Recombination crispr upgrade.","Death limits added to each war campaign level.","War assessment added for each war campaign level."]},{version:"0.2.54",date:"5/13/2019",changes:["Uranium Breakdown Fixes."]},{version:"0.2.53",date:"5/13/2019",changes:["Breakdown Accuracy Enhancements.","Some Kindling Kindred costs reduced.","Fixed bug related to Fanaticism and Ent gods with foundry workers assigned to make plywood.","Plasmid bonus now applies to the sundial.","Fixed some spelling errors."]},{version:"0.2.52",date:"5/11/2019",changes:["Completed research can now be viewed on a separate tab under research.","Removed Plywood requirement from Stock Exchange for players with Kindling Kindred trait.","Fixed a CSS issue in the A.R.P.A. projects tab."]},{version:"0.2.51",date:"5/11/2019",changes:["University starts slightly cheaper.","Added Spatial Superiority crispr upgrade.","Added Spatial Supremacy crispr upgrade.","Exporting a save string now automatically selects the text and copies it to the clipboard."]},{version:"0.2.50",date:"5/10/2019",changes:["Added new capacity breakdowns for various resources."]},{version:"0.2.49",date:"5/10/2019",changes:["Added changelog link to version listing.","Added protection against loading a corrupt save string.","Greedy trait is now less greedy.","Spelling error fixes."]},{version:"0.2.48",date:"5/8/2019",changes:["Resources that are at greater then 99% capacity now change color to indicate they are at cap.","Attacks from rival cities should no longer cause more wounded soldiers then you have.","Assigning craftsman when no citizens are free will no longer take the labor from another job."]},{version:"0.2.47",date:"5/8/2019",changes:["Gluttony trait lowered to 10% from 25% .","High Metabolism trait lowered to 5% from 10% .","Fixed Sheet Metal not being added to craftsman list when unlocked."]},{version:"0.2.46",date:"5/8/2019",changes:["The 5% library bonus was only applying to scientists which was not intended. This now applies to the sundial and professors as well."]},{version:"0.2.45",date:"5/8/2019",changes:["Fixed an issue that allowed you to get extra benefits from under-powered wardenclyffe towers and biolabs."]},{version:"0.2.44",date:"5/8/2019",changes:["Fixed Key Multipliers getting stuck down."]},{version:"0.2.43",date:"5/7/2019",changes:["Fixed bug that could cause player to get free extra crafted resources when using the +5 option.","Reordered buildings in Village tab to group them more logically."]},{version:"0.2.42",date:"5/7/2019",changes:["Fixed a bug that was causing soldiers to become immortal.","Fixed some bugs with morale that caused some weather patterns to apply a different value then was reported.","Added weather to Food breakdown."]},{version:"0.2.41",date:"5/7/2019",changes:["Added a 5% bonus to global knowledge production on libraries."]},{version:"0.2.40",date:"5/7/2019",changes:["The Hivemind trait no longer applies to farmers as this was especially punishing."]},{version:"0.2.39",date:"5/7/2019",changes:["Evolution 2.0: Redid the evolution stage of the game to make it feel less tedious and like it matters more to the next phase of the game.","Fixed a bug that has the intended effects of Pessimism and Optimism traits swapped."]},{version:"0.2.38",date:"5/6/2019",changes:["First public release."]}];function go(){t.settings.expose&&(window.evolve={actions:zc(Qr),races:zc(di),traits:zc(ui),tradeRatio:zc(Za),craftCost:zc(Ya()),atomic_mass:zc(Va),f_rate:zc(Qs),checkAffordable:zc(Cs),adjustCosts:zc(gc),armyRating:zc(ke),tradeBuyPrice:zc(yr),tradeSellPrice:zc(vr),fuel_adjust:zc(Jt),int_fuel_adjust:zc(Yt),alevel:zc(ro),messageQueue:zc(Di),loc:zc(F),shipCosts:zc(ut),updateDebugData:zc(fo),global:{},breakdown:{}})}function fo(){t.settings.expose&&(window.evolve.global=zc(t),window.evolve.craftCost=zc(Ya()),window.evolve.breakdown=zc(r))}$(document).ready((function(){if(window.matchMedia){var e=$('head > link[rel="icon"][media]');$.each(e,(function(t,a){var r=window.matchMedia(a.media);function s(){r.matches&&(e.remove(),e=$(a).appendTo("head"))}r.addListener(s),s()}))}}));var vo=!1;window.addEventListener("storage",(e=>{!1===vo&&Di(F("multitab_warning"),"danger",!0),vo=!0})),t.settings.expose&&go();var yo={showCiv:1,showCivic:2,showResearch:3,showResources:4,showGenetics:5,showAchieve:6,settings:7};$(document).keydown((function(e){let a=(e=e||window.event).key||e.keyCode;Object.keys(v).forEach((function(e){a===t.settings.keyMap[e]&&(v[e]=!0)})),$("input").is(":focus")||$("textarea").is(":focus")||Object.keys(yo).forEach((function(e){a!==t.settings.keyMap[e]||0===t.settings.civTabs||"settings"!==e&&!t.settings[e]||(t.settings.civTabs=yo[e],t.settings.tabLoad||Ct(t.settings.civTabs))}))})),$(document).keyup((function(e){let a=(e=e||window.event).key||e.keyCode;Object.keys(v).forEach((function(e){a===t.settings.keyMap[e]&&(v[e]=!1)}))})),$(document).mousemove((function(e){e=e||window.event,Object.keys(t.settings.keyMap).forEach((function(a){switch(t.settings.keyMap[a]){case"Shift":case 16:v[a]=!!e.shiftKey;break;case"Control":case 17:v[a]=!!e.ctrlKey;break;case"Alt":case 18:v[a]=!!e.altKey;break;case"Meta":case 91:v[a]=!!e.metaKey}}))})),function(){rc($("body")),$("html").addClass(t.settings.font),$("body").append(`
        \n

        Top Bar

        \n {{ race.species | planet }}{{ race.universe | universe }}${F("evo_challenge_simulation")}\n \n \n \n \n \n ${F("year")} {{ city.calendar.year }}\n ${F("day")} {{ city.calendar.day }}\n \n \n {{ s.at / (s.atMultiplier - 1) | remain }}\n \n \n \n \n
        `);let e=$('
        '),a=$('
        ');$("body").append(e),e.append(a),a.append(`
        \n
        \n

        Race Info

        \n
        {{ name() }}
        \n
        ${F("morale")} {{ city.morale.current | mRound }}%
        \n
        MW {{ city.power | replicate | approx }}
        \n
        \n
        \n
        \n
        \n
        \n

        ${F("message_log")}

        \n \n \n \n \n \n ${F("message_log_clear")}\n ${F("message_log_clear_all")}\n
        \n

        ${F("message_filters")}

        \n
        \n

        ${F("messages")}

        \n
        \n
        \n
        \n

        ${F("tab_resources")}

        \n
        `),h.forEach((function(e){$("#msgQueueFilters").append(`\n ${F("message_log_"+e)}\n `)})),sc({el:"#msgQueue",data:{m:p,s:t.settings.msgFilters},methods:{swapFilter(e){if(p.view!==e){$(`#msgQueueFilter-${p.view}`).removeClass("is-active"),$(`#msgQueueFilter-${e}`).addClass("is-active"),p.view=e;let t=$("#msgQueueLog");rc(t),p[e].forEach((function(e){t.append($('

        '+e.msg+"

        "))}))}},clearLog(e){Ni(e=e?[e]:e),rc($("#msgQueueLog")),e?t.lastMsg[e]=[]:Object.keys(t.lastMsg).forEach((function(e){t.lastMsg[e]=[]}))},trigModal(){this.$buefy.modal.open({parent:this,component:{template:''}});let e=setInterval((function(){if($("#modalBox").length>0){clearInterval(e);let r=$c(16,12);$("#modalBox").append($(`

        ${F("message_log")}${r.length>0?r:""}

        `));var a=$('
        ');$("#modalBox").append(a);let s=$(`\n
        \n
        \n ${F("message_log_settings_visible")}\n
        \n
        \n `),i=$(`\n
        \n
        \n
        \n ${F("message_log_settings_length")}\n
        \n
        \n `),c=$(`\n
        \n
        \n
        \n ${F("message_log_settings_save")}\n
        \n
        \n `);a.append(s),a.append(i),a.append(c);let o="",n="",l="",u={},d={};h.forEach((function(e){o+=`
        ${F("message_log_"+e)}
        `,n+=`
        ${F("message_log_"+e)}
        `,l+=`
        ${F("message_log_"+e)}
        `,u[e]=t.settings.msgFilters[e].max,d[e]=t.settings.msgFilters[e].save})),s.append(o),i.append(n),c.append(l),i.append(`\n
        \n \n
        \n `),c.append(`\n
        \n \n
        \n `),sc({el:"#specialModal",data:{s:t.settings.msgFilters,mi:u,si:d},methods:{check(e){if(!t.settings.msgFilters[e].vis&&p.view===e){let e=!1;Object.keys(t.settings.msgFilters).forEach((function(a){if(t.settings.msgFilters[a].vis&&!e){e=!0,$(`#msgQueueFilter-${p.view}`).removeClass("is-active"),$(`#msgQueueFilter-${a}`).addClass("is-active"),p.view=a;let t=$("#msgQueueLog");rc(t),p[a].forEach((function(e){t.append($('

        '+e.msg+"

        "))}))}}))}},checkDisabled(e,a){if(!t.settings.msgFilters[e].vis)return!1;let r=0;return Object.keys(t.settings.msgFilters).forEach((function(e){t.settings.msgFilters[e].vis&&r++})),1===r},maxVal(e){u[e]<1&&(u[e]=1)},saveVal(e){d[e]<0?d[e]=0:d[e]>t.settings.msgFilters[e].max&&(d[e]=t.settings.msgFilters[e].max)},applyMax(){h.forEach((function(e){let a=u[e];t.settings.msgFilters[e].max=a,a');a.append(r);let s=$('
        ');r.append(s),s.append('

        Tab Navigation

        ');let i=$('');s.append(i);let c=$('\n \n ');i.append(c);let o=$('\n \n
        \n
        ');i.append(o);let n=$('\n \n
        \n
        ');i.append(n);let l=$('\n \n
        \n
        ');i.append(l);let u=$('\n \n
        \n
        ');i.append(u);let d=$('\n \n
        \n
        ');i.append(d);let _=$('\n \n
        \n
        ');i.append(_);let m="",g=[{i:"nuclear",f:"steelem",r:2},{i:"zombie",f:"the_misery",r:2},{i:"fire",f:"ill_advised",r:2},{i:"mask",f:"friday",r:1},{i:"skull",f:"demon_slayer",r:2},{i:"taijitu",f:"equilibrium",r:2},{i:"martini",f:"utopia",r:2},{i:"lightbulb",f:"energetic",r:2},{i:"trash",f:"garbage_pie",r:2},{i:"banana",f:"banana",r:2},{i:"turtle",f:"finish_line",r:2},{i:"floppy",f:"digital_ascension",r:2},{i:"slime",f:"slime_lord",r:2},{i:"lightning",f:"annihilation",r:2},{i:"heart",f:"valentine",r:1},{i:"clover",f:"leprechaun",r:1},{i:"bunny",f:"easter",r:1},{i:"egg",f:"egghunt",r:1},{i:"rocket",f:"launch_day",r:1},{i:"sun",f:"solstice",r:1},{i:"firework",f:"firework",r:1},{i:"ghost",f:"halloween",r:1},{i:"candy",f:"trickortreat",r:1},{i:"turkey",f:"thanksgiving",r:1},{i:"present",f:"xmas",r:1}],f=ro();f<2&&(f=2);for(let e=0;e=g[e].r?m+=`${wc(g[e].i,16,f)} {{ '${g[e].i}' | label }}`:t.settings.icon===g[e].i&&(t.settings.icon="star");let v=$c(9,14),y="";v.length>0&&(y=`${v}`);let b=kc(5,12,!0),w="";b.length>0&&(w=`${b}`);let x="",k="";Object.keys(z).length>1&&Object.keys(z).forEach((function(e){t.settings.locale===e&&(k=z[e]),x+=`${z[e]}`}));let q=$(`\n \n
        \n {{ 'theme' | label }} \n \n \n {{ 'theme_dark' | label }}\n {{ 'theme_light' | label }}\n {{ 'theme_night' | label }}\n {{ 'theme_darkNight' | label }}\n {{ 'theme_redgreen' | label }}\n {{ 'theme_gruvboxLight' | label }}\n {{ 'theme_gruvboxDark' | label }}\n {{ 'theme_orangeSoda' | label }}\n {{ 'theme_dracula' | label }}\n ${y}\n \n {{ 'units' | label }} \n \n \n {{ 'metric' | label }}\n {{ 'scientific' | label }}\n {{ 'sln' | label }}\n ${w}\n \n\n {{ 'icons' | label }} \n \n \n ${wc("star",16,f)} {{ 'star' | label }}\n ${m}\n \n
        \n
        \n {{ 'locale' | label }} \n \n \n ${x}\n \n\n {{ 'font' | label }} \n \n \n {{ 'standard' | label }}\n {{ 'large_log' | label }}\n {{ 'large_all' | label }}\n \n\n {{ 'q_merge' | label }} \n \n \n {{ 'merge_never' | label }}\n {{ 'merge_nearby' | label }}\n {{ 'merge_all' | label }}\n \n
        \n {{ 'pause' | label }}\n {{ 'm_keys' | label }}\n {{ 'c_cat' | label }}\n {{ 'q_key' | label }}\n {{ 'q_any' | label }}\n {{ 'q_any_res' | label }}\n {{ 's_pack_on' | label }}\n {{ 'expose' | label }}\n {{ 'tabLoad' | label }}\n {{ 'boring' | label }}\n {{ 'touch' | label }}\n
        \n
        ${F("key_mappings")}
        \n
        ${F("multiplier",[10])}
        \n
        ${F("multiplier",[25])}
        \n
        ${F("multiplier",[100])}
        \n
        ${F("q_key")}
        \n
        \n
        \n
        ${F("tab_mappings")}
        \n
        ${F("tab_civil")}
        \n
        ${F("tab_civics")}
        \n
        ${F("tab_research")}
        \n
        ${F("tab_resources")}
        \n
        ${F("tech_arpa")}
        \n
        ${F("tab_stats")}
        \n
        ${F("tab_settings")}
        \n
        \n
        \n \n \n \n
        \n
        \n {{ | sPack}}\n
        \n
        \n \n \n \n \n \n \n \n
        \n
        \n \n {{ 'enable_reset' | label }}\n
        \n
        \n

        \n {{ 'reset_warn' | label }}\n

        \n

        \n \n \n

        \n
        \n
        \n
        \n
        \n
        `);i.append(q);let M=$('\n \n
        \n
        ');i.append(M),a.append('
        ');let P=$c(15,8);$("body").append(`\n
        \n \n

        \n ${P.length>0?`Ev${P}lve`:"Evolve"}\n by\n Demagorddon\n

        \n
        \n \n

        External Links

        \n \n
        \n
        \n `)}();var bo=t.revision?t.revision:"";t.beta?$("#topBar .version > a").html(`v${t.version} Beta ${t.beta}${bo}`):$("#topBar .version > a").html("v"+t.version+bo),Ni(),t.lastMsg&&Object.keys(t.lastMsg).forEach((function(e){t.lastMsg[e].reverse().forEach((function(t){Di(t.m,t.c,!0,[e],!0)})),t.lastMsg[e].reverse()})),$("#msgQueue").height(t.settings.msgQueueHeight),$("#buildQueue").height(t.settings.buildQueueHeight),!0===t.queue.rename&&(Ks(!0),t.queue.rename=!1),t.settings.sPackMsg=e.getItem("string_pack_name")?F("string_pack_using",[e.getItem("string_pack_name")]):F("string_pack_none"),t.queue.display&&Ri(),t.r_queue.display&&Hi(),sc({el:"#mainColumn div:first-child",data:{s:t.settings},methods:{swapTab:e=>(t.settings.tabLoad||Ct(e),e),saveImport(){$("#importExport").val().length>0&&importGame($("#importExport").val())},saveExport(){$("#importExport").val(window.exportGame()),$("#importExport").select(),document.execCommand("copy")},saveExportFile(){const e=new Date;((e,t,a)=>{const r=document.createElement("a"),s=new Blob([e],{type:"text/plain"});r.href=URL.createObjectURL(s),r.download=t,r.click(),URL.revokeObjectURL(r.href)})(window.exportGame(),`evolve-${e.getFullYear()}-${e.getMonth()+1}-${e.getDate()}-${e.getHours()}-${e.getMinutes()}.txt`)},importStringFile(){let a=document.getElementById("stringPackFile").files[0];if(a){let r=new FileReader,s=document.getElementById("stringPackFile").files[0].name;r.readAsText(a,"UTF-8"),r.onload=function(a){try{JSON.parse(a.target.result)}catch{return void(t.settings.sPackMsg=F("string_pack_error",[s]))}t.settings.sPackMsg=F("string_pack_using",[s]),e.setItem("string_pack_name",s),e.setItem("string_pack",LZString.compressToUTF16(a.target.result)),t.settings.sPackOn&&(t.queue.rename=!0,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload())},r.onerror=function(e){console.error("error reading file")}}},clearStringFile(){e.getItem("string_pack")&&(t.settings.sPackMsg=F("string_pack_none"),e.removeItem("string_pack_name"),e.removeItem("string_pack"),t.settings.sPackOn&&(t.queue.rename=!0,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload()))},stringPackOn(){e.getItem("string_pack")&&(t.queue.rename=!0,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload())},restoreGame(){let t=e.getItem("evolveBak")||!1;this.$buefy.dialog.confirm({title:F("restore"),message:F("restore_warning"),ariaModal:!0,confirmText:F("restore"),onConfirm(){t&&importGame(t,!0)}})},lChange(a){t.settings.locale=a,t.queue.rename=!0,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload()},setTheme(e){t.settings.theme=e,$("html").removeClass(),$("html").addClass(e),$("html").addClass(t.settings.font)},numNotation(e){t.settings.affix=e},icon(a){t.settings.icon=a,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload()},remove(e){t.r_queue.queue.splice(e,1)},font(e){t.settings.font=e,$("html").removeClass("standard"),$("html").removeClass("large_log"),$("html").removeClass("large_all"),$("html").addClass(e)},q_merge(e){t.settings.q_merge=e},toggleTabLoad(){Ot()},unpause(){$("#pausegame").removeClass("play"),$("#pausegame").removeClass("pause"),t.settings.pause?$("#pausegame").addClass("pause"):$("#pausegame").addClass("play"),t.settings.pause||M.s||Ii("start")}},filters:{namecase:e=>e.replace(/(?:^|\s)\w/g,(function(e){return e.toUpperCase()})),label:e=>Pt(e),sPack:()=>t.settings.sPackMsg,notation(e){switch(e){case"si":return F("metric");case"sci":return F("scientific");case"sln":return F("sln")}}}}),["1","3","4","5","6","7","8","9","10","11","12","13","14","15","16"].forEach((function(e){Ti(`settings${e}`,(function(){return F(`settings${e}`)}),{elm:`#settings span.settings${e}`})})),Ti("stringPack",(function(){return F("string_example",['
        {\n "year": "Galactic Standard Year",\n "resource_Food_name": "Nom Noms"\n}
        '])})),t.new&&(Di(F("new"),"warning",!1,["progress"]),t.new=!1),t.city.mass_driver&&(i.mass_driver=t.city.mass_driver.on),t.portal.turret&&(i.turret=t.portal.turret.on),t.interstellar.fusion&&(o.fusion=t.interstellar.fusion.on),t.portal.hell_forge&&(i.hell_forge=t.portal.hell_forge.on),t.space.sam&&(i.sam=t.space.sam.on),t.space.operating_base&&(i.operating_base=t.space.operating_base.on,c.operating_base=t.space.operating_base.on),t.space.fob&&(i.fob=t.space.fob.on),t.tauceti.fusion_generator&&(i.fusion_generator=t.tauceti.fusion_generator.on),oa(!0),rr(),Ot(),Ui(),t.race.shapeshifter&&qi(!1,!0),Object.keys(ai()).forEach((function(e){Li(e)})),w(),sc({el:"#race",data:{race:t.race,city:t.city},methods:{name:()=>Ac("name")},filters:{replicate:e=>t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks")&&t.race.hasOwnProperty("replicator")&&Object.values(t.race.governor.tasks).includes("replicate")&&t.race.governor.config.replicate.pow.on&&t.race.replicator.pow>0?e+t.race.replicator.pow:e,approx:e=>+e.toFixed(2),mRound:e=>+e.toFixed(1)}}),Ti("race",(function(){return"string"==typeof di[t.race.species].desc?di[t.race.species].desc:di[t.race.species].desc()}),{elm:"#race > .name"});var wo=125;if(Ti("morale",(function(e){if(0!==t.city.morale.unemployed){let a=t.city.morale.unemployed>0?"success":"danger";e.popper.append(``)}if(0!==t.city.morale.stress){let a=t.city.morale.stress>0?"success":"danger";e.popper.append(``)}let a=100+t.city.morale.unemployed+t.city.morale.stress;if(Object.keys(t.city.morale).forEach((function(r){if(!["current","unemployed","stress","season","cap","potential"].includes(r)&&0!==t.city.morale[r]){a+=t.city.morale[r];let s=t.city.morale[r]>0?"success":"danger",i=t.city.morale[r];if("entertain"===r&&"democracy"===t.civic.govern.type&&(i/=1+ae.democracy()[0]/100),e.popper.append(``),"entertain"===r&&"democracy"===t.civic.govern.type){let t=ae.democracy()[0];e.popper.append(``)}}})),0!==t.city.morale.season){a+=t.city.morale.season;let r=0===t.city.calendar.season?F("morale_spring"):1===t.city.calendar.season?F("morale_summer"):F("morale_winter"),s=t.city.morale.season>0?"success":"danger";e.popper.append(``)}if("corpocracy"===t.civic.govern.type){let t=ae.corpocracy()[3];a-=t,e.popper.append(``)}if("republic"===t.civic.govern.type){let t=ae.republic()[1];a+=t,e.popper.append(``)}if("federation"===t.civic.govern.type){let t=ae.federation()[1];a+=t,e.popper.append(``)}let r=N("militant",1);if(r&&(a-=r,e.popper.append(``)),t.race.cheese){let r=t.stats.hasOwnProperty("reset")?t.stats.reset+1:1,s=+(r/(r+10)*11).toFixed(2);a+=s,e.popper.append(``)}if(t.race.motivated){let r=Math.ceil(t.race.motivated**.4);a+=r,e.popper.append(``)}if(t.civic.homeless){let r=t.civic.homeless/2;a-=r,e.popper.append(``)}if(t.tech.vax_c||t.tech.vax_f){let r=t.tech.vax_c?10:50;a-=r,e.popper.append(``)}else if(t.tech.vax_s){let t=20;a+=t,e.popper.append(``)}t.city.tormented&&(a-=t.city.tormented,e.popper.append(``)),a=+a.toFixed(1);let s=$("
        ");e.popper.append(s),s.append(``),s.append(``),s.append(``)}),{classes:"has-background-light has-text-dark"}),Ti("powerStatus",(function(e){let a=+(t.city.power_total-t.city.power).toFixed(2);Object.keys(s).forEach((function(t){if(s[t]){let a=+s[t].toFixed(2);e.popper.append(``)}})),e.popper.append(``);let r=+t.city.power.toFixed(2);t.city.power>0?e.popper.append(``):e.popper.append(``)}),{classes:"has-background-light has-text-dark"}),t.settings.pause?$("#pausegame").addClass("pause"):$("#pausegame").addClass("play"),sc({el:"#topBar",data:{city:t.city,race:t.race,s:t.settings},methods:{sign:()=>R("sign"),getAstroSign:()=>R("astrology"),weather:()=>R("weather"),temp:()=>R("temp"),moon:()=>R("moon"),showUniverse:()=>"standard"!==t.race.universe&&"bigbang"!==t.race.universe,showSim:()=>!!t.sim,atRemain:()=>F("accelerated_time"),pause(){$("#pausegame").removeClass("play"),$("#pausegame").removeClass("pause"),t.settings.pause?(t.settings.pause=!1,$("#pausegame").addClass("play")):(t.settings.pause=!0,$("#pausegame").addClass("pause")),t.settings.pause||M.s||Ii("start")},pausedesc:()=>t.settings.pause?F("game_play"):F("game_pause")},filters:{planet:e=>di[e].home,universe:e=>"standard"===e||"bigbang"===e?"":ta[e].name,remain(e){const a=ic(e/1e3);return`${t.settings.atMultiplier}x Speed [${a}]`}}}),["astroSign"].forEach((function(e){Ti(`${e}`,(function(){return R("sign")}),{elm:$(`#${e}`)})})),Ti("topBarPlanet",(function(e){if("protoplasm"===t.race.species)e.popper.append($(`${F("infant")}`));else{let a=di[t.race.species].home,r=Ac("name"),s=ji[t.city.biome].label,i=t.city.ptrait;if(i.length>0){let e="";i.forEach((function(a){Si.hasOwnProperty(a)&&("mellow"===a&&"entish"===t.race.species?e+=`${F("planet_mellow_eg")} `:e+=`${Si[a].label} `)})),s=`${e}${s}`}let c=t.city.calendar.orbit,o=ks(t.city.geology),n="";if(t.race.truepath&&(n+=`
        ${F("evo_challenge_truepath_recap")}
        `),t.race.junker&&(n+=`
        ${F("evo_challenge_junker_desc")} ${F("evo_challenge_junker_conditions")}
        `),t.race.joyless&&(n+=`
        ${F("evo_challenge_joyless_desc")} ${F("evo_challenge_joyless_conditions")}
        `),t.race.steelen&&(n+=`
        ${F("evo_challenge_steelen_desc")} ${F("evo_challenge_steelen_conditions")}
        `),t.race.decay&&(n+=`
        ${F("evo_challenge_decay_desc")} ${F("evo_challenge_decay_conditions")}
        `),t.race.emfield&&(n+=`
        ${F("evo_challenge_emfield_desc")} ${F("evo_challenge_emfield_conditions")}
        `),t.race.inflation&&(n+=`
        ${F("evo_challenge_inflation_desc")} ${F("evo_challenge_inflation_conditions")}
        `),t.race.banana&&(n+=`
        ${F("evo_challenge_banana_desc")} ${F("wiki_achieve_banana1")}. ${F("wiki_achieve_banana2")}. ${F("wiki_achieve_banana3")}. ${F("wiki_achieve_banana4",[500])}. ${F("wiki_achieve_banana5",[50])}.
        `),t.race.witch_hunter&&(n+=`
        ${F("evo_challenge_witch_hunter_desc")}
        `),t.race.nonstandard&&(n+=`
        ${F("evo_challenge_nonstandard_desc")}
        `),t.race.gravity_well&&(n+=`
        ${F("evo_challenge_gravity_well_desc")}
        `),t.race.warlord&&(n+=`
        ${F("evo_challenge_warlord_desc")}
        `),t.race.lone_survivor&&(n+=`
        ${F("evo_challenge_lone_survivor_desc")}
        `),t.race.sludge&&(n+=`
        ${F("evo_challenge_sludge_desc")} ${F("evo_challenge_sludge_conditions")}
        `),t.race.orbit_decay){let e=t.race.orbit_decayed?"":F("evo_challenge_orbit_decay_impact",[t.race.orbit_decay-t.stats.days]);n+=`
        ${t.race.orbit_decayed?F("evo_challenge_orbit_decay_impacted",[di[t.race.species].home]):F("evo_challenge_orbit_decay_desc")} ${F("evo_challenge_orbit_decay_conditions")} ${e}
        `,lc()>=100&&"antimatter"!==t.race.universe?n+=`
        ${F("evo_challenge_cataclysm_warn")}
        `:n+=`
        ${F("evo_challenge_scenario_warn")}
        `}t.race.cataclysm&&(lc()>=50&&"antimatter"!==t.race.universe?n+=`
        ${F("evo_challenge_cataclysm_desc")}
        ${F("evo_challenge_cataclysm_warn")}
        `:n+=`
        ${F("evo_challenge_cataclysm_desc")}
        ${F("evo_challenge_scenario_warn")}
        `),e.popper.append($(`
        ${F(t.race.cataclysm?"no_home":"home",[a,r,s,c])}
        ${o}${n}`))}}),{elm:"#topBar .planetWrap .planet",classes:"has-background-light has-text-dark"}),Ti("topBarUniverse",(function(e){e.popper.append($(`
        ${ta[t.race.universe].desc}
        `)),e.popper.append($(`
        ${ta[t.race.universe].effect}
        `))}),{elm:"#topBar .planetWrap .universe",classes:"has-background-light has-text-dark"}),Ti("topBarSimulation",(function(e){e.popper.append($(`
        ${F("evo_challenge_simulation_topbar")}
        `))}),{elm:"#topBar .planetWrap .simulation",classes:"has-background-light has-text-dark"}),t.race.orbit_decay&&!t.race.orbit_decayed&&Ti("infoTimer",(function(){return t.race.orbit_decayed?"":F("evo_challenge_orbit_decay_impact",[t.race.orbit_decay-t.stats.days])}),{elm:"#infoTimer",classes:"has-background-light has-text-dark"}),ao(),"protoplasm"===t.race.species){t.resource.RNA.display=!0;let e=t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0?Math.min(t.stats.achieve.ascended.l,t.stats.feat.master):0;if(t.sim&&(e=5),e>0&&!t.evolution.mloaded){let a=["dna","membrane","organelles","nucleus","eukaryotic_cell","mitochondria"];for(let e=0;e0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):0;t.sim&&(a=5),a>=5&&!t.evolution.gmloaded&&(t.tech.evo=6,t.evolution.gselect=!0,t.evolution.gmloaded=1,t.evolution.final=80,t.tech.evo_humanoid=1,t.tech.evo_giant=1,t.tech.evo_small=1,t.tech.evo_animalism=2,t.tech.evo_demonic=1,t.tech.evo_angelic=1,t.tech.evo_insectoid=1,t.tech.evo_eggshell=2,t.tech.evo_eldritch=1,t.tech.evo_sand=1,t.tech.evo_polar=1,t.tech.evo_heat=1,t.tech.evo_fey=1,t.tech.evo_aquatic=1),"bigbang"===t.race.universe?(t.seed=t.race.seed,function(){let e=["standard","heavy","antimatter","evil","micro","magic"];for(let a=0;a`),c=$(`${ta[r].name}`);i.append(c),$("#evolution").append(i),$("#"+s).on("click",(function(){t.race.universe=r,rc($("#evolution")),aa(),Ei()})),Ti(s,(function(e){e.popper.append($(`
        ${ta[r].name}
        `)),e.popper.append($(`
        ${ta[r].desc}
        `)),e.popper.append($(`
        ${ta[r].effect}
        `))}),{classes:"has-background-light has-text-dark"})}}()):t.race.seeded&&!t.race.chose?(t.seed=t.race.seed,aa()):ts()}else t.portal.hasOwnProperty("soul_forge")&&t.portal.soul_forge.on&&(i.soul_forge=1),G();Po(!0),$("#lbl_city").html("Village"),window.Worker&&(M.w=new Worker("evolve/evolve.js"),M.w.addEventListener("message",(function(a){switch(a.data){case"fast":!function(){t.race.no_craft||$(".craft").each((function(e){"number"==typeof $(this).data("val")&&$(this).html(k($(this).data("val")*y(),1))}));const e=new Date,a=U();r.p.Global={};var d=1;let _=!1,p=Br("raw");if(t.prestige.Plasmid.count>0&&("antimatter"!==t.race.universe||t.genes.bleed&&"antimatter"===t.race.universe)&&(r.p.Global[F("resource_Plasmid_name")]=100*p[1]+"%",_=!0),t.prestige.AntiPlasmid.count>0&&("antimatter"===t.race.universe||t.genes.bleed&&t.genes.bleed>=2&&"antimatter"!==t.race.universe)&&(r.p.Global[F("resource_AntiPlasmid_name")]=100*p[2]+"%",_=!0),_&&(d+=p[0]),(t.race.no_plasmid||"antimatter"===t.race.universe)&&((t.race.cataclysm||t.race.orbit_decayed)&&t.space.ziggurat&&t.space.ziggurat.count||t.city.temple&&t.city.temple.count)){let e=Dr();r.p.Global[F("faith")]=100*e+"%",d*=1+e}if(t.race.untapped&&t.race.untapped>0){let e=+(t.race.untapped/(t.race.untapped+20)/10+24e-5).toFixed(4);r.p.Global[F("trait_untapped_bd")]=100*e+"%",d*=1+e}if(t.race.rainbow_active&&t.race.rainbow_active>1&&(r.p.Global[F("trait_rainbow_bd")]=`${ui.rainbow.vars()[0]}%`,d*=1+ui.rainbow.vars()[0]/100),t.tech.world_control){let e=25;"federation"===t.civic.govern.type&&(e=ae.federation()[2]),t.race.unified&&(e+=ui.unified.vars()[0]),"taurus"===a&&(e+=H("taurus")[0]),r.p.Global[F("tech_unification")]=`${e}%`,d*=1+e/100}else{let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].anx||t.civic.foreign[`gov${a}`].buy)&&(e+="federation"===t.civic.govern.type?5+ae.federation()[0]:5);e>0&&(r.p.Global[F("civics_garrison_occupy")]=`${e}%`,d*=1+e/100)}if(t.genes.challenge&&t.genes.challenge>=2){let e=lc();r.p.Global[F("mastery")]=e+"%",d*=1+e/100}if(t.pillars){let e=_c();r.p.Global[F("harmonic")]=100*(e[0]-1)+"%",d*=e[0]}if(t.race.ascended&&(r.p.Global[F("achieve_ascended_name")]="5%",d*=1.05),t.race.corruption){let e=2*t.race.corruption;r.p.Global[F("achieve_corrupted_name")]=`${e}%`,d*=1+e/100}if(t.race.rejuvenated){let e=t.stats.days<996?(1e3-t.stats.days)/2e3:.02;r.p.Global[F("rejuvenated")]=100*e+"%",d*=1+e}let h=Pi("octigoran");if(t.race.suction_grip||h>0){let e=0;t.race.suction_grip&&(e+=ui.suction_grip.vars()[0]),h>0&&(e+=+(ui.suction_grip.vars(1)[0]*h).toFixed(2)),r.p.Global[F("trait_suction_grip_bd")]=e+"%",d*=1+e/100}let m=Pi("cyclops");if(t.race.intelligent||m>0){let e=0;t.race.intelligent&&(e+=na(t.civic.scientist.workers,"scientist")*ui.intelligent.vars()[1]+na(t.civic.professor.workers,"professor")*ui.intelligent.vars()[0]),m>0&&(e+=na(t.civic.scientist.workers,"scientist")*ui.intelligent.vars(1)[1]*m+na(t.civic.professor.workers,"professor")*ui.intelligent.vars(1)[0]*m),t.race.high_pop&&(e=Me(e)),r.p.Global[F("trait_intelligent_bd")]=e+"%",d*=1+e/100}if(t.race.slaver&&t.city.slave_pen&&t.city.slave_pen){let e=t.city.slave_pen.slaves*ui.slaver.vars()[0];r.p.Global[F("trait_slaver_bd")]=e+"%",d*=1+e/100}if((t.city.ptrait.includes("trashed")||t.race.scavenger||t.race.servants&&t.race.servants.force_scavenger)&&t.civic.scavenger){let e=t.city.ptrait.includes("trashed")||t.race.scavenger?na(t.civic.scavenger.workers,"scavenger"):0;if(t.race.servants&&(e+=la(t.race.servants.jobs.scavenger)),e>0){let a=e*ui.scavenger.vars()[0];t.city.ptrait.includes("trashed")&&t.race.scavenger&&(a*=1+ui.scavenger.vars()[1]/100),t.city.ptrait.includes("trashed")&&(a*=Si.trashed.vars()[1]),t.race.high_pop&&(a=Me(a)),r.p.Global[F("job_scavenger")]=a+"%",d*=1+a/100}}if(t.race.unfathomable&&t.city.surfaceDwellers&&t.city.captive_housing){let e=0,a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;if(t.city.hasOwnProperty("surfaceDwellers")){for(let a=0;at.civic.torturer.workers*a/2){let r=e-t.civic.torturer.workers*a/2;e-=Math.ceil(r/3)}}if(e>0){let s=e*ui.unfathomable.vars()[2]*a/5;t.race.psychic&&(s*=1+ui.psychic.vars()[1]/100),r.p.Global[F("trait_unfathomable_bd")]=s+"%",d*=1+s/100}}if(t.city.ptrait.includes("mellow")&&(r.p.Global[F("planet_mellow_bd")]="-10%",d*=Si.mellow.vars()[2]),t.city.ptrait.includes("ozone")&&t.city.sun){let e=t.city.sun*Si.ozone.vars()[0];r.p.Global[F("planet_ozone_bd")]=`-${e}%`,d*=1-e/100}let g=Pi("phoenix");if((t.race.smoldering||g>0)&&t.city.hot){let e=0;t.race.smoldering&&(t.city.hot>100?(e+=100*ui.smoldering.vars()[1],e+=(t.city.hot-100)*ui.smoldering.vars()[2]):e+=t.city.hot*ui.smoldering.vars()[1]),g>0&&(t.city.hot>100?(e+=100*ui.smoldering.vars(.25)[1]*g,e+=(t.city.hot-100)*ui.smoldering.vars(.25)[2]*g):e+=t.city.hot*ui.smoldering.vars(.25)[1]*g),r.p.Global[F("trait_smoldering_name")]=`${e}%`,d*=1+e/100}if(t.race.heat_intolerance&&t.city.hot){let e=t.city.hot*ui.heat_intolerance.vars()[0];r.p.Global[F("hot")]=`-${e}%`,d*=1-e/100}if(t.race.chilled&&t.city.cold){let e=0;t.city.cold>100?(e+=100*ui.chilled.vars()[1],e+=(t.city.cold-100)*ui.chilled.vars()[2]):e=t.city.cold*ui.chilled.vars()[1],r.p.Global[F("trait_chilled_name")]=`${e}%`,d*=1+e/100}if(t.race.cold_intolerance&&t.city.cold){let e=t.city.cold*ui.cold_intolerance.vars()[0];r.p.Global[F("cold")]=`-${e}%`,d*=1-e/100}if("anarchy"===t.civic.govern.type&&t.resource[t.race.species].amount>=la(10)){let e=(t.resource[t.race.species].amount-(la(10)-1))*(t.race.high_pop?.25/ui.high_pop.vars()[0]:.25);r.p.Global[F("govern_anarchy")]=`-${e}%`,d*=1-e/100}if(t.civic.govern.protest&&t.civic.govern.protest>0&&(r.p.Global[F("event_protest")]="-30%",d*=.7),t.civic.govern.scandal&&t.civic.govern.scandal>0){let e=N("muckraker",0);e&&(r.p.Global[F("event_scandal")]=`-${e}%`,d*=1-e/100)}if(Pi("capybara")>0||t.race.calm&&t.city.meditation&&t.resource.Zen.display){let e=t.resource.Zen.amount,a=Pi("capybara");a>0&&(e+=Math.round(500*a));let s=e/(e+5e3);r.p.Global[F("trait_calm_bd")]=`+${(100*s).toFixed(2)}%`,d*=1+s}if(t.city.firestorm&&t.city.firestorm>0&&(t.city.firestorm--,r.p.Global[F("event_flare_bd")]="-20%",d*=.8),"aquatic"===di[t.race.species].type&&!["swamp","oceanic"].includes(t.city.biome)||"fey"===di[t.race.species].type&&!["forest","swamp","taiga"].includes(t.city.biome)||"heat"===di[t.race.species].type&&!["ashland","volcanic"].includes(t.city.biome)||"polar"===di[t.race.species].type&&!["tundra","taiga"].includes(t.city.biome)||"sand"===di[t.race.species].type&&!["ashland","desert"].includes(t.city.biome)||"demonic"===di[t.race.species].type&&"hellscape"!==t.city.biome||"angelic"===di[t.race.species].type&&"eden"!==t.city.biome){let e=1;e=t.blood.unbound&&t.blood.unbound>=4?t.race.rejuvenated?.975:.95:t.blood.unbound&&t.blood.unbound>=2?t.race.rejuvenated?.95:.9:t.race.rejuvenated?.9:.8,r.p.Global[F("unsuited")]=`-${Math.round(100*(1-e))}%`,d*=e}if(t.race.hibernator&&3===t.city.calendar.season&&(d*=1-ui.hibernator.vars()[1]/100,r.p.Global[F("morale_winter")]=`-${ui.hibernator.vars()[1]}%`),"magic"===t.race.universe&&t.tech.syphon){let e=t.tech.syphon/8;r.p.Global[F("arpa_syphon_damage")]=`-${e}%`,d*=1-e/100}r.p.consume={},["Money","Knowledge","Food","Lumber","Stone","Chrysotile","Crystal","Furs","Copper","Iron","Cement","Coal","Oil","Uranium","Aluminium","Steel","Titanium","Alloy","Polymer","Iridium","Helium_3","Water","Deuterium","Neutronium","Adamantite","Infernite","Elerium","Nano_Tube","Graphene","Stanene","Bolognium","Vitreloy","Orichalcum","Unobtainium","Quantium","Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Aerogel","Nanoweave","Scarletite","Cipher","Nanite","Mana"].forEach((function(e){r.p.consume[e]={},r.p[e]={}}));var f=.25;if("protoplasm"===t.race.species){if(t.evolution.nucleus&&t.resource.DNA.amount0||t.evolution.poikilohydric&&t.evolution.poikilohydric.count>0||t.evolution.spores&&t.evolution.spores.count>0)&&(v*=2),Vi("DNA",v*d*f),Vi("RNA",-2*e*f)}if(t.evolution.organelles){let e=t.race.rapid_mutation?2:1;t.tech.evo&&t.tech.evo>=2&&e++,Vi("RNA",t.evolution.organelles.count*e*d*f)}if((t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0||t.sim)&&"bigbang"!==t.race.universe&&(!t.race.seeded||t.race.seeded&&t.race.chose)){let e=t.sim?5:Math.min(t.stats.achieve.apocalypse.l,t.stats.feat.novice);Vi("RNA",e/2*f*d),t.resource.DNA.display&&Vi("DNA",e/4*f*d)}t.resource.RNA.amount>=2&&!t.evolution.dna?(t.evolution.dna=1,t.resource.DNA.display=!0,t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1&&(Vi("RNA",t.resource.RNA.max),Vi("DNA",t.resource.RNA.max)),ts()):t.resource.RNA.amount>=10&&!t.evolution.membrane?(t.evolution.membrane={count:0},ts()):t.resource.DNA.amount>=4&&!t.evolution.organelles?(t.evolution.organelles={count:0},ts()):t.evolution.organelles&&t.evolution.organelles.count>=2&&!t.evolution.nucleus?(t.evolution.nucleus={count:0},ts()):t.evolution.nucleus&&t.evolution.nucleus.count>=1&&!t.evolution.eukaryotic_cell?(t.evolution.eukaryotic_cell={count:0},ts()):t.evolution.eukaryotic_cell&&t.evolution.eukaryotic_cell.count>=1&&!t.evolution.mitochondria?(t.evolution.mitochondria={count:0},ts()):t.evolution.mitochondria&&!t.tech.evo&&(t.tech.evo=1,ts())}else{let _=function(){let e=1;if(t.space.ziggurat&&t.space.ziggurat.count>0){let a=t.tech.ancient_study?.006:.004;if(t.tech.ancient_deify&&t.tech.ancient_deify>=2&&c.exotic_lab&&(a+=1e-4*c.exotic_lab),"theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=2e-5;t.race.high_pop&&(e=Me(e)),a+=e*t.civic.priest.workers}t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),t.race.high_pop&&(a=Me(a)),e+=t.space.ziggurat.count*t.civic.colonist.workers*a}return e}(),p=100,h=1,m=1;if(t.race.quarantine&&t.race.qDays){let e=1-(t.race.qDays<=1e3?t.race.qDays:1e3)/1e3;switch(t.race.quarantine){case 1:h=.5+.5*e;break;case 2:h=.25+.25*e,m=.5+.5*e;break;case 3:h=.1+.15*e,m=.25+.25*e;break;case 4:h=.08+.02*e,m=.12+.13*e}if(t.race.vax&&t.tech.focus_cure&&t.tech.focus_cure>=4){let e=+t.race.vax.toFixed(2)/100;e>1&&(e=1),h+=(1-h)*e,m+=(1-m)*e}}if(0===t.city.calendar.season&&t.city.calendar.year>0){let e=t.race.chilled||t.race.smoldering?0:5;p+=e,t.city.morale.season=e}else 1===t.city.calendar.season&&t.race.smoldering?(p+=ui.smoldering.vars()[0],t.city.morale.season=ui.smoldering.vars()[0]):3===t.city.calendar.season?t.race.chilled?(p+=ui.chilled.vars()[0],t.city.morale.season=ui.chilled.vars()[0]):(p-=t.race.leathery?ui.leathery.vars()[0]:5,t.city.morale.season=t.race.leathery?-ui.leathery.vars()[0]:-5):t.city.morale.season=0;if(t.race.cheese){let e=t.stats.hasOwnProperty("reset")?t.stats.reset+1:1;p+=+(e/(e+10)*11).toFixed(2)}if(t.civic.homeless&&(p-=t.civic.homeless/2),t.tech.vax_c||t.tech.vax_f?p-=t.tech.vax_c?10:50:t.tech.vax_s&&(p+=20),t.tech.m_boost?(t.city.morale.leadership=20,p+=20):t.city.morale.leadership=0,Kc()){let e=Lc("morale");t.city.morale.shrine=e.add,p+=e.add}else t.city.morale.shrine=0;let g=N("militant",1);if(g&&(p-=g),"corpocracy"===t.civic.govern.type&&(p-=ae.corpocracy()[3]),"republic"===t.civic.govern.type&&(p+=ae.republic()[1]),"federation"===t.civic.govern.type&&(p+=ae.federation()[1]),t.race.blood_thirst&&t.race.blood_thirst_count>=1){let e=Math.ceil(Math.log2(t.race.blood_thirst_count));t.city.morale.blood_thirst=e,p+=e}else t.city.morale.blood_thirst=0;let v=0;0===t.city.calendar.weather?t.city.calendar.temp>0&&(v=1===t.city.calendar.wind?t.race.skittish?-ui.skittish.vars()[0]:t.race.leathery?-ui.leathery.vars()[0]:-5:t.race.leathery?0:-2):2===t.city.calendar.weather?t.race.nyctophilia?v=-ui.nyctophilia.vars()[0]:(0===t.city.calendar.wind&&t.city.calendar.temp<2||1===t.city.calendar.wind&&2===t.city.calendar.temp)&&(v=2):t.race.nyctophilia&&(v=ui.nyctophilia.vars()[1]),!t.race.snowy||0===t.city.calendar.temp&&0===t.city.calendar.weather||(v-=t.city.calendar.temp>=2?ui.snowy.vars()[1]:ui.snowy.vars()[0]),t.city.morale.weather=t.race.submerged?0:v,p+=t.race.submerged?0:v,t.race.motivated&&(p+=Math.ceil(t.race.motivated**.4));let y=0,k=5;t.city.morale.unemployed=0,t.city.ptrait.includes("mellow")?k*=Si.mellow.vars()[0]:(p-=t.civic.unemployed.workers,t.city.morale.unemployed=-t.civic.unemployed.workers);let M=Pi("vulpine");if(t.civic.hunter.display&&(t.race.playful||M>0)){let e=0;M>0&&(e+=ui.playful.vars(1)[0]*M),t.race.playful&&(e+=ui.playful.vars()[0]),p+=t.civic.hunter.workers*e,t.city.morale.unemployed=t.civic.hunter.workers*e}else y-=t.civic.hunter.workers/k;t.race.optimistic&&(y+=ui.optimistic.vars()[0]);let P=Pi("gecko");if(P>0&&(y+=ui.optimistic.vars(1)[0]*P),t.race.pessimistic&&(y-=ui.pessimistic.vars()[0]),t.civic.garrison){let e=2;t.city.ptrait.includes("mellow")&&(e*=Si.mellow.vars()[0]);let a=t.civic.garrison.max/e;t.race.high_pop&&(a/=ui.high_pop.vars()[0]),y-=a}if(r.p.consume.Money[F("trade")]=0,t.tech.trade||t.race.banana&&t.tech.primitive&&t.tech.primitive>=3){let e=0,s=N("dealmaker",0);Object.keys(t.resource).forEach((function(i){if(t.resource[i].trade>0){e+=t.resource[i].trade;let c=yr(i)*t.resource[i].trade;if(t.resource.Money.amount>=c*f){let e=Za[i];s&&(e*=1+s/100),t.race.persuasive&&(e*=1+ui.persuasive.vars()[0]*t.race.persuasive/100),t.race.merchant&&(e*=1+ui.merchant.vars()[1]/100);let o=Pi("goblin");if(o>0&&(e*=1+ui.merchant.vars(1)[1]/100*o),"capricorn"===a&&(e*=1+H("capricorn")[0]/100),t.genes.trader&&(e*=1+lc()/100),t.stats.achieve.hasOwnProperty("trade")){let a=2*t.stats.achieve.trade.l;a>10&&(a=10),e*=1+a/100}t.race.truepath&&(e*=1-t.civic.foreign.gov3.hstl/101),Vi(i,t.resource[i].trade*f*e),Vi("Money",-c*f),r.p.consume.Money[F("trade")]-=c,r.p.consume[i][F("trade")]=t.resource[i].trade*e}Oo()}else if(t.resource[i].trade<0){e-=t.resource[i].trade;let a=vr(i)*t.resource[i].trade,s=Za[i];if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),s*=1-e/100}t.resource[i].amount>=s*f&&(Vi(i,t.resource[i].trade*f*s),Vi("Money",-a*f),r.p.consume.Money[F("trade")]-=a,r.p.consume[i][F("trade")]=t.resource[i].trade*s),Oo()}})),t.city.market.trade=e}if(0===r.p.consume.Money[F("trade")]&&delete r.p.consume.Money[F("trade")],t.tech.alchemy){let e=0,a=0,s=0;Object.keys(t.race.alchemy).forEach((function(i){if(t.race.alchemy[i]>0){let c=Number(t.race.alchemy[i]);if(t.resource.Mana.amount=f){let s=t.resource[i].basic&&t.tech.alchemy>=2?8*Za[i]:2*Za[i];t.race.witch_hunter&&(s*=3),t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg&&(s*=t.stats.achieve.soul_sponge.mg+1),Vi(i,c*f*s),Vi("Mana",-c*f),Vi("Crystal",-.15*c*f),e-=c,a-=.15*c,r.p.consume[i][F("tab_alchemy")]=c*s,"magic"===t.race.universe&&!t.resource[i].basic&&t.tech.alchemy>=2&&Xc("fullmetal")}}})),t.race.totTransmute=s,r.p.consume.Mana[F("tab_alchemy")]=e,r.p.consume.Crystal[F("tab_alchemy")]=a}if(t.galaxy.trade&&(n.hasOwnProperty("freighter")||n.hasOwnProperty("super_freighter"))){let e=0;t.galaxy.freighter&&(e+=2*n.freighter),t.galaxy.super_freighter&&(e+=5*n.super_freighter),t.galaxy.trade.max=e;let s=0,i=dr();for(let c=0;c0&&(u*=1+ui.merchant.vars(1)[1]/100*p),"capricorn"===a&&(u*=1+H("capricorn")[0]/100),t.genes.trader&&(u*=1+lc()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),u*=1+e/50,n*=1-e/100}s+=t.galaxy.trade[`f${c}`],s>e&&(t.galaxy.trade[`f${c}`]-=s-e,t.galaxy.trade[`f${c}`]<0&&(t.galaxy.trade[`f${c}`]=0));let h=Et("gxy_gorddon");for(let e=0;e0&&(r.p.consume[o][F("trade")]?r.p.consume[o][F("trade")]-=d:r.p.consume[o][F("trade")]=-d),_>0&&(r.p.consume[l][F("trade")]?r.p.consume[l][F("trade")]+=_:r.p.consume[l][F("trade")]=_),h<1&&(r.p.consume[l][F("galaxy_piracy")]?r.p.consume[l][F("galaxy_piracy")]+=-(1-h)*_:r.p.consume[l][F("galaxy_piracy")]=-(1-h)*_),0===r.p.consume[o][F("trade")]&&delete r.p.consume[o][F("trade")],0===r.p.consume[l][F("trade")]&&delete r.p.consume[l][F("trade")]}t.galaxy.trade.cur=s}t.race.deconstructor&&t.city.nanite_factory&&Vs.forEach((function(e){if(t.resource[e].display){let a=t.city.nanite_factory[e]*f;if(a>0&&(t.resource[e].amount=1e3){let e=t.race.lone_survivor?100:1e4;C-=e,O+=e,s[F("tau_star_ringworld")]=e}if(t.interstellar.orichalcum_sphere&&t.interstellar.orichalcum_sphere.count>0){let e=0;e=t.interstellar.orichalcum_sphere.count>=100?cc(1750):cc(750+8*t.interstellar.orichalcum_sphere.count),C-=e,O+=e,s[F("interstellar_dyson_sphere_title")]=e,delete s[F("tech_dyson_net")]}else if(t.interstellar.dyson_sphere&&t.interstellar.dyson_sphere.count>0){let e=0;e=t.interstellar.dyson_sphere.count>=100?cc(750):cc(175+5*t.interstellar.dyson_sphere.count),C-=e,O+=e,s[F("interstellar_dyson_sphere_title")]=e,delete s[F("tech_dyson_net")]}else if(t.interstellar.dyson&&t.interstellar.dyson.count>=1){let e=0;e=t.interstellar.dyson.count>=100?cc(175):cc(1.25*t.interstellar.dyson.count),C-=e,O+=e,s[F("tech_dyson_net")]=e}if(t.interstellar.stellar_engine&&t.interstellar.stellar_engine.count>=100){let e=t.tech.gravity&&t.tech.gravity>=2?13.5:7.5,a=t.interstellar.stellar_engine.mass;t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12));let r=cc(20+(a-8)*e+t.interstellar.stellar_engine.exotic*e*10);C-=r,O+=r,s[F("tech_stellar_engine")]=r}if([{r:"city",s:"coal_power"},{r:"city",s:"oil_power"},{r:"city",s:"fission_power"},{r:"spc_hell",s:"geothermal"},{r:"spc_dwarf",s:"e_reactor"},{r:"int_alpha",s:"fusion"},{r:"tau_home",s:"fusion_generator"},{r:"tau_gas2",s:"alien_space_station"}].forEach((function(e){let a=Tt(e.r),c="city"===e.r?e.r:a,o="city"===e.r?Qr.city:Qr[a][e.r],n="string"==typeof o[e.s].title?o[e.s].title:o[e.s].title();if(t[c][e.s]&&t[c][e.s].on){let a=o[e.s].powered();if(i[e.s]=t[c][e.s].on,o[e.s].hasOwnProperty("p_fuel")){let t=o[e.s].p_fuel();Array.isArray(t)||(t=[t]);for(let a=0;a=3&&i.coal_power){let e=.35*i.coal_power*Pe("psychic_boost","Uranium");r.p.Uranium[F("city_coal_ash")]=e/65/d,Vi("Uranium",e*f/65)}if(t.space.hydrogen_plant){let e=Qr.space.spc_titan.hydrogen_plant.powered();t.space.hydrogen_plant.on>t.space.electrolysis.on&&(t.space.hydrogen_plant.on=t.space.electrolysis.on);let a=t.space.hydrogen_plant.on*e;C+=a,O-=a,s[F("space_hydrogen_plant_title")]=-a}if(t.portal.inferno_power){let e=Qr.portal.prtl_ruins.inferno_power.fuel,a=t.portal.inferno_power.on;Object.keys(e).forEach((function(s){let i=a*e[s];for(;i*f>t.resource[s].amount+(t.resource[s].diff>0?t.resource[s].diff*f:0)&&i>0;)a--,i-=e[s];r.p.consume[s][F("portal_inferno_power_title")]=-i,Vi(s,-i*f)}));let i=a*Qr.portal.prtl_ruins.inferno_power.powered();C+=i,O-=i,s[F("portal_inferno_power_title")]=-i}if(t.space.swarm_satellite&&t.space.swarm_control){let e=t.space.swarm_satellite.count;e>t.space.swarm_control.s_max&&(e=t.space.swarm_control.s_max),t.space.swarm_control.support=e;let a=.35;t.tech.swarm>=4&&(a+=.15*(t.tech.swarm-3)),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1&&(a+=.15),t.blood.illuminate&&(a+=.01*t.blood.illuminate),a=+a.toFixed(2);let r=cc(e*a);C-=r,O+=r,s[F("space_sun_swarm_satellite_title")]=r}if(t.city.mill&&t.tech.agriculture&&t.tech.agriculture>=6){let e=cc(t.city.mill.on*Qr.city.mill.powered());C+=e,O-=e,s[F("city_mill_title2")]=-e}if(t.city.windmill&&t.tech.wind_plant){let e=cc(t.city.windmill.count*Qr.city.windmill.powered());C+=e,O-=e,s[F("city_mill_title2")]=-e}if(t.race.powered){let e=ui.powered.vars()[0]*t.resource[t.race.species].amount;t.race.discharge&&t.race.discharge>0&&(e=+(1.25*e).toFixed(3)),O-=e}t.race.replicator&&(t.city.replicator={count:t.race.replicator.pow,on:t.race.replicator.pow});let j=t.power;if(t.settings.lowPowerBalance){let e=0;for(let a=0;a=0;b--){let e=j[b].split(":"),c=Tt(e[0]),o="city"===e[0]?e[0]:c,n="city"===e[0]?Qr.city:Qr[c][e[0]];if(t[o][e[1]]&&t[o][e[1]].on&&(i[e[1]]=t[o][e[1]].on,n[e[1]].hasOwnProperty("p_fuel"))){let t=n[e[1]].p_fuel();Array.isArray(t)||(t=[t]);for(let s=0;sO&&i[r[1]]>0){let e="city"===r[0]?"city":Tt(r[0]),s="city"===r[0]?Qr.city:Qr[e][r[0]],c=s[r[1]].powerBalancer();if(c){let o=i[r[1]];c.forEach((function(i){let c=0;if(i.hasOwnProperty("r")&&i.hasOwnProperty("k")){let n=t[e][r[1]][i.k]?t[e][r[1]][i.k]:0;t.resource[i.r].odif&&t.resource[i.r].odif<0&&(t.resource[i.r].odif=0);let l=t.resource[i.r].diff+(t.resource[i.r].odif?t.resource[i.r].odif:0);for(;l-c*n>n&&o>0&&a>O;)o--,c++,a-=s[r[1]].powered();t.resource[i.r].odif=n*c}else if(i.hasOwnProperty("s")){let n=s[r[1]].support();t[e][r[1]].soff&&t[e][r[1]].soff<0&&(t[e][r[1]].soff=0);let l=i.s+(t[e][r[1]].soff?t[e][r[1]].soff:0);for(;l-n*c>=n&&o>0&&a>O;)o--,c++,a-=s[r[1]].powered();t[e][r[1]].soff=n*c}})),i[r[1]]=o}}}for(b=j.length-1;b>=0;b--){let e=j[b].split(":"),r=Tt(e[0]),s="city"===e[0]?e[0]:r,c="city"===e[0]?Qr.city:Qr[r][e[0]];if(t[s][e[1]]&&t[s][e[1]].on){let r=c[e[1]].powered();for(;a>O&&i[e[1]]>0;)a-=r,i[e[1]]--;i[e[1]]!==t[s][e[1]].on?($(`#${s}-${e[1]} .on`).addClass("warn"),$(`#${s}-${e[1]} .on`).prop("title",`ON ${i[e[1]]}/${t[s][e[1]].on}`)):($(`#${s}-${e[1]} .on`).removeClass("warn"),$(`#${s}-${e[1]} .on`).prop("title","ON"))}else i[e[1]]=0,$(`#${s}-${e[1]} .on`).removeClass("warn"),$(`#${s}-${e[1]} .on`).prop("title","ON")}O-=e}else for(b=0;bO&&o>0;)o-=c[e[1]].powered(),i[e[1]]--;if(O-=t[s][e[1]].on*a,c[e[1]].hasOwnProperty("p_fuel")){let t=c[e[1]].p_fuel();Array.isArray(t)||(t=[t]);for(let a=0;at.resource.Elerium.amount&&a>0;)a-=e,i.foothold--;r.p.consume.Elerium[F("galaxy_foothold")]=-a,Vi("Elerium",-a*f)}[{a:"space",r:"spc_moon",s:"moon_base",g:"moon"},{a:"space",r:"spc_red",s:"spaceport",g:"red"},{a:"space",r:"spc_titan",s:"electrolysis",g:"titan"},{a:"space",r:"spc_titan",r2:"spc_enceladus",s:"titan_spaceport",g:"enceladus"},{a:"space",r:"spc_eris",s:"drone_control",g:"eris"},{a:"tauceti",r:"tau_home",s:"orbital_station",g:"tau_home"},{a:"tauceti",r:"tau_red",s:"orbital_platform",g:"tau_red"},{a:"tauceti",r:"tau_roid",s:"patrol_ship",g:"tau_roid",oc:!0}].forEach((function(e){if(e.r2=e.r2||e.r,t[e.a][e.s]&&t[e.a][e.s].count>0){if(j.includes(`${e.r}:${e.s}`)||(i[e.s]=t[e.a][e.s].on),Qr[e.a][e.r][e.s].hasOwnProperty("support_fuel")){let a=Qr[e.a][e.r][e.s].support_fuel();Array.isArray(a)||(a=[a]);for(let s=0;s=2?i.nav_beacon*Qr.space.spc_home.nav_beacon.support():0;break;case"red":t[e.a][e.s].s_max+=t.tech.mars&&t.tech.mars>=3?i.red_tower*Qr.space.spc_red.red_tower.support():0,t[e.a][e.s].s_max+=t.tech.luna&&t.tech.luna>=3?i.nav_beacon*Qr.space.spc_home.nav_beacon.support():0;break;case"tau_home":t[e.a][e.s].s_max+=i.tau_farm?i.tau_farm:0}}if(t[e.a][e.s]&&"spc_eris"===e.r&&!i.ai_core2&&(t[e.a][e.s].s_max=0),t[e.a][e.s]){let s=0,i=t.support[e.g].map((e=>e.split(":")[1]));for(var a=0;at[e.a][e.s].s_max&&!e.oc?(l-=s+l-t[e.a][e.s].s_max,$(`#${o} .on`).addClass("warn"),$(`#${o} .on`).prop("title",`ON ${l}/${t[e.a][i[a]].on}`)):($(`#${o} .on`).removeClass("warn"),$(`#${o} .on`).prop("title","ON")),Qr[e.a][e.r2][i[a]].hasOwnProperty("support_fuel")){let t=Qr[e.a][e.r2][i[a]].support_fuel();Array.isArray(t)||(t=[t]);for(let s=0;s0){let e=i.red_factory*Jt(1,!0);Vi("Helium_3",-e*f),r.p.consume.Helium_3[F("space_red_factory_title")]=-e}if(i.int_factory&&i.int_factory>0){let e=i.int_factory*Yt(5);Vi("Deuterium",-e*f),r.p.consume.Deuterium[F("interstellar_int_factory_title")]=-e}if(c.water_freighter&&c.water_freighter>0){let e=Jt(5,!0),t=c.water_freighter*e;for(let a=0;a0){let e=+Yt(5),a=i.starport*e;r.p.consume.Helium_3[F("interstellar_alpha_starport_title")]=-a;for(let t=0;te.split(":")[1]));for(b=0;bt.interstellar.starport.s_max?(r-=e+r-t.interstellar.starport.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.interstellar[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r,o[a[b]]=r}else o[a[b]]=0;if(t.interstellar.starport.support=e,t.interstellar.hasOwnProperty("mining_droid")&&t.interstellar.mining_droid.count>0){let e=o.mining_droid,a=t.interstellar.mining_droid.on,r=a>0?e/a:0,s=a;["adam","uran","coal","alum"].forEach((function(e){s-=t.interstellar.mining_droid[e],s<0&&(t.interstellar.mining_droid[e]+=s,s=0),z[e]=t.interstellar.mining_droid[e]*r}))}}if(t.galaxy.starbase&&t.galaxy.starbase.count>0){let e=+Yt(25),a=i.starbase*e;r.p.consume.Helium_3[F("galaxy_starbase")]=-a;for(let t=0;te.split(":")[1]));for(b=0;bt.galaxy.starbase.s_max?(r-=e+r-t.galaxy.starbase.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.galaxy[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r*-Qr.galaxy.gxy_gateway[a[b]].support(),n[a[b]]=r}else n[a[b]]=0;t.galaxy.starbase.support=e}if(t.galaxy.foothold&&t.galaxy.foothold.count>0){t.galaxy.foothold.s_max=i.foothold*Qr.galaxy.gxy_alien2.foothold.support();let e=0,a=t.support.alien2.map((e=>e.split(":")[1]));for(b=0;bt.galaxy.foothold.s_max?(r-=e+r-t.galaxy.foothold.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.galaxy[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r*-Qr.galaxy.gxy_alien2[a[b]].support(),n[a[b]]=r}else n[a[b]]=0;t.galaxy.foothold.support=e}if(t.portal.guard_post){if(t.portal.guard_post.s_max=t.portal.guard_post.count*Qr.portal.prtl_ruins.guard_post.support(),t.portal.guard_post.on>0){let e=t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(i.soul_forge){let t=ba();t<=e&&(e-=t)}ee.split(":")[1]));for(b=0;bt.portal.harbour.s_max?(r-=e+r-t.portal.harbour.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.portal[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r*-Qr.portal.prtl_lake[a[b]].support(),n[a[b]]=r}else n[a[b]]=0;t.portal.harbour.support=e}if(t.portal.purifier){t.portal.purifier.s_max=i.purifier*Qr.portal.prtl_spire.purifier.support();let e=0,a=t.support.spire.map((e=>e.split(":")[1]));for(b=0;bt.portal.purifier.s_max?(r-=e+r-t.portal.purifier.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.portal[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r*-Qr.portal.prtl_spire[a[b]].support(),l[a[b]]=r}else l[a[b]]=0;t.portal.purifier.support=e}if(t.space.space_station&&t.space.space_station.count>0){let e=+Jt(2.5,!0),t=i.space_station*e;r.p.consume.Helium_3[F("space_belt_station_title")]=-t;for(let a=0;ae.split(":")[1]));for(b=0;bt.space.space_station.s_max){let i=e+r*-Qr.space.spc_belt[a[b]].support()-t.space.space_station.s_max;r-=Math.ceil(i/-Qr.space.spc_belt[a[b]].support()),$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.space[a[b]].on}`)}else $(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON");e+=r*-Qr.space.spc_belt[a[b]].support(),c[a[b]]=r}else c[a[b]]=0;t.space.space_station.support=e}if(t.interstellar.nexus&&t.interstellar.nexus.count>0){let e=350,a=i.nexus*e;r.p.consume.Money[F("interstellar_nexus_bd")]=-a;for(let t=0;te.split(":")[1]));for(b=0;bt.interstellar.nexus.s_max?(r-=e+r-t.interstellar.nexus.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.interstellar[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r,o[a[b]]=r}else o[a[b]]=0;t.interstellar.nexus.support=e}if(t.interstellar.xfer_station&&i.xfer_station){let e=.28,t=i.xfer_station*e;r.p.consume.Uranium[F("interstellar_xfer_station_title")]=-t;for(let a=0;a0){let e=+Jt(2,!0),t=i.outpost*e;r.p.consume.Oil[F("space_gas_moon_outpost_bd")]=-t;for(let a=0;a0){let e=+Yt(3),t=i.neutron_miner*e;r.p.consume.Helium_3[F("interstellar_neutron_miner_title")]=-t;for(let a=0;ae.split(":")[1]))},{area:"galaxy",region:"gxy_gorddon",ships:["freighter"],req:"embassy"},{area:"galaxy",region:"gxy_alien1",ships:["super_freighter"],req:"embassy"},{area:"galaxy",region:"gxy_alien2",ships:["armed_miner","scavenger"],req:"foothold"},{area:"galaxy",region:"gxy_chthonian",ships:["minelayer","raider"],req:"starbase"},{area:"portal",region:"prtl_lake",ships:["bireme","transport"],req:"harbour"}];let A=0,T=0,E=0;for(let e=0;eQr[a][r][i].ship.civ()&&(t.civic[t.civic.d_job].workers-=Qr[a][r][i].ship.civ(),t.civic.crew.workers+=Qr[a][r][i].ship.civ(),t[a][i].crew+=Qr[a][r][i].ship.civ()),t[a][i].crew>t[a][i].on*Qr[a][r][i].ship.civ()&&(t.civic[t.civic.d_job].workers+=Qr[a][r][i].ship.civ(),t.civic.crew.workers-=Qr[a][r][i].ship.civ(),t[a][i].crew-=Qr[a][r][i].ship.civ()),t.civic.crew.assigned=t.civic.crew.workers,A+=t[a][i].crew,E+=t[a][i].crew),Qr[a][r][i].ship.mil&&t[a][i].hasOwnProperty("mil")){if(t[a][i].mil!==t[a][i].on*Qr[a][r][i].ship.mil()&&(t[a][i].mil=t[a][i].on*Qr[a][r][i].ship.mil()),t.civic.garrison.workers-t.portal.fortress.garrison<0){let e=t.civic.garrison.workers-t.portal.fortress.garrison;t[a][i].mil-=e}T+t[a][i].mil>t.civic.garrison.workers-t.portal.fortress.garrison&&(t[a][i].mil=t.civic.garrison.workers-t.portal.fortress.garrison-T),t[a][i].mil<0&&(t[a][i].mil=0),T+=t[a][i].mil}t[a][i].crew0)&&(T+=it(e))})),t.civic.garrison.crew=T),Object.keys(ca).forEach((function(e){if(t.civic[e]&&("crew"!==e&&(E+=t.civic[e].workers,E>t.resource[t.race.species].amount&&(t.civic[e].workers-=E-t.resource[t.race.species].amount),t.civic[e].workers<0&&(t.civic[e].workers=0)),"unemployed"!==e&&"hunter"!==e&&"forager"!==e)){let a=t.civic[e].stress;if(t.city.ptrait.includes("mellow")&&(a+=Si.mellow.vars()[1]),t.race.content){let r="hell_surveyor"===e?.2:.4;a+=t.race.content*r}t.city.ptrait.includes("dense")&&"miner"===e&&(a-=Si.dense.vars()[1]),t.race.freespirit&&"farmer"!==e&&"lumberjack"!==e&&"quarry_worker"!==e&&"crystal_miner"!==e&&"scavenger"!==e&&(a/=1+ui.freespirit.vars()[0]/100);let r=t.civic[e].workers;t.race.high_pop&&(r/=ui.high_pop.vars()[0]),t.race.sky_lover&&["miner","coal_miner","crystal_miner","pit_miner"].includes(e)&&(r*=1+ui.sky_lover.vars()[0]/100),y-=r/a}})),t.civic[t.civic.d_job].workers+=t.resource[t.race.species].amount-E,t.civic[t.civic.d_job].workers<0&&(t.civic[t.civic.d_job].workers=0),Object.keys(ca).forEach((function(e){"craftsman"!==e&&t.civic[e]&&t.civic[e].workers0&&t.civic[e].workers40){let e=t.civic.taxes.tax_rate-40;t.city.morale.tax-=.5*e,p-=.5*e}if("oligarchy"===t.civic.govern.type&&t.civic.taxes.tax_rate>20){let e=t.civic.taxes.tax_rate-20;t.city.morale.tax+=.5*e,p+=.5*e}if(("autocracy"!==t.civic.govern.type&&!t.race.blood_thirst||t.race.immoral)&&t.civic.garrison.protest+t.civic.garrison.fatigue>2){let e=t.race.immoral?1+ui.immoral.vars()[0]/100:1,a=Math.round(Math.log2(t.civic.garrison.protest+t.civic.garrison.fatigue)*e);t.city.morale.warmonger=t.race.immoral?a:-a,p+=t.city.morale.warmonger}else t.city.morale.warmonger=0;let K=100;if(K+=t.city.casino?i.casino:0,K+=t.space.spc_casino?i.spc_casino:0,K+=t.tauceti.tauceti_casino?i.tauceti_casino:0,t.city.amphitheatre){let e=N("athleticism",0);K+=e?t.city.amphitheatre.count*e:t.city.amphitheatre.count}if(c.vr_center&&(K+=2*c.vr_center),o.zoo&&(K+=2*o.zoo),i.resort&&(K+=2*i.resort),t.tech.superstar){let e=t.race.high_pop?Me(1):1;K+=na(t.civic.entertainer.workers,"entertainer")*e}if(wo=K,t.tech.monuments){let e=N("gaslighter",2),a=e?2-e:2;wo+=t.tech.monuments*a}if(t.civic.taxes.tax_rate<20&&!t.race.banana&&(wo+=10-Math.floor(t.civic.taxes.tax_rate/2)),t.stats.achieve.joyless&&(wo+=2*t.stats.achieve.joyless.l),t.race.motivated){let e=Math.ceil(t.race.motivated**.4);wo+=Math.round(e/2)}let L=50;if(t.race.optimistic&&(L+=ui.optimistic.vars()[1]),P>0&&(L+=Math.round(ui.optimistic.vars(1)[1]*P)),t.race.truepath&&(L-=25),t.civic.govern.fr>0){let e=p/2;t.city.morale.rev=e,p-=e,L-=10}else t.city.morale.rev=0;if(t.race.tormented)if(p>100){let e=p-100;e=Math.ceil(e*ui.tormented.vars()[0]/100),p-=e,t.city.tormented=e}else t.city.tormented=0;else delete t.city.tormented;if(t.city.morale.potential=+p.toFixed(1),pwo&&(p=wo),t.city.morale.cap=wo,t.city.morale.current=p,t.city.morale.current<100)if(t.race.blissful){let e=t.city.morale.current-100,a=ui.blissful.vars()[0]/100;d*=1+e*a/100,r.p.Global[F("morale")]=e*a+"%"}else d*=t.city.morale.current/100,r.p.Global[F("morale")]=t.city.morale.current-100+"%";else d*=1+(t.city.morale.current-100)/200,r.p.Global[F("morale")]=(t.city.morale.current-100)/2+"%";if(t.race.lazy&&2===t.city.calendar.temp&&(r.p.Global[F("trait_lazy_bd")]="-"+ui.lazy.vars()[0]+"%",d*=1-ui.lazy.vars()[0]/100),t.race.distracted&&(r.p.Global[F("event_m_curious3_bd")]="-5%",d*=.95),t.race.stimulated&&(r.p.Global[F("event_m_curious4_bd")]="+10%",d*=1.1),t.race.selenophobia){let e=t.city.calendar.moon>14?28-t.city.calendar.moon:t.city.calendar.moon;r.p.Global[F("moon_phase")]=-e+ui.selenophobia.vars()[0]+"%",e=1+ui.selenophobia.vars()[0]/100-e/100,d*=e}if(t.interstellar.mass_ejector){let e=0,a=0,s=0;Object.keys(t.interstellar.mass_ejector).forEach((function(c){if(Va[c]){let o=t.interstellar.mass_ejector[c];e+o>1e3*i.mass_ejector&&(o=1e3*i.mass_ejector-e),e+=o,o>0&&(r.p.consume[c][F("interstellar_blackhole_name")]=-o),o*f>t.resource[c].amount&&(o=t.resource[c].amount/f),o<0&&(o=0),Vi(c,-.25*o),a+=o*Va[c],"magic"===t.race.universe||"Elerium"!==c&&"Infernite"!==c||(s+=o*Va[c])}})),t.interstellar.mass_ejector.mass=a,t.interstellar.mass_ejector.total=e,t.interstellar.stellar_engine.mass+=a/1e10*f,t.interstellar.stellar_engine.exotic+=s/1e10*f}if(t.portal.transport&&t.portal.purifier){let e=0,a=0,s=t.blood.spire&&t.blood.spire>=2?.8:.85;if(Object.keys(t.portal.transport.cargo).forEach((function(i){if(Ja[i]){let c=t.portal.transport.cargo[i];e+c>5*n.transport&&(c=5*n.transport-e),e+=c;let o=c*Ja[i].out;for(;o*f>t.resource[i].amount&&o>0;)o-=Ja[i].out,c--;o>0&&(r.p.consume[i][F("portal_transport_title")]=-o);let l=1-s**(n.bireme||0);Vi(i,-.25*o),a+=Number(c*Ja[i].in*f*l)}})),t.portal.mechbay)for(let e=0;et.portal.purifier.sup_max&&(t.portal.purifier.supply=t.portal.purifier.sup_max)}if(t.race.carnivore&&!t.race.herbivore&&!t.race.soul_eater&&!t.race.artifical&&t.resource.Food.amount>10){let e=ui.carnivore.vars()[0]/100,a=+((t.resource.Food.amount-10)*e).toFixed(3);t.city.smokehouse&&(a*=.9**t.city.smokehouse.count),Vi("Food",-a*f),r.p.consume.Food[F("spoilage")]=-a}if(t.race.gnawer){let e=t.race.kindling_kindred||t.race.smoldering?"Stone":"Lumber";if(t.resource[e].display){let a=(t.resource[t.race.species].amount+t.civic.garrison.workers)*ui.gnawer.vars()[0];r.p.consume[e][F("trait_gnawer_bd")]=-a,Vi(e,-a*f)}}var x=!0;if(t.resource[t.race.species].amount>=1||t.city.farm||t.city.soul_well||t.city.compost||t.city.tourist_center||t.city.transmitter){let e=0,s="virgo"===a?1+H("virgo")[0]/100:1;if(t.race.artifical)t.city.transmitter&&(e=i.transmitter*Pe("transmitter")*Pe("psychic_boost","Food"),r.p.Food[F("city_transmitter")]=e+"v",t.city.transmitter.lpmod=Pe("transmitter")*d*Pe("psychic_boost","Food"));else if(t.race.detritivore){if(t.city.compost){let a=t.city.compost.on;if(!t.race.kindling_kindred){let e=.5,s=a*e;for(;s*f>t.resource.Lumber.amount&&s>0;)s-=e,a--;r.p.consume.Lumber[F("city_compost_heap")]=-s,Vi("Lumber",-s*f)}let s=ui.detritivore.vars()[0]/100,i=a*(1.2+t.tech.compost*s);i*="grassland"===t.city.biome?ji.grassland.vars()[0]:1,i*="savanna"===t.city.biome?ji.savanna.vars()[0]:1,i*="ashland"===t.city.biome?ji.ashland.vars()[0]:1,i*="volcanic"===t.city.biome?ji.volcanic.vars()[0]:1,i*="hellscape"===t.city.biome?ji.hellscape.vars()[0]:1,i*=t.city.ptrait.includes("trashed")?Si.trashed.vars()[0]:1,i*=Pe("psychic_boost","Food"),r.p.Food[F("city_compost_heap")]=i+"v",e+=i}}else if(t.race.carnivore||t.race.soul_eater){let a=xe(),s=na(t.civic.hunter.workers,"hunter");if(s*=pi(s,"hunting"),t.race.servants&&(s+=t.race.servants.jobs.hunter),s*=a*(t.race.carnivore?2:.5),t.race.ghostly&&(s*=1+ui.ghostly.vars()[0]/100),s*=Pe("psychic_boost","Food"),r.p.Food[F(t.race.unfathomable?"job_raider":"job_hunter")]=s+"v",t.race.carnivore&&t.city.lodge&&s>0&&(s*=1+t.city.lodge.count/20,r.p.Food[`ᄂ${F("city_lodge")}`]=5*t.city.lodge.count+"%"),t.city.soul_well){let e=t.city.soul_well.count*(t.race.ghostly?2+ui.ghostly.vars()[1]:2);s+=e*Pe("psychic_boost","Food"),r.p.Food[F("city_soul_well")]=e+"v"}e+=s}else if(t.race.unfathomable){if(t.city.captive_housing){let a=xe(),s=na(t.civic.hunter.workers,"hunter")*a;s*=pi(s,"hunting"),t.race.servants&&(s+=t.race.servants.jobs.hunter*a);let i=.008*s;if(t.city.captive_housing.cattle0&&(s-=Math.round(t.city.captive_housing.cattle**1.25),s=t.city.captive_housing.cattle**2&&(t.city.captive_housing.cattle++,t.city.captive_housing.cattleCatch=0),t.city.captive_housing.cattle>0&&t.resource.Food.amount<.01*t.resource.Food.max&&(t.city.captive_housing.cattle--,t.resource.Food.amount+=1e3,t.stats.cattle++)),t.city.captive_housing.cattle>0){let a=t.city.captive_housing.cattle/3*Pe("psychic_boost","Food");r.p.Food[F("city_captive_housing_cattle_bd")]=a+"v",e+=a}}}else if(t.city.farm||t.race.forager){let a=1;if(t.race.submerged||(0===t.city.calendar.temp&&(0===t.city.calendar.weather?a*=t.race.chilled?1+ui.chilled.vars()[3]/100:.7:a*=t.race.chilled?1+ui.chilled.vars()[4]/100:.85),2===t.city.calendar.weather&&(a*=t.race.chilled?1-ui.chilled.vars()[5]/100:1.1)),t.race.forager){let a=1+(t.tech.foraging?.75*t.tech.foraging:0),s=na(t.civic.forager.workers,"forager");t.race.servants&&(s+=t.race.servants.jobs.forager);let i=s*a*.35;r.p.Food[F("job_forager")]=i+"v",e+=i}if(t.city.farm){let i=na(t.civic.farmer.workers,"farmer"),c=0;i>la(t.city.farm.count)&&(c=i-la(t.city.farm.count),i=la(t.city.farm.count));let o=i*pa(!0)+c*pa(!1);if(t.race.servants){let e=la(t.race.servants.jobs.farmer),a=0,r=la(t.city.farm.count)-i;e>r&&(a=e-r,e=r),o+=e*pa(!0,!0)+a*pa(!1,!0)}let n=1;if(t.city.mill){let e=t.tech.agriculture>=5?.05:.03;n+=(t.city.mill.count-t.city.mill.on)*e}r.p.Food[F("job_farmer")]=o+"v",e+=o*s*a*n*h*Pe("psychic_boost","Food"),o>0&&(r.p.Food[`ᄂ${F("city_mill_title1")}`]=100*(n-1)+"%",r.p.Food[`ᄂ${F("sign_virgo")}+0`]=100*(s-1)+"%",r.p.Food[`ᄂ${F("morale_weather")}`]=100*(a-1)+"%",r.p.Food[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%")}}if(t.tauceti.tau_farm&&i.tau_farm){let e=1+.5*(c.colony||0),t=Pe("tau_farm","food")*i.tau_farm*Pe("psychic_boost","Food"),a=t*d*e;r.p.Food[F("tau_home_tau_farm")]=t+"v",t>0&&(r.p.Food[`ᄂ${F("tau_home_colony")}`]=100*(e-1)+"%"),Vi("Food",a*f)}let n=0;t.tech.military&&(n=t.race.herbivore&&!t.race.carnivore||t.race.artifical?0:ke(qe(),"hunting")/3);let l=0,u=ht("spc_red");t.tech.mars&&(l=c.biodome*na(t.civic.colonist.workers,"colonist")*Pe("biodome","food")*Pe("psychic_boost","Food"),(t.race.cataclysm||t.race.orbit_decayed)&&(l+=c.biodome*Pe("biodome","cat_food")*Pe("psychic_boost","Food"))),r.p.Food[Qr.space.spc_red.biodome.title()]=l+"v",l>0&&(r.p.Food[`ᄂ${F("space_syndicate")}+0`]=-100*(1-u)+"%",r.p.Food[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%",r.p.Food[`ᄂ${F("sign_virgo")}+0`]=100*(s-1)+"%");let p=e+n*h+l*u*_*s;p*=d;let m=t.civic.garrison.workers;t.race.parasite&&!t.tech.isolation&&(m-=2,m<0&&(m=0));let g=t.resource[t.race.species].amount+m-.5*(t.civic.unemployed.workers+na(t.civic.hunter.workers,"hunter"));t.race.forager&&(g-=na(t.civic.forager.workers,"forager")),g*=t.race.gluttony?1+ui.gluttony.vars()[0]/100:1,t.race.high_metabolism&&(g*=1+ui.high_metabolism.vars()[0]/100),t.race.sticky&&(g*=1-ui.sticky.vars()[0]/100);let v=Pi("pinguicula");if(v>0&&(g*=1-ui.sticky.vars(1)[0]/100*v),t.race.photosynth)switch(t.city.calendar.weather){case 0:g*=0===t.city.calendar.temp?1:1-ui.photosynth.vars()[2]/100;break;case 1:g*=1-ui.photosynth.vars()[1]/100;break;case 2:g*=1-ui.photosynth.vars()[0]/100}t.race.ravenous&&(g*=1+ui.ravenous.vars()[0]/100,g+=t.resource.Food.amount/ui.ravenous.vars()[1]),t.race.hibernator&&3===t.city.calendar.season&&(g*=1-ui.hibernator.vars()[0]/100),t.race.high_pop&&(g/=ui.high_pop.vars()[0]),r.p.consume.Food[Ac("name")]=-g;let y=0;t.city.tourist_center&&(y=50*t.city.tourist_center.on,r.p.consume.Food[F("tech_tourism")]=-y);let b=0;t.space.spaceport&&(b=i.spaceport*(t.race.cataclysm||t.race.orbit_decayed?2:25),r.p.consume.Food[F("space_red_spaceport_title")]=-b);let w=0;t.interstellar.starport&&(w=100*i.starport,r.p.consume.Food[F("interstellar_alpha_starport_title")]=-w);let $=0;t.galaxy.starbase&&($=i.s_gate*i.starbase*250,r.p.consume.Food[F("galaxy_starbase")]=-$);let k=0;t.space.space_station&&(k=i.space_station*(t.race.cataclysm?1:10),r.p.consume.Food[F("space_belt_station_title")]=-k);let q=0;t.space.space_barracks&&!t.race.cataclysm&&(q=10*t.space.space_barracks.on,r.p.consume.Food[F("tech_space_marines_bd")]=-q);let M=0;t.galaxy.embassy&&(M=i.s_gate*i.embassy*7500,r.p.consume.Food[F("galaxy_embassy")]=-M);let P=0;t.interstellar.zoo&&(P=12e3*o.zoo,r.p.consume.Food[F("tech_zoo")]=-P);let O=p-g-y-b-w-$-k-q-M-P;if(r.p.Food[F("soldiers")]=n+"v",n>0&&(r.p.Food[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),!Vi("Food",O*f))if(t.race.anthropophagite&&t.resource[t.race.species].amount>1)t.resource[t.race.species].amount--,Vi("Food",1e4*ui.anthropophagite.vars()[0]),t.stats.murders++;else{x=!1;let e=1.25;t.race.slow_digestion&&(e+=ui.slow_digestion.vars()[0]);let a=Pi("slitheryn");a>0&&(e+=ui.slow_digestion.vars(1)[0]*a),t.race.humpback&&(e+=ui.humpback.vars()[0]),t.race.atrophy&&(e-=ui.atrophy.vars()[0]),p1&&0===Math.rand(0,400)&&(t.resource[t.race.species].amount--,Vi("Food",1e4*ui.anthropophagite.vars()[0]),t.stats.murders++)}if(t.portal.fortress&&t.portal.fortress.walls<100&&(Vi("Stone",-50)&&(t.portal.fortress.repair++,r.p.consume.Stone[F("portal_fortress_name")]=-200),t.portal.fortress.repair>=Qr.portal.prtl_fortress.info.repair()&&(t.portal.fortress.repair=0,t.portal.fortress.walls++)),t.race.psychic&&t.resource.Energy.display){let e={},t=ui.psychic.vars()[2];e[F("trait_psychic_name")]=t+"v",Vi("Energy",t*f),r.p.Energy=e}if(t.civic.homeless>0){let e=Math.min(t.civic.homeless,t.resource[t.race.species].max-t.resource[t.race.species].amount);t.civic.homeless-=e,t.resource[t.race.species].amount+=e}else if(x&&t.resource.Food.amount>0&&t.resource[t.race.species].max>t.resource[t.race.species].amount)if(t.race.artifical||t.race.spongy&&0===t.city.calendar.weather);else if(!t.race.parasite||0!==t.city.calendar.wind||t.race.cataclysm||t.race.orbit_decayed)if(t.race.vax&&t.race.vax>=100);else{var q=t.tech.reproduction?t.tech.reproduction:0;t.tech.reproduction&&1===e.getMonth()&&14===e.getDate()&&(q+=5),t.race.fast_growth&&(q*=ui.fast_growth.vars()[0],q+=ui.fast_growth.vars()[1]),t.race.spores&&1===t.city.calendar.wind&&(t.race.parasite?q+=ui.spores.vars()[2]:(q+=ui.spores.vars()[0],q*=ui.spores.vars()[1])),t.tech.reproduction&&t.tech.reproduction>=2&&t.city.hospital&&(q+=t.city.hospital.count),t.genes.birth&&(q+=t.genes.birth),t.race.promiscuous&&(q+=ui.promiscuous.vars()[0]*t.race.promiscuous),"libra"===a&&(q*=1+H("libra")[0]/100),t.race.high_pop&&(q*=ui.high_pop.vars()[2]),"taiga"===t.city.biome&&(q*=ji.taiga.vars()[1]);let r=t.city.ptrait.includes("toxic")?t.resource[t.race.species].amount*Si.toxic.vars()[1]:t.resource[t.race.species].amount;t.race.parasite&&(t.race.cataclysm||t.race.orbit_decayed)&&(q=Math.round(q/5),r*=3),Math.rand(0,1.810792884997279*r)<=q&&t.resource[t.race.species].amount++}let D=0,B=0;if(i.s_gate){let e=["freighter","super_freighter","minelayer","raider"];for(let a=0;a0;if(i.s_gate&&o&&t[a][c]&&(t[a][c].crew>0||t[a][c].mil>0)){let e=0;if(Qr[a][r][c].ship.civ()>0&&(e=Math.floor(t[a][c].crew/Qr[a][r][c].ship.civ())),Qr[a][r][c].ship.mil()>0){let s=Math.floor(t[a][c].mil/Qr[a][r][c].ship.mil());(0===Qr[a][r][c].ship.civ()||st.resource.Helium_3.amount+(t.resource.Helium_3.diff>0?t.resource.Helium_3.diff*f:0)&&i>0;)i-=s,e--;Vi("Helium_3",-i*f),D+=i}if(Qr[a][r][c].ship.hasOwnProperty("deuterium")){let s=+Yt(Qr[a][r][c].ship.deuterium).toFixed(2),i=e*s;for(;i*f>t.resource.Deuterium.amount+(t.resource.Deuterium.diff>0?t.resource.Deuterium.diff*f:0)&&i>0;)i-=s,e--;Vi("Deuterium",-i*f),B+=i}n.hasOwnProperty(c)?n[c]=n[c]>e?e:n[c]:n[c]=e}else n[c]=0}}if(r.p.consume.Helium_3[F("galaxy_fuel_consume")]=-D,r.p.consume.Deuterium[F("galaxy_fuel_consume")]=-B,t.space.shipyard&&t.space.shipyard.ships){let e={Oil:0,Helium_3:0,Uranium:0,Elerium:0};t.space.shipyard.ships.forEach((function(a){if("spc_dwarf"!==a.location){let r=lt(a);r.res&&r.burn>0?r.burn*f0?t.resource[r.res].diff*f:0)?(Vi(r.res,-r.burn*f),a.fueled=!0,e[r.res]+=r.burn):a.fueled=!1:a.fueled=!0}})),r.p.consume.Oil[F("outer_shipyard_fleet")]=-e.Oil,r.p.consume.Helium_3[F("outer_shipyard_fleet")]=-e.Helium_3,r.p.consume.Uranium[F("outer_shipyard_fleet")]=-e.Uranium,r.p.consume.Elerium[F("outer_shipyard_fleet")]=-e.Elerium}t.race.emfield&&(t.race.discharge&&t.race.discharge>0?t.race.discharge--:(t.race.emfield++,0===Math.rand(0,500)&&(t.race.discharge=t.race.emfield,t.race.emfield=1)));let G=x?1:.5;if(t.race.angry&&!1===x&&(G-=ui.angry.vars()[0]/100),t.race.malnutrition&&!1===x&&(G+=ui.malnutrition.vars()[0]/100),t.resource.Furs.display){if(t.race.evil||t.race.artifical||t.race.unfathomable){let e=xe(),a=na(t.civic.hunter.workers,"hunter");if(a*=pi(a,"hunting"),t.race.servants&&(a+=la(t.race.servants.jobs.hunter)),a*=e/20,"savanna"===t.city.biome&&(a*=ji.savanna.vars()[1]),t.race.high_pop&&(a=Me(a)),a*=Pe("psychic_boost","Furs"),r.p.Furs[F(t.race.unfathomable?"job_raider":"job_hunter")]=a+"v",a>0&&(r.p.Furs[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),Vi("Furs",a*G*d*f*h),!t.race.soul_eater&&t.race.evil){let e=na(t.civic.lumberjack.workers,"lumberjack");e*=pi(e,"lumberjack"),t.race.servants&&(e+=t.race.servants.jobs.lumberjack),e/=4,e*=Pe("psychic_boost","Furs"),r.p.Furs[F("job_reclaimer")]=e+"v",e>0&&(r.p.Furs[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),Vi("Furs",e*G*d*f*h)}}let e=ke(qe(),"hunting")/10;if("oceanic"===t.city.biome?e*=ji.oceanic.vars()[2]:"tundra"===t.city.biome&&(e*=ji.tundra.vars()[0]),e*=Pe("psychic_boost","Furs"),r.p.Furs[F("soldiers")]=e+"v",e>0&&(r.p.Furs[`ᄂ${F("quarantine")}+2`]=100*(h-1)+"%"),Vi("Furs",e*G*d*h*f),t.race.forager){let e=1+(t.tech.foraging?.5*t.tech.foraging:0),a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.05*Pe("psychic_boost","Furs");r.p.Furs[F("job_forager")]=s+"v",s>0&&(r.p.Furs[`ᄂ${F("quarantine")}+3`]=100*(h-1)+"%"),Vi("Furs",s*G*h*f)}}if(t.resource.Furs.display&&t.tech.isolation&&t.tauceti.womling_farm){let e=t.tauceti.womling_farm.farmers*Pe("psychic_boost","Furs"),a=e*d;r.p.Furs[F("tau_red_womlings")]=e+"v",Vi("Furs",a)}if(t.race.unfathomable&&t.civic.hunter.display){let e=xe(),a=na(t.civic.hunter.workers,"hunter");a*=pi(a,"hunting"),t.race.servants&&(a+=la(t.race.servants.jobs.hunter)),a*=e/20,t.race.high_pop&&(a=Me(a)),["Lumber","Chrysotile","Stone","Crystal","Copper","Iron","Aluminium","Cement","Coal","Oil","Uranium","Steel","Titanium","Alloy","Polymer","Iridium"].forEach((function(e){if(t.resource[e].display){let s=a*Pe("psychic_boost",e)*Za[e]/5;["Crystal","Uranium"].includes(e)?s*=.2:["Alloy","Polymer","Iridium"].includes(e)?s*=.35:["Steel","Cement"].includes(e)?s*=.85:["Titanium"].includes(e)&&(s*=.65),r.p[e][F(t.race.unfathomable?"job_raider":"job_hunter")]=s+"v",s>0&&(r.p[e][`ᄂ${F("quarantine")}+99`]=100*(h-1)+"%"),Vi(e,s*G*d*f*h)}}))}{let e=t.tech.primitive&&t.tech.primitive>=3?1:0;t.race.ancient_ruins&&e++,t.stats.achieve.extinct_junker&&t.stats.achieve.extinct_junker.l>=1&&e++,t.city.ptrait.includes("magnetic")&&(e+=Si.magnetic.vars()[0]),t.race.ascended&&(e+=2);let s=na(t.civic.professor.workers,"professor"),o=t.race.studious?t.civic.professor.impact+ui.studious.vars()[0]:t.civic.professor.impact,n=Pi("elven");n>0&&(o+=ui.studious.vars(1)[0]*n),s*=o,s*=t.race.pompous?1-ui.pompous.vars()[0]/100:1,s*=pi(na(t.civic.professor.workers,"professor"),"science"),t.tech.anthropology&&t.tech.anthropology>=3&&(s*=1+.05*(t.race.cataclysm||t.race.orbit_decayed?t.space.ziggurat?t.space.ziggurat.count:0:t.city.temple.count)),"theocracy"===t.civic.govern.type&&(s*=1-ae.theocracy()[1]/100);let l=na(t.civic.scientist.workers,"scientist");if(l*=t.civic.scientist.impact,l*=pi(na(t.civic.scientist.workers,"scientist"),"science"),t.tech.science>=6&&t.city.wardenclyffe){let e=na(t.civic.professor.workers,"professor");t.race.high_pop&&(e=Me(e)),l*=1+e*i.wardenclyffe*.01}t.space.satellite&&(l*=1+.01*t.space.satellite.count),"theocracy"===t.civic.govern.type&&(l*=1-ae.theocracy()[2]/100);let u=.05,_=N("muckraker",2);_&&(u-=_/100),t.race.autoignition&&(u-=ui.autoignition.vars()[0]/100,u<0&&(u=0));let p=t.city.library?1+t.city.library.count*u:1,h="gemini"===a?1+H("gemini")[0]/100:1,m=0;if(t.arpa.sequence&&t.arpa.sequence.on&&t.arpa.sequence.time>0){let e=50+10*t.race.mutation;t.arpa.sequence.boost&&(e*=4),e*f<=t.resource.Knowledge.amount?(m=e,xo=!0):xo=!1}else t.arpa.hasOwnProperty("sequence")&&null===t.arpa.sequence.time&&(t.arpa.sequence.time=t.arpa.sequence.max),xo=!1;let g=t.tauceti.hasOwnProperty("womling_lab")?t.tauceti.womling_lab.scientist*(t.tech.womling_gene?10:8):0,v=t.tech.isolation?1+.75*(c.infectious_disease_lab||0):1,y=s+l+g;if(y*=G*d,y+=e*d,y*=p*v,r.p.Knowledge[F("job_professor")]=s+"v",r.p.Knowledge[F("job_scientist")]=l+"v",r.p.Knowledge[F("tau_red_womlings")]=g+"v",r.p.Knowledge[F("hunger")]=100*(G-1)+"%",r.p.Knowledge[t.race.unfathomable?F("tech_moondial"):F("tech_sundial")]=e+"v",t.race.inspired&&(r.p.Knowledge[F("event_inspiration_bd")]="100%",y*=2),t.city.library&&(r.p.Knowledge[F("city_library")]=100*(p-1)+"%"),"gemini"===a&&(r.p.Knowledge[F(`sign_${a}`)]=100*(h-1)+"%"),t.tech.isolation&&c.infectious_disease_lab&&(r.p.Knowledge[Qr.tauceti.tau_home.infectious_disease_lab.title()]=100*(v-1)+"%"),"technocracy"===t.civic.govern.type&&(r.p.Knowledge[F("govern_technocracy")]=ae.technocracy()[2]+"%",y*=1+ae.technocracy()[2]/100),m>0&&(y-=m,r.p.consume.Knowledge[F("genome_bd")]=-m),Vi("Knowledge",y*f),t.tech.tau_gas2&&t.tech.tau_gas2>=6&&(!t.tech.alien_data||t.tech.alien_data<6)&&t.tauceti.alien_space_station&&i.alien_space_station){let e=t.tauceti.alien_space_station.focus/100*y;r.p.consume.Knowledge[F("tau_gas2_alien_station")]=-e,Vi("Knowledge",-e*f),t.tauceti.alien_space_station.decrypted+=+e.toFixed(3),t.stats.know+=+e.toFixed(0),t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?1e6:25e7)&&!t.tech.alien_data?(t.tech.alien_data=1,Di(F("tau_gas2_alien_station_data1",[F("tech_dist_womling")]),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?2e6:5e8)&&t.tech.alien_data&&1===t.tech.alien_data?(t.tech.alien_data=2,t.race.tau_food_item=Math.rand(0,10),Di(F("tau_gas2_alien_station_data2",[F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?3e6:75e7)&&t.tech.alien_data&&2===t.tech.alien_data?(t.tech.alien_data=3,Di(F("tau_gas2_alien_station_data3"),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?48e5:12e8)&&t.tech.alien_data&&3===t.tech.alien_data?(t.tech.alien_data=4,t.race.tau_junk_item=Math.rand(0,10),Di(F("tau_gas2_alien_station_data4",[F(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`)]),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?6e6:15e8)&&t.tech.alien_data&&4===t.tech.alien_data?(t.tech.alien_data=5,Di(F("tau_gas2_alien_station_data5"),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?1e7:25e8)&&t.tech.alien_data&&5===t.tech.alien_data&&(t.tech.alien_data=6,t.tauceti.alien_space_station.decrypted=25e8,t.race.lone_survivor?(t.settings.tau.star=!0,t.tech.matrix=2,t.tauceti.ringworld={count:0},Di(F("tau_gas2_alien_station_data6_alt"),"success",!1,["progress"])):Di(F("tau_gas2_alien_station_data6"),"success",!1,["progress"]),ms())}}let R=0;if(t.city.factory){let e=(i.factory||0)+(i.red_factory||0)+2*(i.int_factory||0)+(c.tau_factory||0)*(t.tech.isolation?5:3),a=t.city.factory.on+(t.space.red_factory?t.space.red_factory.on:0)+(t.interstellar.int_factory?2*t.interstellar.int_factory.on:0)+(t.tauceti.tau_factory?t.tauceti.tau_factory.on*(t.tech.isolation?5:3):0),s=a>0?e/a:0,o=a;["Lux","Furs","Alloy","Polymer","Nano","Stanene"].forEach((function(e){o-=t.city.factory[e],o<0&&(t.city.factory[e]+=o,o=0)}));let l=t.tech.factory||0,p=t.tech.isolation?1+.5*(c.colony||0):1;if(t.city.factory.Lux&&t.city.factory.Lux>0){let e=t.city.factory.Lux*Qs.Lux.fur[l]*s,a=t.city.factory.Lux;for(;e*f>t.resource.Furs.amount&&e>0;)e-=Qs.Lux.fur[l]*s,a--;r.p.consume.Furs[F("city_factory")]=-e,Vi("Furs",-e*f);let i=t.resource[t.race.species].amount*Qs.Lux.demand[l]*s;i=Zs(i);let c=a*i*p;R=c*G,t.race.discharge&&t.race.discharge>0&&(c*=.5),c*=d,Vi("Money",c*f)}if(t.city.factory.Furs&&t.city.factory.Furs>0){let e=Qs.Furs.money[l]*s,a=Qs.Furs.polymer[l]*s,i=t.city.factory.Furs*e,c=t.city.factory.Furs*a,o=t.city.factory.Furs;for(;c*f>t.resource.Polymer.amount&&c>0;)c-=a,i-=e,o--;for(;i*f>t.resource.Money.amount&&i>0;)c-=a,i-=e,o--;r.p.consume.Money[F("city_factory")]=-i,r.p.consume.Polymer[F("city_factory")]=-c,Vi("Money",-i*f),Vi("Polymer",-c*f);let n=o*Qs.Furs.output[l]*s*Pe("psychic_boost","Furs");t.race.toxic&&(n*=1+ui.toxic.vars()[0]/100);let _=Pi("shroomi");_>0&&(n*=1+ui.toxic.vars(1)[0]/100*_),"corpocracy"===t.civic.govern.type&&(n*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(n*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(n*=1.1);let h=n*p;if(h*=G*d,r.p.Furs[F("city_factory")]=n+"v",h>0&&(p>0&&(r.p.Furs[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(h*=.5,r.p.Furs[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory)){let e=(u-1)/8+1;h*=e,r.p.Furs[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}Vi("Furs",h*f)}if(t.city.factory.Alloy&&t.city.factory.Alloy>0){let e=t.city.factory.Alloy*Qs.Alloy.copper[l]*s,a=t.city.factory.Alloy*Qs.Alloy.aluminium[l]*s,i=t.city.factory.Alloy;for(;e*f>t.resource.Copper.amount&&e>0;)e-=Qs.Alloy.copper[l]*s,a-=Qs.Alloy.aluminium[l]*s,i--;for(;a*f>t.resource.Aluminium.amount&&a>0;)e-=Qs.Alloy.copper[l]*s,a-=Qs.Alloy.aluminium[l]*s,i--;r.p.consume.Copper[F("city_factory")]=-e,r.p.consume.Aluminium[F("city_factory")]=-a,Vi("Copper",-e*f),Vi("Aluminium",-a*f);let c=i*Qs.Alloy.output[l]*s*Pe("psychic_boost","Alloy");t.race.toxic&&(c*=1+ui.toxic.vars()[0]/100);let o=Pi("shroomi");o>0&&(c*=1+ui.toxic.vars(1)[0]/100*o),t.tech.alloy&&(c*=1.37),t.race.metallurgist&&(c*=1+ui.metallurgist.vars()[0]*t.race.metallurgist/100),"corpocracy"===t.civic.govern.type&&(c*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(c*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(c*=1.1);let n=c*p;if(n*=G*d,r.p.Alloy[F("city_factory")]=c+"v",n>0){if(p>0&&(r.p.Alloy[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(n*=.5,r.p.Alloy[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory){let e=(u-1)/2+1;n*=e,r.p.Alloy[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}r.p.Alloy[F("hunger")]=100*(G-1)+"%"}Vi("Alloy",n*f)}else r.p.Alloy=0;if(t.city.factory.Polymer&&t.city.factory.Polymer>0){let e=t.race.kindling_kindred||t.race.smoldering?Qs.Polymer.oil_kk[l]*s:Qs.Polymer.oil[l]*s,a=t.race.kindling_kindred||t.race.smoldering?0:Qs.Polymer.lumber[l]*s,i=t.city.factory.Polymer*e,c=t.city.factory.Polymer*a,o=t.city.factory.Polymer;for(;c*f>t.resource.Lumber.amount&&c>0;)c-=a,i-=e,o--;for(;i*f>t.resource.Oil.amount&&i>0;)c-=a,i-=e,o--;r.p.consume.Lumber[F("city_factory")]=-c,r.p.consume.Oil[F("city_factory")]=-i,Vi("Lumber",-c*f),Vi("Oil",-i*f);let n=o*Qs.Polymer.output[l]*s*Pe("psychic_boost","Polymer");t.race.toxic&&(n*=1+ui.toxic.vars()[0]/100);let _=Pi("shroomi");_>0&&(n*=1+ui.toxic.vars(1)[0]/100*_),t.tech.polymer>=2&&(n*=1.42),"corpocracy"===t.civic.govern.type&&(n*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(n*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(n*=1.1);let h=n*p;if(h*=G*d,r.p.Polymer[F("city_factory")]=n+"v",h>0&&(p>0&&(r.p.Polymer[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(h*=.5,r.p.Polymer[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory)){let e=(u-1)/2+1;h*=e,r.p.Polymer[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}r.p.Polymer[F("hunger")]=100*(G-1)+"%",Vi("Polymer",h*f)}if(i.s_gate&&t.galaxy.raider&&n.raider>0){let e=2.3*n.raider*Pe("psychic_boost","Polymer"),t=Et("gxy_chthonian"),a=e*d*t*G*_;r.p.Polymer[F("galaxy_raider")]=e+"v",e>0&&(r.p.Polymer[`ᄂ${F("galaxy_piracy")}`]=-100*(1-t)+"%",r.p.Polymer[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),Vi("Polymer",a*f)}if(t.city.factory.Nano&&t.city.factory.Nano>0){let e=Qs.Nano_Tube.coal[l]*s,a=Qs.Nano_Tube.neutronium[l]*s,i=t.city.factory.Nano*e,c=t.city.factory.Nano*a,o=t.city.factory.Nano;for(;c*f>t.resource.Neutronium.amount&&c>0;)c-=a,i-=e,o--;for(;i*f>t.resource.Coal.amount&&i>0;)c-=a,i-=e,o--;r.p.consume.Coal[F("city_factory")]=-i,r.p.consume.Neutronium[F("city_factory")]=-c,Vi("Neutronium",-c*f),Vi("Coal",-i*f);let n=o*Qs.Nano_Tube.output[l]*s*Pe("psychic_boost","Nano_Tube");t.race.toxic&&(n*=1+ui.toxic.vars()[1]/100);let _=Pi("shroomi");_>0&&(n*=1+ui.toxic.vars(1)[1]/100*_),t.tech.polymer>=2&&(n*=1.42),"corpocracy"===t.civic.govern.type&&(n*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(n*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(n*=1.1);let h=n*p;if(h*=G*d,r.p.Nano_Tube[F("city_factory")]=n+"v",h>0){if(p>0&&(r.p.Nano_Tube[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(h*=.5,r.p.Nano_Tube[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory){let e=(u-1)/2+1;h*=e,r.p.Nano_Tube[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}r.p.Nano_Tube[F("hunger")]=100*(G-1)+"%"}Vi("Nano_Tube",h*f)}else r.p.Nano_Tube=0;if(t.city.factory.Stanene&&t.city.factory.Stanene>0){let e=Qs.Stanene.aluminium[l]*s,a=Qs.Stanene.nano[l]*s,i=t.city.factory.Stanene*e,c=t.city.factory.Stanene*a,o=t.city.factory.Stanene;for(;i*f>t.resource.Aluminium.amount&&i>0;)c-=a,i-=e,o--;for(;c*f>t.resource.Nano_Tube.amount&&c>0;)c-=a,i-=e,o--;r.p.consume.Aluminium[F("city_factory")]=r.p.consume.Aluminium[F("city_factory")]?r.p.consume.Aluminium[F("city_factory")]-i:-i,r.p.consume.Nano_Tube[F("city_factory")]=-c,Vi("Aluminium",-i*f),Vi("Nano_Tube",-c*f);let n=o*Qs.Stanene.output[l]*s*Pe("psychic_boost","Stanene");t.race.toxic&&(n*=1+ui.toxic.vars()[1]/100);let _=Pi("shroomi");_>0&&(n*=1+ui.toxic.vars(1)[1]/100*_),"corpocracy"===t.civic.govern.type&&(n*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(n*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(n*=1.1);let h=n*p;if(h*=G*d,r.p.Stanene[F("city_factory")]=n+"v",h>0){if(p>0&&(r.p.Stanene[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(h*=.5,r.p.Stanene[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory){let e=(u-1)/2+1;h*=e,r.p.Stanene[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}r.p.Stanene[F("hunger")]=100*(G-1)+"%"}Vi("Stanene",h*f)}else r.p.Stanene=0}if(t.resource.Furs.display&&(r.p.Furs[F("hunger")]=100*(G-1)+"%"),t.resource.Cement.display){let e=t.race.high_pop?3/ui.high_pop.vars()[0]:3;"ashland"===t.city.biome&&(e*=ji.ashland.vars()[1]);let a=na(t.civic.cement_worker.workers,"cement_worker")*e,s=na(t.civic.cement_worker.workers,"cement_worker");for(;a*f>t.resource.Stone.amount&&a>0;)a-=e,s--;let o=t.tech.isolation?1+.5*(c.colony||0):1;r.p.consume.Stone[F(t.tech.isolation?"job_cement_worker_bd":"city_cement_plant_bd")]=-a,Vi("Stone",-a*f);let n=t.tech.cement>=4?1.2:1;n*=t.civic.cement_worker.impact,n*=pi(na(t.civic.cement_worker.workers,"cement_worker"),"factory"),"ashland"===t.city.biome&&(n*=ji.ashland.vars()[1]),t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=3&&(n*=1.1);let l=s*n*Pe("psychic_boost","Cement");"corpocracy"===t.civic.govern.type&&(l*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(l*=1+ae.socialist()[1]/100);let _=1,p=1;if(t.city.powered&&i.cement_plant){let e=t.tech.cement>=6?.08:.05;_+=i.cement_plant*e,p+=e}let m=1;if(t.tech.ai_core&&i.citadel>0){let e=+(u/1.75).toFixed(1)/100;m+=i.citadel*e}let g=t.tech.isolation?1+.08*c.mining_pit:1,v=t.tech.isolation?1:h;r.p.Cement[F(t.tech.isolation?"job_cement_worker_bd":"city_cement_plant_bd")]=l+"v",l>0&&(t.tech.isolation&&(r.p.Cement[`ᄂ${F("tau_home_colony")}+0`]=100*(o-1)+"%",r.p.Cement[`ᄂ${F("tau_home_mining_pit")}+0`]=100*(g-1)+"%"),r.p.Cement[`ᄂ${F("power")}+0`]=100*(_-1)+"%",r.p.Cement[`ᄂ${F("quarantine")}+0`]=100*(v-1)+"%"),t.race.discharge&&t.race.discharge>0&&i.cement_plant>0&&(_=.5*(_-1)+1,p=.5*(p-1)+1,r.p.Cement[`ᄂ${F("evo_challenge_discharge")}`]="-50%");let y=l*m*o*g;t.city.cement_plant&&(t.city.cement_plant.cnvay=+(y*G*v*d*(p-1)).toFixed(5)),y*=_*G*v*d,t.tech.ai_core&&i.citadel>0&&(r.p.Cement[F("interstellar_citadel_effect_bd")]=100*(m-1)+"%"),r.p.Cement[F("hunger")]=100*(G-1)+"%",Vi("Cement",y*f)}let U=Lc("metal"),W=0,Q=0,Z=0;if(t.city.smelter&&(t.city.smelter.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation)){let e=t.city.smelter.count;i.stellar_forge&&t.tech.star_forge&&t.tech.star_forge>=2&&(e+=2*i.stellar_forge),i.hell_forge&&(e+=3*i.hell_forge),i.ore_refinery&&(e+=i.ore_refinery*(t.tech.isolation?12:4)),t.tech.m_smelting&&t.space.hell_smelter&&(e+=2*t.space.hell_smelter.count),(t.race.cataclysm||t.race.orbit_decayed)&&t.space.geothermal&&(e+=t.space.geothermal.on),t.city.smelter.cap=e,t.tech.star_forge>=2?(t.city.smelter.StarCap=2*i.stellar_forge,t.city.smelter.Star=t.city.smelter.StarCap):t.city.smelter.StarCap=0,t.race.forge&&(t.city.smelter.Wood=0,t.city.smelter.Coal=0,t.city.smelter.Oil=t.city.smelter.cap-t.city.smelter.Star-t.city.smelter.Inferno),!t.race.kindling_kindred&&!t.race.smoldering||t.race.evil||(t.city.smelter.Wood=0);let a=t.race.kindling_kindred||t.race.smoldering?.15:.25,s=0;if(["Wood","Coal","Oil","Star","Inferno"].forEach((function(e){s+t.city.smelter[e]>t.city.smelter.cap&&(t.city.smelter[e]=t.city.smelter.cap-s),s+=t.city.smelter[e]})),t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium>t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno){let e=t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,a=t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium-e;t.city.smelter.Iron-=a,t.city.smelter.Iron<0&&(a=t.city.smelter.Iron,t.city.smelter.Iron=0,t.city.smelter.Iridium+=a,t.city.smelter.Iridium<0&&(a=t.city.smelter.Iridium,t.city.smelter.Iridium=0),t.city.smelter.Steel+=a,t.city.smelter.Steel<0&&(t.city.smelter.Steel=0))}else if(t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium=2);t.resource.Iridium.display&&e||t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen||t.city.smelter.Iron++}if(t.city.smelter.Star>t.city.smelter.StarCap){let e=t.city.smelter.Star-t.city.smelter.StarCap;t.city.smelter.Star=t.city.smelter.StarCap,t.city.smelter.Oil+=e}let c=t.race.forge?0:t.city.smelter.Wood*(!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species?3:1),o=t.race.forge?0:t.city.smelter.Coal*a,n=t.race.forge?0:.35*t.city.smelter.Oil;W=t.city.smelter.Iron;let l=t.city.smelter.Steel;Z=t.city.smelter.Iridium;let u=t.race.forge?t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil:t.city.smelter.Oil;Q=t.city.smelter.Star;let _=t.city.smelter.Inferno;for(t.race.steelen&&(W+=l,l=0);W+l+Z>t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno;)l>0?l--:W>0?W--:Z--;let p=t.race.soul_eater&&"wendigo"!==t.race.species?"Food":t.race.evil?"Furs":"Lumber";for(;c*f>t.resource[p].amount&&c>0;)c-=!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species?3:1,l>0?l--:W>0?W--:Z--;for(;o*f>t.resource.Coal.amount&&o>0;)o-=a,l>0?l--:W>0?W--:Z--;for(;n*f>t.resource.Oil.amount&&n>0;)n-=.35,u--,l>0?l--:W>0?W--:Z--;if(_>0){let e={Oil:35,Coal:50,Infernite:.5};Object.keys(e).forEach((function(a){for(;e[a]*_*f>t.resource[a].amount&&_>0;)_--,l>0?l--:W>0?W--:Z--})),n+=e.Oil*_,o+=e.Coal*_;let a=e.Infernite*_;r.p.consume.Infernite[F("city_smelter")]=-a,Vi("Infernite",-a*f)}W*=t.tech.smelting>=3?1.2:1,Z>0&&(Z=1+.05*Z);let h=N("dirty_jobs",2);h&&(W*=1+h/100,Z*=1+h/100),t.tech.smelting>=7&&(W*=1.25,Z*=1.25),u>0&&(W*=1+u/200,Z*=1+u/200),_>0&&(W*=1+_/125,Z*=1+_/125),Q>0&&(W*=1+Q/500,Z*=1+Q/75),t.race.pyrophobia&&(W*=1-ui.pyrophobia.vars()[0]/100,Z*=1-ui.pyrophobia.vars()[0]/100);let m=Pi("salamander");if(m>0&&(W*=1.2*m,Z*=1.2*m),Z<1&&(Z=1),t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?r.p.consume.Food[F("city_smelter")]=-c:r.p.consume.Furs[F("city_smelter")]=-c:r.p.consume.Lumber[F("city_smelter")]=-c,r.p.consume.Coal[F("city_smelter")]=-o,r.p.consume.Oil[F("city_smelter")]=-n,Vi(p,-c*f),Vi("Coal",-o*f),Vi("Oil",-n*f),o>0&&t.tech.uranium&&t.tech.uranium>=3){let e=o;t.city.geology.Uranium&&(e*=t.city.geology.Uranium+1);let a=e/65/d*Pe("psychic_boost","Uranium");r.p.Uranium[F("city_coal_ash")]=r.p.Uranium[F("city_coal_ash")]?r.p.Uranium[F("city_coal_ash")]+a:a,Vi("Uranium",e*f/65)}if(t.resource.Steel.display){let e=2*l,a=.25*l;for(;e*f>t.resource.Iron.amount&&e>0||a*f>t.resource.Coal.amount&&a>0;)e-=2,a-=.25,l--;r.p.consume.Coal[F("city_smelter")]-=a,r.p.consume.Iron[F("city_smelter")]=-e,Vi("Iron",-e*f),Vi("Coal",-a*f);let s=1;for(t.stats.achieve.steelen&&t.stats.achieve.steelen.l>=1&&(s*=1+2*t.stats.achieve.steelen.l/100),t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=2&&(s*=1.1),b=4;b<=6;b++)t.tech.smelting>=b&&(s*=1.2);t.tech.smelting>=7&&(s*=1.25),u>0&&(l*=1+u/200),_>0&&(l*=1+_/125),Q&&(l*=1+Q/500),h&&(l*=1+h/100),m>0&&(l*=1.2*m);let i=l*s*Pe("psychic_boost","Steel");t.race.pyrophobia&&(i*=1-ui.pyrophobia.vars()[0]/100);let c=i;if(c*=G*d*U.mult,r.p.Steel[F("city_smelter")]=i+"v",r.p.Steel[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%",r.p.Steel[F("hunger")]=100*(G-1)+"%",Vi("Steel",c*f),t.tech.titanium&&t.tech.titanium>=1){let e=i*G*Pe("psychic_boost","Titanium");Q>0&&(c*=1+Q/50),t.city.geology.Titanium&&(c*=t.city.geology.Titanium+1),"oceanic"===t.city.biome&&(c*=ji.oceanic.vars()[1]),c*=U.mult;let a=t.tech.titanium>=3?10:25;Vi("Titanium",c*f/a),r.p.Titanium[F("resource_Steel_name")]=e/a+"v"}}}let V=t.race.truepath?"space":"interstellar";if(t[V].g_factory&&t[V].g_factory.count>0){let e=t.race.truepath?c.g_factory:o.g_factory,a=t[V].g_factory.on,s=a>0?e/a:0,n=a;(t.race.kindling_kindred||t.race.smoldering)&&(t[V].g_factory.Lumber=0),["Oil","Coal","Lumber"].forEach((function(e){n-=t[V].g_factory[e],n<0&&(t[V].g_factory[e]+=n,n=0)}));let l=t[V].g_factory.Lumber+t[V].g_factory.Coal+t[V].g_factory.Oil;if(l>0){let e=350*t[V].g_factory.Lumber*s,a=25*t[V].g_factory.Coal*s,c=15*t[V].g_factory.Oil*s;for(;e*f>t.resource.Lumber.amount&&e>0;)e-=350*s,l--;for(;a*f>t.resource.Coal.amount&&a>0;)a-=25*s,l--;for(;c*f>t.resource.Oil.amount&&c>0;)c-=15*s,l--;l*=Pe("g_factory")*Pe("psychic_boost","Graphene"),r.p.consume.Lumber[F("interstellar_g_factory_bd")]=-e,r.p.consume.Coal[F("interstellar_g_factory_bd")]=-a,r.p.consume.Oil[F("interstellar_g_factory_bd")]=-c,Vi("Lumber",-e*f),Vi("Coal",-a*f),Vi("Oil",-c*f),"corpocracy"===t.civic.govern.type&&(l*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(l*=1+ae.socialist()[1]/100);let o=1;t.tech.ai_core>=3&&(o+=+(u/5).toFixed(1)/100*i.citadel);let n=t.race.truepath?ht("spc_titan"):1,p=l*o*_*G*d*n*s;r.p.Graphene[F("interstellar_g_factory_bd")]=l+"v",t.tech.isolation&&l>0&&(p*=S,S>1&&(r.p.Graphene[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%")),l>0&&(r.p.Graphene[`ᄂ${F("space_syndicate")}`]=-100*(1-n)+"%",r.p.Graphene[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),t.race.discharge&&t.race.discharge>0&&(p*=.5,r.p.Graphene[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),i.citadel>0&&(r.p.Graphene[F("interstellar_citadel_effect_bd")]=100*(o-1)+"%"),r.p.Graphene[F("hunger")]=100*(G-1)+"%",Vi("Graphene",p*f)}else r.p.Graphene=0}if(t.galaxy.vitreloy_plant&&i.vitreloy_plant>0){let e=5e4*i.vitreloy_plant,a=2.5*i.vitreloy_plant,s=100*i.vitreloy_plant,c=i.vitreloy_plant;for(;e*f>t.resource.Money.amount&&e>0;)e-=350,c--;for(;a*f>t.resource.Bolognium.amount&&a>0;)a-=25,c--;for(;s*f>t.resource.Stanene.amount&&s>0;)s-=15,c--;if(c>0){c*=Pe("vitreloy_plant")*Pe("psychic_boost","Vitreloy"),r.p.consume.Money[F("galaxy_vitreloy_plant_bd")]=-e,r.p.consume.Bolognium[F("galaxy_vitreloy_plant_bd")]=-a,r.p.consume.Stanene[F("galaxy_vitreloy_plant_bd")]=-s,Vi("Money",-e*f),Vi("Bolognium",-a*f),Vi("Stanene",-s*f);let i=Et("gxy_alien1");r.p.Vitreloy[F("galaxy_vitreloy_plant_bd")]=c+"v",t.race.discharge&&t.race.discharge>0&&(c*=.5,r.p.Vitreloy[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),r.p.Vitreloy[F("hunger")]=100*(G-1)+"%",c>0&&(r.p.Vitreloy[`ᄂ${F("galaxy_piracy")}+0`]=-100*(1-i)+"%",r.p.Vitreloy[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%"),Vi("Vitreloy",c*G*d*i*f*_)}}if(i.s_gate&&t.galaxy.raider&&n.raider>0){let e=.05*n.raider*Pe("psychic_boost","Vitreloy"),t=Et("gxy_chthonian"),a=e*d*t*G*_;r.p.Vitreloy[F("galaxy_raider")]=e+"v",e>0&&(r.p.Vitreloy[`ᄂ${F("galaxy_piracy")}+1`]=-100*(1-t)+"%",r.p.Vitreloy[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Vitreloy",a*f)}if(!t.tech.isolation&&t.space.lander&&t.space.crashed_ship&&100===t.space.crashed_ship.count){let e=ht("spc_triton"),a=c.lander*Pe("lander"),s=a*d*e*G;r.p.Cipher[F("space_lander_title")]=a+"v",r.p.Cipher[`ᄂ${F("space_syndicate")}+0`]=-100*(1-e)+"%",r.p.Cipher[`ᄂ${F("hunger")}`]=100*(G-1)+"%",Vi("Cipher",s*f),t.resource.Cipher.display&&t.tech.outer&&2===t.tech.outer&&(t.tech.outer=3,ms())}if(!t.tech.isolation&&t.space.digsite&&100===t.space.digsite.count){t.tech.dig_control||(t.tech.dig_control=1,ms());let e=ht("spc_eris"),a=c.shock_trooper*Pe("shock_trooper"),s=c.tank*Pe("tank");c.shock_trooper&&(r.p.Cipher[F("space_shock_trooper_title")]=a+"v",r.p.Cipher[`ᄂ${F("space_syndicate")}+1`]=-100*(1-e)+"%"),c.tank&&(r.p.Cipher[F("space_tank_title")]=s+"v",r.p.Cipher[`ᄂ${F("space_syndicate")}+2`]=-100*(1-e)+"%"),Vi("Cipher",(a+s)*d*e*f)}if(t.tech.isolation&&t.tauceti.alien_outpost&&i.alien_outpost){let e=Pe("alien_outpost"),t=1+.5*(c.colony||0);r.p.Cipher[F("tech_alien_outpost")]=e+"v",e>0&&(r.p.Cipher[`ᄂ${F("tau_home_colony")}`]=100*(t-1)+"%"),Vi("Cipher",e*d*t*f)}let J={};if(t.tauceti.ore_refinery&&t.tauceti.mining_ship&&t.tech.tau_roid&&t.tech.tau_roid>=4){if(t.tauceti.ore_refinery.max=1e3*t.tauceti.ore_refinery.count,t.tauceti.ore_refinery.fill>0){let e=i.ore_refinery*Pe("ore_refinery");e>t.tauceti.ore_refinery.fill&&(e=t.tauceti.ore_refinery.fill),t.tauceti.ore_refinery.fill-=e*f;let a=t.tech.tau_roid>=5?.6:.64,r=t.tech.tau_roid>=5?.35:.36;J.iron=e*a*(100-t.tauceti.mining_ship.common)/100*Pe("mining_ship_ore","iron")*Pe("psychic_boost","Iron"),J.aluminium=e*a*t.tauceti.mining_ship.common/100*Pe("mining_ship_ore","aluminium")*Pe("psychic_boost","Aluminium"),J.iridium=e*r*(100-t.tauceti.mining_ship.uncommon)/100*Pe("mining_ship_ore","iridium")*Pe("psychic_boost","Iridium"),J.neutronium=e*r*t.tauceti.mining_ship.uncommon/100*Pe("mining_ship_ore","neutronium")*Pe("psychic_boost","Neutronium"),t.tech.tau_roid>=5&&(J.orichalcum=.05*e*(100-t.tauceti.mining_ship.rare)/10*Pe("mining_ship_ore","orichalcum")*Pe("psychic_boost","Orichalcum"),J.elerium=.05*e*t.tauceti.mining_ship.rare/10*Pe("mining_ship_ore","elerium")*Pe("psychic_boost","Elerium"))}let e=c.mining_ship*Pe("mining_ship");t.tauceti.ore_refinery.fill+=e*f,t.tauceti.ore_refinery.fill>t.tauceti.ore_refinery.max&&(t.tauceti.ore_refinery.fill=t.tauceti.ore_refinery.max)}if(t.race.cataclysm||t.race.orbit_decayed){if(t.tech.mars&&c.biodome&&!t.race.kindling_kindred&&!t.race.smoldering){let e=c.biodome*na(t.civic.colonist.workers,"colonist")*Pe("biodome","lumber")*Pe("psychic_boost","Lumber");r.p.Lumber[Qr.space.spc_red.biodome.title()]=e+"v",e>0&&(r.p.Lumber[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),r.p.Lumber[F("hunger")]=100*(G-1)+"%",Vi("Lumber",e*G*d*f*_)}}else if(t.race.soul_eater&&"wendigo"!==t.race.species&&t.race.evil){let e=t.tech.military?t.tech.military>=5?t.tech.military-1:t.tech.military:1,a=na(t.civic.hunter.workers,"hunter");a*=pi(a,"hunting"),t.race.servants&&(a+=la(t.race.servants.jobs.hunter)),a*=e/2,t.race.high_pop&&(a=Me(a)),a*=Pe("psychic_boost","Lumber");let s=ke(qe(),"hunting")/3;s*=Pe("psychic_boost","Lumber"),r.p.Lumber[F(t.race.unfathomable?"job_raider":"job_hunter")]=a+"v",r.p.Lumber[F("soldiers")]=s+"v",r.p.Lumber[F("hunger")]=100*(G-1)+"%",Vi("Lumber",a*G*d*f),Vi("Lumber",s*G*d*f)}else if(t.race.evil){let e=na(t.civic.lumberjack.workers,"lumberjack");e*=pi(e,"lumberjack"),t.race.servants&&(e+=t.race.servants.jobs.lumberjack),e*=Pe("psychic_boost","Lumber");let a=1;t.city.graveyard&&(a+=.08*t.city.graveyard.count);let s=ke(qe(),"hunting")/5;if(s*=Pe("psychic_boost","Lumber"),r.p.Lumber[F("job_reclaimer")]=e+"v",e>0&&(r.p.Lumber[`ᄂ${F("city_graveyard")}`]=100*(a-1)+"%",r.p.Lumber[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),r.p.Lumber[F("soldiers")]=s+"v",s>0&&(r.p.Lumber[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),t.race.forager){let e=1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.25;r.p.Lumber[F("job_forager")]=s+"v",s>0&&(r.p.Lumber[`ᄂ${F("quarantine")}+2`]=100*(h-1)+"%"),Vi("Lumber",s*G*d*h*f)}r.p.Lumber[F("hunger")]=100*(G-1)+"%",Vi("Lumber",e*G*a*d*h*f),Vi("Lumber",s*G*d*h*f)}else{let e=na(t.civic.lumberjack.workers,"lumberjack");e*=pi(e,"lumberjack"),t.race.servants&&(e+=t.race.servants.jobs.lumberjack),e*="forest"===t.city.biome?ji.forest.vars()[0]:1,e*="savanna"===t.city.biome?ji.savanna.vars()[2]:1,e*="desert"===t.city.biome?ji.desert.vars()[2]:1,e*="swamp"===t.city.biome?ji.swamp.vars()[2]:1,e*="taiga"===t.city.biome?ji.taiga.vars()[0]:1,e*=t.civic.lumberjack.impact,t.race.living_tool?e*=ui.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.25*t.tech.science:0)+1:e*=1+(t.tech.axe&&t.tech.axe>1?.35*(t.tech.axe-1):0),e*=Pe("psychic_boost","Lumber");let a=1;if(t.city.sawmill){let e=t.tech.saw>=2?.08:.05;a*=t.city.sawmill.count*e+1}let s=1,c=1;t.city.powered&&t.city.sawmill&&i.sawmill&&(s+=.04*i.sawmill,c+=.04);let o=1;t.city.lumber_yard&&(o+=.02*t.city.lumber_yard.count),r.p.Lumber[F("job_lumberjack")]=e+"v",e>0&&(r.p.Lumber[`ᄂ${F("city_lumber_yard")}`]=100*(o-1)+"%",r.p.Lumber[`ᄂ${F("city_sawmill")}`]=100*(a-1)+"%",r.p.Lumber[`ᄂ${F("power")}`]=100*(s-1)+"%",r.p.Lumber[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),t.race.discharge&&t.race.discharge>0&&i.sawmill>0&&(s=.5*(s-1)+1,c=.5*(c-1)+1,r.p.Lumber[`ᄂ${F("evo_challenge_discharge")}`]="-50%");let n=e*a*o;if(t.city.sawmill&&(t.city.sawmill.psaw=+(n*G*h*d*(c-1)).toFixed(5)),n*=s*G*h*d,t.race.forager){let e=1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.25*Pe("psychic_boost","Lumber");r.p.Lumber[F("job_forager")]=s+"v",Vi("Lumber",s*G*d*f)}r.p.Lumber[F("hunger")]=100*(G-1)+"%",Vi("Lumber",n*f)}let Y=t.city.metal_refinery?6*t.city.metal_refinery.count:0;if(Y*=h,t.race.sappy){if(t.tech.mining&&t.resource[t.race.species].amount>0){let e=t.resource[t.race.species].amount*ui.sappy.vars()[0]*Pe("psychic_boost","Stone");t.race.high_pop&&(e=Me(e));let a=Pi("cacti");if(a>0&&(e*=1+.32*a),r.p.Stone[Ac("name")]=e+"v",t.city.hasOwnProperty("basic_housing")){let a=.025*t.city.basic_housing.count;e*=1+a,r.p.Stone[`ᄂ${Is("small")}`]=100*a+"%"}let s=0;t.civic.hasOwnProperty("garrison")&&(s=t.civic.garrison.workers*ui.sappy.vars()[0],t.race.high_pop&&(s=Me(s)),r.p.Stone[F("soldiers")]=s+"v");let i=(e+s)*G*d;r.p.Stone[F("hunger")]=100*(G-1)+"%",Vi("Stone",i*f)}}else{let e=na(t.civic.quarry_worker.workers,"quarry_worker");e*=pi(e,"miner");let a=Pi("cacti");a>0&&(e*=1+.32*a),t.race.servants&&(e+=t.race.servants.jobs.quarry_worker),e*=t.civic.quarry_worker.impact*Pe("psychic_boost","Stone"),t.race.living_tool?e*=ui.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.06*t.tech.science:0)+1:e*=1+(t.tech.hammer&&t.tech.hammer>0?.4*t.tech.hammer:0),"desert"===t.city.biome&&(e*=ji.desert.vars()[0]),"swamp"===t.city.biome&&(e*=ji.swamp.vars()[3]),t.tech.explosives&&t.tech.explosives>=2&&(e*=t.tech.explosives>=3?1.75:1.5);let s=0;t.race.smoldering&&t.resource.Chrysotile.display&&t.city.rock_quarry&&(s=e*Pe("psychic_boost","Chrysotile"),e*=(100-t.city.rock_quarry.asbestos)/100,s*=t.city.rock_quarry.asbestos/100);let o=1,n=1,l=1;t.city.rock_quarry&&(t.city.rock_quarry.on&&(o+=.04*i.rock_quarry,n+=.04),l+=.02*t.city.rock_quarry.count),r.p.Stone[F("workers")]=e+"v",e>0&&(r.p.Stone[`ᄂ${F("city_rock_quarry")}`]=100*(l-1)+"%",r.p.Stone[`ᄂ${F("power")}`]=100*(o-1)+"%",r.p.Stone[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),t.race.smoldering&&t.resource.Chrysotile.display&&(r.p.Chrysotile[F("workers")]=s+"v",s>0&&(r.p.Chrysotile[`ᄂ${F("city_rock_quarry")}`]=100*(l-1)+"%",r.p.Chrysotile[`ᄂ${F("power")}`]=100*(o-1)+"%")),t.race.discharge&&t.race.discharge>0&&i.rock_quarry>0&&(o=.5*(o-1)+1,n=.5*(n-1)+1,r.p.Stone[`ᄂ${F("evo_challenge_discharge")}`]="-50%",t.race.smoldering&&t.resource.Chrysotile.display&&(r.p.Chrysotile[`ᄂ${F("evo_challenge_discharge")}`]="-50%")),(t.race.cataclysm||t.race.orbit_decayed)&&(t.tech.mars&&c.red_mine&&(e=c.red_mine*na(t.civic.colonist.workers,"colonist")*Pe("red_mine","stone")*Pe("psychic_boost","Stone"),r.p.Stone[F("space_red_mine_title")]=e+"v",e>0&&(r.p.Stone[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),t.race.smoldering&&t.resource.Chrysotile.display&&(s=c.red_mine*na(t.civic.colonist.workers,"colonist")*Pe("red_mine","asbestos")*Pe("psychic_boost","Chrysotile"),r.p.Chrysotile[F("space_red_mine_title")]=s+"v",s>0&&(r.p.Chrysotile[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),s*=_),e*=_),o=1,n=1,l=1);let u=e*l;if(t.city.rock_quarry&&(t.city.rock_quarry.cnvay=+(u*G*h*d*(n-1)).toFixed(5)),u*=o*G*h*d,t.race.forager&&t.resource.Stone.display){let e=1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.22*Pe("psychic_boost","Stone");r.p.Stone[F("job_forager")]=s+"v",s>0&&(r.p.Stone[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),Vi("Stone",s*G*d*h*f)}if(r.p.Stone[F("hunger")]=100*(G-1)+"%",Vi("Stone",u*f),t.race.smoldering&&t.resource.Chrysotile.display){let e=s*o*l;e*=G*d,r.p.Chrysotile[F("hunger")]=100*(G-1)+"%",Vi("Chrysotile",e*f)}if(t.city.metal_refinery&&t.city.metal_refinery.count>0||t.race.cataclysm||t.race.orbit_decayed){let a=e*l*(t.race.cataclysm?.16:.08);t.city.geology.Aluminium&&(a*=t.city.geology.Aluminium+1),a*=Pe("psychic_boost","Aluminium");let s=a*U.mult*G*h*d;if(t.city.metal_refinery.cnvay=+(s*(n-1)).toFixed(5),t.city.rock_quarry.almcvy=t.city.metal_refinery.cnvay,s*=o,t.tech.alumina>=2){Y+=6*i.metal_refinery*h;let e=6*h/100;t.city.metal_refinery.pwr=+(s*e).toFixed(5)}s*=1+Y/100,r.p.Aluminium[`${t.race.cataclysm||t.race.orbit_decayed?F("space_red_mine_title"):F("workers")}+1`]=a+"v",a>0&&(r.p.Aluminium[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),r.p.Aluminium[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%",r.p.Aluminium[F("hunger")]=100*(G-1)+"%",Vi("Aluminium",s*f)}}if(t.resource.Water.display){if(c.water_freighter){let e=ht("spc_enceladus"),t=Pe("water_freighter")*c.water_freighter*Pe("psychic_boost","Water"),a=t*G*d*e*_;r.p.Water[F("space_water_freighter_title")]=t+"v",t>0&&(r.p.Water[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Water[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Water[`ᄂ${F("hunger")}`]=100*(G-1)+"%"),Vi("Water",a*f)}if(t.tech.isolation&&t.tauceti.tau_farm&&i.tau_farm){let e=1+.5*(c.colony||0),t=Pe("tau_farm","water")*i.tau_farm*Pe("psychic_boost","Water"),a=t*d*e;r.p.Water[F("tau_home_tau_farm")]=t+"v",t>0&&(r.p.Water[`ᄂ${F("tau_home_colony")}`]=100*(e-1)+"%"),Vi("Water",a*f)}}if(t.resource.Mana.display){if(t.race.casting&&["farmer","miner","lumberjack","science","factory","army","hunting","crafting"].forEach((function(e){if(t.race.casting[e]&&t.race.casting[e]>0){let a=Ys(t.race.casting[e]);r.p.consume.Mana[F(`modal_pylon_spell_${e}`)]=-a;let s=t.resource.Mana.diff>0?t.resource.Mana.diff*f:0;Vi("Mana",-a*f,!1,s)||t.race.casting[e]--}else delete r.p.consume.Mana[F(`modal_pylon_spell_${e}`)]})),t.city.pylon||t.space.pylon||t.tauceti.pylon){let e=0,a="city_pylon";(t.race.cataclysm||t.race.orbit_decayed)&&t.space.pylon?(e=.005*t.space.pylon.count,a="space_red_pylon"):t.tech.isolation&&t.tauceti.pylon?(e=.0125*t.tauceti.pylon.count,a="tau_home_pylon"):t.city.pylon&&(e=.01*t.city.pylon.count),e*=nc("magic");let s=e*G*d;if(r.p.Mana[F(a)]=e+"v",t.tech.nexus){let e=5*t.tech.nexus;s*=1+e/100,r.p.Mana[`ᄂ${F("arpa_projects_nexus_title")}`]=e+"%"}Vi("Mana",s*f)}if(t.tech.cleric&&t.civic.priest.display){let e=.0025*na(t.civic.priest.workers,"priest");t.race.high_pop&&(e=Me(e)),e*=nc("magic");let a=e*G*d;r.p.Mana[F("job_priest")]=e+"v",Vi("Mana",a*f)}if("magic"===t.race.universe&&t.civic.scientist.display){let e=.025*na(t.civic.scientist.workers,"scientist");t.race.high_pop&&(e=Me(e)),e*=nc("magic");let a=e*G*d;r.p.Mana[F("job_wizard")]=e+"v","magocracy"===t.civic.govern.type&&(a*=1+ae.magocracy()[0]/100,r.p.Mana[`ᄂ${F("govern_magocracy")}`]=ae.magocracy()[0]+"%"),Vi("Mana",a*f)}if("magic"===t.race.universe&&t.tech.syphon){let e=t.tech.syphon/3;e*=nc("magic");let a=e*G*d;r.p.Mana[F("arpa_syphon_title")]=e+"v",Vi("Mana",a*f)}r.p.Mana[F("hunger")]=100*(G-1)+"%"}if(t.resource.Crystal.display){let e=na(t.civic.crystal_miner.workers,"crystal_miner");if(e*=pi(e,"miner"),t.race.servants&&(e+=t.race.servants.jobs.crystal_miner),e*=t.civic.crystal_miner.impact*Pe("psychic_boost","Crystal"),r.p.Crystal[F("job_crystal_miner")]=e+"v","magocracy"===t.civic.govern.type){let t=ae.magocracy()[1];e*=1+t/100,r.p.Crystal[`ᄂ${F("govern_magocracy")}`]=`${t}%`}let a=e*G*d;r.p.Crystal[F("hunger")]=100*(G-1)+"%",Vi("Crystal",a*f)}if(t.resource.Copper.display||t.resource.Iron.display){let e=na(t.civic.miner.workers,"miner");e*=pi(e,"miner"),e*=t.civic.miner.impact,t.race.tough&&(e*=1+ui.tough.vars()[0]/100);let a=Pi("ogre");a>0&&(e*=1+ui.tough.vars(1)[0]/100*a),t.race.industrious&&(e*=1+ui.industrious.vars()[0]*t.race.industrious/100),t.city.ptrait.includes("dense")&&(e*=Si.dense.vars()[0]),t.city.ptrait.includes("permafrost")&&(e*=Si.permafrost.vars()[0]),t.race.living_tool||(e*=1+(t.tech.pickaxe&&t.tech.pickaxe>0?.15*t.tech.pickaxe:0)),t.tech.explosives&&t.tech.explosives>=2&&(e*=t.tech.explosives>=3?1.4:1.25);let s=1,o=1;if(t.city.mine.on&&(s+=.05*i.mine,o+=1.05),t.resource.Copper.display){let a=1/7;t.tech.copper&&(a*=1.2);let c=e*a*Pe("psychic_boost","Copper");t.city.geology.Copper&&(c*=t.city.geology.Copper+1),"volcanic"===t.city.biome?c*=ji.volcanic.vars()[1]:"ashland"===t.city.biome&&(c*=ji.ashland.vars()[2]);let n=s,l=o;r.p.Copper[F("job_miner")]=c+"v",c>0&&(r.p.Copper[`ᄂ${F("power")}`]=100*(n-1)+"%",r.p.Copper[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%",t.race.discharge&&t.race.discharge>0&&i.mine>0&&(n=.5*(n-1)+1,l=.5*(l-1)+1,r.p.Copper[`ᄂ${F("evo_challenge_discharge")}`]="-50%"));let u=c*U.mult;if(t.city.mine.cpow=+(u*G*h*d*(l-1)).toFixed(5),u*=n*G*h*d,Vi("Copper",u*f),t.race.forager&&t.tech.dowsing){let e=t.tech.dowsing>=2?5:1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.025*Pe("psychic_boost","Copper");t.city.geology.Copper&&(s*=t.city.geology.Copper+1),"volcanic"===t.city.biome?s*=ji.volcanic.vars()[1]:"ashland"===t.city.biome&&(s*=ji.ashland.vars()[2]),r.p.Copper[F("job_forager")]=s+"v",s>0&&(r.p.Copper[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),Vi("Copper",s*G*d*h*f)}}if(t.resource.Iron.display){let a=e*(1/4)*Pe("psychic_boost","Iron");t.race.iron_allergy&&(a*=1-ui.iron_allergy.vars()[0]/100);let o=1+.1*W;t.city.geology.Iron&&(a*=t.city.geology.Iron+1),"volcanic"===t.city.biome?a*=ji.volcanic.vars()[2]:"ashland"===t.city.biome&&(a*=ji.ashland.vars()[2]);let n=0,l=ht("spc_belt");c.iron_ship&&(n=c.iron_ship*Pe("iron_ship")*Pe("psychic_boost","Iron"),n*=l);let u=s,p=s;r.p.Iron[F("job_miner")]=a+"v",a>0&&(r.p.Iron[`ᄂ${F("power")}`]=100*(u-1)+"%",t.race.discharge&&t.race.discharge>0&&i.mine>0&&(u=.5*(u-1)+1,p=.5*(p-1)+1,r.p.Iron[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),r.p.Iron[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%");let g=0,v=0;if(t.tech.isolation&&t.race.lone_survivor){{let e=na(t.civic.pit_miner.workers,"pit_miner");e*=pi(e,"miner");let a=1+.5*(c.colony||0),s=e*Pe("psychic_boost","Iron");s*=Pe("mining_pit","iron"),g=s*a,r.p.Iron[F("job_pit_miner")]=s+"v",s>0&&(r.p.Iron[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%")}if(t.tauceti.hasOwnProperty("womling_mine")&&t.tauceti.hasOwnProperty("overseer")){let e=t.tauceti.overseer.prod/100,a=t.tauceti.womling_mine.miners*Pe("womling_mine","iron")*Pe("psychic_boost","Iron");r.p.Iron[F("tau_red_womlings")]=a+"v",v=a*e,a>0&&(r.p.Iron[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-e)+"%")}}let y=J.iron?J.iron*S:0,b=(a*u*h+n*m*_+y+g+v)*o*U.mult;if(t.city.mine.ipow=+(a*h*G*d*(p-1)).toFixed(5),b*=G*d,r.p.Iron[F("job_space_miner")]=n+"v",n>0&&(r.p.Iron[`ᄂ${F("space_syndicate")}`]=-100*(1-l)+"%",r.p.Iron[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Iron[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),J.iron&&J.iron>0&&(r.p.Iron[F("tau_roid_mining_ship")]=J.iron+"v",S>1&&(r.p.Iron[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%")),r.p.Iron[F("city_smelter")]=100*(o-1)+"%",r.p.Iron[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%",t.race.forager&&t.tech.dowsing){let e=t.tech.dowsing>=2?5:1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.035*Pe("psychic_boost","Iron");t.city.geology.Iron&&(s*=t.city.geology.Iron+1),"volcanic"===t.city.biome?s*=ji.volcanic.vars()[2]:"ashland"===t.city.biome&&(s*=ji.ashland.vars()[2]),r.p.Iron[F("job_forager")]=s+"v",Vi("Iron",s*G*d*f)}if(r.p.Iron[F("hunger")]=100*(G-1)+"%",Vi("Iron",b*f),t.tech.titanium&&t.tech.titanium>=2){let e=(c.iron_ship?Me(na(t.civic.miner.workers,"miner"))/4+c.iron_ship/2:na(t.civic.miner.workers,"miner")/4)*W*.1;b=e*d,Q>0&&(b*=1+Q/50),t.city.geology.Titanium&&(b*=t.city.geology.Titanium+1),"oceanic"===t.city.biome&&(b*=ji.oceanic.vars()[0]),b*=U.mult*Pe("psychic_boost","Titanium");let a=t.tech.titanium>=3?10:25;Vi("Titanium",b*f/a),r.p.Titanium[F("resource_Iron_name")]=e/a+"v"}}if(t.race.sappy){if(t.city.metal_refinery&&t.city.metal_refinery.count>0||t.race.cataclysm||t.race.orbit_decayed){let a=0;t.race.cataclysm||t.race.orbit_decayed?t.tech.mars&&c.red_mine&&(a=c.red_mine*na(t.civic.colonist.workers,"colonist")*Pe("red_mine","aluminium")):a=e*s*.088,t.city.geology.Aluminium&&(a*=t.city.geology.Aluminium+1),a*=Pe("psychic_boost","Aluminium");let o=a*U.mult*G*d;t.tech.alumina>=2&&(Y+=6*i.metal_refinery),o*=1+Y/100,r.p.Aluminium[`${t.race.cataclysm||t.race.orbit_decayed?F("space_red_mine_title"):F("job_miner")}+2`]=a+"v",(t.race.cataclysm||t.race.orbit_decayed&&a>0&&_>0)&&(o*=_,r.p.Aluminium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),r.p.Aluminium[F("city_shrine")]=100*(U.mult-1)+"%",r.p.Aluminium[F("hunger")]=100*(G-1)+"%",Vi("Aluminium",o*f)}if(t.race.smoldering&&t.resource.Chrysotile.display){let a=e/2*Pe("psychic_boost","Chrysotile"),c=s;r.p.Chrysotile[F("job_miner")]=a+"v",a>0&&(r.p.Chrysotile[`ᄂ${F("power")}`]=100*(c-1)+"%",t.race.discharge&&t.race.discharge>0&&i.mine>0&&(c=.5*(c-1)+1,r.p.Chrysotile[`ᄂ${F("evo_challenge_discharge")}`]="-50%"));let o=a*c;o*=G*d,r.p.Chrysotile[F("hunger")]=100*(G-1)+"%",Vi("Chrysotile",o*f)}}}if(t.interstellar.mining_droid&&z.alum>0){let e=2.75*z.alum*Pe("psychic_boost","Aluminium"),t=e*U.mult*d*_;t*=1+Y/100,r.p.Aluminium[F("interstellar_mining_droid_title")]=e+"v",e>0&&(r.p.Aluminium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Aluminium",t*f)}if(t.resource.Aluminium.display&&t.space.titan_mine){let e=ht("spc_titan"),a=i.ai_colonist?na(t.civic.titan_colonist.workers,"titan_colonist")+la(i.ai_colonist):na(t.civic.titan_colonist.workers,"titan_colonist"),s=Pe("titan_mine","aluminium")*c.titan_mine*a*Pe("psychic_boost","Aluminium"),o=s*U.mult*d*m*e*_;o*=1+Y/100,r.p.Aluminium[`${F("city_mine")}+0`]=+s.toFixed(3)+"v",s>0&&(r.p.Aluminium[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Aluminium[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%",r.p.Aluminium[`ᄂ${F("quarantine")}+2`]=100*(m-1)+"%"),Vi("Aluminium",o*f)}if(t.resource.Aluminium.display&&J.aluminium&&J.aluminium>0){let e=J.aluminium*U.mult*d*S;e*=1+Y/100,r.p.Aluminium[F("tau_roid_mining_ship")]=J.aluminium+"v",S>1&&(r.p.Aluminium[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Aluminium",e*f)}if(Y>0&&(r.p.Aluminium[F("city_metal_refinery")]=Y+"%",r.p.Aluminium[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),c.red_mine&&c.red_mine>0){let e=ht("spc_red"),a=c.red_mine*na(t.civic.colonist.workers,"colonist")*Pe("red_mine","copper").f;a*=Pe("psychic_boost","Copper"),r.p.Copper[F("space_red_mine_desc_bd",[Xt().red])]=a+"v",a>0&&(r.p.Copper[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Copper[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Copper[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Copper",a*U.mult*f*d*m*G*e*_);let s=c.red_mine*na(t.civic.colonist.workers,"colonist")*G*Pe("red_mine","titanium").f;s*=Pe("psychic_boost","Titanium"),r.p.Titanium[F("space_red_mine_desc_bd",[Xt().red])]=s+"v",s>0&&(r.p.Titanium[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Titanium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Titanium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Titanium",s*U.mult*f*d*m*e*_)}if(Kc()&&(r.p.Copper[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%",r.p.Titanium[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%"),r.p.Copper[F("hunger")]=100*(G-1)+"%",r.p.Uranium.hasOwnProperty(F("city_coal_ash"))&&(r.p.Uranium[F("city_coal_ash")]=r.p.Uranium[F("city_coal_ash")]+"v"),t.resource.Coal.display){let e=na(t.civic.coal_miner.workers,"coal_miner");e*=pi(e,"miner"),t.race.tough&&(e*=1+ui.tough.vars()[0]/100);let a=Pi("ogre");a>0&&(e*=1+ui.tough.vars(1)[0]/100*a),t.race.resilient&&(e*=1+ui.resilient.vars()[0]*t.race.resilient/100),t.tech.explosives&&t.tech.explosives>=2&&(e*=t.tech.explosives>=3?1.4:1.25),t.city.geology.Coal&&(e*=t.city.geology.Coal+1);let s=1,o=1;t.city.coal_mine.on&&(s+=.05*i.coal_mine,o+=.05),e*=t.civic.coal_miner.impact*Pe("psychic_boost","Coal"),r.p.Coal[F("job_coal_miner")]=e+"v",e>0&&(r.p.Coal[`ᄂ${F("power")}`]=100*(s-1)+"%",r.p.Coal[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),t.race.discharge&&t.race.discharge>0&&i.coal_mine>0&&(s=.5*(s-1)+1,o=.5*(o-1)+1,r.p.Coal[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.race.cataclysm&&c.iridium_mine&&(e=c.iridium_mine*Pe("iridium_mine","coal"),e*=t.civic.coal_miner.impact*Pe("psychic_boost","Coal"),r.p.Coal[F("space_moon_iridium_mine_title")]=e+"v",e>0&&(r.p.Coal[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Coal[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),s=1*_);let n=e;if(t.city.coal_mine.cpow=+(n*G*h*d*(o-1)).toFixed(5),n*=s*G*h*d,r.p.Coal[F("hunger")]=100*(G-1)+"%",t.interstellar.mining_droid&&z.coal>0){let e=3.75*z.coal*Pe("psychic_boost","Coal"),t=e*d*_;r.p.Coal[F("interstellar_mining_droid_title")]=e+"v",e>0&&(r.p.Coal[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Coal",t*f)}if(Vi("Coal",n*f),t.resource.Uranium.display){let e=n/(t.race.cataclysm?48:115)*Pe("psychic_boost","Uranium");t.city.coal_mine.upow=+(t.city.coal_mine.cpow/(t.race.cataclysm?48:115)).toFixed(5),t.city.geology.Uranium&&(e*=t.city.geology.Uranium+1),Vi("Uranium",e*f),r.p.Uranium[t.race.cataclysm?F("space_moon_iridium_mine_title"):F("job_coal_miner")]=e/d+"v"}}if(t.interstellar.mining_droid&&z.uran>0){let e=.12*z.uran*Pe("psychic_boost","Uranium"),t=e*d*_;r.p.Uranium[F("interstellar_mining_droid_title")]=e+"v",e>0&&(r.p.Uranium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),Vi("Uranium",t*f)}if(t.space.uranium_mine&&i.uranium_mine){let e=ht("spc_kuiper"),a=i.uranium_mine*Pe("uranium_mine")*Pe("psychic_boost","Uranium"),s=a*d*m*e*_;r.p.Uranium[F("space_kuiper_mine",[t.resource.Uranium.name])]=a+"v",a>0&&(r.p.Uranium[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Uranium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",r.p.Uranium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Uranium",s*f)}if(t.resource.Oil.display){let e=0;if(t.tauceti.whaling_station&&t.tauceti.whaling_ship){if(t.tauceti.whaling_station.max=750*t.tauceti.whaling_station.count,t.tauceti.whaling_station.fill>0){let a=i.whaling_station*Pe("whaling_station");a>t.tauceti.whaling_station.fill&&(a=t.tauceti.whaling_station.fill),t.tauceti.whaling_station.fill-=a*f,e=a*Pe("whaling_ship_oil")*Pe("psychic_boost","Oil")}let a=c.whaling_ship*Pe("whaling_ship");t.tauceti.whaling_station.fill+=a*f,t.tauceti.whaling_station.fill>t.tauceti.whaling_station.max&&(t.tauceti.whaling_station.fill=t.tauceti.whaling_station.max)}let a=t.space.oil_extractor?i.oil_extractor*Pe("oil_extractor"):0,s=t.city.oil_well?Pe("oil_well")*t.city.oil_well.count:0;a*=Pe("psychic_boost","Oil"),s*=Pe("psychic_boost","Oil");let o=ht("spc_gas_moon"),n=s*h+a*m*o*_+e*S;n*=G*d,t.space.oil_extractor&&(t.space.oil_extractor.lpmod=Pe("oil_extractor")*m*o*_),r.p.Oil[F("city_oil_well")]=s+"v",s>0&&(r.p.Oil[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),r.p.Oil[F("space_gas_moon_oil_extractor_title")]=a+"v",a>0&&(r.p.Oil[`ᄂ${F("space_syndicate")}`]=-100*(1-o)+"%",r.p.Oil[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Oil[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),r.p.Oil[F("tau_roid_whaling_ship")]=e+"v",S>1&&(r.p.Oil[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),r.p.Oil[F("hunger")]=100*(G-1)+"%",Vi("Oil",n*f)}if(c.iridium_mine){let e=c.iridium_mine*Pe("iridium_mine","iridium").f;e*=Pe("psychic_boost","Iridium");let t=ht("spc_moon"),a=e*G*U.mult*d*t*m*Z*_;r.p.Iridium[F("space_moon_iridium_mine_title")]=e+"v",e>0&&(r.p.Iridium[`ᄂ${F("city_smelter")}+0`]=100*(Z-1)+"%",r.p.Iridium[`ᄂ${F("space_syndicate")}+0`]=-100*(1-t)+"%",r.p.Iridium[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%",r.p.Iridium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Iridium",a*f)}if(c.iridium_ship){let e=c.iridium_ship*Pe("iridium_ship");e*=Pe("psychic_boost","Iridium");let t=ht("spc_belt"),a=e*G*U.mult*d*t*m*Z*_;r.p.Iridium[F("job_space_miner")]=e+"v",e>0&&(r.p.Iridium[`ᄂ${F("city_smelter")}+1`]=100*(Z-1)+"%",r.p.Iridium[`ᄂ${F("space_syndicate")}+1`]=-100*(1-t)+"%",r.p.Iridium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",r.p.Iridium[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Iridium",a*f)}if(i.s_gate&&t.resource.Adamantite.display&&t.galaxy.armed_miner&&n.armed_miner>0){let e=.65*n.armed_miner*Pe("psychic_boost","Iridium"),t=1+.1*n.ore_processor,a=Et("gxy_alien2"),s=e*d*a*t*G*U.mult*Z*_;r.p.Iridium[F("galaxy_armed_miner_bd")]=e+"v",e>0&&(r.p.Iridium[`ᄂ${F("galaxy_ore_processor")}`]=-100*(1-t)+"%",r.p.Iridium[`ᄂ${F("city_smelter")}+2`]=100*(Z-1)+"%",r.p.Iridium[`ᄂ${F("galaxy_piracy")}`]=-100*(1-a)+"%",r.p.Iridium[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%"),Vi("Iridium",s*f)}if(t.resource.Iridium.display&&J.iridium&&J.iridium>0){let e=J.iridium*U.mult*d*Z*G*S;r.p.Iridium[F("tau_roid_mining_ship")]=J.iridium+"v",r.p.Iridium[`ᄂ${F("city_smelter")}+3`]=100*(Z-1)+"%",S>1&&(r.p.Iridium[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Iridium",e*f)}if(t.space.moon_base&&c.helium_mine){let e=c.helium_mine*Pe("helium_mine").f;e*=Pe("psychic_boost","Helium_3");let t=ht("spc_moon"),a=e*G*d*t*m*_;r.p.Helium_3[F("space_moon_helium_mine_title")]=e+"v",e>0&&(r.p.Helium_3[`ᄂ${F("space_syndicate")}+0`]=-100*(1-t)+"%",r.p.Helium_3[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Helium_3[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Helium_3",a*f)}if(t.space.gas_mining&&i.gas_mining){let e=i.gas_mining*Pe("gas_mining");e*=Pe("psychic_boost","Helium_3");let t=ht("spc_gas"),a=e*G*d*t*m*_;r.p.Helium_3[F("space_gas_mining_title")]=e+"v",e>0&&(r.p.Helium_3[`ᄂ${F("space_syndicate")}+1`]=-100*(1-t)+"%",r.p.Helium_3[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",r.p.Helium_3[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Helium_3",a*f)}if(i.refueling_station){let e=i.refueling_station*Pe("refueling_station");e*=Pe("psychic_boost","Helium_3");let t=e*G*d*S;r.p.Helium_3[F("tau_gas_refueling_station_title")]=e+"v",S>1&&(r.p.Helium_3[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Helium_3",t*f)}if(t.interstellar.harvester&&o.harvester){let e=o.harvester*Pe("harvester","helium");e*=Pe("psychic_boost","Helium_3");let a=e*G*d*_;if(r.p.Helium_3[F("interstellar_harvester_title")]=e+"v",e>0&&(r.p.Helium_3[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(a*=.5,r.p.Helium_3[`ᄂ${F("evo_challenge_discharge")}`]="-50%")),Vi("Helium_3",a*f),t.tech.ram_scoop){let e=o.harvester*Pe("harvester","deuterium");e*=Pe("psychic_boost","Deuterium");let t=e*G*d*_;r.p.Deuterium[F("interstellar_harvester_title")]=e+"v",e>0&&(r.p.Deuterium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),Vi("Deuterium",t*f),r.p.Deuterium[F("hunger")]=100*(G-1)+"%"}}if(i.s_gate&&t.galaxy.raider&&n.raider>0){let e=.65*n.raider*Pe("psychic_boost","Deuterium"),t=Et("gxy_chthonian"),a=e*d*t*G*_;r.p.Deuterium[F("galaxy_raider")]=e+"v",e>0&&(r.p.Deuterium[`ᄂ${F("galaxy_piracy")}`]=-100*(1-t)+"%",r.p.Deuterium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Deuterium",a*f)}if(r.p.Helium_3[F("hunger")]=100*(G-1)+"%",i.outpost){let e=Pe("outpost",!0),a=Pe("psychic_boost","Neutronium");r.p.Neutronium[F("space_gas_moon_outpost_bd")]=e.b*a*i.outpost+"v",t.tech.drone&&(r.p.Neutronium[`ᄂ${F("tech_worker_drone")}`]=100*e.d+"%");let s=ht("spc_gas_moon"),c=i.outpost*e.n*a*G*d*m*s*_;t.space.outpost.lpmod=e.n*a*G*d*m*s*_,e.b>0&&(r.p.Neutronium[`ᄂ${F("space_syndicate")}+0`]=-100*(1-s)+"%",r.p.Neutronium[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%",r.p.Neutronium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%",t.race.discharge&&t.race.discharge>0&&(c*=.5,t.space.outpost.lpmod*=.5,r.p.Neutronium[`ᄂ${F("evo_challenge_discharge")}+0`]="-50%")),Vi("Neutronium",c*f)}if(i.neutron_miner){let e=i.neutron_miner*Pe("neutron_miner")*Pe("psychic_boost","Neutronium"),a=e*G*d*_;r.p.Neutronium[F("interstellar_neutron_miner_bd")]=e+"v",t.interstellar.neutron_miner.lpmod=Pe("neutron_miner")*G*d*_,e>0&&(r.p.Neutronium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(a*=.5,t.interstellar.neutron_miner.lpmod*=.5,r.p.Neutronium[`ᄂ${F("evo_challenge_discharge")}+1`]="-50%")),Vi("Neutronium",a*f)}if(i.s_gate&&t.galaxy.raider&&n.raider>0){let e=.8*n.raider*Pe("psychic_boost","Neutronium"),t=Et("gxy_chthonian"),a=e*d*t*G*_;r.p.Neutronium[F("galaxy_raider")]=e+"v",e>0&&(r.p.Neutronium[`ᄂ${F("galaxy_piracy")}`]=-100*(1-t)+"%",r.p.Neutronium[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%"),Vi("Neutronium",a*f)}if(t.space.neutronium_mine&&i.neutronium_mine){let e=ht("spc_kuiper"),a=i.neutronium_mine*Pe("neutronium_mine")*Pe("psychic_boost","Neutronium"),s=a*d*m*e*_;r.p.Neutronium[F("space_kuiper_mine",[t.resource.Neutronium.name])]=a+"v",a>0&&(r.p.Neutronium[`ᄂ${F("space_syndicate")}+1`]=-100*(1-e)+"%",r.p.Neutronium[`ᄂ${F("space_red_ziggurat_title")}+3`]=100*(_-1)+"%",r.p.Neutronium[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Neutronium",s*f)}if(t.resource.Neutronium.display&&J.neutronium&&J.neutronium>0){let e=J.neutronium*d*S;r.p.Neutronium[F("tau_roid_mining_ship")]=J.neutronium+"v",S>1&&(r.p.Neutronium[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Neutronium",e*f)}if(c.elerium_ship){let e=c.elerium_ship*Pe("elerium_ship")*Pe("psychic_boost","Elerium"),a=ht("spc_belt"),s=e*G*d*m*a*_;r.p.Elerium[F("job_space_miner")]=e+"v",e>0&&(r.p.Elerium[`ᄂ${F("space_syndicate")}+0`]=-100*(1-a)+"%",r.p.Elerium[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%",r.p.Elerium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%",t.race.discharge&&t.race.discharge>0&&(s*=.75,r.p.Elerium[`ᄂ${F("evo_challenge_discharge")}`]="-25%")),Vi("Elerium",s*f)}if(o.elerium_prospector){let e=o.elerium_prospector*Pe("elerium_prospector")*Pe("psychic_boost","Elerium"),t=e*G*d*_;r.p.Elerium[F("interstellar_elerium_prospector_bd")]=e+"v",e>0&&(r.p.Elerium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Elerium",t*f)}if(t.space.elerium_mine&&i.elerium_mine){let e=ht("spc_kuiper"),a=i.elerium_mine*Pe("elerium_mine")*Pe("psychic_boost","Elerium"),s=a*d*m*e*G*_;r.p.Elerium[F("space_kuiper_mine",[t.resource.Elerium.name])]=a+"v",a>0&&(r.p.Elerium[`ᄂ${F("space_syndicate")}+1`]=-100*(1-e)+"%",r.p.Elerium[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%",r.p.Elerium[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Elerium",s*f)}if(t.resource.Elerium.display&&J.elerium&&J.elerium>0){let e=J.elerium*d*S;r.p.Elerium[F("tau_roid_mining_ship")]=J.elerium+"v",S>1&&(r.p.Elerium[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Elerium",e*f)}if(r.p.Elerium[F("hunger")]=100*(G-1)+"%",t.resource.Adamantite.display&&t.interstellar.mining_droid&&z.adam>0){let e=.075*z.adam*Pe("psychic_boost","Adamantite"),a=e*U.mult*d*_;if(r.p.Adamantite[F("interstellar_mining_droid_title")]=e+"v",e>0){if(t.interstellar.processing&&o.processing){let e=.12;t.tech.ai_core&&t.tech.ai_core>=2&&i.citadel>0&&(e+=.02*i.citadel);let s=o.processing*e;a*=1+s,r.p.Adamantite[`ᄂ${F("interstellar_processing_title")}`]=100*s+"%",t.race.discharge&&t.race.discharge>0&&(a*=.5,r.p.Adamantite[`ᄂ${F("evo_challenge_discharge")}`]="-50%")}r.p.Adamantite[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"}Vi("Adamantite",a*f)}if(i.s_gate&&t.resource.Adamantite.display&&t.galaxy.armed_miner&&n.armed_miner>0){let e=.23*n.armed_miner*Pe("psychic_boost","Adamantite"),t=1+.1*n.ore_processor,a=Et("gxy_alien2"),s=e*d*a*t*U.mult*_;r.p.Adamantite[F("galaxy_armed_miner_bd")]=e+"v",e>0&&(r.p.Adamantite[`ᄂ${F("galaxy_ore_processor")}`]=-100*(1-t)+"%",r.p.Adamantite[`ᄂ${F("galaxy_piracy")}`]=-100*(1-a)+"%",r.p.Adamantite[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Adamantite",s*f)}if(t.resource.Adamantite.display&&t.space.titan_mine){let e=ht("spc_titan"),a=i.ai_colonist?na(t.civic.titan_colonist.workers,"titan_colonist")+la(i.ai_colonist):na(t.civic.titan_colonist.workers,"titan_colonist"),s=Pe("titan_mine","adamantite")*c.titan_mine*a*Pe("psychic_boost","Adamantite"),o=s*U.mult*d*m*e*_;r.p.Adamantite[F("city_mine")]=s+"v",s>0&&(r.p.Adamantite[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Adamantite[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%",r.p.Adamantite[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Adamantite",o*f)}if(t.resource.Infernite.display){if(t.civic.hell_surveyor.workers>0){let e=t.tech.infernite>=3?.015:.01,a=na(t.civic.hell_surveyor.workers,"hell_surveyor")*e*Pe("psychic_boost","Infernite"),s=1;if(t.tech.infernite>=2&&i.sensor_drone){let e=t.tech.infernite>=4?t.tech.infernite>=6?.5:.2:.1;s=1+i.sensor_drone*e}let c=a*s*d;r.p.Infernite[F("job_hell_surveyor")]=a+"v",r.p.Infernite[`ᄂ${F("portal_sensor_drone_title")}`]=100*(s-1)+"%",Vi("Infernite",c*f)}if(i.infernite_mine){let e=Pe("infernite_mine"),a=i.infernite_mine*e*Pe("psychic_boost","Infernite"),s=a*d;t.portal.infernite_mine.lpmod=e*d,r.p.Infernite[F("city_mine")]=a+"v",Vi("Infernite",s*f)}}if(i.s_gate&&t.resource.Bolognium.display&&t.galaxy.bolognium_ship&&n.bolognium_ship>0){let e=n.bolognium_ship*Pe("bolognium_ship")*Pe("psychic_boost","Bolognium"),a=Et("gxy_gateway"),s=e*d*a*_;r.p.Bolognium[F("galaxy_bolognium_ship")]=e+"v",e>0&&(r.p.Bolognium[`ᄂ${F("galaxy_piracy")}+0`]=-100*(1-a)+"%",r.p.Bolognium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(s*=.5,r.p.Bolognium[`ᄂ${F("evo_challenge_discharge")}+0`]="-50%")),Vi("Bolognium",s*f)}if(t.civic.pit_miner.display)if(et()){let e=na(t.civic.pit_miner.workers,"pit_miner");e*=pi(e,"miner");let a=1+.5*(c.colony||0);{let t=e*Pe("psychic_boost","Bolognium");t*=Pe("mining_pit","bolognium");let s=t*d*a;r.p.Bolognium[F("job_pit_miner")]=t+"v",t>0&&(r.p.Bolognium[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Bolognium",s*f)}{let t=e*Pe("psychic_boost","Stone");t*=Pe("mining_pit","stone");let s=t*d*a;r.p.Stone[F("job_pit_miner")]=t+"v",t>0&&(r.p.Stone[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Stone",s*f)}{let t=e*Pe("psychic_boost","Adamantite");t*=Pe("mining_pit","adamantite");let s=t*U.mult*d*a;r.p.Adamantite[F("job_pit_miner")]=t+"v",t>0&&(r.p.Adamantite[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Adamantite",s*f)}if(t.tech.isolation){{let t=e*Pe("psychic_boost","Copper");t*=Pe("mining_pit","copper");let s=t*U.mult*d*a;r.p.Copper[F("job_pit_miner")]=t+"v",t>0&&(r.p.Copper[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Copper",s*f)}{let t=e*Pe("psychic_boost","Coal");t*=Pe("mining_pit","coal");let s=t*d*a;r.p.Coal[F("job_pit_miner")]=t+"v",t>0&&(r.p.Coal[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Coal",s*f)}if(t.race.lone_survivor){let t=e*Pe("psychic_boost","Aluminium");t*=Pe("mining_pit","aluminium");let s=t*U.mult*d*a;r.p.Aluminium[F("job_pit_miner")]=t+"v",t>0&&(r.p.Aluminium[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Aluminium",s*f)}{let t=e*Pe("psychic_boost","Chrysotile");t*=Pe("mining_pit","chrysotile");let s=t*d*a*G;r.p.Chrysotile[F("job_pit_miner")]=t+"v",t>0&&(r.p.Chrysotile[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%",r.p.Chrysotile[F("hunger")]=100*(G-1)+"%"),Vi("Chrysotile",s*f)}}}else{let e={},a=na(t.civic.pit_miner.workers,"pit_miner");a*=pi(a,"miner"),a*=Pe("mining_pit","materials");let s=1+.5*(c.colony||0),i=a*d*s;e[F("job_pit_miner")]=a+"v",a>0&&(e[`ᄂ${F("tau_home_colony")}`]=100*(s-1)+"%"),r.p.Materials=e,Vi("Materials",i*f)}if(t.tauceti.tau_farm&&i.tau_farm){let e=1+.5*(c.colony||0);if(!t.race.kindling_kindred&&!t.race.smoldering){let t=Pe("tau_farm","lumber")*i.tau_farm*Pe("psychic_boost","Lumber"),a=t*d*e;r.p.Lumber[F("tau_home_tau_farm")]=t+"v",t>0&&(r.p.Lumber[`ᄂ${F("tau_home_colony")}`]=100*(e-1)+"%"),Vi("Lumber",a*f)}}if(Kc()&&(r.p.Adamantite[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%"),i.s_gate&&t.resource.Bolognium.display&&t.galaxy.armed_miner&&n.armed_miner>0){let e=.032*n.armed_miner*Pe("psychic_boost","Bolognium"),a=1+.1*n.ore_processor,s=Et("gxy_alien2"),i=e*d*s*a*_;r.p.Bolognium[F("galaxy_armed_miner_bd")]=e+"v",e>0&&(r.p.Bolognium[`ᄂ${F("galaxy_ore_processor")}`]=-100*(1-a)+"%",r.p.Bolognium[`ᄂ${F("galaxy_piracy")}+1`]=-100*(1-s)+"%",r.p.Bolognium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(i*=.5,r.p.Bolognium[`ᄂ${F("evo_challenge_discharge")}+1`]="-50%")),Vi("Bolognium",i*f)}if(i.s_gate&&t.resource.Orichalcum.display&&t.galaxy.excavator&&i.excavator>0){let e=i.excavator*Pe("excavator")*Pe("psychic_boost","Orichalcum"),a=Et("gxy_chthonian"),s=e*d*a*_;t.galaxy.excavator.lpmod=Pe("excavator")*d*a*_,r.p.Orichalcum[F("galaxy_excavator")]=e+"v",e>0&&(r.p.Orichalcum[`ᄂ${F("galaxy_piracy")}`]=-100*(1-a)+"%",r.p.Orichalcum[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(s*=.5,t.galaxy.excavator.lpmod*=.5,r.p.Orichalcum[`ᄂ${F("evo_challenge_discharge")}`]="-50%")),Vi("Orichalcum",s*f)}if(t.space.orichalcum_mine&&i.orichalcum_mine){let e=ht("spc_kuiper"),a=i.orichalcum_mine*Pe("orichalcum_mine")*Pe("psychic_boost","Orichalcum"),s=a*d*m*e*_;r.p.Orichalcum[F("space_kuiper_mine",[t.resource.Orichalcum.name])]=a+"v",a>0&&(r.p.Orichalcum[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Orichalcum[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",r.p.Orichalcum[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Orichalcum",s*f)}if(t.resource.Orichalcum.display&&J.orichalcum&&J.orichalcum>0){let e=J.orichalcum*d*S;r.p.Orichalcum[F("tau_roid_mining_ship")]=J.orichalcum+"v",S>1&&(r.p.Orichalcum[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Orichalcum",e*f)}if(t.race.truepath&&t.tech.tau_red&&t.tech.tau_red>=5&&t.tauceti.womling_mine&&t.tauceti.overseer){let e=t.tauceti.womling_mine.miners*Pe("womling_mine","unobtainium")*Pe("psychic_boost","Unobtainium"),a=t.tauceti.overseer.prod/100,s=e*a*d;if(r.p.Unobtainium[F("tau_red_womlings")]=e+"v",e>0&&(r.p.Unobtainium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Unobtainium",s*f),t.tech.isolation){let e=t.tauceti.womling_mine.miners*Pe("womling_mine","uranium")*Pe("psychic_boost","Uranium");r.p.Uranium[F("tau_red_womlings")]=e+"v";let s=e*a*d;e>0&&(r.p.Uranium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Uranium",s*f);let i=t.tauceti.womling_mine.miners*Pe("womling_mine","titanium")*Pe("psychic_boost","Titanium");r.p.Titanium[F("tau_red_womlings")]=i+"v";let c=i*a*U.mult*d;if(i>0&&(r.p.Titanium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Titanium",c*f),t.race.lone_survivor){let e=t.tauceti.womling_mine.miners*Pe("womling_mine","copper")*Pe("psychic_boost","Copper");r.p.Copper[F("tau_red_womlings")]=e+"v";let s=e*a*U.mult*d;s>0&&(r.p.Copper[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Copper",s*f);let i=t.tauceti.womling_mine.miners*Pe("womling_mine","aluminium")*Pe("psychic_boost","Aluminium");r.p.Aluminium[F("tau_red_womlings")]=i+"v";let c=i*a*U.mult*d;i>0&&(r.p.Aluminium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Aluminium",c*f);let o=t.tauceti.womling_mine.miners*Pe("womling_mine","iridium")*Pe("psychic_boost","Iridium");r.p.Iridium[F("tau_red_womlings")]=o+"v";let n=o*a*U.mult*d;o>0&&(r.p.Iridium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Iridium",n*f);let l=t.tauceti.womling_mine.miners*Pe("womling_mine","neutronium")*Pe("psychic_boost","Neutronium");r.p.Neutronium[F("tau_red_womlings")]=l+"v";let u=l*a*G*d;l>0&&(r.p.Neutronium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Neutronium",u*f)}}}r.p.Neutronium[F("hunger")]=100*(G-1)+"%",Kc()&&(r.p.Iridium[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%"),r.p.Iridium[F("hunger")]=100*(G-1)+"%";let X=R?R*d:0;if(t.tech.currency>=1){let e=t.resource[t.race.species].amount+t.civic.garrison.workers-t.civic.unemployed.workers;if(t.race.high_pop&&(e=Me(e)),e*=t.race.truepath?.2:.4,t.race.greedy&&(e*=1-ui.greedy.vars()[0]/100),t.tech.isolation&&(e*=15),e*=Pe("psychic_cash"),x){if(t.tech.banking&&t.tech.banking>=2){let a=+na(t.civic.banker.impact,"banker");t.tech.banking>=10&&(a+=.02*t.tech.stock_exchange),t.race.truthful&&(a*=1-ui.truthful.vars()[0]/100),"republic"===t.civic.govern.type&&(a*=1+ae.republic()[0]/100),t.race.high_pop&&(a=Me(a)),e*=1+t.civic.banker.workers*a}}else e/=2;e*=t.civic.taxes.tax_rate/20,"oligarchy"===t.civic.govern.type&&(e*=1-ae.oligarchy()[0]/100),"corpocracy"===t.civic.govern.type&&(e*=.5),"socialist"===t.civic.govern.type&&(e*=1-ae.socialist()[3]/100),t.race.banana&&(e*=.05);let a=1;if(t.tech.anthropology&&t.tech.anthropology>=4)if(t.race.truepath){let e=t.resource[t.race.species].amount*t.city.temple.count*.08;r.p.Money[F("city_temple")]=e+"v",Vi("Money",+(e*d*f).toFixed(2))}else a+=.025*(t.race.cataclysm||t.race.orbit_decayed?t.space.ziggurat?t.space.ziggurat.count:0:t.city.temple.count);let s=0;if(!t.tech.world_control&&"federation"!==t.civic.govern.type)for(let a=0;a<3;a++)t.civic.foreign[`gov${a}`].buy&&(s+=.2*e);let i=Lc("tax"),c=(e-s)*a*i.mult;c*=d,r.p.Money[F("morale_tax")]=e+"v",e>0&&(r.p.Money[`ᄂ${F("civics_spy_purchase_bd")}`]=-s+"v",r.p.Money[t.race.cataclysm||t.race.orbit_decayed?`ᄂ${F("space_red_ziggurat_title")}`:`ᄂ${F("city_temple")}`]=100*(a-1)+"%",r.p.Money[`ᄂ${F("city_shrine")}`]=100*(i.mult-1)+"%"),r.p.Money[F("city_factory")]=R+"v",t.race.discharge&&t.race.discharge>0&&R>0&&(r.p.Money[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),Vi("Money",+(c*f).toFixed(2)),X+=c}if(t.race.truepath&&t.tauceti.overseer){let e=(t.tauceti.overseer.loyal+t.tauceti.overseer.morale)/200,a=t.tauceti.overseer.pop;i.womling_station&&(a+=2*i.womling_station);let s=a*e*(t.tech.isolation?25:12),c=i.tau_cultural_center?1+.08*i.tau_cultural_center:1,o=s*d*c;r.p.Money[F("tau_red_womlings")]=s+"v",r.p.Money[`ᄂ${F("tech_cultural_center")}`]=100*(c-1)+"%",Vi("Money",+(o*f).toFixed(2))}if(t.tech.gambling&&(i.casino||i.spc_casino||i.tauceti_casino)){let e=0;i.casino&&(e+=i.casino),i.spc_casino&&(e+=i.spc_casino),i.tauceti_casino&&(e+=i.tauceti_casino);let a=Math.log2(1+t.resource[t.race.species].amount),s=2.5;t.race.gambler&&(s*=1+ui.gambler.vars()[0]*t.race.gambler/100),a*=s,t.tech.gambling>=2&&(a*=t.tech.gambling>=5?2:1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(a*=1+.01*t.tech.stock_exchange),"corpocracy"===t.civic.govern.type&&(a*=1+ae.corpocracy()[0]/100),"socialist"===t.civic.govern.type&&(a*=1-ae.socialist()[3]/100),t.race.inflation&&(a*=1+t.race.inflation/1250),t.tech.isolation&&(a*=1.25,t.tech.iso_gambling&&(a*=1+.05*na(t.civic.banker.workers,"banker"))),a*=Pe("psychic_cash");let c=N("racketeer",1);c&&(a*=1+c/100),a*=e,r.p.Money[F("city_casino")]=a+"v",Vi("Money",+(a*f*d*G).toFixed(2)),X+=a*d*G}if(t.city.tourist_center){let e=0,s=t.tech.monument&&t.tech.monument>=3&&i.s_gate?3:1;t.city.amphitheatre&&(e+=t.city.tourist_center.on*t.city.amphitheatre.count*s),t.city.casino&&(e+=t.city.tourist_center.on*t.city.casino.count*5*s),t.space.spc_casino&&(e+=t.city.tourist_center.on*t.space.spc_casino.count*5*s),t.tech.monuments&&(e+=t.city.tourist_center.on*t.tech.monuments*2*s),t.city.trade&&t.stats.achieve.banana&&t.stats.achieve.banana.l>=4&&(e+=t.city.tourist_center.on*t.city.trade.count*3*s);let c=N("pious",1);c&&t.city.temple&&(e+=t.city.tourist_center.on*t.city.temple.count*c*s),"corpocracy"===t.civic.govern.type&&(e*=1+ae.corpocracy()[2]/100),"socialist"===t.civic.govern.type&&(e*=1-ae.socialist()[3]/100),"aquarius"===a&&(e*=1+H("aquarius")[0]/100),e*=Pe("psychic_cash"),r.p.Money[F("tech_tourism")]=Math.round(e)+"v","aquarius"===a&&(r.p.Money[`ᄂ${F("sign_aquarius")}`]=H("aquarius")[0]+"%"),Vi("Money",+(e*f*d*G).toFixed(2)),X+=e*d*G}if(t.tauceti.tau_cultural_center){let e=0;t.tauceti.tauceti_casino&&(e+=i.tau_cultural_center*i.tauceti_casino*20),t.tech.monuments&&(e+=i.tau_cultural_center*t.tech.monuments*5),t.tech.tau_culture&&t.tech.tau_culture>=2&&(e+=i.tau_cultural_center*c.colony*15),"corpocracy"===t.civic.govern.type?e*=1+ae.corpocracy()[2]/100:"socialist"===t.civic.govern.type&&(e*=1-ae.socialist()[3]/100),e*=Pe("psychic_cash"),r.p.Money[F("tech_cultural_center")]=Math.round(e)+"v","aquarius"===a&&(e*=1+H("aquarius")[0]/100,e[`ᄂ${F("sign_aquarius")}`]=H("aquarius")[0]+"%"),Vi("Money",+(e*f*d*G).toFixed(2)),X+=e*d*G}if(t.tech.tau_junksale){let e=40*c.womling_village,t=i.tau_cultural_center?1+.08*i.tau_cultural_center:1;r.p.Money[F("tau_red_womling_village")]=Math.round(e)+"v",r.p.Money[`ᄂ${F("tech_cultural_center")}+1`]=100*(t-1)+"%",Vi("Money",+(e*t*f*d*G).toFixed(2)),X+=e*t*d*G}{let e=N("racketeer",0);if(e){let t=-Math.round(X*(e/100));r.p.consume.Money[F("gov_trait_racketeer_bd")]=t,Vi("Money",+(t*f).toFixed(2))}}{let e=N("pious",0);if(e){let t=-Math.round(X*(e/100));r.p.consume.Money[F("gov_trait_pious_bd")]=t,Vi("Money",+(t*f).toFixed(2))}}if(t.tech.foundry){let e=t.race.resourceful?1-ui.resourceful.vars()[0]/100:1;Pi("arraak")>0&&ui.resourceful.vars(1)[0];let a=Ya(),s={};Xa("","",!0),Object.keys(a).forEach((function(i){if("Thermite"===i&&!Tc("summer"))return;r.p[i]={};let c=na(t.city.foundry[i],"craftsman");t.race.servants&&t.race.servants.hasOwnProperty("sjobs")&&t.race.servants.sjobs.hasOwnProperty(i)&&(c+=la(t.race.servants.sjobs[i]));let o=Xa(i,"auto").multiplier,n=t.genes.crafty?2:1,l=Math.floor(t.resource[a[i][0].r].amount/(a[i][0].a*n*e/140));for(let r=1;r0&&(r.p.consume[e][F("job_craftsman")]=-s[e])}))}!t.settings.showResearch&&(t.resource.Lumber.amount>=5||t.resource.Stone.amount>=6)&&(t.settings.showResearch=!0),t.city.power_total=-C,t.city.power=O,t.city.power<0?($("#powerMeter").addClass("low"),$("#powerMeter").removeClass("neutral"),$("#powerMeter").removeClass("high")):t.city.power>0?($("#powerMeter").removeClass("low"),$("#powerMeter").removeClass("neutral"),$("#powerMeter").addClass("high")):($("#powerMeter").removeClass("low"),$("#powerMeter").addClass("neutral"),$("#powerMeter").removeClass("high")),i.world_controller&&i.world_controller>0?0===t.tech.wsc&&(t.tech.wsc=1,ms()):0!==t.tech.wsc&&(t.tech.wsc=0,ms()),t.tech.portal>=2&&(t.portal.fortress.garrison>0?t.tech.portal_guard=1:t.tech.portal_guard=0),t.race.decay&&Object.keys(Za).forEach((function(e){if(t.resource[e].amount>50){let a=+((t.resource[e].amount-50)*(.001*Za[e])).toFixed(3);Vi(e,-a*f),r.p.consume[e][F("evo_challenge_decay")]=-a}else delete r.p.consume[e][F("evo_challenge_decay")]})),$o&&(t.tech.piracy&&Rt(),t.settings.portal.ruins&&(sc({el:"#srprtl_ruins"},"update"),sc({el:"#foundry"},"update")),t.settings.portal.gate&&sc({el:"#srprtl_gate"},"update"))}if(t.civic.garrison&&t.civic.garrison.workers=2?.08:.05;t.blood.lust&&(a+=.002*t.blood.lust);let r=N("militant",0);r&&(a*=1+r/100),e*=1+(t.race.orbit_decayed&&t.space.space_barracks?t.space.space_barracks.on:t.city.boot_camp.count)*a}t.race.beast&&(e*=1+ui.beast.vars()[2]/100),t.civic.garrison.rate=e*f,t.race.brute&&(t.civic.garrison.rate+=ui.brute.vars()[1]/40*f);let a=Pi("orc");a>0&&(t.civic.garrison.rate+=ui.brute.vars(1)[1]/40*a*f),t.civic.garrison.progress+=t.civic.garrison.rate,t.civic.garrison.progress>=100&&(t.civic.garrison.progress=0,t.civic.garrison.workers++,t.portal.fortress&&t.portal.fortress.assigned&&t.portal.fortress.garrison0?($("#portal-carport .count").hasClass("has-text-alert")||$("#portal-carport .count").addClass("has-text-alert"),t.portal.carport.repair++,t.portal.carport.repair>=Qr.portal.prtl_fortress.carport.repair()&&(t.portal.carport.repair=0,t.portal.carport.damaged--)):$("#portal-carport .count").hasClass("has-text-alert")&&$("#portal-carport .count").removeClass("has-text-alert")),Object.keys(t.resource).forEach((function(e){(t.resource[e].rate>0||0===t.resource[e].rate&&-1===t.resource[e].max)&&function(e,a){let s=1e3;if(t.race.slow){let e=1+ui.slow.vars()[0]/100;s=Math.floor(s*e)}if(t.race.hyper){let e=1-ui.hyper.vars()[0]/100;s=Math.floor(s*e)}t.resource[e].diff=+(t.resource[e].delta/(a/s)).toFixed(2),t.resource[e].delta=0,t.resource[e].hasOwnProperty("gen")&&t.resource[e].hasOwnProperty("gen_d")&&(t.resource[e].gen=+(t.resource[e].gen_d/(a/s)).toFixed(2),t.resource[e].gen_d=0);let i=$(`#res${e} .diff`);t.race.decay?t.resource[e].diff<0?t.resource[e].diff>=r.p.consume[e][F("evo_challenge_decay")]?i.hasClass("has-text-warning")||(i.removeClass("has-text-danger"),i.addClass("has-text-warning")):i.hasClass("has-text-danger")||(i.removeClass("has-text-warning"),i.addClass("has-text-danger")):t.resource[e].diff>=0&&(i.hasClass("has-text-danger")||i.hasClass("has-text-warning"))&&(i.removeClass("has-text-danger"),i.removeClass("has-text-warning")):t.resource[e].diff<0&&!i.hasClass("has-text-danger")?i.addClass("has-text-danger"):t.resource[e].diff>=0&&i.hasClass("has-text-danger")&&i.removeClass("has-text-danger")}(e,M.timers.main)})),t.settings.expose&&(window.evolve||go(),fo()),Tc("easter").active)for(b=1;b<=18;b++)$(`#egg${b}`).length>0&&!$(`#egg${b}`).hasClass("binded")&&(xc(b),$(`#egg${b}`).addClass("binded"));if(Tc("halloween").active){for(b=1;b<=7;b++)$(`#treat${b}`).length>0&&!$(`#treat${b}`).hasClass("binded")&&(qc(b,!1),$(`#treat${b}`).addClass("binded"));for(b=1;b<=7;b++)$(`#trick${b}`).length>0&&!$(`#trick${b}`).hasClass("binded")&&(qc(b,!0),$(`#trick${b}`).addClass("binded"))}$o=!1}();break;case"mid":!function(){const e=U();if("protoplasm"===t.race.species){let e=100;t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1&&(e+=50*(t.stats.achieve.mass_extinction.l-1));var a={RNA:e,DNA:e};if(t.evolution.membrane){let e=t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5;a.RNA+=t.evolution.membrane.count*e}if(t.evolution.eukaryotic_cell){let e=t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10;a.DNA+=t.evolution.eukaryotic_cell.count*e}t.resource.RNA.max=a.RNA,t.resource.DNA.max=a.DNA,Object.keys(Qr.evolution).forEach((function(e){if(Qr.evolution[e]&&Qr.evolution[e].cost){let t=Qr.evolution[e],a=$("#"+t.id);a.length>0&&(Cs(t)?a.hasClass("cna")&&a.removeClass("cna"):a.hasClass("cna")||a.addClass("cna"),Cs(t,!0)?a.hasClass("cnam")&&a.removeClass("cnam"):a.hasClass("cnam")||a.addClass("cnam"))}}))}else{a={Money:1e3,Slave:0,Mana:0,Energy:100,Sus:100,Knowledge:t.stats.achieve.extinct_junker&&t.stats.achieve.extinct_junker.l>=1?1e3:100,Zen:0,Food:1e3,Crates:0,Containers:0,Lumber:200,Stone:200,Chrysotile:200,Crystal:10,Furs:100,Copper:100,Iron:100,Cement:100,Coal:50,Oil:0,Uranium:10,Aluminium:50,Steel:50,Titanium:50,Alloy:50,Polymer:50,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:1,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Unobtainium:0,Cipher:0,Nanite:0,Materials:0};var s={unemployed:-1,hunter:-1,forager:-1,farmer:-1,lumberjack:-1,quarry_worker:-1,crystal_miner:-1,scavenger:-1,torturer:0,miner:0,coal_miner:0,craftsman:0,cement_worker:0,banker:0,entertainer:0,priest:0,professor:0,scientist:0,garrison:0,colonist:0,titan_colonist:0,space_miner:0,hell_surveyor:0,archaeologist:0,pit_miner:0,crew:0};if(t.race.cataclysm?(a.Money+=25e4,a.Knowledge+=1e5,a.Lumber+=1e5,a.Stone+=1e5,a.Chrysotile+=1e5,a.Furs+=1e5,a.Aluminium+=1e5,a.Steel+=1e5,a.Copper+=1e5,a.Iron+=1e5,a.Coal+=1e5,a.Cement+=1e5,a.Titanium+=75e3,a.Alloy+=2e4,a.Polymer+=2e4,a.Uranium+=1e3):t.race.lone_survivor&&(a.Money+=1e9,a.Knowledge+=1e5,a.Food+=9e3,a.Water+=1e4,a.Elerium+=999),t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0){let e=Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept);a.Lumber+=60*e,a.Stone+=60*e}t.race.hasOwnProperty("psychicPowers")&&t.race.psychicPowers.hasOwnProperty("channel")&&(a.Energy-=t.race.psychicPowers.channel.boost,a.Energy-=t.race.psychicPowers.channel.assault,a.Energy-=t.race.psychicPowers.channel.cash,a.Energy<0&&(a.Energy=100,t.race.psychicPowers.channel.boost=0,t.race.psychicPowers.channel.assault=0,t.race.psychicPowers.channel.cash=0));var d={[F("base")]:a.Money+"v"},_={},p={},h={[F("base")]:a.Mana+"v"},g={[F("base")]:a.Mana+"v"},f={[F("base")]:a.Knowledge+"v"},v={},y={},b={},w={[F("base")]:a.Food+"v"},x={[F("base")]:a.Lumber+"v"},k={[F("base")]:a.Stone+"v"},q={[F("base")]:a.Chrysotile+"v"},M={[F("base")]:a.Crystal+"v"},P={[F("base")]:a.Furs+"v"},O={[F("base")]:a.Copper+"v"},C={[F("base")]:a.Iron+"v"},j={[F("base")]:a.Cement+"v"},S={[F("base")]:a.Coal+"v"},z={[F("base")]:a.Oil+"v"},A={[F("base")]:a.Uranium+"v"},T={[F("base")]:a.Steel+"v"},E={[F("base")]:a.Aluminium+"v"},I={[F("base")]:a.Titanium+"v"},K={[F("base")]:a.Alloy+"v"},L={[F("base")]:a.Polymer+"v"},D={[F("base")]:a.Iridium+"v"},B={[F("base")]:a.Helium_3+"v"},G={[F("base")]:a.Water+"v"},R={[F("base")]:a.Deuterium+"v"},W={[F("base")]:a.Neutronium+"v"},Q={[F("base")]:a.Adamantite+"v"},Z={[F("base")]:a.Infernite+"v"},V={[F("base")]:a.Elerium+"v"},J={[F("base")]:a.Nano_Tube+"v"},Y={[F("base")]:a.Graphene+"v"},X={[F("base")]:a.Stanene+"v"},te={[F("base")]:a.Bolognium+"v"},ae={[F("base")]:a.Vitreloy+"v"},re={[F("base")]:a.Orichalcum+"v"},se={[F("base")]:a.Unobtainium+"v"},ie={[F("base")]:a.Cipher+"v"},ce={[F("base")]:a.Nanite+"v"},oe={[F("base")]:a.Materials+"v"};if(r.c={Money:d,[t.race.species]:_,Slave:p,Mana:h,Sus:g,Knowledge:f,Zen:v,Crates:y,Containers:b,Food:w,Lumber:x,Stone:k,Chrysotile:q,Crystal:M,Furs:P,Copper:O,Iron:C,Cement:j,Coal:S,Oil:z,Uranium:A,Steel:T,Aluminium:E,Titanium:I,Alloy:K,Polymer:L,Iridium:D,Helium_3:B,Water:G,Deuterium:R,Neutronium:W,Adamantite:Q,Infernite:Z,Elerium:V,Nano_Tube:J,Graphene:Y,Stanene:X,Bolognium:te,Vitreloy:ae,Orichalcum:re,Unobtainium:se,Nanite:ce,Cipher:ie,Materials:oe},a[t.race.species]=0,t.race.unfathomable&&t.city.captive_housing){let e=t.tech.military?t.tech.military>=5?t.tech.military-1:t.tech.military:1,a=na(t.civic.hunter.workers,"hunter")*e;a*=pi(a,"hunting"),t.race.swift&&(a*=1+ui.swift.vars()[1]/100),t.race.servants&&(a+=t.race.servants.jobs.hunter*e);let r=0,s=0,i=[];if(t.city.hasOwnProperty("surfaceDwellers"))for(let e=0;e0&&i.push(e)}let c=Math.round(40/ui.unfathomable.vars()[1]);if(r=2&&t.civic.torturer.workers>0&&i.length>0&&Math.rand(0,Math.ceil((s+1)**1.45))0&&(t.race.psychicPowers.boostTime--,(t.race.psychicPowers.boostTime<0||t.race.psychicPowers.boostTime>360)&&(t.race.psychicPowers.boostTime=0)),t.race.psychicPowers&&t.race.psychicPowers.assaultTime&&t.race.psychicPowers.assaultTime>0&&(t.race.psychicPowers.assaultTime--,(t.race.psychicPowers.assaultTime<0||t.race.psychicPowers.assaultTime>360)&&(t.race.psychicPowers.assaultTime=0)),t.race.psychicPowers&&t.race.psychicPowers.cash&&t.race.psychicPowers.cash>0&&(t.race.psychicPowers.cash--,(t.race.psychicPowers.cash<0||t.race.psychicPowers.cash>360)&&(t.race.psychicPowers.cash=0))),t.city.nanite_factory){let e=t.city.nanite_factory.count*Lr(2500);a.Nanite+=e,ce[F("city_nanite_factory")]=e+"v"}if(i.transmitter&&t.race.artifical){let e=i.transmitter*Lr(100);a.Food+=e,w[F("city_transmitter")]=e+"v"}if(t.city.pylon||t.space.pylon||t.tauceti.pylon){let e=0,r="city_pylon";(t.race.cataclysm||t.race.orbit_decayed)&&t.space.pylon?(e=Lr(2)*t.space.pylon.count,r="space_red_pylon"):t.tech.isolation&&t.tauceti.pylon?(e=Lr(2)*t.tauceti.pylon.count,r="tau_home_pylon"):t.city.pylon&&(e=Lr(5)*t.city.pylon.count),a.Mana+=e,h[F(r)]=e+"v"}if(t.city.captive_housing){let e=t.city.captive_housing.count;t.city.captive_housing.raceCap=e*(t.tech.unfathomable&&t.tech.unfathomable>=3?3:2),t.city.captive_housing.cattleCap=5*e}if(t.city.farm&&t.tech.farm){let e=t.city.farm.count*Qr.city.farm.citizens();a[t.race.species]+=e,_[F("city_farm")]=e+"v"}if(t.city.wharf){let e=t.tech.world_control?15:10;t.tech.particles&&t.tech.particles>=2&&(e*=2),a.Crates+=t.city.wharf.count*e,y[F("city_wharf")]=t.city.wharf.count*e+"v",a.Containers+=t.city.wharf.count*e,b[F("city_wharf")]=t.city.wharf.count*e+"v"}if(t.space.munitions_depot){let e=25;a.Crates+=t.space.munitions_depot.count*e,y[F("tech_munitions_depot")]=t.space.munitions_depot.count*e+"v",a.Containers+=t.space.munitions_depot.count*e,b[F("tech_munitions_depot")]=t.space.munitions_depot.count*e+"v"}if(t.interstellar.cargo_yard){a.Crates+=50*t.interstellar.cargo_yard.count,y[F("interstellar_cargo_yard_title")]=50*t.interstellar.cargo_yard.count+"v",a.Containers+=50*t.interstellar.cargo_yard.count,b[F("interstellar_cargo_yard_title")]=50*t.interstellar.cargo_yard.count+"v";let e=t.interstellar.cargo_yard.count*Lr(200);a.Neutronium+=e,W[F("interstellar_cargo_yard_title")]=e+"v",e=t.interstellar.cargo_yard.count*Lr(150),a.Infernite+=e,Z[F("interstellar_cargo_yard_title")]=e+"v"}if(t.interstellar.neutron_miner&&i.neutron_miner){let e=i.neutron_miner*Lr(500);a.Neutronium+=e,W[F("interstellar_neutron_miner_title")]=e+"v"}if(t.city.storage_yard){let e=t.tech.container>=3?20:10;t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),a.Crates+=t.city.storage_yard.count*e,y[F("city_storage_yard")]=t.city.storage_yard.count*e+"v"}if(t.space.garage){let e=t.tech.particles>=4?20+t.tech.supercollider:20;(t.tech.world_control||t.race.cataclysm)&&(e+=10),a.Containers+=t.space.garage.count*e,b[F("space_red_garage_title")]=t.space.garage.count*e+"v",(t.race.cataclysm||t.race.orbit_decayed)&&(a.Crates+=t.space.garage.count*e,y[F("space_red_garage_title")]=t.space.garage.count*e+"v")}if(t.tech.tp_depot&&(a.Containers+=50*t.tech.tp_depot,b[F("galaxy_gateway_depot")]=50*t.tech.tp_depot+"v",a.Crates+=50*t.tech.tp_depot,y[F("galaxy_gateway_depot")]=50*t.tech.tp_depot+"v"),t.city.warehouse){let e=t.tech.steel_container>=2?20:10;t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),a.Containers+=t.city.warehouse.count*e,b[F("city_warehouse")]=t.city.warehouse.count*e+"v"}if(t.city.rock_quarry){let e=cs(t.city.rock_quarry.count*Lr(100));a.Stone+=e,k[F("city_rock_quarry")]=e+"v",a.Chrysotile+=e,q[F("city_rock_quarry")]=e+"v"}if(t.city.lumber_yard){let e=cs(t.city.lumber_yard.count*Lr(100));a.Lumber+=e,x[F("city_lumber_yard")]=e+"v"}else if(t.city.graveyard){let e=cs(t.city.graveyard.count*Lr(100));a.Lumber+=e,x[F("city_graveyard")]=e+"v"}if(t.city.sawmill){let e=cs(t.city.sawmill.count*Lr(200));a.Lumber+=e,x[F("city_sawmill")]=e+"v"}if(t.city.mine&&(s.miner+=la(t.city.mine.count)),t.city.coal_mine&&(s.coal_miner+=la(t.city.coal_mine.count)),t.city.bank&&(s.banker+=la(t.city.bank.count)),t.city.amphitheatre){let e=N("athleticism",1);s.entertainer+=la(e?t.city.amphitheatre.count*e:t.city.amphitheatre.count)}if(t.city.casino&&(s.entertainer+=la(t.city.casino.count)),t.space.spc_casino&&(s.entertainer+=la(t.space.spc_casino.count),t.race.orbit_decayed&&(s.banker+=la(t.space.spc_casino.count))),t.tauceti.tauceti_casino&&(s.entertainer+=la(t.tauceti.tauceti_casino.count),t.tech.isolation)){s.banker+=la(t.tauceti.tauceti_casino.count);let e=i.tauceti_casino*Qr.tauceti.tau_home.tauceti_casino.citizens();a[t.race.species]+=e,_[F("city_casino")]=e+"v"}if(t.galaxy.resort&&(s.entertainer+=la(2*i.resort)),t.city.cement_plant&&(s.cement_worker+=la(2*t.city.cement_plant.count)),t.race.orbit_decayed&&i.red_factory&&(s.cement_worker+=la(i.red_factory)),t.race.parasite&&!t.tech.isolation&&(s.garrison+=la(2)),t.city.garrison&&(s.garrison+=t.city.garrison.on*(t.tech.military>=5?la(3):la(2)),t.race.chameleon&&(s.garrison-=t.city.garrison.on)),t.space.space_barracks){let e=t.tech.marines>=2?la(4):la(2);s.garrison+=t.space.space_barracks.on*e}if(t.interstellar.cruiser&&(s.garrison+=o.cruiser*la(3)),i.s_gate&&t.galaxy.starbase){let e=t.tech.marines>=2?la(8):la(5);s.garrison+=i.starbase*e}if(t.race.orbit_decayed&&t.space.hasOwnProperty("red_mine")&&(s.miner+=la(c.red_mine),s.coal_miner+=la(c.red_mine)),!t.tech.world_control){let e=la("federation"===t.civic.govern.type?15:20);for(let a=2;a>=0;a--)t.civic.foreign[`gov${a}`].occ&&(s.garrison-=e,s.garrison<0&&(t.civic.foreign[`gov${a}`].occ=!1,s.garrison+=e,t.civic.garrison.workers+=e,Di(F("civics_garrison_autodeoccupy_desc",[ee(a)]),"danger",!1,["spy"])))}if(t.race.slaver&&t.tech.slaves&&t.city.slave_pen&&(a.Slave=4*t.city.slave_pen.count,p[F("city_slave_pen")]=4*t.city.slave_pen.count+"v",a.Slavet.resource.Zen.max&&(t.resource.Zen.amount=t.resource.Zen.max);let e=t.resource.Zen.amount/(t.resource.Zen.amount+5e3);v[F("trait_calm_desc")]=`+${(100*e).toFixed(2)}%`}if(t.city.basic_housing){let e=t.city.basic_housing.count*Qr.city.basic_housing.citizens();a[t.race.species]+=e,_[Is("small")]=e+"v"}if(t.tauceti.tau_housing&&t.tech.isolation){let e=t.tauceti.tau_housing.count*Qr.tauceti.tau_home.tau_housing.citizens();a[t.race.species]+=e,_[Is("small")]=e+"v"}if(t.city.cottage){let e=t.city.cottage.count*Qr.city.cottage.citizens();if(a[t.race.species]+=e,_[Is("medium")]=e+"v",t.tech.home_safe){let e=t.city.cottage.count*Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?5e3:2e3:1e3);a.Money+=e,d[Is("medium")]=e+"v"}}if(t.city.apartment){let e=i.apartment*Qr.city.apartment.citizens();if(a[t.race.species]+=e,_[Is("large")]=e+"v",t.tech.home_safe){let e=i.apartment*Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?1e4:5e3:2e3);a.Money+=e,d[Is("large")]=e+"v"}}if(i.s_gate&&t.galaxy.consulate&&t.galaxy.consulate.count>=1){let e=Qr.galaxy.gxy_alien1.consulate.citizens();a[t.race.species]+=e,_[F("galaxy_consulate")]=e+"v"}if(i.s_gate&&i.embassy&&t.tech.xeno>=11){let e=Qr.galaxy.gxy_gorddon.embassy.citizens();a[t.race.species]+=e,_[F("galaxy_embassy")]=e+"v"}if(i.s_gate&&i.embassy&&t.galaxy.dormitory){let e=i.dormitory*Qr.galaxy.gxy_gorddon.dormitory.citizens();a[t.race.species]+=e,_[F("galaxy_dormitory")]=e+"v"}if(i.arcology){let e=i.arcology*Qr.portal.prtl_ruins.arcology.citizens();a[t.race.species]+=e,_[F("portal_arcology_title")]=e+"v",s.garrison+=i.arcology*la(5),a.Containers+=i.arcology*Math.round(u)*10,b[F("portal_arcology_title")]=i.arcology*Math.round(u)*10+"v",a.Crates+=i.arcology*Math.round(u)*10,y[F("portal_arcology_title")]=i.arcology*Math.round(u)*10+"v";let r=Oa("ruins"),c=i.arcology*Lr(8*Hs()*r.supress);a.Money+=c,d[F("portal_arcology_title")]=c+"v"}if(c.colony){let e=t.tech.isolation?900:250;a.Containers+=c.colony*e,b[F("tau_home_colony")]=c.colony*e+"v",a.Crates+=c.colony*e,y[F("tau_home_colony")]=c.colony*e+"v";let r=c.colony*Qr.tauceti.tau_home.colony.citizens();a[t.race.species]+=r,_[F("tau_home_colony")]=r+"v"}if(i.operating_base&&(s.garrison+=Math.min(c.operating_base,i.operating_base)*la(4)),i.fob&&(s.garrison+=la(10)),t.space.living_quarters){let e=Math.round(c.living_quarters*Qr.space.spc_red.living_quarters.citizens());if(a[t.race.species]+=e,s.colonist+=la(c.living_quarters),_[`${Xt().red}`]=e+"v",(t.race.cataclysm||t.race.orbit_decayed)&&t.tech.home_safe){let e=c.living_quarters*Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?1e5:5e4:25e3);a.Money+=e,d[F("space_red_living_quarters_title")]=e+"v"}}if(c.biodome&&(t.race.artifical||t.race.orbit_decayed)){let e=c.biodome*Lr(t.race.artifical?500:100);a.Food+=e,w[F("space_red_signal_tower_title")]=e+"v"}if(t.space.titan_quarters){let e=Math.round(c.titan_quarters*Qr.space.spc_titan.titan_quarters.citizens());a[t.race.species]+=e,s.titan_colonist+=la(c.titan_quarters),_[`${Xt().titan}`]=e+"v"}if(t.interstellar.habitat&&i.habitat){let e=i.habitat*Qr.interstellar.int_alpha.habitat.citizens();a[t.race.species]+=e,_[F("interstellar_habitat_title")]=e+"v"}if(t.interstellar.luxury_condo&&i.luxury_condo){let e=i.luxury_condo*Qr.interstellar.int_alpha.luxury_condo.citizens();a[t.race.species]+=e,_[F("tech_luxury_condo")]=e+"v";let r=i.luxury_condo*Lr(75e4);a.Money+=r,d[F("tech_luxury_condo")]=r+"v"}if(t.city.lodge){let e=t.city.lodge.count*Qr.city.lodge.citizens();a[t.race.species]+=e,_[F("city_lodge")]=e+"v"}if(t.space.outpost){let e=t.space.outpost.count*Lr(500);a.Neutronium+=e,W[F("space_gas_moon_outpost_title")]=e+"v"}if(t.city.shed){var ne=os();let e=t.tech.storage<=2?F("city_shed_title1"):t.tech.storage>=4?F("city_shed_title3"):F("city_shed_title2");for(const s of Qr.city.shed.res())if(t.resource[s].display){let i=t.city.shed.count*Lr(Qr.city.shed.val(s)*ne);a[s]+=i,r.c[s][e]=i+"v"}}if(t.race.lone_survivor&&(_[F("base")]="1v",a[t.race.species]=1),t.interstellar.warehouse){ne=os();let e=F("interstellar_alpha_name");for(const s of Qr.interstellar.int_alpha.warehouse.res())if(t.resource[s].display){let i=t.interstellar.warehouse.count*Lr(Qr.interstellar.int_alpha.warehouse.val(s)*ne);a[s]+=i,r.c[s][e]=i+"v"}}if(t.space.storehouse){ne=bt("storehouse",!1);var le=bt("storehouse",!0);let e=F("space_storehouse_title");for(const s of Qr.space.spc_titan.storehouse.res())if(t.resource[s].display){let i=Qr.space.spc_titan.storehouse.heavy(s),c=t.space.storehouse.count*Lr(Qr.space.spc_titan.storehouse.val(s)*(i?le:ne));a[s]+=c,r.c[s][e]=c+"v"}}if(t.tauceti.repository){ne=bt("repository");let e=F("tech_repository");for(const s of Qr.tauceti.tau_home.repository.res())if(t.resource[s].display){let i=t.tauceti.repository.count*Lr(Qr.tauceti.tau_home.repository.val(s)*ne);a[s]+=i,r.c[s][e]=i+"v"}if(t.tech.isolation){let e=250;a.Containers+=t.tauceti.repository.count*e,b[F("tech_repository")]=t.tauceti.repository.count*e+"v",a.Crates+=t.tauceti.repository.count*e,y[F("tech_repository")]=t.tauceti.repository.count*e+"v"}}if(t.tech.isolation&&i.tau_farm&&t.race.artifical){let e=i.tau_farm*Lr(350);a.Food+=e,w[F("tau_home_tau_farm")]=e+"v"}if(t.galaxy.gateway_depot){let e=t.tech.world_control?150:100;a.Crates+=t.galaxy.gateway_depot.count*e,y[F("galaxy_gateway_depot")]=t.galaxy.gateway_depot.count*e+"v",a.Containers+=t.galaxy.gateway_depot.count*e,b[F("galaxy_gateway_depot")]=t.galaxy.gateway_depot.count*e+"v";let r=F("galaxy_gateway_depot"),s=Kt();if(t.resource.Uranium.display){let e=t.galaxy.gateway_depot.count*Lr(3e3*s);a.Uranium+=e,A[r]=e+"v"}if(t.resource.Nano_Tube.display){let e=t.galaxy.gateway_depot.count*Lr(25e4*s);a.Nano_Tube+=e,J[r]=e+"v"}if(t.resource.Neutronium.display){let e=t.galaxy.gateway_depot.count*Lr(9001*s);a.Neutronium+=e,W[r]=e+"v"}if(t.resource.Infernite.display){let e=t.galaxy.gateway_depot.count*Lr(6660*s);a.Infernite+=e,Z[r]=e+"v"}if(t.resource.Elerium.display&&i.gateway_depot&&i.s_gate){let e=i.gateway_depot*Lr(200);a.Elerium+=e,V[r]=e+"v"}}if(t.resource.Infernite.display&&t.portal.fortress){let e=Lr(1e3);a.Infernite+=e,Z[F("portal_fortress_name")]=e+"v"}if(t.space.garage){ne=Qr.space.spc_red.garage.multiplier(!1),le=Qr.space.spc_red.garage.multiplier(!0);let e=F("space_red_garage_title");for(const s of Qr.space.spc_red.garage.res())if(t.resource[s].display){let i=Qr.space.spc_red.garage.heavy(s),c=t.space.garage.count*Lr(Qr.space.spc_red.garage.val(s)*(i?le:ne));a[s]+=c,r.c[s][e]=c+"v"}}if(t.portal.harbour&&i.harbour){let e=F("portal_harbour_title");for(const s of Qr.portal.prtl_lake.harbour.res())if(t.resource[s].display){let t=i.harbour*Lr(Qr.portal.prtl_lake.harbour.val(s));a[s]+=t,r.c[s][e]=t+"v"}}if(t.city.silo){let e=cs(t.city.silo.count*Lr(500));a.Food+=e,w[F("city_silo")]=e+"v"}if(t.city.compost){let e=cs(t.city.compost.count*Lr(200));a.Food+=e,w[F("city_compost_heap")]=e+"v"}if(t.city.soul_well){let e=cs(t.city.soul_well.count*Lr(500));a.Food+=e,w[F("city_soul_well")]=e+"v"}if(t.city.smokehouse){let e=cs(t.city.smokehouse.count*Lr(100));a.Food+=e,w[F("city_smokehouse")]=e+"v"}if(t.city.oil_well){let e=t.city.oil_well.count*Lr(500);a.Oil+=e,z[F("city_oil_well")]=e+"v"}if(t.city.oil_depot){let e=t.city.oil_depot.count*Lr(1e3);e*=t.tech.world_control?1.5:1,a.Oil+=e,z[F("city_oil_depot")]=e+"v",t.tech.uranium>=2&&(e=t.city.oil_depot.count*Lr(250),e*=t.tech.world_control?1.5:1,a.Uranium+=e,A[F("city_oil_depot")]=e+"v"),t.resource.Helium_3.display&&(e=t.city.oil_depot.count*Lr(400),e*=t.tech.world_control?1.5:1,a.Helium_3+=e,B[F("city_oil_depot")]=e+"v")}if(t.space.propellant_depot){let e=t.space.propellant_depot.count*Lr(1250);e*=t.tech.world_control?1.5:1,a.Oil+=e,z[F("space_home_propellant_depot_title")]=e+"v",t.resource.Helium_3.display&&(e=t.space.propellant_depot.count*Lr(1e3),e*=t.tech.world_control?1.5:1,a.Helium_3+=e,B[F("space_home_propellant_depot_title")]=e+"v")}if(i.orbital_station){let e=i.orbital_station*Lr(15e3);a.Helium_3+=e,B[F("tau_home_orbital_station")]=e+"v"}if(i.refueling_station){let e=i.refueling_station*Lr(1e4);if(a.Helium_3+=e,B[F("tau_gas_refueling_station_title")]=e+"v",t.tech.tau_whale>=2){let e=i.refueling_station*Lr(6500);a.Oil+=e,z[F("tau_gas_refueling_station_title")]=e+"v"}}if(i.orbital_platform){let e=i.orbital_platform*Lr(17500);a.Oil+=e,z[F("tau_red_orbital_platform")]=e+"v"}if(t.space.gas_storage){let e=t.space.gas_storage.count*Lr(3500);e*=t.tech.world_control?1.5:1,a.Oil+=e,z[`${Xt().gas} ${F("depot")}`]=e+"v",e=t.space.gas_storage.count*Lr(2500),e*=t.tech.world_control?1.5:1,a.Helium_3+=e,B[`${Xt().gas} ${F("depot")}`]=e+"v",e=t.space.gas_storage.count*Lr(1e3),e*=t.tech.world_control?1.5:1,a.Uranium+=e,A[`${Xt().gas} ${F("depot")}`]=e+"v"}if(i.xfer_station){let e=i.xfer_station*Lr(5e3);if(a.Helium_3+=e,B[F("interstellar_xfer_station_title")]=e+"v",e=i.xfer_station*Lr(4e3),a.Oil+=e,z[F("interstellar_xfer_station_title")]=e+"v",e=i.xfer_station*Lr(2500),a.Uranium+=e,A[F("interstellar_xfer_station_title")]=e+"v",t.resource.Deuterium.display){let e=i.xfer_station*Lr(2e3);a.Deuterium+=e,R[F("interstellar_xfer_station_title")]=e+"v"}}if(t.space.helium_mine){let e=t.space.helium_mine.count*Lr(100);a.Helium_3+=e,B[F("space_moon_helium_mine_title")]=e+"v"}if(Kc()){let e=Lc("know");a.Knowledge+=e.add,f[F("city_shrine")]=e.add+"v"}t.city.temple&&t.genes.ancients&&t.genes.ancients>=2&&(s.priest+=la(t.city.temple.count)),t.space.ziggurat&&t.genes.ancients&&t.genes.ancients>=4&&(s.priest+=la(t.space.ziggurat.count));let U=Et("gxy_alien2");if(t.city.university){let e=Qr.city.university.knowVal()*t.city.university.count;s.professor+=la(t.city.university.count),a.Knowledge+=e,f[F("city_university")]=e+"v"}if(t.race.lone_survivor&&t.tauceti.alien_outpost&&(s.professor+=la(t.tauceti.alien_outpost.count)),t.city.library){let e=125;t.race.nearsighted&&(e*=1-ui.nearsighted.vars()[0]/100),t.race.studious&&(e*=1+ui.studious.vars()[1]/100);let r=Pi("elven");if(r>0&&(e*=1+ui.studious.vars(1)[1]/100*r),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.science&&t.tech.science>=5){let a=na(t.civic.scientist.workers,"scientist");t.race.high_pop&&(a=Me(a)),e*=1+.12*a}t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*(t.race.cataclysm||t.race.orbit_decayed?t.space.ziggurat?t.space.ziggurat.count:0:t.city.temple.count));let s=N("teacher",0);s&&(e*=1+s/100);let i=N("athleticism",2);i&&(e*=1-i/100);let c=N("muckraker",1);c&&(e*=1+c/100);let o=Math.round(t.city.library.count*e);a.Knowledge+=o,f[F("city_library")]=o+"v",t.tech.science&&t.tech.science>=3&&(t.civic.professor.impact=.5+.01*t.city.library.count)}if(t.city.wardenclyffe){let e=1e3;t.city.ptrait.includes("magnetic")&&(e+=Si.magnetic.vars()[1]);let r=t.city.wardenclyffe.count*e;s.scientist+=la(t.city.wardenclyffe.count);let c=t.tech.science>=7?1500:1e3;if(r+=i.wardenclyffe*c,t.tech.supercollider){let e=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;r*=t.tech.supercollider/e+1}t.space.satellite&&(r*=1+.04*t.space.satellite.count);let o=N("athleticism",2);if(o&&(r*=1-o/100),a.Knowledge+=r,f[Ts()]=r+"v","magic"===t.race.universe){let e=t.city.wardenclyffe.count*Lr(8);a.Mana+=e,h[Ts()]=e+"v"}if(t.race.artifical){let e=i.wardenclyffe*Lr(250);a.Food+=e,w[Ts()]=e+"v"}}if(t.race.logical){let e=t.tech.hasOwnProperty("high_tech")?t.tech.high_tech:0;e+=t.tech.hasOwnProperty("science")?t.tech.science:0;let r=t.resource[t.race.species].amount*ui.logical.vars()[1]*e;a.Knowledge+=r,f[di[t.race.species].name]=r+"v"}if(t.portal.sensor_drone){let e=i.sensor_drone*(t.tech.infernite>=6?2500:1e3);a.Knowledge+=e,f[F("portal_sensor_drone_title")]=e+"v"}if(t.space.satellite){let e=t.space.satellite.count*(t.race.cataclysm||t.race.orbit_decayed?2e3:750);if((t.race.cataclysm||t.race.orbit_decayed)&&t.tech.supercollider){let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?5:10;e*=t.tech.supercollider/a+1}a.Knowledge+=e,f[F("space_home_satellite_title")]=e+"v"}if(t.space.observatory&&t.space.observatory.count>0){let e=5e3*c.observatory;t.race.cataclysm&&t.space.satellite&&t.space.satellite.count>0&&(e*=1+.25*t.space.satellite.count),a.Knowledge+=e,f[F("space_moon_observatory_title")]=e+"v",t.race.cataclysm&&(s.professor+=la(c.observatory))}if(t.interstellar.laboratory&&o.laboratory>0){t.tech.science>=16&&(s.scientist+=la(o.laboratory));let e=1e4*o.laboratory;if(t.tech.science>=15&&(e*=1+.02*(t.race.cataclysm?c.exotic_lab:t.city.wardenclyffe.count)),t.race.cataclysm&&i.s_gate&&n.scavenger&&(e*=1+n.scavenger*Et("gxy_alien2")*.75),t.tech.science>=21&&(e*=1.45),a.Knowledge+=e,f[F("magic"===t.race.universe?"tech_sanctum":"interstellar_laboratory_title")]=e+"v","magic"===t.race.universe){let e=o.laboratory*Lr(12);a.Mana+=e,h[F("magic"===t.race.universe?"tech_sanctum":"interstellar_laboratory_title")]=e+"v"}}if(t.city.biolab){let e=3e3;t.portal.sensor_drone&&t.tech.science>=14&&(e*=1+.02*i.sensor_drone),t.tech.science>=20&&(e*=3),t.tech.science>=21&&(e*=1.45),t.tech.biotech>=1&&(e*=2.5),a.Knowledge+=i.biolab*e,f[F("city_biolab")]=i.biolab*e+"v"}if(t.space.zero_g_lab&&Math.min(c.zero_g_lab,i.zero_g_lab)>0){let e=Math.min(c.zero_g_lab,i.zero_g_lab),r=ht("spc_enceladus"),s=Math.round(1e4*e*r);if(a.Knowledge+=s,f[F("tech_zero_g_lab")]=s+"v",t.resource.Cipher.display){let t=1e4*e;a.Cipher+=t,ie[F("tech_zero_g_lab")]=t+"v"}}if(t.tech.isolation&&t.tauceti.alien_outpost&&t.resource.Cipher.display){let e=2e5;a.Cipher+=e,ie[F("tech_alien_outpost")]=e+"v"}if(t.portal.archaeology){let e=Oa("ruins"),r=25e4;t.race.high_pop&&(r=Me(r));let s=Math.round(r*e.supress);a.Knowledge+=na(t.civic.archaeologist.workers,"archaeologist")*s,f[F("portal_archaeology_bd")]=na(t.civic.archaeologist.workers,"archaeologist")*s+"v"}if(i.embassy&&t.galaxy.symposium){let e=1750*i.dormitory,r=650*t.galaxy.trade.cur,s=0;if(t.tech.xeno>=7){let e=t.galaxy.defense.gxy_gorddon.scout_ship*(Qr.galaxy.gxy_gateway.scout_ship.ship.civ()+Qr.galaxy.gxy_gateway.scout_ship.ship.mil());e+=t.galaxy.defense.gxy_gorddon.corvette_ship*(Qr.galaxy.gxy_gateway.corvette_ship.ship.civ()+Qr.galaxy.gxy_gateway.corvette_ship.ship.mil()),e+=t.galaxy.defense.gxy_gorddon.frigate_ship*(Qr.galaxy.gxy_gateway.frigate_ship.ship.civ()+Qr.galaxy.gxy_gateway.frigate_ship.ship.mil()),e+=t.galaxy.defense.gxy_gorddon.cruiser_ship*(Qr.galaxy.gxy_gateway.cruiser_ship.ship.civ()+Qr.galaxy.gxy_gateway.cruiser_ship.ship.mil()),e+=t.galaxy.defense.gxy_gorddon.dreadnought*(Qr.galaxy.gxy_gateway.dreadnought.ship.civ()+Qr.galaxy.gxy_gateway.dreadnought.ship.mil()),n.freighter&&(e+=n.freighter*(Qr.galaxy.gxy_gorddon.freighter.ship.civ()+Qr.galaxy.gxy_gorddon.freighter.ship.mil())),s=300*+Me(e).toFixed(2)}let c=(e+r+s)*i.symposium;a.Knowledge+=c,f[F("galaxy_symposium")]=c+"v"}if(t.city.bank||t.race.cataclysm&&i.spaceport){let e=t.race.cataclysm||t.race.orbit_decayed?4*Hs():Hs(),r=t.race.cataclysm||t.race.orbit_decayed?i.spaceport:t.city.bank.count,s=r*Lr(e);if(a.Money+=s,t.race.cataclysm||t.race.orbit_decayed?d[F("space_red_spaceport_title")]=s+"v":d[F("city_bank")]=s+"v",t.interstellar.exchange){let s=Lr(o.exchange*(e*r/18));t.race.inflation&&(s*=2),t.tech.banking>=13&&(t.galaxy.freighter&&(s*=1+.03*n.freighter),t.galaxy.super_freighter&&(s*=1+.08*n.super_freighter)),s=Math.round(s),a.Money+=s,d[F("interstellar_exchange_bd")]=s+"v"}}if(t.space.titan_bank){let e=2*Hs(),r=t.space.titan_bank.count*Lr(e);a.Money+=r,d[`${Xt().titan} ${F("city_bank")}`]=r+"v"}if(t.tauceti.colony&&t.tech.isolation){let e=25*Hs(),r=t.tauceti.colony.count*Lr(e);a.Money+=r,d[F("tau_home_colony")]=r+"v"}if(t.city.casino||t.space.spc_casino||t.tauceti.tauceti_casino){let e=0;t.city.casino&&t.city.casino.count>0&&(e+=t.city.casino.count),t.space.spc_casino&&t.space.spc_casino.count>0&&(e+=t.space.spc_casino.count),t.tauceti.tauceti_casino&&t.tauceti.tauceti_casino.count>0&&(e+=t.tauceti.tauceti_casino.count);let r=t.tech.gambling>=3?6e4:4e4;t.tech.gambling>=5&&(r+=t.tech.gambling>=6?24e4:6e4);let s=e*Lr(r);t.race.gambler&&(s*=1+ui.gambler.vars()[0]*t.race.gambler/100),t.tech.world_control&&(s=Math.round(1.25*s)),t.tech.stock_exchange&&t.tech.gambling>=4&&(s*=1+.05*t.tech.stock_exchange),t.race.inflation&&(s*=1+t.race.inflation/100),t.tech.isolation&&(s*=5.5),a.Money+=s,d[F("city_casino")]=s+"v"}if(t.galaxy.resort){let e=i.resort*Lr(t.tech.world_control?1875e3:15e5);a.Money+=e,d[F("galaxy_resort")]=e+"v"}if(t.tech.banking>=4){let e=250;t.tech.banking>=11?e=1e3:t.tech.banking>=6&&(e=600);let r=e*(t.resource[t.race.species].amount+t.civic.garrison.workers);t.race.high_pop&&(r=Me(r)),a.Money+=r,d[F("tech_bonds")]=r+"v"}if(i.moon_base){let e=i.moon_base*Lr(500);a.Iridium+=e,D[F("space_moon_base_title")]=e+"v"}if(i.space_station&&(s.space_miner+=la(3*i.space_station),t.tech.asteroid>=5)){let e=i.space_station*Lr(5);a.Elerium+=e,V[F("space_belt_station_title")]=e+"v"}if(c.exotic_lab){let e=c.exotic_lab*Lr(10);a.Elerium+=e,V[F("space_red_exotic_lab_bd")]=e+"v";let r=500;if(t.tech.science>=13&&t.interstellar.laboratory&&(r+=25*o.laboratory),t.tech.ancient_study&&t.tech.ancient_study>=2&&(r+=15*t.space.ziggurat.count),t.tech.mass>=2){let e=na(t.civic.scientist.workers,"scientist");t.race.high_pop&&(e=Me(e)),r+=i.mass_driver*e}t.race.cataclysm&&c.observatory&&(r*=1+.25*c.observatory),(t.race.cataclysm||t.race.orbit_decayed)&&t.portal.sensor_drone&&t.tech.science>=14&&(r*=1+.02*i.sensor_drone),t.tech.science>=21&&(r*=1.45),t.race.high_pop&&(r=Me(r));let n=c.exotic_lab*na(t.civic.colonist.workers,"colonist")*r;a.Knowledge+=n,f[F("tech_exotic_bd")]=n+"v",(t.race.cataclysm||t.race.orbit_decayed)&&(s.scientist+=la(c.exotic_lab))}if(t.tech.isolation&&c.infectious_disease_lab&&(s.professor+=la(2*c.infectious_disease_lab),s.scientist+=la(c.infectious_disease_lab)),c.decoder){let e=i.ai_colonist?na(t.civic.titan_colonist.workers,"titan_colonist")+la(i.ai_colonist):na(t.civic.titan_colonist.workers,"titan_colonist"),r=c.decoder*e*2500;t.race.high_pop&&(r=Me(r)),i.ai_core2&&(r*=1.25),a.Knowledge+=r,f[F("space_decoder_title")]=r+"v"}if(i.elerium_contain){let e=i.elerium_contain*Lr(100);a.Elerium+=e,V[F("space_dwarf_elerium_contain_title")]=e+"v"}if(t.city.foundry&&(s.craftsman+=la(t.city.foundry.count)),c.fabrication&&(s.craftsman+=la(c.fabrication),t.race.cataclysm&&(s.cement_worker+=la(c.fabrication))),t.tech.isolation&&c.tau_factory&&(s.craftsman+=la(5*c.tau_factory),s.cement_worker+=la(2*c.tau_factory)),i.womling_station&&(s.craftsman+=la(1*i.womling_station),s.cement_worker+=la(1*i.womling_station)),i.stellar_forge&&(s.craftsman+=la(2*i.stellar_forge)),t.portal.carport&&(s.hell_surveyor+=t.portal.carport.count-t.portal.carport.damaged),i.archaeology&&(s.archaeologist+=la(2*i.archaeology)),i.nexus){let e=i.nexus*Lr(4e3);a.Helium_3+=e,B[F("interstellar_nexus_title")]=e+"v";let t=i.nexus*Lr(3500);a.Oil+=t,z[F("interstellar_nexus_title")]=t+"v";let r=i.nexus*Lr(3e3);a.Deuterium+=r,R[F("interstellar_nexus_title")]=r+"v";let s=i.nexus*Lr(25);a.Elerium+=s,V[F("interstellar_nexus_title")]=s+"v"}if(i.s_gate&&t.galaxy.gateway_station){let e=i.gateway_station*Lr(2e3);a.Helium_3+=e,B[F("galaxy_gateway_station")]=e+"v";let t=i.gateway_station*Lr(4500);a.Deuterium+=t,R[F("galaxy_gateway_station")]=t+"v";let r=i.gateway_station*Lr(50);a.Elerium+=r,V[F("galaxy_gateway_station")]=r+"v"}if(i.s_gate&&i.telemetry_beacon){let e=t.tech.telemetry?1200:800;t.tech.science>=17&&(e+=25*n.scout_ship);let r=i.telemetry_beacon**2*e;a.Knowledge+=r,f[F("galaxy_telemetry_beacon_bd")]=r+"v"}if(i.s_gate&&n.scavenger){let e=n.scavenger*Math.round(25e3*U);a.Knowledge+=e,f[F("galaxy_scavenger")]=e+"v"}if(r.t_route={},t.city.market.mtrade=0,t.race.banana&&(t.city.market.mtrade++,r.t_route[F("base")]=1),t.city.trade){let e=t.race.nomadic||t.race.xenophobic?t.tech.trade:t.tech.trade+1;if(t.tech.trade&&t.tech.trade>=3&&e--,t.race.flier&&(e+=ui.flier.vars()[1]),t.city.market.mtrade+=e*t.city.trade.count,r.t_route[F("city_trade")]=e*t.city.trade.count,t.tech.fanaticism&&t.tech.fanaticism>=3){let e=t.race.cataclysm||t.race.orbit_decayed?t.space.ziggurat?t.space.ziggurat.count:0:t.city.temple.count;t.city.market.mtrade+=e,r.t_route[t.race.cataclysm?F("space_red_ziggurat_title"):F("city_temple")]=e}}if(t.city.wharf){let e=2*t.city.wharf.count;t.city.market.mtrade+=e,r.t_route[F("city_wharf")]=e}if(t.space.gps&&t.space.gps.count>=4){let e=2*t.space.gps.count;t.city.market.mtrade+=2*t.space.gps.count,r.t_route[F("space_home_gps_title")]=e}if(t.city.storage_yard&&t.tech.trade&&t.tech.trade>=3){let e=t.city.storage_yard.count;t.city.market.mtrade+=e,r.t_route[F("city_storage_yard")]=e}if(t.tech.railway){let e=0;e=t.race.cataclysm||t.race.orbit_decayed?t.space.gps?Math.floor(t.space.gps.count/3):0:t.city.storage_yard?Math.floor(t.city.storage_yard.count/6):0,t.stats.achieve.banana&&t.stats.achieve.banana.l>=2&&e++,t.city.market.mtrade+=t.tech.railway*e,r.t_route[F("arpa_projects_railway_title")]=t.tech.railway*e}if(i.titan_spaceport){let e=i.titan_spaceport*Lr(250);a.Water+=e,G[F("space_red_spaceport_title")]=e+"v"}if(t.tauceti.mining_pit&&(s.pit_miner+=la(c.mining_pit*(t.tech.isolation?6:8)),a.Materials+=1e6*c.mining_pit),t.civic.torturer.display&&t.tech.unfathomable&&t.tech.unfathomable>=2&&(s.torturer=t.city.captive_housing.count),"magic"===t.race.universe&&t.race.witch_hunter){let e=0;if(t.city.wardenclyffe){let a=t.city.wardenclyffe.count;a+=i.wardenclyffe,t.tech.roguemagic&&t.tech.roguemagic>=6&&(a/=2),g[Ts()]=a+"v",e+=a}if(t.civic.scientist.workers>0){let a=t.civic.scientist.workers;"magocracy"===t.civic.govern.type&&(a/=2),a=Me(a),g[F("job_wizard")]=a+"v",e+=a}if(t.city.coal_power&&!t.race.environmentalist){let a=i.coal_power;t.tech.roguemagic&&t.tech.roguemagic>=6&&(a/=2),g[F("city_mana_engine")]=a+"v",e+=a}if(t.city.pylon||t.space.pylon||t.tauceti.pylon){let a=0,r="city_pylon";(t.race.cataclysm||t.race.orbit_decayed)&&t.space.pylon?(a=t.space.pylon.count,r="space_red_pylon"):t.tech.isolation&&t.tauceti.pylon?(a=t.tauceti.pylon.count,r="tau_home_pylon"):t.city.pylon&&(a=t.city.pylon.count),t.tech.roguemagic&&t.tech.roguemagic>=5&&(a/=3),g[F(r)]=a+"v",e+=a}if(t.race.casting){let a=t.race.casting.total;t.tech.roguemagic&&t.tech.roguemagic>=2&&(t.tech.roguemagic>=4&&(a/=4),a-=Me(t.civic.priest.workers),a<0&&(a=0)),g[F("tech_rituals")]=a+"v",e+=a}if(t.race.totTransmute&&t.race.totTransmute>0){let a=t.race.totTransmute/5;g[F("tech_alchemy")]=a+"v",e+=a}let a=0;if(t.tech.explosives&&(a+=4),t.tech.military&&(t.tech.military>=10?a+=28:t.tech.military>=9?a+=24:t.tech.military>=8?a+=20:t.tech.military>=7?a+=16:t.tech.military>=6?a+=12:t.tech.military>=4?a+=8:t.tech.military>=3&&(a+=4)),g[F("witch_hunter_magic_tech")]=a+"v",e+=a,t.tech.roguemagic||(g[F("overt")]=5*e-e+"v",e*=5),t.tech.nexus){let a=.15*t.tech.nexus;g[F("arpa_projects_nexus_title")]=a+"v",e+=a}if(t.tech.syphon){let a=2.5*t.tech.syphon;g[F("arpa_syphon_title")]=a+"v",e+=a}if(t.portal.hasOwnProperty("soul_capacitor")){let a=i.soul_capacitor||0;t.portal.soul_capacitor.ecap=25e5*a,g[F("portal_soul_capacitor_title")]=a/3+"v",e+=a/3}if(t.tech.roguemagic&&t.tech.roguemagic>=3&&t.city.conceal_ward){let a=t.city.conceal_ward.count;t.tech.roguemagic>=8&&(a*=1.25),g[F("city_conceal_ward")]=-a+"v",e-=a}e<0&&(e=0),e=Math.floor(e),t.resource.Sus.amount=e,e>=50&&!t.race.witch_hunter_warned?(t.race.witch_hunter_warned=1,Di(F("witch_hunter_warning"),"danger",!1,["progress"])):e>=80&&t.race.witch_hunter_warned&&1===t.race.witch_hunter_warned&&(t.race.witch_hunter_warned=2,Di(F("witch_hunter_warning2"),"danger",!1,["progress"])),e>=100&&(t.civic.foreign.gov0.hstl=100,t.civic.foreign.gov1.hstl=100,t.civic.foreign.gov2.hstl=100,t.race.truepath&&(t.civic.foreign.gov3.hstl=100))}if(r.gt_route={},t.galaxy.freighter&&(r.gt_route[F("galaxy_freighter")]=2*n.freighter),t.galaxy.super_freighter&&(r.gt_route[F("galaxy_super_freighter")]=5*n.super_freighter),t.galaxy.bolognium_ship&&(s.crew+=t.galaxy.bolognium_ship.on*Qr.galaxy.gxy_gateway.bolognium_ship.ship.civ()),t.galaxy.scout_ship&&(s.crew+=t.galaxy.scout_ship.on*Qr.galaxy.gxy_gateway.scout_ship.ship.civ()),t.galaxy.corvette_ship&&(s.crew+=t.galaxy.corvette_ship.on*Qr.galaxy.gxy_gateway.corvette_ship.ship.civ()),t.galaxy.frigate_ship&&(s.crew+=t.galaxy.frigate_ship.on*Qr.galaxy.gxy_gateway.frigate_ship.ship.civ()),t.galaxy.cruiser_ship&&(s.crew+=t.galaxy.cruiser_ship.on*Qr.galaxy.gxy_gateway.cruiser_ship.ship.civ()),t.galaxy.dreadnought&&(s.crew+=t.galaxy.dreadnought.on*Qr.galaxy.gxy_gateway.dreadnought.ship.civ()),t.galaxy.freighter&&(s.crew+=t.galaxy.freighter.on*Qr.galaxy.gxy_gorddon.freighter.ship.civ()),t.galaxy.super_freighter&&(s.crew+=t.galaxy.super_freighter.on*Qr.galaxy.gxy_alien1.super_freighter.ship.civ()),t.galaxy.armed_miner&&(s.crew+=t.galaxy.armed_miner.on*Qr.galaxy.gxy_alien2.armed_miner.ship.civ()),t.galaxy.scavenger&&(s.crew+=t.galaxy.scavenger.on*Qr.galaxy.gxy_alien2.scavenger.ship.civ()),t.portal.transport&&(s.crew+=t.portal.transport.on*Qr.portal.prtl_lake.transport.ship.civ()),t.tauceti.infectious_disease_lab){let e=39616;if(t.tech.supercollider&&t.tech.isolation){let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}if(a.Knowledge+=i.infectious_disease_lab*Math.round(e),f[Qr.tauceti.tau_home.infectious_disease_lab.title()]=i.infectious_disease_lab*e+"v",t.tech.isolation){let e=c.infectious_disease_lab*Lr(375);a.Elerium+=e,V[Qr.tauceti.tau_home.infectious_disease_lab.title()]=e+"v"}}if(t.race.truepath&&t.tauceti.overseer&&t.tech.tau_red&&t.tech.tau_red>=5){let e=0,r=t.tauceti.overseer.injured,s=0,i=0,o=0;t.race.womling_friend?(i+=25+c.overseer*Qr.tauceti.tau_red.overseer.val(),s+=75+c.womling_fun*Qr.tauceti.tau_red.womling_fun.val()):t.race.womling_god?(i+=75+c.overseer*Qr.tauceti.tau_red.overseer.val(),s+=40+c.womling_fun*Qr.tauceti.tau_red.womling_fun.val()):t.race.womling_lord&&(i+=c.overseer*Qr.tauceti.tau_red.overseer.val(),s+=30+c.womling_fun*Qr.tauceti.tau_red.womling_fun.val());let n=t.tech.womling_pop&&t.tech.womling_pop>=2?6:5;e=c.womling_village*n;let l=2*c.womling_farm;l>e&&(l=e);let u=t.tech.womling_pop?8:6;t.tech.womling_gene&&(u+=2),e>l*u&&(e=l*u);let d=e-l-r,_=0;if(c.womling_lab){_=c.womling_lab,_>d&&(_=d),d-=_;let e=_*Math.round(25e3*t.tauceti.overseer.prod/100);if(a.Knowledge+=e,f[F("interstellar_laboratory_title")]=e+"v",Math.rand(0,10)=5?4.9:5;t.race.lone_survivor&&(e-=.1),t.tauceti.womling_lab.tech>=Math.round((t.tech.womling_tech+2)**e)&&(t.tech.womling_tech++,t.tauceti.womling_lab.tech=0,Di(F("tau_red_womling_advancement",[t.tech.womling_tech]),"advanced",!1,["progress"]),ms())}}let p=6*c.womling_mine;p>d&&(p=d),d-=p;let h=t.tech.tech_womling_firstaid?3:4;if(0===Math.rand(0,10)){let e=Math.rand(0,p+_);e>r&&(r=e)}else r>0&&0===Math.rand(0,h)&&r--;t.tauceti.hasOwnProperty("womling_farm")&&(t.tauceti.womling_farm.farmers=l),t.tauceti.hasOwnProperty("womling_mine")&&(t.tauceti.womling_mine.miners=p),t.tauceti.hasOwnProperty("womling_lab")&&(t.tauceti.womling_lab.scientist=_),i-=p,s-=p,s-=l,s-=r,i>100?i=100:i<0&&(i=0),s>100?s=100:s<0&&(s=0),o=Math.round((i+s)/2),t.tauceti.overseer.loyal=i,t.tauceti.overseer.morale=s,t.tauceti.overseer.pop=e,t.tauceti.overseer.working=l+p+_,t.tauceti.overseer.injured=r,t.tauceti.overseer.prod=o}["inspired","distracted","stimulated","motivated"].forEach((function(e){t.race[e]&&(t.race[e]--,t.race[e]<=0&&delete t.race[e])}));let de=t.resource[t.race.species].amount-a[t.race.species];if(de>0&&(t.race.orbit_decayed&&t.stats.days===t.race.orbit_decay?Di(F("tragic_death",[de]),"danger"):(Di(F(1===de?"abandon1":"abandon2",[de]),"danger"),t.civic.homeless+=de)),i.world_controller){let e=.25;t.interstellar.far_reach&&i.far_reach>0&&(e+=.01*i.far_reach),t.tech.science>=19&&(e+=.15);let r=Math.round(a.Knowledge*e);a.Knowledge+=r,f[F("space_dwarf_collider_title")]=r+"v"}if(i.alien_outpost){let e=0;t.tech.isolation&&(e=t.race.lone_survivor?35e5:65e5,a.Knowledge+=e);let r=.2,s=Math.round(a.Knowledge*r);a.Knowledge+=s,f[F("tech_alien_outpost")]=s+e+"v"}let _e=a.Crates,pe=a.Containers;if(Object.keys(a).forEach((function(e){a.Crates-=t.resource[e].crates})),Object.keys(a).forEach((function(e){a.Containers-=t.resource[e].containers})),a.Crates<0){let e=0-a.Crates;Object.keys(a).forEach((function(r){if(e>0){let s=t.resource[r].crates;s>e&&(s=e),a.Crates+=s,t.resource[r].crates-=s,e-=s}}))}if(a.Containers<0){let e=0-a.Containers;Object.keys(a).forEach((function(r){if(e>0){let s=t.resource[r].containers;s>e&&(s=e),a.Containers+=s,t.resource[r].containers-=s,e-=s}}))}y[F("crates_used")]=a.Crates-_e+"v",b[F("crates_used")]=a.Containers-pe+"v";let he=Or(),me=Cr();Object.keys(a).forEach((function(e){let s=t.resource[e].crates*he;a[e]+=s;let i=t.resource[e].containers*me;a[e]+=i,r.c[e]&&(r.c[e][F("resource_Crates_plural")]=s+"v",r.c[e][F("resource_Containers_plural")]=i+"v"),t.resource[e].max=a[e],t.resource[e].amount>t.resource[e].max&&"Sus"!=e?t.resource[e].amount=t.resource[e].max:t.resource[e].amount<0&&(t.resource[e].amount=0),t.resource[e].amount>=.99*t.resource[e].max?$(`#res${e} .count`).hasClass("has-text-warning")||$(`#res${e} .count`).addClass("has-text-warning"):$(`#res${e} .count`).hasClass("has-text-warning")&&$(`#res${e} .count`).removeClass("has-text-warning")}));let ge=!1,fe=0,ve=0;if(Object.keys(s).forEach((function(e){-1===t.civic[e].max&&t.civic[e].display&&"unemployed"!==e&&"scavenger"!==e&&ve++})),Object.keys(s).forEach((function(e){t.civic[e].max=s[e],t.civic[e].workers>t.civic[e].max&&-1!==t.civic[e].max?t.civic[e].workers=t.civic[e].max:t.civic[e].workers<0&&(t.civic[e].workers=0),t.race.servants&&(-1!==t.civic[e].max||t.race.servants.jobs.hasOwnProperty(e)||(t.race.servants.jobs[e]=0,ge=!0),t.race.servants.jobs.hasOwnProperty(e)&&(!t.civic[e].display&&("scavenger"!==e||ve>0)?t.race.servants.jobs[e]=0:fe+=t.race.servants.jobs[e],fe>t.race.servants.max&&t.race.servants.jobs[e]>0&&(t.race.servants.jobs[e]--,fe--)))})),ge?_a():t.race.servants&&(t.race.servants.force_scavenger=0===ve,t.race.servants.used=fe),t.race.servants&&t.race.servants.hasOwnProperty("smax")&&t.race.servants.smax>0){let e=0;Object.keys(t.race.servants.sjobs).forEach((function(a){t.resource[a].display||(t.race.servants.sjobs[a]=0),e+=t.race.servants.sjobs[a],e>t.race.servants.smax&&(t.race.servants.sjobs[a]-=e-t.race.servants.smax),t.race.servants.sjobs[a]<0&&(t.race.servants.sjobs[a]=0)})),t.race.servants.sused=e}if(t.civic.space_miner.display&&t.space.space_station&&(t.space.space_station.s_max=na(t.civic.space_miner.workers,"space_miner")),t.portal.hasOwnProperty("transport")){let e=0;n.transport&&(e=5*n.transport),t.portal.transport.cargo.max=e}if(t.portal.hasOwnProperty("purifier")){let e=100,a=1e4;l.base_camp&&(a*=1+.4*l.base_camp),l.port&&(e+=l.port*a),t.portal.purifier.sup_max=Math.round(e)}let ye=t.race.truepath?5:3,be=t.race.blurry?2:0,we=Pi("yeti");we>=.25&&(be+=we>=.5?2:1);for(let a=0;a0&&(t.civic.foreign[`gov${a}`].trn--,0===t.civic.foreign[`gov${a}`].trn&&t.civic.foreign[`gov${a}`].spy++),t.civic.foreign[`gov${a}`].sab>0&&(t.civic.foreign[`gov${a}`].sab--,0===t.civic.foreign[`gov${a}`].sab))switch(t.civic.foreign[`gov${a}`].act){case"influence":if(0===Math.floor(m(0,4+be)))jo(a);else{let r=Math.floor(m(t.tech.spy>=5?2:1,t.tech.spy>=5?8:6));"scorpio"===e&&(r+=H("scorpio")[1]),t.civic.foreign[`gov${a}`].hstl-=r,t.civic.foreign[`gov${a}`].hstl<0&&(t.civic.foreign[`gov${a}`].hstl=0),Di(F("civics_spy_influence_success",[ee(a),r]),"success",!1,["spy"])}break;case"sabotage":if(0===Math.floor(m(0,3+be)))jo(a);else{let r=Math.floor(m(t.tech.spy>=5?2:1,t.tech.spy>=5?8:6));"scorpio"===e&&(r+=H("scorpio")[1]),t.civic.foreign[`gov${a}`].mil-=r,t.civic.foreign[`gov${a}`].mil<50&&(t.civic.foreign[`gov${a}`].mil=50),Di(F("civics_spy_sabotage_success",[ee(a),r]),"success",!1,["spy"])}break;case"incite":if(0===Math.floor(m(0,2+Math.floor(be/2))))jo(a);else{let r=Math.floor(m(t.tech.spy>=5?2:1,t.tech.spy>=5?8:6));"scorpio"===e&&(r+=H("scorpio")[1]),t.civic.foreign[`gov${a}`].unrest+=r,t.civic.foreign[`gov${a}`].unrest>100&&(t.civic.foreign[`gov${a}`].unrest=100),Di(F("civics_spy_incite_success",[ee(a),r]),"success",!1,["spy"])}break;case"annex":if(a>=3)break;let r=!t.tech.gov_fed&&!ue();t.civic.foreign[`gov${a}`].anx=!0,Di(F("civics_spy_annex_success",[ee(a)]),"success",!1,["spy"]),r&&ms();break;case"purchase":if(a>=3)break;let s=!t.tech.gov_fed&&!ue();t.civic.foreign[`gov${a}`].buy=!0,Di(F("civics_spy_purchase_success",[ee(a)]),"success",!1,["spy"]),s&&ms()}if(t.race.banana){let e=!1,a=0;if(Object.keys(t.resource).forEach((function(r){t.resource[r].hasOwnProperty("trade")&&t.resource[r].trade<0&&(e?t.resource[r].trade=0:e=r),t.resource[r].hasOwnProperty("trade")&&t.resource[r].trade>0&&(a+=t.resource[r].trade)})),t.resource[e]&&t.resource[e].trade<=-500){let e=Yc();t.stats.banana.b4[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b4.l=!0),a>=500&&eo("banana")}}if(t.galaxy.defense){let e=["dreadnought","cruiser_ship","frigate_ship","corvette_ship","scout_ship"];for(let a=0;an[e[a]]){let i=r-n[e[a]];t.galaxy.defense[s][e[a]]-=i}t.galaxy.defense[s][e[a]]<0&&(t.galaxy.defense[s][e[a]]=0)}})),r=2&&$e.push("slave_market"),$e.forEach((function(e){if(Qr.city[e]&&Qr.city[e].cost){let a=Qr.city[e],r=$("#"+a.id);if(Cs(a)?r.hasClass("cna")&&r.removeClass("cna"):r.hasClass("cna")||r.addClass("cna"),Cs(a,!0)?r.hasClass("cnam")&&r.removeClass("cnam"):r.hasClass("cnam")||r.addClass("cnam"),t.city[e]){let r=tc(a,!1,!0);t.city[e].time=ic(r.t),t.city[e].bn=r.r}}})),Object.keys(Qr.tech).forEach((function(e){if(Qr.tech[e]&&Qr.tech[e].cost){let t=Qr.tech[e],a=$("#"+t.id);a.length>0&&(Cs(t)?a.hasClass("cna")&&a.removeClass("cna"):a.hasClass("cna")||a.addClass("cna"),Cs(t,!0)?a.hasClass("cnam")&&a.removeClass("cnam"):a.hasClass("cnam")||a.addClass("cnam"))}}));let xe=["space","interstellar","galaxy","portal","tauceti"];for(let e=0;e0&&t.city.ptrait.includes("toxic")&&(e+=Si.toxic.vars()[0]),t.arpa.sequence.labs=e,t.arpa.sequence.time-=t.arpa.sequence.boost?2*e:e,t.arpa.sequence.progress=t.arpa.sequence.max-t.arpa.sequence.time,t.arpa.sequence.time<=0){if(t.arpa.sequence.max=5e4*(1+t.race.mutation**2),t.race.adaptable){let e=1-ui.adaptable.vars()[0]/100;t.arpa.sequence.max=Math.floor(t.arpa.sequence.max*e)}if(t.arpa.sequence.progress=0,t.arpa.sequence.time=t.arpa.sequence.max,2===t.tech.genetics)Di(F("genome",[Ac("name")]),"success",!1,["progress"]),t.tech.genetics=3;else{t.race.mutation++;let e=hi(1),a=1+(t.genes.synthesis?t.genes.synthesis:0),r=2**(t.race.mutation-1)*a;t.stats.achieve.creator&&(r=Math.round(r*(1+.5*t.stats.achieve.creator.l))),t.resource.Genes.amount+=r,t.resource.Genes.display=!0;let s=t.genes.plasma?t.race.mutation:1;t.genes.plasma&&s>3&&(s=t.genes.plasma>=2?s>5?5:s:3);let i=s>1?"_plural":"";"antimatter"===t.race.universe?(i=F("resource_AntiPlasmid"+i+"_name"),t.stats.antiplasmid+=s,t.prestige.AntiPlasmid.count+=s,Xc("cross")):(i=F("resource_Plasmid"+i+"_name"),t.stats.plasmid+=s,t.prestige.Plasmid.count+=s),Oe("Crispr"),Di(F("gene_therapy",[F("trait_"+e+"_name"),r,s,i]),"success",!1,["progress"])}Oe("Genetics"),ms()}}if(t.city.foundry){let e=t.civic.craftsman.workers;(t.race.kindling_kindred||t.race.smoldering)&&t.city.foundry.Plywood>0&&(t.civic.craftsman.workers-=t.city.foundry.Plywood,t.city.foundry.crafting-=t.city.foundry.Plywood,t.city.foundry.Plywood=0);let a=Ya();Object.keys(a).forEach((function(a){for(;t.city.foundry[a]>e&&t.city.foundry[a]>0;)t.city.foundry[a]--,t.city.foundry.crafting--;e-=t.city.foundry[a]}))}3===t.tech.foundry&&(t.race.kindling_kindred||t.race.smoldering)&&(t.tech.foundry=4,ms()),(t.race.kindling_kindred||t.race.smoldering)&&(t.civic.lumberjack.workers=0,t.resource.Lumber.crates=0,t.resource.Lumber.containers=0,t.resource.Lumber.trade=0),(t.race.kindling_kindred||t.race.smoldering)&&t.city.foundry&&t.city.foundry.Plywood&&(t.city.foundry.Plywood=0),Tc("fool",2023)&&!t.race.hooved?t.resource.Horseshoe.display=!0:t.race.hooved||(t.resource.Horseshoe.display=!1),Po(!1);let ke=c.iron_ship+c.iridium_ship;if(ke>0&&t.tech.asteroid&&3===t.tech.asteroid&&Math.rand(0,250)<=ke&&(t.tech.asteroid=4,t.resource.Elerium.display=!0,Vi("Elerium",1),ms(),Di(F("discover_elerium"),"info",!1,["progress"])),t.tech.asteroid&&4===t.tech.asteroid&&0===t.resource.Elerium.amount&&Vi("Elerium",1),i.outpost>0&&t.tech.gas_moon&&1===t.tech.gas_moon&&Math.rand(0,100)<=i.outpost&&(t.space.oil_extractor={count:0,on:0},t.tech.gas_moon=2,Di(F("discover_oil",[Xt().gas_moon]),"info",!1,["progress"]),Rt()),t.portal.hasOwnProperty("mechbay")&&t.tech.hell_spire&&t.tech.hell_spire>=9){t.portal.spire.boss||Ta(),Aa();let e=0;for(let a=0;a=2&&t.portal.waygate.progress<100?e+=Ba(r,!0):e+=Ba(r,!1)}if(t.portal.hasOwnProperty("waygate")&&t.tech.hasOwnProperty("waygate")&&1===t.portal.waygate.on&&t.tech.waygate>=2&&t.portal.waygate.progress<100?(t.portal.waygate.progress+=e,t.portal.waygate.time=ic(0===e?-1:(100-t.portal.waygate.progress)/e),t.portal.spire.time=ic(-1)):(t.portal.spire.progress+=e,t.portal.spire.time=ic(0===e?-1:(100-t.portal.spire.progress)/e),t.tech.waygate&&t.tech.waygate>=2&&(t.portal.waygate.time=ic(-1))),t.portal.hasOwnProperty("waygate")&&1===t.portal.waygate.on&&t.portal.waygate.progress>=100&&(t.portal.waygate.progress=100,t.portal.waygate.on=0,t.tech.waygate=3,t.resource.Demonic_Essence.display=!0,t.resource.Demonic_Essence.amount=1,ms()),t.portal.spire.progress>=100){t.portal.spire.progress=0;let e=Number(ro()),a=e;t.genes.blood&&t.genes.blood>=2&&(a*=2),t.prestige.Blood_Stone.count+=a,t.stats.blood+=a,Oe("Blood"),t.tech.hasOwnProperty("b_stone")||(t.tech.b_stone=1,ms()),Di(`${F("portal_spire_conquest",[F(`portal_mech_boss_${t.portal.spire.boss}`),t.portal.spire.count])} ${F(1===a?"portal_spire_conquest_stone":"portal_spire_conquest_stones",[a])}`,"info",!1,["progress","hell"]),t.portal.spire.count++,t.portal.spire.count>10&&(t.tech.hell_spire=10,ms());let r=Yc();t.stats.spire.hasOwnProperty(r)||(t.stats.spire[r]={s0:0,s1:0,s2:0,s3:0,s4:0}),t.portal.spire.count>t.stats.spire[r]["s"+(e-1)]&&(t.stats.spire[r]["s"+(e-1)]=t.portal.spire.count),(!t.stats.spire[r].hasOwnProperty(t.portal.spire.boss)||e>t.stats.spire[r][t.portal.spire.boss])&&(t.stats.spire[r][t.portal.spire.boss]=e),Ta(),$a()}}if(t.race.cannibalize&&t.city.s_alter&&(t.city.s_alter.rage>0&&t.city.s_alter.rage--,t.city.s_alter.regen>0&&t.city.s_alter.regen--,t.city.s_alter.mind>0&&t.city.s_alter.mind--,t.city.s_alter.mine>0&&t.city.s_alter.mine--,t.city.s_alter.harvest>0&&t.city.s_alter.harvest--,$('#popper[data-id="city-s_alter"]').length>0&&Ps(Qr.city.s_alter,"city","s_alter")),t.race.casting){let e=0;["farmer","miner","lumberjack","science","factory","army","hunting","crafting"].forEach((function(a){t.race.casting[a]&&(e+=t.race.casting[a])})),t.race.casting.total=e}if(t.tech.r_queue&&t.r_queue.display){let e=-1,a=!1,r=!1,s=0,i=0,c={t:{t:0,rt:0},r:{},rr:{},id:{}};for(let o=0;o=l.grant[1]){t.r_queue.queue.splice(o,1),Ei(`rq${a.id}`);break}if(Cs(l,!0)){t.r_queue.queue[o].cna=!1;let u=us(n.type,!1),d=t.settings.qAny_res?tc(l):tc(l,c,!1,u);d>=0?(!r&&Cs(l)&&u?(a=l,e=o,t.settings.qAny_res&&(r=!0)):(u&&(s+=d),i+=d),!t.settings.qAny_res&&u&&(r=!0),t.r_queue.queue[o].time=u?s:i):t.r_queue.queue[o].time=d,t.r_queue.queue[o].req=!!u}else t.r_queue.queue[o].cna=!0,t.r_queue.queue[o].time=-1;t.r_queue.queue[o].qa=!!t.settings.qAny_res}e>=0&&a&&!t.r_queue.pause&&a.action()&&(Di(F("research_success",[t.r_queue.queue[e].label]),"success",!1,["queue","research_queue"]),ps(t.r_queue.queue[e].type),a.post&&a.post(),t.r_queue.queue.splice(e,1),Ei(`rq${a.id}`),Bs()),t.r_queue.queue.length>t.r_queue.max&&t.r_queue.queue.splice(t.r_queue.max);let o={},n=[];us("club",o);for(let e=0;e0)for(let e=n.length-1;e>=0;e--)t.r_queue.queue.splice(n[e],1)}t.arpa.sequence&&t.arpa.sequence.auto&&t.tech.genetics&&t.tech.genetics>=8&&Mo(),i.soul_forge&&sc({el:"#fort"},"update"),so()}if(t.tech.queue&&t.queue.display){let e=-1,a=!1,r=!1,s=["space","interstellar","galaxy","portal","tauceti"],i=0,c={t:{t:0,rt:0},r:{},rr:{},id:{}},o=!1;for(let n=0;n=0){i+=s,l.time=i;for(let e=1;e=0&&(t.settings.qAny&&!t.queue.pause&&l.time>1?He(l.type,100,!0):r||(a=u,e=n,o=!0,r=!0))}else if(Cs(u,!0)){l.cna=!1;let s=tc(u,c);if(l.bres=!1,s>=0){!r&&Cs(u)?(a=u,e=n,o=!1,t.settings.qAny&&(r=!0)):i+=s,t.settings.qAny||(r=!0),l.time=i;let d=!1;for(let e=1;e=0&&a&&!t.queue.pause){let r=!1;if(o){let r=t.queue.queue[e].label;He(t.queue.queue[e].type,100,!0,!0)&&(Di(F("build_success",[r]),"success",!1,["queue","building_queue"]),t.queue.queue[e].q>1?t.queue.queue[e].q--:(Ei(`q${a.id}${e}`),t.queue.queue.splice(e,1),Ui()))}else{let s=t.queue.queue[e].q,i=t.queue.queue[e],c=a.queue_complete?a.queue_complete():1;for(let i=0;i1?t.queue.queue[e].q--:(Ei(`q${a.id}${e}`),t.queue.queue.splice(e,1),Ui()),t.race.inflation&&t.tech.primitive&&(a.hasOwnProperty("inflation")&&!a.inflation||t.race.inflation++);r&&ys(a,i.action,i.type)}}let n=!1,l=0,u=[],d=!1;for(let e=0;et.queue.max){let a=Math.ceil(t.queue.queue[e].q/t.queue.queue[e].qs)-(l-t.queue.max);0===a?t.queue.queue.splice(e):(t.queue.queue[e].q=a*t.queue.queue[e].qs,t.queue.queue.splice(e+1))}if("merge_nearby"===t.settings.q_merge){if(n===t.queue.queue[e].id){Ei(`q${t.queue.queue[e].id}${e}`),t.queue.queue[e-1].q+=t.queue.queue[e].q,t.queue.queue.splice(e,1),Ui();break}n=t.queue.queue[e].id}else if("merge_all"===t.settings.q_merge){let a=!1;for(let r=0;r=0&&a>t.resource[r].max,i=e.attr("data-ok")?e.attr("data-ok"):"has-text-dark";t.resource[r].amount+t.resource[r].diffi&&(a-=i-e),e=i),ac&&(e-=e+a-c,ec&&(a-=e+a-c,a0&&$("#mechList").css("height",`calc(100vh - 11.5rem - ${$("#mechAssembly").height()}px)`),$("#shipList").length>0&&$("#shipList").css("height",`calc(100vh - 11.5rem - ${$("#shipPlans").height()}px)`)}();break;case"long":!function(){const a=new Date,r=U();if("protoplasm"!==t.race.species){let a=ai(),s=!1;if(Object.keys(a).forEach((function(e){a[e].l.forEach((function(t){let r=t.split(":"),i=Tt(r[0]),c="city"===r[0]?r[0]:i,o="city"===r[0]?Qr.city[r[1]]:Qr[i][r[0]][r[1]],n=$(`#pg${o.id}${e}`);a[e].s&&(0===n.length||ei(o,c,r[0],r[1])&&n.hasClass("inactive"))&&(s=!0)}))})),s&&ti(),t.tech.syphon&&t.tech.syphon>=80){M.w&&M.w.terminate();let a=$('
        ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),125),setTimeout((function(){a.addClass("b")}),150),setTimeout((function(){a.addClass("c")}),2e3),setTimeout((function(){!function(){if(t.tech.syphon>=80&&"magic"===t.race.universe){t.tech.syphon=79,t.arpa.syphon.rank=79,t.arpa.syphon.complete=99,t.queue.queue=[],t.stats.current=Date.now(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"vacuum"}),Xc(`extinct_${t.race.species}`),Xc("pw_apocalypse"),t.space.hasOwnProperty("spaceport")&&0===t.space.spaceport.count&&Xc("red_dead"),t.race.modified||"balorg"!==t.race.species||Xc("pass"),t.race.junker&&"junker"===t.race.species&&eo("the_misery"),t.race.decay&&Xc("dissipated"),t.race.steelen&&eo("steelem");let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=mc("vacuum");so(),t.stats.blackhole++,Fc(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),t.prestige.Dark.count=+(t.prestige.Dark.count+o.dark).toFixed(3),t.stats.dark=+(t.stats.dark+o.dark).toFixed(3),t.stats.universes++;let n=!!t.race.hasOwnProperty("srace")&&t.race.srace,l=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:"bigbang",seeded:!0,bigbang:!0,probes:4,seed:Math.floor(m(1e4)),ascended:!1},l>0&&(t.race.corruption=l),n&&(t.race.srace=n),Q({orbit:s,biome:i,ptrait:c,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}}()}),4e3)}if(t.portal.fortress&&function(){let e={start:t.portal.fortress.threat,foundGem:!1,stats:{wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}}},a=t.tech.armor?t.tech.armor:0;t.race.armored&&(a+=ui.armored.vars()[1]);let r=Pi("tortoisan");r>0&&(a+=Math.floor(ui.armored.vars(1)[1]*r)),t.race.scales&&(a+=ui.scales.vars()[2]);let s=!1;if(i.soul_forge){let e=t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size;ba()<=e?(s=!0,$("#portal-soul_forge .on").removeClass("altwarn")):(s=!1,$("#portal-soul_forge .on").addClass("altwarn"))}else $("#portal-soul_forge .on").addClass("altwarn");let c=0;if(t.tech.portal>=3&&i.war_drone){e.drones={};for(let a=0;a=Math.rand(0,999)){let a=Math.rand(Math.floor(t.portal.fortress.threat/50),Math.floor(t.portal.fortress.threat/10)),i=t.tech.portal>=7?Math.rand(50,125):Math.rand(25,75);a=5?9e3:1e4)-t.portal.fortress.pity;if("evil"===t.race.universe&&t.prestige.Dark.count>1){let e=t.prestige.Dark.count;t.prestige.Harmony.count>0&&(e*=1+.01*t.prestige.Harmony.count),o-=Math.round(2*Math.log2(e))}t.tech.portal>=4&&i.attractor&&(o=Math.round(o*.948**i.attractor)),t.race.ghostly&&(o=Math.round(o*((100-ui.ghostly.vars()[2])/100)));let n=Pi("wendigo");n>0&&(o=Math.round(o*((100-ui.ghostly.vars(1)[2])/100*n))),o<12&&(o=12);let l=0,u=i.war_droid?i.war_droid:0,p=!1,h=0;t.civic.garrison.wounded>t.civic.garrison.workers-t.portal.fortress.garrison&&(h=t.civic.garrison.wounded-(t.civic.garrison.workers-t.portal.fortress.garrison),h>t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size?(h-=t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size,h/=t.portal.fortress.patrols):h=0);let m=+(h%1).toFixed(10);e.patrols={};for(let r=0;r1/t.portal.fortress.patrols*r?Math.ceil(h):Math.floor(h);if(Math.rand(0,t.portal.fortress.threat)>=Math.rand(0,999)){c.encounter=!0;let r=t.portal.fortress.patrol_size;u>0&&(c.droid=!0,r+=t.tech.hdroid?la(2):la(1),u--);let d=Math.round(ke(r,"hellArmy",n)),_=Math.rand(Math.floor(t.portal.fortress.threat/50),Math.floor(t.portal.fortress.threat/10));t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.rand(0,Math.ceil(_/10)),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0]));let h=30+Math.max(t.race.chameleon?ui.chameleon.vars()[1]:0,t.race.elusive?ui.elusive.vars()[0]:0);if(0===Math.rand(0,h)){c.ambush=!0,l+=Ma(Math.round(_*(1+3*Math.random())),0,!0,c);let e=Math.round(d/2);_0){let a=35-Math.floor(i.attractor/3);a<5&&(a=5);let s=Math.round(r/a);for(let a=0;at.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers);let f=t.portal.fortress.nocrew?t.civic.garrison.workers-t.civic.garrison.crew:t.civic.garrison.workers;if(f0&&"Yes"===t.portal.fortress.notify&&Di(g>0?F("fortress_patrol_casualties_revive",[l,g]):F("fortress_patrol_casualties",[l]),!1,!1,["hell"]),t.portal.fortress.garrison>0&&t.portal.fortress.siege>0&&t.portal.fortress.siege--,t.portal.fortress.siege<=900&&t.portal.fortress.garrison>0&&1>Math.rand(0,t.portal.fortress.siege)){let a={destroyed:!1,damage:0,kills:0,surveyors:0,soldiers:0},r=qa(t.portal.fortress.garrison),i=r/35>1?r/35:1,c=Math.round(t.portal.fortress.threat/2),o=0,n=0,l=!1;for(;c>0&&t.portal.fortress.walls>0;){let e=Math.round(Math.rand(1,i+1));if(e>c&&(e=c),c-=e,t.portal.fortress.threat-=e,t.stats.dkills+=e,s&&(t.portal.soul_forge.kills+=e,Pa(e)),n+=e,c>0&&(o++,t.portal.fortress.walls--,0===t.portal.fortress.walls)){a.destroyed=!0,l=!0;break}}a.damage=o,a.kills=n,e.stats.kills.sieges=n,l?(Di(F("fortress_lost"),!1,!1,["hell"]),a.surveyors=t.civic.hell_surveyor.workers,t.resource[t.race.species].amount-=t.civic.hell_surveyor.workers,t.civic.hell_surveyor.workers=0,t.civic.hell_surveyor.assigned=0,a.soldiers=t.portal.fortress.garrison,e.stats.died+=t.portal.fortress.garrison,t.portal.fortress.patrols=0,t.stats.died+=t.portal.fortress.garrison,t.civic.garrison.workers-=t.portal.fortress.garrison,t.portal.fortress.garrison=0,t.portal.fortress.assigned=0):Di(F("fortress_sieged",[n,o]),!1,!1,["hell"]),t.portal.fortress.siege=999,e.stats.sieges++,e.siege=a}if(t.portal.fortress.threat<1e4){let a=(1e4-t.portal.fortress.threat)/2500+1;t.tech.portal>=4&&i.attractor&&(a*=1+.22*i.attractor);let r=Math.rand(Math.round(10*a),Math.round(50*a));t.portal.fortress.threat+=r,e.demons=r}if(t.civic.hell_surveyor.display&&t.civic.hell_surveyor.workers>0){let a=1e3,r=N("nopain",1);r&&(a*=1+r/100),t.race.blurry&&(a*=1+ui.blurry.vars()[0]/100);let s=Pi("yeti");s>0&&(a*=1+ui.blurry.vars(1)[0]/100*s),t.race.instinct&&(a*=1+ui.instinct.vars()[0]/100),t.tech.infernite&&t.tech.infernite>=5&&(a+=250);let n=t.portal.fortress.threat/a,l=t.civic.hell_surveyor.workers>10?10:t.civic.hell_surveyor.workers;if(n>10-Math.rand(0,l+1)){let a=Math.round(n),r=Math.rand(0,a+1);r>t.civic.hell_surveyor.workers&&(r=t.civic.hell_surveyor.workers),1===r&&"Yes"===t.portal.fortress.s_ntfy?Di(F("fortress_killed"),!1,!1,["hell"]):r>1&&"Yes"===t.portal.fortress.s_ntfy&&Di(F("fortress_eviscerated",[r]),!1,!1,["hell"]),r>0&&(e.surveyors=r,e.stats.surveyors=r,t.civic.hell_surveyor.workers-=r,t.civic.hell_surveyor.max-=r,t.resource[t.race.species].amount-=r,t.portal.carport.damaged+=r)}if(e.surveyor_finds={},t.civic.hell_surveyor.workers>0&&c>0)for(let a=0;a100&&(s=100),r.bodies=s,s>0){let a=25-Math.floor(i.attractor/5);a<5&&(a=5);let c=Math.round(s/a);for(let a=0;a=1e6&&t.tech.gateway&&!t.tech.hell_pit&&(t.tech.hell_pit=1,t.settings.portal.pit=!0,Di(F("portal_hell_pit_found"),"info",!1,["progress","hell"]),$a()),t.tech.hell_pit){if(s&&t.tech.hell_pit>=5&&i.soul_attractor){let a=t.blood.attract?5*t.blood.attract:0,r=i.soul_attractor*Math.rand(40+a,120+a);t.portal.soul_forge.kills+=r,e.soul_attractors=r,Pa(r)}if(s&&t.tech.hell_gun&&i.gun_emplacement){e.gun_emplacements={};let a=0;for(let r=0;r=2?Math.rand(35,75):Math.rand(20,40);a+=s,e.gun_emplacements[r+1].kills=s}e.stats.kills.guns=a,t.portal.soul_forge.kills+=a,Pa(a),t.stats.dkills+=a;let r=t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=5?6750:7500;t.tech.hell_pit>=7&&i.soul_attractor>0&&(r*=.94**i.soul_attractor);for(let a=0;a=5?4500:5e3;0===Math.rand(0,r)&&(e.soul_forge.gem=!0,e.stats.gems.soul_forge++,t.resource.Soul_Gem.amount++)}let a=t.tech.hell_pit>=6?75e4:1e6;if(t.tech.hell_pit>=7&&i.soul_attractor>0&&(a*=.97**i.soul_attractor),s&&t.portal.soul_forge.kills>=Math.round(a)){e.soul_forge.gem_craft=!0,t.portal.soul_forge.kills=0;let a=10-i.soul_attractor>0?10-i.soul_attractor:1;t.tech.high_tech>=16&&!t.tech.corrupt&&0===Math.rand(0,a+1)?(e.soul_forge.corrupt=!0,t.resource.Corrupt_Gem.amount++,t.resource.Corrupt_Gem.display=!0,Di(F("portal_corrupt_gem"),"info",!1,["progress","hell"]),t.tech.corrupt=1,ms()):(t.resource.Soul_Gem.amount++,e.stats.gems.crafted++)}}if(t.tech.hell_gate&&t.tech.hell_gate>=3&&s&&i.gate_turret){e.gate_turrets={};let a=0,r=t.tech.hell_gun>=2?65:40,s=t.tech.hell_gun>=2?100:60;for(let t=0;t=5?2700:3e3;for(let a=0;a0&&t.civic.govern.rev--,t.civic.govern.fr>0&&t.civic.govern.fr--,t.civic.govern.rev<0&&(t.civic.govern.rev=0),t.city.ptrait.includes("trashed")||t.race.scavenger?t.civic.scavenger.display=!0:(t.civic.scavenger.display=!1,t.civic.scavenger.workers=0),t.civic.homeless>0){let e=t.arpa.railway?t.arpa.railway.rank:0,a=Math.floor(e/(e+25)*10);Math.rand(0,10)<=a&&t.civic.homeless--}if(t.tech.currency&&t.tech.currency>=2){let e=N("risktaker",0)?2:4;Object.keys(Qa).forEach((function(a){let r=t.race.truepath?2*Qa[a]:Qa[a];if("Copper"===a&&t.tech.high_tech&&t.tech.high_tech>=2&&(r*=2),"Titanium"===a&&(t.tech.titanium&&t.tech.titanium>0?r*=t.resource.Alloy.display?1:2.5:r*=5),t.resource[a].display&&0===Math.rand(0,e)){let e=3*r,s=r/2,i=(Math.rand(0,200)-100)/100,c=t.resource[a].value+i;ce&&(c=e-r),t.resource[a].value=c}}))}if(t.race.blood_thirst&&(t.race.hasOwnProperty("blood_thirst_count")||(t.race.blood_thirst_count=1),t.race.blood_thirst_count>1&&t.race.blood_thirst_count--),t.race.truepath&&t.civic.foreign.gov3.mil<500&&0===Math.rand(0,50)&&t.civic.foreign.gov3.mil++,t.civic.garrison.wounded>0){let e=t.race.regenerative?ui.regenerative.vars()[0]:1,a=t.city.hospital?t.city.hospital.count:0;if(t.race.orbit_decayed&&t.race.truepath?a=Math.min(c.operating_base,i.operating_base):t.race.artifical&&t.city.boot_camp&&(a=t.city.boot_camp.count),t.race.rejuvenated&&t.stats.achieve.lamentis){let e=t.stats.achieve.lamentis.l;e>5&&(e=5),a+=e}"cancer"===r&&(a+=H("cancer")[0]),t.tech.medic&&t.tech.medic>=2&&(a*=t.tech.medic),t.race.fibroblast&&(a+=ui.fibroblast.vars()[0]*t.race.fibroblast),t.race.cannibalize&&t.city.s_alter&&t.city.s_alter.regen>0&&(a>=20?a*=1+ui.cannibalize.vars()[0]/100:a+=Math.floor(ui.cannibalize.vars()[0]/5));let s=Pi("mantis");s>0&&(a>=20?a*=1+ui.cannibalize.vars(1)[0]/100*s:a+=Math.floor(ui.cannibalize.vars(1)[0]/5*s)),t.race.high_pop&&(a*=ui.high_pop.vars()[2]);let o=N("nopain",0);o&&(a*=1+o/100);let n=Pi("troll");n>0&&(a+=Math.round(20*ui.regenerative.vars(1)[0]*n));let l=20;if(t.race.slow_regen&&(l*=1+ui.slow_regen.vars()[0]/100),a=Math.round(a),a>0){for(;a>=l;)e++,a-=l;Math.rand(0,a)>Math.rand(0,l)&&e++}t.civic.garrison.wounded-=e,t.civic.garrison.wounded<0&&(t.civic.garrison.wounded=0)}t.civic.garrison.fatigue&&t.civic.garrison.fatigue>0&&t.civic.garrison.fatigue--,t.civic.garrison.protest&&t.civic.garrison.protest>0&&t.civic.garrison.protest--;let o=t.tech.mercs&&t.tech.mercs>=2?3:4;if(t.civic.garrison.m_use&&t.civic.garrison.m_use>0&&0===Math.rand(0,o)&&t.civic.garrison.m_use--,t.race.rainbow_active&&t.race.rainbow_active>1&&t.race.rainbow_active--,t.city.calendar.day>0){if(t.city.calendar.day++,t.stats.days++,t.city.calendar.day>t.city.calendar.orbit&&(t.city.calendar.day=1,t.city.calendar.year++),t.race.cataclysm||t.race.orbit_decayed)t.city.calendar.season=-1;else{let e=t.city.ptrait.includes("elliptical")?6:4,a=Math.round(t.city.calendar.orbit/e),r=t.city.calendar.day,s=0;for(;r>a;)r-=a,s++;if(t.city.ptrait.includes("elliptical"))switch(s){case 0:t.city.calendar.season=0;break;case 1:case 2:t.city.calendar.season=1;break;case 3:t.city.calendar.season=2;break;default:t.city.calendar.season=3}else t.city.calendar.season=s}if(t.race.cataclysm||t.race.orbit_decayed)t.city.calendar.wind=0,t.city.calendar.temp=1,t.city.calendar.weather=-1;else if(0===Math.rand(0,5)){let e=Math.rand(0,3),a=Math.rand(0,5),r=Math.rand(0,3);switch(t.city.biome){case"oceanic":case"swamp":0===Math.rand(0,2)&&a>0&&a--;break;case"tundra":case"taiga":3===t.city.calendar.season?e=0:0===Math.rand(0,2)&&e>0&&e--;break;case"desert":0===Math.rand(0,2)&&a<4&&a++;break;case"ashland":0===Math.rand(0,2)&&(a<1?a++:a>2&&a--);case"volcanic":1===t.city.calendar.season?e=2:0===Math.rand(0,2)&&e<2&&!t.city.ptrait.includes("permafrost")&&e++}switch(t.city.calendar.season){case 0:0===Math.rand(0,3)&&a>0&&a--;break;case 1:0===Math.rand(0,3)&&e<2&&e++;break;case 2:0===Math.rand(0,3)&&r>0&&r--;break;case 3:0===Math.rand(0,3)&&e>0&&e--}if(t.city.ptrait.includes("stormy")&&r>0&&(t.race.rejuvenated||0===Math.rand(0,2))&&r--,0===a?(t.race.rainbow&&(t.race.rainbow_active=1),t.city.calendar.weather=0):a>=1&&a<=2?(t.race.rainbow&&(t.race.rainbow_active=1),t.city.calendar.weather=1):(t.race.rainbow&&0===t.city.calendar.weather&&(t.race.rainbow_active=Math.rand(10,20)),t.city.calendar.weather=2,t.race.darkness&&0===Math.rand(0,7-ui.darkness.vars()[0])&&(t.city.calendar.weather=1)),0===e){let e=t.city.calendar.temp-1;e<0&&(e=0),1===t.city.calendar.season&&0===e&&(e=1),0!==e||"hellscape"!==t.city.biome||t.city.ptrait.includes("permafrost")||(e=1),0===e&&"eden"===t.city.biome&&3!==t.city.calendar.season&&(e=1),t.city.calendar.temp=e}else if(2===e){let e=t.city.calendar.temp+1;e>2&&(e=2),3===t.city.calendar.season&&2===e&&(e=1),2===e&&"eden"===t.city.biome&&1!==t.city.calendar.season&&(e=1),t.city.calendar.temp=e}t.city.calendar.wind=0===r?1:0}2===t.city.calendar.weather?t.city.sun++:t.city.sun=0,0===t.city.calendar.temp?t.city.cold++:t.city.cold=0,2===t.city.calendar.temp?t.city.hot++:t.city.hot=0,t.race.orbit_decayed||(t.city.ptrait.includes("retrograde")?(t.city.calendar.moon--,t.city.calendar.moon<0&&(t.city.calendar.moon=27)):(t.city.calendar.moon++,t.city.calendar.moon>27&&(t.city.calendar.moon=0))),G()}if(!(t.race.cataclysm||t.race.orbit_decayed||t.race.lone_survivor||t.race.vax)){let e=Math.floor(5e7/(1+t.race.mutation))-t.stats.days;if(0===t.race.deterioration&&e<4e7){t.race.deterioration=1;let a=Math.round(e/t.city.calendar.orbit);Di(F("deterioration1",[Ac("name"),a]),"danger",!1,["progress"])}else if(1===t.race.deterioration&&e<2e7){t.race.deterioration=2;let a=Math.round(e/t.city.calendar.orbit);Di(F("deterioration2",[Ac("name"),a]),"danger",!1,["progress"])}else if(2===t.race.deterioration&&e<5e6){t.race.deterioration=3;let a=Math.round(e/t.city.calendar.orbit);Di(F("deterioration3",[Ac("name"),a]),"danger",!1,["progress"])}else if(3===t.race.deterioration&&e<1e6){t.race.deterioration=4;let a=Math.round(e/t.city.calendar.orbit);Di(F("deterioration4",[Ac("name"),a]),"danger",!1,["progress"])}else 4===t.race.deterioration&&e<=0&&(t.race.deterioration=5,t.race.decayed=t.stats.days,t.tech.decay=1,Di(F("deterioration5",[Ac("name")]),"danger",!1,["progress"]),ms())}if(t.tech.decay&&t.tech.decay>=2){let e=0;t.genes.minor.fortify&&(e+=t.genes.minor.fortify),t.race.minor.fortify&&(e+=t.race.minor.fortify),t.tech.decay>=3&&(e*=100),t.race.gene_fortify=e}else t.race.gene_fortify=0;if(!t.tech.genesis&&t.race.deterioration>=1&&t.tech.high_tech&&t.tech.high_tech>=10&&(t.tech.genesis=1,Di(F("genesis"),"special",!1,["progress"]),ms()),t.settings.cLabels&&0===$("#city-dist-outskirts").length&&hs(),!t.settings.cLabels&&$("#city-dist-outskirts").length>0&&hs(),t.tech.xeno&&t.tech.xeno>=5&&!t.tech.piracy&&0===Math.rand(0,5)&&(t.tech.piracy=1,Di(F("galaxy_piracy_msg",[di[t.galaxy.alien2.id].name]),"info",!1,["progress"]),Rt()),t.race.cheese&&(t.race.cheese--,t.race.cheese<=0&&delete t.race.cheese),t.tech.piracy&&(t.tech.piracy<1e3||t.tech.xeno>=8&&t.tech.piracy<2500||t.tech.conflict&&t.tech.piracy<5e3)&&t.tech.piracy++,t.portal.archaeology&&t.tech.hasOwnProperty("hell_ruins")&&t.tech.hell_ruins>=2&&!t.tech.hell_vault){let e=Oa("ruins"),a=25e4;t.race.high_pop&&(a=Me(a)),a=Math.round(a*e.supress)*na(t.civic.archaeologist.workers,"archaeologist")/1e3,Math.rand(0,1e4)+1<=a&&(t.tech.hell_vault=1,Di(F("portal_ruins_vault"),"info",!1,["progress"]),$a())}if(t.tech.syndicate&&t.race.truepath){let e=Dt();if(Object.keys(e).forEach((function(a){if(e[a].info.hasOwnProperty("syndicate")&&e[a].info.syndicate()){let r=e[a].info.hasOwnProperty("syndicate_cap")?e[a].info.syndicate_cap():500;t.space.syndicate.hasOwnProperty(a)||(t.space.syndicate[a]=0);let s="spc_triton"===a?5:10;t.space.syndicate[a]r&&(t.space.syndicate[a]=r)}})),t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let e=0,a=0,r=!1;t.space.shipyard.ships.forEach((function(s){if(s.transit>0&&s.fueled){s.transit--;let e=1-s.transit/s.dist,t=Math.abs(s.origin.x-s.destination.x)*e,a=Math.abs(s.origin.y-s.destination.y)*e;s.origin.x<=s.destination.x?s.xy.x=s.origin.x+t:s.xy.x=s.origin.x-t,s.origin.y<=s.destination.y?s.xy.y=s.origin.y+a:s.xy.y=s.origin.y-a}if(0===s.transit&&(s.xy=vt(s.location),s.origin=zc(s.xy),s.dist=0),s.damage>0&&i.shipyard&&s.damage--,"spc_dwarf"!==s.location&&0===Math.rand(0,10)){let e="spc_triton"===s.location?2:1;switch(s.armor){case"steel":s.damage+=Math.rand(1,8*e);break;case"alloy":s.damage+=Math.rand(1,6*e);break;case"neutronium":s.damage+=Math.rand(1,4*e)}s.damage>90&&(s.damage=90)}t.tech.hasOwnProperty("eris_scan")&&"spc_eris"===s.location&&0===s.transit&&(e+=mt(s)),t.tech.hasOwnProperty("tauceti")&&"tauceti"===s.location&&0===s.transit&&(a+=mt(s),r=s.name)})),t.tech.hasOwnProperty("eris_scan")&&t.tech.hasOwnProperty("eris")&&1===t.tech.eris&&e>50&&(t.tech.eris_scan+=e-50,t.tech.eris_scan>=100&&(t.tech.eris_scan=100,t.tech.eris=2,Di(F("space_eris_scan",[Xt().eris]),"info",!1,["progress"]),Rt())),t.tech.hasOwnProperty("tauceti")&&t.tech.tauceti>=1&&a>=1&&1===t.tech.tauceti&&(t.tauceti.orbital_station={count:0,on:0,support:0,s_max:0},t.tauceti.orbital_platform={count:0,on:0,support:0,s_max:0},t.tech.tauceti=2,t.settings.showTau=!0,t.settings.tau.home=!0,t.settings.tau.red=!0,t.settings.tau.gas=!1,t.settings.tau.roid=!1,Di(F("tau_scan",[r]),"info",!1,["progress"]),tt()),t.space.hasOwnProperty("position")&&Object.keys(gt).forEach((function(e){if(t.space.position.hasOwnProperty(e)){let a=-1===gt[e].orbit?t.city.calendar.orbit:gt[e].orbit;if(-2===a)return;0===a?t.space.position[e]=0:(t.space.position[e]+=+(360/a).toFixed(4),t.space.position[e]>=360&&(t.space.position[e]-=360))}})),$("#mapCanvas").length>0&&Mt()}t.tech.triton&&t.tech.triton>=3&&function(){if(t.space.fob){if(t.space.fob.enemy<=1e3){let e=t.tech.outer&&t.tech.outer>=4?125:100;t.space.fob.enemy+=Math.rand(25,e)}let e=Math.ceil(la(t.space.fob.enemy)/5),a=t.civic.garrison.wounded-qe();a<0&&(a=0);let r=ke(t.space.fob.troops,"army",a),s=Math.rand(0,a+1);t.civic.garrison.workers-=s,t.stats.died+=s,t.civic.garrison.wounded-=s,t.space.fob.enemy-=Math.rand(0,r),t.space.fob.enemy<0&&(t.space.fob.enemy=0);let i=Math.rand(0,t.space.fob.troops+1);if(i>e&&(i=e),t.race.armored&&(i-=la(1)),t.race.scales&&(i-=la(1)),t.tech.armor&&(i-=la(t.tech.armor)),i<0&&(i=0),t.race.revive&&s>0){let e=Math.round(Math.rand(0,s+1));t.civic.garrison.workers+=e}t.civic.garrison.wounded+=i,t.civic.garrison.wounded>qe(!1,!0)&&(t.civic.garrison.wounded=qe(!1,!0));{let e=t.civic.garrison.wounded-qe();e<0&&(e=0);let a=t.space.fob.enemy-ke(t.space.fob.troops,"army",e);a<=0&&t.space.crashed_ship.count<100?t.space.crashed_ship.count++:a>0&&t.space.crashed_ship.count>0&&t.space.crashed_ship.count--,100===t.space.crashed_ship.count&&(t.resource.Cipher.display=!0)}}}(),t.tech.eris&&t.tech.eris>=3&&function(){if(t.space.digsite){if(t.space.digsite.enemy<=1e4){let e=250;t.space.digsite.enemy+=Math.rand(25,e)}let e=ke(c.shock_trooper,"army",0);c.tank&&(e+=100*c.tank),e*=ht("spc_eris"),t.space.digsite.enemy-=Math.rand(0,e),t.space.digsite.enemy<0?t.space.digsite.enemy=0:t.space.digsite.enemy>1e4&&(t.space.digsite.enemy=1e4),t.space.digsite.count=Math.floor(100-t.space.digsite.enemy/100)}}()}if((t.stats.matrix>0||t.stats.retire>0)&&!t.race.servants&&0===Math.rand(0,25)){let e=t.stats.matrix+t.stats.retire+t.stats.eden,a=t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=5?2:0;a+=Math.min(t.stats.matrix,t.stats.retire),t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5&&ea.forEach((function(r){t.stats.achieve.overlord[r]>=5&&(a++,e+=2)})),t.race.servants={max:e,used:0,smax:a,sused:0,jobs:{},sjobs:{},force_scavenger:!1},Di(e+a===1?F("civics_servants_msg1"):F("civics_servants_msg2",[e+a]),"caution",!1,["events","major_events"])}if(t.race.truepath&&t.tech.focus_cure&&t.tech.focus_cure>=2&&t.tauceti.infectious_disease_lab)if(t.tauceti.infectious_disease_lab.cure<100){let e=(c.infectious_disease_lab||0)/100;e>1&&(e=1);let a=+Ac("curve",e).toFixed(5)/5;t.tauceti.infectious_disease_lab.cure+=a,t.tauceti.infectious_disease_lab.cure>100&&(t.tauceti.infectious_disease_lab.cure=100)}else if(t.tauceti.infectious_disease_lab.cure>=100&&2===t.tech.focus_cure)t.tech.focus_cure=3,"synthetic"===di[t.race.species].type?Di(F("tech_decode_virus_msg2s"),"info",!1,["progress"]):Di(F("tech_decode_virus_msg2"),"info",!1,["progress"]);else if(t.tech.focus_cure>=4&&t.race.hasOwnProperty("vax")){let e=t.race.artifical?t.city.boot_camp.count:t.city.hospital.count;if(t.race.orbit_decayed&&(e=Math.min(c.operating_base,i.operating_base)),4===t.tech.focus_cure&&t.race.vax<25)t.race.vax+=Math.rand(0,2*e)/150;else if(4===t.tech.focus_cure&&t.race.vax>=25)t.tech.focus_cure=5,Di(F("tech_vaccine_campaign_msg1"),"info",!1,["progress"]);else if(5===t.tech.focus_cure&&t.race.vax<50)t.race.vax+=Math.rand(0,2*e)/450;else if(5===t.tech.focus_cure&&t.race.vax<75)t.race.vax+=Math.rand(0,2*e)/1200;else if(6===t.tech.focus_cure&&t.race.vax<100){let a=1e3;t.tech.vax_p?a=250:t.tech.vax_s?a=390:t.tech.vax_f?a=25:t.tech.vax_c&&(a=125),t.race.vax+=Math.rand(0,2*e)/a}else t.race.vax>=100&&t.tech.focus_cure<=6&&(t.race.vax=100,t.tech.focus_cure=7,Di(F("tech_vaccine_campaign_msg2"),"info",!1,["progress"]),D("assemble"))}if(t.race.infiltrator){let e=t.tech.world_control?"trait_infiltrator_steal_alt":"trait_infiltrator_steal",a=ui.infiltrator.vars()[0]/100;t.resource.Knowledge.max>=Qr.tech.steel.cost.Knowledge()*a&&!t.race.steelen&&t.tech.smelting&&1===t.tech.smelting&&(Di(F(e,[F("tech_steel")]),"info",!1,["progress"]),t.resource.Steel.display=!0,t.tech.smelting=2,Ws(),ms()),t.resource.Knowledge.max>=Qr.tech.electricity.cost.Knowledge()*a&&t.tech.high_tech&&1===t.tech.high_tech&&(Di(F(e,[F("tech_electricity")]),"info",!1,["progress"]),t.tech.high_tech=2,t.city.power=0,t.city.powered=!0,t.city.coal_power={count:0,on:0},t.settings.showPowerGrid=!0,ti(),ms(),hs()),t.resource.Knowledge.max>=Qr.tech.electronics.cost.Knowledge()*a&&t.tech.high_tech&&3===t.tech.high_tech&&t.tech.titanium&&(Di(F(e,[F("tech_electronics")]),"info",!1,["progress"]),t.tech.high_tech=4,t.race.terrifying&&(t.tech.gambling=1,t.city.casino={count:0},t.space.spc_casino={count:0}),ms(),hs()),t.resource.Knowledge.max>=Qr.tech.fission.cost.Knowledge()*a&&t.tech.high_tech&&4===t.tech.high_tech&&t.tech.uranium&&(Di(F(e,[F("tech_fission")]),"info",!1,["progress"]),t.tech.high_tech=5,t.city.fission_power={count:0,on:0},ms(),hs()),t.resource.Knowledge.max>=Qr.tech.rocketry.cost.Knowledge()*a&&t.tech.high_tech&&6===t.tech.high_tech&&(Di(F(e,[F("tech_rocketry")]),"info",!1,["progress"]),t.tech.high_tech=7,t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,Di(F("civics_rival_unlocked",[ee(3)]),"info",!1,["progress","combat"])),Oe("Physics"),ms(),hs()),t.resource.Knowledge.max>=Qr.tech.artifical_intelligence.cost.Knowledge()*a&&t.tech.high_tech&&9===t.tech.high_tech&&(Di(F(e,[F("tech_artificial_intelligence")]),"info",!1,["progress"]),t.tech.high_tech=10,ms(),hs()),t.resource.Knowledge.max>=Qr.tech.quantum_computing.cost.Knowledge()*a&&t.tech.high_tech&&10===t.tech.high_tech&&t.tech.nano&&(Di(F(e,[F("tech_quantum_computing")]),"info",!1,["progress"]),t.tech.high_tech=11,ms(),hs()),t.resource.Knowledge.max>=Qr.tech[t.race.truepath?"virtual_reality_tp":"virtual_reality"].cost.Knowledge()*a&&t.tech.high_tech&&11===t.tech.high_tech&&t.tech.stanene&&(t.tech.infernite&&t.tech.alpha&&t.tech.alpha>=2||t.race.truepath)&&(Di(F(e,[F("tech_virtual_reality")]),"info",!1,["progress"]),t.tech.high_tech=12,ms(),hs()),t.race.truepath?(t.resource.Knowledge.max>=Qr.tech.quantium.cost.Knowledge()*a&&t.tech.supercollider&&t.tech.supercollider>=10&&t.tech.enceladus&&t.tech.enceladus>=3&&!t.tech.quantium&&(Di(F(e,[F("tech_quantium")]),"info",!1,["progress"]),t.tech.quantium=1,t.resource.Quantium.display=!0,ms(),ha()),t.resource.Knowledge.max>=Qr.tech.alien_biotech.cost.Knowledge()*a&&t.tech.genetics&&t.tech.genetics>=8&&t.tech.kuiper&&!t.tech.biotech&&(Di(F(e,[F("tech_alien_biotech")]),"info",!1,["progress"]),t.tech.biotech=1,ms())):(t.resource.Knowledge.max>=Qr.tech.shields.cost.Knowledge()*a&&t.tech.high_tech&&13===t.tech.high_tech&&(Di(F(e,[F("tech_shields")]),"info",!1,["progress"]),t.tech.high_tech=14,t.settings.space.neutron=!0,t.settings.space.blackhole=!0,ms(),hs()),t.resource.Knowledge.max>=Qr.tech.ai_core.cost.Knowledge()*a&&t.tech.high_tech&&14===t.tech.high_tech&&t.tech.blackhole&&t.tech.blackhole>=3&&(Di(F(e,[F("tech_ai_core")]),"info",!1,["progress"]),t.tech.high_tech=15,t.interstellar.citadel={count:0,on:0},ms(),hs()),t.resource.Knowledge.max>=Qr.tech.graphene_processing.cost.Knowledge()*a&&t.tech.ai_core&&2===t.tech.ai_core&&(Di(F(e,[F("tech_graphene_processing")]),"info",!1,["progress"]),t.tech.ai_core=3,ms()),t.resource.Knowledge.max>=Qr.tech.nanoweave.cost.Knowledge()*a&&t.tech.science&&t.tech.science>=18&&!t.tech.nanoweave&&(Di(F(e,[F("tech_nanoweave")]),"info",!1,["progress"]),t.tech.nanoweave=1,t.resource.Nanoweave.display=!0,ms(),ha()),t.resource.Knowledge.max>=Qr.tech.orichalcum_analysis.cost.Knowledge()*a&&t.tech.high_tech&&16===t.tech.high_tech&&t.tech.chthonian&&t.tech.chthonian>=3&&(Di(F(e,[F("tech_orichalcum_analysis")]),"info",!1,["progress"]),Di(F("tech_orichalcum_analysis_result"),"info",!1,["progress"]),t.tech.high_tech=17,ms(),hs()),t.resource.Knowledge.max>=Qr.tech.infernium_fuel.cost.Knowledge()*a&&t.tech.smelting&&7===t.tech.smelting&&t.tech.hell_ruins&&t.tech.hell_ruins>=4&&(Di(F(e,[F("tech_infernium_fuel")]),"info",!1,["progress"]),t.tech.smelting=8,Ws(),ms()))}let l=Pi("moldling");if(l>0){let e="trait_infiltrator_thrall",a=ui.infiltrator.vars(1)[0]/100*l;l>=.02&&t.resource.Knowledge.max>=Qr.tech.smelting.cost.Knowledge()*a&&us("smelting",!1)&&!t.tech.smelting&&(Di(F(e,[F("tech_smelting")]),"info",!1,["progress"]),t.tech.smelting=1,t.city.smelter={count:0,cap:0,Wood:0,Coal:0,Oil:0,Star:0,StarCap:0,Inferno:0,Iron:0,Steel:0,Iridium:0},t.race.steelen&&(t.tech.smelting=2),ms()),l>=.04&&t.resource.Knowledge.max>=Qr.tech.dynamite.cost.Knowledge()*a&&us("dynamite",!1)&&t.tech.explosives&&1===t.tech.explosives&&(Di(F(e,[F("tech_dynamite")]),"info",!1,["progress"]),t.tech.explosives=2,ms()),l>=.8&&t.resource.Knowledge.max>=Qr.tech.portland_cement.cost.Knowledge()*a&&us("portland_cement",!1)&&t.tech.cement&&3===t.tech.cement&&(Di(F(e,[F("tech_portland_cement")]),"info",!1,["progress"]),t.tech.cement=4,ms()),l>=.12&&t.resource.Knowledge.max>=Qr.tech.oxygen_converter.cost.Knowledge()*a&&us("oxygen_converter",!1)&&t.tech.smelting&&4===t.tech.smelting&&(Di(F(e,[F("tech_oxygen_converter")]),"info",!1,["progress"]),t.tech.smelting=5,ms()),l>=.15&&t.resource.Knowledge.max>=Qr.tech.machinery.cost.Knowledge()*a&&us("machinery",!1)&&t.tech.foundry&&6===t.tech.foundry&&(Di(F(e,[F("tech_machinery")]),"info",!1,["progress"]),t.tech.foundry=7,ms()),l>=.2&&t.resource.Knowledge.max>=Qr.tech.uranium_storage.cost.Knowledge()*a&&us("uranium_storage",!1)&&t.tech.uranium&&1===t.tech.uranium&&(Di(F(e,[F("tech_uranium_storage")]),"info",!1,["progress"]),t.tech.uranium=1,ms()),l>=.25&&t.resource.Knowledge.max>=Qr.tech.synthetic_fur.cost.Knowledge()*a&&us("synthetic_fur",!1)&&!t.tech.synthetic_fur&&(Di(F(e,[Qr.tech.synthetic_fur.title()]),"info",!1,["progress"]),t.tech.synthetic_fur=1,ms()),l>=.35&&t.resource.Knowledge.max>=Qr.tech.rover.cost.Knowledge()*a&&us("rover",!1)&&t.tech.space_explore&&1===t.tech.space_explore&&(Di(F(e,[F("tech_rover")]),"info",!1,["progress"]),t.tech.space_explore=2,t.settings.space.moon=!0,t.space.moon_base={count:0,on:0,support:0,s_max:0},ms());let r="trait_infiltrator_thrall_alt";l>=.4&&t.resource.Knowledge.max>=Qr.tech.starcharts.cost.Knowledge()*a&&us("starcharts",!1)&&t.tech.space_explore&&3===t.tech.space_explore&&(Di(F(r,[F("tech_starcharts")]),"info",!1,["progress"]),t.tech.space_explore=4,ms()),l>=.5&&t.resource.Knowledge.max>=Qr.tech.nano_tubes.cost.Knowledge()*a&&us("nano_tubes",!1)&&!t.tech.nano&&(Di(F(r,[F("tech_nano_tubes")]),"info",!1,["progress"]),t.tech.nano=1,t.resource.Nano_Tube.display=!0,ms()),t.race.truepath?(l>=.65&&t.resource.Knowledge.max>=Qr.tech.stanene_tp.cost.Knowledge()*a&&us("stanene_tp",!1)&&!t.tech.stanene&&(Di(F(r,[F("tech_stanene")]),"info",!1,["progress"]),t.tech.stanene=1,t.resource.Stanene.display=!0,ms()),l>=.8&&t.resource.Knowledge.max>=Qr.tech.anitgrav_bunk.cost.Knowledge()*a&&us("anitgrav_bunk",!1)&&t.tech.marines&&1===t.tech.marines&&(Di(F(r,[F("tech_anitgrav_bunk")]),"info",!1,["progress"]),t.tech.marines=2,ms())):(l>=.65&&t.resource.Knowledge.max>=Qr.tech.stanene.cost.Knowledge()*a&&us("stanene",!1)&&!t.tech.stanene&&(Di(F(r,[F("tech_stanene")]),"info",!1,["progress"]),t.tech.stanene=1,t.resource.Stanene.display=!0,ms()),l>=.78&&t.resource.Knowledge.max>=Qr.tech.hydroponics.cost.Knowledge()*a&&us("hydroponics",!1)&&t.tech.mars&&5===t.tech.mars&&(Di(F(r,[F("tech_hydroponics")]),"info",!1,["progress"]),t.tech.mars=6,ms()),l>=.92&&t.resource.Knowledge.max>=Qr.tech.orichalcum_panels.cost.Knowledge()*a&&us("orichalcum_panels",!1)&&t.tech.swarm&&5===t.tech.swarm&&(Di(F(r,[F("tech_orichalcum_panels")]),"info",!1,["progress"]),t.tech.swarm=6,ms()),l>=1&&t.resource.Knowledge.max>=Qr.tech.cybernetics.cost.Knowledge()*a&&us("cybernetics",!1)&&t.tech.high_tech&&17===t.tech.high_tech&&(Di(F(r,[F("tech_cybernetics")]),"info",!1,["progress"]),t.tech.high_tech=18,ms()))}t.race.truepath&&t.tech.tauceti&&3===t.tech.tauceti&&t.space.hasOwnProperty("jump_gate")&&t.tauceti.hasOwnProperty("jump_gate")&&t.space.jump_gate.count>=100&&t.tauceti.jump_gate.count>=100&&(t.tech.tauceti=4,t.resource.Materials.display=!1,t.resource.Bolognium.display=!0,Rt(),tt(),ms()),t.race.truepath&&t.tech.tauceti&&!t.race.lone_survivor?5!==t.tech.tauceti||t.tech.plague||0!==Math.rand(0,50)?t.tech.plague&&t.tech.tau_roid&&t.tech.tau_whale&&(1===t.tech.plague&&(t.tech.tau_roid>=4||t.tech.tau_whale>=2)&&0===Math.rand(0,50)?(t.tech.plague=2,t.race.quarantine=1,t.race.qDays=0,Di(F("tau_plague2",[ee(3)]),"info",!1,["progress"])):2===t.tech.plague&&t.tech.tau_roid>=5&&t.tech.tau_whale>=2&&0===Math.rand(0,50)?(t.tech.plague=3,t.race.quarantine=2,t.race.qDays=0,Di(F("tau_plague3",[ee(3),di[t.race.species].home]),"info",!1,["progress"])):t.tech.isolation?t.tech.plague<5&&0===Math.rand(0,50)&&(t.tech.plague=5,Di(F("tau_plague5b",[di[t.race.species].home]),"info",!1,["progress"]),ms()):3===t.tech.plague&&t.tech.disease&&t.tech.disease>=2&&0===Math.rand(0,50)?(t.tech.plague=4,t.race.quarantine=3,t.race.qDays=0,Di(F("tau_plague5a",[di[t.race.species].home]),"info",!1,["progress"])):4===t.tech.plague&&t.tech.disease&&t.tech.disease>=3&&0===Math.rand(0,50)&&(t.tech.plague=5,t.race.quarantine=4,t.race.qDays=0,Di(F("tau_plague5a",[di[t.race.species].home]),"info",!1,["progress"])),t.race.quarantine&&(t.race.hasOwnProperty("qDays")||(t.race.qDays=0),t.race.qDays++)):(t.tech.plague=1,Di(F("tau_plague",[ee(3)]),"info",!1,["progress"])):t.tech.tau_gas&&t.tech.tau_gas>=4&&!t.tech.plague&&t.race.lone_survivor&&(t.tech.plague=5),t.civic.govern.protest&&t.civic.govern.protest>0&&t.civic.govern.protest--,t.civic.govern.scandal&&t.civic.govern.scandal>0&&t.civic.govern.scandal--;{let e=he("tax_cap"),a=he("tax_cap",!0);t.civic.taxes.tax_rate>e?t.civic.taxes.tax_rate=e:t.civic.taxes.tax_rate0){let e=0;for(let a=0;a3&&(s=t.genes.plasma>=2?s>5?5:s:3),e+=s}t.race.p_mutation=e}!t.tech.whitehole&&t.interstellar.stellar_engine&&t.interstellar.stellar_engine.exotic>=.025?(t.tech.whitehole=1,t.tech.stablized&&delete t.tech.stablized,Di(F("interstellar_blackhole_unstable"),"danger",!1,["progress"]),ms()):t.interstellar.stellar_engine&&t.interstellar.stellar_engine.exotic>=.025&&t.tech.whitehole&&t.tech.stablized&&(delete t.tech.stablized,ms()),!t.tech.xeno&&t.galaxy.scout_ship&&t.galaxy.scout_ship.on>0&&0===Math.rand(0,10)&&(t.tech.xeno=1,t.galaxy.scout_ship.count--,t.galaxy.scout_ship.on--,t.galaxy.scout_ship.crew--,t.galaxy.scout_ship.mil--,t.resource[t.race.species].amount--,t.civic.garrison.workers--,t.civic.garrison.crew--,Di(F("galaxy_encounter"),"info",!1,["progress"]),ms()),t.galaxy.scavenger&&t.tech.conflict&&4===t.tech.conflict&&n.scavenger>0&&Math.rand(0,50)<=n.scavenger&&(t.tech.conflict=5,Di(F("galaxy_scavenger_find"),"info",!1,["progress"]),ms()),t.tech.syndicate||t.race.lone_survivor||!t.tech.outer||0!==Math.rand(0,20)||(Di(F("outer_syndicate",[ee(4)]),"info",!1,["progress"]),t.tech.syndicate=1,t.space.syndicate={}),!t.tech.corrupted_ai&&i.ai_core2&&100===wt()&&(t.tech.corrupted_ai=1,ms()),t.arpa.sequence&&t.arpa.sequence.auto&&t.tech.genetics&&7===t.tech.genetics&&Mo(),t.race.orbit_decay&&(t.race.orbit_decayed||$("#infoTimer").html("T-"+(t.race.orbit_decay-t.stats.days)),function(){if(t.race.orbit_decay&&t.stats.hasOwnProperty("days")&&t.stats.days>=t.race.orbit_decay&&!t.race.orbit_decayed){t.race.orbit_decayed=!0,Di(F("evo_challenge_orbit_decayed_msg",[di[t.race.species].home]),"info",!1,["progress"]),"magic"===t.race.universe&&(t.city.pylon&&(t.space.pylon={count:Math.ceil(t.city.pylon.count/2)}),t.race.casting&&Object.keys(t.race.casting).forEach((function(e){t.race.casting[0]=0}))),Object.keys(Qr.city).forEach((function(e){t.city.hasOwnProperty(e)&&t.city[e].hasOwnProperty("count")&&(t.race.hooved&&Qr.city[e].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Qr.city[e].cost.Horseshoe()*t.city[e].count),t.city[e].count=0,t.city[e].hasOwnProperty("on")&&(t.city[e].on=0))})),t.race.hooved&&t.race.shoecnt<5&&(t.race.shoecnt=5),t.resource.Zen.display&&(t.resource.Zen.display=!1),t.resource.Slave.display&&(t.resource.Slave.display=!1,t.resource.Slave.amount=0,D("slave")),t.race.deconstructor&&Vs.forEach((function(e){t.city.nanite_factory[e]=0})),Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),t.space.red_university={count:0},Object.keys(Qr.space.spc_moon).forEach((function(e){t.space.hasOwnProperty(e)&&t.space[e].hasOwnProperty("count")&&(t.space[e].count=0,t.space[e].hasOwnProperty("on")&&(t.space[e].on=0))})),Object.keys(ca).forEach((function(e){"colonist"!==e&&(t.civic[e].workers=0,t.civic[e].assigned=0)})),["bolognium_ship","scout_ship","corvette_ship","frigate_ship","cruiser_ship","dreadnought","freighter","super_freighter","armed_miner","scavenger"].forEach((function(e){t.galaxy[e]&&(t.galaxy[e].on=0)})),t.portal.transport&&(t.portal.transport.on=0),["forager","farmer","lumberjack","quarry_worker"].forEach((function(e){t.civic[e].display=!1})),t.civic.hunter.display?t.civic.d_job="hunter":t.civic.d_job="unemployed";for(let e of Object.values(t.race.purgatory.city))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);if(t.queue.hasOwnProperty("queue"))for(let e=t.queue.queue.length-1;e>=0;e--){let a=t.queue.queue[e];("city"===a.action||"space"===a.action&&Qr.space.spc_moon[a.type])&&t.queue.queue.splice(e,1)}t.arpa.sequence&&(t.arpa.sequence.on=!1,t.arpa.sequence.boost=!1),t.city.calendar.moon=0,document.getElementById("moon").removeAttribute("class"),$("#moon").addClass("moon wi wi-moon-new"),t.settings.spaceTabs=1,t.settings.space.moon=!1,t.settings.showCity=!1,rc($("#infoTimer")),Rt()}}()),function(){if(t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks){let e=[0,1,2];t.genes.governor>=2&&(e.push(e.length),N("organizer",0)&&e.push(e.length)),N("organizer",0)&&e.push(e.length),e.forEach((function(e){B[t.race.governor.tasks[`t${e}`]]&&B[t.race.governor.tasks[`t${e}`]].req()&&B[t.race.governor.tasks[`t${e}`]].task()}))}}()}if(!t.race.seeded||t.race.seeded&&t.race.chose){if(0===Math.rand(0,t.event.t)){let e=ho("major");if(e.length>0){let a=e[Math.floor(m(0,e.length))];Di(lo[a].effect(),"caution",!1,["events","major_events"]),t.event.l=a}t.event.t=999,"pisces"===r&&(t.event.t-=H("pisces")[0])}else t.event.t--;if("protoplasm"!==t.race.species)if(0===Math.rand(0,t.m_event.t)){let e=ho("minor");if(e.length>0){let a=e[Math.floor(m(0,e.length))];Di(lo[a].effect(),!1,!1,["events","minor_events"]),t.m_event.l=a}t.m_event.t=850,"pisces"===r&&(t.m_event.t-=H("pisces")[1])}else t.m_event.t--;if(t.race.witch_hunter&&t.resource.Sus.amount>=100){let e=300-t.resource.Sus.amount;e<1&&(e=1),0===Math.rand(0,e)&&Di(lo.witch_hunt_crusade.effect(),"caution",!1,["events","major_events"])}if(t.race.witch_hunter&&t.resource.Sus.amount>=50&&t.civic.scientist.workers>0){let e=250-2*t.resource.Sus.amount;e<50&&(e=50),0===Math.rand(0,e)&&Di(lo.witch_hunt.effect(),!1,!1,["events","minor_events"])}}11===a.getMonth()&&a.getDate()>=17&&a.getDate()<=24?(t.special.gift[`g${a.getFullYear()}`]=!0,t.tech.santa=1):delete t.tech.santa,Tc("fool")?$("body").hasClass("fool")||($("body").addClass("fool"),to({fool:!0})):$("body").hasClass("fool")&&($("body").removeClass("fool"),to()),t.stats.current=Date.now(),t.race.hasOwnProperty("geck")||e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),"protoplasm"!==t.race.species&&(t.stats.days+t.stats.tdays)%1e5==99999&&Di(F("backup_warning"),"advanced",!0),--qo<=0&&(qo=60,Zi("page_view",{page_title:"Game Loop"})),t.settings.pause&&M.s&&Ii("stop"),t.settings.at>0&&(t.settings.at-=M.timers.long*(t.settings.atMultiplier-1),t.settings.at<=0&&(t.settings.at=0,Ii("stop"),Ii("start")))}()}}),!1)),Ii("start"),Co();var $o=!0,xo=t.arpa.sequence&&t.arpa.sequence.on?t.arpa.sequence.on:0;let ko={1:1.1,2:1.25,3:1.5};var qo=60;function Mo(){if(t.resource.Knowledge.amount>=2e5&&t.resource.Knowledge.amount>=t.resource.Knowledge.max-1e4){t.resource.Knowledge.amount-=2e5;let e=t.genes.synthesis?ko[t.genes.synthesis]:1;t.resource.Genes.amount+=e}}function Po(e){if(t.tech.high_tech&&t.tech.high_tech>=11){let r=t.resource.Knowledge.max,s=25e4,c=0;for(;r>s;)r-=s,s*=1.1,c++;if(c+=+(r/s).toFixed(2),t.interstellar.citadel){let a=e?t.interstellar.citadel.on:i.citadel;t.tech.high_tech&&t.tech.high_tech>=15&&a>0&&(c*=1+.05*a)}if(t.space.ai_core2){let a=e?t.space.ai_core2.on:i.ai_core2;t.tech.titan_ai_core&&a>0&&(c*=1.25)}if(t.stats.achieve.obsolete&&t.stats.achieve.obsolete.l>=5&&t.prestige.AICore.count>0&&(c*=2-.99**t.prestige.AICore.count),t.race.linked){let e=ui.linked.vars()[0]/100*t.resource[t.race.species].amount;e>ui.linked.vars()[1]/100&&(e-=ui.linked.vars()[1]/100,e/=e+200-ui.linked.vars()[1],e+=ui.linked.vars()[1]/100),c*=1+e}a=+c.toFixed(3),u=a}var a}function Oo(){!1===t.resource.Steel.display&&0===Math.rand(0,1250)&&(t.resource.Steel.display=!0,Vi("Steel",1),Di(F("steel_sample"),"info",!1,["progress"]))}function Co(){["#resources > .resource",".tab-item > .market-item","#galaxyTrade > .market-item"].forEach((function(e){let t=!1;$(`${e}:visible`).each((function(){t?($(this).addClass("alt"),t=!1):($(this).removeClass("alt"),t=!0)}))}))}function jo(e){let a=!(!t.race.elusive&&0!==Math.floor(m(0,3))),r=Pi("satyr");if(r>0&&Math.floor(m(0,100))<=100*r&&(a=!0),!a&&t.civic.foreign[`gov${e}`].spy>0&&(t.civic.foreign[`gov${e}`].spy-=1),a||0!==Math.floor(m(0,4)))Di(F(a?"event_spy_fail":"event_spy",[ee(e)]),"danger",!1,["spy"]);else{Di(F("event_spy_sellout",[ee(e)]),"danger",!1,["spy"]);let a=t.race.mistrustful?5+ui.mistrustful.vars()[0]:5;t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(1,a)),t.civic.foreign[`gov${e}`].hstl>100&&(t.civic.foreign[`gov${e}`].hstl=100)}}P.version_check=setInterval((function(){$.ajax({url:"https://pmotschmann.github.io/Evolve/package.json",type:"GET",dataType:"json",success:function(e){e.version&&e.version!=t.version&&!t.beta&&$("#topBar .version > a").html(`${F("update_avail")} v`+t.version+bo)}})}),9e5),Ti("versionLog",function(e){let t=0;for(t=0;t=0;a--){e.append(`

        v${mo[a].version}${mo[a].hasOwnProperty("revision")?mo[a].revision:""}

        ${mo[a].date}
        `);for(let t=0;t${mo[a].changes[t]}`)}return e}($('
        ')),{wide:!0}),t.race.start_cataclysm&&t.race.start_cataclysm&&(delete t.race.start_cataclysm,Ls())})(); \ No newline at end of file +(()=>{"use strict";var e=window.localStorage,t={seed:1,warseed:1,resource:{},evolution:{},tech:{},city:{},space:{},interstellar:{},portal:{},tauceti:{},civic:{},race:{},genes:{},blood:{},stats:{start:Date.now(),days:0,tdays:0},event:{t:200,l:!1},m_event:{t:499,l:!1}},a={},r={c:{},p:{}},s={},i={},c={},o={},n={},l={},u=0;var d={},_={},p={view:"all"};const h=["all","progress","queue","building_queue","research_queue","combat","spy","events","major_events","minor_events","achievements","hell"];function m(e,a,r){return a=a||1,e=e||0,t[r?"warseed":"seed"]=(9301*t[r?"warseed":"seed"]+49297)%233280,e+t[r?"warseed":"seed"]/233280*(a-e)}Math.rand=function(e,t){return Math.floor(Math.random()*(t-e))+e},t.seed=2,t.warseed=2;{let a=e.getItem("evolved")||!1;if(a){let e=JSON.parse(LZString.decompressFromUTF16(a));e?t=e:f()}else f()}if(t.version||(t.version="0.2.0"),b(t.version)<2060&&Object.keys(t.resource).forEach((function(e){t.resource[e].crates&&(t.resource[e].crates=Math.ceil(t.resource[e].crates/5)),t.resource[e].containers&&(t.resource[e].containers=Math.ceil(t.resource[e].containers/5))})),b(t.version)<2062&&void 0!==t.civic.taxes)switch(Number(t.civic.taxes.tax_rate)){case 0:t.civic.taxes.tax_rate=0;break;case 1:t.civic.taxes.tax_rate=10;break;case 2:t.civic.taxes.tax_rate=20;break;case 3:t.civic.taxes.tax_rate=30;break;case 4:t.civic.taxes.tax_rate=40;break;case 5:t.civic.taxes.tax_rate=50}if(2062===b(t.version)&&void 0!==t.civic.taxes&&2==t.civic.taxes.tax_rate&&(t.civic.taxes.tax_rate=20),b(t.version)<2065&&void 0!==t.race&&"sporgar"===t.race.species&&(delete t.race.crafty,delete t.race.hydrophilic,t.race.infectious=1,t.race.parasite=1,!t.tech.military&&t.tech.primitive&&t.tech.primitive>=3&&(t.civic.garrison.display=!0,t.settings.showCivic=!0,t.city.garrison={count:0})),b(t.version)<3002&&t.space&&(t.tech.space&&t.tech.space>=4&&(t.space.living_quarters||(t.space.living_quarters={count:0,on:0}),t.space.garage||(t.space.garage={count:0}),t.space.red_mine||(t.space.red_mine={count:0,on:0}),t.space.fabrication||(t.space.fabrication={count:0,on:0}),t.space.laboratory||(t.space.laboratory={count:0,on:0})),t.tech.space&&t.tech.space>=3&&(t.space.iridium_mine||(t.space.iridium_mine={count:0,on:0}),t.space.helium_mine||(t.space.helium_mine={count:0,on:0})),t.tech.hell&&(t.space.geothermal||(t.space.geothermal={count:0,on:0}))),b(t.version)<3004&&t.settings&&t.settings.space&&t.settings.space.belt&&(t.space.space_station={count:0,on:0,support:0,s_max:0}),b(t.version)<4001&&t.city&&t.city.factory&&!t.city.factory.Nano&&(t.city.factory.Nano=0),b(t.version)<4003&&t.stats.achieve&&Object.keys(t.stats.achieve).forEach((function(e){t.stats.achieve[e]=1})),b(t.version)<4028&&t.stats.achieve&&t.stats.achieve.genus_demonic&&(t.stats.achieve.biome_hellscape=t.stats.achieve.genus_demonic),b(t.version)<4029&&t.race.mutation&&t.race.mutation>0){t.resource.Genes={name:"Genes",display:!0,value:0,amount:0,crates:0,diff:0,delta:0,max:-2,rate:0};for(let e=0;e=3&&(t.tech.wind_plant=1,t.tech.hunting=2);let e=["Human","Humano","Elf","Elfo","Orc","Cath","Wolven","Centaur","Centauro","Kobold","Goblin","Gnome","Ogre","Ogro","Cyclops","Ciclope","Troll","Tortoisan","Gecko","Slitheryn","Arraak","Pterodacti","Dracnid","Ent","Cacti","Sporgar","Shroomi","Mantis","Scorpid","Antid","Sharkin","Octigoran","Balorg","Imp"];for(let a=0;a0){let e=1;t.race.no_trade&&e++,t.race.no_craft&&e++,t.race.no_crispr&&e++,t.race.weak_mastery&&e++,t.stats.achieve.cross={l:e,a:e}}if(b(t.version)<7e3&&(t.civic.govern||(t.civic.govern={type:"oligarchy",rev:0,fr:0})),b(t.version)<7004&&t.queue&&t.queue.queue)for(let e=0;e0&&(t.stats.harmony=parseFloat(t.stats.harmony.toFixed(2)),t.race.Harmony.count=parseFloat(t.race.Harmony.count.toFixed(2))),b(t.version)<8017&&t.city.garrison&&(t.city.garrison.on=t.city.garrison.count),b(t.version)<9005&&t.race.hasOwnProperty("terrifying")&&t.tech.hasOwnProperty("gambling")&&!t.space.hasOwnProperty("spc_casino")&&(t.space.spc_casino={count:0,on:0}),b(t.version)<9009&&t.genes.hasOwnProperty("ancients")&&t.genes.ancients>=3&&(4===t.genes.ancients?t.genes.ancients=5:t.race.Plasmid.count+=300),b(t.version)<9010&&(["species","gods","old_gods"].forEach((e=>{"orge"===t.race[e]&&(t.race[e]="ogre")})),t.stats.hasOwnProperty("achieve")&&t.stats.achieve.hasOwnProperty("extinct_orge")&&(t.stats.achieve.extinct_ogre=t.stats.achieve.extinct_orge,delete t.stats.achieve.extinct_orge),t.resource.hasOwnProperty("orge")&&(t.resource.ogre=t.resource.orge,delete t.resource.orge),t.city&&t.city.factory&&!t.city.factory.Furs&&(t.city.factory.Furs=0)),b(t.version)<9014&&(["seraph","unicorn","custom"].forEach((e=>{t.race.species===e&&("custom"===e&&t.hasOwnProperty("custom")&&"angelic"===t.custom.race0.genus||"custom"!==e)&&(t.race.holy=1)})),t.hasOwnProperty("arpa")&&t.arpa.hasOwnProperty("sequence")&&(t.arpa.sequence.labs=0)),b(t.version)<1e5&&(delete t.city.lumber,delete t.city.stone,t.stats.dark=0,t.race.Dark&&(t.stats.dark=t.race.Dark.count),t.city.hasOwnProperty("smelter")&&(t.city.smelter.hasOwnProperty("Star")||(t.city.smelter.Star=0),t.city.smelter.hasOwnProperty("StarCap")||(t.city.smelter.StarCap=0),t.city.smelter.hasOwnProperty("Inferno")||(t.city.smelter.Inferno=0)),t.hasOwnProperty("warseed")||(t.warseed=t.seed+1,Math.war=t.hasOwnProperty("warseed")?t.warseed:t.seed),t.portal.hasOwnProperty("bireme")&&(t.portal.bireme.crew=0,t.portal.bireme.mil=0),t.portal.hasOwnProperty("transport")&&(t.portal.transport.crew=0,t.portal.transport.mil=0,t.portal.transport.cargo||(t.portal.transport.cargo={used:0,max:0,Crystal:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0})),t.hasOwnProperty("settings")&&t.settings.portal&&t.settings.portal.spire&&!t.portal.hasOwnProperty("purifier")&&(t.settings.portal.spire=!1),t.portal.hasOwnProperty("mechbay")&&!Array.isArray(t.portal.mechbay.mechs)&&(t.portal.mechbay.mechs=[]),t.portal.transport&&t.portal.transport.count>=1&&!t.tech.hell_spire&&(t.tech.hell_spire=1,t.settings.portal.spire=!0,t.settings.showCargo=!0,t.portal.purifier={count:0,on:0,support:0,s_max:0,supply:0,sup_max:100,diff:0},t.portal.port={count:0,on:0}),t.tech.hasOwnProperty("waygate")&&!t.portal.hasOwnProperty("waygate")&&delete t.tech.waygate,t.hasOwnProperty("blood")||(t.blood={})),b(t.version)<100013&&t.hasOwnProperty("settings")&&t.settings.hasOwnProperty("showPowerGrid")&&t.hasOwnProperty("race")&&t.race.infiltrator&&t.hasOwnProperty("tech")&&t.tech.hasOwnProperty("high_tech")&&t.tech.high_tech>=2&&(t.settings.showPowerGrid=!0),b(t.version)<100014&&(t.race.Dark&&(t.stats.dark=t.race.Dark.count),t.race.casting&&t.race.evil&&(t.race.casting.total-=t.race.casting.lumberjack,t.race.casting.lumberjack=0),t.queue&&t.queue.queue))for(let e=0;e=2,events:!0,major_events:!0,minor_events:!0,achievements:t.stats.achieve&&Object.keys(t.stats.achieve).length>0||t.stats.feat&&Object.keys(t.stats.feat).length>0,hell:t.settings.showPortal||t.stats.blackhole||t.stats.ascend||t.stats.descend}),t.race.hasOwnProperty("inflation")&&["supercollider","stock_exchange","launch_facility","monuments","railway","roid_eject","nexus","syphon"].forEach((function(e){t.tech.hasOwnProperty(e)&&(t.race.inflation+=10*t.tech[e])}))),b(t.version)<101012&&t.civic.garrison&&(t.civic.garrison.rate=0),b(t.version)<101014&&(t.hasOwnProperty("settings")&&t.settings.hasOwnProperty("msgFilters")&&Object.keys(t.settings.msgFilters).forEach((function(e){t.settings.msgFilters[e]={unlocked:!!t.settings.msgFilters[e],vis:!!t.settings.msgFilters[e],max:60,save:3}})),t.hasOwnProperty("lastMsg")&&t.lastMsg)){let e={};h.forEach((function(t){e[t]=[]})),t.lastMsg.forEach((function(t){t.t?t.t.forEach((function(a){e[a].push({m:t.m,c:t.c})})):e.all.push({m:t.m,c:t.c})})),t.lastMsg=e}if(b(t.version)<=101014&&!t.revision&&t.race.cataclysm&&t.race.universe&&"magic"===t.race.universe&&t.tech.magic&&t.tech.magic>=2&&(t.space.pylon={count:0}),b(t.version)<101015&&t.hasOwnProperty("special")&&t.special.hasOwnProperty("trick")&&(t.special.trick[2020]=JSON.parse(JSON.stringify(t.special.trick)),delete t.special.trick.trick1,delete t.special.trick.trick2,delete t.special.trick.trick3,delete t.special.trick.trick4,delete t.special.trick.trick5,delete t.special.trick.trick6,delete t.special.trick.trick7,delete t.special.trick.trick8,delete t.special.trick.trick9,delete t.special.trick.trick10,delete t.special.trick.trick11,delete t.special.trick.trick12),b(t.version)<102e3&&(t.hasOwnProperty("portal")&&t.portal.hasOwnProperty("fortress")&&!t.portal.fortress.hasOwnProperty("nocrew")&&(t.portal.fortress.nocrew=!1),t.city.hasOwnProperty("smelter")&&!t.city.smelter.hasOwnProperty("Iridium")&&(t.city.smelter.Iridium=0),t.hasOwnProperty("portal")&&t.portal.hasOwnProperty("mechbay")&&!t.portal.mechbay.hasOwnProperty("active")&&(t.portal.mechbay.active=0,t.portal.mechbay.scouts=0)),b(t.version)<102001&&(t.race.blood_thirst&&t.race.blood_thirst>3&&(t.race.blood_thirst=1),t.race.rainbow&&t.race.rainbow>3&&(t.race.rainbow=1)),b(t.version)<102005&&!t.stats.cores&&t.race.hasOwnProperty("AICore")&&(t.stats.cores=t.race.AICore.count),b(t.version)<102006&&t.race.artifical&&(t.race.calm&&(t.resource.hasOwnProperty("Zen")&&(t.resource.Zen.display=!0),t.city.meditation={count:0}),t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0})),b(t.version)<102007&&t.stats.hasOwnProperty("achieve")&&delete t.stats.achieve.extinct_sludge,b(t.version)<102012&&(t.city.hasOwnProperty("ptrait")&&(t.city.ptrait="none"===t.city.ptrait?[]:[t.city.ptrait]),t.tech.hell_ruins&&t.tech.hell_ruins>=3&&(t.tech.hell_vault=1)),b(t.version)<102015){if(t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks"))for(let e in t.race.governor.tasks)"asssemble"===t.race.governor.tasks[e]&&(t.race.governor.tasks[e]="assemble");t.settings&&t.settings.hasOwnProperty("restoreCheck")&&delete t.settings.restoreCheck}if(b(t.version)<102017&&(t.portal.hasOwnProperty("fortress")&&(t.portal.observe={settings:{expanded:!1,average:!1,hyperSlow:!1,display:"game_days",dropKills:!0,dropGems:!0},stats:{total:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0}},period:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0}}},graphID:0,graphs:{}}),t.tech.hasOwnProperty("genetics")&&t.tech.genetics>1&&t.hasOwnProperty("arpa")&&(t.arpa.hasOwnProperty("sequence")||(t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!1}),t.arpa.sequence.boost||(t.arpa.sequence.boost=!1),t.arpa.sequence.auto||(t.arpa.sequence.auto=!1),t.arpa.sequence.labs||(t.arpa.sequence.labs=0))),b(t.version)<102021&&t.hasOwnProperty("custom")&&!t.custom.hasOwnProperty("race0")){let e=t.race.hasOwnProperty("species")?t.race.species:"protoplasm";t.galaxy.hasOwnProperty("alien1")&&"custom"===t.galaxy.alien1.id&&(t.galaxy.alien1.id="human"===e?"elven":"human"),t.galaxy.hasOwnProperty("alien2")&&"custom"===t.galaxy.alien2.id&&(t.galaxy.alien2.id="orc"===e||"orc"===t.galaxy.alien1.id?"cath":"orc")}function g(){["reset","plasmid","antiplasmid","universes","phage","starved","tstarved","died","tdied","sac","tsac","know","tknow","portals","dkills","attacks","cfood","tfood","cstone","tstone","clumber","tlumber","mad","bioseed","cataclysm","blackhole","ascend","descend","terraform","aiappoc","matrix","retire","eden","geck","dark","harmony","blood","cores","artifact","cattle","tcattle","murders","tmurders","psykill","tpsykill"].forEach((function(e){t.stats.hasOwnProperty(e)||(t.stats[e]=0)})),t.stats.achieve||(t.stats.achieve={}),t.stats.feat||(t.stats.feat={}),t.stats.hasOwnProperty("womling")||(t.stats.womling={god:{l:0},lord:{l:0},friend:{l:0}}),t.stats.spire||(t.stats.spire={}),t.stats.synth||(t.stats.synth={}),t.stats.hasOwnProperty("banana")||(t.stats.banana={b1:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b2:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b3:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b4:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b5:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1}})}if(b(t.version)<103e3&&(t.hasOwnProperty("tauceti")||(t.tauceti={}),"protoplasm"===t.race.species&&(t.evolution.hasOwnProperty("sexual_reproduction")&&(t.tech.evo=t.evolution.sexual_reproduction.count>0?2:1,delete t.evolution.sexual_reproduction),[["phagocytosis",{evo:3,evo_animal:1}],["chloroplasts",{evo:3,evo_plant:1}],["chitin",{evo:3,evo_fungi:1}],["exterminate",{evo:7,evo_synthetic:2}],["multicellular",{evo:4}],["spores",{evo:5}],["poikilohydric",{evo:5}],["bilateral_symmetry",{evo:5,evo_insectoid:1,evo_mammals:1,evo_eggshell:1,evo_aquatic:1,evo_fey:1,evo_sand:1,evo_heat:1,evo_polar:1}],["bryophyte",{evo:7}],["athropods",{evo:7,evo_insectoid:2}],["mammals",{evo:6,evo_humanoid:1,evo_giant:1,evo_small:1,evo_animalism:1,evo_demonic:1,evo_angelic:1}],["humanoid",{evo:7,evo_humanoid:2}],["gigantism",{evo:7,evo_giant:2}],["dwarfism",{evo:7,evo_small:2}],["animalism",{evo:7,evo_animalism:2}],["carnivore",{evo_animalism:3,evo_carnivore:2}],["herbivore",{evo_animalism:3,evo_herbivore:2}],["omnivore",{evo_animalism:3,evo_omnivore:2}],["celestial",{evo:7,evo_angelic:2}],["demonic",{evo:7,evo_demonic:2}],["aquatic",{evo:7,evo_aquatic:2}],["fey",{evo:7,evo_fey:2}],["heat",{evo:7,evo_heat:2}],["polar",{evo:7,evo_polar:2}],["sand",{evo:7,evo_sand:2}],["eggshell",{evo:6,evo_eggshell:2}],["endothermic",{evo:7,evo_avian:2}],["ectothermic",{evo:7,evo_reptilian:2}],["bunker",{evo_challenge:1}]].forEach((function(e){if(t.evolution.hasOwnProperty(e[0])&&t.evolution[e[0]].count>0)for(let[a,r]of Object.entries(e[1]))t.tech[a]=r;delete t.evolution[e[0]]})),t.evolution.mloaded=1,t.evolution.gmloaded=1)),b(t.version)<103001&&(t.hasOwnProperty("prestige")||(t.prestige={}),t.race.Plasmid&&t.race.Plasmid.hasOwnProperty("anti")&&(t.prestige.AntiPlasmid={count:t.race.Plasmid.anti}),["Plasmid","Phage","AICore","Dark","Harmony"].forEach((function(e){t.race.hasOwnProperty(e)&&(t.prestige[e]={count:t.race[e].count},delete t.race[e])})),["Artifact","Blood_Stone"].forEach((function(e){t.resource.hasOwnProperty(e)&&(t.prestige[e]={count:t.resource[e].amount},delete t.resource[e])})),!t.stats.hasOwnProperty("synth")&&t.race.hasOwnProperty("srace")&&(t.stats.synth={},t.stats.synth[t.race.srace]=!0),t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("config")&&t.race.governor.config.hasOwnProperty("trash")&&["Infernite","Elerium","Copper","Iron"].forEach((function(e){t.race.governor.config.trash.hasOwnProperty(e)&&"number"==typeof t.race.governor.config.trash[e]&&(t.race.governor.config.trash[e]={v:t.race.governor.config.trash[e],s:!0})}))),b(t.version)<103002&&t.portal.hasOwnProperty("observe")&&t.portal.observe.hasOwnProperty("stats")&&(t.portal.observe.stats.period.gems.surveyors=0,t.portal.observe.stats.total.gems.surveyors=0),t.version="1.3.8",t.revision="a",delete t.beta,t.hasOwnProperty("prestige")||(t.prestige={}),["Plasmid","AntiPlasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone"].forEach((function(e){t.prestige.hasOwnProperty(e)||(t.prestige[e]={count:0})})),t.hasOwnProperty("power")||(t.power=[]),t.hasOwnProperty("support")||(t.support={}),["moon","red","belt","alpha","nebula","gateway","alien2","lake","spire","titan","enceladus","eris","tau_home","tau_red","tau_roid"].forEach((function(e){t.support.hasOwnProperty(e)||(t.support[e]=[])})),t.civic.cement_worker&&.25===t.civic.cement_worker.impact&&(t.civic.cement_worker.impact=.4),t.settings||(t.settings={showEvolve:!0,showAchieve:!1,animated:!0,disableReset:!1,font:"standard",q_merge:"merge_nearby",cLabels:!0,theme:"gruvboxDark",locale:"en-US",icon:"star"}),t.settings.space||(t.settings.space={}),t.settings.space.hasOwnProperty("home")||(t.settings.space.home=!0),C(!1),t.settings.icon||(t.settings.icon="star"),t.settings.showResources||(t.settings.showResources=t.settings.showMarket),t.settings.showStorage||(t.city.warehouse||t.city.storage_yard?t.settings.showStorage=!0:t.settings.showStorage=!1),t.settings.hasOwnProperty("touch")||(t.settings.touch=!1),t.settings.hasOwnProperty("lowPowerBalance")||(t.settings.lowPowerBalance=!1),t.queue||(t.queue={display:!1,queue:[]}),t.r_queue||(t.r_queue={display:!1,queue:[]}),t.queue.rename||(t.queue.rename=!1),t.queue.max||(t.queue.max=0),t.r_queue.max||(t.r_queue.max=0),t.queue.pause||(t.queue.pause=!1),t.r_queue.pause||(t.r_queue.pause=!1),t.lastMsg||(t.lastMsg={}),t.settings.msgFilters||(t.settings.msgFilters={}),["all","progress","events","major_events","minor_events"].forEach((function(e){t.settings.msgFilters[e]||(t.settings.msgFilters[e]={unlocked:!0,vis:!0,max:60,save:3})})),h.forEach((function(e){t.lastMsg[e]||(t.lastMsg[e]=[]),t.settings.msgFilters[e]||(t.settings.msgFilters[e]={unlocked:!1,vis:!1,max:60,save:3})})),t.settings.msgQueueHeight||(t.settings.msgQueueHeight=$("#msgQueue").outerHeight(),t.settings.buildQueueHeight=$("#buildQueue").outerHeight()),t.space||(t.space={}),t.starDock||(t.starDock={}),t.interstellar||(t.interstellar={}),t.galaxy||(t.galaxy={}),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Bolognium&&(t.interstellar.mass_ejector.Bolognium=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Vitreloy&&(t.interstellar.mass_ejector.Vitreloy=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Orichalcum&&(t.interstellar.mass_ejector.Orichalcum=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Nanoweave&&(t.interstellar.mass_ejector.Nanoweave=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Scarletite&&(t.interstellar.mass_ejector.Scarletite=0),t.hasOwnProperty("pillars")||(t.pillars={}),t.settings.space.alpha||(t.settings.space.alpha=!1,t.settings.space.proxima=!1,t.settings.space.nebula=!1,t.settings.space.neutron=!1,t.settings.space.blackhole=!1),t.settings.showAchieve||(t.settings.showAchieve=!1),t.settings.locale||(t.settings.locale="en-us"),void 0===t.settings.pause&&(t.settings.pause=!1),void 0===t.settings.mKeys&&(t.settings.mKeys=!0),void 0===t.settings.keyMap&&(t.settings.keyMap={x10:"Control",x25:"Shift",x100:"Alt",q:"q"}),void 0===t.settings.keyMap.showCiv&&(t.settings.keyMap.showCiv="1",t.settings.keyMap.showCivic="2",t.settings.keyMap.showResearch="3",t.settings.keyMap.showResources="4",t.settings.keyMap.showGenetics="5",t.settings.keyMap.showAchieve="6",t.settings.keyMap.settings="7"),delete t.settings.keyMap.d,void 0===t.settings.qAny&&(t.settings.qAny=!1),void 0===t.settings.sPackOn&&(t.settings.sPackOn=!0),void 0===t.settings.qAny_res&&(t.settings.qAny_res=!1),void 0===t.settings.sPackMsg&&(t.settings.sPackMsg=!1),void 0===t.settings.expose&&(t.settings.expose=!1),void 0===t.settings.tabLoad&&(t.settings.tabLoad=!1),void 0===t.settings.boring&&(t.settings.boring=!1),t.settings.hasOwnProperty("mtorder")||(t.settings.mtorder=[]),g(),t.race.seeded||(t.race.seeded=!1),t.race.deterioration||(t.race.deterioration=0),t.race.gene_fortify||(t.race.gene_fortify=0),t.race.old_gods||(t.race.old_gods="none"),t.race.universe||(t.race.universe="standard"),t.genes.minor||(t.genes.minor={}),t.race.minor||(t.race.minor={}),t.hasOwnProperty("govern")||(t.govern={governor:{},candidate:[],policy:{}}),t.settings.hasOwnProperty("showMil")||(t.settings.showMil=!0),t.settings.hasOwnProperty("showPowerGrid")||(t.settings.showPowerGrid=!!(t.hasOwnProperty("tech")&&t.tech.hasOwnProperty("high_tech")&&t.tech.high_tech>=2)),t.settings.affix||(t.settings.affix="si"),t.special||(t.special={}),t.special.gift||(t.special.gift={}),t.special.hasOwnProperty("egg")||(t.special.egg={}),t.special.hasOwnProperty("trick")||(t.special.trick={trick1:!1,trick2:!1,trick3:!1,trick4:!1,trick5:!1,trick6:!1,trick7:!1,trick8:!1,trick9:!1,trick10:!1,trick11:!1,trick12:!1}),t.civic.govern||(t.civic.govern={type:"oligarchy",rev:2e3,fr:0}),t.civic.govern.fr=0,t.hasOwnProperty("custom")||(t.custom={}),t.custom.hasOwnProperty("planet")&&t.custom.planet.hasOwnProperty("biome")&&delete t.custom.planet,t.city.hasOwnProperty("smelter")&&!t.city.smelter.hasOwnProperty("cap")&&(t.city.smelter.cap=0),t.civic.homeless||(t.civic.homeless=0),t.civic.foreign||(t.civic.foreign={gov0:{unrest:0,hstl:100,mil:100,eco:75,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov1:{unrest:0,hstl:0,mil:150,eco:100,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov2:{unrest:0,hstl:50,mil:250,eco:150,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1}}),void 0===t.civic.foreign.gov0.trn&&(t.civic.foreign.gov0.trn=0,t.civic.foreign.gov1.trn=0,t.civic.foreign.gov2.trn=0,t.civic.foreign.gov0.sab=0,t.civic.foreign.gov1.sab=0,t.civic.foreign.gov2.sab=0,t.civic.foreign.gov0.act="none",t.civic.foreign.gov1.act="none",t.civic.foreign.gov2.act="none"),void 0!==t.civic.foreign.gov0.name&&"evo_organism_title"===t.civic.foreign.gov0.name.s1&&(t.civic.foreign.gov0.name.s1="Northern"),void 0!==t.civic.foreign.gov1.name&&"evo_organism_title"===t.civic.foreign.gov1.name.s1&&(t.civic.foreign.gov1.name.s1="Southern"),void 0!==t.civic.foreign.gov2.name&&"evo_organism_title"===t.civic.foreign.gov2.name.s1&&(t.civic.foreign.gov2.name.s1="Divine"),!t.race.evil&&t.race.immoral&&void 0!==t.race&&"wendigo"!==t.race.species)delete t.race.immoral;else if(void 0!==t.race&&"wendigo"===t.race.species){const e=new Date;t.settings.hasOwnProperty("boring")&&!t.settings.boring&&11===e.getMonth()&&e.getDate()>=17&&(t.race.immoral=3)}if(t.hasOwnProperty("special")&&t.special.hasOwnProperty("gift")){const e=new Date(t.stats.start),a=new Date;Object.keys(t.special.gift).forEach((function(r){let s=Number(r.substring(1,5));(s=1?t.civic.d_job="farmer":t.civic.d_job="unemployed"),t.settings.animated=!0,t.settings.disableReset=!1,t.arpa&&t.arpa.launch_facility&&t.arpa.launch_facility.rank>0&&!t.tech.space&&(t.tech.space=1);var v={x10:!1,x25:!1,x100:!1,q:!1};function y(){let e=1;return t.settings.mKeys&&(v.x10&&(e*=10),v.x25&&(e*=25),v.x100&&(e*=100)),e}function b(e){let t=e.split(".",3);return t[0]*=1e5,t[1]*=1e3,Number(t[0])+Number(t[1])+Number(t[2])}function w(){if($(window).width()>=1400&&$("#msgQueue:not(.right)")){let e=$("#buildQueue").detach();e.addClass("right"),e.removeClass("has-text-info");let t=$("#msgQueue").detach();t.addClass("right"),t.removeClass("has-text-info"),t.css("resize","none"),$("#queueColumn").addClass("is-one-quarter"),$("#queueColumn").append(e),$("#queueColumn").append(t),$("#mainColumn").removeClass("is-three-quarters"),$("#mainColumn").addClass("is-half")}else if($(window).width()<1400&&$("#msgQueue").hasClass("right")){let e=$("#buildQueue").detach();e.removeClass("right"),e.addClass("has-text-info");let t=$("#msgQueue").detach();t.removeClass("right"),t.addClass("has-text-info"),t.css("resize","vertical"),$("#queueColumn").removeClass("is-one-quarter"),$("#sideQueue").append(e),$("#sideQueue").append(t),$("#mainColumn").removeClass("is-half"),$("#mainColumn").addClass("is-three-quarters")}}var x={si:["K","M","G","T","P","E","Z","Y"],sci:["e3","e6","e9","e12","e15","e18","e21","e24"],sln:["K","M","B","t","q","Q","s","S"]};function k(e,a,r){let s=0,i="",c=e<0;return c&&(e*=-1),e<=9999?s=+e.toFixed(a):e<1e6?(i=x[t.settings.affix][0],s=r?+(e/1e3).toFixed(1):Math.floor(e/100)/10):e<1e9?(i=x[t.settings.affix][1],s=r?+(e/1e6).toFixed(1):Math.floor(e/1e4)/100):e<1e12?(i=x[t.settings.affix][2],s=r?+(e/1e9).toFixed(1):Math.floor(e/1e7)/100):e<1e15?(i=x[t.settings.affix][3],s=r?+(e/1e12).toFixed(1):Math.floor(e/1e10)/100):e<1e18?(i=x[t.settings.affix][4],s=r?+(e/1e15).toFixed(1):Math.floor(e/1e13)/100):e<1e21?(i=x[t.settings.affix][5],s=r?+(e/1e18).toFixed(1):Math.floor(e/1e16)/100):e<1e24?(i=x[t.settings.affix][6],s=r?+(e/1e21).toFixed(1):Math.floor(e/1e19)/100):(i=x[t.settings.affix][7],s=r?+(e/1e24).toFixed(1):Math.floor(e/1e22)/100),s>=100&&(s=+s.toFixed(1)),c&&(s*=-1),s+i}function q(e,t){var a=document.createElement("div"),r="speak-"+Date.now();a.setAttribute("id",r),a.setAttribute("aria-live",t||"polite"),a.classList.add("sr-only"),document.body.appendChild(a),window.setTimeout((function(){document.getElementById(r).innerHTML=e}),100),window.setTimeout((function(){document.body.removeChild(document.getElementById(r))}),1e3)}$(window).resize((function(){w()})),window.soft_reset=function(a){try{a=a&&"replicator"===a?"replicator":"soft",gtag("event","reset",{end:a})}catch(e){}a||O();let r=!!t.race.hasOwnProperty("srace")&&t.race.srace,s=t.race.hasOwnProperty("geck")?t.race.geck:0;t.race.hasOwnProperty("gecked")&&(s+=t.race.gecked,t.stats.geck-=t.race.gecked);let i={species:"protoplasm",universe:t.race.universe,seeded:t.race.seeded,probes:t.race.probes,seed:t.race.seed,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended,rejuvenated:!!t.race.hasOwnProperty("rejuvenated")&&t.race.rejuvenated};s>0&&(i.geck=s),r&&(i.srace=r),t.race.bigbang&&(i.bigbang=!0),t.race.gods&&(i.gods=t.race.gods),t.race.old_gods&&(i.old_gods=t.race.old_gods),t.race.rapid_mutation&&t.race.rapid_mutation>0&&(i.rapid_mutation=t.race.rapid_mutation),t.race.ancient_ruins&&t.race.ancient_ruins>0&&(i.ancient_ruins=t.race.ancient_ruins),t.race.bigbang&&(i.universe="bigbang"),t.race.hasOwnProperty("corruption")&&(i.corruption=t.race.corruption),t.race=i;let c=t.city.calendar.orbit,o=t.city.biome,n=t.city.ptrait,l=t.city.geology;t.city={calendar:{day:0,year:0,weather:2,temp:1,moon:0,wind:0,orbit:c},biome:o,ptrait:n,geology:l},t.tech.theology&&t.tech.theology>=1?t.tech={theology:1}:t.tech={},j(),t.new=!0,t.seed=Math.rand(0,1e4),t.warseed=Math.rand(0,1e4),t.stats.current=Date.now(),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()};var M={w:!1,s:!1,timers:{},resetTimers(){this.timers={main:250,mid:1e3,long:5e3}}},P={};function O(){h.forEach((function(e){"achievements"!==e&&(t.lastMsg[e]=[])}))}function C(e){let a={base:["showCiv","showCity","showIndustry","showPowerGrid","showMechLab","showShipYard","showResearch","showCivic","showMil","showResources","showMarket","showStorage","showGenetics","showSpace","showDeep","showGalactic","showPortal","showOuter","showTau","showEjector","showCargo","showAlchemy","showGovernor","arpa","showPsychic"],space:["moon","red","hell","sun","gas","gas_moon","belt","dwarf","alpha","proxima","nebula","neutron","blackhole","sirius","stargate","gateway","gorddon","alien1","alien2","chthonian","titan","enceladus","triton","eris","kuiper"],portal:["fortress","badlands","pit","ruins","gate","lake","spire"],tau:["home","red","roid","gas","gas2","star"]};Object.keys(a).forEach((function(r){"base"===r?a[r].forEach((function(a){t.settings.hasOwnProperty(a)&&!e||(t.settings[a]=!1)})):(t.settings.hasOwnProperty(r)||(t.settings[r]={}),a[r].forEach((function(a){t.settings[r].hasOwnProperty(a)&&!e||(t.settings[r][a]=!1)})))})),["civTabs","govTabs","govTabs2","hellTabs","resTabs","spaceTabs","marketTabs","statsTabs"].forEach((function(a){t.settings.hasOwnProperty(a)&&!e||(t.settings[a]=0)}))}function j(){M.w&&M.w.terminate(),t.queue={display:!1,queue:[]},t.r_queue={display:!1,queue:[]},t.space={},t.interstellar={},t.galaxy={},t.portal={},t.starDock={},t.tauceti={},t.civic={new:0},t.civic.foreign={gov0:{unrest:0,hstl:Math.floor(m(80,100)),mil:Math.floor(m(75,125)),eco:Math.floor(m(60,90)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov1:{unrest:0,hstl:Math.floor(m(0,20)),mil:Math.floor(m(125,175)),eco:Math.floor(m(80,120)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov2:{unrest:0,hstl:Math.floor(m(40,60)),mil:Math.floor(m(200,300)),eco:Math.floor(m(130,170)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1}},t.genes.blood||(t.prestige.Blood_Stone.count=0),t.resource={},t.evolution={},t.event={t:100,l:!1},t.m_event={t:499,l:!1},t.stats.days=0,t.stats.know=0,t.stats.starved=0,t.stats.died=0,t.stats.attacks=0,t.stats.dkills=0,t.stats.cfood=0,t.stats.cstone=0,t.stats.clumber=0,t.stats.sac=0,t.stats.cattle=0,t.stats.murders=0,t.settings.at=0,t.settings.showEvolve=!0,t.settings.space.home=!0,C(!0),t.settings.disableReset=!1,t.settings.pause=!1,t.arpa={},delete t.race.hrt,t.genes.queue&&(t.tech.queue=1,t.queue.display=!0)}let S;function F(e,a){let r=S[e];if(!r)return t.settings.expose&&(console.error(`string ${e} not found`),console.log(S)),e;if(a)if(a instanceof Array){for(let s=0;s{r=e})),"en-US"!=a){let e;try{$.getJSON(`strings/strings.${a}.json`,(t=>{e=t}))}catch(e){console.error(e,e.stack)}const s=r.length;e&&Object.assign(r,e),r.length!=s&&t.settings.expose&&console.error(`string.${a}.json has extra keys.`)}let s=e.getItem("string_pack")||!1;if(s&&t.settings.sPackOn){let e;try{e=JSON.parse(LZString.decompressFromUTF16(s))}catch(e){console.error(e,e.stack)}const a=r.length;e&&Object.assign(r,e),r.length!=a&&t.settings.expose&&console.error("string pack has extra keys.")}$.ajaxSetup({async:!0}),S=r}(t.settings.locale);const z={"en-US":"English (US)","es-ES":"Spanish (ESP)","pt-BR":"Português (BR)","zh-CN":"简体中文","zh-TW":"繁體中文","ko-KR":"한국어","cs-CZ":"Čeština","ru-RU":"Русский","im-PL":"Igpay-Atinlay"},A={soldier:{name:F("governor_soldier"),desc:F("governor_soldier_desc"),title:[F("governor_soldier_t1"),F("governor_soldier_t2"),F("governor_soldier_t3")],traits:{tactician:1,militant:1}},criminal:{name:F("governor_criminal"),desc:F("governor_criminal_desc"),title:[F("governor_criminal_t1"),F("governor_criminal_t2"),{m:F("governor_criminal_t3m"),f:F("governor_criminal_t3f")}],traits:{noquestions:1,racketeer:1}},entrepreneur:{name:F("governor_entrepreneur"),desc:F("governor_entrepreneur_desc"),title:[F("governor_entrepreneur_t1"),F("governor_entrepreneur_t2"),{m:F("governor_entrepreneur_t3m"),f:F("governor_entrepreneur_t3f")}],traits:{dealmaker:1,risktaker:1}},educator:{name:F("governor_educator"),desc:F("governor_educator_desc"),title:[F("governor_educator_t1"),F("governor_educator_t2"),F("governor_educator_t3")],traits:{teacher:1,theorist:1}},spiritual:{name:F("governor_spiritual"),desc:F("governor_spiritual_desc"),title:[F("governor_spiritual_t1"),F("governor_spiritual_t2"),F("governor_spiritual_t3")],traits:{inspirational:1,pious:1}},bluecollar:{name:F("governor_bluecollar"),desc:F("governor_bluecollar_desc"),title:[{m:F("governor_bluecollar_t1m"),f:F("governor_bluecollar_t1f")},F("governor_bluecollar_t2"),{m:F("governor_bluecollar_t3m"),f:F("governor_bluecollar_t3f")}],traits:{pragmatist:1,dirty_jobs:1}},noble:{name:F("governor_noble"),desc:F("governor_noble_desc"),title:[{m:F("governor_noble_t1m"),f:F("governor_noble_t1f")},{m:F("governor_noble_t2m"),f:F("governor_noble_t2f")},{m:F("governor_noble_t3m"),f:F("governor_noble_t3f")},{m:F("governor_noble_t4m"),f:F("governor_noble_t4f")}],traits:{extravagant:1,aristocrat:1}},media:{name:F("governor_media"),desc:F("governor_media_desc"),title:[F("governor_media_t1"),{m:F("governor_media_t2m"),f:F("governor_media_t2f")},F("governor_media_t3")],traits:{gaslighter:1,muckraker:1}},sports:{name:F("governor_sports"),desc:F("governor_sports_desc"),title:[F("governor_sports_t1"),F("governor_sports_t2"),F("governor_sports_t3")],traits:{athleticism:1,nopain:1}},bureaucrat:{name:F("governor_bureaucrat"),desc:F("governor_bureaucrat_desc"),title:[F("governor_bureaucrat_t1"),{m:F("governor_bureaucrat_t2m"),f:F("governor_bureaucrat_t2f")},F("governor_bureaucrat_t3")],traits:{organizer:1}}},T={tactician:{name:F("gov_trait_tactician"),effect(){return F("gov_trait_tactician_effect",[$(this)[0].vars()[0]])},vars:()=>[25]},militant:{name:F("gov_trait_militant"),effect(){return F("gov_trait_militant_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[25,10]},noquestions:{name:F("gov_trait_noquestions"),effect(){return F("gov_trait_noquestions_effect",[$(this)[0].vars()[0]])},vars:()=>[.005]},racketeer:{name:F("gov_trait_racketeer"),effect(){return F("gov_trait_racketeer_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[20,35]},dealmaker:{name:F("gov_trait_dealmaker"),effect(){return F("gov_trait_dealmaker_effect",[$(this)[0].vars()[0]])},vars:()=>[125]},risktaker:{name:F("gov_trait_risktaker"),effect(){return F("gov_trait_risktaker_effect",[$(this)[0].vars()[0]])},vars:()=>[12]},teacher:{name:F("gov_trait_teacher"),effect(){return F("gov_trait_teacher_effect",[$(this)[0].vars()[0]])},vars:()=>[6]},theorist:{name:F("gov_trait_theorist"),effect(){return F("gov_trait_theorist_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,4]},inspirational:{name:F("gov_trait_inspirational"),effect(){return F("gov_trait_inspirational_effect",[$(this)[0].vars()[0]])},vars:()=>[20]},pious:{name:F("gov_trait_pious"),effect(){let e=$(this)[0].vars()[1],a=t.tech.monument&&t.tech.monument>=3&&i.s_gate?3:1;return e=("corpocracy"===t.civic.govern.type?2*e:e)*a,F("gov_trait_pious_effect",[$(this)[0].vars()[0],e])},vars:()=>[10,5]},pragmatist:{name:F("gov_trait_pragmatist"),effect(){return F("gov_trait_pragmatist_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,2]},dirty_jobs:{name:F("gov_trait_dirty_jobs"),effect(){return F("gov_trait_dirty_jobs_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[.015,1,10]},extravagant:{name:F("gov_trait_extravagant"),effect(){return F("gov_trait_extravagant_effect",[$(this)[0].vars()[0],Is("large",!0),$(this)[0].vars()[1],$(this)[0].vars()[2]+5])},vars:()=>[10,1.25,1]},aristocrat:{name:F("gov_trait_aristocrat"),effect(){return F("gov_trait_aristocrat_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[50,20,10]},gaslighter:{name:F("gov_trait_gaslighter"),effect(){return F("gov_trait_gaslighter_effect",[$(this)[0].vars()[0],Ts(),$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[1,1,.5]},muckraker:{name:F("gov_trait_muckraker"),effect(){return F("gov_trait_muckraker_effect",[$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[8,12,3]},athleticism:{name:F("gov_trait_athleticism"),effect(){return F("gov_trait_athleticism_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2],Ts()])},vars:()=>[1.5,2,4]},nopain:{name:F("gov_trait_nopain"),effect(){return F("gov_trait_nopain_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,10]},organizer:{name:F("gov_trait_organizer"),effect(){return F("gov_trait_organizer_effect",[$(this)[0].vars()[0]])},vars:()=>[t.genes.governor&&t.genes.governor>=2?2:1]}},E={humanoid:["Sanders","Smith","Geddon","Burgundy","Cristo","Crunch","Berg","Morros","Bower","Maximus"],carnivore:["Instinct","Prowl","Paws","Fluffy","Snarl","Claws","Fang","Stalker","Pounce","Sniff"],herbivore:["Sense","Grazer","Paws","Fluffy","Fern","Claws","Fang","Grass","Stampy","Sniff"],omnivore:["Pelt","Munchy","Paws","Fluffy","Snarl","Claws","Fang","Skavers","Pounce","Sniff"],small:["Bahgins","Banks","Shorty","Parte","Underfoot","Shrimp","Finkle","Littlefoot","Cub","Runt"],giant:["Slender","Titan","Colossus","Bean","Tower","Cloud","Bigfoot","Mountain","Crusher","Megaton"],reptilian:["Scale","Chimera","Ecto","Bask","Forks","Croc","Slither","Sunny","Coldfoot","Webtoe"],avian:["Sparrow","Soar","Shiney","Raven","Squaks","Eddy","Breeze","Flap","Kettle","Flock"],insectoid:["Compound","Centi","Hiver","Buzz","Carpace","Swarm","Devour","Carpi","Chitter","Burrow"],plant:["Grover","Blossom","Leaf","Sapper","Stem","Seed","Sprout","Greensly","Root","Fruit"],fungi:["Detritus","Psychedelic","Cap","Rotface","Patch","Spore","Infecto","Filament","Symbiote","Shade"],aquatic:["Seawolf","Finsley","Inko","Sucker","McBoatFace","Wave","Riptide","Shell","Coral","Pearl"],fey:["Whisper","Prank","Mischief","Flutter","Nature","Dirt","Story","Booker","Tales","Spirit"],heat:["Ash","Magnus","Pumice","Vulcano","Sweat","Flame","Lava","Ember","Smoke","Tinder","Spark"],polar:["Frosty","Snowball","Flake","Chiller","Frost","Cooler","Icecube","Arctic","Tundra","Avalanche"],sand:["Dune","Oasis","Sarlac","Spice","Quick","Grain","Spike","Storm","Glass","Castle"],demonic:["Yekun","Kesabel","Gadreel","Penemue","Abaddon","Azazyel","Leviathan","Samyaza","Kasyade","Typhon"],angelic:["Lightbringer","Illuminous","Sparks","Chrub","Halo","Star","Pompous","Radiant","Fluffy","Fabio"],synthetic:["HK47","D2R2","Bishop","Wally","Number5","Sunny","Data","Beta","Dot","Motoko"],eldritch:["Tentacle","Faceless","Horror","Darkness","Void","Dreamer","Mindflayer","Whisper","Paranoia","Empty"]};function I(e){let a=[],r=di[t.race.species].type,s=Object.keys(A),i=JSON.parse(JSON.stringify(E[r]));e=e||s.length;for(let t=0;t');$("#r_govern1").append(e);let a=$('
        ');e.append(a);let r=$("
        ");r.append($(`
        ${F("governor_office",[t.race.governor.g.n])}
        `)),r.append($(`
        ${F("governor_background")}: ${A[t.race.governor.g.bg].name}
        `)),a.append(r),a.append($(`
        ${F("governor_fire")}
        `));let s=[0,1,2];t.genes.governor&&t.genes.governor>=2&&(s.push(s.length),N("organizer",0)&&s.push(s.length)),N("organizer",0)&&s.push(s.length),s.forEach((function(t){let a=`{{ 'none' | label }}`;Object.keys(B).forEach((function(e){B[e].req()&&(a+=`{{ '${e}' | label }}`)})),e.append(`
        ${F("gov_task",[t+1])}\n \n ${a}\n
        `)})),t.race.governor.hasOwnProperty("config")||(t.race.governor.config={});let i=$('
        ');e.append(i);{t.race.governor.config.hasOwnProperty("storage")||(t.race.governor.config.storage={crt:1e3,cnt:1e3});let e=$(`
        ${F("gov_task_storage")}
        `);i.append(e);let a=$('
        ');e.append(a);let r=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood",s="Steel";a.append($(`${F("gov_task_storage_reserve",[t.resource[r].name])}`)),a.append($(`${F("gov_task_storage_reserve",[t.resource[s].name])}`))}{t.race.governor.config.hasOwnProperty("bal_storage")||(t.race.governor.config.bal_storage={}),t.race.governor.config.bal_storage.hasOwnProperty("adv")||(t.race.governor.config.bal_storage.adv=!1);let e=$(`
        ${F("gov_task_bal_storage")}
        ${F("advanced")}
        `);i.append(e);let a=$('
        ');e.append(a),Object.keys(t.resource).forEach((function(e){t.resource[e].stackable?(t.race.governor.config.bal_storage.hasOwnProperty(e)||(t.race.governor.config.bal_storage[e]="2"),a.append($(`
        ${t.resource[e].name}\n \n 0x\n 1/2\n 1x\n 2x\n 3x\n 4x\n \n
        `))):t.race.governor.config.bal_storage.hasOwnProperty(e)&&delete t.race.governor.config.bal_storage[e]}))}{t.race.governor.config.hasOwnProperty("merc")||(t.race.governor.config.merc={buffer:1,reserve:100});let e=$(`
        ${F("gov_task_merc")}
        `);i.append(e);let a=$('
        ');e.append(a),a.append($(`${F("gov_task_merc_buffer")}`)),a.append($(`${F("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("spy")||(t.race.governor.config.spy={reserve:100});let e=$(`
        ${F("gov_task_spy")}
        `);i.append(e);let a=$('
        ');e.append(a),a.append($(`${F("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("spyop")||(t.race.governor.config.spyop={},Object.keys(t.civic.foreign).forEach((function(e){t.race.governor.config.spyop[e]="gov3"===e?["influence","sabotage"]:["sabotage","incite","influence"]})));let e=$(`
        ${F("gov_task_spyop")}
        `);i.append(e),Object.keys(t.civic.foreign).forEach((function(a){if(a.substr(3,1)<3&&!t.tech.world_control||"gov3"===a&&t.tech.rival){let r=$("
        ");e.append(r),r.append(`\n

        ${F("gov_task_spyop_priority",[ee(a.substring(3))])}

        \n
          \n `);let s=$(`#spyopConfig${a}`);t.race.governor.config.spyop[a].forEach((function(e){s.append(`\n
        • ${F("civics_spy_"+e)}
        • \n `)}))}}))}{t.race.governor.config.hasOwnProperty("tax")||(t.race.governor.config.tax={min:20});let e=$(`
          ${F("gov_task_tax")}
          `);i.append(e);let a=$('
          ');e.append(a),a.append($(`${F("gov_task_tax_min")}`))}{t.race.governor.config.hasOwnProperty("slave")||(t.race.governor.config.slave={reserve:100});let e=$(`
          ${F("gov_task_slave")}
          `);i.append(e);let a=$('
          ');e.append(a),a.append($(`${F("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("trash")||(t.race.governor.config.trash={}),["Infernite","Elerium","Copper","Iron"].forEach((function(e){t.race.governor.config.trash.hasOwnProperty(e)&&"object"==typeof t.race.governor.config.trash[e]&&null!==t.race.governor.config.trash[e]||(t.race.governor.config.trash[e]={v:0,s:!0})}));let e=$(`
          ${F("gov_task_trash")}
          `);i.append(e);let a=$('
          ');e.append(a),Object.keys(t.race.governor.config.trash).forEach((function(e){a.append($(`
          `))}))}{t.race.governor.config.hasOwnProperty("replicate")||(t.race.governor.config.replicate={}),t.race.governor.config.replicate.hasOwnProperty("pow")||(t.race.governor.config.replicate.pow={on:!1,cap:1e4,buffer:0}),t.race.governor.config.replicate.hasOwnProperty("res")||(t.race.governor.config.replicate.res={que:!0,neg:!0,cap:!0});let e=$(`
          ${F("gov_task_replicate")}
          `);i.append(e);let a=$('
          ');e.append(a),a.append($(`
          ${F("gov_task_replicate_auto")}
          `)),a.append($(`${F("gov_task_replicate_pmax")}`)),a.append($(`${F("gov_task_replicate_buff")}`));let r=$('
          ');e.append(r),r.append($(`
          ${F("gov_task_replicate_que")}
          `)),r.append($(`
          ${F("gov_task_replicate_neg")}
          `)),r.append($(`
          ${F("gov_task_replicate_cap")}
          `))}sc({el:"#govOffice",data:{t:t.race.governor.tasks,c:t.race.governor.config,r:t.resource},methods:{setTask(e,a){t.race.governor.tasks[`t${a}`]=e,Zi("govtask",{task:e}),sc({el:"#race"},"update")},showTask:e=>Object.values(t.race.governor.tasks).includes(e),activeTask(e){let a=[];return t.race.hasOwnProperty("governor")&&Object.keys(t.race.governor.tasks).forEach((function(e){"none"!==t.race.governor.tasks[e]&&a.push(t.race.governor.tasks[e])})),!a.includes(e)},showStrRes:e=>t.resource[e].display,bStrEx:()=>t.race.governor.config.bal_storage.adv?"m":"",fire(){let e=(10+(t.race.governor.hasOwnProperty("f")?t.race.governor.f:0))**2-50,a="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";t.prestige[a].count>=e&&(t.prestige[a].count-=e,t.race.governor.candidates=I(10),t.race.governor.hasOwnProperty("f")?t.race.governor.f++:t.race.governor.f=1,delete t.race.governor.g,delete t.race.governor.tasks,Ks(!1,["city-amphitheatre","city-apartment"]),Ri(),Hi(),K())},fireText(){let e=(10+(t.race.governor.hasOwnProperty("f")?t.race.governor.f:0))**2-50;return`
          ${F("governor_fire")}
          ${e} ${F("antimatter"===t.race.universe?"resource_AntiPlasmid_plural_name":"resource_Plasmid_plural_name")}
          `},trashStrat(e){t.race.governor.config.trash[e].s=!t.race.governor.config.trash[e].s},trashLabel:e=>F(t.race.governor.config.trash[e].s?"gov_task_trash_max":"gov_task_trash_min",[t.resource[e].name])},filters:{label:e=>B[e]?"string"==typeof B[e].name?B[e].name:B[e].name():F(`gov_task_${e}`)}}),Ti("govOffice",(function(){let e="";return Object.keys(A[t.race.governor.g.bg].traits).forEach((function(t){e+=(T[t].hasOwnProperty("effect")?T[t].effect():"")+" "})),e}),{elm:"#govOffice .bg"}),Object.keys(t.civic.foreign).forEach((function(e){!function(e){let a=$(`#spyopConfig${e}`)[0];a&&Sortable.create(a,{onEnd(a){let r=t.race.governor.config.spyop[e];r.splice(a.newDraggableIndex,0,r.splice(a.oldDraggableIndex,1)[0]),t.race.governor.config.spyop[e]=r,K()}})}(e)}))}():function(){let e=$('
          ');$("#r_govern1").append(e),t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("candidates")||(t.race.governor={candidates:I(10)}),e.append($(`
          ${F("governor_candidate")}${F("governor_background")}
          `));for(let a=0;a${r.t} ${r.n}${A[r.bg].name}
          `))}sc({el:"#candidates",data:t.race.governor,methods:{appoint(e){if(t.genes.governor&&t.tech.governor){let a=t.race.governor.candidates[e];t.race.governor.g=a,delete t.race.governor.candidates,t.race.governor.tasks={t0:"none",t1:"none",t2:"none",t3:"none",t4:"none",t5:"none"},Ks(!1,["city-amphitheatre","city-apartment"]),Ri(),Hi(),K(),Zi("governor",{appoint:t.race.governor.g.bg})}}}}),t.race.governor.candidates.forEach((function(e){Ti(`candidates-${e.bg}`,(function(){let t="";return Object.keys(A[e.bg].traits).forEach((function(e){t+=(T[e].hasOwnProperty("effect")?T[e].effect():"")+" "})),t}),{elm:`#candidates .${e.bg} .bg`})}))}())}function L(){Object.keys(t.civic.foreign).forEach((function(e){let t=$(`#spyopConfig${e}`)[0];if(t){let e=Sortable.get(t);e&&e.destroy()}}))}function N(e,a){return!(!t.race.hasOwnProperty("governor")||!t.race.governor.hasOwnProperty("g"))&&!!A[t.race.governor.g.bg].traits[e]&&T[e].vars()[a]}function D(e){if(t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks)for(let a=0;at.civic.taxes.display,task(){if($(this)[0].req()){let e=1;t.civic.taxes.tax_rate>=40&&(e+=.5),"oligarchy"===t.civic.govern.type&&t.civic.taxes.tax_rate>=20&&(e-=.5);let a=he("tax_cap",!1);if(t.city.morale.current<100&&t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?45:25))for(;t.city.morale.current<100&&t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?45:25);)he("adj_tax","sub");else t.city.morale.potential>=t.city.morale.cap+e&&t.civic.taxes.tax_ratet.race.governor.config.tax.min&&he("adj_tax","sub")}}},storage:{name:F("gov_task_storage"),req:()=>!!(ns("storage_yard")&&t.tech.container&&t.resource.Crates.display),task(){if($(this)[0].req()){if(t.resource.Crates.amountr&&qr("crate",Math.floor((t.resource[e].amount-r)/a))}if(ns("warehouse")&&t.resource.Containers.display&&t.resource.Containers.amounta&&qr("container",Math.floor((t.resource.Steel.amount-a)/e))}}}},bal_storage:{name:F("gov_task_bal_storage"),req:()=>!!(ns("storage_yard")&&t.tech.container&&t.resource.Crates.display),task(){if($(this)[0].req()){let e=t.resource.Crates.amount,a=e,r=t.resource.Containers.amount,s=r,i=0,c=Object.keys(t.resource).slice().reverse();c.forEach((function(a){t.resource[a].display&&t.resource[a].stackable?(e+=t.resource[a].crates,r+=t.resource[a].containers,i++):(t.resource[a].crates=0,t.resource[a].containers=0)}));let o=Math.floor(e/i),n=Math.floor(r/i),l={Food:{m:.1,cap:100},Coal:{m:.25}};t.race.artifical&&delete l.Food,Object.keys(t.race.governor.config.bal_storage).forEach((function(e){let a=Number(t.race.governor.config.bal_storage[e]);"Coal"===e?l[e]={m:.125*a}:"Food"===e?l[e]={m:.05*a,cap:50*a}:t.resource[e]&&(l[e]={m:a})})),Object.keys(l).forEach((function(a){if(t.resource[a].display)if(l[a].hasOwnProperty("cap")){i--;{let r=Math.floor(o*l[a].m);l[a].hasOwnProperty("cap")&&r>l[a].cap&&(r=l[a].cap),t.resource[a].crates=r,e-=r}if(t.resource.Containers.display){let e=Math.floor(n*l[a].m);l[a].hasOwnProperty("cap")&&e>l[a].cap&&(e=l[a].cap),t.resource[a].containers=e,r-=e}}else i+=l[a].m-1})),o=0!==i?Math.floor(e/i):0,n=0!==i?Math.floor(r/i):0,e-=Math.floor(o*i),r-=Math.floor(n*i),c.forEach((function(a){if((!l[a]||!l[a].hasOwnProperty("cap"))&&(!t.race.artifical||"Food"!==a)&&t.resource[a].display&&t.resource[a].stackable){let s=l[a]?l[a].m:1,i=Math.floor(o>0?o*s:0);if(t.resource[a].crates=i,t.resource.Containers.display){let e=Math.floor(n>0?n*s:0);t.resource[a].containers=e}if(e>0&&s>=1){let r=Math.ceil(s/2);e0&&s>=1){let e=Math.ceil(s/2);r0&&(e>0||r>0);)u--,c.forEach((function(a){l[a]&&l[a].hasOwnProperty("cap")||t.race.artifical&&"Food"===a||t.resource[a].display&&t.resource[a].stackable&&(e>0&&(t.resource[a].crates++,e--),r>0&&(t.resource[a].containers++,r--))}));t.resource.Crates.amount=e,t.resource.Containers.amount=r,i&&(t.resource.Crates.max-=a,t.resource.Containers.max-=s)}}},assemble:{name:F("gov_task_assemble"),req:()=>!(!t.race.artifical||t.tech.focus_cure&&!(t.tech.focus_cure<7)),task(){$(this)[0].req()&&t.resource[t.race.species].max>t.resource[t.race.species].amount&&Qr.city.assembly.action()}},clone:{name:F("gov_task_clone"),req:()=>!!t.tech.cloning,task(){$(this)[0].req()&&t.resource[t.race.species].max>t.resource[t.race.species].amount&&Qr.tauceti.tau_home.cloning_facility.action()}},merc:{name:F("gov_task_merc"),req:()=>!(!ns("garrison")||!t.tech.mercs),task(){if($(this)[0].req()){let e=t.resource.Money.max*(t.race.governor.config.merc.reserve/100);for(;t.civic.garrison.max>t.civic.garrison.workers+t.race.governor.config.merc.buffer&&t.resource.Money.amount>=he("m_cost")&&(t.resource.Money.amount+t.resource.Money.diff>=e||t.resource.Money.diff>=he("m_cost"));)he("m_buy")}}},spy:{name:F("gov_task_spy"),req:()=>!(t.tech.isolation||(!t.race.truepath||!t.tech.spy)&&(!t.tech.spy||t.tech.world_control||t.race.cataclysm)),task(){if($(this)[0].req()){let e=t.resource.Money.max*(t.race.governor.config.spy.reserve/100),a=t.race.truepath&&t.tech.rival?4:3;for(let r=t.tech.world_control?3:0;r=a&&(t.resource.Money.diff>=a||t.resource.Money.amount+t.resource.Money.diff>=e)&&he("t_spy",r)}}}},spyop:{name:F("gov_task_spyop"),req:()=>!(t.tech.isolation||!(t.race.truepath&&t.tech.spy&&t.tech.spy>=2)&&(!(t.tech.spy&&t.tech.spy>=2)||t.tech.world_control||t.race.cataclysm)),task(){if($(this)[0].req()){let e=t.race.truepath&&t.tech.rival?[0,1,2,3]:[0,1,2];t.tech.world_control&&(e=[3]),e.forEach((function(e){t.civic.foreign[`gov${e}`].sab<=0&&t.civic.foreign[`gov${e}`].spy>0&&!t.civic.foreign[`gov${e}`].anx&&!t.civic.foreign[`gov${e}`].buy&&!t.civic.foreign[`gov${e}`].occ&&t.race.governor.config.spyop[`gov${e}`].every((function(a){switch(a){case"influence":if(t.civic.foreign[`gov${e}`].hstl>0&&t.civic.foreign[`gov${e}`].spy>1)return he("s_influence",e),!1;break;case"sabotage":if(t.civic.foreign[`gov${e}`].mil>50)return he("s_sabotage",e),!1;break;case"incite":if(t.civic.foreign[`gov${e}`].unrest<100&&t.civic.foreign[`gov${e}`].spy>2&&e<3)return he("s_incite",e),!1}return!0}))}))}}},slave:{name:F("gov_task_slave"),req:()=>!(t.race.orbit_decayed||!ns("slave_market")||!t.race.slaver||!t.city.slave_pen),task(){let e=t.resource.Money.max*(t.race.governor.config.slave.reserve/100),a=25e3;t.race.inflation&&(a*=1+t.race.inflation/100);let r=N("extravagant",0);r&&(a*=1+r/100),$(this)[0].req()&&t.resource.Money.amount>=a&&(t.resource.Money.diff>=a||t.resource.Money.amount+t.resource.Money.diff>=e)&&4*t.city.slave_pen.count>t.city.slave_pen.slaves&&Qr.city.slave_market.action()}},sacrifice:{name:F("gov_task_sacrifice"),req:()=>!!(ns("s_alter")&&t.city.hasOwnProperty("s_alter")&&t.city.s_alter.count>=1),task(){$(this)[0].req()&&t.resource[t.race.species].amount===t.resource[t.race.species].max&&(!t.race.kindling_kindred&&!t.race.smoldering&&t.city.s_alter.harvest<=1e4||t.city.s_alter.mind<=1e4||t.city.s_alter.mine<=1e4||t.city.s_alter.rage<=1e4||t.city.s_alter.regen<=1e4)&&Qr.city.s_alter.action()}},horseshoe:{name:()=>F(`city_${Bc(!0)}`,[Bc(!1)]),req:()=>!!t.race.hooved,task(){let e=Qr.city.horseshoe.cost;if($(this)[0].req()&&Cs(e)){e=gc(Qr.city.horseshoe);let a="Copper",r=10;Object.keys(e).forEach((function(t){e[t]()>0&&(a=t,r=e[t]())})),t.resource[a].amount>r&&(t.resource[a].diff>=r||t.resource[a].amount+t.resource[a].diff>=t.resource[a].max)&&Qr.city.horseshoe.action()}}},trash:{name:F("gov_task_trash"),req:()=>!!(t.interstellar.mass_ejector&&t.interstellar.mass_ejector.count>=1),task(){let e=function(e){return"magic"===t.race.universe?Va[e]:["Elerium","Infernite"].includes(e)?10*Va[e]:Va[e]},a=1e3*i.mass_ejector;Object.keys(Va).sort(((t,a)=>e(t)0&&(i=0),t.race.governor.config.trash[e]||t.interstellar.mass_ejector.hasOwnProperty(e)&&t.resource[e].display&&t.resource[e].max>0&&t.interstellar.mass_ejector[e]+t.resource[e].diff>0&&t.resource[e].amount+s-i>=.999*t.resource[e].max-1){let r=0;if(t.resource[e].amount+s-i>=.999*t.resource[e].max-1||t.race.governor.config.trash[e]&&!t.race.governor.config.trash[e].s){const a=Math.floor(t.resource[e].diff/t.settings.gameSpeed);r=t.interstellar.mass_ejector[e]+a}t.race.governor.config.trash[e]&&r=.999*t.resource[e].max-1?r:r-Math.abs(t.race.governor.config.trash[e].v)),r>a&&(r=a),r<0&&(r=0),t.race.artifical&&"Food"===e&&(r=0),t.interstellar.mass_ejector[e]=r,a-=r}else t.interstellar.mass_ejector[e]=0})),t.interstellar.mass_ejector.total=1e3*i.mass_ejector-a}},mech:{name:F("gov_task_mech"),req:()=>!!(t.stats.achieve.hasOwnProperty("corrupted")&&t.stats.achieve.corrupted.l>0&&("prtl_spire","mechbay",Gt(ma,"prtl_spire","mechbay"))&&t.portal.hasOwnProperty("mechbay")),task(){if($(this)[0].req()){let e="large",a=ja(e,!1),r=a.c,s=a.s,i=Fa(e),c={type:{}};["small","medium","large","titan","collector"].forEach((function(e){c.type[e]=0,c[e]={chassis:{},weapon:{},equip:{}},["hover","spider","wheel","tread","biped","quad"].forEach((function(t){c[e].chassis[t]=0})),["plasma","laser","kinetic","shotgun","missile","flame","sonic","tesla"].map((e=>({sort:Math.random(),value:e}))).sort(((e,t)=>e.sort-t.sort)).map((e=>e.value)).forEach((function(t){c[e].weapon[t]=0})),["shields","flare","seals","grapple","sonar","ablative","radiator","infrared","coolant","stabilizer"].forEach((function(t){c[e].equip[t]=0}))})),t.portal.mechbay.mechs.forEach((function(e){c.type[e.size]++,c[e.size].chassis[e.chassis]++,e.hardpoint.forEach((function(t){c[e.size].weapon[t]++})),e.equip.forEach((function(t){c[e.size].equip[t]++}))})),c.type.large>=6&&c.type.small<12||c.type.large>=12&&c.type.titan>=2&&c.type.small<24?(e="small",a=ja(e,!1),r=a.c,s=a.s,i=Fa(e)):c.type.large>=6&&c.type.medium<12?(e="medium",a=ja(e,!1),r=a.c,s=a.s,i=Fa(e)):c.type.large>=12&&c.type.titan<2&&(a=ja("titan",!1),a.c<=t.portal.purifier.sup_max&&(e="titan",r=a.c,s=a.s,i=Fa(e)));let o=t.portal.mechbay.max-t.portal.mechbay.bay;if(o=3){if(t.queue.queue.some((e=>["portal-purifier","portal-port","portal-base_camp","portal-mechbay","portal-waygate"].includes(e.id))))return;for(let i=0;it.portal.purifier.sup_max&&(l=t.portal.purifier.sup_max),l>=r&&t.resource.Soul_Gem.amount+n>=s){if(t.resource.Soul_Gem.amount+=n,t.resource.Soul_Gem.amount-=s,t.portal.purifier.supply=l,t.portal.purifier.supply-=r,t.portal.mechbay.mechs[i].infernal=!0,"small"===o.size&&0===o.equip.length)t.portal.mechbay.mechs[i].equip.push("special");else if("medium"===o.size&&1===o.equip.length||"large"===o.size&&2===o.equip.length||"titan"===o.size&&o.equip.length<5){let a="???";Object.keys(c[e].equip).forEach((function(t){("???"===a||c[e].equip[t]=r&&o>=i&&t.resource.Soul_Gem.amount>=s){let a=99,o="hover";Object.keys(c[e].chassis).forEach((function(t){c[e].chassis[t]!(!t.tech.replicator||!t.race.replicator),task(){if(t.race.governor.config.replicate.pow.on){let e=t.race.governor.config.replicate.pow.cap,a=t.race.governor.config.replicate.pow.buffer;if(t.city.power0){let e=t.city.power<0?Math.abs(t.city.power)+a:a-t.city.power;t.race.replicator.pow-=e,t.race.replicator.pow<0&&(t.race.replicator.pow=0)}else t.city.power>a&&t.race.replicator.powe&&(t.race.replicator.pow=e)):t.race.replicator.pow>e&&(t.race.replicator.pow=e);t.race.replicator.pow=Math.floor(t.race.replicator.pow)}let e=!1;for(let a=0;t.race.governor.config.replicate.res.que&&at.resource[e].display)),t.race.governor.config.replicate.res.neg&&t.resource[a[0]].diff<0&&(t.resource[a[0]].amount<=.95*t.resource[a[0]].max||-1===t.resource[a[0]].max))t.race.replicator.res=a[0];else if(-1!==t.resource[t.race.replicator.res].max&&t.race.governor.config.replicate.res.cap&&t.resource[t.race.replicator.res].amount>=t.resource[t.race.replicator.res].max){let r=a.filter((e=>t.resource[e].max>0));for(let a=0;a-1===t.resource[e].max));e.length>0&&(t.race.replicator.res=e[0])}}}}}};function G(){switch(t.city.calendar.moon){case 0:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-1"):$("#moon").removeClass("wi-moon-waning-crescent-6"),$("#moon").addClass("wi-moon-new");break;case 1:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-2"):$("#moon").removeClass("wi-moon-new"),$("#moon").addClass("wi-moon-waxing-crescent-1");break;case 2:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-3"):$("#moon").removeClass("wi-moon-waxing-crescent-1"),$("#moon").addClass("wi-moon-waxing-crescent-2");break;case 3:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-4"):$("#moon").removeClass("wi-moon-waxing-crescent-2"),$("#moon").addClass("wi-moon-waxing-crescent-3");break;case 4:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-5"):$("#moon").removeClass("wi-moon-waxing-crescent-3"),$("#moon").addClass("wi-moon-waxing-crescent-4");break;case 5:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-crescent-6"):$("#moon").removeClass("wi-moon-waxing-crescent-4"),$("#moon").addClass("wi-moon-waxing-crescent-5");break;case 6:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-first-quarter"):$("#moon").removeClass("wi-moon-waxing-crescent-5"),$("#moon").addClass("wi-moon-waxing-crescent-6");break;case 7:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-1"):$("#moon").removeClass("wi-moon-waxing-crescent-6"),$("#moon").addClass("wi-moon-first-quarter");break;case 8:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-2"):$("#moon").removeClass("wi-moon-first-quarter"),$("#moon").addClass("wi-moon-waxing-gibbous-1");break;case 9:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-3"):$("#moon").removeClass("wi-moon-waxing-gibbous-1"),$("#moon").addClass("wi-moon-waxing-gibbous-2");break;case 10:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-4"):$("#moon").removeClass("wi-moon-waxing-gibbous-2"),$("#moon").addClass("wi-moon-waxing-gibbous-3");break;case 11:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-5"):$("#moon").removeClass("wi-moon-waxing-gibbous-3"),$("#moon").addClass("wi-moon-waxing-gibbous-4");break;case 12:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waxing-gibbous-6"):$("#moon").removeClass("wi-moon-waxing-gibbous-4"),$("#moon").addClass("wi-moon-waxing-gibbous-5");break;case 13:rc($("#moon")),t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-full"):$("#moon").removeClass("wi-moon-waxing-gibbous-5"),$("#moon").addClass("wi-moon-waxing-gibbous-6");break;case 14:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-1"):$("#moon").removeClass("wi-moon-waxing-gibbous-6");let e=$c(2);e.length>0?$("#moon").append(e):$("#moon").addClass("wi-moon-full");break;case 15:rc($("#moon")),t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-2"):$("#moon").removeClass("wi-moon-full"),$("#moon").addClass("wi-moon-waning-gibbous-1");break;case 16:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-3"):$("#moon").removeClass("wi-moon-waning-gibbous-1"),$("#moon").addClass("wi-moon-waning-gibbous-2");break;case 17:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-4"):$("#moon").removeClass("wi-moon-waning-gibbous-2"),$("#moon").addClass("wi-moon-waning-gibbous-3");break;case 18:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-5"):$("#moon").removeClass("wi-moon-waning-gibbous-3"),$("#moon").addClass("wi-moon-waning-gibbous-4");break;case 19:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-gibbous-6"):$("#moon").removeClass("wi-moon-waning-gibbous-4"),$("#moon").addClass("wi-moon-waning-gibbous-5");break;case 20:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-third-quarter"):$("#moon").removeClass("wi-moon-waning-gibbous-5"),$("#moon").addClass("wi-moon-waning-gibbous-6");break;case 21:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-1"):$("#moon").removeClass("wi-moon-waning-gibbous-6"),$("#moon").addClass("wi-moon-third-quarter");break;case 22:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-2"):$("#moon").removeClass("wi-moon-third-quarter"),$("#moon").addClass("wi-moon-waning-crescent-1");break;case 23:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-3"):$("#moon").removeClass("wi-moon-waning-crescent-1"),$("#moon").addClass("wi-moon-waning-crescent-2");break;case 24:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-4"):$("#moon").removeClass("wi-moon-waning-crescent-2"),$("#moon").addClass("wi-moon-waning-crescent-3");break;case 25:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-5"):$("#moon").removeClass("wi-moon-waning-crescent-3"),$("#moon").addClass("wi-moon-waning-crescent-4");break;case 26:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-waning-crescent-6"):$("#moon").removeClass("wi-moon-waning-crescent-4"),$("#moon").addClass("wi-moon-waning-crescent-5");break;case 27:t.city.ptrait.includes("retrograde")?$("#moon").removeClass("wi-moon-new"):$("#moon").removeClass("wi-moon-waning-crescent-5"),$("#moon").addClass("wi-moon-waning-crescent-6")}let e;$("#temp").removeClass("wi-thermometer"),$("#temp").removeClass("wi-thermometer-exterior"),0===t.city.calendar.temp?$("#temp").addClass("wi-thermometer-exterior"):2===t.city.calendar.temp&&$("#temp").addClass("wi-thermometer"),$("#weather").removeClass("wi-day-sunny"),$("#weather").removeClass("wi-day-windy"),$("#weather").removeClass("wi-cloud"),$("#weather").removeClass("wi-cloudy-gusts"),$("#weather").removeClass("wi-rain"),$("#weather").removeClass("wi-storm-showers"),$("#weather").removeClass("wi-snow"),$("#weather").removeClass("wi-snow-wind"),0===t.city.calendar.weather?e=0===t.city.calendar.temp?0===t.city.calendar.wind?"wi-snow":"wi-snow-wind":0===t.city.calendar.wind?"wi-rain":"wi-storm-showers":1===t.city.calendar.weather?e=0===t.city.calendar.wind?"wi-cloud":"wi-cloudy-gusts":2===t.city.calendar.weather&&(e=0===t.city.calendar.wind?"wi-day-sunny":"wi-day-windy"),$("#weather").addClass(e)}function R(e){switch(e){case"moon":return t.race.orbit_decayed?F("moon0"):0===t.city.calendar.moon?F("moon1"):t.city.calendar.moon>0&&t.city.calendar.moon<7?F("moon2"):7===t.city.calendar.moon?F("moon3"):t.city.calendar.moon>7&&t.city.calendar.moon<14?F("moon4"):14===t.city.calendar.moon?F("moon5"):t.city.calendar.moon>14&&t.city.calendar.moon<21?F("moon6"):21===t.city.calendar.moon?F("moon7"):t.city.calendar.moon>21?F("moon8"):void 0;case"weather":return function(){switch(t.city.calendar.weather){case 0:return 0===t.city.calendar.temp?1===t.city.calendar.wind?F("snowstorm"):F("snow"):1===t.city.calendar.wind?F("thunderstorm"):F("rain");case 1:return 1===t.city.calendar.wind?F("cloudy_windy"):F("cloudy");case 2:return 1===t.city.calendar.wind?F("sunny_windy"):F("sunny")}}();case"temp":return function(){switch(t.city.calendar.temp){case 0:return F("cold");case 1:return F("moderate");case 2:return F("hot")}}();case"sign":return function(){let e=U(),t=`
          ${F("sign_description",[F(`sign_${e}`),F(`sign_${e}_desc`)])}
          `;return t+=`
          ${function(e){return"pisces"===e||"cancer"===e?F(`sign_${e}_effect`):F(`sign_${e}_effect`,[H(e)[0]])}(e)}
          `,t}();case"astrology":return F(`sign_${U()}_symbol`)}}function H(e){switch(e){case"aries":case"capricorn":return[10];case"taurus":return[2];case"gemini":case"aquarius":return[20];case"cancer":case"sagittarius":return[5];case"leo":return[4];case"virgo":return[15];case"libra":return[25];case"scorpio":return[12,1];case"pisces":return[49,25]}}function U(){const e=new Date;return 0===e.getMonth()&&e.getDate()>=20||1===e.getMonth()&&e.getDate()<=18?"aquarius":1===e.getMonth()&&e.getDate()>=19||2===e.getMonth()&&e.getDate()<=20?"pisces":2===e.getMonth()&&e.getDate()>=21||3===e.getMonth()&&e.getDate()<=19?"aries":3===e.getMonth()&&e.getDate()>=20||4===e.getMonth()&&e.getDate()<=20?"taurus":4===e.getMonth()&&e.getDate()>=21||5===e.getMonth()&&e.getDate()<=21?"gemini":5===e.getMonth()&&e.getDate()>=22||6===e.getMonth()&&e.getDate()<=22?"cancer":6===e.getMonth()&&e.getDate()>=23||7===e.getMonth()&&e.getDate()<=22?"leo":7===e.getMonth()&&e.getDate()>=23||8===e.getMonth()&&e.getDate()<=22?"virgo":8===e.getMonth()&&e.getDate()>=23||9===e.getMonth()&&e.getDate()<=22?"libra":9===e.getMonth()&&e.getDate()>=23||10===e.getMonth()&&e.getDate()<=22?"scorpio":10===e.getMonth()&&e.getDate()>=23||11===e.getMonth()&&e.getDate()<=21?"sagittarius":11===e.getMonth()&&e.getDate()>=22||0===e.getMonth()&&e.getDate()<=19?"capricorn":"time itself is broken"}function W(){M.w&&M.w.terminate(),O(),Zi("reset",{end:"descension"}),Xc("squished",!0),Xc(`extinct_${t.race.species}`),t.race.witch_hunter&&"magic"===t.race.universe?Xc("nightmare"):Xc("corrupted"),"angelic"===di[t.race.species].type&&eo("twisted"),t.race.junker&&"junker"===t.race.species&&eo("the_misery"),!t.race.modified&&t.race.junker&&"junker"===t.race.species&&eo("garbage_pie"),t.race.cataclysm&&eo("finish_line"),t.race.ooze&&"sludge"===t.race.species&&eo("slime_lord");let a=mc("descend");t.prestige.Artifact.count+=a.artifact,t.stats.artifact+=a.artifact;let r=Yc();t.stats.spire.hasOwnProperty(r)&&(t.stats.spire[r].hasOwnProperty("lord")?t.stats.spire[r].lord++:t.stats.spire[r].lord=1,t.tech.dl_reset?t.stats.spire[r].dlstr=0:t.stats.spire[r].hasOwnProperty("dlstr")?t.stats.spire[r].dlstr++:t.stats.spire[r].dlstr=1);let s=t.race.species,i=t.race.gods,c=t.city.calendar.orbit,o=t.city.biome,n=t.city.ptrait,l=t.city.geology;t.stats.descend++,Fc(),so();let u=!!t.race.hasOwnProperty("srace")&&t.race.srace;t.race={species:"protoplasm",gods:s,old_gods:i,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),corruption:5,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},u&&(t.race.srace=u),Q({orbit:c,biome:o,ptrait:n,geology:l}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}function Q(e){t.city={calendar:{day:0,year:0,weather:2,temp:1,moon:0,wind:0,orbit:e.orbit},biome:e.biome,ptrait:e.ptrait},e.geology&&(t.city.geology=e.geology),t.tech={theology:1},j(),t.new=!0,t.seed=Math.rand(0,1e4)}function Z(){let e=Yc();t.race.womling_friend?("m"!==e&&t.stats.womling.friend.l++,"l"!==e&&(t.stats.womling.friend.hasOwnProperty(e)||(t.stats.womling.friend[e]=0),t.stats.womling.friend[e]++)):t.race.womling_lord?("m"!==e&&t.stats.womling.lord.l++,"l"!==e&&(t.stats.womling.lord.hasOwnProperty(e)||(t.stats.womling.lord[e]=0),t.stats.womling.lord[e]++)):t.race.womling_god&&("m"!==e&&t.stats.womling.god.l++,"l"!==e&&(t.stats.womling.god.hasOwnProperty(e)||(t.stats.womling.god[e]=0),t.stats.womling.god[e]++)),t.stats.womling.friend.l>0&&t.stats.womling.lord.l>0&&t.stats.womling.god.l>0&&Xc("overlord","m"===e,ro(),"l"),t.stats.womling.friend[e]>0&&t.stats.womling.lord[e]>0&&t.stats.womling.god[e]>0&&Xc("overlord","m"===e,ro(),e)}function V(e){if(t.civic.taxes||(t.civic.taxes={tax_rate:20,display:!1}),!e&&(t.settings.tabLoad||2===t.settings.civTabs&&0===t.settings.govTabs)){var a=$('
          '),r=$(`\n \n \n \n \n \n \n `);a.append(r),$("#r_civics").append(a),sc({el:"#government .govTabs2",data:{t:t.civic.taxes,s:t.settings},methods:{vis:()=>!!t.tech.govern}}),function(e){var a=$('
          ');e.append(a);var r=$(`
          ${F("civics_government_type")} {{ type | govern }}
          `);a.append(r);var s=$("
          ");a.append(s);var i=$('');s.append(i);var c={template:''};sc({el:"#govType",data:t.civic.govern,filters:{govern:e=>F(`govern_${e}`),set:e=>F("anarchy"===e?"civics_set_gov":"civics_revolution")},methods:{trigModal(){this.$buefy.modal.open({parent:this,component:c});var e=setInterval((function(){$("#modalBox").length>0&&(clearInterval(e),function(){$("#modalBox").append($(`

          ${F("civics_government_type")}

          `));let e=$c(6,10);e.length>0&&$("#modalBoxTitle").append(e);let a=kc(6,14,!1);a.length>0&&$("#modalBoxTitle").append(a);var r=$('
          ');$("#modalBox").append(r),t.tech.govern&&("autocracy"!==t.civic.govern.type&&r.append($(``)),"democracy"!==t.civic.govern.type&&r.append($(``)),"oligarchy"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_theo&&"theocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.govern>=2&&"republic"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_soc&&"socialist"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_corp&&"corpocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.govern>=3&&"technocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_fed&&"federation"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_mage&&"magocracy"!==t.civic.govern.type&&r.append($(``))),sc({el:"#govModal",data:t.civic.govern,methods:{setGov(e){if(0===t.civic.govern.rev){let a=t.genes.governor&&"anarchy"===t.civic.govern.type;t.civic.govern.type=e;let r=1e3;t.tech.high_tech&&(r+=250,t.tech.high_tech>=3&&(r+=250),t.tech.high_tech>=6&&(r+=250)),t.tech.space_explore&&t.tech.space_explore>=3&&(r+=250),t.race.unorganized&&(r=Math.round(r*(1+ui.unorganized.vars()[0]/100))),t.stats.achieve.anarchist&&(r=Math.round(r*(1-t.stats.achieve.anarchist.l/10))),t.race.lawless&&(r=Math.round(r/(100-ui.lawless.vars()[0])));let s=Pi("tuskin");s>0&&(r=Math.round(r/(100-ui.lawless.vars(1)[0]*s)));let i=N("aristocrat",0);i&&(r=Math.round(r*(1-i/100))),t.civic.govern.rev=r+t.civic.govern.fr,a&&ms(),sc({el:"#govModal"},"destroy"),$(".modal-background").click(),Ei()}}}}),Ti("GovPop",(function(e){let a=$(e.this).data("gov"),r=t.tech.unify&&t.tech.unify>=2&&"federation"===a?"federation_alt":a;return"theocracy"===r&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display&&(r="theocracy_alt"),$(`
          ${re(a)}
          ${te()[r]}
          `)}),{elm:"#govModal button",self:!0,classes:"has-background-light has-text-dark"})}())}),50)},startrev(){t.civic.govern.fr=t.civic.govern.rev,t.civic.govern.rev=0},force:()=>t.civic.govern.rev>0?F("civics_force_rev_desc"):F("civics_force_rev_desc2"),vis:()=>!!t.tech.govern}}),Ti("govLabel",(function(){let e=t.tech.unify&&t.tech.unify>=2&&"federation"===t.civic.govern.type?"federation_alt":t.civic.govern.type;return"theocracy"===e&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display&&(e="theocracy_alt"),$(`
          ${re(t.civic.govern.type)}
          ${te()[e]}
          `)})),Ti("govTypeChange",(function(){return t.civic.govern.rev>0?F("civics_change_desc",[t.civic.govern.rev]):F("civics_change_desc2")}),{elm:"#govType .change"})}($("#r_govern0")),function(e){var a=$('
          ');e.append(a);var r=$(`

          ${F("civics_tax_rates")}

          `);a.append(r);var s=$(''),i=$('«'),c=$('»');a.append(i),a.append(s),a.append(c),sc({el:"#tax_rates",data:t.civic.taxes,filters:{tax_level(e){let a=$c(11,14),r=kc(2,14,!1);return a.length>0&&(0===e&&!t.race.noble||10===e&&t.race.noble)?a:13===e&&r.length>0?r:`${e}%`}},methods:{add(){pe("add")},sub(){pe("sub")}}}),Ti("taxRateLabel",(function(){return F("civics_tax_rates_desc")}),{classes:"has-background-light has-text-dark"})}($("#r_govern0"));var s=$('
          ');$("#r_govern0").append(s),K()}}function J(){if(Y(),t.settings.tabLoad||2===t.settings.civTabs&&3===t.settings.govTabs){var a=$('
          ');$("#military").append(a),$("#military").append($('
          ')),fe(a,!0),function(){if(t.race.sludge)return!1;if(0===$("#mad").length){let s="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");var a=$('
          ');$("#military").append(a);var r=$('
          ');a.append(r),r.append($(`
          ${F("civics_mad_reset_desc",[s])}
          `));let i=!(!t.race.hrt||!["wolven","vulpine"].includes(t.race.hrt));r.append($(`
          `)),r.append($(`
          `)),t.civic.mad.armed||($("#mad").addClass("armed"),$("#mad .arm").html(F(i?"civics_mad_disarm_grenades":"civics_mad_disarm_missiles"))),sc({el:"#mad",data:t.civic.mad,methods:{launch(){if(!t.civic.mad.armed&&!t.race.cataclysm){$("body").addClass("nuke");let a=$('
          ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),500),setTimeout((function(){a.addClass("b")}),600),setTimeout((function(){!function(){if(!t.civic.mad.armed&&!t.race.cataclysm){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"mad"});let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=t.city.geology,n=mc("mad");t.stats.mad++,Fc(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=n.plasmid,t.stats.antiplasmid+=n.plasmid):(t.prestige.Plasmid.count+=n.plasmid,t.stats.plasmid+=n.plasmid),Xc("apocalypse"),Xc("squished",!0),Xc(`extinct_${a}`),"anarchy"===t.civic.govern.type&&Xc("anarchist"),"hellscape"===t.city.biome&&"demonic"!==di[t.race.species].type&&eo("take_no_advice"),t.race.truepath&&Xc("ashanddust"),so();let l=!!t.race.hasOwnProperty("srace")&&t.race.srace,u=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,rapid_mutation:1,ancient_ruins:1,universe:t.race.universe,seeded:!1,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},u>0&&(t.race.corruption=u),l&&(t.race.srace=l),Q({orbit:s,biome:i,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}}()}),4e3)}},arm(){t.civic.mad.armed?($("#mad .arm").html(F(i?"civics_mad_disarm_grenades":"civics_mad_disarm_missiles")),t.civic.mad.armed=!1,$("#mad").addClass("armed")):($("#mad .arm").html(F(i?"civics_mad_arm_grenades":"civics_mad_arm_missiles")),t.civic.mad.armed=!0,$("#mad").removeClass("armed"))}}}),["mdarm","mdlaunch"].forEach((function(e){Ti(`mad${e}`,(function(){return"{{ label() }}"}),{elm:`#mad .${e}`,in:function(a){sc({el:`#${a.id} > span`,data:{test:"val"},methods:{label(){switch(e){case"mdarm":return t.tech.world_control&&!t.race.truepath?F("civics_mad_missiles_world_control_desc"):F(i?"civics_mad_missiles_desc_easter":"civics_mad_missiles_desc");case"mdlaunch":{let e=mc("mad"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return F("civics_mad_missiles_warning",[e.plasmid,a])}}}}})},out:function(e){sc({el:`#${e.id} > span`},"destroy")}})}))}}()}}function Y(){t.civic.garrison||(t.civic.garrison={display:!1,disabled:!1,rate:0,progress:0,tactic:0,workers:0,wounded:0,raid:0,max:0}),t.civic.garrison.mercs||(t.civic.garrison.mercs=!1),t.civic.garrison.fatigue||(t.civic.garrison.fatigue=0),t.civic.garrison.protest||(t.civic.garrison.protest=0),t.civic.garrison.m_use||(t.civic.garrison.m_use=0),t.civic.garrison.crew||(t.civic.garrison.crew=0),t.civic.mad||(t.civic.mad={display:!1,armed:!0})}function X(e){if(t.race.truepath){if(t.civic.foreign[`gov${e}`].hstl<10)return 1+(10-t.civic.foreign[`gov${e}`].hstl)/40;if(t.civic.foreign[`gov${e}`].hstl>60)return 1-(-60+t.civic.foreign[`gov${e}`].hstl)/160}return 1}function ee(e){if(void 0===t.civic.foreign[`gov${e}`].name){let a=Ji();t.civic.foreign[`gov${e}`].name={s0:a.s0,s1:a.s1}}return F(`civics_gov${t.civic.foreign[`gov${e}`].name.s0}`,[t.civic.foreign[`gov${e}`].name.s1])}const te=function(){return{anarchy:F("govern_anarchy_effect"),autocracy:F("govern_autocracy_effect",ae.autocracy()),democracy:F("govern_democracy_effect",ae.democracy()),oligarchy:t.tech.high_tech&&t.tech.high_tech>=12?F("govern_oligarchy_effect_alt",[ae.oligarchy()[1]]):F("govern_oligarchy_effect",[ae.oligarchy()[0],ae.oligarchy()[1]]),theocracy:F("govern_theocracy_effect",ae.theocracy()),theocracy_alt:F("govern_theocracy_effect_alt",ae.theocracy()),republic:F("govern_republic_effect",ae.republic()),socialist:F("govern_socialist_effect",ae.socialist()),corpocracy:F("govern_corpocracy_effect",ae.corpocracy()),technocracy:t.tech.high_tech&&t.tech.high_tech>=16?F("govern_technocracy_effect_alt",[ae.technocracy()[0],ae.technocracy()[2]]):F("govern_technocracy_effect",ae.technocracy()),federation:F("govern_federation_effect",[ae.federation()[0],ae.federation()[1]]),federation_alt:F("govern_federation_effect_alt",[25,ae.federation()[2],ae.federation()[1]]),magocracy:F("govern_magocracy_effect",ae.magocracy())}},ae={autocracy:()=>[t.tech.high_tech&&t.tech.high_tech>=2?t.tech.high_tech>=12?10:18:25,N("organizer",0)?40:35],democracy:()=>[t.tech.high_tech&&t.tech.high_tech>=2?t.tech.high_tech>=12?30:25:20,N("organizer",0)?1:5],oligarchy:()=>[t.tech.high_tech&&t.tech.high_tech>=12?0:t.tech.high_tech&&t.tech.high_tech>=2?2:5,N("organizer",0)?25:20],theocracy:()=>[12,N("organizer",0)?10:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?25:40:50],republic:()=>[N("organizer",0)?30:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?40:30:20],socialist:()=>[t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?50:42:35,N("organizer",0)?12:10,10,N("organizer",0)?10:20],corpocracy:()=>[N("organizer",0)?220:200,N("organizer",0)?175:150,N("organizer",0)?110:100,t.tech.high_tech&&t.tech.high_tech>=12?5:10,t.tech.high_tech&&t.tech.high_tech>=16?40:30],technocracy:()=>[8,t.tech.high_tech&&t.tech.high_tech>=16?0:t.tech.high_tech&&t.tech.high_tech>=12?1:2,N("organizer",0)?18:10],federation:()=>[3,N("organizer",0)?12:10,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?40:36:32],magocracy:()=>[N("organizer",0)?30:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?50:40:25]};function re(e){return t.race.witch_hunter&&"magocracy"===e?F("witch_hunter_magocracy"):F(`govern_${e}_desc`)}function se(){if(0===$("#foreign").length&&!t.race.cataclysm&&(!t.tech.world_control||t.race.truepath)&&!t.tech.isolation){let a=$('
          ');a.append($(`

          ${F("civics_foreign")}

          `)),$("#r_govern0").append(a);var e={template:''};let r=t.race.truepath?5:3;for(let e=0;e{{ '${e}' | gov }} - ${F("civics_garrison_occupy")} - ${F("civics_garrison_annex")} - ${F("civics_garrison_purchase")}
          `);a.append(t);let r=$("
          ");r.append($(``)),r.append($(``)),r.append($(``)),t.append(r),t.append($(`
          ${F("civics_gov_mil_rate")}: {{ f${e}.mil | military(${e}) }} ({{ f${e}.mil }})
          `)),t.append($(`
          ${F("civics_gov_relations")}: {{ f${e}.hstl | relation }} ({{ f${e}.hstl | hate }})
          `)),t.append($(`
          ${F("civics_gov_eco_rate")}: {{ f${e}.eco | eco(${e}) }} ({{ f${e}.eco }})
          `)),t.append($(`
          ${F("civics_gov_unrest")}: {{ f${e}.unrest | discontent(${e}) }} ({{ f${e}.unrest | turmoil }})
          `))}let s={f0:t.civic.foreign.gov0,f1:t.civic.foreign.gov1,f2:t.civic.foreign.gov2,t:t.tech,s:t.settings};t.race.truepath&&(s.f3=t.civic.foreign.gov3,s.f4=t.civic.foreign.gov4),sc({el:"#foreign",data:s,filters:{military:(e,a)=>t.civic.foreign[`gov${a}`].spy>=1?F(e<50?"civics_gov_v_weak":e<75?"civics_gov_weak":e>300?"civics_gov_superpower":e>200?"civics_gov_v_strong":e>160?"civics_gov_strong":e>125?"civics_gov_above_average":"civics_gov_average"):"???",relation:e=>F(e>80?"civics_gov_hated":e>60?"civics_gov_hostile":e>40?"civics_gov_poor":e>25?"civics_gov_neutral":e>10?"civics_gov_liked":"civics_gov_good"),eco:(e,a)=>t.civic.foreign[`gov${a}`].spy>=2?F(e<60?"civics_gov_weak":e<80?"civics_gov_recession":e>120?"civics_gov_strong":"civics_gov_average"):"???",discontent:(e,a)=>t.civic.foreign[`gov${a}`].spy>=3?F(e<=0?"civics_gov_none":e<30?"civics_gov_low":e<60?"civics_gov_medium":e<90?"civics_gov_high":"civics_gov_extreme"):"???",gov:e=>ee(e),sab:e=>"none"===e?"":F(`civics_spy_${e}`),hate:e=>100-e+"%",turmoil:e=>`${e}%`},methods:{campaign(e){be(e)},battleAssessment:e=>ye(e),trigModal(a){this.$buefy.modal.open({parent:this,component:e});var r=setInterval((function(){$("#modalBox").length>0&&(clearInterval(r),function(e){$("#modalBox").append($(`

          ${F("civics_espionage_actions")}

          `));var a=$('
          ');$("#modalBox").append(a),t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(a.append($(``)),a.append($(``)),e<3&&a.append($(``)),e<3&&t.civic.foreign[`gov${e}`].hstl<=50&&t.civic.foreign[`gov${e}`].unrest>=50&&a.append($(``)),e<3&&t.civic.foreign[`gov${e}`].spy>=3&&a.append($(``))),sc({el:"#espModal",data:t.civic.foreign[`gov${e}`],methods:{influence(e){t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(de("influence",e),sc({el:"#espModal"},"destroy"),$(".modal-background").click(),Ei())},sabotage(e){t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(de("sabotage",e),sc({el:"#espModal"},"destroy"),$(".modal-background").click(),$("#popGov").hide(),Ei())},incite(e){e>=3||t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(de("incite",e),sc({el:"#espModal"},"destroy"),$(".modal-background").click(),Ei())},annex(a){if(!(a>=3)&&t.civic.foreign[`gov${e}`].hstl<=50&&t.civic.foreign[`gov${e}`].unrest>=50&&t.city.morale.current>=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest&&t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&t.civic.foreign[`gov${a}`].sab<=0){let e=t.tech.spy>=4?150:300;t.race.befuddle&&(e=Math.round(e*(1-ui.befuddle.vars()[0]/100)));let r=Pi("dryad");r>0&&(e=Math.round(e*(1-ui.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="annex",sc({el:"#espModal"},"destroy"),$(".modal-background").click(),Ei()}},purchase(e){if(e>=3)return;let a=le(e);if(a<=t.resource.Money.amount&&t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=3&&t.civic.foreign[`gov${e}`].sab<=0){t.resource.Money.amount-=a;let r=t.tech.spy>=4?150:300;t.race.befuddle&&(r=Math.round(r*(1-ui.befuddle.vars()[0]/100)));let s=Pi("dryad");s>0&&(r=Math.round(r*(1-ui.befuddle.vars(1)[0]/100*s))),t.civic.foreign[`gov${e}`].sab=r,t.civic.foreign[`gov${e}`].act="purchase",sc({el:"#espModal"},"destroy"),$(".modal-background").click(),Ei()}}}}),Ti("GovLabel",(function(a){let r=$(a.this).data("esp"),s="";if("purchase"===r){let t=le(e).toLocaleString();s=F(`civics_spy_${r}_desc`,[ee(e),t])}else if("annex"===r)if(t.city.morale.current>=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest)s=F(`civics_spy_${r}_desc`,[ee(e)]);else{let a=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest;s=F(`civics_spy_${r}_goal`,[ee(e),a])}else s=F(`civics_spy_${r}_desc`,[ee(e)]);let i="";return("influence"===r&&0===t.civic.foreign[`gov${e}`].hstl||"sabotage"===r&&t.civic.foreign[`gov${e}`].spy>=2&&50===t.civic.foreign[`gov${e}`].mil||"incite"===r&&t.civic.foreign[`gov${e}`].spy>=4&&100===t.civic.foreign[`gov${e}`].unrest)&&(i=`
          ${F("civics_spy_warning")}
          `),$(`${i}
          ${s}
          `)}),{elm:"#espModal button",self:!0,classes:"has-background-light has-text-dark"})}(a))}),50)},spy_disabled:e=>t.civic.foreign[`gov${e}`].trn>0||oe(e)>t.resource.Money.amount,spy(e){ne(e)},spyDesc:e=>ie(e),espDesc:()=>ce(),vis:()=>!(!t.civic.garrison.display||t.tech.world_control&&!t.race.truepath||t.race.cataclysm||t.tech.isolation),gvis:e=>!t.tech.isolation&&(e<=2?!t.tech.world_control:3===e&&!!t.tech.rival)}});for(let e=0;e{{ label() }}"}),{elm:`#gov${e} .attack`,in:function(t){sc({el:`#${t.id} > span`,data:{test:"val"},methods:{label:()=>ye(e)}})},out:function(e){sc({el:e.id},"destroy")}}),Ti(`gov${e}ts`,(function(){return"{{ label() }}"}),{elm:`#gov${e} .tspy`,in:function(t){sc({el:`#${t.id} > span`,data:{test:"val"},methods:{label:()=>ie(e)}})},out:function(e){sc({el:e.id},"destroy")}}),Ti(`gov${e}s`,(function(){return ce()}),{elm:`#gov${e} .sspy`});t.race.truepath&&Ti("garRivaldesc1",(function(){return F("civics_gov_tp_rival",[ee(3),di[t.race.species].home])}),{elm:"#gov3 > span"})}}function ie(e){return t.civic.foreign[`gov${e}`].trn>0?F("civics_progress"):F("civics_gov_spy_desc",[k(oe(e))])}function ce(){return F("civics_gov_esp_desc")}function oe(e){let a=Math.round(t.civic.foreign[`gov${e}`].mil/2+t.civic.foreign[`gov${e}`].hstl/2-t.civic.foreign[`gov${e}`].unrest)+10;return a<50&&(a=50),t.race.infiltrator&&(a/=3),"scorpio"===U()&&(a*=1-H("scorpio")[0]/100),Math.round(a**(t.civic.foreign[`gov${e}`].spy+1))+500}function ne(e){if(t.tech.spy&&t.civic.foreign[`gov${e}`].trn<=0){let a=oe(e);if(t.resource.Money.amount>=a){t.resource.Money.amount-=a;let r=300;t.tech.spy>=3&&t.city.boot_camp&&(r-=10*(t.race.orbit_decayed&&t.space.space_barracks?t.space.space_barracks.on:t.city.boot_camp.count),r<10&&(r=10)),t.race.infiltrator&&(r=Math.round(r/2)),t.civic.foreign[`gov${e}`].trn=r}}}function le(e){let a=15384*t.civic.foreign[`gov${e}`].eco;return a*=1+1.6*t.civic.foreign[`gov${e}`].hstl/100,a*=1-.25*t.civic.foreign[`gov${e}`].unrest/100,+a.toFixed(0)}function ue(e){return e?t.tech.world_control||t.civic.foreign[e].occ||t.civic.foreign[e].anx||t.civic.foreign[e].buy:t.civic.foreign.gov0.occ||t.civic.foreign.gov1.occ||t.civic.foreign.gov2.occ||t.civic.foreign.gov0.anx||t.civic.foreign.gov1.anx||t.civic.foreign.gov2.anx||t.civic.foreign.gov0.buy||t.civic.foreign.gov1.buy||t.civic.foreign.gov2.buy}function de(e,a){switch(e){case"influence":if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&t.civic.foreign[`gov${a}`].sab<=0){let e=t.tech.spy>=4?200:300;t.race.befuddle&&(e=Math.round(e*(1-ui.befuddle.vars()[0]/100)));let r=Pi("dryad");r>0&&(e=Math.round(e*(1-ui.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="influence"}break;case"sabotage":if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&t.civic.foreign[`gov${a}`].sab<=0){let e=t.tech.spy>=4?400:600;t.race.befuddle&&(e=Math.round(e*(1-ui.befuddle.vars()[0]/100)));let r=Pi("dryad");r>0&&(e=Math.round(e*(1-ui.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="sabotage"}break;case"incite":if(a>=3)break;if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&t.civic.foreign[`gov${a}`].sab<=0){let e=t.tech.spy>=4?600:900;t.race.befuddle&&(e=Math.round(e*(1-ui.befuddle.vars()[0]/100)));let r=Pi("dryad");r>0&&(e=Math.round(e*(1-ui.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="incite"}}}function _e(e){let a=!!(t.tech.currency&&t.tech.currency>=5);if(e)return!a&&!t.race.terrifying||t.race.noble?t.race.noble?ui.noble.vars()[0]:10:0;{let e=30;t.race.noble?e=ui.noble.vars()[1]:(a||t.race.terrifying)&&(e+=20),"oligarchy"===t.civic.govern.type&&(e+=ae.oligarchy()[1]);let r=N("aristocrat",1);return r&&(e+=r),e}}function pe(e,a){switch(e){case"add":{let e=a||y(),r=_e(!1);t.race.noble?(t.civic.taxes.tax_rate+=e,t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?40:20)&&(t.civic.taxes.tax_rate="oligarchy"===t.civic.govern.type?40:20)):t.civic.taxes.tax_rater&&(t.civic.taxes.tax_rate=r))}break;case"sub":{let e=a||y(),r=_e(!0);t.civic.taxes.tax_rate>r&&(t.civic.taxes.tax_rate-=e,t.civic.taxes.tax_rate25e3&&(e=25e3),t.civic.garrison.m_use>0&&(e*=1.1**t.civic.garrison.m_use),t.race.brute&&(e*=1-ui.brute.vars()[0]/100);let a=Pi("orc");return a>0&&(e*=1-ui.brute.vars(1)[0]/100*a),t.race.inflation&&(e*=1+t.race.inflation/500),t.race.high_pop&&(e*=ui.high_pop.vars()[1]/100),Math.round(e)}function ge(e){if(t.tech.mercs){let a=e||y(),r=!0;for(;r&&a>0;){let e=me();t.civic.garrison.workers=e?(t.resource.Money.amount-=e,t.civic.garrison.workers++,t.civic.garrison.m_use++):r=!1,a--}}}function fe(e,a){rc(e),t.tech.world_control&&!t.race.truepath?e.append($(`

          ${F("civics_garrison")}

          - ${F("rating")} {{ g.workers | hell | rating }}
          `)):e.append($(`

          ${F("civics_garrison")}

          - ${F("rating")} {{ g.workers | hell | rating }} / {{ g.raid | rating }}
          `));var r=$('
          ');e.append(r);var s=$('
          ');r.append(s);let i=t.tech.world_control&&!t.race.truepath?F("civics_garrison_peacekeepers"):F("civics_garrison_soldiers");if(t.tech.isolation||(s.append($(`
          ${i} / {{ g.max | s_max }}
          `)),s.append($(`
          ${F("civics_garrison_crew")} {{ g.crew }}
          `)),s.append($(`
          ${F("civics_garrison_wounded")}
          `)),r.append($(`
          `))),a){let a="";t.tech.isolation&&(a=$c(8,12)),e.append($(`
          ${F("civics_garrison_training")} - ${F("arpa_to_complete")} {{ g.rate, g.progress | trainTime }}${a} {{ g.progress }}%
          `))}var c=$('
          ');e.append(c);var o=$('
          ');if(c.append(o),(!t.tech.world_control||t.race.truepath)&&!t.race.cataclysm&&!t.tech.isolation){var n=$(`
          ${F("civics_garrison_campaign")}
          `);o.append(n);var l=$('{{ g.tactic | tactics }}'),u=$('«'),d=$('»');n.append(u),n.append(l),n.append(d);var _=$(`
          ${F("civics_garrison_battalion")}
          `);o.append(_);var p=$('{{ g.raid }}'),h=$('«'),m=$('»');_.append(h),_.append(p),_.append(m),a&&(t.race.truepath&&t.tech.rival&&c.append($(`
          ${ee(3)}
          `)),t.tech.world_control||(c.append($(`
          ${ee(0)}
          `)),c.append($(`
          ${ee(1)}
          `)),c.append($(`
          ${ee(2)}
          `))))}let g={g:t.civic.garrison,g0:t.civic.foreign.gov0,g1:t.civic.foreign.gov1,g2:t.civic.foreign.gov2};if(t.race.truepath&&(g.g3=t.civic.foreign.gov3,g.g4=t.civic.foreign.gov4),sc({el:a?"#garrison":"#c_garrison",data:g,methods:{hire(){ge()},campaign(e){be(e)},next(){t.civic.garrison.tactic<4&&t.civic.garrison.tactic++},last(){t.civic.garrison.tactic>0&&t.civic.garrison.tactic--},aNext(){let e=y();t.civic.garrison.raidqe()&&(t.civic.garrison.raid=qe()))},aLast(){let e=y();t.civic.garrison.raid>0&&(t.civic.garrison.raid-=e,t.civic.garrison.raid<0&&(t.civic.garrison.raid=0))},vis:()=>t.civic.garrison.display,rvis:()=>!(!t.tech.rival||t.tech.isolation)},filters:{tactics(e){switch(e){case 0:return F("civics_garrison_tactic_ambush");case 1:return F("civics_garrison_tactic_raid");case 2:return F("civics_garrison_tactic_pillage");case 3:return F("civics_garrison_tactic_assault");case 4:return F("civics_garrison_tactic_siege")}},rating:e=>+ke(e,"army").toFixed(1),hell:e=>qe(),stationed(e){let r=qe(),s=t.race.cataclysm?13:31,i=r===s&&!a&&kc(2,14,!0);return r===s&&i.length>0?i:r},s_max:e=>qe(!0),wounded(e){let t=$c(8,12);return a&&0===e&&t.length>0?t:Tc("fool",2021)?qe()-e:e},trainTime:(e,t)=>ic(0===e?-1:(100-t)/(4*e))}}),["tactic","bat","soldier","crew","wounded","hmerc","defenseRating","offenseRating"].forEach((function(e){Ti(a?`garrison${e}`:`cGarrison${e}`,(function(){return"{{ label() }}"}),{elm:`${a?"#garrison":"#c_garrison"} .${e}`,in:function(a){sc({el:`#${a.id} > span`,data:{test:"val"},methods:{label(){switch(e){case"tactic":switch(t.civic.garrison.tactic){case 0:return F("civics_garrison_tactic_ambush_desc");case 1:return F("civics_garrison_tactic_raid_desc");case 2:return F("civics_garrison_tactic_pillage_desc");case 3:return F("civics_garrison_tactic_assault_desc");case 4:return F("civics_garrison_tactic_siege_desc",[la("federation"===t.civic.govern.type?15:20)])}case"bat":return F("civics_garrison_army_label");case"soldier":return ve();case"crew":return F("civics_garrison_crew_desc");case"wounded":return F("civics_garrison_wounded_desc");case"hmerc":return F("civics_garrison_hire_mercenary_cost",[Math.round(me()).toLocaleString()]);case"defenseRating":return F("civics_garrison_defensive_rate");case"offenseRating":return F("civics_garrison_offensive_rate")}}}})},out:function(e){sc({el:e.id},"destroy")}})})),a){let e=t.race.truepath?4:3;for(let t=0;t{{ label() }}"}),{elm:`#garrison .gov${t} button`,in:function(e){sc({el:`#${e.id} > span`,data:{test:"val"},methods:{label:()=>ye(t)}})},out:function(e){sc({el:e.id},"destroy")}});t.race.truepath&&!t.tech.isolation&&Ti("garRivaldesc2",(function(){return F("civics_gov_tp_rival",[ee(3),di[t.race.species].home])}),{elm:"#garrison .gov3 > div"})}}function ve(){let e=ke(qe(),"hunting"),a=[];if((!t.race.herbivore||t.race.carnivore)&&!t.race.artifical){let r=+(e/3).toFixed(2);a.push(r,t.resource.Food.name)}let r=+(e/10).toFixed(2);if(a.push(r,t.resource.Furs.name),t.race.evil&&!t.race.kindling_kindred&&!t.race.smoldering){let r=+(e/(t.race.soul_eater?3:5)).toFixed(2);a.push(r,t.resource.Lumber.name)}let s="civics_garrison_soldier_loot"+a.length/2;return F(t.race.evil&&t.race.soul_eater?"civics_garrison_soldier_evil_desc":"civics_garrison_soldier_desc")+F(s,a)}function ye(e){if(t.civic.foreign[`gov${e}`].occ)return F("civics_garrison_deoccupy_desc");if(t.civic.foreign[`gov${e}`].buy||t.civic.foreign[`gov${e}`].anx)return F("civics_garrison_secede_desc");if(t.civic.garrison.tactic<=1&&t.civic.foreign[`gov${e}`].spy<1||t.civic.garrison.tactic>=2&&t.civic.garrison.tactic<=3&&t.civic.foreign[`gov${e}`].spy<2||4===t.civic.garrison.tactic&&t.civic.foreign[`gov${e}`].spy<3)return F("civics_garrison_no_spy");let a=ke(t.civic.garrison.raid,"army"),r=0;switch(t.civic.garrison.tactic){case 0:r=5;break;case 1:r=27.5;break;case 2:r=62.5;break;case 3:r=125;break;case 4:r=300}return r*=t.civic.foreign[`gov${e}`].mil/100,t.race.banana&&(r*=2),"swamp"===t.city.biome&&(r*=ji.swamp.vars()[0]),Tc("fool",2021)&&(r/=1.25),aqe()?t.civic.garrison.raid=qe():t.civic.garrison.raid<0&&(t.civic.garrison.raid=0),0===t.civic.garrison.raid)return void Di(F("civics_garrison_campaign_no_soldier"),"warning",!1,["combat"]);t.stats.attacks++;let a=t.race.claws?20:16,r=t.race.puny?3:5,s=Math.floor(m(r,a,!0))/10,i=ke(t.civic.garrison.raid,"army")*s,c=0;switch(t.civic.garrison.tactic){case 0:c=m(0,10,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(0,2,!0));break;case 1:c=m(5,50,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(0,3,!0));break;case 2:c=m(25,100,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(1,5,!0));break;case 3:c=m(50,200,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(4,12,!0));break;case 4:c=m(100,500,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(10,25,!0))}c=Math.floor(c*t.civic.foreign[`gov${e}`].mil/100),t.race.banana&&(c*=2),"swamp"===t.city.biome&&(c*=ji.swamp.vars()[0]),t.race.mistrustful&&(t.civic.foreign[`gov${e}`].hstl+=ui.mistrustful.vars()[0]),t.civic.foreign[`gov${e}`].hstl>100&&(t.civic.foreign[`gov${e}`].hstl=100),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(c/5),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0]));let o=0;if(t.civic.garrison.raid>t.civic.garrison.workers-t.civic.garrison.crew-t.civic.garrison.wounded&&(o=t.civic.garrison.raid-(t.civic.garrison.workers-t.civic.garrison.crew-t.civic.garrison.wounded)),t.civic.garrison.fatigue++,i>c){let a=Math.floor(t.civic.garrison.raid/(5-t.civic.garrison.tactic));a+=o,t.city.ptrait.includes("rage")&&(a+=Si.rage.vars()[2]),a<1&&(a=1),a>we()&&(a=we());let r=Math.floor(m(0,a,!0));t.race.frail&&(r+=ui.frail.vars()[0]);let s=0;if(t.race.scales&&(s+=ui.scales.vars()[0]),t.tech.armor&&(s+=t.tech.armor),t.race.high_pop&&(s+=Math.floor(m(0,s*ui.high_pop.vars()[0],!0))),t.race.armored){let e=1-ui.armored.vars()[0]/100;s+=Math.floor(r*e)}let i=Pi("tortoisan");if(i>0){let e=1-ui.armored.vars(1)[0]/100*i;s+=Math.floor(r*e)}if(t.civic.garrison.raid>o&&(r-=s),r<0&&(r=0),r>t.civic.garrison.raid&&(r=t.civic.garrison.raid),t.race.instinct){let e=Math.floor(r*(ui.instinct.vars()[1]/100));r-=e,o+=e}t.civic.garrison.workers-=r,t.stats.died+=r,t.civic.garrison.protest+=r,r>o?(t.civic.garrison.wounded-=o,o=0):(t.civic.garrison.wounded-=r,o-=r),t.civic.garrison.wounded+=Math.floor(m(o,t.civic.garrison.raid-r,!0));let c={Money:0,Food:0,Lumber:0,Stone:0,Copper:0,Iron:0,Aluminium:0,Coal:0,Cement:0,Steel:0,Titanium:0,Crystal:0,Chrysotile:0,Furs:0,Iridium:0,Alloy:0,Polymer:0,Oil:0},n=3===e&&t.race.truepath?["Food","Lumber","Stone","Copper","Iron"]:["Food","Lumber","Stone"],l=3===e&&t.race.truepath?["Aluminium","Coal","Cement","Steel","Furs"]:["Copper","Iron","Aluminium","Coal"],u=3===e&&t.race.truepath?["Titanium","Oil","Iridium","Alloy","Polymer"]:["Cement","Steel"];t.race.artifical&&n.shift(),t.race.smoldering&&n.push("Chrysotile"),t.race.terrifying&&3!==e&&u.push("Titanium"),t.tech.magic&&u.push("Crystal");let d=["Money"];switch(t.civic.garrison.tactic){case 0:{let e=["Money"].concat(n,l);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))]),t.resource.Steel.amount<25&&t.tech.smelting&&1===t.tech.smelting&&0===Math.floor(m(0,20,!0))&&d.push("Steel")}break;case 1:{let e=["Money"].concat(n,l,u);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 2:{let e=["Money"].concat(n,l,u),a=l.concat(u);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),d.push(a[Math.floor(m(0,a.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 3:{let e=["Money"].concat(n,l,u);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(u[Math.floor(m(0,u.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 4:{let e=["Money"].concat(n,l,u);d.push(n[Math.floor(m(0,n.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(u[Math.floor(m(0,u.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}}let _=t.race.terrifying&&3!==e?ui.terrifying.vars()[0]:12,p=t.race.terrifying&&3!==e?ui.terrifying.vars()[1]:32;d.forEach((function(e){switch(e){case"Money":c[e]+=Math.floor(m(100,375,!0));break;case"Food":c[e]+=Math.floor(m(40,175,!0));break;case"Lumber":case"Stone":c[e]+=Math.floor(m(50,250,!0));break;case"Copper":case"Iron":case"Aluminium":c[e]+=Math.floor(m(35,125,!0));break;case"Coal":case"Cement":c[e]+=Math.floor(m(25,100,!0));break;case"Steel":case"Chrysotile":c[e]+=Math.floor(m(20,65,!0));break;case"Titanium":c[e]+=Math.floor(m(_,p,!0));break;case"Crystal":c[e]+=Math.floor(m(1,5,!0));break;case"Oil":c[e]+=Math.floor(m(20,50,!0));break;case"Iridium":c[e]+=Math.floor(m(2,30,!0));break;case"Alloy":case"Polymer":c[e]+=Math.floor(m(5,38,!0))}}));let h=F("civics_garrison_gained");t.resource.Money.display&&c.Money>0&&(c.Money=$e(c.Money,e),h+=F("civics_garrison_quant_money",[c.Money]),Vi("Money",c.Money)),n.concat(l,u).forEach((function(a){c[a]>0&&(t.resource[a].display||"Steel"===a||"Titanium"===a)&&(c[a]=$e(c[a],e),h+=F("civics_garrison_quant_res",[c[a],t.resource[a].name]),Vi(a,c[a]),"Steel"!==a&&"Titanium"!==a||(t.resource[a].display=!0))})),h=h.slice(0,-2),h+=".",Di(h,"warning",!1,["combat"]);let g=0;if(t.race.revive){switch(t.city.calendar.temp){case 0:g=Math.floor(m(0,Math.floor(r/ui.revive.vars()[0]),!0));break;case 1:g=Math.floor(m(0,Math.floor(r/ui.revive.vars()[1]),!0));break;case 2:g=Math.floor(m(0,Math.floor(r/ui.revive.vars()[2]),!0))}t.civic.garrison.workers+=g}if(Di(g>0?F("civics_garrison_victorious_revive",[r,g]):F("civics_garrison_victorious",[r]),"success",!1,["combat"]),t.race.slaver&&t.city.slave_pen){let e=4*t.city.slave_pen.count;if(e>t.city.slave_pen.slaves){let a=Math.floor(m(0,t.civic.garrison.tactic+2,!0));a+t.city.slave_pen.slaves>e&&(a=e-t.city.slave_pen.slaves),a>0&&(t.city.slave_pen.slaves+=a,t.resource.Slave.amount=t.city.slave_pen.slaves,Di(F("civics_garrison_capture",[a]),"success",!1,["combat"]))}}if(t.race.infectious){let e=0;switch(t.civic.garrison.tactic){case 0:e=Math.floor(m(0,ui.infectious.vars()[0],!0));break;case 1:e=Math.floor(m(0,ui.infectious.vars()[1],!0));break;case 2:e=Math.floor(m(0,ui.infectious.vars()[2],!0));break;case 3:e=Math.floor(m(0,ui.infectious.vars()[3],!0));break;case 4:e=Math.floor(m(0,ui.infectious.vars()[4],!0))}t.resource[t.race.species].amount+e>t.resource[t.race.species].max&&(e=t.resource[t.race.species].max-t.resource[t.race.species].amount),e>0&&(t.resource[t.race.species].amount+=e,"unemployed"!==t.civic.d_job&&(t.civic[t.civic.d_job].workers+=e),Di(1===e?F("civics_garrison_soldier_infected"):F("civics_garrison_soldiers_infected",[e]),"special",!1,["combat"]))}let f=la("federation"===t.civic.govern.type?15:20);if(e<=2&&4===t.civic.garrison.tactic&&t.civic.garrison.workers>=f){let a=!t.tech.gov_fed&&!ue();if(t.civic.garrison.workers-=f,t.civic.foreign[`gov${e}`].occ=!0,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none",a&&ms(),t.race.banana){let e=Yc();t.stats.banana.b1[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b1.l=!0)}}}else{let e=t.civic.garrison.raid;e+=o,0===t.civic.garrison.tactic&&(e=Math.floor(e/2)),t.city.ptrait.includes("rage")&&(e+=Si.rage.vars()[2]),e<1&&(e=1),e>we()&&(e=we());let a=Math.floor(m(1,e,!0));t.race.frail&&(a+=t.civic.garrison.tactic+ui.frail.vars()[1]);let r=0;if(t.race.scales&&(r+=ui.scales.vars()[1]),t.tech.armor&&(r+=t.tech.armor),t.race.high_pop&&(r+=Math.floor(m(0,Math.floor(r*ui.high_pop.vars()[0]/2),!0))),t.race.armored){let e=ui.armored.vars()[0]/100;r+=Math.floor(a*e)}let s=Pi("tortoisan");if(s>0){let e=ui.armored.vars(1)[0]/100*s;r+=Math.floor(a*e)}if(t.civic.garrison.raid>o&&(a-=r),t.race.instinct){let e=Math.floor(a*(ui.instinct.vars()[1]/100));a-=e,o+=e}a<1&&(a=1),a>t.civic.garrison.raid&&(a=t.civic.garrison.raid),t.civic.garrison.workers-=a,t.stats.died+=a,t.civic.garrison.protest+=a,a>o?(t.civic.garrison.wounded-=o,o=0):(t.civic.garrison.wounded-=a,o-=a),t.civic.garrison.wounded+=1+Math.floor(m(o,t.civic.garrison.raid-a,!0));let i=0;if(t.race.revive){switch(t.city.calendar.temp){case 0:i=Math.floor(m(0,Math.floor(a/ui.revive.vars()[3]),!0));break;case 1:i=Math.floor(m(0,Math.floor(a/ui.revive.vars()[4]),!0));break;case 2:i=Math.floor(m(0,Math.floor(a/ui.revive.vars()[5]),!0))}t.civic.garrison.workers+=i}Di(i>0?F("civics_garrison_defeat_revive",[a,i]):F("civics_garrison_defeat",[a]),"danger",!1,["combat"])}t.civic.garrison.wounded>t.civic.garrison.workers-t.civic.garrison.crew?t.civic.garrison.wounded=t.civic.garrison.workers-t.civic.garrison.crew:t.civic.garrison.wounded<0&&(t.civic.garrison.wounded=0)}function we(){let e=0,a=t.civic.garrison.raid;switch(t.civic.garrison.tactic){case 0:e=5;break;case 1:e=10;break;case 2:e=25;break;case 3:e=50;break;case 4:e=999}return t.race.high_pop&&(e=la(e)),a>e&&(a=e),a}function $e(e,a){let r=we();t.race.high_pop&&(r/=la(1));let s=e*Math.log(r+1);switch(t.race.invertebrate&&(s*=1-ui.invertebrate.vars()[0]/100),"evil"===t.race.universe&&(s*=nc("evil")),t.civic.garrison.tactic){case 1:s*=4;break;case 2:s*=30;break;case 3:s*=100;break;case 4:s*=400}return t.race.banana&&(s*=.5),"swamp"===t.city.biome&&(s*=ji.swamp.vars()[1]),Math.floor(s*t.civic.foreign[`gov${a}`].eco/100)}function xe(){let e=t.tech.military?t.tech.military>=5?t.tech.military-1:t.tech.military:1;if(t.tech.military&&t.tech.military>1){e-=t.tech.military>=11?2:1,t.race.sniper&&(e*=1+ui.sniper.vars()[0]/100*e);let a=Pi("centaur");a>0&&(e*=1+ui.sniper.vars(1)[0]/100*e*a),e+=t.tech.military>=11?2:1}return e}function ke(e,a,r){if(!t.civic.hasOwnProperty("garrison"))return 1;let s=0;"number"==typeof r?s=r:e>t.civic.garrison.workers-t.civic.garrison.wounded&&(s=e-(t.civic.garrison.workers-t.civic.garrison.wounded));let i=xe(),c=Pi("rhinotaur"),o=e-s/2;(t.race.rage||c>0)&&(o=e+(t.race.rage?s*ui.rage.vars()[1]/100:0)+(c>0?s*ui.rage.vars(1)[1]/100*c:0));let n=t.tech.military?o*i:o;if("army"===a||"hellArmy"===a){t.race.rage&&(n*=1+ui.rage.vars()[0]/100*(t.civic.garrison.wounded||0)),c>0&&(n*=1+ui.rage.vars(1)[0]/100*c*(t.civic.garrison.wounded||0)),t.race.puny&&(n*=1-ui.puny.vars()[0]/100),t.race.claws&&(n*=1+ui.claws.vars()[0]/100);let r=Pi("scorpid");r>0&&(n*=1+ui.claws.vars(1)[0]/100*r),t.race.chameleon&&(n*=1+ui.chameleon.vars()[0]/100),t.race.cautious&&0===t.city.calendar.weather&&(n*=1-ui.cautious.vars()[0]/100),t.race.apex_predator&&(n*=1+ui.apex_predator.vars()[0]/100);let s=Pi("sharkin");s>0&&(n*=1+ui.apex_predator.vars(1)[0]/100*s),t.race.swift&&(n*=1+ui.swift.vars()[0]/100),t.race.fiery&&(n*=1+ui.fiery.vars()[0]/100);let i=Pi("balorg");i>0&&(n*=1+ui.fiery.vars(1)[0]/100*i),t.race.sticky&&(n*=1+ui.sticky.vars()[1]/100);let o=Pi("pinguicula");o>0&&(n*=1+ui.sticky.vars(1)[1]/100*o),t.race.pathetic&&(n*=1-ui.pathetic.vars()[0]/100),t.race.tactical&&(n*=1+ui.tactical.vars()[0]*t.race.tactical/100),t.tech.fanaticism&&t.tech.fanaticism>=4&&(n*=1+.01*t.city.temple.count),t.race.holy&&"hellArmy"===a&&(n*=1+ui.holy.vars()[0]/100);let l=Pi("unicorn");l>0&&"hellArmy"===a&&(n*=1+ui.holy.vars(1)[0]/100*l),t.race.banana&&"hellArmy"===a&&(n*=.8),"aries"===U()&&(n*=1+H("aries")[0]/100);let u=N("tactician",0);if(u&&(n*=1+u/100),t.city.ptrait.includes("rage")&&(n*=Si.rage.vars()[0]),t.race.parasite&&(1===e?n+=2:e>1&&(n+=4)),t.tech.psychic&&t.race.psychicPowers&&t.race.psychicPowers.hasOwnProperty("assaultTime")){let e=0;if(t.race.psychicPowers.assaultTime>0&&(e+=ui.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(ui.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.assault).toFixed(3)}n*=1+e}}return"hunting"===a&&t.race.unfathomable&&(n*=.66),t.race.rejuvenated&&(n*=1.05),"autocracy"===t.civic.govern.type&&(n*=1+ae.autocracy()[1]/100),n=Math.floor(n),n*pi(e,a)}function qe(e,a){if(!t.civic.garrison)return 0;let r=e?"max":"workers",s=t.portal.fortress?t.portal.fortress.garrison:0,i=t.space.fob&&!a?t.space.fob.troops:0;return t.civic.garrison[r]-t.civic.garrison.crew-s-i}function Me(e){return t.race.high_pop&&(e*=ui.high_pop.vars()[1]/100),e}function Pe(e,a){switch(e){case"transmitter":return 2.5;case"oil_well":{let e=t.tech.oil>=4?.48:.4;t.tech.oil>=7?e*=2:t.tech.oil>=5&&(e*=t.tech.oil>=6?1.75:1.25),t.city.geology.Oil&&(e*=t.city.geology.Oil+1),"desert"===t.city.biome?e*=ji.desert.vars()[1]:"tundra"===t.city.biome?e*=ji.tundra.vars()[1]:"taiga"===t.city.biome&&(e*=ji.taiga.vars()[2]);let a=N("dirty_jobs",2);return a&&(e*=1+a/100),e}case"iridium_mine":switch(a){case"iridium":{let e=.035;t.city.geology.Iridium&&(e*=t.city.geology.Iridium+1);let a=e,r=X(3);return{b:a,g:r-1,f:a*r}}case"coal":return.55}case"helium_mine":{let e=.18,t=X(3);return{b:e,g:t-1,f:e*t}}case"red_mine":switch(a){case"copper":{let e=Me(.25),t=X(3);return{b:e,g:t-1,f:e*t}}case"titanium":{let e=Me(.02),t=X(3);return{b:e,g:t-1,f:e*t}}case"stone":return Me(.75);case"asbestos":return Me(1.25);case"aluminium":return Me(.066)}case"biodome":switch(a){case"food":return Me(.25);case"cat_food":return 2;case"lumber":return Me(1.5)}case"gas_mining":return t.tech.helium?.65:.5;case"outpost":{let e={b:.025,d:0,n:0};if(t.tech.drone){let a=t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3?.12:.06;e.d=t.space.drone.count*a,e.n=e.b*(1+e.d)}else e.n=e.b;return a?e:e.n}case"oil_extractor":{let e=t.tech.oil>=4?.48:.4;return t.tech.oil>=7?e*=2:t.tech.oil>=5&&(e*=t.tech.oil>=6?1.75:1.25),e}case"elerium_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?.009:.0075:.005;case"iridium_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?.1:.08:.055;case"iron_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?4:3:2;case"g_factory":if(t.race.truepath){if(t.tech.isolation)return 1.8;{let e=.05*(i.ai_colonist?t.civic.titan_colonist.workers+la(i.ai_colonist):t.civic.titan_colonist.workers);return t.race.high_pop&&(e=Me(e)),e}}return.6;case"harvester":switch(a){case"helium":return.85;case"deuterium":return.15}case"elerium_prospector":return.014;case"neutron_miner":return.055;case"bolognium_ship":return.008;case"excavator":return.2;case"vitreloy_plant":{let e=.18;return"corpocracy"===t.civic.govern.type&&(e*=t.tech.high_tech&&t.tech.high_tech>=16?1.4:1.3),"socialist"===t.civic.govern.type&&(e*=1.1),e}case"infernite_mine":return.5*Oa("gate").supress;case"water_freighter":return 1.25;case"titan_mine":switch(a){case"adamantite":return Me(.02)*(t.space.titan_mine?t.space.titan_mine.ratio:50)/100;case"aluminium":return Me(.12)*(100-(t.space.titan_mine?t.space.titan_mine.ratio:50))/100}case"lander":return 100===t.space.crashed_ship.count?.005:0;case"orichalcum_mine":return.08;case"uranium_mine":return.025;case"neutronium_mine":return.04;case"elerium_mine":return.009;case"shock_trooper":case"tank":return 100===t.space.digsite.count?.0018:0;case"mining_pit":{let e=0;switch(a){case"materials":e=t.tech.isolation?.12:.09;break;case"bolognium":e=t.tech.isolation?.0288:.0216;break;case"stone":e=t.tech.isolation?.8:.6;break;case"adamantite":e=t.tech.isolation?.448:.336;break;case"copper":e=.58;break;case"coal":e=.13;break;case"iron":e=.74;break;case"aluminium":e=.88;break;case"chrysotile":e=1.44}t.race.tough&&(e*=1+ui.tough.vars()[0]/100);let r=Pi("ogre");return r>0&&(e*=1+ui.tough.vars(1)[0]/100*r),t.tech.tau_pit_mining&&(e*=1.18),e}case"tau_farm":switch(a){case"food":return t.tech.isolation?15:9;case"lumber":return t.tech.isolation?12:5.5;case"water":return.35}case"womling_mine":{let e=1;switch(t.tech.womling_mining&&(e+=.15*t.tech.womling_mining),t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5&&(e*=1.1),t.tech.womling_gene&&(e*=1.25),a){case"unobtainium":return.0305*e;case"uranium":return.047*e;case"titanium":return.616*e;case"copper":return 1.191*e;case"iron":return 1.377*e;case"aluminium":return 1.544*e;case"neutronium":return.382*e;case"iridium":return.535*e}}case"refueling_station":return t.tech.isolation?18.5:9.35;case"ore_refinery":return t.tech.tau_ore_mining?40:25;case"whaling_station":return 12;case"mining_ship":if(t.tauceti.patrol_ship){let e=1;return t.tauceti.patrol_ship.support>t.tauceti.patrol_ship.s_max&&(e=Ac("curve",t.tauceti.patrol_ship.s_max/t.tauceti.patrol_ship.support,1.4)),(t.tech.tau_ore_mining&&t.tech.tau_ore_mining>=2?12:10)*e}return 0;case"mining_ship_ore":switch(a){case"iron":case"aluminium":return t.tech.isolation?2.22:1.85;case"iridium":case"neutronium":return t.tech.isolation?.42:.35;case"orichalcum":return t.tech.isolation?.3:.25;case"elerium":return t.tech.isolation?.024:.02}case"whaling_ship":if(t.tauceti.patrol_ship){let e=1;return t.tauceti.patrol_ship.support>t.tauceti.patrol_ship.s_max&&(e=Ac("curve",t.tauceti.patrol_ship.s_max/t.tauceti.patrol_ship.support,1.4)),8*e}return 0;case"whaling_ship_oil":return t.tech.isolation?.78:.42;case"alien_outpost":return.01;case"psychic_boost":if(t.tech.psychic&&t.race.psychic&&t.race.psychicPowers&&t.race.psychicPowers.boost.r===a&&t.race.psychicPowers.hasOwnProperty("boostTime")){let e=0;if(t.race.psychicPowers.boostTime>0&&(e+=ui.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(ui.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.boost).toFixed(3)}return 1+e}return 1;case"psychic_cash":if(t.tech.psychic&&t.race.psychic&&t.race.psychicPowers&&t.race.psychicPowers.hasOwnProperty("cash")){let e=0;if(t.race.psychicPowers.cash>0&&(e+=ui.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(ui.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.cash).toFixed(3)}return 1+e}return 1}}function Oe(e){switch(e){case"Physics":Ne();break;case"Genetics":Be();break;case"Monument":return Te();case"PhysicsTech":return Ce;case"GeneTech":return Se;case"BloodTech":return Fe;case"Crispr":Ge();break;case"Blood":Re()}}const Ce={lhc:{title:()=>Tc("fool",2022)?F("arpa_projects_railway_title"):F("arpa_projects_lhc_title"),desc:()=>Tc("fool",2022)?F("arpa_projects_railway_desc"):F("arpa_projects_lhc_desc"),reqs:{high_tech:6},grant:"supercollider",effect(e){if(Tc("fool",2022)&&!e)return Ce.railway.effect(!0);let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?t.race.cataclysm?20:8:t.race.cataclysm?10:4;return t.tech.storage>=6?t.tech.particles&&t.tech.particles>=4?t.race.cataclysm?F("arpa_projects_lhc_cataclysm3",[a]):F("arpa_projects_lhc_effect3",[a,t.race.orbit_decayed?F("space_home_satellite_title"):Ts()]):t.race.cataclysm?F("arpa_projects_lhc_cataclysm2",[a]):F("arpa_projects_lhc_effect2",[a,t.race.orbit_decayed?F("space_home_satellite_title"):Ts()]):t.race.cataclysm?F("arpa_projects_lhc_cataclysm1",[a]):t.tech.isolation?F("arpa_projects_lhc_iso1",[a,F("tech_infectious_disease_lab_alt")]):F("arpa_projects_lhc_effect1",[a,t.race.orbit_decayed?F("space_home_satellite_title"):Ts()])},cost:{Money:(e,t)=>Le("lhc",e,25e5,1.05,t),Knowledge:(e,t)=>Le("lhc",e,5e5,1.05,t),Copper:(e,t)=>Le("lhc",e,125e3,1.05,t),Cement:(e,t)=>Le("lhc",e,25e4,1.05,t),Aluminium:(e,t)=>Le("lhc",e,35e4,1.05,t),Titanium:(e,t)=>Le("lhc",e,5e4,1.05,t),Polymer:(e,t)=>Le("lhc",e,12e3,1.05,t)}},stock_exchange:{title:F("arpa_projects_stock_exchange_title"),desc:F("arpa_projects_stock_exchange_desc"),reqs:{banking:9},grant:"stock_exchange",effect:()=>t.tech.banking>=10?t.race.cataclysm?t.tech.gambling&&t.tech.gambling>=4?F("arpa_projects_stock_exchange_cataclysm2"):F("arpa_projects_stock_exchange_cataclysm1"):t.tech.gambling&&t.tech.gambling>=4?F("arpa_projects_stock_exchange_effect3"):F("arpa_projects_stock_exchange_effect2"):F("arpa_projects_stock_exchange_effect1"),cost:{Money:(e,t)=>Le("stock_exchange",e,3e6,1.06,t),Plywood:(e,t)=>Le("stock_exchange",e,25e3,1.06,t),Brick:(e,t)=>Le("stock_exchange",e,2e4,1.06,t),Wrought_Iron:(e,t)=>Le("stock_exchange",e,1e4,1.06,t)}},tp_depot:{title:F("galaxy_gateway_depot"),desc:F("arpa_projects_depot_desc"),reqs:{high_tech:6,storage:4},grant:"tp_depot",path:["truepath"],effect:()=>F(t.tech.isolation?"arpa_projects_depot_effect_iso":"arpa_projects_depot_effect",[5,50]),cost:{Money:(e,t)=>Le("tp_depot",e,18e5,1.08,t),Stone:(e,t)=>Le("tp_depot",e,75e4,1.08,t),Iron:(e,t)=>Le("tp_depot",e,25e4,1.08,t),Alloy:(e,t)=>Le("tp_depot",e,3e4,1.08,t)}},launch_facility:{id:"arpalaunch_facility",title:F("arpa_projects_launch_facility_title"),desc:F("arpa_projects_launch_facility_desc"),reqs:{high_tech:7},condition:()=>!t.race.cataclysm&&!t.race.lone_survivor,grant:"launch_facility",rank:1,queue_complete:()=>t.tech.space>=1?0:1,effect:()=>F("arpa_projects_launch_facility_effect1"),cost:{Money:e=>Le("launch_facility",e,2e6,1.1),Knowledge:e=>Le("launch_facility",e,5e5,1.1),Cement:e=>Le("launch_facility",e,15e4,1.1),Oil:e=>Le("launch_facility",e,2e4,1.1),Sheet_Metal:e=>Le("launch_facility",e,15e3,1.1),Alloy:e=>Le("launch_facility",e,25e3,1.1)}},monument:{title(e){if(e)return F("arpa_project_monument_title");switch(t.arpa.m_type){case"Obelisk":return F("arpa_project_monument_obelisk");case"Statue":return F("arpa_project_monument_statue");case"Sculpture":return F("arpa_project_monument_sculpture");case"Monolith":return F("arpa_project_monument_monolith");case"Pillar":return F("arpa_project_monument_pillar");case"Megalith":return F("arpa_project_monument_megalith")}},desc:F("arpa_projects_monument_desc"),reqs:{monument:1},grant:"monuments",effect(){let e=N("gaslighter",2);return F("arpa_projects_monument_effect1",[e?2-e:2])},cost:{Stone:(e,t)=>Ee("Stone",e,t),Aluminium:(e,t)=>Ee("Aluminium",e,t),Cement:(e,t)=>Ee("Cement",e,t),Steel:(e,t)=>Ee("Steel",e,t),Lumber:(e,t)=>Ee("Lumber",e,t),Crystal:(e,t)=>Ee("Crystal",e,t)}},railway:{title:()=>Tc("fool",2022)?F("arpa_projects_lhc_title"):F("arpa_projects_railway_title"),desc:()=>Tc("fool",2022)?F("arpa_projects_lhc_desc"):F("arpa_projects_railway_desc"),reqs:{high_tech:6,trade:3},grant:"railway",effect(e){if(Tc("fool",2022)&&!e)return Ce.lhc.effect(!0);let a=t.stats.achieve.banana&&t.stats.achieve.banana.l>=2?1:0,r=t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?3:2;return t.race.cataclysm||t.race.orbit_decayed?(a+=t.space.gps?Math.floor(t.space.gps.count/3):0,F("arpa_projects_railway_cataclysm1",[a,r,3,1])):(a+=t.city.storage_yard?Math.floor(t.city.storage_yard.count/6):0,F("arpa_projects_railway_effect1",[a,r,6,1]))},cost:{Money:(e,t)=>Le("railway",e,25e5,1.08,t),Lumber:(e,t)=>Le("railway",e,75e4,1.08,t),Iron:(e,t)=>Le("railway",e,3e5,1.08,t),Steel:(e,t)=>Le("railway",e,45e4,1.08,t)}},roid_eject:{title:()=>F("arpa_projects_roid_eject_title",[je()]),desc:()=>F(t.tech.roid_eject<=10?"arpa_projects_roid_eject_desc":"arpa_projects_roid_eject_desc2",[je()]),reqs:{blackhole:6,gateway:3},grant:"roid_eject",effect(){let e=0,a=0;return t.tech.roid_eject&&(e+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12),a=.225*(t.tech.roid_eject+1)*(1+(t.tech.roid_eject+1)/12)-e),`
          ${F("arpa_projects_roid_eject_effect1")}
          ${F("arpa_projects_roid_eject_effect2",[+e.toFixed(3),+a.toFixed(3),je()])}
          `},cost:{Money:(e,t)=>Le("roid_eject",e,1875e4,1.075,t),Deuterium:(e,t)=>Le("roid_eject",e,375e3,1.075,t),Bolognium:(e,t)=>Le("roid_eject",e,15e3,1.075,t)}},nexus:{title:F("arpa_projects_nexus_title"),desc:F("arpa_projects_nexus_desc"),reqs:{magic:5},grant:"nexus",effect:()=>t.tech.roguemagic&&t.tech.roguemagic>=7?`
          ${F("arpa_projects_nexus_effect1",[5])}
          ${F("witch_hunter_nexus",[8])}
          `:F("arpa_projects_nexus_effect1",[5]),cost:{Money:(e,t)=>Le("nexus",e,5e6,1.12,t),Crystal:(e,t)=>Le("nexus",e,6e4,1.12,t),Iridium:(e,t)=>Le("nexus",e,35e3,1.12,t)}},syphon:{title:F("arpa_syphon_title"),desc(){let e="";return e=t.tech.syphon&&t.tech.syphon>=0?`
          ${F("arpa_syphon_desc")}
          ${F("arpa_syphon_desc_warn2")}
          `:`
          ${F("arpa_syphon_desc")}
          ${F("arpa_syphon_desc_warn1")}
          `,t.race.witch_hunter&&(e+=`
          ${F("witch_hunter_suspicion")}
          `),e},reqs:{veil:2},grant:"syphon",effect(){let e=+(1/3*nc("magic")).toFixed(3);if(t.tech.syphon&&t.tech.syphon>=60){let t=mc("vacuum"),a=F("resource_Plasmid_plural_name");return`
          ${F("arpa_syphon_effect_main",[e])}
          ${F("arpa_syphon_effect4")}
          ${F("arpa_syphon_effect_reward",[t.plasmid,t.phage,t.dark,a,80])}
          `}return t.tech.syphon&&t.tech.syphon>=40?`
          ${F("arpa_syphon_effect_main",[e])}
          ${F("arpa_syphon_effect3")}
          `:t.tech.syphon&&t.tech.syphon>=20?`
          ${F("arpa_syphon_effect_main",[e])}
          ${F("arpa_syphon_effect2")}
          `:`
          ${F("arpa_syphon_effect_main",[e])}
          ${F("arpa_syphon_effect1")}
          `},cost:{Money:(e,t)=>Le("syphon",e,75e5,1.025,t),Mana:(e,t)=>Le("syphon",e,5e3,1.025,t),Crystal:(e,t)=>Le("syphon",e,1e5,1.025,t),Infernite:(e,t)=>Le("syphon",e,1e4,1.025,t)}}};function je(){return!t.tech.roid_eject||t.tech.roid_eject<=10?F("arpa_projects_roid_eject_asteroid"):t.tech.roid_eject<=25?F("arpa_projects_roid_eject_moon"):t.tech.roid_eject<=40?F("arpa_projects_roid_eject_dwarf"):t.tech.roid_eject<=60?F("arpa_projects_roid_eject_planet"):F("arpa_projects_roid_eject_remnant")}const Se={genetic_memory:{id:"genes-genetic_memory",title:F("arpa_genepool_genetic_memory_title"),desc:F("arpa_genepool_genetic_memory_desc"),reqs:{},grant:["creep",1],cost:{Plasmid:()=>25},action:()=>!!ze("genetic_memory")},animus:{id:"genes-animus",title:F("arpa_genepool_animus_title"),desc:F("arpa_genepool_animus_desc"),reqs:{creep:1},grant:["creep",2],cost:{Plasmid:()=>75},action:()=>!!ze("animus")},divine_remembrance:{id:"genes-divine_remembrance",title:F("arpa_genepool_divine_remembrance_title"),desc:F("arpa_genepool_divine_remembrance_desc"),reqs:{creep:2},grant:["creep",3],cost:{Plasmid:()=>225},action:()=>!!ze("divine_remembrance")},divine_proportion:{id:"genes-divine_proportion",title:F("arpa_genepool_divine_proportion_title"),desc:F("arpa_genepool_divine_proportion_desc"),reqs:{creep:3},grant:["creep",4],cost:{Plasmid:()=>618},action:()=>!!ze("divine_proportion")},genetic_repository:{id:"genes-genetic_repository",title:F("arpa_genepool_genetic_repository_title"),desc:F("arpa_genepool_genetic_repository_desc"),reqs:{creep:4},grant:["creep",5],cost:{Plasmid:()=>999},action:()=>!!ze("genetic_repository")},spatial_reasoning:{id:"genes-spatial_reasoning",title:F("arpa_genepool_spatial_reasoning_title"),desc:F("arpa_genepool_spatial_reasoning_desc"),reqs:{},grant:["store",1],cost:{Plasmid:()=>50},action:()=>!!ze("spatial_reasoning")},spatial_superiority:{id:"genes-spatial_superiority",title:F("arpa_genepool_spatial_superiority_title"),desc:F("arpa_genepool_spatial_superiority_desc"),reqs:{store:1},grant:["store",2],cost:{Plasmid:()=>125},action:()=>!!ze("spatial_superiority")},spatial_supremacy:{id:"genes-spatial_supremacy",title:F("arpa_genepool_spatial_supremacy_title"),desc:F("arpa_genepool_spatial_supremacy_desc"),reqs:{store:2},grant:["store",3],cost:{Plasmid:()=>325},action:()=>!!ze("spatial_supremacy")},dimensional_warping:{id:"genes-dimensional_warping",title:F("arpa_genepool_dimensional_warping_title"),desc:F("arpa_genepool_dimensional_warping_desc"),reqs:{store:3},grant:["store",4],cost:{Plasmid:()=>500},action:()=>!!ze("dimensional_warping")},enhanced_muscle_fiber:{id:"genes-enhanced_muscle_fiber",title:F("arpa_genepool_enhanced_muscle_fiber_title"),desc:F("arpa_genepool_enhanced_muscle_fiber_desc"),reqs:{},grant:["enhance",1],cost:{Plasmid:()=>25},action:()=>!!ze("enhanced_muscle_fiber")},morphogenesis:{id:"genes-morphogenesis",title:F("arpa_genepool_morphogenesis_title"),desc:F("arpa_genepool_morphogenesis_desc"),reqs:{},grant:["evolve",1],cost:{Plasmid:()=>10},action:()=>!!ze("morphogenesis")},recombination:{id:"genes-recombination",title:F("arpa_genepool_recombination_title"),desc:F("arpa_genepool_recombination_desc"),reqs:{evolve:1},grant:["evolve",2],cost:{Plasmid:()=>35},action:()=>!!ze("recombination")},homologous_recombination:{id:"genes-homologous_recombination",title:F("arpa_genepool_homologous_recombination_title"),desc:F("arpa_genepool_homologous_recombination_desc"),reqs:{evolve:2},grant:["evolve",3],cost:{Plasmid:()=>70},action:()=>!!ze("homologous_recombination")},genetic_reshuffling:{id:"genes-genetic_reshuffling",title:F("arpa_genepool_genetic_reshuffling_title"),desc:F("arpa_genepool_genetic_reshuffling_desc"),reqs:{evolve:3},grant:["evolve",4],cost:{Plasmid:()=>175},action:()=>!!ze("genetic_reshuffling")},recombinant_dna:{id:"genes-recombinant_dna",title:F("arpa_genepool_recombinant_dna_title"),desc:F("arpa_genepool_recombinant_dna_desc"),reqs:{evolve:4},grant:["evolve",5],cost:{Plasmid:()=>440},action:()=>!!ze("recombinant_dna")},chimeric_dna:{id:"genes-chimeric_dna",title:F("arpa_genepool_chimeric_dna_title"),desc:F("arpa_genepool_chimeric_dna_desc"),reqs:{evolve:5},grant:["evolve",6],cost:{Plasmid:()=>1100},action:()=>!!ze("chimeric_dna")},molecular_cloning:{id:"genes-molecular_cloning",title:F("arpa_genepool_molecular_cloning_title"),desc:F("arpa_genepool_molecular_cloning_desc"),reqs:{evolve:6},grant:["evolve",7],cost:{Plasmid:()=>2750},action:()=>!!ze("molecular_cloning")},transgenes:{id:"genes-transgenes",title:F("arpa_genepool_transgenes_title"),desc:F("arpa_genepool_transgenes_desc"),reqs:{evolve:7},grant:["evolve",8],cost:{Plasmid:()=>6875},action:()=>!!ze("transgenes")},synthesis:{id:"genes-synthesis",title:F("arpa_genepool_synthesis_title"),desc:F("arpa_genepool_synthesis_desc",[2,10]),reqs:{evolve:1},grant:["synthesis",1],cost:{Plasmid:()=>25},action:()=>!!ze("synthesis")},karyokinesis:{id:"genes-karyokinesis",title:F("arpa_genepool_karyokinesis_title"),desc:F("arpa_genepool_synthesis_desc",[3,25]),reqs:{synthesis:1},grant:["synthesis",2],cost:{Plasmid:()=>40},action:()=>!!ze("karyokinesis")},cytokinesis:{id:"genes-cytokinesis",title:F("arpa_genepool_cytokinesis_title"),desc:F("arpa_genepool_synthesis_desc",[4,50]),reqs:{synthesis:2},grant:["synthesis",3],cost:{Plasmid:()=>55},action:()=>!!ze("cytokinesis")},mitosis:{id:"genes-mitosis",title:F("arpa_genepool_mitosis_title"),desc:F("arpa_genepool_mitosis_desc",[3]),reqs:{synthesis:3,evolve:2},grant:["plasma",1],cost:{Plasmid:()=>90},action:()=>!!ze("mitosis")},metaphase:{id:"genes-metaphase",title:F("arpa_genepool_metaphase_title"),desc:F("arpa_genepool_mitosis_desc",[5]),reqs:{plasma:1},grant:["plasma",2],cost:{Plasmid:()=>165},action:()=>!!ze("mitosis")},mutation:{id:"genes-mutation",title:F("arpa_genepool_mutation_title"),desc:F("arpa_genepool_mutation_desc"),reqs:{synthesis:3,creep:5},grant:["mutation",1],cost:{Plasmid:()=>1250},action:()=>!!ze("mutation")&&(t.genes.mutation=1,Be(),!0)},transformation:{id:"genes-transformation",title:F("arpa_genepool_transformation_title"),desc:F("arpa_genepool_transformation_desc"),reqs:{mutation:1},grant:["mutation",2],cost:{Plasmid:()=>1500},action:()=>!!ze("transformation")&&(t.genes.mutation=2,Be(),!0)},metamorphosis:{id:"genes-metamorphosis",title:F("arpa_genepool_metamorphosis_title"),desc:F("arpa_genepool_metamorphosis_desc"),reqs:{mutation:2},grant:["mutation",3],cost:{Plasmid:()=>1750},action:()=>!!ze("metamorphosis")&&(t.genes.mutation=3,Be(),!0)},replication:{id:"genes-replication",title:F("arpa_genepool_replication_title"),desc:F("arpa_genepool_replication_desc"),reqs:{evolve:1},grant:["birth",1],cost:{Plasmid:()=>65},action:()=>!!ze("replication")},artificer:{id:"genes-artificer",title:F("arpa_genepool_artificer_title"),desc:F("arpa_genepool_artificer_desc"),reqs:{evolve:1},grant:["crafty",1],cost:{Plasmid:()=>45},action:()=>!!ze("artificer")},detail_oriented:{id:"genes-detail_oriented",title:F("arpa_genepool_detail_oriented_title"),desc:F("arpa_genepool_crafting_desc",["50"]),reqs:{crafty:1},grant:["crafty",2],cost:{Plasmid:()=>90},action:()=>!!ze("detail_oriented")},rigorous:{id:"genes-rigorous",title:F("arpa_genepool_rigorous_title"),desc:F("arpa_genepool_crafting_desc",["100"]),reqs:{crafty:2},grant:["crafty",3],cost:{Plasmid:()=>135},action:()=>!!ze("rigorous")},geographer:{id:"genes-geographer",title:F("arpa_genepool_geographer_title"),desc:F("arpa_genepool_geographer_desc"),reqs:{store:1},grant:["queue",1],cost:{Plasmid:()=>75},action:()=>!!ze("geographer")},architect:{id:"genes-architect",title:F("arpa_genepool_architect_title"),desc:F("arpa_genepool_architect_desc"),reqs:{queue:1},grant:["queue",2],cost:{Plasmid:()=>160},action:()=>!!ze("architect"),post(){Ri(),Hi()}},precognition:{id:"genes-precognition",title:F("arpa_genepool_precognition_title"),desc:F("arpa_genepool_precognition_desc"),reqs:{queue:2},grant:["queue",3],condition:()=>t.stats.aiappoc>0,cost:{Plasmid:()=>3500,Phage:()=>100,AICore:()=>1},action:()=>!!ze("precognition")},governance:{id:"genes-governance",title:F("arpa_genepool_governance_title"),desc:F("arpa_genepool_governance_desc"),reqs:{queue:2},grant:["governor",1],cost:{Plasmid:()=>300,Phage:()=>25},action:()=>!!ze("governance")},civil_service:{id:"genes-civil_service",title:F("arpa_genepool_civil_service_title"),desc:F("arpa_genepool_civil_service_desc"),reqs:{governor:1},grant:["governor",2],cost:{Plasmid:()=>1e3,Harmony:()=>1},action:()=>!!ze("civil_service"),post(){if(t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks"))for(let e=0;e<6;e++)t.race.governor.tasks.hasOwnProperty(`t${e}`)||(t.race.governor.tasks[`t${e}`]="none");K()}},hardened_genes:{id:"genes-hardened_genes",title:F("arpa_genepool_hardened_genes_title"),desc:F("arpa_genepool_hardened_genes_desc"),reqs:{},grant:["challenge",1],cost:{Plasmid:()=>5},action:()=>!!ze("hardened_genes")},unlocked:{id:"genes-unlocked",title:F("arpa_genepool_unlocked_title"),desc:F("arpa_genepool_unlocked_desc"),reqs:{challenge:1},grant:["challenge",2],cost:{Plasmid:()=>50},action:()=>!!ze("unlocked"),post(){lc(!0)}},universal:{id:"genes-universal",title:F("arpa_genepool_universal_title"),desc:F("arpa_genepool_universal_desc"),reqs:{challenge:2},grant:["challenge",3],condition:()=>"standard"!==t.race.universe,cost:{Plasmid:()=>400},action:()=>!!ze("universal"),post(){lc(!0)}},standard:{id:"genes-standard",title:F("arpa_genepool_standard_title"),desc:F("arpa_genepool_standard_desc"),reqs:{challenge:3},grant:["challenge",4],condition:()=>"standard"!==t.race.universe,cost:{Plasmid:()=>2500},action:()=>!!ze("standard"),post(){lc(!0)}},mastered:{id:"genes-mastered",title:F("arpa_genepool_mastered_title"),desc:F("arpa_genepool_mastered_desc"),reqs:{challenge:4},grant:["challenge",5],cost:{Plasmid:()=>4e3},action:()=>!!ze("mastered")},negotiator:{id:"genes-negotiator",title:F("arpa_genepool_negotiator_title"),desc:F("arpa_genepool_negotiator_desc"),reqs:{challenge:2},grant:["trader",1],cost:{Plasmid:()=>750},action:()=>!!ze("negotiator")&&(t.genes.trader=1,We(),!0)},ancients:{id:"genes-ancients",title:F("arpa_genepool_ancients_title"),desc:F("arpa_genepool_ancients_desc"),reqs:{evolve:2},condition:()=>!!t.genes.old_gods,grant:["ancients",1],cost:{Plasmid:()=>120},action:()=>!!ze("ancients")&&(t.genes.ancients=1,ms(),!0)},faith:{id:"genes-faith",title:F("arpa_genepool_faith_title"),desc:F("arpa_genepool_faith_desc"),reqs:{ancients:1},grant:["ancients",2],cost:{Plasmid:()=>300},action:()=>!!ze("faith")&&(t.civic.priest.display=!0,!0)},devotion:{id:"genes-devotion",title:F("arpa_genepool_devotion_title"),desc:F("arpa_genepool_devotion_desc"),reqs:{ancients:2},grant:["ancients",3],cost:{Plasmid:()=>600},action:()=>!!ze("devotion")},acolyte:{id:"genes-acolyte",title:F("arpa_genepool_acolyte_title"),desc:F("arpa_genepool_acolyte_desc"),reqs:{ancients:3},grant:["ancients",4],cost:{Plasmid:()=>1e3},action:()=>!!ze("acolyte")},conviction:{id:"genes-conviction",title:F("arpa_genepool_conviction_title"),desc:F("arpa_genepool_conviction_desc"),reqs:{ancients:4},grant:["ancients",5],cost:{Plasmid:()=>1500},action:()=>!!ze("conviction")},transcendence:{id:"genes-transcendence",title:F("arpa_genepool_transcendence_title"),desc:F("arpa_genepool_transcendence_desc"),reqs:{ancients:1,mutation:3},grant:["transcendence",1],cost:{Plasmid:()=>3e3},action:()=>!!ze("transcendence")&&(t.genes.transcendence=1,ms(),!0)},bleeding_effect:{id:"genes-bleeding_effect",title:F("arpa_genepool_bleeding_effect_title"),desc:F("arpa_genepool_bleeding_effect_desc",[2.5]),reqs:{creep:2},grant:["bleed",1],condition:()=>"antimatter"===t.race.universe,cost:{Plasmid:()=>100},action:()=>!!ze("bleeding_effect")},synchronicity:{id:"genes-synchronicity",title:F("arpa_genepool_synchronicity_title"),desc:F("arpa_genepool_synchronicity_desc",[25]),reqs:{bleed:1},grant:["bleed",2],cost:{Plasmid:()=>500},action:()=>!!ze("synchronicity")},astral_awareness:{id:"genes-astral_awareness",title:F("arpa_genepool_astral_awareness_title"),desc:F("arpa_genepool_astral_awareness_desc"),reqs:{bleed:2},grant:["bleed",3],cost:{Plasmid:()=>1e3},action:()=>!!ze("astral_awareness")},blood_remembrance:{id:"genes-blood_remembrance",title:F("arpa_genepool_blood_remembrance_title"),desc:F("arpa_genepool_blood_remembrance_desc"),reqs:{},grant:["blood",1],condition:()=>t.prestige.Blood_Stone.count>=1,cost:{Plasmid:()=>1e3,Phage:()=>10},action:()=>!!ze("blood_remembrance")},blood_sacrifice:{id:"genes-blood_sacrifice",title:F("arpa_genepool_blood_sacrifice_title"),desc:F("arpa_genepool_blood_sacrifice_desc"),reqs:{blood:1},grant:["blood",2],cost:{Plasmid:()=>3e3,Phage:()=>100,Artifact:()=>1},action:()=>!!ze("blood_sacrifice")},essence_absorber:{id:"genes-essence_absorber",title:F("arpa_genepool_essence_absorber_title"),desc:F("arpa_genepool_essence_absorber_desc"),reqs:{blood:2},grant:["blood",3],cost:{Plasmid:()=>7500,Phage:()=>250,Artifact:()=>1},action:()=>!!ze("essence_absorber"),post(){Re()}}},Fe={purify:{id:"blood-purify",title:F("arpa_blood_purify_title"),desc:F("arpa_blood_purify_desc"),reqs:{},grant:["spire",1],cost:{Blood_Stone:()=>10},action(){return!!Ae($(this)[0].cost)}},chum:{id:"blood-chum",title:F("arpa_blood_chum_title"),desc:F("arpa_blood_chum_desc"),reqs:{spire:1},grant:["spire",2],cost:{Blood_Stone:()=>25},action(){return!!Ae($(this)[0].cost)}},lust:{id:"blood-lust",title:F("arpa_blood_lust_title"),desc:F("arpa_blood_lust_desc"),reqs:{},grant:["lust","*"],cost:{Blood_Stone:e=>15*((e||0)+(t.blood.lust||0))+15,Artifact:e=>((e||0)+(t.blood.lust||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},illuminate:{id:"blood-illuminate",title:F("arpa_blood_illuminate_title"),desc:F("arpa_blood_illuminate_desc"),reqs:{},grant:["illuminate","*"],cost:{Blood_Stone:e=>12*((e||0)+(t.blood.illuminate||0))+12,Artifact:e=>((e||0)+(t.blood.illuminate||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},greed:{id:"blood-greed",title:F("arpa_blood_greed_title"),desc:F("arpa_blood_greed_desc"),reqs:{},grant:["greed","*"],cost:{Blood_Stone:e=>16*((e||0)+(t.blood.greed||0))+16,Artifact:e=>((e||0)+(t.blood.greed||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},hoarder:{id:"blood-hoarder",title:F("arpa_blood_hoarder_title"),desc:F("arpa_blood_hoarder_desc"),reqs:{},grant:["hoarder","*"],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:e=>14*((e||0)+(t.blood.hoarder||0))+14,Artifact:e=>((e||0)+(t.blood.hoarder||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},artisan:{id:"blood-artisan",title:F("arpa_blood_artisan_title"),desc:F("arpa_blood_artisan_desc"),reqs:{},grant:["artisan","*"],cost:{Blood_Stone:e=>8*((e||0)+(t.blood.artisan||0))+8,Artifact:e=>((e||0)+(t.blood.artisan||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},attract:{id:"blood-attract",title:F("arpa_blood_attract_title"),desc:F("arpa_blood_attract_desc"),reqs:{},grant:["attract","*"],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:e=>4*((e||0)+(t.blood.attract||0))+4,Artifact:e=>((e||0)+(t.blood.attract||0))%5==0?1:0},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},wrath:{id:"blood-wrath",title:F("arpa_blood_wrath_title"),desc:F("arpa_blood_wrath_desc"),reqs:{},grant:["wrath","*"],cost:{Blood_Stone:e=>2*((e||0)+(t.blood.wrath||0))+2,Artifact:()=>1},effect:()=>`${F("arpa_blood_repeat")}`,action(){return!!Ae($(this)[0].cost)}},prepared:{id:"blood-prepared",title:F("arpa_blood_prepared_title"),desc:F("arpa_blood_prepared_desc"),reqs:{},grant:["prepared",1],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>50},action(){return!!Ae($(this)[0].cost)},post(){Sa()}},compact:{id:"blood-compact",title:F("arpa_blood_compact_title"),desc:F("arpa_blood_compact_desc"),reqs:{prepared:1},grant:["prepared",2],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>75},action(){return!!Ae($(this)[0].cost)}},infernal:{id:"blood-infernal",title:F("arpa_blood_infernal_title"),desc:F("arpa_blood_infernal_desc"),reqs:{prepared:2},grant:["prepared",3],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>125,Artifact:()=>1},action(){return!!Ae($(this)[0].cost)}},unbound:{id:"blood-unbound",title:F("arpa_blood_unbound_title"),desc:F("arpa_blood_unbound_desc"),reqs:{},grant:["unbound",1],cost:{Blood_Stone:()=>50},action(){return!!Ae($(this)[0].cost)}},unbound_resistance:{id:"blood-unbound_resistance",title:F("arpa_blood_unbound_resistance_title"),desc:F("arpa_blood_unbound_resistance_desc"),reqs:{unbound:1},grant:["unbound",2],cost:{Blood_Stone:()=>100},action(){return!!Ae($(this)[0].cost)}},shadow_war:{id:"blood-shadow_war",title:F("arpa_blood_shadow_war_title"),desc:F("arpa_blood_shadow_war_desc"),reqs:{unbound:2},grant:["unbound",3],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>250,Artifact:()=>2},action(){return!!Ae($(this)[0].cost)}},unbound_immunity:{id:"blood-unbound_immunity",title:F("arpa_blood_unbound_immunity_title"),desc:F("arpa_blood_unbound_immunity_desc"),reqs:{unbound:3},grant:["unbound",4],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>500},action(){return!!Ae($(this)[0].cost)}},blood_aware:{id:"blood-blood_aware",title:F("arpa_blood_blood_aware_title"),desc:F("arpa_blood_blood_aware_desc"),reqs:{},grant:["aware",1],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>10},action(){return!!Ae($(this)[0].cost)}}};function ze(e){let a=!0,r=Se[e].cost;return Object.keys(r).forEach((function(e){let s=e;"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].countNumber(t.resource[r].amount))return a=!1,!1})),a}(e=Ke(e))&&(Object.keys(e).forEach((function(a){t.resource[a].amount-=e[a]()/100})),!0)}function Ke(e,a,r){return e=function(e,a,r){if(r&&r.creative||!r&&t.race.creative){var s={};let t=Pi("human");return Object.keys(e).forEach((function(i){s[i]=function(){let s=e[i](a,r);return s*=1-ui.creative.vars()[1]/100,t>0&&(s*=1-ui.creative.vars(1)[1]/100*t),s}})),s}return e}(e,a,r),gc({cost:e},a,r)}function Le(e,a,r,s,i){var c=t.arpa[e]?t.arpa[e].rank:0;return(i&&i.creative||!i&&t.race.creative)&&"syphon"!==e&&(s-=ui.creative.vars()[0]),a&&(c+=a),Math.round(s**c*r)}function Ne(){if(t.tech.high_tech&&t.tech.high_tech>=6){let e=$("#arpaPhysics");rc(e),Object.keys(Ce).forEach((function(a){!function(e,a){if(function(e){if(Ce[e].condition&&!Ce[e].condition())return!1;let a=t.race.truepath?"truepath":"standard";if(Ce[e].hasOwnProperty("path")&&!Ce[e].path.includes(a))return!1;var r=!0;return Object.keys(Ce[e].reqs).forEach((function(a){(!t.tech[a]||t.tech[a]=Ce[a].rank)return;let r=$(`
          `);e.append(r);let s="string"==typeof Ce[a].title?Ce[a].title:Ce[a].title(),i=$(`
          ${s}{{ rank | level }}
          `);r.append(i);let c=$('
          {{ complete }}%
          ');i.append(c);let o=$('
          ');r.append(o),o.append($(``)),o.append($(``)),o.append($(``)),o.append($(``)),o.append($(``)),sc({el:`#arpa${a}`,data:t.arpa[a],methods:{queue(e){if(t.tech.queue){let r=y();for(let s=0;s0))break;if("merge_never"!==t.settings.q_merge&&t.queue.queue.length>0&&t.queue.queue[t.queue.queue.length-1].id===r)t.queue.queue[t.queue.queue.length-1].q++;else{let a="string"==typeof Ce[e].title?Ce[e].title:Ce[e].title();t.queue.queue.push({id:r,action:"arpa",type:e,label:a,cna:!1,time:0,q:1,qs:1,t_max:0})}Ui()}}},build(e,t){He(e,t,!0)},srDesc:()=>q(Ce[a].desc),srLevel:()=>q(Ce[a].effect()),arpaProjectSRCosts(e,a){let r="100"===e?100-t.arpa[a].complete:e;var s=`Construct ${r}%. Costs:`,i=Ke(Ce[a].cost);return Object.keys(i).forEach((function(e){var a=+(i[e]()*(r/100)).toFixed(0);if(a>0){var c="Money"===e?"$":t.resource[e].name+": ",o=t.resource[e].amount>=a?"":` ${F("insufficient")} ${t.resource[e].name}.`;s+=` ${c} ${k(a,2)}.${o}`}})),s}},filters:{remain:e=>100-e,level:e=>F("arpa_level",[e])}}),Ti(`popArpa${a}`,(function(){return Ce[a].desc}),{elm:`#arpa${a} .head .desc`,classes:"has-background-light has-text-dark"}),Ti(`popArpa${a}`,(function(){return Ce[a].effect()}),{elm:`#arpa${a} .head .rank`,classes:"has-background-light has-text-dark"});let n=[1,10,25,100];for(let e=0;e1){let a=$('
          ');e.append(a);let r=t.tech.genetics>2?F("arpa_gene_mutation"):F("arpa_sequence_genome");t.race.artifical&&(r=t.tech.genetics>2?F("arpa_code_modification"):F("arpa_decompile_source"));let s=$(`
          ${r} - ${F("arpa_to_complete")}
          `);a.append(s);let i=$(`{{ progress }}%`);a.append(i);let c=t.tech.genetics>2?F("arpa_mutate"):F("arpa_sequence");t.race.artifical&&(c=t.tech.genetics>2?F("arpa_modify"):F("arpa_decompile"));let o=$(``);if(a.append(o),t.tech.genetics>=5){let e=$(``);a.append(e)}if(t.tech.genetics>=6){let e=$(``);a.append(e)}if(t.tech.genetics>=7){let e=$(``);a.append(e)}t.arpa.sequence.on&&$("#arpaSequence button.seq").addClass("has-text-success"),t.arpa.sequence.boost&&$("#arpaSequence button.boost").addClass("has-text-success"),t.arpa.sequence.auto&&$("#arpaSequence button.auto").addClass("has-text-success"),sc({el:"#arpaSequence",data:t.arpa.sequence,methods:{toggle(){t.arpa.sequence.on?(t.arpa.sequence.on=!1,$("#arpaSequence button.seq").removeClass("has-text-success")):(t.arpa.sequence.on=!0,$("#arpaSequence button.seq").addClass("has-text-success"))},booster(){t.arpa.sequence.boost?(t.arpa.sequence.boost=!1,$("#arpaSequence button.boost").removeClass("has-text-success")):(t.arpa.sequence.boost=!0,$("#arpaSequence button.boost").addClass("has-text-success"))},boostLabel:e=>F(t.race.artifical?"arpa_boost_artifical_label":"arpa_boost_label")+(e?t.arpa.sequence.boost?F("city_on"):F("city_off"):""),novo(){let e=y();for(let a=0;a=2e5;a++)t.resource.Knowledge.amount-=2e5,t.resource.Genes.amount++},novoLabel:()=>F(t.race.artifical?"arpa_novo_artifical_label":"arpa_novo_label",["200k"]),auto_seq(){t.arpa.sequence.auto?(t.arpa.sequence.auto=!1,$("#arpaSequence button.auto").removeClass("has-text-success")):(t.arpa.sequence.auto=!0,$("#arpaSequence button.auto").addClass("has-text-success"))},autoLabel:e=>F(t.race.artifical?"arpa_auto_compile_label":"arpa_auto_seq_label")+(e?t.arpa.sequence.boost?F("city_on"):F("city_off"):"")},filters:{timer(e){if(t.arpa.sequence.on&&t.arpa.sequence.labs>0){const a=e/(t.settings.gameSpeed*t.arpa.sequence.labs);return t.arpa.sequence.boost?ic(a/2):ic(a)}{let e=$c(14,12);return e.length>0?e:F("time_never")}}}}),Ti("popArpaSeq",(function(){return t.tech.genetics>2?t.race.artifical?F("arpa_modify_desc"):F("arpa_mutate_desc"):t.race.artifical?F("arpa_decompile_desc"):F("arpa_sequence_desc")}),{elm:"#arpaSequence .seqlbl",classes:"has-background-light has-text-dark"})}if(t.tech.genetics>2){let e=$('
          ');$("#arpaGenetics").append(e);let a=$('
          ');e.append(a),t.tech.decay&&t.tech.decay>=2&&(t.settings.mtorder.includes("fortify")||t.settings.mtorder.push("fortify")),Object.keys(t.race).forEach((function(e){ui[e]&&"minor"===ui[e].type&&(t.settings.mtorder.includes(e)||t.settings.mtorder.push(e))})),t.genes.challenge&&t.genes.challenge>=5&&(t.settings.mtorder.includes("mastery")||t.settings.mtorder.push("mastery"));let r=!1,s=[];t.settings.mtorder.forEach((function(e){(ui[e]&&"minor"===ui[e].type||"mastery"===e||"fortify"===e)&&("fortify"!==e||t.tech.decay&&t.tech.decay>=2)&&(!["promiscuous","content","resilient","industrious","tactical","fibroblast"].includes(e)&&t.race.lone_survivor||!t.race.lone_survivor)&&(r=!0,function(e,a){let r=$(`
          `),s=$(`${t.resource.Genes.name} (${t.race.minor[a]||0})`);if(r.append(s),t.prestige.Phage.count>0){let e=$(`${F("resource_Phage_name")} (${t.genes.minor[a]||0})`);r.append(e)}let i=t.race[a]>1?`(${t.race[a]}) `:"";r.append(`${i}${Oi("name",a)}`),e.append(r)}(a,e),s.push(e))})),e.append(`
          ${F("arpa_race_genetic_traids",[Ac("name")])}
          `);let i=Oi("name"),c=[],o=[],n=$('
          ');e.append(n);let l=zc(t.race);Tc("fool",2023)&&(l.hooved=1),Object.keys(l).forEach((function(e){if(ui[e]&&"minor"!==ui[e].type&&"special"!==ui[e].type&&"evil"!==e&&"soul_eater"!==e&&"artifical"!==e){let a=!1;if(t.race.ss_traits&&t.race.ss_traits.includes(e)||t.race.iTraits&&t.race.iTraits.hasOwnProperty(e)?a=!0:("sludge"!==t.race.species||"ooze"!==e&&!t.race.modified)&&t.race.hasOwnProperty(e)||(a=!0),!a&&("major"===ui[e].type&&t.genes.mutation||"genus"===ui[e].type&&t.genes.mutation&&t.genes.mutation>=2)){let t=$('
          '),a=$(`${F("arpa_remove_button")}`);c.push(e),t.append(a),t.append($(`${i[e]?i[e]:ui[e].name} (${F("arpa_genepool_rank",[l[e]])})`)),n.append(t)}else o.push(e),n.append(`
          ${i[e]?i[e]:ui[e].name} (${F("arpa_genepool_rank",[l[e]])})
          `)}}));let u=[];if(t.genes.mutation&&t.genes.mutation>=3&&("sludge"!==t.race.species||!t.race.modified)){e.append(`
          ${F("arpa_race_genetic_gain")}
          `);let a=["dumb","smart"];Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&"custom"!==e&&di[e].type===di[t.race.species].type&&Object.keys(di[e].traits).forEach((function(e){if(!t.race[e]&&"soul_eater"!==e){let r=a.indexOf(e);if(-1===r)u.push(e);else{let s=!1;switch(r%2){case 0:t.race[a[r+1]]&&(s=!0);break;case 1:t.race[a[r-1]]&&(s=!0)}s||u.push(e)}}}))}));let r=$('
          ');e.append(r);for(let e=0;e
          '),s=$(`${F("arpa_gain_button")}`);a.append(s),a.append($(`${i[t]?i[t]:ui[t].name}`)),r.append(a)}}r&&e.prepend(`
          ${F("arpa_race_genetic_minor_traits",[Ac("name")])}
          `);let d=function(e){let a=5*ui[e].val;return"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1),F("arpa_remove",[Oi("name",e),a,"antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name")])},_=function(e){let a=5*ui[e].val;return"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1),F("arpa_gain",[Oi("name",e),a,"antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name")])},p=function(e){let a=Oc(t.race.minor[e]?t.race.minor[e]+4:4);return"mastery"===e&&(a*=5),F("arpa_gene_buy",[Oi("name",e),k(a),t.resource.Genes.name])},h=function(e){let a=Oc(t.genes.minor[e]?t.genes.minor[e]+4:4);return"mastery"===e&&(a*=2),F("arpa_phage_buy",[Oi("name",e),k(a),F("resource_Phage_name")])};sc({el:"#geneticBreakdown",data:{genes:t.genes,race:t.race},methods:{gene(e){let a=0,r=y(),s=!0,i=!1;for(;a=r?(t.resource.Genes.amount-=r,t.race.minor[e]?t.race.minor[e]++:t.race.minor[e]=1,t.race[e]?t.race[e]++:t.race[e]=1,i=!0):s=!1,a++}i&&("mastery"===e&&lc(!0),Be(),"persuasive"===e&&We())},phage(e){let a=0,r=y(),s=!0,i=!1;for(;a=r?(t.prestige.Phage.count-=r,t.genes.minor[e]?t.genes.minor[e]++:t.genes.minor[e]=1,t.race[e]?t.race[e]++:t.race[e]=1,i=!0):s=!1,a++}i&&("mastery"===e&&lc(!0),Be(),"persuasive"===e&&We())},purge(e){if("sludge"===t.race.species&&(t.race.modified||"ooze"===e))return;let a=5*ui[e].val;"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1);let r="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";if(t.prestige[r].count>=a){t.prestige[r].count-=a;let s=t.race[e];delete t.race[e],t.race.modified?t.race.modified++:t.race.modified=1,xi(e,s),Be(),ms(),hs();let i=0;Object.keys(t.race).forEach((function(e){!ui[e]||"major"!=ui[e].type&&"genus"!=ui[e].type||"evil"===e||i++})),0===i&&eo("blank_slate")}},gain(e){if("sludge"===t.race.species&&t.race.modified)return;let a=5*ui[e].val;"sludge"===t.race.species&&(a*=2),"custom"===t.race.species&&(a*=10),a<0&&(a*=-1);let r="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";t.prestige[r].count>=a&&(t.prestige[r].count-=a,t.race[e]=1,t.race.modified?t.race.modified++:t.race.modified=1,$i(e),Be(),ms(),hs())},geneCost:e=>p(e),phageCost:e=>h(e),traitEffect:e=>F(`trait_${e}_effect`),removeCost:e=>d(e),addCost:e=>_(e),genePurchasable(e){let a=Oc(t.race.minor[e]?t.race.minor[e]+4:4);return"mastery"===e&&(a*=5),t.resource.Genes.amount>=a},phagePurchasable(e){let a=Oc(t.genes.minor[e]?t.genes.minor[e]+4:4);return"mastery"===e&&(a*=2),t.prestige.Phage.count>=a}}}),s.forEach((function(e){Ti(`popGenetrait${e}`,(function(){return p(e)}),{elm:`#geneticBreakdown .t-${e} .gbuy`,classes:"has-background-light has-text-dark"}),t.prestige.Phage.count>0&&Ti(`popGenetrait${e}`,(function(){return h(e)}),{elm:`#geneticBreakdown .t-${e} .pbuy`,classes:"has-background-light has-text-dark"}),Ti(`popGenetrait${e}`,(function(){return t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0?`
          ${Oi("desc",e)}
          ${F(`trait_${e}_effect`)}
          `:Oi("desc",e)}),{elm:`#geneticBreakdown .t-${e} .name`,classes:"has-background-light has-text-dark"})})),c.forEach((function(e){Ti(`popRemoveBkdwn${e}`,(function(){return d(e)}),{elm:`#geneticBreakdown .remove${e}`,classes:"has-background-light has-text-dark"});let a=`raceTrait${e}`,r=$("
          ");Hc(r,e,{trank:t.race[e]}),Ti(a,r,{wide:!0,classes:"w30"})})),o.forEach((function(e){let a=`raceTrait${e}`,r=$("
          ");Hc(r,e,{trank:t.race[e]}),Ti(a,r,{elm:`#geneticBreakdown .trait${e}`,wide:!0,classes:"w30"})})),u.forEach((function(e){Ti(`popAddBkdwn${e}`,(function(){return _(e)}),{elm:`#geneticBreakdown .add${e}`,classes:"has-background-light has-text-dark"});let a=`raceTrait${e}`,r=$("
          ");Hc(r,e,{trank:t.race[e]}),Ti(a,r,{wide:!0,classes:"w30"})})),function(){let e=$("#geneticMinor")[0];e&&Sortable.create(e,{onEnd(e){let a=t.settings.mtorder;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.settings.mtorder=a,Be()}})}()}}function Ge(){(t.tech.genetics&&t.tech.genetics>3||t.sim)&&(rc($("#arpaCrispr")),$("#arpaCrispr").append(`
          ${F("arpa_crispr_desc")}
          `),$("#arpaCrispr").append('
          '),Object.keys(Qr.genes).forEach((function(e){Ms(Qr.genes[e].id),function(e){var a=!0;return Object.keys(Qr.genes[e].reqs).forEach((function(r){(!t.genes[r]||t.genes[r]=2&&(rc($("#arpaBlood")),$("#arpaBlood").append(`
          ${F("arpa_blood_desc")}
          `),$("#arpaBlood").append('
          '),Object.keys(Qr.blood).forEach((function(e){Ms(Qr.blood[e].id),function(e){var a=!0;return Object.keys(Qr.blood[e].reqs).forEach((function(r){(!t.blood[r]||t.blood[r]=100&&(t.arpa[e].rank++,t.arpa[e].complete=0,t.tech[Ce[e].grant]=t.arpa[e].rank,i=!0,"monument"===e&&(t.arpa.m_type=Te(),$(`#arpa${e} .head .desc`).html(Ce[e].title()),Ks(!1,["arpamonument"])),"roid_eject"===e&&($(`#arpa${e} .head .desc`).html(Ce[e].title()),Ks(!1,["arparoid_eject"])),"launch_facility"===e&&(t.settings.showSpace=!0,t.tech.space=1,Ei("popArpalaunch_facility"),[1,10,25,100].forEach((function(e){Ei(`popArpalaunch_facility${e}`)})),s||Bi(["arpalaunch_facility"]),Ne(),Rt(),Di(F("arpa_projects_launch_facility_msg"),"info",!1,["progress"])),t.race.inflation&&(t.race.inflation+=10),ms()));if(r){let t=[1,10,25,100],a=$("#popper"),r=a.data("id");for(let s=0;s
          "),i=Ke(Ce[a].cost);let c=ac(Ce[a],r/100,!1,!0);return Object.keys(i).forEach((function(e){var a=+(i[e]()*(r/100)).toFixed(0);if(a>0){var o="Money"===e?"$":t.resource[e].name+": ",n=t.resource[e].amount>=a?"has-text-dark":e===c.r?"has-text-danger":"has-text-alert";s.append($(`
          ${o}${k(a,2)}
          `))}})),s}function We(){Object.keys(t.resource).forEach((function(e){sc({el:`#market-${e}`},"update")})),sc({el:"#galaxyTrade"},"update")}const Qe={spc_titan:{info:{name:()=>Xt().titan,desc:()=>F("space_titan_info_desc",[Xt().titan,di[t.race.species].home]),support:"electrolysis",zone:"outer",syndicate:()=>!!(t.tech.titan&&t.tech.titan>=3&&t.tech.enceladus&&t.tech.enceladus>=2),syndicate_cap:()=>t.tech.triton?t.tech.outer>=4?2e3:1e3:600},titan_mission:{id:"space-titan_mission",title:()=>F("space_mission_title",[Xt().titan]),desc:()=>F("space_mission_desc",[Xt().titan]),reqs:{outer:1},grant:["titan",1],path:["truepath"],queue_complete:()=>t.tech.titan>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(25e4,!1,t).toFixed(0),Elerium:()=>100},effect:()=>F("space_titan_mission_effect",[Xt().titan]),action(){return!!Os($(this)[0])&&(Di(F("space_titan_mission_action",[Xt().titan,di[t.race.species].home]),"info",!1,["progress"]),!0)}},titan_spaceport:{id:"space-titan_spaceport",title:F("space_red_spaceport_title"),desc:`
          ${F("space_red_spaceport_desc")}
          ${F("requires_power")}
          `,reqs:{titan:1},path:["truepath"],cost:{Money:e=>Xi("titan_spaceport",e,25e5,1.32),Lumber:e=>Xi("titan_spaceport",e,75e4,1.32),Cement:e=>Xi("titan_spaceport",e,35e4,1.32),Mythril:e=>Xi("titan_spaceport",e,1e4,1.32)},effect(){let e=t.resource.Water.display?`
          ${F("plus_max_resource",[k(Lr(250)),t.resource.Water.name])}
          `:"";return`${t.tech.enceladus&&t.tech.enceladus>=2?`
          +${F("galaxy_alien2_support",[$(this)[0].support(),Xt().enceladus])}
          `:""}${e}${t.tech.titan&&t.tech.titan>=5?`
          ${F("space_titan_spaceport_storage",[25])}
          `:""}
          ${F("minus_power",[$(this)[0].powered()])}
          `},support:()=>2,powered:()=>oc(10),action(){return!!Os($(this)[0])&&(t.space.titan_spaceport.count++,xs($(this)[0]),!0)},post(){1===t.tech.titan&&(t.tech.titan=2,ms())}},electrolysis:{id:"space-electrolysis",title:F("space_electrolysis_title"),desc:()=>`
          ${F("space_electrolysis_title")}
          ${F("space_electrolysis_req",[t.resource.Water.name])}
          `,reqs:{titan:3},path:["truepath"],cost:{Money:e=>Xi("electrolysis",e,1e6,1.25),Copper:e=>Xi("electrolysis",e,185e3,1.25),Steel:e=>Xi("electrolysis",e,22e4,1.25),Polymer:e=>Xi("electrolysis",e,38e4,1.25)},effect(){return`
          +${F("galaxy_alien2_support",[$(this)[0].support(),Xt().titan])}
          ${F("space_electrolysis_use",[$(this)[0].support_fuel().a,t.resource.Water.name,$(this)[0].powered()])}
          `},support:()=>t.tech.titan_ai_core&&t.tech.titan_ai_core>=2&&i.ai_core2?3:2,support_fuel:()=>({r:"Water",a:35}),powered:()=>oc(8),action(){return!!Os($(this)[0])&&(t.space.electrolysis.count++,xs($(this)[0]),!0)},post(){3===t.tech.titan&&(t.tech.titan=4,ms())}},hydrogen_plant:{id:"space-hydrogen_plant",title:F("space_hydrogen_plant_title"),desc:()=>`
          ${F("space_hydrogen_plant_title")}
          ${F("space_hydrogen_plant_req")}
          `,reqs:{titan_power:1},path:["truepath"],cost:{Money:e=>Xi("hydrogen_plant",e,15e5,1.28),Iridium:e=>Xi("hydrogen_plant",e,292e3,1.28),Stanene:e=>Xi("hydrogen_plant",e,599e3,1.28),Cement:e=>Xi("hydrogen_plant",e,18e4,1.28)},effect(){return`${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${F("space_hydrogen_plant_effect",[1,F("space_electrolysis_title")])}`},support:()=>2,powered:()=>cc(-22),action(){return!!Os($(this)[0])&&(t.space.hydrogen_plant.count++,t.space.electrolysis.on>t.space.hydrogen_plant.on&&t.space.hydrogen_plant.on++,!0)}},titan_quarters:{id:"space-titan_quarters",title:F("interstellar_habitat_title"),desc:()=>`
          ${F("interstellar_habitat_title")}
          ${F("space_habitat_req",[Xt().titan,t.resource.Food.name,t.resource.Water.name])}
          `,reqs:{titan:4},path:["truepath"],cost:{Money:e=>Xi("titan_quarters",e,12e5,1.28),Furs:e=>Xi("titan_quarters",e,85e3,1.28),Plywood:e=>Xi("titan_quarters",e,1e5,1.28),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=la(1);return`
          ${F("space_used_support",[Xt().titan])}
          ${F("plus_max_resource",[la(1),t.race.truepath?F("job_colonist_tp",[Xt().titan]):F("colonist")])}
          ${F("plus_max_resource",[e,F("citizen")])}
          ${F("spend",[$(this)[0].support_fuel()[0].a,t.resource[$(this)[0].support_fuel()[0].r].name])}
          ${F("spend",[$(this)[0].support_fuel()[1].a,t.resource[$(this)[0].support_fuel()[1].r].name])}
          `},support:()=>-1,support_fuel:()=>[{r:"Water",a:12},{r:"Food",a:500}],powered:()=>oc(1),action(){if(Os($(this)[0])){if(t.space.titan_quarters.count++,t.civic.titan_colonist.display=!0,t.space.electrolysis.support0)){let e=t.civic[t.civic.d_job].workers-la(1)<0?t.civic[t.civic.d_job].workers:la(1);t.civic[t.civic.d_job].workers-=e,t.civic.titan_colonist.workers+=e}return!0}return!1},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},titan_mine:{id:"space-titan_mine",title:F("space_red_mine_title"),desc:()=>`
          ${F("space_red_mine_desc")}
          ${F("space_support",[Xt().titan])}
          `,reqs:{titan:4},condition:()=>!!(t.space.titan_quarters&&t.space.titan_quarters.count>0),path:["truepath"],cost:{Money:e=>Xi("titan_mine",e,475e3,1.28),Lumber:e=>Xi("titan_mine",e,568e3,1.28),Wrought_Iron:e=>Xi("titan_mine",e,25e4,1.28)},effect(){let e=Pe("titan_mine","adamantite"),a=Pe("titan_mine","aluminium"),r=+e.toFixed(3),s=+a.toFixed(3);return`
          ${F("space_used_support",[Xt().titan])}
          ${F("space_red_mine_effect",[r,t.resource.Adamantite.name])}
          ${F("space_red_mine_effect",[s,t.resource.Aluminium.name])}
          `},support:()=>-1,powered:()=>oc(1),special:()=>!0,action(){return!!Os($(this)[0])&&(t.space.titan_mine.count++,t.resource.Adamantite.display=!0,t.space.electrolysis.supportXi("storehouse",e,175e3,1.28),Lumber:e=>Xi("storehouse",e,1e5,1.28),Aluminium:e=>Xi("storehouse",e,12e4,1.28),Cement:e=>Xi("storehouse",e,45e3,1.28)},wide:!0,res:()=>["Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Alloy","Polymer","Iridium","Chrysotile","Nano_Tube","Neutronium","Adamantite"],heavy:e=>!!["Copper","Iron","Steel","Titanium","Iridium","Neutronium","Adamantite"].includes(e),val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 3e3;case"Furs":return 1700;case"Copper":return 1520;case"Iron":return 1400;case"Aluminium":return 1280;case"Cement":return 1120;case"Coal":return 480;case"Steel":return 240;case"Titanium":return 160;case"Alloy":return 180;case"Polymer":return 150;case"Iridium":return 175;case"Nano_Tube":return 120;case"Neutronium":return 64;case"Adamantite":return 72;default:return 0}},effect(){let e='
          ',a=bt("storehouse",!1),r=bt("storehouse",!0);for(const s of $(this)[0].res())if(t.resource[s].display){let i=$(this)[0].heavy(s);e+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(s))*(i?r:a)).toFixed(0),1),t.resource[s].name])}`}return e+="
          ",e},action(){if(Os($(this)[0])){t.space.storehouse.count++;let e=bt("storehouse",!1),a=bt("storehouse",!0);for(const r of $(this)[0].res())if(t.resource[r].display){let s=$(this)[0].heavy(r);t.resource[r].max+=Lr($(this)[0].val(r))*(s?a:e)}return!0}return!1}},titan_bank:{id:"space-titan_bank",title:F("city_bank"),desc:()=>F("city_bank_desc",[Xt().titan]),reqs:{titan:6},path:["truepath"],cost:{Money:e=>Xi("titan_bank",e,25e5,1.32),Titanium:e=>Xi("titan_bank",e,38e4,1.32),Neutronium:e=>Xi("titan_bank",e,5e3,1.32)},effect(){let e=2*Hs();return e=Lr(e),e=(+e.toFixed(0)).toLocaleString(),F("plus_max_resource",[`$${e}`,F("resource_Money_name")])},action(){return!!Os($(this)[0])&&(t.resource.Money.max+=Lr(1800),t.space.titan_bank.count++,!0)}},g_factory:{id:"space-g_factory",title:F("interstellar_g_factory_title"),desc:()=>`
          ${F("interstellar_g_factory_title")}
          ${F("space_support",[Xt().titan])}
          `,reqs:{graphene:1},path:["truepath"],cost:{Money:e=>Xi("g_factory",e,95e4,1.28),Copper:e=>Xi("g_factory",e,165e3,1.28),Stone:e=>Xi("g_factory",e,22e4,1.28),Adamantite:e=>Xi("g_factory",e,12500,1.28)},effect(){let e=.05;return t.race.high_pop&&(e=+Me(e).toFixed(3)),`
          ${F("space_used_support",[Xt().titan])}
          ${F("space_red_mine_effect",[e,t.resource.Graphene.name])}
          ${F("interstellar_g_factory_effect")}
          `},support:()=>-1,powered:()=>oc(1),special:!0,action(){return!!Os($(this)[0])&&(t.space.g_factory.count++,t.resource.Graphene.display=!0,t.space.electrolysis.support`
          ${F("space_sam_desc")}
          ${F("requires_power")}
          `,reqs:{titan:7},path:["truepath"],cost:{Money:e=>Xi("sam",e,25e5,1.28),Steel:e=>Xi("sam",e,45e4,1.28),Elerium:e=>Xi("sam",e,120,1.28),Brick:e=>Xi("sam",e,16e4,1.28)},effect(){return`
          ${F("galaxy_defense_platform_effect",[25])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(5),action(){return!!Os($(this)[0])&&(t.space.sam.count++,xs($(this)[0]),!0)},post(){sc({el:"#spc_titansynd"},"update")}},decoder:{id:"space-decoder",title:F("space_decoder_title"),desc:()=>`
          ${F("space_decoder_title")}
          ${F("requires_power_support_combo",[Xt().titan,t.resource.Cipher.name])}
          `,reqs:{titan:8},path:["truepath"],cost:{Money:e=>Xi("decoder",e,125e5,1.275),Elerium:e=>Xi("decoder",e,750,1.275),Orichalcum:e=>Xi("decoder",e,33e4,1.275),Quantium:e=>Xi("decoder",e,18e4,1.275)},effect(){let e=$(this)[0].support_fuel().a,a=2500;t.race.high_pop&&(a=Me(a)),i.ai_core2&&(a*=1.25);let r=`
          ${F("space_used_support",[Xt().titan])}
          `;return r+=`
          ${F("space_red_exotic_lab_effect1",[a])}
          `,r+`
          ${F("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
          `},support:()=>-1,powered:()=>oc(1),support_fuel:()=>({r:"Cipher",a:.06}),action(){return!!Os($(this)[0])&&(t.space.decoder.count++,t.space.electrolysis.support!t.space.hasOwnProperty("ai_core")||t.space.ai_core.count<100||e?`
          ${F("space_ai_core")}
          ${F("requires_segmemts",[100])}
          `+(t.space.hasOwnProperty("ai_core")&&t.space.ai_core.count>=100?`
          ${F("requires_power")}
          `:""):`
          ${F("space_ai_core")}
          `,reqs:{titan:9},path:["truepath"],condition:()=>!(t.space.ai_core.count>=100),queue_size:10,queue_complete:()=>100-t.space.ai_core.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?25e5:0,Cement:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?18e4:0,Aluminium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?25e4:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?250:0,Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?125e3:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?5e4:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?1e5:0,Cipher:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?750:0},effect(e){let a=`
          ${F("space_ai_core_effect")}
          `,r=(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0);return r<100?(a+=`
          ${F("space_dwarf_collider_effect2",[100-r])}
          `,a):Qe.spc_titan.ai_core2.effect()},action(){return!!(Os($(this)[0])&&t.space.ai_core.count<100)&&(t.space.ai_core.count++,t.space.ai_core.count>=100&&(t.tech.titan_ai_core=1,t.space.ai_core2={count:1,on:0},t.city.power>=Qe.spc_titan.ai_core2.powered()&&t.space.ai_core2.on++,Rt(),ms()),!0)}},ai_core2:{id:"space-ai_core2",title:F("space_ai_core"),desc(){return`
          ${F("space_ai_core")}
          ${F("space_electrolysis_req",[t.resource[$(this)[0].p_fuel().r].name])}
          `},reqs:{titan_ai_core:1},path:["truepath"],condition:()=>!!(t.space.hasOwnProperty("ai_core")&&t.space.ai_core.count>=100),wiki:!1,queue_complete:()=>0,cost:{},powered:()=>oc(100),p_fuel:()=>({r:"Water",a:1e3}),effect(){let e=`
          ${F("interstellar_citadel_stat",[+u.toFixed(1)])}
          `;return e+=`
          ${F("interstellar_citadel_effect",[25])}
          ${F("space_ai_core_effect2",[25])}
          `,t.tech.titan_ai_core&&t.tech.titan_ai_core>=2&&(e+=`
          ${F("space_ai_core_effect3",[50])}
          `),e+=`
          ${F("space_electrolysis_use",[$(this)[0].p_fuel().a,t.resource[$(this)[0].p_fuel().r].name,$(this)[0].powered()])}
          `,t.tech.titan_ai_core&&t.tech.titan_ai_core>=3&&(e+=`
          ${F("space_ai_core_effect4",[+wt().toFixed(1)])}
          `),e},action:()=>!1,flair:()=>t.space.hasOwnProperty("ai_core2")&&t.space.ai_core2.on>=1?F("space_ai_core_flair"):F("space_ai_core_flair2")},ai_colonist:{id:"space-ai_colonist",title:F("space_ai_colonist_title"),desc:()=>`
          ${F("space_ai_colonist_title")}
          ${F("requires_power")}
          `,reqs:{titan_ai_core:3},path:["truepath"],cost:{Money:e=>Xi("ai_colonist",e,112e6,1.35),Alloy:e=>Xi("ai_colonist",e,75e4,1.35),Elerium:e=>Xi("ai_colonist",e,500,1.35),Nano_Tube:e=>Xi("ai_colonist",e,525e3,1.35),Quantium:e=>Xi("ai_colonist",e,15e4,1.35),Cipher:e=>Xi("ai_colonist",e,1e4,1.35)},effect(){return`
          ${F("plus_max_resource",[la(1),t.race.truepath?F("job_colonist_tp",[Xt().titan]):F("colonist")])}
          ${F("space_ai_colonist_effect",[la(1),Xt().titan])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(10),action(){return!!Os($(this)[0])&&(t.space.ai_colonist.count++,xs($(this)[0]),!0)},flair:F("tech_combat_droids_flair")}},spc_enceladus:{info:{name:()=>Xt().enceladus,desc:()=>F("space_enceladus_info_desc",[Xt().enceladus,di[t.race.species].home]),support:"titan_spaceport",zone:"outer",syndicate:()=>!!(t.tech.titan&&t.tech.titan>=3&&t.tech.enceladus&&t.tech.enceladus>=2),syndicate_cap:()=>t.tech.triton?t.tech.outer>=4?1500:1e3:600},enceladus_mission:{id:"space-enceladus_mission",title:()=>F("space_mission_title",[Xt().enceladus]),desc:()=>F("space_mission_desc",[Xt().enceladus]),reqs:{outer:1},grant:["enceladus",1],path:["truepath"],queue_complete:()=>t.tech.enceladus>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(25e4,!1,t).toFixed(0),Elerium:()=>100},effect:()=>F("space_titan_mission_effect",[Xt().enceladus]),action(){return!!Os($(this)[0])&&(Di(F("space_enceladus_mission_action",[Xt().enceladus]),"info",!1,["progress"]),t.resource.Water.display=!0,!0)}},water_freighter:{id:"space-water_freighter",title:F("space_water_freighter_title"),desc:()=>`
          ${F("space_water_freighter_title")}
          ${F("space_support",[Xt().enceladus])}
          `,reqs:{enceladus:2},path:["truepath"],cost:{Money:e=>Xi("water_freighter",e,45e4,1.25),Iron:e=>Xi("water_freighter",e,362e3,1.25),Nano_Tube:e=>Xi("water_freighter",e,125e3,1.25),Sheet_Metal:e=>Xi("water_freighter",e,75e3,1.25)},effect(e){let a=+Jt(5,!0,e).toFixed(2),r=+Pe("water_freighter").toFixed(2);return`
          ${F("space_used_support",[Xt().enceladus])}
          ${F("produce",[r,t.resource.Water.name])}
          ${F("space_belt_station_effect3",[a])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.space.water_freighter.count++,t.space.titan_spaceport.support`
          ${F("tech_zero_g_lab")}
          ${F("requires_power_support",[Xt().enceladus])}
          `,reqs:{enceladus:3},path:["truepath"],cost:{Money:e=>Xi("zero_g_lab",e,5e6,1.25),Alloy:e=>Xi("zero_g_lab",e,125e3,1.25),Graphene:e=>Xi("zero_g_lab",e,225e3,1.25),Stanene:e=>Xi("zero_g_lab",e,6e5,1.25)},effect(){let e=ht("spc_enceladus"),a=Math.round(1e4*e),r=`
          ${F("space_used_support",[Xt().enceladus])}
          ${F("city_max_knowledge",[a])}
          `;return t.resource.Quantium.display&&(r+=`
          ${F("space_zero_g_lab_effect",[la(1)])}
          `),t.resource.Cipher.display&&(r+=`
          ${F("plus_max_resource",[1e4,t.resource.Cipher.name])}
          `),r+`
          ${F("minus_power",[$(this)[0].powered()])}
          `},support:()=>-1,powered:()=>oc(12),action(){return!!Os($(this)[0])&&(t.space.zero_g_lab.count++,t.space.titan_spaceport.support`
          ${F("tech_operating_base")}
          ${F("requires_power_support",[Xt().enceladus])}
          `,reqs:{enceladus:4},path:["truepath"],cost:{Money:e=>Xi("operating_base",e,75e5,1.3),Furs:e=>Xi("operating_base",e,5e5,1.3),Adamantite:e=>Xi("operating_base",e,375e3,1.3),Stanene:e=>Xi("operating_base",e,75e4,1.3),Mythril:e=>Xi("operating_base",e,225e3,1.3),Horseshoe:()=>t.race.hooved?4:0},effect(){let e=`
          ${F("space_used_support",[Xt().enceladus])}
          `;return e+=`
          ${F("galaxy_defense_platform_effect",[50])}
          `,e+=F("plus_max_resource",[la(4),F("civics_garrison_soldiers")]),t.race.orbit_decayed&&(e+=`
          ${F("city_hospital_effect",[5*t.tech.medic])}
          `),e+`
          ${F("minus_power",[$(this)[0].powered()])}
          `},support:()=>-1,powered:()=>oc(10),action(){return!!Os($(this)[0])&&(t.space.operating_base.count++,t.space.titan_spaceport.supportXi("munitions_depot",e,5e6,1.22),Iron:e=>Xi("munitions_depot",e,185e3,1.22),Sheet_Metal:e=>Xi("munitions_depot",e,1e5,1.22)},effect:()=>`
          ${F("plus_max_crates",[25])}
          ${F("plus_max_containers",[25])}
          `,action(){return!!Os($(this)[0])&&(t.space.munitions_depot.count++,t.resource.Crates.max+=25,t.resource.Containers.max+=25,!0)}}},spc_triton:{info:{name:()=>Xt().triton,desc:()=>F("space_triton_info_desc",[Xt().triton,di[t.race.species].home]),zone:"outer",syndicate:()=>!!(t.tech.triton&&t.tech.triton>=2),syndicate_cap:()=>t.tech.outer&&t.tech.outer>=4?5e3:3e3,extra(e){t.tech.triton&&t.tech.triton>=3&&($(`#${e}`).append(`
          ${F("space_ground_resist")}
          `),sc({el:`#${e}resist`,data:t.space.fob,methods:{threat(e,a){let r=t.civic.garrison.wounded-qe();r<0&&(r=0);let s=+(e-ke(a,"army",r)).toFixed(0);return s<0?0:s}}}))}},triton_mission:{id:"space-triton_mission",title:()=>F("space_mission_title",[Xt().triton]),desc:()=>F("space_mission_desc",[Xt().triton]),reqs:{outer:2},grant:["triton",1],path:["truepath"],queue_complete:()=>t.tech.triton>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(6e5,!1,t).toFixed(0),Elerium:()=>2500},effect:()=>F("space_triton_mission_effect",[Xt().triton]),action(){return!!Os($(this)[0])&&(Di(F("space_triton_mission_action",[Xt().triton]),"info",!1,["progress"]),t.space.syndicate.spc_triton=1250,t.space.syndicate.spc_titan+=250,t.space.syndicate.spc_enceladus+=250,!0)}},fob:{id:"space-fob",title:F("space_fob_title"),desc:()=>`
          ${F("tech_fob")}
          ${F("requires_power_combo",[t.resource.Helium_3.name])}
          `,reqs:{triton:2},path:["truepath"],queue_complete:()=>1-t.space.fob.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,25e7,1.1),Copper:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,8e6,1.1),Uranium:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,5e4,1.1),Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,25e5,1.1),Graphene:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,3e6,1.1),Sheet_Metal:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,75e5,1.1),Quantium:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Xi("fob",e,5e5,1.1),Horseshoe:e=>t.race.hooved&&(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)<1?10:0},effect(e){let a=qe(),r=qe(!0),s=`
          ${F("galaxy_defense_platform_effect",[500])}
          `;s+=F("plus_max_resource",[la(10),F("civics_garrison_soldiers")]),s+=`
          ${F("civics_garrison_soldiers")}: ${a} / ${r}
          `,s+=`
          ${F("civics_garrison_wounded")}: ${t.civic.garrison?t.civic.garrison.wounded:0}
          `,s+=`
          ${F("space_fob_landed",[t.space.fob?t.space.fob.troops:0])}
          `;let i=+Jt(125,!0,e).toFixed(2);return s+`
          ${F("requires_power_combo_effect",[$(this)[0].powered(),i,t.resource.Helium_3.name])}
          `},powered:()=>oc(50),action(){return!!(t.space.fob.count<1&&Os($(this)[0]))&&(t.space.fob.count++,xs($(this)[0]),!0)},post(){2===t.tech.triton&&(t.tech.triton=3,ms(),Rt(),Di(F("space_fob_msg"),"info",!1,["progress"]))}},lander:{id:"space-lander",title:F("space_lander_title"),desc:()=>`
          ${F("space_lander_title")}
          ${F("requires_soldiers")}
          ${F("space_red_space_barracks_desc_req")}
          `,reqs:{triton:3},path:["truepath"],cost:{Money:e=>Xi("lander",e,24e5,1.15),Aluminium:e=>Xi("lander",e,185e3,1.15),Neutronium:e=>Xi("lander",e,1e4,1.15),Nano_Tube:e=>Xi("lander",e,158e3,1.15)},powered:()=>oc(1),effect(e){let a=+Jt(50,!0,e).toFixed(2),r="";return t.space.crashed_ship&&100===t.space.crashed_ship.count&&(r=`
          ${F("space_lander_effect3",[Pe("lander"),t.resource.Cipher.name])}
          `),`
          ${F("space_lander_effect",[Xt().triton])}
          ${r}
          ${F("space_lander_effect2",[la(3)])}
          ${F("space_red_space_barracks_effect2",[a])}
          `},action(){return!!Os($(this)[0])&&(t.space.lander.count++,t.space.lander.on++,!0)}},crashed_ship:{id:"space-crashed_ship",title:F("space_crashed_ship_title"),desc:()=>`
          ${F("space_crashed_ship_title")}
          `,reqs:{triton:3},path:["truepath"],queue_complete:()=>0,cost:{},effect:()=>`
          ${F("space_crashed_ship_effect",[t.space.crashed_ship?t.space.crashed_ship.count:0])}
          `,action:()=>!1}},spc_kuiper:{info:{name:()=>F("space_kuiper_title"),desc:()=>F("space_kuiper_desc"),zone:"outer",syndicate:()=>!!t.tech.kuiper,syndicate_cap:()=>2500},kuiper_mission:{id:"space-kuiper_mission",title:()=>F("space_mission_title",[F("space_kuiper_title")]),desc:()=>F("space_mission_desc",[F("space_kuiper_title")]),reqs:{outer:7},grant:["kuiper",1],path:["truepath"],queue_complete:()=>t.tech.kuiper>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(1e6,!1,t).toFixed(0),Elerium:()=>1e3},effect:()=>F("space_kuiper_mission_effect"),action(){return!!Os($(this)[0])&&(t.space.orichalcum_mine={count:0,on:0},t.space.uranium_mine={count:0,on:0},t.space.neutronium_mine={count:0,on:0},t.space.syndicate.spc_kuiper=500,Di(F("space_kuiper_mission_action"),"info",!1,["progress"]),!0)}},orichalcum_mine:{id:"space-orichalcum_mine",title:()=>F("space_kuiper_mine",[t.resource.Orichalcum.name]),desc:()=>`
          ${F("space_kuiper_mine",[t.resource.Orichalcum.name])}
          ${F("requires_power_combo",[t.resource.Oil.name])}
          `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Xi("orichalcum_mine",e,25e6,1.25),Graphene:e=>Xi("orichalcum_mine",e,9e5,1.25),Elerium:e=>Xi("orichalcum_mine",e,200,1.25),Mythril:e=>Xi("orichalcum_mine",e,45e4,1.25),Quantium:e=>Xi("orichalcum_mine",e,15e4,1.25)},effect(e){let a=+Pe("orichalcum_mine").toFixed(3),r=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
          ${F("gain",[a,F("resource_Orichalcum_name")])}
          ${F("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
          `},powered:()=>oc(10),p_fuel:()=>({r:"Oil",a:200}),action(){return!!Os($(this)[0])&&(t.space.orichalcum_mine.count++,t.resource.Orichalcum.display=!0,xs($(this)[0]),!0)}},uranium_mine:{id:"space-uranium_mine",title:()=>F("space_kuiper_mine",[t.resource.Uranium.name]),desc:()=>`
          ${F("space_kuiper_mine",[t.resource.Uranium.name])}
          ${F("requires_power_combo",[t.resource.Oil.name])}
          `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Xi("uranium_mine",e,5e6,1.25),Iridium:e=>Xi("uranium_mine",e,25e4,1.25),Steel:e=>Xi("uranium_mine",e,62e4,1.25)},effect(e){let a=+Pe("uranium_mine").toFixed(3),r=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
          ${F("gain",[a,F("resource_Uranium_name")])}
          ${F("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
          `},powered:()=>oc(5),p_fuel:()=>({r:"Oil",a:60}),action(){return!!Os($(this)[0])&&(t.space.uranium_mine.count++,xs($(this)[0]),!0)}},neutronium_mine:{id:"space-neutronium_mine",title:()=>F("space_kuiper_mine",[t.resource.Neutronium.name]),desc:()=>`
          ${F("space_kuiper_mine",[t.resource.Neutronium.name])}
          ${F("requires_power_combo",[t.resource.Oil.name])}
          `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Xi("neutronium_mine",e,8e6,1.25),Adamantite:e=>Xi("neutronium_mine",e,65e4,1.25),Stanene:e=>Xi("neutronium_mine",e,125e4,1.25)},effect(e){let a=+Pe("neutronium_mine").toFixed(3),r=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
          ${F("gain",[a,F("resource_Neutronium_name")])}
          ${F("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
          `},powered:()=>oc(8),p_fuel:()=>({r:"Oil",a:60}),action(){return!!Os($(this)[0])&&(t.space.neutronium_mine.count++,xs($(this)[0]),!0)}},elerium_mine:{id:"space-elerium_mine",title:()=>F("space_kuiper_mine",[t.resource.Elerium.name]),desc:()=>`
          ${F("space_kuiper_mine",[t.resource.Elerium.name])}
          ${F("requires_power_combo",[t.resource.Oil.name])}
          `,reqs:{kuiper:2},path:["truepath"],cost:{Money:e=>Xi("elerium_mine",e,2e7,1.25),Titanium:e=>Xi("elerium_mine",e,25e4,1.25),Neutronium:e=>Xi("elerium_mine",e,12e4,1.25),Orichalcum:e=>Xi("elerium_mine",e,175e3,1.25)},effect(e){let a=+Pe("elerium_mine").toFixed(3),r=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
          ${F("gain",[a,F("resource_Elerium_name")])}
          ${F("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
          `},powered:()=>oc(12),p_fuel:()=>({r:"Oil",a:125}),action(){return!!Os($(this)[0])&&(t.space.elerium_mine.count++,xs($(this)[0]),!0)}}},spc_eris:{info:{name:()=>Xt().eris,desc:()=>F("space_eris_info_desc",[Xt().eris]),support:"drone_control",zone:"outer",syndicate:()=>!!t.tech.eris,syndicate_cap:()=>7500,extra(e){t.tech.eris&&1===t.tech.eris&&($(`#${e}`).append(`
          ${F("space_scanned")} {{ eris_scan }}%
          `),sc({el:`#${e}scanned`,data:t.tech}))}},eris_mission:{id:"space-eris_mission",title:()=>F("space_mission_title",[Xt().eris]),desc:()=>F("space_mission_desc",[Xt().eris]),reqs:{outer:7},grant:["eris",1],path:["truepath"],queue_complete:()=>t.tech.eris>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(125e4,!1,t).toFixed(0),Elerium:()=>1250},effect:()=>F("space_eris_mission_effect",[Xt().eris]),action(){return!!Os($(this)[0])&&(t.space.syndicate.spc_eris=4e3,Di(F("space_eris_mission_action",[Xt().eris]),"info",!1,["progress"]),!0)}},drone_control:{id:"space-drone_control",title:()=>F("space_drone_control",[Xt().titan]),desc(){return`
          ${F("space_drone_control",[Xt().titan])}
          ${F("requires_power_combo",[t.resource[$(this)[0].p_fuel().r].name])}
          `},reqs:{eris:3},path:["truepath"],cost:{Money:e=>Xi("drone_control",e,75e6,1.3),Neutronium:e=>Xi("drone_control",e,1e5,1.3),Stanene:e=>Xi("drone_control",e,45e4,1.3),Quantium:e=>Xi("drone_control",e,3e5,1.3)},effect(){let e=$(this)[0].p_fuel().a;return`
          +${F("galaxy_alien2_support",[$(this)[0].support(),Xt().eris])}
          ${F("requires_power_combo_effect",[$(this)[0].powered(),e,t.resource[$(this)[0].p_fuel().r].name])}
          `},support:()=>5,powered:()=>oc(25),p_fuel:()=>({r:"Uranium",a:5}),action(){return!!Os($(this)[0])&&(t.space.drone_control.count++,xs($(this)[0]),!0)}},shock_trooper:{id:"space-shock_trooper",title:F("space_shock_trooper_title"),desc:()=>`
          ${F("space_shock_trooper_title")}
          ${F("space_support",[Xt().eris])}
          `,reqs:{eris:3},path:["truepath"],cost:{Money:e=>Xi("shock_trooper",e,425e4,1.225),Polymer:e=>Xi("shock_trooper",e,375e3,1.225),Adamantite:e=>Xi("shock_trooper",e,5e5,1.225),Graphene:e=>Xi("shock_trooper",e,22e4,1.225),Elerium:e=>Xi("shock_trooper",e,350,1.225)},effect(){let e=Math.round(ke(1,"army",0)*ht("spc_eris")),a=`
          ${F("space_used_support",[Xt().eris])}
          `;return t.space.digsite&&100===t.space.digsite.count&&(a=`
          ${F("space_lander_effect3",[Pe("shock_trooper"),t.resource.Cipher.name])}
          `),a+`
          ${F("space_digsite_offense",[e])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.space.shock_trooper.count++,t.space.drone_control.support`
          ${F("space_tank_title")}
          ${F("space_support",[Xt().eris])}
          `,reqs:{eris:4},path:["truepath"],cost:{Money:e=>Xi("tank",e,1e8,1.25),Alloy:e=>Xi("tank",e,125e4,1.25),Orichalcum:e=>Xi("tank",e,6e5,1.25),Mythril:e=>Xi("tank",e,5e5,1.25),Uranium:e=>Xi("tank",e,25e3,1.25)},effect(){let e=Math.round(100*ht("spc_eris")),a=`
          ${F("space_used_support",[Xt().eris])}
          `;return t.space.digsite&&100===t.space.digsite.count&&(a=`
          ${F("space_lander_effect3",[Pe("tank"),t.resource.Cipher.name])}
          `),a+`
          ${F("space_digsite_offense",[e])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.space.tank.count++,t.space.drone_control.support`
          ${F("space_digsite_title")}
          `,reqs:{eris:3},path:["truepath"],queue_complete:()=>0,cost:{},effect:()=>`
          ${F("space_crashed_ship_effect",[t.space.digsite?t.space.digsite.count:0])}
          `,action:()=>!1}}},Ze={tau_star:{info:{name:()=>F("tab_tauceti"),desc:()=>F("tau_star",[F("tab_tauceti"),F("space_sun_info_name")])},ringworld:{id:"tauceti-ringworld",title:F("tau_star_ringworld"),desc:e=>!t.tauceti.hasOwnProperty("ringworld")||t.tauceti.ringworld.count<1e3||e?`
          ${F("tau_star_ringworld")}
          ${F("requires_segmemts",[1e3])}
          `:`
          ${F("tau_star_ringworld")}
          `,reqs:{matrix:2},path:["truepath"],queue_size:50,queue_complete:()=>1e3-t.tauceti.ringworld.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?1e7:1e8:0,Neutronium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?2e4:1e5:0,Nano_Tube:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?7e4:35e4:0,Adamantite:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?2e5:1e6:0,Bolognium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?17600:88e3:0,Orichalcum:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?25e3:125e3:0,Unobtainium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?360:1800:0,Quantium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?Ye(t.race.lone_survivor?10100:101e3):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0);if(r<1e3){let e=1e3-r;a+=`
          ${F("tau_star_ringworld_effect")}
          `,a+=`
          ${F("space_dwarf_collider_effect2",[e])}
          `}else a+=`
          ${F("space_dwarf_reactor_effect1",[t.race.lone_survivor?100:1e4])}
          `;return a},action(){return!!(Os($(this)[0])&&t.tauceti.ringworld.count<1e3)&&(t.tauceti.ringworld.count++,t.tauceti.ringworld.count>=1e3&&(t.race.lone_survivor?t.tech.eden=1:(t.tech.matrix=3,t.tauceti.matrix={count:1,on:0}),tt(),Ei()),!0)}},matrix:{id:"tauceti-matrix",title:F("tau_star_matrix"),desc:()=>`
          ${F("tau_star_matrix")}
          ${F("requires_power")}
          `,reqs:{matrix:3},condition:()=>t.tauceti.ringworld.count>=1e3,queue_complete:()=>0,cost:{},powered:()=>1e4,postPower(e){e?setTimeout((function(){t.tech.matrix=i.matrix?4:3,tt()}),250):(t.tech.matrix=3,tt())},effect(){let e=Ve(),t=$(this)[0].powered(),a=t>0?`
          ${F("minus_power",[t])}
          `:"";return`
          ${F("tau_star_matrix_effect")}
          ${e}${a}`},action:()=>!1},blue_pill:{id:"tauceti-blue_pill",title:F("tau_star_blue_pill"),desc:F("tau_star_blue_pill"),wiki:!1,reqs:{matrix:4},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=Ve();return`
          ${F("tau_star_blue_pill_effect")}
          ${e}`},action(){if(Os($(this)[0])){$("body").append('');const a=document.getElementById("matrix"),r=a.getContext("2d"),s=a.width=document.body.offsetWidth,i=a.height=document.body.offsetHeight,c=Math.floor(s/20)+1,o=Array(c).fill(0);function n(){r.fillStyle="#0001",r.fillRect(0,0,s,i),r.fillStyle="#0f0",r.font="15pt monospace",o.forEach(((e,t)=>{const a=String.fromCharCode(Math.rand(65382,65438)),s=20*t;r.fillText(a,s,e),e>100+1e4*Math.random()?o[t]=0:o[t]=e+20}))}return setInterval(n,50),setTimeout((function(){!function(){M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"matrix"});let a=t.race.species,r=t.race.gods,s=di[a].type,i=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,n=t.city.geology,l=mc("matrix");Xc(`biome_${c}`),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),Xc(`genus_${s}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),Xc("bluepill"),Z(),so(),t.stats.matrix++,Fc(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let u=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),u&&(t.race.srace=u),Q({orbit:i,biome:c,ptrait:o,geology:n}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),5e3),!0}return!1}},goe_facility:{id:"tauceti-goe_facility",title:F("tau_star_goe_facility"),desc:()=>`
          ${F("tau_star_goe_facility")}
          `,reqs:{eden:2},condition:()=>t.tauceti.ringworld.count>=1e3,queue_complete:()=>0,cost:{Money:e=>1e6,Copper:e=>1e7,Graphene:e=>5e6,Stanene:e=>8e6,Elerium:e=>1e4},effect(){let e=function(){let e=mc("eden"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
          ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
          ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
          ${F("tau_star_matrix_servants",[1])}
          `}();return`
          ${F("tau_star_goe_facility_effect")}
          ${e}`},action(){if(Os($(this)[0])){let a=gc(Ze.tau_star.goe_facility);return Object.keys(a).forEach((function(e){t.resource[e].amount+=a[e]()})),function(){M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"eden"});let a=t.race.species,r=t.race.gods,s=di[a].type,i=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,n=t.city.geology,l=mc("eden");Xc(`biome_${c}`),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),Xc(`genus_${s}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),Xc("adam_eve"),Z(),so(),t.stats.eden++,Fc(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let u=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),u&&(t.race.srace=u),Q({orbit:i,biome:c,ptrait:o,geology:n}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),!1}return!1}}},tau_home:{info:{name:()=>F("tau_planet",[di[t.race.species].home]),desc:()=>F("tau_home",[di[t.race.species].home]),support:"orbital_station",extra(e){t.tech.tau_home&&t.tech.tau_home>=2&&!et()&&($(`#${e}`).append(`
          ${F("resource_Materials_name")} {{ amount | round }} / {{ max }}
          `),sc({el:`#${e}Mats`,data:t.resource.Materials,methods:{tauShow:()=>!et()},filters:{round:e=>+e.toFixed(0)}}))}},home_mission:{id:"tauceti-home_mission",title:()=>F("tau_new_mission_title",[di[t.race.species].home]),desc:()=>F("tau_new_mission_title",[di[t.race.species].home]),reqs:{tauceti:2},grant:["tau_home",1],path:["truepath"],queue_complete:()=>t.tech.tau_home>=1?0:1,cost:{Money:()=>1e9},effect:()=>F("tau_new_mission_effect",[di[t.race.species].home]),action(){return!!Os($(this)[0])&&(t.tauceti.colony={count:0,on:0},t.tauceti.mining_pit={count:0,on:0},Di(F("tau_home_mission_result",[di[t.race.species].home]),"info",!1,["progress"]),!0)}},dismantle:{id:"tauceti-dismantle",title:()=>F("tau_home_dismantle"),desc:()=>F("tau_home_dismantle"),reqs:{tau_home:1},grant:["tau_home",2],path:["truepath"],queue_complete:()=>t.tech.tau_home>=2?0:1,cost:{Money:()=>1e8},effect(){let e="Explorer";if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let a=t.space.shipyard.ships.findIndex((e=>"tauceti"===e.location&&"explorer"===e.class));-1!==a&&(e=t.space.shipyard.ships[a].name)}return F("tau_home_dismantle_effect",[e])},action(){let e=-1;if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")&&(e=t.space.shipyard.ships.findIndex((e=>"tauceti"===e.location&&"explorer"===e.class))),e>=0&&Os($(this)[0])){if(t.space.shipyard.ships.splice(e,1),t.tauceti.orbital_station.count++,t.tauceti.colony.count++,t.tauceti.mining_pit.count++,t.civic.pit_miner.display=!0,t.resource.Materials.display=!0,t.city.powered&&t.city.power>=Ze.tau_home.orbital_station.powered()){t.tauceti.orbital_station.on++,t.tauceti.colony.on++,t.tauceti.mining_pit.on++;let e=la(4);t.civic[t.civic.d_job].workers${F("tau_home_orbital_station")}
          ${F("requires_power")}
          `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Xi("orbital_station",e,8e7,1.3,"tauceti"),Materials:e=>et()?0:Xi("orbital_station",e,5e5,1.3,"tauceti"),Helium_3:e=>et()?Xi("orbital_station",e,Yt(25e4),1.3,"tauceti"):0,Copper:e=>et()?Xi("orbital_station",e,125e4,1.3,"tauceti"):0,Adamantite:e=>et()?Xi("orbital_station",e,9e5,1.3,"tauceti"):0},effect(){let e=Lr(15e3),a=+Yt($(this)[0].support_fuel().a).toFixed(1),r=`
          ${F("space_red_spaceport_effect1",[F("tau_planet",[di[t.race.species].home]),$(this)[0].support()])}
          `;return r+=`
          ${F("plus_max_resource",[e.toLocaleString(),t.resource.Helium_3.name])}
          `,r+=`
          ${F("spend_power",[a,t.resource[$(this)[0].support_fuel().r].name,$(this)[0].powered()])}
          `,r},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?t.race.lone_survivor?5:25:400}),support:()=>3,powered:()=>oc(t.tech.isolation?t.race.lone_survivor?4:6:30),refresh:!0,action(){return!!Os($(this)[0])&&(t.tauceti.orbital_station.count++,xs($(this)[0]),!0)}},colony:{id:"tauceti-colony",title:F("tau_home_colony"),desc:()=>`
          ${F("tau_home_colony_desc",[di[t.race.species].home])}
          ${F("requires_power_support_combo",[di[t.race.species].home,t.resource.Food.name])}
          `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Xi("colony",e,1575e4,1.225,"tauceti"),Materials:e=>et()?0:Xi("colony",e,65e4,1.225,"tauceti"),Furs:e=>et()?Xi("colony",e,72e4,1.225,"tauceti"):0,Graphene:e=>et()?Xi("colony",e,485e3,1.225,"tauceti"):0,Brick:e=>et()?Xi("colony",e,Ye(88e4),1.225,"tauceti"):0},effect(){let e=$(this)[0].citizens(),a=t.tech.isolation?900:250,r=+$(this)[0].support_fuel().a.toFixed(1),s=`
          ${F("tau_new_support",[$(this)[0].support(),di[t.race.species].home])}
          `;if(t.race.lone_survivor||(s+=`
          ${F("plus_max_citizens",[e])}
          `),t.tech.isolation){let e=25*Hs();e=Lr(e),e=(+e.toFixed(0)).toLocaleString(),s+=`
          ${F("plus_max_resource",[`$${e}`,F("resource_Money_name")])}
          `}if(s+=`
          ${F("tau_home_colony_effect",[50,di[t.race.species].home])}
          `,t.tech.isolation){let e=N("gaslighter",0);s+=`
          ${F("space_red_vr_center_effect1",[2*(e?e+t.tech.broadcast:t.tech.broadcast)])}
          `}return s+=`
          ${F("plus_max_resource",[a,F("resource_Crates_name")])}
          ${F("plus_max_resource",[a,F("resource_Containers_name")])}
          `,t.race.lone_survivor?s+=`
          ${F("gain",[-r,t.resource[$(this)[0].support_fuel().r].name])}
          `:s+=`
          ${F("spend",[r,t.resource[$(this)[0].support_fuel().r].name])}
          `,s},support:()=>-2,support_fuel:()=>({r:"Food",a:t.tech.isolation?t.race.lone_survivor?-2:75:1e3}),powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.colony.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.colony.on++,!0)},citizens(){let e=t.tech.isolation?8:5;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),t.race.lone_survivor?0:e}},tau_housing:{id:"tauceti-tau_housing",title:()=>Is("small"),desc:F("city_basic_housing_desc"),desc(){return 1===$(this)[0].citizens()?F("city_basic_housing_desc"):F("city_basic_housing_desc_plural",[$(this)[0].citizens()])},category:"residential",reqs:{housing:1,isolation:1},condition:()=>!t.race.lone_survivor,cost:{Money:e=>Xi("tau_housing",e,15e4,1.15,"tauceti"),Lumber:e=>t.race.kindling_kindred||t.race.smoldering?0:Xi("tau_housing",e,125e3,1.25,"tauceti"),Stone:e=>t.race.kindling_kindred?Xi("tau_housing",e,125e3,1.25,"tauceti"):0,Chrysotile:e=>t.race.smoldering?Xi("tau_housing",e,5e4,1.25,"tauceti"):0,Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.sappy?`
          ${F("plus_max_resource",[e,F("citizen")])}
          ${F("city_grove_effect",[2.5])}
          `:F("plus_max_resource",[e,F("citizen")])},action(){return!!Os($(this)[0])&&(t.tauceti.tau_housing.count++,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},captive_housing:Vr("captive_housing","tauceti"),pylon:{id:"tauceti-pylon",title:F("tau_home_pylon"),desc:F("tau_home_pylon"),reqs:{magic:2},condition:()=>!(!t.tech.isolation||!t.tauceti.hasOwnProperty("pylon")),cost:{Money:e=>Xi("pylon",e,50,1.48,"tauceti"),Stone:e=>Xi("pylon",e,100,1.42,"tauceti"),Crystal:e=>Xi("pylon",e,8,1.42,"tauceti")-3},effect(){let e=Lr(2);return`
          ${F("gain",[+(.0125*nc("magic")).toFixed(3),t.resource.Mana.name])}
          ${F("plus_max_resource",[e,t.resource.Mana.name])}
          `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!Os($(this)[0])&&(t.tauceti.pylon.count++,t.resource.Mana.max+=Lr(2),!0)}},cloning_facility:{id:"tauceti-cloning_facility",title:F("tau_home_cloning"),desc:()=>F("tau_home_cloning_desc",[di[t.race.species].name]),category:"military",reqs:{cloning:1},path:["truepath"],queue_complete:()=>t.resource[t.race.species].max-t.resource[t.race.species].amount,cost:{Money:e=>t.resource[t.race.species].amount?Xi("citizen",e,Math.round((t.race.high_pop?1e5:125e3)/la(1)),t.race.high_pop?1.01:1.02,"tauceti",t.race.high_pop?1.003:1.005):0,Copper:e=>!t.race.artifical||t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Xi("citizen",e,Math.round(50/la(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0,Aluminium:e=>!t.race.artifical||t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Xi("citizen",e,Math.round(50/la(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0,Nanite:e=>t.race.deconstructor&&t.resource[t.race.species].amount>=3?Xi("citizen",e,Math.round(500/la(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0},effect(){let e="";return t.resource[t.race.species].max===t.resource[t.race.species].amount&&(e=`
          ${F("city_assembly_effect_warn")}
          `),`
          ${F("tau_home_cloning_effect",[di[t.race.species].name])}
          ${e}`},action(){return!!(t.resource[t.race.species].max>t.resource[t.race.species].amount&&Os($(this)[0]))&&(t.resource[t.race.species].amount++,!0)}},horseshoe:Vr("horseshoe","tauceti"),bonfire:Vr("bonfire","tauceti"),firework:Vr("firework","tauceti"),assembly:Vr("assembly","tauceti"),nanite_factory:Vr("nanite_factory","tauceti"),tau_farm:{id:"tauceti-tau_farm",title:F("tau_home_tau_farm"),desc:()=>`
          ${F("tau_home_tau_farm")}
          ${F("requires_power")}
          `,reqs:{tau_home:7},path:["truepath"],cost:{Money:e=>Xi("tau_farm",e,135e6,1.25,"tauceti"),Stone:e=>Xi("tau_farm",e,921e4,1.25,"tauceti"),Steel:e=>Xi("tau_farm",e,6295e3,1.25,"tauceti"),Water:e=>Xi("tau_farm",e,1e4,1.25,"tauceti")},effect(){let e=`
          ${F("space_red_spaceport_effect1",[F("tau_planet",[di[t.race.species].home]),$(this)[0].support()])}
          `;return e+=`
          ${F("produce",[+Pe("tau_farm","food").toFixed(2),t.resource.Food.name])}
          `,t.race.kindling_kindred||t.race.smoldering||(e+=`
          ${F("produce",[+Pe("tau_farm","lumber").toFixed(2),t.resource.Lumber.name])}
          `),t.tech.isolation&&(e+=`
          ${F("produce",[+Pe("tau_farm","water").toFixed(2),t.resource.Water.name])}
          `,t.race.artifical&&(e+=`
          ${F("city_transmitter_effect",[Lr(350)])}
          `)),e+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,e},support:()=>1,powered:()=>cc(t.tech.isolation?1:4),action(){return!!Os($(this)[0])&&(t.tauceti.tau_farm.count++,xs($(this)[0]),!0)}},mining_pit:{id:"tauceti-mining_pit",title:F("tau_home_mining_pit"),desc:()=>`
          ${F("tau_home_mining_pit")}
          ${F("space_support",[di[t.race.species].home])}
          `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Xi("mining_pit",e,425e4,1.225,"tauceti"),Materials:e=>et()?0:Xi("mining_pit",e,35e4,1.225,"tauceti"),Lumber:e=>et()?Xi("mining_pit",e,235e4,1.225,"tauceti"):0,Iron:e=>et()?Xi("mining_pit",e,835e3,1.225,"tauceti"):0},effect(){let e=`
          ${F("tau_new_support",[$(this)[0].support(),di[t.race.species].home])}
          `;if(e+=`
          ${F("plus_max_resource",[la(t.tech.isolation?6:8),F("job_pit_miner")])}
          `,et())if(t.tech.isolation){if(t.race.lone_survivor){let a=[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name,t.resource.Copper.name,t.resource.Iron.name,t.resource.Aluminium.name,t.resource.Coal.name];t.race.smoldering?(a.push(t.resource.Chrysotile.name),e+=`
          ${F("tau_home_mining_pit_effect2cs",a)}
          `):e+=`
          ${F("tau_home_mining_pit_effect2c",a)}
          `}else{let a=[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name,t.resource.Copper.name,t.resource.Coal.name];t.race.smoldering?(a.push(t.resource.Chrysotile.name),e+=`
          ${F("tau_home_mining_pit_effect2bs",a)}
          `):e+=`
          ${F("tau_home_mining_pit_effect2b",a)}
          `}e+=`
          ${F("tau_gas_womling_station_effect",[8,t.resource.Cement.name])}
          `}else e+=`
          ${F("tau_home_mining_pit_effect2",[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name])}
          `;else e+=`
          ${F("plus_max_resource",[1e6,F("resource_Materials_name")])}
          `,e+=`
          ${F("tau_home_mining_pit_effect",[t.resource.Materials.name])}
          `;return e},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.mining_pit.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.mining_pit.on++,!0)}},excavate:{id:"tauceti-excavate",title:F("tau_home_excavate"),desc:()=>`
          ${F("tau_home_excavate")}
          `,reqs:{tau_home:2},grant:["tau_home",3],path:["truepath"],cost:{Money:e=>165e7,Materials:e=>75e4},effect:()=>F("tau_home_excavate_effect"),action(){return!!Os($(this)[0])&&(Di(F("tau_home_excavate_msg"),"info",!1,["progress"]),!0)}},alien_outpost:{id:"tauceti-alien_outpost",title:F("tech_alien_outpost"),desc:()=>`
          ${F("tech_alien_outpost")}
          ${F("requires_power")}
          `,reqs:{tau_home:4},path:["truepath"],cost:{},queue_complete:()=>0,effect(){let e=`
          ${F("plus_max_resource",["20%",F("resource_Knowledge_name")])}
          `;return t.tech.isolation&&(e+=`
          ${F("plus_max_resource",[(t.race.lone_survivor?35e5:65e5).toLocaleString(),F("resource_Knowledge_name")])}
          `,e+=`
          ${F("plus_max_resource",[2e5.toLocaleString(),t.resource.Cipher.name])}
          `,e+=`
          ${F("space_lander_effect3",[Pe("alien_outpost"),t.resource.Cipher.name])}
          `),t.tech.outpost_boost&&(e+=`
          ${F("tech_alien_outpost_effect2")}
          `),t.race.lone_survivor&&(e+=`
          ${F("city_wardenclyffe_effect1",[la(1),t.civic.professor.name])}
          `),e+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,e},powered:()=>oc(t.tech.isolation?t.race.lone_survivor?8:25:100),special:()=>!!t.tech.replicator,action:()=>!1},jump_gate:{id:"tauceti-jump_gate",title:F("tau_jump_gate"),desc:e=>!t.tauceti.hasOwnProperty("jump_gate")||t.tauceti.jump_gate.count<100||e?`
          ${F("tau_jump_gate")}
          ${F("requires_segmemts",[100])}
          `:`
          ${F("tau_jump_gate")}
          `,reqs:{tauceti:3},condition:()=>t.tech.isolation?0:1,path:["truepath"],queue_size:10,queue_complete:()=>100-t.tauceti.jump_gate.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0)<100?1e6:0,Materials:e=>(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0)<100?12500:0},effect(e){let a=(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0);if(a<100){let e=100-a;return`
          ${F("tau_jump_gate_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          `}return F("tau_jump_gate_effect")},action(){return!!(Os($(this)[0])&&t.tauceti.jump_gate.count<100)&&(t.tauceti.jump_gate.count++,!0)}},fusion_generator:{id:"tauceti-fusion_generator",title:F("tech_fusion_generator"),desc:()=>`
          ${F("tech_fusion_generator")}
          ${F("requires_res",[t.resource.Helium_3.name])}
          `,reqs:{tau_home:6},path:["truepath"],cost:{Money:e=>Xi("fusion_generator",e,188e6,1.25,"tauceti"),Iridium:e=>Xi("fusion_generator",e,555e4,1.25,"tauceti"),Stanene:e=>Xi("fusion_generator",e,7003500,1.25,"tauceti"),Sheet_Metal:e=>Xi("fusion_generator",e,Ye(95e3),1.25,"tauceti")},effect(){let e=+Yt($(this)[0].p_fuel().a).toFixed(1),a=`
          ${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
          `;return t.race.lone_survivor?a+=`
          ${F("gain",[-e,t.resource[$(this)[0].p_fuel().r].name])}
          `:a+=`
          ${F("spend",[e,t.resource[$(this)[0].p_fuel().r].name])}
          `,a},p_fuel:()=>({r:"Helium_3",a:t.tech.isolation?t.race.lone_survivor?-15:75:500}),powered:()=>cc(-32),action(){return!!Os($(this)[0])&&(t.tauceti.fusion_generator.count++,t.tauceti.fusion_generator.on++,!0)}},repository:{id:"tauceti-repository",title:F("tech_repository"),desc:F("tech_repository"),reqs:{tau_home:5},path:["truepath"],cost:{Money:e=>Xi("repository",e,1028e4,1.28,"tauceti"),Iron:e=>Xi("repository",e,18e5,1.28,"tauceti"),Cement:e=>Xi("repository",e,15e5,1.28,"tauceti"),Neutronium:e=>Xi("repository",e,215e3,1.28,"tauceti")},wide:!0,res(){let e=["Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Crystal","Alloy","Polymer","Iridium","Chrysotile","Nano_Tube","Neutronium","Adamantite","Unobtainium"];return t.tech.isolation&&(e.push("Oil"),e.push("Helium_3"),e.push("Uranium"),e.push("Water")),e},val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 3e4;case"Crystal":return 10;case"Furs":return 17e3;case"Copper":return 15200;case"Iron":return 14e3;case"Aluminium":return 12800;case"Cement":return 11200;case"Coal":return 4800;case"Steel":return 2400;case"Titanium":return 1600;case"Alloy":return 1800;case"Polymer":return 1500;case"Iridium":return 1750;case"Nano_Tube":return 1200;case"Neutronium":return 640;case"Adamantite":return 720;case"Unobtainium":return 1e3;case"Oil":return 680;case"Helium_3":return 575;case"Uranium":return 125;case"Water":return 15;case"Elerium":return 3;default:return 0}},effect(){let e='
          ',a=bt("repository");for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return t.tech.isolation&&(e+=`${F("plus_max_resource",[250,F("resource_Crates_name")])}${F("plus_max_resource",[250,F("resource_Containers_name")])}`),e+="
          ",e},action(){if(Os($(this)[0])){t.tauceti.repository.count++;let e=bt("repository");for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=Lr($(this)[0].val(a))*e);return!0}return!1}},tau_factory:{id:"tauceti-tau_factory",title:F("tau_home_tau_factory"),desc:()=>`
          ${F("tau_home_tau_factory")}
          ${F("requires_power_support",[di[t.race.species].home])}
          `,reqs:{tau_home:8},path:["truepath"],cost:{Money:e=>Xi("tau_factory",e,269e6,1.25,"tauceti"),Titanium:e=>Xi("tau_factory",e,3e6,1.25,"tauceti"),Elerium:e=>Xi("tau_factory",e,850,1.25,"tauceti"),Bolognium:e=>Xi("tau_factory",e,25e4,1.25,"tauceti"),Quantium:e=>Xi("tau_factory",e,Ye(425e3),1.25,"tauceti")},effect(){let e=`
          ${F("tau_new_support",[$(this)[0].support(),di[t.race.species].home])}
          `;return e+=`
          ${F("tau_home_tau_factory_effect",[t.tech.isolation?5:3])}
          `,t.tech.isolation&&(t.race.flier||(e+=`
          ${F("city_cement_plant_effect1",[la(2)])}
          `),e+=`
          ${F("space_red_fabrication_effect1",[la(5)])}
          `),e+=`
          ${F("city_crafted_mats",[t.tech.isolation?275:90])}
          `,e+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,e},special:!0,support:()=>-1,powered:()=>oc(t.tech.isolation?2:5),action(){return!!Os($(this)[0])&&(t.tauceti.tau_factory.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.tau_factory.on++,!0)}},infectious_disease_lab:{id:"tauceti-infectious_disease_lab",title:()=>t.tech.isolation?F("tech_infectious_disease_lab_alt"):F(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),desc(){return`
          ${$(this)[0].title()}
          ${F("requires_power_support",[di[t.race.species].home])}
          `},reqs:{disease:1},path:["truepath"],cost:{Money:e=>Xi("infectious_disease_lab",e,1e9,1.25,"tauceti"),Alloy:e=>Xi("infectious_disease_lab",e,325e5,1.25,"tauceti"),Polymer:e=>Xi("infectious_disease_lab",e,5e7,1.25,"tauceti"),Bolognium:e=>Xi("infectious_disease_lab",e,25e5,1.25,"tauceti"),Unobtainium:e=>Xi("infectious_disease_lab",e,64e3,1.25,"tauceti")},effect(){let e=39616;if(t.tech.supercollider&&t.tech.isolation){let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}let a=`
          ${F("tau_new_support",[$(this)[0].support(),di[t.race.species].home])}
          `;return a+=`
          ${F("city_max_knowledge",[Math.round(e).toLocaleString()])}
          `,t.tech.isolation&&(a+=`
          ${F("plus_max_resource",[Lr(375),F("resource_Elerium_name")])}
          `,a+=`
          ${F("city_wardenclyffe_effect1",[la(2),t.civic.professor.name])}
          `,a+=`
          ${F("city_wardenclyffe_effect1",[la(1),t.civic.scientist.name])}
          `,a+=`
          ${F("space_zero_g_lab_effect",[la(1)])}
          `,a+=`
          ${F("city_library_effect",[75])}
          `),t.tech.alien_crafting&&(a+=`
          ${F("tau_gas_womling_station_effect",[65,t.resource.Quantium.name])}
          `),t.tech.focus_cure&&(a+=`
          ${F("tau_home_disease_lab_cure",[+t.tauceti.infectious_disease_lab.cure.toFixed(1)])}
          `,t.race.hasOwnProperty("vax")&&(a+=`
          ${F("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
          `)),a+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,a},support:()=>-1,powered:()=>oc(t.tech.isolation?t.race.lone_survivor?2:8:35),action(){return!!Os($(this)[0])&&(t.tauceti.infectious_disease_lab.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.infectious_disease_lab.on++,!0)},post(){1===t.tech.disease&&(t.tech.disease=2,Di(F("tau_plague4",[F("tab_tauceti")]),"info",!1,["progress"]),ms())}},tauceti_casino:{id:"tauceti-tauceti_casino",title:F("city_casino"),desc:F("city_casino"),category:"commercial",reqs:{gambling:1,isolation:1},cost:{Money:e=>Xi("tauceti_casino",e,145e4,1.35,"tauceti"),Furs:e=>Xi("tauceti_casino",e,95e3,1.35,"tauceti"),Cement:e=>Xi("tauceti_casino",e,12e4,1.35,"tauceti"),Plywood:e=>Xi("tauceti_casino",e,Ye(55e3),1.35,"tauceti")},effect(){let e=$(this)[0].citizens(),a=t.race.lone_survivor?"":`
          ${F("plus_max_resource",[e,F("citizen")])}
          `;return a+=ss(),a+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,a},powered:()=>oc(t.race.lone_survivor?1:2),action(){return!!Os($(this)[0])&&(t.tauceti.tauceti_casino.count++,t.race.joyless||(t.civic.entertainer.max+=la(1),t.civic.entertainer.display=!0),xs($(this)[0]),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),t.race.lone_survivor?0:e},flair:F("city_casino_flair")},tau_cultural_center:{id:"tauceti-tau_cultural_center",title:F("tech_cultural_center"),desc(){return`
          ${F("tech_cultural_center")}
          ${F("space_electrolysis_req",[t.resource[$(this)[0].p_fuel().r].name])}
          `},category:"commercial",reqs:{tau_culture:1},path:["truepath"],cost:{Money:e=>Xi("tau_cultural_center",e,9145e4,1.35,"tauceti"),Copper:e=>Xi("tau_cultural_center",e,585e4,1.35,"tauceti"),Coal:e=>Xi("tau_cultural_center",e,465e3,1.35,"tauceti"),Polymer:e=>Xi("tau_cultural_center",e,3792e3,1.35,"tauceti")},effect(){let e=1;"corpocracy"===t.civic.govern.type?e=2:"socialist"===t.civic.govern.type&&(e=.8);let a=20*e,r=5*e,s=15*e,i=`
          ${F("tau_home_cultureal_effect1",[$(this)[0].p_fuel().a,t.resource[$(this)[0].p_fuel().r].name,$(this)[0].title])}
          `;return i+=`
          ${F("city_tourist_center_effect3",[a])}
          `,i+=`
          ${F("city_tourist_center_effect4",[r])}
          `,i+=`
          ${F("tau_home_cultureal_effect2",[8,F("tau_red_womlings")])}
          `,t.tech.tau_culture>=2&&(i+=`
          ${F("tau_home_cultureal_effect3",[s,F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)])}
          `),i+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,i},powered:()=>oc(1),p_fuel:()=>({r:"Food",a:t.race.lone_survivor?25:500}),action(){return!!Os($(this)[0])&&(t.tauceti.tau_cultural_center.count++,t.tauceti.tau_cultural_center.on++,!0)}}},tau_red:{info:{name:()=>F("tau_planet",[Xt().red]),desc:()=>F("tau_red",[Xt().red]),support:"orbital_platform",extra(e){t.tech.tau_red&&t.tech.tau_red>=5&&($(`#${e}`).append(`
          ${F("tau_red_womling_prod")} {{ prod }}%
          `),sc({el:`#${e}Womlings`,data:t.tauceti.overseer}))}},red_mission:{id:"tauceti-red_mission",title:()=>F("tau_new_mission_title",[Xt().red]),desc:()=>F("tau_new_mission_title",[Xt().red]),reqs:{tauceti:2},grant:["tau_red",1],path:["truepath"],queue_complete:()=>t.tech.tau_red>=1?0:1,cost:{Money:()=>1e9},effect:()=>F("tau_new_mission_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.tauceti.settlement={count:0,on:0},Di(F("tau_red_mission_result",[Xt().red]),"info",!1,["progress"]),!0)}},orbital_platform:{id:"tauceti-orbital_platform",title:F("tau_red_orbital_platform"),desc:`
          ${F("tau_red_orbital_platform")}
          ${F("requires_power")}
          `,reqs:{tau_red:1,tauceti:4},path:["truepath"],cost:{Money:e=>Xi("orbital_platform",e,5e7,1.3,"tauceti"),Oil:e=>{return et()?Xi("orbital_platform",e,Yt((a=275e3,t.tech.womling_tech&&t.tech.womling_logistics&&t.tech.womling_logistics>=2&&(a*=.94**t.tech.womling_tech),a)),1.3,"tauceti"):0;var a},Aluminium:e=>Xi("orbital_platform",e,178e4,1.3,"tauceti"),Bolognium:e=>Xi("orbital_platform",e,45e4,1.3,"tauceti")},effect(){let e=Lr(17500),a=+Yt($(this)[0].support_fuel().a).toFixed(1),r=`
          ${F("space_red_spaceport_effect1",[F("tau_planet",[Xt().red]),$(this)[0].support()])}
          `;return r+=`
          ${F("plus_max_resource",[e.toLocaleString(),t.resource.Oil.name])}
          `,r+=`
          ${F("spend_power",[a,t.resource[$(this)[0].support_fuel().r].name,$(this)[0].powered()])}
          `,r},support_fuel:()=>({r:t.race.lone_survivor?"Helium_3":"Oil",a:t.tech.isolation?t.race.lone_survivor?8:32:125}),support(){let e=t.tech.womling_logistics?2.5:2;return t.race.lone_survivor&&(e*=2),e},powered:()=>oc(t.tech.isolation?t.race.lone_survivor?2:3:18),refresh:!0,action(){return!(!et()||!Os($(this)[0])||(t.tauceti.orbital_platform.count++,xs($(this)[0]),1===t.tech.tau_red&&(t.tech.tau_red=2,Di(F("tau_red_orbital_platform_msg",[F("tau_planet",[Xt().red]),F("tau_planet",[di[t.race.species].home])]),"info",!1,["progress"])),0))}},contact:{id:"tauceti-contact",title:()=>F("tau_red_contact"),desc:()=>F("tau_red_contact"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Money:()=>6e8,Food:()=>t.race.lone_survivor&&t.race.artifical?62e3:25e5},effect:()=>F("tau_red_contact_effect"),action(){return!!Os($(this)[0])&&(t.race.womling_friend=1,Je(),!0)}},introduce:{id:"tauceti-introduce",title:()=>F("tau_red_introduce"),desc:()=>F("tau_red_introduce"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Knowledge:()=>7e6},effect:()=>F("tau_red_introduce_effect"),action(){return!!Os($(this)[0])&&(t.race.womling_god=1,Je(),!0)}},subjugate:{id:"tauceti-subjugate",title:()=>F("tau_red_subjugate"),desc:()=>F("tau_red_subjugate"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Money:()=>285e7},effect:()=>F("tau_red_subjugate_effect"),action(){return!!Os($(this)[0])&&(t.race.womling_lord=1,Je(),!0)}},jeff:{id:"tauceti-jeff",title:()=>F("tau_red_jeff"),desc:()=>F("tau_red_jeff"),reqs:{tau_red:5},path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{},effect(){let e=t.tauceti.overseer?t.tauceti.overseer.injured:0;t.tauceti.overseer&&t.tauceti.overseer.pop${F("tau_red_jeff_effect1",[t.tauceti.overseer?t.tauceti.overseer.pop:0])}
          `;return a+=`
          ${F("tau_red_jeff_effect2",[t.tauceti.overseer?t.tauceti.overseer.working:0])}
          `,a+=`
          ${F("tau_red_jeff_effect3",[e])}
          `,a+=`
          ${F("tau_red_jeff_effect4",[t.tauceti.overseer?t.tauceti.overseer.loyal:0])}
          `,a+=`
          ${F("tau_red_jeff_effect5",[t.tauceti.overseer?t.tauceti.overseer.morale:0])}
          `,t.tech.hasOwnProperty("womling_tech")&&(a+=`
          ${F("tau_red_jeff_effect6",[t.tech.womling_tech])}
          `),a+=`
          ${F("job_farmer")}: ${t.tauceti.womling_farm?t.tauceti.womling_farm.farmers:0}
          `,a+=`
          ${F("job_miner")}: ${t.tauceti.womling_mine?t.tauceti.womling_mine.miners:0}
          `,t.tauceti.womling_lab&&(a+=`
          ${F("job_scientist")}: ${t.tauceti.womling_lab?t.tauceti.womling_lab.scientist:0}
          `),a},action:()=>!1},overseer:{id:"tauceti-overseer",title(){return $(this)[0].name()},desc(){return`
          ${$(this)[0].name()}
          ${F("space_support",[Xt().red])}
          `},name:()=>t.race.womling_lord?F("tau_red_overseer"):t.race.womling_god?F("tau_red_womgod"):F("tau_red_womally"),reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Xi("overseer",e,6e6,1.28,"tauceti"),Cement:e=>Xi("overseer",e,245e4,1.28,"tauceti"),Alloy:e=>t.race.womling_friend?Xi("overseer",e,185e4,1.28,"tauceti"):0,Neutronium:e=>t.race.womling_lord?Xi("overseer",e,165e3,1.28,"tauceti"):0,Titanium:e=>t.race.womling_god?Xi("overseer",e,225e4,1.28,"tauceti"):0},effect(){let e=`
          ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
          `;return e+=`
          ${F("tau_red_overseer_effect",[$(this)[0].val()])}
          `,e},val(){let e=0;return t.race.womling_lord?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?12:10:t.race.womling_god?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?6:5:t.race.womling_friend&&(e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?10:8),t.race.lone_survivor&&(e*=2),e},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.overseer.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.overseer.on++,!0)}},womling_village:{id:"tauceti-womling_village",title:F("tau_red_womling_village"),desc:()=>`
          ${F("tau_red_womling_village")}
          ${F("space_support",[Xt().red])}
          `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Xi("womling_village",e,1e7,1.28,"tauceti"),Stone:e=>Xi("womling_village",e,225e4,1.28,"tauceti"),Plywood:e=>Xi("womling_village",e,Ye(125e4),1.28,"tauceti"),Wrought_Iron:e=>Xi("womling_village",e,Ye(4e5),1.28,"tauceti")},effect(){let e=t.tech.womling_pop&&t.tech.womling_pop>=2?6:5,a=`
          ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
          `;return a+=`
          ${F("tau_red_womling_village_effect",[e])}
          `,t.tech.tau_junksale&&(a+=`
          ${F("tau_red_womling_village_effect2",[40,F(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`)])}
          `),a},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_village.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_village.on++,!0)}},womling_farm:{id:"tauceti-womling_farm",title:F("tau_red_womling_farm"),desc:()=>`
          ${F("tau_red_womling_farm")}
          ${F("space_support",[Xt().red])}
          `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Xi("womling_farm",e,24e6,1.28,"tauceti"),Iron:e=>Xi("womling_farm",e,95e5,1.28,"tauceti"),Water:e=>Xi("womling_farm",e,5e3,1.28,"tauceti")},effect(){let e=t.tech.womling_pop?16:12;t.tech.womling_gene&&(e+=4);let a=t.tauceti.hasOwnProperty("womling_farm")?t.tauceti.womling_farm.farmers:0,r=`
          ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
          `;return r+=`
          ${F("tau_red_womling_farm_effect",[e])}
          `,r+=`
          ${F("tau_red_womling_employ",[2])}
          `,t.tech.isolation&&(r+=`
          ${F("tau_red_womling_generate",[t.resource.Furs.name])}
          `),r+=`
          ${F("tau_red_womling_farm_effect2",[e/2*a])}
          `,r},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_farm.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_farm.on++,!0)}},womling_mine:{id:"tauceti-womling_mine",title:F("tau_red_womling_mine"),desc:()=>`
          ${F("tau_red_womling_mine")}
          ${F("space_support",[Xt().red])}
          `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Xi("womling_mine",e,125e5,1.28,"tauceti"),Lumber:e=>Xi("womling_mine",e,128e5,1.28,"tauceti"),Steel:e=>Xi("womling_mine",e,45e5,1.28,"tauceti")},effect(){let e=`
          ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
          `;return t.tech.isolation?t.race.lone_survivor?e+=`
          ${F("tau_red_womling_mine_effect_c",[t.resource.Unobtainium.name,t.resource.Uranium.name,t.resource.Titanium.name,t.resource.Iron.name,t.resource.Copper.name,t.resource.Aluminium.name,t.resource.Neutronium.name,t.resource.Iridium.name])}
          `:e+=`
          ${F("tau_red_womling_mine_effect_b",[t.resource.Unobtainium.name,t.resource.Uranium.name,t.resource.Titanium.name])}
          `:e+=`
          ${F("tau_red_womling_mine_effect_a",[t.resource.Unobtainium.name])}
          `,e+=`
          ${F("tau_red_womling_employ",[6])}
          `,e},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_mine.count++,t.resource.Unobtainium.display=!0,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_mine.on++,!0)},flair:()=>F("tau_red_womling_mine_flair")},womling_fun:{id:"tauceti-womling_fun",title(){return $(this)[0].name()},desc(){return`
          ${$(this)[0].name()}
          ${F("space_support",[Xt().red])}
          `},name:()=>t.race.womling_lord?F("tau_red_womling_fun1"):t.race.womling_god?F("tau_red_womling_fun2"):F("tau_red_womling_fun3"),reqs:{tau_red:6},path:["truepath"],cost:{Money:e=>Xi("womling_fun",e,38e5,1.28,"tauceti"),Food:e=>t.race.womling_friend?Xi("womling_fun",e,175e3,1.28,"tauceti"):0,Lumber:e=>Xi("womling_fun",e,5e5,1.28,"tauceti"),Stone:e=>Xi("womling_fun",e,5e5,1.28,"tauceti"),Furs:e=>t.race.womling_lord||t.race.womling_god?Xi("womling_fun",e,835e3,1.28,"tauceti"):0,Copper:e=>t.race.womling_lord?Xi("womling_fun",e,1125e3,1.28,"tauceti"):0,Alloy:e=>t.race.womling_god?Xi("womling_fun",e,656e3,1.28,"tauceti"):0,Water:e=>t.race.womling_friend?Xi("womling_fun",e,3500,1.28,"tauceti"):0},effect(){let e=`
          ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
          `;return e+=`
          ${F("tau_red_womling_fun_effect",[$(this)[0].val()])}
          `,e},val(){let e=0;return t.race.womling_lord?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?24:20:t.race.womling_god?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?12:10:t.race.womling_friend&&(e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?18:15),t.race.lone_survivor&&(e*=2),e},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_fun.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_fun.on++,!0)}},womling_lab:{id:"tauceti-womling_lab",title:F("interstellar_laboratory_title"),desc:()=>`
          ${F("interstellar_laboratory_title")}
          ${F("space_support",[Xt().red])}
          `,reqs:{tau_red:7},path:["truepath"],cost:{Money:e=>Xi("womling_lab",e,65e6,1.28,"tauceti"),Elerium:e=>Xi("womling_lab",e,1200,1.28,"tauceti"),Orichalcum:e=>Xi("womling_lab",e,25e5,1.28,"tauceti"),Unobtainium:e=>Xi("womling_lab",e,1e4,1.28,"tauceti"),Quantium:e=>Xi("womling_lab",e,Ye(95e3),1.28,"tauceti")},effect(){let e=t.tauceti.hasOwnProperty("overseer")?t.tauceti.overseer.prod:100,a=Math.round(25e3*e/100),r=`
          ${F("tau_new_support",[$(this)[0].support(),Xt().red])}
          `;return r+=`
          ${F("tau_red_womling_lab_effect",[a])}
          `,r+=`
          ${F("tau_red_womling_employ_single",[1])}
          `,r},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.womling_lab.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_lab.on++,!0)}}},tau_gas:{info:{name(e,a){let r=a||"gas_name",s="gas_name"===r?0:1;if(e||t.race[r])switch(e||t.race[r]){case 1:{let e="antimatter"===t.race.universe?"plasmid":"antiplasmid";switch(Math.round(t.stats[e]+s)%3){case 1:return F("tau_planet",[Xt().gas]);case 2:return F("tau_gas_title0a",[Xt().gas]);default:return F("tau_gas_title0b",[Xt().gas])}}case 2:switch(Math.round(t.stats.reset+s)%3){case 1:return F("tau_gas_title1a");case 2:return F("tau_gas_title1b");default:return F("tau_gas_title1c")}case 3:switch(Math.round(t.stats.mad+s)%3){case 1:return F("tau_gas_title2a");case 2:return F("tau_gas_title2b");default:return F("tau_gas_title2c")}case 4:switch(Math.round(t.stats.bioseed+s)%3){case 1:return F("tau_gas_title3a",[di[t.race.gods].solar.gas]);case 2:return F("tau_gas_title3b",[di[t.race.old_gods].name]);default:return F("tau_gas_title3c",[di[t.race.species].name])}case 5:switch(Math.round(t.stats.portals+s)%3){case 1:return F("tau_gas_title4a",[Xt().gas]);case 2:return F("tau_gas_title4b",[Ac("reverse",Xt().gas)]);default:return F("tau_gas_title4c")}case 6:switch(Math.round(t.stats.womling.friend.l+t.stats.womling.lord.l+t.stats.womling.god.l+s)%3){case 1:return F("tau_gas_title5a");case 2:return F("tau_gas_title5b");default:return F("tau_gas_title5c")}case 7:switch(Math.round(t.stats.tdays+s)%3){case 1:return F("tau_gas_title6a");case 2:return F("tau_gas_title6b");default:return F("tau_gas_title6c")}default:return F("gas_name"===r?"tau_gas_title":"tau_gas2_title")}return F("gas_name"===r?"tau_gas_title":"tau_gas2_title")},desc:()=>F("tau_gas_desc")},gas_contest:{id:"tauceti-gas_contest",title:()=>F("tau_gas_contest_title"),desc:()=>F("tau_gas_contest_title"),reqs:{tauceti:5},grant:["tau_gas",1],path:["truepath"],queue_complete:()=>t.tech.tau_gas>=1?0:1,cost:{Money:()=>1e7},effect:()=>t.race.lone_survivor?F("tau_gas_contest_effect_alt"):F("tau_gas_contest_effect"),action(){return!!Os($(this)[0])}},refueling_station:{id:"tauceti-refueling_station",title:()=>F("tau_gas_refueling_station_title"),desc:()=>`
          ${F("tau_gas_refueling_station_title")}
          ${F("requires_power")}
          `,reqs:{tau_gas:2},path:["truepath"],cost:{Money:e=>Xi("refueling_station",e,68e6,1.28,"tauceti"),Graphene:e=>Xi("refueling_station",e,25e5,1.28,"tauceti"),Unobtainium:e=>Xi("refueling_station",e,5500,1.28,"tauceti"),Mythril:e=>Xi("refueling_station",e,Ye(6e4),1.28,"tauceti")},powered:()=>oc(t.tech.isolation?2:5),effect(){let e=+Pe("refueling_station").toFixed(2),a=Lr(1e4),r=`
          ${F("space_gas_mining_effect1",[e])}
          `;return r+=`
          ${F("plus_max_resource",[a.toLocaleString(),t.resource.Helium_3.name])}
          `,t.tech.tau_whale>=2&&(r+=`
          ${F("plus_max_resource",[Lr(6500).toLocaleString(),t.resource.Oil.name])}
          `),t.tech.isolation&&(r+=`
          ${F("interstellar_g_factory_effect")}
          `),r+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,r},special:()=>!!t.tech.isolation,action(){return!!Os($(this)[0])&&(t.tauceti.refueling_station.count++,xs($(this)[0]),!0)},post(){2===t.tech.tau_gas&&(t.tech.tau_gas=3,ms())}},ore_refinery:{id:"tauceti-ore_refinery",title:()=>F("tau_gas_ore_refinery_title"),desc:()=>`
          ${F("tau_gas_ore_refinery_title")}
          ${F("requires_power")}
          `,reqs:{tau_gas:4},path:["truepath"],cost:{Money:e=>Xi("ore_refinery",e,52e6,1.28,"tauceti"),Iridium:e=>Xi("ore_refinery",e,16e5,1.28,"tauceti"),Unobtainium:e=>Xi("ore_refinery",e,800,1.28,"tauceti"),Sheet_Metal:e=>Xi("ore_refinery",e,Ye(118e3),1.28,"tauceti")},powered:()=>oc(t.tech.isolation?2:8),effect(){let e=t.tauceti.hasOwnProperty("ore_refinery")?t.tauceti.ore_refinery.fill:0,a=t.tauceti.hasOwnProperty("ore_refinery")?t.tauceti.ore_refinery.max:0,r=+Pe("ore_refinery").toFixed(2),s=`
          ${F("tau_gas_ore_refinery_effect",[+e.toFixed(2)])}
          `;return s+=`
          ${F("tau_gas_ore_refinery_effect2",[a])}
          `,s+=`
          ${F("tau_gas_ore_refinery_effect3",[r])}
          `,s+=`
          ${F("interstellar_stellar_forge_effect3",[t.tech.isolation?12:4])}
          `,s+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,s},special:!0,action(){return!!Os($(this)[0])&&(t.tauceti.ore_refinery.count++,t.city.powered&&t.city.power>=$(this)[0].powered()&&(t.tauceti.ore_refinery.on++,t.city.smelter.cap+=t.tech.isolation?12:2,t.city.smelter.Steel+=t.tech.isolation?12:2,t.race.evil?t.city.smelter.Wood+=t.tech.isolation?12:2:t.city.smelter.Oil+=t.tech.isolation?12:2),!0)},post(){3===t.tech.tau_roid&&(t.tech.tau_roid=4,tt(),ms())}},whaling_station:{id:"tauceti-whaling_station",title:()=>F("tau_gas_whaling_station_title"),desc:()=>`
          ${F("tau_gas_whaling_station_title")}
          ${F("requires_power")}
          `,reqs:{tau_whale:1},path:["truepath"],cost:{Money:e=>Xi("whaling_station",e,72e6,1.28,"tauceti"),Steel:e=>Xi("whaling_station",e,18e5,1.28,"tauceti"),Polymer:e=>Xi("whaling_station",e,955e3,1.28,"tauceti"),Orichalcum:e=>Xi("whaling_station",e,268e3,1.28,"tauceti")},powered:()=>oc(t.tech.isolation?2:6),effect(){let e=t.tauceti.hasOwnProperty("whaling_station")?t.tauceti.whaling_station.fill:0,a=t.tauceti.hasOwnProperty("whaling_station")?t.tauceti.whaling_station.max:0,r=+Pe("whaling_station").toFixed(2),s=`
          ${F("tau_gas_whaling_station_effect",[+e.toFixed(2)])}
          `;return s+=`
          ${F("tau_gas_whaling_station_effect2",[a])}
          `,s+=`
          ${F("tau_gas_whaling_station_effect3",[r])}
          `,s+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,s},action(){return!!Os($(this)[0])&&(t.tauceti.whaling_station.count++,xs($(this)[0]),!0)},post(){1===t.tech.tau_whale&&(t.tech.tau_whale=2,tt())}},womling_station:{id:"tauceti-womling_station",title:()=>F("tau_gas_womling_station_title"),desc:()=>`
          ${F("tau_gas_womling_station_desc")}
          ${F("requires_power")}
          `,reqs:{womling_technicians:1},path:["truepath"],cost:{Money:e=>Xi("womling_station",e,1334e5,1.26,"tauceti"),Furs:e=>Xi("womling_station",e,3805e3,1.26,"tauceti"),Aluminium:e=>Xi("womling_station",e,85e5,1.26,"tauceti"),Nano_Tube:e=>Xi("womling_station",e,909e3,1.26,"tauceti")},powered:()=>oc(t.tech.isolation?3:6),effect(){let e=t.tech.isolation?30:8;t.tech.womling_gene&&(e*=1.25);let a=`
          ${F("tau_gas_womling_station_effect",[e,Ze.tau_gas.info.name()])}
          `;return t.race.flier||(a+=`
          ${F("city_cement_plant_effect1",[la(1)])}
          `),a+=`
          ${F("space_red_fabrication_effect1",[la(1)])}
          `,a+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,a},action(){return!!Os($(this)[0])&&(t.tauceti.womling_station.count++,xs($(this)[0]),!0)}}},tau_roid:{info:{name:()=>F("tau_roid_title"),desc:()=>F("tau_roid_desc"),support:"patrol_ship"},roid_mission:{id:"tauceti-roid_mission",title:()=>F("space_mission_title",[F("tau_roid_title")]),desc:()=>F("space_mission_desc",[F("tau_roid_title")]),reqs:{tauceti:5},grant:["tau_roid",1],path:["truepath"],queue_complete:()=>t.tech.tau_roid>=1?0:1,cost:{Helium_3:(e,t)=>+Yt(125e4).toFixed(0)},effect:()=>F("tau_roid_mission_effect",[F("tau_roid_title")]),action(){return!!Os($(this)[0])&&(Di(F("tau_roid_mission_result"),"info",!1,["progress"]),!0)}},patrol_ship:{id:"tauceti-patrol_ship",title:F("tau_roid_patrol_ship"),desc:()=>`
          ${F("tau_roid_patrol_ship")}
          ${F("requires_res",[t.resource.Helium_3.name])}
          `,reqs:{tau_roid:3},path:["truepath"],cost:{Money:e=>Xi("patrol_ship",e,45e6,1.25,"tauceti"),Adamantite:e=>Xi("patrol_ship",e,18e5,1.25,"tauceti"),Elerium:e=>Xi("patrol_ship",e,520,1.25,"tauceti"),Stanene:e=>Xi("patrol_ship",e,2675e3,1.25,"tauceti"),Bolognium:e=>Xi("patrol_ship",e,115e4,1.25,"tauceti")},effect(){let e=+Yt($(this)[0].support_fuel().a).toFixed(1),a=`
          ${F("tau_roid_patrol_ship_security",[$(this)[0].support()])}
          `;return a+=`
          ${F("tau_roid_patrol_ship_effect")}
          `,a+=`
          ${F("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
          `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?15:250}),support:()=>1,powered:()=>oc(1),refresh:!0,action(){return!!Os($(this)[0])&&(t.tauceti.patrol_ship.count++,t.tauceti.patrol_ship.on++,!0)}},mining_ship:{id:"tauceti-mining_ship",title:F("tau_roid_mining_ship"),desc:()=>`
          ${F("tau_roid_mining_ship")}
          `,reqs:{tau_roid:4},path:["truepath"],cost:{Money:e=>Xi("mining_ship",e,28e6,1.28,"tauceti"),Uranium:e=>Xi("mining_ship",e,12500,1.28,"tauceti"),Titanium:e=>Xi("mining_ship",e,22e5,1.28,"tauceti"),Alloy:e=>Xi("mining_ship",e,175e4,1.28,"tauceti")},effect(){let e=+Yt($(this)[0].support_fuel().a).toFixed(1),a=`
          ${F("tau_roid_mining_ship_effect",[+Pe("mining_ship").toFixed(2)])}
          `;return a+=`
          ${F("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
          `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?12:75}),support:()=>-1,powered:()=>oc(1),special:!0,action(){return!!Os($(this)[0])&&(t.tauceti.mining_ship.count++,t.tauceti.mining_ship.on++,!0)}},whaling_ship:{id:"tauceti-whaling_ship",title:F("tau_roid_whaling_ship"),desc:()=>`
          ${F("tau_roid_whaling_ship")}
          `,reqs:{tau_whale:2},path:["truepath"],cost:{Money:e=>Xi("whaling_ship",e,35e6,1.28,"tauceti"),Aluminium:e=>Xi("whaling_ship",e,34e5,1.28,"tauceti"),Neutronium:e=>Xi("whaling_ship",e,168e3,1.28,"tauceti"),Nano_Tube:e=>Xi("whaling_ship",e,8e5,1.28,"tauceti")},effect(){let e=+Yt($(this)[0].support_fuel().a).toFixed(1),a=`
          ${F("tau_roid_whaling_ship_effect",[+Pe("whaling_ship").toFixed(2)])}
          `;return a+=`
          ${F("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
          `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?14:90}),support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.tauceti.whaling_ship.count++,t.tauceti.whaling_ship.on++,!0)}}},tau_gas2:{info:{name:e=>Ze.tau_gas.info.name(e||t.race.gas_name2||!1,"gas_name2"),desc:()=>F("tau_gas2_desc",[Ze.tau_gas.info.name()])},gas_contest2:{id:"tauceti-gas_contest2",title:()=>F("tau_gas2_contest_title"),desc:()=>F("tau_gas2_contest_title"),reqs:{tau_gas2:1},grant:["tau_gas2",2],path:["truepath"],queue_complete:()=>t.tech.tau_gas2>=1?0:1,cost:{Money:()=>25e6},effect:()=>F("tau_gas2_contest_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tau_gas2_contest_flair")},alien_station_survey:{id:"tauceti-alien_station_survey",title:F("tau_gas2_alien_station"),desc:F("tau_gas2_alien_station"),reqs:{tau_gas2:3},grant:["tau_gas2",4],path:["truepath"],queue_complete:()=>t.tech.tau_gas3>=4?0:1,cost:{Money:()=>t.race.lone_survivor?15e8:3e9,Helium_3:()=>5e6},effect:()=>F("tau_gas2_alien_station_repair_effect",[Ze.tau_gas2.info.name()]),action(){return!!Os($(this)[0])&&(t.tauceti.alien_station={count:0},Di(F("tau_gas2_alien_station_msg",[Ze.tau_gas2.info.name()]),"info",!1,["progress"]),!0)}},alien_station:{id:"tauceti-alien_station",title:F("tau_gas2_alien_station"),desc:e=>!t.tauceti.hasOwnProperty("alien_station")||t.tauceti.alien_station.count<100||e?`
          ${F("tau_gas2_alien_station")}
          `+(t.tauceti.hasOwnProperty("alien_station")&&t.tauceti.alien_station.count>=100?`
          ${F("space_dwarf_reactor_desc_req")}
          `:`
          ${F("tau_gas2_alien_station_repair")}
          `):`
          ${F("tau_gas2_alien_station")}
          `,reqs:{tau_gas2:4},condition:()=>t.tauceti.alien_station.count<100,path:["truepath"],queue_size:5,queue_complete:()=>100-t.tauceti.alien_station.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?12e6:5e7:0,Aluminium:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?256e3:256e4:0,Polymer:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?198900:989e3:0,Mythril:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?Ye(125e3):0,Cipher:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?256:2001:0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0);return r<100?(a+=`
          ${F("tau_gas2_alien_station_repaired",[r])}
          `,a):Ze.tau_gas2.alien_space_station.effect(e)},action(){return!!(Os($(this)[0])&&t.tauceti.alien_station.count<100)&&(t.tauceti.alien_station.count++,t.tauceti.alien_station.count>=100&&(t.tech.tau_gas2=5,t.tauceti.alien_space_station={count:1,on:0}),!0)},post(){t.resource.Elerium.diff>=10&&(t.tauceti.alien_space_station.on=1),tt()}},alien_space_station:{id:"tauceti-alien_space_station",title:F("tau_gas2_alien_station"),desc:()=>`
          ${F("tau_gas2_alien_station")}
          ${F("space_dwarf_reactor_desc_req")}
          `,reqs:{tau_gas2:5},path:["truepath"],cost:{},queue_complete:()=>0,special:()=>!(!t.tech.tau_gas2||6!==t.tech.tau_gas2||t.tech.alien_data&&!(t.tech.alien_data<6)),wiki:!1,effect(){let e=$(this)[0].p_fuel().a,a=`
          ${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
          `;if(t.tech.tau_gas2&&t.tech.tau_gas2>=6&&t.tauceti.alien_space_station.hasOwnProperty("decrypted")){let e=t.race.lone_survivor?1e5:25e6,r=+(t.tauceti.alien_space_station.decrypted/e).toFixed(2);r>100&&(r=100),a+=`
          ${F("tau_gas2_alien_station_effect",[r])}
          `}return a+=`
          ${F("spend",[e,t.resource[$(this)[0].p_fuel().r].name])}
          `,a},p_fuel:()=>({r:"Elerium",a:t.race.lone_survivor?1:10}),powered:()=>cc(-75),action:()=>!1},matrioshka_brain:{id:"tauceti-matrioshka_brain",title:F("tech_matrioshka_brain"),desc:e=>!t.tauceti.hasOwnProperty("matrioshka_brain")||t.tauceti.matrioshka_brain.count<1e3||e?`
          ${F("tech_matrioshka_brain")}
          ${F("requires_segmemts",[1e3])}
          `:`
          ${F("tech_matrioshka_brain")}
          `,reqs:{tau_gas2:7},condition:()=>!!t.tauceti.matrioshka_brain,path:["truepath"],queue_size:50,queue_complete:()=>1e3-t.tauceti.matrioshka_brain.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?2e7:0,Neutronium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?45e3:0,Nano_Tube:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?16e4:0,Adamantite:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?666e3:0,Stanene:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?61600:0,Bolognium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?44e3:0,Unobtainium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?1200:0,Mythril:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?Ye(64e3):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0);return r<1e3&&(a+=`
          ${F("tau_gas2_matrioshka_brain_seg",[1e3-r])}
          `),a},action(){return!!(Os($(this)[0])&&t.tauceti.matrioshka_brain.count<1e3)&&(t.tauceti.matrioshka_brain.count++,t.tauceti.matrioshka_brain.count>=1e3&&(t.tech.m_brain=1),!0)}},ignition_device:{id:"tauceti-ignition_device",title:F("tech_ignition_device"),desc:e=>!t.tauceti.hasOwnProperty("ignition_device")||t.tauceti.ignition_device.count<10||e?`
          ${F("tech_ignition_device")}
          ${F("requires_segmemts",[10])}
          `:`
          ${F("tech_ignition_device")}
          `,reqs:{tau_gas2:8},condition:()=>!!(t.tauceti.ignition_device&&t.tauceti.ignition_device.count<10),path:["truepath"],queue_size:1,queue_complete:()=>10-t.tauceti.ignition_device.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?25e7:0,Uranium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?5e4:0,Elerium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?25e3:0,Graphene:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?225e5:0,Orichalcum:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?15e6:0,Quantium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?Ye(8e6):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0);return r<10&&(a+=`
          ${F("tau_gas2_ignition_device_seg",[10-r])}
          `),a},action(){return!!(Os($(this)[0])&&t.tauceti.ignition_device.count<10)&&(t.tauceti.ignition_device.count++,t.tauceti.ignition_device.count>=10&&(t.tech.m_ignite=1),!0)}},ignite_gas_giant:{id:"tauceti-ignite_gas_giant",title:()=>F("tau_gas2_ignite_gas_giant",[Ze.tau_gas2.info.name()]),desc:()=>F("tau_gas2_ignite_gas_giant",[Ze.tau_gas2.info.name()]),reqs:{tau_gas2:8,m_ignite:1},grant:["m_ignite",2],queue_size:1,queue_complete:()=>!1,path:["truepath"],cost:{Helium_3:()=>75e5},effect(){let e=`
          ${F("tau_gas2_ignite_gas_giant_effect",[F("tech_matrioshka_brain")])}
          `;return t.tech.m_brain?(e+=`
          ${F("tau_gas2_ignite_gas_giant_effect3")}
          `,e+=function(){let e=mc("retire"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name"),r=t.stats.retire+1===t.stats.matrix?`
          ${F("tau_star_matrix_skilled",[1])}
          `:"";return`
          ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
          ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
          ${F("tau_star_matrix_servants",[1])}
          ${r}`}()):e+=`
          ${F("tau_gas2_ignite_gas_giant_effect2",[F("tech_matrioshka_brain")])}
          `,e},action(){return!(!t.tech.m_brain||!Os($(this)[0])||(function(){M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"retire"});let a=t.race.species,r=t.race.gods,s=di[a].type,i=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,n=t.city.geology,l=mc("retire");Xc(`biome_${c}`),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),Xc(`genus_${s}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),Xc("retired"),Z(),so(),t.stats.retire++,Fc(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let u=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),u&&(t.race.srace=u),Q({orbit:i,biome:c,ptrait:o,geology:n}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),0))}}}};for(let e=1;e<9;e++)Ze.tau_gas[`gas_contest-a${e}`]={id:`tauceti-gas_contest-a${e}`,title:()=>Ze.tau_gas.info.name(e),desc:()=>Ze.tau_gas.info.name(e),reqs:{tau_gas:1},grant:["tau_gas",2],path:["truepath"],wiki:!1,queue_complete:()=>t.tech.tau_gas>=2?0:1,cost:{},effect:()=>F(8===e?"tau_gas_contest_reject":"tau_gas_contest_pick",[Ze.tau_gas.info.name(e)]),action(){return!!Os($(this)[0])&&(t.race.gas_name=e,t.tauceti.refueling_station={count:0,on:0},!0)}},Ze.tau_gas2[`gas_contest-b${e}`]={id:`tauceti-gas_contest-b${e}`,title:()=>Ze.tau_gas2.info.name(e),desc:()=>Ze.tau_gas2.info.name(e),reqs:{tau_gas2:2},grant:["tau_gas2",3],path:["truepath"],wiki:!1,queue_complete:()=>t.tech.tau_gas2>=3?0:1,cost:{},effect:()=>F(8===e?"tau_gas2_contest_reject":"tau_gas_contest_pick",[Ze.tau_gas2.info.name(e)]),action(){return!!Os($(this)[0])&&(t.race.gas_name2=e,!0)}};function Ve(){let e=mc("matrix"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name"),r=t.stats.retire===t.stats.matrix+1?`
          ${F("tau_star_matrix_skilled",[1])}
          `:"";return`
          ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
          ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
          ${F("tau_star_matrix_servants",[1])}
          ${r}`}function Je(){t.tauceti.overseer={count:0,on:0,pop:0,working:0,injured:0,morale:0,loyal:0,prod:0},t.tauceti.womling_village=t.race.lone_survivor?{count:2,on:2}:{count:1,on:1},t.tauceti.womling_mine=t.race.lone_survivor?{count:1,on:1,miners:0}:{count:0,on:0,miners:0},t.tauceti.womling_farm={count:1,on:1,farmers:0},t.tauceti.womling_fun={count:0,on:0}}function Ye(e){return t.tech.womling_tech&&t.tech.womling_recycling&&t.tech.womling_recycling>=1&&(e*=(t.tech.isolation?.97:.98)**t.tech.womling_tech),e}function Xe(){return Qe}function et(){return!!(t.tech.tauceti&&t.tech.tauceti>=4)}function tt(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||6!==t.settings.spaceTabs))return;let e=$("#tauceti");rc(e),e.append($(`

          ${F("tab_tauceti")}

          `)),!t.tech.tauceti||t.tech.tauceti<2||Object.keys(Ze).forEach((function(a){let r=a.replace("tau_","");if(t.settings.tau[`${r}`]){let r="string"==typeof Ze[a].info.name?Ze[a].info.name:Ze[a].info.name(),s="";if(Ze[a].info.hasOwnProperty("prop")&&(s=Ze[a].info.prop()),Ze[a].info.support){let i=Ze[a].info.support;Ze[a].info.hide_support?e.append(`

          ${r}

          ${s}
          `):e.append(`

          ${r}

          {{ support }}/{{ s_max }}${s}
          `),sc({el:`#sr${a}`,data:t.tauceti[i],filters:{filter(){return Ze[a].info.filter(...arguments)}}})}else e.append(`

          ${r}

          ${s}
          `);Ti(a,(function(){return"string"==typeof Ze[a].info.desc?Ze[a].info.desc:Ze[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(Ze[a]).forEach((function(e){"info"!==e&&Gt(Ze,a,e)&&fs(Ze[a][e],"tauceti",e)})),Ze[a].info.hasOwnProperty("extra")&&Ze[a].info.extra(a)}}))}function at(){if((t.settings.tabLoad||2===t.settings.civTabs&&5===t.settings.govTabs)&&(ft(),dt(),rc($("#dwarfShipYard")),t.space.hasOwnProperty("shipyard")&&t.settings.showShipYard)){let e=$("#dwarfShipYard");t.space.shipyard.hasOwnProperty("blueprint")||(t.space.shipyard.blueprint={class:"corvette",armor:"steel",weapon:"railgun",engine:"ion",power:"diesel",sensor:"radar",name:rt()});let a=$('
          ');e.append(a);let r=$('
          ');a.append(r),r.append(`
          ${F("outer_shipyard_registry")}:
          `),r.append(`
          ${F("crew")}
          `),r.append(`
          ${F("power")}
          `),r.append(`
          ${F("firepower")}
          `),r.append(`
          ${F("outer_shipyard_sensors")}
          `),r.append(`
          ${F("speed")}
          `),r.append(`
          ${F("outer_shipyard_fuel")}
          `),a.append('
          ');let s=$('
          ');a.append(s);let i={class:["corvette","frigate","destroyer","cruiser","battlecruiser","dreadnought","explorer"],power:["solar","diesel","fission","fusion","elerium"],weapon:["railgun","laser","p_laser","plasma","phaser","disruptor"],armor:["steel","alloy","neutronium"],engine:["ion","tie","pulse","photon","vacuum","emdrive"],sensor:["visual","radar","lidar","quantum"]};Object.keys(i).forEach((function(e){let t="";i[e].forEach((function(a,r){t+=`${F(`outer_shipyard_${e}_${a}`)}`})),s.append(`\n ${t}\n `)}));let c=$('
          ');c.append(``),c.append(`${F("outer_shipyard_fleet_details")}`),c.append(`${F("outer_shipyard_fleet_sort")}`),a.append(c),c.append(`
          ${F("outer_shipyard_park",[Xt().dwarf])}${F("outer_shipyard_map")}`),st();let o={template:''};sc({el:"#shipPlans",data:{b:t.space.shipyard.blueprint,s:t.space.shipyard},methods:{setVal(e,a){"class"===e&&"explorer"===a?(t.space.shipyard.blueprint.engine="emdrive",t.space.shipyard.blueprint.weapon="railgun",t.tech.syard_armor>=3&&(t.space.shipyard.blueprint.armor="neutronium"),t.tech.syard_sensor>=4&&(t.space.shipyard.blueprint.sensor="quantum"),t.tech.syard_power>=4&&(t.space.shipyard.blueprint.power="elerium")):"class"===e&&"explorer"!==a&&"explorer"===t.space.shipyard.blueprint.class&&(t.space.shipyard.blueprint.engine="ion"),t.space.shipyard.blueprint[e]=a,st()},avail(e,a,r){if(!("class"!==e&&"engine"!==e||!t.tech.tauceti||"emdrive"!==r&&"explorer"!==r))return!0;if("explorer"===t.space.shipyard.blueprint.class){if("weapon"===e)return 1===a;if("engine"===e)return 6===a;if("sensor"===e)return 4===a}return t.tech[`syard_${e}`]>a},crewText:()=>it(t.space.shipyard.blueprint),powerText(){let e=ct(t.space.shipyard.blueprint);return e<0?`${e}kW`:`${e}kW`},fireText:()=>ot(t.space.shipyard.blueprint),sensorText:()=>mt(t.space.shipyard.blueprint)+"km",speedText(){let e=7.695363719135802*nt(t.space.shipyard.blueprint);return Math.round(e)+"km/s"},fuelText(){let e=lt(t.space.shipyard.blueprint);return e.res?`-${e.burn} ${t.resource[e.res].name}`:"N/A"},build(){if(ct(t.space.shipyard.blueprint)>=0){let e=ut(t.space.shipyard.blueprint),a={};if(Object.keys(e).forEach((function(t){a[t]=function(){return e[t]}})),Os(!1,a)){let e=zc(t.space.shipyard.blueprint);e.location="spc_dwarf",e.xy=vt("spc_dwarf"),e.origin=zc(e.xy),e.destination=zc(e.xy),e.transit=0,e.dist=0,e.damage=0,e.fueled=!1,0===e.name.length&&(e.name=rt());let a=1,r=e.name;for(;t.space.shipyard.ships.filter((e=>e.name===r)).length>0;)a++,r=e.name+` ${a}`;e.name=r,t.space.shipyard.ships.push(e),_t(),st(),t.space.shipyard.blueprint.name=rt()}}},trigModal(){this.$buefy.modal.open({parent:this,component:o});let e=setInterval((function(){$("#modalBox").length>0&&(clearInterval(e),$("#modalBox").append($('

          Solar System

          ')),function(e){let t=$('
          ').appendTo(e),a={},r={},s=!1;qt={},kt=20,t.append($('').on("mouseup mouseover mouseout",(()=>s=!1)).on("mousedown",(e=>{s=!0,r.x=e.clientX-qt.x,r.y=e.clientY-qt.y})).on("mousemove",(e=>{s&&(qt.x=e.clientX-r.x,qt.y=e.clientY-r.y,Mt())})).on("wheel",(e=>(e.originalEvent.deltaY<0?(kt/=.8,qt.x=a.x+(qt.x-a.x)/.8,qt.y=a.y+(qt.y-a.y)/.8,Mt()):(kt*=.8,qt.x=a.x+.8*(qt.x-a.x),qt.y=a.y+.8*(qt.y-a.y),Mt()),!1))),$('').on("click",(()=>{kt/=.8,qt.x=a.x+(qt.x-a.x)/.8,qt.y=a.y+(qt.y-a.y)/.8,Mt()})),$('').on("click",(()=>{kt*=.8,qt.x=a.x+.8*(qt.x-a.x),qt.y=a.y+.8*(qt.y-a.y),Mt()})));let i=document.getElementById("mapCanvas").getBoundingClientRect();a.x=i.width/2,a.y=i.height/2,qt.x=a.x,qt.y=a.y,Mt()}($("#modalBox")))}),50)},redraw(){_t()}},filters:{lbl:(e,t)=>F(`outer_shipyard_${t}_${e}`)}}),Object.keys(i).forEach((function(e){for(let t=0;t<$(`#shipPlans .${e}`).length;t++)Ti(`shipPlans${e}${t}`,(function(t){let a=$(t.this).attr("data-val");return F(`outer_shipyard_${e}_${a}_desc`)}),{elm:`#shipPlans .${e}.a${t}`,placement:"right"})})),e.append($('
          ')),_t()}}function rt(){let e=["Trident","Spacewolf","Excalibur","Neptune","Deimos","Phobos","Enterprise","Intrepid","Daedalus","Odyssey","Endurance","Horizon","Hyperion","Icarus","Aurora","Axiom","Nemesis","Normandy","Orion","Prometheus","Vanguard","Discovery","Voyager","Defiant","Titan","Liberty","Destiny","Phoenix","Nautilus","Barracuda","Dolphin","Cuttlefish","Tiger Shark","Stingray","Swordfish","Triton","Dragon","Scorpion","Hagfish","Marlin","Galileo","Raven","Sarcophagus","Excelsior","Scimitar","Vengeance","Nomad","Nova","Olympus","Aegis","Agamemnon","Charon","Achilles","Apollo","Hermes","Hydra","Medusa","Talos","Zeus","Heracles","Cerberus","Acheron","Damocles","Juno","Persephone","Solaris","Victory","Hawk","Fury","Razor","Stinger","Outrider","Falcon","Vulture","Nirvana","Retribution","Swordbreaker","Valkyrie","Athena","Avalon","Merlin","Argonaut","Serenity","Gunstar","Ranger","Tantive","Cygnus","Nostromo","Reliant","Narcissus","Liberator","Sulaco","Infinity","Resolute","Wasp","Hornet","Independence","Gilgamesh","Midway","Concordia","Goliath","Cosmos","Express","Tigers Claw","Oberon","Minnow","Majestic","Spartacus","Colossi","Vigilant","Remorseless","Caelestis","Inquisitor","Atlas","Avenger","Dauntless","Nihilus","Thanatos","Stargazer","Xyzzy","Kraken","Xerxes","Spitfire","McShipFace","Monitor","Merrimack","Constitution","Ghost","Pequod","Arcadia","Corsair","Inferno","Jenny","Revenge","Red October","Jackdaw","Thorn","Caleuche","Valencia","Ourang","Deering","Baychimo","Octavius","Joyita","Lovibond","Celeste","Dutchman"],a=e[Math.rand(0,e.length)];return t.space.shipyard.ships.filter((e=>e.name===a)).length>0&&(a=function(){let e=["al","an","ar","as","at","ea","ed","en","er","es","ha","he","hi","in","is","it","le","me","nd","ne","ng","nt","on","or","ou","re","se","st","te","th","ti","to","ve","wa","all","and","are","but","ent","era","ere","eve","for","had","hat","hen","her","hin","his","ing","ion","ith","not","ome","oul","our","sho","ted","ter","tha","the","thi","tio","uld","ver","was","wit","you"],t=Math.rand(2,5),a="";for(let r=0;r${t.resource[a].name}${k(e[a])}`):$("#shipYardCosts").append(` | ${t.resource[a].name} ${k(e[a])}`)}))}function it(e){switch(e.class){case"corvette":return la(2);case"frigate":return la(3);case"destroyer":return la(4);case"cruiser":return la(6);case"battlecruiser":return la(8);case"dreadnought":case"explorer":return la(10)}}function ct(e,t){let a=0,r=1,s=1;switch(e.class){case"frigate":r=1.1,s=1.2;break;case"destroyer":r=1.5,s=1.65;break;case"cruiser":r=2,s=2.5;break;case"battlecruiser":r=2.5,s=3.5;break;case"dreadnought":r=5,s=6.5;break;case"explorer":r=6,s=2}switch(e.power){case"solar":a=Math.round(50*r);break;case"diesel":a=Math.round(100*r);break;case"fission":a=Math.round(150*r);break;case"fusion":a=Math.round(("explorer"===e.class||t?174:175)*r);break;case"elerium":a=Math.round(200*r)}switch(a=Math.round(cc(a)),e.weapon){case"railgun":a-=Math.round(10*s);break;case"laser":a-=Math.round(30*s);break;case"p_laser":a-=Math.round(18*s);break;case"plasma":a-=Math.round(50*s);break;case"phaser":a-=Math.round(65*s);break;case"disruptor":a-=Math.round(100*s)}switch(e.engine){case"ion":a-=Math.round(25*s);break;case"tie":a-=Math.round(50*s);break;case"pulse":a-=Math.round(40*s);break;case"photon":a-=Math.round(75*s);break;case"vacuum":a-=Math.round(120*s);break;case"emdrive":a-=Math.round(("explorer"===e.class||t?515:1024)*s)}switch(e.sensor){case"radar":a-=Math.round(10*s);break;case"lidar":a-=Math.round(25*s);break;case"quantum":a-=Math.round(75*s)}return a}function ot(e){let t=0;switch(e.weapon){case"railgun":t=36;break;case"laser":t=64;break;case"p_laser":t=54;break;case"plasma":t=90;break;case"phaser":t=114;break;case"disruptor":t=156}switch(e.class){case"corvette":return t;case"frigate":return Math.round(1.5*t);case"destroyer":return Math.round(2.75*t);case"cruiser":return Math.round(5.5*t);case"battlecruiser":return Math.round(10*t);case"dreadnought":return Math.round(22*t);case"explorer":return Math.round(1.2*t)}}function nt(e){let a=1;switch(e.class){case"corvette":a="neutronium"===e.armor?1.1:1;break;case"frigate":a="neutronium"===e.armor?1.35:1.25;break;case"destroyer":a="neutronium"===e.armor?1.95:1.8;break;case"cruiser":a="neutronium"===e.armor?3.5:3;break;case"battlecruiser":a="neutronium"===e.armor?4.8:4;break;case"dreadnought":a="neutronium"===e.armor?7.5:6;break;case"explorer":a=1}let r="spc_dwarf"===e.location&&i.m_relay&&0===e.transit&&t.space.m_relay&&t.space.m_relay.charged>=1e4?3:1;switch(e.engine){case"ion":return 12/a*r;case"tie":return 22/a*r;case"pulse":return 18/a*r;case"photon":return 30/a*r;case"vacuum":return 42/a*r;case"emdrive":return 37500/a*r}}function lt(e){let t=!1,a=0;switch(e.power){case"diesel":t="Oil",a=8;break;case"fission":t="Uranium",a=.5;break;case"fusion":t="Helium_3",a=12;break;case"elerium":t="Elerium",a=1}switch(e.class){case"frigate":a*=1.25;break;case"destroyer":a*=1.5;break;case"cruiser":a*=2;break;case"battlecruiser":a*=3;break;case"dreadnought":a*=5;break;case"explorer":a*=25}return{res:t,burn:+a.toFixed(2)}}function ut(e){let a={},r=1,s=1,i=1;switch(e.class){case"corvette":a.Money=25e5,a.Aluminium=5e5,r=1,s=1,i=2;break;case"frigate":a.Money=5e6,a.Aluminium=125e4,r=1.1,s=1.09,i=1.5;break;case"destroyer":a.Money=15e6,a.Aluminium=35e5,r=1.2,s=1.18,i=1.2;break;case"cruiser":a.Money=5e7,a.Adamantite=1e6,r=1.3,s=1.25;break;case"battlecruiser":a.Money=125e6,a.Adamantite=26e5,r=1.35,s=1.3,i=.8;break;case"dreadnought":a.Money=5e8,a.Adamantite=8e6,r=1.4,s=1.35,i=.5;break;case"explorer":a.Money=8e8,a.Adamantite=95e5,r=1.45,s=1}switch(e.armor){case"steel":a.Steel=Math.round(35e4**r);break;case"alloy":a.Alloy=Math.round(25e4**r);break;case"neutronium":a.Neutronium=Math.round(1e4**r)}switch(e.engine){case"ion":a.Titanium=Math.round(75e3**s);break;case"tie":a.Titanium=Math.round(15e4**s);break;case"pulse":a.Titanium=Math.round(125e3**s);break;case"photon":a.Titanium=Math.round(21e4**s);break;case"vacuum":a.Titanium=Math.round(3e5**s);break;case"emdrive":a.Titanium=Math.round(125e4**s)}let c=!!["dreadnought","explorer"].includes(e.class);switch(e.power){case"solar":case"diesel":a[c?"Orichalcum":"Copper"]=Math.round(4e4**r),a.Iridium=Math.round(15e3**s);break;case"fission":a[c?"Orichalcum":"Copper"]=Math.round(5e4**r),a.Iridium=Math.round(3e4**s);break;case"fusion":a[c?"Orichalcum":"Copper"]=Math.round(5e4**r),a.Iridium=Math.round(4e4**s);break;case"elerium":a[c?"Orichalcum":"Copper"]=Math.round(6e4**r),a.Iridium=Math.round(55e3**s)}if("explorer"!==e.class)switch(e.sensor){case"radar":a.Money=Math.round(a.Money**1.04);break;case"lidar":a.Money=Math.round(a.Money**1.08);break;case"quantum":a.Money=Math.round(a.Money**1.12)}switch(e.weapon){case"railgun":a.Iron=Math.round(25e3**r);break;case"laser":a.Iridium=Math.round(a.Iridium**1.05),a.Nano_Tube=Math.round(12e3**r);break;case"p_laser":a.Iridium=Math.round(a.Iridium**1.035),a.Nano_Tube=Math.round(12e3**r);break;case"plasma":a.Iridium=Math.round(a.Iridium**1.1),a.Nano_Tube=Math.round(2e4**r);break;case"phaser":a.Iridium=Math.round(a.Iridium**1.15),a.Quantium=Math.round(18e3**r);break;case"disruptor":a.Iridium=Math.round(a.Iridium**1.2),a.Quantium=Math.round(35e3**r)}"explorer"===e.class&&(a.Iron*=10,a.Titanium*=5,a.Iridium*=50);let o=0;t.space.shipyard.ships.forEach((function(t){t.class===e.class&&o++}));let n=1+(o-2)/25*i;return Object.keys(a).forEach((function(t){"explorer"===e.class?a[t]=Math.ceil(a[t]*(3*(o+1))):o<2?a[t]=Math.ceil(a[t]*(0===o?.75:.9)):o>2&&(a[t]=Math.ceil(a[t]*n))})),a}function dt(){let e=$("#shipList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}function _t(){if(dt(),rc($("#shipList")),t.tech.isolation)return;let e=$("#shipList");if(t.space.shipyard.sort){let e={spc_dwarf:"a"};t.space.shipyard.ships=t.space.shipyard.ships.sort(((t,a)=>(e[t.location]?e[t.location]:t.location).localeCompare(e[a.location]?e[a.location]:a.location)))}const a=Dt();for(let r=0;r${e}`}}else Object.keys(a).forEach((function(e){if(s.location!==e&&(a[e].info.syndicate()||"spc_dwarf"===e)&&(!t.race.orbit_decayed||t.race.orbit_decayed&&"spc_moon"!==e)){let t="string"==typeof a[e].info.name?a[e].info.name:a[e].info.name();i+=`${t}`}}));let c="tauceti"===s.location?F("tech_era_tauceti"):"string"==typeof a[s.location].info.name?a[s.location].info.name:a[s.location].info.name(),o=`\n ${i}\n `;if(t.space.shipyard.expand){let t=`${F(`outer_shipyard_engine_${s.engine}`)} ${F(`outer_shipyard_class_${s.class}`)}`,a=$(`
          `),i=$(`
          ${s.name} | ${F("outer_shipyard_scrap")} | ${t} | ${F(`outer_shipyard_weapon_${s.weapon}`)} | ${F(`outer_shipyard_power_${s.power}`)} | ${F(`outer_shipyard_armor_${s.armor}`)} | ${F(`outer_shipyard_sensor_${s.sensor}`)}
          `),c=$('
          '),n=$('
          '),l=$(`
          ${o}
          `);c.append(`${F("crew")} `),c.append(`${F("firepower")} `),c.append(`${F("outer_shipyard_sensors")} `),c.append(`${F("speed")} `),c.append(`${F("outer_shipyard_fuel")} `),c.append(`${F("outer_shipyard_hull")} `),n.append(``),a.append(i),a.append(c),a.append(n),a.append(l),e.append(a)}else{let t=$(`
          `),a=$('
          '),i=$('
          '),c=$(`
          ${o}
          `);a.append(`${s.name} | `),a.append(`${F("firepower")} `),a.append(`${F("outer_shipyard_sensors")} `),a.append(`${F("speed")} `),a.append(`${F("outer_shipyard_fuel")} `),a.append(`${F("outer_shipyard_hull")} `),i.append(``),t.append(a),t.append(i),t.append(c),e.append(t)}sc({el:`#shipReg${r}`,data:t.space.shipyard.ships[r],methods:{scrap(e){t.space.shipyard.ships[e]&&"spc_dwarf"===t.space.shipyard.ships[e].location&&(t.space.shipyard.ships.splice(e,1),_t(),st())},scrapAllowed:e=>!(!t.space.shipyard.ships[e]||"spc_dwarf"!==t.space.shipyard.ships[e].location),setLoc(e,a){let r=t.space.shipyard.ships[a];if(e!==r.location){let s=it(r),i=r.transit>0||"spc_dwarf"!==r.location;if(i||t.civic.garrison.workers-t.civic.garrison.crew>=s){let c=pt(r,e),o=yt(r.xy,c),n=nt(r);r.location=e,r.transit=Math.round(o/n),r.dist=Math.round(o/n),r.origin=zc(r.xy),r.destination={x:c.x,y:c.y},i||(t.civic.garrison.crew+=s),_t(),Ei(`ship${a}loc${e}`)}}},crewText:e=>it(t.space.shipyard.ships[e]),fireText:e=>ot(t.space.shipyard.ships[e]),sensorText:e=>mt(t.space.shipyard.ships[e])+"km",speedText(e){let a=7.695363719135802*nt(t.space.shipyard.ships[e]);return Math.round(a)+"km/s"},fuelText(e){let a=lt(t.space.shipyard.ships[e]);return a.res?`${a.burn} ${t.resource[a.res].name}/s`:"N/A"},hullText:e=>100-t.space.shipyard.ships[e].damage+"%",hullDamage:e=>t.space.shipyard.ships[e].damage<=10?"has-text-success":t.space.shipyard.ships[e].damage>=40&&t.space.shipyard.ships[e].damage<65?"has-text-caution":t.space.shipyard.ships[e].damage>=65?"has-text-danger":"",dest(e){let r="explorer"===s.class?F("tech_era_tauceti"):"string"==typeof a[t.space.shipyard.ships[e].location].info.name?a[t.space.shipyard.ships[e].location].info.name:a[t.space.shipyard.ships[e].location].info.name();return F("outer_shipyard_arrive",[r,t.space.shipyard.ships[e].transit])},show:e=>t.space.shipyard.ships[e].transit>0}}),"explorer"===s.class?"tauceti"!==s.location&&Ti(`ship${r}loctauceti`,(function(){return F("transit_time",[Math.round(yt(s.xy,pt(s,"tauceti"))/nt(s))])}),{elm:`#ship${r}loc .tauceti`,placement:"left"}):Object.keys(a).forEach((function(e){(a[e].info.syndicate()||"spc_dwarf"===e)&&s.location!==e&&Ti(`ship${r}loc${e}`,(function(){return F("transit_time",[Math.round(yt(s.xy,pt(s,e))/nt(s))])}),{elm:`#ship${r}loc .${e}`,placement:"left"})}))}!function(){let e=$("#shipList")[0];Sortable.create(e,{onEnd(e){let a=t.space.shipyard.ships;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.space.shipyard.ships=a,_t()}})}()}function pt(e,a){if(-2===gt[a].orbit)return vt(a);let r=Math.sqrt((e.xy.x-xt(a))**2+e.xy.y**2),s=nt(e)/225,i=$t(1,a),c=Math.abs(r-gt[a].dist),o=Math.abs(r+gt[a].dist),n=Math.abs(r-gt[a].dist*i),l=Math.abs(r+gt[a].dist*i),u=Math.floor(Math.min(c,n,o,l)/s),d=Math.ceil(Math.max(c,n,o,l)/s);r>=gt[a].dist&&r<=gt[a].dist*i&&(u=0);let _=360/(-1===gt[a].orbit?t.city.calendar.orbit:gt[a].orbit),p=(t.space.position[a]+u*_)%360,h=Math.PI/180;for(let t=u;t<=d;t++){let r=$t(Math.cos(p*h)*gt[a].dist,a);r+=xt(a);let i=Math.sin(p*h)*gt[a].dist;if(Math.sqrt((r-e.xy.x)**2+(i-e.xy.y)**2)/s<=t)return{x:r,y:i};p=(p+_)%360}return vt(a)}function ht(e,a){if(!t.tech.isolation&&t.tech.syndicate&&t.race.truepath&&t.space.syndicate&&t.space.syndicate.hasOwnProperty(e)){let r=1e3,s=0;switch(t.civic.foreign.gov3.hstl<10?s=250-25*t.civic.foreign.gov3.hstl:t.civic.foreign.gov3.hstl>60&&(s=-13*(t.civic.foreign.gov3.hstl-60)),e){case"spc_home":case"spc_moon":case"spc_red":case"spc_hell":r=1250+s;break;case"spc_gas":case"spc_gas_moon":case"spc_belt":r=1020+s;break;case"spc_titan":case"spc_enceladus":case"spc_triton":case"spc_kuiper":case"spc_eris":r=Qr.space[e].info.syndicate_cap()}let o=t.space.syndicate[e],n=0,l=0,u=0;if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){if(t.space.shipyard.ships.forEach((function(t){if(t.location===e&&0===t.transit&&t.fueled){let e=ot(t);n+=t.damage>0?Math.round(e*(100-t.damage)/100):e,l+=mt(t)}})),"spc_enceladus"===e&&Math.min(c.operating_base,i.operating_base)>0){let e=Math.min(c.operating_base,i.operating_base);n+=50*e}else"spc_titan"===e&&i.sam>0?n+=25*i.sam:"spc_triton"===e&&i.fob>0&&(n+=500,l+=10);l>100&&(l=Math.round((l-100)/(l-100+200)*100)+100),n=Math.round(n*((l+25)/125)),n>o&&(u=n-o),o=o-n>0?o-n:0}return a?{p:1-+(o/r).toFixed(4),r:o,s:l,o:u}:1-+(o/r).toFixed(4)}return a?{p:1,r:0,s:0,o:0}:1}function mt(e){let t=1;switch(e.class){case"corvette":case"frigate":t=2;break;case"destroyer":case"cruiser":t=1.5;break;case"explorer":t=5;break;default:t=1}switch(e.sensor){case"visual":return 1;case"radar":return 10*t;case"lidar":return 18*t;case"quantum":return 32*t}}const gt={spc_sun:{dist:0,orbit:0,size:2},spc_home:{dist:1,orbit:-1,size:.6},spc_moon:{dist:1.01,orbit:-1,size:.1,moon:!0},spc_red:{dist:1.524,orbit:687,size:.5},spc_hell:{dist:.4,orbit:88,size:.4},spc_venus:{dist:.7,orbit:225,size:.5},spc_gas:{dist:5.203,orbit:4330,size:1.25},spc_gas_moon:{dist:5.204,orbit:4330,size:.2,moon:!0},spc_belt:{dist:2.7,orbit:1642,size:.5,belt:!0},spc_dwarf:{dist:2.77,orbit:1682,size:.5},spc_saturn:{dist:9.539,orbit:10751,size:1.1},spc_titan:{dist:9.536,orbit:10751,size:.2,moon:!0},spc_enceladus:{dist:9.542,orbit:10751,size:.1,moon:!0},spc_uranus:{dist:19.8,orbit:30660,size:1},spc_neptune:{dist:30.08,orbit:60152,size:1},spc_triton:{dist:30.1,orbit:60152,size:.1,moon:!0},spc_kuiper:{dist:39.5,orbit:90498,size:.5,belt:!0},spc_eris:{dist:68,orbit:204060,size:.5,size:.5},tauceti:{dist:752568.8,orbit:-2,size:2}};function ft(){t.space.position||(t.space.position={}),Object.keys(gt).forEach((function(e){t.space.position.hasOwnProperty(e)||(t.space.position[e]=Math.rand(0,360))})),t.space.position.spc_home=t.space.position.spc_moon,t.space.position.spc_gas_moon=t.space.position.spc_gas,t.space.position.spc_titan=t.space.position.spc_enceladus,t.space.position.spc_saturn=t.space.position.spc_titan,t.space.position.spc_neptune=t.space.position.spc_triton}function vt(e){let a=$t(+Math.cos(t.space.position[e]*(Math.PI/180)).toFixed(5)*gt[e].dist,e),r=+Math.sin(t.space.position[e]*(Math.PI/180)).toFixed(5)*gt[e].dist;return a+=xt(e),{x:a,y:r}}function yt(e,t){return Math.ceil(225*Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2))}function bt(e,a){let r=1;switch(t.race.pack_rat&&(r*=1+ui.pack_rat.vars()[1]/100),t.stats.achieve.blackhole&&(r*=1+.05*t.stats.achieve.blackhole.l),t.tech.world_control&&(r*=3),e){case"storehouse":i.titan_spaceport&&(r*=1+.25*i.titan_spaceport),a&&t.tech.shelving&&(r*=2),t.tech.shelving&&t.tech.shelving>=3&&(r*=1.5);case"repository":t.tech.isolation&&(r*=3,t.tech.tp_depot&&(r*=1+t.tech.tp_depot/20))}return r}function wt(){let e=0;return i.ai_colonist&&c.decoder&&(e+=i.ai_colonist*c.decoder*.35),c.shock_trooper&&(e+=2*c.shock_trooper),c.tank&&(e+=2*c.tank),e>100&&(e=100),e}function $t(e,a){if(-2!==gt[a].orbit){let r=1.075+gt[a].dist/100;t.city.ptrait.includes("elliptical")&&(r="spc_home"===a?1.5:1.275+gt[a].dist/100),e*=r}return e}function xt(e){if(-2!==gt[e].orbit){let a=gt[e].dist/3;return t.city.ptrait.includes("elliptical")&&"spc_home"===e&&(a+=.15),"spc_eris"===e&&(a+=25),a}return 0}var kt,qt;function Mt(){let e=document.getElementById("mapCanvas"),a=e.getContext("2d");e.width=e.getBoundingClientRect().width,e.height=e.getBoundingClientRect().height,a.save(),a.fillStyle="#000000",a.fillRect(0,0,e.width,e.height),a.translate(qt.x,qt.y),a.scale(kt,kt);let r={};for(let[e,t]of Object.entries(gt))r[e]=vt(e);a.lineWidth=1/kt,a.strokeStyle="#c0c0c0";for(let[e,r]of Object.entries(gt))if(!r.moon&&-2!==r.orbit){a.beginPath(),r.belt||t.race.orbit_decayed&&"spc_home"===e?a.setLineDash([.01,.01]):a.setLineDash([]);let s=xt(e);a.ellipse(s,0,$t(r.dist,e),r.dist,0,0,2*Math.PI,!0),a.stroke()}a.fillStyle="#0000ff",a.strokeStyle="#0000ff";for(let e of t.space.shipyard.ships)e.transit>0&&(a.beginPath(),a.setLineDash([.1,.4]),a.moveTo(e.xy.x,e.xy.y),a.lineTo(e.destination.x,e.destination.y),a.stroke());for(let[e,s]of Object.entries(gt)){if(t.race.orbit_decayed&&["spc_home","spc_moon"].includes(e))continue;let i="558888";if(Qr.space[e]&&Qr.space[e].info.syndicate()&&t.settings.space[e.substring(4)]){let t=ht(e);i=((Math.round(255*(1-t))<<16)+(Math.round(255*t)<<8)).toString(16).padStart(6,0)}"spc_dwarf"===e?i="7132a8":"spc_sun"!==e&&"tauceti"!==e||(i="f8ff2b"),a.fillStyle="#"+i,a.beginPath();let c=s.size/10;if(s.moon)switch(e){case"spc_moon":a.arc(r[e].x+.05,r[e].y+.05,c,0,2*Math.PI,!0);break;case"spc_titan":a.arc(r[e].x-.2,r[e].y-.2,c,0,2*Math.PI,!0);break;default:a.arc(r[e].x+.2,r[e].y+.2,c,0,2*Math.PI,!0)}else{let t=s.size/10;a.arc(r[e].x,r[e].y,t,0,2*Math.PI,!0)}a.fill()}a.fillStyle="#0000ff",a.strokeStyle="#0000ff";for(let e of t.space.shipyard.ships)e.transit>0&&(a.beginPath(),a.arc(e.xy.x,e.xy.y,.1,0,2*Math.PI,!0),a.fill());a.shadowOffsetX=2,a.shadowOffsetY=2,a.shadowBlur=2,a.shadowColor="rgba(0, 0, 0, 0.5)",a.fillStyle="#009aff",a.font=20/kt+"px serif";for(let e of t.space.shipyard.ships)e.transit>0&&a.fillText(e.name,e.xy.x+.15,e.xy.y-.15);a.fillStyle="#ffa500",a.font=25/kt+"px serif";for(let[e,s]of Object.entries(gt))if(Qr.space[e]&&t.settings.space[e.substring(4)]){if(t.race.orbit_decayed&&["spc_home"].includes(e))continue;let i=Qr.space[e].info.name,c="function"==typeof i?i():i;if(s.moon)switch(e){case"spc_moon":a.fillText(c,r[e].x+.1,r[e].y+.1);break;case"spc_titan":a.fillText(c,r[e].x-.3,r[e].y-.3);break;default:a.fillText(c,r[e].x+.25,r[e].y+.2)}else"spc_sun"===e||a.fillText(c,r[e].x,r[e].y-.2*s.size)}a.restore()}function Pt(e){switch(e){case"city":return t.resource[t.race.species]?t.resource[t.race.species].amount<=5?F("tab_city1"):t.resource[t.race.species].amount<=20?F("tab_city2"):t.resource[t.race.species].amount<=75?F("tab_city3"):t.resource[t.race.species].amount<=250?F("tab_city4"):t.resource[t.race.species].amount<=600?F("tab_city5"):t.resource[t.race.species].amount<=1200?F("tab_city6"):t.resource[t.race.species].amount<=2500?F("tab_city7"):F("tab_city8"):F("tab_city1");case"local_space":return F("sol_system",[t.race.truepath?di[t.race.species].home:Ac("name")]);case"outer_local_space":return F("outer_sol_system",[t.race.truepath?di[t.race.species].home:Ac("name")]);case"old":return F("tab_old_res");case"new":return F("tab_new_res");case"old_sr":return F("tab_old_sr_res");case"new_sr":return F("tab_new_sr_res");default:return F(e)}}function Ot(){t.settings.tabLoad?(Ct("mTabCivil"),Ct("mTabCivic"),Ct("mTabResearch"),Ct("mTabResource"),Ct("mTabArpa"),Ct("mTabStats"),Ct("mTabObserve")):Ct(t.settings.civTabs)}function Ct(e){switch(t.settings.tabLoad?Zi("page_view",{page_title:"Evolve - All Tabs"}):(Gs(),ri(),za(),De(),L(),dt(),rc($("#mTabCivil")),rc($("#mTabCivic")),rc($("#mTabResearch")),rc($("#mTabResource")),rc($("#mTabArpa")),rc($("#mTabStats")),rc($("#mTabObserve"))),e){case 0:t.settings.tabLoad||(Zi("page_view",{page_title:"Evolve - Evolution"}),ts());break;case 1:case"mTabCivil":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Civilization"}),$("#mTabCivil").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),sc({el:"#mTabCivil",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(rc($("#city")),rc($("#space")),rc($("#interstellar")),rc($("#galaxy")),rc($("#portal")),rc($("#outerSol")),rc($("#tauCeti")),e){case 0:hs();break;case 1:case 2:case 3:case 5:Rt();break;case 4:$a();break;case 6:tt()}return e}},filters:{label:e=>Pt(e)}}),"protoplasm"!==t.race.species&&(hs(),Rt(),$a(),tt()),t.race.noexport&&("Race"===t.race.noexport?(rc($("#city")),ra()):"Planet"===t.race.noexport&&(rc($("#city")),sa()));break;case 2:case"mTabCivic":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Civics"}),$("#mTabCivic").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),sc({el:"#mTabCivic",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(ri(),L(),za(),dt(),rc($("#civic")),rc($("#industry")),rc($("#powerGrid")),rc($("#military")),rc($("#mechLab")),rc($("#dwarfShipYard")),rc($("#psychicPowers")),e){case 0:$("#civic").append($('
          ')),oa(),$("#civics").append($('
          ')),V(),"protoplasm"===t.race.species||t.race.start_cataclysm||(Y(),fe($("#c_garrison"),!1),se()),t.race.shapeshifter&&qi(!1,!0);break;case 1:Ws();break;case 2:Object.keys(ai()).forEach((function(e){Li(e)})),ti();break;case 3:"protoplasm"===t.race.species||t.race.start_cataclysm||(J(),ka($("#fortress"),!1));break;case 4:"protoplasm"===t.race.species||t.race.start_cataclysm||Sa();break;case 5:t.race.truepath&&"protoplasm"!==t.race.species&&!t.race.start_cataclysm&&at();break;case 6:t.race.psychic&&t.tech.psychic&&"protoplasm"!==t.race.species&&zi()}return e}},filters:{label:e=>Pt(e)}}),Object.keys(ai()).forEach((function(e){Li(e)})),ti(),$("#civic").append($('
          ')),oa(),$("#civics").append($('
          ')),V(),"protoplasm"===t.race.species||t.race.start_cataclysm||(J(),fe($("#c_garrison"),!1),ka($("#fortress"),!1),se(),Sa(),t.race.truepath&&at(),t.race.psychic&&t.tech.psychic&&zi()),t.race.shapeshifter&&qi(!1,!0),Ws();break;case 3:case"mTabResearch":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Research"}),$("#mTabResearch").append('
          \n \n \n \n \n \n \n \n '),sc({el:"#mTabResearch",data:{s:t.settings,rq:t.r_queue},filters:{label:e=>Pt(e)}}),Bs(),"protoplasm"!==t.race.species&&ms();break;case 4:case"mTabResource":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Resources"}),$("#mTabResource").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),sc({el:"#mTabResource",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(rc($("#market")),rc($("#resStorage")),rc($("#resEjector")),rc($("#resCargo")),rc($("#resAlchemy")),e){case 0:ar("market");break;case 1:ar("storage");break;case 2:ar("ejector");break;case 3:ar("supply");break;case 4:ar("alchemy")}return e}},filters:{label:e=>Pt(e)}}),tr(),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let r=a.resource[e].color,s=a.resource[e].tradable;if(a.resource[e].stackable){var i=$(`
          `);$("#resStorage").append(i),fr(`#stack-${e}`,i,e,r)}s&&(i=$(`
          `),$("#market").append(i),ur(`#market-${e}`,i,e,r,!0)),Va[e]&&Ar(e,r),Ja[e]&&Er(e,r),Za[e]&&"magic"===t.race.universe&&(t.resource[e].basic=s,Kr(e,r,s))})),sr();break;case 5:case"mTabArpa":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Arpa"}),$("#mTabArpa").append(`
          \n \n \n \n \n \n \n
          `),sc({el:"#mTabArpa",data:{s:t.settings},filters:{label:e=>Pt(e)}}),Oe("Physics"),Oe("Genetics"),Oe("Crispr"),Oe("Blood");break;case 6:case"mTabStats":t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Stats"}),$("#mTabStats").append('\n \n \n \n \n \n \n \n \n \n '),sc({el:"#mTabStats",data:{s:t.settings},filters:{label:e=>Pt(e)}}),function(){rc($("#achieve")),rc($("#stats"));let e=$('
          ');$("#stats").append(e);let a=$('
          ');$("#perks").append(a);let r=$('
          ');$("#achieve").append(r),function(){rc($("#statsPanel"));let e=$("#statsPanel");if(e.append(`
          ${F("achieve_stats_overall")}
          `),e.append(`
          ${F("achieve_stats_plasmid_earned")} {{ s.plasmid | format }}
          `),t.stats.antiplasmid>0&&e.append(`
          ${F("achieve_stats_antiplasmid_earned")} {{ s.antiplasmid | format }}
          `),t.stats.phage>0&&e.append(`
          ${F("achieve_stats_phage_earned")} {{ s.phage | format }}
          `),t.stats.dark>0&&e.append(`
          ${F("achieve_stats_dark_earned")} {{ s.dark | format }}
          `),t.stats.harmony>0&&e.append(`
          ${F("achieve_stats_harmony_earned")} {{ s.harmony | format }}
          `),t.stats.blood>0&&e.append(`
          ${F("achieve_stats_blood_earned")} {{ s.blood | format }}
          `),t.stats.artifact>0&&e.append(`
          ${F("achieve_stats_artifact_earned")} {{ s.artifact | format }}
          `),e.append(`
          ${F("achieve_stats_knowledge_spent")} {{ s.know | t_know | format }}
          `),e.append(`
          ${F("achieve_stats_starved_to_death")} {{ s.starved | t_starved | format }}
          `),e.append(`
          ${F("achieve_stats_died_in_combat")} {{ s.died | t_died | format }}
          `),e.append(`
          ${F("achieve_stats_game_days_played")} {{ s.days | played | format }}
          `),t.stats.portals>0&&e.append(`
          ${F("achieve_stats_portals")} {{ s.portals | format }}
          `),e.append(`
          ${F("achieve_stats_total_resets")} {{ s.reset | format }}
          `),t.stats.mad>0&&e.append(`
          ${F("achieve_stats_mad_resets")} {{ s.mad | format }}
          `),t.stats.bioseed>0&&e.append(`
          ${F("achieve_stats_bioseed_resets")} {{ s.bioseed | format }}
          `),t.stats.cataclysm>0&&e.append(`
          ${F("achieve_stats_cataclysm_resets")} {{ s.cataclysm | format }}
          `),t.stats.blackhole>0&&e.append(`
          ${F("achieve_stats_blackhole_resets")} {{ s.blackhole | format }}
          `),t.stats.ascend>0&&e.append(`
          ${F("achieve_stats_ascension_resets")} {{ s.ascend | format }}
          `),t.stats.descend>0&&e.append(`
          ${F("achieve_stats_descension_resets")} {{ s.descend | format }}
          `),t.stats.aiappoc>0&&e.append(`
          ${F("achieve_stats_aiappoc_resets")} {{ s.aiappoc | format }}
          `),t.stats.matrix>0&&e.append(`
          ${F("achieve_stats_matrix_resets")} {{ s.matrix | format }}
          `),t.stats.retire>0&&e.append(`
          ${F("achieve_stats_retire_resets")} {{ s.retire | format }}
          `),t.stats.eden>0&&e.append(`
          ${F("achieve_stats_eden_resets")} {{ s.eden | format }}
          `),t.stats.terraform>0&&e.append(`
          ${F("achieve_stats_terraform_resets")} {{ s.terraform | format }}
          `),t.stats.geck>0&&e.append(`
          ${F("achieve_stats_gecks")} {{ s.geck | format }}
          `),e.append(`
          ${F("achieve_stats_current_game")}
          `),e.append(`
          ${F("achieve_stats_knowledge_spent")} {{ s.know | format }}
          `),e.append(`
          ${F("achieve_stats_starved_to_death")} {{ s.starved | format }}
          `),e.append(`
          ${F("achieve_stats_died_in_combat")} {{ s.died | format }}
          `),e.append(`
          ${F("achieve_stats_attacks_made")} {{ s.attacks | format }}
          `),e.append(`
          ${F("achieve_stats_game_days_played")} {{ s.days | format }}
          `),t.stats.dkills>0&&e.append(`
          ${F("achieve_stats_demons_kills")} {{ s.dkills | format }}
          `),t.stats.sac>0&&e.append(`
          ${F("achieve_stats_sacrificed")} {{ s.sac | format }}
          `),t.stats.murders>0&&e.append(`
          ${F("achieve_stats_murders")} {{ s.murders | format }}
          `),t.stats.psykill>0&&e.append(`
          ${F("achieve_stats_psymurders")} {{ s.psykill | format }}
          `),t.resource.hasOwnProperty("Thermite")&&t.resource.Thermite.amount>0&&e.append(`
          ${F("achieve_stats_thermite")} {{ r.Thermite.amount | res }}
          `),Ic().active){let a="";(t.stats.cfood>=13||t.race.cataclysm||t.race.orbit_decayed)&&(a=`${kc(7,12,!0)}`),e.append(`
          ${F("achieve_stats_trickortreat")} {{ s.cfood | format }} ${a}
          `)}sc({el:"#statsPanel",data:{s:t.stats,r:t.resource},filters:{played:e=>e+t.stats.tdays,t_know:e=>e+t.stats.tknow,t_starved:e=>e+t.stats.tstarved,t_died:e=>e+t.stats.tdied,format:e=>e.toLocaleString(),res:e=>(+e.toFixed(2)).toLocaleString()}})}(),no(),$("body").hasClass("fool")?to({fool:!0}):to()}();break;case 7:t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Settings"});break;default:t.settings.tabLoad||Zi("page_view",{page_title:"Evolve - Hell Observation"}),t.portal.observe&&Ga(!0)}$("#popper").length>0&&0===$(`#${$("#popper").data("id")}`).length&&Ei()}const jt={spc_home:{info:{name:()=>di[t.race.species].home,desc:F("space_home_info_desc"),zone:"inner",syndicate:()=>!1},test_launch:{id:"space-test_launch",title:F("space_home_test_launch_title"),desc:F("space_home_test_launch_desc"),reqs:{space:1},grant:["space",2],queue_complete:()=>t.tech.space>=2?0:1,cost:{Money:()=>1e5,Oil:(e,t)=>Jt(7500,!1,t)},effect:F("space_home_test_launch_effect"),action(){if(Os($(this)[0])){if(t.race.truepath){let e=1;if(ue("gov0")||e++,ue("gov1")||e++,ue("gov2")||e++,0!==Math.floor(m(0,e)))return Di(F("space_home_test_launch_action_fail"),"danger",!1,["progress"]),0}return t.space.satellite={count:0},Di(F("space_home_test_launch_action"),"info",!1,["progress"]),!0}return!1}},satellite:{id:"space-satellite",title:F("space_home_satellite_title"),desc:F("space_home_satellite_desc"),reqs:{space:2},cost:{Money:e=>Xi("satellite",e,72e3,1.22),Knowledge:e=>Xi("satellite",e,28e3,1.22),Oil:(e,t)=>Xi("satellite",e,Jt(3200,!1,t),1.22),Alloy:e=>Xi("satellite",e,8e3,1.22)},effect(){let e=t.race.cataclysm||t.race.orbit_decayed?2e3:750;if((t.race.cataclysm||t.race.orbit_decayed)&&t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?5:10;e*=t.tech.supercollider/a+1}let a=t.race.cataclysm?F("space_moon_observatory_title"):t.race.orbit_decayed?F("city_university"):Ts(),r=`
          ${F("space_home_satellite_effect2",[a,t.race.cataclysm?25:t.race.orbit_decayed?12:4])}
          `;return`
          ${F("plus_max_resource",[e,F("resource_Knowledge_name")])}
          ${r}
          ${F("space_home_satellite_effect3",[t.civic.scientist?t.civic.scientist.name:F("job_scientist")])}
          `},action(){return!!Os($(this)[0])&&(Nt("satellite"),t.resource.Knowledge.max+=750,!0)}},gps:{id:"space-gps",title:F("space_home_gps_title"),desc:()=>t.space.hasOwnProperty("gps")&&t.space.gps.count<4?`
          ${F("space_home_gps_desc")}
          ${F("space_home_gps_desc_req")}
          `:`
          ${F("space_home_gps_desc")}
          `,reqs:{satellite:1},not_trait:["terrifying"],cost:{Money:e=>Xi("gps",e,75e3,1.18),Knowledge:e=>Xi("gps",e,5e4,1.18),Copper:e=>Xi("gps",e,6500,1.18),Oil:(e,t)=>Xi("gps",e,Jt(3500,!1,t),1.18),Titanium:e=>Xi("gps",e,8e3,1.18)},effect:e=>(e||0)+(t.space.hasOwnProperty("gps")?t.space.gps.count:0)<4?F("space_home_gps_effect_req"):`
          ${F("space_home_gps_effect")}
          ${F("space_home_gps_effect2",[2])}
          `,action(){return!!Os($(this)[0])&&(Nt("gps"),!0)}},propellant_depot:{id:"space-propellant_depot",title:F("space_home_propellant_depot_title"),desc:F("space_home_propellant_depot_desc"),reqs:{space_explore:1},cost:{Money:e=>Xi("propellant_depot",e,55e3,1.35),Aluminium:e=>Xi("propellant_depot",e,22e3,1.35),Oil:(e,t)=>Xi("propellant_depot",e,Jt(5500,!1,t),1.35)},effect(){let e=Lr(1250)*(t.tech.world_control?1.5:1);if(t.resource.Helium_3.display){let a=Lr(1e3)*(t.tech.world_control?1.5:1);return`
          ${F("plus_max_resource",[e,F("resource_Oil_name")])}
          ${F("plus_max_resource",[a,F("resource_Helium_3_name")])}
          `}return`
          ${F("plus_max_resource",[e,F("resource_Oil_name")])}
          `},action(){return!!Os($(this)[0])&&(Nt("propellant_depot"),t.resource.Oil.max+=Lr(1250)*(t.tech.world_control?1.5:1),t.resource.Helium_3.display&&(t.resource.Helium_3.max+=Lr(1e3)*(t.tech.world_control?1.5:1)),!0)}},nav_beacon:{id:"space-nav_beacon",title:()=>t.race.orbit_decayed?F("space_home_broadcast_beacon_title"):F("space_home_nav_beacon_title"),desc:`
          ${F("space_home_nav_beacon_desc")}
          ${F("requires_power")}
          `,reqs:{luna:2},cost:{Money:e=>Xi("nav_beacon",e,75e3,1.32),Copper:e=>Xi("nav_beacon",e,38e3,1.32),Aluminium:e=>Xi("nav_beacon",e,44e3,1.32),Oil:(e,t)=>Xi("nav_beacon",e,Jt(12500,!1,t),1.32),Iridium:e=>Xi("nav_beacon",e,1200,1.32)},powered:()=>oc(2),powerBalancer:()=>t.tech.luna&&t.tech.luna>=3?[{s:t.space.moon_base.s_max-t.space.moon_base.support},{s:t.space.spaceport.s_max-t.space.spaceport.support}]:[{s:t.space.moon_base.s_max-t.space.moon_base.support}],support:()=>1,effect(){let e="";return t.race.orbit_decayed&&t.tech.broadcast&&(e=`
          ${F("space_red_vr_center_effect1",[t.tech.broadcast/2])}
          `),`${t.race.orbit_decayed?"":`
          ${F("space_home_nav_beacon_effect1")}
          `}${t.tech.luna>=3?`
          ${F("space_red_spaceport_effect1",[Xt().red,1])}
          `:""}${e}
          ${F("space_home_nav_beacon_effect2",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("nav_beacon"),xs($(this)[0]),!0)}}},spc_moon:{info:{name:F("space_moon_info_name"),desc:()=>F("space_moon_info_desc",[di[t.race.species].home]),support:"moon_base",zone:"inner",syndicate:()=>!0},moon_mission:{id:"space-moon_mission",title:F("space_moon_mission_title"),desc:F("space_moon_mission_desc"),reqs:{space:2,space_explore:2},grant:["space",3],queue_complete:()=>t.tech.space>=3?0:1,cost:{Oil:(e,t)=>+Jt(12e3,!1,t).toFixed(0)},effect:F("space_moon_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("space_moon_mission_action"),"info",!1,["progress"]),t.space.iridium_mine={count:0,on:0},t.space.helium_mine={count:0,on:0},!0)}},moon_base:{id:"space-moon_base",title:F("space_moon_base_title"),desc:()=>`
          ${F("space_moon_base_desc")}
          ${F("requires_power_combo",[t.resource.Oil.name])}
          `,reqs:{space:3},cost:{Money:e=>Xi("moon_base",e,22e3,1.32),Cement:e=>Xi("moon_base",e,18e3,1.32),Alloy:e=>Xi("moon_base",e,7800,1.32),Polymer:e=>Xi("moon_base",e,12500,1.32)},effect(e){let t=Lr(500),a=+Jt($(this)[0].support_fuel().a,!0,e).toFixed(2);return`
          ${F("space_moon_base_effect1")}
          ${F("plus_max_resource",[t,F("resource_Iridium_name")])}
          ${F("space_moon_base_effect3",[a,$(this)[0].powered()])}
          `},support:()=>2,support_fuel:()=>({r:"Oil",a:2}),powered:()=>oc(4),powerBalancer:()=>[{s:t.space.moon_base.s_max-t.space.moon_base.support}],refresh:!0,action(){if(Os($(this)[0])){if(Nt("moon_base"),xs($(this)[0]),1===t.space.moon_base.count&&(t.tech.moon=1),!t.tech.luna&&(t.tech.luna=1,t.race.truepath)){let e=F("space_moon_base_msg",[ee(3)]);t.civic.foreign.gov3.hstl<10?e=`${e} ${F("space_moon_base_msg_ally")}`:t.civic.foreign.gov3.hstl>60&&(e=`${e} ${F("space_moon_base_msg_hstl")}`),Di(e,"info",!1,["progress"])}return t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+2500&&(t.race.orbit_decay=t.stats.days+2500,Di(F("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0}return!1}},iridium_mine:{id:"space-iridium_mine",title:F("space_moon_iridium_mine_title"),desc:`
          ${F("space_moon_iridium_mine_desc")}
          ${F("space_support",[F("space_moon_info_name")])}
          `,reqs:{space:3,luna:1},cost:{Money:e=>Xi("iridium_mine",e,42e3,1.35),Lumber:e=>Xi("iridium_mine",e,9e3,1.35),Titanium:e=>Xi("iridium_mine",e,17500,1.35)},effect(){let e=Pe("iridium_mine","iridium"),a=+e.b.toFixed(3),r="";t.race.truepath&&(t.civic.foreign.gov3.hstl<10?r=`
          ${F("space_rival_ally",[+(100*e.g).toFixed(1)])}
          `:t.civic.foreign.gov3.hstl>60&&(r=`
          ${F("space_rival_war",[+(100*e.g).toFixed(1)])}
          `));let s=t.race.cataclysm?`
          ${F("produce",[+Pe("iridium_mine","coal").toFixed(2),t.resource.Coal.name])}
          `:"",i=t.race.cataclysm?`
          ${F("produce",[+(Pe("iridium_mine","coal")/48).toFixed(3),t.resource.Uranium.name])}
          `:"";return`
          ${F("space_used_support",[F("space_moon_info_name")])}
          ${F("space_moon_iridium_mine_effect",[a])}
          ${r}${s}${i}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.resource.Iridium.display=!0,Nt("iridium_mine"),t.resource.Mythril.display||(t.resource.Mythril.display=!0,ha()),t.space.moon_base.support${F("space_moon_helium_mine_desc")}
          ${F("space_support",[F("space_moon_info_name")])}
          `,reqs:{space:3,luna:1},cost:{Money:e=>Xi("helium_mine",e,38e3,1.35),Aluminium:e=>Xi("helium_mine",e,9e3,1.35),Steel:e=>Xi("helium_mine",e,17500,1.35)},effect(){let e=Lr(100),a=Pe("helium_mine"),r=+a.b.toFixed(3),s="";return t.race.truepath&&(t.civic.foreign.gov3.hstl<10?s=`
          ${F("space_rival_ally",[+(100*a.g).toFixed(1)])}
          `:t.civic.foreign.gov3.hstl>60&&(s=`
          ${F("space_rival_war",[+(100*a.g).toFixed(1)])}
          `)),`
          ${F("space_used_support",[F("space_moon_info_name")])}
          ${F("space_moon_helium_mine_effect",[r])}
          ${s}
          ${F("plus_max_resource",[e,F("resource_Helium_3_name")])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.resource.Helium_3.display=!0,Nt("helium_mine"),t.space.moon_base.support${F("space_moon_observatory_desc")}
          ${F("space_support",[F("space_moon_info_name")])}
          `,reqs:{science:9,luna:1},cost:{Money:e=>Xi("observatory",e,2e5,1.28),Knowledge:e=>Xi("observatory",e,69e3,1.28),Stone:e=>Xi("observatory",e,125e3,1.28),Iron:e=>Xi("observatory",e,65e3,1.28),Iridium:e=>Xi("observatory",e,1250,1.28)},effect(){let e="";t.race.cataclysm&&(e=`
          ${F("city_university_effect",[la(1)])}
          `);let a=5e3;t.race.cataclysm&&t.space.satellite&&t.space.satellite.count>0&&(a*=1+.25*t.space.satellite.count);let r=t.race.cataclysm?`
          ${F("space_moon_observatory_cata_effect",[25])}
          `:`
          ${F("space_moon_observatory_effect",[5])}
          `;return`
          ${F("space_used_support",[F("space_moon_info_name")])}
          ${e}
          ${F("plus_max_resource",[a,F("resource_Knowledge_name")])}
          ${r}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("observatory"),t.space.moon_base.supportXt().red,desc:()=>F("space_red_info_desc",[Xt().red]),support:"spaceport",zone:"inner",syndicate:()=>!0},red_mission:{id:"space-red_mission",title:()=>F("space_mission_title",[Xt().red]),desc:()=>F("space_mission_desc",[Xt().red]),reqs:{space:3,space_explore:3},grant:["space",4],queue_complete:()=>t.tech.space>=4?0:1,cost:{Helium_3:(e,t)=>+Jt(4500,!1,t).toFixed(0)},effect:()=>F("space_red_mission_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(Di(F("space_red_mission_action",[Xt().red]),"info",!1,["progress"]),t.space.living_quarters={count:0,on:0},t.space.garage={count:0},t.space.red_mine={count:0,on:0},t.space.fabrication={count:0,on:0},!0)}},spaceport:{id:"space-spaceport",title:F("space_red_spaceport_title"),desc:()=>`
          ${F("space_red_spaceport_desc")}
          ${F("requires_power_space",[t.resource.Food.name])}
          `,reqs:{space:4},cost:{Money:e=>Xi("spaceport",e,47500,1.32),Iridium:e=>Xi("spaceport",e,1750,1.32),Mythril:e=>Xi("spaceport",e,25,1.32),Titanium:e=>Xi("spaceport",e,22500,1.32)},effect(e){let a=+Jt($(this)[0].support_fuel().a,!0,e).toFixed(2),r="";return(t.race.cataclysm||t.race.orbit_decayed)&&(r=`
          ${F("plus_max_resource",[`$${Lr(4*Hs())}`,F("resource_Money_name")])}
          `),`
          ${F("space_red_spaceport_effect1",[Xt().red,$(this)[0].support()])}
          ${r}
          ${F("space_red_spaceport_effect2",[a,$(this)[0].powered()])}
          ${F("spend",[t.race.cataclysm?2:25,t.resource.Food.name])}
          `},support(){let e=t.race.cataclysm||t.race.orbit_decayed?4:3;return t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=4&&e++,e},support_fuel:()=>({r:"Helium_3",a:1.25}),powered:()=>oc(5),powerBalancer:()=>[{s:t.space.spaceport.s_max-t.space.spaceport.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("spaceport"),xs($(this)[0]),t.tech.mars||(t.tech.mars=1),t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+1e3&&(t.race.orbit_decay=t.stats.days+1e3,Di(F("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0)}},red_tower:{id:"space-red_tower",title:F("space_red_tower_title"),desc:()=>`
          ${F("space_red_tower_desc")}
          ${F("requires_power")}
          `,reqs:{mars:3},cost:{Money:e=>Xi("red_tower",e,225e3,1.28),Iron:e=>Xi("red_tower",e,22e3,1.28),Cement:e=>Xi("red_tower",e,15e3,1.28),Alloy:e=>Xi("red_tower",e,8e3,1.28)},effect(){return`
          ${F("space_red_spaceport_effect1",[Xt().red,t.race.cataclysm?2:1])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(2),powerBalancer:()=>[{s:t.space.spaceport.s_max-t.space.spaceport.support}],support:()=>t.race.cataclysm?2:1,action(){return!!Os($(this)[0])&&(Nt("red_tower"),xs($(this)[0]),!0)}},captive_housing:Vr("captive_housing","space"),terraformer:{id:"space-terraformer",title:F("space_terraformer"),desc:e=>!t.space.hasOwnProperty("terraformer")||t.space.terraformer.count<100||e?`
          ${F("space_terraformer")}
          ${F("requires_segmemts",[100])}
          `+(t.space.hasOwnProperty("terraformer")&&t.space.terraformer.count>=100?`
          ${F("requires_power")}
          `:""):`
          ${F("space_terraformer")}
          `,reqs:{terraforming:1},condition:()=>!(t.space.terraformer.count>=100),queue_size:5,queue_complete:()=>100-t.space.terraformer.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?75e5:75e6:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?25e4:75e4:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?1e3:0,Bolognium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:1e5:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?12e3:25e4:0,Soul_Gem:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:1:0,Nanoweave:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:75e3:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100&&t.race.truepath?75e3:0,Cipher:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100&&t.race.truepath?1e3:0},effect(e){let a=(e?e.count:0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0);if(a<100){let e=100-a;return`
          ${F("space_terraformer_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          `}return jt.spc_red.atmo_terraformer.effect(e)},action(){return!!(Os($(this)[0])&&t.space.terraformer.count<100)&&(Nt("terraformer","space"),t.space.terraformer.count>=100&&(t.tech.terraforming=2,t.space.atmo_terraformer={count:1,on:0},Rt(),Ei()),!0)}},atmo_terraformer:{id:"space-atmo_terraformer",title:F("space_terraformer"),desc:()=>`
          ${F("space_terraformer")}
          ${F("requires_power")}
          `,wiki:!1,reqs:{terraforming:2},condition:()=>t.space.terraformer.count>=100,queue_complete:()=>0,cost:{},powered:e=>oc((e?e.truepath:t.race.truepath)?500:5e3),postPower(e){e?setTimeout((function(){t.tech.terraforming=i.atmo_terraformer?3:2,Rt()}),250):(t.tech.terraforming=2,Rt())},effect(e){let t=zt(),a=$(this)[0].powered(e),r=a>0?`
          ${F("minus_power",[a])}
          `:"";return`
          ${F("space_terraformer_effect2")}
          ${t}${r}`},action:()=>!1},terraform:{id:"space-terraform",title:F("space_terraform"),desc:F("space_terraform"),reqs:{terraforming:3},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=zt();return`
          ${F("space_terraform_effect")}
          ${e}`},action(){return!!Os($(this)[0])&&(sa(),!0)}},assembly:Vr("assembly","space"),living_quarters:{id:"space-living_quarters",title:F("space_red_living_quarters_title"),desc:()=>`
          ${F("space_red_living_quarters_desc")}
          ${F("space_support",[Xt().red])}
          `,reqs:{mars:1},cost:{Money:e=>Xi("living_quarters",e,Qt(38e3),1.28),Steel:e=>Xi("living_quarters",e,Qt(15e3),1.28),Polymer:e=>Xi("living_quarters",e,Qt(9500),1.28),Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens(),a="";return(t.race.cataclysm||t.race.orbit_decayed)&&(a=`
          ${F("plus_max_resource",[`$${Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?"100000":"50000":"25000")}`,F("resource_Money_name")])}
          `),`
          ${F("space_used_support",[Xt().red])}
          ${a}
          ${F("plus_max_resource",[la(1),t.race.truepath?F("job_colonist_tp",[Xt().red]):F("colonist")])}
          ${F("plus_max_resource",[e,F("citizen")])}
          `},support:()=>-1,powered:()=>oc(1),action(){if(Os($(this)[0])){if(Nt("living_quarters"),t.civic.colonist.display=!0,t.space.spaceport.support0)){let e=t.civic[t.civic.d_job].workers-la(1)<0?t.civic[t.civic.d_job].workers:la(1);t.civic[t.civic.d_job].workers-=e,t.civic.colonist.workers+=e}return!0}return!1},citizens(){let e=t.race.cataclysm||t.race.orbit_decayed?2:1;return c.biodome&&(e+=(t.tech.mars>=6?.1:.05)*c.biodome),+la(e).toFixed(2)}},pylon:{id:"space-pylon",title:F("space_red_pylon"),desc:F("space_red_pylon"),reqs:{magic:2},condition:()=>!(!t.race.cataclysm&&!t.race.orbit_decayed),cost:{Money:e=>Xi("pylon",e,10,1.48),Stone:e=>Xi("pylon",e,12,1.42),Crystal:e=>Xi("pylon",e,8,1.42)-3},effect(){let e=Lr(2);return`
          ${F("gain",[+(.005*nc("magic")).toFixed(3),t.resource.Mana.name])}
          ${F("plus_max_resource",[e,t.resource.Mana.name])}
          `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!Os($(this)[0])&&(t.space.pylon.count++,t.resource.Mana.max+=Lr(2),!0)}},vr_center:{id:"space-vr_center",title:F("space_red_vr_center_title"),desc:()=>`
          ${F("space_red_vr_center_desc")}
          ${F("space_support",[Xt().red])}
          `,reqs:{mars:1,broadcast:3},cost:{Money:e=>Xi("vr_center",e,38e4,1.25),Copper:e=>Xi("vr_center",e,55e3,1.25),Stanene:e=>Xi("vr_center",e,1e5,1.25),Soul_Gem:e=>Xi("vr_center",e,1,1.25)},effect(){let e=N("gaslighter",1),a=e?e+1:1;return t.race.orbit_decayed&&(a+=2),`
          ${F("space_used_support",[Xt().red])}
          ${F("space_red_vr_center_effect1",[a])}
          ${F("space_red_vr_center_effect2",[2])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("vr_center"),t.space.spaceport.support`
          ${F("space_red_garage_desc")}
          `,reqs:{mars:1},cost:{Money:e=>Xi("garage",e,75e3,1.28),Iron:e=>Xi("garage",e,12e3,1.28),Brick:e=>Xi("garage",e,3e3,1.28),Sheet_Metal:e=>Xi("garage",e,1500,1.28)},wide:!0,res(){let e=["Copper","Iron","Cement","Steel","Titanium","Alloy","Nano_Tube","Neutronium","Infernite"];return(t.race.cataclysm||t.race.orbit_decayed)&&(e.push("Polymer"),e.push("Coal"),e.push("Lumber"),e.push("Chrysotile"),e.push("Stone"),e.push("Furs")),e},heavy:e=>!!["Copper","Iron","Steel","Titanium","Neutronium","Infernite"].includes(e),val(e){switch(e){case"Copper":return 6500;case"Iron":return 5500;case"Cement":return t.race.cataclysm?10500:6e3;case"Steel":return 4500;case"Titanium":return 3500;case"Alloy":case"Polymer":return 2500;case"Nano_Tube":return 25e3;case"Neutronium":return 125;case"Infernite":return 75;case"Coal":return 1500;case"Lumber":case"Chrysotile":case"Stone":return 7500;case"Furs":return 2200;default:return 0}},multiplier(e){let a=t.tech.particles>=4?1+t.tech.supercollider/20:1;return(t.tech.world_control||t.race.cataclysm||t.race.orbit_decayed)&&(a*=2),t.tech.shelving&&t.tech.shelving>=3&&(a*=1.5),a*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,e&&t.tech.shelving&&t.tech.shelving>=2?3*a:a},effect(){let e=$(this)[0].multiplier(!1),a=$(this)[0].multiplier(!0),r=t.tech.particles>=4?20+t.tech.supercollider:20;(t.tech.world_control||t.race.cataclysm||t.race.orbit_decayed)&&(r+=10);let s=t.race.cataclysm||t.race.orbit_decayed?`${F("plus_max_resource",[r,F("resource_Crates_name")])}`:"",i='
          ';i+=`${F("plus_max_resource",[r,F("resource_Containers_name")])}${s}`;for(const r of $(this)[0].res())if(t.resource[r].display){let s=$(this)[0].heavy(r);i+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(r))*(s?a:e)).toFixed(0),1),t.resource[r].name])}`}return i+="
          ",i},action(){if(Os($(this)[0])){Nt("garage");let e=$(this)[0].multiplier(!1),a=$(this)[0].multiplier(!0);for(const r of $(this)[0].res())if(t.resource[r].display){let s=$(this)[0].heavy(r);t.resource[r].max+=Lr($(this)[0].val(r))*(s?a:e)}return!0}return!1}},red_mine:{id:"space-red_mine",title:F("space_red_mine_title"),desc:()=>`
          ${F("space_red_mine_desc")}
          ${F("space_support",[Xt().red])}
          `,reqs:{mars:1},cost:{Money:e=>Xi("red_mine",e,5e4,1.32),Lumber:e=>Xi("red_mine",e,65e3,1.32),Iron:e=>Xi("red_mine",e,33e3,1.32)},effect(){let e=Pe("red_mine","copper"),a=Pe("red_mine","titanium"),r=+e.b.toFixed(3),s=+a.b.toFixed(3),i="";t.race.truepath&&(t.civic.foreign.gov3.hstl<10?i=`
          ${F("space_rival_ally",[+(100*e.g).toFixed(1)])}
          `:t.civic.foreign.gov3.hstl>60&&(i=`
          ${F("space_rival_war",[+(100*e.g).toFixed(1)])}
          `));let c=t.race.orbit_decayed?`
          ${F("city_mine_effect1",[la(1)])}
          ${F("city_coal_mine_effect1",[la(1)])}
          `:"",o=t.race.cataclysm||t.race.orbit_decayed&&!t.race.sappy?`
          ${F("space_red_mine_effect",[+Pe("red_mine","stone").toFixed(2),t.resource.Stone.name])}
          `:"",n=t.race.cataclysm||t.race.orbit_decayed&&t.race.smoldering?`
          ${F("space_red_mine_effect",[+Pe("red_mine","asbestos").toFixed(2),t.resource.Chrysotile.name])}
          `:"",l=t.race.cataclysm||t.race.orbit_decayed?`
          ${F("space_red_mine_effect",[+Pe("red_mine","aluminium").toFixed(2),t.resource.Aluminium.name])}
          `:"";return`
          ${F("space_used_support",[Xt().red])}
          ${c}
          ${F("space_red_mine_effect",[r,t.resource.Copper.name])}
          ${F("space_red_mine_effect",[s,t.resource.Titanium.name])}
          ${i}${n}${o}${l}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("red_mine"),t.space.spaceport.support`
          ${F("space_red_fabrication_desc")}
          ${F("space_support",[Xt().red])}
          `,reqs:{mars:1},cost:{Money:e=>Xi("fabrication",e,9e4,1.32),Copper:e=>Xi("fabrication",e,25e3,1.32),Cement:e=>Xi("fabrication",e,12e3,1.32),Wrought_Iron:e=>Xi("fabrication",e,1200,1.32)},effect(){let e=t.race.cataclysm&&!t.race.flier?`
          ${F("city_cement_plant_effect1",[la(1)])}
          `:"",a=t.race.cataclysm||t.race.orbit_decayed?5:2;return t.race.high_pop&&(a=Me(a)),`
          ${F("space_used_support",[Xt().red])}
          ${F("space_red_fabrication_effect1",[la(1)])}
          ${e}
          ${F("space_red_fabrication_effect2",[a])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("fabrication"),t.space.spaceport.support`
          ${F("space_red_factory_desc")}
          ${F("requires_power_combo",[t.resource.Helium_3.name])}
          `,reqs:{mars:4},cost:{Money:e=>Xi("red_factory",e,75e3,1.32),Brick:e=>Xi("red_factory",e,1e4,1.32),Coal:e=>Xi("red_factory",e,7500,1.32),Mythril:e=>Xi("red_factory",e,50,1.32)},effect(e){let a=`
          ${F("space_red_factory_effect1")}
          `;return t.tech.foundry>=7&&(a+=`
          ${F("space_red_factory_effect2")}
          `),t.race.orbit_decayed&&!t.race.flier&&(a+=`
          ${F("city_cement_plant_effect1",[la(1)])}
          `),a+=`
          ${F("space_red_factory_effect3",[+Jt(1,!0,e).toFixed(2),$(this)[0].powered()])}
          `,a},powered:()=>oc(3),special:!0,action(){return!!Os($(this)[0])&&(t.space.red_factory.count++,xs($(this)[0])&&t.city.factory.Alloy++,t.settings.showIndustry=!0,Ws(),!0)}},nanite_factory:Vr("nanite_factory","space"),biodome:{id:"space-biodome",title:()=>t.race.artifical?F("space_red_signal_tower_title"):t.race.soul_eater?F("space_red_asphodel_title"):F("space_red_biodome_title"),desc(){let e;return e=t.race.artifical?`
          ${F("space_red_signal_tower_title")}
          `:t.race.soul_eater?`
          ${F("space_red_asphodel_desc")}
          `:t.race.carnivore?`
          ${F("space_red_biodome_desc_carn")}
          `:`
          ${F("space_red_biodome_desc",[Xt().red])}
          `,`
          ${e}
          ${F("space_support",[Xt().red])}
          `},reqs:{mars:2},cost:{Money:e=>Xi("biodome",e,45e3,1.28),Lumber:e=>Xi("biodome",e,65e3,1.28),Brick:e=>Xi("biodome",e,1e3,1.28),Nanite:e=>t.race.deconstructor?Xi("biodome",e,75,1.28):0},effect(){let e=+Pe("biodome","food").toFixed(2),a=t.race.cataclysm||t.race.orbit_decayed?`
          ${F("produce",[+Pe("biodome","cat_food").toFixed(2),t.resource.Food.name])}
          `:"",r=!t.race.cataclysm&&!t.race.orbit_decayed||t.race.kindling_kindred?"":`
          ${F("space_red_mine_effect",[+Pe("biodome","lumber").toFixed(2),t.resource.Lumber.name])}
          `,s=t.tech.mars>=6?.1:.05,i=t.race.artifical?F("city_transmitter_effect",[Lr(500)]):F("plus_max_resource",[Lr(100),F("resource_Food_name")]),c=t.race.artifical||t.race.orbit_decayed?`
          ${i}${F("space_used_support",[Xt().red])}
          ${a}
          ${F("space_red_biodome_effect",[e,t.resource.Food.name])}
          ${F("space_red_biodome_effect2",[+la(s).toFixed(2)])}
          ${r}${c}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("biodome"),t.race.cataclysm||(Xc("colonist"),t.race.joyless&&(Xc("joyless"),delete t.race.joyless,ms())),t.space.spaceport.supportt.race.artifical?F("space_red_signal_tower_flair"):t.race.soul_eater?F("space_red_asphodel_flair"):t.race.carnivore?F("space_red_biodome_flair_carn"):F("space_red_biodome_flair")},red_university:{id:"space-red_university",title:F("city_university"),desc:()=>F("city_university_desc",[Xt().red]),reqs:{mars:1},trait:["orbit_decayed"],cost:{Money:e=>Xi("university",e,900,1.5,"city")-500,Lumber:e=>Xi("university",e,500,1.36,"city")-200,Stone:e=>Xi("university",e,750,1.36,"city")-350,Crystal:e=>"magic"===t.race.universe?Xi("university",e,5,1.36,"city"):0},wiki:!1,effect:()=>Qr.city.university.effect(),action(){if(Os($(this)[0])){let e=t.tech.science&&t.tech.science>=8?700:500;if(t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,t.city.university.count++,t.space.red_university.count=t.city.university.count,t.civic.professor.display=!0,t.civic.professor.max=t.city.university.count,!0}return!1}},exotic_lab:{id:"space-exotic_lab",title:F("space_red_exotic_lab_title"),desc:()=>`
          ${F("space_red_exotic_lab_desc")}
          ${F("space_support",[Xt().red])}
          `,reqs:{mars:5},cost:{Money:e=>Xi("exotic_lab",e,75e4,1.28),Steel:e=>Xi("exotic_lab",e,1e5,1.28),Mythril:e=>Xi("exotic_lab",e,1e3,1.28),Elerium:e=>Xi("exotic_lab",e,20,1.28)-4},effect(){let e=500;t.tech.science>=13&&t.interstellar.laboratory&&o.laboratory&&(e+=25*o.laboratory),t.tech.ancient_study&&t.tech.ancient_study>=2&&(e+=15*t.space.ziggurat.count),t.tech.mass>=2&&i.mass_driver&&(e+=Me(i.mass_driver*t.civic.scientist.workers)),t.tech.science>=21&&(e*=1.45),t.race.high_pop&&(e=Me(e));let a=Lr(10),r="",s="";return(t.race.cataclysm||t.race.orbit_decayed)&&(r=`
          ${F("city_wardenclyffe_effect1",[la(1),t.civic.scientist.name])}
          `,e*=1+.25*c.observatory,t.tech.science>=15&&(s=`
          ${F("city_wardenclyffe_effect4",[2])}
          `)),`
          ${F("space_used_support",[Xt().red])}
          ${r}${s}
          ${F("space_red_exotic_lab_effect1",[+e.toFixed(0)])}
          ${F("plus_max_resource",[a,F("resource_Elerium_name")])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("exotic_lab"),t.space.spaceport.support`
          ${F("space_red_exotic_lab_flair1")}
          ${F("space_red_exotic_lab_flair2")}
          `},ziggurat:{id:"space-ziggurat",title:F("space_red_ziggurat_title"),desc:()=>`
          ${F("space_red_ziggurat_desc",["none"!==t.race.old_gods?di[t.race.old_gods.toLowerCase()].entity:di[t.race.species].entity])}
          `,reqs:{theology:4},cost:{Money:e=>Xi("ziggurat",e,6e5,1.28),Stone:e=>Xi("ziggurat",e,25e4,1.28),Aluminium:e=>Xi("ziggurat",e,7e4,1.28),Mythril:e=>Xi("ziggurat",e,250,1.28)},effect(){let e=t.tech.ancient_study?.6:.4;if(t.tech.ancient_deify&&t.tech.ancient_deify>=2&&c.exotic_lab&&(e+=.01*c.exotic_lab),"theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let a=.002;t.race.high_pop&&(a=Me(a)),e+=a*t.civic.priest.workers}t.race.ooze&&(e*=1-ui.ooze.vars()[1]/100),t.race.high_pop&&(e=Me(e)),e=+e.toFixed(2);let a=t.race.truepath?[e,di[t.race.species].home]:[e],r=`
          ${F(t.race.truepath?"space_red_ziggurat_effect_tp":"space_red_ziggurat_effect",a)}
          `;return t.tech.ancient_study&&t.tech.ancient_study>=2&&(r+=`
          ${F("interstellar_laboratory_effect",[3])}
          `),(t.race.cataclysm||t.race.orbit_decayed)&&(r+=rs()),t.genes.ancients&&t.genes.ancients>=4&&(r+=`
          ${F("city_temple_effect6",[la(1)])}
          `),r},action(){return!!Os($(this)[0])&&(Nt("ziggurat"),t.genes.ancients&&t.genes.ancients>=4&&(t.civic.priest.display=!0),t.race.cataclysm&&Xc("iron_will",!1,1),!0)}},space_barracks:{id:"space-space_barracks",title:F("space_red_space_barracks_title"),desc:()=>`
          ${F("space_red_space_barracks_desc")}
          ${F("space_red_space_barracks_desc_req")}
          `,reqs:{marines:1},cost:{Money:e=>Xi("space_barracks",e,35e4,1.28),Alloy:e=>Xi("space_barracks",e,65e3,1.28),Iridium:e=>Xi("space_barracks",e,22500,1.28),Wrought_Iron:e=>Xi("space_barracks",e,12500,1.28),Horseshoe:()=>t.race.hooved?2:0},effect(e){let a=t.race.orbit_decayed?Qr.city.boot_camp.effect():"",r=+Jt(2,!0,e).toFixed(2),s=t.tech.marines>=2?la(4):la(2),i=t.race.cataclysm?"":`
          ${F("space_red_space_barracks_effect3",[t.resource.Food.name])}
          `;return`
          ${F("plus_max_soldiers",[s])}
          ${a}
          ${F("space_red_space_barracks_effect2",[r])}
          ${i}`},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("space_barracks"),t.space.space_barracks.on++,!0)},flair:()=>F("space_red_space_barracks_flair")},bonfire:Vr("bonfire","space"),horseshoe:Vr("horseshoe","space")},spc_hell:{info:{name:()=>Xt().hell,desc:()=>F("space_hell_info_desc",[Xt().hell]),zone:"inner",syndicate:()=>!1},hell_mission:{id:"space-hell_mission",title:()=>F("space_mission_title",[Xt().hell]),desc:()=>F("space_mission_desc",[Xt().hell]),reqs:{space:3,space_explore:3},grant:["hell",1],queue_complete:()=>t.tech.hell>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(6500,!1,t).toFixed(0)},effect:()=>F("space_hell_mission_effect1",[Xt().hell]),action(){return!!Os($(this)[0])&&(Di(F("space_hell_mission_action",[Xt().hell]),"info",!1,["progress"]),t.space.geothermal={count:0,on:0},!0)}},geothermal:{id:"space-geothermal",title:F("space_hell_geothermal_title"),desc:()=>`
          ${F("space_hell_geothermal_desc")}
          ${F("space_hell_geothermal_desc_req")}
          `,reqs:{hell:1},cost:{Money:e=>Xi("geothermal",e,38e3,1.35),Steel:e=>Xi("geothermal",e,15e3,1.35),Polymer:e=>Xi("geothermal",e,9500,1.35)},effect(e){let a=+Jt($(this)[0].p_fuel().a,!0,e).toFixed(2);return`${t.race.cataclysm||t.race.orbit_decayed?`
          ${F("interstellar_stellar_forge_effect3",[1])}
          `:""}${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${F("space_belt_station_effect3",[a])}`},special:()=>!(!t.race.cataclysm&&!t.race.orbit_decayed),powered(){let e=-8;return t.race.forge&&(e-=ui.forge.vars()[0]),t.stats.achieve.failed_history&&t.stats.achieve.failed_history.l>=5&&(e-=2),cc(e)},p_fuel:()=>({r:"Helium_3",a:.5}),action(){return!!Os($(this)[0])&&(Nt("geothermal"),t.space.geothermal.on++,!0)}},hell_smelter:{id:"space-hell_smelter",title:()=>F("space_hell_smelter_title",[Xt().hell]),desc:()=>F("space_hell_smelter_title",[Xt().hell]),reqs:{hell:1,m_smelting:1},path:["truepath"],cost:{Money:e=>Xi("hell_smelter",e,25e4,1.24),Adamantite:e=>Xi("hell_smelter",e,15e3,1.24)},effect:()=>`
          ${F("interstellar_stellar_forge_effect3",[2])}
          `,special:!0,action(){return!!Os($(this)[0])&&(Nt("hell_smelter"),t.city.smelter.cap+=2,t.city.smelter.Steel+=2,t.city.smelter.Oil+=2,!0)}},spc_casino:{id:"space-spc_casino",title:F("city_casino"),desc:F("city_casino"),category:"commercial",reqs:{hell:1,gambling:1},condition:()=>!!(t.race.cataclysm||t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=5),cost:{Money:e=>Xi("spc_casino",e,4e5,1.35),Furs:e=>Xi("spc_casino",e,75e3,1.35),Cement:e=>Xi("spc_casino",e,1e5,1.35),Plywood:e=>Xi("spc_casino",e,2e4,1.35)},effect(){let e=ss();return e+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,e},powered:()=>oc(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2?2:3),action(){return!!Os($(this)[0])&&(t.space.spc_casino.count++,t.race.joyless||(t.civic.entertainer.max+=la(1),t.civic.entertainer.display=!0),xs($(this)[0]),!0)},flair:F("city_casino_flair")},swarm_plant:{id:"space-swarm_plant",title:F("space_hell_swarm_plant_title"),desc:()=>`
          ${F("space_hell_swarm_plant_desc")}
          `,reqs:{solar:4,hell:1},cost:{Money:e=>Xi("swarm_plant",e,Zt(75e3),1.28),Iron:e=>Xi("swarm_plant",e,Zt(65e3),1.28),Neutronium:e=>Xi("swarm_plant",e,Zt(75),1.28),Brick:e=>Xi("swarm_plant",e,Zt(2500),1.28),Mythril:e=>Xi("swarm_plant",e,Zt(100),1.28)},effect(){let e=t.tech.swarm?.88:.94;return t.tech.swarm>=3&&(e-=u/100),e<.05&&(e=.05),e=+(100*(1-e)).toFixed(2),F("space_hell_swarm_plant_effect1",[e])},action(){return!!Os($(this)[0])&&(Nt("swarm_plant"),!0)}},firework:Vr("firework","space")},spc_sun:{info:{name:()=>F("space_sun_info_name"),desc:()=>F("space_sun_info_desc",[di[t.race.species].home]),support:"swarm_control",zone:"inner",syndicate:()=>!1},sun_mission:{id:"space-sun_mission",title:()=>F("space_sun_mission_title"),desc:()=>F("space_sun_mission_desc"),reqs:{space_explore:4},grant:["solar",1],queue_complete:()=>t.tech.solar>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(15e3,!1,t).toFixed(0)},effect:()=>F("space_sun_mission_effect1"),action(){return!!Os($(this)[0])}},swarm_control:{id:"space-swarm_control",title:F("space_sun_swarm_control_title"),desc:()=>`
          ${F("space_sun_swarm_control_desc")}
          `,reqs:{solar:3},cost:{Money:e=>Xi("swarm_control",e,1e5,1.3),Knowledge:e=>Xi("swarm_control",e,6e4,1.3),Alloy:e=>Xi("swarm_control",e,7500,1.3),Helium_3:(e,t)=>Xi("swarm_control",e,Jt(2e3,!1,t),1.3),Mythril:e=>Xi("swarm_control",e,250,1.3)},effect(){return F("space_sun_swarm_control_effect1",[$(this)[0].support()])},support:()=>t.tech.swarm&&t.tech.swarm>=2?t.tech.high_tech>=11?11+Math.round(u):12:10,action(){return!!Os($(this)[0])&&(Nt("swarm_control"),t.space.swarm_control.s_max+=$(this)[0].support(),!0)}},swarm_satellite:{id:"space-swarm_satellite",title:F("space_sun_swarm_satellite_title"),desc:()=>`
          ${F("space_sun_swarm_satellite_desc")}
          ${F("space_sun_swarm_satellite_desc_req")}
          `,reqs:{solar:3},cost:{Money:e=>Xi("swarm_satellite",e,Vt(5e3),1.1),Copper:e=>Xi("swarm_satellite",e,Vt(2500),1.1),Iridium:e=>Xi("swarm_satellite",e,Vt(150),1.1),Helium_3:(e,t)=>Xi("swarm_satellite",e,Vt(Jt(50,!1,t)),1.1)},effect(){let e=.35;return t.tech.swarm>=4&&(e+=.15*(t.tech.swarm-3)),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1&&(e+=.15),t.blood.illuminate&&(e+=.01*t.blood.illuminate),e=+e.toFixed(2),`${F("space_dwarf_reactor_effect1",[cc(e)])}, ${F("space_sun_swarm_satellite_effect1",[1])}`},support:()=>-1,action(){return!!Os($(this)[0])&&(Nt("swarm_satellite"),t.space.swarm_control.support++,!0)}},jump_gate:{id:"space-jump_gate",title:F("tau_jump_gate"),desc:e=>!t.space.hasOwnProperty("jump_gate")||t.space.jump_gate.count<100||e?`
          ${F("tau_jump_gate")}
          ${F("requires_segmemts",[100])}
          `:`
          ${F("tau_jump_gate")}
          `,reqs:{tauceti:3},path:["truepath"],queue_size:10,queue_complete:()=>100-t.space.jump_gate.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?1e6:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?5e4:0,Adamantite:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?12500:0,Graphene:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?42e3:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?35e3:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?25e3:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0);if(a<100){let e=100-a;return`
          ${F("tau_jump_gate_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          `}return F("tau_jump_gate_effect")},action(){return!!(Os($(this)[0])&&t.space.jump_gate.count<100)&&(t.space.jump_gate.count++,!0)}}},spc_gas:{info:{name:()=>Xt().gas,desc:()=>F("space_gas_info_desc",[Xt().gas,di[t.race.species].home]),zone:"outer",syndicate:()=>!0},gas_mission:{id:"space-gas_mission",title:()=>F("space_mission_title",[Xt().gas]),desc:()=>F("space_mission_desc",[Xt().gas]),reqs:{space:4,space_explore:4},grant:["space",5],queue_complete:()=>t.tech.space>=5?0:1,cost:{Helium_3:(e,t)=>+Jt(12500,!1,t).toFixed(0)},effect:()=>F("space_gas_mission_effect",[Xt().gas]),action(){return!!Os($(this)[0])&&(Di(F("space_gas_mission_action",[Xt().gas]),"info",!1,["progress"]),t.settings.space.gas_moon=!0,t.settings.space.belt=!0,t.space.space_station={count:0,on:0,support:0,s_max:0},!0)}},gas_mining:{id:"space-gas_mining",title:F("space_gas_mining_title"),desc:()=>`
          ${F("space_gas_mining_desc")}
          ${F("requires_power")}
          `,reqs:{gas_giant:1},cost:{Money:e=>Xi("gas_mining",e,25e4,1.32),Uranium:e=>Xi("gas_mining",e,500,1.32),Alloy:e=>Xi("gas_mining",e,1e4,1.32),Helium_3:(e,t)=>Xi("gas_mining",e,Jt(2500,!1,t),1.32),Mythril:e=>Xi("gas_mining",e,25,1.32)},effect(){return`
          ${F("space_gas_mining_effect1",[+Pe("gas_mining").toFixed(2)])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(2),action(){return!!Os($(this)[0])&&(Nt("gas_mining"),xs($(this)[0]),!0)}},gas_storage:{id:"space-gas_storage",title:()=>F("space_gas_storage_title",[Xt().gas]),desc:()=>`
          ${F("space_gas_storage_desc")}
          `,reqs:{gas_giant:1},cost:{Money:e=>Xi("gas_storage",e,125e3,1.32),Iridium:e=>Xi("gas_storage",e,3e3,1.32),Sheet_Metal:e=>Xi("gas_storage",e,2e3,1.32),Helium_3:(e,t)=>Xi("gas_storage",e,Jt(1e3,!1,t),1.32)},effect(){let e=Lr(3500)*(t.tech.world_control?1.5:1),a=Lr(2500)*(t.tech.world_control?1.5:1),r=Lr(1e3)*(t.tech.world_control?1.5:1);return`
          ${F("plus_max_resource",[e,F("resource_Oil_name")])}
          ${F("plus_max_resource",[a,F("resource_Helium_3_name")])}
          ${F("plus_max_resource",[r,F("resource_Uranium_name")])}
          `},action(){return!!Os($(this)[0])&&(Nt("gas_storage"),!0)}},star_dock:{id:"space-star_dock",title:()=>F("space_gas_star_dock_title"),desc:()=>`
          ${F("space_gas_star_dock_title")}
          ${F("space_gas_star_dock_desc_req")}
          `,reqs:{genesis:3},queue_complete:()=>1-t.space.star_dock.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?15e5:0,Steel:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?5e5:0,Helium_3:(e,a)=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?Math.round(Jt(1e4,!1,a)):0,Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?25e4:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?1e4:0},effect:()=>`
          ${F("space_gas_star_dock_effect1")}
          `,special:!0,action(){return!(0!==t.space.star_dock.count||!Os($(this)[0])||(Nt("star_dock"),0))}}},spc_gas_moon:{info:{name:()=>Xt().gas_moon,desc:()=>F("space_gas_moon_info_desc",[Xt().gas_moon,Xt().gas]),zone:"outer",syndicate:()=>!0},gas_moon_mission:{id:"space-gas_moon_mission",title:()=>F("space_mission_title",[Xt().gas_moon]),desc:()=>F("space_mission_desc",[Xt().gas_moon]),reqs:{space:5},grant:["space",6],queue_complete:()=>t.tech.space>=6?0:1,cost:{Helium_3:(e,t)=>+Jt(3e4,!1,t).toFixed(0)},effect:()=>F("space_gas_moon_mission_effect",[Xt().gas_moon]),action(){return!!Os($(this)[0])&&(Di(F("space_gas_moon_mission_action",[Xt().gas_moon]),"info",!1,["progress"]),t.space.outpost={count:0,on:0},t.tech.gas_moon=1,!0)}},outpost:{id:"space-outpost",title:F("space_gas_moon_outpost_title"),desc:()=>`
          ${F("space_gas_moon_outpost_desc")}
          ${F("requires_power_combo",[t.resource.Oil.name])}
          `,reqs:{gas_moon:1},cost:{Money:e=>Xi("outpost",e,666e3,1.3),Titanium:e=>Xi("outpost",e,18e3,1.3),Iridium:e=>Xi("outpost",e,2500,1.3),Helium_3:(e,t)=>Xi("outpost",e,Jt(6e3,!1,t),1.3),Mythril:e=>Xi("outpost",e,300,1.3)},effect(e){let t=+Pe("outpost").toFixed(3),a=Lr(500),r=+Jt(2,!0,e).toFixed(2);return`
          ${F("space_gas_moon_outpost_effect1",[t])}
          ${F("plus_max_resource",[a,F("resource_Neutronium_name")])}
          ${F("space_gas_moon_outpost_effect3",[r,$(this)[0].powered()])}
          `},powered:()=>oc(3),powerBalancer:()=>[{r:"Neutronium",k:"lpmod"}],action(){return!!Os($(this)[0])&&(Nt("outpost"),t.resource.Neutronium.display=!0,xs($(this)[0]),!0)}},drone:{id:"space-drone",title:F("space_gas_moon_drone_title"),desc:()=>`
          ${F("space_gas_moon_drone_desc")}
          `,reqs:{gas_moon:1,drone:1},cost:{Money:e=>Xi("drone",e,25e4,1.3),Steel:e=>Xi("drone",e,2e4,1.3),Neutronium:e=>Xi("drone",e,500,1.3),Elerium:e=>Xi("drone",e,25,1.3),Nano_Tube:e=>Xi("drone",e,45e3,1.3)},effect:()=>`
          ${F("space_gas_moon_drone_effect1",[t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3?12:6])}
          `,action(){return!!Os($(this)[0])&&(Nt("drone"),!0)}},oil_extractor:{id:"space-oil_extractor",title:F("space_gas_moon_oil_extractor_title"),desc:()=>`
          ${F("space_gas_moon_oil_extractor_title")}
          ${F("requires_power")}
          `,reqs:{gas_moon:2},cost:{Money:e=>Xi("oil_extractor",e,666e3,1.3),Polymer:e=>Xi("oil_extractor",e,7500,1.3),Helium_3:(e,t)=>Xi("oil_extractor",e,Jt(2500,!1,t),1.3),Wrought_Iron:e=>Xi("oil_extractor",e,5e3,1.3)},effect(){return`${F("space_gas_moon_oil_extractor_effect1",[+Pe("oil_extractor").toFixed(2)])}, ${F("minus_power",[$(this)[0].powered()])}`},powered:()=>oc(1),powerBalancer:()=>[{r:"Oil",k:"lpmod"}],action(){return!!Os($(this)[0])&&(Nt("oil_extractor"),xs($(this)[0]),!0)}}},spc_belt:{info:{name:()=>F("space_belt_info_name"),desc:()=>t.space.space_station&&t.space.space_station.count>0?`
          ${F("space_belt_info_desc",[Xt().red,Xt().gas])}
          ${F("space_belt_info_desc2")}
          `:F("space_belt_info_desc",[Xt().red,Xt().gas]),support:"space_station",zone:"inner",syndicate:()=>!0},belt_mission:{id:"space-belt_mission",title:()=>F("space_belt_mission_title"),desc:()=>F("space_belt_mission_desc"),reqs:{space:5},grant:["asteroid",1],queue_complete:()=>t.tech.asteroid>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(25e3,!1,t).toFixed(0)},effect:()=>F("space_belt_mission_effect1"),action(){return!!Os($(this)[0])&&(Di(F("space_belt_mission_action"),"info",!1,["progress"]),t.settings.space.dwarf=!0,!0)}},space_station:{id:"space-space_station",title:F("space_belt_station_title"),desc:()=>`
          ${F("space_belt_station_desc")}
          ${F("requires_power_space",[t.resource.Food.name])}
          `,reqs:{asteroid:2},cost:{Money:e=>Xi("space_station",e,25e4,1.3),Iron:e=>Xi("space_station",e,85e3,1.3),Polymer:e=>Xi("space_station",e,18e3,1.3),Iridium:e=>Xi("space_station",e,2800,1.28),Helium_3:(e,t)=>Xi("space_station",e,Jt(2e3,!1,t),1.3),Mythril:e=>Xi("space_station",e,75,1.25)},effect(e){let a=+Jt(2.5,!0,e).toFixed(2),r=t.race.cataclysm?1:10,s=Lr(5),i=t.tech.asteroid>=5?`
          ${F("plus_max_resource",[s,F("resource_Elerium_name")])}
          `:"";return`
          ${F("plus_max_space_miners",[la(3)])}
          ${i}
          ${F("space_belt_station_effect3",[a])}
          ${F("space_belt_station_effect4",[r,$(this)[0].powered(),t.resource.Food.name])}
          `},support:()=>la(3),powered:()=>oc(3),refresh:!0,action(){if(Os($(this)[0])){if(Nt("space_station"),t.civic.space_miner.display=!0,t.tech.asteroid<3&&(t.tech.asteroid=3),xs($(this)[0])&&t.civic[t.civic.d_job].workers>0){let e=la(3);t.civic[t.civic.d_job].workers-e<0&&(e=t.civic[t.civic.d_job].workers),t.civic[t.civic.d_job].workers-=e,t.civic.space_miner.workers+=e}return t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+1e3&&(t.race.orbit_decay=t.stats.days+1e3,Di(F("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0}return!1}},elerium_ship:{id:"space-elerium_ship",title:F("space_belt_elerium_ship_title"),desc:()=>F("space_belt_elerium_ship_title"),reqs:{asteroid:5},cost:{Money:e=>Xi("elerium_ship",e,5e5,1.3),Uranium:e=>Xi("elerium_ship",e,2500,1.3),Titanium:e=>Xi("elerium_ship",e,1e4,1.3),Mythril:e=>Xi("elerium_ship",e,500,1.3),Helium_3:(e,t)=>Xi("elerium_ship",e,Jt(5e3,!1,t),1.3)},effect(){let e=+Pe("elerium_ship").toFixed(4);return`
          ${F("space_belt_elerium_ship_effect1",[la(2)])}
          ${F("space_belt_elerium_ship_effect2",[e])}
          `},support:()=>la(-2),powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("elerium_ship"),t.space.space_station.support+1F("space_belt_iridium_ship_title"),reqs:{asteroid:3},cost:{Money:e=>Xi("iridium_ship",e,12e4,1.3),Uranium:e=>Xi("iridium_ship",e,1e3,1.3),Alloy:e=>Xi("iridium_ship",e,48e3,1.3),Iridium:e=>Xi("iridium_ship",e,2800,1.3),Helium_3:(e,t)=>Xi("iridium_ship",e,Jt(1800,!1,t),1.3)},effect(){let e=+Pe("iridium_ship").toFixed(3);return`
          ${F("space_belt_iridium_ship_effect1",[la(1)])}
          ${F("space_belt_iridium_ship_effect2",[e])}
          `},support:()=>la(-1),powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("iridium_ship"),t.space.space_station.supportF("space_belt_iron_ship_title"),reqs:{asteroid:3},cost:{Money:e=>Xi("iron_ship",e,8e4,1.3),Steel:e=>Xi("iron_ship",e,42e3,1.3),Aluminium:e=>Xi("iron_ship",e,38e3,1.3),Polymer:e=>Xi("iron_ship",e,16e3,1.3),Helium_3:(e,t)=>Xi("iron_ship",e,Jt(1200,!1,t),1.3)},effect(){let e=+Pe("iron_ship").toFixed(2);return t.tech.solar&&t.tech.solar>=5?`
          ${F("space_belt_iron_ship_effect1",[la(1)])}
          ${F("space_belt_iron_ship_effect2",[e])}
          ${F("space_belt_iron_ship_effect3")}
          `:`
          ${F("space_belt_iron_ship_effect1",[la(1)])}
          ${F("space_belt_iron_ship_effect2",[e])}
          `},support:()=>la(-1),powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("iron_ship"),t.space.space_station.supportXt().dwarf,desc:()=>F("space_dwarf_info_desc",[Xt().dwarf]),zone:"inner",syndicate:()=>!1},dwarf_mission:{id:"space-dwarf_mission",title:()=>F("space_mission_title",[Xt().dwarf]),desc:()=>F("space_mission_desc",[Xt().dwarf]),reqs:{asteroid:1,elerium:1},grant:["dwarf",1],queue_complete:()=>t.tech.dwarf>=1?0:1,cost:{Helium_3:(e,t)=>+Jt(45e3,!1,t).toFixed(0)},effect:()=>F("space_dwarf_mission_effect1",[Xt().dwarf]),action(){return!!Os($(this)[0])&&(Di(F("space_dwarf_mission_action",[Xt().dwarf]),"info",!1,["progress"]),t.space.elerium_contain={count:0,on:0},!0)}},elerium_contain:{id:"space-elerium_contain",title:F("space_dwarf_elerium_contain_title"),desc:()=>`
          ${F("space_dwarf_elerium_contain_title")}
          ${F("requires_power")}
          `,reqs:{dwarf:1},cost:{Money:e=>Xi("elerium_contain",e,8e5,1.28),Cement:e=>Xi("elerium_contain",e,12e4,1.28),Iridium:e=>Xi("elerium_contain",e,5e4,1.28),Neutronium:e=>Xi("elerium_contain",e,250,1.28)},effect(){return`
          ${F("plus_max_resource",[Lr(100),F("resource_Elerium_name")])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(6),action(){return!!Os($(this)[0])&&(Nt("elerium_contain"),xs($(this)[0]),!0)}},e_reactor:{id:"space-e_reactor",title:F("space_dwarf_reactor_title"),desc:()=>`
          ${F("space_dwarf_reactor_title")}
          ${F("space_dwarf_reactor_desc_req")}
          `,reqs:{elerium:2},cost:{Money:e=>Xi("e_reactor",e,125e4,1.28),Steel:e=>Xi("e_reactor",e,35e4,1.28),Neutronium:e=>Xi("e_reactor",e,1250,1.28),Mythril:e=>Xi("e_reactor",e,2500,1.28)},effect(){let e=$(this)[0].p_fuel().a;return`
          ${F("space_dwarf_reactor_effect1",[-1*$(this)[0].powered()])}
          ${F("space_dwarf_reactor_effect2",[e])}
          `},powered:()=>cc(-25),p_fuel:()=>({r:"Elerium",a:.05}),action(){return!!Os($(this)[0])&&(Nt("e_reactor"),t.space.e_reactor.on++,!0)}},world_collider:{id:"space-world_collider",title:F("space_dwarf_collider_title"),desc(e){if(!t.space.hasOwnProperty("world_collider")||t.space.world_collider.count<1859||e)return`
          ${F("space_dwarf_collider_desc")}
          ${F("space_dwarf_collider_desc_req")}
          `+(t.space.hasOwnProperty("world_collider")&&t.space.world_collider.count>=1859?`
          ${F("requires_power")}
          `:"")},reqs:{science:10},path:["standard"],condition:()=>t.space.world_collider.count<1859,queue_size:100,queue_complete:()=>1859-t.space.world_collider.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?25e3:0,Copper:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?750:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?125:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?12:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?1:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?10:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0);if(a<1859){let e=1859-a;return`
          ${F("space_dwarf_collider_effect1")}
          ${F("space_dwarf_collider_effect2",[e])}
          `}return jt.spc_dwarf.world_controller.effect()},action(){if(t.space.world_collider.count<1859&&Os($(this)[0])){if(Nt("world_collider"),t.space.world_collider.count>=1859){if(t.tech.science=11,t.space.world_controller={count:1,on:0},ms(),Rt(),t.race.banana){let e=Yc();t.stats.banana.b2[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b2.l=!0)}Ei()}return!0}return!1},flair:F("space_dwarf_collider_flair")},world_controller:{id:"space-world_controller",title:F("space_dwarf_collider_title"),desc:()=>`
          ${F("space_dwarf_collider_title")}
          ${F("requires_power")}
          `,wiki:!1,reqs:{science:11},path:["standard"],condition:()=>!(t.space.world_collider.count<1859),queue_complete:()=>0,cost:{},effect(){let e=25;return t.interstellar.far_reach&&i.far_reach>0&&(e+=1*i.far_reach),t.tech.science>=19&&(e+=15),`
          ${F("plus_max_resource",[e+"%",F("resource_Knowledge_name")])}
          ${F("space_dwarf_controller_effect3")}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(20),action:()=>!1,flair:F("space_dwarf_controller_flair")},shipyard:{id:"space-shipyard",title:F("outer_shipyard_title"),desc:()=>`
          ${F("outer_shipyard_title")}
          ${F("requires_power")}
          `,reqs:{shipyard:1},path:["truepath"],cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e7:0,Aluminium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e6:0,Titanium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?65e4:0,Iridium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?25e4:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e4:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?5e5:0},queue_complete:()=>1-t.space.shipyard.count,effect(){return`
          ${F("outer_shipyard_effect")}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(50),special:!0,sAction(){i.shipyard&&(t.settings.civTabs=2,t.settings.govTabs=5,t.settings.tabLoad||(Ct("mTabCivic"),Ei("space-shipyard")))},action(){return!!(t.space.shipyard.count<1&&Os($(this)[0]))&&(Nt("shipyard"),xs($(this)[0])&&(t.settings.showShipYard=!0),t.tech.syard_class=2,t.tech.syard_armor=3,t.tech.syard_weapon=1,t.tech.syard_engine=2,t.tech.syard_power=3,t.tech.syard_sensor=3,!0)}},mass_relay:{id:"space-mass_relay",title:F("space_dwarf_mass_relay_title"),desc(e){if(!t.space.hasOwnProperty("mass_relay")||t.space.mass_relay.count<100||e)return`
          ${F("space_dwarf_mass_relay_title")}
          ${F("requires_segmemts",[100])}
          `},reqs:{outer:5},path:["truepath"],condition:()=>t.space.mass_relay.count<100,queue_size:5,queue_complete:()=>100-t.space.mass_relay.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?1e7:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?7500:0,Adamantite:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?18e3:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?125:0,Stanene:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?1e5:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?25e3:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0);if(a<100){let e=100-a;return`
          ${F("space_dwarf_mass_relay_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          `}return jt.spc_dwarf.m_relay.effect()},action(){return!!(t.space.mass_relay.count<100&&Os($(this)[0]))&&(t.space.mass_relay.count++,t.space.mass_relay.count>=100&&(t.tech.outer=6,t.space.m_relay={count:1,on:1,charged:0},ms(),Rt(),Ei()),!0)}},m_relay:{id:"space-m_relay",title:F("space_dwarf_mass_relay_title"),desc:()=>`
          ${F("space_dwarf_mass_relay_title")}
          ${F("requires_power")}
          `,reqs:{outer:6},path:["truepath"],condition:()=>t.space.mass_relay.count>=100,wiki:!1,queue_complete:()=>0,cost:{},powered:()=>oc(100),effect(){let e=Math.floor(t.space.m_relay.charged/10)/10;return`
          ${F("space_dwarf_mass_relay_effect2",[Xt().dwarf])}
          ${F("minus_power",[$(this)[0].powered()])}
          ${F("space_dwarf_mass_relay_charged",[e])}
          `},action:()=>!1}},spc_titan:Xe().spc_titan,spc_enceladus:Xe().spc_enceladus,spc_triton:Xe().spc_triton,spc_kuiper:Xe().spc_kuiper,spc_eris:Xe().spc_eris},St={int_alpha:{info:{name:F("interstellar_alpha_name"),desc:()=>t.tech.alpha?F("interstellar_alpha_desc2",[di[t.race.species].home]):F("interstellar_alpha_desc1",[di[t.race.species].home]),support:"starport"},alpha_mission:{id:"interstellar-alpha_mission",title:F("space_mission_title",[F("interstellar_alpha_name")]),desc:F("space_mission_desc",[F("interstellar_alpha_name")]),reqs:{ftl:2},grant:["alpha",1],queue_complete:()=>t.tech.alpha>=1?0:1,cost:{Helium_3:()=>+Yt(4e4).toFixed(0)},effect:F("interstellar_alpha_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("interstellar_alpha_mission_result"),"info",!1,["progress"]),t.interstellar.nexus={count:0,on:0,support:0,s_max:0},t.interstellar.warehouse={count:0},!0)}},starport:{id:"interstellar-starport",title:F("interstellar_alpha_starport_title"),desc:()=>`
          ${F("interstellar_alpha_starport_desc")}
          ${F("requires_power_space",[t.resource.Food.name])}
          `,reqs:{alpha:1},cost:{Money:e=>Xi("starport",e,1e6,1.3,"interstellar"),Aluminium:e=>Xi("starport",e,4e5,1.3,"interstellar"),Neutronium:e=>Xi("starport",e,1e3,1.3,"interstellar"),Elerium:e=>Xi("starport",e,100,1.3,"interstellar")},effect(){let e=+Yt(5).toFixed(2);return`
          ${F("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
          ${F("interstellar_alpha_starport_effect2",[e,$(this)[0].powered()])}
          ${F("interstellar_alpha_starport_effect3",[100,t.resource.Food.name])}
          `},support:()=>5,powered:()=>oc(10),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("starport","interstellar"),t.settings.space.proxima=!0,t.settings.space.nebula=!0,xs($(this)[0]),1===t.tech.alpha&&(t.tech.alpha=2,t.interstellar.mining_droid={count:0,on:0,adam:0,uran:0,coal:0,alum:0}),t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+100&&(t.race.orbit_decay=t.stats.days+100,Di(F("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0)}},habitat:{id:"interstellar-habitat",title:F("interstellar_habitat_title"),desc:`
          ${F("interstellar_habitat_desc")}
          ${F("requires_power")}
          `,reqs:{alpha:3},cost:{Money:e=>Xi("habitat",e,8e5,1.25,"interstellar"),Furs:e=>Xi("habitat",e,38e3,1.25,"interstellar"),Adamantite:e=>Xi("habitat",e,3200,1.25,"interstellar"),Plywood:e=>Xi("habitat",e,1e4,1.25,"interstellar"),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return`
          ${F("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
          ${F("plus_max_citizens",[e])}, ${F("minus_power",[$(this)[0].powered()])}
          `},support:()=>1,powered:()=>oc(2),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],action(){return!!Os($(this)[0])&&(Nt("habitat","interstellar"),xs($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens()),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},mining_droid:{id:"interstellar-mining_droid",title:F("interstellar_mining_droid_title"),desc:`
          ${F("interstellar_mining_droid_title")}
          ${F("space_support",[F("interstellar_alpha_name")])}
          `,reqs:{alpha:2},cost:{Money:e=>Xi("mining_droid",e,65e4,1.28,"interstellar"),Steel:e=>Xi("mining_droid",e,12e4,1.28,"interstellar"),Nano_Tube:e=>Xi("mining_droid",e,75e3,1.28,"interstellar"),Elerium:e=>Xi("mining_droid",e,50,1.28,"interstellar")},effect:()=>`
          ${F("space_used_support",[F("interstellar_alpha_name")])}
          ${F("interstellar_mining_droid_effect")}
          `,support:()=>-1,powered:()=>oc(1),special:!0,refresh:!0,action(){return!!Os($(this)[0])&&(Nt("mining_droid","interstellar"),t.resource.Adamantite.display=!0,t.interstellar.starport.support${F("interstellar_processing_title")}
          ${F("space_support",[F("interstellar_alpha_name")])}
          `,reqs:{droids:1},cost:{Money:e=>Xi("processing",e,35e4,1.28,"interstellar"),Iron:e=>Xi("processing",e,18e4,1.28,"interstellar"),Aluminium:e=>Xi("processing",e,6e4,1.28,"interstellar"),Iridium:e=>Xi("processing",e,5e3,1.28,"interstellar")},effect(){let e=12;return t.tech.ai_core&&t.tech.ai_core>=2&&i.citadel>0&&(e+=2*i.citadel),`
          ${F("space_used_support",[F("interstellar_alpha_name")])}
          ${F("interstellar_processing_effect",[e])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("processing","interstellar"),t.interstellar.starport.support`
          ${F("interstellar_fusion_title")}
          ${F("requires_power_support_combo",[F("interstellar_alpha_name"),t.resource.Deuterium.name])}
          `,reqs:{fusion:1},cost:{Money:e=>Xi("fusion",e,99e4,1.28,"interstellar"),Iridium:e=>Xi("fusion",e,44e3,1.28,"interstellar"),Infernite:e=>Xi("fusion",e,350,1.28,"interstellar"),Brick:e=>Xi("fusion",e,18e3,1.28,"interstellar")},effect(){return`
          ${F("space_used_support",[F("interstellar_alpha_name")])}
          ${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${F("interstellar_fusion_effect",[1.25])}
          `},support:()=>-1,powered:()=>cc(-22),p_fuel:()=>({r:"Deuterium",a:1.25}),action(){return!!Os($(this)[0])&&(Nt("fusion","interstellar"),t.interstellar.starport.support"magic"===t.race.universe?F("tech_sanctum"):F("interstellar_laboratory_title"),desc:`
          ${F("magic"===t.race.universe?"tech_sanctum":"interstellar_laboratory_title")}
          ${F("space_support",[F("interstellar_alpha_name")])}
          `,reqs:{science:12},cost:{Money:e=>Xi("laboratory",e,75e4,1.28,"interstellar"),Crystal:e=>"magic"===t.race.universe?Xi("laboratory",e,1200,1.28,"interstellar"):0,Titanium:e=>Xi("laboratory",e,12e4,1.28,"interstellar"),Alloy:e=>Xi("laboratory",e,95e3,1.28,"interstellar"),Mythril:e=>Xi("laboratory",e,8500,1.28,"interstellar")},effect(){let e=1e4;t.tech.science>=15&&(e*=1+.02*(t.race.cataclysm||t.race.orbit_decayed?c.exotic_lab:t.city.wardenclyffe.count)),(t.race.cataclysm||t.race.orbit_decayed&&i.s_gate&&n.scavenger)&&(e*=1+n.scavenger*+(.75*Et("gxy_alien2")).toFixed(1)),t.tech.science>=21&&(e*=1.45),e=Math.round(e);let a="";t.tech.science>=16&&(a=`
          ${F("city_wardenclyffe_effect1",[la(1),t.civic.scientist.name])}
          `);let r=`
          ${F("space_used_support",[F("interstellar_alpha_name")])}
          ${a}
          ${F("city_max_knowledge",[e])}
          `;return t.tech.science>=13&&(r+=`
          ${F("interstellar_laboratory_effect",[5])}
          `),"magic"===t.race.universe&&(r+=`
          ${F("plus_max_resource",[Lr(12),t.resource.Mana.name])}
          `),r},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("laboratory","interstellar"),t.interstellar.starport.support${F("interstellar_exchange_title")}
          ${F("space_support",[F("interstellar_alpha_name")])}
          `,reqs:{banking:12},cost:{Money:e=>Xi("exchange",e,68e4,1.28,"interstellar"),Stone:e=>Xi("exchange",e,115e3,1.28,"interstellar"),Adamantite:e=>Xi("exchange",e,55e3,1.28,"interstellar"),Graphene:e=>Xi("exchange",e,78e3,1.28,"interstellar")},effect(){let e=t.race.cataclysm||t.race.orbit_decayed?i.spaceport:t.city.bank?t.city.bank.count:0,a=t.race.cataclysm||t.race.orbit_decayed?4*Hs():Hs(),r=Lr(t.city.bank?a*e/18:0);return t.race.inflation&&(r*=2),t.tech.banking>=13&&(t.galaxy.freighter&&(r*=1+.03*n.freighter),t.galaxy.super_freighter&&(r*=1+.08*n.super_freighter)),r=+r.toFixed(0),`
          ${F("space_used_support",[F("interstellar_alpha_name")])}
          ${F("plus_max_resource",[`$${r.toLocaleString()}`,F("resource_Money_name")])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("exchange","interstellar"),t.interstellar.starport.support${F("interstellar_g_factory_title")}
          ${F("space_support",[F("interstellar_alpha_name")])}
          `,reqs:{graphene:1},cost:{Money:e=>Xi("g_factory",e,95e4,1.28,"interstellar"),Copper:e=>Xi("g_factory",e,165e3,1.28,"interstellar"),Cement:e=>Xi("g_factory",e,22e4,1.28,"interstellar"),Infernite:e=>Xi("g_factory",e,750,1.28,"interstellar")},effect:()=>`
          ${F("space_used_support",[F("interstellar_alpha_name")])}
          ${F("interstellar_g_factory_effect")}
          `,support:()=>-1,powered:()=>oc(1),special:!0,action(){return!!Os($(this)[0])&&(Nt("g_factory","interstellar"),t.resource.Graphene.display=!0,t.interstellar.starport.support`
          ${F("interstellar_int_factory_title")}
          ${F("requires_power_combo",[t.resource.Deuterium.name])}
          `,reqs:{alpha:4},cost:{Money:e=>Xi("int_factory",e,25e6,1.26,"interstellar"),Coal:e=>Xi("int_factory",e,1e7,1.26,"interstellar"),Brick:e=>Xi("int_factory",e,75e4,1.26,"interstellar"),Bolognium:e=>Xi("int_factory",e,5e4,1.26,"interstellar")},effect(){let e=+Yt(5).toFixed(2);return`
          ${F("interstellar_int_factory_effect")}
          ${F("city_crafted_mats",[10])}
          ${F("interstellar_fusion_effect",[e])} ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(5),special:!0,action(){return!!Os($(this)[0])&&(Nt("int_factory","interstellar"),xs($(this)[0])&&(t.city.factory.Alloy+=2,Ws()),!0)}},luxury_condo:{id:"interstellar-luxury_condo",title:F("tech_luxury_condo"),desc:`
          ${F("tech_luxury_condo")}
          ${F("requires_power")}
          `,reqs:{alpha:5},cost:{Money:e=>Xi("luxury_condo",e,25e6,1.25,"interstellar"),Neutronium:e=>Xi("luxury_condo",e,75e3,1.25,"interstellar"),Stanene:e=>Xi("luxury_condo",e,23e4,1.25,"interstellar"),Orichalcum:e=>Xi("luxury_condo",e,65e3,1.25,"interstellar"),Nanoweave:e=>Xi("luxury_condo",e,12500,1.25,"interstellar"),Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens(),t=Lr(75e4);return`
          ${F("plus_max_citizens",[e])}, ${F("minus_power",[$(this)[0].powered()])}
          ${F("plus_max_resource",[`$${t.toLocaleString()}`,F("resource_Money_name")])}
          `},powered:()=>oc(3),action(){return!!Os($(this)[0])&&(Nt("luxury_condo","interstellar"),xs($(this)[0])&&(t.resource[t.race.species].max+=2),!0)},citizens(){let e=2;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},zoo:{id:"interstellar-zoo",title:F("tech_zoo"),desc:()=>`
          ${F("tech_zoo")}
          ${F("requires_power_support_combo",[F("interstellar_alpha_name"),t.resource.Food.name])}
          `,reqs:{zoo:1},cost:{Money:e=>Xi("zoo",e,5e7,1.24,"interstellar"),Polymer:e=>Xi("zoo",e,6e6,1.24,"interstellar"),Infernite:e=>Xi("zoo",e,75e3,1.24,"interstellar"),Brick:e=>Xi("zoo",e,2e6,1.24,"interstellar")},effect:()=>`
          ${F("space_used_support",[F("interstellar_alpha_name")])}
          ${F("space_red_vr_center_effect1",[5])}
          ${F("space_red_vr_center_effect2",[2])}
          ${F("interstellar_alpha_starport_effect3",[12e3,t.resource.Food.name])}
          `,powered:()=>oc(3),action(){return!!Os($(this)[0])&&(Nt("zoo","interstellar"),t.interstellar.starport.supportt.tech.storage<=2?F("city_shed_title1"):t.tech.storage>=4?F("city_shed_title3"):F("city_shed_title2"),desc(){let e=t.tech.storage>=3?t.tech.storage>=4?F("city_shed_desc_size3"):F("city_shed_desc_size2"):F("city_shed_desc_size1");return F("city_shed_desc",[e])},reqs:{alpha:2},cost:{Money:e=>Xi("warehouse",e,175e3,1.28,"interstellar"),Lumber:e=>Xi("warehouse",e,1e5,1.28,"interstellar"),Aluminium:e=>Xi("warehouse",e,12e4,1.28,"interstellar"),Cement:e=>Xi("warehouse",e,45e3,1.28,"interstellar")},res(){let e=["Lumber","Stone","Chrysotile","Furs","Copper","Iron","Aluminium","Cement","Coal","Nano_Tube","Neutronium","Adamantite","Infernite"];return t.tech.storage>=3&&t.resource.Steel.display&&e.push("Steel"),t.tech.storage>=4&&t.resource.Titanium.display&&e.push("Titanium"),e},val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 750;case"Furs":return 425;case"Copper":return 380;case"Iron":return 350;case"Aluminium":return 320;case"Cement":return 280;case"Coal":return 120;case"Steel":return 60;case"Titanium":return 40;case"Nano_Tube":return 30;case"Neutronium":return 8;case"Adamantite":return 18;case"Infernite":return 5;default:return 0}},wide:!0,effect(){let e='
          ',a=os();for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return e+="
          ",e},action(){if(Os($(this)[0])){Nt("warehouse","interstellar");let e=os();for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=Lr($(this)[0].val(a)*e));return!0}return!1}}},int_proxima:{info:{name:F("interstellar_proxima_name"),desc:()=>t.tech.proxima?F("interstellar_proxima_desc2"):F("interstellar_proxima_desc1")},proxima_mission:{id:"interstellar-proxima_mission",title:F("space_mission_title",[F("interstellar_proxima_name")]),desc:F("space_mission_desc",[F("interstellar_proxima_name")]),reqs:{alpha:1},grant:["proxima",1],queue_complete:()=>t.tech.proxima>=1?0:1,cost:{Helium_3:()=>+Yt(42e3).toFixed(0)},effect:F("interstellar_proxima_mission_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.xfer_station={count:0,on:0},Di(F("interstellar_proxima_mission_result"),"info",!1,["progress"]),!0)}},xfer_station:{id:"interstellar-xfer_station",title:F("interstellar_xfer_station_title"),desc:()=>`
          ${F("interstellar_xfer_station_desc")}
          ${F("requires_power_combo",[t.resource.Uranium.name])}
          `,reqs:{proxima:1},cost:{Money:e=>Xi("xfer_station",e,12e5,1.28,"interstellar"),Neutronium:e=>Xi("xfer_station",e,1500,1.28,"interstellar"),Adamantite:e=>Xi("xfer_station",e,6e3,1.28,"interstellar"),Polymer:e=>Xi("xfer_station",e,12e3,1.28,"interstellar"),Wrought_Iron:e=>Xi("xfer_station",e,3500,1.28,"interstellar")},effect(){let e=Lr(5e3),a=Lr(4e3),r=Lr(2500),s="";return t.resource.Deuterium.display&&(s=`
          ${F("plus_max_resource",[Lr(2e3),F("resource_Deuterium_name")])}
          `),`
          ${F("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
          ${F("plus_max_resource",[a,F("resource_Oil_name")])}
          ${F("plus_max_resource",[e,F("resource_Helium_3_name")])}
          ${F("plus_max_resource",[r,F("resource_Uranium_name")])}
          ${s}
          ${F("city_fission_power_effect",[.28])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},support:()=>1,powered:()=>oc(1),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("xfer_station","interstellar"),xs($(this)[0])&&(t.resource.Uranium.max+=Lr(2500),t.resource.Helium_3.max+=Lr(5e3),t.resource.Oil.max+=Lr(4e3),t.resource.Deuterium.max+=Lr(2e3)),1===t.tech.proxima&&(t.tech.proxima=2,t.interstellar.cargo_yard={count:0}),!0)}},cargo_yard:{id:"interstellar-cargo_yard",title:F("interstellar_cargo_yard_title"),desc:F("interstellar_cargo_yard_title"),reqs:{proxima:2},cost:{Money:e=>Xi("cargo_yard",e,275e3,1.28,"interstellar"),Graphene:e=>Xi("cargo_yard",e,7500,1.28,"interstellar"),Mythril:e=>Xi("cargo_yard",e,6e3,1.28,"interstellar")},effect(){let e=Lr(200),a=Lr(150),r=`
          ${F("plus_max_resource",[50,F("resource_Crates_name")])}
          ${F("plus_max_resource",[50,F("resource_Containers_name")])}
          `;return r+=`
          ${F("plus_max_resource",[e,F("resource_Neutronium_name")])}
          ${F("plus_max_resource",[a,F("resource_Infernite_name")])}
          `,t.tech.storage>=7&&(r+=`
          ${F("interstellar_cargo_yard_effect",[+u.toFixed(3)])}
          `),r},action(){return!!Os($(this)[0])&&(Nt("cargo_yard","interstellar"),!0)}},cruiser:{id:"interstellar-cruiser",title:F("interstellar_cruiser_title"),desc:F("interstellar_cruiser_title"),reqs:{cruiser:1},cost:{Money:e=>Xi("cruiser",e,875e3,1.28,"interstellar"),Aluminium:e=>Xi("cruiser",e,195e3,1.28,"interstellar"),Deuterium:e=>Xi("cruiser",e,+Yt(1500).toFixed(0),1.28,"interstellar"),Neutronium:e=>Xi("cruiser",e,2e3,1.28,"interstellar"),Aerogel:e=>Xi("cruiser",e,250,1.28,"interstellar"),Horseshoe:()=>t.race.hooved?3:0},powered:()=>oc(1),effect(){let e=+Yt(6).toFixed(2);return`
          ${F("plus_max_soldiers",[la(3)])}
          ${F("space_belt_station_effect3",[e])}
          `},action(){return!!Os($(this)[0])&&(Nt("cruiser","interstellar"),t.interstellar.cruiser.on++,!0)}},dyson:{id:"interstellar-dyson",title:F("interstellar_dyson_title"),desc:e=>!t.interstellar.hasOwnProperty("dyson")||t.interstellar.dyson.count<100||e?`
          ${F("interstellar_dyson_title")}
          ${F("requires_segmemts",[100])}
          `:`
          ${F("interstellar_dyson_title")}
          `,reqs:{proxima:3},queue_size:10,queue_complete:()=>100-t.interstellar.dyson.count,condition:()=>!(t.interstellar.dyson.count>=100&&t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?25e4:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?1e4:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?25:0,Stanene:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?1e5:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0);if(a<100){let e=a>0?`
          ${F("space_dwarf_reactor_effect1",[cc(1.25*a)])}
          `:"",t=100-a;return`
          ${F("interstellar_dyson_effect")}
          ${e}
          ${F("space_dwarf_collider_effect2",[t])}
          `}return F("interstellar_dyson_complete",[cc(175)])},action(){return!!(Os($(this)[0])&&t.interstellar.dyson.count<100)&&(Nt("dyson","interstellar"),t.interstellar.dyson.count>=100&&ms(),!0)}},dyson_sphere:{id:"interstellar-dyson_sphere",title:F("interstellar_dyson_sphere_title"),desc:e=>!t.interstellar.hasOwnProperty("dyson_sphere")||t.interstellar.dyson_sphere.count<100||e?`
          ${F("interstellar_dyson_sphere_title")}
          ${F("requires_segmemts",[100])}
          `:`
          ${F("interstellar_dyson_sphere_title")}
          `,reqs:{proxima:3,dyson:1},queue_size:10,queue_complete:()=>100-t.interstellar.dyson_sphere.count,condition:()=>!!(t.interstellar.dyson.count>=100&&t.tech.dyson&&1===t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?5e6:0,Bolognium:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?25e3:0,Vitreloy:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?1250:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0);if(a<100){let e=175+5*a,t=100-a;return`
          ${F("interstellar_dyson_sphere_effect")}
          ${F("space_dwarf_reactor_effect1",[cc(e)])}
          ${F("space_dwarf_collider_effect2",[t])}
          `}return F("interstellar_dyson_sphere_complete",[cc(750)])},action(){return!!(Os($(this)[0])&&t.interstellar.dyson_sphere.count<100)&&(Nt("dyson_sphere","interstellar"),t.interstellar.dyson_sphere.count>=100&&ms(),!0)}},orichalcum_sphere:{id:"interstellar-orichalcum_sphere",title:F("interstellar_dyson_sphere_title"),desc:e=>!t.interstellar.hasOwnProperty("orichalcum_sphere")||t.interstellar.orichalcum_sphere.count<100||e?`
          ${F("interstellar_orichalcum_sphere_desc")}
          ${F("requires_segmemts",[100])}
          `:`
          ${F("interstellar_orichalcum_sphere_desc")}
          `,reqs:{proxima:3,dyson:2},queue_size:10,queue_complete:()=>100-t.interstellar.orichalcum_sphere.count,condition:()=>!!(t.interstellar.dyson_sphere.count>=100&&t.tech.dyson&&2===t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0)<100?25e6:0,Orichalcum:e=>(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0);if(a<100){let e=750+8*a,t=100-a;return`
          ${F("interstellar_orichalcum_sphere_effect")}
          ${F("space_dwarf_reactor_effect1",[cc(e)])}
          ${F("space_dwarf_collider_effect2",[t])}
          `}return F("interstellar_dyson_sphere_complete",[cc(1750)])},action(){return!!(Os($(this)[0])&&t.interstellar.orichalcum_sphere.count<100)&&(Nt("orichalcum_sphere","interstellar"),t.interstellar.orichalcum_sphere.count>=100&&Xc("blacken_the_sun"),!0)}}},int_nebula:{info:{name:F("interstellar_nebula_name"),desc:()=>t.tech.nebula?F("interstellar_nebula_desc2"):F("interstellar_nebula_desc1"),support:"nexus"},nebula_mission:{id:"interstellar-nebula_mission",title:F("space_mission_title",[F("interstellar_nebula_name")]),desc:F("space_mission_desc",[F("interstellar_nebula_name")]),reqs:{alpha:1},grant:["nebula",1],queue_complete:()=>t.tech.nebula>=1?0:1,cost:{Helium_3:()=>+Yt(55e3).toFixed(0)},effect:F("interstellar_nebula_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("interstellar_nebula_mission_result"),"info",!1,["progress"]),!0)}},nexus:{id:"interstellar-nexus",title:F("interstellar_nexus_title"),desc:()=>`
          ${F("interstellar_nexus_title")}
          ${F("requires_power_combo",[t.resource.Money.name])}
          `,reqs:{nebula:1},cost:{Money:e=>Xi("nexus",e,9e5,1.24,"interstellar"),Adamantite:e=>Xi("nexus",e,7500,1.24,"interstellar"),Infernite:e=>Xi("nexus",e,250,1.24,"interstellar"),Sheet_Metal:e=>Xi("nexus",e,14e3,1.24,"interstellar"),Nano_Tube:e=>Xi("nexus",e,17500,1.24,"interstellar")},effect(){let e=Lr(3500),t=Lr(4e3),a=Lr(3e3),r=Lr(25);return`
          ${F("interstellar_nexus_effect1",[$(this)[0].support()])}
          ${F("plus_max_resource",[e,F("resource_Oil_name")])}
          ${F("plus_max_resource",[t,F("resource_Helium_3_name")])}
          ${F("plus_max_resource",[a,F("resource_Deuterium_name")])}
          ${F("plus_max_resource",[r,F("resource_Elerium_name")])}
          ${F("interstellar_nexus_effect2",[$(this)[0].powered(),350])}
          `},support:()=>2,powered:()=>oc(8),powerBalancer:()=>[{s:t.interstellar.nexus.s_max-t.interstellar.nexus.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("nexus","interstellar"),t.resource.Deuterium.display=!0,1===t.tech.nebula&&(t.interstellar.harvester={count:0,on:0},t.tech.nebula=2),xs($(this)[0])&&(t.resource.Oil.max+=Lr(2500),t.resource.Helium_3.max+=Lr(4e3),t.resource.Deuterium.max+=Lr(3e3),t.resource.Elerium.max+=Lr(25)),!0)}},harvester:{id:"interstellar-harvester",title:F("interstellar_harvester_title"),desc:`
          ${F("interstellar_harvester_title")}
          ${F("space_support",[F("interstellar_nebula_name")])}
          `,reqs:{nebula:2},cost:{Money:e=>Xi("harvester",e,65e4,1.28,"interstellar"),Copper:e=>Xi("harvester",e,8e4,1.28,"interstellar"),Alloy:e=>Xi("harvester",e,45e3,1.28,"interstellar"),Iridium:e=>Xi("harvester",e,8e3,1.28,"interstellar")},effect(){let e=+Pe("harvester","helium").toFixed(3),a=+Pe("harvester","deuterium").toFixed(3),r=t.tech.ram_scoop?`
          ${F("interstellar_harvester_effect",[a])}
          `:"";return`
          ${F("space_used_support",[F("interstellar_nebula_name")])}
          ${F("space_gas_mining_effect1",[e])}
          ${r}`},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("harvester","interstellar"),t.interstellar.nexus.support${F("interstellar_elerium_prospector_title")}
          ${F("space_support",[F("interstellar_nebula_name")])}
          `,reqs:{nebula:3},cost:{Money:e=>Xi("elerium_prospector",e,825e3,1.28,"interstellar"),Steel:e=>Xi("elerium_prospector",e,18e3,1.28,"interstellar"),Polymer:e=>Xi("elerium_prospector",e,22e3,1.28,"interstellar"),Graphene:e=>Xi("elerium_prospector",e,82e3,1.28,"interstellar"),Stanene:e=>Xi("elerium_prospector",e,57e3,1.28,"interstellar")},effect(){let e=+Pe("elerium_prospector").toFixed(3);return`
          ${F("space_used_support",[F("interstellar_nebula_name")])}
          ${F("space_belt_elerium_ship_effect2",[e])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("elerium_prospector","interstellar"),t.interstellar.nexus.supportt.tech.neutron?F("interstellar_neutron_desc2",[di[t.race.species].home]):F("interstellar_neutron_desc1")},neutron_mission:{id:"interstellar-neutron_mission",title:F("space_mission_title",[F("interstellar_neutron_name")]),desc:F("space_mission_desc",[F("interstellar_neutron_name")]),reqs:{nebula:1,high_tech:14},grant:["neutron",1],queue_complete:()=>t.tech.neutron>=1?0:1,cost:{Helium_3:()=>+Yt(6e4).toFixed(0),Deuterium:()=>+Yt(1e4).toFixed(0)},effect:F("interstellar_neutron_mission_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.neutron_miner={count:0,on:0},Di(F("interstellar_neutron_mission_result"),"info",!1,["progress"]),!0)}},neutron_miner:{id:"interstellar-neutron_miner",title:F("interstellar_neutron_miner_title"),desc:()=>`
          ${F("interstellar_neutron_miner_desc")}
          ${F("requires_power_combo",[t.resource.Helium_3.name])}
          `,reqs:{neutron:1},cost:{Money:e=>Xi("neutron_miner",e,1e6,1.32,"interstellar"),Titanium:e=>Xi("neutron_miner",e,45e3,1.32,"interstellar"),Stanene:e=>Xi("neutron_miner",e,88e3,1.32,"interstellar"),Elerium:e=>Xi("neutron_miner",e,20,1.32,"interstellar"),Aerogel:e=>Xi("neutron_miner",e,50,1.32,"interstellar")},effect(){let e=+Pe("neutron_miner").toFixed(3),t=Lr(500),a=+Yt(3).toFixed(2);return`
          ${F("space_gas_moon_outpost_effect1",[e])}
          ${F("plus_max_resource",[t,F("resource_Neutronium_name")])}
          ${F("interstellar_alpha_starport_effect2",[a,$(this)[0].powered()])}
          `},powered:()=>oc(6),powerBalancer:()=>[{r:"Neutronium",k:"lpmod"}],action(){return!!Os($(this)[0])&&(Nt("neutron_miner","interstellar"),xs($(this)[0]),!0)}},citadel:{id:"interstellar-citadel",title:F("interstellar_citadel_title"),desc:`
          ${F("interstellar_citadel_desc")}
          ${F("requires_power")}
          `,reqs:{neutron:1,high_tech:15},cost:{Money:e=>Xi("citadel",e,5e6,1.25,"interstellar"),Knowledge:e=>Xi("citadel",e,15e5,1.15,"interstellar"),Graphene:e=>Xi("citadel",e,5e4,1.25,"interstellar"),Stanene:e=>Xi("citadel",e,1e5,1.25,"interstellar"),Elerium:e=>Xi("citadel",e,250,1.25,"interstellar"),Soul_Gem:e=>Xi("citadel",e,1,1.25,"interstellar")},wide:!0,effect(){let e=`
          ${F("interstellar_citadel_stat",[+u.toFixed(1)])}
          ${F("interstellar_citadel_effect",[5])}
          `;if(t.tech.ai_core){let a=+(u/1.75).toFixed(1);t.race.flier||(e+=`
          ${F("interstellar_citadel_effect2",[a])}
          `),t.tech.ai_core>=2&&(e+=`
          ${F("interstellar_citadel_effect3",[2])}
          `),t.tech.ai_core>=3&&(e+=`
          ${F("interstellar_citadel_effect4",[+(u/5).toFixed(1)])}
          `)}return`${e}
          ${F("interstellar_citadel_power",[$(this)[0].powered(),oc(2.5)])}
          `},powered:()=>i.citadel&&i.citadel>1?oc(30+2.5*(i.citadel-1)):oc(30),action(){return!!Os($(this)[0])&&(Nt("citadel","interstellar"),xs($(this)[0]),!0)},flair:()=>F("interstellar_citadel_flair")},stellar_forge:{id:"interstellar-stellar_forge",title:F("interstellar_stellar_forge_title"),desc:`
          ${F("interstellar_stellar_forge_title")}
          ${F("requires_power")}
          `,reqs:{star_forge:1},cost:{Money:e=>Xi("stellar_forge",e,12e5,1.25,"interstellar"),Iridium:e=>Xi("stellar_forge",e,25e4,1.25,"interstellar"),Bolognium:e=>Xi("stellar_forge",e,35e3,1.25,"interstellar"),Aerogel:e=>Xi("stellar_forge",e,75e3,1.25,"interstellar")},effect(){let e=`
          ${F("city_foundry_effect1",[la(2)])}
          ${F("interstellar_stellar_forge_effect",[10])}
          ${F("interstellar_stellar_forge_effect2",[5])}
          `;return t.tech.star_forge&&t.tech.star_forge>=2&&(e+=`
          ${F("interstellar_stellar_forge_effect3",[2])}
          `),`${e}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(3),special:!0,action(){return!!Os($(this)[0])&&(Nt("stellar_forge","interstellar"),xs($(this)[0])&&t.tech.star_forge>=2&&(t.city.smelter.cap+=2,t.city.smelter.Star+=2,t.city.smelter.StarCap+=2,t.city.smelter.Iron+=2),!0)},flair:()=>F("interstellar_stellar_forge_flair")}},int_blackhole:{info:{name:F("interstellar_blackhole_name"),desc(){let e=di[t.race.species].home;if(t.tech.blackhole>=5){let a=+t.interstellar.stellar_engine.mass.toFixed(10),r=+t.interstellar.stellar_engine.exotic.toFixed(10);if(t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12)),t.tech.whitehole){let s=mc("bigbang"),i="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
          ${F("interstellar_blackhole_desc4",[e,a,r])}
          ${F("interstellar_blackhole_desc5",[s.plasmid,s.phage,s.dark,i])}
          `}return t.interstellar.stellar_engine.exotic>0?F("interstellar_blackhole_desc4",[e,a,r]):F("interstellar_blackhole_desc3",[e,a])}return t.tech.blackhole?F("interstellar_blackhole_desc2",[e]):F("interstellar_blackhole_desc1",[e])}},blackhole_mission:{id:"interstellar-blackhole_mission",title:F("space_mission_title",[F("interstellar_blackhole_name")]),desc:F("space_mission_desc",[F("interstellar_blackhole_name")]),reqs:{nebula:1},grant:["blackhole",1],queue_complete:()=>t.tech.blackhole>=1?0:1,cost:{Helium_3:()=>+Yt(75e3).toFixed(0),Deuterium:()=>+Yt(25e3).toFixed(0)},effect:F("interstellar_blackhole_mission_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.far_reach={count:0,on:0},Di(F("interstellar_blackhole_mission_result"),"info",!1,["progress"]),!0)}},far_reach:{id:"interstellar-far_reach",title:F("interstellar_far_reach"),desc:`
          ${F("interstellar_far_reach_desc")}
          ${F("requires_power")}
          `,reqs:{blackhole:1},cost:{Money:e=>Xi("far_reach",e,1e6,1.32,"interstellar"),Knowledge:e=>Xi("far_reach",e,1e5,1.32,"interstellar"),Neutronium:e=>Xi("far_reach",e,2500,1.32,"interstellar"),Elerium:e=>Xi("far_reach",e,100,1.32,"interstellar"),Aerogel:e=>Xi("far_reach",e,1e3,1.32,"interstellar")},effect(){return`
          ${F("interstellar_far_reach_effect",[1])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(5),action(){return!!Os($(this)[0])&&(Nt("far_reach","interstellar"),xs($(this)[0]),1===t.tech.blackhole&&(t.tech.blackhole=2,ms()),!0)},flair:F("interstellar_far_reach_flair")},stellar_engine:{id:"interstellar-stellar_engine",title:F("interstellar_stellar_engine"),desc:e=>!t.interstellar.hasOwnProperty("stellar_engine")||t.interstellar.stellar_engine.count<100||e?`
          ${F("interstellar_stellar_engine")}
          ${F("requires_segmemts",[100])}
          `:`
          ${F("interstellar_stellar_engine")}
          `,reqs:{blackhole:3},queue_size:10,queue_complete:()=>100-t.interstellar.stellar_engine.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?5e5:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?450:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?17500:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?225:0,Graphene:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?45e3:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?250:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?75:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0);if(a<100){let e=100-a;return`
          ${F("interstellar_stellar_engine_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          `}{let e=t.tech.gravity&&t.tech.gravity>=2?13.5:7.5,a=t.interstellar.stellar_engine?t.interstellar.stellar_engine.mass:8;t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12));let r=cc(+(20+(a-8)*e+(t.interstellar.stellar_engine?t.interstellar.stellar_engine.exotic:0)*e*10).toFixed(2));if(t.tech.blackhole>=5){let e=+t.interstellar.stellar_engine.exotic.toFixed(10),s=t.interstellar.stellar_engine.exotic>0?F("interstellar_stellar_engine_effect3",[a,e]):F("interstellar_stellar_engine_effect2",[a]);return`
          ${F("interstellar_stellar_engine_complete",[r])}
          ${s}
          `}return F("interstellar_stellar_engine_complete",[r])}},action(){return!!(Os($(this)[0])&&t.interstellar.stellar_engine.count<100)&&(Nt("stellar_engine","interstellar"),t.interstellar.stellar_engine.count>=100&&3===t.tech.blackhole&&(t.tech.blackhole=4,ms()),!0)}},mass_ejector:{id:"interstellar-mass_ejector",title:F("interstellar_mass_ejector"),desc:`
          ${F("interstellar_mass_ejector")}
          ${F("requires_power")}
          `,reqs:{blackhole:5},cost:{Money:e=>Xi("mass_ejector",e,75e4,1.25,"interstellar"),Adamantite:e=>Xi("mass_ejector",e,125e3,1.25,"interstellar"),Infernite:e=>Xi("mass_ejector",e,275,1.25,"interstellar"),Elerium:e=>Xi("mass_ejector",e,100,1.25,"interstellar"),Mythril:e=>Xi("mass_ejector",e,1e4,1.25,"interstellar")},effect(){return`
          ${F("interstellar_mass_ejector_effect")}, ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(3),special:!0,sAction(){t.settings.civTabs=4,t.settings.marketTabs=2,t.settings.tabLoad||(Ct("mTabResource"),Ei("interstellar-mass_ejector"))},action(){return!!Os($(this)[0])&&(0===t.interstellar.mass_ejector.count&&Di(F("interstellar_mass_ejector_msg"),"info",!1,["progress"]),t.settings.showEjector=!0,Nt("mass_ejector","interstellar"),xs($(this)[0]),rc($("#resources")),rr(),!0)},flair:()=>F("interstellar_mass_ejector_flair")},jump_ship:{id:"interstellar-jump_ship",title:F("interstellar_jump_ship"),desc:F("interstellar_jump_ship_desc"),reqs:{stargate:1},grant:["stargate",2],queue_complete:()=>t.tech.stargate>=2?0:1,cost:{Money:()=>2e7,Copper:()=>24e5,Aluminium:()=>4e6,Titanium:()=>125e4,Adamantite:()=>75e4,Stanene:()=>9e5,Aerogel:()=>1e5},effect:F("interstellar_jump_ship_effect"),action(){return!!Os($(this)[0])}},wormhole_mission:{id:"interstellar-wormhole_mission",title:F("space_mission_title",[F("interstellar_wormhole_name")]),desc:F("space_mission_desc",[F("interstellar_wormhole_name")]),reqs:{stargate:2},grant:["stargate",3],queue_complete:()=>t.tech.stargate>=3?0:1,cost:{Helium_3:()=>+Yt(15e4).toFixed(0),Deuterium:()=>+Yt(75e3).toFixed(0)},effect:F("interstellar_wormhole_mission_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.stargate={count:0},t.galaxy.gateway_station={count:0,on:0},Di(F("interstellar_wormhole_mission_result"),"info",!1,["progress"]),!0)}},stargate:{id:"interstellar-stargate",title:F("interstellar_stargate"),desc:e=>!t.interstellar.hasOwnProperty("stargate")||t.interstellar.stargate.count<200||e?`
          ${F("interstellar_stargate")}
          ${F("requires_segmemts",[200])}
          `+(t.interstellar.hasOwnProperty("stargate")&&t.interstellar.stargate.count>=200?`
          ${F("requires_power")}
          `:""):`
          ${F("interstellar_stargate")}
          `,reqs:{stargate:3},condition:()=>!(t.interstellar.stargate.count>=200),queue_size:10,queue_complete:()=>200-t.interstellar.stargate.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?1e6:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?4800:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?666:0,Elerium:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?75:0,Nano_Tube:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?12e3:0,Stanene:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?6e4:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?3200:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0);if(a<200){let e=200-a;return`
          ${F("interstellar_stargate_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          `}return St.int_blackhole.s_gate.effect()},action(){return!!(Os($(this)[0])&&t.interstellar.stargate.count<200)&&(Nt("stargate","interstellar"),t.interstellar.stargate.count>=200&&(t.tech.stargate=4,t.interstellar.s_gate={count:1,on:0},t.city.power>=St.int_blackhole.s_gate.powered()&&t.interstellar.s_gate.on++,Ut(),Ei()),!0)}},s_gate:{id:"interstellar-s_gate",title:F("interstellar_stargate"),desc:()=>`
          ${F("interstellar_stargate")}
          ${F("requires_power")}
          `,reqs:{stargate:4},condition:()=>t.interstellar.stargate.count>=200,wiki:!1,queue_complete:()=>0,cost:{},powered:()=>oc(250),effect(){return`
          ${F("interstellar_s_gate_effect")}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action:()=>!1}},int_sirius:{info:{name:()=>t.tech.ascension>=3?F("interstellar_sirius_b_name"):F("interstellar_sirius_name"),desc:()=>t.tech.ascension>=3?F("interstellar_sirius_b_desc"):F("interstellar_sirius_desc",[di[t.race.species].home])},sirius_mission:{id:"interstellar-sirius_mission",title:F("space_mission_title",[F("interstellar_sirius_name")]),desc:F("space_mission_desc",[F("interstellar_sirius_name")]),reqs:{ascension:2},grant:["ascension",3],queue_complete:()=>t.tech.ascension>=3?0:1,cost:{Helium_3:()=>+Yt(48e4).toFixed(0),Deuterium:()=>+Yt(225e3).toFixed(0)},effect:()=>F("interstellar_sirius_mission_effect",[Ac("name"),di[t.race.species].home]),action(){return!!Os($(this)[0])}},sirius_b:{id:"interstellar-sirius_b",title:F("interstellar_sirius_b"),desc:F("interstellar_sirius_b"),reqs:{ascension:3},grant:["ascension",4],queue_complete:()=>t.tech.ascension>=4?0:1,cost:{Knowledge:()=>2e7},effect:()=>F("interstellar_sirius_b_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.space_elevator={count:0},!0)}},space_elevator:{id:"interstellar-space_elevator",title:F("interstellar_space_elevator"),desc:e=>!t.interstellar.hasOwnProperty("space_elevator")||t.interstellar.space_elevator.count<100||e?`
          ${F("interstellar_space_elevator")}
          ${F("requires_segmemts",[100])}
          `:`
          ${F("interstellar_space_elevator")}
          `,reqs:{ascension:4},condition:()=>!(t.interstellar.space_elevator.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.space_elevator.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?2e7:0,Nano_Tube:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?5e5:0,Bolognium:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?1e5:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?125e3:0},effect(e){let a=`
          ${F("interstellar_space_elevator_effect")}
          `,r=(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0);return r<100&&(a+=`
          ${F("space_dwarf_collider_effect2",[100-r])}
          `),a},action(){return!!(Os($(this)[0])&&t.interstellar.space_elevator.count<100)&&(Nt("space_elevator","interstellar"),t.interstellar.space_elevator.count>=100&&(t.tech.ascension=5,t.interstellar.gravity_dome={count:0},Ut(),Ei()),!0)}},gravity_dome:{id:"interstellar-gravity_dome",title:F("interstellar_gravity_dome"),desc:e=>!t.interstellar.hasOwnProperty("gravity_dome")||t.interstellar.gravity_dome.count<100||e?`
          ${F("interstellar_gravity_dome")}
          ${F("requires_segmemts",[100])}
          `:`
          ${F("interstellar_gravity_dome")}
          `,reqs:{ascension:5},condition:()=>!(t.interstellar.gravity_dome.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.gravity_dome.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?35e6:0,Cement:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?125e4:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?65e4:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?18e4:0},effect(e){let a=`
          ${F("interstellar_gravity_dome_effect",[di[t.race.species].home])}
          `,r=(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0);return r<100&&(a+=`
          ${F("space_dwarf_collider_effect2",[100-r])}
          `),a},action(){return!!(Os($(this)[0])&&t.interstellar.gravity_dome.count<100)&&(Nt("gravity_dome","interstellar"),t.interstellar.gravity_dome.count>=100&&(t.tech.ascension=6,t.interstellar.ascension_machine={count:0},t.interstellar.thermal_collector={count:0},Ut(),Ei()),!0)}},ascension_machine:{id:"interstellar-ascension_machine",title:F("interstellar_ascension_machine"),desc:e=>!t.interstellar.hasOwnProperty("ascension_machine")||t.interstellar.ascension_machine.count<100||e?`
          ${F("interstellar_ascension_machine")}
          ${F("requires_segmemts",[100])}
          `+(t.interstellar.hasOwnProperty("ascension_machine")&&t.interstellar.ascension_machine.count>=100?`
          ${F("requires_power")}
          `:""):`
          ${F("interstellar_ascension_machine")}
          `,reqs:{ascension:6},condition:()=>!(t.interstellar.ascension_machine.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.ascension_machine.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e6:0,Alloy:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e4:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?1e3:0,Orichalcum:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?25e4:0,Nanoweave:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0);if(a<100){let e=100-a;return`
          ${F("interstellar_ascension_machine_effect",[Ac("name")])}
          ${F("space_dwarf_collider_effect2",[e])}
          `}return St.int_sirius.ascension_trigger.effect()},action(){return!!(Os($(this)[0])&&t.interstellar.ascension_machine.count<100)&&(Nt("ascension_machine","interstellar"),t.interstellar.ascension_machine.count>=100&&(t.tech.ascension=7,t.interstellar.ascension_trigger={count:1,on:0},Ut(),Ei()),!0)}},ascension_trigger:{id:"interstellar-ascension_trigger",title:F("interstellar_ascension_machine"),desc:()=>`
          ${F("interstellar_ascension_machine")}
          ${F("requires_power")}
          `,wiki:!1,reqs:{ascension:7},condition:()=>t.interstellar.ascension_machine.count>=100,queue_complete:()=>0,cost:{},powered(){let e=100;if(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2){e+=t.stats.achieve.technophobe.l>=4?25:10;for(let a=1;a=5&&(e+=5)}let a=Math.round(oc(1e4)-e*(t.interstellar.hasOwnProperty("thermal_collector")?t.interstellar.thermal_collector.count:0));return a<0&&(a=0),a},postPower(e){e?setTimeout((function(){t.tech.ascension=i.ascension_trigger?8:7,Ut()}),250):(t.tech.ascension=7,Ut())},effect(){let e=Ft(),t=$(this)[0].powered(),a=t>0?`
          ${F("minus_power",[t])}
          `:"";return`
          ${F("interstellar_ascension_trigger_effect")}
          ${e}${a}`},action:()=>!1},ascend:{id:"interstellar-ascend",title:F("interstellar_ascend"),desc:F("interstellar_ascend"),reqs:{ascension:8},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=Ft();return`
          ${F("interstellar_ascend_effect")}
          ${e}`},action(){return!!Os($(this)[0])&&(ra(),!0)}},thermal_collector:{id:"interstellar-thermal_collector",title:F("interstellar_thermal_collector"),desc:F("interstellar_thermal_collector"),reqs:{ascension:6},cost:{Money:e=>Xi("thermal_collector",e,5e6,1.08,"interstellar"),Infernite:e=>Xi("thermal_collector",e,25e3,1.08,"interstellar"),Stanene:e=>Xi("thermal_collector",e,1e6,1.08,"interstellar"),Vitreloy:e=>Xi("thermal_collector",e,1e5,1.08,"interstellar")},effect(){let e=100;if(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2){e+=t.stats.achieve.technophobe.l>=4?25:10;for(let a=1;a=5&&(e+=5)}return F("interstellar_thermal_collector_effect",[e])},action(){return!!Os($(this)[0])&&(Nt("thermal_collector","interstellar"),!0)}}}};function Ft(){let e=mc("ascend"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
          ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
          ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
          ${F("interstellar_ascension_trigger_effect2",[e.harmony,F("resource_Harmony_name")])}
          ${F("interstellar_ascension_trigger_effect3")}
          `}function zt(){let e=mc("terraform"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
          ${F("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
          ${F("interstellar_ascension_trigger_effect2",[e.phage,F("resource_Phage_name")])}
          ${F("interstellar_ascension_trigger_effect2",[e.harmony,F("resource_Harmony_name")])}
          ${F("space_terraformer_effect3")}
          `}const At={gxy_gateway:{info:{name:F("galaxy_gateway"),desc:()=>F("galaxy_gateway_desc"),control:()=>({name:Ac("name"),color:"success"}),support:"starbase"},gateway_mission:{id:"galaxy-gateway_mission",title:F("galaxy_gateway_mission"),desc:F("galaxy_gateway_mission"),reqs:{gateway:1},grant:["gateway",2],queue_complete:()=>t.tech.gateway>=2?0:1,cost:{Helium_3:()=>+Yt(212e3).toFixed(0),Deuterium:()=>+Yt(11e4).toFixed(0)},effect:F("galaxy_gateway_mission_effect"),action(){return!!Os($(this)[0])&&(It(),t.galaxy.defense={gxy_stargate:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_gateway:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_gorddon:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_alien1:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_alien2:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_chthonian:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0}},!0)}},starbase:{id:"galaxy-starbase",title:F("galaxy_starbase"),desc:()=>`
          ${F("galaxy_starbase")}
          ${F("requires_power_space",[t.resource.Food.name])}
          `,reqs:{gateway:2},cost:{Money:e=>Xi("starbase",e,42e5,1.25,"galaxy"),Elerium:e=>Xi("starbase",e,1e3,1.25,"galaxy"),Mythril:e=>Xi("starbase",e,9e4,1.25,"galaxy"),Graphene:e=>Xi("starbase",e,32e4,1.25,"galaxy"),Horseshoe:()=>t.race.hooved?5:0},effect(){let e=+Yt(25).toFixed(2),a=t.tech.marines>=2?la(8):la(5);return`
          ${F("galaxy_defense_platform_effect",[25])}
          ${F("galaxy_gateway_support",[$(this)[0].support()])}
          ${F("plus_max_soldiers",[a])}
          ${F("interstellar_alpha_starport_effect2",[e,$(this)[0].powered()])}
          ${F("interstellar_alpha_starport_effect3",[250,t.resource.Food.name])}
          `},support:()=>2,powered:()=>oc(i.s_gate?12:0),powerBalancer:()=>[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("starbase","galaxy"),xs($(this)[0]),2===t.tech.gateway&&(t.galaxy.bolognium_ship={count:0,on:0,crew:0},t.tech.gateway=3),!0)}},ship_dock:{id:"galaxy-ship_dock",title:F("galaxy_ship_dock"),desc:`
          ${F("galaxy_ship_dock")}
          ${F("requires_power")}
          `,reqs:{gateway:4},cost:{Money:e=>Xi("ship_dock",e,36e5,1.25,"galaxy"),Steel:e=>Xi("ship_dock",e,88e4,1.25,"galaxy"),Aluminium:e=>Xi("ship_dock",e,12e5,1.25,"galaxy"),Bolognium:e=>Xi("ship_dock",e,75e3,1.25,"galaxy")},effect(){return`
          ${F("galaxy_ship_dock_effect",[.25])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},support:()=>i.starbase?.25*i.starbase:0,powered:()=>oc(i.s_gate?4:0),powerBalancer:()=>[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],action(){return!!Os($(this)[0])&&(Nt("ship_dock","galaxy"),xs($(this)[0]),!0)}},bolognium_ship:{id:"galaxy-bolognium_ship",title:F("galaxy_bolognium_ship"),desc:()=>`
          ${F("galaxy_bolognium_ship_desc")}
          ${F("galaxy_starbase_support",[F("resource_Helium_3_name")])}
          `,reqs:{gateway:3},cost:{Money:e=>Xi("bolognium_ship",e,14e5,1.22,"galaxy"),Iron:e=>Xi("bolognium_ship",e,56e4,1.22,"galaxy"),Infernite:e=>Xi("bolognium_ship",e,1800,1.22,"galaxy"),Nano_Tube:e=>Xi("bolognium_ship",e,475e3,1.22,"galaxy")},effect(){let e=+Pe("bolognium_ship").toFixed(3),a=+Yt($(this)[0].ship.helium).toFixed(2);return`
          ${F("gain",[e,F("resource_Bolognium_name")])}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
          ${F("spend",[a,t.resource.Helium_3.name])}
          `},support:()=>-1,ship:{civ:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2,mil:()=>0,helium:5},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("bolognium_ship","galaxy"),t.resource.Bolognium.display=!0,t.civic.crew.display=!0,t.galaxy.starbase.support`
          ${F("galaxy_scout_ship")}
          ${F("galaxy_starbase_support",[F("resource_Helium_3_name")])}
          `,reqs:{andromeda:1},cost:{Money:e=>Xi("scout_ship",e,16e5,1.25,"galaxy"),Titanium:e=>Xi("scout_ship",e,325e3,1.25,"galaxy"),Graphene:e=>Xi("scout_ship",e,118e3,1.25,"galaxy"),Soul_Gem:e=>Xi("scout_ship",e,1,1.02,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2),a=t.tech.science>=17?`
          ${F("galaxy_scout_ship_effect2",[25])}
          `:"";return`
          ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
          ${F("galaxy_scout_ship_effect")}
          ${a}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
          ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
          ${F("spend",[e,t.resource.Helium_3.name])}
          `},support:()=>-1,ship:{civ:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,mil:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,helium:6,rating:()=>t.race.banana?7:10},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("scout_ship","galaxy"),t.galaxy.defense.gxy_gateway.scout_ship++,t.galaxy.starbase.support`
          ${F("galaxy_corvette_ship")}
          ${F("galaxy_starbase_support",[F("resource_Helium_3_name")])}
          `,reqs:{andromeda:2},cost:{Money:e=>Xi("corvette_ship",e,45e5,1.25,"galaxy"),Steel:e=>Xi("corvette_ship",e,175e4,1.25,"galaxy"),Infernite:e=>Xi("corvette_ship",e,16e3,1.25,"galaxy"),Bolognium:e=>Xi("corvette_ship",e,35e3,1.25,"galaxy"),Soul_Gem:e=>Xi("corvette_ship",e,1,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return`
          ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
          ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
          ${F("spend",[e,t.resource.Helium_3.name])}
          `},support:()=>-1,ship:{civ:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2,mil:()=>t.race.high_pop?3*ui.high_pop.vars()[0]:3,helium:10,rating:()=>t.race.banana?21:30},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("corvette_ship","galaxy"),t.galaxy.defense.gxy_gateway.corvette_ship++,t.galaxy.starbase.support`
          ${F("galaxy_frigate_ship")}
          ${F("galaxy_starbase_support",[F("resource_Helium_3_name")])}
          `,reqs:{andromeda:3},cost:{Money:e=>Xi("frigate_ship",e,18e6,1.25,"galaxy"),Elerium:e=>Xi("frigate_ship",e,1250,1.25,"galaxy"),Mythril:e=>Xi("frigate_ship",e,35e4,1.25,"galaxy"),Sheet_Metal:e=>Xi("frigate_ship",e,8e5,1.25,"galaxy"),Soul_Gem:e=>Xi("frigate_ship",e,2,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return`
          ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
          ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
          ${F("spend",[e,t.resource.Helium_3.name])}
          `},support:()=>-2,ship:{civ:()=>t.race.high_pop?3*ui.high_pop.vars()[0]:3,mil:()=>t.race.high_pop?5*ui.high_pop.vars()[0]:5,helium:25,rating:()=>t.race.banana?56:80},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("frigate_ship","galaxy"),t.galaxy.defense.gxy_gateway.frigate_ship++,t.galaxy.starbase.support+1`
          ${F("galaxy_cruiser_ship")}
          ${F("galaxy_starbase_support",[F("resource_Deuterium_name")])}
          `,reqs:{andromeda:4},cost:{Money:e=>Xi("cruiser_ship",e,75e6,1.25,"galaxy"),Copper:e=>Xi("cruiser_ship",e,6e6,1.25,"galaxy"),Adamantite:e=>Xi("cruiser_ship",e,1e6,1.25,"galaxy"),Vitreloy:e=>Xi("cruiser_ship",e,75e4,1.25,"galaxy"),Elerium:e=>Xi("cruiser_ship",e,1800,1.25,"galaxy"),Soul_Gem:e=>Xi("cruiser_ship",e,5,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.deuterium).toFixed(2);return`
          ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
          ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
          ${F("spend",[e,t.resource.Deuterium.name])}
          `},support:()=>-3,ship:{civ:()=>t.race.high_pop?6*ui.high_pop.vars()[0]:6,mil:()=>t.race.high_pop?10*ui.high_pop.vars()[0]:10,deuterium:25,rating:()=>t.race.banana?175:250},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("cruiser_ship","galaxy"),t.galaxy.defense.gxy_gateway.cruiser_ship++,t.galaxy.starbase.support+2`
          ${F("galaxy_dreadnought")}
          ${F("galaxy_starbase_support",[F("resource_Deuterium_name")])}
          `,reqs:{andromeda:5},cost:{Money:e=>Xi("dreadnought",e,225e6,1.25,"galaxy"),Neutronium:e=>Xi("dreadnought",e,25e4,1.25,"galaxy"),Bolognium:e=>Xi("dreadnought",e,15e5,1.25,"galaxy"),Vitreloy:e=>Xi("dreadnought",e,1e6,1.25,"galaxy"),Infernite:e=>Xi("dreadnought",e,4e5,1.25,"galaxy"),Aerogel:e=>Xi("dreadnought",e,8e5,1.25,"galaxy"),Soul_Gem:e=>Xi("dreadnought",e,25,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.deuterium).toFixed(2);return`
          ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
          ${F("galaxy_gateway_used_support",[-$(this)[0].support()])}
          ${F("spend",[e,t.resource.Deuterium.name])}
          `},support:()=>-5,ship:{civ:()=>t.race.high_pop?10*ui.high_pop.vars()[0]:10,mil:()=>t.race.high_pop?20*ui.high_pop.vars()[0]:20,deuterium:80,rating:()=>t.race.banana?1260:1800},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("dreadnought","galaxy"),t.galaxy.defense.gxy_gateway.dreadnought++,t.galaxy.starbase.support+2t.tech.piracy?F("galaxy_stargate_desc_alt"):F("galaxy_stargate_desc"),control:()=>({name:Ac("name"),color:"success"})},gateway_station:{id:"galaxy-gateway_station",title:F("galaxy_gateway_station"),desc:()=>`
          ${F("galaxy_gateway_station_desc")}
          ${F("requires_power")}
          `,reqs:{stargate:4},cost:{Money:e=>Xi("gateway_station",e,5e6,1.25,"galaxy"),Aluminium:e=>Xi("gateway_station",e,52e4,1.25,"galaxy"),Polymer:e=>Xi("gateway_station",e,35e4,1.25,"galaxy"),Neutronium:e=>Xi("gateway_station",e,17500,1.25,"galaxy")},effect(){let e=Lr(2e3),a=Lr(4500),r=Lr(50),s="";return t.tech.gateway&&t.tech.gateway>=2&&(s=`
          ${F("galaxy_gateway_support",[$(this)[0].support()])}
          `),`${s}
          ${F("plus_max_resource",[e,F("resource_Helium_3_name")])}
          ${F("plus_max_resource",[a,F("resource_Deuterium_name")])}
          ${F("plus_max_resource",[r,F("resource_Elerium_name")])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},support:()=>.5,powered:()=>oc(i.s_gate?4:0),powerBalancer:()=>!t.galaxy.hasOwnProperty("starbase")&&[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],refresh:!0,action(){return!!Os($(this)[0])&&(Nt("gateway_station","galaxy"),t.resource.Helium_3.max+=Lr(2e3),t.resource.Deuterium.max+=Lr(4500),4===t.tech.stargate&&(t.galaxy.telemetry_beacon={count:0,on:0},t.tech.stargate=5),xs($(this)[0]),!0)}},telemetry_beacon:{id:"galaxy-telemetry_beacon",title:F("galaxy_telemetry_beacon"),desc:()=>`
          ${F("galaxy_telemetry_beacon")}
          ${F("requires_power")}
          `,reqs:{stargate:5},cost:{Money:e=>Xi("telemetry_beacon",e,225e4,1.25,"galaxy"),Copper:e=>Xi("telemetry_beacon",e,685e3,1.25,"galaxy"),Alloy:e=>Xi("telemetry_beacon",e,425e3,1.25,"galaxy"),Iridium:e=>Xi("telemetry_beacon",e,177e3,1.25,"galaxy")},effect(){let e=t.tech.telemetry?1200:800;t.tech.science>=17&&(e+=25*n.scout_ship);let a=i.telemetry_beacon?e*i.telemetry_beacon:0,r="";return t.tech.gateway&&t.tech.gateway>=2&&(r=`
          ${F("galaxy_gateway_support",[$(this)[0].support()])}
          `),`${r}
          ${F("galaxy_telemetry_beacon_effect1",[e])}
          ${F("galaxy_telemetry_beacon_effect2",[a])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},support:()=>t.tech.telemetry?.75:.5,powered:()=>oc(i.s_gate?4:0),powerBalancer:()=>!t.galaxy.hasOwnProperty("starbase")&&[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],postPower(e){let a=e?i.telemetry_beacon+y():i.telemetry_beacon-y();a>t.galaxy.telemetry_beacon.count?a=t.galaxy.telemetry_beacon.count:a<0&&(a=0),i.telemetry_beacon=a,Ps($(this)[0],"galaxy","telemetry_beacon")},action(){return!!Os($(this)[0])&&(Nt("telemetry_beacon","galaxy"),xs($(this)[0])&&(t.resource.Knowledge.max+=1750),t.tech.gateway||(t.galaxy.starbase={count:0,on:0,support:0,s_max:0},t.settings.space.gateway=!0,t.tech.gateway=1,Wt()),!0)}},gateway_depot:{id:"galaxy-gateway_depot",title:F("galaxy_gateway_depot"),desc:`
          ${F("galaxy_gateway_depot")}
          `,reqs:{gateway:5},cost:{Money:e=>Xi("gateway_depot",e,4e6,1.25,"galaxy"),Neutronium:e=>Xi("gateway_depot",e,8e4,1.25,"galaxy"),Stanene:e=>Xi("gateway_depot",e,5e5,1.25,"galaxy"),Vitreloy:e=>Xi("gateway_depot",e,2500,1.25,"galaxy")},wide:!0,effect(){let e=t.tech.world_control?150:100,a=Lr(200),r=Kt(),s=k(+Lr(3e3*r).toFixed(0),1),i=k(+Lr(25e4*r).toFixed(0),1),c=k(+Lr(9001*r).toFixed(0),1),o=k(+Lr(6660*r).toFixed(0),1),n='
          ';return n+=`${F("plus_max_crates",[e])}${F("plus_max_containers",[e])}`,n+=`${F("plus_max_resource",[s,t.resource.Uranium.name])}`,n+=`${F("plus_max_resource",[i,t.resource.Nano_Tube.name])}`,n+=`${F("plus_max_resource",[c,t.resource.Neutronium.name])}`,n+=`${F("plus_max_resource",[o,t.resource.Infernite.name])}`,n+="
          ",`${n}
          ${F("galaxy_gateway_depot_effect",[a,F("resource_Elerium_name")])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(i.s_gate?10:0),action(){if(Os($(this)[0])){Nt("gateway_depot","galaxy");let e=Kt();return t.resource.Uranium.max+=Lr(3e3*e),t.resource.Nano_Tube.max+=Lr(25e4*e),t.resource.Neutronium.max+=Lr(9001*e),t.resource.Infernite.max+=Lr(6660*e),xs($(this)[0]),!0}return!1}},defense_platform:{id:"galaxy-defense_platform",title:F("galaxy_defense_platform"),desc:()=>`
          ${F("galaxy_defense_platform")}
          ${F("requires_power")}
          `,reqs:{stargate:6},cost:{Money:e=>Xi("defense_platform",e,75e4,1.25,"galaxy"),Adamantite:e=>Xi("defense_platform",e,425e3,1.25,"galaxy"),Elerium:e=>Xi("defense_platform",e,800,1.25,"galaxy"),Vitreloy:e=>Xi("defense_platform",e,1250,1.25,"galaxy"),Wrought_Iron:e=>Xi("defense_platform",e,75e3,1.25,"galaxy")},effect(){return`
          ${F("galaxy_defense_platform_effect",[20])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(i.s_gate?5:0),postPower(e){sc({el:"#gxy_stargate"},"update")},action(){return!!Os($(this)[0])&&(Nt("defense_platform","galaxy"),xs($(this)[0]),!0)},post(){sc({el:"#gxy_stargate"},"update")}}},gxy_gorddon:{info:{name:F("galaxy_gorddon"),desc:()=>F("galaxy_gorddon_desc"),control:()=>({name:di[t.galaxy.alien1.id].name,color:"advanced"})},gorddon_mission:{id:"galaxy-gorddon_mission",title:F("galaxy_gorddon_mission"),desc:F("galaxy_gorddon_mission_desc"),reqs:{xeno:2},grant:["xeno",3],queue_complete:()=>t.tech.xeno>=3?0:1,cost:{Structs:()=>({galaxy:{scout_ship:{s:"gxy_gateway",count:2,on:2},corvette_ship:{s:"gxy_gateway",count:1,on:1}}}),Helium_3:()=>+Yt(23e4).toFixed(0),Deuterium:()=>+Yt(125e3).toFixed(0)},effect:F("galaxy_gorddon_mission_effect"),action(){if(Os($(this)[0])){It(),t.galaxy.defense.gxy_gateway.scout_ship-=2,t.galaxy.defense.gxy_gorddon.scout_ship+=2,t.galaxy.defense.gxy_gateway.corvette_ship--,t.galaxy.defense.gxy_gorddon.corvette_ship++;let e=di[t.galaxy.alien1.id].name,a=di[t.galaxy.alien1.id].entity,r=di[t.galaxy.alien2.id].name;return Di(F("galaxy_gorddon_mission_result",[a,e,di[t.galaxy.alien2.id].entity,r]),"info",!1,["progress"]),!0}return!1}},embassy:{id:"galaxy-embassy",title:F("galaxy_embassy"),desc:()=>`
          ${F("galaxy_embassy")}
          ${F("requires_power_combo",[t.resource.Food.name])}
          `,reqs:{xeno:4},queue_complete:()=>1-t.galaxy.embassy.count,cost:{Money:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?3e7:0,Lumber:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?38e6:0,Stone:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?32e6:0,Furs:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?18e6:0,Wrought_Iron:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?6e6:0},effect(){let e="";return t.tech.xeno>=11&&(e=`
          ${F("plus_max_citizens",[$(this)[0].citizens()])}
          `),`
          ${F("galaxy_embassy_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
          ${e}
          ${F("interstellar_alpha_starport_effect3",[7500,t.resource.Food.name])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(i.s_gate?25:0),refresh:!0,action(){return!!(t.galaxy.embassy.count<1&&Os($(this)[0]))&&(Nt("embassy","galaxy"),xs($(this)[0]),4===t.tech.xeno&&(t.tech.xeno=5,t.galaxy.freighter={count:0,on:0,crew:0},t.galaxy.trade={max:0,cur:0,f0:0,f1:0,f2:0,f3:0,f4:0,f5:0,f6:0,f7:0,f8:0},rc($("#resources")),rr(),Di(F("galaxy_embassy_complete",[di[t.galaxy.alien1.id].name,di[t.galaxy.alien2.id].name]),"info",!1,["progress"])),!0)},citizens(){let e=20;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},dormitory:{id:"galaxy-dormitory",title:F("galaxy_dormitory"),desc:()=>`
          ${F("galaxy_dormitory")}
          ${F("requires_power")}
          `,reqs:{xeno:6},cost:{Money:e=>Xi("dormitory",e,1e7,1.25,"galaxy"),Furs:e=>Xi("dormitory",e,7e5,1.25,"galaxy"),Cement:e=>Xi("dormitory",e,12e5,1.25,"galaxy"),Plywood:e=>Xi("dormitory",e,85e3,1.25,"galaxy"),Horseshoe:()=>t.race.hooved?3:0},effect(){return`
          ${F("requires_res",[F("galaxy_embassy")])}
          ${F("plus_max_citizens",[$(this)[0].citizens()])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(3),action(){return!!Os($(this)[0])&&(Nt("dormitory","galaxy"),xs($(this)[0]),!0)},citizens(){let e=3;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},symposium:{id:"galaxy-symposium",title:F("galaxy_symposium"),desc:()=>`
          ${F("galaxy_symposium")}
          ${F("requires_power")}
          `,reqs:{xeno:6},cost:{Money:e=>Xi("symposium",e,8e6,1.25,"galaxy"),Food:e=>t.race.ravenous?0:Xi("symposium",e,t.race.artifical?45e3:125e3,1.25,"galaxy"),Lumber:e=>Xi("symposium",e,46e4,1.25,"galaxy"),Brick:e=>Xi("symposium",e,261600,1.25,"galaxy")},effect(){let e="";return t.tech.xeno>=7&&(e=`
          ${F("galaxy_symposium_effect3",[+Me(300).toFixed(2)])}
          `),`
          ${F("galaxy_symposium_effect",[1750])}
          ${F("galaxy_symposium_effect2",[650])}
          ${e}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(4),action(){return!!Os($(this)[0])&&(Nt("symposium","galaxy"),xs($(this)[0]),!0)}},freighter:{id:"galaxy-freighter",title:F("galaxy_freighter"),desc:()=>`
          ${F("galaxy_freighter")}
          ${F("galaxy_crew_fuel",[F("resource_Helium_3_name")])}
          `,reqs:{xeno:5},cost:{Money:e=>Xi("freighter",e,6e6,1.2,"galaxy"),Uranium:e=>Xi("freighter",e,1e4,1.2,"galaxy"),Adamantite:e=>Xi("freighter",e,46e4,1.2,"galaxy"),Stanene:e=>Xi("freighter",e,261600,1.2,"galaxy"),Bolognium:e=>Xi("freighter",e,66e3,1.2,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2),a="";return t.tech.banking>=13&&(a=`
          ${F("interstellar_exchange_boost",[3])}
          `),`
          ${F("galaxy_freighter_effect",[2,di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
          ${a}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("spend",[e,t.resource.Helium_3.name])}
          `},ship:{civ:()=>t.race.high_pop?3*ui.high_pop.vars()[0]:3,mil:()=>0,helium:12},special:!0,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("freighter","galaxy"),t.galaxy.freighter.on++,t.resource.Vitreloy.display=!0,!0)}}},gxy_alien1:{info:{name:()=>F("galaxy_alien",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),desc:()=>F("galaxy_alien1_desc",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home,di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),control:()=>({name:di[t.galaxy.alien1.id].name,color:"advanced"})},consulate:{id:"galaxy-consulate",title:F("galaxy_consulate"),desc:()=>F("galaxy_consulate_desc",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),reqs:{xeno:8},queue_complete:()=>1-t.galaxy.consulate.count,cost:{Money:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?9e7:0,Stone:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?75e6:0,Furs:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?3e7:0,Iron:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?45e6:0,Horseshoe:e=>t.race.hooved&&(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?10:0},effect(){return F("plus_max_citizens",[$(this)[0].citizens()])},refresh:!0,action(){return!!(Os($(this)[0])&&t.galaxy.consulate.count<1)&&(Nt("consulate","galaxy"),t.galaxy.resort={count:0,on:0},t.galaxy.super_freighter={count:0,on:0,crew:0},t.tech.xeno=9,!0)},citizens(){let e=10;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},resort:{id:"galaxy-resort",title:F("galaxy_resort"),desc:()=>`
          ${F("galaxy_resort")}
          ${F("requires_power")}
          `,reqs:{xeno:9},cost:{Money:e=>Xi("resort",e,33e6,1.25,"galaxy"),Stone:e=>Xi("resort",e,25e6,1.25,"galaxy"),Furs:e=>Xi("resort",e,1e7,1.25,"galaxy"),Oil:e=>Xi("resort",e,Yt(125e3),1.25,"galaxy")},effect(){return`
          ${F("plus_max_citizens",[3])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},effect(){let e=Lr(t.tech.world_control?1875e3:15e5),a=t.race.joyless?"":`
          ${F("city_max_entertainer",[la(2)])}
          `;return`
          ${F("plus_max_resource",[`$${e.toLocaleString()}`,F("resource_Money_name")])}
          ${a}
          ${F("space_red_vr_center_effect2",[2])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(5),action(){return!!Os($(this)[0])&&(Nt("resort","galaxy"),xs($(this)[0]),!0)}},vitreloy_plant:{id:"galaxy-vitreloy_plant",title:F("galaxy_vitreloy_plant"),desc:()=>`
          ${F("galaxy_vitreloy_plant")}
          ${F("galaxy_vitreloy_plant_desc")}
          `,reqs:{xeno:10},cost:{Money:e=>Xi("vitreloy_plant",e,35e6,1.25,"galaxy"),Cement:e=>Xi("vitreloy_plant",e,18e5,1.25,"galaxy"),Neutronium:e=>Xi("vitreloy_plant",e,25e4,1.25,"galaxy"),Iridium:e=>Xi("vitreloy_plant",e,85e4,1.25,"galaxy"),Aerogel:e=>Xi("vitreloy_plant",e,4e5,1.25,"galaxy")},effect(){return`
          ${F("galaxy_vitreloy_plant_effect",[+Pe("vitreloy_plant").toFixed(2)])}
          ${F("galaxy_vitreloy_plant_effect2",[2.5,100])}
          ${F("galaxy_vitreloy_plant_effect3",[5e4,$(this)[0].powered()])}
          `},powered:()=>oc(10),action(){return!!Os($(this)[0])&&(Nt("vitreloy_plant","galaxy"),xs($(this)[0]),!0)}},super_freighter:{id:"galaxy-super_freighter",title:F("galaxy_super_freighter"),desc:()=>`
          ${F("galaxy_super_freighter")}
          ${F("galaxy_crew_fuel",[F("resource_Helium_3_name")])}
          `,reqs:{xeno:9},cost:{Money:e=>Xi("super_freighter",e,28e6,1.2,"galaxy"),Aluminium:e=>Xi("super_freighter",e,35e5,1.2,"galaxy"),Alloy:e=>Xi("super_freighter",e,1e6,1.2,"galaxy"),Graphene:e=>Xi("super_freighter",e,75e4,1.2,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2),a="";return t.tech.banking>=13&&(a=`
          ${F("interstellar_exchange_boost",[8])}
          `),`
          ${F("galaxy_freighter_effect",[5,di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
          ${a}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("spend",[e,t.resource.Helium_3.name])}
          `},ship:{civ:()=>t.race.high_pop?5*ui.high_pop.vars()[0]:5,mil:()=>0,helium:25},special:!0,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("super_freighter","galaxy"),t.galaxy.super_freighter.on++,!0)}}},gxy_alien2:{info:{name:()=>F("galaxy_alien",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),desc:()=>F("galaxy_alien2_desc",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red,di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),control:()=>({name:di[t.galaxy.alien2.id].name,color:"danger"}),support:"foothold"},alien2_mission:{id:"galaxy-alien2_mission",title:()=>F("galaxy_alien2_mission",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),desc:()=>F("galaxy_alien2_mission_desc",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),reqs:{andromeda:4},grant:["conflict",1],queue_complete:()=>t.tech.conflict>=1?0:1,cost:{Custom(){if(t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_alien2")){let e=0;return Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]})),{label:F("galaxy_fleet_rating",[`400`]),met:!(e<400)}}return{label:F("galaxy_fleet_rating",['400']),met:!1}}},effect(){let e=0;t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_alien2")&&Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]}));let a=e>=650?`${F("galaxy_piracy_low")}`:`${F("galaxy_piracy_avg")}`;return`
          ${F("galaxy_alien2_mission_effect2",[e])}
          ${F("galaxy_alien2_mission_effect3",[a])}
          ${F("galaxy_alien2_mission_effect",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name])}
          `},action(){if(Os($(this)[0])){let e=0;if(Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]})),e>=400){if(Di(F("galaxy_alien2_mission_result2",[di[t.galaxy.alien2.id].solar.red]),"info",!1,["progress"]),e<650){let e=80;t.race.instinct&&(e/=2);let a=[];Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(r){for(let s=0;s0&&(e-=At.gxy_gateway[r].ship.rating(),a.push(r))})),Di(F("galaxy_chthonian_mission_result_losses",[a.map((e=>F(`galaxy_${e}`))).join(", ")]),"danger",!1,["progress"]);for(let e=0;e`
          ${F("galaxy_foothold")}
          ${F("requires_power_combo",[t.resource.Elerium.name])}
          `,reqs:{conflict:1},cost:{Money:e=>Xi("foothold",e,25e6,1.25,"galaxy"),Titanium:e=>Xi("foothold",e,3e6,1.25,"galaxy"),Polymer:e=>Xi("foothold",e,175e4,1.25,"galaxy"),Iridium:e=>Xi("foothold",e,9e5,1.25,"galaxy"),Bolognium:e=>Xi("foothold",e,5e4,1.25,"galaxy")},effect(){return`
          ${F("galaxy_defense_platform_effect",[50])}
          ${F("galaxy_foothold_effect",[$(this)[0].support(),di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
          ${F("galaxy_foothold_effect2",[2.5,$(this)[0].powered()])}
          `},support:()=>4,powered:()=>oc(i.s_gate?20:0),powerBalancer:()=>[{s:t.galaxy.foothold.s_max-t.galaxy.foothold.support}],action(){return!!Os($(this)[0])&&(Nt("foothold","galaxy"),xs($(this)[0]),1===t.tech.conflict&&(t.galaxy.armed_miner={count:0,on:0,crew:0,mil:0},t.tech.conflict=2,Wt(),ms()),!0)}},armed_miner:{id:"galaxy-armed_miner",title:F("galaxy_armed_miner"),desc:()=>`
          ${F("galaxy_armed_miner")}
          `,reqs:{conflict:2},cost:{Money:e=>Xi("armed_miner",e,5e6,1.25,"galaxy"),Steel:e=>Xi("armed_miner",e,18e5,1.25,"galaxy"),Stanene:e=>Xi("armed_miner",e,1975e3,1.25,"galaxy"),Vitreloy:e=>Xi("armed_miner",e,2e4,1.25,"galaxy"),Soul_Gem:e=>Xi("armed_miner",e,1,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return`
          ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
          ${F("gain",[.032,F("resource_Bolognium_name")])}
          ${F("gain",[.23,F("resource_Adamantite_name")])}
          ${F("gain",[.65,F("resource_Iridium_name")])}
          ${F("galaxy_alien2_support",[$(this)[0].support(),di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
          ${F("spend",[e,t.resource.Helium_3.name])}
          `},ship:{civ:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2,mil:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,helium:10,rating:()=>t.race.banana?4:5},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("armed_miner","galaxy"),t.galaxy.foothold.support`
          ${F("galaxy_ore_processor")}
          `,reqs:{conflict:3},cost:{Money:e=>Xi("ore_processor",e,3e6,1.25,"galaxy"),Iron:e=>Xi("ore_processor",e,5e6,1.25,"galaxy"),Coal:e=>Xi("ore_processor",e,375e4,1.25,"galaxy"),Graphene:e=>Xi("ore_processor",e,225e4,1.25,"galaxy")},effect(){return`
          ${F("galaxy_ore_processor_effect",[10])}
          ${F("galaxy_alien2_support",[$(this)[0].support(),di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
          `},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("ore_processor","galaxy"),t.galaxy.foothold.supportXi("scavenger",e,75e5,1.25,"galaxy"),Alloy:e=>Xi("scavenger",e,125e4,1.25,"galaxy"),Aluminium:e=>Xi("scavenger",e,68e5,1.25,"galaxy"),Neutronium:e=>Xi("scavenger",e,75e3,1.25,"galaxy"),Elerium:e=>Xi("scavenger",e,750,1.25,"galaxy")},effect(){let e=Et("gxy_alien2"),a=Math.round(25e3*e),r=+Yt($(this)[0].ship.helium).toFixed(2),s=t.race.cataclysm?`
          ${F("galaxy_scavenger_effect2_cata",[+(100*e*.75).toFixed(1)])}
          `:`
          ${F("galaxy_scavenger_effect2",[+(100*e/4).toFixed(1)])}
          `;return`
          ${F("galaxy_scavenger_effect",[a])}
          ${s}
          ${F("galaxy_alien2_support",[$(this)[0].support(),di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          ${F("spend",[r,t.resource.Helium_3.name])}
          `},ship:{civ:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,mil:()=>0,helium:12},support:()=>-1,powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("scavenger","galaxy"),t.galaxy.foothold.supportF("galaxy_chthonian"),desc:()=>F("galaxy_chthonian_desc",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),control:()=>({name:di[t.galaxy.alien2.id].name,color:"danger"})},chthonian_mission:{id:"galaxy-chthonian_mission",title:()=>F("galaxy_alien2_mission",[F("galaxy_chthonian")]),desc:()=>F("galaxy_alien2_mission_desc",[F("galaxy_chthonian")]),reqs:{chthonian:1},grant:["chthonian",2],queue_complete:()=>t.tech.chthonian>=2?0:1,cost:{Custom(){if(t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_chthonian")){let e=0;return Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]})),{label:F("galaxy_fleet_rating",[`1250`]),met:!(e<1250)}}return{label:F("galaxy_fleet_rating",['1250']),met:!1}}},effect(){let e=0;t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_chthonian")&&Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]}));let a=e>=4500?`${F("galaxy_piracy_low")}`:e>=2500?`${F("galaxy_piracy_avg")}`:`${F("galaxy_piracy_high")}`;return`
          ${F("galaxy_alien2_mission_effect2",[e])}
          ${F("galaxy_alien2_mission_effect3",[a])}
          ${F("galaxy_alien2_mission_effect",[F("galaxy_chthonian")])}
          `},action(){if(Os($(this)[0])){let e=0;if(Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=At.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]})),e>=1250){let a=500,r=[];Di(F("galaxy_chthonian_mission_result"),"info",!1,["progress"]),e>=2500&&(a=e>=4500?80:160),t.race.instinct&&(a/=2),Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(e){for(let s=0;s0&&(a-=At.gxy_gateway[e].ship.rating(),r.push(e))})),Di(F("galaxy_chthonian_mission_result_losses",[r.map((e=>F(`galaxy_${e}`))).join(", ")]),"danger",!1,["progress"]);for(let e=0;e`
          ${F("galaxy_minelayer")}
          `,reqs:{chthonian:2},cost:{Money:e=>Xi("minelayer",e,9e6,1.25,"galaxy"),Iron:e=>Xi("minelayer",e,48e5,1.25,"galaxy"),Nano_Tube:e=>Xi("minelayer",e,125e4,1.25,"galaxy"),Nanoweave:e=>Xi("minelayer",e,1e5,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return`
          ${F("galaxy_defense_platform_effect",[$(this)[0].ship.rating()])}
          ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
          ${F("spend",[e,t.resource.Helium_3.name])}
          `},ship:{civ:()=>0,mil:()=>t.race.high_pop?1*ui.high_pop.vars()[0]:1,helium:8,rating:()=>t.race.banana?35:50},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("minelayer","galaxy"),t.galaxy.minelayer.on++,!0)},postPower(){sc({el:"#gxy_chthonian"},"update")},post(){sc({el:"#gxy_chthonian"},"update")}},excavator:{id:"galaxy-excavator",title:F("galaxy_excavator"),desc:()=>`
          ${F("galaxy_excavator")}
          `,reqs:{chthonian:3},cost:{Money:e=>Xi("excavator",e,12e6,1.25,"galaxy"),Polymer:e=>Xi("excavator",e,44e5,1.25,"galaxy"),Iridium:e=>Xi("excavator",e,36e5,1.25,"galaxy"),Mythril:e=>Xi("excavator",e,18e4,1.25,"galaxy")},effect(){return`
          ${F("gain",[+Pe("excavator").toFixed(3),F("resource_Orichalcum_name")])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(8),powerBalancer:()=>[{r:"Orichalcum",p:Pe("excavator")}],action(){return!!Os($(this)[0])&&(Nt("excavator","galaxy"),xs($(this)[0]),!0)}},raider:{id:"galaxy-raider",title:F("galaxy_raider"),desc:()=>`
          ${F("galaxy_raider")}
          `,reqs:{chthonian:3},cost:{Money:e=>Xi("raider",e,12e6,1.25,"galaxy"),Titanium:e=>Xi("raider",e,125e4,1.25,"galaxy"),Bolognium:e=>Xi("raider",e,6e5,1.25,"galaxy"),Vitreloy:e=>Xi("raider",e,125e3,1.25,"galaxy"),Stanene:e=>Xi("raider",e,825e3,1.25,"galaxy")},effect(){let e=+Yt($(this)[0].ship.helium).toFixed(2);return Et("gxy_chthonian"),`
          ${F("galaxy_ship_rating",[$(this)[0].ship.rating()])}
          ${F("gain",[.65,F("resource_Deuterium_name")])}
          ${F("gain",[.05,F("resource_Vitreloy_name")])}
          ${F("gain",[2.3,F("resource_Polymer_name")])}
          ${F("gain",[.8,F("resource_Neutronium_name")])}
          ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
          ${F("spend",[e,t.resource.Helium_3.name])}
          `},ship:{civ:()=>0,mil:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2,helium:18,rating:()=>t.race.banana?9:12},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(Nt("raider","galaxy"),t.galaxy.raider.on++,!0)},postPower(){sc({el:"#gxy_chthonian"},"update")},post(){sc({el:"#gxy_chthonian"},"update")}}}};function Tt(e){let t="space";return"int_"===e.substr(0,4)?t="interstellar":"prtl_"===e.substr(0,5)?t="portal":"gxy_"===e.substr(0,4)?t="galaxy":"tau_"===e.substr(0,4)&&(t="tauceti"),t}function Et(e,a,r){if(t.tech.piracy&&!t.race.truepath){let s=0,c=["dreadnought","cruiser_ship","frigate_ship","corvette_ship","scout_ship"];for(let a=0;ao?o:s))/o)*l+(1-l))*(a?1:Et("gxy_stargate")):(1-(o-(s>o?o:s))/o)*l+(1-l)}return 1}function It(){let e=["protoplasm",t.race.species];t.city.hasOwnProperty("surfaceDwellers")&&e.push(...t.city.surfaceDwellers),t.custom.hasOwnProperty("race0")||e.push("custom");let a=Object.keys(di).filter((function(t){return!["demonic","eldritch"].includes(di[t].type)&&!e.includes(t)})),r=Cc(a);t.galaxy.alien1={id:a[r]},e.push(a[r]),a=Object.keys(di).filter((function(t){return!["angelic"].includes(di[t].type)&&!e.includes(t)}));let s=Cc(a);t.galaxy.alien2={id:a[s]}}function Kt(){let e=1;return t.race.pack_rat&&(e*=1.05),t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),e*=t.tech.world_control?2:1,e}const Lt={satellite:{count:0},propellant_depot:{count:0},gps:{count:0},nav_beacon:{count:0,on:0},moon_base:{count:0,on:0,support:0,s_max:0},iridium_mine:{count:0,on:0},helium_mine:{count:0,on:0},observatory:{count:0,on:0},spaceport:{count:0,on:0,support:0,s_max:0},red_tower:{count:0,on:0},living_quarters:{count:0,on:0},vr_center:{count:0,on:0},garage:{count:0},red_mine:{count:0,on:0},fabrication:{count:0,on:0},red_factory:{count:0,on:0},exotic_lab:{count:0,on:0},ziggurat:{count:0},space_barracks:{count:0,on:0},biodome:{count:0,on:0},laboratory:{count:0,on:0},geothermal:{count:0,on:0},swarm_plant:{count:0},swarm_control:{count:0,support:0,s_max:0},swarm_satellite:{count:0},gas_mining:{count:0,on:0},gas_storage:{count:0},star_dock:{count:0,ship:0,probe:0,template:"human"},outpost:{count:0,on:0},drone:{count:0},oil_extractor:{count:0,on:0},space_station:{count:0,on:0,support:0,s_max:0},iridium_ship:{count:0,on:0},elerium_ship:{count:0,on:0},elerium_prospector:{count:0,on:0},iron_ship:{count:0,on:0},elerium_contain:{count:0,on:0},e_reactor:{count:0,on:0},world_collider:{count:0},world_controller:{count:0,on:0},starport:{count:0,on:0,support:0,s_max:0},mining_droid:{count:0,on:0,adam:0,uran:0,coal:0,alum:0},processing:{count:0,on:0},habitat:{count:0,on:0},fusion:{count:0,on:0},laboratory:{count:0,on:0},exchange:{count:0,on:0},warehouse:{count:0},xfer_station:{count:0,on:0},cargo_yard:{count:0},cruiser:{count:0,on:0},dyson:{count:0},nexus:{count:0,on:0,support:0,s_max:0},harvester:{count:0,on:0},far_reach:{count:0,on:0},stellar_engine:{count:0,mass:8,exotic:0},mass_ejector:{count:0,on:0,total:0,mass:0,Food:0,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0},stargate:{count:0},gateway_station:{count:0,on:0},s_gate:{count:0,on:0},starbase:{count:0,on:0,support:0,s_max:0},bolognium_ship:{count:0,on:0,crew:0},scout_ship:{count:0,on:0,crew:0,mil:0},corvette_ship:{count:0,on:0,crew:0,mil:0},frigate_ship:{count:0,on:0,crew:0,mil:0},cruiser_ship:{count:0,on:0,crew:0,mil:0},dreadnought:{count:0,on:0,crew:0,mil:0},foothold:{count:0,on:0,support:0,s_max:0},turret:{count:0,on:0},carport:{count:0,damaged:0,repair:0},war_droid:{count:0,on:0},repair_droid:{count:0,on:0},war_drones:{count:0,on:0},sensor_drone:{count:0,on:0},attractor:{count:0,on:0}};function Nt(e,a){a||(a="space"),t[a][e]||(t[a][e]=Lt[e]),t[a][e].count++}function Dt(e,t){return e&&t?jt[e][t]:jt}function Bt(e,t,a){switch(e){case"space":return Gt(jt,t,a);case"interstellar":return Gt(St,t,a);case"galaxy":return Gt(At,t,a)}}function Gt(e,a,r){let s=t.race.truepath?"truepath":"standard";if(e[a][r].hasOwnProperty("path")&&!e[a][r].path.includes(s))return!1;var i=!0;return Object.keys(e[a][r].reqs).forEach((function(s){(!t.tech[s]||t.tech[s]=e[a][r].grant[1]&&(i=!1),i}function Rt(){(t.settings.tabLoad||1===t.settings.civTabs)&&(Ht("inner"),t.race.truepath&&Ht("outer"),Ut(),Wt())}function Ht(e){if(e||(e=5===t.settings.spaceTabs?"outer":"inner"),!t.settings.tabLoad&&(1!==t.settings.civTabs||![1,5].includes(t.settings.spaceTabs)||1===t.settings.civTabs&&1===t.settings.spaceTabs&&"inner"!==e||5===t.settings.spaceTabs&&"outer"!==e))return;let a="inner"===e?$("#space"):$("#outerSol");if(rc(a),a.append($(`

          ${F("inner"===e?"tab_space":"tab_outer_space")}

          `)),!t.settings.showSpace)return!1;let r=[];Object.keys(jt).forEach((function(e){t.race.orbit_decayed||t.race.cataclysm?"spc_home"!==e&&(r.push(e),(t.race.orbit_decayed&&"spc_red"===e||t.race.cataclysm&&"spc_moon"===e)&&r.push("spc_home")):r.push(e)})),r.forEach((function(r){let s=r.replace("spc_","");if(t.settings.space[`${s}`]){if(t.race.truepath&&jt[r].info.zone!==e)return;let s="string"==typeof jt[r].info.name?jt[r].info.name:jt[r].info.name(),i=!(!t.race.orbit_decayed&&!t.race.cataclysm);if(i&&"spc_home"!==r||!i){if(jt[r].info.support){let e=jt[r].info.support;t.space[e].hasOwnProperty("support")||(t.space[e].support=0,t.space[e].s_max=0),a.append(`

          ${s}

          {{ support }}/{{ s_max }}
          `),sc({el:`#sr${r}`,data:t.space[e]})}else a.append(`

          ${s}

          `);t.race.truepath&&jt[r].info.hasOwnProperty("syndicate")&&jt[r].info.syndicate()&&t.tech.syndicate&&($(`#${r}`).append(`
          `),$(`#${r}synd`).append(`${F("space_syndicate")} `),$(`#${r}synd`).append(`${F("space_scan_effectiveness")} `),$(`#${r}synd`).append(`${F("space_overkill")} `),sc({el:`#${r}synd`,data:t.space.syndicate,methods:{threat(e){if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let t=ht(e,!0);if(t.s>=10)return t.s>=50?t.r:Math.round(t.r*t.s*.02)}return"???"},scan:e=>t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")?+((ht(e,!0).s+25)/1.25).toFixed(1)+"%":F("galaxy_piracy_none"),overkill(e){if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let t=ht(e,!0);return t.s>=100?t.o:0}return 0}}}),jt[r].info.hasOwnProperty("extra")&&jt[r].info.extra(r))}Ti(r,(function(){return"string"==typeof jt[r].info.desc?jt[r].info.desc:jt[r].info.desc()}),{elm:`#${r} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(jt[r]).forEach((function(t){"info"!==t&&Gt(jt,r,t)&&fs(jt[r][t],"inner"===e?"space":"outerSol",t)}))}}))}function Ut(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||2!==t.settings.spaceTabs))return;let e=$("#interstellar");if(rc(e),e.append($(`

          ${F("tab_interstellar")}

          `)),!t.settings.showDeep)return!1;Object.keys(St).forEach((function(a){let r=a.replace("int_","");if(t.settings.space[`${r}`]){let r="string"==typeof St[a].info.name?St[a].info.name:St[a].info.name();if(St[a].info.support){let s=St[a].info.support;t.interstellar[s].hasOwnProperty("support")||(t.interstellar[s].support=0,t.interstellar[s].s_max=0),e.append(`

          ${r}

          {{ support }}/{{ s_max }}
          `),sc({el:`#sr${a}`,data:t.interstellar[s]})}else e.append(`

          ${r}

          `);Ti(a,(function(){return"string"==typeof St[a].info.desc?St[a].info.desc:St[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(St[a]).forEach((function(e){"info"!==e&&Gt(St,a,e)&&fs(St[a][e],"interstellar",e)}))}}))}function Wt(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||3!==t.settings.spaceTabs))return;let e=$("#galaxy");if(rc(e),e.append($(`

          ${F("tab_galactic")}

          `)),!t.settings.showGalactic)return!1;!function(e,a){if(t.tech.piracy&&!t.race.truepath){let r=$(`

          ${F("galaxy_armada")}

          `);e.append(r);let s=t.tech.world_control?F("civics_garrison_peacekeepers"):F("civics_garrison_soldiers");r.append($("|")),r.append($(`${s} {{ g.workers | stationed }} / {{ g.max | s_max }}`)),r.append($("|")),r.append($(`${F("job_crew_mil")} {{ g.crew }}`)),r.append($("|")),r.append($(`${F("job_crew_civ")} {{ c.workers }} / {{ c.max }}`)),sc({el:`#h${a}`,data:{g:t.civic.garrison,c:t.civic.crew},filters:{stationed:e=>qe(),s_max:e=>qe(!0)}}),["soldier","crew1","crew2"].forEach((function(e){Ti(`h${a}${e}`,(function(){switch(e){case"soldier":return ve();case"crew1":return F("civics_garrison_crew_desc");case"crew2":return F("job_crew_desc")}}),{elm:`#h${a} span.${e}`})}));let i=$(`
          `);e.append(i);let c=["scout_ship","corvette_ship","frigate_ship","cruiser_ship","dreadnought"],o=[];for(let e=0;e<6;e++){let e=$('
          ');o.push(e),i.append(e)}for(let e=0;e${At.gxy_gateway[c[e]].title}`);o[e+1].append(t)}o[0].append($("")),o[0].append($(`${At.gxy_gateway.info.name}`));for(let e=0;e{{ gateway.${c[e]} }}`);o[e+1].append(t)}Object.keys(t.galaxy.defense).forEach((function(e){let a=e.substring(4);if(t.settings.space[a]&&"gateway"!==a){let r=$(`${"string"==typeof At[e].info.name?At[e].info.name:At[e].info.name()}`);o[0].append(r);for(let r=0;r'),s=$(`«`),i=$(`{{ ${a}.${c[r]} }}`),n=$(`»`);o[r+1].append(t),t.append(s),t.append(i),t.append(n)}}})),sc({el:`#${a}`,data:{stargate:t.galaxy.defense.gxy_stargate,gateway:t.galaxy.defense.gxy_gateway,gorddon:t.galaxy.defense.gxy_gorddon,alien1:t.galaxy.defense.gxy_alien1,alien2:t.galaxy.defense.gxy_alien2,chthonian:t.galaxy.defense.gxy_chthonian,t:t.tech},methods:{sub(e,a){if(t.galaxy.defense[e][a]>0){let r=y();r>t.galaxy.defense[e][a]&&(r=t.galaxy.defense[e][a]),t.galaxy.defense.gxy_gateway[a]+=r,t.galaxy.defense[e][a]-=r}},add(e,a){if(t.galaxy.defense.gxy_gateway[a]>0){let r=y();r>t.galaxy.defense.gxy_gateway[a]&&(r=t.galaxy.defense.gxy_gateway[a]),t.galaxy.defense.gxy_gateway[a]-=r,t.galaxy.defense[e][a]+=r}}}}),Object.keys(t.galaxy.defense).forEach((function(e){let a=e.substring(4);t.settings.space[a]&&Ti(`armada${a}`,(function(){return`
          ${"string"==typeof At[e].info.desc?At[e].info.desc:At[e].info.desc()}
          `}))}));for(let e=0;e`);e.append(s);let i=$(`

          ${r}

          `);s.append(i),t.tech.xeno&&t.tech.xeno>=3&&s.append(`{{ r.control().name }}`);let c={el:`#${a}`,data:{r:At[a].info},methods:{threat(e){let a=t.race.infiltrator?1:2;if(t.galaxy.defense[e].scout_ship>=a){let t=100*(1-Et(e,!0));return t=t<1?Math.ceil(t):Math.round(t),0===t?"has-text-success":t<=20?"has-text-advanced":t<=40?"has-text-info":t<=60?"has-text-warning":t<=80?"has-text-caution":"has-text-danger"}return"has-text-danger"}},filters:{pirate(e){let a=t.race.infiltrator?1:2;if(t.galaxy.defense[e].scout_ship>=a){let a=100*(1-Et(e,!0));a=a<1?Math.ceil(a):Math.round(a);let r=t.race.infiltrator?3:4;return t.galaxy.defense[e].scout_ship>=r?`${a}%`:F(0===a?"galaxy_piracy_none":a<=20?"galaxy_piracy_vlow":a<=40?"galaxy_piracy_low":a<=60?"galaxy_piracy_avg":a<=80?"galaxy_piracy_high":"galaxy_piracy_vhigh")}return"???"},defense:e=>Et(e,!0,!0)}};if(At[a].info.support){let e=At[a].info.support;t.galaxy[e]&&(t.galaxy[e].hasOwnProperty("support")||(t.galaxy[e].support=0,t.galaxy[e].s_max=0),s.append('{{ s.support }}/{{ s.s_max }}'),c.data.s=t.galaxy[e])}t.tech.piracy&&s.append(`
          ${F("galaxy_piracy_threat",[di[t.galaxy.alien2.id].name])}{{ '${a}' | pirate }}|${F("galaxy_armada")}: {{ '${a}' | defense }}
          `),sc(c),Ti(a,(function(){return"string"==typeof At[a].info.desc?At[a].info.desc:At[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Ti(a,(function(){return F("galaxy_control",[At[a].info.control().name,r])}),{elm:`#${a} .regionControl`,classes:"has-background-light has-text-dark"}),Object.keys(At[a]).forEach((function(e){"info"!==e&&Gt(At,a,e)&&fs(At[a][e],"galaxy",e)}))}}))}function Qt(e){return t.tech.space_housing&&(e*=.8**t.tech.space_housing),e}function Zt(e){return t.tech.solar&&t.tech.solar>=5&&c.iron_ship&&(e*=.95**c.iron_ship),e}function Vt(e){if(t.space.swarm_plant){let a=t.tech.swarm?.88:.94;t.tech.swarm>=3&&(a-=u/100),a<.05&&(a=.05),e*=a**t.space.swarm_plant.count}return e}function Jt(e,a,r){return r=r||{},"heavy"===t.race.universe&&(e*=1.25+.5*nc("heavy")),t.race.truepath&&(e*=a?2.5:1.25),t.city.mass_driver&&i.mass_driver?e*=(t.race.truepath?.94:.95)**i.mass_driver:r.mass_driver&&(e*=.95**r.mass_driver),t.stats.achieve.heavyweight&&(e*=.96**t.stats.achieve.heavyweight.l),t.city.ptrait.includes("dense")&&(e*=Si.dense.vars()[2]),t.race.cataclysm&&(e*=.2),t.race.heavy&&(e*=1+ui.heavy.vars()[0]/100),Tc("launch_day")&&(e*=.95),e}function Yt(e){return"heavy"===t.race.universe&&(e*=1.2+.3*nc("heavy")),t.stats.achieve.heavyweight&&(e*=.96**t.stats.achieve.heavyweight.l),t.race.heavy&&(e*=1+ui.heavy.vars()[0]/100),Tc("launch_day")&&(e*=.95),e}function Xt(){let e={red:di[t.race.species].solar.red,hell:di[t.race.species].solar.hell,gas:di[t.race.species].solar.gas,gas_moon:di[t.race.species].solar.gas_moon,dwarf:di[t.race.species].solar.dwarf,titan:_i[di[t.race.species].type].solar.titan,enceladus:_i[di[t.race.species].type].solar.enceladus,triton:_i[di[t.race.species].type].solar.triton,eris:_i[di[t.race.species].type].solar.eris};if("custom"===t.race.species)for(let a of["titan","enceladus","triton","eris"])t.custom.race0.hasOwnProperty(a)&&(e[a]=t.custom.race0[a]);return e}const ea=["l","h","a","e","m","mg"],ta={standard:{name:F("universe_standard"),desc:F("universe_standard_desc"),effect:F("universe_standard_effect")},heavy:{name:F("universe_heavy"),desc:F("universe_heavy_desc"),effect:F("universe_heavy_effect",[5])},antimatter:{name:F("universe_antimatter"),desc:F("universe_antimatter_desc"),effect:F("universe_antimatter_effect")},evil:{name:F("universe_evil"),desc:F("universe_evil_desc"),effect:F("universe_evil_effect")},micro:{name:F("universe_micro"),desc:F("universe_micro_desc"),effect:F("universe_micro_effect",[75])},magic:{name:F("universe_magic"),desc:F("universe_magic_desc"),effect:F("universe_magic_effect")}};function aa(){let e=[];if(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=4&&t.custom.hasOwnProperty("planet")&&Object.keys(ta).forEach((function(a){let r=Yc(a);t.custom.planet.hasOwnProperty(r)&&t.custom.planet[r].s&&e.push(`${r}:s`)})),t.race.geck&&t.race.geck>0){let e=$(`
          ${F("gecks_remaining")}: {{ geck }}
          `);$("#evolution").append(e),sc({el:"#geck",data:t.race})}if(0===t.race.probes)bs({custom:e});else{let a=!1;for(let r=0;r'),s={ascended:{},technophobe:t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l?t.stats.achieve.technophobe.l:0};if(a?a.append(r):$("#city").append(r),r.append(`

          ${F("genelab_title")}

          - ${F("genelab_genes")} {{ g.genes }} - ${F("trait_untapped_name")}: {{ g.genes | untapped }}
          `),a){r.append(`\n
          ${F("achieve_ascended_name")}
          \n `);let e=$("
          ");r.append(e),Object.keys(ta).forEach((function(a){s.ascended[a]=t.stats.achieve.ascended&&t.stats.achieve.ascended.hasOwnProperty(Yc(a))?t.stats.achieve.ascended[Yc(a)]:0,e.append(`\n
          ${F("universe_"+a)}
          \n `)})),r.append(`\n
          ${F("achieve_technophobe_name")}
          \n
          \n
          \n
          \n `)}let i=$(`
          ${F("genelab_name")}
          ${F("genelab_entity")}
          ${F("genelab_home")}
          ${F("genelab_desc")}
          `);r.append(i);let c=$(`
          \n
          ${F("genelab_red")}
          \n
          ${F("genelab_hell")}
          \n
          ${F("genelab_gas")}
          \n
          ${F("genelab_gas_moon")}
          \n
          ${F("genelab_dwarf")}
          `);r.append(c);let o=$(`
          \n
          ${F("genelab_titan")}
          \n
          ${F("genelab_enceladus")}
          \n
          ${F("genelab_triton")}
          \n
          ${F("genelab_eris")}
          `);r.append(o);let n=$('
          ');r.append(n);let l=!1,u=`
          ${F("genelab_genus")}
          ",n.append($(u));let d=`
          ${F("genelab_traits")}
          ",n.append($(d));let h=`\n
          \n \n
          \n
          \n
          \n \n \n \n
          \n
          \n {{ err.msg }}\n
          \n `;a||(h+=`\n
          \n \n
          \n `),r.append(h);var g=t.hasOwnProperty("custom")&&t.custom.hasOwnProperty("race0")?{name:t.custom.race0.name,desc:t.custom.race0.desc,entity:t.custom.race0.entity,home:t.custom.race0.home,red:t.custom.race0.red,hell:t.custom.race0.hell,gas:t.custom.race0.gas,gas_moon:t.custom.race0.gas_moon,dwarf:t.custom.race0.dwarf,titan:t.custom.race0.titan||Xt().titan,enceladus:t.custom.race0.enceladus||Xt().enceladus,triton:t.custom.race0.triton||Xt().triton,eris:t.custom.race0.eris||Xt().eris,genes:0,genus:t.custom.race0.genus,traitlist:t.custom.race0.traits}:{name:"Zombie",desc:"Zombies aren't so much a species as they are the shambling remains of a race who succumbed to a nightmarish virus. Yet somehow they continue to drone on.",entity:"rotting bipedal creatures",home:"Grave",red:"Brains",hell:"Rigor Mortis",gas:"Decompose",gas_moon:"Bones",dwarf:"Double Tap",titan:"Necromancer",enceladus:"Skeleton",triton:"Rot",eris:"Zombieland",genes:10,genus:l,traitlist:[]};for(let e=g.traitlist.length-1;e>=0;e--)ui.hasOwnProperty(g.traitlist[e])&&"major"===ui[g.traitlist[e]].type||g.traitlist.splice(e,1);g.genes=Sc(g,!!a&&s);let f={msg:""};sc({el:"#celestialLab",data:{g,w:s,err:f},methods:{val(e){"technophobe"===e?s.technophobe<0?s.technophobe=0:s.technophobe>5&&(s.technophobe=5):s.ascended[e]<0?s.ascended[e]=0:s.ascended[e]>5&&(s.ascended[e]=5)},geneEdit(){g.genes=Sc(g,!!a&&s)},setRace(){Sc(g)>=0&&g.name.length>0&&g.desc.length>0&&g.entity.length>0&&g.home.length>0&&g.red.length>0&&g.hell.length>0&&g.gas.length>0&&g.gas_moon.length>0&&g.dwarf.length>0&&(t.custom.race0={name:g.name,desc:g.desc,entity:g.entity,home:g.home,red:g.red,hell:g.hell,gas:g.gas,gas_moon:g.gas_moon,dwarf:g.dwarf,titan:g.titan,enceladus:g.enceladus,triton:g.triton,eris:g.eris,genus:g.genus,traits:g.traitlist},function(){O(),Zi("reset",{end:"ascend"});let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=t.city.geology,n=mc("ascend");t.stats.ascend++,Fc(),t.prestige.Phage.count+=n.phage,t.stats.phage+=n.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=n.plasmid,t.stats.antiplasmid+=n.plasmid):(t.prestige.Plasmid.count+=n.plasmid,t.stats.plasmid+=n.plasmid),t.prestige.Harmony.count=parseFloat((t.prestige.Harmony.count+n.harmony).toFixed(2)),t.stats.harmony=parseFloat((t.stats.harmony+n.harmony).toFixed(2)),c.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),void 0===t.tech.world_control&&Xc("cult_of_personality");let l=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0&&l++})),l>=4&&Xc("miners_dream"),t.galaxy.hasOwnProperty("dreadnought")&&0!==t.galaxy.dreadnought.count||Xc("dreaded"),t.race.modified||"synth"!==t.race.species&&"nano"!==t.race.species||!t.race.emfield||eo("digital_ascension"),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),so();let u=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!0},d>0&&(t.race.corruption=d),u&&(t.race.srace=u),Object.keys(o).forEach((function(e){o[e]+=.02})),Q({orbit:s,biome:i,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}())},allowed:e=>!("synthetic"===g.genus||!["deconstructor","imitation"].includes(e)||(g.traitlist.includes(e)&&g.traitlist.splice(g.traitlist.indexOf(e),1),0)),reset(){g.name="",g.desc="",g.entity="",g.home="",g.red="",g.hell="",g.gas="",g.gas_moon="",g.dwarf="",g.titan="",g.enceladus="",g.triton="",g.eris="",g.genus=l,g.traitlist=[],g.genes=Sc(g,!!a&&s)},customImport(){let e=document.getElementById("customFile").files[0];if(e){let r=new FileReader;r.readAsText(e,"UTF-8"),r.onload=function(r){let i="";try{i=JSON.parse(r.target.result)}catch{return void(f.msg=F("string_pack_error",[e.name]))}let c=!1;if(Object.keys(g).forEach((function(e){i[e]&&typeof g[e]!=typeof i[e]&&(c=!0)})),c)return f.msg=F("string_pack_error",[e.name]),void console.log("format fail");Object.keys(g).forEach((function(e){i[e]&&(g[e]=i[e])})),["name","home","red","hell","gas","gas_moon","dwarf","titan","enceladus","triton","eris"].forEach((function(e){!i[e]&&["titan","enceladus","triton","eris"].includes(e)?g[e]=F(`genus_${g.genus}_solar_${e}`):g[e].length>20&&(g[e]=g[e].substring(0,20))})),g.entity.length>40&&(g.entity=g.entity.substring(0,40)),g.desc.length>255&&(g.desc=g.desc.substring(0,255)),a||t.stats.achieve[`genus_${g.genus}`]&&t.stats.achieve[`genus_${g.genus}`].l>0||(g.genus=l);let o=[];for(let e=0;e{const r=document.createElement("a"),s=new Blob([e],{type:"text/plain"});r.href=URL.createObjectURL(s),r.download=t,r.click(),URL.revokeObjectURL(r.href)})(JSON.stringify(g,null,4),`evolve-custom-${g.name}.txt`)}},filters:{cost(e){if(ui[e].val>=0){let r=2;a?r+=s.technophobe:t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1&&(r+=t.stats.achieve.technophobe.l);let i=ui[e].val,c=0;for(let e=0;e=0&&c++;return g.traitlist.includes(e)&&c--,c>r&&(i+=c-r),i}return ui[e].val},untapped:e=>`+${e>0?+(100*(e/(e+20)/10+24e-5)).toFixed(3):0}%`}}),Object.keys(li).forEach((function(e){t.stats.achieve[`genus_${e}`]&&t.stats.achieve[`genus_${e}`].l>0&&Ti(`celestialLabgenusSelection${e}`,(function(){let t=$(`
          ${F(`genelab_genus_${e}_desc`)}
          `);return Object.keys(li[e]).forEach((function(e){if(ui[e]){let a=$("
          ");Hc(a,e,{trank:1}),t.append(a)}})),t}),{elm:`#celestialLab .genus_selection .${e}`,classes:"w30",wide:!0})})),Object.keys(p).sort().forEach((function(e){ui.hasOwnProperty(e)&&"major"===ui[e].type&&Ti(`celestialLabtraitSelection${e}`,(function(){let t=$("
          ");return Hc(t,e,{trank:1}),t}),{elm:`#celestialLab .trait_selection .t${e}`,classes:"w30",wide:!0})}))}function sa(a){a||t.race.noexport||(M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),Xc(`biome_${t.city.biome}`),Xc(`genus_${di[t.race.species].type}`),Xc("lamentis"),"junker"===t.race.species&&eo("the_misery"),t.race.noexport="Planet",rc($("#city")),t.settings.showCity=!0,t.settings.showCivic=!1,t.settings.showResearch=!1,t.settings.showResources=!1,t.settings.showGenetics=!1,t.settings.showSpace=!1,t.settings.showDeep=!1,t.settings.showGalactic=!1,t.settings.showPortal=!1,t.settings.spaceTabs=0);let r=$('
          '),s={ascended:{},lamentis:t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l?t.stats.achieve.lamentis.l:0};a?a.append(r):$("#city").append(r),r.append(`

          ${F("planetlab_title")}

          - ${F("planetlab_points")} {{ p.pts }}
          `);let i=$('
          ');r.append(i);let c=!1,o=`
          ${F("wiki_planet_biome")}
          ",i.append($(o));let n=`
          ${F("wiki_planet_trait")}
          ",i.append($(n));let l={},u=["Copper","Iron","Aluminium","Coal","Oil","Titanium","Uranium"];t.stats.achieve.whitehole&&u.push("Iridium");let d=`
          ${F("planetlab_res")}
          ",i.append($(d));let _={biome:c,pts:0,traitlist:[],geology:l,orbit:t.city.calendar.orbit};if(t.custom.hasOwnProperty("planet")){let e=Yc();if(t.custom.planet.hasOwnProperty(e)){let a="s";t.custom.planet[e][a]&&(_=zc(t.custom.planet[e][a]),_.orbit=t.city.calendar.orbit,u.forEach((function(e){_.geology.hasOwnProperty(e)?_.geology[e]*=100:_.geology[e]=0})))}}_.pts=ia(_);let p=`
          \n
          \n \n
          \n `;a||(p+=`\n
          \n \n
          \n `),p+="
          ",r.append(p),sc({el:"#celestialLab",data:{p:_,w:s},methods:{pEdit(){_.pts=ia(_)},setPlanet(){if(ia(_)>=0){Object.keys(_.geology).forEach((function(e){0===_.geology[e]?delete _.geology[e]:_.geology[e]/=100})),t.custom.hasOwnProperty("planet")||(t.custom.planet={});let a=Yc();t.custom.planet.hasOwnProperty(a)||(t.custom.planet[a]={s:!1});let r="s";t.custom.planet[a][r]=zc(_),delete t.custom.planet[a][r].pts,function(a){O(),Zi("reset",{end:"terraform"});let r=t.race.species,s=t.race.gods,i=t.city.calendar.orbit,c=a.biome,o=a.traitlist,n=a.geology,l=mc("terraform");t.stats.terraform++,Fc(),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Harmony.count=parseFloat((t.prestige.Harmony.count+l.harmony).toFixed(2)),t.stats.harmony=parseFloat((t.stats.harmony+l.harmony).toFixed(2)),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),void 0===t.tech.world_control&&Xc("cult_of_personality");let u=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0&&u++})),u>=4&&Xc("miners_dream"),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross"),so();let d=!!t.race.hasOwnProperty("srace")&&t.race.srace,_=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:r,old_gods:s,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended,rejuvenated:!0},_>0&&(t.race.corruption=_),d&&(t.race.srace=d),Q({orbit:i,biome:c,ptrait:o,geology:n}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(_)}},reset(){_.traitlist=[],Object.keys(_.geology).forEach((function(e){_.geology[e]=0})),_.pts=ia(_)},less(e){_.geology[e]-=y(),_.geology[e]<-20&&(_.geology[e]=-20)},more(e){_.geology[e]+=y();let a=30;t.stats.achieve.whitehole&&(a+=5*t.stats.achieve.whitehole.l),"eden"===_.biome&&(a+=5),_.geology[e]>a&&(_.geology[e]=a)}},filters:{res:e=>_.geology[e]}})}function ia(e,a){let r=("eden"===e.biome?0:10)+(t.stats.achieve.lamentis?10*t.stats.achieve.lamentis.l:0);t.race.truepath&&(r*=2),r-=e.traitlist.length**3;let s=0;return Object.keys(e.geology).forEach((function(t){0!==e.geology[t]&&(r-=e.geology[t],s++)})),s>3&&(r-=(s-3)**2),r}const ca={unemployed:function(e){let a=F("job_unemployed_desc");return"unemployed"!==t.civic.d_job||e||(a=a+" "+F("job_default",[F("job_unemployed")])),a},hunter:function(e){let a=F("job_hunter_desc",[t.resource.Food.name]);return t.race.unfathomable&&(a=F("job_eld_hunter_desc")),t.race.artifical?a=t.race.soul_eater?F("job_art_demon_hunter_desc",[t.resource.Furs.name,t.resource.Lumber.name]):F("job_art_hunter_desc",[t.resource.Furs.name]):t.race.soul_eater&&"wendigo"!==t.race.species&&(a=F(t.race.evil?"job_evil_hunter_desc":"job_not_evil_hunter_desc",[t.resource.Food.name,t.resource.Lumber.name,t.resource.Furs.name])),"hunter"!==t.civic.d_job||e||(a=a+" "+F("job_default",[t.race.unfathomable?F("job_raider"):F("job_hunter")])),a},forager:function(e){let a=F("job_forager_desc");return"forager"!==t.civic.d_job||e||(a=a+" "+F("job_default",[F("job_forager")])),a},farmer:function(e){let a=+pa(!0,e).toFixed(2),r=+pa(!1,e).toFixed(2);e||(a=+na(a,"farmer").toFixed(2),r=+na(r,"farmer").toFixed(2));let s=t.race.high_pop&&!e?F("job_farmer_desc_hp",[a,t.resource.Food.name,la(1),r,la(1)*t.city.farm.count]):F("job_farmer_desc",[a,t.resource.Food.name,t.city.farm.count,r]);return"farmer"!==t.civic.d_job||e||(s=s+" "+F("job_default",[F("job_farmer")])),s},lumberjack:function(e){let a=e&&t.race.servants?t.race.servants.jobs.lumberjack:t.civic.lumberjack.workers,r=t.civic.lumberjack.impact;if(e||(a=+na(a,"lumberjack").toFixed(2),r=+na(r,"lumberjack").toFixed(2)),!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species){let s=1+(t.tech.axe&&t.tech.axe>0?.35*(t.tech.axe-1):0);e||(s*=pi(a,"lumberjack")),"forest"===t.city.biome&&(r*=ji.forest.vars()[0]),"savanna"===t.city.biome&&(r*=ji.savanna.vars()[2]),"desert"===t.city.biome&&(r*=ji.desert.vars()[2]),"swamp"===t.city.biome&&(r*=ji.swamp.vars()[2]),"taiga"===t.city.biome&&(r*=ji.taiga.vars()[0]);let i=F("job_lumberjack_desc",[+(r*s).toFixed(2),t.resource.Lumber.name]);return"lumberjack"!==t.civic.d_job||e||(i=i+" "+F("job_default",[F("job_lumberjack")])),i}{let s=1;e||(s*=pi(a,"lumberjack"));let i=+(r*s).toFixed(2),c=+(r/4*s).toFixed(2),o="wendigo"===t.race.species?F("job_reclaimer_desc2",[i]):F("job_reclaimer_desc",[i,c]);return"lumberjack"!==t.civic.d_job||e||(o=o+" "+F("job_default",[F("job_reclaimer")])),o}},quarry_worker:function(e){let a=e&&t.race.servants?t.race.servants.jobs.quarry_worker:t.civic.quarry_worker.workers,r=t.civic.quarry_worker.impact;e||(a=+na(a,"quarry_worker").toFixed(2),r=+na(r,"quarry_worker").toFixed(2));let s=1+(t.tech.hammer&&t.tech.hammer>0?.4*t.tech.hammer:0);e||(s*=pi(a,"miner")),"desert"===t.city.biome&&(s*=ji.desert.vars()[0]),"swamp"===t.city.biome&&(s*=ji.swamp.vars()[3]),t.tech.explosives&&t.tech.explosives>=2&&(s*=t.tech.explosives>=3?1.75:1.5);let i=+(r*s).toFixed(1),c=t.resource.Aluminium.display?F("job_quarry_worker_desc2",[i,t.resource.Stone.name,t.resource.Aluminium.name]):F("job_quarry_worker_desc1",[i,t.resource.Stone.name]);return t.race.smoldering&&(c=c+" "+F("job_quarry_worker_smoldering",[t.resource.Chrysotile.name])),"quarry_worker"!==t.civic.d_job||e||(c=c+" "+F("job_default",[F("job_quarry_worker")])),c},crystal_miner:function(e){let a=e&&t.race.servants?t.race.servants.jobs.crystal_miner:t.civic.crystal_miner.workers,r=t.civic.crystal_miner.impact,s=1;e||(a=+na(a,"crystal_miner").toFixed(2),r=+na(r,"crystal_miner").toFixed(2),s*=pi(a,"miner"));let i=F("job_crystal_miner_desc",[+(r*s).toFixed(2),t.resource.Crystal.name]);return"crystal_miner"!==t.civic.d_job||e||(i=i+" "+F("job_default",[F("job_crystal_miner")])),i},scavenger:function(e){let a=ui.scavenger.vars()[0];t.city.ptrait.includes("trashed")&&t.race.scavenger&&(a*=1+ui.scavenger.vars()[1]/100),t.race.high_pop&&!e&&(a*=ui.high_pop.vars()[1]/100),e||(a=+na(a,"scavenger").toFixed(2));let r=F("job_scavenger_desc",[di[t.race.species].home,a]);return"scavenger"!==t.civic.d_job||e||(r=r+" "+F("job_default",[F("job_scavenger")])),r},torturer:function(){return F("job_torturer_desc")},miner:function(){return t.tech.mining>=3?t.race.sappy&&t.tech.alumina?F("job_miner_desc2_amber"):F("job_miner_desc2"):F("job_miner_desc1")},coal_miner:function(){return t.tech.uranium?F("job_coal_miner_desc2"):F("job_coal_miner_desc1")},craftsman:function(){return F("job_craftsman_desc")},cement_worker:function(){let e=t.race.high_pop?3/ui.high_pop.vars()[0]:3;"ashland"===t.city.biome&&(e*=ji.ashland.vars()[1]),e=+na(e,"cement_worker").toFixed(2);let a=+na(t.civic.cement_worker.impact,"cement_worker").toFixed(2)*(t.tech.cement>=4?1.2:1)*pi(t.civic.cement_worker.workers,"factory");return"ashland"===t.city.biome&&(a*=ji.ashland.vars()[1]),a=+a.toFixed(2),t.race.sappy?F("job_cement_worker_amber_desc",[a]):F("job_cement_worker_desc",[a,e])},banker:function(){let e=100*+na(t.civic.banker.impact,"banker").toFixed(2);return t.tech.banking>=10&&(e+=2*t.tech.stock_exchange),t.race.truthful&&(e*=1-ui.truthful.vars()[0]/100),"republic"===t.civic.govern.type&&(e*=1.25),t.race.high_pop&&(e*=ui.high_pop.vars()[1]/100),e=+e.toFixed(0),F("job_banker_desc",[e])},entertainer:function(){let e=t.tech.theatre;t.race.musical&&(e+=ui.musical.vars()[0]),t.race.emotionless&&(e*=1-ui.emotionless.vars()[0]/100),t.race.high_pop&&(e*=ui.high_pop.vars()[1]/100),e=+na(e,"entertainer").toFixed(2);let a=t.race.high_pop?ui.high_pop.vars()[1]/100:1;return a=+na(a,"entertainer").toFixed(2),t.tech.superstar?F("job_entertainer_desc2",[e,a]):F("job_entertainer_desc",[+e.toFixed(2)])},priest:function(){let e="";return e="theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display?F("job_priest_desc2"):F("job_priest_desc"),t.tech.cleric&&(e+=` ${F("job_priest_desc3")}`),e},professor:function(){let e=+na(1,"professor"),a=+(t.race.studious?t.civic.professor.impact+ui.studious.vars()[0]:t.civic.professor.impact),r=Pi("elven");return r>0&&(a+=ui.studious.vars(1)[0]*r),e*=a,e*=t.race.pompous?1-ui.pompous.vars()[0]/100:1,e*=pi(t.civic.professor.workers,"science"),t.tech.anthropology&&t.tech.anthropology>=3&&(e*=1+.05*t.city.temple.count),"theocracy"===t.civic.govern.type&&(e*=.75),e=+e.toFixed(2),F("job_professor_desc",[e])},scientist:function(){let e=+na(t.civic.scientist.impact,"scientist").toFixed(2);return e*=pi(t.civic.scientist.workers,"science"),t.tech.science>=6&&t.city.wardenclyffe&&(e*=1+t.civic.professor.workers*t.city.wardenclyffe.on*.01),t.space.satellite&&(e*=1+.01*t.space.satellite.count),"theocracy"===t.civic.govern.type&&(e*=t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?.75:.6:.5),e=+e.toFixed(2),"magic"===t.race.universe?F("job_wizard_desc",[e,+(.025*nc("magic")).toFixed(4)]):F("job_scientist_desc",[e])},colonist:()=>F(t.race.truepath?"job_colonist_desc_tp":"job_colonist_desc",[Xt().red]),titan_colonist:()=>F("job_colonist_desc_tp",[Xt().titan]),space_miner:()=>F("job_space_miner_desc"),hell_surveyor:()=>F("job_hell_surveyor_desc"),archaeologist(){let e=75*(i.arcology||0),a=(ke(t.portal.guard_post.on,"hellArmy",0)+e)/5e3;a=a>1?1:a;let r=25e4;return t.race.high_pop&&(r*=ui.high_pop.vars()[1]/100),F("job_archaeologist_desc",[Math.round(r*a).toLocaleString()])},pit_miner:()=>F("job_pit_miner_desc",[F("tau_planet",[di[t.race.species].home])]),crew:()=>F("job_crew_desc")};function oa(e){e||$("#civics").append($(`

          ${F("civics_jobs")}

          `)),da("unemployed",e,0,0,"warning"),da("hunter",e,0,0),da("forager",e,0,0),da("farmer",e,.82,5),da("lumberjack",e,1,5),da("quarry_worker",e,1,5),da("crystal_miner",e,.1,5),da("scavenger",e,.12,5),da("torturer",e,1,3,"advanced"),da("miner",e,1,4,"advanced"),da("coal_miner",e,.2,4,"advanced"),da("craftsman",e,1,5,"advanced"),da("cement_worker",e,.4,5,"advanced"),da("entertainer",e,1,10,"advanced"),da("priest",e,1,3,"advanced"),da("professor",e,.5,6,"advanced"),da("scientist",e,1,5,"advanced"),da("banker",e,.1,6,"advanced"),da("colonist",e,1,5,"advanced"),da("titan_colonist",e,1,5,"advanced"),da("space_miner",e,1,5,"advanced"),da("hell_surveyor",e,1,1,"advanced"),da("archaeologist",e,1,1,"advanced"),da("pit_miner",e,1,4.5,"advanced"),da("crew",e,1,4,"alert"),e||t.race.start_cataclysm||(ha(),t.race.servants&&_a())}function na(e,a){return t.race.strong&&["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(a)&&(e*=ui.strong.vars()[1]),(t.race.swift||t.race.living_tool)&&["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(a)&&(e*=ui.strong.vars(.25)[1]),t.race.lone_survivor&&(["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(a)?e*=80:["craftsman"].includes(a)?e*=60:["miner","coal_miner","cement_worker","banker","entertainer","priest","pit_miner"].includes(a)?e*=45:["professor","scientist"].includes(a)&&(e*=125)),e}function la(e){return t.race.high_pop?e*ui.high_pop.vars()[0]:e}function ua(e){let a="";a=t.race.unfathomable&&"hunter"===e?F("job_raider"):"magic"===t.race.universe&&"scientist"===e?F("job_wizard"):t.race.truepath&&"colonist"===e?F("job_colonist_tp",[Xt().red]):"titan_colonist"===e?F("job_colonist_tp",[Xt().titan]):"lumberjack"!==e||!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species?F("job_"+e):F("job_reclaimer"),t.civic[e].name=a}function da(e,a,r,s,c){let o=!1;if("servant"===a&&(o=!0,a=!1),t.civic[e]||(t.civic[e]={job:e,display:!1,workers:0,max:0,impact:r}),ua(e),t.civic[e].assigned||(t.civic[e].assigned="craftsman"===e?0:t.civic[e].workers),o||(t.civic[e].stress=s,t.civic[e].impact=r),"craftsman"!==e&&!a){var n=o?"servant-"+e:"civ-"+e,l=$(`
          `),u=o?$('
          '):$(`
          `);if(c&&"unemployed"!==e){let t=$(`

          {{ civic.${e}.name }}

          {{ civic.${e}.workers | adjust('${e}') }} / {{ civic.${e}.max | adjust('${e}') }}
          `);l.append(t)}else{c=c||"info";let t=o?$(`

          {{ civic.${e}.name }}

          {{ sjob.${e} }}
          `):$(``);l.append(t)}if(l.append(u),$(o?"#servants":"#jobs").append(l),"crew"!==e){var d=$(`«`),_=$(`»`);u.append(d),u.append(_)}sc(o?{el:`#${n}`,data:{civic:t.civic,sjob:t.race.servants.jobs},methods:{showJob:e=>t.civic[e].display||"scavenger"===e&&t.race.servants.force_scavenger,add(){let a=y();for(let r=0;rt.race.servants.used;r++)t.race.servants.jobs[e]++,t.race.servants.used++},sub(){let a=y();for(let r=0;r0;r++)t.race.servants.jobs[e]--,t.race.servants.used--}}}:{el:`#${n}`,data:{civic:t.civic},methods:{showJob:e=>t.civic[e].display,add(){let a=y();for(let r=0;r0;r++)t.civic[e].workers++,t.civic[t.civic.d_job].workers--,t.civic[e].assigned=t.civic[e].workers},sub(){let a=y();for(let r=0;r0;r++)t.civic[e].workers--,t.civic[t.civic.d_job].workers++,t.civic[e].assigned=t.civic[e].workers},level:e=>0===t.civic[e].workers?"count has-text-danger":t.civic[e].workers===t.civic[e].max?"count has-text-success":t.civic[e].workers<=t.civic[e].max/3?"count has-text-caution":t.civic[e].workers<=.66*t.civic[e].max?"count has-text-warning":t.civic[e].workerst.civic.d_job===e},filters:{d_state:e=>t.civic.d_job===e?"*":"",event(a){if("unemployed"===e&&t.civic.unemployed.display||"hunter"===e&&!t.civic.unemployed.display){let e=$c(3,14);if(0===a&&e.length>0)return e}return a},adjust:(e,t)=>"titan_colonist"===t&&i.ai_colonist?e+la(i.ai_colonist):e}}),Ti(n,(function(){return ca[e](o)}),{elm:`#${n} .job_label`,classes:"has-background-light has-text-dark"})}}function _a(){if(rc($("#servants")),t.race.servants){var e=$(`

          ${F("civics_servants")}

          {{ s.used }} / {{ s.max }}
          `);$("#servants").append(e),["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].forEach((function(e){da(e,"servant")})),sc({el:"#servantList",data:{s:t.race.servants},methods:{level:()=>0===t.race.servants.used?"count has-text-danger":t.race.servants.used===t.race.servants.max?"count has-text-success":t.race.servants.used<=t.race.servants.max/3?"count has-text-caution":t.race.servants.used<=.66*t.race.servants.max?"count has-text-warning":t.race.servants.used=2?1.15:.65),t.race.living_tool&&!a?r*=1+(t.tech.science&&t.tech.science>0?t.tech.science/5:0):r*=1+(t.tech.hoe&&t.tech.hoe>0?t.tech.hoe/3:0),r*="grassland"===t.city.biome?ji.grassland.vars()[0]:1,r*="savanna"===t.city.biome?ji.savanna.vars()[0]:1,r*="ashland"===t.city.biome?ji.ashland.vars()[0]:1,r*="volcanic"===t.city.biome?ji.volcanic.vars()[0]:1,r*="hellscape"===t.city.biome?ji.hellscape.vars()[0]:1,r*=t.city.ptrait.includes("trashed")?Si.trashed.vars()[0]:1,a||(r*=pi(t.civic.farmer.workers,"farmer")),r*=t.tech.agriculture>=7?1.1:1,r*=t.race.low_light?1-ui.low_light.vars()[0]/100:1,a&&(r*=la(1)),r}function ha(e){if(rc($(e?"#skilledServants":"#foundry")),t.city.foundry&&t.city.foundry.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation){let a=$(e?"#skilledServants":"#foundry"),r=e?"{{ s.sused }} / {{ s.smax }}":"{{ f.crafting }} / {{ c.max }}",s=$(`

          ${F(e?"civics_skilled_servants":"craftsman_assigned")}

          ${r}
          `);a.append(s);let o=Tc("summer"),n=["Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Aerogel","Nanoweave"];e||(n.push("Scarletite"),n.push("Quantium")),o&&!e&&n.push("Thermite");for(let r=0;r');a.append(i);let c,o=$('
          ');c="Scarletite"===s&&t.portal.hasOwnProperty("hell_forge")?$(`

          ${r}

          {{ f.${s} }} / {{ p.on | maxScar }}
          `):"Quantium"===s&&(t.space.hasOwnProperty("zero_g_lab")||t.tauceti.hasOwnProperty("infectious_disease_lab"))?$(`

          ${r}

          {{ f.${s} }} / {{ e.on | maxQuantium }}
          `):$(`

          ${r}

          ${e?`{{ s.sjobs.${s} }}`:`{{ f.${s} }}`}
          `),i.append(c),i.append(o),a.append(i);let n=$(`«`),l=$(`»`);o.append(n),o.append(l)}}let l=t.portal.hasOwnProperty("hell_forge")?{c:t.civic.craftsman,p:t.portal.hell_forge}:{c:t.civic.craftsman,e:t.space.hasOwnProperty("zero_g_lab")||t.tauceti.hasOwnProperty("infectious_disease_lab")?t.tech.isolation?t.tauceti.infectious_disease_lab:t.space.zero_g_lab:{count:0,on:0}};e?l.s=t.race.servants:l.f=t.city.foundry,sc({el:e?"#skilledServants":"#foundry",data:l,methods:{add(a){let r=y(),s=-1;"Scarletite"===a?(s=i.hell_forge||0,t.race.high_pop&&(s*=ui.high_pop.vars()[0])):"Quantium"===a&&(s=t.tech.isolation?Math.min(c.infectious_disease_lab,i.infectious_disease_lab)||0:Math.min(c.zero_g_lab,i.zero_g_lab)||0,t.race.high_pop&&(s*=ui.high_pop.vars()[0]));for(let i=0;i0&&(-1===s||s>t.city.foundry[a])))break;t.civic.craftsman.workers++,t.city.foundry.crafting++,t.city.foundry[a]++,t.civic[t.civic.d_job].workers--}},sub(a){let r=y();for(let s=0;s0))break;t.race.servants.sjobs[a]--,t.race.servants.sused--}else{if(!(t.city.foundry[a]>0))break;t.city.foundry[a]--,t.civic.craftsman.workers--,t.city.foundry.crafting--,t.civic[t.civic.d_job].workers++}},level(){let a=e?t.race.servants.sused:t.civic.craftsman.workers,r=e?t.race.servants.smax:t.civic.craftsman.max;return 0===a?"count has-text-danger":a===r?"count has-text-success":a<=r/3?"count has-text-caution":a<=.66*r?"count has-text-warning":a"),a=t.resource[r].name,s=Xa(r,"auto").multiplier,i=t.genes.crafty?2:1,c=+t.resource[r].diff.toFixed(2),o=+(100*s).toFixed(0);e.append($(`
          ${F("craftsman_hover_bonus",[o.toLocaleString(),a])}
          `)),e.append($(`
          ${F("craftsman_hover_prod",[c.toLocaleString(),a])}
          `));let n=Ya();for(let a=0;a${F("craftsman_hover_cost",[s,t.resource[n[r][a].r].name])}
          `))}return e};br(e?`scraft${r}`:`craft${r}`,r,"auto",a)}}e?Ti("servantFoundry",(function(){return F("civics_skilled_servants_desc")}),{elm:"#skilledServants .foundry",classes:"has-background-light has-text-dark"}):Ti("craftsmenFoundry",(function(){return F("job_craftsman_hover")}),{elm:"#foundry .foundry",classes:"has-background-light has-text-dark"}),t.race.servants&&!e&&t.race.servants.smax>0&&ha(!0)}}const ma={prtl_fortress:{info:{name:F("portal_fortress_name"),desc:F("portal_fortress_desc"),repair(){let e=200;return i.repair_droid&&(e*=.95**i.repair_droid),Math.round(e)}},turret:{id:"portal-turret",title:()=>F(t.tech.turret?t.tech.turret>=2?"portal_turret_title3":"portal_turret_title2":"portal_turret_title1"),desc:()=>`
          ${F(t.tech.turret?t.tech.turret>=2?"portal_turret_title3":"portal_turret_title2":"portal_turret_title1")}
          ${F("requires_power")}
          `,reqs:{portal:2},cost:{Money:e=>Xi("turret",e,35e4,1.28,"portal"),Copper:e=>Xi("turret",e,5e4,1.28,"portal"),Adamantite:e=>Xi("turret",e,8e3,1.28,"portal"),Elerium:e=>Xi("turret",e,15,1.28,"portal"),Nano_Tube:e=>Xi("turret",e,28e3,1.28,"portal")},powered:()=>oc(t.tech.turret?4+t.tech.turret:4),postPower(e){i.turret=t.portal.turret.on,sc({el:"#fort"},"update")},effect(){let e=t.tech.turret?t.tech.turret>=2?70:50:35,a=$(this)[0].powered();return`
          ${F("portal_turret_effect",[e])}
          ${F("minus_power",[a])}
          `},action(){return!!Os($(this)[0])&&(Nt("turret","portal"),xs($(this)[0])&&(i.turret++,sc({el:"#fort"},"update")),!0)}},carport:{id:"portal-carport",title:F("portal_carport_title"),desc:()=>F("portal_carport_desc",[1]),reqs:{portal:2},cost:{Money:e=>Xi("carport",e,25e4,1.3,"portal"),Cement:e=>Xi("carport",e,18e3,1.3,"portal"),Oil:e=>Xi("carport",e,6500,1.3,"portal"),Plywood:e=>Xi("carport",e,8500,1.3,"portal")},repair(){let e=180;return i.repair_droid&&(e*=.92**i.repair_droid),Math.round(e)},effect:()=>`${F("portal_carport_effect",[1])}`,action(){return!!Os($(this)[0])&&(Nt("carport","portal"),t.civic.hell_surveyor.display=!0,t.resource.Infernite.display=!0,t.tech.infernite||(t.tech.infernite=1,ms()),!0)}},war_droid:{id:"portal-war_droid",title:F("portal_war_droid_title"),desc:()=>`
          ${F("portal_war_droid_title")}
          ${F("requires_power")}
          `,reqs:{portal:5},cost:{Money:e=>Xi("war_droid",e,495e3,1.26,"portal"),Neutronium:e=>Xi("war_droid",e,1250,1.26,"portal"),Elerium:e=>Xi("war_droid",e,18,1.26,"portal"),Stanene:e=>Xi("war_droid",e,37500,1.26,"portal"),Soul_Gem:e=>Xi("war_droid",e,1,1.26,"portal")},powered:()=>oc(2),effect(){return`
          ${F("portal_war_droid_effect")}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("war_droid","portal"),xs($(this)[0]),!0)},flair:F("portal_war_droid_flair")},repair_droid:{id:"portal-repair_droid",title:F("portal_repair_droid_title"),desc:()=>`
          ${F("portal_repair_droid_title")}
          ${F("requires_power")}
          `,reqs:{portal:6},cost:{Money:e=>Xi("repair_droid",e,444e3,1.26,"portal"),Iron:e=>Xi("repair_droid",e,88e3,1.26,"portal"),Iridium:e=>Xi("repair_droid",e,17616,1.26,"portal"),Infernite:e=>Xi("repair_droid",e,666,1.26,"portal"),Soul_Gem:e=>Xi("repair_droid",e,1,1.15,"portal")},powered:()=>oc(3),effect(){return`
          ${F("portal_repair_droid_effect",[5])}
          ${F("portal_repair_droid_effect2",[8])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("repair_droid","portal"),xs($(this)[0]),!0)},flair:F("portal_repair_droid_flair")}},prtl_badlands:{info:{name:F("portal_badlands_name"),desc:F("portal_badlands_desc")},war_drone:{id:"portal-war_drone",title:F("portal_war_drone_title"),desc:()=>`
          ${F("portal_war_drone_title")}
          ${F("requires_power")}
          `,reqs:{portal:3},powered:()=>oc(5),cost:{Money:e=>Xi("war_drone",e,65e4,1.28,"portal"),Alloy:e=>Xi("war_drone",e,6e4,1.28,"portal"),Graphene:e=>Xi("war_drone",e,1e5,1.28,"portal"),Elerium:e=>Xi("war_drone",e,25,1.28,"portal"),Soul_Gem:e=>Xi("war_drone",e,1,1.28,"portal")},effect(){return`
          ${F("portal_war_drone_effect")}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("war_drone","portal"),xs($(this)[0]),!0)},flair:F("portal_war_drone_flair")},sensor_drone:{id:"portal-sensor_drone",title:F("portal_sensor_drone_title"),desc:()=>`
          ${F("portal_sensor_drone_title")}
          ${F("requires_power")}
          `,reqs:{infernite:2},powered:()=>oc(3),cost:{Money:e=>Xi("sensor_drone",e,5e5,1.25,"portal"),Polymer:e=>Xi("sensor_drone",e,25e3,1.25,"portal"),Adamantite:e=>Xi("sensor_drone",e,12500,1.25,"portal"),Infernite:e=>Xi("sensor_drone",e,100,1.25,"portal")},effect(){let e=t.tech.infernite>=4?t.tech.infernite>=6?50:20:10,a=t.tech.infernite>=6?2500:1e3,r=t.race.cataclysm?`
          ${F("space_moon_observatory_cata_effect",[2])}
          `:`
          ${F("space_moon_observatory_effect",[2])}
          ${F("portal_sensor_drone_effect2",[2])}
          `,s=t.tech.science>=14?`
          ${F("city_max_knowledge",[a])}
          ${r}`:"";return`
          ${F("portal_sensor_drone_effect",[e])}
          ${s}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("sensor_drone","portal"),xs($(this)[0]),!0)}},attractor:{id:"portal-attractor",title:F("portal_attractor_title"),desc:()=>`
          ${F("portal_attractor_title")}
          ${F("requires_power")}
          `,reqs:{portal:4},powered:()=>oc(3),cost:{Money:e=>Xi("attractor",e,35e4,1.25,"portal"),Aluminium:e=>Xi("attractor",e,175e3,1.25,"portal"),Stanene:e=>Xi("attractor",e,9e4,1.25,"portal")},effect(){return`
          ${F("portal_attractor_effect1")}
          ${F("portal_attractor_effect2",[t.resource.Soul_Gem.name])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("attractor","portal"),xs($(this)[0]),!0)}}},prtl_pit:{info:{name:F("portal_pit_name"),desc:F("portal_pit_desc")},pit_mission:{id:"portal-pit_mission",title:F("portal_pit_mission_title"),desc:F("portal_pit_mission_title"),reqs:{hell_pit:1},grant:["hell_pit",2],queue_complete:()=>t.tech.hell_pit>=2?0:1,cost:{Money:()=>5e6,Helium_3:()=>3e5,Deuterium:()=>2e5},effect:F("portal_pit_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_pit_mission_result"),"info",!1,["progress","hell"]),!0)}},assault_forge:{id:"portal-assault_forge",title:F("portal_assault_forge_title"),desc:F("portal_assault_forge_title"),reqs:{hell_pit:2},grant:["hell_pit",3],queue_complete:()=>t.tech.hell_pit>=3?0:1,cost:{Money:()=>1e7,HellArmy:()=>Math.round(650/ke(1,"hellArmy")),Cement:()=>1e7,Adamantite:()=>125e4,Elerium:()=>2400,Stanene:()=>9e5},effect:F("portal_assault_forge_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_assault_forge_result"),"info",!1,["progress","hell"]),!0)}},soul_forge:{id:"portal-soul_forge",title:F("portal_soul_forge_title"),desc:()=>`
          ${F("portal_soul_forge_desc")}
          ${F("requires_power")}
          `,reqs:{hell_pit:4},queue_complete:()=>1-t.portal.soul_forge.count,powered:()=>oc(30),postPower(e){sc({el:"#fort"},"update")},cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?25e6:0,Graphene:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?15e5:0,Infernite:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?25e3:0,Bolognium:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?1e5:0},effect(e){let a=`
          ${F("portal_soul_forge_effect",[t.resource.Soul_Gem.name])}
          `;if((e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)>=1){let e=t.tech.hell_pit>=6?75e4:1e6;t.tech.hell_pit>=7&&i.soul_attractor>0&&(e*=.97**i.soul_attractor),a+=`
          ${F("portal_soul_forge_effect2",[t.portal.soul_forge?t.portal.soul_forge.kills.toLocaleString():0,Math.round(e).toLocaleString()])}
          `}return`${a}
          ${F("portal_soul_forge_soldiers",[ba()])}, ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!(Os($(this)[0])&&t.portal.soul_forge.count<1)&&(Nt("soul_forge","portal"),xs($(this)[0]),!0)}},gun_emplacement:{id:"portal-gun_emplacement",title:F("portal_gun_emplacement_title"),desc:()=>`
          ${F("portal_gun_emplacement_title")}
          ${F("requires_power")}
          `,reqs:{hell_gun:1},powered:()=>oc(3),cost:{Money:e=>Xi("gun_emplacement",e,4e6,1.25,"portal"),Coal:e=>Xi("gun_emplacement",e,25e4,1.25,"portal"),Steel:e=>Xi("gun_emplacement",e,12e5,1.25,"portal"),Wrought_Iron:e=>Xi("gun_emplacement",e,2e5,1.25,"portal")},effect(){let e=t.tech.hell_gun>=2?2:1,a=t.tech.hell_gun>=2?35:20,r=t.tech.hell_gun>=2?75:40;return`
          ${F("portal_gun_emplacement_effect",[e])}
          ${F("portal_gun_emplacement_effect2",[a,r])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("gun_emplacement","portal"),xs($(this)[0]),!0)}},soul_attractor:{id:"portal-soul_attractor",title:F("portal_soul_attractor_title"),desc:()=>`
          ${F("portal_soul_attractor_title")}
          ${F("requires_power")}
          `,reqs:{hell_pit:5},powered:()=>oc(4),cost:{Money:e=>Xi("soul_attractor",e,12e6,1.25,"portal"),Stone:e=>Xi("soul_attractor",e,23e6,1.25,"portal"),Nano_Tube:e=>Xi("soul_attractor",e,314159,1.25,"portal"),Vitreloy:e=>Xi("soul_attractor",e,1618,1.25,"portal"),Aerogel:e=>Xi("soul_attractor",e,18e4,1.25,"portal")},effect(){let e=t.tech.hell_pit>=7?`
          ${F("portal_soul_attractor_effect2",[3])}
          `:"",a=t.blood.attract?5*t.blood.attract:0;return`
          ${F("portal_soul_attractor_effect",[40+a,120+a])}
          ${e}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("soul_attractor","portal"),xs($(this)[0]),!0)}},soul_capacitor:{id:"portal-soul_capacitor",title:F("portal_soul_capacitor_title"),desc:()=>`
          ${F("portal_soul_capacitor_desc")}
          ${F("requires_power")}
          `,reqs:{forbidden:2},powered:()=>oc(125),queue_complete:()=>40-t.portal.soul_capacitor.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,75e7,1.01,"portal"),Crystal:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,125e4,1.01,"portal"),Adamantite:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,65e5,1.01,"portal"),Infernite:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,1e4,1.01,"portal"),Stanene:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,25e5,1.01,"portal"),Bolognium:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,1e6,1.01,"portal"),Soul_Gem:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,3,1.01,"portal"),Mythril:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Xi("soul_capacitor",e,125e4,1.01,"portal")},effect(){let e=t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.ecap:0,a=`
          ${F("portal_soul_capacitor_effect",[(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.energy:0).toLocaleString()])}
          `;return a+=`
          ${F("portal_soul_capacitor_effect2",[e.toLocaleString()])}
          `,a+=`
          ${F("portal_soul_capacitor_effect3",[25e5.toLocaleString()])}
          `,a+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,a},action(){return!!(t.portal.soul_capacitor.count<40&&Os($(this)[0]))&&(t.portal.soul_capacitor.count++,xs($(this)[0]),!0)},postPower(){Ps($(this)[0],"portal","soul_capacitor")}},absorption_chamber:{id:"portal-absorption_chamber",title:F("portal_absorption_chamber_title"),desc:e=>!t.interstellar.hasOwnProperty("absorption_chamber")||t.portal.absorption_chamber.count<100||e?`
          ${F("portal_absorption_chamber_title")}
          ${F("requires_segmemts",[100])}
          `:`
          ${F("portal_absorption_chamber_title")}
          `,reqs:{forbidden:3},queue_size:5,queue_complete:()=>100-t.portal.absorption_chamber.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e6:0,Alloy:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e4:0,Neutronium:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?1e3:0,Orichalcum:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?25e4:0,Nanoweave:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0);if(a<100){let e=100-a;return`
          ${F("portal_absorption_chamber_incomplete")}
          ${F("space_dwarf_collider_effect2",[e])}
          `}if(5===t.tech.forbidden)return`
          ${F("portal_absorption_chamber_effect_eld",[1e8.toLocaleString()])}
          ${F("tech_demonic_infusion_effect2",[mc("descend").artifact])}
          `;{let e=Ft();return`
          ${F("portal_absorption_chamber_effect",[1e8.toLocaleString()])}
          ${e}
          `}},action(){if(Os($(this)[0])){if(t.portal.absorption_chamber.count<100)return Nt("absorption_chamber","portal"),t.portal.absorption_chamber.count>=100&&(t.tech.forbidden=4),!0;if(t.portal.soul_capacitor.energy>=1e8)return 5===t.tech.forbidden?W():ra(),!0}return!1}}},prtl_ruins:{info:{name:F("portal_ruins_name"),desc:F("portal_ruins_desc"),support:"guard_post",prop(){let e=` - ${F("portal_ruins_security")}: {{ on | filter('army') }}`;return e+=` - ${F("portal_ruins_supressed")}: {{ on | filter('sup') }}`,e},filter(e,t){let a=Oa("ruins");switch(t){case"army":return Math.round(a.rating);case"sup":return+(100*a.supress).toFixed(2)+"%"}}},ruins_mission:{id:"portal-ruins_mission",title:F("portal_ruins_mission_title"),desc:F("portal_ruins_mission_title"),reqs:{hell_ruins:1},grant:["hell_ruins",2],queue_complete:()=>t.tech.hell_ruins>=2?0:1,cost:{Money:()=>1e8,Oil:()=>5e5,Helium_3:()=>5e5},effect:F("portal_ruins_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_ruins_mission_result"),"info",!1,["progress","hell"]),t.portal.vault={count:0},t.portal.stonehedge={count:0},t.portal.archaeology={count:0,on:0},!0)}},guard_post:{id:"portal-guard_post",title:F("portal_guard_post_title"),desc:()=>`
          ${F("portal_guard_post_title")}
          ${F("requires_soldiers")}
          ${F("requires_power")}
          `,reqs:{hell_ruins:2},cost:{Money:e=>Xi("guard_post",e,8e6,1.06,"portal"),Lumber:e=>Xi("guard_post",e,65e5,1.06,"portal"),Sheet_Metal:e=>Xi("guard_post",e,3e5,1.06,"portal")},powered:()=>oc(5),support:()=>1,effect(){let e=t.race.holy?1+ui.holy.vars()[1]/100:1,a=Pi("unicorn");return a>0&&(e*=1+ui.holy.vars(1)[1]/100*a),`
          ${F("portal_guard_post_effect1",[Math.round(e*ke(la(1),"hellArmy",0))])}
          ${F("portal_guard_post_effect2",[la(1),$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("guard_post","portal"),t.portal.guard_post.on++,!0)},postPower(){sc({el:"#srprtl_ruins"},"update"),sc({el:"#srprtl_gate"},"update")}},vault:{id:"portal-vault",title:F("portal_vault_title"),desc:F("portal_vault_title"),reqs:{hell_ruins:2,hell_vault:1},condition:()=>!(t.portal.vault.count>=2),queue_complete:()=>2-t.portal.vault.count,cost:{Soul_Gem:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===0?100:0,Money:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?25e7:0,Adamantite:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?125e5:0,Orichalcum:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?3e7:0},effect:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)<1?F("portal_vault_effect",[100]):F("portal_vault_effect2"),action(){return!!(t.portal.vault.count<2&&Os($(this)[0]))&&(Nt("vault","portal"),2===t.portal.vault.count&&(t.tech.hell_ruins=3,t.resource.Codex.display=!0,t.resource.Codex.amount=1,Di(F("portal_vault_result"),"info",!1,["progress","hell"])),!0)},post(){2===t.portal.vault.count&&(ms(),$a(),Ei())}},archaeology:{id:"portal-archaeology",title:F("portal_archaeology_title"),desc:()=>`
          ${F("portal_archaeology_title")}
          ${F("requires_security")}
          ${F("requires_power")}
          `,reqs:{hell_ruins:2},cost:{Money:e=>Xi("archaeology",e,1e8,1.25,"portal"),Titanium:e=>Xi("archaeology",e,375e4,1.25,"portal"),Mythril:e=>Xi("archaeology",e,125e4,1.25,"portal")},powered:()=>oc(8),effect(){return`
          ${F("portal_archaeology_effect",[la(2)])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){if(Os($(this)[0])){if(Nt("archaeology","portal"),t.civic.archaeologist.display=!0,xs($(this)[0])&&t.civic[t.civic.d_job].workers>0){let e=t.civic[t.civic.d_job].workers-la(2)<0?t.civic[t.civic.d_job].workers:la(2);t.civic[t.civic.d_job].workers-=e,t.civic.archaeologist.workers+=e}return!0}return!1}},arcology:{id:"portal-arcology",title:F("portal_arcology_title"),desc:()=>`
          ${F("portal_arcology_title")}
          ${F("requires_security")}
          ${F("requires_power")}
          `,reqs:{housing:4},cost:{Money:e=>Xi("arcology",e,18e7,1.22,"portal"),Graphene:e=>Xi("arcology",e,75e5,1.22,"portal"),Bolognium:e=>Xi("arcology",e,28e5,1.22,"portal"),Orichalcum:e=>Xi("arcology",e,55e5,1.22,"portal"),Nanoweave:e=>Xi("arcology",e,65e4,1.22,"portal"),Horseshoe:()=>t.race.hooved?13:0},powered:()=>oc(25),effect(){let e=Oa("ruins"),t=Lr(8*Hs()*e.supress);t=+t.toFixed(0);let a=10*Math.round(u),r=`
          ${F("plus_max_resource",[a,F("resource_Crates_name")])}
          ${F("plus_max_resource",[a,F("resource_Containers_name")])}
          `;return`
          ${F("plus_max_resource",[`$${t.toLocaleString()}`,F("resource_Money_name")])}
          ${F("plus_max_citizens",[$(this)[0].citizens()])}
          ${F("plus_max_resource",[la(5),F("civics_garrison_soldiers")])}
          ${F("portal_guard_post_effect1",[75])}
          ${r}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("arcology","portal"),xs($(this)[0])&&(t.resource[t.race.species].max+=8),!0)},post(){sc({el:"#srprtl_ruins"},"update"),ms()},postPower(){sc({el:"#srprtl_ruins"},"update"),sc({el:"#srprtl_gate"},"update")},citizens(){let e=8;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},hell_forge:{id:"portal-hell_forge",title:F("portal_hell_forge_title"),desc:()=>`
          ${F("portal_hell_forge_title")}
          ${F("requires_security")}
          ${F("requires_power")}
          `,reqs:{scarletite:1},cost:{Money:e=>Xi("hell_forge",e,25e7,1.15,"portal"),Coal:e=>Xi("hell_forge",e,165e4,1.22,"portal"),Steel:e=>Xi("hell_forge",e,38e5,1.22,"portal"),Iridium:e=>Xi("hell_forge",e,12e5,1.22,"portal"),Neutronium:e=>Xi("hell_forge",e,28e4,1.22,"portal"),Soul_Gem:e=>Xi("hell_forge",e,5,1.22,"portal")},powered:()=>oc(12),special:!0,effect(){let e=+(75*Oa("ruins").supress).toFixed(1),a=t.tech.inferno_power?`
          ${F("portal_hell_forge_effect2",[10,F("portal_inferno_power_title")])}
          `:"";return`
          ${F("portal_hell_forge_effect",[la(1)])}
          ${a}
          ${F("interstellar_stellar_forge_effect3",[3])}
          ${F("interstellar_stellar_forge_effect",[e])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("hell_forge","portal"),xs($(this)[0])&&(t.city.smelter.cap+=3,t.city.smelter.Oil+=3,t.city.smelter.Iron+=3),!0)},post(){ha()},postPower(e){if(!e&&t.portal.hell_forge.on`
          ${F("portal_inferno_power_title")}
          `,reqs:{inferno_power:1},cost:{Money:e=>Xi("inferno_power",e,275e6,1.16,"portal"),Neutronium:e=>Xi("inferno_power",e,375e4,1.18,"portal"),Stanene:e=>Xi("inferno_power",e,12e6,1.18,"portal"),Bolognium:e=>Xi("inferno_power",e,8e6,1.18,"portal")},powered(){let e=20;return i.hasOwnProperty("hell_forge")&&(e+=10*i.hell_forge),cc(-e)},fuel:{Infernite:5,Coal:100,Oil:80},effect(){let e=$(this)[0].fuel;return`
          ${F("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
          ${F("portal_inferno_power_effect",[e.Infernite,t.resource.Infernite.name,e.Coal,t.resource.Coal.name,e.Oil,t.resource.Oil.name])}
          `},action(){return!!Os($(this)[0])&&(Nt("inferno_power","portal"),t.portal.inferno_power.on++,!0)},post(){sc({el:"#foundry"},"update")}},ancient_pillars:{id:"portal-ancient_pillars",title:F("portal_ancient_pillars_title"),desc:F("portal_ancient_pillars_desc"),reqs:{hell_ruins:2},queue_complete:()=>t.tech.pillars&&1===t.tech.pillars&&"micro"!==t.race.universe?1:0,cost:{Harmony:e=>void 0!==e?e+Object.keys(t.pillars).lengthObject.keys(di).length-1,on:()=>Object.keys(t.pillars).length,effect(e){let a=(e||0)+Object.keys(t.pillars).length;return a>=1?`
          ${F("portal_ancient_pillars_effect2",[Object.keys(di).length-1,a])}
          `:`
          ${F("portal_ancient_pillars_effect",[Object.keys(di).length-1])}
          `},action(){return!(!t.tech.pillars||1!==t.tech.pillars||"micro"===t.race.universe||!Os($(this)[0])||(t.pillars[t.race.species]=ro(),t.tech.pillars=2,Lr(0,!1,!0),_c(!0),fa(!0),Xc("resonance"),sc({el:"#portal-ancient_pillars"},"update"),0))}}},prtl_gate:{info:{name:F("portal_gate_name"),desc:()=>`${F("portal_gate_desc")} ${F(t.tech.wtower&&t.tech.etower?"portal_gate_open":"portal_gate_closed")}`,support:"guard_post",hide_support:!0,prop(){let e=` - ${F("portal_ruins_security")}: {{ on | filter('army') }}`;return e+=` - ${F("portal_ruins_supressed")}: {{ on | filter('sup') }}`,e},filter(e,t){let a=Oa("gate");switch(t){case"army":return Math.round(a.rating);case"sup":return+(100*a.supress).toFixed(2)+"%"}}},gate_mission:{id:"portal-gate_mission",title:F("portal_gate_mission_title"),desc:F("portal_gate_mission_title"),reqs:{high_tech:18},grant:["hell_gate",1],queue_complete:()=>t.tech.hell_gate>=1?0:1,cost:{Money:()=>25e7,Knowledge:()=>275e5},effect:F("portal_gate_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_gate_mission_result"),"info",!1,["progress","hell"]),!0)}},west_tower:{id:"portal-west_tower",title:F("portal_west_tower"),desc(e){let a=fa();return!t.portal.hasOwnProperty("west_tower")||t.portal.west_tower.count${F("portal_west_tower")}
          ${F("requires_segmemts",[a])}
          `:`
          ${F("portal_west_tower")}
          `},reqs:{hell_gate:2},queue_size:25,queue_complete:()=>fa()-t.portal.west_tower.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)${F("portal_tower_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          ${F("portal_tower_effect2")}
          `}return F("portal_tower_effect")},action(){return!!(t.portal.west_tower.count=fa()&&(t.tech.wtower=1,t.tech.wtower&&t.tech.etower&&!t.tech.hell_lake&&(t.tech.hell_lake=1,t.settings.portal.lake=!0,t.portal.harbour={count:0,on:0,support:0,s_max:0},Di(F("portal_gate_open"),"info",!1,["progress","hell"]),$a()))}},east_tower:{id:"portal-east_tower",title:F("portal_east_tower"),desc(e){let a=fa();return!t.portal.hasOwnProperty("east_tower")||t.portal.east_tower.count${F("portal_east_tower")}
          ${F("requires_segmemts",[a])}
          `:`
          ${F("portal_east_tower")}
          `},reqs:{hell_gate:2},queue_size:25,queue_complete:()=>fa()-t.portal.east_tower.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)${F("portal_tower_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          ${F("portal_tower_effect2")}
          `}return F("portal_tower_effect")},action(){return!!(t.portal.east_tower.count=fa()&&(t.tech.etower=1,t.tech.wtower&&t.tech.etower&&!t.tech.hell_lake&&(t.tech.hell_lake=1,t.settings.portal.lake=!0,t.portal.harbour={count:0,on:0,support:0,s_max:0},Di(F("portal_gate_open"),"info",!1,["progress","hell"]),$a()))}},gate_turret:{id:"portal-gate_turret",title:F("portal_gate_turret_title"),desc:()=>`
          ${F("portal_gate_turret_title")}
          ${F("requires_power")}
          `,reqs:{hell_gate:3},powered:()=>oc(6),cost:{Money:e=>Xi("gate_turret",e,375e4,1.22,"portal"),Iron:e=>Xi("gate_turret",e,425e4,1.22,"portal"),Elerium:e=>Xi("gate_turret",e,275,1.22,"portal"),Stanene:e=>Xi("gate_turret",e,85e4,1.22,"portal")},effect(){let e=100;t.race.holy&&(e*=1+ui.holy.vars()[1]/100);let a=Pi("unicorn");a>0&&(e*=1+ui.holy.vars(1)[1]/100*a);let r=t.tech.hell_gun>=2?65:40,s=t.tech.hell_gun>=2?100:60;return`
          ${F("portal_gate_turret_effect",[Math.round(e)])}
          ${F("portal_gate_turret_effect2",[r,s])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("gate_turret","portal"),xs($(this)[0]),!0)},postPower(){sc({el:"#srprtl_gate"},"update")}},infernite_mine:{id:"portal-infernite_mine",title:F("portal_infernite_mine_title"),desc:()=>`
          ${F("portal_infernite_mine_title")}
          ${F("requires_security")}
          ${F("requires_power")}
          `,reqs:{hell_gate:4},powered:()=>oc(5),powerBalancer:()=>[{r:"Infernite",k:"lpmod"}],cost:{Money:e=>Xi("infernite_mine",e,75e6,1.26,"portal"),Alloy:e=>Xi("infernite_mine",e,245e4,1.26,"portal"),Orichalcum:e=>Xi("infernite_mine",e,165e4,1.26,"portal"),Wrought_Iron:e=>Xi("infernite_mine",e,68e4,1.26,"portal")},effect(){return`
          ${F("portal_infernite_mine_effect",[+Pe("infernite_mine").toFixed(3)])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("infernite_mine","portal"),xs($(this)[0]),!0)}}},prtl_lake:{info:{name:F("portal_lake_name"),desc:F("portal_lake_desc"),support:"harbour"},lake_mission:{id:"portal-lake_mission",title:F("portal_lake_mission_title"),desc:F("portal_lake_mission_title"),reqs:{hell_lake:1},grant:["hell_lake",2],queue_complete:()=>t.tech.hell_lake>=2?0:1,cost:{Money:()=>5e8,Oil:()=>75e4,Helium_3:()=>6e5},effect:F("portal_lake_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_lake_mission_result"),"info",!1,["progress","hell"]),!0)}},harbour:{id:"portal-harbour",title:F("portal_harbour_title"),desc:()=>`
          ${F("portal_harbour_title")}
          ${F("requires_power")}
          `,reqs:{hell_lake:3},powered:()=>+oc(500*.92**(i.cooling_tower||0)).toFixed(2),support:()=>1,cost:{Money:e=>Xi("harbour",e,225e6,ga(1.18),"portal"),Cement:e=>Xi("harbour",e,5e7,ga(1.18),"portal"),Iridium:e=>Xi("harbour",e,75e5,ga(1.18),"portal"),Infernite:e=>Xi("harbour",e,8e5,ga(1.18),"portal"),Stanene:e=>Xi("harbour",e,175e5,ga(1.18),"portal")},wide:!0,res:()=>["Oil","Alloy","Polymer","Iridium","Helium_3","Deuterium","Neutronium","Adamantite","Infernite","Nano_Tube","Graphene","Stanene","Bolognium","Orichalcum"],val(e){switch(e){case"Oil":return 3e4;case"Alloy":case"Polymer":return 25e4;case"Iridium":return 2e5;case"Helium_3":return 18e3;case"Deuterium":return 12e3;case"Neutronium":return 18e4;case"Adamantite":return 15e4;case"Infernite":return 75e3;case"Nano_Tube":return 75e4;case"Graphene":case"Stanene":return 12e5;case"Bolognium":case"Orichalcum":return 13e4;default:return 0}},effect(){let e='
          ';for(const a of $(this)[0].res())t.resource[a].display&&(e+=`${F("plus_max_resource",[k(+Lr($(this)[0].val(a)).toFixed(0),1),t.resource[a].name])}`);return e+="
          ",`
          ${F("portal_harbour_effect",[1])}
          ${e}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){if(Os($(this)[0])){if(Nt("harbour","portal"),xs($(this)[0]))for(const e of $(this)[0].res())t.resource[e].display&&(t.resource[e].max+=Lr($(this)[0].val(e)));return!0}return!1}},cooling_tower:{id:"portal-cooling_tower",title:F("portal_cooling_tower_title"),desc:()=>`
          ${F("portal_cooling_tower_title")}
          ${F("requires_power")}
          `,reqs:{hell_lake:6},powered:()=>oc(10),cost:{Money:e=>Xi("cooling_tower",e,25e7,1.2,"portal"),Polymer:e=>Xi("cooling_tower",e,12e6,1.2,"portal"),Orichalcum:e=>Xi("cooling_tower",e,85e5,1.2,"portal"),Brick:e=>Xi("cooling_tower",e,25e4,1.2,"portal")},effect(){return`
          ${F("portal_cooling_tower_effect",[8])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("cooling_tower","portal"),xs($(this)[0]),!0)}},bireme:{id:"portal-bireme",title:F("portal_bireme_title"),desc:()=>`
          ${F("portal_bireme_title")}
          ${F("space_support",[F("lake")])}
          `,reqs:{hell_lake:4},powered:()=>oc(1),support:()=>-1,cost:{Money:e=>Xi("bireme",e,19e7,1.24,"portal"),Helium_3:e=>Xi("bireme",e,225e3,1.24,"portal"),Adamantite:e=>Xi("bireme",e,15e6,1.24,"portal"),Nano_Tube:e=>Xi("bireme",e,18e6,1.24,"portal"),Soul_Gem:e=>Xi("bireme",e,10,1.24,"portal"),Scarletite:e=>Xi("bireme",e,125e3,1.24,"portal")},effect(){let e=t.blood.spire&&t.blood.spire>=2?20:15;return`
          ${F("space_used_support",[F("lake")])}
          ${F("portal_bireme_effect",[e])}
          ${F("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
          `},ship:{civ:()=>0,mil:()=>t.race.high_pop?2*ui.high_pop.vars()[0]:2},action(){return!!Os($(this)[0])&&(Nt("bireme","portal"),t.portal.harbour.support`
          ${F("portal_transport_title")}
          ${F("space_support",[F("lake")])}
          `,reqs:{hell_lake:5},powered:()=>oc(1),support:()=>-1,cost:{Money:e=>Xi("transport",e,3e8,1.22,"portal"),Oil:e=>Xi("transport",e,18e4,1.22,"portal"),Alloy:e=>Xi("transport",e,18e6,1.22,"portal"),Graphene:e=>Xi("transport",e,125e5,1.22,"portal"),Soul_Gem:e=>Xi("transport",e,5,1.22,"portal"),Scarletite:e=>Xi("transport",e,25e4,1.22,"portal")},effect(){let e=+((t.blood.spire&&t.blood.spire>=2?.8:.85)**(n.bireme||0)*100).toFixed(1);return`
          ${F("space_used_support",[F("lake")])}
          ${F("portal_transport_effect",[5])}
          ${F("portal_transport_effect2",[e])}
          ${F("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
          `},special:!0,sAction(){t.settings.civTabs=4,t.settings.marketTabs=3,t.settings.tabLoad||(Ct("mTabResource"),Ei("portal-transport"))},ship:{civ:()=>t.race.high_pop?3*ui.high_pop.vars()[0]:3,mil:()=>0},action(){return!!Os($(this)[0])&&(Nt("transport","portal"),t.portal.harbour.support` - ${F("portal_spire_supply")}: {{ supply | filter }} / {{ sup_max }} (+{{ diff | filter(2) }}/s)`,filter:(e,t)=>t?+e.toFixed(t):Math.floor(e)},spire_mission:{id:"portal-spire_mission",title:F("portal_spire_mission_title"),desc:F("portal_spire_mission_title"),reqs:{hell_spire:1},grant:["hell_spire",2],queue_complete:()=>t.tech.hell_spire>=2?0:1,cost:{Species:()=>fc(50),Oil:()=>9e5,Helium_3:()=>75e4,Structs:()=>({portal:{bireme:{s:"prtl_lake",count:1,on:1},transport:{s:"prtl_lake",count:1,on:1}}})},effect:F("portal_spire_mission_effect"),action(){return!!Os($(this)[0])&&(Di(F("portal_spire_mission_result"),"info",!1,["progress","hell"]),!0)},flair:F("portal_spire_mission_flair")},purifier:{id:"portal-purifier",title:F("portal_purifier_title"),desc:()=>`
          ${F("portal_purifier_desc")}
          ${F("requires_power")}
          `,reqs:{hell_spire:3},cost:{Money:e=>Xi("purifier",e,85e6,ga(1.15),"portal"),Supply:e=>t.portal.purifier&&0===t.portal.purifier.count?100:Xi("purifier",e,4200,ga(1.2),"portal")},powered:()=>oc(125),support:()=>t.tech.b_stone&&t.tech.b_stone>=3?1.25:1,effect(){return`
          ${F("portal_purifier_effect",[$(this)[0].support()])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(Nt("purifier","portal"),xs($(this)[0]),!0)}},port:{id:"portal-port",title:F("portal_port_title"),desc:()=>`
          ${F("portal_port_title")}
          ${F("portal_spire_support")}
          `,reqs:{hell_spire:3},cost:{Money:e=>Xi("port",e,135e6,ga(1.2),"portal"),Supply:e=>t.portal.hasOwnProperty("port")&&0===t.portal.port.count?100:Xi("port",e,6250,ga(1.2),"portal")},powered:()=>oc(1),support:()=>-1,effect(){let e=1e4;return l.base_camp&&(e*=1+.4*l.base_camp),`
          ${F("portal_port_effect1",[$(this)[0].support()])}
          ${F("portal_port_effect2",[Math.round(e)])}
          `},action(){return!!Os($(this)[0])&&(Nt("port","portal"),t.portal.purifier.support`
          ${F("portal_base_camp_title")}
          ${F("portal_spire_support")}
          `,reqs:{hell_spire:4},cost:{Money:e=>Xi("base_camp",e,425e6,ga(1.2),"portal"),Supply:e=>Xi("base_camp",e,5e4,ga(1.2),"portal")},powered:()=>oc(1),support:()=>-1,effect(){return`
          ${F("portal_port_effect1",[$(this)[0].support()])}
          ${F("portal_base_camp_effect",[40])}
          `},action(){return!!Os($(this)[0])&&(Nt("base_camp","portal"),t.portal.purifier.support!t.portal.hasOwnProperty("bridge")||t.portal.bridge.count<10||e?`
          ${F("portal_bridge_title")}
          ${F("requires_segmemts",[10])}
          `:`
          ${F("portal_bridge_title")}
          `,reqs:{hell_spire:5},queue_size:1,queue_complete:()=>10-t.portal.bridge.count,cost:{Species:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?fc(10):0,Money:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?5e8:0,Supply:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?1e5:0},effect(e){let a=(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0);if(a<10){let e=10-a;return`
          ${F("portal_bridge_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          ${F("portal_bridge_effect2")}
          `}return F("portal_bridge_complete")},action(){return!!(t.portal.bridge.count<10&&Os($(this)[0]))&&(Nt("bridge","portal"),t.portal.bridge.count>=10&&(t.portal.sphinx={count:0},t.tech.hell_spire=6,$a()),!0)}},sphinx:{id:"portal-sphinx",title:()=>7===t.tech.hell_spire?F("portal_sphinx_solve"):F("portal_sphinx_title"),desc:F("portal_sphinx_desc"),reqs:{hell_spire:6},queue_complete:()=>8-t.tech.hell_spire,cost:{Knowledge(e){let a=(e||0)+(!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2);return 1===a?5e7:0===a?4e7:0}},effect(e){let a=(e||0)+(!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2);return F(1===a?"portal_sphinx_effect2":2===a?"portal_sphinx_effect3":"portal_sphinx_effect")},action(){if(Os($(this)[0])){if(6===t.tech.hell_spire)return t.tech.hell_spire=7,Di(F("portal_sphinx_msg"),"info",!1,["progress","hell"]),$a(),!0;if(7===t.tech.hell_spire)return t.tech.hell_spire=8,$a(),Di(F("portal_sphinx_answer_msg"),"info",!1,["progress","hell"]),!0}return!1}},bribe_sphinx:{id:"portal-bribe_sphinx",title:F("portal_sphinx_bribe"),desc:F("portal_sphinx_desc"),reqs:{hell_spire:7},condition:()=>!(!t.tech.hell_spire||7!==t.tech.hell_spire||t.tech.sphinx_bribe),cost:{Soul_Gem:()=>250,Supply:()=>5e5},effect:()=>F("portal_sphinx_bribe_effect"),action(){return!(!Os($(this)[0])||7!==t.tech.hell_spire||t.tech.sphinx_bribe||(t.tech.sphinx_bribe=1,t.resource.Codex.display=!0,t.resource.Codex.amount=1,Di(F("portal_sphinx_bribe_msg"),"info",!1,["progress","hell"]),0))},post(){t.tech.sphinx_bribe&&(ms(),$a(),Ei("portal-bribe_sphinx"))}},spire_survey:{id:"portal-spire_survey",title:F("portal_spire_survey_title"),desc:F("portal_spire_survey_title"),reqs:{hell_spire:8},grant:["hell_spire",9],queue_complete:()=>t.tech.hell_spire>=9?0:1,cost:{Oil:()=>12e5,Helium_3:()=>9e5},effect:F("portal_spire_survey_effect"),action(){return!!Os($(this)[0])&&(t.portal.mechbay={count:0,on:0,bay:0,max:0,active:0,scouts:0,mechs:[]},t.portal.spire={count:1,progress:0,boss:"",type:"",status:{}},Ta(),Di(F("portal_spire_survey_msg"),"info",!1,["progress","hell"]),!0)},post(){t.tech.hell_spire&&9===t.tech.hell_spire&&($a(),Ei("portal-spire_survey"))}},mechbay:{id:"portal-mechbay",title:F("portal_mechbay_title"),desc:()=>`
          ${F("portal_mechbay_title")}
          ${F("portal_spire_support")}
          `,reqs:{hell_spire:9},cost:{Money:e=>Xi("mechbay",e,1e8,1.2,"portal"),Supply:e=>Xi("mechbay",e,25e4,1.2,"portal")},powered:()=>oc(1),support:()=>-1,special:!0,sAction(){t.settings.civTabs=2,t.settings.govTabs=4,t.settings.tabLoad||(Ct("mTabCivic"),Ei("portal-mechbay"))},effect(){let e=t.portal.hasOwnProperty("mechbay")?t.portal.mechbay.bay:0,a=t.portal.hasOwnProperty("mechbay")?t.portal.mechbay.max:0;return`
          ${F("portal_port_effect1",[$(this)[0].support()])}
          ${F("portal_mechbay_effect")}
          ${F("portal_mechbay_effect2",[e,a])}
          `},action(){return!!Os($(this)[0])&&(Nt("mechbay","portal"),t.portal.purifier.support0,cost:{},effect(){let e=t.portal.hasOwnProperty("spire")?t.portal.spire.count:0,a=t.portal.hasOwnProperty("spire")?`${F(`portal_spire_type_${t.portal.spire.type}`)}`:"?",r="";t.portal.hasOwnProperty("spire")&&Object.keys(t.portal.spire.status).length>0&&(r=`
          ${F("portal_spire_hazard",[Object.keys(t.portal.spire.status).map((e=>`${F(`portal_spire_status_${e}`)}`)).join(", ")])}
          `);let s=t.portal.hasOwnProperty("spire")?`${+t.portal.spire.progress.toFixed(3)}%`:"0%",i=`
          ${F("portal_spire_effect",[e])}
          ${F("portal_spire_type",[a])}
          ${r}
          ${F("portal_spire_progress",[s])}
          `,c=t.portal.hasOwnProperty("spire")?t.portal.spire.boss:"crazed",o=`
          ${F("portal_spire_mob",[`${F(`portal_mech_boss_${c}`)}`])}
          `,n="???",l="???";if(t.stats.spire){let e=function(e){let t="laser",a="laser";return Object.keys(Ca[e].weapon).forEach((function(r){Ca[e].weapon[r]>Ca[e].weapon[t]&&(t=r),Ca[e].weapon[r]0&&(n=F(`portal_mech_weapon_${e.w}`)),t>=5&&(l=F(`portal_mech_weapon_${e.r}`))}return`
          ${i}
          ${o}
          ${F("portal_spire_mob_weak",[`${n}`])}
          ${F("portal_spire_mob_resist",[`${l}`])}
          `},mscan(){let e=0;return Object.keys(t.stats.spire).forEach((function(a){let r=t.portal.hasOwnProperty("spire")?t.portal.spire.boss:"crazed";t.stats.spire.hasOwnProperty(a)&&t.stats.spire[a].hasOwnProperty(r)&&t.stats.spire[a][r]>e&&(e=t.stats.spire[a][r])})),e},wide:!0,action:()=>!1},waygate:{id:"portal-waygate",title:F("portal_waygate_title"),desc:e=>!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2||e?`
          ${F("portal_waygate_title")}
          ${F("requires_segmemts",[10])}
          `:`
          ${F("portal_waygate_title")}
          `,reqs:{waygate:1},queue_size:1,queue_complete:()=>t.tech.waygate>=2?0:10-t.portal.waygate.count,cost:{Species:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?fc(25):0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?fc(25):0,Money:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?1e9:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?1e9:0,Supply:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?5e5:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?5e5:0,Blood_Stone:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?5:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?5:0},powered:()=>t.portal.hasOwnProperty("waygate")&&t.portal.waygate.count>=10?1:0,power_reqs:{waygate:2},effect(e){let a=(e||0)+(t.tech.waygate&&t.tech.waygate>=2?10:t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0);if(a>=10){let e=t.portal.hasOwnProperty("waygate")?`${+t.portal.waygate.progress.toFixed(3)}%`:"0%";return`
          ${F("portal_waygate_open")}
          ${F("portal_waygate_progress",[e])}
          `}{let e=10-a;return`
          ${F("portal_waygate_effect")}
          ${F("space_dwarf_collider_effect2",[e])}
          `}},action(){return!!(t.portal.waygate.count<10&&t.tech.waygate&&1===t.tech.waygate&&Os($(this)[0]))&&(Nt("waygate","portal"),t.portal.waygate.count>=10&&(t.tech.waygate=2,t.portal.waygate.count=1,$a()),!0)}}}};function ga(e){let a=t.portal.hasOwnProperty("spire")&&t.blood.spire?e-(t.portal.spire.count-1)/2500:e;return a>=1.01?a:1.01}const fa=function(e){return va&&!e||(va=1e3,t.hasOwnProperty("pillars")&&Object.keys(t.pillars).forEach((function(e){t.pillars[e]&&(va-=12)}))),va};var va;function ya(e){let t=Oa("gate");return Math.round(e/(t.supress>.01?t.supress:.01))}function ba(){let e=Math.round(650/ke(1,"hellArmy"));return i.gun_emplacement&&(e-=i.gun_emplacement*(t.tech.hell_gun>=2?2:1),e<0&&(e=0)),e}function wa(){return ma}function $a(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||4!==t.settings.spaceTabs))return;let e=$("#portal");rc(e),e.append($(`

          ${F("tab_portal")}

          `)),!t.tech.portal||t.tech.portal<2||Object.keys(ma).forEach((function(a){let r=a.replace("prtl_","");if(t.settings.portal[`${r}`]){let r="string"==typeof ma[a].info.name?ma[a].info.name:ma[a].info.name(),s="";if(ma[a].info.hasOwnProperty("prop")&&(s=ma[a].info.prop()),ma[a].info.support){let i=ma[a].info.support;ma[a].info.hide_support?e.append(`

          ${r}

          ${s}
          `):e.append(`

          ${r}

          {{ support }}/{{ s_max }}${s}
          `),sc({el:`#sr${a}`,data:t.portal[i],filters:{filter(){return ma[a].info.filter(...arguments)}}})}else e.append(`

          ${r}

          ${s}
          `);Ti(a,(function(){return"string"==typeof ma[a].info.desc?ma[a].info.desc:ma[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),"prtl_fortress"===a&&ka(e,!0),Object.keys(ma[a]).forEach((function(e){"info"!==e&&Gt(ma,a,e)&&fs(ma[a][e],"portal",e)}))}}))}function xa(e){switch(e){case"hostiles":return t.portal.fortress.threat>=2e3?`${F("fortress_threat",[t.portal.fortress.threat])} ${F("fortress_threat_high")}`:t.portal.fortress.threat<1e3?`${F("fortress_threat",[t.portal.fortress.threat])} ${F("fortress_threat_low")}`:`${F("fortress_threat",[t.portal.fortress.threat])} ${F("fortress_threat_medium")}`;case"threatLevel":{let e=t.portal.fortress.threat;return e<1e3?`${F("fortress_threat_level")} ${F("fortress_threat_level1")}`:e<1500?`${F("fortress_threat_level")} ${F("fortress_threat_level2")}`:e>=5e3?`${F("fortress_threat_level")} ${F("fortress_threat_level6")}`:e>=3e3?`${F("fortress_threat_level")} ${F("fortress_threat_level5")}`:e>=2e3?`${F("fortress_threat_level")} ${F("fortress_threat_level4")}`:`${F("fortress_threat_level")} ${F("fortress_threat_level3")}`}case"hireLabel":return F("civics_garrison_hire_mercenary_cost",[Math.round(he("m_cost")).toLocaleString()])}}function ka(e,a){if(!t.settings.tabLoad)switch(t.settings.civTabs){case 1:if(4!==t.settings.spaceTabs)return;break;case 2:if(3!==t.settings.govTabs)return;break;default:return}if(!t.tech.portal||t.tech.portal<2)return;let r=a?"fort":"gFort",s=a?$(`
          `):$("#gFort");a?e.append(s):(s.length>0?rc(s):(s=$(`
          `),e.append(s)),s.append(`

          ${F("portal_fortress_name")}

          `));let c=$("
          ");s.append(c);let o=$(`${F("fortress_defense")} {{ f.garrison | defensive }}`);c.append(o);let n=$(`${F("fortress_spotted")} {{ f.threat }}`);c.append(n);let l=$('{{ f.threat | threat }}');c.append(l);let u=$("
          ");s.append(u),u.append($(`${F("fortress_wall")} {{ Math.ceil(f.walls) }}%`));let d=$("
          ");s.append(d),d.append($(`${F("fortress_army")}`)),d.append($('«')),d.append($('{{ f.garrison | patrolling }}')),d.append($('»')),d.append($(`${F("fortress_patrol")}`)),d.append($('«')),d.append($('{{ f.patrols }}')),d.append($('»')),d.append($(`${F("fortress_patrol_size")}`)),d.append($('«')),d.append($('{{ f.patrol_size }}')),d.append($('»')),d.append($(``));let _="light"===t.settings.theme?' type="is-light"':' type="is-dark"',p=$("
          ");d.append(p),p.append($(`${F("fortress_patrol_reports")}`)),p.append($(`${F("fortress_surv_reports")}`)),p.append($(`${F("fortress_nocrew")}`)),a&&s.append($(`
          ${F("civics_garrison_training")} - ${F("arpa_to_complete")} {{ g.rate, g.progress | trainTime }} {{ g.progress }}%
          `)),sc({el:`#${r}`,data:{f:t.portal.fortress,g:t.civic.garrison,s:t.settings},methods:{defense:()=>F("fortress_defense"),hostiles:()=>xa("hostiles"),threatLevel:()=>xa("threatLevel"),aNext(){let e=y();t.portal.fortress.garrisont.civic.garrison.workers&&(t.portal.fortress.garrison=t.civic.garrison.workers),t.portal.fortress.assigned=t.portal.fortress.garrison,sc({el:"#garrison"},"update"))},aLast(){let e=y(),a=t.portal.fortress.patrols*t.portal.fortress.patrol_size;i.soul_forge&&(a+=ba()),t.portal.hasOwnProperty("guard_post")&&(a+=la(t.portal.guard_post.on)),t.portal.fortress.garrison>a&&(t.portal.fortress.garrison-=e,t.portal.fortress.garrison0&&(t.portal.fortress.patrols-=e,t.portal.fortress.patrols<0&&(t.portal.fortress.patrols=0))},patSizeInc(){let e=y();t.portal.fortress.patrol_size1&&(t.portal.fortress.patrol_size-=e,t.portal.fortress.patrol_size<1&&(t.portal.fortress.patrol_size=1))},wall(){let e=t.portal.fortress.walls;return e>=75?"has-text-success":e<=25?"has-text-danger":"has-text-warning"},threaten(){let e=t.portal.fortress.threat;return e<1e3?"has-text-success":e>=2e3?"has-text-danger":"has-text-warning"},hire(){let e=y(),a=!0;for(;a&&e>0;){let r=Math.round(1.24**t.civic.garrison.workers*75)-50;r>25e3&&(r=25e3),t.civic.garrison.m_use>0&&(r*=1.1**t.civic.garrison.m_use),t.race.brute&&(r/=2),r=Math.round(r),t.civic.garrison.workers=r?(t.resource.Money.amount-=r,t.civic.garrison.workers++,t.civic.garrison.m_use++,t.portal.fortress.garrison++,t.portal.fortress.assigned=t.portal.fortress.garrison,sc({el:"#garrison"},"update")):a=!1,e--}},hireLabel:()=>xa("hireLabel"),observation(){t.settings.civTabs=$("#mainTabs > nav ul li").length-1,t.settings.tabLoad||Ga()}},filters:{defensive:e=>qa(e),patrolling(e){let a=e-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(i.soul_forge){let e=ba();e<=a&&(a-=e)}return t.portal.hasOwnProperty("guard_post")&&(a-=la(t.portal.guard_post.on)),a},threat:e=>F(e<1e3?"fortress_threat_level1":e<1500?"fortress_threat_level2":e>=5e3?"fortress_threat_level6":e>=3e3?"fortress_threat_level5":e>=2e3?"fortress_threat_level4":"fortress_threat_level3"),trainTime:(e,t)=>ic(0===e?-1:(100-t)/(4*e))}}),["hostiles","threatLevel","armyLabel","patLabel","patSizeLabel","hireLabel"].forEach((function(e){Ti(`hf${r}${e}`,(function(){switch(e){case"hostiles":case"threatLevel":return xa("hostiles");case"armyLabel":return F("fortress_stationed");case"patLabel":return F("fortress_patrol_desc",[t.portal.fortress.patrols]);case"patSizeLabel":return F("fortress_patrol_size_desc",[t.portal.fortress.patrol_size]);case"hireLabel":return xa("hireLabel")}}),{elm:`#${r} span.${e}`})})),Ti(`hf${r}observe`,(function(){return F("hell_observation_tooltip")}),{elm:`#${r} button.observe`})}function qa(e){let a=e-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(i.soul_forge){let e=ba();e<=a&&(a-=e)}t.portal.hasOwnProperty("guard_post")&&(a-=la(t.portal.guard_post.on));let r=0;if(t.civic.garrison.wounded>t.civic.garrison.workers-t.portal.fortress.garrison&&(r=t.civic.garrison.wounded-(t.civic.garrison.workers-t.portal.fortress.garrison),r>a&&(r=a)),i.war_droid){let e=i.war_droid-t.portal.fortress.patrols>0?i.war_droid-t.portal.fortress.patrols:0;a+=t.tech.hdroid?la(2*e):la(e)}let s=t.tech.turret?t.tech.turret>=2?70:50:35;return Math.round(ke(a,"hellArmy",r))+(i.turret?i.turret*s:0)}function Ma(e,a,r,s){let i=Math.round(Math.log2(e/t.portal.fortress.patrol_size/(a||1)))-Math.rand(0,a),c=0;if(i>0){i>t.portal.fortress.patrol_size&&(i=t.portal.fortress.patrol_size),i=Math.rand(r?1:0,i+1),c=Math.rand(0,i+1);let e=i-c;if(t.race.instinct){let t=Math.floor(c*(ui.instinct.vars()[1]/100));c-=t,e+=t}s.wounded=e,s.died=c,t.civic.garrison.wounded+=e,t.civic.garrison.workers-=c,t.stats.died+=c}return c}function Pa(e){t.race.witch_hunter&&t.portal.hasOwnProperty("soul_capacitor")&&i.soul_capacitor>0&&(t.portal.soul_capacitor.energy+=e,t.portal.soul_capacitor.energy>t.portal.soul_capacitor.ecap&&(t.portal.soul_capacitor.energy=t.portal.soul_capacitor.ecap))}function Oa(e,a){switch(e){case"ruins":{let e=a||la(i.guard_post),r=75*(i.arcology||0),s=ke(e,"hellArmy",0);t.race.holy&&(s*=1+ui.holy.vars()[1]/100);let c=Pi("unicorn");c>0&&(s*=1+ui.holy.vars(1)[1]/100*c);let o=(s+r)/5e3;return{supress:o>1?1:o,rating:s+r}}case"gate":{let e=Oa("ruins",a),r=100*(i.gate_turret||0);t.race.holy&&(r*=1+ui.holy.vars()[1]/100);let s=Pi("unicorn");s>0&&(r*=1+ui.holy.vars(1)[1]/100*s);let c=(e.rating+r)/7500;return{supress:c>1?1:c,rating:e.rating+r}}default:return 0}}const Ca={fire_elm:{weapon:{laser:1.05,flame:0,plasma:.25,kinetic:.5,missile:.5,sonic:1,shotgun:.75,tesla:.65},nozone:{freeze:!0,flooded:!0},amp:{hot:1.75,humid:.8,steam:.9}},water_elm:{weapon:{laser:.65,flame:.5,plasma:1,kinetic:.2,missile:.5,sonic:.5,shotgun:.25,tesla:.75},nozone:{hot:!0,freeze:!0},amp:{steam:1.5,river:1.1,flooded:2,rain:1.75,humid:1.25}},rock_golem:{weapon:{laser:1,flame:.5,plasma:1,kinetic:.65,missile:.95,sonic:.75,shotgun:.35,tesla:0},nozone:{},amp:{}},bone_golem:{weapon:{laser:.45,flame:.35,plasma:.55,kinetic:1,missile:1,sonic:.75,shotgun:.75,tesla:.15},nozone:{},amp:{}},mech_dino:{weapon:{laser:.85,flame:.05,plasma:.55,kinetic:.45,missile:.5,sonic:.35,shotgun:.5,tesla:1},nozone:{},amp:{}},plant:{weapon:{laser:.42,flame:1,plasma:.65,kinetic:.2,missile:.25,sonic:.75,shotgun:.35,tesla:.38},nozone:{},amp:{}},crazed:{weapon:{laser:.5,flame:.85,plasma:.65,kinetic:1,missile:.35,sonic:.15,shotgun:.95,tesla:.6},nozone:{},amp:{}},minotaur:{weapon:{laser:.32,flame:.5,plasma:.82,kinetic:.44,missile:1,sonic:.15,shotgun:.2,tesla:.35},nozone:{},amp:{}},ooze:{weapon:{laser:.2,flame:.65,plasma:1,kinetic:0,missile:0,sonic:.85,shotgun:0,tesla:.15},nozone:{},amp:{}},zombie:{weapon:{laser:.35,flame:1,plasma:.45,kinetic:.08,missile:.8,sonic:.18,shotgun:.95,tesla:.05},nozone:{},amp:{}},raptor:{weapon:{laser:.68,flame:.55,plasma:.85,kinetic:1,missile:.44,sonic:.22,shotgun:.33,tesla:.66},nozone:{},amp:{}},frost_giant:{weapon:{laser:.9,flame:.82,plasma:1,kinetic:.25,missile:.08,sonic:.45,shotgun:.28,tesla:.5},nozone:{hot:!0},amp:{freeze:2.5,hail:1.65}},swarm:{weapon:{laser:.02,flame:1,plasma:.04,kinetic:.01,missile:.08,sonic:.66,shotgun:.38,tesla:.45},nozone:{},amp:{}},dragon:{weapon:{laser:.18,flame:0,plasma:.12,kinetic:.35,missile:1,sonic:.22,shotgun:.65,tesla:.15},nozone:{},amp:{}},mech_dragon:{weapon:{laser:.84,flame:.1,plasma:.68,kinetic:.18,missile:.75,sonic:.22,shotgun:.28,tesla:1},nozone:{},amp:{}},construct:{weapon:{laser:.5,flame:.2,plasma:.6,kinetic:.34,missile:.9,sonic:.08,shotgun:.28,tesla:1},nozone:{},amp:{}},beholder:{weapon:{laser:.75,flame:.15,plasma:1,kinetic:.45,missile:.05,sonic:.01,shotgun:.12,tesla:.3},nozone:{},amp:{}},worm:{weapon:{laser:.55,flame:.38,plasma:.45,kinetic:.2,missile:.05,sonic:1,shotgun:.02,tesla:.01},nozone:{},amp:{}},hydra:{weapon:{laser:.85,flame:.75,plasma:.85,kinetic:.25,missile:.45,sonic:.5,shotgun:.6,tesla:.65},nozone:{},amp:{}},colossus:{weapon:{laser:1,flame:.05,plasma:.75,kinetic:.45,missile:1,sonic:.35,shotgun:.35,tesla:.5},nozone:{},amp:{}},lich:{weapon:{laser:.1,flame:.1,plasma:.1,kinetic:.45,missile:.75,sonic:.35,shotgun:.75,tesla:.5},nozone:{},amp:{}},ape:{weapon:{laser:1,flame:.95,plasma:.85,kinetic:.5,missile:.5,sonic:.05,shotgun:.35,tesla:.68},nozone:{},amp:{}},bandit:{weapon:{laser:.65,flame:.5,plasma:.85,kinetic:1,missile:.5,sonic:.25,shotgun:.75,tesla:.25},nozone:{},amp:{}},croc:{weapon:{laser:.65,flame:.05,plasma:.6,kinetic:.5,missile:.5,sonic:1,shotgun:.2,tesla:.75},nozone:{},amp:{}},djinni:{weapon:{laser:0,flame:.35,plasma:1,kinetic:.15,missile:0,sonic:.65,shotgun:.22,tesla:.4},nozone:{},amp:{}},snake:{weapon:{laser:.5,flame:.5,plasma:.5,kinetic:.5,missile:.5,sonic:.5,shotgun:.5,tesla:.5},nozone:{},amp:{}},centipede:{weapon:{laser:.5,flame:.85,plasma:.95,kinetic:.65,missile:.6,sonic:0,shotgun:.5,tesla:.01},nozone:{},amp:{}},spider:{weapon:{laser:.65,flame:1,plasma:.22,kinetic:.75,missile:.15,sonic:.38,shotgun:.9,tesla:.18},nozone:{},amp:{}},manticore:{weapon:{laser:.05,flame:.25,plasma:.95,kinetic:.5,missile:.15,sonic:.48,shotgun:.4,tesla:.6},nozone:{},amp:{}},fiend:{weapon:{laser:.75,flame:.25,plasma:.5,kinetic:.25,missile:.75,sonic:.25,shotgun:.5,tesla:.5},nozone:{},amp:{}},bat:{weapon:{laser:.16,flame:.18,plasma:.12,kinetic:.25,missile:.02,sonic:1,shotgun:.9,tesla:.58},nozone:{},amp:{}},medusa:{weapon:{laser:.35,flame:.1,plasma:.3,kinetic:.95,missile:1,sonic:.15,shotgun:.88,tesla:.26},nozone:{},amp:{}},ettin:{weapon:{laser:.5,flame:.35,plasma:.8,kinetic:.5,missile:.25,sonic:.3,shotgun:.6,tesla:.09},nozone:{},amp:{}},faceless:{weapon:{laser:.6,flame:.28,plasma:.6,kinetic:0,missile:.05,sonic:.8,shotgun:.15,tesla:1},nozone:{},amp:{}},enchanted:{weapon:{laser:1,flame:.02,plasma:.95,kinetic:.2,missile:.7,sonic:.05,shotgun:.65,tesla:.01},nozone:{},amp:{}},gargoyle:{weapon:{laser:.15,flame:.4,plasma:.3,kinetic:.5,missile:.5,sonic:.85,shotgun:1,tesla:.2},nozone:{},amp:{}},chimera:{weapon:{laser:.38,flame:.6,plasma:.42,kinetic:.85,missile:.35,sonic:.5,shotgun:.65,tesla:.8},nozone:{},amp:{}},gorgon:{weapon:{laser:.65,flame:.65,plasma:.65,kinetic:.65,missile:.65,sonic:.65,shotgun:.65,tesla:.65},nozone:{},amp:{}},kraken:{weapon:{laser:.75,flame:.35,plasma:.75,kinetic:.35,missile:.5,sonic:.18,shotgun:.05,tesla:.85},nozone:{},amp:{}},homunculus:{weapon:{laser:.05,flame:1,plasma:.1,kinetic:.85,missile:.65,sonic:.5,shotgun:.75,tesla:.2},nozone:{},amp:{}}};function ja(e,a){let r=9999,s=1e7;switch(e){case"small":{let e=t.blood.prepared&&t.blood.prepared>=2?5e4:75e3;s=a?2.5*e:e,r=a?20:1}break;case"medium":s=a?45e4:18e4,r=a?100:4;break;case"large":s=a?925e3:375e3,r=a?500:20;break;case"titan":s=a?15e5:75e4,r=a?1500:75;break;case"collector":{let e=t.blood.prepared&&t.blood.prepared>=2?8e3:1e4;s=a?2.5*e:e,r=1}}return{s:r,c:s}}function Sa(){if((t.settings.tabLoad||2===t.settings.civTabs&&4===t.settings.govTabs)&&(rc($("#mechLab")),t.portal.hasOwnProperty("mechbay")&&t.settings.showMechLab)){let e=$("#mechLab");t.portal.mechbay.hasOwnProperty("blueprint")||(t.portal.mechbay.blueprint={size:"small",hardpoint:["laser"],chassis:"tread",equip:[],infernal:!1});let a=$('
          ');e.append(a);let r=$(`
          ${F("portal_mech_assembly")} - {{ b.size | slabel }} {{ b.chassis | clabel }}
          `);a.append(r),r.append(` | ${F("portal_mech_bay_space")}: {{ m.bay }} / {{ m.max }}`),r.append(` | ${F("portal_mech_sup_avail")}: {{ p.supply | round }} / {{ p.sup_max }}`);let s=t.blood.prepared&&t.blood.prepared>=3?`${F("portal_mech_infernal")} (${F("portal_mech_infernal_effect",[25])})`:"";a.append(`
          ${F("portal_mech_space")} {{ b.size | bay }} | ${F("portal_mech_cost")} {{ b.size | price }} | ${F("portal_mech_soul",[t.resource.Soul_Gem.name])} {{ b.size | soul }}${s}
          `),a.append("
          {{ b.size | desc }}
          ");let i=$('
          ');a.append(i);let c="";["small","medium","large","titan","collector"].forEach((function(e,t){c+=`${F(`portal_mech_size_${e}`)}`})),i.append(`\n ${c}\n `);let o="";["wheel","tread","biped","quad","spider","hover"].forEach((function(e,t){o+=`${F(`portal_mech_chassis_${e}`)}`})),i.append(`\n ${o}\n `);for(let e=0;e<4;e++){let t="";["laser","kinetic","shotgun","missile","flame","plasma","sonic","tesla"].forEach((function(a,r){t+=`${F(`portal_mech_weapon_${a}`)}`})),i.append(`\n ${t}\n `)}let n=t.blood.prepared?5:4;for(let e=0;e{{ '${a}' | equipment }}`})),i.append(`\n ${t}\n `)}a.append(`
          `),sc({el:"#mechAssembly",data:{p:t.portal.purifier,m:t.portal.mechbay,b:t.portal.mechbay.blueprint},methods:{build(){let e=ja(t.portal.mechbay.blueprint.size,t.portal.mechbay.blueprint.infernal),a=e.c,r=e.s,s=Fa(t.portal.mechbay.blueprint.size),i=t.portal.mechbay.max-t.portal.mechbay.bay;if(t.portal.purifier.supply>=a&&i>=s&&t.resource.Soul_Gem.amount>=r){t.portal.purifier.supply-=a,t.resource.Soul_Gem.amount-=r;let e=zc(t.portal.mechbay.blueprint);t.portal.mechbay.mechs.push(e),t.portal.mechbay.bay+=s,t.portal.mechbay.active++}},setSize(e){switch(t.portal.mechbay.blueprint.size=e,"collector"===e?t.portal.mechbay.blueprint.hardpoint.length=0:"small"===e||"medium"===e?(0===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push("laser"),t.portal.mechbay.blueprint.hardpoint.length=1):(0===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push("laser"),1===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"plasma":"laser"),"titan"===e?2===t.portal.mechbay.blueprint.hardpoint.length&&(t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"shotgun":"laser"),t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"kinetic":"laser")):t.portal.mechbay.blueprint.hardpoint.length=2),e){case"small":t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?1:0;break;case"medium":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("shields"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?2:1;break;case"collector":case"large":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length<2&&t.portal.mechbay.blueprint.equip.push("shields"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("grapple"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?3:2;break;case"titan":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length<2&&t.portal.mechbay.blueprint.equip.push("shields"),t.portal.mechbay.blueprint.equip.length<3&&t.portal.mechbay.blueprint.equip.push("grapple"),t.portal.mechbay.blueprint.equip.length<4&&t.portal.mechbay.blueprint.equip.push("seals"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("stabilizer"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?5:4}},setType(e){t.portal.mechbay.blueprint.chassis=e},setWep(e,a){t.portal.mechbay.blueprint.hardpoint[a]=e,sc({el:"#mechAssembly"},"update")},setEquip(e,a){t.portal.mechbay.blueprint.equip[a]=e,sc({el:"#mechAssembly"},"update")},vis:e=>"collector"!==t.portal.mechbay.blueprint.size&&(0===e||"large"===t.portal.mechbay.blueprint.size&&e<2||"titan"===t.portal.mechbay.blueprint.size),eVis(e){let a=t.blood.prepared?1:0;switch(t.portal.mechbay.blueprint.size){case"small":return 1===a&&0===e;case"medium":return e<=0+a;case"collector":case"large":return e<=1+a;case"titan":return!0}}},filters:{bay:e=>Fa(e),price:e=>ja(e,t.portal.mechbay.blueprint.infernal).c,soul:e=>ja(e,t.portal.mechbay.blueprint.infernal).s,slabel:e=>F(`portal_mech_size_${e}`),clabel:e=>F(`portal_mech_chassis_${e}`),wlabel:e=>F(`portal_mech_weapon_${e}`),desc:e=>F(`portal_mech_size_${e}_desc`),round:e=>Math.round(e),equipment(e){if("special"!==e)return F(`portal_mech_equip_${e}`);let a="jumpjet";switch(t.portal.mechbay.blueprint.size){case"large":a="battery";break;case"titan":a="target"}return F(`portal_mech_equip_${a}`)}}}),["size","chassis","weapon","equip"].forEach((function(e){let a=1;"weapon"===e?a=4:"equip"===e&&(a=n);for(let r=0;r');e.append(l),za(),rc($("#mechList")),$("#mechList").append(`\n
          \n ${F("portal_mech_scrap")}\n | ${F("portal_mech")} #{{index + 1}}: \n {{ mech.infernal ? "${F("portal_mech_infernal")} " : "" }}{{ mech | size }} {{ mech | chassis }}\n
          \n
          \n \n
          \n
          \n \n
          \n
          \n
          `),sc({el:"#mechList",data:t.portal.mechbay,methods:{scrap(e){if(t.portal.mechbay.mechs[e]){let a=ja(t.portal.mechbay.mechs[e].size,t.portal.mechbay.mechs[e].infernal),r=Fa(t.portal.mechbay.mechs[e].size);t.portal.purifier.supply+=Math.floor(a.c/3),t.resource.Soul_Gem.amount+=Math.floor(a.s/2),t.portal.purifier.supply>t.portal.purifier.sup_max&&(t.portal.purifier.supply=t.portal.purifier.sup_max),t.portal.mechbay.mechs.splice(e,1),t.portal.mechbay.bay-=r,t.portal.mechbay.active--}}},filters:{equipment(e,t){if("special"!==e)return F(`portal_mech_equip_${e}`);let a="jumpjet";switch(t){case"large":a="battery";break;case"titan":a="target"}return F(`portal_mech_equip_${a}`)},weapon:e=>F(`portal_mech_weapon_${e}`),size:e=>F(`portal_mech_size_${e.size}`),chassis:e=>F(`portal_mech_chassis_${e.chassis}`)}}),function(){let e=$("#mechList")[0];Sortable.create(e,{onEnd(e){let a=e.from.querySelectorAll(":scope > .mechRow");e.from.insertBefore(e.item,a[e.oldIndex+(e.oldIndex>e.newIndex)]);let r=t.portal.mechbay.mechs;r.splice(e.newDraggableIndex,0,r.splice(e.oldDraggableIndex,1)[0]),Aa()}})}(),$("#mechList .scrap").each((function(e,a){Ti(`mechList-scrap${e}`,(function(){let a=ja(t.portal.mechbay.mechs[e].size,t.portal.mechbay.mechs[e].infernal);return F("portal_mech_scrap_refund",[Math.floor(a.c/3),Math.floor(a.s/2)])}),{elm:a})}))}}function Fa(e){switch(e){case"small":return 2;case"medium":return t.blood.prepared&&t.blood.prepared>=2?4:5;case"large":return t.blood.prepared&&t.blood.prepared>=2?8:10;case"titan":return t.blood.prepared&&t.blood.prepared>=2?20:25;case"collector":return 1;case"default":return 25}}function za(){let e=$("#mechList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}function Aa(){let e=25*(l.mechbay||0),a=0,r=0,s=0;for(let i of t.portal.mechbay.mechs)a+=Fa(i.size),a<=e&&(r++,"small"===i.size&&s++);t.portal.mechbay.bay=a,t.portal.mechbay.max=e,t.portal.mechbay.active=r,t.portal.mechbay.scouts=s}function Ta(){let e=["sand","swamp","forest","jungle","rocky","gravel","muddy","grass","brush","concrete"];if(t.portal.spire.type=e[Math.floor(m(0,e.length))],t.portal.spire.count>=10){t.portal.spire.status={};let e=["freeze","hot","corrosive","humid","windy","hilly","mountain","radioactive","quake","dust","river","tar","steam","flooded","fog","rain","hail","chasm","dark","gravity"];if(Ea(e[Math.floor(m(0,e.length))]),t.portal.spire.count>=25&&t.portal.spire.count<=100){let a=105-t.portal.spire.count;Math.floor(m(0,a)<=5)&&Ea(e[Math.floor(m(0,e.length))])}else if(t.portal.spire.count>100&&t.portal.spire.count<=250){Ea(e[Math.floor(m(0,e.length))]);let a=260-t.portal.spire.count;Math.floor(m(0,a)<=10)&&Ea(e[Math.floor(m(0,e.length))])}else if(t.portal.spire.count>250&&t.portal.spire.count<=1e3){Ea(e[Math.floor(m(0,e.length))]),Ea(e[Math.floor(m(0,e.length))]);let a=1025-t.portal.spire.count;Math.floor(m(0,a)<=25)&&Ea(e[Math.floor(m(0,e.length))])}else t.portal.spire.count>1e3&&(Ea(e[Math.floor(m(0,e.length))]),Ea(e[Math.floor(m(0,e.length))]),Ea(e[Math.floor(m(0,e.length))]))}let a=Object.keys(Ca).filter((function(e){let a=Object.keys(Ca[e].nozone);return!a.some((e=>Object.keys(t.portal.spire.status).includes(e)))&&!a.includes(t.portal.spire.type)}));t.portal.spire.boss=a[Math.floor(m(0,a.length))]}function Ea(e){t.portal.spire.status.freeze||t.portal.spire.status.hot?"freeze"!==e&&"hot"!==e&&(t.portal.spire.status[e]=!0):t.portal.spire.status.rain||t.portal.spire.status.hail?"rain"!==e&&"hail"!==e&&(t.portal.spire.status[e]=!0):t.portal.spire.status[e]=!0}function Ia(e,a,r){return!e.equip.includes("special")||"small"!==e.size&&"medium"!==e.size&&"collector"!==e.size||a<1&&(a+=(1-a)*(r.includes("gravity")?.1:.2)),"small"!==e.size&&a<1&&(a+=(r.includes("fog")||r.includes("dark")?.005:.01)*t.portal.mechbay.scouts)>1&&(a=1),a}function Ka(e,t){return t<1&&0!==t&&e.equip.includes("special")&&"titan"===e.size&&(t+=.25*(1-t)),e.equip.includes("special")&&"large"===e.size&&(t*=1.02),t}function La(e,t){let a=1;switch(t){case"freeze":e.equip.includes("radiator")||(a=.25);break;case"hot":e.equip.includes("coolant")||(a=.25);break;case"corrosive":e.equip.includes("ablative")||(a=e.equip.includes("shields")?.75:.25);break;case"humid":case"rain":e.equip.includes("seals")||(a=.75);break;case"windy":"hover"===e.chassis&&(a=.5);break;case"hilly":"spider"!==e.chassis&&(a=.75);break;case"mountain":"spider"===e.chassis||e.equip.includes("grapple")||(a=e.equip.includes("flare")?.75:.5);break;case"radioactive":e.equip.includes("shields")||(a=.5);break;case"quake":e.equip.includes("stabilizer")||(a=.25);break;case"dust":e.equip.includes("seals")||(a=.5);break;case"river":"hover"!==e.chassis&&(a=.65);break;case"tar":"quad"!==e.chassis&&(a="tread"===e.chassis||"wheel"===e.chassis?.5:.75);break;case"steam":e.equip.includes("shields")||(a=.75);break;case"flooded":"hover"!==e.chassis&&(a=.35);break;case"fog":e.equip.includes("sonar")||(a=.2);break;case"hail":e.equip.includes("ablative")||e.equip.includes("shields")||(a=.75);break;case"chasm":e.equip.includes("grapple")||(a=.1);break;case"dark":e.equip.includes("infrared")||(a=e.equip.includes("flare")?.25:.1);break;case"gravity":switch(e.size){case"medium":a=.8;break;case"large":a=.45;break;case"titan":a=.25}}return a}function Na(e,a){let r=a||t.portal.spire.type,s=1;switch(e.chassis){case"wheel":switch(r){case"sand":s=["small","medium"].includes(e.size)?.9:.85;break;case"swamp":s=["small","medium"].includes(e.size)?.35:.18;break;case"jungle":s=["small","medium"].includes(e.size)?.92:.85;break;case"rocky":s=["small","medium"].includes(e.size)?.65:.5;break;case"gravel":s=["small","medium"].includes(e.size)?1:.95;break;case"muddy":s=["small","medium"].includes(e.size)?.85:.58;break;case"grass":s=["small","medium"].includes(e.size)?1.3:1.2;break;case"brush":s=["small","medium"].includes(e.size)?.9:.8;break;case"concrete":s=["small","medium"].includes(e.size)?1.1:1}break;case"tread":switch(r){case"sand":s=["small","medium"].includes(e.size)?1.15:1.1;break;case"swamp":s=["small","medium"].includes(e.size)?.55:.4;break;case"forest":s=["small","medium"].includes(e.size)?1:.95;break;case"jungle":s=["small","medium"].includes(e.size)?.95:.9;break;case"rocky":s=["small","medium"].includes(e.size)?.65:.5;break;case"gravel":s=["small","medium"].includes(e.size)?1.3:1.2;break;case"muddy":s=["small","medium"].includes(e.size)?.88:.72}break;case"biped":switch(r){case"sand":s=["small","medium"].includes(e.size)?.78:.65;break;case"swamp":s=["small","medium"].includes(e.size)?.68:.5;break;case"forest":s=["small","medium"].includes(e.size)?1:.95;break;case"jungle":s=["small","medium"].includes(e.size)?.82:.7;break;case"rocky":s=["small","medium"].includes(e.size)?.48:.4;break;case"muddy":s=["small","medium"].includes(e.size)?.85:.7;break;case"grass":s=["small","medium"].includes(e.size)?1.25:1.2;break;case"brush":s=["small","medium"].includes(e.size)?.92:.85}break;case"quad":switch(r){case"sand":s=["small","medium"].includes(e.size)?.86:.75;break;case"swamp":s=["small","medium"].includes(e.size)?.58:.42;break;case"forest":s=["small","medium"].includes(e.size)?1.25:1.2;break;case"rocky":case"brush":s=["small","medium"].includes(e.size)?.95:.9;break;case"gravel":s=["small","medium"].includes(e.size)?.9:.8;break;case"muddy":s=["small","medium"].includes(e.size)?.68:.5;break;case"grass":s=["small","medium"].includes(e.size)?1:.95}break;case"spider":switch(r){case"sand":s=["small","medium"].includes(e.size)?.75:.65;break;case"swamp":s=["small","medium"].includes(e.size)?.9:.78;break;case"forest":s=["small","medium"].includes(e.size)?.82:.75;break;case"jungle":s=["small","medium"].includes(e.size)?.77:.65;break;case"rocky":s=["small","medium"].includes(e.size)?1.25:1.2;break;case"gravel":s=["small","medium"].includes(e.size)?.86:.75;break;case"muddy":s=["small","medium"].includes(e.size)?.92:.82;break;case"brush":s=["small","medium"].includes(e.size)?1:.95}break;case"hover":switch(r){case"swamp":s=["small","medium"].includes(e.size)?1.35:1.2;break;case"forest":s=["small","medium"].includes(e.size)?.65:.48;break;case"jungle":s=["small","medium"].includes(e.size)?.55:.35;break;case"rocky":s=["small","medium"].includes(e.size)?.82:.68;break;case"muddy":s=["small","medium"].includes(e.size)?1.15:1.08;break;case"brush":s=["small","medium"].includes(e.size)?.78:.7}}return s}function Da(e){let a=e.infernal?31.25:25,r=Na(e),s=[];return Object.keys(t.portal.spire.status).forEach((function(t){s.push(t),a*=La(e,t)})),a*=Ia(e,r,s),a}function Ba(e,a){let r=function(e){switch(e){case"small":return.0025;case"medium":return.0075;case"large":return.01;case"titan":return.012;default:return 0}}(e.size);if(0===r)return 0;if(e.hasOwnProperty("infernal")&&e.infernal&&t.blood.prepared&&t.blood.prepared>=3&&(r*=1.25),a){t.stats.achieve.gladiator&&t.stats.achieve.gladiator.l>0&&(r*=1+.1*t.stats.achieve.gladiator.l),t.blood.wrath&&(r*=1+t.blood.wrath/20),"titan"===e.size&&(r*=1.1);let a=Yc();t.stats.spire.hasOwnProperty(a)&&t.stats.spire[a].hasOwnProperty("dlstr")?r/=100+25*t.stats.spire[a].dlstr:r/=100;let s=0;for(let t=0;t0&&(r*=1+.2*t.stats.achieve.gladiator.l),t.blood.wrath&&(r*=1+t.blood.wrath/20),"concrete"===t.portal.spire.type)switch(e.size){case"small":r*=.92;break;case"medium":r*=.95;break;case"titan":r*=1.25}let a=Na(e),s=[];Object.keys(t.portal.spire.status).forEach((function(t){s.push(t),r*=La(e,t)})),r*=Ia(e,a,s),r/=t.portal.spire.count;let i=0;for(let a=0;a nav ul li").length-1&&!e)return;let a=$("#mTabObserve");rc(a);let r=$('
          ');if(a.append(r),r.append(`\n \n \n \n \n \n \n `),sc({el:"#hellObservations",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(rc($("#h_Report")),rc($("#h_Analysis")),e){case 0:Ua();break;case 1:Ra()}return e}}}),t.settings.tabLoad)Ua(),Ra();else switch(t.settings.hellTabs){case 0:Ua();break;case 1:Ra()}}function Ra(){if(!t.settings.tabLoad&&1!==t.settings.hellTabs)return;let e=$("#h_Analysis"),a=$('
          ');e.append(a);let r=$("
          ");a.append(r);let s=$('
          ');a.append(s);let i=$('
          ');s.append(i);let c=$('
          '),o=$('
          ');i.append(c),i.append(o),r.append(`\n
          \n

          ${F("tab_settings")}

          \n
          \n
          \n ${F("hell_analysis_expanded")}\n ${F("hell_analysis_average")}\n ${F("hell_analysis_hyperSlow")}\n
          \n
          \n ${F("hell_analysis_time_game_days")}\n ${F("hell_analysis_time_seconds")}\n ${F("hell_analysis_time_minutes")}\n ${F("hell_analysis_time_hours")}\n ${F("hell_analysis_time_days")}\n
          \n `),sc({el:"#hellAnalysis",data:{s:t.portal.observe.settings,r:t.race}});let n=function(e,t){e=e.toFixed(t);let a=Math.floor(e),r=(+(e-a).toFixed(t)).toString().substring(1);return a.toLocaleString()+r},l=function(e,a,r){if(e){switch("game_days"!==r&&t.portal.observe.settings.hyperSlow&&(t.race.slow&&(a*=1+ui.slow.vars()[0]/100),t.race.hyper&&(a*=1-ui.hyper.vars()[0]/100)),e/=a,r){case"seconds":e/=5;break;case"minutes":e*=12;break;case"hours":e*=720;break;case"days":e*=17280}e=t.portal.observe.settings.expanded?n(e,5):k(e,5,!0)}return F("hell_analysis_time_average",[e,F(`hell_analysis_time_${r}_abbr`)])},u=function(e,a){if(!e)return;let r=$(`#${e}`);rc(r),r.append(`\n

          ${F("hell_analysis_"+a)}

          ${"period"===a?'

          {{ | resetLabel }}

          ':""}
          \n

          {{ st.${a}.start | startLabel }}

          \n

          {{ st.${a}.days, s.display | time }}

          \n

          {{ st.${a}.kills, 'kills', s.average | genericMulti }}

          {{ s.dropKills | dropdownLabel }}

          \n
          \n

          {{ st.${a}.kills.drones, 'kills_drones', s.average | genericSub }}

          \n

          {{ st.${a}.kills.patrols, 'kills_patrols', s.average | genericSub }}

          \n

          {{ st.${a}.kills.sieges, 'kills_sieges', s.average | genericSub }}

          \n

          {{ st.${a}.kills.guns, 'kills_guns', s.average | genericSub }}

          \n

          {{ st.${a}.kills.soul_forge, 'kills_soul_forge', s.average | genericSub }}

          \n

          {{ st.${a}.kills.turrets, 'kills_turrets', s.average | genericSub }}

          \n
          \n

          {{ st.${a}.gems, 'gems', s.average | genericMulti }}

          {{ s.dropGems | dropdownLabel }}

          \n
          \n

          {{ st.${a}.gems.patrols, 'gems_patrols', s.average | genericSub }}

          \n

          {{ st.${a}.gems.guns, 'gems_guns', s.average | genericSub }}

          \n

          {{ st.${a}.gems.soul_forge, 'gems_soul_forge', s.average | genericSub }}

          \n

          {{ st.${a}.gems.crafted, 'gems_crafted', s.average | genericSub }}

          \n

          {{ st.${a}.gems.turrets, 'gems_turrets', s.average | genericSub }}

          \n

          {{ st.${a}.gems.surveyors, 'gems_surveyors', s.average | genericSub }}

          \n
          \n

          {{ st.${a}.wounded, 'wounded', s.average | generic }}

          \n

          {{ st.${a}.died, 'died', s.average | generic }}

          \n

          {{ st.${a}.revived, 'revived', s.average | generic }}

          \n

          {{ st.${a}.surveyors, 'surveyors', s.average | generic }}

          \n

          {{ st.${a}.sieges, 'sieges', s.average | generic }}

          \n `),sc({el:`#${e}`,data:{st:t.portal.observe.stats,s:t.portal.observe.settings,p:t.portal,r:t.race,sg:t.resource.Soul_Gem},methods:{resetObservations(){Object.keys(t.portal.observe.stats.period).forEach((function(e){["kills","gems"].includes(e)?Object.keys(t.portal.observe.stats.period[e]).forEach((function(a){t.portal.observe.stats.period[e][a]=0})):"start"===e?t.portal.observe.stats.period.start={year:t.city.calendar.year,day:t.city.calendar.day}:t.portal.observe.stats.period[e]=0}))},toggleDropdown(e){t.portal.observe.settings[e]=!t.portal.observe.settings[e]}},filters:{generic:(e,r,s)=>F("hell_analysis_number_display",s?[F(`hell_analysis_${r}`),l(e,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]:[F(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+e.toFixed(5)).toLocaleString():k(e,5,!0)]),genericSub:(e,r,s)=>s?"ᄂ"+F("hell_analysis_number_display",[F(`hell_analysis_${r}`),l(e,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]):"ᄂ"+F("hell_analysis_number_display",[F(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+e.toFixed(5)).toLocaleString():k(e,5,!0)]),genericMulti(e,r,s){let i=0;return Object.keys(e).forEach((function(t){i+=e[t]})),F("hell_analysis_number_display",s?[F(`hell_analysis_${r}`),l(i,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]:[F(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+i.toFixed(5)).toLocaleString():k(i,5,!0)])},time(e,a){switch("game_days"!==a&&t.portal.observe.settings.hyperSlow&&(t.race.slow&&(e*=1+ui.slow.vars()[0]/100),t.race.hyper&&(e*=1-ui.hyper.vars()[0]/100)),a){case"seconds":e*=5;break;case"minutes":e/=12;break;case"hours":e/=720;break;case"days":e/=17280}return F("hell_analysis_time",[F(`hell_analysis_time_${a}`),t.portal.observe.settings.expanded?n(e,8):k(e,5,!0)])},resetLabel:()=>F("hell_analysis_period_reset"),startLabel:e=>F("hell_analysis_start",[e.year,e.day]),dropdownLabel:e=>e?"⮝":"⮟"}})};u("hellAnalysisTotal","total"),u("hellAnalysisPeriod","period"),a=$("#hellAnalysis");let d=$("
          ");a.append(d),d.append(`

          ${F("hell_graph_create")}

          `);let _=$('
          ');d.append(_),sc({el:"#hellGraphCreator",methods:{createGraph(){this.$buefy.modal.open({parent:this,component:{template:''}});let e=setInterval((function(){if($("#modalBox").length>0){clearInterval(e),$("#modalBox").append($(`

          ${F("hell_graph_title")}

          `));var a=$('
          ');$("#modalBox").append(a);let r=$('
          ');a.append(r);let s={chartType:"pie",name:"",chartName:"",data:[],radioFake:"",showGroups:!0},i={show:!1,message:""};r.append(`\n

          ${F("hell_graph_name")}

          \n `),r.append(`\n
          \n
          \n

          ${F("hell_graph_type")}

          \n
          \n
          \n ${F("hell_graph_pie")}\n
          \n
          \n `);let c=$('
          ');r.append(c),c.append(`

          ${F("hell_graph_data")}

          `),Object.keys(t.portal.observe.stats).forEach((function(e){["kills","gems"].forEach((function(t){c.append(`
          \n ${F("hell_graph_datapoint",[F(`hell_analysis_${e}`),F(`hell_analysis_${t}`)])}\n
          `)}))})),r.append(`\n
          \n
          \n

          {{ e.message }}

          \n
          \n
          \n \n
          \n
          \n `),sc({el:"#specialModal",data:{s,e:i,sg:t.resource.Soul_Gem},methods:{nameUpdate(e){s.chartName!==e&&(i.show=!1,s.chartName=e)},dataOptions(e){switch(e){case"pie":s.showGroups=!0;break;case"bar":s.showGroups=!1}},setData(e,t){i.show=!1,s.data=[e,t]},createGraph(){if(!s.name)return i.show=!0,void(i.message=F("hell_graph_error_name_blank"));if(0===s.data.length)return i.show=!0,void(i.message=F("hell_graph_error_data_missing"));let e=[],a=[];"pie"===s.chartType&&Object.keys(t.portal.observe.stats[s.data[0]][s.data[1]]).forEach((function(t){e.push(F(`hell_analysis_${s.data[1]}_${t}`)),a.push([s.data[0],s.data[1],t])}));let r=function(e,a,r,s,i){let c=`hellGraph-${t.portal.observe.graphID}`;return t.portal.observe.graphID++,t.portal.observe.graphs[c]={id:c,chartID:`${c}-chart`,name:e,type:a,labels:r,data:s,settings:i},c}(s.chartName,s.chartType,e,a,{title:s.chartName});Ha(_,t.portal.observe.graphs[r]),document.dispatchEvent(new KeyboardEvent("keydown",{key:"Escape"})),document.dispatchEvent(new KeyboardEvent("keyup",{key:"Escape"}))}}})}}),50)}}}),Object.keys(t.portal.observe.graphs).forEach((function(e){Ha(_,t.portal.observe.graphs[e])}))}function Ha(e,a){let r=a.id;_[r]&&_[r].graph.destroy();let s=$(`
          `);e.append(s),s.append(`
          \n
          \n

          \n

          Delete

          \n
          \n
          \n

          ${a.name}

          \n
          \n
          `);let i=$('
          ');s.append(i),sc({el:`#graph-${r}-controls`,methods:{deleteGraph(){_[r].graph.destroy(),delete _[r],delete t.portal.observe.graphs[r],rc($(`#graph-${r}-container`),!0)}}});let c=$(``);i.append(c),_[r]={data:a.data},"pie"===a.type&&(_[r].graph=function(e,a,r,s){let i=[];return r.forEach((function(e){i.push(3===e.length?t.portal.observe.stats[e[0]][e[1]][e[2]]:t.portal.observe.stats[e[0]][e[1]])})),new Chart(e,{type:"pie",data:{labels:a,datasets:[{data:i,backgroundColor:["rgb(255, 99, 132)","rgb(54, 162, 235)","rgb(255, 205, 86)","rgb(201, 203, 207)","rgb(75, 192, 192)","#B86BFF","#48c774"],hoverOffset:4}]},options:{plugins:{legend:{display:!1}}}})}(c,a.labels,a.data,a.settings))}function Ua(){if(!t.settings.tabLoad&&0!==t.settings.hellTabs)return;Wa();let e="",a=$("#h_Report"),r=$('
          ');a.append(r);let s=$('
          ');r.append(s),s.append(`

          ${F("hell_report_log")}

          \n \n \n\t\t \n \n
          `);let i=$('
          ');s.append(i),r.append($('
          '));let c={year:0,day:0};Object.keys(d).length&&(c.year=Object.keys(d)[0].split("-")[1],c.day=Object.keys(d[`year-${c.year}`])[0].split("-")[1]);let o=function(a,r){for(Wa(!0)&&(e="",a=Object.keys(d)[0].split("-")[1],r=Object.keys(d[`year-${c.year}`])[0].split("-")[1]);a${F("year")+" "+a+" | "+F("day")+" "+r}${d[`year-${a}`][`day-${r}`].foundGem?'':""}\n `+e;r=1}for(;r${F("year")+" "+a+" | "+F("day")+" "+r}${d[`year-${a}`][`day-${r}`].foundGem?``:""}\n `+e;c.year=a,c.day=r;let s=$("#hellReportList");rc(s),s.append(e),sc({el:"#hellReportList",methods:{reportLoad(e,t){n(e,t)}}})},n=function(e,a){if(!e||!a)return;let r=$("#hellReportDisplay");rc(r);let s=d[`year-${e}`][`day-${a}`],i=$('
          ');r.append(i);let c=0,o=0;if(Object.keys(s.stats.kills).forEach((function(e){c+=s.stats.kills[e]})),Object.keys(s.stats.gems).forEach((function(e){o+=s.stats.gems[e]})),i.append(`

          ${F("hell_report_log_stats",[e,a])}

          `),i.append(`
          \n

          ${F("hell_report_log_stats_kills",[c])}

          \n

          ${F("hell_report_log_stats_gems",[o])}

          \n

          ${F("hell_report_log_stats_wounded",[s.stats.wounded])}

          \n

          ${F("hell_report_log_stats_died",[s.stats.died])}

          \n
          `),r.append(`

          ${F("hell_report_log_report",[e,a])}

          `),r.append(`

          ${F("hell_report_log_start",[s.start])}

          `),s.drones&&Object.keys(s.drones).forEach((function(e){let t=s.drones[e],a=F("hell_report_log_obj_counter",[F("portal_war_drone_title"),e]);t.encounter?r.append(`

          ${F("hell_report_log_encounter",[a,t.kills])}

          `):r.append(`

          ${F("hell_report_log_encounter_fail",[a])}

          `)})),s.patrols&&Object.keys(s.patrols).forEach((function(e){let a=s.patrols[e],i=F("hell_report_log_obj_counter",[F("hell_report_log_patrol"),e]);if(i=a.droid?F("hell_report_log_patrol_droid",[i]):i,a.encounter){let e=$("

          ");a.ambush?e.append(`${F("hell_report_log_patrol_ambush",[i,a.kills])}`):e.append(`${F("hell_report_log_encounter",[i,a.kills])}`),a.wounded&&e.append(`${a.wounded>1?F("hell_report_log_patrol_wounded_plural",[a.wounded]):F("hell_report_log_patrol_wounded")}`),a.died&&e.append(`${a.died>1?F("hell_report_log_patrol_killed_plural",[a.died]):F("hell_report_log_patrol_killed")}`),a.gem>0&&e.append(`${F("hell_report_log_soul_find",[t.resource.Soul_Gem.name,a.gem])}`),r.append(e)}else r.append(`

          ${F("hell_report_log_encounter_fail",[i])}

          `)})),s.surveyor_finds&&Object.keys(s.surveyor_finds).forEach((function(e){let a=s.surveyor_finds[e],i=F("hell_report_log_obj_counter",[F("job_hell_surveyor"),e]),c=$("

          ");c.append(`${F("hell_report_log_search",[i,a.bodies])}`),a.gem>0&&c.append(`${F("hell_report_log_soul_search",[t.resource.Soul_Gem.name,a.gem])}`),r.append(c)})),s.revived&&r.append(`

          ${s.revived>1?F("hell_report_log_revived_plural",[s.revived]):F("hell_report_log_revived")}

          `),s.patrols_lost&&r.append(`

          ${F("hell_report_log_patrols_lost",[s.patrols_lost])}

          `),s.siege&&(s.siege.destroyed?r.append(`

          ${F("hell_report_log_siege",[s.siege.surveyors,s.siege.soldiers,s.siege.kills])}

          `):r.append(`

          ${F("hell_report_log_siege_fail",[s.siege.damage,s.siege.kills])}

          `)),s.demons&&r.append(`

          ${F("hell_report_log_demons",[s.demons])}

          `),s.surveyors&&r.append(`

          ${s.surveyors>1?F("hell_report_log_surveyors_plural",[s.surveyors]):F("hell_report_log_surveyors")}

          `),s.soul_attractors&&r.append(`

          ${F("hell_report_log_soul_attractors",[s.soul_attractors])}

          `),s.gun_emplacements&&Object.keys(s.gun_emplacements).forEach((function(e){let a=$("

          "),i=s.gun_emplacements[e],c=F("hell_report_log_obj_counter",[F("portal_gun_emplacement_title"),e]);a.append($(`${F("hell_report_log_misc_kills",[c,i.kills,F("portal_pit_name")])}`)),i.gem&&a.append(`${F("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),r.append(a)})),s.soul_forge){let e=$("

          ");e.append(`${F("hell_report_log_soul_forge",[s.soul_forge.kills])}`),s.soul_forge.gem&&e.append(`${F("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),s.soul_forge.gem_craft&&e.append(`${F("hell_report_log_soul_craft",[s.soul_forge.corrupt?F("resource_Corrupt_Gem_name"):t.resource.Soul_Gem.name])}`),r.append(e)}s.gate_turrets&&Object.keys(s.gate_turrets).forEach((function(e){let a=$("

          "),i=s.gate_turrets[e],c=F("hell_report_log_obj_counter",[F("portal_gate_turret_title"),e]);a.append(`${F("hell_report_log_misc_kills",[c,i.kills,F("portal_gate_name")])}`),i.gem&&a.append(`${F("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),r.append(a)})),sc({el:"#hellReportDisplay",data:{g:t.resource.Soul_Gem}})};if(0!==c.day){o(c.year,c.day);let e=c.year,a=c.day;a-1==0?(e--,a=t.city.calendar.orbit):a--,n(e,a)}else c.year=t.city.calendar.year,c.day=t.city.calendar.day;sc({el:"#hellReportLogTitle",methods:{updateList(){o(c.year,c.day)}}}),Ti("hellReportLogs",(function(){return F("hell_report_log_tooltip",[2500])}),{elm:"#hellReport .reportList div:first-child h2"})}function Wa(e){if(!document.getElementById("hellReportList")||e){let e=!1,a=2500,r=(Object.keys(d).length-1)*t.city.calendar.orbit+t.city.calendar.day;if(r>a){let s=Object.keys(d[Object.keys(d)[0]]).length;for(r-t.city.calendar.orbit+s>a&&(e=!0,r-=s,delete d[Object.keys(d)[0]]);r>a;)r-=t.city.calendar.orbit,delete d[Object.keys(d)[0]]}return e}}const Qa={Food:5,Lumber:5,Chrysotile:5,Stone:5,Crystal:6,Furs:8,Copper:25,Iron:40,Aluminium:50,Cement:15,Coal:20,Oil:75,Uranium:550,Steel:100,Titanium:150,Alloy:350,Polymer:250,Iridium:420,Helium_3:620,Deuterium:950,Elerium:2e3,Water:2,Neutronium:1500,Adamantite:2250,Infernite:2750,Nano_Tube:750,Graphene:3e3,Stanene:3600,Bolognium:9e3,Vitreloy:10200,Orichalcum:99e3,Horseshoe:0,Nanite:0,Genes:0,Soul_Gem:0,Corrupt_Gem:0,Codex:0,Cipher:0,Demonic_Essence:0},Za={Food:2,Lumber:2,Chrysotile:1,Stone:2,Crystal:.4,Furs:1,Copper:1,Iron:1,Aluminium:1,Cement:1,Coal:1,Oil:.5,Uranium:.12,Steel:.5,Titanium:.25,Alloy:.2,Polymer:.2,Iridium:.1,Helium_3:.1,Deuterium:.1,Elerium:.02,Water:2,Neutronium:.05,Adamantite:.05,Infernite:.01,Nano_Tube:.1,Graphene:.1,Stanene:.1,Bolognium:.12,Vitreloy:.12,Orichalcum:.05},Va={Food:4.355,Lumber:7.668,Chrysotile:15.395,Stone:20.017,Crystal:5.062,Furs:13.009,Copper:63.546,Iron:55.845,Aluminium:26.9815,Cement:20.009,Coal:12.0107,Oil:5.342,Uranium:238.0289,Steel:55.9,Titanium:47.867,Alloy:45.264,Polymer:120.054,Iridium:192.217,Helium_3:3.0026,Deuterium:2.014,Neutronium:248.74,Adamantite:178.803,Infernite:222.666,Elerium:297.115,Nano_Tube:15.083,Graphene:26.9615,Stanene:33.9615,Bolognium:75.898,Unobtainium:168.59,Vitreloy:41.08,Orichalcum:237.8,Water:18.01,Plywood:7.666,Brick:20.009,Wrought_Iron:55.845,Sheet_Metal:26.9815,Mythril:94.239,Aerogel:7.84,Nanoweave:23.71,Scarletite:188.6,Quantium:241.35},Ja={Lumber:{in:.5,out:25e3},Chrysotile:{in:.5,out:25e3},Stone:{in:.5,out:25e3},Crystal:{in:3,out:25e3},Furs:{in:3,out:25e3},Copper:{in:1.5,out:25e3},Iron:{in:1.5,out:25e3},Aluminium:{in:2.5,out:25e3},Cement:{in:3,out:25e3},Coal:{in:1.5,out:25e3},Oil:{in:2.5,out:12e3},Uranium:{in:5,out:300},Steel:{in:3,out:25e3},Titanium:{in:3,out:25e3},Alloy:{in:6,out:25e3},Polymer:{in:6,out:25e3},Iridium:{in:8,out:25e3},Helium_3:{in:4.5,out:12e3},Deuterium:{in:4,out:1e3},Neutronium:{in:15,out:1e3},Adamantite:{in:12.5,out:1e3},Infernite:{in:25,out:250},Elerium:{in:30,out:250},Nano_Tube:{in:6.5,out:1e3},Graphene:{in:5,out:1e3},Stanene:{in:4.5,out:1e3},Bolognium:{in:18,out:1e3},Vitreloy:{in:14,out:1e3},Orichalcum:{in:10,out:1e3},Plywood:{in:10,out:250},Brick:{in:10,out:250},Wrought_Iron:{in:10,out:250},Sheet_Metal:{in:10,out:250},Mythril:{in:12.5,out:250},Aerogel:{in:16.5,out:250},Nanoweave:{in:18,out:250},Scarletite:{in:35,out:250}};function Ya(){let e={Plywood:[{r:"Lumber",a:100}],Brick:t.race.flier?[{r:"Stone",a:60}]:[{r:"Cement",a:40}],Wrought_Iron:[{r:"Iron",a:80}],Sheet_Metal:[{r:"Aluminium",a:120}],Mythril:[{r:"Iridium",a:100},{r:"Alloy",a:250}],Aerogel:[{r:"Graphene",a:2500},{r:"Infernite",a:50}],Nanoweave:[{r:"Nano_Tube",a:1e3},{r:"Vitreloy",a:40}],Scarletite:[{r:"Iron",a:25e4},{r:"Adamantite",a:7500},{r:"Orichalcum",a:500}],Quantium:[{r:"Nano_Tube",a:1e3},{r:"Graphene",a:1e3},{r:"Elerium",a:25}],Thermite:[{r:"Iron",a:180},{r:"Aluminium",a:60}]};if(t.race.wasteful){let t=1+ui.wasteful.vars()[0]/100;Object.keys(e).forEach((function(a){for(let r=0;r=2){let e=t.tech.foundry>=5?t.tech.foundry>=8?.08:.05:.03;er.general.add.push({name:F("city_foundry"),manual:t.city.foundry.count*e,auto:t.city.foundry.count*e})}if(t.tech.foundry>=3&&Object.keys(er).forEach((function(e){t.city.foundry[e]&&t.city.foundry[e]>1&&er[e].add.push({name:F("tech_apprentices"),manual:(t.city.foundry[e]-1)*Me(.03),auto:(t.city.foundry[e]-1)*Me(.03)})})),t.tech.foundry>=4&&t.city.sawmill&&er.Plywood.add.push({name:F("city_sawmill"),manual:.02*t.city.sawmill.count,auto:.02*t.city.sawmill.count}),t.tech.foundry>=6&&er.Brick.add.push({name:F("city_foundry"),manual:.02*t.city.foundry.count,auto:.02*t.city.foundry.count}),t.tech.foundry>=7&&(er.general.add.push({name:F("city_factory")+` (${F("tab_city5")})`,manual:.05*i.factory,auto:.05*i.factory}),t.tech.mars>=4&&er.general.add.push({name:F("city_factory")+` (${F("tab_space")})`,manual:.05*i.red_factory,auto:.05*i.red_factory}),t.interstellar.int_factory&&i.int_factory&&er.general.add.push({name:F("interstellar_int_factory_title"),manual:.1*i.int_factory,auto:.1*i.int_factory})),t.space.fabrication&&c.fabrication&&er.general.add.push({name:F("space_red_fabrication_title"),manual:c.fabrication*t.civic.colonist.workers*Me(e?.05:.02),auto:c.fabrication*t.civic.colonist.workers*Me(e?.05:.02)}),i.stellar_forge&&(er.Mythril.add.push({name:F("interstellar_stellar_forge_title"),manual:.05*i.stellar_forge,auto:.05*i.stellar_forge}),er.general.add.push({name:F("interstellar_stellar_forge_title"),manual:0,auto:.1*i.stellar_forge})),i.hell_forge){let e=Oa("ruins");er.general.add.push({name:F("portal_hell_forge_title"),manual:0,auto:.75*i.hell_forge*e.supress}),er.Scarletite.multi.push({name:F("portal_ruins_supressed"),manual:1,auto:e.supress})}if(t.tauceti.tau_factory&&c.tau_factory&&er.general.add.push({name:F("tau_home_tau_factory"),manual:0,auto:c.tau_factory*(t.tech.isolation?2.75:.9)}),t.tech.isolation&&t.tauceti.colony&&c.colony&&er.general.add.push({name:F("tau_home_colony"),manual:.5*c.colony,auto:.5*c.colony}),c.zero_g_lab&&i.zero_g_lab||c.infectious_disease_lab&&i.infectious_disease_lab){let e=ht("spc_enceladus");er.Quantium.multi.push({name:F("space_syndicate"),manual:1,auto:e})}if(t.tech.alien_crafting&&c.infectious_disease_lab&&i.infectious_disease_lab){let e=1+.65*Math.min(c.infectious_disease_lab,i.infectious_disease_lab);er.Quantium.multi.push({name:F("tech_infectious_disease_lab_alt"),manual:1,auto:e})}if(t.race.crafty&&er.general.add.push({name:F("wiki_arpa_crispr_crafty"),manual:.03,auto:.03}),t.race.ambidextrous&&er.general.add.push({name:F("trait_ambidextrous_name"),manual:ui.ambidextrous.vars()[0]*t.race.ambidextrous/100,auto:ui.ambidextrous.vars()[0]*t.race.ambidextrous/100}),t.race.rigid&&er.general.add.push({name:F("trait_rigid_name"),manual:-ui.rigid.vars()[0]/100,auto:-ui.rigid.vars()[0]/100}),"socialist"===t.civic.govern.type&&er.general.multi.push({name:F("govern_socialist"),manual:1+ae.socialist()[0]/100,auto:1+ae.socialist()[0]/100}),t.race.casting&&t.race.casting.crafting){let e=1+t.race.casting.crafting/(t.race.casting.crafting+75),a=1+2*t.race.casting.crafting/(2*t.race.casting.crafting+75);er.general.multi.push({name:F("modal_pylon_casting"),manual:e,auto:a})}"magic"===t.race.universe&&er.general.multi.push({name:F("universe_magic"),manual:.8,auto:.8}),t.tech.v_train&&er.general.multi.push({name:F("tech_vocational_training"),manual:1,auto:2}),t.genes.crafty&&er.general.multi.push({name:F("tab_arpa_crispr")+" "+F("wiki_arpa_crispr_crafty"),manual:1,auto:1+.5*(t.genes.crafty-1)}),t.race.living_tool&&er.general.multi.push({name:F("trait_living_tool_name"),manual:1,auto:1+ui.living_tool.vars()[1]/100}),t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=1&&er.general.multi.push({name:F("evo_challenge_orbit_decay"),manual:1,auto:1.1}),t.race.ambidextrous&&er.general.multi.push({name:F("trait_ambidextrous_name"),manual:1,auto:1+ui.ambidextrous.vars()[1]*t.race.ambidextrous/100}),t.blood.artisan&&er.general.multi.push({name:F("tab_arpa_blood")+" "+F("arpa_blood_artisan_title"),manual:1,auto:1+t.blood.artisan/100});let a=Dr();a>0&&er.general.multi.push({name:F("faith"),manual:1,auto:1+a/("antimatter"===t.race.universe?1.5:3)}),t.prestige.Plasmid.count>0&&er.general.multi.push({name:F("resource_Plasmid_plural_name"),manual:Br()/8+1,auto:Br()/8+1}),t.genes.challenge&&t.genes.challenge>=2&&er.general.multi.push({name:F("mastery"),manual:1+lc()/(t.race.weak_mastery?50:100),auto:1+lc()/(t.race.weak_mastery?50:100)})}});var er;function tr(e){if(e)switch(e){case"market":jr();break;case"storage":Sr();break;case"ejector":zr();break;case"supply":Tr();break;case"alchemy":Ir()}else jr(),Sr(),zr(),Tr(),Ir()}function ar(e){"market"===e?(tr("market"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;if(a.resource[e].tradable){var r=$(`
          `);$("#market").append(r),ur(`#market-${e}`,r,e,t,!0)}})),sr()):"storage"===e?(tr("storage"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;if(a.resource[e].stackable){var r=$(`
          `);$("#resStorage").append(r),fr(`#stack-${e}`,r,e,t)}})),sr()):"ejector"===e?(tr("ejector"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;Va[e]&&Ar(e,t)}))):"supply"===e?(tr("supply"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;Ja[e]&&Er(e,t)}))):"alchemy"===e&&(tr("alchemy"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let r=a.resource[e].color,s=a.resource[e].tradable;Za[e]&&"magic"===t.race.universe&&(t.resource[e].basic=s,Kr(e,r,s))})))}function rr(e){if("protoplasm"===t.race.species){let a=100;t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1&&(a+=50*(t.stats.achieve.mass_extinction.l-1)),ir("RNA",e,a,1,!1),ir("DNA",e,a,1,!1)}ir("Money",e,1e3,1,!1,!1,"success"),ir(t.race.species,e,0,0,!1,!1,"warning"),ir("Slave",e,0,0,!1,!1,"warning"),ir("Mana",e,0,1,!1,!1,"warning"),ir("Energy",e,0,0,!1,!1,"warning"),ir("Sus",e,0,0,!1,!1,"warning"),ir("Knowledge",e,100,1,!1,!1,"warning"),ir("Zen",e,0,0,!1,!1,"warning"),ir("Crates",e,0,0,!1,!1,"warning"),ir("Containers",e,0,0,!1,!1,"warning"),ir("Food",e,250,1,!0,!0),ir("Lumber",e,200,1,!0,!0),ir("Chrysotile",e,200,1,!0,!0),ir("Stone",e,200,1,!0,!0),ir("Crystal",e,200,1,!0,!0),ir("Furs",e,100,1,!0,!0),ir("Copper",e,100,1,!0,!0),ir("Iron",e,100,1,!0,!0),ir("Aluminium",e,50,1,!0,!0),ir("Cement",e,100,1,!0,!0),ir("Coal",e,50,1,!0,!0),ir("Oil",e,0,1,!0,!1),ir("Uranium",e,10,1,!0,!1),ir("Steel",e,50,1,!0,!0),ir("Titanium",e,50,1,!0,!0),ir("Alloy",e,50,1,!0,!0),ir("Polymer",e,50,1,!0,!0),ir("Iridium",e,0,1,!0,!0),ir("Helium_3",e,0,1,!0,!1),ir("Water",e,0,1,!1,!1,"advanced"),ir("Deuterium",e,0,1,!1,!1,"advanced"),ir("Neutronium",e,0,1,!1,!1,"advanced"),ir("Adamantite",e,0,1,!1,!0,"advanced"),ir("Infernite",e,0,1,!1,!1,"advanced"),ir("Elerium",e,1,1,!1,!1,"advanced"),ir("Nano_Tube",e,0,1,!1,!1,"advanced"),ir("Graphene",e,0,1,!1,!0,"advanced"),ir("Stanene",e,0,1,!1,!0,"advanced"),ir("Bolognium",e,0,1,!1,!0,"advanced"),ir("Vitreloy",e,0,1,!1,!0,"advanced"),ir("Orichalcum",e,0,1,!1,!0,"advanced"),ir("Unobtainium",e,0,1,!1,!1,"advanced"),ir("Materials",e,0,1,!1,!1,"advanced"),ir("Horseshoe",e,-2,0,!1,!1,"advanced"),ir("Nanite",e,0,1,!1,!1,"advanced"),ir("Genes",e,-2,0,!1,!1,"advanced"),ir("Soul_Gem",e,-2,0,!1,!1,"advanced"),ir("Plywood",e,-1,0,!1,!1,"danger"),ir("Brick",e,-1,0,!1,!1,"danger"),ir("Wrought_Iron",e,-1,0,!1,!1,"danger"),ir("Sheet_Metal",e,-1,0,!1,!1,"danger"),ir("Mythril",e,-1,0,!1,!1,"danger"),ir("Aerogel",e,-1,0,!1,!1,"danger"),ir("Nanoweave",e,-1,0,!1,!1,"danger"),ir("Scarletite",e,-1,0,!1,!1,"danger"),ir("Quantium",e,-1,0,!1,!1,"danger"),ir("Corrupt_Gem",e,-2,0,!1,!1,"caution"),ir("Codex",e,-2,0,!1,!1,"caution"),ir("Cipher",e,0,1,!1,!1,"caution"),ir("Demonic_Essence",e,-2,0,!1,!1,"caution"),e||(or("Blood_Stone","caution"),or("Artifact","caution"),or("Plasmid"),or("AntiPlasmid"),or("Phage"),or("Dark"),or("Harmony"),or("AICore"))}function sr(){"protoplasm"!==t.race.species&&(function(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=t.race.no_trade?" nt":"";var a=$(`
          ${F("resource_market_trade_routes")} / {{ mtrade }}
          `);a.append($(`${F("cancel_all_routes")}`)),$("#market").append(a),sc({el:"#tradeTotal",data:t.city.market,methods:{zero(){Object.keys(t.resource).forEach((function(e){t.resource[e].trade&&(t.city.market.trade-=Math.abs(t.resource[e].trade),t.resource[e].trade=0,$r(e))}))}},filters:{tdeCnt(e){let a=$c(17,11);return(100===e&&!t.tech.isolation&&!t.race.cataclysm||10===e&&(t.tech.isolation||t.race.cataclysm))&&a.length>0?"10"+a:e}}}),Ti("tradeTotalPopover",(function(){let e=$('
          ');return r.hasOwnProperty("t_route")&&Object.keys(r.t_route).forEach((function(t){r.t_route[t]>0&&e.append(``)})),e.append(``),e}),{elm:"#tradeTotalPopover > span"})}(),(t.settings.tabLoad||4===t.settings.civTabs&&0===t.settings.marketTabs)&&($("#market").append($(`

          ${F("galaxy_trade")}

          `)),_r()),function(){if(t.settings.tabLoad||4===t.settings.civTabs&&1===t.settings.marketTabs){var e=$(`
          ${F("resource_Crates_name")}{{ cr.amount }} / {{ cr.max }}${F("resource_Containers_name")}{{ cn.amount }} / {{ cn.max }}
          `);$("#resStorage").append(e),sc({el:"#crateTotal",data:{cr:t.resource.Crates,cn:t.resource.Containers}})}}())}function ir(e,r,s,i,c,o,n){if(n=n||"info",t.resource[e]||(t.resource[e]={}),cr(e),t.race.artifical&&"Food"===e&&(o=!1),r)return;var l;t.resource[e].hasOwnProperty("display")||(t.resource[e].display=!1),t.resource[e].hasOwnProperty("value")||(t.resource[e].value=t.race.truepath?2*Qa[e]:Qa[e]),t.resource[e].hasOwnProperty("amount")||(t.resource[e].amount=0),t.resource[e].hasOwnProperty("max")||(t.resource[e].max=s),t.resource[e].hasOwnProperty("diff")||(t.resource[e].diff=0),t.resource[e].hasOwnProperty("delta")||(t.resource[e].delta=0),t.resource[e].hasOwnProperty("rate")||(t.resource[e].rate=i),"Mana"===e&&(t.resource[e].gen=0,t.resource[e].gen_d=0),t.resource[e].stackable=o,t.resource[e].crates||(t.resource[e].crates=0),t.resource[e].containers||(t.resource[e].containers=0),!t.resource[e].trade&&c&&(t.resource[e].trade=0),l=-1===t.resource[e].max||-2===t.resource[e].max?$(`

          {{ name | namespace }}

          {{ amount | diffSize }}
          `):$(`

          {{ name | namespace }}

          {{ amount | size }} / {{ max | size }}
          `),o?l.append($(`+`)):(-1!==s||-1===s&&0===i&&t.race.no_craft||"Scarletite"===e||"Quantium"===e)&&l.append($(""));let u=!1;if(0!==i||-1===s&&0===i&&t.race.no_craft||"Scarletite"===e||"Quantium"===e)l.append($(`{{ diff | diffSize }} /s`));else if(-1!==s||t.race.no_craft||"Scarletite"===e||"Quantium"===e)l.append($(""));else{let t=$('');l.append(t);let a=[1,5];for(let r=0;r+${a[r]}`));t.append($(`+A`)),u=!0}$("#resources").append(l);var d={template:''};if(sc({el:`#res${e}`,data:t.resource[e],filters:{size:function(e){return e?k(e,0):e},diffSize:function(a){return"Horseshoe"===e&&!t.race.hooved&&Tc("fool",2023)&&(a=5),k(a,2)},namespace:e=>e.replace("_"," ")},methods:{resRate:e=>`${e} ${k(t.resource[e].diff,2)} per second`,trigModal(){this.$buefy.modal.open({parent:this,component:d});var a=setInterval((function(){$("#modalBox").length>0&&(clearInterval(a),function(e){$("#modalBox").append($('

          {{ name }} - {{ amount | size }}/{{ max | size }}

          '));let a=$('
          ');if($("#modalBox").append(a),"Food"===e&&!t.race.artifical||t.race.artifical&&"Coal"===e){let e=$c(7,10);e.length>0&&$("#modalBoxTitle").prepend(e)}if("Stone"===e){let e=kc(1,12,!1);e.length>0&&$("#modalBoxTitle").prepend(e)}let r=$('
          ');a.append(r),r.append($(`
          ${F("resource_modal_crate_owned")} {{ crates.amount }}/{{ crates.max }}${F("resource_modal_crate_assigned")} {{ res.crates }}
          `));let s=$(``),i=$(``),c=$(``);if(r.append(s),r.append(i),r.append(c),sc({el:"#modalCrates",data:{crates:t.resource.Crates,res:t.resource[e]},methods:{buildCrate(){Mr()},subCrate(e){pr(e)},addCrate(e){hr(e)}}}),t.resource.Containers.display){let r=$('
          ');a.append(r),r.append($(`
          ${F("resource_modal_container_owned")} {{ containers.amount }}/{{ containers.max }}${F("resource_modal_container_assigned")} {{ res.containers }}
          `));let s=$(``),i=$(``),c=$(``);r.append(s),r.append(i),r.append(c),sc({el:"#modalContainers",data:{containers:t.resource.Containers,res:t.resource[e]},methods:{buildContainer(){Pr()},removeContainer(e){mr(e)},addContainer(e){gr(e)}}})}sc({el:"#modalBoxTitle",data:t.resource[e],filters:{size:function(e){return k(e,0)},diffSize:function(e){return k(e,2)}}}),["modalCrates","modalContainers"].forEach((function(e){["assign","unassign","construct"].forEach((function(t){Ti(`${e}${t}`,function(e,t){if("modalContainers"===e){let e=Cr();switch(t){case"assign":return F("resource_modal_container_assign_desc",[e]);case"unassign":return F("resource_modal_container_unassign_desc",[e]);case"construct":return kr()}}else{let e=Or();switch(t){case"assign":return F("resource_modal_crate_assign_desc",[e]);case"unassign":return F("resource_modal_crate_unassign_desc",[e]);case"construct":return xr()}}}(e,t),{elm:$(`#${e} > .${t}`),attach:"#main"})}))}))}(e))}),50)},showTrigger:()=>t.resource.Crates.display,craft(e,a){if(!t.race.no_craft){let r=Xa(e,"manual").multiplier,s=Ya(),i=Math.floor(t.resource[s[e][0].r].amount/s[e][0].a);for(let a=1;a${t.resource[s[e][i].r].name} ${c}`}return r}}}),wr(`cnt${e}`,e,"c"),u){let a=[1,5,"A"];for(let r=0;r"),i=e,c=a[r],o=+(100*Xa(i,"manual").multiplier).toFixed(0);s.append($(`
          ${F("manual_crafting_hover_bonus",[o.toLocaleString(),t.resource[i].name])}
          `));let n=Ya(),l=$(`
          ${F("manual_crafting_hover_craft")}
          `),u=0;if("number"!=typeof c){if(u=t.resource[n[i][0].r].amount/n[i][0].a,n[i].length>1)for(let e=1;e${k(o/100*u,1)} ${t.resource[i].name}`))}else{u=y()*c;let e=k(o/100*u,1);l.append($(`${e} ${t.resource[i].name}`))}let d=$(`
          ${F("manual_crafting_hover_use")}
          `);for(let e=0;e${k(u*n[i][e].a,1)} ${t.resource[n[i][e].r].name}`)),e+1, "));return s.append(l),s.append(d),s};br(`inc${e}${a[r]}`,e,"manual",s)}}o&&Ti(`con${e}`,(function(){var a=$(`
          ${F("resource_Crates_plural")} ${t.resource[e].crates}
          `);return t.tech.steel_container&&a.append($(`
          ${F("resource_Containers_plural")} ${t.resource[e].containers}
          `)),a})),e!==t.race.species&&"Crates"!==e&&"Containers"!==e&&-1!==s?wr(`inc${e}`,e,"p"):-1===s&&br(`inc${e}`,e,"auto"),$(`#res${e}`).on("mouseover",(function(){$(`.res-${e}`).each((function(){t.resource[e].amount>=$(this).attr(`data-${e}`)?$(this).addClass("hl-ca"):$(this).addClass("hl-cna")}))})),$(`#res${e}`).on("mouseout",(function(){$(`.res-${e}`).each((function(){$(this).removeClass("hl-ca"),$(this).removeClass("hl-cna")}))})),void 0===a.resource&&(a.resource={}),a.resource[e]={color:n,tradable:c,stackable:o}}function cr(e){if(e===t.race.species?t.resource[e].name=Ac("name"):t.resource[e].name="Money"===e?"$":F(`resource_${e}_name`),Tc("fool",2022))switch(e){case"Lumber":t.resource[e].name=F("resource_Stone_name");break;case"Stone":t.resource[e].name=F("resource_Lumber_name");break;case"Copper":t.resource[e].name=F("resource_Iron_name");break;case"Iron":t.resource[e].name=F("resource_Copper_name");break;case"Steel":t.resource[e].name=F("resource_Titanium_name");break;case"Titanium":t.resource[e].name=F("resource_Steel_name");break;case"Coal":t.resource[e].name=F("resource_Oil_name");break;case"Oil":t.resource[e].name=F("resource_Coal_name");break;case"Alloy":t.resource[e].name=F("resource_Polymer_name");break;case"Polymer":t.resource[e].name=F("resource_Alloy_name");break;case"Graphene":t.resource[e].name=F("resource_Stanene_name");break;case"Stanene":t.resource[e].name=F("resource_Graphene_name");break;case"Plywood":t.resource[e].name=F("resource_Brick_name");break;case"Brick":t.resource[e].name=F("resource_Plywood_name");break;case"Genes":t.resource[e].name=F("resource_Soul_Gem_name");break;case"Soul_Gem":t.resource[e].name=F("resource_Genes_name");break;case"Slave":t.resource[e].name=F("resource_Peon_name")}if("Horseshoe"===e&&(t.resource[e].name=Bc()),t.race.artifical&&"Genes"===e&&(t.resource[e].name=F("resource_Program_name")),t.race.sappy)"Stone"===e&&(t.resource[e].name=F("resource_Amber_name"));else if(t.race.flier)switch(e){case"Stone":t.resource[e].name=F("resource_Clay_name");break;case"Brick":t.resource[e].name=F("resource_Mud_Brick_name")}if(t.race.soul_eater&&"Food"===e&&(t.resource[e].name=F("resource_Souls_name")),t.race.evil)switch(e){case"Lumber":t.resource[e].name=F("resource_Bones_name");break;case"Furs":t.resource[e].name=F("resource_Flesh_name");break;case"Plywood":t.resource[e].name=F("resource_Boneweave_name")}if(t.race.artifical&&"Food"===e&&(t.resource[e].name=F("resource_Signal_name")),Tc("halloween").active)switch(e){case"Food":t.resource[e].name=F("resource_Candy_name");break;case"Lumber":t.resource[e].name=F("resource_Bones_name");break;case"Stone":t.resource[e].name=F("resource_RockCandy_name");break;case"Furs":t.resource[e].name=F("resource_Webs_name");break;case"Plywood":t.resource[e].name=F("resource_Boneweave_name");break;case"Brick":t.resource[e].name=F("resource_Tombstone_name");break;case"Soul_Gem":t.resource[e].name=F("resource_CandyCorn_name")}}function or(e,a){if($(`#res${e}`).length){let t=$(`#res${e}`);return t.detach(),void $("#resources").append(t)}a=a||"special";var r=$(`
          ${F(`resource_${e}_name`)}{{ count | round }}
          `);$("#resources").append(r),sc({el:`#res${e}`,data:t.prestige[e],filters:{round:e=>+e.toFixed(3)}}),"Artifact"!==e&&"Blood_Stone"!==e&&Ti(`res${e}`,(function(){let a=$("
          ");switch(e){case"Plasmid":let r=t.race.no_plasmid?Math.min(t.race.p_mutation,t.prestige.Plasmid.count):t.prestige.Plasmid.count;if(a.append($(`${F(`resource_${e}_desc`,[r,+(100*Br("plasmid")).toFixed(2)])}`)),t.genes.store&&("antimatter"!==t.race.universe||t.genes.bleed>=3)){let e=Lr(1,"plasmid");e>1&&a.append($(` ${F("resource_Plasmid_desc2",[+(100*(e-1)).toFixed(2)])}`))}break;case"AntiPlasmid":a.append($(`${F(`resource_${e}_desc`,[t.prestige.AntiPlasmid.count,+(100*Br("antiplasmid")).toFixed(2)])}`));let s=Lr(1,"anti");t.genes.store&&("antimatter"===t.race.universe||t.genes.bleed>=3)&&s>1&&a.append($(` ${F("resource_Plasmid_desc2",[+(100*(s-1)).toFixed(2)])}`));break;case"Phage":a.append($(`${F(t.prestige.AntiPlasmid.count>0?"resource_Phage_desc2":"resource_Phage_desc",[250+t.prestige.Phage.count])}`));let i=Lr(1,"phage");t.genes.store&&t.genes.store>=4&&i>1&&a.append($(` ${F("resource_Plasmid_desc2",[+(100*(i-1)).toFixed(2)])}`));break;case"Dark":switch(t.race.universe){case"standard":a.append($(`${F(`resource_${e}_desc_s`,[+(100*(nc("standard")-1)).toFixed(2)])}`));break;case"evil":a.append($(`${F(`resource_${e}_desc_e`,[+(100*(nc("evil")-1)).toFixed(2)])}`));break;case"micro":a.append($(`${F(`resource_${e}_desc_m`,[nc("micro",!1),nc("micro",!0)])}`));break;case"heavy":let t=nc("heavy"),r=.25+.5*t,s=.2+.3*t;a.append($(`${F(`resource_${e}_desc_h`,[+(100*r).toFixed(4),+(100*s).toFixed(4)])}`));break;case"antimatter":a.append($(`${F(`resource_${e}_desc_a`,[+(100*(nc("antimatter")-1)).toFixed(2)])}`));break;case"magic":a.append($(`${F(`resource_${e}_desc_mg`,[F("resource_Mana_name"),+(100*(nc("magic")-1)).toFixed(2)])}`))}break;case"Harmony":a.append($(`${F(`resource_${e}_desc`,["standard"===t.race.universe?.1:1,ec()])}`));break;case"AICore":let c=+(100*(1-.99**t.prestige.AICore.count)).toFixed(2);a.append($(`${F(`resource_${e}_desc`,[c])}`))}return a}))}function nr(e){let a=t.tech.currency>=6?-1e6:t.tech.currency>=4?-100:-25;if(t.race.banana){let r=!1;if(Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&t.resource[e].trade<0&&(r=e)})),r&&r!==e)return!1;a=t.tech.currency>=6?-1e6:t.tech.currency>=4?-25:-10}return!(t.resource[e].trade<=a)}function lr(e){let a=t.tech.currency>=6?1e6:t.tech.currency>=4?100:25;return!(t.resource[e].trade>=a)}function ur(e,a,r,s,i){if((t.settings.tabLoad||4===t.settings.civTabs&&0===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==r)){if(i&&a.append($(`

          {{ r.name | namespace }}

          `)),t.race.no_trade||(a.append($(`${F("resource_market_buy")}`)),a.append($(`\${{ r.value | buy }}`)),a.append($(`${F("resource_market_sell")}`)),a.append($(`\${{ r.value | sell }}`))),i&&(t.race.banana&&"Food"===r||t.tech.trade&&!t.race.terrifying)){let e=$(`${F("resource_market_routes")}`);a.append(e),e.append($(`-`)),e.append($('')),e.append($(`+`)),e.append($(`${F("cancel_routes")}`)),$r(r)}sc({el:e,data:{r:t.resource[r],m:t.city.market},methods:{aSell(e){let a=1===Za[e]?F("resource_market_unit"):F("resource_market_units"),r=vr(e),s=Za[e];if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),s*=1-e/100}return s=+s.toFixed(3),F("resource_market_auto_sell_desc",[s,a,r])},aBuy(e){let a=Za[e],r=N("dealmaker",0);r&&(a*=1+r/100),t.race.persuasive&&(a*=1+t.race.persuasive/100),t.race.merchant&&(a*=1+ui.merchant.vars()[1]/100);let s=Pi("goblin");if(s>0&&(a*=1+ui.merchant.vars(1)[1]/100*s),t.genes.trader&&(a*=1+lc()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1+e/50}t.race.truepath&&(a*=1-t.civic.foreign.gov3.hstl/101),a=+a.toFixed(3);let i=F(1===a?"resource_market_unit":"resource_market_units");return F("resource_market_auto_buy_desc",[a,i,yr(e)])},purchase(e){if(!t.race.no_trade&&!t.settings.pause){let a=t.city.market.qty,r=t.resource[e].value;t.race.arrogant&&(r*=1+ui.arrogant.vars()[0]/100),t.race.conniving&&(r*=1-ui.conniving.vars()[0]/100);let s=Pi("imp");s>0&&(r*=1-ui.conniving.vars(1)[0]/100*s);let i=Math.floor(Math.min(a,t.resource.Money.amount/r,t.resource[e].max-t.resource[e].amount));i>0&&(t.resource[e].amount+=i,t.resource.Money.amount-=Math.round(r*i),t.resource[e].value+=Number((i/Math.rand(1e3,1e4)).toFixed(2)))}},sell(e){if(!t.race.no_trade&&!t.settings.pause){let a=t.city.market.qty,r=4;t.race.merchant&&(r*=1-ui.merchant.vars()[0]/100);let s=Pi("goblin");s>0&&(r*=1-ui.merchant.vars(1)[0]/100*s),t.race.asymmetrical&&(r*=1+ui.asymmetrical.vars()[0]/100),t.race.conniving&&(r*=1-ui.conniving.vars()[1]/100);let i=Pi("imp");i>0&&(r*=1-ui.conniving.vars(1)[1]/100*i);let c=t.resource[e].value/r,o=Math.floor(Math.min(a,t.resource[e].amount,(t.resource.Money.max-t.resource.Money.amount)/c));o>0&&(t.resource[e].amount-=o,t.resource.Money.amount+=Math.round(c*o),t.resource[e].value-=Number((o/Math.rand(1e3,1e4)).toFixed(2)),t.resource[e].value0&&(a+=t.resource[r].trade)})),e<=a)break}if(t.resource[e].trade>=0){if(!(lr(e)&&t.city.market.trade(t.race.arrogant&&(e*=1+ui.arrogant.vars()[0]/100),k(e*t.city.market.qty,0)),sell(e){let a=4;t.race.merchant&&(a*=1-ui.merchant.vars()[0]/100);let r=Pi("goblin");return r>0&&(a*=1-ui.merchant.vars(1)[0]/100*r),t.race.asymmetrical&&(a*=1+ui.asymmetrical.vars()[0]/100),k(e*t.city.market.qty/a,0)},trade(e){if("Stone"===r&&(31===e||-31===e)){let e=kc(3,12,!1);if(e.length>0)return e}return e<0?"-"+(e=0-e):e>0?`+${e}`:0},namespace:e=>e.replace("_"," ")}})}}function dr(){return[{buy:{res:"Deuterium",vol:5},sell:{res:"Helium_3",vol:25}},{buy:{res:"Neutronium",vol:2.5},sell:{res:"Copper",vol:200}},{buy:{res:"Adamantite",vol:3},sell:{res:"Iron",vol:300}},{buy:{res:"Elerium",vol:1},sell:{res:"Oil",vol:125}},{buy:{res:"Nano_Tube",vol:10},sell:{res:"Titanium",vol:20}},{buy:{res:"Graphene",vol:25},sell:{res:t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Lumber",vol:1e3}},{buy:{res:"Stanene",vol:40},sell:{res:"Aluminium",vol:800}},{buy:{res:"Bolognium",vol:.75},sell:{res:"Uranium",vol:4}},{buy:{res:"Vitreloy",vol:1},sell:{res:"Infernite",vol:1}}]}function _r(e){let a=e||$("#galaxyTrade");if(e||rc($("#galaxyTrade")),t.galaxy.trade){a.append($(`
          ${F("galaxy_trade")}
          `));let e=dr();for(let r=0;r');a.append(s),s.append($(`${t.resource[e[r].buy.res].name}`)),s.append($(`+{{ '${r}' | t_vol }}/s`)),s.append($(`${t.resource[e[r].sell.res].name}`)),s.append($(`-{{ '${r}' | s_vol }}/s`));let i=$(`${F("resource_market_routes")}`);s.append(i);let c=F("galaxy_freighter_assign",[t.resource[e[r].buy.res].name,t.resource[e[r].sell.res].name]),o=F("galaxy_freighter_unassign",[t.resource[e[r].buy.res].name,t.resource[e[r].sell.res].name]);i.append($(`-`)),i.append($(`{{ g.f${r} }}`)),i.append($(`+`)),i.append($(`${F("cancel_routes")}`))}let r=$(`
          ${F("resource_market_galactic_trade_routes")} {{ g.cur }} / {{ g.max }}
          `);r.append($(`${F("cancel_all_routes")}`)),a.append(r)}sc({el:e?"#specialModal":"#galaxyTrade",data:{g:t.galaxy.trade,t:t.tech},methods:{less(e){let a=y();t.galaxy.trade[`f${e}`]>=a?(t.galaxy.trade[`f${e}`]-=a,t.galaxy.trade.cur-=a):(t.galaxy.trade.cur-=t.galaxy.trade[`f${e}`],t.galaxy.trade[`f${e}`]=0)},more(e){let a=y();t.galaxy.trade.curt.galaxy.trade.max-t.galaxy.trade.cur&&(a=t.galaxy.trade.max-t.galaxy.trade.cur),t.galaxy.trade[`f${e}`]+=a,t.galaxy.trade.cur+=a)},zero(e){if(e)t.galaxy.trade.cur-=t.galaxy.trade[`f${e}`],t.galaxy.trade[`f${e}`]=0;else{let e=dr();for(let a=0;ae},filters:{t_vol(e){let a=dr()[e].buy.vol;t.race.persuasive&&(a*=1+t.race.persuasive/100),t.race.merchant&&(a*=1+ui.merchant.vars()[1]/100);let r=Pi("goblin");if(r>0&&(a*=1+ui.merchant.vars(1)[1]/100*r),t.genes.trader&&(a*=1+lc()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1+e/50}return a=+a.toFixed(2),a},s_vol(e){let a=dr()[e].sell.vol;if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1-e/100}return a=+a.toFixed(2),a}}}),Ti("galacticTradeTotal",(function(){let e=$('
          ');return r.hasOwnProperty("gt_route")&&Object.keys(r.gt_route).forEach((function(t){r.gt_route[t]>0&&e.append(``)})),e.append(``),e}),{elm:"#galacticTradeTotal > span"})}function pr(e){let a=y(),r=Or();a>t.resource[e].crates&&(a=t.resource[e].crates),a>0&&(t.resource.Crates.amount+=a,t.resource.Crates.max+=a,t.resource[e].crates-=a,t.resource[e].max-=r*a)}function hr(e){let a=y(),r=Or();a>t.resource.Crates.amount&&(a=t.resource.Crates.amount),a>0&&(t.resource.Crates.amount-=a,t.resource.Crates.max-=a,t.resource[e].crates+=a,t.resource[e].max+=r*a)}function mr(e){let a=y(),r=Cr();a>t.resource[e].containers&&(a=t.resource[e].containers),a>0&&(t.resource.Containers.amount+=a,t.resource.Containers.max+=a,t.resource[e].containers-=a,t.resource[e].max-=r*a)}function gr(e){let a=y(),r=Cr();a>t.resource.Containers.amount&&(a=t.resource.Containers.amount),a>0&&(t.resource.Containers.amount-=a,t.resource.Containers.max-=a,t.resource[e].containers+=a,t.resource[e].max+=r*a)}function fr(e,a,r,s){if(t.settings.tabLoad||4===t.settings.civTabs&&1===t.settings.marketTabs){if(a.append($(`

          {{ name }}

          `)),t.resource.Crates.display){let e=$(`${F("resource_Crates_name")}`);a.append(e),e.append($(`«`)),e.append($(``)),e.append($(`»`))}if(t.resource.Containers.display){let e=$(`${F("resource_Containers_name")}`);a.append(e),e.append($(`«`)),e.append($('')),e.append($(`»`))}sc({el:e,data:t.resource[r],methods:{addCrate(e){hr(e)},subCrate(e){pr(e)},addCon(e){gr(e)},subCon(e){mr(e)}},filters:{trick(e){if("Stone"===r&&10===t.resource[r].crates&&31===t.resource[r].containers){let e=kc(4,13,!0);if(e.length>0)return e}return e},cCnt(e,a){if("Food"===a&&!t.race.artifical||t.race.artifical&&"Coal"===a){let t=$c(13,10);if(10===e&&t.length>0)return"1"+t}return e}}})}}function vr(e){let a=4;t.race.merchant&&(a*=1-ui.merchant.vars()[0]/100);let r=Pi("goblin");r>0&&(a*=1-ui.merchant.vars(1)[0]/100*r),t.race.asymmetrical&&(a*=1+ui.asymmetrical.vars()[0]/100),t.race.conniving&&a--;let s=t.resource[e].value*Za[e]/a;if(t.city.wharf&&(s*=1+.01*t.city.wharf.count),t.space.gps&&t.space.gps.count>3&&(s*=1+.01*t.space.gps.count),t.tech.railway){let e=t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?.03:.02;s*=1+t.tech.railway*e}return t.race.truepath&&!t.race.lone_survivor&&(s*=1-t.civic.foreign.gov3.hstl/101),t.race.inflation&&(s*=1+t.race.inflation/500),t.race.witch_hunter&&t.resource.Sus.amount>50&&(s*=1-(t.resource.Sus.amount-50)/52),s*=Pe("psychic_cash"),s=+s.toFixed(1),s}function yr(e){let a=t.resource[e].value;t.race.arrogant&&(a*=1+ui.arrogant.vars()[0]/100),t.race.conniving&&(a*=1-ui.conniving.vars()[0]/100);let r=Pi("imp");r>0&&(a*=1-ui.conniving.vars(1)[0]/100*r);let s=a*Za[e];return t.city.wharf&&(s*=.99**t.city.wharf.count),t.space.gps&&t.space.gps.count>3&&(s*=.99**t.space.gps.count),t.tech.railway&&(s*=(t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?.97:.98)**t.tech.railway),t.race.truepath&&!t.race.lone_survivor&&(s*=1+t.civic.foreign.gov3.hstl/101),t.race.inflation&&(s*=1+t.race.inflation/300),t.race.quarantine&&(s*=1+Math.round(t.race.quarantine**3.5)),t.race.witch_hunter&&t.resource.Sus.amount>50&&(s*=1+(t.resource.Sus.amount-50)/8),s=+s.toFixed(1),s}function br(e,a,s,i){Ti(`${e}`,(function(){let e=$('
          {{ res.name | namespace }}
          '),c=$('
          ');e.append(c);let o=Xa(a,s),n=$("
          ");c.append(n),"auto"===s&&r.p[a]&&Object.keys(r.p[a]).forEach((function(e){let t=r.p[a][e],s=parseFloat(t.slice(0,-1));if(0!=s&&!isNaN(s)){let t=s>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),n.append(``)}})),Object.keys(o.multi_bd).forEach((function(e){let t=o.multi_bd[e],a=parseFloat(t.slice(0,-1));if(0!=a&&!isNaN(a)){let t=a>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),n.append(``)}}));let l=$('
          '),u=$(`
          ${F("craft_tools_multi")}
          `);l.append(u);let d=0;if(Object.keys(o.add_bd).forEach((function(e){let t=o.add_bd[e],a=parseFloat(t.slice(0,-1));if(0!=a&&!isNaN(a)){d++;let t=a>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),l.append(``)}})),d>0&&c.append(l),r.p.consume&&r.p.consume[a]){let e=$('
          '),t=0;Object.keys(r.p.consume[a]).forEach((function(s){let i=r.p.consume[a][s];if(0!=i&&!isNaN(i)){t++;let r=i>0?"success":"danger",c=s.replace(/\+.+$/,"");s=s.replace(/'/g,"\\'"),e.append(``)}})),t>0&&c.append(e)}return t.resource[a].diff<0&&t.resource[a].amount>0&&e.append(``),i&&(e.append(''),e.append(i)),e}),{in:function(){sc({el:"#popper > div",data:{[a]:r.p[a],res:t.resource[a],consume:r.p.consume,craft:Xa(a,s)},filters:{translate(e){let t=e[e.length-1],a=parseFloat(e.slice(0,-1)),r=a>0&&a<1||a<0&&a>-1?4:a>0&&a<10||a<0&&a>-10?3:2;a=+a.toFixed(r);let s="%"===t?"%":"";return a>0?"+"+k(a,r)+s:a<0?k(a,r)+s:void 0},fix:e=>e+"v",counter(e){let r=+(e/-t.resource[a].diff).toFixed(0);if(r>60){let e=r%60,t=(r-e)/60;if(t>=60){let e=t%60;return`${(t-e)/60}h ${e}m`}return`${t}m ${e}s`}return`${r}s`},namespace:e=>e.replace("_"," ")}})},out:function(){sc({el:"#popper > div"},"destroy")},classes:"breakdown has-background-light has-text-dark",prop:{modifiers:{preventOverflow:{enabled:!1},hide:{enabled:!1}}}})}function wr(e,a,s){Ti(`${e}`,(function(){let e=$('
          {{ res.name | namespace }}
          '),i=$('
          ');e.append(i);let c=!1;if(r[s][a]){let e=$("
          ");i.append(e);let t=[a];t.push("Global");for(var o=0;o0?"success":"danger",s=t.replace(/\+.+$/,"");t=t.replace(/'/g,"\\'"),e.append(``)}}))}}if(r[s].consume&&r[s].consume[a]){let e=$(`
          `),t=0;Object.keys(r[s].consume[a]).forEach((function(i){let c=r[s].consume[a][i];if(0!=c&&!isNaN(c)){t++;let r=c>0?"success":"danger",s=i.replace(/\+.+$/,"");i=i.replace(/'/g,"\\'"),e.append(``)}})),t>0&&i.append(e)}if("p"===s){let r=t.resource[a].diff>0?"success":"danger";e.append(``)}return e}),{in:function(){sc({el:"#popper > div",data:{Global:r[s].Global,[a]:r[s][a],consume:r[s].consume,res:t.resource[a]},filters:{translate(e){let t=e[e.length-1],a=parseFloat(e.slice(0,-1)),r=a>0&&a<1||a<0&&a>-1?4:a>0&&a<10||a<0&&a>-10?3:2,s="%"===t?"%":"";return a>0?"+"+k(a,r)+s:a<0?k(a,r)+s:void 0},fix:e=>e+"v",counter(e){let r=t.resource[a].diff,s=0;if(r<0?(r*=-1,s=+(e/r).toFixed(0)):s=+((t.resource[a].max-e)/r).toFixed(0),s===1/0||Number.isNaN(s))return"Never";if(s>60){let e=s%60,t=(s-e)/60;if(t>=60){let e=t%60;return`${(t-e)/60}h ${e}m`}return`${t}m ${e}s`}return`${s}s`},direction:e=>F(e>=0?"to_full":"to_empty"),namespace:e=>e.replace("_"," ")}})},out:function(){sc({el:"#popper > div"},"destroy")},classes:"breakdown has-background-light has-text-dark",prop:{modifiers:{preventOverflow:{enabled:!1},hide:{enabled:!1}}}})}function $r(e){$(`#market-${e} .trade .current`).removeClass("has-text-warning"),$(`#market-${e} .trade .current`).removeClass("has-text-danger"),$(`#market-${e} .trade .current`).removeClass("has-text-success"),t.resource[e].trade>0?$(`#market-${e} .trade .current`).addClass("has-text-success"):t.resource[e].trade<0?$(`#market-${e} .trade .current`).addClass("has-text-danger"):$(`#market-${e} .trade .current`).addClass("has-text-warning")}function xr(){let e=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?t.resource.Chrysotile.name:t.resource.Stone.name:t.resource.Plywood?t.resource.Plywood.name:F("resource_Plywood_name");return F("resource_modal_crate_construct_desc",[t.race.kindling_kindred||t.race.smoldering?200:10,e,Or()])}function kr(){return F("resource_modal_container_construct_desc",[125,Cr()])}function qr(e,t){switch(e){case"crate":Mr(t);break;case"container":Pr(t)}}function Mr(e){let a=e||y(),r=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood",s=t.race.kindling_kindred||t.race.smoldering?200:10;a+t.resource.Crates.amount>t.resource.Crates.max&&(a=t.resource.Crates.max-t.resource.Crates.amount),t.resource[r].amount=s*a&&t.resource.Crates.amountt.resource.Containers.max&&(a=t.resource.Containers.max-t.resource.Containers.amount),t.resource.Steel.amount<125*a&&(a=Math.floor(t.resource.Steel.amount/125)),t.resource.Steel.amount>=125*a&&t.resource.Containers.amount=2?500:350;t.tech.container&&t.tech.container>=4&&(e+=t.tech.container>=5?500:250),t.tech.container&&t.tech.container>=6&&(e+=t.tech.container>=7?1200:500),t.tech.container&&t.tech.container>=8&&(e+=4e3),t.race.pack_rat&&(e*=1+ui.pack_rat.vars()[0]/100);let a=Pi("kobold");return a>0&&(e*=1+ui.pack_rat.vars(1)[0]/100*a),t.stats.achieve.banana&&t.stats.achieve.banana.l>=3&&(e*=1.1),e*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,Math.round(Lr(e))}function Cr(){let e=t.tech.steel_container&&t.tech.steel_container>=3?1200:800;t.tech.steel_container&&t.tech.steel_container>=4&&(e+=t.tech.steel_container>=5?1e3:400),t.tech.steel_container&&t.tech.steel_container>=6&&(e+=t.tech.steel_container>=7?7500:1e3),t.tech.steel_container&&t.tech.steel_container>=8&&(e+=8e3),t.race.pack_rat&&(e*=1+ui.pack_rat.vars()[0]/100);let a=Pi("kobold");return a>0&&(e*=1+ui.pack_rat.vars(1)[0]/100*a),e*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,Math.round(Lr(e))}function jr(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=$(`

          ${F("resource_market")}

          `);rc($("#market")),$("#market").append(e),function(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=$("#market-qty");rc(e),t.race.no_trade||(e.append($(`

          ${F("resource_trade_qty")}

          `)),e.append($('-+'))),sc({el:"#market-qty",data:t.city.market,methods:{val(){t.city.market.qty<1?t.city.market.qty=1:t.city.market.qty>Fr()&&(t.city.market.qty=Fr())},limit:()=>Fr(),less(){t.city.market.qty-=y()},more(){t.city.market.qty+=y()}}})}()}function Sr(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||1!==t.settings.marketTabs))return;let e=$(`

          ${F("tab_storage")}

          `);rc($("#resStorage")),$("#resStorage").append(e),t.resource.Crates&&t.resource.Containers&&(e.append($(``)),e.append($(``)),sc({el:"#createHead",data:{cr:t.resource.Crates,cn:t.resource.Containers},methods:{crate(){Mr()},container(){Pr()},buildCrateDesc:()=>xr(),buildContainerDesc:()=>kr()}}))}function Fr(){return t.tech.currency>=6?1e6:t.tech.currency>=4?5e3:100}function zr(){if((t.settings.tabLoad||4===t.settings.civTabs&&2===t.settings.marketTabs)&&(rc($("#resEjector")),t.interstellar.mass_ejector)){let e=$(`

          ${F("interstellar_mass_ejector_vol")}

          `);$("#resEjector").append(e);let a=$('');e.append(a),a.append($(`{{ total }} / {{ on | max }}{{ on | real }}${F("interstellar_mass_ejector_mass")}: {{ mass | approx }} kt/s`)),sc({el:"#eject",data:t.interstellar.mass_ejector,filters:{max:e=>1e3*e,real:e=>i.mass_ejectork(e,2)}})}}function Ar(e,a){if((t.settings.tabLoad||4===t.settings.civTabs&&2===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==e)&&Va[e]&&t.interstellar.mass_ejector){"magic"===t.race.universe||"Elerium"!==e&&"Infernite"!==e||(a="caution");let r=$(`

          ${t.resource[e].name}

          `);$("#resEjector").append(r);let s=$('');r.append(s),s.append($(`«`)),s.append($(`{{ e.${e} }}`)),s.append($(`»`)),s.append($(`${F("interstellar_mass_ejector_per")}: ${Va[e]} kt`)),t.interstellar.mass_ejector.hasOwnProperty(e)||(t.interstellar.mass_ejector[e]=0),sc({el:`#eject${e}`,data:{r:t.resource[e],e:t.interstellar.mass_ejector},methods:{ejectMore(e){let a=y();a+t.interstellar.mass_ejector.total>1e3*i.mass_ejector&&(a=1e3*i.mass_ejector-t.interstellar.mass_ejector.total),t.interstellar.mass_ejector[e]+=a,t.interstellar.mass_ejector.total+=a},ejectLess(e){let a=y();a>t.interstellar.mass_ejector[e]&&(a=t.interstellar.mass_ejector[e]),t.interstellar.mass_ejector[e]>0&&(t.interstellar.mass_ejector[e]-=a,t.interstellar.mass_ejector.total-=a)}}})}}function Tr(){if((t.settings.tabLoad||4===t.settings.civTabs&&3===t.settings.marketTabs)&&(rc($("#resCargo")),t.portal.transport)){let e=$(`

          ${F("portal_transport_supply")}

          `);$("#resCargo").append(e);let a=$('{{ used }} / {{ max }}');e.append(a),sc({el:"#spireSupply",data:t.portal.transport.cargo})}}function Er(e,a){if((t.settings.tabLoad||4===t.settings.civTabs&&3===t.settings.marketTabs)&&Ja[e]&&t.portal.transport){let r=$(`

          ${t.resource[e].name}

          `);$("#resCargo").append(r);let s=$('');r.append(s),s.append($(`«`)),s.append($(`{{ e.${e} }}`)),s.append($(`»`));let i=k(Ja[e].out);s.append($(`${F("portal_transport_item",[`${i}`,`${Ja[e].in}`])}`)),t.portal.transport.cargo.hasOwnProperty(e)||(t.portal.transport.cargo[e]=0),sc({el:`#supply${e}`,data:{r:t.resource[e],e:t.portal.transport.cargo},methods:{supplyMore(e){let a=y();a+t.portal.transport.cargo.used>t.portal.transport.cargo.max&&(a=t.portal.transport.cargo.max-t.portal.transport.cargo.used,t.portal.transport.cargo[e]+a<0&&(a=-t.portal.transport.cargo[e])),t.portal.transport.cargo[e]+=a,t.portal.transport.cargo.used+=a},supplyLess(e){let a=y();a>t.portal.transport.cargo[e]&&(a=t.portal.transport.cargo[e]),t.portal.transport.cargo[e]>0&&(t.portal.transport.cargo[e]-=a,t.portal.transport.cargo.used-=a)}}})}}function Ir(){(t.settings.tabLoad||4===t.settings.civTabs&&4===t.settings.marketTabs)&&rc($("#resAlchemy"))}function Kr(e,a,r){if((t.settings.tabLoad||4===t.settings.civTabs&&4===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==e)&&t.tech.alchemy&&(r||t.tech.alchemy>=2)&&"Crystal"!==e){let s=$(`

          ${t.resource[e].name}

          `);$("#resAlchemy").append(s);let i=$('');s.append(i),i.append($(`«`)),i.append($(`{{ a.${e} }}`)),i.append($(`»`)),t.race.alchemy.hasOwnProperty(e)||(t.race.alchemy[e]=0),sc({el:`#alchemy${e}`,data:{r:t.resource[e],a:t.race.alchemy},methods:{addSpell(e){let a=y();for(let r=0;r=1;r++)t.race.alchemy[e]++,t.resource.Mana.diff--},subSpell(e){let a=y();for(let r=0;r0;r++)t.race.alchemy[e]--,t.resource.Mana.diff++}}}),Ti(`alchemy${e}`,(function(){let a=r&&t.tech.alchemy>=2?8*Za[e]:2*Za[e];return t.race.witch_hunter&&(a*=3),t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg&&(a*=t.stats.achieve.soul_sponge.mg+1),$(`
          ${F("resource_alchemy",[1,F("resource_Mana_name"),.15,F("resource_Crystal_name"),+a.toFixed(2),t.resource[e].name])}
          `)}),{elm:`#alchemy${e} h3`})}}const Lr=(Nr={},function(e,a,r){let s=a||"a",i=[t.race.universe,t.prestige.Plasmid.count,t.prestige.AntiPlasmid.count,t.prestige.Phage.count,t.race.no_plasmid||"0",t.race.p_mutation||"0",t.race.nerfed||"0",t.genes.store||"0",t.genes.bleed||"0",t.city.temple?t.city.temple.count:"0",t.space.ziggurat?t.space.ziggurat.count:"0",t.race.cataclysm?t.race.cataclysm:"0",t.race.orbit_decayed?t.race.orbit_decayed:"0",t.genes.ancients||"0",t.civic.priest?t.civic.priest.workers:"0"].join("-");if(Nr[s]||(Nr[s]={}),!Nr[s][i]||r){let e=1,r=!(!t.race.cataclysm&&!t.race.orbit_decayed);if(t.genes.store){let r=0;if(!a||a&&("plasmid"===a&&"antimatter"!==t.race.universe||"anti"===a&&"antimatter"===t.race.universe)){r="antimatter"===t.race.universe?t.prestige.AntiPlasmid.count:t.prestige.Plasmid.count;let e=r;t.race.no_plasmid?e=Math.min(t.race.p_mutation,r):t.race.nerfed&&(e=Math.floor(r/("antimatter"===t.race.universe?2:5))),r=Math.round(e*(t.race.nerfed?.5:1))}(!a||a&&"phage"===a)&&t.genes.store>=4&&(r+=Math.round(t.prestige.Phage.count*(t.race.nerfed?1/3:1)));let s=t.genes.store>=2?t.genes.store>=3?1250:1666:2500;if("antimatter"===t.race.universe&&(s*=2),t.genes.bleed&&t.genes.bleed>=3&&(!a||a&&("plasmid"===a&&"antimatter"===t.race.universe||"anti"===a&&"antimatter"!==t.race.universe))){let e="antimatter"===t.race.universe?t.prestige.Plasmid.count/5:t.prestige.AntiPlasmid.count/10;r+=Math.round(e*(t.race.nerfed?.5:1))}e*=1+r/s}if("standard"===t.race.universe&&(e*=nc("standard")),"antimatter"===t.race.universe&&(!r&&t.city.temple&&t.city.temple.count||r&&t.space.ziggurat&&t.space.ziggurat.count)){let a=.06;if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.0012:t.genes.ancients>=3?.001:8e-4;t.race.high_pop&&(e=Me(e)),a+=e*t.civic.priest.workers}e*=1+(r?t.space.ziggurat.count:t.city.temple.count)*a}!a&&t.pillars&&(e*=_c()[1]),Nr[s]={},Nr[s][i]=e}return a?Nr[s][i]*e:Math.round(Nr[s][i]*e)});var Nr;function Dr(){if(t.race.no_plasmid||"antimatter"===t.race.universe){let e=!(!t.race.cataclysm&&!t.race.orbit_decayed);if(e&&t.space.ziggurat&&t.space.ziggurat.count||t.city.temple&&t.city.temple.count){let a=t.tech.anthropology&&t.tech.anthropology>=1?.016:.01;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=t.civic.professor.workers*("antimatter"===t.race.universe?2e-4:4e-4);t.race.high_pop&&(e=Me(e)),a+=e}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?15e-5:t.genes.ancients>=3?125e-6:1e-4;t.race.high_pop&&(e=Me(e)),a+=e*t.civic.priest.workers}"antimatter"===t.race.universe?a/=t.race.nerfed?3:2:t.race.nerfed&&(a/=2),t.race.spiritual&&(a*=1+ui.spiritual.vars()[0]/100);let r=Pi("seraph");return r>0&&(a*=1+ui.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1.12),t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),(e?t.space.ziggurat.count:t.city.temple.count)*a}}return 0}const Br=(Gr={},function(e){let a=[t.race.universe,t.prestige.Plasmid.count,t.prestige.AntiPlasmid.count,t.prestige.Phage.count,t.civic.govern.type,t.civic.professor.assigned,t.genes.bleed||"0",t.race.decayed||"0",t.race.gene_fortify||"0",t.tech.anthropology||"0",t.tech.fanaticism||"0",t.race.nerfed||"0",t.race.no_plasmid||"0",t.genes.ancients||"0",t.city.temple?t.city.temple.count:"0",t.space.ziggurat?t.space.ziggurat.count:"0",t.civic.priest?t.civic.priest.workers:"0",t.race.orbit_decayed?t.race.orbit_decayed:"0",t.race.spiritual||"0",t.tech.outpost_boost||"0",i.alien_outpost||"0"].join("-");if(!Gr[a]){let e=0,r=0;if("antimatter"!==t.race.universe||t.genes.bleed){let a=t.race.no_plasmid?Math.min(t.race.p_mutation,t.prestige.Plasmid.count):t.prestige.Plasmid.count;"antimatter"===t.race.universe&&t.genes.bleed&&(a*=.025),t.race.decayed&&(a-=Math.round((t.stats.days-t.race.decayed)/(300+6*t.race.gene_fortify)));let r=250+t.prestige.Phage.count;e=a>r?+(Math.log(r+50)-3.91202).toFixed(5)/2.888+Math.log(a+1-r)/Math.LN2/250:a<0?0:+(Math.log(a+50)-3.91202).toFixed(5)/2.888,t.tech.outpost_boost&&t.race.truepath&&i.alien_outpost&&(e*=2);let s=0;if(t.race.orbit_decayed&&t.space.ziggurat?s=t.space.ziggurat.count:t.city.temple&&(s=t.city.temple.count),s>0&&!t.race.no_plasmid&&"antimatter"!==t.race.universe){let a=t.tech.anthropology&&t.tech.anthropology>=1?.08:.05;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=.002*t.civic.professor.workers;t.race.high_pop&&(e=Me(e)),a+=e}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.0015:t.genes.ancients>=3?.00125:.001;t.race.high_pop&&(e=Me(e)),a+=e*t.civic.priest.workers}t.race.spiritual&&(a*=1+ui.spiritual.vars()[0]/100);let r=Pi("seraph");r>0&&(a*=1+ui.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1.12),t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),t.race.orbit_decayed&&t.race.truepath&&(a*=.1),e*=1+s*a}}if("antimatter"===t.race.universe||t.genes.bleed&&t.genes.bleed>=2){let e=t.prestige.AntiPlasmid.count;"antimatter"!==t.race.universe&&t.genes.bleed&&t.genes.bleed>=2&&(e*=.25),t.race.decayed&&(e-=Math.round((t.stats.days-t.race.decayed)/(300+6*t.race.gene_fortify)));let a=250+t.prestige.Phage.count;r=e>a?+(Math.log(a+50)-3.91202).toFixed(5)/2.888+Math.log(e+1-a)/Math.LN2/250:e<0?0:+(Math.log(e+50)-3.91202).toFixed(5)/2.888,t.tech.outpost_boost&&t.race.truepath&&i.alien_outpost&&(r*=2),r/=3}t.race.nerfed&&("antimatter"===t.race.universe?(e/=2,r/=2):(e/=5,r/=5)),(Gr={})[a]=[(1+e)*(1+r)-1,e,r]}return e&&"raw"===e?Gr[a]:e&&"plasmid"===e?Gr[a][1]:e&&"antiplasmid"===e?Gr[a][2]:Gr[a][0]});var Gr;const Rr={club:{id:"tech-club",title:F("tech_club"),desc:F("tech_club_desc"),category:"agriculture",era:"primitive",reqs:{},grant:["primitive",1],cost:{Lumber:()=>t.race.kindling_kindred||t.race.smoldering?0:5,Stone:()=>t.race.kindling_kindred||t.race.smoldering?5:0},action(){return!!Os($(this)[0])&&(t.resource.Food.display=!0,!0)}},bone_tools:{id:"tech-bone_tools",title:F("tech_bone_tools"),desc:F("tech_bone_tools_desc"),category:"stone_gathering",era:"primitive",reqs:{primitive:1},grant:["primitive",2],condition:()=>!(t.race.soul_eater&&!t.race.evil),cost:{Food:()=>t.race.evil&&!t.race.smoldering?0:10,Lumber:()=>t.race.evil&&!t.race.smoldering?10:0},action(){return!!Os($(this)[0])&&(t.resource.Stone.display=!0,t.race.smoldering&&(t.resource.Chrysotile.display=!0),!0)}},wooden_tools:{id:"tech-wooden_tools",title:()=>t.race.kindling_kindred?F("tech_bone_tools"):F("tech_wooden_tools"),desc:()=>t.race.kindling_kindred?F("tech_bone_tools_desc"):F("tech_wooden_tools_desc"),category:"stone_gathering",era:"primitive",reqs:{primitive:1},grant:["primitive",2],condition:()=>!(!t.race.soul_eater||t.race.evil),cost:{Lumber:()=>10},action(){return!!Os($(this)[0])&&(t.resource.Stone.display=!0,t.race.smoldering&&(t.resource.Chrysotile.display=!0),!0)}},sundial:{id:"tech-sundial",title:()=>t.race.unfathomable?F("tech_moondial"):F("tech_sundial"),desc:()=>t.race.unfathomable?F("tech_moondial_desc"):F("tech_sundial_desc"),category:"science",era:"primitive",reqs:{primitive:2},grant:["primitive",3],cost:{Lumber:()=>8,Stone:()=>10},effect:()=>t.race.unfathomable?F("tech_moondial_effect"):F("tech_sundial_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_sundial_msg"),"info",!1,["progress"]),t.resource.Knowledge.display=!0,t.city.calendar.day++,t.race.infectious&&(t.civic.garrison.display=!0,t.settings.showCivic=!0,t.city.garrison={count:0,on:0}),t.race.banana&&!t.race.terrifying&&(t.settings.showResources=!0,t.settings.showMarket=!0,t.resource.Money.display=!0,t.city.market.active=!0,t.tech.currency=2),t.race.calm&&(t.resource.Zen.display=!0,t.city.meditation={count:0}),!0)}},housing:{id:"tech-housing",title:F("tech_housing"),desc:F("tech_housing_desc"),category:"housing",era:"civilized",reqs:{primitive:3},grant:["housing",1],cost:{Knowledge:()=>10},effect:F("tech_housing_effect"),action(){return!!Os($(this)[0])&&(t.city.basic_housing={count:0},!0)}},cottage:{id:"tech-cottage",title:()=>Is("medium"),desc:F("tech_cottage_desc"),category:"housing",era:"civilized",reqs:{housing:1,cement:1,mining:3},grant:["housing",2],cost:{Knowledge:()=>3600},effect:F("tech_cottage_effect"),action(){return!!Os($(this)[0])&&(t.city.cottage={count:0},!0)}},apartment:{id:"tech-apartment",title:()=>Is("large"),desc:()=>Is("large"),category:"housing",era:"discovery",reqs:{housing:2,high_tech:2},grant:["housing",3],cost:{Knowledge:()=>15750},effect:F("tech_apartment_effect"),action(){return!!Os($(this)[0])&&(t.city.apartment={count:0,on:0},!0)}},arcology:{id:"tech-arcology",title:F("tech_arcology"),desc:F("tech_arcology"),category:"housing",era:"dimensional",reqs:{hell_ruins:4,housing:3,high_tech:17},grant:["housing",4],cost:{Knowledge:()=>25e6},effect:()=>F("tech_arcology_effect"),action(){return!!Os($(this)[0])&&(t.portal.arcology={count:0,on:0},!0)}},steel_beams:{id:"tech-steel_beams",title:F("tech_steel_beams"),desc:F("tech_housing_cost"),category:"housing",era:"discovery",reqs:{housing:2,smelting:2},not_trait:["cataclysm","lone_survivor"],grant:["housing_reduction",1],cost:{Knowledge:()=>11250,Steel:()=>2500},effect:()=>F("tech_steel_beams_effect",[Is("small"),Is("medium")]),action(){return!!Os($(this)[0])}},mythril_beams:{id:"tech-mythril_beams",title:F("tech_mythril_beams"),desc:F("tech_housing_cost"),category:"housing",era:"early_space",reqs:{housing_reduction:1,space:3},grant:["housing_reduction",2],cost:{Knowledge:()=>175e3,Mythril:()=>1e3},effect:()=>F("tech_mythril_beams_effect",[Is("small"),Is("medium")]),action(){return!!Os($(this)[0])}},neutronium_walls:{id:"tech-neutronium_walls",title:F("tech_neutronium_walls"),desc:F("tech_housing_cost"),category:"housing",era:"deep_space",reqs:{housing_reduction:2,gas_moon:1},grant:["housing_reduction",3],cost:{Knowledge:()=>3e5,Neutronium:()=>850},effect:()=>F("tech_neutronium_walls_effect",[Is("small"),Is("medium")]),action(){return!!Os($(this)[0])}},bolognium_alloy_beams:{id:"tech-bolognium_alloy_beams",title:F("tech_bolognium_alloy_beams"),desc:F("tech_housing_cost"),category:"housing",era:"intergalactic",reqs:{housing_reduction:3,gateway:3},grant:["housing_reduction",4],cost:{Knowledge:()=>375e4,Adamantite:()=>25e5,Bolognium:()=>1e5},effect:()=>F("tech_bolognium_alloy_beams_effect",[Is("small"),Is("medium")]),action(){return!!Os($(this)[0])}},aphrodisiac:{id:"tech-aphrodisiac",title:F("tech_aphrodisiac"),desc:F("tech_aphrodisiac_desc"),category:"housing",era:"civilized",reqs:{housing:2},grant:["reproduction",1],not_trait:["artifical"],cost:{Knowledge:()=>4500},effect:F("tech_aphrodisiac_effect"),action(){return!!Os($(this)[0])}},fertility_clinic:{id:"tech-fertility_clinic",title:F("tech_fertility_clinic"),desc:F("tech_fertility_clinic"),category:"housing",era:"intergalactic",reqs:{reproduction:1,xeno:6},not_trait:["cataclysm"],grant:["reproduction",2],cost:{Knowledge:()=>45e5},effect:F("tech_fertility_clinic_effect"),action(){return!!Os($(this)[0])}},captive_housing:{id:"tech-captive_housing",title:F("tech_captive_housing"),desc:F("tech_captive_housing"),category:"eldritch",era:"civilized",reqs:{housing:1},trait:["unfathomable"],grant:["unfathomable",1],cost:{Knowledge:()=>12},effect:F("tech_captive_housing_effect"),action(){return!!Os($(this)[0])&&(t.city.captive_housing={count:0,cattle:0,cattleCatch:0,race0:0,jailrace0:0,race1:0,jailrace1:0,race2:0,jailrace2:0,raceCap:0,cattleCap:0},!0)}},torture:{id:"tech-torture",title:F("tech_torture"),desc:F("tech_torture"),category:"eldritch",era:"civilized",reqs:{unfathomable:1},trait:["unfathomable"],grant:["unfathomable",2],cost:{Knowledge:()=>25},effect:F("tech_torture_effect"),action(){return!!Os($(this)[0])&&(t.civic.torturer.display=!0,!0)}},thrall_quarters:{id:"tech-thrall_quarters",title:F("tech_thrall_quarters"),desc:F("tech_thrall_quarters"),category:"eldritch",era:"civilized",reqs:{unfathomable:2,high_tech:6},trait:["unfathomable"],grant:["unfathomable",3],cost:{Knowledge:()=>95e3,Cement:()=>5e4,Wrought_Iron:()=>12500},effect:F("tech_thrall_quarters_effect"),action(){return!!Os($(this)[0])&&(t.civic.torturer.display=!0,!0)}},psychic_energy:{id:"tech-psychic_energy",title:F("tech_psychic_energy"),desc:F("tech_psychic_energy"),category:"eldritch",era:"civilized",reqs:{housing:1},condition:()=>t.settings.showCivic,trait:["psychic"],grant:["psychic",1],cost:{Knowledge:()=>15},effect:F("tech_psychic_energy_effect"),action(){return!!Os($(this)[0])&&(t.resource.Energy.display=!0,t.settings.showPsychic=!0,t.race.psychicPowers={boost:{r:"Food"},boostTime:0},!0)},post(){zi()}},psychic_attack:{id:"tech-psychic_attack",title:F("tech_psychic_attack"),desc:F("tech_psychic_attack"),category:"eldritch",era:"civilized",reqs:{psychic:1,military:1},condition:()=>t.stats.psykill>=10,trait:["psychic"],grant:["psychic",2],cost:{Knowledge:()=>100},effect:F("tech_psychic_attack_effect"),action(){return!!Os($(this)[0])&&(t.race.psychicPowers.assaultTime=0,!0)},post(){zi()}},psychic_finance:{id:"tech-psychic_finance",title:F("tech_psychic_finance"),desc:F("tech_psychic_finance"),category:"eldritch",era:"civilized",reqs:{psychic:2,high_tech:4},trait:["psychic"],grant:["psychic",3],cost:{Knowledge:()=>65e3},effect:F("tech_psychic_finance_effect"),action(){return!!Os($(this)[0])&&(t.race.psychicPowers.cash=0,!0)},post(){zi()}},psychic_channeling:{id:"tech-psychic_channeling",title:F("tech_psychic_channeling"),desc:F("tech_psychic_channeling"),category:"eldritch",era:"deep_space",reqs:{psychic:3,high_tech:10},trait:["psychic"],grant:["psychic",4],cost:{Knowledge:()=>36e4},effect:F("tech_psychic_channeling_effect"),action(){return!!Os($(this)[0])&&(t.race.psychicPowers.channel={cash:0,assault:0,boost:0},!0)},post(){zi()}},psychic_efficiency:{id:"tech-psychic_efficiency",title:F("tech_psychic_efficiency"),desc:F("tech_psychic_efficiency"),category:"eldritch",era:"intergalactic",reqs:{psychic:4,high_tech:16},trait:["psychic"],grant:["psychic",5],cost:{Knowledge:()=>525e4},effect:F("tech_psychic_efficiency_effect"),action(){return!!Os($(this)[0])},post(){zi()}},mind_break:{id:"tech-mind_break",title:F("tech_mind_break"),desc:F("tech_mind_break"),category:"eldritch",era:"civilized",reqs:{psychic:2,high_tech:1,unfathomable:2},trait:["psychic"],grant:["psychicthrall",1],cost:{Knowledge:()=>7e3},effect:F("tech_mind_break_effect"),action(){return!!Os($(this)[0])},post(){zi()}},psychic_stun:{id:"tech-psychic_stun",title:F("tech_psychic_stun"),desc:F("tech_psychic_stun"),category:"eldritch",era:"civilized",reqs:{psychicthrall:1,high_tech:3,unfathomable:2},trait:["psychic"],grant:["psychicthrall",2],cost:{Knowledge:()=>32e3},effect:F("tech_psychic_stun_effect"),action(){return!!Os($(this)[0])},post(){zi()}},spear:{id:"tech-spear",title:F("tech_spear"),desc:F("tech_spear_desc"),category:"foraging",era:"civilized",reqs:{primitive:3,storage:1},trait:["forager"],grant:["foraging",1],cost:{Knowledge:()=>110,Stone:()=>75},effect:F("tech_spear_effect"),action(){return!!Os($(this)[0])}},bronze_spear:{id:"tech-bronze_spear",title:F("tech_bronze_spear"),desc:F("tech_bronze_spear_desc"),category:"foraging",era:"civilized",reqs:{foraging:1,mining:2},trait:["forager"],grant:["foraging",2],cost:{Knowledge:()=>525,Copper:()=>50},effect:F("tech_bronze_spear_effect"),action(){return!!Os($(this)[0])}},iron_spear:{id:"tech-iron_spear",title:F("tech_iron_spear"),desc:F("tech_iron_spear_desc"),category:"foraging",era:"civilized",reqs:{foraging:2,mining:3},trait:["forager"],grant:["foraging",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1650:3300,Iron:()=>375},effect:F("tech_bronze_spear_effect"),action(){return!!Os($(this)[0])}},dowsing_rod:{id:"tech-dowsing_rod",title:F("tech_dowsing_rod"),desc:F("tech_dowsing_rod_desc"),category:"foraging",era:"civilized",reqs:{foraging:1,mining:2},trait:["forager"],grant:["dowsing",1],cost:{Knowledge:()=>450,Lumber:()=>750},effect:F("tech_dowsing_rod_effect"),action(){return!!Os($(this)[0])}},metal_detector:{id:"tech-metal_detector",title:F("tech_metal_detector"),desc:F("tech_metal_detector_desc"),category:"foraging",era:"civilized",reqs:{dowsing:1,high_tech:4},trait:["forager"],grant:["dowsing",2],cost:{Knowledge:()=>65e3},effect:F("tech_metal_detector_effect"),action(){return!!Os($(this)[0])}},smokehouse:{id:"tech-smokehouse",title:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("city_smokehouse_easter"):F("tech_smokehouse"),desc:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("tech_smokehouse_easter_desc"):F("tech_smokehouse_desc"),category:"storage",era:"civilized",reqs:{primitive:3,storage:1},trait:["carnivore"],not_trait:["cataclysm","artifical","soul_eater","herbivore","lone_survivor"],grant:["hunting",1],cost:{Knowledge:()=>80},effect:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("tech_smokehouse_easter_effect"):F("tech_smokehouse_effect"),action(){return!!Os($(this)[0])&&(gi("city","smokehouse","silo",{count:0}),!0)},post(){t.tech.s_lodge&&(t.tech.hunting=2)}},lodge:{id:"tech-lodge",title:F("tech_lodge"),desc:F("tech_lodge"),wiki:!!t.race.carnivore,category:"agriculture",era:"civilized",reqs:{hunting:1,housing:1,currency:1},condition:()=>!t.tech.s_lodge,grant:["hunting",2],cost:{Knowledge:()=>180},effect:F("tech_lodge_effect"),action(){return!!Os($(this)[0])&&(gi("city","lodge","farm",{count:0}),!0)}},alt_lodge:{id:"tech-alt_lodge",title(){return this.condition()?F("tech_lodge_alt"):F("tech_lodge")},desc(){return this.condition()?F("tech_lodge_alt"):F("tech_lodge")},wiki:!t.race.carnivore,category:"housing",era:"civilized",reqs:{housing:1,currency:1},grant:["s_lodge",1],condition:()=>!!(("wendigo"===t.race.species||t.race.detritivore)&&!t.race.carnivore&&!t.race.herbivore||t.race.carnivore&&t.race.soul_eater||t.race.artifical||t.race.unfathomable),cost:{Knowledge:()=>t.race.artifical?1e4:180},effect(){return this.condition()?F("tech_lodge_effect_alt"):F("tech_lodge_effect")},action(){return!!Os($(this)[0])&&(gi("city","lodge","farm",{count:0}),!0)}},soul_well:{id:"tech-soul_well",title:F("tech_soul_well"),desc:F("tech_soul_well"),category:"souls",era:"civilized",reqs:{primitive:3},trait:["soul_eater"],not_trait:["cataclysm","artifical","lone_survivor"],grant:["soul_eater",1],cost:{Knowledge:()=>10},effect:F("tech_soul_well_effect"),action(){return!!Os($(this)[0])&&(t.city.soul_well={count:0},!0)}},compost:{id:"tech-compost",title:F("tech_compost"),desc:F("tech_compost_desc"),category:"compost",era:"civilized",reqs:{primitive:3},trait:["detritivore"],not_trait:["cataclysm","artifical","lone_survivor"],grant:["compost",1],cost:{Knowledge:()=>10},effect:F("tech_compost_effect"),action(){return!!Os($(this)[0])&&(t.city.compost={count:0,on:0},!0)}},hot_compost:{id:"tech-hot_compost",title:F("tech_hot_compost"),desc:F("tech_hot_compost"),category:"compost",era:"civilized",reqs:{compost:1},trait:["detritivore"],grant:["compost",2],cost:{Knowledge:()=>100},effect:F("tech_hot_compost_effect"),action(){return!!Os($(this)[0])}},mulching:{id:"tech-mulching",title:F("tech_mulching"),desc:F("tech_mulching"),category:"compost",era:"civilized",reqs:{compost:2,mining:3},trait:["detritivore"],grant:["compost",3],cost:{Knowledge:()=>3200},effect:F("tech_mulching_effect"),action(){return!!Os($(this)[0])}},adv_mulching:{id:"tech-adv_mulching",title:F("tech_adv_mulching"),desc:F("tech_adv_mulching"),category:"compost",era:"discovery",reqs:{compost:3,high_tech:2},trait:["detritivore"],grant:["compost",4],cost:{Knowledge:()=>16e3},effect:F("tech_adv_mulching_effect"),action(){return!!Os($(this)[0])}},agriculture:{id:"tech-agriculture",title:F("tech_agriculture"),desc:F("tech_agriculture_desc"),category:"agriculture",era:"civilized",reqs:{primitive:3},condition:()=>!(!t.race.herbivore&&(t.race.carnivore||t.race.detritivore||t.race.soul_eater)),not_trait:["cataclysm","artifical","lone_survivor","unfathomable"],grant:["agriculture",1],cost:{Knowledge:()=>10},effect:F("tech_agriculture_effect"),action(){return!!Os($(this)[0])&&(gi("city","farm","lodge",{count:0}),!0)}},farm_house:{id:"tech-farm_house",title:F("tech_farm_house"),desc:F("tech_farm_house_desc"),category:"housing",era:"civilized",reqs:{agriculture:1,housing:1,currency:1},grant:["farm",1],cost:{Money:()=>50,Knowledge:()=>180},effect:F("tech_farm_house_effect"),action(){return!!Os($(this)[0])}},irrigation:{id:"tech-irrigation",title:F("tech_irrigation"),desc:F("tech_irrigation_desc"),category:"agriculture",era:"civilized",reqs:{agriculture:1},grant:["agriculture",2],cost:{Knowledge:()=>55},effect:F("tech_irrigation_effect"),action(){return!!Os($(this)[0])}},silo:{id:"tech-silo",title:F("tech_silo"),desc:F("tech_silo_desc"),category:"storage",era:"civilized",reqs:{agriculture:2,storage:1},grant:["agriculture",3],cost:{Knowledge:()=>80},effect:F("tech_silo_effect"),action(){return!!Os($(this)[0])&&(gi("city","silo","smokehouse",{count:0}),!0)}},mill:{id:"tech-mill",title:F("tech_mill"),desc:F("tech_mill_desc"),category:"agriculture",era:"civilized",reqs:{agriculture:3,mining:3},grant:["agriculture",4],cost:{Knowledge:()=>5400},effect:F("tech_mill_effect"),action(){return!!Os($(this)[0])&&(gi("city","mill","windmill",{count:0,on:0}),!0)}},windmill:{id:"tech-windmill",title:F("tech_windmill"),desc:F("tech_windmill_desc"),category:"agriculture",era:"discovery",reqs:{agriculture:4,high_tech:1},grant:["agriculture",5],cost:{Knowledge:()=>16200},effect:F("tech_windmill_effect"),action(){return!!Os($(this)[0])}},windturbine:{id:"tech-windturbine",title:F("tech_windturbine"),desc:F("tech_windturbine"),category:"power_generation",era:"globalized",reqs:{agriculture:5,high_tech:4},grant:["agriculture",6],cost:{Knowledge:()=>66e3},effect:F("tech_windturbine_effect"),action(){return!!Os($(this)[0])}},wind_plant:{id:"tech-wind_plant",title:()=>t.race.unfathomable?F("tech_watermill"):F("tech_windmill"),desc:()=>t.race.unfathomable?F("tech_watermill"):F("tech_windmill"),category:"power_generation",era:"globalized",reqs:{high_tech:4},condition:()=>!!(t.race.carnivore||t.race.detritivore||t.race.artifical||t.race.soul_eater||t.race.unfathomable),not_trait:["herbivore"],grant:["wind_plant",1],cost:{Knowledge:()=>66e3},effect:()=>t.race.unfathomable?F("tech_watermill_effect"):F("tech_wind_plant_effect"),action(){return!!Os($(this)[0])&&(gi("city","windmill","mill",{count:0,on:0}),!0)}},gmfood:{id:"tech-gmfood",title:F("tech_gmfood"),desc:F("tech_gmfood_desc"),category:"agriculture",era:"globalized",reqs:{agriculture:6,genetics:1},grant:["agriculture",7],cost:{Knowledge:()=>95e3},effect:F("tech_gmfood_effect"),action(){return!!Os($(this)[0])}},foundry:{id:"tech-foundry",title:F("tech_foundry"),desc:F("tech_foundry"),category:"crafting",era:"civilized",reqs:{mining:2},grant:["foundry",1],cost:{Knowledge:()=>650},effect:F("tech_foundry_effect"),action(){return!!Os($(this)[0])&&(t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},!0)}},artisans:{id:"tech-artisans",title:F("tech_artisans"),desc:F("tech_artisans"),category:"crafting",era:"civilized",reqs:{foundry:1},grant:["foundry",2],cost:{Knowledge:()=>1500},effect:F("tech_artisans_effect"),action(){return!!Os($(this)[0])}},apprentices:{id:"tech-apprentices",title:F("tech_apprentices"),desc:F("tech_apprentices"),category:"crafting",era:"civilized",reqs:{foundry:2},grant:["foundry",3],cost:{Knowledge:()=>3200},effect:F("tech_apprentices_effect"),action(){return!!Os($(this)[0])}},carpentry:{id:"tech-carpentry",title:F("tech_carpentry"),desc:F("tech_carpentry"),category:"crafting",era:"civilized",reqs:{foundry:3,saw:1},grant:["foundry",4],not_trait:["evil"],cost:{Knowledge:()=>5200},effect:F("tech_carpentry_effect"),action(){return!!Os($(this)[0])}},demonic_craftsman:{id:"tech-demonic_craftsman",title:F("tech_master_craftsman"),desc:F("tech_master_craftsman"),category:"crafting",era:"discovery",wiki:!!t.race.evil,reqs:{foundry:3},grant:["foundry",5],trait:["evil"],cost:{Knowledge:()=>12e3},effect:F("tech_master_craftsman_effect"),action(){return!!Os($(this)[0])}},master_craftsman:{id:"tech-master_craftsman",title:F("tech_master_craftsman"),desc:F("tech_master_craftsman"),category:"crafting",era:"discovery",wiki:!t.race.evil,reqs:{foundry:4},grant:["foundry",5],not_trait:["evil"],cost:{Knowledge:()=>12e3},effect:F("tech_master_craftsman_effect"),action(){return!!Os($(this)[0])}},brickworks:{id:"tech-brickworks",title:F("tech_brickworks"),desc:F("tech_brickworks"),category:"crafting",era:"discovery",reqs:{foundry:5},grant:["foundry",6],cost:{Knowledge:()=>18500},effect:F("tech_brickworks_effect"),action(){return!!Os($(this)[0])}},machinery:{id:"tech-machinery",title:F("tech_machinery"),desc:F("tech_machinery"),category:"crafting",era:"globalized",reqs:{foundry:6,high_tech:4},grant:["foundry",7],cost:{Knowledge:()=>66e3},effect:F("tech_machinery_effect"),action(){return!!Os($(this)[0])}},cnc_machine:{id:"tech-cnc_machine",title:F("tech_cnc_machine"),desc:F("tech_cnc_machine"),category:"crafting",era:"globalized",reqs:{foundry:7,high_tech:8},grant:["foundry",8],cost:{Knowledge:()=>132e3},effect:F("tech_cnc_machine_effect"),action(){return!!Os($(this)[0])}},vocational_training:{id:"tech-vocational_training",title:F("tech_vocational_training"),desc:F("tech_vocational_training"),category:"crafting",era:"industrialized",reqs:{foundry:1,high_tech:3},grant:["v_train",1],cost:{Knowledge:()=>3e4},effect:F("tech_vocational_training_effect"),action(){return!!Os($(this)[0])}},stellar_forge:{id:"tech-stellar_forge",title:F("tech_stellar_forge"),desc:F("tech_stellar_forge"),category:"crafting",era:"intergalactic",reqs:{foundry:8,high_tech:15,gateway:3,neutron:1},grant:["star_forge",1],cost:{Knowledge:()=>45e5},effect:F("tech_stellar_forge_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.stellar_forge={count:0,on:0},!0)}},stellar_smelting:{id:"tech-stellar_smelting",title:F("tech_stellar_smelting"),desc:F("tech_stellar_smelting"),category:"crafting",era:"intergalactic",reqs:{star_forge:1,xeno:4},grant:["star_forge",2],cost:{Knowledge:()=>5e6,Vitreloy:()=>1e4},effect:F("tech_stellar_smelting_effect"),action(){return!!Os($(this)[0])},post(){Ws()}},assembly_line:{id:"tech-assembly_line",title:F("tech_assembly_line"),desc:F("tech_assembly_line"),category:"crafting",era:"globalized",reqs:{high_tech:4},grant:["factory",1],cost:{Knowledge:()=>72e3,Copper:()=>125e3},effect:`${F("tech_assembly_line_effect")} ${F("tech_factory_warning")}`,action(){return!!Os($(this)[0])}},automation:{id:"tech-automation",title:F("tech_automation"),desc:F("tech_automation"),category:"crafting",era:"early_space",reqs:{high_tech:8,factory:1},grant:["factory",2],cost:{Knowledge:()=>165e3},effect:`${F("tech_automation_effect")} ${F("tech_factory_warning")}`,action(){return!!Os($(this)[0])}},laser_cutters:{id:"tech-laser_cutters",title:F("tech_laser_cutters"),desc:F("tech_laser_cutters"),category:"crafting",era:"deep_space",reqs:{high_tech:9,factory:2},grant:["factory",3],cost:{Knowledge:()=>3e5,Elerium:()=>200},effect:`${F("tech_laser_cutters_effect")} ${F("tech_factory_warning")}`,action(){return!!Os($(this)[0])}},high_tech_factories:{id:"tech-high_tech_factories",title:F("tech_high_tech_factories"),desc:F("tech_high_tech_factories"),category:"crafting",era:"intergalactic",reqs:{high_tech:17,alpha:4,factory:3},grant:["factory",4],cost:{Knowledge:()=>135e5,Vitreloy:()=>5e5,Orichalcum:()=>3e5},effect:`${F("tech_high_tech_factories_effect")} ${F("tech_factory_warning")}`,action(){return!!Os($(this)[0])}},theatre:{id:"tech-theatre",title:F("tech_theatre"),desc:F("tech_theatre"),category:"entertainment",era:"civilized",reqs:{housing:1,currency:1,cement:1},grant:["theatre",1],not_trait:["joyless"],cost:{Knowledge:()=>750},effect:F("tech_theatre_effect"),action(){return!!Os($(this)[0])&&(t.city.amphitheatre={count:0},!0)}},playwright:{id:"tech-playwright",title:F("tech_playwright"),desc:F("tech_playwright"),category:"entertainment",era:"civilized",reqs:{theatre:1,science:2},grant:["theatre",2],cost:{Knowledge:()=>1080},effect:F("tech_playwright_effect"),action(){return!!Os($(this)[0])}},magic:{id:"tech-magic",title:()=>"magic"===t.race.universe?F("tech_illusionist"):F("tech_magic"),desc:()=>"magic"===t.race.universe?F("tech_illusionist"):F("tech_magic"),category:"entertainment",era:"discovery",reqs:{theatre:2,high_tech:1},grant:["theatre",3],cost:{Knowledge:()=>7920},effect:F("tech_magic_effect"),effect:()=>"magic"===t.race.universe?F("tech_illusionist_effect"):F("tech_magic_effect"),action(){return!!Os($(this)[0])}},superstars:{id:"tech-superstars",title:F("tech_superstars"),desc:F("tech_superstars"),category:"entertainment",era:"interstellar",reqs:{theatre:3,high_tech:12},grant:["superstar",1],cost:{Knowledge:()=>66e4},effect:F("tech_superstars_effect"),action(){return!!Os($(this)[0])}},radio:{id:"tech-radio",title:F("tech_radio"),desc:F("tech_radio"),category:"entertainment",era:"discovery",reqs:{theatre:3,high_tech:2},grant:["broadcast",1],cost:{Knowledge:()=>16200},effect:()=>F("tech_radio_effect",[Ts()]),action(){return!!Os($(this)[0])}},tv:{id:"tech-tv",title:F("tech_tv"),desc:F("tech_tv"),category:"entertainment",era:"globalized",reqs:{broadcast:1,high_tech:4},grant:["broadcast",2],cost:{Knowledge:()=>67500},effect:()=>F("tech_tv_effect",[Ts()]),action(){return!!Os($(this)[0])}},vr_center:{id:"tech-vr_center",title:F("tech_vr_center"),desc:F("tech_vr_center"),category:"entertainment",era:"interstellar",reqs:{broadcast:2,high_tech:12,stanene:1},grant:["broadcast",3],cost:{Knowledge:()=>62e4},effect:()=>F("tech_vr_center_effect"),action(){return!!Os($(this)[0])&&(t.space.vr_center={count:0,on:0},!0)}},zoo:{id:"tech-zoo",title:F("tech_zoo"),desc:F("tech_zoo"),category:"entertainment",era:"dimensional",reqs:{hell_ruins:2},grant:["zoo",1],cost:{Knowledge:()=>225e5},effect:()=>F("tech_zoo_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.zoo={count:0,on:0},!0)}},casino:{id:"tech-casino",title:F("tech_casino"),desc:F("tech_casino"),category:"entertainment",era:"globalized",reqs:{high_tech:4,currency:5},grant:["gambling",1],cost:{Knowledge:()=>95e3},effect:F("tech_casino_effect"),action(){return!!Os($(this)[0])&&(t.city.casino={count:0,on:0},t.space.spc_casino={count:0,on:0},!0)}},dazzle:{id:"tech-dazzle",title:F("tech_dazzle"),desc:F("tech_dazzle"),category:"banking",era:"globalized",reqs:{gambling:1},grant:["gambling",2],cost:{Knowledge:()=>125e3},effect:F("tech_dazzle_effect"),action(){return!!Os($(this)[0])}},casino_vault:{id:"tech-casino_vault",title:F("tech_casino_vault"),desc:F("tech_casino_vault"),category:"banking",era:"early_space",reqs:{gambling:2,space:3},grant:["gambling",3],cost:{Knowledge:()=>145e3,Iridium:()=>2500},effect:F("tech_casino_vault_effect"),action(){return!!Os($(this)[0])}},otb:{id:"tech-otb",title:F("tech_otb"),desc:F("tech_otb"),category:"banking",era:"deep_space",reqs:{gambling:3,banking:10,high_tech:10},grant:["gambling",4],cost:{Knowledge:()=>39e4},effect:F("tech_otb_effect"),action(){return!!Os($(this)[0])}},online_gambling:{id:"tech-online_gambling",title:F("tech_online_gambling"),desc:F("tech_online_gambling"),category:"banking",era:"interstellar",reqs:{gambling:4,banking:12},grant:["gambling",5],cost:{Knowledge:()=>8e5},effect:F("tech_online_gambling_effect"),action(){return!!Os($(this)[0])}},bolognium_vaults:{id:"tech-bolognium_vaults",title:F("tech_bolognium_vaults"),desc:F("tech_bolognium_vaults"),category:"banking",era:"intergalactic",reqs:{gambling:5,gateway:3},grant:["gambling",6],cost:{Knowledge:()=>39e5,Bolognium:()=>18e4},effect:F("tech_bolognium_vaults_effect"),action(){return!!Os($(this)[0])}},mining:{id:"tech-mining",title:()=>t.race.sappy?F("tech_amber"):F("tech_mining"),desc:()=>t.race.sappy?F("tech_amber"):F("tech_mining_desc"),category:"mining",era:"civilized",reqs:{primitive:3},grant:["mining",1],cost:{Knowledge:()=>45},effect:()=>t.race.sappy?F("tech_amber_effect"):F(t.race.flier?"tech_mining_effect_alt":"tech_mining_effect"),action(){return!!Os($(this)[0])&&(t.city.rock_quarry={count:0,on:0,asbestos:50},t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),!0)}},bayer_process:{id:"tech-bayer_process",title:F("tech_bayer_process"),desc:F("tech_bayer_process_desc"),category:"mining",era:"civilized",reqs:{smelting:2},grant:["alumina",1],cost:{Knowledge:()=>4500},effect:()=>t.race.sappy?F("tech_bayer_process_effect_alt"):F("tech_bayer_process_effect"),action(){return!!Os($(this)[0])&&(t.city.metal_refinery={count:0,on:0},ha(),!0)}},elysis_process:{id:"tech-elysis_process",title:F("tech_elysis_process"),desc:F("tech_elysis_process"),category:"mining",era:"interstellar",reqs:{alumina:1,stanene:1,graphene:1},path:["standard","truepath"],not_trait:["cataclysm","lone_survivor"],grant:["alumina",2],cost:{Knowledge:()=>675e3,Graphene:()=>45e3,Stanene:()=>75e3},effect:F("tech_elysis_process_effect"),action(){return!!Os($(this)[0])}},smelting:{id:"tech-smelting",title:F("tech_smelting"),desc:F("tech_smelting_desc"),category:"mining",era:"civilized",reqs:{mining:3},grant:["smelting",1],cost:{Knowledge:()=>4050},effect:F("tech_smelting_effect"),action(){return!!Os($(this)[0])&&(t.city.smelter={count:0,cap:0,Wood:0,Coal:0,Oil:0,Star:0,StarCap:0,Inferno:0,Iron:0,Steel:0,Iridium:0},!0)},post(){t.race.steelen&&(t.tech.smelting=2,ms())}},steel:{id:"tech-steel",title:F("tech_steel"),desc:F("tech_steel_desc"),category:"mining",era:"civilized",reqs:{smelting:1,mining:4},grant:["smelting",2],condition:()=>!t.race.steelen,cost:{Knowledge:()=>4950,Steel:()=>25},effect:F("tech_steel_effect"),action(){return!!Os($(this)[0])&&(t.resource.Steel.display=!0,!0)},post(){Ws(),zi()}},blast_furnace:{id:"tech-blast_furnace",title:F("tech_blast_furnace"),desc:F("tech_blast_furnace"),category:"mining",era:"discovery",reqs:{smelting:2},grant:["smelting",3],cost:{Knowledge:()=>13500,Coal:()=>2e3},effect:F("tech_blast_furnace_effect"),action(){return!!Os($(this)[0])},post(){t.race.steelen&&(t.tech.smelting=6,ms())}},bessemer_process:{id:"tech-bessemer_process",title:F("tech_bessemer_process"),desc:F("tech_bessemer_process"),category:"mining",era:"discovery",reqs:{smelting:3},grant:["smelting",4],condition:()=>!t.race.steelen,cost:{Knowledge:()=>19800,Coal:()=>5e3},effect:F("tech_bessemer_process_effect"),action(){return!!Os($(this)[0])}},oxygen_converter:{id:"tech-oxygen_converter",title:F("tech_oxygen_converter"),desc:F("tech_oxygen_converter"),category:"mining",era:"industrialized",reqs:{smelting:4,high_tech:3},grant:["smelting",5],condition:()=>!t.race.steelen,cost:{Knowledge:()=>46800,Coal:()=>1e4},effect:F("tech_oxygen_converter_effect"),action(){return!!Os($(this)[0])}},electric_arc_furnace:{id:"tech-electric_arc_furnace",title:F("tech_electric_arc_furnace"),desc:F("tech_electric_arc_furnace"),category:"mining",era:"globalized",reqs:{smelting:5,high_tech:4},grant:["smelting",6],condition:()=>!t.race.steelen,cost:{Knowledge:()=>85500,Copper:()=>25e3},effect:F("tech_electric_arc_furnace_effect"),action(){return!!Os($(this)[0])}},hellfire_furnace:{id:"tech-hellfire_furnace",title:F("tech_hellfire_furnace"),desc:F("tech_hellfire_furnace"),category:"mining",era:"interstellar",reqs:{smelting:6,infernite:1},grant:["smelting",7],cost:{Knowledge:()=>615e3,Infernite:()=>2e3,Soul_Gem:()=>2},effect:F("tech_hellfire_furnace_effect"),action(){return!!Os($(this)[0])}},infernium_fuel:{id:"tech-infernium_fuel",title:F("tech_infernium_fuel"),desc:F("tech_infernium_fuel"),category:"mining",era:"dimensional",reqs:{smelting:7,hell_ruins:4},grant:["smelting",8],cost:{Knowledge:()=>275e5,Coal:()=>45e6,Oil:()=>5e5,Infernite:()=>75e4},effect:F("tech_infernium_fuel_effect"),action(){return!!Os($(this)[0])},post(){Ws()}},iridium_smelting_perk:{id:"tech-iridium_smelting_perk",title:F("tech_iridium_smelting"),desc:F("tech_iridium_smelting"),category:"mining",era:"early_space",path:["standard"],reqs:{smelting:6,space:3},condition:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=3),grant:["irid_smelting",1],cost:{Knowledge:()=>35e4,Mythril:()=>2500},effect:F("tech_iridium_smelting_effect"),action(){return!!Os($(this)[0])}},rotary_kiln:{id:"tech-rotary_kiln",title:F("tech_rotary_kiln"),desc:F("tech_rotary_kiln"),category:"mining",era:"industrialized",reqs:{smelting:3,high_tech:3},grant:["copper",1],cost:{Knowledge:()=>57600,Coal:()=>8e3},effect:F("tech_rotary_kiln_effect"),action(){return!!Os($(this)[0])}},metal_working:{id:"tech-metal_working",title:F("tech_metal_working"),desc:F("tech_metal_working_desc"),category:"mining",era:"civilized",reqs:{mining:1},grant:["mining",2],cost:{Knowledge:()=>350},effect:F("tech_metal_working_effect"),action(){return!!Os($(this)[0])&&(t.city.mine={count:0,on:0},!0)}},iron_mining:{id:"tech-iron_mining",title:F("tech_iron_mining"),desc:F("tech_iron_mining_desc"),category:"mining",era:"civilized",reqs:{mining:2},grant:["mining",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?500:2500},effect:F("tech_iron_mining_effect"),action(){return!!Os($(this)[0])&&(t.resource.Iron.display=!0,t.city.foundry&&t.city.foundry.count>0&&(t.resource.Wrought_Iron.display=!0,ha()),!0)},post(){zi()}},coal_mining:{id:"tech-coal_mining",title:F("tech_coal_mining"),desc:F("tech_coal_mining_desc"),category:"power_generation",era:"civilized",reqs:{mining:3},grant:["mining",4],cost:{Knowledge:()=>4320},effect:F("tech_coal_mining_effect"),action(){return!!Os($(this)[0])&&(t.city.coal_mine={count:0,on:0},t.resource.Coal.display=!0,!0)},post(){zi()}},storage:{id:"tech-storage",title:F("tech_storage"),desc:F("tech_storage_desc"),category:"storage",era:"civilized",reqs:{primitive:3,currency:1},grant:["storage",1],cost:{Knowledge:()=>20},effect:F("tech_storage_effect"),action(){return!!Os($(this)[0])&&(t.city.shed={count:0},!0)}},reinforced_shed:{id:"tech-reinforced_shed",title:F("tech_reinforced_shed"),desc:F("tech_reinforced_shed_desc"),category:"storage",era:"civilized",reqs:{storage:1,cement:1,mining:3},grant:["storage",2],cost:{Money:()=>3750,Knowledge:()=>2550,Iron:()=>750,Cement:()=>500},effect:F("tech_reinforced_shed_effect"),action(){return!!Os($(this)[0])}},barns:{id:"tech-barns",title:F("tech_barns"),desc:F("tech_barns_desc"),category:"storage",era:"discovery",reqs:{storage:2,smelting:2,alumina:1},grant:["storage",3],cost:{Knowledge:()=>15750,Aluminium:()=>3e3,Steel:()=>3e3},effect:F("tech_barns_effect"),action(){return!!Os($(this)[0])},post(){Ks(!1,["city-shed"])}},warehouse:{id:"tech-warehouse",title:F("tech_warehouse"),desc:F("tech_warehouse_desc"),category:"storage",era:"industrialized",reqs:{storage:3,high_tech:3,smelting:2},grant:["storage",4],cost:{Knowledge:()=>40500,Titanium:()=>3e3},effect:F("tech_warehouse_effect"),action(){return!!Os($(this)[0])},post(){Ks(!1,["city-shed"])}},cameras:{id:"tech-cameras",title:F("tech_cameras"),desc:F("tech_cameras_desc"),category:"storage",era:"globalized",reqs:{storage:4,high_tech:4},grant:["storage",5],cost:{Money:()=>9e4,Knowledge:()=>65e3},effect:F("tech_cameras_effect"),action(){return!!Os($(this)[0])}},pocket_dimensions:{id:"tech-pocket_dimensions",title:F("tech_pocket_dimensions"),desc:F("tech_pocket_dimensions_desc"),category:"storage",era:"early_space",path:["standard"],reqs:{particles:1,storage:5},grant:["storage",6],cost:{Knowledge:()=>108e3},effect:F("tech_pocket_dimensions_effect"),action(){return!!Os($(this)[0])}},ai_logistics:{id:"tech-ai_logistics",title:F("tech_ai_logistics"),desc:F("tech_ai_logistics"),category:"storage",era:"interstellar",reqs:{storage:6,proxima:2,science:13},grant:["storage",7],cost:{Knowledge:()=>65e4},effect:F("tech_ai_logistics_effect"),action(){return!!Os($(this)[0])}},containerization:{id:"tech-containerization",title:F("tech_containerization"),desc:F("tech_containerization_desc"),category:"storage",era:"civilized",reqs:{cement:1,mining:1,storage:1,science:1},grant:["container",1],cost:{Knowledge:()=>2700},effect:F("tech_containerization_effect"),action(){return!!Os($(this)[0])&&(t.city.storage_yard={count:0},!0)}},reinforced_crates:{id:"tech-reinforced_crates",title:F("tech_reinforced_crates"),desc:F("tech_reinforced_crates"),category:"storage",era:"civilized",reqs:{container:1,smelting:2},grant:["container",2],cost:{Knowledge:()=>6750,Sheet_Metal:()=>100},effect(){if(t.race.smoldering||t.race.kindling_kindred||t.race.evil){let e=F("resource_Bones_name");return t.race.smoldering?e=F("resource_Chrysotile_name"):t.race.kindling_kindred&&(e=F("resource_Stone_name")),F("tech_reinforced_crates_alt_effect",[e])}return F("tech_reinforced_crates_effect")},action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},cranes:{id:"tech-cranes",title:F("tech_cranes"),desc:F("tech_cranes_desc"),category:"storage",era:"discovery",reqs:{container:2,high_tech:2},grant:["container",3],cost:{Knowledge:()=>18e3,Copper:()=>1e3,Steel:()=>2500},effect:F("tech_cranes_effect"),action(){return!!Os($(this)[0])}},titanium_crates:{id:"tech-titanium_crates",title:()=>F("tech_titanium_crates",[t.resource.Titanium.name]),desc:()=>F("tech_titanium_crates",[t.resource.Titanium.name]),category:"storage",era:"globalized",reqs:{container:3,titanium:1},grant:["container",4],cost:{Knowledge:()=>67500,Titanium:()=>1e3},effect:()=>F("tech_titanium_crates_effect",[t.resource.Titanium.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},mythril_crates:{id:"tech-mythril_crates",title:()=>F("tech_mythril_crates",[t.resource.Mythril.name]),desc:()=>F("tech_mythril_crates",[t.resource.Mythril.name]),category:"storage",era:"early_space",reqs:{container:4,space:3},grant:["container",5],cost:{Knowledge:()=>145e3,Mythril:()=>350},effect:()=>F("tech_mythril_crates_effect",[t.resource.Mythril.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},infernite_crates:{id:"tech-infernite_crates",title:()=>F("tech_crates",[t.resource.Infernite.name]),desc:()=>F("tech_infernite_crates_desc",[t.resource.Infernite.name]),category:"storage",era:"interstellar",reqs:{container:5,infernite:1},grant:["container",6],cost:{Knowledge:()=>575e3,Infernite:()=>1e3},effect:()=>F("tech_infernite_crates_effect",[t.resource.Infernite.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},graphene_crates:{id:"tech-graphene_crates",title:()=>F("tech_crates",[t.resource.Graphene.name]),desc:()=>F("tech_crates",[t.resource.Graphene.name]),category:"storage",era:"interstellar",path:["standard","truepath"],reqs:{container:6,graphene:1},grant:["container",7],cost:{Knowledge:()=>725e3,Graphene:()=>75e3},effect:()=>F("tech_graphene_crates_effect",[t.resource.Graphene.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},bolognium_crates:{id:"tech-bolognium_crates",title:()=>F("tech_crates",[t.resource.Bolognium.name]),desc:()=>F("tech_crates",[t.resource.Bolognium.name]),category:"storage",era:"intergalactic",reqs:{container:7,gateway:3},grant:["container",8],cost:{Knowledge:()=>342e4,Bolognium:()=>9e4},effect:()=>F("tech_bolognium_crates_effect",[t.resource.Bolognium.name]),action(){return!!Os($(this)[0])}},steel_containers:{id:"tech-steel_containers",title:()=>F("tech_containers",[t.resource.Steel.name]),desc:()=>F("tech_steel_containers_desc",[t.resource.Steel.name]),category:"storage",era:"discovery",reqs:{smelting:2,container:1},grant:["steel_container",1],cost:{Knowledge:()=>9e3,Steel:()=>250},effect(){if(t.race.smoldering||t.race.kindling_kindred||t.race.evil){let e=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood";return F("tech_steel_containers_alt_effect",[t.resource[e].name,t.resource.Steel.name])}return F("tech_steel_containers_effect",[t.resource.Steel.name])},action(){return!!Os($(this)[0])&&(t.city.warehouse={count:0},!0)}},gantry_crane:{id:"tech-gantry_crane",title:F("tech_gantry_crane"),desc:F("tech_gantry_crane_desc"),category:"storage",era:"discovery",reqs:{steel_container:1,high_tech:2},grant:["steel_container",2],cost:{Knowledge:()=>22500,Steel:()=>5e3},effect:F("tech_gantry_crane_effect"),action(){return!!Os($(this)[0])}},alloy_containers:{id:"tech-alloy_containers",title:()=>F("tech_containers",[t.resource.Alloy.name]),desc:()=>F("tech_alloy_containers_desc",[t.resource.Alloy.name]),category:"storage",era:"industrialized",reqs:{steel_container:2,storage:4},grant:["steel_container",3],cost:{Knowledge:()=>49500,Alloy:()=>2500},effect:()=>F("tech_alloy_containers_effect",[t.resource.Alloy.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},mythril_containers:{id:"tech-mythril_containers",title:()=>F("tech_containers",[t.resource.Mythril.name]),desc:()=>F("tech_mythril_containers_desc",[t.resource.Mythril.name]),category:"storage",era:"early_space",reqs:{steel_container:3,space:3},grant:["steel_container",4],cost:{Knowledge:()=>165e3,Mythril:()=>500},effect:()=>F("tech_mythril_containers_effect",[t.resource.Mythril.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},adamantite_containers:{id:"tech-adamantite_containers",title:()=>F("tech_containers",[t.resource.Adamantite.name]),desc:()=>F("tech_adamantite_containers_desc",[t.resource.Adamantite.name]),category:"storage",era:"interstellar",reqs:{steel_container:4,alpha:2},grant:["steel_container",5],cost:{Knowledge:()=>525e3,Adamantite:()=>17500},effect:()=>F("tech_adamantite_containers_effect",[t.resource.Adamantite.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},aerogel_containers:{id:"tech-aerogel_containers",title:()=>F("tech_containers",[t.resource.Aerogel.name]),desc:()=>F("tech_containers",[t.resource.Aerogel.name]),category:"storage",era:"interstellar",reqs:{steel_container:5,aerogel:1},grant:["steel_container",6],cost:{Knowledge:()=>775e3,Aerogel:()=>500},effect:()=>F("tech_aerogel_containers_effect",[t.resource.Aerogel.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},bolognium_containers:{id:"tech-bolognium_containers",title:()=>F("tech_containers",[t.resource.Bolognium.name]),desc:()=>F("tech_containers",[t.resource.Bolognium.name]),category:"storage",era:"intergalactic",reqs:{steel_container:6,gateway:3},grant:["steel_container",7],cost:{Knowledge:()=>35e5,Bolognium:()=>125e3},effect:()=>F("tech_bolognium_containers_effect",[t.resource.Bolognium.name]),action(){return!!Os($(this)[0])}},nanoweave_containers:{id:"tech-nanoweave_containers",title:()=>F("tech_nanoweave_containers",[t.resource.Nanoweave.name]),desc:()=>F("tech_nanoweave_containers",[t.resource.Nanoweave.name]),category:"storage",era:"intergalactic",reqs:{steel_container:7,nanoweave:1},grant:["steel_container",8],cost:{Knowledge:()=>9e6,Nanoweave:()=>5e4},effect:()=>F("tech_nanoweave_containers_effect",[t.resource.Nanoweave.name]),action(){return!!Os($(this)[0])}},evil_planning:{id:"tech-evil_planning",title:F("tech_urban_planning"),desc:F("tech_urban_planning"),category:"queues",era:"civilized",wiki:!!t.race.terrifying,reqs:{banking:2},grant:["queue",1],trait:["terrifying"],cost:{Knowledge:()=>2500},effect:F("tech_urban_planning_effect"),action(){return!!Os($(this)[0])&&(t.queue.display=!0,!0)},post(){Ri()}},urban_planning:{id:"tech-urban_planning",title:F("tech_urban_planning"),desc:F("tech_urban_planning"),category:"queues",era:"civilized",wiki:!t.race.terrifying,reqs:{banking:2,currency:2},grant:["queue",1],not_trait:["terrifying"],cost:{Knowledge:()=>2500},effect:F("tech_urban_planning_effect"),action(){return!!Os($(this)[0])&&(t.queue.display=!0,t.settings.msgFilters.queue.unlocked||(t.settings.msgFilters.queue.unlocked=!0,t.settings.msgFilters.queue.vis=!0),!0)},post(){Ri()}},zoning_permits:{id:"tech-zoning_permits",title:F("tech_zoning_permits"),desc:F("tech_zoning_permits"),category:"queues",era:"industrialized",reqs:{queue:1,high_tech:3},grant:["queue",2],cost:{Knowledge:()=>28e3},effect:()=>F("tech_zoning_permits_effect",[t.genes.queue&&t.genes.queue>=2?4:2]),action(){return!!Os($(this)[0])},post(){Ri()}},urbanization:{id:"tech-urbanization",title:F("tech_urbanization"),desc:F("tech_urbanization"),category:"queues",era:"globalized",reqs:{queue:2,high_tech:6},grant:["queue",3],cost:{Knowledge:()=>95e3},effect:()=>F("tech_urbanization_effect",[t.genes.queue&&t.genes.queue>=2?6:3]),action(){return!!Os($(this)[0])},post(){Ri()}},assistant:{id:"tech-assistant",title:F("tech_assistant"),desc:F("tech_assistant"),category:"queues",era:"civilized",reqs:{queue:1,science:4},grant:["r_queue",1],cost:{Knowledge:()=>5e3},effect:F("tech_assistant_effect"),action(){return!!Os($(this)[0])&&(t.r_queue.display=!0,t.settings.msgFilters.building_queue.unlocked||(t.settings.msgFilters.building_queue.unlocked=!0,t.settings.msgFilters.building_queue.vis=!0,t.settings.msgFilters.research_queue.unlocked=!0,t.settings.msgFilters.research_queue.vis=!0),!0)},post(){Hi(),t.settings.tabLoad&&$("#resQueue").removeAttr("style")}},government:{id:"tech-government",title:F("tech_government"),desc:F("tech_government_desc"),category:"government",era:"civilized",reqs:{currency:1},grant:["govern",1],cost:{Knowledge:()=>750},effect:F("tech_government_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#govType"},"update"),sc({el:"#foreign"},"update"),sc({el:"#government .govTabs2"},"update"),t.settings.tabLoad&&$("#government .govTabs2").removeAttr("style")}},theocracy:{id:"tech-theocracy",title:F("govern_theocracy"),desc:F("govern_theocracy"),category:"government",era:"civilized",reqs:{govern:1,theology:2},grant:["gov_theo",1],cost:{Knowledge:()=>1200},effect:F("tech_theocracy_effect"),action(){return!!Os($(this)[0])}},republic:{id:"tech-republic",title:F("govern_republic"),desc:F("govern_republic"),category:"government",era:"discovery",reqs:{govern:1},condition:()=>!!(t.tech.trade&&t.tech.trade>=2||t.race.terrifying),grant:["govern",2],cost:{Knowledge:()=>17e3},effect:F("tech_republic_effect"),action(){return!!Os($(this)[0])}},socialist:{id:"tech-socialist",title:F("govern_socialist"),desc:F("govern_socialist"),category:"government",era:"discovery",reqs:{govern:1},condition:()=>!!(t.tech.trade&&t.tech.trade>=2||t.race.terrifying),grant:["gov_soc",1],cost:{Knowledge:()=>17e3},effect:F("tech_socialist_effect"),action(){return!!Os($(this)[0])}},corpocracy:{id:"tech-corpocracy",title:F("govern_corpocracy"),desc:F("govern_corpocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},grant:["gov_corp",1],cost:{Knowledge:()=>26e3},effect:F("tech_corpocracy_effect"),action(){return!!Os($(this)[0])}},technocracy:{id:"tech-technocracy",title:F("govern_technocracy"),desc:F("govern_technocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},grant:["govern",3],cost:{Knowledge:()=>26e3},effect:F("tech_technocracy_effect"),action(){return!!Os($(this)[0])}},federation:{id:"tech-federation",title:F("govern_federation"),desc:F("govern_federation"),category:"government",era:"early_space",reqs:{govern:2},condition:()=>t.tech.unify&&t.tech.unify>=2||ue(),grant:["gov_fed",1],cost:{Knowledge:()=>3e4},effect:F("tech_federation_effect"),action(){return!!Os($(this)[0])}},magocracy:{id:"tech-magocracy",title:F("govern_magocracy"),desc:F("govern_magocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},condition:()=>"magic"===t.race.universe,grant:["gov_mage",1],cost:{Knowledge:()=>26e3},effect:F("tech_magocracy_effect"),action(){return!!Os($(this)[0])}},governor:{id:"tech-governor",title:F("tech_governor"),desc:F("tech_governor"),category:"government",era:"civilized",reqs:{govern:1},condition:()=>!(!t.genes.governor||"anarchy"===t.civic.govern.type),grant:["governor",1],cost:{Knowledge:()=>1e3},effect:F("tech_governor_effect"),action(){return!!Os($(this)[0])&&(t.settings.showGovernor=!0,!0)},post(){K()}},spy:{id:"tech-spy",title:F("tech_spy"),desc:F("tech_spy"),category:"spies",era:"civilized",reqs:{govern:1},grant:["spy",1],cost:{Knowledge:()=>1250},effect:F("tech_spy_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#foreign"},"update")}},espionage:{id:"tech-espionage",title:F("tech_espionage"),desc:F("tech_espionage"),category:"spies",era:"discovery",reqs:{spy:1,high_tech:1},grant:["spy",2],cost:{Knowledge:()=>7500},effect:F("tech_espionage_effect"),action(){return!!Os($(this)[0])&&(t.settings.msgFilters.spy.unlocked||(t.settings.msgFilters.spy.unlocked=!0,t.settings.msgFilters.spy.vis=!0),!0)},post(){sc({el:"#foreign"},"update")}},spy_training:{id:"tech-spy_training",title:F("tech_spy_training"),desc:F("tech_spy_training"),category:"spies",era:"discovery",reqs:{spy:2,boot_camp:1},grant:["spy",3],cost:{Knowledge:()=>1e4},effect:F("tech_spy_training_effect"),action(){return!!Os($(this)[0])}},spy_gadgets:{id:"tech-spy_gadgets",title:F("tech_spy_gadgets"),desc:F("tech_spy_gadgets"),category:"spies",era:"discovery",reqs:{spy:3,high_tech:2},grant:["spy",4],cost:{Knowledge:()=>15e3},effect:F("tech_spy_gadgets_effect"),action(){return!!Os($(this)[0])}},code_breakers:{id:"tech-code_breakers",title:F("tech_code_breakers"),desc:F("tech_code_breakers"),category:"spies",era:"industrialized",reqs:{spy:4,high_tech:4},grant:["spy",5],cost:{Knowledge:()=>55e3},effect:F("tech_code_breakers_effect"),action(){return!!Os($(this)[0])}},currency:{id:"tech-currency",title:F("tech_currency"),desc:F("tech_currency_desc"),category:"banking",era:"civilized",reqs:{housing:1},grant:["currency",1],cost:{Knowledge:()=>22,Lumber:()=>10},effect:F("tech_currency_effect"),action(){return!!Os($(this)[0])&&(t.resource.Money.display=!0,!0)}},market:{id:"tech-market",title:F("tech_market"),desc:F("tech_market_desc"),category:"banking",era:"civilized",reqs:{banking:1,govern:1},not_trait:["terrifying"],grant:["currency",2],cost:{Knowledge:()=>t.race.banana?300:1800},effect:F("tech_market_effect"),action(){return!!Os($(this)[0])&&(t.settings.showResources=!0,t.settings.showMarket=!0,!0)}},tax_rates:{id:"tech-tax_rates",title:F("tech_tax_rates"),desc:F("tech_tax_rates_desc"),category:"banking",era:"civilized",reqs:{banking:2,currency:2,queue:1},not_trait:["terrifying"],grant:["currency",3],cost:{Knowledge:()=>3375},effect:F("tech_tax_rates_effect"),action(){return!!Os($(this)[0])&&(t.civic.taxes.display=!0,!0)}},large_trades:{id:"tech-large_trades",title:F("tech_large_trades"),desc:F("tech_large_trades_desc"),category:"market",era:"civilized",reqs:{currency:3},not_trait:["terrifying"],grant:["currency",4],cost:{Knowledge:()=>6750},effect:F("tech_large_trades_effect"),action(){return!!Os($(this)[0])},post(){t.race.noble&&(t.tech.currency=5,ms())}},corruption:{id:"tech-corruption",title:F("tech_corruption"),desc:F("tech_corruption_desc"),category:"banking",era:"industrialized",reqs:{currency:4,high_tech:3},not_trait:["terrifying","noble"],grant:["currency",5],cost:{Knowledge:()=>36e3},effect:F("tech_corruption_effect"),action(){return!!Os($(this)[0])}},massive_trades:{id:"tech-massive_trades",title:F("tech_massive_trades"),desc:F("tech_massive_trades_desc"),category:"market",era:"globalized",reqs:{currency:5,high_tech:4},not_trait:["terrifying"],grant:["currency",6],cost:{Knowledge:()=>108e3},effect:F("tech_massive_trades_effect"),action(){return!!Os($(this)[0])}},trade:{id:"tech-trade",title:F("tech_trade"),desc:F("tech_trade_desc"),category:"market",era:"civilized",reqs:{currency:2,military:1},not_trait:["terrifying"],grant:["trade",1],cost:{Knowledge:()=>t.race.banana?1200:4500},effect:F("tech_trade_effect"),action(){return!!Os($(this)[0])&&(t.city.trade={count:0},t.city.market.active=!0,!0)}},diplomacy:{id:"tech-diplomacy",title:F("tech_diplomacy"),desc:F("tech_diplomacy_desc"),category:"market",era:"discovery",reqs:{trade:1,high_tech:1},not_trait:["terrifying"],grant:["trade",2],cost:{Knowledge:()=>16200},effect:F("tech_diplomacy_effect"),action(){return!!Os($(this)[0])}},freight:{id:"tech-freight",title:F("tech_freight"),desc:F("tech_freight_desc"),category:"market",era:"industrialized",reqs:{trade:2,high_tech:3},not_trait:["terrifying"],grant:["trade",3],cost:{Knowledge:()=>37800},effect:F("tech_freight_effect"),action(){return!!Os($(this)[0])},post(){t.tech.high_tech>=6&&Oe("Physics")}},wharf:{id:"tech-wharf",title:F("tech_wharf"),desc:F("tech_wharf_desc"),category:"market",era:"industrialized",reqs:{trade:1,high_tech:3,oil:1},not_trait:["thalassophobia"],grant:["wharf",1],cost:{Knowledge:()=>44e3},effect:F("tech_wharf_effect"),action(){return!!Os($(this)[0])&&(t.city.wharf={count:0},!0)}},banking:{id:"tech-banking",title:F("tech_banking"),desc:F("tech_banking_desc"),category:"banking",era:"civilized",reqs:{currency:1},grant:["banking",1],cost:{Knowledge:()=>90},effect:F("tech_banking_effect"),action(){return!!Os($(this)[0])&&(t.city.bank={count:0},!0)}},investing:{id:"tech-investing",title:F("tech_investing"),desc:F("tech_investing_desc"),category:"banking",era:"civilized",reqs:{banking:1},grant:["banking",2],cost:{Money:()=>2500,Knowledge:()=>900},effect:F("tech_investing_effect"),action(){return!!Os($(this)[0])&&(t.civic.banker.display=!0,!0)}},vault:{id:"tech-vault",title:F("tech_vault"),desc:F("tech_vault_desc"),category:"banking",era:"civilized",reqs:{banking:2,cement:1},grant:["banking",3],cost:{Money:()=>2e3,Knowledge:()=>3600,Iron:()=>500,Cement:()=>750},effect:F("tech_vault_effect"),action(){return!!Os($(this)[0])}},bonds:{id:"tech-bonds",title:F("tech_bonds"),desc:F("tech_bonds"),category:"banking",era:"civilized",reqs:{banking:3},grant:["banking",4],cost:{Money:()=>2e4,Knowledge:()=>5e3},effect:F("tech_bonds_effect"),action(){return!!Os($(this)[0])}},steel_vault:{id:"tech-steel_vault",title:F("tech_steel_vault"),desc:F("tech_steel_vault"),category:"banking",era:"civilized",reqs:{banking:4,smelting:2},grant:["banking",5],cost:{Money:()=>3e4,Knowledge:()=>6750,Steel:()=>3e3},effect:F("tech_steel_vault_effect"),action(){return!!Os($(this)[0])}},eebonds:{id:"tech-eebonds",title:F("tech_eebonds"),desc:F("tech_eebonds"),category:"banking",era:"discovery",reqs:{banking:5,high_tech:1},grant:["banking",6],cost:{Money:()=>75e3,Knowledge:()=>18e3},effect:F("tech_eebonds_effect"),action(){return!!Os($(this)[0])}},swiss_banking:{id:"tech-swiss_banking",title:Ur(),desc:Ur(),category:"banking",era:"industrialized",reqs:{banking:6},grant:["banking",7],cost:{Money:()=>125e3,Knowledge:()=>45e3},effect:F("tech_swiss_banking_effect"),action(){return!!Os($(this)[0])}},safety_deposit:{id:"tech-safety_deposit",title:F("tech_safety_deposit"),desc:F("tech_safety_deposit"),category:"banking",era:"globalized",reqs:{banking:7,high_tech:4},grant:["banking",8],cost:{Money:()=>25e4,Knowledge:()=>67500},effect:F("tech_safety_deposit_effect"),action(){return!!Os($(this)[0])}},stock_market:{id:"tech-stock_market",title:F("tech_stock_market"),desc:F("tech_stock_market"),category:"arpa",era:"globalized",reqs:{banking:8,high_tech:6},grant:["banking",9],cost:{Money:()=>325e3,Knowledge:()=>108e3},effect:F("tech_stock_market_effect"),action(){return!!Os($(this)[0])},post(){Oe("Physics")}},hedge_funds:{id:"tech-hedge_funds",title:F("tech_hedge_funds"),desc:F("tech_hedge_funds"),category:"banking",era:"early_space",reqs:{banking:9,stock_exchange:1},grant:["banking",10],cost:{Money:()=>375e3,Knowledge:()=>126e3},effect:F("tech_hedge_funds_effect"),action(){return!!Os($(this)[0])}},four_oh_one:{id:"tech-four_oh_one",title:F("tech_four_oh_one"),desc:F("tech_four_oh_one"),category:"banking",era:"early_space",reqs:{banking:10},grant:["banking",11],cost:{Money:()=>425e3,Knowledge:()=>144e3},effect:F("tech_four_oh_one_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_four_oh_one_flair")},exchange:{id:"tech-exchange",title:F("tech_exchange"),desc:F("tech_exchange"),category:"banking",era:"interstellar",reqs:{banking:11,alpha:2,graphene:1},grant:["banking",12],cost:{Money:()=>1e6,Knowledge:()=>675e3},effect:F("tech_exchange_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.exchange={count:0,on:0},!0)}},foreign_investment:{id:"tech-foreign_investment",title:F("tech_foreign_investment"),desc:F("tech_foreign_investment"),category:"banking",era:"intergalactic",reqs:{banking:12,xeno:10},grant:["banking",13],cost:{Money:()=>1e8,Knowledge:()=>8e6},effect:F("tech_foreign_investment_effect"),action(){return!!Os($(this)[0])}},mythril_vault:{id:"tech-mythril_vault",title:F("tech_mythril_vault"),desc:F("tech_mythril_vault"),category:"banking",era:"early_space",reqs:{banking:5,space:3},grant:["vault",1],cost:{Money:()=>5e5,Knowledge:()=>15e4,Mythril:()=>750},effect:F("tech_mythril_vault_effect"),action(){return!!Os($(this)[0])}},neutronium_vault:{id:"tech-neutronium_vault",title:F("tech_neutronium_vault"),desc:F("tech_neutronium_vault"),category:"banking",era:"deep_space",reqs:{vault:1,gas_moon:1},grant:["vault",2],cost:{Money:()=>75e4,Knowledge:()=>28e4,Neutronium:()=>650},effect:F("tech_neutronium_vault_effect"),action(){return!!Os($(this)[0])}},adamantite_vault:{id:"tech-adamantite_vault",title:F("tech_adamantite_vault"),desc:F("tech_adamantite_vault"),category:"banking",era:"interstellar",reqs:{vault:2,alpha:2},grant:["vault",3],cost:{Money:()=>2e6,Knowledge:()=>56e4,Adamantite:()=>2e4},effect:F("tech_adamantite_vault_effect"),action(){return!!Os($(this)[0])}},graphene_vault:{id:"tech-graphene_vault",title:F("tech_graphene_vault"),desc:F("tech_graphene_vault"),category:"banking",era:"interstellar",path:["standard","truepath"],reqs:{vault:3,graphene:1},grant:["vault",4],cost:{Money:()=>3e6,Knowledge:()=>75e4,Graphene:()=>4e5},effect:F("tech_graphene_vault_effect"),action(){return!!Os($(this)[0])}},home_safe:{id:"tech-home_safe",title:F("tech_home_safe"),desc:F("tech_home_safe"),category:"banking",era:"discovery",reqs:{banking:5},grant:["home_safe",1],cost:{Money:()=>42e3,Knowledge:()=>8e3,Steel:()=>4500},effect:F("tech_home_safe_effect"),action(){return!!Os($(this)[0])}},fire_proof_safe:{id:"tech-fire_proof_safe",title:F("tech_fire_proof_safe"),desc:F("tech_fire_proof_safe"),category:"banking",era:"early_space",reqs:{home_safe:1,space:3},grant:["home_safe",2],cost:{Money:()=>25e4,Knowledge:()=>12e4,Iridium:()=>1e3},effect:F("tech_fire_proof_safe_effect"),action(){return!!Os($(this)[0])}},tamper_proof_safe:{id:"tech-tamper_proof_safe",title:F("tech_tamper_proof_safe"),desc:F("tech_tamper_proof_safe"),category:"banking",era:"interstellar",reqs:{home_safe:2,infernite:1},grant:["home_safe",3],cost:{Money:()=>25e5,Knowledge:()=>6e5,Infernite:()=>800},effect:F("tech_tamper_proof_safe_effect"),action(){return!!Os($(this)[0])}},monument:{id:"tech-monument",title:F("tech_monument"),desc:F("tech_monument"),category:"arpa",era:"globalized",reqs:{high_tech:6},grant:["monument",1],cost:{Knowledge:()=>12e4},effect:F("tech_monument_effect"),action(){return!!Os($(this)[0])&&(t.arpa.m_type=Oe("Monument"),!0)},post(){Oe("Physics")}},tourism:{id:"tech-tourism",title:F("tech_tourism"),desc:F("tech_tourism"),category:"banking",era:"early_space",reqs:{monuments:2,monument:1},not_trait:["cataclysm","lone_survivor"],grant:["monument",2],cost:{Knowledge:()=>15e4},effect:F("tech_tourism_effect"),action(){return!!Os($(this)[0])&&(t.city.tourist_center={count:0,on:0},!0)}},xeno_tourism:{id:"tech-xeno_tourism",title:F("tech_xeno_tourism"),desc:F("tech_xeno_tourism"),category:"banking",era:"intergalactic",reqs:{monument:2,xeno:10,monuments:10},not_trait:["cataclysm"],grant:["monument",3],cost:{Knowledge:()=>8e6},effect:F("tech_xeno_tourism_effect"),action(){return!!Os($(this)[0])}},science:{id:"tech-science",title:F("tech_science"),desc:F("tech_science_desc"),category:"science",era:"civilized",reqs:{housing:1},grant:["science",1],cost:{Knowledge:()=>65},effect:F("tech_science_effect"),action(){return!!Os($(this)[0])&&(t.city.university={count:0},!0)}},library:{id:"tech-library",title:F("tech_library"),desc:F("tech_library_desc"),category:"science",era:"civilized",reqs:{science:1,cement:1},grant:["science",2],cost:{Knowledge:()=>720},effect:F("tech_library_effect"),action(){return!!Os($(this)[0])&&(t.city.library={count:0},!0)}},thesis:{id:"tech-thesis",title:F("tech_thesis"),desc:F("tech_thesis_desc"),category:"science",era:"civilized",reqs:{science:2},grant:["science",3],cost:{Knowledge:()=>1125},effect:F("tech_thesis_effect"),action(){return!!Os($(this)[0])}},research_grant:{id:"tech-research_grant",title:F("tech_research_grant"),desc:F("tech_research_grant_desc"),category:"science",era:"civilized",reqs:{science:3},grant:["science",4],cost:{Knowledge:()=>3240},effect:F("tech_research_grant_effect"),action(){return!!Os($(this)[0])}},scientific_journal:{id:"tech-scientific_journal",title:()=>"magic"===t.race.universe?F("tech_magic_tomes"):F("tech_scientific_journal"),desc:()=>"magic"===t.race.universe?F("tech_magic_tomes_desc"):F("tech_scientific_journal_desc"),category:"science",era:"industrialized",reqs:{science:4,high_tech:3},grant:["science",5],cost:{Knowledge:()=>27e3},effect:()=>"magic"===t.race.universe?F("tech_magic_tomes_effect"):F("tech_scientific_journal_effect"),action(){return!!Os($(this)[0])}},adjunct_professor:{id:"tech-adjunct_professor",title:F("tech_adjunct_professor"),desc:F("tech_adjunct_professor"),category:"science",era:"industrialized",reqs:{science:5},grant:["science",6],cost:{Knowledge:()=>36e3},effect:()=>F("tech_adjunct_professor_effect",[Ts(),t.civic.scientist?t.civic.scientist.name:F("job_scientist")]),action(){return!!Os($(this)[0])}},tesla_coil:{id:"tech-tesla_coil",title:F("tech_tesla_coil"),desc:F("tech_tesla_coil_desc"),category:"science",era:"industrialized",reqs:{science:6,high_tech:3},grant:["science",7],cost:{Knowledge:()=>51750},effect:()=>F("tech_tesla_coil_effect",[Ts()]),action(){return!!Os($(this)[0])}},internet:{id:"tech-internet",title:F("tech_internet"),desc:F("tech_internet"),category:"science",era:"globalized",reqs:{science:7,high_tech:4},grant:["science",8],cost:{Knowledge:()=>61200},effect:F("tech_internet_effect"),action(){return!!Os($(this)[0])&&(t.race.toxic&&"troll"===t.race.species&&Xc("godwin"),!0)}},observatory:{id:"tech-observatory",title:F("tech_observatory"),desc:F("tech_observatory"),category:"science",era:"early_space",reqs:{science:8,space:3,luna:1},grant:["science",9],cost:{Knowledge:()=>148e3},effect:F("tech_observatory_effect"),action(){return!!Os($(this)[0])&&(t.space.observatory={count:0,on:0},!0)}},world_collider:{id:"tech-world_collider",title:F("tech_world_collider"),desc:F("tech_world_collider"),category:"science",era:"deep_space",path:["standard"],reqs:{science:9,elerium:2},grant:["science",10],cost:{Knowledge:()=>35e4},effect:()=>F("tech_world_collider_effect",[Xt().dwarf]),action(){return!!Os($(this)[0])&&(t.space.world_collider={count:0},t.space.world_controller={count:0,on:0},!0)},flair:`
          ${F("tech_world_collider_flair1")}
          ${F("tech_world_collider_flair2")}
          `},laboratory:{id:"tech-laboratory",title:()=>"magic"===t.race.universe?F("tech_sanctum"):F("tech_laboratory"),desc:()=>"magic"===t.race.universe?F("tech_sanctum"):F("tech_laboratory_desc"),category:"science",era:"interstellar",reqs:{science:11,alpha:2},grant:["science",12],cost:{Knowledge:()=>5e5},effect:()=>"magic"===t.race.universe?F("tech_sanctum_effect"):F("tech_laboratory_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.laboratory={count:0,on:0},!0)},flair:()=>"magic"===t.race.universe?F("tech_sanctum_flair"):F("tech_laboratory_flair")},virtual_assistant:{id:"tech-virtual_assistant",title:F("tech_virtual_assistant"),desc:F("tech_virtual_assistant"),category:"science",era:"interstellar",reqs:{science:12,high_tech:12},grant:["science",13],cost:{Knowledge:()=>635e3},effect:()=>"magic"===t.race.universe?F("tech_virtual_assistant_magic_effect"):F("tech_virtual_assistant_effect"),action(){return!!Os($(this)[0])}},dimensional_readings:{id:"tech-dimensional_readings",title:F("tech_dimensional_readings"),desc:F("tech_dimensional_readings"),category:"science",era:"interstellar",reqs:{science:13,infernite:2},grant:["science",14],cost:{Knowledge:()=>75e4},effect:()=>F("tech_dimensional_readings_effect"),action(){return!!Os($(this)[0])}},quantum_entanglement:{id:"tech-quantum_entanglement",title:F("tech_quantum_entanglement"),desc:F("tech_quantum_entanglement"),category:"science",era:"interstellar",reqs:{science:14,neutron:1},grant:["science",15],cost:{Knowledge:()=>85e4,Neutronium:()=>7500,Soul_Gem:()=>2},effect:()=>F("tech_quantum_entanglement_effect",[2,"magic"===t.race.universe?F("tech_sanctum"):F("interstellar_laboratory_title"),Ts()]),action(){return!!Os($(this)[0])}},expedition:{id:"tech-expedition",title:()=>"magic"===t.race.universe?F("tech_expedition_wiz"):F("tech_expedition"),desc:()=>"magic"===t.race.universe?F("tech_expedition_wiz"):F("tech_expedition"),category:"science",era:"intergalactic",reqs:{science:15,xeno:4},grant:["science",16],cost:{Knowledge:()=>535e4},effect:()=>"magic"===t.race.universe?F("tech_expedition_wiz_effect"):F("tech_expedition_effect"),action(){return!!Os($(this)[0])}},subspace_sensors:{id:"tech-subspace_sensors",title:F("tech_subspace_sensors"),desc:F("tech_subspace_sensors"),category:"science",era:"intergalactic",reqs:{science:16,high_tech:16},grant:["science",17],cost:{Knowledge:()=>6e6},effect:()=>F("tech_subspace_sensors_effect"),action(){return!!Os($(this)[0])}},alien_database:{id:"tech-alien_database",title:F("tech_alien_database"),desc:F("tech_alien_database"),category:"progress",era:"intergalactic",reqs:{science:17,conflict:5},grant:["science",18],cost:{Knowledge:()=>825e4},effect:()=>F("tech_alien_database_effect"),action(){return!!Os($(this)[0])}},orichalcum_capacitor:{id:"tech-orichalcum_capacitor",title:F("tech_orichalcum_capacitor"),desc:F("tech_orichalcum_capacitor"),category:"science",era:"intergalactic",reqs:{science:18,high_tech:17},grant:["science",19],cost:{Knowledge:()=>125e5,Orichalcum:()=>25e4},effect:()=>F("tech_orichalcum_capacitor_effect"),action(){return!!Os($(this)[0])}},advanced_biotech:{id:"tech-advanced_biotech",title:F("tech_advanced_biotech"),desc:F("tech_advanced_biotech"),category:"science",era:"dimensional",reqs:{science:19,high_tech:18},grant:["science",20],cost:{Knowledge:()=>255e5},effect:()=>F("tech_advanced_biotech_effect"),action(){return!!Os($(this)[0])}},codex_infinium:{id:"tech-codex_infinium",title:F("tech_codex_infinium"),desc:F("tech_codex_infinium"),category:"science",era:"dimensional",reqs:{science:20,sphinx_bribe:1},grant:["science",21],cost:{Knowledge:()=>401e5,Codex:()=>1},effect:()=>F("tech_codex_infinium_effect"),action(){return!!Os($(this)[0])&&(t.resource.Codex.display=!1,!0)}},bioscience:{id:"tech-bioscience",title:F("tech_bioscience"),desc:F("tech_bioscience_desc"),category:"science",era:"globalized",reqs:{science:8},grant:["genetics",1],cost:{Knowledge:()=>67500},effect:F("tech_bioscience_effect"),action(){return!!Os($(this)[0])&&(t.city.biolab={count:0},!0)}},genetics:{id:"tech-genetics",title:F("tech_genetics"),desc:F("tech_genetics"),category:"arpa",era:"globalized",reqs:{genetics:1,high_tech:6},grant:["genetics",2],cost:{Knowledge:()=>108e3},effect:F("tech_genetics_effect"),action(){return!!Os($(this)[0])&&(t.settings.arpa.genetics=!0,t.arpa.sequence||(t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!t.race.cataclysm&&!t.race.orbit_decayed,boost:!1,auto:!1,labs:0}),!0)},post(){Oe("Genetics")}},crispr:{id:"tech-crispr",title:F("tech_crispr"),desc:F("tech_crispr"),category:"genes",era:"globalized",reqs:{genetics:3},grant:["genetics",4],cost:{Knowledge:()=>125e3},effect:()=>t.race.artifical?F("tech_crispr_effect_artifical"):F("tech_crispr_effect"),action(){return!!Os($(this)[0])&&(t.settings.arpa.crispr=!0,t.settings.arpa.arpaTabs=2,!0)},post(){Oe("Genetics"),Oe("Crispr")}},shotgun_sequencing:{id:"tech-shotgun_sequencing",title:F("tech_shotgun_sequencing"),desc:()=>t.race.artifical?F("tech_shotgun_sequencing_desc_artifical"):F("tech_shotgun_sequencing_desc"),category:"genes",era:"early_space",reqs:{genetics:4},grant:["genetics",5],cost:{Knowledge:()=>165e3},effect:()=>t.race.artifical?F("tech_shotgun_sequencing_effect_artifical"):F("tech_shotgun_sequencing_effect"),action(){return!!Os($(this)[0])&&(t.arpa.sequence.boost=!0,!0)},post(){Oe("Genetics")}},de_novo_sequencing:{id:"tech-de_novo_sequencing",title:F("tech_de_novo_sequencing"),desc:F("tech_de_novo_sequencing"),category:"genes",era:"early_space",reqs:{genetics:5},grant:["genetics",6],cost:{Knowledge:()=>22e4},effect:()=>t.race.artifical?F("tech_de_novo_sequencing_effect_artifical"):F("tech_de_novo_sequencing_effect"),action(){return!!Os($(this)[0])&&(t.resource.Genes.display=!0,!0)},post(){Oe("Genetics")}},dna_sequencer:{id:"tech-dna_sequencer",title:()=>t.race.artifical?F("tech_code_sequencer"):F("tech_dna_sequencer"),desc:()=>t.race.artifical?F("tech_code_sequencer"):F("tech_dna_sequencer"),category:"genes",era:"deep_space",reqs:{genetics:6},grant:["genetics",7],cost:{Knowledge:()=>3e5},effect:()=>t.race.artifical?F("tech_code_sequencer_effect"):F("tech_dna_sequencer_effect"),action(){return!!Os($(this)[0])&&(t.arpa.sequence.auto=!0,!0)},post(){Oe("Genetics")}},rapid_sequencing:{id:"tech-rapid_sequencing",title:()=>t.race.artifical?F("tech_agile_development"):F("tech_rapid_sequencing"),desc:()=>t.race.artifical?F("tech_agile_development"):F("tech_rapid_sequencing"),category:"genes",era:"interstellar",path:["standard","truepath"],reqs:{genetics:7,high_tech:12},grant:["genetics",8],cost:{Knowledge:()=>8e5},effect:()=>t.race.artifical?F("tech_agile_development_effect"):F("tech_rapid_sequencing_effect"),action(){return!!Os($(this)[0])}},mad_science:{id:"tech-mad_science",title:()=>"magic"===t.race.universe?F("tech_sages"):F("tech_mad_science"),desc:()=>"magic"===t.race.universe?F("tech_sages"):F("tech_mad_science"),category:"science",era:"discovery",reqs:{science:2,smelting:2},grant:["high_tech",1],cost:{Money:()=>1e4,Mana:()=>"magic"===t.race.universe?50:0,Knowledge:()=>6750,Crystal:()=>"magic"===t.race.universe?1e3:0,Aluminium:()=>750},effect:()=>"magic"===t.race.universe?F("tech_sages_effect"):F("tech_mad_science_effect"),action(){return!!Os($(this)[0])&&(t.race.terrifying&&(t.civic.taxes.display=!0),t.city.wardenclyffe={count:0,on:0},!0)}},electricity:{id:"tech-electricity",title:F("tech_electricity"),desc:F("tech_electricity"),category:"power_generation",era:"discovery",reqs:{high_tech:1},grant:["high_tech",2],cost:{Knowledge:()=>13500,Copper:()=>1e3},effect:F("tech_electricity_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_electricity_msg"),"info",!1,["progress"]),t.city.power=0,t.city.powered=!0,t.city.coal_power={count:0,on:0},t.settings.showPowerGrid=!0,ti(),!0)}},matter_replicator:{id:"tech-matter_replicator",title:()=>"antimatter"!==t.race.universe||t.race.amexplode?F("tech_replicator"):F("tech_antireplicator"),desc:()=>"antimatter"!==t.race.universe||t.race.amexplode?F("tech_replicator"):F("tech_antireplicator"),category:"special",era:"discovery",reqs:{high_tech:2},condition:()=>!!(t.stats.achieve.adam_eve&&t.stats.achieve.adam_eve.l>=5),not_trait:["lone_survivor"],grant:["replicator",1],cost:{Knowledge:()=>25e3},effect:()=>"antimatter"!==t.race.universe||t.race.amexplode?F("tech_replicator_effect_alt"):F("tech_antireplicator_effect_alt"),action(){if(Os($(this)[0])){if("antimatter"===t.race.universe&&t.race.amexplode){eo("annihilation"),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),$("body").addClass("nuke");let a=$('
          ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),500),setTimeout((function(){a.addClass("b")}),600),setTimeout((function(){window.soft_reset()}),4e3)}else t.race.replicator={res:"Stone",pow:1};return!0}return!1},post(){K()}},industrialization:{id:"tech-industrialization",title:F("tech_industrialization"),desc:F("tech_industrialization"),category:"progress",era:"industrialized",reqs:{high_tech:2,cement:2,steel_container:1},grant:["high_tech",3],cost:{Knowledge:()=>25200},effect:F("tech_industrialization_effect"),action(){return!!Os($(this)[0])&&(t.resource.Titanium.display=!0,t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:0,Nano:0,Stanene:0},!0)},post(){zi()}},electronics:{id:"tech-electronics",title:F("tech_electronics"),desc:F("tech_electronics"),category:"progress",era:"industrialized",reqs:{high_tech:3,titanium:1},grant:["high_tech",4],cost:{Knowledge:()=>5e4},effect:F("tech_electronics_effect"),action(){return!!Os($(this)[0])&&(t.race.terrifying&&(t.tech.gambling=1,t.city.casino={count:0,on:0},t.space.spc_casino={count:0,on:0}),!0)}},fission:{id:"tech-fission",title:F("tech_fission"),desc:F("tech_fission"),category:"progress",era:"globalized",reqs:{high_tech:4,uranium:1},grant:["high_tech",5],cost:{Knowledge:()=>77400,Uranium:()=>10},effect:F("tech_fission_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_fission_msg"),"info",!1,["progress"]),t.city.fission_power={count:0,on:0},!0)}},arpa:{id:"tech-arpa",title:F("tech_arpa"),desc:F("tech_arpa_desc"),category:"arpa",era:"globalized",reqs:{high_tech:5},grant:["high_tech",6],cost:{Knowledge:()=>9e4},effect:F("tech_arpa_effect"),action(){return!!Os($(this)[0])&&(t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.race.truepath&&!t.tech.unify&&(t.tech.unify=1),!0)},post(){Oe("Physics")}},rocketry:{id:"tech-rocketry",title:F("tech_rocketry"),desc:F("tech_rocketry"),category:"arpa",era:"globalized",reqs:{high_tech:6},grant:["high_tech",7],cost:{Knowledge:()=>112500,Oil:()=>t.city.ptrait.includes("dense")?8e3:6800},effect:F("tech_rocketry_effect"),action(){return!!Os($(this)[0])&&(t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,Di(F("civics_rival_unlocked",[ee(3)]),"info",!1,["progress","combat"])),!0)},post(){Oe("Physics")}},robotics:{id:"tech-robotics",title:F("tech_robotics"),desc:F("tech_robotics"),category:"progress",era:"globalized",reqs:{high_tech:7},grant:["high_tech",8],cost:{Knowledge:()=>125e3},effect:F("tech_robotics_effect"),action(){return!!Os($(this)[0])}},lasers:{id:"tech-lasers",title:F("tech_lasers"),desc:F("tech_lasers_desc"),category:"progress",era:"deep_space",reqs:{high_tech:8,space:3,supercollider:1,elerium:1},grant:["high_tech",9],cost:{Knowledge:()=>28e4,Elerium:()=>100},effect:F("tech_lasers_effect"),action(){return!!Os($(this)[0])&&(t.race.cataclysm&&Xc("iron_will",!1,3),!0)}},artifical_intelligence:{id:"tech-artifical_intelligence",title:F("tech_artificial_intelligence"),desc:F("tech_artificial_intelligence"),category:"progress",era:"deep_space",reqs:{high_tech:9},grant:["high_tech",10],cost:{Knowledge:()=>325e3},effect:F("tech_artificial_intelligence_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_artificial_intelligence_flair")},quantum_computing:{id:"tech-quantum_computing",title:F("tech_quantum_computing"),desc:F("tech_quantum_computing"),category:"progress",era:"deep_space",reqs:{high_tech:10,nano:1},grant:["high_tech",11],cost:{Knowledge:()=>435e3,Elerium:()=>250,Nano_Tube:()=>1e5},effect:F("tech_quantum_computing_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_quantum_computing_flair")},virtual_reality:{id:"tech-virtual_reality",title:F("tech_virtual_reality"),desc:F("tech_virtual_reality"),category:"progress",era:"interstellar",reqs:{high_tech:11,alpha:2,infernite:1,stanene:1},grant:["high_tech",12],cost:{Knowledge:()=>6e5,Stanene:()=>1250,Soul_Gem:()=>1},effect:F("tech_virtual_reality_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_virtual_reality_flair")},plasma:{id:"tech-plasma",title:F("tech_plasma"),desc:F("tech_plasma"),category:"progress",era:"interstellar",path:["standard","truepath"],reqs:{high_tech:12},grant:["high_tech",13],cost:{Knowledge:()=>755e3,Infernite:()=>t.race.truepath?0:1e3,Stanene:()=>t.race.truepath?1e6:25e4},effect:F("tech_plasma_effect"),action(){return!!Os($(this)[0])}},shields:{id:"tech-shields",title:F("tech_shields"),desc:F("tech_shields"),category:"stellar_engine",era:"interstellar",reqs:{high_tech:13},grant:["high_tech",14],cost:{Knowledge:()=>85e4},effect:F("tech_shields_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.neutron=!0,t.settings.space.blackhole=!0,!0)}},ai_core:{id:"tech-ai_core",title:F("tech_ai_core"),desc:F("tech_ai_core"),category:"ai_core",era:"interstellar",reqs:{high_tech:14,science:15,blackhole:3},grant:["high_tech",15],cost:{Knowledge:()=>15e5},effect:F("tech_ai_core_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.citadel={count:0,on:0},!0)}},metaphysics:{id:"tech-metaphysics",title:F("tech_metaphysics"),desc:F("tech_metaphysics"),category:"progress",era:"intergalactic",reqs:{high_tech:15,xeno:5},grant:["high_tech",16],cost:{Knowledge:()=>5e6,Vitreloy:()=>1e4,Soul_Gem:()=>10},effect:()=>F("tech_metaphysics_effect"),action(){return!!Os($(this)[0])}},orichalcum_analysis:{id:"tech-orichalcum_analysis",title:F("tech_orichalcum_analysis"),desc:F("tech_orichalcum_analysis"),category:"progress",era:"intergalactic",reqs:{high_tech:16,chthonian:3},grant:["high_tech",17],cost:{Knowledge:()=>122e5,Orichalcum:()=>1e5},effect:()=>F("tech_orichalcum_analysis_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_orichalcum_analysis_result"),"info",!1,["progress"]),!0)}},cybernetics:{id:"tech-cybernetics",title:F("tech_cybernetics"),desc:F("tech_cybernetics"),category:"progress",era:"dimensional",reqs:{high_tech:17,hell_ruins:4},grant:["high_tech",18],cost:{Knowledge:()=>25e6,Adamantite:()=>125e5,Stanene:()=>5e7,Vitreloy:()=>1e7},effect:()=>F("tech_cybernetics_effect"),action(){return!!Os($(this)[0])}},blood_pact:{id:"tech-blood_pact",title:F("tech_blood_pact"),desc:F("tech_blood_pact"),category:"hell_dimension",era:"dimensional",reqs:{high_tech:18,b_stone:1},grant:["b_stone",2],cost:{Knowledge:()=>52e6,Blood_Stone:()=>1},effect:()=>F("tech_blood_pact_effect"),action(){return!!Os($(this)[0])&&(t.settings.arpa.blood=!0,Oe("Crispr"),!0)},post(){Oe("Blood")}},purify:{id:"tech-purify",title:F("tech_purify"),desc:F("tech_purify"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:3,b_stone:2},grant:["b_stone",3],cost:{Knowledge:()=>525e5,Blood_Stone:()=>1},effect:()=>F("tech_purify_effect"),action(){return!!Os($(this)[0])}},waygate:{id:"tech-waygate",title:F("tech_waygate"),desc:F("tech_waygate"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:10,b_stone:2},grant:["waygate",1],cost:{Knowledge:()=>55e6},effect:()=>F("tech_waygate_effect"),action(){return!!Os($(this)[0])&&(t.portal.waygate={count:0,progress:0,on:0},!0)}},demonic_infusion:{id:"tech-demonic_infusion",title:F("tech_demonic_infusion"),desc:F("tech_demonic_infusion"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:10,b_stone:2,waygate:3},grant:["waygate",4],not_trait:["witch_hunter"],cost:{Species:()=>fc(1e3),Knowledge:()=>55e6,Demonic_Essence:()=>1},effect:()=>`
          ${F("tech_demonic_infusion_effect")}
          ${F("tech_demonic_infusion_effect2",[mc("descend").artifact])}
          `,action(){return t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),Os($(this)[0])&&W(),!1}},gate_key:{id:"tech-gate_key",title:F("tech_gate_key"),desc:F("tech_gate_key"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:1},grant:["hell_gate",2],cost:{Knowledge:()=>3e7},effect:()=>F("tech_gate_key_effect"),action(){return!!Os($(this)[0])&&(t.portal.west_tower={count:0,on:0},t.portal.east_tower={count:0,on:0},!0)}},gate_turret:{id:"tech-gate_turret",title:F("tech_gate_turret"),desc:F("tech_gate_turret"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:2},grant:["hell_gate",3],cost:{Knowledge:()=>32e6},effect:()=>F("tech_gate_turret_effect"),action(){return!!Os($(this)[0])&&(t.portal.gate_turret={count:0,on:0},!0)}},infernite_mine:{id:"tech-infernite_mine",title:F("tech_infernite_mine"),desc:F("tech_infernite_mine"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:3},grant:["hell_gate",4],cost:{Knowledge:()=>325e5},effect:()=>F("tech_infernite_mine_effect"),action(){return!!Os($(this)[0])&&(t.portal.infernite_mine={count:0,on:0},!0)}},study_corrupt_gem:{id:"tech-study_corrupt_gem",title:F("tech_study_corrupt_gem"),desc:F("tech_study_corrupt_gem"),category:"hell_dimension",era:"intergalactic",reqs:{high_tech:16,corrupt:1},grant:["corrupt",2],trait:["witch_hunter"],cost:{Mana:()=>t.race.no_plasmid?1e4:5e4,Knowledge:()=>185e5,Corrupt_Gem:()=>1},effect:()=>F("tech_study_corrupt_gem_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_study_corrupt_gem_result"),"info",!1,["progress","hell"]),t.resource.Corrupt_Gem.display=!1,!0)}},soul_binding:{id:"tech-soul_binding",title:F("tech_soul_binding"),desc:F("tech_soul_binding"),category:"hell_dimension",era:"intergalactic",reqs:{corrupt:2,science:19},grant:["forbidden",1],trait:["witch_hunter"],cost:{Knowledge:()=>19e6},effect:()=>F("tech_soul_binding_effect"),action(){return!!Os($(this)[0])}},soul_capacitor:{id:"tech-soul_capacitor",title:F("tech_soul_capacitor"),desc:F("tech_soul_capacitor"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:1},grant:["forbidden",2],trait:["witch_hunter"],cost:{Knowledge:()=>195e5},effect:()=>F("tech_soul_capacitor_effect"),action(){return!!Os($(this)[0])&&(t.portal.soul_capacitor={count:0,on:0,energy:0,ecap:0},!0)}},soul_capacitor:{id:"tech-soul_capacitor",title:F("tech_soul_capacitor"),desc:F("tech_soul_capacitor"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:1},grant:["forbidden",2],trait:["witch_hunter"],cost:{Knowledge:()=>195e5},effect:()=>F("tech_soul_capacitor_effect"),action(){return!!Os($(this)[0])&&(t.portal.soul_capacitor={count:0,on:0,energy:0,ecap:0},!0)}},absorption_chamber:{id:"tech-absorption_chamber",title:F("tech_absorption_chamber"),desc:F("tech_absorption_chamber"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:2},grant:["forbidden",3],trait:["witch_hunter"],cost:{Knowledge:()=>2e7},effect:()=>F("tech_absorption_chamber_effect"),action(){return!!Os($(this)[0])&&(t.portal.absorption_chamber={count:0},!0)}},corrupt_gem_analysis:{id:"tech-corrupt_gem_analysis",title:F("tech_corrupt_gem_analysis"),desc:F("tech_corrupt_gem_analysis"),category:"hell_dimension",era:"dimensional",reqs:{high_tech:16,corrupt:1},grant:["corrupt",2],not_trait:["witch_hunter"],cost:{Species:()=>1,Knowledge:()=>22e6,Corrupt_Gem:()=>1},effect:()=>F("tech_corrupt_gem_analysis_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_corrupt_gem_analysis_result"),"info",!1,["progress","hell"]),t.resource.Corrupt_Gem.display=!1,!0)}},hell_search:{id:"tech-hell_search",title:F("tech_hell_search"),desc:F("tech_hell_search"),category:"hell_dimension",era:"dimensional",reqs:{corrupt:2},grant:["hell_ruins",1],cost:{Knowledge:()=>221e5,Structs:()=>({portal:{sensor_drone:{s:"prtl_badlands",count:25,on:25}}})},effect:()=>F("tech_hell_search_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_hell_search_result"),"info",!1,["progress","hell"]),t.settings.portal.ruins=!0,t.settings.portal.gate=!0,t.portal.guard_post={count:0,on:0,support:0,s_max:0},!0)}},codex_infernium:{id:"tech-codex_infernium",title:F("tech_codex_infernium"),desc:F("tech_codex_infernium"),category:"progress",era:"dimensional",reqs:{hell_ruins:3},grant:["hell_ruins",4],cost:{Knowledge:()=>235e5,Codex:()=>1},effect:()=>F("tech_codex_infernium_effect"),action(){return!!Os($(this)[0])&&(t.resource.Codex.display=!1,!0)}},lake_analysis:{id:"tech-lake_analysis",title:F("tech_lake_analysis"),desc:F("tech_lake_analysis"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:2},grant:["hell_lake",3],cost:{Knowledge:()=>34e6},effect:()=>F("tech_lake_analysis_effect"),action(){return!!Os($(this)[0])}},lake_threat:{id:"tech-lake_threat",title:F("tech_lake_threat"),desc:F("tech_lake_threat"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:3},grant:["hell_lake",4],cost:{Knowledge:()=>345e5},effect:()=>F("tech_lake_threat_effect"),action(){return!!Os($(this)[0])&&(t.portal.bireme={count:0,on:0,crew:0,mil:0},Di(F("tech_lake_threat_result"),"info",!1,["progress","hell"]),!0)}},lake_transport:{id:"tech-lake_transport",title:F("tech_lake_transport"),desc:F("tech_lake_transport"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:4},grant:["hell_lake",5],cost:{Knowledge:()=>35e6},effect:()=>F("tech_lake_transport_effect"),action(){return!!Os($(this)[0])&&(t.portal.transport={count:0,on:0,crew:0,mil:0,cargo:{used:0,max:0,Crystal:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0}},!0)}},cooling_tower:{id:"tech-cooling_tower",title:F("tech_cooling_tower"),desc:F("tech_cooling_tower"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:5},grant:["hell_lake",6],cost:{Knowledge:()=>375e5},effect:()=>F("tech_cooling_tower_effect"),action(){return!!Os($(this)[0])&&(t.portal.cooling_tower={count:0,on:0},!0)}},miasma:{id:"tech-miasma",title:F("tech_miasma"),desc:F("tech_miasma"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:2},grant:["hell_spire",3],cost:{Knowledge:()=>3825e4},effect:()=>F("tech_miasma_effect"),action(){return!!Os($(this)[0])&&(t.portal.port={count:0},!0)}},incorporeal:{id:"tech-incorporeal",title:F("tech_incorporeal"),desc:F("tech_incorporeal"),category:"special",era:"intergalactic",reqs:{science:19},grant:["ascension",1],not_trait:["orbit_decay","witch_hunter"],cost:{Knowledge:()=>175e5,Phage:()=>25},effect:()=>F("tech_incorporeal_effect"),action(){return!!Os($(this)[0])}},tech_ascension:{id:"tech-tech_ascension",title:F("tech_ascension"),desc:F("tech_ascension"),category:"special",era:"intergalactic",reqs:{ascension:1},grant:["ascension",2],not_trait:["orbit_decay","witch_hunter"],cost:{Knowledge:()=>185e5,Plasmid:()=>100},effect:()=>F("tech_ascension_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.sirius=!0,!0)}},terraforming:{id:"tech-terraforming",title:F("tech_terraforming"),desc:F("tech_terraforming"),category:"special",era:"intergalactic",reqs:{science:19},path:["standard"],grant:["terraforming",1],trait:["orbit_decay"],cost:{Knowledge:()=>18e6},effect:()=>F("tech_terraforming_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.terraformer={count:0},!0)}},cement_processing:{id:"tech-cement_processing",title:F("tech_cement_processing"),desc:F("tech_cement_processing"),category:"ai_core",era:"interstellar",reqs:{high_tech:15},not_trait:["flier"],grant:["ai_core",1],cost:{Knowledge:()=>175e4},effect:F("tech_cement_processing_effect"),action(){return!!Os($(this)[0])}},adamantite_processing_flier:{id:"tech-adamantite_processing_flier",title:F("tech_adamantite_processing"),desc:F("tech_adamantite_processing"),category:"ai_core",era:"interstellar",reqs:{high_tech:15},trait:["flier"],grant:["ai_core",2],cost:{Knowledge:()=>2e6},effect:F("tech_adamantite_processing_effect"),action(){return!!Os($(this)[0])}},adamantite_processing:{id:"tech-adamantite_processing",title:F("tech_adamantite_processing"),desc:F("tech_adamantite_processing"),category:"ai_core",era:"interstellar",reqs:{ai_core:1},not_trait:["flier"],grant:["ai_core",2],cost:{Knowledge:()=>2e6},effect:F("tech_adamantite_processing_effect"),action(){return!!Os($(this)[0])}},graphene_processing:{id:"tech-graphene_processing",title:F("tech_graphene_processing"),desc:F("tech_graphene_processing"),category:"ai_core",era:"intergalactic",reqs:{ai_core:2},grant:["ai_core",3],cost:{Knowledge:()=>25e5},effect:F("tech_graphene_processing_effect"),action(){return!!Os($(this)[0])}},fusion_power:{id:"tech-fusion_power",title:F("tech_fusion_power"),desc:F("tech_fusion_power"),category:"power_generation",era:"interstellar",reqs:{ram_scoop:1},grant:["fusion",1],cost:{Knowledge:()=>64e4},effect:F("tech_fusion_power_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.fusion={count:0,on:0},!0)}},infernium_power:{id:"tech-infernium_power",title:F("tech_infernium_power"),desc:F("tech_infernium_power"),category:"power_generation",era:"dimensional",reqs:{smelting:8,hell_ruins:4},grant:["inferno_power",1],cost:{Knowledge:()=>3e7},effect:F("tech_infernium_power_effect"),action(){return!!Os($(this)[0])&&(t.portal.inferno_power={count:0,on:0},!0)}},thermomechanics:{id:"tech-thermomechanics",title:F("tech_thermomechanics"),desc:F("tech_thermomechanics_desc"),category:"crafting",era:"industrialized",reqs:{high_tech:4},grant:["alloy",1],cost:{Knowledge:()=>6e4},effect:()=>F("tech_thermomechanics_effect"),action(){return!!Os($(this)[0])}},quantum_manufacturing:{id:"tech-quantum_manufacturing",title:F("tech_quantum_manufacturing"),desc:F("tech_quantum_manufacturing"),category:"crafting",era:"deep_space",reqs:{high_tech:11},grant:["q_factory",1],cost:{Knowledge:()=>465e3},effect:F("tech_quantum_manufacturing_effect"),action(){return!!Os($(this)[0])}},worker_drone:{id:"tech-worker_drone",title:F("tech_worker_drone"),desc:F("tech_worker_drone"),category:"mining",era:"deep_space",reqs:{nano:1},grant:["drone",1],cost:{Knowledge:()=>4e5},effect:()=>F("tech_worker_drone_effect",[Xt().gas_moon]),action(){return!!Os($(this)[0])&&(t.space.drone={count:0},!0)}},uranium:{id:"tech-uranium",title:F("tech_uranium"),desc:F("tech_uranium"),category:"power_generation",era:"globalized",reqs:{high_tech:4},grant:["uranium",1],cost:{Knowledge:()=>72e3},effect:F("tech_uranium_effect"),action(){return!!Os($(this)[0])&&(t.resource.Uranium.display=!0,!0)},post(){zi()}},uranium_storage:{id:"tech-uranium_storage",title:F("tech_uranium_storage"),desc:F("tech_uranium_storage"),category:"storage",era:"globalized",reqs:{uranium:1},grant:["uranium",2],cost:{Knowledge:()=>75600,Alloy:()=>2500},effect:F("tech_uranium_storage_effect"),action(){return!!Os($(this)[0])}},uranium_ash:{id:"tech-uranium_ash",title:F("tech_uranium_ash"),desc:F("tech_uranium_ash"),category:"power_generation",era:"globalized",reqs:{uranium:2},grant:["uranium",3],cost:{Knowledge:()=>122e3},effect:F("tech_uranium_ash_effect"),action(){return!!Os($(this)[0])}},breeder_reactor:{id:"tech-breeder_reactor",title:F("tech_breeder_reactor"),desc:F("tech_breeder_reactor"),category:"power_generation",era:"early_space",reqs:{high_tech:5,uranium:3,space:3},grant:["uranium",4],cost:{Knowledge:()=>16e4,Uranium:()=>250,Iridium:()=>1e3},effect:F("tech_breeder_reactor_effect"),action(){return!!Os($(this)[0])}},mine_conveyor:{id:"tech-mine_conveyor",title:F("tech_mine_conveyor"),desc:F("tech_mine_conveyor"),category:"mining",era:"discovery",reqs:{high_tech:2},grant:["mine_conveyor",1],cost:{Knowledge:()=>16200,Copper:()=>2250,Steel:()=>1750},effect:F("tech_mine_conveyor_effect"),action(){return!!Os($(this)[0])}},oil_well:{id:"tech-oil_well",title:F("tech_oil_well"),desc:F("tech_oil_well"),category:"power_generation",era:"industrialized",reqs:{high_tech:3},grant:["oil",1],cost:{Knowledge:()=>27e3},effect:F("tech_oil_well_effect"),action(){return!!Os($(this)[0])&&(t.city.oil_well={count:0},!0)}},oil_depot:{id:"tech-oil_depot",title:F("tech_oil_depot"),desc:F("tech_oil_depot"),category:"storage",era:"industrialized",reqs:{oil:1},grant:["oil",2],cost:{Knowledge:()=>32e3},effect:F("tech_oil_depot_effect"),action(){return!!Os($(this)[0])&&(t.city.oil_depot={count:0},!0)}},oil_power:{id:"tech-oil_power",title:()=>t.race.environmentalist?F("city_wind_power"):F("tech_oil_power"),desc:()=>t.race.environmentalist?F("city_wind_power"):F("tech_oil_power"),category:"power_generation",era:"industrialized",reqs:{oil:2},grant:["oil",3],cost:{Knowledge:()=>44e3},effect:()=>t.race.environmentalist?F("tech_wind_power_effect"):F("tech_oil_power_effect"),action(){return!!Os($(this)[0])&&(t.city.oil_power={count:0,on:0},!0)}},titanium_drills:{id:"tech-titanium_drills",title:F("tech_titanium_drills"),desc:F("tech_titanium_drills"),category:"power_generation",era:"industrialized",reqs:{oil:3},grant:["oil",4],cost:{Knowledge:()=>54e3,Titanium:()=>3500},effect:F("tech_titanium_drills_effect"),action(){return!!Os($(this)[0])}},alloy_drills:{id:"tech-alloy_drills",title:F("tech_alloy_drills"),desc:F("tech_alloy_drills"),category:"power_generation",era:"globalized",reqs:{oil:4},grant:["oil",5],cost:{Knowledge:()=>77e3,Alloy:()=>1e3},effect:F("tech_alloy_drills_effect"),action(){return!!Os($(this)[0])}},fracking:{id:"tech-fracking",title:F("tech_fracking"),desc:F("tech_fracking"),category:"power_generation",era:"globalized",reqs:{oil:5,high_tech:6},grant:["oil",6],cost:{Knowledge:()=>132e3},effect:F("tech_fracking_effect"),action(){return!!Os($(this)[0])}},mythril_drills:{id:"tech-mythril_drills",title:F("tech_mythril_drills"),desc:F("tech_mythril_drills"),category:"power_generation",era:"early_space",reqs:{oil:6,space:3},grant:["oil",7],cost:{Knowledge:()=>165e3,Mythril:()=>100},effect:F("tech_mythril_drills_effect"),action(){return!!Os($(this)[0])}},mass_driver:{id:"tech-mass_driver",title:F("tech_mass_driver"),desc:F("tech_mass_driver"),category:"power_generation",era:"early_space",reqs:{oil:6,space:3},grant:["mass",1],cost:{Knowledge:()=>16e4},effect:F("tech_mass_driver_effect"),action(){return!!Os($(this)[0])&&(t.city.mass_driver={count:0,on:0},!0)}},orichalcum_driver:{id:"tech-orichalcum_driver",title:F("tech_orichalcum_driver"),desc:F("tech_orichalcum_driver"),category:"science",era:"intergalactic",reqs:{mass:1,science:19},grant:["mass",2],not_trait:["orbit_decayed"],cost:{Knowledge:()=>14e6,Orichalcum:()=>4e5},effect:()=>F("tech_orichalcum_driver_effect"),action(){return!!Os($(this)[0])&&(t.space.terraformer={count:0},!0)}},polymer:{id:"tech-polymer",title:F("tech_polymer"),desc:F("tech_polymer"),category:"crafting",era:"globalized",reqs:{genetics:1},grant:["polymer",1],cost:{Knowledge:()=>8e4,Oil:()=>5e3,Alloy:()=>450},effect:F("tech_polymer_effect"),action(){return!!Os($(this)[0])&&(t.resource.Polymer.display=!0,Di(F("tech_polymer_avail"),"info",!1,["progress"]),!0)},post(){Ws(),zi()}},fluidized_bed_reactor:{id:"tech-fluidized_bed_reactor",title:F("tech_fluidized_bed_reactor"),desc:F("tech_fluidized_bed_reactor"),category:"crafting",era:"globalized",reqs:{polymer:1,high_tech:6},grant:["polymer",2],cost:{Knowledge:()=>99e3},effect:F("tech_fluidized_bed_reactor_effect"),action(){return!!Os($(this)[0])}},synthetic_fur:{id:"tech-synthetic_fur",title:()=>t.race.evil?F("tech_faux_leather"):F("tech_synthetic_fur"),desc:()=>t.race.evil?F("tech_faux_leather"):F("tech_synthetic_fur"),category:"crafting",era:"globalized",reqs:{polymer:1},grant:["synthetic_fur",1],cost:{Knowledge:()=>1e5,Polymer:()=>2500},effect:()=>t.race.evil?F("tech_faux_leather_effect"):F("tech_synthetic_fur_effect"),action(){return!!Os($(this)[0])},post(){Ws()}},nanoweave:{id:"tech-nanoweave",title:F("tech_nanoweave"),desc:F("tech_nanoweave"),category:"crafting",era:"intergalactic",reqs:{science:18},grant:["nanoweave",1],cost:{Knowledge:()=>85e5,Nano_Tube:()=>5e6,Vitreloy:()=>25e4},effect:F("tech_nanoweave_effect"),action(){return!!Os($(this)[0])&&(t.resource.Nanoweave.display=!0,Di(F("tech_nanoweave_avail"),"info",!1,["progress"]),ha(),!0)},post(){zi()}},stanene:{id:"tech-stanene",title:F("tech_stanene"),desc:F("tech_stanene"),category:"crafting",era:"interstellar",reqs:{infernite:1},grant:["stanene",1],cost:{Knowledge:()=>59e4,Aluminium:()=>5e5,Infernite:()=>1e3},effect:F("tech_stanene_effect"),action(){return!!Os($(this)[0])&&(t.resource.Stanene.display=!0,Di(F("tech_stanene_avail"),"info",!1,["progress"]),!0)},post(){Ws(),zi()}},nano_tubes:{id:"tech-nano_tubes",title:F("tech_nano_tubes"),desc:F("tech_nano_tubes"),category:"crafting",era:"deep_space",reqs:{high_tech:10},grant:["nano",1],cost:{Knowledge:()=>375e3,Coal:()=>1e5,Neutronium:()=>1e3},effect:F("tech_nano_tubes_effect"),action(){return!!Os($(this)[0])&&(t.resource.Nano_Tube.display=!0,Di(F("tech_nano_tubes_msg"),"info",!1,["progress"]),!0)},post(){Ws(),zi()}},scarletite:{id:"tech-scarletite",title:F("tech_scarletite"),desc:F("tech_scarletite"),category:"crafting",era:"dimensional",reqs:{hell_ruins:4},grant:["scarletite",1],cost:{Knowledge:()=>2675e4,Iron:()=>1e8,Adamantite:()=>15e6,Orichalcum:()=>8e6},effect:F("tech_scarletite_effect"),action(){if(Os($(this)[0])){if(t.resource.Scarletite.display=!0,t.portal.hell_forge={count:0,on:0},Di(F("tech_scarletite_avail"),"info",!1,["progress"]),ha(),"micro"===t.race.universe||t.pillars[t.race.species]){let e=ro();e>t.pillars[t.race.species]&&(t.pillars[t.race.species]=e),t.tech.pillars=2}else t.tech.fusable=1;return!0}return!1},post(){zi()}},pillars:{id:"tech-pillars",title:F("tech_pillars"),desc:F("tech_pillars"),category:"hell_dimension",era:"dimensional",reqs:{scarletite:1,fusable:1},grant:["pillars",1],cost:{Knowledge:()=>3e7},effect:F("tech_pillars_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_pillars_msg",[di[t.race.species].entity]),"info",!1,["progress","hell"]),!0)}},reclaimer:{id:"tech-reclaimer",title:F("tech_reclaimer"),desc:F("tech_reclaimer_desc"),category:"reclaimer",era:"civilized",reqs:{primitive:3},grant:["reclaimer",1],trait:["evil"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>45,Lumber:()=>20,Stone:()=>20},effect:F("tech_reclaimer_effect"),action(){return!!Os($(this)[0])&&(t.civic.lumberjack.name=F("job_reclaimer"),t.civic.lumberjack.display=!0,t.city.graveyard={count:0},!0)}},shovel:{id:"tech-shovel",title:F("tech_shovel"),desc:F("tech_shovel"),category:"reclaimer",era:"civilized",reqs:{reclaimer:1,mining:2},grant:["reclaimer",2],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>540,Copper:()=>25},effect:F("tech_shovel_effect"),action(){return!!Os($(this)[0])}},iron_shovel:{id:"tech-iron_shovel",title:F("tech_iron_shovel"),desc:F("tech_iron_shovel"),category:"reclaimer",era:"civilized",reqs:{reclaimer:2,mining:3},grant:["reclaimer",3],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>2700,Iron:()=>250},effect:F("tech_iron_shovel_effect"),action(){return!!Os($(this)[0])}},steel_shovel:{id:"tech-steel_shovel",title:F("tech_steel_shovel"),desc:F("tech_steel_shovel"),category:"reclaimer",era:"discovery",reqs:{reclaimer:3,smelting:2},grant:["reclaimer",4],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>9e3,Steel:()=>250},effect:F("tech_steel_shovel_effect"),action(){return!!Os($(this)[0])}},titanium_shovel:{id:"tech-titanium_shovel",title:F("tech_titanium_shovel"),desc:F("tech_titanium_shovel"),category:"reclaimer",era:"industrialized",reqs:{reclaimer:4,high_tech:3},grant:["reclaimer",5],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>38e3,Titanium:()=>350},effect:F("tech_titanium_shovel_effect"),action(){return!!Os($(this)[0])}},alloy_shovel:{id:"tech-alloy_shovel",title:F("tech_alloy_shovel"),desc:F("tech_alloy_shovel"),category:"reclaimer",era:"globalized",reqs:{reclaimer:5,high_tech:4},grant:["reclaimer",6],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>67500,Alloy:()=>750},effect:F("tech_alloy_shovel_effect"),action(){return!!Os($(this)[0])}},mythril_shovel:{id:"tech-mythril_shovel",title:F("tech_mythril_shovel"),desc:F("tech_mythril_shovel"),category:"reclaimer",era:"early_space",reqs:{reclaimer:6,space:3},grant:["reclaimer",7],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>16e4,Mythril:()=>880},effect:F("tech_mythril_shovel_effect"),action(){return!!Os($(this)[0])}},adamantite_shovel:{id:"tech-adamantite_shovel",title:F("tech_adamantite_shovel"),desc:F("tech_adamantite_shovel"),category:"reclaimer",era:"interstellar",reqs:{reclaimer:7,alpha:2},grant:["reclaimer",8],trait:["evil"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>525e3,Adamantite:()=>1e4},effect:F("tech_adamantite_shovel_effect"),action(){return!!Os($(this)[0])}},stone_axe:{id:"tech-stone_axe",title:()=>F("tech_stone_axe"),desc:()=>F("tech_stone_axe_desc"),category:"lumber_gathering",reqs:{primitive:3},era:"civilized",grant:["axe",1],not_trait:["kindling_kindred","smoldering","evil","cataclysm"],cost:{Knowledge:()=>45,Lumber:()=>20,Stone:()=>20},effect:()=>t.race.living_tool?F("tech_basic_livingtools"):t.race.sappy?F("tech_amber_axe_effect"):F("tech_stone_axe_effect"),action(){return!!Os($(this)[0])&&(t.civic.lumberjack.display=!0,t.city.lumber_yard={count:0},!0)}},copper_axes:{id:"tech-copper_axes",title:F("tech_copper_axes"),desc:F("tech_copper_axes_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:1,mining:2},not_trait:["living_tool"],grant:["axe",2],cost:{Knowledge:()=>540,Copper:()=>25},effect:F("tech_copper_axes_effect"),action(){return!!Os($(this)[0])}},iron_saw:{id:"tech-iron_saw",title:F("tech_iron_saw"),desc:F("tech_iron_saw_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:1,mining:3},grant:["saw",1],not_trait:["lone_survivor"],cost:{Knowledge:()=>3375,Iron:()=>400},effect:F("tech_iron_saw_effect"),action(){return!!Os($(this)[0])&&(t.city.sawmill={count:0,on:0},!0)}},steel_saw:{id:"tech-steel_saw",title:F("tech_steel_saw"),desc:F("tech_steel_saw_desc"),category:"lumber_gathering",era:"discovery",reqs:{smelting:2,saw:1},grant:["saw",2],cost:{Knowledge:()=>10800,Steel:()=>400},effect:F("tech_steel_saw_effect"),action(){return!!Os($(this)[0])}},iron_axes:{id:"tech-iron_axes",title:F("tech_iron_axes"),desc:F("tech_iron_axes_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:2,mining:3},not_trait:["living_tool"],grant:["axe",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1350:2700,Iron:()=>250},effect:F("tech_iron_axes_effect"),action(){return!!Os($(this)[0])}},steel_axes:{id:"tech-steel_axes",title:F("tech_steel_axes"),desc:F("tech_steel_axes_desc"),category:"lumber_gathering",era:"discovery",reqs:{axe:3,smelting:2},not_trait:["living_tool"],grant:["axe",4],cost:{Knowledge:()=>9e3,Steel:()=>250},effect:F("tech_steel_axes_effect"),action(){return!!Os($(this)[0])}},titanium_axes:{id:"tech-titanium_axes",title:F("tech_titanium_axes"),desc:F("tech_titanium_axes_desc"),category:"lumber_gathering",era:"industrialized",reqs:{axe:4,high_tech:3},not_trait:["living_tool"],grant:["axe",5],cost:{Knowledge:()=>38e3,Titanium:()=>350},effect:F("tech_titanium_axes_effect"),action(){return!!Os($(this)[0])}},chainsaws:{id:"tech-chainsaws",title:F("tech_chainsaws"),desc:F("tech_chainsaws_desc"),category:"lumber_gathering",era:"interstellar",reqs:{axe:5,alpha:2},not_trait:["living_tool"],grant:["axe",6],cost:{Knowledge:()=>56e4,Oil:()=>1e4,Adamantite:()=>2e3},effect:F("tech_chainsaws_effect"),action(){return!!Os($(this)[0])},flair:()=>`
          ${F("tech_chainsaws_flair1")}
          ${F("tech_chainsaws_flair2")}
          `},copper_sledgehammer:{id:"tech-copper_sledgehammer",title:F("tech_copper_sledgehammer"),desc:F("tech_copper_sledgehammer_desc"),category:"stone_gathering",era:"civilized",reqs:{mining:2},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",1],cost:{Knowledge:()=>540,Copper:()=>25},effect:F("tech_copper_sledgehammer_effect"),action(){return!!Os($(this)[0])}},iron_sledgehammer:{id:"tech-iron_sledgehammer",title:F("tech_iron_sledgehammer"),desc:F("tech_iron_sledgehammer_desc"),category:"stone_gathering",era:"civilized",reqs:{hammer:1,mining:3},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1350:2700,Iron:()=>250},effect:F("tech_iron_sledgehammer_effect"),action(){return!!Os($(this)[0])}},steel_sledgehammer:{id:"tech-steel_sledgehammer",title:F("tech_steel_sledgehammer"),desc:F("tech_steel_sledgehammer_desc"),category:"stone_gathering",era:"discovery",reqs:{hammer:2,smelting:2},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",3],cost:{Knowledge:()=>7200,Steel:()=>250},effect:F("tech_steel_sledgehammer_effect"),action(){return!!Os($(this)[0])}},titanium_sledgehammer:{id:"tech-titanium_sledgehammer",title:F("tech_titanium_sledgehammer"),desc:F("tech_titanium_sledgehammer_desc"),category:"stone_gathering",era:"industrialized",reqs:{hammer:3,high_tech:3},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",4],cost:{Knowledge:()=>4e4,Titanium:()=>400},effect:F("tech_titanium_sledgehammer_effect"),action(){return!!Os($(this)[0])}},copper_pickaxe:{id:"tech-copper_pickaxe",title:F("tech_copper_pickaxe"),desc:F("tech_copper_pickaxe_desc"),category:"mining",era:"civilized",reqs:{mining:2},not_trait:["cataclysm","living_tool"],grant:["pickaxe",1],cost:{Knowledge:()=>675,Copper:()=>25},effect:F("tech_copper_pickaxe_effect"),action(){return!!Os($(this)[0])}},iron_pickaxe:{id:"tech-iron_pickaxe",title:F("tech_iron_pickaxe"),desc:F("tech_iron_pickaxe_desc"),category:"mining",era:"civilized",reqs:{pickaxe:1,mining:3},not_trait:["cataclysm","living_tool"],grant:["pickaxe",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1600:3200,Iron:()=>250},effect:F("tech_iron_pickaxe_effect"),action(){return!!Os($(this)[0])}},steel_pickaxe:{id:"tech-steel_pickaxe",title:F("tech_steel_pickaxe"),desc:F("tech_steel_pickaxe_desc"),category:"mining",era:"discovery",reqs:{pickaxe:2,smelting:2},not_trait:["living_tool"],grant:["pickaxe",3],cost:{Knowledge:()=>9e3,Steel:()=>250},effect:F("tech_steel_pickaxe_effect"),action(){return!!Os($(this)[0])}},jackhammer:{id:"tech-jackhammer",title:F("tech_jackhammer"),desc:F("tech_jackhammer_desc"),category:"mining",era:"discovery",reqs:{pickaxe:3,high_tech:2},not_trait:["living_tool"],grant:["pickaxe",4],cost:{Knowledge:()=>22500,Copper:()=>5e3},effect:F("tech_jackhammer_effect"),action(){return!!Os($(this)[0])}},jackhammer_mk2:{id:"tech-jackhammer_mk2",title:F("tech_jackhammer_mk2"),desc:F("tech_jackhammer_mk2"),category:"mining",era:"globalized",reqs:{pickaxe:4,high_tech:4},not_trait:["living_tool"],grant:["pickaxe",5],cost:{Knowledge:()=>67500,Titanium:()=>2e3,Alloy:()=>500},effect:F("tech_jackhammer_mk2_effect"),action(){return!!Os($(this)[0])}},adamantite_hammer:{id:"tech-adamantite_hammer",title:F("tech_adamantite_hammer"),desc:F("tech_adamantite_hammer"),category:"mining",era:"interstellar",reqs:{pickaxe:5,alpha:2},not_trait:["living_tool"],grant:["pickaxe",6],cost:{Knowledge:()=>535e3,Adamantite:()=>12500},effect:F("tech_adamantite_hammer_effect"),action(){return!!Os($(this)[0])}},copper_hoe:{id:"tech-copper_hoe",title:F("tech_copper_hoe"),desc:F("tech_copper_hoe_desc"),category:"agriculture",era:"civilized",reqs:{mining:2,agriculture:1},not_trait:["cataclysm","living_tool"],grant:["hoe",1],cost:{Knowledge:()=>720,Copper:()=>50},effect:F("tech_copper_hoe_effect"),action(){return!!Os($(this)[0])}},iron_hoe:{id:"tech-iron_hoe",title:F("tech_iron_hoe"),desc:F("tech_iron_hoe_desc"),category:"agriculture",era:"civilized",reqs:{hoe:1,mining:3,agriculture:1},not_trait:["living_tool"],grant:["hoe",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1800:3600,Iron:()=>500},effect:F("tech_iron_hoe_effect"),action(){return!!Os($(this)[0])}},steel_hoe:{id:"tech-steel_hoe",title:F("tech_steel_hoe"),desc:F("tech_steel_hoe_desc"),category:"agriculture",era:"discovery",reqs:{hoe:2,smelting:2,agriculture:1},not_trait:["living_tool"],grant:["hoe",3],cost:{Knowledge:()=>12600,Steel:()=>500},effect:F("tech_steel_hoe_effect"),action(){return!!Os($(this)[0])}},titanium_hoe:{id:"tech-titanium_hoe",title:F("tech_titanium_hoe"),desc:F("tech_titanium_hoe_desc"),category:"agriculture",era:"industrialized",reqs:{hoe:3,high_tech:3,agriculture:1},not_trait:["living_tool"],grant:["hoe",4],cost:{Knowledge:()=>44e3,Titanium:()=>500},effect:F("tech_titanium_hoe_effect"),action(){return!!Os($(this)[0])}},adamantite_hoe:{id:"tech-adamantite_hoe",title:F("tech_adamantite_hoe"),desc:F("tech_adamantite_hoe_desc"),category:"agriculture",era:"interstellar",reqs:{hoe:4,alpha:2},not_trait:["living_tool"],grant:["hoe",5],cost:{Knowledge:()=>53e4,Adamantite:()=>1e3},effect:F("tech_adamantite_hoe_effect"),action(){return!!Os($(this)[0])}},cyber_limbs:{id:"tech-cyber_limbs",title:F("tech_cyber_limbs"),desc:F("tech_cyber_limbs"),category:"mining",era:"dimensional",reqs:{high_tech:18},grant:["cyber_worker",1],cost:{Knowledge:()=>27e6},effect:F("tech_cyber_limbs_effect"),action(){return!!Os($(this)[0])}},slave_pens:{id:"tech-slave_pens",title:F("tech_slave_pens"),desc:F("tech_slave_pens"),category:"slaves",era:"civilized",reqs:{military:1,mining:1},not_trait:["cataclysm","lone_survivor"],grant:["slaves",1],trait:["slaver"],cost:{Knowledge:()=>150},effect:F("tech_slave_pens_effect"),action(){return!!Os($(this)[0])&&(t.city.slave_pen={count:0,slaves:0},!0)}},slave_market:{id:"tech-slave_market",title:F("tech_slave_market"),desc:F("tech_slave_market"),category:"slaves",era:"discovery",reqs:{slaves:1,high_tech:1},grant:["slaves",2],trait:["slaver"],cost:{Knowledge:()=>8e3},effect:F("tech_slave_market_effect"),action(){return!!Os($(this)[0])}},ceremonial_dagger:{id:"tech-ceremonial_dagger",title:F("tech_ceremonial_dagger"),desc:F("tech_ceremonial_dagger"),category:"sacrifice",era:"civilized",reqs:{mining:1},grant:["sacrifice",1],trait:["cannibalize"],not_trait:["cataclysm","lone_survivor"],cost:{Knowledge:()=>60},effect:F("tech_ceremonial_dagger_effect"),action(){return!!Os($(this)[0])}},last_rites:{id:"tech-last_rites",title:F("tech_last_rites"),desc:F("tech_last_rites"),category:"sacrifice",era:"civilized",reqs:{sacrifice:1,theology:2},grant:["sacrifice",2],trait:["cannibalize"],cost:{Knowledge:()=>1e3},effect:F("tech_last_rites_effect"),action(){return!!Os($(this)[0])}},ancient_infusion:{id:"tech-ancient_infusion",title:F("tech_ancient_infusion"),desc:F("tech_ancient_infusion"),category:"sacrifice",era:"early_space",reqs:{sacrifice:2,theology:4},grant:["sacrifice",3],trait:["cannibalize"],cost:{Knowledge:()=>182e3},effect:F("tech_ancient_infusion_effect"),action(){return!!Os($(this)[0])}},garrison:{id:"tech-garrison",title:F("tech_garrison"),desc:F("tech_garrison_desc"),category:"military",era:"civilized",reqs:{science:1,housing:1},grant:["military",1],cost:{Knowledge:()=>70},effect:F("tech_garrison_effect"),action(){return!!Os($(this)[0])&&(t.city.garrison={count:0,on:0},!0)}},mercs:{id:"tech-mercs",title:F("tech_mercs"),desc:F("tech_mercs_desc"),category:"military",era:"civilized",reqs:{military:1},grant:["mercs",1],not_trait:["lone_survivor"],cost:{Money:()=>1e4,Knowledge:()=>4500},effect:F("tech_mercs_effect"),action(){return!!Os($(this)[0])&&(t.civic.garrison.mercs=!0,!0)}},signing_bonus:{id:"tech-signing_bonus",title:F("tech_signing_bonus"),desc:F("tech_signing_bonus_desc"),category:"military",era:"industrialized",reqs:{mercs:1,high_tech:3},grant:["mercs",2],cost:{Money:()=>5e4,Knowledge:()=>32e3},effect:F("tech_signing_bonus_effect"),action(){return!!Os($(this)[0])}},hospital:{id:"tech-hospital",title:F("tech_hospital"),desc:F("tech_hospital"),category:"military",era:"civilized",reqs:{military:1,alumina:1},grant:["medic",1],not_trait:["artifical"],cost:{Knowledge:()=>5e3},effect:F("tech_hospital_effect"),action(){return!!Os($(this)[0])&&(t.city.hospital={count:0},!0)}},bac_tanks:{id:"tech-bac_tanks",title:()=>t.race.artifical?F("tech_repair_subroutines"):F("tech_bac_tanks"),desc:()=>t.race.artifical?F("tech_repair_subroutines"):F("tech_bac_tanks_desc"),category:"military",era:"interstellar",reqs:{medic:1,infernite:1},grant:["medic",2],cost:{Knowledge:()=>6e5,Infernite:()=>250},effect:()=>t.race.artifical?F("tech_repair_subroutines_effect"):F("tech_bac_tanks_effect"),action(){return!!Os($(this)[0])}},boot_camp:{id:"tech-boot_camp",title:F("tech_boot_camp"),desc:F("tech_boot_camp_desc"),category:"military",era:"discovery",reqs:{high_tech:1},grant:["boot_camp",1],cost:{Knowledge:()=>8e3},effect:F("tech_boot_camp_effect"),action(){return!!Os($(this)[0])&&(t.city.boot_camp={count:0},!0)}},vr_training:{id:"tech-vr_training",title:F("tech_vr_training"),desc:F("tech_vr_training"),category:"military",era:"interstellar",path:["standard","truepath"],reqs:{boot_camp:1,high_tech:12},not_trait:["cataclysm","lone_survivor"],grant:["boot_camp",2],cost:{Knowledge:()=>625e3},effect:()=>F("tech_vr_training_effect"),action(){return!!Os($(this)[0])}},bows:{id:"tech-bows",title:F("tech_bows"),desc:F("tech_bows_desc"),category:"military",era:"civilized",reqs:{military:1},grant:["military",2],cost:{Knowledge:()=>225,Lumber:()=>250},effect:F("tech_bows_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},flintlock_rifle:{id:"tech-flintlock_rifle",title:()=>"magic"===t.race.universe?F("tech_magic_arrow"):F("tech_flintlock_rifle"),desc:()=>"magic"===t.race.universe?F("tech_magic_arrow"):F("tech_flintlock_rifle"),category:"military",era:"civilized",reqs:{military:2,explosives:1},grant:["military",3],cost:{Knowledge:()=>5400,Coal:()=>"magic"===t.race.universe?0:750,Mana:()=>"magic"===t.race.universe?100:0},effect:()=>"magic"===t.race.universe?F("tech_magic_arrow_effect"):F("tech_flintlock_rifle_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},machine_gun:{id:"tech-machine_gun",title:()=>"magic"===t.race.universe?F("tech_fire_mage"):F("tech_machine_gun"),desc:()=>"magic"===t.race.universe?F("tech_fire_mage"):F("tech_machine_gun"),category:"military",era:"industrialized",reqs:{military:3,oil:1},grant:["military",4],cost:{Mana:()=>"magic"===t.race.universe?300:0,Knowledge:()=>33750,Oil:()=>1500},effect:F("tech_machine_gun_effect"),effect:()=>"magic"===t.race.universe?F("tech_fire_mage_effect"):F("tech_machine_gun_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},bunk_beds:{id:"tech-bunk_beds",title:F("tech_bunk_beds"),desc:F("tech_bunk_beds"),category:"military",era:"globalized",reqs:{military:4,high_tech:4},grant:["military",5],cost:{Knowledge:()=>76500,Furs:()=>25e3,Alloy:()=>3e3},effect:F("tech_bunk_beds_effect"),action(){return!!Os($(this)[0])}},rail_guns:{id:"tech-rail_guns",title:()=>"magic"===t.race.universe?F("tech_lightning_caster"):F("tech_rail_guns"),desc:()=>"magic"===t.race.universe?F("tech_lightning_caster"):F("tech_rail_guns"),category:"military",era:"early_space",reqs:{military:5,mass:1},grant:["military",6],cost:{Mana:()=>"magic"===t.race.universe?450:0,Knowledge:()=>2e5,Iridium:()=>2500},effect:()=>"magic"===t.race.universe?F("tech_lightning_caster_effect"):F("tech_rail_guns_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},laser_rifles:{id:"tech-laser_rifles",title:()=>"magic"===t.race.universe?F("tech_mana_rifles"):F("tech_laser_rifles"),desc:()=>"magic"===t.race.universe?F("tech_mana_rifles"):F("tech_laser_rifles"),category:"military",era:"deep_space",reqs:{military:6,high_tech:9,elerium:1},grant:["military",7],cost:{Knowledge:()=>325e3,Elerium:()=>250},effect:()=>"magic"===t.race.universe?F("tech_mana_rifles_effect"):F("tech_laser_rifles_effect"),action(){return!!Os($(this)[0])&&("sharkin"===t.race.species&&Xc("laser_shark"),!0)},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},plasma_rifles:{id:"tech-plasma_rifles",title:()=>"magic"===t.race.universe?F("tech_focused_rifles"):F("tech_plasma_rifles"),desc:()=>"magic"===t.race.universe?F("tech_focused_rifles"):F("tech_plasma_rifles"),category:"military",era:"interstellar",reqs:{military:7,high_tech:13},grant:["military",8],path:["standard","truepath"],cost:{Knowledge:()=>78e4,Elerium:()=>t.race.truepath?1e3:500},effect:()=>"magic"===t.race.universe?F("tech_focused_rifles_effect"):F("tech_plasma_rifles_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},disruptor_rifles:{id:"tech-disruptor_rifles",title:()=>"magic"===t.race.universe?F("tech_magic_missile"):F("tech_disruptor_rifles"),desc:()=>"magic"===t.race.universe?F("tech_magic_missile"):F("tech_disruptor_rifles"),category:"military",era:"interstellar",reqs:{military:8,high_tech:14,science:15,infernite:1},grant:["military",9],cost:{Knowledge:()=>1e6,Infernite:()=>1e3},effect:()=>"magic"===t.race.universe?F("tech_magic_missile_effect"):F("tech_disruptor_rifles_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},gauss_rifles:{id:"tech-gauss_rifles",title:()=>"magic"===t.race.universe?F("tech_magicword_kill"):F("tech_gauss_rifles"),desc:()=>"magic"===t.race.universe?F("tech_magicword_kill"):F("tech_gauss_rifles"),category:"military",era:"intergalactic",reqs:{military:9,science:18},grant:["military",10],cost:{Knowledge:()=>95e5,Bolognium:()=>1e5},effect:()=>"magic"===t.race.universe?F("tech_magicword_kill_effect"):F("tech_gauss_rifles_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},cyborg_soldiers:{id:"tech-cyborg_soldiers",title:F("tech_cyborg_soldiers"),desc:F("tech_cyborg_soldiers"),category:"military",era:"dimensional",reqs:{military:10,high_tech:18},grant:["military",11],cost:{Knowledge:()=>26e6,Adamantite:()=>8e6,Bolognium:()=>4e6,Orichalcum:()=>6e6},effect:F("tech_cyborg_soldiers_effect"),action(){return!!Os($(this)[0])},post(){sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update")}},space_marines:{id:"tech-space_marines",title:F("tech_space_marines"),desc:F("tech_space_marines_desc"),category:"military",era:"early_space",reqs:{space:3,mars:2},grant:["marines",1],cost:{Knowledge:()=>21e4},effect:()=>`
          ${F("tech_space_marines_effect",[Xt().red])}
          `,action(){return!!Os($(this)[0])&&(t.space.space_barracks={count:0,on:0},!0)},flair:F("tech_space_marines_flair")},hammocks:{id:"tech-hammocks",title:F("tech_hammocks"),desc:F("tech_hammocks"),category:"military",era:"intergalactic",reqs:{marines:1,nanoweave:1},grant:["marines",2],cost:{Knowledge:()=>89e5,Nanoweave:()=>3e4},effect:()=>F("tech_hammocks_effect"),action(){return!!Os($(this)[0])}},cruiser:{id:"tech-cruiser",title:F("tech_cruiser"),desc:F("tech_cruiser"),category:"military",era:"interstellar",reqs:{high_tech:14,proxima:2,aerogel:1},grant:["cruiser",1],cost:{Knowledge:()=>86e4},effect:F("tech_cruiser_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.cruiser={count:0,on:0},!0)}},armor:{id:"tech-armor",title:F("tech_armor"),desc:F("tech_armor_desc"),category:"military",era:"civilized",reqs:{military:1},not_trait:["apex_predator"],grant:["armor",1],cost:{Money:()=>250,Knowledge:()=>225,Furs:()=>250},effect:F("tech_armor_effect"),action(){return!!Os($(this)[0])}},plate_armor:{id:"tech-plate_armor",title:F("tech_plate_armor"),desc:F("tech_plate_armor_desc"),category:"military",era:"civilized",reqs:{armor:1,mining:3},grant:["armor",2],cost:{Knowledge:()=>3400,Iron:()=>600},effect:F("tech_plate_armor_effect"),action(){return!!Os($(this)[0])}},kevlar:{id:"tech-kevlar",title:F("tech_kevlar"),desc:F("tech_kevlar_desc"),category:"military",era:"globalized",reqs:{armor:2,polymer:1},grant:["armor",3],cost:{Knowledge:()=>86e3,Polymer:()=>750},effect:F("tech_kevlar_effect"),action(){return!!Os($(this)[0])}},nanoweave_vest:{id:"tech-nanoweave_vest",title:F("tech_nanoweave_vest"),desc:F("tech_nanoweave_vest"),category:"military",era:"intergalactic",reqs:{armor:3,nanoweave:1},grant:["armor",4],cost:{Knowledge:()=>925e4,Nanoweave:()=>75e3},effect:F("tech_nanoweave_vest_effect"),action(){return!!Os($(this)[0])}},laser_turret:{id:"tech-laser_turret",title:F("tech_laser_turret"),desc:F("tech_laser_turret"),category:"hell_dimension",era:"interstellar",reqs:{high_tech:9,portal:2},grant:["turret",1],cost:{Knowledge:()=>6e5,Elerium:()=>100},effect:()=>`
          ${F("tech_laser_turret_effect1")}
          ${F("tech_laser_turret_effect2")}
          `,action(){return!!Os($(this)[0])},post(){sc({el:"#fort"},"update"),Ks(!1,["portal-turret"])}},plasma_turret:{id:"tech-plasma_turret",title:F("tech_plasma_turret"),desc:F("tech_plasma_turret"),category:"hell_dimension",era:"interstellar",reqs:{high_tech:13,turret:1},grant:["turret",2],cost:{Knowledge:()=>76e4,Elerium:()=>350},effect:()=>`
          ${F("tech_plasma_turret_effect")}
          ${F("tech_laser_turret_effect2")}
          `,action(){return!!Os($(this)[0])},post(){sc({el:"#fort"},"update"),Ks(!1,["portal-turret"])}},black_powder:{id:"tech-black_powder",title:()=>"magic"===t.race.universe?F("tech_magic_powder"):F("tech_black_powder"),desc:()=>"magic"===t.race.universe?F("tech_magic_powder_desc"):F("tech_black_powder_desc"),category:"progress",era:"civilized",reqs:{mining:4},grant:["explosives",1],cost:{Knowledge:()=>4500,Mana:()=>"magic"===t.race.universe?100:0,Crystal:()=>"magic"===t.race.universe?250:0,Coal:()=>"magic"===t.race.universe?300:500},effect:()=>"magic"===t.race.universe?F("tech_magic_powder_effect"):F("tech_black_powder_effect"),action(){return!!Os($(this)[0])}},dynamite:{id:"tech-dynamite",title:F("tech_dynamite"),desc:F("tech_dynamite"),category:"mining",era:"civilized",reqs:{explosives:1},grant:["explosives",2],cost:{Knowledge:()=>4800,Coal:()=>750},effect:F("tech_dynamite_effect"),action(){return!!Os($(this)[0])}},anfo:{id:"tech-anfo",title:F("tech_anfo"),desc:F("tech_anfo"),category:"mining",era:"industrialized",reqs:{explosives:2,oil:1},grant:["explosives",3],cost:{Knowledge:()=>42e3,Oil:()=>2500},effect:F("tech_anfo_effect"),action(){return!!Os($(this)[0])}},mad:{id:"tech-mad",title:F("tech_mad"),desc:F("tech_mad_desc"),category:"special",era:"globalized",reqs:{uranium:1,explosives:3,high_tech:7},not_trait:["cataclysm","lone_survivor"],grant:["mad",1],condition:()=>!(t.race.sludge||t.race.truepath&&!t.tech.world_control),cost:{Knowledge:()=>12e4,Oil:()=>t.city.ptrait.includes("dense")?1e4:8500,Uranium:()=>1250},effect:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("tech_mad_effect_easter"):F("tech_mad_effect"),action(){return!!Os($(this)[0])&&(t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?Di(F("tech_mad_info_easter"),"info",!1,["progress"]):Di(F("tech_mad_info"),"info",!1,["progress"]),t.civic.mad.display=!0,!0)}},cement:{id:"tech-cement",title:F("tech_cement"),desc:F("tech_cement_desc"),category:"cement",era:"civilized",reqs:{mining:1,storage:1,science:1},not_trait:["flier"],grant:["cement",1],cost:{Knowledge:()=>500},effect:F("tech_cement_effect"),action(){return!!Os($(this)[0])&&(t.city.cement_plant={count:0,on:0},!0)}},rebar:{id:"tech-rebar",title:F("tech_rebar"),desc:F("tech_rebar"),category:"cement",era:"civilized",reqs:{mining:3,cement:1},not_trait:["flier"],grant:["cement",2],cost:{Knowledge:()=>3200,Iron:()=>750},effect:F("tech_rebar_effect"),action(){return!!Os($(this)[0])}},steel_rebar:{id:"tech-steel_rebar",title:F("tech_steel_rebar"),desc:F("tech_steel_rebar"),category:"cement",era:"civilized",reqs:{smelting:2,cement:2},not_trait:["flier"],grant:["cement",3],cost:{Knowledge:()=>6750,Steel:()=>750},effect:F("tech_steel_rebar_effect"),action(){return!!Os($(this)[0])}},portland_cement:{id:"tech-portland_cement",title:F("tech_portland_cement"),desc:F("tech_portland_cement"),category:"cement",era:"industrialized",reqs:{cement:3,high_tech:3},not_trait:["flier"],grant:["cement",4],cost:{Knowledge:()=>32e3},effect:F("tech_portland_cement_effect"),action(){return!!Os($(this)[0])}},screw_conveyor:{id:"tech-screw_conveyor",title:F("tech_screw_conveyor"),desc:F("tech_screw_conveyor"),category:"cement",era:"globalized",reqs:{cement:4,high_tech:4},not_trait:["flier"],grant:["cement",5],cost:{Knowledge:()=>72e3},effect:F("tech_screw_conveyor_effect"),action(){return!!Os($(this)[0])}},adamantite_screws:{id:"tech-adamantite_screws",title:F("tech_adamantite_screws"),desc:F("tech_adamantite_screws"),category:"cement",era:"interstellar",reqs:{cement:5,alpha:2},not_trait:["cataclysm","flier"],grant:["cement",6],cost:{Knowledge:()=>5e5,Adamantite:()=>1e4},effect:F("tech_adamantite_screws_effect",[3]),action(){return!!Os($(this)[0])}},hunter_process:{id:"tech-hunter_process",title:F("tech_hunter_process"),desc:F("tech_hunter_process"),category:"mining",era:"industrialized",reqs:{high_tech:3,smelting:2},grant:["titanium",1],cost:{Knowledge:()=>45e3,Titanium:()=>1e3},effect:F("tech_hunter_process_effect"),action(){return!!Os($(this)[0])&&(t.resource.Titanium.value=Qa.Titanium,!0)}},kroll_process:{id:"tech-kroll_process",title:F("tech_kroll_process"),desc:F("tech_kroll_process"),category:"mining",era:"globalized",reqs:{titanium:1,high_tech:4},grant:["titanium",2],cost:{Knowledge:()=>78e3,Titanium:()=>1e4},effect:F("tech_kroll_process_effect"),action(){return!!Os($(this)[0])}},cambridge_process:{id:"tech-cambridge_process",title:F("tech_cambridge_process"),desc:F("tech_cambridge_process"),category:"mining",era:"early_space",reqs:{titanium:2,supercollider:1},grant:["titanium",3],cost:{Knowledge:()=>135e3,Titanium:()=>17500},effect:F("tech_cambridge_process_effect"),action(){return!!Os($(this)[0])}},pynn_partical:{id:"tech-pynn_partical",title:F("tech_pynn_partical"),desc:F("tech_pynn_partical"),category:"progress",era:"early_space",path:["standard"],reqs:{supercollider:1},grant:["particles",1],cost:{Knowledge:()=>1e5},effect:F("tech_pynn_partical_effect"),action(){return!!Os($(this)[0])}},matter_compression:{id:"tech-matter_compression",title:F("tech_matter_compression"),desc:F("tech_matter_compression"),category:"storage",era:"early_space",path:["standard"],reqs:{particles:1},grant:["particles",2],cost:{Knowledge:()=>112500},effect:F("tech_matter_compression_effect"),action(){return!!Os($(this)[0])}},higgs_boson:{id:"tech-higgs_boson",title:F("tech_higgs_boson"),desc:F("tech_higgs_boson"),category:"science",era:"early_space",path:["standard"],reqs:{particles:2,supercollider:2},grant:["particles",3],cost:{Knowledge:()=>125e3},effect:F("tech_higgs_boson_effect"),action(){return!!Os($(this)[0])}},dimensional_compression:{id:"tech-dimensional_compression",title:F("tech_dimensional_compression"),desc:F("tech_dimensional_compression"),category:"storage",era:"interstellar",reqs:{particles:3,science:11,supercollider:3},grant:["particles",4],cost:{Knowledge:()=>425e3},effect:F("tech_dimensional_compression_effect"),action(){return!!Os($(this)[0])}},theology:{id:"tech-theology",title:F("tech_theology"),desc:F("tech_theology"),category:"religion",era:"civilized",reqs:{theology:1,housing:1,cement:1},grant:["theology",2],cost:{Knowledge:()=>900},effect:F("tech_theology_effect"),action(){return!!Os($(this)[0])&&(t.city.temple={count:0},t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0}),t.genes.ancients&&t.genes.ancients>=2&&(t.civic.priest.display=!0),!0)}},fanaticism:{id:"tech-fanaticism",title:F("tech_fanaticism"),desc:F("tech_fanaticism"),category:"religion",era:"civilized",wiki:!t.genes.transcendence,reqs:{theology:2},grant:["theology",3],not_gene:["transcendence"],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-anthropology"===e.id)),cost:{Knowledge:()=>2500},effect:`
          ${F("tech_fanaticism_effect")}
          ${F("tech_fanaticism_warning")}
          `,action(){return!!Os($(this)[0])&&(t.tech.fanaticism=1,t.race.gods===t.race.species&&Xc("second_evolution"),Ns(t.race.gods),!0)}},alt_fanaticism:{id:"tech-alt_fanaticism",title:F("tech_fanaticism"),desc:F("tech_fanaticism"),category:"religion",era:"civilized",wiki:!!t.genes.transcendence,reqs:{theology:2},grant:["fanaticism",1],gene:["transcendence"],cost:{Knowledge:()=>2500},effect:`
          ${F("tech_fanaticism_effect")}
          `,action(){return!!Os($(this)[0])&&(2===t.tech.theology&&(t.tech.theology=3),t.race.gods===t.race.species&&Xc("second_evolution"),Ns(t.race.gods),!0)}},ancient_theology:{id:"tech-ancient_theology",title:F("tech_ancient_theology"),desc:F("tech_ancient_theology"),category:"religion",era:"early_space",reqs:{theology:3,mars:2},grant:["theology",4],condition:()=>!!t.genes.ancients,cost:{Knowledge:()=>18e4},effect:()=>F("tech_ancient_theology_effect",["none"!==t.race.old_gods?di[t.race.old_gods.toLowerCase()].entity:di[t.race.species].entity,"none"!==t.race.gods?di[t.race.gods.toLowerCase()].entity:di[t.race.species].entity]),action(){return!!Os($(this)[0])&&(t.space.ziggurat={count:0},!0)}},study:{id:"tech-study",title:F("tech_study"),desc:F("tech_study_desc"),category:"religion",era:"early_space",reqs:{theology:4},grant:["theology",5],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-deify"===e.id)),cost:{Knowledge:()=>195e3},effect:()=>`
          ${F("tech_study_effect",["none"!==t.race.old_gods?di[t.race.old_gods.toLowerCase()].entity:di[t.race.species].entity])}
          ${F("tech_study_warning")}
          `,action(){return!!Os($(this)[0])&&(t.tech.ancient_study=1,!0)}},encoding:{id:"tech-encoding",title:F("tech_encoding"),desc:F("tech_encoding_desc"),category:"religion",era:"deep_space",reqs:{ancient_study:1,mars:5},grant:["ancient_study",2],cost:{Knowledge:()=>268e3},effect:()=>`
          ${F("tech_encoding_effect")}
          `,action(){return!!Os($(this)[0])}},deify:{id:"tech-deify",title:F("tech_deify"),desc:F("tech_deify_desc"),category:"religion",era:"early_space",reqs:{theology:4},grant:["theology",5],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-study"===e.id)),cost:{Knowledge:()=>195e3},effect:()=>`
          ${F("tech_deify_effect",["none"!==t.race.old_gods?di[t.race.old_gods.toLowerCase()].entity:di[t.race.species].entity])}
          ${F("tech_deify_warning")}
          `,action(){return!!Os($(this)[0])&&(t.tech.ancient_deify=1,Ns(t.race.old_gods),Oe("Genetics"),!0)}},infusion:{id:"tech-infusion",title:F("tech_infusion"),desc:F("tech_infusion_desc"),category:"religion",era:"deep_space",reqs:{ancient_deify:1,mars:5},grant:["ancient_deify",2],cost:{Knowledge:()=>268e3},effect:()=>`
          ${F("tech_infusion_effect")}
          `,action(){return!!Os($(this)[0])}},indoctrination:{id:"tech-indoctrination",title:F("tech_indoctrination"),desc:F("tech_indoctrination"),category:"religion",era:"civilized",reqs:{fanaticism:1},grant:["fanaticism",2],cost:{Knowledge:()=>5e3},effect:F("tech_indoctrination_effect"),action(){return!!Os($(this)[0])},post(){t.race.terrifying&&(t.tech.fanaticism=3,ms())}},missionary:{id:"tech-missionary",title:F("tech_missionary"),desc:F("tech_missionary"),category:"religion",era:"discovery",reqs:{fanaticism:2},not_trait:["terrifying"],grant:["fanaticism",3],cost:{Knowledge:()=>1e4},effect:F("tech_missionary_effect"),action(){return!!Os($(this)[0])}},zealotry:{id:"tech-zealotry",title:F("tech_zealotry"),desc:F("tech_zealotry"),category:"religion",era:"discovery",reqs:{fanaticism:3},grant:["fanaticism",4],cost:{Knowledge:()=>25e3},effect:F("tech_zealotry_effect"),action(){return!!Os($(this)[0])}},anthropology:{id:"tech-anthropology",title:F("tech_anthropology"),desc:F("tech_anthropology"),category:"religion",era:"civilized",wiki:!t.genes.transcendence,reqs:{theology:2},grant:["theology",3],not_gene:["transcendence"],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-fanaticism"===e.id)),cost:{Knowledge:()=>2500},effect:`
          ${F("tech_anthropology_effect")}
          ${F("tech_anthropology_warning")}
          `,action(){return!!Os($(this)[0])&&(t.tech.anthropology=1,!0)}},alt_anthropology:{id:"tech-alt_anthropology",title:F("tech_anthropology"),desc:F("tech_anthropology"),category:"religion",era:"civilized",wiki:!!t.genes.transcendence,reqs:{theology:2},grant:["anthropology",1],gene:["transcendence"],cost:{Knowledge:()=>2500},effect:`
          ${F("tech_anthropology_effect")}
          `,action(){return!!Os($(this)[0])&&(2===t.tech.theology&&(t.tech.theology=3),!0)}},mythology:{id:"tech-mythology",title:F("tech_mythology"),desc:F("tech_mythology"),category:"religion",era:"civilized",reqs:{anthropology:1},grant:["anthropology",2],cost:{Knowledge:()=>5e3},effect:F("tech_mythology_effect"),action(){return!!Os($(this)[0])}},archaeology:{id:"tech-archaeology",title:F("tech_archaeology"),desc:F("tech_archaeology"),category:"science",era:"discovery",reqs:{anthropology:2},grant:["anthropology",3],cost:{Knowledge:()=>1e4},effect:F("tech_archaeology_effect"),action(){return!!Os($(this)[0])}},merchandising:{id:"tech-merchandising",title:F("tech_merchandising"),desc:F("tech_merchandising"),category:"banking",era:"discovery",reqs:{anthropology:3},grant:["anthropology",4],cost:{Knowledge:()=>25e3},effect:()=>t.race.truepath?F("tech_merchandising_effect_tp"):F("tech_merchandising_effect"),action(){return!!Os($(this)[0])}},astrophysics:{id:"tech-astrophysics",title:F("tech_astrophysics"),desc:F("tech_astrophysics_desc"),category:"storage",era:"early_space",reqs:{space:2},grant:["space_explore",1],cost:{Knowledge:()=>125e3},effect:F("tech_astrophysics_effect"),action(){return!!Os($(this)[0])&&(t.space.propellant_depot={count:0},!0)}},rover:{id:"tech-rover",title:F("tech_rover"),desc:F("tech_rover"),category:"space_exploration",era:"early_space",reqs:{space_explore:1},grant:["space_explore",2],cost:{Knowledge:()=>135e3,Alloy:()=>22e3,Polymer:()=>18e3,Uranium:()=>750},effect:F("tech_rover_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.moon=!0,t.space.moon_base={count:0,on:0,support:0,s_max:0},!0)}},probes:{id:"tech-probes",title:F("tech_probes"),desc:F("tech_probes"),category:"space_exploration",era:"early_space",reqs:{space_explore:2},grant:["space_explore",3],cost:{Knowledge:()=>168e3,Steel:()=>1e5,Iridium:()=>5e3,Uranium:()=>2250,Helium_3:()=>3500},effect:F("tech_probes_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.red=!0,t.settings.space.hell=!0,t.space.spaceport={count:0,on:0,support:0,s_max:0},!0)}},starcharts:{id:"tech-starcharts",title:F("tech_starcharts"),desc:F("tech_starcharts"),category:"space_exploration",era:"early_space",reqs:{space_explore:3,science:9},grant:["space_explore",4],cost:{Knowledge:()=>185e3},effect:F("tech_starcharts_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.gas=!0,t.settings.space.sun=!0,t.race.truepath&&(t.settings.showOuter=!0),t.space.swarm_control={count:0,support:0,s_max:0},!0)}},colonization:{id:"tech-colonization",title:F("tech_colonization"),desc:()=>F("tech_colonization_desc",[Xt().red]),category:"agriculture",era:"early_space",reqs:{space:4,mars:1},grant:["mars",2],cost:{Knowledge:()=>172e3},effect:()=>F(t.race.artifical?"tech_colonization_artifical_effect":"tech_colonization_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.biodome={count:0,on:0},!0)}},red_tower:{id:"tech-red_tower",title:()=>F("tech_red_tower",[Xt().red]),desc:()=>F("tech_red_tower",[Xt().red]),category:"space_exploration",era:"early_space",reqs:{mars:2},grant:["mars",3],cost:{Knowledge:()=>195e3},effect:()=>F("tech_red_tower_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.red_tower={count:0,on:0},!0)}},space_manufacturing:{id:"tech-space_manufacturing",title:F("tech_space_manufacturing"),desc:F("tech_space_manufacturing_desc"),category:"crafting",era:"early_space",reqs:{mars:3},grant:["mars",4],cost:{Knowledge:()=>22e4},effect:()=>F("tech_space_manufacturing_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.red_factory={count:0,on:0},!0)}},exotic_lab:{id:"tech-exotic_lab",title:F("tech_exotic_lab"),desc:F("tech_exotic_lab_desc"),category:"science",era:"deep_space",reqs:{mars:4,asteroid:5},grant:["mars",5],cost:{Knowledge:()=>25e4},effect:F("tech_exotic_lab_effect"),action(){return!!Os($(this)[0])&&(t.space.exotic_lab={count:0,on:0},!0)}},hydroponics:{id:"tech-hydroponics",title:F("tech_hydroponics"),desc:()=>F("tech_hydroponics"),category:"agriculture",era:"intergalactic",reqs:{mars:5,gateway:3},grant:["mars",6],cost:{Knowledge:()=>3e6,Bolognium:()=>5e5},effect:()=>F("tech_hydroponics_effect"),action(){return!!Os($(this)[0])}},dyson_sphere:{id:"tech-dyson_sphere",title:F("tech_dyson_sphere"),desc:F("tech_dyson_sphere"),category:"power_generation",era:"early_space",reqs:{solar:1},grant:["solar",2],cost:{Knowledge:()=>195e3},effect:F("tech_dyson_sphere_effect"),action(){return!!Os($(this)[0])}},dyson_swarm:{id:"tech-dyson_swarm",title:F("tech_dyson_swarm"),desc:F("tech_dyson_swarm"),category:"power_generation",era:"early_space",reqs:{solar:2},grant:["solar",3],cost:{Knowledge:()=>21e4},effect:F("tech_dyson_swarm_effect"),action(){return!!Os($(this)[0])&&(t.space.swarm_satellite={count:0},!0)}},swarm_plant:{id:"tech-swarm_plant",title:F("tech_swarm_plant"),desc:F("tech_swarm_plant"),category:"power_generation",era:"deep_space",reqs:{solar:3,hell:1,gas_moon:1},grant:["solar",4],cost:{Knowledge:()=>25e4},effect:()=>F("tech_swarm_plant_effect",[di[t.race.species].home,Xt().hell]),action(){return!!Os($(this)[0])&&(t.space.swarm_plant={count:0},!0)}},space_sourced:{id:"tech-space_sourced",title:F("tech_space_sourced"),desc:F("tech_space_sourced_desc"),category:"power_generation",era:"deep_space",reqs:{solar:4,asteroid:3},grant:["solar",5],cost:{Knowledge:()=>3e5},effect:F("tech_space_sourced_effect"),action(){return!!Os($(this)[0])}},swarm_plant_ai:{id:"tech-swarm_plant_ai",title:F("tech_swarm_plant_ai"),desc:F("tech_swarm_plant_ai"),category:"power_generation",era:"deep_space",reqs:{solar:4,high_tech:10},grant:["swarm",1],cost:{Knowledge:()=>335e3},effect:F("tech_swarm_plant_ai_effect"),action(){return!!Os($(this)[0])}},swarm_control_ai:{id:"tech-swarm_control_ai",title:F("tech_swarm_control_ai"),desc:F("tech_swarm_control_ai"),category:"power_generation",era:"deep_space",reqs:{swarm:1},grant:["swarm",2],cost:{Knowledge:()=>36e4},effect:F("tech_swarm_control_ai_effect"),action(){return!!Os($(this)[0])}},quantum_swarm:{id:"tech-quantum_swarm",title:F("tech_quantum_swarm"),desc:F("tech_quantum_swarm"),category:"power_generation",era:"deep_space",reqs:{swarm:2,high_tech:11},grant:["swarm",3],cost:{Knowledge:()=>45e4},effect:F("tech_quantum_swarm_effect"),action(){return!!Os($(this)[0])}},perovskite_cell:{id:"tech-perovskite_cell",title:F("tech_perovskite_cell"),desc:F("tech_perovskite_cell"),category:"power_generation",era:"interstellar",reqs:{swarm:3},grant:["swarm",4],path:["standard","truepath"],cost:{Knowledge:()=>525e3,Titanium:()=>1e5},effect:F("tech_perovskite_cell_effect"),action(){return!!Os($(this)[0])}},swarm_convection:{id:"tech-swarm_convection",title:F("tech_swarm_convection"),desc:F("tech_swarm_convection"),category:"power_generation",era:"interstellar",reqs:{swarm:4,stanene:1},grant:["swarm",5],path:["standard","truepath"],cost:{Knowledge:()=>725e3,Stanene:()=>1e5},effect:F("tech_swarm_convection_effect"),action(){return!!Os($(this)[0])}},orichalcum_panels:{id:"tech-orichalcum_panels",title:F("tech_orichalcum_panels"),desc:F("tech_orichalcum_panels"),category:"power_generation",era:"intergalactic",reqs:{high_tech:17,swarm:5},grant:["swarm",6],cost:{Knowledge:()=>14e6,Orichalcum:()=>125e3},effect:()=>F("tech_orichalcum_panels_effect"),action(){return!!Os($(this)[0])}},dyson_net:{id:"tech-dyson_net",title:F("tech_dyson_net"),desc:F("tech_dyson_net"),category:"power_generation",era:"interstellar",reqs:{solar:3,proxima:2,stanene:1},grant:["proxima",3],cost:{Knowledge:()=>8e5},effect:F("tech_dyson_net_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.dyson={count:0},!0)}},dyson_sphere2:{id:"tech-dyson_sphere2",title:F("tech_dyson_sphere"),desc:F("tech_dyson_sphere"),category:"power_generation",era:"intergalactic",reqs:{proxima:3,piracy:1},grant:["dyson",1],cost:{Knowledge:()=>5e6},effect:F("tech_dyson_sphere2_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.dyson_sphere={count:0},!0)}},orichalcum_sphere:{id:"tech-orichalcum_sphere",title:F("tech_orichalcum_sphere"),desc:F("tech_orichalcum_sphere"),category:"power_generation",era:"intergalactic",reqs:{dyson:1,science:19},condition:()=>!!(t.interstellar.dyson_sphere&&t.interstellar.dyson_sphere.count>=100),grant:["dyson",2],cost:{Knowledge:()=>175e5,Orichalcum:()=>25e4},effect:F("tech_orichalcum_sphere_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.orichalcum_sphere={count:0},!0)}},gps:{id:"tech-gps",title:F("tech_gps"),desc:F("tech_gps"),category:"market",era:"early_space",reqs:{space_explore:1},not_trait:["terrifying"],grant:["satellite",1],cost:{Knowledge:()=>15e4},effect:F("tech_gps_effect"),action(){return!!Os($(this)[0])&&(t.space.gps={count:0},!0)}},nav_beacon:{id:"tech-nav_beacon",title:F("tech_nav_beacon"),desc:F("tech_nav_beacon"),category:"space_exploration",era:"early_space",reqs:{luna:1},grant:["luna",2],cost:{Knowledge:()=>18e4},effect:F("tech_nav_beacon_effect"),action(){return!!Os($(this)[0])&&(t.space.nav_beacon={count:0,on:0},!0)}},subspace_signal:{id:"tech-subspace_signal",title:F("tech_subspace_signal"),desc:F("tech_subspace_signal"),category:"space_exploration",era:"interstellar",reqs:{science:13,luna:2,stanene:1},grant:["luna",3],cost:{Knowledge:()=>7e5,Stanene:()=>125e3},effect:()=>F("tech_subspace_signal_effect",[Xt().red]),action(){return!!Os($(this)[0])}},atmospheric_mining:{id:"tech-atmospheric_mining",title:F("tech_atmospheric_mining"),desc:F("tech_atmospheric_mining"),category:"power_generation",era:"early_space",reqs:{space:5},grant:["gas_giant",1],cost:{Knowledge:()=>19e4},effect:F("tech_atmospheric_mining_effect"),action(){return!!Os($(this)[0])&&(t.space.gas_mining={count:0,on:0},t.space.gas_storage={count:0},!0)}},helium_attractor:{id:"tech-helium_attractor",title:F("tech_helium_attractor"),desc:F("tech_helium_attractor"),category:"power_generation",era:"deep_space",reqs:{gas_giant:1,elerium:1},grant:["helium",1],cost:{Knowledge:()=>29e4,Elerium:()=>250},effect:()=>F("tech_helium_attractor_effect",[Xt().gas]),action(){return!!Os($(this)[0])}},ram_scoops:{id:"tech-ram_scoops",title:F("tech_ram_scoops"),desc:F("tech_ram_scoops"),category:"power_generation",era:"interstellar",reqs:{nebula:2},grant:["ram_scoop",1],cost:{Knowledge:()=>58e4},effect:()=>F("tech_ram_scoops_effect"),action(){return!!Os($(this)[0])}},elerium_prospecting:{id:"tech-elerium_prospecting",title:F("tech_elerium_prospecting"),desc:F("tech_elerium_prospecting"),category:"space_mining",era:"interstellar",reqs:{nebula:2},grant:["nebula",3],cost:{Knowledge:()=>61e4},effect:()=>F("tech_elerium_prospecting_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.elerium_prospector={count:0,on:0},!0)}},zero_g_mining:{id:"tech-zero_g_mining",title:F("tech_zero_g_mining"),desc:F("tech_zero_g_mining"),category:"space_mining",era:"early_space",reqs:{asteroid:1,high_tech:8},grant:["asteroid",2],cost:{Knowledge:()=>21e4},effect:F("tech_zero_g_mining_effect"),action(){return!!Os($(this)[0])&&(t.space.space_station={count:0,on:0,support:0,s_max:0},t.space.iridium_ship={count:0,on:0},t.space.iron_ship={count:0,on:0},!0)}},elerium_mining:{id:"tech-elerium_mining",title:F("tech_elerium_mining"),desc:F("tech_elerium_mining"),category:"space_mining",era:"deep_space",reqs:{asteroid:4},grant:["asteroid",5],cost:{Knowledge:()=>235e3,Elerium:()=>t.race.truepath?.5:1},effect:F("tech_elerium_mining_effect"),action(){return!!Os($(this)[0])&&(t.space.elerium_ship={count:0,on:0},t.race.cataclysm&&Xc("iron_will",!1,2),!0)}},laser_mining:{id:"tech-laser_mining",title:F("tech_laser_mining"),desc:F("tech_laser_mining"),category:"space_mining",era:"deep_space",reqs:{asteroid:5,elerium:1,high_tech:9},grant:["asteroid",6],cost:{Knowledge:()=>35e4},effect:F("tech_laser_mining_effect"),action(){return!!Os($(this)[0])}},plasma_mining:{id:"tech-plasma_mining",title:F("tech_plasma_mining"),desc:F("tech_plasma_mining"),category:"space_mining",era:"interstellar",reqs:{asteroid:6,high_tech:13},grant:["asteroid",7],path:["standard","truepath"],cost:{Knowledge:()=>825e3},effect:F("tech_plasma_mining_effect"),action(){return!!Os($(this)[0])}},elerium_tech:{id:"tech-elerium_tech",title:F("tech_elerium_tech"),desc:F("tech_elerium_tech"),category:"space_mining",era:"deep_space",reqs:{asteroid:5},grant:["elerium",1],cost:{Knowledge:()=>275e3,Elerium:()=>20},effect:F("tech_elerium_tech_effect"),action(){return!!Os($(this)[0])}},elerium_reactor:{id:"tech-elerium_reactor",title:F("tech_elerium_reactor"),desc:F("tech_elerium_reactor"),category:"power_generation",era:"deep_space",reqs:{dwarf:1,elerium:1},grant:["elerium",2],cost:{Knowledge:()=>325e3,Elerium:()=>180},effect:F("tech_elerium_reactor_effect"),action(){return!!Os($(this)[0])&&(t.space.e_reactor={count:0,on:0},!0)}},neutronium_housing:{id:"tech-neutronium_housing",title:F("tech_neutronium_housing"),desc:F("tech_neutronium_housing"),category:"housing",era:"deep_space",reqs:{gas_moon:1},grant:["space_housing",1],cost:{Knowledge:()=>275e3,Neutronium:()=>350},effect:()=>F("tech_neutronium_housing_effect",[Xt().red]),action(){return!!Os($(this)[0])}},unification:{id:"tech-unification",title:F("tech_unification"),desc:()=>F("tech_unification_desc",[di[t.race.species].home]),category:"special",era:"early_space",path:["standard"],reqs:{mars:2},grant:["unify",1],cost:{Knowledge:()=>2e5},effect:F("tech_unification_effect"),action(){return!!Os($(this)[0])}},unification2:{id:"tech-unification2",title:F("tech_unification"),desc:()=>F("tech_unification_desc",[di[t.race.species].home]),category:"special",era:"early_space",path:["standard"],reqs:{unify:1},grant:["unify",2],cost:{Bool(){let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].buy||t.civic.foreign[`gov${a}`].anx)&&e++;return 3===e}},effect(){let e=t.race.banana?`
          ${F("tech_unification_banana")}
          `:"";return`
          ${F("tech_unification_effect2")}
          ${F("tech_unification_warning")}
          ${e}`},action(){return!!Os($(this)[0])&&(t.race.banana&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),delete t.race.banana),t.civic.foreign.gov0.occ&&t.civic.foreign.gov1.occ&&t.civic.foreign.gov2.occ&&Xc("world_domination"),t.civic.foreign.gov0.anx&&t.civic.foreign.gov1.anx&&t.civic.foreign.gov2.anx&&Xc("illuminati"),t.civic.foreign.gov0.buy&&t.civic.foreign.gov1.buy&&t.civic.foreign.gov2.buy&&Xc("syndicate"),0===t.stats.attacks&&Xc("pacifist"),Hr(),!0)}},unite:{id:"tech-unite",title:F("tech_unite"),desc:()=>F("tech_unite_desc"),category:"special",era:"globalized",path:["truepath"],reqs:{unify:1},grant:["unify",2],cost:{Bool(){let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].buy||t.civic.foreign[`gov${a}`].anx)&&e++;return 3===e}},effect:()=>`
          ${F("tech_unite_effect")}
          ${F("tech_unification_effect2")}
          `,action(){return!!Os($(this)[0])&&(t.race.banana&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),delete t.race.banana),t.civic.foreign.gov0.occ&&t.civic.foreign.gov1.occ&&t.civic.foreign.gov2.occ&&Xc("world_domination"),t.civic.foreign.gov0.anx&&t.civic.foreign.gov1.anx&&t.civic.foreign.gov2.anx&&Xc("illuminati"),t.civic.foreign.gov0.buy&&t.civic.foreign.gov1.buy&&t.civic.foreign.gov2.buy&&Xc("syndicate"),0===t.stats.attacks&&Xc("pacifist"),Hr(),t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,Di(F("civics_rival_unlocked",[ee(3)]),"info",!1,["progress","combat"])),!0)}},genesis:{id:"tech-genesis",title:F("tech_genesis"),desc:F("tech_genesis"),category:"special",era:"deep_space",reqs:{high_tech:10,genesis:1},grant:["genesis",2],cost:{Knowledge:()=>35e4},effect:F("tech_genesis_effect"),action(){return!!Os($(this)[0])}},star_dock:{id:"tech-star_dock",title:F("tech_star_dock"),desc:F("tech_star_dock"),category:"special",era:"deep_space",reqs:{genesis:2,space:5,high_tech:10},grant:["genesis",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>38e4},effect:F("tech_star_dock_effect"),action(){return!!Os($(this)[0])&&(t.space.star_dock={count:0,ship:0,probe:0,template:t.race.species},!0)}},interstellar:{id:"tech-interstellar",title:F("tech_interstellar"),desc:F("tech_interstellar"),category:"space_exploration",era:"deep_space",reqs:{genesis:3},grant:["genesis",4],cost:{Knowledge:()=>4e5},effect:F("tech_interstellar_effect"),action(){return!!Os($(this)[0])&&(t.starDock.probes={count:0},!0)}},genesis_ship:{id:"tech-genesis_ship",title:()=>t.race.cataclysm?F("tech_generational_ship"):F("tech_genesis_ship"),desc:()=>t.race.cataclysm?F("tech_generational_ship"):F("tech_genesis_ship"),category:"special",era:"deep_space",reqs:{genesis:4},grant:["genesis",5],cost:{Knowledge:()=>425e3},effect:()=>t.race.cataclysm?F("tech_generational_effect"):F("tech_genesis_ship_effect"),action(){return!!Os($(this)[0])&&(t.starDock.seeder={count:0},t.race.cataclysm&&Xc("iron_will",!1,4),!0)}},geck:{id:"tech-geck",title:()=>F("tech_geck"),desc:()=>F("tech_geck_desc"),category:"special",era:"deep_space",reqs:{genesis:5},grant:["geck",1],condition:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5),cost:{Knowledge:()=>5e5},effect:()=>F("tech_geck_effect"),action(){return!!Os($(this)[0])&&(t.starDock.geck={count:0},!0)}},genetic_decay:{id:"tech-genetic_decay",title:F("tech_genetic_decay"),desc:F("tech_genetic_decay"),category:"genes",era:"early_space",reqs:{decay:1},grant:["decay",2],cost:{Knowledge:()=>2e5},effect:F("tech_genetic_decay_effect"),action(){return!!Os($(this)[0])}},stabilize_decay:{id:"tech-stabilize_decay",title:F("tech_stabilize_decay"),desc:F("tech_stabilize_decay"),category:"genes",era:"dimensional",reqs:{decay:2,high_tech:18},grant:["decay",3],cost:{Knowledge:()=>5e7,Blood_Stone:()=>1},effect:F("tech_stabilize_decay_effect"),action(){return!!Os($(this)[0])}},tachyon:{id:"tech-tachyon",title:F("tech_tachyon"),desc:F("tech_tachyon"),category:"progress",era:"interstellar",reqs:{wsc:1},grant:["ftl",1],cost:{Knowledge:()=>435e3},effect:F("tech_tachyon_effect"),action(){return!!Os($(this)[0])}},warp_drive:{id:"tech-warp_drive",title:F("tech_warp_drive"),desc:F("tech_warp_drive"),category:"space_exploration",era:"interstellar",reqs:{ftl:1},grant:["ftl",2],cost:{Knowledge:()=>45e4},effect:F("tech_warp_drive_effect"),action(){return!!Os($(this)[0])&&(t.settings.showDeep=!0,t.settings.space.alpha=!0,t.interstellar.starport={count:0,on:0,support:0,s_max:0},!0)}},habitat:{id:"tech-habitat",title:F("tech_habitat"),desc:F("tech_habitat_desc"),category:"housing",era:"interstellar",reqs:{alpha:2,droids:1},grant:["alpha",3],cost:{Knowledge:()=>48e4},effect:F("tech_habitat_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.habitat={count:0,on:0},!0)}},graphene:{id:"tech-graphene",title:F("tech_graphene"),desc:F("tech_graphene"),category:"crafting",era:"interstellar",reqs:{alpha:3,infernite:1},grant:["graphene",1],cost:{Knowledge:()=>54e4,Adamantite:()=>1e4},effect:F("tech_graphene_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},!0)}},aerogel:{id:"tech-aerogel",title:F("tech_aerogel"),desc:F("tech_aerogel"),category:"crafting",era:"interstellar",reqs:{graphene:1,science:13},grant:["aerogel",1],cost:{Knowledge:()=>75e4,Graphene:()=>5e4,Infernite:()=>500},effect:F("tech_aerogel_effect"),action(){return!!Os($(this)[0])&&(t.resource.Aerogel.display=!0,ha(),!0)},post(){zi()}},mega_manufacturing:{id:"tech-mega_manufacturing",title:F("tech_mega_manufacturing"),desc:F("tech_mega_manufacturing"),category:"crafting",era:"intergalactic",reqs:{high_tech:16,alpha:3},grant:["alpha",4],cost:{Knowledge:()=>565e4},effect:()=>F("tech_mega_manufacturing_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.int_factory={count:0,on:0},!0)}},luxury_condo:{id:"tech-luxury_condo",title:F("tech_luxury_condo"),desc:F("tech_luxury_condo"),category:"housing",era:"intergalactic",reqs:{high_tech:17,alpha:4},grant:["alpha",5],cost:{Knowledge:()=>15e6},effect:()=>F("tech_luxury_condo_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.luxury_condo={count:0,on:0},!0)}},stellar_engine:{id:"tech-stellar_engine",title:F("tech_stellar_engine"),desc:F("tech_stellar_engine"),category:"stellar_engine",era:"interstellar",reqs:{blackhole:2},grant:["blackhole",3],cost:{Knowledge:()=>1e6},effect:F("tech_stellar_engine_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.stellar_engine={count:0,mass:8,exotic:0},!0)}},mass_ejector:{id:"tech-mass_ejector",title:F("tech_mass_ejector"),desc:F("tech_mass_ejector"),category:"stellar_engine",era:"interstellar",reqs:{blackhole:4},grant:["blackhole",5],cost:{Knowledge:()=>11e5},effect:F("tech_mass_ejector_effect"),action(){return!!Os($(this)[0])&&(t.interstellar.mass_ejector={count:0,on:0,total:0,mass:0,Food:0,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0},!0)}},asteroid_redirect:{id:"tech-asteroid_redirect",title:F("tech_asteroid_redirect"),desc:F("tech_asteroid_redirect"),category:"stellar_engine",era:"intergalactic",reqs:{blackhole:5,gateway:3},grant:["blackhole",6],cost:{Knowledge:()=>35e5},effect:F("tech_asteroid_redirect_effect"),action(){return!!Os($(this)[0])},post(){Oe("Physics")}},exotic_infusion:{id:"tech-exotic_infusion",title:F("tech_exotic_infusion"),desc:F("tech_exotic_infusion"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:1},grant:["whitehole",2],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect:()=>`
          ${F("tech_exotic_infusion_effect",[t.resource.Soul_Gem.name])}
          ${F("tech_exotic_infusion_effect2")}
          `,action(){return!!Cs($(this)[0])},flair:()=>F("tech_exotic_infusion_flair")},infusion_check:{id:"tech-infusion_check",title:F("tech_infusion_check"),desc:F("tech_infusion_check"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:2},grant:["whitehole",3],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect:()=>`
          ${F("tech_infusion_check_effect")}
          ${F("tech_exotic_infusion_effect2")}
          `,action(){return!!Cs($(this)[0])},flair:()=>F("tech_infusion_check_flair")},infusion_confirm:{id:"tech-infusion_confirm",title:F("tech_infusion_confirm"),desc:F("tech_infusion_confirm"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:3},grant:["whitehole",4],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect(){let e=mc("bigbang"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name"),r=`
          ${F("wiki_tech_infusion_confirm_gains",[e.plasmid,e.phage,e.dark,a])}
          `;return`
          ${F("tech_infusion_confirm_effect")}
          ${F("tech_exotic_infusion_effect2")}
          ${r}`},action(){if(Os($(this)[0])){if(t.tech.whitehole>=4)return;t.tech.whitehole=4;let a=$('
          ');return $("body").append(a),setTimeout((function(){a.addClass("burn")}),125),setTimeout((function(){a.addClass("b")}),150),setTimeout((function(){a.addClass("c")}),2e3),setTimeout((function(){!function(){switch(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"blackhole"}),Xc(`extinct_${t.race.species}`),t.race.universe){case"heavy":Xc("heavy");break;case"antimatter":Xc("canceled");break;case"evil":Xc("eviltwin");break;case"micro":Xc("microbang",!0);break;case"standard":Xc("whitehole")}t.space.hasOwnProperty("spaceport")&&0===t.space.spaceport.count&&Xc("red_dead"),Xc("squished",!0),"evil"===t.race.universe&&"angelic"===di[t.race.species].type&&eo("nephilim"),t.race.junker&&"junker"===t.race.species&&eo("the_misery"),t.race.decay&&Xc("dissipated"),t.race.steelen&&eo("steelem");let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=mc("bigbang");so(),t.stats.blackhole++,Fc(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),t.prestige.Dark.count=+(t.prestige.Dark.count+o.dark).toFixed(3),t.stats.dark=+(t.stats.dark+o.dark).toFixed(3),t.stats.universes++;let n=!!t.race.hasOwnProperty("srace")&&t.race.srace,l=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:"bigbang",seeded:!0,bigbang:!0,probes:4,seed:Math.floor(m(1e4)),ascended:!1},l>0&&(t.race.corruption=l),n&&(t.race.srace=n),Q({orbit:s,biome:i,ptrait:c,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),4e3),!1}return!1},flair:()=>F("tech_infusion_confirm_flair")},stabilize_blackhole:{id:"tech-stabilize_blackhole",title:F("tech_stabilize_blackhole"),desc:()=>`
          ${F("tech_stabilize_blackhole")}
          ${F("tech_stabilize_blackhole2")}
          `,category:"stellar_engine",era:"interstellar",reqs:{whitehole:1},grant:["stablized",1],cost:{Knowledge:()=>15e5,Neutronium:()=>2e4},effect:F("tech_stabilize_blackhole_effect"),action(){if(Os($(this)[0])){if(t.interstellar.stellar_engine.mass+=2e4*Va.Neutronium/1e10,t.interstellar.stellar_engine.mass+=40*t.interstellar.stellar_engine.exotic,t.interstellar.stellar_engine.exotic=0,delete t.tech.whitehole,t.race.banana&&t.interstellar.stellar_engine.mass>=12){let e=Yc();t.stats.banana.b3[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b3.l=!0)}return!0}return!1}},veil:{id:"tech-veil",title:F("tech_veil"),desc:F("tech_veil"),category:"magic",era:"interstellar",reqs:{blackhole:2},condition:()=>"magic"===t.race.universe,grant:["veil",1],cost:{Knowledge:()=>125e4},effect:F("tech_veil_effect"),action(){return!!Os($(this)[0])}},mana_syphon:{id:"tech-mana_syphon",title:F("tech_mana_syphon"),desc:F("tech_mana_syphon"),category:"magic",era:"interstellar",reqs:{veil:1},condition:()=>"magic"===t.race.universe,grant:["veil",2],cost:{Knowledge:()=>15e5},effect:F("tech_mana_syphon_effect"),action(){return!!Os($(this)[0])},post(){Oe("Physics")}},gravitational_waves:{id:"tech-gravitational_waves",title:F("tech_gravitational_waves"),desc:F("tech_gravitational_waves"),category:"power_generation",era:"interstellar",reqs:{blackhole:4},grant:["gravity",1],cost:{Knowledge:()=>125e4},effect:F("tech_gravitational_waves_effect"),action(){return!!Os($(this)[0])}},gravity_convection:{id:"tech-gravity_convection",title:F("tech_gravity_convection"),desc:F("tech_gravity_convection"),category:"power_generation",era:"interstellar",reqs:{gravity:1},grant:["gravity",2],cost:{Knowledge:()=>135e4},effect:F("tech_gravity_convection_effect"),action(){return!!Os($(this)[0])}},wormholes:{id:"tech-wormholes",title:F("tech_wormholes"),desc:F("tech_wormholes"),category:"space_exploration",era:"intergalactic",reqs:{gravity:1,science:15},grant:["stargate",1],cost:{Knowledge:()=>225e4},effect:F("tech_wormholes_effect"),action(){return!!Os($(this)[0])}},portal:{id:"tech-portal",title:F("tech_portal"),desc:F("tech_portal_desc"),category:"hell_dimension",era:"interstellar",reqs:{wsc:1},grant:["portal",1],cost:{Knowledge:()=>5e5},effect:F("tech_portal_effect"),action(){return!!Os($(this)[0])}},fortifications:{id:"tech-fortifications",title:F("tech_fort"),desc:F("tech_fort_desc"),category:"hell_dimension",era:"interstellar",reqs:{portal:1},grant:["portal",2],cost:{Knowledge:()=>55e4,Stone:()=>1e6},effect:F("tech_fort_effect"),action(){return!!Os($(this)[0])&&(t.settings.showPortal=!0,t.settings.portal.fortress=!0,t.settings.msgFilters.hell.unlocked||(t.settings.msgFilters.hell.unlocked=!0,t.settings.msgFilters.hell.vis=!0),t.portal.fortress={threat:1e4,garrison:0,walls:100,repair:0,patrols:0,patrol_size:10,siege:999,notify:"Yes",s_ntfy:"Yes",nocrew:!1},t.portal.turret={count:0,on:0},t.portal.carport={count:0,damaged:0,repair:0},"demonic"===di[t.race.species].type?Xc("blood_war"):Xc("pandemonium"),t.portal.observe={settings:{expanded:!1,average:!1,hyperSlow:!1,display:"game_days",dropKills:!0,dropGems:!0},stats:{total:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}},period:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}}},graphID:0,graphs:{}},!0)},post(){Ga()}},war_drones:{id:"tech-war_drones",title:F("tech_war_drones"),desc:F("tech_war_drones"),category:"hell_dimension",era:"interstellar",reqs:{portal:2,graphene:1},grant:["portal",3],cost:{Knowledge:()=>7e5},effect:F("tech_war_drones_effect"),action(){return!!Os($(this)[0])&&(t.settings.portal.badlands=!0,t.portal.war_drone={count:0,on:0},!0)}},demon_attractor:{id:"tech-demon_attractor",title:F("tech_demon_attractor"),desc:F("tech_demon_attractor"),category:"hell_dimension",era:"interstellar",reqs:{portal:3,stanene:1},grant:["portal",4],cost:{Knowledge:()=>745e3},effect:F("tech_demon_attractor_effect"),action(){return!!Os($(this)[0])&&(t.portal.attractor={count:0,on:0},!0)}},combat_droids:{id:"tech-combat_droids",title:F("tech_combat_droids"),desc:F("tech_combat_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:4},grant:["portal",5],cost:{Knowledge:()=>762e3,Soul_Gem:()=>1},effect:F("tech_combat_droids_effect"),action(){return!!Os($(this)[0])&&(t.portal.war_droid={count:0,on:0},!0)},flair:()=>F("tech_combat_droids_flair")},repair_droids:{id:"tech-repair_droids",title:F("tech_repair_droids"),desc:F("tech_repair_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:5},grant:["portal",6],cost:{Knowledge:()=>794e3,Soul_Gem:()=>1},effect:F("tech_repair_droids_effect"),action(){return!!Os($(this)[0])&&(t.portal.repair_droid={count:0,on:0},!0)}},advanced_predators:{id:"tech-advanced_predators",title:F("tech_advanced_predators"),desc:F("tech_advanced_predators"),category:"hell_dimension",era:"intergalactic",reqs:{portal:6,xeno:4},grant:["portal",7],cost:{Knowledge:()=>5e6,Bolognium:()=>5e5,Vitreloy:()=>25e4},effect:F("tech_advanced_predators_effect"),action(){return!!Os($(this)[0])}},enhanced_droids:{id:"tech-enhanced_droids",title:F("tech_enhanced_droids"),desc:F("tech_enhanced_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:5,military:9},grant:["hdroid",1],cost:{Knowledge:()=>105e4},effect:F("tech_enhanced_droids_effect"),action(){return!!Os($(this)[0])}},sensor_drone:{id:"tech-sensor_drone",title:F("tech_sensor_drone"),desc:F("tech_sensor_drone"),category:"hell_dimension",era:"interstellar",reqs:{portal:3,infernite:1,stanene:1,graphene:1},grant:["infernite",2],cost:{Knowledge:()=>725e3},effect:F("tech_sensor_drone_effect"),action(){return!!Os($(this)[0])&&(t.portal.sensor_drone={count:0,on:0},!0)}},map_terrain:{id:"tech-map_terrain",title:F("tech_map_terrain"),desc:F("tech_map_terrain"),category:"hell_dimension",era:"interstellar",reqs:{infernite:2},grant:["infernite",3],cost:{Knowledge:()=>948e3},effect:()=>F("tech_map_terrain_effect"),action(){return!!Os($(this)[0])}},calibrated_sensors:{id:"tech-calibrated_sensors",title:F("tech_calibrated_sensors"),desc:F("tech_calibrated_sensors"),category:"hell_dimension",era:"interstellar",reqs:{infernite:3},grant:["infernite",4],cost:{Knowledge:()=>1125e3,Infernite:()=>3500},effect:()=>F("tech_calibrated_sensors_effect"),action(){return!!Os($(this)[0])}},shield_generator:{id:"tech-shield_generator",title:F("tech_shield_generator"),desc:F("tech_shield_generator"),category:"hell_dimension",era:"intergalactic",reqs:{high_tech:14,gateway:3,infernite:4},grant:["infernite",5],cost:{Knowledge:()=>268e4,Bolognium:()=>75e3},effect:()=>F("tech_shield_generator_effect"),action(){return!!Os($(this)[0])}},enhanced_sensors:{id:"tech-enhanced_sensors",title:F("tech_enhanced_sensors"),desc:F("tech_enhanced_sensors"),category:"hell_dimension",era:"intergalactic",reqs:{infernite:5,xeno:4},grant:["infernite",6],cost:{Knowledge:()=>475e4,Vitreloy:()=>25e3},effect:()=>F("tech_enhanced_sensors_effect"),action(){return!!Os($(this)[0])}},xeno_linguistics:{id:"tech-xeno_linguistics",title:F("tech_xeno_linguistics"),desc:F("tech_xeno_linguistics"),category:"andromeda",era:"intergalactic",reqs:{xeno:1},grant:["xeno",2],cost:{Knowledge:()=>3e6},effect:()=>F("tech_xeno_linguistics_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.gorddon=!0,!0)}},xeno_culture:{id:"tech-xeno_culture",title:F("tech_xeno_culture"),desc:F("tech_xeno_culture"),category:"progress",era:"intergalactic",reqs:{xeno:3},grant:["xeno",4],cost:{Knowledge:()=>34e5},effect:()=>F("tech_xeno_culture_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name,di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].entity]),action(){return!!Os($(this)[0])&&(t.galaxy.embassy={count:0,on:0},!0)}},cultural_exchange:{id:"tech-cultural_exchange",title:F("tech_cultural_exchange"),desc:F("tech_cultural_exchange"),category:"andromeda",era:"intergalactic",reqs:{xeno:5},grant:["xeno",6],cost:{Knowledge:()=>355e4},effect:()=>F("tech_cultural_exchange_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!Os($(this)[0])&&(t.galaxy.symposium={count:0,on:0},t.galaxy.dormitory={count:0,on:0},!0)}},shore_leave:{id:"tech-shore_leave",title:F("tech_shore_leave"),desc:F("tech_shore_leave"),category:"science",era:"intergalactic",reqs:{andromeda:3,xeno:6},grant:["xeno",7],cost:{Knowledge:()=>46e5},effect:()=>F("tech_shore_leave_effect"),action(){return!!Os($(this)[0])}},xeno_gift:{id:"tech-xeno_gift",title:F("tech_xeno_gift"),desc:F("tech_xeno_gift"),category:"andromeda",era:"intergalactic",reqs:{high_tech:16,xeno:7},grant:["xeno",8],cost:{Knowledge:()=>65e5,Infernite:()=>125e3},effect:()=>F("tech_xeno_gift_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.consulate={count:0},t.settings.space.alien1=!0,Di(F("tech_xeno_gift_msg",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),"info",!1,["progress"]),!0)}},industrial_partnership:{id:"tech-industrial_partnership",title:F("tech_industrial_partnership"),desc:()=>F("tech_industrial_partnership"),category:"andromeda",era:"intergalactic",reqs:{xeno:9},grant:["xeno",10],cost:{Knowledge:()=>725e4},effect:()=>F("tech_industrial_partnership_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!Os($(this)[0])&&(t.galaxy.vitreloy_plant={count:0,on:0},!0)}},embassy_housing:{id:"tech-embassy_housing",title:F("tech_embassy_housing"),desc:()=>F("tech_embassy_housing"),category:"andromeda",era:"intergalactic",reqs:{xeno:10,science:18},grant:["xeno",11],cost:{Knowledge:()=>1075e4},effect:()=>F("tech_embassy_housing_effect",[di[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!Os($(this)[0])}},advanced_telemetry:{id:"tech-advanced_telemetry",title:F("tech_advanced_telemetry"),desc:F("tech_advanced_telemetry"),category:"science",era:"intergalactic",reqs:{xeno:5},grant:["telemetry",1],cost:{Knowledge:()=>42e5,Vitreloy:()=>1e4},effect:()=>F("tech_advanced_telemetry_effect"),action(){return!!Os($(this)[0])}},defense_platform:{id:"tech-defense_platform",title:F("galaxy_defense_platform"),desc:F("galaxy_defense_platform"),category:"andromeda",era:"intergalactic",reqs:{stargate:5,piracy:1},grant:["stargate",6],cost:{Knowledge:()=>485e4},effect:F("tech_defense_platform_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.defense_platform={count:0,on:0},!0)}},scout_ship:{id:"tech-scout_ship",title:F("galaxy_scout_ship"),desc:F("galaxy_scout_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{gateway:3},grant:["andromeda",1],cost:{Knowledge:()=>26e5},effect:()=>F("tech_scout_ship_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.scout_ship={count:0,on:0,crew:0,mil:0},!0)}},corvette_ship:{id:"tech-corvette_ship",title:F("galaxy_corvette_ship"),desc:F("galaxy_corvette_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:1,xeno:1},grant:["andromeda",2],cost:{Knowledge:()=>32e5},effect:()=>F("tech_corvette_ship_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.corvette_ship={count:0,on:0,crew:0,mil:0},!0)}},frigate_ship:{id:"tech-frigate_ship",title:F("galaxy_frigate_ship"),desc:F("galaxy_frigate_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:2,xeno:6},grant:["andromeda",3],cost:{Knowledge:()=>4e6},effect:()=>F("tech_frigate_ship_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.frigate_ship={count:0,on:0,crew:0,mil:0},Rt(),!0)}},cruiser_ship:{id:"tech-cruiser_ship",title:F("galaxy_cruiser_ship"),desc:F("galaxy_cruiser_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:3,xeno:10},grant:["andromeda",4],cost:{Knowledge:()=>75e5},effect:()=>F("tech_cruiser_ship_effect",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),action(){return!!Os($(this)[0])&&(t.galaxy.cruiser_ship={count:0,on:0,crew:0,mil:0},t.galaxy.foothold={count:0,on:0,support:0,s_max:0},t.settings.space.alien2=!0,Rt(),!0)}},dreadnought:{id:"tech-dreadnought",title:F("galaxy_dreadnought"),desc:F("galaxy_dreadnought"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:4,science:18},grant:["andromeda",5],cost:{Knowledge:()=>1e7},effect:()=>F("tech_dreadnought_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.dreadnought={count:0,on:0,crew:0,mil:0},Rt(),!0)}},ship_dock:{id:"tech-ship_dock",title:F("galaxy_ship_dock"),desc:F("galaxy_ship_dock"),category:"andromeda_ships",era:"intergalactic",reqs:{gateway:3,xeno:6},grant:["gateway",4],cost:{Knowledge:()=>39e5},effect:()=>F("tech_ship_dock_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.ship_dock={count:0,on:0},!0)}},ore_processor:{id:"tech-ore_processor",title:F("galaxy_ore_processor"),desc:F("galaxy_ore_processor"),category:"space_mining",era:"intergalactic",reqs:{conflict:2},grant:["conflict",3],cost:{Knowledge:()=>75e5},effect:()=>F("tech_ore_processor_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.ore_processor={count:0,on:0},!0)}},scavenger:{id:"tech-scavenger",title:F("galaxy_scavenger"),desc:F("galaxy_scavenger"),category:"science",era:"intergalactic",reqs:{conflict:3},grant:["conflict",4],cost:{Knowledge:()=>8e6},effect:()=>F("tech_scavenger_effect",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),action(){return!!Os($(this)[0])&&(t.galaxy.scavenger={count:0,on:0,crew:0},!0)}},coordinates:{id:"tech-coordinates",title:F("tech_coordinates"),desc:F("tech_coordinates"),category:"andromeda",era:"intergalactic",reqs:{science:18,conflict:5},grant:["chthonian",1],cost:{Knowledge:()=>1e7},effect:()=>F("tech_coordinates_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.minelayer={count:0,on:0,crew:0,mil:0},t.settings.space.chthonian=!0,!0)}},chthonian_survey:{id:"tech-chthonian_survey",title:F("tech_chthonian_survey"),desc:F("tech_chthonian_survey"),category:"space_mining",era:"intergalactic",reqs:{chthonian:2},grant:["chthonian",3],cost:{Knowledge:()=>118e5},effect:()=>F("tech_chthonian_survey_effect"),action(){return!!Os($(this)[0])&&(t.resource.Orichalcum.display=!0,t.galaxy.excavator={count:0,on:0},t.galaxy.raider={count:0,on:0,crew:0,mil:0},Di(F("tech_chthonian_survey_result"),"info",!1,["progress"]),!0)},post(){zi()}},gateway_depot:{id:"tech-gateway_depot",title:F("galaxy_gateway_depot"),desc:F("galaxy_gateway_depot"),category:"storage",era:"intergalactic",reqs:{gateway:4},grant:["gateway",5],cost:{Knowledge:()=>435e4},effect:()=>F("tech_gateway_depot_effect"),action(){return!!Os($(this)[0])&&(t.galaxy.gateway_depot={count:0,on:0},!0)}},soul_forge:{id:"tech-soul_forge",title:F("portal_soul_forge_title"),desc:F("portal_soul_forge_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:3},grant:["hell_pit",4],cost:{Knowledge:()=>275e4},effect:()=>F("tech_soul_forge_effect"),action(){return!!Os($(this)[0])&&(t.portal.soul_forge={count:0,on:0,kills:0},!0)}},soul_attractor:{id:"tech-soul_attractor",title:F("portal_soul_attractor_title"),desc:F("portal_soul_attractor_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:4,high_tech:16},grant:["hell_pit",5],cost:{Knowledge:()=>55e5},effect:()=>F("tech_soul_attractor_effect"),action(){return!!Os($(this)[0])&&(t.portal.soul_attractor={count:0,on:0},!0)}},soul_absorption:{id:"tech-soul_absorption",title:F("tech_soul_absorption"),desc:F("tech_soul_absorption"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:5},grant:["hell_pit",6],cost:{Knowledge:()=>6e6,Infernite:()=>25e4},effect:()=>F("tech_soul_absorption_effect"),action(){return!!Os($(this)[0])}},soul_link:{id:"tech-soul_link",title:F("tech_soul_link"),desc:F("tech_soul_link"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:6},grant:["hell_pit",7],cost:{Knowledge:()=>75e5,Vitreloy:()=>25e4},effect:()=>F("tech_soul_link_effect"),action(){return!!Os($(this)[0])}},gun_emplacement:{id:"tech-gun_emplacement",title:F("portal_gun_emplacement_title"),desc:F("portal_gun_emplacement_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:4},grant:["hell_gun",1],cost:{Knowledge:()=>3e6},effect:()=>F("tech_gun_emplacement_effect"),action(){return!!Os($(this)[0])&&(t.portal.gun_emplacement={count:0,on:0},!0)}},advanced_emplacement:{id:"tech-advanced_emplacement",title:F("tech_advanced_emplacement"),desc:F("tech_advanced_emplacement"),category:"hell_dimension",era:"intergalactic",reqs:{hell_gun:1,high_tech:17},grant:["hell_gun",2],cost:{Knowledge:()=>125e5,Orichalcum:()=>18e4},effect:()=>F("tech_advanced_emplacement_effect"),action(){return!!Os($(this)[0])}},dial_it_to_11:{id:"tech-dial_it_to_11",title:F("tech_dial_it_to_11"),desc:F("tech_dial_it_to_11"),category:"science",wiki:!1,era:"deep_space",reqs:{quaked:1},grant:["quaked",2],cost:{Knowledge:()=>5e5},condition:()=>!(t.race.sludge&&!t.race.cataclysm),effect(){let e=mc("cataclysm"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
          ${F("tech_dial_it_to_11_effect",[Xt().dwarf,t.race.cataclysm?Xt().red:di[t.race.species].home])}
          ${F("tech_dial_it_to_11_effect2")}
          ${F("star_dock_genesis_effect2",[e.plasmid,a])}
          ${F("star_dock_genesis_effect3",[e.phage])}
          `},action(){return!!Os($(this)[0])&&($("#main").addClass("earthquake"),setTimeout((function(){$("#main").removeClass("earthquake"),function(){if(t.city.ptrait.includes("unstable")&&t.tech.quaked){M.w&&M.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),Zi("reset",{end:"cataclysm"}),O();let a=mc("cataclysm");t.stats.cataclysm++,Fc(),t.prestige.Phage.count+=a.phage,t.stats.phage+=a.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=a.plasmid,t.stats.antiplasmid+=a.plasmid):(t.prestige.Plasmid.count+=a.plasmid,t.stats.plasmid+=a.plasmid),Xc("squished",!0),Xc(`extinct_${t.race.species}`),"hellscape"===t.city.biome&&"demonic"!==di[t.race.species].type&&eo("take_no_advice"),so(),Xc("shaken"),t.race.cataclysm&&Xc("failed_history");let r=!!t.race.hasOwnProperty("srace")&&t.race.srace,s=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:t.race.species,gods:t.race.gods,old_gods:t.race.old_gods,universe:t.race.universe,seeded:!1,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},s>0&&(t.race.corruption=s),r&&(t.race.srace=r),Q({orbit:t.city.calendar.orbit,biome:t.city.biome,ptrait:t.city.ptrait,geology:t.city.geology}),"antimatter"===t.race.universe?t.race.weak_mastery=1:t.race.no_plasmid=1;let i=["crispr","trade","craft"];for(let e=0;eF("tech_dial_it_to_11_flair")},limit_collider:{id:"tech-limit_collider",title:F("tech_limit_collider"),desc:F("tech_limit_collider"),category:"science",wiki:!1,era:"deep_space",reqs:{quaked:1},grant:["quaked",2],cost:{Knowledge:()=>5e5},effect:()=>F("tech_limit_collider_effect"),action(){return!!Os($(this)[0])}},mana:{id:"tech-mana",title:F("tech_mana"),desc:F("tech_mana"),category:"magic",era:"civilized",reqs:{primitive:3},grant:["magic",1],condition:()=>"magic"===t.race.universe,cost:{Knowledge:()=>25},effect:()=>F("tech_mana_effect"),action(){return!!Os($(this)[0])&&(t.resource.Mana.display=!0,t.resource.Crystal.display=!0,t.civic.crystal_miner.display=!0,t.race.witch_hunter&&(t.resource.Sus.display=!0),!0)},flair:F("tech_mana_flair"),post(){zi()}},ley_lines:{id:"tech-ley_lines",title:F("tech_ley_lines"),desc:F("tech_ley_lines"),category:"magic",era:"civilized",reqs:{magic:1},grant:["magic",2],condition:()=>"magic"===t.race.universe,cost:{Knowledge:()=>40},effect:()=>F("tech_ley_lines_effect"),action(){return!!Os($(this)[0])&&(t.tech.isolation?t.tauceti.pylon={count:0}:t.race.cataclysm||t.race.orbit_decayed?t.space.pylon={count:0}:t.city.pylon={count:0},!0)}},rituals:{id:"tech-rituals",title:F("tech_rituals"),desc:F("tech_rituals"),category:"magic",era:"civilized",reqs:{magic:2},grant:["magic",3],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>25,Knowledge:()=>750,Crystal:()=>50},effect:()=>F("tech_rituals_effect"),action(){return!!Os($(this)[0])&&(t.race.casting={farmer:0,miner:0,lumberjack:0,science:0,factory:0,army:0,hunting:0,crafting:0,total:0},t.settings.showIndustry=!0,!0)},post(){Ws()}},crafting_ritual:{id:"tech-crafting_ritual",title:F("tech_crafting_ritual"),desc:F("tech_crafting_ritual"),category:"magic",era:"discovery",reqs:{magic:3,foundry:5},grant:["magic",4],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>100,Knowledge:()=>15e3,Crystal:()=>2500},effect:()=>F("tech_crafting_ritual_effect"),action(){return!!Os($(this)[0])&&(t.race.casting.crafting=0,!0)},post(){Ws()}},mana_nexus:{id:"tech-mana_nexus",title:F("tech_mana_nexus"),desc:F("tech_mana_nexus"),category:"magic",era:"early_space",reqs:{magic:4,space:3,luna:1},grant:["magic",5],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>500,Knowledge:()=>16e4,Crystal:()=>2500},effect:()=>F("tech_mana_nexus_effect"),action(){return!!Os($(this)[0])},post(){Oe("Physics")}},clerics:{id:"tech-clerics",title:F("tech_clerics"),desc:F("tech_clerics"),category:"magic",era:"civilized",reqs:{magic:3},grant:["cleric",1],condition:()=>!!("magic"===t.race.universe&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display),cost:{Mana:()=>100,Knowledge:()=>2e3,Crystal:()=>100},effect:()=>F("tech_clerics_effect"),action(){return!!Os($(this)[0])}},conjuring:{id:"tech-conjuring",title:F("tech_conjuring"),desc:F("tech_conjuring_desc"),category:"magic",era:"civilized",reqs:{magic:1},grant:["conjuring",1],not_trait:["cataclysm"],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>2,Crystal:()=>5},effect:()=>F("tech_conjuring_effect"),action(){return!!Os($(this)[0])}},res_conjuring:{id:"tech-res_conjuring",title:F("tech_res_conjuring"),desc:F("tech_res_conjuring"),category:"magic",era:"civilized",reqs:{conjuring:1},grant:["conjuring",2],not_trait:["cataclysm"],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>5,Crystal:()=>10},effect:()=>F("tech_res_conjuring_effect"),action(){return!!Os($(this)[0])}},alchemy:{id:"tech-alchemy",title:F("tech_alchemy"),desc:F("tech_alchemy"),category:"magic",era:"discovery",reqs:{magic:3,high_tech:1},grant:["alchemy",1],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>100,Knowledge:()=>1e4,Crystal:()=>250},effect:()=>F("tech_alchemy_effect"),action(){return!!Os($(this)[0])&&(t.race.alchemy={Food:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0},t.settings.showAlchemy=!0,!0)},post(){rc($("#resources")),rr(),t.settings.tabLoad&&ar("alchemy")}},transmutation:{id:"tech-transmutation",title:F("tech_transmutation"),desc:F("tech_transmutation"),category:"magic",era:"intergalactic",reqs:{alchemy:1,high_tech:16},grant:["alchemy",2],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>1250,Knowledge:()=>55e5,Crystal:()=>1e6},effect:()=>F("tech_transmutation_effect"),action(){return!!Os($(this)[0])},post(){rc($("#resources")),rr()}},secret_society:{id:"tech-secret_society",title:F("tech_secret_society"),desc:F("tech_secret_society"),category:"magic",era:"civilized",reqs:{magic:1},grant:["roguemagic",1],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>10,Knowledge:()=>45},effect:()=>F("tech_secret_society_effect"),action(){return!!Os($(this)[0])}},cultists:{id:"tech-cultists",title:F("tech_cultists"),desc:F("tech_cultists"),category:"magic",era:"civilized",reqs:{roguemagic:1,cleric:1},grant:["roguemagic",2],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>250,Knowledge:()=>2125},effect:()=>F("tech_cultists_effect"),action(){return!!Os($(this)[0])}},conceal_ward:{id:"tech-conceal_ward",title:F("tech_conceal_ward"),desc:F("tech_conceal_ward"),category:"magic",era:"discovery",reqs:{roguemagic:2,theatre:3},grant:["roguemagic",3],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>500,Knowledge:()=>8200,Crystal:()=>1e3},effect:()=>F("tech_conceal_ward_effect"),action(){return!!Os($(this)[0])&&(t.city.conceal_ward={count:0},t.space.conceal_ward={count:0},!0)}},subtle_rituals:{id:"tech-subtle_rituals",title:F("tech_subtle_rituals"),desc:F("tech_subtle_rituals"),category:"magic",era:"discovery",reqs:{roguemagic:3,magic:4},grant:["roguemagic",4],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>100,Knowledge:()=>15e3,Crystal:()=>2500},effect:()=>F("tech_subtle_rituals_effect"),action(){return!!Os($(this)[0])}},pylon_camouflage:{id:"tech-pylon_camouflage",title:F("tech_pylon_camouflage"),desc:F("tech_pylon_camouflage"),category:"magic",era:"industrialized",reqs:{roguemagic:4,high_tech:3},grant:["roguemagic",5],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>1e3,Knowledge:()=>3e4,Crystal:()=>3750},effect:()=>F("tech_pylon_camouflage_effect"),action(){return!!Os($(this)[0])}},fake_tech:{id:"tech-fake_tech",title:F("tech_fake_tech"),desc:F("tech_fake_tech"),category:"magic",era:"industrialized",reqs:{roguemagic:5,high_tech:4},grant:["roguemagic",6],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>2250,Knowledge:()=>6e4},effect:()=>F("tech_fake_tech_effect"),action(){return!!Os($(this)[0])}},concealment:{id:"tech-concealment",title:F("tech_concealment"),desc:F("tech_concealment"),category:"magic",era:"early_space",reqs:{roguemagic:6,magic:5},grant:["roguemagic",7],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>3e3,Knowledge:()=>185e3},effect:()=>F("tech_concealment_effect"),action(){return!!Os($(this)[0])}},improved_concealment:{id:"tech-improved_concealment",title:F("tech_improved_concealment"),desc:F("tech_improved_concealment"),category:"magic",era:"intergalactic",reqs:{roguemagic:7,forbidden:1},grant:["roguemagic",8],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>t.race.no_plasmid?6e3:25e3,Knowledge:()=>2e7},effect:()=>F("tech_improved_concealment_effect"),action(){return!!Os($(this)[0])}},outerplane_summon:{id:"tech-outerplane_summon",title:F("tech_outerplane_summon"),desc:F("tech_outerplane_summon"),category:"magic",era:"dimensional",reqs:{roguemagic:8,forbidden:4,hell_spire:10,b_stone:2,waygate:3},grant:["forbidden",5],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>t.race.no_plasmid?12e3:6e4,Knowledge:()=>6e7,Demonic_Essence:()=>1},effect:()=>F("tech_outerplane_summon_effect"),action(){return!!Os($(this)[0])}},dark_bomb:{id:"tech-dark_bomb",title:F("tech_dark_bomb"),desc:F("tech_dark_bomb"),category:"hell_dimension",era:"dimensional",reqs:{},reqs:{hell_spire:10,b_stone:2,waygate:2,sphinx_bribe:1},condition(){let e=Yc();return!!(t.stats.spire.hasOwnProperty(e)&&t.stats.spire[e].hasOwnProperty("dlstr")&&t.stats.spire[e].dlstr>0)},grant:["dl_reset",1],cost:{Knowledge:()=>65e6,Soul_Gem:()=>5e3,Blood_Stone:()=>25,Dark:()=>1,Supply:()=>1e6},effect:()=>F("tech_dark_bomb_effect"),action(){return!!Os($(this)[0])&&(t.portal.waygate.progress=100,t.portal.waygate.on=0,t.tech.waygate=3,t.resource.Demonic_Essence.display=!0,t.resource.Demonic_Essence.amount=1,!0)},flair:()=>F("tech_dark_bomb_flair")},bribe_sphinx:{id:"tech-bribe_sphinx",title:F("portal_sphinx_bribe"),desc:F("portal_sphinx_bribe"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:8},grant:["sphinx_bribe",1],cost:{Soul_Gem:()=>250,Supply:()=>5e5},effect:()=>F("tech_bribe_sphinx_effect"),action(){return!!Os($(this)[0])&&(t.resource.Codex.display=!0,t.resource.Codex.amount=1,Di(F("tech_bribe_sphinx_msg"),"info",!1,["progress","hell"]),!0)}},alien_biotech:{id:"tech-alien_biotech",title:F("tech_alien_biotech"),desc:F("tech_alien_biotech"),category:"science",era:"solar",reqs:{genetics:8,kuiper:1},grant:["biotech",1],path:["truepath"],cost:{Knowledge:()=>24e5,Orichalcum:()=>125e3,Cipher:()=>15e3},effect:()=>F(t.race.orbit_decayed?"tech_alien_biotech_effect_alt":"tech_alien_biotech_effect"),action(){return!!Os($(this)[0])}},zero_g_lab:{id:"tech-zero_g_lab",title:F("tech_zero_g_lab"),desc:F("tech_zero_g_lab"),category:"science",era:"solar",path:["truepath"],reqs:{high_tech:13,graphene:1,enceladus:2},grant:["enceladus",3],cost:{Knowledge:()=>9e5},effect:F("tech_zero_g_lab_effect"),action(){return!!Os($(this)[0])&&(t.space.zero_g_lab={count:0,on:0},!0)}},operating_base:{id:"tech-operating_base",title:F("tech_operating_base"),desc:F("tech_operating_base"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{enceladus:3,triton:1},grant:["enceladus",4],cost:{Knowledge:()=>14e5},effect:()=>F("tech_operating_base_effect",[Xt().enceladus]),action(){return!!Os($(this)[0])&&(t.space.operating_base={count:0,on:0},!0)}},munitions_depot:{id:"tech-munitions_depot",title:F("tech_munitions_depot"),desc:F("tech_munitions_depot"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{enceladus:4},grant:["enceladus",5],cost:{Knowledge:()=>15e5},effect:()=>F("tech_munitions_depot_effect"),action(){return!!Os($(this)[0])&&(t.space.munitions_depot={count:0},!0)}},fob:{id:"tech-fob",title:F("tech_fob"),desc:F("tech_fob"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{triton:1},grant:["triton",2],cost:{Knowledge:()=>145e4},effect:()=>F("tech_fob_effect",[Xt().triton]),action(){return!!Os($(this)[0])&&(t.space.fob={count:0,on:0,troops:0,enemy:0},t.space.lander={count:0,on:0},t.space.crashed_ship={count:0},!0)}},bac_tanks_tp:{id:"tech-bac_tanks_tp",title:F("tech_bac_tanks"),desc:F("tech_bac_tanks_desc"),category:"military",era:"solar",path:["truepath"],reqs:{medic:1,triton:2},grant:["medic",2],cost:{Knowledge:()=>175e4},effect:F("tech_bac_tanks_effect"),action(){return!!Os($(this)[0])}},medkit:{id:"tech-medkit",title:F("tech_medkit"),desc:F("tech_medkit"),category:"military",era:"solar",path:["truepath"],reqs:{medic:2,outer:4},grant:["medic",3],cost:{Knowledge:()=>225e4,Quantium:()=>25e4,Cipher:()=>8e3},effect:F("tech_medkit_effect"),action(){return!!Os($(this)[0])}},sam_site:{id:"tech-sam_site",title:F("tech_sam_site"),desc:F("tech_sam_site"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{titan:6,triton:1},grant:["titan",7],cost:{Knowledge:()=>1475e3},effect:()=>F("tech_sam_site_effect",[Xt().titan]),action(){return!!Os($(this)[0])&&(t.space.sam={count:0,on:0},!0)}},data_cracker:{id:"tech-data_cracker",title:F("tech_data_cracker"),desc:F("tech_data_cracker"),category:"science",era:"solar",path:["truepath"],reqs:{titan:7,kuiper:1},grant:["titan",8],cost:{Knowledge:()=>275e4,Cipher:()=>25e3},effect:()=>F("tech_data_cracker_effect",[t.resource.Cipher.name]),action(){return!!Os($(this)[0])&&(t.space.decoder={count:0,on:0},!0)}},ai_core_tp:{id:"tech-ai_core_tp",title:F("tech_ai_core"),desc:F("tech_ai_core"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan:8},grant:["titan",9],cost:{Knowledge:()=>3e6,Cipher:()=>1e5},effect:F("tech_ai_core_effect"),action(){return!!Os($(this)[0])&&(t.space.ai_core={count:0},!0)}},ai_optimizations:{id:"tech-ai_optimizations",title:F("tech_ai_optimizations"),desc:F("tech_ai_optimizations"),category:"ai_core",era:"solar",path:["truepath"],reqs:{eris:3,titan:9,titan_ai_core:1,dig_control:1},grant:["titan_ai_core",2],cost:{Knowledge:()=>375e4,Cipher:()=>75e3},effect:F("tech_ai_optimizations_effect"),action(){return!!Os($(this)[0])},class:"synth"},synthetic_life:{id:"tech-synthetic_life",title:F("tech_synthetic_life"),desc:F("tech_synthetic_life"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:2},grant:["titan_ai_core",3],cost:{Knowledge:()=>4e6,Cipher:()=>75e3},effect:F("tech_synthetic_life_effect"),action(){return!!Os($(this)[0])&&(t.space.ai_colonist={count:0,on:0},!0)},class:"synth"},protocol66:{id:"tech-protocol66",title:F("tech_protocol66"),desc:F("tech_protocol66"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:3,corrupted_ai:1},grant:["corrupted_ai",2],cost:{Knowledge:()=>5e6},effect:F("tech_protocol66_effect"),action(){return!!Cs($(this)[0])},flair:F("tech_protocol66_flair"),class:"synth"},protocol66a:{id:"tech-protocol66a",title:F("tech_protocol66"),desc:F("tech_protocol66"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:3,corrupted_ai:2},wiki:!1,grant:["corrupted_ai",3],cost:{Knowledge:()=>5e6},effect(){let e=mc("ai"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name"),r=`
          ${F("tech_protocol66a_effect_gains",[e.plasmid,a,e.phage,e.cores])}
          `;return`
          ${F("tech_protocol66a_effect")}
          ${r}`},action(){return!!Os($(this)[0])&&(M.w&&M.w.terminate(),Ei(),$("body").append('
          '),$("#aiAppoc").addClass("noise-wrapper"),$("#aiAppoc > div").addClass("noise"),setTimeout((function(){$("body").append('
          '),$("body").append('
          '),$("#deadAirTop").animate({height:"50%",opacity:1},400),$("#deadAirBottom").animate({height:"50%",opacity:1},400)}),3e3),setTimeout((function(){!function(){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"ai apocalypse"}),Xc(`extinct_${t.race.species}`),Xc("obsolete"),Xc("squished",!0),t.race.junker&&"junker"===t.race.species&&eo("the_misery");let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=t.city.geology,n=mc("ai");so(),t.stats.aiappoc++,Fc(),t.prestige.Phage.count+=n.phage,t.stats.phage+=n.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=n.plasmid,t.stats.antiplasmid+=n.plasmid):(t.prestige.Plasmid.count+=n.plasmid,t.stats.plasmid+=n.plasmid),t.prestige.AICore.count+=n.cores,t.stats.cores+=n.cores;let l="synthetic"!==di[a].type?a:t.race.hasOwnProperty("srace")?t.race.srace:a;t.stats.synth[l]=!0;let u=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,srace:l,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},u>0&&(t.race.corruption=u),Q({orbit:s,biome:i,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),4e3),!0)},flair:F("tech_protocol66a_flair"),class:"synth"},terraforming_tp:{id:"tech-terraforming_tp",title:F("tech_terraforming"),desc:F("tech_terraforming"),category:"special",era:"solar",reqs:{dig_control:1,eris:2,titan_ai_core:2},path:["truepath"],grant:["terraforming",1],trait:["orbit_decay"],cost:{Knowledge:()=>5e6},effect:()=>F("tech_terraforming_effect",[Xt().red]),action(){return!!Os($(this)[0])&&(t.space.terraformer={count:0},!0)}},quantium:{id:"tech-quantium",title:F("tech_quantium"),desc:F("tech_quantium"),category:"crafting",era:"solar",path:["truepath"],reqs:{supercollider:10,enceladus:3},grant:["quantium",1],cost:{Knowledge:()=>1e6,Elerium:()=>1e3,Nano_Tube:()=>1e6,Graphene:()=>1e6},effect:F("tech_quantium_effect"),action(){return!!Os($(this)[0])&&(t.resource.Quantium.display=!0,!0)},post(){zi()}},anitgrav_bunk:{id:"tech-anitgrav_bunk",title:F("tech_anitgrav_bunk"),desc:F("tech_anitgrav_bunk"),category:"military",era:"solar",path:["truepath"],reqs:{marines:1,quantium:1},grant:["marines",2],cost:{Knowledge:()=>125e4,Quantium:()=>5e5},effect:()=>F("tech_anitgrav_bunk_effect",[F("space_red_space_barracks_title")]),action(){return!!Os($(this)[0])}},higgs_boson_tp:{id:"tech-higgs_boson_tp",title:F("tech_higgs_boson"),desc:F("tech_higgs_boson"),category:"science",era:"early_space",path:["truepath"],reqs:{supercollider:2},grant:["tp_particles",1],cost:{Knowledge:()=>125e3},effect:F("tech_higgs_boson_effect"),action(){return!!Os($(this)[0])}},long_range_probes:{id:"tech-long_range_probes",title:F("tech_long_range_probes"),desc:F("tech_long_range_probes"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{high_tech:10,elerium:1},grant:["outer",1],cost:{Knowledge:()=>4e5,Uranium:()=>2e4,Iridium:()=>25e4,Neutronium:()=>3e3,Elerium:()=>350},effect:F("tech_long_range_probes_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.titan=!0,t.settings.space.enceladus=!0,t.space.titan_spaceport={count:0,on:0,support:0,s_max:0},t.space.electrolysis={count:0,on:0,support:0,s_max:0},!0)}},strange_signal:{id:"tech-strange_signal",title:F("tech_strange_signal"),desc:F("tech_strange_signal"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:1,syard_sensor:4},grant:["outer",2],cost:{Knowledge:()=>135e4},effect:F("tech_strange_signal_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.triton=!0,!0)}},data_analysis:{id:"tech-data_analysis",title:F("tech_data_analysis"),desc:F("tech_data_analysis"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:3},grant:["outer",4],cost:{Knowledge:()=>18e5,Cipher:()=>12500},effect:F("tech_data_analysis_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_data_analysis_result"),"info",!1,["progress"]),t.space.syndicate.spc_titan+=500,t.space.syndicate.spc_enceladus+=250,t.space.syndicate.spc_triton+=1e3,!0)}},mass_relay:{id:"tech-mass_relay",title:F("tech_mass_relay"),desc:F("tech_mass_relay"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:4},grant:["outer",5],cost:{Knowledge:()=>22e5,Cipher:()=>4e4},effect:F("tech_mass_relay_effect"),action(){return!!Os($(this)[0])&&(t.space.mass_relay={count:0},!0)}},nav_data:{id:"tech-nav_data",title:F("tech_nav_data"),desc:F("tech_nav_data"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:6},grant:["outer",7],cost:{Knowledge:()=>225e4,Cipher:()=>6e4},effect:F("tech_nav_data_effect"),action(){return!!Os($(this)[0])&&(t.settings.space.eris=!0,t.settings.space.kuiper=!0,t.tech.eris_scan=0,t.space.drone_control={count:0,on:0,support:0,s_max:0},Di(F("tech_nav_data_result",[Xt().eris]),"info",!1,["progress"]),!0)}},sensor_logs:{id:"tech-sensor_logs",title:F("tech_sensor_logs"),desc:F("tech_sensor_logs"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:7},grant:["outer",8],cost:{Knowledge:()=>35e5,Cipher:()=>65e3},effect:F("tech_sensor_logs_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_sensor_logs_result"),"info",!1,["progress"]),!0)}},dronewar:{id:"tech-dronewar",title:F("tech_dronewar"),desc:F("tech_dronewar"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{eris:2,titan_ai_core:1},grant:["eris",3],cost:{Knowledge:()=>32e5,Cipher:()=>25e3},effect:()=>F("tech_dronewar_effect",[Xt().eris]),action(){return!!Os($(this)[0])&&(t.space.shock_trooper={count:0,on:0},t.space.digsite={count:0,enemy:1e4},!0)}},drone_tank:{id:"tech-drone_tank",title:F("tech_drone_tank"),desc:F("tech_drone_tank"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{eris:3},grant:["eris",4],cost:{Knowledge:()=>34e5,Cipher:()=>5e4},effect:F("tech_drone_tank_effect"),action(){return!!Os($(this)[0])&&(t.space.tank={count:0,on:0},!0)}},stanene_tp:{id:"tech-stanene_tp",title:F("tech_stanene"),desc:F("tech_stanene"),category:"crafting",era:"solar",path:["truepath"],reqs:{titan:1,enceladus:1},grant:["stanene",1],cost:{Knowledge:()=>525e3,Aluminium:()=>5e5,Nano_Tube:()=>1e5},effect:F("tech_stanene_effect"),action(){return!!Os($(this)[0])&&(t.resource.Stanene.display=!0,Di(F("tech_stanene_avail"),"info",!1,["progress"]),!0)},post(){Ws(),zi()}},graphene_tp:{id:"tech-graphene_tp",title:F("tech_graphene"),desc:F("tech_graphene"),category:"crafting",era:"solar",path:["truepath"],reqs:{titan:5},grant:["graphene",1],cost:{Knowledge:()=>64e4,Adamantite:()=>25e3},effect:F("tech_graphene_effect"),action(){return!!Os($(this)[0])&&(t.space.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},!0)}},virtual_reality_tp:{id:"tech-virtual_reality_tp",title:F("tech_virtual_reality"),desc:F("tech_virtual_reality"),category:"progress",era:"solar",path:["truepath"],reqs:{high_tech:11,titan:4,stanene:1},grant:["high_tech",12],cost:{Knowledge:()=>616e3,Nano_Tube:()=>1e6,Stanene:()=>125e3},effect:F("tech_virtual_reality_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_virtual_reality_flair")},electrolysis:{id:"tech-electrolysis",title:F("tech_electrolysis"),desc:F("tech_electrolysis"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:2,enceladus:1},grant:["titan",3],cost:{Knowledge:()=>465e3},effect:()=>F("tech_electrolysis_effect",[Xt().titan,t.resource.Water.name]),action(){return!!Os($(this)[0])&&(t.space.titan_quarters={count:0,on:0},t.space.titan_mine={count:0,on:0,ratio:90},!0)}},storehouse:{id:"tech-storehouse",title:()=>F("tech_storehouse",[Xt().titan]),desc:()=>F("tech_storehouse",[Xt().titan]),category:"storage",era:"solar",path:["truepath"],reqs:{titan:4},grant:["titan",5],cost:{Knowledge:()=>5e5},effect:()=>F("tech_storehouse_effect",[Xt().titan]),action(){return!!Os($(this)[0])&&(t.space.storehouse={count:0},!0)}},adamantite_vault_tp:{id:"tech-adamantite_vault_tp",title:F("tech_adamantite_vault"),desc:F("tech_adamantite_vault"),category:"banking",era:"solar",path:["truepath"],reqs:{vault:2,titan:4},grant:["vault",3],cost:{Money:()=>2e6,Knowledge:()=>56e4,Adamantite:()=>2e4},effect:F("tech_adamantite_vault_effect"),action(){return!!Os($(this)[0])}},titan_bank:{id:"tech-titan_bank",title:()=>F("tech_titan_bank",[Xt().titan]),desc:()=>F("tech_titan_bank",[Xt().titan]),category:"storage",era:"solar",path:["truepath"],reqs:{titan:5},grant:["titan",6],cost:{Knowledge:()=>6e5},effect:()=>F("tech_titan_bank_effect",[Xt().titan]),action(){return!!Os($(this)[0])&&(t.space.titan_bank={count:0},!0)}},hydrogen_plant:{id:"tech-hydrogen_plant",title:F("tech_hydrogen_plant"),desc:F("tech_hydrogen_plant"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:4,stanene:1},grant:["titan_power",1],cost:{Knowledge:()=>55e4},effect:()=>F("tech_hydrogen_plant_effect"),action(){return!!Os($(this)[0])&&(t.space.hydrogen_plant={count:0,on:0},!0)}},water_mining:{id:"tech-water_mining",title:F("tech_water_mining"),desc:F("tech_water_mining"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:2,enceladus:1},grant:["enceladus",2],cost:{Knowledge:()=>45e4},effect:()=>F("tech_water_mining_effect",[Xt().enceladus,di[t.race.species].home,t.resource.Water.name]),action(){return!!Os($(this)[0])&&(t.space.water_freighter={count:0,on:0},!0)}},mercury_smelting:{id:"tech-mercury_smelting",title:F("tech_mercury_smelting"),desc:F("tech_mercury_smelting"),category:"mining",era:"solar",path:["truepath"],reqs:{hell:1,titan:4,smelting:6},grant:["m_smelting",1],cost:{Knowledge:()=>625e3,Adamantite:()=>5e4},effect:()=>F("tech_mercury_smelting_effect",[Xt().hell]),action(){return!!Os($(this)[0])&&(t.space.hell_smelter={count:0},!0)}},iridium_smelting:{id:"tech-iridium_smelting",title:F("tech_iridium_smelting"),desc:F("tech_iridium_smelting"),category:"mining",era:"solar",path:["truepath"],reqs:{m_smelting:1,graphene:1},grant:["m_smelting",2],cost:{Knowledge:()=>825e3,Graphene:()=>125e3},effect:F("tech_iridium_smelting_effect"),action(){return!!Os($(this)[0])}},adamantite_crates:{id:"tech-adamantite_crates",title:F("tech_adamantite_crates"),desc:F("tech_adamantite_crates_desc"),category:"storage",era:"solar",path:["truepath"],reqs:{container:5,titan:4},grant:["container",6],cost:{Knowledge:()=>525e3,Adamantite:()=>12500},effect:F("tech_adamantite_crates_effect"),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},bolognium_crates_tp:{id:"tech-bolognium_crates_tp",title:()=>F("tech_crates",[t.resource.Bolognium.name]),desc:()=>F("tech_crates",[t.resource.Bolognium.name]),category:"storage",era:"tauceti",path:["truepath"],reqs:{container:7,tauceti:4},grant:["container",8],cost:{Knowledge:()=>616e4,Bolognium:()=>75e4},effect:()=>F("tech_bolognium_crates_effect",[t.resource.Bolognium.name]),action(){return!!Os($(this)[0])}},adamantite_containers_tp:{id:"tech-adamantite_containers_tp",title:()=>F("tech_containers",[t.resource.Adamantite.name]),desc:()=>F("tech_adamantite_containers_desc",[t.resource.Adamantite.name]),category:"storage",era:"solar",path:["truepath"],reqs:{steel_container:4,titan:4},grant:["steel_container",5],cost:{Knowledge:()=>575e3,Adamantite:()=>17500},effect:()=>F("tech_adamantite_containers_effect",[t.resource.Adamantite.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},quantium_containers:{id:"tech-quantium_containers",title:()=>F("tech_containers",[t.resource.Quantium.name]),desc:()=>F("tech_containers",[t.resource.Quantium.name]),category:"storage",era:"solar",path:["truepath"],reqs:{steel_container:5,quantium:1},grant:["steel_container",6],cost:{Knowledge:()=>115e4,Quantium:()=>1e5},effect:()=>F("tech_quantium_containers_effect",[t.resource.Quantium.name]),action(){return!!Os($(this)[0])&&(sc({el:"#createHead"},"update"),!0)}},unobtainium_containers:{id:"tech-unobtainium_containers",title:()=>F("tech_containers",[t.resource.Unobtainium.name]),desc:()=>F("tech_containers",[t.resource.Unobtainium.name]),category:"storage",era:"tauceti",path:["truepath"],reqs:{steel_container:6,tau_red:7},grant:["steel_container",7],cost:{Knowledge:()=>725e4,Unobtainium:()=>7500},effect:()=>F("tech_bolognium_containers_effect",[t.resource.Unobtainium.name]),action(){return!!Os($(this)[0])}},reinforced_shelving:{id:"tech-reinforced_shelving",title:F("tech_reinforced_shelving"),desc:F("tech_reinforced_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{graphene:1,titan:5},grant:["shelving",1],cost:{Knowledge:()=>85e4,Adamantite:()=>35e4,Graphene:()=>25e4},effect:F("tech_reinforced_shelving_effect"),action(){return!!Os($(this)[0])}},garage_shelving:{id:"tech-garage_shelving",title:F("tech_garage_shelving"),desc:F("tech_garage_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{shelving:1,quantium:1},grant:["shelving",2],cost:{Knowledge:()=>125e4,Quantium:()=>75e3},effect:F("tech_garage_shelving_effect"),action(){return!!Os($(this)[0])}},warehouse_shelving:{id:"tech-warehouse_shelving",title:F("tech_warehouse_shelving"),desc:F("tech_warehouse_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{shelving:2,quantium:1,outer:4},grant:["shelving",3],cost:{Knowledge:()=>225e4,Quantium:()=>1e6,Cipher:()=>25e3},effect:F("tech_warehouse_shelving_effect"),action(){return!!Os($(this)[0])}},elerium_extraction:{id:"tech-elerium_extraction",title:F("tech_elerium_extraction"),desc:F("tech_elerium_extraction"),category:"mining",era:"solar",path:["truepath"],reqs:{kuiper:1},grant:["kuiper",2],cost:{Knowledge:()=>25e5,Orichalcum:()=>1e5,Cipher:()=>12e3},effect:()=>F("tech_elerium_extraction_effect"),action(){return!!Os($(this)[0])&&(t.space.elerium_mine={count:0,on:0},!0)}},orichalcum_panels_tp:{id:"tech-orichalcum_panels_tp",title:F("tech_orichalcum_panels"),desc:F("tech_orichalcum_panels"),category:"power_generation",era:"solar",path:["truepath"],reqs:{kuiper:1,swarm:5},grant:["swarm",6],cost:{Knowledge:()=>24e5,Orichalcum:()=>125e3},effect:()=>F("tech_orichalcum_panels_effect"),action(){return!!Os($(this)[0])}},shipyard:{id:"tech-shipyard",title:()=>F("tech_shipyard",[Xt().dwarf]),desc:()=>F("tech_shipyard",[Xt().dwarf]),category:"space_militarization",era:"solar",path:["truepath"],reqs:{outer:1,syndicate:1},grant:["shipyard",1],cost:{Knowledge:()=>42e4},effect:()=>F("tech_shipyard_effect",[Xt().dwarf]),action(){return!!Os($(this)[0])&&(t.space.shipyard={count:0,on:0,ships:[],expand:!0,sort:!0},ft(),!0)}},ship_lasers:{id:"tech-ship_lasers",title:F("tech_ship_lasers"),desc:F("tech_ship_lasers"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{military:7,syard_weapon:1},grant:["syard_weapon",2],cost:{Knowledge:()=>425e3,Elerium:()=>500},effect:F("tech_ship_lasers_effect"),action(){return!!Os($(this)[0])}},pulse_lasers:{id:"tech-pulse_lasers",title:F("tech_pulse_lasers"),desc:F("tech_pulse_lasers"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:2},grant:["syard_weapon",3],cost:{Knowledge:()=>5e5,Elerium:()=>750},effect:F("tech_pulse_lasers_effect"),action(){return!!Os($(this)[0])}},ship_plasma:{id:"tech-ship_plasma",title:F("tech_ship_plasma"),desc:F("tech_ship_plasma"),category:"space_militarization",era:"solar",reqs:{high_tech:13,syard_weapon:3},grant:["syard_weapon",4],path:["truepath"],cost:{Knowledge:()=>88e4,Elerium:()=>2500},effect:F("tech_ship_plasma_effect"),action(){return!!Os($(this)[0])}},ship_phaser:{id:"tech-ship_phaser",title:F("tech_ship_phaser"),desc:F("tech_ship_phaser"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:4,quantium:1},grant:["syard_weapon",5],cost:{Knowledge:()=>1225e3,Quantium:()=>75e3},effect:F("tech_ship_phaser_effect"),action(){return!!Os($(this)[0])}},ship_disruptor:{id:"tech-ship_disruptor",title:F("tech_ship_disruptor"),desc:F("tech_ship_disruptor"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:5,outer:4},grant:["syard_weapon",6],cost:{Knowledge:()=>2e6,Cipher:()=>25e3},effect:F("tech_ship_disruptor_effect"),action(){return!!Os($(this)[0])}},destroyer_ship:{id:"tech-destroyer_ship",title:F("tech_destroyer_ship"),desc:F("tech_destroyer_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:2},grant:["syard_class",3],cost:{Knowledge:()=>465e3},effect:F("tech_destroyer_ship_effect"),action(){return!!Os($(this)[0])}},cruiser_ship_tp:{id:"tech-cruiser_ship_tp",title:F("tech_cruiser_ship"),desc:F("tech_cruiser_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:3,titan:4},grant:["syard_class",4],cost:{Knowledge:()=>75e4,Adamantite:()=>5e4},effect:F("tech_cruiser_ship_tp"),action(){return!!Os($(this)[0])}},h_cruiser_ship:{id:"tech-h_cruiser_ship",title:F("tech_h_cruiser_ship"),desc:F("tech_h_cruiser_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:4,triton:1},grant:["syard_class",5],cost:{Knowledge:()=>15e5},effect:F("tech_h_cruiser_ship_effect"),action(){return!!Os($(this)[0])}},dreadnought_ship:{id:"tech-dreadnought_ship",title:F("tech_dreadnought_ship"),desc:F("tech_dreadnought_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:5,kuiper:1},grant:["syard_class",6],cost:{Knowledge:()=>25e5,Cipher:()=>1e4},effect:F("tech_dreadnought_ship_effect"),action(){return!!Os($(this)[0])}},pulse_engine:{id:"tech-pulse_engine",title:F("outer_shipyard_engine_pulse"),desc:F("outer_shipyard_engine_pulse"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:2,stanene:1},grant:["syard_engine",3],cost:{Knowledge:()=>555e3,Stanene:()=>25e4},effect:F("tech_pulse_engine_effect"),action(){return!!Os($(this)[0])}},photon_engine:{id:"tech-photon_engine",title:F("outer_shipyard_engine_photon"),desc:F("outer_shipyard_engine_photon"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:3,quantium:1},grant:["syard_engine",4],cost:{Knowledge:()=>115e4,Quantium:()=>5e4},effect:F("tech_photon_engine_effect"),action(){return!!Os($(this)[0])}},vacuum_drive:{id:"tech-vacuum_drive",title:F("outer_shipyard_engine_vacuum"),desc:F("outer_shipyard_engine_vacuum"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:4,outer:4},grant:["syard_engine",5],cost:{Knowledge:()=>185e4,Cipher:()=>1e4},effect:F("outer_shipyard_engine_vacuum_desc"),action(){return!!Os($(this)[0])}},ship_fusion:{id:"tech-ship_fusion",title:F("tech_fusion_generator"),desc:F("tech_fusion_generator"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_power:3,quantium:1},grant:["syard_power",4],cost:{Knowledge:()=>11e5,Quantium:()=>65e3},effect:F("tech_fusion_generator_effect"),action(){return!!Os($(this)[0])}},ship_elerium:{id:"tech-ship_elerium",title:F("tech_elerium_generator"),desc:F("tech_elerium_generator"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_power:4,outer:4},grant:["syard_power",5],cost:{Knowledge:()=>19e5,Cipher:()=>18e3},effect:F("tech_elerium_generator_effect"),action(){return!!Os($(this)[0])}},quantum_signatures:{id:"tech-quantum_signatures",title:F("tech_quantum_signatures"),desc:F("tech_quantum_signatures"),category:"progress",era:"solar",path:["truepath"],reqs:{quantium:1,syard_sensor:3},grant:["syard_sensor",4],cost:{Knowledge:()=>105e4,Quantium:()=>1e4},effect:F("tech_quantum_signatures_effect"),action(){return!!Os($(this)[0])}},interstellar_drive:{id:"tech-interstellar_drive",title:F("tech_interstellar_drive"),desc:F("tech_interstellar_drive"),category:"progress",era:"tauceti",path:["truepath"],reqs:{outer:8,titan_ai_core:2,syard_sensor:4},grant:["tauceti",1],cost:{Knowledge:()=>45e5,Quantium:()=>25e4,Cipher:()=>75e3},effect:F("tech_interstellar_drive_effect"),action(){return!!Os($(this)[0])}},alien_outpost:{id:"tech-alien_outpost",title:F("tech_alien_outpost"),desc:F("tech_alien_outpost"),category:"science",era:"tauceti",path:["truepath"],reqs:{tauceti:2,tau_home:3},grant:["tau_home",4],cost:{Knowledge:()=>5e6,Cipher:()=>1e5},effect:F("tech_alien_outpost_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.alien_outpost={count:1,on:0},t.tauceti.jump_gate={count:0},t.space.jump_gate={count:0},Di(F("tech_alien_outpost_msg"),"info",!1,["progress"]),!0)}},jumpgates:{id:"tech-jumpgates",title:F("tech_jumpgates"),desc:F("tech_jumpgates"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tauceti:2,tau_home:4},grant:["tauceti",3],cost:{Knowledge:()=>6e6},effect:F("tech_jumpgates_effect"),action(){return!!Os($(this)[0])}},system_survey:{id:"tech-system_survey",title:F("tech_system_survey"),desc:F("tech_system_survey"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tauceti:4,womling_tech:1},grant:["tauceti",5],cost:{Knowledge:()=>7e6},effect:F("tech_system_survey_effect"),action(){return!!Os($(this)[0])&&(t.settings.tau.roid=!0,t.settings.tau.gas=!0,t.tauceti.patrol_ship={count:0,on:0,support:0,s_max:0},!0)}},repository:{id:"tech-repository",title:F("tech_repository"),desc:F("tech_repository"),category:"storage",era:"tauceti",path:["truepath"],reqs:{tauceti:4,tau_home:4},grant:["tau_home",5],cost:{Knowledge:()=>65e5},effect:F("tech_repository_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.repository={count:0},!0)}},fusion_generator:{id:"tech-fusion_generator",title:F("tech_fusion_power"),desc:F("tech_fusion_power"),category:"power_generation",era:"tauceti",path:["truepath"],reqs:{tau_home:5},grant:["tau_home",6],cost:{Knowledge:()=>675e4},effect:F("tech_tau_fusion_power_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.fusion_generator={count:0,on:0},!0)}},tau_cultivation:{id:"tech-tau_cultivation",title:F("tech_tau_cultivation"),desc:F("tech_tau_cultivation"),category:"agriculture",era:"tauceti",path:["truepath"],reqs:{tau_home:6},grant:["tau_home",7],cost:{Knowledge:()=>69e5},effect:()=>F("tech_tau_cultivation_effect",[di[t.race.species].home]),action(){return!!Os($(this)[0])&&(t.tauceti.tau_farm={count:0,on:0},!0)}},tau_manufacturing:{id:"tech-tau_manufacturing",title:F("tech_tau_manufacturing"),desc:F("tech_tau_manufacturing"),category:"crafting",era:"tauceti",path:["truepath"],reqs:{tau_home:7},grant:["tau_home",8],cost:{Knowledge:()=>725e4},effect:()=>F("tech_tau_manufacturing_effect",[di[t.race.species].home]),action(){return!!Os($(this)[0])&&(t.tauceti.tau_factory={count:0,on:0},!0)}},weasels:{id:"tech-weasels",title:F("tech_weasels"),desc:F("tech_weasels"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:2},grant:["tau_red",3],cost:{Knowledge:()=>625e4},effect:()=>F("tech_weasels_effect",[F("tau_planet",[Xt().red])]),action(){return!!Os($(this)[0])&&(Di(F("tech_weasels_msg",[F("tau_planet",[Xt().red])]),"info",!1,["progress"]),!0)}},jeff:{id:"tech-jeff",title:F("tech_jeff"),desc:F("tech_jeff"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:3},grant:["tau_red",4],cost:{Knowledge:()=>638e4},effect:()=>F("tech_jeff_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_jeff_effect_msg",[]),"info",!1,["progress"]),!0)}},womling_fun:{id:"tech-womling_fun",title:F("tech_womling_fun"),desc:F("tech_womling_fun"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:5},grant:["tau_red",6],cost:{Knowledge:()=>665e4},effect:()=>F("tech_womling_fun_effect"),action(){return!!Os($(this)[0])}},womling_lab:{id:"tech-womling_lab",title:F("tech_womling_lab"),desc:F("tech_womling_lab"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:6},grant:["tau_red",7],cost:{Knowledge:()=>69e5},effect:()=>F("tech_womling_lab_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.womling_lab={count:0,on:0,scientist:0,tech:0},t.tech.womling_tech=0,!0)}},womling_mining:{id:"tech-womling_mining",title:F("tech_womling_mining"),desc:F("tech_womling_mining"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:1},grant:["womling_mining",1],cost:{Knowledge:()=>71e5},effect:()=>F("tech_womling_mining_effect"),action(){return!!Os($(this)[0])}},womling_firstaid:{id:"tech-womling_firstaid",title:F("tech_womling_firstaid"),desc:F("tech_womling_firstaid"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:2},grant:["womling_firstaid",1],cost:{Knowledge:()=>735e4},effect:()=>F("tech_womling_firstaid_effect"),action(){return!!Os($(this)[0])}},womling_logistics:{id:"tech-womling_logistics",title:F("tech_womling_logistics"),desc:F("tech_womling_logistics"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:3},grant:["womling_logistics",1],cost:{Knowledge:()=>765e4},effect:()=>F("tech_womling_logistics_effect",[F("tau_red_orbital_platform")]),action(){return!!Os($(this)[0])}},womling_repulser:{id:"tech-womling_repulser",title:F("tech_womling_repulser"),desc:F("tech_womling_repulser"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:4,womling_logistics:1},grant:["womling_logistics",2],cost:{Knowledge:()=>79e5},effect:()=>F("tech_womling_repulser_effect",[t.resource.Oil.name,F("tau_red_orbital_platform")]),action(){return!!Os($(this)[0])}},womling_farming:{id:"tech-womling_farming",title:F("tech_womling_farming"),desc:F("tech_womling_farming"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:5},grant:["womling_pop",1],cost:{Knowledge:()=>82e5},effect:()=>F("tech_womling_farming_effect"),action(){return!!Os($(this)[0])}},womling_housing:{id:"tech-womling_housing",title:F("tech_womling_housing"),desc:F("tech_womling_housing"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:6,womling_pop:1},grant:["womling_pop",2],cost:{Knowledge:()=>85e5},effect:()=>F("tech_womling_housing_effect"),action(){return!!Os($(this)[0])}},womling_support:{id:"tech-womling_support",title:F("tech_womling_support"),desc:F("tech_womling_support"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:7,tau_gas:4},grant:["womling_technicians",1],cost:{Knowledge:()=>885e4},effect:()=>`
          ${F("tech_womling_support_effect")}
          `,action(){return!!Os($(this)[0])&&(t.tauceti.womling_station={count:0,on:0},!0)}},womling_recycling:{id:"tech-womling_recycling",title:F("tech_womling_recycling"),desc:F("tech_womling_recycling"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:8},grant:["womling_recycling",1],cost:{Knowledge:()=>955e4},effect:()=>`
          ${F("tech_womling_recycling_effect")}
          `,action(){return!!Os($(this)[0])}},asteroid_analysis:{id:"tech-asteroid_analysis",title:F("tech_asteroid_analysis"),desc:F("tech_asteroid_analysis"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_roid:1},grant:["tau_roid",2],cost:{Knowledge:()=>735e4},effect:()=>F("tech_asteroid_analysis_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_asteroid_analysis_msg"),"info",!1,["progress"]),!0)}},shark_repellent:{id:"tech-shark_repellent",title:F("tech_shark_repellent"),desc:F("tech_shark_repellent"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_roid:2},grant:["tau_roid",3],cost:{Knowledge:()=>74e5},effect:()=>F("tech_shark_repellent_effect"),action(){return!!Os($(this)[0])&&(Di(F("tech_shark_repellent_msg"),"info",!1,["progress"]),!0)}},belt_mining:{id:"tech-belt_mining",title:F("tech_belt_mining"),desc:F("tech_belt_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{tau_gas:3,tau_roid:3},grant:["tau_gas",4],cost:{Knowledge:()=>765e4},effect:()=>F("tech_belt_mining_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.ore_refinery={count:0,on:0,max:0,fill:0},t.tauceti.mining_ship={count:0,on:0,common:50,uncommon:50,rare:50},!0)}},adv_belt_mining:{id:"tech-adv_belt_mining",title:F("tech_adv_belt_mining"),desc:F("tech_adv_belt_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{tau_roid:4},grant:["tau_roid",5],cost:{Knowledge:()=>79e5},effect:()=>F("tech_adv_belt_mining_effect"),action(){return!!Os($(this)[0])}},space_whaling:{id:"tech-space_whaling",title:F("tech_space_whaling"),desc:F("tech_space_whaling"),category:"whaling",era:"tauceti",path:["truepath"],reqs:{tau_gas:3,tau_roid:3},grant:["tau_whale",1],cost:{Knowledge:()=>75e5},effect:()=>F("tech_space_whaling_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.whaling_station={count:0,on:0,max:0,fill:0},t.tauceti.whaling_ship={count:0,on:0},!0)}},infectious_disease_lab:{id:"tech-infectious_disease_lab",title:()=>F(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),desc:()=>F(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),category:"science",era:"tauceti",path:["truepath"],reqs:{plague:2},grant:["disease",1],cost:{Knowledge:()=>825e4},effect:()=>F(t.race.artifical?"tech_infectious_disease_lab_effect_s":"tech_infectious_disease_lab_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.infectious_disease_lab={count:0,on:0,cure:0},!0)}},isolation_protocol:{id:"tech-isolation_protocol",title:F("tech_isolation_protocol"),desc:F("tech_isolation_protocol"),category:"plague",era:"tauceti",path:["truepath"],reqs:{disease:2},grant:["disease",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>85e5},effect:()=>`
          ${F("tech_isolation_protocol_effect",[F("tab_tauceti")])}
          ${F("tech_isolation_protocol_warning")}
          `,action(){return!!Os($(this)[0])&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),t.tech.isolation=1,function(){let e={city:{},space:{},ships:[]};e.ships=[...t.space.shipyard.ships],t.space.shipyard.ships=[],t.settings.spaceTabs=6,t.settings.showSpace=!1,t.settings.showOuter=!1,t.settings.showCity=!1,t.settings.showShipYard=!1,5===t.settings.govTabs&&(t.settings.govTabs=0),dt(),rc($("#shipList")),Object.keys(Qr.city).forEach((function(a){t.city.hasOwnProperty(a)&&t.city[a].hasOwnProperty("count")&&(t.race.hooved&&Qr.city[a].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Qr.city[a].cost.Horseshoe()*t.city[a].count),e.city[a]={c:t.city[a].count},t.city[a].count=0,t.city[a].hasOwnProperty("on")&&(e.city[a].o=t.city[a].on,t.city[a].on=0))})),["spc_home","spc_moon","spc_red","spc_hell","spc_sun","spc_gas","spc_gas_moon","spc_belt","spc_dwarf","spc_titan","spc_enceladus","spc_triton","spc_kuiper","spc_eris"].forEach((function(a){Object.keys(Qr.space[a]).forEach((function(r){t.space.hasOwnProperty(r)&&t.space[r].hasOwnProperty("count")&&(t.race.hooved&&Qr.space[a][r].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Qr.space[a][r].cost.Horseshoe()*t.space[r].count),e.space[r]={c:t.space[r].count},t.space[r].count=0,t.space[r].hasOwnProperty("on")&&(e.space[r].o=t.space[r].on,t.space[r].on=0))}))})),t.race.hooved&&t.race.shoecnt<5&&(t.race.shoecnt=5),t.resource.Zen.display&&(t.resource.Zen.display=!1),t.resource.Slave.display&&(t.resource.Slave.display=!1,t.resource.Slave.amount=0,D("slave")),t.race.deconstructor&&Vs.forEach((function(e){t.city.nanite_factory[e]=0})),Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),Object.keys(ca).forEach((function(e){["professor","scientist","pit_miner","cement_worker","craftsman"].includes(e)||(t.civic[e].workers=0,t.civic[e].assigned=0)})),["forager","farmer","lumberjack","quarry_worker","miner","coal_miner","priest","colonist","titan_colonist","space_miner"].forEach((function(e){t.civic[e].display=!1})),t.civic.hunter.display?t.civic.d_job="hunter":t.civic.d_job="unemployed",t.arpa.sequence&&(t.arpa.sequence.on=!1,t.arpa.sequence.boost=!1);for(let e of Object.values(t.race.purgatory.city))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);for(let e of Object.values(t.race.purgatory.space))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);if(t.queue.hasOwnProperty("queue"))for(let e=t.queue.queue.length-1;e>=0;e--){let a=t.queue.queue[e];"city"!==a.action&&"space"!==a.action&&"starDock"!==a.action||t.queue.queue.splice(e,1)}t.tech.magic&&t.tech.magic>=2&&(t.tauceti.pylon={count:0},t.race.casting&&Object.keys(t.race.casting).forEach((function(e){t.race.casting[0]=0}))),t.tauceti.tauceti_casino={count:0,on:0},t.tauceti.tau_housing={count:0};let a=c.colony*Ze.tau_home.colony.citizens();t.resource[t.race.species].amount>a&&(t.resource[t.race.species].amount=a),D("spy"),D("spyop"),rc($("#infoTimer")),t.race.inactive=e}(),!0)}},focus_cure:{id:"tech-focus_cure",title:F("tech_focus_cure"),desc:F("tech_focus_cure"),category:"plague",era:"tauceti",path:["truepath"],reqs:{disease:2},grant:["disease",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>85e5},effect:()=>`
          ${F("tech_focus_cure_effect",[F("tab_tauceti")])}
          ${F("tech_focus_cure_warning")}
          `,action(){return!!Os($(this)[0])&&(t.tech.focus_cure=1,!0)}},decode_virus:{id:"tech-decode_virus",title:F("tech_decode_virus"),desc:F("tech_decode_virus"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:1},grant:["focus_cure",2],cost:{Knowledge:()=>9e6},effect:()=>`
          ${F(t.race.artifical?"tech_decode_virus_effect_s":"tech_decode_virus_effect")}
          `,action(){return!!Os($(this)[0])&&(t.race.artifical?Di(F("tech_decode_virus_msg1s",[Qr.tauceti.tau_home.infectious_disease_lab.title()]),"info",!1,["progress"]):Di(F("tech_decode_virus_msg1",[Qr.tauceti.tau_home.infectious_disease_lab.title()]),"info",!1,["progress"]),!0)}},vaccine_campaign:{id:"tech-vaccine_campaign",title:F("tech_vaccine_campaign"),desc:F("tech_vaccine_campaign"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:3},grant:["focus_cure",4],cost:{Knowledge:()=>925e4},effect:()=>`
          ${F("tech_vaccine_campaign_effect",[t.race.artifical?Qr.city.boot_camp.title():Qr.city.hospital.title])}
          `,action(){return!!Os($(this)[0])&&(t.race.vax=0,!0)}},vax_strat1:{id:"tech-vax_strat1",title:F("tech_vax_strat1"),desc:F("tech_vax_strat1"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
          ${F("tech_vax_strat1_effect")}
          ${F("tech_vax_warning")}
          `,action(){return!!Os($(this)[0])&&(t.tech.vax_p=1,Di(F("tech_vax_strat1_msg"),"info",!1,["progress"]),!0)}},vax_strat2:{id:"tech-vax_strat2",title:F("tech_vax_strat2"),desc:F("tech_vax_strat2"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
          ${F("tech_vax_strat2_effect")}
          ${F("tech_vax_warning")}
          `,action(){return!!Os($(this)[0])&&(t.tech.vax_f=1,Di(F("tech_vax_strat2_msg"),"info",!1,["progress"]),!0)}},vax_strat3:{id:"tech-vax_strat3",title:F("tech_vax_strat3"),desc:F("tech_vax_strat3"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
          ${F("tech_vax_strat3_effect")}
          ${F("tech_vax_warning")}
          `,action(){return!!Os($(this)[0])&&(t.tech.vax_s=1,Di(F("tech_vax_strat3_msg"),"info",!1,["progress"]),!0)}},vax_strat4:{id:"tech-vax_strat4",title:F("tech_vax_strat4"),desc:F("tech_vax_strat4"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
          ${F("tech_vax_strat4_effect")}
          ${F("tech_vax_warning")}
          `,action(){return!!Os($(this)[0])&&(t.tech.vax_c=1,Di(F("tech_vax_strat4_msg"),"info",!1,["progress"]),!0)}},cloning:{id:"tech-cloning",title:F("tech_cloning"),desc:F("tech_cloning"),category:"housing",era:"tauceti",path:["truepath"],reqs:{focus_cure:7},grant:["cloning",1],cost:{Knowledge:()=>975e4},effect:()=>`
          ${F(t.race.artifical?"tech_cloning_effect_s":"tech_cloning_effect")}
          `,action(){return!!Os($(this)[0])&&(t.tauceti.cloning_facility={count:0,on:0},!0)}},clone_degradation:{id:"tech-clone_degradation",title:F("tech_clone_degradation"),desc:F("tech_clone_degradation"),category:"progress",era:"tauceti",path:["truepath"],reqs:{cloning:1},grant:["cloning",2],cost:{Knowledge:()=>1e7},effect:()=>`
          ${F("tech_clone_degradation_effect")}
          `,action(){return!!Os($(this)[0])&&(Di(F("tech_clone_degradation_msg"),"info",!1,["progress"]),!0)}},digital_paradise:{id:"tech-digital_paradise",title:F("tech_digital_paradise"),desc:F("tech_digital_paradise"),category:"progress",era:"tauceti",path:["truepath"],reqs:{cloning:2},grant:["matrix",1],cost:{Knowledge:()=>105e5,Cipher:()=>2e5},effect:()=>`
          ${F("tech_digital_paradise_effect")}
          `,action(){return!!Os($(this)[0])}},ringworld:{id:"tech-ringworld",title:F("tech_ringworld"),desc:F("tech_ringworld"),category:"progress",era:"tauceti",path:["truepath"],reqs:{matrix:1},grant:["matrix",2],cost:{Money:()=>3e9,Knowledge:()=>11e6},effect:()=>`
          ${F("tech_ringworld_effect")}
          `,action(){return!!Os($(this)[0])&&(t.settings.tau.star=!0,t.tauceti.ringworld={count:0},!0)}},iso_gambling:{id:"tech-iso_gambling",title:F("tech_iso_gambling"),desc:F("tech_iso_gambling"),category:"banking",era:"tauceti",reqs:{gambling:4,isolation:1},grant:["iso_gambling",1],cost:{Knowledge:()=>865e4},effect:F("tech_iso_gambling_effect",[5]),action(){return!!Os($(this)[0])}},outpost_boost:{id:"tech-outpost_boost",title:()=>F("tech_outpost_boost"),desc:()=>F("tech_outpost_boost"),category:"special",era:"tauceti",path:["truepath"],reqs:{tau_home:4,isolation:1},grant:["outpost_boost",1],cost:{Knowledge:()=>89e5},effect:()=>F("tech_outpost_boost_effect"),action(){return!!Os($(this)[0])},flair:()=>F("tech_outpost_boost_flair")},cultural_center:{id:"tech-cultural_center",title:F("tech_cultural_center"),desc:F("tech_cultural_center"),category:"banking",era:"tauceti",path:["truepath"],reqs:{iso_gambling:1,isolation:1},grant:["tau_culture",1],cost:{Knowledge:()=>885e4},effect:F("tech_cultural_center_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.tau_cultural_center={count:0,on:0},!0)},flair:()=>F("tech_cultural_center_flair")},outer_tau_survey:{id:"tech-outer_tau_survey",title:F("tech_outer_tau_survey"),desc:F("tech_outer_tau_survey"),category:"progress",era:"tauceti",path:["truepath"],reqs:{outpost_boost:1,plague:5},grant:["tau_gas2",1],cost:{Knowledge:()=>91e5,Helium_3:()=>+Yt(5e6).toFixed(0)},effect:F("tech_outer_tau_survey_effect"),action(){return!!Os($(this)[0])&&(t.settings.tau.gas2=!0,!0)}},alien_research:{id:"tech-alien_research",title:F("tech_alien_research"),desc:F("tech_alien_research"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_gas2:5},grant:["tau_gas2",6],cost:{Knowledge:()=>935e4},effect:F("tech_alien_research_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.alien_space_station.decrypted=0,t.tauceti.alien_space_station.focus=95,Di(F("tech_alien_research_msg"),"info",!1,["progress"]),!0)}},womling_gene_therapy:{id:"tech-womling_gene_therapy",title:F("tech_womling_gene_therapy"),desc:F("tech_womling_gene_therapy"),category:"womling",era:"tauceti",path:["truepath"],reqs:{alien_data:1},grant:["womling_gene",1],cost:{Knowledge:()=>952e4},effect:F("tech_womling_gene_therapy_effect"),action(){return!!Os($(this)[0])}},food_culture:{id:"tech-food_culture",title:()=>F("tech_food_culture",[F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),desc:()=>F("tech_food_culture",[F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),category:"banking",era:"tauceti",path:["truepath"],reqs:{alien_data:2,tau_culture:1},grant:["tau_culture",2],cost:{Knowledge:()=>941e4},effect:()=>F("tech_food_culture_effect",[F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`),F("tech_cultural_center")]),action(){return!!Os($(this)[0])}},advanced_refinery:{id:"tech-advanced_refinery",title:F("tech_advanced_refinery"),desc:F("tech_advanced_refinery"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:3},grant:["tau_ore_mining",1],cost:{Knowledge:()=>968e4},effect:()=>F("tech_advanced_refinery_effect"),action(){return!!Os($(this)[0])}},advanced_pit_mining:{id:"tech-advanced_pit_mining",title:F("tech_advanced_pit_mining"),desc:F("tech_advanced_pit_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:3},grant:["tau_pit_mining",1],cost:{Knowledge:()=>972e4},effect:()=>F("tech_advanced_pit_mining_effect"),action(){return!!Os($(this)[0])}},useless_junk:{id:"tech-useless_junk",title:F("tech_useless_junk"),desc:F("tech_useless_junk"),category:"womling",era:"tauceti",path:["truepath"],reqs:{alien_data:4},grant:["tau_junksale",1],cost:{Knowledge:()=>955e4},effect:()=>F("tech_useless_junk_effect",[F(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`),F("tau_red_womlings")]),action(){return!!Os($(this)[0])}},advanced_asteroid_mining:{id:"tech-advanced_asteroid_mining",title:F("tech_advanced_asteroid_mining"),desc:F("tech_advanced_asteroid_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:5,tau_ore_mining:1},grant:["tau_ore_mining",2],cost:{Knowledge:()=>975e4},effect:()=>F("tech_advanced_asteroid_mining_effect",[F("tau_roid_mining_ship")]),action(){return!!Os($(this)[0])}},advanced_material_synthesis:{id:"tech-advanced_material_synthesis",title:F("tech_advanced_material_synthesis"),desc:F("tech_advanced_material_synthesis"),category:"crafting",era:"tauceti",path:["truepath"],reqs:{alien_data:5,disease:1},grant:["alien_crafting",1],cost:{Knowledge:()=>988e4},effect:()=>F("tech_advanced_material_synthesis_effect",[t.resource.Quantium.name]),action(){return!!Os($(this)[0])}},matrioshka_brain:{id:"tech-matrioshka_brain",title:F("tech_matrioshka_brain"),desc:F("tech_matrioshka_brain"),category:"progress",era:"tauceti",path:["truepath"],reqs:{alien_data:6,tau_gas2:6},grant:["tau_gas2",7],not_trait:["lone_survivor"],cost:{Knowledge:()=>1e7},effect:()=>F("tech_matrioshka_brain_effect",[Qr.tauceti.tau_gas2.info.name()]),action(){return!!Os($(this)[0])&&(t.tauceti.matrioshka_brain={count:0},!0)}},ignition_device:{id:"tech-ignition_device",title:F("tech_ignition_device"),desc:F("tech_ignition_device"),category:"progress",era:"tauceti",path:["truepath"],reqs:{alien_data:6,tau_gas2:7},grant:["tau_gas2",8],cost:{Knowledge:()=>105e5},effect:()=>F("tech_ignition_device_effect",[Qr.tauceti.tau_gas2.info.name()]),action(){return!!Os($(this)[0])&&(t.tauceti.ignition_device={count:0},t.tauceti.hasOwnProperty("matrioshka_brain")||(t.tauceti.matrioshka_brain={count:0}),!0)}},replicator:{id:"tech-replicator",title:()=>"antimatter"===t.race.universe?F("tech_antireplicator"):F("tech_replicator"),desc:()=>"antimatter"===t.race.universe?F("tech_antireplicator"):F("tech_replicator"),category:"special",era:"tauceti",path:["truepath"],reqs:{tau_home:4,isolation:1},trait:["lone_survivor"],grant:["replicator",1],cost:{Knowledge:()=>625e4},effect:()=>"antimatter"===t.race.universe?F("tech_antireplicator_effect"):F("tech_replicator_effect"),action(){return!!Os($(this)[0])&&(t.race.replicator={res:"Unobtainium",pow:1},!0)}},womling_unlock:{id:"tech-womling_unlock",title:F("tech_womling_unlock"),desc:F("tech_womling_unlock"),category:"womling",era:"tauceti",path:["truepath"],reqs:{replicator:1},trait:["lone_survivor"],grant:["tau_red",4],cost:{Knowledge:()=>65e5},effect:()=>F("tech_womling_unlock_effect",[F("tau_planet",[Xt().red])]),action(){return!!Os($(this)[0])&&(t.settings.tau.red=!0,t.tauceti.orbital_platform.count=1,t.tauceti.orbital_platform.on=1,!0)}},garden_of_eden:{id:"tech-garden_of_eden",title:F("tech_garden_of_eden"),desc:F("tech_garden_of_eden"),category:"special",era:"tauceti",path:["truepath"],reqs:{eden:1},grant:["eden",2],cost:{Knowledge:()=>1e7},effect:()=>F("tech_garden_of_eden_effect"),action(){return!!Os($(this)[0])&&(t.tauceti.goe_facility={count:0},!0)}}};function Hr(){t.tech.world_control=1,rc($("#garrison")),rc($("#c_garrison")),fe($("#garrison"),!0),fe($("#c_garrison"),!1);for(let e=0;e<3;e++){if(t.civic.foreign[`gov${e}`].occ){let a=la("federation"===t.civic.govern.type?15:20);t.civic.garrison.max+=a,t.civic.garrison.workers+=a,t.civic.foreign[`gov${e}`].occ=!1}t.civic.foreign[`gov${e}`].buy=!1,t.civic.foreign[`gov${e}`].anx=!1,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none"}D("spy"),D("spyop")}function Ur(e,a){let r=["swiss","gouda","cheddar","brie","feta","ricotta","goat","mascarpone","bleu","colby_jack","camembert","gorgonzola","mozzarella","roquefort","provolone","monterey_jack","muenster","cambozola","jarlsberg","bocconcini","cantal","emmental","havarti","burrata","cottage","asiago","wensleydale","pepper_jack","queso_blanco","pecorino","raclette","fontina","reblochon","port_salut","brillat_savarin","cream","stilton","taleggio","manchego","edam","gruyeye","parmigiano_reggiano","epoisses","comte","caciocavallo","teleme","grana_padano","chaumes","morbier","halloumi","lancashire","bleu_de_gex","fourme_d_ambert","fromage_blanc","red_leicester","bleu_d_auvergne","pont_l_eveque","jl_grubb","castello_blue","wagasi","ayibe","caravane","limburger","herve","kashkaval","sirene","paski_sir","akkawi","olomoucke_syrecky","anari","danbo","hermelín","trappista","stinking_bishop","banbury","sulguni","hofoingi","urda","golka","rokpol","telemea","bryndza","parenica","kackavalj","liptauer","greve","korbaciky","herrgardsost","vasterbottensost","mish","anejo","quesillo","nacho","reggianito","catupiry","queso_paipa","canastra","port_wine","cados","brie_de_meaux"];if(a)return r;let s=(t.stats.hasOwnProperty("reset")?t.stats.reset:0)%r.length;return e?F(`cheese_${r[s]}`):F("tech_swiss_bank",[F(`cheese_${r[s]}`)])}const Wr={standard:["primitive","discovery","civilized","industrialized","globalized","early_space","deep_space","interstellar","intergalactic","dimensional"],truepath:["primitive","discovery","civilized","industrialized","globalized","early_space","deep_space","solar","tauceti"]},Qr={evolution:{rna:{id:"evolution-rna",title:F("resource_RNA_name"),desc:()=>F("evo_rna",[t.race.rapid_mutation?2:1]),condition:()=>t.resource.hasOwnProperty("RNA")&&t.resource.RNA.display&&!t.race.evoFinalMenu,action:()=>(t.resource.RNA.amount0},dna:{id:"evolution-dna",title:F("evo_dna_title"),desc:F("evo_dna_desc"),condition:()=>t.resource.hasOwnProperty("DNA")&&t.resource.DNA.display&&!t.race.evoFinalMenu,cost:{RNA:()=>2},action:()=>(t.resource.RNA.amount>=2&&t.resource.DNA.amount0},membrane:{id:"evolution-membrane",title:F("evo_membrane_title"),desc:F("evo_membrane_desc"),condition:()=>t.evolution.hasOwnProperty("membrane")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("membrane",2,2,e)},effect:()=>F("evo_membrane_effect",[t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5]),action(){return!!Os($(this)[0])&&(t.resource.RNA.max+=t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5,t.evolution.membrane.count++,!0)}},organelles:{id:"evolution-organelles",title:F("evo_organelles_title"),desc:F("evo_organelles_desc"),condition:()=>t.evolution.hasOwnProperty("organelles")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("organelles",12,8,e),DNA:e=>is("organelles",4,4,e)},effect(){let e=t.race.rapid_mutation?2:1;return t.evolution.sexual_reproduction&&t.evolution.sexual_reproduction.count>0&&e++,F("evo_organelles_effect",[e])},action(){return!!Os($(this)[0])&&(t.evolution.organelles.count++,!0)}},nucleus:{id:"evolution-nucleus",title:F("evo_nucleus_title"),desc:F("evo_nucleus_desc"),condition:()=>t.evolution.hasOwnProperty("nucleus")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("nucleus",38,t.tech.evo&&t.tech.evo>=4?16:32,e),DNA:e=>is("nucleus",18,t.tech.evo&&t.tech.evo>=4?12:16,e)},effect:()=>F("evo_nucleus_effect",[t.evolution.bilateral_symmetry&&t.evolution.bilateral_symmetry.count>0||t.evolution.poikilohydric&&t.evolution.poikilohydric.count>0||t.evolution.spores&&t.evolution.spores.count>0?2:1]),action(){return!!Os($(this)[0])&&(t.evolution.nucleus.count++,!0)}},eukaryotic_cell:{id:"evolution-eukaryotic_cell",title:F("evo_eukaryotic_title"),desc:F("evo_eukaryotic_desc"),condition:()=>t.evolution.hasOwnProperty("eukaryotic_cell")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("eukaryotic_cell",20,20,e),DNA:e=>is("eukaryotic_cell",40,12,e)},effect:()=>F("evo_eukaryotic_effect",[t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10]),action(){return!!Os($(this)[0])&&(t.evolution.eukaryotic_cell.count++,t.resource.DNA.max+=t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10,!0)}},mitochondria:{id:"evolution-mitochondria",title:F("evo_mitochondria_title"),desc:F("evo_mitochondria_desc"),condition:()=>t.evolution.hasOwnProperty("mitochondria")&&!t.race.evoFinalMenu,cost:{RNA:e=>is("mitochondria",75,50,e),DNA:e=>is("mitochondria",65,35,e)},effect:F("evo_mitochondria_effect"),action(){return!!Os($(this)[0])&&(t.evolution.mitochondria.count++,!0)}},sexual_reproduction:{id:"evolution-sexual_reproduction",title:F("evo_sexual_reproduction_title"),desc:F("evo_sexual_reproduction_desc"),reqs:{evo:1},grant:["evo",2],condition:()=>t.tech.evo&&1===t.tech.evo,cost:{DNA:()=>150},effect:F("evo_sexual_reproduction_effect"),action(){return!!Os($(this)[0])&&(t.evolution.final=20,!0)},queue_complete:()=>t.tech.evo&&1===t.tech.evo?1:0},phagocytosis:{id:"evolution-phagocytosis",title:F("evo_phagocytosis_title"),desc:F("evo_phagocytosis_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>t.tech.evo&&2===t.tech.evo,cost:{DNA:()=>175},effect:F("evo_phagocytosis_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_animal=1,t.evolution.final=40,!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0},chloroplasts:{id:"evolution-chloroplasts",title:()=>t.evolution.gselect?F("genelab_genus_plant"):F("evo_chloroplasts_title"),desc:F("evo_chloroplasts_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>Jr(2),cost:{DNA:()=>175},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_chloroplasts_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_chloroplasts_effect"),action(){return!!Os($(this)[0])&&(t.evolution.gselect?(t.tech.evo=7,t.tech.evo_plant=2,t.evolution.final=100):(t.tech.evo_plant=1,t.evolution.final=40),!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Pc("genus_plant")},chitin:{id:"evolution-chitin",title:()=>t.evolution.gselect?F("genelab_genus_fungi"):F("evo_chitin_title"),desc:F("evo_chitin_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>Jr(2),cost:{DNA:()=>175},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_chitin_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_chitin_effect"),action(){return!!Os($(this)[0])&&(t.evolution.gselect?(t.tech.evo=7,t.tech.evo_fungi=2,t.evolution.final=100):(t.tech.evo_fungi=1,t.evolution.final=40),!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Pc("genus_fungi")},exterminate:{id:"evolution-exterminate",title:()=>t.evolution.gselect?F("genelab_genus_synthetic"):F("evo_exterminate_title"),desc:F("evo_exterminate_desc"),reqs:{evo:2},grant:["evo",7],condition:()=>Jr(2)&&t.stats.achieve.obsolete&&t.stats.achieve.obsolete.l>=5,cost:{DNA:()=>200},effect:()=>F("evo_exterminate_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_synthetic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Pc("genus_synthetic")},multicellular:{id:"evolution-multicellular",title:F("evo_multicellular_title"),desc:F("evo_multicellular_desc"),reqs:{evo:3},grant:["evo",4],condition:()=>t.tech.evo&&3===t.tech.evo,cost:{DNA:()=>200},effect:F("evo_multicellular_effect"),action(){return!!Os($(this)[0])&&(t.evolution.final=60,!0)},queue_complete:()=>t.tech.evo&&3===t.tech.evo?1:0},spores:{id:"evolution-spores",title:F("evo_spores_title"),desc:F("evo_spores_desc"),reqs:{evo:4,evo_fungi:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:F("evo_nucleus_boost"),action(){return!!Os($(this)[0])&&(t.evolution.final=80,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},poikilohydric:{id:"evolution-poikilohydric",title:F("evo_poikilohydric_title"),desc:F("evo_poikilohydric_desc"),reqs:{evo:4,evo_plant:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:F("evo_nucleus_boost"),action(){return!!Os($(this)[0])&&(t.evolution.final=80,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},bilateral_symmetry:{id:"evolution-bilateral_symmetry",title:F("evo_bilateral_symmetry_title"),desc:F("evo_bilateral_symmetry_desc"),reqs:{evo:4,evo_animal:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:F("evo_nucleus_boost"),action(){return!!Os($(this)[0])&&(t.evolution.final=80,t.tech.evo_insectoid=1,t.tech.evo_mammals=1,t.tech.evo_eggshell=1,t.tech.evo_eldritch=1,t.tech.evo_aquatic=1,t.tech.evo_fey=1,t.tech.evo_sand=1,t.tech.evo_heat=1,t.tech.evo_polar=1,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},bryophyte:{id:"evolution-bryophyte",title:F("evo_bryophyte_title"),desc:F("evo_bryophyte_desc"),reqs:{evo:5},grant:["evo",7],condition:()=>!(!t.tech.evo_plant&&!t.tech.evo_fungi)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_bryophyte_effect"),action(){return!!Os($(this)[0])&&(t.evolution.final=100,t.tech.evo_fungi&&(t.tech.evo_fungi=2),t.tech.evo_plant&&(t.tech.evo_plant=2),!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},athropods:{id:"evolution-athropods",title:F("evo_athropods_title"),desc:F("evo_athropods_desc"),reqs:{evo:5,evo_insectoid:1},grant:["evo",7],condition:()=>Jr(5),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_athropods_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_athropods_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_insectoid=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_insectoid")},mammals:{id:"evolution-mammals",title:F("evo_mammals_title"),desc:F("evo_mammals_desc"),reqs:{evo:5,evo_mammals:1},grant:["evo",6],condition:()=>t.tech.evo&&5===t.tech.evo,cost:{DNA:()=>245},effect:F("evo_mammals_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_humanoid=1,t.tech.evo_giant=1,t.tech.evo_small=1,t.tech.evo_animalism=1,t.tech.evo_demonic=1,t.tech.evo_angelic=1,t.evolution.final=90,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},humanoid:{id:"evolution-humanoid",title:F("evo_humanoid_title"),desc:F("evo_humanoid_desc"),reqs:{evo:6,evo_humanoid:1},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_humanoid_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_humanoid_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_humanoid=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_humanoid")},gigantism:{id:"evolution-gigantism",title:F("evo_gigantism_title"),desc:F("evo_gigantism_desc"),reqs:{evo:6,evo_giant:1},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_gigantism_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_gigantism_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_giant=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_giant")},dwarfism:{id:"evolution-dwarfism",title:F("evo_dwarfism_title"),desc:F("evo_dwarfism_desc"),reqs:{evo:6,evo_small:1},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_dwarfism_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_dwarfism_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_small=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_small")},animalism:{id:"evolution-animalism",title:F("evo_animalism_title"),desc:F("evo_animalism_desc"),reqs:{evo:6,evo_animalism:1},grant:["evo",7],condition:()=>Jr(6)&&t.tech.evo_animalism&&1===t.tech.evo_animalism,cost:{DNA:()=>250},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_animalism_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_animalism_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_animalism=2,t.evolution.final=95,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo&&1===t.tech.evo_animalism?1:0},carnivore:{id:"evolution-carnivore",title:F("evo_carnivore_title"),desc:F("evo_carnivore_desc"),reqs:{evo_animalism:2},grant:["evo_animalism",3],condition:()=>Jr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_carnivore_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_carnivore_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo=7,t.tech.evo_carnivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Pc("genus_carnivore")},herbivore:{id:"evolution-herbivore",title:F("evo_herbivore_title"),desc:F("evo_herbivore_desc"),reqs:{evo_animalism:2},grant:["evo_animalism",3],condition:()=>Jr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_herbivore_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_herbivore_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo=7,t.tech.evo_herbivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Pc("genus_herbivore")},omnivore:{id:"evolution-omnivore",title:F("evo_omnivore_title"),desc:F("evo_omnivore_desc"),reqs:{evo_animalism:2,locked:1},grant:["evo_animalism",3],condition:()=>Jr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},wiki:!1,effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_omnivore_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_omnivore_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_omnivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Pc("genus_omnivore")},celestial:{id:"evolution-celestial",title:F("evo_celestial_title"),desc:F("evo_celestial_desc"),reqs:{evo:6,evo_angelic:1},grant:["evo",7],condition:()=>!!("eden"===t.city.biome||t.blood.unbound&&t.blood.unbound>=3)&&Jr(6),cost:{DNA:()=>260},effect:()=>F("evo_celestial_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_angelic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_angelic")},demonic:{id:"evolution-demonic",title:F("evo_demonic_title"),desc:F("evo_demonic_desc"),reqs:{evo:6,evo_demonic:1},grant:["evo",7],condition:()=>!!("hellscape"===t.city.biome||t.blood.unbound&&t.blood.unbound>=3)&&Jr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"===t.race.universe?`
          ${F("evo_demonic_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_demonic_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_demonic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_demonic")},eldritch:{id:"evolution-eldritch",title:F("evo_eldritch_title"),desc:F("evo_eldritch_desc"),reqs:{evo:5,evo_eldritch:1},grant:["evo",7],condition:()=>!(!t.stats.achieve.nightmare||!t.stats.achieve.nightmare.mg)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_eldritch_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_eldritch=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_eldritch")},aquatic:{id:"evolution-aquatic",title:F("evo_aquatic_title"),desc:F("evo_aquatic_desc"),reqs:{evo:5,evo_aquatic:1},grant:["evo",7],condition:()=>!(!["oceanic","swamp"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_aquatic_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_aquatic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_aquatic")},fey:{id:"evolution-fey",title:F("evo_fey_title"),desc:F("evo_fey_desc"),reqs:{evo:5,evo_fey:1},grant:["evo",7],condition:()=>!(!["forest","swamp","taiga"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_fey_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_fey=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_fey")},heat:{id:"evolution-heat",title:F("evo_heat_title"),desc:F("evo_heat_desc"),reqs:{evo:5,evo_heat:1},grant:["evo",7],condition:()=>!(!["volcanic","ashland"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_heat_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_heat=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_heat")},polar:{id:"evolution-polar",title:F("evo_polar_title"),desc:F("evo_polar_desc"),reqs:{evo:5,evo_polar:1},grant:["evo",7],condition:()=>!(!["tundra","taiga"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_polar_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_polar=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_polar")},sand:{id:"evolution-sand",title:F("evo_sand_title"),desc:F("evo_sand_desc"),reqs:{evo:5,evo_sand:1},grant:["evo",7],condition:()=>!(!["desert","ashland"].includes(t.city.biome)&&!t.blood.unbound)&&Jr(5),cost:{DNA:()=>260},effect:F("evo_sand_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_sand=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Pc("genus_sand")},eggshell:{id:"evolution-eggshell",title:F("evo_eggshell_title"),desc:F("evo_eggshell_desc"),reqs:{evo:5,evo_eggshell:1},grant:["evo",6],condition:()=>t.tech.evo&&5===t.tech.evo&&!t.evolution.gselect,cost:{DNA:()=>245},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_eggshell_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_eggshell_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_eggshell=2,t.evolution.final=90,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},endothermic:{id:"evolution-endothermic",title:()=>t.evolution.gselect?F("genelab_genus_avian"):F("evo_endothermic_title"),desc:F("evo_endothermic_desc"),reqs:{evo:6,evo_eggshell:2},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:F("evo_endothermic_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_avian=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_avian")},ectothermic:{id:"evolution-ectothermic",title:()=>t.evolution.gselect?F("genelab_genus_reptilian"):F("evo_ectothermic_title"),desc:F("evo_ectothermic_desc"),reqs:{evo:6,evo_eggshell:2},grant:["evo",7],condition:()=>Jr(6),cost:{DNA:()=>260},effect:F("evo_ectothermic_effect"),action(){return!!Os($(this)[0])&&(t.tech.evo_reptilian=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Pc("genus_reptilian")},sentience:{id:"evolution-sentience",title:F("evo_sentience_title"),desc:F("evo_sentience_desc"),reqs:{evo:7},grant:["evo",8],condition:()=>t.tech.evo&&7===t.tech.evo&&100===t.evolution.final,cost:{RNA:()=>300,DNA:()=>300},effect:()=>t.evolution.exterminate?F("evo_sentience_ai_effect"):F("evo_sentience_effect"),action(){if(Os($(this)[0])){let e=[],a="humanoid";for(let e in li)if(t.tech[`evo_${e}`]&&t.tech[`evo_${e}`]>=2){a=e;break}if(t.race.junker||t.race.sludge){let r=t.race.sludge?"sludge":"junker";t.race.jtype=a,e.push(r)}else for(let t in Yr){let r=Yr[t];di[r].type===a&&e.push(r)}t.race.species=e[Math.floor(m(0,e.length))],t.stats.achieve[`extinct_${t.race.species}`]&&t.stats.achieve[`extinct_${t.race.species}`].l>=1&&(t.race.species=e[Math.floor(m(0,e.length))]),Ls()}return!1},emblem(){for(let e in Yr){let a=Yr[e];if(t.tech[`evo_${di[a].type}`]&&t.tech[`evo_${di[a].type}`]>=2)return Pc(`genus_${di[a].type}`)}return""},queue_complete:()=>t.tech.evo&&7===t.tech.evo?1:0}},city:{gift:{id:"city-gift",title:F("city_gift"),desc:F("city_gift_desc"),wiki:!1,category:"outskirts",reqs:{primitive:1},queue_complete:()=>0,not_tech:["santa"],not_trait:["cataclysm","lone_survivor"],class:["hgift"],condition(){const e=new Date;if(11!==e.getMonth()||11===e.getMonth()&&(e.getDate()<=16||e.getDate()>=25)){let e=!1;return t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(a){t.special.gift[a]&&(e=!0)})),e}return!1},count(){let e=0;return t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(a){t.special.gift[a]&&e++})),e},action(){if(!t.settings.pause){const e=new Date;let a=!1;if(t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(e){t.special.gift[e]&&(a=e)})),11!==e.getMonth()||11===e.getMonth()&&(e.getDate()<=16||e.getDate()>=25))if("g2019"===a)t.special&&t.special.gift&&(delete t.special.gift[a],"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=100,t.stats.antiplasmid+=100,Di(F("city_gift_msg",[100,F("arpa_genepool_effect_antiplasmid")]),"info",!1,["events"])):(t.prestige.Plasmid.count+=100,t.stats.plasmid+=100,Di(F("city_gift_msg",[100,F("arpa_genepool_effect_plasmid")]),"info",!1,["events"])),hs());else if(t.special&&t.special.gift){delete t.special.gift[a];let e=100+(t.stats.hasOwnProperty("reset")?t.stats.reset:0)+(t.stats.hasOwnProperty("mad")?t.stats.mad:0),r=(t.stats.hasOwnProperty("bioseed")?t.stats.bioseed:0)+(t.stats.hasOwnProperty("cataclysm")?t.stats.cataclysm:0),s=[];if(t.stats.died+t.stats.tdied>0){let e=t.stats.died+t.stats.tdied;t.resource.Coal.amount+=e,s.push(`${e.toLocaleString()} ${F("resource_Coal_name")}`)}if("antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=e,t.stats.antiplasmid+=e,s.push(`${e.toLocaleString()} ${F("resource_AntiPlasmid_plural_name")}`)):(t.prestige.Plasmid.count+=e,t.stats.plasmid+=e,s.push(`${e.toLocaleString()} ${F("resource_Plasmid_plural_name")}`)),r>0&&(t.prestige.Phage.count+=r,t.stats.phage+=r,s.push(`${r.toLocaleString()} ${F("resource_Phage_name")}`)),t.stats.hasOwnProperty("achieve")){let e=t.stats.achieve.whitehole?t.stats.achieve.whitehole.l:0;e+=t.stats.achieve.heavy?t.stats.achieve.heavy.l:0,e+=t.stats.achieve.canceled?t.stats.achieve.canceled.l:0,e+=t.stats.achieve.eviltwin?t.stats.achieve.eviltwin.l:0,e+=t.stats.achieve.microbang?t.stats.achieve.microbang.l:0,e+=t.stats.achieve.pw_apocalypse?t.stats.achieve.pw_apocalypse.l:0;let r=t.stats.achieve.ascended?t.stats.achieve.ascended.l:0,i=t.stats.achieve.corrupted?t.stats.achieve.corrupted.l:0,c=t.stats.achieve.obsolete?t.stats.achieve.obsolete.l:0;if(e>30&&(e=30),r>5&&(r=5),i>5&&(i=5),e>0){let a=+(e/7.5).toFixed(2);t.prestige.Dark.count+=a,t.stats.dark+=a,s.push(`${a} ${F("resource_Dark_name")}`)}if(r>0&&(t.prestige.Harmony.count+=r,t.stats.harmony+=r,s.push(`${r} ${F("resource_Harmony_name")}`)),i>0){let e=5*i,a=i;t.prestige.Blood_Stone.count+=e,t.stats.blood+=e,t.prestige.Artifact.count+=a,t.stats.artifact+=a,s.push(`${e} ${F("resource_Blood_Stone_name")}`),s.push(`${a} ${F("resource_Artifact_name")}`)}"g2020"!==a&&c>0&&(t.prestige.AICore.count+=c,t.stats.cores+=c,s.push(`${c} ${F("resource_AICore_name")}`))}Di(F("city_gift2_msg",[s.join(", ")]),"info",!1,["events"]),hs()}}return!1},touchlabel:F("open")},food:{id:"city-food",title:()=>Ic().active?t.tech.conjuring?F("city_trick_conjure"):F("city_trick"):t.tech.conjuring?F("city_food_conjure"):F("city_food"),desc(){let e=$(this)[0].val(!1);return Ic().active?t.tech.conjuring?F("city_trick_conjure_desc",[e]):F("city_trick_desc",[e]):t.tech.conjuring?F("city_food_conjure_desc",[e]):F("city_food_desc",[e])},category:"outskirts",reqs:{primitive:1},not_trait:["soul_eater","cataclysm","artifical"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring?1:0},action(){return t.settings.pause||(t.resource.Food.amount=1&&(a*=10,t.resource.Food.amountIc().active?t.tech.conjuring&&t.tech.conjuring>=2?F("city_dig_conjour"):F("city_dig"):t.tech.conjuring&&t.tech.conjuring>=2?F("city_lumber_conjure"):F("city_lumber"),desc(){let e=$(this)[0].val(!1);return Ic().active?t.tech.conjuring&&t.tech.conjuring>=2?F("city_dig_conjour_desc",[e]):F("city_dig_desc",[e]):t.tech.conjuring&&t.tech.conjuring>=2?F("city_lumber_conjure_desc",[e]):F("city_lumber_desc",[e])},category:"outskirts",reqs:{},not_trait:["evil","cataclysm"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||(t.resource.Lumber.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Lumber.amountt.tech.conjuring&&t.tech.conjuring>=2?F("city_conjour",[t.resource.Stone.name]):F("city_gather",[t.resource.Stone.name]),desc(){let e=$(this)[0].val(!1);return t.tech.conjuring&&t.tech.conjuring>=2?F("city_stone_conjour_desc",[e,t.resource.Stone.name]):F(t.race.sappy?"city_amber_desc":"city_stone_desc",[e,t.resource.Stone.name])},category:"outskirts",reqs:{primitive:2},not_trait:["cataclysm","lone_survivor"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||(t.resource.Stone.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Stone.amountt.tech.conjuring&&t.tech.conjuring>=2?F("city_chrysotile_conjour"):F("city_gather",[t.resource.Chrysotile.name]),desc(){let e=$(this)[0].val(!1);return t.tech.conjuring&&t.tech.conjuring>=2?F("city_stone_conjour_desc",[e,t.resource.Chrysotile.name]):F("city_stone_desc",[e,t.resource.Chrysotile.name])},category:"outskirts",reqs:{primitive:2},trait:["smoldering"],not_trait:["cataclysm","lone_survivor"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||t.resource.Chrysotile.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Chrysotile.amountt.race.soul_eater?t.tech.primitive?t.resource.hasOwnProperty("furs")&&t.resource.Furs.display?F("city_evil_desc3"):F("city_evil_desc2"):F("city_evil_desc1"):t.resource.hasOwnProperty("furs")&&t.resource.Furs.display?F("city_evil_desc4"):F("city_evil_desc1"),category:"outskirts",reqs:{},trait:["evil"],not_trait:["kindling_kindred","smoldering","cataclysm"],queue_complete:()=>0,action(){if(!t.settings.pause){let e=t.race.strong?ui.strong.vars()[0]:1;t.genes.enhance&&(e*=2),t.race.smoldering||(t.resource.Lumber.amount25e3},queue_complete:()=>t.city.slave_pen?4*t.city.slave_pen.count-t.city.slave_pen.slaves:0,action(){return!!(t.city.slave_pen&&4*t.city.slave_pen.count>t.city.slave_pen.slaves&&Os($(this)[0]))&&(t.city.slave_pen.slaves++,t.resource.Slave.amount=t.city.slave_pen.slaves,!0)},touchlabel:F("purchase")},s_alter:{id:"city-s_alter",title:F("city_s_alter"),desc:()=>t.city.hasOwnProperty("s_alter")&&t.city.s_alter.count>=1?`
          ${F("city_s_alter")}
          ${F("city_s_alter_desc")}
          `:F("city_s_alter"),category:"outskirts",reqs:{mining:1},trait:["cannibalize"],not_trait:["cataclysm","lone_survivor"],inflation:!1,cost:{Stone:e=>(e||0)+(t.city.hasOwnProperty("s_alter")?t.city.s_alter.count:0)>=1?0:100},effect(){let e=`
          ${F("city_s_alter_sacrifice",[t.civic[t.civic.d_job]?t.civic[t.civic.d_job].workers:0])}
          `;if(t.city.hasOwnProperty("s_alter")&&t.city.s_alter.rage>0&&(e+=`
          ${F("city_s_alter_rage",[ui.cannibalize.vars()[0],ic(t.city.s_alter.rage)])}
          `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.regen>0&&(e+=`
          ${F("city_s_alter_regen",[ui.cannibalize.vars()[0],ic(t.city.s_alter.regen)])}
          `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.mind>0&&(e+=`
          ${F("city_s_alter_mind",[ui.cannibalize.vars()[0],ic(t.city.s_alter.mind)])}
          `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.mine>0&&(e+=`
          ${F("city_s_alter_mine",[ui.cannibalize.vars()[0],ic(t.city.s_alter.mine)])}
          `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.harvest>0){let a=t.race.evil&&!t.race.soul_eater?F("job_reclaimer"):F("job_lumberjack");e+=`
          ${F("city_s_alter_harvest",[ui.cannibalize.vars()[0],ic(t.city.s_alter.harvest),a])}
          `}return e},action(){if(Os($(this)[0])){if(0===t.city.s_alter.count)t.city.s_alter.count++;else if(t.civic[t.civic.d_job].workers>0){t.resource[t.race.species].amount--,t.civic[t.civic.d_job].workers--,t.stats.sac++,t.resource.Food.amount+=Math.rand(250,1e3);let e=300,a=600;if(t.tech.sacrifice)switch(t.tech.sacrifice){case 1:e=600,a=1500;break;case 2:e=1800,a=3600;break;case 3:e=5400,a=16200}switch(t.race.kindling_kindred||t.race.smoldering?Math.rand(0,4):Math.rand(0,5)){case 0:t.city.s_alter.rage+=Math.rand(e,a);break;case 1:t.city.s_alter.mind+=Math.rand(e,a);break;case 2:t.city.s_alter.regen+=Math.rand(e,a);break;case 3:t.city.s_alter.mine+=Math.rand(e,a);break;case 4:t.city.s_alter.harvest+=Math.rand(e,a)}}return!0}return!1},touchlabel:F("tech_dist_sacrifice")},basic_housing:{id:"city-basic_housing",title:()=>Es(),desc:F("city_basic_housing_desc"),desc(){return 1===$(this)[0].citizens()?F("city_basic_housing_desc"):F("city_basic_housing_desc_plural",[$(this)[0].citizens()])},category:"residential",reqs:{housing:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.basic_housing?t.city.basic_housing.count:0)+e>=5?Yi("basic_housing",e,20,1.17):0),Lumber:e=>t.race.kindling_kindred||t.race.smoldering?0:Yi("basic_housing",e,10,1.23),Stone:e=>t.race.kindling_kindred?Yi("basic_housing",e,10,1.23):0,Chrysotile:e=>t.race.smoldering?Yi("basic_housing",e,10,1.23):0,Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.sappy?`
          ${F("plus_max_resource",[e,F("citizen")])}
          ${F("city_grove_effect",[2.5])}
          `:F("plus_max_resource",[e,F("citizen")])},action(){return!!Os($(this)[0])&&(t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=$(this)[0].citizens(),t.city.basic_housing.count++,t.settings.showCivic=!0,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},cottage:{id:"city-cottage",title:()=>Is("medium"),desc(){return F("city_cottage_desc",[$(this)[0].citizens()])},category:"residential",reqs:{housing:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("cottage",e,900,1.15),Plywood:e=>Yi("cottage",e,25,1.25),Brick:e=>Yi("cottage",e,20,1.25),Wrought_Iron:e=>Yi("cottage",e,15,1.25),Iron:e=>t.city.ptrait.includes("unstable")?Yi("cottage",e,5,1.25):0,Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens();if(t.tech.home_safe){let a=Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?5e3:2e3:1e3);return`
          ${F("plus_max_citizens",[e])}
          ${F("plus_max_resource",[`$${a.toLocaleString()}`,F("resource_Money_name")])}
          `}return F("plus_max_citizens",[e])},action(){return!!Os($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens(),t.city.cottage.count++,!0)},citizens(){let e=2;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},apartment:{id:"city-apartment",title:()=>Is("large"),desc(){return`
          ${F("city_apartment_desc",[$(this)[0].citizens()])}
          ${F("requires_power")}
          `},category:"residential",reqs:{housing:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("apartment",e,1750,1.26)-500,Crystal:e=>"magic"===t.race.universe?Yi("apartment",e,25,1.22):0,Furs:e=>Yi("apartment",e,725,1.32)-500,Copper:e=>Yi("apartment",e,650,1.32)-500,Cement:e=>Yi("apartment",e,700,1.32)-500,Steel:e=>Yi("apartment",e,800,1.32)-500,Horseshoe:()=>t.race.hooved?5:0},effect(){let e=N("extravagant",2),a=$(this)[0].citizens();if(t.tech.home_safe){let r=Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?1e4:5e3:2e3);return e&&(r*=2),`
          ${F("plus_max_citizens",[a])}. ${F("minus_power",[$(this)[0].powered()])}
          ${F("plus_max_resource",[`$${r.toLocaleString()}`,F("resource_Money_name")])}
          `}return`${F("plus_max_citizens",[a])}. ${F("minus_power",[$(this)[0].powered()])}`},powered:()=>oc(N("extravagant",1)||1),action(){return!!Os($(this)[0])&&(t.city.apartment.count++,xs($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens()),!0)},citizens(){let e=N("extravagant",2),a=e?5+e:5;return t.race.high_pop&&(a*=ui.high_pop.vars()[0]),a}},lodge:{id:"city-lodge",title:F("city_lodge"),desc:()=>t.race.detritivore?F("city_lodge_desc_alt"):F("city_lodge_desc"),category:"residential",reqs:{housing:1,currency:1},not_trait:["cataclysm","lone_survivor"],condition:()=>!!((t.race.soul_eater||t.race.detritivore||t.race.artifical||t.race.unfathomable)&&t.tech.s_lodge||t.tech.hunting&&t.tech.hunting>=2),cost:{Money:e=>Yi("lodge",e,50,1.32),Lumber:e=>Yi("lodge",e,20,1.36),Stone:e=>Yi("lodge",e,10,1.36),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.carnivore&&!t.race.artifical?`
          ${F("plus_max_resource",[e,F("citizen")])}
          ${F("city_lodge_effect",[5])}
          `:F("plus_max_resource",[e,F("citizen")])},action(){return!!Os($(this)[0])&&(t.city.lodge.count++,t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=1,t.settings.showCivic=!0,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}},smokehouse:{id:"city-smokehouse",title:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?F("city_smokehouse_easter"):F("city_smokehouse"),desc:F("city_smokehouse_desc"),category:"trade",reqs:{hunting:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("smokehouse",e,85,1.32),Lumber:e=>Yi("smokehouse",e,65,1.36),Stone:e=>Yi("smokehouse",e,50,1.36)},effect:()=>`
          ${F("plus_max_resource",[cs(Lr(100)),F("resource_Food_name")])}
          ${F("city_smokehouse_effect",[10])}
          `,action(){return!!Os($(this)[0])&&(t.city.smokehouse.count++,t.resource.Food.max+=cs(Lr(100)),!0)}},soul_well:{id:"city-soul_well",title:F("city_soul_well"),desc:F("city_soul_well_desc"),category:"trade",reqs:{soul_eater:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.soul_well?t.city.soul_well.count:0)+e>=3?Yi("soul_well",e,50,1.32):0),Lumber:e=>Yi("soul_well",e,20,1.36),Stone:e=>Yi("soul_well",e,10,1.36)},effect(){let e=cs(Lr(500));return`
          ${F("city_soul_well_effect",[t.race.ghostly?2+ui.ghostly.vars()[1]:2])}
          ${F("plus_max_resource",[e,F("resource_Souls_name")])}
          `},action(){return!!Os($(this)[0])&&(t.city.soul_well.count++,t.resource.Food.max+=cs(Lr(500)),!0)}},slave_pen:{id:"city-slave_pen",title:F("city_slave_pen"),desc:F("city_slave_pen"),category:"commercial",reqs:{slaves:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("slave_pen",e,250,1.32),Lumber:e=>Yi("slave_pen",e,100,1.36),Stone:e=>Yi("slave_pen",e,75,1.36),Copper:e=>Yi("slave_pen",e,10,1.36),Nanite:e=>t.race.deconstructor?Yi("slave_pen",e,4,1.36):0},effect(){let e=t.city.slave_pen?4*t.city.slave_pen.count:4,a=t.city.slave_pen?t.city.slave_pen.slaves:0;return`
          ${F("city_slave_pen_effect",[4])}
          ${F("city_slave_pen_effect2",[a,e])}
          `},action(){return!!Os($(this)[0])&&(t.city.slave_pen.count++,t.resource.Slave.display=!0,t.resource.Slave.amount=t.city.slave_pen.slaves,t.resource.Slave.max=4*t.city.slave_pen.count,!0)}},transmitter:{id:"city-transmitter",title:F("city_transmitter"),desc:()=>`
          ${F("city_transmitter_desc")}
          ${F("requires_power")}
          `,category:"residential",reqs:{high_tech:4},trait:["artifical"],cost:{Money:e=>t.city.transmitter&&t.city.transmitter.count>=3?Yi("transmitter",e,50,1.32):0,Copper:e=>Yi("transmitter",e,20,1.36),Steel:e=>Yi("transmitter",e,10,1.36)},effect(){let e=+Pe("transmitter").toFixed(2),a=Lr(100);return`
          ${F("gain",[e,t.resource.Food.name])}
          ${F("city_transmitter_effect",[a])}
          ${F("minus_power",[$(this)[0].powered()])}
          `},powered:()=>oc(.5),powerBalancer:()=>[{r:"Food",k:"lpmod"}],action(){return!!Os($(this)[0])&&(t.city.transmitter.count++,xs($(this)[0]),!0)}},captive_housing:Vr("captive_housing","city"),farm:{id:"city-farm",title:F("city_farm"),desc:F("city_farm_desc"),category:"residential",reqs:{agriculture:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.farm?t.city.farm.count:0)+e>=3?Yi("farm",e,50,1.32):0),Lumber:e=>Yi("farm",e,20,1.36),Stone:e=>Yi("farm",e,10,1.36),Horseshoe:e=>t.race.hooved&&(t.city.farm?t.city.farm.count:0)+(e||0)>=2?1:0},effect(){let e=$(this)[0].citizens();return t.tech.farm?`
          ${F("city_farm_effect")}
          ${F("plus_max_resource",[e,F("citizen")])}
          `:F("city_farm_effect")},action(){return!!Os($(this)[0])&&(t.city.farm.count++,t.civic.farmer.display=!0,t.tech.farm&&(t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=$(this)[0].citizens(),t.settings.showCivic=!0),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e},flair:()=>t.tech.agriculture>=7?F("city_farm_flair2"):F("city_farm_flair1")},compost:{id:"city-compost",title:F("city_compost_heap"),desc:F("city_compost_heap_desc"),category:"residential",reqs:{compost:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.compost?t.city.compost.count:0)+e>=3?Yi("compost",e,50,1.32):0),Lumber:e=>Yi("compost",e,12,1.36),Stone:e=>Yi("compost",e,12,1.36)},effect(){let e=1.2+.8*(t.tech.compost?t.tech.compost:0);e*="grassland"===t.city.biome?ji.grassland.vars()[0]:1,e*="savanna"===t.city.biome?ji.savanna.vars()[0]:1,e*="ashland"===t.city.biome?ji.ashland.vars()[0]:1,e*="volcanic"===t.city.biome?ji.volcanic.vars()[0]:1,e*="hellscape"===t.city.biome?ji.hellscape.vars()[0]:1,e*=t.city.ptrait.includes("trashed")?Si.trashed.vars()[0]:1,e=+e.toFixed(2);let a=cs(Lr(200)),r=t.race.kindling_kindred?"":`
          ${F("city_compost_heap_effect2",[.5,t.resource.Lumber.name])}
          `;return`
          ${F("city_compost_heap_effect",[e])}
          ${F("city_compost_heap_effect3",[a])}
          ${r}`},switchable:()=>!0,action(){return!!Os($(this)[0])&&(t.city.compost.count++,t.city.compost.on++,t.resource.Food.max+=cs(Lr(200)),!0)}},mill:{id:"city-mill",title:()=>t.tech.agriculture>=5?F("city_mill_title2"):F("city_mill_title1"),desc(){let e=t.tech.agriculture>=5?5:3;return t.tech.agriculture>=6?F("city_mill_desc2",[e,-1*$(this)[0].powered()]):F("city_mill_desc1",[e])},category:"utility",reqs:{agriculture:4},not_tech:["wind_plant"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("mill",e,1e3,1.31),Lumber:e=>Yi("mill",e,600,1.33),Iron:e=>Yi("mill",e,150,1.33),Cement:e=>Yi("mill",e,125,1.33)},powered:()=>t.race.environmentalist?-1.5:-1,power_reqs:{agriculture:6},effect:()=>t.tech.agriculture>=6&&`${F("city_on")} ${F("city_mill_effect1")} ${F("city_off")} ${F("city_mill_effect2")}`,action(){return!!Os($(this)[0])&&(t.city.mill.count++,!0)}},windmill:{id:"city-windmill",title:()=>t.race.unfathomable?F("tech_watermill"):F("city_mill_title2"),desc:()=>t.race.unfathomable?F("tech_watermill"):F("city_mill_title2"),wiki:!1,category:"utility",reqs:{wind_plant:1},not_trait:["cataclysm","lone_survivor"],powered:()=>t.race.environmentalist?-1.5:-1,power_reqs:{false:1},cost:{Money:e=>Yi("windmill",e,1e3,1.31),Lumber:e=>Yi("windmill",e,600,1.33),Iron:e=>Yi("windmill",e,150,1.33),Cement:e=>Yi("windmill",e,125,1.33)},effect(){return`
          ${F("space_dwarf_reactor_effect1",[-1*$(this)[0].powered()])}
          `},action(){return!!Os($(this)[0])&&(t.city.windmill.count++,!0)}},silo:{id:"city-silo",title:F("city_silo"),desc:F("city_food_storage"),category:"trade",reqs:{agriculture:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("silo",e,85,1.32),Lumber:e=>Yi("silo",e,65,1.36),Stone:e=>Yi("silo",e,50,1.36),Iron:e=>(t.city.silo?t.city.silo.count:0)+(e||0)>=4&&t.city.ptrait.includes("unstable")?Yi("silo",e,10,1.36):0},effect:()=>F("plus_max_resource",[cs(Lr(500)),F("resource_Food_name")]),action(){return!!Os($(this)[0])&&(t.city.silo.count++,t.resource.Food.max+=cs(Lr(500)),!0)}},assembly:Vr("assembly","city"),garrison:{id:"city-garrison",title:()=>t.race.flier?F("city_garrison_flier"):F("city_garrison"),desc:F("city_garrison_desc"),category:"military",reqs:{military:1,housing:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("garrison",e,240,1.5),Stone:e=>Yi("garrison",e,260,1.46),Iron:e=>(t.city.garrison?t.city.garrison.count:0)+(e||0)>=4&&t.city.ptrait.includes("unstable")?Yi("garrison",e,50,1.4):0,Horseshoe:()=>t.race.hooved?t.race.chameleon?1:2:0},effect(){let e=t.tech.military>=5?la(3):la(2);return t.race.chameleon&&e--,F("plus_max_resource",[e,F("civics_garrison_soldiers")])},switchable:()=>!0,action(){if(Os($(this)[0])){t.settings.showMil=!0,t.settings.msgFilters.combat.unlocked||(t.settings.msgFilters.combat.unlocked=!0,t.settings.msgFilters.combat.vis=!0),t.civic.garrison.display||(t.civic.garrison.display=!0,sc({el:"#garrison"},"update"),sc({el:"#c_garrison"},"update"));let e=t.tech.military>=5?3:2;return t.race.chameleon&&(e-=t.city.garrison.count),t.civic.garrison.max+=e,t.city.garrison.count++,t.city.garrison.on++,t.resource.Furs.display=!0,!0}return!1}},hospital:{id:"city-hospital",title:F("city_hospital"),desc:F("city_hospital_desc"),category:"military",reqs:{medic:1},not_trait:["cataclysm","artifical"],cost:{Money:e=>Yi("hospital",e,22e3,1.32),Furs:e=>Yi("hospital",e,4e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?Yi("hospital",e,500,1.32):0,Aluminium:e=>Yi("hospital",e,1e4,1.32)},effect(){let e=t.tech.reproduction&&t.tech.reproduction>=2?`
          ${F("city_hospital_effect2")}
          `:"",a=`
          ${F("city_hospital_effect",[5*t.tech.medic])}
          ${e}`;return!t.race.artifical&&t.race.hasOwnProperty("vax")&&(a+=`
          ${F("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
          `),a},action(){return!!Os($(this)[0])&&(t.city.hospital.count++,!0)}},boot_camp:{id:"city-boot_camp",title:()=>t.race.artifical?F("city_boot_camp_art"):F("city_boot_camp"),desc:()=>t.race.artifical?F("city_boot_camp_art_desc",[di[t.race.species].name]):F("city_boot_camp_desc"),category:"military",reqs:{boot_camp:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("boot_camp",e,5e4,1.32),Lumber:e=>Yi("boot_camp",e,21500,1.32),Iron:e=>t.city.ptrait.includes("unstable")?Yi("boot_camp",e,300,1.32):0,Aluminium:e=>Yi("boot_camp",e,12e3,1.32),Brick:e=>Yi("boot_camp",e,1400,1.32)},effect(){let e=t.tech.boot_camp>=2?8:5;t.blood.lust&&(e+=.2*t.blood.lust);let a=N("militant",0);a&&(e*=1+a/100);let r=t.tech.spy&&t.tech.spy>=3?`
          ${F("city_boot_camp_effect",[e])}
          ${F("city_boot_camp_effect2",[10])}
          `:`
          ${F("city_boot_camp_effect",[e])}
          `;return t.race.artifical&&!t.race.orbit_decayed&&(r+=`
          ${F("city_boot_camp_art_effect",[5*(t.tech.medic||1)])}
          `),t.race.artifical&&t.race.hasOwnProperty("vax")&&(desc+=`
          ${F("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
          `),r},action(){return!!Os($(this)[0])&&(t.city.boot_camp.count++,!0)}},shed:{id:"city-shed",title:()=>t.tech.storage<=2?F("city_shed_title1"):t.tech.storage>=4?F("city_shed_title3"):F("city_shed_title2"),desc(){let e=t.tech.storage>=3?t.tech.storage>=4?F("city_shed_desc_size3"):F("city_shed_desc_size2"):F("city_shed_desc_size1");return F("city_shed_desc",[e])},category:"trade",reqs:{storage:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("shed",e,75,1.22),Lumber:e=>t.tech.storage&&t.tech.storage<4?Yi("shed",e,55,1.32):0,Stone:e=>t.tech.storage&&t.tech.storage<3?Yi("shed",e,45,1.32):0,Iron:e=>t.tech.storage&&t.tech.storage>=4?Yi("shed",e,22,1.32):0,Cement:e=>t.tech.storage&&t.tech.storage>=3?Yi("shed",e,18,1.32):0},res(){let e=["Lumber","Stone","Chrysotile","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal"];return t.tech.storage>=3&&t.resource.Steel.display&&e.push("Steel"),t.tech.storage>=4&&t.resource.Titanium.display&&e.push("Titanium"),t.tech.shelving&&t.tech.shelving>=3&&t.resource.Graphene.display&&e.push("Graphene"),t.tech.shelving&&t.tech.shelving>=3&&t.resource.Stanene.display&&e.push("Stanene"),t.race.unfathomable&&e.push("Food"),e},val(e){switch(e){case"Food":return 50;case"Lumber":case"Stone":case"Chrysotile":return 300;case"Crystal":return 8;case"Furs":case"Iron":return 125;case"Copper":case"Aluminium":return 90;case"Cement":return 100;case"Coal":return 75;case"Steel":return 40;case"Titanium":return 20;case"Graphene":return 15;case"Stanene":return 25;default:return 0}},effect(){let e='
          ',a=os();for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${F("plus_max_resource",[k(+(Lr($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return e+="
          ",e},wide:!0,action(){if(Os($(this)[0])){t.city.shed.count++;let e=os();for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=Lr($(this)[0].val(a)*e));return!0}return!1}},storage_yard:{id:"city-storage_yard",title:F("city_storage_yard"),desc:F("city_storage_yard_desc"),category:"trade",reqs:{container:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("storage_yard",e,10,Rs(1.36)),Brick:e=>Yi("storage_yard",e,3,Rs(1.35)),Wrought_Iron:e=>Yi("storage_yard",e,5,Rs(1.35))},effect(){let e=t.tech.container>=3?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.tech.trade&&t.tech.trade>=3?`
          ${F("plus_max_resource",[e,F("resource_Crates_name")])}
          ${F("city_trade_effect",[1])}
          `:F("plus_max_resource",[e,F("resource_Crates_name")])},action(){if(Os($(this)[0])){!1===t.resource.Crates.display&&Di(F("city_storage_yard_msg"),"info",!1,["progress"]),t.city.storage_yard.count++,t.settings.showResources=!0,t.settings.showStorage=!0,t.settings.showMarket||(t.settings.marketTabs=1);let e=t.tech.container>=3?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Crates.max+=e,t.resource.Crates.display||(t.resource.Crates.display=!0,rc($("#resources")),rr(),t.settings.tabLoad&&(ar("storage"),K())),!0}return!1}},warehouse:{id:"city-warehouse",title:F("city_warehouse"),desc:F("city_warehouse_desc"),category:"trade",reqs:{steel_container:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("warehouse",e,400,Rs(1.26)),Cement:e=>Yi("warehouse",e,75,Rs(1.26)),Sheet_Metal:e=>Yi("warehouse",e,25,Rs(1.25))},effect(){let e=t.tech.steel_container>=2?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),F("plus_max_resource",[e,F("resource_Containers_name")])},action(){if(Os($(this)[0])){!1===t.resource.Containers.display&&Di(F("city_warehouse_msg"),"info",!1,["progress"]),t.city.warehouse.count++,t.settings.showResources=!0,t.settings.showStorage=!0;let e=t.tech.steel_container>=2?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Containers.max+=e,t.resource.Containers.display||(t.resource.Containers.display=!0,rc($("#resources")),rr(),t.settings.tabLoad&&ar("storage")),!0}return!1}},bank:{id:"city-bank",title:F("city_bank"),desc:()=>F("city_bank_desc",[di[t.race.species].home]),category:"commercial",reqs:{banking:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("bank",e,250,1.35),Lumber:e=>Yi("bank",e,75,1.32),Stone:e=>Yi("bank",e,100,1.35),Iron:e=>(t.city.bank?t.city.bank.count:0)+(e||0)>=2&&t.city.ptrait.includes("unstable")?Yi("bank",e,30,1.3):0},effect(){let e=Hs();return e=Lr(e),e=(+e.toFixed(0)).toLocaleString(),t.tech.banking>=2?`
          ${F("plus_max_resource",[`$${e}`,F("resource_Money_name")])}
          ${F("plus_max_resource",[la(1),F("banker_name")])}
          `:F("plus_max_resource",[`$${e}`,F("resource_Money_name")])},action(){return!!Os($(this)[0])&&(t.resource.Money.max+=Lr(1800),t.city.bank.count++,t.civic.banker.max=la(t.city.bank.count),!0)}},pylon:{id:"city-pylon",title:F("city_pylon"),desc:F("city_pylon"),category:"industrial",reqs:{magic:2},not_trait:["cataclysm","orbit_decayed"],cost:{Money:e=>(e=e||0,(t.city.pylon?t.city.pylon.count:0)+e>=2?Yi("pylon",e,10,1.48):0),Stone:e=>Yi("pylon",e,12,1.42),Crystal:e=>Yi("pylon",e,8,1.42)-3},effect(){let e=Lr(5);return`
          ${F("gain",[+(.01*nc("magic")).toFixed(3),t.resource.Mana.name])}
          ${F("plus_max_resource",[e,t.resource.Mana.name])}
          `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!Os($(this)[0])&&(t.city.pylon.count++,t.resource.Mana.max+=Lr(5),!0)}},conceal_ward:{id:"city-conceal_ward",title:F("city_conceal_ward"),desc:F("city_conceal_ward"),category:"industrial",reqs:{roguemagic:3},not_trait:["cataclysm","orbit_decayed"],cost:{Money:e=>Yi("conceal_ward",e,500,1.25),Mana:e=>{return Yi("conceal_ward",e,(a=42,t.tech.nexus&&t.tech.roguemagic&&t.tech.roguemagic>=7&&(a*=.92**t.tech.nexus),a),1.25);var a},Crystal:e=>Yi("conceal_ward",e,5,1.25)},effect:()=>`
          ${F("city_conceal_ward_effect",[t.tech.roguemagic&&t.tech.roguemagic>=8?1.25:1])}
          `,action(){return!!Os($(this)[0])&&(t.city.conceal_ward.count++,!0)}},graveyard:{id:"city-graveyard",title:F("city_graveyard"),desc:F("city_graveyard_desc"),category:"industrial",reqs:{reclaimer:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.graveyard?t.city.graveyard.count:0)+e>=5?Yi("graveyard",e,5,1.85):0),Lumber:e=>Yi("graveyard",e,2,1.95),Stone:e=>Yi("graveyard",e,6,1.9)},effect(){let e=cs(Lr(100));return`
          ${F("city_graveyard_effect",[8])}
          ${F("plus_max_resource",[e,t.resource.Lumber.name])}
          `},action(){return!!Os($(this)[0])&&(t.city.graveyard.count++,t.resource.Lumber.max+=cs(Lr(100)),!0)}},lumber_yard:{id:"city-lumber_yard",title:F("city_lumber_yard"),desc:F("city_lumber_yard_desc"),category:"industrial",reqs:{axe:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.lumber_yard?t.city.lumber_yard.count:0)+e>=5?Yi("lumber_yard",e,5,1.85):0),Lumber:e=>Yi("lumber_yard",e,6,1.9),Stone:e=>Yi("lumber_yard",e,2,1.95)},effect(){let e=cs(Lr(100));return`
          ${F("city_lumber_yard_effect",[2])}
          ${F("plus_max_resource",[e,t.resource.Lumber.name])}
          `},action(){return!!Os($(this)[0])&&(t.city.lumber_yard.count++,t.civic.lumberjack.display=!0,t.resource.Lumber.max+=cs(Lr(100)),!0)}},sawmill:{id:"city-sawmill",title:F("city_sawmill"),desc:F("city_sawmill_desc"),category:"industrial",reqs:{saw:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("sawmill",e,3e3,1.26),Iron:e=>Yi("sawmill",e,400,1.26),Cement:e=>Yi("sawmill",e,420,1.26)},effect(){let e=t.tech.saw>=2?8:5,a=`
          ${F("plus_max_resource",[cs(Lr(200)),t.resource.Lumber.name])}
          ${F("city_lumber_yard_effect",[e])}
          `;return t.tech.foundry&&t.tech.foundry>=4&&(a+=`
          ${F("city_sawmill_effect2",[2])}
          `),t.city.powered&&(a+=`
          ${F("city_sawmill_effect3",[4,$(this)[0].powered()])}
          `),a},powered:()=>oc(1),powerBalancer:()=>!!t.city.sawmill.hasOwnProperty("psaw")&&[{r:"Lumber",k:"psaw"}],action(){return!!Os($(this)[0])&&(t.city.sawmill.count++,t.resource.Lumber.max+=cs(Lr(200)),xs($(this)[0]),!0)}},rock_quarry:{id:"city-rock_quarry",title:()=>t.race.flier?F("city_rock_quarry_alt"):F("city_rock_quarry"),desc:()=>t.race.flier?F("city_rock_quarry_desc_alt",[t.resource.Stone.name]):F("city_rock_quarry_desc"),category:"industrial",reqs:{mining:1},not_trait:["cataclysm","sappy"],cost:{Money:e=>(e=e||0,(t.city.rock_quarry?t.city.rock_quarry.count:0)+e>=2?Yi("rock_quarry",e,20,1.45):0),Lumber:e=>Yi("rock_quarry",e,50,1.36),Stone:e=>Yi("rock_quarry",e,10,1.36)},effect(){let e=cs(Lr(100)),a=t.race.smoldering?`
          ${F("plus_max_resource",[e,t.resource.Chrysotile.name])}
          `:"";return t.tech.mine_conveyor?`
          ${F("city_rock_quarry_effect1",[2])}
          ${F("plus_max_resource",[e,t.resource.Stone.name])}
          ${a}
          ${F("city_rock_quarry_effect2",[4,$(this)[0].powered()])}
          `:`
          ${F("city_rock_quarry_effect1",[2])}
          ${F("plus_max_resource",[e,t.resource.Stone.name])}
          ${a}`},special:()=>!!t.race.smoldering,powered:()=>oc(1),powerBalancer:()=>!!t.city.rock_quarry.hasOwnProperty("cnvay")&&(t.city.hasOwnProperty("metal_refinery")&&t.city.rock_quarry.hasOwnProperty("almcvy")?[{r:"Stone",k:"cnvay"},{r:"Aluminium",k:"almcvy"}]:[{r:"Stone",k:"cnvay"}]),power_reqs:{mine_conveyor:1},action(){if(Os($(this)[0])){t.city.rock_quarry.count++,t.civic.quarry_worker.display=!0;let e=cs(Lr(100));return t.resource.Stone.max+=e,t.race.smoldering&&t.resource.Chrysotile.display&&(t.settings.showCivic=!0,t.settings.showIndustry=!0,t.resource.Chrysotile.max+=e),t.tech.mine_conveyor&&xs($(this)[0]),!0}return!1}},cement_plant:{id:"city-cement_plant",title:F("city_cement_plant"),desc:F("city_cement_plant_desc"),category:"industrial",reqs:{cement:1},not_trait:["cataclysm","lone_survivor","flier"],cost:{Money:e=>Yi("cement_plant",e,3e3,1.5),Lumber:e=>Yi("cement_plant",e,1800,1.36),Stone:e=>Yi("cement_plant",e,2e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?Yi("cement_plant",e,275,1.32):0},effect(){if(t.tech.cement>=5){let e=t.tech.cement>=6?8:5;return`
          ${F("city_cement_plant_effect1",[la(2)])}
          ${F("city_cement_plant_effect2",[$(this)[0].powered(),e])}
          `}return F("city_cement_plant_effect1",[la(2)])},powered:()=>oc(2),powerBalancer:()=>!!t.city.cement_plant.hasOwnProperty("cnvay")&&[{r:"Cement",k:"cnvay"}],power_reqs:{cement:5},action(){return!!Os($(this)[0])&&(t.resource.Cement.display=!0,t.city.cement_plant.count++,t.civic.cement_worker.display=!0,t.civic.cement_worker.max=t.city.cement_plant.count*la(2),t.tech.cement&&t.tech.cement>=5&&xs($(this)[0]),!0)}},foundry:{id:"city-foundry",title:F("city_foundry"),desc:F("city_foundry_desc"),category:"industrial",reqs:{foundry:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("foundry",e,750,1.36),Stone:e=>Yi("foundry",e,100,1.36),Copper:e=>Yi("foundry",e,250,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("foundry",e,40,1.36):0},effect(){let e=`
          ${F("city_foundry_effect1",[la(1)])}
          `;return t.tech.foundry>=2&&(e+=`
          ${F("city_crafted_mats",[t.tech.foundry>=5?t.tech.foundry>=8?8:5:3])}
          `),t.tech.foundry>=6&&(e+=`
          ${F("city_foundry_effect2",[2])}
          `),e},action(){return!!Os($(this)[0])&&(0===t.city.foundry.count&&(t.race.no_craft?Di(F("city_foundry_msg2"),"info",!1,["progress"]):Di(F("city_foundry_msg1"),"info",!1,["progress"])),t.city.foundry.count++,t.civic.craftsman.max+=la(1),t.civic.craftsman.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.resource.Plywood.display=!0),t.resource.Brick.display=!0,t.resource.Iron.display&&(t.resource.Wrought_Iron.display=!0),t.resource.Aluminium.display&&(t.resource.Sheet_Metal.display=!0),ha(),!0)}},factory:{id:"city-factory",title:F("city_factory"),desc:`
          ${F("city_factory_desc")}
          ${F("requires_power")}
          `,category:"industrial",reqs:{high_tech:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("factory",e,25e3,Fs(1.32)),Cement:e=>Yi("factory",e,1e3,Fs(1.32)),Steel:e=>Yi("factory",e,7500,Fs(1.32)),Titanium:e=>Yi("factory",e,2500,Fs(1.32))},effect(){let e=`
          ${F("city_factory_effect")}
          ${F("minus_power",[$(this)[0].powered()])}
          `;return t.tech.foundry>=7&&(e+=`
          ${F("city_crafted_mats",[5])}
          `),e},powered:()=>oc(3),special:!0,action(){return!!Os($(this)[0])&&(t.city.factory.count++,t.resource.Alloy.display=!0,t.tech.polymer&&(t.resource.Polymer.display=!0),xs($(this)[0])&&t.city.factory.Alloy++,t.settings.showIndustry=!0,Ws(),!0)}},nanite_factory:Vr("nanite_factory","city"),smelter:{id:"city-smelter",title:F("city_smelter"),desc:F("city_smelter_desc"),category:"industrial",reqs:{smelting:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("smelter",e,1e3,Fs(1.32)),Iron:e=>Yi("smelter",e,500,Fs(1.33))},effect(){var e=t.tech.smelting>=3?t.tech.smelting>=7?15:12:10;return t.race.pyrophobia&&(e*=.9),t.tech.smelting>=2&&!t.race.steelen?F("city_smelter_effect2",[e]):F("city_smelter_effect1",[e])},special:!0,action(){return!!Os($(this)[0])&&(t.city.smelter.count++,t.race.kindling_kindred||t.race.smoldering||t.race.artifical?t.race.artifical?t.city.smelter.Oil++:t.race.evil?t.city.smelter.Wood++:t.city.smelter.Coal++:t.city.smelter.Wood++,t.city.smelter.Iron++,t.settings.showIndustry=!0,Ws(),!0)},flair:`
          ${F("city_smelter_flair1")}
          ${F("city_smelter_flair2")}
          `},metal_refinery:{id:"city-metal_refinery",title:F("city_metal_refinery"),desc:F("city_metal_refinery_desc"),category:"industrial",reqs:{alumina:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("metal_refinery",e,2500,1.35),Iron:e=>t.city.ptrait.includes("unstable")?Yi("metal_refinery",e,125,1.35):0,Steel:e=>Yi("metal_refinery",e,350,1.35)},powered:()=>oc(2),powerBalancer:()=>!!t.city.metal_refinery.hasOwnProperty("pwr")&&[{r:"Aluminium",k:"cnvay"}],power_reqs:{alumina:2},effect(){let e=t.race.sappy?"city_metal_refinery_effect_alt":"city_metal_refinery_effect";return t.tech.alumina>=2?`${F(e,[6])} ${F("city_metal_refinery_effect2",[6,12,$(this)[0].powered()])}`:F(e,[6])},action(){return!!Os($(this)[0])&&(t.city.metal_refinery.count++,t.resource.Aluminium.display=!0,t.city.foundry&&t.city.foundry.count>0&&!t.resource.Sheet_Metal.display&&(t.resource.Sheet_Metal.display=!0,ha()),t.tech.alumina>=2&&xs($(this)[0]),!0)}},mine:{id:"city-mine",title:F("city_mine"),desc:F("city_mine_desc"),category:"industrial",reqs:{mining:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("mine",e,60,Fs(1.6)),Lumber:e=>Yi("mine",e,175,Fs(1.38))},effect(){return t.tech.mine_conveyor?`
          ${F("city_mine_effect1",[la(1)])}
          ${F("city_mine_effect2",[$(this)[0].powered(),5])}
          `:F("city_mine_effect1",[la(1)])},powered:()=>oc(1),powerBalancer:()=>!(!t.city.mine.hasOwnProperty("cpow")||!t.city.mine.hasOwnProperty("ipow"))&&[{r:"Copper",k:"cpow"},{r:"Iron",k:"ipow"}],power_reqs:{mine_conveyor:1},action(){return!!Os($(this)[0])&&(t.city.mine.count++,t.resource.Copper.display=!0,t.civic.miner.display=!0,t.civic.miner.max=la(t.city.mine.count),t.tech.mine_conveyor&&xs($(this)[0]),!0)},flair:()=>"avian"===di[t.race.species].type?F("city_mine_flair_avian"):""},coal_mine:{id:"city-coal_mine",title:F("city_coal_mine"),desc:F("city_coal_mine_desc"),category:"industrial",reqs:{mining:4},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("coal_mine",e,480,Fs(1.4)),Lumber:e=>Yi("coal_mine",e,250,Fs(1.36)),Iron:e=>t.city.ptrait.includes("unstable")?Yi("coal_mine",e,28,Fs(1.36)):0,Wrought_Iron:e=>Yi("coal_mine",e,18,Fs(1.36))},effect(){return t.tech.mine_conveyor?`
          ${F("city_coal_mine_effect1",[la(1)])}
          ${F("city_coal_mine_effect2",[$(this)[0].powered(),5])}
          `:F("city_coal_mine_effect1",[la(1)])},powered:()=>oc(1),powerBalancer:()=>t.city.coal_mine.hasOwnProperty("cpow")&&t.city.coal_mine.hasOwnProperty("upow")&&t.resource.Uranium.display?[{r:"Coal",k:"cpow"},{r:"Uranium",k:"upow"}]:!!t.city.coal_mine.hasOwnProperty("cpow")&&[{r:"Coal",k:"cpow"}],power_reqs:{mine_conveyor:1},action(){return!!Os($(this)[0])&&(t.city.coal_mine.count++,t.resource.Coal.display=!0,t.civic.coal_miner.display=!0,t.civic.coal_miner.max=la(t.city.coal_mine.count),t.tech.mine_conveyor&&xs($(this)[0]),!0)}},oil_well:{id:"city-oil_well",title:F("city_oil_well"),desc:F("city_oil_well_desc"),category:"industrial",reqs:{oil:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("oil_well",e,5e3,Fs(1.5)),Iron:e=>t.city.ptrait.includes("unstable")?Yi("oil_well",e,450,Fs(1.5)):0,Cement:e=>Yi("oil_well",e,5250,Fs(1.5)),Steel:e=>Yi("oil_well",e,6e3,Fs(1.5))},effect:()=>F("city_oil_well_effect",[+Pe("oil_well").toFixed(2),Lr(500)]),action(){return!!Os($(this)[0])&&(t.city.oil_well.count++,t.resource.Oil.max+=Lr(500),1===t.city.oil_well.count&&(t.resource.Oil.display=!0,Ws()),!0)},flair:F("city_oil_well_flair")},oil_depot:{id:"city-oil_depot",title:F("city_oil_depot"),desc:F("city_oil_depot_desc"),category:"trade",reqs:{oil:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("oil_depot",e,2500,Fs(1.46)),Iron:e=>t.city.ptrait.includes("unstable")?Yi("oil_depot",e,325,Fs(1.36)):0,Cement:e=>Yi("oil_depot",e,3750,Fs(1.46)),Sheet_Metal:e=>Yi("oil_depot",e,100,Fs(1.45))},effect(){let e=Lr(1e3);e*=t.tech.world_control?1.5:1;let a=`
          ${F("plus_max_resource",[e,t.resource.Oil.name])}.
          `;if(t.resource.Helium_3.display){let e=Lr(400);e*=t.tech.world_control?1.5:1,a+=`
          ${F("plus_max_resource",[e,t.resource.Helium_3.name])}.
          `}if(t.tech.uranium>=2){let e=Lr(250);e*=t.tech.world_control?1.5:1,a+=`
          ${F("plus_max_resource",[e,t.resource.Uranium.name])}.
          `}return a},action(){return!!Os($(this)[0])&&(t.city.oil_depot.count++,t.resource.Oil.max+=Lr(1e3)*(t.tech.world_control?1.5:1),t.resource.Helium_3.display&&(t.resource.Helium_3.max+=Lr(400)*(t.tech.world_control?1.5:1)),t.tech.uranium>=2&&(t.resource.Uranium.max+=Lr(250)*(t.tech.world_control?1.5:1)),!0)}},trade:{id:"city-trade",title:F("city_trade"),desc:F("city_trade_desc"),category:"trade",reqs:{trade:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("trade",e,500,1.36),Lumber:e=>Yi("trade",e,125,1.36),Stone:e=>Yi("trade",e,50,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("trade",e,15,1.36):0,Furs:e=>Yi("trade",e,65,1.36)},effect(){let e=t.race.xenophobic||t.race.nomadic?t.tech.trade:t.tech.trade+1;return t.tech.trade&&t.tech.trade>=3&&e--,t.race.flier&&(e+=ui.flier.vars()[1]),F("city_trade_effect",[e])},action(){if(Os($(this)[0])){t.city.trade.count++;let e=t.race.xenophobic||t.race.nomadic?t.tech.trade:t.tech.trade+1;return t.tech.trade&&t.tech.trade>=3&&e--,t.city.market.mtrade+=e,!0}return!1}},wharf:{id:"city-wharf",title:F("city_wharf"),desc:F("city_wharf_desc"),category:"trade",era:"industrialized",reqs:{wharf:1},not_trait:["thalassophobia","cataclysm"],cost:{Money:e=>Yi("wharf",e,62e3,1.32),Lumber:e=>Yi("wharf",e,44e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?Yi("wharf",e,200,1.32):0,Cement:e=>Yi("wharf",e,3e3,1.32),Oil:e=>Yi("wharf",e,750,1.32)},effect(){let e=t.tech.world_control?15:10;return t.tech.particles&&t.tech.particles>=2&&(e*=2),`
          ${F("city_trade_effect",[2])}
          ${F("city_wharf_effect")}
          ${F("plus_max_crates",[e])}
          ${F("plus_max_containers",[e])}
          `},action(){if(Os($(this)[0])){!1===t.resource.Containers.display&&(Di(F("city_warehouse_msg"),"info",!1,["progress"]),t.resource.Containers.display=!0,rc($("#resources")),rr()),t.city.wharf.count++,t.city.market.mtrade+=2;let e=t.tech.world_control?15:10;return t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Crates.max+=e,t.resource.Containers.max+=e,!0}return!1}},tourist_center:{id:"city-tourist_center",title:F("city_tourist_center"),desc:F("city_tourist_center_desc"),category:"commercial",reqs:{monument:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("tourist_center",e,1e5,1.36),Stone:e=>Yi("tourist_center",e,25e3,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("tourist_center",e,1e3,1.36):0,Furs:e=>Yi("tourist_center",e,7500,1.36),Plywood:e=>Yi("tourist_center",e,5e3,1.36)},effect(){let e=t.tech.monument&&t.tech.monument>=3&&i.s_gate?3:1,a=("corpocracy"===t.civic.govern.type?2:1)*e,r=("corpocracy"===t.civic.govern.type?10:5)*e,s=("corpocracy"===t.civic.govern.type?4:2)*e,c="";t.stats.achieve.banana&&t.stats.achieve.banana.l>=4&&(c=`
          ${F("city_tourist_center_effect5",[("corpocracy"===t.civic.govern.type?6:3)*e])}
          `);let o="",n=N("pious",1);return n&&(o=`
          ${F("city_tourist_center_effect6",[("corpocracy"===t.civic.govern.type?2*n:n)*e])}
          `),`
          ${F("city_tourist_center_effect1",[t.resource.Food.name])}
          ${F("city_tourist_center_effect2",[a,Qr.city.amphitheatre.title()])}
          ${F("city_tourist_center_effect3",[r])}
          ${F("city_tourist_center_effect4",[s])}
          ${c}${o}`},powered:()=>oc(1),action(){return!!Os($(this)[0])&&(t.city.tourist_center.count++,t.city.tourist_center.on++,!0)}},amphitheatre:{id:"city-amphitheatre",title:()=>F(N("athleticism",0)?"city_stadium":"city_amphitheatre"),desc:()=>F(N("athleticism",0)?"city_stadium":"city_amphitheatre_desc"),category:"commercial",reqs:{theatre:1},not_trait:["joyless","cataclysm"],cost:{Money:e=>Yi("amphitheatre",e,500,1.55),Lumber:e=>Yi("amphitheatre",e,50,1.75),Stone:e=>Yi("amphitheatre",e,200,1.75),Iron:e=>t.city.ptrait.includes("unstable")?Yi("amphitheatre",e,18,1.36):0},effect(){let e=N("athleticism",0);return`
          ${F("city_max_entertainer",[la(N("athleticism",1)||1)])}
          ${F("city_max_morale",[e||1])}
          `},action(){return!!Os($(this)[0])&&(t.city.amphitheatre.count++,t.civic.entertainer.max+=la(1),t.civic.entertainer.display=!0,!0)},flair:()=>F(N("athleticism",0)?"city_stadium_flair":"city_amphitheatre_flair")},casino:{id:"city-casino",title:F("city_casino"),desc:F("city_casino"),category:"commercial",reqs:{gambling:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("casino",e,35e4,1.35),Iron:e=>t.city.ptrait.includes("unstable")?Yi("casino",e,2e3,1.35):0,Furs:e=>Yi("casino",e,6e4,1.35),Plywood:e=>Yi("casino",e,1e4,1.35),Brick:e=>Yi("casino",e,6e3,1.35)},effect(){let e=ss();return e+=`
          ${F("minus_power",[$(this)[0].powered()])}
          `,e},powered:()=>oc(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2?2:3),action(){return!!Os($(this)[0])&&(t.city.casino.count++,t.race.joyless||(t.civic.entertainer.max+=la(1),t.civic.entertainer.display=!0),xs($(this)[0]),!0)},flair:F("city_casino_flair")},temple:{id:"city-temple",title:F("city_temple"),desc:()=>F("city_temple_desc",["none"!==t.race.gods?di[t.race.gods.toLowerCase()].entity:di[t.race.species].entity]),category:"commercial",reqs:{theology:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("temple",e,50,1.36),Lumber:e=>Yi("temple",e,25,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("temple",e,6,1.36):0,Furs:e=>Yi("temple",e,15,1.36),Cement:e=>Yi("temple",e,10,1.36)},effect(){let e=rs();return t.genes.ancients&&t.genes.ancients>=2&&(e+=`
          ${F("city_temple_effect6",[la(1)])}
          `),e},action(){return!!Os($(this)[0])&&(t.genes.ancients&&t.genes.ancients>=2&&(t.civic.priest.display=!0),t.city.temple.count++,!0)}},shrine:{id:"city-shrine",title:F("city_shrine"),desc:()=>F("city_shrine_desc"),category:"commercial",reqs:{theology:2},trait:["magnificent"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("shrine",e,75,1.32),Stone:e=>Yi("shrine",e,65,1.32),Furs:e=>Yi("shrine",e,10,1.32),Copper:e=>Yi("shrine",e,15,1.32)},effect(){let e=`
          ${F("city_shrine_effect")}
          `;if(t.city.shrine&&t.city.shrine.morale>0&&(e+=`
          ${F("city_shrine_morale",[+Lc("morale").add.toFixed(1)])}
          `),t.city.shrine&&t.city.shrine.metal>0&&(e+=`
          ${F("city_shrine_metal",[+(100*(Lc("metal").mult-1)).toFixed(1)])}
          `),t.city.shrine&&t.city.shrine.know>0){let t=Lc("know");e+=`
          ${F("city_shrine_know",[(+t.add.toFixed(1)).toLocaleString()])}
          `,e+=`
          ${F("city_shrine_know2",[+(100*(t.mult-1)).toFixed(1)])}
          `}return t.city.shrine&&t.city.shrine.tax>0&&(e+=`
          ${F("city_shrine_tax",[+(100*(Lc("tax").mult-1)).toFixed(1)])}
          `),e},action(){if(Os($(this)[0])){if(t.city.shrine.count++,t.city.calendar.moon>0&&t.city.calendar.moon<7)t.city.shrine.morale++;else if(t.city.calendar.moon>7&&t.city.calendar.moon<14)t.city.shrine.metal++;else if(t.city.calendar.moon>14&&t.city.calendar.moon<21)t.city.shrine.know++;else if(t.city.calendar.moon>21)t.city.shrine.tax++;else switch(Math.floor(m(0,4))){case 0:t.city.shrine.morale++;break;case 1:t.city.shrine.metal++;break;case 2:t.city.shrine.know++;break;case 3:t.city.shrine.tax++}return!0}return!1}},meditation:{id:"city-meditation",title:F("city_meditation"),desc:F("city_meditation"),category:"commercial",reqs:{primitive:3},trait:["calm"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("meditation",e,50,1.2),Stone:e=>Yi("meditation",e,25,1.2),Furs:e=>Yi("meditation",e,8,1.2)},effect(){let e=t.resource.Zen.amount/(t.resource.Zen.amount+5e3);return`
          ${F("city_meditation_effect",[ui.calm.vars()[0]])}
          ${F("city_meditation_effect2",[2])}
          ${F("city_meditation_effect3",[1])}
          ${F("city_meditation_effect4",[`${(100*e).toFixed(2)}%`])}
          `},action(){return!!Os($(this)[0])&&(t.city.meditation.count++,t.resource.Zen.max+=ui.calm.vars()[0],!0)}},university:{id:"city-university",title:F("city_university"),desc:()=>F("city_university_desc",[di[t.race.species].home]),category:"science",reqs:{science:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("university",e,900,1.5)-500,Lumber:e=>Yi("university",e,500,1.36)-200,Stone:e=>Yi("university",e,750,1.36)-350,Crystal:e=>"magic"===t.race.universe?Yi("university",e,5,1.36):0,Iron:e=>(t.city.university?t.city.university.count:0)+(e||0)>=3&&t.city.ptrait.includes("unstable")?Yi("university",e,25,1.36):0},effect(){let e=+$(this)[0].knowVal().toFixed(0);return`
          ${F("city_university_effect",[la(1)])}
          ${F("city_max_knowledge",[e.toLocaleString()])}
          `},knowVal(){let e=1,a=t.tech.science&&t.tech.science>=8?700:500;t.city.ptrait.includes("permafrost")&&(a+=Si.permafrost.vars()[1]),t.tech.science>=4&&(e+=.02*t.city.library.count),t.space.observatory&&t.space.observatory.count>0&&(e+=.05*c.observatory),t.portal.sensor_drone&&t.tech.science>=14&&(e+=.02*i.sensor_drone),t.race.hard_of_hearing&&(e*=1-ui.hard_of_hearing.vars()[0]/100),t.race.curious&&(e*=1+ui.curious.vars()[0]/100*t.resource[t.race.species].amount);let r=Pi("cath");if(r>0&&(e*=1+ui.curious.vars(3)[0]*r),i.s_gate&&n.scavenger){let t=Et("gxy_alien2");e*=1+n.scavenger*t/4}let s=N("teacher",0);s&&(e*=1+s/100);let o=N("athleticism",2);o&&(e*=1-o/100),Kc()&&(e*=Lc("know").mult);let l=a*e;if(t.tech.supercollider){let e=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;l*=t.tech.supercollider/e+1}return t.race.orbit_decayed&&(t.space.satellite&&(l*=1+.12*t.space.satellite.count),t.tech.biotech&&t.tech.biotech>=1&&(l*=2)),l},action(){if(Os($(this)[0])){let e=t.tech.science&&t.tech.science>=8?700:500;if(t.tech.science>=4&&(e*=1+.02*t.city.library.count),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,t.city.university.count++,t.civic.professor.display=!0,t.civic.professor.max=t.city.university.count,!0}return!1}},library:{id:"city-library",title:F("city_library"),desc:()=>F("city_library_desc",[di[t.race.species].home]),category:"science",reqs:{science:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("library",e,45,1.2),Crystal:e=>"magic"===t.race.universe?Yi("library",e,2,1.2):0,Iron:e=>t.city.ptrait.includes("unstable")?Yi("library",e,4,1.2):0,Furs:e=>Yi("library",e,22,1.2),Plywood:e=>Yi("library",e,20,1.2),Brick:e=>Yi("library",e,15,1.2)},effect(){let e=125;t.race.nearsighted&&(e*=1-ui.nearsighted.vars()[0]/100),t.race.studious&&(e*=1+ui.studious.vars()[1]/100);let a=Pi("elven");if(a>0&&(e*=1+ui.studious.vars(1)[1]/100*a),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*t.city.temple.count),t.tech.science&&t.tech.science>=5){let a=na(t.civic.scientist.workers,"scientist");t.race.high_pop&&(a=Me(a)),e*=1+.12*a}let r=N("teacher",0);r&&(e*=1+r/100);let s=N("athleticism",2);s&&(e*=1-s/100);let i=N("muckraker",1);i&&(e*=1+i/100),e=+e.toFixed(0);let c=N("muckraker",2),o=c?5-c:5;return t.race.autoignition&&(o-=ui.autoignition.vars()[0],o<0&&(o=0)),`
          ${F("city_max_knowledge",[e.toLocaleString()])}
          ${F("city_library_effect",[o])}
          `},action(){if(Os($(this)[0])){let e=125;return t.race.nearsighted&&(e*=1-ui.nearsighted.vars()[0]/100),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*t.city.temple.count),t.tech.science&&t.tech.science>=5&&(e*=1+.12*na(t.civic.scientist.workers,"scientist")),e=+e.toFixed(1),t.resource.Knowledge.max+=e,t.city.library.count++,t.tech.science&&t.tech.science>=3&&(t.civic.professor.impact=.5+.01*t.city.library.count),!0}return!1},flair:F("city_library_flair")},wardenclyffe:{id:"city-wardenclyffe",title:()=>Ts(),desc:F("city_wardenclyffe_desc"),category:"science",reqs:{high_tech:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("wardenclyffe",e,5e3,1.22),Knowledge:e=>Yi("wardenclyffe",e,t.race.logical?1e3-ui.logical.vars()[0]:1e3,1.22),Crystal:e=>"magic"===t.race.universe?Yi("wardenclyffe",e,100,1.22):0,Copper:e=>Yi("wardenclyffe",e,500,1.22),Iron:e=>t.city.ptrait.includes("unstable")?Yi("wardenclyffe",e,75,1.22):0,Cement:e=>Yi("wardenclyffe",e,350,1.22),Sheet_Metal:e=>Yi("wardenclyffe",e,125,1.2),Nanite:e=>t.race.deconstructor?Yi("wardenclyffe",e,50,1.18):0},effect(){let e=1e3;if(t.city.ptrait.includes("magnetic")&&(e+=Si.magnetic.vars()[1]),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}t.space.satellite&&(e*=1+.04*t.space.satellite.count);let a=N("athleticism",2);a&&(e*=1-a/100),e=+e.toFixed(0);let r=`
          ${F("city_wardenclyffe_effect1",[la(1),t.civic.scientist?t.civic.scientist.name:F("job_scientist")])}
          ${F("city_max_knowledge",[e.toLocaleString()])}
          `;if(t.city.powered){let e=t.tech.science>=7?2500:2e3;if(t.city.ptrait.includes("magnetic")&&(e+=Si.magnetic.vars()[1]),t.space.satellite&&(e*=1+.04*t.space.satellite.count),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}let a=N("athleticism",2);if(a&&(e*=1-a/100),e=+e.toFixed(1),t.tech.science>=15&&(r+=`
          ${F("city_wardenclyffe_effect4",[2])}
          `),"magic"===t.race.universe&&(r+=`
          ${F("plus_max_resource",[Lr(8),t.resource.Mana.name])}
          `),t.tech.broadcast){let a=t.tech.broadcast;r+=`
          ${F("city_wardenclyffe_effect3",[$(this)[0].powered(),e.toLocaleString(),a])}
          `}else r+=`
          ${F("city_wardenclyffe_effect2",[$(this)[0].powered(),e.toLocaleString()])}
          `;t.race.artifical&&(r+=`
          ${F("city_transmitter_effect",[Lr(250)])}oc(2),action(){if(Os($(this)[0])){let e=1e3;if(t.city.wardenclyffe.count++,t.civic.scientist.display=!0,t.civic.scientist.max=t.city.wardenclyffe.count,xs($(this)[0])&&(e=t.tech.science>=7?2500:2e3),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,!0}return!1},flair:()=>"magic"===t.race.universe?`
          ${F("city_wizard_tower_flair")}
          `:t.race.evil?`
          ${F("city_babel_flair")}
          `:`
          ${F("city_wardenclyffe_flair1")}
          ${F("city_wardenclyffe_flair2")}
          `},biolab:{id:"city-biolab",title:F("city_biolab"),desc:`
          ${F("city_biolab_desc")}
          ${F("requires_power")}
          `,category:"science",reqs:{genetics:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("biolab",e,25e3,1.3),Knowledge:e=>Yi("biolab",e,5e3,1.3),Copper:e=>Yi("biolab",e,1250,1.3),Iron:e=>t.city.ptrait.includes("unstable")?Yi("biolab",e,160,1.3):0,Alloy:e=>Yi("biolab",e,350,1.3)},effect(){let e=3e3;return t.portal.sensor_drone&&t.tech.science>=14&&(e*=1+.02*i.sensor_drone),t.tech.science>=20&&(e*=3),t.tech.science>=21&&(e*=1.45),t.tech.biotech>=1&&(e*=2.5),e=+e.toFixed(0),`${F("city_max_knowledge",[e.toLocaleString()])}, ${F("minus_power",[$(this)[0].powered()])}`},powered:()=>oc(2),action(){return!!Os($(this)[0])&&(t.city.biolab.count++,xs($(this)[0])&&(t.resource.Knowledge.max+=3e3),!0)}},coal_power:{id:"city-coal_power",title:()=>t.race.environmentalist?F("city_hydro_power"):F("magic"===t.race.universe?"city_mana_engine":"city_coal_power"),desc:()=>t.race.environmentalist?`
          ${F("city_hydro_power_desc")}
          `:`
          ${F("magic"===t.race.universe?"city_mana_engine_desc":"city_coal_power_desc")}
          ${F("requires_res",[F("magic"===t.race.universe?"resource_Mana_name":"resource_Coal_name")])}
          `,category:"utility",reqs:{high_tech:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("coal_power",e,1e4,Fs(1.22)),Crystal:e=>"magic"===t.race.universe?Yi("coal_power",e,125,Fs(1.22)):0,Copper:e=>Yi("coal_power",e,1800,Fs(1.22))-1e3,Iron:e=>t.city.ptrait.includes("unstable")?Yi("coal_power",e,175,Fs(1.22)):0,Cement:e=>Yi("coal_power",e,600,Fs(1.22)),Steel:e=>Yi("coal_power",e,2e3,Fs(1.22))-1e3},effect(){let e="magic"===t.race.universe?.05:.35,a=-$(this)[0].powered();return t.race.environmentalist?`+${a}MW`:`+${a}MW. ${F("magic"===t.race.universe?"city_mana_engine_effect":"city_coal_power_effect",[e])}`},powered(){let e=t.race.environmentalist?t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1?-5:-4:t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1?-6:-5,a=N("dirty_jobs",1);return a&&(e-=a),cc(e)},p_fuel:()=>"magic"===t.race.universe?{r:"Mana",a:t.race.environmentalist?0:.05}:{r:"Coal",a:t.race.environmentalist?0:.35},action(){return!!Os($(this)[0])&&(t.city.coal_power.count++,t.city.coal_power.on++,t.city.power+=5,!0)}},oil_power:{id:"city-oil_power",title:()=>t.race.environmentalist?F("city_wind_power"):F("city_oil_power"),desc:()=>t.race.environmentalist?`
          ${F("city_wind_power_desc")}
          `:`
          ${F("city_oil_power_desc")}
          ${F("requires_res",[F("resource_Oil_name")])}
          `,category:"utility",reqs:{oil:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("oil_power",e,5e4,Fs(1.22)),Copper:e=>Yi("oil_power",e,6500,Fs(1.22))+1e3,Iron:e=>t.city.ptrait.includes("unstable")?Yi("oil_power",e,180,Fs(1.22)):0,Aluminium:e=>Yi("oil_power",e,12e3,Fs(1.22)),Cement:e=>Yi("oil_power",e,5600,Fs(1.22))+1e3},effect(){let e=-$(this)[0].powered();return t.race.environmentalist?`+${e}MW`:`+${e}MW. ${F("city_oil_power_effect",[.65])}`},powered(){let e=0;if(t.race.environmentalist)if(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3){let a=1===t.city.calendar.wind?-7:-5;e=t.stats.achieve.dissipated.l>=5?a-2:a-1}else e=1===t.city.calendar.wind?-7:-5;else e=t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3?t.stats.achieve.dissipated.l>=5?-8:-7:-6;let a=N("dirty_jobs",1);return a&&(e-=a),cc(e)},p_fuel:()=>({r:"Oil",a:t.race.environmentalist?0:.65}),action(){return!!Os($(this)[0])&&(t.city.oil_power.count++,t.city.oil_power.on++,t.city.power+=6,!0)}},fission_power:{id:"city-fission_power",title:F("city_fission_power"),desc:`
          ${F("city_fission_power_desc")}
          ${F("requires_res",[F("resource_Uranium_name")])}
          `,category:"utility",reqs:{high_tech:5},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("fission_power",e,25e4,1.36),Copper:e=>Yi("fission_power",e,13500,1.36),Iron:e=>t.city.ptrait.includes("unstable")?Yi("fission_power",e,1750,1.36):0,Cement:e=>Yi("fission_power",e,10800,1.36),Titanium:e=>Yi("fission_power",e,7500,1.36)},effect(){return`+${-$(this)[0].powered()}MW. ${F("city_fission_power_effect",[.1])}`},powered:()=>cc(t.tech.uranium>=4?-18:-14),p_fuel:()=>({r:"Uranium",a:.1}),action(){return!!Os($(this)[0])&&(t.city.fission_power.count++,t.city.fission_power.on++,t.city.power+=14,!0)}},mass_driver:{id:"city-mass_driver",title:F("city_mass_driver"),desc:`
          ${F("city_mass_driver_desc")}
          ${F("requires_power")}
          `,category:"utility",reqs:{mass:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>Yi("mass_driver",e,375e3,1.32),Copper:e=>Yi("mass_driver",e,33e3,1.32),Iron:e=>Yi("mass_driver",e,42500,1.32),Iridium:e=>Yi("mass_driver",e,2200,1.32)},effect(){return`${t.tech.mass>=2?`
          ${F("city_mass_driver_effect2",[1,t.civic.scientist.name])}
          `:""}${F("city_mass_driver_effect",[t.race.truepath?6:5,Ac("name")])} ${F("minus_power",[$(this)[0].powered()])}`},powered(){let e=t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=4?4:5;return oc(t.tech.mass>=2?e-1:e)},action(){return!!Os($(this)[0])&&(t.city.mass_driver.count++,xs($(this)[0]),!0)}},replicator:{id:"city-replicator",title:F("tech_replicator"),desc:F("tech_replicator"),category:"utility",reqs:{special_hack:1},cost:{},wiki:!1,effect:()=>"fake structure",powered:()=>1,action:()=>!1}},tech:Rr,arpa:Oe("PhysicsTech"),genes:Oe("GeneTech"),blood:Oe("BloodTech"),space:Dt(),interstellar:St,galaxy:At,starDock:{probes:{id:"starDock-probes",title:F("star_dock_probe"),desc:()=>`
          ${F("star_dock_probe_desc")}
          `,reqs:{genesis:4},cost:{Money:e=>Yi("probes",e,35e4,t.race.truepath?1.125:1.25,"starDock"),Alloy:e=>Yi("probes",e,75e3,t.race.truepath?1.125:1.25,"starDock"),Polymer:e=>Yi("probes",e,85e3,t.race.truepath?1.125:1.25,"starDock"),Iridium:e=>Yi("probes",e,12e3,t.race.truepath?1.125:1.25,"starDock"),Mythril:e=>Yi("probes",e,3500,t.race.truepath?1.125:1.25,"starDock")},effect:()=>`
          ${F("star_dock_probe_effect")}
          `,action(){return!!Os($(this)[0])&&(t.starDock.probes.count++,!0)}},geck:{id:"starDock-geck",title:F("tech_geck"),desc:()=>`
          ${F("tech_geck_desc")}
          `,reqs:{geck:1},condition:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5),queue_complete:()=>0,no_multi:!0,cost:{Money:e=>Yi("geck",e,1e6,1.25,"starDock"),Elerium:e=>Yi("geck",e,1e3,1.25,"starDock"),Plasmid:e=>Yi("geck",e,25,1.4,"starDock")},effect:()=>`
          ${F("star_dock_geck_effect")}
          `,action(){return!!Os($(this)[0])&&(t.starDock.geck.count++,!0)}},seeder:{id:"starDock-seeder",title:()=>t.race.cataclysm?F("star_dock_exodus"):F("star_dock_seeder"),desc(){let e=t.race.cataclysm?F("star_dock_exodus"):F("star_dock_seeder");return t.starDock.seeder&&t.starDock.seeder.count>=100?`
          ${e}
          ${F("star_dock_seeder_desc2")}
          `:`
          ${e}
          ${F("star_dock_seeder_desc1")}
          `},reqs:{genesis:5},queue_size:10,queue_complete:()=>100-t.starDock.seeder.count,cost:{Money:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?1e5:0,Steel:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?25e3:0,Neutronium:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?240:0,Elerium:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?10:0,Nano_Tube:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?12e3:0},effect(e){let a=(e||0)+(t.starDock.seeder?t.starDock.seeder.count:0),r=a<100?F("star_dock_seeder_status1",[100-a]):F("star_dock_seeder_status2");return`
          ${t.race.cataclysm?F("star_dock_exodus_effect"):F("star_dock_seeder_effect")}
          ${r}
          `},action(){return!!(t.starDock.seeder.count<100&&Os($(this)[0]))&&(t.starDock.seeder.count++,t.starDock.seeder.count>=100&&(t.tech.genesis=6,Ei("starDock-seeder"),rc($("#modalBox")),zs(Qr.space.spc_gas.star_dock,"star_dock")),!0)}},prep_ship:{id:"starDock-prep_ship",title:F("star_dock_prep"),desc:()=>`
          ${t.race.cataclysm?F("star_dock_prep_cata_desc"):F("star_dock_prep_desc")}
          ${F("star_dock_genesis_desc2")}
          `,reqs:{genesis:6},queue_complete:()=>0,cost:{},effect(){let e=mc("bioseed"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
          ${t.race.cataclysm?F("star_dock_prep_cata_effect"):F("star_dock_prep_effect")}
          ${F("star_dock_genesis_effect2",[e.plasmid,a])}
          ${F("star_dock_genesis_effect3",[e.phage])}
          `},action:()=>(t.tech.genesis=7,Ei("starDock-prep_ship"),rc($("#modalBox")),zs(Qr.space.spc_gas.star_dock,"star_dock"),!0)},launch_ship:{id:"starDock-launch_ship",title:F("star_dock_genesis"),desc:()=>`
          ${t.race.cataclysm?F("star_dock_prep_cata_effect"):F("star_dock_genesis_desc1")}
          ${F("star_dock_genesis_desc2")}
          `,reqs:{genesis:7},queue_complete:()=>0,cost:{},effect(){let e=mc("bioseed"),a="antimatter"===t.race.universe?F("resource_AntiPlasmid_plural_name"):F("resource_Plasmid_plural_name");return`
          ${t.race.cataclysm?F("star_dock_genesis_cata_effect1"):F("star_dock_genesis_effect1")}
          ${F("star_dock_genesis_effect2",[e.plasmid,a])}
          ${F("star_dock_genesis_effect3",[e.phage])}
          `},action:()=>(function(){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"bioseed"});let a=t.race.species,r=t.race.gods,s=di[a].type,i=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,n=mc("bioseed");t.stats.bioseed++,Fc(),t.prestige.Phage.count+=n.phage,t.stats.phage+=n.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=n.plasmid,t.stats.antiplasmid+=n.plasmid):(t.prestige.Plasmid.count+=n.plasmid,t.stats.plasmid+=n.plasmid),Xc("seeder"),Xc(`biome_${c}`),o.forEach((function(e){Si.hasOwnProperty(e)&&Xc(`atmo_${e}`)})),Xc(`genus_${s}`),t.race.truepath&&Xc("exodus"),o.includes("dense")&&"heavy"===t.race.universe&&Xc("double_density"),t.race.junker&&"junker"===t.race.species&&eo("organ_harvester"),"hellscape"===t.city.biome&&"demonic"!==di[t.race.species].type&&eo("ill_advised"),void 0===t.tech.world_control&&Xc("cult_of_personality"),t.race.cataclysm&&Xc("iron_will",!1,5),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&Xc("gross");let l=0,u=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0?l++:t.city.geology[e]<0&&u++})),l>=4&&Xc("miners_dream"),u>=3&&eo("rocky_road"),t.race.steelen&&t.race.steelen>=1&&Xc("steelen"),"micro"===t.race.universe&&(t.race.small||t.race.compact?Xc("macro",!0):Xc("marble",!0)),so();let d=!!t.race.hasOwnProperty("srace")&&t.race.srace,_=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0,p=t.starDock.probes.count+1,h=t.starDock.hasOwnProperty("geck")?t.starDock.geck.count:0;t.stats.achieve.explorer&&(p+=t.stats.achieve.explorer.l),t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!0,probes:p,geck:h,seed:Math.floor(m(1e4)),ascended:!1},_>0&&(t.race.corruption=_),d&&(t.race.srace=d),Q({orbit:i,biome:c,ptrait:o,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),!1)}},portal:wa(),tauceti:Ze};function Zr(){let a=$("#evolution .evolving").nextAll();Object.values(a).forEach((function(e){rc($(e),!0)})),rc($("#evolution .evolving"),!0),t.evolution.bunker={count:1},Ms(Qr.evolution.bunker.id),As(),t.race.truepath||t.race.lone_survivor?(t.evolution.nerfed={count:0},t.evolution.badgenes={count:0}):("antimatter"===t.race.universe?t.evolution.mastery={count:0}:t.evolution.plasmid={count:0},t.evolution.crispr={count:0}),t.evolution.trade={count:0},t.evolution.craft={count:0},t.evolution.junker={count:0},t.evolution.joyless={count:0},t.evolution.steelen={count:0},(t.stats.achieve.whitehole||t.sim)&&(t.evolution.decay={count:0}),(t.stats.achieve.ascended||t.sim)&&(t.evolution.emfield={count:0}),(t.stats.achieve.scrooge||t.sim)&&(t.evolution.inflation={count:0}),(t.stats.achieve.shaken||t.sim)&&(t.evolution.cataclysm={count:0}),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&(t.evolution.banana={count:0},t.evolution.orbit_decay={count:0}),"standard"===t.race.universe&&(t.stats.achieve.whitehole||t.sim),"heavy"===t.race.universe&&(t.stats.achieve.seeder&&t.stats.achieve.seeder.h||t.sim),"magic"===t.race.universe&&(t.stats.achieve.ascended&&t.stats.achieve.ascended.mg||t.sim)&&(t.evolution.witch_hunter={count:0}),"evil"===t.race.universe&&(t.stats.achieve.corrupted&&t.stats.achieve.corrupted.e||t.sim),(t.stats.achieve.ascended||t.stats.achieve.corrupted||t.sim)&&(t.evolution.truepath={count:0}),((t.stats.achieve.ascended||t.stats.achieve.corrupted)&&t.stats.achieve.extinct_junker||t.sim)&&(t.evolution.sludge={count:0}),(t.stats.achieve.bluepill||t.sim)&&(t.evolution.simulation={count:0}),(t.stats.achieve.retired||t.sim)&&(t.evolution.lone_survivor={count:0}),function(){let e=$('
          ');$("#evolution").append(e),e.append($(`

          ${F("evo_challenge_genes")}

          `)),e.append($(`
          ${F("evo_challenge_genes_desc")}
          `)),t.genes.challenge&&t.genes.challenge>=2&&e.append($(`
          ${F("evo_challenge_genes_mastery")}
          `))}(),t.race.truepath||t.race.lone_survivor?gs("evolution","nerfed"):"antimatter"===t.race.universe?gs("evolution","mastery"):gs("evolution","plasmid"),gs("evolution","trade"),gs("evolution","craft"),t.race.truepath||t.race.lone_survivor?gs("evolution","badgenes"):gs("evolution","crispr"),function(){let e=$('
          ');$("#evolution").append(e),e.append($(`

          ${F("evo_challenge_run")}

          `)),e.append($(`
          ${F("evo_challenge_run_desc")}
          `))}(),gs("evolution","joyless"),gs("evolution","steelen"),(t.stats.achieve.whitehole||t.sim)&&gs("evolution","decay"),(t.stats.achieve.ascended||t.sim)&&gs("evolution","emfield"),(t.stats.achieve.scrooge||t.sim)&&gs("evolution","inflation"),((t.stats.achieve.ascended||t.stats.achieve.corrupted)&&t.stats.achieve.extinct_junker||t.sim)&&gs("evolution","sludge"),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&gs("evolution","orbit_decay"),"standard"===t.race.universe&&(t.stats.achieve.whitehole||t.sim),"heavy"===t.race.universe&&(t.stats.achieve.seeder&&t.stats.achieve.seeder.h||t.sim),"magic"===t.race.universe&&(t.stats.achieve.ascended&&t.stats.achieve.ascended.mg||t.sim)&&gs("evolution","witch_hunter"),"evil"===t.race.universe&&(t.stats.achieve.corrupted&&t.stats.achieve.corrupted.e||t.sim),t.hasOwnProperty("beta")&&!t.sim&&gs("evolution","simulation"),function(){let e=$('
          ');$("#evolution").append(e),e.append($(`

          ${F("evo_scenario")}

          `)),e.append($(`
          ${F("evo_scenario_desc")}
          `))}(),gs("evolution","junker"),(t.stats.achieve.shaken||t.sim)&&gs("evolution","cataclysm"),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&gs("evolution","banana"),(t.stats.achieve.ascended||t.stats.achieve.corrupted||t.sim)&&gs("evolution","truepath"),(t.stats.achieve.retired||t.sim)&&gs("evolution","lone_survivor"),t.sim?function(){let a=$('
          ');$("#evolution").append(a),a.append($(`

          ${F("evo_challenge_simulation")}

          `)),a.append($(`
          ${F("evo_challenge_simulation_desc")}
          `)),a.append($(``)),sc({el:"#simSection",data:{},methods:{exitsim(){t.hasOwnProperty("sim")&&(t.stats=zc(t.sim.stats),t.prestige=zc(t.sim.prestige),t.genes=zc(t.sim.genes),t.blood=zc(t.sim.blood),t.pillars=zc(t.sim.pillars),t.race=zc(t.sim.race),delete t.sim,t.race.species="protoplasm",delete t.race.simulation,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload())}}})}():t.race.simulation&&function(){let e=$('
          ');$("#evolution").append(e),e.append($(`

          ${F("evo_challenge_simulation")}

          `)),e.append($(`
          ${F("evo_challenge_simulation_desc")}
          `));let a=$($('
          '));e.append(a),t.race.simConfig||(t.race.simConfig={}),["Plasmid","AntiPlasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone"].forEach((function(e){t.race.simConfig[e]=t.race.simConfig[e]||0,a.append($(`
          ${F(`resource_${e}_name`)}
          `))})),sc({el:"#simSection",data:t.race.simConfig})}()}function Vr(e,a){let r=t.race.orbit_decay?"orbit_decayed":"cataclysm",s=function(e,t,a){return"space"===a?e.hasOwnProperty("trait")?e.trait.push(t):e.trait=[t]:"tauceti"===a?e.reqs.isolation=1:e.hasOwnProperty("not_trait")?e.not_trait.push(t):e.not_trait=[t],e};switch(e){case"bonfire":return s({id:`${a}-bonfire`,title:F("city_bonfire"),desc:F("city_bonfire_desc"),category:"outskirts",wiki:!1,reqs:{primitive:3},condition:()=>Tc("summer"),queue_complete:()=>0,effect(){let e=2.5*t.resource.Thermite.diff/(2.5*t.resource.Thermite.diff+500)*500,a=1e5+9e3*t.stats.reset;a>1e6&&(a=1e6);let r=t.resource.Thermite.amount${F("city_bonfire_effect3",[a.toLocaleString()])}
          ${F("city_bonfire_effect4",[(+t.resource.Thermite.amount.toFixed(0)).toLocaleString(),a.toLocaleString()])}
          `:"";return`
          ${F("city_bonfire_effect",[t.resource.Thermite.diff])}
          ${F("city_bonfire_effect2",[+e.toFixed(1)])}
          ${r}`},action:()=>!1,flair:()=>F("city_bonfire_flair")},r,a);case"firework":return s({id:`${a}-firework`,title:F("city_firework"),desc:F("city_firework"),category:"outskirts",wiki:!1,reqs:{mining:3},condition:()=>Tc("firework")&&(t.tech.cement||t.race.flier),cost:{Money:()=>0===t[a].firework.count?5e4:0,Iron:()=>0===t[a].firework.count?7500:0,Cement:()=>0===t[a].firework.count?1e4:0},queue_complete:()=>1-t[a].firework.count,switchable:()=>!0,effect:()=>0===t[a].firework.count?F("city_firework_build"):F("city_firework_effect"),action(){return!(0!==t[a].firework.count||!Os($(this)[0])||(t[a].firework.count=1,0))}},r,a);case"assembly":{let e=function(e){let a=Me(e);return t.race.promiscuous&&(a/=1+ui.promiscuous.vars()[1]*t.race.promiscuous),Math.round(a)};return s({id:`${a}-assembly`,title:F("city_assembly"),desc:()=>F("city_assembly_desc",[di[t.race.species].name]),category:"military",reqs:{},trait:["artifical"],queue_complete:()=>t.resource[t.race.species].max-t.resource[t.race.species].amount,cost:{Money:a=>t.resource[t.race.species].amount?Yi("citizen",a,e(125),1.01):0,Copper:a=>t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Yi("citizen",a,e(50),1.01):0,Aluminium:a=>t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Yi("citizen",a,e(50),1.01):0,Nanite:a=>t.race.deconstructor&&t.resource[t.race.species].amount>=3?Yi("citizen",a,e(500),1.01):0},effect(){let e="";return t.resource[t.race.species].max===t.resource[t.race.species].amount&&(e=`
          ${F("city_assembly_effect_warn")}
          `),`
          ${F("city_assembly_effect",[di[t.race.species].name])}
          ${e}`},action(){return!!(t.race.vax&&t.race.vax>=100)||!!(t.resource[t.race.species].max>t.resource[t.race.species].amount&&Os($(this)[0]))&&(t.resource[t.race.species].amount++,!0)}},r,a)}case"nanite_factory":return s({id:`${a}-nanite_factory`,title:F("city_nanite_factory"),desc:F("city_nanite_factory"),category:"industrial",reqs:{},trait:["deconstructor"],region:"city",cost:{Money:e=>Yi("nanite_factory",e,25e3,Fs(1.25)),Copper:e=>Yi("nanite_factory",e,1200,Fs(1.25)),Steel:e=>Yi("nanite_factory",e,1e3,Fs(1.25))},effect(){let e=Lr(2500);return`
          ${F("city_nanite_factory_effect",[t.resource.Nanite.name])}
          ${F("plus_max_resource",[e,t.resource.Nanite.name])}.
          `},special:!0,action(){return!!Os($(this)[0])&&(t.city.nanite_factory.count++,t.settings.showIndustry=!0,Ws(),!0)},flair:F("city_nanite_factory_flair")},r,a);case"captive_housing":return s({id:`${a}-captive_housing`,title:F("city_captive_housing"),desc:F("city_captive_housing_desc"),category:"residential",reqs:{unfathomable:1},trait:["unfathomable"],region:"city",cost:{Money:e=>Yi("captive_housing",e,40,1.35),Lumber:e=>Yi("captive_housing",e,30,1.35),Stone:e=>Yi("captive_housing",e,18,1.35)},effect(){let e="";t.race.artifical||t.race.detritivore||t.race.carnivore||t.race.soul_eater||(e+=`
          ${F("city_captive_housing_cattle",[t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.cattle:0,t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.cattleCap:0])}
          `);let a=0;if(t.city.hasOwnProperty("surfaceDwellers"))for(let r=0;r${F("city_captive_housing_broken",[di[s].name,i])}`,e+=`
          ${F("city_captive_housing_untrained",[di[s].name,c])}
          `}return e+=`
          ${F("city_captive_housing_capacity",[a,t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.raceCap:0])}
          `,t.tech.unfathomable&&t.tech.unfathomable>=2&&(e+=`
          ${F("plus_max_resource",[1,F("job_torturer")])}
          `),e},action(){if(Os($(this)[0])){t.city.captive_housing.count++;let e=t.city.captive_housing.count;return t.city.captive_housing.raceCap=e*(t.tech.unfathomable&&t.tech.unfathomable>=3?3:2),t.city.captive_housing.cattleCap=5*e,!0}return!1}},r,a);case"horseshoe":return s({id:`${a}-horseshoe`,title:()=>F(`city_${Bc(!0)}`,[Bc(!1)]),desc:()=>F(`city_${Bc(!0)}_desc`,[Bc(!1)]),category:"outskirts",reqs:{primitive:3},condition:()=>t.race.hooved||Tc("fool",2023),inflation:!1,cost:{Lumber(e){let a=(t.race.shoecnt||0)+(e||0);return t.race.kindling_kindred||t.race.smoldering||t.resource.Copper.display&&!(a<=12)?0:Math.round((a>12?25:5)*(a<=5?1:a-4)*(ui.hooved.vars()[0]/100))},Copper(e){let a=(t.race.shoecnt||0)+(e||0),r=!t.race.kindling_kindred&&!t.race.smoldering;return(!r||r&&a>12&&t.resource.Copper.display)&&(!t.resource.Iron.display||a<=75)?Math.round((a>75?20:5)*(a<=12?1:a-11)*(ui.hooved.vars()[0]/100)):0},Iron(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Iron.display&&a>75&&(!t.resource.Steel.display||a<=150)?Math.round((a<=150?12:28)*a*(ui.hooved.vars()[0]/100)):0},Steel(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Steel.display&&a>150&&(!t.resource.Adamantite.display||a<=500)?Math.round((a<=500?40:100)*a*(ui.hooved.vars()[0]/100)):0},Adamantite(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Adamantite.display&&a>500&&(!t.resource.Orichalcum.display||a<=5e3)?Math.round((a<=5e3?5:25)*a*(ui.hooved.vars()[0]/100)):0},Orichalcum(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Orichalcum.display&&a>5e3?Math.round((25*a-12e4)*(ui.hooved.vars()[0]/100)):0}},action(){return!(t.race.hooved||!Tc("fool",2023))||!(!t.resource.Horseshoe.display||!Os($(this)[0]))&&(t.resource.Horseshoe.amount++,t.race.shoecnt++,!(5001===t.race.shoecnt&&t.resource.Orichalcum.display||501===t.race.shoecnt&&t.resource.Adamantite.display||151===t.race.shoecnt&&t.resource.Steel.display||76===t.race.shoecnt&&t.resource.Iron.display||13===t.race.shoecnt&&t.resource.Copper.display&&t.resource.Lumber.display)||0)}},r,a)}}function Jr(e,a){a=a||"evo";let r=t.evolution.final||0;return(t.tech[a]&&t.tech[a]===e||t.evolution.gselect)&&r<100}const Yr=["human","orc","elven","troll","ogre","cyclops","kobold","goblin","gnome","cath","wolven","vulpine","centaur","rhinotaur","capybara","tortoisan","gecko","slitheryn","arraak","pterodacti","dracnid","sporgar","shroomi","moldling","mantis","scorpid","antid","entish","cacti","pinguicula","sharkin","octigoran","dryad","satyr","phoenix","salamander","yeti","wendigo","tuskin","kamel","imp","balorg","seraph","unicorn","synth","nano","ghast","shoggoth","custom"];if(Yr.forEach((e=>Qr.evolution[e]={id:`evolution-${e}`,title:()=>di[e].name,desc:()=>`${F("evo_evolve")} ${di[e].name}`,reqs:{evo:7},grant:["evo",8],condition:()=>(t.race.seeded||t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>=1||t.stats.achieve[`extinct_${e}`]&&t.stats.achieve[`extinct_${e}`].l>=1)&&t.tech[`evo_${di[e].type}`]>=2&&100===t.evolution.final&&!t.race.evoFinalMenu,cost:{RNA:()=>320,DNA:()=>320},race:!0,effect:()=>`${"string"==typeof di[e].desc?di[e].desc:di[e].desc()} ${F("evo_complete")}`,action(){if(Os($(this)[0])){if(["synth","custom"].includes(e))return function(e){if(("synth"===e||"custom"===e&&t.custom.race0.traits.includes("imitation"))&&Object.keys(t.stats.synth).length>1)return t.race.evoFinalMenu=e,ts(),!0;t.race.species=e,Ls()}(e);t.race.species=e,Ls()}return!1},queue_complete:()=>t.tech.evo&&7===t.tech.evo?1:0,emblem:()=>Pc(`extinct_${e}`)})),Object.keys(t.stats.synth).length>1){let e=zc(Yr);e.push("junker"),e.push("sludge"),e.forEach((e=>Qr.evolution[`s-${e}`]={id:`evolution-s-${e}`,title:()=>di[e].name,desc:()=>`${F("evo_imitate")} ${di[e].name}`,reqs:{evo:8},grant:["evo",9],condition:()=>t.stats.synth[e]&&t.race.evoFinalMenu,cost:{},race:!0,effect:()=>F("evo_imitate_race",[di[e].name]),action:()=>(t.stats.synth[e]&&(t.race.species=t.race.evoFinalMenu,t.race.srace=e,Ls()),!1),queue_complete:()=>t.tech.evo&&8===t.tech.evo?1:0}))}const Xr={plasmid:"no_plasmid",mastery:"weak_mastery",trade:"no_trade",craft:"no_craft",crispr:"no_crispr",nerfed:"nerfed",badgenes:"badgenes"};Object.keys(Xr).forEach((e=>Qr.evolution[e]={id:`evolution-${e}`,title:F(`evo_challenge_${e}`),desc:F(`evo_challenge_${e}`),condition:()=>t.evolution.hasOwnProperty(e),cost:{DNA:()=>10},challenge:!0,effect:()=>as(e),action(){return Os($(this)[0])&&(t.race[Xr[e]]?(delete t.race[Xr[e]],$(`#${$(this)[0].id}`).removeClass("hl"),(t.race.truepath||t.race.lone_survivor)&&(delete t.race.nerfed,delete t.race.badgenes),["junker","cataclysm","banana","truepath","lone_survivor"].forEach((function(e){delete t.race[e],$(`#evolution-${e}`).removeClass("hl")}))):(t.race[Xr[e]]=1,$(`#${$(this)[0].id}`).addClass("hl")),Zr(),ao()),!1},highlight:()=>!!t.race[Xr[e]],queue_complete:()=>0}));const es={joyless:{t:"c",e:"joyless"},steelen:{t:"c",e:"steelen"},decay:{t:"c",e:"dissipated"},emfield:{t:"c",e:"technophobe"},inflation:{t:"c",e:"wheelbarrow"},sludge:{t:"c",e:"extinct_sludge"},orbit_decay:{t:"c",e:"lamentis"},witch_hunter:{t:"c",e:"soul_sponge"},simulation:{t:"c",e:"thereisnospoon"},junker:{t:"s",e:"extinct_junker"},cataclysm:{t:"s",e:"iron_will"},banana:{t:"s",e:"banana"},truepath:{t:"s",e:"pathfinder"},lone_survivor:{t:"s",e:"adam_eve"}};function ts(){if((t.settings.tabLoad||0===t.settings.civTabs)&&"bigbang"!==t.race.universe&&(!t.race.seeded||t.race.chose)){if(t.tech.evo_challenge){let e=$("#evolution .evolving").nextAll();Object.values(e).forEach((function(e){rc($(e),!0)})),rc($("#evolution .evolving"),!0)}Object.keys(Qr.evolution).forEach((function(e){if(!Qr.evolution[e].challenge){Ms(Qr.evolution[e].id);var a=!0;Qr.evolution[e].hasOwnProperty("reqs")&&Object.keys(Qr.evolution[e].reqs).forEach((function(r){(!t.tech[r]||t.tech[r]=2&&As(),t.tech.evo_challenge&&Zr())}}function as(e){switch(e){case"nerfed":return F(`evo_challenge_${e}_effect`,"antimatter"===t.race.universe?["20%","50%","50%","33%"]:["50%","20%","50%","33%"]);case"badgenes":return F(`evo_challenge_${e}_effect`,[1,2]);case"orbit_decay":return lc()>=100?`
          ${F("evo_challenge_orbit_decay_effect",[5e3])}
          ${F("evo_challenge_scenario_failwarn")}
          `:`
          ${F("evo_challenge_orbit_decay_effect",[5e3])}
          ${F("evo_challenge_scenario_failwarn")}
          ${F("evo_challenge_scenario_warn")}
          `;case"junker":return"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
          ${F("evo_challenge_junker_effect")}
          ${F("evo_warn_unwise")}
          `:F("evo_challenge_junker_effect");case"cataclysm":return lc()>=50?`
          ${F("evo_challenge_cataclysm_effect")}
          ${F("evo_challenge_cataclysm_warn")}
          `:`
          ${F("evo_challenge_cataclysm_effect")}
          ${F("evo_challenge_scenario_warn")}
          `;default:return F(`evo_challenge_${e}_effect`)}}function rs(){let e;if("antimatter"===t.race.universe||t.race.no_plasmid){let a=t.tech.anthropology&&t.tech.anthropology>=1?1.6:1;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=na(t.civic.professor.workers,"professor")*("antimatter"===t.race.universe?.02:.04);t.race.high_pop&&(e=Me(e)),a+=+e.toFixed(2)}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.015:t.genes.ancients>=3?.0125:.01;t.race.high_pop&&(e=Me(e)),a+=e*na(t.civic.priest.workers,"priest")}"antimatter"===t.race.universe&&(a/=2),t.race.spiritual&&(a*=1+ui.spiritual.vars()[0]/100);let r=Pi("seraph");if(r>0&&(a*=1+ui.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1+ae.theocracy()[0]/100),t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),a=+a.toFixed(3),e=`
          ${F("city_temple_effect1",[a])}
          `,"antimatter"===t.race.universe){let a=6;if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.12:t.genes.ancients>=3?.1:.08;t.race.high_pop&&(e=Me(e)),a+=e*na(t.civic.priest.workers,"priest")}e+=`
          ${F("city_temple_effect5",[a.toFixed(2)])}
          `}}else{let a=t.tech.anthropology&&t.tech.anthropology>=1?8:5;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=.2*na(t.civic.professor.workers,"professor");t.race.high_pop&&(e=Me(e)),a+=+e.toFixed(1)}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.15:t.genes.ancients>=3?.125:.1;t.race.high_pop&&(e=Me(e)),a+=e*na(t.civic.priest.workers,"priest")}t.race.spiritual&&(a*=1+ui.spiritual.vars()[0]/100);let r=Pi("seraph");r>0&&(a*=1+ui.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1+ae.theocracy()[0]/100),t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),t.race.orbit_decayed&&t.race.truepath&&(a*=.1),a=+a.toFixed(3),e=`
          ${F("city_temple_effect2",[a])}
          `}return t.tech.fanaticism&&t.tech.fanaticism>=3&&(e+=`
          ${F("city_temple_effect3")}
          `),t.tech.anthropology&&t.tech.anthropology>=4&&(e+=`
          ${t.race.truepath?F("city_temple_effect_tp",[2,25]):F("city_temple_effect4")}
          `),e}function ss(){let e=t.tech.gambling>=3?6e4:4e4;t.tech.gambling>=5&&(e+=t.tech.gambling>=6?24e4:6e4),e=Lr(e),t.race.gambler&&(e*=1+.04*t.race.gambler),t.tech.world_control&&(e*=1.25),t.race.truepath&&(e*=1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(e*=1+.05*t.tech.stock_exchange),t.race.inflation&&(e*=1+t.race.inflation/100),t.tech.isolation&&(e*=5.5),e=Math.round(e);let a=t.race.joyless?"":`
          ${F("city_max_entertainer",[la(1)])}
          `,r=t.race.orbit_decayed||t.tech.isolation?`
          ${F("plus_max_resource",[la(1),F("banker_name")])}
          `:"",s=`
          ${F("plus_max_resource",[`$${e.toLocaleString()}`,F("resource_Money_name")])}
          ${a}${r}
          ${F("city_max_morale",[1])}
          `,i=Math.log2(1+t.resource[t.race.species].amount)*(t.race.gambler?2.5+t.race.gambler/10:2.5);return t.tech.gambling&&t.tech.gambling>=2&&(i*=t.tech.gambling>=5?2:1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(i*=1+.01*t.tech.stock_exchange),"corpocracy"===t.civic.govern.type&&(i*=3),"socialist"===t.civic.govern.type&&(i*=.8),t.race.inflation&&(i*=1+t.race.inflation/1250),t.tech.isolation&&(i*=1.25,t.tech.iso_gambling&&(i*=1+.05*na(t.civic.banker.workers,"banker"))),i=+i.toFixed(2),s+=`
          ${F("tech_casino_effect2",[i])}
          `,s}function is(e,a,r,s){return((t.evolution.hasOwnProperty(e)?t.evolution[e].count:0)+(s||0))*r+a}function cs(e){return t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),Math.round(e)}function os(){let e=1.25*(t.tech.storage-1)+1;t.tech.storage>=3&&(e*=t.tech.storage>=4?3:1.5),t.race.pack_rat&&(e*=1+ui.pack_rat.vars()[1]/100);let a=Pi("kobold");return a>0&&(e*=1+ui.pack_rat.vars(1)[1]/100*a),t.tech.storage>=6&&(e*=1+t.tech.supercollider/20),t.tech.tp_depot&&(e*=1+t.tech.tp_depot/20),t.tech.shelving&&t.tech.shelving>=3&&(e*=1.5),t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),e*=t.tech.world_control?3:1,t.race.ascended&&(e*=1.1),t.blood.hoarder&&(e*=1+t.blood.hoarder/100),t.tech.storage>=7&&t.interstellar.cargo_yard&&(e*=1+t.interstellar.cargo_yard.count*u/100),e}function ns(e){if((t.race.kindling_kindred||t.race.smoldering)&&"lumber"===e)return!1;if((t.race.kindling_kindred||t.race.smoldering)&&"stone"===e)return!0;let a=t.race.truepath?"truepath":"standard";if(Qr.city[e].hasOwnProperty("path")&&!Qr.city[e].path.includes(a))return!1;var r=!0;return Object.keys(Qr.city[e].reqs).forEach((function(a){(!t.tech[a]||t.tech[a]=3&&(s=!0,t.r_queue.queue.forEach((function(e){us(e.type,!1)&&(a[Qr[e.action][e.type].grant[0]]={v:Qr[e.action][e.type].grant[1],a:e.type})})),Object.keys(i).forEach((function(r){let i=t.tech[r]||0;ls(r,t.tech[r])||(!a[r]||a[r].vi+1)&&(s=!1)}))),!(!r&&!s||t.tech[Qr.tech[e].grant[0]]&&!(t.tech[Qr.tech[e].grant[0]]`).appendTo("#city").append(`

          ${F(`city_dist_${a}`)}

          `),e[a].forEach((function(e){gs("city",e)})),Ti(`dist-${a}`,(function(){return F(`city_dist_${a}_desc`)}),{elm:`#city-dist-${a} h3`,classes:"has-background-light has-text-dark"})}}))}function ms(){if(!t.settings.tabLoad&&3!==t.settings.civTabs)return;let e={},a={},r={},s=[],i=[],c=[];["primitive","civilized","discovery","industrialized","globalized","early_space","deep_space","interstellar","intergalactic"].forEach((function(e){r[e]=[]}));const o={interstellar:"solar"};let n={};Object.keys(Qr.tech).forEach((function(l){if(!function(e){let a=t.race.truepath?"truepath":"standard";return!(!Wr[a].includes(Qr.tech[e].era)&&!Qr.tech[e].hasOwnProperty("path")||Qr.tech[e].hasOwnProperty("path")&&!Qr.tech[e].path.includes(a))}(l))return;Ms(Qr.tech[l].id);let u=function(e){let a=Qr.tech[e].grant[0];if(t.tech[a]&&t.tech[a]>=Qr.tech[e].grant[1]){if("fanaticism"!==e&&"anthropology"!==e&&"deify"!==e&&"study"!==e)return!0;if("fanaticism"===e&&t.tech.fanaticism)return!0;if("anthropology"===e&&t.tech.anthropology)return!0;if("deify"===e&&t.tech.ancient_deify)return!0;if("study"===e&&t.tech.ancient_study)return!0}return!1}(l),d=Qr.tech[l],_="category"in d?d.category:"research";if(u||-1!==s.indexOf(_)||s.push(_),u&&-1===i.indexOf(_)&&i.push(_),-1===c.indexOf(_)&&c.push(_),!0===u)_ in a||(a[_]=[]),a[_].push(l);else{let a=Qr.tech[l];if(!ds(a))return;let s=us(l,n);if(!s)return;_ in e||(e[_]=[]);let i=t.race.truepath&&o[a.era]?o[a.era]:a.era;r.hasOwnProperty(i)||(r[i]=[]),r[i].push({t:l,p:"precog"===s})}})),rc($("#tech")),Object.keys(r).forEach((function(e){r[e].length>0&&($("#tech").append(`

          ${F(`tech_era_${e}`)}

          `),r[e].sort((function(e,t){return null==Qr.tech[e.t].cost.Knowledge?-1:null==Qr.tech[t.t].cost.Knowledge||Qr.tech[e.t].cost.Knowledge()>Qr.tech[t.t].cost.Knowledge()?1:-1})),r[e].forEach((function(e){gs("tech",e.t,!1,!!e.p&&n)})))})),c.forEach((function(e){rc($(`#tech-dist-${e}`),!0),rc($(`#tech-dist-old-${e}`),!0)})),i.forEach((function(e){if(!(e in a))return;$(`
          `).appendTo("#oldTech").append(`

          ${F(`tech_dist_${e}`)}

          `);let t=kc(4,12,!1);t.length>0&&"science"===e&&$("#tech-dist-old-science h3").append(t),a[e].forEach((function(e){gs("tech",e,!0,!1)}))}))}function gs(e,t,a,r){fs(Qr[e][t],e,t,a,r)}function fs(e,a,r,s,i){if(!1===ds(e))return;let c=a;"outerSol"===a&&(a="space"),e.region&&(a=e.region),e.powered&&!t[a][r].on&&(t[a][r].on=0);let o=e.id;Ms(o);let n="";i&&e&&e.reqs&&Object.keys(e.reqs).forEach((function(e){i[e]&&(n+=` data-req-${e}="${i[e].a}"`)}));let l,u=e.highlight&&e.highlight()?$(`
          `):$(`
          `);if(Cs(e,!1,["genes","blood"].includes(a))||u.addClass("cna"),Cs(e,!0,["genes","blood"].includes(a))||u.addClass("cnam"),s)l=$('{{ title }}');else{let t="",r="";if(e.cost){let s="genes"!==a&&"blood"!==a?gc(e):e.cost;Object.keys(s).forEach((function(e){let a=s[e]();a>0&&(t+=` res-${e}`,r+=` data-${e}="${a}"`)}))}let s="";e.class&&(s="function"==typeof e.class?` ${e.class()}`:` ${e.class}`),i&&(s=" precog");let c=e.highlight?e.highlight()?`${F("active")}`:`${F("not_active")}`:"";l=$(`${c}{{ title }} description`)}if(u.append(l),e.hasOwnProperty("special")&&("function"==typeof e.special&&e.special()||!0===e.special)){let e=$('
          \n \n
          ');u.append(e)}if(e.on||e.off){if(e.on){let e=$('');u.append(e)}if(e.off){let e=$('');u.append(e)}}else if(e.powered&&t.tech.high_tech&&t.tech.high_tech>=2&&_s(e)||e.switchable&&e.switchable()){let t=$(``),a=$(``);u.append(t),u.append(a)}if(e.count){let t=e.count();t>1&&l.append($(`${t}`))}else"tech"!==a&&t[a]&&t[a][r]&&t[a][r].count>=0?l.append($('{{ act.count }}')):"blood"===a&&t[a]&&t[a][e.grant[0]]&&t[a][e.grant[0]]>0&&"*"===e.grant[1]&&l.append($(` ${t[a][e.grant[0]]} `));if("tech"!==a&&t[a]&&t[a][r]&&void 0!==t[a][r].repair&&l.append($('
          ')),s?$("#oldTech").append(u):$("#"+c).append(u),"tech"!==a&&t[a]&&t[a][r]&&0===t[a][r].count&&($(`#${o} .count`).css("display","none"),$(`#${o} .special`).css("display","none"),$(`#${o} .on`).css("display","none"),$(`#${o} .off`).css("display","none")),e.emblem){let t=e.emblem();u.append($(t))}let d={template:''};sc({el:"#"+o,data:{title:"string"==typeof e.title?e.title:e.title(),act:t[a][r]},methods:{action(){"ontouchstart"in document.documentElement&&navigator.userAgent.match(t.settings.touch)||vs(e,a,r)},describe(){q(function(e,a){let r="string"==typeof e.desc?e.desc:e.desc();if(r+=". ",e.cost&&!a){r=Cs(e)?r+F("affordable")+". ":r+F("not_affordable")+". ",r+="Costs: ";let a=e.id.split("-")[0];var s="genes"!==a&&"blood"!==a?gc(e):e.cost;Object.keys(s).forEach((function(e){if("Custom"===e){let t=s[e]();r+=t.label}else if("Structs"===e){let a=s[e]();Object.keys(a).forEach((function(e){Object.keys(a[e]).forEach((function(s){let i="";if(a[e][s].hasOwnProperty("s")){let t=a[e][s].s;i="string"==typeof Qr[e][t][s].title?Qr[e][t][s].title:Qr[e][t][s].title()}else i="string"==typeof Qr[e][s].title?Qr[e][s].title:Qr[e][s].title();r+=`${i}. `,t[e][s]?a[e][s].count>t[e][s].count?r+=`${F("insufficient")} ${i}. `:a[e][s].hasOwnProperty("on")&&a[e][s].on>t[e][s].on&&(r+=`${F("insufficient")} ${i} enabled. `):r+=`${F("insufficient")} ${i}. `}))}))}else if(t.prestige.hasOwnProperty(e)){let a=s[e]();if(a>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let s=F(`resource_${e}_name`);r+=`${s}: ${a}. `,t.prestige[e].count0){let s=F(`resource_${e}_name`);r+=`${s}: ${a}. `,t.portal.purifier.supply0){let e="Money"===i?"$":t.resource[i].name+": ";e=e.replace("_"," ");let s=k(a,1);r+=`${e}${s}. `,t.resource[i].amount0&&(clearInterval(t),zs(e,r))}),50)}},on_label:()=>`on: ${t[a][r].on}`,off_label:()=>"off: "+(t[a][r].count-t[a][r].on),power_on(){let s=y();for(let e=0;e0;e++)t[a][r].on--;e.postPower&&setTimeout((function(){e.postPower(!1)}),250)},repair:()=>t[a][r].repair,repairMax:()=>e.repair()},filters:{val(t){switch(t){case"on":return e.on();case"off":return e.off()}},p_off(e,s){let i=t[a][r].count-e;if("city-casino"===s&&!t.race.cataclysm&&!t.race.orbit_decayed||"space-spc_casino"===s&&(t.race.cataclysm||t.race.orbit_decayed)||"tauceti-tauceti_casino"===s&&t.tech.isolation){let e=$c(5,12);if(0===i&&e.length>0)return e}return i},p_on(e,a){if("city-biolab"===a&&!t.race.cataclysm&&!t.race.orbit_decayed||(t.race.cataclysm||t.race.orbit_decayed)&&"space-exotic_lab"===a||t.tech.isolation&&"tauceti-infectious_disease_lab"===a){let t=$c(12,12);if(0===e&&t.length>0)return t}else if("city-garrison"===a||"space-space_barracks"===a){let t=kc(1,14,!0);if(e===("city-garrison"===a?13:0)&&t.length>0)return t}return e},title:e=>e,options:e=>F("action_options",[e])}}),Ti(o,(function(){}),{in:function(i){qs(i.popper,e,t[a][r],s,a,r)},out:function(){sc({el:"#popTimer"},"destroy")},attach:"starDock"===a?"body .modal":"#main",wide:e.wide})}function vs(e,a,r){if("spcdock-launch_ship"===e.id)e.action();else switch(a){case"tech":if(t.settings.qKey&&v.q||!us(r,!1)||!e.action()){if((!e.no_queue||!e.no_queue())&&t.tech.r_queue&&t.r_queue.queue.length0){let n=t.settings.qKey?s:1;n>t.queue.max-i&&(n=t.queue.max-i);let l=e.queue_size?e.queue_size:1;if(e.region&&(a=e.id.split("-")[0]),"merge_never"!==t.settings.q_merge)t.queue.queue.length>0&&t.queue.queue[t.queue.queue.length-1].id===e.id?t.queue.queue[t.queue.queue.length-1].q+=Math.min(o,l*n):t.queue.queue.push({id:e.id,action:a,type:r,label:"string"==typeof e.title?e.title:e.title(),cna:!1,time:0,q:Math.min(o,l*n),qs:l,t_max:0,bres:!1});else for(let s=0;s0;s++)t.queue.queue.push({id:e.id,action:a,type:r,label:"string"==typeof e.title?e.title:e.title(),cna:!1,time:0,q:Math.min(o,l),qs:l,t_max:0,bres:!1}),o-=l;c=!0}}break}t.race.inflation&&t.tech.primitive&&(e.hasOwnProperty("inflation")&&!e.inflation||t.race.inflation++),i=!0}if(i&&(ys(e,a,r),t.tech.queue&&e.queue_complete)){let a=e.queue_complete();for(let r=0,s=0;sa?(i.q=a,a=0):a-=i.q)}}c&&Ui();break}}}function ys(e,a,r){if(!Cs(e)){let t=e.id;$(`#${t}`).addClass("cna")}if(e.grant){let a=e.grant[0];(!t.tech[a]||t.tech[a]=4&&t.custom.planet&&e.custom&&e.custom.length>0&&0===Math.floor(m(0,10))){c=e.custom[Math.floor(m(0,e.custom.length))];let o=c.split(":");if(t.custom.planet[o[0]]&&t.custom.planet[o[0]][o[1]]){let e=zc(t.custom.planet[o[0]][o[1]]);a=e.biome,r=e.traitlist,s=e.orbit,i=e.geology,r.sort()}else c=!1}if(!c){a=$s("biome",e),r=$s("trait",e,{biome:a}),r.sort();let c=Math.floor(m(0,3)),o=30;t.stats.achieve.whitehole&&(o+=5*t.stats.achieve.whitehole.l,c+=t.stats.achieve.whitehole.l),"eden"===a&&(o+=5);for(let e=0;e`),_=$(`${u}`);d.append(_),$("#evolution").append(d);let p=!1,h=0;return Ti(n,(function(e){p=e,ws(e,u,a,s,r,i,h)}),{classes:"has-background-light has-text-dark"}),$("#"+n).on("click",(function(){if(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5&&t.race.hasOwnProperty("geck")&&t.race.geck>0){if(Object.keys(i).forEach((function(e){i[e]+=Math.floor(m(0,7))/100})),h>0){let t=8-h;t<1&&(t=1),0===Math.floor(m(0,t))&&(a=$s("biome",e))}if(0===Math.floor(m(0,2))){let t=$s("trait",e,{biome:a,cap:1});if(t.length>0){if(r.includes(t[0])){let e=r.indexOf(t[0]);r.splice(e,1)}else void 0!==t[0]&&r.push(t[0]);l="",r.forEach((function(e){Si.hasOwnProperty(e)&&(l+=`${Si[e].label} `)}))}}u=`${l}${ji[a].label} ${o}`,$(`#${n} .aTitle`).html(u),h++,t.race.geck--,t.race.hasOwnProperty("gecked")||(t.race.gecked=0),t.race.gecked++,rc(p.popper),ws(p,u,a,s,r,i,h)}else delete t.race.geck,t.race.gecked&&(t.stats.geck+=t.race.gecked),t.race.chose=n,t.city.biome=a,t.city.calendar.orbit=s,t.city.geology=i,t.city.ptrait=r,h>0&&(t.race.rejuvenated=!0),rc($("#evolution")),Ei(),ts()})),c||("eden"===a?"hellscape":a)}function ws(e,t,a,r,s,i,c){e.popper.append($(`
          ${F("set_planet",[t,ji[a].label,r])}
          `)),e.popper.append($(`
          ${ji[a].desc}
          `)),s.length>0&&s.forEach((function(t){e.popper.append($(`
          ${Si[t].desc}
          `))}));let o=ks(i);o.length>0&&e.popper.append($(`
          ${o}
          `)),c&&c>0&&e.popper.append($(`
          ${F("rejuvenated")}
          `))}function $s(e,a,r){if(r=r||{},"biome"===e){let e="grassland",r=!a.hell&&t.stats.portals>=1?7:6,s=0===Math.floor(m(0,3)),i=Yc();switch(Math.floor(m(0,r))){case 0:e=s&&t.stats.achieve.biome_grassland&&t.stats.achieve.biome_grassland[i]&&t.stats.achieve.biome_grassland[i]>0?"savanna":"grassland";break;case 1:e=s&&t.stats.achieve.biome_oceanic&&t.stats.achieve.biome_oceanic[i]&&t.stats.achieve.biome_oceanic[i]>0?"swamp":"oceanic";break;case 2:e=s&&t.stats.achieve.biome_forest&&t.stats.achieve.biome_forest[i]&&t.stats.achieve.biome_forest[i]>0?0===Math.floor(m(0,2))?"taiga":"swamp":"forest";break;case 3:e=s&&t.stats.achieve.biome_desert&&t.stats.achieve.biome_desert[i]&&t.stats.achieve.biome_desert[i]>0?"ashland":"desert";break;case 4:e=s&&t.stats.achieve.biome_volcanic&&t.stats.achieve.biome_volcanic[i]&&t.stats.achieve.biome_volcanic[i]>0?"ashland":"volcanic";break;case 5:e=s&&t.stats.achieve.biome_tundra&&t.stats.achieve.biome_tundra[i]&&t.stats.achieve.biome_tundra[i]>0?"taiga":"tundra";break;case 6:e="evil"===t.race.universe?"eden":"hellscape";break;default:e="grassland"}return e}if("trait"===e){let e=[],t=r.cap||2;for(let a=0;a0&&(s+=t.race.replicator.pow),!(t.city.hasOwnProperty("powered")&&s>=e.powered()&&(t[r[0]][r[1]].on++,t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks")&&t.race.hasOwnProperty("replicator")&&Object.values(t.race.governor.tasks).includes("replicate")&&t.race.governor.config.replicate.pow.on&&t.race.replicator.pow>0&&(t.city.power-=e.powered(),B.replicate.task()),a&&"function"==typeof a))||a(e)}return!1}function ks(e){let a="";if(Object.keys(e).length>0){let r="",s="",i=t.stats.achieve.miners_dream?t.stats.achieve.miners_dream.l>=4?2*t.stats.achieve.miners_dream.l-3:t.stats.achieve.miners_dream.l:0;t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=0&&i++;for(let t in e)if(0!==t)if(e[t]>0){let a=`
          ${F(`resource_${t}_name`)}`;i>0?(a+=`: +${Math.round(100*(e[t]+1)-100)}%`,i--):a+=`: ${F("bonus")}`,a+="
          ",r+=a}else if(e[t]<0){let a=`
          ${F(`resource_${t}_name`)}`;i>0?(a+=`: ${Math.round(100*(e[t]+1)-100)}%`,i--):a+=`: ${F("malus")}`,a+="
          ",s+=a}a=`
          ${r}${s}
          `}return a}function qs(e,a,r,s,i,c,o){rc(e);var n="string"==typeof a.desc?a.desc:a.desc();o=o||!1;let l=!1;!(i&&c&&"ontouchstart"in document.documentElement&&navigator.userAgent.match(/Mobi/)&&t.settings.touch)||(l=$(`${a.hasOwnProperty("touchlabel")?a.touchlabel:F("construct")}`),e.append(l),$("#touchButton").on("touchstart",(function(){vs(a,i,c)}))),e.append($(`
          ${n}
          `));let u=a.id.split("-")[0];a.category&&"tech"===u&&!s&&e.append($(`
          ${F("tech_dist_category")}: ${F(`tech_dist_${a.category}`)}
          `));let d=tc(a,!1,!0);if(a.cost&&!s){let r=!0;var _=$('
          '),p="genes"!==u&&"blood"!==u?gc(a):a.cost;Object.keys(p).forEach((function(e){if("Custom"===e){let t=p[e]();_.append($(`
          ${t.label}
          `)),r=!1}else if("Structs"===e){let a=p[e]();Object.keys(a).forEach((function(e){Object.keys(a[e]).forEach((function(s){let i=a[e][s].hasOwnProperty("on")?a[e][s].on:a[e][s].count,c="has-text-dark",o="";t[e][s]?a[e][s].count>t[e][s].count?(c="has-text-danger",o=' (blocking resource)'):a[e][s].hasOwnProperty("on")&&a[e][s].on>t[e][s].on&&(c="has-text-alert"):(c="has-text-danger",o=' (blocking resource)');let n="";if(a[e][s].hasOwnProperty("s")){let t=a[e][s].s;n="string"==typeof Qr[e][t][s].title?Qr[e][t][s].title:Qr[e][t][s].title()}else n="string"==typeof Qr[e][s].title?Qr[e][s].title:Qr[e][s].title();r=!1,_.append($(`
          ${n}: ${i}${o}
          `))}))}))}else if(t.prestige.hasOwnProperty(e)){let a=p[e]();if(a>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let s=F(`resource_${e}_name`),i="has-text-dark",c="";t.prestige[e].count(blocking resource)'),r=!1,_.append($(`
          ${s}: ${a}${c}
          `))}}else if("Supply"===e){let a=p[e]();if(a>0){let s=F(`resource_${e}_name`),i="has-text-dark",c="";t.portal.purifier.supply(blocking resource)'),r=!1,_.append($(`
          ${s}: ${a}${c}
          `))}}else if("Morale"!==e&&"Army"!==e&&"Bool"!==e){let a=p[e]();if(a>0){let s="",i="Species"===e?t.race.species:e;if("HellArmy"===e){let c=F("fortress_troops"),o="has-text-dark";t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size(blocking resource)'):o="has-text-alert"),r=!1,_.append($(`
          ${c}: ${a}${s}
          `))}else{let s="Money"===i?"$":t.resource[i].name+": ";s=s.replace("_"," ");let c="has-text-dark",n="";t.resource[i].amount(blocking resource)'):c="has-text-alert",o&&o!==e&&d.r===i?(c+=" grad-from-left",n=' (first blocking resource)'):o&&o===e&&d.r!==i&&(c+=" grad-from-left-warn")):o&&o===e&&(c+=" grad-from-right",n=' (last blocking resource)');let l=k(a,1);r=!1,_.append($(`
          ${s}${l}${n}
          `))}}}})),r||e.append(_)}if(a.effect){var h="string"==typeof a.effect?a.effect:a.effect();h&&e.append($(`
          ${h}
          `))}if(a.flair){var m="string"==typeof a.flair?a.flair:a.flair();e.append($(`
          ${m}
          `)),e.addClass("flair")}if(a.reqs){let t=[];if(Object.keys(a.reqs).forEach((function(e){let r=$(`#${a.id}`).attr(`data-req-${e}`);r&&t.push("string"==typeof Qr.tech[r].title?Qr.tech[r].title:Qr.tech[r].title())})),t.length>0){let a=t.join(", ");e.append($(`
          ${F("requires_tech",[a])}
          `))}}if(!s&&"blood"!==a.id.substring(0,5)&&!Cs(a)&&Cs(a,!0)){if("string"==typeof r&&"notimer"===r)return;if(r&&r.time)e.append($('
          {{ time | timer }}
          ')),sc({el:"#popTimer",data:r,filters:{timer:e=>F("action_ready",[e])}});else{let t=ic(d.t);e.append($(`
          ${F("action_ready",[t])}
          `))}}("portal-spire"===a.id||"portal-waygate"===a.id&&t.tech.waygate>=2)&&r&&r.time&&(e.append($('
          {{ time | timer }}
          ')),sc({el:"#popTimer",data:r,filters:{timer:e=>F("floor_clearing",[!a.hasOwnProperty("mscan")||a.hasOwnProperty("mscan")&&a.mscan()>0?e:"???"])}}))}function Ms(e){rc($(`#${e}`),!0),Ei(e)}function Ps(e,a,r){var s=e.id;t[a]&&t[a][r]&&t[a][r].count&&($(`#${s} .count`).html(t[a][r].count),t[a][r]&&t[a][r].count>0&&($(`#${s} .count`).css("display","inline-block"),$(`#${s} .special`).css("display","block"),$(`#${s} .on`).css("display","block"),$(`#${s} .off`).css("display","block"))),$("#popper").data("id")===s&&qs($("#popper"),e,t[a][r],!1,a,r)}function Os(e,a){return!!js(a=a||gc(e))&&(Object.keys(a).forEach((function(e){if(t.prestige.hasOwnProperty(e)){let r=a[e]();"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].count-=r}else if("Supply"===e){let r=a[e]();t.portal.purifier.supply-=r}else if("Morale"!==e&&"Army"!==e&&"HellArmy"!==e&&"Structs"!==e&&"Bool"!==e&&"Custom"!==e){let r=a[e](),s="Species"===e?t.race.species:e;t.resource[s].amount-=r,"Knowledge"===s&&(t.stats.know+=r)}})),!0)}function Cs(e,a,r){if(e.cost){let c=r?e.cost:gc(e);return a?(s=c,i=!0,Object.keys(s).forEach((function(e){if("Custom"===e);else if("Structs"===e){if(!Ss(s[e]()))return void(i=!1)}else if(t.prestige.hasOwnProperty(e)){let a=e;if("Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].count0||t.resource[r].max>=0&&a>Number(t.resource[r].max)&&-1!==Number(t.resource[r].max))return void(i=!1)}})),i):js(c)}var s,i;return!0}function js(e){var a=!0;return Object.keys(e).forEach((function(r){if("Custom"===r){if(!e[r]().met)return void(a=!1)}else if("Structs"===r){if(!Ss(e[r]()))return void(a=!1)}else if(t.prestige.hasOwnProperty(r)){let s=r;if("Plasmid"===r&&"antimatter"===t.race.universe&&(r="AntiPlasmid"),t.prestige[r].count=0&&s>t.resource[i].max;if(s>Number(t.resource[i].amount)+t.resource[i].diff||c)return void(a=!1)}})),a}function Ss(e){let a=!0;return Object.keys(e).forEach((function(r){t.hasOwnProperty(r)?Object.keys(e[r]).forEach((function(s){t[r].hasOwnProperty(s)?(t[r][s].count${r}

          `));var s=$('
          ');switch($("#modalBox").append(s),a){case"smelter":case"hell_smelter":case"stellar_forge":case"hell_forge":case"geothermal":case"ore_refinery":Us("smelter",s);break;case"factory":case"red_factory":case"int_factory":case"tau_factory":Us("factory",s);break;case"star_dock":!function(e){if(t.tech.genesis<4){let t=$(`
          ${F("stardock_warn")}
          `);return void e.append(t)}let a=$('
          ');e.append(a),fs(Qr.starDock.probes,"starDock","probes"),t.tech.geck&&t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5&&fs(Qr.starDock.geck,"starDock","geck"),t.tech.genesis>=5&&fs(Qr.starDock.seeder,"starDock","seeder"),6===t.tech.genesis&&fs(Qr.starDock.prep_ship,"starDock","prep_ship"),t.tech.genesis>=7&&fs(Qr.starDock.launch_ship,"starDock","launch_ship")}(s);break;case"mining_droid":Us("droid",s);break;case"g_factory":case"refueling_station":Us("graphene",s);break;case"freighter":case"super_freighter":_r(s);break;case"pylon":Us("pylon",s);break;case"rock_quarry":Us("rock_quarry",s);break;case"titan_mine":Us("titan_mine",s);break;case"mining_ship":Us("mining_ship",s);break;case"alien_space_station":Us("alien_space_station",s);break;case"nanite_factory":Us("nanite_factory",s);break;case"alien_outpost":Us("replicator",s)}}function As(){rc($("#evolution .evolving"),!0);let e=$(`
          ${t.evolution.final}%
          `);$("#evolution").append(e)}function Ts(){return"magic"===t.race.universe?F("city_wizard_tower_title"):t.race.evil?F("city_babel_title"):F("city_wardenclyffe")}function Es(){switch(t.race.species){case"orc":return F("city_basic_housing_orc_title");case"wolven":return F("city_basic_housing_wolven_title");case"sporgar":return F("city_basic_housing_sporgar_title");case"dracnid":case"balorg":return F("city_basic_housing_title7");case"imp":return F("city_basic_housing_title8");case"seraph":return F("city_basic_housing_seraph_title");case"unicorn":return F("city_basic_housing_unicorn_title")}switch(di[t.race.species].type){case"avian":return F("city_basic_housing_nest_title");case"plant":return F("city_basic_housing_entish_title");case"sand":return F("city_basic_housing_sand_title");case"polar":return F("city_basic_housing_polar_title");case"eldritch":return F("city_basic_housing_eldritch_title")}return t.city.ptrait.includes("trashed")?F("city_basic_housing_trash_title"):F("city_basic_housing_title")}function Is(e,a){switch(e){case"small":return Es();case"medium":return function(){switch(t.race.species){case"sporgar":return F("city_cottage_title2");case"balorg":return F("city_cottage_title3");case"imp":return F("city_basic_housing_title7");case"seraph":return F("city_cottage_title4");case"unicorn":return F("city_cottage_title5");case"dracnid":return F("city_cottage_title7")}switch(di[t.race.species].type){case"avian":return F("city_cottage_title6");case"eldritch":return F("city_cottage_title8")}return F("city_cottage_title1")}();case"large":return function(e){if(!e&&N("extravagant",0))return F("city_mansion");if("sporgar"===t.race.species)return F("city_apartment_title2");switch(di[t.race.species].type){case"avian":return F("city_apartment_title5");case"sand":return F("city_apartment_title6");case"demonic":return F("city_apartment_title3");case"angelic":return F("city_apartment_title4");case"giant":return F("city_apartment_title7");case"eldritch":return F("city_apartment_title8")}return F("city_apartment_title1")}(a)}}function Ks(e,a){if(t.tech.queue&&t.queue.display){let e=["space","interstellar","galaxy","portal","tauceti"];for(let r=0;r-1)if(e.includes(s.action)){let e=!0;Object.keys(Qr[s.action]).forEach((function(a){Qr[s.action][a][s.type]&&e&&(t.queue.queue[r].label="string"==typeof Qr[s.action][a][s.type].title?Qr[s.action][a][s.type].title:Qr[s.action][a][s.type].title(),e=!1)}))}else Qr[s.action][s.type]&&(t.queue.queue[r].label="string"==typeof Qr[s.action][s.type].title?Qr[s.action][s.type].title:Qr[s.action][s.type].title())}}if(e&&t.tech.r_queue&&t.r_queue.display)for(let e=0;e=4&&Mi(e)})),Object.keys(di[t.race.species].traits).forEach((function(e){Mi(e,{set:di[t.race.species].traits[e]})})),t.race.imitation&&t.race.srace&&ki(!1),Object.keys(t.tech).forEach((function(e){"evo_"===e.substring(0,4)&&delete t.tech[e]})),delete t.tech.evo,t.evolution={};const i=new Date;!t.settings.boring&&11===i.getMonth()&&i.getDate()>=17&&("elven"===t.race.species?(Mi("slaver",{set:2}),Mi("resourceful",{set:.5}),Mi("small",{set:.25})):"capybara"===t.race.species?(Mi("beast_of_burden",{set:1}),Mi("pack_rat",{set:.5}),Mi("musical",{set:.25})):"centaur"===t.race.species?(Mi("beast_of_burden",{set:1}),Mi("curious",{set:.5}),Mi("blissful",{set:.25})):"wendigo"===t.race.species?(Mi("immoral",{set:3}),Mi("cannibalize",{set:.5}),Mi("claws",{set:.25})):"yeti"===t.race.species?(Mi("scavenger",{set:3}),Mi("regenerative",{set:.5}),Mi("musical",{set:.25})):"entish"===t.race.species&&(Mi("photosynth",{set:3}),Mi("optimistic",{set:.5}),Mi("armored",{set:.25})));const c=Tc("easter");if("wolven"===t.race.species&&c.active?(Mi("hyper",{set:1}),Mi("fast_growth",{set:1}),Mi("rainbow",{set:1}),Mi("optimistic",{set:1})):"vulpine"===t.race.species&&c.active&&(Mi("cannibalize",{set:2}),Mi("rage",{set:1}),Mi("blood_thirst",{set:1}),Mi("sticky",{set:1})),t.race.no_crispr||t.race.badgenes){let e=t.race.badgenes?3:1;for(let a=0;a=2)for(let e=1;e<8;e++)t.genes.evolve>=e+1&&hi(e);let l=Ji();t.civic.foreign.gov0.name={s0:l.s0,s1:l.s1};let u=Ji();for(;l.s0===u.s0&&l.s1===u.s1;)u=Ji();t.civic.foreign.gov1.name={s0:u.s0,s1:u.s1};let d=Ji();for(;l.s0===d.s0&&l.s1===d.s1||u.s0===d.s0&&u.s1===d.s1;)d=Ji();if(t.civic.foreign.gov2.name={s0:d.s0,s1:d.s1},t.race.truepath||t.race.lone_survivor){t.civic.foreign.gov0.mil=Math.round(1.5*t.civic.foreign.gov0.mil),t.civic.foreign.gov1.mil=Math.round(1.4*t.civic.foreign.gov1.mil),t.civic.foreign.gov2.mil=Math.round(1.25*t.civic.foreign.gov2.mil),t.civic.foreign.gov3={unrest:0,hstl:Math.floor(m(20,40)),mil:Math.floor(m(650,750)),eco:Math.floor(m(250,300)),spy:0,esp:0,trn:0,sab:0,act:"none"};let e=Ji(!0);t.civic.foreign.gov3.name={s0:e.s0,s1:e.s1},t.civic.foreign.gov4={unrest:0,hstl:100,mil:300,eco:100,spy:0,esp:0,trn:0,sab:0,act:"none"};let a=Ji(!0);for(;a.s1===e.s1;)a=Ji(!0);t.civic.foreign.gov4.name={s0:99,s1:a.s1}}if(t.race.cataclysm?Di(F("cataclysm_sentience",[di[t.race.species].home,Ac("name")]),"info",!1,["progress"]):Di(F("sentience",[F("genelab_genus_"+di[t.race.species].type),di[t.race.species].entity,Ac("name")]),"info",!1,["progress"]),t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1&&(t.resource.Steel.display=!0,t.resource.Steel.amount=25,t.stats.achieve.technophobe.l>=3)){t.race.truepath||(t.resource.Soul_Gem.display=!0);let e=1;for(let a=1;a=5&&e++;t.resource.Soul_Gem.amount=e}if("tortoisan"===t.race.species){let e=Math.floor(m(100));t.race.shell_color=99===e?"rainbow":e>=97&&e<=98?"white":e>=93&&e<=96?"red":e>=89&&e<=92?"orange":e>=85&&e<=88?"yellow":e>=75&&e<=84?"purple":e>=65&&e<=74?"blue":"green"}if("vulpine"===t.race.species){let e=Math.floor(m(100));t.race.fox_color=e>=85?"white":e>=70&&e<=84?"tan":e>=55&&e<=69?"silver":e>=35&&e<=54?"grey":"red"}if(_c(!0),t.blood.aware&&(t.settings.arpa.blood=!0,t.tech.b_stone=2),oa(!0),Y(),V(!0),t.race.shapeshifter&&qi(!1,!0),t.race.carnivore||t.race.soul_eater||t.race.unfathomable?(t.civic.d_job="hunter",t.civic.hunter.display=!0):t.race.forager?(t.civic.d_job="forager",t.civic.forager.display=!0):(t.civic.d_job="unemployed",t.civic.unemployed.display=!0),t.race.hooved&&(t.resource.Horseshoe.display=!0,t.resource.Horseshoe.amount=5,t.race.shoecnt=5),t.race.deconstructor&&(t.resource.Nanite.display=!0,t.city.nanite_factory={count:1,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Bolognium:0,Orichalcum:0},t.settings.showIndustry=!0),lc(!0),(t.race.truepath||t.race.lone_survivor)&&Object.keys(Qa).forEach((function(e){t.resource.hasOwnProperty(e)&&(t.resource[e].value=2*Qa[e])})),ni(t.race.species,!0),Zi("sentience",{species:t.race.species,challenge:ro()-1}),t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0){let e=Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept);t.resource.Food.amount+=100*e,t.resource.Stone.max+=60*e,t.resource.Stone.amount+=100*e,t.race.smoldering?(t.resource.Chrysotile.max+=60*e,t.resource.Chrysotile.amount+=100*e):(t.resource.Lumber.max+=60*e,t.resource.Lumber.amount+=100*e)}t.race.cataclysm?t.race.cataclysm&&(t.tech.unify=2,t.tech.spy=5,t.tech.primitive=3,t.tech.currency=6,t.tech.govern=3,t.tech.boot_camp=1,t.tech.medic=1,t.tech.military=5,t.tech.marines=1,t.tech.explosives=3,t.tech.trade=3,t.tech.wharf=1,t.tech.banking=6,t.tech.gambling=1,t.tech.home_safe=1,t.tech.housing=3,t.tech.smelting=3,t.tech.copper=1,t.tech.storage=5,t.tech.container=4,t.tech.steel_container=3,t.tech.mining=4,t.tech.oil=7,t.tech.mass=1,t.tech.alumina=1,t.tech.titanium=2,t.tech.polymer=2,t.tech.uranium=4,t.tech.foundry=7,t.tech.factory=1,t.tech.theatre=3,t.tech.broadcast=2,t.tech.mine_conveyor=1,t.tech.science=9,t.tech.high_tech=7,t.tech.genetics=1,t.tech.theology=2,t.tech.space=6,t.tech.solar=3,t.tech.luna=2,t.tech.hell=1,t.tech.mars=5,t.tech.gas_giant=1,t.tech.gas_moon=2,t.tech.asteroid=3,t.tech.satellite=1,t.tech.space_explore=4,t.tech.genesis=2,t.settings.showSpace=!0,t.settings.space.home=!0,t.settings.space.moon=!0,t.settings.space.red=!0,t.settings.space.hell=!0,t.settings.space.sun=!0,t.settings.space.gas=!0,t.settings.space.gas_moon=!0,t.settings.space.belt=!0,t.settings.space.dwarf=!0,t.settings.showCity=!1,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.settings.civTabs=1,t.settings.spaceTabs=1,t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Food.display=!0,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Cement.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Uranium.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Alloy.display=!0,t.resource.Polymer.display=!0,t.resource.Iridium.display=!0,t.resource.Helium_3.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Mythril.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.resource.Lumber.max=9e4,t.resource.Lumber.amount=9e4,t.resource.Plywood.amount=5e4),t.race.smoldering&&(t.resource.Chrysotile.display=!0,t.resource.Chrysotile.max=9e4,t.resource.Chrysotile.amount=9e4),t.resource[t.race.species].max=8,t.resource[t.race.species].amount=8,t.resource.Crates.amount=20,t.resource.Containers.amount=20,t.resource.Money.max=225e3,t.resource.Money.amount=225e3,t.resource.Food.max=1e3,t.resource.Food.amount=1e3,t.resource.Oil.max=1e3,t.resource.Oil.amount=1e3,t.resource.Helium_3.max=1e3,t.resource.Helium_3.amount=1e3,t.resource.Uranium.max=1e3,t.resource.Uranium.amount=1e3,t.resource.Stone.max=9e4,t.resource.Stone.amount=9e4,t.resource.Furs.max=4e4,t.resource.Furs.amount=4e4,t.resource.Copper.max=75e3,t.resource.Copper.amount=75e3,t.resource.Iron.max=75e3,t.resource.Iron.amount=75e3,t.resource.Steel.max=75e3,t.resource.Steel.amount=75e3,t.resource.Aluminium.max=75e3,t.resource.Aluminium.amount=75e3,t.resource.Cement.max=75e3,t.resource.Cement.amount=75e3,t.resource.Titanium.max=75e3,t.resource.Titanium.amount=75e3,t.resource.Coal.max=1e4,t.resource.Coal.amount=1e4,t.resource.Alloy.max=2e4,t.resource.Alloy.amount=2e4,t.resource.Polymer.max=2e4,t.resource.Polymer.amount=2e4,t.resource.Iridium.max=1e3,t.resource.Iridium.amount=1e3,t.resource.Brick.amount=5e4,t.resource.Wrought_Iron.amount=5e4,t.resource.Sheet_Metal.amount=5e4,t.resource.Mythril.amount=8e3,t.resource.Iridium.crates=5,t.resource.Iridium.containers=5,t.civic.taxes.display=!0,t.civic.professor.display=!0,t.civic.scientist.display=!0,t.civic.colonist.display=!0,t.civic.space_miner.display=!0,t.race.flier||(t.tech.cement=5,t.civic.cement_worker.display=!0,t.civic.cement_worker.max=1,t.civic.cement_worker.workers=1),t.civic.colonist.max=4,t.civic.colonist.workers=4,t.civic.space_miner.max=3,t.civic.space_miner.workers=2,t.civic.professor.max=1,t.civic.professor.workers=1,t.city.calendar.day++,t.city.market.active=!0,t.city.power=0,t.city.powered=!0,t.race.artifical&&(t.city.transmitter={count:0,on:0}),t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:0,cap:2,Wood:0,Coal:0,Oil:2,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:1,Iridium:0},t.city.fission_power={count:0,on:0},t.city.oil_power={count:0,on:0},t.city.coal_power={count:0,on:0},t.city.mass_driver={count:0,on:0},t.city.mine={count:0,on:0},t.city.coal_mine={count:0,on:0},t.city.oil_well={count:0},t.city.oil_depot={count:0},t.city.garrison={count:0,on:0},t.city.basic_housing={count:0},t.city.cottage={count:0},t.city.apartment={count:0,on:0},t.city.amphitheatre={count:0},t.city.casino={count:0,on:0},t.city.rock_quarry={count:0,on:0,asbestos:50},t.city.metal_refinery={count:0,on:0},t.city.storage_yard={count:0},t.city.warehouse={count:0},t.city.trade={count:0},t.city.wharf={count:0},t.city.bank={count:0},t.city.tourist_center={count:0,on:0},t.city.university={count:0},t.city.library={count:0},t.city.wardenclyffe={count:0,on:0},t.city.biolab={count:0,on:0},t.city.lumber_yard={count:0},t.city.sawmill={count:0,on:0},t.city.temple={count:0},t.space.satellite={count:1},t.space.propellant_depot={count:1},t.space.gps={count:4},t.space.nav_beacon={count:1,on:1},t.space.moon_base={count:1,on:1,support:3,s_max:3},t.space.iridium_mine={count:1,on:1},t.space.helium_mine={count:1,on:1},t.space.observatory={count:1,on:1},t.space.spaceport={count:2,on:2,support:8,s_max:10},t.space.red_tower={count:1,on:1},t.space.living_quarters={count:4,on:4},t.space.vr_center={count:0,on:0},t.space.garage={count:1},t.space.red_mine={count:1,on:1},t.space.fabrication={count:1,on:1},t.space.red_factory={count:1,on:1},t.space.exotic_lab={count:1,on:1},t.space.ziggurat={count:0},t.space.space_barracks={count:1,on:1},t.space.biodome={count:2,on:2},t.space.laboratory={count:0,on:0},t.space.geothermal={count:2,on:2},t.space.spc_casino={count:0,on:0},t.space.swarm_plant={count:0},t.space.swarm_control={count:5,support:40,s_max:50},t.space.swarm_satellite={count:40},t.space.gas_mining={count:2,on:2},t.space.gas_storage={count:1},t.space.outpost={count:0,on:0},t.space.drone={count:0},t.space.oil_extractor={count:2,on:2},t.space.space_station={count:1,on:1,support:0,s_max:3},t.space.iridium_ship={count:1,on:1},t.space.elerium_ship={count:0,on:0},t.space.elerium_prospector={count:0,on:0},t.space.iron_ship={count:1,on:1},t.space.elerium_contain={count:0,on:0},t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:2,wounded:0,raid:0,max:2},hs(),ms(),Rt(),Oe("Physics"),ha()):t.race.lone_survivor?t.race.lone_survivor&&(t.tech.alloy=1,t.tech.alumina=2,t.tech.asteroid=7,t.tech.banking=11,t.tech.biotech=1,t.tech.boot_camp=2,t.tech.broadcast=2,t.tech.container=7,t.tech.copper=1,t.tech.currency=6,t.tech.disease=2,t.tech.drone=1,t.tech.elerium=2,t.tech.explosives=3,t.tech.factory=3,t.tech.foundry=8,t.tech.gambling=4,t.tech.gas_giant=1,t.tech.gas_moon=2,t.tech.genesis=2,t.tech.genetics=2,t.tech.gov_corp=1,t.tech.gov_fed=1,t.tech.gov_soc=1,t.tech.gov_theo=1,t.tech.govern=3,t.tech.graphene=1,t.tech.helium=1,t.tech.hell=1,t.tech.high_tech=13,t.tech.home_safe=2,t.tech.housing=3,t.tech.housing_reduction=3,t.tech.kuiper=2,t.tech.launch_facility=1,t.tech.luna=2,t.tech.m_smelting=2,t.tech.marines=2,t.tech.mars=5,t.tech.mass=1,t.tech.medic=3,t.tech.military=8,t.tech.mine_conveyor=1,t.tech.mining=4,t.tech.monument=1,t.tech.nano=1,t.tech.oil=7,t.tech.outer=8,t.tech.pickaxe=5,t.tech.polymer=2,t.tech.primitive=3,t.tech.q_factory=1,t.tech.quantium=1,t.tech.queue=3,t.tech.r_queue=1,t.tech.reproduction=1,t.tech.rival=1,t.tech.satellite=1,t.tech.science=9,t.tech.shelving=3,t.tech.shipyard=1,t.tech.smelting=6,t.tech.solar=5,t.tech.space=6,t.tech.space_explore=4,t.tech.space_housing=1,t.tech.spy=5,t.tech.stanene=1,t.tech.steel_container=6,t.tech.storage=5,t.tech.swarm=6,t.tech.syard_armor=3,t.tech.syard_class=6,t.tech.syard_engine=5,t.tech.syard_power=5,t.tech.syard_sensor=4,t.tech.syard_weapon=6,t.tech.syndicate=0,t.tech.synthetic_fur=1,t.tech.tau_home=6,t.tech.tauceti=4,t.tech.theatre=3,t.tech.theology=2,t.tech.titan=9,t.tech.titan_ai_core=3,t.tech.titan_power=1,t.tech.titanium=3,t.tech.trade=3,t.tech.unify=2,t.tech.uranium=4,t.tech.v_train=1,t.tech.vault=4,t.tech.wharf=1,t.tech.world_control=1,t.tech.wsc=0,t.race.flier||(t.tech.cement=5,t.resource.Cement.display=!0),"magic"===t.race.universe&&(t.tech.gov_mage=1,t.tech.magic=4,t.tech.conjuring=2,t.resource.Mana.display=!0,t.resource.Crystal.display=!0,t.civic.crystal_miner.display=!0,t.tauceti.pylon={count:0},t.race.casting={farmer:0,miner:0,lumberjack:0,science:0,factory:0,army:0,hunting:0,crafting:0,total:0,crafting:0}),t.settings.showSpace=!1,t.settings.showTau=!0,t.settings.tau.home=!0,t.settings.showCity=!1,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.settings.civTabs=1,t.settings.spaceTabs=6,t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.settings.arpa.genetics=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.resource.Food.display=!0,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Uranium.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Alloy.display=!0,t.resource.Polymer.display=!0,t.resource.Iridium.display=!0,t.resource.Helium_3.display=!0,t.resource.Water.display=!0,t.resource.Neutronium.display=!0,t.resource.Adamantite.display=!0,t.resource.Elerium.display=!0,t.resource.Nano_Tube.display=!0,t.resource.Graphene.display=!0,t.resource.Stanene.display=!0,t.resource.Orichalcum.display=!0,t.resource.Bolognium.display=!0,t.resource.Unobtainium.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Mythril.display=!0,t.resource.Quantium.display=!0,t.resource.Cipher.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.civic.lumberjack.display=!0,t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.resource.Lumber.max=1e7,t.resource.Lumber.amount=1e7,t.resource.Plywood.amount=25e5,t.resource.Lumber.crates=25,t.resource.Lumber.containers=25,t.tech.axe=5),t.race.smoldering&&(t.resource.Chrysotile.display=!0,t.resource.Chrysotile.max=5e6,t.resource.Chrysotile.amount=5e6),t.race.sappy||(t.tech.hammer=4),t.race.apex_predator||(t.tech.armor=3),t.resource[t.race.species].max=1,t.resource[t.race.species].amount=1,t.resource.Crates.amount=1e3,t.resource.Containers.amount=1e3,t.resource.Money.max=1e9,t.resource.Money.amount=1e9,t.resource.Knowledge.max=8e6,t.resource.Knowledge.amount=8e6,t.resource.Food.max=1e4,t.resource.Food.amount=1e4,t.resource.Oil.max=5e5,t.resource.Oil.amount=5e5,t.resource.Helium_3.max=5e5,t.resource.Helium_3.amount=5e5,t.resource.Water.max=25e3,t.resource.Water.amount=25e3,t.resource.Uranium.max=5e5,t.resource.Uranium.amount=5e5,t.resource.Stone.max=1e7,t.resource.Stone.amount=1e7,t.resource.Furs.max=5e6,t.resource.Furs.amount=5e6,t.resource.Copper.max=5e6,t.resource.Copper.amount=5e6,t.resource.Iron.max=5e6,t.resource.Iron.amount=5e6,t.resource.Steel.max=5e6,t.resource.Steel.amount=5e6,t.resource.Aluminium.max=5e6,t.resource.Aluminium.amount=5e6,t.resource.Cement.max=5e6,t.resource.Cement.amount=5e6,t.resource.Titanium.max=5e6,t.resource.Titanium.amount=5e6,t.resource.Coal.max=5e6,t.resource.Coal.amount=5e6,t.resource.Alloy.max=5e6,t.resource.Alloy.amount=5e6,t.resource.Polymer.max=5e6,t.resource.Polymer.amount=5e6,t.resource.Iridium.max=5e6,t.resource.Iridium.amount=5e6,t.resource.Neutronium.max=5e5,t.resource.Neutronium.amount=5e5,t.resource.Adamantite.max=5e6,t.resource.Adamantite.amount=5e6,t.resource.Elerium.max=1e3,t.resource.Elerium.amount=1e3,t.resource.Nano_Tube.max=5e6,t.resource.Nano_Tube.amount=5e6,t.resource.Graphene.max=5e6,t.resource.Graphene.amount=5e6,t.resource.Stanene.max=5e6,t.resource.Stanene.amount=5e6,t.resource.Bolognium.max=5e6,t.resource.Bolognium.amount=5e6,t.resource.Orichalcum.max=5e6,t.resource.Orichalcum.amount=5e6,t.resource.Brick.amount=25e5,t.resource.Wrought_Iron.amount=25e5,t.resource.Sheet_Metal.amount=25e5,t.resource.Mythril.amount=25e5,t.resource.Quantium.amount=25e5,t.race.artifical||(t.resource.Food.crates=10,t.resource.Food.containers=10),t.resource.Stone.crates=25,t.resource.Stone.containers=25,t.resource.Furs.crates=25,t.resource.Furs.containers=25,t.resource.Coal.crates=10,t.resource.Coal.containers=10,t.resource.Copper.crates=25,t.resource.Copper.containers=25,t.resource.Iron.crates=25,t.resource.Iron.containers=25,t.resource.Aluminium.crates=25,t.resource.Aluminium.containers=25,t.resource.Steel.crates=25,t.resource.Steel.containers=25,t.resource.Titanium.crates=25,t.resource.Titanium.containers=25,t.resource.Alloy.crates=25,t.resource.Alloy.containers=25,t.resource.Polymer.crates=25,t.resource.Polymer.containers=25,t.resource.Iridium.crates=25,t.resource.Iridium.containers=25,t.resource.Adamantite.crates=25,t.resource.Adamantite.containers=25,t.resource.Graphene.crates=25,t.resource.Graphene.containers=25,t.resource.Stanene.crates=25,t.resource.Stanene.containers=25,t.resource.Bolognium.crates=25,t.resource.Bolognium.containers=25,t.resource.Orichalcum.crates=25,t.resource.Orichalcum.containers=25,t.civic.taxes.display=!0,t.race.flier||(t.civic.cement_worker.display=!0,t.resource.Cement.crates=25,t.resource.Cement.containers=25),t.race.sappy||(t.civic.quarry_worker.display=!0),t.civic.professor.display=!0,t.civic.scientist.display=!0,t.civic.banker.display=!0,t.civic.pit_miner.display=!0,t.civic.professor.max=1,t.civic.professor.workers=1,t.city.calendar.day++,t.city.market.active=!0,t.city.power=0,t.city.powered=!0,t.race.artifical&&(t.city.transmitter={count:0,on:0}),t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:0,cap:2,Wood:0,Coal:0,Oil:2,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:1,Iridium:0},t.city.amphitheatre={count:0},t.city.apartment={count:0,on:0},t.city.bank={count:0},t.city.basic_housing={count:0},t.city.biolab={count:0,on:0},t.city.boot_camp={count:0},t.city.casino={count:0,on:0},t.city.cement_plant={count:0,on:0},t.city.coal_mine={count:0,on:0},t.city.coal_power={count:0,on:0},t.city.cottage={count:0},t.city.fission_power={count:0,on:0},t.city.garrison={count:0,on:0},t.city.hospital={count:0},t.city.library={count:0},t.city.lumber_yard={count:0},t.city.mass_driver={count:0,on:0},t.city.metal_refinery={count:0,on:0},t.city.mine={count:0,on:0},t.city.oil_depot={count:0},t.city.oil_power={count:0,on:0},t.city.oil_well={count:0},t.city.rock_quarry={count:0,on:0,asbestos:50},t.city.sawmill={count:0,on:0},t.city.shed={count:0,on:0},t.city.storage_yard={count:0},t.city.temple={count:0},t.city.tourist_center={count:0,on:0},t.city.trade={count:0},t.city.university={count:0},t.city.wardenclyffe={count:0,on:0},t.city.warehouse={count:0},t.city.wharf={count:0},t.space.ai_colonist={count:0,on:0},t.space.ai_core={count:100},t.space.ai_core2={count:0,on:0},t.space.biodome={count:0,on:0},t.space.crashed_ship={count:100},t.space.decoder={count:0,on:0},t.space.digsite={count:0},t.space.drone={count:0},t.space.drone_control={count:0,on:0},t.space.e_reactor={count:0,on:0},t.space.electrolysis={count:0,on:0,support:0,s_max:0},t.space.elerium_contain={count:0,on:0},t.space.elerium_mine={count:0,on:0},t.space.elerium_ship={count:0,on:0},t.space.exotic_lab={count:0,on:0},t.space.fabrication={count:0,on:0},t.space.fob={count:0,on:0,troops:0,enemy:0},t.space.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},t.space.garage={count:0},t.space.gas_mining={count:0,on:0},t.space.gas_storage={count:0},t.space.geothermal={count:0,on:0},t.space.gps={count:0},t.space.helium_mine={count:0,on:0},t.space.hell_smelter={count:0,on:0},t.space.hydrogen_plant={count:0,on:0},t.space.iridium_mine={count:0,on:0},t.space.iridium_ship={count:0,on:0},t.space.iron_ship={count:0,on:0},t.space.lander={count:0,on:0},t.space.living_quarters={count:0,on:0},t.space.m_relay={count:0,on:0},t.space.mass_relay={count:100},t.space.moon_base={count:0,on:0,support:0,s_max:0},t.space.munitions_depot={count:0},t.space.nav_beacon={count:0,on:0},t.space.neutronium_mine={count:0,on:0},t.space.observatory={count:0,on:0},t.space.oil_extractor={count:0,on:0},t.space.operating_base={count:0,on:0},t.space.orichalcum_mine={count:0,on:0},t.space.outpost={count:0,on:0},t.space.propellant_depot={count:0},t.space.red_factory={count:0,on:0},t.space.red_mine={count:0,on:0},t.space.red_tower={count:0,on:0},t.space.satellite={count:0},t.space.shipyard={count:0,on:0,ships:[],expand:!1,sort:!0},t.space.shock_trooper={count:0,on:0},t.space.space_barracks={count:0,on:0},t.space.space_station={count:0,on:0,support:0,s_max:0},t.space.spaceport={count:0,on:0,support:0,s_max:0},t.space.spc_casino={count:0,on:0},t.space.storehouse={count:0},t.space.swarm_control={count:0,support:0,s_max:0},t.space.swarm_plant={count:0},t.space.swarm_satellite={count:0},t.space.tank={count:0,on:0},t.space.titan_bank={count:0},t.space.titan_mine={count:0,on:0},t.space.titan_quarters={count:0,on:0},t.space.titan_spaceport={count:0,on:0,support:0,s_max:0},t.space.uranium_mine={count:0,on:0},t.space.vr_center={count:0,on:0},t.space.water_freighter={count:0,on:0},t.space.zero_g_lab={count:0,on:0},t.space.ziggurat={count:0},t.tauceti.alien_outpost={count:1,on:1},t.tauceti.colony={count:1,on:1},t.tauceti.fusion_generator={count:1,on:1},t.tauceti.infectious_disease_lab={count:0,on:0,cure:0},t.tauceti.mining_pit={count:1,on:1},t.tauceti.orbital_platform={count:0,on:0,support:0,s_max:0},t.tauceti.orbital_station={count:1,on:1,support:0,s_max:0},t.tauceti.refueling_station={count:0,on:0},t.tauceti.repository={count:2},t.tauceti.tauceti_casino={count:0,on:0},t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:2,wounded:0,raid:0,max:2},t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!0,boost:!1,auto:!1,labs:0},t.tech.stock_exchange=0,t.tech.monuments=0,t.tech.supercollider=0,t.tech.tp_depot=0,t.tech.railway=0,t.tech.isolation=1,t.race.truepath=1,t.arpa.m_type=Oe("Monument"),ms(),tt(),Oe("Physics"),ha()):t.race.artifical&&t.race.artifical&&(t.tech.spy=5,t.tech.primitive=3,t.tech.currency=6,t.tech.govern=3,t.tech.boot_camp=1,t.tech.medic=1,t.tech.military=5,t.tech.explosives=3,t.tech.trade=3,t.tech.banking=6,t.tech.home_safe=1,t.tech.housing=3,t.tech.smelting=3,t.tech.copper=1,t.tech.storage=5,t.tech.container=4,t.tech.steel_container=3,t.tech.mining=4,t.tech.pickaxe=2,t.tech.hammer=2,t.tech.oil=3,t.tech.alumina=1,t.tech.titanium=1,t.tech.foundry=7,t.tech.factory=1,t.tech.theatre=3,t.tech.broadcast=1,t.tech.science=7,t.tech.high_tech=4,t.tech.theology=2,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Food.display=!0,t.resource.Money.amount=1e3,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.race.flier||(t.tech.cement=5,t.resource.Cement.display=!0),t.race.kindling_kindred||t.race.smoldering||(t.race.evil?(t.tech.reclaimer=3,t.city.graveyard={count:1}):(t.tech.axe=3,t.tech.saw=2,t.city.lumber_yard={count:1},t.city.sawmill={count:0,on:0}),t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.civic.lumberjack.display=!0),t.race.smoldering&&(t.resource.Chrysotile.display=!0),t.resource[t.race.species].max=0,t.resource[t.race.species].amount=0,t.resource.Crates.amount=10,t.resource.Containers.amount=10,t.civic.taxes.display=!0,t.civic.miner.display=!0,t.civic.coal_miner.display=!0,t.civic.quarry_worker.display=!0,t.civic.professor.display=!0,t.civic.scientist.display=!0,t.race.flier||(t.civic.cement_worker.display=!0),t.civic.banker.display=!0,t.city.calendar.day++,t.city.market.active=!0,t.city.power=7.5,t.city.powered=!0,t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:1,cap:0,Wood:0,Coal:0,Oil:1,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:0,Iridium:0},t.city.oil_power={count:1,on:1},t.city.coal_power={count:0,on:0},t.city.transmitter={count:1,on:1},t.city.mine={count:1,on:0},t.city.coal_mine={count:1,on:0},t.city.oil_well={count:1},t.city.oil_depot={count:1},t.city.cement_plant={count:1,on:0},t.city.garrison={count:0,on:0},t.city.boot_camp={count:0},t.city.basic_housing={count:0},t.city.cottage={count:0},t.city.apartment={count:0,on:0},t.city.amphitheatre={count:0},t.city.rock_quarry={count:1,on:0,asbestos:50},t.city.metal_refinery={count:1,on:0},t.city.shed={count:2},t.city.storage_yard={count:1},t.city.warehouse={count:1},t.city.trade={count:0},t.city.wharf={count:0},t.city.bank={count:1},t.city.university={count:1},t.city.library={count:1},t.city.wardenclyffe={count:0,on:0},t.city.temple={count:0},t.race.calm&&(t.resource.Zen.display=!0,t.city.meditation={count:0}),t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0}),t.civic.govern.type="technocracy",t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:0,wounded:0,raid:0,max:0},hs(),ms(),ha()),t.settings.tabLoad?(hs(),J(),fe($("#c_garrison"),!1),se(),t.race.cataclysm||t.race.lone_survivor?(rc($("#r_civics")),V(),Ws(),tr("market"),tr("storage"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color,r=a.resource[e].tradable;if(a.resource[e].stackable){var s=$(`
          `);$("#resStorage").append(s),fr(`#stack-${e}`,s,e,t)}r&&(s=$(`
          `),$("#market").append(s),ur(`#market-${e}`,s,e,t,!0))})),sr(),Oe("Genetics"),Oe("Crispr"),Oe("Blood")):t.sim&&(Oe("Crispr"),Oe("Blood"))):Ct("mTabCivil"),t.queue.hasOwnProperty("queue")&&(t.queue.queue=[]),(t.race.slow||t.race.hyper||"junker"===t.race.species)&&(e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload())}function Ns(e){switch(di[e].fanaticism){case"smart":t.race.dumb?(hi(5),Oe("Genetics")):Ds("smart");break;case"infectious":Ds("infectious"),"human"===t.race.species&&Xc("infested");break;case"blood_thirst":Ds("blood_thirst"),"entish"===t.race.species&&Xc("madagascar_tree");break;case"none":hi(5),Oe("Genetics");break;default:Ds(di[e].fanaticism)}}function Ds(e){t.race[e]?Mi(e)?"imitation"===e?ki(!0):"shapeshifter"===e&&qi(t.race.ss_genus):(hi(5),Oe("Genetics")):(t.race[e]=1,$i(e))}function Bs(){if(!t.settings.tabLoad&&3!==t.settings.civTabs)return;Gs(),rc($("#resQueue")),$("#resQueue").append($(`\n

          ${F("research_queue")} ({{ queue.length }}/{{ max }})

          \n \n `));let e=$('
            ');$("#resQueue").append(e),e.append($('
          • {{ item.label }} [{{ item.time | time }}]
          • '));try{sc({el:"#resQueue",data:t.r_queue,methods:{remove(e){Ei(`rq${t.r_queue.queue[e].id}`),t.r_queue.queue.splice(e,1),Bs(),ms()},setID:e=>`rq${t.r_queue.queue[e].id}`,pauseRQueue(){$("#pauserqueue").removeClass("play"),$("#pauserqueue").removeClass("pause"),t.r_queue.pause?(t.r_queue.pause=!1,$("#pauserqueue").addClass("play")):(t.r_queue.pause=!0,$("#pauserqueue").addClass("pause"))},pausedesc:()=>t.r_queue.pause?F("r_queue_play"):F("r_queue_pause")},filters:{time:e=>ic(e)}}),function(){let e=$("#resQueue .buildList")[0];Sortable.create(e,{onEnd(e){let a=t.r_queue.queue;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.r_queue.queue=a,Bs()}}),function(){for(let e=0;e=5?e-.01:e}function Hs(){let e=1800;t.tech.vault>=1?e=7500*(t.tech.vault+1):t.tech.banking>=5?e=9e3:t.tech.banking>=3&&(e=4e3),t.race.paranoid&&(e*=1-ui.paranoid.vars()[0]/100),t.race.hoarder&&(e*=1+ui.hoarder.vars()[0]/100);let a=Pi("dracnid");a>0&&(e*=1+ui.hoarder.vars(1)[0]/100*a),t.tech.banking>=7&&(e*=1+Me(.05*na(t.civic.banker.workers,"banker"))),t.tech.banking>=8&&(e+=Me(25*t.resource[t.race.species].amount)),t.tech.stock_exchange&&(e*=1+.1*t.tech.stock_exchange),t.tech.world_control&&(e*=1.25),t.race.truepath&&(e*=1.25),t.blood.greed&&(e*=1+t.blood.greed/100),t.stats.achieve.wheelbarrow&&(e*=1+t.stats.achieve.wheelbarrow.l/50),t.race.inflation&&(e*=1+t.race.inflation/125);let r=N("risktaker",0);return r&&(e*=1+r/100),e}function Us(e,a,r){switch(e){case"smelter":!function(e,a){let r=$(`
            ${F("modal_smelter_fuel")}: {{s.count | on}}/{{ s.cap }}
            `);if(e.append(r),e.hasClass("modalBody")){let e=$c(10);e.length>0&&r.prepend(e)}if(a&&t.race.forge&&t.race.steelen){let e=kc(3,12,!0);e.length>0&&r.prepend(e)}let s=e.hasClass("modalBody")?"mSmelterFuels":"smelterFuels",i=$(`
            `);if(e.append(i),!t.race.forge){if(!t.race.kindling_kindred&&!t.race.smoldering||t.race.evil){let e=t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?t.resource.Food.name:t.resource.Furs.name:t.resource.Lumber.name,a=$(`${e} {{ s.Wood }}`),r=$('«'),s=$('»');i.append(r),i.append(a),i.append(s)}if(t.resource.Coal.display){let e=$(`${t.resource.Coal.name} `),a=$('«'),r=$('»');i.append(a),i.append(e),i.append(r)}}if(t.race.forge){let e=$(`${F("trait_forge_name")} {{ s.Oil }}`);i.append(e)}else if(t.resource.Oil.display){let e=$(`${t.resource.Oil.name} {{ s.Oil }}`),a=$('«'),r=$('»');i.append(a),i.append(e),i.append(r)}if(t.tech.star_forge&&t.tech.star_forge>=2){let e=$(`${F("star")} {{ s.Star }}`);i.append(e)}if(t.tech.smelting&&t.tech.smelting>=8){let e=$(`${F("modal_smelter_inferno")} {{ s.Inferno }}`),t=$('«'),a=$('»');i.append(t),i.append(e),i.append(a)}let c=$('
            ');e.append(c);let o=!!(t.tech.irid_smelting||t.tech.m_smelting&&t.tech.m_smelting>=2);if(t.resource.Iridium.display&&o||t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen){let a=$(`
            `);e.append(a),a.append(`
            ${F("modal_smelter_type")}: {{s.count | son}}/{{ s.cap | on }}
            `);let r=$('
            ');a.append(r);let s=$(`${t.resource.Iron.name} {{ s.Iron }}`),i=$('«'),c=$('»');if(r.append(i),r.append(s),r.append(c),t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen){let e=$(`${t.resource.Steel.name} {{ s.Steel }}`),a=$('«'),s=$('»');r.append(a),r.append(e),r.append(s)}if(t.resource.Iridium.display&&o){let e=$(`${t.resource.Iridium.name} {{ s.Iridium }}`),a=$('«'),s=$('»');r.append(a),r.append(e),r.append(s)}}function n(e){switch(e){case"wood":return F("modal_build_wood",[t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?t.resource.Food.name:t.resource.Furs.name:t.resource.Lumber.name,t.race.evil&&!t.race.soul_eater||"wendigo"===t.race.species?1:3]);case"coal":{let e=t.race.kindling_kindred?.15:.25;return t.tech.uranium&&t.tech.uranium>=3?F("modal_build_coal2",[e,F("resource_Coal_name"),F("resource_Uranium_name")]):F("modal_build_coal1",[e,F("resource_Coal_name")])}case"oil":return t.race.forge?F("modal_build_forge"):F("modal_build_oil",["0.35",F("resource_Oil_name")]);case"star":return t.tech.irid_smelting?F("modal_build_star2",[F("resource_Titanium_name"),F("resource_Iridium_name")]):F("modal_build_star",[F("resource_Titanium_name")]);case"inferno":{let e=35,t=.5;return F("modal_build_inferno",[50,F("resource_Coal_name"),e,F("resource_Oil_name"),t,F("resource_Infernite_name")])}}}function l(e){if("steel"===e){let e=t.tech.smelting>=4?1.2:1;return t.tech.smelting>=5&&(e*=1.2),t.tech.smelting>=6&&(e*=1.2),t.tech.smelting>=7&&(e*=1.25),t.race.pyrophobia&&(e*=.9),F("modal_smelter_steel",[+e.toFixed(3),F("resource_Steel_name"),F("resource_Coal_name"),F("resource_Iron_name")])}if("iridium"===e){let e=t.tech.smelting>=7?6.25:5;return t.race.pyrophobia&&(e*=.9),F("modal_smelter_iron",[+e.toFixed(3),F("resource_Iridium_name")])}{let e=t.tech.smelting>=3?t.tech.smelting>=7?15:12:10;return t.race.pyrophobia&&(e*=.9),F("modal_smelter_iron",[+e.toFixed(3),F("resource_Iron_name")])}}sc({el:a||"#specialModal",data:{s:t.city.smelter,lum:t.resource.Lumber,coal:t.resource.Coal,oil:t.resource.Oil,food:t.resource.Food,fur:t.resource.Furs},methods:{addFuel(e){let a=y();for(let r=0;r=t.city.smelter.StarCap)break;if(a0))break;"Wood"!==e&&t.city.smelter.Wood>0?(t.city.smelter.Wood--,t.city.smelter[e]++):"Coal"!==e&&t.city.smelter.Coal>0?(t.city.smelter.Coal--,t.city.smelter[e]++):"Oil"!==e&&t.city.smelter.Oil>0?(t.city.smelter.Oil--,t.city.smelter[e]++):"Inferno"!==e&&t.city.smelter.Inferno>0&&(t.city.smelter.Inferno--,t.city.smelter[e]++)}}},subFuel(e){let a=y();for(let r=0;r0;r++){t.city.smelter[e]--,t.race.forge&&"Inferno"===e&&t.city.smelter.Oil++;let a=t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno;t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium>a&&(t.city.smelter.Iron>0?t.city.smelter.Iron--:t.city.smelter.Steel>0?t.city.smelter.Steel--:t.city.smelter.Iridium>0&&t.city.smelter.Iridium--)}},mLabel:e=>l(e),addMetal(e){let a=y();for(let r=0;r0&&"Iron"!==e)t.city.smelter.Iron--,t.city.smelter[e]++;else if(t.city.smelter.Steel>0&&"Steel"!==e)t.city.smelter.Steel--,t.city.smelter[e]++;else{if(!(t.city.smelter.Iridium>0&&"Iridium"!==e))break;t.city.smelter.Iridium--,t.city.smelter[e]++}}},subMetal(e){let a=y();t.city.smelter[e]-=a,t.city.smelter[e]<0&&(t.city.smelter[e]=0)},buildLabel:e=>n(e),ariaCount:e=>` ${t.city.smelter[e]} ${e} fueled.`,ariaProd:e=>`. ${t.city.smelter[e]} producing ${e}.`,net:e=>t.resource[e].diff>=0?"has-text-success":"has-text-danger",level:()=>Xs(t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,t.city.smelter.count)},filters:{on:e=>t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,son:e=>t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium,diffSize:e=>e>0?`+${k(e,2)}`:k(e,2),spook(e){if(a&&((t.race.kindling_kindred||t.race.smoldering)&&(6===t.city.smelter.Steel||6===t.city.smelter.Iron)||6===t.city.smelter.Wood)&&6===t.city.smelter.Coal&&6===t.city.smelter.Oil){let e=kc(3,12,!0);if(e.length>0)return e}return e},altspook(e){if(a&&t.race.forge&&6===t.city.smelter.Steel){let e=kc(3,12,!0);if(e.length>0)return e}return e}}});let u=e.hasClass("modalBody")?"mSmelterFuels":"smelterFuels";if(["wood","coal","oil","star","inferno"].forEach((function(e){Ti(`${u}${e}`,(function(){return n(e)}),{elm:$(`#${u} > .${e}`),attach:"#main"})})),t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen||t.resource.Iridium.display&&o){let a=e.hasClass("modalBody")?"mSmelterMats":"smelterMats";["iron","steel","iridium"].forEach((function(e){("steel"!==e||t.resource.Steel.display&&!t.race.steelen)&&("iridium"!==e||t.resource.Iridium.display&&o)&&Ti(`${a}${e}`,(function(){return l(e)}),{elm:$(`#${a} span.${e}`),attach:"#main"})}))}}(a,r);break;case"factory":!function(e,a){let r=$(`
            ${F("modal_factory_operate")}: {{count | on}}/{{ on | max }}
            `);e.append(r);let s=$(`
            ${F("modal_factory_lux")}
            `);e.append(s);let o=$(''),n=$('«'),l=$('»');if(s.append(n),s.append(o),s.append(l),t.tech.synthetic_fur){let a=$(`
            ${t.race.evil?F("resource_Flesh_name"):F("resource_Furs_name")}
            `);e.append(a);let r=$('{{ Furs }}'),s=$('«'),i=$('»');a.append(s),a.append(r),a.append(i)}let u=$(`
            ${F("resource_Alloy_name")}
            `);e.append(u);let d=$('{{ Alloy }}'),_=$('«'),p=$('»');if(u.append(_),u.append(d),u.append(p),t.tech.polymer){let t=$(`
            ${F("resource_Polymer_name")}
            `);e.append(t);let a=$('{{ Polymer }}'),r=$('«'),s=$('»');t.append(r),t.append(a),t.append(s)}if(t.tech.nano){let t=$(`
            ${F("resource_Nano_Tube_name")}
            `);e.append(t);let a=$('{{ Nano }}'),r=$('«'),s=$('»');t.append(r),t.append(a),t.append(s)}if(t.tech.stanene){let t=$(`
            ${F("resource_Stanene_name")}
            `);e.append(t);let a=$('{{ Stanene }}'),r=$('«'),s=$('»');t.append(r),t.append(a),t.append(s)}function h(e){let a=!!t.tech.factory;switch(e){case"Lux":{let e=+t.resource[t.race.species].amount*(a?Qs.Lux.demand[t.tech.factory]:Qs.Lux.demand[0]);return e=Zs(e).toFixed(2),F("modal_factory_lux_label",[a?Qs.Lux.fur[t.tech.factory]:Qs.Lux.fur[0],t.resource.Furs.name,e])}case"Furs":{let e=a?Qs.Furs.money[t.tech.factory]:Qs.Furs.money[0],r=a?Qs.Furs.polymer[t.tech.factory]:Qs.Furs.polymer[0];return F("modal_factory_alloy_label",[e,F("resource_Money_name"),r,F("resource_Polymer_name"),t.race.evil?F("resource_Flesh_name"):F("resource_Furs_name")])}case"Alloy":{let e=a?Qs.Alloy.copper[t.tech.factory]:Qs.Alloy.copper[0],r=a?Qs.Alloy.aluminium[t.tech.factory]:Qs.Alloy.aluminium[0];return F("modal_factory_alloy_label",[e,F("resource_Copper_name"),r,F("resource_Aluminium_name"),F("resource_Alloy_name")])}case"Polymer":if(t.race.kindling_kindred||t.race.smoldering)return F("modal_factory_polymer_label2",[a?Qs.Polymer.oil_kk[t.tech.factory]:Qs.Polymer.oil_kk[0],F("resource_Oil_name"),F("resource_Polymer_name")]);{let e=a?Qs.Polymer.oil[t.tech.factory]:Qs.Polymer.oil[0],r=a?Qs.Polymer.lumber[t.tech.factory]:Qs.Polymer.lumber[0];return F("modal_factory_polymer_label1",[e,F("resource_Oil_name"),r,t.resource.Lumber.name,F("resource_Polymer_name")])}case"Nano":{let e=a?Qs.Nano_Tube.coal[t.tech.factory]:Qs.Nano_Tube.coal[0],r=a?Qs.Nano_Tube.neutronium[t.tech.factory]:Qs.Nano_Tube.neutronium[0];return F("modal_factory_nano_label",[e,F("resource_Coal_name"),r,F("resource_Neutronium_name"),F("resource_Nano_Tube_name")])}case"Stanene":{let e=a?Qs.Stanene.aluminium[t.tech.factory]:Qs.Stanene.aluminium[0],r=a?Qs.Stanene.nano[t.tech.factory]:Qs.Stanene.nano[0];return F("modal_factory_stanene_label",[e,F("resource_Aluminium_name"),r,F("resource_Nano_Tube_name"),F("resource_Stanene_name")])}}}sc({el:a||"#specialModal",data:t.city.factory,methods:{subItem:function(e){let a=y();for(var r=0;r0;r++)t.city.factory[e]--},addItem:function(e){let a=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;t.interstellar.int_factory&&i.int_factory&&(a+=2*i.int_factory),t.tauceti.tau_factory&&c.tau_factory&&(a+=c.tau_factory*(t.tech.isolation?5:3));let r=y();for(var s=0;s0))break;t.city.factory.Alloy--,t.city.factory[e]++}}},buildLabel:function(e){return h(e)},ariaProd:e=>`. ${t.city.factory[e]} factories producing ${e}.`,level(){let e=t.city.factory.Lux+t.city.factory.Furs+t.city.factory.Alloy+t.city.factory.Polymer+t.city.factory.Nano+t.city.factory.Stanene,a=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;return t.interstellar.int_factory&&i.int_factory&&(a+=2*i.int_factory),t.tauceti.tau_factory&&c.tau_factory&&(a+=c.tau_factory*(t.tech.isolation?5:3)),Xs(e,a)}},filters:{on:()=>t.city.factory.Lux+t.city.factory.Furs+t.city.factory.Alloy+t.city.factory.Polymer+t.city.factory.Nano+t.city.factory.Stanene,max(){let e=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;return t.interstellar.int_factory&&i.int_factory&&(e+=2*i.int_factory),t.tauceti.tau_factory&&c.tau_factory&&(e+=c.tau_factory*(t.tech.isolation?5:3)),e},spook(e){if(3===t.city.factory.Lux&&a){let e=kc(6,12,!0);if(e.length>0)return e}return e}}}),["Lux","Furs","Alloy","Polymer","Nano","Stanene"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iFactory";Ti(`${a}${t}`,(function(){return h(t)}),{elm:$(`#${a} .factory > .${t}`),attach:"#main"})}))}(a,r);break;case"droid":!function(e,a){let r=$(`
            ${F("modal_factory_operate")}: {{count | on}}/{{ on | max }}
            `);e.append(r);let s=$(`
            ${F("resource_Adamantite_name")}
            `);e.append(s);let i=$('{{ adam }}'),c=$('«'),o=$('»');s.append(c),s.append(i),s.append(o);let n=$(`
            ${F("resource_Uranium_name")}
            `);e.append(n);let l=$('{{ uran }}'),u=$('«'),d=$('»');n.append(u),n.append(l),n.append(d);let _=$(`
            ${F("resource_Coal_name")}
            `);e.append(_);let p=$('{{ coal }}'),h=$('«'),m=$('»');_.append(h),_.append(p),_.append(m);let g=$(`
            ${F("resource_Aluminium_name")}
            `);e.append(g);let f=$('{{ alum }}'),v=$('«'),b=$('»');function w(e){switch(e){case"adam":return F("modal_droid_res_label",[F("resource_Adamantite_name")]);case"uran":return F("modal_droid_res_label",[F("resource_Uranium_name")]);case"coal":return F("modal_droid_res_label",[F("resource_Coal_name")]);case"alum":return F("modal_droid_res_label",[F("resource_Aluminium_name")])}}g.append(v),g.append(f),g.append(b),sc({el:a||"#specialModal",data:t.interstellar.mining_droid,methods:{subItem:function(e){let a=y();for(var r=0;r0;r++)t.interstellar.mining_droid[e]--},addItem:function(e){let a=y();for(var r=0;r`. ${t.interstellar.mining_droid[e]} driod mining ${e}.`,level:()=>Xs(t.interstellar.mining_droid.adam+t.interstellar.mining_droid.uran+t.interstellar.mining_droid.coal+t.interstellar.mining_droid.alum,t.interstellar.mining_droid.on)},filters:{on:()=>t.interstellar.mining_droid.adam+t.interstellar.mining_droid.uran+t.interstellar.mining_droid.coal+t.interstellar.mining_droid.alum,max:()=>t.interstellar.mining_droid.on}}),["adam","uran","coal","alum"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iDroid";Ti(`${a}${t}`,(function(){return w(t)}),{elm:$(`#${a} .factory > .${t}`),attach:"#main"})}))}(a,r);break;case"graphene":!function(e,a){let r=t.race.truepath?"space":"interstellar",s=$(`
            ${F("modal_smelter_fuel")}: {{count | on}}/{{ on | max }}
            `);e.append(s);let i=$("
            ");if(e.append(i),!t.race.kindling_kindred&&!t.race.smoldering){let e=t.resource.Lumber.name,a=$(`${e} {{ Lumber }}`),r=$('«'),s=$('»');i.append(r),i.append(a),i.append(s)}if(t.resource.Coal.display){let e=$(`${t.resource.Coal.name} {{ Coal }}`),a=$('«'),r=$('»');i.append(a),i.append(e),i.append(r)}if(t.resource.Oil.display){let e=$(`${t.resource.Oil.name} {{ Oil }}`),a=$('«'),r=$('»');i.append(a),i.append(e),i.append(r)}function c(e){switch(e){case"wood":return F("modal_graphene_produce",[350,t.race.evil?F("resource_Bones_name"):F("resource_Lumber_name"),F("resource_Graphene_name")]);case"coal":return F("modal_graphene_produce",[25,F("resource_Coal_name"),F("resource_Graphene_name")]);case"oil":return F("modal_graphene_produce",[15,F("resource_Oil_name"),F("resource_Graphene_name")])}}sc({el:a||"#specialModal",data:t[r].g_factory,methods:{subWood(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Lumber--},addWood(){let e=y();for(let a=0;a0))break;t[r].g_factory.Oil>t[r].g_factory.Coal?t[r].g_factory.Coal>0?t[r].g_factory.Coal--:t[r].g_factory.Oil--:t[r].g_factory.Oil>0?t[r].g_factory.Oil--:t[r].g_factory.Coal--,t[r].g_factory.Lumber++}},subCoal(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Coal--},addCoal(){let e=y();for(let a=0;a0))break;t[r].g_factory.Lumber>0?t[r].g_factory.Lumber--:t[r].g_factory.Oil--,t[r].g_factory.Coal++}},subOil(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Oil--},addOil(){let e=y();for(let a=0;a0))break;t[r].g_factory.Lumber>0?t[r].g_factory.Lumber--:t[r].g_factory.Coal--,t[r].g_factory.Oil++}},buildLabel:e=>c(e),ariaCount:e=>` ${t[r].g_factory[e]} ${e} fueled.`,ariaProd:e=>`. ${t[r].g_factory[e]} producing ${e}.`,level:()=>Xs(t[r].g_factory.Lumber+t[r].g_factory.Coal+t[r].g_factory.Oil,t[r].g_factory.on)},filters:{on:function(e){return t[r].g_factory.Lumber+t[r].g_factory.Coal+t[r].g_factory.Oil}}}),["wood","coal","oil"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iGraphene";Ti(`${a}${t}`,(function(){return c(t)}),{elm:$(`#${a} > div > .${t}`),attach:"#main"})}))}(a,r);break;case"pylon":!function(e,a){let r=$(`
            ${F("modal_pylon_casting")}: {{total | drain}}
            `);e.append(r);let s=$('
            ');e.append(s);let i=[];function c(e){let a=+Ys(t.race.casting[e]).toFixed(4),r=+(Ys(t.race.casting[e]+1)-Ys(t.race.casting[e])).toFixed(4),s=+(t.race.casting[e]/(t.race.casting[e]+75)*100).toFixed(2);return"crafting"===e?F("modal_pylon_casting_label_crafting",[a,s,+(2*t.race.casting[e]/(2*t.race.casting[e]+75)*100).toFixed(2),r]):F("modal_pylon_casting_label",[F(`modal_pylon_spell_${e}`),a,r,s])}i=t.race.orbit_decayed?["miner","science","factory","army","hunting","crafting"]:t.race.cataclysm?["science","factory","army","hunting","crafting"]:t.race.unfathomable?["miner","lumberjack","science","factory","army","hunting","crafting"]:["farmer","miner","lumberjack","science","factory","army","hunting","crafting"],t.tech.magic&&t.tech.magic>=3&&i.forEach((function(e){if("crafting"!==e&&"lumberjack"!==e&&"farmer"!==e||"farmer"===e&&!t.race.detritivore&&!t.race.carnivore&&!t.race.soul_eater&&!t.race.artifical||"lumberjack"===e&&!t.race.kindling_kindred&&!t.race.smoldering&&!t.race.evil||"crafting"===e&&t.tech.magic>=4){let t=$(`${F(`modal_pylon_spell_${e}`)} {{ ${e} }}`),a=$(`«`),r=$(`»`);s.append(a),s.append(t),s.append(r)}})),sc({el:a||"#specialModal",data:t.race.casting,methods:{buildLabel:e=>c(e),addSpell(e){let a=y();for(let r=0;r=a))break;t.race.casting[e]++,t.race.casting.total++,t.resource.Mana.diff-=a}},subSpell(e){let a=y();for(let r=0;r0;r++)t.race.casting[e]--,t.race.casting.total--},ariaCount:e=>` ${e} casting.`,level:()=>Xs(t.race.casting.total,t.resource.Mana.gen,!0)},filters:{drain:function(e){let a=0;return i.forEach((function(e){t.race.casting[e]&&t.race.casting[e]>0&&(a+=Ys(t.race.casting[e]))})),F("modal_pylon_casting_cost",[+a.toFixed(3)])}}}),i.forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iPylon";Ti(`${a}${t}`,(function(){return c(t)}),{elm:$(`#${a} > .pylon > .${t}`),attach:"#main"})}))}(a,r);break;case"rock_quarry":!function(e,a){e.append($(`
            ${F("modal_quarry_ratio",[t.resource.Chrysotile.name])}
            `));let r=$('
            «»
            ');e.append(r),sc({el:a||"#specialModal",data:t.city.rock_quarry,methods:{sub(){let e=y();t.city.rock_quarry.asbestos>0&&(t.city.rock_quarry.asbestos-=e,t.city.rock_quarry.asbestos<0&&(t.city.rock_quarry.asbestos=0))},add(){let e=y();t.city.rock_quarry.asbestos<100&&(t.city.rock_quarry.asbestos+=e,t.city.rock_quarry.asbestos>100&&(t.city.rock_quarry.asbestos=100))}}})}(a,r);break;case"titan_mine":!function(e,a){e.append($(`
            ${F("modal_quarry_ratio",[t.resource.Adamantite.name])}
            `));let r=$('
            «»
            ');e.append(r),sc({el:a||"#specialModal",data:t.space.titan_mine,methods:{sub(){let e=y();t.space.titan_mine.ratio>0&&(t.space.titan_mine.ratio-=e,t.space.titan_mine.ratio<0&&(t.space.titan_mine.ratio=0))},add(){let e=y();t.space.titan_mine.ratio<100&&(t.space.titan_mine.ratio+=e,t.space.titan_mine.ratio>100&&(t.space.titan_mine.ratio=100))}}})}(a,r);break;case"nanite_factory":!function(e,a){let r=$(`
            ${F("modal_factory_operate")}: {{count | on}}/{{ count | max }}
            `);e.append(r);let s=e.hasClass("modalBody")?"mNFactoryRes":"NFactoryRes",i=$(`
            `);e.append(i),Vs.forEach((function(e){if(t.resource[e].display){let a=$(`${t.resource[e].name} {{ ${e} }}`),r=$(`«`),s=$(`»`);i.append(r),i.append(a),i.append(s)}})),sc({el:a||"#specialModal",data:t.city.nanite_factory,methods:{subItem:function(e){let a=y();t.city.nanite_factory[e]-=a,t.city.nanite_factory[e]<0&&(t.city.nanite_factory[e]=0)},addItem:function(e){let a=y(),r=0;Vs.forEach((function(e){r+=t.city.nanite_factory[e]}));let s=50*t.city.nanite_factory.count-r;a>s&&(a=s),a>0&&(t.city.nanite_factory[e]+=a)},eatLabel:e=>`Consume ${e} to produce ${t.resource.Nanite.name}`,level(){let e=0;Vs.forEach((function(a){e+=t.city.nanite_factory[a]}));let a=t.city.nanite_factory.count;return Xs(e,a)}},filters:{on(){let e=0;return Vs.forEach((function(a){e+=t.city.nanite_factory[a]})),e},max:()=>50*t.city.nanite_factory.count}}),Vs.forEach((function(a){let r=e.hasClass("modalBody")?"specialModal":"iNFactory";Ti(`${r}${a}`,(function(){return function(e){let a=+(Va[e]/100*(ui.deconstructor.vars()[0]/100)).toFixed(4),r=+(t.city.nanite_factory[e]*a).toFixed(4);return F("modal_nfactory_resource_label",[1,t.resource[e].name,a,t.resource.Nanite.name,t.city.nanite_factory[e],r])}(a)}),{elm:$(`#${r} > .fuels > .${a}`),attach:"#main"})}))}(a,r);break;case"mining_ship":!function(e,a){e.append($(`
            ${F("tau_roid_mining_ship_ratio",[t.resource.Iron.name,t.resource.Aluminium.name])}
            `));let r=$('
            «»
            ');e.append(r),e.append($(`
            ${F("tau_roid_mining_ship_ratio",[t.resource.Iridium.name,t.resource.Neutronium.name])}
            `));let s=$('
            «»
            ');if(e.append(s),t.tech.tau_roid>=5){e.append($(`
            ${F("tau_roid_mining_ship_ratio",[t.resource.Orichalcum.name,t.resource.Elerium.name])}
            `));let a=$('
            «»
            ');e.append(a)}sc({el:a||"#specialModal",data:t.tauceti.mining_ship,methods:{sub(e){let a=y();t.tauceti.mining_ship[e]>0&&(t.tauceti.mining_ship[e]-=a,t.tauceti.mining_ship[e]<0&&(t.tauceti.mining_ship[e]=0))},add(e){let a=y();t.tauceti.mining_ship[e]<100&&(t.tauceti.mining_ship[e]+=a,t.tauceti.mining_ship[e]>100&&(t.tauceti.mining_ship[e]=100))}}})}(a,r);break;case"alien_space_station":!function(e,a){e.append($(`
            ${F("tau_gas2_alien_station_focus",[t.resource.Knowledge.name])}
            `));let r=$('
            «»
            ');e.append(r),sc({el:a||"#specialModal",data:t.tauceti.alien_space_station,methods:{sub(e){let a=y();t.tauceti.alien_space_station[e]>0&&(t.tauceti.alien_space_station[e]-=a,t.tauceti.alien_space_station[e]<0&&(t.tauceti.alien_space_station[e]=0))},add(e){let a=y();t.tauceti.alien_space_station[e]<100&&(t.tauceti.alien_space_station[e]+=a,t.tauceti.alien_space_station[e]>100&&(t.tauceti.alien_space_station[e]=100))}}})}(a,r);break;case"replicator":!function(e,a){if(t.race.replicator){e.append($(`
            ${"antimatter"===t.race.universe?F("tech_antireplicator"):F("tech_replicator")}
            `));let r=$('
            ');if(e.append(r),a){let e="";Object.keys(Va).forEach((function(a){e+=`${t.resource[a].name}`})),r.append(`
            \n ${e}\n
            `)}else{let e="";Object.keys(Va).forEach((function(a){t.resource[a].display&&(e+=`${t.resource[a].name}`)})),r.append(`
            ${e}
            `)}let s=a?$("
            "):$('
            ');r.append(s);let i=$('{{ pow }}MW'),c=$('«'),o=$('»');if(s.append(c),s.append(i),s.append(o),e.append('
            {{ res | result }}
            '),sc({el:a||"#specialModal",data:t.race.replicator,methods:{less(){let e=y();t.race.replicator.pow>0&&(t.race.replicator.pow-=e,t.race.replicator.pow<0&&(t.race.replicator.pow=0))},more(){let e=y();t.race.replicator.pow+=e},setVal(e){t.resource[e].display&&(t.race.replicator.res=e)},avail:e=>t.resource[e].display,aria:()=>t.race.replicator.pow+"MW"},filters:{resName:e=>t.resource[e].name,result:e=>F("tau_replicator",[Js(e,t.race.replicator.pow).toFixed(3),t.resource[e].name])}}),!a){const e=document.getElementById("hscrolltarget");e.addEventListener("wheel",(t=>{t.preventDefault(),e.scrollLeft+=t.deltaY}))}}}(a,r)}}function Ws(){if(t.settings.tabLoad||2===t.settings.civTabs&&1===t.settings.govTabs){if(rc($("#industry")),t.city.smelter&&(t.city.smelter.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation)){var e=$(`

            ${F("city_smelter")}

            `);$("#industry").append(e),Us("smelter",e,"#iSmelter")}if(t.city.factory&&t.city.factory.count>0||t.space.red_factory&&t.space.red_factory.count>0||t.tauceti.tau_factory&&t.tauceti.tau_factory.count>0){var a=$(`

            ${F("city_factory")}

            `);$("#industry").append(a),Us("factory",a,"#iFactory")}if(t.interstellar.mining_droid&&t.interstellar.mining_droid.count>0){var r=$(`

            ${F("interstellar_mining_droid_title")}

            `);$("#industry").append(r),Us("droid",r,"#iDroid")}if(t.interstellar.g_factory&&t.interstellar.g_factory.count>0||t.space.g_factory&&(t.space.g_factory.count>0||t.tauceti.refueling_station&&t.tauceti.refueling_station.count>0)){var s=$(`

            ${F("interstellar_g_factory_title")}

            `);$("#industry").append(s),Us("graphene",s,"#iGraphene")}if(t.race.casting&&(t.city.pylon||t.space.pylon||t.tauceti.pylon)){var i=$(`

            ${F("city_pylon")}

            `);$("#industry").append(i),Us("pylon",i,"#iPylon")}if(t.race.smoldering&&t.city.rock_quarry&&!t.race.cataclysm&&!t.race.orbit_decayed&&!t.tech.isolation){var c=$(`

            ${F("city_rock_quarry")}

            `);$("#industry").append(c),Us("rock_quarry",c,"#iQuarry")}if(t.space.titan_mine&&t.space.titan_mine.count>0&&(c=$(`

            ${F("city_mine")}

            `),$("#industry").append(c),Us("titan_mine",c,"#iTMine")),t.tech.tau_roid&&t.tech.tau_roid>=4&&t.tauceti.mining_ship){var o=$(`

            ${F("tau_roid_mining_ship")}

            `);$("#industry").append(o),Us("mining_ship",o,"#iMiningShip")}if(t.tech.tau_gas2&&6===t.tech.tau_gas2&&t.tauceti.alien_space_station&&(!t.tech.alien_data||t.tech.alien_data<6)){var n=$(`

            ${F("tau_gas2_alien_station")}

            `);$("#industry").append(n),Us("alien_space_station",n,"#iAlienSpaceStation")}if(t.race.deconstructor&&t.city.nanite_factory){var l=$(`

            ${F("city_nanite_factory")}

            `);$("#industry").append(l),Us("nanite_factory",l,"#iNFactory")}if(t.race.replicator&&t.tech.replicator){var u=$(`

            ${"antimatter"===t.race.universe?F("tech_antireplicator"):F("tech_replicator")}

            `);$("#industry").append(u),Us("replicator",u,"#iReplicator")}}}Object.keys(es).forEach((e=>Qr.evolution[e]={id:`evolution-${e}`,title:F(`evo_challenge_${e}`),desc(){let a="";return"micro"===t.race.universe&&(a+=`
            ${F("evo_challenge_micro_warn")}
            `),a+=`
            ${F(`evo_challenge_${e}_desc`)}
            `,["sludge","junker"].includes(e)&&(a+=`
            ${F("evo_start")}
            `),a},condition:()=>t.evolution.hasOwnProperty(e),cost:{DNA:()=>"c"===es[e].t?25:50},challenge:!0,effect:()=>as(e),action(){return Os($(this)[0])&&("c"===es[e].t?function(e){t.race[e]?(delete t.race[e],$(`#evolution-${e}`).removeClass("hl"),"sludge"===e&&Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).removeClass("is-hidden")}))):(t.race[e]=1,$(`#evolution-${e}`).addClass("hl"),"sludge"===e&&(Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).addClass("is-hidden")})),t.race.junker&&delete t.race.junker),"orbit_decay"===e&&(delete t.race.cataclysm,t.race.lone_survivor&&(delete t.race.lone_survivor,["nerfed","badgenes"].forEach((function(e){delete t.race[Xr[e]]}))))),Zr(),ao()}(e):function(e){if(t.race.sludge||Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).removeClass("is-hidden")})),t.race[e])delete t.race[e],$(`#evolution-${e}`).removeClass("hl"),["nerfed","badgenes"].forEach((function(e){delete t.race[Xr[e]]}));else{["junker","cataclysm","banana","truepath","lone_survivor"].forEach((function(e){delete t.race[e],$(`#evolution-${e}`).removeClass("hl")})),t.race[e]=1,$(`#evolution-${e}`).addClass("hl"),"junker"===e&&(Object.keys(di).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).addClass("is-hidden")})),t.race.sludge&&delete t.race.sludge),"cataclysm"!==e&&"lone_survivor"!==e||delete t.race.orbit_decay,"truepath"===e||"lone_survivor"===e?(t.race.nerfed=1,["crispr","plasmid","mastery"].forEach((function(e){delete t.race[Xr[e]]}))):(["nerfed","badgenes"].forEach((function(e){delete t.race[Xr[e]]})),"antimatter"===t.race.universe?(t.race.weak_mastery=1,$("#evolution-mastery").hasClass("hl")||$("#evolution-mastery").addClass("hl")):(t.race.no_plasmid=1,$("#evolution-plasmid").hasClass("hl")||$("#evolution-plasmid").addClass("hl")));let a="truepath"===e||"lone_survivor"===e?["badgenes","trade","craft"]:["crispr","trade","craft"];for(let e=0;ePc(es[e].e),highlight:()=>!!t.race[e],queue_complete:()=>0})),Qr.evolution.bunker={id:"evolution-bunker",title:F("evo_bunker"),desc:()=>`
            ${F("evo_bunker")}
            ${F("evo_challenge")}
            `,reqs:{evo:6},grant:["evo_challenge",1],condition:()=>t.genes.challenge&&100===t.evolution.final&&!t.race.evoFinalMenu,cost:{DNA:()=>10},effect:F("evo_bunker_effect"),action(){return!!Os($(this)[0])},queue_complete:()=>t.tech.evo_challenge?0:1,flair:F("evo_bunker_flair")};const Qs={Lux:{demand:[.14,.21,.28,.35,.42],fur:[2,3,4,5,6]},Furs:{money:[10,15,20,25,30],polymer:[1.5,2.25,3,3.75,4.5],output:[1,1.5,2,2.5,3]},Alloy:{copper:[.75,1.12,1.49,1.86,2.23],aluminium:[1,1.5,2,2.5,3],output:[.075,.112,.149,.186,.223]},Polymer:{oil_kk:[.22,.33,.44,.55,.66],oil:[.18,.27,.36,.45,.54],lumber:[15,22,29,36,43],output:[.125,.187,.249,.311,.373]},Nano_Tube:{coal:[8,12,16,20,24],neutronium:[.05,.075,.1,.125,.15],output:[.2,.3,.4,.5,.6]},Stanene:{aluminium:[30,45,60,75,90],nano:[.02,.03,.04,.05,.06],output:[.6,.9,1.2,1.5,1.8]}};function Zs(e){t.race.toxic&&(e*=1+ui.toxic.vars()[0]/100);let a=Pi("shroomi");return a>0&&(e*=1+ui.toxic.vars(1)[0]/100*a),"corpocracy"===t.civic.govern.type&&(e*=2.5),"socialist"===t.civic.govern.type&&(e*=.8),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(e*=1.1),t.race.inflation&&(e*=1+t.race.inflation/1250),t.tech.isolation&&(e*=1+.5*(c.colony||0)),e*Pe("psychic_cash")}const Vs=["Lumber","Chrysotile","Stone","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal","Oil","Uranium","Steel","Titanium","Alloy","Polymer","Iridium","Helium_3","Water","Deuterium","Neutronium","Adamantite","Bolognium","Orichalcum"];function Js(e,a){return t.race.lone_survivor?17.5*u/Va[e]*a:12.5*(u||1)/Va[e]*a**.75}function Ys(e,t){return e*((1+(t=void 0===t?.0025:t))**e-1)}function Xs(e,t,a){return e<=0?a?"has-text-success":"has-text-danger":e>=t?a?"has-text-danger":"has-text-success":e<=t/3?a?"has-text-info":"has-text-caution":e<=.66*t?"has-text-warning":e
            ${F("power_grid_header")}
            Distribute Low Power
            `),sc({el:"#powerModeSwitch",data:t.settings}),Object.keys(e).forEach((function(a){if(!e[a].s)return;let r="";"power"===a&&(r=kc(7,12,!1)),e[a].r&&e[a].rs&&t[e[a].r][e[a].rs]?($("#powerGrid").append(`
            ${e[a].n} {{ support }}/{{ s_max }}
            `),sc({el:`#pg${a}sup`,data:t[e[a].r][e[a].rs]})):$("#powerGrid").append(`
            ${e[a].n}${r}
            `);let s=$(`
            `);$("#powerGrid").append(s);let i=0;for(let r=0;r`);o.append(` ${u}${d}`),o.append('{{ on | off }} {{ on }}'),o.append('« »'),s.append(o),sc({el:`#pg${l.id}${a}`,data:t[n][c[1]],methods:{power_on(){let e=y();for(let a=0;a0;a++)t[n][c[1]].on--;l.postPower&&setTimeout((function(){l.postPower(!1)}),250)},higher(){let t=$(`#pg${l.id}${a}`).attr("data-idx"),r=$(`#pg${l.id}${a}`).prevAll('.circuit:not(".inactive")').attr("data-idx");if(r>=0){let s=e[a].l;s.splice(r,0,s.splice(t,1)[0]),e[a].l=s,ti()}},lower(){let t=$(`#pg${l.id}${a}`).attr("data-idx"),r=$(`#pg${l.id}${a}`).nextAll('.circuit:not(".inactive")').attr("data-idx");if(rt[n][c[1]].count-e,idx(e){let t=$c(18,11);return 10===e&&t.length>0?"1"+t:e}}})}else{let e=$(`
            `);e.append(`${u}${d}`),s.append(e)}}!function(e){let t=$(`#grid${e}`)[0],a=ai();Sortable.create(t,{onEnd(t){let r=a[e].l;r.splice(t.newDraggableIndex,0,r.splice(t.oldDraggableIndex,1)[0]),a[e].l=r,ti()}})}(a);let c=$(`
            `);$("#powerGrid").append(c),sc({el:`#${a}GridReset`,data:{},methods:{resetGrid(e){Li(e,!0),ti()}}})}))}function ai(){return{power:{l:t.power,n:F("power"),s:!0,r:!1,rs:!1},moon:{l:t.support.moon,n:F("space_moon_info_name"),s:t.settings.space.moon,r:"space",rs:"moon_base"},red:{l:t.support.red,n:Xt().red,s:t.settings.space.red,r:"space",rs:"spaceport"},belt:{l:t.support.belt,n:F("space_belt_info_name"),s:t.settings.space.belt,r:"space",rs:"space_station"},alpha:{l:t.support.alpha,n:F("interstellar_alpha_name"),s:t.settings.space.alpha,r:"interstellar",rs:"starport"},nebula:{l:t.support.nebula,n:F("interstellar_nebula_name"),s:t.settings.space.nebula,r:"interstellar",rs:"nexus"},gateway:{l:t.support.gateway,n:F("galaxy_gateway"),s:t.settings.space.gateway,r:"galaxy",rs:"starbase"},alien2:{l:t.support.alien2,n:F("galaxy_alien",[di[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),s:t.settings.space.alien2,r:"galaxy",rs:"foothold"},lake:{l:t.support.lake,n:F("portal_lake_name"),s:t.settings.portal.lake,r:"portal",rs:"harbour"},spire:{l:t.support.spire,n:F("portal_spire_name"),s:t.settings.portal.spire,r:"portal",rs:"purifier"},titan:{l:t.support.titan,n:Xt().titan,s:t.settings.space.titan,r:"space",rs:"electrolysis"},enceladus:{l:t.support.enceladus,n:Xt().enceladus,s:t.settings.space.enceladus,r:"space",rs:"titan_spaceport"},eris:{l:t.support.eris,n:Xt().eris,s:t.settings.space.eris,r:"space",rs:"drone_control"},tau_home:{l:t.support.tau_home,n:F("tau_planet",[di[t.race.species].home]),s:t.settings.tau.home,r:"tauceti",rs:"orbital_station"},tau_red:{l:t.support.tau_red,n:F("tau_planet",[Xt().red]),s:t.settings.tau.red,r:"tauceti",rs:"orbital_platform"},tau_roid:{l:t.support.tau_roid,n:F("tau_roid_title"),s:t.settings.tau.roid,r:"tauceti",rs:"patrol_ship"}}}function ri(e){e=e||ai(),Object.keys(e).forEach((function(e){let t=$(`#grid${e}`)[0];if(t){let e=Sortable.get(t);e&&e.destroy()}}))}const si=new Date,ii=Ec(),ci=Ic(),oi=["diverse","arrogant","angry","lazy","paranoid","greedy","puny","dumb","nearsighted","gluttony","slow","hard_of_hearing","pessimistic","solitary","pyrophobia","skittish","nyctophilia","frail","atrophy","invertebrate","pathetic","invertebrate","unorganized","slow_regen","snowy","mistrustful","fragrant","freespirit","hooved","heavy","gnawer"];function ni(e,a){if(t.settings.boring)return t.race.hrt&&delete t.race.hrt,!1;switch(e){case"elven":case"capybara":case"centaur":case"wendigo":case"entish":case"yeti":return!!(11===si.getMonth()&&si.getDate()>=17||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"wolven":case"vulpine":return!!(ii.active||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"arraak":return!!(10===si.getMonth()&&si.getDate()>=22&&si.getDate()<=28||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"seraph":return!!(1===si.getMonth()&&14===si.getDate()||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"junker":return!!(ci.active||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0)}return!1}const li={humanoid:{adaptable:1,wasteful:1},carnivore:{carnivore:1,beast:1,cautious:1},herbivore:{herbivore:1,instinct:1},small:{small:1,weak:1},giant:{large:1,strong:1},reptilian:{cold_blooded:1,scales:1},avian:{flier:1,hollow_bones:1,sky_lover:1},insectoid:{high_pop:1,fast_growth:1,high_metabolism:1},plant:{sappy:1,asymmetrical:1},fungi:{detritivore:1,spongy:1},aquatic:{submerged:1,low_light:1},fey:{elusive:1,iron_allergy:1},heat:{smoldering:1,cold_intolerance:1},polar:{chilled:1,heat_intolerance:1},sand:{scavenger:1,nomadic:1},demonic:{immoral:1,evil:1,soul_eater:1},angelic:{blissful:1,pompous:1,holy:1},synthetic:{artifical:1,powered:1},eldritch:{psychic:1,tormented:1,darkness:1,unfathomable:1}},ui={adaptable:{name:F("trait_adaptable_name"),desc:F("trait_adaptable"),type:"genus",val:3,vars(e){switch(e||t.race.adaptable||1){case.25:return[3];case.5:return[5];case 1:return[10];case 2:return[15];case 3:return[20]}}},wasteful:{name:F("trait_wasteful_name"),desc:F("trait_wasteful"),type:"genus",val:-3,vars(e){switch(e||t.race.wasteful||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[6];case 3:return[4]}}},xenophobic:{name:F("trait_xenophobic_name"),desc:F("trait_xenophobic"),type:"genus",val:-5},carnivore:{name:F("trait_carnivore_name"),desc:F("trait_carnivore"),type:"genus",val:3,vars(e){switch(e||t.race.carnivore||1){case.25:return[65];case.5:return[60];case 1:return[50];case 2:return[40];case 3:return[35]}}},beast:{name:F("trait_beast_name"),desc:F("trait_beast"),type:"genus",val:2,vars(e){switch(e||t.race.beast||1){case.25:return[4,8,4];case.5:return[5,10,5];case 1:return[8,15,10];case 2:return[10,20,15];case 3:return[12,24,20]}}},cautious:{name:F("trait_cautious_name"),desc:F("trait_cautious"),type:"genus",val:-2,vars(e){switch(e||t.race.cautious||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},herbivore:{name:F("trait_herbivore_name"),desc:F("trait_herbivore"),type:"genus",val:-7},instinct:{name:F("trait_instinct_name"),desc:F("trait_instinct"),type:"genus",val:5,vars(e){switch(e||t.race.instinct||1){case.25:return[3,15];case.5:return[5,25];case 1:return[10,50];case 2:return[15,60];case 3:return[20,65]}}},small:{name:F("trait_small_name"),desc:F("trait_small"),type:"genus",val:6,vars(e){switch(e||t.race.small||1){case.25:return[.0025,.0015];case.5:return[.005,.0025];case 1:return[.01,.005];case 2:return[.0125,.006];case 3:return[.015,.0075]}}},weak:{name:F("trait_weak_name"),desc:F("trait_weak"),type:"genus",val:-3,vars(e){switch(e||t.race.weak||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},large:{name:F("trait_large_name"),desc:F("trait_large"),type:"genus",val:-5,vars(e){switch(e||t.race.large||1){case.25:return[.007];case.5:return[.006];case 1:return[.005];case 2:return[.004];case 3:return[.003]}}},strong:{name:F("trait_strong_name"),desc:F("trait_strong"),type:"genus",val:5,vars(e){switch(e||t.race.strong||1){case.25:return[2,1.25];case.5:return[3,1.5];case 1:return[4,2];case 2:return[5,2.25];case 3:return[6,2.5]}}},cold_blooded:{name:F("trait_cold_blooded_name"),desc:F("trait_cold_blooded"),type:"genus",val:-2,vars(e){switch(e||t.race.cold_blooded||1){case.25:return[30,6];case.5:return[25,8];case 1:return[20,10];case 2:return[15,15];case 3:return[12,18]}}},scales:{name:F("trait_scales_name"),desc:F("trait_scales"),type:"genus",val:5,vars(e){switch(e||t.race.scales||1){case.25:return[1,0,1];case.5:return[1,1,1];case 1:return[2,1,1];case 2:return[2,2,1];case 3:return[2,2,2]}}},flier:{name:F("trait_flier_name"),desc:F("trait_flier"),type:"genus",val:3,vars(e){switch(e||t.race.flier||1){case.25:return[10,0];case.5:return[15,0];case 1:return[25,1];case 2:return[40,1];case 3:return[50,2]}}},hollow_bones:{name:F("trait_hollow_bones_name"),desc:F("trait_hollow_bones"),type:"genus",val:2,vars(e){switch(e||t.race.hollow_bones||1){case.25:return[1];case.5:return[2];case 1:return[5];case 2:return[8];case 3:return[10]}}},sky_lover:{name:F("trait_sky_lover_name"),desc:F("trait_sky_lover"),type:"genus",val:-2,vars(e){switch(e||t.race.sky_lover||1){case.25:return[40];case.5:return[30];case 1:return[20];case 2:return[15];case 3:return[10]}}},rigid:{name:F("trait_rigid_name"),desc:F("trait_rigid"),type:"genus",val:-2,vars(e){switch(e||t.race.rigid||1){case.25:return[3];case.5:return[2];case 1:return[1];case 2:return[.5];case 3:return[.4]}}},high_pop:{name:F("trait_high_pop_name"),desc:F("trait_high_pop"),type:"genus",val:3,vars(e){switch(e||t.race.high_pop||1){case.25:return[2,50,1.5];case.5:return[3,34,2.5];case 1:return[4,26,3.5];case 2:return[5,21.2,4.5];case 3:return[6,18,5.5]}}},fast_growth:{name:F("trait_fast_growth_name"),desc:F("trait_fast_growth"),type:"genus",val:2,vars(e){switch(e||t.race.fast_growth||1){case.25:return[1.5,1];case.5:return[2,1];case 1:return[2,2];case 2:return[2.5,3];case 3:return[3,3]}}},high_metabolism:{name:F("trait_high_metabolism_name"),desc:F("trait_high_metabolism"),type:"genus",val:-1,vars(e){switch(e||t.race.high_metabolism||1){case.25:return[10];case.5:return[8];case 1:return[5];case 2:return[2];case 3:return[1]}}},photosynth:{name:F("trait_photosynth_name"),desc:F("trait_photosynth"),type:"genus",val:3,vars(e){switch(e||t.race.photosynth||1){case.25:return[10,5,4];case.5:return[20,10,5];case 1:return[40,20,10];case 2:return[50,30,15];case 3:return[60,35,20]}}},sappy:{name:F("trait_sappy_name"),desc:F("trait_sappy",[F("resource_Amber_name")]),type:"genus",val:4,vars(e){switch(e||t.race.sappy||1){case.25:return[.4];case.5:return[.5];case 1:return[.6];case 2:return[.65];case 3:return[.7]}}},asymmetrical:{name:F("trait_asymmetrical_name"),desc:F("trait_asymmetrical"),type:"genus",val:-3,vars(e){switch(e||t.race.asymmetrical||1){case.25:return[30];case.5:return[25];case 1:return[20];case 2:return[15];case 3:return[10]}}},detritivore:{name:F("trait_detritivore_name"),desc:F("trait_detritivore"),type:"genus",val:2,vars(e){switch(e||t.race.detritivore||1){case.25:return[65];case.5:return[72];case 1:return[80];case 2:return[85];case 3:return[90]}}},spores:{name:F("trait_spores_name"),desc:F("trait_spores"),type:"genus",val:2,vars(e){switch(e||t.race.spores||1){case.25:return[1,1.5,1];case.5:return[2,1.5,1];case 1:return[2,2,1];case 2:return[2,2.5,2];case 3:return[2,3,2]}}},spongy:{name:F("trait_spongy_name"),desc:F("trait_spongy"),type:"genus",val:-2},submerged:{name:F("trait_submerged_name"),desc:F("trait_submerged"),type:"genus",val:3},low_light:{name:F("trait_low_light_name"),desc:F("trait_low_light"),type:"genus",val:-2,vars(e){switch(e||t.race.low_light||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},elusive:{name:F("trait_elusive_name"),desc:F("trait_elusive"),type:"genus",val:7,vars(e){switch(e||t.race.elusive||1){case.25:return[10];case.5:return[15];case 1:return[20];case 2:return[25];case 3:return[30]}}},iron_allergy:{name:F("trait_iron_allergy_name"),desc:F("trait_iron_allergy"),type:"genus",val:-4,vars(e){switch(e||t.race.iron_allergy||1){case.25:return[40];case.5:return[35];case 1:return[25];case 2:return[18];case 3:return[15]}}},smoldering:{name:F("trait_smoldering_name"),desc:F("trait_smoldering"),type:"genus",val:7,vars(e){switch(e||t.race.smoldering||1){case.25:return[3,.14,.08];case.5:return[4,.18,.1];case 1:return[5,.35,.2];case 2:return[10,.38,.22];case 3:return[12,.4,.24]}}},cold_intolerance:{name:F("trait_cold_intolerance_name"),desc:F("trait_cold_intolerance"),type:"genus",val:-4,vars(e){switch(e||t.race.cold_intolerance||1){case.25:return[.35];case.5:return[.3];case 1:return[.25];case 2:return[.2];case 3:return[.18]}}},chilled:{name:F("trait_chilled_name"),desc:F("trait_chilled"),type:"genus",val:7,vars(e){switch(e||t.race.chilled||1){case.25:return[1,.14,.08,5,2,20];case.5:return[2,.18,.1,10,5,18];case 1:return[5,.35,.2,20,10,15];case 2:return[10,.38,.22,25,12,10];case 3:return[12,.4,.24,30,14,8]}}},heat_intolerance:{name:F("trait_heat_intolerance_name"),desc:F("trait_heat_intolerance"),type:"genus",val:-4,vars(e){switch(e||t.race.heat_intolerance||1){case.25:return[.35];case.5:return[.3];case 1:return[.25];case 2:return[.2];case 3:return[.18]}}},scavenger:{name:F("trait_scavenger_name"),desc:F("trait_scavenger"),type:"genus",val:3,vars(e){switch(e||t.race.scavenger||1){case.25:return[.08,20];case.5:return[.1,22];case 1:return[.12,25];case 2:return[.14,30];case 3:return[.16,32]}}},nomadic:{name:F("trait_nomadic_name"),desc:F("trait_nomadic"),type:"genus",val:-5},immoral:{name:F("trait_immoral_name"),desc:F("trait_immoral"),type:"genus",val:4,vars(e){switch(e||t.race.immoral||1){case.25:return[-30];case.5:return[-20];case 1:return[0];case 2:return[20];case 3:return[30]}}},evil:{name:F("trait_evil_name"),desc:F("trait_evil"),type:"genus",val:0},blissful:{name:F("trait_blissful_name"),desc:F("trait_blissful"),type:"genus",val:3,vars(e){switch(e||t.race.blissful||1){case.25:return[70];case.5:return[60];case 1:return[50];case 2:return[40];case 3:return[30]}}},pompous:{name:F("trait_pompous_name"),desc:F("trait_pompous"),type:"genus",val:-6,vars(e){switch(e||t.race.pompous||1){case.25:return[85];case.5:return[80];case 1:return[75];case 2:return[65];case 3:return[60]}}},holy:{name:F("trait_holy_name"),desc:F("trait_holy"),type:"genus",val:4,vars(e){switch(e||t.race.holy||1){case.25:return[25,10];case.5:return[30,15];case 1:return[50,25];case 2:return[60,35];case 3:return[65,40]}}},artifical:{name:F("trait_artifical_name"),desc:F("trait_artifical"),type:"genus",val:5,vars(e){switch(e||t.race.artifical||1){case.25:return[5];case.5:return[10];case 1:return[20];case 2:return[25];case 3:return[30]}}},powered:{name:F("trait_powered_name"),desc:F("trait_powered"),type:"genus",val:-6,vars(e){switch(e||t.race.powered||1){case.25:return[.35,5];case.5:return[.3,8];case 1:return[.2,16];case 2:return[.1,20];case 3:return[.05,24]}}},psychic:{name:F("trait_psychic_name"),desc:F("trait_psychic"),type:"genus",val:10,vars(e){switch(e||t.race.psychic||1){case.25:return[.35,5,.01,20];case.5:return[.65,10,.025,30];case 1:return[1,15,.05,40];case 2:return[1.25,20,.075,50];case 3:return[1.5,25,.1,60]}}},tormented:{name:F("trait_tormented_name"),desc:F("trait_tormented"),type:"genus",val:-25,vars(e){switch(e||t.race.tormented||1){case.25:return[99];case.5:return[95];case 1:return[90];case 2:return[80];case 3:return[75]}}},darkness:{name:F("trait_darkness_name"),desc:F("trait_darkness"),type:"genus",val:1,vars(e){switch(e||t.race.darkness||1){case.25:return[1];case.5:return[2];case 1:return[3];case 2:return[4];case 3:return[5]}}},unfathomable:{name:F("trait_unfathomable_name"),desc:F("trait_unfathomable"),type:"genus",val:15,vars(e){switch(e||t.race.unfathomable||1){case.25:return[1,.5,.05];case.5:return[1,.65,.08];case 1:return[2,.8,.1];case 2:return[2,.9,.12];case 3:return[3,1,.13]}}},creative:{name:F("trait_creative_name"),desc:F("trait_creative"),type:"major",val:8,vars(e){switch(e||t.race.creative||1){case.25:return[.0015,5];case.5:return[.0025,10];case 1:return[.005,20];case 2:return[.006,22];case 3:return[.0065,24]}}},diverse:{name:F("trait_diverse_name"),desc:F("trait_diverse"),type:"major",val:-4,vars(e){switch(e||t.race.diverse||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},studious:{name:F("trait_studious_name"),desc:F("trait_studious"),type:"major",val:2,vars(e){switch(e||t.race.studious||1){case.25:return[.1,6];case.5:return[.15,8];case 1:return[.25,10];case 2:return[.35,12];case 3:return[.4,14]}}},arrogant:{name:F("trait_arrogant_name"),desc:F("trait_arrogant"),type:"major",val:-2,vars(e){switch(e||t.race.arrogant||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},brute:{name:F("trait_brute_name"),desc:F("trait_brute"),type:"major",val:7,vars(e){switch(e||t.race.brute||1){case.25:return[20,50];case.5:return[25,60];case 1:return[50,100];case 2:return[60,120];case 3:return[65,140]}}},angry:{name:F("trait_angry_name"),desc:F("trait_angry"),type:"major",val:-1,vars(e){switch(e||t.race.angry||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},lazy:{name:F("trait_lazy_name"),desc:F("trait_lazy"),type:"major",val:-4,vars(e){switch(e||t.race.lazy||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},curious:{name:F("trait_curious_name"),desc:F("trait_curious"),type:"major",val:4,vars(e){switch(e||t.race.curious||1){case.25:return[.03];case.5:return[.05];case 1:return[.1];case 2:return[.12];case 3:return[.13]}}},pack_mentality:{name:F("trait_pack_mentality_name"),desc:F("trait_pack_mentality"),type:"major",val:4,vars(e){switch(e||t.race.pack_mentality||1){case.25:return[.04,.016];case.5:return[.035,.018];case 1:return[.03,.02];case 2:return[.026,.022];case 3:return[.024,.023]}}},tracker:{name:F("trait_tracker_name"),desc:F("trait_tracker"),type:"major",val:2,vars(e){switch(e||t.race.tracker||1){case.25:return[10];case.5:return[15];case 1:return[20];case 2:return[25];case 3:return[30]}}},playful:{name:F("trait_playful_name"),desc:F("trait_playful"),type:"major",val:5,vars(e){switch(e||t.race.playful||1){case.25:return[.3];case.5:return[.4];case 1:return[.5];case 2:return[.6];case 3:return[.7]}}},freespirit:{name:F("trait_freespirit_name"),desc:F("trait_freespirit"),type:"major",val:-3,vars(e){switch(e||t.race.freespirit||1){case.25:return[65];case.5:return[60];case 1:return[50];case 2:return[35];case 3:return[25]}}},beast_of_burden:{name:F("trait_beast_of_burden_name"),desc:F("trait_beast_of_burden"),type:"major",val:3},sniper:{name:F("trait_sniper_name"),desc:F("trait_sniper"),type:"major",val:6,vars(e){switch(e||t.race.sniper||1){case.25:return[4];case.5:return[6];case 1:return[8];case 2:return[9];case 3:return[10]}}},hooved:{name:F("trait_hooved_name"),desc:F("trait_hooved"),type:"major",val:-4,vars(e){switch(e||t.race.hooved||1){case.25:return[130];case.5:return[120];case 1:return[100];case 2:return[80];case 3:return[70]}}},rage:{name:F("trait_rage_name"),desc:F("trait_rage"),type:"major",val:4,vars(e){switch(e||t.race.rage||1){case.25:return[.3,20];case.5:return[.5,30];case 1:return[1,50];case 2:return[1.25,60];case 3:return[1.4,65]}}},heavy:{name:F("trait_heavy_name"),desc:F("trait_heavy"),type:"major",val:-4,vars(e){switch(e||t.race.heavy||1){case.25:return[18,10];case.5:return[15,8];case 1:return[10,5];case 2:return[8,4];case 3:return[6,3]}}},gnawer:{name:F("trait_gnawer_name"),desc:F("trait_gnawer"),type:"major",val:-1,vars(e){switch(e||t.race.gnawer||1){case.25:return[.5];case.5:return[.4];case 1:return[.25];case 2:return[.2];case 3:return[.15]}}},calm:{name:F("trait_calm_name"),desc:F("trait_calm"),type:"major",val:6,vars(e){switch(e||t.race.calm||1){case.25:return[7];case.5:return[8];case 1:return[10];case 2:return[12];case 3:return[13]}}},pack_rat:{name:F("trait_pack_rat_name"),desc:F("trait_pack_rat"),type:"major",val:3,vars(e){switch(e||t.race.pack_rat||1){case.25:return[5,2];case.5:return[6,3];case 1:return[10,5];case 2:return[15,8];case 3:return[20,10]}}},paranoid:{name:F("trait_paranoid_name"),desc:F("trait_paranoid"),type:"major",val:-3,vars(e){switch(e||t.race.paranoid||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},greedy:{name:F("trait_greedy_name"),desc:F("trait_greedy"),type:"major",val:-5,vars(e){switch(e||t.race.greedy||1){case.25:return[17.5];case.5:return[15];case 1:return[12.5];case 2:return[10];case 3:return[8]}}},merchant:{name:F("trait_merchant_name"),desc:F("trait_merchant"),type:"major",val:3,vars(e){switch(e||t.race.merchant||1){case.25:return[10,3];case.5:return[15,5];case 1:return[25,10];case 2:return[35,12];case 3:return[40,13]}}},smart:{name:F("trait_smart_name"),desc:F("trait_smart"),type:"major",val:6,vars(e){switch(e||t.race.smart||1){case.25:return[3];case.5:return[5];case 1:return[10];case 2:return[12];case 3:return[13]}}},puny:{name:F("trait_puny_name"),desc:F("trait_puny"),type:"major",val:-4,vars(e){switch(e||t.race.puny||1){case.25:return[18];case.5:return[15];case 1:return[10];case 2:return[6];case 3:return[4]}}},dumb:{name:F("trait_dumb_name"),desc:F("trait_dumb"),type:"major",val:-5,vars(e){switch(e||t.race.dumb||1){case.25:return[7];case.5:return[6];case 1:return[5];case 2:return[4];case 3:return[3]}}},tough:{name:F("trait_tough_name"),desc:F("trait_tough"),type:"major",val:4,vars(e){switch(e||t.race.tough||1){case.25:return[10];case.5:return[15];case 1:return[25];case 2:return[35];case 3:return[40]}}},nearsighted:{name:F("trait_nearsighted_name"),desc:F("trait_nearsighted"),type:"major",val:-4,vars(e){switch(e||t.race.nearsighted||1){case.25:return[18];case.5:return[15];case 1:return[12];case 2:return[10];case 3:return[8]}}},intelligent:{name:F("trait_intelligent_name"),desc:F("trait_intelligent"),type:"major",val:7,vars(e){switch(e||t.race.intelligent||1){case.25:return[.08,.15];case.5:return[.1,.2];case 1:return[.125,.25];case 2:return[.14,.3];case 3:return[.15,.32]}}},regenerative:{name:F("trait_regenerative_name"),desc:F("trait_regenerative"),type:"major",val:8,vars:e=>[4],vars(e){switch(e||t.race.regenerative||1){case.25:return[2];case.5:return[3];case 1:return[4];case 2:return[5];case 3:return[6]}}},gluttony:{name:F("trait_gluttony_name"),desc:F("trait_gluttony"),type:"major",val:-2,vars(e){switch(e||t.race.gluttony||1){case.25:return[20];case.5:return[15];case 1:return[10];case 2:return[8];case 3:return[6]}}},slow:{name:F("trait_slow_name"),desc:F("trait_slow"),type:"major",val:-5,vars(e){switch(e||t.race.slow||1){case.25:return[13];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},armored:{name:F("trait_armored_name"),desc:F("trait_armored"),type:"major",val:4,vars(e){switch(e||t.race.armored||1){case.25:return[15,1];case.5:return[25,1];case 1:return[50,2];case 2:return[70,2];case 3:return[80,2]}}},optimistic:{name:F("trait_optimistic_name"),desc:F("trait_optimistic"),type:"major",val:5,vars(e){switch(e||t.race.optimistic||1){case.25:return[4,6];case.5:return[5,8];case 1:return[10,10];case 2:return[15,13];case 3:return[18,15]}}},chameleon:{name:F("trait_chameleon_name"),desc:F("trait_chameleon"),type:"major",val:6,vars(e){switch(e||t.race.chameleon||1){case.25:return[5,10];case.5:return[10,15];case 1:return[20,20];case 2:return[25,25];case 3:return[30,30]}}},slow_digestion:{name:F("trait_slow_digestion_name"),desc:F("trait_slow_digestion"),type:"major",val:1,vars(e){switch(e||t.race.slow_digestion||1){case.25:return[.3];case.5:return[.5];case 1:return[.75];case 2:return[1];case 3:return[1.25]}}},hard_of_hearing:{name:F("trait_hard_of_hearing_name"),desc:F("trait_hard_of_hearing"),type:"major",val:-3,vars(e){switch(e||t.race.hard_of_hearing||1){case.25:return[7];case.5:return[6];case 1:return[5];case 2:return[4];case 3:return[3]}}},resourceful:{name:F("trait_resourceful_name"),desc:F("trait_resourceful"),type:"major",val:4,vars(e){switch(e||t.race.resourceful||1){case.25:return[6];case.5:return[8];case 1:return[12];case 2:return[16];case 3:return[18]}}},selenophobia:{name:F("trait_selenophobia_name"),desc:F("trait_selenophobia"),type:"major",val:-6,vars(e){switch(e||t.race.selenophobia||1){case.25:return[2];case.5:return[3];case 1:return[4];case 2:return[5];case 3:return[6]}}},leathery:{name:F("trait_leathery_name"),desc:F("trait_leathery"),type:"major",val:2,vars(e){switch(e||t.race.leathery||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:return[1];case 3:return[0]}}},pessimistic:{name:F("trait_pessimistic_name"),desc:F("trait_pessimistic"),type:"major",val:-1,vars(e){switch(e||t.race.pessimistic||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:case 3:return[1]}}},hoarder:{name:F("trait_hoarder_name"),desc:F("trait_hoarder"),type:"major",val:4,vars(e){switch(e||t.race.hoarder||1){case.25:return[5];case.5:return[10];case 1:return[20];case 2:return[25];case 3:return[30]}}},solitary:{name:F("trait_solitary_name"),desc:F("trait_solitary"),type:"major",val:-1,vars(e){switch(e||t.race.solitary||1){case.25:return[.01,.025];case.5:return[.01,.02];case 1:return[.02,.02];case 2:return[.025,.02];case 3:return[.025,.015]}}},kindling_kindred:{name:F("trait_kindling_kindred_name"),desc:F("trait_kindling_kindred"),type:"major",val:8,vars(e){switch(e||t.race.kindling_kindred||1){case.25:return[10];case.5:return[8];case 1:return[5];case 2:return[4];case 3:return[3]}}},pyrophobia:{name:F("trait_pyrophobia_name"),desc:F("trait_pyrophobia"),type:"major",val:-4,vars(e){switch(e||t.race.pyrophobia||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},hyper:{name:F("trait_hyper_name"),desc:F("trait_hyper"),type:"major",val:4,vars(e){switch(e||t.race.hyper||1){case.25:return[2];case.5:return[3];case 1:return[5];case 2:return[6];case 3:return[7]}}},skittish:{name:F("trait_skittish_name"),desc:F("trait_skittish"),type:"major",val:-4,vars(e){switch(e||t.race.skittish||1){case.25:return[18];case.5:return[15];case 1:return[12];case 2:return[8];case 3:return[6]}}},fragrant:{name:F("trait_fragrant_name"),desc:F("trait_fragrant"),type:"major",val:-3,vars(e){switch(e||t.race.fragrant||1){case.25:return[35];case.5:return[30];case 1:return[20];case 2:return[15];case 3:return[12]}}},sticky:{name:F("trait_sticky_name"),desc:F("trait_sticky"),type:"major",val:3,vars(e){switch(e||t.race.sticky||1){case.25:return[5,5];case.5:return[10,8];case 1:return[20,15];case 2:return[25,18];case 3:return[30,20]}}},infectious:{name:F("trait_infectious_name"),desc:F("trait_infectious"),type:"major",val:4,vars(e){switch(e||t.race.infectious||1){case.25:return[1,2,3,7,18];case.5:return[1,2,4,8,20];case 1:return[2,3,5,10,25];case 2:return[2,4,6,12,30];case 3:return[3,4,7,13,32]}}},parasite:{name:F("trait_parasite_name"),desc:F("trait_parasite"),type:"major",val:-4},toxic:{name:F("trait_toxic_name"),desc:F("trait_toxic"),type:"major",val:5,vars(e){switch(e||t.race.toxic||1){case.25:return[5,3,10];case.5:return[10,5,15];case 1:return[20,8,30];case 2:return[25,10,40];case 3:return[30,12,45]}}},nyctophilia:{name:F("trait_nyctophilia_name"),desc:F("trait_nyctophilia"),type:"major",val:-3,vars(e){switch(e||t.race.nyctophilia||1){case.25:return[10,6];case.5:return[8,5];case 1:return[5,2];case 2:return[3,1];case 3:return[2,1]}}},infiltrator:{name:F("trait_infiltrator_name"),desc:F("trait_infiltrator"),type:"major",val:4,vars(e){switch(e||t.race.infiltrator||1){case.25:return[110];case.5:return[100];case 1:return[90];case 2:return[85];case 3:return[80]}}},hibernator:{name:F("trait_hibernator_name"),desc:F("trait_hibernator"),type:"major",val:-3,vars(e){switch(e||t.race.hibernator||1){case.25:return[15,8];case.5:return[20,8];case 1:return[25,8];case 2:return[30,6];case 3:return[35,5]}}},cannibalize:{name:F("trait_cannibalize_name"),desc:F("trait_cannibalize"),type:"major",val:5,vars(e){switch(e||t.race.cannibalize||1){case.25:return[8];case.5:return[10];case 1:return[15];case 2:return[20];case 3:return[22]}}},frail:{name:F("trait_frail_name"),desc:F("trait_frail"),type:"major",val:-5,vars(e){switch(e||t.race.frail||1){case.25:return[2,2];case.5:return[1,2];case 1:return[1,1];case 2:case 3:return[1,0]}}},malnutrition:{name:F("trait_malnutrition_name"),desc:F("trait_malnutrition"),type:"major",val:1,vars(e){switch(e||t.race.malnutrition||1){case.25:return[10];case.5:return[12];case 1:return[25];case 2:return[40];case 3:return[50]}}},claws:{name:F("trait_claws_name"),desc:F("trait_claws"),type:"major",val:5,vars(e){switch(e||t.race.claws||1){case.25:return[8];case.5:return[12];case 1:return[25];case 2:return[32];case 3:return[35]}}},atrophy:{name:F("trait_atrophy_name"),desc:F("trait_atrophy"),type:"major",val:-1,vars(e){switch(e||t.race.atrophy||1){case.25:return[.35];case.5:return[.25];case 1:return[.15];case 2:return[.1];case 3:return[.08]}}},hivemind:{name:F("trait_hivemind_name"),desc:F("trait_hivemind"),type:"major",val:9,vars(e){switch(e||t.race.hivemind||1){case.25:return[12];case.5:return[11];case 1:return[10];case 2:return[8];case 3:return[7]}}},tunneler:{name:F("trait_tunneler_name"),desc:F("trait_tunneler"),type:"major",val:2,vars(e){switch(e||t.race.tunneler||1){case.25:return[.002];case.5:return[.005];case 1:return[.01];case 2:return[.015];case 3:return[.018]}}},blood_thirst:{name:F("trait_blood_thirst_name"),desc:F("trait_blood_thirst"),type:"major",val:5,vars(e){switch(e||t.race.blood_thirst||1){case.25:return[25e4];case.5:return[5e5];case 1:return[1e6];case 2:return[2e6];case 3:return[4e6]}}},apex_predator:{name:F("trait_apex_predator_name"),desc:F("trait_apex_predator"),type:"major",val:6,vars(e){switch(e||t.race.apex_predator||1){case.25:return[15,20];case.5:return[20,30];case 1:return[30,50];case 2:return[40,60];case 3:return[45,65]}}},invertebrate:{name:F("trait_invertebrate_name"),desc:F("trait_invertebrate"),type:"major",val:-2,vars(e){switch(e||t.race.invertebrate||1){case.25:return[25];case.5:return[20];case 1:return[10];case 2:return[8];case 3:return[5]}}},suction_grip:{name:F("trait_suction_grip_name"),desc:F("trait_suction_grip"),type:"major",val:4,vars(e){switch(e||t.race.suction_grip||1){case.25:return[5];case.5:return[6];case 1:return[8];case 2:return[12];case 3:return[14]}}},befuddle:{name:F("trait_befuddle_name"),desc:F("trait_befuddle"),type:"major",val:4,vars(e){switch(e||t.race.befuddle||1){case.25:return[20];case.5:return[30];case 1:return[50];case 2:return[75];case 3:return[85]}}},environmentalist:{name:F("trait_environmentalist_name"),desc:F("trait_environmentalist"),type:"major",val:-5},unorganized:{name:F("trait_unorganized_name"),desc:F("trait_unorganized"),type:"major",val:-2,vars(e){switch(e||t.race.unorganized||1){case.25:return[90];case.5:return[80];case 1:return[50];case 2:return[40];case 3:return[30]}}},musical:{name:F("trait_musical_name"),desc:F("trait_musical"),type:"major",val:5,vars(e){switch(e||t.race.musical||1){case.25:return[.25];case.5:return[.5];case 1:return[1];case 2:return[1.1];case 3:return[1.2]}}},revive:{name:F("trait_revive_name"),desc:F("trait_revive"),type:"major",val:4,vars(e){switch(e||t.race.revive||1){case.25:return[7,5,2,8,6,3,4];case.5:return[6,4,2,7,5,2.5,4];case 1:return[5,3,1.5,6,4,2,3];case 2:return[4,2,1,5,3,1.5,2];case 3:return[3,1.5,1,4,2.5,1,2]}}},slow_regen:{name:F("trait_slow_regen_name"),desc:F("trait_slow_regen"),type:"major",val:-4,vars(e){switch(e||t.race.slow_regen||1){case.25:return[40];case.5:return[35];case 1:return[25];case 2:return[20];case 3:return[15]}}},forge:{name:F("trait_forge_name"),desc:F("trait_forge"),type:"major",val:4,vars(e){switch(e||t.race.forge||1){case.25:return[.5];case.5:return[1];case 1:return[2];case 2:return[2.5];case 3:return[3]}}},autoignition:{name:F("trait_autoignition_name"),desc:F("trait_autoignition"),type:"major",val:-4,vars(e){switch(e||t.race.autoignition||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:return[1.5];case 3:return[1]}}},blurry:{name:F("trait_blurry_name"),desc:F("trait_blurry"),type:"major",val:5,vars(e){switch(e||t.race.blurry||1){case.25:return[10];case.5:return[15];case 1:return[25];case 2:return[35];case 3:return[40]}}},snowy:{name:F("trait_snowy_name"),desc:F("trait_snowy"),type:"major",val:-3,vars(e){switch(e||t.race.snowy||1){case.25:return[4,10];case.5:return[3,8];case 1:return[2,5];case 2:return[2,4];case 3:return[1,3]}}},ravenous:{name:F("trait_ravenous_name"),desc:F("trait_ravenous"),type:"major",val:-5,vars(e){switch(e||t.race.ravenous||1){case.25:return[30,2];case.5:return[25,2];case 1:return[20,3];case 2:return[15,4];case 3:return[10,4]}}},ghostly:{name:F("trait_ghostly_name"),desc:F("trait_ghostly"),type:"major",val:5,vars(e){switch(e||t.race.ghostly||1){case.25:return[20,1.2,5];case.5:return[25,1.25,10];case 1:return[50,1.5,15];case 2:return[60,1.6,20];case 3:return[65,1.7,22]}}},lawless:{name:F("trait_lawless_name"),desc:F("trait_lawless"),type:"major",val:3,vars(e){switch(e||t.race.lawless||1){case.25:return[30];case.5:return[50];case 1:return[90];case 2:return[95];case 3:return[98]}}},mistrustful:{name:F("trait_mistrustful_name"),desc:F("trait_mistrustful"),type:"major",val:-1,vars(e){switch(e||t.race.mistrustful||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:case 3:return[1]}}},humpback:{name:F("trait_humpback_name"),desc:F("trait_humpback"),type:"major",val:4,vars(e){switch(e||t.race.humpback||1){case.25:return[.2,8];case.5:return[.25,10];case 1:return[.5,20];case 2:return[.75,25];case 3:return[.8,30]}}},thalassophobia:{name:F("trait_thalassophobia_name"),desc:F("trait_thalassophobia"),type:"major",val:-4},fiery:{name:F("trait_fiery_name"),desc:F("trait_fiery"),type:"major",val:10,vars(e){switch(e||t.race.fiery||1){case.25:return[30,15];case.5:return[40,18];case 1:return[65,25];case 2:return[70,35];case 3:return[72,38]}}},terrifying:{name:F("trait_terrifying_name"),desc:F("trait_terrifying"),type:"major",val:6,vars(e){switch(e||t.race.terrifying||1){case.25:return[8,20];case.5:return[10,25];case 1:return[12,32];case 2:return[12,34];case 3:return[12,36]}}},slaver:{name:F("trait_slaver_name"),desc:F("trait_slaver"),type:"major",val:12,vars(e){switch(e||t.race.slaver||1){case.25:return[.1];case.5:return[.14];case 1:return[.28];case 2:return[.3];case 3:return[.32]}}},compact:{name:F("trait_compact_name"),desc:F("trait_compact"),type:"major",val:10,vars(e){switch(e||t.race.compact||1){case.25:return[.005,.003];case.5:return[.01,.005];case 1:return[.015,.0075];case 2:return[.018,.0085];case 3:return[.02,.009]}}},conniving:{name:F("trait_conniving_name"),desc:F("trait_conniving"),type:"major",val:4,vars(e){switch(e||t.race.conniving||1){case.25:return[2,8];case.5:return[3,10];case 1:return[5,15];case 2:return[8,20];case 3:return[10,24]}}},pathetic:{name:F("trait_pathetic_name"),desc:F("trait_pathetic"),type:"major",val:-5,vars(e){switch(e||t.race.pathetic||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},spiritual:{name:F("trait_spiritual_name"),desc:F("trait_spiritual"),type:"major",val:4,vars(e){switch(e||t.race.spiritual||1){case.25:return[8];case.5:return[10];case 1:return[13];case 2:return[15];case 3:return[18]}}},truthful:{name:F("trait_truthful_name"),desc:F("trait_truthful"),type:"major",val:-7,vars(e){switch(e||t.race.truthful||1){case.25:return[75];case.5:return[65];case 1:return[50];case 2:return[30];case 3:return[20]}}},unified:{name:F("trait_unified_name"),desc:F("trait_unified"),type:"major",val:4,vars(e){switch(e||t.race.unified||1){case.25:return[0];case.5:return[1];case 1:return[3];case 2:return[5];case 3:return[7]}}},rainbow:{name:F("trait_rainbow_name"),desc:F("trait_rainbow"),type:"major",val:3,vars(e){switch(e||t.race.rainbow||1){case.25:return[20];case.5:return[30];case 1:return[50];case 2:return[80];case 3:return[100]}}},magnificent:{name:F("trait_magnificent_name"),desc:F("trait_magnificent"),type:"major",val:6,vars(e){switch(e||t.race.magnificent||1){case.25:return[300,1,.5,.75,1];case.5:return[350,2,.75,.8,1];case 1:return[400,3,1,1,1];case 2:return[450,3,1.5,1.5,1.5];case 3:return[500,3,2,2,2]}}},noble:{name:F("trait_noble_name"),desc:F("trait_noble"),type:"major",val:-3,vars(e){switch(e||t.race.noble||1){case.25:return[15,20];case.5:return[12,20];case 1:return[10,20];case 2:return[10,24];case 3:return[10,28]}}},imitation:{name:F("trait_imitation_name"),desc:F("trait_imitation"),type:"major",val:6,vars(e){switch(e||t.race.imitation||1){case.25:return[.25,.5];case.5:return[.25,1];case 1:return[.5,1];case 2:return[.5,2];case 3:return[1,2]}}},emotionless:{name:F("trait_emotionless_name"),desc:F("trait_emotionless"),type:"major",val:-4,vars(e){switch(e||t.race.emotionless||1){case.25:return[50,10];case.5:return[45,10];case 1:return[35,13];case 2:return[25,15];case 3:return[20,15]}}},logical:{name:F("trait_logical_name"),desc:F("trait_logical"),type:"major",val:6,vars(e){switch(e||t.race.logical||1){case.25:return[25,10];case.5:return[50,15];case 1:return[100,25];case 2:return[125,30];case 3:return[150,32]}}},shapeshifter:{name:F("trait_shapeshifter_name"),desc:F("trait_shapeshifter"),type:"major",val:10,vars(e){switch(e||t.race.shapeshifter||1){case.25:return[.25,.5];case.5:return[.25,1];case 1:return[.5,1];case 2:return[.5,2];case 3:return[1,2]}}},deconstructor:{name:F("trait_deconstructor_name"),desc:F("trait_deconstructor"),type:"major",val:-4,vars(e){switch(e||t.race.deconstructor||1){case.25:return[40];case.5:return[60];case 1:return[100];case 2:return[125];case 3:return[140]}}},linked:{name:F("trait_linked_name"),desc:F("trait_linked"),type:"major",val:4,vars(e){switch(e||t.race.linked||1){case.25:return[.03,40];case.5:return[.05,40];case 1:return[.1,80];case 2:return[.12,100];case 3:return[.14,100]}}},dark_dweller:{name:F("trait_dark_dweller_name"),desc:F("trait_dark_dweller"),type:"major",val:-3,vars(e){switch(e||t.race.dark_dweller||1){case.25:return[90];case.5:return[75];case 1:return[60];case 2:return[45];case 3:return[30]}}},swift:{name:F("trait_swift_name"),desc:F("trait_swift"),type:"major",val:10,vars(e){switch(e||t.race.swift||1){case.25:return[35,15];case.5:return[55,30];case 1:return[75,45];case 2:return[85,55];case 3:return[90,65]}}},anthropophagite:{name:F("trait_anthropophagite_name"),desc:F("trait_anthropophagite"),type:"major",val:-2,vars(e){switch(e||t.race.anthropophagite||1){case.25:return[.4];case.5:return[.65];case 1:return[1];case 2:return[1.5];case 3:return[2]}}},living_tool:{name:F("trait_living_tool_name"),desc:F("trait_living_tool"),type:"major",val:12,vars(e){switch(e||t.race.living_tool||1){case.25:return[.65,5];case.5:return[.8,12];case 1:return[1,25];case 2:return[1.1,35];case 3:return[1.2,42]}}},bloated:{name:F("trait_bloated_name"),desc:F("trait_bloated"),type:"major",val:-10,vars(e){switch(e||t.race.bloated||1){case.25:return[25];case.5:return[20];case 1:return[15];case 2:return[10];case 3:return[5]}}},ooze:{name:F("trait_ooze_name"),desc:F("trait_ooze"),type:"major",val:-50,vars(e){switch(e||t.race.ooze||1){case.25:return[20,25,40];case.5:return[15,20,35];case 1:return[12,15,30];case 2:return[10,12,25];case 3:return[8,10,20]}}},soul_eater:{name:F("trait_soul_eater_name"),desc:F("trait_soul_eater"),type:"special",val:0},untapped:{name:F("trait_untapped_name"),desc:F("trait_untapped"),type:"special",val:0},emfield:{name:F("trait_emfield_name"),desc:F("trait_emfield"),type:"special",val:-20},tactical:{name:F("trait_tactical_name"),desc:F("trait_tactical"),type:"minor",vars:e=>[5]},analytical:{name:F("trait_analytical_name"),desc:F("trait_analytical"),type:"minor",vars:e=>[1]},promiscuous:{name:F("trait_promiscuous_name"),desc:F("trait_promiscuous"),type:"minor",vars:e=>[1,.02]},resilient:{name:F("trait_resilient_name"),desc:F("trait_resilient"),type:"minor",vars:e=>[2]},cunning:{name:F("trait_cunning_name"),desc:F("trait_cunning"),type:"minor",vars:e=>[5]},hardy:{name:F("trait_hardy_name"),desc:F("trait_hardy"),type:"minor",vars:e=>[1]},ambidextrous:{name:F("trait_ambidextrous_name"),desc:F("trait_ambidextrous"),type:"minor",vars:e=>[3,2]},industrious:{name:F("trait_industrious_name"),desc:F("trait_industrious"),type:"minor",vars:e=>[2]},content:{name:F("trait_content_name"),desc:F("trait_content"),type:"minor"},fibroblast:{name:F("trait_fibroblast_name"),desc:F("trait_fibroblast"),type:"minor",vars:e=>[2]},metallurgist:{name:F("trait_metallurgist_name"),desc:F("trait_metallurgist"),type:"minor",vars:e=>[4]},gambler:{name:F("trait_gambler_name"),desc:F("trait_gambler"),type:"minor",vars:e=>[4]},persuasive:{name:F("trait_persuasive_name"),desc:F("trait_persuasive"),type:"minor",vars:e=>[1]},fortify:{name:F("trait_fortify_name"),desc:F("trait_fortify"),type:"special"},mastery:{name:F("trait_mastery_name"),desc:F("trait_mastery"),type:"special",vars:e=>[1]}},di={protoplasm:{name:F("race_protoplasm"),desc:F("race_protoplasm_desc"),type:"organism",home:F("race_prehistoric"),entity:"ooze",traits:{},solar:{red:F("race_human_solar_red"),hell:F("race_human_solar_hell"),gas:F("race_human_solar_gas"),gas_moon:F("race_human_solar_gas_moon"),dwarf:F("race_human_solar_dwarf")},fanaticism:"none",basic:()=>!1},human:{name:F("race_human"),desc:F("race_human_desc"),type:"humanoid",home:F("race_human_home"),entity:F("race_human_entity"),traits:{creative:1,diverse:1},solar:{red:F("race_human_solar_red"),hell:F("race_human_solar_hell"),gas:F("race_human_solar_gas"),gas_moon:F("race_human_solar_gas_moon"),dwarf:F("race_human_solar_dwarf")},fanaticism:"creative",basic:()=>!0},elven:{name:F("race_elven"),desc:F(ni("elven")?"race_xmas_elf_desc":"race_elven_desc"),type:"humanoid",home:F(ni("elven")?"race_xmas_elf_home":"race_elven_home"),entity:F("race_elven_entity"),traits:{studious:1,arrogant:1},solar:{red:F(ni("elven")?"race_xmas_elf_solar_red":"race_elven_solar_red"),hell:F(ni("elven")?"race_xmas_elf_solar_hell":"race_elven_solar_hell"),gas:F(ni("elven")?"race_xmas_elf_solar_gas":"race_elven_solar_gas"),gas_moon:F(ni("elven")?"race_xmas_elf_solar_gas_moon":"race_elven_solar_gas_moon"),dwarf:F(ni("elven")?"race_xmas_elf_solar_dwarf":"race_elven_solar_dwarf")},fanaticism:"studious",basic:()=>!0},orc:{name:F("race_orc"),desc:F("race_orc_desc"),type:"humanoid",home:F("race_orc_home"),entity:F("race_orc_entity"),traits:{brute:1,angry:1},solar:{red:F("race_orc_solar_red"),hell:F("race_orc_solar_hell"),gas:F("race_orc_solar_gas"),gas_moon:F("race_orc_solar_gas_moon"),dwarf:F("race_orc_solar_dwarf")},fanaticism:"brute",basic:()=>!0},cath:{name:F("race_cath"),desc:F("race_cath_desc"),type:"carnivore",home:F("race_cath_home"),entity:F("race_cath_entity"),traits:{lazy:1,curious:1},solar:{red:F("race_cath_solar_red"),hell:F("race_cath_solar_hell"),gas:F("race_cath_solar_gas"),gas_moon:F("race_cath_solar_gas_moon"),dwarf:F("race_cath_solar_dwarf")},fanaticism:"curious",basic:()=>!0},wolven:{name:ni("wolven")?F("race_rabbit"):F("race_wolven"),desc:ni("wolven")?F("race_rabbit_desc"):F("race_wolven_desc"),type:"carnivore",home:ni("wolven")?F("race_rabbit_home"):F("race_wolven_home"),entity:ni("wolven")?F("race_rabbit_entity"):F("race_wolven_entity"),traits:{pack_mentality:1,tracker:1},solar:{red:ni("wolven")?F("race_rabbit_solar_red"):F("race_wolven_solar_red"),hell:ni("wolven")?F("race_rabbit_solar_hell"):F("race_wolven_solar_hell"),gas:ni("wolven")?F("race_rabbit_solar_gas"):F("race_wolven_solar_gas"),gas_moon:ni("wolven")?F("race_rabbit_solar_gas_moon"):F("race_wolven_solar_gas_moon"),dwarf:ni("wolven")?F("race_rabbit_solar_dwarf"):F("race_wolven_solar_dwarf")},fanaticism:"tracker",basic:()=>!0},vulpine:{name:ni("vulpine")?F("race_chocolate_rabbit"):F("magic"===t.race.universe?"race_kitsune":"race_vulpine"),desc:()=>ni("vulpine")?F("race_chocolate_rabbit_desc"):F("race_vulpine_desc",[F("magic"===t.race.universe?"race_kitsune":"race_vulpine"),t.race.hasOwnProperty("fox_color")?F(`color_${t.race.fox_color}`):F("color_red")]),type:"carnivore",home:ni("vulpine")?F("race_chocolate_rabbit_home"):F("race_vulpine_home"),entity:F("race_vulpine_entity"),traits:{playful:1,freespirit:1},solar:{red:ni("vulpine")?F("race_chocolate_rabbit_solar_red"):F("race_vulpine_solar_red"),hell:ni("vulpine")?F("race_chocolate_rabbit_solar_hell"):F("race_vulpine_solar_hell"),gas:ni("vulpine")?F("race_chocolate_rabbit_solar_gas"):F("race_vulpine_solar_gas"),gas_moon:ni("vulpine")?F("race_chocolate_rabbit_solar_gas_moon"):F("race_vulpine_solar_gas_moon"),dwarf:ni("vulpine")?F("race_chocolate_rabbit_solar_dwarf"):F("race_vulpine_solar_dwarf")},fanaticism:"playful",basic:()=>!0},centaur:{name:F(ni("centaur")?"race_reindeer":"race_centaur"),desc:F(ni("centaur")?"race_reindeer_desc":"race_centaur_desc"),type:"herbivore",home:F(ni("centaur")?"race_reindeer_home":"race_centaur_home"),entity:F(ni("centaur")?"race_reindeer_entity":"race_centaur_entity"),traits:{sniper:1,hooved:1},solar:{red:F(ni("centaur")?"race_reindeer_solar_red":"race_centaur_solar_red"),hell:F(ni("centaur")?"race_reindeer_solar_hell":"race_centaur_solar_hell"),gas:F(ni("centaur")?"race_reindeer_solar_gas":"race_centaur_solar_gas"),gas_moon:F(ni("centaur")?"race_reindeer_solar_gas_moon":"race_centaur_solar_gas_moon"),dwarf:F(ni("centaur")?"race_reindeer_solar_dwarf":"race_centaur_solar_dwarf")},fanaticism:"sniper",basic:()=>!0},rhinotaur:{name:F("race_rhinotaur"),desc:F("race_rhinotaur_desc"),type:"herbivore",home:F("race_rhinotaur_home"),entity:F("race_rhinotaur_entity"),traits:{rage:1,heavy:1},solar:{red:F("race_rhinotaur_solar_red"),hell:F("race_rhinotaur_solar_hell"),gas:F("race_rhinotaur_solar_gas"),gas_moon:F("race_rhinotaur_solar_gas_moon"),dwarf:F("race_rhinotaur_solar_dwarf")},fanaticism:"rage",basic:()=>!0},capybara:{name:F(ni("capybara")?"race_donkey":"race_capybara"),desc:F(ni("capybara")?"race_donkey_desc":"race_capybara_desc"),type:"herbivore",home:F(ni("capybara")?"race_donkey_home":"race_capybara_home"),entity:F(ni("capybara")?"race_donkey_entity":"race_capybara_entity"),traits:{gnawer:1,calm:1},solar:{red:F(ni("capybara")?"race_donkey_solar_red":"race_capybara_solar_red"),hell:F(ni("capybara")?"race_donkey_solar_hell":"race_capybara_solar_hell"),gas:F(ni("capybara")?"race_donkey_solar_gas":"race_capybara_solar_gas"),gas_moon:F(ni("capybara")?"race_donkey_solar_gas_moon":"race_capybara_solar_gas_moon"),dwarf:F(ni("capybara")?"race_donkey_solar_dwarf":"race_capybara_solar_dwarf")},fanaticism:"calm",basic:()=>!0},kobold:{name:F("race_kobold"),desc:F("race_kobold_desc"),type:"small",home:F("race_kobold_home"),entity:F("race_kobold_entity"),traits:{pack_rat:1,paranoid:1},solar:{red:F("race_kobold_solar_red"),hell:F("race_kobold_solar_hell"),gas:F("race_kobold_solar_gas"),gas_moon:F("race_kobold_solar_gas_moon"),dwarf:F("race_kobold_solar_dwarf")},fanaticism:"pack_rat",basic:()=>!0},goblin:{name:F("race_goblin"),desc:F("race_goblin_desc"),type:"small",home:F("race_goblin_home"),entity:F("race_goblin_entity"),traits:{greedy:1,merchant:1},solar:{red:F("race_goblin_solar_red"),hell:F("race_goblin_solar_hell"),gas:F("race_goblin_solar_gas"),gas_moon:F("race_goblin_solar_gas_moon"),dwarf:F("race_goblin_solar_dwarf")},fanaticism:"merchant",basic:()=>!0},gnome:{name:F("race_gnome"),desc:F("race_gnome_desc"),type:"small",home:F("race_gnome_home"),entity:F("race_gnome_entity"),traits:{smart:1,puny:1},solar:{red:F("race_gnome_solar_red"),hell:F("race_gnome_solar_hell"),gas:F("race_gnome_solar_gas"),gas_moon:F("race_gnome_solar_gas_moon"),dwarf:F("race_gnome_solar_dwarf")},fanaticism:"smart",basic:()=>!0},ogre:{name:F("race_ogre"),desc:F("race_ogre_desc"),type:"giant",home:F("race_ogre_home"),entity:F("race_ogre_entity"),traits:{dumb:1,tough:1},solar:{red:F("race_ogre_solar_red"),hell:F("race_ogre_solar_hell"),gas:F("race_ogre_solar_gas"),gas_moon:F("race_ogre_solar_gas_moon"),dwarf:F("race_ogre_solar_dwarf")},fanaticism:"tough",basic:()=>!0},cyclops:{name:F("race_cyclops"),desc:F("race_cyclops_desc"),type:"giant",home:F("race_cyclops_home"),entity:F("race_cyclops_entity"),traits:{nearsighted:1,intelligent:1},solar:{red:F("race_cyclops_solar_red"),hell:F("race_cyclops_solar_hell"),gas:F("race_cyclops_solar_gas"),gas_moon:F("race_cyclops_solar_gas_moon"),dwarf:F("race_cyclops_solar_dwarf")},fanaticism:"intelligent",basic:()=>!0},troll:{name:F("race_troll"),desc:F("race_troll_desc"),type:"giant",home:F("race_troll_home"),entity:F("race_troll_entity"),traits:{regenerative:1,gluttony:1},solar:{red:F("race_troll_solar_red"),hell:F("race_troll_solar_hell"),gas:F("race_troll_solar_gas"),gas_moon:F("race_troll_solar_gas_moon"),dwarf:F("race_troll_solar_dwarf")},fanaticism:"regenerative",basic:()=>!0},tortoisan:{name:F("race_tortoisan"),desc:()=>F("race_tortoisan_desc",[t.race.hasOwnProperty("shell_color")?F(`color_${t.race.shell_color}`):F("color_green")]),type:"reptilian",home:F("race_tortoisan_home"),entity:F("race_tortoisan_entity"),traits:{slow:1,armored:1},solar:{red:F("race_tortoisan_solar_red"),hell:F("race_tortoisan_solar_hell"),gas:F("race_tortoisan_solar_gas"),gas_moon:F("race_tortoisan_solar_gas_moon"),dwarf:F("race_tortoisan_solar_dwarf")},fanaticism:"armored",basic:()=>!0},gecko:{name:F("race_gecko"),desc:F("race_gecko_desc"),type:"reptilian",home:F("race_gecko_home"),entity:F("race_gecko_entity"),traits:{optimistic:1,chameleon:1},solar:{red:F("race_gecko_solar_red"),hell:F("race_gecko_solar_hell"),gas:F("race_gecko_solar_gas"),gas_moon:F("race_gecko_solar_gas_moon"),dwarf:F("race_gecko_solar_dwarf")},fanaticism:"optimistic",basic:()=>!0},slitheryn:{name:F("race_slitheryn"),desc:F("race_slitheryn_desc"),type:"reptilian",home:F("race_slitheryn_home"),entity:F("race_slitheryn_entity"),traits:{slow_digestion:1,hard_of_hearing:1},solar:{red:F("race_slitheryn_solar_red"),hell:F("race_slitheryn_solar_hell"),gas:F("race_slitheryn_solar_gas"),gas_moon:F("race_slitheryn_solar_gas_moon"),dwarf:F("race_slitheryn_solar_dwarf")},fanaticism:"slow_digestion",basic:()=>!0},arraak:{name:F(ni("arraak")?"race_turkey":"race_arraak"),desc:F(ni("arraak")?"race_turkey_desc":"race_arraak_desc"),type:"avian",home:F(ni("arraak")?"race_turkey_home":"race_arraak_home"),entity:F("race_arraak_entity"),traits:{resourceful:1,selenophobia:1},solar:{red:F(ni("arraak")?"race_turkey_solar_red":"race_arraak_solar_red"),hell:F(ni("arraak")?"race_turkey_solar_hell":"race_arraak_solar_hell"),gas:F(ni("arraak")?"race_turkey_solar_gas":"race_arraak_solar_gas"),gas_moon:F(ni("arraak")?"race_turkey_solar_gas_moon":"race_arraak_solar_gas_moon"),dwarf:F(ni("arraak")?"race_turkey_solar_dwarf":"race_arraak_solar_dwarf")},fanaticism:"resourceful",basic:()=>!0},pterodacti:{name:F("race_pterodacti"),desc:F("race_pterodacti_desc"),type:"avian",home:F("race_pterodacti_home"),entity:F("race_pterodacti_entity"),traits:{leathery:1,pessimistic:1},solar:{red:F("race_pterodacti_solar_red"),hell:F("race_pterodacti_solar_hell"),gas:F("race_pterodacti_solar_gas"),gas_moon:F("race_pterodacti_solar_gas_moon"),dwarf:F("race_pterodacti_solar_dwarf")},fanaticism:"leathery",basic:()=>!0},dracnid:{name:F("race_dracnid"),desc:F("race_dracnid_desc"),type:"avian",home:F("race_dracnid_home"),entity:F("race_dracnid_entity"),traits:{hoarder:1,solitary:1},solar:{red:F("race_dracnid_solar_red"),hell:F("race_dracnid_solar_hell"),gas:F("race_dracnid_solar_gas"),gas_moon:F("race_dracnid_solar_gas_moon"),dwarf:F("race_dracnid_solar_dwarf")},fanaticism:"hoarder",basic:()=>!0},entish:{name:F(ni("entish")?"race_spruce":"race_entish"),desc:F(ni("entish")?"race_spruce_desc":"race_entish_desc"),type:"plant",home:F(ni("entish")?"race_spruce_home":"race_entish_home"),entity:F(ni("entish")?"race_spruce_entity":"race_entish_entity"),traits:{kindling_kindred:1,pyrophobia:1},solar:{red:F(ni("entish")?"race_spruce_solar_red":"race_entish_solar_red"),hell:F(ni("entish")?"race_spruce_solar_hell":"race_entish_solar_hell"),gas:F(ni("entish")?"race_spruce_solar_gas":"race_entish_solar_gas"),gas_moon:F(ni("entish")?"race_spruce_solar_gas_moon":"race_entish_solar_gas_moon"),dwarf:F(ni("entish")?"race_spruce_solar_dwarf":"race_entish_solar_dwarf")},fanaticism:"kindling_kindred",basic:()=>!0},cacti:{name:F("race_cacti"),desc:F("race_cacti_desc"),type:"plant",home:F("race_cacti_home"),entity:F("race_cacti_entity"),traits:{hyper:1,skittish:1},solar:{red:F("race_cacti_solar_red"),hell:F("race_cacti_solar_hell"),gas:F("race_cacti_solar_gas"),gas_moon:F("race_cacti_solar_gas_moon"),dwarf:F("race_cacti_solar_dwarf")},fanaticism:"hyper",basic:()=>!0},pinguicula:{name:F("race_pinguicula"),desc:F("race_pinguicula_desc"),type:"plant",home:F("race_pinguicula_home"),entity:F("race_pinguicula_entity"),traits:{fragrant:1,sticky:1},solar:{red:F("race_pinguicula_solar_red"),hell:F("race_pinguicula_solar_hell"),gas:F("race_pinguicula_solar_gas"),gas_moon:F("race_pinguicula_solar_gas_moon"),dwarf:F("race_pinguicula_solar_dwarf")},fanaticism:"sticky",basic:()=>!0},sporgar:{name:F("race_sporgar"),desc:F("race_sporgar_desc"),type:"fungi",home:F("race_sporgar_home"),entity:F("race_sporgar_entity"),traits:{infectious:1,parasite:1},solar:{red:F("race_sporgar_solar_red"),hell:F("race_sporgar_solar_hell"),gas:F("race_sporgar_solar_gas"),gas_moon:F("race_sporgar_solar_gas_moon"),dwarf:F("race_sporgar_solar_dwarf")},fanaticism:"infectious",basic:()=>!1},shroomi:{name:F("race_shroomi"),desc:F("race_shroomi_desc"),type:"fungi",home:F("race_shroomi_home"),entity:F("race_shroomi_entity"),traits:{toxic:1,nyctophilia:1},solar:{red:F("race_shroomi_solar_red"),hell:F("race_shroomi_solar_hell"),gas:F("race_shroomi_solar_gas"),gas_moon:F("race_shroomi_solar_gas_moon"),dwarf:F("race_shroomi_solar_dwarf")},fanaticism:"toxic",basic:()=>!0},moldling:{name:F("race_moldling"),desc:F("race_moldling_desc"),type:"fungi",home:F("race_moldling_home"),entity:F("race_moldling_entity"),traits:{infiltrator:1,hibernator:1},solar:{red:F("race_moldling_solar_red"),hell:F("race_moldling_solar_hell"),gas:F("race_moldling_solar_gas"),gas_moon:F("race_moldling_solar_gas_moon"),dwarf:F("race_moldling_solar_dwarf")},fanaticism:"infiltrator",basic:()=>!0},mantis:{name:F("race_mantis"),desc:F("race_mantis_desc"),type:"insectoid",home:F("race_mantis_home"),entity:F("race_mantis_entity"),traits:{cannibalize:1,malnutrition:1},solar:{red:F("race_mantis_solar_red"),hell:F("race_mantis_solar_hell"),gas:F("race_mantis_solar_gas"),gas_moon:F("race_mantis_solar_gas_moon"),dwarf:F("race_mantis_solar_dwarf")},fanaticism:"cannibalize",basic:()=>!0},scorpid:{name:F("race_scorpid"),desc:F("race_scorpid_desc"),type:"insectoid",home:F("race_scorpid_home"),entity:F("race_scorpid_entity"),traits:{claws:1,atrophy:1},solar:{red:F("race_scorpid_solar_red"),hell:F("race_scorpid_solar_hell"),gas:F("race_scorpid_solar_gas"),gas_moon:F("race_scorpid_solar_gas_moon"),dwarf:F("race_scorpid_solar_dwarf")},fanaticism:"claws",basic:()=>!0},antid:{name:F("race_antid"),desc:F("race_antid_desc"),type:"insectoid",home:F("race_antid_home"),entity:F("race_antid_entity"),traits:{hivemind:1,tunneler:1},solar:{red:F("race_antid_solar_red"),hell:F("race_antid_solar_hell"),gas:F("race_antid_solar_gas"),gas_moon:F("race_antid_solar_gas_moon"),dwarf:F("race_antid_solar_dwarf")},fanaticism:"hivemind",basic:()=>!0},sharkin:{name:F("race_sharkin"),desc:F("race_sharkin_desc"),type:"aquatic",home:F("race_sharkin_home"),entity:F("race_sharkin_entity"),traits:{blood_thirst:1,apex_predator:1},solar:{red:F("race_sharkin_solar_red"),hell:F("race_sharkin_solar_hell"),gas:F("race_sharkin_solar_gas"),gas_moon:F("race_sharkin_solar_gas_moon"),dwarf:F("race_sharkin_solar_dwarf")},fanaticism:"blood_thirst",basic:()=>!!["oceanic","swamp"].includes(t.city.biome)},octigoran:{name:F("race_octigoran"),desc:F("race_octigoran_desc"),type:"aquatic",home:F("race_octigoran_home"),entity:F("race_octigoran_entity"),traits:{invertebrate:1,suction_grip:1},solar:{red:F("race_octigoran_solar_red"),hell:F("race_octigoran_solar_hell"),gas:F("race_octigoran_solar_gas"),gas_moon:F("race_octigoran_solar_gas_moon"),dwarf:F("race_octigoran_solar_dwarf")},fanaticism:"suction_grip",basic:()=>!!["oceanic","swamp"].includes(t.city.biome)},dryad:{name:F("race_dryad"),desc:F("race_dryad_desc"),type:"fey",home:F("race_dryad_home"),entity:F("race_dryad_entity"),traits:{befuddle:1,environmentalist:1,kindling_kindred:1},solar:{red:F("race_dryad_solar_red"),hell:F("race_dryad_solar_hell"),gas:F("race_dryad_solar_gas"),gas_moon:F("race_dryad_solar_gas_moon"),dwarf:F("race_dryad_solar_dwarf")},fanaticism:"befuddle",basic:()=>!!["forest","swamp","taiga"].includes(t.city.biome)},satyr:{name:F("race_satyr"),desc:F("race_satyr_desc"),type:"fey",home:F("race_satyr_home"),entity:F("race_satyr_entity"),traits:{unorganized:1,musical:1},solar:{red:F("race_satyr_solar_red"),hell:F("race_satyr_solar_hell"),gas:F("race_satyr_solar_gas"),gas_moon:F("race_satyr_solar_gas_moon"),dwarf:F("race_satyr_solar_dwarf")},fanaticism:"musical",basic:()=>!!["forest","swamp","taiga"].includes(t.city.biome)},phoenix:{name:F("race_phoenix"),desc:F("race_phoenix_desc"),type:"heat",home:F("race_phoenix_home"),entity:F("race_phoenix_entity"),traits:{revive:1,slow_regen:1},solar:{red:F("race_phoenix_solar_red"),hell:F("race_phoenix_solar_hell"),gas:F("race_phoenix_solar_gas"),gas_moon:F("race_phoenix_solar_gas_moon"),dwarf:F("race_phoenix_solar_dwarf")},fanaticism:"revive",basic:()=>!!["volcanic","ashland"].includes(t.city.biome)},salamander:{name:F("race_salamander"),desc:F("race_salamander_desc"),type:"heat",home:F("race_salamander_home"),entity:F("race_salamander_entity"),traits:{forge:1,autoignition:1},solar:{red:F("race_salamander_solar_red"),hell:F("race_salamander_solar_hell"),gas:F("race_salamander_solar_gas"),gas_moon:F("race_salamander_solar_gas_moon"),dwarf:F("race_salamander_solar_dwarf")},fanaticism:"forge",basic:()=>!!["volcanic","ashland"].includes(t.city.biome)},yeti:{name:F(ni("yeti")?"race_snowman":"race_yeti"),desc:F(ni("yeti")?"race_snowman_desc":"race_yeti_desc"),type:"polar",home:F(ni("yeti")?"race_snowman_home":"race_yeti_home"),entity:F(ni("yeti")?"race_snowman_entity":"race_yeti_entity"),traits:{blurry:1,snowy:1},solar:{red:F(ni("yeti")?"race_snowman_solar_red":"race_yeti_solar_red"),hell:F(ni("yeti")?"race_snowman_solar_hell":"race_yeti_solar_hell"),gas:F(ni("yeti")?"race_snowman_solar_gas":"race_yeti_solar_gas"),gas_moon:F(ni("yeti")?"race_snowman_solar_gas_moon":"race_yeti_solar_gas_moon"),dwarf:F(ni("yeti")?"race_snowman_solar_dwarf":"race_yeti_solar_dwarf")},fanaticism:"blurry",basic:()=>!!["tundra","taiga"].includes(t.city.biome)},wendigo:{name:F(ni("wendigo")?"race_krampus":"race_wendigo"),desc:F(ni("wendigo")?"race_krampus_desc":"race_wendigo_desc"),type:"polar",home:F(ni("wendigo")?"race_krampus_home":"race_wendigo_home"),entity:F(ni("wendigo")?"race_krampus_entity":"race_wendigo_entity"),traits:{ravenous:1,ghostly:1,soul_eater:1},solar:{red:F(ni("wendigo")?"race_krampus_solar_red":"race_wendigo_solar_red"),hell:F(ni("wendigo")?"race_krampus_solar_hell":"race_wendigo_solar_hell"),gas:F(ni("wendigo")?"race_krampus_solar_gas":"race_wendigo_solar_gas"),gas_moon:F(ni("wendigo")?"race_krampus_solar_gas_moon":"race_wendigo_solar_gas_moon"),dwarf:F(ni("wendigo")?"race_krampus_solar_dwarf":"race_wendigo_solar_dwarf")},fanaticism:"ghostly",basic:()=>!!["tundra","taiga"].includes(t.city.biome)},tuskin:{name:F("race_tuskin"),desc:F("race_tuskin_desc"),type:"sand",home:F("race_tuskin_home"),entity:F("race_tuskin_entity"),traits:{lawless:1,mistrustful:1},solar:{red:F("race_tuskin_solar_red"),hell:F("race_tuskin_solar_hell"),gas:F("race_tuskin_solar_gas"),gas_moon:F("race_tuskin_solar_gas_moon"),dwarf:F("race_tuskin_solar_dwarf")},fanaticism:"lawless",basic:()=>!!["desert","ashland"].includes(t.city.biome)},kamel:{name:F("race_kamel"),desc:F("race_kamel_desc"),type:"sand",home:F("race_kamel_home"),entity:F("race_kamel_entity"),traits:{humpback:1,thalassophobia:1},solar:{red:F("race_kamel_solar_red"),hell:F("race_kamel_solar_hell"),gas:F("race_kamel_solar_gas"),gas_moon:F("race_kamel_solar_gas_moon"),dwarf:F("race_kamel_solar_dwarf")},fanaticism:"humpback",basic:()=>!!["desert","ashland"].includes(t.city.biome)},balorg:{name:F("race_balorg"),desc:F("race_balorg_desc"),type:"demonic",home:F("race_balorg_home"),entity:F("race_balorg_entity"),traits:{fiery:1,terrifying:1,slaver:1},solar:{red:F("race_balorg_solar_red"),hell:F("race_balorg_solar_hell"),gas:F("race_balorg_solar_gas"),gas_moon:F("race_balorg_solar_gas_moon"),dwarf:F("race_balorg_solar_dwarf")},fanaticism:"fiery",basic:()=>"hellscape"===t.city.biome},imp:{name:F("race_imp"),desc:F("race_imp_desc"),type:"demonic",home:F("race_imp_home"),entity:F("race_imp_entity"),traits:{compact:1,conniving:1,pathetic:1},solar:{red:F("race_imp_solar_red"),hell:F("race_imp_solar_hell"),gas:F("race_imp_solar_gas"),gas_moon:F("race_imp_solar_gas_moon"),dwarf:F("race_imp_solar_dwarf")},fanaticism:"conniving",basic:()=>"hellscape"===t.city.biome},seraph:{name:F(ni("seraph")?"race_cherub":"race_seraph"),desc:F(ni("seraph")?"race_cherub_desc":"race_seraph_desc"),type:"angelic",home:F(ni("seraph")?"race_cherub_home":"race_seraph_home"),entity:F(ni("seraph")?"race_cherub_entity":"race_seraph_entity"),traits:{unified:1,spiritual:1,truthful:1},solar:{red:F(ni("seraph")?"race_cherub_solar_red":"race_seraph_solar_red"),hell:F(ni("seraph")?"race_cherub_solar_hell":"race_seraph_solar_hell"),gas:F(ni("seraph")?"race_cherub_solar_gas":"race_seraph_solar_gas"),gas_moon:F(ni("seraph")?"race_cherub_solar_gas_moon":"race_seraph_solar_gas_moon"),dwarf:F(ni("seraph")?"race_cherub_solar_dwarf":"race_seraph_solar_dwarf")},fanaticism:"spiritual",basic:()=>"eden"===t.city.biome},unicorn:{name:F("race_unicorn"),desc:F("race_unicorn_desc"),type:"angelic",home:F("race_unicorn_home"),entity:F("race_unicorn_entity"),traits:{rainbow:1,magnificent:1,noble:1},solar:{red:F("race_unicorn_solar_red"),hell:F("race_unicorn_solar_hell"),gas:F("race_unicorn_solar_gas"),gas_moon:F("race_unicorn_solar_gas_moon"),dwarf:F("race_unicorn_solar_dwarf")},fanaticism:"magnificent",basic:()=>"eden"===t.city.biome},synth:{name:F("race_synth"),desc(){let e=t.race.hasOwnProperty("srace")?t.race.srace:"human";return F("race_synth_desc",[di[e].name])},type:"synthetic",home:F("race_synth_home"),entity:F("race_synth_entity"),traits:{imitation:1,emotionless:1,logical:1},solar:{red:F("race_synth_solar_red"),hell:F("race_synth_solar_hell"),gas:F("race_synth_solar_gas"),gas_moon:F("race_synth_solar_gas_moon"),dwarf:F("race_synth_solar_dwarf")},fanaticism:"logical",basic:()=>!1},nano:{name:F("race_nano"),desc:F("race_nano_desc"),type:"synthetic",home:F("race_nano_home"),entity:F("race_nano_entity"),traits:{deconstructor:1,linked:1,shapeshifter:1},solar:{red:F("race_nano_solar_red"),hell:F("race_nano_solar_hell"),gas:F("race_nano_solar_gas"),gas_moon:F("race_nano_solar_gas_moon"),dwarf:F("race_nano_solar_dwarf")},fanaticism:"shapeshifter",basic:()=>!1},ghast:{name:F("race_ghast"),desc:F("race_ghast_desc"),type:"eldritch",home:F("race_ghast_home"),entity:F("race_ghast_entity"),traits:{dark_dweller:1,swift:1,anthropophagite:1},solar:{red:F("race_ghast_solar_red"),hell:F("race_ghast_solar_hell"),gas:F("race_ghast_solar_gas"),gas_moon:F("race_ghast_solar_gas_moon"),dwarf:F("race_ghast_solar_dwarf")},fanaticism:"swift",basic:()=>!1},shoggoth:{name:F("race_shoggoth"),desc:F("race_shoggoth_desc"),type:"eldritch",home:F("race_shoggoth_home"),entity:F("race_shoggoth_entity"),traits:{living_tool:1,bloated:1},solar:{red:F("race_shoggoth_solar_red"),hell:F("race_shoggoth_solar_hell"),gas:F("race_shoggoth_solar_gas"),gas_moon:F("race_shoggoth_solar_gas_moon"),dwarf:F("race_shoggoth_solar_dwarf")},fanaticism:"living_tool",basic:()=>!1},junker:{name:ni("junker")?F("race_ghoul"):F("race_junker"),desc:ni("junker")?F("race_ghoul_desc"):F("race_junker_desc"),type:t.race.hasOwnProperty("jtype")?t.race.jtype:"humanoid",home:ni("junker")?F("race_ghoul_home"):F("race_junker_home"),entity:ni("junker")?F("race_ghoul_entity"):F("race_junker_entity"),traits:{diverse:1,arrogant:1,angry:1,lazy:1,paranoid:1,greedy:1,puny:1,dumb:1,nearsighted:1,gluttony:1,slow:1,hard_of_hearing:1,pessimistic:1,solitary:1,pyrophobia:1,skittish:1,nyctophilia:1,frail:1,atrophy:1,invertebrate:1,pathetic:1,hibernator:1,freespirit:1,heavy:1,gnawer:1,hooved:1},solar:{red:ni("junker")?F("race_ghoul_solar_red"):F("race_junker_solar_red"),hell:ni("junker")?F("race_ghoul_solar_hell"):F("race_junker_solar_hell"),gas:ni("junker")?F("race_ghoul_solar_gas"):F("race_junker_solar_gas"),gas_moon:ni("junker")?F("race_ghoul_solar_gas_moon"):F("race_junker_solar_gas_moon"),dwarf:ni("junker")?F("race_ghoul_solar_dwarf"):F("race_junker_solar_dwarf")},fanaticism:"none",basic:()=>!1},sludge:{name:F("race_sludge"),desc:F("race_sludge_desc"),type:t.race.hasOwnProperty("jtype")?t.race.jtype:"humanoid",home:F("race_sludge_home"),entity:F("race_sludge_entity"),traits:{ooze:.25,diverse:.25,arrogant:.25,angry:.25,lazy:.25,hooved:.25,freespirit:.25,heavy:.25,gnawer:.25,paranoid:.25,greedy:.25,puny:.25,dumb:.25,nearsighted:.25,gluttony:.25,slow:.25,hard_of_hearing:.25,selenophobia:.25,pessimistic:.25,solitary:.25,pyrophobia:.25,skittish:.25,fragrant:.25,nyctophilia:.25,hibernator:.25,frail:.25,atrophy:.25,invertebrate:.25,unorganized:.25,slow_regen:.25,autoignition:.25,snowy:.25,mistrustful:.25,thalassophobia:.25,pathetic:.25,truthful:.25},solar:{red:F("race_sludge_solar_red"),hell:F("race_sludge_solar_hell"),gas:F("race_sludge_solar_gas"),gas_moon:F("race_sludge_solar_gas_moon"),dwarf:F("race_sludge_solar_dwarf")},fanaticism:"ooze",basic:()=>!1},custom:function(){if(t.hasOwnProperty("custom")&&t.custom.hasOwnProperty("race0")){let e={};for(let a=0;aui[a].val&&(a=t.custom.race0.traits[e]);return{name:t.custom.race0.name,desc:t.custom.race0.desc,type:t.custom.race0.genus,home:t.custom.race0.home,entity:t.custom.race0.entity,traits:e,solar:{red:t.custom.race0.red,hell:t.custom.race0.hell,gas:t.custom.race0.gas,gas_moon:t.custom.race0.gas_moon,dwarf:t.custom.race0.dwarf},fanaticism:a,basic:()=>!1}}return{}}()},_i={organism:{},humanoid:{},carnivore:{},herbivore:{},omnivore:{},small:{},giant:{},reptilian:{},avian:{},insectoid:{},plant:{},fungi:{},aquatic:{},fey:{},heat:{},polar:{},sand:{},demonic:{},angelic:{},synthetic:{},eldritch:{}};function pi(e,a){let r=1,s=N("theorist",1);!s||"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1-s/100);let i=N("inspirational",0);!i||"farmer"!==a&&"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1+i/100);let c=N("dirty_jobs",2);if(c&&"miner"===a&&(r*=1+c/100),t.race.rejuvenated&&["lumberjack","miner","factory"].includes(a)&&(r*=1.1),"lumberjack"===a&&t.race.evil&&!t.race.soul_eater&&(t.race.living_tool?r*=1+ui.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.3*t.tech.science:0):r*=1+.4*(t.tech.reclaimer-1)),!t.race.powered||"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1+ui.powered.vars()[1]/100),t.race.artifical&&"science"===a&&(r*=1+ui.artifical.vars()[0]/100),t.race.hivemind&&"farmer"!==a&&!t.race.lone_survivor){let s=ui.hivemind.vars()[0],i=.05;t.race.high_pop&&"army"!==a&&"hellArmy"!==a&&(s*=ui.high_pop.vars()[0],i=.5/(ui.hivemind.vars()[0]*ui.high_pop.vars()[0])),r*=e<=s?e*i+(1-s*i):1-("army"===a||"hellArmy"===a?.99:t.race.high_pop?.985:.98)**(e-s)+1}let o=Pi("antid");if(o>0&&(r*=1+(1-("army"===a||"hellArmy"===a?.99:t.race.high_pop?.985:.98)**(e*o/4))/2),t.race.cold_blooded&&"army"!==a&&"hellArmy"!==a&&"factory"!==a&&"science"!==a){switch(t.city.calendar.temp){case 0:r*=1-ui.cold_blooded.vars()[0]/100;break;case 2:r*=1+ui.cold_blooded.vars()[1]/100;break;default:r*=1}switch(t.city.calendar.weather){case 0:r*=1-ui.cold_blooded.vars()[0]/100;break;case 2:r*=1+ui.cold_blooded.vars()[1]/100;break;default:r*=1}}t.race.cannibalize&&t.city.s_alter&&t.city.s_alter.count>0&&("miner"===a&&t.city.s_alter.mine>0&&(r*=1+ui.cannibalize.vars()[0]/100),"lumberjack"===a&&t.city.s_alter.harvest>0&&(r*=1+ui.cannibalize.vars()[0]/100),("army"===a||"hellArmy"===a)&&t.city.s_alter.rage>0&&(r*=1+ui.cannibalize.vars()[0]/100),"science"===a&&t.city.s_alter.mind>0&&(r*=1+ui.cannibalize.vars()[0]/100));let n=Pi("mantis");n>0&&("miner"===a&&(r*=1+ui.cannibalize.vars(1)[0]/100*n),"lumberjack"===a&&(r*=1+ui.cannibalize.vars(1)[0]/100*n),"army"!==a&&"hellArmy"!==a||(r*=1+ui.cannibalize.vars(1)[0]/100*n),"science"===a&&(r*=1+ui.cannibalize.vars(1)[0]/100*n)),!t.race.humpback||"miner"!==a&&"lumberjack"!==a||(r*=1+ui.humpback.vars()[0]/100);let l=Pi("kamel");l>0&&("miner"===a||"lumberjack"===a)&&(r*=1+ui.humpback.vars(1)[0]/100*l),t.city.ptrait.includes("magnetic")&&"miner"===a&&(r*=Si.magnetic.vars()[2]),!t.race.weak||"miner"!==a&&"lumberjack"!==a||(r*=1-ui.weak.vars()[0]/100),t.race.hydrophilic&&0===t.city.calendar.weather&&t.city.calendar.temp>0&&"factory"!==a&&(r*=.75),t.race.toxic&&"factory"===a&&(r*=1+ui.toxic.vars()[2]/100);let u=Pi("shroomi");if(u>0&&"factory"===a&&(r*=1+ui.toxic.vars(1)[2]/100*u),t.race.hardy&&"factory"===a&&(r*=1+ui.hardy.vars()[0]*t.race.hardy/100),t.race.analytical&&"science"===a&&(r*=1+ui.analytical.vars()[0]*t.race.analytical/100),t.race.ooze&&(r*=1-ui.ooze.vars()[0]/100),"democracy"===t.civic.govern.type&&(r*=1-ae.democracy()[1]/100),!t.tech.cyber_worker||"lumberjack"!==a&&"miner"!==a||(r*=1.25),"hunting"===a){t.race.tracker&&(r*=1+ui.tracker.vars()[0]/100);let e=Pi("wolven");e>0&&(r*=1+ui.tracker.vars(1)[0]/100*e),t.race.beast&&(r*=1+(1===t.city.calendar.wind?ui.beast.vars()[1]:ui.beast.vars()[0])/100),t.race.apex_predator&&(r*=1+ui.apex_predator.vars()[1]/100);let a=Pi("sharkin");a>0&&(r*=1+ui.apex_predator.vars(1)[1]/100*a),t.race.fiery&&(r*=1+ui.fiery.vars()[1]/100);let s=Pi("balorg");s>0&&(r*=1+ui.fiery.vars(1)[1]/100*s),t.race.fragrant&&(r*=1-ui.fragrant.vars()[0]/100),t.city.ptrait.includes("rage")&&(r*=Si.rage.vars()[1]),t.race.cunning&&(r*=1+ui.cunning.vars()[0]*t.race.cunning/100),"savanna"===t.city.biome&&(r*=ji.savanna.vars()[1]),t.race.dark_dweller&&2===t.city.calendar.weather&&(r*=1-ui.dark_dweller.vars()[0]/100)}if("magic"===t.race.universe&&(r*="science"===a?.6:"army"===a||"hellArmy"===a?.75:.8,t.race.witch_hunter&&(r*=.75),t.race.hasOwnProperty("casting")&&t.race.casting["hellArmy"===a?"army":a])){let e=t.race.casting["hellArmy"===a?"army":a];t.race.witch_hunter?r*=1+e/(e+75)*2.5:r*=1+e/(e+75)}return t.race.living_tool&&"miner"===a&&(r*=1+ui.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.12*t.tech.science:0)),t.race.high_pop&&(r=Me(r)),r}function hi(e){let a=[];Object.keys(ui).forEach((function(e){"minor"!==ui[e].type||t.race[e]||a.push(e)})),0===a.length&&Object.keys(ui).forEach((function(e){"minor"===ui[e].type&&a.push(e)}));let r=a[Math.floor(m(0,a.length))];return t.race[r]?t.race[r]+=e:t.race[r]=e,r}function mi(e,a,r){t.race.purgatory[e].hasOwnProperty(a)?(t[e][a]=t.race.purgatory[e][a],delete t.race.purgatory[e][a]):r&&(t[e][a]=r)}function gi(e,a,r,s){t.race.purgatory[e].hasOwnProperty(a)?(t[e][a]=t.race.purgatory[e][a],delete t.race.purgatory[e][a]):t.race.purgatory[e].hasOwnProperty(r)?(t[e][a]=t.race.purgatory[e][r],delete t.race.purgatory[e][r]):s&&(t[e][a]=s)}function fi(e,a){t[e].hasOwnProperty(a)&&(t.race.purgatory[e][a]=t[e][a],delete t[e][a])}function vi(e,a){if(t.race.purgatory[e].hasOwnProperty(a))return t.race.purgatory[e][a]}function yi(){bi("Lumber"),bi("Plywood"),Bi(["city-graveyard","city-lumber_yard","city-sawmill"]),Gi(["reclaimer","axe","saw"]),fi("city","sawmill"),fi("city","graveyard"),fi("city","lumber_yard"),fi("tech","axe"),fi("tech","reclaimer"),fi("tech","saw"),t.civic.lumberjack.display=!1,t.civic.lumberjack.workers=0,"lumberjack"===t.civic.d_job&&(t.civic.d_job=t.race.carnivore||t.race.soul_eater?"hunter":"unemployed"),t.race.casting&&(t.race.casting.total-=t.race.casting.lumberjack,t.race.casting.lumberjack=0,Ws()),t.city.s_alter&&(t.city.s_alter.harvest=0)}function bi(e){t.resource[e].display=!1,t.race.alchemy&&t.race.alchemy.hasOwnProperty(e)&&(t.resource.Mana.diff+=t.race.alchemy[e],t.race.alchemy[e]=0),t.interstellar.mass_ejector&&t.interstellar.mass_ejector.hasOwnProperty(e)&&(t.interstellar.mass_ejector.total-=t.interstellar.mass_ejector[e],t.interstellar.mass_ejector[e]=0),t.city.nanite_factory&&t.city.nanite_factory.hasOwnProperty(e)&&(t.city.nanite_factory[e]=0),t.portal.transport&&t.portal.transport.cargo.hasOwnProperty(e)&&(t.portal.transport.cargo.used-=t.portal.transport.cargo[e],t.portal.transport.cargo[e]=0),t.tech.foundry&&t.city.foundry.hasOwnProperty(e)&&(t.civic.craftsman.workers-=t.city.foundry[e],t.city.foundry.crafting-=t.city.foundry[e],t.city.foundry[e]=0,ha()),t.resource[e].hasOwnProperty("trade")&&(t.city.market.trade-=Math.abs(t.resource[e].trade),t.resource[e].trade=0),t.resource.Crates.amount+=t.resource[e].crates,t.resource[e].crates=0,t.resource.Containers.amount+=t.resource[e].containers,t.resource[e].containers=0}function wi(){let e=ds(Qr.tech.agriculture),a=ds(Qr.tech.smokehouse),r=ds(Qr.tech.reclaimer)||ds(Qr.tech.stone_axe),i=ds(Qr.tech.alt_lodge),c=ds(Qr.tech.wind_plant),o=[],n=[];if(!t.race.artifical){if(["agriculture","farm","hunting","s_lodge","wind_plant","compost","soul_eater"].forEach((function(e){fi("tech",e)})),["silo","farm","mill","windmill","smokehouse","lodge","compost","soul_well"].forEach((function(e){fi("city",e)})),i){mi("tech","s_lodge");let e=vi("tech","farm")>=1||vi("tech","hunting")>=2?1:0;e>0&&(!t.tech.s_lodge||t.tech.s_lodge=1&&gi("city","lodge","farm",{count:0})}if(a){mi("tech","hunting");let e=vi("tech","farm")>=1||vi("tech","s_lodge")>=1?2:vi("tech","agriculture")>=3?1:0;e>0&&(!t.tech.hunting||t.tech.hunting=1&&gi("city","smokehouse","silo",{count:0}),t.tech.hunting>=2&&!i&&gi("city","lodge","farm",{count:0})}else n.push("hunting"),o.push("city-smokehouse"),i||n.push("city-lodge");if(e){mi("tech","farm");let e=vi("tech","hunting")>=2||vi("tech","s_lodge")>=1?1:0;e>0&&(!t.tech.farm||t.tech.farm=1?3:vi("tech","s_lodge")>=1?1:0;a>0&&(!t.tech.agriculture||t.tech.agriculture=1&&gi("city","farm","lodge",{count:0}),t.tech.agriculture>=3&&gi("city","silo","smokehouse",{count:0}),t.tech.agriculture>=4&&!c&&gi("city","mill","windmill",{count:0,on:0})}else n.push("agriculture","farm"),o.push("city-farm","city-silo","city-mill");t.race.soul_eater?(mi("tech","soul_eater"),mi("city","soul_well")):(o.push("city-soul_well"),n.push("soul_eater")),t.race.detritivore?(mi("tech","compost"),mi("city","compost")):(n.push("compost"),o.push("city-compost")),c?(mi("tech","wind_plant"),t.tech.wind_plant>=1&&gi("city","windmill","mill",{count:0,on:0})):(n.push("wind_plant"),o.push("city-windmill"),delete s[F("city_mill_title2")])}let l=[],u=[];!t.race.orbit_decayed&&e&&t.tech.agriculture>=1&&t.city.farm.count>0?l.push("farmer"):u.push("farmer"),t.race.carnivore&&!t.race.herbivore||t.race.soul_eater||t.race.unfathomable?(l.push("hunter"),u.push("unemployed")):(u.push("hunter"),l.push("unemployed")),!t.race.orbit_decayed&&r?l.push("lumberjack"):u.push("lumberjack"),l.forEach((function(e){t.civic[e].display||(t.civic[e].workers=0,t.civic[e].display=!0)})),u.forEach((function(e){t.civic[e].display&&(t.civic.d_job===e&&(t.civic.d_job=l[0]),t.civic[l[0]].workers+=t.civic[e].workers,t.civic[e].workers=0,t.civic[e].display=!1)})),t.race.casting&&(e||(t.race.casting.total-=t.race.casting.farmer,t.race.casting.farmer=0),Ws()),Bi(o),Gi(n),cr("Food")}function $i(a){switch(a){case"high_pop":t.resource[t.race.species].amount=Math.round(t.resource[t.race.species].amount*ui.high_pop.vars()[0]),t.civic.hasOwnProperty("garrison")&&(t.civic.garrison.workers=Math.round(t.civic.garrison.workers*ui.high_pop.vars()[0]));break;case"kindling_kindred":if(t.race.smoldering)break;yi();break;case"smoldering":if(t.resource.Chrysotile.display=!0,t.race.kindling_kindred)break;yi();break;case"forge":Ws();break;case"soul_eater":ua("lumberjack");case"detritivore":case"carnivore":case"herbivore":wi();break;case"unfathomable":for(wi(),t.city.hasOwnProperty("surfaceDwellers")||(t.city.surfaceDwellers=[]);t.city.surfaceDwellers.lengthui.unfathomable.vars()[0]&&(t.city.surfaceDwellers.length=ui.unfathomable.vars()[0]),t.race.psychic&&zi();break;case"flier":cr("Stone"),cr("Brick"),t.resource.Cement.display=!1,t.civic.cement_worker.display=!1,t.civic.cement_worker.workers=0,fi("tech","cement"),fi("city","cement_plant");break;case"sappy":"quarry_worker"===t.civic.d_job&&(t.civic.d_job="unemployed"),t.civic.quarry_worker.display=!1,t.civic.quarry_worker.workers=0,cr("Stone"),fi("tech","hammer"),fi("city","rock_quarry");break;case"apex_predator":Gi(["armor"]),fi("tech","armor");break;case"environmentalist":delete s[F("city_coal_power")],delete s[F("city_mana_engine")],delete s[F("city_oil_power")];break;case"terrifying":Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),t.settings.showMarket=!1,0===t.settings.marketTabs&&(t.settings.marketTabs=1),Bi(["city-trade"]),Gi(["trade"]),fi("tech","trade"),fi("city","trade");break;case"slaver":mi("tech","slaves"),t.tech.slaves>=1&&(mi("city","slave_pen",{count:0,slaves:0}),t.city.slave_pen.count>0&&!t.race.orbit_decayed&&(t.resource.Slave.display=!0));break;case"cannibalize":mi("tech","sacrifice"),t.tech.mining&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0});break;case"magnificent":t.tech.theology>=2&&mi("city","shrine",{count:0,morale:0,metal:0,know:0,tax:0});break;case"unified":t.tech.world_control=1,t.tech.unify=2,rc($("#garrison")),rc($("#c_garrison")),fe($("#garrison"),!0),fe($("#c_garrison"),!1);for(let e=0;e<3;e++){if(t.civic.foreign[`gov${e}`].occ){let a=la("federation"===t.civic.govern.type?15:20);t.civic.garrison.max+=a,t.civic.garrison.workers+=a,t.civic.foreign[`gov${e}`].occ=!1}t.civic.foreign[`gov${e}`].buy=!1,t.civic.foreign[`gov${e}`].anx=!1,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none"}D("spy"),D("spyop");break;case"noble":t.civic.taxes.tax_rate<10?t.civic.taxes.tax_rate=10:t.civic.taxes.tax_rate>20&&(t.civic.taxes.tax_rate=20);break;case"toxic":"troll"===t.race.species&&t.tech.science&&t.tech.science>=8&&Xc("godwin");break;case"thalassophobia":Bi(["city-wharf"]),Gi(["wharf"]),fi("city","wharf");break;case"hooved":t.resource.Horseshoe.display=!0,t.race.hasOwnProperty("shoecnt")||(t.race.shoecnt=0);break;case"slow":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w?(Ii("stop"),Ii("start")):window.location.reload();case"hyper":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w?(Ii("stop"),Ii("start")):window.location.reload();case"calm":t.tech.primitive>=3&&(mi("city","meditation",{count:0}),t.race.orbit_decayed||(t.resource.Zen.display=!0));break;case"blood_thirst":t.race.blood_thirst_count=1;break;case"deconstructor":t.resource.Nanite.display=!0,mi("city","nanite_factory",{count:1,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Bolognium:0,Orichalcum:0});break;case"shapeshifter":qi(!1,!0);break;case"imitation":ki(!0);break;case"evil":cr("Lumber"),cr("Furs"),cr("Plywood");break;case"psychic":t.tech.psychic&&(t.resource.Energy.display=!0,t.settings.showPsychic=!0);break;case"ooze":t.tech.high_tech||"custom"===t.race.species||"sludge"===t.race.species||(t.race.gross_enabled=1),lc(!0)}}function xi(a,r){switch(a){case"high_pop":t.resource[t.race.species].amount=Math.round(t.resource[t.race.species].amount/ui.high_pop.vars(r)[0]),t.civic.hasOwnProperty("garrison")&&(t.civic.garrison.workers=Math.round(t.civic.garrison.workers/ui.high_pop.vars(r)[0]));break;case"kindling_kindred":if(t.race.smoldering)break;t.resource.Lumber.display=!0,t.tech.foundry&&(t.resource.Plywood.display=!0),t.race.casting&&Ws(),mi("city","sawmill"),mi("city","graveyard"),mi("city","lumber_yard"),mi("tech","axe"),mi("tech","reclaimer"),mi("tech","saw"),!t.tech.axe&&!t.tech.reclaimer||t.race.orbit_decayed||(t.civic.lumberjack.display=!0);break;case"smoldering":if(bi("Chrysotile"),t.race.kindling_kindred)break;t.resource.Lumber.display=!0,t.tech.foundry&&(t.resource.Plywood.display=!0),t.race.casting&&Ws(),mi("city","sawmill"),mi("city","graveyard"),mi("city","lumber_yard"),mi("tech","axe"),mi("tech","reclaimer"),mi("tech","saw"),!t.tech.axe&&!t.tech.reclaimer||t.race.orbit_decayed||(t.civic.lumberjack.display=!0);break;case"forge":Ws();break;case"soul_eater":ua("lumberjack");case"detritivore":case"carnivore":case"herbivore":case"unfathomable":wi(),t.race.psychic&&zi();break;case"flier":cr("Stone"),cr("Brick"),mi("tech","cement"),t.tech.cement&&(mi("city","cement_plant"),t.resource.Cement.display=!0,t.civic.cement_worker.display=!0);break;case"sappy":cr("Stone"),mi("tech","hammer"),t.tech.mining>=1&&(mi("city","rock_quarry",{count:0,asbestos:0}),(t.city.rock_quarry&&t.city.rock_quarry.count>0||t.race.lone_survivor)&&(t.civic.quarry_worker.display=!0));break;case"apex_predator":mi("tech","armor");break;case"environmentalist":delete s[F("city_hydro_power")],delete s[F("city_wind_power")];break;case"terrifying":t.settings.showMarket=!0,mi("tech","trade"),mi("city","trade");break;case"slaver":Bi(["city-slave_pen"]),Gi(["slaves"]),fi("city","slave_pen"),fi("tech","slaves"),t.resource.Slave.amount=0,t.resource.Slave.max=0,t.resource.Slave.display=!1,D("slave");break;case"cannibalize":Bi(["city-s_alter"]),Gi(["sacrifice"]),fi("tech","sacrifice"),delete t.city.s_alter,D("sacrifice");break;case"magnificent":Bi(["city-shrine"]),fi("city","shrine");break;case"thalassophobia":t.tech.wharf&&mi("city","wharf",{count:0});break;case"hooved":Bi(["city-horseshoe","space-horseshoe"]),t.resource.Horseshoe.display=!1,D("horseshoe");break;case"slow":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w?(Ii("stop"),Ii("start")):window.location.reload();case"hyper":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w?(Ii("stop"),Ii("start")):window.location.reload();case"calm":Bi(["city-meditation"]),t.resource.Zen.display=!1,fi("city","meditation");break;case"blood_thirst":delete t.race.blood_thirst_count;break;case"deconstructor":Bi(["city-nanite_factory"]),t.resource.Nanite.display=!1,fi("city","nanite_factory");break;case"shapeshifter":rc($("#sshifter")),qi();break;case"imitation":t.race.iTraits&&(Object.keys(t.race.iTraits).forEach((function(e){if("imitation"!==e)if(0===t.race.iTraits[e]){let a=t.race[e];delete t.race[e],xi(e,a)}else t.race[e]=t.race.iTraits[e]})),delete t.race.iTraits);break;case"evil":cr("Lumber"),cr("Furs"),cr("Plywood");break;case"psychic":t.resource.Energy.display=!1,t.settings.showPsychic=!1;break;case"ooze":delete t.race.gross_enabled,lc(!0)}}function ki(e){if(t.race.imitation&&t.race.srace){t.race.iTraits||(t.race.iTraits={}),t.race.shapeshifter&&qi(t.race.ss_genus===di[t.race.srace].type&&"none",!0);let a=[];if(Object.keys(li[di[t.race.srace].type]).forEach((function(e){t.race[e]||a.push(e)})),"custom"===t.race.srace){let e=["evil","evil"];Object.keys(di[t.race.srace].traits).forEach((function(t){ui[t].val>ui[e[0]].val?e[0]=t:ui[t].val=0?t.race[e]=ui.shapeshifter.vars()[0]:t.race[e]=ui.shapeshifter.vars()[1],$i(e),r.push(e))})),t.race.ss_genus=e),a){rc($("#sshifter")),t.race.ss_genus=t.race.hasOwnProperty("ss_genus")?t.race.ss_genus:"none";let e="";Object.keys(li).forEach((function(a){"synthetic"!==a&&"eldritch"!==a&&a!==di[t.race.species].type&&(!t.race.imitation||a!==di[t.race.srace].type)&&t.stats.achieve[`genus_${a}`]&&t.stats.achieve[`genus_${a}`].l>0&&(e+=`{{ '${a}' | genus }}`)})),$("#sshifter").append(`${F("trait_shapeshifter_name")}: \n \n {{ 'none' | genus }}${e}\n `),sc({el:"#sshifter",data:t.race,methods:{setShape(e){qi(e)}},filters:{genus:e=>F(`genelab_genus_${e}`)}})}t.race.ss_traits=r}function Mi(e,a){if(a=a||{},t.race[e]&&!a.force)switch(t.race[e]){case.25:return t.race[e]=a.down?.25:.5,!a.down;case.5:return t.race[e]=a.down?.25:1,!0;case 1:return t.race[e]=a.down?.5:2,!0;case 2:return t.race[e]=a.down?1:3,!0;case 3:return t.race[e]=a.down?2:3,!!a.down}else if(a.set)return t.race[e]=a.set,!0;return!1}function Pi(e){if(t.race.unfathomable&&t.city.surfaceDwellers&&t.city.surfaceDwellers.includes(e)&&t.city.captive_housing){let a=t.city.surfaceDwellers.indexOf(e),r=t.city.captive_housing[`race${a}`];if(r>100&&(r=100),r>t.civic.torturer.workers){let e=r-t.civic.torturer.workers;r-=Math.ceil(e/3)}return r/100*((t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0)/5)}return 0}function Oi(e,a){switch(e){case"name":{let e={hooved:Ci(!1),promiscuous:t.race.artifical?F("trait_promiscuous_synth_name"):ui.promiscuous.name};return a?e[a]?e[a]:ui[a].name:e}case"desc":{let e={hooved:Ci(!0),promiscuous:t.race.artifical?F("trait_promiscuous_synth"):ui.promiscuous.desc};return a?e[a]?e[a]:ui[a].desc:e}}}function Ci(e){return t.race.sludge?F(e?"trait_hooved_slime":"trait_hooved_slime_name"):["cath","wolven","dracnid","seraph","cyclops","kobold","tuskin","sharkin"].includes(t.race.species)?F(e?`trait_hooved_${t.race.species}`:`trait_hooved_${t.race.species}_name`):["humanoid","avian","plant","fungi","reptilian","fey","synthetic"].includes(di[t.race.species].type)?F(e?`trait_hooved_${di[t.race.species].type}`:`trait_hooved_${di[t.race.species].type}_name`):e?ui.hooved.desc:ui.hooved.name}Object.keys(_i).forEach((function(e){let t="organism"===e?"humanoid":e;_i[e].solar={titan:F(`genus_${t}_solar_titan`),enceladus:F(`genus_${t}_solar_enceladus`),triton:F(`genus_${t}_solar_triton`),eris:F(`genus_${t}_solar_eris`)}}));const ji={grassland:{label:F("biome_grassland_name"),desc:F("biome_grassland"),vars:()=>t.race.rejuvenated?[1.25]:[1.2],wiki:["%"]},oceanic:{label:F("biome_oceanic_name"),desc:F("biome_oceanic"),vars:()=>t.race.rejuvenated?[1.25,1.12,.92]:[1.12,1.06,.95],wiki:["%","%","%"]},forest:{label:F("biome_forest_name"),desc:F("biome_forest"),vars:()=>t.race.rejuvenated?[1.35]:[1.2],wiki:["%"]},desert:{label:F("biome_desert_name"),desc:F("biome_desert"),vars:()=>t.race.rejuvenated?[1.35,1.18,.6]:[1.2,1.1,.75],wiki:["%","%","%"]},volcanic:{label:F("biome_volcanic_name"),desc:F("biome_volcanic"),vars:()=>t.race.rejuvenated?[.8,1.25,1.15]:[.9,1.12,1.08],wiki:["%","%","%"]},tundra:{label:F("biome_tundra_name"),desc:F("biome_tundra"),vars:()=>t.race.rejuvenated?[1.5,.8]:[1.25,.9],wiki:["%","%"]},savanna:{label:F("biome_savanna_name"),desc:F("biome_savanna"),vars:()=>t.race.rejuvenated?[1.18,1.25,.75]:[1.1,1.18,.8],wiki:["%","%","%"]},swamp:{label:F("biome_swamp_name"),desc:F("biome_swamp"),vars:()=>t.race.rejuvenated?[1.6,1.35,1.15,.78]:[1.4,1.25,1.1,.88],wiki:["%","%","%","%"]},ashland:{label:F("biome_ashland_name"),desc:F("biome_ashland"),vars:()=>t.race.rejuvenated?[.55,1.35,1.2]:[.62,1.25,1.1],wiki:["%","%","%"]},taiga:{label:F("biome_taiga_name"),desc:F("biome_taiga"),vars:()=>t.race.rejuvenated?[1.2,1.65,.88]:[1.1,1.5,.92],wiki:["%","%","%"]},hellscape:{label:F("biome_hellscape_name"),desc:F("biome_hellscape"),vars:()=>t.race.rejuvenated?[.2]:[.25],wiki:["%"]},eden:{label:F("biome_eden_name"),desc:F("biome_eden")}},Si={toxic:{label:F("planet_toxic"),desc:F("planet_toxic_desc"),vars:()=>t.race.rejuvenated?[2,1.5]:[1,1.25],wiki:["A","-%"]},mellow:{label:F("planet_mellow"),desc:F("planet_mellow_desc"),vars:()=>t.race.rejuvenated?[2,3,.88]:[1.5,2,.9],wiki:["%","A","%"]},rage:{label:F("planet_rage"),desc:F("planet_rage_desc"),vars:()=>t.race.rejuvenated?[1.1,1.05,1]:[1.05,1.02,1],wiki:["%","%","A"]},stormy:{label:F("planet_stormy"),desc:F("planet_stormy_desc")},ozone:{label:F("planet_ozone"),desc:F("planet_ozone_desc"),vars:()=>t.race.rejuvenated?[.18]:[.25],wiki:["-A"]},magnetic:{label:F("planet_magnetic"),desc:F("planet_magnetic_desc"),vars:()=>t.race.rejuvenated?[2,150,.98]:[1,100,.985],wiki:["A","A","%"]},trashed:{label:F("planet_trashed"),desc:F("planet_trashed_desc"),vars:()=>t.race.rejuvenated?[.8,1.2]:[.75,1],wiki:["%","%"]},elliptical:{label:F("planet_elliptical"),desc:F("planet_elliptical_desc")},flare:{label:F("planet_flare"),desc:F("planet_flare_desc")},dense:{label:F("planet_dense"),desc:F("planet_dense_desc"),vars:()=>t.race.rejuvenated?[1.5,1.2,1.35]:[1.2,1,1.2],wiki:["%","A","%"]},unstable:{label:F("planet_unstable"),desc:F("planet_unstable_desc")},permafrost:{label:F("planet_permafrost"),desc:F("planet_permafrost_desc"),vars:()=>t.race.rejuvenated?[.7,125]:[.75,100],wiki:["%","A"]},retrograde:{label:F("planet_retrograde"),desc:F("planet_retrograde_desc")}};function Fi(e){e=e||[];let t=Object.keys(di).filter((function(t){return di[t].basic()&&!e.includes(t)}));return t[Cc(t)]}function zi(){if(!t.settings.tabLoad&&(2!==t.settings.civTabs||6!==t.settings.govTabs))return;let e=$("#psychicPowers");rc(e),t.race.psychic&&t.tech.psychic&&(function(e){let a=$('
            ');e.append(a),a.append($(`
            ${F("psychic_boost_title")}
            `));let r=$("
            ");a.append(r);let s="";if(Object.keys(Va).forEach((function(e){t.resource[e].display&&(s+=`${t.resource[e].name}`)})),r.append(`
            ${s}
            `),a.append('
            '),t.tech.psychic>=4){let e=$(`
            ${F("psychic_channel")}
            `),t=$('{{ c.boost }}'),r=$(`«`),s=$(`»`);e.append(r),e.append(t),e.append(s),a.append(e)}let i=t.tech.psychic>=5?60:75,c=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;sc({el:"#psychicBoost",data:{b:t.race.psychicPowers.boost,c:t.tech.psychic>=4?t.race.psychicPowers.channel:{}},methods:{boostVal(){t.resource.Energy.amount>=i&&(t.resource.Energy.amount-=i,t.race.psychicPowers.boostTime=72*c)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.boost--}},filters:{boost:e=>F("psychic_boost_button",[t.resource[e]?t.resource[e].name:"N/A",i]),boostTime:()=>t.race.psychicPowers.boostTime>0?F("psychic_boost_time",[t.race.psychicPowers.boostTime]):""}});const o=document.getElementById("psyhscrolltarget");o.addEventListener("wheel",(e=>{e.preventDefault(),o.scrollLeft+=e.deltaY})),Ti("psychicBoost",(function(){return F("psychic_boost_desc",[ui.psychic.vars()[3]])}),{elm:"#psychicBoost > div > button"})}(e),function(e){let a=$('
            ');e.append(a),a.append($(`
            ${F("psychic_murder_title")}
            `)),a.append('
            ');let r=t.tech.psychic>=5?8:10;sc({el:"#psychicKill",data:{},methods:{murder(){t.resource.Energy.amount>=r&&t.resource[t.race.species].amount>=1&&(t.resource.Energy.amount-=r,t.resource[t.race.species].amount--,t.stats.psykill++,t.race.anthropophagite&&Vi("Food",1e4*ui.anthropophagite.vars()[0]),10===t.stats.psykill&&zi())}},filters:{kill:()=>F("psychic_murder_button",[r])}}),Ti("psychicKill",(function(){return F("psychic_murder_desc")}),{elm:"#psychicKill > div > button"})}(e),t.tech.psychic>=2&&function(e){let a=$('
            ');if(e.append(a),a.append($(`
            ${F("psychic_assault_title")}
            `)),a.append('
            '),t.tech.psychic>=4){let e=$(`
            ${F("psychic_channel")}
            `),t=$('{{ assault }}'),r=$(`«`),s=$(`»`);e.append(r),e.append(t),e.append(s),a.append(e)}let r=t.tech.psychic>=5?36:45,s=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;sc({el:"#psychicAssault",data:t.tech.psychic>=4?t.race.psychicPowers.channel:{},methods:{boostVal(){t.resource.Energy.amount>=r&&(t.resource.Energy.amount-=r,t.race.psychicPowers.assaultTime=72*s)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.assault--}},filters:{boost:()=>F("psychic_boost_button",[F("psychic_attack"),r]),boostTime:()=>t.race.psychicPowers.assaultTime>0?F("psychic_boost_time",[t.race.psychicPowers.assaultTime]):""}}),Ti("psychicAssault",(function(){return F("psychic_assault_desc",[ui.psychic.vars()[3]])}),{elm:"#psychicAssault > div > button"})}(e),t.tech.psychic>=3&&(t.race.psychicPowers.cash||(t.race.psychicPowers.cash=0),function(e){let a=$('
            ');if(e.append(a),a.append($(`
            ${F("psychic_profit_title")}
            `)),a.append('
            '),t.tech.psychic>=4){let e=$(`
            ${F("psychic_channel")}
            `),t=$('{{ cash }}'),r=$(`«`),s=$(`»`);e.append(r),e.append(t),e.append(s),a.append(e)}let r=t.tech.psychic>=5?52:65,s=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;sc({el:"#psychicFinance",data:t.tech.psychic>=4?t.race.psychicPowers.channel:{},methods:{boostVal(){t.resource.Energy.amount>=r&&(t.resource.Energy.amount-=r,t.race.psychicPowers.cash=72*s)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.cash--}},filters:{boost:()=>F("psychic_boost_button",[F("psychic_profit"),r]),boostTime:()=>t.race.psychicPowers.cash>0?F("psychic_boost_time",[t.race.psychicPowers.cash]):""}}),Ti("psychicFinance",(function(){return F("psychic_profit_desc",[ui.psychic.vars()[3]])}),{elm:"#psychicFinance > div > button"})}(e)),t.tech.psychicthrall&&t.tech.unfathomable&&t.race.unfathomable&&(t.tech.psychicthrall>=2&&function(e){let a=$('
            ');e.append(a),a.append($(`
            ${F("psychic_stun_title")}
            `)),a.append('
            ');let r=t.tech.psychic>=5?80:100;sc({el:"#psychicCapture",data:{},methods:{stun(){if(t.resource.Energy.amount>=r&&t.tech.unfathomable){let e=0;if(t.city.hasOwnProperty("surfaceDwellers"))for(let a=0;aF("psychic_stun_button",[r])}}),Ti("psychicCapture",(function(){return F("psychic_stun_desc")}),{elm:"#psychicCapture > div > button"})}(e),function(e){let a=$('
            ');e.append(a),a.append($(`
            ${F("psychic_mind_break_title")}
            `)),a.append('
            ');let r=t.tech.psychic>=5?64:80;sc({el:"#psychicMindBreak",data:{},methods:{breakMind(){if(t.resource.Energy.amount>=r&&t.tech.unfathomable){let e=[];if(t.city.hasOwnProperty("surfaceDwellers"))for(let a=0;a0&&e.push(a);if(e.length>0){let a=e[Math.rand(0,e.length)];t.city.captive_housing[`jailrace${a}`]--,t.city.captive_housing[`race${a}`]++,t.resource.Energy.amount-=r}}}},filters:{break:()=>F("psychic_mind_break_button",[r])}}),Ti("psychicMindBreak",(function(){return F("psychic_mind_break_desc")}),{elm:"#psychicMindBreak > div > button"})}(e)))}var Ai=!1;function Ti(e,a,r){r||(r={}),r.hasOwnProperty("elm")||(r.elm="#"+e),r.hasOwnProperty("bind")||(r.bind=!0),r.hasOwnProperty("unbind")||(r.unbind=!0),r.hasOwnProperty("placement")||(r.placement="bottom"),r.bind&&$(r.elm).on(r.bind_mouse_enter?"mouseenter":"mouseover",(function(){(Ai||$("#popper").length>0)&&Ei();let s=r.wide?" wide":"",i=r.classes?r.classes:"has-background-light has-text-dark pop-desc";var c=$(`
            `);r.attach?$(r.attach).append(c):$("#main").append(c),a&&c.append("function"==typeof a?a({this:this,popper:c}):a),Ai=Popper.createPopper(r.self?this:$(r.elm)[0],document.querySelector("#popper"),{placement:r.placement,modifiers:[{name:"flip",enabled:!0},{name:"offset",options:{offset:r.offset?r.offset:[0,0]}}]}),c.show(),r.hasOwnProperty("in")&&"function"==typeof r.in&&r.in({this:this,popper:c,id:"popper"}),Tc("firework")&&t[t.race.cataclysm||t.race.orbit_decayed?"space":"city"].firework.on>0&&$(c).append('')})),r.unbind&&("ontouchstart"in document.documentElement&&navigator.userAgent.match(t.settings.touch)?$(r.elm).on("touchend",(function(e){Ei(),r.hasOwnProperty("out")&&"function"==typeof r.out&&r.out({this:this,popper:$("#popper"),id:"popper"})})):$(r.elm).on(r.bind_mouse_enter?"mouseleave":"mouseout",(function(){Ei(),r.hasOwnProperty("out")&&"function"==typeof r.out&&r.out({this:this,popper:$("#popper"),id:"popper"})})))}function Ei(e){e&&$("#popper").data("id")!==e||($("#popper").hide(),Ai&&(Ai.destroy(),Ai=!1),rc($("#popper"),!0))}function Ii(e){switch(e){case"stop":M.w?M.w.postMessage({loop:"clear"}):(clearInterval(P.main_loop),clearInterval(P.mid_loop),clearInterval(P.long_loop)),M.s=!1;break;case"start":if(M.resetTimers(),t.settings.gameSpeed=1,Ki(),t.settings.at>0&&(t.settings.gameSpeed*=t.settings.atMultiplier),t.race.slow){const e=1-ui.slow.vars()[0]/100;t.settings.gameSpeed*=e}if(t.race.hyper){const e=1+ui.hyper.vars()[0]/100;t.settings.gameSpeed*=e}M.timers.mid/=t.settings.gameSpeed,M.timers.long/=t.settings.gameSpeed,M.w?(M.w.postMessage({loop:"short",period:M.timers.main}),M.w.postMessage({loop:"mid",period:M.timers.mid}),M.w.postMessage({loop:"long",period:M.timers.long})):(P.main_loop=setInterval((function(){fastLoop()}),M.timers.main),P.mid_loop=setInterval((function(){midLoop()}),M.timers.mid),P.long_loop=setInterval((function(){longLoop()}),M.timers.long)),M.s=!0}}function Ki(){if(!t.stats.hasOwnProperty("current"))return;const e=Date.now()-t.stats.current;if(e>=12e4){const a=t.settings.at+2*e/3,r=288e5;t.settings.at=Math.min(a,r)}}function Li(e,t){let a=ai(),r=[];switch(e){case"power":r=["city:transmitter","prtl_ruins:arcology","city:apartment","int_alpha:habitat","int_alpha:luxury_condo","spc_red:spaceport","spc_titan:titan_spaceport","spc_titan:electrolysis","int_alpha:starport","spc_dwarf:shipyard","spc_titan:ai_core2","spc_eris:drone_control","spc_titan:ai_colonist","int_blackhole:s_gate","gxy_gateway:starbase","spc_triton:fob","spc_enceladus:operating_base","spc_enceladus:zero_g_lab","spc_titan:sam","gxy_gateway:ship_dock","prtl_ruins:hell_forge","int_neutron:stellar_forge","int_neutron:citadel","tau_home:orbital_station","tau_red:orbital_platform","tau_gas:refueling_station","tau_home:tau_farm","tau_gas:ore_refinery","tau_gas:whaling_station","city:coal_mine","spc_moon:moon_base","spc_red:red_tower","spc_home:nav_beacon","int_proxima:xfer_station","gxy_stargate:telemetry_beacon","int_nebula:nexus","gxy_stargate:gateway_depot","spc_dwarf:elerium_contain","spc_gas:gas_mining","spc_belt:space_station","spc_gas_moon:outpost","gxy_gorddon:embassy","gxy_gorddon:dormitory","gxy_alien1:resort","spc_gas_moon:oil_extractor","int_alpha:int_factory","city:factory","spc_red:red_factory","spc_dwarf:world_controller","prtl_fortress:turret","prtl_badlands:war_drone","city:wardenclyffe","city:biolab","city:mine","city:rock_quarry","city:cement_plant","city:sawmill","city:mass_driver","int_neutron:neutron_miner","prtl_fortress:war_droid","prtl_pit:soul_forge","gxy_chthonian:excavator","int_blackhole:far_reach","prtl_badlands:sensor_drone","prtl_badlands:attractor","city:metal_refinery","gxy_stargate:gateway_station","gxy_alien1:vitreloy_plant","gxy_alien2:foothold","gxy_gorddon:symposium","int_blackhole:mass_ejector","city:casino","spc_hell:spc_casino","tau_home:tauceti_casino","prtl_fortress:repair_droid","gxy_stargate:defense_platform","prtl_ruins:guard_post","prtl_lake:cooling_tower","prtl_lake:harbour","prtl_spire:purifier","prtl_ruins:archaeology","prtl_pit:gun_emplacement","prtl_gate:gate_turret","prtl_pit:soul_attractor","prtl_gate:infernite_mine","int_sirius:ascension_trigger","spc_kuiper:orichalcum_mine","spc_kuiper:elerium_mine","spc_kuiper:uranium_mine","spc_kuiper:neutronium_mine","spc_dwarf:m_relay","tau_home:tau_factory","tau_home:infectious_disease_lab","tau_home:alien_outpost","tau_gas:womling_station","spc_red:atmo_terraformer","tau_star:matrix","tau_home:tau_cultural_center","prtl_pit:soul_capacitor","city:replicator"];break;case"moon":r=["spc_moon:helium_mine","spc_moon:iridium_mine","spc_moon:observatory"];break;case"red":r=["spc_red:living_quarters","spc_red:exotic_lab","spc_red:red_mine","spc_red:fabrication","spc_red:biodome","spc_red:vr_center"];break;case"belt":r=["spc_belt:elerium_ship","spc_belt:iridium_ship","spc_belt:iron_ship"];break;case"alpha":r=["int_alpha:fusion","int_alpha:mining_droid","int_alpha:processing","int_alpha:laboratory","int_alpha:g_factory","int_alpha:exchange","int_alpha:zoo"];break;case"nebula":r=["int_nebula:harvester","int_nebula:elerium_prospector"];break;case"gateway":r=["gxy_gateway:bolognium_ship","gxy_gateway:dreadnought","gxy_gateway:cruiser_ship","gxy_gateway:frigate_ship","gxy_gateway:corvette_ship","gxy_gateway:scout_ship"];break;case"alien2":r=["gxy_alien2:armed_miner","gxy_alien2:ore_processor","gxy_alien2:scavenger"];break;case"lake":r=["prtl_lake:bireme","prtl_lake:transport"];break;case"spire":r=["prtl_spire:port","prtl_spire:base_camp","prtl_spire:mechbay"];break;case"titan":r=["spc_titan:titan_quarters","spc_titan:titan_mine","spc_titan:g_factory","spc_titan:decoder"];break;case"enceladus":r=["spc_enceladus:water_freighter","spc_enceladus:operating_base","spc_enceladus:zero_g_lab"];break;case"eris":r=["spc_eris:shock_trooper","spc_eris:tank"];break;case"tau_home":r=["tau_home:colony","tau_home:tau_factory","tau_home:mining_pit","tau_home:infectious_disease_lab"];break;case"tau_red":r=["tau_red:womling_village","tau_red:womling_farm","tau_red:overseer","tau_red:womling_mine","tau_red:womling_fun","tau_red:womling_lab"];break;case"tau_roid":r=["tau_roid:mining_ship","tau_roid:whaling_ship"]}t&&(a[e].l.length=0),r.forEach((function(t){a[e].l.includes(t)||a[e].l.push(t)})),a[e].l.length>r.length&&a[e].l.forEach((function(t){r.includes(t)||a[e].l.splice(a[e].l.indexOf(t),1)}))}function Ni(e){(e=e||h).forEach((function(e){p[e]=[],t.settings.msgFilters[p.view].vis||($(`#msgQueueFilter-${p.view}`).removeClass("is-active"),$(`#msgQueueFilter-${e}`).addClass("is-active"),p.view=e)}))}function Di(e,a,r,s,i){if(s=s||[],i||s.includes("all")||s.push("all"),a=a||"warning",s.includes(p.view)){let r=$('

            '+e+"

            ");$("#msgQueueLog").prepend(r),$("#msgQueueLog").children().length>t.settings.msgFilters[p.view].max&&$("#msgQueueLog").children().last().remove()}s.forEach((function(r){p[r].unshift({msg:e,color:a}),p[r].length>t.settings.msgFilters[r].max&&p[r].pop()})),r||s.forEach((function(r){t.lastMsg[r]&&(t.lastMsg[r].unshift({m:e,c:a}),t.lastMsg[r].length>t.settings.msgFilters[r].save&&t.lastMsg[r].splice(t.settings.msgFilters[r].save))}))}function Bi(e){for(let a=t.queue.queue.length-1;a>=0;a--)e.includes(t.queue.queue[a].id)&&t.queue.queue.splice(a,1)}function Gi(e){for(let a=t.r_queue.queue.length-1;a>=0;a--)e.includes(Qr.tech[t.r_queue.queue[a].type].grant[0])&&t.r_queue.queue.splice(a,1)}function Ri(){let e=t.tech.queue>=2?t.tech.queue>=3?8:5:3;t.stats.feat.journeyman&&t.stats.feat.journeyman>=2&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>=2&&(e+=Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman)>=4?2:1),t.genes.queue&&t.genes.queue>=2&&(e*=2);let a=N("pragmatist",0);a&&(e=Math.round(e*(1+a/100))),t.queue.max=e}function Hi(){let e=3;if(t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0){let a=Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman);e+=a>=3?a>=5?3:2:1}t.genes.queue&&t.genes.queue>=2&&(e*=2);let a=N("theorist",0);a&&(e=Math.round(e*(1+a/100))),t.r_queue.max=e}function Ui(){!function(){let e=$("#buildQueue .buildList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}(),rc($("#buildQueue")),$("#buildQueue").append($(`\n

            ${F("building_queue")} ({{ | used_q }}/{{ max }})

            \n \n `));let e=$('
              ');$("#buildQueue").append(e),e.append($('
            • {{ item.label }}{{ item.q | count }} [{{ item.time | time }}{{ item.t_max | max_t(item.time) }}]
            • '));try{sc({el:"#buildQueue",data:t.queue,methods:{remove(e){let a=y();for(let r=0;r0&&(t.queue.queue[e].q-=t.queue.queue[e].qs),t.queue.queue[e].q<=0){Ei(`q${t.queue.queue[e].id}${e}`),t.queue.queue.splice(e,1),Ui();break}},setID:e=>`q${t.queue.queue[e].id}${e}`,setData(e,a){let r,s=t.queue.queue[e].id.split("-");"arpa"===s[0].substring(0,4)?r=s[0].substring(4):"city"===s[0]||"evolution"===s[0]||"starDock"===s[0]?r=Qr[s[0]][s[1]]:Object.keys(Qr[s[0]]).forEach((function(e){Qr[s[0]][e].hasOwnProperty(s[1])&&(r=Qr[s[0]][e][s[1]])}));let i={};if(r.cost){let e=gc(r);Object.keys(e).forEach((function(t){let r=e[t]();r>0&&(i[`${a}-${t}`]=r)}))}return i},pauseQueue(){$("#pausequeue").removeClass("play"),$("#pausequeue").removeClass("pause"),t.queue.pause?(t.queue.pause=!1,$("#pausequeue").addClass("play")):(t.queue.pause=!0,$("#pausequeue").addClass("pause"))},pausedesc:()=>t.queue.pause?F("queue_play"):F("queue_pause")},filters:{time:e=>ic(e),count:e=>e>1?` (${e})`:"",max_t:(e,t)=>t===e||t<0?"":` / ${ic(e)}`,used_q(){let e=0;for(let a=0;a=4&&(r.tech.whitehole=3,r.resource.Soul_Gem.amount+=10,r.resource.Knowledge.amount+=15e5,r.stats.know-=15e5),r.tech.hasOwnProperty("quaked")&&2===r.tech.quaked&&(r.tech.quaked=1,r.resource.Knowledge.amount+=5e5,r.stats.know-=5e5),r.tech.hasOwnProperty("corrupted_ai")&&3===r.tech.corrupted_ai&&(r.tech.corrupted_ai=1,r.resource.Knowledge.amount+=5e6,r.stats.know-=5e6)),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(r))),window.location.reload())};const Qi=!1;function Zi(e,t){try{t.debug_mode=Qi,gtag("event",e,t)}catch(e){}}function Vi(e,a,r,s){let i=t.resource[e].amount+a,c=!0;return i>t.resource[e].max&&-1!=t.resource[e].max?i=t.resource[e].max:i<0&&((!s||s&&-1*i>s)&&(c=!1),i=0),Number.isNaN(i)||(t.resource[e].amount=i,r||(t.resource[e].delta+=a,"Mana"===e&&a>0&&(t.resource[e].gen_d+=a))),c}function Ji(e){let a=di[t.race.species].type;switch(a){case"animal":a="animalism";break;case"small":a="dwarfism";break;case"giant":a="gigantism";break;case"avian":case"reptilian":a="eggshell";break;case"fungi":a="chitin";break;case"insectoid":a="athropods";break;case"angelic":a="celestial";break;case"organism":a="sentience"}const r=e?[F("civics_gov_tp_name0"),F("civics_gov_tp_name1"),F("civics_gov_tp_name2"),F("civics_gov_tp_name3"),F("civics_gov_tp_name4"),F("civics_gov_tp_name5"),F("civics_gov_tp_name6"),F("civics_gov_tp_name7"),F("civics_gov_tp_name8"),F("civics_gov_tp_name9")]:[di[t.race.species].name,di[t.race.species].home,F(`biome_${t.city.biome}_name`),F(`evo_${a}_title`),F("civics_gov_name0"),F("civics_gov_name1"),F("civics_gov_name2"),F("civics_gov_name3"),F("civics_gov_name4"),F("civics_gov_name5"),F("civics_gov_name6"),F("civics_gov_name7"),F("civics_gov_name8"),F("civics_gov_name9"),F("civics_gov_name10"),F("civics_gov_name11")];return{s0:Math.rand(0,14),s1:r[Math.rand(0,r.length)]}}function Yi(e,a,r,s,i){i||(i="city"),"micro"===t.race.universe&&(s-=nc("micro",!1)),t.race.small?s-=ui.small.vars()[0]:t.race.large&&(s+=ui.large.vars()[0]),t.race.compact&&(s-=ui.compact.vars()[0]),!t.race.tunneler||"mine"!==e&&"coal_mine"!==e||(s-=ui.tunneler.vars()[0]),!t.tech.housing_reduction||"basic_housing"!==e&&"cottage"!==e||(s-=.02*t.tech.housing_reduction),t.tech.housing_reduction&&"captive_housing"===e&&(s-=.01*t.tech.housing_reduction),"basic_housing"===e&&(t.race.solitary&&(s-=ui.solitary.vars()[0]),t.race.pack_mentality&&(s+=ui.pack_mentality.vars()[0])),"cottage"===e&&(t.race.solitary&&(s+=ui.solitary.vars()[1]),t.race.pack_mentality&&(s-=ui.pack_mentality.vars()[1])),"apartment"===e&&t.race.pack_mentality&&(s-=ui.pack_mentality.vars()[1]),t.genes.creep&&!t.race.no_crispr?s-=.01*t.genes.creep:t.genes.creep&&t.race.no_crispr&&(s-=.002*t.genes.creep);let c=N("noquestions",0);c&&(s-=c),s<1.005&&(s=1.005);var o="citizen"===e?t.resource[t.race.species].amount:t[i][e]?t[i][e].count:0;return a&&(o+=a),Math.round(s**o*r)}function Xi(e,a,r,s,i,c){i||(i="space"),c=c||1.005,"micro"===t.race.universe&&(s-=nc("micro",!0)),t.genes.creep&&!t.race.no_crispr?s-=.01*t.genes.creep:t.genes.creep&&t.race.no_crispr&&(s-=.002*t.genes.creep),t.race.small&&(s-=ui.small.vars()[1]),t.race.compact&&(s-=ui.compact.vars()[1]),t.prestige.Harmony.count>0&&t.stats.achieve.ascended&&(s-=ec());let o=N("noquestions",0);o&&(s-=o),s0&&t.stats.achieve.ascended){let e=0;switch(t.race.universe){case"heavy":t.stats.achieve.ascended.hasOwnProperty("h")&&(e=t.stats.achieve.ascended.h*t.prestige.Harmony.count);break;case"antimatter":t.stats.achieve.ascended.hasOwnProperty("a")&&(e=t.stats.achieve.ascended.a*t.prestige.Harmony.count);break;case"evil":t.stats.achieve.ascended.hasOwnProperty("e")&&(e=t.stats.achieve.ascended.e*t.prestige.Harmony.count);break;case"micro":t.stats.achieve.ascended.hasOwnProperty("m")&&(e=t.stats.achieve.ascended.m*t.prestige.Harmony.count);break;case"magic":t.stats.achieve.ascended.hasOwnProperty("mg")&&(e=t.stats.achieve.ascended.mg*t.prestige.Harmony.count);break;default:t.stats.achieve.ascended.hasOwnProperty("l")&&(e=t.stats.achieve.ascended.l*t.prestige.Harmony.count)}if(e>0)return e=.01*(Math.log(50+e)-3.912023005428146),+e.toFixed(5)}return 0}function tc(e,a,r,s){if(s=void 0===s||s,e.cost){let i=0,c=!1,o=!(!a||!a.id[e.id])&&a.id[e.id],n=gc(e,o),l=!!a&&{},u=!!a&&{};a&&(Object.keys(a.r).forEach((function(e){l[e]=a.r[e]})),Object.keys(a.rr).forEach((function(e){u[e]=a.rr[e]})));let d=!1;t.interstellar.hasOwnProperty("mass_ejector")&&t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks&&Object.keys(t.race.governor.tasks).forEach((function(e){"trash"===t.race.governor.tasks[e]&&(d=!0)}));let _={};return Object.keys(n).forEach((function(e){if(i>=0&&!t.prestige.hasOwnProperty(e)&&!["Morale","HellArmy","Structs","Bool"].includes(e)){var r=Number(o?n[e](o):n[e]());if(r>0){let o="Species"===e?t.race.species:e,n="Supply"===e?t.portal.purifier.supply:Number(t.resource[o].amount),p="Supply"===e?t.portal.purifier.sup_max:t.resource[o].max,h="Supply"===e?t.portal.purifier.diff:t.resource[o].diff;if(d&&t.interstellar.mass_ejector[e]&&(h+=t.interstellar.mass_ejector[e],t.race.governor.config.trash.hasOwnProperty(e)&&(h-=Math.min(t.race.governor.config.trash[e].v,t.interstellar.mass_ejector[e]))),a&&(n+=h*(s?a.t.t:a.t.rt),a.r.hasOwnProperty(o)||(a.r[o]=0),a.rr.hasOwnProperty(o)||(a.rr[o]=0),s?(n-=Number(a.r[o]),a.r[o]+=r,a.rr[o]+=r):(n-=Number(a.rr[o]),a.rr[o]+=r),p>=0&&n>p&&(n=p)),r>n)if(h>0){let e=(r-n)/h;e>i&&(c=o,i=e),_[o]=e}else a&&(a.r=l,a.rr=u),i=-9999999,_[o]=99999999-h,(_[c]&&_[o]>_[c]||!_[c])&&(c=o)}}})),a&&i>=0&&(void 0===a.id[e.id]?a.id[e.id]=1:a.id[e.id]++,s&&(a.t.t+=i),a.t.rt+=i),r?{t:i,r:c,s:_}:i}return 0}function ac(e,a,r,s){let i=!(!r||!r.id[e.id])&&r.id[e.id],c=Ke(e.cost,i),o=0,n=!!r&&{},l=!!r&&{},u=!1;r&&(Object.keys(r.r).forEach((function(e){n[e]=r.r[e]})),Object.keys(r.rr).forEach((function(e){l[e]=r.rr[e]})));let d=!1;t.interstellar.hasOwnProperty("mass_ejector")&&t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks&&Object.keys(t.race.governor.tasks).forEach((function(e){"trash"===t.race.governor.tasks[e]&&(d=!0)}));let _={};return Object.keys(c).forEach((function(e){if(o>=0){let s=Number(c[e](i))*a;if(s>0){let a=Number(t.resource[e].amount),i=t.resource[e].diff;if(r&&(d&&t.interstellar.mass_ejector[e]&&(i+=t.interstellar.mass_ejector[e],t.race.governor.config.trash.hasOwnProperty(e)&&(i-=Math.min(t.race.governor.config.trash[e].v,t.interstellar.mass_ejector[e]))),a+=i*r.t.t,r.r[e]?(a-=Number(r.r[e]),r.r[e]+=s):r.r[e]=s,r.rr[e]?r.rr[e]+=s:r.rr[e]=s,t.resource[e].max>=0&&a>t.resource[e].max&&(a=t.resource[e].max)),s>a)if(i>0){let t=(s-a)/i;t>o&&(o=t,u=e),_[e]=t}else r&&(r.r=n,r.rr=l),o=-9999999,_[e]=99999999-i,(_[u]&&_[e]>_[u]||!_[u])&&(u=e)}}})),r&&o>=0&&(void 0===r.id[e.id]?r.id[e.id]=1:r.id[e.id]++,r.t.t+=o,r.t.rt+=o),s?{t:o,r:u,s:_}:o}function rc(e,t){if(e.find(".vb").each((function(){try{$(this)[0].__vue__.$destroy()}catch(e){}})),t){try{e[0].__vue__.$destroy()}catch(e){}e.remove()}else e.empty()}function sc(e,t){if(t=t||"create",$(e.el).length>0&&void 0!==$(e.el)[0].__vue__)try{"update"===t?$(e.el)[0].__vue__.$forceUpdate():$(e.el)[0].__vue__.$destroy()}catch(e){}"create"===t&&(new Vue(e),$(e.el).addClass("vb"))}function ic(e){let t;if(e<0)t=F("time_never");else if((e=+e.toFixed(0))>60){let a=e%60,r=(e-a)/60;if(r>=60){let e=r%60,a=(r-e)/60;a>24?(e=a%24,t=`${(a-e)/24}d ${e}h`):(e=("0"+e).slice(-2),t=`${a}h ${e}m`)}else a=("0"+a).slice(-2),t=`${r}m ${a}s`}else t=`${e}s`;return t}function cc(e){return"antimatter"===t.race.universe&&(e=+(e*=nc("antimatter")).toFixed(2)),"leo"===U()&&(e=+(e*=1+H("leo")[0]/100).toFixed(2)),e}function oc(e){return t.race.emfield?+(1.5*e).toFixed(2):e}function nc(e,a,r,s){s||(s={});let i=void 0!==s.dark?s.dark:t.prestige.Dark.count,c=void 0!==s.harmony?s.harmony:t.prestige.Harmony.count,o=void 0!==s.sludge?s.sludge:t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge[Yc(e)]?t.stats.achieve.extinct_sludge[Yc(e)]:0;switch(e){case"standard":return"standard"===t.race.universe||r?(c>0&&(i*=1+.001*c),o&&(i*=1+.03*o),1+i/200):0;case"evil":return"evil"===t.race.universe||r?(c>0&&(i*=1+.01*c),o&&(i*=1+.03*o),1+(Math.log2(10+i)-3.321928094887362)/5):1;case"micro":return"micro"===t.race.universe||r?a?(c>0&&(i*=1+.01*c),i=.01+(Math.log(100+i)-4.605170185988092)/35,o&&(i*=1+.03*o),i>.04&&(i=.04),+i.toFixed(5)):(c>0&&(i*=1+.01*c),i=.02+(Math.log(100+i)-4.605170185988092)/20,o&&(i*=1+.03*o),i>.06&&(i=.06),+i.toFixed(5)):0;case"heavy":return"heavy"===t.race.universe||r?(c>0&&(i*=1+.01*c),o&&(i*=1+.03*o),.995**i):1;case"antimatter":return"antimatter"===t.race.universe||r?(c>0&&(i*=1+.01*c),o&&(i*=1+.03*o),1+(Math.log(50+i)-3.912023005428146)/5):0;case"magic":return"magic"===t.race.universe||r?(c>0&&(i*=1+.01*c),o&&(i*=1+.03*o),1+(Math.log(50+i)-3.912023005428146)/3):0}return 0}const lc=function(e){return uc&&!e?uc:t.genes.challenge&&t.genes.challenge>=2?uc=dc(t.race.universe):0};var uc;function dc(e,a){if(t.genes.challenge&&t.genes.challenge>=2){let r=Jc(e=e||t.race.universe),s="standard"===e?.25:.15,i=t.genes.challenge>=3?.15:.1;t.genes.challenge>=4&&"standard"!==e&&(s+=.05,i-=.05),t.race.weak_mastery&&"antimatter"===e&&(s/=10,i/=10),t.race.nerfed&&(s/="antimatter"===e?5:2,i/="antimatter"===e?5:2),t.race.ooze&&(s*=1-ui.ooze.vars()[2]/100,i*=1-ui.ooze.vars()[2]/100);let c=t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):0;c>0&&(s*=1+c/100,i*=1+c/100);let o=r.aLvl*s,n=0;return"standard"!==e&&(n=r.uLvl*i),t.genes.challenge>=5&&t.race.hasOwnProperty("mastery")&&(o*=1+ui.mastery.vars()[0]*t.race.mastery/100,n*=1+ui.mastery.vars()[0]*t.race.mastery/100),a?{g:o,u:n,m:o+n}:o+n}return a?{g:0,u:0,m:0}:0}const _c=function(e){if(!pc||e){let e=0;Object.keys(t.pillars).forEach((function(a){di[a]&&t.race.species===a?e+=4:di[a]&&e++})),pc=[1+e/100,1+2*e/100]}return pc};var pc;function hc(e,a,r,s){r=r||0;let i=(s=s||{}).genes;void 0===i&&(i=ro()-1,i>4&&(i=4));let c=s.uni||t.race.universe;if("micro"===c&&(e*=.25),"antimatter"===c&&(e*=1.1),"heavy"===c&&"mad"!==a)switch(i){case 1:e*=1.1;break;case 2:e*=1.15;break;case 3:e*=1.2;break;case 4:e*=1.25;break;default:e*=1.05}switch((void 0!==s.tp?s.tp:t.race.truepath)&&(e*=1.1),i){case 1:return+(1.05*e).toFixed(r);case 2:return+(1.12*e).toFixed(r);case 3:return+(1.25*e).toFixed(r);case 4:return+(1.45*e).toFixed(r);default:return+e.toFixed(r)}}function mc(e,a){let r={plasmid:0,phage:0,dark:0,harmony:0,artifact:0,cores:0};a||(a={});let s=a.genes,i=a.uni;i=i||t.race.universe;let c=0;if(void 0===a.cit){let e=t.civic.hasOwnProperty("garrison")?t.civic.garrison.workers:0;for(let a=0;a<3;a++)t.civic.foreign[`gov${a}`].occ&&(e+=la("federation"===t.civic.govern.type?15:20));c=t.race.high_pop?Math.round(t.resource[t.race.species].amount/ui.high_pop.vars()[0])+Math.round(e/ui.high_pop.vars()[0]):t.resource[t.race.species].amount+e}else c=a.high_pop?Math.round(a.cit/ui.high_pop.vars(a.high_pop)[0])+Math.round(a.sol/ui.high_pop.vars(a.high_pop)[0]):a.cit+a.sol;let o=999,n=1e6,l=100,u=0,d=150;switch(e){case"mad":o=3,n=1e5,l=1.1,d=150,(void 0!==a.synth?a.synth:"synthetic"===di[t.race.species].type)&&(o=5,n=125e3,d=100);break;case"cataclysm":case"bioseed":o=3,n=5e4,l=1.015,u=1,d=400;break;case"ai":o=2.5,n=45e3,l=1.014,u=2,d=600;break;case"vacuum":case"bigbang":o=2.2,n=4e4,l=1.012,u=2.5,d=800;break;case"ascend":case"terraform":o=1.15,n=3e4,l=1.008,u=4,d=2e3;break;case"matrix":o=1.5,n=32e3,l=1.01,u=3.2,d=1800;break;case"retire":o=1.15,n=32e3,l=1.006,u=3.2,d=1800;break;case"eden":o=1,n=18e3,l=1.004,u=2.5,d=1800}if(d=void 0!==s?Math.floor(d*(1+(s+(a.tp?1:0))/8)):Math.floor(d*(1+(ro()-(t.race.truepath?0:1))/8)),void 0===a.plas){let s=void 0!==a.know?a.know:t.stats.know,i=Math.round(c/o);for(;s>n;)i++,s-=n,n*=l;if(t.race.cataclysm?i+=300:t.race.lone_survivor&&(i+=800),r.plasmid=hc(i,e,!1,a),!a.rawPlasmids&&r.plasmid>d){let e=r.plasmid-d;r.plasmid=d,e=Math.floor(e/(e+d)*d),r.plasmid+=e}}else r.plasmid=a.plas;if(r.phage=r.plasmid>0?hc(Math.floor(Math.log2(r.plasmid)*Math.E*u),e,!1,a):0,"bigbang"===e){let e=a.exotic,s=a.mass;void 0===e&&t.interstellar&&t.interstellar.stellar_engine&&(e=t.interstellar.stellar_engine.exotic,s=t.interstellar.stellar_engine.mass);let i=+Math.log(1+40*e).toFixed(3);i+=+(Math.log2(s-7)/2.5).toFixed(3),i=hc(i,"bigbang",3,a),r.dark=i}else if("vacuum"===e){let e=void 0!==a.mana?a.mana:t.resource.Mana.gen,s=+(Math.log2(e)/5).toFixed(3);s=hc(s,"vacuum",3,a),r.dark=s}if(["ascend","descend","terraform"].includes(e)){let c=1;if(void 0===s?(c=ro(),c>5&&(c=5)):c=s+1,"ascend"===e||"terraform"===e){switch(i){case"micro":c*=.25;break;case"heavy":c*=1.2;break;case"antimatter":c*=1.1}r.harmony=parseFloat(c.toFixed(2))}else if("descend"===e){let e="micro"===i?1:c,s=a.floor;void 0!==s?s++:s=t.portal.hasOwnProperty("spire")?t.portal.spire.count:0,[50,100].forEach((function(t){s>t&&e++})),r.artifact=e}}return"ai"===e&&(r.cores="micro"===i?2:5),r}function gc(e,a,r){let s=e.cost||{};if((s.RNA||s.DNA)&&t.genes.evolve){var i={};return Object.keys(s).forEach((function(e){"RNA"!==e&&"DNA"!==e||(i[e]=function(){return Math.round(.8*s[e](a,r))})})),i}return s=function(e,a,r){if(t.race.bloated){let t=1+ui.bloated.vars()[0]/100;var s={};return Object.keys(e).forEach((function(i){["Food","Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Alloy","Polymer","Iridium"].includes(i)?s[i]=function(){return e[i](a,r)*t}:s[i]=function(){return e[i](a,r)}})),s}return e}(s,a,r),s=function(e,a,r,s){if((s?s.truepath:t.race.truepath)&&(!a.hasOwnProperty("path")||!a.path.includes("truepath"))){var i={};return Object.keys(e).forEach((function(t){"Money"===t?i[t]=function(){return Math.round(3*e[t](r,s))}:["Structs","Knowledge","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe"].includes(t)?i[t]=function(){return e[t](r,s)}:i[t]=function(){return Math.round(2*e[t](r,s))}})),i}return e}(s,e,a,r),s=function(e,a,r){if(t.race.lone_survivor){var s={};return Object.keys(e).forEach((function(t){["Structs","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe"].includes(t)?s[t]=function(){return e[t](a,r)}:["Knowledge"].includes(t)?s[t]=function(){return Math.round(.5*e[t](a,r))}:["Money"].includes(t)?s[t]=function(){return Math.round(.22*e[t](a,r))}:["Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Quantium"].includes(t)?s[t]=function(){return Math.round(.14*e[t](a,r))}:s[t]=function(){return Math.round(.28*e[t](a,r))}})),s}return e}(s,a,r),s=function(e,a,r){if(t.race.inflation){var s={};return Object.keys(e).forEach((function(i){if("Money"===i){let c=1+t.race.inflation/75;s[i]=function(){return Math.round(e[i](a,r)*c)}}else s[i]=function(){return e[i](a,r)}})),s}return e}(s,a,r),s=function(e,a,r){if("technocracy"===t.civic.govern.type){let t=1+ae.technocracy()[1]/100;var s={};return Object.keys(e).forEach((function(i){if("Knowledge"===i){let t=1-ae.technocracy()[0]/100;s[i]=function(){return Math.round(e[i](a,r)*t)}}else s[i]="Money"===i||"Structs"===i||"Custom"===i?function(){return e[i](a,r)}:function(){return Math.round(e[i](a,r)*t)}})),s}return e}(s,a,r),s=function(e,a,r){if(t.race.flier&&(e.Stone||e.Cement)){var s={};let t=1-ui.flier.vars()[0]/100;return Object.keys(e).forEach((function(i){"Stone"!==i||e.Cement?"Cement"===i?e.Stone?s.Stone=function(){return Math.round(e.Stone(a,r)*t+1.8*e[i](a,r)*t)||0}:s.Stone=function(){return Math.round(1.75*e[i](a,r)*t)}:s[i]=function(){return e[i](a,r)}:s[i]=function(){return Math.round(e[i](a,r)*t)||0}})),s}return e}(s,a,r),s=function(e,a,r){if(t.race.kindling_kindred&&(e.Lumber||e.Plywood)){var s={};let t=1+ui.kindling_kindred.vars()[0]/100;return Object.keys(e).forEach((function(i){"Lumber"!==i&&"Plywood"!==i&&"Structs"!==i?s[i]=function(){return Math.round(e[i](a,r)*t)||0}:"Structs"===i&&(s[i]=function(){return e[i](a,r)})})),s}if(t.race.unfathomable&&t.city.captive_housing){let t=Pi("entish");if(t>0){s={};let i=1-.4*t;return Object.keys(e).forEach((function(t){s[t]="Lumber"===t&&"Plywood"===t?function(){return Math.round(e[t](a,r)*i)||0}:function(){return e[t](a,r)}})),s}}return e}(s,a,r),s=function(e,a,r){if(t.race.smoldering){let s={};return Object.keys(e).forEach((function(t){if("Lumber"===t||"Plywood"===t){let i="Plywood"===t?2:1;s.Chrysotile=function(){return Math.round(e[t](a,r)*i)||0}}else["HellArmy","Structs","Chrysotile","Knowledge","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe","Mana","Energy"].includes(t)?s[t]=function(){return e[t](a,r)}:s[t]=function(){return Math.round(.9*e[t](a,r))}})),!s.hasOwnProperty("Chrysotile")&&e.hasOwnProperty("Money")&&t.tech.primitive&&t.tech.primitive>=3&&(s.Chrysotile=function(){let t=e.Money(a,r)||0;return t>0?Math.round(t/50):0}),s}return e}(s,a,r),s=function(e,a,r){let s=N("pragmatist",1),i=Pi("gnome");if((t.race.smart||t.race.dumb||s||i>0)&&e.Knowledge){var c={};return Object.keys(e).forEach((function(o){c[o]="Knowledge"===o?function(){let c=e[o](a,r);return t.race.smart&&(c*=1-ui.smart.vars()[0]/100),i>0&&(c*=1-ui.smart.vars(1)[0]/100*i),t.race.dumb&&(c*=1+ui.dumb.vars()[0]/100),s&&(c*=1+s/100),Math.round(c)}:function(){return e[o](a,r)}})),c}return e}(s,a,r),s=function(e,a,r){if(e.Cement&&t.tech.cement&&t.tech.cement>=2){let i=t.tech.cement>=3?.8:.9;var s={};return Object.keys(e).forEach((function(t){s[t]="Cement"===t?function(){return Math.round(e[t](a,r)*i)||0}:function(){return e[t](a,r)}})),s}return e}(s,a,r),s=function(e,t,a){let r=N("extravagant",0);if(r){var s={};return Object.keys(e).forEach((function(i){if("Money"===i){let c=1+r/100;s[i]=function(){return Math.round(e[i](t,a)*c)}}else s[i]=function(){return e[i](t,a)}})),s}return e}(s,a,r),s=function(e,a,r){if(t.race.heavy){var s={};return Object.keys(e).forEach((function(t){s[t]="Stone"===t||"Cement"===t||"Wrought_Iron"===t?function(){return Math.round(e[t](a,r)*(1+ui.heavy.vars()[1]/100))}:function(){return e[t](a,r)}})),s}return e}(s,a,r),function(e,a,r){let s=Pi("pterodacti");if((t.race.hollow_bones||s>0)&&(e.Plywood||e.Brick||e.Wrought_Iron||e.Sheet_Metal||e.Mythril||e.Aerogel||e.Nanoweave||e.Scarletite||e.Quantium)){var i={};return Object.keys(e).forEach((function(c){i[c]="Plywood"===c||"Brick"===c||"Wrought_Iron"===c||"Sheet_Metal"===c||"Mythril"===c||"Aerogel"===c||"Nanoweave"===c||"Scarletite"===c||"Quantium"===c?function(){let i=e[c](a,r);return t.race.hollow_bones&&(i*=1-ui.hollow_bones.vars()[0]/100),s>0&&(i*=1-ui.hollow_bones.vars(3)[0]/100*s),Math.round(i)}:function(){return e[c](a,r)}})),i}return e}(s,a,r)}function fc(e){return t.race.high_pop&&(e*=ui.high_pop.vars()[0]),e}function vc(e){switch(e){case"star":return'';case"atom":return'';case"heavy":return'';case"evil":return'';case"micro":return'';case"magic":return'';case"rocket":return'';case"heart":return'';case"clover":return'';case"candy":return'';case"ghost":return'';case"turkey":return'';case"present":return'';case"nuclear":return'';case"zombie":return'';case"fire":return'';case"mask":return'';case"skull":return'';case"taijitu":return'';case"trash":return'';case"martini":return'';case"lightbulb":return'';case"bunny":return'';case"egg":return'';case"turtle":return'';case"candycorn":return'';case"banana":return'\n ';case"sun":return'';case"firework":return'';case"floppy":return'';case"slime":return'';case"lightning":return'\n \n '}}function yc(e){switch(e){case"star":return"0 0 640 640";case"atom":return"0 0 100 88.379";case"heavy":case"mask":return"0 0 24 24";case"evil":return"0 0 240 240";case"micro":return"0 0 276 276";case"magic":return"0 0 2666 2666";case"rocket":return"0 0 165 173";case"sun":return"0 0 48 48";case"heart":return"0 0 20 16";case"clover":return"0 0 660.51 780.1";case"candy":return"0 0 200 200";case"ghost":return"0 0 399 432.23";case"turkey":return"0 0 250 300";case"present":return"0 0 410.98 434.75";case"nuclear":return"0 0 101.22 101.22";case"zombie":return"0 0 175 304";case"fire":return"0 0 615.18 879.36";case"skull":return"0 0 256.27 300.86";case"taijitu":return"0 -10 256 256 ";case"pizza":return"0 0 217.444 144.397";case"trash":case"martini":return"0 0 15 15";case"party":return"0 0 528.69 983.1";case"lightbulb":return"0 0 100 156";case"bunny":case"ant":return"0 0 128 128";case"egg":return"0 0 273.61 295.02";case"turtle":return"20 40 270 50";case"candycorn":return"0 0 325 449.98";case"banana":return"0 0 113.38582 111.81719";case"firework":return"0 10 12 35";case"floppy":return"0 0 60 60";case"slime":return"0 0 552 495";case"lightning":return"0 0 16 16"}}function bc(e,a){if("feat"===a)switch(e){case"steelem":return"nuclear";case"the_misery":return"zombie";case"ill_advised":return"fire";case"garbage_pie":return"trash";case"demon_slayer":return"skull";case"equilibrium":return"taijitu";case"utopia":return"martini";case"energetic":return"lightbulb";case"finish_line":return"turtle";case"banana":return"banana";case"digital_ascension":return"floppy";case"slime_lord":return"slime";case"annihilation":return"lightning";case"friday":return"mask";case"valentine":return"heart";case"leprechaun":return"clover";case"easter":return"bunny";case"launch_day":return"rocket";case"solstice":return"sun";case"firework":return"firework";case"egghunt":return"egg";case"halloween":return"ghost";case"trickortreat":return"candy";case"thanksgiving":return"turkey";case"xmas":return"present";default:return"star"}return t.settings.icon}function wc(e,t,a,r,s){let i="";return r&&(i=`id="${r}" `),`${vc(e)}`}function $c(e,a){let r=Ec();const s=new Date;return r.active&&!t.special.egg[s.getFullYear()][`egg${e}`]?wc("egg",a||16,2,`egg${e}`,'role="button" aria-label="Egg" '):""}function xc(e){$(`#egg${e}`).click((function(){let a=(new Date).getFullYear();t.special.egg[a][`egg${e}`]||(t.special.egg[a][`egg${e}`]=!0,e<=12?"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=9,t.stats.antiplasmid+=9,Di(F("city_egg_msg",[9,F("resource_AntiPlasmid_plural_name")]),"success",!1,["events"])):(t.prestige.Plasmid.count+=9,t.stats.plasmid+=9,Di(F("city_egg_msg",[9,F("resource_Plasmid_plural_name")]),"success",!1,["events"])):(t.prestige.Phage.count+=4,t.stats.phage+=4,Di(F("city_egg_msg",[4,F("resource_Phage_name")]),"success",!1,["events"])),$(`#egg${e}`).remove(),$(".popper").hide())}))}function kc(e,a,r){let s=Ic();const i=(new Date).getFullYear();let c=r?"trick":"treat";return s.active&&!t.special.trick[i][`${c}${e}`]?wc(r?"ghost":"candycorn",a||16,2,`${c}${e}`,`role="button" aria-label="${r?"Ghost":"Candy Corn"}" `):""}function qc(e,a){const r=(new Date).getFullYear();let s=a?"trick":"treat";$(`#${s}${e}`).click((function(){t.special.trick[r][`${s}${e}`]||(t.special.trick[r][`${s}${e}`]=!0,a?(t.prestige.Phage.count+=2,t.stats.phage+=2,Di(F("city_ghost_msg",[2,F("resource_Phage_name")]),"success",!1,["events"])):"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=13,t.stats.antiplasmid+=13,Di(F("city_trick_msg",[13,F("resource_AntiPlasmid_plural_name")]),"success",!1,["events"])):(t.prestige.Plasmid.count+=13,t.stats.plasmid+=13,Di(F("city_trick_msg",[13,F("resource_Plasmid_plural_name")]),"success",!1,["events"])),$(`#${s}${e}`).remove(),setTimeout((function(){1===e&&a&&$(".popper").hide()}),250))}))}function Mc(e,a,r,s,i,c){return t.stats.achieve[e]&&(i?t.stats.achieve[e][c]-1:t.stats.achieve[e][c])>0?`

              ${vc(r)}

              `:""}function Pc(e,a,r,s,i){a||(a=10),r||(r=bc(e,"achievement"));let c="";if(i)switch(i){case"standard":c+=Mc(e,a,r,F(t.settings.icon),s,"l");break;case"antimatter":c+=Mc(e,a,"atom",F("universe_antimatter"),s,"a");break;case"evil":c+=Mc(e,a,"evil",F("universe_evil"),s,"e");break;case"heavy":c+=Mc(e,a,"heavy",F("universe_heavy"),s,"h");break;case"micro":c+=Mc(e,a,"micro",F("universe_micro"),s,"m");break;case"magic":c+=Mc(e,a,"magic",F("universe_magic"),s,"mg")}else c+=Mc(e,a,r,F(t.settings.icon),s,"l"),c+=Mc(e,a,"atom",F("universe_antimatter"),s,"a"),c+=Mc(e,a,"evil",F("universe_evil"),s,"e"),c+=Mc(e,a,"heavy",F("universe_heavy"),s,"h"),c+=Mc(e,a,"micro",F("universe_micro"),s,"m"),c+=Mc(e,a,"magic",F("universe_magic"),s,"mg");return c}function Oc(e,t){return(t=t||{})[e]?t[e]:e<=1?1:t[e]=Oc(e-1,t)+Oc(e-2,t)}function Cc(e){var t=Object.keys(e);return t[t.length*Math.random()<<0]}function jc(e){switch(e){case 1:return F("basic");case 2:return F("plain");case 3:return F("bronze");case 4:return F("silver");case 5:return F("gold");default:return""}}function Sc(e,a){let r=0;if(a)Object.keys(a.ascended).forEach((function(e){r+=a.ascended[e]}));else if(t.stats.achieve.ascended)for(let e=0;e=1&&(s+=t.stats.achieve.technophobe.l);let i=0;for(let t=0;t=0&&(i>s&&(a-=s-i),i++),r-=a}return r}function Fc(){t.stats.reset++,t.stats.tdays+=t.stats.days,t.stats.days=0,t.stats.tknow+=t.stats.know,t.stats.know=0,t.stats.tstarved+=t.stats.starved,t.stats.starved=0,t.stats.tdied+=t.stats.died,t.stats.died=0,t.stats.tsac+=t.stats.sac,t.stats.sac=0,t.stats.tcattle+=t.stats.cattle,t.stats.cattle=0,t.stats.tmurders+=t.stats.murders,t.stats.murders=0,t.stats.tpsykill+=t.stats.psykill,t.stats.psykill=0}function zc(e){if(null===e||"object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());if(Array.isArray(e)){var t=[];return e.forEach((function(e){t.push(zc(e))})),t}let a=new e.constructor;for(var r in e)e.hasOwnProperty(r)&&(a[r]=zc(e[r]));return a}function Ac(e,a,r){switch(e){case"reverse":{let e=a.toLowerCase().split("").reverse().join("");return e.charAt(0).toUpperCase()+e.slice(1)}case"name":return Tc("fool",2021)?Ac("reverse",di[t.race.species].name):di[t.race.species].name;case"curve":return 1-(1-a)**(r||1.5)}return!1}function Tc(e,a){switch(e){case"easter":return Ec();case"halloween":return Ic();case"fool":{const e=new Date;return!(t.settings.boring||3!==e.getMonth()||1!==e.getDate()||a&&e.getFullYear()!==a)}case"launch_day":{const e=new Date;return!t.settings.boring&&4===e.getMonth()&&6===e.getDate()}case"summer":{const e=new Date;return!t.settings.boring&&5===e.getMonth()&&[20,21,22].includes(e.getDate())?(t.city.hasOwnProperty("foundry")&&!t.city.foundry.hasOwnProperty("Thermite")&&(t.city.foundry.Thermite=0),t.resource.hasOwnProperty("Thermite")||(t.resource.Thermite={name:F("resource_Thermite_name"),display:!1,value:0,amount:0,crates:0,diff:0,delta:0,max:-1,rate:0}),!0):(t.city.hasOwnProperty("foundry")&&t.city.foundry.hasOwnProperty("Thermite")&&(t.city.foundry.crafting-=t.city.foundry.Thermite,t.civic.craftsman.workers-=t.city.foundry.Thermite,t.civic[t.civic.d_job].workers+=t.city.foundry.Thermite,delete t.city.foundry.Thermite),!1)}case"firework":{const e=new Date;if(!t.settings.boring&&6===e.getMonth()&&[1,2,3,4].includes(e.getDate())){let e=t.race.cataclysm||t.race.orbit_decayed?"space":"city";return t[e].hasOwnProperty("firework")||(t[e].firework={count:0,on:0}),!0}return(t.city.hasOwnProperty("firework")||t.space.hasOwnProperty("firework"))&&(delete t.city.firework,delete t.space.firework),!1}}return!1}function Ec(){const e=new Date;let a=e.getFullYear();t.special.egg.hasOwnProperty(a)||(t.special.egg[a]={egg1:!1,egg2:!1,egg3:!1,egg4:!1,egg5:!1,egg6:!1,egg7:!1,egg8:!1,egg9:!1,egg10:!1,egg11:!1,egg12:!1}),t.special.egg.hasOwnProperty(a)&&!t.special.egg[a].hasOwnProperty("egg13")&&(t.special.egg[a].egg13=!1,t.special.egg[a].egg14=!1,t.special.egg[a].egg15=!1),t.special.egg.hasOwnProperty(a)&&!t.special.egg[a].hasOwnProperty("egg16")&&(t.special.egg[a].egg16=!1,t.special.egg[a].egg17=!1,t.special.egg[a].egg18=!1);let r=Math.floor,s=a%19,i=r(a/100),c=(i-r(i/4)-r((8*i+13)/25)+19*s+15)%30,o=c-r(c/28)*(1-r(29/(c+1))*r((21-s)/11)),n=o-(a+r(a/4)+o+2-i+r(i/4))%7,l=3+r((n+40)/44),u=n+28-31*r(l/4),d={date:[l-1,u],active:!1,endDate:[l-1,u],hint:!1,hintDate:[l-1,u],solve:!1,solveDate:[l-1,u]};return t.settings.boring||(d.endDate[1]+=10,(2===d.endDate[0]&&d.endDate[1]>31||3===d.endDate[0]&&d.endDate[1]>30)&&(d.endDate[1]-=2===d.endDate[0]?31:30,d.endDate[0]++),d.hintDate[1]+=1,(2===d.hintDate[0]&&d.hintDate[1]>31||3===d.hintDate[0]&&d.hintDate[1]>30)&&(d.hintDate[1]-=2===d.hintDate[0]?31:30,d.hintDate[0]++),d.solveDate[1]+=3,(2===d.solveDate[0]&&d.solveDate[1]>31||3===d.solveDate[0]&&d.solveDate[1]>30)&&(d.solveDate[1]-=2===d.solveDate[0]?31:30,d.solveDate[0]++),e.getMonth()>=d.date[0]&&e.getDate()>=d.date[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.active=!0,e.getMonth()>=d.hintDate[0]&&e.getDate()>=d.hintDate[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.hint=!0),e.getMonth()>=d.solveDate[0]&&e.getDate()>=d.solveDate[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.solve=!0))),d}function Ic(){const e=new Date;let a=e.getFullYear();t.special.trick.hasOwnProperty(a)||(t.special.trick[a]={trick1:!1,trick2:!1,trick3:!1,trick4:!1,trick5:!1,trick6:!1,trick7:!1,treat1:!1,treat2:!1,treat3:!1,treat4:!1,treat5:!1,treat6:!1,treat7:!1});let r={date:[9,28],active:!1,endDate:[10,4],hint:!1,hintDate:[9,29],solve:!1,solveDate:[9,31]};if(t.settings.boring)return r;let s=new Date(`${r.date[0]+1}/${r.date[1]}/${a}`),i=new Date(`${r.endDate[0]+1}/${r.endDate[1]}/${a}`);return e>=s&&e<=i&&(r.active=!0,e>=new Date(`${r.hintDate[0]+1}/${r.hintDate[1]}/${a}`)&&e<=i&&(r.hint=!0),e>=new Date(`${r.solveDate[0]+1}/${r.solveDate[1]}/${a}`)&&e<=i&&(r.solve=!0)),r}function Kc(){return t.race.magnificent&&t.city.hasOwnProperty("shrine")&&t.city.shrine.count>0}function Lc(e){let a={mult:1,add:0};if(Kc())switch(e){case"metal":a.mult+=+t.city.shrine.metal/100*ui.magnificent.vars()[3];break;case"tax":a.mult+=+t.city.shrine.tax/100*ui.magnificent.vars()[2];break;case"know":a.add+=+t.city.shrine.know*ui.magnificent.vars()[0],a.mult+=+t.city.shrine.know*ui.magnificent.vars()[1]/100;break;case"morale":a.add+=t.city.shrine.morale*ui.magnificent.vars()[4]}return a}const Nc={promiscuous:!1,revive:!1,fast_growth:!1,spores:!1,terrifying:!1,fibroblast:!0,hivemind:!0,imitation:!0,elusive:!0,chameleon:!0,blood_thirst:!0,selenophobia:!0,hooved:!0,anthropophagite:!0,unfathomable:!1,darkness:!1,living_tool:!1};function Dc(e,a){let r=ui[e].hasOwnProperty("vars")?ui[e].vars(a):[];return Nc.hasOwnProperty(e)&&("fibroblast"===e?r=[5*r[0]]:"hivemind"===e&&t.race.high_pop?r=[r[0]*ui.high_pop.vars()[0]]:"imitation"===e?r.push(di[t.race.srace||"protoplasm"].name):"elusive"===e?r=[Math.round(100*(1/30/(1/(30+r[0]))-1))]:"chameleon"===e?r=[r[0],Math.round(100*(1/30/(1/(30+r[1]))-1))]:"blood_thirst"===e?r=[Math.ceil(Math.log2(r[0]))]:"selenophobia"===e?r=[14-r[0],r[0]]:"hooved"===e?r.unshift(Bc()):"anthropophagite"===e?r=[1e4*r[0]]:Nc[e]||(r=[])),r}function Bc(e){return t.race.sludge?e?"craft":F("resource_Beaker_name"):"cath"===t.race.species?e?"craft":F("resource_Box_name"):"wolven"===t.race.species?e?"craft":F("resource_ChewToy_name"):"dracnid"===t.race.species?e?"craft":F("resource_Hoard_name"):"seraph"===t.race.species?e?"forge":F("resource_Halo_name"):"cyclops"===t.race.species?e?"craft":F("resource_Monocle_name"):"kobold"===t.race.species?e?"craft":F("resource_Candle_name"):"tuskin"===t.race.species?e?"craft":F("resource_Goggles_name"):"sharkin"===t.race.species?e?"craft":F("resource_ToothSharpener_name"):"humanoid"===di[t.race.species].type?e?"craft":F("resource_Sandals_name"):"avian"===di[t.race.species].type?e?"craft":F("resource_Perch_name"):"plant"===di[t.race.species].type?e?"craft":F("resource_Planter_name"):"fungi"===di[t.race.species].type?e?"craft":F("resource_DampCloth_name"):"reptilian"===di[t.race.species].type?e?"craft":F("resource_HeatRock_name"):"fey"===di[t.race.species].type?e?"craft":F("resource_PixieDust_name"):"synthetic"===di[t.race.species].type?e?"craft":F("resource_Battery_name"):e?"forge":F("resource_Horseshoe_name")}const Gc={infiltrator:[F("wiki_trait_effect_infiltrator_ex1"),F("wiki_trait_effect_infiltrator_ex2",[[`${F("tech_steel")}`,`${F("tech_electricity")}`,`${F("tech_electronics")}`,`${F("tech_fission")}`,`${F("tech_rocketry")}`,`${F("tech_artificial_intelligence")}`,`${F("tech_quantum_computing")}`,`${F("tech_virtual_reality")}`,`${F("tech_shields")}`,`${F("tech_ai_core")}`,`${F("tech_graphene_processing")}`,`${F("tech_nanoweave")}`,`${F("tech_orichalcum_analysis")}`,`${F("tech_infernium_fuel")}`].join(", ")])],heavy:[F("wiki_trait_effect_heavy_ex1",[Rc("Stone"),Rc("Cement"),Rc("Wrought_Iron")])],sniper:[F("wiki_trait_effect_sniper_ex1")],hooved:[F("wiki_trait_effect_hooved_ex1",[Bc(!1)]),F("wiki_trait_effect_hooved_ex2",[`${t.resource.hasOwnProperty("Lumber")?t.resource.Lumber.name:F("resource_Lumber_name")}`,`${t.resource.hasOwnProperty("Copper")?t.resource.Copper.name:F("resource_Copper_name")}`,`${t.resource.hasOwnProperty("Iron")?t.resource.Iron.name:F("resource_Iron_name")}`,`${t.resource.hasOwnProperty("Steel")?t.resource.Steel.name:F("resource_Steel_name")}`,`${t.resource.hasOwnProperty("Adamantite")?t.resource.Adamantite.name:F("resource_Adamantite_name")}`,`${t.resource.hasOwnProperty("Orichalcum")?t.resource.Orichalcum.name:F("resource_Orichalcum_name")}`,12,75,150,500,5e3]),F("wiki_trait_effect_hooved_ex3"),F("wiki_trait_effect_hooved_ex4",['5',Bc(!1)]),F("wiki_trait_effect_hooved_ex5",[`${t.resource.hasOwnProperty("Lumber")?t.resource.Lumber.name:F("resource_Lumber_name")}`,`${t.resource.hasOwnProperty("Copper")?t.resource.Copper.name:F("resource_Copper_name")}`])],instinct:[F("wiki_trait_effect_instinct_ex1",[6.67,F("galaxy_chthonian"),10])],logical:[F("wiki_trait_effect_logical_ex1",[t.tech.hasOwnProperty("science")?t.tech.science:0,t.tech.hasOwnProperty("high_tech")?t.tech.high_tech:0])],high_pop:[F("wiki_trait_effect_high_pop_ex1")],flier:[F("wiki_trait_effect_flier_ex1")],unfathomable:[F("wiki_trait_effect_unfathomable_ex1"),F("wiki_trait_effect_unfathomable_ex2")]};function Rc(e){return`${t.hasOwnProperty("resource")&&t.resource.hasOwnProperty(e)?t.resource[e].name:F(`resource_${e}_name`)}`}function Hc(e,a,r){let s=r.fanatic||!1,i=r.tpage||!1,c=r.trank||!1,o=r.wiki||!1,n="",l=Oi("name",a),u=Oi("desc",a);i&&["genus","major"].includes(ui[a].type)&&(n=`«${F("wiki_trait_rank")} {{ rank }}»`),o&&e.append(`

              ${l}

              ${n}
              `),o&&(i&&ui[a].hasOwnProperty("val")?e.append(`
              ${F(`wiki_trait_${ui[a].type}`)}${F("wiki_trait_value",[ui[a].val])}
              `):e.append(`
              ${F(`wiki_trait_${ui[a].type}`)}
              `)),s&&o&&e.append(`
              ${F("wiki_trait_fanaticism",[s])}
              `),e.append(`
              ${u}
              `);let d="warning";if(ui[a].hasOwnProperty("val")&&(d=ui[a].val>=0?"success":"danger"),i&&["genus","major"].includes(ui[a].type)?e.append(`
              `):(o||t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0)&&e.append(`
              ${F(`wiki_trait_effect_${a}`,Dc(a,c))}
              `),Gc[a]&&o&&Gc[a].forEach((function(t){e.append(`
              ${t}
              `)})),i&&["genus","major"].includes(ui[a].type)){let e={rank:t.race[a]||1};sc({el:`#${ui[a].type}_${a}`,data:e,methods:{getTraitDesc:e=>F(`wiki_trait_effect_${a}`,Dc(a,e)),up(){switch(e.rank){case.25:e.rank=.5;break;case.5:e.rank=1;break;case 1:e.rank=2;break;case 2:case 3:e.rank=3}},down(){switch(e.rank){case.25:case.5:e.rank=.25;break;case 1:e.rank=.5;break;case 2:e.rank=1;break;case 3:e.rank=2}}}})}}const Uc={misc:["apocalypse","ascended","dreaded","anarchist","second_evolution","blackhole","warmonger","red_tactics","pacifist","neutralized","paradise","scrooge","madagascar_tree","godwin","laser_shark","infested","mass_starvation","colonist","world_domination","illuminati","syndicate","cult_of_personality","doomed","pandemonium","blood_war","landfill","seeder","miners_dream","shaken","blacken_the_sun","trade","resonance","enlightenment","gladiator","corrupted","red_dead"],species:["mass_extinction","extinct_human","extinct_elven","extinct_orc","extinct_cath","extinct_wolven","extinct_vulpine","extinct_centaur","extinct_rhinotaur","extinct_capybara","extinct_kobold","extinct_goblin","extinct_gnome","extinct_ogre","extinct_cyclops","extinct_troll","extinct_tortoisan","extinct_gecko","extinct_slitheryn","extinct_arraak","extinct_pterodacti","extinct_dracnid","extinct_entish","extinct_cacti","extinct_pinguicula","extinct_sporgar","extinct_shroomi","extinct_moldling","extinct_mantis","extinct_scorpid","extinct_antid","extinct_sharkin","extinct_octigoran","extinct_dryad","extinct_satyr","extinct_phoenix","extinct_salamander","extinct_yeti","extinct_wendigo","extinct_tuskin","extinct_kamel","extinct_balorg","extinct_imp","extinct_seraph","extinct_unicorn","extinct_synth","extinct_nano","extinct_ghast","extinct_shoggoth","extinct_junker","extinct_sludge","extinct_custom"],genus:["creator","genus_humanoid","genus_carnivore","genus_herbivore","genus_small","genus_giant","genus_reptilian","genus_avian","genus_insectoid","genus_plant","genus_fungi","genus_aquatic","genus_fey","genus_heat","genus_polar","genus_sand","genus_demonic","genus_angelic","genus_synthetic","genus_eldritch"],planet:["explorer","biome_grassland","biome_oceanic","biome_forest","biome_desert","biome_volcanic","biome_tundra","biome_savanna","biome_swamp","biome_ashland","biome_taiga","biome_hellscape","biome_eden","atmo_toxic","atmo_mellow","atmo_rage","atmo_stormy","atmo_ozone","atmo_magnetic","atmo_trashed","atmo_elliptical","atmo_flare","atmo_dense","atmo_unstable","atmo_permafrost","atmo_retrograde"],universe:["vigilante","squished","double_density","cross","macro","marble","heavyweight","whitehole","heavy","canceled","eviltwin","microbang","pw_apocalypse","fullmetal","pass","soul_sponge","nightmare"],challenge:["joyless","steelen","dissipated","technophobe","wheelbarrow","iron_will","failed_history","banana","pathfinder","ashanddust","exodus","obsolete","bluepill","retired","gross","lamentis","overlord","adam_eve"]},Wc={colonist:[Ac("name")]},Qc={trade:[750,50]},Zc={};Object.keys(Uc).forEach((function(e){Uc[e].forEach((t=>Zc[t]={name:F(`achieve_${t}_name`),desc:Qc[t]?F(`achieve_${t}_desc`,Qc[t]):F(`achieve_${t}_desc`),flair:Wc[t]?F(`achieve_${t}_flair`,Wc[t]):F(`achieve_${t}_flair`),type:e}))}));const Vc={utopia:{name:F("feat_utopia_name"),desc:F("feat_utopia_desc"),flair:F("feat_utopia_flair")},take_no_advice:{name:F("feat_take_no_advice_name"),desc:F("feat_take_no_advice_desc"),flair:F("feat_take_no_advice_flair")},ill_advised:{name:F("feat_ill_advised_name"),desc:F("feat_ill_advised_desc"),flair:F("feat_ill_advised_flair")},organ_harvester:{name:F("feat_organ_harvester_name"),desc:F("feat_organ_harvester_desc"),flair:F("feat_organ_harvester_flair")},the_misery:{name:F("feat_the_misery_name"),desc:F("feat_the_misery_desc"),flair:F("feat_the_misery_flair")},energetic:{name:F("feat_energetic_name"),desc:F("feat_energetic_desc"),flair:F("feat_energetic_flair")},garbage_pie:{name:F("feat_garbage_pie_name"),desc:F("feat_garbage_pie_desc"),flair:F("feat_garbage_pie_flair")},finish_line:{name:F("feat_finish_line_name"),desc:F("feat_finish_line_desc"),flair:F("feat_finish_line_flair")},blank_slate:{name:F("feat_blank_slate_name"),desc:F("feat_blank_slate_desc"),flair:F("feat_blank_slate_flair")},supermassive:{name:F("feat_supermassive_name"),desc:F("feat_supermassive_desc"),flair:F("feat_supermassive_flair")},steelem:{name:F("feat_steelem_name"),desc:F("feat_steelem_desc"),flair:F("feat_steelem_flair")},banana:{name:F("feat_banana_name"),desc:F("feat_banana_desc",[500,500]),flair:F("feat_banana_flair")},rocky_road:{name:F("feat_rocky_road_name"),desc:F("feat_rocky_road_desc"),flair:F("feat_rocky_road_flair")},demon_slayer:{name:F("feat_demon_slayer_name"),desc:F("feat_demon_slayer_desc"),flair:F("feat_demon_slayer_flair")},equilibrium:{name:F("feat_equilibrium_name"),desc:F("feat_equilibrium_desc"),flair:F("feat_equilibrium_flair")},digital_ascension:{name:F("feat_digital_ascension_name"),desc:F("feat_digital_ascension_desc"),flair:F("feat_digital_ascension_flair")},novice:{name:F("feat_novice_name"),desc:F("feat_achievement_hunter_desc",[10]),flair:F("feat_novice_flair")},journeyman:{name:F("feat_journeyman_name"),desc:F("feat_achievement_hunter_desc",[25]),flair:F("feat_journeyman_flair")},adept:{name:F("feat_adept_name"),desc:F("feat_achievement_hunter_desc",[50]),flair:F("feat_adept_flair")},master:{name:F("feat_master_name"),desc:F("feat_achievement_hunter_desc",[75]),flair:F("feat_master_flair")},grandmaster:{name:F("feat_grandmaster_name"),desc:F("feat_achievement_hunter_desc",[100]),flair:F("feat_grandmaster_flair")},nephilim:{name:F("feat_nephilim_name"),desc:F("feat_nephilim_desc"),flair:F("feat_nephilim_flair")},twisted:{name:F("feat_twisted_name"),desc:F("feat_twisted_desc"),flair:F("feat_twisted_flair")},slime_lord:{name:F("feat_slime_lord_name"),desc:F("feat_slime_lord_desc"),flair:F("feat_slime_lord_flair")},annihilation:{name:F("feat_annihilation_name"),desc:F("feat_annihilation_desc"),flair:F("feat_annihilation_flair")},friday:{name:F("feat_friday_name"),desc:F("feat_friday_desc"),flair:F("feat_friday_flair")},valentine:{name:F("feat_love_name"),desc:F("feat_love_desc"),flair:F("feat_love_flair")},leprechaun:{name:F("feat_leprechaun_name"),desc:F("feat_leprechaun_desc"),flair:F("feat_leprechaun_flair")},easter:{name:F("feat_easter_name"),desc:F("feat_easter_desc"),flair:F("feat_easter_flair")},egghunt:{name:F("feat_egghunt_name"),desc:F("feat_egghunt_desc"),flair:F("feat_egghunt_flair")},launch_day:{name:F("feat_launch_day_name"),desc:F("feat_launch_day_desc"),flair:F("feat_launch_day_flair")},solstice:{name:F("feat_solstice_name"),desc:F("feat_solstice_desc"),flair:F("feat_solstice_flair")},firework:{name:F("feat_firework_name"),desc:F("feat_firework_desc"),flair:F("feat_firework_flair")},halloween:{name:F("feat_boo_name"),desc:F("feat_boo_desc"),flair:F("feat_boo_flair")},trickortreat:{name:F("feat_trickortreat_name"),desc:F("feat_trickortreat_desc"),flair:F("feat_trickortreat_flair")},thanksgiving:{name:F("feat_gobble_gobble_name"),desc:F("feat_gobble_gobble_desc"),flair:F("feat_gobble_gobble_flair")},xmas:{name:F("feat_xmas_name"),desc:F("feat_xmas_desc"),flair:F("feat_xmas_flair")},fool:{name:F("feat_fool_name"),desc:F("feat_fool_desc"),flair:F("feat_fool_flair")}};{let e=Jc();e.aLvl,e.uLvl}function Jc(e){let a=Yc(e=e||t.race.universe),r=0,s=0;return Object.keys(Zc).forEach((function(e){t.stats.achieve[e]&&(r+=t.stats.achieve[e].l>5?5:t.stats.achieve[e].l,t.stats.achieve[e][a]&&(s+=t.stats.achieve[e][a]>5?5:t.stats.achieve[e][a]))})),{aLvl:r,uLvl:s}}function Yc(e){switch(e=e||t.race.universe){case"evil":return"e";case"antimatter":return"a";case"heavy":return"h";case"micro":return"m";case"magic":return"mg";default:return"l"}}function Xc(e,a,r,s){if("micro"!==t.race.universe&&!0===a)return!1;t.settings.msgFilters.achievements.unlocked||(t.settings.msgFilters.achievements.unlocked=!0,t.settings.msgFilters.achievements.vis=!0);let i=ro(),c=!1,o=!1;(void 0===r||r>i)&&(r=i);let n=!0;if(void 0===t.stats.achieve[e]&&(t.stats.achieve[e]={l:0},n=!1),("micro"===t.race.universe&&!0===a||"micro"!==t.race.universe&&!0!==a)&&t.stats.achieve[e]&&t.stats.achieve[e].ls)&&(r=s),!t.stats.feat[e]||t.stats.feat[e]&&t.stats.feat[e]5?5:t.stats.achieve[e].l,t.stats.achieve[e][o]&&(c+=t.stats.achieve[e][o]>5?5:t.stats.achieve[e][o]);let s=Pc(e,16,l,n);n&&t.stats.achieve[e].l>1||!n?a.append($(`
              ${Zc[e].name}${Zc[e].desc}${s}
              `)):n&&1===t.stats.achieve[e].l&&r--}})),n&&!t.stats.feat.fool){let e=$(`
              ${Vc.fool.name}${F("feat_fool_spoof")}
              `);a.append(e)}else Object.keys(Vc).forEach((function(e){let r=bc(e,"feat");if(t.stats.feat[e]){let s=t.stats.feat[e]>1?`

              ${vc(r)}

              `:"";if("easter"===e){let e=$c(4,14);e.length>0&&(s=e)}a.append($(`
              ${Vc[e].name}${Vc[e].desc}${s}
              `))}}));let l=kc(5,12,!1);a.prepend(`
              ${F("achieve_draw_achieve_earned",[r,s])}${l}
              `),sc({el:"#achievePanel",methods:{flair:e=>Zc[e].flair,feat:e=>Vc[e].flair}}),n&&!t.stats.feat.fool&&$("#thefool").on("mouseover",(function(){"micro"===t.race.universe?eo("fool",!0):eo("fool"),to()}))}function ao(){let e=ro();$("#topBar span.flair")&&rc($("#topBar span.flair"),!0);let a=$c(1,14);if(a.length>0&&$("#topBar .planet").after($(a)),e>1&&0===$("#topBar .planet .flair").length){if(0===a.length){let t=bc("topbar","challenge");$("#topBar .planet").after(`${vc(t)}`)}let r="";t.race.no_plasmid&&(r+=`
              ${F("evo_challenge_plasmid")}
              `),t.race.weak_mastery&&(r+=`
              ${F("evo_challenge_mastery")}
              `),t.race.no_trade&&(r+=`
              ${F("evo_challenge_trade")}
              `),t.race.no_craft&&(r+=`
              ${F("evo_challenge_craft")}
              `),t.race.no_crispr&&(r+=`
              ${F("evo_challenge_crispr")}
              `),t.race.nerfed&&(r+=`
              ${F("evo_challenge_nerfed")}
              `),t.race.badgenes&&(r+=`
              ${F("evo_challenge_badgenes")}
              `),r.length>0&&$("#topBar .planetWrap .flair").append($(`
              Active Challenge Genes
              ${r}
              `)),Ti("topbarPlanet",(function(e){let t=$('
              ');e.popper.append(t),t.append($(r))}),{elm:"#topBar .planetWrap .flair",classes:"has-background-light has-text-dark"})}}function ro(){let e=1;return t.race.no_plasmid&&e++,t.race.no_trade&&e++,t.race.no_craft&&e++,t.race.no_crispr&&e++,t.race.weak_mastery&&e++,t.race.nerfed&&e++,t.race.badgenes&&e++,e>5&&(e=5),e}function so(){let e=ro();for(let a=e;a>=0;a--)io("extinct_","mass_extinction",25,a),"evil"===t.race.universe&&co("extinct_","vigilante",12,a),io("genus_","creator",9,a),io("biome_","explorer",6,a),"heavy"===t.race.universe&&co("genus_","heavyweight",8,a);if(t.tech.supercollider&&t.tech.supercollider>=99&&Xc("blackhole"),t.stats.starved>=100&&Xc("mass_starvation"),Math.round(Math.log2(t.civic.garrison.protest+t.civic.garrison.fatigue))>=8&&Xc("warmonger"),t.stats.died>=250&&Xc("red_tactics"),t.interstellar.stellar_engine&&t.interstellar.stellar_engine.mass>=12&&Xc("landfill"),t.interstellar.stellar_engine&&t.interstellar.stellar_engine.mass>=100&&eo("supermassive"),t.tech.piracy&&t.tech.chthonian&&t.tech.chthonian>=2&&t.galaxy&&1===Et("gxy_stargate")&&1===Et("gxy_gateway")&&1===Et("gxy_gorddon")&&1===Et("gxy_alien1")&&1===Et("gxy_alien2")&&1===Et("gxy_chthonian")&&Xc("neutralized"),Tc("summer")&&t.resource.hasOwnProperty("Thermite")){let e=1e5+9e3*t.stats.reset;e>1e6&&(e=1e6),t.resource.Thermite.amount>e&&eo("solstice","micro"===t.race.universe)}if(Tc("firework")&&t[t.race.cataclysm||t.race.orbit_decayed?"space":"city"].firework.on>0&&eo("firework","micro"===t.race.universe),t.city.morale.current>=200&&(Xc("paradise"),t.city.morale.current>=500&&eo("utopia")),t.resource.hasOwnProperty("Money")&&t.resource.Money.amount>=1e9&&Xc("scrooge"),t.resource.hasOwnProperty("Money")&&t.race.inflation&&t.resource.Money.amount>=25e10&&Xc("wheelbarrow"),t.civic.hasOwnProperty("govern")&&t.galaxy.hasOwnProperty("trade")&&t.city.hasOwnProperty("market")&&t.galaxy.trade.cur>=50&&t.city.market.trade>=750&&"federation"===t.civic.govern.type&&Xc("trade"),t.tech.pillars){let e={},a=0,r=5;if(Object.keys(t.pillars).forEach((function(s){di[s]&&((!e[di[s].type]||t.pillars[s]>e[di[s].type])&&(e[di[s].type]=t.pillars[s]),t.pillars[s]=Object.keys(li).length){let t=5;Object.keys(e).forEach((function(a){e[a]=Object.keys(di).length-1&&Xc("resonance"),a>=50&&eo("equilibrium",!1,r)}if(t.portal.hasOwnProperty("mechbay")&&t.tech.hasOwnProperty("hell_spire")&&t.tech.hell_spire>=9){let e=Object.keys(Ca).length,a={};Object.keys(t.stats.spire).forEach((function(r){let s={};Object.keys(t.stats.spire[r]).forEach((function(e){Ca[e]&&((!a.hasOwnProperty(e)||a[e]0&&(s[e]=t.stats.spire[r][e]))})),Object.keys(s).length===e&&Xc("gladiator",!1,Math.min(...Object.values(s)),r)})),Object.keys(a).length===e&&Xc("gladiator",!1,Math.min(...Object.values(a)),"l")}if(t.race.banana){let e=Yc();t.tech.hasOwnProperty("monuments")&&t.tech.monuments>=50&&(t.stats.banana.b5[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b5.l=!0));let a=0,r=0;["b1","b2","b3","b4","b5"].forEach((function(s){t.stats.banana[s].l&&a++,"l"!==e&&t.stats.banana[s][e]&&r++})),a>0&&Xc("banana",!1,a,"l"),r>0&&"l"!==e&&Xc("banana",!1,r,e),t.interstellar.hasOwnProperty("stellar_engine")&&t.interstellar.stellar_engine.mass>=12&&0===t.interstellar.stellar_engine.exotic&&(t.stats.banana.b3[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b3.l=!0))}["l",Yc()].forEach((function(e){let a=0;["ashanddust","exodus","obsolete","bluepill","retired"].forEach((function(r){t.stats.achieve[r]&&t.stats.achieve[r][e]&&t.stats.achieve[r][e]>=5&&a++})),a>0&&Xc("pathfinder",!1,a,e)}));const a=new Date;let r=Tc("easter"),s=Tc("halloween"),i=a.getFullYear();if(!t.settings.boring&&13===a.getDate()&&5===a.getDay()&&t.resource[t.race.species].amount>=1){let e=!1;e=eo("friday","micro"===t.race.universe),e&&t.resource[t.race.species].amount--}else if(t.settings.boring||1!==a.getMonth()||14!==a.getDate())if(t.settings.boring||2!==a.getMonth()||17!==a.getDate())if(r.active){eo("easter","micro"===t.race.universe);let e=0;for(let a=1;a<=18;a++)t.special.egg[i][`egg${a}`]&&e++;e>=12&&eo("egghunt","micro"===t.race.universe)}else if(Tc("launch_day"))eo("launch_day","micro"===t.race.universe);else if(s.active){let e=0;for(let a=1;a<=7;a++)t.special.trick[i][`trick${a}`]&&e++;for(let a=1;a<=7;a++)t.special.trick[i][`treat${a}`]&&e++;e>=12&&eo("trickortreat","micro"===t.race.universe),9===a.getMonth()&&31===a.getDate()&&eo("halloween","micro"===t.race.universe)}else!t.settings.boring&&10===a.getMonth()&&a.getDate()>=22&&a.getDate()<=28?eo("thanksgiving","micro"===t.race.universe):t.settings.boring||11!==a.getMonth()||25!=a.getDate()||eo("xmas","micro"===t.race.universe);else eo("leprechaun","micro"===t.race.universe);else eo("valentine","micro"===t.race.universe);!t.settings.boring&&3===a.getMonth()&&a.getDate()>=1&&a.getDate()<=3&&t.stats.feat.hasOwnProperty("fool")&&t.stats.feat.fool>0&&eo("fool","micro"===t.race.universe),t.stats.dkills>=666e6&&eo("demon_slayer");for(let a=e;a>=1;a--){let e=0;const r=Object.keys(Zc);for(const s of r)t.stats.achieve[s]&&t.stats.achieve[s].l>=a&&e++;let s=[{c:10,f:"novice"},{c:25,f:"journeyman"},{c:50,f:"adept"},{c:75,f:"master"},{c:100,f:"grandmaster"}];for(let r=0;r<5;r++)e>=s[r].c&&(!t.stats.feat[s[r].f]||t.stats.feat[s[r].f]=s&&i++;if(i>=r&&(Xc(a,!1,s),"standard"!==t.race.universe))switch(t.race.universe){case"evil":t.stats.achieve[a].e=void 0;break;case"antimatter":t.stats.achieve[a].a=void 0;break;case"heavy":t.stats.achieve[a].h=void 0;break;case"micro":t.stats.achieve[a].m=void 0;break;case"magic":t.stats.achieve[a].mg=void 0}}"standard"!==t.race.universe&&co(e,a,r,s)}function co(e,a,r,s){let i=!1;switch(t.race.universe){case"evil":(void 0===t.stats.achieve[a]||void 0===t.stats.achieve[a].e||t.stats.achieve[a].e=s&&i++;break;case"antimatter":t.stats.achieve[a]&&t.stats.achieve[a].a&&t.stats.achieve[a].a>=s&&i++;break;case"heavy":t.stats.achieve[a]&&t.stats.achieve[a].h&&t.stats.achieve[a].h>=s&&i++;break;case"micro":t.stats.achieve[a]&&t.stats.achieve[a].m&&t.stats.achieve[a].m>=s&&i++;break;case"magic":t.stats.achieve[a]&&t.stats.achieve[a].mg&&t.stats.achieve[a].mg>=s&&i++}i>=r&&Xc(a,!1,s)}}const oo={mastery:{name:F("mastery"),desc(){let e="";return Object.keys(ta).forEach((function(a){let r=dc(a,!0);"standard"===a?e+=`${ta[a].name}: ${F("perks_mastery_general",[`${+r.g.toFixed(2)}%`])}`:t.stats.achieve.whitehole&&(e+=`${ta[a].name}: ${F("perks_mastery_general",[`${+r.g.toFixed(2)}%`])}, ${F("perks_mastery_universe",[`${+r.u.toFixed(2)}%`])}`)})),e},active:()=>!!(t.genes.challenge&&t.genes.challenge>=2),notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_unlocked_title")}`])]},blackhole:{name:F("achieve_blackhole_name"),desc:e=>F("achieve_perks_blackhole",[e?"5/10/15/20/25":t.stats.achieve.blackhole?5*t.stats.achieve.blackhole.l:5]),active:()=>!!(t.stats.achieve.blackhole&&t.stats.achieve.blackhole.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_blackhole_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_blackhole_name")}`])]},trade:{name:F("achieve_trade_name"),desc:e=>F("achieve_perks_trade",[e?"2/4/6/8/10":t.stats.achieve.trade?2*t.stats.achieve.trade.l:2,e?"1/2/3/4/5":t.stats.achieve.trade?t.stats.achieve.trade.l:1]),active:()=>!!(t.stats.achieve.trade&&t.stats.achieve.trade.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_trade_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_trade_name")}`])]},creator:{name:F("achieve_creator_name"),desc:e=>F("achieve_perks_creator",[e?"1.5/2/2.5/3/3.5":1+(t.stats.achieve.creator?.5*t.stats.achieve.creator.l:.5)]),active:()=>!!(t.stats.achieve.creator&&t.stats.achieve.creator.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_creator_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_creator_name")}`])]},mass_extinction:{name:F("achieve_mass_extinction_name"),group:[{desc:()=>F("achieve_perks_mass_extinction"),active:()=>!!(t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>=1)},{desc(e){let a=t.stats.achieve.mass_extinction?t.stats.achieve.mass_extinction.l:1;return F("achieve_perks_mass_extinction2",[e?"0/50/100/150/200":50*(a-1)])},active:()=>!!(t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_mass_extinction_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_mass_extinction_name")}`])]},doomed:{name:F("achieve_doomed_name"),desc:e=>F("achieve_perks_doomed"),active:()=>t.stats.portals>=1,notes:[F("wiki_perks_achievement_note",[`${F("achieve_doomed_name")}`])]},explorer:{name:F("achieve_explorer_name"),desc:e=>F("achieve_perks_explorer",[e?"1/2/3/4/5":t.stats.achieve.explorer?t.stats.achieve.explorer.l:1]),active:()=>!!(t.stats.achieve.explorer&&t.stats.achieve.explorer.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_explorer_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_explorer_name")}`])]},miners_dream:{name:F("achieve_miners_dream_name"),desc:e=>F("achieve_perks_miners_dream",[e?"1/2/3/5/7":t.stats.achieve.miners_dream?t.stats.achieve.miners_dream.l>=4?2*t.stats.achieve.miners_dream.l-3:t.stats.achieve.miners_dream.l:0]),active:()=>!!(t.stats.achieve.miners_dream&&t.stats.achieve.miners_dream.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_miners_dream_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_miners_dream_name")}`])]},extinct_junker:{name:F("achieve_extinct_junker_name"),desc:()=>F("achieve_perks_enlightened"),active:()=>!!(t.stats.achieve.extinct_junker&&t.stats.achieve.extinct_junker.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_extinct_junker_name")}`])]},joyless:{name:F("achieve_joyless_name"),desc:e=>F("achieve_perks_joyless",[e?"2/4/6/8/10":t.stats.achieve.joyless?2*t.stats.achieve.joyless.l:2]),active:()=>!!(t.stats.achieve.joyless&&t.stats.achieve.joyless.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_joyless_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_joyless_name")}`])]},steelen:{name:F("achieve_steelen_name"),desc:e=>F("achieve_perks_steelen",[e?"2/4/6/8/10":t.stats.achieve.steelen?2*t.stats.achieve.steelen.l:2]),active:()=>!!(t.stats.achieve.steelen&&t.stats.achieve.steelen.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_steelen_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_steelen_name")}`])]},wheelbarrow:{name:F("achieve_wheelbarrow_name"),desc:e=>F("achieve_perks_wheelbarrow",[e?"2/4/6/8/10":t.stats.achieve.wheelbarrow?2*t.stats.achieve.wheelbarrow.l:2]),active:()=>!!(t.stats.achieve.wheelbarrow&&t.stats.achieve.wheelbarrow.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_wheelbarrow_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_wheelbarrow_name")}`])]},extinct_sludge:{name:F("achieve_extinct_sludge_name"),group:[{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.l:3,F("universe_standard")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.l>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.h:3,F("universe_heavy")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.h>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.a:3,F("universe_antimatter")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.a>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.e:3,F("universe_evil")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.e>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.m:3,F("universe_micro")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.m>=1)},{desc:e=>F("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.mg:3,F("universe_magic")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.mg>=1)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_extinct_sludge_name")}`]),F("wiki_perks_achievement_note_universe_scale",[`${F("achieve_extinct_sludge_name")}`])]},whitehole:{name:F("achieve_whitehole_name"),group:[{desc:()=>F("achieve_perks_whitehole"),active:()=>!!t.stats.achieve.whitehole},{desc:e=>F("achieve_perks_whitehole2",[e?"5/10/15/20/25":t.stats.achieve.whitehole?5*t.stats.achieve.whitehole.l:5]),active:()=>!!t.stats.achieve.whitehole},{desc:e=>F("achieve_perks_whitehole3",[e?"1/2/3/4/5":t.stats.achieve.whitehole?t.stats.achieve.whitehole.l:1]),active:()=>!!t.stats.achieve.whitehole}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_whitehole_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_whitehole_name")}`])]},heavyweight:{name:F("achieve_heavyweight_name"),desc:e=>F("achieve_perks_heavyweight",[e?"4/8/12/16/20":t.stats.achieve.heavyweight?4*t.stats.achieve.heavyweight.l:4]),active:()=>!!t.stats.achieve.heavyweight,notes:[F("wiki_perks_achievement_note",[`${F("achieve_heavyweight_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_heavyweight_name")}`])]},dissipated:{name:F("achieve_dissipated_name"),group:[{desc:()=>F("achieve_perks_dissipated1",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1)},{desc:e=>F("achieve_perks_dissipated2",[e?"1/2":t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=5?2:1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3)},{desc:()=>F("achieve_perks_dissipated3",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2)},{desc:()=>F("achieve_perks_dissipated4",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=4)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_dissipated_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_dissipated_name")}`])]},banana:{name:F("achieve_banana_name"),group:[{desc:()=>F("achieve_perks_banana1",[50]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=1)},{desc:()=>F("achieve_perks_banana2",[1]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=2)},{desc:()=>F("achieve_perks_banana3",[10]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=3)},{desc:()=>F("achieve_perks_banana4",[3]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=4)},{desc:()=>F("achieve_perks_banana5",[.01]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=5)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_banana_name")}`]),F("wiki_perks_achievement_note_task",[`${F("achieve_banana_name")}`]),F("wiki_perks_achievement_note_task_num",[1,`${F("wiki_achieve_banana1")}`]),F("wiki_perks_achievement_note_task_num",[2,`${F("wiki_achieve_banana2")}`]),F("wiki_perks_achievement_note_task_num",[3,`${F("wiki_achieve_banana3")}`]),F("wiki_perks_achievement_note_task_num",[4,`${F("wiki_achieve_banana4",[500])}`]),F("wiki_perks_achievement_note_task_num",[5,`${F("wiki_achieve_banana5",[50])}`])]},anarchist:{name:F("achieve_anarchist_name"),desc:e=>F("achieve_perks_anarchist",[e?"10/20/30/40/50":t.stats.achieve.anarchist?10*t.stats.achieve.anarchist.l:10]),active:()=>!!(t.stats.achieve.anarchist&&t.stats.achieve.anarchist.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_anarchist_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_anarchist_name")}`])]},ascended:{name:F("achieve_ascended_name"),group:[{desc(e){let a;if(e)a="1-30";else if(a=0,t.stats.achieve.ascended)for(let e=0;e!!(t.stats.achieve.ascended&&t.stats.achieve.ascended.l>=1)},{desc:()=>F("achieve_perks_ascended2",[ec()]),active:()=>!!(t.stats.achieve.ascended&&t.stats.achieve.ascended[Yc()]>=1)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_ascended_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_ascended_name")}`]),F("wiki_perks_achievement_note_universe",[`${F("achieve_ascended_name")}`])]},technophobe:{name:F("achieve_technophobe_name"),group:[{desc:()=>F("achieve_perks_technophobe1",[25]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1)},{desc(e){let a;if(e)a="10/25/30/35/40/45/50";else{a=t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=4?25:10;for(let e=1;e=5&&(a+=5)}return F("achieve_perks_technophobe2",[a])},active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2)},{desc(e){let a;if(e)a="1/2/3/4/5/6";else{a=1;for(let e=1;e=5&&(a+=1)}return F(e||a>1?"achieve_perks_technophobe3a":"achieve_perks_technophobe3",[a])},active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=3)},{desc:()=>F("achieve_perks_technophobe4",[10]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=5)},{desc:e=>F("achieve_perks_technophobe5",[e?"1/2/3/4/5":t.stats.achieve.technophobe?t.stats.achieve.technophobe.l:0]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_technophobe_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_technophobe_name")}`]),F("wiki_perks_achievement_note_universe",[`${F("achieve_technophobe_name")}`])]},iron_will:{name:F("achieve_iron_will_name"),group:[{desc:()=>F("achieve_perks_iron_will1",[.15]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1)},{desc:()=>F("achieve_perks_iron_will2",[10]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2)},{desc:()=>F("achieve_perks_iron_will3",[6]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3)},{desc:()=>F("achieve_perks_iron_will4",[1]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=4)},{desc:()=>F("achieve_perks_iron_will5"),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=5)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_iron_will_name")}`]),F("wiki_perks_achievement_note_ironwill",[`${F("evo_challenge_cataclysm")}`]),F("wiki_perks_achievement_note_ironwill2",[1,`${F("space_red_ziggurat_title")}`]),F("wiki_perks_achievement_note_ironwill3",[2,`${F("tech_elerium_mining")}`]),F("wiki_perks_achievement_note_ironwill3",[3,`${F("tech_lasers")}`]),F("wiki_perks_achievement_note_ironwill3",[4,`${F("tech_generational_ship")}`]),F("wiki_perks_achievement_note_ironwill4",[5,`${F("wiki_resets_bioseed")}`])]},failed_history:{name:F("achieve_failed_history_name"),desc:()=>F("achieve_perks_failed_history",[2]),active:()=>!!(t.stats.achieve.failed_history&&t.stats.achieve.failed_history.l>=5),notes:[F("wiki_perks_achievement_note",[`${F("achieve_failed_history_name")}`]),F("wiki_perks_achievement_note_failed_history",[`${F("evo_challenge_cataclysm")}`])]},lamentis:{name:F("achieve_lamentis_name"),group:[{desc:()=>F("achieve_perks_lamentis1",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=1)},{desc:()=>F("achieve_perks_lamentis2",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=2)},{desc:()=>F("achieve_perks_lamentis3",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=3)},{desc:()=>F("achieve_perks_lamentis4"),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=4)},{desc:()=>F("achieve_perks_lamentis5"),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_lamentis_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_lamentis_name")}`])]},soul_sponge:{name:F("achieve_soul_sponge_name"),desc:e=>F("achieve_perks_soul_sponge",[e?"100/200/300/400/500":t.stats.achieve.soul_sponge?100*t.stats.achieve.soul_sponge.mg:100]),active:()=>!!(t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_soul_sponge_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_soul_sponge_name")}`])]},nightmare:{name:F("achieve_nightmare_name"),desc:()=>F("achieve_perks_nightmare"),active:()=>!!(t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_nightmare_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_nightmare_name")}`])]},gladiator:{name:F("achieve_gladiator_name"),desc:e=>F("achieve_perks_gladiator",[e?"20/40/60/80/100":t.stats.achieve.gladiator?20*t.stats.achieve.gladiator.l:20]),active:()=>!!(t.stats.achieve.gladiator&&t.stats.achieve.gladiator.l>=1),notes:[F("wiki_perks_achievement_note",[`${F("achieve_gladiator_name")}`]),F("wiki_perks_achievement_note_scale",[`${F("achieve_gladiator_name")}`])]},pathfinder:{name:F("achieve_pathfinder_name"),group:[{desc:()=>F("achieve_perks_pathfinder1",[10]),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1)},{desc:()=>F("achieve_perks_pathfinder2",[10]),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2)},{desc:()=>F("achieve_perks_pathfinder3"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=3)},{desc:()=>F("achieve_perks_pathfinder4"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=4)},{desc:()=>F("achieve_perks_pathfinder5"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=5)}],notes:[F("wiki_perks_achievement_note",[`${F("achieve_pathfinder_name")}`]),F("wiki_perks_achievement_note_pathfinder",[`${F("evo_challenge_truepath")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_mad")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_bioseed")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_ai")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_matrix")}`]),F("wiki_perks_achievement_note_pathfinder_reset",[`${F("wiki_resets_retired")}`])]},overlord:{name:F("achieve_overlord_name"),desc(){let e=`
              ${F("achieve_perks_overlord1",[10])}
              `;return e+=`
              ${F("achieve_perks_overlord2")}
              `,e+=`
              ${F("achieve_perks_overlord3")}
              `,e+=`
              ${F("achieve_perks_overlord4")}
              `,e},active:()=>!!(t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5),notes:[F("wiki_perks_achievement_note",[`${F("achieve_overlord_name")}`])]},adam_eve:{name:F("achieve_adam_eve_name"),desc:()=>F("achieve_perks_adam_eve"),active:()=>!!(t.stats.achieve.adam_eve&&t.stats.achieve.adam_eve.l>=5),notes:[]},creep:{name:F("wiki_arpa_crispr_creep"),desc:e=>F("arpa_perks_creep",[e?"0.01/0.02/0.03/0.04/0.05":t.genes.creep?.01*t.genes.creep:0]),active:()=>!!t.genes.creep,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_genetic_memory_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_animus_title")}`,`${F("arpa_genepool_divine_remembrance_title")}`,`${F("arpa_genepool_divine_proportion_title")}`,`${F("arpa_genepool_genetic_repository_title")}`].join(", ")])]},store:{name:F("wiki_arpa_crispr_store"),desc(e){let a=e?"0.04/0.06/0.08":t.genes.store&&t.genes.store>1?2===t.genes.store?.06:.08:.04;return F(t.genes.store&&t.genes.store>=4?"arpa_perks_store2":"arpa_perks_store1",[a])},active:()=>!!t.genes.store,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_spatial_reasoning_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_spatial_superiority_title")}`,`${F("arpa_genepool_spatial_supremacy_title")}`,`${F("arpa_genepool_dimensional_warping_title")}`].join(", ")])]},evolve:{name:F("wiki_arpa_crispr_evolve"),group:[{desc:()=>F("arpa_perks_evolve"),active:()=>!!t.genes.evolve},{desc:()=>F("arpa_genepool_recombination_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=2)},{desc:()=>F("arpa_genepool_homologous_recombination_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=3)},{desc:()=>F("arpa_genepool_genetic_reshuffling_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=4)},{desc:()=>F("arpa_genepool_recombinant_dna_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=5)},{desc:()=>F("arpa_genepool_chimeric_dna_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=6)},{desc:()=>F("arpa_genepool_molecular_cloning_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=7)},{desc:()=>F("arpa_genepool_transgenes_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=8)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_morphogenesis_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_recombination_title")}`,`${F("arpa_genepool_homologous_recombination_title")}`,`${F("arpa_genepool_genetic_reshuffling_title")}`,`${F("arpa_genepool_recombinant_dna_title")}`,`${F("arpa_genepool_chimeric_dna_title")}`,`${F("arpa_genepool_molecular_cloning_title")}`,`${F("arpa_genepool_transgenes_title")}`].join(", ")])]},birth:{name:F("wiki_arpa_crispr_birth"),desc:()=>F("arpa_perks_birth"),active:()=>!!t.genes.birth,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_replication_title")}`])]},enhance:{name:F("wiki_arpa_crispr_enhance"),desc:()=>F("arpa_perks_enhance"),active:()=>!!t.genes.enhance,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_enhanced_muscle_fiber_title")}`])]},crafty:{name:F("wiki_arpa_crispr_crafty"),group:[{desc:()=>F("arpa_genepool_artificer_desc"),active:()=>!!t.genes.crafty},{desc:e=>F("arpa_genepool_crafting_desc",[e?"50/100":t.genes.crafty&&t.genes.crafty>=3?100:50]),active:()=>!!(t.genes.crafty&&t.genes.crafty>=2)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_artificer_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_detail_oriented_title")}`,`${F("arpa_genepool_rigorous_title")}`].join(", ")])]},governor:{name:F("wiki_arpa_crispr_governor"),desc:()=>F("arpa_perks_governor"),active:()=>!!t.genes.governor,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_governance_title")}`])]},synthesis:{name:F("wiki_arpa_crispr_synthesis"),desc:e=>F("arpa_genepool_synthesis_desc",[e?"2/3/4":t.genes.synthesis&&t.genes.synthesis>=2?t.genes.synthesis>=3?4:3:2,e?"10/25/50":t.genes.synthesis&&t.genes.synthesis>=2?t.genes.synthesis>=3?50:25:10]),active:()=>!!t.genes.synthesis,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_synthesis_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_karyokinesis_title")}`,`${F("arpa_genepool_cytokinesis_title")}`].join(", ")])]},challenge:{name:F("wiki_arpa_crispr_challenge"),group:[{desc:()=>F("arpa_perks_challenge"),active:()=>!!t.genes.challenge},{desc:()=>F("arpa_genepool_unlocked_desc"),active:()=>!!(t.genes.challenge&&t.genes.challenge>=2)},{desc:e=>F("arpa_perks_challenge2",[e?"60/80":t.genes.challenge&&t.genes.challenge>=4?80:60,e?"60/40":t.genes.challenge&&t.genes.challenge>=4?40:60]),active:()=>!!(t.genes.challenge&&t.genes.challenge>=3)},{desc:()=>F("arpa_perks_challenge3"),active:()=>!!(t.genes.challenge&&t.genes.challenge>=5)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_hardened_genes_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_unlocked_title")}`,`${F("arpa_genepool_universal_title")}`,`${F("arpa_genepool_standard_title")}`,`${F("arpa_genepool_mastered_title")}`].join(", ")]),F("wiki_perks_crispr_note_challenge",[F("arpa_genepool_universal_title"),F("arpa_genepool_standard_title")])]},ancients:{name:F("wiki_arpa_crispr_ancients"),group:[{desc:()=>F("arpa_perks_ancients"),active:()=>!!t.genes.ancients},{desc:()=>t.genes.ancients&&t.genes.ancients>=4?F("arpa_perks_ancients3"):F("arpa_perks_ancients2"),active:()=>!!(t.genes.ancients&&t.genes.ancients>=2)},{desc:e=>F("arpa_perks_ancients4",[e?"25/50":t.genes.ancients&&t.genes.ancients>=5?50:25]),active:()=>!!(t.genes.ancients&&t.genes.ancients>=3)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_ancients_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_faith_title")}`,`${F("arpa_genepool_devotion_title")}`,`${F("arpa_genepool_acolyte_title")}`,`${F("arpa_genepool_conviction_title")}`].join(", ")])]},trader:{name:F("wiki_arpa_crispr_trader"),desc:()=>F("arpa_genepool_negotiator_desc"),active:()=>!!t.genes.trader,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_negotiator_title")}`])]},transcendence:{name:F("wiki_arpa_crispr_transcendence"),desc:()=>F("arpa_genepool_transcendence_desc"),active:()=>!!t.genes.transcendence,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_transcendence_title")}`])]},queue:{name:F("wiki_arpa_crispr_queue"),group:[{desc:()=>F("arpa_genepool_geographer_desc"),active:()=>!!t.genes.queue},{desc:()=>F("arpa_genepool_architect_desc"),active:()=>!!(t.genes.queue&&t.genes.queue>=2)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_geographer_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_architect_title")}`].join(", ")])]},plasma:{name:F("wiki_arpa_crispr_plasma"),desc:e=>F("arpa_genepool_mitosis_desc",[e?"3/5":t.genes.plasma>=2?5:3]),active:()=>!!t.genes.plasma,notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_mitosis_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_metaphase_title")}`].join(", ")])]},mutation:{name:F("wiki_arpa_crispr_mutation"),group:[{desc:()=>t.genes.mutation&&t.genes.mutation>1?F("arpa_perks_mutation2"):F("arpa_perks_mutation1"),active:()=>!!t.genes.mutation},{desc:()=>F("arpa_perks_mutation3"),active:()=>!!(t.genes.mutation&&t.genes.mutation>=3)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_mutation_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_transformation_title")}`,`${F("arpa_genepool_metamorphosis_title")}`].join(", ")])]},bleed:{name:F("wiki_arpa_crispr_bleed"),group:[{desc:()=>F("arpa_genepool_bleeding_effect_desc",[2.5]),active:()=>!!t.genes.bleed},{desc:()=>F("arpa_genepool_synchronicity_desc",[25]),active:()=>!!(t.genes.bleed&&t.genes.bleed>=2)},{desc:()=>F("arpa_genepool_astral_awareness_desc"),active:()=>!!(t.genes.bleed&&t.genes.bleed>=3)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_bleeding_effect_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_synchronicity_title")}`,`${F("arpa_genepool_astral_awareness_title")}`].join(", ")]),F("wiki_perks_crispr_note_bleed",[`${F("arpa_genepool_bleeding_effect_title")}`])]},blood:{name:F("wiki_arpa_crispr_blood"),group:[{desc:()=>F("arpa_genepool_blood_remembrance_desc"),active:()=>!!t.genes.blood},{desc:()=>F("arpa_genepool_blood_sacrifice_desc"),active:()=>!!(t.genes.blood&&t.genes.blood>=2)},{desc:()=>F("arpa_genepool_essence_absorber_desc"),active:()=>!!(t.genes.blood&&t.genes.blood>=3)}],notes:[F("wiki_perks_crispr_note",[`${F("arpa_genepool_blood_remembrance_title")}`]),F("wiki_perks_crispr_note_upgrade",[[`${F("arpa_genepool_blood_sacrifice_title")}`,`${F("arpa_genepool_essence_absorber_title")}`].join(", ")]),F("wiki_perks_crispr_note_blood",[F("arpa_genepool_blood_remembrance_title")])]},spire:{name:F("wiki_arpa_blood_spire"),group:[{desc:()=>F("arpa_blood_purify_desc"),active:()=>!!t.blood.spire},{desc:()=>F("arpa_blood_chum_desc"),active:()=>!!(t.blood.spire&&t.blood.spire>=2)}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_purify_title")}`]),F("wiki_perks_blood_note_upgrade",[[`${F("arpa_blood_chum_title")}`].join(", ")])]},lust:{name:F("wiki_arpa_blood_lust"),group:[{desc:e=>F("arpa_perks_lust",[e?.2:.2*(t.blood.lust?t.blood.lust:1)]),active:()=>!!t.blood.lust}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_lust_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_lust_title")])]},illuminate:{name:F("wiki_arpa_blood_illuminate"),group:[{desc:e=>F("arpa_perks_illuminate",[e?.01:.01*(t.blood.illuminate?t.blood.illuminate:1)]),active:()=>!!t.blood.illuminate}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_illuminate_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_illuminate_title")])]},greed:{name:F("wiki_arpa_blood_greed"),group:[{desc:e=>F("arpa_perks_greed",[e?1:1*(t.blood.greed?t.blood.greed:1)]),active:()=>!!t.blood.greed}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_greed_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_greed_title")])]},hoarder:{name:F("wiki_arpa_blood_hoarder"),group:[{desc:e=>F("arpa_perks_hoarder",[e?1:1*(t.blood.hoarder?t.blood.hoarder:1)]),active:()=>!!t.blood.hoarder}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_hoarder_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_hoarder_title")])]},artisan:{name:F("wiki_arpa_blood_artisan"),group:[{desc:e=>F("arpa_perks_artisan",[e?1:1*(t.blood.artisan?t.blood.artisan:1)]),active:()=>!!t.blood.artisan}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_artisan_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_artisan_title")])]},attract:{name:F("wiki_arpa_blood_attract"),group:[{desc:e=>F("arpa_perks_attract",[e?5:5*(t.blood.attract?t.blood.attract:1)]),active:()=>!!t.blood.attract}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_attract_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_attract_title")])]},wrath:{name:F("wiki_arpa_blood_wrath"),group:[{desc:e=>F("arpa_perks_wrath",[e?5:5*(t.blood.wrath?t.blood.wrath:1)]),active:()=>!!t.blood.wrath}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_wrath_title")}`]),F("wiki_perks_blood_note_repeat",[F("arpa_blood_wrath_title")])]},prepared:{name:F("wiki_arpa_blood_prepared"),group:[{desc:()=>F("arpa_blood_prepared_desc"),active:()=>!!t.blood.prepared},{desc:()=>F("arpa_blood_compact_desc"),active:()=>!!(t.blood.prepared&&t.blood.prepared>=2)}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_prepared_title")}`]),F("wiki_perks_blood_note_upgrade",[[`${F("arpa_blood_compact_title")}`].join(", ")])]},unbound:{name:F("wiki_arpa_blood_unbound"),group:[{desc:()=>F("arpa_blood_unbound_desc"),active:()=>!!t.blood.unbound},{desc:()=>F("arpa_blood_shadow_war_desc"),active:()=>!!(t.blood.unbound&&t.blood.unbound>=3)},{desc:e=>F("arpa_perks_unbound_resist",[e?"10/5":t.blood.unbound&&t.blood.unbound>=4?5:10]),active:()=>!!(t.blood.unbound&&t.blood.unbound>=2)}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_unbound_title")}`]),F("wiki_perks_blood_note_upgrade",[[`${F("arpa_blood_unbound_resistance_title")}`,`${F("arpa_blood_shadow_war_title")}`,`${F("arpa_blood_unbound_immunity_title")}`].join(", ")])]},aware:{name:F("wiki_arpa_blood_aware"),group:[{desc:()=>F("arpa_blood_blood_aware_desc"),active:()=>!!t.blood.aware}],notes:[F("wiki_perks_blood_note",[`${F("arpa_blood_blood_aware_title")}`])]},harmonic:{name:F("harmonic"),group:[{desc(e){let t=_c();return F("perks_harmonic",[e?`1-${Object.keys(di).length+2}`:+(100*(t[0]-1)).toFixed(0),e?"2-"+2*(Object.keys(di).length+2):+(100*(t[1]-1)).toFixed(0)])},active(){let e=_c();return!!(t.pillars&&e[0]>1)}},{desc:e=>(_c(),F("perks_harmonic2",[F("portal_west_tower"),F("portal_east_tower"),e?"12-"+12*(Object.keys(di).length-1):12*Object.keys(t.pillars).length])),active(){let e=_c();return!!(t.pillars&&e[0]>1)}}],notes:[F("wiki_perks_harmonic_note1"),F("wiki_perks_harmonic_note2")]},novice:{name:F("perk_novice"),desc(e){let a=t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0?Math.min(t.stats.achieve.apocalypse.l,t.stats.feat.novice):1;return`
              ${F("achieve_perks_novice",[e?"0.5/1/1.5/2/2.5":a/2,e?"0.25/0.5/0.75/1/1.25":a/4])}
              ${F("achieve_perks_novice2")}
              `},active:()=>!!(t.stats.feat.novice&&t.stats.mad>0),notes:[F("wiki_perks_progress_note1",[10,F("wiki_resets_mad")]),F("wiki_perks_progress_note2")]},journeyman:{name:F("perk_journeyman"),desc(e){let a=t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0?Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman):1;return e||a>1?`
              ${F("achieve_perks_journeyman2",[e?"1/2/3":a>=3?a>=5?3:2:1,e?"1/2":a>=4?2:1])}
              ${F("achieve_perks_journeyman3")}
              `:`
              ${F("achieve_perks_journeyman1",[1])}
              ${F("achieve_perks_journeyman3")}
              `},active:()=>!!(t.stats.feat.journeyman&&t.stats.bioseed>0),notes:[F("wiki_perks_progress_note1",[25,F("wiki_resets_bioseed")]),F("wiki_perks_progress_note2")]},adept:{name:F("perk_adept"),desc(e){let a=t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0?Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept):1;return F("achieve_perks_adept",[e?"100/200/300/400/500":100*a,e?"60/120/180/240/300":60*a])},active:()=>!!(t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0),notes:[F("wiki_perks_progress_note1",[50,F("wiki_resets_blackhole")]),F("wiki_perks_progress_note2")]},master:{name:F("perk_master"),desc(e){let a=t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0?Math.min(t.stats.achieve.ascended.l,t.stats.feat.master):1;return F("achieve_perks_master",[e?"1/2/3/4/5":a,e?"2/4/6/8/10":2*a,F("evo_mitochondria_title"),F("evo_eukaryotic_title"),F("evo_membrane_title"),F("evo_organelles_title"),F("evo_nucleus_title")])},active:()=>!!(t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0),notes:[F("wiki_perks_progress_note1",[75,F("wiki_resets_ascension")]),F("wiki_perks_progress_note2")]},grandmaster:{name:F("perk_grandmaster"),desc(e){let a=t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):1;return F("achieve_perks_grandmaster",[e?"1/2/3/4/5":a])},active:()=>!!(t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0),notes:[F("wiki_perks_progress_note1",[100,F("wiki_resets_infusion")]),F("wiki_perks_progress_note2")]}};function no(){rc($("#perksPanel"));let e=$("#perksPanel"),t=!1;Object.keys(oo).forEach((function(a){if(oo[a].hasOwnProperty("group")){let r=!1,s=$(`
              ${oo[a].name}
              `);oo[a].group.forEach((function(e){e.active()&&(r=!0,s.append($(`
              ${e.desc()}
              `)))})),r&&(t=!0,e.append(s))}else oo[a].active()&&(t=!0,e.append($(`
              ${oo[a].name}${oo[a].desc()}
              `)))})),t||e.append($(`
              ${F("perks_none")}
              `))}const lo={dna_replication:{reqs:{race:"protoplasm",resource:"DNA"},type:"major",effect(){var e=Math.rand(1,Math.round(t.resource.DNA.max/3)),a=t.resource.DNA.amount+e;return a>t.resource.DNA.max&&(a=t.resource.DNA.max),t.resource.DNA.amount=a,F("event_dna",[e.toLocaleString()])}},rna_meteor:{reqs:{race:"protoplasm",resource:"RNA"},type:"major",effect(){var e=Math.rand(1,Math.round(t.resource.RNA.max/2)),a=t.resource.RNA.amount+e;return a>t.resource.RNA.max&&(a=t.resource.RNA.max),t.resource.RNA.amount=a,F("event_rna",[e.toLocaleString()])}},inspiration:{reqs:{resource:"Knowledge"},type:"major",effect:()=>(t.race.inspired=Math.rand(300,600),F("event_inspiration"))},motivation:{reqs:{tech:"primitive"},type:"major",effect:()=>(t.race.motivated=Math.rand(300,600),F("event_motivation"))},fire:{reqs:{resource:"Lumber",nogenus:"aquatic",notrait:"evil"},type:"major",effect(){var e=Math.rand(1,Math.round(t.resource.Lumber.amount/4)),a=t.resource.Lumber.amount-e;return a<0&&(a=0),t.resource.Lumber.amount=a,F("event_fire",[e.toLocaleString()])}},flare:{reqs:{tech:"primitive"},type:"major",condition:()=>!!t.city.ptrait.includes("flare"),effect(){let e=0,a=di[t.race.species].home;t.race.cataclysm||t.race.orbit_decayed?(t.space.hasOwnProperty("living_quarters")&&(e+=Math.round(c.living_quarters*Qr.space.spc_red.living_quarters.citizens())),a=di[t.race.species].solar.red):(t.city.hasOwnProperty("basic_housing")&&(e+=t.city.basic_housing.count*Qr.city.basic_housing.citizens()),t.city.hasOwnProperty("cottage")&&(e+=t.city.cottage.count*Qr.city.cottage.citizens()),t.city.hasOwnProperty("apartment")&&(e+=i.apartment*Qr.city.apartment.citizens())),e>t.resource[t.race.species].amount&&(e=t.resource[t.race.species].amount),e=Math.floor(.1*e);let r=Math.rand(0,e);if(t.resource[t.race.species].amount-=r,t.civic[t.civic.d_job].workers-=r,t.civic[t.civic.d_job].workers<0&&(t.civic[t.civic.d_job].workers=0),"oceanic"!==t.city.biome){let e=400;"forest"===t.city.biome?e*=2:"desert"!==t.city.biome&&"volcanic"!==t.city.biome||(e/=2),t.city.firestorm=Math.rand(e,10*e)}return F("oceanic"===t.city.biome?"event_flare2":"event_flare",[a,r.toLocaleString()])}},raid:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(ue("gov0")&&ue("gov1")&&ue("gov2")||t.race.truepath||t.race.cataclysm||!(t.civic.foreign.gov0.hstl>60||t.civic.foreign.gov1.hstl>60||t.civic.foreign.gov2.hstl>60)),effect(){let e=ke(qe(),"army",t.civic.garrison.wounded),a=t.tech.high_tech?t.tech.high_tech+1:1,r=Math.rand(25,50)*a,s=t.civic.garrison.wounded>qe()?qe():t.civic.garrison.wounded,i=Math.floor(m(0,s)),c=Math.floor(m(0,qe()-s));if(t.race.instinct&&(i=Math.round(i/2),c=Math.round(c/2)),t.civic.garrison.workers-=i,t.civic.garrison.wounded+=c,t.stats.died+=i,t.civic.garrison.wounded>t.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(r/5),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0])),e>r)return F("event_raid1",[i.toLocaleString(),c.toLocaleString()]);{let e=Math.rand(1,Math.round(t.resource.Money.amount/4));if(e<=0)return F("event_raid1",[i.toLocaleString(),c.toLocaleString()]);{let a=t.resource.Money.amount-e;return a<0&&(a=0),t.resource.Money.amount=a,F("event_raid2",[e.toLocaleString(),i.toLocaleString(),c.toLocaleString()])}}}},siege:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(ue("gov0")||ue("gov1")||ue("gov2"))&&!t.race.truepath&&t.civic.foreign.gov0.hstl>80&&t.civic.foreign.gov1.hstl>80&&t.civic.foreign.gov2.hstl>80,effect(){let e=ke(qe(),"army",t.civic.garrison.wounded),a=t.tech.high_tech?t.tech.high_tech+1:1,r=(t.civic.foreign.gov0.mil+t.civic.foreign.gov1.mil+t.civic.foreign.gov2.mil)*a,s=t.civic.garrison.wounded>qe()?qe():t.civic.garrison.wounded,i=Math.floor(m(0,s)),c=Math.floor(m(0,qe()-s));if(t.race.instinct&&(i=Math.round(i/2),c=Math.round(c/2)),t.civic.garrison.workers-=i,t.civic.garrison.wounded+=c,t.stats.died+=i,t.civic.garrison.wounded>t.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(r/5),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0])),e>r)return F("event_siege1",[i.toLocaleString(),c.toLocaleString()]);var o=Math.rand(1,Math.round(t.resource.Money.amount/2)),n=t.resource.Money.amount-o;return n<0&&(n=0),t.resource.Money.amount=n,F("event_siege2",[o.toLocaleString(),i.toLocaleString(),c.toLocaleString()])}},pillage0:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(!t.race.truepath||t.tech.isolation||ue("gov0")||!(t.civic.foreign.gov0.hstl>60)),effect:()=>po("gov0")},pillage1:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(!t.race.truepath||t.tech.isolation||ue("gov1")||!(t.civic.foreign.gov1.hstl>60)),effect:()=>po("gov1")},pillage2:{reqs:{tech:"military",notech:"world_control"},type:"major",condition:()=>!(!t.race.truepath||t.tech.isolation||ue("gov2")||!(t.civic.foreign.gov2.hstl>60)),effect:()=>po("gov2")},pillage3:{reqs:{tech:"military"},type:"major",condition:()=>!!(t.race.truepath&&!t.tech.isolation&&t.tech.rival&&t.civic.foreign.gov3.hstl>60),effect:()=>po("gov3",!0)},witch_hunt_crusade:{reqs:{tech:"magic"},type:"major",condition:()=>!!(t.race.witch_hunter&&t.resource.Sus.amount>=100),effect:()=>po("witchhunt",!0)},terrorist:{reqs:{tech:"world_control",notrait:"truepath"},type:"major",effect(){let e=Math.floor(m(0,t.civic.garrison.wounded)),a=Math.floor(m(0,t.civic.garrison.workers-t.civic.garrison.wounded));return t.race.instinct&&(e=Math.round(e/2),a=Math.round(a/2)),t.civic.garrison.workers-=e,t.civic.garrison.wounded+=a,t.stats.died+=e,t.civic.garrison.wounded>t.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers),t.race.blood_thirst&&(t.race.blood_thirst_count+=1e3,t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0])),0===e?F("event_terrorist1",[a.toLocaleString()]):F("event_terrorist2",[a.toLocaleString(),e.toLocaleString()])}},quake:{reqs:{tech:"wsc",notech:"quaked"},type:"major",condition:()=>!!t.city.ptrait.includes("unstable"),effect:()=>(t.tech.quaked=1,ms(),F("event_quake",[t.race.cataclysm||t.race.orbit_decayed?di[t.race.species].solar.red:di[t.race.species].home]))},doom:{reqs:{tech:"wsc",notech:"portal_guard"},type:"major",condition:()=>!!(t.space.space_barracks&&t.space.space_barracks.on>0),effect:()=>(Xc("doomed"),t.stats.portals++,F(t.race.evil?"event_doom_alt":"event_doom",[di[t.race.species].solar.dwarf]))},demon_influx:{reqs:{tech:"portal_guard"},type:"major",effect(){let e=Math.rand(2500,5e3);return t.portal.fortress.threat+=e,F("event_demon_influx",[e.toLocaleString()])}},ruins:{reqs:{trait:"ancient_ruins",resource:"Knowledge"},type:"major",effect(){let e=["Iron","Copper","Steel","Cement"];for(var a=0;at.resource[r].max?t.resource[r].amount=t.resource[r].max:t.resource[r].amount+=e}}return F("event_ruins")}},tax_revolt:{reqs:{low_morale:99,notrait:"blissful",tech:"primitive"},type:"major",condition(){let e="oligarchy"===t.civic.govern.type?45:25,a=N("aristocrat",2);return a&&(e-=a),t.civic.taxes.tax_rate>e},effect:()=>function(){let e=["Soul_Gem","Corrupt_Gem","Codex","Demonic_Essence"],a="oligarchy"===t.civic.govern.type?45:25,r=N("aristocrat",2);r&&(a-=r);let s=.04*(t.civic.taxes.tax_rate-a);return Object.keys(t.resource).forEach((function(a){if(!e.includes(a)){let e=Math.rand(1,Math.round(t.resource[a].amount*s)),r=t.resource[a].amount-e;r<0&&(r=0),t.resource[a].amount=r}})),F("event_tax_revolt")}()},slave_death1:_o("major","death1"),slave_death2:_o("major","death2"),slave_death3:_o("major","death3"),protest:{reqs:{tech:"primitive"},type:"major",condition:()=>"republic"===t.civic.govern.type,effect(){switch(t.civic.govern.protest=Math.rand(30,60),Math.rand(0,10)){case 0:return F("event_protest0",[Is("small")]);case 1:return F("event_protest1");case 2:return F("event_protest2");case 3:return t.civic.govern.protest=Math.rand(45,75),F("event_protest3");case 4:return F("event_protest4");case 5:return t.civic.govern.protest=Math.rand(45,75),F("event_protest5");case 6:return F("event_protest6");case 7:return F("event_protest7");case 8:return F("event_protest8");case 9:return t.civic.govern.protest=Math.rand(60,90),F("event_protest9")}}},scandal:{reqs:{tech:"govern"},type:"major",condition:()=>!!N("muckraker",0),effect(){switch(t.civic.govern.scandal=Math.rand(15,90),Math.rand(0,10)){case 0:return F("event_scandal0");case 1:return F("event_scandal1");case 2:return F("event_scandal2");case 3:return F("event_scandal3");case 4:return F("event_scandal4");case 5:return F("event_scandal5");case 6:return F("event_scandal6");case 7:return F("event_scandal7");case 8:return F("event_scandal8");case 9:return F("event_scandal9")}}},spy:{reqs:{tech:"primitive",notech:"world_control"},type:"major",condition(){if(t.race.elusive)return!1;if(Pi("satyr")>.25)return!1;for(let e=0;e<3;e++)if(t.civic.foreign[`gov${e}`].spy>0&&!t.civic.foreign[`gov${e}`].occ&&!t.civic.foreign[`gov${e}`].anx&&!t.civic.foreign[`gov${e}`].buy)return!0;return!1},effect(){let e=[];for(let a=0;a<3;a++)t.civic.foreign[`gov${a}`].spy>0&&!t.civic.foreign[`gov${a}`].occ&&!t.civic.foreign[`gov${a}`].anx&&!t.civic.foreign[`gov${a}`].buy&&e.push(a);let a=e[Math.rand(0,e.length)];return t.civic.foreign[`gov${a}`].spy--,0===t.civic.foreign[`gov${a}`].spy&&(t.civic.foreign[`gov${a}`].act="none",t.civic.foreign[`gov${a}`].sab=0),F("event_spy",[ee(a)])}},mine_collapse:{reqs:{tech:"mining"},type:"major",condition:()=>t.resource[t.race.species].amount>0&&t.civic.miner.workers>0,effect:()=>(t.resource[t.race.species].amount--,t.civic.miner.workers--,F("event_mine_collapse"))},m_curious:{reqs:{tech:"primitive",trait:"curious"},condition:()=>t.resource[t.race.species].amount>=40,type:"major",effect(){switch(Math.rand(0,5)){case 0:{let e="Money",a=Math.rand(5e4,5e6);switch(Math.rand(0,5)){case 0:t.resource.Steel.display&&(e="Steel",a=Math.rand(100,1e5));break;case 1:t.resource.Bolognium.display&&(e="Bolognium",a=Math.rand(500,5e4));break;case 2:t.resource.Alloy.display&&(e="Alloy",a=Math.rand(250,1e6));break;case 3:t.resource.Adamantite.display&&(e="Adamantite",a=Math.rand(1e3,25e4));break;case 4:t.resource.Soul_Gem.display&&(e="Soul_Gem",a=1)}return t.resource[e].amount+=a,t.resource[e].max>=0&&t.resource[e].amount>t.resource[e].max&&(t.resource[e].amount=t.resource[e].max),F("event_m_curious0","Money"===e?[di[t.race.species].name,"$",a.toLocaleString()]:[di[t.race.species].name,a.toLocaleString(),t.resource[e].name])}case 1:return t.resource[t.race.species].amount-=10,t.civic[t.civic.d_job].workers-=10,t.civic[t.civic.d_job].workers<0&&(t.civic[t.civic.d_job].workers=0),F("event_m_curious1",[di[t.race.species].name]);case 2:return t.race.inspired=Math.rand(600,1200),F("event_m_curious2",[di[t.race.species].name]);case 3:return t.race.distracted=Math.rand(200,600),F("event_m_curious3",[di[t.race.species].name]);case 4:return"cath"===t.race.species?(t.race.stimulated=Math.rand(500,1e3),F("event_m_curious4a",[di[t.race.species].name])):F("event_m_curious4b",[di[t.race.species].name])}}},curious1:{reqs:{tech:"primitive",trait:"curious"},type:"minor",effect:()=>F(`event_curious${Math.rand(0,5)}`,[di[t.race.species].name])},curious2:{reqs:{tech:"primitive",trait:"curious"},type:"minor",effect:()=>F(`event_curious${Math.rand(5,10)}`,[di[t.race.species].name])},slave_escape1:_o("minor","escape1"),slave_escape2:_o("minor","escape2"),slave_escape3:_o("minor","death4"),shooting_star:uo("shooting_star","primitive"),tumbleweed:uo("tumbleweed","primitive"),flashmob:uo("flashmob","high_tech"),witch_hunt:{reqs:{tech:"magic"},type:"minor",condition:()=>!!(t.race.witch_hunter&&t.resource.Sus.amount>=50&&t.civic.scientist.workers>0),effect:()=>(t.resource[t.race.species].amount--,t.civic.scientist.workers--,t.civic.scientist.assigned--,F("witch_hunter_witch_hunt"))},heatwave:{reqs:{tech:"primitive"},type:"minor",condition:()=>!t.race.cataclysm&&!t.race.orbit_decayed&&2!==t.city.calendar.temp,effect:()=>(t.city.calendar.temp=2,t.city.cold=0,F("event_heatwave"))},coldsnap:{reqs:{tech:"primitive"},type:"minor",condition:()=>!t.race.cataclysm&&!t.race.orbit_decayed&&0!==t.city.calendar.temp,effect:()=>(t.city.calendar.temp=0,t.city.hot=0,F("event_coldsnap"))},cucumber:uo("cucumber","primitive"),planking:uo("planking","high_tech"),furryfish:uo("furryfish","primitive"),meteor_shower:uo("meteor_shower","primitive"),hum:uo("hum","high_tech"),bloodrain:uo("bloodrain","primitive"),haunting:uo("haunting","science"),mothman:uo("mothman","science"),dejavu:uo("dejavu","theology"),dollar:uo("dollar","currency",(function(){let e=Math.rand(1,10);return t.resource.Money.amount+=e,t.resource.Money.amount>t.resource.Money.max&&(t.resource.Money.amount=t.resource.Money.max),e})),pickpocket:uo("pickpocket","currency",(function(){let e=Math.rand(1,10);return t.resource.Money.amount-=e,t.resource.Money.amount<0&&(t.resource.Money.amount=0),e})),bird:uo("bird","primitive"),contest:{reqs:{tech:"science"},type:"minor",effect(){let e=Math.rand(0,3),t=Math.rand(0,10);return F("event_contest",[F(`event_contest_place${e}`),F(`event_contest_type${t}`)])}},cloud:uo("cloud","primitive",(function(){return F(`event_cloud_type${Math.rand(0,11)}`)})),dark_cloud:{reqs:{tech:"primitive"},type:"minor",condition:()=>!t.race.cataclysm&&!t.race.orbit_decayed&&0!==t.city.calendar.weather,effect:()=>(t.city.calendar.weather=0,F("event_dark_cloud"))},gloom:{reqs:{tech:"primitive"},type:"minor",condition:()=>!t.race.cataclysm&&!t.race.orbit_decayed&&1!==t.city.calendar.weather,effect:()=>(t.city.calendar.weather=1,F("event_gloom"))},tracks:uo("tracks","primitive"),hoax:uo("hoax","primitive"),burial:uo("burial","primitive"),artifacts:uo("artifacts","high_tech"),parade:uo("parade","world_control"),crop_circle:uo("crop_circle","agriculture"),llama:uo("llama","primitive",(function(){let e=Math.rand(25,100);return t.resource.Food.amount-=e,t.resource.Food.amount<0&&(t.resource.Food.amount=0),e}),(function(){return!(t.race.carnivore||t.race.soul_eater||t.race.detritivore||t.race.artifical)})),cat:uo("cat","primitive"),omen:uo("omen","primitive"),theft:uo("theft","primitive",(function(){return F(`event_theft_type${Math.rand(0,10)}`)})),compass:uo("compass","mining"),bone:uo("bone","primitive"),delicacy:uo("delicacy","high_tech"),prank:uo("prank","primitive",(function(){return F(`event_prank_type${Math.rand(0,10)}`)})),graffiti:uo("graffiti","science"),soul:uo("soul","soul_eater"),cheese:{reqs:{tech:"banking"},type:"minor",condition:()=>!!(t.tech.banking&&t.tech.banking>=7),effect(){let e=t.stats.hasOwnProperty("reset")?t.stats.reset+1:1;return t.race.cheese=Math.rand(10,10+e),F("event_cheese")}},tremor:uo("tremor","primitive"),rumor:uo("rumor","primitive",(function(){return F(`event_rumor_type${Math.rand(0,10)}`)}))};function uo(e,t,a,r){return{reqs:{tech:t},condition(){let e=!0;return"function"==typeof r&&(e=r()),e},type:"minor",effect(){let t=!1;return"function"==typeof a&&(t=a()),t?F(`event_${e}`,[t]):F(`event_${e}`)}}}function _o(e,a){return{reqs:{trait:"slaver",tech:"slaves"},condition:()=>!(t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation),type:e,effect:()=>t.city.slave_pen&&t.city.slave_pen.slaves>0?(t.city.slave_pen.slaves--,t.resource.Slave.amount=t.city.slave_pen.slaves,F(`event_slave_${a}`)):F("event_slave_none")}}function po(e,a){let r=ke(qe(),"army",t.civic.garrison.wounded),s=t.tech.high_tech?t.tech.high_tech+1:1,i=("witchhunt"===e?1e3:t.civic.foreign[e].mil)*(1+Math.floor(m(0,10)-5)/10)*s,c=t.civic.garrison.wounded>qe()?qe():t.civic.garrison.wounded,o=qe()>0?Math.floor(m(1,c)):0,n=Math.floor(m(0,qe()-c));t.race.instinct&&(o=Math.round(o/2),n=Math.round(n/2)),t.civic.garrison.workers-=o,t.civic.garrison.wounded+=n,t.stats.died+=o,t.civic.garrison.wounded>t.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(i/5),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0]));let l="witchhunt"===e?F("witch_hunter_crusade"):F(`civics_gov${t.civic.foreign[e].name.s0}`,[t.civic.foreign[e].name.s1]);if(r>i)return F("event_pillaged1",[l,o.toLocaleString(),n.toLocaleString()]);{let e=a?2:4,r=[],s=Object.keys(Za);return s.push("Money"),s.forEach((function(a){if(t.resource[a]&&t.resource[a].display&&t.resource[a].amount>0){let s=Math.rand(1,Math.round(t.resource[a].amount/e)),i=t.resource[a].amount-s;i<0&&(i=0),t.resource[a].amount=i,"Money"===a?r.push(`$${k(s)}`):r.push(`${k(s)} ${t.resource[a].name}`)}})),F("event_pillaged2",[l,o.toLocaleString(),n.toLocaleString(),r.join(", ")])}}function ho(e){let a=[];return Object.keys(lo).forEach((function(r){let s=!0;e!==lo[r].type&&(s=!1),("major"===e&&t.event.l===r||"minor"===e&&t.m_event.l===r)&&(s=!1),lo[r].reqs&&Object.keys(lo[r].reqs).forEach((function(e){switch(e){case"race":lo[r].reqs[e]!==t.race.species&&(s=!1);break;case"genus":lo[r].reqs[e]!==di[t.race.species].type&&(s=!1);break;case"nogenus":lo[r].reqs[e]===di[t.race.species].type&&(s=!1);break;case"resource":t.resource[lo[r].reqs[e]]&&t.resource[lo[r].reqs[e]].display||(s=!1);break;case"trait":t.race[lo[r].reqs[e]]||(s=!1);break;case"notrait":t.race[lo[r].reqs[e]]&&(s=!1);break;case"tech":t.tech[lo[r].reqs[e]]||(s=!1);break;case"notech":t.tech[lo[r].reqs[e]]&&(s=!1);break;case"high_tax_rate":t.civic.taxes.tax_rate<=lo[r].reqs[e]&&(s=!1);break;case"low_morale":t.city.morale.current>=lo[r].reqs[e]&&(s=!1);break;case"biome":t.city.biome!==lo[r].reqs[e]&&(s=!1);break;default:s=!1}})),s&&lo[r].condition&&!lo[r].condition()&&(s=!1),s&&a.push(r)})),a}const mo=[{version:"1.3.8",revision:"a",date:"6/1/2023",changes:["Fixed high pop scaling."]},{version:"1.3.8",date:"6/1/2023",changes:["Unfathomable bug fixes.","Psychic powers up time now scale with rank of Ancient Nightmare.","Additional Psychic power upgrades.","Intergalactic Raider renamed to Corsair."]},{version:"1.3.7",revision:"a",date:"5/30/2023",changes:["Fixed issue with drawing the same alien species twice in intergalactic content.","Adjusted Mana costs for some research techs in Witch Hunter."]},{version:"1.3.7",date:"5/29/2023",changes:["Added Magic universe exclusive challenge: Witch Hunter.","Reduced Encrypted Data cost of Data Analysis, Advanced Medkits, Automated Warehousing, Elerium Extraction, and Drone Warfare techs.","Star Forge smelting bonus rebalanced.","Antimatter Dark Energy effect now applies to Truepath Ship power generation.","Fixed Magocracy Crystal bonus.","Reduced Crystal cost of Alchemy.","Fixed Humpback trait rank scaling.","Infiltrator can now steal Alien Biotech on Truepath.","Fixed brownout issue with using Replicator Gov task when constructing a new powered building.","Fixed rejuvenated trashed planet bonus.","Fixed orbit period on reterraformed planets."]},{version:"1.3.6",date:"4/22/2023",changes:["Added Astrological signs.","Added Motivated Event.","Operating Bases now function as Hospitals in Orbit Decay scenario.","Stellar Forge is now locked to using Star Fuel for smelting.","Species with the Forge trait can now use Inferno Fuel and Star Fuel.","Reduced Wireless Signal needed to Contact womlings in Lone Survivor."]},{version:"1.3.5",revision:"c",date:"4/16/2023",changes:["Made Egg #17 easier to get in Cataclysm mode."]},{version:"1.3.5",revision:"b",date:"4/9/2023",changes:["Increased egg accessibility with certain traits or challenge modes."]},{version:"1.3.5",revision:"a",date:"4/8/2023",changes:["Fixed a bug that caused eggs 16-18 not to count for unlocking the egg hunt feat."]},{version:"1.3.5",date:"4/7/2023",changes:["Avian species now have the Flier trait.","Avian Rigid trait replaced with Sky Lover.","Added Wireless storage to High-Tech farm in isolation","Fixed truepath dreadnought power costs.","Fixed a bug that could assign extra challenge genes.","Fixed a bug with changing languages with active Tau Ceti content.","Fixed many issues with preload tab content in the early game."]},{version:"1.3.4",revision:"b",date:"3/30/2023",changes:["Prevented some bugs caused by distributed power mode from occurring.","You can now unlock World Domination, Illuminati, Syndicate, and Pacifist in Truepath."]},{version:"1.3.4",revision:"a",date:"3/25/2023",changes:["A restore point is now made if you select isolation protocol."]},{version:"1.3.4",date:"3/24/2023",changes:["Evolving Synth can now choose imitation race from any species killed by an AI Apocalypse.","Fixed issue with miscalculating low fuel usage for various power generating structures.","Extractor Ship Isolation output boosted by 20%.","Added additional Hooved reskins.","Fixed various issues with Preload Tab Content.","Explorer Ship config is now locked down for Engine, Sensor, and Weapon components.","Skilled Servants assigned to craft inactive resources will now be refunded."]},{version:"1.3.3",revision:"a",date:"3/20/2023",changes:["Fixed a bug that could cause the Test Launch to be unavailable."]},{version:"1.3.3",date:"3/15/2023",changes:["Rebalanced Soul Gem drop mechanics.","Added Annihilation Feat.","Added additional Mass Ejector Optimizer config mode.","Servants are no longer affected by most racial traits.","The Lone Survivor can no longer benefit from Hivemind.","Fixed High Pop issue with Pit Miners.","Fixed bug with unlocking Replicator without a Governor."]},{version:"1.3.2",revision:"c",date:"3/8/2023",changes:["Fixed cataclysm reset while having preload tab content enabled."]},{version:"1.3.2",revision:"b",date:"3/5/2023",changes:["Fixed Rock Quarry under industry tab for Smoldering players."]},{version:"1.3.2",revision:"a",date:"3/5/2023",changes:["Adjusted hell calculation."]},{version:"1.3.2",date:"3/4/2023",changes:["High-Tech Factory changed back to tool modifier, however value is increased from original 25% to 90%.","Advanced Material Synthesis increased from 50% to 65%.","Added new interaction between Hell Surveyors and Drone victims.","Fixed bug that would cause Replicator Governor task to swap resources when focusing a resource without a cap.","Fixed inability to produce Chrysotile in Isolation."]},{version:"1.3.1",date:"3/3/2023",changes:["Added Advanced Material Synthesis tech to Isolation path.","High-Tech Factory crafting bonus changed from a Tool modifier to a direct multiplier.","Updated Mass Ejector Optimizer logic.","Fixed a bug that broke Cataclysm reset.","Fixed fuel calculation bug with Moon Bases and Spaceports.","Fixed issue with self replicating Synth and Nano.","Fixed bugs with purchasing CRISPR techs in Antimatter universe."]},{version:"1.3.0",revision:"b",date:"3/1/2023",changes:["Fixed issue with Mass Ejector Optimizer gov task breaking the governor subtab."]},{version:"1.3.0",revision:"a",date:"3/1/2023",changes:["Fixed Antimatter universe."]},{version:"1.3.0",date:"3/1/2023",changes:["The True Path has been extended, explore Tau Ceti and expand your civilization.","Added Perks: Evolve Master and Evolve Grandmaster.","Added Distributed Low Power mode setting.","Added Precognition CRISPR upgrade.","Strong trait now buffs basic jobs but has a weaker effect on manual resource collection.","Ships in Truepath can now only be scrapped at the Shipyard.","Truepath Sensor Range and Costs adjusted. Range now depends partly on base ship class.","Queue stacks now indicate first block vs last blocking resource with a gradient indicator.","Added screen reader improvements for blocking resources.","You can no longer unlock Anarchist by Cataclysm.","Syndicate will now also steal food from Biodomes.","Reinforced Shed upgrade now requires unlocking Iron Mining.","You must now construct a Titan Habitat before a Titan Mine.","Removed dark background effect from modal popups.","Increased Entrepreneur Governor trade bonus from 75% to 125% and Bank capacity boost from 10% to 12%.","Increased Media Governor morale bonuses and Library bonus.","Increased Soldier Governor combat bonus from 5% to 25%.","Increased Educator Governor knowledge bonus from 5% to 6%.","Increased Spiritualist Governor worker bonus from 10% to 20% and tourism bonus from $2 to $5 per Temple.","Increased Noble Governor tax cap bonus from 10% to 20%.","Bluecollar Governor now increases output of Coal and Oil power plants and boosts Miners, Smelter, and Oil Derrick.","Bureaucrat Governor now provides a slight boost to government effects."]},{version:"1.2.21",date:"1/10/2023",changes:["New Achievement filtering options in Wiki.","Updated Chinese lang file.","Updated Korean lang file."]},{version:"1.2.20",date:"9/16/2022",changes:["New homelessness system.","Factory, Mining Droids, and Graphene Plants will remember resource assignment after a low power shutdown.","Terraforming and Ascension can no longer be queued or multi-clicked.","AI Cores show correct bonus in tooltip.","Stealing Rocketry will now unlock rival in Truepath.","Playful will no longer remove unemployed stress with no hunters.","Andromeda Citizens will no longer stick around if abandoned by a stargate shutdown.","Fixed various bugs with mutating in or out some traits.","Made some improvements for screen readers to determine active state of challenges."]},{version:"1.2.19",revision:"a",date:"8/21/2022",changes:["Home Planet Orbital structures are now merged with the Moon instead of Red Planet in Cataclysm."]},{version:"1.2.19",date:"8/20/2022",changes:["Added rank scaling effects to traits: Carnivore, Hooved, Leathery, Unified, & Magnificent.","Structures orbiting the home planet are now moved to the Red planet after Orbit Decay or during Cataclysm.","Fixed a bug with deactivating fuel consuming structures when fuel runs dry.","Already active Governor tasks will no longer display for assignment in other task slots.","Constructing a Stellar or Infernal Forge will now assign Iron as a default resource instead of nothing.","Buffed effects of Star Forge fueled smelting.","Fixed an incorrect source label for money storage in Orbit Decay."]},{version:"1.2.18",revision:"a",date:"8/14/2022",changes:["Fixed ARPA queueing."]},{version:"1.2.18",date:"8/14/2022",changes:["More accurate timers when using Governor Trash Management task.","Optimistic Min Morale effect now scales with trait rank.","Fixed TP loot table when Assaulting or Sieging rival."]},{version:"1.2.17",revision:"a",date:"8/10/2022",changes:["Cheese Event power is now scaled with your cheese level.","Fixed Soft Reset bug with Rejuvenated."]},{version:"1.2.17",date:"8/10/2022",changes:["New Hell stats tracking and analytics.","Fixed Genetics not unlocking in Cataclysm.","Fixed many High Pop scaling interactions.","Fixed some loading bugs with wiki when no save data is present.","Updated various wiki entries and calculators.","Updated Pig Latin."]},{version:"1.2.16",revision:"a",date:"8/8/2022",changes:["Fixed OD bugs with Ziggurat, Garage, and Fabrication.","Fixed Launch Facility sometimes getting stuck in queue."]},{version:"1.2.16",date:"8/4/2022",changes:["Added Orbit Decay Challenge.","Added Retrograde planetary trait.","New achievement: Better dead than red.","New CRISPR upgrade: Civil Service.","Other stuff the dev was too lazy to document."]},{version:"1.2.15",revision:"a",date:"7/1/2022",changes:["Fixed bug that prevented games without save data from loading."]},{version:"1.2.15",date:"7/1/2022",changes:["Firework Festival now starts on July 1st and ends July 4th.","Added Dracula theme by azzzertyy.","Fixed bug with Horseshoe governor and multiplier keys.","Fixed issues with starting Cataclysm as Synth.","Fixed bugs with wrong path techs being displayed.","Evil Synth now start with a Graveyard instead of a Lumberyard.","Deify and study can no longer be queued at same time.","Restore backup no longer requires double clicking to trigger confirmation box."]},{version:"1.2.14",revision:"a",date:"4/19/2022",changes:["Fixed some minor bugs.","Updated some translations."]},{version:"1.2.14",date:"4/1/2022",changes:["Added Titan Mine slider to Industry tab.","Added additional popup confirmation to Restore Backup.","Nanite Factory interface now has tooltips for each resource","The Vault Discovery event can no longer occur if there are 0 Archaeologists and/or if Suppression is at 0%","Fixed bugs related to unlocking the Fool feat.","Fixed bugs with Mass Ejector optimizor governor task."]},{version:"1.2.13",date:"3/31/2022",changes:["Restore Backup must now be clicked twice to trigger."]},{version:"1.2.12",revision:"c",date:"3/7/2022",changes:["Fixed Double Density achievement."]},{version:"1.2.12",revision:"b",date:"3/2/2022",changes:["Fixed logic fault with mech constructor inferno upgrades."]},{version:"1.2.12",revision:"a",date:"3/1/2022",changes:["Fixed some bugs with planet traits.","Fixed bug with attacking on Swamp planets."]},{version:"1.2.12",date:"2/28/2022",changes:["Planets can now have upto two traits.","Advanced Biomes: Savanna, Swamp, Ashland, and Taiga can now appear.","Added Permafrost planetary trait.","Forest Biome lumber bonus changed from 15% to 20%.","Exotic materials are now ranked higher by the Mass Optimizer governor task.","Repair droid effect on Carport repairs buffed from 5% to 8%.","You must now discover the Hell Vault through Archaeology.","Water now has Mass."]},{version:"1.2.11",date:"2/16/2022",changes:["Added Doomed achievement to the perks lists.","Added Governor CRISPR tree to perks list.","Updated prestige gain/bonus calculators.","Fixed Ritual Casting not showing up in Industry in Cataclysm.","Detritivores no longer see the Farming ritual.","Fixed Entertainer tooltip showing twice the effect of Musical.","Fixed Gauss Rifles showing the effect for Disruptor Rifles.","Fixed Water Freighter tooltip showing half the Helium-3 cost.","Fixed some affordability checks."]},{version:"1.2.10",date:"2/7/2022",changes:["Bioseed probes now have significantly less cost creep inside True Path scenario.","You can no longer manually buy or sell resources while the game is paused.","Fixed bug with High Pop trait and Savings Bonds granting too much money.","Minor bug fixes"]},{version:"1.2.9",date:"1/29/2022",changes:["Spies may now sell you out when caught or escape when failing a mission.","Infiltrator can now steal Quantium tech inside True Path.","Genetics Lab UI updated."]},{version:"1.2.8",revision:"a",date:"1/19/2022",changes:["Fixed Farmer per Farm scaling with High Pop trait.","Adjusted low end scaling of High Pop Hivemind trait.","Wireless Signal cost for Symposium lowered.","Added Anarchy scaling with High Pop"]},{version:"1.2.8",date:"1/19/2022",changes:["Insectoid genus redesigned with High Population trait.","Fixed bug that caused incorrect timer calculations when using Slow or Hyper trait at any rank other then 1."]},{version:"1.2.7",revision:"a",date:"1/11/2022",changes:["Fixed storage bug with standard universe."]},{version:"1.2.7",date:"1/11/2022",changes:["Failed Experiment Challenge mode.","Ziggurat bonus separated from base production of buildings.","Fixed bug that prevented smoldering races from being able to loot Chrysotile","Fixed bug that would cause Intergalactic Tech page in wiki not to load if you were playing in Antimatter universe."]},{version:"1.2.6",date:"12/24/2021",changes:["Fixed bug that prevented custom Synthetic race from showing if you refreshed the page.","Fixed bugs with Synthetic evolution and traits: Calm, Cannibalize, and Magnificent.","Fixed bugs with using the quick tab keys when preload tabs is enabled."]},{version:"1.2.5",date:"12/21/2021",changes:["Fixed bug that caused a planet to lose its geology traits after an AI reset.","Fixed bug with scavenger job description."]},{version:"1.2.4",date:"12/19/2021",changes:["Solar system now has elliptical orbits.","Fixed Evolve Adept Food bonus.","Rank of each aquired trait is now listed in genetics tab.","Crate/Container sources are now listed in resource popup.",'Manual buying/selling will auto scale down to prevent "waste".']},{version:"1.2.3",date:"12/16/2021",changes:["Expanded Festive Season to include additional species."]},{version:"1.2.2",date:"12/15/2021",changes:["Graphene Plants now show on industry tab for True Path.","Added entry for Festive Season into wiki.","The game wiki will now load without any game data."]},{version:"1.2.1",date:"12/14/2021",changes:["Smelter metals can now be reallocated without unassigning.","Increased accuracy of syndicate intel data","Fixed bug with removing Weak & Bad genes when toggling True Path.","Fixed bug with adding or removing Professors not updating indoctrination value.","Fixed bug with Planet Wiki entry that prevented some data from loading.","Added trait rankings to wiki."]},{version:"1.2.0",revision:"a",date:"12/12/2021",changes:["Fixed bug with Plasmid Storage.","Fixed bug with Befuddle trait and Espionage.","Fixed bug with Composting.","Updated Solar Map.","Added setting to enable mobile device support.","Minor buff to TP Frigate power."]},{version:"1.2.0",date:"12/12/2021",changes:["Unlock the True Path (Requires completion of Ascension or Demonic Infusion).","Using Fanaticism to gain an unempowered trait you already possess will now empower that trait.","Added option to Hell Fortress to prevent using ship crew as reinforcements.","Shrine Metal bonus now applies to Mining Droid Aluminium production.","Armored trait now prevents 50% of deaths.","Cannibalize healing now applies a percent based bonus instead of being equivalent to 3 5% Hospitals.","GruvBox Dark is now the default theme.","Added Evolve Adept Perk.","Themed several additional weapon techs in magic universe for immersion.","Smoldering and Chilled effects now display as Smoldering or Chilled in production breakdowns instead of Hot/Cold.","Improved touch device support."]},{version:"1.1.17",date:"11/28/2021",changes:["Job stress from Civilian Ship Crew is now calculated correctly.","Things will now show as unaffordable if they require a locked resource.","Added new entries to Mechanics section of Wiki: Job Stress, Cost Creep, and Warmonger.","Evolve Novice and Evolve Journeyman perk conditions updated."]},{version:"1.1.16",date:"10/30/2021",changes:["Ghost #3 can now be captured with Smoldering.","Ghost #7 can now be captured in Cataclysm mode.","Updated description of Trick or Treat feat.","Llamas will no longer harass carnivores, detritivores, and soul eaters by grazing their fields."]},{version:"1.1.15",date:"10/20/2021",changes:["Added buttons to pause queues.","Cracked Pylons now correctly add to Mana cap.","Pillar of Bones will no longer be rolled with the Smoldering trait.","Fixed bugs with removing Terrifying trait.","Fixed bug with items in queue blocking the next item when it couldn't be completed due to negative production of a resource.","The Tax-Morale governor task is now slightly smarter."]},{version:"1.1.14",revision:"a",date:"9/30/2021",changes:["Fixed Pylon bug with upgraded save games in Magic Cataclysm runs.","Fixed a Message Log filtering problem where some players might not unlock some options."]},{version:"1.1.14",date:"9/29/2021",changes:["New settings options for message log filters.","Added Cracked Pylons for Magic Cataclysm mode.","Conjuring is no longer researchable in Cataclysm mode.","Challenges section added to Wiki under Gameplay.","Smoldering Gnawer will now consume Stone instead of nothing."]},{version:"1.1.13",date:"9/5/2021",changes:["Expanded Mechanics entries in wiki.","Fixed some errors in wiki prestige calculators.","Added a Custom Lab calculator to wiki under species."]},{version:"1.1.12",date:"8/19/2021",changes:["Training Timer for Military tab.","Draggable config options for Spy Operator.","Bug fixes for log and queue windows."]},{version:"1.1.11",date:"8/12/2021",changes:["ARPA projects now contribute to inflation.","Mercenaries costs are now affected by inflation.","Trade is now affected by inflation.","Casino income is now affected by inflation.","Luxury Goods income is now affected by inflation.","Rescaled inflation levels.","Wheelbarrow achievement now requires $250 billion.","Inflation bug fixes.","New message log filters.","Fixed Luxury Goods tooltip money value."]},{version:"1.1.10",date:"8/8/2021",changes:["Added Inflation Challenge Mode. Requires Scrooge achievement to unlock.","Import/Export race feature added to Ascension lab.","Added merge options for queue.","Available space in queue is now shown.","Added Blackhole + Mass Ejector mechanic entry to wiki.","Fixed some display bugs with Alchemy.","Fixed bug where Protoplasm could be required by some structures late in hell phase."]},{version:"1.1.9",date:"7/7/2021",changes:["Firework festival bug fix for cataclysm mode."]},{version:"1.1.8",date:"7/3/2021",changes:["Added firework festival event (July 4th - July 8th).","Added Copper and Iron settings to Mass Ejector Optimizer task.","Current Quantum Level now shown on Citadel Stations.","Updated wiki prestige calculators.","Added a Quantum Level section to wiki."]},{version:"1.1.7",date:"6/29/2021",changes:["Added a Mass Ejector Optimizer governor task.","Fixed precision error with Tech Scavengers.","Prestige calculators added to wiki.","Progress related event section added to wiki.","Anti-plasmids gained from MAD in antimatter universe are now correctly calculated."]},{version:"1.1.6",date:"6/19/2021",changes:["Solstice event is now easier for less seasoned players.","Wharves are no longer affected by the Nomadic trait.","Decreased cost of Iron Horseshoes."]},{version:"1.1.5",date:"6/16/2021",changes:["Support for String Packs.","Separate research queue behavior option.","Balorg can now use the governor tax task."]},{version:"1.1.4",date:"6/11/2021",changes:["Fixed a bug that would sometimes cause mechs to be constructed without weapons.","Fixed a bug that would cause an open tooltip to change descriptions when a queue item completes."]},{version:"1.1.3",date:"6/7/2021",changes:["Improvements to tooltip reliability.","The first Horseshoes can now be constructed out of Lumber if available as a resource.","Horseshoe pacing updated, see Hooved entry in wiki for expanded information."]},{version:"1.1.2",date:"6/6/2021",changes:["Added Money Reserve % config value to Slave replacement task.","Various special buildings are now dropped from the queue if you remove their required trait.","Spy Operator will no longer attempt espionage against controlled cities.","Fixed many issues with labels not updating"]},{version:"1.1.1",date:"6/5/2021",changes:["Unifying during banana republic now triggers an automatic backup save.","Holding a key multiplier with the queue key will now queue mulitple of a building.","Dealmaker import bonus buffed from 40% to 75%.","Nerfed Beast trait to 8% hunting / 15% windy hunting / 10% soldier training.","Restored Cautious trait to Carnivore genus.","Added Money Reserve % config values to Merc and Spy recruiter tasks.","Horseshoes can now be queued.","Adamantite Horseshoes are now much cheaper.","Changed progression system for Horseshoe costs, will not change to next resource unless it's unlocked."]},{version:"1.1.0",date:"6/4/2021",changes:["Appoint a Governor to help run the everyday tasks, unlock in the CRISPR lab.","Animal genus split into 2 new beast genus: Carnivore & Herbivore.","Carnivore Species: Cath, Wolven, Vulpine.","Herbivore Species: Centaur, Rhinotaur, Capybara.","Cath, Wolven, and Centaur redesigned.","Spire Mech Combat rebalanced.","Titan mechs now have 4 weapon slots and an extra equipment slot.","New Equipment: Jump Jet (All but Heavy & Titan), Battery (Heavy Only), and Targeting Computer (Titan Only).","New Scavenger mech type","Reweighted Angelic genus trait costs.","Major event messages are now shown in a different color from minor ones.","Decreased frequency of minor events.","Smoldering no longer applies to a variety of special resources.","Frenzy renamed to Blood Thirst.","Madagascar Tree achievement now requires inheriting Blood Thirst instead of Carnivore.","Expanded Hell section of Wiki"]},{version:"1.0.43",date:"5/18/2021",changes:["Banana Smoothie will no longer unlock for free in alternate universes.","Added a Spire Floor clear timer for previously beaten monsters.","Gate Turrets now correctly contribute to demon kills."]},{version:"1.0.42",date:"5/4/2021",changes:["Minor bug fixes with new events."]},{version:"1.0.41",date:"5/3/2021",changes:["Added launch day event for May 6th.","New minor event system.","The same event can no longer trigger twice in a row."]},{version:"1.0.40",date:"4/11/2021",changes:["Special event race reskins will now persist after event ends until reset.","Added a warning to Unification tech if playing Banana Republic scenario."]},{version:"1.0.39",date:"4/9/2021",changes:["Added challenge win conditions to planet description popover."]},{version:"1.0.38",date:"4/4/2021",changes:["Fixed a bug that prevented some races from acquiring Egg #3."]},{version:"1.0.37",date:"4/3/2021",changes:["Fixed a bug with unlocking the Egg Hunt feat."]},{version:"1.0.36",date:"4/1/2021",changes:["Fool Feat will automatically upgrade to current challenge level for eligible players."]},{version:"1.0.35",date:"3/31/2021",changes:["Changed Blackhole objective of Banana Republic scenerio from stabilize a blackhole to Expand a blackhole to 12 solar mass without exotic matter.","Fixed Terrifying trade exploit in Banana Republic scenerio."]},{version:"1.0.34",date:"3/28/2021",changes:["Added the Banana Republic challenge.","Tax Riots will no longer cause loss of Artifacts, Blood Stones, and other key resources.","Cancel all routes option for trade screen.","Protests no longer apply their penalty twice.","Minor genetic traits can now be reordered by dragging.","Max trade routes per resource type are now governed by Large Trade and Massive Trade upgrades.","Misc minor bug fixes."]},{version:"1.0.33",date:"3/20/2021",changes:["Enhanced threat assessment for Spire.","Added a Save as File option for exporting game state."]},{version:"1.0.32",date:"3/19/2021",changes:["Unemployment Rework.","Fixed reactivity of some tooltips.","Fixed cut off tooltips on settings tab.","Xeno Tourism now requires 10 Monuments and Tourism."]},{version:"1.0.31",date:"3/15/2021",changes:["Alien 1 system is now named after their homeworld.","Alien 2 system is now named after their red planet.","Fixed various cut off tooltips."]},{version:"1.0.30",date:"3/4/2021",changes:["Wharves once again now grant the correct number of trade routes.","Fixed errors with Casino vault size.","Sacrificed Citizens stat for Mantis players.","Factory production can be assigned without first removing it from Alloy production."]},{version:"1.0.29",date:"2/25/2021",changes:["Evolved species will no longer be stuck in the queue after evolution.","Fixed potential viewport scrolling issues with Settings and Evolution tabs.","Added a warning for users running Evolve in multiple tabs.","The game will now remind players to backup their game data once every 100,000 game days."]},{version:"1.0.28",date:"2/21/2021",changes:["Queue can now be used during evolution stage if unlocked with CRISPR tech.","Fixed incorrect Scarletite costs with Wasteful trait.","Graphene Plants now default to Oil with Smoldering.","Fixed many string errors."]},{version:"1.0.27",date:"2/11/2021",changes:["Added Trade Federation achievement.","Added Mastery section to perks page.","Fixed aria label of jobs.","Squished achievement will now unlock from Blackhole or Demonic Infusion."]},{version:"1.0.26",date:"1/30/2021",changes:["Enhanced crafted material popovers.","Universe filters for wiki achievements page.","Cheese Guide."]},{version:"1.0.25",date:"1/23/2021",changes:["Added Piracy section to Wiki under Gameplay-Mechanics.","Numerous minor bug fixes."]},{version:"1.0.24",date:"1/17/2021",changes:["Evil Smoldering races can now research bone tools."]},{version:"1.0.23",date:"1/16/2021",changes:["Redesigned Heat based Genus mechanics.","Untapped Potential formula changed: now has diminishing returns for stacking unspent genes.","Faith now has an effect on auto crafting (Craftsmen Only).","Added new topics to Mechanics section of Wiki.","Minor bug fixes."]},{version:"1.0.22",date:"1/15/2021",changes:["Fixed Cataclysm mode game start."]},{version:"1.0.21",date:"1/10/2021",changes:["Gain upto 8 hours of accelerated time when game is stopped/closed.","Optimized tab content loading for performance.","Pause game feature."]},{version:"1.0.20",date:"12/29/2020",changes:["Fixed issue with keyup event not releasing multiplier keys."]},{version:"1.0.19",date:"12/28/2020",changes:["Studious now improves library knowledge by 10%.","Merchant now increases the amount of resources gained from trading by 10%.","Tracker raised from 10% to 20%.","Resourceful raised from 10% to 12%.","Claws raised from 20% to 25%.","Apex Predator combat bonus raised from 25% to 30%.","Forge Geothermal power boost raised from +1MW to +2MW.","Beast trait now boosts Hunting by 10% or 20% when windy and improves soldier training time by 20%.","Beast gene point cost changed from 2 to 3 points.","Top level tab quick selection key bindings (default 1-7)."]},{version:"1.0.18",date:"12/24/2020",changes:["Fixed issue with species costs on some techs requiring protoplasm without a reload."]},{version:"1.0.17",date:"12/19/2020",changes:["Larger font size modes.","Added descriptions for city sectors.","Last 3 event messages will now be preserved on reload.","Fixed Evolution bugs with Unbound Infusion active.","Improved timer accuracy of stacked queue items when No Queue Order is used."]},{version:"1.0.16",date:"12/16/2020",changes:["Dark Bomb: Kill and Reset the Demon Lord's accumulated strength using the new Dark Bomb.","Bonus Artifacts can now be earned during Demonic Infusion if Spire floor 50 or 100 are cleared.","Renamed the tech upgrade Purify to Enhanced Air Filters in order to prevent confusion with the Blood Infusion Purify."]},{version:"1.0.15",date:"12/12/2020",changes:["Redesigned Inferno Reactor, output is now tied to Infernal Forge.","Steel can once again be discovered by Ambush attacks.","Power Grid is now shown in Cataclysm.","Cataclysm reset no longer incorrectly grants Rapid Mutation or Ancient Ruins.","Many minor bug fixes."]},{version:"1.0.14",date:"12/8/2020",changes:["Vacuum Collapse no longer removes all charges of Corrupted bonus.","Vacuum Collapse now correctly increases Dark Energy earned on the stats page.","Lumber Ritual is no longer displayed to Evil races.","Multiplier keys now work when hiring mercenaries."]},{version:"1.0.13",date:"12/4/2020",changes:["Power Grid now correctly unlocks when gaining Electricity from Infiltrator trait.","Feats Garbage Pie and Finish Line can now be unlocked by Demonic Infusion."]},{version:"1.0.12",date:"12/4/2020",changes:["MechBay tab improvements.","Mechlist can now be reordered by dragging.","Power Grid can now control On/Off state.","Support type structures can now be controlled by the power grid."]},{version:"1.0.11",date:"12/2/2020",changes:["Fixed a memory leak.","Minor adjustments to GruvBox Dark theme.","Cheesy Goodness."]},{version:"1.0.10",date:"12/1/2020",changes:["Ascended buff now persists after Demonic Infusion.","New Themes: GruvBox Light, GruvBox Dark, and Orange Soda."]},{version:"1.0.9",date:"11/29/2020",changes:["Perks separated on to a separate tab under Stats.","Added Perks section to Wiki."]},{version:"1.0.8",date:"11/28/2020",changes:["Base Neutronium cost of Inferno Reactor lowered to 3,750,000.","Fixed Valdi genus traits after evolution.","Prepared rank 2 now correctly applies when building mechs.","Power Grid is now more strict in checking what is available.","Fixed bug that sometimes caused crafting to use a wrong Mastery value."]},{version:"1.0.7",date:"11/25/2020",changes:["Fixed a bug where Technocracy prevented Alien 2 & Chthonian invasions from working."]},{version:"1.0.6",date:"11/24/2020",changes:["Fixed Mechlab quick switch button.","Titan class mech power increased by 12.5%."]},{version:"1.0.5",date:"11/22/2020",changes:["Adjustable Power Grid","Light Theme bug fixes."]},{version:"1.0.4",date:"11/21/2020",changes:["Gains from Alchemy are now higher.","Any mixed fleet can now invade the Alien 2 and Chthonian systems as long as the invasion force is strong enough.","Alien 2 Invasion requires minimum of 400 fleet rating and at least 650 to take no losses.","Chthonian Invasion requires a minimum 1250 fleet rating, 2500 for average losses, and 4500 for minimum losses."]},{version:"1.0.3",date:"11/15/2020",changes:["Fixed compost heap values.","Added combat section to the wiki under gameplay.","Added Equilibrium feat for pillaring every species.","The Misery feat can now be earned from Demonic Infusion."]},{version:"1.0.2",date:"11/10/2020",changes:["Valdi now take your chosen Genus instead of humanoid.","Wrath Blood Infusion now properly applies to all Mech fights.","Artifacts can now be spent properly on the CRISPR tab.","Crystal trade prices adjusted.","Megalith base price reduced from 100k to 55k.","Many minor bug fixes."]},{version:"1.0.1",date:"11/08/2020",changes:["Fixed display bug with CRISPR costs and Technocracy.","Fixed issue with some Windmills not producing power.","The Resort now properly formats its vault size."]},{version:"1.0.0",date:"11/07/2020",changes:["Expanded Interdimensional content, delve deep into the hell dimension.","New Magic Universe.","Fling asteroids into the blackhole with the Asteroid Redirect ARPA project.","The same monument type will no longer be chosen twice in a row.","Evil races can now construct a Pillar of Bones monument type.","Democracy now only affects Entertainers.","Some government bonuses now scale with tech era.","Races with Detritivore can now build Windmills.","Base Aluminium income for plant based species is now roughly 10% higher.","Beast of Burden now grants an extra loot roll instead of a 10% boost.","Revamped combat loot formulas.","Build queue resource highlighting.","Low Contrast Dark Night Theme.","Ewnay igpay atinlay anguagelay."]},{version:"0.9.24",date:"11/1/2020",changes:["Holiday icons from feats earned with no stars can now be accessed.","Challenge feat icons still require at least 1 star."]},{version:"0.9.23",date:"10/30/2020",changes:["New settings option for people who hate fun.","Added ability for an obscure combination of settings and racial traits to get Ghost #3"]},{version:"0.9.22",date:"10/28/2020",changes:["Halloween cosmetic effects will now run for the duration of the Trick or Treat event instead of just on Halloween.","Ents, Dryads, and Salamanders can now find all the Ghosts.","A certain Ghost is now easier to obtain in Cataclysm.","Accessibility improvements for the event."]},{version:"0.9.21",date:"10/27/2020",changes:["Trick or Treat Event, runs from 10/28 - 11/4."]},{version:"0.9.20",date:"10/16/2020",changes:["Fixed bug with the holy trait that improperly applied its bonus."]},{version:"0.9.19",date:"9/1/2020",changes:["Swarm Control AI now provides a base increase of +2 before unlocking Quantum Computing.","Fixed bugs with manual crafting popover.","Fixed bug that stopped DNA & RNA generation during evolution if the Cataclysm scenario was toggled on."]},{version:"0.9.18",date:"8/28/2020",changes:["ARPA Queue timer fixes.","Swarm Control AI upgrade now make Control Stations scale with Quantum level."]},{version:"0.9.17",date:"8/22/2020",changes:["Fixed bug that prevented Cataclysm Ascension from completing.","Rank 1 sacrifice is slightly less effective","Rank 3 sacrifice is significantly more effective","New Research is now shown by Era."]},{version:"0.9.16",date:"8/12/2020",changes:["Bug Fixes by Beorseder:","Fixed issue where Exotic Materials Lab and Fortifications would clear current queue.","Fixed Scavengers not working during Cataclysm.","Fixed display bug with Galactic Exchange during Cataclysm.","Genomic Mutations no longer give the wrong number of Genes without Synthesis upgrades.","Genomic Mutations now tell how many Plasmids/Antiplasmids are gained from them.","Techs now display their requirements on the wiki."]},{version:"0.9.15",date:"8/10/2020",changes:["Tax revolts can no longer destroy Soul Gems.","If you lose your sample of Elerium before researching Elerium Mining it will now be replaced."]},{version:"0.9.14",date:"8/9/2020",changes:["Angelic races now have an innate bonus vs demonic creatures.","Enhanced Muscle Fibers added to perks page.","Genome sequencing will now be off by default in Cataclysm.","Reorganized achievements page in Wiki."]},{version:"0.9.13",date:"8/6/2020",changes:["Special resource descriptions now update."]},{version:"0.9.12",date:"8/3/2020",changes:["Added Crossed the Finish Line feat for Ascending with Cataclysm.","Adjusted many post World Collider Cataclysm things that referenced none existent planetary structures.","Added a fix for Stabilize Blackhole being stuck in an untriggerable state.","Upgrading achievements will now send a notification."]},{version:"0.9.11",date:"8/1/2020",changes:["Fixed a bug that caused Factories to charge the wrong amount of Polymer for producing Synthetic Furs."]},{version:"0.9.10",date:"7/30/2020",changes:["Expanded list of potential enemy city names.","Added Synthetic Fur option to Factories.","Restoring a backup after a Cataclysm will now allow you to Cataclysm again.","Fixed Lumber penalty on Desert worlds.","Many minor bug fixes."]},{version:"0.9.9",date:"7/21/2020",changes:["Added Devotion upgrade to ancients CRISPR line between Faith and Acolyte. The total cost is the same, it's just spread out more.","Players with Ancients 4 are granted Ancients 5 automatically, those with Ancients 3 are refunded 300 Plasmids.","Added Enhanced Muscle Fiber CRISPR upgrade.","High tax morale penalty under Oligarchy is now reduced.","Fixed bugs with Blackhole reset and restoring backups.","Fixed bug with adjusting taxes as a Noble race that would set it to the max."]},{version:"0.9.8",date:"7/18/2020",changes:["Czech translation by Mousesama","The slaves have staged a successful hunger strike to demand better living conditions, as a result slave pens can now only hold 4 slaves each.","Autocracy and Frenzy no longer block Immoral races from gaining a Warmonger bonus.","Geology traits now display under planet information.","Popovers added to building and research queues."]},{version:"0.9.7",date:"7/13/2020",changes:["Seasons no longer exist in Cataclysm mode.","It is no longer Sunny in Cataclysm mode.","Parasites are no longer unable to grow population in Cataclysm mode, but they do take a growth penalty.","Base Sawmill effect is now separated from lumberjack in production breakdown."]},{version:"0.9.6",date:"7/10/2020",changes:["Fixed bug with Infiltrator not unlocking Nanoweave.","Fixed bug with Railways not adding traderoutes correctly in Cataclysm mode."]},{version:"0.9.5",date:"7/6/2020",changes:["Fixed a bug that occurred when combining the Terrifying trait with the gold star Iron Will perk."]},{version:"0.9.4",date:"7/3/2020",changes:["Failed History perk raised from +1 Geothermal to +2 Geothermal energy.","Fixed Oligarchy tax riot immunity between 36%-45%.","Infiltrator can now steal Graphene Processing, Nanoweave, and Orichalcum Analysis techs."]},{version:"0.9.3",date:"7/1/2020",changes:["Increased base number of Plasmids earned in Cataclysm mode."]},{version:"0.9.2",date:"6/30/2020",changes:["Added Restore Backup option, restores game to just before your last prestige reset.","Extended Recombination CRISPR line.","When gaining a random minor trait from Fanaticism, you will now gain 5 ranks of it."]},{version:"0.9.1",date:"6/21/2020",changes:["Fixed Dyson Net."]},{version:"0.9.0",date:"6/21/2020",changes:["Added Scenarios Section to Evolution Challenges.","Added Cataclysm Scenario for those who value science over caution.","Genetic Dead End is now classified as a Scenario.","Plant genus redesign. Photosynth trait replaced with Sappy.","Added 3rd race option for Plant genus: Pinguicula.","Dyson Net now provides partial power as it is constructed.","Added Orichalcum upgrade for Dyson Sphere.","Added Xeno Tourism upgrade.","Added Fertility Clinic upgrade for Hospitals.","Added OTB, Online Gambling, & Bolognium Vault upgrade for Casinos.","Added Scrooge achievement.","Added Soul Link upgrade for Soul Forge/Soul Attractors.","Reduced Bolognium cost of Freighters & Corvette Ships.","Increased rating of Corvette Ships to 30.","Piracy will no longer start until after you construct the Embassy.","Reduced power requirement of Soul Forge and Soul Attractor.","Gun Emplacements and Soul Attractors are now more potent.","Reduced requirement of Demon Slayer feat to 666 Million demon kills."]},{version:"0.8.17",date:"5/30/2020",changes:["Added 3rd race option for Fungus genus: Moldling.","Fungi genus Spore trait replaced with Detritivore.","Casinos now start powered and generated money immediately.","Extreme Dazzle upgrade now boosts Casino income by 50%.","Reduced power requirement of Casino by 1.","Casino Max Morale boost no longer works unless casino is powered.","Occupation will now unlock Federation research.","Added Double Density achievement in heavyverse.","Stoned penalty on mellow planets raised to 10%.","Unemployed citizens on mellow planets no longer generate any stress (note: hunters are NOT unemployed).","Life on mellow planets is now overall less stressful.","Slaver trait rating raised to 12.","Barracks can now be switched off.","Space Stations will now automatically staff Space Miners from the default job when constructed.","Factories now default to producing Alloy instead of Nothing."]},{version:"0.8.16",date:"5/8/2020",changes:["Oceanic biome now applies a 6% bonus to Titanium from Steel smelting.","Oceanic biome now applies a 12% bonus to Titanium from Iron smelting.","Oceanic biome now applies a 5% penalty to Fur generation.","Tundra biome now applies a 25% bonus to Fur generation.","Tundra biome now applies a 10% penalty to Oil generation.","New planetary modifiers: Elliptical, Flare, Dense, and Unstable.","Oligarchy tax riot immunity raised from 35% to 45%."]},{version:"0.8.15",date:"5/2/2020",changes:["Grassland biome Food bonus raised to 20%.","Forest biome Lumber bonus raised to 15%.","Desert biome now applies a 25% Lumber penalty.","Desert biome now gives a 20% stone bonus and a 10% Oil bonus.","Volcanic biome now applies a 10% Food penalty.","Volcanic biome now gives an 8% Iron and 12% Copper bonus.","Added partial Korean translation.","Achievements in the wiki are now sorted Alphabetically.","Some achievements now show completion progress in the wiki."]},{version:"0.8.14",date:"4/30/2020",changes:["Post unification Federation now gives a 32% bonus (raised from 30%).","Federation now increases morale by 10%.","Socialist factory bonus is now 10% (raised from 5%).","Socialist crafting bonus is now 35% (raised from 25%).","Corpocracy factory bonus is now 30% (raised from 20%).","Corpocracy factory bonus now applies to Cement, Graphene, and Vitreloy.","Republic now increases morale by 20%.","Oligarchy tax revenue penalty is now 5% (lowered from 10%).","Oligarchy can now set taxes 20% higher then other governments (raised from 10%).","Technocracy now adds a 10% Knowledge gain bonus.","Autocracy governments are now immune to the warmonger penalty.","Priests now apply a bonus to Ziggurats under Theocracy.","Fixed display of Theocracy effect on temples. This gives a 12% bonus but was only displaying as a 5% increase.","Noble Oligarchy can now set their taxes as high as 40%."]},{version:"0.8.13",date:"4/29/2020",changes:["New research is now sorted by knowledge cost.","Added popover descriptions for prestige resources.","Harmony Crystals now boost standard Dark Energy by 0.1% instead of 0.01%.","Lots of minor bug fixes."]},{version:"0.8.12",date:"4/24/2020",changes:["Farming has been redesigned. Farms no longer directly generate food, Farmers now generate food in combination with Farms.","Added Energizer Feat for ascending without building any Thermal Collectors.","Bad traits no longer count for Ascension Species Creator complexity.","Dreaded Achievement will now unlock if you never researched dreadnoughts.","Fixed issue with some feats spamming the log due to micro achievements.","Fixed base training rate of soldiers.","Fixed bug with diverse trait that made it do the opposite of what it was suppose to do.",'Adjusted color of "purple" text on Night theme.',"Kilowatts are now Megawatts."]},{version:"0.8.11",date:"4/16/2020",changes:["Ascension reset no longer offers planet choices, instead your next race is created on the old planet with bonuses added to that planet.","Ascended planets now gain +2% to all geology deposits, +5% production, +10% storage, and +2 Sundial base Knowledge gain.","Unspent gene points in the Ascension Lab will be converted into Untapped Potential.","Ascension lab now has a complexity gene tax for adding more then 4 traits.","Technophobe perk now applies an additional bonus to custom race complexity.","Paranoid and Hoarder can now be combined.","Over capped slaves will now be released."]},{version:"0.8.10",date:"4/13/2020",changes:["Added EM (Electromagnetic) Field Challenge."]},{version:"0.8.9",date:"4/12/2020",changes:["Added a Feat for finding all the Eggs.","Current egg count can now be checked in the Wiki."]},{version:"0.8.8",date:"4/12/2020",changes:["Easter Event Activated","Event ends 10 days after the start of Easter."]},{version:"0.8.7",date:"4/11/2020",changes:["Fixed Pathetic trait."]},{version:"0.8.6",date:"4/11/2020",changes:["Fixed Brute trait.","Added section for Achievements and Feats to Wiki."]},{version:"0.8.5",date:"4/11/2020",changes:["Added New Work in Progress Game Wiki","Sentience is now more likely to grant a species where the extinction achievement has not yet been earned.","Sentience can now include custom races.","Incorporeal Existence research now costs Phage instead of Plasmids.","Ascension research now Plasmids instead of Phage.","The change log is now part of the Wiki."]},{version:"0.8.4",date:"4/4/2020",changes:["Fixed breaking bug with Rigid trait."]},{version:"0.8.3",date:"4/3/2020",changes:["Federation now reduces the soldier requirement of occupied cities by 5.","Fixed incorrect Industrious string."]},{version:"0.8.2",date:"3/30/2020",changes:["Piracy in the Gateway and Stargate regions ramp up more slowly as you explore Andromeda.","Fixed formatting of multiline Crafting Tooltip cost display.","Fixed incorrect string used by completed Dyson Sphere."]},{version:"0.8.1",date:"3/29/2020",changes:["Piracy now slowly takes effect in the Gateway System and Stargate region over 1000 days after piracy begins.","Purchasing Negotiator and levels of Persuasive will now update the regular Market as well as the Galactic Market.","Added new CRISPR upgrade effects from the Challenge, Ancients, and Trader trees to the perks list.","Queued Monuments will update their name in the queue when a Monument is constructed.","Fixed bug where ARPA projects at the end of the Queue while No Queue Order was active would cause No Queue Order to not work as intended.","The name of the trait gained from a Mutation in the message is now localized.","Adding Apex Predator will remove currently obtained Armor techs.",'Annexed/Purchased powers will now have a respective " - Annexed"/" - Purchased" tag next to their name, like Occupied powers do.',"Blackhole reset gives its proper reward again.","The amount of Gene/Phage levels of Minor Traits purchased is now affected by Multiplier Keys.","The amount of Ships moved from one area to another is now affected by Multiplier Keys.","Manual Crafting button tooltips are more informational.","Constructing the first Foundry of a game will log a message briefly explaining what Crafted Resources are and the ways to make them.","Informative messages (mission results, messages that explain newly unlocked mechanics, the Launch Facility message that informs the player of the space tab, etc.) are now displayed in blue, to separate them from less important messages.","Added the missing Wormhole Mission result string."]},{version:"0.8.0",date:"3/27/2020",changes:["Intergalactic Content.","Universe Mastery Rework.","-Each Universe now tracks its own mastery level responsible for 40% of the mastery bonus, the remaining 60% comes from the general mastery level.","-Standard Universe mastery rules remains unchanged.","Micro icons can now be earned for none Micro achievements. These will not count for standard mastery, only Micro mastery.","Unification 3.0, the unification system has been reworked.","Federation Government type.","New Faith CRISPR line of upgrades, unlocks priest job.","Universal, Standard and Mastered CRISPR Upgrades, for masters of the universes.","Added Negotiator CRISPR upgrade.","Added Persuasive Minor Gene.","Extended the Deify and Study Ancients tech trees.","Enhanced Droids upgrade for War Droids.","Repair Droids for Fortress.","Smoldering and Chilled now have reduced effectiveness after 100 stacks.","Removed Heavy Genus Feats, these were redundant with Universe Icons.","Blackhole reset now also grants species level extinction achievement.","Power cost of Mass Ejector increased to 3kW.","Genetics lab custom mutation costs rescaled to static values depending on the genetic trait.","Colonists will now be automatically assigned when a Living Quarter is completed if the default job has any available citizens.","Biodome redesigned, produces less food but increases living quarter capacity for Citizens.","More robust research categories.","Various racial traits now apply to ARPA projects.","Human Creative trait rescaled.","Large cost creep penalty reduced to 0.005 from 0.01.","Strong gathering bonus increased from 2 to 5.","Compact lowered from -0.02 to -0.015."]},{version:"0.7.28",date:"3/16/2020",changes:["Antimatter Universe now gives a 10% prestige bonus post MAD.","St. Patrick's Day event.","Blood War can no longer be earned by none demonic evil races.","Build Crate/Container buttons now update create/container values when upgraded by research."]},{version:"0.7.27",date:"3/10/2020",changes:["Memory leak fixes."]},{version:"0.7.26",date:"3/5/2020",changes:["Any race where the associated extinction achievement has been unlocked is now always available during evolution.","Joyless perk changed to +2% Max Morale per star level.","The effects of the Mass Extinction and Creator perks have been swapped.","Creator perk (old mass extinction) changed to 1.5x / 2x / 2.5x / 3x / 3.5x genes gained on mutation.","Minor traits bought with Phage now count twice when you complete evolution."]},{version:"0.7.25",date:"2/26/2020",changes:["Unicorn Shrine bonus is now determined by the moon phase when constructed.","Shrine Knowledge bonus now applies an additional affect to universities.","Smelters in Evil universe when using Kindling Kindred default to Flesh instead of Coal.","Evil Wendigo Smelters correctly display that they use 1 Flesh/s instead of 3 Souls/s. Also fixed the bug where they end up using 3 Flesh/s instead of 1.","Fixed bug where the Evil Wendigo Reclaimer description would show the Lumberjack description.","If Containers have not yet been unlocked as a resource, getting a Wharf will unlock it.","Fixed bug where, if Freight Trains was gotten after ARPA, the Railway project would need a refresh to appear."]},{version:"0.7.24",date:"2/12/2020",changes:["Special Prestige icons awarded to players from certain feats can now be set to replace the standard Star icon."]},{version:"0.7.23",date:"2/11/2020",changes:["Steelen Challenge now requires Bioseed as its win condition.","Added Feat for Blackhole reset with Steelen Challenge.","Added V-Day Event stuff."]},{version:"0.7.22",date:"2/9/2020",changes:["Steelen Challenge.","Graveyards are now removed upon gaining Kindling Kindred.","If Default job is set to Farmer/Lumberjack for Carnivore/Kindling Kindred, it will be changed to Unemployed upon adding those traits.","Fixed bug where gaining Carnivore and having no Grain Mills would make Smokehouses unpurchasable until refresh.","Cargo Yard now requires the construction of a Transfer Station to be unlocked.","Mitosis/Metaphase effect now appears on perks list."]},{version:"0.7.21",date:"1/28/2020",changes:["More bug fixes."]},{version:"0.7.20",date:"1/20/2020",changes:["Bug Fixes by Beorseder.","Fixed bug where purchasing Multicellular would double DNA generation from Nuclei instead of Bilateral Symmetry/Poikilohydric/Spores.","New population from the Infectious trait now go into the set Default job, instead of always Unemployed.","Controlled Mutation will no longer offer conflicting traits."]},{version:"0.7.19",date:"1/14/2020",changes:["Bug Fixes."]},{version:"0.7.18",date:"1/12/2020",changes:["Theocracy temple bonus raised from 5% to 12%.","Technocracy knowledge discount raised from 5% to 8%.","Corpocracy Casino Bonus raised from +100% to +200%.","Corpocracy Luxury Good Bonus raised from +50% to +150%.","Corpocracy Tourism Bonus raised from +50% to +100%.","Corpocracy morale penalty lowered from -15% to -10%.","Corpocracy Manufacturing Bonus raised from +15% to +20%.","Miner's Dream now scales the information that is revealed depending on the star level of the achievement.","Slaves now appear as a resource.","Alternate universes now award icons for complex achievements."]},{version:"0.7.17",date:"1/9/2020",changes:["Fixed an issue with displaying foreign powers in civics tab on unlock."]},{version:"0.7.16",date:"1/8/2020",changes:["Exploration Missions can be queued again.","The game will now notify the user if the current version is out of date.","Changes by Beorseder.","Geology deposit aesthetic changes on planet selection.","Miner's Dream Achievement & Perk."]},{version:"0.7.15",date:"1/7/2020",changes:["Queueing the World Collider will no longer lag the game.","Multi-segment projects will now have extra segments cleared from the queue on completion.","Spy and Government related popovers that would sometimes get stuck open will now clear.","Queued projects that will not complete due to lack of production will now display a green [Never] instead of -1 second timer.","Multi-segment projects no longer block queueing ARPA projects unless they consumed the entire queue space."]},{version:"0.7.14",date:"12/31/2019",changes:["Research Categorization option by Naryl."]},{version:"0.7.13",date:"12/30/2019",changes:["Gene decay will no longer result in a negative plasmid count.","Gene fortification is slightly more effective."]},{version:"0.7.12",date:"12/19/2019",changes:["Gene Fortification.","Fixed Cultural Supremacy popover."]},{version:"0.7.11",date:"12/15/2019",changes:["Decaying resources will now use a warning color if you are losing that resource but at a slower rate then the decay rate.","The most bottlenecked resource will now display in red while other trouble resources will be marked with an alert color.","CRISPR upgrades are now darkened when unaffordable.","Transfer Station now lists its uranium storage.","Wendigo bug fixes."]},{version:"0.7.10",date:"12/12/2019",changes:["Craftsman now continuously output product instead of once/twice a month.","Cumulative achievements now check for lower tier unlocks."]},{version:"0.7.9",date:"12/7/2019",changes:["Many bug fixes."]},{version:"0.7.8",date:"12/6/2019",changes:["The default job can now be set to: Unemployed, Farmer, Lumberjack, Quarry Worker, or Scavenger.","New line of feats for achievement hunting.","Novice Perk.","Journeyman Perk."]},{version:"0.7.7",date:"12/5/2019",changes:["Super projects now queue in larger batches.","Super projects now only report completion by the queue if actually complete instead of for each segment constructed."]},{version:"0.7.6",date:"12/2/2019",changes:["Adjacent queue items of the same type will now combine.","Architect now doubles queue sizes instead of adding a flat +2.","Misc minor bug fixes."]},{version:"0.7.5",date:"11/28/2019",changes:["Queueing 2x or more of the same building in a row will now stack them in the queue.","Queue timer now adjusts for cost creep.","ARPA Projects can now be queued.","Fixed a bug that could break the game when Yeti or Wendigo unlocked the genetics lab."]},{version:"0.7.4",date:"11/27/2019",changes:["Wendigo can now build hunting lodges.","Trade route prices are now tracked to 1 decimal.","Elusive spies will no longer be killed when they fail a mission.","Disruptor Rifles now require researching Quantum Entanglement."]},{version:"0.7.3",date:"11/26/2019",changes:["Night Theme trade volume control made more night theme friendly.","Contrast improvements for Night and R/G Theme."]},{version:"0.7.2",date:"11/24/2019",changes:["New market buy/sell volume control.","Large Trade upgrade now raises the buy/sell cap to 5,000.","Massive Trades upgrade now raises the buy/sell cap to 1,000,000.","Various bug fixes by Beorseder."]},{version:"0.7.1",date:"11/23/2019",changes:["Garrison controls reintegrated into government section.","Mutation plasmids now track correctly in no plasmid challenge runs.","Fixed many issues with foreign power name generation.","Feat star icon is no longer tiny."]},{version:"0.7.0",date:"11/21/2019",changes:["Establish a Government.","Battle rival cities.","Biome races added for Forest, Desert, Tundra, and Volcanic.","New ARPA Project: Railway.","New CRISPR upgrades: Mitosis & Metaphase.","Construct advanced AI stations in deep space.","Rapid Gene Sequencing upgrade.","Civics tab split into Government, Industry, and Military sections.","Inspiration no longer adds an upfront knowledge bonus.","Vigilante requirement lowered to 12.","Xenophobic replaced with Wasteful.","Added Rocky Road Feat.","Configurable number notations."]},{version:"0.6.27",date:"11/12/2019",changes:["Tundra planets are now always cold in winter.","Volcanic planets are now always hot in summer.","Stormy planets are now more likely to be windy.","Fixed issue with last rites not showing up as affordable.","2-4x Challenge Multipliers changed:.","2 Challenges: +12% Prestige.","3 Challenges: +25% Prestige.","4 Challenges: +45% Prestige.","Heavy Universe prestige bonus now scales with challenge level:.","0 Challenges: +5% Prestige.","1 Challenge: +10% Prestige.","2 Challenges: +15% Prestige.","3 Challenges: +20% Prestige.","4 Challenges: +25% Prestige."]},{version:"0.6.26",date:"11/7/2019",changes:["ARPA costs now update without mousing off and back on the buttons.","Fixed issues with incorrectly powering on newly built structures.","None-demonic evil smelters now correctly state they burn 1 flesh/s.","Added whitehole perk to stats page."]},{version:"0.6.25",date:"11/2/2019",changes:["Geology bonus is now preserved on MAD reset.","Key Mappings are now configurable for multiplier and queue keys."]},{version:"0.6.24",date:"10/31/2019",changes:["The Halloween feat will now unlock inside a micro universe."]},{version:"0.6.23",date:"10/28/2019",changes:["Exotic mass now counts towards Galactic Landfill and Supermassive.","Fixed issues with queue timers and kindling kindred trait.","Dark Energy now applies to windmills in antimatter universe."]},{version:"0.6.22",date:"10/26/2019",changes:["Game optimizations.","Bug fixes for queues.","Fixed bug with war droids."]},{version:"0.6.21",date:"10/24/2019",changes:["Freight Train upgrade now adds a trade route to freight yards instead of trade posts.","Toxic troll achievement.","Spatial reasoning rounding fix."]},{version:"0.6.20",date:"10/21/2019",changes:["Fixed application of plasmids with antiplasmids.","Updated description of bleeding effect.","Added achievement for synthesizing an anti-plasmid.","More readable achievement page."]},{version:"0.6.19",date:"10/20/2019",changes:["Fixed power errors with hell dimension turrets.","Crate/Container rounding is now applied after spatial reasoning.","Added extra text to the asteroid belt description to call out the necessity of assigning space miners.","Evil Ents can now burn flesh in the smelter."]},{version:"0.6.18",date:"10/16/2019",changes:["Swarm Satellite redesign.","Swarm Satellites cost and output decreased.","Control Stations can now control 10/18 swarm satellites.","Iron mining ship swarm plant discount now applies to all swarm plant costs.","New upgrades to increase output of swarm satellites."]},{version:"0.6.17",date:"10/14/2019",changes:['"Q" key now works with research queue.',"Added settings option to not enforce queue order.","Decay challenge no longer shows the star level for Joyless.","All universe types can now be seen on achievements.","Genus completion is now marked on sentience.","Challenges can now be toggled during evolution.","Inspiration event now gives a temporary buff to all science production.","Added Slave Market for slaver races to buy slaves as an alternative to catching them.","Added Crate/Container storage amount to the build crate/container tooltip.","Added a button to cancel all trade routes for each resource."]},{version:"0.6.16",date:"10/13/2019",changes:["Employment is now color coded depending on staffing levels.","GPS satellites now add additional trade routes.","Added stats tracking on reset mechanics used.","Added a message when completing the launch facility.","Added icons to challenges and races in evolution stage to indicate level of challenge completion."]},{version:"0.6.15",date:"10/11/2019",changes:["Added a settings option to disable the queue hot key.","The queue hot key is now disabled by default because it breaks the game for some users."]},{version:"0.6.14",date:"10/9/2019",changes:["Fixed several bugs with celestial races.","Only one demonic invasion event is now required to reach a hellscape planet.","New city categorization can now be switched off in the settings tab.","Holding Q while clicking a building will now queue it instead of constructing it."]},{version:"0.6.13",date:"10/7/2019",changes:["Fixed bioseed reset bug when seeding from a planet without a special property."]},{version:"0.6.12",date:"10/6/2019",changes:["Added a hire merc option to fortress, mercs hired here go directly to the fortress.","Default patrol size is now 10 instead of 4.","Adjusted margins in city tab/space tabs to slightly reduce vertical scrolling.","New Tower of Babel flair."]},{version:"0.6.11",date:"10/5/2019",changes:["New planetary modifiers: Toxic, Mellow, Rage, Stormy, Ozone, Magnetic, and Trashed.","City Categorization by NotOats.","Chinese Translation."]},{version:"0.6.10",date:"10/1/2019",changes:["Fixed issue with gene editing costing the wrong type of Plasmid.","Fixed Bone label in Graphene plant.","Fixed issue with Plywood not unlocking when removing Kindling Kindred trait."]},{version:"0.6.9",date:"9/30/2019",changes:["Antimatter Universe.","Bleeding Effect line of CRISPR upgrades, requires Anti-Plasmids to unlock.","Balorg can now unlock queues.","Fixed aria labels in mass ejector."]},{version:"0.6.8",date:"9/24/2019",changes:["Queue reordering no longer swaps the dragged item with the one in the target spot.","Added timers to research queue.","Cost adjustments are now applied to queue timers increasing their accuracy."]},{version:"0.6.7",date:"9/24/2019",changes:["Cath windmills now generate power instead of just looking pretty.","Fixed Spanish strings file, language now loads again."]},{version:"0.6.6",date:"9/23/2019",changes:["Added special tech tree to sacrificial altar to boost its effectiveness per sacrifice.","Restored windmills to cath.","Challenge Multiplier Dark Energy rounding calculation fixed.","Added extra information to blackhole description when it reaches destabilization point.","Added a warning to stabilize option that it will reset your exotic matter."]},{version:"0.6.5",date:"9/21/2019",changes:["Fixed display issue with frenzy appearing to never drop below 1%.","Updated the tooltip values on farms and farmers to include the hellscape penalty.","Fixed Evil Ents so they start with Gather Stone option."]},{version:"0.6.4",date:"9/19/2019",changes:["Fixed double windmill issue with evil universe races.","Spanish language updates.","Added warnings to challenge modes in micro universe that you will not receive credit."]},{version:"0.6.3",date:"9/17/2019",changes:["Restored broken perks."]},{version:"0.6.2",date:"9/17/2019",changes:["Bug Fixes."]},{version:"0.6.1",date:"9/17/2019",changes:["Universe Update, explore ~~ 4 ~~ 3 new universe types:.","Heavy Gravity Universe.","Micro Universe.","Evil Universe.","New Decay Challenge.","Antimatter universe is still forming, coming soon.","Dark Energy effects added, unique per universe type.","New Plasmid scaling formula.","Blackhole mass added to Stellar Engine.","Stuff I probably forgot about."]},{version:"0.5.18",date:"9/11/2019",changes:["Spanish translation provided by RanaPeluda.","Fixed Ent fanaticism.","Modals are no longer unnecessarily wide.","Smelter modal now shows the fuel production for each type."]},{version:"0.5.17",date:"9/5/2019",changes:["Mantis Frail trait replaced with new Cannibalize trait, eat your own citizens for buffs.","The Fortress will now remember the number of troops assigned to it and attempt to keep it at that level."]},{version:"0.5.16",date:"9/3/2019",changes:["Made some adjustments to Soul Gem drop odds.","Added a message when you discover your first Soul Gem."]},{version:"0.5.15",date:"9/1/2019",changes:["Portuguese translations updated by Rodrigodd."]},{version:"0.5.14",date:"9/1/2019",changes:["Buildings will no longer be added to the queue if holding down a multiplier key.","Fixed a problem with smelters that could cause their production to become stuck in a high state.","Fixed initial display state of containers in storage management tab."]},{version:"0.5.13",date:"8/30/2019",changes:["New layout for selecting challenge genes/modes during end of evolution stage.","Fixed bug with low support elerium miners that caused them to miscalculate miner outputs.","Added a threat level warning to fortress."]},{version:"0.5.12",date:"8/30/2019",changes:["Pacifist Achievement is now unlocked by unifying without ever initiating an attack."]},{version:"0.5.11",date:"8/28/2019",changes:["Fixed issue with nucleus DNA bonus not applying from correct cell stage evolutions.","Building timers now count down without refreshing the popover.","Long action titles will now wrap instead of overflowing the button.","Fixed a bug that could cause the research queue to clear items from the building queue."]},{version:"0.5.10",date:"8/28/2019",changes:["Fixed bug with some construction projects not refreshing the page after being built with the queue.","Space exploration missions can no longer be queued more then once at a time.","One off projects are now removed from the queue if completed manually.","Queue timers now track crafted resources.","Demonic attractor soul gem drop rate increase buffed from 5% to 8%.","Updated some fortress related tooltips.","Mousing over the star rating in the top left corner now lists which challenges are active.","Time until ready added to unaffordable actions."]},{version:"0.5.9",date:"8/27/2019",changes:["Active build queues wiped due do internal game breaking format change."]},{version:"0.5.8",date:"8/27/2019",changes:["Construction timers added to build queue.","Construction and research completed by queues are now logged to the message list.","Improved drag and drop support for queues."]},{version:"0.5.7",date:"8/25/2019",changes:["Drag support for queue sorting.","Fixed resource display bug that occurred when buying a mass ejector.","Minor traits now show the number of ranks from phage or genes spent."]},{version:"0.5.6",date:"8/23/2019",changes:["Building queue now works in space.","Added a separate research queue.","Fixed rock quarry awarding 4% stone bonus instead of the stated 2%.","Fixed rendering bugs with the blackhole and mass ejector."]},{version:"0.5.5",date:"8/22/2019",changes:["Bug Fixes for queueing system."]},{version:"0.5.4",date:"8/22/2019",changes:["Building Queue system v1.0.","Urban Planning, Zoning Permits, and Urbanization queue related techs.","New CRISPR upgrades for enhanced queueing."]},{version:"0.5.3",date:"8/20/2019",changes:["Stats and Achievements separated into separate sub tabs.","Disruptor rifle upgrade for soldiers.","Mass Ejector can no longer be unlocked before completing the Stellar Engine."]},{version:"0.5.2",date:"8/20/2019",changes:["Fixed misnamed mantis trait key.","Fixed Iron smelter paying out 10x intended amount."]},{version:"0.5.1",date:"8/20/2019",changes:["Disappearing craftsman fix."]},{version:"0.5.0",date:"8/19/2019",changes:["Interstellar space is now unlockable.","Interdimensional travel is now unlockable.","New management tab for Crates & Containers.","Power generation breakdown.","Improved resource breakdown layout.","Leathery trait buffed.","Chameleon trait now adds a combat rating bonus.","Optimistic now also applies to the minimum morale rating.","Smarter Smelter fuel switching.","New CRISPR unlocks."]},{version:"0.4.42",date:"8/16/2019",changes:["Fixed some screen reader issues with the crate modal launch button.","Added a warning to the Genetic Dead End challenge if you are on a hellscape planet."]},{version:"0.4.41",date:"8/15/2019",changes:["Joyless Challenge.","??? - Nothing to see here, move along."]},{version:"0.4.40",date:"8/9/2019",changes:["Changed No Crispr gene into the Weak Crispr gene."]},{version:"0.4.39",date:"8/6/2019",changes:["Genetic Disaster Challenge."]},{version:"0.4.38",date:"8/5/2019",changes:["Special action icon is now properly flagged as a button."]},{version:"0.4.37",date:"7/31/2019",changes:["ARIA Improvements for Factory and A.R.P.A."]},{version:"0.4.36",date:"7/27/2019",changes:["Slow and Hyper traits can now combine.","Added new achievements: Creator & Explorer.","Added perks for Mass Extinction, Creator, and Explorer."]},{version:"0.4.35",date:"7/25/2019",changes:["Centaur can now pick Fanaticism.","Challenge multiplier is now applied to phage gain."]},{version:"0.4.34",date:"7/23/2019",changes:["Fixed SR descriptions of buildings that lack affordability.","Fixed resource highlighting of buildings that have zero costs."]},{version:"0.4.33",date:"7/23/2019",changes:["Fixes for Ent Fanaticism not releasing some resources.","Aria improvements for the smelter modal.","Improved screen reader resource affordability description of buildings/research.","Resource highlighting on structures."]},{version:"0.4.32",date:"7/21/2019",changes:["Balorg slaver trait added.","Ziggurat bonus now applies to the oil extractor.","Geology Oil rich/poor no longer applies to oil extractor.","Added resource alternate row coloring.","Added an affordability hint for screen readers.","Fixed some bugs with awarding a random minor trait from fanaticism.","Dimensional Compression now charges the correct cost."]},{version:"0.4.31",date:"7/20/2019",changes:["Extreme Dazzle casino upgrade.","Metallurgist minor trait, buffs alloy.","Gambler minor trait, buffs casinos.","A.R.P.A. projects now use resource approximations for large numbers.","Cement Factory renamed to Cement Plant to reduce confusion with the regular Factory.","Key multipliers now work inside the factory modal.","Imps and Balorg now have access to advanced crafting tech.","Imps and Balorg now have access to windmills.","Balorg can now set their taxes below 10% and above 30%."]},{version:"0.4.30",date:"7/19/2019",changes:["Portuguese translation by Rodrigodd.","DNA Sequencer upgrade.","Gene Assembly cost increase to 200k.","Synthesis now applies a bonus to auto crafted genes.","Ambidextrous buffed.","Ambidextrous now has a greater effect on auto crafting."]},{version:"0.4.29",date:"7/18/2019",changes:["Genetic modification system, customize your race with minor traits.","Shotgun Sequencing upgrade for genome research.","Randomly gained minor traits will no longer stack unless they have all been unlocked.","Genes are now gained from random mutations.","Synthesis line of CRISPR upgrades.","Satellite and Observatory cost reductions.","Fibroblast minor trait.","Iridium is now unlocked by constructing an iridium mine instead of the moon base.","Helium-3 is now unlocked by constructing a helium-3 mine instead of the moon base.","Genome sequencing now defaults to on when first unlocked."]},{version:"0.4.28",date:"7/16/2019",changes:["Added missing hellscape achievement.","Fixed spatial reasoning and phage interaction.","Fixed warmonger unlocking requirement."]},{version:"0.4.27",date:"7/13/2019",changes:["Added special action description buttons for screen readers."]},{version:"0.4.26",date:"7/12/2019",changes:["Unlocked CRISPR upgrades are now listed as perks.","Control/Shift/Alt click now works with power on and off buttons."]},{version:"0.4.25",date:"7/11/2019",changes:["Quantum Manufacturing upgrade.","Quantum Swarm cost lowered from 465k to 450k."]},{version:"0.4.24",date:"7/10/2019",changes:["Thermomechanics upgrade for alloy production.","Ziggurats unlockable via ancients upgrade.","Cement factory has a more clear label in breakdown lists."]},{version:"0.4.23",date:"7/7/2019",changes:["Resources at the millions breakpoint and above are now shown with 2 significant decimal points.","Reduced the creep cost of Observatory.","Reduced the base knowledge cost of Observatory.","Reduced the Brick cost of Boot Camps.","Evil has been unleashed."]},{version:"0.4.22",date:"7/6/2019",changes:["Fixed issue with having exactly 251 Plasmids that would break your resources.","Fixed issue with planet generation that caused it to always use the same seed."]},{version:"0.4.21",date:"7/6/2019",changes:["Fixed unlocking of mass extinction achievement.","Fixed potential fuel consumption bug with power plants."]},{version:"0.4.20",date:"7/4/2019",changes:["Phage can now be earned from space resets, phage extends the plasmid diminishing return breakpoint.","Dimensional Warping crispr upgrade, applies phages to spatial reasoning.","Added special windmill tech for carnivore path to equalize power grid.","Space Stations now give 5 Elerium storage instead of 4."]},{version:"0.4.19",date:"7/2/2019",changes:["Fixed bugs with the hell planet and gas planet survey mission.","Fixed bug that prevented the planet description tooltip from triggering.","Aluminium now properly requires you to build a metal refinery."]},{version:"0.4.18",date:"7/1/2019",changes:["Planets choice now has more depth to it, each planet can be poor or rich in various resource types.","A mineral poor planet suffers anywhere from 1 to 10% penalty for that resource.","A mineral rich planet gains anywhere from 1 to 20% bonus for that resource.","The fire event no longer triggers for aquatic races.","The first interstellar probe now contributes to the number of potential target worlds.","All interstellar space probe costs are now cheaper."]},{version:"0.4.17",date:"6/29/2019",changes:["Added indication of current challenge level to top bar.","Added H tags for accessibility."]},{version:"0.4.16",date:"6/28/2019",changes:["New Hospital, heals wounded soldiers faster.","New Boot Camp, train new soldiers quicker.","Lowered research cost of Mass Driver from 170k to 160k.","Lowered Iridium cost of Mass Drivers.","Updated Mass Extinction unlock requirement."]},{version:"0.4.15",date:"6/28/2019",changes:["Global bonuses are now multiplicative instead of additive.","Decreased base Elerium cost of Exotic Lab by 4.","Creative trait decreases cost creep instead of providing a flat discount.","ARPA 100% button replaced with remaining percentage value.","New experimental military advice."]},{version:"0.4.14",date:"6/27/2019",changes:["Statues now cost Aluminium instead of Wrought Iron.","Nav Beacon now costs Aluminium instead of Iron.","Helium-3 Mine now costs Aluminium instead of Copper.","Elerium Mining Ship now costs Titanium instead of Iridium.","Iron Mining Ship now costs Aluminium instead of Titanium.","Dimension Compression upgrade now works correctly.","Aluminium can now be looted from battle."]},{version:"0.4.13",date:"6/26/2019",changes:["Aluminium resource added to the game, research Bayer Process to unlock Metal Refinery which in turn unlocks Aluminum.","New Metal Refinery structure for producing Aluminium.","Alloy is now made out of Aluminium and Copper.","Sheet Metal is now made out of Aluminium.","Oil Powerplant and Propellant Depot now cost Aluminium instead of Steel.","Some minor accessibility improvements."]},{version:"0.4.12",date:"6/24/2019",changes:["Blackhole achievement now gives a permanent perk for completing it, the perk strength depends on the achievement level.","Fixed issue with event timer being frozen after changing planets.","Fixed the unlocking of upgraded versions of some achievements.","Cost descriptions now show approximations above 10,000."]},{version:"0.4.11",date:"6/24/2019",changes:["Re-evaluated starvation breakpoint.","Added Infested Terran achievement.","Titanium price is now reset after unlocking Hunter Process.","Resources now have a 25% chance of their market price changing per day, up from 10%."]},{version:"0.4.10",date:"6/23/2019",changes:["Fixed stats tracking on demonic invasions so it actually tracks new invasions."]},{version:"0.4.9",date:"6/23/2019",changes:["Fabrication facilities now increase craftsman cap.","Added stats tracking on demonic invasions.","Detail Oriented buffed to 50% from 33%.","Rigorous buffed to 100% from 66%.","Crafting bonus now shown for each resource.","Temple Faith bonus now applies to crafting in no plasmid challenge mode.","Mastery bonus now applies to crafting."]},{version:"0.4.8",date:"6/22/2019",changes:["Fixed a bug that removed MAD when achieving unification.","Fixed missing options in evolution stage with picking avians after space reset."]},{version:"0.4.7",date:"6/21/2019",changes:["Activating challenge genes now provide a bonus to the number of plasmids earned."]},{version:"0.4.6",date:"6/21/2019",changes:["Reduced Nano Tube and Neutronium costs of bioseeder ship.","Reduced Mythril cost of Space Probes."]},{version:"0.4.5",date:"6/19/2019",changes:["Mastery Bonus now unlockable in CRISPR.","Fixed bug with elerium mining that could cause negative mining when you lacked asteroid miners.","Fixed low power warning not clearing when you have no buildings active.","Fixed Sporgar label of Cottages in Steel & Mythril Beams research.","Gene Mutation research will no longer turn off when you run out of knowledge, instead it will pause.","Human creative trait buffed from 2% to 5%.","Troll regenerative trait buffed to heal 4 wounded per day instead of 2.","Ogre tough trait buffed to 25% from 10%.","Gecko optimistic trait buffed to 10% from 2%.","Arraak resourceful trait buffed from 5% to 10%.","Dracnid hoarder trait buffed from 10% to 20%.","Shroomi toxic trait buffed from 10% to 25%.","Wolven pack mentality trait now applies to apartments.","Reduced Nano Tube cost of Mining Drones."]},{version:"0.4.4",date:"6/18/2019",changes:["Matter compression now applies to Wharves.","Xenophobia now applies to Wharves.","Plasmids earned by mutation now apply to no plasmid challenge run.","Reduced Nano Tube cost of Mining Drones."]},{version:"0.4.3",date:"6/17/2019",changes:["Challenge mode achievement tracking.","Vocational Training for craftsman.","Spelling and grammar fixes.","Fixed incorrect reject unity reward text."]},{version:"0.4.2",date:"6/16/2019",changes:["Added some clarification to breakdown of stress."]},{version:"0.4.1",date:"6/16/2019",changes:["Fixed a bug with factories converted from some pre 0.4.0 save files."]},{version:"0.4.0",date:"6/16/2019",changes:["Space reset option, control the destiny of your next race.","Challenge Modes.","New Stuff to discover.","New Achievements to unlock.","Added missing Cyclops racial trait.","World Domination, maybe.","Added soft reset option."]},{version:"0.3.12",date:"6/11/2019",changes:["Fixed bug with riot event that caused it to trigger on high morale instead of low morale."]},{version:"0.3.11",date:"6/10/2019",changes:["The Gas Moon and the Dwarf planets are now accessible.","New technologies based on new discoveries made in deep space.","Wharves can now be unlocked after discovering oil.","There is now an alternative method of unlocking steel.","Night Theme updated, popovers are no longer bright.","Trade route tooltips now include money being imported or exported.","New crispr upgrades for crafting.","Warmonger achievement requirement lowered from 10% to 8%."]},{version:"0.3.10",date:"6/9/2019",changes:["Added code to fix peculiar failed space launch game state."]},{version:"0.3.9",date:"6/8/2019",changes:["New official Evolve [Discord](https://discordapp.com/invite/dcwdQEr)."]},{version:"0.3.8",date:"6/7/2019",changes:["Fixed a problem with negative craftsman counts that could result from craftsman dying."]},{version:"0.3.7",date:"6/6/2019",changes:["Warmongering is now tracked and high casualties may impact morale.","Depleting the mercenary pool will temporarily increase their cost.","Three new achievements related to war."]},{version:"0.3.6",date:"6/5/2019",changes:["Fixed issue with production breakdowns not showing when income was only produced by trade.","Fixed issue that prevented affordability check from refreshing on space missions."]},{version:"0.3.5",date:"6/5/2019",changes:["Mythril Craftsman now unlock correctly.","Fixed a bug that could pause the game if you ran out of Titanium."]},{version:"0.3.4",date:"6/4/2019",changes:["The Asteroid Belt is now open for business.","Robotics Upgrades.","Automation renamed to Machinery.","Assembly Line upgrade for factory."]},{version:"0.3.3",date:"6/3/2019",changes:["New Orbit Structure: Navigation Beacon.","New Red Planet Structures: Space Control Tower and Space Factory.","Reduced number of monuments required to unlock tourism from 4 to 2.","Cement plant workers now round their contribution to 2 decimal places.","Red planet mining now correctly attributes to the red planet in breakdowns."]},{version:"0.3.2",date:"6/3/2019",changes:["Fixed bug that would let you launch the space missions without the proper resources, this would corrupt your game file and break the game.","Added code to detect games corrupted by the previous bug and fix them.","Fixed Fanaticism bug that wouldn't release lumberjacks when you have ent gods."]},{version:"0.3.1",date:"6/3/2019",changes:["Added building check redundancy to auto correct game states that shouldn't occur anyway."]},{version:"0.3.0",date:"6/2/2019",changes:["Space V1 Update.","This opens the first steps into space exploration, more to come... this is not the end.","Rebalanced storage caps to help the game feel more idle friendly."]},{version:"0.2.70",date:"6/2/2019",changes:["Fixed bug when picking Fanaticism with cath gods that wouldn't release your farmers.","Fixed bug when upgrading weapon technology that wouldn't immediately show the increase in army rating."]},{version:"0.2.69",date:"5/26/2019",changes:["Fixed bug which could let you get free barn or warehouse upgrade by essentially skipping over the tech.","Added aria button roles to many button like elements that were not technically buttons."]},{version:"0.2.68",date:"5/26/2019",changes:["Fixed bug with Rock Quarry that prevented the 2% bonus from working unless you had electricity unlocked."]},{version:"0.2.67",date:"5/24/2019",changes:["Revamp of farmer, lumberjack, and quarry worker jobs. These govern the most basic materials produced and can now assign as many workers as you like to these positions.","Farms now directly produce food instead of determining farmer cap.","Lumber Yards now increase lumber production instead of governing lumberjack cap.","Rock Quarry now increase stone production instead of governing quarry worker cap.","Sawmill powered on bonus reduced from 5% to 4%.","Rock Quarry powered on bonus reduced from 5% to 4%.","Stock Exchanges no longer cost Knowledge.","Fixed a display bug that could cause farmers to falsely show they produced more food then they actual did."]},{version:"0.2.66",date:"5/22/2019",changes:["Added alternate row coloring to the market to help distinguish rows."]},{version:"0.2.65",date:"5/21/2019",changes:["Sporgar race redesigned into a parasitic race that spreads through infecting victims."]},{version:"0.2.64",date:"5/20/2019",changes:["Currency is now required before unlocking Basic Storage.","Primitive Axes are no longer gated behind Basic Storage.","Foundry now requires Metal Working to unlock and no longer requires Cement.","Research tab now defaults back to new when resetting.","Fixed issue with not being able to buy something if you had consumption on a resource and the cost was the same as your max capacity.","Fixed issue with max affordability check not refreshing on evolution stage.","Experimental Red-Green color blind theme."]},{version:"0.2.63",date:"5/20/2019",changes:["Fixed an issue that accidentally set the default tax rate to 2% instead of 20% for new games."]},{version:"0.2.62",date:"5/19/2019",changes:["Tax system revamped. Taxes can now be adjusted more granularly and effect morale instead of production.","Cement is now a requirement for theology since cement is needed for temples."]},{version:"0.2.61",date:"5/19/2019",changes:["Every genus type now has its own evolution path."]},{version:"0.2.60",date:"5/18/2019",changes:["Rescaled crate/container volumes. There are now substantially less crates/containers but they do a lot more per crate/container.","Spatial Reasoning now correctly applies to crates & containers.","Increased base value of several major storage facilities.","Added storage timers.","A.R.P.A. costs in popover now update their affordability check.","Buildings and Research that can not be afforded due to low capacity are now marked in red text."]},{version:"0.2.59",date:"5/17/2019",changes:["Added additional validation to ensure save strings belong to evolve before importing.","Fixed army rating display when rating doesn't calculate to a whole number.","Fixed listing order of some resources.","Smelter Iron bonus breakdown fixed.","Added Selenophobia to breakdown lists."]},{version:"0.2.58",date:"5/15/2019",changes:["Settings option to disable multiplier keys."]},{version:"0.2.57",date:"5/15/2019",changes:["Added labor validation to coal miners.","Key Multipliers now work with job and trade route assignment."]},{version:"0.2.56",date:"5/15/2019",changes:["Added +- symbols to trade route to distinguish import vs export."]},{version:"0.2.55",date:"5/14/2019",changes:["Manually crafting resources now gets all the same bonuses as auto crafting.","Fixed Recombination crispr upgrade.","Death limits added to each war campaign level.","War assessment added for each war campaign level."]},{version:"0.2.54",date:"5/13/2019",changes:["Uranium Breakdown Fixes."]},{version:"0.2.53",date:"5/13/2019",changes:["Breakdown Accuracy Enhancements.","Some Kindling Kindred costs reduced.","Fixed bug related to Fanaticism and Ent gods with foundry workers assigned to make plywood.","Plasmid bonus now applies to the sundial.","Fixed some spelling errors."]},{version:"0.2.52",date:"5/11/2019",changes:["Completed research can now be viewed on a separate tab under research.","Removed Plywood requirement from Stock Exchange for players with Kindling Kindred trait.","Fixed a CSS issue in the A.R.P.A. projects tab."]},{version:"0.2.51",date:"5/11/2019",changes:["University starts slightly cheaper.","Added Spatial Superiority crispr upgrade.","Added Spatial Supremacy crispr upgrade.","Exporting a save string now automatically selects the text and copies it to the clipboard."]},{version:"0.2.50",date:"5/10/2019",changes:["Added new capacity breakdowns for various resources."]},{version:"0.2.49",date:"5/10/2019",changes:["Added changelog link to version listing.","Added protection against loading a corrupt save string.","Greedy trait is now less greedy.","Spelling error fixes."]},{version:"0.2.48",date:"5/8/2019",changes:["Resources that are at greater then 99% capacity now change color to indicate they are at cap.","Attacks from rival cities should no longer cause more wounded soldiers then you have.","Assigning craftsman when no citizens are free will no longer take the labor from another job."]},{version:"0.2.47",date:"5/8/2019",changes:["Gluttony trait lowered to 10% from 25% .","High Metabolism trait lowered to 5% from 10% .","Fixed Sheet Metal not being added to craftsman list when unlocked."]},{version:"0.2.46",date:"5/8/2019",changes:["The 5% library bonus was only applying to scientists which was not intended. This now applies to the sundial and professors as well."]},{version:"0.2.45",date:"5/8/2019",changes:["Fixed an issue that allowed you to get extra benefits from under-powered wardenclyffe towers and biolabs."]},{version:"0.2.44",date:"5/8/2019",changes:["Fixed Key Multipliers getting stuck down."]},{version:"0.2.43",date:"5/7/2019",changes:["Fixed bug that could cause player to get free extra crafted resources when using the +5 option.","Reordered buildings in Village tab to group them more logically."]},{version:"0.2.42",date:"5/7/2019",changes:["Fixed a bug that was causing soldiers to become immortal.","Fixed some bugs with morale that caused some weather patterns to apply a different value then was reported.","Added weather to Food breakdown."]},{version:"0.2.41",date:"5/7/2019",changes:["Added a 5% bonus to global knowledge production on libraries."]},{version:"0.2.40",date:"5/7/2019",changes:["The Hivemind trait no longer applies to farmers as this was especially punishing."]},{version:"0.2.39",date:"5/7/2019",changes:["Evolution 2.0: Redid the evolution stage of the game to make it feel less tedious and like it matters more to the next phase of the game.","Fixed a bug that has the intended effects of Pessimism and Optimism traits swapped."]},{version:"0.2.38",date:"5/6/2019",changes:["First public release."]}];function go(){t.settings.expose&&(window.evolve={actions:zc(Qr),races:zc(di),traits:zc(ui),tradeRatio:zc(Za),craftCost:zc(Ya()),atomic_mass:zc(Va),f_rate:zc(Qs),checkAffordable:zc(Cs),adjustCosts:zc(gc),armyRating:zc(ke),tradeBuyPrice:zc(yr),tradeSellPrice:zc(vr),fuel_adjust:zc(Jt),int_fuel_adjust:zc(Yt),alevel:zc(ro),messageQueue:zc(Di),loc:zc(F),shipCosts:zc(ut),updateDebugData:zc(fo),global:{},breakdown:{}})}function fo(){t.settings.expose&&(window.evolve.global=zc(t),window.evolve.craftCost=zc(Ya()),window.evolve.breakdown=zc(r))}$(document).ready((function(){if(window.matchMedia){var e=$('head > link[rel="icon"][media]');$.each(e,(function(t,a){var r=window.matchMedia(a.media);function s(){r.matches&&(e.remove(),e=$(a).appendTo("head"))}r.addListener(s),s()}))}}));var vo=!1;window.addEventListener("storage",(e=>{!1===vo&&Di(F("multitab_warning"),"danger",!0),vo=!0})),t.settings.expose&&go();var yo={showCiv:1,showCivic:2,showResearch:3,showResources:4,showGenetics:5,showAchieve:6,settings:7};$(document).keydown((function(e){let a=(e=e||window.event).key||e.keyCode;Object.keys(v).forEach((function(e){a===t.settings.keyMap[e]&&(v[e]=!0)})),$("input").is(":focus")||$("textarea").is(":focus")||Object.keys(yo).forEach((function(e){a!==t.settings.keyMap[e]||0===t.settings.civTabs||"settings"!==e&&!t.settings[e]||(t.settings.civTabs=yo[e],t.settings.tabLoad||Ct(t.settings.civTabs))}))})),$(document).keyup((function(e){let a=(e=e||window.event).key||e.keyCode;Object.keys(v).forEach((function(e){a===t.settings.keyMap[e]&&(v[e]=!1)}))})),$(document).mousemove((function(e){e=e||window.event,Object.keys(t.settings.keyMap).forEach((function(a){switch(t.settings.keyMap[a]){case"Shift":case 16:v[a]=!!e.shiftKey;break;case"Control":case 17:v[a]=!!e.ctrlKey;break;case"Alt":case 18:v[a]=!!e.altKey;break;case"Meta":case 91:v[a]=!!e.metaKey}}))})),function(){rc($("body")),$("html").addClass(t.settings.font),$("body").append(`
              \n

              Top Bar

              \n {{ race.species | planet }}{{ race.universe | universe }}${F("evo_challenge_simulation")}\n \n \n \n \n \n ${F("year")} {{ city.calendar.year }}\n ${F("day")} {{ city.calendar.day }}\n \n \n {{ s.at / (s.atMultiplier - 1) | remain }}\n \n \n \n \n
              `);let e=$('
              '),a=$('
              ');$("body").append(e),e.append(a),a.append(`
              \n
              \n

              Race Info

              \n
              {{ name() }}
              \n
              ${F("morale")} {{ city.morale.current | mRound }}%
              \n
              MW {{ city.power | replicate | approx }}
              \n
              \n
              \n
              \n
              \n
              \n

              ${F("message_log")}

              \n \n \n \n \n \n ${F("message_log_clear")}\n ${F("message_log_clear_all")}\n
              \n

              ${F("message_filters")}

              \n
              \n

              ${F("messages")}

              \n
              \n
              \n
              \n

              ${F("tab_resources")}

              \n
              `),h.forEach((function(e){$("#msgQueueFilters").append(`\n ${F("message_log_"+e)}\n `)})),sc({el:"#msgQueue",data:{m:p,s:t.settings.msgFilters},methods:{swapFilter(e){if(p.view!==e){$(`#msgQueueFilter-${p.view}`).removeClass("is-active"),$(`#msgQueueFilter-${e}`).addClass("is-active"),p.view=e;let t=$("#msgQueueLog");rc(t),p[e].forEach((function(e){t.append($('

              '+e.msg+"

              "))}))}},clearLog(e){Ni(e=e?[e]:e),rc($("#msgQueueLog")),e?t.lastMsg[e]=[]:Object.keys(t.lastMsg).forEach((function(e){t.lastMsg[e]=[]}))},trigModal(){this.$buefy.modal.open({parent:this,component:{template:''}});let e=setInterval((function(){if($("#modalBox").length>0){clearInterval(e);let r=$c(16,12);$("#modalBox").append($(`

              ${F("message_log")}${r.length>0?r:""}

              `));var a=$('
              ');$("#modalBox").append(a);let s=$(`\n
              \n
              \n ${F("message_log_settings_visible")}\n
              \n
              \n `),i=$(`\n
              \n
              \n
              \n ${F("message_log_settings_length")}\n
              \n
              \n `),c=$(`\n
              \n
              \n
              \n ${F("message_log_settings_save")}\n
              \n
              \n `);a.append(s),a.append(i),a.append(c);let o="",n="",l="",u={},d={};h.forEach((function(e){o+=`
              ${F("message_log_"+e)}
              `,n+=`
              ${F("message_log_"+e)}
              `,l+=`
              ${F("message_log_"+e)}
              `,u[e]=t.settings.msgFilters[e].max,d[e]=t.settings.msgFilters[e].save})),s.append(o),i.append(n),c.append(l),i.append(`\n
              \n \n
              \n `),c.append(`\n
              \n \n
              \n `),sc({el:"#specialModal",data:{s:t.settings.msgFilters,mi:u,si:d},methods:{check(e){if(!t.settings.msgFilters[e].vis&&p.view===e){let e=!1;Object.keys(t.settings.msgFilters).forEach((function(a){if(t.settings.msgFilters[a].vis&&!e){e=!0,$(`#msgQueueFilter-${p.view}`).removeClass("is-active"),$(`#msgQueueFilter-${a}`).addClass("is-active"),p.view=a;let t=$("#msgQueueLog");rc(t),p[a].forEach((function(e){t.append($('

              '+e.msg+"

              "))}))}}))}},checkDisabled(e,a){if(!t.settings.msgFilters[e].vis)return!1;let r=0;return Object.keys(t.settings.msgFilters).forEach((function(e){t.settings.msgFilters[e].vis&&r++})),1===r},maxVal(e){u[e]<1&&(u[e]=1)},saveVal(e){d[e]<0?d[e]=0:d[e]>t.settings.msgFilters[e].max&&(d[e]=t.settings.msgFilters[e].max)},applyMax(){h.forEach((function(e){let a=u[e];t.settings.msgFilters[e].max=a,a');a.append(r);let s=$('
              ');r.append(s),s.append('

              Tab Navigation

              ');let i=$('');s.append(i);let c=$('\n \n ');i.append(c);let o=$('\n \n
              \n
              ');i.append(o);let n=$('\n \n
              \n
              ');i.append(n);let l=$('\n \n
              \n
              ');i.append(l);let u=$('\n \n
              \n
              ');i.append(u);let d=$('\n \n
              \n
              ');i.append(d);let _=$('\n \n
              \n
              ');i.append(_);let m="",g=[{i:"nuclear",f:"steelem",r:2},{i:"zombie",f:"the_misery",r:2},{i:"fire",f:"ill_advised",r:2},{i:"mask",f:"friday",r:1},{i:"skull",f:"demon_slayer",r:2},{i:"taijitu",f:"equilibrium",r:2},{i:"martini",f:"utopia",r:2},{i:"lightbulb",f:"energetic",r:2},{i:"trash",f:"garbage_pie",r:2},{i:"banana",f:"banana",r:2},{i:"turtle",f:"finish_line",r:2},{i:"floppy",f:"digital_ascension",r:2},{i:"slime",f:"slime_lord",r:2},{i:"lightning",f:"annihilation",r:2},{i:"heart",f:"valentine",r:1},{i:"clover",f:"leprechaun",r:1},{i:"bunny",f:"easter",r:1},{i:"egg",f:"egghunt",r:1},{i:"rocket",f:"launch_day",r:1},{i:"sun",f:"solstice",r:1},{i:"firework",f:"firework",r:1},{i:"ghost",f:"halloween",r:1},{i:"candy",f:"trickortreat",r:1},{i:"turkey",f:"thanksgiving",r:1},{i:"present",f:"xmas",r:1}],f=ro();f<2&&(f=2);for(let e=0;e=g[e].r?m+=`${wc(g[e].i,16,f)} {{ '${g[e].i}' | label }}`:t.settings.icon===g[e].i&&(t.settings.icon="star");let v=$c(9,14),y="";v.length>0&&(y=`${v}`);let b=kc(5,12,!0),w="";b.length>0&&(w=`${b}`);let x="",k="";Object.keys(z).length>1&&Object.keys(z).forEach((function(e){t.settings.locale===e&&(k=z[e]),x+=`${z[e]}`}));let q=$(`\n \n
              \n {{ 'theme' | label }} \n \n \n {{ 'theme_dark' | label }}\n {{ 'theme_light' | label }}\n {{ 'theme_night' | label }}\n {{ 'theme_darkNight' | label }}\n {{ 'theme_redgreen' | label }}\n {{ 'theme_gruvboxLight' | label }}\n {{ 'theme_gruvboxDark' | label }}\n {{ 'theme_orangeSoda' | label }}\n {{ 'theme_dracula' | label }}\n ${y}\n \n {{ 'units' | label }} \n \n \n {{ 'metric' | label }}\n {{ 'scientific' | label }}\n {{ 'sln' | label }}\n ${w}\n \n\n {{ 'icons' | label }} \n \n \n ${wc("star",16,f)} {{ 'star' | label }}\n ${m}\n \n
              \n
              \n {{ 'locale' | label }} \n \n \n ${x}\n \n\n {{ 'font' | label }} \n \n \n {{ 'standard' | label }}\n {{ 'large_log' | label }}\n {{ 'large_all' | label }}\n \n\n {{ 'q_merge' | label }} \n \n \n {{ 'merge_never' | label }}\n {{ 'merge_nearby' | label }}\n {{ 'merge_all' | label }}\n \n
              \n {{ 'pause' | label }}\n {{ 'm_keys' | label }}\n {{ 'c_cat' | label }}\n {{ 'q_key' | label }}\n {{ 'q_any' | label }}\n {{ 'q_any_res' | label }}\n {{ 's_pack_on' | label }}\n {{ 'expose' | label }}\n {{ 'tabLoad' | label }}\n {{ 'boring' | label }}\n {{ 'touch' | label }}\n
              \n
              ${F("key_mappings")}
              \n
              ${F("multiplier",[10])}
              \n
              ${F("multiplier",[25])}
              \n
              ${F("multiplier",[100])}
              \n
              ${F("q_key")}
              \n
              \n
              \n
              ${F("tab_mappings")}
              \n
              ${F("tab_civil")}
              \n
              ${F("tab_civics")}
              \n
              ${F("tab_research")}
              \n
              ${F("tab_resources")}
              \n
              ${F("tech_arpa")}
              \n
              ${F("tab_stats")}
              \n
              ${F("tab_settings")}
              \n
              \n
              \n \n \n \n
              \n
              \n {{ | sPack}}\n
              \n
              \n \n \n \n \n \n \n \n
              \n
              \n \n {{ 'enable_reset' | label }}\n
              \n
              \n

              \n {{ 'reset_warn' | label }}\n

              \n

              \n \n \n

              \n
              \n
              \n
              \n
              \n
              `);i.append(q);let M=$('\n \n
              \n
              ');i.append(M),a.append('
              ');let P=$c(15,8);$("body").append(`\n
              \n \n

              \n ${P.length>0?`Ev${P}lve`:"Evolve"}\n by\n Demagorddon\n

              \n
              \n \n

              External Links

              \n \n
              \n
              \n `)}();var bo=t.revision?t.revision:"";t.beta?$("#topBar .version > a").html(`v${t.version} Beta ${t.beta}${bo}`):$("#topBar .version > a").html("v"+t.version+bo),Ni(),t.lastMsg&&Object.keys(t.lastMsg).forEach((function(e){t.lastMsg[e].reverse().forEach((function(t){Di(t.m,t.c,!0,[e],!0)})),t.lastMsg[e].reverse()})),$("#msgQueue").height(t.settings.msgQueueHeight),$("#buildQueue").height(t.settings.buildQueueHeight),!0===t.queue.rename&&(Ks(!0),t.queue.rename=!1),t.settings.sPackMsg=e.getItem("string_pack_name")?F("string_pack_using",[e.getItem("string_pack_name")]):F("string_pack_none"),t.queue.display&&Ri(),t.r_queue.display&&Hi(),sc({el:"#mainColumn div:first-child",data:{s:t.settings},methods:{swapTab:e=>(t.settings.tabLoad||Ct(e),e),saveImport(){$("#importExport").val().length>0&&importGame($("#importExport").val())},saveExport(){$("#importExport").val(window.exportGame()),$("#importExport").select(),document.execCommand("copy")},saveExportFile(){const e=new Date;((e,t,a)=>{const r=document.createElement("a"),s=new Blob([e],{type:"text/plain"});r.href=URL.createObjectURL(s),r.download=t,r.click(),URL.revokeObjectURL(r.href)})(window.exportGame(),`evolve-${e.getFullYear()}-${e.getMonth()+1}-${e.getDate()}-${e.getHours()}-${e.getMinutes()}.txt`)},importStringFile(){let a=document.getElementById("stringPackFile").files[0];if(a){let r=new FileReader,s=document.getElementById("stringPackFile").files[0].name;r.readAsText(a,"UTF-8"),r.onload=function(a){try{JSON.parse(a.target.result)}catch{return void(t.settings.sPackMsg=F("string_pack_error",[s]))}t.settings.sPackMsg=F("string_pack_using",[s]),e.setItem("string_pack_name",s),e.setItem("string_pack",LZString.compressToUTF16(a.target.result)),t.settings.sPackOn&&(t.queue.rename=!0,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload())},r.onerror=function(e){console.error("error reading file")}}},clearStringFile(){e.getItem("string_pack")&&(t.settings.sPackMsg=F("string_pack_none"),e.removeItem("string_pack_name"),e.removeItem("string_pack"),t.settings.sPackOn&&(t.queue.rename=!0,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload()))},stringPackOn(){e.getItem("string_pack")&&(t.queue.rename=!0,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload())},restoreGame(){let t=e.getItem("evolveBak")||!1;this.$buefy.dialog.confirm({title:F("restore"),message:F("restore_warning"),ariaModal:!0,confirmText:F("restore"),onConfirm(){t&&importGame(t,!0)}})},lChange(a){t.settings.locale=a,t.queue.rename=!0,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload()},setTheme(e){t.settings.theme=e,$("html").removeClass(),$("html").addClass(e),$("html").addClass(t.settings.font)},numNotation(e){t.settings.affix=e},icon(a){t.settings.icon=a,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),M.w&&M.w.terminate(),window.location.reload()},remove(e){t.r_queue.queue.splice(e,1)},font(e){t.settings.font=e,$("html").removeClass("standard"),$("html").removeClass("large_log"),$("html").removeClass("large_all"),$("html").addClass(e)},q_merge(e){t.settings.q_merge=e},toggleTabLoad(){Ot()},unpause(){$("#pausegame").removeClass("play"),$("#pausegame").removeClass("pause"),t.settings.pause?$("#pausegame").addClass("pause"):$("#pausegame").addClass("play"),t.settings.pause||M.s||Ii("start")}},filters:{namecase:e=>e.replace(/(?:^|\s)\w/g,(function(e){return e.toUpperCase()})),label:e=>Pt(e),sPack:()=>t.settings.sPackMsg,notation(e){switch(e){case"si":return F("metric");case"sci":return F("scientific");case"sln":return F("sln")}}}}),["1","3","4","5","6","7","8","9","10","11","12","13","14","15","16"].forEach((function(e){Ti(`settings${e}`,(function(){return F(`settings${e}`)}),{elm:`#settings span.settings${e}`})})),Ti("stringPack",(function(){return F("string_example",['
              {\n "year": "Galactic Standard Year",\n "resource_Food_name": "Nom Noms"\n}
              '])})),t.new&&(Di(F("new"),"warning",!1,["progress"]),t.new=!1),t.city.mass_driver&&(i.mass_driver=t.city.mass_driver.on),t.portal.turret&&(i.turret=t.portal.turret.on),t.interstellar.fusion&&(o.fusion=t.interstellar.fusion.on),t.portal.hell_forge&&(i.hell_forge=t.portal.hell_forge.on),t.space.sam&&(i.sam=t.space.sam.on),t.space.operating_base&&(i.operating_base=t.space.operating_base.on,c.operating_base=t.space.operating_base.on),t.space.fob&&(i.fob=t.space.fob.on),t.tauceti.fusion_generator&&(i.fusion_generator=t.tauceti.fusion_generator.on),oa(!0),rr(),Ot(),Ui(),t.race.shapeshifter&&qi(!1,!0),Object.keys(ai()).forEach((function(e){Li(e)})),w(),sc({el:"#race",data:{race:t.race,city:t.city},methods:{name:()=>Ac("name")},filters:{replicate:e=>t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks")&&t.race.hasOwnProperty("replicator")&&Object.values(t.race.governor.tasks).includes("replicate")&&t.race.governor.config.replicate.pow.on&&t.race.replicator.pow>0?e+t.race.replicator.pow:e,approx:e=>+e.toFixed(2),mRound:e=>+e.toFixed(1)}}),Ti("race",(function(){return"string"==typeof di[t.race.species].desc?di[t.race.species].desc:di[t.race.species].desc()}),{elm:"#race > .name"});var wo=125;if(Ti("morale",(function(e){if(0!==t.city.morale.unemployed){let a=t.city.morale.unemployed>0?"success":"danger";e.popper.append(``)}if(0!==t.city.morale.stress){let a=t.city.morale.stress>0?"success":"danger";e.popper.append(``)}let a=100+t.city.morale.unemployed+t.city.morale.stress;if(Object.keys(t.city.morale).forEach((function(r){if(!["current","unemployed","stress","season","cap","potential"].includes(r)&&0!==t.city.morale[r]){a+=t.city.morale[r];let s=t.city.morale[r]>0?"success":"danger",i=t.city.morale[r];if("entertain"===r&&"democracy"===t.civic.govern.type&&(i/=1+ae.democracy()[0]/100),e.popper.append(``),"entertain"===r&&"democracy"===t.civic.govern.type){let t=ae.democracy()[0];e.popper.append(``)}}})),0!==t.city.morale.season){a+=t.city.morale.season;let r=0===t.city.calendar.season?F("morale_spring"):1===t.city.calendar.season?F("morale_summer"):F("morale_winter"),s=t.city.morale.season>0?"success":"danger";e.popper.append(``)}if("corpocracy"===t.civic.govern.type){let t=ae.corpocracy()[3];a-=t,e.popper.append(``)}if("republic"===t.civic.govern.type){let t=ae.republic()[1];a+=t,e.popper.append(``)}if("federation"===t.civic.govern.type){let t=ae.federation()[1];a+=t,e.popper.append(``)}let r=N("militant",1);if(r&&(a-=r,e.popper.append(``)),t.race.cheese){let r=t.stats.hasOwnProperty("reset")?t.stats.reset+1:1,s=+(r/(r+10)*11).toFixed(2);a+=s,e.popper.append(``)}if(t.race.motivated){let r=Math.ceil(t.race.motivated**.4);a+=r,e.popper.append(``)}if(t.civic.homeless){let r=t.civic.homeless/2;a-=r,e.popper.append(``)}if(t.tech.vax_c||t.tech.vax_f){let r=t.tech.vax_c?10:50;a-=r,e.popper.append(``)}else if(t.tech.vax_s){let t=20;a+=t,e.popper.append(``)}t.city.tormented&&(a-=t.city.tormented,e.popper.append(``)),a=+a.toFixed(1);let s=$("
              ");e.popper.append(s),s.append(``),s.append(``),s.append(``)}),{classes:"has-background-light has-text-dark"}),Ti("powerStatus",(function(e){let a=+(t.city.power_total-t.city.power).toFixed(2);Object.keys(s).forEach((function(t){if(s[t]){let a=+s[t].toFixed(2);e.popper.append(``)}})),e.popper.append(``);let r=+t.city.power.toFixed(2);t.city.power>0?e.popper.append(``):e.popper.append(``)}),{classes:"has-background-light has-text-dark"}),t.settings.pause?$("#pausegame").addClass("pause"):$("#pausegame").addClass("play"),sc({el:"#topBar",data:{city:t.city,race:t.race,s:t.settings},methods:{sign:()=>R("sign"),getAstroSign:()=>R("astrology"),weather:()=>R("weather"),temp:()=>R("temp"),moon:()=>R("moon"),showUniverse:()=>"standard"!==t.race.universe&&"bigbang"!==t.race.universe,showSim:()=>!!t.sim,atRemain:()=>F("accelerated_time"),pause(){$("#pausegame").removeClass("play"),$("#pausegame").removeClass("pause"),t.settings.pause?(t.settings.pause=!1,$("#pausegame").addClass("play")):(t.settings.pause=!0,$("#pausegame").addClass("pause")),t.settings.pause||M.s||Ii("start")},pausedesc:()=>t.settings.pause?F("game_play"):F("game_pause")},filters:{planet:e=>di[e].home,universe:e=>"standard"===e||"bigbang"===e?"":ta[e].name,remain(e){const a=ic(e/1e3);return`${t.settings.atMultiplier}x Speed [${a}]`}}}),["astroSign"].forEach((function(e){Ti(`${e}`,(function(){return R("sign")}),{elm:$(`#${e}`)})})),Ti("topBarPlanet",(function(e){if("protoplasm"===t.race.species)e.popper.append($(`${F("infant")}`));else{let a=di[t.race.species].home,r=Ac("name"),s=ji[t.city.biome].label,i=t.city.ptrait;if(i.length>0){let e="";i.forEach((function(a){Si.hasOwnProperty(a)&&("mellow"===a&&"entish"===t.race.species?e+=`${F("planet_mellow_eg")} `:e+=`${Si[a].label} `)})),s=`${e}${s}`}let c=t.city.calendar.orbit,o=ks(t.city.geology),n="";if(t.race.truepath&&(n+=`
              ${F("evo_challenge_truepath_recap")}
              `),t.race.junker&&(n+=`
              ${F("evo_challenge_junker_desc")} ${F("evo_challenge_junker_conditions")}
              `),t.race.joyless&&(n+=`
              ${F("evo_challenge_joyless_desc")} ${F("evo_challenge_joyless_conditions")}
              `),t.race.steelen&&(n+=`
              ${F("evo_challenge_steelen_desc")} ${F("evo_challenge_steelen_conditions")}
              `),t.race.decay&&(n+=`
              ${F("evo_challenge_decay_desc")} ${F("evo_challenge_decay_conditions")}
              `),t.race.emfield&&(n+=`
              ${F("evo_challenge_emfield_desc")} ${F("evo_challenge_emfield_conditions")}
              `),t.race.inflation&&(n+=`
              ${F("evo_challenge_inflation_desc")} ${F("evo_challenge_inflation_conditions")}
              `),t.race.banana&&(n+=`
              ${F("evo_challenge_banana_desc")} ${F("wiki_achieve_banana1")}. ${F("wiki_achieve_banana2")}. ${F("wiki_achieve_banana3")}. ${F("wiki_achieve_banana4",[500])}. ${F("wiki_achieve_banana5",[50])}.
              `),t.race.witch_hunter&&(n+=`
              ${F("evo_challenge_witch_hunter_desc")}
              `),t.race.nonstandard&&(n+=`
              ${F("evo_challenge_nonstandard_desc")}
              `),t.race.gravity_well&&(n+=`
              ${F("evo_challenge_gravity_well_desc")}
              `),t.race.warlord&&(n+=`
              ${F("evo_challenge_warlord_desc")}
              `),t.race.lone_survivor&&(n+=`
              ${F("evo_challenge_lone_survivor_desc")}
              `),t.race.sludge&&(n+=`
              ${F("evo_challenge_sludge_desc")} ${F("evo_challenge_sludge_conditions")}
              `),t.race.orbit_decay){let e=t.race.orbit_decayed?"":F("evo_challenge_orbit_decay_impact",[t.race.orbit_decay-t.stats.days]);n+=`
              ${t.race.orbit_decayed?F("evo_challenge_orbit_decay_impacted",[di[t.race.species].home]):F("evo_challenge_orbit_decay_desc")} ${F("evo_challenge_orbit_decay_conditions")} ${e}
              `,lc()>=100&&"antimatter"!==t.race.universe?n+=`
              ${F("evo_challenge_cataclysm_warn")}
              `:n+=`
              ${F("evo_challenge_scenario_warn")}
              `}t.race.cataclysm&&(lc()>=50&&"antimatter"!==t.race.universe?n+=`
              ${F("evo_challenge_cataclysm_desc")}
              ${F("evo_challenge_cataclysm_warn")}
              `:n+=`
              ${F("evo_challenge_cataclysm_desc")}
              ${F("evo_challenge_scenario_warn")}
              `),e.popper.append($(`
              ${F(t.race.cataclysm?"no_home":"home",[a,r,s,c])}
              ${o}${n}`))}}),{elm:"#topBar .planetWrap .planet",classes:"has-background-light has-text-dark"}),Ti("topBarUniverse",(function(e){e.popper.append($(`
              ${ta[t.race.universe].desc}
              `)),e.popper.append($(`
              ${ta[t.race.universe].effect}
              `))}),{elm:"#topBar .planetWrap .universe",classes:"has-background-light has-text-dark"}),Ti("topBarSimulation",(function(e){e.popper.append($(`
              ${F("evo_challenge_simulation_topbar")}
              `))}),{elm:"#topBar .planetWrap .simulation",classes:"has-background-light has-text-dark"}),t.race.orbit_decay&&!t.race.orbit_decayed&&Ti("infoTimer",(function(){return t.race.orbit_decayed?"":F("evo_challenge_orbit_decay_impact",[t.race.orbit_decay-t.stats.days])}),{elm:"#infoTimer",classes:"has-background-light has-text-dark"}),ao(),"protoplasm"===t.race.species){t.resource.RNA.display=!0;let e=t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0?Math.min(t.stats.achieve.ascended.l,t.stats.feat.master):0;if(t.sim&&(e=5),e>0&&!t.evolution.mloaded){let a=["dna","membrane","organelles","nucleus","eukaryotic_cell","mitochondria"];for(let e=0;e0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):0;t.sim&&(a=5),a>=5&&!t.evolution.gmloaded&&(t.tech.evo=6,t.evolution.gselect=!0,t.evolution.gmloaded=1,t.evolution.final=80,t.tech.evo_humanoid=1,t.tech.evo_giant=1,t.tech.evo_small=1,t.tech.evo_animalism=2,t.tech.evo_demonic=1,t.tech.evo_angelic=1,t.tech.evo_insectoid=1,t.tech.evo_eggshell=2,t.tech.evo_eldritch=1,t.tech.evo_sand=1,t.tech.evo_polar=1,t.tech.evo_heat=1,t.tech.evo_fey=1,t.tech.evo_aquatic=1),"bigbang"===t.race.universe?(t.seed=t.race.seed,function(){let e=["standard","heavy","antimatter","evil","micro","magic"];for(let a=0;a`),c=$(`${ta[r].name}`);i.append(c),$("#evolution").append(i),$("#"+s).on("click",(function(){t.race.universe=r,rc($("#evolution")),aa(),Ei()})),Ti(s,(function(e){e.popper.append($(`
              ${ta[r].name}
              `)),e.popper.append($(`
              ${ta[r].desc}
              `)),e.popper.append($(`
              ${ta[r].effect}
              `))}),{classes:"has-background-light has-text-dark"})}}()):t.race.seeded&&!t.race.chose?(t.seed=t.race.seed,aa()):ts()}else t.portal.hasOwnProperty("soul_forge")&&t.portal.soul_forge.on&&(i.soul_forge=1),G();Po(!0),$("#lbl_city").html("Village"),window.Worker&&(M.w=new Worker("evolve/evolve.js"),M.w.addEventListener("message",(function(a){switch(a.data){case"fast":!function(){t.race.no_craft||$(".craft").each((function(e){"number"==typeof $(this).data("val")&&$(this).html(k($(this).data("val")*y(),1))}));const e=new Date,a=U();r.p.Global={};var d=1;let _=!1,p=Br("raw");if(t.prestige.Plasmid.count>0&&("antimatter"!==t.race.universe||t.genes.bleed&&"antimatter"===t.race.universe)&&(r.p.Global[F("resource_Plasmid_name")]=100*p[1]+"%",_=!0),t.prestige.AntiPlasmid.count>0&&("antimatter"===t.race.universe||t.genes.bleed&&t.genes.bleed>=2&&"antimatter"!==t.race.universe)&&(r.p.Global[F("resource_AntiPlasmid_name")]=100*p[2]+"%",_=!0),_&&(d+=p[0]),(t.race.no_plasmid||"antimatter"===t.race.universe)&&((t.race.cataclysm||t.race.orbit_decayed)&&t.space.ziggurat&&t.space.ziggurat.count||t.city.temple&&t.city.temple.count)){let e=Dr();r.p.Global[F("faith")]=100*e+"%",d*=1+e}if(t.race.untapped&&t.race.untapped>0){let e=+(t.race.untapped/(t.race.untapped+20)/10+24e-5).toFixed(4);r.p.Global[F("trait_untapped_bd")]=100*e+"%",d*=1+e}if(t.race.rainbow_active&&t.race.rainbow_active>1&&(r.p.Global[F("trait_rainbow_bd")]=`${ui.rainbow.vars()[0]}%`,d*=1+ui.rainbow.vars()[0]/100),t.tech.world_control){let e=25;"federation"===t.civic.govern.type&&(e=ae.federation()[2]),t.race.unified&&(e+=ui.unified.vars()[0]),"taurus"===a&&(e+=H("taurus")[0]),r.p.Global[F("tech_unification")]=`${e}%`,d*=1+e/100}else{let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].anx||t.civic.foreign[`gov${a}`].buy)&&(e+="federation"===t.civic.govern.type?5+ae.federation()[0]:5);e>0&&(r.p.Global[F("civics_garrison_occupy")]=`${e}%`,d*=1+e/100)}if(t.genes.challenge&&t.genes.challenge>=2){let e=lc();r.p.Global[F("mastery")]=e+"%",d*=1+e/100}if(t.pillars){let e=_c();r.p.Global[F("harmonic")]=100*(e[0]-1)+"%",d*=e[0]}if(t.race.ascended&&(r.p.Global[F("achieve_ascended_name")]="5%",d*=1.05),t.race.corruption){let e=2*t.race.corruption;r.p.Global[F("achieve_corrupted_name")]=`${e}%`,d*=1+e/100}if(t.race.rejuvenated){let e=t.stats.days<996?(1e3-t.stats.days)/2e3:.02;r.p.Global[F("rejuvenated")]=100*e+"%",d*=1+e}let h=Pi("octigoran");if(t.race.suction_grip||h>0){let e=0;t.race.suction_grip&&(e+=ui.suction_grip.vars()[0]),h>0&&(e+=+(ui.suction_grip.vars(1)[0]*h).toFixed(2)),r.p.Global[F("trait_suction_grip_bd")]=e+"%",d*=1+e/100}let m=Pi("cyclops");if(t.race.intelligent||m>0){let e=0;t.race.intelligent&&(e+=na(t.civic.scientist.workers,"scientist")*ui.intelligent.vars()[1]+na(t.civic.professor.workers,"professor")*ui.intelligent.vars()[0]),m>0&&(e+=na(t.civic.scientist.workers,"scientist")*ui.intelligent.vars(1)[1]*m+na(t.civic.professor.workers,"professor")*ui.intelligent.vars(1)[0]*m),t.race.high_pop&&(e=Me(e)),r.p.Global[F("trait_intelligent_bd")]=e+"%",d*=1+e/100}if(t.race.slaver&&t.city.slave_pen&&t.city.slave_pen){let e=t.city.slave_pen.slaves*ui.slaver.vars()[0];r.p.Global[F("trait_slaver_bd")]=e+"%",d*=1+e/100}if((t.city.ptrait.includes("trashed")||t.race.scavenger||t.race.servants&&t.race.servants.force_scavenger)&&t.civic.scavenger){let e=t.city.ptrait.includes("trashed")||t.race.scavenger?na(t.civic.scavenger.workers,"scavenger"):0;if(t.race.servants&&(e+=la(t.race.servants.jobs.scavenger)),e>0){let a=e*ui.scavenger.vars()[0];t.city.ptrait.includes("trashed")&&t.race.scavenger&&(a*=1+ui.scavenger.vars()[1]/100),t.city.ptrait.includes("trashed")&&(a*=Si.trashed.vars()[1]),t.race.high_pop&&(a=Me(a)),r.p.Global[F("job_scavenger")]=a+"%",d*=1+a/100}}if(t.race.unfathomable&&t.city.surfaceDwellers&&t.city.captive_housing){let e=0,a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;if(t.city.hasOwnProperty("surfaceDwellers")){for(let a=0;at.civic.torturer.workers*a/2){let r=e-t.civic.torturer.workers*a/2;e-=Math.ceil(r/3)}}if(e>0){let s=e*ui.unfathomable.vars()[2]*a/5;t.race.psychic&&(s*=1+ui.psychic.vars()[1]/100),r.p.Global[F("trait_unfathomable_bd")]=s+"%",d*=1+s/100}}if(t.city.ptrait.includes("mellow")&&(r.p.Global[F("planet_mellow_bd")]="-10%",d*=Si.mellow.vars()[2]),t.city.ptrait.includes("ozone")&&t.city.sun){let e=t.city.sun*Si.ozone.vars()[0];r.p.Global[F("planet_ozone_bd")]=`-${e}%`,d*=1-e/100}let g=Pi("phoenix");if((t.race.smoldering||g>0)&&t.city.hot){let e=0;t.race.smoldering&&(t.city.hot>100?(e+=100*ui.smoldering.vars()[1],e+=(t.city.hot-100)*ui.smoldering.vars()[2]):e+=t.city.hot*ui.smoldering.vars()[1]),g>0&&(t.city.hot>100?(e+=100*ui.smoldering.vars(.25)[1]*g,e+=(t.city.hot-100)*ui.smoldering.vars(.25)[2]*g):e+=t.city.hot*ui.smoldering.vars(.25)[1]*g),r.p.Global[F("trait_smoldering_name")]=`${e}%`,d*=1+e/100}if(t.race.heat_intolerance&&t.city.hot){let e=t.city.hot*ui.heat_intolerance.vars()[0];r.p.Global[F("hot")]=`-${e}%`,d*=1-e/100}if(t.race.chilled&&t.city.cold){let e=0;t.city.cold>100?(e+=100*ui.chilled.vars()[1],e+=(t.city.cold-100)*ui.chilled.vars()[2]):e=t.city.cold*ui.chilled.vars()[1],r.p.Global[F("trait_chilled_name")]=`${e}%`,d*=1+e/100}if(t.race.cold_intolerance&&t.city.cold){let e=t.city.cold*ui.cold_intolerance.vars()[0];r.p.Global[F("cold")]=`-${e}%`,d*=1-e/100}if("anarchy"===t.civic.govern.type&&t.resource[t.race.species].amount>=la(10)){let e=(t.resource[t.race.species].amount-(la(10)-1))*(t.race.high_pop?.25/ui.high_pop.vars()[0]:.25);r.p.Global[F("govern_anarchy")]=`-${e}%`,d*=1-e/100}if(t.civic.govern.protest&&t.civic.govern.protest>0&&(r.p.Global[F("event_protest")]="-30%",d*=.7),t.civic.govern.scandal&&t.civic.govern.scandal>0){let e=N("muckraker",0);e&&(r.p.Global[F("event_scandal")]=`-${e}%`,d*=1-e/100)}if(Pi("capybara")>0||t.race.calm&&t.city.meditation&&t.resource.Zen.display){let e=t.resource.Zen.amount,a=Pi("capybara");a>0&&(e+=Math.round(500*a));let s=e/(e+5e3);r.p.Global[F("trait_calm_bd")]=`+${(100*s).toFixed(2)}%`,d*=1+s}if(t.city.firestorm&&t.city.firestorm>0&&(t.city.firestorm--,r.p.Global[F("event_flare_bd")]="-20%",d*=.8),"aquatic"===di[t.race.species].type&&!["swamp","oceanic"].includes(t.city.biome)||"fey"===di[t.race.species].type&&!["forest","swamp","taiga"].includes(t.city.biome)||"heat"===di[t.race.species].type&&!["ashland","volcanic"].includes(t.city.biome)||"polar"===di[t.race.species].type&&!["tundra","taiga"].includes(t.city.biome)||"sand"===di[t.race.species].type&&!["ashland","desert"].includes(t.city.biome)||"demonic"===di[t.race.species].type&&"hellscape"!==t.city.biome||"angelic"===di[t.race.species].type&&"eden"!==t.city.biome){let e=1;e=t.blood.unbound&&t.blood.unbound>=4?t.race.rejuvenated?.975:.95:t.blood.unbound&&t.blood.unbound>=2?t.race.rejuvenated?.95:.9:t.race.rejuvenated?.9:.8,r.p.Global[F("unsuited")]=`-${Math.round(100*(1-e))}%`,d*=e}if(t.race.hibernator&&3===t.city.calendar.season&&(d*=1-ui.hibernator.vars()[1]/100,r.p.Global[F("morale_winter")]=`-${ui.hibernator.vars()[1]}%`),"magic"===t.race.universe&&t.tech.syphon){let e=t.tech.syphon/8;r.p.Global[F("arpa_syphon_damage")]=`-${e}%`,d*=1-e/100}r.p.consume={},["Money","Knowledge","Food","Lumber","Stone","Chrysotile","Crystal","Furs","Copper","Iron","Cement","Coal","Oil","Uranium","Aluminium","Steel","Titanium","Alloy","Polymer","Iridium","Helium_3","Water","Deuterium","Neutronium","Adamantite","Infernite","Elerium","Nano_Tube","Graphene","Stanene","Bolognium","Vitreloy","Orichalcum","Unobtainium","Quantium","Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Aerogel","Nanoweave","Scarletite","Cipher","Nanite","Mana"].forEach((function(e){r.p.consume[e]={},r.p[e]={}}));var f=M.timers.main*t.settings.gameSpeed/1e3;if("protoplasm"===t.race.species){if(t.evolution.nucleus&&t.resource.DNA.amount0||t.evolution.poikilohydric&&t.evolution.poikilohydric.count>0||t.evolution.spores&&t.evolution.spores.count>0)&&(v*=2),Vi("DNA",v*d*f),Vi("RNA",-2*e*f)}if(t.evolution.organelles){let e=t.race.rapid_mutation?2:1;t.tech.evo&&t.tech.evo>=2&&e++,Vi("RNA",t.evolution.organelles.count*e*d*f)}if((t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0||t.sim)&&"bigbang"!==t.race.universe&&(!t.race.seeded||t.race.seeded&&t.race.chose)){let e=t.sim?5:Math.min(t.stats.achieve.apocalypse.l,t.stats.feat.novice);Vi("RNA",e/2*f*d),t.resource.DNA.display&&Vi("DNA",e/4*f*d)}t.resource.RNA.amount>=2&&!t.evolution.dna?(t.evolution.dna=1,t.resource.DNA.display=!0,t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1&&(Vi("RNA",t.resource.RNA.max),Vi("DNA",t.resource.RNA.max)),ts()):t.resource.RNA.amount>=10&&!t.evolution.membrane?(t.evolution.membrane={count:0},ts()):t.resource.DNA.amount>=4&&!t.evolution.organelles?(t.evolution.organelles={count:0},ts()):t.evolution.organelles&&t.evolution.organelles.count>=2&&!t.evolution.nucleus?(t.evolution.nucleus={count:0},ts()):t.evolution.nucleus&&t.evolution.nucleus.count>=1&&!t.evolution.eukaryotic_cell?(t.evolution.eukaryotic_cell={count:0},ts()):t.evolution.eukaryotic_cell&&t.evolution.eukaryotic_cell.count>=1&&!t.evolution.mitochondria?(t.evolution.mitochondria={count:0},ts()):t.evolution.mitochondria&&!t.tech.evo&&(t.tech.evo=1,ts())}else{let _=function(){let e=1;if(t.space.ziggurat&&t.space.ziggurat.count>0){let a=t.tech.ancient_study?.006:.004;if(t.tech.ancient_deify&&t.tech.ancient_deify>=2&&c.exotic_lab&&(a+=1e-4*c.exotic_lab),"theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=2e-5;t.race.high_pop&&(e=Me(e)),a+=e*t.civic.priest.workers}t.race.ooze&&(a*=1-ui.ooze.vars()[1]/100),t.race.high_pop&&(a=Me(a)),e+=t.space.ziggurat.count*t.civic.colonist.workers*a}return e}(),p=100,h=1,m=1;if(t.race.quarantine&&t.race.qDays){let e=1-(t.race.qDays<=1e3?t.race.qDays:1e3)/1e3;switch(t.race.quarantine){case 1:h=.5+.5*e;break;case 2:h=.25+.25*e,m=.5+.5*e;break;case 3:h=.1+.15*e,m=.25+.25*e;break;case 4:h=.08+.02*e,m=.12+.13*e}if(t.race.vax&&t.tech.focus_cure&&t.tech.focus_cure>=4){let e=+t.race.vax.toFixed(2)/100;e>1&&(e=1),h+=(1-h)*e,m+=(1-m)*e}}if(0===t.city.calendar.season&&t.city.calendar.year>0){let e=t.race.chilled||t.race.smoldering?0:5;p+=e,t.city.morale.season=e}else 1===t.city.calendar.season&&t.race.smoldering?(p+=ui.smoldering.vars()[0],t.city.morale.season=ui.smoldering.vars()[0]):3===t.city.calendar.season?t.race.chilled?(p+=ui.chilled.vars()[0],t.city.morale.season=ui.chilled.vars()[0]):(p-=t.race.leathery?ui.leathery.vars()[0]:5,t.city.morale.season=t.race.leathery?-ui.leathery.vars()[0]:-5):t.city.morale.season=0;if(t.race.cheese){let e=t.stats.hasOwnProperty("reset")?t.stats.reset+1:1;p+=+(e/(e+10)*11).toFixed(2)}if(t.civic.homeless&&(p-=t.civic.homeless/2),t.tech.vax_c||t.tech.vax_f?p-=t.tech.vax_c?10:50:t.tech.vax_s&&(p+=20),t.tech.m_boost?(t.city.morale.leadership=20,p+=20):t.city.morale.leadership=0,Kc()){let e=Lc("morale");t.city.morale.shrine=e.add,p+=e.add}else t.city.morale.shrine=0;let g=N("militant",1);if(g&&(p-=g),"corpocracy"===t.civic.govern.type&&(p-=ae.corpocracy()[3]),"republic"===t.civic.govern.type&&(p+=ae.republic()[1]),"federation"===t.civic.govern.type&&(p+=ae.federation()[1]),t.race.blood_thirst&&t.race.blood_thirst_count>=1){let e=Math.ceil(Math.log2(t.race.blood_thirst_count));t.city.morale.blood_thirst=e,p+=e}else t.city.morale.blood_thirst=0;let v=0;0===t.city.calendar.weather?t.city.calendar.temp>0&&(v=1===t.city.calendar.wind?t.race.skittish?-ui.skittish.vars()[0]:t.race.leathery?-ui.leathery.vars()[0]:-5:t.race.leathery?0:-2):2===t.city.calendar.weather?t.race.nyctophilia?v=-ui.nyctophilia.vars()[0]:(0===t.city.calendar.wind&&t.city.calendar.temp<2||1===t.city.calendar.wind&&2===t.city.calendar.temp)&&(v=2):t.race.nyctophilia&&(v=ui.nyctophilia.vars()[1]),!t.race.snowy||0===t.city.calendar.temp&&0===t.city.calendar.weather||(v-=t.city.calendar.temp>=2?ui.snowy.vars()[1]:ui.snowy.vars()[0]),t.city.morale.weather=t.race.submerged?0:v,p+=t.race.submerged?0:v,t.race.motivated&&(p+=Math.ceil(t.race.motivated**.4));let y=0,k=5;t.city.morale.unemployed=0,t.city.ptrait.includes("mellow")?k*=Si.mellow.vars()[0]:(p-=t.civic.unemployed.workers,t.city.morale.unemployed=-t.civic.unemployed.workers);let M=Pi("vulpine");if(t.civic.hunter.display&&(t.race.playful||M>0)){let e=0;M>0&&(e+=ui.playful.vars(1)[0]*M),t.race.playful&&(e+=ui.playful.vars()[0]),p+=t.civic.hunter.workers*e,t.city.morale.unemployed=t.civic.hunter.workers*e}else y-=t.civic.hunter.workers/k;t.race.optimistic&&(y+=ui.optimistic.vars()[0]);let P=Pi("gecko");if(P>0&&(y+=ui.optimistic.vars(1)[0]*P),t.race.pessimistic&&(y-=ui.pessimistic.vars()[0]),t.civic.garrison){let e=2;t.city.ptrait.includes("mellow")&&(e*=Si.mellow.vars()[0]);let a=t.civic.garrison.max/e;t.race.high_pop&&(a/=ui.high_pop.vars()[0]),y-=a}if(r.p.consume.Money[F("trade")]=0,t.tech.trade||t.race.banana&&t.tech.primitive&&t.tech.primitive>=3){let e=0,s=N("dealmaker",0);Object.keys(t.resource).forEach((function(i){if(t.resource[i].trade>0){e+=t.resource[i].trade;let c=yr(i)*t.resource[i].trade;if(t.resource.Money.amount>=c*f){let e=Za[i];s&&(e*=1+s/100),t.race.persuasive&&(e*=1+ui.persuasive.vars()[0]*t.race.persuasive/100),t.race.merchant&&(e*=1+ui.merchant.vars()[1]/100);let o=Pi("goblin");if(o>0&&(e*=1+ui.merchant.vars(1)[1]/100*o),"capricorn"===a&&(e*=1+H("capricorn")[0]/100),t.genes.trader&&(e*=1+lc()/100),t.stats.achieve.hasOwnProperty("trade")){let a=2*t.stats.achieve.trade.l;a>10&&(a=10),e*=1+a/100}t.race.truepath&&(e*=1-t.civic.foreign.gov3.hstl/101),Vi(i,t.resource[i].trade*f*e),Vi("Money",-c*f),r.p.consume.Money[F("trade")]-=c,r.p.consume[i][F("trade")]=t.resource[i].trade*e}Oo()}else if(t.resource[i].trade<0){e-=t.resource[i].trade;let a=vr(i)*t.resource[i].trade,s=Za[i];if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),s*=1-e/100}t.resource[i].amount>=s*f&&(Vi(i,t.resource[i].trade*f*s),Vi("Money",-a*f),r.p.consume.Money[F("trade")]-=a,r.p.consume[i][F("trade")]=t.resource[i].trade*s),Oo()}})),t.city.market.trade=e}if(0===r.p.consume.Money[F("trade")]&&delete r.p.consume.Money[F("trade")],t.tech.alchemy){let e=0,a=0,s=0;Object.keys(t.race.alchemy).forEach((function(i){if(t.race.alchemy[i]>0){let c=Number(t.race.alchemy[i]);if(t.resource.Mana.amount=f){let s=t.resource[i].basic&&t.tech.alchemy>=2?8*Za[i]:2*Za[i];t.race.witch_hunter&&(s*=3),t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg&&(s*=t.stats.achieve.soul_sponge.mg+1),Vi(i,c*f*s),Vi("Mana",-c*f),Vi("Crystal",-.15*c*f),e-=c,a-=.15*c,r.p.consume[i][F("tab_alchemy")]=c*s,"magic"===t.race.universe&&!t.resource[i].basic&&t.tech.alchemy>=2&&Xc("fullmetal")}}})),t.race.totTransmute=s,r.p.consume.Mana[F("tab_alchemy")]=e,r.p.consume.Crystal[F("tab_alchemy")]=a}if(t.galaxy.trade&&(n.hasOwnProperty("freighter")||n.hasOwnProperty("super_freighter"))){let e=0;t.galaxy.freighter&&(e+=2*n.freighter),t.galaxy.super_freighter&&(e+=5*n.super_freighter),t.galaxy.trade.max=e;let s=0,i=dr();for(let c=0;c0&&(u*=1+ui.merchant.vars(1)[1]/100*p),"capricorn"===a&&(u*=1+H("capricorn")[0]/100),t.genes.trader&&(u*=1+lc()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),u*=1+e/50,n*=1-e/100}s+=t.galaxy.trade[`f${c}`],s>e&&(t.galaxy.trade[`f${c}`]-=s-e,t.galaxy.trade[`f${c}`]<0&&(t.galaxy.trade[`f${c}`]=0));let h=Et("gxy_gorddon");for(let e=0;e0&&(r.p.consume[o][F("trade")]?r.p.consume[o][F("trade")]-=d:r.p.consume[o][F("trade")]=-d),_>0&&(r.p.consume[l][F("trade")]?r.p.consume[l][F("trade")]+=_:r.p.consume[l][F("trade")]=_),h<1&&(r.p.consume[l][F("galaxy_piracy")]?r.p.consume[l][F("galaxy_piracy")]+=-(1-h)*_:r.p.consume[l][F("galaxy_piracy")]=-(1-h)*_),0===r.p.consume[o][F("trade")]&&delete r.p.consume[o][F("trade")],0===r.p.consume[l][F("trade")]&&delete r.p.consume[l][F("trade")]}t.galaxy.trade.cur=s}t.race.deconstructor&&t.city.nanite_factory&&Vs.forEach((function(e){if(t.resource[e].display){let a=t.city.nanite_factory[e]*f;if(a>0&&(t.resource[e].amount=1e3){let e=t.race.lone_survivor?100:1e4;C-=e,O+=e,s[F("tau_star_ringworld")]=e}if(t.interstellar.orichalcum_sphere&&t.interstellar.orichalcum_sphere.count>0){let e=0;e=t.interstellar.orichalcum_sphere.count>=100?cc(1750):cc(750+8*t.interstellar.orichalcum_sphere.count),C-=e,O+=e,s[F("interstellar_dyson_sphere_title")]=e,delete s[F("tech_dyson_net")]}else if(t.interstellar.dyson_sphere&&t.interstellar.dyson_sphere.count>0){let e=0;e=t.interstellar.dyson_sphere.count>=100?cc(750):cc(175+5*t.interstellar.dyson_sphere.count),C-=e,O+=e,s[F("interstellar_dyson_sphere_title")]=e,delete s[F("tech_dyson_net")]}else if(t.interstellar.dyson&&t.interstellar.dyson.count>=1){let e=0;e=t.interstellar.dyson.count>=100?cc(175):cc(1.25*t.interstellar.dyson.count),C-=e,O+=e,s[F("tech_dyson_net")]=e}if(t.interstellar.stellar_engine&&t.interstellar.stellar_engine.count>=100){let e=t.tech.gravity&&t.tech.gravity>=2?13.5:7.5,a=t.interstellar.stellar_engine.mass;t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12));let r=cc(20+(a-8)*e+t.interstellar.stellar_engine.exotic*e*10);C-=r,O+=r,s[F("tech_stellar_engine")]=r}if([{r:"city",s:"coal_power"},{r:"city",s:"oil_power"},{r:"city",s:"fission_power"},{r:"spc_hell",s:"geothermal"},{r:"spc_dwarf",s:"e_reactor"},{r:"int_alpha",s:"fusion"},{r:"tau_home",s:"fusion_generator"},{r:"tau_gas2",s:"alien_space_station"}].forEach((function(e){let a=Tt(e.r),c="city"===e.r?e.r:a,o="city"===e.r?Qr.city:Qr[a][e.r],n="string"==typeof o[e.s].title?o[e.s].title:o[e.s].title();if(t[c][e.s]&&t[c][e.s].on){let a=o[e.s].powered();if(i[e.s]=t[c][e.s].on,o[e.s].hasOwnProperty("p_fuel")){let t=o[e.s].p_fuel();Array.isArray(t)||(t=[t]);for(let a=0;a=3&&i.coal_power){let e=.35*i.coal_power*Pe("psychic_boost","Uranium");r.p.Uranium[F("city_coal_ash")]=e/65/d,Vi("Uranium",e*f/65)}if(t.space.hydrogen_plant){let e=Qr.space.spc_titan.hydrogen_plant.powered();t.space.hydrogen_plant.on>t.space.electrolysis.on&&(t.space.hydrogen_plant.on=t.space.electrolysis.on);let a=t.space.hydrogen_plant.on*e;C+=a,O-=a,s[F("space_hydrogen_plant_title")]=-a}if(t.portal.inferno_power){let e=Qr.portal.prtl_ruins.inferno_power.fuel,a=t.portal.inferno_power.on;Object.keys(e).forEach((function(s){let i=a*e[s];for(;i*f>t.resource[s].amount+(t.resource[s].diff>0?t.resource[s].diff*f:0)&&i>0;)a--,i-=e[s];r.p.consume[s][F("portal_inferno_power_title")]=-i,Vi(s,-i*f)}));let i=a*Qr.portal.prtl_ruins.inferno_power.powered();C+=i,O-=i,s[F("portal_inferno_power_title")]=-i}if(t.space.swarm_satellite&&t.space.swarm_control){let e=t.space.swarm_satellite.count;e>t.space.swarm_control.s_max&&(e=t.space.swarm_control.s_max),t.space.swarm_control.support=e;let a=.35;t.tech.swarm>=4&&(a+=.15*(t.tech.swarm-3)),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1&&(a+=.15),t.blood.illuminate&&(a+=.01*t.blood.illuminate),a=+a.toFixed(2);let r=cc(e*a);C-=r,O+=r,s[F("space_sun_swarm_satellite_title")]=r}if(t.city.mill&&t.tech.agriculture&&t.tech.agriculture>=6){let e=cc(t.city.mill.on*Qr.city.mill.powered());C+=e,O-=e,s[F("city_mill_title2")]=-e}if(t.city.windmill&&t.tech.wind_plant){let e=cc(t.city.windmill.count*Qr.city.windmill.powered());C+=e,O-=e,s[F("city_mill_title2")]=-e}if(t.race.powered){let e=ui.powered.vars()[0]*t.resource[t.race.species].amount;t.race.discharge&&t.race.discharge>0&&(e=+(1.25*e).toFixed(3)),O-=e}t.race.replicator&&(t.city.replicator={count:t.race.replicator.pow,on:t.race.replicator.pow});let j=t.power;if(t.settings.lowPowerBalance){let e=0;for(let a=0;a=0;b--){let e=j[b].split(":"),c=Tt(e[0]),o="city"===e[0]?e[0]:c,n="city"===e[0]?Qr.city:Qr[c][e[0]];if(t[o][e[1]]&&t[o][e[1]].on&&(i[e[1]]=t[o][e[1]].on,n[e[1]].hasOwnProperty("p_fuel"))){let t=n[e[1]].p_fuel();Array.isArray(t)||(t=[t]);for(let s=0;sO&&i[r[1]]>0){let e="city"===r[0]?"city":Tt(r[0]),s="city"===r[0]?Qr.city:Qr[e][r[0]],c=s[r[1]].powerBalancer();if(c){let o=i[r[1]];c.forEach((function(i){let c=0;if(i.hasOwnProperty("r")&&i.hasOwnProperty("k")){let n=t[e][r[1]][i.k]?t[e][r[1]][i.k]:0;t.resource[i.r].odif&&t.resource[i.r].odif<0&&(t.resource[i.r].odif=0);let l=t.resource[i.r].diff+(t.resource[i.r].odif?t.resource[i.r].odif:0);for(;l-c*n>n&&o>0&&a>O;)o--,c++,a-=s[r[1]].powered();t.resource[i.r].odif=n*c}else if(i.hasOwnProperty("s")){let n=s[r[1]].support();t[e][r[1]].soff&&t[e][r[1]].soff<0&&(t[e][r[1]].soff=0);let l=i.s+(t[e][r[1]].soff?t[e][r[1]].soff:0);for(;l-n*c>=n&&o>0&&a>O;)o--,c++,a-=s[r[1]].powered();t[e][r[1]].soff=n*c}})),i[r[1]]=o}}}for(b=j.length-1;b>=0;b--){let e=j[b].split(":"),r=Tt(e[0]),s="city"===e[0]?e[0]:r,c="city"===e[0]?Qr.city:Qr[r][e[0]];if(t[s][e[1]]&&t[s][e[1]].on){let r=c[e[1]].powered();for(;a>O&&i[e[1]]>0;)a-=r,i[e[1]]--;i[e[1]]!==t[s][e[1]].on?($(`#${s}-${e[1]} .on`).addClass("warn"),$(`#${s}-${e[1]} .on`).prop("title",`ON ${i[e[1]]}/${t[s][e[1]].on}`)):($(`#${s}-${e[1]} .on`).removeClass("warn"),$(`#${s}-${e[1]} .on`).prop("title","ON"))}else i[e[1]]=0,$(`#${s}-${e[1]} .on`).removeClass("warn"),$(`#${s}-${e[1]} .on`).prop("title","ON")}O-=e}else for(b=0;bO&&o>0;)o-=c[e[1]].powered(),i[e[1]]--;if(O-=t[s][e[1]].on*a,c[e[1]].hasOwnProperty("p_fuel")){let t=c[e[1]].p_fuel();Array.isArray(t)||(t=[t]);for(let a=0;at.resource.Elerium.amount&&a>0;)a-=e,i.foothold--;r.p.consume.Elerium[F("galaxy_foothold")]=-a,Vi("Elerium",-a*f)}[{a:"space",r:"spc_moon",s:"moon_base",g:"moon"},{a:"space",r:"spc_red",s:"spaceport",g:"red"},{a:"space",r:"spc_titan",s:"electrolysis",g:"titan"},{a:"space",r:"spc_titan",r2:"spc_enceladus",s:"titan_spaceport",g:"enceladus"},{a:"space",r:"spc_eris",s:"drone_control",g:"eris"},{a:"tauceti",r:"tau_home",s:"orbital_station",g:"tau_home"},{a:"tauceti",r:"tau_red",s:"orbital_platform",g:"tau_red"},{a:"tauceti",r:"tau_roid",s:"patrol_ship",g:"tau_roid",oc:!0}].forEach((function(e){if(e.r2=e.r2||e.r,t[e.a][e.s]&&t[e.a][e.s].count>0){if(j.includes(`${e.r}:${e.s}`)||(i[e.s]=t[e.a][e.s].on),Qr[e.a][e.r][e.s].hasOwnProperty("support_fuel")){let a=Qr[e.a][e.r][e.s].support_fuel();Array.isArray(a)||(a=[a]);for(let s=0;s=2?i.nav_beacon*Qr.space.spc_home.nav_beacon.support():0;break;case"red":t[e.a][e.s].s_max+=t.tech.mars&&t.tech.mars>=3?i.red_tower*Qr.space.spc_red.red_tower.support():0,t[e.a][e.s].s_max+=t.tech.luna&&t.tech.luna>=3?i.nav_beacon*Qr.space.spc_home.nav_beacon.support():0;break;case"tau_home":t[e.a][e.s].s_max+=i.tau_farm?i.tau_farm:0}}if(t[e.a][e.s]&&"spc_eris"===e.r&&!i.ai_core2&&(t[e.a][e.s].s_max=0),t[e.a][e.s]){let s=0,i=t.support[e.g].map((e=>e.split(":")[1]));for(var a=0;at[e.a][e.s].s_max&&!e.oc?(l-=s+l-t[e.a][e.s].s_max,$(`#${o} .on`).addClass("warn"),$(`#${o} .on`).prop("title",`ON ${l}/${t[e.a][i[a]].on}`)):($(`#${o} .on`).removeClass("warn"),$(`#${o} .on`).prop("title","ON")),Qr[e.a][e.r2][i[a]].hasOwnProperty("support_fuel")){let t=Qr[e.a][e.r2][i[a]].support_fuel();Array.isArray(t)||(t=[t]);for(let s=0;s0){let e=i.red_factory*Jt(1,!0);Vi("Helium_3",-e*f),r.p.consume.Helium_3[F("space_red_factory_title")]=-e}if(i.int_factory&&i.int_factory>0){let e=i.int_factory*Yt(5);Vi("Deuterium",-e*f),r.p.consume.Deuterium[F("interstellar_int_factory_title")]=-e}if(c.water_freighter&&c.water_freighter>0){let e=Jt(5,!0),t=c.water_freighter*e;for(let a=0;a0){let e=+Yt(5),a=i.starport*e;r.p.consume.Helium_3[F("interstellar_alpha_starport_title")]=-a;for(let t=0;te.split(":")[1]));for(b=0;bt.interstellar.starport.s_max?(r-=e+r-t.interstellar.starport.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.interstellar[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r,o[a[b]]=r}else o[a[b]]=0;if(t.interstellar.starport.support=e,t.interstellar.hasOwnProperty("mining_droid")&&t.interstellar.mining_droid.count>0){let e=o.mining_droid,a=t.interstellar.mining_droid.on,r=a>0?e/a:0,s=a;["adam","uran","coal","alum"].forEach((function(e){s-=t.interstellar.mining_droid[e],s<0&&(t.interstellar.mining_droid[e]+=s,s=0),z[e]=t.interstellar.mining_droid[e]*r}))}}if(t.galaxy.starbase&&t.galaxy.starbase.count>0){let e=+Yt(25),a=i.starbase*e;r.p.consume.Helium_3[F("galaxy_starbase")]=-a;for(let t=0;te.split(":")[1]));for(b=0;bt.galaxy.starbase.s_max?(r-=e+r-t.galaxy.starbase.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.galaxy[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r*-Qr.galaxy.gxy_gateway[a[b]].support(),n[a[b]]=r}else n[a[b]]=0;t.galaxy.starbase.support=e}if(t.galaxy.foothold&&t.galaxy.foothold.count>0){t.galaxy.foothold.s_max=i.foothold*Qr.galaxy.gxy_alien2.foothold.support();let e=0,a=t.support.alien2.map((e=>e.split(":")[1]));for(b=0;bt.galaxy.foothold.s_max?(r-=e+r-t.galaxy.foothold.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.galaxy[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r*-Qr.galaxy.gxy_alien2[a[b]].support(),n[a[b]]=r}else n[a[b]]=0;t.galaxy.foothold.support=e}if(t.portal.guard_post){if(t.portal.guard_post.s_max=t.portal.guard_post.count*Qr.portal.prtl_ruins.guard_post.support(),t.portal.guard_post.on>0){let e=t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(i.soul_forge){let t=ba();t<=e&&(e-=t)}ee.split(":")[1]));for(b=0;bt.portal.harbour.s_max?(r-=e+r-t.portal.harbour.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.portal[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r*-Qr.portal.prtl_lake[a[b]].support(),n[a[b]]=r}else n[a[b]]=0;t.portal.harbour.support=e}if(t.portal.purifier){t.portal.purifier.s_max=i.purifier*Qr.portal.prtl_spire.purifier.support();let e=0,a=t.support.spire.map((e=>e.split(":")[1]));for(b=0;bt.portal.purifier.s_max?(r-=e+r-t.portal.purifier.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.portal[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r*-Qr.portal.prtl_spire[a[b]].support(),l[a[b]]=r}else l[a[b]]=0;t.portal.purifier.support=e}if(t.space.space_station&&t.space.space_station.count>0){let e=+Jt(2.5,!0),t=i.space_station*e;r.p.consume.Helium_3[F("space_belt_station_title")]=-t;for(let a=0;ae.split(":")[1]));for(b=0;bt.space.space_station.s_max){let i=e+r*-Qr.space.spc_belt[a[b]].support()-t.space.space_station.s_max;r-=Math.ceil(i/-Qr.space.spc_belt[a[b]].support()),$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.space[a[b]].on}`)}else $(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON");e+=r*-Qr.space.spc_belt[a[b]].support(),c[a[b]]=r}else c[a[b]]=0;t.space.space_station.support=e}if(t.interstellar.nexus&&t.interstellar.nexus.count>0){let e=350,a=i.nexus*e;r.p.consume.Money[F("interstellar_nexus_bd")]=-a;for(let t=0;te.split(":")[1]));for(b=0;bt.interstellar.nexus.s_max?(r-=e+r-t.interstellar.nexus.s_max,$(`#${s} .on`).addClass("warn"),$(`#${s} .on`).prop("title",`ON ${r}/${t.interstellar[a[b]].on}`)):($(`#${s} .on`).removeClass("warn"),$(`#${s} .on`).prop("title","ON")),e+=r,o[a[b]]=r}else o[a[b]]=0;t.interstellar.nexus.support=e}if(t.interstellar.xfer_station&&i.xfer_station){let e=.28,t=i.xfer_station*e;r.p.consume.Uranium[F("interstellar_xfer_station_title")]=-t;for(let a=0;a0){let e=+Jt(2,!0),t=i.outpost*e;r.p.consume.Oil[F("space_gas_moon_outpost_bd")]=-t;for(let a=0;a0){let e=+Yt(3),t=i.neutron_miner*e;r.p.consume.Helium_3[F("interstellar_neutron_miner_title")]=-t;for(let a=0;ae.split(":")[1]))},{area:"galaxy",region:"gxy_gorddon",ships:["freighter"],req:"embassy"},{area:"galaxy",region:"gxy_alien1",ships:["super_freighter"],req:"embassy"},{area:"galaxy",region:"gxy_alien2",ships:["armed_miner","scavenger"],req:"foothold"},{area:"galaxy",region:"gxy_chthonian",ships:["minelayer","raider"],req:"starbase"},{area:"portal",region:"prtl_lake",ships:["bireme","transport"],req:"harbour"}];let A=0,T=0,E=0;for(let e=0;eQr[a][r][i].ship.civ()&&(t.civic[t.civic.d_job].workers-=Qr[a][r][i].ship.civ(),t.civic.crew.workers+=Qr[a][r][i].ship.civ(),t[a][i].crew+=Qr[a][r][i].ship.civ()),t[a][i].crew>t[a][i].on*Qr[a][r][i].ship.civ()&&(t.civic[t.civic.d_job].workers+=Qr[a][r][i].ship.civ(),t.civic.crew.workers-=Qr[a][r][i].ship.civ(),t[a][i].crew-=Qr[a][r][i].ship.civ()),t.civic.crew.assigned=t.civic.crew.workers,A+=t[a][i].crew,E+=t[a][i].crew),Qr[a][r][i].ship.mil&&t[a][i].hasOwnProperty("mil")){if(t[a][i].mil!==t[a][i].on*Qr[a][r][i].ship.mil()&&(t[a][i].mil=t[a][i].on*Qr[a][r][i].ship.mil()),t.civic.garrison.workers-t.portal.fortress.garrison<0){let e=t.civic.garrison.workers-t.portal.fortress.garrison;t[a][i].mil-=e}T+t[a][i].mil>t.civic.garrison.workers-t.portal.fortress.garrison&&(t[a][i].mil=t.civic.garrison.workers-t.portal.fortress.garrison-T),t[a][i].mil<0&&(t[a][i].mil=0),T+=t[a][i].mil}t[a][i].crew0)&&(T+=it(e))})),t.civic.garrison.crew=T),Object.keys(ca).forEach((function(e){if(t.civic[e]&&("crew"!==e&&(E+=t.civic[e].workers,E>t.resource[t.race.species].amount&&(t.civic[e].workers-=E-t.resource[t.race.species].amount),t.civic[e].workers<0&&(t.civic[e].workers=0)),"unemployed"!==e&&"hunter"!==e&&"forager"!==e)){let a=t.civic[e].stress;if(t.city.ptrait.includes("mellow")&&(a+=Si.mellow.vars()[1]),t.race.content){let r="hell_surveyor"===e?.2:.4;a+=t.race.content*r}t.city.ptrait.includes("dense")&&"miner"===e&&(a-=Si.dense.vars()[1]),t.race.freespirit&&"farmer"!==e&&"lumberjack"!==e&&"quarry_worker"!==e&&"crystal_miner"!==e&&"scavenger"!==e&&(a/=1+ui.freespirit.vars()[0]/100);let r=t.civic[e].workers;t.race.high_pop&&(r/=ui.high_pop.vars()[0]),t.race.sky_lover&&["miner","coal_miner","crystal_miner","pit_miner"].includes(e)&&(r*=1+ui.sky_lover.vars()[0]/100),y-=r/a}})),t.civic[t.civic.d_job].workers+=t.resource[t.race.species].amount-E,t.civic[t.civic.d_job].workers<0&&(t.civic[t.civic.d_job].workers=0),Object.keys(ca).forEach((function(e){"craftsman"!==e&&t.civic[e]&&t.civic[e].workers0&&t.civic[e].workers40){let e=t.civic.taxes.tax_rate-40;t.city.morale.tax-=.5*e,p-=.5*e}if("oligarchy"===t.civic.govern.type&&t.civic.taxes.tax_rate>20){let e=t.civic.taxes.tax_rate-20;t.city.morale.tax+=.5*e,p+=.5*e}if(("autocracy"!==t.civic.govern.type&&!t.race.blood_thirst||t.race.immoral)&&t.civic.garrison.protest+t.civic.garrison.fatigue>2){let e=t.race.immoral?1+ui.immoral.vars()[0]/100:1,a=Math.round(Math.log2(t.civic.garrison.protest+t.civic.garrison.fatigue)*e);t.city.morale.warmonger=t.race.immoral?a:-a,p+=t.city.morale.warmonger}else t.city.morale.warmonger=0;let K=100;if(K+=t.city.casino?i.casino:0,K+=t.space.spc_casino?i.spc_casino:0,K+=t.tauceti.tauceti_casino?i.tauceti_casino:0,t.city.amphitheatre){let e=N("athleticism",0);K+=e?t.city.amphitheatre.count*e:t.city.amphitheatre.count}if(c.vr_center&&(K+=2*c.vr_center),o.zoo&&(K+=2*o.zoo),i.resort&&(K+=2*i.resort),t.tech.superstar){let e=t.race.high_pop?Me(1):1;K+=na(t.civic.entertainer.workers,"entertainer")*e}if(wo=K,t.tech.monuments){let e=N("gaslighter",2),a=e?2-e:2;wo+=t.tech.monuments*a}if(t.civic.taxes.tax_rate<20&&!t.race.banana&&(wo+=10-Math.floor(t.civic.taxes.tax_rate/2)),t.stats.achieve.joyless&&(wo+=2*t.stats.achieve.joyless.l),t.race.motivated){let e=Math.ceil(t.race.motivated**.4);wo+=Math.round(e/2)}let L=50;if(t.race.optimistic&&(L+=ui.optimistic.vars()[1]),P>0&&(L+=Math.round(ui.optimistic.vars(1)[1]*P)),t.race.truepath&&(L-=25),t.civic.govern.fr>0){let e=p/2;t.city.morale.rev=e,p-=e,L-=10}else t.city.morale.rev=0;if(t.race.tormented)if(p>100){let e=p-100;e=Math.ceil(e*ui.tormented.vars()[0]/100),p-=e,t.city.tormented=e}else t.city.tormented=0;else delete t.city.tormented;if(t.city.morale.potential=+p.toFixed(1),pwo&&(p=wo),t.city.morale.cap=wo,t.city.morale.current=p,t.city.morale.current<100)if(t.race.blissful){let e=t.city.morale.current-100,a=ui.blissful.vars()[0]/100;d*=1+e*a/100,r.p.Global[F("morale")]=e*a+"%"}else d*=t.city.morale.current/100,r.p.Global[F("morale")]=t.city.morale.current-100+"%";else d*=1+(t.city.morale.current-100)/200,r.p.Global[F("morale")]=(t.city.morale.current-100)/2+"%";if(t.race.lazy&&2===t.city.calendar.temp&&(r.p.Global[F("trait_lazy_bd")]="-"+ui.lazy.vars()[0]+"%",d*=1-ui.lazy.vars()[0]/100),t.race.distracted&&(r.p.Global[F("event_m_curious3_bd")]="-5%",d*=.95),t.race.stimulated&&(r.p.Global[F("event_m_curious4_bd")]="+10%",d*=1.1),t.race.selenophobia){let e=t.city.calendar.moon>14?28-t.city.calendar.moon:t.city.calendar.moon;r.p.Global[F("moon_phase")]=-e+ui.selenophobia.vars()[0]+"%",e=1+ui.selenophobia.vars()[0]/100-e/100,d*=e}if(t.interstellar.mass_ejector){let e=0,a=0,s=0;Object.keys(t.interstellar.mass_ejector).forEach((function(c){if(Va[c]){let o=t.interstellar.mass_ejector[c];e+o>1e3*i.mass_ejector&&(o=1e3*i.mass_ejector-e),e+=o,o>0&&(r.p.consume[c][F("interstellar_blackhole_name")]=-o),o*f>t.resource[c].amount&&(o=t.resource[c].amount/f),o<0&&(o=0),Vi(c,-f*o),a+=o*Va[c],"magic"===t.race.universe||"Elerium"!==c&&"Infernite"!==c||(s+=o*Va[c])}})),t.interstellar.mass_ejector.mass=a,t.interstellar.mass_ejector.total=e,t.interstellar.stellar_engine.mass+=a/1e10*f,t.interstellar.stellar_engine.exotic+=s/1e10*f}if(t.portal.transport&&t.portal.purifier){let e=0,a=0,s=t.blood.spire&&t.blood.spire>=2?.8:.85;if(Object.keys(t.portal.transport.cargo).forEach((function(i){if(Ja[i]){let c=t.portal.transport.cargo[i];e+c>5*n.transport&&(c=5*n.transport-e),e+=c;let o=c*Ja[i].out;for(;o*f>t.resource[i].amount&&o>0;)o-=Ja[i].out,c--;o>0&&(r.p.consume[i][F("portal_transport_title")]=-o);let l=1-s**(n.bireme||0);Vi(i,-f*o),a+=Number(c*Ja[i].in*f*l)}})),t.portal.mechbay)for(let e=0;et.portal.purifier.sup_max&&(t.portal.purifier.supply=t.portal.purifier.sup_max)}if(t.race.carnivore&&!t.race.herbivore&&!t.race.soul_eater&&!t.race.artifical&&t.resource.Food.amount>10){let e=ui.carnivore.vars()[0]/100,a=+((t.resource.Food.amount-10)*e).toFixed(3);t.city.smokehouse&&(a*=.9**t.city.smokehouse.count),Vi("Food",-a*f),r.p.consume.Food[F("spoilage")]=-a}if(t.race.gnawer){let e=t.race.kindling_kindred||t.race.smoldering?"Stone":"Lumber";if(t.resource[e].display){let a=(t.resource[t.race.species].amount+t.civic.garrison.workers)*ui.gnawer.vars()[0];r.p.consume[e][F("trait_gnawer_bd")]=-a,Vi(e,-a*f)}}var x=!0;if(t.resource[t.race.species].amount>=1||t.city.farm||t.city.soul_well||t.city.compost||t.city.tourist_center||t.city.transmitter){let e=0,s="virgo"===a?1+H("virgo")[0]/100:1;if(t.race.artifical)t.city.transmitter&&(e=i.transmitter*Pe("transmitter")*Pe("psychic_boost","Food"),r.p.Food[F("city_transmitter")]=e+"v",t.city.transmitter.lpmod=Pe("transmitter")*d*Pe("psychic_boost","Food"));else if(t.race.detritivore){if(t.city.compost){let a=t.city.compost.on;if(!t.race.kindling_kindred){let e=.5,s=a*e;for(;s*f>t.resource.Lumber.amount&&s>0;)s-=e,a--;r.p.consume.Lumber[F("city_compost_heap")]=-s,Vi("Lumber",-s*f)}let s=ui.detritivore.vars()[0]/100,i=a*(1.2+t.tech.compost*s);i*="grassland"===t.city.biome?ji.grassland.vars()[0]:1,i*="savanna"===t.city.biome?ji.savanna.vars()[0]:1,i*="ashland"===t.city.biome?ji.ashland.vars()[0]:1,i*="volcanic"===t.city.biome?ji.volcanic.vars()[0]:1,i*="hellscape"===t.city.biome?ji.hellscape.vars()[0]:1,i*=t.city.ptrait.includes("trashed")?Si.trashed.vars()[0]:1,i*=Pe("psychic_boost","Food"),r.p.Food[F("city_compost_heap")]=i+"v",e+=i}}else if(t.race.carnivore||t.race.soul_eater){let a=xe(),s=na(t.civic.hunter.workers,"hunter");if(s*=pi(s,"hunting"),t.race.servants&&(s+=t.race.servants.jobs.hunter),s*=a*(t.race.carnivore?2:.5),t.race.ghostly&&(s*=1+ui.ghostly.vars()[0]/100),s*=Pe("psychic_boost","Food"),r.p.Food[F(t.race.unfathomable?"job_raider":"job_hunter")]=s+"v",t.race.carnivore&&t.city.lodge&&s>0&&(s*=1+t.city.lodge.count/20,r.p.Food[`ᄂ${F("city_lodge")}`]=5*t.city.lodge.count+"%"),t.city.soul_well){let e=t.city.soul_well.count*(t.race.ghostly?2+ui.ghostly.vars()[1]:2);s+=e*Pe("psychic_boost","Food"),r.p.Food[F("city_soul_well")]=e+"v"}e+=s}else if(t.race.unfathomable){if(t.city.captive_housing){let a=xe(),s=na(t.civic.hunter.workers,"hunter")*a;s*=pi(s,"hunting"),t.race.servants&&(s+=t.race.servants.jobs.hunter*a);let i=.008*s;if(t.city.captive_housing.cattle0&&(s-=Math.round(t.city.captive_housing.cattle**1.25),s=t.city.captive_housing.cattle**2&&(t.city.captive_housing.cattle++,t.city.captive_housing.cattleCatch=0),t.city.captive_housing.cattle>0&&t.resource.Food.amount<.01*t.resource.Food.max&&(t.city.captive_housing.cattle--,t.resource.Food.amount+=1e3,t.stats.cattle++)),t.city.captive_housing.cattle>0){let a=t.city.captive_housing.cattle/3*Pe("psychic_boost","Food");r.p.Food[F("city_captive_housing_cattle_bd")]=a+"v",e+=a}}}else if(t.city.farm||t.race.forager){let a=1;if(t.race.submerged||(0===t.city.calendar.temp&&(0===t.city.calendar.weather?a*=t.race.chilled?1+ui.chilled.vars()[3]/100:.7:a*=t.race.chilled?1+ui.chilled.vars()[4]/100:.85),2===t.city.calendar.weather&&(a*=t.race.chilled?1-ui.chilled.vars()[5]/100:1.1)),t.race.forager){let a=1+(t.tech.foraging?.75*t.tech.foraging:0),s=na(t.civic.forager.workers,"forager");t.race.servants&&(s+=t.race.servants.jobs.forager);let i=s*a*.35;r.p.Food[F("job_forager")]=i+"v",e+=i}if(t.city.farm){let i=na(t.civic.farmer.workers,"farmer"),c=0;i>la(t.city.farm.count)&&(c=i-la(t.city.farm.count),i=la(t.city.farm.count));let o=i*pa(!0)+c*pa(!1);if(t.race.servants){let e=la(t.race.servants.jobs.farmer),a=0,r=la(t.city.farm.count)-i;e>r&&(a=e-r,e=r),o+=e*pa(!0,!0)+a*pa(!1,!0)}let n=1;if(t.city.mill){let e=t.tech.agriculture>=5?.05:.03;n+=(t.city.mill.count-t.city.mill.on)*e}r.p.Food[F("job_farmer")]=o+"v",e+=o*s*a*n*h*Pe("psychic_boost","Food"),o>0&&(r.p.Food[`ᄂ${F("city_mill_title1")}`]=100*(n-1)+"%",r.p.Food[`ᄂ${F("sign_virgo")}+0`]=100*(s-1)+"%",r.p.Food[`ᄂ${F("morale_weather")}`]=100*(a-1)+"%",r.p.Food[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%")}}if(t.tauceti.tau_farm&&i.tau_farm){let e=1+.5*(c.colony||0),t=Pe("tau_farm","food")*i.tau_farm*Pe("psychic_boost","Food"),a=t*d*e;r.p.Food[F("tau_home_tau_farm")]=t+"v",t>0&&(r.p.Food[`ᄂ${F("tau_home_colony")}`]=100*(e-1)+"%"),Vi("Food",a*f)}let n=0;t.tech.military&&(n=t.race.herbivore&&!t.race.carnivore||t.race.artifical?0:ke(qe(),"hunting")/3);let l=0,u=ht("spc_red");t.tech.mars&&(l=c.biodome*na(t.civic.colonist.workers,"colonist")*Pe("biodome","food")*Pe("psychic_boost","Food"),(t.race.cataclysm||t.race.orbit_decayed)&&(l+=c.biodome*Pe("biodome","cat_food")*Pe("psychic_boost","Food"))),r.p.Food[Qr.space.spc_red.biodome.title()]=l+"v",l>0&&(r.p.Food[`ᄂ${F("space_syndicate")}+0`]=-100*(1-u)+"%",r.p.Food[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%",r.p.Food[`ᄂ${F("sign_virgo")}+0`]=100*(s-1)+"%");let p=e+n*h+l*u*_*s;p*=d;let m=t.civic.garrison.workers;t.race.parasite&&!t.tech.isolation&&(m-=2,m<0&&(m=0));let g=t.resource[t.race.species].amount+m-.5*(t.civic.unemployed.workers+na(t.civic.hunter.workers,"hunter"));t.race.forager&&(g-=na(t.civic.forager.workers,"forager")),g*=t.race.gluttony?1+ui.gluttony.vars()[0]/100:1,t.race.high_metabolism&&(g*=1+ui.high_metabolism.vars()[0]/100),t.race.sticky&&(g*=1-ui.sticky.vars()[0]/100);let v=Pi("pinguicula");if(v>0&&(g*=1-ui.sticky.vars(1)[0]/100*v),t.race.photosynth)switch(t.city.calendar.weather){case 0:g*=0===t.city.calendar.temp?1:1-ui.photosynth.vars()[2]/100;break;case 1:g*=1-ui.photosynth.vars()[1]/100;break;case 2:g*=1-ui.photosynth.vars()[0]/100}t.race.ravenous&&(g*=1+ui.ravenous.vars()[0]/100,g+=t.resource.Food.amount/ui.ravenous.vars()[1]),t.race.hibernator&&3===t.city.calendar.season&&(g*=1-ui.hibernator.vars()[0]/100),t.race.high_pop&&(g/=ui.high_pop.vars()[0]),r.p.consume.Food[Ac("name")]=-g;let y=0;t.city.tourist_center&&(y=50*t.city.tourist_center.on,r.p.consume.Food[F("tech_tourism")]=-y);let b=0;t.space.spaceport&&(b=i.spaceport*(t.race.cataclysm||t.race.orbit_decayed?2:25),r.p.consume.Food[F("space_red_spaceport_title")]=-b);let w=0;t.interstellar.starport&&(w=100*i.starport,r.p.consume.Food[F("interstellar_alpha_starport_title")]=-w);let $=0;t.galaxy.starbase&&($=i.s_gate*i.starbase*250,r.p.consume.Food[F("galaxy_starbase")]=-$);let k=0;t.space.space_station&&(k=i.space_station*(t.race.cataclysm?1:10),r.p.consume.Food[F("space_belt_station_title")]=-k);let q=0;t.space.space_barracks&&!t.race.cataclysm&&(q=10*t.space.space_barracks.on,r.p.consume.Food[F("tech_space_marines_bd")]=-q);let M=0;t.galaxy.embassy&&(M=i.s_gate*i.embassy*7500,r.p.consume.Food[F("galaxy_embassy")]=-M);let P=0;t.interstellar.zoo&&(P=12e3*o.zoo,r.p.consume.Food[F("tech_zoo")]=-P);let O=p-g-y-b-w-$-k-q-M-P;if(r.p.Food[F("soldiers")]=n+"v",n>0&&(r.p.Food[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),!Vi("Food",O*f))if(t.race.anthropophagite&&t.resource[t.race.species].amount>1)t.resource[t.race.species].amount--,Vi("Food",1e4*ui.anthropophagite.vars()[0]),t.stats.murders++;else{x=!1;let e=1.25;t.race.slow_digestion&&(e+=ui.slow_digestion.vars()[0]);let a=Pi("slitheryn");a>0&&(e+=ui.slow_digestion.vars(1)[0]*a),t.race.humpback&&(e+=ui.humpback.vars()[0]),t.race.atrophy&&(e-=ui.atrophy.vars()[0]),p1&&0===Math.rand(0,400)&&(t.resource[t.race.species].amount--,Vi("Food",1e4*ui.anthropophagite.vars()[0]),t.stats.murders++)}if(t.portal.fortress&&t.portal.fortress.walls<100&&(Vi("Stone",-200*f)&&(t.portal.fortress.repair+=4*f,r.p.consume.Stone[F("portal_fortress_name")]=-200),t.portal.fortress.repair>=Qr.portal.prtl_fortress.info.repair()&&(t.portal.fortress.repair=0,t.portal.fortress.walls+=4*f,t.portal.fortress.walls>100&&(t.portal.fortress.walls=100))),t.race.psychic&&t.resource.Energy.display){let e={},t=ui.psychic.vars()[2];e[F("trait_psychic_name")]=t+"v",Vi("Energy",t*f),r.p.Energy=e}if(t.civic.homeless>0){let e=Math.min(t.civic.homeless,t.resource[t.race.species].max-t.resource[t.race.species].amount);t.civic.homeless-=e,t.resource[t.race.species].amount+=e}else if(x&&t.resource.Food.amount>0&&t.resource[t.race.species].max>t.resource[t.race.species].amount)if(t.race.artifical||t.race.spongy&&0===t.city.calendar.weather);else if(!t.race.parasite||0!==t.city.calendar.wind||t.race.cataclysm||t.race.orbit_decayed)if(t.race.vax&&t.race.vax>=100);else{var q=t.tech.reproduction?t.tech.reproduction:0;t.tech.reproduction&&1===e.getMonth()&&14===e.getDate()&&(q+=5),t.race.fast_growth&&(q*=ui.fast_growth.vars()[0],q+=ui.fast_growth.vars()[1]),t.race.spores&&1===t.city.calendar.wind&&(t.race.parasite?q+=ui.spores.vars()[2]:(q+=ui.spores.vars()[0],q*=ui.spores.vars()[1])),t.tech.reproduction&&t.tech.reproduction>=2&&t.city.hospital&&(q+=t.city.hospital.count),t.genes.birth&&(q+=t.genes.birth),t.race.promiscuous&&(q+=ui.promiscuous.vars()[0]*t.race.promiscuous),"libra"===a&&(q*=1+H("libra")[0]/100),t.race.high_pop&&(q*=ui.high_pop.vars()[2]),"taiga"===t.city.biome&&(q*=ji.taiga.vars()[1]);let r=t.city.ptrait.includes("toxic")?t.resource[t.race.species].amount*Si.toxic.vars()[1]:t.resource[t.race.species].amount;t.race.parasite&&(t.race.cataclysm||t.race.orbit_decayed)&&(q=Math.round(q/5),r*=3),Math.rand(0,r*(3-2**f))<=q&&t.resource[t.race.species].amount++}let D=0,B=0;if(i.s_gate){let e=["freighter","super_freighter","minelayer","raider"];for(let a=0;a0;if(i.s_gate&&o&&t[a][c]&&(t[a][c].crew>0||t[a][c].mil>0)){let e=0;if(Qr[a][r][c].ship.civ()>0&&(e=Math.floor(t[a][c].crew/Qr[a][r][c].ship.civ())),Qr[a][r][c].ship.mil()>0){let s=Math.floor(t[a][c].mil/Qr[a][r][c].ship.mil());(0===Qr[a][r][c].ship.civ()||st.resource.Helium_3.amount+(t.resource.Helium_3.diff>0?t.resource.Helium_3.diff*f:0)&&i>0;)i-=s,e--;Vi("Helium_3",-i*f),D+=i}if(Qr[a][r][c].ship.hasOwnProperty("deuterium")){let s=+Yt(Qr[a][r][c].ship.deuterium).toFixed(2),i=e*s;for(;i*f>t.resource.Deuterium.amount+(t.resource.Deuterium.diff>0?t.resource.Deuterium.diff*f:0)&&i>0;)i-=s,e--;Vi("Deuterium",-i*f),B+=i}n.hasOwnProperty(c)?n[c]=n[c]>e?e:n[c]:n[c]=e}else n[c]=0}}if(r.p.consume.Helium_3[F("galaxy_fuel_consume")]=-D,r.p.consume.Deuterium[F("galaxy_fuel_consume")]=-B,t.space.shipyard&&t.space.shipyard.ships){let e={Oil:0,Helium_3:0,Uranium:0,Elerium:0};t.space.shipyard.ships.forEach((function(a){if("spc_dwarf"!==a.location){let r=lt(a);r.res&&r.burn>0?r.burn*f0?t.resource[r.res].diff*f:0)?(Vi(r.res,-r.burn*f),a.fueled=!0,e[r.res]+=r.burn):a.fueled=!1:a.fueled=!0}})),r.p.consume.Oil[F("outer_shipyard_fleet")]=-e.Oil,r.p.consume.Helium_3[F("outer_shipyard_fleet")]=-e.Helium_3,r.p.consume.Uranium[F("outer_shipyard_fleet")]=-e.Uranium,r.p.consume.Elerium[F("outer_shipyard_fleet")]=-e.Elerium}t.race.emfield&&(t.race.discharge&&t.race.discharge>0?t.race.discharge-=4*f:(t.race.emfield++,0===Math.rand(0,500)&&(t.race.discharge=t.race.emfield,t.race.emfield=1)));let G=x?1:.5;if(t.race.angry&&!1===x&&(G-=ui.angry.vars()[0]/100),t.race.malnutrition&&!1===x&&(G+=ui.malnutrition.vars()[0]/100),t.resource.Furs.display){if(t.race.evil||t.race.artifical||t.race.unfathomable){let e=xe(),a=na(t.civic.hunter.workers,"hunter");if(a*=pi(a,"hunting"),t.race.servants&&(a+=la(t.race.servants.jobs.hunter)),a*=e/20,"savanna"===t.city.biome&&(a*=ji.savanna.vars()[1]),t.race.high_pop&&(a=Me(a)),a*=Pe("psychic_boost","Furs"),r.p.Furs[F(t.race.unfathomable?"job_raider":"job_hunter")]=a+"v",a>0&&(r.p.Furs[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),Vi("Furs",a*G*d*f*h),!t.race.soul_eater&&t.race.evil){let e=na(t.civic.lumberjack.workers,"lumberjack");e*=pi(e,"lumberjack"),t.race.servants&&(e+=t.race.servants.jobs.lumberjack),e/=4,e*=Pe("psychic_boost","Furs"),r.p.Furs[F("job_reclaimer")]=e+"v",e>0&&(r.p.Furs[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),Vi("Furs",e*G*d*f*h)}}let e=ke(qe(),"hunting")/10;if("oceanic"===t.city.biome?e*=ji.oceanic.vars()[2]:"tundra"===t.city.biome&&(e*=ji.tundra.vars()[0]),e*=Pe("psychic_boost","Furs"),r.p.Furs[F("soldiers")]=e+"v",e>0&&(r.p.Furs[`ᄂ${F("quarantine")}+2`]=100*(h-1)+"%"),Vi("Furs",e*G*d*h*f),t.race.forager){let e=1+(t.tech.foraging?.5*t.tech.foraging:0),a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.05*Pe("psychic_boost","Furs");r.p.Furs[F("job_forager")]=s+"v",s>0&&(r.p.Furs[`ᄂ${F("quarantine")}+3`]=100*(h-1)+"%"),Vi("Furs",s*G*h*f)}}if(t.resource.Furs.display&&t.tech.isolation&&t.tauceti.womling_farm){let e=t.tauceti.womling_farm.farmers*Pe("psychic_boost","Furs"),a=e*d;r.p.Furs[F("tau_red_womlings")]=e+"v",Vi("Furs",a)}if(t.race.unfathomable&&t.civic.hunter.display){let e=xe(),a=na(t.civic.hunter.workers,"hunter");a*=pi(a,"hunting"),t.race.servants&&(a+=la(t.race.servants.jobs.hunter)),a*=e/20,t.race.high_pop&&(a=Me(a)),["Lumber","Chrysotile","Stone","Crystal","Copper","Iron","Aluminium","Cement","Coal","Oil","Uranium","Steel","Titanium","Alloy","Polymer","Iridium"].forEach((function(e){if(t.resource[e].display){let s=a*Pe("psychic_boost",e)*Za[e]/5;["Crystal","Uranium"].includes(e)?s*=.2:["Alloy","Polymer","Iridium"].includes(e)?s*=.35:["Steel","Cement"].includes(e)?s*=.85:["Titanium"].includes(e)&&(s*=.65),r.p[e][F(t.race.unfathomable?"job_raider":"job_hunter")]=s+"v",s>0&&(r.p[e][`ᄂ${F("quarantine")}+99`]=100*(h-1)+"%"),Vi(e,s*G*d*f*h)}}))}{let e=t.tech.primitive&&t.tech.primitive>=3?1:0;t.race.ancient_ruins&&e++,t.stats.achieve.extinct_junker&&t.stats.achieve.extinct_junker.l>=1&&e++,t.city.ptrait.includes("magnetic")&&(e+=Si.magnetic.vars()[0]),t.race.ascended&&(e+=2);let s=na(t.civic.professor.workers,"professor"),o=t.race.studious?t.civic.professor.impact+ui.studious.vars()[0]:t.civic.professor.impact,n=Pi("elven");n>0&&(o+=ui.studious.vars(1)[0]*n),s*=o,s*=t.race.pompous?1-ui.pompous.vars()[0]/100:1,s*=pi(na(t.civic.professor.workers,"professor"),"science"),t.tech.anthropology&&t.tech.anthropology>=3&&(s*=1+.05*(t.race.cataclysm||t.race.orbit_decayed?t.space.ziggurat?t.space.ziggurat.count:0:t.city.temple.count)),"theocracy"===t.civic.govern.type&&(s*=1-ae.theocracy()[1]/100);let l=na(t.civic.scientist.workers,"scientist");if(l*=t.civic.scientist.impact,l*=pi(na(t.civic.scientist.workers,"scientist"),"science"),t.tech.science>=6&&t.city.wardenclyffe){let e=na(t.civic.professor.workers,"professor");t.race.high_pop&&(e=Me(e)),l*=1+e*i.wardenclyffe*.01}t.space.satellite&&(l*=1+.01*t.space.satellite.count),"theocracy"===t.civic.govern.type&&(l*=1-ae.theocracy()[2]/100);let u=.05,_=N("muckraker",2);_&&(u-=_/100),t.race.autoignition&&(u-=ui.autoignition.vars()[0]/100,u<0&&(u=0));let p=t.city.library?1+t.city.library.count*u:1,h="gemini"===a?1+H("gemini")[0]/100:1,m=0;if(t.arpa.sequence&&t.arpa.sequence.on&&t.arpa.sequence.time>0){let e=50+10*t.race.mutation;t.arpa.sequence.boost&&(e*=4),e*f<=t.resource.Knowledge.amount?(m=e,xo=!0):xo=!1}else t.arpa.hasOwnProperty("sequence")&&null===t.arpa.sequence.time&&(t.arpa.sequence.time=t.arpa.sequence.max),xo=!1;let g=t.tauceti.hasOwnProperty("womling_lab")?t.tauceti.womling_lab.scientist*(t.tech.womling_gene?10:8):0,v=t.tech.isolation?1+.75*(c.infectious_disease_lab||0):1,y=s+l+g;if(y*=G*d,y+=e*d,y*=p*v,r.p.Knowledge[F("job_professor")]=s+"v",r.p.Knowledge[F("job_scientist")]=l+"v",r.p.Knowledge[F("tau_red_womlings")]=g+"v",r.p.Knowledge[F("hunger")]=100*(G-1)+"%",r.p.Knowledge[t.race.unfathomable?F("tech_moondial"):F("tech_sundial")]=e+"v",t.race.inspired&&(r.p.Knowledge[F("event_inspiration_bd")]="100%",y*=2),t.city.library&&(r.p.Knowledge[F("city_library")]=100*(p-1)+"%"),"gemini"===a&&(r.p.Knowledge[F(`sign_${a}`)]=100*(h-1)+"%"),t.tech.isolation&&c.infectious_disease_lab&&(r.p.Knowledge[Qr.tauceti.tau_home.infectious_disease_lab.title()]=100*(v-1)+"%"),"technocracy"===t.civic.govern.type&&(r.p.Knowledge[F("govern_technocracy")]=ae.technocracy()[2]+"%",y*=1+ae.technocracy()[2]/100),m>0&&(y-=m,r.p.consume.Knowledge[F("genome_bd")]=-m),Vi("Knowledge",y*f),t.tech.tau_gas2&&t.tech.tau_gas2>=6&&(!t.tech.alien_data||t.tech.alien_data<6)&&t.tauceti.alien_space_station&&i.alien_space_station){let e=t.tauceti.alien_space_station.focus/100*y;r.p.consume.Knowledge[F("tau_gas2_alien_station")]=-e,Vi("Knowledge",-e*f),t.tauceti.alien_space_station.decrypted+=+e.toFixed(3),t.stats.know+=+e.toFixed(0),t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?1e6:25e7)&&!t.tech.alien_data?(t.tech.alien_data=1,Di(F("tau_gas2_alien_station_data1",[F("tech_dist_womling")]),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?2e6:5e8)&&t.tech.alien_data&&1===t.tech.alien_data?(t.tech.alien_data=2,t.race.tau_food_item=Math.rand(0,10),Di(F("tau_gas2_alien_station_data2",[F(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?3e6:75e7)&&t.tech.alien_data&&2===t.tech.alien_data?(t.tech.alien_data=3,Di(F("tau_gas2_alien_station_data3"),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?48e5:12e8)&&t.tech.alien_data&&3===t.tech.alien_data?(t.tech.alien_data=4,t.race.tau_junk_item=Math.rand(0,10),Di(F("tau_gas2_alien_station_data4",[F(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`)]),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?6e6:15e8)&&t.tech.alien_data&&4===t.tech.alien_data?(t.tech.alien_data=5,Di(F("tau_gas2_alien_station_data5"),"success",!1,["progress"]),ms()):t.tauceti.alien_space_station.decrypted>=(t.race.lone_survivor?1e7:25e8)&&t.tech.alien_data&&5===t.tech.alien_data&&(t.tech.alien_data=6,t.tauceti.alien_space_station.decrypted=25e8,t.race.lone_survivor?(t.settings.tau.star=!0,t.tech.matrix=2,t.tauceti.ringworld={count:0},Di(F("tau_gas2_alien_station_data6_alt"),"success",!1,["progress"])):Di(F("tau_gas2_alien_station_data6"),"success",!1,["progress"]),ms())}}let R=0;if(t.city.factory){let e=(i.factory||0)+(i.red_factory||0)+2*(i.int_factory||0)+(c.tau_factory||0)*(t.tech.isolation?5:3),a=t.city.factory.on+(t.space.red_factory?t.space.red_factory.on:0)+(t.interstellar.int_factory?2*t.interstellar.int_factory.on:0)+(t.tauceti.tau_factory?t.tauceti.tau_factory.on*(t.tech.isolation?5:3):0),s=a>0?e/a:0,o=a;["Lux","Furs","Alloy","Polymer","Nano","Stanene"].forEach((function(e){o-=t.city.factory[e],o<0&&(t.city.factory[e]+=o,o=0)}));let l=t.tech.factory||0,p=t.tech.isolation?1+.5*(c.colony||0):1;if(t.city.factory.Lux&&t.city.factory.Lux>0){let e=t.city.factory.Lux*Qs.Lux.fur[l]*s,a=t.city.factory.Lux;for(;e*f>t.resource.Furs.amount&&e>0;)e-=Qs.Lux.fur[l]*s,a--;r.p.consume.Furs[F("city_factory")]=-e,Vi("Furs",-e*f);let i=t.resource[t.race.species].amount*Qs.Lux.demand[l]*s;i=Zs(i);let c=a*i*p;R=c*G,t.race.discharge&&t.race.discharge>0&&(c*=.5),c*=d,Vi("Money",c*f)}if(t.city.factory.Furs&&t.city.factory.Furs>0){let e=Qs.Furs.money[l]*s,a=Qs.Furs.polymer[l]*s,i=t.city.factory.Furs*e,c=t.city.factory.Furs*a,o=t.city.factory.Furs;for(;c*f>t.resource.Polymer.amount&&c>0;)c-=a,i-=e,o--;for(;i*f>t.resource.Money.amount&&i>0;)c-=a,i-=e,o--;r.p.consume.Money[F("city_factory")]=-i,r.p.consume.Polymer[F("city_factory")]=-c,Vi("Money",-i*f),Vi("Polymer",-c*f);let n=o*Qs.Furs.output[l]*s*Pe("psychic_boost","Furs");t.race.toxic&&(n*=1+ui.toxic.vars()[0]/100);let _=Pi("shroomi");_>0&&(n*=1+ui.toxic.vars(1)[0]/100*_),"corpocracy"===t.civic.govern.type&&(n*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(n*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(n*=1.1);let h=n*p;if(h*=G*d,r.p.Furs[F("city_factory")]=n+"v",h>0&&(p>0&&(r.p.Furs[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(h*=.5,r.p.Furs[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory)){let e=(u-1)/8+1;h*=e,r.p.Furs[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}Vi("Furs",h*f)}if(t.city.factory.Alloy&&t.city.factory.Alloy>0){let e=t.city.factory.Alloy*Qs.Alloy.copper[l]*s,a=t.city.factory.Alloy*Qs.Alloy.aluminium[l]*s,i=t.city.factory.Alloy;for(;e*f>t.resource.Copper.amount&&e>0;)e-=Qs.Alloy.copper[l]*s,a-=Qs.Alloy.aluminium[l]*s,i--;for(;a*f>t.resource.Aluminium.amount&&a>0;)e-=Qs.Alloy.copper[l]*s,a-=Qs.Alloy.aluminium[l]*s,i--;r.p.consume.Copper[F("city_factory")]=-e,r.p.consume.Aluminium[F("city_factory")]=-a,Vi("Copper",-e*f),Vi("Aluminium",-a*f);let c=i*Qs.Alloy.output[l]*s*Pe("psychic_boost","Alloy");t.race.toxic&&(c*=1+ui.toxic.vars()[0]/100);let o=Pi("shroomi");o>0&&(c*=1+ui.toxic.vars(1)[0]/100*o),t.tech.alloy&&(c*=1.37),t.race.metallurgist&&(c*=1+ui.metallurgist.vars()[0]*t.race.metallurgist/100),"corpocracy"===t.civic.govern.type&&(c*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(c*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(c*=1.1);let n=c*p;if(n*=G*d,r.p.Alloy[F("city_factory")]=c+"v",n>0){if(p>0&&(r.p.Alloy[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(n*=.5,r.p.Alloy[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory){let e=(u-1)/2+1;n*=e,r.p.Alloy[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}r.p.Alloy[F("hunger")]=100*(G-1)+"%"}Vi("Alloy",n*f)}else r.p.Alloy=0;if(t.city.factory.Polymer&&t.city.factory.Polymer>0){let e=t.race.kindling_kindred||t.race.smoldering?Qs.Polymer.oil_kk[l]*s:Qs.Polymer.oil[l]*s,a=t.race.kindling_kindred||t.race.smoldering?0:Qs.Polymer.lumber[l]*s,i=t.city.factory.Polymer*e,c=t.city.factory.Polymer*a,o=t.city.factory.Polymer;for(;c*f>t.resource.Lumber.amount&&c>0;)c-=a,i-=e,o--;for(;i*f>t.resource.Oil.amount&&i>0;)c-=a,i-=e,o--;r.p.consume.Lumber[F("city_factory")]=-c,r.p.consume.Oil[F("city_factory")]=-i,Vi("Lumber",-c*f),Vi("Oil",-i*f);let n=o*Qs.Polymer.output[l]*s*Pe("psychic_boost","Polymer");t.race.toxic&&(n*=1+ui.toxic.vars()[0]/100);let _=Pi("shroomi");_>0&&(n*=1+ui.toxic.vars(1)[0]/100*_),t.tech.polymer>=2&&(n*=1.42),"corpocracy"===t.civic.govern.type&&(n*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(n*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(n*=1.1);let h=n*p;if(h*=G*d,r.p.Polymer[F("city_factory")]=n+"v",h>0&&(p>0&&(r.p.Polymer[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(h*=.5,r.p.Polymer[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory)){let e=(u-1)/2+1;h*=e,r.p.Polymer[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}r.p.Polymer[F("hunger")]=100*(G-1)+"%",Vi("Polymer",h*f)}if(i.s_gate&&t.galaxy.raider&&n.raider>0){let e=2.3*n.raider*Pe("psychic_boost","Polymer"),t=Et("gxy_chthonian"),a=e*d*t*G*_;r.p.Polymer[F("galaxy_raider")]=e+"v",e>0&&(r.p.Polymer[`ᄂ${F("galaxy_piracy")}`]=-100*(1-t)+"%",r.p.Polymer[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),Vi("Polymer",a*f)}if(t.city.factory.Nano&&t.city.factory.Nano>0){let e=Qs.Nano_Tube.coal[l]*s,a=Qs.Nano_Tube.neutronium[l]*s,i=t.city.factory.Nano*e,c=t.city.factory.Nano*a,o=t.city.factory.Nano;for(;c*f>t.resource.Neutronium.amount&&c>0;)c-=a,i-=e,o--;for(;i*f>t.resource.Coal.amount&&i>0;)c-=a,i-=e,o--;r.p.consume.Coal[F("city_factory")]=-i,r.p.consume.Neutronium[F("city_factory")]=-c,Vi("Neutronium",-c*f),Vi("Coal",-i*f);let n=o*Qs.Nano_Tube.output[l]*s*Pe("psychic_boost","Nano_Tube");t.race.toxic&&(n*=1+ui.toxic.vars()[1]/100);let _=Pi("shroomi");_>0&&(n*=1+ui.toxic.vars(1)[1]/100*_),t.tech.polymer>=2&&(n*=1.42),"corpocracy"===t.civic.govern.type&&(n*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(n*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(n*=1.1);let h=n*p;if(h*=G*d,r.p.Nano_Tube[F("city_factory")]=n+"v",h>0){if(p>0&&(r.p.Nano_Tube[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(h*=.5,r.p.Nano_Tube[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory){let e=(u-1)/2+1;h*=e,r.p.Nano_Tube[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}r.p.Nano_Tube[F("hunger")]=100*(G-1)+"%"}Vi("Nano_Tube",h*f)}else r.p.Nano_Tube=0;if(t.city.factory.Stanene&&t.city.factory.Stanene>0){let e=Qs.Stanene.aluminium[l]*s,a=Qs.Stanene.nano[l]*s,i=t.city.factory.Stanene*e,c=t.city.factory.Stanene*a,o=t.city.factory.Stanene;for(;i*f>t.resource.Aluminium.amount&&i>0;)c-=a,i-=e,o--;for(;c*f>t.resource.Nano_Tube.amount&&c>0;)c-=a,i-=e,o--;r.p.consume.Aluminium[F("city_factory")]=r.p.consume.Aluminium[F("city_factory")]?r.p.consume.Aluminium[F("city_factory")]-i:-i,r.p.consume.Nano_Tube[F("city_factory")]=-c,Vi("Aluminium",-i*f),Vi("Nano_Tube",-c*f);let n=o*Qs.Stanene.output[l]*s*Pe("psychic_boost","Stanene");t.race.toxic&&(n*=1+ui.toxic.vars()[1]/100);let _=Pi("shroomi");_>0&&(n*=1+ui.toxic.vars(1)[1]/100*_),"corpocracy"===t.civic.govern.type&&(n*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(n*=1+ae.socialist()[1]/100),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(n*=1.1);let h=n*p;if(h*=G*d,r.p.Stanene[F("city_factory")]=n+"v",h>0){if(p>0&&(r.p.Stanene[`ᄂ${F("tau_home_colony")}`]=100*(p-1)+"%"),t.race.discharge&&t.race.discharge>0&&(h*=.5,r.p.Stanene[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.tech.q_factory){let e=(u-1)/2+1;h*=e,r.p.Stanene[`ᄂ${F("quantum")}`]=100*(e-1)+"%"}r.p.Stanene[F("hunger")]=100*(G-1)+"%"}Vi("Stanene",h*f)}else r.p.Stanene=0}if(t.resource.Furs.display&&(r.p.Furs[F("hunger")]=100*(G-1)+"%"),t.resource.Cement.display){let e=t.race.high_pop?3/ui.high_pop.vars()[0]:3;"ashland"===t.city.biome&&(e*=ji.ashland.vars()[1]);let a=na(t.civic.cement_worker.workers,"cement_worker")*e,s=na(t.civic.cement_worker.workers,"cement_worker");for(;a*f>t.resource.Stone.amount&&a>0;)a-=e,s--;let o=t.tech.isolation?1+.5*(c.colony||0):1;r.p.consume.Stone[F(t.tech.isolation?"job_cement_worker_bd":"city_cement_plant_bd")]=-a,Vi("Stone",-a*f);let n=t.tech.cement>=4?1.2:1;n*=t.civic.cement_worker.impact,n*=pi(na(t.civic.cement_worker.workers,"cement_worker"),"factory"),"ashland"===t.city.biome&&(n*=ji.ashland.vars()[1]),t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=3&&(n*=1.1);let l=s*n*Pe("psychic_boost","Cement");"corpocracy"===t.civic.govern.type&&(l*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(l*=1+ae.socialist()[1]/100);let _=1,p=1;if(t.city.powered&&i.cement_plant){let e=t.tech.cement>=6?.08:.05;_+=i.cement_plant*e,p+=e}let m=1;if(t.tech.ai_core&&i.citadel>0){let e=+(u/1.75).toFixed(1)/100;m+=i.citadel*e}let g=t.tech.isolation?1+.08*c.mining_pit:1,v=t.tech.isolation?1:h;r.p.Cement[F(t.tech.isolation?"job_cement_worker_bd":"city_cement_plant_bd")]=l+"v",l>0&&(t.tech.isolation&&(r.p.Cement[`ᄂ${F("tau_home_colony")}+0`]=100*(o-1)+"%",r.p.Cement[`ᄂ${F("tau_home_mining_pit")}+0`]=100*(g-1)+"%"),r.p.Cement[`ᄂ${F("power")}+0`]=100*(_-1)+"%",r.p.Cement[`ᄂ${F("quarantine")}+0`]=100*(v-1)+"%"),t.race.discharge&&t.race.discharge>0&&i.cement_plant>0&&(_=.5*(_-1)+1,p=.5*(p-1)+1,r.p.Cement[`ᄂ${F("evo_challenge_discharge")}`]="-50%");let y=l*m*o*g;t.city.cement_plant&&(t.city.cement_plant.cnvay=+(y*G*v*d*(p-1)).toFixed(5)),y*=_*G*v*d,t.tech.ai_core&&i.citadel>0&&(r.p.Cement[F("interstellar_citadel_effect_bd")]=100*(m-1)+"%"),r.p.Cement[F("hunger")]=100*(G-1)+"%",Vi("Cement",y*f)}let U=Lc("metal"),W=0,Q=0,Z=0;if(t.city.smelter&&(t.city.smelter.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation)){let e=t.city.smelter.count;i.stellar_forge&&t.tech.star_forge&&t.tech.star_forge>=2&&(e+=2*i.stellar_forge),i.hell_forge&&(e+=3*i.hell_forge),i.ore_refinery&&(e+=i.ore_refinery*(t.tech.isolation?12:4)),t.tech.m_smelting&&t.space.hell_smelter&&(e+=2*t.space.hell_smelter.count),(t.race.cataclysm||t.race.orbit_decayed)&&t.space.geothermal&&(e+=t.space.geothermal.on),t.city.smelter.cap=e,t.tech.star_forge>=2?(t.city.smelter.StarCap=2*i.stellar_forge,t.city.smelter.Star=t.city.smelter.StarCap):t.city.smelter.StarCap=0,t.race.forge&&(t.city.smelter.Wood=0,t.city.smelter.Coal=0,t.city.smelter.Oil=t.city.smelter.cap-t.city.smelter.Star-t.city.smelter.Inferno),!t.race.kindling_kindred&&!t.race.smoldering||t.race.evil||(t.city.smelter.Wood=0);let a=t.race.kindling_kindred||t.race.smoldering?.15:.25,s=0;if(["Wood","Coal","Oil","Star","Inferno"].forEach((function(e){s+t.city.smelter[e]>t.city.smelter.cap&&(t.city.smelter[e]=t.city.smelter.cap-s),s+=t.city.smelter[e]})),t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium>t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno){let e=t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,a=t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium-e;t.city.smelter.Iron-=a,t.city.smelter.Iron<0&&(a=t.city.smelter.Iron,t.city.smelter.Iron=0,t.city.smelter.Iridium+=a,t.city.smelter.Iridium<0&&(a=t.city.smelter.Iridium,t.city.smelter.Iridium=0),t.city.smelter.Steel+=a,t.city.smelter.Steel<0&&(t.city.smelter.Steel=0))}else if(t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium=2);t.resource.Iridium.display&&e||t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen||t.city.smelter.Iron++}if(t.city.smelter.Star>t.city.smelter.StarCap){let e=t.city.smelter.Star-t.city.smelter.StarCap;t.city.smelter.Star=t.city.smelter.StarCap,t.city.smelter.Oil+=e}let c=t.race.forge?0:t.city.smelter.Wood*(!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species?3:1),o=t.race.forge?0:t.city.smelter.Coal*a,n=t.race.forge?0:.35*t.city.smelter.Oil;W=t.city.smelter.Iron;let l=t.city.smelter.Steel;Z=t.city.smelter.Iridium;let u=t.race.forge?t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil:t.city.smelter.Oil;Q=t.city.smelter.Star;let _=t.city.smelter.Inferno;for(t.race.steelen&&(W+=l,l=0);W+l+Z>t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno;)l>0?l--:W>0?W--:Z--;let p=t.race.soul_eater&&"wendigo"!==t.race.species?"Food":t.race.evil?"Furs":"Lumber";for(;c*f>t.resource[p].amount&&c>0;)c-=!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species?3:1,l>0?l--:W>0?W--:Z--;for(;o*f>t.resource.Coal.amount&&o>0;)o-=a,l>0?l--:W>0?W--:Z--;for(;n*f>t.resource.Oil.amount&&n>0;)n-=.35,u--,l>0?l--:W>0?W--:Z--;if(_>0){let e={Oil:35,Coal:50,Infernite:.5};Object.keys(e).forEach((function(a){for(;e[a]*_*f>t.resource[a].amount&&_>0;)_--,l>0?l--:W>0?W--:Z--})),n+=e.Oil*_,o+=e.Coal*_;let a=e.Infernite*_;r.p.consume.Infernite[F("city_smelter")]=-a,Vi("Infernite",-a*f)}W*=t.tech.smelting>=3?1.2:1,Z>0&&(Z=1+.05*Z);let h=N("dirty_jobs",2);h&&(W*=1+h/100,Z*=1+h/100),t.tech.smelting>=7&&(W*=1.25,Z*=1.25),u>0&&(W*=1+u/200,Z*=1+u/200),_>0&&(W*=1+_/125,Z*=1+_/125),Q>0&&(W*=1+Q/500,Z*=1+Q/75),t.race.pyrophobia&&(W*=1-ui.pyrophobia.vars()[0]/100,Z*=1-ui.pyrophobia.vars()[0]/100);let m=Pi("salamander");if(m>0&&(W*=1.2*m,Z*=1.2*m),Z<1&&(Z=1),t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?r.p.consume.Food[F("city_smelter")]=-c:r.p.consume.Furs[F("city_smelter")]=-c:r.p.consume.Lumber[F("city_smelter")]=-c,r.p.consume.Coal[F("city_smelter")]=-o,r.p.consume.Oil[F("city_smelter")]=-n,Vi(p,-c*f),Vi("Coal",-o*f),Vi("Oil",-n*f),o>0&&t.tech.uranium&&t.tech.uranium>=3){let e=o;t.city.geology.Uranium&&(e*=t.city.geology.Uranium+1);let a=e/65/d*Pe("psychic_boost","Uranium");r.p.Uranium[F("city_coal_ash")]=r.p.Uranium[F("city_coal_ash")]?r.p.Uranium[F("city_coal_ash")]+a:a,Vi("Uranium",e*f/65)}if(t.resource.Steel.display){let e=2*l,a=.25*l;for(;e*f>t.resource.Iron.amount&&e>0||a*f>t.resource.Coal.amount&&a>0;)e-=2,a-=.25,l--;r.p.consume.Coal[F("city_smelter")]-=a,r.p.consume.Iron[F("city_smelter")]=-e,Vi("Iron",-e*f),Vi("Coal",-a*f);let s=1;for(t.stats.achieve.steelen&&t.stats.achieve.steelen.l>=1&&(s*=1+2*t.stats.achieve.steelen.l/100),t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=2&&(s*=1.1),b=4;b<=6;b++)t.tech.smelting>=b&&(s*=1.2);t.tech.smelting>=7&&(s*=1.25),u>0&&(l*=1+u/200),_>0&&(l*=1+_/125),Q&&(l*=1+Q/500),h&&(l*=1+h/100),m>0&&(l*=1.2*m);let i=l*s*Pe("psychic_boost","Steel");t.race.pyrophobia&&(i*=1-ui.pyrophobia.vars()[0]/100);let c=i;if(c*=G*d*U.mult,r.p.Steel[F("city_smelter")]=i+"v",r.p.Steel[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%",r.p.Steel[F("hunger")]=100*(G-1)+"%",Vi("Steel",c*f),t.tech.titanium&&t.tech.titanium>=1){let e=i*G*Pe("psychic_boost","Titanium");Q>0&&(c*=1+Q/50),t.city.geology.Titanium&&(c*=t.city.geology.Titanium+1),"oceanic"===t.city.biome&&(c*=ji.oceanic.vars()[1]),c*=U.mult;let a=t.tech.titanium>=3?10:25;Vi("Titanium",c*f/a),r.p.Titanium[F("resource_Steel_name")]=e/a+"v"}}}let V=t.race.truepath?"space":"interstellar";if(t[V].g_factory&&t[V].g_factory.count>0){let e=t.race.truepath?c.g_factory:o.g_factory,a=t[V].g_factory.on,s=a>0?e/a:0,n=a;(t.race.kindling_kindred||t.race.smoldering)&&(t[V].g_factory.Lumber=0),["Oil","Coal","Lumber"].forEach((function(e){n-=t[V].g_factory[e],n<0&&(t[V].g_factory[e]+=n,n=0)}));let l=t[V].g_factory.Lumber+t[V].g_factory.Coal+t[V].g_factory.Oil;if(l>0){let e=350*t[V].g_factory.Lumber*s,a=25*t[V].g_factory.Coal*s,c=15*t[V].g_factory.Oil*s;for(;e*f>t.resource.Lumber.amount&&e>0;)e-=350*s,l--;for(;a*f>t.resource.Coal.amount&&a>0;)a-=25*s,l--;for(;c*f>t.resource.Oil.amount&&c>0;)c-=15*s,l--;l*=Pe("g_factory")*Pe("psychic_boost","Graphene"),r.p.consume.Lumber[F("interstellar_g_factory_bd")]=-e,r.p.consume.Coal[F("interstellar_g_factory_bd")]=-a,r.p.consume.Oil[F("interstellar_g_factory_bd")]=-c,Vi("Lumber",-e*f),Vi("Coal",-a*f),Vi("Oil",-c*f),"corpocracy"===t.civic.govern.type&&(l*=1+ae.corpocracy()[4]/100),"socialist"===t.civic.govern.type&&(l*=1+ae.socialist()[1]/100);let o=1;t.tech.ai_core>=3&&(o+=+(u/5).toFixed(1)/100*i.citadel);let n=t.race.truepath?ht("spc_titan"):1,p=l*o*_*G*d*n*s;r.p.Graphene[F("interstellar_g_factory_bd")]=l+"v",t.tech.isolation&&l>0&&(p*=S,S>1&&(r.p.Graphene[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%")),l>0&&(r.p.Graphene[`ᄂ${F("space_syndicate")}`]=-100*(1-n)+"%",r.p.Graphene[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),t.race.discharge&&t.race.discharge>0&&(p*=.5,r.p.Graphene[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),i.citadel>0&&(r.p.Graphene[F("interstellar_citadel_effect_bd")]=100*(o-1)+"%"),r.p.Graphene[F("hunger")]=100*(G-1)+"%",Vi("Graphene",p*f)}else r.p.Graphene=0}if(t.galaxy.vitreloy_plant&&i.vitreloy_plant>0){let e=5e4*i.vitreloy_plant,a=2.5*i.vitreloy_plant,s=100*i.vitreloy_plant,c=i.vitreloy_plant;for(;e*f>t.resource.Money.amount&&e>0;)e-=350,c--;for(;a*f>t.resource.Bolognium.amount&&a>0;)a-=25,c--;for(;s*f>t.resource.Stanene.amount&&s>0;)s-=15,c--;if(c>0){c*=Pe("vitreloy_plant")*Pe("psychic_boost","Vitreloy"),r.p.consume.Money[F("galaxy_vitreloy_plant_bd")]=-e,r.p.consume.Bolognium[F("galaxy_vitreloy_plant_bd")]=-a,r.p.consume.Stanene[F("galaxy_vitreloy_plant_bd")]=-s,Vi("Money",-e*f),Vi("Bolognium",-a*f),Vi("Stanene",-s*f);let i=Et("gxy_alien1");r.p.Vitreloy[F("galaxy_vitreloy_plant_bd")]=c+"v",t.race.discharge&&t.race.discharge>0&&(c*=.5,r.p.Vitreloy[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),r.p.Vitreloy[F("hunger")]=100*(G-1)+"%",c>0&&(r.p.Vitreloy[`ᄂ${F("galaxy_piracy")}+0`]=-100*(1-i)+"%",r.p.Vitreloy[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%"),Vi("Vitreloy",c*G*d*i*f*_)}}if(i.s_gate&&t.galaxy.raider&&n.raider>0){let e=.05*n.raider*Pe("psychic_boost","Vitreloy"),t=Et("gxy_chthonian"),a=e*d*t*G*_;r.p.Vitreloy[F("galaxy_raider")]=e+"v",e>0&&(r.p.Vitreloy[`ᄂ${F("galaxy_piracy")}+1`]=-100*(1-t)+"%",r.p.Vitreloy[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Vitreloy",a*f)}if(!t.tech.isolation&&t.space.lander&&t.space.crashed_ship&&100===t.space.crashed_ship.count){let e=ht("spc_triton"),a=c.lander*Pe("lander"),s=a*d*e*G;r.p.Cipher[F("space_lander_title")]=a+"v",r.p.Cipher[`ᄂ${F("space_syndicate")}+0`]=-100*(1-e)+"%",r.p.Cipher[`ᄂ${F("hunger")}`]=100*(G-1)+"%",Vi("Cipher",s*f),t.resource.Cipher.display&&t.tech.outer&&2===t.tech.outer&&(t.tech.outer=3,ms())}if(!t.tech.isolation&&t.space.digsite&&100===t.space.digsite.count){t.tech.dig_control||(t.tech.dig_control=1,ms());let e=ht("spc_eris"),a=c.shock_trooper*Pe("shock_trooper"),s=c.tank*Pe("tank");c.shock_trooper&&(r.p.Cipher[F("space_shock_trooper_title")]=a+"v",r.p.Cipher[`ᄂ${F("space_syndicate")}+1`]=-100*(1-e)+"%"),c.tank&&(r.p.Cipher[F("space_tank_title")]=s+"v",r.p.Cipher[`ᄂ${F("space_syndicate")}+2`]=-100*(1-e)+"%"),Vi("Cipher",(a+s)*d*e*f)}if(t.tech.isolation&&t.tauceti.alien_outpost&&i.alien_outpost){let e=Pe("alien_outpost"),t=1+.5*(c.colony||0);r.p.Cipher[F("tech_alien_outpost")]=e+"v",e>0&&(r.p.Cipher[`ᄂ${F("tau_home_colony")}`]=100*(t-1)+"%"),Vi("Cipher",e*d*t*f)}let J={};if(t.tauceti.ore_refinery&&t.tauceti.mining_ship&&t.tech.tau_roid&&t.tech.tau_roid>=4){if(t.tauceti.ore_refinery.max=1e3*t.tauceti.ore_refinery.count,t.tauceti.ore_refinery.fill>0){let e=i.ore_refinery*Pe("ore_refinery");e>t.tauceti.ore_refinery.fill&&(e=t.tauceti.ore_refinery.fill),t.tauceti.ore_refinery.fill-=e*f;let a=t.tech.tau_roid>=5?.6:.64,r=t.tech.tau_roid>=5?.35:.36;J.iron=e*a*(100-t.tauceti.mining_ship.common)/100*Pe("mining_ship_ore","iron")*Pe("psychic_boost","Iron"),J.aluminium=e*a*t.tauceti.mining_ship.common/100*Pe("mining_ship_ore","aluminium")*Pe("psychic_boost","Aluminium"),J.iridium=e*r*(100-t.tauceti.mining_ship.uncommon)/100*Pe("mining_ship_ore","iridium")*Pe("psychic_boost","Iridium"),J.neutronium=e*r*t.tauceti.mining_ship.uncommon/100*Pe("mining_ship_ore","neutronium")*Pe("psychic_boost","Neutronium"),t.tech.tau_roid>=5&&(J.orichalcum=.05*e*(100-t.tauceti.mining_ship.rare)/10*Pe("mining_ship_ore","orichalcum")*Pe("psychic_boost","Orichalcum"),J.elerium=.05*e*t.tauceti.mining_ship.rare/10*Pe("mining_ship_ore","elerium")*Pe("psychic_boost","Elerium"))}let e=c.mining_ship*Pe("mining_ship");t.tauceti.ore_refinery.fill+=e*f,t.tauceti.ore_refinery.fill>t.tauceti.ore_refinery.max&&(t.tauceti.ore_refinery.fill=t.tauceti.ore_refinery.max)}if(t.race.cataclysm||t.race.orbit_decayed){if(t.tech.mars&&c.biodome&&!t.race.kindling_kindred&&!t.race.smoldering){let e=c.biodome*na(t.civic.colonist.workers,"colonist")*Pe("biodome","lumber")*Pe("psychic_boost","Lumber");r.p.Lumber[Qr.space.spc_red.biodome.title()]=e+"v",e>0&&(r.p.Lumber[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),r.p.Lumber[F("hunger")]=100*(G-1)+"%",Vi("Lumber",e*G*d*f*_)}}else if(t.race.soul_eater&&"wendigo"!==t.race.species&&t.race.evil){let e=t.tech.military?t.tech.military>=5?t.tech.military-1:t.tech.military:1,a=na(t.civic.hunter.workers,"hunter");a*=pi(a,"hunting"),t.race.servants&&(a+=la(t.race.servants.jobs.hunter)),a*=e/2,t.race.high_pop&&(a=Me(a)),a*=Pe("psychic_boost","Lumber");let s=ke(qe(),"hunting")/3;s*=Pe("psychic_boost","Lumber"),r.p.Lumber[F(t.race.unfathomable?"job_raider":"job_hunter")]=a+"v",r.p.Lumber[F("soldiers")]=s+"v",r.p.Lumber[F("hunger")]=100*(G-1)+"%",Vi("Lumber",a*G*d*f),Vi("Lumber",s*G*d*f)}else if(t.race.evil){let e=na(t.civic.lumberjack.workers,"lumberjack");e*=pi(e,"lumberjack"),t.race.servants&&(e+=t.race.servants.jobs.lumberjack),e*=Pe("psychic_boost","Lumber");let a=1;t.city.graveyard&&(a+=.08*t.city.graveyard.count);let s=ke(qe(),"hunting")/5;if(s*=Pe("psychic_boost","Lumber"),r.p.Lumber[F("job_reclaimer")]=e+"v",e>0&&(r.p.Lumber[`ᄂ${F("city_graveyard")}`]=100*(a-1)+"%",r.p.Lumber[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),r.p.Lumber[F("soldiers")]=s+"v",s>0&&(r.p.Lumber[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),t.race.forager){let e=1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.25;r.p.Lumber[F("job_forager")]=s+"v",s>0&&(r.p.Lumber[`ᄂ${F("quarantine")}+2`]=100*(h-1)+"%"),Vi("Lumber",s*G*d*h*f)}r.p.Lumber[F("hunger")]=100*(G-1)+"%",Vi("Lumber",e*G*a*d*h*f),Vi("Lumber",s*G*d*h*f)}else{let e=na(t.civic.lumberjack.workers,"lumberjack");e*=pi(e,"lumberjack"),t.race.servants&&(e+=t.race.servants.jobs.lumberjack),e*="forest"===t.city.biome?ji.forest.vars()[0]:1,e*="savanna"===t.city.biome?ji.savanna.vars()[2]:1,e*="desert"===t.city.biome?ji.desert.vars()[2]:1,e*="swamp"===t.city.biome?ji.swamp.vars()[2]:1,e*="taiga"===t.city.biome?ji.taiga.vars()[0]:1,e*=t.civic.lumberjack.impact,t.race.living_tool?e*=ui.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.25*t.tech.science:0)+1:e*=1+(t.tech.axe&&t.tech.axe>1?.35*(t.tech.axe-1):0),e*=Pe("psychic_boost","Lumber");let a=1;if(t.city.sawmill){let e=t.tech.saw>=2?.08:.05;a*=t.city.sawmill.count*e+1}let s=1,c=1;t.city.powered&&t.city.sawmill&&i.sawmill&&(s+=.04*i.sawmill,c+=.04);let o=1;t.city.lumber_yard&&(o+=.02*t.city.lumber_yard.count),r.p.Lumber[F("job_lumberjack")]=e+"v",e>0&&(r.p.Lumber[`ᄂ${F("city_lumber_yard")}`]=100*(o-1)+"%",r.p.Lumber[`ᄂ${F("city_sawmill")}`]=100*(a-1)+"%",r.p.Lumber[`ᄂ${F("power")}`]=100*(s-1)+"%",r.p.Lumber[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),t.race.discharge&&t.race.discharge>0&&i.sawmill>0&&(s=.5*(s-1)+1,c=.5*(c-1)+1,r.p.Lumber[`ᄂ${F("evo_challenge_discharge")}`]="-50%");let n=e*a*o;if(t.city.sawmill&&(t.city.sawmill.psaw=+(n*G*h*d*(c-1)).toFixed(5)),n*=s*G*h*d,t.race.forager){let e=1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.25*Pe("psychic_boost","Lumber");r.p.Lumber[F("job_forager")]=s+"v",Vi("Lumber",s*G*d*f)}r.p.Lumber[F("hunger")]=100*(G-1)+"%",Vi("Lumber",n*f)}let Y=t.city.metal_refinery?6*t.city.metal_refinery.count:0;if(Y*=h,t.race.sappy){if(t.tech.mining&&t.resource[t.race.species].amount>0){let e=t.resource[t.race.species].amount*ui.sappy.vars()[0]*Pe("psychic_boost","Stone");t.race.high_pop&&(e=Me(e));let a=Pi("cacti");if(a>0&&(e*=1+.32*a),r.p.Stone[Ac("name")]=e+"v",t.city.hasOwnProperty("basic_housing")){let a=.025*t.city.basic_housing.count;e*=1+a,r.p.Stone[`ᄂ${Is("small")}`]=100*a+"%"}let s=0;t.civic.hasOwnProperty("garrison")&&(s=t.civic.garrison.workers*ui.sappy.vars()[0],t.race.high_pop&&(s=Me(s)),r.p.Stone[F("soldiers")]=s+"v");let i=(e+s)*G*d;r.p.Stone[F("hunger")]=100*(G-1)+"%",Vi("Stone",i*f)}}else{let e=na(t.civic.quarry_worker.workers,"quarry_worker");e*=pi(e,"miner");let a=Pi("cacti");a>0&&(e*=1+.32*a),t.race.servants&&(e+=t.race.servants.jobs.quarry_worker),e*=t.civic.quarry_worker.impact*Pe("psychic_boost","Stone"),t.race.living_tool?e*=ui.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.06*t.tech.science:0)+1:e*=1+(t.tech.hammer&&t.tech.hammer>0?.4*t.tech.hammer:0),"desert"===t.city.biome&&(e*=ji.desert.vars()[0]),"swamp"===t.city.biome&&(e*=ji.swamp.vars()[3]),t.tech.explosives&&t.tech.explosives>=2&&(e*=t.tech.explosives>=3?1.75:1.5);let s=0;t.race.smoldering&&t.resource.Chrysotile.display&&t.city.rock_quarry&&(s=e*Pe("psychic_boost","Chrysotile"),e*=(100-t.city.rock_quarry.asbestos)/100,s*=t.city.rock_quarry.asbestos/100);let o=1,n=1,l=1;t.city.rock_quarry&&(t.city.rock_quarry.on&&(o+=.04*i.rock_quarry,n+=.04),l+=.02*t.city.rock_quarry.count),r.p.Stone[F("workers")]=e+"v",e>0&&(r.p.Stone[`ᄂ${F("city_rock_quarry")}`]=100*(l-1)+"%",r.p.Stone[`ᄂ${F("power")}`]=100*(o-1)+"%",r.p.Stone[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),t.race.smoldering&&t.resource.Chrysotile.display&&(r.p.Chrysotile[F("workers")]=s+"v",s>0&&(r.p.Chrysotile[`ᄂ${F("city_rock_quarry")}`]=100*(l-1)+"%",r.p.Chrysotile[`ᄂ${F("power")}`]=100*(o-1)+"%")),t.race.discharge&&t.race.discharge>0&&i.rock_quarry>0&&(o=.5*(o-1)+1,n=.5*(n-1)+1,r.p.Stone[`ᄂ${F("evo_challenge_discharge")}`]="-50%",t.race.smoldering&&t.resource.Chrysotile.display&&(r.p.Chrysotile[`ᄂ${F("evo_challenge_discharge")}`]="-50%")),(t.race.cataclysm||t.race.orbit_decayed)&&(t.tech.mars&&c.red_mine&&(e=c.red_mine*na(t.civic.colonist.workers,"colonist")*Pe("red_mine","stone")*Pe("psychic_boost","Stone"),r.p.Stone[F("space_red_mine_title")]=e+"v",e>0&&(r.p.Stone[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),t.race.smoldering&&t.resource.Chrysotile.display&&(s=c.red_mine*na(t.civic.colonist.workers,"colonist")*Pe("red_mine","asbestos")*Pe("psychic_boost","Chrysotile"),r.p.Chrysotile[F("space_red_mine_title")]=s+"v",s>0&&(r.p.Chrysotile[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),s*=_),e*=_),o=1,n=1,l=1);let u=e*l;if(t.city.rock_quarry&&(t.city.rock_quarry.cnvay=+(u*G*h*d*(n-1)).toFixed(5)),u*=o*G*h*d,t.race.forager&&t.resource.Stone.display){let e=1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.22*Pe("psychic_boost","Stone");r.p.Stone[F("job_forager")]=s+"v",s>0&&(r.p.Stone[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),Vi("Stone",s*G*d*h*f)}if(r.p.Stone[F("hunger")]=100*(G-1)+"%",Vi("Stone",u*f),t.race.smoldering&&t.resource.Chrysotile.display){let e=s*o*l;e*=G*d,r.p.Chrysotile[F("hunger")]=100*(G-1)+"%",Vi("Chrysotile",e*f)}if(t.city.metal_refinery&&t.city.metal_refinery.count>0||t.race.cataclysm||t.race.orbit_decayed){let a=e*l*(t.race.cataclysm?.16:.08);t.city.geology.Aluminium&&(a*=t.city.geology.Aluminium+1),a*=Pe("psychic_boost","Aluminium");let s=a*U.mult*G*h*d;if(t.city.metal_refinery.cnvay=+(s*(n-1)).toFixed(5),t.city.rock_quarry.almcvy=t.city.metal_refinery.cnvay,s*=o,t.tech.alumina>=2){Y+=6*i.metal_refinery*h;let e=6*h/100;t.city.metal_refinery.pwr=+(s*e).toFixed(5)}s*=1+Y/100,r.p.Aluminium[`${t.race.cataclysm||t.race.orbit_decayed?F("space_red_mine_title"):F("workers")}+1`]=a+"v",a>0&&(r.p.Aluminium[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),r.p.Aluminium[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%",r.p.Aluminium[F("hunger")]=100*(G-1)+"%",Vi("Aluminium",s*f)}}if(t.resource.Water.display){if(c.water_freighter){let e=ht("spc_enceladus"),t=Pe("water_freighter")*c.water_freighter*Pe("psychic_boost","Water"),a=t*G*d*e*_;r.p.Water[F("space_water_freighter_title")]=t+"v",t>0&&(r.p.Water[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Water[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Water[`ᄂ${F("hunger")}`]=100*(G-1)+"%"),Vi("Water",a*f)}if(t.tech.isolation&&t.tauceti.tau_farm&&i.tau_farm){let e=1+.5*(c.colony||0),t=Pe("tau_farm","water")*i.tau_farm*Pe("psychic_boost","Water"),a=t*d*e;r.p.Water[F("tau_home_tau_farm")]=t+"v",t>0&&(r.p.Water[`ᄂ${F("tau_home_colony")}`]=100*(e-1)+"%"),Vi("Water",a*f)}}if(t.resource.Mana.display){if(t.race.casting&&["farmer","miner","lumberjack","science","factory","army","hunting","crafting"].forEach((function(e){if(t.race.casting[e]&&t.race.casting[e]>0){let a=Ys(t.race.casting[e]);r.p.consume.Mana[F(`modal_pylon_spell_${e}`)]=-a;let s=t.resource.Mana.diff>0?t.resource.Mana.diff*f:0;Vi("Mana",-a*f,!1,s)||t.race.casting[e]--}else delete r.p.consume.Mana[F(`modal_pylon_spell_${e}`)]})),t.city.pylon||t.space.pylon||t.tauceti.pylon){let e=0,a="city_pylon";(t.race.cataclysm||t.race.orbit_decayed)&&t.space.pylon?(e=.005*t.space.pylon.count,a="space_red_pylon"):t.tech.isolation&&t.tauceti.pylon?(e=.0125*t.tauceti.pylon.count,a="tau_home_pylon"):t.city.pylon&&(e=.01*t.city.pylon.count),e*=nc("magic");let s=e*G*d;if(r.p.Mana[F(a)]=e+"v",t.tech.nexus){let e=5*t.tech.nexus;s*=1+e/100,r.p.Mana[`ᄂ${F("arpa_projects_nexus_title")}`]=e+"%"}Vi("Mana",s*f)}if(t.tech.cleric&&t.civic.priest.display){let e=.0025*na(t.civic.priest.workers,"priest");t.race.high_pop&&(e=Me(e)),e*=nc("magic");let a=e*G*d;r.p.Mana[F("job_priest")]=e+"v",Vi("Mana",a*f)}if("magic"===t.race.universe&&t.civic.scientist.display){let e=.025*na(t.civic.scientist.workers,"scientist");t.race.high_pop&&(e=Me(e)),e*=nc("magic");let a=e*G*d;r.p.Mana[F("job_wizard")]=e+"v","magocracy"===t.civic.govern.type&&(a*=1+ae.magocracy()[0]/100,r.p.Mana[`ᄂ${F("govern_magocracy")}`]=ae.magocracy()[0]+"%"),Vi("Mana",a*f)}if("magic"===t.race.universe&&t.tech.syphon){let e=t.tech.syphon/3;e*=nc("magic");let a=e*G*d;r.p.Mana[F("arpa_syphon_title")]=e+"v",Vi("Mana",a*f)}r.p.Mana[F("hunger")]=100*(G-1)+"%"}if(t.resource.Crystal.display){let e=na(t.civic.crystal_miner.workers,"crystal_miner");if(e*=pi(e,"miner"),t.race.servants&&(e+=t.race.servants.jobs.crystal_miner),e*=t.civic.crystal_miner.impact*Pe("psychic_boost","Crystal"),r.p.Crystal[F("job_crystal_miner")]=e+"v","magocracy"===t.civic.govern.type){let t=ae.magocracy()[1];e*=1+t/100,r.p.Crystal[`ᄂ${F("govern_magocracy")}`]=`${t}%`}let a=e*G*d;r.p.Crystal[F("hunger")]=100*(G-1)+"%",Vi("Crystal",a*f)}if(t.resource.Copper.display||t.resource.Iron.display){let e=na(t.civic.miner.workers,"miner");e*=pi(e,"miner"),e*=t.civic.miner.impact,t.race.tough&&(e*=1+ui.tough.vars()[0]/100);let a=Pi("ogre");a>0&&(e*=1+ui.tough.vars(1)[0]/100*a),t.race.industrious&&(e*=1+ui.industrious.vars()[0]*t.race.industrious/100),t.city.ptrait.includes("dense")&&(e*=Si.dense.vars()[0]),t.city.ptrait.includes("permafrost")&&(e*=Si.permafrost.vars()[0]),t.race.living_tool||(e*=1+(t.tech.pickaxe&&t.tech.pickaxe>0?.15*t.tech.pickaxe:0)),t.tech.explosives&&t.tech.explosives>=2&&(e*=t.tech.explosives>=3?1.4:1.25);let s=1,o=1;if(t.city.mine.on&&(s+=.05*i.mine,o+=1.05),t.resource.Copper.display){let a=1/7;t.tech.copper&&(a*=1.2);let c=e*a*Pe("psychic_boost","Copper");t.city.geology.Copper&&(c*=t.city.geology.Copper+1),"volcanic"===t.city.biome?c*=ji.volcanic.vars()[1]:"ashland"===t.city.biome&&(c*=ji.ashland.vars()[2]);let n=s,l=o;r.p.Copper[F("job_miner")]=c+"v",c>0&&(r.p.Copper[`ᄂ${F("power")}`]=100*(n-1)+"%",r.p.Copper[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%",t.race.discharge&&t.race.discharge>0&&i.mine>0&&(n=.5*(n-1)+1,l=.5*(l-1)+1,r.p.Copper[`ᄂ${F("evo_challenge_discharge")}`]="-50%"));let u=c*U.mult;if(t.city.mine.cpow=+(u*G*h*d*(l-1)).toFixed(5),u*=n*G*h*d,Vi("Copper",u*f),t.race.forager&&t.tech.dowsing){let e=t.tech.dowsing>=2?5:1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.025*Pe("psychic_boost","Copper");t.city.geology.Copper&&(s*=t.city.geology.Copper+1),"volcanic"===t.city.biome?s*=ji.volcanic.vars()[1]:"ashland"===t.city.biome&&(s*=ji.ashland.vars()[2]),r.p.Copper[F("job_forager")]=s+"v",s>0&&(r.p.Copper[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),Vi("Copper",s*G*d*h*f)}}if(t.resource.Iron.display){let a=e*(1/4)*Pe("psychic_boost","Iron");t.race.iron_allergy&&(a*=1-ui.iron_allergy.vars()[0]/100);let o=1+.1*W;t.city.geology.Iron&&(a*=t.city.geology.Iron+1),"volcanic"===t.city.biome?a*=ji.volcanic.vars()[2]:"ashland"===t.city.biome&&(a*=ji.ashland.vars()[2]);let n=0,l=ht("spc_belt");c.iron_ship&&(n=c.iron_ship*Pe("iron_ship")*Pe("psychic_boost","Iron"),n*=l);let u=s,p=s;r.p.Iron[F("job_miner")]=a+"v",a>0&&(r.p.Iron[`ᄂ${F("power")}`]=100*(u-1)+"%",t.race.discharge&&t.race.discharge>0&&i.mine>0&&(u=.5*(u-1)+1,p=.5*(p-1)+1,r.p.Iron[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),r.p.Iron[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%");let g=0,v=0;if(t.tech.isolation&&t.race.lone_survivor){{let e=na(t.civic.pit_miner.workers,"pit_miner");e*=pi(e,"miner");let a=1+.5*(c.colony||0),s=e*Pe("psychic_boost","Iron");s*=Pe("mining_pit","iron"),g=s*a,r.p.Iron[F("job_pit_miner")]=s+"v",s>0&&(r.p.Iron[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%")}if(t.tauceti.hasOwnProperty("womling_mine")&&t.tauceti.hasOwnProperty("overseer")){let e=t.tauceti.overseer.prod/100,a=t.tauceti.womling_mine.miners*Pe("womling_mine","iron")*Pe("psychic_boost","Iron");r.p.Iron[F("tau_red_womlings")]=a+"v",v=a*e,a>0&&(r.p.Iron[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-e)+"%")}}let y=J.iron?J.iron*S:0,b=(a*u*h+n*m*_+y+g+v)*o*U.mult;if(t.city.mine.ipow=+(a*h*G*d*(p-1)).toFixed(5),b*=G*d,r.p.Iron[F("job_space_miner")]=n+"v",n>0&&(r.p.Iron[`ᄂ${F("space_syndicate")}`]=-100*(1-l)+"%",r.p.Iron[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Iron[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),J.iron&&J.iron>0&&(r.p.Iron[F("tau_roid_mining_ship")]=J.iron+"v",S>1&&(r.p.Iron[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%")),r.p.Iron[F("city_smelter")]=100*(o-1)+"%",r.p.Iron[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%",t.race.forager&&t.tech.dowsing){let e=t.tech.dowsing>=2?5:1,a=na(t.civic.forager.workers,"forager");t.race.servants&&(a+=t.race.servants.jobs.forager);let s=a*e*.035*Pe("psychic_boost","Iron");t.city.geology.Iron&&(s*=t.city.geology.Iron+1),"volcanic"===t.city.biome?s*=ji.volcanic.vars()[2]:"ashland"===t.city.biome&&(s*=ji.ashland.vars()[2]),r.p.Iron[F("job_forager")]=s+"v",Vi("Iron",s*G*d*f)}if(r.p.Iron[F("hunger")]=100*(G-1)+"%",Vi("Iron",b*f),t.tech.titanium&&t.tech.titanium>=2){let e=(c.iron_ship?Me(na(t.civic.miner.workers,"miner"))/4+c.iron_ship/2:na(t.civic.miner.workers,"miner")/4)*W*.1;b=e*d,Q>0&&(b*=1+Q/50),t.city.geology.Titanium&&(b*=t.city.geology.Titanium+1),"oceanic"===t.city.biome&&(b*=ji.oceanic.vars()[0]),b*=U.mult*Pe("psychic_boost","Titanium");let a=t.tech.titanium>=3?10:25;Vi("Titanium",b*f/a),r.p.Titanium[F("resource_Iron_name")]=e/a+"v"}}if(t.race.sappy){if(t.city.metal_refinery&&t.city.metal_refinery.count>0||t.race.cataclysm||t.race.orbit_decayed){let a=0;t.race.cataclysm||t.race.orbit_decayed?t.tech.mars&&c.red_mine&&(a=c.red_mine*na(t.civic.colonist.workers,"colonist")*Pe("red_mine","aluminium")):a=e*s*.088,t.city.geology.Aluminium&&(a*=t.city.geology.Aluminium+1),a*=Pe("psychic_boost","Aluminium");let o=a*U.mult*G*d;t.tech.alumina>=2&&(Y+=6*i.metal_refinery),o*=1+Y/100,r.p.Aluminium[`${t.race.cataclysm||t.race.orbit_decayed?F("space_red_mine_title"):F("job_miner")}+2`]=a+"v",(t.race.cataclysm||t.race.orbit_decayed&&a>0&&_>0)&&(o*=_,r.p.Aluminium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),r.p.Aluminium[F("city_shrine")]=100*(U.mult-1)+"%",r.p.Aluminium[F("hunger")]=100*(G-1)+"%",Vi("Aluminium",o*f)}if(t.race.smoldering&&t.resource.Chrysotile.display){let a=e/2*Pe("psychic_boost","Chrysotile"),c=s;r.p.Chrysotile[F("job_miner")]=a+"v",a>0&&(r.p.Chrysotile[`ᄂ${F("power")}`]=100*(c-1)+"%",t.race.discharge&&t.race.discharge>0&&i.mine>0&&(c=.5*(c-1)+1,r.p.Chrysotile[`ᄂ${F("evo_challenge_discharge")}`]="-50%"));let o=a*c;o*=G*d,r.p.Chrysotile[F("hunger")]=100*(G-1)+"%",Vi("Chrysotile",o*f)}}}if(t.interstellar.mining_droid&&z.alum>0){let e=2.75*z.alum*Pe("psychic_boost","Aluminium"),t=e*U.mult*d*_;t*=1+Y/100,r.p.Aluminium[F("interstellar_mining_droid_title")]=e+"v",e>0&&(r.p.Aluminium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Aluminium",t*f)}if(t.resource.Aluminium.display&&t.space.titan_mine){let e=ht("spc_titan"),a=i.ai_colonist?na(t.civic.titan_colonist.workers,"titan_colonist")+la(i.ai_colonist):na(t.civic.titan_colonist.workers,"titan_colonist"),s=Pe("titan_mine","aluminium")*c.titan_mine*a*Pe("psychic_boost","Aluminium"),o=s*U.mult*d*m*e*_;o*=1+Y/100,r.p.Aluminium[`${F("city_mine")}+0`]=+s.toFixed(3)+"v",s>0&&(r.p.Aluminium[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Aluminium[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%",r.p.Aluminium[`ᄂ${F("quarantine")}+2`]=100*(m-1)+"%"),Vi("Aluminium",o*f)}if(t.resource.Aluminium.display&&J.aluminium&&J.aluminium>0){let e=J.aluminium*U.mult*d*S;e*=1+Y/100,r.p.Aluminium[F("tau_roid_mining_ship")]=J.aluminium+"v",S>1&&(r.p.Aluminium[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Aluminium",e*f)}if(Y>0&&(r.p.Aluminium[F("city_metal_refinery")]=Y+"%",r.p.Aluminium[`ᄂ${F("quarantine")}+1`]=100*(h-1)+"%"),c.red_mine&&c.red_mine>0){let e=ht("spc_red"),a=c.red_mine*na(t.civic.colonist.workers,"colonist")*Pe("red_mine","copper").f;a*=Pe("psychic_boost","Copper"),r.p.Copper[F("space_red_mine_desc_bd",[Xt().red])]=a+"v",a>0&&(r.p.Copper[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Copper[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Copper[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Copper",a*U.mult*f*d*m*G*e*_);let s=c.red_mine*na(t.civic.colonist.workers,"colonist")*G*Pe("red_mine","titanium").f;s*=Pe("psychic_boost","Titanium"),r.p.Titanium[F("space_red_mine_desc_bd",[Xt().red])]=s+"v",s>0&&(r.p.Titanium[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Titanium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Titanium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Titanium",s*U.mult*f*d*m*e*_)}if(Kc()&&(r.p.Copper[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%",r.p.Titanium[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%"),r.p.Copper[F("hunger")]=100*(G-1)+"%",r.p.Uranium.hasOwnProperty(F("city_coal_ash"))&&(r.p.Uranium[F("city_coal_ash")]=r.p.Uranium[F("city_coal_ash")]+"v"),t.resource.Coal.display){let e=na(t.civic.coal_miner.workers,"coal_miner");e*=pi(e,"miner"),t.race.tough&&(e*=1+ui.tough.vars()[0]/100);let a=Pi("ogre");a>0&&(e*=1+ui.tough.vars(1)[0]/100*a),t.race.resilient&&(e*=1+ui.resilient.vars()[0]*t.race.resilient/100),t.tech.explosives&&t.tech.explosives>=2&&(e*=t.tech.explosives>=3?1.4:1.25),t.city.geology.Coal&&(e*=t.city.geology.Coal+1);let s=1,o=1;t.city.coal_mine.on&&(s+=.05*i.coal_mine,o+=.05),e*=t.civic.coal_miner.impact*Pe("psychic_boost","Coal"),r.p.Coal[F("job_coal_miner")]=e+"v",e>0&&(r.p.Coal[`ᄂ${F("power")}`]=100*(s-1)+"%",r.p.Coal[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),t.race.discharge&&t.race.discharge>0&&i.coal_mine>0&&(s=.5*(s-1)+1,o=.5*(o-1)+1,r.p.Coal[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),t.race.cataclysm&&c.iridium_mine&&(e=c.iridium_mine*Pe("iridium_mine","coal"),e*=t.civic.coal_miner.impact*Pe("psychic_boost","Coal"),r.p.Coal[F("space_moon_iridium_mine_title")]=e+"v",e>0&&(r.p.Coal[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Coal[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),s=1*_);let n=e;if(t.city.coal_mine.cpow=+(n*G*h*d*(o-1)).toFixed(5),n*=s*G*h*d,r.p.Coal[F("hunger")]=100*(G-1)+"%",t.interstellar.mining_droid&&z.coal>0){let e=3.75*z.coal*Pe("psychic_boost","Coal"),t=e*d*_;r.p.Coal[F("interstellar_mining_droid_title")]=e+"v",e>0&&(r.p.Coal[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Coal",t*f)}if(Vi("Coal",n*f),t.resource.Uranium.display){let e=n/(t.race.cataclysm?48:115)*Pe("psychic_boost","Uranium");t.city.coal_mine.upow=+(t.city.coal_mine.cpow/(t.race.cataclysm?48:115)).toFixed(5),t.city.geology.Uranium&&(e*=t.city.geology.Uranium+1),Vi("Uranium",e*f),r.p.Uranium[t.race.cataclysm?F("space_moon_iridium_mine_title"):F("job_coal_miner")]=e/d+"v"}}if(t.interstellar.mining_droid&&z.uran>0){let e=.12*z.uran*Pe("psychic_boost","Uranium"),t=e*d*_;r.p.Uranium[F("interstellar_mining_droid_title")]=e+"v",e>0&&(r.p.Uranium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),Vi("Uranium",t*f)}if(t.space.uranium_mine&&i.uranium_mine){let e=ht("spc_kuiper"),a=i.uranium_mine*Pe("uranium_mine")*Pe("psychic_boost","Uranium"),s=a*d*m*e*_;r.p.Uranium[F("space_kuiper_mine",[t.resource.Uranium.name])]=a+"v",a>0&&(r.p.Uranium[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Uranium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",r.p.Uranium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Uranium",s*f)}if(t.resource.Oil.display){let e=0;if(t.tauceti.whaling_station&&t.tauceti.whaling_ship){if(t.tauceti.whaling_station.max=750*t.tauceti.whaling_station.count,t.tauceti.whaling_station.fill>0){let a=i.whaling_station*Pe("whaling_station");a>t.tauceti.whaling_station.fill&&(a=t.tauceti.whaling_station.fill),t.tauceti.whaling_station.fill-=a*f,e=a*Pe("whaling_ship_oil")*Pe("psychic_boost","Oil")}let a=c.whaling_ship*Pe("whaling_ship");t.tauceti.whaling_station.fill+=a*f,t.tauceti.whaling_station.fill>t.tauceti.whaling_station.max&&(t.tauceti.whaling_station.fill=t.tauceti.whaling_station.max)}let a=t.space.oil_extractor?i.oil_extractor*Pe("oil_extractor"):0,s=t.city.oil_well?Pe("oil_well")*t.city.oil_well.count:0;a*=Pe("psychic_boost","Oil"),s*=Pe("psychic_boost","Oil");let o=ht("spc_gas_moon"),n=s*h+a*m*o*_+e*S;n*=G*d,t.space.oil_extractor&&(t.space.oil_extractor.lpmod=Pe("oil_extractor")*m*o*_),r.p.Oil[F("city_oil_well")]=s+"v",s>0&&(r.p.Oil[`ᄂ${F("quarantine")}+0`]=100*(h-1)+"%"),r.p.Oil[F("space_gas_moon_oil_extractor_title")]=a+"v",a>0&&(r.p.Oil[`ᄂ${F("space_syndicate")}`]=-100*(1-o)+"%",r.p.Oil[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Oil[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),r.p.Oil[F("tau_roid_whaling_ship")]=e+"v",S>1&&(r.p.Oil[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),r.p.Oil[F("hunger")]=100*(G-1)+"%",Vi("Oil",n*f)}if(c.iridium_mine){let e=c.iridium_mine*Pe("iridium_mine","iridium").f;e*=Pe("psychic_boost","Iridium");let t=ht("spc_moon"),a=e*G*U.mult*d*t*m*Z*_;r.p.Iridium[F("space_moon_iridium_mine_title")]=e+"v",e>0&&(r.p.Iridium[`ᄂ${F("city_smelter")}+0`]=100*(Z-1)+"%",r.p.Iridium[`ᄂ${F("space_syndicate")}+0`]=-100*(1-t)+"%",r.p.Iridium[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%",r.p.Iridium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Iridium",a*f)}if(c.iridium_ship){let e=c.iridium_ship*Pe("iridium_ship");e*=Pe("psychic_boost","Iridium");let t=ht("spc_belt"),a=e*G*U.mult*d*t*m*Z*_;r.p.Iridium[F("job_space_miner")]=e+"v",e>0&&(r.p.Iridium[`ᄂ${F("city_smelter")}+1`]=100*(Z-1)+"%",r.p.Iridium[`ᄂ${F("space_syndicate")}+1`]=-100*(1-t)+"%",r.p.Iridium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",r.p.Iridium[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Iridium",a*f)}if(i.s_gate&&t.resource.Adamantite.display&&t.galaxy.armed_miner&&n.armed_miner>0){let e=.65*n.armed_miner*Pe("psychic_boost","Iridium"),t=1+.1*n.ore_processor,a=Et("gxy_alien2"),s=e*d*a*t*G*U.mult*Z*_;r.p.Iridium[F("galaxy_armed_miner_bd")]=e+"v",e>0&&(r.p.Iridium[`ᄂ${F("galaxy_ore_processor")}`]=-100*(1-t)+"%",r.p.Iridium[`ᄂ${F("city_smelter")}+2`]=100*(Z-1)+"%",r.p.Iridium[`ᄂ${F("galaxy_piracy")}`]=-100*(1-a)+"%",r.p.Iridium[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%"),Vi("Iridium",s*f)}if(t.resource.Iridium.display&&J.iridium&&J.iridium>0){let e=J.iridium*U.mult*d*Z*G*S;r.p.Iridium[F("tau_roid_mining_ship")]=J.iridium+"v",r.p.Iridium[`ᄂ${F("city_smelter")}+3`]=100*(Z-1)+"%",S>1&&(r.p.Iridium[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Iridium",e*f)}if(t.space.moon_base&&c.helium_mine){let e=c.helium_mine*Pe("helium_mine").f;e*=Pe("psychic_boost","Helium_3");let t=ht("spc_moon"),a=e*G*d*t*m*_;r.p.Helium_3[F("space_moon_helium_mine_title")]=e+"v",e>0&&(r.p.Helium_3[`ᄂ${F("space_syndicate")}+0`]=-100*(1-t)+"%",r.p.Helium_3[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",r.p.Helium_3[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Helium_3",a*f)}if(t.space.gas_mining&&i.gas_mining){let e=i.gas_mining*Pe("gas_mining");e*=Pe("psychic_boost","Helium_3");let t=ht("spc_gas"),a=e*G*d*t*m*_;r.p.Helium_3[F("space_gas_mining_title")]=e+"v",e>0&&(r.p.Helium_3[`ᄂ${F("space_syndicate")}+1`]=-100*(1-t)+"%",r.p.Helium_3[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",r.p.Helium_3[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Helium_3",a*f)}if(i.refueling_station){let e=i.refueling_station*Pe("refueling_station");e*=Pe("psychic_boost","Helium_3");let t=e*G*d*S;r.p.Helium_3[F("tau_gas_refueling_station_title")]=e+"v",S>1&&(r.p.Helium_3[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Helium_3",t*f)}if(t.interstellar.harvester&&o.harvester){let e=o.harvester*Pe("harvester","helium");e*=Pe("psychic_boost","Helium_3");let a=e*G*d*_;if(r.p.Helium_3[F("interstellar_harvester_title")]=e+"v",e>0&&(r.p.Helium_3[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(a*=.5,r.p.Helium_3[`ᄂ${F("evo_challenge_discharge")}`]="-50%")),Vi("Helium_3",a*f),t.tech.ram_scoop){let e=o.harvester*Pe("harvester","deuterium");e*=Pe("psychic_boost","Deuterium");let t=e*G*d*_;r.p.Deuterium[F("interstellar_harvester_title")]=e+"v",e>0&&(r.p.Deuterium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"),Vi("Deuterium",t*f),r.p.Deuterium[F("hunger")]=100*(G-1)+"%"}}if(i.s_gate&&t.galaxy.raider&&n.raider>0){let e=.65*n.raider*Pe("psychic_boost","Deuterium"),t=Et("gxy_chthonian"),a=e*d*t*G*_;r.p.Deuterium[F("galaxy_raider")]=e+"v",e>0&&(r.p.Deuterium[`ᄂ${F("galaxy_piracy")}`]=-100*(1-t)+"%",r.p.Deuterium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Deuterium",a*f)}if(r.p.Helium_3[F("hunger")]=100*(G-1)+"%",i.outpost){let e=Pe("outpost",!0),a=Pe("psychic_boost","Neutronium");r.p.Neutronium[F("space_gas_moon_outpost_bd")]=e.b*a*i.outpost+"v",t.tech.drone&&(r.p.Neutronium[`ᄂ${F("tech_worker_drone")}`]=100*e.d+"%");let s=ht("spc_gas_moon"),c=i.outpost*e.n*a*G*d*m*s*_;t.space.outpost.lpmod=e.n*a*G*d*m*s*_,e.b>0&&(r.p.Neutronium[`ᄂ${F("space_syndicate")}+0`]=-100*(1-s)+"%",r.p.Neutronium[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%",r.p.Neutronium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%",t.race.discharge&&t.race.discharge>0&&(c*=.5,t.space.outpost.lpmod*=.5,r.p.Neutronium[`ᄂ${F("evo_challenge_discharge")}+0`]="-50%")),Vi("Neutronium",c*f)}if(i.neutron_miner){let e=i.neutron_miner*Pe("neutron_miner")*Pe("psychic_boost","Neutronium"),a=e*G*d*_;r.p.Neutronium[F("interstellar_neutron_miner_bd")]=e+"v",t.interstellar.neutron_miner.lpmod=Pe("neutron_miner")*G*d*_,e>0&&(r.p.Neutronium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(a*=.5,t.interstellar.neutron_miner.lpmod*=.5,r.p.Neutronium[`ᄂ${F("evo_challenge_discharge")}+1`]="-50%")),Vi("Neutronium",a*f)}if(i.s_gate&&t.galaxy.raider&&n.raider>0){let e=.8*n.raider*Pe("psychic_boost","Neutronium"),t=Et("gxy_chthonian"),a=e*d*t*G*_;r.p.Neutronium[F("galaxy_raider")]=e+"v",e>0&&(r.p.Neutronium[`ᄂ${F("galaxy_piracy")}`]=-100*(1-t)+"%",r.p.Neutronium[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%"),Vi("Neutronium",a*f)}if(t.space.neutronium_mine&&i.neutronium_mine){let e=ht("spc_kuiper"),a=i.neutronium_mine*Pe("neutronium_mine")*Pe("psychic_boost","Neutronium"),s=a*d*m*e*_;r.p.Neutronium[F("space_kuiper_mine",[t.resource.Neutronium.name])]=a+"v",a>0&&(r.p.Neutronium[`ᄂ${F("space_syndicate")}+1`]=-100*(1-e)+"%",r.p.Neutronium[`ᄂ${F("space_red_ziggurat_title")}+3`]=100*(_-1)+"%",r.p.Neutronium[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Neutronium",s*f)}if(t.resource.Neutronium.display&&J.neutronium&&J.neutronium>0){let e=J.neutronium*d*S;r.p.Neutronium[F("tau_roid_mining_ship")]=J.neutronium+"v",S>1&&(r.p.Neutronium[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Neutronium",e*f)}if(c.elerium_ship){let e=c.elerium_ship*Pe("elerium_ship")*Pe("psychic_boost","Elerium"),a=ht("spc_belt"),s=e*G*d*m*a*_;r.p.Elerium[F("job_space_miner")]=e+"v",e>0&&(r.p.Elerium[`ᄂ${F("space_syndicate")}+0`]=-100*(1-a)+"%",r.p.Elerium[`ᄂ${F("space_red_ziggurat_title")}+0`]=100*(_-1)+"%",r.p.Elerium[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%",t.race.discharge&&t.race.discharge>0&&(s*=.75,r.p.Elerium[`ᄂ${F("evo_challenge_discharge")}`]="-25%")),Vi("Elerium",s*f)}if(o.elerium_prospector){let e=o.elerium_prospector*Pe("elerium_prospector")*Pe("psychic_boost","Elerium"),t=e*G*d*_;r.p.Elerium[F("interstellar_elerium_prospector_bd")]=e+"v",e>0&&(r.p.Elerium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Elerium",t*f)}if(t.space.elerium_mine&&i.elerium_mine){let e=ht("spc_kuiper"),a=i.elerium_mine*Pe("elerium_mine")*Pe("psychic_boost","Elerium"),s=a*d*m*e*G*_;r.p.Elerium[F("space_kuiper_mine",[t.resource.Elerium.name])]=a+"v",a>0&&(r.p.Elerium[`ᄂ${F("space_syndicate")}+1`]=-100*(1-e)+"%",r.p.Elerium[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%",r.p.Elerium[`ᄂ${F("quarantine")}+1`]=100*(m-1)+"%"),Vi("Elerium",s*f)}if(t.resource.Elerium.display&&J.elerium&&J.elerium>0){let e=J.elerium*d*S;r.p.Elerium[F("tau_roid_mining_ship")]=J.elerium+"v",S>1&&(r.p.Elerium[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Elerium",e*f)}if(r.p.Elerium[F("hunger")]=100*(G-1)+"%",t.resource.Adamantite.display&&t.interstellar.mining_droid&&z.adam>0){let e=.075*z.adam*Pe("psychic_boost","Adamantite"),a=e*U.mult*d*_;if(r.p.Adamantite[F("interstellar_mining_droid_title")]=e+"v",e>0){if(t.interstellar.processing&&o.processing){let e=.12;t.tech.ai_core&&t.tech.ai_core>=2&&i.citadel>0&&(e+=.02*i.citadel);let s=o.processing*e;a*=1+s,r.p.Adamantite[`ᄂ${F("interstellar_processing_title")}`]=100*s+"%",t.race.discharge&&t.race.discharge>0&&(a*=.5,r.p.Adamantite[`ᄂ${F("evo_challenge_discharge")}`]="-50%")}r.p.Adamantite[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%"}Vi("Adamantite",a*f)}if(i.s_gate&&t.resource.Adamantite.display&&t.galaxy.armed_miner&&n.armed_miner>0){let e=.23*n.armed_miner*Pe("psychic_boost","Adamantite"),t=1+.1*n.ore_processor,a=Et("gxy_alien2"),s=e*d*a*t*U.mult*_;r.p.Adamantite[F("galaxy_armed_miner_bd")]=e+"v",e>0&&(r.p.Adamantite[`ᄂ${F("galaxy_ore_processor")}`]=-100*(1-t)+"%",r.p.Adamantite[`ᄂ${F("galaxy_piracy")}`]=-100*(1-a)+"%",r.p.Adamantite[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%"),Vi("Adamantite",s*f)}if(t.resource.Adamantite.display&&t.space.titan_mine){let e=ht("spc_titan"),a=i.ai_colonist?na(t.civic.titan_colonist.workers,"titan_colonist")+la(i.ai_colonist):na(t.civic.titan_colonist.workers,"titan_colonist"),s=Pe("titan_mine","adamantite")*c.titan_mine*a*Pe("psychic_boost","Adamantite"),o=s*U.mult*d*m*e*_;r.p.Adamantite[F("city_mine")]=s+"v",s>0&&(r.p.Adamantite[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Adamantite[`ᄂ${F("space_red_ziggurat_title")}+2`]=100*(_-1)+"%",r.p.Adamantite[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Adamantite",o*f)}if(t.resource.Infernite.display){if(t.civic.hell_surveyor.workers>0){let e=t.tech.infernite>=3?.015:.01,a=na(t.civic.hell_surveyor.workers,"hell_surveyor")*e*Pe("psychic_boost","Infernite"),s=1;if(t.tech.infernite>=2&&i.sensor_drone){let e=t.tech.infernite>=4?t.tech.infernite>=6?.5:.2:.1;s=1+i.sensor_drone*e}let c=a*s*d;r.p.Infernite[F("job_hell_surveyor")]=a+"v",r.p.Infernite[`ᄂ${F("portal_sensor_drone_title")}`]=100*(s-1)+"%",Vi("Infernite",c*f)}if(i.infernite_mine){let e=Pe("infernite_mine"),a=i.infernite_mine*e*Pe("psychic_boost","Infernite"),s=a*d;t.portal.infernite_mine.lpmod=e*d,r.p.Infernite[F("city_mine")]=a+"v",Vi("Infernite",s*f)}}if(i.s_gate&&t.resource.Bolognium.display&&t.galaxy.bolognium_ship&&n.bolognium_ship>0){let e=n.bolognium_ship*Pe("bolognium_ship")*Pe("psychic_boost","Bolognium"),a=Et("gxy_gateway"),s=e*d*a*_;r.p.Bolognium[F("galaxy_bolognium_ship")]=e+"v",e>0&&(r.p.Bolognium[`ᄂ${F("galaxy_piracy")}+0`]=-100*(1-a)+"%",r.p.Bolognium[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(s*=.5,r.p.Bolognium[`ᄂ${F("evo_challenge_discharge")}+0`]="-50%")),Vi("Bolognium",s*f)}if(t.civic.pit_miner.display)if(et()){let e=na(t.civic.pit_miner.workers,"pit_miner");e*=pi(e,"miner");let a=1+.5*(c.colony||0);{let t=e*Pe("psychic_boost","Bolognium");t*=Pe("mining_pit","bolognium");let s=t*d*a;r.p.Bolognium[F("job_pit_miner")]=t+"v",t>0&&(r.p.Bolognium[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Bolognium",s*f)}{let t=e*Pe("psychic_boost","Stone");t*=Pe("mining_pit","stone");let s=t*d*a;r.p.Stone[F("job_pit_miner")]=t+"v",t>0&&(r.p.Stone[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Stone",s*f)}{let t=e*Pe("psychic_boost","Adamantite");t*=Pe("mining_pit","adamantite");let s=t*U.mult*d*a;r.p.Adamantite[F("job_pit_miner")]=t+"v",t>0&&(r.p.Adamantite[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Adamantite",s*f)}if(t.tech.isolation){{let t=e*Pe("psychic_boost","Copper");t*=Pe("mining_pit","copper");let s=t*U.mult*d*a;r.p.Copper[F("job_pit_miner")]=t+"v",t>0&&(r.p.Copper[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Copper",s*f)}{let t=e*Pe("psychic_boost","Coal");t*=Pe("mining_pit","coal");let s=t*d*a;r.p.Coal[F("job_pit_miner")]=t+"v",t>0&&(r.p.Coal[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Coal",s*f)}if(t.race.lone_survivor){let t=e*Pe("psychic_boost","Aluminium");t*=Pe("mining_pit","aluminium");let s=t*U.mult*d*a;r.p.Aluminium[F("job_pit_miner")]=t+"v",t>0&&(r.p.Aluminium[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%"),Vi("Aluminium",s*f)}{let t=e*Pe("psychic_boost","Chrysotile");t*=Pe("mining_pit","chrysotile");let s=t*d*a*G;r.p.Chrysotile[F("job_pit_miner")]=t+"v",t>0&&(r.p.Chrysotile[`ᄂ${F("tau_home_colony")}`]=100*(a-1)+"%",r.p.Chrysotile[F("hunger")]=100*(G-1)+"%"),Vi("Chrysotile",s*f)}}}else{let e={},a=na(t.civic.pit_miner.workers,"pit_miner");a*=pi(a,"miner"),a*=Pe("mining_pit","materials");let s=1+.5*(c.colony||0),i=a*d*s;e[F("job_pit_miner")]=a+"v",a>0&&(e[`ᄂ${F("tau_home_colony")}`]=100*(s-1)+"%"),r.p.Materials=e,Vi("Materials",i*f)}if(t.tauceti.tau_farm&&i.tau_farm){let e=1+.5*(c.colony||0);if(!t.race.kindling_kindred&&!t.race.smoldering){let t=Pe("tau_farm","lumber")*i.tau_farm*Pe("psychic_boost","Lumber"),a=t*d*e;r.p.Lumber[F("tau_home_tau_farm")]=t+"v",t>0&&(r.p.Lumber[`ᄂ${F("tau_home_colony")}`]=100*(e-1)+"%"),Vi("Lumber",a*f)}}if(Kc()&&(r.p.Adamantite[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%"),i.s_gate&&t.resource.Bolognium.display&&t.galaxy.armed_miner&&n.armed_miner>0){let e=.032*n.armed_miner*Pe("psychic_boost","Bolognium"),a=1+.1*n.ore_processor,s=Et("gxy_alien2"),i=e*d*s*a*_;r.p.Bolognium[F("galaxy_armed_miner_bd")]=e+"v",e>0&&(r.p.Bolognium[`ᄂ${F("galaxy_ore_processor")}`]=-100*(1-a)+"%",r.p.Bolognium[`ᄂ${F("galaxy_piracy")}+1`]=-100*(1-s)+"%",r.p.Bolognium[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(i*=.5,r.p.Bolognium[`ᄂ${F("evo_challenge_discharge")}+1`]="-50%")),Vi("Bolognium",i*f)}if(i.s_gate&&t.resource.Orichalcum.display&&t.galaxy.excavator&&i.excavator>0){let e=i.excavator*Pe("excavator")*Pe("psychic_boost","Orichalcum"),a=Et("gxy_chthonian"),s=e*d*a*_;t.galaxy.excavator.lpmod=Pe("excavator")*d*a*_,r.p.Orichalcum[F("galaxy_excavator")]=e+"v",e>0&&(r.p.Orichalcum[`ᄂ${F("galaxy_piracy")}`]=-100*(1-a)+"%",r.p.Orichalcum[`ᄂ${F("space_red_ziggurat_title")}`]=100*(_-1)+"%",t.race.discharge&&t.race.discharge>0&&(s*=.5,t.galaxy.excavator.lpmod*=.5,r.p.Orichalcum[`ᄂ${F("evo_challenge_discharge")}`]="-50%")),Vi("Orichalcum",s*f)}if(t.space.orichalcum_mine&&i.orichalcum_mine){let e=ht("spc_kuiper"),a=i.orichalcum_mine*Pe("orichalcum_mine")*Pe("psychic_boost","Orichalcum"),s=a*d*m*e*_;r.p.Orichalcum[F("space_kuiper_mine",[t.resource.Orichalcum.name])]=a+"v",a>0&&(r.p.Orichalcum[`ᄂ${F("space_syndicate")}`]=-100*(1-e)+"%",r.p.Orichalcum[`ᄂ${F("space_red_ziggurat_title")}+1`]=100*(_-1)+"%",r.p.Orichalcum[`ᄂ${F("quarantine")}+0`]=100*(m-1)+"%"),Vi("Orichalcum",s*f)}if(t.resource.Orichalcum.display&&J.orichalcum&&J.orichalcum>0){let e=J.orichalcum*d*S;r.p.Orichalcum[F("tau_roid_mining_ship")]=J.orichalcum+"v",S>1&&(r.p.Orichalcum[`ᄂ${F("tau_red_womlings")}+0`]=100*(S-1)+"%"),Vi("Orichalcum",e*f)}if(t.race.truepath&&t.tech.tau_red&&t.tech.tau_red>=5&&t.tauceti.womling_mine&&t.tauceti.overseer){let e=t.tauceti.womling_mine.miners*Pe("womling_mine","unobtainium")*Pe("psychic_boost","Unobtainium"),a=t.tauceti.overseer.prod/100,s=e*a*d;if(r.p.Unobtainium[F("tau_red_womlings")]=e+"v",e>0&&(r.p.Unobtainium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Unobtainium",s*f),t.tech.isolation){let e=t.tauceti.womling_mine.miners*Pe("womling_mine","uranium")*Pe("psychic_boost","Uranium");r.p.Uranium[F("tau_red_womlings")]=e+"v";let s=e*a*d;e>0&&(r.p.Uranium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Uranium",s*f);let i=t.tauceti.womling_mine.miners*Pe("womling_mine","titanium")*Pe("psychic_boost","Titanium");r.p.Titanium[F("tau_red_womlings")]=i+"v";let c=i*a*U.mult*d;if(i>0&&(r.p.Titanium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Titanium",c*f),t.race.lone_survivor){let e=t.tauceti.womling_mine.miners*Pe("womling_mine","copper")*Pe("psychic_boost","Copper");r.p.Copper[F("tau_red_womlings")]=e+"v";let s=e*a*U.mult*d;s>0&&(r.p.Copper[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Copper",s*f);let i=t.tauceti.womling_mine.miners*Pe("womling_mine","aluminium")*Pe("psychic_boost","Aluminium");r.p.Aluminium[F("tau_red_womlings")]=i+"v";let c=i*a*U.mult*d;i>0&&(r.p.Aluminium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Aluminium",c*f);let o=t.tauceti.womling_mine.miners*Pe("womling_mine","iridium")*Pe("psychic_boost","Iridium");r.p.Iridium[F("tau_red_womlings")]=o+"v";let n=o*a*U.mult*d;o>0&&(r.p.Iridium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Iridium",n*f);let l=t.tauceti.womling_mine.miners*Pe("womling_mine","neutronium")*Pe("psychic_boost","Neutronium");r.p.Neutronium[F("tau_red_womlings")]=l+"v";let u=l*a*G*d;l>0&&(r.p.Neutronium[`ᄂ${F("tau_red_womling_prod_label")}`]=-100*(1-a)+"%"),Vi("Neutronium",u*f)}}}r.p.Neutronium[F("hunger")]=100*(G-1)+"%",Kc()&&(r.p.Iridium[F("city_shrine")]=(100*(U.mult-1)).toFixed(1)+"%"),r.p.Iridium[F("hunger")]=100*(G-1)+"%";let X=R?R*d:0;if(t.tech.currency>=1){let e=t.resource[t.race.species].amount+t.civic.garrison.workers-t.civic.unemployed.workers;if(t.race.high_pop&&(e=Me(e)),e*=t.race.truepath?.2:.4,t.race.greedy&&(e*=1-ui.greedy.vars()[0]/100),t.tech.isolation&&(e*=15),e*=Pe("psychic_cash"),x){if(t.tech.banking&&t.tech.banking>=2){let a=+na(t.civic.banker.impact,"banker");t.tech.banking>=10&&(a+=.02*t.tech.stock_exchange),t.race.truthful&&(a*=1-ui.truthful.vars()[0]/100),"republic"===t.civic.govern.type&&(a*=1+ae.republic()[0]/100),t.race.high_pop&&(a=Me(a)),e*=1+t.civic.banker.workers*a}}else e/=2;e*=t.civic.taxes.tax_rate/20,"oligarchy"===t.civic.govern.type&&(e*=1-ae.oligarchy()[0]/100),"corpocracy"===t.civic.govern.type&&(e*=.5),"socialist"===t.civic.govern.type&&(e*=1-ae.socialist()[3]/100),t.race.banana&&(e*=.05);let a=1;if(t.tech.anthropology&&t.tech.anthropology>=4)if(t.race.truepath){let e=t.resource[t.race.species].amount*t.city.temple.count*.08;r.p.Money[F("city_temple")]=e+"v",Vi("Money",+(e*d*f).toFixed(2))}else a+=.025*(t.race.cataclysm||t.race.orbit_decayed?t.space.ziggurat?t.space.ziggurat.count:0:t.city.temple.count);let s=0;if(!t.tech.world_control&&"federation"!==t.civic.govern.type)for(let a=0;a<3;a++)t.civic.foreign[`gov${a}`].buy&&(s+=.2*e);let i=Lc("tax"),c=(e-s)*a*i.mult;c*=d,r.p.Money[F("morale_tax")]=e+"v",e>0&&(r.p.Money[`ᄂ${F("civics_spy_purchase_bd")}`]=-s+"v",r.p.Money[t.race.cataclysm||t.race.orbit_decayed?`ᄂ${F("space_red_ziggurat_title")}`:`ᄂ${F("city_temple")}`]=100*(a-1)+"%",r.p.Money[`ᄂ${F("city_shrine")}`]=100*(i.mult-1)+"%"),r.p.Money[F("city_factory")]=R+"v",t.race.discharge&&t.race.discharge>0&&R>0&&(r.p.Money[`ᄂ${F("evo_challenge_discharge")}`]="-50%"),Vi("Money",+(c*f).toFixed(2)),X+=c}if(t.race.truepath&&t.tauceti.overseer){let e=(t.tauceti.overseer.loyal+t.tauceti.overseer.morale)/200,a=t.tauceti.overseer.pop;i.womling_station&&(a+=2*i.womling_station);let s=a*e*(t.tech.isolation?25:12),c=i.tau_cultural_center?1+.08*i.tau_cultural_center:1,o=s*d*c;r.p.Money[F("tau_red_womlings")]=s+"v",r.p.Money[`ᄂ${F("tech_cultural_center")}`]=100*(c-1)+"%",Vi("Money",+(o*f).toFixed(2))}if(t.tech.gambling&&(i.casino||i.spc_casino||i.tauceti_casino)){let e=0;i.casino&&(e+=i.casino),i.spc_casino&&(e+=i.spc_casino),i.tauceti_casino&&(e+=i.tauceti_casino);let a=Math.log2(1+t.resource[t.race.species].amount),s=2.5;t.race.gambler&&(s*=1+ui.gambler.vars()[0]*t.race.gambler/100),a*=s,t.tech.gambling>=2&&(a*=t.tech.gambling>=5?2:1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(a*=1+.01*t.tech.stock_exchange),"corpocracy"===t.civic.govern.type&&(a*=1+ae.corpocracy()[0]/100),"socialist"===t.civic.govern.type&&(a*=1-ae.socialist()[3]/100),t.race.inflation&&(a*=1+t.race.inflation/1250),t.tech.isolation&&(a*=1.25,t.tech.iso_gambling&&(a*=1+.05*na(t.civic.banker.workers,"banker"))),a*=Pe("psychic_cash");let c=N("racketeer",1);c&&(a*=1+c/100),a*=e,r.p.Money[F("city_casino")]=a+"v",Vi("Money",+(a*f*d*G).toFixed(2)),X+=a*d*G}if(t.city.tourist_center){let e=0,s=t.tech.monument&&t.tech.monument>=3&&i.s_gate?3:1;t.city.amphitheatre&&(e+=t.city.tourist_center.on*t.city.amphitheatre.count*s),t.city.casino&&(e+=t.city.tourist_center.on*t.city.casino.count*5*s),t.space.spc_casino&&(e+=t.city.tourist_center.on*t.space.spc_casino.count*5*s),t.tech.monuments&&(e+=t.city.tourist_center.on*t.tech.monuments*2*s),t.city.trade&&t.stats.achieve.banana&&t.stats.achieve.banana.l>=4&&(e+=t.city.tourist_center.on*t.city.trade.count*3*s);let c=N("pious",1);c&&t.city.temple&&(e+=t.city.tourist_center.on*t.city.temple.count*c*s),"corpocracy"===t.civic.govern.type&&(e*=1+ae.corpocracy()[2]/100),"socialist"===t.civic.govern.type&&(e*=1-ae.socialist()[3]/100),"aquarius"===a&&(e*=1+H("aquarius")[0]/100),e*=Pe("psychic_cash"),r.p.Money[F("tech_tourism")]=Math.round(e)+"v","aquarius"===a&&(r.p.Money[`ᄂ${F("sign_aquarius")}`]=H("aquarius")[0]+"%"),Vi("Money",+(e*f*d*G).toFixed(2)),X+=e*d*G}if(t.tauceti.tau_cultural_center){let e=0;t.tauceti.tauceti_casino&&(e+=i.tau_cultural_center*i.tauceti_casino*20),t.tech.monuments&&(e+=i.tau_cultural_center*t.tech.monuments*5),t.tech.tau_culture&&t.tech.tau_culture>=2&&(e+=i.tau_cultural_center*c.colony*15),"corpocracy"===t.civic.govern.type?e*=1+ae.corpocracy()[2]/100:"socialist"===t.civic.govern.type&&(e*=1-ae.socialist()[3]/100),e*=Pe("psychic_cash"),r.p.Money[F("tech_cultural_center")]=Math.round(e)+"v","aquarius"===a&&(e*=1+H("aquarius")[0]/100,e[`ᄂ${F("sign_aquarius")}`]=H("aquarius")[0]+"%"),Vi("Money",+(e*f*d*G).toFixed(2)),X+=e*d*G}if(t.tech.tau_junksale){let e=40*c.womling_village,t=i.tau_cultural_center?1+.08*i.tau_cultural_center:1;r.p.Money[F("tau_red_womling_village")]=Math.round(e)+"v",r.p.Money[`ᄂ${F("tech_cultural_center")}+1`]=100*(t-1)+"%",Vi("Money",+(e*t*f*d*G).toFixed(2)),X+=e*t*d*G}{let e=N("racketeer",0);if(e){let t=-Math.round(X*(e/100));r.p.consume.Money[F("gov_trait_racketeer_bd")]=t,Vi("Money",+(t*f).toFixed(2))}}{let e=N("pious",0);if(e){let t=-Math.round(X*(e/100));r.p.consume.Money[F("gov_trait_pious_bd")]=t,Vi("Money",+(t*f).toFixed(2))}}if(t.tech.foundry){let e=t.race.resourceful?1-ui.resourceful.vars()[0]/100:1;Pi("arraak")>0&&ui.resourceful.vars(1)[0];let a=Ya(),s={};Xa("","",!0),Object.keys(a).forEach((function(i){if("Thermite"===i&&!Tc("summer"))return;r.p[i]={};let c=na(t.city.foundry[i],"craftsman");t.race.servants&&t.race.servants.hasOwnProperty("sjobs")&&t.race.servants.sjobs.hasOwnProperty(i)&&(c+=la(t.race.servants.sjobs[i]));let o=Xa(i,"auto").multiplier,n=t.genes.crafty?2:1,l=Math.floor(t.resource[a[i][0].r].amount/(a[i][0].a*n*e/140));for(let r=1;r0&&(r.p.consume[e][F("job_craftsman")]=-s[e])}))}!t.settings.showResearch&&(t.resource.Lumber.amount>=5||t.resource.Stone.amount>=6)&&(t.settings.showResearch=!0),t.city.power_total=-C,t.city.power=O,t.city.power<0?($("#powerMeter").addClass("low"),$("#powerMeter").removeClass("neutral"),$("#powerMeter").removeClass("high")):t.city.power>0?($("#powerMeter").removeClass("low"),$("#powerMeter").removeClass("neutral"),$("#powerMeter").addClass("high")):($("#powerMeter").removeClass("low"),$("#powerMeter").addClass("neutral"),$("#powerMeter").removeClass("high")),i.world_controller&&i.world_controller>0?0===t.tech.wsc&&(t.tech.wsc=1,ms()):0!==t.tech.wsc&&(t.tech.wsc=0,ms()),t.tech.portal>=2&&(t.portal.fortress.garrison>0?t.tech.portal_guard=1:t.tech.portal_guard=0),t.race.decay&&Object.keys(Za).forEach((function(e){if(t.resource[e].amount>50){let a=+((t.resource[e].amount-50)*(.001*Za[e])).toFixed(3);Vi(e,-a*f),r.p.consume[e][F("evo_challenge_decay")]=-a}else delete r.p.consume[e][F("evo_challenge_decay")]})),$o&&(t.tech.piracy&&Rt(),t.settings.portal.ruins&&(sc({el:"#srprtl_ruins"},"update"),sc({el:"#foundry"},"update")),t.settings.portal.gate&&sc({el:"#srprtl_gate"},"update"))}if(t.civic.garrison&&t.civic.garrison.workers=2?.08:.05;t.blood.lust&&(a+=.002*t.blood.lust);let r=N("militant",0);r&&(a*=1+r/100),e*=1+(t.race.orbit_decayed&&t.space.space_barracks?t.space.space_barracks.on:t.city.boot_camp.count)*a}t.race.beast&&(e*=1+ui.beast.vars()[2]/100),t.civic.garrison.rate=e*f,t.race.brute&&(t.civic.garrison.rate+=ui.brute.vars()[1]/40*f);let a=Pi("orc");a>0&&(t.civic.garrison.rate+=ui.brute.vars(1)[1]/40*a*f),t.civic.garrison.progress+=t.civic.garrison.rate,t.civic.garrison.progress>=100&&(t.civic.garrison.progress=0,t.civic.garrison.workers++,t.portal.fortress&&t.portal.fortress.assigned&&t.portal.fortress.garrison0?($("#portal-carport .count").hasClass("has-text-alert")||$("#portal-carport .count").addClass("has-text-alert"),t.portal.carport.repair+=4*f,t.portal.carport.repair>=Qr.portal.prtl_fortress.carport.repair()&&(t.portal.carport.repair=0,t.portal.carport.damaged--)):$("#portal-carport .count").hasClass("has-text-alert")&&$("#portal-carport .count").removeClass("has-text-alert")),Object.keys(t.resource).forEach((function(e){(t.resource[e].rate>0||0===t.resource[e].rate&&-1===t.resource[e].max)&&function(e,a){const s=1e3/a;t.resource[e].diff=+(t.resource[e].delta*s).toFixed(2),t.resource[e].delta=0,t.resource[e].hasOwnProperty("gen")&&t.resource[e].hasOwnProperty("gen_d")&&(t.resource[e].gen=+(t.resource[e].gen_d*s).toFixed(2),t.resource[e].gen_d=0);let i=$(`#res${e} .diff`);t.race.decay?t.resource[e].diff<0?t.resource[e].diff>=r.p.consume[e][F("evo_challenge_decay")]?i.hasClass("has-text-warning")||(i.removeClass("has-text-danger"),i.addClass("has-text-warning")):i.hasClass("has-text-danger")||(i.removeClass("has-text-warning"),i.addClass("has-text-danger")):t.resource[e].diff>=0&&(i.hasClass("has-text-danger")||i.hasClass("has-text-warning"))&&(i.removeClass("has-text-danger"),i.removeClass("has-text-warning")):t.resource[e].diff<0&&!i.hasClass("has-text-danger")?i.addClass("has-text-danger"):t.resource[e].diff>=0&&i.hasClass("has-text-danger")&&i.removeClass("has-text-danger")}(e,M.timers.main)})),t.settings.expose&&(window.evolve||go(),fo()),Tc("easter").active)for(b=1;b<=18;b++)$(`#egg${b}`).length>0&&!$(`#egg${b}`).hasClass("binded")&&(xc(b),$(`#egg${b}`).addClass("binded"));if(Tc("halloween").active){for(b=1;b<=7;b++)$(`#treat${b}`).length>0&&!$(`#treat${b}`).hasClass("binded")&&(qc(b,!1),$(`#treat${b}`).addClass("binded"));for(b=1;b<=7;b++)$(`#trick${b}`).length>0&&!$(`#trick${b}`).hasClass("binded")&&(qc(b,!0),$(`#trick${b}`).addClass("binded"))}$o=!1}();break;case"mid":!function(){const e=U();if("protoplasm"===t.race.species){let e=100;t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1&&(e+=50*(t.stats.achieve.mass_extinction.l-1));var a={RNA:e,DNA:e};if(t.evolution.membrane){let e=t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5;a.RNA+=t.evolution.membrane.count*e}if(t.evolution.eukaryotic_cell){let e=t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10;a.DNA+=t.evolution.eukaryotic_cell.count*e}t.resource.RNA.max=a.RNA,t.resource.DNA.max=a.DNA,Object.keys(Qr.evolution).forEach((function(e){if(Qr.evolution[e]&&Qr.evolution[e].cost){let t=Qr.evolution[e],a=$("#"+t.id);a.length>0&&(Cs(t)?a.hasClass("cna")&&a.removeClass("cna"):a.hasClass("cna")||a.addClass("cna"),Cs(t,!0)?a.hasClass("cnam")&&a.removeClass("cnam"):a.hasClass("cnam")||a.addClass("cnam"))}}))}else{a={Money:1e3,Slave:0,Mana:0,Energy:100,Sus:100,Knowledge:t.stats.achieve.extinct_junker&&t.stats.achieve.extinct_junker.l>=1?1e3:100,Zen:0,Food:1e3,Crates:0,Containers:0,Lumber:200,Stone:200,Chrysotile:200,Crystal:10,Furs:100,Copper:100,Iron:100,Cement:100,Coal:50,Oil:0,Uranium:10,Aluminium:50,Steel:50,Titanium:50,Alloy:50,Polymer:50,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:1,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Unobtainium:0,Cipher:0,Nanite:0,Materials:0};var s={unemployed:-1,hunter:-1,forager:-1,farmer:-1,lumberjack:-1,quarry_worker:-1,crystal_miner:-1,scavenger:-1,torturer:0,miner:0,coal_miner:0,craftsman:0,cement_worker:0,banker:0,entertainer:0,priest:0,professor:0,scientist:0,garrison:0,colonist:0,titan_colonist:0,space_miner:0,hell_surveyor:0,archaeologist:0,pit_miner:0,crew:0};if(t.race.cataclysm?(a.Money+=25e4,a.Knowledge+=1e5,a.Lumber+=1e5,a.Stone+=1e5,a.Chrysotile+=1e5,a.Furs+=1e5,a.Aluminium+=1e5,a.Steel+=1e5,a.Copper+=1e5,a.Iron+=1e5,a.Coal+=1e5,a.Cement+=1e5,a.Titanium+=75e3,a.Alloy+=2e4,a.Polymer+=2e4,a.Uranium+=1e3):t.race.lone_survivor&&(a.Money+=1e9,a.Knowledge+=1e5,a.Food+=9e3,a.Water+=1e4,a.Elerium+=999),t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0){let e=Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept);a.Lumber+=60*e,a.Stone+=60*e}t.race.hasOwnProperty("psychicPowers")&&t.race.psychicPowers.hasOwnProperty("channel")&&(a.Energy-=t.race.psychicPowers.channel.boost,a.Energy-=t.race.psychicPowers.channel.assault,a.Energy-=t.race.psychicPowers.channel.cash,a.Energy<0&&(a.Energy=100,t.race.psychicPowers.channel.boost=0,t.race.psychicPowers.channel.assault=0,t.race.psychicPowers.channel.cash=0));var d={[F("base")]:a.Money+"v"},_={},p={},h={[F("base")]:a.Mana+"v"},g={[F("base")]:a.Mana+"v"},f={[F("base")]:a.Knowledge+"v"},v={},y={},b={},w={[F("base")]:a.Food+"v"},x={[F("base")]:a.Lumber+"v"},k={[F("base")]:a.Stone+"v"},q={[F("base")]:a.Chrysotile+"v"},P={[F("base")]:a.Crystal+"v"},O={[F("base")]:a.Furs+"v"},C={[F("base")]:a.Copper+"v"},j={[F("base")]:a.Iron+"v"},S={[F("base")]:a.Cement+"v"},z={[F("base")]:a.Coal+"v"},A={[F("base")]:a.Oil+"v"},T={[F("base")]:a.Uranium+"v"},E={[F("base")]:a.Steel+"v"},I={[F("base")]:a.Aluminium+"v"},K={[F("base")]:a.Titanium+"v"},L={[F("base")]:a.Alloy+"v"},D={[F("base")]:a.Polymer+"v"},B={[F("base")]:a.Iridium+"v"},G={[F("base")]:a.Helium_3+"v"},R={[F("base")]:a.Water+"v"},W={[F("base")]:a.Deuterium+"v"},Q={[F("base")]:a.Neutronium+"v"},Z={[F("base")]:a.Adamantite+"v"},V={[F("base")]:a.Infernite+"v"},J={[F("base")]:a.Elerium+"v"},Y={[F("base")]:a.Nano_Tube+"v"},X={[F("base")]:a.Graphene+"v"},te={[F("base")]:a.Stanene+"v"},ae={[F("base")]:a.Bolognium+"v"},re={[F("base")]:a.Vitreloy+"v"},se={[F("base")]:a.Orichalcum+"v"},ie={[F("base")]:a.Unobtainium+"v"},ce={[F("base")]:a.Cipher+"v"},oe={[F("base")]:a.Nanite+"v"},ne={[F("base")]:a.Materials+"v"};if(r.c={Money:d,[t.race.species]:_,Slave:p,Mana:h,Sus:g,Knowledge:f,Zen:v,Crates:y,Containers:b,Food:w,Lumber:x,Stone:k,Chrysotile:q,Crystal:P,Furs:O,Copper:C,Iron:j,Cement:S,Coal:z,Oil:A,Uranium:T,Steel:E,Aluminium:I,Titanium:K,Alloy:L,Polymer:D,Iridium:B,Helium_3:G,Water:R,Deuterium:W,Neutronium:Q,Adamantite:Z,Infernite:V,Elerium:J,Nano_Tube:Y,Graphene:X,Stanene:te,Bolognium:ae,Vitreloy:re,Orichalcum:se,Unobtainium:ie,Nanite:oe,Cipher:ce,Materials:ne},a[t.race.species]=0,t.race.unfathomable&&t.city.captive_housing){let e=t.tech.military?t.tech.military>=5?t.tech.military-1:t.tech.military:1,a=na(t.civic.hunter.workers,"hunter")*e;a*=pi(a,"hunting"),t.race.swift&&(a*=1+ui.swift.vars()[1]/100),t.race.servants&&(a+=t.race.servants.jobs.hunter*e);let r=0,s=0,i=[];if(t.city.hasOwnProperty("surfaceDwellers"))for(let e=0;e0&&i.push(e)}let c=Math.round(40/ui.unfathomable.vars()[1]);if(r=2&&t.civic.torturer.workers>0&&i.length>0&&Math.rand(0,Math.ceil((s+1)**1.45))0&&(t.race.psychicPowers.boostTime--,(t.race.psychicPowers.boostTime<0||t.race.psychicPowers.boostTime>360)&&(t.race.psychicPowers.boostTime=0)),t.race.psychicPowers&&t.race.psychicPowers.assaultTime&&t.race.psychicPowers.assaultTime>0&&(t.race.psychicPowers.assaultTime--,(t.race.psychicPowers.assaultTime<0||t.race.psychicPowers.assaultTime>360)&&(t.race.psychicPowers.assaultTime=0)),t.race.psychicPowers&&t.race.psychicPowers.cash&&t.race.psychicPowers.cash>0&&(t.race.psychicPowers.cash--,(t.race.psychicPowers.cash<0||t.race.psychicPowers.cash>360)&&(t.race.psychicPowers.cash=0))),t.city.nanite_factory){let e=t.city.nanite_factory.count*Lr(2500);a.Nanite+=e,oe[F("city_nanite_factory")]=e+"v"}if(i.transmitter&&t.race.artifical){let e=i.transmitter*Lr(100);a.Food+=e,w[F("city_transmitter")]=e+"v"}if(t.city.pylon||t.space.pylon||t.tauceti.pylon){let e=0,r="city_pylon";(t.race.cataclysm||t.race.orbit_decayed)&&t.space.pylon?(e=Lr(2)*t.space.pylon.count,r="space_red_pylon"):t.tech.isolation&&t.tauceti.pylon?(e=Lr(2)*t.tauceti.pylon.count,r="tau_home_pylon"):t.city.pylon&&(e=Lr(5)*t.city.pylon.count),a.Mana+=e,h[F(r)]=e+"v"}if(t.city.captive_housing){let e=t.city.captive_housing.count;t.city.captive_housing.raceCap=e*(t.tech.unfathomable&&t.tech.unfathomable>=3?3:2),t.city.captive_housing.cattleCap=5*e}if(t.city.farm&&t.tech.farm){let e=t.city.farm.count*Qr.city.farm.citizens();a[t.race.species]+=e,_[F("city_farm")]=e+"v"}if(t.city.wharf){let e=t.tech.world_control?15:10;t.tech.particles&&t.tech.particles>=2&&(e*=2),a.Crates+=t.city.wharf.count*e,y[F("city_wharf")]=t.city.wharf.count*e+"v",a.Containers+=t.city.wharf.count*e,b[F("city_wharf")]=t.city.wharf.count*e+"v"}if(t.space.munitions_depot){let e=25;a.Crates+=t.space.munitions_depot.count*e,y[F("tech_munitions_depot")]=t.space.munitions_depot.count*e+"v",a.Containers+=t.space.munitions_depot.count*e,b[F("tech_munitions_depot")]=t.space.munitions_depot.count*e+"v"}if(t.interstellar.cargo_yard){a.Crates+=50*t.interstellar.cargo_yard.count,y[F("interstellar_cargo_yard_title")]=50*t.interstellar.cargo_yard.count+"v",a.Containers+=50*t.interstellar.cargo_yard.count,b[F("interstellar_cargo_yard_title")]=50*t.interstellar.cargo_yard.count+"v";let e=t.interstellar.cargo_yard.count*Lr(200);a.Neutronium+=e,Q[F("interstellar_cargo_yard_title")]=e+"v",e=t.interstellar.cargo_yard.count*Lr(150),a.Infernite+=e,V[F("interstellar_cargo_yard_title")]=e+"v"}if(t.interstellar.neutron_miner&&i.neutron_miner){let e=i.neutron_miner*Lr(500);a.Neutronium+=e,Q[F("interstellar_neutron_miner_title")]=e+"v"}if(t.city.storage_yard){let e=t.tech.container>=3?20:10;t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),a.Crates+=t.city.storage_yard.count*e,y[F("city_storage_yard")]=t.city.storage_yard.count*e+"v"}if(t.space.garage){let e=t.tech.particles>=4?20+t.tech.supercollider:20;(t.tech.world_control||t.race.cataclysm)&&(e+=10),a.Containers+=t.space.garage.count*e,b[F("space_red_garage_title")]=t.space.garage.count*e+"v",(t.race.cataclysm||t.race.orbit_decayed)&&(a.Crates+=t.space.garage.count*e,y[F("space_red_garage_title")]=t.space.garage.count*e+"v")}if(t.tech.tp_depot&&(a.Containers+=50*t.tech.tp_depot,b[F("galaxy_gateway_depot")]=50*t.tech.tp_depot+"v",a.Crates+=50*t.tech.tp_depot,y[F("galaxy_gateway_depot")]=50*t.tech.tp_depot+"v"),t.city.warehouse){let e=t.tech.steel_container>=2?20:10;t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),a.Containers+=t.city.warehouse.count*e,b[F("city_warehouse")]=t.city.warehouse.count*e+"v"}if(t.city.rock_quarry){let e=cs(t.city.rock_quarry.count*Lr(100));a.Stone+=e,k[F("city_rock_quarry")]=e+"v",a.Chrysotile+=e,q[F("city_rock_quarry")]=e+"v"}if(t.city.lumber_yard){let e=cs(t.city.lumber_yard.count*Lr(100));a.Lumber+=e,x[F("city_lumber_yard")]=e+"v"}else if(t.city.graveyard){let e=cs(t.city.graveyard.count*Lr(100));a.Lumber+=e,x[F("city_graveyard")]=e+"v"}if(t.city.sawmill){let e=cs(t.city.sawmill.count*Lr(200));a.Lumber+=e,x[F("city_sawmill")]=e+"v"}if(t.city.mine&&(s.miner+=la(t.city.mine.count)),t.city.coal_mine&&(s.coal_miner+=la(t.city.coal_mine.count)),t.city.bank&&(s.banker+=la(t.city.bank.count)),t.city.amphitheatre){let e=N("athleticism",1);s.entertainer+=la(e?t.city.amphitheatre.count*e:t.city.amphitheatre.count)}if(t.city.casino&&(s.entertainer+=la(t.city.casino.count)),t.space.spc_casino&&(s.entertainer+=la(t.space.spc_casino.count),t.race.orbit_decayed&&(s.banker+=la(t.space.spc_casino.count))),t.tauceti.tauceti_casino&&(s.entertainer+=la(t.tauceti.tauceti_casino.count),t.tech.isolation)){s.banker+=la(t.tauceti.tauceti_casino.count);let e=i.tauceti_casino*Qr.tauceti.tau_home.tauceti_casino.citizens();a[t.race.species]+=e,_[F("city_casino")]=e+"v"}if(t.galaxy.resort&&(s.entertainer+=la(2*i.resort)),t.city.cement_plant&&(s.cement_worker+=la(2*t.city.cement_plant.count)),t.race.orbit_decayed&&i.red_factory&&(s.cement_worker+=la(i.red_factory)),t.race.parasite&&!t.tech.isolation&&(s.garrison+=la(2)),t.city.garrison&&(s.garrison+=t.city.garrison.on*(t.tech.military>=5?la(3):la(2)),t.race.chameleon&&(s.garrison-=t.city.garrison.on)),t.space.space_barracks){let e=t.tech.marines>=2?la(4):la(2);s.garrison+=t.space.space_barracks.on*e}if(t.interstellar.cruiser&&(s.garrison+=o.cruiser*la(3)),i.s_gate&&t.galaxy.starbase){let e=t.tech.marines>=2?la(8):la(5);s.garrison+=i.starbase*e}if(t.race.orbit_decayed&&t.space.hasOwnProperty("red_mine")&&(s.miner+=la(c.red_mine),s.coal_miner+=la(c.red_mine)),!t.tech.world_control){let e=la("federation"===t.civic.govern.type?15:20);for(let a=2;a>=0;a--)t.civic.foreign[`gov${a}`].occ&&(s.garrison-=e,s.garrison<0&&(t.civic.foreign[`gov${a}`].occ=!1,s.garrison+=e,t.civic.garrison.workers+=e,Di(F("civics_garrison_autodeoccupy_desc",[ee(a)]),"danger",!1,["spy"])))}if(t.race.slaver&&t.tech.slaves&&t.city.slave_pen&&(a.Slave=4*t.city.slave_pen.count,p[F("city_slave_pen")]=4*t.city.slave_pen.count+"v",a.Slavet.resource.Zen.max&&(t.resource.Zen.amount=t.resource.Zen.max);let e=t.resource.Zen.amount/(t.resource.Zen.amount+5e3);v[F("trait_calm_desc")]=`+${(100*e).toFixed(2)}%`}if(t.city.basic_housing){let e=t.city.basic_housing.count*Qr.city.basic_housing.citizens();a[t.race.species]+=e,_[Is("small")]=e+"v"}if(t.tauceti.tau_housing&&t.tech.isolation){let e=t.tauceti.tau_housing.count*Qr.tauceti.tau_home.tau_housing.citizens();a[t.race.species]+=e,_[Is("small")]=e+"v"}if(t.city.cottage){let e=t.city.cottage.count*Qr.city.cottage.citizens();if(a[t.race.species]+=e,_[Is("medium")]=e+"v",t.tech.home_safe){let e=t.city.cottage.count*Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?5e3:2e3:1e3);a.Money+=e,d[Is("medium")]=e+"v"}}if(t.city.apartment){let e=i.apartment*Qr.city.apartment.citizens();if(a[t.race.species]+=e,_[Is("large")]=e+"v",t.tech.home_safe){let e=i.apartment*Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?1e4:5e3:2e3);a.Money+=e,d[Is("large")]=e+"v"}}if(i.s_gate&&t.galaxy.consulate&&t.galaxy.consulate.count>=1){let e=Qr.galaxy.gxy_alien1.consulate.citizens();a[t.race.species]+=e,_[F("galaxy_consulate")]=e+"v"}if(i.s_gate&&i.embassy&&t.tech.xeno>=11){let e=Qr.galaxy.gxy_gorddon.embassy.citizens();a[t.race.species]+=e,_[F("galaxy_embassy")]=e+"v"}if(i.s_gate&&i.embassy&&t.galaxy.dormitory){let e=i.dormitory*Qr.galaxy.gxy_gorddon.dormitory.citizens();a[t.race.species]+=e,_[F("galaxy_dormitory")]=e+"v"}if(i.arcology){let e=i.arcology*Qr.portal.prtl_ruins.arcology.citizens();a[t.race.species]+=e,_[F("portal_arcology_title")]=e+"v",s.garrison+=i.arcology*la(5),a.Containers+=i.arcology*Math.round(u)*10,b[F("portal_arcology_title")]=i.arcology*Math.round(u)*10+"v",a.Crates+=i.arcology*Math.round(u)*10,y[F("portal_arcology_title")]=i.arcology*Math.round(u)*10+"v";let r=Oa("ruins"),c=i.arcology*Lr(8*Hs()*r.supress);a.Money+=c,d[F("portal_arcology_title")]=c+"v"}if(c.colony){let e=t.tech.isolation?900:250;a.Containers+=c.colony*e,b[F("tau_home_colony")]=c.colony*e+"v",a.Crates+=c.colony*e,y[F("tau_home_colony")]=c.colony*e+"v";let r=c.colony*Qr.tauceti.tau_home.colony.citizens();a[t.race.species]+=r,_[F("tau_home_colony")]=r+"v"}if(i.operating_base&&(s.garrison+=Math.min(c.operating_base,i.operating_base)*la(4)),i.fob&&(s.garrison+=la(10)),t.space.living_quarters){let e=Math.round(c.living_quarters*Qr.space.spc_red.living_quarters.citizens());if(a[t.race.species]+=e,s.colonist+=la(c.living_quarters),_[`${Xt().red}`]=e+"v",(t.race.cataclysm||t.race.orbit_decayed)&&t.tech.home_safe){let e=c.living_quarters*Lr(t.tech.home_safe>=2?t.tech.home_safe>=3?1e5:5e4:25e3);a.Money+=e,d[F("space_red_living_quarters_title")]=e+"v"}}if(c.biodome&&(t.race.artifical||t.race.orbit_decayed)){let e=c.biodome*Lr(t.race.artifical?500:100);a.Food+=e,w[F("space_red_signal_tower_title")]=e+"v"}if(t.space.titan_quarters){let e=Math.round(c.titan_quarters*Qr.space.spc_titan.titan_quarters.citizens());a[t.race.species]+=e,s.titan_colonist+=la(c.titan_quarters),_[`${Xt().titan}`]=e+"v"}if(t.interstellar.habitat&&i.habitat){let e=i.habitat*Qr.interstellar.int_alpha.habitat.citizens();a[t.race.species]+=e,_[F("interstellar_habitat_title")]=e+"v"}if(t.interstellar.luxury_condo&&i.luxury_condo){let e=i.luxury_condo*Qr.interstellar.int_alpha.luxury_condo.citizens();a[t.race.species]+=e,_[F("tech_luxury_condo")]=e+"v";let r=i.luxury_condo*Lr(75e4);a.Money+=r,d[F("tech_luxury_condo")]=r+"v"}if(t.city.lodge){let e=t.city.lodge.count*Qr.city.lodge.citizens();a[t.race.species]+=e,_[F("city_lodge")]=e+"v"}if(t.space.outpost){let e=t.space.outpost.count*Lr(500);a.Neutronium+=e,Q[F("space_gas_moon_outpost_title")]=e+"v"}if(t.city.shed){var le=os();let e=t.tech.storage<=2?F("city_shed_title1"):t.tech.storage>=4?F("city_shed_title3"):F("city_shed_title2");for(const s of Qr.city.shed.res())if(t.resource[s].display){let i=t.city.shed.count*Lr(Qr.city.shed.val(s)*le);a[s]+=i,r.c[s][e]=i+"v"}}if(t.race.lone_survivor&&(_[F("base")]="1v",a[t.race.species]=1),t.interstellar.warehouse){le=os();let e=F("interstellar_alpha_name");for(const s of Qr.interstellar.int_alpha.warehouse.res())if(t.resource[s].display){let i=t.interstellar.warehouse.count*Lr(Qr.interstellar.int_alpha.warehouse.val(s)*le);a[s]+=i,r.c[s][e]=i+"v"}}if(t.space.storehouse){le=bt("storehouse",!1);var de=bt("storehouse",!0);let e=F("space_storehouse_title");for(const s of Qr.space.spc_titan.storehouse.res())if(t.resource[s].display){let i=Qr.space.spc_titan.storehouse.heavy(s),c=t.space.storehouse.count*Lr(Qr.space.spc_titan.storehouse.val(s)*(i?de:le));a[s]+=c,r.c[s][e]=c+"v"}}if(t.tauceti.repository){le=bt("repository");let e=F("tech_repository");for(const s of Qr.tauceti.tau_home.repository.res())if(t.resource[s].display){let i=t.tauceti.repository.count*Lr(Qr.tauceti.tau_home.repository.val(s)*le);a[s]+=i,r.c[s][e]=i+"v"}if(t.tech.isolation){let e=250;a.Containers+=t.tauceti.repository.count*e,b[F("tech_repository")]=t.tauceti.repository.count*e+"v",a.Crates+=t.tauceti.repository.count*e,y[F("tech_repository")]=t.tauceti.repository.count*e+"v"}}if(t.tech.isolation&&i.tau_farm&&t.race.artifical){let e=i.tau_farm*Lr(350);a.Food+=e,w[F("tau_home_tau_farm")]=e+"v"}if(t.galaxy.gateway_depot){let e=t.tech.world_control?150:100;a.Crates+=t.galaxy.gateway_depot.count*e,y[F("galaxy_gateway_depot")]=t.galaxy.gateway_depot.count*e+"v",a.Containers+=t.galaxy.gateway_depot.count*e,b[F("galaxy_gateway_depot")]=t.galaxy.gateway_depot.count*e+"v";let r=F("galaxy_gateway_depot"),s=Kt();if(t.resource.Uranium.display){let e=t.galaxy.gateway_depot.count*Lr(3e3*s);a.Uranium+=e,T[r]=e+"v"}if(t.resource.Nano_Tube.display){let e=t.galaxy.gateway_depot.count*Lr(25e4*s);a.Nano_Tube+=e,Y[r]=e+"v"}if(t.resource.Neutronium.display){let e=t.galaxy.gateway_depot.count*Lr(9001*s);a.Neutronium+=e,Q[r]=e+"v"}if(t.resource.Infernite.display){let e=t.galaxy.gateway_depot.count*Lr(6660*s);a.Infernite+=e,V[r]=e+"v"}if(t.resource.Elerium.display&&i.gateway_depot&&i.s_gate){let e=i.gateway_depot*Lr(200);a.Elerium+=e,J[r]=e+"v"}}if(t.resource.Infernite.display&&t.portal.fortress){let e=Lr(1e3);a.Infernite+=e,V[F("portal_fortress_name")]=e+"v"}if(t.space.garage){le=Qr.space.spc_red.garage.multiplier(!1),de=Qr.space.spc_red.garage.multiplier(!0);let e=F("space_red_garage_title");for(const s of Qr.space.spc_red.garage.res())if(t.resource[s].display){let i=Qr.space.spc_red.garage.heavy(s),c=t.space.garage.count*Lr(Qr.space.spc_red.garage.val(s)*(i?de:le));a[s]+=c,r.c[s][e]=c+"v"}}if(t.portal.harbour&&i.harbour){let e=F("portal_harbour_title");for(const s of Qr.portal.prtl_lake.harbour.res())if(t.resource[s].display){let t=i.harbour*Lr(Qr.portal.prtl_lake.harbour.val(s));a[s]+=t,r.c[s][e]=t+"v"}}if(t.city.silo){let e=cs(t.city.silo.count*Lr(500));a.Food+=e,w[F("city_silo")]=e+"v"}if(t.city.compost){let e=cs(t.city.compost.count*Lr(200));a.Food+=e,w[F("city_compost_heap")]=e+"v"}if(t.city.soul_well){let e=cs(t.city.soul_well.count*Lr(500));a.Food+=e,w[F("city_soul_well")]=e+"v"}if(t.city.smokehouse){let e=cs(t.city.smokehouse.count*Lr(100));a.Food+=e,w[F("city_smokehouse")]=e+"v"}if(t.city.oil_well){let e=t.city.oil_well.count*Lr(500);a.Oil+=e,A[F("city_oil_well")]=e+"v"}if(t.city.oil_depot){let e=t.city.oil_depot.count*Lr(1e3);e*=t.tech.world_control?1.5:1,a.Oil+=e,A[F("city_oil_depot")]=e+"v",t.tech.uranium>=2&&(e=t.city.oil_depot.count*Lr(250),e*=t.tech.world_control?1.5:1,a.Uranium+=e,T[F("city_oil_depot")]=e+"v"),t.resource.Helium_3.display&&(e=t.city.oil_depot.count*Lr(400),e*=t.tech.world_control?1.5:1,a.Helium_3+=e,G[F("city_oil_depot")]=e+"v")}if(t.space.propellant_depot){let e=t.space.propellant_depot.count*Lr(1250);e*=t.tech.world_control?1.5:1,a.Oil+=e,A[F("space_home_propellant_depot_title")]=e+"v",t.resource.Helium_3.display&&(e=t.space.propellant_depot.count*Lr(1e3),e*=t.tech.world_control?1.5:1,a.Helium_3+=e,G[F("space_home_propellant_depot_title")]=e+"v")}if(i.orbital_station){let e=i.orbital_station*Lr(15e3);a.Helium_3+=e,G[F("tau_home_orbital_station")]=e+"v"}if(i.refueling_station){let e=i.refueling_station*Lr(1e4);if(a.Helium_3+=e,G[F("tau_gas_refueling_station_title")]=e+"v",t.tech.tau_whale>=2){let e=i.refueling_station*Lr(6500);a.Oil+=e,A[F("tau_gas_refueling_station_title")]=e+"v"}}if(i.orbital_platform){let e=i.orbital_platform*Lr(17500);a.Oil+=e,A[F("tau_red_orbital_platform")]=e+"v"}if(t.space.gas_storage){let e=t.space.gas_storage.count*Lr(3500);e*=t.tech.world_control?1.5:1,a.Oil+=e,A[`${Xt().gas} ${F("depot")}`]=e+"v",e=t.space.gas_storage.count*Lr(2500),e*=t.tech.world_control?1.5:1,a.Helium_3+=e,G[`${Xt().gas} ${F("depot")}`]=e+"v",e=t.space.gas_storage.count*Lr(1e3),e*=t.tech.world_control?1.5:1,a.Uranium+=e,T[`${Xt().gas} ${F("depot")}`]=e+"v"}if(i.xfer_station){let e=i.xfer_station*Lr(5e3);if(a.Helium_3+=e,G[F("interstellar_xfer_station_title")]=e+"v",e=i.xfer_station*Lr(4e3),a.Oil+=e,A[F("interstellar_xfer_station_title")]=e+"v",e=i.xfer_station*Lr(2500),a.Uranium+=e,T[F("interstellar_xfer_station_title")]=e+"v",t.resource.Deuterium.display){let e=i.xfer_station*Lr(2e3);a.Deuterium+=e,W[F("interstellar_xfer_station_title")]=e+"v"}}if(t.space.helium_mine){let e=t.space.helium_mine.count*Lr(100);a.Helium_3+=e,G[F("space_moon_helium_mine_title")]=e+"v"}if(Kc()){let e=Lc("know");a.Knowledge+=e.add,f[F("city_shrine")]=e.add+"v"}t.city.temple&&t.genes.ancients&&t.genes.ancients>=2&&(s.priest+=la(t.city.temple.count)),t.space.ziggurat&&t.genes.ancients&&t.genes.ancients>=4&&(s.priest+=la(t.space.ziggurat.count));let U=Et("gxy_alien2");if(t.city.university){let e=Qr.city.university.knowVal()*t.city.university.count;s.professor+=la(t.city.university.count),a.Knowledge+=e,f[F("city_university")]=e+"v"}if(t.race.lone_survivor&&t.tauceti.alien_outpost&&(s.professor+=la(t.tauceti.alien_outpost.count)),t.city.library){let e=125;t.race.nearsighted&&(e*=1-ui.nearsighted.vars()[0]/100),t.race.studious&&(e*=1+ui.studious.vars()[1]/100);let r=Pi("elven");if(r>0&&(e*=1+ui.studious.vars(1)[1]/100*r),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.science&&t.tech.science>=5){let a=na(t.civic.scientist.workers,"scientist");t.race.high_pop&&(a=Me(a)),e*=1+.12*a}t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*(t.race.cataclysm||t.race.orbit_decayed?t.space.ziggurat?t.space.ziggurat.count:0:t.city.temple.count));let s=N("teacher",0);s&&(e*=1+s/100);let i=N("athleticism",2);i&&(e*=1-i/100);let c=N("muckraker",1);c&&(e*=1+c/100);let o=Math.round(t.city.library.count*e);a.Knowledge+=o,f[F("city_library")]=o+"v",t.tech.science&&t.tech.science>=3&&(t.civic.professor.impact=.5+.01*t.city.library.count)}if(t.city.wardenclyffe){let e=1e3;t.city.ptrait.includes("magnetic")&&(e+=Si.magnetic.vars()[1]);let r=t.city.wardenclyffe.count*e;s.scientist+=la(t.city.wardenclyffe.count);let c=t.tech.science>=7?1500:1e3;if(r+=i.wardenclyffe*c,t.tech.supercollider){let e=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;r*=t.tech.supercollider/e+1}t.space.satellite&&(r*=1+.04*t.space.satellite.count);let o=N("athleticism",2);if(o&&(r*=1-o/100),a.Knowledge+=r,f[Ts()]=r+"v","magic"===t.race.universe){let e=t.city.wardenclyffe.count*Lr(8);a.Mana+=e,h[Ts()]=e+"v"}if(t.race.artifical){let e=i.wardenclyffe*Lr(250);a.Food+=e,w[Ts()]=e+"v"}}if(t.race.logical){let e=t.tech.hasOwnProperty("high_tech")?t.tech.high_tech:0;e+=t.tech.hasOwnProperty("science")?t.tech.science:0;let r=t.resource[t.race.species].amount*ui.logical.vars()[1]*e;a.Knowledge+=r,f[di[t.race.species].name]=r+"v"}if(t.portal.sensor_drone){let e=i.sensor_drone*(t.tech.infernite>=6?2500:1e3);a.Knowledge+=e,f[F("portal_sensor_drone_title")]=e+"v"}if(t.space.satellite){let e=t.space.satellite.count*(t.race.cataclysm||t.race.orbit_decayed?2e3:750);if((t.race.cataclysm||t.race.orbit_decayed)&&t.tech.supercollider){let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?5:10;e*=t.tech.supercollider/a+1}a.Knowledge+=e,f[F("space_home_satellite_title")]=e+"v"}if(t.space.observatory&&t.space.observatory.count>0){let e=5e3*c.observatory;t.race.cataclysm&&t.space.satellite&&t.space.satellite.count>0&&(e*=1+.25*t.space.satellite.count),a.Knowledge+=e,f[F("space_moon_observatory_title")]=e+"v",t.race.cataclysm&&(s.professor+=la(c.observatory))}if(t.interstellar.laboratory&&o.laboratory>0){t.tech.science>=16&&(s.scientist+=la(o.laboratory));let e=1e4*o.laboratory;if(t.tech.science>=15&&(e*=1+.02*(t.race.cataclysm?c.exotic_lab:t.city.wardenclyffe.count)),t.race.cataclysm&&i.s_gate&&n.scavenger&&(e*=1+n.scavenger*Et("gxy_alien2")*.75),t.tech.science>=21&&(e*=1.45),a.Knowledge+=e,f[F("magic"===t.race.universe?"tech_sanctum":"interstellar_laboratory_title")]=e+"v","magic"===t.race.universe){let e=o.laboratory*Lr(12);a.Mana+=e,h[F("magic"===t.race.universe?"tech_sanctum":"interstellar_laboratory_title")]=e+"v"}}if(t.city.biolab){let e=3e3;t.portal.sensor_drone&&t.tech.science>=14&&(e*=1+.02*i.sensor_drone),t.tech.science>=20&&(e*=3),t.tech.science>=21&&(e*=1.45),t.tech.biotech>=1&&(e*=2.5),a.Knowledge+=i.biolab*e,f[F("city_biolab")]=i.biolab*e+"v"}if(t.space.zero_g_lab&&Math.min(c.zero_g_lab,i.zero_g_lab)>0){let e=Math.min(c.zero_g_lab,i.zero_g_lab),r=ht("spc_enceladus"),s=Math.round(1e4*e*r);if(a.Knowledge+=s,f[F("tech_zero_g_lab")]=s+"v",t.resource.Cipher.display){let t=1e4*e;a.Cipher+=t,ce[F("tech_zero_g_lab")]=t+"v"}}if(t.tech.isolation&&t.tauceti.alien_outpost&&t.resource.Cipher.display){let e=2e5;a.Cipher+=e,ce[F("tech_alien_outpost")]=e+"v"}if(t.portal.archaeology){let e=Oa("ruins"),r=25e4;t.race.high_pop&&(r=Me(r));let s=Math.round(r*e.supress);a.Knowledge+=na(t.civic.archaeologist.workers,"archaeologist")*s,f[F("portal_archaeology_bd")]=na(t.civic.archaeologist.workers,"archaeologist")*s+"v"}if(i.embassy&&t.galaxy.symposium){let e=1750*i.dormitory,r=650*t.galaxy.trade.cur,s=0;if(t.tech.xeno>=7){let e=t.galaxy.defense.gxy_gorddon.scout_ship*(Qr.galaxy.gxy_gateway.scout_ship.ship.civ()+Qr.galaxy.gxy_gateway.scout_ship.ship.mil());e+=t.galaxy.defense.gxy_gorddon.corvette_ship*(Qr.galaxy.gxy_gateway.corvette_ship.ship.civ()+Qr.galaxy.gxy_gateway.corvette_ship.ship.mil()),e+=t.galaxy.defense.gxy_gorddon.frigate_ship*(Qr.galaxy.gxy_gateway.frigate_ship.ship.civ()+Qr.galaxy.gxy_gateway.frigate_ship.ship.mil()),e+=t.galaxy.defense.gxy_gorddon.cruiser_ship*(Qr.galaxy.gxy_gateway.cruiser_ship.ship.civ()+Qr.galaxy.gxy_gateway.cruiser_ship.ship.mil()),e+=t.galaxy.defense.gxy_gorddon.dreadnought*(Qr.galaxy.gxy_gateway.dreadnought.ship.civ()+Qr.galaxy.gxy_gateway.dreadnought.ship.mil()),n.freighter&&(e+=n.freighter*(Qr.galaxy.gxy_gorddon.freighter.ship.civ()+Qr.galaxy.gxy_gorddon.freighter.ship.mil())),s=300*+Me(e).toFixed(2)}let c=(e+r+s)*i.symposium;a.Knowledge+=c,f[F("galaxy_symposium")]=c+"v"}if(t.city.bank||t.race.cataclysm&&i.spaceport){let e=t.race.cataclysm||t.race.orbit_decayed?4*Hs():Hs(),r=t.race.cataclysm||t.race.orbit_decayed?i.spaceport:t.city.bank.count,s=r*Lr(e);if(a.Money+=s,t.race.cataclysm||t.race.orbit_decayed?d[F("space_red_spaceport_title")]=s+"v":d[F("city_bank")]=s+"v",t.interstellar.exchange){let s=Lr(o.exchange*(e*r/18));t.race.inflation&&(s*=2),t.tech.banking>=13&&(t.galaxy.freighter&&(s*=1+.03*n.freighter),t.galaxy.super_freighter&&(s*=1+.08*n.super_freighter)),s=Math.round(s),a.Money+=s,d[F("interstellar_exchange_bd")]=s+"v"}}if(t.space.titan_bank){let e=2*Hs(),r=t.space.titan_bank.count*Lr(e);a.Money+=r,d[`${Xt().titan} ${F("city_bank")}`]=r+"v"}if(t.tauceti.colony&&t.tech.isolation){let e=25*Hs(),r=t.tauceti.colony.count*Lr(e);a.Money+=r,d[F("tau_home_colony")]=r+"v"}if(t.city.casino||t.space.spc_casino||t.tauceti.tauceti_casino){let e=0;t.city.casino&&t.city.casino.count>0&&(e+=t.city.casino.count),t.space.spc_casino&&t.space.spc_casino.count>0&&(e+=t.space.spc_casino.count),t.tauceti.tauceti_casino&&t.tauceti.tauceti_casino.count>0&&(e+=t.tauceti.tauceti_casino.count);let r=t.tech.gambling>=3?6e4:4e4;t.tech.gambling>=5&&(r+=t.tech.gambling>=6?24e4:6e4);let s=e*Lr(r);t.race.gambler&&(s*=1+ui.gambler.vars()[0]*t.race.gambler/100),t.tech.world_control&&(s=Math.round(1.25*s)),t.tech.stock_exchange&&t.tech.gambling>=4&&(s*=1+.05*t.tech.stock_exchange),t.race.inflation&&(s*=1+t.race.inflation/100),t.tech.isolation&&(s*=5.5),a.Money+=s,d[F("city_casino")]=s+"v"}if(t.galaxy.resort){let e=i.resort*Lr(t.tech.world_control?1875e3:15e5);a.Money+=e,d[F("galaxy_resort")]=e+"v"}if(t.tech.banking>=4){let e=250;t.tech.banking>=11?e=1e3:t.tech.banking>=6&&(e=600);let r=e*(t.resource[t.race.species].amount+t.civic.garrison.workers);t.race.high_pop&&(r=Me(r)),a.Money+=r,d[F("tech_bonds")]=r+"v"}if(i.moon_base){let e=i.moon_base*Lr(500);a.Iridium+=e,B[F("space_moon_base_title")]=e+"v"}if(i.space_station&&(s.space_miner+=la(3*i.space_station),t.tech.asteroid>=5)){let e=i.space_station*Lr(5);a.Elerium+=e,J[F("space_belt_station_title")]=e+"v"}if(c.exotic_lab){let e=c.exotic_lab*Lr(10);a.Elerium+=e,J[F("space_red_exotic_lab_bd")]=e+"v";let r=500;if(t.tech.science>=13&&t.interstellar.laboratory&&(r+=25*o.laboratory),t.tech.ancient_study&&t.tech.ancient_study>=2&&(r+=15*t.space.ziggurat.count),t.tech.mass>=2){let e=na(t.civic.scientist.workers,"scientist");t.race.high_pop&&(e=Me(e)),r+=i.mass_driver*e}t.race.cataclysm&&c.observatory&&(r*=1+.25*c.observatory),(t.race.cataclysm||t.race.orbit_decayed)&&t.portal.sensor_drone&&t.tech.science>=14&&(r*=1+.02*i.sensor_drone),t.tech.science>=21&&(r*=1.45),t.race.high_pop&&(r=Me(r));let n=c.exotic_lab*na(t.civic.colonist.workers,"colonist")*r;a.Knowledge+=n,f[F("tech_exotic_bd")]=n+"v",(t.race.cataclysm||t.race.orbit_decayed)&&(s.scientist+=la(c.exotic_lab))}if(t.tech.isolation&&c.infectious_disease_lab&&(s.professor+=la(2*c.infectious_disease_lab),s.scientist+=la(c.infectious_disease_lab)),c.decoder){let e=i.ai_colonist?na(t.civic.titan_colonist.workers,"titan_colonist")+la(i.ai_colonist):na(t.civic.titan_colonist.workers,"titan_colonist"),r=c.decoder*e*2500;t.race.high_pop&&(r=Me(r)),i.ai_core2&&(r*=1.25),a.Knowledge+=r,f[F("space_decoder_title")]=r+"v"}if(i.elerium_contain){let e=i.elerium_contain*Lr(100);a.Elerium+=e,J[F("space_dwarf_elerium_contain_title")]=e+"v"}if(t.city.foundry&&(s.craftsman+=la(t.city.foundry.count)),c.fabrication&&(s.craftsman+=la(c.fabrication),t.race.cataclysm&&(s.cement_worker+=la(c.fabrication))),t.tech.isolation&&c.tau_factory&&(s.craftsman+=la(5*c.tau_factory),s.cement_worker+=la(2*c.tau_factory)),i.womling_station&&(s.craftsman+=la(1*i.womling_station),s.cement_worker+=la(1*i.womling_station)),i.stellar_forge&&(s.craftsman+=la(2*i.stellar_forge)),t.portal.carport&&(s.hell_surveyor+=t.portal.carport.count-t.portal.carport.damaged),i.archaeology&&(s.archaeologist+=la(2*i.archaeology)),i.nexus){let e=i.nexus*Lr(4e3);a.Helium_3+=e,G[F("interstellar_nexus_title")]=e+"v";let t=i.nexus*Lr(3500);a.Oil+=t,A[F("interstellar_nexus_title")]=t+"v";let r=i.nexus*Lr(3e3);a.Deuterium+=r,W[F("interstellar_nexus_title")]=r+"v";let s=i.nexus*Lr(25);a.Elerium+=s,J[F("interstellar_nexus_title")]=s+"v"}if(i.s_gate&&t.galaxy.gateway_station){let e=i.gateway_station*Lr(2e3);a.Helium_3+=e,G[F("galaxy_gateway_station")]=e+"v";let t=i.gateway_station*Lr(4500);a.Deuterium+=t,W[F("galaxy_gateway_station")]=t+"v";let r=i.gateway_station*Lr(50);a.Elerium+=r,J[F("galaxy_gateway_station")]=r+"v"}if(i.s_gate&&i.telemetry_beacon){let e=t.tech.telemetry?1200:800;t.tech.science>=17&&(e+=25*n.scout_ship);let r=i.telemetry_beacon**2*e;a.Knowledge+=r,f[F("galaxy_telemetry_beacon_bd")]=r+"v"}if(i.s_gate&&n.scavenger){let e=n.scavenger*Math.round(25e3*U);a.Knowledge+=e,f[F("galaxy_scavenger")]=e+"v"}if(r.t_route={},t.city.market.mtrade=0,t.race.banana&&(t.city.market.mtrade++,r.t_route[F("base")]=1),t.city.trade){let e=t.race.nomadic||t.race.xenophobic?t.tech.trade:t.tech.trade+1;if(t.tech.trade&&t.tech.trade>=3&&e--,t.race.flier&&(e+=ui.flier.vars()[1]),t.city.market.mtrade+=e*t.city.trade.count,r.t_route[F("city_trade")]=e*t.city.trade.count,t.tech.fanaticism&&t.tech.fanaticism>=3){let e=t.race.cataclysm||t.race.orbit_decayed?t.space.ziggurat?t.space.ziggurat.count:0:t.city.temple.count;t.city.market.mtrade+=e,r.t_route[t.race.cataclysm?F("space_red_ziggurat_title"):F("city_temple")]=e}}if(t.city.wharf){let e=2*t.city.wharf.count;t.city.market.mtrade+=e,r.t_route[F("city_wharf")]=e}if(t.space.gps&&t.space.gps.count>=4){let e=2*t.space.gps.count;t.city.market.mtrade+=2*t.space.gps.count,r.t_route[F("space_home_gps_title")]=e}if(t.city.storage_yard&&t.tech.trade&&t.tech.trade>=3){let e=t.city.storage_yard.count;t.city.market.mtrade+=e,r.t_route[F("city_storage_yard")]=e}if(t.tech.railway){let e=0;e=t.race.cataclysm||t.race.orbit_decayed?t.space.gps?Math.floor(t.space.gps.count/3):0:t.city.storage_yard?Math.floor(t.city.storage_yard.count/6):0,t.stats.achieve.banana&&t.stats.achieve.banana.l>=2&&e++,t.city.market.mtrade+=t.tech.railway*e,r.t_route[F("arpa_projects_railway_title")]=t.tech.railway*e}if(i.titan_spaceport){let e=i.titan_spaceport*Lr(250);a.Water+=e,R[F("space_red_spaceport_title")]=e+"v"}if(t.tauceti.mining_pit&&(s.pit_miner+=la(c.mining_pit*(t.tech.isolation?6:8)),a.Materials+=1e6*c.mining_pit),t.civic.torturer.display&&t.tech.unfathomable&&t.tech.unfathomable>=2&&(s.torturer=t.city.captive_housing.count),"magic"===t.race.universe&&t.race.witch_hunter){let e=0;if(t.city.wardenclyffe){let a=t.city.wardenclyffe.count;a+=i.wardenclyffe,t.tech.roguemagic&&t.tech.roguemagic>=6&&(a/=2),g[Ts()]=a+"v",e+=a}if(t.civic.scientist.workers>0){let a=t.civic.scientist.workers;"magocracy"===t.civic.govern.type&&(a/=2),a=Me(a),g[F("job_wizard")]=a+"v",e+=a}if(t.city.coal_power&&!t.race.environmentalist){let a=i.coal_power;t.tech.roguemagic&&t.tech.roguemagic>=6&&(a/=2),g[F("city_mana_engine")]=a+"v",e+=a}if(t.city.pylon||t.space.pylon||t.tauceti.pylon){let a=0,r="city_pylon";(t.race.cataclysm||t.race.orbit_decayed)&&t.space.pylon?(a=t.space.pylon.count,r="space_red_pylon"):t.tech.isolation&&t.tauceti.pylon?(a=t.tauceti.pylon.count,r="tau_home_pylon"):t.city.pylon&&(a=t.city.pylon.count),t.tech.roguemagic&&t.tech.roguemagic>=5&&(a/=3),g[F(r)]=a+"v",e+=a}if(t.race.casting){let a=t.race.casting.total;t.tech.roguemagic&&t.tech.roguemagic>=2&&(t.tech.roguemagic>=4&&(a/=4),a-=Me(t.civic.priest.workers),a<0&&(a=0)),g[F("tech_rituals")]=a+"v",e+=a}if(t.race.totTransmute&&t.race.totTransmute>0){let a=t.race.totTransmute/5;g[F("tech_alchemy")]=a+"v",e+=a}let a=0;if(t.tech.explosives&&(a+=4),t.tech.military&&(t.tech.military>=10?a+=28:t.tech.military>=9?a+=24:t.tech.military>=8?a+=20:t.tech.military>=7?a+=16:t.tech.military>=6?a+=12:t.tech.military>=4?a+=8:t.tech.military>=3&&(a+=4)),g[F("witch_hunter_magic_tech")]=a+"v",e+=a,t.tech.roguemagic||(g[F("overt")]=5*e-e+"v",e*=5),t.tech.nexus){let a=.15*t.tech.nexus;g[F("arpa_projects_nexus_title")]=a+"v",e+=a}if(t.tech.syphon){let a=2.5*t.tech.syphon;g[F("arpa_syphon_title")]=a+"v",e+=a}if(t.portal.hasOwnProperty("soul_capacitor")){let a=i.soul_capacitor||0;t.portal.soul_capacitor.ecap=25e5*a,g[F("portal_soul_capacitor_title")]=a/3+"v",e+=a/3}if(t.tech.roguemagic&&t.tech.roguemagic>=3&&t.city.conceal_ward){let a=t.city.conceal_ward.count;t.tech.roguemagic>=8&&(a*=1.25),g[F("city_conceal_ward")]=-a+"v",e-=a}e<0&&(e=0),e=Math.floor(e),t.resource.Sus.amount=e,e>=50&&!t.race.witch_hunter_warned?(t.race.witch_hunter_warned=1,Di(F("witch_hunter_warning"),"danger",!1,["progress"])):e>=80&&t.race.witch_hunter_warned&&1===t.race.witch_hunter_warned&&(t.race.witch_hunter_warned=2,Di(F("witch_hunter_warning2"),"danger",!1,["progress"])),e>=100&&(t.civic.foreign.gov0.hstl=100,t.civic.foreign.gov1.hstl=100,t.civic.foreign.gov2.hstl=100,t.race.truepath&&(t.civic.foreign.gov3.hstl=100))}if(r.gt_route={},t.galaxy.freighter&&(r.gt_route[F("galaxy_freighter")]=2*n.freighter),t.galaxy.super_freighter&&(r.gt_route[F("galaxy_super_freighter")]=5*n.super_freighter),t.galaxy.bolognium_ship&&(s.crew+=t.galaxy.bolognium_ship.on*Qr.galaxy.gxy_gateway.bolognium_ship.ship.civ()),t.galaxy.scout_ship&&(s.crew+=t.galaxy.scout_ship.on*Qr.galaxy.gxy_gateway.scout_ship.ship.civ()),t.galaxy.corvette_ship&&(s.crew+=t.galaxy.corvette_ship.on*Qr.galaxy.gxy_gateway.corvette_ship.ship.civ()),t.galaxy.frigate_ship&&(s.crew+=t.galaxy.frigate_ship.on*Qr.galaxy.gxy_gateway.frigate_ship.ship.civ()),t.galaxy.cruiser_ship&&(s.crew+=t.galaxy.cruiser_ship.on*Qr.galaxy.gxy_gateway.cruiser_ship.ship.civ()),t.galaxy.dreadnought&&(s.crew+=t.galaxy.dreadnought.on*Qr.galaxy.gxy_gateway.dreadnought.ship.civ()),t.galaxy.freighter&&(s.crew+=t.galaxy.freighter.on*Qr.galaxy.gxy_gorddon.freighter.ship.civ()),t.galaxy.super_freighter&&(s.crew+=t.galaxy.super_freighter.on*Qr.galaxy.gxy_alien1.super_freighter.ship.civ()),t.galaxy.armed_miner&&(s.crew+=t.galaxy.armed_miner.on*Qr.galaxy.gxy_alien2.armed_miner.ship.civ()),t.galaxy.scavenger&&(s.crew+=t.galaxy.scavenger.on*Qr.galaxy.gxy_alien2.scavenger.ship.civ()),t.portal.transport&&(s.crew+=t.portal.transport.on*Qr.portal.prtl_lake.transport.ship.civ()),t.tauceti.infectious_disease_lab){let e=39616;if(t.tech.supercollider&&t.tech.isolation){let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}if(a.Knowledge+=i.infectious_disease_lab*Math.round(e),f[Qr.tauceti.tau_home.infectious_disease_lab.title()]=i.infectious_disease_lab*e+"v",t.tech.isolation){let e=c.infectious_disease_lab*Lr(375);a.Elerium+=e,J[Qr.tauceti.tau_home.infectious_disease_lab.title()]=e+"v"}}if(t.race.truepath&&t.tauceti.overseer&&t.tech.tau_red&&t.tech.tau_red>=5){let e=0,r=t.tauceti.overseer.injured,s=0,i=0,o=0;t.race.womling_friend?(i+=25+c.overseer*Qr.tauceti.tau_red.overseer.val(),s+=75+c.womling_fun*Qr.tauceti.tau_red.womling_fun.val()):t.race.womling_god?(i+=75+c.overseer*Qr.tauceti.tau_red.overseer.val(),s+=40+c.womling_fun*Qr.tauceti.tau_red.womling_fun.val()):t.race.womling_lord&&(i+=c.overseer*Qr.tauceti.tau_red.overseer.val(),s+=30+c.womling_fun*Qr.tauceti.tau_red.womling_fun.val());let n=t.tech.womling_pop&&t.tech.womling_pop>=2?6:5;e=c.womling_village*n;let l=2*c.womling_farm;l>e&&(l=e);let u=t.tech.womling_pop?8:6;t.tech.womling_gene&&(u+=2),e>l*u&&(e=l*u);let d=e-l-r,_=0;if(c.womling_lab){_=c.womling_lab,_>d&&(_=d),d-=_;let e=_*Math.round(25e3*t.tauceti.overseer.prod/100);if(a.Knowledge+=e,f[F("interstellar_laboratory_title")]=e+"v",Math.rand(0,10)=5?4.9:5;t.race.lone_survivor&&(e-=.1),t.tauceti.womling_lab.tech>=Math.round((t.tech.womling_tech+2)**e)&&(t.tech.womling_tech++,t.tauceti.womling_lab.tech=0,Di(F("tau_red_womling_advancement",[t.tech.womling_tech]),"advanced",!1,["progress"]),ms())}}let p=6*c.womling_mine;p>d&&(p=d),d-=p;let h=t.tech.tech_womling_firstaid?3:4;if(0===Math.rand(0,10)){let e=Math.rand(0,p+_);e>r&&(r=e)}else r>0&&0===Math.rand(0,h)&&r--;t.tauceti.hasOwnProperty("womling_farm")&&(t.tauceti.womling_farm.farmers=l),t.tauceti.hasOwnProperty("womling_mine")&&(t.tauceti.womling_mine.miners=p),t.tauceti.hasOwnProperty("womling_lab")&&(t.tauceti.womling_lab.scientist=_),i-=p,s-=p,s-=l,s-=r,i>100?i=100:i<0&&(i=0),s>100?s=100:s<0&&(s=0),o=Math.round((i+s)/2),t.tauceti.overseer.loyal=i,t.tauceti.overseer.morale=s,t.tauceti.overseer.pop=e,t.tauceti.overseer.working=l+p+_,t.tauceti.overseer.injured=r,t.tauceti.overseer.prod=o}["inspired","distracted","stimulated","motivated"].forEach((function(e){t.race[e]&&(t.race[e]--,t.race[e]<=0&&delete t.race[e])}));let _e=t.resource[t.race.species].amount-a[t.race.species];if(_e>0&&(t.race.orbit_decayed&&t.stats.days===t.race.orbit_decay?Di(F("tragic_death",[_e]),"danger"):(Di(F(1===_e?"abandon1":"abandon2",[_e]),"danger"),t.civic.homeless+=_e)),i.world_controller){let e=.25;t.interstellar.far_reach&&i.far_reach>0&&(e+=.01*i.far_reach),t.tech.science>=19&&(e+=.15);let r=Math.round(a.Knowledge*e);a.Knowledge+=r,f[F("space_dwarf_collider_title")]=r+"v"}if(i.alien_outpost){let e=0;t.tech.isolation&&(e=t.race.lone_survivor?35e5:65e5,a.Knowledge+=e);let r=.2,s=Math.round(a.Knowledge*r);a.Knowledge+=s,f[F("tech_alien_outpost")]=s+e+"v"}let pe=a.Crates,he=a.Containers;if(Object.keys(a).forEach((function(e){a.Crates-=t.resource[e].crates})),Object.keys(a).forEach((function(e){a.Containers-=t.resource[e].containers})),a.Crates<0){let e=0-a.Crates;Object.keys(a).forEach((function(r){if(e>0){let s=t.resource[r].crates;s>e&&(s=e),a.Crates+=s,t.resource[r].crates-=s,e-=s}}))}if(a.Containers<0){let e=0-a.Containers;Object.keys(a).forEach((function(r){if(e>0){let s=t.resource[r].containers;s>e&&(s=e),a.Containers+=s,t.resource[r].containers-=s,e-=s}}))}y[F("crates_used")]=a.Crates-pe+"v",b[F("crates_used")]=a.Containers-he+"v";let me=Or(),ge=Cr();Object.keys(a).forEach((function(e){let s=t.resource[e].crates*me;a[e]+=s;let i=t.resource[e].containers*ge;a[e]+=i,r.c[e]&&(r.c[e][F("resource_Crates_plural")]=s+"v",r.c[e][F("resource_Containers_plural")]=i+"v"),t.resource[e].max=a[e],t.resource[e].amount>t.resource[e].max&&"Sus"!=e?t.resource[e].amount=t.resource[e].max:t.resource[e].amount<0&&(t.resource[e].amount=0),t.resource[e].amount>=.99*t.resource[e].max?$(`#res${e} .count`).hasClass("has-text-warning")||$(`#res${e} .count`).addClass("has-text-warning"):$(`#res${e} .count`).hasClass("has-text-warning")&&$(`#res${e} .count`).removeClass("has-text-warning")}));let fe=!1,ve=0,ye=0;if(Object.keys(s).forEach((function(e){-1===t.civic[e].max&&t.civic[e].display&&"unemployed"!==e&&"scavenger"!==e&&ye++})),Object.keys(s).forEach((function(e){t.civic[e].max=s[e],t.civic[e].workers>t.civic[e].max&&-1!==t.civic[e].max?t.civic[e].workers=t.civic[e].max:t.civic[e].workers<0&&(t.civic[e].workers=0),t.race.servants&&(-1!==t.civic[e].max||t.race.servants.jobs.hasOwnProperty(e)||(t.race.servants.jobs[e]=0,fe=!0),t.race.servants.jobs.hasOwnProperty(e)&&(!t.civic[e].display&&("scavenger"!==e||ye>0)?t.race.servants.jobs[e]=0:ve+=t.race.servants.jobs[e],ve>t.race.servants.max&&t.race.servants.jobs[e]>0&&(t.race.servants.jobs[e]--,ve--)))})),fe?_a():t.race.servants&&(t.race.servants.force_scavenger=0===ye,t.race.servants.used=ve),t.race.servants&&t.race.servants.hasOwnProperty("smax")&&t.race.servants.smax>0){let e=0;Object.keys(t.race.servants.sjobs).forEach((function(a){t.resource[a].display||(t.race.servants.sjobs[a]=0),e+=t.race.servants.sjobs[a],e>t.race.servants.smax&&(t.race.servants.sjobs[a]-=e-t.race.servants.smax),t.race.servants.sjobs[a]<0&&(t.race.servants.sjobs[a]=0)})),t.race.servants.sused=e}if(t.civic.space_miner.display&&t.space.space_station&&(t.space.space_station.s_max=na(t.civic.space_miner.workers,"space_miner")),t.portal.hasOwnProperty("transport")){let e=0;n.transport&&(e=5*n.transport),t.portal.transport.cargo.max=e}if(t.portal.hasOwnProperty("purifier")){let e=100,a=1e4;l.base_camp&&(a*=1+.4*l.base_camp),l.port&&(e+=l.port*a),t.portal.purifier.sup_max=Math.round(e)}let be=t.race.truepath?5:3,we=t.race.blurry?2:0,$e=Pi("yeti");$e>=.25&&(we+=$e>=.5?2:1);for(let a=0;a0&&(t.civic.foreign[`gov${a}`].trn-=M.timers.mid*t.settings.gameSpeed/1e3,t.civic.foreign[`gov${a}`].trn<=0&&t.civic.foreign[`gov${a}`].spy++),t.civic.foreign[`gov${a}`].sab>0&&(t.civic.foreign[`gov${a}`].sab-=M.timers.mid*t.settings.gameSpeed/1e3,t.civic.foreign[`gov${a}`].sab<=0))switch(t.civic.foreign[`gov${a}`].act){case"influence":if(0===Math.floor(m(0,4+we)))jo(a);else{let r=Math.floor(m(t.tech.spy>=5?2:1,t.tech.spy>=5?8:6));"scorpio"===e&&(r+=H("scorpio")[1]),t.civic.foreign[`gov${a}`].hstl-=r,t.civic.foreign[`gov${a}`].hstl<0&&(t.civic.foreign[`gov${a}`].hstl=0),Di(F("civics_spy_influence_success",[ee(a),r]),"success",!1,["spy"])}break;case"sabotage":if(0===Math.floor(m(0,3+we)))jo(a);else{let r=Math.floor(m(t.tech.spy>=5?2:1,t.tech.spy>=5?8:6));"scorpio"===e&&(r+=H("scorpio")[1]),t.civic.foreign[`gov${a}`].mil-=r,t.civic.foreign[`gov${a}`].mil<50&&(t.civic.foreign[`gov${a}`].mil=50),Di(F("civics_spy_sabotage_success",[ee(a),r]),"success",!1,["spy"])}break;case"incite":if(0===Math.floor(m(0,2+Math.floor(we/2))))jo(a);else{let r=Math.floor(m(t.tech.spy>=5?2:1,t.tech.spy>=5?8:6));"scorpio"===e&&(r+=H("scorpio")[1]),t.civic.foreign[`gov${a}`].unrest+=r,t.civic.foreign[`gov${a}`].unrest>100&&(t.civic.foreign[`gov${a}`].unrest=100),Di(F("civics_spy_incite_success",[ee(a),r]),"success",!1,["spy"])}break;case"annex":if(a>=3)break;let r=!t.tech.gov_fed&&!ue();t.civic.foreign[`gov${a}`].anx=!0,Di(F("civics_spy_annex_success",[ee(a)]),"success",!1,["spy"]),r&&ms();break;case"purchase":if(a>=3)break;let s=!t.tech.gov_fed&&!ue();t.civic.foreign[`gov${a}`].buy=!0,Di(F("civics_spy_purchase_success",[ee(a)]),"success",!1,["spy"]),s&&ms()}if(t.race.banana){let e=!1,a=0;if(Object.keys(t.resource).forEach((function(r){t.resource[r].hasOwnProperty("trade")&&t.resource[r].trade<0&&(e?t.resource[r].trade=0:e=r),t.resource[r].hasOwnProperty("trade")&&t.resource[r].trade>0&&(a+=t.resource[r].trade)})),t.resource[e]&&t.resource[e].trade<=-500){let e=Yc();t.stats.banana.b4[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b4.l=!0),a>=500&&eo("banana")}}if(t.galaxy.defense){let e=["dreadnought","cruiser_ship","frigate_ship","corvette_ship","scout_ship"];for(let a=0;an[e[a]]){let i=r-n[e[a]];t.galaxy.defense[s][e[a]]-=i}t.galaxy.defense[s][e[a]]<0&&(t.galaxy.defense[s][e[a]]=0)}})),r=2&&xe.push("slave_market"),xe.forEach((function(e){if(Qr.city[e]&&Qr.city[e].cost){let a=Qr.city[e],r=$("#"+a.id);if(Cs(a)?r.hasClass("cna")&&r.removeClass("cna"):r.hasClass("cna")||r.addClass("cna"),Cs(a,!0)?r.hasClass("cnam")&&r.removeClass("cnam"):r.hasClass("cnam")||r.addClass("cnam"),t.city[e]){let r=tc(a,!1,!0);t.city[e].time=ic(r.t),t.city[e].bn=r.r}}})),Object.keys(Qr.tech).forEach((function(e){if(Qr.tech[e]&&Qr.tech[e].cost){let t=Qr.tech[e],a=$("#"+t.id);a.length>0&&(Cs(t)?a.hasClass("cna")&&a.removeClass("cna"):a.hasClass("cna")||a.addClass("cna"),Cs(t,!0)?a.hasClass("cnam")&&a.removeClass("cnam"):a.hasClass("cnam")||a.addClass("cnam"))}}));let ke=["space","interstellar","galaxy","portal","tauceti"];for(let e=0;e0&&t.city.ptrait.includes("toxic")&&(e+=Si.toxic.vars()[0]),t.arpa.sequence.labs=e,t.arpa.sequence.time-=t.arpa.sequence.boost?2*e:e,t.arpa.sequence.progress=t.arpa.sequence.max-t.arpa.sequence.time,t.arpa.sequence.time<=0){if(t.arpa.sequence.max=5e4*(1+t.race.mutation**2),t.race.adaptable){let e=1-ui.adaptable.vars()[0]/100;t.arpa.sequence.max=Math.floor(t.arpa.sequence.max*e)}if(t.arpa.sequence.progress=0,t.arpa.sequence.time=t.arpa.sequence.max,2===t.tech.genetics)Di(F("genome",[Ac("name")]),"success",!1,["progress"]),t.tech.genetics=3;else{t.race.mutation++;let e=hi(1),a=1+(t.genes.synthesis?t.genes.synthesis:0),r=2**(t.race.mutation-1)*a;t.stats.achieve.creator&&(r=Math.round(r*(1+.5*t.stats.achieve.creator.l))),t.resource.Genes.amount+=r,t.resource.Genes.display=!0;let s=t.genes.plasma?t.race.mutation:1;t.genes.plasma&&s>3&&(s=t.genes.plasma>=2?s>5?5:s:3);let i=s>1?"_plural":"";"antimatter"===t.race.universe?(i=F("resource_AntiPlasmid"+i+"_name"),t.stats.antiplasmid+=s,t.prestige.AntiPlasmid.count+=s,Xc("cross")):(i=F("resource_Plasmid"+i+"_name"),t.stats.plasmid+=s,t.prestige.Plasmid.count+=s),Oe("Crispr"),Di(F("gene_therapy",[F("trait_"+e+"_name"),r,s,i]),"success",!1,["progress"])}Oe("Genetics"),ms()}}if(t.city.foundry){let e=t.civic.craftsman.workers;(t.race.kindling_kindred||t.race.smoldering)&&t.city.foundry.Plywood>0&&(t.civic.craftsman.workers-=t.city.foundry.Plywood,t.city.foundry.crafting-=t.city.foundry.Plywood,t.city.foundry.Plywood=0);let a=Ya();Object.keys(a).forEach((function(a){for(;t.city.foundry[a]>e&&t.city.foundry[a]>0;)t.city.foundry[a]--,t.city.foundry.crafting--;e-=t.city.foundry[a]}))}3===t.tech.foundry&&(t.race.kindling_kindred||t.race.smoldering)&&(t.tech.foundry=4,ms()),(t.race.kindling_kindred||t.race.smoldering)&&(t.civic.lumberjack.workers=0,t.resource.Lumber.crates=0,t.resource.Lumber.containers=0,t.resource.Lumber.trade=0),(t.race.kindling_kindred||t.race.smoldering)&&t.city.foundry&&t.city.foundry.Plywood&&(t.city.foundry.Plywood=0),Tc("fool",2023)&&!t.race.hooved?t.resource.Horseshoe.display=!0:t.race.hooved||(t.resource.Horseshoe.display=!1),Po(!1);let qe=c.iron_ship+c.iridium_ship;if(qe>0&&t.tech.asteroid&&3===t.tech.asteroid&&Math.rand(0,250)<=qe&&(t.tech.asteroid=4,t.resource.Elerium.display=!0,Vi("Elerium",1),ms(),Di(F("discover_elerium"),"info",!1,["progress"])),t.tech.asteroid&&4===t.tech.asteroid&&0===t.resource.Elerium.amount&&Vi("Elerium",1),i.outpost>0&&t.tech.gas_moon&&1===t.tech.gas_moon&&Math.rand(0,100)<=i.outpost&&(t.space.oil_extractor={count:0,on:0},t.tech.gas_moon=2,Di(F("discover_oil",[Xt().gas_moon]),"info",!1,["progress"]),Rt()),t.portal.hasOwnProperty("mechbay")&&t.tech.hell_spire&&t.tech.hell_spire>=9){t.portal.spire.boss||Ta(),Aa();let e=0;for(let a=0;a=2&&t.portal.waygate.progress<100?e+=Ba(r,!0):e+=Ba(r,!1)}if(t.portal.hasOwnProperty("waygate")&&t.tech.hasOwnProperty("waygate")&&1===t.portal.waygate.on&&t.tech.waygate>=2&&t.portal.waygate.progress<100?(t.portal.waygate.progress+=e,t.portal.waygate.time=ic(0===e?-1:(100-t.portal.waygate.progress)/e),t.portal.spire.time=ic(-1)):(t.portal.spire.progress+=e,t.portal.spire.time=ic(0===e?-1:(100-t.portal.spire.progress)/e),t.tech.waygate&&t.tech.waygate>=2&&(t.portal.waygate.time=ic(-1))),t.portal.hasOwnProperty("waygate")&&1===t.portal.waygate.on&&t.portal.waygate.progress>=100&&(t.portal.waygate.progress=100,t.portal.waygate.on=0,t.tech.waygate=3,t.resource.Demonic_Essence.display=!0,t.resource.Demonic_Essence.amount=1,ms()),t.portal.spire.progress>=100){t.portal.spire.progress=0;let e=Number(ro()),a=e;t.genes.blood&&t.genes.blood>=2&&(a*=2),t.prestige.Blood_Stone.count+=a,t.stats.blood+=a,Oe("Blood"),t.tech.hasOwnProperty("b_stone")||(t.tech.b_stone=1,ms()),Di(`${F("portal_spire_conquest",[F(`portal_mech_boss_${t.portal.spire.boss}`),t.portal.spire.count])} ${F(1===a?"portal_spire_conquest_stone":"portal_spire_conquest_stones",[a])}`,"info",!1,["progress","hell"]),t.portal.spire.count++,t.portal.spire.count>10&&(t.tech.hell_spire=10,ms());let r=Yc();t.stats.spire.hasOwnProperty(r)||(t.stats.spire[r]={s0:0,s1:0,s2:0,s3:0,s4:0}),t.portal.spire.count>t.stats.spire[r]["s"+(e-1)]&&(t.stats.spire[r]["s"+(e-1)]=t.portal.spire.count),(!t.stats.spire[r].hasOwnProperty(t.portal.spire.boss)||e>t.stats.spire[r][t.portal.spire.boss])&&(t.stats.spire[r][t.portal.spire.boss]=e),Ta(),$a()}}if(t.race.cannibalize&&t.city.s_alter&&(t.city.s_alter.rage>0&&t.city.s_alter.rage--,t.city.s_alter.regen>0&&t.city.s_alter.regen--,t.city.s_alter.mind>0&&t.city.s_alter.mind--,t.city.s_alter.mine>0&&t.city.s_alter.mine--,t.city.s_alter.harvest>0&&t.city.s_alter.harvest--,$('#popper[data-id="city-s_alter"]').length>0&&Ps(Qr.city.s_alter,"city","s_alter")),t.race.casting){let e=0;["farmer","miner","lumberjack","science","factory","army","hunting","crafting"].forEach((function(a){t.race.casting[a]&&(e+=t.race.casting[a])})),t.race.casting.total=e}if(t.tech.r_queue&&t.r_queue.display){let e=-1,a=!1,r=!1,s=0,i=0,c={t:{t:0,rt:0},r:{},rr:{},id:{}};for(let o=0;o=l.grant[1]){t.r_queue.queue.splice(o,1),Ei(`rq${a.id}`);break}if(Cs(l,!0)){t.r_queue.queue[o].cna=!1;let u=us(n.type,!1),d=t.settings.qAny_res?tc(l):tc(l,c,!1,u);d>=0?(!r&&Cs(l)&&u?(a=l,e=o,t.settings.qAny_res&&(r=!0)):(u&&(s+=d),i+=d),!t.settings.qAny_res&&u&&(r=!0),t.r_queue.queue[o].time=u?s:i):t.r_queue.queue[o].time=d,t.r_queue.queue[o].req=!!u}else t.r_queue.queue[o].cna=!0,t.r_queue.queue[o].time=-1;t.r_queue.queue[o].qa=!!t.settings.qAny_res}e>=0&&a&&!t.r_queue.pause&&a.action()&&(Di(F("research_success",[t.r_queue.queue[e].label]),"success",!1,["queue","research_queue"]),ps(t.r_queue.queue[e].type),a.post&&a.post(),t.r_queue.queue.splice(e,1),Ei(`rq${a.id}`),Bs()),t.r_queue.queue.length>t.r_queue.max&&t.r_queue.queue.splice(t.r_queue.max);let o={},n=[];us("club",o);for(let e=0;e0)for(let e=n.length-1;e>=0;e--)t.r_queue.queue.splice(n[e],1)}t.arpa.sequence&&t.arpa.sequence.auto&&t.tech.genetics&&t.tech.genetics>=8&&Mo(),i.soul_forge&&sc({el:"#fort"},"update"),so()}if(t.tech.queue&&t.queue.display){let e=-1,a=!1,r=!1,s=["space","interstellar","galaxy","portal","tauceti"],i=0,c={t:{t:0,rt:0},r:{},rr:{},id:{}},o=!1;for(let n=0;n=0){i+=s,l.time=i;for(let e=1;e=0&&(t.settings.qAny&&!t.queue.pause&&l.time>1?He(l.type,100,!0):r||(a=u,e=n,o=!0,r=!0))}else if(Cs(u,!0)){l.cna=!1;let s=tc(u,c);if(l.bres=!1,s>=0){!r&&Cs(u)?(a=u,e=n,o=!1,t.settings.qAny&&(r=!0)):i+=s,t.settings.qAny||(r=!0),l.time=i;let d=!1;for(let e=1;e=0&&a&&!t.queue.pause){let r=!1;if(o){let r=t.queue.queue[e].label;He(t.queue.queue[e].type,100,!0,!0)&&(Di(F("build_success",[r]),"success",!1,["queue","building_queue"]),t.queue.queue[e].q>1?t.queue.queue[e].q--:(Ei(`q${a.id}${e}`),t.queue.queue.splice(e,1),Ui()))}else{let s=t.queue.queue[e].q,i=t.queue.queue[e],c=a.queue_complete?a.queue_complete():1;for(let i=0;i1?t.queue.queue[e].q--:(Ei(`q${a.id}${e}`),t.queue.queue.splice(e,1),Ui()),t.race.inflation&&t.tech.primitive&&(a.hasOwnProperty("inflation")&&!a.inflation||t.race.inflation++);r&&ys(a,i.action,i.type)}}let n=!1,l=0,u=[],d=!1;for(let e=0;et.queue.max){let a=Math.ceil(t.queue.queue[e].q/t.queue.queue[e].qs)-(l-t.queue.max);0===a?t.queue.queue.splice(e):(t.queue.queue[e].q=a*t.queue.queue[e].qs,t.queue.queue.splice(e+1))}if("merge_nearby"===t.settings.q_merge){if(n===t.queue.queue[e].id){Ei(`q${t.queue.queue[e].id}${e}`),t.queue.queue[e-1].q+=t.queue.queue[e].q,t.queue.queue.splice(e,1),Ui();break}n=t.queue.queue[e].id}else if("merge_all"===t.settings.q_merge){let a=!1;for(let r=0;r=0&&a>t.resource[r].max,i=e.attr("data-ok")?e.attr("data-ok"):"has-text-dark";t.resource[r].amount+t.resource[r].diffi&&(a-=i-e),e=i),ac&&(e-=e+a-c,ec&&(a-=e+a-c,a0&&$("#mechList").css("height",`calc(100vh - 11.5rem - ${$("#mechAssembly").height()}px)`),$("#shipList").length>0&&$("#shipList").css("height",`calc(100vh - 11.5rem - ${$("#shipPlans").height()}px)`)}();break;case"long":!function(){const a=new Date,r=U();if("protoplasm"!==t.race.species){let a=ai(),s=!1;if(Object.keys(a).forEach((function(e){a[e].l.forEach((function(t){let r=t.split(":"),i=Tt(r[0]),c="city"===r[0]?r[0]:i,o="city"===r[0]?Qr.city[r[1]]:Qr[i][r[0]][r[1]],n=$(`#pg${o.id}${e}`);a[e].s&&(0===n.length||ei(o,c,r[0],r[1])&&n.hasClass("inactive"))&&(s=!0)}))})),s&&ti(),t.tech.syphon&&t.tech.syphon>=80){M.w&&M.w.terminate();let a=$('
              ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),125),setTimeout((function(){a.addClass("b")}),150),setTimeout((function(){a.addClass("c")}),2e3),setTimeout((function(){!function(){if(t.tech.syphon>=80&&"magic"===t.race.universe){t.tech.syphon=79,t.arpa.syphon.rank=79,t.arpa.syphon.complete=99,t.queue.queue=[],t.stats.current=Date.now(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),Zi("reset",{end:"vacuum"}),Xc(`extinct_${t.race.species}`),Xc("pw_apocalypse"),t.space.hasOwnProperty("spaceport")&&0===t.space.spaceport.count&&Xc("red_dead"),t.race.modified||"balorg"!==t.race.species||Xc("pass"),t.race.junker&&"junker"===t.race.species&&eo("the_misery"),t.race.decay&&Xc("dissipated"),t.race.steelen&&eo("steelem");let a=t.race.species,r=t.race.gods,s=t.city.calendar.orbit,i=t.city.biome,c=t.city.ptrait,o=mc("vacuum");so(),t.stats.blackhole++,Fc(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),t.prestige.Dark.count=+(t.prestige.Dark.count+o.dark).toFixed(3),t.stats.dark=+(t.stats.dark+o.dark).toFixed(3),t.stats.universes++;let n=!!t.race.hasOwnProperty("srace")&&t.race.srace,l=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:"bigbang",seeded:!0,bigbang:!0,probes:4,seed:Math.floor(m(1e4)),ascended:!1},l>0&&(t.race.corruption=l),n&&(t.race.srace=n),Q({orbit:s,biome:i,ptrait:c,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}}()}),4e3)}if(t.portal.fortress&&function(){let e={start:t.portal.fortress.threat,foundGem:!1,stats:{wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}}},a=t.tech.armor?t.tech.armor:0;t.race.armored&&(a+=ui.armored.vars()[1]);let r=Pi("tortoisan");r>0&&(a+=Math.floor(ui.armored.vars(1)[1]*r)),t.race.scales&&(a+=ui.scales.vars()[2]);let s=!1;if(i.soul_forge){let e=t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size;ba()<=e?(s=!0,$("#portal-soul_forge .on").removeClass("altwarn")):(s=!1,$("#portal-soul_forge .on").addClass("altwarn"))}else $("#portal-soul_forge .on").addClass("altwarn");let c=0;if(t.tech.portal>=3&&i.war_drone){e.drones={};for(let a=0;a=Math.rand(0,999)){let a=Math.rand(Math.floor(t.portal.fortress.threat/50),Math.floor(t.portal.fortress.threat/10)),i=t.tech.portal>=7?Math.rand(50,125):Math.rand(25,75);a=5?9e3:1e4)-t.portal.fortress.pity;if("evil"===t.race.universe&&t.prestige.Dark.count>1){let e=t.prestige.Dark.count;t.prestige.Harmony.count>0&&(e*=1+.01*t.prestige.Harmony.count),o-=Math.round(2*Math.log2(e))}t.tech.portal>=4&&i.attractor&&(o=Math.round(o*.948**i.attractor)),t.race.ghostly&&(o=Math.round(o*((100-ui.ghostly.vars()[2])/100)));let n=Pi("wendigo");n>0&&(o=Math.round(o*((100-ui.ghostly.vars(1)[2])/100*n))),o<12&&(o=12);let l=0,u=i.war_droid?i.war_droid:0,p=!1,h=0;t.civic.garrison.wounded>t.civic.garrison.workers-t.portal.fortress.garrison&&(h=t.civic.garrison.wounded-(t.civic.garrison.workers-t.portal.fortress.garrison),h>t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size?(h-=t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size,h/=t.portal.fortress.patrols):h=0);let m=+(h%1).toFixed(10);e.patrols={};for(let r=0;r1/t.portal.fortress.patrols*r?Math.ceil(h):Math.floor(h);if(Math.rand(0,t.portal.fortress.threat)>=Math.rand(0,999)){c.encounter=!0;let r=t.portal.fortress.patrol_size;u>0&&(c.droid=!0,r+=t.tech.hdroid?la(2):la(1),u--);let d=Math.round(ke(r,"hellArmy",n)),_=Math.rand(Math.floor(t.portal.fortress.threat/50),Math.floor(t.portal.fortress.threat/10));t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.rand(0,Math.ceil(_/10)),t.race.blood_thirst_count>ui.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=ui.blood_thirst.vars()[0]));let h=30+Math.max(t.race.chameleon?ui.chameleon.vars()[1]:0,t.race.elusive?ui.elusive.vars()[0]:0);if(0===Math.rand(0,h)){c.ambush=!0,l+=Ma(Math.round(_*(1+3*Math.random())),0,!0,c);let e=Math.round(d/2);_0){let a=35-Math.floor(i.attractor/3);a<5&&(a=5);let s=Math.round(r/a);for(let a=0;at.civic.garrison.workers&&(t.civic.garrison.wounded=t.civic.garrison.workers);let f=t.portal.fortress.nocrew?t.civic.garrison.workers-t.civic.garrison.crew:t.civic.garrison.workers;if(f0&&"Yes"===t.portal.fortress.notify&&Di(g>0?F("fortress_patrol_casualties_revive",[l,g]):F("fortress_patrol_casualties",[l]),!1,!1,["hell"]),t.portal.fortress.garrison>0&&t.portal.fortress.siege>0&&t.portal.fortress.siege--,t.portal.fortress.siege<=900&&t.portal.fortress.garrison>0&&1>Math.rand(0,t.portal.fortress.siege)){let a={destroyed:!1,damage:0,kills:0,surveyors:0,soldiers:0},r=qa(t.portal.fortress.garrison),i=r/35>1?r/35:1,c=Math.round(t.portal.fortress.threat/2),o=0,n=0,l=!1;for(;c>0&&t.portal.fortress.walls>0;){let e=Math.round(Math.rand(1,i+1));if(e>c&&(e=c),c-=e,t.portal.fortress.threat-=e,t.stats.dkills+=e,s&&(t.portal.soul_forge.kills+=e,Pa(e)),n+=e,c>0&&(o++,t.portal.fortress.walls--,t.portal.fortress.walls<=0)){a.destroyed=!0,l=!0;break}}a.damage=o,a.kills=n,e.stats.kills.sieges=n,l?(Di(F("fortress_lost"),!1,!1,["hell"]),a.surveyors=t.civic.hell_surveyor.workers,t.resource[t.race.species].amount-=t.civic.hell_surveyor.workers,t.civic.hell_surveyor.workers=0,t.civic.hell_surveyor.assigned=0,a.soldiers=t.portal.fortress.garrison,e.stats.died+=t.portal.fortress.garrison,t.portal.fortress.patrols=0,t.stats.died+=t.portal.fortress.garrison,t.civic.garrison.workers-=t.portal.fortress.garrison,t.portal.fortress.garrison=0,t.portal.fortress.assigned=0):Di(F("fortress_sieged",[n,o]),!1,!1,["hell"]),t.portal.fortress.siege=999,e.stats.sieges++,e.siege=a}if(t.portal.fortress.threat<1e4){let a=(1e4-t.portal.fortress.threat)/2500+1;t.tech.portal>=4&&i.attractor&&(a*=1+.22*i.attractor);let r=Math.rand(Math.round(10*a),Math.round(50*a));t.portal.fortress.threat+=r,e.demons=r}if(t.civic.hell_surveyor.display&&t.civic.hell_surveyor.workers>0){let a=1e3,r=N("nopain",1);r&&(a*=1+r/100),t.race.blurry&&(a*=1+ui.blurry.vars()[0]/100);let s=Pi("yeti");s>0&&(a*=1+ui.blurry.vars(1)[0]/100*s),t.race.instinct&&(a*=1+ui.instinct.vars()[0]/100),t.tech.infernite&&t.tech.infernite>=5&&(a+=250);let n=t.portal.fortress.threat/a,l=t.civic.hell_surveyor.workers>10?10:t.civic.hell_surveyor.workers;if(n>10-Math.rand(0,l+1)){let a=Math.round(n),r=Math.rand(0,a+1);r>t.civic.hell_surveyor.workers&&(r=t.civic.hell_surveyor.workers),1===r&&"Yes"===t.portal.fortress.s_ntfy?Di(F("fortress_killed"),!1,!1,["hell"]):r>1&&"Yes"===t.portal.fortress.s_ntfy&&Di(F("fortress_eviscerated",[r]),!1,!1,["hell"]),r>0&&(e.surveyors=r,e.stats.surveyors=r,t.civic.hell_surveyor.workers-=r,t.civic.hell_surveyor.max-=r,t.resource[t.race.species].amount-=r,t.portal.carport.damaged+=r)}if(e.surveyor_finds={},t.civic.hell_surveyor.workers>0&&c>0)for(let a=0;a100&&(s=100),r.bodies=s,s>0){let a=25-Math.floor(i.attractor/5);a<5&&(a=5);let c=Math.round(s/a);for(let a=0;a=1e6&&t.tech.gateway&&!t.tech.hell_pit&&(t.tech.hell_pit=1,t.settings.portal.pit=!0,Di(F("portal_hell_pit_found"),"info",!1,["progress","hell"]),$a()),t.tech.hell_pit){if(s&&t.tech.hell_pit>=5&&i.soul_attractor){let a=t.blood.attract?5*t.blood.attract:0,r=i.soul_attractor*Math.rand(40+a,120+a);t.portal.soul_forge.kills+=r,e.soul_attractors=r,Pa(r)}if(s&&t.tech.hell_gun&&i.gun_emplacement){e.gun_emplacements={};let a=0;for(let r=0;r=2?Math.rand(35,75):Math.rand(20,40);a+=s,e.gun_emplacements[r+1].kills=s}e.stats.kills.guns=a,t.portal.soul_forge.kills+=a,Pa(a),t.stats.dkills+=a;let r=t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=5?6750:7500;t.tech.hell_pit>=7&&i.soul_attractor>0&&(r*=.94**i.soul_attractor);for(let a=0;a=5?4500:5e3;0===Math.rand(0,r)&&(e.soul_forge.gem=!0,e.stats.gems.soul_forge++,t.resource.Soul_Gem.amount++)}let a=t.tech.hell_pit>=6?75e4:1e6;if(t.tech.hell_pit>=7&&i.soul_attractor>0&&(a*=.97**i.soul_attractor),s&&t.portal.soul_forge.kills>=Math.round(a)){e.soul_forge.gem_craft=!0,t.portal.soul_forge.kills=0;let a=10-i.soul_attractor>0?10-i.soul_attractor:1;t.tech.high_tech>=16&&!t.tech.corrupt&&0===Math.rand(0,a+1)?(e.soul_forge.corrupt=!0,t.resource.Corrupt_Gem.amount++,t.resource.Corrupt_Gem.display=!0,Di(F("portal_corrupt_gem"),"info",!1,["progress","hell"]),t.tech.corrupt=1,ms()):(t.resource.Soul_Gem.amount++,e.stats.gems.crafted++)}}if(t.tech.hell_gate&&t.tech.hell_gate>=3&&s&&i.gate_turret){e.gate_turrets={};let a=0,r=t.tech.hell_gun>=2?65:40,s=t.tech.hell_gun>=2?100:60;for(let t=0;t=5?2700:3e3;for(let a=0;a0&&t.civic.govern.rev--,t.civic.govern.fr>0&&t.civic.govern.fr--,t.civic.govern.rev<0&&(t.civic.govern.rev=0),t.city.ptrait.includes("trashed")||t.race.scavenger?t.civic.scavenger.display=!0:(t.civic.scavenger.display=!1,t.civic.scavenger.workers=0),t.civic.homeless>0){let e=t.arpa.railway?t.arpa.railway.rank:0,a=Math.floor(e/(e+25)*10);Math.rand(0,10)<=a&&t.civic.homeless--}if(t.tech.currency&&t.tech.currency>=2){let e=N("risktaker",0)?2:4;Object.keys(Qa).forEach((function(a){let r=t.race.truepath?2*Qa[a]:Qa[a];if("Copper"===a&&t.tech.high_tech&&t.tech.high_tech>=2&&(r*=2),"Titanium"===a&&(t.tech.titanium&&t.tech.titanium>0?r*=t.resource.Alloy.display?1:2.5:r*=5),t.resource[a].display&&0===Math.rand(0,e)){let e=3*r,s=r/2,i=(Math.rand(0,200)-100)/100,c=t.resource[a].value+i;ce&&(c=e-r),t.resource[a].value=c}}))}if(t.race.blood_thirst&&(t.race.hasOwnProperty("blood_thirst_count")||(t.race.blood_thirst_count=1),t.race.blood_thirst_count>1&&t.race.blood_thirst_count--),t.race.truepath&&t.civic.foreign.gov3.mil<500&&0===Math.rand(0,50)&&t.civic.foreign.gov3.mil++,t.civic.garrison.wounded>0){let e=t.race.regenerative?ui.regenerative.vars()[0]:1,a=t.city.hospital?t.city.hospital.count:0;if(t.race.orbit_decayed&&t.race.truepath?a=Math.min(c.operating_base,i.operating_base):t.race.artifical&&t.city.boot_camp&&(a=t.city.boot_camp.count),t.race.rejuvenated&&t.stats.achieve.lamentis){let e=t.stats.achieve.lamentis.l;e>5&&(e=5),a+=e}"cancer"===r&&(a+=H("cancer")[0]),t.tech.medic&&t.tech.medic>=2&&(a*=t.tech.medic),t.race.fibroblast&&(a+=ui.fibroblast.vars()[0]*t.race.fibroblast),t.race.cannibalize&&t.city.s_alter&&t.city.s_alter.regen>0&&(a>=20?a*=1+ui.cannibalize.vars()[0]/100:a+=Math.floor(ui.cannibalize.vars()[0]/5));let s=Pi("mantis");s>0&&(a>=20?a*=1+ui.cannibalize.vars(1)[0]/100*s:a+=Math.floor(ui.cannibalize.vars(1)[0]/5*s)),t.race.high_pop&&(a*=ui.high_pop.vars()[2]);let o=N("nopain",0);o&&(a*=1+o/100);let n=Pi("troll");n>0&&(a+=Math.round(20*ui.regenerative.vars(1)[0]*n));let l=20;if(t.race.slow_regen&&(l*=1+ui.slow_regen.vars()[0]/100),a=Math.round(a),a>0){for(;a>=l;)e++,a-=l;Math.rand(0,a)>Math.rand(0,l)&&e++}t.civic.garrison.wounded-=e,t.civic.garrison.wounded<0&&(t.civic.garrison.wounded=0)}t.civic.garrison.fatigue&&t.civic.garrison.fatigue>0&&t.civic.garrison.fatigue--,t.civic.garrison.protest&&t.civic.garrison.protest>0&&t.civic.garrison.protest--;let o=t.tech.mercs&&t.tech.mercs>=2?3:4;if(t.civic.garrison.m_use&&t.civic.garrison.m_use>0&&0===Math.rand(0,o)&&t.civic.garrison.m_use--,t.race.rainbow_active&&t.race.rainbow_active>1&&t.race.rainbow_active--,t.city.calendar.day>0){if(t.city.calendar.day++,t.stats.days++,t.city.calendar.day>t.city.calendar.orbit&&(t.city.calendar.day=1,t.city.calendar.year++),t.race.cataclysm||t.race.orbit_decayed)t.city.calendar.season=-1;else{let e=t.city.ptrait.includes("elliptical")?6:4,a=Math.round(t.city.calendar.orbit/e),r=t.city.calendar.day,s=0;for(;r>a;)r-=a,s++;if(t.city.ptrait.includes("elliptical"))switch(s){case 0:t.city.calendar.season=0;break;case 1:case 2:t.city.calendar.season=1;break;case 3:t.city.calendar.season=2;break;default:t.city.calendar.season=3}else t.city.calendar.season=s}if(t.race.cataclysm||t.race.orbit_decayed)t.city.calendar.wind=0,t.city.calendar.temp=1,t.city.calendar.weather=-1;else if(0===Math.rand(0,5)){let e=Math.rand(0,3),a=Math.rand(0,5),r=Math.rand(0,3);switch(t.city.biome){case"oceanic":case"swamp":0===Math.rand(0,2)&&a>0&&a--;break;case"tundra":case"taiga":3===t.city.calendar.season?e=0:0===Math.rand(0,2)&&e>0&&e--;break;case"desert":0===Math.rand(0,2)&&a<4&&a++;break;case"ashland":0===Math.rand(0,2)&&(a<1?a++:a>2&&a--);case"volcanic":1===t.city.calendar.season?e=2:0===Math.rand(0,2)&&e<2&&!t.city.ptrait.includes("permafrost")&&e++}switch(t.city.calendar.season){case 0:0===Math.rand(0,3)&&a>0&&a--;break;case 1:0===Math.rand(0,3)&&e<2&&e++;break;case 2:0===Math.rand(0,3)&&r>0&&r--;break;case 3:0===Math.rand(0,3)&&e>0&&e--}if(t.city.ptrait.includes("stormy")&&r>0&&(t.race.rejuvenated||0===Math.rand(0,2))&&r--,0===a?(t.race.rainbow&&(t.race.rainbow_active=1),t.city.calendar.weather=0):a>=1&&a<=2?(t.race.rainbow&&(t.race.rainbow_active=1),t.city.calendar.weather=1):(t.race.rainbow&&0===t.city.calendar.weather&&(t.race.rainbow_active=Math.rand(10,20)),t.city.calendar.weather=2,t.race.darkness&&0===Math.rand(0,7-ui.darkness.vars()[0])&&(t.city.calendar.weather=1)),0===e){let e=t.city.calendar.temp-1;e<0&&(e=0),1===t.city.calendar.season&&0===e&&(e=1),0!==e||"hellscape"!==t.city.biome||t.city.ptrait.includes("permafrost")||(e=1),0===e&&"eden"===t.city.biome&&3!==t.city.calendar.season&&(e=1),t.city.calendar.temp=e}else if(2===e){let e=t.city.calendar.temp+1;e>2&&(e=2),3===t.city.calendar.season&&2===e&&(e=1),2===e&&"eden"===t.city.biome&&1!==t.city.calendar.season&&(e=1),t.city.calendar.temp=e}t.city.calendar.wind=0===r?1:0}2===t.city.calendar.weather?t.city.sun++:t.city.sun=0,0===t.city.calendar.temp?t.city.cold++:t.city.cold=0,2===t.city.calendar.temp?t.city.hot++:t.city.hot=0,t.race.orbit_decayed||(t.city.ptrait.includes("retrograde")?(t.city.calendar.moon--,t.city.calendar.moon<0&&(t.city.calendar.moon=27)):(t.city.calendar.moon++,t.city.calendar.moon>27&&(t.city.calendar.moon=0))),G()}if(!(t.race.cataclysm||t.race.orbit_decayed||t.race.lone_survivor||t.race.vax)){let e=Math.floor(5e7/(1+t.race.mutation))-t.stats.days;if(0===t.race.deterioration&&e<4e7){t.race.deterioration=1;let a=Math.round(e/t.city.calendar.orbit);Di(F("deterioration1",[Ac("name"),a]),"danger",!1,["progress"])}else if(1===t.race.deterioration&&e<2e7){t.race.deterioration=2;let a=Math.round(e/t.city.calendar.orbit);Di(F("deterioration2",[Ac("name"),a]),"danger",!1,["progress"])}else if(2===t.race.deterioration&&e<5e6){t.race.deterioration=3;let a=Math.round(e/t.city.calendar.orbit);Di(F("deterioration3",[Ac("name"),a]),"danger",!1,["progress"])}else if(3===t.race.deterioration&&e<1e6){t.race.deterioration=4;let a=Math.round(e/t.city.calendar.orbit);Di(F("deterioration4",[Ac("name"),a]),"danger",!1,["progress"])}else 4===t.race.deterioration&&e<=0&&(t.race.deterioration=5,t.race.decayed=t.stats.days,t.tech.decay=1,Di(F("deterioration5",[Ac("name")]),"danger",!1,["progress"]),ms())}if(t.tech.decay&&t.tech.decay>=2){let e=0;t.genes.minor.fortify&&(e+=t.genes.minor.fortify),t.race.minor.fortify&&(e+=t.race.minor.fortify),t.tech.decay>=3&&(e*=100),t.race.gene_fortify=e}else t.race.gene_fortify=0;if(!t.tech.genesis&&t.race.deterioration>=1&&t.tech.high_tech&&t.tech.high_tech>=10&&(t.tech.genesis=1,Di(F("genesis"),"special",!1,["progress"]),ms()),t.settings.cLabels&&0===$("#city-dist-outskirts").length&&hs(),!t.settings.cLabels&&$("#city-dist-outskirts").length>0&&hs(),t.tech.xeno&&t.tech.xeno>=5&&!t.tech.piracy&&0===Math.rand(0,5)&&(t.tech.piracy=1,Di(F("galaxy_piracy_msg",[di[t.galaxy.alien2.id].name]),"info",!1,["progress"]),Rt()),t.race.cheese&&(t.race.cheese--,t.race.cheese<=0&&delete t.race.cheese),t.tech.piracy&&(t.tech.piracy<1e3||t.tech.xeno>=8&&t.tech.piracy<2500||t.tech.conflict&&t.tech.piracy<5e3)&&t.tech.piracy++,t.portal.archaeology&&t.tech.hasOwnProperty("hell_ruins")&&t.tech.hell_ruins>=2&&!t.tech.hell_vault){let e=Oa("ruins"),a=25e4;t.race.high_pop&&(a=Me(a)),a=Math.round(a*e.supress)*na(t.civic.archaeologist.workers,"archaeologist")/1e3,Math.rand(0,1e4)+1<=a&&(t.tech.hell_vault=1,Di(F("portal_ruins_vault"),"info",!1,["progress"]),$a())}if(t.tech.syndicate&&t.race.truepath){let e=Dt();if(Object.keys(e).forEach((function(a){if(e[a].info.hasOwnProperty("syndicate")&&e[a].info.syndicate()){let r=e[a].info.hasOwnProperty("syndicate_cap")?e[a].info.syndicate_cap():500;t.space.syndicate.hasOwnProperty(a)||(t.space.syndicate[a]=0);let s="spc_triton"===a?5:10;t.space.syndicate[a]r&&(t.space.syndicate[a]=r)}})),t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let e=0,a=0,r=!1;t.space.shipyard.ships.forEach((function(s){if(s.transit>0&&s.fueled){s.transit--;let e=1-s.transit/s.dist,t=Math.abs(s.origin.x-s.destination.x)*e,a=Math.abs(s.origin.y-s.destination.y)*e;s.origin.x<=s.destination.x?s.xy.x=s.origin.x+t:s.xy.x=s.origin.x-t,s.origin.y<=s.destination.y?s.xy.y=s.origin.y+a:s.xy.y=s.origin.y-a}if(0===s.transit&&(s.xy=vt(s.location),s.origin=zc(s.xy),s.dist=0),s.damage>0&&i.shipyard&&s.damage--,"spc_dwarf"!==s.location&&0===Math.rand(0,10)){let e="spc_triton"===s.location?2:1;switch(s.armor){case"steel":s.damage+=Math.rand(1,8*e);break;case"alloy":s.damage+=Math.rand(1,6*e);break;case"neutronium":s.damage+=Math.rand(1,4*e)}s.damage>90&&(s.damage=90)}t.tech.hasOwnProperty("eris_scan")&&"spc_eris"===s.location&&0===s.transit&&(e+=mt(s)),t.tech.hasOwnProperty("tauceti")&&"tauceti"===s.location&&0===s.transit&&(a+=mt(s),r=s.name)})),t.tech.hasOwnProperty("eris_scan")&&t.tech.hasOwnProperty("eris")&&1===t.tech.eris&&e>50&&(t.tech.eris_scan+=e-50,t.tech.eris_scan>=100&&(t.tech.eris_scan=100,t.tech.eris=2,Di(F("space_eris_scan",[Xt().eris]),"info",!1,["progress"]),Rt())),t.tech.hasOwnProperty("tauceti")&&t.tech.tauceti>=1&&a>=1&&1===t.tech.tauceti&&(t.tauceti.orbital_station={count:0,on:0,support:0,s_max:0},t.tauceti.orbital_platform={count:0,on:0,support:0,s_max:0},t.tech.tauceti=2,t.settings.showTau=!0,t.settings.tau.home=!0,t.settings.tau.red=!0,t.settings.tau.gas=!1,t.settings.tau.roid=!1,Di(F("tau_scan",[r]),"info",!1,["progress"]),tt()),t.space.hasOwnProperty("position")&&Object.keys(gt).forEach((function(e){if(t.space.position.hasOwnProperty(e)){let a=-1===gt[e].orbit?t.city.calendar.orbit:gt[e].orbit;if(-2===a)return;0===a?t.space.position[e]=0:(t.space.position[e]+=+(360/a).toFixed(4),t.space.position[e]>=360&&(t.space.position[e]-=360))}})),$("#mapCanvas").length>0&&Mt()}t.tech.triton&&t.tech.triton>=3&&function(){if(t.space.fob){if(t.space.fob.enemy<=1e3){let e=t.tech.outer&&t.tech.outer>=4?125:100;t.space.fob.enemy+=Math.rand(25,e)}let e=Math.ceil(la(t.space.fob.enemy)/5),a=t.civic.garrison.wounded-qe();a<0&&(a=0);let r=ke(t.space.fob.troops,"army",a),s=Math.rand(0,a+1);t.civic.garrison.workers-=s,t.stats.died+=s,t.civic.garrison.wounded-=s,t.space.fob.enemy-=Math.rand(0,r),t.space.fob.enemy<0&&(t.space.fob.enemy=0);let i=Math.rand(0,t.space.fob.troops+1);if(i>e&&(i=e),t.race.armored&&(i-=la(1)),t.race.scales&&(i-=la(1)),t.tech.armor&&(i-=la(t.tech.armor)),i<0&&(i=0),t.race.revive&&s>0){let e=Math.round(Math.rand(0,s+1));t.civic.garrison.workers+=e}t.civic.garrison.wounded+=i,t.civic.garrison.wounded>qe(!1,!0)&&(t.civic.garrison.wounded=qe(!1,!0));{let e=t.civic.garrison.wounded-qe();e<0&&(e=0);let a=t.space.fob.enemy-ke(t.space.fob.troops,"army",e);a<=0&&t.space.crashed_ship.count<100?t.space.crashed_ship.count++:a>0&&t.space.crashed_ship.count>0&&t.space.crashed_ship.count--,100===t.space.crashed_ship.count&&(t.resource.Cipher.display=!0)}}}(),t.tech.eris&&t.tech.eris>=3&&function(){if(t.space.digsite){if(t.space.digsite.enemy<=1e4){let e=250;t.space.digsite.enemy+=Math.rand(25,e)}let e=ke(c.shock_trooper,"army",0);c.tank&&(e+=100*c.tank),e*=ht("spc_eris"),t.space.digsite.enemy-=Math.rand(0,e),t.space.digsite.enemy<0?t.space.digsite.enemy=0:t.space.digsite.enemy>1e4&&(t.space.digsite.enemy=1e4),t.space.digsite.count=Math.floor(100-t.space.digsite.enemy/100)}}()}if((t.stats.matrix>0||t.stats.retire>0)&&!t.race.servants&&0===Math.rand(0,25)){let e=t.stats.matrix+t.stats.retire+t.stats.eden,a=t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=5?2:0;a+=Math.min(t.stats.matrix,t.stats.retire),t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5&&ea.forEach((function(r){t.stats.achieve.overlord[r]>=5&&(a++,e+=2)})),t.race.servants={max:e,used:0,smax:a,sused:0,jobs:{},sjobs:{},force_scavenger:!1},Di(e+a===1?F("civics_servants_msg1"):F("civics_servants_msg2",[e+a]),"caution",!1,["events","major_events"])}if(t.race.truepath&&t.tech.focus_cure&&t.tech.focus_cure>=2&&t.tauceti.infectious_disease_lab)if(t.tauceti.infectious_disease_lab.cure<100){let e=(c.infectious_disease_lab||0)/100;e>1&&(e=1);let a=+Ac("curve",e).toFixed(5)/5;t.tauceti.infectious_disease_lab.cure+=a,t.tauceti.infectious_disease_lab.cure>100&&(t.tauceti.infectious_disease_lab.cure=100)}else if(t.tauceti.infectious_disease_lab.cure>=100&&2===t.tech.focus_cure)t.tech.focus_cure=3,"synthetic"===di[t.race.species].type?Di(F("tech_decode_virus_msg2s"),"info",!1,["progress"]):Di(F("tech_decode_virus_msg2"),"info",!1,["progress"]);else if(t.tech.focus_cure>=4&&t.race.hasOwnProperty("vax")){let e=t.race.artifical?t.city.boot_camp.count:t.city.hospital.count;if(t.race.orbit_decayed&&(e=Math.min(c.operating_base,i.operating_base)),4===t.tech.focus_cure&&t.race.vax<25)t.race.vax+=Math.rand(0,2*e)/150;else if(4===t.tech.focus_cure&&t.race.vax>=25)t.tech.focus_cure=5,Di(F("tech_vaccine_campaign_msg1"),"info",!1,["progress"]);else if(5===t.tech.focus_cure&&t.race.vax<50)t.race.vax+=Math.rand(0,2*e)/450;else if(5===t.tech.focus_cure&&t.race.vax<75)t.race.vax+=Math.rand(0,2*e)/1200;else if(6===t.tech.focus_cure&&t.race.vax<100){let a=1e3;t.tech.vax_p?a=250:t.tech.vax_s?a=390:t.tech.vax_f?a=25:t.tech.vax_c&&(a=125),t.race.vax+=Math.rand(0,2*e)/a}else t.race.vax>=100&&t.tech.focus_cure<=6&&(t.race.vax=100,t.tech.focus_cure=7,Di(F("tech_vaccine_campaign_msg2"),"info",!1,["progress"]),D("assemble"))}if(t.race.infiltrator){let e=t.tech.world_control?"trait_infiltrator_steal_alt":"trait_infiltrator_steal",a=ui.infiltrator.vars()[0]/100;t.resource.Knowledge.max>=Qr.tech.steel.cost.Knowledge()*a&&!t.race.steelen&&t.tech.smelting&&1===t.tech.smelting&&(Di(F(e,[F("tech_steel")]),"info",!1,["progress"]),t.resource.Steel.display=!0,t.tech.smelting=2,Ws(),ms()),t.resource.Knowledge.max>=Qr.tech.electricity.cost.Knowledge()*a&&t.tech.high_tech&&1===t.tech.high_tech&&(Di(F(e,[F("tech_electricity")]),"info",!1,["progress"]),t.tech.high_tech=2,t.city.power=0,t.city.powered=!0,t.city.coal_power={count:0,on:0},t.settings.showPowerGrid=!0,ti(),ms(),hs()),t.resource.Knowledge.max>=Qr.tech.electronics.cost.Knowledge()*a&&t.tech.high_tech&&3===t.tech.high_tech&&t.tech.titanium&&(Di(F(e,[F("tech_electronics")]),"info",!1,["progress"]),t.tech.high_tech=4,t.race.terrifying&&(t.tech.gambling=1,t.city.casino={count:0},t.space.spc_casino={count:0}),ms(),hs()),t.resource.Knowledge.max>=Qr.tech.fission.cost.Knowledge()*a&&t.tech.high_tech&&4===t.tech.high_tech&&t.tech.uranium&&(Di(F(e,[F("tech_fission")]),"info",!1,["progress"]),t.tech.high_tech=5,t.city.fission_power={count:0,on:0},ms(),hs()),t.resource.Knowledge.max>=Qr.tech.rocketry.cost.Knowledge()*a&&t.tech.high_tech&&6===t.tech.high_tech&&(Di(F(e,[F("tech_rocketry")]),"info",!1,["progress"]),t.tech.high_tech=7,t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,Di(F("civics_rival_unlocked",[ee(3)]),"info",!1,["progress","combat"])),Oe("Physics"),ms(),hs()),t.resource.Knowledge.max>=Qr.tech.artifical_intelligence.cost.Knowledge()*a&&t.tech.high_tech&&9===t.tech.high_tech&&(Di(F(e,[F("tech_artificial_intelligence")]),"info",!1,["progress"]),t.tech.high_tech=10,ms(),hs()),t.resource.Knowledge.max>=Qr.tech.quantum_computing.cost.Knowledge()*a&&t.tech.high_tech&&10===t.tech.high_tech&&t.tech.nano&&(Di(F(e,[F("tech_quantum_computing")]),"info",!1,["progress"]),t.tech.high_tech=11,ms(),hs()),t.resource.Knowledge.max>=Qr.tech[t.race.truepath?"virtual_reality_tp":"virtual_reality"].cost.Knowledge()*a&&t.tech.high_tech&&11===t.tech.high_tech&&t.tech.stanene&&(t.tech.infernite&&t.tech.alpha&&t.tech.alpha>=2||t.race.truepath)&&(Di(F(e,[F("tech_virtual_reality")]),"info",!1,["progress"]),t.tech.high_tech=12,ms(),hs()),t.race.truepath?(t.resource.Knowledge.max>=Qr.tech.quantium.cost.Knowledge()*a&&t.tech.supercollider&&t.tech.supercollider>=10&&t.tech.enceladus&&t.tech.enceladus>=3&&!t.tech.quantium&&(Di(F(e,[F("tech_quantium")]),"info",!1,["progress"]),t.tech.quantium=1,t.resource.Quantium.display=!0,ms(),ha()),t.resource.Knowledge.max>=Qr.tech.alien_biotech.cost.Knowledge()*a&&t.tech.genetics&&t.tech.genetics>=8&&t.tech.kuiper&&!t.tech.biotech&&(Di(F(e,[F("tech_alien_biotech")]),"info",!1,["progress"]),t.tech.biotech=1,ms())):(t.resource.Knowledge.max>=Qr.tech.shields.cost.Knowledge()*a&&t.tech.high_tech&&13===t.tech.high_tech&&(Di(F(e,[F("tech_shields")]),"info",!1,["progress"]),t.tech.high_tech=14,t.settings.space.neutron=!0,t.settings.space.blackhole=!0,ms(),hs()),t.resource.Knowledge.max>=Qr.tech.ai_core.cost.Knowledge()*a&&t.tech.high_tech&&14===t.tech.high_tech&&t.tech.blackhole&&t.tech.blackhole>=3&&(Di(F(e,[F("tech_ai_core")]),"info",!1,["progress"]),t.tech.high_tech=15,t.interstellar.citadel={count:0,on:0},ms(),hs()),t.resource.Knowledge.max>=Qr.tech.graphene_processing.cost.Knowledge()*a&&t.tech.ai_core&&2===t.tech.ai_core&&(Di(F(e,[F("tech_graphene_processing")]),"info",!1,["progress"]),t.tech.ai_core=3,ms()),t.resource.Knowledge.max>=Qr.tech.nanoweave.cost.Knowledge()*a&&t.tech.science&&t.tech.science>=18&&!t.tech.nanoweave&&(Di(F(e,[F("tech_nanoweave")]),"info",!1,["progress"]),t.tech.nanoweave=1,t.resource.Nanoweave.display=!0,ms(),ha()),t.resource.Knowledge.max>=Qr.tech.orichalcum_analysis.cost.Knowledge()*a&&t.tech.high_tech&&16===t.tech.high_tech&&t.tech.chthonian&&t.tech.chthonian>=3&&(Di(F(e,[F("tech_orichalcum_analysis")]),"info",!1,["progress"]),Di(F("tech_orichalcum_analysis_result"),"info",!1,["progress"]),t.tech.high_tech=17,ms(),hs()),t.resource.Knowledge.max>=Qr.tech.infernium_fuel.cost.Knowledge()*a&&t.tech.smelting&&7===t.tech.smelting&&t.tech.hell_ruins&&t.tech.hell_ruins>=4&&(Di(F(e,[F("tech_infernium_fuel")]),"info",!1,["progress"]),t.tech.smelting=8,Ws(),ms()))}let l=Pi("moldling");if(l>0){let e="trait_infiltrator_thrall",a=ui.infiltrator.vars(1)[0]/100*l;l>=.02&&t.resource.Knowledge.max>=Qr.tech.smelting.cost.Knowledge()*a&&us("smelting",!1)&&!t.tech.smelting&&(Di(F(e,[F("tech_smelting")]),"info",!1,["progress"]),t.tech.smelting=1,t.city.smelter={count:0,cap:0,Wood:0,Coal:0,Oil:0,Star:0,StarCap:0,Inferno:0,Iron:0,Steel:0,Iridium:0},t.race.steelen&&(t.tech.smelting=2),ms()),l>=.04&&t.resource.Knowledge.max>=Qr.tech.dynamite.cost.Knowledge()*a&&us("dynamite",!1)&&t.tech.explosives&&1===t.tech.explosives&&(Di(F(e,[F("tech_dynamite")]),"info",!1,["progress"]),t.tech.explosives=2,ms()),l>=.8&&t.resource.Knowledge.max>=Qr.tech.portland_cement.cost.Knowledge()*a&&us("portland_cement",!1)&&t.tech.cement&&3===t.tech.cement&&(Di(F(e,[F("tech_portland_cement")]),"info",!1,["progress"]),t.tech.cement=4,ms()),l>=.12&&t.resource.Knowledge.max>=Qr.tech.oxygen_converter.cost.Knowledge()*a&&us("oxygen_converter",!1)&&t.tech.smelting&&4===t.tech.smelting&&(Di(F(e,[F("tech_oxygen_converter")]),"info",!1,["progress"]),t.tech.smelting=5,ms()),l>=.15&&t.resource.Knowledge.max>=Qr.tech.machinery.cost.Knowledge()*a&&us("machinery",!1)&&t.tech.foundry&&6===t.tech.foundry&&(Di(F(e,[F("tech_machinery")]),"info",!1,["progress"]),t.tech.foundry=7,ms()),l>=.2&&t.resource.Knowledge.max>=Qr.tech.uranium_storage.cost.Knowledge()*a&&us("uranium_storage",!1)&&t.tech.uranium&&1===t.tech.uranium&&(Di(F(e,[F("tech_uranium_storage")]),"info",!1,["progress"]),t.tech.uranium=1,ms()),l>=.25&&t.resource.Knowledge.max>=Qr.tech.synthetic_fur.cost.Knowledge()*a&&us("synthetic_fur",!1)&&!t.tech.synthetic_fur&&(Di(F(e,[Qr.tech.synthetic_fur.title()]),"info",!1,["progress"]),t.tech.synthetic_fur=1,ms()),l>=.35&&t.resource.Knowledge.max>=Qr.tech.rover.cost.Knowledge()*a&&us("rover",!1)&&t.tech.space_explore&&1===t.tech.space_explore&&(Di(F(e,[F("tech_rover")]),"info",!1,["progress"]),t.tech.space_explore=2,t.settings.space.moon=!0,t.space.moon_base={count:0,on:0,support:0,s_max:0},ms());let r="trait_infiltrator_thrall_alt";l>=.4&&t.resource.Knowledge.max>=Qr.tech.starcharts.cost.Knowledge()*a&&us("starcharts",!1)&&t.tech.space_explore&&3===t.tech.space_explore&&(Di(F(r,[F("tech_starcharts")]),"info",!1,["progress"]),t.tech.space_explore=4,ms()),l>=.5&&t.resource.Knowledge.max>=Qr.tech.nano_tubes.cost.Knowledge()*a&&us("nano_tubes",!1)&&!t.tech.nano&&(Di(F(r,[F("tech_nano_tubes")]),"info",!1,["progress"]),t.tech.nano=1,t.resource.Nano_Tube.display=!0,ms()),t.race.truepath?(l>=.65&&t.resource.Knowledge.max>=Qr.tech.stanene_tp.cost.Knowledge()*a&&us("stanene_tp",!1)&&!t.tech.stanene&&(Di(F(r,[F("tech_stanene")]),"info",!1,["progress"]),t.tech.stanene=1,t.resource.Stanene.display=!0,ms()),l>=.8&&t.resource.Knowledge.max>=Qr.tech.anitgrav_bunk.cost.Knowledge()*a&&us("anitgrav_bunk",!1)&&t.tech.marines&&1===t.tech.marines&&(Di(F(r,[F("tech_anitgrav_bunk")]),"info",!1,["progress"]),t.tech.marines=2,ms())):(l>=.65&&t.resource.Knowledge.max>=Qr.tech.stanene.cost.Knowledge()*a&&us("stanene",!1)&&!t.tech.stanene&&(Di(F(r,[F("tech_stanene")]),"info",!1,["progress"]),t.tech.stanene=1,t.resource.Stanene.display=!0,ms()),l>=.78&&t.resource.Knowledge.max>=Qr.tech.hydroponics.cost.Knowledge()*a&&us("hydroponics",!1)&&t.tech.mars&&5===t.tech.mars&&(Di(F(r,[F("tech_hydroponics")]),"info",!1,["progress"]),t.tech.mars=6,ms()),l>=.92&&t.resource.Knowledge.max>=Qr.tech.orichalcum_panels.cost.Knowledge()*a&&us("orichalcum_panels",!1)&&t.tech.swarm&&5===t.tech.swarm&&(Di(F(r,[F("tech_orichalcum_panels")]),"info",!1,["progress"]),t.tech.swarm=6,ms()),l>=1&&t.resource.Knowledge.max>=Qr.tech.cybernetics.cost.Knowledge()*a&&us("cybernetics",!1)&&t.tech.high_tech&&17===t.tech.high_tech&&(Di(F(r,[F("tech_cybernetics")]),"info",!1,["progress"]),t.tech.high_tech=18,ms()))}t.race.truepath&&t.tech.tauceti&&3===t.tech.tauceti&&t.space.hasOwnProperty("jump_gate")&&t.tauceti.hasOwnProperty("jump_gate")&&t.space.jump_gate.count>=100&&t.tauceti.jump_gate.count>=100&&(t.tech.tauceti=4,t.resource.Materials.display=!1,t.resource.Bolognium.display=!0,Rt(),tt(),ms()),t.race.truepath&&t.tech.tauceti&&!t.race.lone_survivor?5!==t.tech.tauceti||t.tech.plague||0!==Math.rand(0,50)?t.tech.plague&&t.tech.tau_roid&&t.tech.tau_whale&&(1===t.tech.plague&&(t.tech.tau_roid>=4||t.tech.tau_whale>=2)&&0===Math.rand(0,50)?(t.tech.plague=2,t.race.quarantine=1,t.race.qDays=0,Di(F("tau_plague2",[ee(3)]),"info",!1,["progress"])):2===t.tech.plague&&t.tech.tau_roid>=5&&t.tech.tau_whale>=2&&0===Math.rand(0,50)?(t.tech.plague=3,t.race.quarantine=2,t.race.qDays=0,Di(F("tau_plague3",[ee(3),di[t.race.species].home]),"info",!1,["progress"])):t.tech.isolation?t.tech.plague<5&&0===Math.rand(0,50)&&(t.tech.plague=5,Di(F("tau_plague5b",[di[t.race.species].home]),"info",!1,["progress"]),ms()):3===t.tech.plague&&t.tech.disease&&t.tech.disease>=2&&0===Math.rand(0,50)?(t.tech.plague=4,t.race.quarantine=3,t.race.qDays=0,Di(F("tau_plague5a",[di[t.race.species].home]),"info",!1,["progress"])):4===t.tech.plague&&t.tech.disease&&t.tech.disease>=3&&0===Math.rand(0,50)&&(t.tech.plague=5,t.race.quarantine=4,t.race.qDays=0,Di(F("tau_plague5a",[di[t.race.species].home]),"info",!1,["progress"])),t.race.quarantine&&(t.race.hasOwnProperty("qDays")||(t.race.qDays=0),t.race.qDays++)):(t.tech.plague=1,Di(F("tau_plague",[ee(3)]),"info",!1,["progress"])):t.tech.tau_gas&&t.tech.tau_gas>=4&&!t.tech.plague&&t.race.lone_survivor&&(t.tech.plague=5),t.civic.govern.protest&&t.civic.govern.protest>0&&t.civic.govern.protest--,t.civic.govern.scandal&&t.civic.govern.scandal>0&&t.civic.govern.scandal--;{let e=he("tax_cap"),a=he("tax_cap",!0);t.civic.taxes.tax_rate>e?t.civic.taxes.tax_rate=e:t.civic.taxes.tax_rate0){let e=0;for(let a=0;a3&&(s=t.genes.plasma>=2?s>5?5:s:3),e+=s}t.race.p_mutation=e}!t.tech.whitehole&&t.interstellar.stellar_engine&&t.interstellar.stellar_engine.exotic>=.025?(t.tech.whitehole=1,t.tech.stablized&&delete t.tech.stablized,Di(F("interstellar_blackhole_unstable"),"danger",!1,["progress"]),ms()):t.interstellar.stellar_engine&&t.interstellar.stellar_engine.exotic>=.025&&t.tech.whitehole&&t.tech.stablized&&(delete t.tech.stablized,ms()),!t.tech.xeno&&t.galaxy.scout_ship&&t.galaxy.scout_ship.on>0&&0===Math.rand(0,10)&&(t.tech.xeno=1,t.galaxy.scout_ship.count--,t.galaxy.scout_ship.on--,t.galaxy.scout_ship.crew--,t.galaxy.scout_ship.mil--,t.resource[t.race.species].amount--,t.civic.garrison.workers--,t.civic.garrison.crew--,Di(F("galaxy_encounter"),"info",!1,["progress"]),ms()),t.galaxy.scavenger&&t.tech.conflict&&4===t.tech.conflict&&n.scavenger>0&&Math.rand(0,50)<=n.scavenger&&(t.tech.conflict=5,Di(F("galaxy_scavenger_find"),"info",!1,["progress"]),ms()),t.tech.syndicate||t.race.lone_survivor||!t.tech.outer||0!==Math.rand(0,20)||(Di(F("outer_syndicate",[ee(4)]),"info",!1,["progress"]),t.tech.syndicate=1,t.space.syndicate={}),!t.tech.corrupted_ai&&i.ai_core2&&100===wt()&&(t.tech.corrupted_ai=1,ms()),t.arpa.sequence&&t.arpa.sequence.auto&&t.tech.genetics&&7===t.tech.genetics&&Mo(),t.race.orbit_decay&&(t.race.orbit_decayed||$("#infoTimer").html("T-"+(t.race.orbit_decay-t.stats.days)),function(){if(t.race.orbit_decay&&t.stats.hasOwnProperty("days")&&t.stats.days>=t.race.orbit_decay&&!t.race.orbit_decayed){t.race.orbit_decayed=!0,Di(F("evo_challenge_orbit_decayed_msg",[di[t.race.species].home]),"info",!1,["progress"]),"magic"===t.race.universe&&(t.city.pylon&&(t.space.pylon={count:Math.ceil(t.city.pylon.count/2)}),t.race.casting&&Object.keys(t.race.casting).forEach((function(e){t.race.casting[0]=0}))),Object.keys(Qr.city).forEach((function(e){t.city.hasOwnProperty(e)&&t.city[e].hasOwnProperty("count")&&(t.race.hooved&&Qr.city[e].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Qr.city[e].cost.Horseshoe()*t.city[e].count),t.city[e].count=0,t.city[e].hasOwnProperty("on")&&(t.city[e].on=0))})),t.race.hooved&&t.race.shoecnt<5&&(t.race.shoecnt=5),t.resource.Zen.display&&(t.resource.Zen.display=!1),t.resource.Slave.display&&(t.resource.Slave.display=!1,t.resource.Slave.amount=0,D("slave")),t.race.deconstructor&&Vs.forEach((function(e){t.city.nanite_factory[e]=0})),Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),t.space.red_university={count:0},Object.keys(Qr.space.spc_moon).forEach((function(e){t.space.hasOwnProperty(e)&&t.space[e].hasOwnProperty("count")&&(t.space[e].count=0,t.space[e].hasOwnProperty("on")&&(t.space[e].on=0))})),Object.keys(ca).forEach((function(e){"colonist"!==e&&(t.civic[e].workers=0,t.civic[e].assigned=0)})),["bolognium_ship","scout_ship","corvette_ship","frigate_ship","cruiser_ship","dreadnought","freighter","super_freighter","armed_miner","scavenger"].forEach((function(e){t.galaxy[e]&&(t.galaxy[e].on=0)})),t.portal.transport&&(t.portal.transport.on=0),["forager","farmer","lumberjack","quarry_worker"].forEach((function(e){t.civic[e].display=!1})),t.civic.hunter.display?t.civic.d_job="hunter":t.civic.d_job="unemployed";for(let e of Object.values(t.race.purgatory.city))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);if(t.queue.hasOwnProperty("queue"))for(let e=t.queue.queue.length-1;e>=0;e--){let a=t.queue.queue[e];("city"===a.action||"space"===a.action&&Qr.space.spc_moon[a.type])&&t.queue.queue.splice(e,1)}t.arpa.sequence&&(t.arpa.sequence.on=!1,t.arpa.sequence.boost=!1),t.city.calendar.moon=0,document.getElementById("moon").removeAttribute("class"),$("#moon").addClass("moon wi wi-moon-new"),t.settings.spaceTabs=1,t.settings.space.moon=!1,t.settings.showCity=!1,rc($("#infoTimer")),Rt()}}()),function(){if(t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks){let e=[0,1,2];t.genes.governor>=2&&(e.push(e.length),N("organizer",0)&&e.push(e.length)),N("organizer",0)&&e.push(e.length),e.forEach((function(e){B[t.race.governor.tasks[`t${e}`]]&&B[t.race.governor.tasks[`t${e}`]].req()&&B[t.race.governor.tasks[`t${e}`]].task()}))}}()}if(!t.race.seeded||t.race.seeded&&t.race.chose){if(0===Math.rand(0,t.event.t)){let e=ho("major");if(e.length>0){let a=e[Math.floor(m(0,e.length))];Di(lo[a].effect(),"caution",!1,["events","major_events"]),t.event.l=a}t.event.t=999,"pisces"===r&&(t.event.t-=H("pisces")[0])}else t.event.t--;if("protoplasm"!==t.race.species)if(0===Math.rand(0,t.m_event.t)){let e=ho("minor");if(e.length>0){let a=e[Math.floor(m(0,e.length))];Di(lo[a].effect(),!1,!1,["events","minor_events"]),t.m_event.l=a}t.m_event.t=850,"pisces"===r&&(t.m_event.t-=H("pisces")[1])}else t.m_event.t--;if(t.race.witch_hunter&&t.resource.Sus.amount>=100){let e=300-t.resource.Sus.amount;e<1&&(e=1),0===Math.rand(0,e)&&Di(lo.witch_hunt_crusade.effect(),"caution",!1,["events","major_events"])}if(t.race.witch_hunter&&t.resource.Sus.amount>=50&&t.civic.scientist.workers>0){let e=250-2*t.resource.Sus.amount;e<50&&(e=50),0===Math.rand(0,e)&&Di(lo.witch_hunt.effect(),!1,!1,["events","minor_events"])}}11===a.getMonth()&&a.getDate()>=17&&a.getDate()<=24?(t.special.gift[`g${a.getFullYear()}`]=!0,t.tech.santa=1):delete t.tech.santa,Tc("fool")?$("body").hasClass("fool")||($("body").addClass("fool"),to({fool:!0})):$("body").hasClass("fool")&&($("body").removeClass("fool"),to()),t.stats.current=Date.now(),t.race.hasOwnProperty("geck")||e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),"protoplasm"!==t.race.species&&(t.stats.days+t.stats.tdays)%1e5==99999&&Di(F("backup_warning"),"advanced",!0),--qo<=0&&(qo=60,Zi("page_view",{page_title:"Game Loop"})),t.settings.pause&&M.s&&Ii("stop"),t.settings.at>0&&(t.settings.at-=M.timers.long*(t.settings.atMultiplier-1),t.settings.at<=0&&(t.settings.at=0,Ii("stop"),Ii("start")))}()}}),!1)),Ii("start"),Co();var $o=!0,xo=t.arpa.sequence&&t.arpa.sequence.on?t.arpa.sequence.on:0;let ko={1:1.1,2:1.25,3:1.5};var qo=60;function Mo(){if(t.resource.Knowledge.amount>=2e5&&t.resource.Knowledge.amount>=t.resource.Knowledge.max-1e4){t.resource.Knowledge.amount-=2e5;let e=t.genes.synthesis?ko[t.genes.synthesis]:1;t.resource.Genes.amount+=e}}function Po(e){if(t.tech.high_tech&&t.tech.high_tech>=11){let r=t.resource.Knowledge.max,s=25e4,c=0;for(;r>s;)r-=s,s*=1.1,c++;if(c+=+(r/s).toFixed(2),t.interstellar.citadel){let a=e?t.interstellar.citadel.on:i.citadel;t.tech.high_tech&&t.tech.high_tech>=15&&a>0&&(c*=1+.05*a)}if(t.space.ai_core2){let a=e?t.space.ai_core2.on:i.ai_core2;t.tech.titan_ai_core&&a>0&&(c*=1.25)}if(t.stats.achieve.obsolete&&t.stats.achieve.obsolete.l>=5&&t.prestige.AICore.count>0&&(c*=2-.99**t.prestige.AICore.count),t.race.linked){let e=ui.linked.vars()[0]/100*t.resource[t.race.species].amount;e>ui.linked.vars()[1]/100&&(e-=ui.linked.vars()[1]/100,e/=e+200-ui.linked.vars()[1],e+=ui.linked.vars()[1]/100),c*=1+e}a=+c.toFixed(3),u=a}var a}function Oo(){!1===t.resource.Steel.display&&0===Math.rand(0,1250)&&(t.resource.Steel.display=!0,Vi("Steel",1),Di(F("steel_sample"),"info",!1,["progress"]))}function Co(){["#resources > .resource",".tab-item > .market-item","#galaxyTrade > .market-item"].forEach((function(e){let t=!1;$(`${e}:visible`).each((function(){t?($(this).addClass("alt"),t=!1):($(this).removeClass("alt"),t=!0)}))}))}function jo(e){let a=!(!t.race.elusive&&0!==Math.floor(m(0,3))),r=Pi("satyr");if(r>0&&Math.floor(m(0,100))<=100*r&&(a=!0),!a&&t.civic.foreign[`gov${e}`].spy>0&&(t.civic.foreign[`gov${e}`].spy-=1),a||0!==Math.floor(m(0,4)))Di(F(a?"event_spy_fail":"event_spy",[ee(e)]),"danger",!1,["spy"]);else{Di(F("event_spy_sellout",[ee(e)]),"danger",!1,["spy"]);let a=t.race.mistrustful?5+ui.mistrustful.vars()[0]:5;t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(1,a)),t.civic.foreign[`gov${e}`].hstl>100&&(t.civic.foreign[`gov${e}`].hstl=100)}}P.version_check=setInterval((function(){$.ajax({url:"https://pmotschmann.github.io/Evolve/package.json",type:"GET",dataType:"json",success:function(e){e.version&&e.version!=t.version&&!t.beta&&$("#topBar .version > a").html(`${F("update_avail")} v`+t.version+bo)}})}),9e5),Ti("versionLog",function(e){let t=0;for(t=0;t=0;a--){e.append(`

              v${mo[a].version}${mo[a].hasOwnProperty("revision")?mo[a].revision:""}

              ${mo[a].date}
              `);for(let t=0;t${mo[a].changes[t]}`)}return e}($('
              ')),{wide:!0}),t.race.start_cataclysm&&t.race.start_cataclysm&&(delete t.race.start_cataclysm,Ls())})(); \ No newline at end of file diff --git a/src/governor.js b/src/governor.js index da8c9bc03a..26eb31e156 100644 --- a/src/governor.js +++ b/src/governor.js @@ -1103,10 +1103,11 @@ export const gov_tasks = { if (craft > 0){ craft = 0; } if (global.race.governor.config.trash[res] || global.interstellar.mass_ejector.hasOwnProperty(res) && global.resource[res].display && global.resource[res].max > 0 && global.interstellar.mass_ejector[res] + global.resource[res].diff > 0 && global.resource[res].amount + trade - craft >= global.resource[res].max * 0.999 - 1){ - let set = (global.resource[res].amount + trade - craft >= global.resource[res].max * 0.999 - 1) || (global.race.governor.config.trash[res] && !global.race.governor.config.trash[res].s) - ? Math.floor(global.interstellar.mass_ejector[res] + global.resource[res].diff) - : 0; - + let set = 0; + if ((global.resource[res].amount + trade - craft >= global.resource[res].max * 0.999 - 1) || (global.race.governor.config.trash[res] && !global.race.governor.config.trash[res].s)) { + const diff = Math.floor(global.resource[res].diff / global.settings.gameSpeed); + set = global.interstellar.mass_ejector[res] + diff; + } if (global.race.governor.config.trash[res] && set < global.race.governor.config.trash[res].v && global.race.governor.config.trash[res].s){ set = Math.abs(global.race.governor.config.trash[res].v); } diff --git a/wiki/wiki.js b/wiki/wiki.js index 889e38fe84..7f6fc26b82 100644 --- a/wiki/wiki.js +++ b/wiki/wiki.js @@ -1 +1 @@ -(()=>{"use strict";var e=window.localStorage,t={seed:1,warseed:1,resource:{},evolution:{},tech:{},city:{},space:{},interstellar:{},portal:{},tauceti:{},civic:{},race:{},genes:{},blood:{},stats:{start:Date.now(),days:0,tdays:0},event:{t:200,l:!1},m_event:{t:499,l:!1}},a={},r={c:{},p:{}},i={},s={},n={},c={},o={},l={},_=0;var d={},p={},u={view:"all"};const h=["all","progress","queue","building_queue","research_queue","combat","spy","events","major_events","minor_events","achievements","hell"];function m(e,a,r){return a=a||1,e=e||0,t[r?"warseed":"seed"]=(9301*t[r?"warseed":"seed"]+49297)%233280,e+t[r?"warseed":"seed"]/233280*(a-e)}Math.rand=function(e,t){return Math.floor(Math.random()*(t-e))+e},t.seed=2,t.warseed=2;{let a=e.getItem("evolved")||!1;if(a){let e=JSON.parse(LZString.decompressFromUTF16(a));e?t=e:v()}else v()}if(t.version||(t.version="0.2.0"),b(t.version)<2060&&Object.keys(t.resource).forEach((function(e){t.resource[e].crates&&(t.resource[e].crates=Math.ceil(t.resource[e].crates/5)),t.resource[e].containers&&(t.resource[e].containers=Math.ceil(t.resource[e].containers/5))})),b(t.version)<2062&&void 0!==t.civic.taxes)switch(Number(t.civic.taxes.tax_rate)){case 0:t.civic.taxes.tax_rate=0;break;case 1:t.civic.taxes.tax_rate=10;break;case 2:t.civic.taxes.tax_rate=20;break;case 3:t.civic.taxes.tax_rate=30;break;case 4:t.civic.taxes.tax_rate=40;break;case 5:t.civic.taxes.tax_rate=50}if(2062===b(t.version)&&void 0!==t.civic.taxes&&2==t.civic.taxes.tax_rate&&(t.civic.taxes.tax_rate=20),b(t.version)<2065&&void 0!==t.race&&"sporgar"===t.race.species&&(delete t.race.crafty,delete t.race.hydrophilic,t.race.infectious=1,t.race.parasite=1,!t.tech.military&&t.tech.primitive&&t.tech.primitive>=3&&(t.civic.garrison.display=!0,t.settings.showCivic=!0,t.city.garrison={count:0})),b(t.version)<3002&&t.space&&(t.tech.space&&t.tech.space>=4&&(t.space.living_quarters||(t.space.living_quarters={count:0,on:0}),t.space.garage||(t.space.garage={count:0}),t.space.red_mine||(t.space.red_mine={count:0,on:0}),t.space.fabrication||(t.space.fabrication={count:0,on:0}),t.space.laboratory||(t.space.laboratory={count:0,on:0})),t.tech.space&&t.tech.space>=3&&(t.space.iridium_mine||(t.space.iridium_mine={count:0,on:0}),t.space.helium_mine||(t.space.helium_mine={count:0,on:0})),t.tech.hell&&(t.space.geothermal||(t.space.geothermal={count:0,on:0}))),b(t.version)<3004&&t.settings&&t.settings.space&&t.settings.space.belt&&(t.space.space_station={count:0,on:0,support:0,s_max:0}),b(t.version)<4001&&t.city&&t.city.factory&&!t.city.factory.Nano&&(t.city.factory.Nano=0),b(t.version)<4003&&t.stats.achieve&&Object.keys(t.stats.achieve).forEach((function(e){t.stats.achieve[e]=1})),b(t.version)<4028&&t.stats.achieve&&t.stats.achieve.genus_demonic&&(t.stats.achieve.biome_hellscape=t.stats.achieve.genus_demonic),b(t.version)<4029&&t.race.mutation&&t.race.mutation>0){t.resource.Genes={name:"Genes",display:!0,value:0,amount:0,crates:0,diff:0,delta:0,max:-2,rate:0};for(let e=0;e=3&&(t.tech.wind_plant=1,t.tech.hunting=2);let e=["Human","Humano","Elf","Elfo","Orc","Cath","Wolven","Centaur","Centauro","Kobold","Goblin","Gnome","Ogre","Ogro","Cyclops","Ciclope","Troll","Tortoisan","Gecko","Slitheryn","Arraak","Pterodacti","Dracnid","Ent","Cacti","Sporgar","Shroomi","Mantis","Scorpid","Antid","Sharkin","Octigoran","Balorg","Imp"];for(let a=0;a0){let e=1;t.race.no_trade&&e++,t.race.no_craft&&e++,t.race.no_crispr&&e++,t.race.weak_mastery&&e++,t.stats.achieve.cross={l:e,a:e}}if(b(t.version)<7e3&&(t.civic.govern||(t.civic.govern={type:"oligarchy",rev:0,fr:0})),b(t.version)<7004&&t.queue&&t.queue.queue)for(let e=0;e0&&(t.stats.harmony=parseFloat(t.stats.harmony.toFixed(2)),t.race.Harmony.count=parseFloat(t.race.Harmony.count.toFixed(2))),b(t.version)<8017&&t.city.garrison&&(t.city.garrison.on=t.city.garrison.count),b(t.version)<9005&&t.race.hasOwnProperty("terrifying")&&t.tech.hasOwnProperty("gambling")&&!t.space.hasOwnProperty("spc_casino")&&(t.space.spc_casino={count:0,on:0}),b(t.version)<9009&&t.genes.hasOwnProperty("ancients")&&t.genes.ancients>=3&&(4===t.genes.ancients?t.genes.ancients=5:t.race.Plasmid.count+=300),b(t.version)<9010&&(["species","gods","old_gods"].forEach((e=>{"orge"===t.race[e]&&(t.race[e]="ogre")})),t.stats.hasOwnProperty("achieve")&&t.stats.achieve.hasOwnProperty("extinct_orge")&&(t.stats.achieve.extinct_ogre=t.stats.achieve.extinct_orge,delete t.stats.achieve.extinct_orge),t.resource.hasOwnProperty("orge")&&(t.resource.ogre=t.resource.orge,delete t.resource.orge),t.city&&t.city.factory&&!t.city.factory.Furs&&(t.city.factory.Furs=0)),b(t.version)<9014&&(["seraph","unicorn","custom"].forEach((e=>{t.race.species===e&&("custom"===e&&t.hasOwnProperty("custom")&&"angelic"===t.custom.race0.genus||"custom"!==e)&&(t.race.holy=1)})),t.hasOwnProperty("arpa")&&t.arpa.hasOwnProperty("sequence")&&(t.arpa.sequence.labs=0)),b(t.version)<1e5&&(delete t.city.lumber,delete t.city.stone,t.stats.dark=0,t.race.Dark&&(t.stats.dark=t.race.Dark.count),t.city.hasOwnProperty("smelter")&&(t.city.smelter.hasOwnProperty("Star")||(t.city.smelter.Star=0),t.city.smelter.hasOwnProperty("StarCap")||(t.city.smelter.StarCap=0),t.city.smelter.hasOwnProperty("Inferno")||(t.city.smelter.Inferno=0)),t.hasOwnProperty("warseed")||(t.warseed=t.seed+1,Math.war=t.hasOwnProperty("warseed")?t.warseed:t.seed),t.portal.hasOwnProperty("bireme")&&(t.portal.bireme.crew=0,t.portal.bireme.mil=0),t.portal.hasOwnProperty("transport")&&(t.portal.transport.crew=0,t.portal.transport.mil=0,t.portal.transport.cargo||(t.portal.transport.cargo={used:0,max:0,Crystal:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0})),t.hasOwnProperty("settings")&&t.settings.portal&&t.settings.portal.spire&&!t.portal.hasOwnProperty("purifier")&&(t.settings.portal.spire=!1),t.portal.hasOwnProperty("mechbay")&&!Array.isArray(t.portal.mechbay.mechs)&&(t.portal.mechbay.mechs=[]),t.portal.transport&&t.portal.transport.count>=1&&!t.tech.hell_spire&&(t.tech.hell_spire=1,t.settings.portal.spire=!0,t.settings.showCargo=!0,t.portal.purifier={count:0,on:0,support:0,s_max:0,supply:0,sup_max:100,diff:0},t.portal.port={count:0,on:0}),t.tech.hasOwnProperty("waygate")&&!t.portal.hasOwnProperty("waygate")&&delete t.tech.waygate,t.hasOwnProperty("blood")||(t.blood={})),b(t.version)<100013&&t.hasOwnProperty("settings")&&t.settings.hasOwnProperty("showPowerGrid")&&t.hasOwnProperty("race")&&t.race.infiltrator&&t.hasOwnProperty("tech")&&t.tech.hasOwnProperty("high_tech")&&t.tech.high_tech>=2&&(t.settings.showPowerGrid=!0),b(t.version)<100014&&(t.race.Dark&&(t.stats.dark=t.race.Dark.count),t.race.casting&&t.race.evil&&(t.race.casting.total-=t.race.casting.lumberjack,t.race.casting.lumberjack=0),t.queue&&t.queue.queue))for(let e=0;e=2,events:!0,major_events:!0,minor_events:!0,achievements:t.stats.achieve&&Object.keys(t.stats.achieve).length>0||t.stats.feat&&Object.keys(t.stats.feat).length>0,hell:t.settings.showPortal||t.stats.blackhole||t.stats.ascend||t.stats.descend}),t.race.hasOwnProperty("inflation")&&["supercollider","stock_exchange","launch_facility","monuments","railway","roid_eject","nexus","syphon"].forEach((function(e){t.tech.hasOwnProperty(e)&&(t.race.inflation+=10*t.tech[e])}))),b(t.version)<101012&&t.civic.garrison&&(t.civic.garrison.rate=0),b(t.version)<101014&&(t.hasOwnProperty("settings")&&t.settings.hasOwnProperty("msgFilters")&&Object.keys(t.settings.msgFilters).forEach((function(e){t.settings.msgFilters[e]={unlocked:!!t.settings.msgFilters[e],vis:!!t.settings.msgFilters[e],max:60,save:3}})),t.hasOwnProperty("lastMsg")&&t.lastMsg)){let e={};h.forEach((function(t){e[t]=[]})),t.lastMsg.forEach((function(t){t.t?t.t.forEach((function(a){e[a].push({m:t.m,c:t.c})})):e.all.push({m:t.m,c:t.c})})),t.lastMsg=e}if(b(t.version)<=101014&&!t.revision&&t.race.cataclysm&&t.race.universe&&"magic"===t.race.universe&&t.tech.magic&&t.tech.magic>=2&&(t.space.pylon={count:0}),b(t.version)<101015&&t.hasOwnProperty("special")&&t.special.hasOwnProperty("trick")&&(t.special.trick[2020]=JSON.parse(JSON.stringify(t.special.trick)),delete t.special.trick.trick1,delete t.special.trick.trick2,delete t.special.trick.trick3,delete t.special.trick.trick4,delete t.special.trick.trick5,delete t.special.trick.trick6,delete t.special.trick.trick7,delete t.special.trick.trick8,delete t.special.trick.trick9,delete t.special.trick.trick10,delete t.special.trick.trick11,delete t.special.trick.trick12),b(t.version)<102e3&&(t.hasOwnProperty("portal")&&t.portal.hasOwnProperty("fortress")&&!t.portal.fortress.hasOwnProperty("nocrew")&&(t.portal.fortress.nocrew=!1),t.city.hasOwnProperty("smelter")&&!t.city.smelter.hasOwnProperty("Iridium")&&(t.city.smelter.Iridium=0),t.hasOwnProperty("portal")&&t.portal.hasOwnProperty("mechbay")&&!t.portal.mechbay.hasOwnProperty("active")&&(t.portal.mechbay.active=0,t.portal.mechbay.scouts=0)),b(t.version)<102001&&(t.race.blood_thirst&&t.race.blood_thirst>3&&(t.race.blood_thirst=1),t.race.rainbow&&t.race.rainbow>3&&(t.race.rainbow=1)),b(t.version)<102005&&!t.stats.cores&&t.race.hasOwnProperty("AICore")&&(t.stats.cores=t.race.AICore.count),b(t.version)<102006&&t.race.artifical&&(t.race.calm&&(t.resource.hasOwnProperty("Zen")&&(t.resource.Zen.display=!0),t.city.meditation={count:0}),t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0})),b(t.version)<102007&&t.stats.hasOwnProperty("achieve")&&delete t.stats.achieve.extinct_sludge,b(t.version)<102012&&(t.city.hasOwnProperty("ptrait")&&(t.city.ptrait="none"===t.city.ptrait?[]:[t.city.ptrait]),t.tech.hell_ruins&&t.tech.hell_ruins>=3&&(t.tech.hell_vault=1)),b(t.version)<102015){if(t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks"))for(let e in t.race.governor.tasks)"asssemble"===t.race.governor.tasks[e]&&(t.race.governor.tasks[e]="assemble");t.settings&&t.settings.hasOwnProperty("restoreCheck")&&delete t.settings.restoreCheck}if(b(t.version)<102017&&(t.portal.hasOwnProperty("fortress")&&(t.portal.observe={settings:{expanded:!1,average:!1,hyperSlow:!1,display:"game_days",dropKills:!0,dropGems:!0},stats:{total:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0}},period:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0}}},graphID:0,graphs:{}}),t.tech.hasOwnProperty("genetics")&&t.tech.genetics>1&&t.hasOwnProperty("arpa")&&(t.arpa.hasOwnProperty("sequence")||(t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!1}),t.arpa.sequence.boost||(t.arpa.sequence.boost=!1),t.arpa.sequence.auto||(t.arpa.sequence.auto=!1),t.arpa.sequence.labs||(t.arpa.sequence.labs=0))),b(t.version)<102021&&t.hasOwnProperty("custom")&&!t.custom.hasOwnProperty("race0")){let e=t.race.hasOwnProperty("species")?t.race.species:"protoplasm";t.galaxy.hasOwnProperty("alien1")&&"custom"===t.galaxy.alien1.id&&(t.galaxy.alien1.id="human"===e?"elven":"human"),t.galaxy.hasOwnProperty("alien2")&&"custom"===t.galaxy.alien2.id&&(t.galaxy.alien2.id="orc"===e||"orc"===t.galaxy.alien1.id?"cath":"orc")}function g(){["reset","plasmid","antiplasmid","universes","phage","starved","tstarved","died","tdied","sac","tsac","know","tknow","portals","dkills","attacks","cfood","tfood","cstone","tstone","clumber","tlumber","mad","bioseed","cataclysm","blackhole","ascend","descend","terraform","aiappoc","matrix","retire","eden","geck","dark","harmony","blood","cores","artifact","cattle","tcattle","murders","tmurders","psykill","tpsykill"].forEach((function(e){t.stats.hasOwnProperty(e)||(t.stats[e]=0)})),t.stats.achieve||(t.stats.achieve={}),t.stats.feat||(t.stats.feat={}),t.stats.hasOwnProperty("womling")||(t.stats.womling={god:{l:0},lord:{l:0},friend:{l:0}}),t.stats.spire||(t.stats.spire={}),t.stats.synth||(t.stats.synth={}),t.stats.hasOwnProperty("banana")||(t.stats.banana={b1:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b2:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b3:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b4:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b5:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1}})}if(b(t.version)<103e3&&(t.hasOwnProperty("tauceti")||(t.tauceti={}),"protoplasm"===t.race.species&&(t.evolution.hasOwnProperty("sexual_reproduction")&&(t.tech.evo=t.evolution.sexual_reproduction.count>0?2:1,delete t.evolution.sexual_reproduction),[["phagocytosis",{evo:3,evo_animal:1}],["chloroplasts",{evo:3,evo_plant:1}],["chitin",{evo:3,evo_fungi:1}],["exterminate",{evo:7,evo_synthetic:2}],["multicellular",{evo:4}],["spores",{evo:5}],["poikilohydric",{evo:5}],["bilateral_symmetry",{evo:5,evo_insectoid:1,evo_mammals:1,evo_eggshell:1,evo_aquatic:1,evo_fey:1,evo_sand:1,evo_heat:1,evo_polar:1}],["bryophyte",{evo:7}],["athropods",{evo:7,evo_insectoid:2}],["mammals",{evo:6,evo_humanoid:1,evo_giant:1,evo_small:1,evo_animalism:1,evo_demonic:1,evo_angelic:1}],["humanoid",{evo:7,evo_humanoid:2}],["gigantism",{evo:7,evo_giant:2}],["dwarfism",{evo:7,evo_small:2}],["animalism",{evo:7,evo_animalism:2}],["carnivore",{evo_animalism:3,evo_carnivore:2}],["herbivore",{evo_animalism:3,evo_herbivore:2}],["omnivore",{evo_animalism:3,evo_omnivore:2}],["celestial",{evo:7,evo_angelic:2}],["demonic",{evo:7,evo_demonic:2}],["aquatic",{evo:7,evo_aquatic:2}],["fey",{evo:7,evo_fey:2}],["heat",{evo:7,evo_heat:2}],["polar",{evo:7,evo_polar:2}],["sand",{evo:7,evo_sand:2}],["eggshell",{evo:6,evo_eggshell:2}],["endothermic",{evo:7,evo_avian:2}],["ectothermic",{evo:7,evo_reptilian:2}],["bunker",{evo_challenge:1}]].forEach((function(e){if(t.evolution.hasOwnProperty(e[0])&&t.evolution[e[0]].count>0)for(let[a,r]of Object.entries(e[1]))t.tech[a]=r;delete t.evolution[e[0]]})),t.evolution.mloaded=1,t.evolution.gmloaded=1)),b(t.version)<103001&&(t.hasOwnProperty("prestige")||(t.prestige={}),t.race.Plasmid&&t.race.Plasmid.hasOwnProperty("anti")&&(t.prestige.AntiPlasmid={count:t.race.Plasmid.anti}),["Plasmid","Phage","AICore","Dark","Harmony"].forEach((function(e){t.race.hasOwnProperty(e)&&(t.prestige[e]={count:t.race[e].count},delete t.race[e])})),["Artifact","Blood_Stone"].forEach((function(e){t.resource.hasOwnProperty(e)&&(t.prestige[e]={count:t.resource[e].amount},delete t.resource[e])})),!t.stats.hasOwnProperty("synth")&&t.race.hasOwnProperty("srace")&&(t.stats.synth={},t.stats.synth[t.race.srace]=!0),t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("config")&&t.race.governor.config.hasOwnProperty("trash")&&["Infernite","Elerium","Copper","Iron"].forEach((function(e){t.race.governor.config.trash.hasOwnProperty(e)&&"number"==typeof t.race.governor.config.trash[e]&&(t.race.governor.config.trash[e]={v:t.race.governor.config.trash[e],s:!0})}))),b(t.version)<103002&&t.portal.hasOwnProperty("observe")&&t.portal.observe.hasOwnProperty("stats")&&(t.portal.observe.stats.period.gems.surveyors=0,t.portal.observe.stats.total.gems.surveyors=0),t.version="1.3.8",t.revision="a",delete t.beta,t.hasOwnProperty("prestige")||(t.prestige={}),["Plasmid","AntiPlasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone"].forEach((function(e){t.prestige.hasOwnProperty(e)||(t.prestige[e]={count:0})})),t.hasOwnProperty("power")||(t.power=[]),t.hasOwnProperty("support")||(t.support={}),["moon","red","belt","alpha","nebula","gateway","alien2","lake","spire","titan","enceladus","eris","tau_home","tau_red","tau_roid"].forEach((function(e){t.support.hasOwnProperty(e)||(t.support[e]=[])})),t.civic.cement_worker&&.25===t.civic.cement_worker.impact&&(t.civic.cement_worker.impact=.4),t.settings||(t.settings={showEvolve:!0,showAchieve:!1,animated:!0,disableReset:!1,font:"standard",q_merge:"merge_nearby",cLabels:!0,theme:"gruvboxDark",locale:"en-US",icon:"star"}),t.settings.space||(t.settings.space={}),t.settings.space.hasOwnProperty("home")||(t.settings.space.home=!0),M(!1),t.settings.icon||(t.settings.icon="star"),t.settings.showResources||(t.settings.showResources=t.settings.showMarket),t.settings.showStorage||(t.city.warehouse||t.city.storage_yard?t.settings.showStorage=!0:t.settings.showStorage=!1),t.settings.hasOwnProperty("touch")||(t.settings.touch=!1),t.settings.hasOwnProperty("lowPowerBalance")||(t.settings.lowPowerBalance=!1),t.queue||(t.queue={display:!1,queue:[]}),t.r_queue||(t.r_queue={display:!1,queue:[]}),t.queue.rename||(t.queue.rename=!1),t.queue.max||(t.queue.max=0),t.r_queue.max||(t.r_queue.max=0),t.queue.pause||(t.queue.pause=!1),t.r_queue.pause||(t.r_queue.pause=!1),t.lastMsg||(t.lastMsg={}),t.settings.msgFilters||(t.settings.msgFilters={}),["all","progress","events","major_events","minor_events"].forEach((function(e){t.settings.msgFilters[e]||(t.settings.msgFilters[e]={unlocked:!0,vis:!0,max:60,save:3})})),h.forEach((function(e){t.lastMsg[e]||(t.lastMsg[e]=[]),t.settings.msgFilters[e]||(t.settings.msgFilters[e]={unlocked:!1,vis:!1,max:60,save:3})})),t.settings.msgQueueHeight||(t.settings.msgQueueHeight=$("#msgQueue").outerHeight(),t.settings.buildQueueHeight=$("#buildQueue").outerHeight()),t.space||(t.space={}),t.starDock||(t.starDock={}),t.interstellar||(t.interstellar={}),t.galaxy||(t.galaxy={}),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Bolognium&&(t.interstellar.mass_ejector.Bolognium=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Vitreloy&&(t.interstellar.mass_ejector.Vitreloy=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Orichalcum&&(t.interstellar.mass_ejector.Orichalcum=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Nanoweave&&(t.interstellar.mass_ejector.Nanoweave=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Scarletite&&(t.interstellar.mass_ejector.Scarletite=0),t.hasOwnProperty("pillars")||(t.pillars={}),t.settings.space.alpha||(t.settings.space.alpha=!1,t.settings.space.proxima=!1,t.settings.space.nebula=!1,t.settings.space.neutron=!1,t.settings.space.blackhole=!1),t.settings.showAchieve||(t.settings.showAchieve=!1),t.settings.locale||(t.settings.locale="en-us"),void 0===t.settings.pause&&(t.settings.pause=!1),void 0===t.settings.mKeys&&(t.settings.mKeys=!0),void 0===t.settings.keyMap&&(t.settings.keyMap={x10:"Control",x25:"Shift",x100:"Alt",q:"q"}),void 0===t.settings.keyMap.showCiv&&(t.settings.keyMap.showCiv="1",t.settings.keyMap.showCivic="2",t.settings.keyMap.showResearch="3",t.settings.keyMap.showResources="4",t.settings.keyMap.showGenetics="5",t.settings.keyMap.showAchieve="6",t.settings.keyMap.settings="7"),delete t.settings.keyMap.d,void 0===t.settings.qAny&&(t.settings.qAny=!1),void 0===t.settings.sPackOn&&(t.settings.sPackOn=!0),void 0===t.settings.qAny_res&&(t.settings.qAny_res=!1),void 0===t.settings.sPackMsg&&(t.settings.sPackMsg=!1),void 0===t.settings.expose&&(t.settings.expose=!1),void 0===t.settings.tabLoad&&(t.settings.tabLoad=!1),void 0===t.settings.boring&&(t.settings.boring=!1),t.settings.hasOwnProperty("mtorder")||(t.settings.mtorder=[]),g(),t.race.seeded||(t.race.seeded=!1),t.race.deterioration||(t.race.deterioration=0),t.race.gene_fortify||(t.race.gene_fortify=0),t.race.old_gods||(t.race.old_gods="none"),t.race.universe||(t.race.universe="standard"),t.genes.minor||(t.genes.minor={}),t.race.minor||(t.race.minor={}),t.hasOwnProperty("govern")||(t.govern={governor:{},candidate:[],policy:{}}),t.settings.hasOwnProperty("showMil")||(t.settings.showMil=!0),t.settings.hasOwnProperty("showPowerGrid")||(t.settings.showPowerGrid=!!(t.hasOwnProperty("tech")&&t.tech.hasOwnProperty("high_tech")&&t.tech.high_tech>=2)),t.settings.affix||(t.settings.affix="si"),t.special||(t.special={}),t.special.gift||(t.special.gift={}),t.special.hasOwnProperty("egg")||(t.special.egg={}),t.special.hasOwnProperty("trick")||(t.special.trick={trick1:!1,trick2:!1,trick3:!1,trick4:!1,trick5:!1,trick6:!1,trick7:!1,trick8:!1,trick9:!1,trick10:!1,trick11:!1,trick12:!1}),t.civic.govern||(t.civic.govern={type:"oligarchy",rev:2e3,fr:0}),t.civic.govern.fr=0,t.hasOwnProperty("custom")||(t.custom={}),t.custom.hasOwnProperty("planet")&&t.custom.planet.hasOwnProperty("biome")&&delete t.custom.planet,t.city.hasOwnProperty("smelter")&&!t.city.smelter.hasOwnProperty("cap")&&(t.city.smelter.cap=0),t.civic.homeless||(t.civic.homeless=0),t.civic.foreign||(t.civic.foreign={gov0:{unrest:0,hstl:100,mil:100,eco:75,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov1:{unrest:0,hstl:0,mil:150,eco:100,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov2:{unrest:0,hstl:50,mil:250,eco:150,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1}}),void 0===t.civic.foreign.gov0.trn&&(t.civic.foreign.gov0.trn=0,t.civic.foreign.gov1.trn=0,t.civic.foreign.gov2.trn=0,t.civic.foreign.gov0.sab=0,t.civic.foreign.gov1.sab=0,t.civic.foreign.gov2.sab=0,t.civic.foreign.gov0.act="none",t.civic.foreign.gov1.act="none",t.civic.foreign.gov2.act="none"),void 0!==t.civic.foreign.gov0.name&&"evo_organism_title"===t.civic.foreign.gov0.name.s1&&(t.civic.foreign.gov0.name.s1="Northern"),void 0!==t.civic.foreign.gov1.name&&"evo_organism_title"===t.civic.foreign.gov1.name.s1&&(t.civic.foreign.gov1.name.s1="Southern"),void 0!==t.civic.foreign.gov2.name&&"evo_organism_title"===t.civic.foreign.gov2.name.s1&&(t.civic.foreign.gov2.name.s1="Divine"),!t.race.evil&&t.race.immoral&&void 0!==t.race&&"wendigo"!==t.race.species)delete t.race.immoral;else if(void 0!==t.race&&"wendigo"===t.race.species){const e=new Date;t.settings.hasOwnProperty("boring")&&!t.settings.boring&&11===e.getMonth()&&e.getDate()>=17&&(t.race.immoral=3)}if(t.hasOwnProperty("special")&&t.special.hasOwnProperty("gift")){const e=new Date(t.stats.start),a=new Date;Object.keys(t.special.gift).forEach((function(r){let i=Number(r.substring(1,5));(i=1?t.civic.d_job="farmer":t.civic.d_job="unemployed"),t.settings.animated=!0,t.settings.disableReset=!1,t.arpa&&t.arpa.launch_facility&&t.arpa.launch_facility.rank>0&&!t.tech.space&&(t.tech.space=1);var f={x10:!1,x25:!1,x100:!1,q:!1};function y(){let e=1;return t.settings.mKeys&&(f.x10&&(e*=10),f.x25&&(e*=25),f.x100&&(e*=100)),e}function b(e){let t=e.split(".",3);return t[0]*=1e5,t[1]*=1e3,Number(t[0])+Number(t[1])+Number(t[2])}function w(){if($(window).width()>=1400&&$("#msgQueue:not(.right)")){let e=$("#buildQueue").detach();e.addClass("right"),e.removeClass("has-text-info");let t=$("#msgQueue").detach();t.addClass("right"),t.removeClass("has-text-info"),t.css("resize","none"),$("#queueColumn").addClass("is-one-quarter"),$("#queueColumn").append(e),$("#queueColumn").append(t),$("#mainColumn").removeClass("is-three-quarters"),$("#mainColumn").addClass("is-half")}else if($(window).width()<1400&&$("#msgQueue").hasClass("right")){let e=$("#buildQueue").detach();e.removeClass("right"),e.addClass("has-text-info");let t=$("#msgQueue").detach();t.removeClass("right"),t.addClass("has-text-info"),t.css("resize","vertical"),$("#queueColumn").removeClass("is-one-quarter"),$("#sideQueue").append(e),$("#sideQueue").append(t),$("#mainColumn").removeClass("is-half"),$("#mainColumn").addClass("is-three-quarters")}}var k={si:["K","M","G","T","P","E","Z","Y"],sci:["e3","e6","e9","e12","e15","e18","e21","e24"],sln:["K","M","B","t","q","Q","s","S"]};function x(e,a,r){let i=0,s="",n=e<0;return n&&(e*=-1),e<=9999?i=+e.toFixed(a):e<1e6?(s=k[t.settings.affix][0],i=r?+(e/1e3).toFixed(1):Math.floor(e/100)/10):e<1e9?(s=k[t.settings.affix][1],i=r?+(e/1e6).toFixed(1):Math.floor(e/1e4)/100):e<1e12?(s=k[t.settings.affix][2],i=r?+(e/1e9).toFixed(1):Math.floor(e/1e7)/100):e<1e15?(s=k[t.settings.affix][3],i=r?+(e/1e12).toFixed(1):Math.floor(e/1e10)/100):e<1e18?(s=k[t.settings.affix][4],i=r?+(e/1e15).toFixed(1):Math.floor(e/1e13)/100):e<1e21?(s=k[t.settings.affix][5],i=r?+(e/1e18).toFixed(1):Math.floor(e/1e16)/100):e<1e24?(s=k[t.settings.affix][6],i=r?+(e/1e21).toFixed(1):Math.floor(e/1e19)/100):(s=k[t.settings.affix][7],i=r?+(e/1e24).toFixed(1):Math.floor(e/1e22)/100),i>=100&&(i=+i.toFixed(1)),n&&(i*=-1),i+s}function q(e,t){var a=document.createElement("div"),r="speak-"+Date.now();a.setAttribute("id",r),a.setAttribute("aria-live",t||"polite"),a.classList.add("sr-only"),document.body.appendChild(a),window.setTimeout((function(){document.getElementById(r).innerHTML=e}),100),window.setTimeout((function(){document.body.removeChild(document.getElementById(r))}),1e3)}$(window).resize((function(){w()})),window.soft_reset=function(a){try{a=a&&"replicator"===a?"replicator":"soft",gtag("event","reset",{end:a})}catch(e){}a||O();let r=!!t.race.hasOwnProperty("srace")&&t.race.srace,i=t.race.hasOwnProperty("geck")?t.race.geck:0;t.race.hasOwnProperty("gecked")&&(i+=t.race.gecked,t.stats.geck-=t.race.gecked);let s={species:"protoplasm",universe:t.race.universe,seeded:t.race.seeded,probes:t.race.probes,seed:t.race.seed,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended,rejuvenated:!!t.race.hasOwnProperty("rejuvenated")&&t.race.rejuvenated};i>0&&(s.geck=i),r&&(s.srace=r),t.race.bigbang&&(s.bigbang=!0),t.race.gods&&(s.gods=t.race.gods),t.race.old_gods&&(s.old_gods=t.race.old_gods),t.race.rapid_mutation&&t.race.rapid_mutation>0&&(s.rapid_mutation=t.race.rapid_mutation),t.race.ancient_ruins&&t.race.ancient_ruins>0&&(s.ancient_ruins=t.race.ancient_ruins),t.race.bigbang&&(s.universe="bigbang"),t.race.hasOwnProperty("corruption")&&(s.corruption=t.race.corruption),t.race=s;let n=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,l=t.city.geology;t.city={calendar:{day:0,year:0,weather:2,temp:1,moon:0,wind:0,orbit:n},biome:c,ptrait:o,geology:l},t.tech.theology&&t.tech.theology>=1?t.tech={theology:1}:t.tech={},S(),t.new=!0,t.seed=Math.rand(0,1e4),t.warseed=Math.rand(0,1e4),t.stats.current=Date.now(),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()};var P={w:!1,s:!1,timers:{},resetTimers(){this.timers={main:250,mid:1e3,long:5e3}}},j={};function O(){h.forEach((function(e){"achievements"!==e&&(t.lastMsg[e]=[])}))}function M(e){let a={base:["showCiv","showCity","showIndustry","showPowerGrid","showMechLab","showShipYard","showResearch","showCivic","showMil","showResources","showMarket","showStorage","showGenetics","showSpace","showDeep","showGalactic","showPortal","showOuter","showTau","showEjector","showCargo","showAlchemy","showGovernor","arpa","showPsychic"],space:["moon","red","hell","sun","gas","gas_moon","belt","dwarf","alpha","proxima","nebula","neutron","blackhole","sirius","stargate","gateway","gorddon","alien1","alien2","chthonian","titan","enceladus","triton","eris","kuiper"],portal:["fortress","badlands","pit","ruins","gate","lake","spire"],tau:["home","red","roid","gas","gas2","star"]};Object.keys(a).forEach((function(r){"base"===r?a[r].forEach((function(a){t.settings.hasOwnProperty(a)&&!e||(t.settings[a]=!1)})):(t.settings.hasOwnProperty(r)||(t.settings[r]={}),a[r].forEach((function(a){t.settings[r].hasOwnProperty(a)&&!e||(t.settings[r][a]=!1)})))})),["civTabs","govTabs","govTabs2","hellTabs","resTabs","spaceTabs","marketTabs","statsTabs"].forEach((function(a){t.settings.hasOwnProperty(a)&&!e||(t.settings[a]=0)}))}function S(){P.w&&P.w.terminate(),t.queue={display:!1,queue:[]},t.r_queue={display:!1,queue:[]},t.space={},t.interstellar={},t.galaxy={},t.portal={},t.starDock={},t.tauceti={},t.civic={new:0},t.civic.foreign={gov0:{unrest:0,hstl:Math.floor(m(80,100)),mil:Math.floor(m(75,125)),eco:Math.floor(m(60,90)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov1:{unrest:0,hstl:Math.floor(m(0,20)),mil:Math.floor(m(125,175)),eco:Math.floor(m(80,120)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov2:{unrest:0,hstl:Math.floor(m(40,60)),mil:Math.floor(m(200,300)),eco:Math.floor(m(130,170)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1}},t.genes.blood||(t.prestige.Blood_Stone.count=0),t.resource={},t.evolution={},t.event={t:100,l:!1},t.m_event={t:499,l:!1},t.stats.days=0,t.stats.know=0,t.stats.starved=0,t.stats.died=0,t.stats.attacks=0,t.stats.dkills=0,t.stats.cfood=0,t.stats.cstone=0,t.stats.clumber=0,t.stats.sac=0,t.stats.cattle=0,t.stats.murders=0,t.settings.at=0,t.settings.showEvolve=!0,t.settings.space.home=!0,M(!0),t.settings.disableReset=!1,t.settings.pause=!1,t.arpa={},delete t.race.hrt,t.genes.queue&&(t.tech.queue=1,t.queue.display=!0)}let C;function z(e,a){let r=C[e];if(!r)return t.settings.expose&&(console.error(`string ${e} not found`),console.log(C)),e;if(a)if(a instanceof Array){for(let i=0;i{r=e})),"en-US"!=a){let e;try{$.getJSON(`strings/strings.${a}.json`,(t=>{e=t}))}catch(e){console.error(e,e.stack)}const i=r.length;e&&Object.assign(r,e),r.length!=i&&t.settings.expose&&console.error(`string.${a}.json has extra keys.`)}let i=e.getItem("string_pack")||!1;if(i&&t.settings.sPackOn){let e;try{e=JSON.parse(LZString.decompressFromUTF16(i))}catch(e){console.error(e,e.stack)}const a=r.length;e&&Object.assign(r,e),r.length!=a&&t.settings.expose&&console.error("string pack has extra keys.")}$.ajaxSetup({async:!0}),C=r}(t.settings.locale);const F={soldier:{name:z("governor_soldier"),desc:z("governor_soldier_desc"),title:[z("governor_soldier_t1"),z("governor_soldier_t2"),z("governor_soldier_t3")],traits:{tactician:1,militant:1}},criminal:{name:z("governor_criminal"),desc:z("governor_criminal_desc"),title:[z("governor_criminal_t1"),z("governor_criminal_t2"),{m:z("governor_criminal_t3m"),f:z("governor_criminal_t3f")}],traits:{noquestions:1,racketeer:1}},entrepreneur:{name:z("governor_entrepreneur"),desc:z("governor_entrepreneur_desc"),title:[z("governor_entrepreneur_t1"),z("governor_entrepreneur_t2"),{m:z("governor_entrepreneur_t3m"),f:z("governor_entrepreneur_t3f")}],traits:{dealmaker:1,risktaker:1}},educator:{name:z("governor_educator"),desc:z("governor_educator_desc"),title:[z("governor_educator_t1"),z("governor_educator_t2"),z("governor_educator_t3")],traits:{teacher:1,theorist:1}},spiritual:{name:z("governor_spiritual"),desc:z("governor_spiritual_desc"),title:[z("governor_spiritual_t1"),z("governor_spiritual_t2"),z("governor_spiritual_t3")],traits:{inspirational:1,pious:1}},bluecollar:{name:z("governor_bluecollar"),desc:z("governor_bluecollar_desc"),title:[{m:z("governor_bluecollar_t1m"),f:z("governor_bluecollar_t1f")},z("governor_bluecollar_t2"),{m:z("governor_bluecollar_t3m"),f:z("governor_bluecollar_t3f")}],traits:{pragmatist:1,dirty_jobs:1}},noble:{name:z("governor_noble"),desc:z("governor_noble_desc"),title:[{m:z("governor_noble_t1m"),f:z("governor_noble_t1f")},{m:z("governor_noble_t2m"),f:z("governor_noble_t2f")},{m:z("governor_noble_t3m"),f:z("governor_noble_t3f")},{m:z("governor_noble_t4m"),f:z("governor_noble_t4f")}],traits:{extravagant:1,aristocrat:1}},media:{name:z("governor_media"),desc:z("governor_media_desc"),title:[z("governor_media_t1"),{m:z("governor_media_t2m"),f:z("governor_media_t2f")},z("governor_media_t3")],traits:{gaslighter:1,muckraker:1}},sports:{name:z("governor_sports"),desc:z("governor_sports_desc"),title:[z("governor_sports_t1"),z("governor_sports_t2"),z("governor_sports_t3")],traits:{athleticism:1,nopain:1}},bureaucrat:{name:z("governor_bureaucrat"),desc:z("governor_bureaucrat_desc"),title:[z("governor_bureaucrat_t1"),{m:z("governor_bureaucrat_t2m"),f:z("governor_bureaucrat_t2f")},z("governor_bureaucrat_t3")],traits:{organizer:1}}},A={tactician:{name:z("gov_trait_tactician"),effect(){return z("gov_trait_tactician_effect",[$(this)[0].vars()[0]])},vars:()=>[25]},militant:{name:z("gov_trait_militant"),effect(){return z("gov_trait_militant_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[25,10]},noquestions:{name:z("gov_trait_noquestions"),effect(){return z("gov_trait_noquestions_effect",[$(this)[0].vars()[0]])},vars:()=>[.005]},racketeer:{name:z("gov_trait_racketeer"),effect(){return z("gov_trait_racketeer_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[20,35]},dealmaker:{name:z("gov_trait_dealmaker"),effect(){return z("gov_trait_dealmaker_effect",[$(this)[0].vars()[0]])},vars:()=>[125]},risktaker:{name:z("gov_trait_risktaker"),effect(){return z("gov_trait_risktaker_effect",[$(this)[0].vars()[0]])},vars:()=>[12]},teacher:{name:z("gov_trait_teacher"),effect(){return z("gov_trait_teacher_effect",[$(this)[0].vars()[0]])},vars:()=>[6]},theorist:{name:z("gov_trait_theorist"),effect(){return z("gov_trait_theorist_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,4]},inspirational:{name:z("gov_trait_inspirational"),effect(){return z("gov_trait_inspirational_effect",[$(this)[0].vars()[0]])},vars:()=>[20]},pious:{name:z("gov_trait_pious"),effect(){let e=$(this)[0].vars()[1],a=t.tech.monument&&t.tech.monument>=3&&s.s_gate?3:1;return e=("corpocracy"===t.civic.govern.type?2*e:e)*a,z("gov_trait_pious_effect",[$(this)[0].vars()[0],e])},vars:()=>[10,5]},pragmatist:{name:z("gov_trait_pragmatist"),effect(){return z("gov_trait_pragmatist_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,2]},dirty_jobs:{name:z("gov_trait_dirty_jobs"),effect(){return z("gov_trait_dirty_jobs_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[.015,1,10]},extravagant:{name:z("gov_trait_extravagant"),effect(){return z("gov_trait_extravagant_effect",[$(this)[0].vars()[0],pi("large",!0),$(this)[0].vars()[1],$(this)[0].vars()[2]+5])},vars:()=>[10,1.25,1]},aristocrat:{name:z("gov_trait_aristocrat"),effect(){return z("gov_trait_aristocrat_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[50,20,10]},gaslighter:{name:z("gov_trait_gaslighter"),effect(){return z("gov_trait_gaslighter_effect",[$(this)[0].vars()[0],_i(),$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[1,1,.5]},muckraker:{name:z("gov_trait_muckraker"),effect(){return z("gov_trait_muckraker_effect",[$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[8,12,3]},athleticism:{name:z("gov_trait_athleticism"),effect(){return z("gov_trait_athleticism_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2],_i()])},vars:()=>[1.5,2,4]},nopain:{name:z("gov_trait_nopain"),effect(){return z("gov_trait_nopain_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,10]},organizer:{name:z("gov_trait_organizer"),effect(){return z("gov_trait_organizer_effect",[$(this)[0].vars()[0]])},vars:()=>[t.genes.governor&&t.genes.governor>=2?2:1]}},I={humanoid:["Sanders","Smith","Geddon","Burgundy","Cristo","Crunch","Berg","Morros","Bower","Maximus"],carnivore:["Instinct","Prowl","Paws","Fluffy","Snarl","Claws","Fang","Stalker","Pounce","Sniff"],herbivore:["Sense","Grazer","Paws","Fluffy","Fern","Claws","Fang","Grass","Stampy","Sniff"],omnivore:["Pelt","Munchy","Paws","Fluffy","Snarl","Claws","Fang","Skavers","Pounce","Sniff"],small:["Bahgins","Banks","Shorty","Parte","Underfoot","Shrimp","Finkle","Littlefoot","Cub","Runt"],giant:["Slender","Titan","Colossus","Bean","Tower","Cloud","Bigfoot","Mountain","Crusher","Megaton"],reptilian:["Scale","Chimera","Ecto","Bask","Forks","Croc","Slither","Sunny","Coldfoot","Webtoe"],avian:["Sparrow","Soar","Shiney","Raven","Squaks","Eddy","Breeze","Flap","Kettle","Flock"],insectoid:["Compound","Centi","Hiver","Buzz","Carpace","Swarm","Devour","Carpi","Chitter","Burrow"],plant:["Grover","Blossom","Leaf","Sapper","Stem","Seed","Sprout","Greensly","Root","Fruit"],fungi:["Detritus","Psychedelic","Cap","Rotface","Patch","Spore","Infecto","Filament","Symbiote","Shade"],aquatic:["Seawolf","Finsley","Inko","Sucker","McBoatFace","Wave","Riptide","Shell","Coral","Pearl"],fey:["Whisper","Prank","Mischief","Flutter","Nature","Dirt","Story","Booker","Tales","Spirit"],heat:["Ash","Magnus","Pumice","Vulcano","Sweat","Flame","Lava","Ember","Smoke","Tinder","Spark"],polar:["Frosty","Snowball","Flake","Chiller","Frost","Cooler","Icecube","Arctic","Tundra","Avalanche"],sand:["Dune","Oasis","Sarlac","Spice","Quick","Grain","Spike","Storm","Glass","Castle"],demonic:["Yekun","Kesabel","Gadreel","Penemue","Abaddon","Azazyel","Leviathan","Samyaza","Kasyade","Typhon"],angelic:["Lightbringer","Illuminous","Sparks","Chrub","Halo","Star","Pompous","Radiant","Fluffy","Fabio"],synthetic:["HK47","D2R2","Bishop","Wally","Number5","Sunny","Data","Beta","Dot","Motoko"],eldritch:["Tentacle","Faceless","Horror","Darkness","Void","Dreamer","Mindflayer","Whisper","Paranoia","Empty"]};function T(e){let a=[],r=Ki[t.race.species].type,i=Object.keys(F),s=JSON.parse(JSON.stringify(I[r]));e=e||i.length;for(let t=0;t');$("#r_govern1").append(e);let a=$('
              ');e.append(a);let r=$("
              ");r.append($(`
              ${z("governor_office",[t.race.governor.g.n])}
              `)),r.append($(`
              ${z("governor_background")}: ${F[t.race.governor.g.bg].name}
              `)),a.append(r),a.append($(`
              ${z("governor_fire")}
              `));let i=[0,1,2];t.genes.governor&&t.genes.governor>=2&&(i.push(i.length),K("organizer",0)&&i.push(i.length)),K("organizer",0)&&i.push(i.length),i.forEach((function(t){let a=`{{ 'none' | label }}`;Object.keys(B).forEach((function(e){B[e].req()&&(a+=`{{ '${e}' | label }}`)})),e.append(`
              ${z("gov_task",[t+1])}\n \n ${a}\n
              `)})),t.race.governor.hasOwnProperty("config")||(t.race.governor.config={});let s=$('
              ');e.append(s);{t.race.governor.config.hasOwnProperty("storage")||(t.race.governor.config.storage={crt:1e3,cnt:1e3});let e=$(`
              ${z("gov_task_storage")}
              `);s.append(e);let a=$('
              ');e.append(a);let r=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood",i="Steel";a.append($(`${z("gov_task_storage_reserve",[t.resource[r].name])}`)),a.append($(`${z("gov_task_storage_reserve",[t.resource[i].name])}`))}{t.race.governor.config.hasOwnProperty("bal_storage")||(t.race.governor.config.bal_storage={}),t.race.governor.config.bal_storage.hasOwnProperty("adv")||(t.race.governor.config.bal_storage.adv=!1);let e=$(`
              ${z("gov_task_bal_storage")}
              ${z("advanced")}
              `);s.append(e);let a=$('
              ');e.append(a),Object.keys(t.resource).forEach((function(e){t.resource[e].stackable?(t.race.governor.config.bal_storage.hasOwnProperty(e)||(t.race.governor.config.bal_storage[e]="2"),a.append($(`
              ${t.resource[e].name}\n \n 0x\n 1/2\n 1x\n 2x\n 3x\n 4x\n \n
              `))):t.race.governor.config.bal_storage.hasOwnProperty(e)&&delete t.race.governor.config.bal_storage[e]}))}{t.race.governor.config.hasOwnProperty("merc")||(t.race.governor.config.merc={buffer:1,reserve:100});let e=$(`
              ${z("gov_task_merc")}
              `);s.append(e);let a=$('
              ');e.append(a),a.append($(`${z("gov_task_merc_buffer")}`)),a.append($(`${z("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("spy")||(t.race.governor.config.spy={reserve:100});let e=$(`
              ${z("gov_task_spy")}
              `);s.append(e);let a=$('
              ');e.append(a),a.append($(`${z("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("spyop")||(t.race.governor.config.spyop={},Object.keys(t.civic.foreign).forEach((function(e){t.race.governor.config.spyop[e]="gov3"===e?["influence","sabotage"]:["sabotage","incite","influence"]})));let e=$(`
              ${z("gov_task_spyop")}
              `);s.append(e),Object.keys(t.civic.foreign).forEach((function(a){if(a.substr(3,1)<3&&!t.tech.world_control||"gov3"===a&&t.tech.rival){let r=$("
              ");e.append(r),r.append(`\n

              ${z("gov_task_spyop_priority",[Z(a.substring(3))])}

              \n
                \n `);let i=$(`#spyopConfig${a}`);t.race.governor.config.spyop[a].forEach((function(e){i.append(`\n
              • ${z("civics_spy_"+e)}
              • \n `)}))}}))}{t.race.governor.config.hasOwnProperty("tax")||(t.race.governor.config.tax={min:20});let e=$(`
                ${z("gov_task_tax")}
                `);s.append(e);let a=$('
                ');e.append(a),a.append($(`${z("gov_task_tax_min")}`))}{t.race.governor.config.hasOwnProperty("slave")||(t.race.governor.config.slave={reserve:100});let e=$(`
                ${z("gov_task_slave")}
                `);s.append(e);let a=$('
                ');e.append(a),a.append($(`${z("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("trash")||(t.race.governor.config.trash={}),["Infernite","Elerium","Copper","Iron"].forEach((function(e){t.race.governor.config.trash.hasOwnProperty(e)&&"object"==typeof t.race.governor.config.trash[e]&&null!==t.race.governor.config.trash[e]||(t.race.governor.config.trash[e]={v:0,s:!0})}));let e=$(`
                ${z("gov_task_trash")}
                `);s.append(e);let a=$('
                ');e.append(a),Object.keys(t.race.governor.config.trash).forEach((function(e){a.append($(`
                `))}))}{t.race.governor.config.hasOwnProperty("replicate")||(t.race.governor.config.replicate={}),t.race.governor.config.replicate.hasOwnProperty("pow")||(t.race.governor.config.replicate.pow={on:!1,cap:1e4,buffer:0}),t.race.governor.config.replicate.hasOwnProperty("res")||(t.race.governor.config.replicate.res={que:!0,neg:!0,cap:!0});let e=$(`
                ${z("gov_task_replicate")}
                `);s.append(e);let a=$('
                ');e.append(a),a.append($(`
                ${z("gov_task_replicate_auto")}
                `)),a.append($(`${z("gov_task_replicate_pmax")}`)),a.append($(`${z("gov_task_replicate_buff")}`));let r=$('
                ');e.append(r),r.append($(`
                ${z("gov_task_replicate_que")}
                `)),r.append($(`
                ${z("gov_task_replicate_neg")}
                `)),r.append($(`
                ${z("gov_task_replicate_cap")}
                `))}Cs({el:"#govOffice",data:{t:t.race.governor.tasks,c:t.race.governor.config,r:t.resource},methods:{setTask(e,a){t.race.governor.tasks[`t${a}`]=e,ks("govtask",{task:e}),Cs({el:"#race"},"update")},showTask:e=>Object.values(t.race.governor.tasks).includes(e),activeTask(e){let a=[];return t.race.hasOwnProperty("governor")&&Object.keys(t.race.governor.tasks).forEach((function(e){"none"!==t.race.governor.tasks[e]&&a.push(t.race.governor.tasks[e])})),!a.includes(e)},showStrRes:e=>t.resource[e].display,bStrEx:()=>t.race.governor.config.bal_storage.adv?"m":"",fire(){let e=(10+(t.race.governor.hasOwnProperty("f")?t.race.governor.f:0))**2-50,a="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";t.prestige[a].count>=e&&(t.prestige[a].count-=e,t.race.governor.candidates=T(10),t.race.governor.hasOwnProperty("f")?t.race.governor.f++:t.race.governor.f=1,delete t.race.governor.g,delete t.race.governor.tasks,ui(!1,["city-amphitheatre","city-apartment"]),vs(),fs(),L())},fireText(){let e=(10+(t.race.governor.hasOwnProperty("f")?t.race.governor.f:0))**2-50;return`
                ${z("governor_fire")}
                ${e} ${z("antimatter"===t.race.universe?"resource_AntiPlasmid_plural_name":"resource_Plasmid_plural_name")}
                `},trashStrat(e){t.race.governor.config.trash[e].s=!t.race.governor.config.trash[e].s},trashLabel:e=>z(t.race.governor.config.trash[e].s?"gov_task_trash_max":"gov_task_trash_min",[t.resource[e].name])},filters:{label:e=>B[e]?"string"==typeof B[e].name?B[e].name:B[e].name():z(`gov_task_${e}`)}}),ls("govOffice",(function(){let e="";return Object.keys(F[t.race.governor.g.bg].traits).forEach((function(t){e+=(A[t].hasOwnProperty("effect")?A[t].effect():"")+" "})),e}),{elm:"#govOffice .bg"}),Object.keys(t.civic.foreign).forEach((function(e){!function(e){let a=$(`#spyopConfig${e}`)[0];a&&Sortable.create(a,{onEnd(a){let r=t.race.governor.config.spyop[e];r.splice(a.newDraggableIndex,0,r.splice(a.oldDraggableIndex,1)[0]),t.race.governor.config.spyop[e]=r,L()}})}(e)}))}():function(){let e=$('
                ');$("#r_govern1").append(e),t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("candidates")||(t.race.governor={candidates:T(10)}),e.append($(`
                ${z("governor_candidate")}${z("governor_background")}
                `));for(let a=0;a${r.t} ${r.n}${F[r.bg].name}
                `))}Cs({el:"#candidates",data:t.race.governor,methods:{appoint(e){if(t.genes.governor&&t.tech.governor){let a=t.race.governor.candidates[e];t.race.governor.g=a,delete t.race.governor.candidates,t.race.governor.tasks={t0:"none",t1:"none",t2:"none",t3:"none",t4:"none",t5:"none"},ui(!1,["city-amphitheatre","city-apartment"]),vs(),fs(),L(),ks("governor",{appoint:t.race.governor.g.bg})}}}}),t.race.governor.candidates.forEach((function(e){ls(`candidates-${e.bg}`,(function(){let t="";return Object.keys(F[e.bg].traits).forEach((function(e){t+=(A[e].hasOwnProperty("effect")?A[e].effect():"")+" "})),t}),{elm:`#candidates .${e.bg} .bg`})}))}())}function E(){Object.keys(t.civic.foreign).forEach((function(e){let t=$(`#spyopConfig${e}`)[0];if(t){let e=Sortable.get(t);e&&e.destroy()}}))}function K(e,a){return!(!t.race.hasOwnProperty("governor")||!t.race.governor.hasOwnProperty("g"))&&!!F[t.race.governor.g.bg].traits[e]&&A[e].vars()[a]}function D(e){if(t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks)for(let a=0;at.civic.taxes.display,task(){if($(this)[0].req()){let e=1;t.civic.taxes.tax_rate>=40&&(e+=.5),"oligarchy"===t.civic.govern.type&&t.civic.taxes.tax_rate>=20&&(e-=.5);let a=de("tax_cap",!1);if(t.city.morale.current<100&&t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?45:25))for(;t.city.morale.current<100&&t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?45:25);)de("adj_tax","sub");else t.city.morale.potential>=t.city.morale.cap+e&&t.civic.taxes.tax_ratet.race.governor.config.tax.min&&de("adj_tax","sub")}}},storage:{name:z("gov_task_storage"),req:()=>!!(Nr("storage_yard")&&t.tech.container&&t.resource.Crates.display),task(){if($(this)[0].req()){if(t.resource.Crates.amountr&&nr("crate",Math.floor((t.resource[e].amount-r)/a))}if(Nr("warehouse")&&t.resource.Containers.display&&t.resource.Containers.amounta&&nr("container",Math.floor((t.resource.Steel.amount-a)/e))}}}},bal_storage:{name:z("gov_task_bal_storage"),req:()=>!!(Nr("storage_yard")&&t.tech.container&&t.resource.Crates.display),task(){if($(this)[0].req()){let e=t.resource.Crates.amount,a=e,r=t.resource.Containers.amount,i=r,s=0,n=Object.keys(t.resource).slice().reverse();n.forEach((function(a){t.resource[a].display&&t.resource[a].stackable?(e+=t.resource[a].crates,r+=t.resource[a].containers,s++):(t.resource[a].crates=0,t.resource[a].containers=0)}));let c=Math.floor(e/s),o=Math.floor(r/s),l={Food:{m:.1,cap:100},Coal:{m:.25}};t.race.artifical&&delete l.Food,Object.keys(t.race.governor.config.bal_storage).forEach((function(e){let a=Number(t.race.governor.config.bal_storage[e]);"Coal"===e?l[e]={m:.125*a}:"Food"===e?l[e]={m:.05*a,cap:50*a}:t.resource[e]&&(l[e]={m:a})})),Object.keys(l).forEach((function(a){if(t.resource[a].display)if(l[a].hasOwnProperty("cap")){s--;{let r=Math.floor(c*l[a].m);l[a].hasOwnProperty("cap")&&r>l[a].cap&&(r=l[a].cap),t.resource[a].crates=r,e-=r}if(t.resource.Containers.display){let e=Math.floor(o*l[a].m);l[a].hasOwnProperty("cap")&&e>l[a].cap&&(e=l[a].cap),t.resource[a].containers=e,r-=e}}else s+=l[a].m-1})),c=0!==s?Math.floor(e/s):0,o=0!==s?Math.floor(r/s):0,e-=Math.floor(c*s),r-=Math.floor(o*s),n.forEach((function(a){if((!l[a]||!l[a].hasOwnProperty("cap"))&&(!t.race.artifical||"Food"!==a)&&t.resource[a].display&&t.resource[a].stackable){let i=l[a]?l[a].m:1,s=Math.floor(c>0?c*i:0);if(t.resource[a].crates=s,t.resource.Containers.display){let e=Math.floor(o>0?o*i:0);t.resource[a].containers=e}if(e>0&&i>=1){let r=Math.ceil(i/2);e0&&i>=1){let e=Math.ceil(i/2);r0&&(e>0||r>0);)_--,n.forEach((function(a){l[a]&&l[a].hasOwnProperty("cap")||t.race.artifical&&"Food"===a||t.resource[a].display&&t.resource[a].stackable&&(e>0&&(t.resource[a].crates++,e--),r>0&&(t.resource[a].containers++,r--))}));t.resource.Crates.amount=e,t.resource.Containers.amount=r,s&&(t.resource.Crates.max-=a,t.resource.Containers.max-=i)}}},assemble:{name:z("gov_task_assemble"),req:()=>!(!t.race.artifical||t.tech.focus_cure&&!(t.tech.focus_cure<7)),task(){$(this)[0].req()&&t.resource[t.race.species].max>t.resource[t.race.species].amount&&Mr.city.assembly.action()}},clone:{name:z("gov_task_clone"),req:()=>!!t.tech.cloning,task(){$(this)[0].req()&&t.resource[t.race.species].max>t.resource[t.race.species].amount&&Mr.tauceti.tau_home.cloning_facility.action()}},merc:{name:z("gov_task_merc"),req:()=>!(!Nr("garrison")||!t.tech.mercs),task(){if($(this)[0].req()){let e=t.resource.Money.max*(t.race.governor.config.merc.reserve/100);for(;t.civic.garrison.max>t.civic.garrison.workers+t.race.governor.config.merc.buffer&&t.resource.Money.amount>=de("m_cost")&&(t.resource.Money.amount+t.resource.Money.diff>=e||t.resource.Money.diff>=de("m_cost"));)de("m_buy")}}},spy:{name:z("gov_task_spy"),req:()=>!(t.tech.isolation||(!t.race.truepath||!t.tech.spy)&&(!t.tech.spy||t.tech.world_control||t.race.cataclysm)),task(){if($(this)[0].req()){let e=t.resource.Money.max*(t.race.governor.config.spy.reserve/100),a=t.race.truepath&&t.tech.rival?4:3;for(let r=t.tech.world_control?3:0;r=a&&(t.resource.Money.diff>=a||t.resource.Money.amount+t.resource.Money.diff>=e)&&de("t_spy",r)}}}},spyop:{name:z("gov_task_spyop"),req:()=>!(t.tech.isolation||!(t.race.truepath&&t.tech.spy&&t.tech.spy>=2)&&(!(t.tech.spy&&t.tech.spy>=2)||t.tech.world_control||t.race.cataclysm)),task(){if($(this)[0].req()){let e=t.race.truepath&&t.tech.rival?[0,1,2,3]:[0,1,2];t.tech.world_control&&(e=[3]),e.forEach((function(e){0===t.civic.foreign[`gov${e}`].sab&&t.civic.foreign[`gov${e}`].spy>0&&!t.civic.foreign[`gov${e}`].anx&&!t.civic.foreign[`gov${e}`].buy&&!t.civic.foreign[`gov${e}`].occ&&t.race.governor.config.spyop[`gov${e}`].every((function(a){switch(a){case"influence":if(t.civic.foreign[`gov${e}`].hstl>0&&t.civic.foreign[`gov${e}`].spy>1)return de("s_influence",e),!1;break;case"sabotage":if(t.civic.foreign[`gov${e}`].mil>50)return de("s_sabotage",e),!1;break;case"incite":if(t.civic.foreign[`gov${e}`].unrest<100&&t.civic.foreign[`gov${e}`].spy>2&&e<3)return de("s_incite",e),!1}return!0}))}))}}},slave:{name:z("gov_task_slave"),req:()=>!(t.race.orbit_decayed||!Nr("slave_market")||!t.race.slaver||!t.city.slave_pen),task(){let e=t.resource.Money.max*(t.race.governor.config.slave.reserve/100),a=25e3;t.race.inflation&&(a*=1+t.race.inflation/100);let r=K("extravagant",0);r&&(a*=1+r/100),$(this)[0].req()&&t.resource.Money.amount>=a&&(t.resource.Money.diff>=a||t.resource.Money.amount+t.resource.Money.diff>=e)&&4*t.city.slave_pen.count>t.city.slave_pen.slaves&&Mr.city.slave_market.action()}},sacrifice:{name:z("gov_task_sacrifice"),req:()=>!!(Nr("s_alter")&&t.city.hasOwnProperty("s_alter")&&t.city.s_alter.count>=1),task(){$(this)[0].req()&&t.resource[t.race.species].amount===t.resource[t.race.species].max&&(!t.race.kindling_kindred&&!t.race.smoldering&&t.city.s_alter.harvest<=1e4||t.city.s_alter.mind<=1e4||t.city.s_alter.mine<=1e4||t.city.s_alter.rage<=1e4||t.city.s_alter.regen<=1e4)&&Mr.city.s_alter.action()}},horseshoe:{name:()=>z(`city_${hn(!0)}`,[hn(!1)]),req:()=>!!t.race.hooved,task(){let e=Mr.city.horseshoe.cost;if($(this)[0].req()&&ii(e)){e=Ns(Mr.city.horseshoe);let a="Copper",r=10;Object.keys(e).forEach((function(t){e[t]()>0&&(a=t,r=e[t]())})),t.resource[a].amount>r&&(t.resource[a].diff>=r||t.resource[a].amount+t.resource[a].diff>=t.resource[a].max)&&Mr.city.horseshoe.action()}}},trash:{name:z("gov_task_trash"),req:()=>!!(t.interstellar.mass_ejector&&t.interstellar.mass_ejector.count>=1),task(){let e=function(e){return"magic"===t.race.universe?Fa[e]:["Elerium","Infernite"].includes(e)?10*Fa[e]:Fa[e]},a=1e3*s.mass_ejector;Object.keys(Fa).sort(((t,a)=>e(t)0&&(s=0),t.race.governor.config.trash[e]||t.interstellar.mass_ejector.hasOwnProperty(e)&&t.resource[e].display&&t.resource[e].max>0&&t.interstellar.mass_ejector[e]+t.resource[e].diff>0&&t.resource[e].amount+i-s>=.999*t.resource[e].max-1){let r=t.resource[e].amount+i-s>=.999*t.resource[e].max-1||t.race.governor.config.trash[e]&&!t.race.governor.config.trash[e].s?Math.floor(t.interstellar.mass_ejector[e]+t.resource[e].diff):0;t.race.governor.config.trash[e]&&r=.999*t.resource[e].max-1?r:r-Math.abs(t.race.governor.config.trash[e].v)),r>a&&(r=a),r<0&&(r=0),t.race.artifical&&"Food"===e&&(r=0),t.interstellar.mass_ejector[e]=r,a-=r}else t.interstellar.mass_ejector[e]=0})),t.interstellar.mass_ejector.total=1e3*s.mass_ejector-a}},mech:{name:z("gov_task_mech"),req:()=>!!(t.stats.achieve.hasOwnProperty("corrupted")&&t.stats.achieve.corrupted.l>0&&("prtl_spire","mechbay",Tt(na,"prtl_spire","mechbay"))&&t.portal.hasOwnProperty("mechbay")),task(){if($(this)[0].req()){let e="large",a=fa(e,!1),r=a.c,i=a.s,s=ba(e),n={type:{}};["small","medium","large","titan","collector"].forEach((function(e){n.type[e]=0,n[e]={chassis:{},weapon:{},equip:{}},["hover","spider","wheel","tread","biped","quad"].forEach((function(t){n[e].chassis[t]=0})),["plasma","laser","kinetic","shotgun","missile","flame","sonic","tesla"].map((e=>({sort:Math.random(),value:e}))).sort(((e,t)=>e.sort-t.sort)).map((e=>e.value)).forEach((function(t){n[e].weapon[t]=0})),["shields","flare","seals","grapple","sonar","ablative","radiator","infrared","coolant","stabilizer"].forEach((function(t){n[e].equip[t]=0}))})),t.portal.mechbay.mechs.forEach((function(e){n.type[e.size]++,n[e.size].chassis[e.chassis]++,e.hardpoint.forEach((function(t){n[e.size].weapon[t]++})),e.equip.forEach((function(t){n[e.size].equip[t]++}))})),n.type.large>=6&&n.type.small<12||n.type.large>=12&&n.type.titan>=2&&n.type.small<24?(e="small",a=fa(e,!1),r=a.c,i=a.s,s=ba(e)):n.type.large>=6&&n.type.medium<12?(e="medium",a=fa(e,!1),r=a.c,i=a.s,s=ba(e)):n.type.large>=12&&n.type.titan<2&&(a=fa("titan",!1),a.c<=t.portal.purifier.sup_max&&(e="titan",r=a.c,i=a.s,s=ba(e)));let c=t.portal.mechbay.max-t.portal.mechbay.bay;if(c=3){if(t.queue.queue.some((e=>["portal-purifier","portal-port","portal-base_camp","portal-mechbay","portal-waygate"].includes(e.id))))return;for(let s=0;st.portal.purifier.sup_max&&(l=t.portal.purifier.sup_max),l>=r&&t.resource.Soul_Gem.amount+o>=i){if(t.resource.Soul_Gem.amount+=o,t.resource.Soul_Gem.amount-=i,t.portal.purifier.supply=l,t.portal.purifier.supply-=r,t.portal.mechbay.mechs[s].infernal=!0,"small"===c.size&&0===c.equip.length)t.portal.mechbay.mechs[s].equip.push("special");else if("medium"===c.size&&1===c.equip.length||"large"===c.size&&2===c.equip.length||"titan"===c.size&&c.equip.length<5){let a="???";Object.keys(n[e].equip).forEach((function(t){("???"===a||n[e].equip[t]=r&&c>=s&&t.resource.Soul_Gem.amount>=i){let a=99,c="hover";Object.keys(n[e].chassis).forEach((function(t){n[e].chassis[t]!(!t.tech.replicator||!t.race.replicator),task(){if(t.race.governor.config.replicate.pow.on){let e=t.race.governor.config.replicate.pow.cap,a=t.race.governor.config.replicate.pow.buffer;if(t.city.power0){let e=t.city.power<0?Math.abs(t.city.power)+a:a-t.city.power;t.race.replicator.pow-=e,t.race.replicator.pow<0&&(t.race.replicator.pow=0)}else t.city.power>a&&t.race.replicator.powe&&(t.race.replicator.pow=e)):t.race.replicator.pow>e&&(t.race.replicator.pow=e);t.race.replicator.pow=Math.floor(t.race.replicator.pow)}let e=!1;for(let a=0;t.race.governor.config.replicate.res.que&&at.resource[e].display)),t.race.governor.config.replicate.res.neg&&t.resource[a[0]].diff<0&&(t.resource[a[0]].amount<=.95*t.resource[a[0]].max||-1===t.resource[a[0]].max))t.race.replicator.res=a[0];else if(-1!==t.resource[t.race.replicator.res].max&&t.race.governor.config.replicate.res.cap&&t.resource[t.race.replicator.res].amount>=t.resource[t.race.replicator.res].max){let r=a.filter((e=>t.resource[e].max>0));for(let a=0;a-1===t.resource[e].max));e.length>0&&(t.race.replicator.res=e[0])}}}}}};function G(e){switch(e){case"aries":case"capricorn":return[10];case"taurus":return[2];case"gemini":case"aquarius":return[20];case"cancer":case"sagittarius":return[5];case"leo":return[4];case"virgo":return[15];case"libra":return[25];case"scorpio":return[12,1];case"pisces":return[49,25]}}function N(){const e=new Date;return 0===e.getMonth()&&e.getDate()>=20||1===e.getMonth()&&e.getDate()<=18?"aquarius":1===e.getMonth()&&e.getDate()>=19||2===e.getMonth()&&e.getDate()<=20?"pisces":2===e.getMonth()&&e.getDate()>=21||3===e.getMonth()&&e.getDate()<=19?"aries":3===e.getMonth()&&e.getDate()>=20||4===e.getMonth()&&e.getDate()<=20?"taurus":4===e.getMonth()&&e.getDate()>=21||5===e.getMonth()&&e.getDate()<=21?"gemini":5===e.getMonth()&&e.getDate()>=22||6===e.getMonth()&&e.getDate()<=22?"cancer":6===e.getMonth()&&e.getDate()>=23||7===e.getMonth()&&e.getDate()<=22?"leo":7===e.getMonth()&&e.getDate()>=23||8===e.getMonth()&&e.getDate()<=22?"virgo":8===e.getMonth()&&e.getDate()>=23||9===e.getMonth()&&e.getDate()<=22?"libra":9===e.getMonth()&&e.getDate()>=23||10===e.getMonth()&&e.getDate()<=22?"scorpio":10===e.getMonth()&&e.getDate()>=23||11===e.getMonth()&&e.getDate()<=21?"sagittarius":11===e.getMonth()&&e.getDate()>=22||0===e.getMonth()&&e.getDate()<=19?"capricorn":"time itself is broken"}function R(){P.w&&P.w.terminate(),O(),ks("reset",{end:"descension"}),qn("squished",!0),qn(`extinct_${t.race.species}`),t.race.witch_hunter&&"magic"===t.race.universe?qn("nightmare"):qn("corrupted"),"angelic"===Ki[t.race.species].type&&Pn("twisted"),t.race.junker&&"junker"===t.race.species&&Pn("the_misery"),!t.race.modified&&t.race.junker&&"junker"===t.race.species&&Pn("garbage_pie"),t.race.cataclysm&&Pn("finish_line"),t.race.ooze&&"sludge"===t.race.species&&Pn("slime_lord");let a=Gs("descend");t.prestige.Artifact.count+=a.artifact,t.stats.artifact+=a.artifact;let r=xn();t.stats.spire.hasOwnProperty(r)&&(t.stats.spire[r].hasOwnProperty("lord")?t.stats.spire[r].lord++:t.stats.spire[r].lord=1,t.tech.dl_reset?t.stats.spire[r].dlstr=0:t.stats.spire[r].hasOwnProperty("dlstr")?t.stats.spire[r].dlstr++:t.stats.spire[r].dlstr=1);let i=t.race.species,s=t.race.gods,n=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,l=t.city.geology;t.stats.descend++,rn(),Sn();let _=!!t.race.hasOwnProperty("srace")&&t.race.srace;t.race={species:"protoplasm",gods:i,old_gods:s,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),corruption:5,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},_&&(t.race.srace=_),H({orbit:n,biome:c,ptrait:o,geology:l}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}function H(e){t.city={calendar:{day:0,year:0,weather:2,temp:1,moon:0,wind:0,orbit:e.orbit},biome:e.biome,ptrait:e.ptrait},e.geology&&(t.city.geology=e.geology),t.tech={theology:1},S(),t.new=!0,t.seed=Math.rand(0,1e4)}function U(){let e=xn();t.race.womling_friend?("m"!==e&&t.stats.womling.friend.l++,"l"!==e&&(t.stats.womling.friend.hasOwnProperty(e)||(t.stats.womling.friend[e]=0),t.stats.womling.friend[e]++)):t.race.womling_lord?("m"!==e&&t.stats.womling.lord.l++,"l"!==e&&(t.stats.womling.lord.hasOwnProperty(e)||(t.stats.womling.lord[e]=0),t.stats.womling.lord[e]++)):t.race.womling_god&&("m"!==e&&t.stats.womling.god.l++,"l"!==e&&(t.stats.womling.god.hasOwnProperty(e)||(t.stats.womling.god[e]=0),t.stats.womling.god[e]++)),t.stats.womling.friend.l>0&&t.stats.womling.lord.l>0&&t.stats.womling.god.l>0&&qn("overlord","m"===e,Mn(),"l"),t.stats.womling.friend[e]>0&&t.stats.womling.lord[e]>0&&t.stats.womling.god[e]>0&&qn("overlord","m"===e,Mn(),e)}function V(e){if(t.civic.taxes||(t.civic.taxes={tax_rate:20,display:!1}),!e&&(t.settings.tabLoad||2===t.settings.civTabs&&0===t.settings.govTabs)){var a=$('
                '),r=$(`\n \n \n \n \n \n \n `);a.append(r),$("#r_civics").append(a),Cs({el:"#government .govTabs2",data:{t:t.civic.taxes,s:t.settings},methods:{vis:()=>!!t.tech.govern}}),function(e){var a=$('
                ');e.append(a);var r=$(`
                ${z("civics_government_type")} {{ type | govern }}
                `);a.append(r);var i=$("
                ");a.append(i);var s=$('');i.append(s);var n={template:''};Cs({el:"#govType",data:t.civic.govern,filters:{govern:e=>z(`govern_${e}`),set:e=>z("anarchy"===e?"civics_set_gov":"civics_revolution")},methods:{trigModal(){this.$buefy.modal.open({parent:this,component:n});var e=setInterval((function(){$("#modalBox").length>0&&(clearInterval(e),function(){$("#modalBox").append($(`

                ${z("civics_government_type")}

                `));let e=Qs(6,10);e.length>0&&$("#modalBoxTitle").append(e);let a=Js(6,14,!1);a.length>0&&$("#modalBoxTitle").append(a);var r=$('
                ');$("#modalBox").append(r),t.tech.govern&&("autocracy"!==t.civic.govern.type&&r.append($(``)),"democracy"!==t.civic.govern.type&&r.append($(``)),"oligarchy"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_theo&&"theocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.govern>=2&&"republic"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_soc&&"socialist"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_corp&&"corpocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.govern>=3&&"technocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_fed&&"federation"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_mage&&"magocracy"!==t.civic.govern.type&&r.append($(``))),Cs({el:"#govModal",data:t.civic.govern,methods:{setGov(e){if(0===t.civic.govern.rev){let a=t.genes.governor&&"anarchy"===t.civic.govern.type;t.civic.govern.type=e;let r=1e3;t.tech.high_tech&&(r+=250,t.tech.high_tech>=3&&(r+=250),t.tech.high_tech>=6&&(r+=250)),t.tech.space_explore&&t.tech.space_explore>=3&&(r+=250),t.race.unorganized&&(r=Math.round(r*(1+Ei.unorganized.vars()[0]/100))),t.stats.achieve.anarchist&&(r=Math.round(r*(1-t.stats.achieve.anarchist.l/10))),t.race.lawless&&(r=Math.round(r/(100-Ei.lawless.vars()[0])));let i=ts("tuskin");i>0&&(r=Math.round(r/(100-Ei.lawless.vars(1)[0]*i)));let s=K("aristocrat",0);s&&(r=Math.round(r*(1-s/100))),t.civic.govern.rev=r+t.civic.govern.fr,a&&Qr(),Cs({el:"#govModal"},"destroy"),$(".modal-background").click(),_s()}}}}),ls("GovPop",(function(e){let a=$(e.this).data("gov"),r=t.tech.unify&&t.tech.unify>=2&&"federation"===a?"federation_alt":a;return"theocracy"===r&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display&&(r="theocracy_alt"),$(`
                ${ee(a)}
                ${X()[r]}
                `)}),{elm:"#govModal button",self:!0,classes:"has-background-light has-text-dark"})}())}),50)},startrev(){t.civic.govern.fr=t.civic.govern.rev,t.civic.govern.rev=0},force:()=>t.civic.govern.rev>0?z("civics_force_rev_desc"):z("civics_force_rev_desc2"),vis:()=>!!t.tech.govern}}),ls("govLabel",(function(){let e=t.tech.unify&&t.tech.unify>=2&&"federation"===t.civic.govern.type?"federation_alt":t.civic.govern.type;return"theocracy"===e&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display&&(e="theocracy_alt"),$(`
                ${ee(t.civic.govern.type)}
                ${X()[e]}
                `)})),ls("govTypeChange",(function(){return t.civic.govern.rev>0?z("civics_change_desc",[t.civic.govern.rev]):z("civics_change_desc2")}),{elm:"#govType .change"})}($("#r_govern0")),function(e){var a=$('
                ');e.append(a);var r=$(`

                ${z("civics_tax_rates")}

                `);a.append(r);var i=$(''),s=$('«'),n=$('»');a.append(s),a.append(i),a.append(n),Cs({el:"#tax_rates",data:t.civic.taxes,filters:{tax_level(e){let a=Qs(11,14),r=Js(2,14,!1);return a.length>0&&(0===e&&!t.race.noble||10===e&&t.race.noble)?a:13===e&&r.length>0?r:`${e}%`}},methods:{add(){_e("add")},sub(){_e("sub")}}}),ls("taxRateLabel",(function(){return z("civics_tax_rates_desc")}),{classes:"has-background-light has-text-dark"})}($("#r_govern0"));var i=$('
                ');$("#r_govern0").append(i),L()}}function W(){if(Q(),t.settings.tabLoad||2===t.settings.civTabs&&3===t.settings.govTabs){var a=$('
                ');$("#military").append(a),$("#military").append($('
                ')),he(a,!0),function(){if(t.race.sludge)return!1;if(0===$("#mad").length){let i="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");var a=$('
                ');$("#military").append(a);var r=$('
                ');a.append(r),r.append($(`
                ${z("civics_mad_reset_desc",[i])}
                `));let s=!(!t.race.hrt||!["wolven","vulpine"].includes(t.race.hrt));r.append($(`
                `)),r.append($(`
                `)),t.civic.mad.armed||($("#mad").addClass("armed"),$("#mad .arm").html(z(s?"civics_mad_disarm_grenades":"civics_mad_disarm_missiles"))),Cs({el:"#mad",data:t.civic.mad,methods:{launch(){if(!t.civic.mad.armed&&!t.race.cataclysm){$("body").addClass("nuke");let a=$('
                ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),500),setTimeout((function(){a.addClass("b")}),600),setTimeout((function(){!function(){if(!t.civic.mad.armed&&!t.race.cataclysm){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"mad"});let a=t.race.species,r=t.race.gods,i=t.city.calendar.orbit,s=t.city.biome,n=t.city.ptrait,c=t.city.geology,o=Gs("mad");t.stats.mad++,rn(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),qn("apocalypse"),qn("squished",!0),qn(`extinct_${a}`),"anarchy"===t.civic.govern.type&&qn("anarchist"),"hellscape"===t.city.biome&&"demonic"!==Ki[t.race.species].type&&Pn("take_no_advice"),t.race.truepath&&qn("ashanddust"),Sn();let l=!!t.race.hasOwnProperty("srace")&&t.race.srace,_=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,rapid_mutation:1,ancient_ruins:1,universe:t.race.universe,seeded:!1,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},_>0&&(t.race.corruption=_),l&&(t.race.srace=l),H({orbit:i,biome:s,ptrait:n,geology:c}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}}()}),4e3)}},arm(){t.civic.mad.armed?($("#mad .arm").html(z(s?"civics_mad_disarm_grenades":"civics_mad_disarm_missiles")),t.civic.mad.armed=!1,$("#mad").addClass("armed")):($("#mad .arm").html(z(s?"civics_mad_arm_grenades":"civics_mad_arm_missiles")),t.civic.mad.armed=!0,$("#mad").removeClass("armed"))}}}),["mdarm","mdlaunch"].forEach((function(e){ls(`mad${e}`,(function(){return"{{ label() }}"}),{elm:`#mad .${e}`,in:function(a){Cs({el:`#${a.id} > span`,data:{test:"val"},methods:{label(){switch(e){case"mdarm":return t.tech.world_control&&!t.race.truepath?z("civics_mad_missiles_world_control_desc"):z(s?"civics_mad_missiles_desc_easter":"civics_mad_missiles_desc");case"mdlaunch":{let e=Gs("mad"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return z("civics_mad_missiles_warning",[e.plasmid,a])}}}}})},out:function(e){Cs({el:`#${e.id} > span`},"destroy")}})}))}}()}}function Q(){t.civic.garrison||(t.civic.garrison={display:!1,disabled:!1,rate:0,progress:0,tactic:0,workers:0,wounded:0,raid:0,max:0}),t.civic.garrison.mercs||(t.civic.garrison.mercs=!1),t.civic.garrison.fatigue||(t.civic.garrison.fatigue=0),t.civic.garrison.protest||(t.civic.garrison.protest=0),t.civic.garrison.m_use||(t.civic.garrison.m_use=0),t.civic.garrison.crew||(t.civic.garrison.crew=0),t.civic.mad||(t.civic.mad={display:!1,armed:!0})}function J(e){if(t.race.truepath){if(t.civic.foreign[`gov${e}`].hstl<10)return 1+(10-t.civic.foreign[`gov${e}`].hstl)/40;if(t.civic.foreign[`gov${e}`].hstl>60)return 1-(-60+t.civic.foreign[`gov${e}`].hstl)/160}return 1}function Z(e){if(void 0===t.civic.foreign[`gov${e}`].name){let a=xs();t.civic.foreign[`gov${e}`].name={s0:a.s0,s1:a.s1}}return z(`civics_gov${t.civic.foreign[`gov${e}`].name.s0}`,[t.civic.foreign[`gov${e}`].name.s1])}const X=function(){return{anarchy:z("govern_anarchy_effect"),autocracy:z("govern_autocracy_effect",Y.autocracy()),democracy:z("govern_democracy_effect",Y.democracy()),oligarchy:t.tech.high_tech&&t.tech.high_tech>=12?z("govern_oligarchy_effect_alt",[Y.oligarchy()[1]]):z("govern_oligarchy_effect",[Y.oligarchy()[0],Y.oligarchy()[1]]),theocracy:z("govern_theocracy_effect",Y.theocracy()),theocracy_alt:z("govern_theocracy_effect_alt",Y.theocracy()),republic:z("govern_republic_effect",Y.republic()),socialist:z("govern_socialist_effect",Y.socialist()),corpocracy:z("govern_corpocracy_effect",Y.corpocracy()),technocracy:t.tech.high_tech&&t.tech.high_tech>=16?z("govern_technocracy_effect_alt",[Y.technocracy()[0],Y.technocracy()[2]]):z("govern_technocracy_effect",Y.technocracy()),federation:z("govern_federation_effect",[Y.federation()[0],Y.federation()[1]]),federation_alt:z("govern_federation_effect_alt",[25,Y.federation()[2],Y.federation()[1]]),magocracy:z("govern_magocracy_effect",Y.magocracy())}},Y={autocracy:()=>[t.tech.high_tech&&t.tech.high_tech>=2?t.tech.high_tech>=12?10:18:25,K("organizer",0)?40:35],democracy:()=>[t.tech.high_tech&&t.tech.high_tech>=2?t.tech.high_tech>=12?30:25:20,K("organizer",0)?1:5],oligarchy:()=>[t.tech.high_tech&&t.tech.high_tech>=12?0:t.tech.high_tech&&t.tech.high_tech>=2?2:5,K("organizer",0)?25:20],theocracy:()=>[12,K("organizer",0)?10:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?25:40:50],republic:()=>[K("organizer",0)?30:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?40:30:20],socialist:()=>[t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?50:42:35,K("organizer",0)?12:10,10,K("organizer",0)?10:20],corpocracy:()=>[K("organizer",0)?220:200,K("organizer",0)?175:150,K("organizer",0)?110:100,t.tech.high_tech&&t.tech.high_tech>=12?5:10,t.tech.high_tech&&t.tech.high_tech>=16?40:30],technocracy:()=>[8,t.tech.high_tech&&t.tech.high_tech>=16?0:t.tech.high_tech&&t.tech.high_tech>=12?1:2,K("organizer",0)?18:10],federation:()=>[3,K("organizer",0)?12:10,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?40:36:32],magocracy:()=>[K("organizer",0)?30:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?50:40:25]};function ee(e){return t.race.witch_hunter&&"magocracy"===e?z("witch_hunter_magocracy"):z(`govern_${e}_desc`)}function te(){if(0===$("#foreign").length&&!t.race.cataclysm&&(!t.tech.world_control||t.race.truepath)&&!t.tech.isolation){let a=$('
                ');a.append($(`

                ${z("civics_foreign")}

                `)),$("#r_govern0").append(a);var e={template:''};let r=t.race.truepath?5:3;for(let e=0;e{{ '${e}' | gov }} - ${z("civics_garrison_occupy")} - ${z("civics_garrison_annex")} - ${z("civics_garrison_purchase")}
                `);a.append(t);let r=$("
                ");r.append($(``)),r.append($(``)),r.append($(``)),t.append(r),t.append($(`
                ${z("civics_gov_mil_rate")}: {{ f${e}.mil | military(${e}) }} ({{ f${e}.mil }})
                `)),t.append($(`
                ${z("civics_gov_relations")}: {{ f${e}.hstl | relation }} ({{ f${e}.hstl | hate }})
                `)),t.append($(`
                ${z("civics_gov_eco_rate")}: {{ f${e}.eco | eco(${e}) }} ({{ f${e}.eco }})
                `)),t.append($(`
                ${z("civics_gov_unrest")}: {{ f${e}.unrest | discontent(${e}) }} ({{ f${e}.unrest | turmoil }})
                `))}let i={f0:t.civic.foreign.gov0,f1:t.civic.foreign.gov1,f2:t.civic.foreign.gov2,t:t.tech};t.race.truepath&&(i.f3=t.civic.foreign.gov3,i.f4=t.civic.foreign.gov4),Cs({el:"#foreign",data:i,filters:{military:(e,a)=>t.civic.foreign[`gov${a}`].spy>=1?z(e<50?"civics_gov_v_weak":e<75?"civics_gov_weak":e>300?"civics_gov_superpower":e>200?"civics_gov_v_strong":e>160?"civics_gov_strong":e>125?"civics_gov_above_average":"civics_gov_average"):"???",relation:e=>z(e>80?"civics_gov_hated":e>60?"civics_gov_hostile":e>40?"civics_gov_poor":e>25?"civics_gov_neutral":e>10?"civics_gov_liked":"civics_gov_good"),eco:(e,a)=>t.civic.foreign[`gov${a}`].spy>=2?z(e<60?"civics_gov_weak":e<80?"civics_gov_recession":e>120?"civics_gov_strong":"civics_gov_average"):"???",discontent:(e,a)=>t.civic.foreign[`gov${a}`].spy>=3?z(e<=0?"civics_gov_none":e<30?"civics_gov_low":e<60?"civics_gov_medium":e<90?"civics_gov_high":"civics_gov_extreme"):"???",gov:e=>Z(e),sab:e=>"none"===e?"":z(`civics_spy_${e}`),hate:e=>100-e+"%",turmoil:e=>`${e}%`},methods:{campaign(e){ve(e)},battleAssessment:e=>ge(e),trigModal(a){this.$buefy.modal.open({parent:this,component:e});var r=setInterval((function(){$("#modalBox").length>0&&(clearInterval(r),function(e){$("#modalBox").append($(`

                ${z("civics_espionage_actions")}

                `));var a=$('
                ');$("#modalBox").append(a),t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(a.append($(``)),a.append($(``)),e<3&&a.append($(``)),e<3&&t.civic.foreign[`gov${e}`].hstl<=50&&t.civic.foreign[`gov${e}`].unrest>=50&&a.append($(``)),e<3&&t.civic.foreign[`gov${e}`].spy>=3&&a.append($(``))),Cs({el:"#espModal",data:t.civic.foreign[`gov${e}`],methods:{influence(e){t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(oe("influence",e),Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),_s())},sabotage(e){t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(oe("sabotage",e),Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),$("#popGov").hide(),_s())},incite(e){e>=3||t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(oe("incite",e),Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),_s())},annex(a){if(!(a>=3)&&t.civic.foreign[`gov${e}`].hstl<=50&&t.civic.foreign[`gov${e}`].unrest>=50&&t.city.morale.current>=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest&&t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&0===t.civic.foreign[`gov${a}`].sab){let e=t.tech.spy>=4?150:300;t.race.befuddle&&(e=Math.round(e*(1-Ei.befuddle.vars()[0]/100)));let r=ts("dryad");r>0&&(e=Math.round(e*(1-Ei.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="annex",Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),_s()}},purchase(e){if(e>=3)return;let a=ne(e);if(a<=t.resource.Money.amount&&t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=3&&0===t.civic.foreign[`gov${e}`].sab){t.resource.Money.amount-=a;let r=t.tech.spy>=4?150:300;t.race.befuddle&&(r=Math.round(r*(1-Ei.befuddle.vars()[0]/100)));let i=ts("dryad");i>0&&(r=Math.round(r*(1-Ei.befuddle.vars(1)[0]/100*i))),t.civic.foreign[`gov${e}`].sab=r,t.civic.foreign[`gov${e}`].act="purchase",Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),_s()}}}}),ls("GovLabel",(function(a){let r=$(a.this).data("esp"),i="";if("purchase"===r){let t=ne(e).toLocaleString();i=z(`civics_spy_${r}_desc`,[Z(e),t])}else if("annex"===r)if(t.city.morale.current>=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest)i=z(`civics_spy_${r}_desc`,[Z(e)]);else{let a=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest;i=z(`civics_spy_${r}_goal`,[Z(e),a])}else i=z(`civics_spy_${r}_desc`,[Z(e)]);let s="";return("influence"===r&&0===t.civic.foreign[`gov${e}`].hstl||"sabotage"===r&&t.civic.foreign[`gov${e}`].spy>=2&&50===t.civic.foreign[`gov${e}`].mil||"incite"===r&&t.civic.foreign[`gov${e}`].spy>=4&&100===t.civic.foreign[`gov${e}`].unrest)&&(s=`
                ${z("civics_spy_warning")}
                `),$(`${s}
                ${i}
                `)}),{elm:"#espModal button",self:!0,classes:"has-background-light has-text-dark"})}(a))}),50)},spy_disabled:e=>t.civic.foreign[`gov${e}`].trn>0||ie(e)>t.resource.Money.amount,spy(e){se(e)},spyDesc:e=>ae(e),espDesc:()=>re(),vis:()=>!(!t.civic.garrison.display||t.tech.world_control&&!t.race.truepath||t.race.cataclysm||t.tech.isolation),gvis:e=>!t.tech.isolation&&(e<=2?!t.tech.world_control:3===e&&!!t.tech.rival)}});for(let e=0;e{{ label() }}"}),{elm:`#gov${e} .attack`,in:function(t){Cs({el:`#${t.id} > span`,data:{test:"val"},methods:{label:()=>ge(e)}})},out:function(e){Cs({el:e.id},"destroy")}}),ls(`gov${e}ts`,(function(){return"{{ label() }}"}),{elm:`#gov${e} .tspy`,in:function(t){Cs({el:`#${t.id} > span`,data:{test:"val"},methods:{label:()=>ae(e)}})},out:function(e){Cs({el:e.id},"destroy")}}),ls(`gov${e}s`,(function(){return re()}),{elm:`#gov${e} .sspy`});t.race.truepath&&ls("garRivaldesc1",(function(){return z("civics_gov_tp_rival",[Z(3),Ki[t.race.species].home])}),{elm:"#gov3 > span"})}}function ae(e){return t.civic.foreign[`gov${e}`].trn>0?z("civics_progress"):z("civics_gov_spy_desc",[x(ie(e))])}function re(){return z("civics_gov_esp_desc")}function ie(e){let a=Math.round(t.civic.foreign[`gov${e}`].mil/2+t.civic.foreign[`gov${e}`].hstl/2-t.civic.foreign[`gov${e}`].unrest)+10;return a<50&&(a=50),t.race.infiltrator&&(a/=3),"scorpio"===N()&&(a*=1-G("scorpio")[0]/100),Math.round(a**(t.civic.foreign[`gov${e}`].spy+1))+500}function se(e){if(t.tech.spy&&0===t.civic.foreign[`gov${e}`].trn){let a=ie(e);if(t.resource.Money.amount>=a){t.resource.Money.amount-=a;let r=300;t.tech.spy>=3&&t.city.boot_camp&&(r-=10*(t.race.orbit_decayed&&t.space.space_barracks?t.space.space_barracks.on:t.city.boot_camp.count),r<10&&(r=10)),t.race.infiltrator&&(r=Math.round(r/2)),t.civic.foreign[`gov${e}`].trn=r}}}function ne(e){let a=15384*t.civic.foreign[`gov${e}`].eco;return a*=1+1.6*t.civic.foreign[`gov${e}`].hstl/100,a*=1-.25*t.civic.foreign[`gov${e}`].unrest/100,+a.toFixed(0)}function ce(e){return e?t.tech.world_control||t.civic.foreign[e].occ||t.civic.foreign[e].anx||t.civic.foreign[e].buy:t.civic.foreign.gov0.occ||t.civic.foreign.gov1.occ||t.civic.foreign.gov2.occ||t.civic.foreign.gov0.anx||t.civic.foreign.gov1.anx||t.civic.foreign.gov2.anx||t.civic.foreign.gov0.buy||t.civic.foreign.gov1.buy||t.civic.foreign.gov2.buy}function oe(e,a){switch(e){case"influence":if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&0===t.civic.foreign[`gov${a}`].sab){let e=t.tech.spy>=4?200:300;t.race.befuddle&&(e=Math.round(e*(1-Ei.befuddle.vars()[0]/100)));let r=ts("dryad");r>0&&(e=Math.round(e*(1-Ei.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="influence"}break;case"sabotage":if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&0===t.civic.foreign[`gov${a}`].sab){let e=t.tech.spy>=4?400:600;t.race.befuddle&&(e=Math.round(e*(1-Ei.befuddle.vars()[0]/100)));let r=ts("dryad");r>0&&(e=Math.round(e*(1-Ei.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="sabotage"}break;case"incite":if(a>=3)break;if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&0===t.civic.foreign[`gov${a}`].sab){let e=t.tech.spy>=4?600:900;t.race.befuddle&&(e=Math.round(e*(1-Ei.befuddle.vars()[0]/100)));let r=ts("dryad");r>0&&(e=Math.round(e*(1-Ei.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="incite"}}}function le(e){let a=!!(t.tech.currency&&t.tech.currency>=5);if(e)return!a&&!t.race.terrifying||t.race.noble?t.race.noble?Ei.noble.vars()[0]:10:0;{let e=30;t.race.noble?e=Ei.noble.vars()[1]:(a||t.race.terrifying)&&(e+=20),"oligarchy"===t.civic.govern.type&&(e+=Y.oligarchy()[1]);let r=K("aristocrat",1);return r&&(e+=r),e}}function _e(e,a){switch(e){case"add":{let e=a||y(),r=le(!1);t.race.noble?(t.civic.taxes.tax_rate+=e,t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?40:20)&&(t.civic.taxes.tax_rate="oligarchy"===t.civic.govern.type?40:20)):t.civic.taxes.tax_rater&&(t.civic.taxes.tax_rate=r))}break;case"sub":{let e=a||y(),r=le(!0);t.civic.taxes.tax_rate>r&&(t.civic.taxes.tax_rate-=e,t.civic.taxes.tax_rate25e3&&(e=25e3),t.civic.garrison.m_use>0&&(e*=1.1**t.civic.garrison.m_use),t.race.brute&&(e*=1-Ei.brute.vars()[0]/100);let a=ts("orc");return a>0&&(e*=1-Ei.brute.vars(1)[0]/100*a),t.race.inflation&&(e*=1+t.race.inflation/500),t.race.high_pop&&(e*=Ei.high_pop.vars()[1]/100),Math.round(e)}function ue(e){if(t.tech.mercs){let a=e||y(),r=!0;for(;r&&a>0;){let e=pe();t.civic.garrison.workers=e?(t.resource.Money.amount-=e,t.civic.garrison.workers++,t.civic.garrison.m_use++):r=!1,a--}}}function he(e,a){Ss(e),t.tech.world_control&&!t.race.truepath?e.append($(`

                ${z("civics_garrison")}

                - ${z("rating")} {{ g.workers | hell | rating }}
                `)):e.append($(`

                ${z("civics_garrison")}

                - ${z("rating")} {{ g.workers | hell | rating }} / {{ g.raid | rating }}
                `));var r=$('
                ');e.append(r);var i=$('
                ');r.append(i);let s=t.tech.world_control&&!t.race.truepath?z("civics_garrison_peacekeepers"):z("civics_garrison_soldiers");if(t.tech.isolation||(i.append($(`
                ${s} / {{ g.max | s_max }}
                `)),i.append($(`
                ${z("civics_garrison_crew")} {{ g.crew }}
                `)),i.append($(`
                ${z("civics_garrison_wounded")}
                `)),r.append($(`
                `))),a){let a="";t.tech.isolation&&(a=Qs(8,12)),e.append($(`
                ${z("civics_garrison_training")} - ${z("arpa_to_complete")} {{ g.rate, g.progress | trainTime }}${a} {{ g.progress }}%
                `))}var n=$('
                ');e.append(n);var c=$('
                ');if(n.append(c),(!t.tech.world_control||t.race.truepath)&&!t.race.cataclysm&&!t.tech.isolation){var o=$(`
                ${z("civics_garrison_campaign")}
                `);c.append(o);var l=$('{{ g.tactic | tactics }}'),_=$('«'),d=$('»');o.append(_),o.append(l),o.append(d);var p=$(`
                ${z("civics_garrison_battalion")}
                `);c.append(p);var u=$('{{ g.raid }}'),h=$('«'),m=$('»');p.append(h),p.append(u),p.append(m),a&&(t.race.truepath&&t.tech.rival&&n.append($(`
                ${Z(3)}
                `)),t.tech.world_control||(n.append($(`
                ${Z(0)}
                `)),n.append($(`
                ${Z(1)}
                `)),n.append($(`
                ${Z(2)}
                `))))}let g={g:t.civic.garrison,g0:t.civic.foreign.gov0,g1:t.civic.foreign.gov1,g2:t.civic.foreign.gov2};if(t.race.truepath&&(g.g3=t.civic.foreign.gov3,g.g4=t.civic.foreign.gov4),Cs({el:a?"#garrison":"#c_garrison",data:g,methods:{hire(){ue()},campaign(e){ve(e)},next(){t.civic.garrison.tactic<4&&t.civic.garrison.tactic++},last(){t.civic.garrison.tactic>0&&t.civic.garrison.tactic--},aNext(){let e=y();t.civic.garrison.raidwe()&&(t.civic.garrison.raid=we()))},aLast(){let e=y();t.civic.garrison.raid>0&&(t.civic.garrison.raid-=e,t.civic.garrison.raid<0&&(t.civic.garrison.raid=0))},vis:()=>t.civic.garrison.display,rvis:()=>!(!t.tech.rival||t.tech.isolation)},filters:{tactics(e){switch(e){case 0:return z("civics_garrison_tactic_ambush");case 1:return z("civics_garrison_tactic_raid");case 2:return z("civics_garrison_tactic_pillage");case 3:return z("civics_garrison_tactic_assault");case 4:return z("civics_garrison_tactic_siege")}},rating:e=>+be(e,"army").toFixed(1),hell:e=>we(),stationed(e){let r=we(),i=t.race.cataclysm?13:31,s=r===i&&!a&&Js(2,14,!0);return r===i&&s.length>0?s:r},s_max:e=>we(!0),wounded(e){let t=Qs(8,12);return a&&0===e&&t.length>0?t:cn("fool",2021)?we()-e:e},trainTime:(e,t)=>zs(0===e?-1:(100-t)/(4*e))}}),["tactic","bat","soldier","crew","wounded","hmerc","defenseRating","offenseRating"].forEach((function(e){ls(a?`garrison${e}`:`cGarrison${e}`,(function(){return"{{ label() }}"}),{elm:`${a?"#garrison":"#c_garrison"} .${e}`,in:function(a){Cs({el:`#${a.id} > span`,data:{test:"val"},methods:{label(){switch(e){case"tactic":switch(t.civic.garrison.tactic){case 0:return z("civics_garrison_tactic_ambush_desc");case 1:return z("civics_garrison_tactic_raid_desc");case 2:return z("civics_garrison_tactic_pillage_desc");case 3:return z("civics_garrison_tactic_assault_desc");case 4:return z("civics_garrison_tactic_siege_desc",[ta("federation"===t.civic.govern.type?15:20)])}case"bat":return z("civics_garrison_army_label");case"soldier":return me();case"crew":return z("civics_garrison_crew_desc");case"wounded":return z("civics_garrison_wounded_desc");case"hmerc":return z("civics_garrison_hire_mercenary_cost",[Math.round(pe()).toLocaleString()]);case"defenseRating":return z("civics_garrison_defensive_rate");case"offenseRating":return z("civics_garrison_offensive_rate")}}}})},out:function(e){Cs({el:e.id},"destroy")}})})),a){let e=t.race.truepath?4:3;for(let t=0;t{{ label() }}"}),{elm:`#garrison .gov${t} button`,in:function(e){Cs({el:`#${e.id} > span`,data:{test:"val"},methods:{label:()=>ge(t)}})},out:function(e){Cs({el:e.id},"destroy")}});t.race.truepath&&!t.tech.isolation&&ls("garRivaldesc2",(function(){return z("civics_gov_tp_rival",[Z(3),Ki[t.race.species].home])}),{elm:"#garrison .gov3 > div"})}}function me(){let e=be(we(),"hunting"),a=[];if((!t.race.herbivore||t.race.carnivore)&&!t.race.artifical){let r=+(e/3).toFixed(2);a.push(r,t.resource.Food.name)}let r=+(e/10).toFixed(2);if(a.push(r,t.resource.Furs.name),t.race.evil&&!t.race.kindling_kindred&&!t.race.smoldering){let r=+(e/(t.race.soul_eater?3:5)).toFixed(2);a.push(r,t.resource.Lumber.name)}let i="civics_garrison_soldier_loot"+a.length/2;return z(t.race.evil&&t.race.soul_eater?"civics_garrison_soldier_evil_desc":"civics_garrison_soldier_desc")+z(i,a)}function ge(e){if(t.civic.foreign[`gov${e}`].occ)return z("civics_garrison_deoccupy_desc");if(t.civic.foreign[`gov${e}`].buy||t.civic.foreign[`gov${e}`].anx)return z("civics_garrison_secede_desc");if(t.civic.garrison.tactic<=1&&t.civic.foreign[`gov${e}`].spy<1||t.civic.garrison.tactic>=2&&t.civic.garrison.tactic<=3&&t.civic.foreign[`gov${e}`].spy<2||4===t.civic.garrison.tactic&&t.civic.foreign[`gov${e}`].spy<3)return z("civics_garrison_no_spy");let a=be(t.civic.garrison.raid,"army"),r=0;switch(t.civic.garrison.tactic){case 0:r=5;break;case 1:r=27.5;break;case 2:r=62.5;break;case 3:r=125;break;case 4:r=300}return r*=t.civic.foreign[`gov${e}`].mil/100,t.race.banana&&(r*=2),"swamp"===t.city.biome&&(r*=is.swamp.vars()[0]),cn("fool",2021)&&(r/=1.25),awe()?t.civic.garrison.raid=we():t.civic.garrison.raid<0&&(t.civic.garrison.raid=0),0===t.civic.garrison.raid)return void hs(z("civics_garrison_campaign_no_soldier"),"warning",!1,["combat"]);t.stats.attacks++;let a=t.race.claws?20:16,r=t.race.puny?3:5,i=Math.floor(m(r,a,!0))/10,s=be(t.civic.garrison.raid,"army")*i,n=0;switch(t.civic.garrison.tactic){case 0:n=m(0,10,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(0,2,!0));break;case 1:n=m(5,50,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(0,3,!0));break;case 2:n=m(25,100,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(1,5,!0));break;case 3:n=m(50,200,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(4,12,!0));break;case 4:n=m(100,500,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(10,25,!0))}n=Math.floor(n*t.civic.foreign[`gov${e}`].mil/100),t.race.banana&&(n*=2),"swamp"===t.city.biome&&(n*=is.swamp.vars()[0]),t.race.mistrustful&&(t.civic.foreign[`gov${e}`].hstl+=Ei.mistrustful.vars()[0]),t.civic.foreign[`gov${e}`].hstl>100&&(t.civic.foreign[`gov${e}`].hstl=100),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(n/5),t.race.blood_thirst_count>Ei.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=Ei.blood_thirst.vars()[0]));let c=0;if(t.civic.garrison.raid>t.civic.garrison.workers-t.civic.garrison.crew-t.civic.garrison.wounded&&(c=t.civic.garrison.raid-(t.civic.garrison.workers-t.civic.garrison.crew-t.civic.garrison.wounded)),t.civic.garrison.fatigue++,s>n){let a=Math.floor(t.civic.garrison.raid/(5-t.civic.garrison.tactic));a+=c,t.city.ptrait.includes("rage")&&(a+=ss.rage.vars()[2]),a<1&&(a=1),a>fe()&&(a=fe());let r=Math.floor(m(0,a,!0));t.race.frail&&(r+=Ei.frail.vars()[0]);let i=0;if(t.race.scales&&(i+=Ei.scales.vars()[0]),t.tech.armor&&(i+=t.tech.armor),t.race.high_pop&&(i+=Math.floor(m(0,i*Ei.high_pop.vars()[0],!0))),t.race.armored){let e=1-Ei.armored.vars()[0]/100;i+=Math.floor(r*e)}let s=ts("tortoisan");if(s>0){let e=1-Ei.armored.vars(1)[0]/100*s;i+=Math.floor(r*e)}if(t.civic.garrison.raid>c&&(r-=i),r<0&&(r=0),r>t.civic.garrison.raid&&(r=t.civic.garrison.raid),t.race.instinct){let e=Math.floor(r*(Ei.instinct.vars()[1]/100));r-=e,c+=e}t.civic.garrison.workers-=r,t.stats.died+=r,t.civic.garrison.protest+=r,r>c?(t.civic.garrison.wounded-=c,c=0):(t.civic.garrison.wounded-=r,c-=r),t.civic.garrison.wounded+=Math.floor(m(c,t.civic.garrison.raid-r,!0));let n={Money:0,Food:0,Lumber:0,Stone:0,Copper:0,Iron:0,Aluminium:0,Coal:0,Cement:0,Steel:0,Titanium:0,Crystal:0,Chrysotile:0,Furs:0,Iridium:0,Alloy:0,Polymer:0,Oil:0},o=3===e&&t.race.truepath?["Food","Lumber","Stone","Copper","Iron"]:["Food","Lumber","Stone"],l=3===e&&t.race.truepath?["Aluminium","Coal","Cement","Steel","Furs"]:["Copper","Iron","Aluminium","Coal"],_=3===e&&t.race.truepath?["Titanium","Oil","Iridium","Alloy","Polymer"]:["Cement","Steel"];t.race.artifical&&o.shift(),t.race.smoldering&&o.push("Chrysotile"),t.race.terrifying&&3!==e&&_.push("Titanium"),t.tech.magic&&_.push("Crystal");let d=["Money"];switch(t.civic.garrison.tactic){case 0:{let e=["Money"].concat(o,l);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))]),t.resource.Steel.amount<25&&t.tech.smelting&&1===t.tech.smelting&&0===Math.floor(m(0,20,!0))&&d.push("Steel")}break;case 1:{let e=["Money"].concat(o,l,_);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 2:{let e=["Money"].concat(o,l,_),a=l.concat(_);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),d.push(a[Math.floor(m(0,a.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 3:{let e=["Money"].concat(o,l,_);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(_[Math.floor(m(0,_.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 4:{let e=["Money"].concat(o,l,_);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(_[Math.floor(m(0,_.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}}let p=t.race.terrifying&&3!==e?Ei.terrifying.vars()[0]:12,u=t.race.terrifying&&3!==e?Ei.terrifying.vars()[1]:32;d.forEach((function(e){switch(e){case"Money":n[e]+=Math.floor(m(100,375,!0));break;case"Food":n[e]+=Math.floor(m(40,175,!0));break;case"Lumber":case"Stone":n[e]+=Math.floor(m(50,250,!0));break;case"Copper":case"Iron":case"Aluminium":n[e]+=Math.floor(m(35,125,!0));break;case"Coal":case"Cement":n[e]+=Math.floor(m(25,100,!0));break;case"Steel":case"Chrysotile":n[e]+=Math.floor(m(20,65,!0));break;case"Titanium":n[e]+=Math.floor(m(p,u,!0));break;case"Crystal":n[e]+=Math.floor(m(1,5,!0));break;case"Oil":n[e]+=Math.floor(m(20,50,!0));break;case"Iridium":n[e]+=Math.floor(m(2,30,!0));break;case"Alloy":case"Polymer":n[e]+=Math.floor(m(5,38,!0))}}));let h=z("civics_garrison_gained");t.resource.Money.display&&n.Money>0&&(n.Money=ye(n.Money,e),h+=z("civics_garrison_quant_money",[n.Money]),$s("Money",n.Money)),o.concat(l,_).forEach((function(a){n[a]>0&&(t.resource[a].display||"Steel"===a||"Titanium"===a)&&(n[a]=ye(n[a],e),h+=z("civics_garrison_quant_res",[n[a],t.resource[a].name]),$s(a,n[a]),"Steel"!==a&&"Titanium"!==a||(t.resource[a].display=!0))})),h=h.slice(0,-2),h+=".",hs(h,"warning",!1,["combat"]);let g=0;if(t.race.revive){switch(t.city.calendar.temp){case 0:g=Math.floor(m(0,Math.floor(r/Ei.revive.vars()[0]),!0));break;case 1:g=Math.floor(m(0,Math.floor(r/Ei.revive.vars()[1]),!0));break;case 2:g=Math.floor(m(0,Math.floor(r/Ei.revive.vars()[2]),!0))}t.civic.garrison.workers+=g}if(hs(g>0?z("civics_garrison_victorious_revive",[r,g]):z("civics_garrison_victorious",[r]),"success",!1,["combat"]),t.race.slaver&&t.city.slave_pen){let e=4*t.city.slave_pen.count;if(e>t.city.slave_pen.slaves){let a=Math.floor(m(0,t.civic.garrison.tactic+2,!0));a+t.city.slave_pen.slaves>e&&(a=e-t.city.slave_pen.slaves),a>0&&(t.city.slave_pen.slaves+=a,t.resource.Slave.amount=t.city.slave_pen.slaves,hs(z("civics_garrison_capture",[a]),"success",!1,["combat"]))}}if(t.race.infectious){let e=0;switch(t.civic.garrison.tactic){case 0:e=Math.floor(m(0,Ei.infectious.vars()[0],!0));break;case 1:e=Math.floor(m(0,Ei.infectious.vars()[1],!0));break;case 2:e=Math.floor(m(0,Ei.infectious.vars()[2],!0));break;case 3:e=Math.floor(m(0,Ei.infectious.vars()[3],!0));break;case 4:e=Math.floor(m(0,Ei.infectious.vars()[4],!0))}t.resource[t.race.species].amount+e>t.resource[t.race.species].max&&(e=t.resource[t.race.species].max-t.resource[t.race.species].amount),e>0&&(t.resource[t.race.species].amount+=e,"unemployed"!==t.civic.d_job&&(t.civic[t.civic.d_job].workers+=e),hs(1===e?z("civics_garrison_soldier_infected"):z("civics_garrison_soldiers_infected",[e]),"special",!1,["combat"]))}let v=ta("federation"===t.civic.govern.type?15:20);if(e<=2&&4===t.civic.garrison.tactic&&t.civic.garrison.workers>=v){let a=!t.tech.gov_fed&&!ce();if(t.civic.garrison.workers-=v,t.civic.foreign[`gov${e}`].occ=!0,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none",a&&Qr(),t.race.banana){let e=xn();t.stats.banana.b1[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b1.l=!0)}}}else{let e=t.civic.garrison.raid;e+=c,0===t.civic.garrison.tactic&&(e=Math.floor(e/2)),t.city.ptrait.includes("rage")&&(e+=ss.rage.vars()[2]),e<1&&(e=1),e>fe()&&(e=fe());let a=Math.floor(m(1,e,!0));t.race.frail&&(a+=t.civic.garrison.tactic+Ei.frail.vars()[1]);let r=0;if(t.race.scales&&(r+=Ei.scales.vars()[1]),t.tech.armor&&(r+=t.tech.armor),t.race.high_pop&&(r+=Math.floor(m(0,Math.floor(r*Ei.high_pop.vars()[0]/2),!0))),t.race.armored){let e=Ei.armored.vars()[0]/100;r+=Math.floor(a*e)}let i=ts("tortoisan");if(i>0){let e=Ei.armored.vars(1)[0]/100*i;r+=Math.floor(a*e)}if(t.civic.garrison.raid>c&&(a-=r),t.race.instinct){let e=Math.floor(a*(Ei.instinct.vars()[1]/100));a-=e,c+=e}a<1&&(a=1),a>t.civic.garrison.raid&&(a=t.civic.garrison.raid),t.civic.garrison.workers-=a,t.stats.died+=a,t.civic.garrison.protest+=a,a>c?(t.civic.garrison.wounded-=c,c=0):(t.civic.garrison.wounded-=a,c-=a),t.civic.garrison.wounded+=1+Math.floor(m(c,t.civic.garrison.raid-a,!0));let s=0;if(t.race.revive){switch(t.city.calendar.temp){case 0:s=Math.floor(m(0,Math.floor(a/Ei.revive.vars()[3]),!0));break;case 1:s=Math.floor(m(0,Math.floor(a/Ei.revive.vars()[4]),!0));break;case 2:s=Math.floor(m(0,Math.floor(a/Ei.revive.vars()[5]),!0))}t.civic.garrison.workers+=s}hs(s>0?z("civics_garrison_defeat_revive",[a,s]):z("civics_garrison_defeat",[a]),"danger",!1,["combat"])}t.civic.garrison.wounded>t.civic.garrison.workers-t.civic.garrison.crew?t.civic.garrison.wounded=t.civic.garrison.workers-t.civic.garrison.crew:t.civic.garrison.wounded<0&&(t.civic.garrison.wounded=0)}function fe(){let e=0,a=t.civic.garrison.raid;switch(t.civic.garrison.tactic){case 0:e=5;break;case 1:e=10;break;case 2:e=25;break;case 3:e=50;break;case 4:e=999}return t.race.high_pop&&(e=ta(e)),a>e&&(a=e),a}function ye(e,a){let r=fe();t.race.high_pop&&(r/=ta(1));let i=e*Math.log(r+1);switch(t.race.invertebrate&&(i*=1-Ei.invertebrate.vars()[0]/100),"evil"===t.race.universe&&(i*=Is("evil")),t.civic.garrison.tactic){case 1:i*=4;break;case 2:i*=30;break;case 3:i*=100;break;case 4:i*=400}return t.race.banana&&(i*=.5),"swamp"===t.city.biome&&(i*=is.swamp.vars()[1]),Math.floor(i*t.civic.foreign[`gov${a}`].eco/100)}function be(e,a,r){if(!t.civic.hasOwnProperty("garrison"))return 1;let i=0;"number"==typeof r?i=r:e>t.civic.garrison.workers-t.civic.garrison.wounded&&(i=e-(t.civic.garrison.workers-t.civic.garrison.wounded));let s=function(){let e=t.tech.military?t.tech.military>=5?t.tech.military-1:t.tech.military:1;if(t.tech.military&&t.tech.military>1){e-=t.tech.military>=11?2:1,t.race.sniper&&(e*=1+Ei.sniper.vars()[0]/100*e);let a=ts("centaur");a>0&&(e*=1+Ei.sniper.vars(1)[0]/100*e*a),e+=t.tech.military>=11?2:1}return e}(),n=ts("rhinotaur"),c=e-i/2;(t.race.rage||n>0)&&(c=e+(t.race.rage?i*Ei.rage.vars()[1]/100:0)+(n>0?i*Ei.rage.vars(1)[1]/100*n:0));let o=t.tech.military?c*s:c;if("army"===a||"hellArmy"===a){t.race.rage&&(o*=1+Ei.rage.vars()[0]/100*(t.civic.garrison.wounded||0)),n>0&&(o*=1+Ei.rage.vars(1)[0]/100*n*(t.civic.garrison.wounded||0)),t.race.puny&&(o*=1-Ei.puny.vars()[0]/100),t.race.claws&&(o*=1+Ei.claws.vars()[0]/100);let r=ts("scorpid");r>0&&(o*=1+Ei.claws.vars(1)[0]/100*r),t.race.chameleon&&(o*=1+Ei.chameleon.vars()[0]/100),t.race.cautious&&0===t.city.calendar.weather&&(o*=1-Ei.cautious.vars()[0]/100),t.race.apex_predator&&(o*=1+Ei.apex_predator.vars()[0]/100);let i=ts("sharkin");i>0&&(o*=1+Ei.apex_predator.vars(1)[0]/100*i),t.race.swift&&(o*=1+Ei.swift.vars()[0]/100),t.race.fiery&&(o*=1+Ei.fiery.vars()[0]/100);let s=ts("balorg");s>0&&(o*=1+Ei.fiery.vars(1)[0]/100*s),t.race.sticky&&(o*=1+Ei.sticky.vars()[1]/100);let c=ts("pinguicula");c>0&&(o*=1+Ei.sticky.vars(1)[1]/100*c),t.race.pathetic&&(o*=1-Ei.pathetic.vars()[0]/100),t.race.tactical&&(o*=1+Ei.tactical.vars()[0]*t.race.tactical/100),t.tech.fanaticism&&t.tech.fanaticism>=4&&(o*=1+.01*t.city.temple.count),t.race.holy&&"hellArmy"===a&&(o*=1+Ei.holy.vars()[0]/100);let l=ts("unicorn");l>0&&"hellArmy"===a&&(o*=1+Ei.holy.vars(1)[0]/100*l),t.race.banana&&"hellArmy"===a&&(o*=.8),"aries"===N()&&(o*=1+G("aries")[0]/100);let _=K("tactician",0);if(_&&(o*=1+_/100),t.city.ptrait.includes("rage")&&(o*=ss.rage.vars()[0]),t.race.parasite&&(1===e?o+=2:e>1&&(o+=4)),t.tech.psychic&&t.race.psychicPowers&&t.race.psychicPowers.hasOwnProperty("assaultTime")){let e=0;if(t.race.psychicPowers.assaultTime>0&&(e+=Ei.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(Ei.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.assault).toFixed(3)}o*=1+e}}return"hunting"===a&&t.race.unfathomable&&(o*=.66),t.race.rejuvenated&&(o*=1.05),"autocracy"===t.civic.govern.type&&(o*=1+Y.autocracy()[1]/100),o=Math.floor(o),o*Bi(e,a)}function we(e,a){if(!t.civic.garrison)return 0;let r=e?"max":"workers",i=t.portal.fortress?t.portal.fortress.garrison:0,s=t.space.fob&&!a?t.space.fob.troops:0;return t.civic.garrison[r]-t.civic.garrison.crew-i-s}function ke(e){return t.race.high_pop&&(e*=Ei.high_pop.vars()[1]/100),e}function $e(e,a){switch(e){case"transmitter":return 2.5;case"oil_well":{let e=t.tech.oil>=4?.48:.4;t.tech.oil>=7?e*=2:t.tech.oil>=5&&(e*=t.tech.oil>=6?1.75:1.25),t.city.geology.Oil&&(e*=t.city.geology.Oil+1),"desert"===t.city.biome?e*=is.desert.vars()[1]:"tundra"===t.city.biome?e*=is.tundra.vars()[1]:"taiga"===t.city.biome&&(e*=is.taiga.vars()[2]);let a=K("dirty_jobs",2);return a&&(e*=1+a/100),e}case"iridium_mine":switch(a){case"iridium":{let e=.035;t.city.geology.Iridium&&(e*=t.city.geology.Iridium+1);let a=e,r=J(3);return{b:a,g:r-1,f:a*r}}case"coal":return.55}case"helium_mine":{let e=.18,t=J(3);return{b:e,g:t-1,f:e*t}}case"red_mine":switch(a){case"copper":{let e=ke(.25),t=J(3);return{b:e,g:t-1,f:e*t}}case"titanium":{let e=ke(.02),t=J(3);return{b:e,g:t-1,f:e*t}}case"stone":return ke(.75);case"asbestos":return ke(1.25);case"aluminium":return ke(.066)}case"biodome":switch(a){case"food":return ke(.25);case"cat_food":return 2;case"lumber":return ke(1.5)}case"gas_mining":return t.tech.helium?.65:.5;case"outpost":{let e={b:.025,d:0,n:0};if(t.tech.drone){let a=t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3?.12:.06;e.d=t.space.drone.count*a,e.n=e.b*(1+e.d)}else e.n=e.b;return a?e:e.n}case"oil_extractor":{let e=t.tech.oil>=4?.48:.4;return t.tech.oil>=7?e*=2:t.tech.oil>=5&&(e*=t.tech.oil>=6?1.75:1.25),e}case"elerium_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?.009:.0075:.005;case"iridium_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?.1:.08:.055;case"iron_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?4:3:2;case"g_factory":if(t.race.truepath){if(t.tech.isolation)return 1.8;{let e=.05*(s.ai_colonist?t.civic.titan_colonist.workers+ta(s.ai_colonist):t.civic.titan_colonist.workers);return t.race.high_pop&&(e=ke(e)),e}}return.6;case"harvester":switch(a){case"helium":return.85;case"deuterium":return.15}case"elerium_prospector":return.014;case"neutron_miner":return.055;case"bolognium_ship":return.008;case"excavator":return.2;case"vitreloy_plant":{let e=.18;return"corpocracy"===t.civic.govern.type&&(e*=t.tech.high_tech&&t.tech.high_tech>=16?1.4:1.3),"socialist"===t.civic.govern.type&&(e*=1.1),e}case"infernite_mine":return.5*ga("gate").supress;case"water_freighter":return 1.25;case"titan_mine":switch(a){case"adamantite":return ke(.02)*(t.space.titan_mine?t.space.titan_mine.ratio:50)/100;case"aluminium":return ke(.12)*(100-(t.space.titan_mine?t.space.titan_mine.ratio:50))/100}case"lander":return 100===t.space.crashed_ship.count?.005:0;case"orichalcum_mine":return.08;case"uranium_mine":return.025;case"neutronium_mine":return.04;case"elerium_mine":return.009;case"shock_trooper":case"tank":return 100===t.space.digsite.count?.0018:0;case"mining_pit":{let e=0;switch(a){case"materials":e=t.tech.isolation?.12:.09;break;case"bolognium":e=t.tech.isolation?.0288:.0216;break;case"stone":e=t.tech.isolation?.8:.6;break;case"adamantite":e=t.tech.isolation?.448:.336;break;case"copper":e=.58;break;case"coal":e=.13;break;case"iron":e=.74;break;case"aluminium":e=.88;break;case"chrysotile":e=1.44}t.race.tough&&(e*=1+Ei.tough.vars()[0]/100);let r=ts("ogre");return r>0&&(e*=1+Ei.tough.vars(1)[0]/100*r),t.tech.tau_pit_mining&&(e*=1.18),e}case"tau_farm":switch(a){case"food":return t.tech.isolation?15:9;case"lumber":return t.tech.isolation?12:5.5;case"water":return.35}case"womling_mine":{let e=1;switch(t.tech.womling_mining&&(e+=.15*t.tech.womling_mining),t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5&&(e*=1.1),t.tech.womling_gene&&(e*=1.25),a){case"unobtainium":return.0305*e;case"uranium":return.047*e;case"titanium":return.616*e;case"copper":return 1.191*e;case"iron":return 1.377*e;case"aluminium":return 1.544*e;case"neutronium":return.382*e;case"iridium":return.535*e}}case"refueling_station":return t.tech.isolation?18.5:9.35;case"ore_refinery":return t.tech.tau_ore_mining?40:25;case"whaling_station":return 12;case"mining_ship":if(t.tauceti.patrol_ship){let e=1;return t.tauceti.patrol_ship.support>t.tauceti.patrol_ship.s_max&&(e=nn("curve",t.tauceti.patrol_ship.s_max/t.tauceti.patrol_ship.support,1.4)),(t.tech.tau_ore_mining&&t.tech.tau_ore_mining>=2?12:10)*e}return 0;case"mining_ship_ore":switch(a){case"iron":case"aluminium":return t.tech.isolation?2.22:1.85;case"iridium":case"neutronium":return t.tech.isolation?.42:.35;case"orichalcum":return t.tech.isolation?.3:.25;case"elerium":return t.tech.isolation?.024:.02}case"whaling_ship":if(t.tauceti.patrol_ship){let e=1;return t.tauceti.patrol_ship.support>t.tauceti.patrol_ship.s_max&&(e=nn("curve",t.tauceti.patrol_ship.s_max/t.tauceti.patrol_ship.support,1.4)),8*e}return 0;case"whaling_ship_oil":return t.tech.isolation?.78:.42;case"alien_outpost":return.01;case"psychic_boost":if(t.tech.psychic&&t.race.psychic&&t.race.psychicPowers&&t.race.psychicPowers.boost.r===a&&t.race.psychicPowers.hasOwnProperty("boostTime")){let e=0;if(t.race.psychicPowers.boostTime>0&&(e+=Ei.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(Ei.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.boost).toFixed(3)}return 1+e}return 1;case"psychic_cash":if(t.tech.psychic&&t.race.psychic&&t.race.psychicPowers&&t.race.psychicPowers.hasOwnProperty("cash")){let e=0;if(t.race.psychicPowers.cash>0&&(e+=Ei.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(Ei.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.cash).toFixed(3)}return 1+e}return 1}}function xe(e){switch(e){case"Physics":Te();break;case"Genetics":Ee();break;case"Monument":return Ce();case"PhysicsTech":return qe;case"GeneTech":return je;case"BloodTech":return Oe;case"Crispr":Ke();break;case"Blood":De()}}const qe={lhc:{title:()=>cn("fool",2022)?z("arpa_projects_railway_title"):z("arpa_projects_lhc_title"),desc:()=>cn("fool",2022)?z("arpa_projects_railway_desc"):z("arpa_projects_lhc_desc"),reqs:{high_tech:6},grant:"supercollider",effect(e){if(cn("fool",2022)&&!e)return qe.railway.effect(!0);let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?t.race.cataclysm?20:8:t.race.cataclysm?10:4;return t.tech.storage>=6?t.tech.particles&&t.tech.particles>=4?t.race.cataclysm?z("arpa_projects_lhc_cataclysm3",[a]):z("arpa_projects_lhc_effect3",[a,t.race.orbit_decayed?z("space_home_satellite_title"):_i()]):t.race.cataclysm?z("arpa_projects_lhc_cataclysm2",[a]):z("arpa_projects_lhc_effect2",[a,t.race.orbit_decayed?z("space_home_satellite_title"):_i()]):t.race.cataclysm?z("arpa_projects_lhc_cataclysm1",[a]):t.tech.isolation?z("arpa_projects_lhc_iso1",[a,z("tech_infectious_disease_lab_alt")]):z("arpa_projects_lhc_effect1",[a,t.race.orbit_decayed?z("space_home_satellite_title"):_i()])},cost:{Money:(e,t)=>Ie("lhc",e,25e5,1.05,t),Knowledge:(e,t)=>Ie("lhc",e,5e5,1.05,t),Copper:(e,t)=>Ie("lhc",e,125e3,1.05,t),Cement:(e,t)=>Ie("lhc",e,25e4,1.05,t),Aluminium:(e,t)=>Ie("lhc",e,35e4,1.05,t),Titanium:(e,t)=>Ie("lhc",e,5e4,1.05,t),Polymer:(e,t)=>Ie("lhc",e,12e3,1.05,t)}},stock_exchange:{title:z("arpa_projects_stock_exchange_title"),desc:z("arpa_projects_stock_exchange_desc"),reqs:{banking:9},grant:"stock_exchange",effect:()=>t.tech.banking>=10?t.race.cataclysm?t.tech.gambling&&t.tech.gambling>=4?z("arpa_projects_stock_exchange_cataclysm2"):z("arpa_projects_stock_exchange_cataclysm1"):t.tech.gambling&&t.tech.gambling>=4?z("arpa_projects_stock_exchange_effect3"):z("arpa_projects_stock_exchange_effect2"):z("arpa_projects_stock_exchange_effect1"),cost:{Money:(e,t)=>Ie("stock_exchange",e,3e6,1.06,t),Plywood:(e,t)=>Ie("stock_exchange",e,25e3,1.06,t),Brick:(e,t)=>Ie("stock_exchange",e,2e4,1.06,t),Wrought_Iron:(e,t)=>Ie("stock_exchange",e,1e4,1.06,t)}},tp_depot:{title:z("galaxy_gateway_depot"),desc:z("arpa_projects_depot_desc"),reqs:{high_tech:6,storage:4},grant:"tp_depot",path:["truepath"],effect:()=>z(t.tech.isolation?"arpa_projects_depot_effect_iso":"arpa_projects_depot_effect",[5,50]),cost:{Money:(e,t)=>Ie("tp_depot",e,18e5,1.08,t),Stone:(e,t)=>Ie("tp_depot",e,75e4,1.08,t),Iron:(e,t)=>Ie("tp_depot",e,25e4,1.08,t),Alloy:(e,t)=>Ie("tp_depot",e,3e4,1.08,t)}},launch_facility:{id:"arpalaunch_facility",title:z("arpa_projects_launch_facility_title"),desc:z("arpa_projects_launch_facility_desc"),reqs:{high_tech:7},condition:()=>!t.race.cataclysm&&!t.race.lone_survivor,grant:"launch_facility",rank:1,queue_complete:()=>t.tech.space>=1?0:1,effect:()=>z("arpa_projects_launch_facility_effect1"),cost:{Money:e=>Ie("launch_facility",e,2e6,1.1),Knowledge:e=>Ie("launch_facility",e,5e5,1.1),Cement:e=>Ie("launch_facility",e,15e4,1.1),Oil:e=>Ie("launch_facility",e,2e4,1.1),Sheet_Metal:e=>Ie("launch_facility",e,15e3,1.1),Alloy:e=>Ie("launch_facility",e,25e3,1.1)}},monument:{title(e){if(e)return z("arpa_project_monument_title");switch(t.arpa.m_type){case"Obelisk":return z("arpa_project_monument_obelisk");case"Statue":return z("arpa_project_monument_statue");case"Sculpture":return z("arpa_project_monument_sculpture");case"Monolith":return z("arpa_project_monument_monolith");case"Pillar":return z("arpa_project_monument_pillar");case"Megalith":return z("arpa_project_monument_megalith")}},desc:z("arpa_projects_monument_desc"),reqs:{monument:1},grant:"monuments",effect(){let e=K("gaslighter",2);return z("arpa_projects_monument_effect1",[e?2-e:2])},cost:{Stone:(e,t)=>ze("Stone",e,t),Aluminium:(e,t)=>ze("Aluminium",e,t),Cement:(e,t)=>ze("Cement",e,t),Steel:(e,t)=>ze("Steel",e,t),Lumber:(e,t)=>ze("Lumber",e,t),Crystal:(e,t)=>ze("Crystal",e,t)}},railway:{title:()=>cn("fool",2022)?z("arpa_projects_lhc_title"):z("arpa_projects_railway_title"),desc:()=>cn("fool",2022)?z("arpa_projects_lhc_desc"):z("arpa_projects_railway_desc"),reqs:{high_tech:6,trade:3},grant:"railway",effect(e){if(cn("fool",2022)&&!e)return qe.lhc.effect(!0);let a=t.stats.achieve.banana&&t.stats.achieve.banana.l>=2?1:0,r=t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?3:2;return t.race.cataclysm||t.race.orbit_decayed?(a+=t.space.gps?Math.floor(t.space.gps.count/3):0,z("arpa_projects_railway_cataclysm1",[a,r,3,1])):(a+=t.city.storage_yard?Math.floor(t.city.storage_yard.count/6):0,z("arpa_projects_railway_effect1",[a,r,6,1]))},cost:{Money:(e,t)=>Ie("railway",e,25e5,1.08,t),Lumber:(e,t)=>Ie("railway",e,75e4,1.08,t),Iron:(e,t)=>Ie("railway",e,3e5,1.08,t),Steel:(e,t)=>Ie("railway",e,45e4,1.08,t)}},roid_eject:{title:()=>z("arpa_projects_roid_eject_title",[Pe()]),desc:()=>z(t.tech.roid_eject<=10?"arpa_projects_roid_eject_desc":"arpa_projects_roid_eject_desc2",[Pe()]),reqs:{blackhole:6,gateway:3},grant:"roid_eject",effect(){let e=0,a=0;return t.tech.roid_eject&&(e+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12),a=.225*(t.tech.roid_eject+1)*(1+(t.tech.roid_eject+1)/12)-e),`
                ${z("arpa_projects_roid_eject_effect1")}
                ${z("arpa_projects_roid_eject_effect2",[+e.toFixed(3),+a.toFixed(3),Pe()])}
                `},cost:{Money:(e,t)=>Ie("roid_eject",e,1875e4,1.075,t),Deuterium:(e,t)=>Ie("roid_eject",e,375e3,1.075,t),Bolognium:(e,t)=>Ie("roid_eject",e,15e3,1.075,t)}},nexus:{title:z("arpa_projects_nexus_title"),desc:z("arpa_projects_nexus_desc"),reqs:{magic:5},grant:"nexus",effect:()=>t.tech.roguemagic&&t.tech.roguemagic>=7?`
                ${z("arpa_projects_nexus_effect1",[5])}
                ${z("witch_hunter_nexus",[8])}
                `:z("arpa_projects_nexus_effect1",[5]),cost:{Money:(e,t)=>Ie("nexus",e,5e6,1.12,t),Crystal:(e,t)=>Ie("nexus",e,6e4,1.12,t),Iridium:(e,t)=>Ie("nexus",e,35e3,1.12,t)}},syphon:{title:z("arpa_syphon_title"),desc(){let e="";return e=t.tech.syphon&&t.tech.syphon>=0?`
                ${z("arpa_syphon_desc")}
                ${z("arpa_syphon_desc_warn2")}
                `:`
                ${z("arpa_syphon_desc")}
                ${z("arpa_syphon_desc_warn1")}
                `,t.race.witch_hunter&&(e+=`
                ${z("witch_hunter_suspicion")}
                `),e},reqs:{veil:2},grant:"syphon",effect(){let e=+(1/3*Is("magic")).toFixed(3);if(t.tech.syphon&&t.tech.syphon>=60){let t=Gs("vacuum"),a=z("resource_Plasmid_plural_name");return`
                ${z("arpa_syphon_effect_main",[e])}
                ${z("arpa_syphon_effect4")}
                ${z("arpa_syphon_effect_reward",[t.plasmid,t.phage,t.dark,a,80])}
                `}return t.tech.syphon&&t.tech.syphon>=40?`
                ${z("arpa_syphon_effect_main",[e])}
                ${z("arpa_syphon_effect3")}
                `:t.tech.syphon&&t.tech.syphon>=20?`
                ${z("arpa_syphon_effect_main",[e])}
                ${z("arpa_syphon_effect2")}
                `:`
                ${z("arpa_syphon_effect_main",[e])}
                ${z("arpa_syphon_effect1")}
                `},cost:{Money:(e,t)=>Ie("syphon",e,75e5,1.025,t),Mana:(e,t)=>Ie("syphon",e,5e3,1.025,t),Crystal:(e,t)=>Ie("syphon",e,1e5,1.025,t),Infernite:(e,t)=>Ie("syphon",e,1e4,1.025,t)}}};function Pe(){return!t.tech.roid_eject||t.tech.roid_eject<=10?z("arpa_projects_roid_eject_asteroid"):t.tech.roid_eject<=25?z("arpa_projects_roid_eject_moon"):t.tech.roid_eject<=40?z("arpa_projects_roid_eject_dwarf"):t.tech.roid_eject<=60?z("arpa_projects_roid_eject_planet"):z("arpa_projects_roid_eject_remnant")}const je={genetic_memory:{id:"genes-genetic_memory",title:z("arpa_genepool_genetic_memory_title"),desc:z("arpa_genepool_genetic_memory_desc"),reqs:{},grant:["creep",1],cost:{Plasmid:()=>25},action:()=>!!Me("genetic_memory")},animus:{id:"genes-animus",title:z("arpa_genepool_animus_title"),desc:z("arpa_genepool_animus_desc"),reqs:{creep:1},grant:["creep",2],cost:{Plasmid:()=>75},action:()=>!!Me("animus")},divine_remembrance:{id:"genes-divine_remembrance",title:z("arpa_genepool_divine_remembrance_title"),desc:z("arpa_genepool_divine_remembrance_desc"),reqs:{creep:2},grant:["creep",3],cost:{Plasmid:()=>225},action:()=>!!Me("divine_remembrance")},divine_proportion:{id:"genes-divine_proportion",title:z("arpa_genepool_divine_proportion_title"),desc:z("arpa_genepool_divine_proportion_desc"),reqs:{creep:3},grant:["creep",4],cost:{Plasmid:()=>618},action:()=>!!Me("divine_proportion")},genetic_repository:{id:"genes-genetic_repository",title:z("arpa_genepool_genetic_repository_title"),desc:z("arpa_genepool_genetic_repository_desc"),reqs:{creep:4},grant:["creep",5],cost:{Plasmid:()=>999},action:()=>!!Me("genetic_repository")},spatial_reasoning:{id:"genes-spatial_reasoning",title:z("arpa_genepool_spatial_reasoning_title"),desc:z("arpa_genepool_spatial_reasoning_desc"),reqs:{},grant:["store",1],cost:{Plasmid:()=>50},action:()=>!!Me("spatial_reasoning")},spatial_superiority:{id:"genes-spatial_superiority",title:z("arpa_genepool_spatial_superiority_title"),desc:z("arpa_genepool_spatial_superiority_desc"),reqs:{store:1},grant:["store",2],cost:{Plasmid:()=>125},action:()=>!!Me("spatial_superiority")},spatial_supremacy:{id:"genes-spatial_supremacy",title:z("arpa_genepool_spatial_supremacy_title"),desc:z("arpa_genepool_spatial_supremacy_desc"),reqs:{store:2},grant:["store",3],cost:{Plasmid:()=>325},action:()=>!!Me("spatial_supremacy")},dimensional_warping:{id:"genes-dimensional_warping",title:z("arpa_genepool_dimensional_warping_title"),desc:z("arpa_genepool_dimensional_warping_desc"),reqs:{store:3},grant:["store",4],cost:{Plasmid:()=>500},action:()=>!!Me("dimensional_warping")},enhanced_muscle_fiber:{id:"genes-enhanced_muscle_fiber",title:z("arpa_genepool_enhanced_muscle_fiber_title"),desc:z("arpa_genepool_enhanced_muscle_fiber_desc"),reqs:{},grant:["enhance",1],cost:{Plasmid:()=>25},action:()=>!!Me("enhanced_muscle_fiber")},morphogenesis:{id:"genes-morphogenesis",title:z("arpa_genepool_morphogenesis_title"),desc:z("arpa_genepool_morphogenesis_desc"),reqs:{},grant:["evolve",1],cost:{Plasmid:()=>10},action:()=>!!Me("morphogenesis")},recombination:{id:"genes-recombination",title:z("arpa_genepool_recombination_title"),desc:z("arpa_genepool_recombination_desc"),reqs:{evolve:1},grant:["evolve",2],cost:{Plasmid:()=>35},action:()=>!!Me("recombination")},homologous_recombination:{id:"genes-homologous_recombination",title:z("arpa_genepool_homologous_recombination_title"),desc:z("arpa_genepool_homologous_recombination_desc"),reqs:{evolve:2},grant:["evolve",3],cost:{Plasmid:()=>70},action:()=>!!Me("homologous_recombination")},genetic_reshuffling:{id:"genes-genetic_reshuffling",title:z("arpa_genepool_genetic_reshuffling_title"),desc:z("arpa_genepool_genetic_reshuffling_desc"),reqs:{evolve:3},grant:["evolve",4],cost:{Plasmid:()=>175},action:()=>!!Me("genetic_reshuffling")},recombinant_dna:{id:"genes-recombinant_dna",title:z("arpa_genepool_recombinant_dna_title"),desc:z("arpa_genepool_recombinant_dna_desc"),reqs:{evolve:4},grant:["evolve",5],cost:{Plasmid:()=>440},action:()=>!!Me("recombinant_dna")},chimeric_dna:{id:"genes-chimeric_dna",title:z("arpa_genepool_chimeric_dna_title"),desc:z("arpa_genepool_chimeric_dna_desc"),reqs:{evolve:5},grant:["evolve",6],cost:{Plasmid:()=>1100},action:()=>!!Me("chimeric_dna")},molecular_cloning:{id:"genes-molecular_cloning",title:z("arpa_genepool_molecular_cloning_title"),desc:z("arpa_genepool_molecular_cloning_desc"),reqs:{evolve:6},grant:["evolve",7],cost:{Plasmid:()=>2750},action:()=>!!Me("molecular_cloning")},transgenes:{id:"genes-transgenes",title:z("arpa_genepool_transgenes_title"),desc:z("arpa_genepool_transgenes_desc"),reqs:{evolve:7},grant:["evolve",8],cost:{Plasmid:()=>6875},action:()=>!!Me("transgenes")},synthesis:{id:"genes-synthesis",title:z("arpa_genepool_synthesis_title"),desc:z("arpa_genepool_synthesis_desc",[2,10]),reqs:{evolve:1},grant:["synthesis",1],cost:{Plasmid:()=>25},action:()=>!!Me("synthesis")},karyokinesis:{id:"genes-karyokinesis",title:z("arpa_genepool_karyokinesis_title"),desc:z("arpa_genepool_synthesis_desc",[3,25]),reqs:{synthesis:1},grant:["synthesis",2],cost:{Plasmid:()=>40},action:()=>!!Me("karyokinesis")},cytokinesis:{id:"genes-cytokinesis",title:z("arpa_genepool_cytokinesis_title"),desc:z("arpa_genepool_synthesis_desc",[4,50]),reqs:{synthesis:2},grant:["synthesis",3],cost:{Plasmid:()=>55},action:()=>!!Me("cytokinesis")},mitosis:{id:"genes-mitosis",title:z("arpa_genepool_mitosis_title"),desc:z("arpa_genepool_mitosis_desc",[3]),reqs:{synthesis:3,evolve:2},grant:["plasma",1],cost:{Plasmid:()=>90},action:()=>!!Me("mitosis")},metaphase:{id:"genes-metaphase",title:z("arpa_genepool_metaphase_title"),desc:z("arpa_genepool_mitosis_desc",[5]),reqs:{plasma:1},grant:["plasma",2],cost:{Plasmid:()=>165},action:()=>!!Me("mitosis")},mutation:{id:"genes-mutation",title:z("arpa_genepool_mutation_title"),desc:z("arpa_genepool_mutation_desc"),reqs:{synthesis:3,creep:5},grant:["mutation",1],cost:{Plasmid:()=>1250},action:()=>!!Me("mutation")&&(t.genes.mutation=1,Ee(),!0)},transformation:{id:"genes-transformation",title:z("arpa_genepool_transformation_title"),desc:z("arpa_genepool_transformation_desc"),reqs:{mutation:1},grant:["mutation",2],cost:{Plasmid:()=>1500},action:()=>!!Me("transformation")&&(t.genes.mutation=2,Ee(),!0)},metamorphosis:{id:"genes-metamorphosis",title:z("arpa_genepool_metamorphosis_title"),desc:z("arpa_genepool_metamorphosis_desc"),reqs:{mutation:2},grant:["mutation",3],cost:{Plasmid:()=>1750},action:()=>!!Me("metamorphosis")&&(t.genes.mutation=3,Ee(),!0)},replication:{id:"genes-replication",title:z("arpa_genepool_replication_title"),desc:z("arpa_genepool_replication_desc"),reqs:{evolve:1},grant:["birth",1],cost:{Plasmid:()=>65},action:()=>!!Me("replication")},artificer:{id:"genes-artificer",title:z("arpa_genepool_artificer_title"),desc:z("arpa_genepool_artificer_desc"),reqs:{evolve:1},grant:["crafty",1],cost:{Plasmid:()=>45},action:()=>!!Me("artificer")},detail_oriented:{id:"genes-detail_oriented",title:z("arpa_genepool_detail_oriented_title"),desc:z("arpa_genepool_crafting_desc",["50"]),reqs:{crafty:1},grant:["crafty",2],cost:{Plasmid:()=>90},action:()=>!!Me("detail_oriented")},rigorous:{id:"genes-rigorous",title:z("arpa_genepool_rigorous_title"),desc:z("arpa_genepool_crafting_desc",["100"]),reqs:{crafty:2},grant:["crafty",3],cost:{Plasmid:()=>135},action:()=>!!Me("rigorous")},geographer:{id:"genes-geographer",title:z("arpa_genepool_geographer_title"),desc:z("arpa_genepool_geographer_desc"),reqs:{store:1},grant:["queue",1],cost:{Plasmid:()=>75},action:()=>!!Me("geographer")},architect:{id:"genes-architect",title:z("arpa_genepool_architect_title"),desc:z("arpa_genepool_architect_desc"),reqs:{queue:1},grant:["queue",2],cost:{Plasmid:()=>160},action:()=>!!Me("architect"),post(){vs(),fs()}},precognition:{id:"genes-precognition",title:z("arpa_genepool_precognition_title"),desc:z("arpa_genepool_precognition_desc"),reqs:{queue:2},grant:["queue",3],condition:()=>t.stats.aiappoc>0,cost:{Plasmid:()=>3500,Phage:()=>100,AICore:()=>1},action:()=>!!Me("precognition")},governance:{id:"genes-governance",title:z("arpa_genepool_governance_title"),desc:z("arpa_genepool_governance_desc"),reqs:{queue:2},grant:["governor",1],cost:{Plasmid:()=>300,Phage:()=>25},action:()=>!!Me("governance")},civil_service:{id:"genes-civil_service",title:z("arpa_genepool_civil_service_title"),desc:z("arpa_genepool_civil_service_desc"),reqs:{governor:1},grant:["governor",2],cost:{Plasmid:()=>1e3,Harmony:()=>1},action:()=>!!Me("civil_service"),post(){if(t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks"))for(let e=0;e<6;e++)t.race.governor.tasks.hasOwnProperty(`t${e}`)||(t.race.governor.tasks[`t${e}`]="none");L()}},hardened_genes:{id:"genes-hardened_genes",title:z("arpa_genepool_hardened_genes_title"),desc:z("arpa_genepool_hardened_genes_desc"),reqs:{},grant:["challenge",1],cost:{Plasmid:()=>5},action:()=>!!Me("hardened_genes")},unlocked:{id:"genes-unlocked",title:z("arpa_genepool_unlocked_title"),desc:z("arpa_genepool_unlocked_desc"),reqs:{challenge:1},grant:["challenge",2],cost:{Plasmid:()=>50},action:()=>!!Me("unlocked"),post(){Ts(!0)}},universal:{id:"genes-universal",title:z("arpa_genepool_universal_title"),desc:z("arpa_genepool_universal_desc"),reqs:{challenge:2},grant:["challenge",3],condition:()=>"standard"!==t.race.universe,cost:{Plasmid:()=>400},action:()=>!!Me("universal"),post(){Ts(!0)}},standard:{id:"genes-standard",title:z("arpa_genepool_standard_title"),desc:z("arpa_genepool_standard_desc"),reqs:{challenge:3},grant:["challenge",4],condition:()=>"standard"!==t.race.universe,cost:{Plasmid:()=>2500},action:()=>!!Me("standard"),post(){Ts(!0)}},mastered:{id:"genes-mastered",title:z("arpa_genepool_mastered_title"),desc:z("arpa_genepool_mastered_desc"),reqs:{challenge:4},grant:["challenge",5],cost:{Plasmid:()=>4e3},action:()=>!!Me("mastered")},negotiator:{id:"genes-negotiator",title:z("arpa_genepool_negotiator_title"),desc:z("arpa_genepool_negotiator_desc"),reqs:{challenge:2},grant:["trader",1],cost:{Plasmid:()=>750},action:()=>!!Me("negotiator")&&(t.genes.trader=1,Ge(),!0)},ancients:{id:"genes-ancients",title:z("arpa_genepool_ancients_title"),desc:z("arpa_genepool_ancients_desc"),reqs:{evolve:2},condition:()=>!!t.genes.old_gods,grant:["ancients",1],cost:{Plasmid:()=>120},action:()=>!!Me("ancients")&&(t.genes.ancients=1,Qr(),!0)},faith:{id:"genes-faith",title:z("arpa_genepool_faith_title"),desc:z("arpa_genepool_faith_desc"),reqs:{ancients:1},grant:["ancients",2],cost:{Plasmid:()=>300},action:()=>!!Me("faith")&&(t.civic.priest.display=!0,!0)},devotion:{id:"genes-devotion",title:z("arpa_genepool_devotion_title"),desc:z("arpa_genepool_devotion_desc"),reqs:{ancients:2},grant:["ancients",3],cost:{Plasmid:()=>600},action:()=>!!Me("devotion")},acolyte:{id:"genes-acolyte",title:z("arpa_genepool_acolyte_title"),desc:z("arpa_genepool_acolyte_desc"),reqs:{ancients:3},grant:["ancients",4],cost:{Plasmid:()=>1e3},action:()=>!!Me("acolyte")},conviction:{id:"genes-conviction",title:z("arpa_genepool_conviction_title"),desc:z("arpa_genepool_conviction_desc"),reqs:{ancients:4},grant:["ancients",5],cost:{Plasmid:()=>1500},action:()=>!!Me("conviction")},transcendence:{id:"genes-transcendence",title:z("arpa_genepool_transcendence_title"),desc:z("arpa_genepool_transcendence_desc"),reqs:{ancients:1,mutation:3},grant:["transcendence",1],cost:{Plasmid:()=>3e3},action:()=>!!Me("transcendence")&&(t.genes.transcendence=1,Qr(),!0)},bleeding_effect:{id:"genes-bleeding_effect",title:z("arpa_genepool_bleeding_effect_title"),desc:z("arpa_genepool_bleeding_effect_desc",[2.5]),reqs:{creep:2},grant:["bleed",1],condition:()=>"antimatter"===t.race.universe,cost:{Plasmid:()=>100},action:()=>!!Me("bleeding_effect")},synchronicity:{id:"genes-synchronicity",title:z("arpa_genepool_synchronicity_title"),desc:z("arpa_genepool_synchronicity_desc",[25]),reqs:{bleed:1},grant:["bleed",2],cost:{Plasmid:()=>500},action:()=>!!Me("synchronicity")},astral_awareness:{id:"genes-astral_awareness",title:z("arpa_genepool_astral_awareness_title"),desc:z("arpa_genepool_astral_awareness_desc"),reqs:{bleed:2},grant:["bleed",3],cost:{Plasmid:()=>1e3},action:()=>!!Me("astral_awareness")},blood_remembrance:{id:"genes-blood_remembrance",title:z("arpa_genepool_blood_remembrance_title"),desc:z("arpa_genepool_blood_remembrance_desc"),reqs:{},grant:["blood",1],condition:()=>t.prestige.Blood_Stone.count>=1,cost:{Plasmid:()=>1e3,Phage:()=>10},action:()=>!!Me("blood_remembrance")},blood_sacrifice:{id:"genes-blood_sacrifice",title:z("arpa_genepool_blood_sacrifice_title"),desc:z("arpa_genepool_blood_sacrifice_desc"),reqs:{blood:1},grant:["blood",2],cost:{Plasmid:()=>3e3,Phage:()=>100,Artifact:()=>1},action:()=>!!Me("blood_sacrifice")},essence_absorber:{id:"genes-essence_absorber",title:z("arpa_genepool_essence_absorber_title"),desc:z("arpa_genepool_essence_absorber_desc"),reqs:{blood:2},grant:["blood",3],cost:{Plasmid:()=>7500,Phage:()=>250,Artifact:()=>1},action:()=>!!Me("essence_absorber"),post(){De()}}},Oe={purify:{id:"blood-purify",title:z("arpa_blood_purify_title"),desc:z("arpa_blood_purify_desc"),reqs:{},grant:["spire",1],cost:{Blood_Stone:()=>10},action(){return!!Se($(this)[0].cost)}},chum:{id:"blood-chum",title:z("arpa_blood_chum_title"),desc:z("arpa_blood_chum_desc"),reqs:{spire:1},grant:["spire",2],cost:{Blood_Stone:()=>25},action(){return!!Se($(this)[0].cost)}},lust:{id:"blood-lust",title:z("arpa_blood_lust_title"),desc:z("arpa_blood_lust_desc"),reqs:{},grant:["lust","*"],cost:{Blood_Stone:e=>15*((e||0)+(t.blood.lust||0))+15,Artifact:e=>((e||0)+(t.blood.lust||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},illuminate:{id:"blood-illuminate",title:z("arpa_blood_illuminate_title"),desc:z("arpa_blood_illuminate_desc"),reqs:{},grant:["illuminate","*"],cost:{Blood_Stone:e=>12*((e||0)+(t.blood.illuminate||0))+12,Artifact:e=>((e||0)+(t.blood.illuminate||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},greed:{id:"blood-greed",title:z("arpa_blood_greed_title"),desc:z("arpa_blood_greed_desc"),reqs:{},grant:["greed","*"],cost:{Blood_Stone:e=>16*((e||0)+(t.blood.greed||0))+16,Artifact:e=>((e||0)+(t.blood.greed||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},hoarder:{id:"blood-hoarder",title:z("arpa_blood_hoarder_title"),desc:z("arpa_blood_hoarder_desc"),reqs:{},grant:["hoarder","*"],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:e=>14*((e||0)+(t.blood.hoarder||0))+14,Artifact:e=>((e||0)+(t.blood.hoarder||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},artisan:{id:"blood-artisan",title:z("arpa_blood_artisan_title"),desc:z("arpa_blood_artisan_desc"),reqs:{},grant:["artisan","*"],cost:{Blood_Stone:e=>8*((e||0)+(t.blood.artisan||0))+8,Artifact:e=>((e||0)+(t.blood.artisan||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},attract:{id:"blood-attract",title:z("arpa_blood_attract_title"),desc:z("arpa_blood_attract_desc"),reqs:{},grant:["attract","*"],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:e=>4*((e||0)+(t.blood.attract||0))+4,Artifact:e=>((e||0)+(t.blood.attract||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},wrath:{id:"blood-wrath",title:z("arpa_blood_wrath_title"),desc:z("arpa_blood_wrath_desc"),reqs:{},grant:["wrath","*"],cost:{Blood_Stone:e=>2*((e||0)+(t.blood.wrath||0))+2,Artifact:()=>1},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},prepared:{id:"blood-prepared",title:z("arpa_blood_prepared_title"),desc:z("arpa_blood_prepared_desc"),reqs:{},grant:["prepared",1],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>50},action(){return!!Se($(this)[0].cost)},post(){ya()}},compact:{id:"blood-compact",title:z("arpa_blood_compact_title"),desc:z("arpa_blood_compact_desc"),reqs:{prepared:1},grant:["prepared",2],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>75},action(){return!!Se($(this)[0].cost)}},infernal:{id:"blood-infernal",title:z("arpa_blood_infernal_title"),desc:z("arpa_blood_infernal_desc"),reqs:{prepared:2},grant:["prepared",3],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>125,Artifact:()=>1},action(){return!!Se($(this)[0].cost)}},unbound:{id:"blood-unbound",title:z("arpa_blood_unbound_title"),desc:z("arpa_blood_unbound_desc"),reqs:{},grant:["unbound",1],cost:{Blood_Stone:()=>50},action(){return!!Se($(this)[0].cost)}},unbound_resistance:{id:"blood-unbound_resistance",title:z("arpa_blood_unbound_resistance_title"),desc:z("arpa_blood_unbound_resistance_desc"),reqs:{unbound:1},grant:["unbound",2],cost:{Blood_Stone:()=>100},action(){return!!Se($(this)[0].cost)}},shadow_war:{id:"blood-shadow_war",title:z("arpa_blood_shadow_war_title"),desc:z("arpa_blood_shadow_war_desc"),reqs:{unbound:2},grant:["unbound",3],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>250,Artifact:()=>2},action(){return!!Se($(this)[0].cost)}},unbound_immunity:{id:"blood-unbound_immunity",title:z("arpa_blood_unbound_immunity_title"),desc:z("arpa_blood_unbound_immunity_desc"),reqs:{unbound:3},grant:["unbound",4],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>500},action(){return!!Se($(this)[0].cost)}},blood_aware:{id:"blood-blood_aware",title:z("arpa_blood_blood_aware_title"),desc:z("arpa_blood_blood_aware_desc"),reqs:{},grant:["aware",1],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>10},action(){return!!Se($(this)[0].cost)}}};function Me(e){let a=!0,r=je[e].cost;return Object.keys(r).forEach((function(e){let i=e;"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].countNumber(t.resource[r].amount))return a=!1,!1})),a}(e=Ae(e))&&(Object.keys(e).forEach((function(a){t.resource[a].amount-=e[a]()/100})),!0)}function Ae(e,a,r){return e=function(e,a,r){if(r&&r.creative||!r&&t.race.creative){var i={};let t=ts("human");return Object.keys(e).forEach((function(s){i[s]=function(){let i=e[s](a,r);return i*=1-Ei.creative.vars()[1]/100,t>0&&(i*=1-Ei.creative.vars(1)[1]/100*t),i}})),i}return e}(e,a,r),Ns({cost:e},a,r)}function Ie(e,a,r,i,s){var n=t.arpa[e]?t.arpa[e].rank:0;return(s&&s.creative||!s&&t.race.creative)&&"syphon"!==e&&(i-=Ei.creative.vars()[0]),a&&(n+=a),Math.round(i**n*r)}function Te(){if(t.tech.high_tech&&t.tech.high_tech>=6){let e=$("#arpaPhysics");Ss(e),Object.keys(qe).forEach((function(a){!function(e,a){if(function(e){if(qe[e].condition&&!qe[e].condition())return!1;let a=t.race.truepath?"truepath":"standard";if(qe[e].hasOwnProperty("path")&&!qe[e].path.includes(a))return!1;var r=!0;return Object.keys(qe[e].reqs).forEach((function(a){(!t.tech[a]||t.tech[a]=qe[a].rank)return;let r=$(`
                `);e.append(r);let i="string"==typeof qe[a].title?qe[a].title:qe[a].title(),s=$(`
                ${i}{{ rank | level }}
                `);r.append(s);let n=$('
                {{ complete }}%
                ');s.append(n);let c=$('
                ');r.append(c),c.append($(``)),c.append($(``)),c.append($(``)),c.append($(``)),c.append($(``)),Cs({el:`#arpa${a}`,data:t.arpa[a],methods:{queue(e){if(t.tech.queue){let r=y();for(let i=0;i0))break;if("merge_never"!==t.settings.q_merge&&t.queue.queue.length>0&&t.queue.queue[t.queue.queue.length-1].id===r)t.queue.queue[t.queue.queue.length-1].q++;else{let a="string"==typeof qe[e].title?qe[e].title:qe[e].title();t.queue.queue.push({id:r,action:"arpa",type:e,label:a,cna:!1,time:0,q:1,qs:1,t_max:0})}ys()}}},build(e,a){!function(e,a,r,i){let s=!1;100===a&&(a=100-t.arpa[e].complete);for(let r=0;r=100&&(t.arpa[e].rank++,t.arpa[e].complete=0,t.tech[qe[e].grant]=t.arpa[e].rank,s=!0,"monument"===e&&(t.arpa.m_type=Ce(),$(`#arpa${e} .head .desc`).html(qe[e].title()),ui(!1,["arpamonument"])),"roid_eject"===e&&($(`#arpa${e} .head .desc`).html(qe[e].title()),ui(!1,["arparoid_eject"])),"launch_facility"===e&&(t.settings.showSpace=!0,t.tech.space=1,_s("popArpalaunch_facility"),[1,10,25,100].forEach((function(e){_s(`popArpalaunch_facility${e}`)})),ms(["arpalaunch_facility"]),Te(),Lt(),hs(z("arpa_projects_launch_facility_msg"),"info",!1,["progress"])),t.race.inflation&&(t.race.inflation+=10),Qr()));{let t=[1,10,25,100],a=$("#popper"),r=a.data("id");for(let i=0;iq(qe[a].desc),srLevel:()=>q(qe[a].effect()),arpaProjectSRCosts(e,a){let r="100"===e?100-t.arpa[a].complete:e;var i=`Construct ${r}%. Costs:`,s=Ae(qe[a].cost);return Object.keys(s).forEach((function(e){var a=+(s[e]()*(r/100)).toFixed(0);if(a>0){var n="Money"===e?"$":t.resource[e].name+": ",c=t.resource[e].amount>=a?"":` ${z("insufficient")} ${t.resource[e].name}.`;i+=` ${n} ${x(a,2)}.${c}`}})),i}},filters:{remain:e=>100-e,level:e=>z("arpa_level",[e])}}),ls(`popArpa${a}`,(function(){return qe[a].desc}),{elm:`#arpa${a} .head .desc`,classes:"has-background-light has-text-dark"}),ls(`popArpa${a}`,(function(){return qe[a].effect()}),{elm:`#arpa${a} .head .rank`,classes:"has-background-light has-text-dark"});let o=[1,10,25,100];for(let e=0;e1){let a=$('
                ');e.append(a);let r=t.tech.genetics>2?z("arpa_gene_mutation"):z("arpa_sequence_genome");t.race.artifical&&(r=t.tech.genetics>2?z("arpa_code_modification"):z("arpa_decompile_source"));let i=$(`
                ${r} - ${z("arpa_to_complete")}
                `);a.append(i);let s=$(`{{ progress }}%`);a.append(s);let n=t.tech.genetics>2?z("arpa_mutate"):z("arpa_sequence");t.race.artifical&&(n=t.tech.genetics>2?z("arpa_modify"):z("arpa_decompile"));let c=$(``);if(a.append(c),t.tech.genetics>=5){let e=$(``);a.append(e)}if(t.tech.genetics>=6){let e=$(``);a.append(e)}if(t.tech.genetics>=7){let e=$(``);a.append(e)}t.arpa.sequence.on&&$("#arpaSequence button.seq").addClass("has-text-success"),t.arpa.sequence.boost&&$("#arpaSequence button.boost").addClass("has-text-success"),t.arpa.sequence.auto&&$("#arpaSequence button.auto").addClass("has-text-success"),Cs({el:"#arpaSequence",data:t.arpa.sequence,methods:{toggle(){t.arpa.sequence.on?(t.arpa.sequence.on=!1,$("#arpaSequence button.seq").removeClass("has-text-success")):(t.arpa.sequence.on=!0,$("#arpaSequence button.seq").addClass("has-text-success"))},booster(){t.arpa.sequence.boost?(t.arpa.sequence.boost=!1,$("#arpaSequence button.boost").removeClass("has-text-success")):(t.arpa.sequence.boost=!0,$("#arpaSequence button.boost").addClass("has-text-success"))},boostLabel:e=>z(t.race.artifical?"arpa_boost_artifical_label":"arpa_boost_label")+(e?t.arpa.sequence.boost?z("city_on"):z("city_off"):""),novo(){let e=y();for(let a=0;a=2e5;a++)t.resource.Knowledge.amount-=2e5,t.resource.Genes.amount++},novoLabel:()=>z(t.race.artifical?"arpa_novo_artifical_label":"arpa_novo_label",["200k"]),auto_seq(){t.arpa.sequence.auto?(t.arpa.sequence.auto=!1,$("#arpaSequence button.auto").removeClass("has-text-success")):(t.arpa.sequence.auto=!0,$("#arpaSequence button.auto").addClass("has-text-success"))},autoLabel:e=>z(t.race.artifical?"arpa_auto_compile_label":"arpa_auto_seq_label")+(e?t.arpa.sequence.boost?z("city_on"):z("city_off"):"")},filters:{timer(e){if(t.arpa.sequence.on&&t.arpa.sequence.labs>0)return t.arpa.sequence.boost?zs(e/(2*t.arpa.sequence.labs)):zs(e/t.arpa.sequence.labs);{let e=Qs(14,12);return e.length>0?e:z("time_never")}}}}),ls("popArpaSeq",(function(){return t.tech.genetics>2?t.race.artifical?z("arpa_modify_desc"):z("arpa_mutate_desc"):t.race.artifical?z("arpa_decompile_desc"):z("arpa_sequence_desc")}),{elm:"#arpaSequence .seqlbl",classes:"has-background-light has-text-dark"})}if(t.tech.genetics>2){let e=$('
                ');$("#arpaGenetics").append(e);let a=$('
                ');e.append(a),t.tech.decay&&t.tech.decay>=2&&(t.settings.mtorder.includes("fortify")||t.settings.mtorder.push("fortify")),Object.keys(t.race).forEach((function(e){Ei[e]&&"minor"===Ei[e].type&&(t.settings.mtorder.includes(e)||t.settings.mtorder.push(e))})),t.genes.challenge&&t.genes.challenge>=5&&(t.settings.mtorder.includes("mastery")||t.settings.mtorder.push("mastery"));let r=!1,i=[];t.settings.mtorder.forEach((function(e){(Ei[e]&&"minor"===Ei[e].type||"mastery"===e||"fortify"===e)&&("fortify"!==e||t.tech.decay&&t.tech.decay>=2)&&(!["promiscuous","content","resilient","industrious","tactical","fibroblast"].includes(e)&&t.race.lone_survivor||!t.race.lone_survivor)&&(r=!0,function(e,a){let r=$(`
                `),i=$(`${t.resource.Genes.name} (${t.race.minor[a]||0})`);if(r.append(i),t.prestige.Phage.count>0){let e=$(`${z("resource_Phage_name")} (${t.genes.minor[a]||0})`);r.append(e)}let s=t.race[a]>1?`(${t.race[a]}) `:"";r.append(`${s}${as("name",a)}`),e.append(r)}(a,e),i.push(e))})),e.append(`
                ${z("arpa_race_genetic_traids",[nn("name")])}
                `);let s=as("name"),n=[],c=[],o=$('
                ');e.append(o);let l=sn(t.race);cn("fool",2023)&&(l.hooved=1),Object.keys(l).forEach((function(e){if(Ei[e]&&"minor"!==Ei[e].type&&"special"!==Ei[e].type&&"evil"!==e&&"soul_eater"!==e&&"artifical"!==e){let a=!1;if(t.race.ss_traits&&t.race.ss_traits.includes(e)||t.race.iTraits&&t.race.iTraits.hasOwnProperty(e)?a=!0:("sludge"!==t.race.species||"ooze"!==e&&!t.race.modified)&&t.race.hasOwnProperty(e)||(a=!0),!a&&("major"===Ei[e].type&&t.genes.mutation||"genus"===Ei[e].type&&t.genes.mutation&&t.genes.mutation>=2)){let t=$('
                '),a=$(`${z("arpa_remove_button")}`);n.push(e),t.append(a),t.append($(`${s[e]?s[e]:Ei[e].name} (${z("arpa_genepool_rank",[l[e]])})`)),o.append(t)}else c.push(e),o.append(`
                ${s[e]?s[e]:Ei[e].name} (${z("arpa_genepool_rank",[l[e]])})
                `)}}));let _=[];if(t.genes.mutation&&t.genes.mutation>=3&&("sludge"!==t.race.species||!t.race.modified)){e.append(`
                ${z("arpa_race_genetic_gain")}
                `);let a=["dumb","smart"];Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&"custom"!==e&&Ki[e].type===Ki[t.race.species].type&&Object.keys(Ki[e].traits).forEach((function(e){if(!t.race[e]&&"soul_eater"!==e){let r=a.indexOf(e);if(-1===r)_.push(e);else{let i=!1;switch(r%2){case 0:t.race[a[r+1]]&&(i=!0);break;case 1:t.race[a[r-1]]&&(i=!0)}i||_.push(e)}}}))}));let r=$('
                ');e.append(r);for(let e=0;e<_.length;e++){let t=_[e],a=$('
                '),i=$(`${z("arpa_gain_button")}`);a.append(i),a.append($(`${s[t]?s[t]:Ei[t].name}`)),r.append(a)}}r&&e.prepend(`
                ${z("arpa_race_genetic_minor_traits",[nn("name")])}
                `);let d=function(e){let a=5*Ei[e].val;return"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1),z("arpa_remove",[as("name",e),a,"antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name")])},p=function(e){let a=5*Ei[e].val;return"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1),z("arpa_gain",[as("name",e),a,"antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name")])},u=function(e){let a=Ys(t.race.minor[e]?t.race.minor[e]+4:4);return"mastery"===e&&(a*=5),z("arpa_gene_buy",[as("name",e),x(a),t.resource.Genes.name])},h=function(e){let a=Ys(t.genes.minor[e]?t.genes.minor[e]+4:4);return"mastery"===e&&(a*=2),z("arpa_phage_buy",[as("name",e),x(a),z("resource_Phage_name")])};Cs({el:"#geneticBreakdown",data:{genes:t.genes,race:t.race},methods:{gene(e){let a=0,r=y(),i=!0,s=!1;for(;a=r?(t.resource.Genes.amount-=r,t.race.minor[e]?t.race.minor[e]++:t.race.minor[e]=1,t.race[e]?t.race[e]++:t.race[e]=1,s=!0):i=!1,a++}s&&("mastery"===e&&Ts(!0),Ee(),"persuasive"===e&&Ge())},phage(e){let a=0,r=y(),i=!0,s=!1;for(;a=r?(t.prestige.Phage.count-=r,t.genes.minor[e]?t.genes.minor[e]++:t.genes.minor[e]=1,t.race[e]?t.race[e]++:t.race[e]=1,s=!0):i=!1,a++}s&&("mastery"===e&&Ts(!0),Ee(),"persuasive"===e&&Ge())},purge(e){if("sludge"===t.race.species&&(t.race.modified||"ooze"===e))return;let a=5*Ei[e].val;"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1);let r="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";if(t.prestige[r].count>=a){t.prestige[r].count-=a;let i=t.race[e];delete t.race[e],t.race.modified?t.race.modified++:t.race.modified=1,Zi(e,i),Ee(),Qr(),Wr();let s=0;Object.keys(t.race).forEach((function(e){!Ei[e]||"major"!=Ei[e].type&&"genus"!=Ei[e].type||"evil"===e||s++})),0===s&&Pn("blank_slate")}},gain(e){if("sludge"===t.race.species&&t.race.modified)return;let a=5*Ei[e].val;"sludge"===t.race.species&&(a*=2),"custom"===t.race.species&&(a*=10),a<0&&(a*=-1);let r="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";t.prestige[r].count>=a&&(t.prestige[r].count-=a,t.race[e]=1,t.race.modified?t.race.modified++:t.race.modified=1,Ji(e),Ee(),Qr(),Wr())},geneCost:e=>u(e),phageCost:e=>h(e),traitEffect:e=>z(`trait_${e}_effect`),removeCost:e=>d(e),addCost:e=>p(e),genePurchasable(e){let a=Ys(t.race.minor[e]?t.race.minor[e]+4:4);return"mastery"===e&&(a*=5),t.resource.Genes.amount>=a},phagePurchasable(e){let a=Ys(t.genes.minor[e]?t.genes.minor[e]+4:4);return"mastery"===e&&(a*=2),t.prestige.Phage.count>=a}}}),i.forEach((function(e){ls(`popGenetrait${e}`,(function(){return u(e)}),{elm:`#geneticBreakdown .t-${e} .gbuy`,classes:"has-background-light has-text-dark"}),t.prestige.Phage.count>0&&ls(`popGenetrait${e}`,(function(){return h(e)}),{elm:`#geneticBreakdown .t-${e} .pbuy`,classes:"has-background-light has-text-dark"}),ls(`popGenetrait${e}`,(function(){return t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0?`
                ${as("desc",e)}
                ${z(`trait_${e}_effect`)}
                `:as("desc",e)}),{elm:`#geneticBreakdown .t-${e} .name`,classes:"has-background-light has-text-dark"})})),n.forEach((function(e){ls(`popRemoveBkdwn${e}`,(function(){return d(e)}),{elm:`#geneticBreakdown .remove${e}`,classes:"has-background-light has-text-dark"});let a=`raceTrait${e}`,r=$("
                ");vn(r,e,{trank:t.race[e]}),ls(a,r,{wide:!0,classes:"w30"})})),c.forEach((function(e){let a=`raceTrait${e}`,r=$("
                ");vn(r,e,{trank:t.race[e]}),ls(a,r,{elm:`#geneticBreakdown .trait${e}`,wide:!0,classes:"w30"})})),_.forEach((function(e){ls(`popAddBkdwn${e}`,(function(){return p(e)}),{elm:`#geneticBreakdown .add${e}`,classes:"has-background-light has-text-dark"});let a=`raceTrait${e}`,r=$("
                ");vn(r,e,{trank:t.race[e]}),ls(a,r,{wide:!0,classes:"w30"})})),function(){let e=$("#geneticMinor")[0];e&&Sortable.create(e,{onEnd(e){let a=t.settings.mtorder;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.settings.mtorder=a,Ee()}})}()}}function Ke(){(t.tech.genetics&&t.tech.genetics>3||t.sim)&&(Ss($("#arpaCrispr")),$("#arpaCrispr").append(`
                ${z("arpa_crispr_desc")}
                `),$("#arpaCrispr").append('
                '),Object.keys(Mr.genes).forEach((function(e){ti(Mr.genes[e].id),function(e){var a=!0;return Object.keys(Mr.genes[e].reqs).forEach((function(r){(!t.genes[r]||t.genes[r]=2&&(Ss($("#arpaBlood")),$("#arpaBlood").append(`
                ${z("arpa_blood_desc")}
                `),$("#arpaBlood").append('
                '),Object.keys(Mr.blood).forEach((function(e){ti(Mr.blood[e].id),function(e){var a=!0;return Object.keys(Mr.blood[e].reqs).forEach((function(r){(!t.blood[r]||t.blood[r]
                "),s=Ae(qe[a].cost);let n=Ms(qe[a],r/100,!1,!0);return Object.keys(s).forEach((function(e){var a=+(s[e]()*(r/100)).toFixed(0);if(a>0){var c="Money"===e?"$":t.resource[e].name+": ",o=t.resource[e].amount>=a?"has-text-dark":e===n.r?"has-text-danger":"has-text-alert";i.append($(`
                ${c}${x(a,2)}
                `))}})),i}function Ge(){Object.keys(t.resource).forEach((function(e){Cs({el:`#market-${e}`},"update")})),Cs({el:"#galaxyTrade"},"update")}const Ne={spc_titan:{info:{name:()=>Ut().titan,desc:()=>z("space_titan_info_desc",[Ut().titan,Ki[t.race.species].home]),support:"electrolysis",zone:"outer",syndicate:()=>!!(t.tech.titan&&t.tech.titan>=3&&t.tech.enceladus&&t.tech.enceladus>=2),syndicate_cap:()=>t.tech.triton?t.tech.outer>=4?2e3:1e3:600},titan_mission:{id:"space-titan_mission",title:()=>z("space_mission_title",[Ut().titan]),desc:()=>z("space_mission_desc",[Ut().titan]),reqs:{outer:1},grant:["titan",1],path:["truepath"],queue_complete:()=>t.tech.titan>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(25e4,!1,t).toFixed(0),Elerium:()=>100},effect:()=>z("space_titan_mission_effect",[Ut().titan]),action(){return!!ri($(this)[0])&&(hs(z("space_titan_mission_action",[Ut().titan,Ki[t.race.species].home]),"info",!1,["progress"]),!0)}},titan_spaceport:{id:"space-titan_spaceport",title:z("space_red_spaceport_title"),desc:`
                ${z("space_red_spaceport_desc")}
                ${z("requires_power")}
                `,reqs:{titan:1},path:["truepath"],cost:{Money:e=>Ps("titan_spaceport",e,25e5,1.32),Lumber:e=>Ps("titan_spaceport",e,75e4,1.32),Cement:e=>Ps("titan_spaceport",e,35e4,1.32),Mythril:e=>Ps("titan_spaceport",e,1e4,1.32)},effect(){let e=t.resource.Water.display?`
                ${z("plus_max_resource",[x(br(250)),t.resource.Water.name])}
                `:"";return`${t.tech.enceladus&&t.tech.enceladus>=2?`
                +${z("galaxy_alien2_support",[$(this)[0].support(),Ut().enceladus])}
                `:""}${e}${t.tech.titan&&t.tech.titan>=5?`
                ${z("space_titan_spaceport_storage",[25])}
                `:""}
                ${z("minus_power",[$(this)[0].powered()])}
                `},support:()=>2,powered:()=>As(10),action(){return!!ri($(this)[0])&&(t.space.titan_spaceport.count++,Yr($(this)[0]),!0)},post(){1===t.tech.titan&&(t.tech.titan=2,Qr())}},electrolysis:{id:"space-electrolysis",title:z("space_electrolysis_title"),desc:()=>`
                ${z("space_electrolysis_title")}
                ${z("space_electrolysis_req",[t.resource.Water.name])}
                `,reqs:{titan:3},path:["truepath"],cost:{Money:e=>Ps("electrolysis",e,1e6,1.25),Copper:e=>Ps("electrolysis",e,185e3,1.25),Steel:e=>Ps("electrolysis",e,22e4,1.25),Polymer:e=>Ps("electrolysis",e,38e4,1.25)},effect(){return`
                +${z("galaxy_alien2_support",[$(this)[0].support(),Ut().titan])}
                ${z("space_electrolysis_use",[$(this)[0].support_fuel().a,t.resource.Water.name,$(this)[0].powered()])}
                `},support:()=>t.tech.titan_ai_core&&t.tech.titan_ai_core>=2&&s.ai_core2?3:2,support_fuel:()=>({r:"Water",a:35}),powered:()=>As(8),action(){return!!ri($(this)[0])&&(t.space.electrolysis.count++,Yr($(this)[0]),!0)},post(){3===t.tech.titan&&(t.tech.titan=4,Qr())}},hydrogen_plant:{id:"space-hydrogen_plant",title:z("space_hydrogen_plant_title"),desc:()=>`
                ${z("space_hydrogen_plant_title")}
                ${z("space_hydrogen_plant_req")}
                `,reqs:{titan_power:1},path:["truepath"],cost:{Money:e=>Ps("hydrogen_plant",e,15e5,1.28),Iridium:e=>Ps("hydrogen_plant",e,292e3,1.28),Stanene:e=>Ps("hydrogen_plant",e,599e3,1.28),Cement:e=>Ps("hydrogen_plant",e,18e4,1.28)},effect(){return`${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${z("space_hydrogen_plant_effect",[1,z("space_electrolysis_title")])}`},support:()=>2,powered:()=>Fs(-22),action(){return!!ri($(this)[0])&&(t.space.hydrogen_plant.count++,t.space.electrolysis.on>t.space.hydrogen_plant.on&&t.space.hydrogen_plant.on++,!0)}},titan_quarters:{id:"space-titan_quarters",title:z("interstellar_habitat_title"),desc:()=>`
                ${z("interstellar_habitat_title")}
                ${z("space_habitat_req",[Ut().titan,t.resource.Food.name,t.resource.Water.name])}
                `,reqs:{titan:4},path:["truepath"],cost:{Money:e=>Ps("titan_quarters",e,12e5,1.28),Furs:e=>Ps("titan_quarters",e,85e3,1.28),Plywood:e=>Ps("titan_quarters",e,1e5,1.28),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=ta(1);return`
                ${z("space_used_support",[Ut().titan])}
                ${z("plus_max_resource",[ta(1),t.race.truepath?z("job_colonist_tp",[Ut().titan]):z("colonist")])}
                ${z("plus_max_resource",[e,z("citizen")])}
                ${z("spend",[$(this)[0].support_fuel()[0].a,t.resource[$(this)[0].support_fuel()[0].r].name])}
                ${z("spend",[$(this)[0].support_fuel()[1].a,t.resource[$(this)[0].support_fuel()[1].r].name])}
                `},support:()=>-1,support_fuel:()=>[{r:"Water",a:12},{r:"Food",a:500}],powered:()=>As(1),action(){if(ri($(this)[0])){if(t.space.titan_quarters.count++,t.civic.titan_colonist.display=!0,t.space.electrolysis.support0)){let e=t.civic[t.civic.d_job].workers-ta(1)<0?t.civic[t.civic.d_job].workers:ta(1);t.civic[t.civic.d_job].workers-=e,t.civic.titan_colonist.workers+=e}return!0}return!1},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},titan_mine:{id:"space-titan_mine",title:z("space_red_mine_title"),desc:()=>`
                ${z("space_red_mine_desc")}
                ${z("space_support",[Ut().titan])}
                `,reqs:{titan:4},condition:()=>!!(t.space.titan_quarters&&t.space.titan_quarters.count>0),path:["truepath"],cost:{Money:e=>Ps("titan_mine",e,475e3,1.28),Lumber:e=>Ps("titan_mine",e,568e3,1.28),Wrought_Iron:e=>Ps("titan_mine",e,25e4,1.28)},effect(){let e=$e("titan_mine","adamantite"),a=$e("titan_mine","aluminium"),r=+e.toFixed(3),i=+a.toFixed(3);return`
                ${z("space_used_support",[Ut().titan])}
                ${z("space_red_mine_effect",[r,t.resource.Adamantite.name])}
                ${z("space_red_mine_effect",[i,t.resource.Aluminium.name])}
                `},support:()=>-1,powered:()=>As(1),special:()=>!0,action(){return!!ri($(this)[0])&&(t.space.titan_mine.count++,t.resource.Adamantite.display=!0,t.space.electrolysis.supportPs("storehouse",e,175e3,1.28),Lumber:e=>Ps("storehouse",e,1e5,1.28),Aluminium:e=>Ps("storehouse",e,12e4,1.28),Cement:e=>Ps("storehouse",e,45e3,1.28)},wide:!0,res:()=>["Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Alloy","Polymer","Iridium","Chrysotile","Nano_Tube","Neutronium","Adamantite"],heavy:e=>!!["Copper","Iron","Steel","Titanium","Iridium","Neutronium","Adamantite"].includes(e),val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 3e3;case"Furs":return 1700;case"Copper":return 1520;case"Iron":return 1400;case"Aluminium":return 1280;case"Cement":return 1120;case"Coal":return 480;case"Steel":return 240;case"Titanium":return 160;case"Alloy":return 180;case"Polymer":return 150;case"Iridium":return 175;case"Nano_Tube":return 120;case"Neutronium":return 64;case"Adamantite":return 72;default:return 0}},effect(){let e='
                ',a=mt("storehouse",!1),r=mt("storehouse",!0);for(const i of $(this)[0].res())if(t.resource[i].display){let s=$(this)[0].heavy(i);e+=`${z("plus_max_resource",[x(+(br($(this)[0].val(i))*(s?r:a)).toFixed(0),1),t.resource[i].name])}`}return e+="
                ",e},action(){if(ri($(this)[0])){t.space.storehouse.count++;let e=mt("storehouse",!1),a=mt("storehouse",!0);for(const r of $(this)[0].res())if(t.resource[r].display){let i=$(this)[0].heavy(r);t.resource[r].max+=br($(this)[0].val(r))*(i?a:e)}return!0}return!1}},titan_bank:{id:"space-titan_bank",title:z("city_bank"),desc:()=>z("city_bank_desc",[Ut().titan]),reqs:{titan:6},path:["truepath"],cost:{Money:e=>Ps("titan_bank",e,25e5,1.32),Titanium:e=>Ps("titan_bank",e,38e4,1.32),Neutronium:e=>Ps("titan_bank",e,5e3,1.32)},effect(){let e=2*bi();return e=br(e),e=(+e.toFixed(0)).toLocaleString(),z("plus_max_resource",[`$${e}`,z("resource_Money_name")])},action(){return!!ri($(this)[0])&&(t.resource.Money.max+=br(1800),t.space.titan_bank.count++,!0)}},g_factory:{id:"space-g_factory",title:z("interstellar_g_factory_title"),desc:()=>`
                ${z("interstellar_g_factory_title")}
                ${z("space_support",[Ut().titan])}
                `,reqs:{graphene:1},path:["truepath"],cost:{Money:e=>Ps("g_factory",e,95e4,1.28),Copper:e=>Ps("g_factory",e,165e3,1.28),Stone:e=>Ps("g_factory",e,22e4,1.28),Adamantite:e=>Ps("g_factory",e,12500,1.28)},effect(){let e=.05;return t.race.high_pop&&(e=+ke(e).toFixed(3)),`
                ${z("space_used_support",[Ut().titan])}
                ${z("space_red_mine_effect",[e,t.resource.Graphene.name])}
                ${z("interstellar_g_factory_effect")}
                `},support:()=>-1,powered:()=>As(1),special:!0,action(){return!!ri($(this)[0])&&(t.space.g_factory.count++,t.resource.Graphene.display=!0,t.space.electrolysis.support`
                ${z("space_sam_desc")}
                ${z("requires_power")}
                `,reqs:{titan:7},path:["truepath"],cost:{Money:e=>Ps("sam",e,25e5,1.28),Steel:e=>Ps("sam",e,45e4,1.28),Elerium:e=>Ps("sam",e,120,1.28),Brick:e=>Ps("sam",e,16e4,1.28)},effect(){return`
                ${z("galaxy_defense_platform_effect",[25])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(5),action(){return!!ri($(this)[0])&&(t.space.sam.count++,Yr($(this)[0]),!0)},post(){Cs({el:"#spc_titansynd"},"update")}},decoder:{id:"space-decoder",title:z("space_decoder_title"),desc:()=>`
                ${z("space_decoder_title")}
                ${z("requires_power_support_combo",[Ut().titan,t.resource.Cipher.name])}
                `,reqs:{titan:8},path:["truepath"],cost:{Money:e=>Ps("decoder",e,125e5,1.275),Elerium:e=>Ps("decoder",e,750,1.275),Orichalcum:e=>Ps("decoder",e,33e4,1.275),Quantium:e=>Ps("decoder",e,18e4,1.275)},effect(){let e=$(this)[0].support_fuel().a,a=2500;t.race.high_pop&&(a=ke(a)),s.ai_core2&&(a*=1.25);let r=`
                ${z("space_used_support",[Ut().titan])}
                `;return r+=`
                ${z("space_red_exotic_lab_effect1",[a])}
                `,r+`
                ${z("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
                `},support:()=>-1,powered:()=>As(1),support_fuel:()=>({r:"Cipher",a:.06}),action(){return!!ri($(this)[0])&&(t.space.decoder.count++,t.space.electrolysis.support!t.space.hasOwnProperty("ai_core")||t.space.ai_core.count<100||e?`
                ${z("space_ai_core")}
                ${z("requires_segmemts",[100])}
                `+(t.space.hasOwnProperty("ai_core")&&t.space.ai_core.count>=100?`
                ${z("requires_power")}
                `:""):`
                ${z("space_ai_core")}
                `,reqs:{titan:9},path:["truepath"],condition:()=>!(t.space.ai_core.count>=100),queue_size:10,queue_complete:()=>100-t.space.ai_core.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?25e5:0,Cement:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?18e4:0,Aluminium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?25e4:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?250:0,Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?125e3:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?5e4:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?1e5:0,Cipher:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?750:0},effect(e){let a=`
                ${z("space_ai_core_effect")}
                `,r=(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0);return r<100?(a+=`
                ${z("space_dwarf_collider_effect2",[100-r])}
                `,a):Ne.spc_titan.ai_core2.effect()},action(){return!!(ri($(this)[0])&&t.space.ai_core.count<100)&&(t.space.ai_core.count++,t.space.ai_core.count>=100&&(t.tech.titan_ai_core=1,t.space.ai_core2={count:1,on:0},t.city.power>=Ne.spc_titan.ai_core2.powered()&&t.space.ai_core2.on++,Lt(),Qr()),!0)}},ai_core2:{id:"space-ai_core2",title:z("space_ai_core"),desc(){return`
                ${z("space_ai_core")}
                ${z("space_electrolysis_req",[t.resource[$(this)[0].p_fuel().r].name])}
                `},reqs:{titan_ai_core:1},path:["truepath"],condition:()=>!!(t.space.hasOwnProperty("ai_core")&&t.space.ai_core.count>=100),wiki:!1,queue_complete:()=>0,cost:{},powered:()=>As(100),p_fuel:()=>({r:"Water",a:1e3}),effect(){let e=`
                ${z("interstellar_citadel_stat",[+_.toFixed(1)])}
                `;return e+=`
                ${z("interstellar_citadel_effect",[25])}
                ${z("space_ai_core_effect2",[25])}
                `,t.tech.titan_ai_core&&t.tech.titan_ai_core>=2&&(e+=`
                ${z("space_ai_core_effect3",[50])}
                `),e+=`
                ${z("space_electrolysis_use",[$(this)[0].p_fuel().a,t.resource[$(this)[0].p_fuel().r].name,$(this)[0].powered()])}
                `,t.tech.titan_ai_core&&t.tech.titan_ai_core>=3&&(e+=`
                ${z("space_ai_core_effect4",[+function(){let e=0;return s.ai_colonist&&n.decoder&&(e+=s.ai_colonist*n.decoder*.35),n.shock_trooper&&(e+=2*n.shock_trooper),n.tank&&(e+=2*n.tank),e>100&&(e=100),e}().toFixed(1)])}
                `),e},action:()=>!1,flair:()=>t.space.hasOwnProperty("ai_core2")&&t.space.ai_core2.on>=1?z("space_ai_core_flair"):z("space_ai_core_flair2")},ai_colonist:{id:"space-ai_colonist",title:z("space_ai_colonist_title"),desc:()=>`
                ${z("space_ai_colonist_title")}
                ${z("requires_power")}
                `,reqs:{titan_ai_core:3},path:["truepath"],cost:{Money:e=>Ps("ai_colonist",e,112e6,1.35),Alloy:e=>Ps("ai_colonist",e,75e4,1.35),Elerium:e=>Ps("ai_colonist",e,500,1.35),Nano_Tube:e=>Ps("ai_colonist",e,525e3,1.35),Quantium:e=>Ps("ai_colonist",e,15e4,1.35),Cipher:e=>Ps("ai_colonist",e,1e4,1.35)},effect(){return`
                ${z("plus_max_resource",[ta(1),t.race.truepath?z("job_colonist_tp",[Ut().titan]):z("colonist")])}
                ${z("space_ai_colonist_effect",[ta(1),Ut().titan])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(10),action(){return!!ri($(this)[0])&&(t.space.ai_colonist.count++,Yr($(this)[0]),!0)},flair:z("tech_combat_droids_flair")}},spc_enceladus:{info:{name:()=>Ut().enceladus,desc:()=>z("space_enceladus_info_desc",[Ut().enceladus,Ki[t.race.species].home]),support:"titan_spaceport",zone:"outer",syndicate:()=>!!(t.tech.titan&&t.tech.titan>=3&&t.tech.enceladus&&t.tech.enceladus>=2),syndicate_cap:()=>t.tech.triton?t.tech.outer>=4?1500:1e3:600},enceladus_mission:{id:"space-enceladus_mission",title:()=>z("space_mission_title",[Ut().enceladus]),desc:()=>z("space_mission_desc",[Ut().enceladus]),reqs:{outer:1},grant:["enceladus",1],path:["truepath"],queue_complete:()=>t.tech.enceladus>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(25e4,!1,t).toFixed(0),Elerium:()=>100},effect:()=>z("space_titan_mission_effect",[Ut().enceladus]),action(){return!!ri($(this)[0])&&(hs(z("space_enceladus_mission_action",[Ut().enceladus]),"info",!1,["progress"]),t.resource.Water.display=!0,!0)}},water_freighter:{id:"space-water_freighter",title:z("space_water_freighter_title"),desc:()=>`
                ${z("space_water_freighter_title")}
                ${z("space_support",[Ut().enceladus])}
                `,reqs:{enceladus:2},path:["truepath"],cost:{Money:e=>Ps("water_freighter",e,45e4,1.25),Iron:e=>Ps("water_freighter",e,362e3,1.25),Nano_Tube:e=>Ps("water_freighter",e,125e3,1.25),Sheet_Metal:e=>Ps("water_freighter",e,75e3,1.25)},effect(e){let a=+Rt(5,!0,e).toFixed(2),r=+$e("water_freighter").toFixed(2);return`
                ${z("space_used_support",[Ut().enceladus])}
                ${z("produce",[r,t.resource.Water.name])}
                ${z("space_belt_station_effect3",[a])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.space.water_freighter.count++,t.space.titan_spaceport.support`
                ${z("tech_zero_g_lab")}
                ${z("requires_power_support",[Ut().enceladus])}
                `,reqs:{enceladus:3},path:["truepath"],cost:{Money:e=>Ps("zero_g_lab",e,5e6,1.25),Alloy:e=>Ps("zero_g_lab",e,125e3,1.25),Graphene:e=>Ps("zero_g_lab",e,225e3,1.25),Stanene:e=>Ps("zero_g_lab",e,6e5,1.25)},effect(){let e=lt("spc_enceladus"),a=Math.round(1e4*e),r=`
                ${z("space_used_support",[Ut().enceladus])}
                ${z("city_max_knowledge",[a])}
                `;return t.resource.Quantium.display&&(r+=`
                ${z("space_zero_g_lab_effect",[ta(1)])}
                `),t.resource.Cipher.display&&(r+=`
                ${z("plus_max_resource",[1e4,t.resource.Cipher.name])}
                `),r+`
                ${z("minus_power",[$(this)[0].powered()])}
                `},support:()=>-1,powered:()=>As(12),action(){return!!ri($(this)[0])&&(t.space.zero_g_lab.count++,t.space.titan_spaceport.support`
                ${z("tech_operating_base")}
                ${z("requires_power_support",[Ut().enceladus])}
                `,reqs:{enceladus:4},path:["truepath"],cost:{Money:e=>Ps("operating_base",e,75e5,1.3),Furs:e=>Ps("operating_base",e,5e5,1.3),Adamantite:e=>Ps("operating_base",e,375e3,1.3),Stanene:e=>Ps("operating_base",e,75e4,1.3),Mythril:e=>Ps("operating_base",e,225e3,1.3),Horseshoe:()=>t.race.hooved?4:0},effect(){let e=`
                ${z("space_used_support",[Ut().enceladus])}
                `;return e+=`
                ${z("galaxy_defense_platform_effect",[50])}
                `,e+=z("plus_max_resource",[ta(4),z("civics_garrison_soldiers")]),t.race.orbit_decayed&&(e+=`
                ${z("city_hospital_effect",[5*t.tech.medic])}
                `),e+`
                ${z("minus_power",[$(this)[0].powered()])}
                `},support:()=>-1,powered:()=>As(10),action(){return!!ri($(this)[0])&&(t.space.operating_base.count++,t.space.titan_spaceport.supportPs("munitions_depot",e,5e6,1.22),Iron:e=>Ps("munitions_depot",e,185e3,1.22),Sheet_Metal:e=>Ps("munitions_depot",e,1e5,1.22)},effect:()=>`
                ${z("plus_max_crates",[25])}
                ${z("plus_max_containers",[25])}
                `,action(){return!!ri($(this)[0])&&(t.space.munitions_depot.count++,t.resource.Crates.max+=25,t.resource.Containers.max+=25,!0)}}},spc_triton:{info:{name:()=>Ut().triton,desc:()=>z("space_triton_info_desc",[Ut().triton,Ki[t.race.species].home]),zone:"outer",syndicate:()=>!!(t.tech.triton&&t.tech.triton>=2),syndicate_cap:()=>t.tech.outer&&t.tech.outer>=4?5e3:3e3,extra(e){t.tech.triton&&t.tech.triton>=3&&($(`#${e}`).append(`
                ${z("space_ground_resist")}
                `),Cs({el:`#${e}resist`,data:t.space.fob,methods:{threat(e,a){let r=t.civic.garrison.wounded-we();r<0&&(r=0);let i=+(e-be(a,"army",r)).toFixed(0);return i<0?0:i}}}))}},triton_mission:{id:"space-triton_mission",title:()=>z("space_mission_title",[Ut().triton]),desc:()=>z("space_mission_desc",[Ut().triton]),reqs:{outer:2},grant:["triton",1],path:["truepath"],queue_complete:()=>t.tech.triton>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(6e5,!1,t).toFixed(0),Elerium:()=>2500},effect:()=>z("space_triton_mission_effect",[Ut().triton]),action(){return!!ri($(this)[0])&&(hs(z("space_triton_mission_action",[Ut().triton]),"info",!1,["progress"]),t.space.syndicate.spc_triton=1250,t.space.syndicate.spc_titan+=250,t.space.syndicate.spc_enceladus+=250,!0)}},fob:{id:"space-fob",title:z("space_fob_title"),desc:()=>`
                ${z("tech_fob")}
                ${z("requires_power_combo",[t.resource.Helium_3.name])}
                `,reqs:{triton:2},path:["truepath"],queue_complete:()=>1-t.space.fob.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,25e7,1.1),Copper:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,8e6,1.1),Uranium:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,5e4,1.1),Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,25e5,1.1),Graphene:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,3e6,1.1),Sheet_Metal:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,75e5,1.1),Quantium:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,5e5,1.1),Horseshoe:e=>t.race.hooved&&(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)<1?10:0},effect(e){let a=we(),r=we(!0),i=`
                ${z("galaxy_defense_platform_effect",[500])}
                `;i+=z("plus_max_resource",[ta(10),z("civics_garrison_soldiers")]),i+=`
                ${z("civics_garrison_soldiers")}: ${a} / ${r}
                `,i+=`
                ${z("civics_garrison_wounded")}: ${t.civic.garrison?t.civic.garrison.wounded:0}
                `,i+=`
                ${z("space_fob_landed",[t.space.fob?t.space.fob.troops:0])}
                `;let s=+Rt(125,!0,e).toFixed(2);return i+`
                ${z("requires_power_combo_effect",[$(this)[0].powered(),s,t.resource.Helium_3.name])}
                `},powered:()=>As(50),action(){return!!(t.space.fob.count<1&&ri($(this)[0]))&&(t.space.fob.count++,Yr($(this)[0]),!0)},post(){2===t.tech.triton&&(t.tech.triton=3,Qr(),Lt(),hs(z("space_fob_msg"),"info",!1,["progress"]))}},lander:{id:"space-lander",title:z("space_lander_title"),desc:()=>`
                ${z("space_lander_title")}
                ${z("requires_soldiers")}
                ${z("space_red_space_barracks_desc_req")}
                `,reqs:{triton:3},path:["truepath"],cost:{Money:e=>Ps("lander",e,24e5,1.15),Aluminium:e=>Ps("lander",e,185e3,1.15),Neutronium:e=>Ps("lander",e,1e4,1.15),Nano_Tube:e=>Ps("lander",e,158e3,1.15)},powered:()=>As(1),effect(e){let a=+Rt(50,!0,e).toFixed(2),r="";return t.space.crashed_ship&&100===t.space.crashed_ship.count&&(r=`
                ${z("space_lander_effect3",[$e("lander"),t.resource.Cipher.name])}
                `),`
                ${z("space_lander_effect",[Ut().triton])}
                ${r}
                ${z("space_lander_effect2",[ta(3)])}
                ${z("space_red_space_barracks_effect2",[a])}
                `},action(){return!!ri($(this)[0])&&(t.space.lander.count++,t.space.lander.on++,!0)}},crashed_ship:{id:"space-crashed_ship",title:z("space_crashed_ship_title"),desc:()=>`
                ${z("space_crashed_ship_title")}
                `,reqs:{triton:3},path:["truepath"],queue_complete:()=>0,cost:{},effect:()=>`
                ${z("space_crashed_ship_effect",[t.space.crashed_ship?t.space.crashed_ship.count:0])}
                `,action:()=>!1}},spc_kuiper:{info:{name:()=>z("space_kuiper_title"),desc:()=>z("space_kuiper_desc"),zone:"outer",syndicate:()=>!!t.tech.kuiper,syndicate_cap:()=>2500},kuiper_mission:{id:"space-kuiper_mission",title:()=>z("space_mission_title",[z("space_kuiper_title")]),desc:()=>z("space_mission_desc",[z("space_kuiper_title")]),reqs:{outer:7},grant:["kuiper",1],path:["truepath"],queue_complete:()=>t.tech.kuiper>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(1e6,!1,t).toFixed(0),Elerium:()=>1e3},effect:()=>z("space_kuiper_mission_effect"),action(){return!!ri($(this)[0])&&(t.space.orichalcum_mine={count:0,on:0},t.space.uranium_mine={count:0,on:0},t.space.neutronium_mine={count:0,on:0},t.space.syndicate.spc_kuiper=500,hs(z("space_kuiper_mission_action"),"info",!1,["progress"]),!0)}},orichalcum_mine:{id:"space-orichalcum_mine",title:()=>z("space_kuiper_mine",[t.resource.Orichalcum.name]),desc:()=>`
                ${z("space_kuiper_mine",[t.resource.Orichalcum.name])}
                ${z("requires_power_combo",[t.resource.Oil.name])}
                `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Ps("orichalcum_mine",e,25e6,1.25),Graphene:e=>Ps("orichalcum_mine",e,9e5,1.25),Elerium:e=>Ps("orichalcum_mine",e,200,1.25),Mythril:e=>Ps("orichalcum_mine",e,45e4,1.25),Quantium:e=>Ps("orichalcum_mine",e,15e4,1.25)},effect(e){let a=+$e("orichalcum_mine").toFixed(3),r=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
                ${z("gain",[a,z("resource_Orichalcum_name")])}
                ${z("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
                `},powered:()=>As(10),p_fuel:()=>({r:"Oil",a:200}),action(){return!!ri($(this)[0])&&(t.space.orichalcum_mine.count++,t.resource.Orichalcum.display=!0,Yr($(this)[0]),!0)}},uranium_mine:{id:"space-uranium_mine",title:()=>z("space_kuiper_mine",[t.resource.Uranium.name]),desc:()=>`
                ${z("space_kuiper_mine",[t.resource.Uranium.name])}
                ${z("requires_power_combo",[t.resource.Oil.name])}
                `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Ps("uranium_mine",e,5e6,1.25),Iridium:e=>Ps("uranium_mine",e,25e4,1.25),Steel:e=>Ps("uranium_mine",e,62e4,1.25)},effect(e){let a=+$e("uranium_mine").toFixed(3),r=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
                ${z("gain",[a,z("resource_Uranium_name")])}
                ${z("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
                `},powered:()=>As(5),p_fuel:()=>({r:"Oil",a:60}),action(){return!!ri($(this)[0])&&(t.space.uranium_mine.count++,Yr($(this)[0]),!0)}},neutronium_mine:{id:"space-neutronium_mine",title:()=>z("space_kuiper_mine",[t.resource.Neutronium.name]),desc:()=>`
                ${z("space_kuiper_mine",[t.resource.Neutronium.name])}
                ${z("requires_power_combo",[t.resource.Oil.name])}
                `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Ps("neutronium_mine",e,8e6,1.25),Adamantite:e=>Ps("neutronium_mine",e,65e4,1.25),Stanene:e=>Ps("neutronium_mine",e,125e4,1.25)},effect(e){let a=+$e("neutronium_mine").toFixed(3),r=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
                ${z("gain",[a,z("resource_Neutronium_name")])}
                ${z("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
                `},powered:()=>As(8),p_fuel:()=>({r:"Oil",a:60}),action(){return!!ri($(this)[0])&&(t.space.neutronium_mine.count++,Yr($(this)[0]),!0)}},elerium_mine:{id:"space-elerium_mine",title:()=>z("space_kuiper_mine",[t.resource.Elerium.name]),desc:()=>`
                ${z("space_kuiper_mine",[t.resource.Elerium.name])}
                ${z("requires_power_combo",[t.resource.Oil.name])}
                `,reqs:{kuiper:2},path:["truepath"],cost:{Money:e=>Ps("elerium_mine",e,2e7,1.25),Titanium:e=>Ps("elerium_mine",e,25e4,1.25),Neutronium:e=>Ps("elerium_mine",e,12e4,1.25),Orichalcum:e=>Ps("elerium_mine",e,175e3,1.25)},effect(e){let a=+$e("elerium_mine").toFixed(3),r=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
                ${z("gain",[a,z("resource_Elerium_name")])}
                ${z("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
                `},powered:()=>As(12),p_fuel:()=>({r:"Oil",a:125}),action(){return!!ri($(this)[0])&&(t.space.elerium_mine.count++,Yr($(this)[0]),!0)}}},spc_eris:{info:{name:()=>Ut().eris,desc:()=>z("space_eris_info_desc",[Ut().eris]),support:"drone_control",zone:"outer",syndicate:()=>!!t.tech.eris,syndicate_cap:()=>7500,extra(e){t.tech.eris&&1===t.tech.eris&&($(`#${e}`).append(`
                ${z("space_scanned")} {{ eris_scan }}%
                `),Cs({el:`#${e}scanned`,data:t.tech}))}},eris_mission:{id:"space-eris_mission",title:()=>z("space_mission_title",[Ut().eris]),desc:()=>z("space_mission_desc",[Ut().eris]),reqs:{outer:7},grant:["eris",1],path:["truepath"],queue_complete:()=>t.tech.eris>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(125e4,!1,t).toFixed(0),Elerium:()=>1250},effect:()=>z("space_eris_mission_effect",[Ut().eris]),action(){return!!ri($(this)[0])&&(t.space.syndicate.spc_eris=4e3,hs(z("space_eris_mission_action",[Ut().eris]),"info",!1,["progress"]),!0)}},drone_control:{id:"space-drone_control",title:()=>z("space_drone_control",[Ut().titan]),desc(){return`
                ${z("space_drone_control",[Ut().titan])}
                ${z("requires_power_combo",[t.resource[$(this)[0].p_fuel().r].name])}
                `},reqs:{eris:3},path:["truepath"],cost:{Money:e=>Ps("drone_control",e,75e6,1.3),Neutronium:e=>Ps("drone_control",e,1e5,1.3),Stanene:e=>Ps("drone_control",e,45e4,1.3),Quantium:e=>Ps("drone_control",e,3e5,1.3)},effect(){let e=$(this)[0].p_fuel().a;return`
                +${z("galaxy_alien2_support",[$(this)[0].support(),Ut().eris])}
                ${z("requires_power_combo_effect",[$(this)[0].powered(),e,t.resource[$(this)[0].p_fuel().r].name])}
                `},support:()=>5,powered:()=>As(25),p_fuel:()=>({r:"Uranium",a:5}),action(){return!!ri($(this)[0])&&(t.space.drone_control.count++,Yr($(this)[0]),!0)}},shock_trooper:{id:"space-shock_trooper",title:z("space_shock_trooper_title"),desc:()=>`
                ${z("space_shock_trooper_title")}
                ${z("space_support",[Ut().eris])}
                `,reqs:{eris:3},path:["truepath"],cost:{Money:e=>Ps("shock_trooper",e,425e4,1.225),Polymer:e=>Ps("shock_trooper",e,375e3,1.225),Adamantite:e=>Ps("shock_trooper",e,5e5,1.225),Graphene:e=>Ps("shock_trooper",e,22e4,1.225),Elerium:e=>Ps("shock_trooper",e,350,1.225)},effect(){let e=Math.round(be(1,"army",0)*lt("spc_eris")),a=`
                ${z("space_used_support",[Ut().eris])}
                `;return t.space.digsite&&100===t.space.digsite.count&&(a=`
                ${z("space_lander_effect3",[$e("shock_trooper"),t.resource.Cipher.name])}
                `),a+`
                ${z("space_digsite_offense",[e])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.space.shock_trooper.count++,t.space.drone_control.support`
                ${z("space_tank_title")}
                ${z("space_support",[Ut().eris])}
                `,reqs:{eris:4},path:["truepath"],cost:{Money:e=>Ps("tank",e,1e8,1.25),Alloy:e=>Ps("tank",e,125e4,1.25),Orichalcum:e=>Ps("tank",e,6e5,1.25),Mythril:e=>Ps("tank",e,5e5,1.25),Uranium:e=>Ps("tank",e,25e3,1.25)},effect(){let e=Math.round(100*lt("spc_eris")),a=`
                ${z("space_used_support",[Ut().eris])}
                `;return t.space.digsite&&100===t.space.digsite.count&&(a=`
                ${z("space_lander_effect3",[$e("tank"),t.resource.Cipher.name])}
                `),a+`
                ${z("space_digsite_offense",[e])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.space.tank.count++,t.space.drone_control.support`
                ${z("space_digsite_title")}
                `,reqs:{eris:3},path:["truepath"],queue_complete:()=>0,cost:{},effect:()=>`
                ${z("space_crashed_ship_effect",[t.space.digsite?t.space.digsite.count:0])}
                `,action:()=>!1}}},Re={tau_star:{info:{name:()=>z("tab_tauceti"),desc:()=>z("tau_star",[z("tab_tauceti"),z("space_sun_info_name")])},ringworld:{id:"tauceti-ringworld",title:z("tau_star_ringworld"),desc:e=>!t.tauceti.hasOwnProperty("ringworld")||t.tauceti.ringworld.count<1e3||e?`
                ${z("tau_star_ringworld")}
                ${z("requires_segmemts",[1e3])}
                `:`
                ${z("tau_star_ringworld")}
                `,reqs:{matrix:2},path:["truepath"],queue_size:50,queue_complete:()=>1e3-t.tauceti.ringworld.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?1e7:1e8:0,Neutronium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?2e4:1e5:0,Nano_Tube:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?7e4:35e4:0,Adamantite:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?2e5:1e6:0,Bolognium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?17600:88e3:0,Orichalcum:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?25e3:125e3:0,Unobtainium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?360:1800:0,Quantium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?Ve(t.race.lone_survivor?10100:101e3):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0);if(r<1e3){let e=1e3-r;a+=`
                ${z("tau_star_ringworld_effect")}
                `,a+=`
                ${z("space_dwarf_collider_effect2",[e])}
                `}else a+=`
                ${z("space_dwarf_reactor_effect1",[t.race.lone_survivor?100:1e4])}
                `;return a},action(){return!!(ri($(this)[0])&&t.tauceti.ringworld.count<1e3)&&(t.tauceti.ringworld.count++,t.tauceti.ringworld.count>=1e3&&(t.race.lone_survivor?t.tech.eden=1:(t.tech.matrix=3,t.tauceti.matrix={count:1,on:0}),Je(),_s()),!0)}},matrix:{id:"tauceti-matrix",title:z("tau_star_matrix"),desc:()=>`
                ${z("tau_star_matrix")}
                ${z("requires_power")}
                `,reqs:{matrix:3},condition:()=>t.tauceti.ringworld.count>=1e3,queue_complete:()=>0,cost:{},powered:()=>1e4,postPower(e){e?setTimeout((function(){t.tech.matrix=s.matrix?4:3,Je()}),250):(t.tech.matrix=3,Je())},effect(){let e=He(),t=$(this)[0].powered(),a=t>0?`
                ${z("minus_power",[t])}
                `:"";return`
                ${z("tau_star_matrix_effect")}
                ${e}${a}`},action:()=>!1},blue_pill:{id:"tauceti-blue_pill",title:z("tau_star_blue_pill"),desc:z("tau_star_blue_pill"),wiki:!1,reqs:{matrix:4},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=He();return`
                ${z("tau_star_blue_pill_effect")}
                ${e}`},action(){if(ri($(this)[0])){$("body").append('');const a=document.getElementById("matrix"),r=a.getContext("2d"),i=a.width=document.body.offsetWidth,s=a.height=document.body.offsetHeight,n=Math.floor(i/20)+1,c=Array(n).fill(0);function o(){r.fillStyle="#0001",r.fillRect(0,0,i,s),r.fillStyle="#0f0",r.font="15pt monospace",c.forEach(((e,t)=>{const a=String.fromCharCode(Math.rand(65382,65438)),i=20*t;r.fillText(a,i,e),e>100+1e4*Math.random()?c[t]=0:c[t]=e+20}))}return setInterval(o,50),setTimeout((function(){!function(){P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"matrix"});let a=t.race.species,r=t.race.gods,i=Ki[a].type,s=t.city.calendar.orbit,n=t.city.biome,c=t.city.ptrait,o=t.city.geology,l=Gs("matrix");qn(`biome_${n}`),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),qn(`genus_${i}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),qn("bluepill"),U(),Sn(),t.stats.matrix++,rn(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let _=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),_&&(t.race.srace=_),H({orbit:s,biome:n,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),5e3),!0}return!1}},goe_facility:{id:"tauceti-goe_facility",title:z("tau_star_goe_facility"),desc:()=>`
                ${z("tau_star_goe_facility")}
                `,reqs:{eden:2},condition:()=>t.tauceti.ringworld.count>=1e3,queue_complete:()=>0,cost:{Money:e=>1e6,Copper:e=>1e7,Graphene:e=>5e6,Stanene:e=>8e6,Elerium:e=>1e4},effect(){let e=function(){let e=Gs("eden"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                ${z("tau_star_matrix_servants",[1])}
                `}();return`
                ${z("tau_star_goe_facility_effect")}
                ${e}`},action(){if(ri($(this)[0])){let a=Ns(Re.tau_star.goe_facility);return Object.keys(a).forEach((function(e){t.resource[e].amount+=a[e]()})),function(){P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"eden"});let a=t.race.species,r=t.race.gods,i=Ki[a].type,s=t.city.calendar.orbit,n=t.city.biome,c=t.city.ptrait,o=t.city.geology,l=Gs("eden");qn(`biome_${n}`),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),qn(`genus_${i}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),qn("adam_eve"),U(),Sn(),t.stats.eden++,rn(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let _=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),_&&(t.race.srace=_),H({orbit:s,biome:n,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),!1}return!1}}},tau_home:{info:{name:()=>z("tau_planet",[Ki[t.race.species].home]),desc:()=>z("tau_home",[Ki[t.race.species].home]),support:"orbital_station",extra(e){t.tech.tau_home&&t.tech.tau_home>=2&&!Qe()&&($(`#${e}`).append(`
                ${z("resource_Materials_name")} {{ amount | round }} / {{ max }}
                `),Cs({el:`#${e}Mats`,data:t.resource.Materials,methods:{tauShow:()=>!Qe()},filters:{round:e=>+e.toFixed(0)}}))}},home_mission:{id:"tauceti-home_mission",title:()=>z("tau_new_mission_title",[Ki[t.race.species].home]),desc:()=>z("tau_new_mission_title",[Ki[t.race.species].home]),reqs:{tauceti:2},grant:["tau_home",1],path:["truepath"],queue_complete:()=>t.tech.tau_home>=1?0:1,cost:{Money:()=>1e9},effect:()=>z("tau_new_mission_effect",[Ki[t.race.species].home]),action(){return!!ri($(this)[0])&&(t.tauceti.colony={count:0,on:0},t.tauceti.mining_pit={count:0,on:0},hs(z("tau_home_mission_result",[Ki[t.race.species].home]),"info",!1,["progress"]),!0)}},dismantle:{id:"tauceti-dismantle",title:()=>z("tau_home_dismantle"),desc:()=>z("tau_home_dismantle"),reqs:{tau_home:1},grant:["tau_home",2],path:["truepath"],queue_complete:()=>t.tech.tau_home>=2?0:1,cost:{Money:()=>1e8},effect(){let e="Explorer";if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let a=t.space.shipyard.ships.findIndex((e=>"tauceti"===e.location&&"explorer"===e.class));-1!==a&&(e=t.space.shipyard.ships[a].name)}return z("tau_home_dismantle_effect",[e])},action(){let e=-1;if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")&&(e=t.space.shipyard.ships.findIndex((e=>"tauceti"===e.location&&"explorer"===e.class))),e>=0&&ri($(this)[0])){if(t.space.shipyard.ships.splice(e,1),t.tauceti.orbital_station.count++,t.tauceti.colony.count++,t.tauceti.mining_pit.count++,t.civic.pit_miner.display=!0,t.resource.Materials.display=!0,t.city.powered&&t.city.power>=Re.tau_home.orbital_station.powered()){t.tauceti.orbital_station.on++,t.tauceti.colony.on++,t.tauceti.mining_pit.on++;let e=ta(4);t.civic[t.civic.d_job].workers${z("tau_home_orbital_station")}
                ${z("requires_power")}
                `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Ps("orbital_station",e,8e7,1.3,"tauceti"),Materials:e=>Qe()?0:Ps("orbital_station",e,5e5,1.3,"tauceti"),Helium_3:e=>Qe()?Ps("orbital_station",e,Ht(25e4),1.3,"tauceti"):0,Copper:e=>Qe()?Ps("orbital_station",e,125e4,1.3,"tauceti"):0,Adamantite:e=>Qe()?Ps("orbital_station",e,9e5,1.3,"tauceti"):0},effect(){let e=br(15e3),a=+Ht($(this)[0].support_fuel().a).toFixed(1),r=`
                ${z("space_red_spaceport_effect1",[z("tau_planet",[Ki[t.race.species].home]),$(this)[0].support()])}
                `;return r+=`
                ${z("plus_max_resource",[e.toLocaleString(),t.resource.Helium_3.name])}
                `,r+=`
                ${z("spend_power",[a,t.resource[$(this)[0].support_fuel().r].name,$(this)[0].powered()])}
                `,r},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?t.race.lone_survivor?5:25:400}),support:()=>3,powered:()=>As(t.tech.isolation?t.race.lone_survivor?4:6:30),refresh:!0,action(){return!!ri($(this)[0])&&(t.tauceti.orbital_station.count++,Yr($(this)[0]),!0)}},colony:{id:"tauceti-colony",title:z("tau_home_colony"),desc:()=>`
                ${z("tau_home_colony_desc",[Ki[t.race.species].home])}
                ${z("requires_power_support_combo",[Ki[t.race.species].home,t.resource.Food.name])}
                `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Ps("colony",e,1575e4,1.225,"tauceti"),Materials:e=>Qe()?0:Ps("colony",e,65e4,1.225,"tauceti"),Furs:e=>Qe()?Ps("colony",e,72e4,1.225,"tauceti"):0,Graphene:e=>Qe()?Ps("colony",e,485e3,1.225,"tauceti"):0,Brick:e=>Qe()?Ps("colony",e,Ve(88e4),1.225,"tauceti"):0},effect(){let e=$(this)[0].citizens(),a=t.tech.isolation?900:250,r=+$(this)[0].support_fuel().a.toFixed(1),i=`
                ${z("tau_new_support",[$(this)[0].support(),Ki[t.race.species].home])}
                `;if(t.race.lone_survivor||(i+=`
                ${z("plus_max_citizens",[e])}
                `),t.tech.isolation){let e=25*bi();e=br(e),e=(+e.toFixed(0)).toLocaleString(),i+=`
                ${z("plus_max_resource",[`$${e}`,z("resource_Money_name")])}
                `}if(i+=`
                ${z("tau_home_colony_effect",[50,Ki[t.race.species].home])}
                `,t.tech.isolation){let e=K("gaslighter",0);i+=`
                ${z("space_red_vr_center_effect1",[2*(e?e+t.tech.broadcast:t.tech.broadcast)])}
                `}return i+=`
                ${z("plus_max_resource",[a,z("resource_Crates_name")])}
                ${z("plus_max_resource",[a,z("resource_Containers_name")])}
                `,t.race.lone_survivor?i+=`
                ${z("gain",[-r,t.resource[$(this)[0].support_fuel().r].name])}
                `:i+=`
                ${z("spend",[r,t.resource[$(this)[0].support_fuel().r].name])}
                `,i},support:()=>-2,support_fuel:()=>({r:"Food",a:t.tech.isolation?t.race.lone_survivor?-2:75:1e3}),powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.colony.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.colony.on++,!0)},citizens(){let e=t.tech.isolation?8:5;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),t.race.lone_survivor?0:e}},tau_housing:{id:"tauceti-tau_housing",title:()=>pi("small"),desc:z("city_basic_housing_desc"),desc(){return 1===$(this)[0].citizens()?z("city_basic_housing_desc"):z("city_basic_housing_desc_plural",[$(this)[0].citizens()])},category:"residential",reqs:{housing:1,isolation:1},condition:()=>!t.race.lone_survivor,cost:{Money:e=>Ps("tau_housing",e,15e4,1.15,"tauceti"),Lumber:e=>t.race.kindling_kindred||t.race.smoldering?0:Ps("tau_housing",e,125e3,1.25,"tauceti"),Stone:e=>t.race.kindling_kindred?Ps("tau_housing",e,125e3,1.25,"tauceti"):0,Chrysotile:e=>t.race.smoldering?Ps("tau_housing",e,5e4,1.25,"tauceti"):0,Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.sappy?`
                ${z("plus_max_resource",[e,z("citizen")])}
                ${z("city_grove_effect",[2.5])}
                `:z("plus_max_resource",[e,z("citizen")])},action(){return!!ri($(this)[0])&&(t.tauceti.tau_housing.count++,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},captive_housing:Cr("captive_housing","tauceti"),pylon:{id:"tauceti-pylon",title:z("tau_home_pylon"),desc:z("tau_home_pylon"),reqs:{magic:2},condition:()=>!(!t.tech.isolation||!t.tauceti.hasOwnProperty("pylon")),cost:{Money:e=>Ps("pylon",e,50,1.48,"tauceti"),Stone:e=>Ps("pylon",e,100,1.42,"tauceti"),Crystal:e=>Ps("pylon",e,8,1.42,"tauceti")-3},effect(){let e=br(2);return`
                ${z("gain",[+(.0125*Is("magic")).toFixed(3),t.resource.Mana.name])}
                ${z("plus_max_resource",[e,t.resource.Mana.name])}
                `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!ri($(this)[0])&&(t.tauceti.pylon.count++,t.resource.Mana.max+=br(2),!0)}},cloning_facility:{id:"tauceti-cloning_facility",title:z("tau_home_cloning"),desc:()=>z("tau_home_cloning_desc",[Ki[t.race.species].name]),category:"military",reqs:{cloning:1},path:["truepath"],queue_complete:()=>t.resource[t.race.species].max-t.resource[t.race.species].amount,cost:{Money:e=>t.resource[t.race.species].amount?Ps("citizen",e,Math.round((t.race.high_pop?1e5:125e3)/ta(1)),t.race.high_pop?1.01:1.02,"tauceti",t.race.high_pop?1.003:1.005):0,Copper:e=>!t.race.artifical||t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Ps("citizen",e,Math.round(50/ta(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0,Aluminium:e=>!t.race.artifical||t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Ps("citizen",e,Math.round(50/ta(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0,Nanite:e=>t.race.deconstructor&&t.resource[t.race.species].amount>=3?Ps("citizen",e,Math.round(500/ta(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0},effect(){let e="";return t.resource[t.race.species].max===t.resource[t.race.species].amount&&(e=`
                ${z("city_assembly_effect_warn")}
                `),`
                ${z("tau_home_cloning_effect",[Ki[t.race.species].name])}
                ${e}`},action(){return!!(t.resource[t.race.species].max>t.resource[t.race.species].amount&&ri($(this)[0]))&&(t.resource[t.race.species].amount++,!0)}},horseshoe:Cr("horseshoe","tauceti"),bonfire:Cr("bonfire","tauceti"),firework:Cr("firework","tauceti"),assembly:Cr("assembly","tauceti"),nanite_factory:Cr("nanite_factory","tauceti"),tau_farm:{id:"tauceti-tau_farm",title:z("tau_home_tau_farm"),desc:()=>`
                ${z("tau_home_tau_farm")}
                ${z("requires_power")}
                `,reqs:{tau_home:7},path:["truepath"],cost:{Money:e=>Ps("tau_farm",e,135e6,1.25,"tauceti"),Stone:e=>Ps("tau_farm",e,921e4,1.25,"tauceti"),Steel:e=>Ps("tau_farm",e,6295e3,1.25,"tauceti"),Water:e=>Ps("tau_farm",e,1e4,1.25,"tauceti")},effect(){let e=`
                ${z("space_red_spaceport_effect1",[z("tau_planet",[Ki[t.race.species].home]),$(this)[0].support()])}
                `;return e+=`
                ${z("produce",[+$e("tau_farm","food").toFixed(2),t.resource.Food.name])}
                `,t.race.kindling_kindred||t.race.smoldering||(e+=`
                ${z("produce",[+$e("tau_farm","lumber").toFixed(2),t.resource.Lumber.name])}
                `),t.tech.isolation&&(e+=`
                ${z("produce",[+$e("tau_farm","water").toFixed(2),t.resource.Water.name])}
                `,t.race.artifical&&(e+=`
                ${z("city_transmitter_effect",[br(350)])}
                `)),e+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,e},support:()=>1,powered:()=>Fs(t.tech.isolation?1:4),action(){return!!ri($(this)[0])&&(t.tauceti.tau_farm.count++,Yr($(this)[0]),!0)}},mining_pit:{id:"tauceti-mining_pit",title:z("tau_home_mining_pit"),desc:()=>`
                ${z("tau_home_mining_pit")}
                ${z("space_support",[Ki[t.race.species].home])}
                `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Ps("mining_pit",e,425e4,1.225,"tauceti"),Materials:e=>Qe()?0:Ps("mining_pit",e,35e4,1.225,"tauceti"),Lumber:e=>Qe()?Ps("mining_pit",e,235e4,1.225,"tauceti"):0,Iron:e=>Qe()?Ps("mining_pit",e,835e3,1.225,"tauceti"):0},effect(){let e=`
                ${z("tau_new_support",[$(this)[0].support(),Ki[t.race.species].home])}
                `;if(e+=`
                ${z("plus_max_resource",[ta(t.tech.isolation?6:8),z("job_pit_miner")])}
                `,Qe())if(t.tech.isolation){if(t.race.lone_survivor){let a=[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name,t.resource.Copper.name,t.resource.Iron.name,t.resource.Aluminium.name,t.resource.Coal.name];t.race.smoldering?(a.push(t.resource.Chrysotile.name),e+=`
                ${z("tau_home_mining_pit_effect2cs",a)}
                `):e+=`
                ${z("tau_home_mining_pit_effect2c",a)}
                `}else{let a=[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name,t.resource.Copper.name,t.resource.Coal.name];t.race.smoldering?(a.push(t.resource.Chrysotile.name),e+=`
                ${z("tau_home_mining_pit_effect2bs",a)}
                `):e+=`
                ${z("tau_home_mining_pit_effect2b",a)}
                `}e+=`
                ${z("tau_gas_womling_station_effect",[8,t.resource.Cement.name])}
                `}else e+=`
                ${z("tau_home_mining_pit_effect2",[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name])}
                `;else e+=`
                ${z("plus_max_resource",[1e6,z("resource_Materials_name")])}
                `,e+=`
                ${z("tau_home_mining_pit_effect",[t.resource.Materials.name])}
                `;return e},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.mining_pit.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.mining_pit.on++,!0)}},excavate:{id:"tauceti-excavate",title:z("tau_home_excavate"),desc:()=>`
                ${z("tau_home_excavate")}
                `,reqs:{tau_home:2},grant:["tau_home",3],path:["truepath"],cost:{Money:e=>165e7,Materials:e=>75e4},effect:()=>z("tau_home_excavate_effect"),action(){return!!ri($(this)[0])&&(hs(z("tau_home_excavate_msg"),"info",!1,["progress"]),!0)}},alien_outpost:{id:"tauceti-alien_outpost",title:z("tech_alien_outpost"),desc:()=>`
                ${z("tech_alien_outpost")}
                ${z("requires_power")}
                `,reqs:{tau_home:4},path:["truepath"],cost:{},queue_complete:()=>0,effect(){let e=`
                ${z("plus_max_resource",["20%",z("resource_Knowledge_name")])}
                `;return t.tech.isolation&&(e+=`
                ${z("plus_max_resource",[(t.race.lone_survivor?35e5:65e5).toLocaleString(),z("resource_Knowledge_name")])}
                `,e+=`
                ${z("plus_max_resource",[2e5.toLocaleString(),t.resource.Cipher.name])}
                `,e+=`
                ${z("space_lander_effect3",[$e("alien_outpost"),t.resource.Cipher.name])}
                `),t.tech.outpost_boost&&(e+=`
                ${z("tech_alien_outpost_effect2")}
                `),t.race.lone_survivor&&(e+=`
                ${z("city_wardenclyffe_effect1",[ta(1),t.civic.professor.name])}
                `),e+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,e},powered:()=>As(t.tech.isolation?t.race.lone_survivor?8:25:100),special:()=>!!t.tech.replicator,action:()=>!1},jump_gate:{id:"tauceti-jump_gate",title:z("tau_jump_gate"),desc:e=>!t.tauceti.hasOwnProperty("jump_gate")||t.tauceti.jump_gate.count<100||e?`
                ${z("tau_jump_gate")}
                ${z("requires_segmemts",[100])}
                `:`
                ${z("tau_jump_gate")}
                `,reqs:{tauceti:3},condition:()=>t.tech.isolation?0:1,path:["truepath"],queue_size:10,queue_complete:()=>100-t.tauceti.jump_gate.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0)<100?1e6:0,Materials:e=>(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0)<100?12500:0},effect(e){let a=(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0);if(a<100){let e=100-a;return`
                ${z("tau_jump_gate_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                `}return z("tau_jump_gate_effect")},action(){return!!(ri($(this)[0])&&t.tauceti.jump_gate.count<100)&&(t.tauceti.jump_gate.count++,!0)}},fusion_generator:{id:"tauceti-fusion_generator",title:z("tech_fusion_generator"),desc:()=>`
                ${z("tech_fusion_generator")}
                ${z("requires_res",[t.resource.Helium_3.name])}
                `,reqs:{tau_home:6},path:["truepath"],cost:{Money:e=>Ps("fusion_generator",e,188e6,1.25,"tauceti"),Iridium:e=>Ps("fusion_generator",e,555e4,1.25,"tauceti"),Stanene:e=>Ps("fusion_generator",e,7003500,1.25,"tauceti"),Sheet_Metal:e=>Ps("fusion_generator",e,Ve(95e3),1.25,"tauceti")},effect(){let e=+Ht($(this)[0].p_fuel().a).toFixed(1),a=`
                ${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
                `;return t.race.lone_survivor?a+=`
                ${z("gain",[-e,t.resource[$(this)[0].p_fuel().r].name])}
                `:a+=`
                ${z("spend",[e,t.resource[$(this)[0].p_fuel().r].name])}
                `,a},p_fuel:()=>({r:"Helium_3",a:t.tech.isolation?t.race.lone_survivor?-15:75:500}),powered:()=>Fs(-32),action(){return!!ri($(this)[0])&&(t.tauceti.fusion_generator.count++,t.tauceti.fusion_generator.on++,!0)}},repository:{id:"tauceti-repository",title:z("tech_repository"),desc:z("tech_repository"),reqs:{tau_home:5},path:["truepath"],cost:{Money:e=>Ps("repository",e,1028e4,1.28,"tauceti"),Iron:e=>Ps("repository",e,18e5,1.28,"tauceti"),Cement:e=>Ps("repository",e,15e5,1.28,"tauceti"),Neutronium:e=>Ps("repository",e,215e3,1.28,"tauceti")},wide:!0,res(){let e=["Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Crystal","Alloy","Polymer","Iridium","Chrysotile","Nano_Tube","Neutronium","Adamantite","Unobtainium"];return t.tech.isolation&&(e.push("Oil"),e.push("Helium_3"),e.push("Uranium"),e.push("Water")),e},val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 3e4;case"Crystal":return 10;case"Furs":return 17e3;case"Copper":return 15200;case"Iron":return 14e3;case"Aluminium":return 12800;case"Cement":return 11200;case"Coal":return 4800;case"Steel":return 2400;case"Titanium":return 1600;case"Alloy":return 1800;case"Polymer":return 1500;case"Iridium":return 1750;case"Nano_Tube":return 1200;case"Neutronium":return 640;case"Adamantite":return 720;case"Unobtainium":return 1e3;case"Oil":return 680;case"Helium_3":return 575;case"Uranium":return 125;case"Water":return 15;case"Elerium":return 3;default:return 0}},effect(){let e='
                ',a=mt("repository");for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${z("plus_max_resource",[x(+(br($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return t.tech.isolation&&(e+=`${z("plus_max_resource",[250,z("resource_Crates_name")])}${z("plus_max_resource",[250,z("resource_Containers_name")])}`),e+="
                ",e},action(){if(ri($(this)[0])){t.tauceti.repository.count++;let e=mt("repository");for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=br($(this)[0].val(a))*e);return!0}return!1}},tau_factory:{id:"tauceti-tau_factory",title:z("tau_home_tau_factory"),desc:()=>`
                ${z("tau_home_tau_factory")}
                ${z("requires_power_support",[Ki[t.race.species].home])}
                `,reqs:{tau_home:8},path:["truepath"],cost:{Money:e=>Ps("tau_factory",e,269e6,1.25,"tauceti"),Titanium:e=>Ps("tau_factory",e,3e6,1.25,"tauceti"),Elerium:e=>Ps("tau_factory",e,850,1.25,"tauceti"),Bolognium:e=>Ps("tau_factory",e,25e4,1.25,"tauceti"),Quantium:e=>Ps("tau_factory",e,Ve(425e3),1.25,"tauceti")},effect(){let e=`
                ${z("tau_new_support",[$(this)[0].support(),Ki[t.race.species].home])}
                `;return e+=`
                ${z("tau_home_tau_factory_effect",[t.tech.isolation?5:3])}
                `,t.tech.isolation&&(t.race.flier||(e+=`
                ${z("city_cement_plant_effect1",[ta(2)])}
                `),e+=`
                ${z("space_red_fabrication_effect1",[ta(5)])}
                `),e+=`
                ${z("city_crafted_mats",[t.tech.isolation?275:90])}
                `,e+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,e},special:!0,support:()=>-1,powered:()=>As(t.tech.isolation?2:5),action(){return!!ri($(this)[0])&&(t.tauceti.tau_factory.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.tau_factory.on++,!0)}},infectious_disease_lab:{id:"tauceti-infectious_disease_lab",title:()=>t.tech.isolation?z("tech_infectious_disease_lab_alt"):z(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),desc(){return`
                ${$(this)[0].title()}
                ${z("requires_power_support",[Ki[t.race.species].home])}
                `},reqs:{disease:1},path:["truepath"],cost:{Money:e=>Ps("infectious_disease_lab",e,1e9,1.25,"tauceti"),Alloy:e=>Ps("infectious_disease_lab",e,325e5,1.25,"tauceti"),Polymer:e=>Ps("infectious_disease_lab",e,5e7,1.25,"tauceti"),Bolognium:e=>Ps("infectious_disease_lab",e,25e5,1.25,"tauceti"),Unobtainium:e=>Ps("infectious_disease_lab",e,64e3,1.25,"tauceti")},effect(){let e=39616;if(t.tech.supercollider&&t.tech.isolation){let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}let a=`
                ${z("tau_new_support",[$(this)[0].support(),Ki[t.race.species].home])}
                `;return a+=`
                ${z("city_max_knowledge",[Math.round(e).toLocaleString()])}
                `,t.tech.isolation&&(a+=`
                ${z("plus_max_resource",[br(375),z("resource_Elerium_name")])}
                `,a+=`
                ${z("city_wardenclyffe_effect1",[ta(2),t.civic.professor.name])}
                `,a+=`
                ${z("city_wardenclyffe_effect1",[ta(1),t.civic.scientist.name])}
                `,a+=`
                ${z("space_zero_g_lab_effect",[ta(1)])}
                `,a+=`
                ${z("city_library_effect",[75])}
                `),t.tech.alien_crafting&&(a+=`
                ${z("tau_gas_womling_station_effect",[65,t.resource.Quantium.name])}
                `),t.tech.focus_cure&&(a+=`
                ${z("tau_home_disease_lab_cure",[+t.tauceti.infectious_disease_lab.cure.toFixed(1)])}
                `,t.race.hasOwnProperty("vax")&&(a+=`
                ${z("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
                `)),a+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,a},support:()=>-1,powered:()=>As(t.tech.isolation?t.race.lone_survivor?2:8:35),action(){return!!ri($(this)[0])&&(t.tauceti.infectious_disease_lab.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.infectious_disease_lab.on++,!0)},post(){1===t.tech.disease&&(t.tech.disease=2,hs(z("tau_plague4",[z("tab_tauceti")]),"info",!1,["progress"]),Qr())}},tauceti_casino:{id:"tauceti-tauceti_casino",title:z("city_casino"),desc:z("city_casino"),category:"commercial",reqs:{gambling:1,isolation:1},cost:{Money:e=>Ps("tauceti_casino",e,145e4,1.35,"tauceti"),Furs:e=>Ps("tauceti_casino",e,95e3,1.35,"tauceti"),Cement:e=>Ps("tauceti_casino",e,12e4,1.35,"tauceti"),Plywood:e=>Ps("tauceti_casino",e,Ve(55e3),1.35,"tauceti")},effect(){let e=$(this)[0].citizens(),a=t.race.lone_survivor?"":`
                ${z("plus_max_resource",[e,z("citizen")])}
                `;return a+=Kr(),a+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,a},powered:()=>As(t.race.lone_survivor?1:2),action(){return!!ri($(this)[0])&&(t.tauceti.tauceti_casino.count++,t.race.joyless||(t.civic.entertainer.max+=ta(1),t.civic.entertainer.display=!0),Yr($(this)[0]),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),t.race.lone_survivor?0:e},flair:z("city_casino_flair")},tau_cultural_center:{id:"tauceti-tau_cultural_center",title:z("tech_cultural_center"),desc(){return`
                ${z("tech_cultural_center")}
                ${z("space_electrolysis_req",[t.resource[$(this)[0].p_fuel().r].name])}
                `},category:"commercial",reqs:{tau_culture:1},path:["truepath"],cost:{Money:e=>Ps("tau_cultural_center",e,9145e4,1.35,"tauceti"),Copper:e=>Ps("tau_cultural_center",e,585e4,1.35,"tauceti"),Coal:e=>Ps("tau_cultural_center",e,465e3,1.35,"tauceti"),Polymer:e=>Ps("tau_cultural_center",e,3792e3,1.35,"tauceti")},effect(){let e=1;"corpocracy"===t.civic.govern.type?e=2:"socialist"===t.civic.govern.type&&(e=.8);let a=20*e,r=5*e,i=15*e,s=`
                ${z("tau_home_cultureal_effect1",[$(this)[0].p_fuel().a,t.resource[$(this)[0].p_fuel().r].name,$(this)[0].title])}
                `;return s+=`
                ${z("city_tourist_center_effect3",[a])}
                `,s+=`
                ${z("city_tourist_center_effect4",[r])}
                `,s+=`
                ${z("tau_home_cultureal_effect2",[8,z("tau_red_womlings")])}
                `,t.tech.tau_culture>=2&&(s+=`
                ${z("tau_home_cultureal_effect3",[i,z(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)])}
                `),s+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,s},powered:()=>As(1),p_fuel:()=>({r:"Food",a:t.race.lone_survivor?25:500}),action(){return!!ri($(this)[0])&&(t.tauceti.tau_cultural_center.count++,t.tauceti.tau_cultural_center.on++,!0)}}},tau_red:{info:{name:()=>z("tau_planet",[Ut().red]),desc:()=>z("tau_red",[Ut().red]),support:"orbital_platform",extra(e){t.tech.tau_red&&t.tech.tau_red>=5&&($(`#${e}`).append(`
                ${z("tau_red_womling_prod")} {{ prod }}%
                `),Cs({el:`#${e}Womlings`,data:t.tauceti.overseer}))}},red_mission:{id:"tauceti-red_mission",title:()=>z("tau_new_mission_title",[Ut().red]),desc:()=>z("tau_new_mission_title",[Ut().red]),reqs:{tauceti:2},grant:["tau_red",1],path:["truepath"],queue_complete:()=>t.tech.tau_red>=1?0:1,cost:{Money:()=>1e9},effect:()=>z("tau_new_mission_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.tauceti.settlement={count:0,on:0},hs(z("tau_red_mission_result",[Ut().red]),"info",!1,["progress"]),!0)}},orbital_platform:{id:"tauceti-orbital_platform",title:z("tau_red_orbital_platform"),desc:`
                ${z("tau_red_orbital_platform")}
                ${z("requires_power")}
                `,reqs:{tau_red:1,tauceti:4},path:["truepath"],cost:{Money:e=>Ps("orbital_platform",e,5e7,1.3,"tauceti"),Oil:e=>{return Qe()?Ps("orbital_platform",e,Ht((a=275e3,t.tech.womling_tech&&t.tech.womling_logistics&&t.tech.womling_logistics>=2&&(a*=.94**t.tech.womling_tech),a)),1.3,"tauceti"):0;var a},Aluminium:e=>Ps("orbital_platform",e,178e4,1.3,"tauceti"),Bolognium:e=>Ps("orbital_platform",e,45e4,1.3,"tauceti")},effect(){let e=br(17500),a=+Ht($(this)[0].support_fuel().a).toFixed(1),r=`
                ${z("space_red_spaceport_effect1",[z("tau_planet",[Ut().red]),$(this)[0].support()])}
                `;return r+=`
                ${z("plus_max_resource",[e.toLocaleString(),t.resource.Oil.name])}
                `,r+=`
                ${z("spend_power",[a,t.resource[$(this)[0].support_fuel().r].name,$(this)[0].powered()])}
                `,r},support_fuel:()=>({r:t.race.lone_survivor?"Helium_3":"Oil",a:t.tech.isolation?t.race.lone_survivor?8:32:125}),support(){let e=t.tech.womling_logistics?2.5:2;return t.race.lone_survivor&&(e*=2),e},powered:()=>As(t.tech.isolation?t.race.lone_survivor?2:3:18),refresh:!0,action(){return!(!Qe()||!ri($(this)[0])||(t.tauceti.orbital_platform.count++,Yr($(this)[0]),1===t.tech.tau_red&&(t.tech.tau_red=2,hs(z("tau_red_orbital_platform_msg",[z("tau_planet",[Ut().red]),z("tau_planet",[Ki[t.race.species].home])]),"info",!1,["progress"])),0))}},contact:{id:"tauceti-contact",title:()=>z("tau_red_contact"),desc:()=>z("tau_red_contact"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Money:()=>6e8,Food:()=>t.race.lone_survivor&&t.race.artifical?62e3:25e5},effect:()=>z("tau_red_contact_effect"),action(){return!!ri($(this)[0])&&(t.race.womling_friend=1,Ue(),!0)}},introduce:{id:"tauceti-introduce",title:()=>z("tau_red_introduce"),desc:()=>z("tau_red_introduce"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Knowledge:()=>7e6},effect:()=>z("tau_red_introduce_effect"),action(){return!!ri($(this)[0])&&(t.race.womling_god=1,Ue(),!0)}},subjugate:{id:"tauceti-subjugate",title:()=>z("tau_red_subjugate"),desc:()=>z("tau_red_subjugate"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Money:()=>285e7},effect:()=>z("tau_red_subjugate_effect"),action(){return!!ri($(this)[0])&&(t.race.womling_lord=1,Ue(),!0)}},jeff:{id:"tauceti-jeff",title:()=>z("tau_red_jeff"),desc:()=>z("tau_red_jeff"),reqs:{tau_red:5},path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{},effect(){let e=t.tauceti.overseer?t.tauceti.overseer.injured:0;t.tauceti.overseer&&t.tauceti.overseer.pop${z("tau_red_jeff_effect1",[t.tauceti.overseer?t.tauceti.overseer.pop:0])}
                `;return a+=`
                ${z("tau_red_jeff_effect2",[t.tauceti.overseer?t.tauceti.overseer.working:0])}
                `,a+=`
                ${z("tau_red_jeff_effect3",[e])}
                `,a+=`
                ${z("tau_red_jeff_effect4",[t.tauceti.overseer?t.tauceti.overseer.loyal:0])}
                `,a+=`
                ${z("tau_red_jeff_effect5",[t.tauceti.overseer?t.tauceti.overseer.morale:0])}
                `,t.tech.hasOwnProperty("womling_tech")&&(a+=`
                ${z("tau_red_jeff_effect6",[t.tech.womling_tech])}
                `),a+=`
                ${z("job_farmer")}: ${t.tauceti.womling_farm?t.tauceti.womling_farm.farmers:0}
                `,a+=`
                ${z("job_miner")}: ${t.tauceti.womling_mine?t.tauceti.womling_mine.miners:0}
                `,t.tauceti.womling_lab&&(a+=`
                ${z("job_scientist")}: ${t.tauceti.womling_lab?t.tauceti.womling_lab.scientist:0}
                `),a},action:()=>!1},overseer:{id:"tauceti-overseer",title(){return $(this)[0].name()},desc(){return`
                ${$(this)[0].name()}
                ${z("space_support",[Ut().red])}
                `},name:()=>t.race.womling_lord?z("tau_red_overseer"):t.race.womling_god?z("tau_red_womgod"):z("tau_red_womally"),reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Ps("overseer",e,6e6,1.28,"tauceti"),Cement:e=>Ps("overseer",e,245e4,1.28,"tauceti"),Alloy:e=>t.race.womling_friend?Ps("overseer",e,185e4,1.28,"tauceti"):0,Neutronium:e=>t.race.womling_lord?Ps("overseer",e,165e3,1.28,"tauceti"):0,Titanium:e=>t.race.womling_god?Ps("overseer",e,225e4,1.28,"tauceti"):0},effect(){let e=`
                ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                `;return e+=`
                ${z("tau_red_overseer_effect",[$(this)[0].val()])}
                `,e},val(){let e=0;return t.race.womling_lord?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?12:10:t.race.womling_god?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?6:5:t.race.womling_friend&&(e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?10:8),t.race.lone_survivor&&(e*=2),e},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.overseer.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.overseer.on++,!0)}},womling_village:{id:"tauceti-womling_village",title:z("tau_red_womling_village"),desc:()=>`
                ${z("tau_red_womling_village")}
                ${z("space_support",[Ut().red])}
                `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Ps("womling_village",e,1e7,1.28,"tauceti"),Stone:e=>Ps("womling_village",e,225e4,1.28,"tauceti"),Plywood:e=>Ps("womling_village",e,Ve(125e4),1.28,"tauceti"),Wrought_Iron:e=>Ps("womling_village",e,Ve(4e5),1.28,"tauceti")},effect(){let e=t.tech.womling_pop&&t.tech.womling_pop>=2?6:5,a=`
                ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                `;return a+=`
                ${z("tau_red_womling_village_effect",[e])}
                `,t.tech.tau_junksale&&(a+=`
                ${z("tau_red_womling_village_effect2",[40,z(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`)])}
                `),a},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_village.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_village.on++,!0)}},womling_farm:{id:"tauceti-womling_farm",title:z("tau_red_womling_farm"),desc:()=>`
                ${z("tau_red_womling_farm")}
                ${z("space_support",[Ut().red])}
                `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Ps("womling_farm",e,24e6,1.28,"tauceti"),Iron:e=>Ps("womling_farm",e,95e5,1.28,"tauceti"),Water:e=>Ps("womling_farm",e,5e3,1.28,"tauceti")},effect(){let e=t.tech.womling_pop?16:12;t.tech.womling_gene&&(e+=4);let a=t.tauceti.hasOwnProperty("womling_farm")?t.tauceti.womling_farm.farmers:0,r=`
                ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                `;return r+=`
                ${z("tau_red_womling_farm_effect",[e])}
                `,r+=`
                ${z("tau_red_womling_employ",[2])}
                `,t.tech.isolation&&(r+=`
                ${z("tau_red_womling_generate",[t.resource.Furs.name])}
                `),r+=`
                ${z("tau_red_womling_farm_effect2",[e/2*a])}
                `,r},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_farm.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_farm.on++,!0)}},womling_mine:{id:"tauceti-womling_mine",title:z("tau_red_womling_mine"),desc:()=>`
                ${z("tau_red_womling_mine")}
                ${z("space_support",[Ut().red])}
                `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Ps("womling_mine",e,125e5,1.28,"tauceti"),Lumber:e=>Ps("womling_mine",e,128e5,1.28,"tauceti"),Steel:e=>Ps("womling_mine",e,45e5,1.28,"tauceti")},effect(){let e=`
                ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                `;return t.tech.isolation?t.race.lone_survivor?e+=`
                ${z("tau_red_womling_mine_effect_c",[t.resource.Unobtainium.name,t.resource.Uranium.name,t.resource.Titanium.name,t.resource.Iron.name,t.resource.Copper.name,t.resource.Aluminium.name,t.resource.Neutronium.name,t.resource.Iridium.name])}
                `:e+=`
                ${z("tau_red_womling_mine_effect_b",[t.resource.Unobtainium.name,t.resource.Uranium.name,t.resource.Titanium.name])}
                `:e+=`
                ${z("tau_red_womling_mine_effect_a",[t.resource.Unobtainium.name])}
                `,e+=`
                ${z("tau_red_womling_employ",[6])}
                `,e},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_mine.count++,t.resource.Unobtainium.display=!0,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_mine.on++,!0)},flair:()=>z("tau_red_womling_mine_flair")},womling_fun:{id:"tauceti-womling_fun",title(){return $(this)[0].name()},desc(){return`
                ${$(this)[0].name()}
                ${z("space_support",[Ut().red])}
                `},name:()=>t.race.womling_lord?z("tau_red_womling_fun1"):t.race.womling_god?z("tau_red_womling_fun2"):z("tau_red_womling_fun3"),reqs:{tau_red:6},path:["truepath"],cost:{Money:e=>Ps("womling_fun",e,38e5,1.28,"tauceti"),Food:e=>t.race.womling_friend?Ps("womling_fun",e,175e3,1.28,"tauceti"):0,Lumber:e=>Ps("womling_fun",e,5e5,1.28,"tauceti"),Stone:e=>Ps("womling_fun",e,5e5,1.28,"tauceti"),Furs:e=>t.race.womling_lord||t.race.womling_god?Ps("womling_fun",e,835e3,1.28,"tauceti"):0,Copper:e=>t.race.womling_lord?Ps("womling_fun",e,1125e3,1.28,"tauceti"):0,Alloy:e=>t.race.womling_god?Ps("womling_fun",e,656e3,1.28,"tauceti"):0,Water:e=>t.race.womling_friend?Ps("womling_fun",e,3500,1.28,"tauceti"):0},effect(){let e=`
                ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                `;return e+=`
                ${z("tau_red_womling_fun_effect",[$(this)[0].val()])}
                `,e},val(){let e=0;return t.race.womling_lord?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?24:20:t.race.womling_god?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?12:10:t.race.womling_friend&&(e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?18:15),t.race.lone_survivor&&(e*=2),e},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_fun.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_fun.on++,!0)}},womling_lab:{id:"tauceti-womling_lab",title:z("interstellar_laboratory_title"),desc:()=>`
                ${z("interstellar_laboratory_title")}
                ${z("space_support",[Ut().red])}
                `,reqs:{tau_red:7},path:["truepath"],cost:{Money:e=>Ps("womling_lab",e,65e6,1.28,"tauceti"),Elerium:e=>Ps("womling_lab",e,1200,1.28,"tauceti"),Orichalcum:e=>Ps("womling_lab",e,25e5,1.28,"tauceti"),Unobtainium:e=>Ps("womling_lab",e,1e4,1.28,"tauceti"),Quantium:e=>Ps("womling_lab",e,Ve(95e3),1.28,"tauceti")},effect(){let e=t.tauceti.hasOwnProperty("overseer")?t.tauceti.overseer.prod:100,a=Math.round(25e3*e/100),r=`
                ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                `;return r+=`
                ${z("tau_red_womling_lab_effect",[a])}
                `,r+=`
                ${z("tau_red_womling_employ_single",[1])}
                `,r},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_lab.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_lab.on++,!0)}}},tau_gas:{info:{name(e,a){let r=a||"gas_name",i="gas_name"===r?0:1;if(e||t.race[r])switch(e||t.race[r]){case 1:{let e="antimatter"===t.race.universe?"plasmid":"antiplasmid";switch(Math.round(t.stats[e]+i)%3){case 1:return z("tau_planet",[Ut().gas]);case 2:return z("tau_gas_title0a",[Ut().gas]);default:return z("tau_gas_title0b",[Ut().gas])}}case 2:switch(Math.round(t.stats.reset+i)%3){case 1:return z("tau_gas_title1a");case 2:return z("tau_gas_title1b");default:return z("tau_gas_title1c")}case 3:switch(Math.round(t.stats.mad+i)%3){case 1:return z("tau_gas_title2a");case 2:return z("tau_gas_title2b");default:return z("tau_gas_title2c")}case 4:switch(Math.round(t.stats.bioseed+i)%3){case 1:return z("tau_gas_title3a",[Ki[t.race.gods].solar.gas]);case 2:return z("tau_gas_title3b",[Ki[t.race.old_gods].name]);default:return z("tau_gas_title3c",[Ki[t.race.species].name])}case 5:switch(Math.round(t.stats.portals+i)%3){case 1:return z("tau_gas_title4a",[Ut().gas]);case 2:return z("tau_gas_title4b",[nn("reverse",Ut().gas)]);default:return z("tau_gas_title4c")}case 6:switch(Math.round(t.stats.womling.friend.l+t.stats.womling.lord.l+t.stats.womling.god.l+i)%3){case 1:return z("tau_gas_title5a");case 2:return z("tau_gas_title5b");default:return z("tau_gas_title5c")}case 7:switch(Math.round(t.stats.tdays+i)%3){case 1:return z("tau_gas_title6a");case 2:return z("tau_gas_title6b");default:return z("tau_gas_title6c")}default:return z("gas_name"===r?"tau_gas_title":"tau_gas2_title")}return z("gas_name"===r?"tau_gas_title":"tau_gas2_title")},desc:()=>z("tau_gas_desc")},gas_contest:{id:"tauceti-gas_contest",title:()=>z("tau_gas_contest_title"),desc:()=>z("tau_gas_contest_title"),reqs:{tauceti:5},grant:["tau_gas",1],path:["truepath"],queue_complete:()=>t.tech.tau_gas>=1?0:1,cost:{Money:()=>1e7},effect:()=>t.race.lone_survivor?z("tau_gas_contest_effect_alt"):z("tau_gas_contest_effect"),action(){return!!ri($(this)[0])}},refueling_station:{id:"tauceti-refueling_station",title:()=>z("tau_gas_refueling_station_title"),desc:()=>`
                ${z("tau_gas_refueling_station_title")}
                ${z("requires_power")}
                `,reqs:{tau_gas:2},path:["truepath"],cost:{Money:e=>Ps("refueling_station",e,68e6,1.28,"tauceti"),Graphene:e=>Ps("refueling_station",e,25e5,1.28,"tauceti"),Unobtainium:e=>Ps("refueling_station",e,5500,1.28,"tauceti"),Mythril:e=>Ps("refueling_station",e,Ve(6e4),1.28,"tauceti")},powered:()=>As(t.tech.isolation?2:5),effect(){let e=+$e("refueling_station").toFixed(2),a=br(1e4),r=`
                ${z("space_gas_mining_effect1",[e])}
                `;return r+=`
                ${z("plus_max_resource",[a.toLocaleString(),t.resource.Helium_3.name])}
                `,t.tech.tau_whale>=2&&(r+=`
                ${z("plus_max_resource",[br(6500).toLocaleString(),t.resource.Oil.name])}
                `),t.tech.isolation&&(r+=`
                ${z("interstellar_g_factory_effect")}
                `),r+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,r},special:()=>!!t.tech.isolation,action(){return!!ri($(this)[0])&&(t.tauceti.refueling_station.count++,Yr($(this)[0]),!0)},post(){2===t.tech.tau_gas&&(t.tech.tau_gas=3,Qr())}},ore_refinery:{id:"tauceti-ore_refinery",title:()=>z("tau_gas_ore_refinery_title"),desc:()=>`
                ${z("tau_gas_ore_refinery_title")}
                ${z("requires_power")}
                `,reqs:{tau_gas:4},path:["truepath"],cost:{Money:e=>Ps("ore_refinery",e,52e6,1.28,"tauceti"),Iridium:e=>Ps("ore_refinery",e,16e5,1.28,"tauceti"),Unobtainium:e=>Ps("ore_refinery",e,800,1.28,"tauceti"),Sheet_Metal:e=>Ps("ore_refinery",e,Ve(118e3),1.28,"tauceti")},powered:()=>As(t.tech.isolation?2:8),effect(){let e=t.tauceti.hasOwnProperty("ore_refinery")?t.tauceti.ore_refinery.fill:0,a=t.tauceti.hasOwnProperty("ore_refinery")?t.tauceti.ore_refinery.max:0,r=+$e("ore_refinery").toFixed(2),i=`
                ${z("tau_gas_ore_refinery_effect",[+e.toFixed(2)])}
                `;return i+=`
                ${z("tau_gas_ore_refinery_effect2",[a])}
                `,i+=`
                ${z("tau_gas_ore_refinery_effect3",[r])}
                `,i+=`
                ${z("interstellar_stellar_forge_effect3",[t.tech.isolation?12:4])}
                `,i+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,i},special:!0,action(){return!!ri($(this)[0])&&(t.tauceti.ore_refinery.count++,t.city.powered&&t.city.power>=$(this)[0].powered()&&(t.tauceti.ore_refinery.on++,t.city.smelter.cap+=t.tech.isolation?12:2,t.city.smelter.Steel+=t.tech.isolation?12:2,t.race.evil?t.city.smelter.Wood+=t.tech.isolation?12:2:t.city.smelter.Oil+=t.tech.isolation?12:2),!0)},post(){3===t.tech.tau_roid&&(t.tech.tau_roid=4,Je(),Qr())}},whaling_station:{id:"tauceti-whaling_station",title:()=>z("tau_gas_whaling_station_title"),desc:()=>`
                ${z("tau_gas_whaling_station_title")}
                ${z("requires_power")}
                `,reqs:{tau_whale:1},path:["truepath"],cost:{Money:e=>Ps("whaling_station",e,72e6,1.28,"tauceti"),Steel:e=>Ps("whaling_station",e,18e5,1.28,"tauceti"),Polymer:e=>Ps("whaling_station",e,955e3,1.28,"tauceti"),Orichalcum:e=>Ps("whaling_station",e,268e3,1.28,"tauceti")},powered:()=>As(t.tech.isolation?2:6),effect(){let e=t.tauceti.hasOwnProperty("whaling_station")?t.tauceti.whaling_station.fill:0,a=t.tauceti.hasOwnProperty("whaling_station")?t.tauceti.whaling_station.max:0,r=+$e("whaling_station").toFixed(2),i=`
                ${z("tau_gas_whaling_station_effect",[+e.toFixed(2)])}
                `;return i+=`
                ${z("tau_gas_whaling_station_effect2",[a])}
                `,i+=`
                ${z("tau_gas_whaling_station_effect3",[r])}
                `,i+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,i},action(){return!!ri($(this)[0])&&(t.tauceti.whaling_station.count++,Yr($(this)[0]),!0)},post(){1===t.tech.tau_whale&&(t.tech.tau_whale=2,Je())}},womling_station:{id:"tauceti-womling_station",title:()=>z("tau_gas_womling_station_title"),desc:()=>`
                ${z("tau_gas_womling_station_desc")}
                ${z("requires_power")}
                `,reqs:{womling_technicians:1},path:["truepath"],cost:{Money:e=>Ps("womling_station",e,1334e5,1.26,"tauceti"),Furs:e=>Ps("womling_station",e,3805e3,1.26,"tauceti"),Aluminium:e=>Ps("womling_station",e,85e5,1.26,"tauceti"),Nano_Tube:e=>Ps("womling_station",e,909e3,1.26,"tauceti")},powered:()=>As(t.tech.isolation?3:6),effect(){let e=t.tech.isolation?30:8;t.tech.womling_gene&&(e*=1.25);let a=`
                ${z("tau_gas_womling_station_effect",[e,Re.tau_gas.info.name()])}
                `;return t.race.flier||(a+=`
                ${z("city_cement_plant_effect1",[ta(1)])}
                `),a+=`
                ${z("space_red_fabrication_effect1",[ta(1)])}
                `,a+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,a},action(){return!!ri($(this)[0])&&(t.tauceti.womling_station.count++,Yr($(this)[0]),!0)}}},tau_roid:{info:{name:()=>z("tau_roid_title"),desc:()=>z("tau_roid_desc"),support:"patrol_ship"},roid_mission:{id:"tauceti-roid_mission",title:()=>z("space_mission_title",[z("tau_roid_title")]),desc:()=>z("space_mission_desc",[z("tau_roid_title")]),reqs:{tauceti:5},grant:["tau_roid",1],path:["truepath"],queue_complete:()=>t.tech.tau_roid>=1?0:1,cost:{Helium_3:(e,t)=>+Ht(125e4).toFixed(0)},effect:()=>z("tau_roid_mission_effect",[z("tau_roid_title")]),action(){return!!ri($(this)[0])&&(hs(z("tau_roid_mission_result"),"info",!1,["progress"]),!0)}},patrol_ship:{id:"tauceti-patrol_ship",title:z("tau_roid_patrol_ship"),desc:()=>`
                ${z("tau_roid_patrol_ship")}
                ${z("requires_res",[t.resource.Helium_3.name])}
                `,reqs:{tau_roid:3},path:["truepath"],cost:{Money:e=>Ps("patrol_ship",e,45e6,1.25,"tauceti"),Adamantite:e=>Ps("patrol_ship",e,18e5,1.25,"tauceti"),Elerium:e=>Ps("patrol_ship",e,520,1.25,"tauceti"),Stanene:e=>Ps("patrol_ship",e,2675e3,1.25,"tauceti"),Bolognium:e=>Ps("patrol_ship",e,115e4,1.25,"tauceti")},effect(){let e=+Ht($(this)[0].support_fuel().a).toFixed(1),a=`
                ${z("tau_roid_patrol_ship_security",[$(this)[0].support()])}
                `;return a+=`
                ${z("tau_roid_patrol_ship_effect")}
                `,a+=`
                ${z("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
                `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?15:250}),support:()=>1,powered:()=>As(1),refresh:!0,action(){return!!ri($(this)[0])&&(t.tauceti.patrol_ship.count++,t.tauceti.patrol_ship.on++,!0)}},mining_ship:{id:"tauceti-mining_ship",title:z("tau_roid_mining_ship"),desc:()=>`
                ${z("tau_roid_mining_ship")}
                `,reqs:{tau_roid:4},path:["truepath"],cost:{Money:e=>Ps("mining_ship",e,28e6,1.28,"tauceti"),Uranium:e=>Ps("mining_ship",e,12500,1.28,"tauceti"),Titanium:e=>Ps("mining_ship",e,22e5,1.28,"tauceti"),Alloy:e=>Ps("mining_ship",e,175e4,1.28,"tauceti")},effect(){let e=+Ht($(this)[0].support_fuel().a).toFixed(1),a=`
                ${z("tau_roid_mining_ship_effect",[+$e("mining_ship").toFixed(2)])}
                `;return a+=`
                ${z("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
                `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?12:75}),support:()=>-1,powered:()=>As(1),special:!0,action(){return!!ri($(this)[0])&&(t.tauceti.mining_ship.count++,t.tauceti.mining_ship.on++,!0)}},whaling_ship:{id:"tauceti-whaling_ship",title:z("tau_roid_whaling_ship"),desc:()=>`
                ${z("tau_roid_whaling_ship")}
                `,reqs:{tau_whale:2},path:["truepath"],cost:{Money:e=>Ps("whaling_ship",e,35e6,1.28,"tauceti"),Aluminium:e=>Ps("whaling_ship",e,34e5,1.28,"tauceti"),Neutronium:e=>Ps("whaling_ship",e,168e3,1.28,"tauceti"),Nano_Tube:e=>Ps("whaling_ship",e,8e5,1.28,"tauceti")},effect(){let e=+Ht($(this)[0].support_fuel().a).toFixed(1),a=`
                ${z("tau_roid_whaling_ship_effect",[+$e("whaling_ship").toFixed(2)])}
                `;return a+=`
                ${z("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
                `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?14:90}),support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.whaling_ship.count++,t.tauceti.whaling_ship.on++,!0)}}},tau_gas2:{info:{name:e=>Re.tau_gas.info.name(e||t.race.gas_name2||!1,"gas_name2"),desc:()=>z("tau_gas2_desc",[Re.tau_gas.info.name()])},gas_contest2:{id:"tauceti-gas_contest2",title:()=>z("tau_gas2_contest_title"),desc:()=>z("tau_gas2_contest_title"),reqs:{tau_gas2:1},grant:["tau_gas2",2],path:["truepath"],queue_complete:()=>t.tech.tau_gas2>=1?0:1,cost:{Money:()=>25e6},effect:()=>z("tau_gas2_contest_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tau_gas2_contest_flair")},alien_station_survey:{id:"tauceti-alien_station_survey",title:z("tau_gas2_alien_station"),desc:z("tau_gas2_alien_station"),reqs:{tau_gas2:3},grant:["tau_gas2",4],path:["truepath"],queue_complete:()=>t.tech.tau_gas3>=4?0:1,cost:{Money:()=>t.race.lone_survivor?15e8:3e9,Helium_3:()=>5e6},effect:()=>z("tau_gas2_alien_station_repair_effect",[Re.tau_gas2.info.name()]),action(){return!!ri($(this)[0])&&(t.tauceti.alien_station={count:0},hs(z("tau_gas2_alien_station_msg",[Re.tau_gas2.info.name()]),"info",!1,["progress"]),!0)}},alien_station:{id:"tauceti-alien_station",title:z("tau_gas2_alien_station"),desc:e=>!t.tauceti.hasOwnProperty("alien_station")||t.tauceti.alien_station.count<100||e?`
                ${z("tau_gas2_alien_station")}
                `+(t.tauceti.hasOwnProperty("alien_station")&&t.tauceti.alien_station.count>=100?`
                ${z("space_dwarf_reactor_desc_req")}
                `:`
                ${z("tau_gas2_alien_station_repair")}
                `):`
                ${z("tau_gas2_alien_station")}
                `,reqs:{tau_gas2:4},condition:()=>t.tauceti.alien_station.count<100,path:["truepath"],queue_size:5,queue_complete:()=>100-t.tauceti.alien_station.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?12e6:5e7:0,Aluminium:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?256e3:256e4:0,Polymer:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?198900:989e3:0,Mythril:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?Ve(125e3):0,Cipher:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?256:2001:0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0);return r<100?(a+=`
                ${z("tau_gas2_alien_station_repaired",[r])}
                `,a):Re.tau_gas2.alien_space_station.effect(e)},action(){return!!(ri($(this)[0])&&t.tauceti.alien_station.count<100)&&(t.tauceti.alien_station.count++,t.tauceti.alien_station.count>=100&&(t.tech.tau_gas2=5,t.tauceti.alien_space_station={count:1,on:0}),!0)},post(){t.resource.Elerium.diff>=10&&(t.tauceti.alien_space_station.on=1),Je()}},alien_space_station:{id:"tauceti-alien_space_station",title:z("tau_gas2_alien_station"),desc:()=>`
                ${z("tau_gas2_alien_station")}
                ${z("space_dwarf_reactor_desc_req")}
                `,reqs:{tau_gas2:5},path:["truepath"],cost:{},queue_complete:()=>0,special:()=>!(!t.tech.tau_gas2||6!==t.tech.tau_gas2||t.tech.alien_data&&!(t.tech.alien_data<6)),wiki:!1,effect(){let e=$(this)[0].p_fuel().a,a=`
                ${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
                `;if(t.tech.tau_gas2&&t.tech.tau_gas2>=6&&t.tauceti.alien_space_station.hasOwnProperty("decrypted")){let e=t.race.lone_survivor?1e5:25e6,r=+(t.tauceti.alien_space_station.decrypted/e).toFixed(2);r>100&&(r=100),a+=`
                ${z("tau_gas2_alien_station_effect",[r])}
                `}return a+=`
                ${z("spend",[e,t.resource[$(this)[0].p_fuel().r].name])}
                `,a},p_fuel:()=>({r:"Elerium",a:t.race.lone_survivor?1:10}),powered:()=>Fs(-75),action:()=>!1},matrioshka_brain:{id:"tauceti-matrioshka_brain",title:z("tech_matrioshka_brain"),desc:e=>!t.tauceti.hasOwnProperty("matrioshka_brain")||t.tauceti.matrioshka_brain.count<1e3||e?`
                ${z("tech_matrioshka_brain")}
                ${z("requires_segmemts",[1e3])}
                `:`
                ${z("tech_matrioshka_brain")}
                `,reqs:{tau_gas2:7},condition:()=>!!t.tauceti.matrioshka_brain,path:["truepath"],queue_size:50,queue_complete:()=>1e3-t.tauceti.matrioshka_brain.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?2e7:0,Neutronium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?45e3:0,Nano_Tube:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?16e4:0,Adamantite:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?666e3:0,Stanene:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?61600:0,Bolognium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?44e3:0,Unobtainium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?1200:0,Mythril:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?Ve(64e3):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0);return r<1e3&&(a+=`
                ${z("tau_gas2_matrioshka_brain_seg",[1e3-r])}
                `),a},action(){return!!(ri($(this)[0])&&t.tauceti.matrioshka_brain.count<1e3)&&(t.tauceti.matrioshka_brain.count++,t.tauceti.matrioshka_brain.count>=1e3&&(t.tech.m_brain=1),!0)}},ignition_device:{id:"tauceti-ignition_device",title:z("tech_ignition_device"),desc:e=>!t.tauceti.hasOwnProperty("ignition_device")||t.tauceti.ignition_device.count<10||e?`
                ${z("tech_ignition_device")}
                ${z("requires_segmemts",[10])}
                `:`
                ${z("tech_ignition_device")}
                `,reqs:{tau_gas2:8},condition:()=>!!(t.tauceti.ignition_device&&t.tauceti.ignition_device.count<10),path:["truepath"],queue_size:1,queue_complete:()=>10-t.tauceti.ignition_device.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?25e7:0,Uranium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?5e4:0,Elerium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?25e3:0,Graphene:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?225e5:0,Orichalcum:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?15e6:0,Quantium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?Ve(8e6):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0);return r<10&&(a+=`
                ${z("tau_gas2_ignition_device_seg",[10-r])}
                `),a},action(){return!!(ri($(this)[0])&&t.tauceti.ignition_device.count<10)&&(t.tauceti.ignition_device.count++,t.tauceti.ignition_device.count>=10&&(t.tech.m_ignite=1),!0)}},ignite_gas_giant:{id:"tauceti-ignite_gas_giant",title:()=>z("tau_gas2_ignite_gas_giant",[Re.tau_gas2.info.name()]),desc:()=>z("tau_gas2_ignite_gas_giant",[Re.tau_gas2.info.name()]),reqs:{tau_gas2:8,m_ignite:1},grant:["m_ignite",2],queue_size:1,queue_complete:()=>!1,path:["truepath"],cost:{Helium_3:()=>75e5},effect(){let e=`
                ${z("tau_gas2_ignite_gas_giant_effect",[z("tech_matrioshka_brain")])}
                `;return t.tech.m_brain?(e+=`
                ${z("tau_gas2_ignite_gas_giant_effect3")}
                `,e+=function(){let e=Gs("retire"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name"),r=t.stats.retire+1===t.stats.matrix?`
                ${z("tau_star_matrix_skilled",[1])}
                `:"";return`
                ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                ${z("tau_star_matrix_servants",[1])}
                ${r}`}()):e+=`
                ${z("tau_gas2_ignite_gas_giant_effect2",[z("tech_matrioshka_brain")])}
                `,e},action(){return!(!t.tech.m_brain||!ri($(this)[0])||(function(){P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"retire"});let a=t.race.species,r=t.race.gods,i=Ki[a].type,s=t.city.calendar.orbit,n=t.city.biome,c=t.city.ptrait,o=t.city.geology,l=Gs("retire");qn(`biome_${n}`),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),qn(`genus_${i}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),qn("retired"),U(),Sn(),t.stats.retire++,rn(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let _=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),_&&(t.race.srace=_),H({orbit:s,biome:n,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),0))}}}};for(let e=1;e<9;e++)Re.tau_gas[`gas_contest-a${e}`]={id:`tauceti-gas_contest-a${e}`,title:()=>Re.tau_gas.info.name(e),desc:()=>Re.tau_gas.info.name(e),reqs:{tau_gas:1},grant:["tau_gas",2],path:["truepath"],wiki:!1,queue_complete:()=>t.tech.tau_gas>=2?0:1,cost:{},effect:()=>z(8===e?"tau_gas_contest_reject":"tau_gas_contest_pick",[Re.tau_gas.info.name(e)]),action(){return!!ri($(this)[0])&&(t.race.gas_name=e,t.tauceti.refueling_station={count:0,on:0},!0)}},Re.tau_gas2[`gas_contest-b${e}`]={id:`tauceti-gas_contest-b${e}`,title:()=>Re.tau_gas2.info.name(e),desc:()=>Re.tau_gas2.info.name(e),reqs:{tau_gas2:2},grant:["tau_gas2",3],path:["truepath"],wiki:!1,queue_complete:()=>t.tech.tau_gas2>=3?0:1,cost:{},effect:()=>z(8===e?"tau_gas2_contest_reject":"tau_gas_contest_pick",[Re.tau_gas2.info.name(e)]),action(){return!!ri($(this)[0])&&(t.race.gas_name2=e,!0)}};function He(){let e=Gs("matrix"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name"),r=t.stats.retire===t.stats.matrix+1?`
                ${z("tau_star_matrix_skilled",[1])}
                `:"";return`
                ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                ${z("tau_star_matrix_servants",[1])}
                ${r}`}function Ue(){t.tauceti.overseer={count:0,on:0,pop:0,working:0,injured:0,morale:0,loyal:0,prod:0},t.tauceti.womling_village=t.race.lone_survivor?{count:2,on:2}:{count:1,on:1},t.tauceti.womling_mine=t.race.lone_survivor?{count:1,on:1,miners:0}:{count:0,on:0,miners:0},t.tauceti.womling_farm={count:1,on:1,farmers:0},t.tauceti.womling_fun={count:0,on:0}}function Ve(e){return t.tech.womling_tech&&t.tech.womling_recycling&&t.tech.womling_recycling>=1&&(e*=(t.tech.isolation?.97:.98)**t.tech.womling_tech),e}function We(){return Ne}function Qe(){return!!(t.tech.tauceti&&t.tech.tauceti>=4)}function Je(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||6!==t.settings.spaceTabs))return;let e=$("#tauceti");Ss(e),e.append($(`

                ${z("tab_tauceti")}

                `)),!t.tech.tauceti||t.tech.tauceti<2||Object.keys(Re).forEach((function(a){let r=a.replace("tau_","");if(t.settings.tau[`${r}`]){let r="string"==typeof Re[a].info.name?Re[a].info.name:Re[a].info.name(),i="";if(Re[a].info.hasOwnProperty("prop")&&(i=Re[a].info.prop()),Re[a].info.support){let s=Re[a].info.support;Re[a].info.hide_support?e.append(`

                ${r}

                ${i}
                `):e.append(`

                ${r}

                {{ support }}/{{ s_max }}${i}
                `),Cs({el:`#sr${a}`,data:t.tauceti[s],filters:{filter(){return Re[a].info.filter(...arguments)}}})}else e.append(`

                ${r}

                ${i}
                `);ls(a,(function(){return"string"==typeof Re[a].info.desc?Re[a].info.desc:Re[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(Re[a]).forEach((function(e){"info"!==e&&Tt(Re,a,e)&&Zr(Re[a][e],"tauceti",e)})),Re[a].info.hasOwnProperty("extra")&&Re[a].info.extra(a)}}))}function Ze(){if((t.settings.tabLoad||2===t.settings.civTabs&&5===t.settings.govTabs)&&(pt(),nt(),Ss($("#dwarfShipYard")),t.space.hasOwnProperty("shipyard")&&t.settings.showShipYard)){let e=$("#dwarfShipYard");t.space.shipyard.hasOwnProperty("blueprint")||(t.space.shipyard.blueprint={class:"corvette",armor:"steel",weapon:"railgun",engine:"ion",power:"diesel",sensor:"radar",name:Xe()});let a=$('
                ');e.append(a);let r=$('
                ');a.append(r),r.append(`
                ${z("outer_shipyard_registry")}:
                `),r.append(`
                ${z("crew")}
                `),r.append(`
                ${z("power")}
                `),r.append(`
                ${z("firepower")}
                `),r.append(`
                ${z("outer_shipyard_sensors")}
                `),r.append(`
                ${z("speed")}
                `),r.append(`
                ${z("outer_shipyard_fuel")}
                `),a.append('
                ');let i=$('
                ');a.append(i);let s={class:["corvette","frigate","destroyer","cruiser","battlecruiser","dreadnought","explorer"],power:["solar","diesel","fission","fusion","elerium"],weapon:["railgun","laser","p_laser","plasma","phaser","disruptor"],armor:["steel","alloy","neutronium"],engine:["ion","tie","pulse","photon","vacuum","emdrive"],sensor:["visual","radar","lidar","quantum"]};Object.keys(s).forEach((function(e){let t="";s[e].forEach((function(a,r){t+=`${z(`outer_shipyard_${e}_${a}`)}`})),i.append(`\n ${t}\n `)}));let n=$('
                ');n.append(``),n.append(`${z("outer_shipyard_fleet_details")}`),n.append(`${z("outer_shipyard_fleet_sort")}`),a.append(n),n.append(`
                ${z("outer_shipyard_park",[Ut().dwarf])}${z("outer_shipyard_map")}`),Ye();let c={template:''};Cs({el:"#shipPlans",data:{b:t.space.shipyard.blueprint,s:t.space.shipyard},methods:{setVal(e,a){"class"===e&&"explorer"===a?(t.space.shipyard.blueprint.engine="emdrive",t.space.shipyard.blueprint.weapon="railgun",t.tech.syard_armor>=3&&(t.space.shipyard.blueprint.armor="neutronium"),t.tech.syard_sensor>=4&&(t.space.shipyard.blueprint.sensor="quantum"),t.tech.syard_power>=4&&(t.space.shipyard.blueprint.power="elerium")):"class"===e&&"explorer"!==a&&"explorer"===t.space.shipyard.blueprint.class&&(t.space.shipyard.blueprint.engine="ion"),t.space.shipyard.blueprint[e]=a,Ye()},avail(e,a,r){if(!("class"!==e&&"engine"!==e||!t.tech.tauceti||"emdrive"!==r&&"explorer"!==r))return!0;if("explorer"===t.space.shipyard.blueprint.class){if("weapon"===e)return 1===a;if("engine"===e)return 6===a;if("sensor"===e)return 4===a}return t.tech[`syard_${e}`]>a},crewText:()=>et(t.space.shipyard.blueprint),powerText(){let e=tt(t.space.shipyard.blueprint);return e<0?`${e}kW`:`${e}kW`},fireText:()=>at(t.space.shipyard.blueprint),sensorText:()=>_t(t.space.shipyard.blueprint)+"km",speedText(){let e=7.695363719135802*rt(t.space.shipyard.blueprint);return Math.round(e)+"km/s"},fuelText(){let e=it(t.space.shipyard.blueprint);return e.res?`-${e.burn} ${t.resource[e.res].name}`:"N/A"},build(){if(tt(t.space.shipyard.blueprint)>=0){let e=st(t.space.shipyard.blueprint),a={};if(Object.keys(e).forEach((function(t){a[t]=function(){return e[t]}})),ri(!1,a)){let e=sn(t.space.shipyard.blueprint);e.location="spc_dwarf",e.xy=ut("spc_dwarf"),e.origin=sn(e.xy),e.destination=sn(e.xy),e.transit=0,e.dist=0,e.damage=0,e.fueled=!1,0===e.name.length&&(e.name=Xe());let a=1,r=e.name;for(;t.space.shipyard.ships.filter((e=>e.name===r)).length>0;)a++,r=e.name+` ${a}`;e.name=r,t.space.shipyard.ships.push(e),ct(),Ye(),t.space.shipyard.blueprint.name=Xe()}}},trigModal(){this.$buefy.modal.open({parent:this,component:c});let e=setInterval((function(){$("#modalBox").length>0&&(clearInterval(e),$("#modalBox").append($('

                Solar System

                ')),function(e){let t=$('
                ').appendTo(e),a={},r={},i=!1;yt={},ft=20,t.append($('').on("mouseup mouseover mouseout",(()=>i=!1)).on("mousedown",(e=>{i=!0,r.x=e.clientX-yt.x,r.y=e.clientY-yt.y})).on("mousemove",(e=>{i&&(yt.x=e.clientX-r.x,yt.y=e.clientY-r.y,bt())})).on("wheel",(e=>(e.originalEvent.deltaY<0?(ft/=.8,yt.x=a.x+(yt.x-a.x)/.8,yt.y=a.y+(yt.y-a.y)/.8,bt()):(ft*=.8,yt.x=a.x+.8*(yt.x-a.x),yt.y=a.y+.8*(yt.y-a.y),bt()),!1))),$('').on("click",(()=>{ft/=.8,yt.x=a.x+(yt.x-a.x)/.8,yt.y=a.y+(yt.y-a.y)/.8,bt()})),$('').on("click",(()=>{ft*=.8,yt.x=a.x+.8*(yt.x-a.x),yt.y=a.y+.8*(yt.y-a.y),bt()})));let s=document.getElementById("mapCanvas").getBoundingClientRect();a.x=s.width/2,a.y=s.height/2,yt.x=a.x,yt.y=a.y,bt()}($("#modalBox")))}),50)},redraw(){ct()}},filters:{lbl:(e,t)=>z(`outer_shipyard_${t}_${e}`)}}),Object.keys(s).forEach((function(e){for(let t=0;t<$(`#shipPlans .${e}`).length;t++)ls(`shipPlans${e}${t}`,(function(t){let a=$(t.this).attr("data-val");return z(`outer_shipyard_${e}_${a}_desc`)}),{elm:`#shipPlans .${e}.a${t}`,placement:"right"})})),e.append($('
                ')),ct()}}function Xe(){let e=["Trident","Spacewolf","Excalibur","Neptune","Deimos","Phobos","Enterprise","Intrepid","Daedalus","Odyssey","Endurance","Horizon","Hyperion","Icarus","Aurora","Axiom","Nemesis","Normandy","Orion","Prometheus","Vanguard","Discovery","Voyager","Defiant","Titan","Liberty","Destiny","Phoenix","Nautilus","Barracuda","Dolphin","Cuttlefish","Tiger Shark","Stingray","Swordfish","Triton","Dragon","Scorpion","Hagfish","Marlin","Galileo","Raven","Sarcophagus","Excelsior","Scimitar","Vengeance","Nomad","Nova","Olympus","Aegis","Agamemnon","Charon","Achilles","Apollo","Hermes","Hydra","Medusa","Talos","Zeus","Heracles","Cerberus","Acheron","Damocles","Juno","Persephone","Solaris","Victory","Hawk","Fury","Razor","Stinger","Outrider","Falcon","Vulture","Nirvana","Retribution","Swordbreaker","Valkyrie","Athena","Avalon","Merlin","Argonaut","Serenity","Gunstar","Ranger","Tantive","Cygnus","Nostromo","Reliant","Narcissus","Liberator","Sulaco","Infinity","Resolute","Wasp","Hornet","Independence","Gilgamesh","Midway","Concordia","Goliath","Cosmos","Express","Tigers Claw","Oberon","Minnow","Majestic","Spartacus","Colossi","Vigilant","Remorseless","Caelestis","Inquisitor","Atlas","Avenger","Dauntless","Nihilus","Thanatos","Stargazer","Xyzzy","Kraken","Xerxes","Spitfire","McShipFace","Monitor","Merrimack","Constitution","Ghost","Pequod","Arcadia","Corsair","Inferno","Jenny","Revenge","Red October","Jackdaw","Thorn","Caleuche","Valencia","Ourang","Deering","Baychimo","Octavius","Joyita","Lovibond","Celeste","Dutchman"],a=e[Math.rand(0,e.length)];return t.space.shipyard.ships.filter((e=>e.name===a)).length>0&&(a=function(){let e=["al","an","ar","as","at","ea","ed","en","er","es","ha","he","hi","in","is","it","le","me","nd","ne","ng","nt","on","or","ou","re","se","st","te","th","ti","to","ve","wa","all","and","are","but","ent","era","ere","eve","for","had","hat","hen","her","hin","his","ing","ion","ith","not","ome","oul","our","sho","ted","ter","tha","the","thi","tio","uld","ver","was","wit","you"],t=Math.rand(2,5),a="";for(let r=0;r${t.resource[a].name}${x(e[a])}`):$("#shipYardCosts").append(` | ${t.resource[a].name} ${x(e[a])}`)}))}function et(e){switch(e.class){case"corvette":return ta(2);case"frigate":return ta(3);case"destroyer":return ta(4);case"cruiser":return ta(6);case"battlecruiser":return ta(8);case"dreadnought":case"explorer":return ta(10)}}function tt(e,t){let a=0,r=1,i=1;switch(e.class){case"frigate":r=1.1,i=1.2;break;case"destroyer":r=1.5,i=1.65;break;case"cruiser":r=2,i=2.5;break;case"battlecruiser":r=2.5,i=3.5;break;case"dreadnought":r=5,i=6.5;break;case"explorer":r=6,i=2}switch(e.power){case"solar":a=Math.round(50*r);break;case"diesel":a=Math.round(100*r);break;case"fission":a=Math.round(150*r);break;case"fusion":a=Math.round(("explorer"===e.class||t?174:175)*r);break;case"elerium":a=Math.round(200*r)}switch(a=Math.round(Fs(a)),e.weapon){case"railgun":a-=Math.round(10*i);break;case"laser":a-=Math.round(30*i);break;case"p_laser":a-=Math.round(18*i);break;case"plasma":a-=Math.round(50*i);break;case"phaser":a-=Math.round(65*i);break;case"disruptor":a-=Math.round(100*i)}switch(e.engine){case"ion":a-=Math.round(25*i);break;case"tie":a-=Math.round(50*i);break;case"pulse":a-=Math.round(40*i);break;case"photon":a-=Math.round(75*i);break;case"vacuum":a-=Math.round(120*i);break;case"emdrive":a-=Math.round(("explorer"===e.class||t?515:1024)*i)}switch(e.sensor){case"radar":a-=Math.round(10*i);break;case"lidar":a-=Math.round(25*i);break;case"quantum":a-=Math.round(75*i)}return a}function at(e){let t=0;switch(e.weapon){case"railgun":t=36;break;case"laser":t=64;break;case"p_laser":t=54;break;case"plasma":t=90;break;case"phaser":t=114;break;case"disruptor":t=156}switch(e.class){case"corvette":return t;case"frigate":return Math.round(1.5*t);case"destroyer":return Math.round(2.75*t);case"cruiser":return Math.round(5.5*t);case"battlecruiser":return Math.round(10*t);case"dreadnought":return Math.round(22*t);case"explorer":return Math.round(1.2*t)}}function rt(e){let a=1;switch(e.class){case"corvette":a="neutronium"===e.armor?1.1:1;break;case"frigate":a="neutronium"===e.armor?1.35:1.25;break;case"destroyer":a="neutronium"===e.armor?1.95:1.8;break;case"cruiser":a="neutronium"===e.armor?3.5:3;break;case"battlecruiser":a="neutronium"===e.armor?4.8:4;break;case"dreadnought":a="neutronium"===e.armor?7.5:6;break;case"explorer":a=1}let r="spc_dwarf"===e.location&&s.m_relay&&0===e.transit&&t.space.m_relay&&t.space.m_relay.charged>=1e4?3:1;switch(e.engine){case"ion":return 12/a*r;case"tie":return 22/a*r;case"pulse":return 18/a*r;case"photon":return 30/a*r;case"vacuum":return 42/a*r;case"emdrive":return 37500/a*r}}function it(e){let t=!1,a=0;switch(e.power){case"diesel":t="Oil",a=8;break;case"fission":t="Uranium",a=.5;break;case"fusion":t="Helium_3",a=12;break;case"elerium":t="Elerium",a=1}switch(e.class){case"frigate":a*=1.25;break;case"destroyer":a*=1.5;break;case"cruiser":a*=2;break;case"battlecruiser":a*=3;break;case"dreadnought":a*=5;break;case"explorer":a*=25}return{res:t,burn:+a.toFixed(2)}}function st(e){let a={},r=1,i=1,s=1;switch(e.class){case"corvette":a.Money=25e5,a.Aluminium=5e5,r=1,i=1,s=2;break;case"frigate":a.Money=5e6,a.Aluminium=125e4,r=1.1,i=1.09,s=1.5;break;case"destroyer":a.Money=15e6,a.Aluminium=35e5,r=1.2,i=1.18,s=1.2;break;case"cruiser":a.Money=5e7,a.Adamantite=1e6,r=1.3,i=1.25;break;case"battlecruiser":a.Money=125e6,a.Adamantite=26e5,r=1.35,i=1.3,s=.8;break;case"dreadnought":a.Money=5e8,a.Adamantite=8e6,r=1.4,i=1.35,s=.5;break;case"explorer":a.Money=8e8,a.Adamantite=95e5,r=1.45,i=1}switch(e.armor){case"steel":a.Steel=Math.round(35e4**r);break;case"alloy":a.Alloy=Math.round(25e4**r);break;case"neutronium":a.Neutronium=Math.round(1e4**r)}switch(e.engine){case"ion":a.Titanium=Math.round(75e3**i);break;case"tie":a.Titanium=Math.round(15e4**i);break;case"pulse":a.Titanium=Math.round(125e3**i);break;case"photon":a.Titanium=Math.round(21e4**i);break;case"vacuum":a.Titanium=Math.round(3e5**i);break;case"emdrive":a.Titanium=Math.round(125e4**i)}let n=!!["dreadnought","explorer"].includes(e.class);switch(e.power){case"solar":case"diesel":a[n?"Orichalcum":"Copper"]=Math.round(4e4**r),a.Iridium=Math.round(15e3**i);break;case"fission":a[n?"Orichalcum":"Copper"]=Math.round(5e4**r),a.Iridium=Math.round(3e4**i);break;case"fusion":a[n?"Orichalcum":"Copper"]=Math.round(5e4**r),a.Iridium=Math.round(4e4**i);break;case"elerium":a[n?"Orichalcum":"Copper"]=Math.round(6e4**r),a.Iridium=Math.round(55e3**i)}if("explorer"!==e.class)switch(e.sensor){case"radar":a.Money=Math.round(a.Money**1.04);break;case"lidar":a.Money=Math.round(a.Money**1.08);break;case"quantum":a.Money=Math.round(a.Money**1.12)}switch(e.weapon){case"railgun":a.Iron=Math.round(25e3**r);break;case"laser":a.Iridium=Math.round(a.Iridium**1.05),a.Nano_Tube=Math.round(12e3**r);break;case"p_laser":a.Iridium=Math.round(a.Iridium**1.035),a.Nano_Tube=Math.round(12e3**r);break;case"plasma":a.Iridium=Math.round(a.Iridium**1.1),a.Nano_Tube=Math.round(2e4**r);break;case"phaser":a.Iridium=Math.round(a.Iridium**1.15),a.Quantium=Math.round(18e3**r);break;case"disruptor":a.Iridium=Math.round(a.Iridium**1.2),a.Quantium=Math.round(35e3**r)}"explorer"===e.class&&(a.Iron*=10,a.Titanium*=5,a.Iridium*=50);let c=0;t.space.shipyard.ships.forEach((function(t){t.class===e.class&&c++}));let o=1+(c-2)/25*s;return Object.keys(a).forEach((function(t){"explorer"===e.class?a[t]=Math.ceil(a[t]*(3*(c+1))):c<2?a[t]=Math.ceil(a[t]*(0===c?.75:.9)):c>2&&(a[t]=Math.ceil(a[t]*o))})),a}function nt(){let e=$("#shipList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}function ct(){if(nt(),Ss($("#shipList")),t.tech.isolation)return;let e=$("#shipList");if(t.space.shipyard.sort){let e={spc_dwarf:"a"};t.space.shipyard.ships=t.space.shipyard.ships.sort(((t,a)=>(e[t.location]?e[t.location]:t.location).localeCompare(e[a.location]?e[a.location]:a.location)))}const a=At();for(let r=0;r${e}`}}else Object.keys(a).forEach((function(e){if(i.location!==e&&(a[e].info.syndicate()||"spc_dwarf"===e)&&(!t.race.orbit_decayed||t.race.orbit_decayed&&"spc_moon"!==e)){let t="string"==typeof a[e].info.name?a[e].info.name:a[e].info.name();s+=`${t}`}}));let n="tauceti"===i.location?z("tech_era_tauceti"):"string"==typeof a[i.location].info.name?a[i.location].info.name:a[i.location].info.name(),c=`\n ${s}\n `;if(t.space.shipyard.expand){let t=`${z(`outer_shipyard_engine_${i.engine}`)} ${z(`outer_shipyard_class_${i.class}`)}`,a=$(`
                `),s=$(`
                ${i.name} | ${z("outer_shipyard_scrap")} | ${t} | ${z(`outer_shipyard_weapon_${i.weapon}`)} | ${z(`outer_shipyard_power_${i.power}`)} | ${z(`outer_shipyard_armor_${i.armor}`)} | ${z(`outer_shipyard_sensor_${i.sensor}`)}
                `),n=$('
                '),o=$('
                '),l=$(`
                ${c}
                `);n.append(`${z("crew")} `),n.append(`${z("firepower")} `),n.append(`${z("outer_shipyard_sensors")} `),n.append(`${z("speed")} `),n.append(`${z("outer_shipyard_fuel")} `),n.append(`${z("outer_shipyard_hull")} `),o.append(``),a.append(s),a.append(n),a.append(o),a.append(l),e.append(a)}else{let t=$(`
                `),a=$('
                '),s=$('
                '),n=$(`
                ${c}
                `);a.append(`${i.name} | `),a.append(`${z("firepower")} `),a.append(`${z("outer_shipyard_sensors")} `),a.append(`${z("speed")} `),a.append(`${z("outer_shipyard_fuel")} `),a.append(`${z("outer_shipyard_hull")} `),s.append(``),t.append(a),t.append(s),t.append(n),e.append(t)}Cs({el:`#shipReg${r}`,data:t.space.shipyard.ships[r],methods:{scrap(e){t.space.shipyard.ships[e]&&"spc_dwarf"===t.space.shipyard.ships[e].location&&(t.space.shipyard.ships.splice(e,1),ct(),Ye())},scrapAllowed:e=>!(!t.space.shipyard.ships[e]||"spc_dwarf"!==t.space.shipyard.ships[e].location),setLoc(e,a){let r=t.space.shipyard.ships[a];if(e!==r.location){let i=et(r),s=r.transit>0||"spc_dwarf"!==r.location;if(s||t.civic.garrison.workers-t.civic.garrison.crew>=i){let n=ot(r,e),c=ht(r.xy,n),o=rt(r);r.location=e,r.transit=Math.round(c/o),r.dist=Math.round(c/o),r.origin=sn(r.xy),r.destination={x:n.x,y:n.y},s||(t.civic.garrison.crew+=i),ct(),_s(`ship${a}loc${e}`)}}},crewText:e=>et(t.space.shipyard.ships[e]),fireText:e=>at(t.space.shipyard.ships[e]),sensorText:e=>_t(t.space.shipyard.ships[e])+"km",speedText(e){let a=7.695363719135802*rt(t.space.shipyard.ships[e]);return Math.round(a)+"km/s"},fuelText(e){let a=it(t.space.shipyard.ships[e]);return a.res?`${a.burn} ${t.resource[a.res].name}/s`:"N/A"},hullText:e=>100-t.space.shipyard.ships[e].damage+"%",hullDamage:e=>t.space.shipyard.ships[e].damage<=10?"has-text-success":t.space.shipyard.ships[e].damage>=40&&t.space.shipyard.ships[e].damage<65?"has-text-caution":t.space.shipyard.ships[e].damage>=65?"has-text-danger":"",dest(e){let r="explorer"===i.class?z("tech_era_tauceti"):"string"==typeof a[t.space.shipyard.ships[e].location].info.name?a[t.space.shipyard.ships[e].location].info.name:a[t.space.shipyard.ships[e].location].info.name();return z("outer_shipyard_arrive",[r,t.space.shipyard.ships[e].transit])},show:e=>t.space.shipyard.ships[e].transit>0}}),"explorer"===i.class?"tauceti"!==i.location&&ls(`ship${r}loctauceti`,(function(){return z("transit_time",[Math.round(ht(i.xy,ot(i,"tauceti"))/rt(i))])}),{elm:`#ship${r}loc .tauceti`,placement:"left"}):Object.keys(a).forEach((function(e){(a[e].info.syndicate()||"spc_dwarf"===e)&&i.location!==e&&ls(`ship${r}loc${e}`,(function(){return z("transit_time",[Math.round(ht(i.xy,ot(i,e))/rt(i))])}),{elm:`#ship${r}loc .${e}`,placement:"left"})}))}!function(){let e=$("#shipList")[0];Sortable.create(e,{onEnd(e){let a=t.space.shipyard.ships;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.space.shipyard.ships=a,ct()}})}()}function ot(e,a){if(-2===dt[a].orbit)return ut(a);let r=Math.sqrt((e.xy.x-vt(a))**2+e.xy.y**2),i=rt(e)/225,s=gt(1,a),n=Math.abs(r-dt[a].dist),c=Math.abs(r+dt[a].dist),o=Math.abs(r-dt[a].dist*s),l=Math.abs(r+dt[a].dist*s),_=Math.floor(Math.min(n,o,c,l)/i),d=Math.ceil(Math.max(n,o,c,l)/i);r>=dt[a].dist&&r<=dt[a].dist*s&&(_=0);let p=360/(-1===dt[a].orbit?t.city.calendar.orbit:dt[a].orbit),u=(t.space.position[a]+_*p)%360,h=Math.PI/180;for(let t=_;t<=d;t++){let r=gt(Math.cos(u*h)*dt[a].dist,a);r+=vt(a);let s=Math.sin(u*h)*dt[a].dist;if(Math.sqrt((r-e.xy.x)**2+(s-e.xy.y)**2)/i<=t)return{x:r,y:s};u=(u+p)%360}return ut(a)}function lt(e,a){if(!t.tech.isolation&&t.tech.syndicate&&t.race.truepath&&t.space.syndicate&&t.space.syndicate.hasOwnProperty(e)){let r=1e3,i=0;switch(t.civic.foreign.gov3.hstl<10?i=250-25*t.civic.foreign.gov3.hstl:t.civic.foreign.gov3.hstl>60&&(i=-13*(t.civic.foreign.gov3.hstl-60)),e){case"spc_home":case"spc_moon":case"spc_red":case"spc_hell":r=1250+i;break;case"spc_gas":case"spc_gas_moon":case"spc_belt":r=1020+i;break;case"spc_titan":case"spc_enceladus":case"spc_triton":case"spc_kuiper":case"spc_eris":r=Mr.space[e].info.syndicate_cap()}let c=t.space.syndicate[e],o=0,l=0,_=0;if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){if(t.space.shipyard.ships.forEach((function(t){if(t.location===e&&0===t.transit&&t.fueled){let e=at(t);o+=t.damage>0?Math.round(e*(100-t.damage)/100):e,l+=_t(t)}})),"spc_enceladus"===e&&Math.min(n.operating_base,s.operating_base)>0){let e=Math.min(n.operating_base,s.operating_base);o+=50*e}else"spc_titan"===e&&s.sam>0?o+=25*s.sam:"spc_triton"===e&&s.fob>0&&(o+=500,l+=10);l>100&&(l=Math.round((l-100)/(l-100+200)*100)+100),o=Math.round(o*((l+25)/125)),o>c&&(_=o-c),c=c-o>0?c-o:0}return a?{p:1-+(c/r).toFixed(4),r:c,s:l,o:_}:1-+(c/r).toFixed(4)}return a?{p:1,r:0,s:0,o:0}:1}function _t(e){let t=1;switch(e.class){case"corvette":case"frigate":t=2;break;case"destroyer":case"cruiser":t=1.5;break;case"explorer":t=5;break;default:t=1}switch(e.sensor){case"visual":return 1;case"radar":return 10*t;case"lidar":return 18*t;case"quantum":return 32*t}}const dt={spc_sun:{dist:0,orbit:0,size:2},spc_home:{dist:1,orbit:-1,size:.6},spc_moon:{dist:1.01,orbit:-1,size:.1,moon:!0},spc_red:{dist:1.524,orbit:687,size:.5},spc_hell:{dist:.4,orbit:88,size:.4},spc_venus:{dist:.7,orbit:225,size:.5},spc_gas:{dist:5.203,orbit:4330,size:1.25},spc_gas_moon:{dist:5.204,orbit:4330,size:.2,moon:!0},spc_belt:{dist:2.7,orbit:1642,size:.5,belt:!0},spc_dwarf:{dist:2.77,orbit:1682,size:.5},spc_saturn:{dist:9.539,orbit:10751,size:1.1},spc_titan:{dist:9.536,orbit:10751,size:.2,moon:!0},spc_enceladus:{dist:9.542,orbit:10751,size:.1,moon:!0},spc_uranus:{dist:19.8,orbit:30660,size:1},spc_neptune:{dist:30.08,orbit:60152,size:1},spc_triton:{dist:30.1,orbit:60152,size:.1,moon:!0},spc_kuiper:{dist:39.5,orbit:90498,size:.5,belt:!0},spc_eris:{dist:68,orbit:204060,size:.5,size:.5},tauceti:{dist:752568.8,orbit:-2,size:2}};function pt(){t.space.position||(t.space.position={}),Object.keys(dt).forEach((function(e){t.space.position.hasOwnProperty(e)||(t.space.position[e]=Math.rand(0,360))})),t.space.position.spc_home=t.space.position.spc_moon,t.space.position.spc_gas_moon=t.space.position.spc_gas,t.space.position.spc_titan=t.space.position.spc_enceladus,t.space.position.spc_saturn=t.space.position.spc_titan,t.space.position.spc_neptune=t.space.position.spc_triton}function ut(e){let a=gt(+Math.cos(t.space.position[e]*(Math.PI/180)).toFixed(5)*dt[e].dist,e),r=+Math.sin(t.space.position[e]*(Math.PI/180)).toFixed(5)*dt[e].dist;return a+=vt(e),{x:a,y:r}}function ht(e,t){return Math.ceil(225*Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2))}function mt(e,a){let r=1;switch(t.race.pack_rat&&(r*=1+Ei.pack_rat.vars()[1]/100),t.stats.achieve.blackhole&&(r*=1+.05*t.stats.achieve.blackhole.l),t.tech.world_control&&(r*=3),e){case"storehouse":s.titan_spaceport&&(r*=1+.25*s.titan_spaceport),a&&t.tech.shelving&&(r*=2),t.tech.shelving&&t.tech.shelving>=3&&(r*=1.5);case"repository":t.tech.isolation&&(r*=3,t.tech.tp_depot&&(r*=1+t.tech.tp_depot/20))}return r}function gt(e,a){if(-2!==dt[a].orbit){let r=1.075+dt[a].dist/100;t.city.ptrait.includes("elliptical")&&(r="spc_home"===a?1.5:1.275+dt[a].dist/100),e*=r}return e}function vt(e){if(-2!==dt[e].orbit){let a=dt[e].dist/3;return t.city.ptrait.includes("elliptical")&&"spc_home"===e&&(a+=.15),"spc_eris"===e&&(a+=25),a}return 0}var ft,yt;function bt(){let e=document.getElementById("mapCanvas"),a=e.getContext("2d");e.width=e.getBoundingClientRect().width,e.height=e.getBoundingClientRect().height,a.save(),a.fillStyle="#000000",a.fillRect(0,0,e.width,e.height),a.translate(yt.x,yt.y),a.scale(ft,ft);let r={};for(let[e,t]of Object.entries(dt))r[e]=ut(e);a.lineWidth=1/ft,a.strokeStyle="#c0c0c0";for(let[e,r]of Object.entries(dt))if(!r.moon&&-2!==r.orbit){a.beginPath(),r.belt||t.race.orbit_decayed&&"spc_home"===e?a.setLineDash([.01,.01]):a.setLineDash([]);let i=vt(e);a.ellipse(i,0,gt(r.dist,e),r.dist,0,0,2*Math.PI,!0),a.stroke()}a.fillStyle="#0000ff",a.strokeStyle="#0000ff";for(let e of t.space.shipyard.ships)e.transit>0&&(a.beginPath(),a.setLineDash([.1,.4]),a.moveTo(e.xy.x,e.xy.y),a.lineTo(e.destination.x,e.destination.y),a.stroke());for(let[e,i]of Object.entries(dt)){if(t.race.orbit_decayed&&["spc_home","spc_moon"].includes(e))continue;let s="558888";if(Mr.space[e]&&Mr.space[e].info.syndicate()&&t.settings.space[e.substring(4)]){let t=lt(e);s=((Math.round(255*(1-t))<<16)+(Math.round(255*t)<<8)).toString(16).padStart(6,0)}"spc_dwarf"===e?s="7132a8":"spc_sun"!==e&&"tauceti"!==e||(s="f8ff2b"),a.fillStyle="#"+s,a.beginPath();let n=i.size/10;if(i.moon)switch(e){case"spc_moon":a.arc(r[e].x+.05,r[e].y+.05,n,0,2*Math.PI,!0);break;case"spc_titan":a.arc(r[e].x-.2,r[e].y-.2,n,0,2*Math.PI,!0);break;default:a.arc(r[e].x+.2,r[e].y+.2,n,0,2*Math.PI,!0)}else{let t=i.size/10;a.arc(r[e].x,r[e].y,t,0,2*Math.PI,!0)}a.fill()}a.fillStyle="#0000ff",a.strokeStyle="#0000ff";for(let e of t.space.shipyard.ships)e.transit>0&&(a.beginPath(),a.arc(e.xy.x,e.xy.y,.1,0,2*Math.PI,!0),a.fill());a.shadowOffsetX=2,a.shadowOffsetY=2,a.shadowBlur=2,a.shadowColor="rgba(0, 0, 0, 0.5)",a.fillStyle="#009aff",a.font=20/ft+"px serif";for(let e of t.space.shipyard.ships)e.transit>0&&a.fillText(e.name,e.xy.x+.15,e.xy.y-.15);a.fillStyle="#ffa500",a.font=25/ft+"px serif";for(let[e,i]of Object.entries(dt))if(Mr.space[e]&&t.settings.space[e.substring(4)]){if(t.race.orbit_decayed&&["spc_home"].includes(e))continue;let s=Mr.space[e].info.name,n="function"==typeof s?s():s;if(i.moon)switch(e){case"spc_moon":a.fillText(n,r[e].x+.1,r[e].y+.1);break;case"spc_titan":a.fillText(n,r[e].x-.3,r[e].y-.3);break;default:a.fillText(n,r[e].x+.25,r[e].y+.2)}else"spc_sun"===e||a.fillText(n,r[e].x,r[e].y-.2*i.size)}a.restore()}function wt(e){switch(e){case"city":return t.resource[t.race.species]?t.resource[t.race.species].amount<=5?z("tab_city1"):t.resource[t.race.species].amount<=20?z("tab_city2"):t.resource[t.race.species].amount<=75?z("tab_city3"):t.resource[t.race.species].amount<=250?z("tab_city4"):t.resource[t.race.species].amount<=600?z("tab_city5"):t.resource[t.race.species].amount<=1200?z("tab_city6"):t.resource[t.race.species].amount<=2500?z("tab_city7"):z("tab_city8"):z("tab_city1");case"local_space":return z("sol_system",[t.race.truepath?Ki[t.race.species].home:nn("name")]);case"outer_local_space":return z("outer_sol_system",[t.race.truepath?Ki[t.race.species].home:nn("name")]);case"old":return z("tab_old_res");case"new":return z("tab_new_res");case"old_sr":return z("tab_old_sr_res");case"new_sr":return z("tab_new_sr_res");default:return z(e)}}function kt(e){switch(t.settings.tabLoad?ks("page_view",{page_title:"Evolve - All Tabs"}):(fi(),Ci(),wa(),Le(),E(),nt(),Ss($("#mTabCivil")),Ss($("#mTabCivic")),Ss($("#mTabResearch")),Ss($("#mTabResource")),Ss($("#mTabArpa")),Ss($("#mTabStats")),Ss($("#mTabObserve"))),e){case 0:t.settings.tabLoad||(ks("page_view",{page_title:"Evolve - Evolution"}),Tr());break;case 1:case"mTabCivil":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Civilization"}),$("#mTabCivil").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),Cs({el:"#mTabCivil",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(Ss($("#city")),Ss($("#space")),Ss($("#interstellar")),Ss($("#galaxy")),Ss($("#portal")),Ss($("#outerSol")),Ss($("#tauCeti")),e){case 0:Wr();break;case 1:case 2:case 3:case 5:Lt();break;case 4:ua();break;case 6:Je()}return e}},filters:{label:e=>wt(e)}}),"protoplasm"!==t.race.species&&(Wr(),Lt(),ua(),Je()),t.race.noexport&&("Race"===t.race.noexport?(Ss($("#city")),Qt()):"Planet"===t.race.noexport&&(Ss($("#city")),Jt()));break;case 2:case"mTabCivic":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Civics"}),$("#mTabCivic").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),Cs({el:"#mTabCivic",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(Ci(),E(),wa(),nt(),Ss($("#civic")),Ss($("#industry")),Ss($("#powerGrid")),Ss($("#military")),Ss($("#mechLab")),Ss($("#dwarfShipYard")),Ss($("#psychicPowers")),e){case 0:$("#civic").append($('
                ')),Yt(),$("#civics").append($('
                ')),V(),"protoplasm"===t.race.species||t.race.start_cataclysm||(Q(),he($("#c_garrison"),!1),te()),t.race.shapeshifter&&Yi(!1,!0);break;case 1:ki();break;case 2:Object.keys(Si()).forEach((function(e){us(e)})),Mi();break;case 3:"protoplasm"===t.race.species||t.race.start_cataclysm||(W(),ma($("#fortress"),!1));break;case 4:"protoplasm"===t.race.species||t.race.start_cataclysm||ya();break;case 5:t.race.truepath&&"protoplasm"!==t.race.species&&!t.race.start_cataclysm&&Ze();break;case 6:t.race.psychic&&t.tech.psychic&&"protoplasm"!==t.race.species&&cs()}return e}},filters:{label:e=>wt(e)}}),Object.keys(Si()).forEach((function(e){us(e)})),Mi(),$("#civic").append($('
                ')),Yt(),$("#civics").append($('
                ')),V(),"protoplasm"===t.race.species||t.race.start_cataclysm||(W(),he($("#c_garrison"),!1),ma($("#fortress"),!1),te(),ya(),t.race.truepath&&Ze(),t.race.psychic&&t.tech.psychic&&cs()),t.race.shapeshifter&&Yi(!1,!0),ki();break;case 3:case"mTabResearch":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Research"}),$("#mTabResearch").append('
                \n \n \n \n \n \n \n \n '),Cs({el:"#mTabResearch",data:{s:t.settings,rq:t.r_queue},filters:{label:e=>wt(e)}}),vi(),"protoplasm"!==t.race.species&&Qr();break;case 4:case"mTabResource":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Resources"}),$("#mTabResource").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),Cs({el:"#mTabResource",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(Ss($("#market")),Ss($("#resStorage")),Ss($("#resEjector")),Ss($("#resCargo")),Ss($("#resAlchemy")),e){case 0:Ka("market");break;case 1:Ka("storage");break;case 2:Ka("ejector");break;case 3:Ka("supply");break;case 4:Ka("alchemy")}return e}},filters:{label:e=>wt(e)}}),Ea(),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let r=a.resource[e].color,i=a.resource[e].tradable;if(a.resource[e].stackable){var s=$(`
                `);$("#resStorage").append(s),er(`#stack-${e}`,s,e,r)}i&&(s=$(`
                `),$("#market").append(s),Va(`#market-${e}`,s,e,r,!0)),Fa[e]&&mr(e,r),Aa[e]&&vr(e,r),za[e]&&"magic"===t.race.universe&&(t.resource[e].basic=i,yr(e,r,i))})),Ba();break;case 5:case"mTabArpa":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Arpa"}),$("#mTabArpa").append(`
                \n \n \n \n \n \n \n
                `),Cs({el:"#mTabArpa",data:{s:t.settings},filters:{label:e=>wt(e)}}),xe("Physics"),xe("Genetics"),xe("Crispr"),xe("Blood");break;case 6:case"mTabStats":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Stats"}),$("#mTabStats").append('\n \n \n \n \n \n \n \n \n \n '),Cs({el:"#mTabStats",data:{s:t.settings},filters:{label:e=>wt(e)}}),function(){Ss($("#achieve")),Ss($("#stats"));let e=$('
                ');$("#stats").append(e);let a=$('
                ');$("#perks").append(a);let r=$('
                ');$("#achieve").append(r),function(){Ss($("#statsPanel"));let e=$("#statsPanel");if(e.append(`
                ${z("achieve_stats_overall")}
                `),e.append(`
                ${z("achieve_stats_plasmid_earned")} {{ s.plasmid | format }}
                `),t.stats.antiplasmid>0&&e.append(`
                ${z("achieve_stats_antiplasmid_earned")} {{ s.antiplasmid | format }}
                `),t.stats.phage>0&&e.append(`
                ${z("achieve_stats_phage_earned")} {{ s.phage | format }}
                `),t.stats.dark>0&&e.append(`
                ${z("achieve_stats_dark_earned")} {{ s.dark | format }}
                `),t.stats.harmony>0&&e.append(`
                ${z("achieve_stats_harmony_earned")} {{ s.harmony | format }}
                `),t.stats.blood>0&&e.append(`
                ${z("achieve_stats_blood_earned")} {{ s.blood | format }}
                `),t.stats.artifact>0&&e.append(`
                ${z("achieve_stats_artifact_earned")} {{ s.artifact | format }}
                `),e.append(`
                ${z("achieve_stats_knowledge_spent")} {{ s.know | t_know | format }}
                `),e.append(`
                ${z("achieve_stats_starved_to_death")} {{ s.starved | t_starved | format }}
                `),e.append(`
                ${z("achieve_stats_died_in_combat")} {{ s.died | t_died | format }}
                `),e.append(`
                ${z("achieve_stats_game_days_played")} {{ s.days | played | format }}
                `),t.stats.portals>0&&e.append(`
                ${z("achieve_stats_portals")} {{ s.portals | format }}
                `),e.append(`
                ${z("achieve_stats_total_resets")} {{ s.reset | format }}
                `),t.stats.mad>0&&e.append(`
                ${z("achieve_stats_mad_resets")} {{ s.mad | format }}
                `),t.stats.bioseed>0&&e.append(`
                ${z("achieve_stats_bioseed_resets")} {{ s.bioseed | format }}
                `),t.stats.cataclysm>0&&e.append(`
                ${z("achieve_stats_cataclysm_resets")} {{ s.cataclysm | format }}
                `),t.stats.blackhole>0&&e.append(`
                ${z("achieve_stats_blackhole_resets")} {{ s.blackhole | format }}
                `),t.stats.ascend>0&&e.append(`
                ${z("achieve_stats_ascension_resets")} {{ s.ascend | format }}
                `),t.stats.descend>0&&e.append(`
                ${z("achieve_stats_descension_resets")} {{ s.descend | format }}
                `),t.stats.aiappoc>0&&e.append(`
                ${z("achieve_stats_aiappoc_resets")} {{ s.aiappoc | format }}
                `),t.stats.matrix>0&&e.append(`
                ${z("achieve_stats_matrix_resets")} {{ s.matrix | format }}
                `),t.stats.retire>0&&e.append(`
                ${z("achieve_stats_retire_resets")} {{ s.retire | format }}
                `),t.stats.eden>0&&e.append(`
                ${z("achieve_stats_eden_resets")} {{ s.eden | format }}
                `),t.stats.terraform>0&&e.append(`
                ${z("achieve_stats_terraform_resets")} {{ s.terraform | format }}
                `),t.stats.geck>0&&e.append(`
                ${z("achieve_stats_gecks")} {{ s.geck | format }}
                `),e.append(`
                ${z("achieve_stats_current_game")}
                `),e.append(`
                ${z("achieve_stats_knowledge_spent")} {{ s.know | format }}
                `),e.append(`
                ${z("achieve_stats_starved_to_death")} {{ s.starved | format }}
                `),e.append(`
                ${z("achieve_stats_died_in_combat")} {{ s.died | format }}
                `),e.append(`
                ${z("achieve_stats_attacks_made")} {{ s.attacks | format }}
                `),e.append(`
                ${z("achieve_stats_game_days_played")} {{ s.days | format }}
                `),t.stats.dkills>0&&e.append(`
                ${z("achieve_stats_demons_kills")} {{ s.dkills | format }}
                `),t.stats.sac>0&&e.append(`
                ${z("achieve_stats_sacrificed")} {{ s.sac | format }}
                `),t.stats.murders>0&&e.append(`
                ${z("achieve_stats_murders")} {{ s.murders | format }}
                `),t.stats.psykill>0&&e.append(`
                ${z("achieve_stats_psymurders")} {{ s.psykill | format }}
                `),t.resource.hasOwnProperty("Thermite")&&t.resource.Thermite.amount>0&&e.append(`
                ${z("achieve_stats_thermite")} {{ r.Thermite.amount | res }}
                `),ln().active){let a="";(t.stats.cfood>=13||t.race.cataclysm||t.race.orbit_decayed)&&(a=`${Js(7,12,!0)}`),e.append(`
                ${z("achieve_stats_trickortreat")} {{ s.cfood | format }} ${a}
                `)}Cs({el:"#statsPanel",data:{s:t.stats,r:t.resource},filters:{played:e=>e+t.stats.tdays,t_know:e=>e+t.stats.tknow,t_starved:e=>e+t.stats.tstarved,t_died:e=>e+t.stats.tdied,format:e=>e.toLocaleString(),res:e=>(+e.toFixed(2)).toLocaleString()}})}(),An(),$("body").hasClass("fool")?jn({fool:!0}):jn()}();break;case 7:t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Settings"});break;default:t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Hell Observation"}),t.portal.observe&&Pa(!0)}$("#popper").length>0&&0===$(`#${$("#popper").data("id")}`).length&&_s()}const $t={spc_home:{info:{name:()=>Ki[t.race.species].home,desc:z("space_home_info_desc"),zone:"inner",syndicate:()=>!1},test_launch:{id:"space-test_launch",title:z("space_home_test_launch_title"),desc:z("space_home_test_launch_desc"),reqs:{space:1},grant:["space",2],queue_complete:()=>t.tech.space>=2?0:1,cost:{Money:()=>1e5,Oil:(e,t)=>Rt(7500,!1,t)},effect:z("space_home_test_launch_effect"),action(){if(ri($(this)[0])){if(t.race.truepath){let e=1;if(ce("gov0")||e++,ce("gov1")||e++,ce("gov2")||e++,0!==Math.floor(m(0,e)))return hs(z("space_home_test_launch_action_fail"),"danger",!1,["progress"]),0}return t.space.satellite={count:0},hs(z("space_home_test_launch_action"),"info",!1,["progress"]),!0}return!1}},satellite:{id:"space-satellite",title:z("space_home_satellite_title"),desc:z("space_home_satellite_desc"),reqs:{space:2},cost:{Money:e=>Ps("satellite",e,72e3,1.22),Knowledge:e=>Ps("satellite",e,28e3,1.22),Oil:(e,t)=>Ps("satellite",e,Rt(3200,!1,t),1.22),Alloy:e=>Ps("satellite",e,8e3,1.22)},effect(){let e=t.race.cataclysm||t.race.orbit_decayed?2e3:750;if((t.race.cataclysm||t.race.orbit_decayed)&&t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?5:10;e*=t.tech.supercollider/a+1}let a=t.race.cataclysm?z("space_moon_observatory_title"):t.race.orbit_decayed?z("city_university"):_i(),r=`
                ${z("space_home_satellite_effect2",[a,t.race.cataclysm?25:t.race.orbit_decayed?12:4])}
                `;return`
                ${z("plus_max_resource",[e,z("resource_Knowledge_name")])}
                ${r}
                ${z("space_home_satellite_effect3",[t.civic.scientist?t.civic.scientist.name:z("job_scientist")])}
                `},action(){return!!ri($(this)[0])&&(Ft("satellite"),t.resource.Knowledge.max+=750,!0)}},gps:{id:"space-gps",title:z("space_home_gps_title"),desc:()=>t.space.hasOwnProperty("gps")&&t.space.gps.count<4?`
                ${z("space_home_gps_desc")}
                ${z("space_home_gps_desc_req")}
                `:`
                ${z("space_home_gps_desc")}
                `,reqs:{satellite:1},not_trait:["terrifying"],cost:{Money:e=>Ps("gps",e,75e3,1.18),Knowledge:e=>Ps("gps",e,5e4,1.18),Copper:e=>Ps("gps",e,6500,1.18),Oil:(e,t)=>Ps("gps",e,Rt(3500,!1,t),1.18),Titanium:e=>Ps("gps",e,8e3,1.18)},effect:e=>(e||0)+(t.space.hasOwnProperty("gps")?t.space.gps.count:0)<4?z("space_home_gps_effect_req"):`
                ${z("space_home_gps_effect")}
                ${z("space_home_gps_effect2",[2])}
                `,action(){return!!ri($(this)[0])&&(Ft("gps"),!0)}},propellant_depot:{id:"space-propellant_depot",title:z("space_home_propellant_depot_title"),desc:z("space_home_propellant_depot_desc"),reqs:{space_explore:1},cost:{Money:e=>Ps("propellant_depot",e,55e3,1.35),Aluminium:e=>Ps("propellant_depot",e,22e3,1.35),Oil:(e,t)=>Ps("propellant_depot",e,Rt(5500,!1,t),1.35)},effect(){let e=br(1250)*(t.tech.world_control?1.5:1);if(t.resource.Helium_3.display){let a=br(1e3)*(t.tech.world_control?1.5:1);return`
                ${z("plus_max_resource",[e,z("resource_Oil_name")])}
                ${z("plus_max_resource",[a,z("resource_Helium_3_name")])}
                `}return`
                ${z("plus_max_resource",[e,z("resource_Oil_name")])}
                `},action(){return!!ri($(this)[0])&&(Ft("propellant_depot"),t.resource.Oil.max+=br(1250)*(t.tech.world_control?1.5:1),t.resource.Helium_3.display&&(t.resource.Helium_3.max+=br(1e3)*(t.tech.world_control?1.5:1)),!0)}},nav_beacon:{id:"space-nav_beacon",title:()=>t.race.orbit_decayed?z("space_home_broadcast_beacon_title"):z("space_home_nav_beacon_title"),desc:`
                ${z("space_home_nav_beacon_desc")}
                ${z("requires_power")}
                `,reqs:{luna:2},cost:{Money:e=>Ps("nav_beacon",e,75e3,1.32),Copper:e=>Ps("nav_beacon",e,38e3,1.32),Aluminium:e=>Ps("nav_beacon",e,44e3,1.32),Oil:(e,t)=>Ps("nav_beacon",e,Rt(12500,!1,t),1.32),Iridium:e=>Ps("nav_beacon",e,1200,1.32)},powered:()=>As(2),powerBalancer:()=>t.tech.luna&&t.tech.luna>=3?[{s:t.space.moon_base.s_max-t.space.moon_base.support},{s:t.space.spaceport.s_max-t.space.spaceport.support}]:[{s:t.space.moon_base.s_max-t.space.moon_base.support}],support:()=>1,effect(){let e="";return t.race.orbit_decayed&&t.tech.broadcast&&(e=`
                ${z("space_red_vr_center_effect1",[t.tech.broadcast/2])}
                `),`${t.race.orbit_decayed?"":`
                ${z("space_home_nav_beacon_effect1")}
                `}${t.tech.luna>=3?`
                ${z("space_red_spaceport_effect1",[Ut().red,1])}
                `:""}${e}
                ${z("space_home_nav_beacon_effect2",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("nav_beacon"),Yr($(this)[0]),!0)}}},spc_moon:{info:{name:z("space_moon_info_name"),desc:()=>z("space_moon_info_desc",[Ki[t.race.species].home]),support:"moon_base",zone:"inner",syndicate:()=>!0},moon_mission:{id:"space-moon_mission",title:z("space_moon_mission_title"),desc:z("space_moon_mission_desc"),reqs:{space:2,space_explore:2},grant:["space",3],queue_complete:()=>t.tech.space>=3?0:1,cost:{Oil:(e,t)=>+Rt(12e3,!1,t).toFixed(0)},effect:z("space_moon_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("space_moon_mission_action"),"info",!1,["progress"]),t.space.iridium_mine={count:0,on:0},t.space.helium_mine={count:0,on:0},!0)}},moon_base:{id:"space-moon_base",title:z("space_moon_base_title"),desc:()=>`
                ${z("space_moon_base_desc")}
                ${z("requires_power_combo",[t.resource.Oil.name])}
                `,reqs:{space:3},cost:{Money:e=>Ps("moon_base",e,22e3,1.32),Cement:e=>Ps("moon_base",e,18e3,1.32),Alloy:e=>Ps("moon_base",e,7800,1.32),Polymer:e=>Ps("moon_base",e,12500,1.32)},effect(e){let t=br(500),a=+Rt($(this)[0].support_fuel().a,!0,e).toFixed(2);return`
                ${z("space_moon_base_effect1")}
                ${z("plus_max_resource",[t,z("resource_Iridium_name")])}
                ${z("space_moon_base_effect3",[a,$(this)[0].powered()])}
                `},support:()=>2,support_fuel:()=>({r:"Oil",a:2}),powered:()=>As(4),powerBalancer:()=>[{s:t.space.moon_base.s_max-t.space.moon_base.support}],refresh:!0,action(){if(ri($(this)[0])){if(Ft("moon_base"),Yr($(this)[0]),1===t.space.moon_base.count&&(t.tech.moon=1),!t.tech.luna&&(t.tech.luna=1,t.race.truepath)){let e=z("space_moon_base_msg",[Z(3)]);t.civic.foreign.gov3.hstl<10?e=`${e} ${z("space_moon_base_msg_ally")}`:t.civic.foreign.gov3.hstl>60&&(e=`${e} ${z("space_moon_base_msg_hstl")}`),hs(e,"info",!1,["progress"])}return t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+2500&&(t.race.orbit_decay=t.stats.days+2500,hs(z("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0}return!1}},iridium_mine:{id:"space-iridium_mine",title:z("space_moon_iridium_mine_title"),desc:`
                ${z("space_moon_iridium_mine_desc")}
                ${z("space_support",[z("space_moon_info_name")])}
                `,reqs:{space:3,luna:1},cost:{Money:e=>Ps("iridium_mine",e,42e3,1.35),Lumber:e=>Ps("iridium_mine",e,9e3,1.35),Titanium:e=>Ps("iridium_mine",e,17500,1.35)},effect(){let e=$e("iridium_mine","iridium"),a=+e.b.toFixed(3),r="";t.race.truepath&&(t.civic.foreign.gov3.hstl<10?r=`
                ${z("space_rival_ally",[+(100*e.g).toFixed(1)])}
                `:t.civic.foreign.gov3.hstl>60&&(r=`
                ${z("space_rival_war",[+(100*e.g).toFixed(1)])}
                `));let i=t.race.cataclysm?`
                ${z("produce",[+$e("iridium_mine","coal").toFixed(2),t.resource.Coal.name])}
                `:"",s=t.race.cataclysm?`
                ${z("produce",[+($e("iridium_mine","coal")/48).toFixed(3),t.resource.Uranium.name])}
                `:"";return`
                ${z("space_used_support",[z("space_moon_info_name")])}
                ${z("space_moon_iridium_mine_effect",[a])}
                ${r}${i}${s}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.resource.Iridium.display=!0,Ft("iridium_mine"),t.resource.Mythril.display||(t.resource.Mythril.display=!0,sa()),t.space.moon_base.support${z("space_moon_helium_mine_desc")}
                ${z("space_support",[z("space_moon_info_name")])}
                `,reqs:{space:3,luna:1},cost:{Money:e=>Ps("helium_mine",e,38e3,1.35),Aluminium:e=>Ps("helium_mine",e,9e3,1.35),Steel:e=>Ps("helium_mine",e,17500,1.35)},effect(){let e=br(100),a=$e("helium_mine"),r=+a.b.toFixed(3),i="";return t.race.truepath&&(t.civic.foreign.gov3.hstl<10?i=`
                ${z("space_rival_ally",[+(100*a.g).toFixed(1)])}
                `:t.civic.foreign.gov3.hstl>60&&(i=`
                ${z("space_rival_war",[+(100*a.g).toFixed(1)])}
                `)),`
                ${z("space_used_support",[z("space_moon_info_name")])}
                ${z("space_moon_helium_mine_effect",[r])}
                ${i}
                ${z("plus_max_resource",[e,z("resource_Helium_3_name")])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.resource.Helium_3.display=!0,Ft("helium_mine"),t.space.moon_base.support${z("space_moon_observatory_desc")}
                ${z("space_support",[z("space_moon_info_name")])}
                `,reqs:{science:9,luna:1},cost:{Money:e=>Ps("observatory",e,2e5,1.28),Knowledge:e=>Ps("observatory",e,69e3,1.28),Stone:e=>Ps("observatory",e,125e3,1.28),Iron:e=>Ps("observatory",e,65e3,1.28),Iridium:e=>Ps("observatory",e,1250,1.28)},effect(){let e="";t.race.cataclysm&&(e=`
                ${z("city_university_effect",[ta(1)])}
                `);let a=5e3;t.race.cataclysm&&t.space.satellite&&t.space.satellite.count>0&&(a*=1+.25*t.space.satellite.count);let r=t.race.cataclysm?`
                ${z("space_moon_observatory_cata_effect",[25])}
                `:`
                ${z("space_moon_observatory_effect",[5])}
                `;return`
                ${z("space_used_support",[z("space_moon_info_name")])}
                ${e}
                ${z("plus_max_resource",[a,z("resource_Knowledge_name")])}
                ${r}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("observatory"),t.space.moon_base.supportUt().red,desc:()=>z("space_red_info_desc",[Ut().red]),support:"spaceport",zone:"inner",syndicate:()=>!0},red_mission:{id:"space-red_mission",title:()=>z("space_mission_title",[Ut().red]),desc:()=>z("space_mission_desc",[Ut().red]),reqs:{space:3,space_explore:3},grant:["space",4],queue_complete:()=>t.tech.space>=4?0:1,cost:{Helium_3:(e,t)=>+Rt(4500,!1,t).toFixed(0)},effect:()=>z("space_red_mission_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(hs(z("space_red_mission_action",[Ut().red]),"info",!1,["progress"]),t.space.living_quarters={count:0,on:0},t.space.garage={count:0},t.space.red_mine={count:0,on:0},t.space.fabrication={count:0,on:0},!0)}},spaceport:{id:"space-spaceport",title:z("space_red_spaceport_title"),desc:()=>`
                ${z("space_red_spaceport_desc")}
                ${z("requires_power_space",[t.resource.Food.name])}
                `,reqs:{space:4},cost:{Money:e=>Ps("spaceport",e,47500,1.32),Iridium:e=>Ps("spaceport",e,1750,1.32),Mythril:e=>Ps("spaceport",e,25,1.32),Titanium:e=>Ps("spaceport",e,22500,1.32)},effect(e){let a=+Rt($(this)[0].support_fuel().a,!0,e).toFixed(2),r="";return(t.race.cataclysm||t.race.orbit_decayed)&&(r=`
                ${z("plus_max_resource",[`$${br(4*bi())}`,z("resource_Money_name")])}
                `),`
                ${z("space_red_spaceport_effect1",[Ut().red,$(this)[0].support()])}
                ${r}
                ${z("space_red_spaceport_effect2",[a,$(this)[0].powered()])}
                ${z("spend",[t.race.cataclysm?2:25,t.resource.Food.name])}
                `},support(){let e=t.race.cataclysm||t.race.orbit_decayed?4:3;return t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=4&&e++,e},support_fuel:()=>({r:"Helium_3",a:1.25}),powered:()=>As(5),powerBalancer:()=>[{s:t.space.spaceport.s_max-t.space.spaceport.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("spaceport"),Yr($(this)[0]),t.tech.mars||(t.tech.mars=1),t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+1e3&&(t.race.orbit_decay=t.stats.days+1e3,hs(z("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0)}},red_tower:{id:"space-red_tower",title:z("space_red_tower_title"),desc:()=>`
                ${z("space_red_tower_desc")}
                ${z("requires_power")}
                `,reqs:{mars:3},cost:{Money:e=>Ps("red_tower",e,225e3,1.28),Iron:e=>Ps("red_tower",e,22e3,1.28),Cement:e=>Ps("red_tower",e,15e3,1.28),Alloy:e=>Ps("red_tower",e,8e3,1.28)},effect(){return`
                ${z("space_red_spaceport_effect1",[Ut().red,t.race.cataclysm?2:1])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(2),powerBalancer:()=>[{s:t.space.spaceport.s_max-t.space.spaceport.support}],support:()=>t.race.cataclysm?2:1,action(){return!!ri($(this)[0])&&(Ft("red_tower"),Yr($(this)[0]),!0)}},captive_housing:Cr("captive_housing","space"),terraformer:{id:"space-terraformer",title:z("space_terraformer"),desc:e=>!t.space.hasOwnProperty("terraformer")||t.space.terraformer.count<100||e?`
                ${z("space_terraformer")}
                ${z("requires_segmemts",[100])}
                `+(t.space.hasOwnProperty("terraformer")&&t.space.terraformer.count>=100?`
                ${z("requires_power")}
                `:""):`
                ${z("space_terraformer")}
                `,reqs:{terraforming:1},condition:()=>!(t.space.terraformer.count>=100),queue_size:5,queue_complete:()=>100-t.space.terraformer.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?75e5:75e6:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?25e4:75e4:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?1e3:0,Bolognium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:1e5:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?12e3:25e4:0,Soul_Gem:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:1:0,Nanoweave:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:75e3:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100&&t.race.truepath?75e3:0,Cipher:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100&&t.race.truepath?1e3:0},effect(e){let a=(e?e.count:0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0);if(a<100){let e=100-a;return`
                ${z("space_terraformer_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                `}return $t.spc_red.atmo_terraformer.effect(e)},action(){return!!(ri($(this)[0])&&t.space.terraformer.count<100)&&(Ft("terraformer","space"),t.space.terraformer.count>=100&&(t.tech.terraforming=2,t.space.atmo_terraformer={count:1,on:0},Lt(),_s()),!0)}},atmo_terraformer:{id:"space-atmo_terraformer",title:z("space_terraformer"),desc:()=>`
                ${z("space_terraformer")}
                ${z("requires_power")}
                `,wiki:!1,reqs:{terraforming:2},condition:()=>t.space.terraformer.count>=100,queue_complete:()=>0,cost:{},powered:e=>As((e?e.truepath:t.race.truepath)?500:5e3),postPower(e){e?setTimeout((function(){t.tech.terraforming=s.atmo_terraformer?3:2,Lt()}),250):(t.tech.terraforming=2,Lt())},effect(e){let t=Pt(),a=$(this)[0].powered(e),r=a>0?`
                ${z("minus_power",[a])}
                `:"";return`
                ${z("space_terraformer_effect2")}
                ${t}${r}`},action:()=>!1},terraform:{id:"space-terraform",title:z("space_terraform"),desc:z("space_terraform"),reqs:{terraforming:3},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=Pt();return`
                ${z("space_terraform_effect")}
                ${e}`},action(){return!!ri($(this)[0])&&(Jt(),!0)}},assembly:Cr("assembly","space"),living_quarters:{id:"space-living_quarters",title:z("space_red_living_quarters_title"),desc:()=>`
                ${z("space_red_living_quarters_desc")}
                ${z("space_support",[Ut().red])}
                `,reqs:{mars:1},cost:{Money:e=>Ps("living_quarters",e,Bt(38e3),1.28),Steel:e=>Ps("living_quarters",e,Bt(15e3),1.28),Polymer:e=>Ps("living_quarters",e,Bt(9500),1.28),Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens(),a="";return(t.race.cataclysm||t.race.orbit_decayed)&&(a=`
                ${z("plus_max_resource",[`$${br(t.tech.home_safe>=2?t.tech.home_safe>=3?"100000":"50000":"25000")}`,z("resource_Money_name")])}
                `),`
                ${z("space_used_support",[Ut().red])}
                ${a}
                ${z("plus_max_resource",[ta(1),t.race.truepath?z("job_colonist_tp",[Ut().red]):z("colonist")])}
                ${z("plus_max_resource",[e,z("citizen")])}
                `},support:()=>-1,powered:()=>As(1),action(){if(ri($(this)[0])){if(Ft("living_quarters"),t.civic.colonist.display=!0,t.space.spaceport.support0)){let e=t.civic[t.civic.d_job].workers-ta(1)<0?t.civic[t.civic.d_job].workers:ta(1);t.civic[t.civic.d_job].workers-=e,t.civic.colonist.workers+=e}return!0}return!1},citizens(){let e=t.race.cataclysm||t.race.orbit_decayed?2:1;return n.biodome&&(e+=(t.tech.mars>=6?.1:.05)*n.biodome),+ta(e).toFixed(2)}},pylon:{id:"space-pylon",title:z("space_red_pylon"),desc:z("space_red_pylon"),reqs:{magic:2},condition:()=>!(!t.race.cataclysm&&!t.race.orbit_decayed),cost:{Money:e=>Ps("pylon",e,10,1.48),Stone:e=>Ps("pylon",e,12,1.42),Crystal:e=>Ps("pylon",e,8,1.42)-3},effect(){let e=br(2);return`
                ${z("gain",[+(.005*Is("magic")).toFixed(3),t.resource.Mana.name])}
                ${z("plus_max_resource",[e,t.resource.Mana.name])}
                `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!ri($(this)[0])&&(t.space.pylon.count++,t.resource.Mana.max+=br(2),!0)}},vr_center:{id:"space-vr_center",title:z("space_red_vr_center_title"),desc:()=>`
                ${z("space_red_vr_center_desc")}
                ${z("space_support",[Ut().red])}
                `,reqs:{mars:1,broadcast:3},cost:{Money:e=>Ps("vr_center",e,38e4,1.25),Copper:e=>Ps("vr_center",e,55e3,1.25),Stanene:e=>Ps("vr_center",e,1e5,1.25),Soul_Gem:e=>Ps("vr_center",e,1,1.25)},effect(){let e=K("gaslighter",1),a=e?e+1:1;return t.race.orbit_decayed&&(a+=2),`
                ${z("space_used_support",[Ut().red])}
                ${z("space_red_vr_center_effect1",[a])}
                ${z("space_red_vr_center_effect2",[2])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("vr_center"),t.space.spaceport.support`
                ${z("space_red_garage_desc")}
                `,reqs:{mars:1},cost:{Money:e=>Ps("garage",e,75e3,1.28),Iron:e=>Ps("garage",e,12e3,1.28),Brick:e=>Ps("garage",e,3e3,1.28),Sheet_Metal:e=>Ps("garage",e,1500,1.28)},wide:!0,res(){let e=["Copper","Iron","Cement","Steel","Titanium","Alloy","Nano_Tube","Neutronium","Infernite"];return(t.race.cataclysm||t.race.orbit_decayed)&&(e.push("Polymer"),e.push("Coal"),e.push("Lumber"),e.push("Chrysotile"),e.push("Stone"),e.push("Furs")),e},heavy:e=>!!["Copper","Iron","Steel","Titanium","Neutronium","Infernite"].includes(e),val(e){switch(e){case"Copper":return 6500;case"Iron":return 5500;case"Cement":return t.race.cataclysm?10500:6e3;case"Steel":return 4500;case"Titanium":return 3500;case"Alloy":case"Polymer":return 2500;case"Nano_Tube":return 25e3;case"Neutronium":return 125;case"Infernite":return 75;case"Coal":return 1500;case"Lumber":case"Chrysotile":case"Stone":return 7500;case"Furs":return 2200;default:return 0}},multiplier(e){let a=t.tech.particles>=4?1+t.tech.supercollider/20:1;return(t.tech.world_control||t.race.cataclysm||t.race.orbit_decayed)&&(a*=2),t.tech.shelving&&t.tech.shelving>=3&&(a*=1.5),a*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,e&&t.tech.shelving&&t.tech.shelving>=2?3*a:a},effect(){let e=$(this)[0].multiplier(!1),a=$(this)[0].multiplier(!0),r=t.tech.particles>=4?20+t.tech.supercollider:20;(t.tech.world_control||t.race.cataclysm||t.race.orbit_decayed)&&(r+=10);let i=t.race.cataclysm||t.race.orbit_decayed?`${z("plus_max_resource",[r,z("resource_Crates_name")])}`:"",s='
                ';s+=`${z("plus_max_resource",[r,z("resource_Containers_name")])}${i}`;for(const r of $(this)[0].res())if(t.resource[r].display){let i=$(this)[0].heavy(r);s+=`${z("plus_max_resource",[x(+(br($(this)[0].val(r))*(i?a:e)).toFixed(0),1),t.resource[r].name])}`}return s+="
                ",s},action(){if(ri($(this)[0])){Ft("garage");let e=$(this)[0].multiplier(!1),a=$(this)[0].multiplier(!0);for(const r of $(this)[0].res())if(t.resource[r].display){let i=$(this)[0].heavy(r);t.resource[r].max+=br($(this)[0].val(r))*(i?a:e)}return!0}return!1}},red_mine:{id:"space-red_mine",title:z("space_red_mine_title"),desc:()=>`
                ${z("space_red_mine_desc")}
                ${z("space_support",[Ut().red])}
                `,reqs:{mars:1},cost:{Money:e=>Ps("red_mine",e,5e4,1.32),Lumber:e=>Ps("red_mine",e,65e3,1.32),Iron:e=>Ps("red_mine",e,33e3,1.32)},effect(){let e=$e("red_mine","copper"),a=$e("red_mine","titanium"),r=+e.b.toFixed(3),i=+a.b.toFixed(3),s="";t.race.truepath&&(t.civic.foreign.gov3.hstl<10?s=`
                ${z("space_rival_ally",[+(100*e.g).toFixed(1)])}
                `:t.civic.foreign.gov3.hstl>60&&(s=`
                ${z("space_rival_war",[+(100*e.g).toFixed(1)])}
                `));let n=t.race.orbit_decayed?`
                ${z("city_mine_effect1",[ta(1)])}
                ${z("city_coal_mine_effect1",[ta(1)])}
                `:"",c=t.race.cataclysm||t.race.orbit_decayed&&!t.race.sappy?`
                ${z("space_red_mine_effect",[+$e("red_mine","stone").toFixed(2),t.resource.Stone.name])}
                `:"",o=t.race.cataclysm||t.race.orbit_decayed&&t.race.smoldering?`
                ${z("space_red_mine_effect",[+$e("red_mine","asbestos").toFixed(2),t.resource.Chrysotile.name])}
                `:"",l=t.race.cataclysm||t.race.orbit_decayed?`
                ${z("space_red_mine_effect",[+$e("red_mine","aluminium").toFixed(2),t.resource.Aluminium.name])}
                `:"";return`
                ${z("space_used_support",[Ut().red])}
                ${n}
                ${z("space_red_mine_effect",[r,t.resource.Copper.name])}
                ${z("space_red_mine_effect",[i,t.resource.Titanium.name])}
                ${s}${o}${c}${l}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("red_mine"),t.space.spaceport.support`
                ${z("space_red_fabrication_desc")}
                ${z("space_support",[Ut().red])}
                `,reqs:{mars:1},cost:{Money:e=>Ps("fabrication",e,9e4,1.32),Copper:e=>Ps("fabrication",e,25e3,1.32),Cement:e=>Ps("fabrication",e,12e3,1.32),Wrought_Iron:e=>Ps("fabrication",e,1200,1.32)},effect(){let e=t.race.cataclysm&&!t.race.flier?`
                ${z("city_cement_plant_effect1",[ta(1)])}
                `:"",a=t.race.cataclysm||t.race.orbit_decayed?5:2;return t.race.high_pop&&(a=ke(a)),`
                ${z("space_used_support",[Ut().red])}
                ${z("space_red_fabrication_effect1",[ta(1)])}
                ${e}
                ${z("space_red_fabrication_effect2",[a])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("fabrication"),t.space.spaceport.support`
                ${z("space_red_factory_desc")}
                ${z("requires_power_combo",[t.resource.Helium_3.name])}
                `,reqs:{mars:4},cost:{Money:e=>Ps("red_factory",e,75e3,1.32),Brick:e=>Ps("red_factory",e,1e4,1.32),Coal:e=>Ps("red_factory",e,7500,1.32),Mythril:e=>Ps("red_factory",e,50,1.32)},effect(e){let a=`
                ${z("space_red_factory_effect1")}
                `;return t.tech.foundry>=7&&(a+=`
                ${z("space_red_factory_effect2")}
                `),t.race.orbit_decayed&&!t.race.flier&&(a+=`
                ${z("city_cement_plant_effect1",[ta(1)])}
                `),a+=`
                ${z("space_red_factory_effect3",[+Rt(1,!0,e).toFixed(2),$(this)[0].powered()])}
                `,a},powered:()=>As(3),special:!0,action(){return!!ri($(this)[0])&&(t.space.red_factory.count++,Yr($(this)[0])&&t.city.factory.Alloy++,t.settings.showIndustry=!0,ki(),!0)}},nanite_factory:Cr("nanite_factory","space"),biodome:{id:"space-biodome",title:()=>t.race.artifical?z("space_red_signal_tower_title"):t.race.soul_eater?z("space_red_asphodel_title"):z("space_red_biodome_title"),desc(){let e;return e=t.race.artifical?`
                ${z("space_red_signal_tower_title")}
                `:t.race.soul_eater?`
                ${z("space_red_asphodel_desc")}
                `:t.race.carnivore?`
                ${z("space_red_biodome_desc_carn")}
                `:`
                ${z("space_red_biodome_desc",[Ut().red])}
                `,`
                ${e}
                ${z("space_support",[Ut().red])}
                `},reqs:{mars:2},cost:{Money:e=>Ps("biodome",e,45e3,1.28),Lumber:e=>Ps("biodome",e,65e3,1.28),Brick:e=>Ps("biodome",e,1e3,1.28),Nanite:e=>t.race.deconstructor?Ps("biodome",e,75,1.28):0},effect(){let e=+$e("biodome","food").toFixed(2),a=t.race.cataclysm||t.race.orbit_decayed?`
                ${z("produce",[+$e("biodome","cat_food").toFixed(2),t.resource.Food.name])}
                `:"",r=!t.race.cataclysm&&!t.race.orbit_decayed||t.race.kindling_kindred?"":`
                ${z("space_red_mine_effect",[+$e("biodome","lumber").toFixed(2),t.resource.Lumber.name])}
                `,i=t.tech.mars>=6?.1:.05,s=t.race.artifical?z("city_transmitter_effect",[br(500)]):z("plus_max_resource",[br(100),z("resource_Food_name")]),n=t.race.artifical||t.race.orbit_decayed?`
                ${s}${z("space_used_support",[Ut().red])}
                ${a}
                ${z("space_red_biodome_effect",[e,t.resource.Food.name])}
                ${z("space_red_biodome_effect2",[+ta(i).toFixed(2)])}
                ${r}${n}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("biodome"),t.race.cataclysm||(qn("colonist"),t.race.joyless&&(qn("joyless"),delete t.race.joyless,Qr())),t.space.spaceport.supportt.race.artifical?z("space_red_signal_tower_flair"):t.race.soul_eater?z("space_red_asphodel_flair"):t.race.carnivore?z("space_red_biodome_flair_carn"):z("space_red_biodome_flair")},red_university:{id:"space-red_university",title:z("city_university"),desc:()=>z("city_university_desc",[Ut().red]),reqs:{mars:1},trait:["orbit_decayed"],cost:{Money:e=>Ps("university",e,900,1.5,"city")-500,Lumber:e=>Ps("university",e,500,1.36,"city")-200,Stone:e=>Ps("university",e,750,1.36,"city")-350,Crystal:e=>"magic"===t.race.universe?Ps("university",e,5,1.36,"city"):0},wiki:!1,effect:()=>Mr.city.university.effect(),action(){if(ri($(this)[0])){let e=t.tech.science&&t.tech.science>=8?700:500;if(t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,t.city.university.count++,t.space.red_university.count=t.city.university.count,t.civic.professor.display=!0,t.civic.professor.max=t.city.university.count,!0}return!1}},exotic_lab:{id:"space-exotic_lab",title:z("space_red_exotic_lab_title"),desc:()=>`
                ${z("space_red_exotic_lab_desc")}
                ${z("space_support",[Ut().red])}
                `,reqs:{mars:5},cost:{Money:e=>Ps("exotic_lab",e,75e4,1.28),Steel:e=>Ps("exotic_lab",e,1e5,1.28),Mythril:e=>Ps("exotic_lab",e,1e3,1.28),Elerium:e=>Ps("exotic_lab",e,20,1.28)-4},effect(){let e=500;t.tech.science>=13&&t.interstellar.laboratory&&c.laboratory&&(e+=25*c.laboratory),t.tech.ancient_study&&t.tech.ancient_study>=2&&(e+=15*t.space.ziggurat.count),t.tech.mass>=2&&s.mass_driver&&(e+=ke(s.mass_driver*t.civic.scientist.workers)),t.tech.science>=21&&(e*=1.45),t.race.high_pop&&(e=ke(e));let a=br(10),r="",i="";return(t.race.cataclysm||t.race.orbit_decayed)&&(r=`
                ${z("city_wardenclyffe_effect1",[ta(1),t.civic.scientist.name])}
                `,e*=1+.25*n.observatory,t.tech.science>=15&&(i=`
                ${z("city_wardenclyffe_effect4",[2])}
                `)),`
                ${z("space_used_support",[Ut().red])}
                ${r}${i}
                ${z("space_red_exotic_lab_effect1",[+e.toFixed(0)])}
                ${z("plus_max_resource",[a,z("resource_Elerium_name")])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("exotic_lab"),t.space.spaceport.support`
                ${z("space_red_exotic_lab_flair1")}
                ${z("space_red_exotic_lab_flair2")}
                `},ziggurat:{id:"space-ziggurat",title:z("space_red_ziggurat_title"),desc:()=>`
                ${z("space_red_ziggurat_desc",["none"!==t.race.old_gods?Ki[t.race.old_gods.toLowerCase()].entity:Ki[t.race.species].entity])}
                `,reqs:{theology:4},cost:{Money:e=>Ps("ziggurat",e,6e5,1.28),Stone:e=>Ps("ziggurat",e,25e4,1.28),Aluminium:e=>Ps("ziggurat",e,7e4,1.28),Mythril:e=>Ps("ziggurat",e,250,1.28)},effect(){let e=t.tech.ancient_study?.6:.4;if(t.tech.ancient_deify&&t.tech.ancient_deify>=2&&n.exotic_lab&&(e+=.01*n.exotic_lab),"theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let a=.002;t.race.high_pop&&(a=ke(a)),e+=a*t.civic.priest.workers}t.race.ooze&&(e*=1-Ei.ooze.vars()[1]/100),t.race.high_pop&&(e=ke(e)),e=+e.toFixed(2);let a=t.race.truepath?[e,Ki[t.race.species].home]:[e],r=`
                ${z(t.race.truepath?"space_red_ziggurat_effect_tp":"space_red_ziggurat_effect",a)}
                `;return t.tech.ancient_study&&t.tech.ancient_study>=2&&(r+=`
                ${z("interstellar_laboratory_effect",[3])}
                `),(t.race.cataclysm||t.race.orbit_decayed)&&(r+=Er()),t.genes.ancients&&t.genes.ancients>=4&&(r+=`
                ${z("city_temple_effect6",[ta(1)])}
                `),r},action(){return!!ri($(this)[0])&&(Ft("ziggurat"),t.genes.ancients&&t.genes.ancients>=4&&(t.civic.priest.display=!0),t.race.cataclysm&&qn("iron_will",!1,1),!0)}},space_barracks:{id:"space-space_barracks",title:z("space_red_space_barracks_title"),desc:()=>`
                ${z("space_red_space_barracks_desc")}
                ${z("space_red_space_barracks_desc_req")}
                `,reqs:{marines:1},cost:{Money:e=>Ps("space_barracks",e,35e4,1.28),Alloy:e=>Ps("space_barracks",e,65e3,1.28),Iridium:e=>Ps("space_barracks",e,22500,1.28),Wrought_Iron:e=>Ps("space_barracks",e,12500,1.28),Horseshoe:()=>t.race.hooved?2:0},effect(e){let a=t.race.orbit_decayed?Mr.city.boot_camp.effect():"",r=+Rt(2,!0,e).toFixed(2),i=t.tech.marines>=2?ta(4):ta(2),s=t.race.cataclysm?"":`
                ${z("space_red_space_barracks_effect3",[t.resource.Food.name])}
                `;return`
                ${z("plus_max_soldiers",[i])}
                ${a}
                ${z("space_red_space_barracks_effect2",[r])}
                ${s}`},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("space_barracks"),t.space.space_barracks.on++,!0)},flair:()=>z("space_red_space_barracks_flair")},bonfire:Cr("bonfire","space"),horseshoe:Cr("horseshoe","space")},spc_hell:{info:{name:()=>Ut().hell,desc:()=>z("space_hell_info_desc",[Ut().hell]),zone:"inner",syndicate:()=>!1},hell_mission:{id:"space-hell_mission",title:()=>z("space_mission_title",[Ut().hell]),desc:()=>z("space_mission_desc",[Ut().hell]),reqs:{space:3,space_explore:3},grant:["hell",1],queue_complete:()=>t.tech.hell>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(6500,!1,t).toFixed(0)},effect:()=>z("space_hell_mission_effect1",[Ut().hell]),action(){return!!ri($(this)[0])&&(hs(z("space_hell_mission_action",[Ut().hell]),"info",!1,["progress"]),t.space.geothermal={count:0,on:0},!0)}},geothermal:{id:"space-geothermal",title:z("space_hell_geothermal_title"),desc:()=>`
                ${z("space_hell_geothermal_desc")}
                ${z("space_hell_geothermal_desc_req")}
                `,reqs:{hell:1},cost:{Money:e=>Ps("geothermal",e,38e3,1.35),Steel:e=>Ps("geothermal",e,15e3,1.35),Polymer:e=>Ps("geothermal",e,9500,1.35)},effect(e){let a=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(2);return`${t.race.cataclysm||t.race.orbit_decayed?`
                ${z("interstellar_stellar_forge_effect3",[1])}
                `:""}${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${z("space_belt_station_effect3",[a])}`},special:()=>!(!t.race.cataclysm&&!t.race.orbit_decayed),powered(){let e=-8;return t.race.forge&&(e-=Ei.forge.vars()[0]),t.stats.achieve.failed_history&&t.stats.achieve.failed_history.l>=5&&(e-=2),Fs(e)},p_fuel:()=>({r:"Helium_3",a:.5}),action(){return!!ri($(this)[0])&&(Ft("geothermal"),t.space.geothermal.on++,!0)}},hell_smelter:{id:"space-hell_smelter",title:()=>z("space_hell_smelter_title",[Ut().hell]),desc:()=>z("space_hell_smelter_title",[Ut().hell]),reqs:{hell:1,m_smelting:1},path:["truepath"],cost:{Money:e=>Ps("hell_smelter",e,25e4,1.24),Adamantite:e=>Ps("hell_smelter",e,15e3,1.24)},effect:()=>`
                ${z("interstellar_stellar_forge_effect3",[2])}
                `,special:!0,action(){return!!ri($(this)[0])&&(Ft("hell_smelter"),t.city.smelter.cap+=2,t.city.smelter.Steel+=2,t.city.smelter.Oil+=2,!0)}},spc_casino:{id:"space-spc_casino",title:z("city_casino"),desc:z("city_casino"),category:"commercial",reqs:{hell:1,gambling:1},condition:()=>!!(t.race.cataclysm||t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=5),cost:{Money:e=>Ps("spc_casino",e,4e5,1.35),Furs:e=>Ps("spc_casino",e,75e3,1.35),Cement:e=>Ps("spc_casino",e,1e5,1.35),Plywood:e=>Ps("spc_casino",e,2e4,1.35)},effect(){let e=Kr();return e+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,e},powered:()=>As(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2?2:3),action(){return!!ri($(this)[0])&&(t.space.spc_casino.count++,t.race.joyless||(t.civic.entertainer.max+=ta(1),t.civic.entertainer.display=!0),Yr($(this)[0]),!0)},flair:z("city_casino_flair")},swarm_plant:{id:"space-swarm_plant",title:z("space_hell_swarm_plant_title"),desc:()=>`
                ${z("space_hell_swarm_plant_desc")}
                `,reqs:{solar:4,hell:1},cost:{Money:e=>Ps("swarm_plant",e,Gt(75e3),1.28),Iron:e=>Ps("swarm_plant",e,Gt(65e3),1.28),Neutronium:e=>Ps("swarm_plant",e,Gt(75),1.28),Brick:e=>Ps("swarm_plant",e,Gt(2500),1.28),Mythril:e=>Ps("swarm_plant",e,Gt(100),1.28)},effect(){let e=t.tech.swarm?.88:.94;return t.tech.swarm>=3&&(e-=_/100),e<.05&&(e=.05),e=+(100*(1-e)).toFixed(2),z("space_hell_swarm_plant_effect1",[e])},action(){return!!ri($(this)[0])&&(Ft("swarm_plant"),!0)}},firework:Cr("firework","space")},spc_sun:{info:{name:()=>z("space_sun_info_name"),desc:()=>z("space_sun_info_desc",[Ki[t.race.species].home]),support:"swarm_control",zone:"inner",syndicate:()=>!1},sun_mission:{id:"space-sun_mission",title:()=>z("space_sun_mission_title"),desc:()=>z("space_sun_mission_desc"),reqs:{space_explore:4},grant:["solar",1],queue_complete:()=>t.tech.solar>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(15e3,!1,t).toFixed(0)},effect:()=>z("space_sun_mission_effect1"),action(){return!!ri($(this)[0])}},swarm_control:{id:"space-swarm_control",title:z("space_sun_swarm_control_title"),desc:()=>`
                ${z("space_sun_swarm_control_desc")}
                `,reqs:{solar:3},cost:{Money:e=>Ps("swarm_control",e,1e5,1.3),Knowledge:e=>Ps("swarm_control",e,6e4,1.3),Alloy:e=>Ps("swarm_control",e,7500,1.3),Helium_3:(e,t)=>Ps("swarm_control",e,Rt(2e3,!1,t),1.3),Mythril:e=>Ps("swarm_control",e,250,1.3)},effect(){return z("space_sun_swarm_control_effect1",[$(this)[0].support()])},support:()=>t.tech.swarm&&t.tech.swarm>=2?t.tech.high_tech>=11?11+Math.round(_):12:10,action(){return!!ri($(this)[0])&&(Ft("swarm_control"),t.space.swarm_control.s_max+=$(this)[0].support(),!0)}},swarm_satellite:{id:"space-swarm_satellite",title:z("space_sun_swarm_satellite_title"),desc:()=>`
                ${z("space_sun_swarm_satellite_desc")}
                ${z("space_sun_swarm_satellite_desc_req")}
                `,reqs:{solar:3},cost:{Money:e=>Ps("swarm_satellite",e,Nt(5e3),1.1),Copper:e=>Ps("swarm_satellite",e,Nt(2500),1.1),Iridium:e=>Ps("swarm_satellite",e,Nt(150),1.1),Helium_3:(e,t)=>Ps("swarm_satellite",e,Nt(Rt(50,!1,t)),1.1)},effect(){let e=.35;return t.tech.swarm>=4&&(e+=.15*(t.tech.swarm-3)),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1&&(e+=.15),t.blood.illuminate&&(e+=.01*t.blood.illuminate),e=+e.toFixed(2),`${z("space_dwarf_reactor_effect1",[Fs(e)])}, ${z("space_sun_swarm_satellite_effect1",[1])}`},support:()=>-1,action(){return!!ri($(this)[0])&&(Ft("swarm_satellite"),t.space.swarm_control.support++,!0)}},jump_gate:{id:"space-jump_gate",title:z("tau_jump_gate"),desc:e=>!t.space.hasOwnProperty("jump_gate")||t.space.jump_gate.count<100||e?`
                ${z("tau_jump_gate")}
                ${z("requires_segmemts",[100])}
                `:`
                ${z("tau_jump_gate")}
                `,reqs:{tauceti:3},path:["truepath"],queue_size:10,queue_complete:()=>100-t.space.jump_gate.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?1e6:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?5e4:0,Adamantite:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?12500:0,Graphene:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?42e3:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?35e3:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?25e3:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0);if(a<100){let e=100-a;return`
                ${z("tau_jump_gate_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                `}return z("tau_jump_gate_effect")},action(){return!!(ri($(this)[0])&&t.space.jump_gate.count<100)&&(t.space.jump_gate.count++,!0)}}},spc_gas:{info:{name:()=>Ut().gas,desc:()=>z("space_gas_info_desc",[Ut().gas,Ki[t.race.species].home]),zone:"outer",syndicate:()=>!0},gas_mission:{id:"space-gas_mission",title:()=>z("space_mission_title",[Ut().gas]),desc:()=>z("space_mission_desc",[Ut().gas]),reqs:{space:4,space_explore:4},grant:["space",5],queue_complete:()=>t.tech.space>=5?0:1,cost:{Helium_3:(e,t)=>+Rt(12500,!1,t).toFixed(0)},effect:()=>z("space_gas_mission_effect",[Ut().gas]),action(){return!!ri($(this)[0])&&(hs(z("space_gas_mission_action",[Ut().gas]),"info",!1,["progress"]),t.settings.space.gas_moon=!0,t.settings.space.belt=!0,t.space.space_station={count:0,on:0,support:0,s_max:0},!0)}},gas_mining:{id:"space-gas_mining",title:z("space_gas_mining_title"),desc:()=>`
                ${z("space_gas_mining_desc")}
                ${z("requires_power")}
                `,reqs:{gas_giant:1},cost:{Money:e=>Ps("gas_mining",e,25e4,1.32),Uranium:e=>Ps("gas_mining",e,500,1.32),Alloy:e=>Ps("gas_mining",e,1e4,1.32),Helium_3:(e,t)=>Ps("gas_mining",e,Rt(2500,!1,t),1.32),Mythril:e=>Ps("gas_mining",e,25,1.32)},effect(){return`
                ${z("space_gas_mining_effect1",[+$e("gas_mining").toFixed(2)])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(2),action(){return!!ri($(this)[0])&&(Ft("gas_mining"),Yr($(this)[0]),!0)}},gas_storage:{id:"space-gas_storage",title:()=>z("space_gas_storage_title",[Ut().gas]),desc:()=>`
                ${z("space_gas_storage_desc")}
                `,reqs:{gas_giant:1},cost:{Money:e=>Ps("gas_storage",e,125e3,1.32),Iridium:e=>Ps("gas_storage",e,3e3,1.32),Sheet_Metal:e=>Ps("gas_storage",e,2e3,1.32),Helium_3:(e,t)=>Ps("gas_storage",e,Rt(1e3,!1,t),1.32)},effect(){let e=br(3500)*(t.tech.world_control?1.5:1),a=br(2500)*(t.tech.world_control?1.5:1),r=br(1e3)*(t.tech.world_control?1.5:1);return`
                ${z("plus_max_resource",[e,z("resource_Oil_name")])}
                ${z("plus_max_resource",[a,z("resource_Helium_3_name")])}
                ${z("plus_max_resource",[r,z("resource_Uranium_name")])}
                `},action(){return!!ri($(this)[0])&&(Ft("gas_storage"),!0)}},star_dock:{id:"space-star_dock",title:()=>z("space_gas_star_dock_title"),desc:()=>`
                ${z("space_gas_star_dock_title")}
                ${z("space_gas_star_dock_desc_req")}
                `,reqs:{genesis:3},queue_complete:()=>1-t.space.star_dock.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?15e5:0,Steel:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?5e5:0,Helium_3:(e,a)=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?Math.round(Rt(1e4,!1,a)):0,Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?25e4:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?1e4:0},effect:()=>`
                ${z("space_gas_star_dock_effect1")}
                `,special:!0,action(){return!(0!==t.space.star_dock.count||!ri($(this)[0])||(Ft("star_dock"),0))}}},spc_gas_moon:{info:{name:()=>Ut().gas_moon,desc:()=>z("space_gas_moon_info_desc",[Ut().gas_moon,Ut().gas]),zone:"outer",syndicate:()=>!0},gas_moon_mission:{id:"space-gas_moon_mission",title:()=>z("space_mission_title",[Ut().gas_moon]),desc:()=>z("space_mission_desc",[Ut().gas_moon]),reqs:{space:5},grant:["space",6],queue_complete:()=>t.tech.space>=6?0:1,cost:{Helium_3:(e,t)=>+Rt(3e4,!1,t).toFixed(0)},effect:()=>z("space_gas_moon_mission_effect",[Ut().gas_moon]),action(){return!!ri($(this)[0])&&(hs(z("space_gas_moon_mission_action",[Ut().gas_moon]),"info",!1,["progress"]),t.space.outpost={count:0,on:0},t.tech.gas_moon=1,!0)}},outpost:{id:"space-outpost",title:z("space_gas_moon_outpost_title"),desc:()=>`
                ${z("space_gas_moon_outpost_desc")}
                ${z("requires_power_combo",[t.resource.Oil.name])}
                `,reqs:{gas_moon:1},cost:{Money:e=>Ps("outpost",e,666e3,1.3),Titanium:e=>Ps("outpost",e,18e3,1.3),Iridium:e=>Ps("outpost",e,2500,1.3),Helium_3:(e,t)=>Ps("outpost",e,Rt(6e3,!1,t),1.3),Mythril:e=>Ps("outpost",e,300,1.3)},effect(e){let t=+$e("outpost").toFixed(3),a=br(500),r=+Rt(2,!0,e).toFixed(2);return`
                ${z("space_gas_moon_outpost_effect1",[t])}
                ${z("plus_max_resource",[a,z("resource_Neutronium_name")])}
                ${z("space_gas_moon_outpost_effect3",[r,$(this)[0].powered()])}
                `},powered:()=>As(3),powerBalancer:()=>[{r:"Neutronium",k:"lpmod"}],action(){return!!ri($(this)[0])&&(Ft("outpost"),t.resource.Neutronium.display=!0,Yr($(this)[0]),!0)}},drone:{id:"space-drone",title:z("space_gas_moon_drone_title"),desc:()=>`
                ${z("space_gas_moon_drone_desc")}
                `,reqs:{gas_moon:1,drone:1},cost:{Money:e=>Ps("drone",e,25e4,1.3),Steel:e=>Ps("drone",e,2e4,1.3),Neutronium:e=>Ps("drone",e,500,1.3),Elerium:e=>Ps("drone",e,25,1.3),Nano_Tube:e=>Ps("drone",e,45e3,1.3)},effect:()=>`
                ${z("space_gas_moon_drone_effect1",[t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3?12:6])}
                `,action(){return!!ri($(this)[0])&&(Ft("drone"),!0)}},oil_extractor:{id:"space-oil_extractor",title:z("space_gas_moon_oil_extractor_title"),desc:()=>`
                ${z("space_gas_moon_oil_extractor_title")}
                ${z("requires_power")}
                `,reqs:{gas_moon:2},cost:{Money:e=>Ps("oil_extractor",e,666e3,1.3),Polymer:e=>Ps("oil_extractor",e,7500,1.3),Helium_3:(e,t)=>Ps("oil_extractor",e,Rt(2500,!1,t),1.3),Wrought_Iron:e=>Ps("oil_extractor",e,5e3,1.3)},effect(){return`${z("space_gas_moon_oil_extractor_effect1",[+$e("oil_extractor").toFixed(2)])}, ${z("minus_power",[$(this)[0].powered()])}`},powered:()=>As(1),powerBalancer:()=>[{r:"Oil",k:"lpmod"}],action(){return!!ri($(this)[0])&&(Ft("oil_extractor"),Yr($(this)[0]),!0)}}},spc_belt:{info:{name:()=>z("space_belt_info_name"),desc:()=>t.space.space_station&&t.space.space_station.count>0?`
                ${z("space_belt_info_desc",[Ut().red,Ut().gas])}
                ${z("space_belt_info_desc2")}
                `:z("space_belt_info_desc",[Ut().red,Ut().gas]),support:"space_station",zone:"inner",syndicate:()=>!0},belt_mission:{id:"space-belt_mission",title:()=>z("space_belt_mission_title"),desc:()=>z("space_belt_mission_desc"),reqs:{space:5},grant:["asteroid",1],queue_complete:()=>t.tech.asteroid>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(25e3,!1,t).toFixed(0)},effect:()=>z("space_belt_mission_effect1"),action(){return!!ri($(this)[0])&&(hs(z("space_belt_mission_action"),"info",!1,["progress"]),t.settings.space.dwarf=!0,!0)}},space_station:{id:"space-space_station",title:z("space_belt_station_title"),desc:()=>`
                ${z("space_belt_station_desc")}
                ${z("requires_power_space",[t.resource.Food.name])}
                `,reqs:{asteroid:2},cost:{Money:e=>Ps("space_station",e,25e4,1.3),Iron:e=>Ps("space_station",e,85e3,1.3),Polymer:e=>Ps("space_station",e,18e3,1.3),Iridium:e=>Ps("space_station",e,2800,1.28),Helium_3:(e,t)=>Ps("space_station",e,Rt(2e3,!1,t),1.3),Mythril:e=>Ps("space_station",e,75,1.25)},effect(e){let a=+Rt(2.5,!0,e).toFixed(2),r=t.race.cataclysm?1:10,i=br(5),s=t.tech.asteroid>=5?`
                ${z("plus_max_resource",[i,z("resource_Elerium_name")])}
                `:"";return`
                ${z("plus_max_space_miners",[ta(3)])}
                ${s}
                ${z("space_belt_station_effect3",[a])}
                ${z("space_belt_station_effect4",[r,$(this)[0].powered(),t.resource.Food.name])}
                `},support:()=>ta(3),powered:()=>As(3),refresh:!0,action(){if(ri($(this)[0])){if(Ft("space_station"),t.civic.space_miner.display=!0,t.tech.asteroid<3&&(t.tech.asteroid=3),Yr($(this)[0])&&t.civic[t.civic.d_job].workers>0){let e=ta(3);t.civic[t.civic.d_job].workers-e<0&&(e=t.civic[t.civic.d_job].workers),t.civic[t.civic.d_job].workers-=e,t.civic.space_miner.workers+=e}return t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+1e3&&(t.race.orbit_decay=t.stats.days+1e3,hs(z("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0}return!1}},elerium_ship:{id:"space-elerium_ship",title:z("space_belt_elerium_ship_title"),desc:()=>z("space_belt_elerium_ship_title"),reqs:{asteroid:5},cost:{Money:e=>Ps("elerium_ship",e,5e5,1.3),Uranium:e=>Ps("elerium_ship",e,2500,1.3),Titanium:e=>Ps("elerium_ship",e,1e4,1.3),Mythril:e=>Ps("elerium_ship",e,500,1.3),Helium_3:(e,t)=>Ps("elerium_ship",e,Rt(5e3,!1,t),1.3)},effect(){let e=+$e("elerium_ship").toFixed(4);return`
                ${z("space_belt_elerium_ship_effect1",[ta(2)])}
                ${z("space_belt_elerium_ship_effect2",[e])}
                `},support:()=>ta(-2),powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("elerium_ship"),t.space.space_station.support+1z("space_belt_iridium_ship_title"),reqs:{asteroid:3},cost:{Money:e=>Ps("iridium_ship",e,12e4,1.3),Uranium:e=>Ps("iridium_ship",e,1e3,1.3),Alloy:e=>Ps("iridium_ship",e,48e3,1.3),Iridium:e=>Ps("iridium_ship",e,2800,1.3),Helium_3:(e,t)=>Ps("iridium_ship",e,Rt(1800,!1,t),1.3)},effect(){let e=+$e("iridium_ship").toFixed(3);return`
                ${z("space_belt_iridium_ship_effect1",[ta(1)])}
                ${z("space_belt_iridium_ship_effect2",[e])}
                `},support:()=>ta(-1),powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("iridium_ship"),t.space.space_station.supportz("space_belt_iron_ship_title"),reqs:{asteroid:3},cost:{Money:e=>Ps("iron_ship",e,8e4,1.3),Steel:e=>Ps("iron_ship",e,42e3,1.3),Aluminium:e=>Ps("iron_ship",e,38e3,1.3),Polymer:e=>Ps("iron_ship",e,16e3,1.3),Helium_3:(e,t)=>Ps("iron_ship",e,Rt(1200,!1,t),1.3)},effect(){let e=+$e("iron_ship").toFixed(2);return t.tech.solar&&t.tech.solar>=5?`
                ${z("space_belt_iron_ship_effect1",[ta(1)])}
                ${z("space_belt_iron_ship_effect2",[e])}
                ${z("space_belt_iron_ship_effect3")}
                `:`
                ${z("space_belt_iron_ship_effect1",[ta(1)])}
                ${z("space_belt_iron_ship_effect2",[e])}
                `},support:()=>ta(-1),powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("iron_ship"),t.space.space_station.supportUt().dwarf,desc:()=>z("space_dwarf_info_desc",[Ut().dwarf]),zone:"inner",syndicate:()=>!1},dwarf_mission:{id:"space-dwarf_mission",title:()=>z("space_mission_title",[Ut().dwarf]),desc:()=>z("space_mission_desc",[Ut().dwarf]),reqs:{asteroid:1,elerium:1},grant:["dwarf",1],queue_complete:()=>t.tech.dwarf>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(45e3,!1,t).toFixed(0)},effect:()=>z("space_dwarf_mission_effect1",[Ut().dwarf]),action(){return!!ri($(this)[0])&&(hs(z("space_dwarf_mission_action",[Ut().dwarf]),"info",!1,["progress"]),t.space.elerium_contain={count:0,on:0},!0)}},elerium_contain:{id:"space-elerium_contain",title:z("space_dwarf_elerium_contain_title"),desc:()=>`
                ${z("space_dwarf_elerium_contain_title")}
                ${z("requires_power")}
                `,reqs:{dwarf:1},cost:{Money:e=>Ps("elerium_contain",e,8e5,1.28),Cement:e=>Ps("elerium_contain",e,12e4,1.28),Iridium:e=>Ps("elerium_contain",e,5e4,1.28),Neutronium:e=>Ps("elerium_contain",e,250,1.28)},effect(){return`
                ${z("plus_max_resource",[br(100),z("resource_Elerium_name")])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(6),action(){return!!ri($(this)[0])&&(Ft("elerium_contain"),Yr($(this)[0]),!0)}},e_reactor:{id:"space-e_reactor",title:z("space_dwarf_reactor_title"),desc:()=>`
                ${z("space_dwarf_reactor_title")}
                ${z("space_dwarf_reactor_desc_req")}
                `,reqs:{elerium:2},cost:{Money:e=>Ps("e_reactor",e,125e4,1.28),Steel:e=>Ps("e_reactor",e,35e4,1.28),Neutronium:e=>Ps("e_reactor",e,1250,1.28),Mythril:e=>Ps("e_reactor",e,2500,1.28)},effect(){let e=$(this)[0].p_fuel().a;return`
                ${z("space_dwarf_reactor_effect1",[-1*$(this)[0].powered()])}
                ${z("space_dwarf_reactor_effect2",[e])}
                `},powered:()=>Fs(-25),p_fuel:()=>({r:"Elerium",a:.05}),action(){return!!ri($(this)[0])&&(Ft("e_reactor"),t.space.e_reactor.on++,!0)}},world_collider:{id:"space-world_collider",title:z("space_dwarf_collider_title"),desc(e){if(!t.space.hasOwnProperty("world_collider")||t.space.world_collider.count<1859||e)return`
                ${z("space_dwarf_collider_desc")}
                ${z("space_dwarf_collider_desc_req")}
                `+(t.space.hasOwnProperty("world_collider")&&t.space.world_collider.count>=1859?`
                ${z("requires_power")}
                `:"")},reqs:{science:10},path:["standard"],condition:()=>t.space.world_collider.count<1859,queue_size:100,queue_complete:()=>1859-t.space.world_collider.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?25e3:0,Copper:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?750:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?125:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?12:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?1:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?10:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0);if(a<1859){let e=1859-a;return`
                ${z("space_dwarf_collider_effect1")}
                ${z("space_dwarf_collider_effect2",[e])}
                `}return $t.spc_dwarf.world_controller.effect()},action(){if(t.space.world_collider.count<1859&&ri($(this)[0])){if(Ft("world_collider"),t.space.world_collider.count>=1859){if(t.tech.science=11,t.space.world_controller={count:1,on:0},Qr(),Lt(),t.race.banana){let e=xn();t.stats.banana.b2[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b2.l=!0)}_s()}return!0}return!1},flair:z("space_dwarf_collider_flair")},world_controller:{id:"space-world_controller",title:z("space_dwarf_collider_title"),desc:()=>`
                ${z("space_dwarf_collider_title")}
                ${z("requires_power")}
                `,wiki:!1,reqs:{science:11},path:["standard"],condition:()=>!(t.space.world_collider.count<1859),queue_complete:()=>0,cost:{},effect(){let e=25;return t.interstellar.far_reach&&s.far_reach>0&&(e+=1*s.far_reach),t.tech.science>=19&&(e+=15),`
                ${z("plus_max_resource",[e+"%",z("resource_Knowledge_name")])}
                ${z("space_dwarf_controller_effect3")}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(20),action:()=>!1,flair:z("space_dwarf_controller_flair")},shipyard:{id:"space-shipyard",title:z("outer_shipyard_title"),desc:()=>`
                ${z("outer_shipyard_title")}
                ${z("requires_power")}
                `,reqs:{shipyard:1},path:["truepath"],cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e7:0,Aluminium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e6:0,Titanium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?65e4:0,Iridium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?25e4:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e4:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?5e5:0},queue_complete:()=>1-t.space.shipyard.count,effect(){return`
                ${z("outer_shipyard_effect")}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(50),special:!0,sAction(){s.shipyard&&(t.settings.civTabs=2,t.settings.govTabs=5,t.settings.tabLoad||(kt("mTabCivic"),_s("space-shipyard")))},action(){return!!(t.space.shipyard.count<1&&ri($(this)[0]))&&(Ft("shipyard"),Yr($(this)[0])&&(t.settings.showShipYard=!0),t.tech.syard_class=2,t.tech.syard_armor=3,t.tech.syard_weapon=1,t.tech.syard_engine=2,t.tech.syard_power=3,t.tech.syard_sensor=3,!0)}},mass_relay:{id:"space-mass_relay",title:z("space_dwarf_mass_relay_title"),desc(e){if(!t.space.hasOwnProperty("mass_relay")||t.space.mass_relay.count<100||e)return`
                ${z("space_dwarf_mass_relay_title")}
                ${z("requires_segmemts",[100])}
                `},reqs:{outer:5},path:["truepath"],condition:()=>t.space.mass_relay.count<100,queue_size:5,queue_complete:()=>100-t.space.mass_relay.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?1e7:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?7500:0,Adamantite:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?18e3:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?125:0,Stanene:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?1e5:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?25e3:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0);if(a<100){let e=100-a;return`
                ${z("space_dwarf_mass_relay_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                `}return $t.spc_dwarf.m_relay.effect()},action(){return!!(t.space.mass_relay.count<100&&ri($(this)[0]))&&(t.space.mass_relay.count++,t.space.mass_relay.count>=100&&(t.tech.outer=6,t.space.m_relay={count:1,on:1,charged:0},Qr(),Lt(),_s()),!0)}},m_relay:{id:"space-m_relay",title:z("space_dwarf_mass_relay_title"),desc:()=>`
                ${z("space_dwarf_mass_relay_title")}
                ${z("requires_power")}
                `,reqs:{outer:6},path:["truepath"],condition:()=>t.space.mass_relay.count>=100,wiki:!1,queue_complete:()=>0,cost:{},powered:()=>As(100),effect(){let e=Math.floor(t.space.m_relay.charged/10)/10;return`
                ${z("space_dwarf_mass_relay_effect2",[Ut().dwarf])}
                ${z("minus_power",[$(this)[0].powered()])}
                ${z("space_dwarf_mass_relay_charged",[e])}
                `},action:()=>!1}},spc_titan:We().spc_titan,spc_enceladus:We().spc_enceladus,spc_triton:We().spc_triton,spc_kuiper:We().spc_kuiper,spc_eris:We().spc_eris},xt={int_alpha:{info:{name:z("interstellar_alpha_name"),desc:()=>t.tech.alpha?z("interstellar_alpha_desc2",[Ki[t.race.species].home]):z("interstellar_alpha_desc1",[Ki[t.race.species].home]),support:"starport"},alpha_mission:{id:"interstellar-alpha_mission",title:z("space_mission_title",[z("interstellar_alpha_name")]),desc:z("space_mission_desc",[z("interstellar_alpha_name")]),reqs:{ftl:2},grant:["alpha",1],queue_complete:()=>t.tech.alpha>=1?0:1,cost:{Helium_3:()=>+Ht(4e4).toFixed(0)},effect:z("interstellar_alpha_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("interstellar_alpha_mission_result"),"info",!1,["progress"]),t.interstellar.nexus={count:0,on:0,support:0,s_max:0},t.interstellar.warehouse={count:0},!0)}},starport:{id:"interstellar-starport",title:z("interstellar_alpha_starport_title"),desc:()=>`
                ${z("interstellar_alpha_starport_desc")}
                ${z("requires_power_space",[t.resource.Food.name])}
                `,reqs:{alpha:1},cost:{Money:e=>Ps("starport",e,1e6,1.3,"interstellar"),Aluminium:e=>Ps("starport",e,4e5,1.3,"interstellar"),Neutronium:e=>Ps("starport",e,1e3,1.3,"interstellar"),Elerium:e=>Ps("starport",e,100,1.3,"interstellar")},effect(){let e=+Ht(5).toFixed(2);return`
                ${z("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
                ${z("interstellar_alpha_starport_effect2",[e,$(this)[0].powered()])}
                ${z("interstellar_alpha_starport_effect3",[100,t.resource.Food.name])}
                `},support:()=>5,powered:()=>As(10),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("starport","interstellar"),t.settings.space.proxima=!0,t.settings.space.nebula=!0,Yr($(this)[0]),1===t.tech.alpha&&(t.tech.alpha=2,t.interstellar.mining_droid={count:0,on:0,adam:0,uran:0,coal:0,alum:0}),t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+100&&(t.race.orbit_decay=t.stats.days+100,hs(z("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0)}},habitat:{id:"interstellar-habitat",title:z("interstellar_habitat_title"),desc:`
                ${z("interstellar_habitat_desc")}
                ${z("requires_power")}
                `,reqs:{alpha:3},cost:{Money:e=>Ps("habitat",e,8e5,1.25,"interstellar"),Furs:e=>Ps("habitat",e,38e3,1.25,"interstellar"),Adamantite:e=>Ps("habitat",e,3200,1.25,"interstellar"),Plywood:e=>Ps("habitat",e,1e4,1.25,"interstellar"),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return`
                ${z("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
                ${z("plus_max_citizens",[e])}, ${z("minus_power",[$(this)[0].powered()])}
                `},support:()=>1,powered:()=>As(2),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],action(){return!!ri($(this)[0])&&(Ft("habitat","interstellar"),Yr($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens()),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},mining_droid:{id:"interstellar-mining_droid",title:z("interstellar_mining_droid_title"),desc:`
                ${z("interstellar_mining_droid_title")}
                ${z("space_support",[z("interstellar_alpha_name")])}
                `,reqs:{alpha:2},cost:{Money:e=>Ps("mining_droid",e,65e4,1.28,"interstellar"),Steel:e=>Ps("mining_droid",e,12e4,1.28,"interstellar"),Nano_Tube:e=>Ps("mining_droid",e,75e3,1.28,"interstellar"),Elerium:e=>Ps("mining_droid",e,50,1.28,"interstellar")},effect:()=>`
                ${z("space_used_support",[z("interstellar_alpha_name")])}
                ${z("interstellar_mining_droid_effect")}
                `,support:()=>-1,powered:()=>As(1),special:!0,refresh:!0,action(){return!!ri($(this)[0])&&(Ft("mining_droid","interstellar"),t.resource.Adamantite.display=!0,t.interstellar.starport.support${z("interstellar_processing_title")}
                ${z("space_support",[z("interstellar_alpha_name")])}
                `,reqs:{droids:1},cost:{Money:e=>Ps("processing",e,35e4,1.28,"interstellar"),Iron:e=>Ps("processing",e,18e4,1.28,"interstellar"),Aluminium:e=>Ps("processing",e,6e4,1.28,"interstellar"),Iridium:e=>Ps("processing",e,5e3,1.28,"interstellar")},effect(){let e=12;return t.tech.ai_core&&t.tech.ai_core>=2&&s.citadel>0&&(e+=2*s.citadel),`
                ${z("space_used_support",[z("interstellar_alpha_name")])}
                ${z("interstellar_processing_effect",[e])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("processing","interstellar"),t.interstellar.starport.support`
                ${z("interstellar_fusion_title")}
                ${z("requires_power_support_combo",[z("interstellar_alpha_name"),t.resource.Deuterium.name])}
                `,reqs:{fusion:1},cost:{Money:e=>Ps("fusion",e,99e4,1.28,"interstellar"),Iridium:e=>Ps("fusion",e,44e3,1.28,"interstellar"),Infernite:e=>Ps("fusion",e,350,1.28,"interstellar"),Brick:e=>Ps("fusion",e,18e3,1.28,"interstellar")},effect(){return`
                ${z("space_used_support",[z("interstellar_alpha_name")])}
                ${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${z("interstellar_fusion_effect",[1.25])}
                `},support:()=>-1,powered:()=>Fs(-22),p_fuel:()=>({r:"Deuterium",a:1.25}),action(){return!!ri($(this)[0])&&(Ft("fusion","interstellar"),t.interstellar.starport.support"magic"===t.race.universe?z("tech_sanctum"):z("interstellar_laboratory_title"),desc:`
                ${z("magic"===t.race.universe?"tech_sanctum":"interstellar_laboratory_title")}
                ${z("space_support",[z("interstellar_alpha_name")])}
                `,reqs:{science:12},cost:{Money:e=>Ps("laboratory",e,75e4,1.28,"interstellar"),Crystal:e=>"magic"===t.race.universe?Ps("laboratory",e,1200,1.28,"interstellar"):0,Titanium:e=>Ps("laboratory",e,12e4,1.28,"interstellar"),Alloy:e=>Ps("laboratory",e,95e3,1.28,"interstellar"),Mythril:e=>Ps("laboratory",e,8500,1.28,"interstellar")},effect(){let e=1e4;t.tech.science>=15&&(e*=1+.02*(t.race.cataclysm||t.race.orbit_decayed?n.exotic_lab:t.city.wardenclyffe.count)),(t.race.cataclysm||t.race.orbit_decayed&&s.s_gate&&o.scavenger)&&(e*=1+o.scavenger*+(.75*Mt("gxy_alien2")).toFixed(1)),t.tech.science>=21&&(e*=1.45),e=Math.round(e);let a="";t.tech.science>=16&&(a=`
                ${z("city_wardenclyffe_effect1",[ta(1),t.civic.scientist.name])}
                `);let r=`
                ${z("space_used_support",[z("interstellar_alpha_name")])}
                ${a}
                ${z("city_max_knowledge",[e])}
                `;return t.tech.science>=13&&(r+=`
                ${z("interstellar_laboratory_effect",[5])}
                `),"magic"===t.race.universe&&(r+=`
                ${z("plus_max_resource",[br(12),t.resource.Mana.name])}
                `),r},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("laboratory","interstellar"),t.interstellar.starport.support${z("interstellar_exchange_title")}
                ${z("space_support",[z("interstellar_alpha_name")])}
                `,reqs:{banking:12},cost:{Money:e=>Ps("exchange",e,68e4,1.28,"interstellar"),Stone:e=>Ps("exchange",e,115e3,1.28,"interstellar"),Adamantite:e=>Ps("exchange",e,55e3,1.28,"interstellar"),Graphene:e=>Ps("exchange",e,78e3,1.28,"interstellar")},effect(){let e=t.race.cataclysm||t.race.orbit_decayed?s.spaceport:t.city.bank?t.city.bank.count:0,a=t.race.cataclysm||t.race.orbit_decayed?4*bi():bi(),r=br(t.city.bank?a*e/18:0);return t.race.inflation&&(r*=2),t.tech.banking>=13&&(t.galaxy.freighter&&(r*=1+.03*o.freighter),t.galaxy.super_freighter&&(r*=1+.08*o.super_freighter)),r=+r.toFixed(0),`
                ${z("space_used_support",[z("interstellar_alpha_name")])}
                ${z("plus_max_resource",[`$${r.toLocaleString()}`,z("resource_Money_name")])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("exchange","interstellar"),t.interstellar.starport.support${z("interstellar_g_factory_title")}
                ${z("space_support",[z("interstellar_alpha_name")])}
                `,reqs:{graphene:1},cost:{Money:e=>Ps("g_factory",e,95e4,1.28,"interstellar"),Copper:e=>Ps("g_factory",e,165e3,1.28,"interstellar"),Cement:e=>Ps("g_factory",e,22e4,1.28,"interstellar"),Infernite:e=>Ps("g_factory",e,750,1.28,"interstellar")},effect:()=>`
                ${z("space_used_support",[z("interstellar_alpha_name")])}
                ${z("interstellar_g_factory_effect")}
                `,support:()=>-1,powered:()=>As(1),special:!0,action(){return!!ri($(this)[0])&&(Ft("g_factory","interstellar"),t.resource.Graphene.display=!0,t.interstellar.starport.support`
                ${z("interstellar_int_factory_title")}
                ${z("requires_power_combo",[t.resource.Deuterium.name])}
                `,reqs:{alpha:4},cost:{Money:e=>Ps("int_factory",e,25e6,1.26,"interstellar"),Coal:e=>Ps("int_factory",e,1e7,1.26,"interstellar"),Brick:e=>Ps("int_factory",e,75e4,1.26,"interstellar"),Bolognium:e=>Ps("int_factory",e,5e4,1.26,"interstellar")},effect(){let e=+Ht(5).toFixed(2);return`
                ${z("interstellar_int_factory_effect")}
                ${z("city_crafted_mats",[10])}
                ${z("interstellar_fusion_effect",[e])} ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(5),special:!0,action(){return!!ri($(this)[0])&&(Ft("int_factory","interstellar"),Yr($(this)[0])&&(t.city.factory.Alloy+=2,ki()),!0)}},luxury_condo:{id:"interstellar-luxury_condo",title:z("tech_luxury_condo"),desc:`
                ${z("tech_luxury_condo")}
                ${z("requires_power")}
                `,reqs:{alpha:5},cost:{Money:e=>Ps("luxury_condo",e,25e6,1.25,"interstellar"),Neutronium:e=>Ps("luxury_condo",e,75e3,1.25,"interstellar"),Stanene:e=>Ps("luxury_condo",e,23e4,1.25,"interstellar"),Orichalcum:e=>Ps("luxury_condo",e,65e3,1.25,"interstellar"),Nanoweave:e=>Ps("luxury_condo",e,12500,1.25,"interstellar"),Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens(),t=br(75e4);return`
                ${z("plus_max_citizens",[e])}, ${z("minus_power",[$(this)[0].powered()])}
                ${z("plus_max_resource",[`$${t.toLocaleString()}`,z("resource_Money_name")])}
                `},powered:()=>As(3),action(){return!!ri($(this)[0])&&(Ft("luxury_condo","interstellar"),Yr($(this)[0])&&(t.resource[t.race.species].max+=2),!0)},citizens(){let e=2;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},zoo:{id:"interstellar-zoo",title:z("tech_zoo"),desc:()=>`
                ${z("tech_zoo")}
                ${z("requires_power_support_combo",[z("interstellar_alpha_name"),t.resource.Food.name])}
                `,reqs:{zoo:1},cost:{Money:e=>Ps("zoo",e,5e7,1.24,"interstellar"),Polymer:e=>Ps("zoo",e,6e6,1.24,"interstellar"),Infernite:e=>Ps("zoo",e,75e3,1.24,"interstellar"),Brick:e=>Ps("zoo",e,2e6,1.24,"interstellar")},effect:()=>`
                ${z("space_used_support",[z("interstellar_alpha_name")])}
                ${z("space_red_vr_center_effect1",[5])}
                ${z("space_red_vr_center_effect2",[2])}
                ${z("interstellar_alpha_starport_effect3",[12e3,t.resource.Food.name])}
                `,powered:()=>As(3),action(){return!!ri($(this)[0])&&(Ft("zoo","interstellar"),t.interstellar.starport.supportt.tech.storage<=2?z("city_shed_title1"):t.tech.storage>=4?z("city_shed_title3"):z("city_shed_title2"),desc(){let e=t.tech.storage>=3?t.tech.storage>=4?z("city_shed_desc_size3"):z("city_shed_desc_size2"):z("city_shed_desc_size1");return z("city_shed_desc",[e])},reqs:{alpha:2},cost:{Money:e=>Ps("warehouse",e,175e3,1.28,"interstellar"),Lumber:e=>Ps("warehouse",e,1e5,1.28,"interstellar"),Aluminium:e=>Ps("warehouse",e,12e4,1.28,"interstellar"),Cement:e=>Ps("warehouse",e,45e3,1.28,"interstellar")},res(){let e=["Lumber","Stone","Chrysotile","Furs","Copper","Iron","Aluminium","Cement","Coal","Nano_Tube","Neutronium","Adamantite","Infernite"];return t.tech.storage>=3&&t.resource.Steel.display&&e.push("Steel"),t.tech.storage>=4&&t.resource.Titanium.display&&e.push("Titanium"),e},val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 750;case"Furs":return 425;case"Copper":return 380;case"Iron":return 350;case"Aluminium":return 320;case"Cement":return 280;case"Coal":return 120;case"Steel":return 60;case"Titanium":return 40;case"Nano_Tube":return 30;case"Neutronium":return 8;case"Adamantite":return 18;case"Infernite":return 5;default:return 0}},wide:!0,effect(){let e='
                ',a=Gr();for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${z("plus_max_resource",[x(+(br($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return e+="
                ",e},action(){if(ri($(this)[0])){Ft("warehouse","interstellar");let e=Gr();for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=br($(this)[0].val(a)*e));return!0}return!1}}},int_proxima:{info:{name:z("interstellar_proxima_name"),desc:()=>t.tech.proxima?z("interstellar_proxima_desc2"):z("interstellar_proxima_desc1")},proxima_mission:{id:"interstellar-proxima_mission",title:z("space_mission_title",[z("interstellar_proxima_name")]),desc:z("space_mission_desc",[z("interstellar_proxima_name")]),reqs:{alpha:1},grant:["proxima",1],queue_complete:()=>t.tech.proxima>=1?0:1,cost:{Helium_3:()=>+Ht(42e3).toFixed(0)},effect:z("interstellar_proxima_mission_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.xfer_station={count:0,on:0},hs(z("interstellar_proxima_mission_result"),"info",!1,["progress"]),!0)}},xfer_station:{id:"interstellar-xfer_station",title:z("interstellar_xfer_station_title"),desc:()=>`
                ${z("interstellar_xfer_station_desc")}
                ${z("requires_power_combo",[t.resource.Uranium.name])}
                `,reqs:{proxima:1},cost:{Money:e=>Ps("xfer_station",e,12e5,1.28,"interstellar"),Neutronium:e=>Ps("xfer_station",e,1500,1.28,"interstellar"),Adamantite:e=>Ps("xfer_station",e,6e3,1.28,"interstellar"),Polymer:e=>Ps("xfer_station",e,12e3,1.28,"interstellar"),Wrought_Iron:e=>Ps("xfer_station",e,3500,1.28,"interstellar")},effect(){let e=br(5e3),a=br(4e3),r=br(2500),i="";return t.resource.Deuterium.display&&(i=`
                ${z("plus_max_resource",[br(2e3),z("resource_Deuterium_name")])}
                `),`
                ${z("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
                ${z("plus_max_resource",[a,z("resource_Oil_name")])}
                ${z("plus_max_resource",[e,z("resource_Helium_3_name")])}
                ${z("plus_max_resource",[r,z("resource_Uranium_name")])}
                ${i}
                ${z("city_fission_power_effect",[.28])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},support:()=>1,powered:()=>As(1),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("xfer_station","interstellar"),Yr($(this)[0])&&(t.resource.Uranium.max+=br(2500),t.resource.Helium_3.max+=br(5e3),t.resource.Oil.max+=br(4e3),t.resource.Deuterium.max+=br(2e3)),1===t.tech.proxima&&(t.tech.proxima=2,t.interstellar.cargo_yard={count:0}),!0)}},cargo_yard:{id:"interstellar-cargo_yard",title:z("interstellar_cargo_yard_title"),desc:z("interstellar_cargo_yard_title"),reqs:{proxima:2},cost:{Money:e=>Ps("cargo_yard",e,275e3,1.28,"interstellar"),Graphene:e=>Ps("cargo_yard",e,7500,1.28,"interstellar"),Mythril:e=>Ps("cargo_yard",e,6e3,1.28,"interstellar")},effect(){let e=br(200),a=br(150),r=`
                ${z("plus_max_resource",[50,z("resource_Crates_name")])}
                ${z("plus_max_resource",[50,z("resource_Containers_name")])}
                `;return r+=`
                ${z("plus_max_resource",[e,z("resource_Neutronium_name")])}
                ${z("plus_max_resource",[a,z("resource_Infernite_name")])}
                `,t.tech.storage>=7&&(r+=`
                ${z("interstellar_cargo_yard_effect",[+_.toFixed(3)])}
                `),r},action(){return!!ri($(this)[0])&&(Ft("cargo_yard","interstellar"),!0)}},cruiser:{id:"interstellar-cruiser",title:z("interstellar_cruiser_title"),desc:z("interstellar_cruiser_title"),reqs:{cruiser:1},cost:{Money:e=>Ps("cruiser",e,875e3,1.28,"interstellar"),Aluminium:e=>Ps("cruiser",e,195e3,1.28,"interstellar"),Deuterium:e=>Ps("cruiser",e,+Ht(1500).toFixed(0),1.28,"interstellar"),Neutronium:e=>Ps("cruiser",e,2e3,1.28,"interstellar"),Aerogel:e=>Ps("cruiser",e,250,1.28,"interstellar"),Horseshoe:()=>t.race.hooved?3:0},powered:()=>As(1),effect(){let e=+Ht(6).toFixed(2);return`
                ${z("plus_max_soldiers",[ta(3)])}
                ${z("space_belt_station_effect3",[e])}
                `},action(){return!!ri($(this)[0])&&(Ft("cruiser","interstellar"),t.interstellar.cruiser.on++,!0)}},dyson:{id:"interstellar-dyson",title:z("interstellar_dyson_title"),desc:e=>!t.interstellar.hasOwnProperty("dyson")||t.interstellar.dyson.count<100||e?`
                ${z("interstellar_dyson_title")}
                ${z("requires_segmemts",[100])}
                `:`
                ${z("interstellar_dyson_title")}
                `,reqs:{proxima:3},queue_size:10,queue_complete:()=>100-t.interstellar.dyson.count,condition:()=>!(t.interstellar.dyson.count>=100&&t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?25e4:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?1e4:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?25:0,Stanene:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?1e5:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0);if(a<100){let e=a>0?`
                ${z("space_dwarf_reactor_effect1",[Fs(1.25*a)])}
                `:"",t=100-a;return`
                ${z("interstellar_dyson_effect")}
                ${e}
                ${z("space_dwarf_collider_effect2",[t])}
                `}return z("interstellar_dyson_complete",[Fs(175)])},action(){return!!(ri($(this)[0])&&t.interstellar.dyson.count<100)&&(Ft("dyson","interstellar"),t.interstellar.dyson.count>=100&&Qr(),!0)}},dyson_sphere:{id:"interstellar-dyson_sphere",title:z("interstellar_dyson_sphere_title"),desc:e=>!t.interstellar.hasOwnProperty("dyson_sphere")||t.interstellar.dyson_sphere.count<100||e?`
                ${z("interstellar_dyson_sphere_title")}
                ${z("requires_segmemts",[100])}
                `:`
                ${z("interstellar_dyson_sphere_title")}
                `,reqs:{proxima:3,dyson:1},queue_size:10,queue_complete:()=>100-t.interstellar.dyson_sphere.count,condition:()=>!!(t.interstellar.dyson.count>=100&&t.tech.dyson&&1===t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?5e6:0,Bolognium:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?25e3:0,Vitreloy:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?1250:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0);if(a<100){let e=175+5*a,t=100-a;return`
                ${z("interstellar_dyson_sphere_effect")}
                ${z("space_dwarf_reactor_effect1",[Fs(e)])}
                ${z("space_dwarf_collider_effect2",[t])}
                `}return z("interstellar_dyson_sphere_complete",[Fs(750)])},action(){return!!(ri($(this)[0])&&t.interstellar.dyson_sphere.count<100)&&(Ft("dyson_sphere","interstellar"),t.interstellar.dyson_sphere.count>=100&&Qr(),!0)}},orichalcum_sphere:{id:"interstellar-orichalcum_sphere",title:z("interstellar_dyson_sphere_title"),desc:e=>!t.interstellar.hasOwnProperty("orichalcum_sphere")||t.interstellar.orichalcum_sphere.count<100||e?`
                ${z("interstellar_orichalcum_sphere_desc")}
                ${z("requires_segmemts",[100])}
                `:`
                ${z("interstellar_orichalcum_sphere_desc")}
                `,reqs:{proxima:3,dyson:2},queue_size:10,queue_complete:()=>100-t.interstellar.orichalcum_sphere.count,condition:()=>!!(t.interstellar.dyson_sphere.count>=100&&t.tech.dyson&&2===t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0)<100?25e6:0,Orichalcum:e=>(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0);if(a<100){let e=750+8*a,t=100-a;return`
                ${z("interstellar_orichalcum_sphere_effect")}
                ${z("space_dwarf_reactor_effect1",[Fs(e)])}
                ${z("space_dwarf_collider_effect2",[t])}
                `}return z("interstellar_dyson_sphere_complete",[Fs(1750)])},action(){return!!(ri($(this)[0])&&t.interstellar.orichalcum_sphere.count<100)&&(Ft("orichalcum_sphere","interstellar"),t.interstellar.orichalcum_sphere.count>=100&&qn("blacken_the_sun"),!0)}}},int_nebula:{info:{name:z("interstellar_nebula_name"),desc:()=>t.tech.nebula?z("interstellar_nebula_desc2"):z("interstellar_nebula_desc1"),support:"nexus"},nebula_mission:{id:"interstellar-nebula_mission",title:z("space_mission_title",[z("interstellar_nebula_name")]),desc:z("space_mission_desc",[z("interstellar_nebula_name")]),reqs:{alpha:1},grant:["nebula",1],queue_complete:()=>t.tech.nebula>=1?0:1,cost:{Helium_3:()=>+Ht(55e3).toFixed(0)},effect:z("interstellar_nebula_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("interstellar_nebula_mission_result"),"info",!1,["progress"]),!0)}},nexus:{id:"interstellar-nexus",title:z("interstellar_nexus_title"),desc:()=>`
                ${z("interstellar_nexus_title")}
                ${z("requires_power_combo",[t.resource.Money.name])}
                `,reqs:{nebula:1},cost:{Money:e=>Ps("nexus",e,9e5,1.24,"interstellar"),Adamantite:e=>Ps("nexus",e,7500,1.24,"interstellar"),Infernite:e=>Ps("nexus",e,250,1.24,"interstellar"),Sheet_Metal:e=>Ps("nexus",e,14e3,1.24,"interstellar"),Nano_Tube:e=>Ps("nexus",e,17500,1.24,"interstellar")},effect(){let e=br(3500),t=br(4e3),a=br(3e3),r=br(25);return`
                ${z("interstellar_nexus_effect1",[$(this)[0].support()])}
                ${z("plus_max_resource",[e,z("resource_Oil_name")])}
                ${z("plus_max_resource",[t,z("resource_Helium_3_name")])}
                ${z("plus_max_resource",[a,z("resource_Deuterium_name")])}
                ${z("plus_max_resource",[r,z("resource_Elerium_name")])}
                ${z("interstellar_nexus_effect2",[$(this)[0].powered(),350])}
                `},support:()=>2,powered:()=>As(8),powerBalancer:()=>[{s:t.interstellar.nexus.s_max-t.interstellar.nexus.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("nexus","interstellar"),t.resource.Deuterium.display=!0,1===t.tech.nebula&&(t.interstellar.harvester={count:0,on:0},t.tech.nebula=2),Yr($(this)[0])&&(t.resource.Oil.max+=br(2500),t.resource.Helium_3.max+=br(4e3),t.resource.Deuterium.max+=br(3e3),t.resource.Elerium.max+=br(25)),!0)}},harvester:{id:"interstellar-harvester",title:z("interstellar_harvester_title"),desc:`
                ${z("interstellar_harvester_title")}
                ${z("space_support",[z("interstellar_nebula_name")])}
                `,reqs:{nebula:2},cost:{Money:e=>Ps("harvester",e,65e4,1.28,"interstellar"),Copper:e=>Ps("harvester",e,8e4,1.28,"interstellar"),Alloy:e=>Ps("harvester",e,45e3,1.28,"interstellar"),Iridium:e=>Ps("harvester",e,8e3,1.28,"interstellar")},effect(){let e=+$e("harvester","helium").toFixed(3),a=+$e("harvester","deuterium").toFixed(3),r=t.tech.ram_scoop?`
                ${z("interstellar_harvester_effect",[a])}
                `:"";return`
                ${z("space_used_support",[z("interstellar_nebula_name")])}
                ${z("space_gas_mining_effect1",[e])}
                ${r}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("harvester","interstellar"),t.interstellar.nexus.support${z("interstellar_elerium_prospector_title")}
                ${z("space_support",[z("interstellar_nebula_name")])}
                `,reqs:{nebula:3},cost:{Money:e=>Ps("elerium_prospector",e,825e3,1.28,"interstellar"),Steel:e=>Ps("elerium_prospector",e,18e3,1.28,"interstellar"),Polymer:e=>Ps("elerium_prospector",e,22e3,1.28,"interstellar"),Graphene:e=>Ps("elerium_prospector",e,82e3,1.28,"interstellar"),Stanene:e=>Ps("elerium_prospector",e,57e3,1.28,"interstellar")},effect(){let e=+$e("elerium_prospector").toFixed(3);return`
                ${z("space_used_support",[z("interstellar_nebula_name")])}
                ${z("space_belt_elerium_ship_effect2",[e])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("elerium_prospector","interstellar"),t.interstellar.nexus.supportt.tech.neutron?z("interstellar_neutron_desc2",[Ki[t.race.species].home]):z("interstellar_neutron_desc1")},neutron_mission:{id:"interstellar-neutron_mission",title:z("space_mission_title",[z("interstellar_neutron_name")]),desc:z("space_mission_desc",[z("interstellar_neutron_name")]),reqs:{nebula:1,high_tech:14},grant:["neutron",1],queue_complete:()=>t.tech.neutron>=1?0:1,cost:{Helium_3:()=>+Ht(6e4).toFixed(0),Deuterium:()=>+Ht(1e4).toFixed(0)},effect:z("interstellar_neutron_mission_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.neutron_miner={count:0,on:0},hs(z("interstellar_neutron_mission_result"),"info",!1,["progress"]),!0)}},neutron_miner:{id:"interstellar-neutron_miner",title:z("interstellar_neutron_miner_title"),desc:()=>`
                ${z("interstellar_neutron_miner_desc")}
                ${z("requires_power_combo",[t.resource.Helium_3.name])}
                `,reqs:{neutron:1},cost:{Money:e=>Ps("neutron_miner",e,1e6,1.32,"interstellar"),Titanium:e=>Ps("neutron_miner",e,45e3,1.32,"interstellar"),Stanene:e=>Ps("neutron_miner",e,88e3,1.32,"interstellar"),Elerium:e=>Ps("neutron_miner",e,20,1.32,"interstellar"),Aerogel:e=>Ps("neutron_miner",e,50,1.32,"interstellar")},effect(){let e=+$e("neutron_miner").toFixed(3),t=br(500),a=+Ht(3).toFixed(2);return`
                ${z("space_gas_moon_outpost_effect1",[e])}
                ${z("plus_max_resource",[t,z("resource_Neutronium_name")])}
                ${z("interstellar_alpha_starport_effect2",[a,$(this)[0].powered()])}
                `},powered:()=>As(6),powerBalancer:()=>[{r:"Neutronium",k:"lpmod"}],action(){return!!ri($(this)[0])&&(Ft("neutron_miner","interstellar"),Yr($(this)[0]),!0)}},citadel:{id:"interstellar-citadel",title:z("interstellar_citadel_title"),desc:`
                ${z("interstellar_citadel_desc")}
                ${z("requires_power")}
                `,reqs:{neutron:1,high_tech:15},cost:{Money:e=>Ps("citadel",e,5e6,1.25,"interstellar"),Knowledge:e=>Ps("citadel",e,15e5,1.15,"interstellar"),Graphene:e=>Ps("citadel",e,5e4,1.25,"interstellar"),Stanene:e=>Ps("citadel",e,1e5,1.25,"interstellar"),Elerium:e=>Ps("citadel",e,250,1.25,"interstellar"),Soul_Gem:e=>Ps("citadel",e,1,1.25,"interstellar")},wide:!0,effect(){let e=`
                ${z("interstellar_citadel_stat",[+_.toFixed(1)])}
                ${z("interstellar_citadel_effect",[5])}
                `;if(t.tech.ai_core){let a=+(_/1.75).toFixed(1);t.race.flier||(e+=`
                ${z("interstellar_citadel_effect2",[a])}
                `),t.tech.ai_core>=2&&(e+=`
                ${z("interstellar_citadel_effect3",[2])}
                `),t.tech.ai_core>=3&&(e+=`
                ${z("interstellar_citadel_effect4",[+(_/5).toFixed(1)])}
                `)}return`${e}
                ${z("interstellar_citadel_power",[$(this)[0].powered(),As(2.5)])}
                `},powered:()=>s.citadel&&s.citadel>1?As(30+2.5*(s.citadel-1)):As(30),action(){return!!ri($(this)[0])&&(Ft("citadel","interstellar"),Yr($(this)[0]),!0)},flair:()=>z("interstellar_citadel_flair")},stellar_forge:{id:"interstellar-stellar_forge",title:z("interstellar_stellar_forge_title"),desc:`
                ${z("interstellar_stellar_forge_title")}
                ${z("requires_power")}
                `,reqs:{star_forge:1},cost:{Money:e=>Ps("stellar_forge",e,12e5,1.25,"interstellar"),Iridium:e=>Ps("stellar_forge",e,25e4,1.25,"interstellar"),Bolognium:e=>Ps("stellar_forge",e,35e3,1.25,"interstellar"),Aerogel:e=>Ps("stellar_forge",e,75e3,1.25,"interstellar")},effect(){let e=`
                ${z("city_foundry_effect1",[ta(2)])}
                ${z("interstellar_stellar_forge_effect",[10])}
                ${z("interstellar_stellar_forge_effect2",[5])}
                `;return t.tech.star_forge&&t.tech.star_forge>=2&&(e+=`
                ${z("interstellar_stellar_forge_effect3",[2])}
                `),`${e}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(3),special:!0,action(){return!!ri($(this)[0])&&(Ft("stellar_forge","interstellar"),Yr($(this)[0])&&t.tech.star_forge>=2&&(t.city.smelter.cap+=2,t.city.smelter.Star+=2,t.city.smelter.StarCap+=2,t.city.smelter.Iron+=2),!0)},flair:()=>z("interstellar_stellar_forge_flair")}},int_blackhole:{info:{name:z("interstellar_blackhole_name"),desc(){let e=Ki[t.race.species].home;if(t.tech.blackhole>=5){let a=+t.interstellar.stellar_engine.mass.toFixed(10),r=+t.interstellar.stellar_engine.exotic.toFixed(10);if(t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12)),t.tech.whitehole){let i=Gs("bigbang"),s="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                ${z("interstellar_blackhole_desc4",[e,a,r])}
                ${z("interstellar_blackhole_desc5",[i.plasmid,i.phage,i.dark,s])}
                `}return t.interstellar.stellar_engine.exotic>0?z("interstellar_blackhole_desc4",[e,a,r]):z("interstellar_blackhole_desc3",[e,a])}return t.tech.blackhole?z("interstellar_blackhole_desc2",[e]):z("interstellar_blackhole_desc1",[e])}},blackhole_mission:{id:"interstellar-blackhole_mission",title:z("space_mission_title",[z("interstellar_blackhole_name")]),desc:z("space_mission_desc",[z("interstellar_blackhole_name")]),reqs:{nebula:1},grant:["blackhole",1],queue_complete:()=>t.tech.blackhole>=1?0:1,cost:{Helium_3:()=>+Ht(75e3).toFixed(0),Deuterium:()=>+Ht(25e3).toFixed(0)},effect:z("interstellar_blackhole_mission_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.far_reach={count:0,on:0},hs(z("interstellar_blackhole_mission_result"),"info",!1,["progress"]),!0)}},far_reach:{id:"interstellar-far_reach",title:z("interstellar_far_reach"),desc:`
                ${z("interstellar_far_reach_desc")}
                ${z("requires_power")}
                `,reqs:{blackhole:1},cost:{Money:e=>Ps("far_reach",e,1e6,1.32,"interstellar"),Knowledge:e=>Ps("far_reach",e,1e5,1.32,"interstellar"),Neutronium:e=>Ps("far_reach",e,2500,1.32,"interstellar"),Elerium:e=>Ps("far_reach",e,100,1.32,"interstellar"),Aerogel:e=>Ps("far_reach",e,1e3,1.32,"interstellar")},effect(){return`
                ${z("interstellar_far_reach_effect",[1])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(5),action(){return!!ri($(this)[0])&&(Ft("far_reach","interstellar"),Yr($(this)[0]),1===t.tech.blackhole&&(t.tech.blackhole=2,Qr()),!0)},flair:z("interstellar_far_reach_flair")},stellar_engine:{id:"interstellar-stellar_engine",title:z("interstellar_stellar_engine"),desc:e=>!t.interstellar.hasOwnProperty("stellar_engine")||t.interstellar.stellar_engine.count<100||e?`
                ${z("interstellar_stellar_engine")}
                ${z("requires_segmemts",[100])}
                `:`
                ${z("interstellar_stellar_engine")}
                `,reqs:{blackhole:3},queue_size:10,queue_complete:()=>100-t.interstellar.stellar_engine.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?5e5:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?450:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?17500:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?225:0,Graphene:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?45e3:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?250:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?75:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0);if(a<100){let e=100-a;return`
                ${z("interstellar_stellar_engine_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                `}{let e=t.tech.gravity&&t.tech.gravity>=2?13.5:7.5,a=t.interstellar.stellar_engine?t.interstellar.stellar_engine.mass:8;t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12));let r=Fs(+(20+(a-8)*e+(t.interstellar.stellar_engine?t.interstellar.stellar_engine.exotic:0)*e*10).toFixed(2));if(t.tech.blackhole>=5){let e=+t.interstellar.stellar_engine.exotic.toFixed(10),i=t.interstellar.stellar_engine.exotic>0?z("interstellar_stellar_engine_effect3",[a,e]):z("interstellar_stellar_engine_effect2",[a]);return`
                ${z("interstellar_stellar_engine_complete",[r])}
                ${i}
                `}return z("interstellar_stellar_engine_complete",[r])}},action(){return!!(ri($(this)[0])&&t.interstellar.stellar_engine.count<100)&&(Ft("stellar_engine","interstellar"),t.interstellar.stellar_engine.count>=100&&3===t.tech.blackhole&&(t.tech.blackhole=4,Qr()),!0)}},mass_ejector:{id:"interstellar-mass_ejector",title:z("interstellar_mass_ejector"),desc:`
                ${z("interstellar_mass_ejector")}
                ${z("requires_power")}
                `,reqs:{blackhole:5},cost:{Money:e=>Ps("mass_ejector",e,75e4,1.25,"interstellar"),Adamantite:e=>Ps("mass_ejector",e,125e3,1.25,"interstellar"),Infernite:e=>Ps("mass_ejector",e,275,1.25,"interstellar"),Elerium:e=>Ps("mass_ejector",e,100,1.25,"interstellar"),Mythril:e=>Ps("mass_ejector",e,1e4,1.25,"interstellar")},effect(){return`
                ${z("interstellar_mass_ejector_effect")}, ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(3),special:!0,sAction(){t.settings.civTabs=4,t.settings.marketTabs=2,t.settings.tabLoad||(kt("mTabResource"),_s("interstellar-mass_ejector"))},action(){return!!ri($(this)[0])&&(0===t.interstellar.mass_ejector.count&&hs(z("interstellar_mass_ejector_msg"),"info",!1,["progress"]),t.settings.showEjector=!0,Ft("mass_ejector","interstellar"),Yr($(this)[0]),Ss($("#resources")),Da(),!0)},flair:()=>z("interstellar_mass_ejector_flair")},jump_ship:{id:"interstellar-jump_ship",title:z("interstellar_jump_ship"),desc:z("interstellar_jump_ship_desc"),reqs:{stargate:1},grant:["stargate",2],queue_complete:()=>t.tech.stargate>=2?0:1,cost:{Money:()=>2e7,Copper:()=>24e5,Aluminium:()=>4e6,Titanium:()=>125e4,Adamantite:()=>75e4,Stanene:()=>9e5,Aerogel:()=>1e5},effect:z("interstellar_jump_ship_effect"),action(){return!!ri($(this)[0])}},wormhole_mission:{id:"interstellar-wormhole_mission",title:z("space_mission_title",[z("interstellar_wormhole_name")]),desc:z("space_mission_desc",[z("interstellar_wormhole_name")]),reqs:{stargate:2},grant:["stargate",3],queue_complete:()=>t.tech.stargate>=3?0:1,cost:{Helium_3:()=>+Ht(15e4).toFixed(0),Deuterium:()=>+Ht(75e3).toFixed(0)},effect:z("interstellar_wormhole_mission_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.stargate={count:0},t.galaxy.gateway_station={count:0,on:0},hs(z("interstellar_wormhole_mission_result"),"info",!1,["progress"]),!0)}},stargate:{id:"interstellar-stargate",title:z("interstellar_stargate"),desc:e=>!t.interstellar.hasOwnProperty("stargate")||t.interstellar.stargate.count<200||e?`
                ${z("interstellar_stargate")}
                ${z("requires_segmemts",[200])}
                `+(t.interstellar.hasOwnProperty("stargate")&&t.interstellar.stargate.count>=200?`
                ${z("requires_power")}
                `:""):`
                ${z("interstellar_stargate")}
                `,reqs:{stargate:3},condition:()=>!(t.interstellar.stargate.count>=200),queue_size:10,queue_complete:()=>200-t.interstellar.stargate.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?1e6:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?4800:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?666:0,Elerium:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?75:0,Nano_Tube:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?12e3:0,Stanene:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?6e4:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?3200:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0);if(a<200){let e=200-a;return`
                ${z("interstellar_stargate_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                `}return xt.int_blackhole.s_gate.effect()},action(){return!!(ri($(this)[0])&&t.interstellar.stargate.count<200)&&(Ft("stargate","interstellar"),t.interstellar.stargate.count>=200&&(t.tech.stargate=4,t.interstellar.s_gate={count:1,on:0},t.city.power>=xt.int_blackhole.s_gate.powered()&&t.interstellar.s_gate.on++,Kt(),_s()),!0)}},s_gate:{id:"interstellar-s_gate",title:z("interstellar_stargate"),desc:()=>`
                ${z("interstellar_stargate")}
                ${z("requires_power")}
                `,reqs:{stargate:4},condition:()=>t.interstellar.stargate.count>=200,wiki:!1,queue_complete:()=>0,cost:{},powered:()=>As(250),effect(){return`
                ${z("interstellar_s_gate_effect")}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action:()=>!1}},int_sirius:{info:{name:()=>t.tech.ascension>=3?z("interstellar_sirius_b_name"):z("interstellar_sirius_name"),desc:()=>t.tech.ascension>=3?z("interstellar_sirius_b_desc"):z("interstellar_sirius_desc",[Ki[t.race.species].home])},sirius_mission:{id:"interstellar-sirius_mission",title:z("space_mission_title",[z("interstellar_sirius_name")]),desc:z("space_mission_desc",[z("interstellar_sirius_name")]),reqs:{ascension:2},grant:["ascension",3],queue_complete:()=>t.tech.ascension>=3?0:1,cost:{Helium_3:()=>+Ht(48e4).toFixed(0),Deuterium:()=>+Ht(225e3).toFixed(0)},effect:()=>z("interstellar_sirius_mission_effect",[nn("name"),Ki[t.race.species].home]),action(){return!!ri($(this)[0])}},sirius_b:{id:"interstellar-sirius_b",title:z("interstellar_sirius_b"),desc:z("interstellar_sirius_b"),reqs:{ascension:3},grant:["ascension",4],queue_complete:()=>t.tech.ascension>=4?0:1,cost:{Knowledge:()=>2e7},effect:()=>z("interstellar_sirius_b_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.space_elevator={count:0},!0)}},space_elevator:{id:"interstellar-space_elevator",title:z("interstellar_space_elevator"),desc:e=>!t.interstellar.hasOwnProperty("space_elevator")||t.interstellar.space_elevator.count<100||e?`
                ${z("interstellar_space_elevator")}
                ${z("requires_segmemts",[100])}
                `:`
                ${z("interstellar_space_elevator")}
                `,reqs:{ascension:4},condition:()=>!(t.interstellar.space_elevator.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.space_elevator.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?2e7:0,Nano_Tube:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?5e5:0,Bolognium:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?1e5:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?125e3:0},effect(e){let a=`
                ${z("interstellar_space_elevator_effect")}
                `,r=(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0);return r<100&&(a+=`
                ${z("space_dwarf_collider_effect2",[100-r])}
                `),a},action(){return!!(ri($(this)[0])&&t.interstellar.space_elevator.count<100)&&(Ft("space_elevator","interstellar"),t.interstellar.space_elevator.count>=100&&(t.tech.ascension=5,t.interstellar.gravity_dome={count:0},Kt(),_s()),!0)}},gravity_dome:{id:"interstellar-gravity_dome",title:z("interstellar_gravity_dome"),desc:e=>!t.interstellar.hasOwnProperty("gravity_dome")||t.interstellar.gravity_dome.count<100||e?`
                ${z("interstellar_gravity_dome")}
                ${z("requires_segmemts",[100])}
                `:`
                ${z("interstellar_gravity_dome")}
                `,reqs:{ascension:5},condition:()=>!(t.interstellar.gravity_dome.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.gravity_dome.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?35e6:0,Cement:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?125e4:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?65e4:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?18e4:0},effect(e){let a=`
                ${z("interstellar_gravity_dome_effect",[Ki[t.race.species].home])}
                `,r=(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0);return r<100&&(a+=`
                ${z("space_dwarf_collider_effect2",[100-r])}
                `),a},action(){return!!(ri($(this)[0])&&t.interstellar.gravity_dome.count<100)&&(Ft("gravity_dome","interstellar"),t.interstellar.gravity_dome.count>=100&&(t.tech.ascension=6,t.interstellar.ascension_machine={count:0},t.interstellar.thermal_collector={count:0},Kt(),_s()),!0)}},ascension_machine:{id:"interstellar-ascension_machine",title:z("interstellar_ascension_machine"),desc:e=>!t.interstellar.hasOwnProperty("ascension_machine")||t.interstellar.ascension_machine.count<100||e?`
                ${z("interstellar_ascension_machine")}
                ${z("requires_segmemts",[100])}
                `+(t.interstellar.hasOwnProperty("ascension_machine")&&t.interstellar.ascension_machine.count>=100?`
                ${z("requires_power")}
                `:""):`
                ${z("interstellar_ascension_machine")}
                `,reqs:{ascension:6},condition:()=>!(t.interstellar.ascension_machine.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.ascension_machine.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e6:0,Alloy:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e4:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?1e3:0,Orichalcum:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?25e4:0,Nanoweave:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0);if(a<100){let e=100-a;return`
                ${z("interstellar_ascension_machine_effect",[nn("name")])}
                ${z("space_dwarf_collider_effect2",[e])}
                `}return xt.int_sirius.ascension_trigger.effect()},action(){return!!(ri($(this)[0])&&t.interstellar.ascension_machine.count<100)&&(Ft("ascension_machine","interstellar"),t.interstellar.ascension_machine.count>=100&&(t.tech.ascension=7,t.interstellar.ascension_trigger={count:1,on:0},Kt(),_s()),!0)}},ascension_trigger:{id:"interstellar-ascension_trigger",title:z("interstellar_ascension_machine"),desc:()=>`
                ${z("interstellar_ascension_machine")}
                ${z("requires_power")}
                `,wiki:!1,reqs:{ascension:7},condition:()=>t.interstellar.ascension_machine.count>=100,queue_complete:()=>0,cost:{},powered(){let e=100;if(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2){e+=t.stats.achieve.technophobe.l>=4?25:10;for(let a=1;a=5&&(e+=5)}let a=Math.round(As(1e4)-e*(t.interstellar.hasOwnProperty("thermal_collector")?t.interstellar.thermal_collector.count:0));return a<0&&(a=0),a},postPower(e){e?setTimeout((function(){t.tech.ascension=s.ascension_trigger?8:7,Kt()}),250):(t.tech.ascension=7,Kt())},effect(){let e=qt(),t=$(this)[0].powered(),a=t>0?`
                ${z("minus_power",[t])}
                `:"";return`
                ${z("interstellar_ascension_trigger_effect")}
                ${e}${a}`},action:()=>!1},ascend:{id:"interstellar-ascend",title:z("interstellar_ascend"),desc:z("interstellar_ascend"),reqs:{ascension:8},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=qt();return`
                ${z("interstellar_ascend_effect")}
                ${e}`},action(){return!!ri($(this)[0])&&(Qt(),!0)}},thermal_collector:{id:"interstellar-thermal_collector",title:z("interstellar_thermal_collector"),desc:z("interstellar_thermal_collector"),reqs:{ascension:6},cost:{Money:e=>Ps("thermal_collector",e,5e6,1.08,"interstellar"),Infernite:e=>Ps("thermal_collector",e,25e3,1.08,"interstellar"),Stanene:e=>Ps("thermal_collector",e,1e6,1.08,"interstellar"),Vitreloy:e=>Ps("thermal_collector",e,1e5,1.08,"interstellar")},effect(){let e=100;if(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2){e+=t.stats.achieve.technophobe.l>=4?25:10;for(let a=1;a=5&&(e+=5)}return z("interstellar_thermal_collector_effect",[e])},action(){return!!ri($(this)[0])&&(Ft("thermal_collector","interstellar"),!0)}}}};function qt(){let e=Gs("ascend"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                ${z("interstellar_ascension_trigger_effect2",[e.harmony,z("resource_Harmony_name")])}
                ${z("interstellar_ascension_trigger_effect3")}
                `}function Pt(){let e=Gs("terraform"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                ${z("interstellar_ascension_trigger_effect2",[e.harmony,z("resource_Harmony_name")])}
                ${z("space_terraformer_effect3")}
                `}const jt={gxy_gateway:{info:{name:z("galaxy_gateway"),desc:()=>z("galaxy_gateway_desc"),control:()=>({name:nn("name"),color:"success"}),support:"starbase"},gateway_mission:{id:"galaxy-gateway_mission",title:z("galaxy_gateway_mission"),desc:z("galaxy_gateway_mission"),reqs:{gateway:1},grant:["gateway",2],queue_complete:()=>t.tech.gateway>=2?0:1,cost:{Helium_3:()=>+Ht(212e3).toFixed(0),Deuterium:()=>+Ht(11e4).toFixed(0)},effect:z("galaxy_gateway_mission_effect"),action(){return!!ri($(this)[0])&&(St(),t.galaxy.defense={gxy_stargate:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_gateway:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_gorddon:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_alien1:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_alien2:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_chthonian:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0}},!0)}},starbase:{id:"galaxy-starbase",title:z("galaxy_starbase"),desc:()=>`
                ${z("galaxy_starbase")}
                ${z("requires_power_space",[t.resource.Food.name])}
                `,reqs:{gateway:2},cost:{Money:e=>Ps("starbase",e,42e5,1.25,"galaxy"),Elerium:e=>Ps("starbase",e,1e3,1.25,"galaxy"),Mythril:e=>Ps("starbase",e,9e4,1.25,"galaxy"),Graphene:e=>Ps("starbase",e,32e4,1.25,"galaxy"),Horseshoe:()=>t.race.hooved?5:0},effect(){let e=+Ht(25).toFixed(2),a=t.tech.marines>=2?ta(8):ta(5);return`
                ${z("galaxy_defense_platform_effect",[25])}
                ${z("galaxy_gateway_support",[$(this)[0].support()])}
                ${z("plus_max_soldiers",[a])}
                ${z("interstellar_alpha_starport_effect2",[e,$(this)[0].powered()])}
                ${z("interstellar_alpha_starport_effect3",[250,t.resource.Food.name])}
                `},support:()=>2,powered:()=>As(s.s_gate?12:0),powerBalancer:()=>[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("starbase","galaxy"),Yr($(this)[0]),2===t.tech.gateway&&(t.galaxy.bolognium_ship={count:0,on:0,crew:0},t.tech.gateway=3),!0)}},ship_dock:{id:"galaxy-ship_dock",title:z("galaxy_ship_dock"),desc:`
                ${z("galaxy_ship_dock")}
                ${z("requires_power")}
                `,reqs:{gateway:4},cost:{Money:e=>Ps("ship_dock",e,36e5,1.25,"galaxy"),Steel:e=>Ps("ship_dock",e,88e4,1.25,"galaxy"),Aluminium:e=>Ps("ship_dock",e,12e5,1.25,"galaxy"),Bolognium:e=>Ps("ship_dock",e,75e3,1.25,"galaxy")},effect(){return`
                ${z("galaxy_ship_dock_effect",[.25])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},support:()=>s.starbase?.25*s.starbase:0,powered:()=>As(s.s_gate?4:0),powerBalancer:()=>[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],action(){return!!ri($(this)[0])&&(Ft("ship_dock","galaxy"),Yr($(this)[0]),!0)}},bolognium_ship:{id:"galaxy-bolognium_ship",title:z("galaxy_bolognium_ship"),desc:()=>`
                ${z("galaxy_bolognium_ship_desc")}
                ${z("galaxy_starbase_support",[z("resource_Helium_3_name")])}
                `,reqs:{gateway:3},cost:{Money:e=>Ps("bolognium_ship",e,14e5,1.22,"galaxy"),Iron:e=>Ps("bolognium_ship",e,56e4,1.22,"galaxy"),Infernite:e=>Ps("bolognium_ship",e,1800,1.22,"galaxy"),Nano_Tube:e=>Ps("bolognium_ship",e,475e3,1.22,"galaxy")},effect(){let e=+$e("bolognium_ship").toFixed(3),a=+Ht($(this)[0].ship.helium).toFixed(2);return`
                ${z("gain",[e,z("resource_Bolognium_name")])}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                ${z("spend",[a,t.resource.Helium_3.name])}
                `},support:()=>-1,ship:{civ:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2,mil:()=>0,helium:5},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("bolognium_ship","galaxy"),t.resource.Bolognium.display=!0,t.civic.crew.display=!0,t.galaxy.starbase.support`
                ${z("galaxy_scout_ship")}
                ${z("galaxy_starbase_support",[z("resource_Helium_3_name")])}
                `,reqs:{andromeda:1},cost:{Money:e=>Ps("scout_ship",e,16e5,1.25,"galaxy"),Titanium:e=>Ps("scout_ship",e,325e3,1.25,"galaxy"),Graphene:e=>Ps("scout_ship",e,118e3,1.25,"galaxy"),Soul_Gem:e=>Ps("scout_ship",e,1,1.02,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2),a=t.tech.science>=17?`
                ${z("galaxy_scout_ship_effect2",[25])}
                `:"";return`
                ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                ${z("galaxy_scout_ship_effect")}
                ${a}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                ${z("spend",[e,t.resource.Helium_3.name])}
                `},support:()=>-1,ship:{civ:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,mil:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,helium:6,rating:()=>t.race.banana?7:10},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("scout_ship","galaxy"),t.galaxy.defense.gxy_gateway.scout_ship++,t.galaxy.starbase.support`
                ${z("galaxy_corvette_ship")}
                ${z("galaxy_starbase_support",[z("resource_Helium_3_name")])}
                `,reqs:{andromeda:2},cost:{Money:e=>Ps("corvette_ship",e,45e5,1.25,"galaxy"),Steel:e=>Ps("corvette_ship",e,175e4,1.25,"galaxy"),Infernite:e=>Ps("corvette_ship",e,16e3,1.25,"galaxy"),Bolognium:e=>Ps("corvette_ship",e,35e3,1.25,"galaxy"),Soul_Gem:e=>Ps("corvette_ship",e,1,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return`
                ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                ${z("spend",[e,t.resource.Helium_3.name])}
                `},support:()=>-1,ship:{civ:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2,mil:()=>t.race.high_pop?3*Ei.high_pop.vars()[0]:3,helium:10,rating:()=>t.race.banana?21:30},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("corvette_ship","galaxy"),t.galaxy.defense.gxy_gateway.corvette_ship++,t.galaxy.starbase.support`
                ${z("galaxy_frigate_ship")}
                ${z("galaxy_starbase_support",[z("resource_Helium_3_name")])}
                `,reqs:{andromeda:3},cost:{Money:e=>Ps("frigate_ship",e,18e6,1.25,"galaxy"),Elerium:e=>Ps("frigate_ship",e,1250,1.25,"galaxy"),Mythril:e=>Ps("frigate_ship",e,35e4,1.25,"galaxy"),Sheet_Metal:e=>Ps("frigate_ship",e,8e5,1.25,"galaxy"),Soul_Gem:e=>Ps("frigate_ship",e,2,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return`
                ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                ${z("spend",[e,t.resource.Helium_3.name])}
                `},support:()=>-2,ship:{civ:()=>t.race.high_pop?3*Ei.high_pop.vars()[0]:3,mil:()=>t.race.high_pop?5*Ei.high_pop.vars()[0]:5,helium:25,rating:()=>t.race.banana?56:80},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("frigate_ship","galaxy"),t.galaxy.defense.gxy_gateway.frigate_ship++,t.galaxy.starbase.support+1`
                ${z("galaxy_cruiser_ship")}
                ${z("galaxy_starbase_support",[z("resource_Deuterium_name")])}
                `,reqs:{andromeda:4},cost:{Money:e=>Ps("cruiser_ship",e,75e6,1.25,"galaxy"),Copper:e=>Ps("cruiser_ship",e,6e6,1.25,"galaxy"),Adamantite:e=>Ps("cruiser_ship",e,1e6,1.25,"galaxy"),Vitreloy:e=>Ps("cruiser_ship",e,75e4,1.25,"galaxy"),Elerium:e=>Ps("cruiser_ship",e,1800,1.25,"galaxy"),Soul_Gem:e=>Ps("cruiser_ship",e,5,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.deuterium).toFixed(2);return`
                ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                ${z("spend",[e,t.resource.Deuterium.name])}
                `},support:()=>-3,ship:{civ:()=>t.race.high_pop?6*Ei.high_pop.vars()[0]:6,mil:()=>t.race.high_pop?10*Ei.high_pop.vars()[0]:10,deuterium:25,rating:()=>t.race.banana?175:250},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("cruiser_ship","galaxy"),t.galaxy.defense.gxy_gateway.cruiser_ship++,t.galaxy.starbase.support+2`
                ${z("galaxy_dreadnought")}
                ${z("galaxy_starbase_support",[z("resource_Deuterium_name")])}
                `,reqs:{andromeda:5},cost:{Money:e=>Ps("dreadnought",e,225e6,1.25,"galaxy"),Neutronium:e=>Ps("dreadnought",e,25e4,1.25,"galaxy"),Bolognium:e=>Ps("dreadnought",e,15e5,1.25,"galaxy"),Vitreloy:e=>Ps("dreadnought",e,1e6,1.25,"galaxy"),Infernite:e=>Ps("dreadnought",e,4e5,1.25,"galaxy"),Aerogel:e=>Ps("dreadnought",e,8e5,1.25,"galaxy"),Soul_Gem:e=>Ps("dreadnought",e,25,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.deuterium).toFixed(2);return`
                ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                ${z("spend",[e,t.resource.Deuterium.name])}
                `},support:()=>-5,ship:{civ:()=>t.race.high_pop?10*Ei.high_pop.vars()[0]:10,mil:()=>t.race.high_pop?20*Ei.high_pop.vars()[0]:20,deuterium:80,rating:()=>t.race.banana?1260:1800},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("dreadnought","galaxy"),t.galaxy.defense.gxy_gateway.dreadnought++,t.galaxy.starbase.support+2t.tech.piracy?z("galaxy_stargate_desc_alt"):z("galaxy_stargate_desc"),control:()=>({name:nn("name"),color:"success"})},gateway_station:{id:"galaxy-gateway_station",title:z("galaxy_gateway_station"),desc:()=>`
                ${z("galaxy_gateway_station_desc")}
                ${z("requires_power")}
                `,reqs:{stargate:4},cost:{Money:e=>Ps("gateway_station",e,5e6,1.25,"galaxy"),Aluminium:e=>Ps("gateway_station",e,52e4,1.25,"galaxy"),Polymer:e=>Ps("gateway_station",e,35e4,1.25,"galaxy"),Neutronium:e=>Ps("gateway_station",e,17500,1.25,"galaxy")},effect(){let e=br(2e3),a=br(4500),r=br(50),i="";return t.tech.gateway&&t.tech.gateway>=2&&(i=`
                ${z("galaxy_gateway_support",[$(this)[0].support()])}
                `),`${i}
                ${z("plus_max_resource",[e,z("resource_Helium_3_name")])}
                ${z("plus_max_resource",[a,z("resource_Deuterium_name")])}
                ${z("plus_max_resource",[r,z("resource_Elerium_name")])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},support:()=>.5,powered:()=>As(s.s_gate?4:0),powerBalancer:()=>!t.galaxy.hasOwnProperty("starbase")&&[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("gateway_station","galaxy"),t.resource.Helium_3.max+=br(2e3),t.resource.Deuterium.max+=br(4500),4===t.tech.stargate&&(t.galaxy.telemetry_beacon={count:0,on:0},t.tech.stargate=5),Yr($(this)[0]),!0)}},telemetry_beacon:{id:"galaxy-telemetry_beacon",title:z("galaxy_telemetry_beacon"),desc:()=>`
                ${z("galaxy_telemetry_beacon")}
                ${z("requires_power")}
                `,reqs:{stargate:5},cost:{Money:e=>Ps("telemetry_beacon",e,225e4,1.25,"galaxy"),Copper:e=>Ps("telemetry_beacon",e,685e3,1.25,"galaxy"),Alloy:e=>Ps("telemetry_beacon",e,425e3,1.25,"galaxy"),Iridium:e=>Ps("telemetry_beacon",e,177e3,1.25,"galaxy")},effect(){let e=t.tech.telemetry?1200:800;t.tech.science>=17&&(e+=25*o.scout_ship);let a=s.telemetry_beacon?e*s.telemetry_beacon:0,r="";return t.tech.gateway&&t.tech.gateway>=2&&(r=`
                ${z("galaxy_gateway_support",[$(this)[0].support()])}
                `),`${r}
                ${z("galaxy_telemetry_beacon_effect1",[e])}
                ${z("galaxy_telemetry_beacon_effect2",[a])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},support:()=>t.tech.telemetry?.75:.5,powered:()=>As(s.s_gate?4:0),powerBalancer:()=>!t.galaxy.hasOwnProperty("starbase")&&[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],postPower(e){let a=e?s.telemetry_beacon+y():s.telemetry_beacon-y();a>t.galaxy.telemetry_beacon.count?a=t.galaxy.telemetry_beacon.count:a<0&&(a=0),s.telemetry_beacon=a,ai($(this)[0],"galaxy","telemetry_beacon")},action(){return!!ri($(this)[0])&&(Ft("telemetry_beacon","galaxy"),Yr($(this)[0])&&(t.resource.Knowledge.max+=1750),t.tech.gateway||(t.galaxy.starbase={count:0,on:0,support:0,s_max:0},t.settings.space.gateway=!0,t.tech.gateway=1,Dt()),!0)}},gateway_depot:{id:"galaxy-gateway_depot",title:z("galaxy_gateway_depot"),desc:`
                ${z("galaxy_gateway_depot")}
                `,reqs:{gateway:5},cost:{Money:e=>Ps("gateway_depot",e,4e6,1.25,"galaxy"),Neutronium:e=>Ps("gateway_depot",e,8e4,1.25,"galaxy"),Stanene:e=>Ps("gateway_depot",e,5e5,1.25,"galaxy"),Vitreloy:e=>Ps("gateway_depot",e,2500,1.25,"galaxy")},wide:!0,effect(){let e=t.tech.world_control?150:100,a=br(200),r=Ct(),i=x(+br(3e3*r).toFixed(0),1),s=x(+br(25e4*r).toFixed(0),1),n=x(+br(9001*r).toFixed(0),1),c=x(+br(6660*r).toFixed(0),1),o='
                ';return o+=`${z("plus_max_crates",[e])}${z("plus_max_containers",[e])}`,o+=`${z("plus_max_resource",[i,t.resource.Uranium.name])}`,o+=`${z("plus_max_resource",[s,t.resource.Nano_Tube.name])}`,o+=`${z("plus_max_resource",[n,t.resource.Neutronium.name])}`,o+=`${z("plus_max_resource",[c,t.resource.Infernite.name])}`,o+="
                ",`${o}
                ${z("galaxy_gateway_depot_effect",[a,z("resource_Elerium_name")])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(s.s_gate?10:0),action(){if(ri($(this)[0])){Ft("gateway_depot","galaxy");let e=Ct();return t.resource.Uranium.max+=br(3e3*e),t.resource.Nano_Tube.max+=br(25e4*e),t.resource.Neutronium.max+=br(9001*e),t.resource.Infernite.max+=br(6660*e),Yr($(this)[0]),!0}return!1}},defense_platform:{id:"galaxy-defense_platform",title:z("galaxy_defense_platform"),desc:()=>`
                ${z("galaxy_defense_platform")}
                ${z("requires_power")}
                `,reqs:{stargate:6},cost:{Money:e=>Ps("defense_platform",e,75e4,1.25,"galaxy"),Adamantite:e=>Ps("defense_platform",e,425e3,1.25,"galaxy"),Elerium:e=>Ps("defense_platform",e,800,1.25,"galaxy"),Vitreloy:e=>Ps("defense_platform",e,1250,1.25,"galaxy"),Wrought_Iron:e=>Ps("defense_platform",e,75e3,1.25,"galaxy")},effect(){return`
                ${z("galaxy_defense_platform_effect",[20])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(s.s_gate?5:0),postPower(e){Cs({el:"#gxy_stargate"},"update")},action(){return!!ri($(this)[0])&&(Ft("defense_platform","galaxy"),Yr($(this)[0]),!0)},post(){Cs({el:"#gxy_stargate"},"update")}}},gxy_gorddon:{info:{name:z("galaxy_gorddon"),desc:()=>z("galaxy_gorddon_desc"),control:()=>({name:Ki[t.galaxy.alien1.id].name,color:"advanced"})},gorddon_mission:{id:"galaxy-gorddon_mission",title:z("galaxy_gorddon_mission"),desc:z("galaxy_gorddon_mission_desc"),reqs:{xeno:2},grant:["xeno",3],queue_complete:()=>t.tech.xeno>=3?0:1,cost:{Structs:()=>({galaxy:{scout_ship:{s:"gxy_gateway",count:2,on:2},corvette_ship:{s:"gxy_gateway",count:1,on:1}}}),Helium_3:()=>+Ht(23e4).toFixed(0),Deuterium:()=>+Ht(125e3).toFixed(0)},effect:z("galaxy_gorddon_mission_effect"),action(){if(ri($(this)[0])){St(),t.galaxy.defense.gxy_gateway.scout_ship-=2,t.galaxy.defense.gxy_gorddon.scout_ship+=2,t.galaxy.defense.gxy_gateway.corvette_ship--,t.galaxy.defense.gxy_gorddon.corvette_ship++;let e=Ki[t.galaxy.alien1.id].name,a=Ki[t.galaxy.alien1.id].entity,r=Ki[t.galaxy.alien2.id].name;return hs(z("galaxy_gorddon_mission_result",[a,e,Ki[t.galaxy.alien2.id].entity,r]),"info",!1,["progress"]),!0}return!1}},embassy:{id:"galaxy-embassy",title:z("galaxy_embassy"),desc:()=>`
                ${z("galaxy_embassy")}
                ${z("requires_power_combo",[t.resource.Food.name])}
                `,reqs:{xeno:4},queue_complete:()=>1-t.galaxy.embassy.count,cost:{Money:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?3e7:0,Lumber:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?38e6:0,Stone:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?32e6:0,Furs:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?18e6:0,Wrought_Iron:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?6e6:0},effect(){let e="";return t.tech.xeno>=11&&(e=`
                ${z("plus_max_citizens",[$(this)[0].citizens()])}
                `),`
                ${z("galaxy_embassy_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
                ${e}
                ${z("interstellar_alpha_starport_effect3",[7500,t.resource.Food.name])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(s.s_gate?25:0),refresh:!0,action(){return!!(t.galaxy.embassy.count<1&&ri($(this)[0]))&&(Ft("embassy","galaxy"),Yr($(this)[0]),4===t.tech.xeno&&(t.tech.xeno=5,t.galaxy.freighter={count:0,on:0,crew:0},t.galaxy.trade={max:0,cur:0,f0:0,f1:0,f2:0,f3:0,f4:0,f5:0,f6:0,f7:0,f8:0},Ss($("#resources")),Da(),hs(z("galaxy_embassy_complete",[Ki[t.galaxy.alien1.id].name,Ki[t.galaxy.alien2.id].name]),"info",!1,["progress"])),!0)},citizens(){let e=20;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},dormitory:{id:"galaxy-dormitory",title:z("galaxy_dormitory"),desc:()=>`
                ${z("galaxy_dormitory")}
                ${z("requires_power")}
                `,reqs:{xeno:6},cost:{Money:e=>Ps("dormitory",e,1e7,1.25,"galaxy"),Furs:e=>Ps("dormitory",e,7e5,1.25,"galaxy"),Cement:e=>Ps("dormitory",e,12e5,1.25,"galaxy"),Plywood:e=>Ps("dormitory",e,85e3,1.25,"galaxy"),Horseshoe:()=>t.race.hooved?3:0},effect(){return`
                ${z("requires_res",[z("galaxy_embassy")])}
                ${z("plus_max_citizens",[$(this)[0].citizens()])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(3),action(){return!!ri($(this)[0])&&(Ft("dormitory","galaxy"),Yr($(this)[0]),!0)},citizens(){let e=3;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},symposium:{id:"galaxy-symposium",title:z("galaxy_symposium"),desc:()=>`
                ${z("galaxy_symposium")}
                ${z("requires_power")}
                `,reqs:{xeno:6},cost:{Money:e=>Ps("symposium",e,8e6,1.25,"galaxy"),Food:e=>t.race.ravenous?0:Ps("symposium",e,t.race.artifical?45e3:125e3,1.25,"galaxy"),Lumber:e=>Ps("symposium",e,46e4,1.25,"galaxy"),Brick:e=>Ps("symposium",e,261600,1.25,"galaxy")},effect(){let e="";return t.tech.xeno>=7&&(e=`
                ${z("galaxy_symposium_effect3",[+ke(300).toFixed(2)])}
                `),`
                ${z("galaxy_symposium_effect",[1750])}
                ${z("galaxy_symposium_effect2",[650])}
                ${e}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(4),action(){return!!ri($(this)[0])&&(Ft("symposium","galaxy"),Yr($(this)[0]),!0)}},freighter:{id:"galaxy-freighter",title:z("galaxy_freighter"),desc:()=>`
                ${z("galaxy_freighter")}
                ${z("galaxy_crew_fuel",[z("resource_Helium_3_name")])}
                `,reqs:{xeno:5},cost:{Money:e=>Ps("freighter",e,6e6,1.2,"galaxy"),Uranium:e=>Ps("freighter",e,1e4,1.2,"galaxy"),Adamantite:e=>Ps("freighter",e,46e4,1.2,"galaxy"),Stanene:e=>Ps("freighter",e,261600,1.2,"galaxy"),Bolognium:e=>Ps("freighter",e,66e3,1.2,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2),a="";return t.tech.banking>=13&&(a=`
                ${z("interstellar_exchange_boost",[3])}
                `),`
                ${z("galaxy_freighter_effect",[2,Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
                ${a}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("spend",[e,t.resource.Helium_3.name])}
                `},ship:{civ:()=>t.race.high_pop?3*Ei.high_pop.vars()[0]:3,mil:()=>0,helium:12},special:!0,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("freighter","galaxy"),t.galaxy.freighter.on++,t.resource.Vitreloy.display=!0,!0)}}},gxy_alien1:{info:{name:()=>z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),desc:()=>z("galaxy_alien1_desc",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home,Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),control:()=>({name:Ki[t.galaxy.alien1.id].name,color:"advanced"})},consulate:{id:"galaxy-consulate",title:z("galaxy_consulate"),desc:()=>z("galaxy_consulate_desc",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),reqs:{xeno:8},queue_complete:()=>1-t.galaxy.consulate.count,cost:{Money:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?9e7:0,Stone:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?75e6:0,Furs:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?3e7:0,Iron:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?45e6:0,Horseshoe:e=>t.race.hooved&&(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?10:0},effect(){return z("plus_max_citizens",[$(this)[0].citizens()])},refresh:!0,action(){return!!(ri($(this)[0])&&t.galaxy.consulate.count<1)&&(Ft("consulate","galaxy"),t.galaxy.resort={count:0,on:0},t.galaxy.super_freighter={count:0,on:0,crew:0},t.tech.xeno=9,!0)},citizens(){let e=10;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},resort:{id:"galaxy-resort",title:z("galaxy_resort"),desc:()=>`
                ${z("galaxy_resort")}
                ${z("requires_power")}
                `,reqs:{xeno:9},cost:{Money:e=>Ps("resort",e,33e6,1.25,"galaxy"),Stone:e=>Ps("resort",e,25e6,1.25,"galaxy"),Furs:e=>Ps("resort",e,1e7,1.25,"galaxy"),Oil:e=>Ps("resort",e,Ht(125e3),1.25,"galaxy")},effect(){return`
                ${z("plus_max_citizens",[3])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},effect(){let e=br(t.tech.world_control?1875e3:15e5),a=t.race.joyless?"":`
                ${z("city_max_entertainer",[ta(2)])}
                `;return`
                ${z("plus_max_resource",[`$${e.toLocaleString()}`,z("resource_Money_name")])}
                ${a}
                ${z("space_red_vr_center_effect2",[2])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(5),action(){return!!ri($(this)[0])&&(Ft("resort","galaxy"),Yr($(this)[0]),!0)}},vitreloy_plant:{id:"galaxy-vitreloy_plant",title:z("galaxy_vitreloy_plant"),desc:()=>`
                ${z("galaxy_vitreloy_plant")}
                ${z("galaxy_vitreloy_plant_desc")}
                `,reqs:{xeno:10},cost:{Money:e=>Ps("vitreloy_plant",e,35e6,1.25,"galaxy"),Cement:e=>Ps("vitreloy_plant",e,18e5,1.25,"galaxy"),Neutronium:e=>Ps("vitreloy_plant",e,25e4,1.25,"galaxy"),Iridium:e=>Ps("vitreloy_plant",e,85e4,1.25,"galaxy"),Aerogel:e=>Ps("vitreloy_plant",e,4e5,1.25,"galaxy")},effect(){return`
                ${z("galaxy_vitreloy_plant_effect",[+$e("vitreloy_plant").toFixed(2)])}
                ${z("galaxy_vitreloy_plant_effect2",[2.5,100])}
                ${z("galaxy_vitreloy_plant_effect3",[5e4,$(this)[0].powered()])}
                `},powered:()=>As(10),action(){return!!ri($(this)[0])&&(Ft("vitreloy_plant","galaxy"),Yr($(this)[0]),!0)}},super_freighter:{id:"galaxy-super_freighter",title:z("galaxy_super_freighter"),desc:()=>`
                ${z("galaxy_super_freighter")}
                ${z("galaxy_crew_fuel",[z("resource_Helium_3_name")])}
                `,reqs:{xeno:9},cost:{Money:e=>Ps("super_freighter",e,28e6,1.2,"galaxy"),Aluminium:e=>Ps("super_freighter",e,35e5,1.2,"galaxy"),Alloy:e=>Ps("super_freighter",e,1e6,1.2,"galaxy"),Graphene:e=>Ps("super_freighter",e,75e4,1.2,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2),a="";return t.tech.banking>=13&&(a=`
                ${z("interstellar_exchange_boost",[8])}
                `),`
                ${z("galaxy_freighter_effect",[5,Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
                ${a}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("spend",[e,t.resource.Helium_3.name])}
                `},ship:{civ:()=>t.race.high_pop?5*Ei.high_pop.vars()[0]:5,mil:()=>0,helium:25},special:!0,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("super_freighter","galaxy"),t.galaxy.super_freighter.on++,!0)}}},gxy_alien2:{info:{name:()=>z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),desc:()=>z("galaxy_alien2_desc",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red,Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),control:()=>({name:Ki[t.galaxy.alien2.id].name,color:"danger"}),support:"foothold"},alien2_mission:{id:"galaxy-alien2_mission",title:()=>z("galaxy_alien2_mission",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),desc:()=>z("galaxy_alien2_mission_desc",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),reqs:{andromeda:4},grant:["conflict",1],queue_complete:()=>t.tech.conflict>=1?0:1,cost:{Custom(){if(t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_alien2")){let e=0;return Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]})),{label:z("galaxy_fleet_rating",[`400`]),met:!(e<400)}}return{label:z("galaxy_fleet_rating",['400']),met:!1}}},effect(){let e=0;t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_alien2")&&Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]}));let a=e>=650?`${z("galaxy_piracy_low")}`:`${z("galaxy_piracy_avg")}`;return`
                ${z("galaxy_alien2_mission_effect2",[e])}
                ${z("galaxy_alien2_mission_effect3",[a])}
                ${z("galaxy_alien2_mission_effect",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name])}
                `},action(){if(ri($(this)[0])){let e=0;if(Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]})),e>=400){if(hs(z("galaxy_alien2_mission_result2",[Ki[t.galaxy.alien2.id].solar.red]),"info",!1,["progress"]),e<650){let e=80;t.race.instinct&&(e/=2);let a=[];Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(r){for(let i=0;i0&&(e-=jt.gxy_gateway[r].ship.rating(),a.push(r))})),hs(z("galaxy_chthonian_mission_result_losses",[a.map((e=>z(`galaxy_${e}`))).join(", ")]),"danger",!1,["progress"]);for(let e=0;e`
                ${z("galaxy_foothold")}
                ${z("requires_power_combo",[t.resource.Elerium.name])}
                `,reqs:{conflict:1},cost:{Money:e=>Ps("foothold",e,25e6,1.25,"galaxy"),Titanium:e=>Ps("foothold",e,3e6,1.25,"galaxy"),Polymer:e=>Ps("foothold",e,175e4,1.25,"galaxy"),Iridium:e=>Ps("foothold",e,9e5,1.25,"galaxy"),Bolognium:e=>Ps("foothold",e,5e4,1.25,"galaxy")},effect(){return`
                ${z("galaxy_defense_platform_effect",[50])}
                ${z("galaxy_foothold_effect",[$(this)[0].support(),Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
                ${z("galaxy_foothold_effect2",[2.5,$(this)[0].powered()])}
                `},support:()=>4,powered:()=>As(s.s_gate?20:0),powerBalancer:()=>[{s:t.galaxy.foothold.s_max-t.galaxy.foothold.support}],action(){return!!ri($(this)[0])&&(Ft("foothold","galaxy"),Yr($(this)[0]),1===t.tech.conflict&&(t.galaxy.armed_miner={count:0,on:0,crew:0,mil:0},t.tech.conflict=2,Dt(),Qr()),!0)}},armed_miner:{id:"galaxy-armed_miner",title:z("galaxy_armed_miner"),desc:()=>`
                ${z("galaxy_armed_miner")}
                `,reqs:{conflict:2},cost:{Money:e=>Ps("armed_miner",e,5e6,1.25,"galaxy"),Steel:e=>Ps("armed_miner",e,18e5,1.25,"galaxy"),Stanene:e=>Ps("armed_miner",e,1975e3,1.25,"galaxy"),Vitreloy:e=>Ps("armed_miner",e,2e4,1.25,"galaxy"),Soul_Gem:e=>Ps("armed_miner",e,1,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return`
                ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                ${z("gain",[.032,z("resource_Bolognium_name")])}
                ${z("gain",[.23,z("resource_Adamantite_name")])}
                ${z("gain",[.65,z("resource_Iridium_name")])}
                ${z("galaxy_alien2_support",[$(this)[0].support(),Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                ${z("spend",[e,t.resource.Helium_3.name])}
                `},ship:{civ:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2,mil:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,helium:10,rating:()=>t.race.banana?4:5},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("armed_miner","galaxy"),t.galaxy.foothold.support`
                ${z("galaxy_ore_processor")}
                `,reqs:{conflict:3},cost:{Money:e=>Ps("ore_processor",e,3e6,1.25,"galaxy"),Iron:e=>Ps("ore_processor",e,5e6,1.25,"galaxy"),Coal:e=>Ps("ore_processor",e,375e4,1.25,"galaxy"),Graphene:e=>Ps("ore_processor",e,225e4,1.25,"galaxy")},effect(){return`
                ${z("galaxy_ore_processor_effect",[10])}
                ${z("galaxy_alien2_support",[$(this)[0].support(),Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
                `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("ore_processor","galaxy"),t.galaxy.foothold.supportPs("scavenger",e,75e5,1.25,"galaxy"),Alloy:e=>Ps("scavenger",e,125e4,1.25,"galaxy"),Aluminium:e=>Ps("scavenger",e,68e5,1.25,"galaxy"),Neutronium:e=>Ps("scavenger",e,75e3,1.25,"galaxy"),Elerium:e=>Ps("scavenger",e,750,1.25,"galaxy")},effect(){let e=Mt("gxy_alien2"),a=Math.round(25e3*e),r=+Ht($(this)[0].ship.helium).toFixed(2),i=t.race.cataclysm?`
                ${z("galaxy_scavenger_effect2_cata",[+(100*e*.75).toFixed(1)])}
                `:`
                ${z("galaxy_scavenger_effect2",[+(100*e/4).toFixed(1)])}
                `;return`
                ${z("galaxy_scavenger_effect",[a])}
                ${i}
                ${z("galaxy_alien2_support",[$(this)[0].support(),Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                ${z("spend",[r,t.resource.Helium_3.name])}
                `},ship:{civ:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,mil:()=>0,helium:12},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("scavenger","galaxy"),t.galaxy.foothold.supportz("galaxy_chthonian"),desc:()=>z("galaxy_chthonian_desc",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),control:()=>({name:Ki[t.galaxy.alien2.id].name,color:"danger"})},chthonian_mission:{id:"galaxy-chthonian_mission",title:()=>z("galaxy_alien2_mission",[z("galaxy_chthonian")]),desc:()=>z("galaxy_alien2_mission_desc",[z("galaxy_chthonian")]),reqs:{chthonian:1},grant:["chthonian",2],queue_complete:()=>t.tech.chthonian>=2?0:1,cost:{Custom(){if(t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_chthonian")){let e=0;return Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]})),{label:z("galaxy_fleet_rating",[`1250`]),met:!(e<1250)}}return{label:z("galaxy_fleet_rating",['1250']),met:!1}}},effect(){let e=0;t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_chthonian")&&Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]}));let a=e>=4500?`${z("galaxy_piracy_low")}`:e>=2500?`${z("galaxy_piracy_avg")}`:`${z("galaxy_piracy_high")}`;return`
                ${z("galaxy_alien2_mission_effect2",[e])}
                ${z("galaxy_alien2_mission_effect3",[a])}
                ${z("galaxy_alien2_mission_effect",[z("galaxy_chthonian")])}
                `},action(){if(ri($(this)[0])){let e=0;if(Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]})),e>=1250){let a=500,r=[];hs(z("galaxy_chthonian_mission_result"),"info",!1,["progress"]),e>=2500&&(a=e>=4500?80:160),t.race.instinct&&(a/=2),Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(e){for(let i=0;i0&&(a-=jt.gxy_gateway[e].ship.rating(),r.push(e))})),hs(z("galaxy_chthonian_mission_result_losses",[r.map((e=>z(`galaxy_${e}`))).join(", ")]),"danger",!1,["progress"]);for(let e=0;e`
                ${z("galaxy_minelayer")}
                `,reqs:{chthonian:2},cost:{Money:e=>Ps("minelayer",e,9e6,1.25,"galaxy"),Iron:e=>Ps("minelayer",e,48e5,1.25,"galaxy"),Nano_Tube:e=>Ps("minelayer",e,125e4,1.25,"galaxy"),Nanoweave:e=>Ps("minelayer",e,1e5,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return`
                ${z("galaxy_defense_platform_effect",[$(this)[0].ship.rating()])}
                ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                ${z("spend",[e,t.resource.Helium_3.name])}
                `},ship:{civ:()=>0,mil:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,helium:8,rating:()=>t.race.banana?35:50},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("minelayer","galaxy"),t.galaxy.minelayer.on++,!0)},postPower(){Cs({el:"#gxy_chthonian"},"update")},post(){Cs({el:"#gxy_chthonian"},"update")}},excavator:{id:"galaxy-excavator",title:z("galaxy_excavator"),desc:()=>`
                ${z("galaxy_excavator")}
                `,reqs:{chthonian:3},cost:{Money:e=>Ps("excavator",e,12e6,1.25,"galaxy"),Polymer:e=>Ps("excavator",e,44e5,1.25,"galaxy"),Iridium:e=>Ps("excavator",e,36e5,1.25,"galaxy"),Mythril:e=>Ps("excavator",e,18e4,1.25,"galaxy")},effect(){return`
                ${z("gain",[+$e("excavator").toFixed(3),z("resource_Orichalcum_name")])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(8),powerBalancer:()=>[{r:"Orichalcum",p:$e("excavator")}],action(){return!!ri($(this)[0])&&(Ft("excavator","galaxy"),Yr($(this)[0]),!0)}},raider:{id:"galaxy-raider",title:z("galaxy_raider"),desc:()=>`
                ${z("galaxy_raider")}
                `,reqs:{chthonian:3},cost:{Money:e=>Ps("raider",e,12e6,1.25,"galaxy"),Titanium:e=>Ps("raider",e,125e4,1.25,"galaxy"),Bolognium:e=>Ps("raider",e,6e5,1.25,"galaxy"),Vitreloy:e=>Ps("raider",e,125e3,1.25,"galaxy"),Stanene:e=>Ps("raider",e,825e3,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return Mt("gxy_chthonian"),`
                ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                ${z("gain",[.65,z("resource_Deuterium_name")])}
                ${z("gain",[.05,z("resource_Vitreloy_name")])}
                ${z("gain",[2.3,z("resource_Polymer_name")])}
                ${z("gain",[.8,z("resource_Neutronium_name")])}
                ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                ${z("spend",[e,t.resource.Helium_3.name])}
                `},ship:{civ:()=>0,mil:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2,helium:18,rating:()=>t.race.banana?9:12},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("raider","galaxy"),t.galaxy.raider.on++,!0)},postPower(){Cs({el:"#gxy_chthonian"},"update")},post(){Cs({el:"#gxy_chthonian"},"update")}}}};function Ot(e){let t="space";return"int_"===e.substr(0,4)?t="interstellar":"prtl_"===e.substr(0,5)?t="portal":"gxy_"===e.substr(0,4)?t="galaxy":"tau_"===e.substr(0,4)&&(t="tauceti"),t}function Mt(e,a,r){if(t.tech.piracy&&!t.race.truepath){let i=0,n=["dreadnought","cruiser_ship","frigate_ship","corvette_ship","scout_ship"];for(let a=0;ac?c:i))/c)*l+(1-l))*(a?1:Mt("gxy_stargate")):(1-(c-(i>c?c:i))/c)*l+(1-l)}return 1}function St(){let e=["protoplasm",t.race.species];t.city.hasOwnProperty("surfaceDwellers")&&e.push(...t.city.surfaceDwellers),t.custom.hasOwnProperty("race0")||e.push("custom");let a=Object.keys(Ki).filter((function(t){return!["demonic","eldritch"].includes(Ki[t].type)&&!e.includes(t)})),r=en(a);t.galaxy.alien1={id:a[r]},e.push(a[r]),a=Object.keys(Ki).filter((function(t){return!["angelic"].includes(Ki[t].type)&&!e.includes(t)}));let i=en(a);t.galaxy.alien2={id:a[i]}}function Ct(){let e=1;return t.race.pack_rat&&(e*=1.05),t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),e*=t.tech.world_control?2:1,e}const zt={satellite:{count:0},propellant_depot:{count:0},gps:{count:0},nav_beacon:{count:0,on:0},moon_base:{count:0,on:0,support:0,s_max:0},iridium_mine:{count:0,on:0},helium_mine:{count:0,on:0},observatory:{count:0,on:0},spaceport:{count:0,on:0,support:0,s_max:0},red_tower:{count:0,on:0},living_quarters:{count:0,on:0},vr_center:{count:0,on:0},garage:{count:0},red_mine:{count:0,on:0},fabrication:{count:0,on:0},red_factory:{count:0,on:0},exotic_lab:{count:0,on:0},ziggurat:{count:0},space_barracks:{count:0,on:0},biodome:{count:0,on:0},laboratory:{count:0,on:0},geothermal:{count:0,on:0},swarm_plant:{count:0},swarm_control:{count:0,support:0,s_max:0},swarm_satellite:{count:0},gas_mining:{count:0,on:0},gas_storage:{count:0},star_dock:{count:0,ship:0,probe:0,template:"human"},outpost:{count:0,on:0},drone:{count:0},oil_extractor:{count:0,on:0},space_station:{count:0,on:0,support:0,s_max:0},iridium_ship:{count:0,on:0},elerium_ship:{count:0,on:0},elerium_prospector:{count:0,on:0},iron_ship:{count:0,on:0},elerium_contain:{count:0,on:0},e_reactor:{count:0,on:0},world_collider:{count:0},world_controller:{count:0,on:0},starport:{count:0,on:0,support:0,s_max:0},mining_droid:{count:0,on:0,adam:0,uran:0,coal:0,alum:0},processing:{count:0,on:0},habitat:{count:0,on:0},fusion:{count:0,on:0},laboratory:{count:0,on:0},exchange:{count:0,on:0},warehouse:{count:0},xfer_station:{count:0,on:0},cargo_yard:{count:0},cruiser:{count:0,on:0},dyson:{count:0},nexus:{count:0,on:0,support:0,s_max:0},harvester:{count:0,on:0},far_reach:{count:0,on:0},stellar_engine:{count:0,mass:8,exotic:0},mass_ejector:{count:0,on:0,total:0,mass:0,Food:0,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0},stargate:{count:0},gateway_station:{count:0,on:0},s_gate:{count:0,on:0},starbase:{count:0,on:0,support:0,s_max:0},bolognium_ship:{count:0,on:0,crew:0},scout_ship:{count:0,on:0,crew:0,mil:0},corvette_ship:{count:0,on:0,crew:0,mil:0},frigate_ship:{count:0,on:0,crew:0,mil:0},cruiser_ship:{count:0,on:0,crew:0,mil:0},dreadnought:{count:0,on:0,crew:0,mil:0},foothold:{count:0,on:0,support:0,s_max:0},turret:{count:0,on:0},carport:{count:0,damaged:0,repair:0},war_droid:{count:0,on:0},repair_droid:{count:0,on:0},war_drones:{count:0,on:0},sensor_drone:{count:0,on:0},attractor:{count:0,on:0}};function Ft(e,a){a||(a="space"),t[a][e]||(t[a][e]=zt[e]),t[a][e].count++}function At(e,t){return e&&t?$t[e][t]:$t}function It(e,t,a){switch(e){case"space":return Tt($t,t,a);case"interstellar":return Tt(xt,t,a);case"galaxy":return Tt(jt,t,a)}}function Tt(e,a,r){let i=t.race.truepath?"truepath":"standard";if(e[a][r].hasOwnProperty("path")&&!e[a][r].path.includes(i))return!1;var s=!0;return Object.keys(e[a][r].reqs).forEach((function(i){(!t.tech[i]||t.tech[i]=e[a][r].grant[1]&&(s=!1),s}function Lt(){(t.settings.tabLoad||1===t.settings.civTabs)&&(Et("inner"),t.race.truepath&&Et("outer"),Kt(),Dt())}function Et(e){if(e||(e=5===t.settings.spaceTabs?"outer":"inner"),!t.settings.tabLoad&&(1!==t.settings.civTabs||![1,5].includes(t.settings.spaceTabs)||1===t.settings.civTabs&&1===t.settings.spaceTabs&&"inner"!==e||5===t.settings.spaceTabs&&"outer"!==e))return;let a="inner"===e?$("#space"):$("#outerSol");if(Ss(a),a.append($(`

                ${z("inner"===e?"tab_space":"tab_outer_space")}

                `)),!t.settings.showSpace)return!1;let r=[];Object.keys($t).forEach((function(e){t.race.orbit_decayed||t.race.cataclysm?"spc_home"!==e&&(r.push(e),(t.race.orbit_decayed&&"spc_red"===e||t.race.cataclysm&&"spc_moon"===e)&&r.push("spc_home")):r.push(e)})),r.forEach((function(r){let i=r.replace("spc_","");if(t.settings.space[`${i}`]){if(t.race.truepath&&$t[r].info.zone!==e)return;let i="string"==typeof $t[r].info.name?$t[r].info.name:$t[r].info.name(),s=!(!t.race.orbit_decayed&&!t.race.cataclysm);if(s&&"spc_home"!==r||!s){if($t[r].info.support){let e=$t[r].info.support;t.space[e].hasOwnProperty("support")||(t.space[e].support=0,t.space[e].s_max=0),a.append(`

                ${i}

                {{ support }}/{{ s_max }}
                `),Cs({el:`#sr${r}`,data:t.space[e]})}else a.append(`

                ${i}

                `);t.race.truepath&&$t[r].info.hasOwnProperty("syndicate")&&$t[r].info.syndicate()&&t.tech.syndicate&&($(`#${r}`).append(`
                `),$(`#${r}synd`).append(`${z("space_syndicate")} `),$(`#${r}synd`).append(`${z("space_scan_effectiveness")} `),$(`#${r}synd`).append(`${z("space_overkill")} `),Cs({el:`#${r}synd`,data:t.space.syndicate,methods:{threat(e){if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let t=lt(e,!0);if(t.s>=10)return t.s>=50?t.r:Math.round(t.r*t.s*.02)}return"???"},scan:e=>t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")?+((lt(e,!0).s+25)/1.25).toFixed(1)+"%":z("galaxy_piracy_none"),overkill(e){if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let t=lt(e,!0);return t.s>=100?t.o:0}return 0}}}),$t[r].info.hasOwnProperty("extra")&&$t[r].info.extra(r))}ls(r,(function(){return"string"==typeof $t[r].info.desc?$t[r].info.desc:$t[r].info.desc()}),{elm:`#${r} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys($t[r]).forEach((function(t){"info"!==t&&Tt($t,r,t)&&Zr($t[r][t],"inner"===e?"space":"outerSol",t)}))}}))}function Kt(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||2!==t.settings.spaceTabs))return;let e=$("#interstellar");if(Ss(e),e.append($(`

                ${z("tab_interstellar")}

                `)),!t.settings.showDeep)return!1;Object.keys(xt).forEach((function(a){let r=a.replace("int_","");if(t.settings.space[`${r}`]){let r="string"==typeof xt[a].info.name?xt[a].info.name:xt[a].info.name();if(xt[a].info.support){let i=xt[a].info.support;t.interstellar[i].hasOwnProperty("support")||(t.interstellar[i].support=0,t.interstellar[i].s_max=0),e.append(`

                ${r}

                {{ support }}/{{ s_max }}
                `),Cs({el:`#sr${a}`,data:t.interstellar[i]})}else e.append(`

                ${r}

                `);ls(a,(function(){return"string"==typeof xt[a].info.desc?xt[a].info.desc:xt[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(xt[a]).forEach((function(e){"info"!==e&&Tt(xt,a,e)&&Zr(xt[a][e],"interstellar",e)}))}}))}function Dt(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||3!==t.settings.spaceTabs))return;let e=$("#galaxy");if(Ss(e),e.append($(`

                ${z("tab_galactic")}

                `)),!t.settings.showGalactic)return!1;!function(e,a){if(t.tech.piracy&&!t.race.truepath){let r=$(`

                ${z("galaxy_armada")}

                `);e.append(r);let i=t.tech.world_control?z("civics_garrison_peacekeepers"):z("civics_garrison_soldiers");r.append($("|")),r.append($(`${i} {{ g.workers | stationed }} / {{ g.max | s_max }}`)),r.append($("|")),r.append($(`${z("job_crew_mil")} {{ g.crew }}`)),r.append($("|")),r.append($(`${z("job_crew_civ")} {{ c.workers }} / {{ c.max }}`)),Cs({el:`#h${a}`,data:{g:t.civic.garrison,c:t.civic.crew},filters:{stationed:e=>we(),s_max:e=>we(!0)}}),["soldier","crew1","crew2"].forEach((function(e){ls(`h${a}${e}`,(function(){switch(e){case"soldier":return me();case"crew1":return z("civics_garrison_crew_desc");case"crew2":return z("job_crew_desc")}}),{elm:`#h${a} span.${e}`})}));let s=$(`
                `);e.append(s);let n=["scout_ship","corvette_ship","frigate_ship","cruiser_ship","dreadnought"],c=[];for(let e=0;e<6;e++){let e=$('
                ');c.push(e),s.append(e)}for(let e=0;e${jt.gxy_gateway[n[e]].title}`);c[e+1].append(t)}c[0].append($("")),c[0].append($(`${jt.gxy_gateway.info.name}`));for(let e=0;e{{ gateway.${n[e]} }}`);c[e+1].append(t)}Object.keys(t.galaxy.defense).forEach((function(e){let a=e.substring(4);if(t.settings.space[a]&&"gateway"!==a){let r=$(`${"string"==typeof jt[e].info.name?jt[e].info.name:jt[e].info.name()}`);c[0].append(r);for(let r=0;r'),i=$(`«`),s=$(`{{ ${a}.${n[r]} }}`),o=$(`»`);c[r+1].append(t),t.append(i),t.append(s),t.append(o)}}})),Cs({el:`#${a}`,data:{stargate:t.galaxy.defense.gxy_stargate,gateway:t.galaxy.defense.gxy_gateway,gorddon:t.galaxy.defense.gxy_gorddon,alien1:t.galaxy.defense.gxy_alien1,alien2:t.galaxy.defense.gxy_alien2,chthonian:t.galaxy.defense.gxy_chthonian,t:t.tech},methods:{sub(e,a){if(t.galaxy.defense[e][a]>0){let r=y();r>t.galaxy.defense[e][a]&&(r=t.galaxy.defense[e][a]),t.galaxy.defense.gxy_gateway[a]+=r,t.galaxy.defense[e][a]-=r}},add(e,a){if(t.galaxy.defense.gxy_gateway[a]>0){let r=y();r>t.galaxy.defense.gxy_gateway[a]&&(r=t.galaxy.defense.gxy_gateway[a]),t.galaxy.defense.gxy_gateway[a]-=r,t.galaxy.defense[e][a]+=r}}}}),Object.keys(t.galaxy.defense).forEach((function(e){let a=e.substring(4);t.settings.space[a]&&ls(`armada${a}`,(function(){return`
                ${"string"==typeof jt[e].info.desc?jt[e].info.desc:jt[e].info.desc()}
                `}))}));for(let e=0;e`);e.append(i);let s=$(`

                ${r}

                `);i.append(s),t.tech.xeno&&t.tech.xeno>=3&&i.append(`{{ r.control().name }}`);let n={el:`#${a}`,data:{r:jt[a].info},methods:{threat(e){let a=t.race.infiltrator?1:2;if(t.galaxy.defense[e].scout_ship>=a){let t=100*(1-Mt(e,!0));return t=t<1?Math.ceil(t):Math.round(t),0===t?"has-text-success":t<=20?"has-text-advanced":t<=40?"has-text-info":t<=60?"has-text-warning":t<=80?"has-text-caution":"has-text-danger"}return"has-text-danger"}},filters:{pirate(e){let a=t.race.infiltrator?1:2;if(t.galaxy.defense[e].scout_ship>=a){let a=100*(1-Mt(e,!0));a=a<1?Math.ceil(a):Math.round(a);let r=t.race.infiltrator?3:4;return t.galaxy.defense[e].scout_ship>=r?`${a}%`:z(0===a?"galaxy_piracy_none":a<=20?"galaxy_piracy_vlow":a<=40?"galaxy_piracy_low":a<=60?"galaxy_piracy_avg":a<=80?"galaxy_piracy_high":"galaxy_piracy_vhigh")}return"???"},defense:e=>Mt(e,!0,!0)}};if(jt[a].info.support){let e=jt[a].info.support;t.galaxy[e]&&(t.galaxy[e].hasOwnProperty("support")||(t.galaxy[e].support=0,t.galaxy[e].s_max=0),i.append('{{ s.support }}/{{ s.s_max }}'),n.data.s=t.galaxy[e])}t.tech.piracy&&i.append(`
                ${z("galaxy_piracy_threat",[Ki[t.galaxy.alien2.id].name])}{{ '${a}' | pirate }}|${z("galaxy_armada")}: {{ '${a}' | defense }}
                `),Cs(n),ls(a,(function(){return"string"==typeof jt[a].info.desc?jt[a].info.desc:jt[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),ls(a,(function(){return z("galaxy_control",[jt[a].info.control().name,r])}),{elm:`#${a} .regionControl`,classes:"has-background-light has-text-dark"}),Object.keys(jt[a]).forEach((function(e){"info"!==e&&Tt(jt,a,e)&&Zr(jt[a][e],"galaxy",e)}))}}))}function Bt(e){return t.tech.space_housing&&(e*=.8**t.tech.space_housing),e}function Gt(e){return t.tech.solar&&t.tech.solar>=5&&n.iron_ship&&(e*=.95**n.iron_ship),e}function Nt(e){if(t.space.swarm_plant){let a=t.tech.swarm?.88:.94;t.tech.swarm>=3&&(a-=_/100),a<.05&&(a=.05),e*=a**t.space.swarm_plant.count}return e}function Rt(e,a,r){return r=r||{},"heavy"===t.race.universe&&(e*=1.25+.5*Is("heavy")),t.race.truepath&&(e*=a?2.5:1.25),t.city.mass_driver&&s.mass_driver?e*=(t.race.truepath?.94:.95)**s.mass_driver:r.mass_driver&&(e*=.95**r.mass_driver),t.stats.achieve.heavyweight&&(e*=.96**t.stats.achieve.heavyweight.l),t.city.ptrait.includes("dense")&&(e*=ss.dense.vars()[2]),t.race.cataclysm&&(e*=.2),t.race.heavy&&(e*=1+Ei.heavy.vars()[0]/100),cn("launch_day")&&(e*=.95),e}function Ht(e){return"heavy"===t.race.universe&&(e*=1.2+.3*Is("heavy")),t.stats.achieve.heavyweight&&(e*=.96**t.stats.achieve.heavyweight.l),t.race.heavy&&(e*=1+Ei.heavy.vars()[0]/100),cn("launch_day")&&(e*=.95),e}function Ut(){let e={red:Ki[t.race.species].solar.red,hell:Ki[t.race.species].solar.hell,gas:Ki[t.race.species].solar.gas,gas_moon:Ki[t.race.species].solar.gas_moon,dwarf:Ki[t.race.species].solar.dwarf,titan:Di[Ki[t.race.species].type].solar.titan,enceladus:Di[Ki[t.race.species].type].solar.enceladus,triton:Di[Ki[t.race.species].type].solar.triton,eris:Di[Ki[t.race.species].type].solar.eris};if("custom"===t.race.species)for(let a of["titan","enceladus","triton","eris"])t.custom.race0.hasOwnProperty(a)&&(e[a]=t.custom.race0[a]);return e}const Vt=["l","h","a","e","m","mg"],Wt={standard:{name:z("universe_standard"),desc:z("universe_standard_desc"),effect:z("universe_standard_effect")},heavy:{name:z("universe_heavy"),desc:z("universe_heavy_desc"),effect:z("universe_heavy_effect",[5])},antimatter:{name:z("universe_antimatter"),desc:z("universe_antimatter_desc"),effect:z("universe_antimatter_effect")},evil:{name:z("universe_evil"),desc:z("universe_evil_desc"),effect:z("universe_evil_effect")},micro:{name:z("universe_micro"),desc:z("universe_micro_desc"),effect:z("universe_micro_effect",[75])},magic:{name:z("universe_magic"),desc:z("universe_magic_desc"),effect:z("universe_magic_effect")}};function Qt(a){a||t.race.noexport||(P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),qn(`biome_${t.city.biome}`),qn(`genus_${Ki[t.race.species].type}`),t.race.witch_hunter&&"magic"===t.race.universe?qn("soul_sponge"):(qn("ascended"),0===t.interstellar.thermal_collector.count&&Pn("energetic")),"junker"===t.race.species&&Pn("the_misery"),!t.race.modified&&t.race.junker&&"junker"===t.race.species&&Pn("garbage_pie"),t.race.emfield&&qn("technophobe"),t.race.cataclysm&&Pn("finish_line"),t.race.noexport="Race",Ss($("#city")),t.settings.showCity=!0,t.settings.showCivic=!1,t.settings.showResearch=!1,t.settings.showResources=!1,t.settings.showGenetics=!1,t.settings.showSpace=!1,t.settings.showDeep=!1,t.settings.showGalactic=!1,t.settings.showPortal=!1,t.settings.spaceTabs=0);let r=$('
                '),i={ascended:{},technophobe:t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l?t.stats.achieve.technophobe.l:0};if(a?a.append(r):$("#city").append(r),r.append(`

                ${z("genelab_title")}

                - ${z("genelab_genes")} {{ g.genes }} - ${z("trait_untapped_name")}: {{ g.genes | untapped }}
                `),a){r.append(`\n
                ${z("achieve_ascended_name")}
                \n `);let e=$("
                ");r.append(e),Object.keys(Wt).forEach((function(a){i.ascended[a]=t.stats.achieve.ascended&&t.stats.achieve.ascended.hasOwnProperty(xn(a))?t.stats.achieve.ascended[xn(a)]:0,e.append(`\n
                ${z("universe_"+a)}
                \n `)})),r.append(`\n
                ${z("achieve_technophobe_name")}
                \n
                \n
                \n
                \n `)}let s=$(`
                ${z("genelab_name")}
                ${z("genelab_entity")}
                ${z("genelab_home")}
                ${z("genelab_desc")}
                `);r.append(s);let n=$(`
                \n
                ${z("genelab_red")}
                \n
                ${z("genelab_hell")}
                \n
                ${z("genelab_gas")}
                \n
                ${z("genelab_gas_moon")}
                \n
                ${z("genelab_dwarf")}
                `);r.append(n);let c=$(`
                \n
                ${z("genelab_titan")}
                \n
                ${z("genelab_enceladus")}
                \n
                ${z("genelab_triton")}
                \n
                ${z("genelab_eris")}
                `);r.append(c);let o=$('
                ');r.append(o);let l=!1,_=`
                ${z("genelab_genus")}
                ",o.append($(_));let d=`
                ${z("genelab_traits")}
                ",o.append($(d));let h=`\n
                \n \n
                \n
                \n
                \n \n \n \n
                \n
                \n {{ err.msg }}\n
                \n `;a||(h+=`\n
                \n \n
                \n `),r.append(h);var g=t.hasOwnProperty("custom")&&t.custom.hasOwnProperty("race0")?{name:t.custom.race0.name,desc:t.custom.race0.desc,entity:t.custom.race0.entity,home:t.custom.race0.home,red:t.custom.race0.red,hell:t.custom.race0.hell,gas:t.custom.race0.gas,gas_moon:t.custom.race0.gas_moon,dwarf:t.custom.race0.dwarf,titan:t.custom.race0.titan||Ut().titan,enceladus:t.custom.race0.enceladus||Ut().enceladus,triton:t.custom.race0.triton||Ut().triton,eris:t.custom.race0.eris||Ut().eris,genes:0,genus:t.custom.race0.genus,traitlist:t.custom.race0.traits}:{name:"Zombie",desc:"Zombies aren't so much a species as they are the shambling remains of a race who succumbed to a nightmarish virus. Yet somehow they continue to drone on.",entity:"rotting bipedal creatures",home:"Grave",red:"Brains",hell:"Rigor Mortis",gas:"Decompose",gas_moon:"Bones",dwarf:"Double Tap",titan:"Necromancer",enceladus:"Skeleton",triton:"Rot",eris:"Zombieland",genes:10,genus:l,traitlist:[]};for(let e=g.traitlist.length-1;e>=0;e--)Ei.hasOwnProperty(g.traitlist[e])&&"major"===Ei[g.traitlist[e]].type||g.traitlist.splice(e,1);g.genes=an(g,!!a&&i);let v={msg:""};Cs({el:"#celestialLab",data:{g,w:i,err:v},methods:{val(e){"technophobe"===e?i.technophobe<0?i.technophobe=0:i.technophobe>5&&(i.technophobe=5):i.ascended[e]<0?i.ascended[e]=0:i.ascended[e]>5&&(i.ascended[e]=5)},geneEdit(){g.genes=an(g,!!a&&i)},setRace(){an(g)>=0&&g.name.length>0&&g.desc.length>0&&g.entity.length>0&&g.home.length>0&&g.red.length>0&&g.hell.length>0&&g.gas.length>0&&g.gas_moon.length>0&&g.dwarf.length>0&&(t.custom.race0={name:g.name,desc:g.desc,entity:g.entity,home:g.home,red:g.red,hell:g.hell,gas:g.gas,gas_moon:g.gas_moon,dwarf:g.dwarf,titan:g.titan,enceladus:g.enceladus,triton:g.triton,eris:g.eris,genus:g.genus,traits:g.traitlist},function(){O(),ks("reset",{end:"ascend"});let a=t.race.species,r=t.race.gods,i=t.city.calendar.orbit,s=t.city.biome,n=t.city.ptrait,c=t.city.geology,o=Gs("ascend");t.stats.ascend++,rn(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),t.prestige.Harmony.count=parseFloat((t.prestige.Harmony.count+o.harmony).toFixed(2)),t.stats.harmony=parseFloat((t.stats.harmony+o.harmony).toFixed(2)),n.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),void 0===t.tech.world_control&&qn("cult_of_personality");let l=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0&&l++})),l>=4&&qn("miners_dream"),t.galaxy.hasOwnProperty("dreadnought")&&0!==t.galaxy.dreadnought.count||qn("dreaded"),t.race.modified||"synth"!==t.race.species&&"nano"!==t.race.species||!t.race.emfield||Pn("digital_ascension"),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),Sn();let _=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!0},d>0&&(t.race.corruption=d),_&&(t.race.srace=_),Object.keys(c).forEach((function(e){c[e]+=.02})),H({orbit:i,biome:s,ptrait:n,geology:c}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}())},allowed:e=>!("synthetic"===g.genus||!["deconstructor","imitation"].includes(e)||(g.traitlist.includes(e)&&g.traitlist.splice(g.traitlist.indexOf(e),1),0)),reset(){g.name="",g.desc="",g.entity="",g.home="",g.red="",g.hell="",g.gas="",g.gas_moon="",g.dwarf="",g.titan="",g.enceladus="",g.triton="",g.eris="",g.genus=l,g.traitlist=[],g.genes=an(g,!!a&&i)},customImport(){let e=document.getElementById("customFile").files[0];if(e){let r=new FileReader;r.readAsText(e,"UTF-8"),r.onload=function(r){let s="";try{s=JSON.parse(r.target.result)}catch{return void(v.msg=z("string_pack_error",[e.name]))}let n=!1;if(Object.keys(g).forEach((function(e){s[e]&&typeof g[e]!=typeof s[e]&&(n=!0)})),n)return v.msg=z("string_pack_error",[e.name]),void console.log("format fail");Object.keys(g).forEach((function(e){s[e]&&(g[e]=s[e])})),["name","home","red","hell","gas","gas_moon","dwarf","titan","enceladus","triton","eris"].forEach((function(e){!s[e]&&["titan","enceladus","triton","eris"].includes(e)?g[e]=z(`genus_${g.genus}_solar_${e}`):g[e].length>20&&(g[e]=g[e].substring(0,20))})),g.entity.length>40&&(g.entity=g.entity.substring(0,40)),g.desc.length>255&&(g.desc=g.desc.substring(0,255)),a||t.stats.achieve[`genus_${g.genus}`]&&t.stats.achieve[`genus_${g.genus}`].l>0||(g.genus=l);let c=[];for(let e=0;e{const r=document.createElement("a"),i=new Blob([e],{type:"text/plain"});r.href=URL.createObjectURL(i),r.download=t,r.click(),URL.revokeObjectURL(r.href)})(JSON.stringify(g,null,4),`evolve-custom-${g.name}.txt`)}},filters:{cost(e){if(Ei[e].val>=0){let r=2;a?r+=i.technophobe:t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1&&(r+=t.stats.achieve.technophobe.l);let s=Ei[e].val,n=0;for(let e=0;e=0&&n++;return g.traitlist.includes(e)&&n--,n>r&&(s+=n-r),s}return Ei[e].val},untapped:e=>`+${e>0?+(100*(e/(e+20)/10+24e-5)).toFixed(3):0}%`}}),Object.keys(Li).forEach((function(e){t.stats.achieve[`genus_${e}`]&&t.stats.achieve[`genus_${e}`].l>0&&ls(`celestialLabgenusSelection${e}`,(function(){let t=$(`
                ${z(`genelab_genus_${e}_desc`)}
                `);return Object.keys(Li[e]).forEach((function(e){if(Ei[e]){let a=$("
                ");vn(a,e,{trank:1}),t.append(a)}})),t}),{elm:`#celestialLab .genus_selection .${e}`,classes:"w30",wide:!0})})),Object.keys(u).sort().forEach((function(e){Ei.hasOwnProperty(e)&&"major"===Ei[e].type&&ls(`celestialLabtraitSelection${e}`,(function(){let t=$("
                ");return vn(t,e,{trank:1}),t}),{elm:`#celestialLab .trait_selection .t${e}`,classes:"w30",wide:!0})}))}function Jt(a){a||t.race.noexport||(P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),qn(`biome_${t.city.biome}`),qn(`genus_${Ki[t.race.species].type}`),qn("lamentis"),"junker"===t.race.species&&Pn("the_misery"),t.race.noexport="Planet",Ss($("#city")),t.settings.showCity=!0,t.settings.showCivic=!1,t.settings.showResearch=!1,t.settings.showResources=!1,t.settings.showGenetics=!1,t.settings.showSpace=!1,t.settings.showDeep=!1,t.settings.showGalactic=!1,t.settings.showPortal=!1,t.settings.spaceTabs=0);let r=$('
                '),i={ascended:{},lamentis:t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l?t.stats.achieve.lamentis.l:0};a?a.append(r):$("#city").append(r),r.append(`

                ${z("planetlab_title")}

                - ${z("planetlab_points")} {{ p.pts }}
                `);let s=$('
                ');r.append(s);let n=!1,c=`
                ${z("wiki_planet_biome")}
                ",s.append($(c));let o=`
                ${z("wiki_planet_trait")}
                ",s.append($(o));let l={},_=["Copper","Iron","Aluminium","Coal","Oil","Titanium","Uranium"];t.stats.achieve.whitehole&&_.push("Iridium");let d=`
                ${z("planetlab_res")}
                ",s.append($(d));let p={biome:n,pts:0,traitlist:[],geology:l,orbit:t.city.calendar.orbit};if(t.custom.hasOwnProperty("planet")){let e=xn();if(t.custom.planet.hasOwnProperty(e)){let a="s";t.custom.planet[e][a]&&(p=sn(t.custom.planet[e][a]),p.orbit=t.city.calendar.orbit,_.forEach((function(e){p.geology.hasOwnProperty(e)?p.geology[e]*=100:p.geology[e]=0})))}}p.pts=Zt(p);let u=`
                \n
                \n \n
                \n `;a||(u+=`\n
                \n \n
                \n `),u+="
                ",r.append(u),Cs({el:"#celestialLab",data:{p,w:i},methods:{pEdit(){p.pts=Zt(p)},setPlanet(){if(Zt(p)>=0){Object.keys(p.geology).forEach((function(e){0===p.geology[e]?delete p.geology[e]:p.geology[e]/=100})),t.custom.hasOwnProperty("planet")||(t.custom.planet={});let a=xn();t.custom.planet.hasOwnProperty(a)||(t.custom.planet[a]={s:!1});let r="s";t.custom.planet[a][r]=sn(p),delete t.custom.planet[a][r].pts,function(a){O(),ks("reset",{end:"terraform"});let r=t.race.species,i=t.race.gods,s=t.city.calendar.orbit,n=a.biome,c=a.traitlist,o=a.geology,l=Gs("terraform");t.stats.terraform++,rn(),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Harmony.count=parseFloat((t.prestige.Harmony.count+l.harmony).toFixed(2)),t.stats.harmony=parseFloat((t.stats.harmony+l.harmony).toFixed(2)),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),void 0===t.tech.world_control&&qn("cult_of_personality");let _=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0&&_++})),_>=4&&qn("miners_dream"),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),Sn();let d=!!t.race.hasOwnProperty("srace")&&t.race.srace,p=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:r,old_gods:i,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended,rejuvenated:!0},p>0&&(t.race.corruption=p),d&&(t.race.srace=d),H({orbit:s,biome:n,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(p)}},reset(){p.traitlist=[],Object.keys(p.geology).forEach((function(e){p.geology[e]=0})),p.pts=Zt(p)},less(e){p.geology[e]-=y(),p.geology[e]<-20&&(p.geology[e]=-20)},more(e){p.geology[e]+=y();let a=30;t.stats.achieve.whitehole&&(a+=5*t.stats.achieve.whitehole.l),"eden"===p.biome&&(a+=5),p.geology[e]>a&&(p.geology[e]=a)}},filters:{res:e=>p.geology[e]}})}function Zt(e,a){let r=("eden"===e.biome?0:10)+(t.stats.achieve.lamentis?10*t.stats.achieve.lamentis.l:0);t.race.truepath&&(r*=2),r-=e.traitlist.length**3;let i=0;return Object.keys(e.geology).forEach((function(t){0!==e.geology[t]&&(r-=e.geology[t],i++)})),i>3&&(r-=(i-3)**2),r}const Xt={unemployed:function(e){let a=z("job_unemployed_desc");return"unemployed"!==t.civic.d_job||e||(a=a+" "+z("job_default",[z("job_unemployed")])),a},hunter:function(e){let a=z("job_hunter_desc",[t.resource.Food.name]);return t.race.unfathomable&&(a=z("job_eld_hunter_desc")),t.race.artifical?a=t.race.soul_eater?z("job_art_demon_hunter_desc",[t.resource.Furs.name,t.resource.Lumber.name]):z("job_art_hunter_desc",[t.resource.Furs.name]):t.race.soul_eater&&"wendigo"!==t.race.species&&(a=z(t.race.evil?"job_evil_hunter_desc":"job_not_evil_hunter_desc",[t.resource.Food.name,t.resource.Lumber.name,t.resource.Furs.name])),"hunter"!==t.civic.d_job||e||(a=a+" "+z("job_default",[t.race.unfathomable?z("job_raider"):z("job_hunter")])),a},forager:function(e){let a=z("job_forager_desc");return"forager"!==t.civic.d_job||e||(a=a+" "+z("job_default",[z("job_forager")])),a},farmer:function(e){let a=+ia(!0,e).toFixed(2),r=+ia(!1,e).toFixed(2);e||(a=+ea(a,"farmer").toFixed(2),r=+ea(r,"farmer").toFixed(2));let i=t.race.high_pop&&!e?z("job_farmer_desc_hp",[a,t.resource.Food.name,ta(1),r,ta(1)*t.city.farm.count]):z("job_farmer_desc",[a,t.resource.Food.name,t.city.farm.count,r]);return"farmer"!==t.civic.d_job||e||(i=i+" "+z("job_default",[z("job_farmer")])),i},lumberjack:function(e){let a=e&&t.race.servants?t.race.servants.jobs.lumberjack:t.civic.lumberjack.workers,r=t.civic.lumberjack.impact;if(e||(a=+ea(a,"lumberjack").toFixed(2),r=+ea(r,"lumberjack").toFixed(2)),!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species){let i=1+(t.tech.axe&&t.tech.axe>0?.35*(t.tech.axe-1):0);e||(i*=Bi(a,"lumberjack")),"forest"===t.city.biome&&(r*=is.forest.vars()[0]),"savanna"===t.city.biome&&(r*=is.savanna.vars()[2]),"desert"===t.city.biome&&(r*=is.desert.vars()[2]),"swamp"===t.city.biome&&(r*=is.swamp.vars()[2]),"taiga"===t.city.biome&&(r*=is.taiga.vars()[0]);let s=z("job_lumberjack_desc",[+(r*i).toFixed(2),t.resource.Lumber.name]);return"lumberjack"!==t.civic.d_job||e||(s=s+" "+z("job_default",[z("job_lumberjack")])),s}{let i=1;e||(i*=Bi(a,"lumberjack"));let s=+(r*i).toFixed(2),n=+(r/4*i).toFixed(2),c="wendigo"===t.race.species?z("job_reclaimer_desc2",[s]):z("job_reclaimer_desc",[s,n]);return"lumberjack"!==t.civic.d_job||e||(c=c+" "+z("job_default",[z("job_reclaimer")])),c}},quarry_worker:function(e){let a=e&&t.race.servants?t.race.servants.jobs.quarry_worker:t.civic.quarry_worker.workers,r=t.civic.quarry_worker.impact;e||(a=+ea(a,"quarry_worker").toFixed(2),r=+ea(r,"quarry_worker").toFixed(2));let i=1+(t.tech.hammer&&t.tech.hammer>0?.4*t.tech.hammer:0);e||(i*=Bi(a,"miner")),"desert"===t.city.biome&&(i*=is.desert.vars()[0]),"swamp"===t.city.biome&&(i*=is.swamp.vars()[3]),t.tech.explosives&&t.tech.explosives>=2&&(i*=t.tech.explosives>=3?1.75:1.5);let s=+(r*i).toFixed(1),n=t.resource.Aluminium.display?z("job_quarry_worker_desc2",[s,t.resource.Stone.name,t.resource.Aluminium.name]):z("job_quarry_worker_desc1",[s,t.resource.Stone.name]);return t.race.smoldering&&(n=n+" "+z("job_quarry_worker_smoldering",[t.resource.Chrysotile.name])),"quarry_worker"!==t.civic.d_job||e||(n=n+" "+z("job_default",[z("job_quarry_worker")])),n},crystal_miner:function(e){let a=e&&t.race.servants?t.race.servants.jobs.crystal_miner:t.civic.crystal_miner.workers,r=t.civic.crystal_miner.impact,i=1;e||(a=+ea(a,"crystal_miner").toFixed(2),r=+ea(r,"crystal_miner").toFixed(2),i*=Bi(a,"miner"));let s=z("job_crystal_miner_desc",[+(r*i).toFixed(2),t.resource.Crystal.name]);return"crystal_miner"!==t.civic.d_job||e||(s=s+" "+z("job_default",[z("job_crystal_miner")])),s},scavenger:function(e){let a=Ei.scavenger.vars()[0];t.city.ptrait.includes("trashed")&&t.race.scavenger&&(a*=1+Ei.scavenger.vars()[1]/100),t.race.high_pop&&!e&&(a*=Ei.high_pop.vars()[1]/100),e||(a=+ea(a,"scavenger").toFixed(2));let r=z("job_scavenger_desc",[Ki[t.race.species].home,a]);return"scavenger"!==t.civic.d_job||e||(r=r+" "+z("job_default",[z("job_scavenger")])),r},torturer:function(){return z("job_torturer_desc")},miner:function(){return t.tech.mining>=3?t.race.sappy&&t.tech.alumina?z("job_miner_desc2_amber"):z("job_miner_desc2"):z("job_miner_desc1")},coal_miner:function(){return t.tech.uranium?z("job_coal_miner_desc2"):z("job_coal_miner_desc1")},craftsman:function(){return z("job_craftsman_desc")},cement_worker:function(){let e=t.race.high_pop?3/Ei.high_pop.vars()[0]:3;"ashland"===t.city.biome&&(e*=is.ashland.vars()[1]),e=+ea(e,"cement_worker").toFixed(2);let a=+ea(t.civic.cement_worker.impact,"cement_worker").toFixed(2)*(t.tech.cement>=4?1.2:1)*Bi(t.civic.cement_worker.workers,"factory");return"ashland"===t.city.biome&&(a*=is.ashland.vars()[1]),a=+a.toFixed(2),t.race.sappy?z("job_cement_worker_amber_desc",[a]):z("job_cement_worker_desc",[a,e])},banker:function(){let e=100*+ea(t.civic.banker.impact,"banker").toFixed(2);return t.tech.banking>=10&&(e+=2*t.tech.stock_exchange),t.race.truthful&&(e*=1-Ei.truthful.vars()[0]/100),"republic"===t.civic.govern.type&&(e*=1.25),t.race.high_pop&&(e*=Ei.high_pop.vars()[1]/100),e=+e.toFixed(0),z("job_banker_desc",[e])},entertainer:function(){let e=t.tech.theatre;t.race.musical&&(e+=Ei.musical.vars()[0]),t.race.emotionless&&(e*=1-Ei.emotionless.vars()[0]/100),t.race.high_pop&&(e*=Ei.high_pop.vars()[1]/100),e=+ea(e,"entertainer").toFixed(2);let a=t.race.high_pop?Ei.high_pop.vars()[1]/100:1;return a=+ea(a,"entertainer").toFixed(2),t.tech.superstar?z("job_entertainer_desc2",[e,a]):z("job_entertainer_desc",[+e.toFixed(2)])},priest:function(){let e="";return e="theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display?z("job_priest_desc2"):z("job_priest_desc"),t.tech.cleric&&(e+=` ${z("job_priest_desc3")}`),e},professor:function(){let e=+ea(1,"professor"),a=+(t.race.studious?t.civic.professor.impact+Ei.studious.vars()[0]:t.civic.professor.impact),r=ts("elven");return r>0&&(a+=Ei.studious.vars(1)[0]*r),e*=a,e*=t.race.pompous?1-Ei.pompous.vars()[0]/100:1,e*=Bi(t.civic.professor.workers,"science"),t.tech.anthropology&&t.tech.anthropology>=3&&(e*=1+.05*t.city.temple.count),"theocracy"===t.civic.govern.type&&(e*=.75),e=+e.toFixed(2),z("job_professor_desc",[e])},scientist:function(){let e=+ea(t.civic.scientist.impact,"scientist").toFixed(2);return e*=Bi(t.civic.scientist.workers,"science"),t.tech.science>=6&&t.city.wardenclyffe&&(e*=1+t.civic.professor.workers*t.city.wardenclyffe.on*.01),t.space.satellite&&(e*=1+.01*t.space.satellite.count),"theocracy"===t.civic.govern.type&&(e*=t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?.75:.6:.5),e=+e.toFixed(2),"magic"===t.race.universe?z("job_wizard_desc",[e,+(.025*Is("magic")).toFixed(4)]):z("job_scientist_desc",[e])},colonist:()=>z(t.race.truepath?"job_colonist_desc_tp":"job_colonist_desc",[Ut().red]),titan_colonist:()=>z("job_colonist_desc_tp",[Ut().titan]),space_miner:()=>z("job_space_miner_desc"),hell_surveyor:()=>z("job_hell_surveyor_desc"),archaeologist(){let e=75*(s.arcology||0),a=(be(t.portal.guard_post.on,"hellArmy",0)+e)/5e3;a=a>1?1:a;let r=25e4;return t.race.high_pop&&(r*=Ei.high_pop.vars()[1]/100),z("job_archaeologist_desc",[Math.round(r*a).toLocaleString()])},pit_miner:()=>z("job_pit_miner_desc",[z("tau_planet",[Ki[t.race.species].home])]),crew:()=>z("job_crew_desc")};function Yt(e){e||$("#civics").append($(`

                ${z("civics_jobs")}

                `)),ra("unemployed",e,0,0,"warning"),ra("hunter",e,0,0),ra("forager",e,0,0),ra("farmer",e,.82,5),ra("lumberjack",e,1,5),ra("quarry_worker",e,1,5),ra("crystal_miner",e,.1,5),ra("scavenger",e,.12,5),ra("torturer",e,1,3,"advanced"),ra("miner",e,1,4,"advanced"),ra("coal_miner",e,.2,4,"advanced"),ra("craftsman",e,1,5,"advanced"),ra("cement_worker",e,.4,5,"advanced"),ra("entertainer",e,1,10,"advanced"),ra("priest",e,1,3,"advanced"),ra("professor",e,.5,6,"advanced"),ra("scientist",e,1,5,"advanced"),ra("banker",e,.1,6,"advanced"),ra("colonist",e,1,5,"advanced"),ra("titan_colonist",e,1,5,"advanced"),ra("space_miner",e,1,5,"advanced"),ra("hell_surveyor",e,1,1,"advanced"),ra("archaeologist",e,1,1,"advanced"),ra("pit_miner",e,1,4.5,"advanced"),ra("crew",e,1,4,"alert"),e||t.race.start_cataclysm||(sa(),t.race.servants&&function(){if(Ss($("#servants")),t.race.servants){var e=$(`

                ${z("civics_servants")}

                {{ s.used }} / {{ s.max }}
                `);$("#servants").append(e),["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].forEach((function(e){ra(e,"servant")})),Cs({el:"#servantList",data:{s:t.race.servants},methods:{level:()=>0===t.race.servants.used?"count has-text-danger":t.race.servants.used===t.race.servants.max?"count has-text-success":t.race.servants.used<=t.race.servants.max/3?"count has-text-caution":t.race.servants.used<=.66*t.race.servants.max?"count has-text-warning":t.race.servants.used`),_=c?$('
                '):$(`
                `);if(n&&"unemployed"!==e){let t=$(`

                {{ civic.${e}.name }}

                {{ civic.${e}.workers | adjust('${e}') }} / {{ civic.${e}.max | adjust('${e}') }}
                `);l.append(t)}else{n=n||"info";let t=c?$(`

                {{ civic.${e}.name }}

                {{ sjob.${e} }}
                `):$(``);l.append(t)}if(l.append(_),$(c?"#servants":"#jobs").append(l),"crew"!==e){var d=$(`«`),p=$(`»`);_.append(d),_.append(p)}Cs(c?{el:`#${o}`,data:{civic:t.civic,sjob:t.race.servants.jobs},methods:{showJob:e=>t.civic[e].display||"scavenger"===e&&t.race.servants.force_scavenger,add(){let a=y();for(let r=0;rt.race.servants.used;r++)t.race.servants.jobs[e]++,t.race.servants.used++},sub(){let a=y();for(let r=0;r0;r++)t.race.servants.jobs[e]--,t.race.servants.used--}}}:{el:`#${o}`,data:{civic:t.civic},methods:{showJob:e=>t.civic[e].display,add(){let a=y();for(let r=0;r0;r++)t.civic[e].workers++,t.civic[t.civic.d_job].workers--,t.civic[e].assigned=t.civic[e].workers},sub(){let a=y();for(let r=0;r0;r++)t.civic[e].workers--,t.civic[t.civic.d_job].workers++,t.civic[e].assigned=t.civic[e].workers},level:e=>0===t.civic[e].workers?"count has-text-danger":t.civic[e].workers===t.civic[e].max?"count has-text-success":t.civic[e].workers<=t.civic[e].max/3?"count has-text-caution":t.civic[e].workers<=.66*t.civic[e].max?"count has-text-warning":t.civic[e].workerst.civic.d_job===e},filters:{d_state:e=>t.civic.d_job===e?"*":"",event(a){if("unemployed"===e&&t.civic.unemployed.display||"hunter"===e&&!t.civic.unemployed.display){let e=Qs(3,14);if(0===a&&e.length>0)return e}return a},adjust:(e,t)=>"titan_colonist"===t&&s.ai_colonist?e+ta(s.ai_colonist):e}}),ls(o,(function(){return Xt[e](c)}),{elm:`#${o} .job_label`,classes:"has-background-light has-text-dark"})}}function ia(e,a){let r=t.civic.farmer.impact;return e&&(r+=t.tech.agriculture&&t.tech.agriculture>=2?1.15:.65),t.race.living_tool&&!a?r*=1+(t.tech.science&&t.tech.science>0?t.tech.science/5:0):r*=1+(t.tech.hoe&&t.tech.hoe>0?t.tech.hoe/3:0),r*="grassland"===t.city.biome?is.grassland.vars()[0]:1,r*="savanna"===t.city.biome?is.savanna.vars()[0]:1,r*="ashland"===t.city.biome?is.ashland.vars()[0]:1,r*="volcanic"===t.city.biome?is.volcanic.vars()[0]:1,r*="hellscape"===t.city.biome?is.hellscape.vars()[0]:1,r*=t.city.ptrait.includes("trashed")?ss.trashed.vars()[0]:1,a||(r*=Bi(t.civic.farmer.workers,"farmer")),r*=t.tech.agriculture>=7?1.1:1,r*=t.race.low_light?1-Ei.low_light.vars()[0]/100:1,a&&(r*=ta(1)),r}function sa(e){if(Ss($(e?"#skilledServants":"#foundry")),t.city.foundry&&t.city.foundry.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation){let a=$(e?"#skilledServants":"#foundry"),r=e?"{{ s.sused }} / {{ s.smax }}":"{{ f.crafting }} / {{ c.max }}",i=$(`

                ${z(e?"civics_skilled_servants":"craftsman_assigned")}

                ${r}
                `);a.append(i);let c=cn("summer"),o=["Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Aerogel","Nanoweave"];e||(o.push("Scarletite"),o.push("Quantium")),c&&!e&&o.push("Thermite");for(let r=0;r');a.append(s);let n,c=$('
                ');n="Scarletite"===i&&t.portal.hasOwnProperty("hell_forge")?$(`

                ${r}

                {{ f.${i} }} / {{ p.on | maxScar }}
                `):"Quantium"===i&&(t.space.hasOwnProperty("zero_g_lab")||t.tauceti.hasOwnProperty("infectious_disease_lab"))?$(`

                ${r}

                {{ f.${i} }} / {{ e.on | maxQuantium }}
                `):$(`

                ${r}

                ${e?`{{ s.sjobs.${i} }}`:`{{ f.${i} }}`}
                `),s.append(n),s.append(c),a.append(s);let o=$(`«`),l=$(`»`);c.append(o),c.append(l)}}let l=t.portal.hasOwnProperty("hell_forge")?{c:t.civic.craftsman,p:t.portal.hell_forge}:{c:t.civic.craftsman,e:t.space.hasOwnProperty("zero_g_lab")||t.tauceti.hasOwnProperty("infectious_disease_lab")?t.tech.isolation?t.tauceti.infectious_disease_lab:t.space.zero_g_lab:{count:0,on:0}};e?l.s=t.race.servants:l.f=t.city.foundry,Cs({el:e?"#skilledServants":"#foundry",data:l,methods:{add(a){let r=y(),i=-1;"Scarletite"===a?(i=s.hell_forge||0,t.race.high_pop&&(i*=Ei.high_pop.vars()[0])):"Quantium"===a&&(i=t.tech.isolation?Math.min(n.infectious_disease_lab,s.infectious_disease_lab)||0:Math.min(n.zero_g_lab,s.zero_g_lab)||0,t.race.high_pop&&(i*=Ei.high_pop.vars()[0]));for(let s=0;s0&&(-1===i||i>t.city.foundry[a])))break;t.civic.craftsman.workers++,t.city.foundry.crafting++,t.city.foundry[a]++,t.civic[t.civic.d_job].workers--}},sub(a){let r=y();for(let i=0;i0))break;t.race.servants.sjobs[a]--,t.race.servants.sused--}else{if(!(t.city.foundry[a]>0))break;t.city.foundry[a]--,t.civic.craftsman.workers--,t.city.foundry.crafting--,t.civic[t.civic.d_job].workers++}},level(){let a=e?t.race.servants.sused:t.civic.craftsman.workers,r=e?t.race.servants.smax:t.civic.craftsman.max;return 0===a?"count has-text-danger":a===r?"count has-text-success":a<=r/3?"count has-text-caution":a<=.66*r?"count has-text-warning":a"),a=t.resource[r].name,i=Ta(r,"auto").multiplier,s=t.genes.crafty?2:1,n=+t.resource[r].diff.toFixed(2),c=+(100*i).toFixed(0);e.append($(`
                ${z("craftsman_hover_bonus",[c.toLocaleString(),a])}
                `)),e.append($(`
                ${z("craftsman_hover_prod",[n.toLocaleString(),a])}
                `));let o=Ia();for(let a=0;a${z("craftsman_hover_cost",[i,t.resource[o[r][a].r].name])}
                `))}return e};tr(e?`scraft${r}`:`craft${r}`,r,"auto",a)}}e?ls("servantFoundry",(function(){return z("civics_skilled_servants_desc")}),{elm:"#skilledServants .foundry",classes:"has-background-light has-text-dark"}):ls("craftsmenFoundry",(function(){return z("job_craftsman_hover")}),{elm:"#foundry .foundry",classes:"has-background-light has-text-dark"}),t.race.servants&&!e&&t.race.servants.smax>0&&sa(!0)}}const na={prtl_fortress:{info:{name:z("portal_fortress_name"),desc:z("portal_fortress_desc"),repair(){let e=200;return s.repair_droid&&(e*=.95**s.repair_droid),Math.round(e)}},turret:{id:"portal-turret",title:()=>z(t.tech.turret?t.tech.turret>=2?"portal_turret_title3":"portal_turret_title2":"portal_turret_title1"),desc:()=>`
                ${z(t.tech.turret?t.tech.turret>=2?"portal_turret_title3":"portal_turret_title2":"portal_turret_title1")}
                ${z("requires_power")}
                `,reqs:{portal:2},cost:{Money:e=>Ps("turret",e,35e4,1.28,"portal"),Copper:e=>Ps("turret",e,5e4,1.28,"portal"),Adamantite:e=>Ps("turret",e,8e3,1.28,"portal"),Elerium:e=>Ps("turret",e,15,1.28,"portal"),Nano_Tube:e=>Ps("turret",e,28e3,1.28,"portal")},powered:()=>As(t.tech.turret?4+t.tech.turret:4),postPower(e){s.turret=t.portal.turret.on,Cs({el:"#fort"},"update")},effect(){let e=t.tech.turret?t.tech.turret>=2?70:50:35,a=$(this)[0].powered();return`
                ${z("portal_turret_effect",[e])}
                ${z("minus_power",[a])}
                `},action(){return!!ri($(this)[0])&&(Ft("turret","portal"),Yr($(this)[0])&&(s.turret++,Cs({el:"#fort"},"update")),!0)}},carport:{id:"portal-carport",title:z("portal_carport_title"),desc:()=>z("portal_carport_desc",[1]),reqs:{portal:2},cost:{Money:e=>Ps("carport",e,25e4,1.3,"portal"),Cement:e=>Ps("carport",e,18e3,1.3,"portal"),Oil:e=>Ps("carport",e,6500,1.3,"portal"),Plywood:e=>Ps("carport",e,8500,1.3,"portal")},repair(){let e=180;return s.repair_droid&&(e*=.92**s.repair_droid),Math.round(e)},effect:()=>`${z("portal_carport_effect",[1])}`,action(){return!!ri($(this)[0])&&(Ft("carport","portal"),t.civic.hell_surveyor.display=!0,t.resource.Infernite.display=!0,t.tech.infernite||(t.tech.infernite=1,Qr()),!0)}},war_droid:{id:"portal-war_droid",title:z("portal_war_droid_title"),desc:()=>`
                ${z("portal_war_droid_title")}
                ${z("requires_power")}
                `,reqs:{portal:5},cost:{Money:e=>Ps("war_droid",e,495e3,1.26,"portal"),Neutronium:e=>Ps("war_droid",e,1250,1.26,"portal"),Elerium:e=>Ps("war_droid",e,18,1.26,"portal"),Stanene:e=>Ps("war_droid",e,37500,1.26,"portal"),Soul_Gem:e=>Ps("war_droid",e,1,1.26,"portal")},powered:()=>As(2),effect(){return`
                ${z("portal_war_droid_effect")}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("war_droid","portal"),Yr($(this)[0]),!0)},flair:z("portal_war_droid_flair")},repair_droid:{id:"portal-repair_droid",title:z("portal_repair_droid_title"),desc:()=>`
                ${z("portal_repair_droid_title")}
                ${z("requires_power")}
                `,reqs:{portal:6},cost:{Money:e=>Ps("repair_droid",e,444e3,1.26,"portal"),Iron:e=>Ps("repair_droid",e,88e3,1.26,"portal"),Iridium:e=>Ps("repair_droid",e,17616,1.26,"portal"),Infernite:e=>Ps("repair_droid",e,666,1.26,"portal"),Soul_Gem:e=>Ps("repair_droid",e,1,1.15,"portal")},powered:()=>As(3),effect(){return`
                ${z("portal_repair_droid_effect",[5])}
                ${z("portal_repair_droid_effect2",[8])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("repair_droid","portal"),Yr($(this)[0]),!0)},flair:z("portal_repair_droid_flair")}},prtl_badlands:{info:{name:z("portal_badlands_name"),desc:z("portal_badlands_desc")},war_drone:{id:"portal-war_drone",title:z("portal_war_drone_title"),desc:()=>`
                ${z("portal_war_drone_title")}
                ${z("requires_power")}
                `,reqs:{portal:3},powered:()=>As(5),cost:{Money:e=>Ps("war_drone",e,65e4,1.28,"portal"),Alloy:e=>Ps("war_drone",e,6e4,1.28,"portal"),Graphene:e=>Ps("war_drone",e,1e5,1.28,"portal"),Elerium:e=>Ps("war_drone",e,25,1.28,"portal"),Soul_Gem:e=>Ps("war_drone",e,1,1.28,"portal")},effect(){return`
                ${z("portal_war_drone_effect")}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("war_drone","portal"),Yr($(this)[0]),!0)},flair:z("portal_war_drone_flair")},sensor_drone:{id:"portal-sensor_drone",title:z("portal_sensor_drone_title"),desc:()=>`
                ${z("portal_sensor_drone_title")}
                ${z("requires_power")}
                `,reqs:{infernite:2},powered:()=>As(3),cost:{Money:e=>Ps("sensor_drone",e,5e5,1.25,"portal"),Polymer:e=>Ps("sensor_drone",e,25e3,1.25,"portal"),Adamantite:e=>Ps("sensor_drone",e,12500,1.25,"portal"),Infernite:e=>Ps("sensor_drone",e,100,1.25,"portal")},effect(){let e=t.tech.infernite>=4?t.tech.infernite>=6?50:20:10,a=t.tech.infernite>=6?2500:1e3,r=t.race.cataclysm?`
                ${z("space_moon_observatory_cata_effect",[2])}
                `:`
                ${z("space_moon_observatory_effect",[2])}
                ${z("portal_sensor_drone_effect2",[2])}
                `,i=t.tech.science>=14?`
                ${z("city_max_knowledge",[a])}
                ${r}`:"";return`
                ${z("portal_sensor_drone_effect",[e])}
                ${i}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("sensor_drone","portal"),Yr($(this)[0]),!0)}},attractor:{id:"portal-attractor",title:z("portal_attractor_title"),desc:()=>`
                ${z("portal_attractor_title")}
                ${z("requires_power")}
                `,reqs:{portal:4},powered:()=>As(3),cost:{Money:e=>Ps("attractor",e,35e4,1.25,"portal"),Aluminium:e=>Ps("attractor",e,175e3,1.25,"portal"),Stanene:e=>Ps("attractor",e,9e4,1.25,"portal")},effect(){return`
                ${z("portal_attractor_effect1")}
                ${z("portal_attractor_effect2",[t.resource.Soul_Gem.name])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("attractor","portal"),Yr($(this)[0]),!0)}}},prtl_pit:{info:{name:z("portal_pit_name"),desc:z("portal_pit_desc")},pit_mission:{id:"portal-pit_mission",title:z("portal_pit_mission_title"),desc:z("portal_pit_mission_title"),reqs:{hell_pit:1},grant:["hell_pit",2],queue_complete:()=>t.tech.hell_pit>=2?0:1,cost:{Money:()=>5e6,Helium_3:()=>3e5,Deuterium:()=>2e5},effect:z("portal_pit_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_pit_mission_result"),"info",!1,["progress","hell"]),!0)}},assault_forge:{id:"portal-assault_forge",title:z("portal_assault_forge_title"),desc:z("portal_assault_forge_title"),reqs:{hell_pit:2},grant:["hell_pit",3],queue_complete:()=>t.tech.hell_pit>=3?0:1,cost:{Money:()=>1e7,HellArmy:()=>Math.round(650/be(1,"hellArmy")),Cement:()=>1e7,Adamantite:()=>125e4,Elerium:()=>2400,Stanene:()=>9e5},effect:z("portal_assault_forge_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_assault_forge_result"),"info",!1,["progress","hell"]),!0)}},soul_forge:{id:"portal-soul_forge",title:z("portal_soul_forge_title"),desc:()=>`
                ${z("portal_soul_forge_desc")}
                ${z("requires_power")}
                `,reqs:{hell_pit:4},queue_complete:()=>1-t.portal.soul_forge.count,powered:()=>As(30),postPower(e){Cs({el:"#fort"},"update")},cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?25e6:0,Graphene:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?15e5:0,Infernite:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?25e3:0,Bolognium:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?1e5:0},effect(e){let a=`
                ${z("portal_soul_forge_effect",[t.resource.Soul_Gem.name])}
                `;if((e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)>=1){let e=t.tech.hell_pit>=6?75e4:1e6;t.tech.hell_pit>=7&&s.soul_attractor>0&&(e*=.97**s.soul_attractor),a+=`
                ${z("portal_soul_forge_effect2",[t.portal.soul_forge?t.portal.soul_forge.kills.toLocaleString():0,Math.round(e).toLocaleString()])}
                `}return`${a}
                ${z("portal_soul_forge_soldiers",[da()])}, ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!(ri($(this)[0])&&t.portal.soul_forge.count<1)&&(Ft("soul_forge","portal"),Yr($(this)[0]),!0)}},gun_emplacement:{id:"portal-gun_emplacement",title:z("portal_gun_emplacement_title"),desc:()=>`
                ${z("portal_gun_emplacement_title")}
                ${z("requires_power")}
                `,reqs:{hell_gun:1},powered:()=>As(3),cost:{Money:e=>Ps("gun_emplacement",e,4e6,1.25,"portal"),Coal:e=>Ps("gun_emplacement",e,25e4,1.25,"portal"),Steel:e=>Ps("gun_emplacement",e,12e5,1.25,"portal"),Wrought_Iron:e=>Ps("gun_emplacement",e,2e5,1.25,"portal")},effect(){let e=t.tech.hell_gun>=2?2:1,a=t.tech.hell_gun>=2?35:20,r=t.tech.hell_gun>=2?75:40;return`
                ${z("portal_gun_emplacement_effect",[e])}
                ${z("portal_gun_emplacement_effect2",[a,r])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("gun_emplacement","portal"),Yr($(this)[0]),!0)}},soul_attractor:{id:"portal-soul_attractor",title:z("portal_soul_attractor_title"),desc:()=>`
                ${z("portal_soul_attractor_title")}
                ${z("requires_power")}
                `,reqs:{hell_pit:5},powered:()=>As(4),cost:{Money:e=>Ps("soul_attractor",e,12e6,1.25,"portal"),Stone:e=>Ps("soul_attractor",e,23e6,1.25,"portal"),Nano_Tube:e=>Ps("soul_attractor",e,314159,1.25,"portal"),Vitreloy:e=>Ps("soul_attractor",e,1618,1.25,"portal"),Aerogel:e=>Ps("soul_attractor",e,18e4,1.25,"portal")},effect(){let e=t.tech.hell_pit>=7?`
                ${z("portal_soul_attractor_effect2",[3])}
                `:"",a=t.blood.attract?5*t.blood.attract:0;return`
                ${z("portal_soul_attractor_effect",[40+a,120+a])}
                ${e}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("soul_attractor","portal"),Yr($(this)[0]),!0)}},soul_capacitor:{id:"portal-soul_capacitor",title:z("portal_soul_capacitor_title"),desc:()=>`
                ${z("portal_soul_capacitor_desc")}
                ${z("requires_power")}
                `,reqs:{forbidden:2},powered:()=>As(125),queue_complete:()=>40-t.portal.soul_capacitor.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,75e7,1.01,"portal"),Crystal:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,125e4,1.01,"portal"),Adamantite:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,65e5,1.01,"portal"),Infernite:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,1e4,1.01,"portal"),Stanene:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,25e5,1.01,"portal"),Bolognium:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,1e6,1.01,"portal"),Soul_Gem:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,3,1.01,"portal"),Mythril:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,125e4,1.01,"portal")},effect(){let e=t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.ecap:0,a=`
                ${z("portal_soul_capacitor_effect",[(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.energy:0).toLocaleString()])}
                `;return a+=`
                ${z("portal_soul_capacitor_effect2",[e.toLocaleString()])}
                `,a+=`
                ${z("portal_soul_capacitor_effect3",[25e5.toLocaleString()])}
                `,a+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,a},action(){return!!(t.portal.soul_capacitor.count<40&&ri($(this)[0]))&&(t.portal.soul_capacitor.count++,Yr($(this)[0]),!0)},postPower(){ai($(this)[0],"portal","soul_capacitor")}},absorption_chamber:{id:"portal-absorption_chamber",title:z("portal_absorption_chamber_title"),desc:e=>!t.interstellar.hasOwnProperty("absorption_chamber")||t.portal.absorption_chamber.count<100||e?`
                ${z("portal_absorption_chamber_title")}
                ${z("requires_segmemts",[100])}
                `:`
                ${z("portal_absorption_chamber_title")}
                `,reqs:{forbidden:3},queue_size:5,queue_complete:()=>100-t.portal.absorption_chamber.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e6:0,Alloy:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e4:0,Neutronium:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?1e3:0,Orichalcum:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?25e4:0,Nanoweave:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0);if(a<100){let e=100-a;return`
                ${z("portal_absorption_chamber_incomplete")}
                ${z("space_dwarf_collider_effect2",[e])}
                `}if(5===t.tech.forbidden)return`
                ${z("portal_absorption_chamber_effect_eld",[1e8.toLocaleString()])}
                ${z("tech_demonic_infusion_effect2",[Gs("descend").artifact])}
                `;{let e=qt();return`
                ${z("portal_absorption_chamber_effect",[1e8.toLocaleString()])}
                ${e}
                `}},action(){if(ri($(this)[0])){if(t.portal.absorption_chamber.count<100)return Ft("absorption_chamber","portal"),t.portal.absorption_chamber.count>=100&&(t.tech.forbidden=4),!0;if(t.portal.soul_capacitor.energy>=1e8)return 5===t.tech.forbidden?R():Qt(),!0}return!1}}},prtl_ruins:{info:{name:z("portal_ruins_name"),desc:z("portal_ruins_desc"),support:"guard_post",prop(){let e=` - ${z("portal_ruins_security")}: {{ on | filter('army') }}`;return e+=` - ${z("portal_ruins_supressed")}: {{ on | filter('sup') }}`,e},filter(e,t){let a=ga("ruins");switch(t){case"army":return Math.round(a.rating);case"sup":return+(100*a.supress).toFixed(2)+"%"}}},ruins_mission:{id:"portal-ruins_mission",title:z("portal_ruins_mission_title"),desc:z("portal_ruins_mission_title"),reqs:{hell_ruins:1},grant:["hell_ruins",2],queue_complete:()=>t.tech.hell_ruins>=2?0:1,cost:{Money:()=>1e8,Oil:()=>5e5,Helium_3:()=>5e5},effect:z("portal_ruins_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_ruins_mission_result"),"info",!1,["progress","hell"]),t.portal.vault={count:0},t.portal.stonehedge={count:0},t.portal.archaeology={count:0,on:0},!0)}},guard_post:{id:"portal-guard_post",title:z("portal_guard_post_title"),desc:()=>`
                ${z("portal_guard_post_title")}
                ${z("requires_soldiers")}
                ${z("requires_power")}
                `,reqs:{hell_ruins:2},cost:{Money:e=>Ps("guard_post",e,8e6,1.06,"portal"),Lumber:e=>Ps("guard_post",e,65e5,1.06,"portal"),Sheet_Metal:e=>Ps("guard_post",e,3e5,1.06,"portal")},powered:()=>As(5),support:()=>1,effect(){let e=t.race.holy?1+Ei.holy.vars()[1]/100:1,a=ts("unicorn");return a>0&&(e*=1+Ei.holy.vars(1)[1]/100*a),`
                ${z("portal_guard_post_effect1",[Math.round(e*be(ta(1),"hellArmy",0))])}
                ${z("portal_guard_post_effect2",[ta(1),$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("guard_post","portal"),t.portal.guard_post.on++,!0)},postPower(){Cs({el:"#srprtl_ruins"},"update"),Cs({el:"#srprtl_gate"},"update")}},vault:{id:"portal-vault",title:z("portal_vault_title"),desc:z("portal_vault_title"),reqs:{hell_ruins:2,hell_vault:1},condition:()=>!(t.portal.vault.count>=2),queue_complete:()=>2-t.portal.vault.count,cost:{Soul_Gem:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===0?100:0,Money:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?25e7:0,Adamantite:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?125e5:0,Orichalcum:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?3e7:0},effect:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)<1?z("portal_vault_effect",[100]):z("portal_vault_effect2"),action(){return!!(t.portal.vault.count<2&&ri($(this)[0]))&&(Ft("vault","portal"),2===t.portal.vault.count&&(t.tech.hell_ruins=3,t.resource.Codex.display=!0,t.resource.Codex.amount=1,hs(z("portal_vault_result"),"info",!1,["progress","hell"])),!0)},post(){2===t.portal.vault.count&&(Qr(),ua(),_s())}},archaeology:{id:"portal-archaeology",title:z("portal_archaeology_title"),desc:()=>`
                ${z("portal_archaeology_title")}
                ${z("requires_security")}
                ${z("requires_power")}
                `,reqs:{hell_ruins:2},cost:{Money:e=>Ps("archaeology",e,1e8,1.25,"portal"),Titanium:e=>Ps("archaeology",e,375e4,1.25,"portal"),Mythril:e=>Ps("archaeology",e,125e4,1.25,"portal")},powered:()=>As(8),effect(){return`
                ${z("portal_archaeology_effect",[ta(2)])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){if(ri($(this)[0])){if(Ft("archaeology","portal"),t.civic.archaeologist.display=!0,Yr($(this)[0])&&t.civic[t.civic.d_job].workers>0){let e=t.civic[t.civic.d_job].workers-ta(2)<0?t.civic[t.civic.d_job].workers:ta(2);t.civic[t.civic.d_job].workers-=e,t.civic.archaeologist.workers+=e}return!0}return!1}},arcology:{id:"portal-arcology",title:z("portal_arcology_title"),desc:()=>`
                ${z("portal_arcology_title")}
                ${z("requires_security")}
                ${z("requires_power")}
                `,reqs:{housing:4},cost:{Money:e=>Ps("arcology",e,18e7,1.22,"portal"),Graphene:e=>Ps("arcology",e,75e5,1.22,"portal"),Bolognium:e=>Ps("arcology",e,28e5,1.22,"portal"),Orichalcum:e=>Ps("arcology",e,55e5,1.22,"portal"),Nanoweave:e=>Ps("arcology",e,65e4,1.22,"portal"),Horseshoe:()=>t.race.hooved?13:0},powered:()=>As(25),effect(){let e=ga("ruins"),t=br(8*bi()*e.supress);t=+t.toFixed(0);let a=10*Math.round(_),r=`
                ${z("plus_max_resource",[a,z("resource_Crates_name")])}
                ${z("plus_max_resource",[a,z("resource_Containers_name")])}
                `;return`
                ${z("plus_max_resource",[`$${t.toLocaleString()}`,z("resource_Money_name")])}
                ${z("plus_max_citizens",[$(this)[0].citizens()])}
                ${z("plus_max_resource",[ta(5),z("civics_garrison_soldiers")])}
                ${z("portal_guard_post_effect1",[75])}
                ${r}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("arcology","portal"),Yr($(this)[0])&&(t.resource[t.race.species].max+=8),!0)},post(){Cs({el:"#srprtl_ruins"},"update"),Qr()},postPower(){Cs({el:"#srprtl_ruins"},"update"),Cs({el:"#srprtl_gate"},"update")},citizens(){let e=8;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},hell_forge:{id:"portal-hell_forge",title:z("portal_hell_forge_title"),desc:()=>`
                ${z("portal_hell_forge_title")}
                ${z("requires_security")}
                ${z("requires_power")}
                `,reqs:{scarletite:1},cost:{Money:e=>Ps("hell_forge",e,25e7,1.15,"portal"),Coal:e=>Ps("hell_forge",e,165e4,1.22,"portal"),Steel:e=>Ps("hell_forge",e,38e5,1.22,"portal"),Iridium:e=>Ps("hell_forge",e,12e5,1.22,"portal"),Neutronium:e=>Ps("hell_forge",e,28e4,1.22,"portal"),Soul_Gem:e=>Ps("hell_forge",e,5,1.22,"portal")},powered:()=>As(12),special:!0,effect(){let e=+(75*ga("ruins").supress).toFixed(1),a=t.tech.inferno_power?`
                ${z("portal_hell_forge_effect2",[10,z("portal_inferno_power_title")])}
                `:"";return`
                ${z("portal_hell_forge_effect",[ta(1)])}
                ${a}
                ${z("interstellar_stellar_forge_effect3",[3])}
                ${z("interstellar_stellar_forge_effect",[e])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("hell_forge","portal"),Yr($(this)[0])&&(t.city.smelter.cap+=3,t.city.smelter.Oil+=3,t.city.smelter.Iron+=3),!0)},post(){sa()},postPower(e){if(!e&&t.portal.hell_forge.on`
                ${z("portal_inferno_power_title")}
                `,reqs:{inferno_power:1},cost:{Money:e=>Ps("inferno_power",e,275e6,1.16,"portal"),Neutronium:e=>Ps("inferno_power",e,375e4,1.18,"portal"),Stanene:e=>Ps("inferno_power",e,12e6,1.18,"portal"),Bolognium:e=>Ps("inferno_power",e,8e6,1.18,"portal")},powered(){let e=20;return s.hasOwnProperty("hell_forge")&&(e+=10*s.hell_forge),Fs(-e)},fuel:{Infernite:5,Coal:100,Oil:80},effect(){let e=$(this)[0].fuel;return`
                ${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
                ${z("portal_inferno_power_effect",[e.Infernite,t.resource.Infernite.name,e.Coal,t.resource.Coal.name,e.Oil,t.resource.Oil.name])}
                `},action(){return!!ri($(this)[0])&&(Ft("inferno_power","portal"),t.portal.inferno_power.on++,!0)},post(){Cs({el:"#foundry"},"update")}},ancient_pillars:{id:"portal-ancient_pillars",title:z("portal_ancient_pillars_title"),desc:z("portal_ancient_pillars_desc"),reqs:{hell_ruins:2},queue_complete:()=>t.tech.pillars&&1===t.tech.pillars&&"micro"!==t.race.universe?1:0,cost:{Harmony:e=>void 0!==e?e+Object.keys(t.pillars).lengthObject.keys(Ki).length-1,on:()=>Object.keys(t.pillars).length,effect(e){let a=(e||0)+Object.keys(t.pillars).length;return a>=1?`
                ${z("portal_ancient_pillars_effect2",[Object.keys(Ki).length-1,a])}
                `:`
                ${z("portal_ancient_pillars_effect",[Object.keys(Ki).length-1])}
                `},action(){return!(!t.tech.pillars||1!==t.tech.pillars||"micro"===t.race.universe||!ri($(this)[0])||(t.pillars[t.race.species]=Mn(),t.tech.pillars=2,br(0,!1,!0),Ks(!0),oa(!0),qn("resonance"),Cs({el:"#portal-ancient_pillars"},"update"),0))}}},prtl_gate:{info:{name:z("portal_gate_name"),desc:()=>`${z("portal_gate_desc")} ${z(t.tech.wtower&&t.tech.etower?"portal_gate_open":"portal_gate_closed")}`,support:"guard_post",hide_support:!0,prop(){let e=` - ${z("portal_ruins_security")}: {{ on | filter('army') }}`;return e+=` - ${z("portal_ruins_supressed")}: {{ on | filter('sup') }}`,e},filter(e,t){let a=ga("gate");switch(t){case"army":return Math.round(a.rating);case"sup":return+(100*a.supress).toFixed(2)+"%"}}},gate_mission:{id:"portal-gate_mission",title:z("portal_gate_mission_title"),desc:z("portal_gate_mission_title"),reqs:{high_tech:18},grant:["hell_gate",1],queue_complete:()=>t.tech.hell_gate>=1?0:1,cost:{Money:()=>25e7,Knowledge:()=>275e5},effect:z("portal_gate_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_gate_mission_result"),"info",!1,["progress","hell"]),!0)}},west_tower:{id:"portal-west_tower",title:z("portal_west_tower"),desc(e){let a=oa();return!t.portal.hasOwnProperty("west_tower")||t.portal.west_tower.count${z("portal_west_tower")}
                ${z("requires_segmemts",[a])}
                `:`
                ${z("portal_west_tower")}
                `},reqs:{hell_gate:2},queue_size:25,queue_complete:()=>oa()-t.portal.west_tower.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)${z("portal_tower_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                ${z("portal_tower_effect2")}
                `}return z("portal_tower_effect")},action(){return!!(t.portal.west_tower.count=oa()&&(t.tech.wtower=1,t.tech.wtower&&t.tech.etower&&!t.tech.hell_lake&&(t.tech.hell_lake=1,t.settings.portal.lake=!0,t.portal.harbour={count:0,on:0,support:0,s_max:0},hs(z("portal_gate_open"),"info",!1,["progress","hell"]),ua()))}},east_tower:{id:"portal-east_tower",title:z("portal_east_tower"),desc(e){let a=oa();return!t.portal.hasOwnProperty("east_tower")||t.portal.east_tower.count${z("portal_east_tower")}
                ${z("requires_segmemts",[a])}
                `:`
                ${z("portal_east_tower")}
                `},reqs:{hell_gate:2},queue_size:25,queue_complete:()=>oa()-t.portal.east_tower.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)${z("portal_tower_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                ${z("portal_tower_effect2")}
                `}return z("portal_tower_effect")},action(){return!!(t.portal.east_tower.count=oa()&&(t.tech.etower=1,t.tech.wtower&&t.tech.etower&&!t.tech.hell_lake&&(t.tech.hell_lake=1,t.settings.portal.lake=!0,t.portal.harbour={count:0,on:0,support:0,s_max:0},hs(z("portal_gate_open"),"info",!1,["progress","hell"]),ua()))}},gate_turret:{id:"portal-gate_turret",title:z("portal_gate_turret_title"),desc:()=>`
                ${z("portal_gate_turret_title")}
                ${z("requires_power")}
                `,reqs:{hell_gate:3},powered:()=>As(6),cost:{Money:e=>Ps("gate_turret",e,375e4,1.22,"portal"),Iron:e=>Ps("gate_turret",e,425e4,1.22,"portal"),Elerium:e=>Ps("gate_turret",e,275,1.22,"portal"),Stanene:e=>Ps("gate_turret",e,85e4,1.22,"portal")},effect(){let e=100;t.race.holy&&(e*=1+Ei.holy.vars()[1]/100);let a=ts("unicorn");a>0&&(e*=1+Ei.holy.vars(1)[1]/100*a);let r=t.tech.hell_gun>=2?65:40,i=t.tech.hell_gun>=2?100:60;return`
                ${z("portal_gate_turret_effect",[Math.round(e)])}
                ${z("portal_gate_turret_effect2",[r,i])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("gate_turret","portal"),Yr($(this)[0]),!0)},postPower(){Cs({el:"#srprtl_gate"},"update")}},infernite_mine:{id:"portal-infernite_mine",title:z("portal_infernite_mine_title"),desc:()=>`
                ${z("portal_infernite_mine_title")}
                ${z("requires_security")}
                ${z("requires_power")}
                `,reqs:{hell_gate:4},powered:()=>As(5),powerBalancer:()=>[{r:"Infernite",k:"lpmod"}],cost:{Money:e=>Ps("infernite_mine",e,75e6,1.26,"portal"),Alloy:e=>Ps("infernite_mine",e,245e4,1.26,"portal"),Orichalcum:e=>Ps("infernite_mine",e,165e4,1.26,"portal"),Wrought_Iron:e=>Ps("infernite_mine",e,68e4,1.26,"portal")},effect(){return`
                ${z("portal_infernite_mine_effect",[+$e("infernite_mine").toFixed(3)])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("infernite_mine","portal"),Yr($(this)[0]),!0)}}},prtl_lake:{info:{name:z("portal_lake_name"),desc:z("portal_lake_desc"),support:"harbour"},lake_mission:{id:"portal-lake_mission",title:z("portal_lake_mission_title"),desc:z("portal_lake_mission_title"),reqs:{hell_lake:1},grant:["hell_lake",2],queue_complete:()=>t.tech.hell_lake>=2?0:1,cost:{Money:()=>5e8,Oil:()=>75e4,Helium_3:()=>6e5},effect:z("portal_lake_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_lake_mission_result"),"info",!1,["progress","hell"]),!0)}},harbour:{id:"portal-harbour",title:z("portal_harbour_title"),desc:()=>`
                ${z("portal_harbour_title")}
                ${z("requires_power")}
                `,reqs:{hell_lake:3},powered:()=>+As(500*.92**(s.cooling_tower||0)).toFixed(2),support:()=>1,cost:{Money:e=>Ps("harbour",e,225e6,ca(1.18),"portal"),Cement:e=>Ps("harbour",e,5e7,ca(1.18),"portal"),Iridium:e=>Ps("harbour",e,75e5,ca(1.18),"portal"),Infernite:e=>Ps("harbour",e,8e5,ca(1.18),"portal"),Stanene:e=>Ps("harbour",e,175e5,ca(1.18),"portal")},wide:!0,res:()=>["Oil","Alloy","Polymer","Iridium","Helium_3","Deuterium","Neutronium","Adamantite","Infernite","Nano_Tube","Graphene","Stanene","Bolognium","Orichalcum"],val(e){switch(e){case"Oil":return 3e4;case"Alloy":case"Polymer":return 25e4;case"Iridium":return 2e5;case"Helium_3":return 18e3;case"Deuterium":return 12e3;case"Neutronium":return 18e4;case"Adamantite":return 15e4;case"Infernite":return 75e3;case"Nano_Tube":return 75e4;case"Graphene":case"Stanene":return 12e5;case"Bolognium":case"Orichalcum":return 13e4;default:return 0}},effect(){let e='
                ';for(const a of $(this)[0].res())t.resource[a].display&&(e+=`${z("plus_max_resource",[x(+br($(this)[0].val(a)).toFixed(0),1),t.resource[a].name])}`);return e+="
                ",`
                ${z("portal_harbour_effect",[1])}
                ${e}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){if(ri($(this)[0])){if(Ft("harbour","portal"),Yr($(this)[0]))for(const e of $(this)[0].res())t.resource[e].display&&(t.resource[e].max+=br($(this)[0].val(e)));return!0}return!1}},cooling_tower:{id:"portal-cooling_tower",title:z("portal_cooling_tower_title"),desc:()=>`
                ${z("portal_cooling_tower_title")}
                ${z("requires_power")}
                `,reqs:{hell_lake:6},powered:()=>As(10),cost:{Money:e=>Ps("cooling_tower",e,25e7,1.2,"portal"),Polymer:e=>Ps("cooling_tower",e,12e6,1.2,"portal"),Orichalcum:e=>Ps("cooling_tower",e,85e5,1.2,"portal"),Brick:e=>Ps("cooling_tower",e,25e4,1.2,"portal")},effect(){return`
                ${z("portal_cooling_tower_effect",[8])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("cooling_tower","portal"),Yr($(this)[0]),!0)}},bireme:{id:"portal-bireme",title:z("portal_bireme_title"),desc:()=>`
                ${z("portal_bireme_title")}
                ${z("space_support",[z("lake")])}
                `,reqs:{hell_lake:4},powered:()=>As(1),support:()=>-1,cost:{Money:e=>Ps("bireme",e,19e7,1.24,"portal"),Helium_3:e=>Ps("bireme",e,225e3,1.24,"portal"),Adamantite:e=>Ps("bireme",e,15e6,1.24,"portal"),Nano_Tube:e=>Ps("bireme",e,18e6,1.24,"portal"),Soul_Gem:e=>Ps("bireme",e,10,1.24,"portal"),Scarletite:e=>Ps("bireme",e,125e3,1.24,"portal")},effect(){let e=t.blood.spire&&t.blood.spire>=2?20:15;return`
                ${z("space_used_support",[z("lake")])}
                ${z("portal_bireme_effect",[e])}
                ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                `},ship:{civ:()=>0,mil:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2},action(){return!!ri($(this)[0])&&(Ft("bireme","portal"),t.portal.harbour.support`
                ${z("portal_transport_title")}
                ${z("space_support",[z("lake")])}
                `,reqs:{hell_lake:5},powered:()=>As(1),support:()=>-1,cost:{Money:e=>Ps("transport",e,3e8,1.22,"portal"),Oil:e=>Ps("transport",e,18e4,1.22,"portal"),Alloy:e=>Ps("transport",e,18e6,1.22,"portal"),Graphene:e=>Ps("transport",e,125e5,1.22,"portal"),Soul_Gem:e=>Ps("transport",e,5,1.22,"portal"),Scarletite:e=>Ps("transport",e,25e4,1.22,"portal")},effect(){let e=+((t.blood.spire&&t.blood.spire>=2?.8:.85)**(o.bireme||0)*100).toFixed(1);return`
                ${z("space_used_support",[z("lake")])}
                ${z("portal_transport_effect",[5])}
                ${z("portal_transport_effect2",[e])}
                ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                `},special:!0,sAction(){t.settings.civTabs=4,t.settings.marketTabs=3,t.settings.tabLoad||(kt("mTabResource"),_s("portal-transport"))},ship:{civ:()=>t.race.high_pop?3*Ei.high_pop.vars()[0]:3,mil:()=>0},action(){return!!ri($(this)[0])&&(Ft("transport","portal"),t.portal.harbour.support` - ${z("portal_spire_supply")}: {{ supply | filter }} / {{ sup_max }} (+{{ diff | filter(2) }}/s)`,filter:(e,t)=>t?+e.toFixed(t):Math.floor(e)},spire_mission:{id:"portal-spire_mission",title:z("portal_spire_mission_title"),desc:z("portal_spire_mission_title"),reqs:{hell_spire:1},grant:["hell_spire",2],queue_complete:()=>t.tech.hell_spire>=2?0:1,cost:{Species:()=>Rs(50),Oil:()=>9e5,Helium_3:()=>75e4,Structs:()=>({portal:{bireme:{s:"prtl_lake",count:1,on:1},transport:{s:"prtl_lake",count:1,on:1}}})},effect:z("portal_spire_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_spire_mission_result"),"info",!1,["progress","hell"]),!0)},flair:z("portal_spire_mission_flair")},purifier:{id:"portal-purifier",title:z("portal_purifier_title"),desc:()=>`
                ${z("portal_purifier_desc")}
                ${z("requires_power")}
                `,reqs:{hell_spire:3},cost:{Money:e=>Ps("purifier",e,85e6,ca(1.15),"portal"),Supply:e=>t.portal.purifier&&0===t.portal.purifier.count?100:Ps("purifier",e,4200,ca(1.2),"portal")},powered:()=>As(125),support:()=>t.tech.b_stone&&t.tech.b_stone>=3?1.25:1,effect(){return`
                ${z("portal_purifier_effect",[$(this)[0].support()])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(Ft("purifier","portal"),Yr($(this)[0]),!0)}},port:{id:"portal-port",title:z("portal_port_title"),desc:()=>`
                ${z("portal_port_title")}
                ${z("portal_spire_support")}
                `,reqs:{hell_spire:3},cost:{Money:e=>Ps("port",e,135e6,ca(1.2),"portal"),Supply:e=>t.portal.hasOwnProperty("port")&&0===t.portal.port.count?100:Ps("port",e,6250,ca(1.2),"portal")},powered:()=>As(1),support:()=>-1,effect(){let e=1e4;return l.base_camp&&(e*=1+.4*l.base_camp),`
                ${z("portal_port_effect1",[$(this)[0].support()])}
                ${z("portal_port_effect2",[Math.round(e)])}
                `},action(){return!!ri($(this)[0])&&(Ft("port","portal"),t.portal.purifier.support`
                ${z("portal_base_camp_title")}
                ${z("portal_spire_support")}
                `,reqs:{hell_spire:4},cost:{Money:e=>Ps("base_camp",e,425e6,ca(1.2),"portal"),Supply:e=>Ps("base_camp",e,5e4,ca(1.2),"portal")},powered:()=>As(1),support:()=>-1,effect(){return`
                ${z("portal_port_effect1",[$(this)[0].support()])}
                ${z("portal_base_camp_effect",[40])}
                `},action(){return!!ri($(this)[0])&&(Ft("base_camp","portal"),t.portal.purifier.support!t.portal.hasOwnProperty("bridge")||t.portal.bridge.count<10||e?`
                ${z("portal_bridge_title")}
                ${z("requires_segmemts",[10])}
                `:`
                ${z("portal_bridge_title")}
                `,reqs:{hell_spire:5},queue_size:1,queue_complete:()=>10-t.portal.bridge.count,cost:{Species:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?Rs(10):0,Money:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?5e8:0,Supply:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?1e5:0},effect(e){let a=(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0);if(a<10){let e=10-a;return`
                ${z("portal_bridge_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                ${z("portal_bridge_effect2")}
                `}return z("portal_bridge_complete")},action(){return!!(t.portal.bridge.count<10&&ri($(this)[0]))&&(Ft("bridge","portal"),t.portal.bridge.count>=10&&(t.portal.sphinx={count:0},t.tech.hell_spire=6,ua()),!0)}},sphinx:{id:"portal-sphinx",title:()=>7===t.tech.hell_spire?z("portal_sphinx_solve"):z("portal_sphinx_title"),desc:z("portal_sphinx_desc"),reqs:{hell_spire:6},queue_complete:()=>8-t.tech.hell_spire,cost:{Knowledge(e){let a=(e||0)+(!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2);return 1===a?5e7:0===a?4e7:0}},effect(e){let a=(e||0)+(!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2);return z(1===a?"portal_sphinx_effect2":2===a?"portal_sphinx_effect3":"portal_sphinx_effect")},action(){if(ri($(this)[0])){if(6===t.tech.hell_spire)return t.tech.hell_spire=7,hs(z("portal_sphinx_msg"),"info",!1,["progress","hell"]),ua(),!0;if(7===t.tech.hell_spire)return t.tech.hell_spire=8,ua(),hs(z("portal_sphinx_answer_msg"),"info",!1,["progress","hell"]),!0}return!1}},bribe_sphinx:{id:"portal-bribe_sphinx",title:z("portal_sphinx_bribe"),desc:z("portal_sphinx_desc"),reqs:{hell_spire:7},condition:()=>!(!t.tech.hell_spire||7!==t.tech.hell_spire||t.tech.sphinx_bribe),cost:{Soul_Gem:()=>250,Supply:()=>5e5},effect:()=>z("portal_sphinx_bribe_effect"),action(){return!(!ri($(this)[0])||7!==t.tech.hell_spire||t.tech.sphinx_bribe||(t.tech.sphinx_bribe=1,t.resource.Codex.display=!0,t.resource.Codex.amount=1,hs(z("portal_sphinx_bribe_msg"),"info",!1,["progress","hell"]),0))},post(){t.tech.sphinx_bribe&&(Qr(),ua(),_s("portal-bribe_sphinx"))}},spire_survey:{id:"portal-spire_survey",title:z("portal_spire_survey_title"),desc:z("portal_spire_survey_title"),reqs:{hell_spire:8},grant:["hell_spire",9],queue_complete:()=>t.tech.hell_spire>=9?0:1,cost:{Oil:()=>12e5,Helium_3:()=>9e5},effect:z("portal_spire_survey_effect"),action(){return!!ri($(this)[0])&&(t.portal.mechbay={count:0,on:0,bay:0,max:0,active:0,scouts:0,mechs:[]},t.portal.spire={count:1,progress:0,boss:"",type:"",status:{}},function(){let e=["sand","swamp","forest","jungle","rocky","gravel","muddy","grass","brush","concrete"];if(t.portal.spire.type=e[Math.floor(m(0,e.length))],t.portal.spire.count>=10){t.portal.spire.status={};let e=["freeze","hot","corrosive","humid","windy","hilly","mountain","radioactive","quake","dust","river","tar","steam","flooded","fog","rain","hail","chasm","dark","gravity"];if($a(e[Math.floor(m(0,e.length))]),t.portal.spire.count>=25&&t.portal.spire.count<=100){let a=105-t.portal.spire.count;Math.floor(m(0,a)<=5)&&$a(e[Math.floor(m(0,e.length))])}else if(t.portal.spire.count>100&&t.portal.spire.count<=250){$a(e[Math.floor(m(0,e.length))]);let a=260-t.portal.spire.count;Math.floor(m(0,a)<=10)&&$a(e[Math.floor(m(0,e.length))])}else if(t.portal.spire.count>250&&t.portal.spire.count<=1e3){$a(e[Math.floor(m(0,e.length))]),$a(e[Math.floor(m(0,e.length))]);let a=1025-t.portal.spire.count;Math.floor(m(0,a)<=25)&&$a(e[Math.floor(m(0,e.length))])}else t.portal.spire.count>1e3&&($a(e[Math.floor(m(0,e.length))]),$a(e[Math.floor(m(0,e.length))]),$a(e[Math.floor(m(0,e.length))]))}let a=Object.keys(va).filter((function(e){let a=Object.keys(va[e].nozone);return!a.some((e=>Object.keys(t.portal.spire.status).includes(e)))&&!a.includes(t.portal.spire.type)}));t.portal.spire.boss=a[Math.floor(m(0,a.length))]}(),hs(z("portal_spire_survey_msg"),"info",!1,["progress","hell"]),!0)},post(){t.tech.hell_spire&&9===t.tech.hell_spire&&(ua(),_s("portal-spire_survey"))}},mechbay:{id:"portal-mechbay",title:z("portal_mechbay_title"),desc:()=>`
                ${z("portal_mechbay_title")}
                ${z("portal_spire_support")}
                `,reqs:{hell_spire:9},cost:{Money:e=>Ps("mechbay",e,1e8,1.2,"portal"),Supply:e=>Ps("mechbay",e,25e4,1.2,"portal")},powered:()=>As(1),support:()=>-1,special:!0,sAction(){t.settings.civTabs=2,t.settings.govTabs=4,t.settings.tabLoad||(kt("mTabCivic"),_s("portal-mechbay"))},effect(){let e=t.portal.hasOwnProperty("mechbay")?t.portal.mechbay.bay:0,a=t.portal.hasOwnProperty("mechbay")?t.portal.mechbay.max:0;return`
                ${z("portal_port_effect1",[$(this)[0].support()])}
                ${z("portal_mechbay_effect")}
                ${z("portal_mechbay_effect2",[e,a])}
                `},action(){return!!ri($(this)[0])&&(Ft("mechbay","portal"),t.portal.purifier.support0,cost:{},effect(){let e=t.portal.hasOwnProperty("spire")?t.portal.spire.count:0,a=t.portal.hasOwnProperty("spire")?`${z(`portal_spire_type_${t.portal.spire.type}`)}`:"?",r="";t.portal.hasOwnProperty("spire")&&Object.keys(t.portal.spire.status).length>0&&(r=`
                ${z("portal_spire_hazard",[Object.keys(t.portal.spire.status).map((e=>`${z(`portal_spire_status_${e}`)}`)).join(", ")])}
                `);let i=t.portal.hasOwnProperty("spire")?`${+t.portal.spire.progress.toFixed(3)}%`:"0%",s=`
                ${z("portal_spire_effect",[e])}
                ${z("portal_spire_type",[a])}
                ${r}
                ${z("portal_spire_progress",[i])}
                `,n=t.portal.hasOwnProperty("spire")?t.portal.spire.boss:"crazed",c=`
                ${z("portal_spire_mob",[`${z(`portal_mech_boss_${n}`)}`])}
                `,o="???",l="???";if(t.stats.spire){let e=function(e){let t="laser",a="laser";return Object.keys(va[e].weapon).forEach((function(r){va[e].weapon[r]>va[e].weapon[t]&&(t=r),va[e].weapon[r]0&&(o=z(`portal_mech_weapon_${e.w}`)),t>=5&&(l=z(`portal_mech_weapon_${e.r}`))}return`
                ${s}
                ${c}
                ${z("portal_spire_mob_weak",[`${o}`])}
                ${z("portal_spire_mob_resist",[`${l}`])}
                `},mscan(){let e=0;return Object.keys(t.stats.spire).forEach((function(a){let r=t.portal.hasOwnProperty("spire")?t.portal.spire.boss:"crazed";t.stats.spire.hasOwnProperty(a)&&t.stats.spire[a].hasOwnProperty(r)&&t.stats.spire[a][r]>e&&(e=t.stats.spire[a][r])})),e},wide:!0,action:()=>!1},waygate:{id:"portal-waygate",title:z("portal_waygate_title"),desc:e=>!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2||e?`
                ${z("portal_waygate_title")}
                ${z("requires_segmemts",[10])}
                `:`
                ${z("portal_waygate_title")}
                `,reqs:{waygate:1},queue_size:1,queue_complete:()=>t.tech.waygate>=2?0:10-t.portal.waygate.count,cost:{Species:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?Rs(25):0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?Rs(25):0,Money:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?1e9:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?1e9:0,Supply:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?5e5:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?5e5:0,Blood_Stone:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?5:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?5:0},powered:()=>t.portal.hasOwnProperty("waygate")&&t.portal.waygate.count>=10?1:0,power_reqs:{waygate:2},effect(e){let a=(e||0)+(t.tech.waygate&&t.tech.waygate>=2?10:t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0);if(a>=10){let e=t.portal.hasOwnProperty("waygate")?`${+t.portal.waygate.progress.toFixed(3)}%`:"0%";return`
                ${z("portal_waygate_open")}
                ${z("portal_waygate_progress",[e])}
                `}{let e=10-a;return`
                ${z("portal_waygate_effect")}
                ${z("space_dwarf_collider_effect2",[e])}
                `}},action(){return!!(t.portal.waygate.count<10&&t.tech.waygate&&1===t.tech.waygate&&ri($(this)[0]))&&(Ft("waygate","portal"),t.portal.waygate.count>=10&&(t.tech.waygate=2,t.portal.waygate.count=1,ua()),!0)}}}};function ca(e){let a=t.portal.hasOwnProperty("spire")&&t.blood.spire?e-(t.portal.spire.count-1)/2500:e;return a>=1.01?a:1.01}const oa=function(e){return la&&!e||(la=1e3,t.hasOwnProperty("pillars")&&Object.keys(t.pillars).forEach((function(e){t.pillars[e]&&(la-=12)}))),la};var la;function _a(e){let t=ga("gate");return Math.round(e/(t.supress>.01?t.supress:.01))}function da(){let e=Math.round(650/be(1,"hellArmy"));return s.gun_emplacement&&(e-=s.gun_emplacement*(t.tech.hell_gun>=2?2:1),e<0&&(e=0)),e}function pa(){return na}function ua(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||4!==t.settings.spaceTabs))return;let e=$("#portal");Ss(e),e.append($(`

                ${z("tab_portal")}

                `)),!t.tech.portal||t.tech.portal<2||Object.keys(na).forEach((function(a){let r=a.replace("prtl_","");if(t.settings.portal[`${r}`]){let r="string"==typeof na[a].info.name?na[a].info.name:na[a].info.name(),i="";if(na[a].info.hasOwnProperty("prop")&&(i=na[a].info.prop()),na[a].info.support){let s=na[a].info.support;na[a].info.hide_support?e.append(`

                ${r}

                ${i}
                `):e.append(`

                ${r}

                {{ support }}/{{ s_max }}${i}
                `),Cs({el:`#sr${a}`,data:t.portal[s],filters:{filter(){return na[a].info.filter(...arguments)}}})}else e.append(`

                ${r}

                ${i}
                `);ls(a,(function(){return"string"==typeof na[a].info.desc?na[a].info.desc:na[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),"prtl_fortress"===a&&ma(e,!0),Object.keys(na[a]).forEach((function(e){"info"!==e&&Tt(na,a,e)&&Zr(na[a][e],"portal",e)}))}}))}function ha(e){switch(e){case"hostiles":return t.portal.fortress.threat>=2e3?`${z("fortress_threat",[t.portal.fortress.threat])} ${z("fortress_threat_high")}`:t.portal.fortress.threat<1e3?`${z("fortress_threat",[t.portal.fortress.threat])} ${z("fortress_threat_low")}`:`${z("fortress_threat",[t.portal.fortress.threat])} ${z("fortress_threat_medium")}`;case"threatLevel":{let e=t.portal.fortress.threat;return e<1e3?`${z("fortress_threat_level")} ${z("fortress_threat_level1")}`:e<1500?`${z("fortress_threat_level")} ${z("fortress_threat_level2")}`:e>=5e3?`${z("fortress_threat_level")} ${z("fortress_threat_level6")}`:e>=3e3?`${z("fortress_threat_level")} ${z("fortress_threat_level5")}`:e>=2e3?`${z("fortress_threat_level")} ${z("fortress_threat_level4")}`:`${z("fortress_threat_level")} ${z("fortress_threat_level3")}`}case"hireLabel":return z("civics_garrison_hire_mercenary_cost",[Math.round(de("m_cost")).toLocaleString()])}}function ma(e,a){if(!t.settings.tabLoad)switch(t.settings.civTabs){case 1:if(4!==t.settings.spaceTabs)return;break;case 2:if(3!==t.settings.govTabs)return;break;default:return}if(!t.tech.portal||t.tech.portal<2)return;let r=a?"fort":"gFort",i=a?$(`
                `):$("#gFort");a?e.append(i):(i.length>0?Ss(i):(i=$(`
                `),e.append(i)),i.append(`

                ${z("portal_fortress_name")}

                `));let n=$("
                ");i.append(n);let c=$(`${z("fortress_defense")} {{ f.garrison | defensive }}`);n.append(c);let o=$(`${z("fortress_spotted")} {{ f.threat }}`);n.append(o);let l=$('{{ f.threat | threat }}');n.append(l);let _=$("
                ");i.append(_),_.append($(`${z("fortress_wall")} {{ f.walls }}%`));let d=$("
                ");i.append(d),d.append($(`${z("fortress_army")}`)),d.append($('«')),d.append($('{{ f.garrison | patrolling }}')),d.append($('»')),d.append($(`${z("fortress_patrol")}`)),d.append($('«')),d.append($('{{ f.patrols }}')),d.append($('»')),d.append($(`${z("fortress_patrol_size")}`)),d.append($('«')),d.append($('{{ f.patrol_size }}')),d.append($('»')),d.append($(``));let p="light"===t.settings.theme?' type="is-light"':' type="is-dark"',u=$("
                ");d.append(u),u.append($(`${z("fortress_patrol_reports")}`)),u.append($(`${z("fortress_surv_reports")}`)),u.append($(`${z("fortress_nocrew")}`)),a&&i.append($(`
                ${z("civics_garrison_training")} - ${z("arpa_to_complete")} {{ g.rate, g.progress | trainTime }} {{ g.progress }}%
                `)),Cs({el:`#${r}`,data:{f:t.portal.fortress,g:t.civic.garrison,s:t.settings},methods:{defense:()=>z("fortress_defense"),hostiles:()=>ha("hostiles"),threatLevel:()=>ha("threatLevel"),aNext(){let e=y();t.portal.fortress.garrisont.civic.garrison.workers&&(t.portal.fortress.garrison=t.civic.garrison.workers),t.portal.fortress.assigned=t.portal.fortress.garrison,Cs({el:"#garrison"},"update"))},aLast(){let e=y(),a=t.portal.fortress.patrols*t.portal.fortress.patrol_size;s.soul_forge&&(a+=da()),t.portal.hasOwnProperty("guard_post")&&(a+=ta(t.portal.guard_post.on)),t.portal.fortress.garrison>a&&(t.portal.fortress.garrison-=e,t.portal.fortress.garrison0&&(t.portal.fortress.patrols-=e,t.portal.fortress.patrols<0&&(t.portal.fortress.patrols=0))},patSizeInc(){let e=y();t.portal.fortress.patrol_size1&&(t.portal.fortress.patrol_size-=e,t.portal.fortress.patrol_size<1&&(t.portal.fortress.patrol_size=1))},wall(){let e=t.portal.fortress.walls;return e>=75?"has-text-success":e<=25?"has-text-danger":"has-text-warning"},threaten(){let e=t.portal.fortress.threat;return e<1e3?"has-text-success":e>=2e3?"has-text-danger":"has-text-warning"},hire(){let e=y(),a=!0;for(;a&&e>0;){let r=Math.round(1.24**t.civic.garrison.workers*75)-50;r>25e3&&(r=25e3),t.civic.garrison.m_use>0&&(r*=1.1**t.civic.garrison.m_use),t.race.brute&&(r/=2),r=Math.round(r),t.civic.garrison.workers=r?(t.resource.Money.amount-=r,t.civic.garrison.workers++,t.civic.garrison.m_use++,t.portal.fortress.garrison++,t.portal.fortress.assigned=t.portal.fortress.garrison,Cs({el:"#garrison"},"update")):a=!1,e--}},hireLabel:()=>ha("hireLabel"),observation(){t.settings.civTabs=$("#mainTabs > nav ul li").length-1,t.settings.tabLoad||Pa()}},filters:{defensive:e=>function(e){let a=e-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(s.soul_forge){let e=da();e<=a&&(a-=e)}t.portal.hasOwnProperty("guard_post")&&(a-=ta(t.portal.guard_post.on));let r=0;if(t.civic.garrison.wounded>t.civic.garrison.workers-t.portal.fortress.garrison&&(r=t.civic.garrison.wounded-(t.civic.garrison.workers-t.portal.fortress.garrison),r>a&&(r=a)),s.war_droid){let e=s.war_droid-t.portal.fortress.patrols>0?s.war_droid-t.portal.fortress.patrols:0;a+=t.tech.hdroid?ta(2*e):ta(e)}let i=t.tech.turret?t.tech.turret>=2?70:50:35;return Math.round(be(a,"hellArmy",r))+(s.turret?s.turret*i:0)}(e),patrolling(e){let a=e-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(s.soul_forge){let e=da();e<=a&&(a-=e)}return t.portal.hasOwnProperty("guard_post")&&(a-=ta(t.portal.guard_post.on)),a},threat:e=>z(e<1e3?"fortress_threat_level1":e<1500?"fortress_threat_level2":e>=5e3?"fortress_threat_level6":e>=3e3?"fortress_threat_level5":e>=2e3?"fortress_threat_level4":"fortress_threat_level3"),trainTime:(e,t)=>zs(0===e?-1:(100-t)/(4*e))}}),["hostiles","threatLevel","armyLabel","patLabel","patSizeLabel","hireLabel"].forEach((function(e){ls(`hf${r}${e}`,(function(){switch(e){case"hostiles":case"threatLevel":return ha("hostiles");case"armyLabel":return z("fortress_stationed");case"patLabel":return z("fortress_patrol_desc",[t.portal.fortress.patrols]);case"patSizeLabel":return z("fortress_patrol_size_desc",[t.portal.fortress.patrol_size]);case"hireLabel":return ha("hireLabel")}}),{elm:`#${r} span.${e}`})})),ls(`hf${r}observe`,(function(){return z("hell_observation_tooltip")}),{elm:`#${r} button.observe`})}function ga(e,a){switch(e){case"ruins":{let e=a||ta(s.guard_post),r=75*(s.arcology||0),i=be(e,"hellArmy",0);t.race.holy&&(i*=1+Ei.holy.vars()[1]/100);let n=ts("unicorn");n>0&&(i*=1+Ei.holy.vars(1)[1]/100*n);let c=(i+r)/5e3;return{supress:c>1?1:c,rating:i+r}}case"gate":{let e=ga("ruins",a),r=100*(s.gate_turret||0);t.race.holy&&(r*=1+Ei.holy.vars()[1]/100);let i=ts("unicorn");i>0&&(r*=1+Ei.holy.vars(1)[1]/100*i);let n=(e.rating+r)/7500;return{supress:n>1?1:n,rating:e.rating+r}}default:return 0}}const va={fire_elm:{weapon:{laser:1.05,flame:0,plasma:.25,kinetic:.5,missile:.5,sonic:1,shotgun:.75,tesla:.65},nozone:{freeze:!0,flooded:!0},amp:{hot:1.75,humid:.8,steam:.9}},water_elm:{weapon:{laser:.65,flame:.5,plasma:1,kinetic:.2,missile:.5,sonic:.5,shotgun:.25,tesla:.75},nozone:{hot:!0,freeze:!0},amp:{steam:1.5,river:1.1,flooded:2,rain:1.75,humid:1.25}},rock_golem:{weapon:{laser:1,flame:.5,plasma:1,kinetic:.65,missile:.95,sonic:.75,shotgun:.35,tesla:0},nozone:{},amp:{}},bone_golem:{weapon:{laser:.45,flame:.35,plasma:.55,kinetic:1,missile:1,sonic:.75,shotgun:.75,tesla:.15},nozone:{},amp:{}},mech_dino:{weapon:{laser:.85,flame:.05,plasma:.55,kinetic:.45,missile:.5,sonic:.35,shotgun:.5,tesla:1},nozone:{},amp:{}},plant:{weapon:{laser:.42,flame:1,plasma:.65,kinetic:.2,missile:.25,sonic:.75,shotgun:.35,tesla:.38},nozone:{},amp:{}},crazed:{weapon:{laser:.5,flame:.85,plasma:.65,kinetic:1,missile:.35,sonic:.15,shotgun:.95,tesla:.6},nozone:{},amp:{}},minotaur:{weapon:{laser:.32,flame:.5,plasma:.82,kinetic:.44,missile:1,sonic:.15,shotgun:.2,tesla:.35},nozone:{},amp:{}},ooze:{weapon:{laser:.2,flame:.65,plasma:1,kinetic:0,missile:0,sonic:.85,shotgun:0,tesla:.15},nozone:{},amp:{}},zombie:{weapon:{laser:.35,flame:1,plasma:.45,kinetic:.08,missile:.8,sonic:.18,shotgun:.95,tesla:.05},nozone:{},amp:{}},raptor:{weapon:{laser:.68,flame:.55,plasma:.85,kinetic:1,missile:.44,sonic:.22,shotgun:.33,tesla:.66},nozone:{},amp:{}},frost_giant:{weapon:{laser:.9,flame:.82,plasma:1,kinetic:.25,missile:.08,sonic:.45,shotgun:.28,tesla:.5},nozone:{hot:!0},amp:{freeze:2.5,hail:1.65}},swarm:{weapon:{laser:.02,flame:1,plasma:.04,kinetic:.01,missile:.08,sonic:.66,shotgun:.38,tesla:.45},nozone:{},amp:{}},dragon:{weapon:{laser:.18,flame:0,plasma:.12,kinetic:.35,missile:1,sonic:.22,shotgun:.65,tesla:.15},nozone:{},amp:{}},mech_dragon:{weapon:{laser:.84,flame:.1,plasma:.68,kinetic:.18,missile:.75,sonic:.22,shotgun:.28,tesla:1},nozone:{},amp:{}},construct:{weapon:{laser:.5,flame:.2,plasma:.6,kinetic:.34,missile:.9,sonic:.08,shotgun:.28,tesla:1},nozone:{},amp:{}},beholder:{weapon:{laser:.75,flame:.15,plasma:1,kinetic:.45,missile:.05,sonic:.01,shotgun:.12,tesla:.3},nozone:{},amp:{}},worm:{weapon:{laser:.55,flame:.38,plasma:.45,kinetic:.2,missile:.05,sonic:1,shotgun:.02,tesla:.01},nozone:{},amp:{}},hydra:{weapon:{laser:.85,flame:.75,plasma:.85,kinetic:.25,missile:.45,sonic:.5,shotgun:.6,tesla:.65},nozone:{},amp:{}},colossus:{weapon:{laser:1,flame:.05,plasma:.75,kinetic:.45,missile:1,sonic:.35,shotgun:.35,tesla:.5},nozone:{},amp:{}},lich:{weapon:{laser:.1,flame:.1,plasma:.1,kinetic:.45,missile:.75,sonic:.35,shotgun:.75,tesla:.5},nozone:{},amp:{}},ape:{weapon:{laser:1,flame:.95,plasma:.85,kinetic:.5,missile:.5,sonic:.05,shotgun:.35,tesla:.68},nozone:{},amp:{}},bandit:{weapon:{laser:.65,flame:.5,plasma:.85,kinetic:1,missile:.5,sonic:.25,shotgun:.75,tesla:.25},nozone:{},amp:{}},croc:{weapon:{laser:.65,flame:.05,plasma:.6,kinetic:.5,missile:.5,sonic:1,shotgun:.2,tesla:.75},nozone:{},amp:{}},djinni:{weapon:{laser:0,flame:.35,plasma:1,kinetic:.15,missile:0,sonic:.65,shotgun:.22,tesla:.4},nozone:{},amp:{}},snake:{weapon:{laser:.5,flame:.5,plasma:.5,kinetic:.5,missile:.5,sonic:.5,shotgun:.5,tesla:.5},nozone:{},amp:{}},centipede:{weapon:{laser:.5,flame:.85,plasma:.95,kinetic:.65,missile:.6,sonic:0,shotgun:.5,tesla:.01},nozone:{},amp:{}},spider:{weapon:{laser:.65,flame:1,plasma:.22,kinetic:.75,missile:.15,sonic:.38,shotgun:.9,tesla:.18},nozone:{},amp:{}},manticore:{weapon:{laser:.05,flame:.25,plasma:.95,kinetic:.5,missile:.15,sonic:.48,shotgun:.4,tesla:.6},nozone:{},amp:{}},fiend:{weapon:{laser:.75,flame:.25,plasma:.5,kinetic:.25,missile:.75,sonic:.25,shotgun:.5,tesla:.5},nozone:{},amp:{}},bat:{weapon:{laser:.16,flame:.18,plasma:.12,kinetic:.25,missile:.02,sonic:1,shotgun:.9,tesla:.58},nozone:{},amp:{}},medusa:{weapon:{laser:.35,flame:.1,plasma:.3,kinetic:.95,missile:1,sonic:.15,shotgun:.88,tesla:.26},nozone:{},amp:{}},ettin:{weapon:{laser:.5,flame:.35,plasma:.8,kinetic:.5,missile:.25,sonic:.3,shotgun:.6,tesla:.09},nozone:{},amp:{}},faceless:{weapon:{laser:.6,flame:.28,plasma:.6,kinetic:0,missile:.05,sonic:.8,shotgun:.15,tesla:1},nozone:{},amp:{}},enchanted:{weapon:{laser:1,flame:.02,plasma:.95,kinetic:.2,missile:.7,sonic:.05,shotgun:.65,tesla:.01},nozone:{},amp:{}},gargoyle:{weapon:{laser:.15,flame:.4,plasma:.3,kinetic:.5,missile:.5,sonic:.85,shotgun:1,tesla:.2},nozone:{},amp:{}},chimera:{weapon:{laser:.38,flame:.6,plasma:.42,kinetic:.85,missile:.35,sonic:.5,shotgun:.65,tesla:.8},nozone:{},amp:{}},gorgon:{weapon:{laser:.65,flame:.65,plasma:.65,kinetic:.65,missile:.65,sonic:.65,shotgun:.65,tesla:.65},nozone:{},amp:{}},kraken:{weapon:{laser:.75,flame:.35,plasma:.75,kinetic:.35,missile:.5,sonic:.18,shotgun:.05,tesla:.85},nozone:{},amp:{}},homunculus:{weapon:{laser:.05,flame:1,plasma:.1,kinetic:.85,missile:.65,sonic:.5,shotgun:.75,tesla:.2},nozone:{},amp:{}}};function fa(e,a){let r=9999,i=1e7;switch(e){case"small":{let e=t.blood.prepared&&t.blood.prepared>=2?5e4:75e3;i=a?2.5*e:e,r=a?20:1}break;case"medium":i=a?45e4:18e4,r=a?100:4;break;case"large":i=a?925e3:375e3,r=a?500:20;break;case"titan":i=a?15e5:75e4,r=a?1500:75;break;case"collector":{let e=t.blood.prepared&&t.blood.prepared>=2?8e3:1e4;i=a?2.5*e:e,r=1}}return{s:r,c:i}}function ya(){if((t.settings.tabLoad||2===t.settings.civTabs&&4===t.settings.govTabs)&&(Ss($("#mechLab")),t.portal.hasOwnProperty("mechbay")&&t.settings.showMechLab)){let e=$("#mechLab");t.portal.mechbay.hasOwnProperty("blueprint")||(t.portal.mechbay.blueprint={size:"small",hardpoint:["laser"],chassis:"tread",equip:[],infernal:!1});let a=$('
                ');e.append(a);let r=$(`
                ${z("portal_mech_assembly")} - {{ b.size | slabel }} {{ b.chassis | clabel }}
                `);a.append(r),r.append(` | ${z("portal_mech_bay_space")}: {{ m.bay }} / {{ m.max }}`),r.append(` | ${z("portal_mech_sup_avail")}: {{ p.supply | round }} / {{ p.sup_max }}`);let i=t.blood.prepared&&t.blood.prepared>=3?`${z("portal_mech_infernal")} (${z("portal_mech_infernal_effect",[25])})`:"";a.append(`
                ${z("portal_mech_space")} {{ b.size | bay }} | ${z("portal_mech_cost")} {{ b.size | price }} | ${z("portal_mech_soul",[t.resource.Soul_Gem.name])} {{ b.size | soul }}${i}
                `),a.append("
                {{ b.size | desc }}
                ");let s=$('
                ');a.append(s);let n="";["small","medium","large","titan","collector"].forEach((function(e,t){n+=`${z(`portal_mech_size_${e}`)}`})),s.append(`\n ${n}\n `);let c="";["wheel","tread","biped","quad","spider","hover"].forEach((function(e,t){c+=`${z(`portal_mech_chassis_${e}`)}`})),s.append(`\n ${c}\n `);for(let e=0;e<4;e++){let t="";["laser","kinetic","shotgun","missile","flame","plasma","sonic","tesla"].forEach((function(a,r){t+=`${z(`portal_mech_weapon_${a}`)}`})),s.append(`\n ${t}\n `)}let o=t.blood.prepared?5:4;for(let e=0;e{{ '${a}' | equipment }}`})),s.append(`\n ${t}\n `)}a.append(`
                `),Cs({el:"#mechAssembly",data:{p:t.portal.purifier,m:t.portal.mechbay,b:t.portal.mechbay.blueprint},methods:{build(){let e=fa(t.portal.mechbay.blueprint.size,t.portal.mechbay.blueprint.infernal),a=e.c,r=e.s,i=ba(t.portal.mechbay.blueprint.size),s=t.portal.mechbay.max-t.portal.mechbay.bay;if(t.portal.purifier.supply>=a&&s>=i&&t.resource.Soul_Gem.amount>=r){t.portal.purifier.supply-=a,t.resource.Soul_Gem.amount-=r;let e=sn(t.portal.mechbay.blueprint);t.portal.mechbay.mechs.push(e),t.portal.mechbay.bay+=i,t.portal.mechbay.active++}},setSize(e){switch(t.portal.mechbay.blueprint.size=e,"collector"===e?t.portal.mechbay.blueprint.hardpoint.length=0:"small"===e||"medium"===e?(0===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push("laser"),t.portal.mechbay.blueprint.hardpoint.length=1):(0===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push("laser"),1===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"plasma":"laser"),"titan"===e?2===t.portal.mechbay.blueprint.hardpoint.length&&(t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"shotgun":"laser"),t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"kinetic":"laser")):t.portal.mechbay.blueprint.hardpoint.length=2),e){case"small":t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?1:0;break;case"medium":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("shields"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?2:1;break;case"collector":case"large":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length<2&&t.portal.mechbay.blueprint.equip.push("shields"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("grapple"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?3:2;break;case"titan":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length<2&&t.portal.mechbay.blueprint.equip.push("shields"),t.portal.mechbay.blueprint.equip.length<3&&t.portal.mechbay.blueprint.equip.push("grapple"),t.portal.mechbay.blueprint.equip.length<4&&t.portal.mechbay.blueprint.equip.push("seals"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("stabilizer"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?5:4}},setType(e){t.portal.mechbay.blueprint.chassis=e},setWep(e,a){t.portal.mechbay.blueprint.hardpoint[a]=e,Cs({el:"#mechAssembly"},"update")},setEquip(e,a){t.portal.mechbay.blueprint.equip[a]=e,Cs({el:"#mechAssembly"},"update")},vis:e=>"collector"!==t.portal.mechbay.blueprint.size&&(0===e||"large"===t.portal.mechbay.blueprint.size&&e<2||"titan"===t.portal.mechbay.blueprint.size),eVis(e){let a=t.blood.prepared?1:0;switch(t.portal.mechbay.blueprint.size){case"small":return 1===a&&0===e;case"medium":return e<=0+a;case"collector":case"large":return e<=1+a;case"titan":return!0}}},filters:{bay:e=>ba(e),price:e=>fa(e,t.portal.mechbay.blueprint.infernal).c,soul:e=>fa(e,t.portal.mechbay.blueprint.infernal).s,slabel:e=>z(`portal_mech_size_${e}`),clabel:e=>z(`portal_mech_chassis_${e}`),wlabel:e=>z(`portal_mech_weapon_${e}`),desc:e=>z(`portal_mech_size_${e}_desc`),round:e=>Math.round(e),equipment(e){if("special"!==e)return z(`portal_mech_equip_${e}`);let a="jumpjet";switch(t.portal.mechbay.blueprint.size){case"large":a="battery";break;case"titan":a="target"}return z(`portal_mech_equip_${a}`)}}}),["size","chassis","weapon","equip"].forEach((function(e){let a=1;"weapon"===e?a=4:"equip"===e&&(a=o);for(let r=0;r');e.append(l),wa(),Ss($("#mechList")),$("#mechList").append(`\n
                \n ${z("portal_mech_scrap")}\n | ${z("portal_mech")} #{{index + 1}}: \n {{ mech.infernal ? "${z("portal_mech_infernal")} " : "" }}{{ mech | size }} {{ mech | chassis }}\n
                \n
                \n \n
                \n
                \n \n
                \n
                \n
                `),Cs({el:"#mechList",data:t.portal.mechbay,methods:{scrap(e){if(t.portal.mechbay.mechs[e]){let a=fa(t.portal.mechbay.mechs[e].size,t.portal.mechbay.mechs[e].infernal),r=ba(t.portal.mechbay.mechs[e].size);t.portal.purifier.supply+=Math.floor(a.c/3),t.resource.Soul_Gem.amount+=Math.floor(a.s/2),t.portal.purifier.supply>t.portal.purifier.sup_max&&(t.portal.purifier.supply=t.portal.purifier.sup_max),t.portal.mechbay.mechs.splice(e,1),t.portal.mechbay.bay-=r,t.portal.mechbay.active--}}},filters:{equipment(e,t){if("special"!==e)return z(`portal_mech_equip_${e}`);let a="jumpjet";switch(t){case"large":a="battery";break;case"titan":a="target"}return z(`portal_mech_equip_${a}`)},weapon:e=>z(`portal_mech_weapon_${e}`),size:e=>z(`portal_mech_size_${e.size}`),chassis:e=>z(`portal_mech_chassis_${e.chassis}`)}}),function(){let e=$("#mechList")[0];Sortable.create(e,{onEnd(e){let a=e.from.querySelectorAll(":scope > .mechRow");e.from.insertBefore(e.item,a[e.oldIndex+(e.oldIndex>e.newIndex)]);let r=t.portal.mechbay.mechs;r.splice(e.newDraggableIndex,0,r.splice(e.oldDraggableIndex,1)[0]),ka()}})}(),$("#mechList .scrap").each((function(e,a){ls(`mechList-scrap${e}`,(function(){let a=fa(t.portal.mechbay.mechs[e].size,t.portal.mechbay.mechs[e].infernal);return z("portal_mech_scrap_refund",[Math.floor(a.c/3),Math.floor(a.s/2)])}),{elm:a})}))}}function ba(e){switch(e){case"small":return 2;case"medium":return t.blood.prepared&&t.blood.prepared>=2?4:5;case"large":return t.blood.prepared&&t.blood.prepared>=2?8:10;case"titan":return t.blood.prepared&&t.blood.prepared>=2?20:25;case"collector":return 1;case"default":return 25}}function wa(){let e=$("#mechList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}function ka(){let e=25*(l.mechbay||0),a=0,r=0,i=0;for(let s of t.portal.mechbay.mechs)a+=ba(s.size),a<=e&&(r++,"small"===s.size&&i++);t.portal.mechbay.bay=a,t.portal.mechbay.max=e,t.portal.mechbay.active=r,t.portal.mechbay.scouts=i}function $a(e){t.portal.spire.status.freeze||t.portal.spire.status.hot?"freeze"!==e&&"hot"!==e&&(t.portal.spire.status[e]=!0):t.portal.spire.status.rain||t.portal.spire.status.hail?"rain"!==e&&"hail"!==e&&(t.portal.spire.status[e]=!0):t.portal.spire.status[e]=!0}function xa(e,a){let r=a||t.portal.spire.type,i=1;switch(e.chassis){case"wheel":switch(r){case"sand":i=["small","medium"].includes(e.size)?.9:.85;break;case"swamp":i=["small","medium"].includes(e.size)?.35:.18;break;case"jungle":i=["small","medium"].includes(e.size)?.92:.85;break;case"rocky":i=["small","medium"].includes(e.size)?.65:.5;break;case"gravel":i=["small","medium"].includes(e.size)?1:.95;break;case"muddy":i=["small","medium"].includes(e.size)?.85:.58;break;case"grass":i=["small","medium"].includes(e.size)?1.3:1.2;break;case"brush":i=["small","medium"].includes(e.size)?.9:.8;break;case"concrete":i=["small","medium"].includes(e.size)?1.1:1}break;case"tread":switch(r){case"sand":i=["small","medium"].includes(e.size)?1.15:1.1;break;case"swamp":i=["small","medium"].includes(e.size)?.55:.4;break;case"forest":i=["small","medium"].includes(e.size)?1:.95;break;case"jungle":i=["small","medium"].includes(e.size)?.95:.9;break;case"rocky":i=["small","medium"].includes(e.size)?.65:.5;break;case"gravel":i=["small","medium"].includes(e.size)?1.3:1.2;break;case"muddy":i=["small","medium"].includes(e.size)?.88:.72}break;case"biped":switch(r){case"sand":i=["small","medium"].includes(e.size)?.78:.65;break;case"swamp":i=["small","medium"].includes(e.size)?.68:.5;break;case"forest":i=["small","medium"].includes(e.size)?1:.95;break;case"jungle":i=["small","medium"].includes(e.size)?.82:.7;break;case"rocky":i=["small","medium"].includes(e.size)?.48:.4;break;case"muddy":i=["small","medium"].includes(e.size)?.85:.7;break;case"grass":i=["small","medium"].includes(e.size)?1.25:1.2;break;case"brush":i=["small","medium"].includes(e.size)?.92:.85}break;case"quad":switch(r){case"sand":i=["small","medium"].includes(e.size)?.86:.75;break;case"swamp":i=["small","medium"].includes(e.size)?.58:.42;break;case"forest":i=["small","medium"].includes(e.size)?1.25:1.2;break;case"rocky":case"brush":i=["small","medium"].includes(e.size)?.95:.9;break;case"gravel":i=["small","medium"].includes(e.size)?.9:.8;break;case"muddy":i=["small","medium"].includes(e.size)?.68:.5;break;case"grass":i=["small","medium"].includes(e.size)?1:.95}break;case"spider":switch(r){case"sand":i=["small","medium"].includes(e.size)?.75:.65;break;case"swamp":i=["small","medium"].includes(e.size)?.9:.78;break;case"forest":i=["small","medium"].includes(e.size)?.82:.75;break;case"jungle":i=["small","medium"].includes(e.size)?.77:.65;break;case"rocky":i=["small","medium"].includes(e.size)?1.25:1.2;break;case"gravel":i=["small","medium"].includes(e.size)?.86:.75;break;case"muddy":i=["small","medium"].includes(e.size)?.92:.82;break;case"brush":i=["small","medium"].includes(e.size)?1:.95}break;case"hover":switch(r){case"swamp":i=["small","medium"].includes(e.size)?1.35:1.2;break;case"forest":i=["small","medium"].includes(e.size)?.65:.48;break;case"jungle":i=["small","medium"].includes(e.size)?.55:.35;break;case"rocky":i=["small","medium"].includes(e.size)?.82:.68;break;case"muddy":i=["small","medium"].includes(e.size)?1.15:1.08;break;case"brush":i=["small","medium"].includes(e.size)?.78:.7}}return i}function qa(e){switch(e){case"small":return.0025;case"medium":return.0075;case"large":return.01;case"titan":return.012;default:return 0}}function Pa(e){if(!t.settings.tabLoad&&t.settings.civTabs!==$("#mainTabs > nav ul li").length-1&&!e)return;let a=$("#mTabObserve");Ss(a);let r=$('
                ');if(a.append(r),r.append(`\n \n \n \n \n \n \n `),Cs({el:"#hellObservations",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(Ss($("#h_Report")),Ss($("#h_Analysis")),e){case 0:Ma();break;case 1:ja()}return e}}}),t.settings.tabLoad)Ma(),ja();else switch(t.settings.hellTabs){case 0:Ma();break;case 1:ja()}}function ja(){if(!t.settings.tabLoad&&1!==t.settings.hellTabs)return;let e=$("#h_Analysis"),a=$('
                ');e.append(a);let r=$("
                ");a.append(r);let i=$('
                ');a.append(i);let s=$('
                ');i.append(s);let n=$('
                '),c=$('
                ');s.append(n),s.append(c),r.append(`\n
                \n

                ${z("tab_settings")}

                \n
                \n
                \n ${z("hell_analysis_expanded")}\n ${z("hell_analysis_average")}\n ${z("hell_analysis_hyperSlow")}\n
                \n
                \n ${z("hell_analysis_time_game_days")}\n ${z("hell_analysis_time_seconds")}\n ${z("hell_analysis_time_minutes")}\n ${z("hell_analysis_time_hours")}\n ${z("hell_analysis_time_days")}\n
                \n `),Cs({el:"#hellAnalysis",data:{s:t.portal.observe.settings,r:t.race}});let o=function(e,t){e=e.toFixed(t);let a=Math.floor(e),r=(+(e-a).toFixed(t)).toString().substring(1);return a.toLocaleString()+r},l=function(e,a,r){if(e){switch("game_days"!==r&&t.portal.observe.settings.hyperSlow&&(t.race.slow&&(a*=1+Ei.slow.vars()[0]/100),t.race.hyper&&(a*=1-Ei.hyper.vars()[0]/100)),e/=a,r){case"seconds":e/=5;break;case"minutes":e*=12;break;case"hours":e*=720;break;case"days":e*=17280}e=t.portal.observe.settings.expanded?o(e,5):x(e,5,!0)}return z("hell_analysis_time_average",[e,z(`hell_analysis_time_${r}_abbr`)])},_=function(e,a){if(!e)return;let r=$(`#${e}`);Ss(r),r.append(`\n

                ${z("hell_analysis_"+a)}

                ${"period"===a?'

                {{ | resetLabel }}

                ':""}
                \n

                {{ st.${a}.start | startLabel }}

                \n

                {{ st.${a}.days, s.display | time }}

                \n

                {{ st.${a}.kills, 'kills', s.average | genericMulti }}

                {{ s.dropKills | dropdownLabel }}

                \n
                \n

                {{ st.${a}.kills.drones, 'kills_drones', s.average | genericSub }}

                \n

                {{ st.${a}.kills.patrols, 'kills_patrols', s.average | genericSub }}

                \n

                {{ st.${a}.kills.sieges, 'kills_sieges', s.average | genericSub }}

                \n

                {{ st.${a}.kills.guns, 'kills_guns', s.average | genericSub }}

                \n

                {{ st.${a}.kills.soul_forge, 'kills_soul_forge', s.average | genericSub }}

                \n

                {{ st.${a}.kills.turrets, 'kills_turrets', s.average | genericSub }}

                \n
                \n

                {{ st.${a}.gems, 'gems', s.average | genericMulti }}

                {{ s.dropGems | dropdownLabel }}

                \n
                \n

                {{ st.${a}.gems.patrols, 'gems_patrols', s.average | genericSub }}

                \n

                {{ st.${a}.gems.guns, 'gems_guns', s.average | genericSub }}

                \n

                {{ st.${a}.gems.soul_forge, 'gems_soul_forge', s.average | genericSub }}

                \n

                {{ st.${a}.gems.crafted, 'gems_crafted', s.average | genericSub }}

                \n

                {{ st.${a}.gems.turrets, 'gems_turrets', s.average | genericSub }}

                \n

                {{ st.${a}.gems.surveyors, 'gems_surveyors', s.average | genericSub }}

                \n
                \n

                {{ st.${a}.wounded, 'wounded', s.average | generic }}

                \n

                {{ st.${a}.died, 'died', s.average | generic }}

                \n

                {{ st.${a}.revived, 'revived', s.average | generic }}

                \n

                {{ st.${a}.surveyors, 'surveyors', s.average | generic }}

                \n

                {{ st.${a}.sieges, 'sieges', s.average | generic }}

                \n `),Cs({el:`#${e}`,data:{st:t.portal.observe.stats,s:t.portal.observe.settings,p:t.portal,r:t.race,sg:t.resource.Soul_Gem},methods:{resetObservations(){Object.keys(t.portal.observe.stats.period).forEach((function(e){["kills","gems"].includes(e)?Object.keys(t.portal.observe.stats.period[e]).forEach((function(a){t.portal.observe.stats.period[e][a]=0})):"start"===e?t.portal.observe.stats.period.start={year:t.city.calendar.year,day:t.city.calendar.day}:t.portal.observe.stats.period[e]=0}))},toggleDropdown(e){t.portal.observe.settings[e]=!t.portal.observe.settings[e]}},filters:{generic:(e,r,i)=>z("hell_analysis_number_display",i?[z(`hell_analysis_${r}`),l(e,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]:[z(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+e.toFixed(5)).toLocaleString():x(e,5,!0)]),genericSub:(e,r,i)=>i?"ᄂ"+z("hell_analysis_number_display",[z(`hell_analysis_${r}`),l(e,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]):"ᄂ"+z("hell_analysis_number_display",[z(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+e.toFixed(5)).toLocaleString():x(e,5,!0)]),genericMulti(e,r,i){let s=0;return Object.keys(e).forEach((function(t){s+=e[t]})),z("hell_analysis_number_display",i?[z(`hell_analysis_${r}`),l(s,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]:[z(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+s.toFixed(5)).toLocaleString():x(s,5,!0)])},time(e,a){switch("game_days"!==a&&t.portal.observe.settings.hyperSlow&&(t.race.slow&&(e*=1+Ei.slow.vars()[0]/100),t.race.hyper&&(e*=1-Ei.hyper.vars()[0]/100)),a){case"seconds":e*=5;break;case"minutes":e/=12;break;case"hours":e/=720;break;case"days":e/=17280}return z("hell_analysis_time",[z(`hell_analysis_time_${a}`),t.portal.observe.settings.expanded?o(e,8):x(e,5,!0)])},resetLabel:()=>z("hell_analysis_period_reset"),startLabel:e=>z("hell_analysis_start",[e.year,e.day]),dropdownLabel:e=>e?"⮝":"⮟"}})};_("hellAnalysisTotal","total"),_("hellAnalysisPeriod","period"),a=$("#hellAnalysis");let d=$("
                ");a.append(d),d.append(`

                ${z("hell_graph_create")}

                `);let p=$('
                ');d.append(p),Cs({el:"#hellGraphCreator",methods:{createGraph(){this.$buefy.modal.open({parent:this,component:{template:''}});let e=setInterval((function(){if($("#modalBox").length>0){clearInterval(e),$("#modalBox").append($(`

                ${z("hell_graph_title")}

                `));var a=$('
                ');$("#modalBox").append(a);let r=$('
                ');a.append(r);let i={chartType:"pie",name:"",chartName:"",data:[],radioFake:"",showGroups:!0},s={show:!1,message:""};r.append(`\n

                ${z("hell_graph_name")}

                \n `),r.append(`\n
                \n
                \n

                ${z("hell_graph_type")}

                \n
                \n
                \n ${z("hell_graph_pie")}\n
                \n
                \n `);let n=$('
                ');r.append(n),n.append(`

                ${z("hell_graph_data")}

                `),Object.keys(t.portal.observe.stats).forEach((function(e){["kills","gems"].forEach((function(t){n.append(`
                \n ${z("hell_graph_datapoint",[z(`hell_analysis_${e}`),z(`hell_analysis_${t}`)])}\n
                `)}))})),r.append(`\n
                \n
                \n

                {{ e.message }}

                \n
                \n
                \n \n
                \n
                \n `),Cs({el:"#specialModal",data:{s:i,e:s,sg:t.resource.Soul_Gem},methods:{nameUpdate(e){i.chartName!==e&&(s.show=!1,i.chartName=e)},dataOptions(e){switch(e){case"pie":i.showGroups=!0;break;case"bar":i.showGroups=!1}},setData(e,t){s.show=!1,i.data=[e,t]},createGraph(){if(!i.name)return s.show=!0,void(s.message=z("hell_graph_error_name_blank"));if(0===i.data.length)return s.show=!0,void(s.message=z("hell_graph_error_data_missing"));let e=[],a=[];"pie"===i.chartType&&Object.keys(t.portal.observe.stats[i.data[0]][i.data[1]]).forEach((function(t){e.push(z(`hell_analysis_${i.data[1]}_${t}`)),a.push([i.data[0],i.data[1],t])}));let r=function(e,a,r,i,s){let n=`hellGraph-${t.portal.observe.graphID}`;return t.portal.observe.graphID++,t.portal.observe.graphs[n]={id:n,chartID:`${n}-chart`,name:e,type:a,labels:r,data:i,settings:s},n}(i.chartName,i.chartType,e,a,{title:i.chartName});Oa(p,t.portal.observe.graphs[r]),document.dispatchEvent(new KeyboardEvent("keydown",{key:"Escape"})),document.dispatchEvent(new KeyboardEvent("keyup",{key:"Escape"}))}}})}}),50)}}}),Object.keys(t.portal.observe.graphs).forEach((function(e){Oa(p,t.portal.observe.graphs[e])}))}function Oa(e,a){let r=a.id;p[r]&&p[r].graph.destroy();let i=$(`
                `);e.append(i),i.append(`
                \n
                \n

                \n

                Delete

                \n
                \n
                \n

                ${a.name}

                \n
                \n
                `);let s=$('
                ');i.append(s),Cs({el:`#graph-${r}-controls`,methods:{deleteGraph(){p[r].graph.destroy(),delete p[r],delete t.portal.observe.graphs[r],Ss($(`#graph-${r}-container`),!0)}}});let n=$(``);s.append(n),p[r]={data:a.data},"pie"===a.type&&(p[r].graph=function(e,a,r,i){let s=[];return r.forEach((function(e){s.push(3===e.length?t.portal.observe.stats[e[0]][e[1]][e[2]]:t.portal.observe.stats[e[0]][e[1]])})),new Chart(e,{type:"pie",data:{labels:a,datasets:[{data:s,backgroundColor:["rgb(255, 99, 132)","rgb(54, 162, 235)","rgb(255, 205, 86)","rgb(201, 203, 207)","rgb(75, 192, 192)","#B86BFF","#48c774"],hoverOffset:4}]},options:{plugins:{legend:{display:!1}}}})}(n,a.labels,a.data,a.settings))}function Ma(){if(!t.settings.tabLoad&&0!==t.settings.hellTabs)return;Sa();let e="",a=$("#h_Report"),r=$('
                ');a.append(r);let i=$('
                ');r.append(i),i.append(`

                ${z("hell_report_log")}

                \n \n \n\t\t \n \n
                `);let s=$('
                ');i.append(s),r.append($('
                '));let n={year:0,day:0};Object.keys(d).length&&(n.year=Object.keys(d)[0].split("-")[1],n.day=Object.keys(d[`year-${n.year}`])[0].split("-")[1]);let c=function(a,r){for(Sa(!0)&&(e="",a=Object.keys(d)[0].split("-")[1],r=Object.keys(d[`year-${n.year}`])[0].split("-")[1]);a${z("year")+" "+a+" | "+z("day")+" "+r}${d[`year-${a}`][`day-${r}`].foundGem?'':""}\n `+e;r=1}for(;r${z("year")+" "+a+" | "+z("day")+" "+r}${d[`year-${a}`][`day-${r}`].foundGem?``:""}\n `+e;n.year=a,n.day=r;let i=$("#hellReportList");Ss(i),i.append(e),Cs({el:"#hellReportList",methods:{reportLoad(e,t){o(e,t)}}})},o=function(e,a){if(!e||!a)return;let r=$("#hellReportDisplay");Ss(r);let i=d[`year-${e}`][`day-${a}`],s=$('
                ');r.append(s);let n=0,c=0;if(Object.keys(i.stats.kills).forEach((function(e){n+=i.stats.kills[e]})),Object.keys(i.stats.gems).forEach((function(e){c+=i.stats.gems[e]})),s.append(`

                ${z("hell_report_log_stats",[e,a])}

                `),s.append(`
                \n

                ${z("hell_report_log_stats_kills",[n])}

                \n

                ${z("hell_report_log_stats_gems",[c])}

                \n

                ${z("hell_report_log_stats_wounded",[i.stats.wounded])}

                \n

                ${z("hell_report_log_stats_died",[i.stats.died])}

                \n
                `),r.append(`

                ${z("hell_report_log_report",[e,a])}

                `),r.append(`

                ${z("hell_report_log_start",[i.start])}

                `),i.drones&&Object.keys(i.drones).forEach((function(e){let t=i.drones[e],a=z("hell_report_log_obj_counter",[z("portal_war_drone_title"),e]);t.encounter?r.append(`

                ${z("hell_report_log_encounter",[a,t.kills])}

                `):r.append(`

                ${z("hell_report_log_encounter_fail",[a])}

                `)})),i.patrols&&Object.keys(i.patrols).forEach((function(e){let a=i.patrols[e],s=z("hell_report_log_obj_counter",[z("hell_report_log_patrol"),e]);if(s=a.droid?z("hell_report_log_patrol_droid",[s]):s,a.encounter){let e=$("

                ");a.ambush?e.append(`${z("hell_report_log_patrol_ambush",[s,a.kills])}`):e.append(`${z("hell_report_log_encounter",[s,a.kills])}`),a.wounded&&e.append(`${a.wounded>1?z("hell_report_log_patrol_wounded_plural",[a.wounded]):z("hell_report_log_patrol_wounded")}`),a.died&&e.append(`${a.died>1?z("hell_report_log_patrol_killed_plural",[a.died]):z("hell_report_log_patrol_killed")}`),a.gem>0&&e.append(`${z("hell_report_log_soul_find",[t.resource.Soul_Gem.name,a.gem])}`),r.append(e)}else r.append(`

                ${z("hell_report_log_encounter_fail",[s])}

                `)})),i.surveyor_finds&&Object.keys(i.surveyor_finds).forEach((function(e){let a=i.surveyor_finds[e],s=z("hell_report_log_obj_counter",[z("job_hell_surveyor"),e]),n=$("

                ");n.append(`${z("hell_report_log_search",[s,a.bodies])}`),a.gem>0&&n.append(`${z("hell_report_log_soul_search",[t.resource.Soul_Gem.name,a.gem])}`),r.append(n)})),i.revived&&r.append(`

                ${i.revived>1?z("hell_report_log_revived_plural",[i.revived]):z("hell_report_log_revived")}

                `),i.patrols_lost&&r.append(`

                ${z("hell_report_log_patrols_lost",[i.patrols_lost])}

                `),i.siege&&(i.siege.destroyed?r.append(`

                ${z("hell_report_log_siege",[i.siege.surveyors,i.siege.soldiers,i.siege.kills])}

                `):r.append(`

                ${z("hell_report_log_siege_fail",[i.siege.damage,i.siege.kills])}

                `)),i.demons&&r.append(`

                ${z("hell_report_log_demons",[i.demons])}

                `),i.surveyors&&r.append(`

                ${i.surveyors>1?z("hell_report_log_surveyors_plural",[i.surveyors]):z("hell_report_log_surveyors")}

                `),i.soul_attractors&&r.append(`

                ${z("hell_report_log_soul_attractors",[i.soul_attractors])}

                `),i.gun_emplacements&&Object.keys(i.gun_emplacements).forEach((function(e){let a=$("

                "),s=i.gun_emplacements[e],n=z("hell_report_log_obj_counter",[z("portal_gun_emplacement_title"),e]);a.append($(`${z("hell_report_log_misc_kills",[n,s.kills,z("portal_pit_name")])}`)),s.gem&&a.append(`${z("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),r.append(a)})),i.soul_forge){let e=$("

                ");e.append(`${z("hell_report_log_soul_forge",[i.soul_forge.kills])}`),i.soul_forge.gem&&e.append(`${z("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),i.soul_forge.gem_craft&&e.append(`${z("hell_report_log_soul_craft",[i.soul_forge.corrupt?z("resource_Corrupt_Gem_name"):t.resource.Soul_Gem.name])}`),r.append(e)}i.gate_turrets&&Object.keys(i.gate_turrets).forEach((function(e){let a=$("

                "),s=i.gate_turrets[e],n=z("hell_report_log_obj_counter",[z("portal_gate_turret_title"),e]);a.append(`${z("hell_report_log_misc_kills",[n,s.kills,z("portal_gate_name")])}`),s.gem&&a.append(`${z("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),r.append(a)})),Cs({el:"#hellReportDisplay",data:{g:t.resource.Soul_Gem}})};if(0!==n.day){c(n.year,n.day);let e=n.year,a=n.day;a-1==0?(e--,a=t.city.calendar.orbit):a--,o(e,a)}else n.year=t.city.calendar.year,n.day=t.city.calendar.day;Cs({el:"#hellReportLogTitle",methods:{updateList(){c(n.year,n.day)}}}),ls("hellReportLogs",(function(){return z("hell_report_log_tooltip",[2500])}),{elm:"#hellReport .reportList div:first-child h2"})}function Sa(e){if(!document.getElementById("hellReportList")||e){let e=!1,a=2500,r=(Object.keys(d).length-1)*t.city.calendar.orbit+t.city.calendar.day;if(r>a){let i=Object.keys(d[Object.keys(d)[0]]).length;for(r-t.city.calendar.orbit+i>a&&(e=!0,r-=i,delete d[Object.keys(d)[0]]);r>a;)r-=t.city.calendar.orbit,delete d[Object.keys(d)[0]]}return e}}const Ca={Food:5,Lumber:5,Chrysotile:5,Stone:5,Crystal:6,Furs:8,Copper:25,Iron:40,Aluminium:50,Cement:15,Coal:20,Oil:75,Uranium:550,Steel:100,Titanium:150,Alloy:350,Polymer:250,Iridium:420,Helium_3:620,Deuterium:950,Elerium:2e3,Water:2,Neutronium:1500,Adamantite:2250,Infernite:2750,Nano_Tube:750,Graphene:3e3,Stanene:3600,Bolognium:9e3,Vitreloy:10200,Orichalcum:99e3,Horseshoe:0,Nanite:0,Genes:0,Soul_Gem:0,Corrupt_Gem:0,Codex:0,Cipher:0,Demonic_Essence:0},za={Food:2,Lumber:2,Chrysotile:1,Stone:2,Crystal:.4,Furs:1,Copper:1,Iron:1,Aluminium:1,Cement:1,Coal:1,Oil:.5,Uranium:.12,Steel:.5,Titanium:.25,Alloy:.2,Polymer:.2,Iridium:.1,Helium_3:.1,Deuterium:.1,Elerium:.02,Water:2,Neutronium:.05,Adamantite:.05,Infernite:.01,Nano_Tube:.1,Graphene:.1,Stanene:.1,Bolognium:.12,Vitreloy:.12,Orichalcum:.05},Fa={Food:4.355,Lumber:7.668,Chrysotile:15.395,Stone:20.017,Crystal:5.062,Furs:13.009,Copper:63.546,Iron:55.845,Aluminium:26.9815,Cement:20.009,Coal:12.0107,Oil:5.342,Uranium:238.0289,Steel:55.9,Titanium:47.867,Alloy:45.264,Polymer:120.054,Iridium:192.217,Helium_3:3.0026,Deuterium:2.014,Neutronium:248.74,Adamantite:178.803,Infernite:222.666,Elerium:297.115,Nano_Tube:15.083,Graphene:26.9615,Stanene:33.9615,Bolognium:75.898,Unobtainium:168.59,Vitreloy:41.08,Orichalcum:237.8,Water:18.01,Plywood:7.666,Brick:20.009,Wrought_Iron:55.845,Sheet_Metal:26.9815,Mythril:94.239,Aerogel:7.84,Nanoweave:23.71,Scarletite:188.6,Quantium:241.35},Aa={Lumber:{in:.5,out:25e3},Chrysotile:{in:.5,out:25e3},Stone:{in:.5,out:25e3},Crystal:{in:3,out:25e3},Furs:{in:3,out:25e3},Copper:{in:1.5,out:25e3},Iron:{in:1.5,out:25e3},Aluminium:{in:2.5,out:25e3},Cement:{in:3,out:25e3},Coal:{in:1.5,out:25e3},Oil:{in:2.5,out:12e3},Uranium:{in:5,out:300},Steel:{in:3,out:25e3},Titanium:{in:3,out:25e3},Alloy:{in:6,out:25e3},Polymer:{in:6,out:25e3},Iridium:{in:8,out:25e3},Helium_3:{in:4.5,out:12e3},Deuterium:{in:4,out:1e3},Neutronium:{in:15,out:1e3},Adamantite:{in:12.5,out:1e3},Infernite:{in:25,out:250},Elerium:{in:30,out:250},Nano_Tube:{in:6.5,out:1e3},Graphene:{in:5,out:1e3},Stanene:{in:4.5,out:1e3},Bolognium:{in:18,out:1e3},Vitreloy:{in:14,out:1e3},Orichalcum:{in:10,out:1e3},Plywood:{in:10,out:250},Brick:{in:10,out:250},Wrought_Iron:{in:10,out:250},Sheet_Metal:{in:10,out:250},Mythril:{in:12.5,out:250},Aerogel:{in:16.5,out:250},Nanoweave:{in:18,out:250},Scarletite:{in:35,out:250}};function Ia(){let e={Plywood:[{r:"Lumber",a:100}],Brick:t.race.flier?[{r:"Stone",a:60}]:[{r:"Cement",a:40}],Wrought_Iron:[{r:"Iron",a:80}],Sheet_Metal:[{r:"Aluminium",a:120}],Mythril:[{r:"Iridium",a:100},{r:"Alloy",a:250}],Aerogel:[{r:"Graphene",a:2500},{r:"Infernite",a:50}],Nanoweave:[{r:"Nano_Tube",a:1e3},{r:"Vitreloy",a:40}],Scarletite:[{r:"Iron",a:25e4},{r:"Adamantite",a:7500},{r:"Orichalcum",a:500}],Quantium:[{r:"Nano_Tube",a:1e3},{r:"Graphene",a:1e3},{r:"Elerium",a:25}],Thermite:[{r:"Iron",a:180},{r:"Aluminium",a:60}]};if(t.race.wasteful){let t=1+Ei.wasteful.vars()[0]/100;Object.keys(e).forEach((function(a){for(let r=0;r=2){let e=t.tech.foundry>=5?t.tech.foundry>=8?.08:.05:.03;La.general.add.push({name:z("city_foundry"),manual:t.city.foundry.count*e,auto:t.city.foundry.count*e})}if(t.tech.foundry>=3&&Object.keys(La).forEach((function(e){t.city.foundry[e]&&t.city.foundry[e]>1&&La[e].add.push({name:z("tech_apprentices"),manual:(t.city.foundry[e]-1)*ke(.03),auto:(t.city.foundry[e]-1)*ke(.03)})})),t.tech.foundry>=4&&t.city.sawmill&&La.Plywood.add.push({name:z("city_sawmill"),manual:.02*t.city.sawmill.count,auto:.02*t.city.sawmill.count}),t.tech.foundry>=6&&La.Brick.add.push({name:z("city_foundry"),manual:.02*t.city.foundry.count,auto:.02*t.city.foundry.count}),t.tech.foundry>=7&&(La.general.add.push({name:z("city_factory")+` (${z("tab_city5")})`,manual:.05*s.factory,auto:.05*s.factory}),t.tech.mars>=4&&La.general.add.push({name:z("city_factory")+` (${z("tab_space")})`,manual:.05*s.red_factory,auto:.05*s.red_factory}),t.interstellar.int_factory&&s.int_factory&&La.general.add.push({name:z("interstellar_int_factory_title"),manual:.1*s.int_factory,auto:.1*s.int_factory})),t.space.fabrication&&n.fabrication&&La.general.add.push({name:z("space_red_fabrication_title"),manual:n.fabrication*t.civic.colonist.workers*ke(e?.05:.02),auto:n.fabrication*t.civic.colonist.workers*ke(e?.05:.02)}),s.stellar_forge&&(La.Mythril.add.push({name:z("interstellar_stellar_forge_title"),manual:.05*s.stellar_forge,auto:.05*s.stellar_forge}),La.general.add.push({name:z("interstellar_stellar_forge_title"),manual:0,auto:.1*s.stellar_forge})),s.hell_forge){let e=ga("ruins");La.general.add.push({name:z("portal_hell_forge_title"),manual:0,auto:.75*s.hell_forge*e.supress}),La.Scarletite.multi.push({name:z("portal_ruins_supressed"),manual:1,auto:e.supress})}if(t.tauceti.tau_factory&&n.tau_factory&&La.general.add.push({name:z("tau_home_tau_factory"),manual:0,auto:n.tau_factory*(t.tech.isolation?2.75:.9)}),t.tech.isolation&&t.tauceti.colony&&n.colony&&La.general.add.push({name:z("tau_home_colony"),manual:.5*n.colony,auto:.5*n.colony}),n.zero_g_lab&&s.zero_g_lab||n.infectious_disease_lab&&s.infectious_disease_lab){let e=lt("spc_enceladus");La.Quantium.multi.push({name:z("space_syndicate"),manual:1,auto:e})}if(t.tech.alien_crafting&&n.infectious_disease_lab&&s.infectious_disease_lab){let e=1+.65*Math.min(n.infectious_disease_lab,s.infectious_disease_lab);La.Quantium.multi.push({name:z("tech_infectious_disease_lab_alt"),manual:1,auto:e})}if(t.race.crafty&&La.general.add.push({name:z("wiki_arpa_crispr_crafty"),manual:.03,auto:.03}),t.race.ambidextrous&&La.general.add.push({name:z("trait_ambidextrous_name"),manual:Ei.ambidextrous.vars()[0]*t.race.ambidextrous/100,auto:Ei.ambidextrous.vars()[0]*t.race.ambidextrous/100}),t.race.rigid&&La.general.add.push({name:z("trait_rigid_name"),manual:-Ei.rigid.vars()[0]/100,auto:-Ei.rigid.vars()[0]/100}),"socialist"===t.civic.govern.type&&La.general.multi.push({name:z("govern_socialist"),manual:1+Y.socialist()[0]/100,auto:1+Y.socialist()[0]/100}),t.race.casting&&t.race.casting.crafting){let e=1+t.race.casting.crafting/(t.race.casting.crafting+75),a=1+2*t.race.casting.crafting/(2*t.race.casting.crafting+75);La.general.multi.push({name:z("modal_pylon_casting"),manual:e,auto:a})}"magic"===t.race.universe&&La.general.multi.push({name:z("universe_magic"),manual:.8,auto:.8}),t.tech.v_train&&La.general.multi.push({name:z("tech_vocational_training"),manual:1,auto:2}),t.genes.crafty&&La.general.multi.push({name:z("tab_arpa_crispr")+" "+z("wiki_arpa_crispr_crafty"),manual:1,auto:1+.5*(t.genes.crafty-1)}),t.race.living_tool&&La.general.multi.push({name:z("trait_living_tool_name"),manual:1,auto:1+Ei.living_tool.vars()[1]/100}),t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=1&&La.general.multi.push({name:z("evo_challenge_orbit_decay"),manual:1,auto:1.1}),t.race.ambidextrous&&La.general.multi.push({name:z("trait_ambidextrous_name"),manual:1,auto:1+Ei.ambidextrous.vars()[1]*t.race.ambidextrous/100}),t.blood.artisan&&La.general.multi.push({name:z("tab_arpa_blood")+" "+z("arpa_blood_artisan_title"),manual:1,auto:1+t.blood.artisan/100});let a=function(){if(t.race.no_plasmid||"antimatter"===t.race.universe){let e=!(!t.race.cataclysm&&!t.race.orbit_decayed);if(e&&t.space.ziggurat&&t.space.ziggurat.count||t.city.temple&&t.city.temple.count){let a=t.tech.anthropology&&t.tech.anthropology>=1?.016:.01;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=t.civic.professor.workers*("antimatter"===t.race.universe?2e-4:4e-4);t.race.high_pop&&(e=ke(e)),a+=e}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?15e-5:t.genes.ancients>=3?125e-6:1e-4;t.race.high_pop&&(e=ke(e)),a+=e*t.civic.priest.workers}"antimatter"===t.race.universe?a/=t.race.nerfed?3:2:t.race.nerfed&&(a/=2),t.race.spiritual&&(a*=1+Ei.spiritual.vars()[0]/100);let r=ts("seraph");return r>0&&(a*=1+Ei.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1.12),t.race.ooze&&(a*=1-Ei.ooze.vars()[1]/100),(e?t.space.ziggurat.count:t.city.temple.count)*a}}return 0}();a>0&&La.general.multi.push({name:z("faith"),manual:1,auto:1+a/("antimatter"===t.race.universe?1.5:3)}),t.prestige.Plasmid.count>0&&La.general.multi.push({name:z("resource_Plasmid_plural_name"),manual:kr()/8+1,auto:kr()/8+1}),t.genes.challenge&&t.genes.challenge>=2&&La.general.multi.push({name:z("mastery"),manual:1+Ts()/(t.race.weak_mastery?50:100),auto:1+Ts()/(t.race.weak_mastery?50:100)})}});var La;function Ea(e){if(e)switch(e){case"market":dr();break;case"storage":pr();break;case"ejector":hr();break;case"supply":gr();break;case"alchemy":fr()}else dr(),pr(),hr(),gr(),fr()}function Ka(e){"market"===e?(Ea("market"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;if(a.resource[e].tradable){var r=$(`
                `);$("#market").append(r),Va(`#market-${e}`,r,e,t,!0)}})),Ba()):"storage"===e?(Ea("storage"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;if(a.resource[e].stackable){var r=$(`
                `);$("#resStorage").append(r),er(`#stack-${e}`,r,e,t)}})),Ba()):"ejector"===e?(Ea("ejector"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;Fa[e]&&mr(e,t)}))):"supply"===e?(Ea("supply"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;Aa[e]&&vr(e,t)}))):"alchemy"===e&&(Ea("alchemy"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let r=a.resource[e].color,i=a.resource[e].tradable;za[e]&&"magic"===t.race.universe&&(t.resource[e].basic=i,yr(e,r,i))})))}function Da(e){if("protoplasm"===t.race.species){let a=100;t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1&&(a+=50*(t.stats.achieve.mass_extinction.l-1)),Ga("RNA",e,a,1,!1),Ga("DNA",e,a,1,!1)}Ga("Money",e,1e3,1,!1,!1,"success"),Ga(t.race.species,e,0,0,!1,!1,"warning"),Ga("Slave",e,0,0,!1,!1,"warning"),Ga("Mana",e,0,1,!1,!1,"warning"),Ga("Energy",e,0,0,!1,!1,"warning"),Ga("Sus",e,0,0,!1,!1,"warning"),Ga("Knowledge",e,100,1,!1,!1,"warning"),Ga("Zen",e,0,0,!1,!1,"warning"),Ga("Crates",e,0,0,!1,!1,"warning"),Ga("Containers",e,0,0,!1,!1,"warning"),Ga("Food",e,250,1,!0,!0),Ga("Lumber",e,200,1,!0,!0),Ga("Chrysotile",e,200,1,!0,!0),Ga("Stone",e,200,1,!0,!0),Ga("Crystal",e,200,1,!0,!0),Ga("Furs",e,100,1,!0,!0),Ga("Copper",e,100,1,!0,!0),Ga("Iron",e,100,1,!0,!0),Ga("Aluminium",e,50,1,!0,!0),Ga("Cement",e,100,1,!0,!0),Ga("Coal",e,50,1,!0,!0),Ga("Oil",e,0,1,!0,!1),Ga("Uranium",e,10,1,!0,!1),Ga("Steel",e,50,1,!0,!0),Ga("Titanium",e,50,1,!0,!0),Ga("Alloy",e,50,1,!0,!0),Ga("Polymer",e,50,1,!0,!0),Ga("Iridium",e,0,1,!0,!0),Ga("Helium_3",e,0,1,!0,!1),Ga("Water",e,0,1,!1,!1,"advanced"),Ga("Deuterium",e,0,1,!1,!1,"advanced"),Ga("Neutronium",e,0,1,!1,!1,"advanced"),Ga("Adamantite",e,0,1,!1,!0,"advanced"),Ga("Infernite",e,0,1,!1,!1,"advanced"),Ga("Elerium",e,1,1,!1,!1,"advanced"),Ga("Nano_Tube",e,0,1,!1,!1,"advanced"),Ga("Graphene",e,0,1,!1,!0,"advanced"),Ga("Stanene",e,0,1,!1,!0,"advanced"),Ga("Bolognium",e,0,1,!1,!0,"advanced"),Ga("Vitreloy",e,0,1,!1,!0,"advanced"),Ga("Orichalcum",e,0,1,!1,!0,"advanced"),Ga("Unobtainium",e,0,1,!1,!1,"advanced"),Ga("Materials",e,0,1,!1,!1,"advanced"),Ga("Horseshoe",e,-2,0,!1,!1,"advanced"),Ga("Nanite",e,0,1,!1,!1,"advanced"),Ga("Genes",e,-2,0,!1,!1,"advanced"),Ga("Soul_Gem",e,-2,0,!1,!1,"advanced"),Ga("Plywood",e,-1,0,!1,!1,"danger"),Ga("Brick",e,-1,0,!1,!1,"danger"),Ga("Wrought_Iron",e,-1,0,!1,!1,"danger"),Ga("Sheet_Metal",e,-1,0,!1,!1,"danger"),Ga("Mythril",e,-1,0,!1,!1,"danger"),Ga("Aerogel",e,-1,0,!1,!1,"danger"),Ga("Nanoweave",e,-1,0,!1,!1,"danger"),Ga("Scarletite",e,-1,0,!1,!1,"danger"),Ga("Quantium",e,-1,0,!1,!1,"danger"),Ga("Corrupt_Gem",e,-2,0,!1,!1,"caution"),Ga("Codex",e,-2,0,!1,!1,"caution"),Ga("Cipher",e,0,1,!1,!1,"caution"),Ga("Demonic_Essence",e,-2,0,!1,!1,"caution"),e||(Ra("Blood_Stone","caution"),Ra("Artifact","caution"),Ra("Plasmid"),Ra("AntiPlasmid"),Ra("Phage"),Ra("Dark"),Ra("Harmony"),Ra("AICore"))}function Ba(){"protoplasm"!==t.race.species&&(function(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=t.race.no_trade?" nt":"";var a=$(`
                ${z("resource_market_trade_routes")} / {{ mtrade }}
                `);a.append($(`${z("cancel_all_routes")}`)),$("#market").append(a),Cs({el:"#tradeTotal",data:t.city.market,methods:{zero(){Object.keys(t.resource).forEach((function(e){t.resource[e].trade&&(t.city.market.trade-=Math.abs(t.resource[e].trade),t.resource[e].trade=0,rr(e))}))}},filters:{tdeCnt(e){let a=Qs(17,11);return(100===e&&!t.tech.isolation&&!t.race.cataclysm||10===e&&(t.tech.isolation||t.race.cataclysm))&&a.length>0?"10"+a:e}}}),ls("tradeTotalPopover",(function(){let e=$('
                ');return r.hasOwnProperty("t_route")&&Object.keys(r.t_route).forEach((function(t){r.t_route[t]>0&&e.append(``)})),e.append(``),e}),{elm:"#tradeTotalPopover > span"})}(),(t.settings.tabLoad||4===t.settings.civTabs&&0===t.settings.marketTabs)&&($("#market").append($(`

                ${z("galaxy_trade")}

                `)),Qa()),function(){if(t.settings.tabLoad||4===t.settings.civTabs&&1===t.settings.marketTabs){var e=$(`
                ${z("resource_Crates_name")}{{ cr.amount }} / {{ cr.max }}${z("resource_Containers_name")}{{ cn.amount }} / {{ cn.max }}
                `);$("#resStorage").append(e),Cs({el:"#crateTotal",data:{cr:t.resource.Crates,cn:t.resource.Containers}})}}())}function Ga(e,r,i,s,n,c,o){if(o=o||"info",t.resource[e]||(t.resource[e]={}),Na(e),t.race.artifical&&"Food"===e&&(c=!1),r)return;var l;t.resource[e].hasOwnProperty("display")||(t.resource[e].display=!1),t.resource[e].hasOwnProperty("value")||(t.resource[e].value=t.race.truepath?2*Ca[e]:Ca[e]),t.resource[e].hasOwnProperty("amount")||(t.resource[e].amount=0),t.resource[e].hasOwnProperty("max")||(t.resource[e].max=i),t.resource[e].hasOwnProperty("diff")||(t.resource[e].diff=0),t.resource[e].hasOwnProperty("delta")||(t.resource[e].delta=0),t.resource[e].hasOwnProperty("rate")||(t.resource[e].rate=s),"Mana"===e&&(t.resource[e].gen=0,t.resource[e].gen_d=0),t.resource[e].stackable=c,t.resource[e].crates||(t.resource[e].crates=0),t.resource[e].containers||(t.resource[e].containers=0),!t.resource[e].trade&&n&&(t.resource[e].trade=0),l=-1===t.resource[e].max||-2===t.resource[e].max?$(`

                {{ name | namespace }}

                {{ amount | diffSize }}
                `):$(`

                {{ name | namespace }}

                {{ amount | size }} / {{ max | size }}
                `),c?l.append($(`+`)):(-1!==i||-1===i&&0===s&&t.race.no_craft||"Scarletite"===e||"Quantium"===e)&&l.append($(""));let _=!1;if(0!==s||-1===i&&0===s&&t.race.no_craft||"Scarletite"===e||"Quantium"===e)l.append($(`{{ diff | diffSize }} /s`));else if(-1!==i||t.race.no_craft||"Scarletite"===e||"Quantium"===e)l.append($(""));else{let t=$('');l.append(t);let a=[1,5];for(let r=0;r+${a[r]}`));t.append($(`+A`)),_=!0}$("#resources").append(l);var d={template:''};if(Cs({el:`#res${e}`,data:t.resource[e],filters:{size:function(e){return e?x(e,0):e},diffSize:function(a){return"Horseshoe"===e&&!t.race.hooved&&cn("fool",2023)&&(a=5),x(a,2)},namespace:e=>e.replace("_"," ")},methods:{resRate:e=>`${e} ${x(t.resource[e].diff,2)} per second`,trigModal(){this.$buefy.modal.open({parent:this,component:d});var a=setInterval((function(){$("#modalBox").length>0&&(clearInterval(a),function(e){$("#modalBox").append($('

                {{ name }} - {{ amount | size }}/{{ max | size }}

                '));let a=$('
                ');if($("#modalBox").append(a),"Food"===e&&!t.race.artifical||t.race.artifical&&"Coal"===e){let e=Qs(7,10);e.length>0&&$("#modalBoxTitle").prepend(e)}if("Stone"===e){let e=Js(1,12,!1);e.length>0&&$("#modalBoxTitle").prepend(e)}let r=$('
                ');a.append(r),r.append($(`
                ${z("resource_modal_crate_owned")} {{ crates.amount }}/{{ crates.max }}${z("resource_modal_crate_assigned")} {{ res.crates }}
                `));let i=$(``),s=$(``),n=$(``);if(r.append(i),r.append(s),r.append(n),Cs({el:"#modalCrates",data:{crates:t.resource.Crates,res:t.resource[e]},methods:{buildCrate(){cr()},subCrate(e){Ja(e)},addCrate(e){Za(e)}}}),t.resource.Containers.display){let r=$('
                ');a.append(r),r.append($(`
                ${z("resource_modal_container_owned")} {{ containers.amount }}/{{ containers.max }}${z("resource_modal_container_assigned")} {{ res.containers }}
                `));let i=$(``),s=$(``),n=$(``);r.append(i),r.append(s),r.append(n),Cs({el:"#modalContainers",data:{containers:t.resource.Containers,res:t.resource[e]},methods:{buildContainer(){or()},removeContainer(e){Xa(e)},addContainer(e){Ya(e)}}})}Cs({el:"#modalBoxTitle",data:t.resource[e],filters:{size:function(e){return x(e,0)},diffSize:function(e){return x(e,2)}}}),["modalCrates","modalContainers"].forEach((function(e){["assign","unassign","construct"].forEach((function(t){ls(`${e}${t}`,function(e,t){if("modalContainers"===e){let e=_r();switch(t){case"assign":return z("resource_modal_container_assign_desc",[e]);case"unassign":return z("resource_modal_container_unassign_desc",[e]);case"construct":return sr()}}else{let e=lr();switch(t){case"assign":return z("resource_modal_crate_assign_desc",[e]);case"unassign":return z("resource_modal_crate_unassign_desc",[e]);case"construct":return ir()}}}(e,t),{elm:$(`#${e} > .${t}`),attach:"#main"})}))}))}(e))}),50)},showTrigger:()=>t.resource.Crates.display,craft(e,a){if(!t.race.no_craft){let r=Ta(e,"manual").multiplier,i=Ia(),s=Math.floor(t.resource[i[e][0].r].amount/i[e][0].a);for(let a=1;a${t.resource[i[e][s].r].name} ${n}`}return r}}}),ar(`cnt${e}`,e,"c"),_){let a=[1,5,"A"];for(let r=0;r"),s=e,n=a[r],c=+(100*Ta(s,"manual").multiplier).toFixed(0);i.append($(`
                ${z("manual_crafting_hover_bonus",[c.toLocaleString(),t.resource[s].name])}
                `));let o=Ia(),l=$(`
                ${z("manual_crafting_hover_craft")}
                `),_=0;if("number"!=typeof n){if(_=t.resource[o[s][0].r].amount/o[s][0].a,o[s].length>1)for(let e=1;e${x(c/100*_,1)} ${t.resource[s].name}`))}else{_=y()*n;let e=x(c/100*_,1);l.append($(`${e} ${t.resource[s].name}`))}let d=$(`
                ${z("manual_crafting_hover_use")}
                `);for(let e=0;e${x(_*o[s][e].a,1)} ${t.resource[o[s][e].r].name}`)),e+1, "));return i.append(l),i.append(d),i};tr(`inc${e}${a[r]}`,e,"manual",i)}}c&&ls(`con${e}`,(function(){var a=$(`
                ${z("resource_Crates_plural")} ${t.resource[e].crates}
                `);return t.tech.steel_container&&a.append($(`
                ${z("resource_Containers_plural")} ${t.resource[e].containers}
                `)),a})),e!==t.race.species&&"Crates"!==e&&"Containers"!==e&&-1!==i?ar(`inc${e}`,e,"p"):-1===i&&tr(`inc${e}`,e,"auto"),$(`#res${e}`).on("mouseover",(function(){$(`.res-${e}`).each((function(){t.resource[e].amount>=$(this).attr(`data-${e}`)?$(this).addClass("hl-ca"):$(this).addClass("hl-cna")}))})),$(`#res${e}`).on("mouseout",(function(){$(`.res-${e}`).each((function(){$(this).removeClass("hl-ca"),$(this).removeClass("hl-cna")}))})),void 0===a.resource&&(a.resource={}),a.resource[e]={color:o,tradable:n,stackable:c}}function Na(e){if(e===t.race.species?t.resource[e].name=nn("name"):t.resource[e].name="Money"===e?"$":z(`resource_${e}_name`),cn("fool",2022))switch(e){case"Lumber":t.resource[e].name=z("resource_Stone_name");break;case"Stone":t.resource[e].name=z("resource_Lumber_name");break;case"Copper":t.resource[e].name=z("resource_Iron_name");break;case"Iron":t.resource[e].name=z("resource_Copper_name");break;case"Steel":t.resource[e].name=z("resource_Titanium_name");break;case"Titanium":t.resource[e].name=z("resource_Steel_name");break;case"Coal":t.resource[e].name=z("resource_Oil_name");break;case"Oil":t.resource[e].name=z("resource_Coal_name");break;case"Alloy":t.resource[e].name=z("resource_Polymer_name");break;case"Polymer":t.resource[e].name=z("resource_Alloy_name");break;case"Graphene":t.resource[e].name=z("resource_Stanene_name");break;case"Stanene":t.resource[e].name=z("resource_Graphene_name");break;case"Plywood":t.resource[e].name=z("resource_Brick_name");break;case"Brick":t.resource[e].name=z("resource_Plywood_name");break;case"Genes":t.resource[e].name=z("resource_Soul_Gem_name");break;case"Soul_Gem":t.resource[e].name=z("resource_Genes_name");break;case"Slave":t.resource[e].name=z("resource_Peon_name")}if("Horseshoe"===e&&(t.resource[e].name=hn()),t.race.artifical&&"Genes"===e&&(t.resource[e].name=z("resource_Program_name")),t.race.sappy)"Stone"===e&&(t.resource[e].name=z("resource_Amber_name"));else if(t.race.flier)switch(e){case"Stone":t.resource[e].name=z("resource_Clay_name");break;case"Brick":t.resource[e].name=z("resource_Mud_Brick_name")}if(t.race.soul_eater&&"Food"===e&&(t.resource[e].name=z("resource_Souls_name")),t.race.evil)switch(e){case"Lumber":t.resource[e].name=z("resource_Bones_name");break;case"Furs":t.resource[e].name=z("resource_Flesh_name");break;case"Plywood":t.resource[e].name=z("resource_Boneweave_name")}if(t.race.artifical&&"Food"===e&&(t.resource[e].name=z("resource_Signal_name")),cn("halloween").active)switch(e){case"Food":t.resource[e].name=z("resource_Candy_name");break;case"Lumber":t.resource[e].name=z("resource_Bones_name");break;case"Stone":t.resource[e].name=z("resource_RockCandy_name");break;case"Furs":t.resource[e].name=z("resource_Webs_name");break;case"Plywood":t.resource[e].name=z("resource_Boneweave_name");break;case"Brick":t.resource[e].name=z("resource_Tombstone_name");break;case"Soul_Gem":t.resource[e].name=z("resource_CandyCorn_name")}}function Ra(e,a){if($(`#res${e}`).length){let t=$(`#res${e}`);return t.detach(),void $("#resources").append(t)}a=a||"special";var r=$(`
                ${z(`resource_${e}_name`)}{{ count | round }}
                `);$("#resources").append(r),Cs({el:`#res${e}`,data:t.prestige[e],filters:{round:e=>+e.toFixed(3)}}),"Artifact"!==e&&"Blood_Stone"!==e&&ls(`res${e}`,(function(){let a=$("
                ");switch(e){case"Plasmid":let r=t.race.no_plasmid?Math.min(t.race.p_mutation,t.prestige.Plasmid.count):t.prestige.Plasmid.count;if(a.append($(`${z(`resource_${e}_desc`,[r,+(100*kr("plasmid")).toFixed(2)])}`)),t.genes.store&&("antimatter"!==t.race.universe||t.genes.bleed>=3)){let e=br(1,"plasmid");e>1&&a.append($(` ${z("resource_Plasmid_desc2",[+(100*(e-1)).toFixed(2)])}`))}break;case"AntiPlasmid":a.append($(`${z(`resource_${e}_desc`,[t.prestige.AntiPlasmid.count,+(100*kr("antiplasmid")).toFixed(2)])}`));let i=br(1,"anti");t.genes.store&&("antimatter"===t.race.universe||t.genes.bleed>=3)&&i>1&&a.append($(` ${z("resource_Plasmid_desc2",[+(100*(i-1)).toFixed(2)])}`));break;case"Phage":a.append($(`${z(t.prestige.AntiPlasmid.count>0?"resource_Phage_desc2":"resource_Phage_desc",[250+t.prestige.Phage.count])}`));let s=br(1,"phage");t.genes.store&&t.genes.store>=4&&s>1&&a.append($(` ${z("resource_Plasmid_desc2",[+(100*(s-1)).toFixed(2)])}`));break;case"Dark":switch(t.race.universe){case"standard":a.append($(`${z(`resource_${e}_desc_s`,[+(100*(Is("standard")-1)).toFixed(2)])}`));break;case"evil":a.append($(`${z(`resource_${e}_desc_e`,[+(100*(Is("evil")-1)).toFixed(2)])}`));break;case"micro":a.append($(`${z(`resource_${e}_desc_m`,[Is("micro",!1),Is("micro",!0)])}`));break;case"heavy":let t=Is("heavy"),r=.25+.5*t,i=.2+.3*t;a.append($(`${z(`resource_${e}_desc_h`,[+(100*r).toFixed(4),+(100*i).toFixed(4)])}`));break;case"antimatter":a.append($(`${z(`resource_${e}_desc_a`,[+(100*(Is("antimatter")-1)).toFixed(2)])}`));break;case"magic":a.append($(`${z(`resource_${e}_desc_mg`,[z("resource_Mana_name"),+(100*(Is("magic")-1)).toFixed(2)])}`))}break;case"Harmony":a.append($(`${z(`resource_${e}_desc`,["standard"===t.race.universe?.1:1,js()])}`));break;case"AICore":let n=+(100*(1-.99**t.prestige.AICore.count)).toFixed(2);a.append($(`${z(`resource_${e}_desc`,[n])}`))}return a}))}function Ha(e){let a=t.tech.currency>=6?-1e6:t.tech.currency>=4?-100:-25;if(t.race.banana){let r=!1;if(Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&t.resource[e].trade<0&&(r=e)})),r&&r!==e)return!1;a=t.tech.currency>=6?-1e6:t.tech.currency>=4?-25:-10}return!(t.resource[e].trade<=a)}function Ua(e){let a=t.tech.currency>=6?1e6:t.tech.currency>=4?100:25;return!(t.resource[e].trade>=a)}function Va(e,a,r,i,s){if((t.settings.tabLoad||4===t.settings.civTabs&&0===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==r)){if(s&&a.append($(`

                {{ r.name | namespace }}

                `)),t.race.no_trade||(a.append($(`${z("resource_market_buy")}`)),a.append($(`\${{ r.value | buy }}`)),a.append($(`${z("resource_market_sell")}`)),a.append($(`\${{ r.value | sell }}`))),s&&(t.race.banana&&"Food"===r||t.tech.trade&&!t.race.terrifying)){let e=$(`${z("resource_market_routes")}`);a.append(e),e.append($(`-`)),e.append($('')),e.append($(`+`)),e.append($(`${z("cancel_routes")}`)),rr(r)}Cs({el:e,data:{r:t.resource[r],m:t.city.market},methods:{aSell(e){let a=1===za[e]?z("resource_market_unit"):z("resource_market_units"),r=function(e){let a=4;t.race.merchant&&(a*=1-Ei.merchant.vars()[0]/100);let r=ts("goblin");r>0&&(a*=1-Ei.merchant.vars(1)[0]/100*r),t.race.asymmetrical&&(a*=1+Ei.asymmetrical.vars()[0]/100),t.race.conniving&&a--;let i=t.resource[e].value*za[e]/a;if(t.city.wharf&&(i*=1+.01*t.city.wharf.count),t.space.gps&&t.space.gps.count>3&&(i*=1+.01*t.space.gps.count),t.tech.railway){let e=t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?.03:.02;i*=1+t.tech.railway*e}return t.race.truepath&&!t.race.lone_survivor&&(i*=1-t.civic.foreign.gov3.hstl/101),t.race.inflation&&(i*=1+t.race.inflation/500),t.race.witch_hunter&&t.resource.Sus.amount>50&&(i*=1-(t.resource.Sus.amount-50)/52),i*=$e("psychic_cash"),i=+i.toFixed(1),i}(e),i=za[e];if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),i*=1-e/100}return i=+i.toFixed(3),z("resource_market_auto_sell_desc",[i,a,r])},aBuy(e){let a=za[e],r=K("dealmaker",0);r&&(a*=1+r/100),t.race.persuasive&&(a*=1+t.race.persuasive/100),t.race.merchant&&(a*=1+Ei.merchant.vars()[1]/100);let i=ts("goblin");if(i>0&&(a*=1+Ei.merchant.vars(1)[1]/100*i),t.genes.trader&&(a*=1+Ts()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1+e/50}t.race.truepath&&(a*=1-t.civic.foreign.gov3.hstl/101),a=+a.toFixed(3);let s=z(1===a?"resource_market_unit":"resource_market_units"),n=function(e){let a=t.resource[e].value;t.race.arrogant&&(a*=1+Ei.arrogant.vars()[0]/100),t.race.conniving&&(a*=1-Ei.conniving.vars()[0]/100);let r=ts("imp");r>0&&(a*=1-Ei.conniving.vars(1)[0]/100*r);let i=a*za[e];return t.city.wharf&&(i*=.99**t.city.wharf.count),t.space.gps&&t.space.gps.count>3&&(i*=.99**t.space.gps.count),t.tech.railway&&(i*=(t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?.97:.98)**t.tech.railway),t.race.truepath&&!t.race.lone_survivor&&(i*=1+t.civic.foreign.gov3.hstl/101),t.race.inflation&&(i*=1+t.race.inflation/300),t.race.quarantine&&(i*=1+Math.round(t.race.quarantine**3.5)),t.race.witch_hunter&&t.resource.Sus.amount>50&&(i*=1+(t.resource.Sus.amount-50)/8),i=+i.toFixed(1),i}(e);return z("resource_market_auto_buy_desc",[a,s,n])},purchase(e){if(!t.race.no_trade&&!t.settings.pause){let a=t.city.market.qty,r=t.resource[e].value;t.race.arrogant&&(r*=1+Ei.arrogant.vars()[0]/100),t.race.conniving&&(r*=1-Ei.conniving.vars()[0]/100);let i=ts("imp");i>0&&(r*=1-Ei.conniving.vars(1)[0]/100*i);let s=Math.floor(Math.min(a,t.resource.Money.amount/r,t.resource[e].max-t.resource[e].amount));s>0&&(t.resource[e].amount+=s,t.resource.Money.amount-=Math.round(r*s),t.resource[e].value+=Number((s/Math.rand(1e3,1e4)).toFixed(2)))}},sell(e){if(!t.race.no_trade&&!t.settings.pause){let a=t.city.market.qty,r=4;t.race.merchant&&(r*=1-Ei.merchant.vars()[0]/100);let i=ts("goblin");i>0&&(r*=1-Ei.merchant.vars(1)[0]/100*i),t.race.asymmetrical&&(r*=1+Ei.asymmetrical.vars()[0]/100),t.race.conniving&&(r*=1-Ei.conniving.vars()[1]/100);let s=ts("imp");s>0&&(r*=1-Ei.conniving.vars(1)[1]/100*s);let n=t.resource[e].value/r,c=Math.floor(Math.min(a,t.resource[e].amount,(t.resource.Money.max-t.resource.Money.amount)/n));c>0&&(t.resource[e].amount-=c,t.resource.Money.amount+=Math.round(n*c),t.resource[e].value-=Number((c/Math.rand(1e3,1e4)).toFixed(2)),t.resource[e].value0&&(a+=t.resource[r].trade)})),e<=a)break}if(t.resource[e].trade>=0){if(!(Ua(e)&&t.city.market.trade(t.race.arrogant&&(e*=1+Ei.arrogant.vars()[0]/100),x(e*t.city.market.qty,0)),sell(e){let a=4;t.race.merchant&&(a*=1-Ei.merchant.vars()[0]/100);let r=ts("goblin");return r>0&&(a*=1-Ei.merchant.vars(1)[0]/100*r),t.race.asymmetrical&&(a*=1+Ei.asymmetrical.vars()[0]/100),x(e*t.city.market.qty/a,0)},trade(e){if("Stone"===r&&(31===e||-31===e)){let e=Js(3,12,!1);if(e.length>0)return e}return e<0?"-"+(e=0-e):e>0?`+${e}`:0},namespace:e=>e.replace("_"," ")}})}}function Wa(){return[{buy:{res:"Deuterium",vol:5},sell:{res:"Helium_3",vol:25}},{buy:{res:"Neutronium",vol:2.5},sell:{res:"Copper",vol:200}},{buy:{res:"Adamantite",vol:3},sell:{res:"Iron",vol:300}},{buy:{res:"Elerium",vol:1},sell:{res:"Oil",vol:125}},{buy:{res:"Nano_Tube",vol:10},sell:{res:"Titanium",vol:20}},{buy:{res:"Graphene",vol:25},sell:{res:t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Lumber",vol:1e3}},{buy:{res:"Stanene",vol:40},sell:{res:"Aluminium",vol:800}},{buy:{res:"Bolognium",vol:.75},sell:{res:"Uranium",vol:4}},{buy:{res:"Vitreloy",vol:1},sell:{res:"Infernite",vol:1}}]}function Qa(e){let a=e||$("#galaxyTrade");if(e||Ss($("#galaxyTrade")),t.galaxy.trade){a.append($(`
                ${z("galaxy_trade")}
                `));let e=Wa();for(let r=0;r');a.append(i),i.append($(`${t.resource[e[r].buy.res].name}`)),i.append($(`+{{ '${r}' | t_vol }}/s`)),i.append($(`${t.resource[e[r].sell.res].name}`)),i.append($(`-{{ '${r}' | s_vol }}/s`));let s=$(`${z("resource_market_routes")}`);i.append(s);let n=z("galaxy_freighter_assign",[t.resource[e[r].buy.res].name,t.resource[e[r].sell.res].name]),c=z("galaxy_freighter_unassign",[t.resource[e[r].buy.res].name,t.resource[e[r].sell.res].name]);s.append($(`-`)),s.append($(`{{ g.f${r} }}`)),s.append($(`+`)),s.append($(`${z("cancel_routes")}`))}let r=$(`
                ${z("resource_market_galactic_trade_routes")} {{ g.cur }} / {{ g.max }}
                `);r.append($(`${z("cancel_all_routes")}`)),a.append(r)}Cs({el:e?"#specialModal":"#galaxyTrade",data:{g:t.galaxy.trade,t:t.tech},methods:{less(e){let a=y();t.galaxy.trade[`f${e}`]>=a?(t.galaxy.trade[`f${e}`]-=a,t.galaxy.trade.cur-=a):(t.galaxy.trade.cur-=t.galaxy.trade[`f${e}`],t.galaxy.trade[`f${e}`]=0)},more(e){let a=y();t.galaxy.trade.curt.galaxy.trade.max-t.galaxy.trade.cur&&(a=t.galaxy.trade.max-t.galaxy.trade.cur),t.galaxy.trade[`f${e}`]+=a,t.galaxy.trade.cur+=a)},zero(e){if(e)t.galaxy.trade.cur-=t.galaxy.trade[`f${e}`],t.galaxy.trade[`f${e}`]=0;else{let e=Wa();for(let a=0;ae},filters:{t_vol(e){let a=Wa()[e].buy.vol;t.race.persuasive&&(a*=1+t.race.persuasive/100),t.race.merchant&&(a*=1+Ei.merchant.vars()[1]/100);let r=ts("goblin");if(r>0&&(a*=1+Ei.merchant.vars(1)[1]/100*r),t.genes.trader&&(a*=1+Ts()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1+e/50}return a=+a.toFixed(2),a},s_vol(e){let a=Wa()[e].sell.vol;if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1-e/100}return a=+a.toFixed(2),a}}}),ls("galacticTradeTotal",(function(){let e=$('
                ');return r.hasOwnProperty("gt_route")&&Object.keys(r.gt_route).forEach((function(t){r.gt_route[t]>0&&e.append(``)})),e.append(``),e}),{elm:"#galacticTradeTotal > span"})}function Ja(e){let a=y(),r=lr();a>t.resource[e].crates&&(a=t.resource[e].crates),a>0&&(t.resource.Crates.amount+=a,t.resource.Crates.max+=a,t.resource[e].crates-=a,t.resource[e].max-=r*a)}function Za(e){let a=y(),r=lr();a>t.resource.Crates.amount&&(a=t.resource.Crates.amount),a>0&&(t.resource.Crates.amount-=a,t.resource.Crates.max-=a,t.resource[e].crates+=a,t.resource[e].max+=r*a)}function Xa(e){let a=y(),r=_r();a>t.resource[e].containers&&(a=t.resource[e].containers),a>0&&(t.resource.Containers.amount+=a,t.resource.Containers.max+=a,t.resource[e].containers-=a,t.resource[e].max-=r*a)}function Ya(e){let a=y(),r=_r();a>t.resource.Containers.amount&&(a=t.resource.Containers.amount),a>0&&(t.resource.Containers.amount-=a,t.resource.Containers.max-=a,t.resource[e].containers+=a,t.resource[e].max+=r*a)}function er(e,a,r,i){if(t.settings.tabLoad||4===t.settings.civTabs&&1===t.settings.marketTabs){if(a.append($(`

                {{ name }}

                `)),t.resource.Crates.display){let e=$(`${z("resource_Crates_name")}`);a.append(e),e.append($(`«`)),e.append($(``)),e.append($(`»`))}if(t.resource.Containers.display){let e=$(`${z("resource_Containers_name")}`);a.append(e),e.append($(`«`)),e.append($('')),e.append($(`»`))}Cs({el:e,data:t.resource[r],methods:{addCrate(e){Za(e)},subCrate(e){Ja(e)},addCon(e){Ya(e)},subCon(e){Xa(e)}},filters:{trick(e){if("Stone"===r&&10===t.resource[r].crates&&31===t.resource[r].containers){let e=Js(4,13,!0);if(e.length>0)return e}return e},cCnt(e,a){if("Food"===a&&!t.race.artifical||t.race.artifical&&"Coal"===a){let t=Qs(13,10);if(10===e&&t.length>0)return"1"+t}return e}}})}}function tr(e,a,i,s){ls(`${e}`,(function(){let e=$('
                {{ res.name | namespace }}
                '),n=$('
                ');e.append(n);let c=Ta(a,i),o=$("
                ");n.append(o),"auto"===i&&r.p[a]&&Object.keys(r.p[a]).forEach((function(e){let t=r.p[a][e],i=parseFloat(t.slice(0,-1));if(0!=i&&!isNaN(i)){let t=i>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),o.append(``)}})),Object.keys(c.multi_bd).forEach((function(e){let t=c.multi_bd[e],a=parseFloat(t.slice(0,-1));if(0!=a&&!isNaN(a)){let t=a>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),o.append(``)}}));let l=$('
                '),_=$(`
                ${z("craft_tools_multi")}
                `);l.append(_);let d=0;if(Object.keys(c.add_bd).forEach((function(e){let t=c.add_bd[e],a=parseFloat(t.slice(0,-1));if(0!=a&&!isNaN(a)){d++;let t=a>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),l.append(``)}})),d>0&&n.append(l),r.p.consume&&r.p.consume[a]){let e=$('
                '),t=0;Object.keys(r.p.consume[a]).forEach((function(i){let s=r.p.consume[a][i];if(0!=s&&!isNaN(s)){t++;let r=s>0?"success":"danger",n=i.replace(/\+.+$/,"");i=i.replace(/'/g,"\\'"),e.append(``)}})),t>0&&n.append(e)}return t.resource[a].diff<0&&t.resource[a].amount>0&&e.append(``),s&&(e.append(''),e.append(s)),e}),{in:function(){Cs({el:"#popper > div",data:{[a]:r.p[a],res:t.resource[a],consume:r.p.consume,craft:Ta(a,i)},filters:{translate(e){let t=e[e.length-1],a=parseFloat(e.slice(0,-1)),r=a>0&&a<1||a<0&&a>-1?4:a>0&&a<10||a<0&&a>-10?3:2;a=+a.toFixed(r);let i="%"===t?"%":"";return a>0?"+"+x(a,r)+i:a<0?x(a,r)+i:void 0},fix:e=>e+"v",counter(e){let r=+(e/-t.resource[a].diff).toFixed(0);if(r>60){let e=r%60,t=(r-e)/60;if(t>=60){let e=t%60;return`${(t-e)/60}h ${e}m`}return`${t}m ${e}s`}return`${r}s`},namespace:e=>e.replace("_"," ")}})},out:function(){Cs({el:"#popper > div"},"destroy")},classes:"breakdown has-background-light has-text-dark",prop:{modifiers:{preventOverflow:{enabled:!1},hide:{enabled:!1}}}})}function ar(e,a,i){ls(`${e}`,(function(){let e=$('
                {{ res.name | namespace }}
                '),s=$('
                ');e.append(s);let n=!1;if(r[i][a]){let e=$("
                ");s.append(e);let t=[a];t.push("Global");for(var c=0;c0?"success":"danger",i=t.replace(/\+.+$/,"");t=t.replace(/'/g,"\\'"),e.append(``)}}))}}if(r[i].consume&&r[i].consume[a]){let e=$(`
                `),t=0;Object.keys(r[i].consume[a]).forEach((function(s){let n=r[i].consume[a][s];if(0!=n&&!isNaN(n)){t++;let r=n>0?"success":"danger",i=s.replace(/\+.+$/,"");s=s.replace(/'/g,"\\'"),e.append(``)}})),t>0&&s.append(e)}if("p"===i){let r=t.resource[a].diff>0?"success":"danger";e.append(``)}return e}),{in:function(){Cs({el:"#popper > div",data:{Global:r[i].Global,[a]:r[i][a],consume:r[i].consume,res:t.resource[a]},filters:{translate(e){let t=e[e.length-1],a=parseFloat(e.slice(0,-1)),r=a>0&&a<1||a<0&&a>-1?4:a>0&&a<10||a<0&&a>-10?3:2,i="%"===t?"%":"";return a>0?"+"+x(a,r)+i:a<0?x(a,r)+i:void 0},fix:e=>e+"v",counter(e){let r=t.resource[a].diff,i=0;if(r<0?(r*=-1,i=+(e/r).toFixed(0)):i=+((t.resource[a].max-e)/r).toFixed(0),i===1/0||Number.isNaN(i))return"Never";if(i>60){let e=i%60,t=(i-e)/60;if(t>=60){let e=t%60;return`${(t-e)/60}h ${e}m`}return`${t}m ${e}s`}return`${i}s`},direction:e=>z(e>=0?"to_full":"to_empty"),namespace:e=>e.replace("_"," ")}})},out:function(){Cs({el:"#popper > div"},"destroy")},classes:"breakdown has-background-light has-text-dark",prop:{modifiers:{preventOverflow:{enabled:!1},hide:{enabled:!1}}}})}function rr(e){$(`#market-${e} .trade .current`).removeClass("has-text-warning"),$(`#market-${e} .trade .current`).removeClass("has-text-danger"),$(`#market-${e} .trade .current`).removeClass("has-text-success"),t.resource[e].trade>0?$(`#market-${e} .trade .current`).addClass("has-text-success"):t.resource[e].trade<0?$(`#market-${e} .trade .current`).addClass("has-text-danger"):$(`#market-${e} .trade .current`).addClass("has-text-warning")}function ir(){let e=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?t.resource.Chrysotile.name:t.resource.Stone.name:t.resource.Plywood?t.resource.Plywood.name:z("resource_Plywood_name");return z("resource_modal_crate_construct_desc",[t.race.kindling_kindred||t.race.smoldering?200:10,e,lr()])}function sr(){return z("resource_modal_container_construct_desc",[125,_r()])}function nr(e,t){switch(e){case"crate":cr(t);break;case"container":or(t)}}function cr(e){let a=e||y(),r=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood",i=t.race.kindling_kindred||t.race.smoldering?200:10;a+t.resource.Crates.amount>t.resource.Crates.max&&(a=t.resource.Crates.max-t.resource.Crates.amount),t.resource[r].amount=i*a&&t.resource.Crates.amountt.resource.Containers.max&&(a=t.resource.Containers.max-t.resource.Containers.amount),t.resource.Steel.amount<125*a&&(a=Math.floor(t.resource.Steel.amount/125)),t.resource.Steel.amount>=125*a&&t.resource.Containers.amount=2?500:350;t.tech.container&&t.tech.container>=4&&(e+=t.tech.container>=5?500:250),t.tech.container&&t.tech.container>=6&&(e+=t.tech.container>=7?1200:500),t.tech.container&&t.tech.container>=8&&(e+=4e3),t.race.pack_rat&&(e*=1+Ei.pack_rat.vars()[0]/100);let a=ts("kobold");return a>0&&(e*=1+Ei.pack_rat.vars(1)[0]/100*a),t.stats.achieve.banana&&t.stats.achieve.banana.l>=3&&(e*=1.1),e*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,Math.round(br(e))}function _r(){let e=t.tech.steel_container&&t.tech.steel_container>=3?1200:800;t.tech.steel_container&&t.tech.steel_container>=4&&(e+=t.tech.steel_container>=5?1e3:400),t.tech.steel_container&&t.tech.steel_container>=6&&(e+=t.tech.steel_container>=7?7500:1e3),t.tech.steel_container&&t.tech.steel_container>=8&&(e+=8e3),t.race.pack_rat&&(e*=1+Ei.pack_rat.vars()[0]/100);let a=ts("kobold");return a>0&&(e*=1+Ei.pack_rat.vars(1)[0]/100*a),e*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,Math.round(br(e))}function dr(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=$(`

                ${z("resource_market")}

                `);Ss($("#market")),$("#market").append(e),function(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=$("#market-qty");Ss(e),t.race.no_trade||(e.append($(`

                ${z("resource_trade_qty")}

                `)),e.append($('-+'))),Cs({el:"#market-qty",data:t.city.market,methods:{val(){t.city.market.qty<1?t.city.market.qty=1:t.city.market.qty>ur()&&(t.city.market.qty=ur())},limit:()=>ur(),less(){t.city.market.qty-=y()},more(){t.city.market.qty+=y()}}})}()}function pr(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||1!==t.settings.marketTabs))return;let e=$(`

                ${z("tab_storage")}

                `);Ss($("#resStorage")),$("#resStorage").append(e),t.resource.Crates&&t.resource.Containers&&(e.append($(``)),e.append($(``)),Cs({el:"#createHead",data:{cr:t.resource.Crates,cn:t.resource.Containers},methods:{crate(){cr()},container(){or()},buildCrateDesc:()=>ir(),buildContainerDesc:()=>sr()}}))}function ur(){return t.tech.currency>=6?1e6:t.tech.currency>=4?5e3:100}function hr(){if((t.settings.tabLoad||4===t.settings.civTabs&&2===t.settings.marketTabs)&&(Ss($("#resEjector")),t.interstellar.mass_ejector)){let e=$(`

                ${z("interstellar_mass_ejector_vol")}

                `);$("#resEjector").append(e);let a=$('');e.append(a),a.append($(`{{ total }} / {{ on | max }}{{ on | real }}${z("interstellar_mass_ejector_mass")}: {{ mass | approx }} kt/s`)),Cs({el:"#eject",data:t.interstellar.mass_ejector,filters:{max:e=>1e3*e,real:e=>s.mass_ejectorx(e,2)}})}}function mr(e,a){if((t.settings.tabLoad||4===t.settings.civTabs&&2===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==e)&&Fa[e]&&t.interstellar.mass_ejector){"magic"===t.race.universe||"Elerium"!==e&&"Infernite"!==e||(a="caution");let r=$(`

                ${t.resource[e].name}

                `);$("#resEjector").append(r);let i=$('');r.append(i),i.append($(`«`)),i.append($(`{{ e.${e} }}`)),i.append($(`»`)),i.append($(`${z("interstellar_mass_ejector_per")}: ${Fa[e]} kt`)),t.interstellar.mass_ejector.hasOwnProperty(e)||(t.interstellar.mass_ejector[e]=0),Cs({el:`#eject${e}`,data:{r:t.resource[e],e:t.interstellar.mass_ejector},methods:{ejectMore(e){let a=y();a+t.interstellar.mass_ejector.total>1e3*s.mass_ejector&&(a=1e3*s.mass_ejector-t.interstellar.mass_ejector.total),t.interstellar.mass_ejector[e]+=a,t.interstellar.mass_ejector.total+=a},ejectLess(e){let a=y();a>t.interstellar.mass_ejector[e]&&(a=t.interstellar.mass_ejector[e]),t.interstellar.mass_ejector[e]>0&&(t.interstellar.mass_ejector[e]-=a,t.interstellar.mass_ejector.total-=a)}}})}}function gr(){if((t.settings.tabLoad||4===t.settings.civTabs&&3===t.settings.marketTabs)&&(Ss($("#resCargo")),t.portal.transport)){let e=$(`

                ${z("portal_transport_supply")}

                `);$("#resCargo").append(e);let a=$('{{ used }} / {{ max }}');e.append(a),Cs({el:"#spireSupply",data:t.portal.transport.cargo})}}function vr(e,a){if((t.settings.tabLoad||4===t.settings.civTabs&&3===t.settings.marketTabs)&&Aa[e]&&t.portal.transport){let r=$(`

                ${t.resource[e].name}

                `);$("#resCargo").append(r);let i=$('');r.append(i),i.append($(`«`)),i.append($(`{{ e.${e} }}`)),i.append($(`»`));let s=x(Aa[e].out);i.append($(`${z("portal_transport_item",[`${s}`,`${Aa[e].in}`])}`)),t.portal.transport.cargo.hasOwnProperty(e)||(t.portal.transport.cargo[e]=0),Cs({el:`#supply${e}`,data:{r:t.resource[e],e:t.portal.transport.cargo},methods:{supplyMore(e){let a=y();a+t.portal.transport.cargo.used>t.portal.transport.cargo.max&&(a=t.portal.transport.cargo.max-t.portal.transport.cargo.used,t.portal.transport.cargo[e]+a<0&&(a=-t.portal.transport.cargo[e])),t.portal.transport.cargo[e]+=a,t.portal.transport.cargo.used+=a},supplyLess(e){let a=y();a>t.portal.transport.cargo[e]&&(a=t.portal.transport.cargo[e]),t.portal.transport.cargo[e]>0&&(t.portal.transport.cargo[e]-=a,t.portal.transport.cargo.used-=a)}}})}}function fr(){(t.settings.tabLoad||4===t.settings.civTabs&&4===t.settings.marketTabs)&&Ss($("#resAlchemy"))}function yr(e,a,r){if((t.settings.tabLoad||4===t.settings.civTabs&&4===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==e)&&t.tech.alchemy&&(r||t.tech.alchemy>=2)&&"Crystal"!==e){let i=$(`

                ${t.resource[e].name}

                `);$("#resAlchemy").append(i);let s=$('');i.append(s),s.append($(`«`)),s.append($(`{{ a.${e} }}`)),s.append($(`»`)),t.race.alchemy.hasOwnProperty(e)||(t.race.alchemy[e]=0),Cs({el:`#alchemy${e}`,data:{r:t.resource[e],a:t.race.alchemy},methods:{addSpell(e){let a=y();for(let r=0;r=1;r++)t.race.alchemy[e]++,t.resource.Mana.diff--},subSpell(e){let a=y();for(let r=0;r0;r++)t.race.alchemy[e]--,t.resource.Mana.diff++}}}),ls(`alchemy${e}`,(function(){let a=r&&t.tech.alchemy>=2?8*za[e]:2*za[e];return t.race.witch_hunter&&(a*=3),t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg&&(a*=t.stats.achieve.soul_sponge.mg+1),$(`
                ${z("resource_alchemy",[1,z("resource_Mana_name"),.15,z("resource_Crystal_name"),+a.toFixed(2),t.resource[e].name])}
                `)}),{elm:`#alchemy${e} h3`})}}const br=(wr={},function(e,a,r){let i=a||"a",s=[t.race.universe,t.prestige.Plasmid.count,t.prestige.AntiPlasmid.count,t.prestige.Phage.count,t.race.no_plasmid||"0",t.race.p_mutation||"0",t.race.nerfed||"0",t.genes.store||"0",t.genes.bleed||"0",t.city.temple?t.city.temple.count:"0",t.space.ziggurat?t.space.ziggurat.count:"0",t.race.cataclysm?t.race.cataclysm:"0",t.race.orbit_decayed?t.race.orbit_decayed:"0",t.genes.ancients||"0",t.civic.priest?t.civic.priest.workers:"0"].join("-");if(wr[i]||(wr[i]={}),!wr[i][s]||r){let e=1,r=!(!t.race.cataclysm&&!t.race.orbit_decayed);if(t.genes.store){let r=0;if(!a||a&&("plasmid"===a&&"antimatter"!==t.race.universe||"anti"===a&&"antimatter"===t.race.universe)){r="antimatter"===t.race.universe?t.prestige.AntiPlasmid.count:t.prestige.Plasmid.count;let e=r;t.race.no_plasmid?e=Math.min(t.race.p_mutation,r):t.race.nerfed&&(e=Math.floor(r/("antimatter"===t.race.universe?2:5))),r=Math.round(e*(t.race.nerfed?.5:1))}(!a||a&&"phage"===a)&&t.genes.store>=4&&(r+=Math.round(t.prestige.Phage.count*(t.race.nerfed?1/3:1)));let i=t.genes.store>=2?t.genes.store>=3?1250:1666:2500;if("antimatter"===t.race.universe&&(i*=2),t.genes.bleed&&t.genes.bleed>=3&&(!a||a&&("plasmid"===a&&"antimatter"===t.race.universe||"anti"===a&&"antimatter"!==t.race.universe))){let e="antimatter"===t.race.universe?t.prestige.Plasmid.count/5:t.prestige.AntiPlasmid.count/10;r+=Math.round(e*(t.race.nerfed?.5:1))}e*=1+r/i}if("standard"===t.race.universe&&(e*=Is("standard")),"antimatter"===t.race.universe&&(!r&&t.city.temple&&t.city.temple.count||r&&t.space.ziggurat&&t.space.ziggurat.count)){let a=.06;if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.0012:t.genes.ancients>=3?.001:8e-4;t.race.high_pop&&(e=ke(e)),a+=e*t.civic.priest.workers}e*=1+(r?t.space.ziggurat.count:t.city.temple.count)*a}!a&&t.pillars&&(e*=Ks()[1]),wr[i]={},wr[i][s]=e}return a?wr[i][s]*e:Math.round(wr[i][s]*e)});var wr;const kr=($r={},function(e){let a=[t.race.universe,t.prestige.Plasmid.count,t.prestige.AntiPlasmid.count,t.prestige.Phage.count,t.civic.govern.type,t.civic.professor.assigned,t.genes.bleed||"0",t.race.decayed||"0",t.race.gene_fortify||"0",t.tech.anthropology||"0",t.tech.fanaticism||"0",t.race.nerfed||"0",t.race.no_plasmid||"0",t.genes.ancients||"0",t.city.temple?t.city.temple.count:"0",t.space.ziggurat?t.space.ziggurat.count:"0",t.civic.priest?t.civic.priest.workers:"0",t.race.orbit_decayed?t.race.orbit_decayed:"0",t.race.spiritual||"0",t.tech.outpost_boost||"0",s.alien_outpost||"0"].join("-");if(!$r[a]){let e=0,r=0;if("antimatter"!==t.race.universe||t.genes.bleed){let a=t.race.no_plasmid?Math.min(t.race.p_mutation,t.prestige.Plasmid.count):t.prestige.Plasmid.count;"antimatter"===t.race.universe&&t.genes.bleed&&(a*=.025),t.race.decayed&&(a-=Math.round((t.stats.days-t.race.decayed)/(300+6*t.race.gene_fortify)));let r=250+t.prestige.Phage.count;e=a>r?+(Math.log(r+50)-3.91202).toFixed(5)/2.888+Math.log(a+1-r)/Math.LN2/250:a<0?0:+(Math.log(a+50)-3.91202).toFixed(5)/2.888,t.tech.outpost_boost&&t.race.truepath&&s.alien_outpost&&(e*=2);let i=0;if(t.race.orbit_decayed&&t.space.ziggurat?i=t.space.ziggurat.count:t.city.temple&&(i=t.city.temple.count),i>0&&!t.race.no_plasmid&&"antimatter"!==t.race.universe){let a=t.tech.anthropology&&t.tech.anthropology>=1?.08:.05;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=.002*t.civic.professor.workers;t.race.high_pop&&(e=ke(e)),a+=e}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.0015:t.genes.ancients>=3?.00125:.001;t.race.high_pop&&(e=ke(e)),a+=e*t.civic.priest.workers}t.race.spiritual&&(a*=1+Ei.spiritual.vars()[0]/100);let r=ts("seraph");r>0&&(a*=1+Ei.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1.12),t.race.ooze&&(a*=1-Ei.ooze.vars()[1]/100),t.race.orbit_decayed&&t.race.truepath&&(a*=.1),e*=1+i*a}}if("antimatter"===t.race.universe||t.genes.bleed&&t.genes.bleed>=2){let e=t.prestige.AntiPlasmid.count;"antimatter"!==t.race.universe&&t.genes.bleed&&t.genes.bleed>=2&&(e*=.25),t.race.decayed&&(e-=Math.round((t.stats.days-t.race.decayed)/(300+6*t.race.gene_fortify)));let a=250+t.prestige.Phage.count;r=e>a?+(Math.log(a+50)-3.91202).toFixed(5)/2.888+Math.log(e+1-a)/Math.LN2/250:e<0?0:+(Math.log(e+50)-3.91202).toFixed(5)/2.888,t.tech.outpost_boost&&t.race.truepath&&s.alien_outpost&&(r*=2),r/=3}t.race.nerfed&&("antimatter"===t.race.universe?(e/=2,r/=2):(e/=5,r/=5)),($r={})[a]=[(1+e)*(1+r)-1,e,r]}return e&&"raw"===e?$r[a]:e&&"plasmid"===e?$r[a][1]:e&&"antiplasmid"===e?$r[a][2]:$r[a][0]});var $r;const xr={club:{id:"tech-club",title:z("tech_club"),desc:z("tech_club_desc"),category:"agriculture",era:"primitive",reqs:{},grant:["primitive",1],cost:{Lumber:()=>t.race.kindling_kindred||t.race.smoldering?0:5,Stone:()=>t.race.kindling_kindred||t.race.smoldering?5:0},action(){return!!ri($(this)[0])&&(t.resource.Food.display=!0,!0)}},bone_tools:{id:"tech-bone_tools",title:z("tech_bone_tools"),desc:z("tech_bone_tools_desc"),category:"stone_gathering",era:"primitive",reqs:{primitive:1},grant:["primitive",2],condition:()=>!(t.race.soul_eater&&!t.race.evil),cost:{Food:()=>t.race.evil&&!t.race.smoldering?0:10,Lumber:()=>t.race.evil&&!t.race.smoldering?10:0},action(){return!!ri($(this)[0])&&(t.resource.Stone.display=!0,t.race.smoldering&&(t.resource.Chrysotile.display=!0),!0)}},wooden_tools:{id:"tech-wooden_tools",title:()=>t.race.kindling_kindred?z("tech_bone_tools"):z("tech_wooden_tools"),desc:()=>t.race.kindling_kindred?z("tech_bone_tools_desc"):z("tech_wooden_tools_desc"),category:"stone_gathering",era:"primitive",reqs:{primitive:1},grant:["primitive",2],condition:()=>!(!t.race.soul_eater||t.race.evil),cost:{Lumber:()=>10},action(){return!!ri($(this)[0])&&(t.resource.Stone.display=!0,t.race.smoldering&&(t.resource.Chrysotile.display=!0),!0)}},sundial:{id:"tech-sundial",title:()=>t.race.unfathomable?z("tech_moondial"):z("tech_sundial"),desc:()=>t.race.unfathomable?z("tech_moondial_desc"):z("tech_sundial_desc"),category:"science",era:"primitive",reqs:{primitive:2},grant:["primitive",3],cost:{Lumber:()=>8,Stone:()=>10},effect:()=>t.race.unfathomable?z("tech_moondial_effect"):z("tech_sundial_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_sundial_msg"),"info",!1,["progress"]),t.resource.Knowledge.display=!0,t.city.calendar.day++,t.race.infectious&&(t.civic.garrison.display=!0,t.settings.showCivic=!0,t.city.garrison={count:0,on:0}),t.race.banana&&!t.race.terrifying&&(t.settings.showResources=!0,t.settings.showMarket=!0,t.resource.Money.display=!0,t.city.market.active=!0,t.tech.currency=2),t.race.calm&&(t.resource.Zen.display=!0,t.city.meditation={count:0}),!0)}},housing:{id:"tech-housing",title:z("tech_housing"),desc:z("tech_housing_desc"),category:"housing",era:"civilized",reqs:{primitive:3},grant:["housing",1],cost:{Knowledge:()=>10},effect:z("tech_housing_effect"),action(){return!!ri($(this)[0])&&(t.city.basic_housing={count:0},!0)}},cottage:{id:"tech-cottage",title:()=>pi("medium"),desc:z("tech_cottage_desc"),category:"housing",era:"civilized",reqs:{housing:1,cement:1,mining:3},grant:["housing",2],cost:{Knowledge:()=>3600},effect:z("tech_cottage_effect"),action(){return!!ri($(this)[0])&&(t.city.cottage={count:0},!0)}},apartment:{id:"tech-apartment",title:()=>pi("large"),desc:()=>pi("large"),category:"housing",era:"discovery",reqs:{housing:2,high_tech:2},grant:["housing",3],cost:{Knowledge:()=>15750},effect:z("tech_apartment_effect"),action(){return!!ri($(this)[0])&&(t.city.apartment={count:0,on:0},!0)}},arcology:{id:"tech-arcology",title:z("tech_arcology"),desc:z("tech_arcology"),category:"housing",era:"dimensional",reqs:{hell_ruins:4,housing:3,high_tech:17},grant:["housing",4],cost:{Knowledge:()=>25e6},effect:()=>z("tech_arcology_effect"),action(){return!!ri($(this)[0])&&(t.portal.arcology={count:0,on:0},!0)}},steel_beams:{id:"tech-steel_beams",title:z("tech_steel_beams"),desc:z("tech_housing_cost"),category:"housing",era:"discovery",reqs:{housing:2,smelting:2},not_trait:["cataclysm","lone_survivor"],grant:["housing_reduction",1],cost:{Knowledge:()=>11250,Steel:()=>2500},effect:()=>z("tech_steel_beams_effect",[pi("small"),pi("medium")]),action(){return!!ri($(this)[0])}},mythril_beams:{id:"tech-mythril_beams",title:z("tech_mythril_beams"),desc:z("tech_housing_cost"),category:"housing",era:"early_space",reqs:{housing_reduction:1,space:3},grant:["housing_reduction",2],cost:{Knowledge:()=>175e3,Mythril:()=>1e3},effect:()=>z("tech_mythril_beams_effect",[pi("small"),pi("medium")]),action(){return!!ri($(this)[0])}},neutronium_walls:{id:"tech-neutronium_walls",title:z("tech_neutronium_walls"),desc:z("tech_housing_cost"),category:"housing",era:"deep_space",reqs:{housing_reduction:2,gas_moon:1},grant:["housing_reduction",3],cost:{Knowledge:()=>3e5,Neutronium:()=>850},effect:()=>z("tech_neutronium_walls_effect",[pi("small"),pi("medium")]),action(){return!!ri($(this)[0])}},bolognium_alloy_beams:{id:"tech-bolognium_alloy_beams",title:z("tech_bolognium_alloy_beams"),desc:z("tech_housing_cost"),category:"housing",era:"intergalactic",reqs:{housing_reduction:3,gateway:3},grant:["housing_reduction",4],cost:{Knowledge:()=>375e4,Adamantite:()=>25e5,Bolognium:()=>1e5},effect:()=>z("tech_bolognium_alloy_beams_effect",[pi("small"),pi("medium")]),action(){return!!ri($(this)[0])}},aphrodisiac:{id:"tech-aphrodisiac",title:z("tech_aphrodisiac"),desc:z("tech_aphrodisiac_desc"),category:"housing",era:"civilized",reqs:{housing:2},grant:["reproduction",1],not_trait:["artifical"],cost:{Knowledge:()=>4500},effect:z("tech_aphrodisiac_effect"),action(){return!!ri($(this)[0])}},fertility_clinic:{id:"tech-fertility_clinic",title:z("tech_fertility_clinic"),desc:z("tech_fertility_clinic"),category:"housing",era:"intergalactic",reqs:{reproduction:1,xeno:6},not_trait:["cataclysm"],grant:["reproduction",2],cost:{Knowledge:()=>45e5},effect:z("tech_fertility_clinic_effect"),action(){return!!ri($(this)[0])}},captive_housing:{id:"tech-captive_housing",title:z("tech_captive_housing"),desc:z("tech_captive_housing"),category:"eldritch",era:"civilized",reqs:{housing:1},trait:["unfathomable"],grant:["unfathomable",1],cost:{Knowledge:()=>12},effect:z("tech_captive_housing_effect"),action(){return!!ri($(this)[0])&&(t.city.captive_housing={count:0,cattle:0,cattleCatch:0,race0:0,jailrace0:0,race1:0,jailrace1:0,race2:0,jailrace2:0,raceCap:0,cattleCap:0},!0)}},torture:{id:"tech-torture",title:z("tech_torture"),desc:z("tech_torture"),category:"eldritch",era:"civilized",reqs:{unfathomable:1},trait:["unfathomable"],grant:["unfathomable",2],cost:{Knowledge:()=>25},effect:z("tech_torture_effect"),action(){return!!ri($(this)[0])&&(t.civic.torturer.display=!0,!0)}},thrall_quarters:{id:"tech-thrall_quarters",title:z("tech_thrall_quarters"),desc:z("tech_thrall_quarters"),category:"eldritch",era:"civilized",reqs:{unfathomable:2,high_tech:6},trait:["unfathomable"],grant:["unfathomable",3],cost:{Knowledge:()=>95e3,Cement:()=>5e4,Wrought_Iron:()=>12500},effect:z("tech_thrall_quarters_effect"),action(){return!!ri($(this)[0])&&(t.civic.torturer.display=!0,!0)}},psychic_energy:{id:"tech-psychic_energy",title:z("tech_psychic_energy"),desc:z("tech_psychic_energy"),category:"eldritch",era:"civilized",reqs:{housing:1},condition:()=>t.settings.showCivic,trait:["psychic"],grant:["psychic",1],cost:{Knowledge:()=>15},effect:z("tech_psychic_energy_effect"),action(){return!!ri($(this)[0])&&(t.resource.Energy.display=!0,t.settings.showPsychic=!0,t.race.psychicPowers={boost:{r:"Food"},boostTime:0},!0)},post(){cs()}},psychic_attack:{id:"tech-psychic_attack",title:z("tech_psychic_attack"),desc:z("tech_psychic_attack"),category:"eldritch",era:"civilized",reqs:{psychic:1,military:1},condition:()=>t.stats.psykill>=10,trait:["psychic"],grant:["psychic",2],cost:{Knowledge:()=>100},effect:z("tech_psychic_attack_effect"),action(){return!!ri($(this)[0])&&(t.race.psychicPowers.assaultTime=0,!0)},post(){cs()}},psychic_finance:{id:"tech-psychic_finance",title:z("tech_psychic_finance"),desc:z("tech_psychic_finance"),category:"eldritch",era:"civilized",reqs:{psychic:2,high_tech:4},trait:["psychic"],grant:["psychic",3],cost:{Knowledge:()=>65e3},effect:z("tech_psychic_finance_effect"),action(){return!!ri($(this)[0])&&(t.race.psychicPowers.cash=0,!0)},post(){cs()}},psychic_channeling:{id:"tech-psychic_channeling",title:z("tech_psychic_channeling"),desc:z("tech_psychic_channeling"),category:"eldritch",era:"deep_space",reqs:{psychic:3,high_tech:10},trait:["psychic"],grant:["psychic",4],cost:{Knowledge:()=>36e4},effect:z("tech_psychic_channeling_effect"),action(){return!!ri($(this)[0])&&(t.race.psychicPowers.channel={cash:0,assault:0,boost:0},!0)},post(){cs()}},psychic_efficiency:{id:"tech-psychic_efficiency",title:z("tech_psychic_efficiency"),desc:z("tech_psychic_efficiency"),category:"eldritch",era:"intergalactic",reqs:{psychic:4,high_tech:16},trait:["psychic"],grant:["psychic",5],cost:{Knowledge:()=>525e4},effect:z("tech_psychic_efficiency_effect"),action(){return!!ri($(this)[0])},post(){cs()}},mind_break:{id:"tech-mind_break",title:z("tech_mind_break"),desc:z("tech_mind_break"),category:"eldritch",era:"civilized",reqs:{psychic:2,high_tech:1,unfathomable:2},trait:["psychic"],grant:["psychicthrall",1],cost:{Knowledge:()=>7e3},effect:z("tech_mind_break_effect"),action(){return!!ri($(this)[0])},post(){cs()}},psychic_stun:{id:"tech-psychic_stun",title:z("tech_psychic_stun"),desc:z("tech_psychic_stun"),category:"eldritch",era:"civilized",reqs:{psychicthrall:1,high_tech:3,unfathomable:2},trait:["psychic"],grant:["psychicthrall",2],cost:{Knowledge:()=>32e3},effect:z("tech_psychic_stun_effect"),action(){return!!ri($(this)[0])},post(){cs()}},spear:{id:"tech-spear",title:z("tech_spear"),desc:z("tech_spear_desc"),category:"foraging",era:"civilized",reqs:{primitive:3,storage:1},trait:["forager"],grant:["foraging",1],cost:{Knowledge:()=>110,Stone:()=>75},effect:z("tech_spear_effect"),action(){return!!ri($(this)[0])}},bronze_spear:{id:"tech-bronze_spear",title:z("tech_bronze_spear"),desc:z("tech_bronze_spear_desc"),category:"foraging",era:"civilized",reqs:{foraging:1,mining:2},trait:["forager"],grant:["foraging",2],cost:{Knowledge:()=>525,Copper:()=>50},effect:z("tech_bronze_spear_effect"),action(){return!!ri($(this)[0])}},iron_spear:{id:"tech-iron_spear",title:z("tech_iron_spear"),desc:z("tech_iron_spear_desc"),category:"foraging",era:"civilized",reqs:{foraging:2,mining:3},trait:["forager"],grant:["foraging",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1650:3300,Iron:()=>375},effect:z("tech_bronze_spear_effect"),action(){return!!ri($(this)[0])}},dowsing_rod:{id:"tech-dowsing_rod",title:z("tech_dowsing_rod"),desc:z("tech_dowsing_rod_desc"),category:"foraging",era:"civilized",reqs:{foraging:1,mining:2},trait:["forager"],grant:["dowsing",1],cost:{Knowledge:()=>450,Lumber:()=>750},effect:z("tech_dowsing_rod_effect"),action(){return!!ri($(this)[0])}},metal_detector:{id:"tech-metal_detector",title:z("tech_metal_detector"),desc:z("tech_metal_detector_desc"),category:"foraging",era:"civilized",reqs:{dowsing:1,high_tech:4},trait:["forager"],grant:["dowsing",2],cost:{Knowledge:()=>65e3},effect:z("tech_metal_detector_effect"),action(){return!!ri($(this)[0])}},smokehouse:{id:"tech-smokehouse",title:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("city_smokehouse_easter"):z("tech_smokehouse"),desc:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("tech_smokehouse_easter_desc"):z("tech_smokehouse_desc"),category:"storage",era:"civilized",reqs:{primitive:3,storage:1},trait:["carnivore"],not_trait:["cataclysm","artifical","soul_eater","herbivore","lone_survivor"],grant:["hunting",1],cost:{Knowledge:()=>80},effect:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("tech_smokehouse_easter_effect"):z("tech_smokehouse_effect"),action(){return!!ri($(this)[0])&&(Ri("city","smokehouse","silo",{count:0}),!0)},post(){t.tech.s_lodge&&(t.tech.hunting=2)}},lodge:{id:"tech-lodge",title:z("tech_lodge"),desc:z("tech_lodge"),wiki:!!t.race.carnivore,category:"agriculture",era:"civilized",reqs:{hunting:1,housing:1,currency:1},condition:()=>!t.tech.s_lodge,grant:["hunting",2],cost:{Knowledge:()=>180},effect:z("tech_lodge_effect"),action(){return!!ri($(this)[0])&&(Ri("city","lodge","farm",{count:0}),!0)}},alt_lodge:{id:"tech-alt_lodge",title(){return this.condition()?z("tech_lodge_alt"):z("tech_lodge")},desc(){return this.condition()?z("tech_lodge_alt"):z("tech_lodge")},wiki:!t.race.carnivore,category:"housing",era:"civilized",reqs:{housing:1,currency:1},grant:["s_lodge",1],condition:()=>!!(("wendigo"===t.race.species||t.race.detritivore)&&!t.race.carnivore&&!t.race.herbivore||t.race.carnivore&&t.race.soul_eater||t.race.artifical||t.race.unfathomable),cost:{Knowledge:()=>t.race.artifical?1e4:180},effect(){return this.condition()?z("tech_lodge_effect_alt"):z("tech_lodge_effect")},action(){return!!ri($(this)[0])&&(Ri("city","lodge","farm",{count:0}),!0)}},soul_well:{id:"tech-soul_well",title:z("tech_soul_well"),desc:z("tech_soul_well"),category:"souls",era:"civilized",reqs:{primitive:3},trait:["soul_eater"],not_trait:["cataclysm","artifical","lone_survivor"],grant:["soul_eater",1],cost:{Knowledge:()=>10},effect:z("tech_soul_well_effect"),action(){return!!ri($(this)[0])&&(t.city.soul_well={count:0},!0)}},compost:{id:"tech-compost",title:z("tech_compost"),desc:z("tech_compost_desc"),category:"compost",era:"civilized",reqs:{primitive:3},trait:["detritivore"],not_trait:["cataclysm","artifical","lone_survivor"],grant:["compost",1],cost:{Knowledge:()=>10},effect:z("tech_compost_effect"),action(){return!!ri($(this)[0])&&(t.city.compost={count:0,on:0},!0)}},hot_compost:{id:"tech-hot_compost",title:z("tech_hot_compost"),desc:z("tech_hot_compost"),category:"compost",era:"civilized",reqs:{compost:1},trait:["detritivore"],grant:["compost",2],cost:{Knowledge:()=>100},effect:z("tech_hot_compost_effect"),action(){return!!ri($(this)[0])}},mulching:{id:"tech-mulching",title:z("tech_mulching"),desc:z("tech_mulching"),category:"compost",era:"civilized",reqs:{compost:2,mining:3},trait:["detritivore"],grant:["compost",3],cost:{Knowledge:()=>3200},effect:z("tech_mulching_effect"),action(){return!!ri($(this)[0])}},adv_mulching:{id:"tech-adv_mulching",title:z("tech_adv_mulching"),desc:z("tech_adv_mulching"),category:"compost",era:"discovery",reqs:{compost:3,high_tech:2},trait:["detritivore"],grant:["compost",4],cost:{Knowledge:()=>16e3},effect:z("tech_adv_mulching_effect"),action(){return!!ri($(this)[0])}},agriculture:{id:"tech-agriculture",title:z("tech_agriculture"),desc:z("tech_agriculture_desc"),category:"agriculture",era:"civilized",reqs:{primitive:3},condition:()=>!(!t.race.herbivore&&(t.race.carnivore||t.race.detritivore||t.race.soul_eater)),not_trait:["cataclysm","artifical","lone_survivor","unfathomable"],grant:["agriculture",1],cost:{Knowledge:()=>10},effect:z("tech_agriculture_effect"),action(){return!!ri($(this)[0])&&(Ri("city","farm","lodge",{count:0}),!0)}},farm_house:{id:"tech-farm_house",title:z("tech_farm_house"),desc:z("tech_farm_house_desc"),category:"housing",era:"civilized",reqs:{agriculture:1,housing:1,currency:1},grant:["farm",1],cost:{Money:()=>50,Knowledge:()=>180},effect:z("tech_farm_house_effect"),action(){return!!ri($(this)[0])}},irrigation:{id:"tech-irrigation",title:z("tech_irrigation"),desc:z("tech_irrigation_desc"),category:"agriculture",era:"civilized",reqs:{agriculture:1},grant:["agriculture",2],cost:{Knowledge:()=>55},effect:z("tech_irrigation_effect"),action(){return!!ri($(this)[0])}},silo:{id:"tech-silo",title:z("tech_silo"),desc:z("tech_silo_desc"),category:"storage",era:"civilized",reqs:{agriculture:2,storage:1},grant:["agriculture",3],cost:{Knowledge:()=>80},effect:z("tech_silo_effect"),action(){return!!ri($(this)[0])&&(Ri("city","silo","smokehouse",{count:0}),!0)}},mill:{id:"tech-mill",title:z("tech_mill"),desc:z("tech_mill_desc"),category:"agriculture",era:"civilized",reqs:{agriculture:3,mining:3},grant:["agriculture",4],cost:{Knowledge:()=>5400},effect:z("tech_mill_effect"),action(){return!!ri($(this)[0])&&(Ri("city","mill","windmill",{count:0,on:0}),!0)}},windmill:{id:"tech-windmill",title:z("tech_windmill"),desc:z("tech_windmill_desc"),category:"agriculture",era:"discovery",reqs:{agriculture:4,high_tech:1},grant:["agriculture",5],cost:{Knowledge:()=>16200},effect:z("tech_windmill_effect"),action(){return!!ri($(this)[0])}},windturbine:{id:"tech-windturbine",title:z("tech_windturbine"),desc:z("tech_windturbine"),category:"power_generation",era:"globalized",reqs:{agriculture:5,high_tech:4},grant:["agriculture",6],cost:{Knowledge:()=>66e3},effect:z("tech_windturbine_effect"),action(){return!!ri($(this)[0])}},wind_plant:{id:"tech-wind_plant",title:()=>t.race.unfathomable?z("tech_watermill"):z("tech_windmill"),desc:()=>t.race.unfathomable?z("tech_watermill"):z("tech_windmill"),category:"power_generation",era:"globalized",reqs:{high_tech:4},condition:()=>!!(t.race.carnivore||t.race.detritivore||t.race.artifical||t.race.soul_eater||t.race.unfathomable),not_trait:["herbivore"],grant:["wind_plant",1],cost:{Knowledge:()=>66e3},effect:()=>t.race.unfathomable?z("tech_watermill_effect"):z("tech_wind_plant_effect"),action(){return!!ri($(this)[0])&&(Ri("city","windmill","mill",{count:0,on:0}),!0)}},gmfood:{id:"tech-gmfood",title:z("tech_gmfood"),desc:z("tech_gmfood_desc"),category:"agriculture",era:"globalized",reqs:{agriculture:6,genetics:1},grant:["agriculture",7],cost:{Knowledge:()=>95e3},effect:z("tech_gmfood_effect"),action(){return!!ri($(this)[0])}},foundry:{id:"tech-foundry",title:z("tech_foundry"),desc:z("tech_foundry"),category:"crafting",era:"civilized",reqs:{mining:2},grant:["foundry",1],cost:{Knowledge:()=>650},effect:z("tech_foundry_effect"),action(){return!!ri($(this)[0])&&(t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},!0)}},artisans:{id:"tech-artisans",title:z("tech_artisans"),desc:z("tech_artisans"),category:"crafting",era:"civilized",reqs:{foundry:1},grant:["foundry",2],cost:{Knowledge:()=>1500},effect:z("tech_artisans_effect"),action(){return!!ri($(this)[0])}},apprentices:{id:"tech-apprentices",title:z("tech_apprentices"),desc:z("tech_apprentices"),category:"crafting",era:"civilized",reqs:{foundry:2},grant:["foundry",3],cost:{Knowledge:()=>3200},effect:z("tech_apprentices_effect"),action(){return!!ri($(this)[0])}},carpentry:{id:"tech-carpentry",title:z("tech_carpentry"),desc:z("tech_carpentry"),category:"crafting",era:"civilized",reqs:{foundry:3,saw:1},grant:["foundry",4],not_trait:["evil"],cost:{Knowledge:()=>5200},effect:z("tech_carpentry_effect"),action(){return!!ri($(this)[0])}},demonic_craftsman:{id:"tech-demonic_craftsman",title:z("tech_master_craftsman"),desc:z("tech_master_craftsman"),category:"crafting",era:"discovery",wiki:!!t.race.evil,reqs:{foundry:3},grant:["foundry",5],trait:["evil"],cost:{Knowledge:()=>12e3},effect:z("tech_master_craftsman_effect"),action(){return!!ri($(this)[0])}},master_craftsman:{id:"tech-master_craftsman",title:z("tech_master_craftsman"),desc:z("tech_master_craftsman"),category:"crafting",era:"discovery",wiki:!t.race.evil,reqs:{foundry:4},grant:["foundry",5],not_trait:["evil"],cost:{Knowledge:()=>12e3},effect:z("tech_master_craftsman_effect"),action(){return!!ri($(this)[0])}},brickworks:{id:"tech-brickworks",title:z("tech_brickworks"),desc:z("tech_brickworks"),category:"crafting",era:"discovery",reqs:{foundry:5},grant:["foundry",6],cost:{Knowledge:()=>18500},effect:z("tech_brickworks_effect"),action(){return!!ri($(this)[0])}},machinery:{id:"tech-machinery",title:z("tech_machinery"),desc:z("tech_machinery"),category:"crafting",era:"globalized",reqs:{foundry:6,high_tech:4},grant:["foundry",7],cost:{Knowledge:()=>66e3},effect:z("tech_machinery_effect"),action(){return!!ri($(this)[0])}},cnc_machine:{id:"tech-cnc_machine",title:z("tech_cnc_machine"),desc:z("tech_cnc_machine"),category:"crafting",era:"globalized",reqs:{foundry:7,high_tech:8},grant:["foundry",8],cost:{Knowledge:()=>132e3},effect:z("tech_cnc_machine_effect"),action(){return!!ri($(this)[0])}},vocational_training:{id:"tech-vocational_training",title:z("tech_vocational_training"),desc:z("tech_vocational_training"),category:"crafting",era:"industrialized",reqs:{foundry:1,high_tech:3},grant:["v_train",1],cost:{Knowledge:()=>3e4},effect:z("tech_vocational_training_effect"),action(){return!!ri($(this)[0])}},stellar_forge:{id:"tech-stellar_forge",title:z("tech_stellar_forge"),desc:z("tech_stellar_forge"),category:"crafting",era:"intergalactic",reqs:{foundry:8,high_tech:15,gateway:3,neutron:1},grant:["star_forge",1],cost:{Knowledge:()=>45e5},effect:z("tech_stellar_forge_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.stellar_forge={count:0,on:0},!0)}},stellar_smelting:{id:"tech-stellar_smelting",title:z("tech_stellar_smelting"),desc:z("tech_stellar_smelting"),category:"crafting",era:"intergalactic",reqs:{star_forge:1,xeno:4},grant:["star_forge",2],cost:{Knowledge:()=>5e6,Vitreloy:()=>1e4},effect:z("tech_stellar_smelting_effect"),action(){return!!ri($(this)[0])},post(){ki()}},assembly_line:{id:"tech-assembly_line",title:z("tech_assembly_line"),desc:z("tech_assembly_line"),category:"crafting",era:"globalized",reqs:{high_tech:4},grant:["factory",1],cost:{Knowledge:()=>72e3,Copper:()=>125e3},effect:`${z("tech_assembly_line_effect")} ${z("tech_factory_warning")}`,action(){return!!ri($(this)[0])}},automation:{id:"tech-automation",title:z("tech_automation"),desc:z("tech_automation"),category:"crafting",era:"early_space",reqs:{high_tech:8,factory:1},grant:["factory",2],cost:{Knowledge:()=>165e3},effect:`${z("tech_automation_effect")} ${z("tech_factory_warning")}`,action(){return!!ri($(this)[0])}},laser_cutters:{id:"tech-laser_cutters",title:z("tech_laser_cutters"),desc:z("tech_laser_cutters"),category:"crafting",era:"deep_space",reqs:{high_tech:9,factory:2},grant:["factory",3],cost:{Knowledge:()=>3e5,Elerium:()=>200},effect:`${z("tech_laser_cutters_effect")} ${z("tech_factory_warning")}`,action(){return!!ri($(this)[0])}},high_tech_factories:{id:"tech-high_tech_factories",title:z("tech_high_tech_factories"),desc:z("tech_high_tech_factories"),category:"crafting",era:"intergalactic",reqs:{high_tech:17,alpha:4,factory:3},grant:["factory",4],cost:{Knowledge:()=>135e5,Vitreloy:()=>5e5,Orichalcum:()=>3e5},effect:`${z("tech_high_tech_factories_effect")} ${z("tech_factory_warning")}`,action(){return!!ri($(this)[0])}},theatre:{id:"tech-theatre",title:z("tech_theatre"),desc:z("tech_theatre"),category:"entertainment",era:"civilized",reqs:{housing:1,currency:1,cement:1},grant:["theatre",1],not_trait:["joyless"],cost:{Knowledge:()=>750},effect:z("tech_theatre_effect"),action(){return!!ri($(this)[0])&&(t.city.amphitheatre={count:0},!0)}},playwright:{id:"tech-playwright",title:z("tech_playwright"),desc:z("tech_playwright"),category:"entertainment",era:"civilized",reqs:{theatre:1,science:2},grant:["theatre",2],cost:{Knowledge:()=>1080},effect:z("tech_playwright_effect"),action(){return!!ri($(this)[0])}},magic:{id:"tech-magic",title:()=>"magic"===t.race.universe?z("tech_illusionist"):z("tech_magic"),desc:()=>"magic"===t.race.universe?z("tech_illusionist"):z("tech_magic"),category:"entertainment",era:"discovery",reqs:{theatre:2,high_tech:1},grant:["theatre",3],cost:{Knowledge:()=>7920},effect:z("tech_magic_effect"),effect:()=>"magic"===t.race.universe?z("tech_illusionist_effect"):z("tech_magic_effect"),action(){return!!ri($(this)[0])}},superstars:{id:"tech-superstars",title:z("tech_superstars"),desc:z("tech_superstars"),category:"entertainment",era:"interstellar",reqs:{theatre:3,high_tech:12},grant:["superstar",1],cost:{Knowledge:()=>66e4},effect:z("tech_superstars_effect"),action(){return!!ri($(this)[0])}},radio:{id:"tech-radio",title:z("tech_radio"),desc:z("tech_radio"),category:"entertainment",era:"discovery",reqs:{theatre:3,high_tech:2},grant:["broadcast",1],cost:{Knowledge:()=>16200},effect:()=>z("tech_radio_effect",[_i()]),action(){return!!ri($(this)[0])}},tv:{id:"tech-tv",title:z("tech_tv"),desc:z("tech_tv"),category:"entertainment",era:"globalized",reqs:{broadcast:1,high_tech:4},grant:["broadcast",2],cost:{Knowledge:()=>67500},effect:()=>z("tech_tv_effect",[_i()]),action(){return!!ri($(this)[0])}},vr_center:{id:"tech-vr_center",title:z("tech_vr_center"),desc:z("tech_vr_center"),category:"entertainment",era:"interstellar",reqs:{broadcast:2,high_tech:12,stanene:1},grant:["broadcast",3],cost:{Knowledge:()=>62e4},effect:()=>z("tech_vr_center_effect"),action(){return!!ri($(this)[0])&&(t.space.vr_center={count:0,on:0},!0)}},zoo:{id:"tech-zoo",title:z("tech_zoo"),desc:z("tech_zoo"),category:"entertainment",era:"dimensional",reqs:{hell_ruins:2},grant:["zoo",1],cost:{Knowledge:()=>225e5},effect:()=>z("tech_zoo_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.zoo={count:0,on:0},!0)}},casino:{id:"tech-casino",title:z("tech_casino"),desc:z("tech_casino"),category:"entertainment",era:"globalized",reqs:{high_tech:4,currency:5},grant:["gambling",1],cost:{Knowledge:()=>95e3},effect:z("tech_casino_effect"),action(){return!!ri($(this)[0])&&(t.city.casino={count:0,on:0},t.space.spc_casino={count:0,on:0},!0)}},dazzle:{id:"tech-dazzle",title:z("tech_dazzle"),desc:z("tech_dazzle"),category:"banking",era:"globalized",reqs:{gambling:1},grant:["gambling",2],cost:{Knowledge:()=>125e3},effect:z("tech_dazzle_effect"),action(){return!!ri($(this)[0])}},casino_vault:{id:"tech-casino_vault",title:z("tech_casino_vault"),desc:z("tech_casino_vault"),category:"banking",era:"early_space",reqs:{gambling:2,space:3},grant:["gambling",3],cost:{Knowledge:()=>145e3,Iridium:()=>2500},effect:z("tech_casino_vault_effect"),action(){return!!ri($(this)[0])}},otb:{id:"tech-otb",title:z("tech_otb"),desc:z("tech_otb"),category:"banking",era:"deep_space",reqs:{gambling:3,banking:10,high_tech:10},grant:["gambling",4],cost:{Knowledge:()=>39e4},effect:z("tech_otb_effect"),action(){return!!ri($(this)[0])}},online_gambling:{id:"tech-online_gambling",title:z("tech_online_gambling"),desc:z("tech_online_gambling"),category:"banking",era:"interstellar",reqs:{gambling:4,banking:12},grant:["gambling",5],cost:{Knowledge:()=>8e5},effect:z("tech_online_gambling_effect"),action(){return!!ri($(this)[0])}},bolognium_vaults:{id:"tech-bolognium_vaults",title:z("tech_bolognium_vaults"),desc:z("tech_bolognium_vaults"),category:"banking",era:"intergalactic",reqs:{gambling:5,gateway:3},grant:["gambling",6],cost:{Knowledge:()=>39e5,Bolognium:()=>18e4},effect:z("tech_bolognium_vaults_effect"),action(){return!!ri($(this)[0])}},mining:{id:"tech-mining",title:()=>t.race.sappy?z("tech_amber"):z("tech_mining"),desc:()=>t.race.sappy?z("tech_amber"):z("tech_mining_desc"),category:"mining",era:"civilized",reqs:{primitive:3},grant:["mining",1],cost:{Knowledge:()=>45},effect:()=>t.race.sappy?z("tech_amber_effect"):z(t.race.flier?"tech_mining_effect_alt":"tech_mining_effect"),action(){return!!ri($(this)[0])&&(t.city.rock_quarry={count:0,on:0,asbestos:50},t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),!0)}},bayer_process:{id:"tech-bayer_process",title:z("tech_bayer_process"),desc:z("tech_bayer_process_desc"),category:"mining",era:"civilized",reqs:{smelting:2},grant:["alumina",1],cost:{Knowledge:()=>4500},effect:()=>t.race.sappy?z("tech_bayer_process_effect_alt"):z("tech_bayer_process_effect"),action(){return!!ri($(this)[0])&&(t.city.metal_refinery={count:0,on:0},sa(),!0)}},elysis_process:{id:"tech-elysis_process",title:z("tech_elysis_process"),desc:z("tech_elysis_process"),category:"mining",era:"interstellar",reqs:{alumina:1,stanene:1,graphene:1},path:["standard","truepath"],not_trait:["cataclysm","lone_survivor"],grant:["alumina",2],cost:{Knowledge:()=>675e3,Graphene:()=>45e3,Stanene:()=>75e3},effect:z("tech_elysis_process_effect"),action(){return!!ri($(this)[0])}},smelting:{id:"tech-smelting",title:z("tech_smelting"),desc:z("tech_smelting_desc"),category:"mining",era:"civilized",reqs:{mining:3},grant:["smelting",1],cost:{Knowledge:()=>4050},effect:z("tech_smelting_effect"),action(){return!!ri($(this)[0])&&(t.city.smelter={count:0,cap:0,Wood:0,Coal:0,Oil:0,Star:0,StarCap:0,Inferno:0,Iron:0,Steel:0,Iridium:0},!0)},post(){t.race.steelen&&(t.tech.smelting=2,Qr())}},steel:{id:"tech-steel",title:z("tech_steel"),desc:z("tech_steel_desc"),category:"mining",era:"civilized",reqs:{smelting:1,mining:4},grant:["smelting",2],condition:()=>!t.race.steelen,cost:{Knowledge:()=>4950,Steel:()=>25},effect:z("tech_steel_effect"),action(){return!!ri($(this)[0])&&(t.resource.Steel.display=!0,!0)},post(){ki(),cs()}},blast_furnace:{id:"tech-blast_furnace",title:z("tech_blast_furnace"),desc:z("tech_blast_furnace"),category:"mining",era:"discovery",reqs:{smelting:2},grant:["smelting",3],cost:{Knowledge:()=>13500,Coal:()=>2e3},effect:z("tech_blast_furnace_effect"),action(){return!!ri($(this)[0])},post(){t.race.steelen&&(t.tech.smelting=6,Qr())}},bessemer_process:{id:"tech-bessemer_process",title:z("tech_bessemer_process"),desc:z("tech_bessemer_process"),category:"mining",era:"discovery",reqs:{smelting:3},grant:["smelting",4],condition:()=>!t.race.steelen,cost:{Knowledge:()=>19800,Coal:()=>5e3},effect:z("tech_bessemer_process_effect"),action(){return!!ri($(this)[0])}},oxygen_converter:{id:"tech-oxygen_converter",title:z("tech_oxygen_converter"),desc:z("tech_oxygen_converter"),category:"mining",era:"industrialized",reqs:{smelting:4,high_tech:3},grant:["smelting",5],condition:()=>!t.race.steelen,cost:{Knowledge:()=>46800,Coal:()=>1e4},effect:z("tech_oxygen_converter_effect"),action(){return!!ri($(this)[0])}},electric_arc_furnace:{id:"tech-electric_arc_furnace",title:z("tech_electric_arc_furnace"),desc:z("tech_electric_arc_furnace"),category:"mining",era:"globalized",reqs:{smelting:5,high_tech:4},grant:["smelting",6],condition:()=>!t.race.steelen,cost:{Knowledge:()=>85500,Copper:()=>25e3},effect:z("tech_electric_arc_furnace_effect"),action(){return!!ri($(this)[0])}},hellfire_furnace:{id:"tech-hellfire_furnace",title:z("tech_hellfire_furnace"),desc:z("tech_hellfire_furnace"),category:"mining",era:"interstellar",reqs:{smelting:6,infernite:1},grant:["smelting",7],cost:{Knowledge:()=>615e3,Infernite:()=>2e3,Soul_Gem:()=>2},effect:z("tech_hellfire_furnace_effect"),action(){return!!ri($(this)[0])}},infernium_fuel:{id:"tech-infernium_fuel",title:z("tech_infernium_fuel"),desc:z("tech_infernium_fuel"),category:"mining",era:"dimensional",reqs:{smelting:7,hell_ruins:4},grant:["smelting",8],cost:{Knowledge:()=>275e5,Coal:()=>45e6,Oil:()=>5e5,Infernite:()=>75e4},effect:z("tech_infernium_fuel_effect"),action(){return!!ri($(this)[0])},post(){ki()}},iridium_smelting_perk:{id:"tech-iridium_smelting_perk",title:z("tech_iridium_smelting"),desc:z("tech_iridium_smelting"),category:"mining",era:"early_space",path:["standard"],reqs:{smelting:6,space:3},condition:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=3),grant:["irid_smelting",1],cost:{Knowledge:()=>35e4,Mythril:()=>2500},effect:z("tech_iridium_smelting_effect"),action(){return!!ri($(this)[0])}},rotary_kiln:{id:"tech-rotary_kiln",title:z("tech_rotary_kiln"),desc:z("tech_rotary_kiln"),category:"mining",era:"industrialized",reqs:{smelting:3,high_tech:3},grant:["copper",1],cost:{Knowledge:()=>57600,Coal:()=>8e3},effect:z("tech_rotary_kiln_effect"),action(){return!!ri($(this)[0])}},metal_working:{id:"tech-metal_working",title:z("tech_metal_working"),desc:z("tech_metal_working_desc"),category:"mining",era:"civilized",reqs:{mining:1},grant:["mining",2],cost:{Knowledge:()=>350},effect:z("tech_metal_working_effect"),action(){return!!ri($(this)[0])&&(t.city.mine={count:0,on:0},!0)}},iron_mining:{id:"tech-iron_mining",title:z("tech_iron_mining"),desc:z("tech_iron_mining_desc"),category:"mining",era:"civilized",reqs:{mining:2},grant:["mining",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?500:2500},effect:z("tech_iron_mining_effect"),action(){return!!ri($(this)[0])&&(t.resource.Iron.display=!0,t.city.foundry&&t.city.foundry.count>0&&(t.resource.Wrought_Iron.display=!0,sa()),!0)},post(){cs()}},coal_mining:{id:"tech-coal_mining",title:z("tech_coal_mining"),desc:z("tech_coal_mining_desc"),category:"power_generation",era:"civilized",reqs:{mining:3},grant:["mining",4],cost:{Knowledge:()=>4320},effect:z("tech_coal_mining_effect"),action(){return!!ri($(this)[0])&&(t.city.coal_mine={count:0,on:0},t.resource.Coal.display=!0,!0)},post(){cs()}},storage:{id:"tech-storage",title:z("tech_storage"),desc:z("tech_storage_desc"),category:"storage",era:"civilized",reqs:{primitive:3,currency:1},grant:["storage",1],cost:{Knowledge:()=>20},effect:z("tech_storage_effect"),action(){return!!ri($(this)[0])&&(t.city.shed={count:0},!0)}},reinforced_shed:{id:"tech-reinforced_shed",title:z("tech_reinforced_shed"),desc:z("tech_reinforced_shed_desc"),category:"storage",era:"civilized",reqs:{storage:1,cement:1,mining:3},grant:["storage",2],cost:{Money:()=>3750,Knowledge:()=>2550,Iron:()=>750,Cement:()=>500},effect:z("tech_reinforced_shed_effect"),action(){return!!ri($(this)[0])}},barns:{id:"tech-barns",title:z("tech_barns"),desc:z("tech_barns_desc"),category:"storage",era:"discovery",reqs:{storage:2,smelting:2,alumina:1},grant:["storage",3],cost:{Knowledge:()=>15750,Aluminium:()=>3e3,Steel:()=>3e3},effect:z("tech_barns_effect"),action(){return!!ri($(this)[0])},post(){ui(!1,["city-shed"])}},warehouse:{id:"tech-warehouse",title:z("tech_warehouse"),desc:z("tech_warehouse_desc"),category:"storage",era:"industrialized",reqs:{storage:3,high_tech:3,smelting:2},grant:["storage",4],cost:{Knowledge:()=>40500,Titanium:()=>3e3},effect:z("tech_warehouse_effect"),action(){return!!ri($(this)[0])},post(){ui(!1,["city-shed"])}},cameras:{id:"tech-cameras",title:z("tech_cameras"),desc:z("tech_cameras_desc"),category:"storage",era:"globalized",reqs:{storage:4,high_tech:4},grant:["storage",5],cost:{Money:()=>9e4,Knowledge:()=>65e3},effect:z("tech_cameras_effect"),action(){return!!ri($(this)[0])}},pocket_dimensions:{id:"tech-pocket_dimensions",title:z("tech_pocket_dimensions"),desc:z("tech_pocket_dimensions_desc"),category:"storage",era:"early_space",path:["standard"],reqs:{particles:1,storage:5},grant:["storage",6],cost:{Knowledge:()=>108e3},effect:z("tech_pocket_dimensions_effect"),action(){return!!ri($(this)[0])}},ai_logistics:{id:"tech-ai_logistics",title:z("tech_ai_logistics"),desc:z("tech_ai_logistics"),category:"storage",era:"interstellar",reqs:{storage:6,proxima:2,science:13},grant:["storage",7],cost:{Knowledge:()=>65e4},effect:z("tech_ai_logistics_effect"),action(){return!!ri($(this)[0])}},containerization:{id:"tech-containerization",title:z("tech_containerization"),desc:z("tech_containerization_desc"),category:"storage",era:"civilized",reqs:{cement:1,mining:1,storage:1,science:1},grant:["container",1],cost:{Knowledge:()=>2700},effect:z("tech_containerization_effect"),action(){return!!ri($(this)[0])&&(t.city.storage_yard={count:0},!0)}},reinforced_crates:{id:"tech-reinforced_crates",title:z("tech_reinforced_crates"),desc:z("tech_reinforced_crates"),category:"storage",era:"civilized",reqs:{container:1,smelting:2},grant:["container",2],cost:{Knowledge:()=>6750,Sheet_Metal:()=>100},effect(){if(t.race.smoldering||t.race.kindling_kindred||t.race.evil){let e=z("resource_Bones_name");return t.race.smoldering?e=z("resource_Chrysotile_name"):t.race.kindling_kindred&&(e=z("resource_Stone_name")),z("tech_reinforced_crates_alt_effect",[e])}return z("tech_reinforced_crates_effect")},action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},cranes:{id:"tech-cranes",title:z("tech_cranes"),desc:z("tech_cranes_desc"),category:"storage",era:"discovery",reqs:{container:2,high_tech:2},grant:["container",3],cost:{Knowledge:()=>18e3,Copper:()=>1e3,Steel:()=>2500},effect:z("tech_cranes_effect"),action(){return!!ri($(this)[0])}},titanium_crates:{id:"tech-titanium_crates",title:()=>z("tech_titanium_crates",[t.resource.Titanium.name]),desc:()=>z("tech_titanium_crates",[t.resource.Titanium.name]),category:"storage",era:"globalized",reqs:{container:3,titanium:1},grant:["container",4],cost:{Knowledge:()=>67500,Titanium:()=>1e3},effect:()=>z("tech_titanium_crates_effect",[t.resource.Titanium.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},mythril_crates:{id:"tech-mythril_crates",title:()=>z("tech_mythril_crates",[t.resource.Mythril.name]),desc:()=>z("tech_mythril_crates",[t.resource.Mythril.name]),category:"storage",era:"early_space",reqs:{container:4,space:3},grant:["container",5],cost:{Knowledge:()=>145e3,Mythril:()=>350},effect:()=>z("tech_mythril_crates_effect",[t.resource.Mythril.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},infernite_crates:{id:"tech-infernite_crates",title:()=>z("tech_crates",[t.resource.Infernite.name]),desc:()=>z("tech_infernite_crates_desc",[t.resource.Infernite.name]),category:"storage",era:"interstellar",reqs:{container:5,infernite:1},grant:["container",6],cost:{Knowledge:()=>575e3,Infernite:()=>1e3},effect:()=>z("tech_infernite_crates_effect",[t.resource.Infernite.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},graphene_crates:{id:"tech-graphene_crates",title:()=>z("tech_crates",[t.resource.Graphene.name]),desc:()=>z("tech_crates",[t.resource.Graphene.name]),category:"storage",era:"interstellar",path:["standard","truepath"],reqs:{container:6,graphene:1},grant:["container",7],cost:{Knowledge:()=>725e3,Graphene:()=>75e3},effect:()=>z("tech_graphene_crates_effect",[t.resource.Graphene.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},bolognium_crates:{id:"tech-bolognium_crates",title:()=>z("tech_crates",[t.resource.Bolognium.name]),desc:()=>z("tech_crates",[t.resource.Bolognium.name]),category:"storage",era:"intergalactic",reqs:{container:7,gateway:3},grant:["container",8],cost:{Knowledge:()=>342e4,Bolognium:()=>9e4},effect:()=>z("tech_bolognium_crates_effect",[t.resource.Bolognium.name]),action(){return!!ri($(this)[0])}},steel_containers:{id:"tech-steel_containers",title:()=>z("tech_containers",[t.resource.Steel.name]),desc:()=>z("tech_steel_containers_desc",[t.resource.Steel.name]),category:"storage",era:"discovery",reqs:{smelting:2,container:1},grant:["steel_container",1],cost:{Knowledge:()=>9e3,Steel:()=>250},effect(){if(t.race.smoldering||t.race.kindling_kindred||t.race.evil){let e=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood";return z("tech_steel_containers_alt_effect",[t.resource[e].name,t.resource.Steel.name])}return z("tech_steel_containers_effect",[t.resource.Steel.name])},action(){return!!ri($(this)[0])&&(t.city.warehouse={count:0},!0)}},gantry_crane:{id:"tech-gantry_crane",title:z("tech_gantry_crane"),desc:z("tech_gantry_crane_desc"),category:"storage",era:"discovery",reqs:{steel_container:1,high_tech:2},grant:["steel_container",2],cost:{Knowledge:()=>22500,Steel:()=>5e3},effect:z("tech_gantry_crane_effect"),action(){return!!ri($(this)[0])}},alloy_containers:{id:"tech-alloy_containers",title:()=>z("tech_containers",[t.resource.Alloy.name]),desc:()=>z("tech_alloy_containers_desc",[t.resource.Alloy.name]),category:"storage",era:"industrialized",reqs:{steel_container:2,storage:4},grant:["steel_container",3],cost:{Knowledge:()=>49500,Alloy:()=>2500},effect:()=>z("tech_alloy_containers_effect",[t.resource.Alloy.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},mythril_containers:{id:"tech-mythril_containers",title:()=>z("tech_containers",[t.resource.Mythril.name]),desc:()=>z("tech_mythril_containers_desc",[t.resource.Mythril.name]),category:"storage",era:"early_space",reqs:{steel_container:3,space:3},grant:["steel_container",4],cost:{Knowledge:()=>165e3,Mythril:()=>500},effect:()=>z("tech_mythril_containers_effect",[t.resource.Mythril.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},adamantite_containers:{id:"tech-adamantite_containers",title:()=>z("tech_containers",[t.resource.Adamantite.name]),desc:()=>z("tech_adamantite_containers_desc",[t.resource.Adamantite.name]),category:"storage",era:"interstellar",reqs:{steel_container:4,alpha:2},grant:["steel_container",5],cost:{Knowledge:()=>525e3,Adamantite:()=>17500},effect:()=>z("tech_adamantite_containers_effect",[t.resource.Adamantite.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},aerogel_containers:{id:"tech-aerogel_containers",title:()=>z("tech_containers",[t.resource.Aerogel.name]),desc:()=>z("tech_containers",[t.resource.Aerogel.name]),category:"storage",era:"interstellar",reqs:{steel_container:5,aerogel:1},grant:["steel_container",6],cost:{Knowledge:()=>775e3,Aerogel:()=>500},effect:()=>z("tech_aerogel_containers_effect",[t.resource.Aerogel.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},bolognium_containers:{id:"tech-bolognium_containers",title:()=>z("tech_containers",[t.resource.Bolognium.name]),desc:()=>z("tech_containers",[t.resource.Bolognium.name]),category:"storage",era:"intergalactic",reqs:{steel_container:6,gateway:3},grant:["steel_container",7],cost:{Knowledge:()=>35e5,Bolognium:()=>125e3},effect:()=>z("tech_bolognium_containers_effect",[t.resource.Bolognium.name]),action(){return!!ri($(this)[0])}},nanoweave_containers:{id:"tech-nanoweave_containers",title:()=>z("tech_nanoweave_containers",[t.resource.Nanoweave.name]),desc:()=>z("tech_nanoweave_containers",[t.resource.Nanoweave.name]),category:"storage",era:"intergalactic",reqs:{steel_container:7,nanoweave:1},grant:["steel_container",8],cost:{Knowledge:()=>9e6,Nanoweave:()=>5e4},effect:()=>z("tech_nanoweave_containers_effect",[t.resource.Nanoweave.name]),action(){return!!ri($(this)[0])}},evil_planning:{id:"tech-evil_planning",title:z("tech_urban_planning"),desc:z("tech_urban_planning"),category:"queues",era:"civilized",wiki:!!t.race.terrifying,reqs:{banking:2},grant:["queue",1],trait:["terrifying"],cost:{Knowledge:()=>2500},effect:z("tech_urban_planning_effect"),action(){return!!ri($(this)[0])&&(t.queue.display=!0,!0)},post(){vs()}},urban_planning:{id:"tech-urban_planning",title:z("tech_urban_planning"),desc:z("tech_urban_planning"),category:"queues",era:"civilized",wiki:!t.race.terrifying,reqs:{banking:2,currency:2},grant:["queue",1],not_trait:["terrifying"],cost:{Knowledge:()=>2500},effect:z("tech_urban_planning_effect"),action(){return!!ri($(this)[0])&&(t.queue.display=!0,t.settings.msgFilters.queue.unlocked||(t.settings.msgFilters.queue.unlocked=!0,t.settings.msgFilters.queue.vis=!0),!0)},post(){vs()}},zoning_permits:{id:"tech-zoning_permits",title:z("tech_zoning_permits"),desc:z("tech_zoning_permits"),category:"queues",era:"industrialized",reqs:{queue:1,high_tech:3},grant:["queue",2],cost:{Knowledge:()=>28e3},effect:()=>z("tech_zoning_permits_effect",[t.genes.queue&&t.genes.queue>=2?4:2]),action(){return!!ri($(this)[0])},post(){vs()}},urbanization:{id:"tech-urbanization",title:z("tech_urbanization"),desc:z("tech_urbanization"),category:"queues",era:"globalized",reqs:{queue:2,high_tech:6},grant:["queue",3],cost:{Knowledge:()=>95e3},effect:()=>z("tech_urbanization_effect",[t.genes.queue&&t.genes.queue>=2?6:3]),action(){return!!ri($(this)[0])},post(){vs()}},assistant:{id:"tech-assistant",title:z("tech_assistant"),desc:z("tech_assistant"),category:"queues",era:"civilized",reqs:{queue:1,science:4},grant:["r_queue",1],cost:{Knowledge:()=>5e3},effect:z("tech_assistant_effect"),action(){return!!ri($(this)[0])&&(t.r_queue.display=!0,t.settings.msgFilters.building_queue.unlocked||(t.settings.msgFilters.building_queue.unlocked=!0,t.settings.msgFilters.building_queue.vis=!0,t.settings.msgFilters.research_queue.unlocked=!0,t.settings.msgFilters.research_queue.vis=!0),!0)},post(){fs(),t.settings.tabLoad&&$("#resQueue").removeAttr("style")}},government:{id:"tech-government",title:z("tech_government"),desc:z("tech_government_desc"),category:"government",era:"civilized",reqs:{currency:1},grant:["govern",1],cost:{Knowledge:()=>750},effect:z("tech_government_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#govType"},"update"),Cs({el:"#foreign"},"update"),Cs({el:"#government .govTabs2"},"update"),t.settings.tabLoad&&$("#government .govTabs2").removeAttr("style")}},theocracy:{id:"tech-theocracy",title:z("govern_theocracy"),desc:z("govern_theocracy"),category:"government",era:"civilized",reqs:{govern:1,theology:2},grant:["gov_theo",1],cost:{Knowledge:()=>1200},effect:z("tech_theocracy_effect"),action(){return!!ri($(this)[0])}},republic:{id:"tech-republic",title:z("govern_republic"),desc:z("govern_republic"),category:"government",era:"discovery",reqs:{govern:1},condition:()=>!!(t.tech.trade&&t.tech.trade>=2||t.race.terrifying),grant:["govern",2],cost:{Knowledge:()=>17e3},effect:z("tech_republic_effect"),action(){return!!ri($(this)[0])}},socialist:{id:"tech-socialist",title:z("govern_socialist"),desc:z("govern_socialist"),category:"government",era:"discovery",reqs:{govern:1},condition:()=>!!(t.tech.trade&&t.tech.trade>=2||t.race.terrifying),grant:["gov_soc",1],cost:{Knowledge:()=>17e3},effect:z("tech_socialist_effect"),action(){return!!ri($(this)[0])}},corpocracy:{id:"tech-corpocracy",title:z("govern_corpocracy"),desc:z("govern_corpocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},grant:["gov_corp",1],cost:{Knowledge:()=>26e3},effect:z("tech_corpocracy_effect"),action(){return!!ri($(this)[0])}},technocracy:{id:"tech-technocracy",title:z("govern_technocracy"),desc:z("govern_technocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},grant:["govern",3],cost:{Knowledge:()=>26e3},effect:z("tech_technocracy_effect"),action(){return!!ri($(this)[0])}},federation:{id:"tech-federation",title:z("govern_federation"),desc:z("govern_federation"),category:"government",era:"early_space",reqs:{govern:2},condition:()=>t.tech.unify&&t.tech.unify>=2||ce(),grant:["gov_fed",1],cost:{Knowledge:()=>3e4},effect:z("tech_federation_effect"),action(){return!!ri($(this)[0])}},magocracy:{id:"tech-magocracy",title:z("govern_magocracy"),desc:z("govern_magocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},condition:()=>"magic"===t.race.universe,grant:["gov_mage",1],cost:{Knowledge:()=>26e3},effect:z("tech_magocracy_effect"),action(){return!!ri($(this)[0])}},governor:{id:"tech-governor",title:z("tech_governor"),desc:z("tech_governor"),category:"government",era:"civilized",reqs:{govern:1},condition:()=>!(!t.genes.governor||"anarchy"===t.civic.govern.type),grant:["governor",1],cost:{Knowledge:()=>1e3},effect:z("tech_governor_effect"),action(){return!!ri($(this)[0])&&(t.settings.showGovernor=!0,!0)},post(){L()}},spy:{id:"tech-spy",title:z("tech_spy"),desc:z("tech_spy"),category:"spies",era:"civilized",reqs:{govern:1},grant:["spy",1],cost:{Knowledge:()=>1250},effect:z("tech_spy_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#foreign"},"update")}},espionage:{id:"tech-espionage",title:z("tech_espionage"),desc:z("tech_espionage"),category:"spies",era:"discovery",reqs:{spy:1,high_tech:1},grant:["spy",2],cost:{Knowledge:()=>7500},effect:z("tech_espionage_effect"),action(){return!!ri($(this)[0])&&(t.settings.msgFilters.spy.unlocked||(t.settings.msgFilters.spy.unlocked=!0,t.settings.msgFilters.spy.vis=!0),!0)},post(){Cs({el:"#foreign"},"update")}},spy_training:{id:"tech-spy_training",title:z("tech_spy_training"),desc:z("tech_spy_training"),category:"spies",era:"discovery",reqs:{spy:2,boot_camp:1},grant:["spy",3],cost:{Knowledge:()=>1e4},effect:z("tech_spy_training_effect"),action(){return!!ri($(this)[0])}},spy_gadgets:{id:"tech-spy_gadgets",title:z("tech_spy_gadgets"),desc:z("tech_spy_gadgets"),category:"spies",era:"discovery",reqs:{spy:3,high_tech:2},grant:["spy",4],cost:{Knowledge:()=>15e3},effect:z("tech_spy_gadgets_effect"),action(){return!!ri($(this)[0])}},code_breakers:{id:"tech-code_breakers",title:z("tech_code_breakers"),desc:z("tech_code_breakers"),category:"spies",era:"industrialized",reqs:{spy:4,high_tech:4},grant:["spy",5],cost:{Knowledge:()=>55e3},effect:z("tech_code_breakers_effect"),action(){return!!ri($(this)[0])}},currency:{id:"tech-currency",title:z("tech_currency"),desc:z("tech_currency_desc"),category:"banking",era:"civilized",reqs:{housing:1},grant:["currency",1],cost:{Knowledge:()=>22,Lumber:()=>10},effect:z("tech_currency_effect"),action(){return!!ri($(this)[0])&&(t.resource.Money.display=!0,!0)}},market:{id:"tech-market",title:z("tech_market"),desc:z("tech_market_desc"),category:"banking",era:"civilized",reqs:{banking:1,govern:1},not_trait:["terrifying"],grant:["currency",2],cost:{Knowledge:()=>t.race.banana?300:1800},effect:z("tech_market_effect"),action(){return!!ri($(this)[0])&&(t.settings.showResources=!0,t.settings.showMarket=!0,!0)}},tax_rates:{id:"tech-tax_rates",title:z("tech_tax_rates"),desc:z("tech_tax_rates_desc"),category:"banking",era:"civilized",reqs:{banking:2,currency:2,queue:1},not_trait:["terrifying"],grant:["currency",3],cost:{Knowledge:()=>3375},effect:z("tech_tax_rates_effect"),action(){return!!ri($(this)[0])&&(t.civic.taxes.display=!0,!0)}},large_trades:{id:"tech-large_trades",title:z("tech_large_trades"),desc:z("tech_large_trades_desc"),category:"market",era:"civilized",reqs:{currency:3},not_trait:["terrifying"],grant:["currency",4],cost:{Knowledge:()=>6750},effect:z("tech_large_trades_effect"),action(){return!!ri($(this)[0])},post(){t.race.noble&&(t.tech.currency=5,Qr())}},corruption:{id:"tech-corruption",title:z("tech_corruption"),desc:z("tech_corruption_desc"),category:"banking",era:"industrialized",reqs:{currency:4,high_tech:3},not_trait:["terrifying","noble"],grant:["currency",5],cost:{Knowledge:()=>36e3},effect:z("tech_corruption_effect"),action(){return!!ri($(this)[0])}},massive_trades:{id:"tech-massive_trades",title:z("tech_massive_trades"),desc:z("tech_massive_trades_desc"),category:"market",era:"globalized",reqs:{currency:5,high_tech:4},not_trait:["terrifying"],grant:["currency",6],cost:{Knowledge:()=>108e3},effect:z("tech_massive_trades_effect"),action(){return!!ri($(this)[0])}},trade:{id:"tech-trade",title:z("tech_trade"),desc:z("tech_trade_desc"),category:"market",era:"civilized",reqs:{currency:2,military:1},not_trait:["terrifying"],grant:["trade",1],cost:{Knowledge:()=>t.race.banana?1200:4500},effect:z("tech_trade_effect"),action(){return!!ri($(this)[0])&&(t.city.trade={count:0},t.city.market.active=!0,!0)}},diplomacy:{id:"tech-diplomacy",title:z("tech_diplomacy"),desc:z("tech_diplomacy_desc"),category:"market",era:"discovery",reqs:{trade:1,high_tech:1},not_trait:["terrifying"],grant:["trade",2],cost:{Knowledge:()=>16200},effect:z("tech_diplomacy_effect"),action(){return!!ri($(this)[0])}},freight:{id:"tech-freight",title:z("tech_freight"),desc:z("tech_freight_desc"),category:"market",era:"industrialized",reqs:{trade:2,high_tech:3},not_trait:["terrifying"],grant:["trade",3],cost:{Knowledge:()=>37800},effect:z("tech_freight_effect"),action(){return!!ri($(this)[0])},post(){t.tech.high_tech>=6&&xe("Physics")}},wharf:{id:"tech-wharf",title:z("tech_wharf"),desc:z("tech_wharf_desc"),category:"market",era:"industrialized",reqs:{trade:1,high_tech:3,oil:1},not_trait:["thalassophobia"],grant:["wharf",1],cost:{Knowledge:()=>44e3},effect:z("tech_wharf_effect"),action(){return!!ri($(this)[0])&&(t.city.wharf={count:0},!0)}},banking:{id:"tech-banking",title:z("tech_banking"),desc:z("tech_banking_desc"),category:"banking",era:"civilized",reqs:{currency:1},grant:["banking",1],cost:{Knowledge:()=>90},effect:z("tech_banking_effect"),action(){return!!ri($(this)[0])&&(t.city.bank={count:0},!0)}},investing:{id:"tech-investing",title:z("tech_investing"),desc:z("tech_investing_desc"),category:"banking",era:"civilized",reqs:{banking:1},grant:["banking",2],cost:{Money:()=>2500,Knowledge:()=>900},effect:z("tech_investing_effect"),action(){return!!ri($(this)[0])&&(t.civic.banker.display=!0,!0)}},vault:{id:"tech-vault",title:z("tech_vault"),desc:z("tech_vault_desc"),category:"banking",era:"civilized",reqs:{banking:2,cement:1},grant:["banking",3],cost:{Money:()=>2e3,Knowledge:()=>3600,Iron:()=>500,Cement:()=>750},effect:z("tech_vault_effect"),action(){return!!ri($(this)[0])}},bonds:{id:"tech-bonds",title:z("tech_bonds"),desc:z("tech_bonds"),category:"banking",era:"civilized",reqs:{banking:3},grant:["banking",4],cost:{Money:()=>2e4,Knowledge:()=>5e3},effect:z("tech_bonds_effect"),action(){return!!ri($(this)[0])}},steel_vault:{id:"tech-steel_vault",title:z("tech_steel_vault"),desc:z("tech_steel_vault"),category:"banking",era:"civilized",reqs:{banking:4,smelting:2},grant:["banking",5],cost:{Money:()=>3e4,Knowledge:()=>6750,Steel:()=>3e3},effect:z("tech_steel_vault_effect"),action(){return!!ri($(this)[0])}},eebonds:{id:"tech-eebonds",title:z("tech_eebonds"),desc:z("tech_eebonds"),category:"banking",era:"discovery",reqs:{banking:5,high_tech:1},grant:["banking",6],cost:{Money:()=>75e3,Knowledge:()=>18e3},effect:z("tech_eebonds_effect"),action(){return!!ri($(this)[0])}},swiss_banking:{id:"tech-swiss_banking",title:Pr(),desc:Pr(),category:"banking",era:"industrialized",reqs:{banking:6},grant:["banking",7],cost:{Money:()=>125e3,Knowledge:()=>45e3},effect:z("tech_swiss_banking_effect"),action(){return!!ri($(this)[0])}},safety_deposit:{id:"tech-safety_deposit",title:z("tech_safety_deposit"),desc:z("tech_safety_deposit"),category:"banking",era:"globalized",reqs:{banking:7,high_tech:4},grant:["banking",8],cost:{Money:()=>25e4,Knowledge:()=>67500},effect:z("tech_safety_deposit_effect"),action(){return!!ri($(this)[0])}},stock_market:{id:"tech-stock_market",title:z("tech_stock_market"),desc:z("tech_stock_market"),category:"arpa",era:"globalized",reqs:{banking:8,high_tech:6},grant:["banking",9],cost:{Money:()=>325e3,Knowledge:()=>108e3},effect:z("tech_stock_market_effect"),action(){return!!ri($(this)[0])},post(){xe("Physics")}},hedge_funds:{id:"tech-hedge_funds",title:z("tech_hedge_funds"),desc:z("tech_hedge_funds"),category:"banking",era:"early_space",reqs:{banking:9,stock_exchange:1},grant:["banking",10],cost:{Money:()=>375e3,Knowledge:()=>126e3},effect:z("tech_hedge_funds_effect"),action(){return!!ri($(this)[0])}},four_oh_one:{id:"tech-four_oh_one",title:z("tech_four_oh_one"),desc:z("tech_four_oh_one"),category:"banking",era:"early_space",reqs:{banking:10},grant:["banking",11],cost:{Money:()=>425e3,Knowledge:()=>144e3},effect:z("tech_four_oh_one_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_four_oh_one_flair")},exchange:{id:"tech-exchange",title:z("tech_exchange"),desc:z("tech_exchange"),category:"banking",era:"interstellar",reqs:{banking:11,alpha:2,graphene:1},grant:["banking",12],cost:{Money:()=>1e6,Knowledge:()=>675e3},effect:z("tech_exchange_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.exchange={count:0,on:0},!0)}},foreign_investment:{id:"tech-foreign_investment",title:z("tech_foreign_investment"),desc:z("tech_foreign_investment"),category:"banking",era:"intergalactic",reqs:{banking:12,xeno:10},grant:["banking",13],cost:{Money:()=>1e8,Knowledge:()=>8e6},effect:z("tech_foreign_investment_effect"),action(){return!!ri($(this)[0])}},mythril_vault:{id:"tech-mythril_vault",title:z("tech_mythril_vault"),desc:z("tech_mythril_vault"),category:"banking",era:"early_space",reqs:{banking:5,space:3},grant:["vault",1],cost:{Money:()=>5e5,Knowledge:()=>15e4,Mythril:()=>750},effect:z("tech_mythril_vault_effect"),action(){return!!ri($(this)[0])}},neutronium_vault:{id:"tech-neutronium_vault",title:z("tech_neutronium_vault"),desc:z("tech_neutronium_vault"),category:"banking",era:"deep_space",reqs:{vault:1,gas_moon:1},grant:["vault",2],cost:{Money:()=>75e4,Knowledge:()=>28e4,Neutronium:()=>650},effect:z("tech_neutronium_vault_effect"),action(){return!!ri($(this)[0])}},adamantite_vault:{id:"tech-adamantite_vault",title:z("tech_adamantite_vault"),desc:z("tech_adamantite_vault"),category:"banking",era:"interstellar",reqs:{vault:2,alpha:2},grant:["vault",3],cost:{Money:()=>2e6,Knowledge:()=>56e4,Adamantite:()=>2e4},effect:z("tech_adamantite_vault_effect"),action(){return!!ri($(this)[0])}},graphene_vault:{id:"tech-graphene_vault",title:z("tech_graphene_vault"),desc:z("tech_graphene_vault"),category:"banking",era:"interstellar",path:["standard","truepath"],reqs:{vault:3,graphene:1},grant:["vault",4],cost:{Money:()=>3e6,Knowledge:()=>75e4,Graphene:()=>4e5},effect:z("tech_graphene_vault_effect"),action(){return!!ri($(this)[0])}},home_safe:{id:"tech-home_safe",title:z("tech_home_safe"),desc:z("tech_home_safe"),category:"banking",era:"discovery",reqs:{banking:5},grant:["home_safe",1],cost:{Money:()=>42e3,Knowledge:()=>8e3,Steel:()=>4500},effect:z("tech_home_safe_effect"),action(){return!!ri($(this)[0])}},fire_proof_safe:{id:"tech-fire_proof_safe",title:z("tech_fire_proof_safe"),desc:z("tech_fire_proof_safe"),category:"banking",era:"early_space",reqs:{home_safe:1,space:3},grant:["home_safe",2],cost:{Money:()=>25e4,Knowledge:()=>12e4,Iridium:()=>1e3},effect:z("tech_fire_proof_safe_effect"),action(){return!!ri($(this)[0])}},tamper_proof_safe:{id:"tech-tamper_proof_safe",title:z("tech_tamper_proof_safe"),desc:z("tech_tamper_proof_safe"),category:"banking",era:"interstellar",reqs:{home_safe:2,infernite:1},grant:["home_safe",3],cost:{Money:()=>25e5,Knowledge:()=>6e5,Infernite:()=>800},effect:z("tech_tamper_proof_safe_effect"),action(){return!!ri($(this)[0])}},monument:{id:"tech-monument",title:z("tech_monument"),desc:z("tech_monument"),category:"arpa",era:"globalized",reqs:{high_tech:6},grant:["monument",1],cost:{Knowledge:()=>12e4},effect:z("tech_monument_effect"),action(){return!!ri($(this)[0])&&(t.arpa.m_type=xe("Monument"),!0)},post(){xe("Physics")}},tourism:{id:"tech-tourism",title:z("tech_tourism"),desc:z("tech_tourism"),category:"banking",era:"early_space",reqs:{monuments:2,monument:1},not_trait:["cataclysm","lone_survivor"],grant:["monument",2],cost:{Knowledge:()=>15e4},effect:z("tech_tourism_effect"),action(){return!!ri($(this)[0])&&(t.city.tourist_center={count:0,on:0},!0)}},xeno_tourism:{id:"tech-xeno_tourism",title:z("tech_xeno_tourism"),desc:z("tech_xeno_tourism"),category:"banking",era:"intergalactic",reqs:{monument:2,xeno:10,monuments:10},not_trait:["cataclysm"],grant:["monument",3],cost:{Knowledge:()=>8e6},effect:z("tech_xeno_tourism_effect"),action(){return!!ri($(this)[0])}},science:{id:"tech-science",title:z("tech_science"),desc:z("tech_science_desc"),category:"science",era:"civilized",reqs:{housing:1},grant:["science",1],cost:{Knowledge:()=>65},effect:z("tech_science_effect"),action(){return!!ri($(this)[0])&&(t.city.university={count:0},!0)}},library:{id:"tech-library",title:z("tech_library"),desc:z("tech_library_desc"),category:"science",era:"civilized",reqs:{science:1,cement:1},grant:["science",2],cost:{Knowledge:()=>720},effect:z("tech_library_effect"),action(){return!!ri($(this)[0])&&(t.city.library={count:0},!0)}},thesis:{id:"tech-thesis",title:z("tech_thesis"),desc:z("tech_thesis_desc"),category:"science",era:"civilized",reqs:{science:2},grant:["science",3],cost:{Knowledge:()=>1125},effect:z("tech_thesis_effect"),action(){return!!ri($(this)[0])}},research_grant:{id:"tech-research_grant",title:z("tech_research_grant"),desc:z("tech_research_grant_desc"),category:"science",era:"civilized",reqs:{science:3},grant:["science",4],cost:{Knowledge:()=>3240},effect:z("tech_research_grant_effect"),action(){return!!ri($(this)[0])}},scientific_journal:{id:"tech-scientific_journal",title:()=>"magic"===t.race.universe?z("tech_magic_tomes"):z("tech_scientific_journal"),desc:()=>"magic"===t.race.universe?z("tech_magic_tomes_desc"):z("tech_scientific_journal_desc"),category:"science",era:"industrialized",reqs:{science:4,high_tech:3},grant:["science",5],cost:{Knowledge:()=>27e3},effect:()=>"magic"===t.race.universe?z("tech_magic_tomes_effect"):z("tech_scientific_journal_effect"),action(){return!!ri($(this)[0])}},adjunct_professor:{id:"tech-adjunct_professor",title:z("tech_adjunct_professor"),desc:z("tech_adjunct_professor"),category:"science",era:"industrialized",reqs:{science:5},grant:["science",6],cost:{Knowledge:()=>36e3},effect:()=>z("tech_adjunct_professor_effect",[_i(),t.civic.scientist?t.civic.scientist.name:z("job_scientist")]),action(){return!!ri($(this)[0])}},tesla_coil:{id:"tech-tesla_coil",title:z("tech_tesla_coil"),desc:z("tech_tesla_coil_desc"),category:"science",era:"industrialized",reqs:{science:6,high_tech:3},grant:["science",7],cost:{Knowledge:()=>51750},effect:()=>z("tech_tesla_coil_effect",[_i()]),action(){return!!ri($(this)[0])}},internet:{id:"tech-internet",title:z("tech_internet"),desc:z("tech_internet"),category:"science",era:"globalized",reqs:{science:7,high_tech:4},grant:["science",8],cost:{Knowledge:()=>61200},effect:z("tech_internet_effect"),action(){return!!ri($(this)[0])&&(t.race.toxic&&"troll"===t.race.species&&qn("godwin"),!0)}},observatory:{id:"tech-observatory",title:z("tech_observatory"),desc:z("tech_observatory"),category:"science",era:"early_space",reqs:{science:8,space:3,luna:1},grant:["science",9],cost:{Knowledge:()=>148e3},effect:z("tech_observatory_effect"),action(){return!!ri($(this)[0])&&(t.space.observatory={count:0,on:0},!0)}},world_collider:{id:"tech-world_collider",title:z("tech_world_collider"),desc:z("tech_world_collider"),category:"science",era:"deep_space",path:["standard"],reqs:{science:9,elerium:2},grant:["science",10],cost:{Knowledge:()=>35e4},effect:()=>z("tech_world_collider_effect",[Ut().dwarf]),action(){return!!ri($(this)[0])&&(t.space.world_collider={count:0},t.space.world_controller={count:0,on:0},!0)},flair:`
                ${z("tech_world_collider_flair1")}
                ${z("tech_world_collider_flair2")}
                `},laboratory:{id:"tech-laboratory",title:()=>"magic"===t.race.universe?z("tech_sanctum"):z("tech_laboratory"),desc:()=>"magic"===t.race.universe?z("tech_sanctum"):z("tech_laboratory_desc"),category:"science",era:"interstellar",reqs:{science:11,alpha:2},grant:["science",12],cost:{Knowledge:()=>5e5},effect:()=>"magic"===t.race.universe?z("tech_sanctum_effect"):z("tech_laboratory_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.laboratory={count:0,on:0},!0)},flair:()=>"magic"===t.race.universe?z("tech_sanctum_flair"):z("tech_laboratory_flair")},virtual_assistant:{id:"tech-virtual_assistant",title:z("tech_virtual_assistant"),desc:z("tech_virtual_assistant"),category:"science",era:"interstellar",reqs:{science:12,high_tech:12},grant:["science",13],cost:{Knowledge:()=>635e3},effect:()=>"magic"===t.race.universe?z("tech_virtual_assistant_magic_effect"):z("tech_virtual_assistant_effect"),action(){return!!ri($(this)[0])}},dimensional_readings:{id:"tech-dimensional_readings",title:z("tech_dimensional_readings"),desc:z("tech_dimensional_readings"),category:"science",era:"interstellar",reqs:{science:13,infernite:2},grant:["science",14],cost:{Knowledge:()=>75e4},effect:()=>z("tech_dimensional_readings_effect"),action(){return!!ri($(this)[0])}},quantum_entanglement:{id:"tech-quantum_entanglement",title:z("tech_quantum_entanglement"),desc:z("tech_quantum_entanglement"),category:"science",era:"interstellar",reqs:{science:14,neutron:1},grant:["science",15],cost:{Knowledge:()=>85e4,Neutronium:()=>7500,Soul_Gem:()=>2},effect:()=>z("tech_quantum_entanglement_effect",[2,"magic"===t.race.universe?z("tech_sanctum"):z("interstellar_laboratory_title"),_i()]),action(){return!!ri($(this)[0])}},expedition:{id:"tech-expedition",title:()=>"magic"===t.race.universe?z("tech_expedition_wiz"):z("tech_expedition"),desc:()=>"magic"===t.race.universe?z("tech_expedition_wiz"):z("tech_expedition"),category:"science",era:"intergalactic",reqs:{science:15,xeno:4},grant:["science",16],cost:{Knowledge:()=>535e4},effect:()=>"magic"===t.race.universe?z("tech_expedition_wiz_effect"):z("tech_expedition_effect"),action(){return!!ri($(this)[0])}},subspace_sensors:{id:"tech-subspace_sensors",title:z("tech_subspace_sensors"),desc:z("tech_subspace_sensors"),category:"science",era:"intergalactic",reqs:{science:16,high_tech:16},grant:["science",17],cost:{Knowledge:()=>6e6},effect:()=>z("tech_subspace_sensors_effect"),action(){return!!ri($(this)[0])}},alien_database:{id:"tech-alien_database",title:z("tech_alien_database"),desc:z("tech_alien_database"),category:"progress",era:"intergalactic",reqs:{science:17,conflict:5},grant:["science",18],cost:{Knowledge:()=>825e4},effect:()=>z("tech_alien_database_effect"),action(){return!!ri($(this)[0])}},orichalcum_capacitor:{id:"tech-orichalcum_capacitor",title:z("tech_orichalcum_capacitor"),desc:z("tech_orichalcum_capacitor"),category:"science",era:"intergalactic",reqs:{science:18,high_tech:17},grant:["science",19],cost:{Knowledge:()=>125e5,Orichalcum:()=>25e4},effect:()=>z("tech_orichalcum_capacitor_effect"),action(){return!!ri($(this)[0])}},advanced_biotech:{id:"tech-advanced_biotech",title:z("tech_advanced_biotech"),desc:z("tech_advanced_biotech"),category:"science",era:"dimensional",reqs:{science:19,high_tech:18},grant:["science",20],cost:{Knowledge:()=>255e5},effect:()=>z("tech_advanced_biotech_effect"),action(){return!!ri($(this)[0])}},codex_infinium:{id:"tech-codex_infinium",title:z("tech_codex_infinium"),desc:z("tech_codex_infinium"),category:"science",era:"dimensional",reqs:{science:20,sphinx_bribe:1},grant:["science",21],cost:{Knowledge:()=>401e5,Codex:()=>1},effect:()=>z("tech_codex_infinium_effect"),action(){return!!ri($(this)[0])&&(t.resource.Codex.display=!1,!0)}},bioscience:{id:"tech-bioscience",title:z("tech_bioscience"),desc:z("tech_bioscience_desc"),category:"science",era:"globalized",reqs:{science:8},grant:["genetics",1],cost:{Knowledge:()=>67500},effect:z("tech_bioscience_effect"),action(){return!!ri($(this)[0])&&(t.city.biolab={count:0},!0)}},genetics:{id:"tech-genetics",title:z("tech_genetics"),desc:z("tech_genetics"),category:"arpa",era:"globalized",reqs:{genetics:1,high_tech:6},grant:["genetics",2],cost:{Knowledge:()=>108e3},effect:z("tech_genetics_effect"),action(){return!!ri($(this)[0])&&(t.settings.arpa.genetics=!0,t.arpa.sequence||(t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!t.race.cataclysm&&!t.race.orbit_decayed,boost:!1,auto:!1,labs:0}),!0)},post(){xe("Genetics")}},crispr:{id:"tech-crispr",title:z("tech_crispr"),desc:z("tech_crispr"),category:"genes",era:"globalized",reqs:{genetics:3},grant:["genetics",4],cost:{Knowledge:()=>125e3},effect:()=>t.race.artifical?z("tech_crispr_effect_artifical"):z("tech_crispr_effect"),action(){return!!ri($(this)[0])&&(t.settings.arpa.crispr=!0,t.settings.arpa.arpaTabs=2,!0)},post(){xe("Genetics"),xe("Crispr")}},shotgun_sequencing:{id:"tech-shotgun_sequencing",title:z("tech_shotgun_sequencing"),desc:()=>t.race.artifical?z("tech_shotgun_sequencing_desc_artifical"):z("tech_shotgun_sequencing_desc"),category:"genes",era:"early_space",reqs:{genetics:4},grant:["genetics",5],cost:{Knowledge:()=>165e3},effect:()=>t.race.artifical?z("tech_shotgun_sequencing_effect_artifical"):z("tech_shotgun_sequencing_effect"),action(){return!!ri($(this)[0])&&(t.arpa.sequence.boost=!0,!0)},post(){xe("Genetics")}},de_novo_sequencing:{id:"tech-de_novo_sequencing",title:z("tech_de_novo_sequencing"),desc:z("tech_de_novo_sequencing"),category:"genes",era:"early_space",reqs:{genetics:5},grant:["genetics",6],cost:{Knowledge:()=>22e4},effect:()=>t.race.artifical?z("tech_de_novo_sequencing_effect_artifical"):z("tech_de_novo_sequencing_effect"),action(){return!!ri($(this)[0])&&(t.resource.Genes.display=!0,!0)},post(){xe("Genetics")}},dna_sequencer:{id:"tech-dna_sequencer",title:()=>t.race.artifical?z("tech_code_sequencer"):z("tech_dna_sequencer"),desc:()=>t.race.artifical?z("tech_code_sequencer"):z("tech_dna_sequencer"),category:"genes",era:"deep_space",reqs:{genetics:6},grant:["genetics",7],cost:{Knowledge:()=>3e5},effect:()=>t.race.artifical?z("tech_code_sequencer_effect"):z("tech_dna_sequencer_effect"),action(){return!!ri($(this)[0])&&(t.arpa.sequence.auto=!0,!0)},post(){xe("Genetics")}},rapid_sequencing:{id:"tech-rapid_sequencing",title:()=>t.race.artifical?z("tech_agile_development"):z("tech_rapid_sequencing"),desc:()=>t.race.artifical?z("tech_agile_development"):z("tech_rapid_sequencing"),category:"genes",era:"interstellar",path:["standard","truepath"],reqs:{genetics:7,high_tech:12},grant:["genetics",8],cost:{Knowledge:()=>8e5},effect:()=>t.race.artifical?z("tech_agile_development_effect"):z("tech_rapid_sequencing_effect"),action(){return!!ri($(this)[0])}},mad_science:{id:"tech-mad_science",title:()=>"magic"===t.race.universe?z("tech_sages"):z("tech_mad_science"),desc:()=>"magic"===t.race.universe?z("tech_sages"):z("tech_mad_science"),category:"science",era:"discovery",reqs:{science:2,smelting:2},grant:["high_tech",1],cost:{Money:()=>1e4,Mana:()=>"magic"===t.race.universe?50:0,Knowledge:()=>6750,Crystal:()=>"magic"===t.race.universe?1e3:0,Aluminium:()=>750},effect:()=>"magic"===t.race.universe?z("tech_sages_effect"):z("tech_mad_science_effect"),action(){return!!ri($(this)[0])&&(t.race.terrifying&&(t.civic.taxes.display=!0),t.city.wardenclyffe={count:0,on:0},!0)}},electricity:{id:"tech-electricity",title:z("tech_electricity"),desc:z("tech_electricity"),category:"power_generation",era:"discovery",reqs:{high_tech:1},grant:["high_tech",2],cost:{Knowledge:()=>13500,Copper:()=>1e3},effect:z("tech_electricity_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_electricity_msg"),"info",!1,["progress"]),t.city.power=0,t.city.powered=!0,t.city.coal_power={count:0,on:0},t.settings.showPowerGrid=!0,Mi(),!0)}},matter_replicator:{id:"tech-matter_replicator",title:()=>"antimatter"!==t.race.universe||t.race.amexplode?z("tech_replicator"):z("tech_antireplicator"),desc:()=>"antimatter"!==t.race.universe||t.race.amexplode?z("tech_replicator"):z("tech_antireplicator"),category:"special",era:"discovery",reqs:{high_tech:2},condition:()=>!!(t.stats.achieve.adam_eve&&t.stats.achieve.adam_eve.l>=5),not_trait:["lone_survivor"],grant:["replicator",1],cost:{Knowledge:()=>25e3},effect:()=>"antimatter"!==t.race.universe||t.race.amexplode?z("tech_replicator_effect_alt"):z("tech_antireplicator_effect_alt"),action(){if(ri($(this)[0])){if("antimatter"===t.race.universe&&t.race.amexplode){Pn("annihilation"),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),$("body").addClass("nuke");let a=$('
                ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),500),setTimeout((function(){a.addClass("b")}),600),setTimeout((function(){window.soft_reset()}),4e3)}else t.race.replicator={res:"Stone",pow:1};return!0}return!1},post(){L()}},industrialization:{id:"tech-industrialization",title:z("tech_industrialization"),desc:z("tech_industrialization"),category:"progress",era:"industrialized",reqs:{high_tech:2,cement:2,steel_container:1},grant:["high_tech",3],cost:{Knowledge:()=>25200},effect:z("tech_industrialization_effect"),action(){return!!ri($(this)[0])&&(t.resource.Titanium.display=!0,t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:0,Nano:0,Stanene:0},!0)},post(){cs()}},electronics:{id:"tech-electronics",title:z("tech_electronics"),desc:z("tech_electronics"),category:"progress",era:"industrialized",reqs:{high_tech:3,titanium:1},grant:["high_tech",4],cost:{Knowledge:()=>5e4},effect:z("tech_electronics_effect"),action(){return!!ri($(this)[0])&&(t.race.terrifying&&(t.tech.gambling=1,t.city.casino={count:0,on:0},t.space.spc_casino={count:0,on:0}),!0)}},fission:{id:"tech-fission",title:z("tech_fission"),desc:z("tech_fission"),category:"progress",era:"globalized",reqs:{high_tech:4,uranium:1},grant:["high_tech",5],cost:{Knowledge:()=>77400,Uranium:()=>10},effect:z("tech_fission_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_fission_msg"),"info",!1,["progress"]),t.city.fission_power={count:0,on:0},!0)}},arpa:{id:"tech-arpa",title:z("tech_arpa"),desc:z("tech_arpa_desc"),category:"arpa",era:"globalized",reqs:{high_tech:5},grant:["high_tech",6],cost:{Knowledge:()=>9e4},effect:z("tech_arpa_effect"),action(){return!!ri($(this)[0])&&(t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.race.truepath&&!t.tech.unify&&(t.tech.unify=1),!0)},post(){xe("Physics")}},rocketry:{id:"tech-rocketry",title:z("tech_rocketry"),desc:z("tech_rocketry"),category:"arpa",era:"globalized",reqs:{high_tech:6},grant:["high_tech",7],cost:{Knowledge:()=>112500,Oil:()=>t.city.ptrait.includes("dense")?8e3:6800},effect:z("tech_rocketry_effect"),action(){return!!ri($(this)[0])&&(t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,hs(z("civics_rival_unlocked",[Z(3)]),"info",!1,["progress","combat"])),!0)},post(){xe("Physics")}},robotics:{id:"tech-robotics",title:z("tech_robotics"),desc:z("tech_robotics"),category:"progress",era:"globalized",reqs:{high_tech:7},grant:["high_tech",8],cost:{Knowledge:()=>125e3},effect:z("tech_robotics_effect"),action(){return!!ri($(this)[0])}},lasers:{id:"tech-lasers",title:z("tech_lasers"),desc:z("tech_lasers_desc"),category:"progress",era:"deep_space",reqs:{high_tech:8,space:3,supercollider:1,elerium:1},grant:["high_tech",9],cost:{Knowledge:()=>28e4,Elerium:()=>100},effect:z("tech_lasers_effect"),action(){return!!ri($(this)[0])&&(t.race.cataclysm&&qn("iron_will",!1,3),!0)}},artifical_intelligence:{id:"tech-artifical_intelligence",title:z("tech_artificial_intelligence"),desc:z("tech_artificial_intelligence"),category:"progress",era:"deep_space",reqs:{high_tech:9},grant:["high_tech",10],cost:{Knowledge:()=>325e3},effect:z("tech_artificial_intelligence_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_artificial_intelligence_flair")},quantum_computing:{id:"tech-quantum_computing",title:z("tech_quantum_computing"),desc:z("tech_quantum_computing"),category:"progress",era:"deep_space",reqs:{high_tech:10,nano:1},grant:["high_tech",11],cost:{Knowledge:()=>435e3,Elerium:()=>250,Nano_Tube:()=>1e5},effect:z("tech_quantum_computing_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_quantum_computing_flair")},virtual_reality:{id:"tech-virtual_reality",title:z("tech_virtual_reality"),desc:z("tech_virtual_reality"),category:"progress",era:"interstellar",reqs:{high_tech:11,alpha:2,infernite:1,stanene:1},grant:["high_tech",12],cost:{Knowledge:()=>6e5,Stanene:()=>1250,Soul_Gem:()=>1},effect:z("tech_virtual_reality_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_virtual_reality_flair")},plasma:{id:"tech-plasma",title:z("tech_plasma"),desc:z("tech_plasma"),category:"progress",era:"interstellar",path:["standard","truepath"],reqs:{high_tech:12},grant:["high_tech",13],cost:{Knowledge:()=>755e3,Infernite:()=>t.race.truepath?0:1e3,Stanene:()=>t.race.truepath?1e6:25e4},effect:z("tech_plasma_effect"),action(){return!!ri($(this)[0])}},shields:{id:"tech-shields",title:z("tech_shields"),desc:z("tech_shields"),category:"stellar_engine",era:"interstellar",reqs:{high_tech:13},grant:["high_tech",14],cost:{Knowledge:()=>85e4},effect:z("tech_shields_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.neutron=!0,t.settings.space.blackhole=!0,!0)}},ai_core:{id:"tech-ai_core",title:z("tech_ai_core"),desc:z("tech_ai_core"),category:"ai_core",era:"interstellar",reqs:{high_tech:14,science:15,blackhole:3},grant:["high_tech",15],cost:{Knowledge:()=>15e5},effect:z("tech_ai_core_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.citadel={count:0,on:0},!0)}},metaphysics:{id:"tech-metaphysics",title:z("tech_metaphysics"),desc:z("tech_metaphysics"),category:"progress",era:"intergalactic",reqs:{high_tech:15,xeno:5},grant:["high_tech",16],cost:{Knowledge:()=>5e6,Vitreloy:()=>1e4,Soul_Gem:()=>10},effect:()=>z("tech_metaphysics_effect"),action(){return!!ri($(this)[0])}},orichalcum_analysis:{id:"tech-orichalcum_analysis",title:z("tech_orichalcum_analysis"),desc:z("tech_orichalcum_analysis"),category:"progress",era:"intergalactic",reqs:{high_tech:16,chthonian:3},grant:["high_tech",17],cost:{Knowledge:()=>122e5,Orichalcum:()=>1e5},effect:()=>z("tech_orichalcum_analysis_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_orichalcum_analysis_result"),"info",!1,["progress"]),!0)}},cybernetics:{id:"tech-cybernetics",title:z("tech_cybernetics"),desc:z("tech_cybernetics"),category:"progress",era:"dimensional",reqs:{high_tech:17,hell_ruins:4},grant:["high_tech",18],cost:{Knowledge:()=>25e6,Adamantite:()=>125e5,Stanene:()=>5e7,Vitreloy:()=>1e7},effect:()=>z("tech_cybernetics_effect"),action(){return!!ri($(this)[0])}},blood_pact:{id:"tech-blood_pact",title:z("tech_blood_pact"),desc:z("tech_blood_pact"),category:"hell_dimension",era:"dimensional",reqs:{high_tech:18,b_stone:1},grant:["b_stone",2],cost:{Knowledge:()=>52e6,Blood_Stone:()=>1},effect:()=>z("tech_blood_pact_effect"),action(){return!!ri($(this)[0])&&(t.settings.arpa.blood=!0,xe("Crispr"),!0)},post(){xe("Blood")}},purify:{id:"tech-purify",title:z("tech_purify"),desc:z("tech_purify"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:3,b_stone:2},grant:["b_stone",3],cost:{Knowledge:()=>525e5,Blood_Stone:()=>1},effect:()=>z("tech_purify_effect"),action(){return!!ri($(this)[0])}},waygate:{id:"tech-waygate",title:z("tech_waygate"),desc:z("tech_waygate"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:10,b_stone:2},grant:["waygate",1],cost:{Knowledge:()=>55e6},effect:()=>z("tech_waygate_effect"),action(){return!!ri($(this)[0])&&(t.portal.waygate={count:0,progress:0,on:0},!0)}},demonic_infusion:{id:"tech-demonic_infusion",title:z("tech_demonic_infusion"),desc:z("tech_demonic_infusion"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:10,b_stone:2,waygate:3},grant:["waygate",4],not_trait:["witch_hunter"],cost:{Species:()=>Rs(1e3),Knowledge:()=>55e6,Demonic_Essence:()=>1},effect:()=>`
                ${z("tech_demonic_infusion_effect")}
                ${z("tech_demonic_infusion_effect2",[Gs("descend").artifact])}
                `,action(){return t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),ri($(this)[0])&&R(),!1}},gate_key:{id:"tech-gate_key",title:z("tech_gate_key"),desc:z("tech_gate_key"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:1},grant:["hell_gate",2],cost:{Knowledge:()=>3e7},effect:()=>z("tech_gate_key_effect"),action(){return!!ri($(this)[0])&&(t.portal.west_tower={count:0,on:0},t.portal.east_tower={count:0,on:0},!0)}},gate_turret:{id:"tech-gate_turret",title:z("tech_gate_turret"),desc:z("tech_gate_turret"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:2},grant:["hell_gate",3],cost:{Knowledge:()=>32e6},effect:()=>z("tech_gate_turret_effect"),action(){return!!ri($(this)[0])&&(t.portal.gate_turret={count:0,on:0},!0)}},infernite_mine:{id:"tech-infernite_mine",title:z("tech_infernite_mine"),desc:z("tech_infernite_mine"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:3},grant:["hell_gate",4],cost:{Knowledge:()=>325e5},effect:()=>z("tech_infernite_mine_effect"),action(){return!!ri($(this)[0])&&(t.portal.infernite_mine={count:0,on:0},!0)}},study_corrupt_gem:{id:"tech-study_corrupt_gem",title:z("tech_study_corrupt_gem"),desc:z("tech_study_corrupt_gem"),category:"hell_dimension",era:"intergalactic",reqs:{high_tech:16,corrupt:1},grant:["corrupt",2],trait:["witch_hunter"],cost:{Mana:()=>t.race.no_plasmid?1e4:5e4,Knowledge:()=>185e5,Corrupt_Gem:()=>1},effect:()=>z("tech_study_corrupt_gem_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_study_corrupt_gem_result"),"info",!1,["progress","hell"]),t.resource.Corrupt_Gem.display=!1,!0)}},soul_binding:{id:"tech-soul_binding",title:z("tech_soul_binding"),desc:z("tech_soul_binding"),category:"hell_dimension",era:"intergalactic",reqs:{corrupt:2,science:19},grant:["forbidden",1],trait:["witch_hunter"],cost:{Knowledge:()=>19e6},effect:()=>z("tech_soul_binding_effect"),action(){return!!ri($(this)[0])}},soul_capacitor:{id:"tech-soul_capacitor",title:z("tech_soul_capacitor"),desc:z("tech_soul_capacitor"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:1},grant:["forbidden",2],trait:["witch_hunter"],cost:{Knowledge:()=>195e5},effect:()=>z("tech_soul_capacitor_effect"),action(){return!!ri($(this)[0])&&(t.portal.soul_capacitor={count:0,on:0,energy:0,ecap:0},!0)}},soul_capacitor:{id:"tech-soul_capacitor",title:z("tech_soul_capacitor"),desc:z("tech_soul_capacitor"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:1},grant:["forbidden",2],trait:["witch_hunter"],cost:{Knowledge:()=>195e5},effect:()=>z("tech_soul_capacitor_effect"),action(){return!!ri($(this)[0])&&(t.portal.soul_capacitor={count:0,on:0,energy:0,ecap:0},!0)}},absorption_chamber:{id:"tech-absorption_chamber",title:z("tech_absorption_chamber"),desc:z("tech_absorption_chamber"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:2},grant:["forbidden",3],trait:["witch_hunter"],cost:{Knowledge:()=>2e7},effect:()=>z("tech_absorption_chamber_effect"),action(){return!!ri($(this)[0])&&(t.portal.absorption_chamber={count:0},!0)}},corrupt_gem_analysis:{id:"tech-corrupt_gem_analysis",title:z("tech_corrupt_gem_analysis"),desc:z("tech_corrupt_gem_analysis"),category:"hell_dimension",era:"dimensional",reqs:{high_tech:16,corrupt:1},grant:["corrupt",2],not_trait:["witch_hunter"],cost:{Species:()=>1,Knowledge:()=>22e6,Corrupt_Gem:()=>1},effect:()=>z("tech_corrupt_gem_analysis_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_corrupt_gem_analysis_result"),"info",!1,["progress","hell"]),t.resource.Corrupt_Gem.display=!1,!0)}},hell_search:{id:"tech-hell_search",title:z("tech_hell_search"),desc:z("tech_hell_search"),category:"hell_dimension",era:"dimensional",reqs:{corrupt:2},grant:["hell_ruins",1],cost:{Knowledge:()=>221e5,Structs:()=>({portal:{sensor_drone:{s:"prtl_badlands",count:25,on:25}}})},effect:()=>z("tech_hell_search_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_hell_search_result"),"info",!1,["progress","hell"]),t.settings.portal.ruins=!0,t.settings.portal.gate=!0,t.portal.guard_post={count:0,on:0,support:0,s_max:0},!0)}},codex_infernium:{id:"tech-codex_infernium",title:z("tech_codex_infernium"),desc:z("tech_codex_infernium"),category:"progress",era:"dimensional",reqs:{hell_ruins:3},grant:["hell_ruins",4],cost:{Knowledge:()=>235e5,Codex:()=>1},effect:()=>z("tech_codex_infernium_effect"),action(){return!!ri($(this)[0])&&(t.resource.Codex.display=!1,!0)}},lake_analysis:{id:"tech-lake_analysis",title:z("tech_lake_analysis"),desc:z("tech_lake_analysis"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:2},grant:["hell_lake",3],cost:{Knowledge:()=>34e6},effect:()=>z("tech_lake_analysis_effect"),action(){return!!ri($(this)[0])}},lake_threat:{id:"tech-lake_threat",title:z("tech_lake_threat"),desc:z("tech_lake_threat"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:3},grant:["hell_lake",4],cost:{Knowledge:()=>345e5},effect:()=>z("tech_lake_threat_effect"),action(){return!!ri($(this)[0])&&(t.portal.bireme={count:0,on:0,crew:0,mil:0},hs(z("tech_lake_threat_result"),"info",!1,["progress","hell"]),!0)}},lake_transport:{id:"tech-lake_transport",title:z("tech_lake_transport"),desc:z("tech_lake_transport"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:4},grant:["hell_lake",5],cost:{Knowledge:()=>35e6},effect:()=>z("tech_lake_transport_effect"),action(){return!!ri($(this)[0])&&(t.portal.transport={count:0,on:0,crew:0,mil:0,cargo:{used:0,max:0,Crystal:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0}},!0)}},cooling_tower:{id:"tech-cooling_tower",title:z("tech_cooling_tower"),desc:z("tech_cooling_tower"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:5},grant:["hell_lake",6],cost:{Knowledge:()=>375e5},effect:()=>z("tech_cooling_tower_effect"),action(){return!!ri($(this)[0])&&(t.portal.cooling_tower={count:0,on:0},!0)}},miasma:{id:"tech-miasma",title:z("tech_miasma"),desc:z("tech_miasma"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:2},grant:["hell_spire",3],cost:{Knowledge:()=>3825e4},effect:()=>z("tech_miasma_effect"),action(){return!!ri($(this)[0])&&(t.portal.port={count:0},!0)}},incorporeal:{id:"tech-incorporeal",title:z("tech_incorporeal"),desc:z("tech_incorporeal"),category:"special",era:"intergalactic",reqs:{science:19},grant:["ascension",1],not_trait:["orbit_decay","witch_hunter"],cost:{Knowledge:()=>175e5,Phage:()=>25},effect:()=>z("tech_incorporeal_effect"),action(){return!!ri($(this)[0])}},tech_ascension:{id:"tech-tech_ascension",title:z("tech_ascension"),desc:z("tech_ascension"),category:"special",era:"intergalactic",reqs:{ascension:1},grant:["ascension",2],not_trait:["orbit_decay","witch_hunter"],cost:{Knowledge:()=>185e5,Plasmid:()=>100},effect:()=>z("tech_ascension_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.sirius=!0,!0)}},terraforming:{id:"tech-terraforming",title:z("tech_terraforming"),desc:z("tech_terraforming"),category:"special",era:"intergalactic",reqs:{science:19},path:["standard"],grant:["terraforming",1],trait:["orbit_decay"],cost:{Knowledge:()=>18e6},effect:()=>z("tech_terraforming_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.terraformer={count:0},!0)}},cement_processing:{id:"tech-cement_processing",title:z("tech_cement_processing"),desc:z("tech_cement_processing"),category:"ai_core",era:"interstellar",reqs:{high_tech:15},not_trait:["flier"],grant:["ai_core",1],cost:{Knowledge:()=>175e4},effect:z("tech_cement_processing_effect"),action(){return!!ri($(this)[0])}},adamantite_processing_flier:{id:"tech-adamantite_processing_flier",title:z("tech_adamantite_processing"),desc:z("tech_adamantite_processing"),category:"ai_core",era:"interstellar",reqs:{high_tech:15},trait:["flier"],grant:["ai_core",2],cost:{Knowledge:()=>2e6},effect:z("tech_adamantite_processing_effect"),action(){return!!ri($(this)[0])}},adamantite_processing:{id:"tech-adamantite_processing",title:z("tech_adamantite_processing"),desc:z("tech_adamantite_processing"),category:"ai_core",era:"interstellar",reqs:{ai_core:1},not_trait:["flier"],grant:["ai_core",2],cost:{Knowledge:()=>2e6},effect:z("tech_adamantite_processing_effect"),action(){return!!ri($(this)[0])}},graphene_processing:{id:"tech-graphene_processing",title:z("tech_graphene_processing"),desc:z("tech_graphene_processing"),category:"ai_core",era:"intergalactic",reqs:{ai_core:2},grant:["ai_core",3],cost:{Knowledge:()=>25e5},effect:z("tech_graphene_processing_effect"),action(){return!!ri($(this)[0])}},fusion_power:{id:"tech-fusion_power",title:z("tech_fusion_power"),desc:z("tech_fusion_power"),category:"power_generation",era:"interstellar",reqs:{ram_scoop:1},grant:["fusion",1],cost:{Knowledge:()=>64e4},effect:z("tech_fusion_power_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.fusion={count:0,on:0},!0)}},infernium_power:{id:"tech-infernium_power",title:z("tech_infernium_power"),desc:z("tech_infernium_power"),category:"power_generation",era:"dimensional",reqs:{smelting:8,hell_ruins:4},grant:["inferno_power",1],cost:{Knowledge:()=>3e7},effect:z("tech_infernium_power_effect"),action(){return!!ri($(this)[0])&&(t.portal.inferno_power={count:0,on:0},!0)}},thermomechanics:{id:"tech-thermomechanics",title:z("tech_thermomechanics"),desc:z("tech_thermomechanics_desc"),category:"crafting",era:"industrialized",reqs:{high_tech:4},grant:["alloy",1],cost:{Knowledge:()=>6e4},effect:()=>z("tech_thermomechanics_effect"),action(){return!!ri($(this)[0])}},quantum_manufacturing:{id:"tech-quantum_manufacturing",title:z("tech_quantum_manufacturing"),desc:z("tech_quantum_manufacturing"),category:"crafting",era:"deep_space",reqs:{high_tech:11},grant:["q_factory",1],cost:{Knowledge:()=>465e3},effect:z("tech_quantum_manufacturing_effect"),action(){return!!ri($(this)[0])}},worker_drone:{id:"tech-worker_drone",title:z("tech_worker_drone"),desc:z("tech_worker_drone"),category:"mining",era:"deep_space",reqs:{nano:1},grant:["drone",1],cost:{Knowledge:()=>4e5},effect:()=>z("tech_worker_drone_effect",[Ut().gas_moon]),action(){return!!ri($(this)[0])&&(t.space.drone={count:0},!0)}},uranium:{id:"tech-uranium",title:z("tech_uranium"),desc:z("tech_uranium"),category:"power_generation",era:"globalized",reqs:{high_tech:4},grant:["uranium",1],cost:{Knowledge:()=>72e3},effect:z("tech_uranium_effect"),action(){return!!ri($(this)[0])&&(t.resource.Uranium.display=!0,!0)},post(){cs()}},uranium_storage:{id:"tech-uranium_storage",title:z("tech_uranium_storage"),desc:z("tech_uranium_storage"),category:"storage",era:"globalized",reqs:{uranium:1},grant:["uranium",2],cost:{Knowledge:()=>75600,Alloy:()=>2500},effect:z("tech_uranium_storage_effect"),action(){return!!ri($(this)[0])}},uranium_ash:{id:"tech-uranium_ash",title:z("tech_uranium_ash"),desc:z("tech_uranium_ash"),category:"power_generation",era:"globalized",reqs:{uranium:2},grant:["uranium",3],cost:{Knowledge:()=>122e3},effect:z("tech_uranium_ash_effect"),action(){return!!ri($(this)[0])}},breeder_reactor:{id:"tech-breeder_reactor",title:z("tech_breeder_reactor"),desc:z("tech_breeder_reactor"),category:"power_generation",era:"early_space",reqs:{high_tech:5,uranium:3,space:3},grant:["uranium",4],cost:{Knowledge:()=>16e4,Uranium:()=>250,Iridium:()=>1e3},effect:z("tech_breeder_reactor_effect"),action(){return!!ri($(this)[0])}},mine_conveyor:{id:"tech-mine_conveyor",title:z("tech_mine_conveyor"),desc:z("tech_mine_conveyor"),category:"mining",era:"discovery",reqs:{high_tech:2},grant:["mine_conveyor",1],cost:{Knowledge:()=>16200,Copper:()=>2250,Steel:()=>1750},effect:z("tech_mine_conveyor_effect"),action(){return!!ri($(this)[0])}},oil_well:{id:"tech-oil_well",title:z("tech_oil_well"),desc:z("tech_oil_well"),category:"power_generation",era:"industrialized",reqs:{high_tech:3},grant:["oil",1],cost:{Knowledge:()=>27e3},effect:z("tech_oil_well_effect"),action(){return!!ri($(this)[0])&&(t.city.oil_well={count:0},!0)}},oil_depot:{id:"tech-oil_depot",title:z("tech_oil_depot"),desc:z("tech_oil_depot"),category:"storage",era:"industrialized",reqs:{oil:1},grant:["oil",2],cost:{Knowledge:()=>32e3},effect:z("tech_oil_depot_effect"),action(){return!!ri($(this)[0])&&(t.city.oil_depot={count:0},!0)}},oil_power:{id:"tech-oil_power",title:()=>t.race.environmentalist?z("city_wind_power"):z("tech_oil_power"),desc:()=>t.race.environmentalist?z("city_wind_power"):z("tech_oil_power"),category:"power_generation",era:"industrialized",reqs:{oil:2},grant:["oil",3],cost:{Knowledge:()=>44e3},effect:()=>t.race.environmentalist?z("tech_wind_power_effect"):z("tech_oil_power_effect"),action(){return!!ri($(this)[0])&&(t.city.oil_power={count:0,on:0},!0)}},titanium_drills:{id:"tech-titanium_drills",title:z("tech_titanium_drills"),desc:z("tech_titanium_drills"),category:"power_generation",era:"industrialized",reqs:{oil:3},grant:["oil",4],cost:{Knowledge:()=>54e3,Titanium:()=>3500},effect:z("tech_titanium_drills_effect"),action(){return!!ri($(this)[0])}},alloy_drills:{id:"tech-alloy_drills",title:z("tech_alloy_drills"),desc:z("tech_alloy_drills"),category:"power_generation",era:"globalized",reqs:{oil:4},grant:["oil",5],cost:{Knowledge:()=>77e3,Alloy:()=>1e3},effect:z("tech_alloy_drills_effect"),action(){return!!ri($(this)[0])}},fracking:{id:"tech-fracking",title:z("tech_fracking"),desc:z("tech_fracking"),category:"power_generation",era:"globalized",reqs:{oil:5,high_tech:6},grant:["oil",6],cost:{Knowledge:()=>132e3},effect:z("tech_fracking_effect"),action(){return!!ri($(this)[0])}},mythril_drills:{id:"tech-mythril_drills",title:z("tech_mythril_drills"),desc:z("tech_mythril_drills"),category:"power_generation",era:"early_space",reqs:{oil:6,space:3},grant:["oil",7],cost:{Knowledge:()=>165e3,Mythril:()=>100},effect:z("tech_mythril_drills_effect"),action(){return!!ri($(this)[0])}},mass_driver:{id:"tech-mass_driver",title:z("tech_mass_driver"),desc:z("tech_mass_driver"),category:"power_generation",era:"early_space",reqs:{oil:6,space:3},grant:["mass",1],cost:{Knowledge:()=>16e4},effect:z("tech_mass_driver_effect"),action(){return!!ri($(this)[0])&&(t.city.mass_driver={count:0,on:0},!0)}},orichalcum_driver:{id:"tech-orichalcum_driver",title:z("tech_orichalcum_driver"),desc:z("tech_orichalcum_driver"),category:"science",era:"intergalactic",reqs:{mass:1,science:19},grant:["mass",2],not_trait:["orbit_decayed"],cost:{Knowledge:()=>14e6,Orichalcum:()=>4e5},effect:()=>z("tech_orichalcum_driver_effect"),action(){return!!ri($(this)[0])&&(t.space.terraformer={count:0},!0)}},polymer:{id:"tech-polymer",title:z("tech_polymer"),desc:z("tech_polymer"),category:"crafting",era:"globalized",reqs:{genetics:1},grant:["polymer",1],cost:{Knowledge:()=>8e4,Oil:()=>5e3,Alloy:()=>450},effect:z("tech_polymer_effect"),action(){return!!ri($(this)[0])&&(t.resource.Polymer.display=!0,hs(z("tech_polymer_avail"),"info",!1,["progress"]),!0)},post(){ki(),cs()}},fluidized_bed_reactor:{id:"tech-fluidized_bed_reactor",title:z("tech_fluidized_bed_reactor"),desc:z("tech_fluidized_bed_reactor"),category:"crafting",era:"globalized",reqs:{polymer:1,high_tech:6},grant:["polymer",2],cost:{Knowledge:()=>99e3},effect:z("tech_fluidized_bed_reactor_effect"),action(){return!!ri($(this)[0])}},synthetic_fur:{id:"tech-synthetic_fur",title:()=>t.race.evil?z("tech_faux_leather"):z("tech_synthetic_fur"),desc:()=>t.race.evil?z("tech_faux_leather"):z("tech_synthetic_fur"),category:"crafting",era:"globalized",reqs:{polymer:1},grant:["synthetic_fur",1],cost:{Knowledge:()=>1e5,Polymer:()=>2500},effect:()=>t.race.evil?z("tech_faux_leather_effect"):z("tech_synthetic_fur_effect"),action(){return!!ri($(this)[0])},post(){ki()}},nanoweave:{id:"tech-nanoweave",title:z("tech_nanoweave"),desc:z("tech_nanoweave"),category:"crafting",era:"intergalactic",reqs:{science:18},grant:["nanoweave",1],cost:{Knowledge:()=>85e5,Nano_Tube:()=>5e6,Vitreloy:()=>25e4},effect:z("tech_nanoweave_effect"),action(){return!!ri($(this)[0])&&(t.resource.Nanoweave.display=!0,hs(z("tech_nanoweave_avail"),"info",!1,["progress"]),sa(),!0)},post(){cs()}},stanene:{id:"tech-stanene",title:z("tech_stanene"),desc:z("tech_stanene"),category:"crafting",era:"interstellar",reqs:{infernite:1},grant:["stanene",1],cost:{Knowledge:()=>59e4,Aluminium:()=>5e5,Infernite:()=>1e3},effect:z("tech_stanene_effect"),action(){return!!ri($(this)[0])&&(t.resource.Stanene.display=!0,hs(z("tech_stanene_avail"),"info",!1,["progress"]),!0)},post(){ki(),cs()}},nano_tubes:{id:"tech-nano_tubes",title:z("tech_nano_tubes"),desc:z("tech_nano_tubes"),category:"crafting",era:"deep_space",reqs:{high_tech:10},grant:["nano",1],cost:{Knowledge:()=>375e3,Coal:()=>1e5,Neutronium:()=>1e3},effect:z("tech_nano_tubes_effect"),action(){return!!ri($(this)[0])&&(t.resource.Nano_Tube.display=!0,hs(z("tech_nano_tubes_msg"),"info",!1,["progress"]),!0)},post(){ki(),cs()}},scarletite:{id:"tech-scarletite",title:z("tech_scarletite"),desc:z("tech_scarletite"),category:"crafting",era:"dimensional",reqs:{hell_ruins:4},grant:["scarletite",1],cost:{Knowledge:()=>2675e4,Iron:()=>1e8,Adamantite:()=>15e6,Orichalcum:()=>8e6},effect:z("tech_scarletite_effect"),action(){if(ri($(this)[0])){if(t.resource.Scarletite.display=!0,t.portal.hell_forge={count:0,on:0},hs(z("tech_scarletite_avail"),"info",!1,["progress"]),sa(),"micro"===t.race.universe||t.pillars[t.race.species]){let e=Mn();e>t.pillars[t.race.species]&&(t.pillars[t.race.species]=e),t.tech.pillars=2}else t.tech.fusable=1;return!0}return!1},post(){cs()}},pillars:{id:"tech-pillars",title:z("tech_pillars"),desc:z("tech_pillars"),category:"hell_dimension",era:"dimensional",reqs:{scarletite:1,fusable:1},grant:["pillars",1],cost:{Knowledge:()=>3e7},effect:z("tech_pillars_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_pillars_msg",[Ki[t.race.species].entity]),"info",!1,["progress","hell"]),!0)}},reclaimer:{id:"tech-reclaimer",title:z("tech_reclaimer"),desc:z("tech_reclaimer_desc"),category:"reclaimer",era:"civilized",reqs:{primitive:3},grant:["reclaimer",1],trait:["evil"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>45,Lumber:()=>20,Stone:()=>20},effect:z("tech_reclaimer_effect"),action(){return!!ri($(this)[0])&&(t.civic.lumberjack.name=z("job_reclaimer"),t.civic.lumberjack.display=!0,t.city.graveyard={count:0},!0)}},shovel:{id:"tech-shovel",title:z("tech_shovel"),desc:z("tech_shovel"),category:"reclaimer",era:"civilized",reqs:{reclaimer:1,mining:2},grant:["reclaimer",2],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>540,Copper:()=>25},effect:z("tech_shovel_effect"),action(){return!!ri($(this)[0])}},iron_shovel:{id:"tech-iron_shovel",title:z("tech_iron_shovel"),desc:z("tech_iron_shovel"),category:"reclaimer",era:"civilized",reqs:{reclaimer:2,mining:3},grant:["reclaimer",3],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>2700,Iron:()=>250},effect:z("tech_iron_shovel_effect"),action(){return!!ri($(this)[0])}},steel_shovel:{id:"tech-steel_shovel",title:z("tech_steel_shovel"),desc:z("tech_steel_shovel"),category:"reclaimer",era:"discovery",reqs:{reclaimer:3,smelting:2},grant:["reclaimer",4],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>9e3,Steel:()=>250},effect:z("tech_steel_shovel_effect"),action(){return!!ri($(this)[0])}},titanium_shovel:{id:"tech-titanium_shovel",title:z("tech_titanium_shovel"),desc:z("tech_titanium_shovel"),category:"reclaimer",era:"industrialized",reqs:{reclaimer:4,high_tech:3},grant:["reclaimer",5],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>38e3,Titanium:()=>350},effect:z("tech_titanium_shovel_effect"),action(){return!!ri($(this)[0])}},alloy_shovel:{id:"tech-alloy_shovel",title:z("tech_alloy_shovel"),desc:z("tech_alloy_shovel"),category:"reclaimer",era:"globalized",reqs:{reclaimer:5,high_tech:4},grant:["reclaimer",6],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>67500,Alloy:()=>750},effect:z("tech_alloy_shovel_effect"),action(){return!!ri($(this)[0])}},mythril_shovel:{id:"tech-mythril_shovel",title:z("tech_mythril_shovel"),desc:z("tech_mythril_shovel"),category:"reclaimer",era:"early_space",reqs:{reclaimer:6,space:3},grant:["reclaimer",7],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>16e4,Mythril:()=>880},effect:z("tech_mythril_shovel_effect"),action(){return!!ri($(this)[0])}},adamantite_shovel:{id:"tech-adamantite_shovel",title:z("tech_adamantite_shovel"),desc:z("tech_adamantite_shovel"),category:"reclaimer",era:"interstellar",reqs:{reclaimer:7,alpha:2},grant:["reclaimer",8],trait:["evil"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>525e3,Adamantite:()=>1e4},effect:z("tech_adamantite_shovel_effect"),action(){return!!ri($(this)[0])}},stone_axe:{id:"tech-stone_axe",title:()=>z("tech_stone_axe"),desc:()=>z("tech_stone_axe_desc"),category:"lumber_gathering",reqs:{primitive:3},era:"civilized",grant:["axe",1],not_trait:["kindling_kindred","smoldering","evil","cataclysm"],cost:{Knowledge:()=>45,Lumber:()=>20,Stone:()=>20},effect:()=>t.race.living_tool?z("tech_basic_livingtools"):t.race.sappy?z("tech_amber_axe_effect"):z("tech_stone_axe_effect"),action(){return!!ri($(this)[0])&&(t.civic.lumberjack.display=!0,t.city.lumber_yard={count:0},!0)}},copper_axes:{id:"tech-copper_axes",title:z("tech_copper_axes"),desc:z("tech_copper_axes_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:1,mining:2},not_trait:["living_tool"],grant:["axe",2],cost:{Knowledge:()=>540,Copper:()=>25},effect:z("tech_copper_axes_effect"),action(){return!!ri($(this)[0])}},iron_saw:{id:"tech-iron_saw",title:z("tech_iron_saw"),desc:z("tech_iron_saw_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:1,mining:3},grant:["saw",1],not_trait:["lone_survivor"],cost:{Knowledge:()=>3375,Iron:()=>400},effect:z("tech_iron_saw_effect"),action(){return!!ri($(this)[0])&&(t.city.sawmill={count:0,on:0},!0)}},steel_saw:{id:"tech-steel_saw",title:z("tech_steel_saw"),desc:z("tech_steel_saw_desc"),category:"lumber_gathering",era:"discovery",reqs:{smelting:2,saw:1},grant:["saw",2],cost:{Knowledge:()=>10800,Steel:()=>400},effect:z("tech_steel_saw_effect"),action(){return!!ri($(this)[0])}},iron_axes:{id:"tech-iron_axes",title:z("tech_iron_axes"),desc:z("tech_iron_axes_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:2,mining:3},not_trait:["living_tool"],grant:["axe",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1350:2700,Iron:()=>250},effect:z("tech_iron_axes_effect"),action(){return!!ri($(this)[0])}},steel_axes:{id:"tech-steel_axes",title:z("tech_steel_axes"),desc:z("tech_steel_axes_desc"),category:"lumber_gathering",era:"discovery",reqs:{axe:3,smelting:2},not_trait:["living_tool"],grant:["axe",4],cost:{Knowledge:()=>9e3,Steel:()=>250},effect:z("tech_steel_axes_effect"),action(){return!!ri($(this)[0])}},titanium_axes:{id:"tech-titanium_axes",title:z("tech_titanium_axes"),desc:z("tech_titanium_axes_desc"),category:"lumber_gathering",era:"industrialized",reqs:{axe:4,high_tech:3},not_trait:["living_tool"],grant:["axe",5],cost:{Knowledge:()=>38e3,Titanium:()=>350},effect:z("tech_titanium_axes_effect"),action(){return!!ri($(this)[0])}},chainsaws:{id:"tech-chainsaws",title:z("tech_chainsaws"),desc:z("tech_chainsaws_desc"),category:"lumber_gathering",era:"interstellar",reqs:{axe:5,alpha:2},not_trait:["living_tool"],grant:["axe",6],cost:{Knowledge:()=>56e4,Oil:()=>1e4,Adamantite:()=>2e3},effect:z("tech_chainsaws_effect"),action(){return!!ri($(this)[0])},flair:()=>`
                ${z("tech_chainsaws_flair1")}
                ${z("tech_chainsaws_flair2")}
                `},copper_sledgehammer:{id:"tech-copper_sledgehammer",title:z("tech_copper_sledgehammer"),desc:z("tech_copper_sledgehammer_desc"),category:"stone_gathering",era:"civilized",reqs:{mining:2},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",1],cost:{Knowledge:()=>540,Copper:()=>25},effect:z("tech_copper_sledgehammer_effect"),action(){return!!ri($(this)[0])}},iron_sledgehammer:{id:"tech-iron_sledgehammer",title:z("tech_iron_sledgehammer"),desc:z("tech_iron_sledgehammer_desc"),category:"stone_gathering",era:"civilized",reqs:{hammer:1,mining:3},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1350:2700,Iron:()=>250},effect:z("tech_iron_sledgehammer_effect"),action(){return!!ri($(this)[0])}},steel_sledgehammer:{id:"tech-steel_sledgehammer",title:z("tech_steel_sledgehammer"),desc:z("tech_steel_sledgehammer_desc"),category:"stone_gathering",era:"discovery",reqs:{hammer:2,smelting:2},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",3],cost:{Knowledge:()=>7200,Steel:()=>250},effect:z("tech_steel_sledgehammer_effect"),action(){return!!ri($(this)[0])}},titanium_sledgehammer:{id:"tech-titanium_sledgehammer",title:z("tech_titanium_sledgehammer"),desc:z("tech_titanium_sledgehammer_desc"),category:"stone_gathering",era:"industrialized",reqs:{hammer:3,high_tech:3},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",4],cost:{Knowledge:()=>4e4,Titanium:()=>400},effect:z("tech_titanium_sledgehammer_effect"),action(){return!!ri($(this)[0])}},copper_pickaxe:{id:"tech-copper_pickaxe",title:z("tech_copper_pickaxe"),desc:z("tech_copper_pickaxe_desc"),category:"mining",era:"civilized",reqs:{mining:2},not_trait:["cataclysm","living_tool"],grant:["pickaxe",1],cost:{Knowledge:()=>675,Copper:()=>25},effect:z("tech_copper_pickaxe_effect"),action(){return!!ri($(this)[0])}},iron_pickaxe:{id:"tech-iron_pickaxe",title:z("tech_iron_pickaxe"),desc:z("tech_iron_pickaxe_desc"),category:"mining",era:"civilized",reqs:{pickaxe:1,mining:3},not_trait:["cataclysm","living_tool"],grant:["pickaxe",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1600:3200,Iron:()=>250},effect:z("tech_iron_pickaxe_effect"),action(){return!!ri($(this)[0])}},steel_pickaxe:{id:"tech-steel_pickaxe",title:z("tech_steel_pickaxe"),desc:z("tech_steel_pickaxe_desc"),category:"mining",era:"discovery",reqs:{pickaxe:2,smelting:2},not_trait:["living_tool"],grant:["pickaxe",3],cost:{Knowledge:()=>9e3,Steel:()=>250},effect:z("tech_steel_pickaxe_effect"),action(){return!!ri($(this)[0])}},jackhammer:{id:"tech-jackhammer",title:z("tech_jackhammer"),desc:z("tech_jackhammer_desc"),category:"mining",era:"discovery",reqs:{pickaxe:3,high_tech:2},not_trait:["living_tool"],grant:["pickaxe",4],cost:{Knowledge:()=>22500,Copper:()=>5e3},effect:z("tech_jackhammer_effect"),action(){return!!ri($(this)[0])}},jackhammer_mk2:{id:"tech-jackhammer_mk2",title:z("tech_jackhammer_mk2"),desc:z("tech_jackhammer_mk2"),category:"mining",era:"globalized",reqs:{pickaxe:4,high_tech:4},not_trait:["living_tool"],grant:["pickaxe",5],cost:{Knowledge:()=>67500,Titanium:()=>2e3,Alloy:()=>500},effect:z("tech_jackhammer_mk2_effect"),action(){return!!ri($(this)[0])}},adamantite_hammer:{id:"tech-adamantite_hammer",title:z("tech_adamantite_hammer"),desc:z("tech_adamantite_hammer"),category:"mining",era:"interstellar",reqs:{pickaxe:5,alpha:2},not_trait:["living_tool"],grant:["pickaxe",6],cost:{Knowledge:()=>535e3,Adamantite:()=>12500},effect:z("tech_adamantite_hammer_effect"),action(){return!!ri($(this)[0])}},copper_hoe:{id:"tech-copper_hoe",title:z("tech_copper_hoe"),desc:z("tech_copper_hoe_desc"),category:"agriculture",era:"civilized",reqs:{mining:2,agriculture:1},not_trait:["cataclysm","living_tool"],grant:["hoe",1],cost:{Knowledge:()=>720,Copper:()=>50},effect:z("tech_copper_hoe_effect"),action(){return!!ri($(this)[0])}},iron_hoe:{id:"tech-iron_hoe",title:z("tech_iron_hoe"),desc:z("tech_iron_hoe_desc"),category:"agriculture",era:"civilized",reqs:{hoe:1,mining:3,agriculture:1},not_trait:["living_tool"],grant:["hoe",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1800:3600,Iron:()=>500},effect:z("tech_iron_hoe_effect"),action(){return!!ri($(this)[0])}},steel_hoe:{id:"tech-steel_hoe",title:z("tech_steel_hoe"),desc:z("tech_steel_hoe_desc"),category:"agriculture",era:"discovery",reqs:{hoe:2,smelting:2,agriculture:1},not_trait:["living_tool"],grant:["hoe",3],cost:{Knowledge:()=>12600,Steel:()=>500},effect:z("tech_steel_hoe_effect"),action(){return!!ri($(this)[0])}},titanium_hoe:{id:"tech-titanium_hoe",title:z("tech_titanium_hoe"),desc:z("tech_titanium_hoe_desc"),category:"agriculture",era:"industrialized",reqs:{hoe:3,high_tech:3,agriculture:1},not_trait:["living_tool"],grant:["hoe",4],cost:{Knowledge:()=>44e3,Titanium:()=>500},effect:z("tech_titanium_hoe_effect"),action(){return!!ri($(this)[0])}},adamantite_hoe:{id:"tech-adamantite_hoe",title:z("tech_adamantite_hoe"),desc:z("tech_adamantite_hoe_desc"),category:"agriculture",era:"interstellar",reqs:{hoe:4,alpha:2},not_trait:["living_tool"],grant:["hoe",5],cost:{Knowledge:()=>53e4,Adamantite:()=>1e3},effect:z("tech_adamantite_hoe_effect"),action(){return!!ri($(this)[0])}},cyber_limbs:{id:"tech-cyber_limbs",title:z("tech_cyber_limbs"),desc:z("tech_cyber_limbs"),category:"mining",era:"dimensional",reqs:{high_tech:18},grant:["cyber_worker",1],cost:{Knowledge:()=>27e6},effect:z("tech_cyber_limbs_effect"),action(){return!!ri($(this)[0])}},slave_pens:{id:"tech-slave_pens",title:z("tech_slave_pens"),desc:z("tech_slave_pens"),category:"slaves",era:"civilized",reqs:{military:1,mining:1},not_trait:["cataclysm","lone_survivor"],grant:["slaves",1],trait:["slaver"],cost:{Knowledge:()=>150},effect:z("tech_slave_pens_effect"),action(){return!!ri($(this)[0])&&(t.city.slave_pen={count:0,slaves:0},!0)}},slave_market:{id:"tech-slave_market",title:z("tech_slave_market"),desc:z("tech_slave_market"),category:"slaves",era:"discovery",reqs:{slaves:1,high_tech:1},grant:["slaves",2],trait:["slaver"],cost:{Knowledge:()=>8e3},effect:z("tech_slave_market_effect"),action(){return!!ri($(this)[0])}},ceremonial_dagger:{id:"tech-ceremonial_dagger",title:z("tech_ceremonial_dagger"),desc:z("tech_ceremonial_dagger"),category:"sacrifice",era:"civilized",reqs:{mining:1},grant:["sacrifice",1],trait:["cannibalize"],not_trait:["cataclysm","lone_survivor"],cost:{Knowledge:()=>60},effect:z("tech_ceremonial_dagger_effect"),action(){return!!ri($(this)[0])}},last_rites:{id:"tech-last_rites",title:z("tech_last_rites"),desc:z("tech_last_rites"),category:"sacrifice",era:"civilized",reqs:{sacrifice:1,theology:2},grant:["sacrifice",2],trait:["cannibalize"],cost:{Knowledge:()=>1e3},effect:z("tech_last_rites_effect"),action(){return!!ri($(this)[0])}},ancient_infusion:{id:"tech-ancient_infusion",title:z("tech_ancient_infusion"),desc:z("tech_ancient_infusion"),category:"sacrifice",era:"early_space",reqs:{sacrifice:2,theology:4},grant:["sacrifice",3],trait:["cannibalize"],cost:{Knowledge:()=>182e3},effect:z("tech_ancient_infusion_effect"),action(){return!!ri($(this)[0])}},garrison:{id:"tech-garrison",title:z("tech_garrison"),desc:z("tech_garrison_desc"),category:"military",era:"civilized",reqs:{science:1,housing:1},grant:["military",1],cost:{Knowledge:()=>70},effect:z("tech_garrison_effect"),action(){return!!ri($(this)[0])&&(t.city.garrison={count:0,on:0},!0)}},mercs:{id:"tech-mercs",title:z("tech_mercs"),desc:z("tech_mercs_desc"),category:"military",era:"civilized",reqs:{military:1},grant:["mercs",1],not_trait:["lone_survivor"],cost:{Money:()=>1e4,Knowledge:()=>4500},effect:z("tech_mercs_effect"),action(){return!!ri($(this)[0])&&(t.civic.garrison.mercs=!0,!0)}},signing_bonus:{id:"tech-signing_bonus",title:z("tech_signing_bonus"),desc:z("tech_signing_bonus_desc"),category:"military",era:"industrialized",reqs:{mercs:1,high_tech:3},grant:["mercs",2],cost:{Money:()=>5e4,Knowledge:()=>32e3},effect:z("tech_signing_bonus_effect"),action(){return!!ri($(this)[0])}},hospital:{id:"tech-hospital",title:z("tech_hospital"),desc:z("tech_hospital"),category:"military",era:"civilized",reqs:{military:1,alumina:1},grant:["medic",1],not_trait:["artifical"],cost:{Knowledge:()=>5e3},effect:z("tech_hospital_effect"),action(){return!!ri($(this)[0])&&(t.city.hospital={count:0},!0)}},bac_tanks:{id:"tech-bac_tanks",title:()=>t.race.artifical?z("tech_repair_subroutines"):z("tech_bac_tanks"),desc:()=>t.race.artifical?z("tech_repair_subroutines"):z("tech_bac_tanks_desc"),category:"military",era:"interstellar",reqs:{medic:1,infernite:1},grant:["medic",2],cost:{Knowledge:()=>6e5,Infernite:()=>250},effect:()=>t.race.artifical?z("tech_repair_subroutines_effect"):z("tech_bac_tanks_effect"),action(){return!!ri($(this)[0])}},boot_camp:{id:"tech-boot_camp",title:z("tech_boot_camp"),desc:z("tech_boot_camp_desc"),category:"military",era:"discovery",reqs:{high_tech:1},grant:["boot_camp",1],cost:{Knowledge:()=>8e3},effect:z("tech_boot_camp_effect"),action(){return!!ri($(this)[0])&&(t.city.boot_camp={count:0},!0)}},vr_training:{id:"tech-vr_training",title:z("tech_vr_training"),desc:z("tech_vr_training"),category:"military",era:"interstellar",path:["standard","truepath"],reqs:{boot_camp:1,high_tech:12},not_trait:["cataclysm","lone_survivor"],grant:["boot_camp",2],cost:{Knowledge:()=>625e3},effect:()=>z("tech_vr_training_effect"),action(){return!!ri($(this)[0])}},bows:{id:"tech-bows",title:z("tech_bows"),desc:z("tech_bows_desc"),category:"military",era:"civilized",reqs:{military:1},grant:["military",2],cost:{Knowledge:()=>225,Lumber:()=>250},effect:z("tech_bows_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},flintlock_rifle:{id:"tech-flintlock_rifle",title:()=>"magic"===t.race.universe?z("tech_magic_arrow"):z("tech_flintlock_rifle"),desc:()=>"magic"===t.race.universe?z("tech_magic_arrow"):z("tech_flintlock_rifle"),category:"military",era:"civilized",reqs:{military:2,explosives:1},grant:["military",3],cost:{Knowledge:()=>5400,Coal:()=>"magic"===t.race.universe?0:750,Mana:()=>"magic"===t.race.universe?100:0},effect:()=>"magic"===t.race.universe?z("tech_magic_arrow_effect"):z("tech_flintlock_rifle_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},machine_gun:{id:"tech-machine_gun",title:()=>"magic"===t.race.universe?z("tech_fire_mage"):z("tech_machine_gun"),desc:()=>"magic"===t.race.universe?z("tech_fire_mage"):z("tech_machine_gun"),category:"military",era:"industrialized",reqs:{military:3,oil:1},grant:["military",4],cost:{Mana:()=>"magic"===t.race.universe?300:0,Knowledge:()=>33750,Oil:()=>1500},effect:z("tech_machine_gun_effect"),effect:()=>"magic"===t.race.universe?z("tech_fire_mage_effect"):z("tech_machine_gun_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},bunk_beds:{id:"tech-bunk_beds",title:z("tech_bunk_beds"),desc:z("tech_bunk_beds"),category:"military",era:"globalized",reqs:{military:4,high_tech:4},grant:["military",5],cost:{Knowledge:()=>76500,Furs:()=>25e3,Alloy:()=>3e3},effect:z("tech_bunk_beds_effect"),action(){return!!ri($(this)[0])}},rail_guns:{id:"tech-rail_guns",title:()=>"magic"===t.race.universe?z("tech_lightning_caster"):z("tech_rail_guns"),desc:()=>"magic"===t.race.universe?z("tech_lightning_caster"):z("tech_rail_guns"),category:"military",era:"early_space",reqs:{military:5,mass:1},grant:["military",6],cost:{Mana:()=>"magic"===t.race.universe?450:0,Knowledge:()=>2e5,Iridium:()=>2500},effect:()=>"magic"===t.race.universe?z("tech_lightning_caster_effect"):z("tech_rail_guns_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},laser_rifles:{id:"tech-laser_rifles",title:()=>"magic"===t.race.universe?z("tech_mana_rifles"):z("tech_laser_rifles"),desc:()=>"magic"===t.race.universe?z("tech_mana_rifles"):z("tech_laser_rifles"),category:"military",era:"deep_space",reqs:{military:6,high_tech:9,elerium:1},grant:["military",7],cost:{Knowledge:()=>325e3,Elerium:()=>250},effect:()=>"magic"===t.race.universe?z("tech_mana_rifles_effect"):z("tech_laser_rifles_effect"),action(){return!!ri($(this)[0])&&("sharkin"===t.race.species&&qn("laser_shark"),!0)},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},plasma_rifles:{id:"tech-plasma_rifles",title:()=>"magic"===t.race.universe?z("tech_focused_rifles"):z("tech_plasma_rifles"),desc:()=>"magic"===t.race.universe?z("tech_focused_rifles"):z("tech_plasma_rifles"),category:"military",era:"interstellar",reqs:{military:7,high_tech:13},grant:["military",8],path:["standard","truepath"],cost:{Knowledge:()=>78e4,Elerium:()=>t.race.truepath?1e3:500},effect:()=>"magic"===t.race.universe?z("tech_focused_rifles_effect"):z("tech_plasma_rifles_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},disruptor_rifles:{id:"tech-disruptor_rifles",title:()=>"magic"===t.race.universe?z("tech_magic_missile"):z("tech_disruptor_rifles"),desc:()=>"magic"===t.race.universe?z("tech_magic_missile"):z("tech_disruptor_rifles"),category:"military",era:"interstellar",reqs:{military:8,high_tech:14,science:15,infernite:1},grant:["military",9],cost:{Knowledge:()=>1e6,Infernite:()=>1e3},effect:()=>"magic"===t.race.universe?z("tech_magic_missile_effect"):z("tech_disruptor_rifles_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},gauss_rifles:{id:"tech-gauss_rifles",title:()=>"magic"===t.race.universe?z("tech_magicword_kill"):z("tech_gauss_rifles"),desc:()=>"magic"===t.race.universe?z("tech_magicword_kill"):z("tech_gauss_rifles"),category:"military",era:"intergalactic",reqs:{military:9,science:18},grant:["military",10],cost:{Knowledge:()=>95e5,Bolognium:()=>1e5},effect:()=>"magic"===t.race.universe?z("tech_magicword_kill_effect"):z("tech_gauss_rifles_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},cyborg_soldiers:{id:"tech-cyborg_soldiers",title:z("tech_cyborg_soldiers"),desc:z("tech_cyborg_soldiers"),category:"military",era:"dimensional",reqs:{military:10,high_tech:18},grant:["military",11],cost:{Knowledge:()=>26e6,Adamantite:()=>8e6,Bolognium:()=>4e6,Orichalcum:()=>6e6},effect:z("tech_cyborg_soldiers_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},space_marines:{id:"tech-space_marines",title:z("tech_space_marines"),desc:z("tech_space_marines_desc"),category:"military",era:"early_space",reqs:{space:3,mars:2},grant:["marines",1],cost:{Knowledge:()=>21e4},effect:()=>`
                ${z("tech_space_marines_effect",[Ut().red])}
                `,action(){return!!ri($(this)[0])&&(t.space.space_barracks={count:0,on:0},!0)},flair:z("tech_space_marines_flair")},hammocks:{id:"tech-hammocks",title:z("tech_hammocks"),desc:z("tech_hammocks"),category:"military",era:"intergalactic",reqs:{marines:1,nanoweave:1},grant:["marines",2],cost:{Knowledge:()=>89e5,Nanoweave:()=>3e4},effect:()=>z("tech_hammocks_effect"),action(){return!!ri($(this)[0])}},cruiser:{id:"tech-cruiser",title:z("tech_cruiser"),desc:z("tech_cruiser"),category:"military",era:"interstellar",reqs:{high_tech:14,proxima:2,aerogel:1},grant:["cruiser",1],cost:{Knowledge:()=>86e4},effect:z("tech_cruiser_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.cruiser={count:0,on:0},!0)}},armor:{id:"tech-armor",title:z("tech_armor"),desc:z("tech_armor_desc"),category:"military",era:"civilized",reqs:{military:1},not_trait:["apex_predator"],grant:["armor",1],cost:{Money:()=>250,Knowledge:()=>225,Furs:()=>250},effect:z("tech_armor_effect"),action(){return!!ri($(this)[0])}},plate_armor:{id:"tech-plate_armor",title:z("tech_plate_armor"),desc:z("tech_plate_armor_desc"),category:"military",era:"civilized",reqs:{armor:1,mining:3},grant:["armor",2],cost:{Knowledge:()=>3400,Iron:()=>600},effect:z("tech_plate_armor_effect"),action(){return!!ri($(this)[0])}},kevlar:{id:"tech-kevlar",title:z("tech_kevlar"),desc:z("tech_kevlar_desc"),category:"military",era:"globalized",reqs:{armor:2,polymer:1},grant:["armor",3],cost:{Knowledge:()=>86e3,Polymer:()=>750},effect:z("tech_kevlar_effect"),action(){return!!ri($(this)[0])}},nanoweave_vest:{id:"tech-nanoweave_vest",title:z("tech_nanoweave_vest"),desc:z("tech_nanoweave_vest"),category:"military",era:"intergalactic",reqs:{armor:3,nanoweave:1},grant:["armor",4],cost:{Knowledge:()=>925e4,Nanoweave:()=>75e3},effect:z("tech_nanoweave_vest_effect"),action(){return!!ri($(this)[0])}},laser_turret:{id:"tech-laser_turret",title:z("tech_laser_turret"),desc:z("tech_laser_turret"),category:"hell_dimension",era:"interstellar",reqs:{high_tech:9,portal:2},grant:["turret",1],cost:{Knowledge:()=>6e5,Elerium:()=>100},effect:()=>`
                ${z("tech_laser_turret_effect1")}
                ${z("tech_laser_turret_effect2")}
                `,action(){return!!ri($(this)[0])},post(){Cs({el:"#fort"},"update"),ui(!1,["portal-turret"])}},plasma_turret:{id:"tech-plasma_turret",title:z("tech_plasma_turret"),desc:z("tech_plasma_turret"),category:"hell_dimension",era:"interstellar",reqs:{high_tech:13,turret:1},grant:["turret",2],cost:{Knowledge:()=>76e4,Elerium:()=>350},effect:()=>`
                ${z("tech_plasma_turret_effect")}
                ${z("tech_laser_turret_effect2")}
                `,action(){return!!ri($(this)[0])},post(){Cs({el:"#fort"},"update"),ui(!1,["portal-turret"])}},black_powder:{id:"tech-black_powder",title:()=>"magic"===t.race.universe?z("tech_magic_powder"):z("tech_black_powder"),desc:()=>"magic"===t.race.universe?z("tech_magic_powder_desc"):z("tech_black_powder_desc"),category:"progress",era:"civilized",reqs:{mining:4},grant:["explosives",1],cost:{Knowledge:()=>4500,Mana:()=>"magic"===t.race.universe?100:0,Crystal:()=>"magic"===t.race.universe?250:0,Coal:()=>"magic"===t.race.universe?300:500},effect:()=>"magic"===t.race.universe?z("tech_magic_powder_effect"):z("tech_black_powder_effect"),action(){return!!ri($(this)[0])}},dynamite:{id:"tech-dynamite",title:z("tech_dynamite"),desc:z("tech_dynamite"),category:"mining",era:"civilized",reqs:{explosives:1},grant:["explosives",2],cost:{Knowledge:()=>4800,Coal:()=>750},effect:z("tech_dynamite_effect"),action(){return!!ri($(this)[0])}},anfo:{id:"tech-anfo",title:z("tech_anfo"),desc:z("tech_anfo"),category:"mining",era:"industrialized",reqs:{explosives:2,oil:1},grant:["explosives",3],cost:{Knowledge:()=>42e3,Oil:()=>2500},effect:z("tech_anfo_effect"),action(){return!!ri($(this)[0])}},mad:{id:"tech-mad",title:z("tech_mad"),desc:z("tech_mad_desc"),category:"special",era:"globalized",reqs:{uranium:1,explosives:3,high_tech:7},not_trait:["cataclysm","lone_survivor"],grant:["mad",1],condition:()=>!(t.race.sludge||t.race.truepath&&!t.tech.world_control),cost:{Knowledge:()=>12e4,Oil:()=>t.city.ptrait.includes("dense")?1e4:8500,Uranium:()=>1250},effect:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("tech_mad_effect_easter"):z("tech_mad_effect"),action(){return!!ri($(this)[0])&&(t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?hs(z("tech_mad_info_easter"),"info",!1,["progress"]):hs(z("tech_mad_info"),"info",!1,["progress"]),t.civic.mad.display=!0,!0)}},cement:{id:"tech-cement",title:z("tech_cement"),desc:z("tech_cement_desc"),category:"cement",era:"civilized",reqs:{mining:1,storage:1,science:1},not_trait:["flier"],grant:["cement",1],cost:{Knowledge:()=>500},effect:z("tech_cement_effect"),action(){return!!ri($(this)[0])&&(t.city.cement_plant={count:0,on:0},!0)}},rebar:{id:"tech-rebar",title:z("tech_rebar"),desc:z("tech_rebar"),category:"cement",era:"civilized",reqs:{mining:3,cement:1},not_trait:["flier"],grant:["cement",2],cost:{Knowledge:()=>3200,Iron:()=>750},effect:z("tech_rebar_effect"),action(){return!!ri($(this)[0])}},steel_rebar:{id:"tech-steel_rebar",title:z("tech_steel_rebar"),desc:z("tech_steel_rebar"),category:"cement",era:"civilized",reqs:{smelting:2,cement:2},not_trait:["flier"],grant:["cement",3],cost:{Knowledge:()=>6750,Steel:()=>750},effect:z("tech_steel_rebar_effect"),action(){return!!ri($(this)[0])}},portland_cement:{id:"tech-portland_cement",title:z("tech_portland_cement"),desc:z("tech_portland_cement"),category:"cement",era:"industrialized",reqs:{cement:3,high_tech:3},not_trait:["flier"],grant:["cement",4],cost:{Knowledge:()=>32e3},effect:z("tech_portland_cement_effect"),action(){return!!ri($(this)[0])}},screw_conveyor:{id:"tech-screw_conveyor",title:z("tech_screw_conveyor"),desc:z("tech_screw_conveyor"),category:"cement",era:"globalized",reqs:{cement:4,high_tech:4},not_trait:["flier"],grant:["cement",5],cost:{Knowledge:()=>72e3},effect:z("tech_screw_conveyor_effect"),action(){return!!ri($(this)[0])}},adamantite_screws:{id:"tech-adamantite_screws",title:z("tech_adamantite_screws"),desc:z("tech_adamantite_screws"),category:"cement",era:"interstellar",reqs:{cement:5,alpha:2},not_trait:["cataclysm","flier"],grant:["cement",6],cost:{Knowledge:()=>5e5,Adamantite:()=>1e4},effect:z("tech_adamantite_screws_effect",[3]),action(){return!!ri($(this)[0])}},hunter_process:{id:"tech-hunter_process",title:z("tech_hunter_process"),desc:z("tech_hunter_process"),category:"mining",era:"industrialized",reqs:{high_tech:3,smelting:2},grant:["titanium",1],cost:{Knowledge:()=>45e3,Titanium:()=>1e3},effect:z("tech_hunter_process_effect"),action(){return!!ri($(this)[0])&&(t.resource.Titanium.value=Ca.Titanium,!0)}},kroll_process:{id:"tech-kroll_process",title:z("tech_kroll_process"),desc:z("tech_kroll_process"),category:"mining",era:"globalized",reqs:{titanium:1,high_tech:4},grant:["titanium",2],cost:{Knowledge:()=>78e3,Titanium:()=>1e4},effect:z("tech_kroll_process_effect"),action(){return!!ri($(this)[0])}},cambridge_process:{id:"tech-cambridge_process",title:z("tech_cambridge_process"),desc:z("tech_cambridge_process"),category:"mining",era:"early_space",reqs:{titanium:2,supercollider:1},grant:["titanium",3],cost:{Knowledge:()=>135e3,Titanium:()=>17500},effect:z("tech_cambridge_process_effect"),action(){return!!ri($(this)[0])}},pynn_partical:{id:"tech-pynn_partical",title:z("tech_pynn_partical"),desc:z("tech_pynn_partical"),category:"progress",era:"early_space",path:["standard"],reqs:{supercollider:1},grant:["particles",1],cost:{Knowledge:()=>1e5},effect:z("tech_pynn_partical_effect"),action(){return!!ri($(this)[0])}},matter_compression:{id:"tech-matter_compression",title:z("tech_matter_compression"),desc:z("tech_matter_compression"),category:"storage",era:"early_space",path:["standard"],reqs:{particles:1},grant:["particles",2],cost:{Knowledge:()=>112500},effect:z("tech_matter_compression_effect"),action(){return!!ri($(this)[0])}},higgs_boson:{id:"tech-higgs_boson",title:z("tech_higgs_boson"),desc:z("tech_higgs_boson"),category:"science",era:"early_space",path:["standard"],reqs:{particles:2,supercollider:2},grant:["particles",3],cost:{Knowledge:()=>125e3},effect:z("tech_higgs_boson_effect"),action(){return!!ri($(this)[0])}},dimensional_compression:{id:"tech-dimensional_compression",title:z("tech_dimensional_compression"),desc:z("tech_dimensional_compression"),category:"storage",era:"interstellar",reqs:{particles:3,science:11,supercollider:3},grant:["particles",4],cost:{Knowledge:()=>425e3},effect:z("tech_dimensional_compression_effect"),action(){return!!ri($(this)[0])}},theology:{id:"tech-theology",title:z("tech_theology"),desc:z("tech_theology"),category:"religion",era:"civilized",reqs:{theology:1,housing:1,cement:1},grant:["theology",2],cost:{Knowledge:()=>900},effect:z("tech_theology_effect"),action(){return!!ri($(this)[0])&&(t.city.temple={count:0},t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0}),t.genes.ancients&&t.genes.ancients>=2&&(t.civic.priest.display=!0),!0)}},fanaticism:{id:"tech-fanaticism",title:z("tech_fanaticism"),desc:z("tech_fanaticism"),category:"religion",era:"civilized",wiki:!t.genes.transcendence,reqs:{theology:2},grant:["theology",3],not_gene:["transcendence"],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-anthropology"===e.id)),cost:{Knowledge:()=>2500},effect:`
                ${z("tech_fanaticism_effect")}
                ${z("tech_fanaticism_warning")}
                `,action(){return!!ri($(this)[0])&&(t.tech.fanaticism=1,t.race.gods===t.race.species&&qn("second_evolution"),mi(t.race.gods),!0)}},alt_fanaticism:{id:"tech-alt_fanaticism",title:z("tech_fanaticism"),desc:z("tech_fanaticism"),category:"religion",era:"civilized",wiki:!!t.genes.transcendence,reqs:{theology:2},grant:["fanaticism",1],gene:["transcendence"],cost:{Knowledge:()=>2500},effect:`
                ${z("tech_fanaticism_effect")}
                `,action(){return!!ri($(this)[0])&&(2===t.tech.theology&&(t.tech.theology=3),t.race.gods===t.race.species&&qn("second_evolution"),mi(t.race.gods),!0)}},ancient_theology:{id:"tech-ancient_theology",title:z("tech_ancient_theology"),desc:z("tech_ancient_theology"),category:"religion",era:"early_space",reqs:{theology:3,mars:2},grant:["theology",4],condition:()=>!!t.genes.ancients,cost:{Knowledge:()=>18e4},effect:()=>z("tech_ancient_theology_effect",["none"!==t.race.old_gods?Ki[t.race.old_gods.toLowerCase()].entity:Ki[t.race.species].entity,"none"!==t.race.gods?Ki[t.race.gods.toLowerCase()].entity:Ki[t.race.species].entity]),action(){return!!ri($(this)[0])&&(t.space.ziggurat={count:0},!0)}},study:{id:"tech-study",title:z("tech_study"),desc:z("tech_study_desc"),category:"religion",era:"early_space",reqs:{theology:4},grant:["theology",5],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-deify"===e.id)),cost:{Knowledge:()=>195e3},effect:()=>`
                ${z("tech_study_effect",["none"!==t.race.old_gods?Ki[t.race.old_gods.toLowerCase()].entity:Ki[t.race.species].entity])}
                ${z("tech_study_warning")}
                `,action(){return!!ri($(this)[0])&&(t.tech.ancient_study=1,!0)}},encoding:{id:"tech-encoding",title:z("tech_encoding"),desc:z("tech_encoding_desc"),category:"religion",era:"deep_space",reqs:{ancient_study:1,mars:5},grant:["ancient_study",2],cost:{Knowledge:()=>268e3},effect:()=>`
                ${z("tech_encoding_effect")}
                `,action(){return!!ri($(this)[0])}},deify:{id:"tech-deify",title:z("tech_deify"),desc:z("tech_deify_desc"),category:"religion",era:"early_space",reqs:{theology:4},grant:["theology",5],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-study"===e.id)),cost:{Knowledge:()=>195e3},effect:()=>`
                ${z("tech_deify_effect",["none"!==t.race.old_gods?Ki[t.race.old_gods.toLowerCase()].entity:Ki[t.race.species].entity])}
                ${z("tech_deify_warning")}
                `,action(){return!!ri($(this)[0])&&(t.tech.ancient_deify=1,mi(t.race.old_gods),xe("Genetics"),!0)}},infusion:{id:"tech-infusion",title:z("tech_infusion"),desc:z("tech_infusion_desc"),category:"religion",era:"deep_space",reqs:{ancient_deify:1,mars:5},grant:["ancient_deify",2],cost:{Knowledge:()=>268e3},effect:()=>`
                ${z("tech_infusion_effect")}
                `,action(){return!!ri($(this)[0])}},indoctrination:{id:"tech-indoctrination",title:z("tech_indoctrination"),desc:z("tech_indoctrination"),category:"religion",era:"civilized",reqs:{fanaticism:1},grant:["fanaticism",2],cost:{Knowledge:()=>5e3},effect:z("tech_indoctrination_effect"),action(){return!!ri($(this)[0])},post(){t.race.terrifying&&(t.tech.fanaticism=3,Qr())}},missionary:{id:"tech-missionary",title:z("tech_missionary"),desc:z("tech_missionary"),category:"religion",era:"discovery",reqs:{fanaticism:2},not_trait:["terrifying"],grant:["fanaticism",3],cost:{Knowledge:()=>1e4},effect:z("tech_missionary_effect"),action(){return!!ri($(this)[0])}},zealotry:{id:"tech-zealotry",title:z("tech_zealotry"),desc:z("tech_zealotry"),category:"religion",era:"discovery",reqs:{fanaticism:3},grant:["fanaticism",4],cost:{Knowledge:()=>25e3},effect:z("tech_zealotry_effect"),action(){return!!ri($(this)[0])}},anthropology:{id:"tech-anthropology",title:z("tech_anthropology"),desc:z("tech_anthropology"),category:"religion",era:"civilized",wiki:!t.genes.transcendence,reqs:{theology:2},grant:["theology",3],not_gene:["transcendence"],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-fanaticism"===e.id)),cost:{Knowledge:()=>2500},effect:`
                ${z("tech_anthropology_effect")}
                ${z("tech_anthropology_warning")}
                `,action(){return!!ri($(this)[0])&&(t.tech.anthropology=1,!0)}},alt_anthropology:{id:"tech-alt_anthropology",title:z("tech_anthropology"),desc:z("tech_anthropology"),category:"religion",era:"civilized",wiki:!!t.genes.transcendence,reqs:{theology:2},grant:["anthropology",1],gene:["transcendence"],cost:{Knowledge:()=>2500},effect:`
                ${z("tech_anthropology_effect")}
                `,action(){return!!ri($(this)[0])&&(2===t.tech.theology&&(t.tech.theology=3),!0)}},mythology:{id:"tech-mythology",title:z("tech_mythology"),desc:z("tech_mythology"),category:"religion",era:"civilized",reqs:{anthropology:1},grant:["anthropology",2],cost:{Knowledge:()=>5e3},effect:z("tech_mythology_effect"),action(){return!!ri($(this)[0])}},archaeology:{id:"tech-archaeology",title:z("tech_archaeology"),desc:z("tech_archaeology"),category:"science",era:"discovery",reqs:{anthropology:2},grant:["anthropology",3],cost:{Knowledge:()=>1e4},effect:z("tech_archaeology_effect"),action(){return!!ri($(this)[0])}},merchandising:{id:"tech-merchandising",title:z("tech_merchandising"),desc:z("tech_merchandising"),category:"banking",era:"discovery",reqs:{anthropology:3},grant:["anthropology",4],cost:{Knowledge:()=>25e3},effect:()=>t.race.truepath?z("tech_merchandising_effect_tp"):z("tech_merchandising_effect"),action(){return!!ri($(this)[0])}},astrophysics:{id:"tech-astrophysics",title:z("tech_astrophysics"),desc:z("tech_astrophysics_desc"),category:"storage",era:"early_space",reqs:{space:2},grant:["space_explore",1],cost:{Knowledge:()=>125e3},effect:z("tech_astrophysics_effect"),action(){return!!ri($(this)[0])&&(t.space.propellant_depot={count:0},!0)}},rover:{id:"tech-rover",title:z("tech_rover"),desc:z("tech_rover"),category:"space_exploration",era:"early_space",reqs:{space_explore:1},grant:["space_explore",2],cost:{Knowledge:()=>135e3,Alloy:()=>22e3,Polymer:()=>18e3,Uranium:()=>750},effect:z("tech_rover_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.moon=!0,t.space.moon_base={count:0,on:0,support:0,s_max:0},!0)}},probes:{id:"tech-probes",title:z("tech_probes"),desc:z("tech_probes"),category:"space_exploration",era:"early_space",reqs:{space_explore:2},grant:["space_explore",3],cost:{Knowledge:()=>168e3,Steel:()=>1e5,Iridium:()=>5e3,Uranium:()=>2250,Helium_3:()=>3500},effect:z("tech_probes_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.red=!0,t.settings.space.hell=!0,t.space.spaceport={count:0,on:0,support:0,s_max:0},!0)}},starcharts:{id:"tech-starcharts",title:z("tech_starcharts"),desc:z("tech_starcharts"),category:"space_exploration",era:"early_space",reqs:{space_explore:3,science:9},grant:["space_explore",4],cost:{Knowledge:()=>185e3},effect:z("tech_starcharts_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.gas=!0,t.settings.space.sun=!0,t.race.truepath&&(t.settings.showOuter=!0),t.space.swarm_control={count:0,support:0,s_max:0},!0)}},colonization:{id:"tech-colonization",title:z("tech_colonization"),desc:()=>z("tech_colonization_desc",[Ut().red]),category:"agriculture",era:"early_space",reqs:{space:4,mars:1},grant:["mars",2],cost:{Knowledge:()=>172e3},effect:()=>z(t.race.artifical?"tech_colonization_artifical_effect":"tech_colonization_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.biodome={count:0,on:0},!0)}},red_tower:{id:"tech-red_tower",title:()=>z("tech_red_tower",[Ut().red]),desc:()=>z("tech_red_tower",[Ut().red]),category:"space_exploration",era:"early_space",reqs:{mars:2},grant:["mars",3],cost:{Knowledge:()=>195e3},effect:()=>z("tech_red_tower_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.red_tower={count:0,on:0},!0)}},space_manufacturing:{id:"tech-space_manufacturing",title:z("tech_space_manufacturing"),desc:z("tech_space_manufacturing_desc"),category:"crafting",era:"early_space",reqs:{mars:3},grant:["mars",4],cost:{Knowledge:()=>22e4},effect:()=>z("tech_space_manufacturing_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.red_factory={count:0,on:0},!0)}},exotic_lab:{id:"tech-exotic_lab",title:z("tech_exotic_lab"),desc:z("tech_exotic_lab_desc"),category:"science",era:"deep_space",reqs:{mars:4,asteroid:5},grant:["mars",5],cost:{Knowledge:()=>25e4},effect:z("tech_exotic_lab_effect"),action(){return!!ri($(this)[0])&&(t.space.exotic_lab={count:0,on:0},!0)}},hydroponics:{id:"tech-hydroponics",title:z("tech_hydroponics"),desc:()=>z("tech_hydroponics"),category:"agriculture",era:"intergalactic",reqs:{mars:5,gateway:3},grant:["mars",6],cost:{Knowledge:()=>3e6,Bolognium:()=>5e5},effect:()=>z("tech_hydroponics_effect"),action(){return!!ri($(this)[0])}},dyson_sphere:{id:"tech-dyson_sphere",title:z("tech_dyson_sphere"),desc:z("tech_dyson_sphere"),category:"power_generation",era:"early_space",reqs:{solar:1},grant:["solar",2],cost:{Knowledge:()=>195e3},effect:z("tech_dyson_sphere_effect"),action(){return!!ri($(this)[0])}},dyson_swarm:{id:"tech-dyson_swarm",title:z("tech_dyson_swarm"),desc:z("tech_dyson_swarm"),category:"power_generation",era:"early_space",reqs:{solar:2},grant:["solar",3],cost:{Knowledge:()=>21e4},effect:z("tech_dyson_swarm_effect"),action(){return!!ri($(this)[0])&&(t.space.swarm_satellite={count:0},!0)}},swarm_plant:{id:"tech-swarm_plant",title:z("tech_swarm_plant"),desc:z("tech_swarm_plant"),category:"power_generation",era:"deep_space",reqs:{solar:3,hell:1,gas_moon:1},grant:["solar",4],cost:{Knowledge:()=>25e4},effect:()=>z("tech_swarm_plant_effect",[Ki[t.race.species].home,Ut().hell]),action(){return!!ri($(this)[0])&&(t.space.swarm_plant={count:0},!0)}},space_sourced:{id:"tech-space_sourced",title:z("tech_space_sourced"),desc:z("tech_space_sourced_desc"),category:"power_generation",era:"deep_space",reqs:{solar:4,asteroid:3},grant:["solar",5],cost:{Knowledge:()=>3e5},effect:z("tech_space_sourced_effect"),action(){return!!ri($(this)[0])}},swarm_plant_ai:{id:"tech-swarm_plant_ai",title:z("tech_swarm_plant_ai"),desc:z("tech_swarm_plant_ai"),category:"power_generation",era:"deep_space",reqs:{solar:4,high_tech:10},grant:["swarm",1],cost:{Knowledge:()=>335e3},effect:z("tech_swarm_plant_ai_effect"),action(){return!!ri($(this)[0])}},swarm_control_ai:{id:"tech-swarm_control_ai",title:z("tech_swarm_control_ai"),desc:z("tech_swarm_control_ai"),category:"power_generation",era:"deep_space",reqs:{swarm:1},grant:["swarm",2],cost:{Knowledge:()=>36e4},effect:z("tech_swarm_control_ai_effect"),action(){return!!ri($(this)[0])}},quantum_swarm:{id:"tech-quantum_swarm",title:z("tech_quantum_swarm"),desc:z("tech_quantum_swarm"),category:"power_generation",era:"deep_space",reqs:{swarm:2,high_tech:11},grant:["swarm",3],cost:{Knowledge:()=>45e4},effect:z("tech_quantum_swarm_effect"),action(){return!!ri($(this)[0])}},perovskite_cell:{id:"tech-perovskite_cell",title:z("tech_perovskite_cell"),desc:z("tech_perovskite_cell"),category:"power_generation",era:"interstellar",reqs:{swarm:3},grant:["swarm",4],path:["standard","truepath"],cost:{Knowledge:()=>525e3,Titanium:()=>1e5},effect:z("tech_perovskite_cell_effect"),action(){return!!ri($(this)[0])}},swarm_convection:{id:"tech-swarm_convection",title:z("tech_swarm_convection"),desc:z("tech_swarm_convection"),category:"power_generation",era:"interstellar",reqs:{swarm:4,stanene:1},grant:["swarm",5],path:["standard","truepath"],cost:{Knowledge:()=>725e3,Stanene:()=>1e5},effect:z("tech_swarm_convection_effect"),action(){return!!ri($(this)[0])}},orichalcum_panels:{id:"tech-orichalcum_panels",title:z("tech_orichalcum_panels"),desc:z("tech_orichalcum_panels"),category:"power_generation",era:"intergalactic",reqs:{high_tech:17,swarm:5},grant:["swarm",6],cost:{Knowledge:()=>14e6,Orichalcum:()=>125e3},effect:()=>z("tech_orichalcum_panels_effect"),action(){return!!ri($(this)[0])}},dyson_net:{id:"tech-dyson_net",title:z("tech_dyson_net"),desc:z("tech_dyson_net"),category:"power_generation",era:"interstellar",reqs:{solar:3,proxima:2,stanene:1},grant:["proxima",3],cost:{Knowledge:()=>8e5},effect:z("tech_dyson_net_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.dyson={count:0},!0)}},dyson_sphere2:{id:"tech-dyson_sphere2",title:z("tech_dyson_sphere"),desc:z("tech_dyson_sphere"),category:"power_generation",era:"intergalactic",reqs:{proxima:3,piracy:1},grant:["dyson",1],cost:{Knowledge:()=>5e6},effect:z("tech_dyson_sphere2_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.dyson_sphere={count:0},!0)}},orichalcum_sphere:{id:"tech-orichalcum_sphere",title:z("tech_orichalcum_sphere"),desc:z("tech_orichalcum_sphere"),category:"power_generation",era:"intergalactic",reqs:{dyson:1,science:19},condition:()=>!!(t.interstellar.dyson_sphere&&t.interstellar.dyson_sphere.count>=100),grant:["dyson",2],cost:{Knowledge:()=>175e5,Orichalcum:()=>25e4},effect:z("tech_orichalcum_sphere_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.orichalcum_sphere={count:0},!0)}},gps:{id:"tech-gps",title:z("tech_gps"),desc:z("tech_gps"),category:"market",era:"early_space",reqs:{space_explore:1},not_trait:["terrifying"],grant:["satellite",1],cost:{Knowledge:()=>15e4},effect:z("tech_gps_effect"),action(){return!!ri($(this)[0])&&(t.space.gps={count:0},!0)}},nav_beacon:{id:"tech-nav_beacon",title:z("tech_nav_beacon"),desc:z("tech_nav_beacon"),category:"space_exploration",era:"early_space",reqs:{luna:1},grant:["luna",2],cost:{Knowledge:()=>18e4},effect:z("tech_nav_beacon_effect"),action(){return!!ri($(this)[0])&&(t.space.nav_beacon={count:0,on:0},!0)}},subspace_signal:{id:"tech-subspace_signal",title:z("tech_subspace_signal"),desc:z("tech_subspace_signal"),category:"space_exploration",era:"interstellar",reqs:{science:13,luna:2,stanene:1},grant:["luna",3],cost:{Knowledge:()=>7e5,Stanene:()=>125e3},effect:()=>z("tech_subspace_signal_effect",[Ut().red]),action(){return!!ri($(this)[0])}},atmospheric_mining:{id:"tech-atmospheric_mining",title:z("tech_atmospheric_mining"),desc:z("tech_atmospheric_mining"),category:"power_generation",era:"early_space",reqs:{space:5},grant:["gas_giant",1],cost:{Knowledge:()=>19e4},effect:z("tech_atmospheric_mining_effect"),action(){return!!ri($(this)[0])&&(t.space.gas_mining={count:0,on:0},t.space.gas_storage={count:0},!0)}},helium_attractor:{id:"tech-helium_attractor",title:z("tech_helium_attractor"),desc:z("tech_helium_attractor"),category:"power_generation",era:"deep_space",reqs:{gas_giant:1,elerium:1},grant:["helium",1],cost:{Knowledge:()=>29e4,Elerium:()=>250},effect:()=>z("tech_helium_attractor_effect",[Ut().gas]),action(){return!!ri($(this)[0])}},ram_scoops:{id:"tech-ram_scoops",title:z("tech_ram_scoops"),desc:z("tech_ram_scoops"),category:"power_generation",era:"interstellar",reqs:{nebula:2},grant:["ram_scoop",1],cost:{Knowledge:()=>58e4},effect:()=>z("tech_ram_scoops_effect"),action(){return!!ri($(this)[0])}},elerium_prospecting:{id:"tech-elerium_prospecting",title:z("tech_elerium_prospecting"),desc:z("tech_elerium_prospecting"),category:"space_mining",era:"interstellar",reqs:{nebula:2},grant:["nebula",3],cost:{Knowledge:()=>61e4},effect:()=>z("tech_elerium_prospecting_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.elerium_prospector={count:0,on:0},!0)}},zero_g_mining:{id:"tech-zero_g_mining",title:z("tech_zero_g_mining"),desc:z("tech_zero_g_mining"),category:"space_mining",era:"early_space",reqs:{asteroid:1,high_tech:8},grant:["asteroid",2],cost:{Knowledge:()=>21e4},effect:z("tech_zero_g_mining_effect"),action(){return!!ri($(this)[0])&&(t.space.space_station={count:0,on:0,support:0,s_max:0},t.space.iridium_ship={count:0,on:0},t.space.iron_ship={count:0,on:0},!0)}},elerium_mining:{id:"tech-elerium_mining",title:z("tech_elerium_mining"),desc:z("tech_elerium_mining"),category:"space_mining",era:"deep_space",reqs:{asteroid:4},grant:["asteroid",5],cost:{Knowledge:()=>235e3,Elerium:()=>t.race.truepath?.5:1},effect:z("tech_elerium_mining_effect"),action(){return!!ri($(this)[0])&&(t.space.elerium_ship={count:0,on:0},t.race.cataclysm&&qn("iron_will",!1,2),!0)}},laser_mining:{id:"tech-laser_mining",title:z("tech_laser_mining"),desc:z("tech_laser_mining"),category:"space_mining",era:"deep_space",reqs:{asteroid:5,elerium:1,high_tech:9},grant:["asteroid",6],cost:{Knowledge:()=>35e4},effect:z("tech_laser_mining_effect"),action(){return!!ri($(this)[0])}},plasma_mining:{id:"tech-plasma_mining",title:z("tech_plasma_mining"),desc:z("tech_plasma_mining"),category:"space_mining",era:"interstellar",reqs:{asteroid:6,high_tech:13},grant:["asteroid",7],path:["standard","truepath"],cost:{Knowledge:()=>825e3},effect:z("tech_plasma_mining_effect"),action(){return!!ri($(this)[0])}},elerium_tech:{id:"tech-elerium_tech",title:z("tech_elerium_tech"),desc:z("tech_elerium_tech"),category:"space_mining",era:"deep_space",reqs:{asteroid:5},grant:["elerium",1],cost:{Knowledge:()=>275e3,Elerium:()=>20},effect:z("tech_elerium_tech_effect"),action(){return!!ri($(this)[0])}},elerium_reactor:{id:"tech-elerium_reactor",title:z("tech_elerium_reactor"),desc:z("tech_elerium_reactor"),category:"power_generation",era:"deep_space",reqs:{dwarf:1,elerium:1},grant:["elerium",2],cost:{Knowledge:()=>325e3,Elerium:()=>180},effect:z("tech_elerium_reactor_effect"),action(){return!!ri($(this)[0])&&(t.space.e_reactor={count:0,on:0},!0)}},neutronium_housing:{id:"tech-neutronium_housing",title:z("tech_neutronium_housing"),desc:z("tech_neutronium_housing"),category:"housing",era:"deep_space",reqs:{gas_moon:1},grant:["space_housing",1],cost:{Knowledge:()=>275e3,Neutronium:()=>350},effect:()=>z("tech_neutronium_housing_effect",[Ut().red]),action(){return!!ri($(this)[0])}},unification:{id:"tech-unification",title:z("tech_unification"),desc:()=>z("tech_unification_desc",[Ki[t.race.species].home]),category:"special",era:"early_space",path:["standard"],reqs:{mars:2},grant:["unify",1],cost:{Knowledge:()=>2e5},effect:z("tech_unification_effect"),action(){return!!ri($(this)[0])}},unification2:{id:"tech-unification2",title:z("tech_unification"),desc:()=>z("tech_unification_desc",[Ki[t.race.species].home]),category:"special",era:"early_space",path:["standard"],reqs:{unify:1},grant:["unify",2],cost:{Bool(){let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].buy||t.civic.foreign[`gov${a}`].anx)&&e++;return 3===e}},effect(){let e=t.race.banana?`
                ${z("tech_unification_banana")}
                `:"";return`
                ${z("tech_unification_effect2")}
                ${z("tech_unification_warning")}
                ${e}`},action(){return!!ri($(this)[0])&&(t.race.banana&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),delete t.race.banana),t.civic.foreign.gov0.occ&&t.civic.foreign.gov1.occ&&t.civic.foreign.gov2.occ&&qn("world_domination"),t.civic.foreign.gov0.anx&&t.civic.foreign.gov1.anx&&t.civic.foreign.gov2.anx&&qn("illuminati"),t.civic.foreign.gov0.buy&&t.civic.foreign.gov1.buy&&t.civic.foreign.gov2.buy&&qn("syndicate"),0===t.stats.attacks&&qn("pacifist"),qr(),!0)}},unite:{id:"tech-unite",title:z("tech_unite"),desc:()=>z("tech_unite_desc"),category:"special",era:"globalized",path:["truepath"],reqs:{unify:1},grant:["unify",2],cost:{Bool(){let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].buy||t.civic.foreign[`gov${a}`].anx)&&e++;return 3===e}},effect:()=>`
                ${z("tech_unite_effect")}
                ${z("tech_unification_effect2")}
                `,action(){return!!ri($(this)[0])&&(t.race.banana&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),delete t.race.banana),t.civic.foreign.gov0.occ&&t.civic.foreign.gov1.occ&&t.civic.foreign.gov2.occ&&qn("world_domination"),t.civic.foreign.gov0.anx&&t.civic.foreign.gov1.anx&&t.civic.foreign.gov2.anx&&qn("illuminati"),t.civic.foreign.gov0.buy&&t.civic.foreign.gov1.buy&&t.civic.foreign.gov2.buy&&qn("syndicate"),0===t.stats.attacks&&qn("pacifist"),qr(),t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,hs(z("civics_rival_unlocked",[Z(3)]),"info",!1,["progress","combat"])),!0)}},genesis:{id:"tech-genesis",title:z("tech_genesis"),desc:z("tech_genesis"),category:"special",era:"deep_space",reqs:{high_tech:10,genesis:1},grant:["genesis",2],cost:{Knowledge:()=>35e4},effect:z("tech_genesis_effect"),action(){return!!ri($(this)[0])}},star_dock:{id:"tech-star_dock",title:z("tech_star_dock"),desc:z("tech_star_dock"),category:"special",era:"deep_space",reqs:{genesis:2,space:5,high_tech:10},grant:["genesis",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>38e4},effect:z("tech_star_dock_effect"),action(){return!!ri($(this)[0])&&(t.space.star_dock={count:0,ship:0,probe:0,template:t.race.species},!0)}},interstellar:{id:"tech-interstellar",title:z("tech_interstellar"),desc:z("tech_interstellar"),category:"space_exploration",era:"deep_space",reqs:{genesis:3},grant:["genesis",4],cost:{Knowledge:()=>4e5},effect:z("tech_interstellar_effect"),action(){return!!ri($(this)[0])&&(t.starDock.probes={count:0},!0)}},genesis_ship:{id:"tech-genesis_ship",title:()=>t.race.cataclysm?z("tech_generational_ship"):z("tech_genesis_ship"),desc:()=>t.race.cataclysm?z("tech_generational_ship"):z("tech_genesis_ship"),category:"special",era:"deep_space",reqs:{genesis:4},grant:["genesis",5],cost:{Knowledge:()=>425e3},effect:()=>t.race.cataclysm?z("tech_generational_effect"):z("tech_genesis_ship_effect"),action(){return!!ri($(this)[0])&&(t.starDock.seeder={count:0},t.race.cataclysm&&qn("iron_will",!1,4),!0)}},geck:{id:"tech-geck",title:()=>z("tech_geck"),desc:()=>z("tech_geck_desc"),category:"special",era:"deep_space",reqs:{genesis:5},grant:["geck",1],condition:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5),cost:{Knowledge:()=>5e5},effect:()=>z("tech_geck_effect"),action(){return!!ri($(this)[0])&&(t.starDock.geck={count:0},!0)}},genetic_decay:{id:"tech-genetic_decay",title:z("tech_genetic_decay"),desc:z("tech_genetic_decay"),category:"genes",era:"early_space",reqs:{decay:1},grant:["decay",2],cost:{Knowledge:()=>2e5},effect:z("tech_genetic_decay_effect"),action(){return!!ri($(this)[0])}},stabilize_decay:{id:"tech-stabilize_decay",title:z("tech_stabilize_decay"),desc:z("tech_stabilize_decay"),category:"genes",era:"dimensional",reqs:{decay:2,high_tech:18},grant:["decay",3],cost:{Knowledge:()=>5e7,Blood_Stone:()=>1},effect:z("tech_stabilize_decay_effect"),action(){return!!ri($(this)[0])}},tachyon:{id:"tech-tachyon",title:z("tech_tachyon"),desc:z("tech_tachyon"),category:"progress",era:"interstellar",reqs:{wsc:1},grant:["ftl",1],cost:{Knowledge:()=>435e3},effect:z("tech_tachyon_effect"),action(){return!!ri($(this)[0])}},warp_drive:{id:"tech-warp_drive",title:z("tech_warp_drive"),desc:z("tech_warp_drive"),category:"space_exploration",era:"interstellar",reqs:{ftl:1},grant:["ftl",2],cost:{Knowledge:()=>45e4},effect:z("tech_warp_drive_effect"),action(){return!!ri($(this)[0])&&(t.settings.showDeep=!0,t.settings.space.alpha=!0,t.interstellar.starport={count:0,on:0,support:0,s_max:0},!0)}},habitat:{id:"tech-habitat",title:z("tech_habitat"),desc:z("tech_habitat_desc"),category:"housing",era:"interstellar",reqs:{alpha:2,droids:1},grant:["alpha",3],cost:{Knowledge:()=>48e4},effect:z("tech_habitat_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.habitat={count:0,on:0},!0)}},graphene:{id:"tech-graphene",title:z("tech_graphene"),desc:z("tech_graphene"),category:"crafting",era:"interstellar",reqs:{alpha:3,infernite:1},grant:["graphene",1],cost:{Knowledge:()=>54e4,Adamantite:()=>1e4},effect:z("tech_graphene_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},!0)}},aerogel:{id:"tech-aerogel",title:z("tech_aerogel"),desc:z("tech_aerogel"),category:"crafting",era:"interstellar",reqs:{graphene:1,science:13},grant:["aerogel",1],cost:{Knowledge:()=>75e4,Graphene:()=>5e4,Infernite:()=>500},effect:z("tech_aerogel_effect"),action(){return!!ri($(this)[0])&&(t.resource.Aerogel.display=!0,sa(),!0)},post(){cs()}},mega_manufacturing:{id:"tech-mega_manufacturing",title:z("tech_mega_manufacturing"),desc:z("tech_mega_manufacturing"),category:"crafting",era:"intergalactic",reqs:{high_tech:16,alpha:3},grant:["alpha",4],cost:{Knowledge:()=>565e4},effect:()=>z("tech_mega_manufacturing_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.int_factory={count:0,on:0},!0)}},luxury_condo:{id:"tech-luxury_condo",title:z("tech_luxury_condo"),desc:z("tech_luxury_condo"),category:"housing",era:"intergalactic",reqs:{high_tech:17,alpha:4},grant:["alpha",5],cost:{Knowledge:()=>15e6},effect:()=>z("tech_luxury_condo_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.luxury_condo={count:0,on:0},!0)}},stellar_engine:{id:"tech-stellar_engine",title:z("tech_stellar_engine"),desc:z("tech_stellar_engine"),category:"stellar_engine",era:"interstellar",reqs:{blackhole:2},grant:["blackhole",3],cost:{Knowledge:()=>1e6},effect:z("tech_stellar_engine_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.stellar_engine={count:0,mass:8,exotic:0},!0)}},mass_ejector:{id:"tech-mass_ejector",title:z("tech_mass_ejector"),desc:z("tech_mass_ejector"),category:"stellar_engine",era:"interstellar",reqs:{blackhole:4},grant:["blackhole",5],cost:{Knowledge:()=>11e5},effect:z("tech_mass_ejector_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.mass_ejector={count:0,on:0,total:0,mass:0,Food:0,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0},!0)}},asteroid_redirect:{id:"tech-asteroid_redirect",title:z("tech_asteroid_redirect"),desc:z("tech_asteroid_redirect"),category:"stellar_engine",era:"intergalactic",reqs:{blackhole:5,gateway:3},grant:["blackhole",6],cost:{Knowledge:()=>35e5},effect:z("tech_asteroid_redirect_effect"),action(){return!!ri($(this)[0])},post(){xe("Physics")}},exotic_infusion:{id:"tech-exotic_infusion",title:z("tech_exotic_infusion"),desc:z("tech_exotic_infusion"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:1},grant:["whitehole",2],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect:()=>`
                ${z("tech_exotic_infusion_effect",[t.resource.Soul_Gem.name])}
                ${z("tech_exotic_infusion_effect2")}
                `,action(){return!!ii($(this)[0])},flair:()=>z("tech_exotic_infusion_flair")},infusion_check:{id:"tech-infusion_check",title:z("tech_infusion_check"),desc:z("tech_infusion_check"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:2},grant:["whitehole",3],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect:()=>`
                ${z("tech_infusion_check_effect")}
                ${z("tech_exotic_infusion_effect2")}
                `,action(){return!!ii($(this)[0])},flair:()=>z("tech_infusion_check_flair")},infusion_confirm:{id:"tech-infusion_confirm",title:z("tech_infusion_confirm"),desc:z("tech_infusion_confirm"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:3},grant:["whitehole",4],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect(){let e=Gs("bigbang"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name"),r=`
                ${z("wiki_tech_infusion_confirm_gains",[e.plasmid,e.phage,e.dark,a])}
                `;return`
                ${z("tech_infusion_confirm_effect")}
                ${z("tech_exotic_infusion_effect2")}
                ${r}`},action(){if(ri($(this)[0])){if(t.tech.whitehole>=4)return;t.tech.whitehole=4;let a=$('
                ');return $("body").append(a),setTimeout((function(){a.addClass("burn")}),125),setTimeout((function(){a.addClass("b")}),150),setTimeout((function(){a.addClass("c")}),2e3),setTimeout((function(){!function(){switch(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"blackhole"}),qn(`extinct_${t.race.species}`),t.race.universe){case"heavy":qn("heavy");break;case"antimatter":qn("canceled");break;case"evil":qn("eviltwin");break;case"micro":qn("microbang",!0);break;case"standard":qn("whitehole")}t.space.hasOwnProperty("spaceport")&&0===t.space.spaceport.count&&qn("red_dead"),qn("squished",!0),"evil"===t.race.universe&&"angelic"===Ki[t.race.species].type&&Pn("nephilim"),t.race.junker&&"junker"===t.race.species&&Pn("the_misery"),t.race.decay&&qn("dissipated"),t.race.steelen&&Pn("steelem");let a=t.race.species,r=t.race.gods,i=t.city.calendar.orbit,s=t.city.biome,n=t.city.ptrait,c=Gs("bigbang");Sn(),t.stats.blackhole++,rn(),t.prestige.Phage.count+=c.phage,t.stats.phage+=c.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=c.plasmid,t.stats.antiplasmid+=c.plasmid):(t.prestige.Plasmid.count+=c.plasmid,t.stats.plasmid+=c.plasmid),t.prestige.Dark.count=+(t.prestige.Dark.count+c.dark).toFixed(3),t.stats.dark=+(t.stats.dark+c.dark).toFixed(3),t.stats.universes++;let o=!!t.race.hasOwnProperty("srace")&&t.race.srace,l=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:"bigbang",seeded:!0,bigbang:!0,probes:4,seed:Math.floor(m(1e4)),ascended:!1},l>0&&(t.race.corruption=l),o&&(t.race.srace=o),H({orbit:i,biome:s,ptrait:n,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),4e3),!1}return!1},flair:()=>z("tech_infusion_confirm_flair")},stabilize_blackhole:{id:"tech-stabilize_blackhole",title:z("tech_stabilize_blackhole"),desc:()=>`
                ${z("tech_stabilize_blackhole")}
                ${z("tech_stabilize_blackhole2")}
                `,category:"stellar_engine",era:"interstellar",reqs:{whitehole:1},grant:["stablized",1],cost:{Knowledge:()=>15e5,Neutronium:()=>2e4},effect:z("tech_stabilize_blackhole_effect"),action(){if(ri($(this)[0])){if(t.interstellar.stellar_engine.mass+=2e4*Fa.Neutronium/1e10,t.interstellar.stellar_engine.mass+=40*t.interstellar.stellar_engine.exotic,t.interstellar.stellar_engine.exotic=0,delete t.tech.whitehole,t.race.banana&&t.interstellar.stellar_engine.mass>=12){let e=xn();t.stats.banana.b3[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b3.l=!0)}return!0}return!1}},veil:{id:"tech-veil",title:z("tech_veil"),desc:z("tech_veil"),category:"magic",era:"interstellar",reqs:{blackhole:2},condition:()=>"magic"===t.race.universe,grant:["veil",1],cost:{Knowledge:()=>125e4},effect:z("tech_veil_effect"),action(){return!!ri($(this)[0])}},mana_syphon:{id:"tech-mana_syphon",title:z("tech_mana_syphon"),desc:z("tech_mana_syphon"),category:"magic",era:"interstellar",reqs:{veil:1},condition:()=>"magic"===t.race.universe,grant:["veil",2],cost:{Knowledge:()=>15e5},effect:z("tech_mana_syphon_effect"),action(){return!!ri($(this)[0])},post(){xe("Physics")}},gravitational_waves:{id:"tech-gravitational_waves",title:z("tech_gravitational_waves"),desc:z("tech_gravitational_waves"),category:"power_generation",era:"interstellar",reqs:{blackhole:4},grant:["gravity",1],cost:{Knowledge:()=>125e4},effect:z("tech_gravitational_waves_effect"),action(){return!!ri($(this)[0])}},gravity_convection:{id:"tech-gravity_convection",title:z("tech_gravity_convection"),desc:z("tech_gravity_convection"),category:"power_generation",era:"interstellar",reqs:{gravity:1},grant:["gravity",2],cost:{Knowledge:()=>135e4},effect:z("tech_gravity_convection_effect"),action(){return!!ri($(this)[0])}},wormholes:{id:"tech-wormholes",title:z("tech_wormholes"),desc:z("tech_wormholes"),category:"space_exploration",era:"intergalactic",reqs:{gravity:1,science:15},grant:["stargate",1],cost:{Knowledge:()=>225e4},effect:z("tech_wormholes_effect"),action(){return!!ri($(this)[0])}},portal:{id:"tech-portal",title:z("tech_portal"),desc:z("tech_portal_desc"),category:"hell_dimension",era:"interstellar",reqs:{wsc:1},grant:["portal",1],cost:{Knowledge:()=>5e5},effect:z("tech_portal_effect"),action(){return!!ri($(this)[0])}},fortifications:{id:"tech-fortifications",title:z("tech_fort"),desc:z("tech_fort_desc"),category:"hell_dimension",era:"interstellar",reqs:{portal:1},grant:["portal",2],cost:{Knowledge:()=>55e4,Stone:()=>1e6},effect:z("tech_fort_effect"),action(){return!!ri($(this)[0])&&(t.settings.showPortal=!0,t.settings.portal.fortress=!0,t.settings.msgFilters.hell.unlocked||(t.settings.msgFilters.hell.unlocked=!0,t.settings.msgFilters.hell.vis=!0),t.portal.fortress={threat:1e4,garrison:0,walls:100,repair:0,patrols:0,patrol_size:10,siege:999,notify:"Yes",s_ntfy:"Yes",nocrew:!1},t.portal.turret={count:0,on:0},t.portal.carport={count:0,damaged:0,repair:0},"demonic"===Ki[t.race.species].type?qn("blood_war"):qn("pandemonium"),t.portal.observe={settings:{expanded:!1,average:!1,hyperSlow:!1,display:"game_days",dropKills:!0,dropGems:!0},stats:{total:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}},period:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}}},graphID:0,graphs:{}},!0)},post(){Pa()}},war_drones:{id:"tech-war_drones",title:z("tech_war_drones"),desc:z("tech_war_drones"),category:"hell_dimension",era:"interstellar",reqs:{portal:2,graphene:1},grant:["portal",3],cost:{Knowledge:()=>7e5},effect:z("tech_war_drones_effect"),action(){return!!ri($(this)[0])&&(t.settings.portal.badlands=!0,t.portal.war_drone={count:0,on:0},!0)}},demon_attractor:{id:"tech-demon_attractor",title:z("tech_demon_attractor"),desc:z("tech_demon_attractor"),category:"hell_dimension",era:"interstellar",reqs:{portal:3,stanene:1},grant:["portal",4],cost:{Knowledge:()=>745e3},effect:z("tech_demon_attractor_effect"),action(){return!!ri($(this)[0])&&(t.portal.attractor={count:0,on:0},!0)}},combat_droids:{id:"tech-combat_droids",title:z("tech_combat_droids"),desc:z("tech_combat_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:4},grant:["portal",5],cost:{Knowledge:()=>762e3,Soul_Gem:()=>1},effect:z("tech_combat_droids_effect"),action(){return!!ri($(this)[0])&&(t.portal.war_droid={count:0,on:0},!0)},flair:()=>z("tech_combat_droids_flair")},repair_droids:{id:"tech-repair_droids",title:z("tech_repair_droids"),desc:z("tech_repair_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:5},grant:["portal",6],cost:{Knowledge:()=>794e3,Soul_Gem:()=>1},effect:z("tech_repair_droids_effect"),action(){return!!ri($(this)[0])&&(t.portal.repair_droid={count:0,on:0},!0)}},advanced_predators:{id:"tech-advanced_predators",title:z("tech_advanced_predators"),desc:z("tech_advanced_predators"),category:"hell_dimension",era:"intergalactic",reqs:{portal:6,xeno:4},grant:["portal",7],cost:{Knowledge:()=>5e6,Bolognium:()=>5e5,Vitreloy:()=>25e4},effect:z("tech_advanced_predators_effect"),action(){return!!ri($(this)[0])}},enhanced_droids:{id:"tech-enhanced_droids",title:z("tech_enhanced_droids"),desc:z("tech_enhanced_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:5,military:9},grant:["hdroid",1],cost:{Knowledge:()=>105e4},effect:z("tech_enhanced_droids_effect"),action(){return!!ri($(this)[0])}},sensor_drone:{id:"tech-sensor_drone",title:z("tech_sensor_drone"),desc:z("tech_sensor_drone"),category:"hell_dimension",era:"interstellar",reqs:{portal:3,infernite:1,stanene:1,graphene:1},grant:["infernite",2],cost:{Knowledge:()=>725e3},effect:z("tech_sensor_drone_effect"),action(){return!!ri($(this)[0])&&(t.portal.sensor_drone={count:0,on:0},!0)}},map_terrain:{id:"tech-map_terrain",title:z("tech_map_terrain"),desc:z("tech_map_terrain"),category:"hell_dimension",era:"interstellar",reqs:{infernite:2},grant:["infernite",3],cost:{Knowledge:()=>948e3},effect:()=>z("tech_map_terrain_effect"),action(){return!!ri($(this)[0])}},calibrated_sensors:{id:"tech-calibrated_sensors",title:z("tech_calibrated_sensors"),desc:z("tech_calibrated_sensors"),category:"hell_dimension",era:"interstellar",reqs:{infernite:3},grant:["infernite",4],cost:{Knowledge:()=>1125e3,Infernite:()=>3500},effect:()=>z("tech_calibrated_sensors_effect"),action(){return!!ri($(this)[0])}},shield_generator:{id:"tech-shield_generator",title:z("tech_shield_generator"),desc:z("tech_shield_generator"),category:"hell_dimension",era:"intergalactic",reqs:{high_tech:14,gateway:3,infernite:4},grant:["infernite",5],cost:{Knowledge:()=>268e4,Bolognium:()=>75e3},effect:()=>z("tech_shield_generator_effect"),action(){return!!ri($(this)[0])}},enhanced_sensors:{id:"tech-enhanced_sensors",title:z("tech_enhanced_sensors"),desc:z("tech_enhanced_sensors"),category:"hell_dimension",era:"intergalactic",reqs:{infernite:5,xeno:4},grant:["infernite",6],cost:{Knowledge:()=>475e4,Vitreloy:()=>25e3},effect:()=>z("tech_enhanced_sensors_effect"),action(){return!!ri($(this)[0])}},xeno_linguistics:{id:"tech-xeno_linguistics",title:z("tech_xeno_linguistics"),desc:z("tech_xeno_linguistics"),category:"andromeda",era:"intergalactic",reqs:{xeno:1},grant:["xeno",2],cost:{Knowledge:()=>3e6},effect:()=>z("tech_xeno_linguistics_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.gorddon=!0,!0)}},xeno_culture:{id:"tech-xeno_culture",title:z("tech_xeno_culture"),desc:z("tech_xeno_culture"),category:"progress",era:"intergalactic",reqs:{xeno:3},grant:["xeno",4],cost:{Knowledge:()=>34e5},effect:()=>z("tech_xeno_culture_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name,Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].entity]),action(){return!!ri($(this)[0])&&(t.galaxy.embassy={count:0,on:0},!0)}},cultural_exchange:{id:"tech-cultural_exchange",title:z("tech_cultural_exchange"),desc:z("tech_cultural_exchange"),category:"andromeda",era:"intergalactic",reqs:{xeno:5},grant:["xeno",6],cost:{Knowledge:()=>355e4},effect:()=>z("tech_cultural_exchange_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!ri($(this)[0])&&(t.galaxy.symposium={count:0,on:0},t.galaxy.dormitory={count:0,on:0},!0)}},shore_leave:{id:"tech-shore_leave",title:z("tech_shore_leave"),desc:z("tech_shore_leave"),category:"science",era:"intergalactic",reqs:{andromeda:3,xeno:6},grant:["xeno",7],cost:{Knowledge:()=>46e5},effect:()=>z("tech_shore_leave_effect"),action(){return!!ri($(this)[0])}},xeno_gift:{id:"tech-xeno_gift",title:z("tech_xeno_gift"),desc:z("tech_xeno_gift"),category:"andromeda",era:"intergalactic",reqs:{high_tech:16,xeno:7},grant:["xeno",8],cost:{Knowledge:()=>65e5,Infernite:()=>125e3},effect:()=>z("tech_xeno_gift_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.consulate={count:0},t.settings.space.alien1=!0,hs(z("tech_xeno_gift_msg",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),"info",!1,["progress"]),!0)}},industrial_partnership:{id:"tech-industrial_partnership",title:z("tech_industrial_partnership"),desc:()=>z("tech_industrial_partnership"),category:"andromeda",era:"intergalactic",reqs:{xeno:9},grant:["xeno",10],cost:{Knowledge:()=>725e4},effect:()=>z("tech_industrial_partnership_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!ri($(this)[0])&&(t.galaxy.vitreloy_plant={count:0,on:0},!0)}},embassy_housing:{id:"tech-embassy_housing",title:z("tech_embassy_housing"),desc:()=>z("tech_embassy_housing"),category:"andromeda",era:"intergalactic",reqs:{xeno:10,science:18},grant:["xeno",11],cost:{Knowledge:()=>1075e4},effect:()=>z("tech_embassy_housing_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!ri($(this)[0])}},advanced_telemetry:{id:"tech-advanced_telemetry",title:z("tech_advanced_telemetry"),desc:z("tech_advanced_telemetry"),category:"science",era:"intergalactic",reqs:{xeno:5},grant:["telemetry",1],cost:{Knowledge:()=>42e5,Vitreloy:()=>1e4},effect:()=>z("tech_advanced_telemetry_effect"),action(){return!!ri($(this)[0])}},defense_platform:{id:"tech-defense_platform",title:z("galaxy_defense_platform"),desc:z("galaxy_defense_platform"),category:"andromeda",era:"intergalactic",reqs:{stargate:5,piracy:1},grant:["stargate",6],cost:{Knowledge:()=>485e4},effect:z("tech_defense_platform_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.defense_platform={count:0,on:0},!0)}},scout_ship:{id:"tech-scout_ship",title:z("galaxy_scout_ship"),desc:z("galaxy_scout_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{gateway:3},grant:["andromeda",1],cost:{Knowledge:()=>26e5},effect:()=>z("tech_scout_ship_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.scout_ship={count:0,on:0,crew:0,mil:0},!0)}},corvette_ship:{id:"tech-corvette_ship",title:z("galaxy_corvette_ship"),desc:z("galaxy_corvette_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:1,xeno:1},grant:["andromeda",2],cost:{Knowledge:()=>32e5},effect:()=>z("tech_corvette_ship_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.corvette_ship={count:0,on:0,crew:0,mil:0},!0)}},frigate_ship:{id:"tech-frigate_ship",title:z("galaxy_frigate_ship"),desc:z("galaxy_frigate_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:2,xeno:6},grant:["andromeda",3],cost:{Knowledge:()=>4e6},effect:()=>z("tech_frigate_ship_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.frigate_ship={count:0,on:0,crew:0,mil:0},Lt(),!0)}},cruiser_ship:{id:"tech-cruiser_ship",title:z("galaxy_cruiser_ship"),desc:z("galaxy_cruiser_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:3,xeno:10},grant:["andromeda",4],cost:{Knowledge:()=>75e5},effect:()=>z("tech_cruiser_ship_effect",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),action(){return!!ri($(this)[0])&&(t.galaxy.cruiser_ship={count:0,on:0,crew:0,mil:0},t.galaxy.foothold={count:0,on:0,support:0,s_max:0},t.settings.space.alien2=!0,Lt(),!0)}},dreadnought:{id:"tech-dreadnought",title:z("galaxy_dreadnought"),desc:z("galaxy_dreadnought"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:4,science:18},grant:["andromeda",5],cost:{Knowledge:()=>1e7},effect:()=>z("tech_dreadnought_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.dreadnought={count:0,on:0,crew:0,mil:0},Lt(),!0)}},ship_dock:{id:"tech-ship_dock",title:z("galaxy_ship_dock"),desc:z("galaxy_ship_dock"),category:"andromeda_ships",era:"intergalactic",reqs:{gateway:3,xeno:6},grant:["gateway",4],cost:{Knowledge:()=>39e5},effect:()=>z("tech_ship_dock_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.ship_dock={count:0,on:0},!0)}},ore_processor:{id:"tech-ore_processor",title:z("galaxy_ore_processor"),desc:z("galaxy_ore_processor"),category:"space_mining",era:"intergalactic",reqs:{conflict:2},grant:["conflict",3],cost:{Knowledge:()=>75e5},effect:()=>z("tech_ore_processor_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.ore_processor={count:0,on:0},!0)}},scavenger:{id:"tech-scavenger",title:z("galaxy_scavenger"),desc:z("galaxy_scavenger"),category:"science",era:"intergalactic",reqs:{conflict:3},grant:["conflict",4],cost:{Knowledge:()=>8e6},effect:()=>z("tech_scavenger_effect",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),action(){return!!ri($(this)[0])&&(t.galaxy.scavenger={count:0,on:0,crew:0},!0)}},coordinates:{id:"tech-coordinates",title:z("tech_coordinates"),desc:z("tech_coordinates"),category:"andromeda",era:"intergalactic",reqs:{science:18,conflict:5},grant:["chthonian",1],cost:{Knowledge:()=>1e7},effect:()=>z("tech_coordinates_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.minelayer={count:0,on:0,crew:0,mil:0},t.settings.space.chthonian=!0,!0)}},chthonian_survey:{id:"tech-chthonian_survey",title:z("tech_chthonian_survey"),desc:z("tech_chthonian_survey"),category:"space_mining",era:"intergalactic",reqs:{chthonian:2},grant:["chthonian",3],cost:{Knowledge:()=>118e5},effect:()=>z("tech_chthonian_survey_effect"),action(){return!!ri($(this)[0])&&(t.resource.Orichalcum.display=!0,t.galaxy.excavator={count:0,on:0},t.galaxy.raider={count:0,on:0,crew:0,mil:0},hs(z("tech_chthonian_survey_result"),"info",!1,["progress"]),!0)},post(){cs()}},gateway_depot:{id:"tech-gateway_depot",title:z("galaxy_gateway_depot"),desc:z("galaxy_gateway_depot"),category:"storage",era:"intergalactic",reqs:{gateway:4},grant:["gateway",5],cost:{Knowledge:()=>435e4},effect:()=>z("tech_gateway_depot_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.gateway_depot={count:0,on:0},!0)}},soul_forge:{id:"tech-soul_forge",title:z("portal_soul_forge_title"),desc:z("portal_soul_forge_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:3},grant:["hell_pit",4],cost:{Knowledge:()=>275e4},effect:()=>z("tech_soul_forge_effect"),action(){return!!ri($(this)[0])&&(t.portal.soul_forge={count:0,on:0,kills:0},!0)}},soul_attractor:{id:"tech-soul_attractor",title:z("portal_soul_attractor_title"),desc:z("portal_soul_attractor_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:4,high_tech:16},grant:["hell_pit",5],cost:{Knowledge:()=>55e5},effect:()=>z("tech_soul_attractor_effect"),action(){return!!ri($(this)[0])&&(t.portal.soul_attractor={count:0,on:0},!0)}},soul_absorption:{id:"tech-soul_absorption",title:z("tech_soul_absorption"),desc:z("tech_soul_absorption"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:5},grant:["hell_pit",6],cost:{Knowledge:()=>6e6,Infernite:()=>25e4},effect:()=>z("tech_soul_absorption_effect"),action(){return!!ri($(this)[0])}},soul_link:{id:"tech-soul_link",title:z("tech_soul_link"),desc:z("tech_soul_link"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:6},grant:["hell_pit",7],cost:{Knowledge:()=>75e5,Vitreloy:()=>25e4},effect:()=>z("tech_soul_link_effect"),action(){return!!ri($(this)[0])}},gun_emplacement:{id:"tech-gun_emplacement",title:z("portal_gun_emplacement_title"),desc:z("portal_gun_emplacement_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:4},grant:["hell_gun",1],cost:{Knowledge:()=>3e6},effect:()=>z("tech_gun_emplacement_effect"),action(){return!!ri($(this)[0])&&(t.portal.gun_emplacement={count:0,on:0},!0)}},advanced_emplacement:{id:"tech-advanced_emplacement",title:z("tech_advanced_emplacement"),desc:z("tech_advanced_emplacement"),category:"hell_dimension",era:"intergalactic",reqs:{hell_gun:1,high_tech:17},grant:["hell_gun",2],cost:{Knowledge:()=>125e5,Orichalcum:()=>18e4},effect:()=>z("tech_advanced_emplacement_effect"),action(){return!!ri($(this)[0])}},dial_it_to_11:{id:"tech-dial_it_to_11",title:z("tech_dial_it_to_11"),desc:z("tech_dial_it_to_11"),category:"science",wiki:!1,era:"deep_space",reqs:{quaked:1},grant:["quaked",2],cost:{Knowledge:()=>5e5},condition:()=>!(t.race.sludge&&!t.race.cataclysm),effect(){let e=Gs("cataclysm"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                ${z("tech_dial_it_to_11_effect",[Ut().dwarf,t.race.cataclysm?Ut().red:Ki[t.race.species].home])}
                ${z("tech_dial_it_to_11_effect2")}
                ${z("star_dock_genesis_effect2",[e.plasmid,a])}
                ${z("star_dock_genesis_effect3",[e.phage])}
                `},action(){return!!ri($(this)[0])&&($("#main").addClass("earthquake"),setTimeout((function(){$("#main").removeClass("earthquake"),function(){if(t.city.ptrait.includes("unstable")&&t.tech.quaked){P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),ks("reset",{end:"cataclysm"}),O();let a=Gs("cataclysm");t.stats.cataclysm++,rn(),t.prestige.Phage.count+=a.phage,t.stats.phage+=a.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=a.plasmid,t.stats.antiplasmid+=a.plasmid):(t.prestige.Plasmid.count+=a.plasmid,t.stats.plasmid+=a.plasmid),qn("squished",!0),qn(`extinct_${t.race.species}`),"hellscape"===t.city.biome&&"demonic"!==Ki[t.race.species].type&&Pn("take_no_advice"),Sn(),qn("shaken"),t.race.cataclysm&&qn("failed_history");let r=!!t.race.hasOwnProperty("srace")&&t.race.srace,i=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:t.race.species,gods:t.race.gods,old_gods:t.race.old_gods,universe:t.race.universe,seeded:!1,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},i>0&&(t.race.corruption=i),r&&(t.race.srace=r),H({orbit:t.city.calendar.orbit,biome:t.city.biome,ptrait:t.city.ptrait,geology:t.city.geology}),"antimatter"===t.race.universe?t.race.weak_mastery=1:t.race.no_plasmid=1;let s=["crispr","trade","craft"];for(let e=0;ez("tech_dial_it_to_11_flair")},limit_collider:{id:"tech-limit_collider",title:z("tech_limit_collider"),desc:z("tech_limit_collider"),category:"science",wiki:!1,era:"deep_space",reqs:{quaked:1},grant:["quaked",2],cost:{Knowledge:()=>5e5},effect:()=>z("tech_limit_collider_effect"),action(){return!!ri($(this)[0])}},mana:{id:"tech-mana",title:z("tech_mana"),desc:z("tech_mana"),category:"magic",era:"civilized",reqs:{primitive:3},grant:["magic",1],condition:()=>"magic"===t.race.universe,cost:{Knowledge:()=>25},effect:()=>z("tech_mana_effect"),action(){return!!ri($(this)[0])&&(t.resource.Mana.display=!0,t.resource.Crystal.display=!0,t.civic.crystal_miner.display=!0,t.race.witch_hunter&&(t.resource.Sus.display=!0),!0)},flair:z("tech_mana_flair"),post(){cs()}},ley_lines:{id:"tech-ley_lines",title:z("tech_ley_lines"),desc:z("tech_ley_lines"),category:"magic",era:"civilized",reqs:{magic:1},grant:["magic",2],condition:()=>"magic"===t.race.universe,cost:{Knowledge:()=>40},effect:()=>z("tech_ley_lines_effect"),action(){return!!ri($(this)[0])&&(t.tech.isolation?t.tauceti.pylon={count:0}:t.race.cataclysm||t.race.orbit_decayed?t.space.pylon={count:0}:t.city.pylon={count:0},!0)}},rituals:{id:"tech-rituals",title:z("tech_rituals"),desc:z("tech_rituals"),category:"magic",era:"civilized",reqs:{magic:2},grant:["magic",3],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>25,Knowledge:()=>750,Crystal:()=>50},effect:()=>z("tech_rituals_effect"),action(){return!!ri($(this)[0])&&(t.race.casting={farmer:0,miner:0,lumberjack:0,science:0,factory:0,army:0,hunting:0,crafting:0,total:0},t.settings.showIndustry=!0,!0)},post(){ki()}},crafting_ritual:{id:"tech-crafting_ritual",title:z("tech_crafting_ritual"),desc:z("tech_crafting_ritual"),category:"magic",era:"discovery",reqs:{magic:3,foundry:5},grant:["magic",4],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>100,Knowledge:()=>15e3,Crystal:()=>2500},effect:()=>z("tech_crafting_ritual_effect"),action(){return!!ri($(this)[0])&&(t.race.casting.crafting=0,!0)},post(){ki()}},mana_nexus:{id:"tech-mana_nexus",title:z("tech_mana_nexus"),desc:z("tech_mana_nexus"),category:"magic",era:"early_space",reqs:{magic:4,space:3,luna:1},grant:["magic",5],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>500,Knowledge:()=>16e4,Crystal:()=>2500},effect:()=>z("tech_mana_nexus_effect"),action(){return!!ri($(this)[0])},post(){xe("Physics")}},clerics:{id:"tech-clerics",title:z("tech_clerics"),desc:z("tech_clerics"),category:"magic",era:"civilized",reqs:{magic:3},grant:["cleric",1],condition:()=>!!("magic"===t.race.universe&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display),cost:{Mana:()=>100,Knowledge:()=>2e3,Crystal:()=>100},effect:()=>z("tech_clerics_effect"),action(){return!!ri($(this)[0])}},conjuring:{id:"tech-conjuring",title:z("tech_conjuring"),desc:z("tech_conjuring_desc"),category:"magic",era:"civilized",reqs:{magic:1},grant:["conjuring",1],not_trait:["cataclysm"],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>2,Crystal:()=>5},effect:()=>z("tech_conjuring_effect"),action(){return!!ri($(this)[0])}},res_conjuring:{id:"tech-res_conjuring",title:z("tech_res_conjuring"),desc:z("tech_res_conjuring"),category:"magic",era:"civilized",reqs:{conjuring:1},grant:["conjuring",2],not_trait:["cataclysm"],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>5,Crystal:()=>10},effect:()=>z("tech_res_conjuring_effect"),action(){return!!ri($(this)[0])}},alchemy:{id:"tech-alchemy",title:z("tech_alchemy"),desc:z("tech_alchemy"),category:"magic",era:"discovery",reqs:{magic:3,high_tech:1},grant:["alchemy",1],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>100,Knowledge:()=>1e4,Crystal:()=>250},effect:()=>z("tech_alchemy_effect"),action(){return!!ri($(this)[0])&&(t.race.alchemy={Food:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0},t.settings.showAlchemy=!0,!0)},post(){Ss($("#resources")),Da(),t.settings.tabLoad&&Ka("alchemy")}},transmutation:{id:"tech-transmutation",title:z("tech_transmutation"),desc:z("tech_transmutation"),category:"magic",era:"intergalactic",reqs:{alchemy:1,high_tech:16},grant:["alchemy",2],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>1250,Knowledge:()=>55e5,Crystal:()=>1e6},effect:()=>z("tech_transmutation_effect"),action(){return!!ri($(this)[0])},post(){Ss($("#resources")),Da()}},secret_society:{id:"tech-secret_society",title:z("tech_secret_society"),desc:z("tech_secret_society"),category:"magic",era:"civilized",reqs:{magic:1},grant:["roguemagic",1],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>10,Knowledge:()=>45},effect:()=>z("tech_secret_society_effect"),action(){return!!ri($(this)[0])}},cultists:{id:"tech-cultists",title:z("tech_cultists"),desc:z("tech_cultists"),category:"magic",era:"civilized",reqs:{roguemagic:1,cleric:1},grant:["roguemagic",2],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>250,Knowledge:()=>2125},effect:()=>z("tech_cultists_effect"),action(){return!!ri($(this)[0])}},conceal_ward:{id:"tech-conceal_ward",title:z("tech_conceal_ward"),desc:z("tech_conceal_ward"),category:"magic",era:"discovery",reqs:{roguemagic:2,theatre:3},grant:["roguemagic",3],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>500,Knowledge:()=>8200,Crystal:()=>1e3},effect:()=>z("tech_conceal_ward_effect"),action(){return!!ri($(this)[0])&&(t.city.conceal_ward={count:0},t.space.conceal_ward={count:0},!0)}},subtle_rituals:{id:"tech-subtle_rituals",title:z("tech_subtle_rituals"),desc:z("tech_subtle_rituals"),category:"magic",era:"discovery",reqs:{roguemagic:3,magic:4},grant:["roguemagic",4],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>100,Knowledge:()=>15e3,Crystal:()=>2500},effect:()=>z("tech_subtle_rituals_effect"),action(){return!!ri($(this)[0])}},pylon_camouflage:{id:"tech-pylon_camouflage",title:z("tech_pylon_camouflage"),desc:z("tech_pylon_camouflage"),category:"magic",era:"industrialized",reqs:{roguemagic:4,high_tech:3},grant:["roguemagic",5],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>1e3,Knowledge:()=>3e4,Crystal:()=>3750},effect:()=>z("tech_pylon_camouflage_effect"),action(){return!!ri($(this)[0])}},fake_tech:{id:"tech-fake_tech",title:z("tech_fake_tech"),desc:z("tech_fake_tech"),category:"magic",era:"industrialized",reqs:{roguemagic:5,high_tech:4},grant:["roguemagic",6],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>2250,Knowledge:()=>6e4},effect:()=>z("tech_fake_tech_effect"),action(){return!!ri($(this)[0])}},concealment:{id:"tech-concealment",title:z("tech_concealment"),desc:z("tech_concealment"),category:"magic",era:"early_space",reqs:{roguemagic:6,magic:5},grant:["roguemagic",7],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>3e3,Knowledge:()=>185e3},effect:()=>z("tech_concealment_effect"),action(){return!!ri($(this)[0])}},improved_concealment:{id:"tech-improved_concealment",title:z("tech_improved_concealment"),desc:z("tech_improved_concealment"),category:"magic",era:"intergalactic",reqs:{roguemagic:7,forbidden:1},grant:["roguemagic",8],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>t.race.no_plasmid?6e3:25e3,Knowledge:()=>2e7},effect:()=>z("tech_improved_concealment_effect"),action(){return!!ri($(this)[0])}},outerplane_summon:{id:"tech-outerplane_summon",title:z("tech_outerplane_summon"),desc:z("tech_outerplane_summon"),category:"magic",era:"dimensional",reqs:{roguemagic:8,forbidden:4,hell_spire:10,b_stone:2,waygate:3},grant:["forbidden",5],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>t.race.no_plasmid?12e3:6e4,Knowledge:()=>6e7,Demonic_Essence:()=>1},effect:()=>z("tech_outerplane_summon_effect"),action(){return!!ri($(this)[0])}},dark_bomb:{id:"tech-dark_bomb",title:z("tech_dark_bomb"),desc:z("tech_dark_bomb"),category:"hell_dimension",era:"dimensional",reqs:{},reqs:{hell_spire:10,b_stone:2,waygate:2,sphinx_bribe:1},condition(){let e=xn();return!!(t.stats.spire.hasOwnProperty(e)&&t.stats.spire[e].hasOwnProperty("dlstr")&&t.stats.spire[e].dlstr>0)},grant:["dl_reset",1],cost:{Knowledge:()=>65e6,Soul_Gem:()=>5e3,Blood_Stone:()=>25,Dark:()=>1,Supply:()=>1e6},effect:()=>z("tech_dark_bomb_effect"),action(){return!!ri($(this)[0])&&(t.portal.waygate.progress=100,t.portal.waygate.on=0,t.tech.waygate=3,t.resource.Demonic_Essence.display=!0,t.resource.Demonic_Essence.amount=1,!0)},flair:()=>z("tech_dark_bomb_flair")},bribe_sphinx:{id:"tech-bribe_sphinx",title:z("portal_sphinx_bribe"),desc:z("portal_sphinx_bribe"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:8},grant:["sphinx_bribe",1],cost:{Soul_Gem:()=>250,Supply:()=>5e5},effect:()=>z("tech_bribe_sphinx_effect"),action(){return!!ri($(this)[0])&&(t.resource.Codex.display=!0,t.resource.Codex.amount=1,hs(z("tech_bribe_sphinx_msg"),"info",!1,["progress","hell"]),!0)}},alien_biotech:{id:"tech-alien_biotech",title:z("tech_alien_biotech"),desc:z("tech_alien_biotech"),category:"science",era:"solar",reqs:{genetics:8,kuiper:1},grant:["biotech",1],path:["truepath"],cost:{Knowledge:()=>24e5,Orichalcum:()=>125e3,Cipher:()=>15e3},effect:()=>z(t.race.orbit_decayed?"tech_alien_biotech_effect_alt":"tech_alien_biotech_effect"),action(){return!!ri($(this)[0])}},zero_g_lab:{id:"tech-zero_g_lab",title:z("tech_zero_g_lab"),desc:z("tech_zero_g_lab"),category:"science",era:"solar",path:["truepath"],reqs:{high_tech:13,graphene:1,enceladus:2},grant:["enceladus",3],cost:{Knowledge:()=>9e5},effect:z("tech_zero_g_lab_effect"),action(){return!!ri($(this)[0])&&(t.space.zero_g_lab={count:0,on:0},!0)}},operating_base:{id:"tech-operating_base",title:z("tech_operating_base"),desc:z("tech_operating_base"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{enceladus:3,triton:1},grant:["enceladus",4],cost:{Knowledge:()=>14e5},effect:()=>z("tech_operating_base_effect",[Ut().enceladus]),action(){return!!ri($(this)[0])&&(t.space.operating_base={count:0,on:0},!0)}},munitions_depot:{id:"tech-munitions_depot",title:z("tech_munitions_depot"),desc:z("tech_munitions_depot"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{enceladus:4},grant:["enceladus",5],cost:{Knowledge:()=>15e5},effect:()=>z("tech_munitions_depot_effect"),action(){return!!ri($(this)[0])&&(t.space.munitions_depot={count:0},!0)}},fob:{id:"tech-fob",title:z("tech_fob"),desc:z("tech_fob"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{triton:1},grant:["triton",2],cost:{Knowledge:()=>145e4},effect:()=>z("tech_fob_effect",[Ut().triton]),action(){return!!ri($(this)[0])&&(t.space.fob={count:0,on:0,troops:0,enemy:0},t.space.lander={count:0,on:0},t.space.crashed_ship={count:0},!0)}},bac_tanks_tp:{id:"tech-bac_tanks_tp",title:z("tech_bac_tanks"),desc:z("tech_bac_tanks_desc"),category:"military",era:"solar",path:["truepath"],reqs:{medic:1,triton:2},grant:["medic",2],cost:{Knowledge:()=>175e4},effect:z("tech_bac_tanks_effect"),action(){return!!ri($(this)[0])}},medkit:{id:"tech-medkit",title:z("tech_medkit"),desc:z("tech_medkit"),category:"military",era:"solar",path:["truepath"],reqs:{medic:2,outer:4},grant:["medic",3],cost:{Knowledge:()=>225e4,Quantium:()=>25e4,Cipher:()=>8e3},effect:z("tech_medkit_effect"),action(){return!!ri($(this)[0])}},sam_site:{id:"tech-sam_site",title:z("tech_sam_site"),desc:z("tech_sam_site"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{titan:6,triton:1},grant:["titan",7],cost:{Knowledge:()=>1475e3},effect:()=>z("tech_sam_site_effect",[Ut().titan]),action(){return!!ri($(this)[0])&&(t.space.sam={count:0,on:0},!0)}},data_cracker:{id:"tech-data_cracker",title:z("tech_data_cracker"),desc:z("tech_data_cracker"),category:"science",era:"solar",path:["truepath"],reqs:{titan:7,kuiper:1},grant:["titan",8],cost:{Knowledge:()=>275e4,Cipher:()=>25e3},effect:()=>z("tech_data_cracker_effect",[t.resource.Cipher.name]),action(){return!!ri($(this)[0])&&(t.space.decoder={count:0,on:0},!0)}},ai_core_tp:{id:"tech-ai_core_tp",title:z("tech_ai_core"),desc:z("tech_ai_core"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan:8},grant:["titan",9],cost:{Knowledge:()=>3e6,Cipher:()=>1e5},effect:z("tech_ai_core_effect"),action(){return!!ri($(this)[0])&&(t.space.ai_core={count:0},!0)}},ai_optimizations:{id:"tech-ai_optimizations",title:z("tech_ai_optimizations"),desc:z("tech_ai_optimizations"),category:"ai_core",era:"solar",path:["truepath"],reqs:{eris:3,titan:9,titan_ai_core:1,dig_control:1},grant:["titan_ai_core",2],cost:{Knowledge:()=>375e4,Cipher:()=>75e3},effect:z("tech_ai_optimizations_effect"),action(){return!!ri($(this)[0])},class:"synth"},synthetic_life:{id:"tech-synthetic_life",title:z("tech_synthetic_life"),desc:z("tech_synthetic_life"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:2},grant:["titan_ai_core",3],cost:{Knowledge:()=>4e6,Cipher:()=>75e3},effect:z("tech_synthetic_life_effect"),action(){return!!ri($(this)[0])&&(t.space.ai_colonist={count:0,on:0},!0)},class:"synth"},protocol66:{id:"tech-protocol66",title:z("tech_protocol66"),desc:z("tech_protocol66"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:3,corrupted_ai:1},grant:["corrupted_ai",2],cost:{Knowledge:()=>5e6},effect:z("tech_protocol66_effect"),action(){return!!ii($(this)[0])},flair:z("tech_protocol66_flair"),class:"synth"},protocol66a:{id:"tech-protocol66a",title:z("tech_protocol66"),desc:z("tech_protocol66"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:3,corrupted_ai:2},wiki:!1,grant:["corrupted_ai",3],cost:{Knowledge:()=>5e6},effect(){let e=Gs("ai"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name"),r=`
                ${z("tech_protocol66a_effect_gains",[e.plasmid,a,e.phage,e.cores])}
                `;return`
                ${z("tech_protocol66a_effect")}
                ${r}`},action(){return!!ri($(this)[0])&&(P.w&&P.w.terminate(),_s(),$("body").append('
                '),$("#aiAppoc").addClass("noise-wrapper"),$("#aiAppoc > div").addClass("noise"),setTimeout((function(){$("body").append('
                '),$("body").append('
                '),$("#deadAirTop").animate({height:"50%",opacity:1},400),$("#deadAirBottom").animate({height:"50%",opacity:1},400)}),3e3),setTimeout((function(){!function(){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"ai apocalypse"}),qn(`extinct_${t.race.species}`),qn("obsolete"),qn("squished",!0),t.race.junker&&"junker"===t.race.species&&Pn("the_misery");let a=t.race.species,r=t.race.gods,i=t.city.calendar.orbit,s=t.city.biome,n=t.city.ptrait,c=t.city.geology,o=Gs("ai");Sn(),t.stats.aiappoc++,rn(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),t.prestige.AICore.count+=o.cores,t.stats.cores+=o.cores;let l="synthetic"!==Ki[a].type?a:t.race.hasOwnProperty("srace")?t.race.srace:a;t.stats.synth[l]=!0;let _=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,srace:l,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},_>0&&(t.race.corruption=_),H({orbit:i,biome:s,ptrait:n,geology:c}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),4e3),!0)},flair:z("tech_protocol66a_flair"),class:"synth"},terraforming_tp:{id:"tech-terraforming_tp",title:z("tech_terraforming"),desc:z("tech_terraforming"),category:"special",era:"solar",reqs:{dig_control:1,eris:2,titan_ai_core:2},path:["truepath"],grant:["terraforming",1],trait:["orbit_decay"],cost:{Knowledge:()=>5e6},effect:()=>z("tech_terraforming_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.terraformer={count:0},!0)}},quantium:{id:"tech-quantium",title:z("tech_quantium"),desc:z("tech_quantium"),category:"crafting",era:"solar",path:["truepath"],reqs:{supercollider:10,enceladus:3},grant:["quantium",1],cost:{Knowledge:()=>1e6,Elerium:()=>1e3,Nano_Tube:()=>1e6,Graphene:()=>1e6},effect:z("tech_quantium_effect"),action(){return!!ri($(this)[0])&&(t.resource.Quantium.display=!0,!0)},post(){cs()}},anitgrav_bunk:{id:"tech-anitgrav_bunk",title:z("tech_anitgrav_bunk"),desc:z("tech_anitgrav_bunk"),category:"military",era:"solar",path:["truepath"],reqs:{marines:1,quantium:1},grant:["marines",2],cost:{Knowledge:()=>125e4,Quantium:()=>5e5},effect:()=>z("tech_anitgrav_bunk_effect",[z("space_red_space_barracks_title")]),action(){return!!ri($(this)[0])}},higgs_boson_tp:{id:"tech-higgs_boson_tp",title:z("tech_higgs_boson"),desc:z("tech_higgs_boson"),category:"science",era:"early_space",path:["truepath"],reqs:{supercollider:2},grant:["tp_particles",1],cost:{Knowledge:()=>125e3},effect:z("tech_higgs_boson_effect"),action(){return!!ri($(this)[0])}},long_range_probes:{id:"tech-long_range_probes",title:z("tech_long_range_probes"),desc:z("tech_long_range_probes"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{high_tech:10,elerium:1},grant:["outer",1],cost:{Knowledge:()=>4e5,Uranium:()=>2e4,Iridium:()=>25e4,Neutronium:()=>3e3,Elerium:()=>350},effect:z("tech_long_range_probes_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.titan=!0,t.settings.space.enceladus=!0,t.space.titan_spaceport={count:0,on:0,support:0,s_max:0},t.space.electrolysis={count:0,on:0,support:0,s_max:0},!0)}},strange_signal:{id:"tech-strange_signal",title:z("tech_strange_signal"),desc:z("tech_strange_signal"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:1,syard_sensor:4},grant:["outer",2],cost:{Knowledge:()=>135e4},effect:z("tech_strange_signal_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.triton=!0,!0)}},data_analysis:{id:"tech-data_analysis",title:z("tech_data_analysis"),desc:z("tech_data_analysis"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:3},grant:["outer",4],cost:{Knowledge:()=>18e5,Cipher:()=>12500},effect:z("tech_data_analysis_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_data_analysis_result"),"info",!1,["progress"]),t.space.syndicate.spc_titan+=500,t.space.syndicate.spc_enceladus+=250,t.space.syndicate.spc_triton+=1e3,!0)}},mass_relay:{id:"tech-mass_relay",title:z("tech_mass_relay"),desc:z("tech_mass_relay"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:4},grant:["outer",5],cost:{Knowledge:()=>22e5,Cipher:()=>4e4},effect:z("tech_mass_relay_effect"),action(){return!!ri($(this)[0])&&(t.space.mass_relay={count:0},!0)}},nav_data:{id:"tech-nav_data",title:z("tech_nav_data"),desc:z("tech_nav_data"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:6},grant:["outer",7],cost:{Knowledge:()=>225e4,Cipher:()=>6e4},effect:z("tech_nav_data_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.eris=!0,t.settings.space.kuiper=!0,t.tech.eris_scan=0,t.space.drone_control={count:0,on:0,support:0,s_max:0},hs(z("tech_nav_data_result",[Ut().eris]),"info",!1,["progress"]),!0)}},sensor_logs:{id:"tech-sensor_logs",title:z("tech_sensor_logs"),desc:z("tech_sensor_logs"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:7},grant:["outer",8],cost:{Knowledge:()=>35e5,Cipher:()=>65e3},effect:z("tech_sensor_logs_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_sensor_logs_result"),"info",!1,["progress"]),!0)}},dronewar:{id:"tech-dronewar",title:z("tech_dronewar"),desc:z("tech_dronewar"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{eris:2,titan_ai_core:1},grant:["eris",3],cost:{Knowledge:()=>32e5,Cipher:()=>25e3},effect:()=>z("tech_dronewar_effect",[Ut().eris]),action(){return!!ri($(this)[0])&&(t.space.shock_trooper={count:0,on:0},t.space.digsite={count:0,enemy:1e4},!0)}},drone_tank:{id:"tech-drone_tank",title:z("tech_drone_tank"),desc:z("tech_drone_tank"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{eris:3},grant:["eris",4],cost:{Knowledge:()=>34e5,Cipher:()=>5e4},effect:z("tech_drone_tank_effect"),action(){return!!ri($(this)[0])&&(t.space.tank={count:0,on:0},!0)}},stanene_tp:{id:"tech-stanene_tp",title:z("tech_stanene"),desc:z("tech_stanene"),category:"crafting",era:"solar",path:["truepath"],reqs:{titan:1,enceladus:1},grant:["stanene",1],cost:{Knowledge:()=>525e3,Aluminium:()=>5e5,Nano_Tube:()=>1e5},effect:z("tech_stanene_effect"),action(){return!!ri($(this)[0])&&(t.resource.Stanene.display=!0,hs(z("tech_stanene_avail"),"info",!1,["progress"]),!0)},post(){ki(),cs()}},graphene_tp:{id:"tech-graphene_tp",title:z("tech_graphene"),desc:z("tech_graphene"),category:"crafting",era:"solar",path:["truepath"],reqs:{titan:5},grant:["graphene",1],cost:{Knowledge:()=>64e4,Adamantite:()=>25e3},effect:z("tech_graphene_effect"),action(){return!!ri($(this)[0])&&(t.space.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},!0)}},virtual_reality_tp:{id:"tech-virtual_reality_tp",title:z("tech_virtual_reality"),desc:z("tech_virtual_reality"),category:"progress",era:"solar",path:["truepath"],reqs:{high_tech:11,titan:4,stanene:1},grant:["high_tech",12],cost:{Knowledge:()=>616e3,Nano_Tube:()=>1e6,Stanene:()=>125e3},effect:z("tech_virtual_reality_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_virtual_reality_flair")},electrolysis:{id:"tech-electrolysis",title:z("tech_electrolysis"),desc:z("tech_electrolysis"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:2,enceladus:1},grant:["titan",3],cost:{Knowledge:()=>465e3},effect:()=>z("tech_electrolysis_effect",[Ut().titan,t.resource.Water.name]),action(){return!!ri($(this)[0])&&(t.space.titan_quarters={count:0,on:0},t.space.titan_mine={count:0,on:0,ratio:90},!0)}},storehouse:{id:"tech-storehouse",title:()=>z("tech_storehouse",[Ut().titan]),desc:()=>z("tech_storehouse",[Ut().titan]),category:"storage",era:"solar",path:["truepath"],reqs:{titan:4},grant:["titan",5],cost:{Knowledge:()=>5e5},effect:()=>z("tech_storehouse_effect",[Ut().titan]),action(){return!!ri($(this)[0])&&(t.space.storehouse={count:0},!0)}},adamantite_vault_tp:{id:"tech-adamantite_vault_tp",title:z("tech_adamantite_vault"),desc:z("tech_adamantite_vault"),category:"banking",era:"solar",path:["truepath"],reqs:{vault:2,titan:4},grant:["vault",3],cost:{Money:()=>2e6,Knowledge:()=>56e4,Adamantite:()=>2e4},effect:z("tech_adamantite_vault_effect"),action(){return!!ri($(this)[0])}},titan_bank:{id:"tech-titan_bank",title:()=>z("tech_titan_bank",[Ut().titan]),desc:()=>z("tech_titan_bank",[Ut().titan]),category:"storage",era:"solar",path:["truepath"],reqs:{titan:5},grant:["titan",6],cost:{Knowledge:()=>6e5},effect:()=>z("tech_titan_bank_effect",[Ut().titan]),action(){return!!ri($(this)[0])&&(t.space.titan_bank={count:0},!0)}},hydrogen_plant:{id:"tech-hydrogen_plant",title:z("tech_hydrogen_plant"),desc:z("tech_hydrogen_plant"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:4,stanene:1},grant:["titan_power",1],cost:{Knowledge:()=>55e4},effect:()=>z("tech_hydrogen_plant_effect"),action(){return!!ri($(this)[0])&&(t.space.hydrogen_plant={count:0,on:0},!0)}},water_mining:{id:"tech-water_mining",title:z("tech_water_mining"),desc:z("tech_water_mining"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:2,enceladus:1},grant:["enceladus",2],cost:{Knowledge:()=>45e4},effect:()=>z("tech_water_mining_effect",[Ut().enceladus,Ki[t.race.species].home,t.resource.Water.name]),action(){return!!ri($(this)[0])&&(t.space.water_freighter={count:0,on:0},!0)}},mercury_smelting:{id:"tech-mercury_smelting",title:z("tech_mercury_smelting"),desc:z("tech_mercury_smelting"),category:"mining",era:"solar",path:["truepath"],reqs:{hell:1,titan:4,smelting:6},grant:["m_smelting",1],cost:{Knowledge:()=>625e3,Adamantite:()=>5e4},effect:()=>z("tech_mercury_smelting_effect",[Ut().hell]),action(){return!!ri($(this)[0])&&(t.space.hell_smelter={count:0},!0)}},iridium_smelting:{id:"tech-iridium_smelting",title:z("tech_iridium_smelting"),desc:z("tech_iridium_smelting"),category:"mining",era:"solar",path:["truepath"],reqs:{m_smelting:1,graphene:1},grant:["m_smelting",2],cost:{Knowledge:()=>825e3,Graphene:()=>125e3},effect:z("tech_iridium_smelting_effect"),action(){return!!ri($(this)[0])}},adamantite_crates:{id:"tech-adamantite_crates",title:z("tech_adamantite_crates"),desc:z("tech_adamantite_crates_desc"),category:"storage",era:"solar",path:["truepath"],reqs:{container:5,titan:4},grant:["container",6],cost:{Knowledge:()=>525e3,Adamantite:()=>12500},effect:z("tech_adamantite_crates_effect"),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},bolognium_crates_tp:{id:"tech-bolognium_crates_tp",title:()=>z("tech_crates",[t.resource.Bolognium.name]),desc:()=>z("tech_crates",[t.resource.Bolognium.name]),category:"storage",era:"tauceti",path:["truepath"],reqs:{container:7,tauceti:4},grant:["container",8],cost:{Knowledge:()=>616e4,Bolognium:()=>75e4},effect:()=>z("tech_bolognium_crates_effect",[t.resource.Bolognium.name]),action(){return!!ri($(this)[0])}},adamantite_containers_tp:{id:"tech-adamantite_containers_tp",title:()=>z("tech_containers",[t.resource.Adamantite.name]),desc:()=>z("tech_adamantite_containers_desc",[t.resource.Adamantite.name]),category:"storage",era:"solar",path:["truepath"],reqs:{steel_container:4,titan:4},grant:["steel_container",5],cost:{Knowledge:()=>575e3,Adamantite:()=>17500},effect:()=>z("tech_adamantite_containers_effect",[t.resource.Adamantite.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},quantium_containers:{id:"tech-quantium_containers",title:()=>z("tech_containers",[t.resource.Quantium.name]),desc:()=>z("tech_containers",[t.resource.Quantium.name]),category:"storage",era:"solar",path:["truepath"],reqs:{steel_container:5,quantium:1},grant:["steel_container",6],cost:{Knowledge:()=>115e4,Quantium:()=>1e5},effect:()=>z("tech_quantium_containers_effect",[t.resource.Quantium.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},unobtainium_containers:{id:"tech-unobtainium_containers",title:()=>z("tech_containers",[t.resource.Unobtainium.name]),desc:()=>z("tech_containers",[t.resource.Unobtainium.name]),category:"storage",era:"tauceti",path:["truepath"],reqs:{steel_container:6,tau_red:7},grant:["steel_container",7],cost:{Knowledge:()=>725e4,Unobtainium:()=>7500},effect:()=>z("tech_bolognium_containers_effect",[t.resource.Unobtainium.name]),action(){return!!ri($(this)[0])}},reinforced_shelving:{id:"tech-reinforced_shelving",title:z("tech_reinforced_shelving"),desc:z("tech_reinforced_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{graphene:1,titan:5},grant:["shelving",1],cost:{Knowledge:()=>85e4,Adamantite:()=>35e4,Graphene:()=>25e4},effect:z("tech_reinforced_shelving_effect"),action(){return!!ri($(this)[0])}},garage_shelving:{id:"tech-garage_shelving",title:z("tech_garage_shelving"),desc:z("tech_garage_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{shelving:1,quantium:1},grant:["shelving",2],cost:{Knowledge:()=>125e4,Quantium:()=>75e3},effect:z("tech_garage_shelving_effect"),action(){return!!ri($(this)[0])}},warehouse_shelving:{id:"tech-warehouse_shelving",title:z("tech_warehouse_shelving"),desc:z("tech_warehouse_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{shelving:2,quantium:1,outer:4},grant:["shelving",3],cost:{Knowledge:()=>225e4,Quantium:()=>1e6,Cipher:()=>25e3},effect:z("tech_warehouse_shelving_effect"),action(){return!!ri($(this)[0])}},elerium_extraction:{id:"tech-elerium_extraction",title:z("tech_elerium_extraction"),desc:z("tech_elerium_extraction"),category:"mining",era:"solar",path:["truepath"],reqs:{kuiper:1},grant:["kuiper",2],cost:{Knowledge:()=>25e5,Orichalcum:()=>1e5,Cipher:()=>12e3},effect:()=>z("tech_elerium_extraction_effect"),action(){return!!ri($(this)[0])&&(t.space.elerium_mine={count:0,on:0},!0)}},orichalcum_panels_tp:{id:"tech-orichalcum_panels_tp",title:z("tech_orichalcum_panels"),desc:z("tech_orichalcum_panels"),category:"power_generation",era:"solar",path:["truepath"],reqs:{kuiper:1,swarm:5},grant:["swarm",6],cost:{Knowledge:()=>24e5,Orichalcum:()=>125e3},effect:()=>z("tech_orichalcum_panels_effect"),action(){return!!ri($(this)[0])}},shipyard:{id:"tech-shipyard",title:()=>z("tech_shipyard",[Ut().dwarf]),desc:()=>z("tech_shipyard",[Ut().dwarf]),category:"space_militarization",era:"solar",path:["truepath"],reqs:{outer:1,syndicate:1},grant:["shipyard",1],cost:{Knowledge:()=>42e4},effect:()=>z("tech_shipyard_effect",[Ut().dwarf]),action(){return!!ri($(this)[0])&&(t.space.shipyard={count:0,on:0,ships:[],expand:!0,sort:!0},pt(),!0)}},ship_lasers:{id:"tech-ship_lasers",title:z("tech_ship_lasers"),desc:z("tech_ship_lasers"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{military:7,syard_weapon:1},grant:["syard_weapon",2],cost:{Knowledge:()=>425e3,Elerium:()=>500},effect:z("tech_ship_lasers_effect"),action(){return!!ri($(this)[0])}},pulse_lasers:{id:"tech-pulse_lasers",title:z("tech_pulse_lasers"),desc:z("tech_pulse_lasers"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:2},grant:["syard_weapon",3],cost:{Knowledge:()=>5e5,Elerium:()=>750},effect:z("tech_pulse_lasers_effect"),action(){return!!ri($(this)[0])}},ship_plasma:{id:"tech-ship_plasma",title:z("tech_ship_plasma"),desc:z("tech_ship_plasma"),category:"space_militarization",era:"solar",reqs:{high_tech:13,syard_weapon:3},grant:["syard_weapon",4],path:["truepath"],cost:{Knowledge:()=>88e4,Elerium:()=>2500},effect:z("tech_ship_plasma_effect"),action(){return!!ri($(this)[0])}},ship_phaser:{id:"tech-ship_phaser",title:z("tech_ship_phaser"),desc:z("tech_ship_phaser"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:4,quantium:1},grant:["syard_weapon",5],cost:{Knowledge:()=>1225e3,Quantium:()=>75e3},effect:z("tech_ship_phaser_effect"),action(){return!!ri($(this)[0])}},ship_disruptor:{id:"tech-ship_disruptor",title:z("tech_ship_disruptor"),desc:z("tech_ship_disruptor"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:5,outer:4},grant:["syard_weapon",6],cost:{Knowledge:()=>2e6,Cipher:()=>25e3},effect:z("tech_ship_disruptor_effect"),action(){return!!ri($(this)[0])}},destroyer_ship:{id:"tech-destroyer_ship",title:z("tech_destroyer_ship"),desc:z("tech_destroyer_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:2},grant:["syard_class",3],cost:{Knowledge:()=>465e3},effect:z("tech_destroyer_ship_effect"),action(){return!!ri($(this)[0])}},cruiser_ship_tp:{id:"tech-cruiser_ship_tp",title:z("tech_cruiser_ship"),desc:z("tech_cruiser_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:3,titan:4},grant:["syard_class",4],cost:{Knowledge:()=>75e4,Adamantite:()=>5e4},effect:z("tech_cruiser_ship_tp"),action(){return!!ri($(this)[0])}},h_cruiser_ship:{id:"tech-h_cruiser_ship",title:z("tech_h_cruiser_ship"),desc:z("tech_h_cruiser_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:4,triton:1},grant:["syard_class",5],cost:{Knowledge:()=>15e5},effect:z("tech_h_cruiser_ship_effect"),action(){return!!ri($(this)[0])}},dreadnought_ship:{id:"tech-dreadnought_ship",title:z("tech_dreadnought_ship"),desc:z("tech_dreadnought_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:5,kuiper:1},grant:["syard_class",6],cost:{Knowledge:()=>25e5,Cipher:()=>1e4},effect:z("tech_dreadnought_ship_effect"),action(){return!!ri($(this)[0])}},pulse_engine:{id:"tech-pulse_engine",title:z("outer_shipyard_engine_pulse"),desc:z("outer_shipyard_engine_pulse"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:2,stanene:1},grant:["syard_engine",3],cost:{Knowledge:()=>555e3,Stanene:()=>25e4},effect:z("tech_pulse_engine_effect"),action(){return!!ri($(this)[0])}},photon_engine:{id:"tech-photon_engine",title:z("outer_shipyard_engine_photon"),desc:z("outer_shipyard_engine_photon"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:3,quantium:1},grant:["syard_engine",4],cost:{Knowledge:()=>115e4,Quantium:()=>5e4},effect:z("tech_photon_engine_effect"),action(){return!!ri($(this)[0])}},vacuum_drive:{id:"tech-vacuum_drive",title:z("outer_shipyard_engine_vacuum"),desc:z("outer_shipyard_engine_vacuum"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:4,outer:4},grant:["syard_engine",5],cost:{Knowledge:()=>185e4,Cipher:()=>1e4},effect:z("outer_shipyard_engine_vacuum_desc"),action(){return!!ri($(this)[0])}},ship_fusion:{id:"tech-ship_fusion",title:z("tech_fusion_generator"),desc:z("tech_fusion_generator"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_power:3,quantium:1},grant:["syard_power",4],cost:{Knowledge:()=>11e5,Quantium:()=>65e3},effect:z("tech_fusion_generator_effect"),action(){return!!ri($(this)[0])}},ship_elerium:{id:"tech-ship_elerium",title:z("tech_elerium_generator"),desc:z("tech_elerium_generator"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_power:4,outer:4},grant:["syard_power",5],cost:{Knowledge:()=>19e5,Cipher:()=>18e3},effect:z("tech_elerium_generator_effect"),action(){return!!ri($(this)[0])}},quantum_signatures:{id:"tech-quantum_signatures",title:z("tech_quantum_signatures"),desc:z("tech_quantum_signatures"),category:"progress",era:"solar",path:["truepath"],reqs:{quantium:1,syard_sensor:3},grant:["syard_sensor",4],cost:{Knowledge:()=>105e4,Quantium:()=>1e4},effect:z("tech_quantum_signatures_effect"),action(){return!!ri($(this)[0])}},interstellar_drive:{id:"tech-interstellar_drive",title:z("tech_interstellar_drive"),desc:z("tech_interstellar_drive"),category:"progress",era:"tauceti",path:["truepath"],reqs:{outer:8,titan_ai_core:2,syard_sensor:4},grant:["tauceti",1],cost:{Knowledge:()=>45e5,Quantium:()=>25e4,Cipher:()=>75e3},effect:z("tech_interstellar_drive_effect"),action(){return!!ri($(this)[0])}},alien_outpost:{id:"tech-alien_outpost",title:z("tech_alien_outpost"),desc:z("tech_alien_outpost"),category:"science",era:"tauceti",path:["truepath"],reqs:{tauceti:2,tau_home:3},grant:["tau_home",4],cost:{Knowledge:()=>5e6,Cipher:()=>1e5},effect:z("tech_alien_outpost_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.alien_outpost={count:1,on:0},t.tauceti.jump_gate={count:0},t.space.jump_gate={count:0},hs(z("tech_alien_outpost_msg"),"info",!1,["progress"]),!0)}},jumpgates:{id:"tech-jumpgates",title:z("tech_jumpgates"),desc:z("tech_jumpgates"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tauceti:2,tau_home:4},grant:["tauceti",3],cost:{Knowledge:()=>6e6},effect:z("tech_jumpgates_effect"),action(){return!!ri($(this)[0])}},system_survey:{id:"tech-system_survey",title:z("tech_system_survey"),desc:z("tech_system_survey"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tauceti:4,womling_tech:1},grant:["tauceti",5],cost:{Knowledge:()=>7e6},effect:z("tech_system_survey_effect"),action(){return!!ri($(this)[0])&&(t.settings.tau.roid=!0,t.settings.tau.gas=!0,t.tauceti.patrol_ship={count:0,on:0,support:0,s_max:0},!0)}},repository:{id:"tech-repository",title:z("tech_repository"),desc:z("tech_repository"),category:"storage",era:"tauceti",path:["truepath"],reqs:{tauceti:4,tau_home:4},grant:["tau_home",5],cost:{Knowledge:()=>65e5},effect:z("tech_repository_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.repository={count:0},!0)}},fusion_generator:{id:"tech-fusion_generator",title:z("tech_fusion_power"),desc:z("tech_fusion_power"),category:"power_generation",era:"tauceti",path:["truepath"],reqs:{tau_home:5},grant:["tau_home",6],cost:{Knowledge:()=>675e4},effect:z("tech_tau_fusion_power_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.fusion_generator={count:0,on:0},!0)}},tau_cultivation:{id:"tech-tau_cultivation",title:z("tech_tau_cultivation"),desc:z("tech_tau_cultivation"),category:"agriculture",era:"tauceti",path:["truepath"],reqs:{tau_home:6},grant:["tau_home",7],cost:{Knowledge:()=>69e5},effect:()=>z("tech_tau_cultivation_effect",[Ki[t.race.species].home]),action(){return!!ri($(this)[0])&&(t.tauceti.tau_farm={count:0,on:0},!0)}},tau_manufacturing:{id:"tech-tau_manufacturing",title:z("tech_tau_manufacturing"),desc:z("tech_tau_manufacturing"),category:"crafting",era:"tauceti",path:["truepath"],reqs:{tau_home:7},grant:["tau_home",8],cost:{Knowledge:()=>725e4},effect:()=>z("tech_tau_manufacturing_effect",[Ki[t.race.species].home]),action(){return!!ri($(this)[0])&&(t.tauceti.tau_factory={count:0,on:0},!0)}},weasels:{id:"tech-weasels",title:z("tech_weasels"),desc:z("tech_weasels"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:2},grant:["tau_red",3],cost:{Knowledge:()=>625e4},effect:()=>z("tech_weasels_effect",[z("tau_planet",[Ut().red])]),action(){return!!ri($(this)[0])&&(hs(z("tech_weasels_msg",[z("tau_planet",[Ut().red])]),"info",!1,["progress"]),!0)}},jeff:{id:"tech-jeff",title:z("tech_jeff"),desc:z("tech_jeff"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:3},grant:["tau_red",4],cost:{Knowledge:()=>638e4},effect:()=>z("tech_jeff_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_jeff_effect_msg",[]),"info",!1,["progress"]),!0)}},womling_fun:{id:"tech-womling_fun",title:z("tech_womling_fun"),desc:z("tech_womling_fun"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:5},grant:["tau_red",6],cost:{Knowledge:()=>665e4},effect:()=>z("tech_womling_fun_effect"),action(){return!!ri($(this)[0])}},womling_lab:{id:"tech-womling_lab",title:z("tech_womling_lab"),desc:z("tech_womling_lab"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:6},grant:["tau_red",7],cost:{Knowledge:()=>69e5},effect:()=>z("tech_womling_lab_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.womling_lab={count:0,on:0,scientist:0,tech:0},t.tech.womling_tech=0,!0)}},womling_mining:{id:"tech-womling_mining",title:z("tech_womling_mining"),desc:z("tech_womling_mining"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:1},grant:["womling_mining",1],cost:{Knowledge:()=>71e5},effect:()=>z("tech_womling_mining_effect"),action(){return!!ri($(this)[0])}},womling_firstaid:{id:"tech-womling_firstaid",title:z("tech_womling_firstaid"),desc:z("tech_womling_firstaid"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:2},grant:["womling_firstaid",1],cost:{Knowledge:()=>735e4},effect:()=>z("tech_womling_firstaid_effect"),action(){return!!ri($(this)[0])}},womling_logistics:{id:"tech-womling_logistics",title:z("tech_womling_logistics"),desc:z("tech_womling_logistics"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:3},grant:["womling_logistics",1],cost:{Knowledge:()=>765e4},effect:()=>z("tech_womling_logistics_effect",[z("tau_red_orbital_platform")]),action(){return!!ri($(this)[0])}},womling_repulser:{id:"tech-womling_repulser",title:z("tech_womling_repulser"),desc:z("tech_womling_repulser"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:4,womling_logistics:1},grant:["womling_logistics",2],cost:{Knowledge:()=>79e5},effect:()=>z("tech_womling_repulser_effect",[t.resource.Oil.name,z("tau_red_orbital_platform")]),action(){return!!ri($(this)[0])}},womling_farming:{id:"tech-womling_farming",title:z("tech_womling_farming"),desc:z("tech_womling_farming"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:5},grant:["womling_pop",1],cost:{Knowledge:()=>82e5},effect:()=>z("tech_womling_farming_effect"),action(){return!!ri($(this)[0])}},womling_housing:{id:"tech-womling_housing",title:z("tech_womling_housing"),desc:z("tech_womling_housing"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:6,womling_pop:1},grant:["womling_pop",2],cost:{Knowledge:()=>85e5},effect:()=>z("tech_womling_housing_effect"),action(){return!!ri($(this)[0])}},womling_support:{id:"tech-womling_support",title:z("tech_womling_support"),desc:z("tech_womling_support"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:7,tau_gas:4},grant:["womling_technicians",1],cost:{Knowledge:()=>885e4},effect:()=>`
                ${z("tech_womling_support_effect")}
                `,action(){return!!ri($(this)[0])&&(t.tauceti.womling_station={count:0,on:0},!0)}},womling_recycling:{id:"tech-womling_recycling",title:z("tech_womling_recycling"),desc:z("tech_womling_recycling"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:8},grant:["womling_recycling",1],cost:{Knowledge:()=>955e4},effect:()=>`
                ${z("tech_womling_recycling_effect")}
                `,action(){return!!ri($(this)[0])}},asteroid_analysis:{id:"tech-asteroid_analysis",title:z("tech_asteroid_analysis"),desc:z("tech_asteroid_analysis"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_roid:1},grant:["tau_roid",2],cost:{Knowledge:()=>735e4},effect:()=>z("tech_asteroid_analysis_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_asteroid_analysis_msg"),"info",!1,["progress"]),!0)}},shark_repellent:{id:"tech-shark_repellent",title:z("tech_shark_repellent"),desc:z("tech_shark_repellent"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_roid:2},grant:["tau_roid",3],cost:{Knowledge:()=>74e5},effect:()=>z("tech_shark_repellent_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_shark_repellent_msg"),"info",!1,["progress"]),!0)}},belt_mining:{id:"tech-belt_mining",title:z("tech_belt_mining"),desc:z("tech_belt_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{tau_gas:3,tau_roid:3},grant:["tau_gas",4],cost:{Knowledge:()=>765e4},effect:()=>z("tech_belt_mining_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.ore_refinery={count:0,on:0,max:0,fill:0},t.tauceti.mining_ship={count:0,on:0,common:50,uncommon:50,rare:50},!0)}},adv_belt_mining:{id:"tech-adv_belt_mining",title:z("tech_adv_belt_mining"),desc:z("tech_adv_belt_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{tau_roid:4},grant:["tau_roid",5],cost:{Knowledge:()=>79e5},effect:()=>z("tech_adv_belt_mining_effect"),action(){return!!ri($(this)[0])}},space_whaling:{id:"tech-space_whaling",title:z("tech_space_whaling"),desc:z("tech_space_whaling"),category:"whaling",era:"tauceti",path:["truepath"],reqs:{tau_gas:3,tau_roid:3},grant:["tau_whale",1],cost:{Knowledge:()=>75e5},effect:()=>z("tech_space_whaling_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.whaling_station={count:0,on:0,max:0,fill:0},t.tauceti.whaling_ship={count:0,on:0},!0)}},infectious_disease_lab:{id:"tech-infectious_disease_lab",title:()=>z(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),desc:()=>z(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),category:"science",era:"tauceti",path:["truepath"],reqs:{plague:2},grant:["disease",1],cost:{Knowledge:()=>825e4},effect:()=>z(t.race.artifical?"tech_infectious_disease_lab_effect_s":"tech_infectious_disease_lab_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.infectious_disease_lab={count:0,on:0,cure:0},!0)}},isolation_protocol:{id:"tech-isolation_protocol",title:z("tech_isolation_protocol"),desc:z("tech_isolation_protocol"),category:"plague",era:"tauceti",path:["truepath"],reqs:{disease:2},grant:["disease",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>85e5},effect:()=>`
                ${z("tech_isolation_protocol_effect",[z("tab_tauceti")])}
                ${z("tech_isolation_protocol_warning")}
                `,action(){return!!ri($(this)[0])&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),t.tech.isolation=1,function(){let e={city:{},space:{},ships:[]};e.ships=[...t.space.shipyard.ships],t.space.shipyard.ships=[],t.settings.spaceTabs=6,t.settings.showSpace=!1,t.settings.showOuter=!1,t.settings.showCity=!1,t.settings.showShipYard=!1,5===t.settings.govTabs&&(t.settings.govTabs=0),nt(),Ss($("#shipList")),Object.keys(Mr.city).forEach((function(a){t.city.hasOwnProperty(a)&&t.city[a].hasOwnProperty("count")&&(t.race.hooved&&Mr.city[a].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Mr.city[a].cost.Horseshoe()*t.city[a].count),e.city[a]={c:t.city[a].count},t.city[a].count=0,t.city[a].hasOwnProperty("on")&&(e.city[a].o=t.city[a].on,t.city[a].on=0))})),["spc_home","spc_moon","spc_red","spc_hell","spc_sun","spc_gas","spc_gas_moon","spc_belt","spc_dwarf","spc_titan","spc_enceladus","spc_triton","spc_kuiper","spc_eris"].forEach((function(a){Object.keys(Mr.space[a]).forEach((function(r){t.space.hasOwnProperty(r)&&t.space[r].hasOwnProperty("count")&&(t.race.hooved&&Mr.space[a][r].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Mr.space[a][r].cost.Horseshoe()*t.space[r].count),e.space[r]={c:t.space[r].count},t.space[r].count=0,t.space[r].hasOwnProperty("on")&&(e.space[r].o=t.space[r].on,t.space[r].on=0))}))})),t.race.hooved&&t.race.shoecnt<5&&(t.race.shoecnt=5),t.resource.Zen.display&&(t.resource.Zen.display=!1),t.resource.Slave.display&&(t.resource.Slave.display=!1,t.resource.Slave.amount=0,D("slave")),t.race.deconstructor&&xi.forEach((function(e){t.city.nanite_factory[e]=0})),Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),Object.keys(Xt).forEach((function(e){["professor","scientist","pit_miner","cement_worker","craftsman"].includes(e)||(t.civic[e].workers=0,t.civic[e].assigned=0)})),["forager","farmer","lumberjack","quarry_worker","miner","coal_miner","priest","colonist","titan_colonist","space_miner"].forEach((function(e){t.civic[e].display=!1})),t.civic.hunter.display?t.civic.d_job="hunter":t.civic.d_job="unemployed",t.arpa.sequence&&(t.arpa.sequence.on=!1,t.arpa.sequence.boost=!1);for(let e of Object.values(t.race.purgatory.city))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);for(let e of Object.values(t.race.purgatory.space))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);if(t.queue.hasOwnProperty("queue"))for(let e=t.queue.queue.length-1;e>=0;e--){let a=t.queue.queue[e];"city"!==a.action&&"space"!==a.action&&"starDock"!==a.action||t.queue.queue.splice(e,1)}t.tech.magic&&t.tech.magic>=2&&(t.tauceti.pylon={count:0},t.race.casting&&Object.keys(t.race.casting).forEach((function(e){t.race.casting[0]=0}))),t.tauceti.tauceti_casino={count:0,on:0},t.tauceti.tau_housing={count:0};let a=n.colony*Re.tau_home.colony.citizens();t.resource[t.race.species].amount>a&&(t.resource[t.race.species].amount=a),D("spy"),D("spyop"),Ss($("#infoTimer")),t.race.inactive=e}(),!0)}},focus_cure:{id:"tech-focus_cure",title:z("tech_focus_cure"),desc:z("tech_focus_cure"),category:"plague",era:"tauceti",path:["truepath"],reqs:{disease:2},grant:["disease",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>85e5},effect:()=>`
                ${z("tech_focus_cure_effect",[z("tab_tauceti")])}
                ${z("tech_focus_cure_warning")}
                `,action(){return!!ri($(this)[0])&&(t.tech.focus_cure=1,!0)}},decode_virus:{id:"tech-decode_virus",title:z("tech_decode_virus"),desc:z("tech_decode_virus"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:1},grant:["focus_cure",2],cost:{Knowledge:()=>9e6},effect:()=>`
                ${z(t.race.artifical?"tech_decode_virus_effect_s":"tech_decode_virus_effect")}
                `,action(){return!!ri($(this)[0])&&(t.race.artifical?hs(z("tech_decode_virus_msg1s",[Mr.tauceti.tau_home.infectious_disease_lab.title()]),"info",!1,["progress"]):hs(z("tech_decode_virus_msg1",[Mr.tauceti.tau_home.infectious_disease_lab.title()]),"info",!1,["progress"]),!0)}},vaccine_campaign:{id:"tech-vaccine_campaign",title:z("tech_vaccine_campaign"),desc:z("tech_vaccine_campaign"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:3},grant:["focus_cure",4],cost:{Knowledge:()=>925e4},effect:()=>`
                ${z("tech_vaccine_campaign_effect",[t.race.artifical?Mr.city.boot_camp.title():Mr.city.hospital.title])}
                `,action(){return!!ri($(this)[0])&&(t.race.vax=0,!0)}},vax_strat1:{id:"tech-vax_strat1",title:z("tech_vax_strat1"),desc:z("tech_vax_strat1"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
                ${z("tech_vax_strat1_effect")}
                ${z("tech_vax_warning")}
                `,action(){return!!ri($(this)[0])&&(t.tech.vax_p=1,hs(z("tech_vax_strat1_msg"),"info",!1,["progress"]),!0)}},vax_strat2:{id:"tech-vax_strat2",title:z("tech_vax_strat2"),desc:z("tech_vax_strat2"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
                ${z("tech_vax_strat2_effect")}
                ${z("tech_vax_warning")}
                `,action(){return!!ri($(this)[0])&&(t.tech.vax_f=1,hs(z("tech_vax_strat2_msg"),"info",!1,["progress"]),!0)}},vax_strat3:{id:"tech-vax_strat3",title:z("tech_vax_strat3"),desc:z("tech_vax_strat3"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
                ${z("tech_vax_strat3_effect")}
                ${z("tech_vax_warning")}
                `,action(){return!!ri($(this)[0])&&(t.tech.vax_s=1,hs(z("tech_vax_strat3_msg"),"info",!1,["progress"]),!0)}},vax_strat4:{id:"tech-vax_strat4",title:z("tech_vax_strat4"),desc:z("tech_vax_strat4"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
                ${z("tech_vax_strat4_effect")}
                ${z("tech_vax_warning")}
                `,action(){return!!ri($(this)[0])&&(t.tech.vax_c=1,hs(z("tech_vax_strat4_msg"),"info",!1,["progress"]),!0)}},cloning:{id:"tech-cloning",title:z("tech_cloning"),desc:z("tech_cloning"),category:"housing",era:"tauceti",path:["truepath"],reqs:{focus_cure:7},grant:["cloning",1],cost:{Knowledge:()=>975e4},effect:()=>`
                ${z(t.race.artifical?"tech_cloning_effect_s":"tech_cloning_effect")}
                `,action(){return!!ri($(this)[0])&&(t.tauceti.cloning_facility={count:0,on:0},!0)}},clone_degradation:{id:"tech-clone_degradation",title:z("tech_clone_degradation"),desc:z("tech_clone_degradation"),category:"progress",era:"tauceti",path:["truepath"],reqs:{cloning:1},grant:["cloning",2],cost:{Knowledge:()=>1e7},effect:()=>`
                ${z("tech_clone_degradation_effect")}
                `,action(){return!!ri($(this)[0])&&(hs(z("tech_clone_degradation_msg"),"info",!1,["progress"]),!0)}},digital_paradise:{id:"tech-digital_paradise",title:z("tech_digital_paradise"),desc:z("tech_digital_paradise"),category:"progress",era:"tauceti",path:["truepath"],reqs:{cloning:2},grant:["matrix",1],cost:{Knowledge:()=>105e5,Cipher:()=>2e5},effect:()=>`
                ${z("tech_digital_paradise_effect")}
                `,action(){return!!ri($(this)[0])}},ringworld:{id:"tech-ringworld",title:z("tech_ringworld"),desc:z("tech_ringworld"),category:"progress",era:"tauceti",path:["truepath"],reqs:{matrix:1},grant:["matrix",2],cost:{Money:()=>3e9,Knowledge:()=>11e6},effect:()=>`
                ${z("tech_ringworld_effect")}
                `,action(){return!!ri($(this)[0])&&(t.settings.tau.star=!0,t.tauceti.ringworld={count:0},!0)}},iso_gambling:{id:"tech-iso_gambling",title:z("tech_iso_gambling"),desc:z("tech_iso_gambling"),category:"banking",era:"tauceti",reqs:{gambling:4,isolation:1},grant:["iso_gambling",1],cost:{Knowledge:()=>865e4},effect:z("tech_iso_gambling_effect",[5]),action(){return!!ri($(this)[0])}},outpost_boost:{id:"tech-outpost_boost",title:()=>z("tech_outpost_boost"),desc:()=>z("tech_outpost_boost"),category:"special",era:"tauceti",path:["truepath"],reqs:{tau_home:4,isolation:1},grant:["outpost_boost",1],cost:{Knowledge:()=>89e5},effect:()=>z("tech_outpost_boost_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_outpost_boost_flair")},cultural_center:{id:"tech-cultural_center",title:z("tech_cultural_center"),desc:z("tech_cultural_center"),category:"banking",era:"tauceti",path:["truepath"],reqs:{iso_gambling:1,isolation:1},grant:["tau_culture",1],cost:{Knowledge:()=>885e4},effect:z("tech_cultural_center_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.tau_cultural_center={count:0,on:0},!0)},flair:()=>z("tech_cultural_center_flair")},outer_tau_survey:{id:"tech-outer_tau_survey",title:z("tech_outer_tau_survey"),desc:z("tech_outer_tau_survey"),category:"progress",era:"tauceti",path:["truepath"],reqs:{outpost_boost:1,plague:5},grant:["tau_gas2",1],cost:{Knowledge:()=>91e5,Helium_3:()=>+Ht(5e6).toFixed(0)},effect:z("tech_outer_tau_survey_effect"),action(){return!!ri($(this)[0])&&(t.settings.tau.gas2=!0,!0)}},alien_research:{id:"tech-alien_research",title:z("tech_alien_research"),desc:z("tech_alien_research"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_gas2:5},grant:["tau_gas2",6],cost:{Knowledge:()=>935e4},effect:z("tech_alien_research_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.alien_space_station.decrypted=0,t.tauceti.alien_space_station.focus=95,hs(z("tech_alien_research_msg"),"info",!1,["progress"]),!0)}},womling_gene_therapy:{id:"tech-womling_gene_therapy",title:z("tech_womling_gene_therapy"),desc:z("tech_womling_gene_therapy"),category:"womling",era:"tauceti",path:["truepath"],reqs:{alien_data:1},grant:["womling_gene",1],cost:{Knowledge:()=>952e4},effect:z("tech_womling_gene_therapy_effect"),action(){return!!ri($(this)[0])}},food_culture:{id:"tech-food_culture",title:()=>z("tech_food_culture",[z(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),desc:()=>z("tech_food_culture",[z(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),category:"banking",era:"tauceti",path:["truepath"],reqs:{alien_data:2,tau_culture:1},grant:["tau_culture",2],cost:{Knowledge:()=>941e4},effect:()=>z("tech_food_culture_effect",[z(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`),z("tech_cultural_center")]),action(){return!!ri($(this)[0])}},advanced_refinery:{id:"tech-advanced_refinery",title:z("tech_advanced_refinery"),desc:z("tech_advanced_refinery"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:3},grant:["tau_ore_mining",1],cost:{Knowledge:()=>968e4},effect:()=>z("tech_advanced_refinery_effect"),action(){return!!ri($(this)[0])}},advanced_pit_mining:{id:"tech-advanced_pit_mining",title:z("tech_advanced_pit_mining"),desc:z("tech_advanced_pit_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:3},grant:["tau_pit_mining",1],cost:{Knowledge:()=>972e4},effect:()=>z("tech_advanced_pit_mining_effect"),action(){return!!ri($(this)[0])}},useless_junk:{id:"tech-useless_junk",title:z("tech_useless_junk"),desc:z("tech_useless_junk"),category:"womling",era:"tauceti",path:["truepath"],reqs:{alien_data:4},grant:["tau_junksale",1],cost:{Knowledge:()=>955e4},effect:()=>z("tech_useless_junk_effect",[z(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`),z("tau_red_womlings")]),action(){return!!ri($(this)[0])}},advanced_asteroid_mining:{id:"tech-advanced_asteroid_mining",title:z("tech_advanced_asteroid_mining"),desc:z("tech_advanced_asteroid_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:5,tau_ore_mining:1},grant:["tau_ore_mining",2],cost:{Knowledge:()=>975e4},effect:()=>z("tech_advanced_asteroid_mining_effect",[z("tau_roid_mining_ship")]),action(){return!!ri($(this)[0])}},advanced_material_synthesis:{id:"tech-advanced_material_synthesis",title:z("tech_advanced_material_synthesis"),desc:z("tech_advanced_material_synthesis"),category:"crafting",era:"tauceti",path:["truepath"],reqs:{alien_data:5,disease:1},grant:["alien_crafting",1],cost:{Knowledge:()=>988e4},effect:()=>z("tech_advanced_material_synthesis_effect",[t.resource.Quantium.name]),action(){return!!ri($(this)[0])}},matrioshka_brain:{id:"tech-matrioshka_brain",title:z("tech_matrioshka_brain"),desc:z("tech_matrioshka_brain"),category:"progress",era:"tauceti",path:["truepath"],reqs:{alien_data:6,tau_gas2:6},grant:["tau_gas2",7],not_trait:["lone_survivor"],cost:{Knowledge:()=>1e7},effect:()=>z("tech_matrioshka_brain_effect",[Mr.tauceti.tau_gas2.info.name()]),action(){return!!ri($(this)[0])&&(t.tauceti.matrioshka_brain={count:0},!0)}},ignition_device:{id:"tech-ignition_device",title:z("tech_ignition_device"),desc:z("tech_ignition_device"),category:"progress",era:"tauceti",path:["truepath"],reqs:{alien_data:6,tau_gas2:7},grant:["tau_gas2",8],cost:{Knowledge:()=>105e5},effect:()=>z("tech_ignition_device_effect",[Mr.tauceti.tau_gas2.info.name()]),action(){return!!ri($(this)[0])&&(t.tauceti.ignition_device={count:0},t.tauceti.hasOwnProperty("matrioshka_brain")||(t.tauceti.matrioshka_brain={count:0}),!0)}},replicator:{id:"tech-replicator",title:()=>"antimatter"===t.race.universe?z("tech_antireplicator"):z("tech_replicator"),desc:()=>"antimatter"===t.race.universe?z("tech_antireplicator"):z("tech_replicator"),category:"special",era:"tauceti",path:["truepath"],reqs:{tau_home:4,isolation:1},trait:["lone_survivor"],grant:["replicator",1],cost:{Knowledge:()=>625e4},effect:()=>"antimatter"===t.race.universe?z("tech_antireplicator_effect"):z("tech_replicator_effect"),action(){return!!ri($(this)[0])&&(t.race.replicator={res:"Unobtainium",pow:1},!0)}},womling_unlock:{id:"tech-womling_unlock",title:z("tech_womling_unlock"),desc:z("tech_womling_unlock"),category:"womling",era:"tauceti",path:["truepath"],reqs:{replicator:1},trait:["lone_survivor"],grant:["tau_red",4],cost:{Knowledge:()=>65e5},effect:()=>z("tech_womling_unlock_effect",[z("tau_planet",[Ut().red])]),action(){return!!ri($(this)[0])&&(t.settings.tau.red=!0,t.tauceti.orbital_platform.count=1,t.tauceti.orbital_platform.on=1,!0)}},garden_of_eden:{id:"tech-garden_of_eden",title:z("tech_garden_of_eden"),desc:z("tech_garden_of_eden"),category:"special",era:"tauceti",path:["truepath"],reqs:{eden:1},grant:["eden",2],cost:{Knowledge:()=>1e7},effect:()=>z("tech_garden_of_eden_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.goe_facility={count:0},!0)}}};function qr(){t.tech.world_control=1,Ss($("#garrison")),Ss($("#c_garrison")),he($("#garrison"),!0),he($("#c_garrison"),!1);for(let e=0;e<3;e++){if(t.civic.foreign[`gov${e}`].occ){let a=ta("federation"===t.civic.govern.type?15:20);t.civic.garrison.max+=a,t.civic.garrison.workers+=a,t.civic.foreign[`gov${e}`].occ=!1}t.civic.foreign[`gov${e}`].buy=!1,t.civic.foreign[`gov${e}`].anx=!1,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none"}D("spy"),D("spyop")}function Pr(e,a){let r=["swiss","gouda","cheddar","brie","feta","ricotta","goat","mascarpone","bleu","colby_jack","camembert","gorgonzola","mozzarella","roquefort","provolone","monterey_jack","muenster","cambozola","jarlsberg","bocconcini","cantal","emmental","havarti","burrata","cottage","asiago","wensleydale","pepper_jack","queso_blanco","pecorino","raclette","fontina","reblochon","port_salut","brillat_savarin","cream","stilton","taleggio","manchego","edam","gruyeye","parmigiano_reggiano","epoisses","comte","caciocavallo","teleme","grana_padano","chaumes","morbier","halloumi","lancashire","bleu_de_gex","fourme_d_ambert","fromage_blanc","red_leicester","bleu_d_auvergne","pont_l_eveque","jl_grubb","castello_blue","wagasi","ayibe","caravane","limburger","herve","kashkaval","sirene","paski_sir","akkawi","olomoucke_syrecky","anari","danbo","hermelín","trappista","stinking_bishop","banbury","sulguni","hofoingi","urda","golka","rokpol","telemea","bryndza","parenica","kackavalj","liptauer","greve","korbaciky","herrgardsost","vasterbottensost","mish","anejo","quesillo","nacho","reggianito","catupiry","queso_paipa","canastra","port_wine","cados","brie_de_meaux"];if(a)return r;let i=(t.stats.hasOwnProperty("reset")?t.stats.reset:0)%r.length;return e?z(`cheese_${r[i]}`):z("tech_swiss_bank",[z(`cheese_${r[i]}`)])}const jr={standard:["primitive","discovery","civilized","industrialized","globalized","early_space","deep_space","interstellar","intergalactic","dimensional"],truepath:["primitive","discovery","civilized","industrialized","globalized","early_space","deep_space","solar","tauceti"]};function Or(e){if(e){let t={};return Object.keys(xr).forEach((function(a){(jr[e].includes(xr[a].era)||xr[a].hasOwnProperty("path"))&&(!xr[a].hasOwnProperty("path")||xr[a].hasOwnProperty("path")&&xr[a].path.includes(e))&&(t[a]=xr[a])})),t}return xr}const Mr={evolution:{rna:{id:"evolution-rna",title:z("resource_RNA_name"),desc:()=>z("evo_rna",[t.race.rapid_mutation?2:1]),condition:()=>t.resource.hasOwnProperty("RNA")&&t.resource.RNA.display&&!t.race.evoFinalMenu,action:()=>(t.resource.RNA.amount0},dna:{id:"evolution-dna",title:z("evo_dna_title"),desc:z("evo_dna_desc"),condition:()=>t.resource.hasOwnProperty("DNA")&&t.resource.DNA.display&&!t.race.evoFinalMenu,cost:{RNA:()=>2},action:()=>(t.resource.RNA.amount>=2&&t.resource.DNA.amount0},membrane:{id:"evolution-membrane",title:z("evo_membrane_title"),desc:z("evo_membrane_desc"),condition:()=>t.evolution.hasOwnProperty("membrane")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("membrane",2,2,e)},effect:()=>z("evo_membrane_effect",[t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5]),action(){return!!ri($(this)[0])&&(t.resource.RNA.max+=t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5,t.evolution.membrane.count++,!0)}},organelles:{id:"evolution-organelles",title:z("evo_organelles_title"),desc:z("evo_organelles_desc"),condition:()=>t.evolution.hasOwnProperty("organelles")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("organelles",12,8,e),DNA:e=>Dr("organelles",4,4,e)},effect(){let e=t.race.rapid_mutation?2:1;return t.evolution.sexual_reproduction&&t.evolution.sexual_reproduction.count>0&&e++,z("evo_organelles_effect",[e])},action(){return!!ri($(this)[0])&&(t.evolution.organelles.count++,!0)}},nucleus:{id:"evolution-nucleus",title:z("evo_nucleus_title"),desc:z("evo_nucleus_desc"),condition:()=>t.evolution.hasOwnProperty("nucleus")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("nucleus",38,t.tech.evo&&t.tech.evo>=4?16:32,e),DNA:e=>Dr("nucleus",18,t.tech.evo&&t.tech.evo>=4?12:16,e)},effect:()=>z("evo_nucleus_effect",[t.evolution.bilateral_symmetry&&t.evolution.bilateral_symmetry.count>0||t.evolution.poikilohydric&&t.evolution.poikilohydric.count>0||t.evolution.spores&&t.evolution.spores.count>0?2:1]),action(){return!!ri($(this)[0])&&(t.evolution.nucleus.count++,!0)}},eukaryotic_cell:{id:"evolution-eukaryotic_cell",title:z("evo_eukaryotic_title"),desc:z("evo_eukaryotic_desc"),condition:()=>t.evolution.hasOwnProperty("eukaryotic_cell")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("eukaryotic_cell",20,20,e),DNA:e=>Dr("eukaryotic_cell",40,12,e)},effect:()=>z("evo_eukaryotic_effect",[t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10]),action(){return!!ri($(this)[0])&&(t.evolution.eukaryotic_cell.count++,t.resource.DNA.max+=t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10,!0)}},mitochondria:{id:"evolution-mitochondria",title:z("evo_mitochondria_title"),desc:z("evo_mitochondria_desc"),condition:()=>t.evolution.hasOwnProperty("mitochondria")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("mitochondria",75,50,e),DNA:e=>Dr("mitochondria",65,35,e)},effect:z("evo_mitochondria_effect"),action(){return!!ri($(this)[0])&&(t.evolution.mitochondria.count++,!0)}},sexual_reproduction:{id:"evolution-sexual_reproduction",title:z("evo_sexual_reproduction_title"),desc:z("evo_sexual_reproduction_desc"),reqs:{evo:1},grant:["evo",2],condition:()=>t.tech.evo&&1===t.tech.evo,cost:{DNA:()=>150},effect:z("evo_sexual_reproduction_effect"),action(){return!!ri($(this)[0])&&(t.evolution.final=20,!0)},queue_complete:()=>t.tech.evo&&1===t.tech.evo?1:0},phagocytosis:{id:"evolution-phagocytosis",title:z("evo_phagocytosis_title"),desc:z("evo_phagocytosis_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>t.tech.evo&&2===t.tech.evo,cost:{DNA:()=>175},effect:z("evo_phagocytosis_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_animal=1,t.evolution.final=40,!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0},chloroplasts:{id:"evolution-chloroplasts",title:()=>t.evolution.gselect?z("genelab_genus_plant"):z("evo_chloroplasts_title"),desc:z("evo_chloroplasts_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>zr(2),cost:{DNA:()=>175},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_chloroplasts_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_chloroplasts_effect"),action(){return!!ri($(this)[0])&&(t.evolution.gselect?(t.tech.evo=7,t.tech.evo_plant=2,t.evolution.final=100):(t.tech.evo_plant=1,t.evolution.final=40),!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Xs("genus_plant")},chitin:{id:"evolution-chitin",title:()=>t.evolution.gselect?z("genelab_genus_fungi"):z("evo_chitin_title"),desc:z("evo_chitin_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>zr(2),cost:{DNA:()=>175},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_chitin_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_chitin_effect"),action(){return!!ri($(this)[0])&&(t.evolution.gselect?(t.tech.evo=7,t.tech.evo_fungi=2,t.evolution.final=100):(t.tech.evo_fungi=1,t.evolution.final=40),!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Xs("genus_fungi")},exterminate:{id:"evolution-exterminate",title:()=>t.evolution.gselect?z("genelab_genus_synthetic"):z("evo_exterminate_title"),desc:z("evo_exterminate_desc"),reqs:{evo:2},grant:["evo",7],condition:()=>zr(2)&&t.stats.achieve.obsolete&&t.stats.achieve.obsolete.l>=5,cost:{DNA:()=>200},effect:()=>z("evo_exterminate_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_synthetic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Xs("genus_synthetic")},multicellular:{id:"evolution-multicellular",title:z("evo_multicellular_title"),desc:z("evo_multicellular_desc"),reqs:{evo:3},grant:["evo",4],condition:()=>t.tech.evo&&3===t.tech.evo,cost:{DNA:()=>200},effect:z("evo_multicellular_effect"),action(){return!!ri($(this)[0])&&(t.evolution.final=60,!0)},queue_complete:()=>t.tech.evo&&3===t.tech.evo?1:0},spores:{id:"evolution-spores",title:z("evo_spores_title"),desc:z("evo_spores_desc"),reqs:{evo:4,evo_fungi:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:z("evo_nucleus_boost"),action(){return!!ri($(this)[0])&&(t.evolution.final=80,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},poikilohydric:{id:"evolution-poikilohydric",title:z("evo_poikilohydric_title"),desc:z("evo_poikilohydric_desc"),reqs:{evo:4,evo_plant:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:z("evo_nucleus_boost"),action(){return!!ri($(this)[0])&&(t.evolution.final=80,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},bilateral_symmetry:{id:"evolution-bilateral_symmetry",title:z("evo_bilateral_symmetry_title"),desc:z("evo_bilateral_symmetry_desc"),reqs:{evo:4,evo_animal:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:z("evo_nucleus_boost"),action(){return!!ri($(this)[0])&&(t.evolution.final=80,t.tech.evo_insectoid=1,t.tech.evo_mammals=1,t.tech.evo_eggshell=1,t.tech.evo_eldritch=1,t.tech.evo_aquatic=1,t.tech.evo_fey=1,t.tech.evo_sand=1,t.tech.evo_heat=1,t.tech.evo_polar=1,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},bryophyte:{id:"evolution-bryophyte",title:z("evo_bryophyte_title"),desc:z("evo_bryophyte_desc"),reqs:{evo:5},grant:["evo",7],condition:()=>!(!t.tech.evo_plant&&!t.tech.evo_fungi)&&zr(5),cost:{DNA:()=>260},effect:z("evo_bryophyte_effect"),action(){return!!ri($(this)[0])&&(t.evolution.final=100,t.tech.evo_fungi&&(t.tech.evo_fungi=2),t.tech.evo_plant&&(t.tech.evo_plant=2),!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},athropods:{id:"evolution-athropods",title:z("evo_athropods_title"),desc:z("evo_athropods_desc"),reqs:{evo:5,evo_insectoid:1},grant:["evo",7],condition:()=>zr(5),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_athropods_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_athropods_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_insectoid=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_insectoid")},mammals:{id:"evolution-mammals",title:z("evo_mammals_title"),desc:z("evo_mammals_desc"),reqs:{evo:5,evo_mammals:1},grant:["evo",6],condition:()=>t.tech.evo&&5===t.tech.evo,cost:{DNA:()=>245},effect:z("evo_mammals_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_humanoid=1,t.tech.evo_giant=1,t.tech.evo_small=1,t.tech.evo_animalism=1,t.tech.evo_demonic=1,t.tech.evo_angelic=1,t.evolution.final=90,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},humanoid:{id:"evolution-humanoid",title:z("evo_humanoid_title"),desc:z("evo_humanoid_desc"),reqs:{evo:6,evo_humanoid:1},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_humanoid_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_humanoid_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_humanoid=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_humanoid")},gigantism:{id:"evolution-gigantism",title:z("evo_gigantism_title"),desc:z("evo_gigantism_desc"),reqs:{evo:6,evo_giant:1},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_gigantism_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_gigantism_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_giant=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_giant")},dwarfism:{id:"evolution-dwarfism",title:z("evo_dwarfism_title"),desc:z("evo_dwarfism_desc"),reqs:{evo:6,evo_small:1},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_dwarfism_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_dwarfism_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_small=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_small")},animalism:{id:"evolution-animalism",title:z("evo_animalism_title"),desc:z("evo_animalism_desc"),reqs:{evo:6,evo_animalism:1},grant:["evo",7],condition:()=>zr(6)&&t.tech.evo_animalism&&1===t.tech.evo_animalism,cost:{DNA:()=>250},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_animalism_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_animalism_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_animalism=2,t.evolution.final=95,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo&&1===t.tech.evo_animalism?1:0},carnivore:{id:"evolution-carnivore",title:z("evo_carnivore_title"),desc:z("evo_carnivore_desc"),reqs:{evo_animalism:2},grant:["evo_animalism",3],condition:()=>zr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_carnivore_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_carnivore_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo=7,t.tech.evo_carnivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Xs("genus_carnivore")},herbivore:{id:"evolution-herbivore",title:z("evo_herbivore_title"),desc:z("evo_herbivore_desc"),reqs:{evo_animalism:2},grant:["evo_animalism",3],condition:()=>zr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_herbivore_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_herbivore_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo=7,t.tech.evo_herbivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Xs("genus_herbivore")},omnivore:{id:"evolution-omnivore",title:z("evo_omnivore_title"),desc:z("evo_omnivore_desc"),reqs:{evo_animalism:2,locked:1},grant:["evo_animalism",3],condition:()=>zr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},wiki:!1,effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_omnivore_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_omnivore_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_omnivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Xs("genus_omnivore")},celestial:{id:"evolution-celestial",title:z("evo_celestial_title"),desc:z("evo_celestial_desc"),reqs:{evo:6,evo_angelic:1},grant:["evo",7],condition:()=>!!("eden"===t.city.biome||t.blood.unbound&&t.blood.unbound>=3)&&zr(6),cost:{DNA:()=>260},effect:()=>z("evo_celestial_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_angelic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_angelic")},demonic:{id:"evolution-demonic",title:z("evo_demonic_title"),desc:z("evo_demonic_desc"),reqs:{evo:6,evo_demonic:1},grant:["evo",7],condition:()=>!!("hellscape"===t.city.biome||t.blood.unbound&&t.blood.unbound>=3)&&zr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"===t.race.universe?`
                ${z("evo_demonic_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_demonic_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_demonic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_demonic")},eldritch:{id:"evolution-eldritch",title:z("evo_eldritch_title"),desc:z("evo_eldritch_desc"),reqs:{evo:5,evo_eldritch:1},grant:["evo",7],condition:()=>!(!t.stats.achieve.nightmare||!t.stats.achieve.nightmare.mg)&&zr(5),cost:{DNA:()=>260},effect:z("evo_eldritch_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_eldritch=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_eldritch")},aquatic:{id:"evolution-aquatic",title:z("evo_aquatic_title"),desc:z("evo_aquatic_desc"),reqs:{evo:5,evo_aquatic:1},grant:["evo",7],condition:()=>!(!["oceanic","swamp"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_aquatic_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_aquatic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_aquatic")},fey:{id:"evolution-fey",title:z("evo_fey_title"),desc:z("evo_fey_desc"),reqs:{evo:5,evo_fey:1},grant:["evo",7],condition:()=>!(!["forest","swamp","taiga"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_fey_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_fey=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_fey")},heat:{id:"evolution-heat",title:z("evo_heat_title"),desc:z("evo_heat_desc"),reqs:{evo:5,evo_heat:1},grant:["evo",7],condition:()=>!(!["volcanic","ashland"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_heat_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_heat=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_heat")},polar:{id:"evolution-polar",title:z("evo_polar_title"),desc:z("evo_polar_desc"),reqs:{evo:5,evo_polar:1},grant:["evo",7],condition:()=>!(!["tundra","taiga"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_polar_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_polar=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_polar")},sand:{id:"evolution-sand",title:z("evo_sand_title"),desc:z("evo_sand_desc"),reqs:{evo:5,evo_sand:1},grant:["evo",7],condition:()=>!(!["desert","ashland"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_sand_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_sand=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_sand")},eggshell:{id:"evolution-eggshell",title:z("evo_eggshell_title"),desc:z("evo_eggshell_desc"),reqs:{evo:5,evo_eggshell:1},grant:["evo",6],condition:()=>t.tech.evo&&5===t.tech.evo&&!t.evolution.gselect,cost:{DNA:()=>245},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_eggshell_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_eggshell_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_eggshell=2,t.evolution.final=90,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},endothermic:{id:"evolution-endothermic",title:()=>t.evolution.gselect?z("genelab_genus_avian"):z("evo_endothermic_title"),desc:z("evo_endothermic_desc"),reqs:{evo:6,evo_eggshell:2},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:z("evo_endothermic_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_avian=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_avian")},ectothermic:{id:"evolution-ectothermic",title:()=>t.evolution.gselect?z("genelab_genus_reptilian"):z("evo_ectothermic_title"),desc:z("evo_ectothermic_desc"),reqs:{evo:6,evo_eggshell:2},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:z("evo_ectothermic_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_reptilian=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_reptilian")},sentience:{id:"evolution-sentience",title:z("evo_sentience_title"),desc:z("evo_sentience_desc"),reqs:{evo:7},grant:["evo",8],condition:()=>t.tech.evo&&7===t.tech.evo&&100===t.evolution.final,cost:{RNA:()=>300,DNA:()=>300},effect:()=>t.evolution.exterminate?z("evo_sentience_ai_effect"):z("evo_sentience_effect"),action(){if(ri($(this)[0])){let e=[],a="humanoid";for(let e in Li)if(t.tech[`evo_${e}`]&&t.tech[`evo_${e}`]>=2){a=e;break}if(t.race.junker||t.race.sludge){let r=t.race.sludge?"sludge":"junker";t.race.jtype=a,e.push(r)}else for(let t in Fr){let r=Fr[t];Ki[r].type===a&&e.push(r)}t.race.species=e[Math.floor(m(0,e.length))],t.stats.achieve[`extinct_${t.race.species}`]&&t.stats.achieve[`extinct_${t.race.species}`].l>=1&&(t.race.species=e[Math.floor(m(0,e.length))]),hi()}return!1},emblem(){for(let e in Fr){let a=Fr[e];if(t.tech[`evo_${Ki[a].type}`]&&t.tech[`evo_${Ki[a].type}`]>=2)return Xs(`genus_${Ki[a].type}`)}return""},queue_complete:()=>t.tech.evo&&7===t.tech.evo?1:0}},city:{gift:{id:"city-gift",title:z("city_gift"),desc:z("city_gift_desc"),wiki:!1,category:"outskirts",reqs:{primitive:1},queue_complete:()=>0,not_tech:["santa"],not_trait:["cataclysm","lone_survivor"],class:["hgift"],condition(){const e=new Date;if(11!==e.getMonth()||11===e.getMonth()&&(e.getDate()<=16||e.getDate()>=25)){let e=!1;return t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(a){t.special.gift[a]&&(e=!0)})),e}return!1},count(){let e=0;return t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(a){t.special.gift[a]&&e++})),e},action(){if(!t.settings.pause){const e=new Date;let a=!1;if(t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(e){t.special.gift[e]&&(a=e)})),11!==e.getMonth()||11===e.getMonth()&&(e.getDate()<=16||e.getDate()>=25))if("g2019"===a)t.special&&t.special.gift&&(delete t.special.gift[a],"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=100,t.stats.antiplasmid+=100,hs(z("city_gift_msg",[100,z("arpa_genepool_effect_antiplasmid")]),"info",!1,["events"])):(t.prestige.Plasmid.count+=100,t.stats.plasmid+=100,hs(z("city_gift_msg",[100,z("arpa_genepool_effect_plasmid")]),"info",!1,["events"])),Wr());else if(t.special&&t.special.gift){delete t.special.gift[a];let e=100+(t.stats.hasOwnProperty("reset")?t.stats.reset:0)+(t.stats.hasOwnProperty("mad")?t.stats.mad:0),r=(t.stats.hasOwnProperty("bioseed")?t.stats.bioseed:0)+(t.stats.hasOwnProperty("cataclysm")?t.stats.cataclysm:0),i=[];if(t.stats.died+t.stats.tdied>0){let e=t.stats.died+t.stats.tdied;t.resource.Coal.amount+=e,i.push(`${e.toLocaleString()} ${z("resource_Coal_name")}`)}if("antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=e,t.stats.antiplasmid+=e,i.push(`${e.toLocaleString()} ${z("resource_AntiPlasmid_plural_name")}`)):(t.prestige.Plasmid.count+=e,t.stats.plasmid+=e,i.push(`${e.toLocaleString()} ${z("resource_Plasmid_plural_name")}`)),r>0&&(t.prestige.Phage.count+=r,t.stats.phage+=r,i.push(`${r.toLocaleString()} ${z("resource_Phage_name")}`)),t.stats.hasOwnProperty("achieve")){let e=t.stats.achieve.whitehole?t.stats.achieve.whitehole.l:0;e+=t.stats.achieve.heavy?t.stats.achieve.heavy.l:0,e+=t.stats.achieve.canceled?t.stats.achieve.canceled.l:0,e+=t.stats.achieve.eviltwin?t.stats.achieve.eviltwin.l:0,e+=t.stats.achieve.microbang?t.stats.achieve.microbang.l:0,e+=t.stats.achieve.pw_apocalypse?t.stats.achieve.pw_apocalypse.l:0;let r=t.stats.achieve.ascended?t.stats.achieve.ascended.l:0,s=t.stats.achieve.corrupted?t.stats.achieve.corrupted.l:0,n=t.stats.achieve.obsolete?t.stats.achieve.obsolete.l:0;if(e>30&&(e=30),r>5&&(r=5),s>5&&(s=5),e>0){let a=+(e/7.5).toFixed(2);t.prestige.Dark.count+=a,t.stats.dark+=a,i.push(`${a} ${z("resource_Dark_name")}`)}if(r>0&&(t.prestige.Harmony.count+=r,t.stats.harmony+=r,i.push(`${r} ${z("resource_Harmony_name")}`)),s>0){let e=5*s,a=s;t.prestige.Blood_Stone.count+=e,t.stats.blood+=e,t.prestige.Artifact.count+=a,t.stats.artifact+=a,i.push(`${e} ${z("resource_Blood_Stone_name")}`),i.push(`${a} ${z("resource_Artifact_name")}`)}"g2020"!==a&&n>0&&(t.prestige.AICore.count+=n,t.stats.cores+=n,i.push(`${n} ${z("resource_AICore_name")}`))}hs(z("city_gift2_msg",[i.join(", ")]),"info",!1,["events"]),Wr()}}return!1},touchlabel:z("open")},food:{id:"city-food",title:()=>ln().active?t.tech.conjuring?z("city_trick_conjure"):z("city_trick"):t.tech.conjuring?z("city_food_conjure"):z("city_food"),desc(){let e=$(this)[0].val(!1);return ln().active?t.tech.conjuring?z("city_trick_conjure_desc",[e]):z("city_trick_desc",[e]):t.tech.conjuring?z("city_food_conjure_desc",[e]):z("city_food_desc",[e])},category:"outskirts",reqs:{primitive:1},not_trait:["soul_eater","cataclysm","artifical"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring?1:0},action(){return t.settings.pause||(t.resource.Food.amount=1&&(a*=10,t.resource.Food.amountln().active?t.tech.conjuring&&t.tech.conjuring>=2?z("city_dig_conjour"):z("city_dig"):t.tech.conjuring&&t.tech.conjuring>=2?z("city_lumber_conjure"):z("city_lumber"),desc(){let e=$(this)[0].val(!1);return ln().active?t.tech.conjuring&&t.tech.conjuring>=2?z("city_dig_conjour_desc",[e]):z("city_dig_desc",[e]):t.tech.conjuring&&t.tech.conjuring>=2?z("city_lumber_conjure_desc",[e]):z("city_lumber_desc",[e])},category:"outskirts",reqs:{},not_trait:["evil","cataclysm"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||(t.resource.Lumber.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Lumber.amountt.tech.conjuring&&t.tech.conjuring>=2?z("city_conjour",[t.resource.Stone.name]):z("city_gather",[t.resource.Stone.name]),desc(){let e=$(this)[0].val(!1);return t.tech.conjuring&&t.tech.conjuring>=2?z("city_stone_conjour_desc",[e,t.resource.Stone.name]):z(t.race.sappy?"city_amber_desc":"city_stone_desc",[e,t.resource.Stone.name])},category:"outskirts",reqs:{primitive:2},not_trait:["cataclysm","lone_survivor"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||(t.resource.Stone.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Stone.amountt.tech.conjuring&&t.tech.conjuring>=2?z("city_chrysotile_conjour"):z("city_gather",[t.resource.Chrysotile.name]),desc(){let e=$(this)[0].val(!1);return t.tech.conjuring&&t.tech.conjuring>=2?z("city_stone_conjour_desc",[e,t.resource.Chrysotile.name]):z("city_stone_desc",[e,t.resource.Chrysotile.name])},category:"outskirts",reqs:{primitive:2},trait:["smoldering"],not_trait:["cataclysm","lone_survivor"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||t.resource.Chrysotile.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Chrysotile.amountt.race.soul_eater?t.tech.primitive?t.resource.hasOwnProperty("furs")&&t.resource.Furs.display?z("city_evil_desc3"):z("city_evil_desc2"):z("city_evil_desc1"):t.resource.hasOwnProperty("furs")&&t.resource.Furs.display?z("city_evil_desc4"):z("city_evil_desc1"),category:"outskirts",reqs:{},trait:["evil"],not_trait:["kindling_kindred","smoldering","cataclysm"],queue_complete:()=>0,action(){if(!t.settings.pause){let e=t.race.strong?Ei.strong.vars()[0]:1;t.genes.enhance&&(e*=2),t.race.smoldering||(t.resource.Lumber.amount25e3},queue_complete:()=>t.city.slave_pen?4*t.city.slave_pen.count-t.city.slave_pen.slaves:0,action(){return!!(t.city.slave_pen&&4*t.city.slave_pen.count>t.city.slave_pen.slaves&&ri($(this)[0]))&&(t.city.slave_pen.slaves++,t.resource.Slave.amount=t.city.slave_pen.slaves,!0)},touchlabel:z("purchase")},s_alter:{id:"city-s_alter",title:z("city_s_alter"),desc:()=>t.city.hasOwnProperty("s_alter")&&t.city.s_alter.count>=1?`
                ${z("city_s_alter")}
                ${z("city_s_alter_desc")}
                `:z("city_s_alter"),category:"outskirts",reqs:{mining:1},trait:["cannibalize"],not_trait:["cataclysm","lone_survivor"],inflation:!1,cost:{Stone:e=>(e||0)+(t.city.hasOwnProperty("s_alter")?t.city.s_alter.count:0)>=1?0:100},effect(){let e=`
                ${z("city_s_alter_sacrifice",[t.civic[t.civic.d_job]?t.civic[t.civic.d_job].workers:0])}
                `;if(t.city.hasOwnProperty("s_alter")&&t.city.s_alter.rage>0&&(e+=`
                ${z("city_s_alter_rage",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.rage)])}
                `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.regen>0&&(e+=`
                ${z("city_s_alter_regen",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.regen)])}
                `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.mind>0&&(e+=`
                ${z("city_s_alter_mind",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.mind)])}
                `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.mine>0&&(e+=`
                ${z("city_s_alter_mine",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.mine)])}
                `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.harvest>0){let a=t.race.evil&&!t.race.soul_eater?z("job_reclaimer"):z("job_lumberjack");e+=`
                ${z("city_s_alter_harvest",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.harvest),a])}
                `}return e},action(){if(ri($(this)[0])){if(0===t.city.s_alter.count)t.city.s_alter.count++;else if(t.civic[t.civic.d_job].workers>0){t.resource[t.race.species].amount--,t.civic[t.civic.d_job].workers--,t.stats.sac++,t.resource.Food.amount+=Math.rand(250,1e3);let e=300,a=600;if(t.tech.sacrifice)switch(t.tech.sacrifice){case 1:e=600,a=1500;break;case 2:e=1800,a=3600;break;case 3:e=5400,a=16200}switch(t.race.kindling_kindred||t.race.smoldering?Math.rand(0,4):Math.rand(0,5)){case 0:t.city.s_alter.rage+=Math.rand(e,a);break;case 1:t.city.s_alter.mind+=Math.rand(e,a);break;case 2:t.city.s_alter.regen+=Math.rand(e,a);break;case 3:t.city.s_alter.mine+=Math.rand(e,a);break;case 4:t.city.s_alter.harvest+=Math.rand(e,a)}}return!0}return!1},touchlabel:z("tech_dist_sacrifice")},basic_housing:{id:"city-basic_housing",title:()=>di(),desc:z("city_basic_housing_desc"),desc(){return 1===$(this)[0].citizens()?z("city_basic_housing_desc"):z("city_basic_housing_desc_plural",[$(this)[0].citizens()])},category:"residential",reqs:{housing:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.basic_housing?t.city.basic_housing.count:0)+e>=5?qs("basic_housing",e,20,1.17):0),Lumber:e=>t.race.kindling_kindred||t.race.smoldering?0:qs("basic_housing",e,10,1.23),Stone:e=>t.race.kindling_kindred?qs("basic_housing",e,10,1.23):0,Chrysotile:e=>t.race.smoldering?qs("basic_housing",e,10,1.23):0,Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.sappy?`
                ${z("plus_max_resource",[e,z("citizen")])}
                ${z("city_grove_effect",[2.5])}
                `:z("plus_max_resource",[e,z("citizen")])},action(){return!!ri($(this)[0])&&(t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=$(this)[0].citizens(),t.city.basic_housing.count++,t.settings.showCivic=!0,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},cottage:{id:"city-cottage",title:()=>pi("medium"),desc(){return z("city_cottage_desc",[$(this)[0].citizens()])},category:"residential",reqs:{housing:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("cottage",e,900,1.15),Plywood:e=>qs("cottage",e,25,1.25),Brick:e=>qs("cottage",e,20,1.25),Wrought_Iron:e=>qs("cottage",e,15,1.25),Iron:e=>t.city.ptrait.includes("unstable")?qs("cottage",e,5,1.25):0,Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens();if(t.tech.home_safe){let a=br(t.tech.home_safe>=2?t.tech.home_safe>=3?5e3:2e3:1e3);return`
                ${z("plus_max_citizens",[e])}
                ${z("plus_max_resource",[`$${a.toLocaleString()}`,z("resource_Money_name")])}
                `}return z("plus_max_citizens",[e])},action(){return!!ri($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens(),t.city.cottage.count++,!0)},citizens(){let e=2;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},apartment:{id:"city-apartment",title:()=>pi("large"),desc(){return`
                ${z("city_apartment_desc",[$(this)[0].citizens()])}
                ${z("requires_power")}
                `},category:"residential",reqs:{housing:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("apartment",e,1750,1.26)-500,Crystal:e=>"magic"===t.race.universe?qs("apartment",e,25,1.22):0,Furs:e=>qs("apartment",e,725,1.32)-500,Copper:e=>qs("apartment",e,650,1.32)-500,Cement:e=>qs("apartment",e,700,1.32)-500,Steel:e=>qs("apartment",e,800,1.32)-500,Horseshoe:()=>t.race.hooved?5:0},effect(){let e=K("extravagant",2),a=$(this)[0].citizens();if(t.tech.home_safe){let r=br(t.tech.home_safe>=2?t.tech.home_safe>=3?1e4:5e3:2e3);return e&&(r*=2),`
                ${z("plus_max_citizens",[a])}. ${z("minus_power",[$(this)[0].powered()])}
                ${z("plus_max_resource",[`$${r.toLocaleString()}`,z("resource_Money_name")])}
                `}return`${z("plus_max_citizens",[a])}. ${z("minus_power",[$(this)[0].powered()])}`},powered:()=>As(K("extravagant",1)||1),action(){return!!ri($(this)[0])&&(t.city.apartment.count++,Yr($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens()),!0)},citizens(){let e=K("extravagant",2),a=e?5+e:5;return t.race.high_pop&&(a*=Ei.high_pop.vars()[0]),a}},lodge:{id:"city-lodge",title:z("city_lodge"),desc:()=>t.race.detritivore?z("city_lodge_desc_alt"):z("city_lodge_desc"),category:"residential",reqs:{housing:1,currency:1},not_trait:["cataclysm","lone_survivor"],condition:()=>!!((t.race.soul_eater||t.race.detritivore||t.race.artifical||t.race.unfathomable)&&t.tech.s_lodge||t.tech.hunting&&t.tech.hunting>=2),cost:{Money:e=>qs("lodge",e,50,1.32),Lumber:e=>qs("lodge",e,20,1.36),Stone:e=>qs("lodge",e,10,1.36),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.carnivore&&!t.race.artifical?`
                ${z("plus_max_resource",[e,z("citizen")])}
                ${z("city_lodge_effect",[5])}
                `:z("plus_max_resource",[e,z("citizen")])},action(){return!!ri($(this)[0])&&(t.city.lodge.count++,t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=1,t.settings.showCivic=!0,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},smokehouse:{id:"city-smokehouse",title:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("city_smokehouse_easter"):z("city_smokehouse"),desc:z("city_smokehouse_desc"),category:"trade",reqs:{hunting:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("smokehouse",e,85,1.32),Lumber:e=>qs("smokehouse",e,65,1.36),Stone:e=>qs("smokehouse",e,50,1.36)},effect:()=>`
                ${z("plus_max_resource",[Br(br(100)),z("resource_Food_name")])}
                ${z("city_smokehouse_effect",[10])}
                `,action(){return!!ri($(this)[0])&&(t.city.smokehouse.count++,t.resource.Food.max+=Br(br(100)),!0)}},soul_well:{id:"city-soul_well",title:z("city_soul_well"),desc:z("city_soul_well_desc"),category:"trade",reqs:{soul_eater:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.soul_well?t.city.soul_well.count:0)+e>=3?qs("soul_well",e,50,1.32):0),Lumber:e=>qs("soul_well",e,20,1.36),Stone:e=>qs("soul_well",e,10,1.36)},effect(){let e=Br(br(500));return`
                ${z("city_soul_well_effect",[t.race.ghostly?2+Ei.ghostly.vars()[1]:2])}
                ${z("plus_max_resource",[e,z("resource_Souls_name")])}
                `},action(){return!!ri($(this)[0])&&(t.city.soul_well.count++,t.resource.Food.max+=Br(br(500)),!0)}},slave_pen:{id:"city-slave_pen",title:z("city_slave_pen"),desc:z("city_slave_pen"),category:"commercial",reqs:{slaves:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("slave_pen",e,250,1.32),Lumber:e=>qs("slave_pen",e,100,1.36),Stone:e=>qs("slave_pen",e,75,1.36),Copper:e=>qs("slave_pen",e,10,1.36),Nanite:e=>t.race.deconstructor?qs("slave_pen",e,4,1.36):0},effect(){let e=t.city.slave_pen?4*t.city.slave_pen.count:4,a=t.city.slave_pen?t.city.slave_pen.slaves:0;return`
                ${z("city_slave_pen_effect",[4])}
                ${z("city_slave_pen_effect2",[a,e])}
                `},action(){return!!ri($(this)[0])&&(t.city.slave_pen.count++,t.resource.Slave.display=!0,t.resource.Slave.amount=t.city.slave_pen.slaves,t.resource.Slave.max=4*t.city.slave_pen.count,!0)}},transmitter:{id:"city-transmitter",title:z("city_transmitter"),desc:()=>`
                ${z("city_transmitter_desc")}
                ${z("requires_power")}
                `,category:"residential",reqs:{high_tech:4},trait:["artifical"],cost:{Money:e=>t.city.transmitter&&t.city.transmitter.count>=3?qs("transmitter",e,50,1.32):0,Copper:e=>qs("transmitter",e,20,1.36),Steel:e=>qs("transmitter",e,10,1.36)},effect(){let e=+$e("transmitter").toFixed(2),a=br(100);return`
                ${z("gain",[e,t.resource.Food.name])}
                ${z("city_transmitter_effect",[a])}
                ${z("minus_power",[$(this)[0].powered()])}
                `},powered:()=>As(.5),powerBalancer:()=>[{r:"Food",k:"lpmod"}],action(){return!!ri($(this)[0])&&(t.city.transmitter.count++,Yr($(this)[0]),!0)}},captive_housing:Cr("captive_housing","city"),farm:{id:"city-farm",title:z("city_farm"),desc:z("city_farm_desc"),category:"residential",reqs:{agriculture:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.farm?t.city.farm.count:0)+e>=3?qs("farm",e,50,1.32):0),Lumber:e=>qs("farm",e,20,1.36),Stone:e=>qs("farm",e,10,1.36),Horseshoe:e=>t.race.hooved&&(t.city.farm?t.city.farm.count:0)+(e||0)>=2?1:0},effect(){let e=$(this)[0].citizens();return t.tech.farm?`
                ${z("city_farm_effect")}
                ${z("plus_max_resource",[e,z("citizen")])}
                `:z("city_farm_effect")},action(){return!!ri($(this)[0])&&(t.city.farm.count++,t.civic.farmer.display=!0,t.tech.farm&&(t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=$(this)[0].citizens(),t.settings.showCivic=!0),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e},flair:()=>t.tech.agriculture>=7?z("city_farm_flair2"):z("city_farm_flair1")},compost:{id:"city-compost",title:z("city_compost_heap"),desc:z("city_compost_heap_desc"),category:"residential",reqs:{compost:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.compost?t.city.compost.count:0)+e>=3?qs("compost",e,50,1.32):0),Lumber:e=>qs("compost",e,12,1.36),Stone:e=>qs("compost",e,12,1.36)},effect(){let e=1.2+.8*(t.tech.compost?t.tech.compost:0);e*="grassland"===t.city.biome?is.grassland.vars()[0]:1,e*="savanna"===t.city.biome?is.savanna.vars()[0]:1,e*="ashland"===t.city.biome?is.ashland.vars()[0]:1,e*="volcanic"===t.city.biome?is.volcanic.vars()[0]:1,e*="hellscape"===t.city.biome?is.hellscape.vars()[0]:1,e*=t.city.ptrait.includes("trashed")?ss.trashed.vars()[0]:1,e=+e.toFixed(2);let a=Br(br(200)),r=t.race.kindling_kindred?"":`
                ${z("city_compost_heap_effect2",[.5,t.resource.Lumber.name])}
                `;return`
                ${z("city_compost_heap_effect",[e])}
                ${z("city_compost_heap_effect3",[a])}
                ${r}`},switchable:()=>!0,action(){return!!ri($(this)[0])&&(t.city.compost.count++,t.city.compost.on++,t.resource.Food.max+=Br(br(200)),!0)}},mill:{id:"city-mill",title:()=>t.tech.agriculture>=5?z("city_mill_title2"):z("city_mill_title1"),desc(){let e=t.tech.agriculture>=5?5:3;return t.tech.agriculture>=6?z("city_mill_desc2",[e,-1*$(this)[0].powered()]):z("city_mill_desc1",[e])},category:"utility",reqs:{agriculture:4},not_tech:["wind_plant"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("mill",e,1e3,1.31),Lumber:e=>qs("mill",e,600,1.33),Iron:e=>qs("mill",e,150,1.33),Cement:e=>qs("mill",e,125,1.33)},powered:()=>t.race.environmentalist?-1.5:-1,power_reqs:{agriculture:6},effect:()=>t.tech.agriculture>=6&&`${z("city_on")} ${z("city_mill_effect1")} ${z("city_off")} ${z("city_mill_effect2")}`,action(){return!!ri($(this)[0])&&(t.city.mill.count++,!0)}},windmill:{id:"city-windmill",title:()=>t.race.unfathomable?z("tech_watermill"):z("city_mill_title2"),desc:()=>t.race.unfathomable?z("tech_watermill"):z("city_mill_title2"),wiki:!1,category:"utility",reqs:{wind_plant:1},not_trait:["cataclysm","lone_survivor"],powered:()=>t.race.environmentalist?-1.5:-1,power_reqs:{false:1},cost:{Money:e=>qs("windmill",e,1e3,1.31),Lumber:e=>qs("windmill",e,600,1.33),Iron:e=>qs("windmill",e,150,1.33),Cement:e=>qs("windmill",e,125,1.33)},effect(){return`
                ${z("space_dwarf_reactor_effect1",[-1*$(this)[0].powered()])}
                `},action(){return!!ri($(this)[0])&&(t.city.windmill.count++,!0)}},silo:{id:"city-silo",title:z("city_silo"),desc:z("city_food_storage"),category:"trade",reqs:{agriculture:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("silo",e,85,1.32),Lumber:e=>qs("silo",e,65,1.36),Stone:e=>qs("silo",e,50,1.36),Iron:e=>(t.city.silo?t.city.silo.count:0)+(e||0)>=4&&t.city.ptrait.includes("unstable")?qs("silo",e,10,1.36):0},effect:()=>z("plus_max_resource",[Br(br(500)),z("resource_Food_name")]),action(){return!!ri($(this)[0])&&(t.city.silo.count++,t.resource.Food.max+=Br(br(500)),!0)}},assembly:Cr("assembly","city"),garrison:{id:"city-garrison",title:()=>t.race.flier?z("city_garrison_flier"):z("city_garrison"),desc:z("city_garrison_desc"),category:"military",reqs:{military:1,housing:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("garrison",e,240,1.5),Stone:e=>qs("garrison",e,260,1.46),Iron:e=>(t.city.garrison?t.city.garrison.count:0)+(e||0)>=4&&t.city.ptrait.includes("unstable")?qs("garrison",e,50,1.4):0,Horseshoe:()=>t.race.hooved?t.race.chameleon?1:2:0},effect(){let e=t.tech.military>=5?ta(3):ta(2);return t.race.chameleon&&e--,z("plus_max_resource",[e,z("civics_garrison_soldiers")])},switchable:()=>!0,action(){if(ri($(this)[0])){t.settings.showMil=!0,t.settings.msgFilters.combat.unlocked||(t.settings.msgFilters.combat.unlocked=!0,t.settings.msgFilters.combat.vis=!0),t.civic.garrison.display||(t.civic.garrison.display=!0,Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update"));let e=t.tech.military>=5?3:2;return t.race.chameleon&&(e-=t.city.garrison.count),t.civic.garrison.max+=e,t.city.garrison.count++,t.city.garrison.on++,t.resource.Furs.display=!0,!0}return!1}},hospital:{id:"city-hospital",title:z("city_hospital"),desc:z("city_hospital_desc"),category:"military",reqs:{medic:1},not_trait:["cataclysm","artifical"],cost:{Money:e=>qs("hospital",e,22e3,1.32),Furs:e=>qs("hospital",e,4e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?qs("hospital",e,500,1.32):0,Aluminium:e=>qs("hospital",e,1e4,1.32)},effect(){let e=t.tech.reproduction&&t.tech.reproduction>=2?`
                ${z("city_hospital_effect2")}
                `:"",a=`
                ${z("city_hospital_effect",[5*t.tech.medic])}
                ${e}`;return!t.race.artifical&&t.race.hasOwnProperty("vax")&&(a+=`
                ${z("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
                `),a},action(){return!!ri($(this)[0])&&(t.city.hospital.count++,!0)}},boot_camp:{id:"city-boot_camp",title:()=>t.race.artifical?z("city_boot_camp_art"):z("city_boot_camp"),desc:()=>t.race.artifical?z("city_boot_camp_art_desc",[Ki[t.race.species].name]):z("city_boot_camp_desc"),category:"military",reqs:{boot_camp:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("boot_camp",e,5e4,1.32),Lumber:e=>qs("boot_camp",e,21500,1.32),Iron:e=>t.city.ptrait.includes("unstable")?qs("boot_camp",e,300,1.32):0,Aluminium:e=>qs("boot_camp",e,12e3,1.32),Brick:e=>qs("boot_camp",e,1400,1.32)},effect(){let e=t.tech.boot_camp>=2?8:5;t.blood.lust&&(e+=.2*t.blood.lust);let a=K("militant",0);a&&(e*=1+a/100);let r=t.tech.spy&&t.tech.spy>=3?`
                ${z("city_boot_camp_effect",[e])}
                ${z("city_boot_camp_effect2",[10])}
                `:`
                ${z("city_boot_camp_effect",[e])}
                `;return t.race.artifical&&!t.race.orbit_decayed&&(r+=`
                ${z("city_boot_camp_art_effect",[5*(t.tech.medic||1)])}
                `),t.race.artifical&&t.race.hasOwnProperty("vax")&&(desc+=`
                ${z("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
                `),r},action(){return!!ri($(this)[0])&&(t.city.boot_camp.count++,!0)}},shed:{id:"city-shed",title:()=>t.tech.storage<=2?z("city_shed_title1"):t.tech.storage>=4?z("city_shed_title3"):z("city_shed_title2"),desc(){let e=t.tech.storage>=3?t.tech.storage>=4?z("city_shed_desc_size3"):z("city_shed_desc_size2"):z("city_shed_desc_size1");return z("city_shed_desc",[e])},category:"trade",reqs:{storage:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("shed",e,75,1.22),Lumber:e=>t.tech.storage&&t.tech.storage<4?qs("shed",e,55,1.32):0,Stone:e=>t.tech.storage&&t.tech.storage<3?qs("shed",e,45,1.32):0,Iron:e=>t.tech.storage&&t.tech.storage>=4?qs("shed",e,22,1.32):0,Cement:e=>t.tech.storage&&t.tech.storage>=3?qs("shed",e,18,1.32):0},res(){let e=["Lumber","Stone","Chrysotile","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal"];return t.tech.storage>=3&&t.resource.Steel.display&&e.push("Steel"),t.tech.storage>=4&&t.resource.Titanium.display&&e.push("Titanium"),t.tech.shelving&&t.tech.shelving>=3&&t.resource.Graphene.display&&e.push("Graphene"),t.tech.shelving&&t.tech.shelving>=3&&t.resource.Stanene.display&&e.push("Stanene"),t.race.unfathomable&&e.push("Food"),e},val(e){switch(e){case"Food":return 50;case"Lumber":case"Stone":case"Chrysotile":return 300;case"Crystal":return 8;case"Furs":case"Iron":return 125;case"Copper":case"Aluminium":return 90;case"Cement":return 100;case"Coal":return 75;case"Steel":return 40;case"Titanium":return 20;case"Graphene":return 15;case"Stanene":return 25;default:return 0}},effect(){let e='
                ',a=Gr();for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${z("plus_max_resource",[x(+(br($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return e+="
                ",e},wide:!0,action(){if(ri($(this)[0])){t.city.shed.count++;let e=Gr();for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=br($(this)[0].val(a)*e));return!0}return!1}},storage_yard:{id:"city-storage_yard",title:z("city_storage_yard"),desc:z("city_storage_yard_desc"),category:"trade",reqs:{container:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("storage_yard",e,10,yi(1.36)),Brick:e=>qs("storage_yard",e,3,yi(1.35)),Wrought_Iron:e=>qs("storage_yard",e,5,yi(1.35))},effect(){let e=t.tech.container>=3?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.tech.trade&&t.tech.trade>=3?`
                ${z("plus_max_resource",[e,z("resource_Crates_name")])}
                ${z("city_trade_effect",[1])}
                `:z("plus_max_resource",[e,z("resource_Crates_name")])},action(){if(ri($(this)[0])){!1===t.resource.Crates.display&&hs(z("city_storage_yard_msg"),"info",!1,["progress"]),t.city.storage_yard.count++,t.settings.showResources=!0,t.settings.showStorage=!0,t.settings.showMarket||(t.settings.marketTabs=1);let e=t.tech.container>=3?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Crates.max+=e,t.resource.Crates.display||(t.resource.Crates.display=!0,Ss($("#resources")),Da(),t.settings.tabLoad&&(Ka("storage"),L())),!0}return!1}},warehouse:{id:"city-warehouse",title:z("city_warehouse"),desc:z("city_warehouse_desc"),category:"trade",reqs:{steel_container:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("warehouse",e,400,yi(1.26)),Cement:e=>qs("warehouse",e,75,yi(1.26)),Sheet_Metal:e=>qs("warehouse",e,25,yi(1.25))},effect(){let e=t.tech.steel_container>=2?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),z("plus_max_resource",[e,z("resource_Containers_name")])},action(){if(ri($(this)[0])){!1===t.resource.Containers.display&&hs(z("city_warehouse_msg"),"info",!1,["progress"]),t.city.warehouse.count++,t.settings.showResources=!0,t.settings.showStorage=!0;let e=t.tech.steel_container>=2?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Containers.max+=e,t.resource.Containers.display||(t.resource.Containers.display=!0,Ss($("#resources")),Da(),t.settings.tabLoad&&Ka("storage")),!0}return!1}},bank:{id:"city-bank",title:z("city_bank"),desc:()=>z("city_bank_desc",[Ki[t.race.species].home]),category:"commercial",reqs:{banking:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("bank",e,250,1.35),Lumber:e=>qs("bank",e,75,1.32),Stone:e=>qs("bank",e,100,1.35),Iron:e=>(t.city.bank?t.city.bank.count:0)+(e||0)>=2&&t.city.ptrait.includes("unstable")?qs("bank",e,30,1.3):0},effect(){let e=bi();return e=br(e),e=(+e.toFixed(0)).toLocaleString(),t.tech.banking>=2?`
                ${z("plus_max_resource",[`$${e}`,z("resource_Money_name")])}
                ${z("plus_max_resource",[ta(1),z("banker_name")])}
                `:z("plus_max_resource",[`$${e}`,z("resource_Money_name")])},action(){return!!ri($(this)[0])&&(t.resource.Money.max+=br(1800),t.city.bank.count++,t.civic.banker.max=ta(t.city.bank.count),!0)}},pylon:{id:"city-pylon",title:z("city_pylon"),desc:z("city_pylon"),category:"industrial",reqs:{magic:2},not_trait:["cataclysm","orbit_decayed"],cost:{Money:e=>(e=e||0,(t.city.pylon?t.city.pylon.count:0)+e>=2?qs("pylon",e,10,1.48):0),Stone:e=>qs("pylon",e,12,1.42),Crystal:e=>qs("pylon",e,8,1.42)-3},effect(){let e=br(5);return`
                ${z("gain",[+(.01*Is("magic")).toFixed(3),t.resource.Mana.name])}
                ${z("plus_max_resource",[e,t.resource.Mana.name])}
                `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!ri($(this)[0])&&(t.city.pylon.count++,t.resource.Mana.max+=br(5),!0)}},conceal_ward:{id:"city-conceal_ward",title:z("city_conceal_ward"),desc:z("city_conceal_ward"),category:"industrial",reqs:{roguemagic:3},not_trait:["cataclysm","orbit_decayed"],cost:{Money:e=>qs("conceal_ward",e,500,1.25),Mana:e=>{return qs("conceal_ward",e,(a=42,t.tech.nexus&&t.tech.roguemagic&&t.tech.roguemagic>=7&&(a*=.92**t.tech.nexus),a),1.25);var a},Crystal:e=>qs("conceal_ward",e,5,1.25)},effect:()=>`
                ${z("city_conceal_ward_effect",[t.tech.roguemagic&&t.tech.roguemagic>=8?1.25:1])}
                `,action(){return!!ri($(this)[0])&&(t.city.conceal_ward.count++,!0)}},graveyard:{id:"city-graveyard",title:z("city_graveyard"),desc:z("city_graveyard_desc"),category:"industrial",reqs:{reclaimer:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.graveyard?t.city.graveyard.count:0)+e>=5?qs("graveyard",e,5,1.85):0),Lumber:e=>qs("graveyard",e,2,1.95),Stone:e=>qs("graveyard",e,6,1.9)},effect(){let e=Br(br(100));return`
                ${z("city_graveyard_effect",[8])}
                ${z("plus_max_resource",[e,t.resource.Lumber.name])}
                `},action(){return!!ri($(this)[0])&&(t.city.graveyard.count++,t.resource.Lumber.max+=Br(br(100)),!0)}},lumber_yard:{id:"city-lumber_yard",title:z("city_lumber_yard"),desc:z("city_lumber_yard_desc"),category:"industrial",reqs:{axe:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.lumber_yard?t.city.lumber_yard.count:0)+e>=5?qs("lumber_yard",e,5,1.85):0),Lumber:e=>qs("lumber_yard",e,6,1.9),Stone:e=>qs("lumber_yard",e,2,1.95)},effect(){let e=Br(br(100));return`
                ${z("city_lumber_yard_effect",[2])}
                ${z("plus_max_resource",[e,t.resource.Lumber.name])}
                `},action(){return!!ri($(this)[0])&&(t.city.lumber_yard.count++,t.civic.lumberjack.display=!0,t.resource.Lumber.max+=Br(br(100)),!0)}},sawmill:{id:"city-sawmill",title:z("city_sawmill"),desc:z("city_sawmill_desc"),category:"industrial",reqs:{saw:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("sawmill",e,3e3,1.26),Iron:e=>qs("sawmill",e,400,1.26),Cement:e=>qs("sawmill",e,420,1.26)},effect(){let e=t.tech.saw>=2?8:5,a=`
                ${z("plus_max_resource",[Br(br(200)),t.resource.Lumber.name])}
                ${z("city_lumber_yard_effect",[e])}
                `;return t.tech.foundry&&t.tech.foundry>=4&&(a+=`
                ${z("city_sawmill_effect2",[2])}
                `),t.city.powered&&(a+=`
                ${z("city_sawmill_effect3",[4,$(this)[0].powered()])}
                `),a},powered:()=>As(1),powerBalancer:()=>!!t.city.sawmill.hasOwnProperty("psaw")&&[{r:"Lumber",k:"psaw"}],action(){return!!ri($(this)[0])&&(t.city.sawmill.count++,t.resource.Lumber.max+=Br(br(200)),Yr($(this)[0]),!0)}},rock_quarry:{id:"city-rock_quarry",title:()=>t.race.flier?z("city_rock_quarry_alt"):z("city_rock_quarry"),desc:()=>t.race.flier?z("city_rock_quarry_desc_alt",[t.resource.Stone.name]):z("city_rock_quarry_desc"),category:"industrial",reqs:{mining:1},not_trait:["cataclysm","sappy"],cost:{Money:e=>(e=e||0,(t.city.rock_quarry?t.city.rock_quarry.count:0)+e>=2?qs("rock_quarry",e,20,1.45):0),Lumber:e=>qs("rock_quarry",e,50,1.36),Stone:e=>qs("rock_quarry",e,10,1.36)},effect(){let e=Br(br(100)),a=t.race.smoldering?`
                ${z("plus_max_resource",[e,t.resource.Chrysotile.name])}
                `:"";return t.tech.mine_conveyor?`
                ${z("city_rock_quarry_effect1",[2])}
                ${z("plus_max_resource",[e,t.resource.Stone.name])}
                ${a}
                ${z("city_rock_quarry_effect2",[4,$(this)[0].powered()])}
                `:`
                ${z("city_rock_quarry_effect1",[2])}
                ${z("plus_max_resource",[e,t.resource.Stone.name])}
                ${a}`},special:()=>!!t.race.smoldering,powered:()=>As(1),powerBalancer:()=>!!t.city.rock_quarry.hasOwnProperty("cnvay")&&(t.city.hasOwnProperty("metal_refinery")&&t.city.rock_quarry.hasOwnProperty("almcvy")?[{r:"Stone",k:"cnvay"},{r:"Aluminium",k:"almcvy"}]:[{r:"Stone",k:"cnvay"}]),power_reqs:{mine_conveyor:1},action(){if(ri($(this)[0])){t.city.rock_quarry.count++,t.civic.quarry_worker.display=!0;let e=Br(br(100));return t.resource.Stone.max+=e,t.race.smoldering&&t.resource.Chrysotile.display&&(t.settings.showCivic=!0,t.settings.showIndustry=!0,t.resource.Chrysotile.max+=e),t.tech.mine_conveyor&&Yr($(this)[0]),!0}return!1}},cement_plant:{id:"city-cement_plant",title:z("city_cement_plant"),desc:z("city_cement_plant_desc"),category:"industrial",reqs:{cement:1},not_trait:["cataclysm","lone_survivor","flier"],cost:{Money:e=>qs("cement_plant",e,3e3,1.5),Lumber:e=>qs("cement_plant",e,1800,1.36),Stone:e=>qs("cement_plant",e,2e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?qs("cement_plant",e,275,1.32):0},effect(){if(t.tech.cement>=5){let e=t.tech.cement>=6?8:5;return`
                ${z("city_cement_plant_effect1",[ta(2)])}
                ${z("city_cement_plant_effect2",[$(this)[0].powered(),e])}
                `}return z("city_cement_plant_effect1",[ta(2)])},powered:()=>As(2),powerBalancer:()=>!!t.city.cement_plant.hasOwnProperty("cnvay")&&[{r:"Cement",k:"cnvay"}],power_reqs:{cement:5},action(){return!!ri($(this)[0])&&(t.resource.Cement.display=!0,t.city.cement_plant.count++,t.civic.cement_worker.display=!0,t.civic.cement_worker.max=t.city.cement_plant.count*ta(2),t.tech.cement&&t.tech.cement>=5&&Yr($(this)[0]),!0)}},foundry:{id:"city-foundry",title:z("city_foundry"),desc:z("city_foundry_desc"),category:"industrial",reqs:{foundry:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("foundry",e,750,1.36),Stone:e=>qs("foundry",e,100,1.36),Copper:e=>qs("foundry",e,250,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("foundry",e,40,1.36):0},effect(){let e=`
                ${z("city_foundry_effect1",[ta(1)])}
                `;return t.tech.foundry>=2&&(e+=`
                ${z("city_crafted_mats",[t.tech.foundry>=5?t.tech.foundry>=8?8:5:3])}
                `),t.tech.foundry>=6&&(e+=`
                ${z("city_foundry_effect2",[2])}
                `),e},action(){return!!ri($(this)[0])&&(0===t.city.foundry.count&&(t.race.no_craft?hs(z("city_foundry_msg2"),"info",!1,["progress"]):hs(z("city_foundry_msg1"),"info",!1,["progress"])),t.city.foundry.count++,t.civic.craftsman.max+=ta(1),t.civic.craftsman.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.resource.Plywood.display=!0),t.resource.Brick.display=!0,t.resource.Iron.display&&(t.resource.Wrought_Iron.display=!0),t.resource.Aluminium.display&&(t.resource.Sheet_Metal.display=!0),sa(),!0)}},factory:{id:"city-factory",title:z("city_factory"),desc:`
                ${z("city_factory_desc")}
                ${z("requires_power")}
                `,category:"industrial",reqs:{high_tech:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("factory",e,25e3,ci(1.32)),Cement:e=>qs("factory",e,1e3,ci(1.32)),Steel:e=>qs("factory",e,7500,ci(1.32)),Titanium:e=>qs("factory",e,2500,ci(1.32))},effect(){let e=`
                ${z("city_factory_effect")}
                ${z("minus_power",[$(this)[0].powered()])}
                `;return t.tech.foundry>=7&&(e+=`
                ${z("city_crafted_mats",[5])}
                `),e},powered:()=>As(3),special:!0,action(){return!!ri($(this)[0])&&(t.city.factory.count++,t.resource.Alloy.display=!0,t.tech.polymer&&(t.resource.Polymer.display=!0),Yr($(this)[0])&&t.city.factory.Alloy++,t.settings.showIndustry=!0,ki(),!0)}},nanite_factory:Cr("nanite_factory","city"),smelter:{id:"city-smelter",title:z("city_smelter"),desc:z("city_smelter_desc"),category:"industrial",reqs:{smelting:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("smelter",e,1e3,ci(1.32)),Iron:e=>qs("smelter",e,500,ci(1.33))},effect(){var e=t.tech.smelting>=3?t.tech.smelting>=7?15:12:10;return t.race.pyrophobia&&(e*=.9),t.tech.smelting>=2&&!t.race.steelen?z("city_smelter_effect2",[e]):z("city_smelter_effect1",[e])},special:!0,action(){return!!ri($(this)[0])&&(t.city.smelter.count++,t.race.kindling_kindred||t.race.smoldering||t.race.artifical?t.race.artifical?t.city.smelter.Oil++:t.race.evil?t.city.smelter.Wood++:t.city.smelter.Coal++:t.city.smelter.Wood++,t.city.smelter.Iron++,t.settings.showIndustry=!0,ki(),!0)},flair:`
                ${z("city_smelter_flair1")}
                ${z("city_smelter_flair2")}
                `},metal_refinery:{id:"city-metal_refinery",title:z("city_metal_refinery"),desc:z("city_metal_refinery_desc"),category:"industrial",reqs:{alumina:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("metal_refinery",e,2500,1.35),Iron:e=>t.city.ptrait.includes("unstable")?qs("metal_refinery",e,125,1.35):0,Steel:e=>qs("metal_refinery",e,350,1.35)},powered:()=>As(2),powerBalancer:()=>!!t.city.metal_refinery.hasOwnProperty("pwr")&&[{r:"Aluminium",k:"cnvay"}],power_reqs:{alumina:2},effect(){let e=t.race.sappy?"city_metal_refinery_effect_alt":"city_metal_refinery_effect";return t.tech.alumina>=2?`${z(e,[6])} ${z("city_metal_refinery_effect2",[6,12,$(this)[0].powered()])}`:z(e,[6])},action(){return!!ri($(this)[0])&&(t.city.metal_refinery.count++,t.resource.Aluminium.display=!0,t.city.foundry&&t.city.foundry.count>0&&!t.resource.Sheet_Metal.display&&(t.resource.Sheet_Metal.display=!0,sa()),t.tech.alumina>=2&&Yr($(this)[0]),!0)}},mine:{id:"city-mine",title:z("city_mine"),desc:z("city_mine_desc"),category:"industrial",reqs:{mining:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("mine",e,60,ci(1.6)),Lumber:e=>qs("mine",e,175,ci(1.38))},effect(){return t.tech.mine_conveyor?`
                ${z("city_mine_effect1",[ta(1)])}
                ${z("city_mine_effect2",[$(this)[0].powered(),5])}
                `:z("city_mine_effect1",[ta(1)])},powered:()=>As(1),powerBalancer:()=>!(!t.city.mine.hasOwnProperty("cpow")||!t.city.mine.hasOwnProperty("ipow"))&&[{r:"Copper",k:"cpow"},{r:"Iron",k:"ipow"}],power_reqs:{mine_conveyor:1},action(){return!!ri($(this)[0])&&(t.city.mine.count++,t.resource.Copper.display=!0,t.civic.miner.display=!0,t.civic.miner.max=ta(t.city.mine.count),t.tech.mine_conveyor&&Yr($(this)[0]),!0)},flair:()=>"avian"===Ki[t.race.species].type?z("city_mine_flair_avian"):""},coal_mine:{id:"city-coal_mine",title:z("city_coal_mine"),desc:z("city_coal_mine_desc"),category:"industrial",reqs:{mining:4},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("coal_mine",e,480,ci(1.4)),Lumber:e=>qs("coal_mine",e,250,ci(1.36)),Iron:e=>t.city.ptrait.includes("unstable")?qs("coal_mine",e,28,ci(1.36)):0,Wrought_Iron:e=>qs("coal_mine",e,18,ci(1.36))},effect(){return t.tech.mine_conveyor?`
                ${z("city_coal_mine_effect1",[ta(1)])}
                ${z("city_coal_mine_effect2",[$(this)[0].powered(),5])}
                `:z("city_coal_mine_effect1",[ta(1)])},powered:()=>As(1),powerBalancer:()=>t.city.coal_mine.hasOwnProperty("cpow")&&t.city.coal_mine.hasOwnProperty("upow")&&t.resource.Uranium.display?[{r:"Coal",k:"cpow"},{r:"Uranium",k:"upow"}]:!!t.city.coal_mine.hasOwnProperty("cpow")&&[{r:"Coal",k:"cpow"}],power_reqs:{mine_conveyor:1},action(){return!!ri($(this)[0])&&(t.city.coal_mine.count++,t.resource.Coal.display=!0,t.civic.coal_miner.display=!0,t.civic.coal_miner.max=ta(t.city.coal_mine.count),t.tech.mine_conveyor&&Yr($(this)[0]),!0)}},oil_well:{id:"city-oil_well",title:z("city_oil_well"),desc:z("city_oil_well_desc"),category:"industrial",reqs:{oil:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("oil_well",e,5e3,ci(1.5)),Iron:e=>t.city.ptrait.includes("unstable")?qs("oil_well",e,450,ci(1.5)):0,Cement:e=>qs("oil_well",e,5250,ci(1.5)),Steel:e=>qs("oil_well",e,6e3,ci(1.5))},effect:()=>z("city_oil_well_effect",[+$e("oil_well").toFixed(2),br(500)]),action(){return!!ri($(this)[0])&&(t.city.oil_well.count++,t.resource.Oil.max+=br(500),1===t.city.oil_well.count&&(t.resource.Oil.display=!0,ki()),!0)},flair:z("city_oil_well_flair")},oil_depot:{id:"city-oil_depot",title:z("city_oil_depot"),desc:z("city_oil_depot_desc"),category:"trade",reqs:{oil:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("oil_depot",e,2500,ci(1.46)),Iron:e=>t.city.ptrait.includes("unstable")?qs("oil_depot",e,325,ci(1.36)):0,Cement:e=>qs("oil_depot",e,3750,ci(1.46)),Sheet_Metal:e=>qs("oil_depot",e,100,ci(1.45))},effect(){let e=br(1e3);e*=t.tech.world_control?1.5:1;let a=`
                ${z("plus_max_resource",[e,t.resource.Oil.name])}.
                `;if(t.resource.Helium_3.display){let e=br(400);e*=t.tech.world_control?1.5:1,a+=`
                ${z("plus_max_resource",[e,t.resource.Helium_3.name])}.
                `}if(t.tech.uranium>=2){let e=br(250);e*=t.tech.world_control?1.5:1,a+=`
                ${z("plus_max_resource",[e,t.resource.Uranium.name])}.
                `}return a},action(){return!!ri($(this)[0])&&(t.city.oil_depot.count++,t.resource.Oil.max+=br(1e3)*(t.tech.world_control?1.5:1),t.resource.Helium_3.display&&(t.resource.Helium_3.max+=br(400)*(t.tech.world_control?1.5:1)),t.tech.uranium>=2&&(t.resource.Uranium.max+=br(250)*(t.tech.world_control?1.5:1)),!0)}},trade:{id:"city-trade",title:z("city_trade"),desc:z("city_trade_desc"),category:"trade",reqs:{trade:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("trade",e,500,1.36),Lumber:e=>qs("trade",e,125,1.36),Stone:e=>qs("trade",e,50,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("trade",e,15,1.36):0,Furs:e=>qs("trade",e,65,1.36)},effect(){let e=t.race.xenophobic||t.race.nomadic?t.tech.trade:t.tech.trade+1;return t.tech.trade&&t.tech.trade>=3&&e--,t.race.flier&&(e+=Ei.flier.vars()[1]),z("city_trade_effect",[e])},action(){if(ri($(this)[0])){t.city.trade.count++;let e=t.race.xenophobic||t.race.nomadic?t.tech.trade:t.tech.trade+1;return t.tech.trade&&t.tech.trade>=3&&e--,t.city.market.mtrade+=e,!0}return!1}},wharf:{id:"city-wharf",title:z("city_wharf"),desc:z("city_wharf_desc"),category:"trade",era:"industrialized",reqs:{wharf:1},not_trait:["thalassophobia","cataclysm"],cost:{Money:e=>qs("wharf",e,62e3,1.32),Lumber:e=>qs("wharf",e,44e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?qs("wharf",e,200,1.32):0,Cement:e=>qs("wharf",e,3e3,1.32),Oil:e=>qs("wharf",e,750,1.32)},effect(){let e=t.tech.world_control?15:10;return t.tech.particles&&t.tech.particles>=2&&(e*=2),`
                ${z("city_trade_effect",[2])}
                ${z("city_wharf_effect")}
                ${z("plus_max_crates",[e])}
                ${z("plus_max_containers",[e])}
                `},action(){if(ri($(this)[0])){!1===t.resource.Containers.display&&(hs(z("city_warehouse_msg"),"info",!1,["progress"]),t.resource.Containers.display=!0,Ss($("#resources")),Da()),t.city.wharf.count++,t.city.market.mtrade+=2;let e=t.tech.world_control?15:10;return t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Crates.max+=e,t.resource.Containers.max+=e,!0}return!1}},tourist_center:{id:"city-tourist_center",title:z("city_tourist_center"),desc:z("city_tourist_center_desc"),category:"commercial",reqs:{monument:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("tourist_center",e,1e5,1.36),Stone:e=>qs("tourist_center",e,25e3,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("tourist_center",e,1e3,1.36):0,Furs:e=>qs("tourist_center",e,7500,1.36),Plywood:e=>qs("tourist_center",e,5e3,1.36)},effect(){let e=t.tech.monument&&t.tech.monument>=3&&s.s_gate?3:1,a=("corpocracy"===t.civic.govern.type?2:1)*e,r=("corpocracy"===t.civic.govern.type?10:5)*e,i=("corpocracy"===t.civic.govern.type?4:2)*e,n="";t.stats.achieve.banana&&t.stats.achieve.banana.l>=4&&(n=`
                ${z("city_tourist_center_effect5",[("corpocracy"===t.civic.govern.type?6:3)*e])}
                `);let c="",o=K("pious",1);return o&&(c=`
                ${z("city_tourist_center_effect6",[("corpocracy"===t.civic.govern.type?2*o:o)*e])}
                `),`
                ${z("city_tourist_center_effect1",[t.resource.Food.name])}
                ${z("city_tourist_center_effect2",[a,Mr.city.amphitheatre.title()])}
                ${z("city_tourist_center_effect3",[r])}
                ${z("city_tourist_center_effect4",[i])}
                ${n}${c}`},powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.city.tourist_center.count++,t.city.tourist_center.on++,!0)}},amphitheatre:{id:"city-amphitheatre",title:()=>z(K("athleticism",0)?"city_stadium":"city_amphitheatre"),desc:()=>z(K("athleticism",0)?"city_stadium":"city_amphitheatre_desc"),category:"commercial",reqs:{theatre:1},not_trait:["joyless","cataclysm"],cost:{Money:e=>qs("amphitheatre",e,500,1.55),Lumber:e=>qs("amphitheatre",e,50,1.75),Stone:e=>qs("amphitheatre",e,200,1.75),Iron:e=>t.city.ptrait.includes("unstable")?qs("amphitheatre",e,18,1.36):0},effect(){let e=K("athleticism",0);return`
                ${z("city_max_entertainer",[ta(K("athleticism",1)||1)])}
                ${z("city_max_morale",[e||1])}
                `},action(){return!!ri($(this)[0])&&(t.city.amphitheatre.count++,t.civic.entertainer.max+=ta(1),t.civic.entertainer.display=!0,!0)},flair:()=>z(K("athleticism",0)?"city_stadium_flair":"city_amphitheatre_flair")},casino:{id:"city-casino",title:z("city_casino"),desc:z("city_casino"),category:"commercial",reqs:{gambling:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("casino",e,35e4,1.35),Iron:e=>t.city.ptrait.includes("unstable")?qs("casino",e,2e3,1.35):0,Furs:e=>qs("casino",e,6e4,1.35),Plywood:e=>qs("casino",e,1e4,1.35),Brick:e=>qs("casino",e,6e3,1.35)},effect(){let e=Kr();return e+=`
                ${z("minus_power",[$(this)[0].powered()])}
                `,e},powered:()=>As(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2?2:3),action(){return!!ri($(this)[0])&&(t.city.casino.count++,t.race.joyless||(t.civic.entertainer.max+=ta(1),t.civic.entertainer.display=!0),Yr($(this)[0]),!0)},flair:z("city_casino_flair")},temple:{id:"city-temple",title:z("city_temple"),desc:()=>z("city_temple_desc",["none"!==t.race.gods?Ki[t.race.gods.toLowerCase()].entity:Ki[t.race.species].entity]),category:"commercial",reqs:{theology:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("temple",e,50,1.36),Lumber:e=>qs("temple",e,25,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("temple",e,6,1.36):0,Furs:e=>qs("temple",e,15,1.36),Cement:e=>qs("temple",e,10,1.36)},effect(){let e=Er();return t.genes.ancients&&t.genes.ancients>=2&&(e+=`
                ${z("city_temple_effect6",[ta(1)])}
                `),e},action(){return!!ri($(this)[0])&&(t.genes.ancients&&t.genes.ancients>=2&&(t.civic.priest.display=!0),t.city.temple.count++,!0)}},shrine:{id:"city-shrine",title:z("city_shrine"),desc:()=>z("city_shrine_desc"),category:"commercial",reqs:{theology:2},trait:["magnificent"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("shrine",e,75,1.32),Stone:e=>qs("shrine",e,65,1.32),Furs:e=>qs("shrine",e,10,1.32),Copper:e=>qs("shrine",e,15,1.32)},effect(){let e=`
                ${z("city_shrine_effect")}
                `;if(t.city.shrine&&t.city.shrine.morale>0&&(e+=`
                ${z("city_shrine_morale",[+dn("morale").add.toFixed(1)])}
                `),t.city.shrine&&t.city.shrine.metal>0&&(e+=`
                ${z("city_shrine_metal",[+(100*(dn("metal").mult-1)).toFixed(1)])}
                `),t.city.shrine&&t.city.shrine.know>0){let t=dn("know");e+=`
                ${z("city_shrine_know",[(+t.add.toFixed(1)).toLocaleString()])}
                `,e+=`
                ${z("city_shrine_know2",[+(100*(t.mult-1)).toFixed(1)])}
                `}return t.city.shrine&&t.city.shrine.tax>0&&(e+=`
                ${z("city_shrine_tax",[+(100*(dn("tax").mult-1)).toFixed(1)])}
                `),e},action(){if(ri($(this)[0])){if(t.city.shrine.count++,t.city.calendar.moon>0&&t.city.calendar.moon<7)t.city.shrine.morale++;else if(t.city.calendar.moon>7&&t.city.calendar.moon<14)t.city.shrine.metal++;else if(t.city.calendar.moon>14&&t.city.calendar.moon<21)t.city.shrine.know++;else if(t.city.calendar.moon>21)t.city.shrine.tax++;else switch(Math.floor(m(0,4))){case 0:t.city.shrine.morale++;break;case 1:t.city.shrine.metal++;break;case 2:t.city.shrine.know++;break;case 3:t.city.shrine.tax++}return!0}return!1}},meditation:{id:"city-meditation",title:z("city_meditation"),desc:z("city_meditation"),category:"commercial",reqs:{primitive:3},trait:["calm"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("meditation",e,50,1.2),Stone:e=>qs("meditation",e,25,1.2),Furs:e=>qs("meditation",e,8,1.2)},effect(){let e=t.resource.Zen.amount/(t.resource.Zen.amount+5e3);return`
                ${z("city_meditation_effect",[Ei.calm.vars()[0]])}
                ${z("city_meditation_effect2",[2])}
                ${z("city_meditation_effect3",[1])}
                ${z("city_meditation_effect4",[`${(100*e).toFixed(2)}%`])}
                `},action(){return!!ri($(this)[0])&&(t.city.meditation.count++,t.resource.Zen.max+=Ei.calm.vars()[0],!0)}},university:{id:"city-university",title:z("city_university"),desc:()=>z("city_university_desc",[Ki[t.race.species].home]),category:"science",reqs:{science:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("university",e,900,1.5)-500,Lumber:e=>qs("university",e,500,1.36)-200,Stone:e=>qs("university",e,750,1.36)-350,Crystal:e=>"magic"===t.race.universe?qs("university",e,5,1.36):0,Iron:e=>(t.city.university?t.city.university.count:0)+(e||0)>=3&&t.city.ptrait.includes("unstable")?qs("university",e,25,1.36):0},effect(){let e=+$(this)[0].knowVal().toFixed(0);return`
                ${z("city_university_effect",[ta(1)])}
                ${z("city_max_knowledge",[e.toLocaleString()])}
                `},knowVal(){let e=1,a=t.tech.science&&t.tech.science>=8?700:500;t.city.ptrait.includes("permafrost")&&(a+=ss.permafrost.vars()[1]),t.tech.science>=4&&(e+=.02*t.city.library.count),t.space.observatory&&t.space.observatory.count>0&&(e+=.05*n.observatory),t.portal.sensor_drone&&t.tech.science>=14&&(e+=.02*s.sensor_drone),t.race.hard_of_hearing&&(e*=1-Ei.hard_of_hearing.vars()[0]/100),t.race.curious&&(e*=1+Ei.curious.vars()[0]/100*t.resource[t.race.species].amount);let r=ts("cath");if(r>0&&(e*=1+Ei.curious.vars(3)[0]*r),s.s_gate&&o.scavenger){let t=Mt("gxy_alien2");e*=1+o.scavenger*t/4}let i=K("teacher",0);i&&(e*=1+i/100);let c=K("athleticism",2);c&&(e*=1-c/100),_n()&&(e*=dn("know").mult);let l=a*e;if(t.tech.supercollider){let e=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;l*=t.tech.supercollider/e+1}return t.race.orbit_decayed&&(t.space.satellite&&(l*=1+.12*t.space.satellite.count),t.tech.biotech&&t.tech.biotech>=1&&(l*=2)),l},action(){if(ri($(this)[0])){let e=t.tech.science&&t.tech.science>=8?700:500;if(t.tech.science>=4&&(e*=1+.02*t.city.library.count),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,t.city.university.count++,t.civic.professor.display=!0,t.civic.professor.max=t.city.university.count,!0}return!1}},library:{id:"city-library",title:z("city_library"),desc:()=>z("city_library_desc",[Ki[t.race.species].home]),category:"science",reqs:{science:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("library",e,45,1.2),Crystal:e=>"magic"===t.race.universe?qs("library",e,2,1.2):0,Iron:e=>t.city.ptrait.includes("unstable")?qs("library",e,4,1.2):0,Furs:e=>qs("library",e,22,1.2),Plywood:e=>qs("library",e,20,1.2),Brick:e=>qs("library",e,15,1.2)},effect(){let e=125;t.race.nearsighted&&(e*=1-Ei.nearsighted.vars()[0]/100),t.race.studious&&(e*=1+Ei.studious.vars()[1]/100);let a=ts("elven");if(a>0&&(e*=1+Ei.studious.vars(1)[1]/100*a),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*t.city.temple.count),t.tech.science&&t.tech.science>=5){let a=ea(t.civic.scientist.workers,"scientist");t.race.high_pop&&(a=ke(a)),e*=1+.12*a}let r=K("teacher",0);r&&(e*=1+r/100);let i=K("athleticism",2);i&&(e*=1-i/100);let s=K("muckraker",1);s&&(e*=1+s/100),e=+e.toFixed(0);let n=K("muckraker",2),c=n?5-n:5;return t.race.autoignition&&(c-=Ei.autoignition.vars()[0],c<0&&(c=0)),`
                ${z("city_max_knowledge",[e.toLocaleString()])}
                ${z("city_library_effect",[c])}
                `},action(){if(ri($(this)[0])){let e=125;return t.race.nearsighted&&(e*=1-Ei.nearsighted.vars()[0]/100),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*t.city.temple.count),t.tech.science&&t.tech.science>=5&&(e*=1+.12*ea(t.civic.scientist.workers,"scientist")),e=+e.toFixed(1),t.resource.Knowledge.max+=e,t.city.library.count++,t.tech.science&&t.tech.science>=3&&(t.civic.professor.impact=.5+.01*t.city.library.count),!0}return!1},flair:z("city_library_flair")},wardenclyffe:{id:"city-wardenclyffe",title:()=>_i(),desc:z("city_wardenclyffe_desc"),category:"science",reqs:{high_tech:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("wardenclyffe",e,5e3,1.22),Knowledge:e=>qs("wardenclyffe",e,t.race.logical?1e3-Ei.logical.vars()[0]:1e3,1.22),Crystal:e=>"magic"===t.race.universe?qs("wardenclyffe",e,100,1.22):0,Copper:e=>qs("wardenclyffe",e,500,1.22),Iron:e=>t.city.ptrait.includes("unstable")?qs("wardenclyffe",e,75,1.22):0,Cement:e=>qs("wardenclyffe",e,350,1.22),Sheet_Metal:e=>qs("wardenclyffe",e,125,1.2),Nanite:e=>t.race.deconstructor?qs("wardenclyffe",e,50,1.18):0},effect(){let e=1e3;if(t.city.ptrait.includes("magnetic")&&(e+=ss.magnetic.vars()[1]),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}t.space.satellite&&(e*=1+.04*t.space.satellite.count);let a=K("athleticism",2);a&&(e*=1-a/100),e=+e.toFixed(0);let r=`
                ${z("city_wardenclyffe_effect1",[ta(1),t.civic.scientist?t.civic.scientist.name:z("job_scientist")])}
                ${z("city_max_knowledge",[e.toLocaleString()])}
                `;if(t.city.powered){let e=t.tech.science>=7?2500:2e3;if(t.city.ptrait.includes("magnetic")&&(e+=ss.magnetic.vars()[1]),t.space.satellite&&(e*=1+.04*t.space.satellite.count),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}let a=K("athleticism",2);if(a&&(e*=1-a/100),e=+e.toFixed(1),t.tech.science>=15&&(r+=`
                ${z("city_wardenclyffe_effect4",[2])}
                `),"magic"===t.race.universe&&(r+=`
                ${z("plus_max_resource",[br(8),t.resource.Mana.name])}
                `),t.tech.broadcast){let a=t.tech.broadcast;r+=`
                ${z("city_wardenclyffe_effect3",[$(this)[0].powered(),e.toLocaleString(),a])}
                `}else r+=`
                ${z("city_wardenclyffe_effect2",[$(this)[0].powered(),e.toLocaleString()])}
                `;t.race.artifical&&(r+=`
                ${z("city_transmitter_effect",[br(250)])}As(2),action(){if(ri($(this)[0])){let e=1e3;if(t.city.wardenclyffe.count++,t.civic.scientist.display=!0,t.civic.scientist.max=t.city.wardenclyffe.count,Yr($(this)[0])&&(e=t.tech.science>=7?2500:2e3),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,!0}return!1},flair:()=>"magic"===t.race.universe?`
                ${z("city_wizard_tower_flair")}
                `:t.race.evil?`
                ${z("city_babel_flair")}
                `:`
                ${z("city_wardenclyffe_flair1")}
                ${z("city_wardenclyffe_flair2")}
                `},biolab:{id:"city-biolab",title:z("city_biolab"),desc:`
                ${z("city_biolab_desc")}
                ${z("requires_power")}
                `,category:"science",reqs:{genetics:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("biolab",e,25e3,1.3),Knowledge:e=>qs("biolab",e,5e3,1.3),Copper:e=>qs("biolab",e,1250,1.3),Iron:e=>t.city.ptrait.includes("unstable")?qs("biolab",e,160,1.3):0,Alloy:e=>qs("biolab",e,350,1.3)},effect(){let e=3e3;return t.portal.sensor_drone&&t.tech.science>=14&&(e*=1+.02*s.sensor_drone),t.tech.science>=20&&(e*=3),t.tech.science>=21&&(e*=1.45),t.tech.biotech>=1&&(e*=2.5),e=+e.toFixed(0),`${z("city_max_knowledge",[e.toLocaleString()])}, ${z("minus_power",[$(this)[0].powered()])}`},powered:()=>As(2),action(){return!!ri($(this)[0])&&(t.city.biolab.count++,Yr($(this)[0])&&(t.resource.Knowledge.max+=3e3),!0)}},coal_power:{id:"city-coal_power",title:()=>t.race.environmentalist?z("city_hydro_power"):z("magic"===t.race.universe?"city_mana_engine":"city_coal_power"),desc:()=>t.race.environmentalist?`
                ${z("city_hydro_power_desc")}
                `:`
                ${z("magic"===t.race.universe?"city_mana_engine_desc":"city_coal_power_desc")}
                ${z("requires_res",[z("magic"===t.race.universe?"resource_Mana_name":"resource_Coal_name")])}
                `,category:"utility",reqs:{high_tech:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("coal_power",e,1e4,ci(1.22)),Crystal:e=>"magic"===t.race.universe?qs("coal_power",e,125,ci(1.22)):0,Copper:e=>qs("coal_power",e,1800,ci(1.22))-1e3,Iron:e=>t.city.ptrait.includes("unstable")?qs("coal_power",e,175,ci(1.22)):0,Cement:e=>qs("coal_power",e,600,ci(1.22)),Steel:e=>qs("coal_power",e,2e3,ci(1.22))-1e3},effect(){let e="magic"===t.race.universe?.05:.35,a=-$(this)[0].powered();return t.race.environmentalist?`+${a}MW`:`+${a}MW. ${z("magic"===t.race.universe?"city_mana_engine_effect":"city_coal_power_effect",[e])}`},powered(){let e=t.race.environmentalist?t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1?-5:-4:t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1?-6:-5,a=K("dirty_jobs",1);return a&&(e-=a),Fs(e)},p_fuel:()=>"magic"===t.race.universe?{r:"Mana",a:t.race.environmentalist?0:.05}:{r:"Coal",a:t.race.environmentalist?0:.35},action(){return!!ri($(this)[0])&&(t.city.coal_power.count++,t.city.coal_power.on++,t.city.power+=5,!0)}},oil_power:{id:"city-oil_power",title:()=>t.race.environmentalist?z("city_wind_power"):z("city_oil_power"),desc:()=>t.race.environmentalist?`
                ${z("city_wind_power_desc")}
                `:`
                ${z("city_oil_power_desc")}
                ${z("requires_res",[z("resource_Oil_name")])}
                `,category:"utility",reqs:{oil:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("oil_power",e,5e4,ci(1.22)),Copper:e=>qs("oil_power",e,6500,ci(1.22))+1e3,Iron:e=>t.city.ptrait.includes("unstable")?qs("oil_power",e,180,ci(1.22)):0,Aluminium:e=>qs("oil_power",e,12e3,ci(1.22)),Cement:e=>qs("oil_power",e,5600,ci(1.22))+1e3},effect(){let e=-$(this)[0].powered();return t.race.environmentalist?`+${e}MW`:`+${e}MW. ${z("city_oil_power_effect",[.65])}`},powered(){let e=0;if(t.race.environmentalist)if(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3){let a=1===t.city.calendar.wind?-7:-5;e=t.stats.achieve.dissipated.l>=5?a-2:a-1}else e=1===t.city.calendar.wind?-7:-5;else e=t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3?t.stats.achieve.dissipated.l>=5?-8:-7:-6;let a=K("dirty_jobs",1);return a&&(e-=a),Fs(e)},p_fuel:()=>({r:"Oil",a:t.race.environmentalist?0:.65}),action(){return!!ri($(this)[0])&&(t.city.oil_power.count++,t.city.oil_power.on++,t.city.power+=6,!0)}},fission_power:{id:"city-fission_power",title:z("city_fission_power"),desc:`
                ${z("city_fission_power_desc")}
                ${z("requires_res",[z("resource_Uranium_name")])}
                `,category:"utility",reqs:{high_tech:5},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("fission_power",e,25e4,1.36),Copper:e=>qs("fission_power",e,13500,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("fission_power",e,1750,1.36):0,Cement:e=>qs("fission_power",e,10800,1.36),Titanium:e=>qs("fission_power",e,7500,1.36)},effect(){return`+${-$(this)[0].powered()}MW. ${z("city_fission_power_effect",[.1])}`},powered:()=>Fs(t.tech.uranium>=4?-18:-14),p_fuel:()=>({r:"Uranium",a:.1}),action(){return!!ri($(this)[0])&&(t.city.fission_power.count++,t.city.fission_power.on++,t.city.power+=14,!0)}},mass_driver:{id:"city-mass_driver",title:z("city_mass_driver"),desc:`
                ${z("city_mass_driver_desc")}
                ${z("requires_power")}
                `,category:"utility",reqs:{mass:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("mass_driver",e,375e3,1.32),Copper:e=>qs("mass_driver",e,33e3,1.32),Iron:e=>qs("mass_driver",e,42500,1.32),Iridium:e=>qs("mass_driver",e,2200,1.32)},effect(){return`${t.tech.mass>=2?`
                ${z("city_mass_driver_effect2",[1,t.civic.scientist.name])}
                `:""}${z("city_mass_driver_effect",[t.race.truepath?6:5,nn("name")])} ${z("minus_power",[$(this)[0].powered()])}`},powered(){let e=t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=4?4:5;return As(t.tech.mass>=2?e-1:e)},action(){return!!ri($(this)[0])&&(t.city.mass_driver.count++,Yr($(this)[0]),!0)}},replicator:{id:"city-replicator",title:z("tech_replicator"),desc:z("tech_replicator"),category:"utility",reqs:{special_hack:1},cost:{},wiki:!1,effect:()=>"fake structure",powered:()=>1,action:()=>!1}},tech:Or(),arpa:xe("PhysicsTech"),genes:xe("GeneTech"),blood:xe("BloodTech"),space:At(),interstellar:xt,galaxy:jt,starDock:{probes:{id:"starDock-probes",title:z("star_dock_probe"),desc:()=>`
                ${z("star_dock_probe_desc")}
                `,reqs:{genesis:4},cost:{Money:e=>qs("probes",e,35e4,t.race.truepath?1.125:1.25,"starDock"),Alloy:e=>qs("probes",e,75e3,t.race.truepath?1.125:1.25,"starDock"),Polymer:e=>qs("probes",e,85e3,t.race.truepath?1.125:1.25,"starDock"),Iridium:e=>qs("probes",e,12e3,t.race.truepath?1.125:1.25,"starDock"),Mythril:e=>qs("probes",e,3500,t.race.truepath?1.125:1.25,"starDock")},effect:()=>`
                ${z("star_dock_probe_effect")}
                `,action(){return!!ri($(this)[0])&&(t.starDock.probes.count++,!0)}},geck:{id:"starDock-geck",title:z("tech_geck"),desc:()=>`
                ${z("tech_geck_desc")}
                `,reqs:{geck:1},condition:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5),queue_complete:()=>0,no_multi:!0,cost:{Money:e=>qs("geck",e,1e6,1.25,"starDock"),Elerium:e=>qs("geck",e,1e3,1.25,"starDock"),Plasmid:e=>qs("geck",e,25,1.4,"starDock")},effect:()=>`
                ${z("star_dock_geck_effect")}
                `,action(){return!!ri($(this)[0])&&(t.starDock.geck.count++,!0)}},seeder:{id:"starDock-seeder",title:()=>t.race.cataclysm?z("star_dock_exodus"):z("star_dock_seeder"),desc(){let e=t.race.cataclysm?z("star_dock_exodus"):z("star_dock_seeder");return t.starDock.seeder&&t.starDock.seeder.count>=100?`
                ${e}
                ${z("star_dock_seeder_desc2")}
                `:`
                ${e}
                ${z("star_dock_seeder_desc1")}
                `},reqs:{genesis:5},queue_size:10,queue_complete:()=>100-t.starDock.seeder.count,cost:{Money:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?1e5:0,Steel:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?25e3:0,Neutronium:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?240:0,Elerium:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?10:0,Nano_Tube:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?12e3:0},effect(e){let a=(e||0)+(t.starDock.seeder?t.starDock.seeder.count:0),r=a<100?z("star_dock_seeder_status1",[100-a]):z("star_dock_seeder_status2");return`
                ${t.race.cataclysm?z("star_dock_exodus_effect"):z("star_dock_seeder_effect")}
                ${r}
                `},action(){return!!(t.starDock.seeder.count<100&&ri($(this)[0]))&&(t.starDock.seeder.count++,t.starDock.seeder.count>=100&&(t.tech.genesis=6,_s("starDock-seeder"),Ss($("#modalBox")),oi(Mr.space.spc_gas.star_dock,"star_dock")),!0)}},prep_ship:{id:"starDock-prep_ship",title:z("star_dock_prep"),desc:()=>`
                ${t.race.cataclysm?z("star_dock_prep_cata_desc"):z("star_dock_prep_desc")}
                ${z("star_dock_genesis_desc2")}
                `,reqs:{genesis:6},queue_complete:()=>0,cost:{},effect(){let e=Gs("bioseed"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                ${t.race.cataclysm?z("star_dock_prep_cata_effect"):z("star_dock_prep_effect")}
                ${z("star_dock_genesis_effect2",[e.plasmid,a])}
                ${z("star_dock_genesis_effect3",[e.phage])}
                `},action:()=>(t.tech.genesis=7,_s("starDock-prep_ship"),Ss($("#modalBox")),oi(Mr.space.spc_gas.star_dock,"star_dock"),!0)},launch_ship:{id:"starDock-launch_ship",title:z("star_dock_genesis"),desc:()=>`
                ${t.race.cataclysm?z("star_dock_prep_cata_effect"):z("star_dock_genesis_desc1")}
                ${z("star_dock_genesis_desc2")}
                `,reqs:{genesis:7},queue_complete:()=>0,cost:{},effect(){let e=Gs("bioseed"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                ${t.race.cataclysm?z("star_dock_genesis_cata_effect1"):z("star_dock_genesis_effect1")}
                ${z("star_dock_genesis_effect2",[e.plasmid,a])}
                ${z("star_dock_genesis_effect3",[e.phage])}
                `},action:()=>(function(){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"bioseed"});let a=t.race.species,r=t.race.gods,i=Ki[a].type,s=t.city.calendar.orbit,n=t.city.biome,c=t.city.ptrait,o=Gs("bioseed");t.stats.bioseed++,rn(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),qn("seeder"),qn(`biome_${n}`),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),qn(`genus_${i}`),t.race.truepath&&qn("exodus"),c.includes("dense")&&"heavy"===t.race.universe&&qn("double_density"),t.race.junker&&"junker"===t.race.species&&Pn("organ_harvester"),"hellscape"===t.city.biome&&"demonic"!==Ki[t.race.species].type&&Pn("ill_advised"),void 0===t.tech.world_control&&qn("cult_of_personality"),t.race.cataclysm&&qn("iron_will",!1,5),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross");let l=0,_=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0?l++:t.city.geology[e]<0&&_++})),l>=4&&qn("miners_dream"),_>=3&&Pn("rocky_road"),t.race.steelen&&t.race.steelen>=1&&qn("steelen"),"micro"===t.race.universe&&(t.race.small||t.race.compact?qn("macro",!0):qn("marble",!0)),Sn();let d=!!t.race.hasOwnProperty("srace")&&t.race.srace,p=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0,u=t.starDock.probes.count+1,h=t.starDock.hasOwnProperty("geck")?t.starDock.geck.count:0;t.stats.achieve.explorer&&(u+=t.stats.achieve.explorer.l),t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!0,probes:u,geck:h,seed:Math.floor(m(1e4)),ascended:!1},p>0&&(t.race.corruption=p),d&&(t.race.srace=d),H({orbit:s,biome:n,ptrait:c,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),!1)}},portal:pa(),tauceti:Re};function Sr(){let a=$("#evolution .evolving").nextAll();Object.values(a).forEach((function(e){Ss($(e),!0)})),Ss($("#evolution .evolving"),!0),t.evolution.bunker={count:1},ti(Mr.evolution.bunker.id),li(),t.race.truepath||t.race.lone_survivor?(t.evolution.nerfed={count:0},t.evolution.badgenes={count:0}):("antimatter"===t.race.universe?t.evolution.mastery={count:0}:t.evolution.plasmid={count:0},t.evolution.crispr={count:0}),t.evolution.trade={count:0},t.evolution.craft={count:0},t.evolution.junker={count:0},t.evolution.joyless={count:0},t.evolution.steelen={count:0},(t.stats.achieve.whitehole||t.sim)&&(t.evolution.decay={count:0}),(t.stats.achieve.ascended||t.sim)&&(t.evolution.emfield={count:0}),(t.stats.achieve.scrooge||t.sim)&&(t.evolution.inflation={count:0}),(t.stats.achieve.shaken||t.sim)&&(t.evolution.cataclysm={count:0}),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&(t.evolution.banana={count:0},t.evolution.orbit_decay={count:0}),"standard"===t.race.universe&&(t.stats.achieve.whitehole||t.sim),"heavy"===t.race.universe&&(t.stats.achieve.seeder&&t.stats.achieve.seeder.h||t.sim),"magic"===t.race.universe&&(t.stats.achieve.ascended&&t.stats.achieve.ascended.mg||t.sim)&&(t.evolution.witch_hunter={count:0}),"evil"===t.race.universe&&(t.stats.achieve.corrupted&&t.stats.achieve.corrupted.e||t.sim),(t.stats.achieve.ascended||t.stats.achieve.corrupted||t.sim)&&(t.evolution.truepath={count:0}),((t.stats.achieve.ascended||t.stats.achieve.corrupted)&&t.stats.achieve.extinct_junker||t.sim)&&(t.evolution.sludge={count:0}),(t.stats.achieve.bluepill||t.sim)&&(t.evolution.simulation={count:0}),(t.stats.achieve.retired||t.sim)&&(t.evolution.lone_survivor={count:0}),function(){let e=$('
                ');$("#evolution").append(e),e.append($(`

                ${z("evo_challenge_genes")}

                `)),e.append($(`
                ${z("evo_challenge_genes_desc")}
                `)),t.genes.challenge&&t.genes.challenge>=2&&e.append($(`
                ${z("evo_challenge_genes_mastery")}
                `))}(),t.race.truepath||t.race.lone_survivor?Jr("evolution","nerfed"):"antimatter"===t.race.universe?Jr("evolution","mastery"):Jr("evolution","plasmid"),Jr("evolution","trade"),Jr("evolution","craft"),t.race.truepath||t.race.lone_survivor?Jr("evolution","badgenes"):Jr("evolution","crispr"),function(){let e=$('
                ');$("#evolution").append(e),e.append($(`

                ${z("evo_challenge_run")}

                `)),e.append($(`
                ${z("evo_challenge_run_desc")}
                `))}(),Jr("evolution","joyless"),Jr("evolution","steelen"),(t.stats.achieve.whitehole||t.sim)&&Jr("evolution","decay"),(t.stats.achieve.ascended||t.sim)&&Jr("evolution","emfield"),(t.stats.achieve.scrooge||t.sim)&&Jr("evolution","inflation"),((t.stats.achieve.ascended||t.stats.achieve.corrupted)&&t.stats.achieve.extinct_junker||t.sim)&&Jr("evolution","sludge"),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&Jr("evolution","orbit_decay"),"standard"===t.race.universe&&(t.stats.achieve.whitehole||t.sim),"heavy"===t.race.universe&&(t.stats.achieve.seeder&&t.stats.achieve.seeder.h||t.sim),"magic"===t.race.universe&&(t.stats.achieve.ascended&&t.stats.achieve.ascended.mg||t.sim)&&Jr("evolution","witch_hunter"),"evil"===t.race.universe&&(t.stats.achieve.corrupted&&t.stats.achieve.corrupted.e||t.sim),t.hasOwnProperty("beta")&&!t.sim&&Jr("evolution","simulation"),function(){let e=$('
                ');$("#evolution").append(e),e.append($(`

                ${z("evo_scenario")}

                `)),e.append($(`
                ${z("evo_scenario_desc")}
                `))}(),Jr("evolution","junker"),(t.stats.achieve.shaken||t.sim)&&Jr("evolution","cataclysm"),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&Jr("evolution","banana"),(t.stats.achieve.ascended||t.stats.achieve.corrupted||t.sim)&&Jr("evolution","truepath"),(t.stats.achieve.retired||t.sim)&&Jr("evolution","lone_survivor"),t.sim?function(){let a=$('
                ');$("#evolution").append(a),a.append($(`

                ${z("evo_challenge_simulation")}

                `)),a.append($(`
                ${z("evo_challenge_simulation_desc")}
                `)),a.append($(``)),Cs({el:"#simSection",data:{},methods:{exitsim(){t.hasOwnProperty("sim")&&(t.stats=sn(t.sim.stats),t.prestige=sn(t.sim.prestige),t.genes=sn(t.sim.genes),t.blood=sn(t.sim.blood),t.pillars=sn(t.sim.pillars),t.race=sn(t.sim.race),delete t.sim,t.race.species="protoplasm",delete t.race.simulation,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w&&P.w.terminate(),window.location.reload())}}})}():t.race.simulation&&function(){let e=$('
                ');$("#evolution").append(e),e.append($(`

                ${z("evo_challenge_simulation")}

                `)),e.append($(`
                ${z("evo_challenge_simulation_desc")}
                `));let a=$($('
                '));e.append(a),t.race.simConfig||(t.race.simConfig={}),["Plasmid","AntiPlasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone"].forEach((function(e){t.race.simConfig[e]=t.race.simConfig[e]||0,a.append($(`
                ${z(`resource_${e}_name`)}
                `))})),Cs({el:"#simSection",data:t.race.simConfig})}()}function Cr(e,a){let r=t.race.orbit_decay?"orbit_decayed":"cataclysm",i=function(e,t,a){return"space"===a?e.hasOwnProperty("trait")?e.trait.push(t):e.trait=[t]:"tauceti"===a?e.reqs.isolation=1:e.hasOwnProperty("not_trait")?e.not_trait.push(t):e.not_trait=[t],e};switch(e){case"bonfire":return i({id:`${a}-bonfire`,title:z("city_bonfire"),desc:z("city_bonfire_desc"),category:"outskirts",wiki:!1,reqs:{primitive:3},condition:()=>cn("summer"),queue_complete:()=>0,effect(){let e=2.5*t.resource.Thermite.diff/(2.5*t.resource.Thermite.diff+500)*500,a=1e5+9e3*t.stats.reset;a>1e6&&(a=1e6);let r=t.resource.Thermite.amount${z("city_bonfire_effect3",[a.toLocaleString()])}
                ${z("city_bonfire_effect4",[(+t.resource.Thermite.amount.toFixed(0)).toLocaleString(),a.toLocaleString()])}
                `:"";return`
                ${z("city_bonfire_effect",[t.resource.Thermite.diff])}
                ${z("city_bonfire_effect2",[+e.toFixed(1)])}
                ${r}`},action:()=>!1,flair:()=>z("city_bonfire_flair")},r,a);case"firework":return i({id:`${a}-firework`,title:z("city_firework"),desc:z("city_firework"),category:"outskirts",wiki:!1,reqs:{mining:3},condition:()=>cn("firework")&&(t.tech.cement||t.race.flier),cost:{Money:()=>0===t[a].firework.count?5e4:0,Iron:()=>0===t[a].firework.count?7500:0,Cement:()=>0===t[a].firework.count?1e4:0},queue_complete:()=>1-t[a].firework.count,switchable:()=>!0,effect:()=>0===t[a].firework.count?z("city_firework_build"):z("city_firework_effect"),action(){return!(0!==t[a].firework.count||!ri($(this)[0])||(t[a].firework.count=1,0))}},r,a);case"assembly":{let e=function(e){let a=ke(e);return t.race.promiscuous&&(a/=1+Ei.promiscuous.vars()[1]*t.race.promiscuous),Math.round(a)};return i({id:`${a}-assembly`,title:z("city_assembly"),desc:()=>z("city_assembly_desc",[Ki[t.race.species].name]),category:"military",reqs:{},trait:["artifical"],queue_complete:()=>t.resource[t.race.species].max-t.resource[t.race.species].amount,cost:{Money:a=>t.resource[t.race.species].amount?qs("citizen",a,e(125),1.01):0,Copper:a=>t.race.deconstructor?0:t.resource[t.race.species].amount>=5?qs("citizen",a,e(50),1.01):0,Aluminium:a=>t.race.deconstructor?0:t.resource[t.race.species].amount>=5?qs("citizen",a,e(50),1.01):0,Nanite:a=>t.race.deconstructor&&t.resource[t.race.species].amount>=3?qs("citizen",a,e(500),1.01):0},effect(){let e="";return t.resource[t.race.species].max===t.resource[t.race.species].amount&&(e=`
                ${z("city_assembly_effect_warn")}
                `),`
                ${z("city_assembly_effect",[Ki[t.race.species].name])}
                ${e}`},action(){return!!(t.race.vax&&t.race.vax>=100)||!!(t.resource[t.race.species].max>t.resource[t.race.species].amount&&ri($(this)[0]))&&(t.resource[t.race.species].amount++,!0)}},r,a)}case"nanite_factory":return i({id:`${a}-nanite_factory`,title:z("city_nanite_factory"),desc:z("city_nanite_factory"),category:"industrial",reqs:{},trait:["deconstructor"],region:"city",cost:{Money:e=>qs("nanite_factory",e,25e3,ci(1.25)),Copper:e=>qs("nanite_factory",e,1200,ci(1.25)),Steel:e=>qs("nanite_factory",e,1e3,ci(1.25))},effect(){let e=br(2500);return`
                ${z("city_nanite_factory_effect",[t.resource.Nanite.name])}
                ${z("plus_max_resource",[e,t.resource.Nanite.name])}.
                `},special:!0,action(){return!!ri($(this)[0])&&(t.city.nanite_factory.count++,t.settings.showIndustry=!0,ki(),!0)},flair:z("city_nanite_factory_flair")},r,a);case"captive_housing":return i({id:`${a}-captive_housing`,title:z("city_captive_housing"),desc:z("city_captive_housing_desc"),category:"residential",reqs:{unfathomable:1},trait:["unfathomable"],region:"city",cost:{Money:e=>qs("captive_housing",e,40,1.35),Lumber:e=>qs("captive_housing",e,30,1.35),Stone:e=>qs("captive_housing",e,18,1.35)},effect(){let e="";t.race.artifical||t.race.detritivore||t.race.carnivore||t.race.soul_eater||(e+=`
                ${z("city_captive_housing_cattle",[t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.cattle:0,t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.cattleCap:0])}
                `);let a=0;if(t.city.hasOwnProperty("surfaceDwellers"))for(let r=0;r${z("city_captive_housing_broken",[Ki[i].name,s])}`,e+=`
                ${z("city_captive_housing_untrained",[Ki[i].name,n])}
                `}return e+=`
                ${z("city_captive_housing_capacity",[a,t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.raceCap:0])}
                `,t.tech.unfathomable&&t.tech.unfathomable>=2&&(e+=`
                ${z("plus_max_resource",[1,z("job_torturer")])}
                `),e},action(){if(ri($(this)[0])){t.city.captive_housing.count++;let e=t.city.captive_housing.count;return t.city.captive_housing.raceCap=e*(t.tech.unfathomable&&t.tech.unfathomable>=3?3:2),t.city.captive_housing.cattleCap=5*e,!0}return!1}},r,a);case"horseshoe":return i({id:`${a}-horseshoe`,title:()=>z(`city_${hn(!0)}`,[hn(!1)]),desc:()=>z(`city_${hn(!0)}_desc`,[hn(!1)]),category:"outskirts",reqs:{primitive:3},condition:()=>t.race.hooved||cn("fool",2023),inflation:!1,cost:{Lumber(e){let a=(t.race.shoecnt||0)+(e||0);return t.race.kindling_kindred||t.race.smoldering||t.resource.Copper.display&&!(a<=12)?0:Math.round((a>12?25:5)*(a<=5?1:a-4)*(Ei.hooved.vars()[0]/100))},Copper(e){let a=(t.race.shoecnt||0)+(e||0),r=!t.race.kindling_kindred&&!t.race.smoldering;return(!r||r&&a>12&&t.resource.Copper.display)&&(!t.resource.Iron.display||a<=75)?Math.round((a>75?20:5)*(a<=12?1:a-11)*(Ei.hooved.vars()[0]/100)):0},Iron(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Iron.display&&a>75&&(!t.resource.Steel.display||a<=150)?Math.round((a<=150?12:28)*a*(Ei.hooved.vars()[0]/100)):0},Steel(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Steel.display&&a>150&&(!t.resource.Adamantite.display||a<=500)?Math.round((a<=500?40:100)*a*(Ei.hooved.vars()[0]/100)):0},Adamantite(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Adamantite.display&&a>500&&(!t.resource.Orichalcum.display||a<=5e3)?Math.round((a<=5e3?5:25)*a*(Ei.hooved.vars()[0]/100)):0},Orichalcum(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Orichalcum.display&&a>5e3?Math.round((25*a-12e4)*(Ei.hooved.vars()[0]/100)):0}},action(){return!(t.race.hooved||!cn("fool",2023))||!(!t.resource.Horseshoe.display||!ri($(this)[0]))&&(t.resource.Horseshoe.amount++,t.race.shoecnt++,!(5001===t.race.shoecnt&&t.resource.Orichalcum.display||501===t.race.shoecnt&&t.resource.Adamantite.display||151===t.race.shoecnt&&t.resource.Steel.display||76===t.race.shoecnt&&t.resource.Iron.display||13===t.race.shoecnt&&t.resource.Copper.display&&t.resource.Lumber.display)||0)}},r,a)}}function zr(e,a){a=a||"evo";let r=t.evolution.final||0;return(t.tech[a]&&t.tech[a]===e||t.evolution.gselect)&&r<100}const Fr=["human","orc","elven","troll","ogre","cyclops","kobold","goblin","gnome","cath","wolven","vulpine","centaur","rhinotaur","capybara","tortoisan","gecko","slitheryn","arraak","pterodacti","dracnid","sporgar","shroomi","moldling","mantis","scorpid","antid","entish","cacti","pinguicula","sharkin","octigoran","dryad","satyr","phoenix","salamander","yeti","wendigo","tuskin","kamel","imp","balorg","seraph","unicorn","synth","nano","ghast","shoggoth","custom"];if(Fr.forEach((e=>Mr.evolution[e]={id:`evolution-${e}`,title:()=>Ki[e].name,desc:()=>`${z("evo_evolve")} ${Ki[e].name}`,reqs:{evo:7},grant:["evo",8],condition:()=>(t.race.seeded||t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>=1||t.stats.achieve[`extinct_${e}`]&&t.stats.achieve[`extinct_${e}`].l>=1)&&t.tech[`evo_${Ki[e].type}`]>=2&&100===t.evolution.final&&!t.race.evoFinalMenu,cost:{RNA:()=>320,DNA:()=>320},race:!0,effect:()=>`${"string"==typeof Ki[e].desc?Ki[e].desc:Ki[e].desc()} ${z("evo_complete")}`,action(){if(ri($(this)[0])){if(["synth","custom"].includes(e))return function(e){if(("synth"===e||"custom"===e&&t.custom.race0.traits.includes("imitation"))&&Object.keys(t.stats.synth).length>1)return t.race.evoFinalMenu=e,Tr(),!0;t.race.species=e,hi()}(e);t.race.species=e,hi()}return!1},queue_complete:()=>t.tech.evo&&7===t.tech.evo?1:0,emblem:()=>Xs(`extinct_${e}`)})),Object.keys(t.stats.synth).length>1){let e=sn(Fr);e.push("junker"),e.push("sludge"),e.forEach((e=>Mr.evolution[`s-${e}`]={id:`evolution-s-${e}`,title:()=>Ki[e].name,desc:()=>`${z("evo_imitate")} ${Ki[e].name}`,reqs:{evo:8},grant:["evo",9],condition:()=>t.stats.synth[e]&&t.race.evoFinalMenu,cost:{},race:!0,effect:()=>z("evo_imitate_race",[Ki[e].name]),action:()=>(t.stats.synth[e]&&(t.race.species=t.race.evoFinalMenu,t.race.srace=e,hi()),!1),queue_complete:()=>t.tech.evo&&8===t.tech.evo?1:0}))}const Ar={plasmid:"no_plasmid",mastery:"weak_mastery",trade:"no_trade",craft:"no_craft",crispr:"no_crispr",nerfed:"nerfed",badgenes:"badgenes"};Object.keys(Ar).forEach((e=>Mr.evolution[e]={id:`evolution-${e}`,title:z(`evo_challenge_${e}`),desc:z(`evo_challenge_${e}`),condition:()=>t.evolution.hasOwnProperty(e),cost:{DNA:()=>10},challenge:!0,effect:()=>Lr(e),action(){return ri($(this)[0])&&(t.race[Ar[e]]?(delete t.race[Ar[e]],$(`#${$(this)[0].id}`).removeClass("hl"),(t.race.truepath||t.race.lone_survivor)&&(delete t.race.nerfed,delete t.race.badgenes),["junker","cataclysm","banana","truepath","lone_survivor"].forEach((function(e){delete t.race[e],$(`#evolution-${e}`).removeClass("hl")}))):(t.race[Ar[e]]=1,$(`#${$(this)[0].id}`).addClass("hl")),Sr(),On()),!1},highlight:()=>!!t.race[Ar[e]],queue_complete:()=>0}));const Ir={joyless:{t:"c",e:"joyless"},steelen:{t:"c",e:"steelen"},decay:{t:"c",e:"dissipated"},emfield:{t:"c",e:"technophobe"},inflation:{t:"c",e:"wheelbarrow"},sludge:{t:"c",e:"extinct_sludge"},orbit_decay:{t:"c",e:"lamentis"},witch_hunter:{t:"c",e:"soul_sponge"},simulation:{t:"c",e:"thereisnospoon"},junker:{t:"s",e:"extinct_junker"},cataclysm:{t:"s",e:"iron_will"},banana:{t:"s",e:"banana"},truepath:{t:"s",e:"pathfinder"},lone_survivor:{t:"s",e:"adam_eve"}};function Tr(){if((t.settings.tabLoad||0===t.settings.civTabs)&&"bigbang"!==t.race.universe&&(!t.race.seeded||t.race.chose)){if(t.tech.evo_challenge){let e=$("#evolution .evolving").nextAll();Object.values(e).forEach((function(e){Ss($(e),!0)})),Ss($("#evolution .evolving"),!0)}Object.keys(Mr.evolution).forEach((function(e){if(!Mr.evolution[e].challenge){ti(Mr.evolution[e].id);var a=!0;Mr.evolution[e].hasOwnProperty("reqs")&&Object.keys(Mr.evolution[e].reqs).forEach((function(r){(!t.tech[r]||t.tech[r]=2&&li(),t.tech.evo_challenge&&Sr())}}function Lr(e){switch(e){case"nerfed":return z(`evo_challenge_${e}_effect`,"antimatter"===t.race.universe?["20%","50%","50%","33%"]:["50%","20%","50%","33%"]);case"badgenes":return z(`evo_challenge_${e}_effect`,[1,2]);case"orbit_decay":return Ts()>=100?`
                ${z("evo_challenge_orbit_decay_effect",[5e3])}
                ${z("evo_challenge_scenario_failwarn")}
                `:`
                ${z("evo_challenge_orbit_decay_effect",[5e3])}
                ${z("evo_challenge_scenario_failwarn")}
                ${z("evo_challenge_scenario_warn")}
                `;case"junker":return"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                ${z("evo_challenge_junker_effect")}
                ${z("evo_warn_unwise")}
                `:z("evo_challenge_junker_effect");case"cataclysm":return Ts()>=50?`
                ${z("evo_challenge_cataclysm_effect")}
                ${z("evo_challenge_cataclysm_warn")}
                `:`
                ${z("evo_challenge_cataclysm_effect")}
                ${z("evo_challenge_scenario_warn")}
                `;default:return z(`evo_challenge_${e}_effect`)}}function Er(){let e;if("antimatter"===t.race.universe||t.race.no_plasmid){let a=t.tech.anthropology&&t.tech.anthropology>=1?1.6:1;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=ea(t.civic.professor.workers,"professor")*("antimatter"===t.race.universe?.02:.04);t.race.high_pop&&(e=ke(e)),a+=+e.toFixed(2)}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.015:t.genes.ancients>=3?.0125:.01;t.race.high_pop&&(e=ke(e)),a+=e*ea(t.civic.priest.workers,"priest")}"antimatter"===t.race.universe&&(a/=2),t.race.spiritual&&(a*=1+Ei.spiritual.vars()[0]/100);let r=ts("seraph");if(r>0&&(a*=1+Ei.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1+Y.theocracy()[0]/100),t.race.ooze&&(a*=1-Ei.ooze.vars()[1]/100),a=+a.toFixed(3),e=`
                ${z("city_temple_effect1",[a])}
                `,"antimatter"===t.race.universe){let a=6;if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.12:t.genes.ancients>=3?.1:.08;t.race.high_pop&&(e=ke(e)),a+=e*ea(t.civic.priest.workers,"priest")}e+=`
                ${z("city_temple_effect5",[a.toFixed(2)])}
                `}}else{let a=t.tech.anthropology&&t.tech.anthropology>=1?8:5;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=.2*ea(t.civic.professor.workers,"professor");t.race.high_pop&&(e=ke(e)),a+=+e.toFixed(1)}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.15:t.genes.ancients>=3?.125:.1;t.race.high_pop&&(e=ke(e)),a+=e*ea(t.civic.priest.workers,"priest")}t.race.spiritual&&(a*=1+Ei.spiritual.vars()[0]/100);let r=ts("seraph");r>0&&(a*=1+Ei.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1+Y.theocracy()[0]/100),t.race.ooze&&(a*=1-Ei.ooze.vars()[1]/100),t.race.orbit_decayed&&t.race.truepath&&(a*=.1),a=+a.toFixed(3),e=`
                ${z("city_temple_effect2",[a])}
                `}return t.tech.fanaticism&&t.tech.fanaticism>=3&&(e+=`
                ${z("city_temple_effect3")}
                `),t.tech.anthropology&&t.tech.anthropology>=4&&(e+=`
                ${t.race.truepath?z("city_temple_effect_tp",[2,25]):z("city_temple_effect4")}
                `),e}function Kr(){let e=t.tech.gambling>=3?6e4:4e4;t.tech.gambling>=5&&(e+=t.tech.gambling>=6?24e4:6e4),e=br(e),t.race.gambler&&(e*=1+.04*t.race.gambler),t.tech.world_control&&(e*=1.25),t.race.truepath&&(e*=1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(e*=1+.05*t.tech.stock_exchange),t.race.inflation&&(e*=1+t.race.inflation/100),t.tech.isolation&&(e*=5.5),e=Math.round(e);let a=t.race.joyless?"":`
                ${z("city_max_entertainer",[ta(1)])}
                `,r=t.race.orbit_decayed||t.tech.isolation?`
                ${z("plus_max_resource",[ta(1),z("banker_name")])}
                `:"",i=`
                ${z("plus_max_resource",[`$${e.toLocaleString()}`,z("resource_Money_name")])}
                ${a}${r}
                ${z("city_max_morale",[1])}
                `,s=Math.log2(1+t.resource[t.race.species].amount)*(t.race.gambler?2.5+t.race.gambler/10:2.5);return t.tech.gambling&&t.tech.gambling>=2&&(s*=t.tech.gambling>=5?2:1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(s*=1+.01*t.tech.stock_exchange),"corpocracy"===t.civic.govern.type&&(s*=3),"socialist"===t.civic.govern.type&&(s*=.8),t.race.inflation&&(s*=1+t.race.inflation/1250),t.tech.isolation&&(s*=1.25,t.tech.iso_gambling&&(s*=1+.05*ea(t.civic.banker.workers,"banker"))),s=+s.toFixed(2),i+=`
                ${z("tech_casino_effect2",[s])}
                `,i}function Dr(e,a,r,i){return((t.evolution.hasOwnProperty(e)?t.evolution[e].count:0)+(i||0))*r+a}function Br(e){return t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),Math.round(e)}function Gr(){let e=1.25*(t.tech.storage-1)+1;t.tech.storage>=3&&(e*=t.tech.storage>=4?3:1.5),t.race.pack_rat&&(e*=1+Ei.pack_rat.vars()[1]/100);let a=ts("kobold");return a>0&&(e*=1+Ei.pack_rat.vars(1)[1]/100*a),t.tech.storage>=6&&(e*=1+t.tech.supercollider/20),t.tech.tp_depot&&(e*=1+t.tech.tp_depot/20),t.tech.shelving&&t.tech.shelving>=3&&(e*=1.5),t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),e*=t.tech.world_control?3:1,t.race.ascended&&(e*=1.1),t.blood.hoarder&&(e*=1+t.blood.hoarder/100),t.tech.storage>=7&&t.interstellar.cargo_yard&&(e*=1+t.interstellar.cargo_yard.count*_/100),e}function Nr(e){if((t.race.kindling_kindred||t.race.smoldering)&&"lumber"===e)return!1;if((t.race.kindling_kindred||t.race.smoldering)&&"stone"===e)return!0;let a=t.race.truepath?"truepath":"standard";if(Mr.city[e].hasOwnProperty("path")&&!Mr.city[e].path.includes(a))return!1;var r=!0;return Object.keys(Mr.city[e].reqs).forEach((function(a){(!t.tech[a]||t.tech[a]=3&&(i=!0,t.r_queue.queue.forEach((function(e){Hr(e.type,!1)&&(a[Mr[e.action][e.type].grant[0]]={v:Mr[e.action][e.type].grant[1],a:e.type})})),Object.keys(s).forEach((function(r){let s=t.tech[r]||0;Rr(r,t.tech[r])||(!a[r]||a[r].vs+1)&&(i=!1)}))),!(!r&&!i||t.tech[Mr.tech[e].grant[0]]&&!(t.tech[Mr.tech[e].grant[0]]`).appendTo("#city").append(`

                ${z(`city_dist_${a}`)}

                `),e[a].forEach((function(e){Jr("city",e)})),ls(`dist-${a}`,(function(){return z(`city_dist_${a}_desc`)}),{elm:`#city-dist-${a} h3`,classes:"has-background-light has-text-dark"})}}))}function Qr(){if(!t.settings.tabLoad&&3!==t.settings.civTabs)return;let e={},a={},r={},i=[],s=[],n=[];["primitive","civilized","discovery","industrialized","globalized","early_space","deep_space","interstellar","intergalactic"].forEach((function(e){r[e]=[]}));const c={interstellar:"solar"};let o={};Object.keys(Mr.tech).forEach((function(l){if(!function(e){let a=t.race.truepath?"truepath":"standard";return!(!jr[a].includes(Mr.tech[e].era)&&!Mr.tech[e].hasOwnProperty("path")||Mr.tech[e].hasOwnProperty("path")&&!Mr.tech[e].path.includes(a))}(l))return;ti(Mr.tech[l].id);let _=function(e){let a=Mr.tech[e].grant[0];if(t.tech[a]&&t.tech[a]>=Mr.tech[e].grant[1]){if("fanaticism"!==e&&"anthropology"!==e&&"deify"!==e&&"study"!==e)return!0;if("fanaticism"===e&&t.tech.fanaticism)return!0;if("anthropology"===e&&t.tech.anthropology)return!0;if("deify"===e&&t.tech.ancient_deify)return!0;if("study"===e&&t.tech.ancient_study)return!0}return!1}(l),d=Mr.tech[l],p="category"in d?d.category:"research";if(_||-1!==i.indexOf(p)||i.push(p),_&&-1===s.indexOf(p)&&s.push(p),-1===n.indexOf(p)&&n.push(p),!0===_)p in a||(a[p]=[]),a[p].push(l);else{let a=Mr.tech[l];if(!Ur(a))return;let i=Hr(l,o);if(!i)return;p in e||(e[p]=[]);let s=t.race.truepath&&c[a.era]?c[a.era]:a.era;r.hasOwnProperty(s)||(r[s]=[]),r[s].push({t:l,p:"precog"===i})}})),Ss($("#tech")),Object.keys(r).forEach((function(e){r[e].length>0&&($("#tech").append(`

                ${z(`tech_era_${e}`)}

                `),r[e].sort((function(e,t){return null==Mr.tech[e.t].cost.Knowledge?-1:null==Mr.tech[t.t].cost.Knowledge||Mr.tech[e.t].cost.Knowledge()>Mr.tech[t.t].cost.Knowledge()?1:-1})),r[e].forEach((function(e){Jr("tech",e.t,!1,!!e.p&&o)})))})),n.forEach((function(e){Ss($(`#tech-dist-${e}`),!0),Ss($(`#tech-dist-old-${e}`),!0)})),s.forEach((function(e){if(!(e in a))return;$(`
                `).appendTo("#oldTech").append(`

                ${z(`tech_dist_${e}`)}

                `);let t=Js(4,12,!1);t.length>0&&"science"===e&&$("#tech-dist-old-science h3").append(t),a[e].forEach((function(e){Jr("tech",e,!0,!1)}))}))}function Jr(e,t,a,r){Zr(Mr[e][t],e,t,a,r)}function Zr(e,a,r,i,s){if(!1===Ur(e))return;let n=a;"outerSol"===a&&(a="space"),e.region&&(a=e.region),e.powered&&!t[a][r].on&&(t[a][r].on=0);let c=e.id;ti(c);let o="";s&&e&&e.reqs&&Object.keys(e.reqs).forEach((function(e){s[e]&&(o+=` data-req-${e}="${s[e].a}"`)}));let l,_=e.highlight&&e.highlight()?$(`
                `):$(`
                `);if(ii(e,!1,["genes","blood"].includes(a))||_.addClass("cna"),ii(e,!0,["genes","blood"].includes(a))||_.addClass("cnam"),i)l=$('{{ title }}');else{let t="",r="";if(e.cost){let i="genes"!==a&&"blood"!==a?Ns(e):e.cost;Object.keys(i).forEach((function(e){let a=i[e]();a>0&&(t+=` res-${e}`,r+=` data-${e}="${a}"`)}))}let i="";e.class&&(i="function"==typeof e.class?` ${e.class()}`:` ${e.class}`),s&&(i=" precog");let n=e.highlight?e.highlight()?`${z("active")}`:`${z("not_active")}`:"";l=$(`${n}{{ title }} description`)}if(_.append(l),e.hasOwnProperty("special")&&("function"==typeof e.special&&e.special()||!0===e.special)){let e=$('
                \n \n
                ');_.append(e)}if(e.on||e.off){if(e.on){let e=$('');_.append(e)}if(e.off){let e=$('');_.append(e)}}else if(e.powered&&t.tech.high_tech&&t.tech.high_tech>=2&&Vr(e)||e.switchable&&e.switchable()){let t=$(``),a=$(``);_.append(t),_.append(a)}if(e.count){let t=e.count();t>1&&l.append($(`${t}`))}else"tech"!==a&&t[a]&&t[a][r]&&t[a][r].count>=0?l.append($('{{ act.count }}')):"blood"===a&&t[a]&&t[a][e.grant[0]]&&t[a][e.grant[0]]>0&&"*"===e.grant[1]&&l.append($(` ${t[a][e.grant[0]]} `));if("tech"!==a&&t[a]&&t[a][r]&&void 0!==t[a][r].repair&&l.append($('
                ')),i?$("#oldTech").append(_):$("#"+n).append(_),"tech"!==a&&t[a]&&t[a][r]&&0===t[a][r].count&&($(`#${c} .count`).css("display","none"),$(`#${c} .special`).css("display","none"),$(`#${c} .on`).css("display","none"),$(`#${c} .off`).css("display","none")),e.emblem){let t=e.emblem();_.append($(t))}let d={template:''};Cs({el:"#"+c,data:{title:"string"==typeof e.title?e.title:e.title(),act:t[a][r]},methods:{action(){"ontouchstart"in document.documentElement&&navigator.userAgent.match(t.settings.touch)||Xr(e,a,r)},describe(){q(function(e,a){let r="string"==typeof e.desc?e.desc:e.desc();if(r+=". ",e.cost&&!a){r=ii(e)?r+z("affordable")+". ":r+z("not_affordable")+". ",r+="Costs: ";let a=e.id.split("-")[0];var i="genes"!==a&&"blood"!==a?Ns(e):e.cost;Object.keys(i).forEach((function(e){if("Custom"===e){let t=i[e]();r+=t.label}else if("Structs"===e){let a=i[e]();Object.keys(a).forEach((function(e){Object.keys(a[e]).forEach((function(i){let s="";if(a[e][i].hasOwnProperty("s")){let t=a[e][i].s;s="string"==typeof Mr[e][t][i].title?Mr[e][t][i].title:Mr[e][t][i].title()}else s="string"==typeof Mr[e][i].title?Mr[e][i].title:Mr[e][i].title();r+=`${s}. `,t[e][i]?a[e][i].count>t[e][i].count?r+=`${z("insufficient")} ${s}. `:a[e][i].hasOwnProperty("on")&&a[e][i].on>t[e][i].on&&(r+=`${z("insufficient")} ${s} enabled. `):r+=`${z("insufficient")} ${s}. `}))}))}else if(t.prestige.hasOwnProperty(e)){let a=i[e]();if(a>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let i=z(`resource_${e}_name`);r+=`${i}: ${a}. `,t.prestige[e].count0){let i=z(`resource_${e}_name`);r+=`${i}: ${a}. `,t.portal.purifier.supply0){let e="Money"===s?"$":t.resource[s].name+": ";e=e.replace("_"," ");let i=x(a,1);r+=`${e}${i}. `,t.resource[s].amount0&&(clearInterval(t),oi(e,r))}),50)}},on_label:()=>`on: ${t[a][r].on}`,off_label:()=>"off: "+(t[a][r].count-t[a][r].on),power_on(){let i=y();for(let e=0;e0;e++)t[a][r].on--;e.postPower&&setTimeout((function(){e.postPower(!1)}),250)},repair:()=>t[a][r].repair,repairMax:()=>e.repair()},filters:{val(t){switch(t){case"on":return e.on();case"off":return e.off()}},p_off(e,i){let s=t[a][r].count-e;if("city-casino"===i&&!t.race.cataclysm&&!t.race.orbit_decayed||"space-spc_casino"===i&&(t.race.cataclysm||t.race.orbit_decayed)||"tauceti-tauceti_casino"===i&&t.tech.isolation){let e=Qs(5,12);if(0===s&&e.length>0)return e}return s},p_on(e,a){if("city-biolab"===a&&!t.race.cataclysm&&!t.race.orbit_decayed||(t.race.cataclysm||t.race.orbit_decayed)&&"space-exotic_lab"===a||t.tech.isolation&&"tauceti-infectious_disease_lab"===a){let t=Qs(12,12);if(0===e&&t.length>0)return t}else if("city-garrison"===a||"space-space_barracks"===a){let t=Js(1,14,!0);if(e===("city-garrison"===a?13:0)&&t.length>0)return t}return e},title:e=>e,options:e=>z("action_options",[e])}}),ls(c,(function(){}),{in:function(s){ei(s.popper,e,t[a][r],i,a,r)},out:function(){Cs({el:"#popTimer"},"destroy")},attach:"starDock"===a?"body .modal":"#main",wide:e.wide})}function Xr(e,a,r){if("spcdock-launch_ship"===e.id)e.action();else switch(a){case"tech":if(t.settings.qKey&&f.q||!Hr(r,!1)||!e.action()){if((!e.no_queue||!e.no_queue())&&t.tech.r_queue&&t.r_queue.queue.length0){let o=t.settings.qKey?i:1;o>t.queue.max-s&&(o=t.queue.max-s);let l=e.queue_size?e.queue_size:1;if(e.region&&(a=e.id.split("-")[0]),"merge_never"!==t.settings.q_merge)t.queue.queue.length>0&&t.queue.queue[t.queue.queue.length-1].id===e.id?t.queue.queue[t.queue.queue.length-1].q+=Math.min(c,l*o):t.queue.queue.push({id:e.id,action:a,type:r,label:"string"==typeof e.title?e.title:e.title(),cna:!1,time:0,q:Math.min(c,l*o),qs:l,t_max:0,bres:!1});else for(let i=0;i0;i++)t.queue.queue.push({id:e.id,action:a,type:r,label:"string"==typeof e.title?e.title:e.title(),cna:!1,time:0,q:Math.min(c,l),qs:l,t_max:0,bres:!1}),c-=l;n=!0}}break}t.race.inflation&&t.tech.primitive&&(e.hasOwnProperty("inflation")&&!e.inflation||t.race.inflation++),s=!0}if(s&&(function(e,a,r){if(!ii(e)){let t=e.id;$(`#${t}`).addClass("cna")}if(e.grant){let a=e.grant[0];(!t.tech[a]||t.tech[a]a?(s.q=a,a=0):a-=s.q)}}n&&ys();break}}}function Yr(e,a){let r=e.id.split("-");if(t.hasOwnProperty(r[0])&&t[r[0]].hasOwnProperty(r[1])&&e.hasOwnProperty("powered")){let i=t.city.power;return t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks")&&t.race.hasOwnProperty("replicator")&&Object.values(t.race.governor.tasks).includes("replicate")&&t.race.governor.config.replicate.pow.on&&t.race.replicator.pow>0&&(i+=t.race.replicator.pow),!(t.city.hasOwnProperty("powered")&&i>=e.powered()&&(t[r[0]][r[1]].on++,t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks")&&t.race.hasOwnProperty("replicator")&&Object.values(t.race.governor.tasks).includes("replicate")&&t.race.governor.config.replicate.pow.on&&t.race.replicator.pow>0&&(t.city.power-=e.powered(),B.replicate.task()),a&&"function"==typeof a))||a(e)}return!1}function ei(e,a,r,i,s,n,c){Ss(e);var o="string"==typeof a.desc?a.desc:a.desc();c=c||!1;let l=!1;!(s&&n&&"ontouchstart"in document.documentElement&&navigator.userAgent.match(/Mobi/)&&t.settings.touch)||(l=$(`${a.hasOwnProperty("touchlabel")?a.touchlabel:z("construct")}`),e.append(l),$("#touchButton").on("touchstart",(function(){Xr(a,s,n)}))),e.append($(`
                ${o}
                `));let _=a.id.split("-")[0];a.category&&"tech"===_&&!i&&e.append($(`
                ${z("tech_dist_category")}: ${z(`tech_dist_${a.category}`)}
                `));let d=Os(a,!1,!0);if(a.cost&&!i){let r=!0;var p=$('
                '),u="genes"!==_&&"blood"!==_?Ns(a):a.cost;Object.keys(u).forEach((function(e){if("Custom"===e){let t=u[e]();p.append($(`
                ${t.label}
                `)),r=!1}else if("Structs"===e){let a=u[e]();Object.keys(a).forEach((function(e){Object.keys(a[e]).forEach((function(i){let s=a[e][i].hasOwnProperty("on")?a[e][i].on:a[e][i].count,n="has-text-dark",c="";t[e][i]?a[e][i].count>t[e][i].count?(n="has-text-danger",c=' (blocking resource)'):a[e][i].hasOwnProperty("on")&&a[e][i].on>t[e][i].on&&(n="has-text-alert"):(n="has-text-danger",c=' (blocking resource)');let o="";if(a[e][i].hasOwnProperty("s")){let t=a[e][i].s;o="string"==typeof Mr[e][t][i].title?Mr[e][t][i].title:Mr[e][t][i].title()}else o="string"==typeof Mr[e][i].title?Mr[e][i].title:Mr[e][i].title();r=!1,p.append($(`
                ${o}: ${s}${c}
                `))}))}))}else if(t.prestige.hasOwnProperty(e)){let a=u[e]();if(a>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let i=z(`resource_${e}_name`),s="has-text-dark",n="";t.prestige[e].count(blocking resource)'),r=!1,p.append($(`
                ${i}: ${a}${n}
                `))}}else if("Supply"===e){let a=u[e]();if(a>0){let i=z(`resource_${e}_name`),s="has-text-dark",n="";t.portal.purifier.supply(blocking resource)'),r=!1,p.append($(`
                ${i}: ${a}${n}
                `))}}else if("Morale"!==e&&"Army"!==e&&"Bool"!==e){let a=u[e]();if(a>0){let i="",s="Species"===e?t.race.species:e;if("HellArmy"===e){let n=z("fortress_troops"),c="has-text-dark";t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size(blocking resource)'):c="has-text-alert"),r=!1,p.append($(`
                ${n}: ${a}${i}
                `))}else{let i="Money"===s?"$":t.resource[s].name+": ";i=i.replace("_"," ");let n="has-text-dark",o="";t.resource[s].amount(blocking resource)'):n="has-text-alert",c&&c!==e&&d.r===s?(n+=" grad-from-left",o=' (first blocking resource)'):c&&c===e&&d.r!==s&&(n+=" grad-from-left-warn")):c&&c===e&&(n+=" grad-from-right",o=' (last blocking resource)');let l=x(a,1);r=!1,p.append($(`
                ${i}${l}${o}
                `))}}}})),r||e.append(p)}if(a.effect){var h="string"==typeof a.effect?a.effect:a.effect();h&&e.append($(`
                ${h}
                `))}if(a.flair){var m="string"==typeof a.flair?a.flair:a.flair();e.append($(`
                ${m}
                `)),e.addClass("flair")}if(a.reqs){let t=[];if(Object.keys(a.reqs).forEach((function(e){let r=$(`#${a.id}`).attr(`data-req-${e}`);r&&t.push("string"==typeof Mr.tech[r].title?Mr.tech[r].title:Mr.tech[r].title())})),t.length>0){let a=t.join(", ");e.append($(`
                ${z("requires_tech",[a])}
                `))}}if(!i&&"blood"!==a.id.substring(0,5)&&!ii(a)&&ii(a,!0)){if("string"==typeof r&&"notimer"===r)return;if(r&&r.time)e.append($('
                {{ time | timer }}
                ')),Cs({el:"#popTimer",data:r,filters:{timer:e=>z("action_ready",[e])}});else{let t=zs(d.t);e.append($(`
                ${z("action_ready",[t])}
                `))}}("portal-spire"===a.id||"portal-waygate"===a.id&&t.tech.waygate>=2)&&r&&r.time&&(e.append($('
                {{ time | timer }}
                ')),Cs({el:"#popTimer",data:r,filters:{timer:e=>z("floor_clearing",[!a.hasOwnProperty("mscan")||a.hasOwnProperty("mscan")&&a.mscan()>0?e:"???"])}}))}function ti(e){Ss($(`#${e}`),!0),_s(e)}function ai(e,a,r){var i=e.id;t[a]&&t[a][r]&&t[a][r].count&&($(`#${i} .count`).html(t[a][r].count),t[a][r]&&t[a][r].count>0&&($(`#${i} .count`).css("display","inline-block"),$(`#${i} .special`).css("display","block"),$(`#${i} .on`).css("display","block"),$(`#${i} .off`).css("display","block"))),$("#popper").data("id")===i&&ei($("#popper"),e,t[a][r],!1,a,r)}function ri(e,a){return!!si(a=a||Ns(e))&&(Object.keys(a).forEach((function(e){if(t.prestige.hasOwnProperty(e)){let r=a[e]();"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].count-=r}else if("Supply"===e){let r=a[e]();t.portal.purifier.supply-=r}else if("Morale"!==e&&"Army"!==e&&"HellArmy"!==e&&"Structs"!==e&&"Bool"!==e&&"Custom"!==e){let r=a[e](),i="Species"===e?t.race.species:e;t.resource[i].amount-=r,"Knowledge"===i&&(t.stats.know+=r)}})),!0)}function ii(e,a,r){if(e.cost){let n=r?e.cost:Ns(e);return a?(i=n,s=!0,Object.keys(i).forEach((function(e){if("Custom"===e);else if("Structs"===e){if(!ni(i[e]()))return void(s=!1)}else if(t.prestige.hasOwnProperty(e)){let a=e;if("Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].count0||t.resource[r].max>=0&&a>Number(t.resource[r].max)&&-1!==Number(t.resource[r].max))return void(s=!1)}})),s):si(n)}var i,s;return!0}function si(e){var a=!0;return Object.keys(e).forEach((function(r){if("Custom"===r){if(!e[r]().met)return void(a=!1)}else if("Structs"===r){if(!ni(e[r]()))return void(a=!1)}else if(t.prestige.hasOwnProperty(r)){let i=r;if("Plasmid"===r&&"antimatter"===t.race.universe&&(r="AntiPlasmid"),t.prestige[r].count=0&&i>t.resource[s].max;if(i>Number(t.resource[s].amount)+t.resource[s].diff||n)return void(a=!1)}})),a}function ni(e){let a=!0;return Object.keys(e).forEach((function(r){t.hasOwnProperty(r)?Object.keys(e[r]).forEach((function(i){t[r].hasOwnProperty(i)?(t[r][i].count${r}

                `));var i=$('
                ');switch($("#modalBox").append(i),a){case"smelter":case"hell_smelter":case"stellar_forge":case"hell_forge":case"geothermal":case"ore_refinery":wi("smelter",i);break;case"factory":case"red_factory":case"int_factory":case"tau_factory":wi("factory",i);break;case"star_dock":!function(e){if(t.tech.genesis<4){let t=$(`
                ${z("stardock_warn")}
                `);return void e.append(t)}let a=$('
                ');e.append(a),Zr(Mr.starDock.probes,"starDock","probes"),t.tech.geck&&t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5&&Zr(Mr.starDock.geck,"starDock","geck"),t.tech.genesis>=5&&Zr(Mr.starDock.seeder,"starDock","seeder"),6===t.tech.genesis&&Zr(Mr.starDock.prep_ship,"starDock","prep_ship"),t.tech.genesis>=7&&Zr(Mr.starDock.launch_ship,"starDock","launch_ship")}(i);break;case"mining_droid":wi("droid",i);break;case"g_factory":case"refueling_station":wi("graphene",i);break;case"freighter":case"super_freighter":Qa(i);break;case"pylon":wi("pylon",i);break;case"rock_quarry":wi("rock_quarry",i);break;case"titan_mine":wi("titan_mine",i);break;case"mining_ship":wi("mining_ship",i);break;case"alien_space_station":wi("alien_space_station",i);break;case"nanite_factory":wi("nanite_factory",i);break;case"alien_outpost":wi("replicator",i)}}function li(){Ss($("#evolution .evolving"),!0);let e=$(`
                ${t.evolution.final}%
                `);$("#evolution").append(e)}function _i(){return"magic"===t.race.universe?z("city_wizard_tower_title"):t.race.evil?z("city_babel_title"):z("city_wardenclyffe")}function di(){switch(t.race.species){case"orc":return z("city_basic_housing_orc_title");case"wolven":return z("city_basic_housing_wolven_title");case"sporgar":return z("city_basic_housing_sporgar_title");case"dracnid":case"balorg":return z("city_basic_housing_title7");case"imp":return z("city_basic_housing_title8");case"seraph":return z("city_basic_housing_seraph_title");case"unicorn":return z("city_basic_housing_unicorn_title")}switch(Ki[t.race.species].type){case"avian":return z("city_basic_housing_nest_title");case"plant":return z("city_basic_housing_entish_title");case"sand":return z("city_basic_housing_sand_title");case"polar":return z("city_basic_housing_polar_title");case"eldritch":return z("city_basic_housing_eldritch_title")}return t.city.ptrait.includes("trashed")?z("city_basic_housing_trash_title"):z("city_basic_housing_title")}function pi(e,a){switch(e){case"small":return di();case"medium":return function(){switch(t.race.species){case"sporgar":return z("city_cottage_title2");case"balorg":return z("city_cottage_title3");case"imp":return z("city_basic_housing_title7");case"seraph":return z("city_cottage_title4");case"unicorn":return z("city_cottage_title5");case"dracnid":return z("city_cottage_title7")}switch(Ki[t.race.species].type){case"avian":return z("city_cottage_title6");case"eldritch":return z("city_cottage_title8")}return z("city_cottage_title1")}();case"large":return function(e){if(!e&&K("extravagant",0))return z("city_mansion");if("sporgar"===t.race.species)return z("city_apartment_title2");switch(Ki[t.race.species].type){case"avian":return z("city_apartment_title5");case"sand":return z("city_apartment_title6");case"demonic":return z("city_apartment_title3");case"angelic":return z("city_apartment_title4");case"giant":return z("city_apartment_title7");case"eldritch":return z("city_apartment_title8")}return z("city_apartment_title1")}(a)}}function ui(e,a){if(t.tech.queue&&t.queue.display){let e=["space","interstellar","galaxy","portal","tauceti"];for(let r=0;r-1)if(e.includes(i.action)){let e=!0;Object.keys(Mr[i.action]).forEach((function(a){Mr[i.action][a][i.type]&&e&&(t.queue.queue[r].label="string"==typeof Mr[i.action][a][i.type].title?Mr[i.action][a][i.type].title:Mr[i.action][a][i.type].title(),e=!1)}))}else Mr[i.action][i.type]&&(t.queue.queue[r].label="string"==typeof Mr[i.action][i.type].title?Mr[i.action][i.type].title:Mr[i.action][i.type].title())}}if(e&&t.tech.r_queue&&t.r_queue.display)for(let e=0;e=4&&es(e)})),Object.keys(Ki[t.race.species].traits).forEach((function(e){es(e,{set:Ki[t.race.species].traits[e]})})),t.race.imitation&&t.race.srace&&Xi(!1),Object.keys(t.tech).forEach((function(e){"evo_"===e.substring(0,4)&&delete t.tech[e]})),delete t.tech.evo,t.evolution={};const s=new Date;!t.settings.boring&&11===s.getMonth()&&s.getDate()>=17&&("elven"===t.race.species?(es("slaver",{set:2}),es("resourceful",{set:.5}),es("small",{set:.25})):"capybara"===t.race.species?(es("beast_of_burden",{set:1}),es("pack_rat",{set:.5}),es("musical",{set:.25})):"centaur"===t.race.species?(es("beast_of_burden",{set:1}),es("curious",{set:.5}),es("blissful",{set:.25})):"wendigo"===t.race.species?(es("immoral",{set:3}),es("cannibalize",{set:.5}),es("claws",{set:.25})):"yeti"===t.race.species?(es("scavenger",{set:3}),es("regenerative",{set:.5}),es("musical",{set:.25})):"entish"===t.race.species&&(es("photosynth",{set:3}),es("optimistic",{set:.5}),es("armored",{set:.25})));const n=cn("easter");if("wolven"===t.race.species&&n.active?(es("hyper",{set:1}),es("fast_growth",{set:1}),es("rainbow",{set:1}),es("optimistic",{set:1})):"vulpine"===t.race.species&&n.active&&(es("cannibalize",{set:2}),es("rage",{set:1}),es("blood_thirst",{set:1}),es("sticky",{set:1})),t.race.no_crispr||t.race.badgenes){let e=t.race.badgenes?3:1;for(let a=0;a=2)for(let e=1;e<8;e++)t.genes.evolve>=e+1&&Gi(e);let l=xs();t.civic.foreign.gov0.name={s0:l.s0,s1:l.s1};let _=xs();for(;l.s0===_.s0&&l.s1===_.s1;)_=xs();t.civic.foreign.gov1.name={s0:_.s0,s1:_.s1};let d=xs();for(;l.s0===d.s0&&l.s1===d.s1||_.s0===d.s0&&_.s1===d.s1;)d=xs();if(t.civic.foreign.gov2.name={s0:d.s0,s1:d.s1},t.race.truepath||t.race.lone_survivor){t.civic.foreign.gov0.mil=Math.round(1.5*t.civic.foreign.gov0.mil),t.civic.foreign.gov1.mil=Math.round(1.4*t.civic.foreign.gov1.mil),t.civic.foreign.gov2.mil=Math.round(1.25*t.civic.foreign.gov2.mil),t.civic.foreign.gov3={unrest:0,hstl:Math.floor(m(20,40)),mil:Math.floor(m(650,750)),eco:Math.floor(m(250,300)),spy:0,esp:0,trn:0,sab:0,act:"none"};let e=xs(!0);t.civic.foreign.gov3.name={s0:e.s0,s1:e.s1},t.civic.foreign.gov4={unrest:0,hstl:100,mil:300,eco:100,spy:0,esp:0,trn:0,sab:0,act:"none"};let a=xs(!0);for(;a.s1===e.s1;)a=xs(!0);t.civic.foreign.gov4.name={s0:99,s1:a.s1}}if(t.race.cataclysm?hs(z("cataclysm_sentience",[Ki[t.race.species].home,nn("name")]),"info",!1,["progress"]):hs(z("sentience",[z("genelab_genus_"+Ki[t.race.species].type),Ki[t.race.species].entity,nn("name")]),"info",!1,["progress"]),t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1&&(t.resource.Steel.display=!0,t.resource.Steel.amount=25,t.stats.achieve.technophobe.l>=3)){t.race.truepath||(t.resource.Soul_Gem.display=!0);let e=1;for(let a=1;a=5&&e++;t.resource.Soul_Gem.amount=e}if("tortoisan"===t.race.species){let e=Math.floor(m(100));t.race.shell_color=99===e?"rainbow":e>=97&&e<=98?"white":e>=93&&e<=96?"red":e>=89&&e<=92?"orange":e>=85&&e<=88?"yellow":e>=75&&e<=84?"purple":e>=65&&e<=74?"blue":"green"}if("vulpine"===t.race.species){let e=Math.floor(m(100));t.race.fox_color=e>=85?"white":e>=70&&e<=84?"tan":e>=55&&e<=69?"silver":e>=35&&e<=54?"grey":"red"}if(Ks(!0),t.blood.aware&&(t.settings.arpa.blood=!0,t.tech.b_stone=2),Yt(!0),Q(),V(!0),t.race.shapeshifter&&Yi(!1,!0),t.race.carnivore||t.race.soul_eater||t.race.unfathomable?(t.civic.d_job="hunter",t.civic.hunter.display=!0):t.race.forager?(t.civic.d_job="forager",t.civic.forager.display=!0):(t.civic.d_job="unemployed",t.civic.unemployed.display=!0),t.race.hooved&&(t.resource.Horseshoe.display=!0,t.resource.Horseshoe.amount=5,t.race.shoecnt=5),t.race.deconstructor&&(t.resource.Nanite.display=!0,t.city.nanite_factory={count:1,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Bolognium:0,Orichalcum:0},t.settings.showIndustry=!0),Ts(!0),(t.race.truepath||t.race.lone_survivor)&&Object.keys(Ca).forEach((function(e){t.resource.hasOwnProperty(e)&&(t.resource[e].value=2*Ca[e])})),Ti(t.race.species,!0),ks("sentience",{species:t.race.species,challenge:Mn()-1}),t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0){let e=Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept);t.resource.Food.amount+=100*e,t.resource.Stone.max+=60*e,t.resource.Stone.amount+=100*e,t.race.smoldering?(t.resource.Chrysotile.max+=60*e,t.resource.Chrysotile.amount+=100*e):(t.resource.Lumber.max+=60*e,t.resource.Lumber.amount+=100*e)}t.race.cataclysm?t.race.cataclysm&&(t.tech.unify=2,t.tech.spy=5,t.tech.primitive=3,t.tech.currency=6,t.tech.govern=3,t.tech.boot_camp=1,t.tech.medic=1,t.tech.military=5,t.tech.marines=1,t.tech.explosives=3,t.tech.trade=3,t.tech.wharf=1,t.tech.banking=6,t.tech.gambling=1,t.tech.home_safe=1,t.tech.housing=3,t.tech.smelting=3,t.tech.copper=1,t.tech.storage=5,t.tech.container=4,t.tech.steel_container=3,t.tech.mining=4,t.tech.oil=7,t.tech.mass=1,t.tech.alumina=1,t.tech.titanium=2,t.tech.polymer=2,t.tech.uranium=4,t.tech.foundry=7,t.tech.factory=1,t.tech.theatre=3,t.tech.broadcast=2,t.tech.mine_conveyor=1,t.tech.science=9,t.tech.high_tech=7,t.tech.genetics=1,t.tech.theology=2,t.tech.space=6,t.tech.solar=3,t.tech.luna=2,t.tech.hell=1,t.tech.mars=5,t.tech.gas_giant=1,t.tech.gas_moon=2,t.tech.asteroid=3,t.tech.satellite=1,t.tech.space_explore=4,t.tech.genesis=2,t.settings.showSpace=!0,t.settings.space.home=!0,t.settings.space.moon=!0,t.settings.space.red=!0,t.settings.space.hell=!0,t.settings.space.sun=!0,t.settings.space.gas=!0,t.settings.space.gas_moon=!0,t.settings.space.belt=!0,t.settings.space.dwarf=!0,t.settings.showCity=!1,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.settings.civTabs=1,t.settings.spaceTabs=1,t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Food.display=!0,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Cement.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Uranium.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Alloy.display=!0,t.resource.Polymer.display=!0,t.resource.Iridium.display=!0,t.resource.Helium_3.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Mythril.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.resource.Lumber.max=9e4,t.resource.Lumber.amount=9e4,t.resource.Plywood.amount=5e4),t.race.smoldering&&(t.resource.Chrysotile.display=!0,t.resource.Chrysotile.max=9e4,t.resource.Chrysotile.amount=9e4),t.resource[t.race.species].max=8,t.resource[t.race.species].amount=8,t.resource.Crates.amount=20,t.resource.Containers.amount=20,t.resource.Money.max=225e3,t.resource.Money.amount=225e3,t.resource.Food.max=1e3,t.resource.Food.amount=1e3,t.resource.Oil.max=1e3,t.resource.Oil.amount=1e3,t.resource.Helium_3.max=1e3,t.resource.Helium_3.amount=1e3,t.resource.Uranium.max=1e3,t.resource.Uranium.amount=1e3,t.resource.Stone.max=9e4,t.resource.Stone.amount=9e4,t.resource.Furs.max=4e4,t.resource.Furs.amount=4e4,t.resource.Copper.max=75e3,t.resource.Copper.amount=75e3,t.resource.Iron.max=75e3,t.resource.Iron.amount=75e3,t.resource.Steel.max=75e3,t.resource.Steel.amount=75e3,t.resource.Aluminium.max=75e3,t.resource.Aluminium.amount=75e3,t.resource.Cement.max=75e3,t.resource.Cement.amount=75e3,t.resource.Titanium.max=75e3,t.resource.Titanium.amount=75e3,t.resource.Coal.max=1e4,t.resource.Coal.amount=1e4,t.resource.Alloy.max=2e4,t.resource.Alloy.amount=2e4,t.resource.Polymer.max=2e4,t.resource.Polymer.amount=2e4,t.resource.Iridium.max=1e3,t.resource.Iridium.amount=1e3,t.resource.Brick.amount=5e4,t.resource.Wrought_Iron.amount=5e4,t.resource.Sheet_Metal.amount=5e4,t.resource.Mythril.amount=8e3,t.resource.Iridium.crates=5,t.resource.Iridium.containers=5,t.civic.taxes.display=!0,t.civic.professor.display=!0,t.civic.scientist.display=!0,t.civic.colonist.display=!0,t.civic.space_miner.display=!0,t.race.flier||(t.tech.cement=5,t.civic.cement_worker.display=!0,t.civic.cement_worker.max=1,t.civic.cement_worker.workers=1),t.civic.colonist.max=4,t.civic.colonist.workers=4,t.civic.space_miner.max=3,t.civic.space_miner.workers=2,t.civic.professor.max=1,t.civic.professor.workers=1,t.city.calendar.day++,t.city.market.active=!0,t.city.power=0,t.city.powered=!0,t.race.artifical&&(t.city.transmitter={count:0,on:0}),t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:0,cap:2,Wood:0,Coal:0,Oil:2,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:1,Iridium:0},t.city.fission_power={count:0,on:0},t.city.oil_power={count:0,on:0},t.city.coal_power={count:0,on:0},t.city.mass_driver={count:0,on:0},t.city.mine={count:0,on:0},t.city.coal_mine={count:0,on:0},t.city.oil_well={count:0},t.city.oil_depot={count:0},t.city.garrison={count:0,on:0},t.city.basic_housing={count:0},t.city.cottage={count:0},t.city.apartment={count:0,on:0},t.city.amphitheatre={count:0},t.city.casino={count:0,on:0},t.city.rock_quarry={count:0,on:0,asbestos:50},t.city.metal_refinery={count:0,on:0},t.city.storage_yard={count:0},t.city.warehouse={count:0},t.city.trade={count:0},t.city.wharf={count:0},t.city.bank={count:0},t.city.tourist_center={count:0,on:0},t.city.university={count:0},t.city.library={count:0},t.city.wardenclyffe={count:0,on:0},t.city.biolab={count:0,on:0},t.city.lumber_yard={count:0},t.city.sawmill={count:0,on:0},t.city.temple={count:0},t.space.satellite={count:1},t.space.propellant_depot={count:1},t.space.gps={count:4},t.space.nav_beacon={count:1,on:1},t.space.moon_base={count:1,on:1,support:3,s_max:3},t.space.iridium_mine={count:1,on:1},t.space.helium_mine={count:1,on:1},t.space.observatory={count:1,on:1},t.space.spaceport={count:2,on:2,support:8,s_max:10},t.space.red_tower={count:1,on:1},t.space.living_quarters={count:4,on:4},t.space.vr_center={count:0,on:0},t.space.garage={count:1},t.space.red_mine={count:1,on:1},t.space.fabrication={count:1,on:1},t.space.red_factory={count:1,on:1},t.space.exotic_lab={count:1,on:1},t.space.ziggurat={count:0},t.space.space_barracks={count:1,on:1},t.space.biodome={count:2,on:2},t.space.laboratory={count:0,on:0},t.space.geothermal={count:2,on:2},t.space.spc_casino={count:0,on:0},t.space.swarm_plant={count:0},t.space.swarm_control={count:5,support:40,s_max:50},t.space.swarm_satellite={count:40},t.space.gas_mining={count:2,on:2},t.space.gas_storage={count:1},t.space.outpost={count:0,on:0},t.space.drone={count:0},t.space.oil_extractor={count:2,on:2},t.space.space_station={count:1,on:1,support:0,s_max:3},t.space.iridium_ship={count:1,on:1},t.space.elerium_ship={count:0,on:0},t.space.elerium_prospector={count:0,on:0},t.space.iron_ship={count:1,on:1},t.space.elerium_contain={count:0,on:0},t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:2,wounded:0,raid:0,max:2},Wr(),Qr(),Lt(),xe("Physics"),sa()):t.race.lone_survivor?t.race.lone_survivor&&(t.tech.alloy=1,t.tech.alumina=2,t.tech.asteroid=7,t.tech.banking=11,t.tech.biotech=1,t.tech.boot_camp=2,t.tech.broadcast=2,t.tech.container=7,t.tech.copper=1,t.tech.currency=6,t.tech.disease=2,t.tech.drone=1,t.tech.elerium=2,t.tech.explosives=3,t.tech.factory=3,t.tech.foundry=8,t.tech.gambling=4,t.tech.gas_giant=1,t.tech.gas_moon=2,t.tech.genesis=2,t.tech.genetics=2,t.tech.gov_corp=1,t.tech.gov_fed=1,t.tech.gov_soc=1,t.tech.gov_theo=1,t.tech.govern=3,t.tech.graphene=1,t.tech.helium=1,t.tech.hell=1,t.tech.high_tech=13,t.tech.home_safe=2,t.tech.housing=3,t.tech.housing_reduction=3,t.tech.kuiper=2,t.tech.launch_facility=1,t.tech.luna=2,t.tech.m_smelting=2,t.tech.marines=2,t.tech.mars=5,t.tech.mass=1,t.tech.medic=3,t.tech.military=8,t.tech.mine_conveyor=1,t.tech.mining=4,t.tech.monument=1,t.tech.nano=1,t.tech.oil=7,t.tech.outer=8,t.tech.pickaxe=5,t.tech.polymer=2,t.tech.primitive=3,t.tech.q_factory=1,t.tech.quantium=1,t.tech.queue=3,t.tech.r_queue=1,t.tech.reproduction=1,t.tech.rival=1,t.tech.satellite=1,t.tech.science=9,t.tech.shelving=3,t.tech.shipyard=1,t.tech.smelting=6,t.tech.solar=5,t.tech.space=6,t.tech.space_explore=4,t.tech.space_housing=1,t.tech.spy=5,t.tech.stanene=1,t.tech.steel_container=6,t.tech.storage=5,t.tech.swarm=6,t.tech.syard_armor=3,t.tech.syard_class=6,t.tech.syard_engine=5,t.tech.syard_power=5,t.tech.syard_sensor=4,t.tech.syard_weapon=6,t.tech.syndicate=0,t.tech.synthetic_fur=1,t.tech.tau_home=6,t.tech.tauceti=4,t.tech.theatre=3,t.tech.theology=2,t.tech.titan=9,t.tech.titan_ai_core=3,t.tech.titan_power=1,t.tech.titanium=3,t.tech.trade=3,t.tech.unify=2,t.tech.uranium=4,t.tech.v_train=1,t.tech.vault=4,t.tech.wharf=1,t.tech.world_control=1,t.tech.wsc=0,t.race.flier||(t.tech.cement=5,t.resource.Cement.display=!0),"magic"===t.race.universe&&(t.tech.gov_mage=1,t.tech.magic=4,t.tech.conjuring=2,t.resource.Mana.display=!0,t.resource.Crystal.display=!0,t.civic.crystal_miner.display=!0,t.tauceti.pylon={count:0},t.race.casting={farmer:0,miner:0,lumberjack:0,science:0,factory:0,army:0,hunting:0,crafting:0,total:0,crafting:0}),t.settings.showSpace=!1,t.settings.showTau=!0,t.settings.tau.home=!0,t.settings.showCity=!1,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.settings.civTabs=1,t.settings.spaceTabs=6,t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.settings.arpa.genetics=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.resource.Food.display=!0,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Uranium.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Alloy.display=!0,t.resource.Polymer.display=!0,t.resource.Iridium.display=!0,t.resource.Helium_3.display=!0,t.resource.Water.display=!0,t.resource.Neutronium.display=!0,t.resource.Adamantite.display=!0,t.resource.Elerium.display=!0,t.resource.Nano_Tube.display=!0,t.resource.Graphene.display=!0,t.resource.Stanene.display=!0,t.resource.Orichalcum.display=!0,t.resource.Bolognium.display=!0,t.resource.Unobtainium.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Mythril.display=!0,t.resource.Quantium.display=!0,t.resource.Cipher.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.civic.lumberjack.display=!0,t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.resource.Lumber.max=1e7,t.resource.Lumber.amount=1e7,t.resource.Plywood.amount=25e5,t.resource.Lumber.crates=25,t.resource.Lumber.containers=25,t.tech.axe=5),t.race.smoldering&&(t.resource.Chrysotile.display=!0,t.resource.Chrysotile.max=5e6,t.resource.Chrysotile.amount=5e6),t.race.sappy||(t.tech.hammer=4),t.race.apex_predator||(t.tech.armor=3),t.resource[t.race.species].max=1,t.resource[t.race.species].amount=1,t.resource.Crates.amount=1e3,t.resource.Containers.amount=1e3,t.resource.Money.max=1e9,t.resource.Money.amount=1e9,t.resource.Knowledge.max=8e6,t.resource.Knowledge.amount=8e6,t.resource.Food.max=1e4,t.resource.Food.amount=1e4,t.resource.Oil.max=5e5,t.resource.Oil.amount=5e5,t.resource.Helium_3.max=5e5,t.resource.Helium_3.amount=5e5,t.resource.Water.max=25e3,t.resource.Water.amount=25e3,t.resource.Uranium.max=5e5,t.resource.Uranium.amount=5e5,t.resource.Stone.max=1e7,t.resource.Stone.amount=1e7,t.resource.Furs.max=5e6,t.resource.Furs.amount=5e6,t.resource.Copper.max=5e6,t.resource.Copper.amount=5e6,t.resource.Iron.max=5e6,t.resource.Iron.amount=5e6,t.resource.Steel.max=5e6,t.resource.Steel.amount=5e6,t.resource.Aluminium.max=5e6,t.resource.Aluminium.amount=5e6,t.resource.Cement.max=5e6,t.resource.Cement.amount=5e6,t.resource.Titanium.max=5e6,t.resource.Titanium.amount=5e6,t.resource.Coal.max=5e6,t.resource.Coal.amount=5e6,t.resource.Alloy.max=5e6,t.resource.Alloy.amount=5e6,t.resource.Polymer.max=5e6,t.resource.Polymer.amount=5e6,t.resource.Iridium.max=5e6,t.resource.Iridium.amount=5e6,t.resource.Neutronium.max=5e5,t.resource.Neutronium.amount=5e5,t.resource.Adamantite.max=5e6,t.resource.Adamantite.amount=5e6,t.resource.Elerium.max=1e3,t.resource.Elerium.amount=1e3,t.resource.Nano_Tube.max=5e6,t.resource.Nano_Tube.amount=5e6,t.resource.Graphene.max=5e6,t.resource.Graphene.amount=5e6,t.resource.Stanene.max=5e6,t.resource.Stanene.amount=5e6,t.resource.Bolognium.max=5e6,t.resource.Bolognium.amount=5e6,t.resource.Orichalcum.max=5e6,t.resource.Orichalcum.amount=5e6,t.resource.Brick.amount=25e5,t.resource.Wrought_Iron.amount=25e5,t.resource.Sheet_Metal.amount=25e5,t.resource.Mythril.amount=25e5,t.resource.Quantium.amount=25e5,t.race.artifical||(t.resource.Food.crates=10,t.resource.Food.containers=10),t.resource.Stone.crates=25,t.resource.Stone.containers=25,t.resource.Furs.crates=25,t.resource.Furs.containers=25,t.resource.Coal.crates=10,t.resource.Coal.containers=10,t.resource.Copper.crates=25,t.resource.Copper.containers=25,t.resource.Iron.crates=25,t.resource.Iron.containers=25,t.resource.Aluminium.crates=25,t.resource.Aluminium.containers=25,t.resource.Steel.crates=25,t.resource.Steel.containers=25,t.resource.Titanium.crates=25,t.resource.Titanium.containers=25,t.resource.Alloy.crates=25,t.resource.Alloy.containers=25,t.resource.Polymer.crates=25,t.resource.Polymer.containers=25,t.resource.Iridium.crates=25,t.resource.Iridium.containers=25,t.resource.Adamantite.crates=25,t.resource.Adamantite.containers=25,t.resource.Graphene.crates=25,t.resource.Graphene.containers=25,t.resource.Stanene.crates=25,t.resource.Stanene.containers=25,t.resource.Bolognium.crates=25,t.resource.Bolognium.containers=25,t.resource.Orichalcum.crates=25,t.resource.Orichalcum.containers=25,t.civic.taxes.display=!0,t.race.flier||(t.civic.cement_worker.display=!0,t.resource.Cement.crates=25,t.resource.Cement.containers=25),t.race.sappy||(t.civic.quarry_worker.display=!0),t.civic.professor.display=!0,t.civic.scientist.display=!0,t.civic.banker.display=!0,t.civic.pit_miner.display=!0,t.civic.professor.max=1,t.civic.professor.workers=1,t.city.calendar.day++,t.city.market.active=!0,t.city.power=0,t.city.powered=!0,t.race.artifical&&(t.city.transmitter={count:0,on:0}),t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:0,cap:2,Wood:0,Coal:0,Oil:2,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:1,Iridium:0},t.city.amphitheatre={count:0},t.city.apartment={count:0,on:0},t.city.bank={count:0},t.city.basic_housing={count:0},t.city.biolab={count:0,on:0},t.city.boot_camp={count:0},t.city.casino={count:0,on:0},t.city.cement_plant={count:0,on:0},t.city.coal_mine={count:0,on:0},t.city.coal_power={count:0,on:0},t.city.cottage={count:0},t.city.fission_power={count:0,on:0},t.city.garrison={count:0,on:0},t.city.hospital={count:0},t.city.library={count:0},t.city.lumber_yard={count:0},t.city.mass_driver={count:0,on:0},t.city.metal_refinery={count:0,on:0},t.city.mine={count:0,on:0},t.city.oil_depot={count:0},t.city.oil_power={count:0,on:0},t.city.oil_well={count:0},t.city.rock_quarry={count:0,on:0,asbestos:50},t.city.sawmill={count:0,on:0},t.city.shed={count:0,on:0},t.city.storage_yard={count:0},t.city.temple={count:0},t.city.tourist_center={count:0,on:0},t.city.trade={count:0},t.city.university={count:0},t.city.wardenclyffe={count:0,on:0},t.city.warehouse={count:0},t.city.wharf={count:0},t.space.ai_colonist={count:0,on:0},t.space.ai_core={count:100},t.space.ai_core2={count:0,on:0},t.space.biodome={count:0,on:0},t.space.crashed_ship={count:100},t.space.decoder={count:0,on:0},t.space.digsite={count:0},t.space.drone={count:0},t.space.drone_control={count:0,on:0},t.space.e_reactor={count:0,on:0},t.space.electrolysis={count:0,on:0,support:0,s_max:0},t.space.elerium_contain={count:0,on:0},t.space.elerium_mine={count:0,on:0},t.space.elerium_ship={count:0,on:0},t.space.exotic_lab={count:0,on:0},t.space.fabrication={count:0,on:0},t.space.fob={count:0,on:0,troops:0,enemy:0},t.space.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},t.space.garage={count:0},t.space.gas_mining={count:0,on:0},t.space.gas_storage={count:0},t.space.geothermal={count:0,on:0},t.space.gps={count:0},t.space.helium_mine={count:0,on:0},t.space.hell_smelter={count:0,on:0},t.space.hydrogen_plant={count:0,on:0},t.space.iridium_mine={count:0,on:0},t.space.iridium_ship={count:0,on:0},t.space.iron_ship={count:0,on:0},t.space.lander={count:0,on:0},t.space.living_quarters={count:0,on:0},t.space.m_relay={count:0,on:0},t.space.mass_relay={count:100},t.space.moon_base={count:0,on:0,support:0,s_max:0},t.space.munitions_depot={count:0},t.space.nav_beacon={count:0,on:0},t.space.neutronium_mine={count:0,on:0},t.space.observatory={count:0,on:0},t.space.oil_extractor={count:0,on:0},t.space.operating_base={count:0,on:0},t.space.orichalcum_mine={count:0,on:0},t.space.outpost={count:0,on:0},t.space.propellant_depot={count:0},t.space.red_factory={count:0,on:0},t.space.red_mine={count:0,on:0},t.space.red_tower={count:0,on:0},t.space.satellite={count:0},t.space.shipyard={count:0,on:0,ships:[],expand:!1,sort:!0},t.space.shock_trooper={count:0,on:0},t.space.space_barracks={count:0,on:0},t.space.space_station={count:0,on:0,support:0,s_max:0},t.space.spaceport={count:0,on:0,support:0,s_max:0},t.space.spc_casino={count:0,on:0},t.space.storehouse={count:0},t.space.swarm_control={count:0,support:0,s_max:0},t.space.swarm_plant={count:0},t.space.swarm_satellite={count:0},t.space.tank={count:0,on:0},t.space.titan_bank={count:0},t.space.titan_mine={count:0,on:0},t.space.titan_quarters={count:0,on:0},t.space.titan_spaceport={count:0,on:0,support:0,s_max:0},t.space.uranium_mine={count:0,on:0},t.space.vr_center={count:0,on:0},t.space.water_freighter={count:0,on:0},t.space.zero_g_lab={count:0,on:0},t.space.ziggurat={count:0},t.tauceti.alien_outpost={count:1,on:1},t.tauceti.colony={count:1,on:1},t.tauceti.fusion_generator={count:1,on:1},t.tauceti.infectious_disease_lab={count:0,on:0,cure:0},t.tauceti.mining_pit={count:1,on:1},t.tauceti.orbital_platform={count:0,on:0,support:0,s_max:0},t.tauceti.orbital_station={count:1,on:1,support:0,s_max:0},t.tauceti.refueling_station={count:0,on:0},t.tauceti.repository={count:2},t.tauceti.tauceti_casino={count:0,on:0},t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:2,wounded:0,raid:0,max:2},t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!0,boost:!1,auto:!1,labs:0},t.tech.stock_exchange=0,t.tech.monuments=0,t.tech.supercollider=0,t.tech.tp_depot=0,t.tech.railway=0,t.tech.isolation=1,t.race.truepath=1,t.arpa.m_type=xe("Monument"),Qr(),Je(),xe("Physics"),sa()):t.race.artifical&&t.race.artifical&&(t.tech.spy=5,t.tech.primitive=3,t.tech.currency=6,t.tech.govern=3,t.tech.boot_camp=1,t.tech.medic=1,t.tech.military=5,t.tech.explosives=3,t.tech.trade=3,t.tech.banking=6,t.tech.home_safe=1,t.tech.housing=3,t.tech.smelting=3,t.tech.copper=1,t.tech.storage=5,t.tech.container=4,t.tech.steel_container=3,t.tech.mining=4,t.tech.pickaxe=2,t.tech.hammer=2,t.tech.oil=3,t.tech.alumina=1,t.tech.titanium=1,t.tech.foundry=7,t.tech.factory=1,t.tech.theatre=3,t.tech.broadcast=1,t.tech.science=7,t.tech.high_tech=4,t.tech.theology=2,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Food.display=!0,t.resource.Money.amount=1e3,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.race.flier||(t.tech.cement=5,t.resource.Cement.display=!0),t.race.kindling_kindred||t.race.smoldering||(t.race.evil?(t.tech.reclaimer=3,t.city.graveyard={count:1}):(t.tech.axe=3,t.tech.saw=2,t.city.lumber_yard={count:1},t.city.sawmill={count:0,on:0}),t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.civic.lumberjack.display=!0),t.race.smoldering&&(t.resource.Chrysotile.display=!0),t.resource[t.race.species].max=0,t.resource[t.race.species].amount=0,t.resource.Crates.amount=10,t.resource.Containers.amount=10,t.civic.taxes.display=!0,t.civic.miner.display=!0,t.civic.coal_miner.display=!0,t.civic.quarry_worker.display=!0,t.civic.professor.display=!0,t.civic.scientist.display=!0,t.race.flier||(t.civic.cement_worker.display=!0),t.civic.banker.display=!0,t.city.calendar.day++,t.city.market.active=!0,t.city.power=7.5,t.city.powered=!0,t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:1,cap:0,Wood:0,Coal:0,Oil:1,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:0,Iridium:0},t.city.oil_power={count:1,on:1},t.city.coal_power={count:0,on:0},t.city.transmitter={count:1,on:1},t.city.mine={count:1,on:0},t.city.coal_mine={count:1,on:0},t.city.oil_well={count:1},t.city.oil_depot={count:1},t.city.cement_plant={count:1,on:0},t.city.garrison={count:0,on:0},t.city.boot_camp={count:0},t.city.basic_housing={count:0},t.city.cottage={count:0},t.city.apartment={count:0,on:0},t.city.amphitheatre={count:0},t.city.rock_quarry={count:1,on:0,asbestos:50},t.city.metal_refinery={count:1,on:0},t.city.shed={count:2},t.city.storage_yard={count:1},t.city.warehouse={count:1},t.city.trade={count:0},t.city.wharf={count:0},t.city.bank={count:1},t.city.university={count:1},t.city.library={count:1},t.city.wardenclyffe={count:0,on:0},t.city.temple={count:0},t.race.calm&&(t.resource.Zen.display=!0,t.city.meditation={count:0}),t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0}),t.civic.govern.type="technocracy",t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:0,wounded:0,raid:0,max:0},Wr(),Qr(),sa()),t.settings.tabLoad?(Wr(),W(),he($("#c_garrison"),!1),te(),t.race.cataclysm||t.race.lone_survivor?(Ss($("#r_civics")),V(),ki(),Ea("market"),Ea("storage"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color,r=a.resource[e].tradable;if(a.resource[e].stackable){var i=$(`
                `);$("#resStorage").append(i),er(`#stack-${e}`,i,e,t)}r&&(i=$(`
                `),$("#market").append(i),Va(`#market-${e}`,i,e,t,!0))})),Ba(),xe("Genetics"),xe("Crispr"),xe("Blood")):t.sim&&(xe("Crispr"),xe("Blood"))):kt("mTabCivil"),t.queue.hasOwnProperty("queue")&&(t.queue.queue=[]),(t.race.slow||t.race.hyper||"junker"===t.race.species)&&(e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w&&P.w.terminate(),window.location.reload())}function mi(e){switch(Ki[e].fanaticism){case"smart":t.race.dumb?(Gi(5),xe("Genetics")):gi("smart");break;case"infectious":gi("infectious"),"human"===t.race.species&&qn("infested");break;case"blood_thirst":gi("blood_thirst"),"entish"===t.race.species&&qn("madagascar_tree");break;case"none":Gi(5),xe("Genetics");break;default:gi(Ki[e].fanaticism)}}function gi(e){t.race[e]?es(e)?"imitation"===e?Xi(!0):"shapeshifter"===e&&Yi(t.race.ss_genus):(Gi(5),xe("Genetics")):(t.race[e]=1,Ji(e))}function vi(){if(!t.settings.tabLoad&&3!==t.settings.civTabs)return;fi(),Ss($("#resQueue")),$("#resQueue").append($(`\n

                ${z("research_queue")} ({{ queue.length }}/{{ max }})

                \n \n `));let e=$('
                  ');$("#resQueue").append(e),e.append($('
                • {{ item.label }} [{{ item.time | time }}]
                • '));try{Cs({el:"#resQueue",data:t.r_queue,methods:{remove(e){_s(`rq${t.r_queue.queue[e].id}`),t.r_queue.queue.splice(e,1),vi(),Qr()},setID:e=>`rq${t.r_queue.queue[e].id}`,pauseRQueue(){$("#pauserqueue").removeClass("play"),$("#pauserqueue").removeClass("pause"),t.r_queue.pause?(t.r_queue.pause=!1,$("#pauserqueue").addClass("play")):(t.r_queue.pause=!0,$("#pauserqueue").addClass("pause"))},pausedesc:()=>t.r_queue.pause?z("r_queue_play"):z("r_queue_pause")},filters:{time:e=>zs(e)}}),function(){let e=$("#resQueue .buildList")[0];Sortable.create(e,{onEnd(e){let a=t.r_queue.queue;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.r_queue.queue=a,vi()}}),function(){for(let e=0;e=5?e-.01:e}function bi(){let e=1800;t.tech.vault>=1?e=7500*(t.tech.vault+1):t.tech.banking>=5?e=9e3:t.tech.banking>=3&&(e=4e3),t.race.paranoid&&(e*=1-Ei.paranoid.vars()[0]/100),t.race.hoarder&&(e*=1+Ei.hoarder.vars()[0]/100);let a=ts("dracnid");a>0&&(e*=1+Ei.hoarder.vars(1)[0]/100*a),t.tech.banking>=7&&(e*=1+ke(.05*ea(t.civic.banker.workers,"banker"))),t.tech.banking>=8&&(e+=ke(25*t.resource[t.race.species].amount)),t.tech.stock_exchange&&(e*=1+.1*t.tech.stock_exchange),t.tech.world_control&&(e*=1.25),t.race.truepath&&(e*=1.25),t.blood.greed&&(e*=1+t.blood.greed/100),t.stats.achieve.wheelbarrow&&(e*=1+t.stats.achieve.wheelbarrow.l/50),t.race.inflation&&(e*=1+t.race.inflation/125);let r=K("risktaker",0);return r&&(e*=1+r/100),e}function wi(e,a,r){switch(e){case"smelter":!function(e,a){let r=$(`
                  ${z("modal_smelter_fuel")}: {{s.count | on}}/{{ s.cap }}
                  `);if(e.append(r),e.hasClass("modalBody")){let e=Qs(10);e.length>0&&r.prepend(e)}if(a&&t.race.forge&&t.race.steelen){let e=Js(3,12,!0);e.length>0&&r.prepend(e)}let i=e.hasClass("modalBody")?"mSmelterFuels":"smelterFuels",s=$(`
                  `);if(e.append(s),!t.race.forge){if(!t.race.kindling_kindred&&!t.race.smoldering||t.race.evil){let e=t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?t.resource.Food.name:t.resource.Furs.name:t.resource.Lumber.name,a=$(`${e} {{ s.Wood }}`),r=$('«'),i=$('»');s.append(r),s.append(a),s.append(i)}if(t.resource.Coal.display){let e=$(`${t.resource.Coal.name} `),a=$('«'),r=$('»');s.append(a),s.append(e),s.append(r)}}if(t.race.forge){let e=$(`${z("trait_forge_name")} {{ s.Oil }}`);s.append(e)}else if(t.resource.Oil.display){let e=$(`${t.resource.Oil.name} {{ s.Oil }}`),a=$('«'),r=$('»');s.append(a),s.append(e),s.append(r)}if(t.tech.star_forge&&t.tech.star_forge>=2){let e=$(`${z("star")} {{ s.Star }}`);s.append(e)}if(t.tech.smelting&&t.tech.smelting>=8){let e=$(`${z("modal_smelter_inferno")} {{ s.Inferno }}`),t=$('«'),a=$('»');s.append(t),s.append(e),s.append(a)}let n=$('
                  ');e.append(n);let c=!!(t.tech.irid_smelting||t.tech.m_smelting&&t.tech.m_smelting>=2);if(t.resource.Iridium.display&&c||t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen){let a=$(`
                  `);e.append(a),a.append(`
                  ${z("modal_smelter_type")}: {{s.count | son}}/{{ s.cap | on }}
                  `);let r=$('
                  ');a.append(r);let i=$(`${t.resource.Iron.name} {{ s.Iron }}`),s=$('«'),n=$('»');if(r.append(s),r.append(i),r.append(n),t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen){let e=$(`${t.resource.Steel.name} {{ s.Steel }}`),a=$('«'),i=$('»');r.append(a),r.append(e),r.append(i)}if(t.resource.Iridium.display&&c){let e=$(`${t.resource.Iridium.name} {{ s.Iridium }}`),a=$('«'),i=$('»');r.append(a),r.append(e),r.append(i)}}function o(e){switch(e){case"wood":return z("modal_build_wood",[t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?t.resource.Food.name:t.resource.Furs.name:t.resource.Lumber.name,t.race.evil&&!t.race.soul_eater||"wendigo"===t.race.species?1:3]);case"coal":{let e=t.race.kindling_kindred?.15:.25;return t.tech.uranium&&t.tech.uranium>=3?z("modal_build_coal2",[e,z("resource_Coal_name"),z("resource_Uranium_name")]):z("modal_build_coal1",[e,z("resource_Coal_name")])}case"oil":return t.race.forge?z("modal_build_forge"):z("modal_build_oil",["0.35",z("resource_Oil_name")]);case"star":return t.tech.irid_smelting?z("modal_build_star2",[z("resource_Titanium_name"),z("resource_Iridium_name")]):z("modal_build_star",[z("resource_Titanium_name")]);case"inferno":{let e=35,t=.5;return z("modal_build_inferno",[50,z("resource_Coal_name"),e,z("resource_Oil_name"),t,z("resource_Infernite_name")])}}}function l(e){if("steel"===e){let e=t.tech.smelting>=4?1.2:1;return t.tech.smelting>=5&&(e*=1.2),t.tech.smelting>=6&&(e*=1.2),t.tech.smelting>=7&&(e*=1.25),t.race.pyrophobia&&(e*=.9),z("modal_smelter_steel",[+e.toFixed(3),z("resource_Steel_name"),z("resource_Coal_name"),z("resource_Iron_name")])}if("iridium"===e){let e=t.tech.smelting>=7?6.25:5;return t.race.pyrophobia&&(e*=.9),z("modal_smelter_iron",[+e.toFixed(3),z("resource_Iridium_name")])}{let e=t.tech.smelting>=3?t.tech.smelting>=7?15:12:10;return t.race.pyrophobia&&(e*=.9),z("modal_smelter_iron",[+e.toFixed(3),z("resource_Iron_name")])}}Cs({el:a||"#specialModal",data:{s:t.city.smelter,lum:t.resource.Lumber,coal:t.resource.Coal,oil:t.resource.Oil,food:t.resource.Food,fur:t.resource.Furs},methods:{addFuel(e){let a=y();for(let r=0;r=t.city.smelter.StarCap)break;if(a0))break;"Wood"!==e&&t.city.smelter.Wood>0?(t.city.smelter.Wood--,t.city.smelter[e]++):"Coal"!==e&&t.city.smelter.Coal>0?(t.city.smelter.Coal--,t.city.smelter[e]++):"Oil"!==e&&t.city.smelter.Oil>0?(t.city.smelter.Oil--,t.city.smelter[e]++):"Inferno"!==e&&t.city.smelter.Inferno>0&&(t.city.smelter.Inferno--,t.city.smelter[e]++)}}},subFuel(e){let a=y();for(let r=0;r0;r++){t.city.smelter[e]--,t.race.forge&&"Inferno"===e&&t.city.smelter.Oil++;let a=t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno;t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium>a&&(t.city.smelter.Iron>0?t.city.smelter.Iron--:t.city.smelter.Steel>0?t.city.smelter.Steel--:t.city.smelter.Iridium>0&&t.city.smelter.Iridium--)}},mLabel:e=>l(e),addMetal(e){let a=y();for(let r=0;r0&&"Iron"!==e)t.city.smelter.Iron--,t.city.smelter[e]++;else if(t.city.smelter.Steel>0&&"Steel"!==e)t.city.smelter.Steel--,t.city.smelter[e]++;else{if(!(t.city.smelter.Iridium>0&&"Iridium"!==e))break;t.city.smelter.Iridium--,t.city.smelter[e]++}}},subMetal(e){let a=y();t.city.smelter[e]-=a,t.city.smelter[e]<0&&(t.city.smelter[e]=0)},buildLabel:e=>o(e),ariaCount:e=>` ${t.city.smelter[e]} ${e} fueled.`,ariaProd:e=>`. ${t.city.smelter[e]} producing ${e}.`,net:e=>t.resource[e].diff>=0?"has-text-success":"has-text-danger",level:()=>ji(t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,t.city.smelter.count)},filters:{on:e=>t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,son:e=>t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium,diffSize:e=>e>0?`+${x(e,2)}`:x(e,2),spook(e){if(a&&((t.race.kindling_kindred||t.race.smoldering)&&(6===t.city.smelter.Steel||6===t.city.smelter.Iron)||6===t.city.smelter.Wood)&&6===t.city.smelter.Coal&&6===t.city.smelter.Oil){let e=Js(3,12,!0);if(e.length>0)return e}return e},altspook(e){if(a&&t.race.forge&&6===t.city.smelter.Steel){let e=Js(3,12,!0);if(e.length>0)return e}return e}}});let _=e.hasClass("modalBody")?"mSmelterFuels":"smelterFuels";if(["wood","coal","oil","star","inferno"].forEach((function(e){ls(`${_}${e}`,(function(){return o(e)}),{elm:$(`#${_} > .${e}`),attach:"#main"})})),t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen||t.resource.Iridium.display&&c){let a=e.hasClass("modalBody")?"mSmelterMats":"smelterMats";["iron","steel","iridium"].forEach((function(e){("steel"!==e||t.resource.Steel.display&&!t.race.steelen)&&("iridium"!==e||t.resource.Iridium.display&&c)&&ls(`${a}${e}`,(function(){return l(e)}),{elm:$(`#${a} span.${e}`),attach:"#main"})}))}}(a,r);break;case"factory":!function(e,a){let r=$(`
                  ${z("modal_factory_operate")}: {{count | on}}/{{ on | max }}
                  `);e.append(r);let i=$(`
                  ${z("modal_factory_lux")}
                  `);e.append(i);let c=$(''),o=$('«'),l=$('»');if(i.append(o),i.append(c),i.append(l),t.tech.synthetic_fur){let a=$(`
                  ${t.race.evil?z("resource_Flesh_name"):z("resource_Furs_name")}
                  `);e.append(a);let r=$('{{ Furs }}'),i=$('«'),s=$('»');a.append(i),a.append(r),a.append(s)}let _=$(`
                  ${z("resource_Alloy_name")}
                  `);e.append(_);let d=$('{{ Alloy }}'),p=$('«'),u=$('»');if(_.append(p),_.append(d),_.append(u),t.tech.polymer){let t=$(`
                  ${z("resource_Polymer_name")}
                  `);e.append(t);let a=$('{{ Polymer }}'),r=$('«'),i=$('»');t.append(r),t.append(a),t.append(i)}if(t.tech.nano){let t=$(`
                  ${z("resource_Nano_Tube_name")}
                  `);e.append(t);let a=$('{{ Nano }}'),r=$('«'),i=$('»');t.append(r),t.append(a),t.append(i)}if(t.tech.stanene){let t=$(`
                  ${z("resource_Stanene_name")}
                  `);e.append(t);let a=$('{{ Stanene }}'),r=$('«'),i=$('»');t.append(r),t.append(a),t.append(i)}function h(e){let a=!!t.tech.factory;switch(e){case"Lux":{let e=+t.resource[t.race.species].amount*(a?$i.Lux.demand[t.tech.factory]:$i.Lux.demand[0]);return e=function(e){t.race.toxic&&(e*=1+Ei.toxic.vars()[0]/100);let a=ts("shroomi");return a>0&&(e*=1+Ei.toxic.vars(1)[0]/100*a),"corpocracy"===t.civic.govern.type&&(e*=2.5),"socialist"===t.civic.govern.type&&(e*=.8),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(e*=1.1),t.race.inflation&&(e*=1+t.race.inflation/1250),t.tech.isolation&&(e*=1+.5*(n.colony||0)),e*=$e("psychic_cash")}(e).toFixed(2),z("modal_factory_lux_label",[a?$i.Lux.fur[t.tech.factory]:$i.Lux.fur[0],t.resource.Furs.name,e])}case"Furs":{let e=a?$i.Furs.money[t.tech.factory]:$i.Furs.money[0],r=a?$i.Furs.polymer[t.tech.factory]:$i.Furs.polymer[0];return z("modal_factory_alloy_label",[e,z("resource_Money_name"),r,z("resource_Polymer_name"),t.race.evil?z("resource_Flesh_name"):z("resource_Furs_name")])}case"Alloy":{let e=a?$i.Alloy.copper[t.tech.factory]:$i.Alloy.copper[0],r=a?$i.Alloy.aluminium[t.tech.factory]:$i.Alloy.aluminium[0];return z("modal_factory_alloy_label",[e,z("resource_Copper_name"),r,z("resource_Aluminium_name"),z("resource_Alloy_name")])}case"Polymer":if(t.race.kindling_kindred||t.race.smoldering)return z("modal_factory_polymer_label2",[a?$i.Polymer.oil_kk[t.tech.factory]:$i.Polymer.oil_kk[0],z("resource_Oil_name"),z("resource_Polymer_name")]);{let e=a?$i.Polymer.oil[t.tech.factory]:$i.Polymer.oil[0],r=a?$i.Polymer.lumber[t.tech.factory]:$i.Polymer.lumber[0];return z("modal_factory_polymer_label1",[e,z("resource_Oil_name"),r,t.resource.Lumber.name,z("resource_Polymer_name")])}case"Nano":{let e=a?$i.Nano_Tube.coal[t.tech.factory]:$i.Nano_Tube.coal[0],r=a?$i.Nano_Tube.neutronium[t.tech.factory]:$i.Nano_Tube.neutronium[0];return z("modal_factory_nano_label",[e,z("resource_Coal_name"),r,z("resource_Neutronium_name"),z("resource_Nano_Tube_name")])}case"Stanene":{let e=a?$i.Stanene.aluminium[t.tech.factory]:$i.Stanene.aluminium[0],r=a?$i.Stanene.nano[t.tech.factory]:$i.Stanene.nano[0];return z("modal_factory_stanene_label",[e,z("resource_Aluminium_name"),r,z("resource_Nano_Tube_name"),z("resource_Stanene_name")])}}}Cs({el:a||"#specialModal",data:t.city.factory,methods:{subItem:function(e){let a=y();for(var r=0;r0;r++)t.city.factory[e]--},addItem:function(e){let a=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;t.interstellar.int_factory&&s.int_factory&&(a+=2*s.int_factory),t.tauceti.tau_factory&&n.tau_factory&&(a+=n.tau_factory*(t.tech.isolation?5:3));let r=y();for(var i=0;i0))break;t.city.factory.Alloy--,t.city.factory[e]++}}},buildLabel:function(e){return h(e)},ariaProd:e=>`. ${t.city.factory[e]} factories producing ${e}.`,level(){let e=t.city.factory.Lux+t.city.factory.Furs+t.city.factory.Alloy+t.city.factory.Polymer+t.city.factory.Nano+t.city.factory.Stanene,a=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;return t.interstellar.int_factory&&s.int_factory&&(a+=2*s.int_factory),t.tauceti.tau_factory&&n.tau_factory&&(a+=n.tau_factory*(t.tech.isolation?5:3)),ji(e,a)}},filters:{on:()=>t.city.factory.Lux+t.city.factory.Furs+t.city.factory.Alloy+t.city.factory.Polymer+t.city.factory.Nano+t.city.factory.Stanene,max(){let e=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;return t.interstellar.int_factory&&s.int_factory&&(e+=2*s.int_factory),t.tauceti.tau_factory&&n.tau_factory&&(e+=n.tau_factory*(t.tech.isolation?5:3)),e},spook(e){if(3===t.city.factory.Lux&&a){let e=Js(6,12,!0);if(e.length>0)return e}return e}}}),["Lux","Furs","Alloy","Polymer","Nano","Stanene"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iFactory";ls(`${a}${t}`,(function(){return h(t)}),{elm:$(`#${a} .factory > .${t}`),attach:"#main"})}))}(a,r);break;case"droid":!function(e,a){let r=$(`
                  ${z("modal_factory_operate")}: {{count | on}}/{{ on | max }}
                  `);e.append(r);let i=$(`
                  ${z("resource_Adamantite_name")}
                  `);e.append(i);let s=$('{{ adam }}'),n=$('«'),c=$('»');i.append(n),i.append(s),i.append(c);let o=$(`
                  ${z("resource_Uranium_name")}
                  `);e.append(o);let l=$('{{ uran }}'),_=$('«'),d=$('»');o.append(_),o.append(l),o.append(d);let p=$(`
                  ${z("resource_Coal_name")}
                  `);e.append(p);let u=$('{{ coal }}'),h=$('«'),m=$('»');p.append(h),p.append(u),p.append(m);let g=$(`
                  ${z("resource_Aluminium_name")}
                  `);e.append(g);let v=$('{{ alum }}'),f=$('«'),b=$('»');function w(e){switch(e){case"adam":return z("modal_droid_res_label",[z("resource_Adamantite_name")]);case"uran":return z("modal_droid_res_label",[z("resource_Uranium_name")]);case"coal":return z("modal_droid_res_label",[z("resource_Coal_name")]);case"alum":return z("modal_droid_res_label",[z("resource_Aluminium_name")])}}g.append(f),g.append(v),g.append(b),Cs({el:a||"#specialModal",data:t.interstellar.mining_droid,methods:{subItem:function(e){let a=y();for(var r=0;r0;r++)t.interstellar.mining_droid[e]--},addItem:function(e){let a=y();for(var r=0;r`. ${t.interstellar.mining_droid[e]} driod mining ${e}.`,level:()=>ji(t.interstellar.mining_droid.adam+t.interstellar.mining_droid.uran+t.interstellar.mining_droid.coal+t.interstellar.mining_droid.alum,t.interstellar.mining_droid.on)},filters:{on:()=>t.interstellar.mining_droid.adam+t.interstellar.mining_droid.uran+t.interstellar.mining_droid.coal+t.interstellar.mining_droid.alum,max:()=>t.interstellar.mining_droid.on}}),["adam","uran","coal","alum"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iDroid";ls(`${a}${t}`,(function(){return w(t)}),{elm:$(`#${a} .factory > .${t}`),attach:"#main"})}))}(a,r);break;case"graphene":!function(e,a){let r=t.race.truepath?"space":"interstellar",i=$(`
                  ${z("modal_smelter_fuel")}: {{count | on}}/{{ on | max }}
                  `);e.append(i);let s=$("
                  ");if(e.append(s),!t.race.kindling_kindred&&!t.race.smoldering){let e=t.resource.Lumber.name,a=$(`${e} {{ Lumber }}`),r=$('«'),i=$('»');s.append(r),s.append(a),s.append(i)}if(t.resource.Coal.display){let e=$(`${t.resource.Coal.name} {{ Coal }}`),a=$('«'),r=$('»');s.append(a),s.append(e),s.append(r)}if(t.resource.Oil.display){let e=$(`${t.resource.Oil.name} {{ Oil }}`),a=$('«'),r=$('»');s.append(a),s.append(e),s.append(r)}function n(e){switch(e){case"wood":return z("modal_graphene_produce",[350,t.race.evil?z("resource_Bones_name"):z("resource_Lumber_name"),z("resource_Graphene_name")]);case"coal":return z("modal_graphene_produce",[25,z("resource_Coal_name"),z("resource_Graphene_name")]);case"oil":return z("modal_graphene_produce",[15,z("resource_Oil_name"),z("resource_Graphene_name")])}}Cs({el:a||"#specialModal",data:t[r].g_factory,methods:{subWood(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Lumber--},addWood(){let e=y();for(let a=0;a0))break;t[r].g_factory.Oil>t[r].g_factory.Coal?t[r].g_factory.Coal>0?t[r].g_factory.Coal--:t[r].g_factory.Oil--:t[r].g_factory.Oil>0?t[r].g_factory.Oil--:t[r].g_factory.Coal--,t[r].g_factory.Lumber++}},subCoal(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Coal--},addCoal(){let e=y();for(let a=0;a0))break;t[r].g_factory.Lumber>0?t[r].g_factory.Lumber--:t[r].g_factory.Oil--,t[r].g_factory.Coal++}},subOil(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Oil--},addOil(){let e=y();for(let a=0;a0))break;t[r].g_factory.Lumber>0?t[r].g_factory.Lumber--:t[r].g_factory.Coal--,t[r].g_factory.Oil++}},buildLabel:e=>n(e),ariaCount:e=>` ${t[r].g_factory[e]} ${e} fueled.`,ariaProd:e=>`. ${t[r].g_factory[e]} producing ${e}.`,level:()=>ji(t[r].g_factory.Lumber+t[r].g_factory.Coal+t[r].g_factory.Oil,t[r].g_factory.on)},filters:{on:function(e){return t[r].g_factory.Lumber+t[r].g_factory.Coal+t[r].g_factory.Oil}}}),["wood","coal","oil"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iGraphene";ls(`${a}${t}`,(function(){return n(t)}),{elm:$(`#${a} > div > .${t}`),attach:"#main"})}))}(a,r);break;case"pylon":!function(e,a){let r=$(`
                  ${z("modal_pylon_casting")}: {{total | drain}}
                  `);e.append(r);let i=$('
                  ');e.append(i);let s=[];function n(e){let a=+Pi(t.race.casting[e]).toFixed(4),r=+(Pi(t.race.casting[e]+1)-Pi(t.race.casting[e])).toFixed(4),i=+(t.race.casting[e]/(t.race.casting[e]+75)*100).toFixed(2);return"crafting"===e?z("modal_pylon_casting_label_crafting",[a,i,+(2*t.race.casting[e]/(2*t.race.casting[e]+75)*100).toFixed(2),r]):z("modal_pylon_casting_label",[z(`modal_pylon_spell_${e}`),a,r,i])}s=t.race.orbit_decayed?["miner","science","factory","army","hunting","crafting"]:t.race.cataclysm?["science","factory","army","hunting","crafting"]:t.race.unfathomable?["miner","lumberjack","science","factory","army","hunting","crafting"]:["farmer","miner","lumberjack","science","factory","army","hunting","crafting"],t.tech.magic&&t.tech.magic>=3&&s.forEach((function(e){if("crafting"!==e&&"lumberjack"!==e&&"farmer"!==e||"farmer"===e&&!t.race.detritivore&&!t.race.carnivore&&!t.race.soul_eater&&!t.race.artifical||"lumberjack"===e&&!t.race.kindling_kindred&&!t.race.smoldering&&!t.race.evil||"crafting"===e&&t.tech.magic>=4){let t=$(`${z(`modal_pylon_spell_${e}`)} {{ ${e} }}`),a=$(`«`),r=$(`»`);i.append(a),i.append(t),i.append(r)}})),Cs({el:a||"#specialModal",data:t.race.casting,methods:{buildLabel:e=>n(e),addSpell(e){let a=y();for(let r=0;r=a))break;t.race.casting[e]++,t.race.casting.total++,t.resource.Mana.diff-=a}},subSpell(e){let a=y();for(let r=0;r0;r++)t.race.casting[e]--,t.race.casting.total--},ariaCount:e=>` ${e} casting.`,level:()=>ji(t.race.casting.total,t.resource.Mana.gen,!0)},filters:{drain:function(e){let a=0;return s.forEach((function(e){t.race.casting[e]&&t.race.casting[e]>0&&(a+=Pi(t.race.casting[e]))})),z("modal_pylon_casting_cost",[+a.toFixed(3)])}}}),s.forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iPylon";ls(`${a}${t}`,(function(){return n(t)}),{elm:$(`#${a} > .pylon > .${t}`),attach:"#main"})}))}(a,r);break;case"rock_quarry":!function(e,a){e.append($(`
                  ${z("modal_quarry_ratio",[t.resource.Chrysotile.name])}
                  `));let r=$('
                  «»
                  ');e.append(r),Cs({el:a||"#specialModal",data:t.city.rock_quarry,methods:{sub(){let e=y();t.city.rock_quarry.asbestos>0&&(t.city.rock_quarry.asbestos-=e,t.city.rock_quarry.asbestos<0&&(t.city.rock_quarry.asbestos=0))},add(){let e=y();t.city.rock_quarry.asbestos<100&&(t.city.rock_quarry.asbestos+=e,t.city.rock_quarry.asbestos>100&&(t.city.rock_quarry.asbestos=100))}}})}(a,r);break;case"titan_mine":!function(e,a){e.append($(`
                  ${z("modal_quarry_ratio",[t.resource.Adamantite.name])}
                  `));let r=$('
                  «»
                  ');e.append(r),Cs({el:a||"#specialModal",data:t.space.titan_mine,methods:{sub(){let e=y();t.space.titan_mine.ratio>0&&(t.space.titan_mine.ratio-=e,t.space.titan_mine.ratio<0&&(t.space.titan_mine.ratio=0))},add(){let e=y();t.space.titan_mine.ratio<100&&(t.space.titan_mine.ratio+=e,t.space.titan_mine.ratio>100&&(t.space.titan_mine.ratio=100))}}})}(a,r);break;case"nanite_factory":!function(e,a){let r=$(`
                  ${z("modal_factory_operate")}: {{count | on}}/{{ count | max }}
                  `);e.append(r);let i=e.hasClass("modalBody")?"mNFactoryRes":"NFactoryRes",s=$(`
                  `);e.append(s),xi.forEach((function(e){if(t.resource[e].display){let a=$(`${t.resource[e].name} {{ ${e} }}`),r=$(`«`),i=$(`»`);s.append(r),s.append(a),s.append(i)}})),Cs({el:a||"#specialModal",data:t.city.nanite_factory,methods:{subItem:function(e){let a=y();t.city.nanite_factory[e]-=a,t.city.nanite_factory[e]<0&&(t.city.nanite_factory[e]=0)},addItem:function(e){let a=y(),r=0;xi.forEach((function(e){r+=t.city.nanite_factory[e]}));let i=50*t.city.nanite_factory.count-r;a>i&&(a=i),a>0&&(t.city.nanite_factory[e]+=a)},eatLabel:e=>`Consume ${e} to produce ${t.resource.Nanite.name}`,level(){let e=0;xi.forEach((function(a){e+=t.city.nanite_factory[a]}));let a=t.city.nanite_factory.count;return ji(e,a)}},filters:{on(){let e=0;return xi.forEach((function(a){e+=t.city.nanite_factory[a]})),e},max:()=>50*t.city.nanite_factory.count}}),xi.forEach((function(a){let r=e.hasClass("modalBody")?"specialModal":"iNFactory";ls(`${r}${a}`,(function(){return function(e){let a=+(Fa[e]/100*(Ei.deconstructor.vars()[0]/100)).toFixed(4),r=+(t.city.nanite_factory[e]*a).toFixed(4);return z("modal_nfactory_resource_label",[1,t.resource[e].name,a,t.resource.Nanite.name,t.city.nanite_factory[e],r])}(a)}),{elm:$(`#${r} > .fuels > .${a}`),attach:"#main"})}))}(a,r);break;case"mining_ship":!function(e,a){e.append($(`
                  ${z("tau_roid_mining_ship_ratio",[t.resource.Iron.name,t.resource.Aluminium.name])}
                  `));let r=$('
                  «»
                  ');e.append(r),e.append($(`
                  ${z("tau_roid_mining_ship_ratio",[t.resource.Iridium.name,t.resource.Neutronium.name])}
                  `));let i=$('
                  «»
                  ');if(e.append(i),t.tech.tau_roid>=5){e.append($(`
                  ${z("tau_roid_mining_ship_ratio",[t.resource.Orichalcum.name,t.resource.Elerium.name])}
                  `));let a=$('
                  «»
                  ');e.append(a)}Cs({el:a||"#specialModal",data:t.tauceti.mining_ship,methods:{sub(e){let a=y();t.tauceti.mining_ship[e]>0&&(t.tauceti.mining_ship[e]-=a,t.tauceti.mining_ship[e]<0&&(t.tauceti.mining_ship[e]=0))},add(e){let a=y();t.tauceti.mining_ship[e]<100&&(t.tauceti.mining_ship[e]+=a,t.tauceti.mining_ship[e]>100&&(t.tauceti.mining_ship[e]=100))}}})}(a,r);break;case"alien_space_station":!function(e,a){e.append($(`
                  ${z("tau_gas2_alien_station_focus",[t.resource.Knowledge.name])}
                  `));let r=$('
                  «»
                  ');e.append(r),Cs({el:a||"#specialModal",data:t.tauceti.alien_space_station,methods:{sub(e){let a=y();t.tauceti.alien_space_station[e]>0&&(t.tauceti.alien_space_station[e]-=a,t.tauceti.alien_space_station[e]<0&&(t.tauceti.alien_space_station[e]=0))},add(e){let a=y();t.tauceti.alien_space_station[e]<100&&(t.tauceti.alien_space_station[e]+=a,t.tauceti.alien_space_station[e]>100&&(t.tauceti.alien_space_station[e]=100))}}})}(a,r);break;case"replicator":!function(e,a){if(t.race.replicator){e.append($(`
                  ${"antimatter"===t.race.universe?z("tech_antireplicator"):z("tech_replicator")}
                  `));let r=$('
                  ');if(e.append(r),a){let e="";Object.keys(Fa).forEach((function(a){e+=`${t.resource[a].name}`})),r.append(`
                  \n ${e}\n
                  `)}else{let e="";Object.keys(Fa).forEach((function(a){t.resource[a].display&&(e+=`${t.resource[a].name}`)})),r.append(`
                  ${e}
                  `)}let i=a?$("
                  "):$('
                  ');r.append(i);let s=$('{{ pow }}MW'),n=$('«'),c=$('»');if(i.append(n),i.append(s),i.append(c),e.append('
                  {{ res | result }}
                  '),Cs({el:a||"#specialModal",data:t.race.replicator,methods:{less(){let e=y();t.race.replicator.pow>0&&(t.race.replicator.pow-=e,t.race.replicator.pow<0&&(t.race.replicator.pow=0))},more(){let e=y();t.race.replicator.pow+=e},setVal(e){t.resource[e].display&&(t.race.replicator.res=e)},avail:e=>t.resource[e].display,aria:()=>t.race.replicator.pow+"MW"},filters:{resName:e=>t.resource[e].name,result:e=>z("tau_replicator",[qi(e,t.race.replicator.pow).toFixed(3),t.resource[e].name])}}),!a){const e=document.getElementById("hscrolltarget");e.addEventListener("wheel",(t=>{t.preventDefault(),e.scrollLeft+=t.deltaY}))}}}(a,r)}}function ki(){if(t.settings.tabLoad||2===t.settings.civTabs&&1===t.settings.govTabs){if(Ss($("#industry")),t.city.smelter&&(t.city.smelter.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation)){var e=$(`

                  ${z("city_smelter")}

                  `);$("#industry").append(e),wi("smelter",e,"#iSmelter")}if(t.city.factory&&t.city.factory.count>0||t.space.red_factory&&t.space.red_factory.count>0||t.tauceti.tau_factory&&t.tauceti.tau_factory.count>0){var a=$(`

                  ${z("city_factory")}

                  `);$("#industry").append(a),wi("factory",a,"#iFactory")}if(t.interstellar.mining_droid&&t.interstellar.mining_droid.count>0){var r=$(`

                  ${z("interstellar_mining_droid_title")}

                  `);$("#industry").append(r),wi("droid",r,"#iDroid")}if(t.interstellar.g_factory&&t.interstellar.g_factory.count>0||t.space.g_factory&&(t.space.g_factory.count>0||t.tauceti.refueling_station&&t.tauceti.refueling_station.count>0)){var i=$(`

                  ${z("interstellar_g_factory_title")}

                  `);$("#industry").append(i),wi("graphene",i,"#iGraphene")}if(t.race.casting&&(t.city.pylon||t.space.pylon||t.tauceti.pylon)){var s=$(`

                  ${z("city_pylon")}

                  `);$("#industry").append(s),wi("pylon",s,"#iPylon")}if(t.race.smoldering&&t.city.rock_quarry&&!t.race.cataclysm&&!t.race.orbit_decayed&&!t.tech.isolation){var n=$(`

                  ${z("city_rock_quarry")}

                  `);$("#industry").append(n),wi("rock_quarry",n,"#iQuarry")}if(t.space.titan_mine&&t.space.titan_mine.count>0&&(n=$(`

                  ${z("city_mine")}

                  `),$("#industry").append(n),wi("titan_mine",n,"#iTMine")),t.tech.tau_roid&&t.tech.tau_roid>=4&&t.tauceti.mining_ship){var c=$(`

                  ${z("tau_roid_mining_ship")}

                  `);$("#industry").append(c),wi("mining_ship",c,"#iMiningShip")}if(t.tech.tau_gas2&&6===t.tech.tau_gas2&&t.tauceti.alien_space_station&&(!t.tech.alien_data||t.tech.alien_data<6)){var o=$(`

                  ${z("tau_gas2_alien_station")}

                  `);$("#industry").append(o),wi("alien_space_station",o,"#iAlienSpaceStation")}if(t.race.deconstructor&&t.city.nanite_factory){var l=$(`

                  ${z("city_nanite_factory")}

                  `);$("#industry").append(l),wi("nanite_factory",l,"#iNFactory")}if(t.race.replicator&&t.tech.replicator){var _=$(`

                  ${"antimatter"===t.race.universe?z("tech_antireplicator"):z("tech_replicator")}

                  `);$("#industry").append(_),wi("replicator",_,"#iReplicator")}}}Object.keys(Ir).forEach((e=>Mr.evolution[e]={id:`evolution-${e}`,title:z(`evo_challenge_${e}`),desc(){let a="";return"micro"===t.race.universe&&(a+=`
                  ${z("evo_challenge_micro_warn")}
                  `),a+=`
                  ${z(`evo_challenge_${e}_desc`)}
                  `,["sludge","junker"].includes(e)&&(a+=`
                  ${z("evo_start")}
                  `),a},condition:()=>t.evolution.hasOwnProperty(e),cost:{DNA:()=>"c"===Ir[e].t?25:50},challenge:!0,effect:()=>Lr(e),action(){return ri($(this)[0])&&("c"===Ir[e].t?function(e){t.race[e]?(delete t.race[e],$(`#evolution-${e}`).removeClass("hl"),"sludge"===e&&Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).removeClass("is-hidden")}))):(t.race[e]=1,$(`#evolution-${e}`).addClass("hl"),"sludge"===e&&(Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).addClass("is-hidden")})),t.race.junker&&delete t.race.junker),"orbit_decay"===e&&(delete t.race.cataclysm,t.race.lone_survivor&&(delete t.race.lone_survivor,["nerfed","badgenes"].forEach((function(e){delete t.race[Ar[e]]}))))),Sr(),On()}(e):function(e){if(t.race.sludge||Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).removeClass("is-hidden")})),t.race[e])delete t.race[e],$(`#evolution-${e}`).removeClass("hl"),["nerfed","badgenes"].forEach((function(e){delete t.race[Ar[e]]}));else{["junker","cataclysm","banana","truepath","lone_survivor"].forEach((function(e){delete t.race[e],$(`#evolution-${e}`).removeClass("hl")})),t.race[e]=1,$(`#evolution-${e}`).addClass("hl"),"junker"===e&&(Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).addClass("is-hidden")})),t.race.sludge&&delete t.race.sludge),"cataclysm"!==e&&"lone_survivor"!==e||delete t.race.orbit_decay,"truepath"===e||"lone_survivor"===e?(t.race.nerfed=1,["crispr","plasmid","mastery"].forEach((function(e){delete t.race[Ar[e]]}))):(["nerfed","badgenes"].forEach((function(e){delete t.race[Ar[e]]})),"antimatter"===t.race.universe?(t.race.weak_mastery=1,$("#evolution-mastery").hasClass("hl")||$("#evolution-mastery").addClass("hl")):(t.race.no_plasmid=1,$("#evolution-plasmid").hasClass("hl")||$("#evolution-plasmid").addClass("hl")));let a="truepath"===e||"lone_survivor"===e?["badgenes","trade","craft"]:["crispr","trade","craft"];for(let e=0;eXs(Ir[e].e),highlight:()=>!!t.race[e],queue_complete:()=>0})),Mr.evolution.bunker={id:"evolution-bunker",title:z("evo_bunker"),desc:()=>`
                  ${z("evo_bunker")}
                  ${z("evo_challenge")}
                  `,reqs:{evo:6},grant:["evo_challenge",1],condition:()=>t.genes.challenge&&100===t.evolution.final&&!t.race.evoFinalMenu,cost:{DNA:()=>10},effect:z("evo_bunker_effect"),action(){return!!ri($(this)[0])},queue_complete:()=>t.tech.evo_challenge?0:1,flair:z("evo_bunker_flair")};const $i={Lux:{demand:[.14,.21,.28,.35,.42],fur:[2,3,4,5,6]},Furs:{money:[10,15,20,25,30],polymer:[1.5,2.25,3,3.75,4.5],output:[1,1.5,2,2.5,3]},Alloy:{copper:[.75,1.12,1.49,1.86,2.23],aluminium:[1,1.5,2,2.5,3],output:[.075,.112,.149,.186,.223]},Polymer:{oil_kk:[.22,.33,.44,.55,.66],oil:[.18,.27,.36,.45,.54],lumber:[15,22,29,36,43],output:[.125,.187,.249,.311,.373]},Nano_Tube:{coal:[8,12,16,20,24],neutronium:[.05,.075,.1,.125,.15],output:[.2,.3,.4,.5,.6]},Stanene:{aluminium:[30,45,60,75,90],nano:[.02,.03,.04,.05,.06],output:[.6,.9,1.2,1.5,1.8]}},xi=["Lumber","Chrysotile","Stone","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal","Oil","Uranium","Steel","Titanium","Alloy","Polymer","Iridium","Helium_3","Water","Deuterium","Neutronium","Adamantite","Bolognium","Orichalcum"];function qi(e,a){return t.race.lone_survivor?17.5*_/Fa[e]*a:12.5*(_||1)/Fa[e]*a**.75}function Pi(e,t){return e*((1+(t=void 0===t?.0025:t))**e-1)}function ji(e,t,a){return e<=0?a?"has-text-success":"has-text-danger":e>=t?a?"has-text-danger":"has-text-success":e<=t/3?a?"has-text-info":"has-text-caution":e<=.66*t?"has-text-warning":e
                  ${z("power_grid_header")}
                  Distribute Low Power
                  `),Cs({el:"#powerModeSwitch",data:t.settings}),Object.keys(e).forEach((function(a){if(!e[a].s)return;let r="";"power"===a&&(r=Js(7,12,!1)),e[a].r&&e[a].rs&&t[e[a].r][e[a].rs]?($("#powerGrid").append(`
                  ${e[a].n} {{ support }}/{{ s_max }}
                  `),Cs({el:`#pg${a}sup`,data:t[e[a].r][e[a].rs]})):$("#powerGrid").append(`
                  ${e[a].n}${r}
                  `);let i=$(`
                  `);$("#powerGrid").append(i);let s=0;for(let r=0;r`);c.append(` ${_}${d}`),c.append('{{ on | off }} {{ on }}'),c.append('« »'),i.append(c),Cs({el:`#pg${l.id}${a}`,data:t[o][n[1]],methods:{power_on(){let e=y();for(let a=0;a0;a++)t[o][n[1]].on--;l.postPower&&setTimeout((function(){l.postPower(!1)}),250)},higher(){let t=$(`#pg${l.id}${a}`).attr("data-idx"),r=$(`#pg${l.id}${a}`).prevAll('.circuit:not(".inactive")').attr("data-idx");if(r>=0){let i=e[a].l;i.splice(r,0,i.splice(t,1)[0]),e[a].l=i,Mi()}},lower(){let t=$(`#pg${l.id}${a}`).attr("data-idx"),r=$(`#pg${l.id}${a}`).nextAll('.circuit:not(".inactive")').attr("data-idx");if(rt[o][n[1]].count-e,idx(e){let t=Qs(18,11);return 10===e&&t.length>0?"1"+t:e}}})}else{let e=$(`
                  `);e.append(`${_}${d}`),i.append(e)}}!function(e){let t=$(`#grid${e}`)[0],a=Si();Sortable.create(t,{onEnd(t){let r=a[e].l;r.splice(t.newDraggableIndex,0,r.splice(t.oldDraggableIndex,1)[0]),a[e].l=r,Mi()}})}(a);let n=$(`
                  `);$("#powerGrid").append(n),Cs({el:`#${a}GridReset`,data:{},methods:{resetGrid(e){us(e,!0),Mi()}}})}))}function Si(){return{power:{l:t.power,n:z("power"),s:!0,r:!1,rs:!1},moon:{l:t.support.moon,n:z("space_moon_info_name"),s:t.settings.space.moon,r:"space",rs:"moon_base"},red:{l:t.support.red,n:Ut().red,s:t.settings.space.red,r:"space",rs:"spaceport"},belt:{l:t.support.belt,n:z("space_belt_info_name"),s:t.settings.space.belt,r:"space",rs:"space_station"},alpha:{l:t.support.alpha,n:z("interstellar_alpha_name"),s:t.settings.space.alpha,r:"interstellar",rs:"starport"},nebula:{l:t.support.nebula,n:z("interstellar_nebula_name"),s:t.settings.space.nebula,r:"interstellar",rs:"nexus"},gateway:{l:t.support.gateway,n:z("galaxy_gateway"),s:t.settings.space.gateway,r:"galaxy",rs:"starbase"},alien2:{l:t.support.alien2,n:z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),s:t.settings.space.alien2,r:"galaxy",rs:"foothold"},lake:{l:t.support.lake,n:z("portal_lake_name"),s:t.settings.portal.lake,r:"portal",rs:"harbour"},spire:{l:t.support.spire,n:z("portal_spire_name"),s:t.settings.portal.spire,r:"portal",rs:"purifier"},titan:{l:t.support.titan,n:Ut().titan,s:t.settings.space.titan,r:"space",rs:"electrolysis"},enceladus:{l:t.support.enceladus,n:Ut().enceladus,s:t.settings.space.enceladus,r:"space",rs:"titan_spaceport"},eris:{l:t.support.eris,n:Ut().eris,s:t.settings.space.eris,r:"space",rs:"drone_control"},tau_home:{l:t.support.tau_home,n:z("tau_planet",[Ki[t.race.species].home]),s:t.settings.tau.home,r:"tauceti",rs:"orbital_station"},tau_red:{l:t.support.tau_red,n:z("tau_planet",[Ut().red]),s:t.settings.tau.red,r:"tauceti",rs:"orbital_platform"},tau_roid:{l:t.support.tau_roid,n:z("tau_roid_title"),s:t.settings.tau.roid,r:"tauceti",rs:"patrol_ship"}}}function Ci(e){e=e||Si(),Object.keys(e).forEach((function(e){let t=$(`#grid${e}`)[0];if(t){let e=Sortable.get(t);e&&e.destroy()}}))}const zi=new Date,Fi=on(),Ai=ln(),Ii=["diverse","arrogant","angry","lazy","paranoid","greedy","puny","dumb","nearsighted","gluttony","slow","hard_of_hearing","pessimistic","solitary","pyrophobia","skittish","nyctophilia","frail","atrophy","invertebrate","pathetic","invertebrate","unorganized","slow_regen","snowy","mistrustful","fragrant","freespirit","hooved","heavy","gnawer"];function Ti(e,a){if(t.settings.boring)return t.race.hrt&&delete t.race.hrt,!1;switch(e){case"elven":case"capybara":case"centaur":case"wendigo":case"entish":case"yeti":return!!(11===zi.getMonth()&&zi.getDate()>=17||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"wolven":case"vulpine":return!!(Fi.active||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"arraak":return!!(10===zi.getMonth()&&zi.getDate()>=22&&zi.getDate()<=28||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"seraph":return!!(1===zi.getMonth()&&14===zi.getDate()||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"junker":return!!(Ai.active||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0)}return!1}const Li={humanoid:{adaptable:1,wasteful:1},carnivore:{carnivore:1,beast:1,cautious:1},herbivore:{herbivore:1,instinct:1},small:{small:1,weak:1},giant:{large:1,strong:1},reptilian:{cold_blooded:1,scales:1},avian:{flier:1,hollow_bones:1,sky_lover:1},insectoid:{high_pop:1,fast_growth:1,high_metabolism:1},plant:{sappy:1,asymmetrical:1},fungi:{detritivore:1,spongy:1},aquatic:{submerged:1,low_light:1},fey:{elusive:1,iron_allergy:1},heat:{smoldering:1,cold_intolerance:1},polar:{chilled:1,heat_intolerance:1},sand:{scavenger:1,nomadic:1},demonic:{immoral:1,evil:1,soul_eater:1},angelic:{blissful:1,pompous:1,holy:1},synthetic:{artifical:1,powered:1},eldritch:{psychic:1,tormented:1,darkness:1,unfathomable:1}},Ei={adaptable:{name:z("trait_adaptable_name"),desc:z("trait_adaptable"),type:"genus",val:3,vars(e){switch(e||t.race.adaptable||1){case.25:return[3];case.5:return[5];case 1:return[10];case 2:return[15];case 3:return[20]}}},wasteful:{name:z("trait_wasteful_name"),desc:z("trait_wasteful"),type:"genus",val:-3,vars(e){switch(e||t.race.wasteful||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[6];case 3:return[4]}}},xenophobic:{name:z("trait_xenophobic_name"),desc:z("trait_xenophobic"),type:"genus",val:-5},carnivore:{name:z("trait_carnivore_name"),desc:z("trait_carnivore"),type:"genus",val:3,vars(e){switch(e||t.race.carnivore||1){case.25:return[65];case.5:return[60];case 1:return[50];case 2:return[40];case 3:return[35]}}},beast:{name:z("trait_beast_name"),desc:z("trait_beast"),type:"genus",val:2,vars(e){switch(e||t.race.beast||1){case.25:return[4,8,4];case.5:return[5,10,5];case 1:return[8,15,10];case 2:return[10,20,15];case 3:return[12,24,20]}}},cautious:{name:z("trait_cautious_name"),desc:z("trait_cautious"),type:"genus",val:-2,vars(e){switch(e||t.race.cautious||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},herbivore:{name:z("trait_herbivore_name"),desc:z("trait_herbivore"),type:"genus",val:-7},instinct:{name:z("trait_instinct_name"),desc:z("trait_instinct"),type:"genus",val:5,vars(e){switch(e||t.race.instinct||1){case.25:return[3,15];case.5:return[5,25];case 1:return[10,50];case 2:return[15,60];case 3:return[20,65]}}},small:{name:z("trait_small_name"),desc:z("trait_small"),type:"genus",val:6,vars(e){switch(e||t.race.small||1){case.25:return[.0025,.0015];case.5:return[.005,.0025];case 1:return[.01,.005];case 2:return[.0125,.006];case 3:return[.015,.0075]}}},weak:{name:z("trait_weak_name"),desc:z("trait_weak"),type:"genus",val:-3,vars(e){switch(e||t.race.weak||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},large:{name:z("trait_large_name"),desc:z("trait_large"),type:"genus",val:-5,vars(e){switch(e||t.race.large||1){case.25:return[.007];case.5:return[.006];case 1:return[.005];case 2:return[.004];case 3:return[.003]}}},strong:{name:z("trait_strong_name"),desc:z("trait_strong"),type:"genus",val:5,vars(e){switch(e||t.race.strong||1){case.25:return[2,1.25];case.5:return[3,1.5];case 1:return[4,2];case 2:return[5,2.25];case 3:return[6,2.5]}}},cold_blooded:{name:z("trait_cold_blooded_name"),desc:z("trait_cold_blooded"),type:"genus",val:-2,vars(e){switch(e||t.race.cold_blooded||1){case.25:return[30,6];case.5:return[25,8];case 1:return[20,10];case 2:return[15,15];case 3:return[12,18]}}},scales:{name:z("trait_scales_name"),desc:z("trait_scales"),type:"genus",val:5,vars(e){switch(e||t.race.scales||1){case.25:return[1,0,1];case.5:return[1,1,1];case 1:return[2,1,1];case 2:return[2,2,1];case 3:return[2,2,2]}}},flier:{name:z("trait_flier_name"),desc:z("trait_flier"),type:"genus",val:3,vars(e){switch(e||t.race.flier||1){case.25:return[10,0];case.5:return[15,0];case 1:return[25,1];case 2:return[40,1];case 3:return[50,2]}}},hollow_bones:{name:z("trait_hollow_bones_name"),desc:z("trait_hollow_bones"),type:"genus",val:2,vars(e){switch(e||t.race.hollow_bones||1){case.25:return[1];case.5:return[2];case 1:return[5];case 2:return[8];case 3:return[10]}}},sky_lover:{name:z("trait_sky_lover_name"),desc:z("trait_sky_lover"),type:"genus",val:-2,vars(e){switch(e||t.race.sky_lover||1){case.25:return[40];case.5:return[30];case 1:return[20];case 2:return[15];case 3:return[10]}}},rigid:{name:z("trait_rigid_name"),desc:z("trait_rigid"),type:"genus",val:-2,vars(e){switch(e||t.race.rigid||1){case.25:return[3];case.5:return[2];case 1:return[1];case 2:return[.5];case 3:return[.4]}}},high_pop:{name:z("trait_high_pop_name"),desc:z("trait_high_pop"),type:"genus",val:3,vars(e){switch(e||t.race.high_pop||1){case.25:return[2,50,1.5];case.5:return[3,34,2.5];case 1:return[4,26,3.5];case 2:return[5,21.2,4.5];case 3:return[6,18,5.5]}}},fast_growth:{name:z("trait_fast_growth_name"),desc:z("trait_fast_growth"),type:"genus",val:2,vars(e){switch(e||t.race.fast_growth||1){case.25:return[1.5,1];case.5:return[2,1];case 1:return[2,2];case 2:return[2.5,3];case 3:return[3,3]}}},high_metabolism:{name:z("trait_high_metabolism_name"),desc:z("trait_high_metabolism"),type:"genus",val:-1,vars(e){switch(e||t.race.high_metabolism||1){case.25:return[10];case.5:return[8];case 1:return[5];case 2:return[2];case 3:return[1]}}},photosynth:{name:z("trait_photosynth_name"),desc:z("trait_photosynth"),type:"genus",val:3,vars(e){switch(e||t.race.photosynth||1){case.25:return[10,5,4];case.5:return[20,10,5];case 1:return[40,20,10];case 2:return[50,30,15];case 3:return[60,35,20]}}},sappy:{name:z("trait_sappy_name"),desc:z("trait_sappy",[z("resource_Amber_name")]),type:"genus",val:4,vars(e){switch(e||t.race.sappy||1){case.25:return[.4];case.5:return[.5];case 1:return[.6];case 2:return[.65];case 3:return[.7]}}},asymmetrical:{name:z("trait_asymmetrical_name"),desc:z("trait_asymmetrical"),type:"genus",val:-3,vars(e){switch(e||t.race.asymmetrical||1){case.25:return[30];case.5:return[25];case 1:return[20];case 2:return[15];case 3:return[10]}}},detritivore:{name:z("trait_detritivore_name"),desc:z("trait_detritivore"),type:"genus",val:2,vars(e){switch(e||t.race.detritivore||1){case.25:return[65];case.5:return[72];case 1:return[80];case 2:return[85];case 3:return[90]}}},spores:{name:z("trait_spores_name"),desc:z("trait_spores"),type:"genus",val:2,vars(e){switch(e||t.race.spores||1){case.25:return[1,1.5,1];case.5:return[2,1.5,1];case 1:return[2,2,1];case 2:return[2,2.5,2];case 3:return[2,3,2]}}},spongy:{name:z("trait_spongy_name"),desc:z("trait_spongy"),type:"genus",val:-2},submerged:{name:z("trait_submerged_name"),desc:z("trait_submerged"),type:"genus",val:3},low_light:{name:z("trait_low_light_name"),desc:z("trait_low_light"),type:"genus",val:-2,vars(e){switch(e||t.race.low_light||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},elusive:{name:z("trait_elusive_name"),desc:z("trait_elusive"),type:"genus",val:7,vars(e){switch(e||t.race.elusive||1){case.25:return[10];case.5:return[15];case 1:return[20];case 2:return[25];case 3:return[30]}}},iron_allergy:{name:z("trait_iron_allergy_name"),desc:z("trait_iron_allergy"),type:"genus",val:-4,vars(e){switch(e||t.race.iron_allergy||1){case.25:return[40];case.5:return[35];case 1:return[25];case 2:return[18];case 3:return[15]}}},smoldering:{name:z("trait_smoldering_name"),desc:z("trait_smoldering"),type:"genus",val:7,vars(e){switch(e||t.race.smoldering||1){case.25:return[3,.14,.08];case.5:return[4,.18,.1];case 1:return[5,.35,.2];case 2:return[10,.38,.22];case 3:return[12,.4,.24]}}},cold_intolerance:{name:z("trait_cold_intolerance_name"),desc:z("trait_cold_intolerance"),type:"genus",val:-4,vars(e){switch(e||t.race.cold_intolerance||1){case.25:return[.35];case.5:return[.3];case 1:return[.25];case 2:return[.2];case 3:return[.18]}}},chilled:{name:z("trait_chilled_name"),desc:z("trait_chilled"),type:"genus",val:7,vars(e){switch(e||t.race.chilled||1){case.25:return[1,.14,.08,5,2,20];case.5:return[2,.18,.1,10,5,18];case 1:return[5,.35,.2,20,10,15];case 2:return[10,.38,.22,25,12,10];case 3:return[12,.4,.24,30,14,8]}}},heat_intolerance:{name:z("trait_heat_intolerance_name"),desc:z("trait_heat_intolerance"),type:"genus",val:-4,vars(e){switch(e||t.race.heat_intolerance||1){case.25:return[.35];case.5:return[.3];case 1:return[.25];case 2:return[.2];case 3:return[.18]}}},scavenger:{name:z("trait_scavenger_name"),desc:z("trait_scavenger"),type:"genus",val:3,vars(e){switch(e||t.race.scavenger||1){case.25:return[.08,20];case.5:return[.1,22];case 1:return[.12,25];case 2:return[.14,30];case 3:return[.16,32]}}},nomadic:{name:z("trait_nomadic_name"),desc:z("trait_nomadic"),type:"genus",val:-5},immoral:{name:z("trait_immoral_name"),desc:z("trait_immoral"),type:"genus",val:4,vars(e){switch(e||t.race.immoral||1){case.25:return[-30];case.5:return[-20];case 1:return[0];case 2:return[20];case 3:return[30]}}},evil:{name:z("trait_evil_name"),desc:z("trait_evil"),type:"genus",val:0},blissful:{name:z("trait_blissful_name"),desc:z("trait_blissful"),type:"genus",val:3,vars(e){switch(e||t.race.blissful||1){case.25:return[70];case.5:return[60];case 1:return[50];case 2:return[40];case 3:return[30]}}},pompous:{name:z("trait_pompous_name"),desc:z("trait_pompous"),type:"genus",val:-6,vars(e){switch(e||t.race.pompous||1){case.25:return[85];case.5:return[80];case 1:return[75];case 2:return[65];case 3:return[60]}}},holy:{name:z("trait_holy_name"),desc:z("trait_holy"),type:"genus",val:4,vars(e){switch(e||t.race.holy||1){case.25:return[25,10];case.5:return[30,15];case 1:return[50,25];case 2:return[60,35];case 3:return[65,40]}}},artifical:{name:z("trait_artifical_name"),desc:z("trait_artifical"),type:"genus",val:5,vars(e){switch(e||t.race.artifical||1){case.25:return[5];case.5:return[10];case 1:return[20];case 2:return[25];case 3:return[30]}}},powered:{name:z("trait_powered_name"),desc:z("trait_powered"),type:"genus",val:-6,vars(e){switch(e||t.race.powered||1){case.25:return[.35,5];case.5:return[.3,8];case 1:return[.2,16];case 2:return[.1,20];case 3:return[.05,24]}}},psychic:{name:z("trait_psychic_name"),desc:z("trait_psychic"),type:"genus",val:10,vars(e){switch(e||t.race.psychic||1){case.25:return[.35,5,.01,20];case.5:return[.65,10,.025,30];case 1:return[1,15,.05,40];case 2:return[1.25,20,.075,50];case 3:return[1.5,25,.1,60]}}},tormented:{name:z("trait_tormented_name"),desc:z("trait_tormented"),type:"genus",val:-25,vars(e){switch(e||t.race.tormented||1){case.25:return[99];case.5:return[95];case 1:return[90];case 2:return[80];case 3:return[75]}}},darkness:{name:z("trait_darkness_name"),desc:z("trait_darkness"),type:"genus",val:1,vars(e){switch(e||t.race.darkness||1){case.25:return[1];case.5:return[2];case 1:return[3];case 2:return[4];case 3:return[5]}}},unfathomable:{name:z("trait_unfathomable_name"),desc:z("trait_unfathomable"),type:"genus",val:15,vars(e){switch(e||t.race.unfathomable||1){case.25:return[1,.5,.05];case.5:return[1,.65,.08];case 1:return[2,.8,.1];case 2:return[2,.9,.12];case 3:return[3,1,.13]}}},creative:{name:z("trait_creative_name"),desc:z("trait_creative"),type:"major",val:8,vars(e){switch(e||t.race.creative||1){case.25:return[.0015,5];case.5:return[.0025,10];case 1:return[.005,20];case 2:return[.006,22];case 3:return[.0065,24]}}},diverse:{name:z("trait_diverse_name"),desc:z("trait_diverse"),type:"major",val:-4,vars(e){switch(e||t.race.diverse||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},studious:{name:z("trait_studious_name"),desc:z("trait_studious"),type:"major",val:2,vars(e){switch(e||t.race.studious||1){case.25:return[.1,6];case.5:return[.15,8];case 1:return[.25,10];case 2:return[.35,12];case 3:return[.4,14]}}},arrogant:{name:z("trait_arrogant_name"),desc:z("trait_arrogant"),type:"major",val:-2,vars(e){switch(e||t.race.arrogant||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},brute:{name:z("trait_brute_name"),desc:z("trait_brute"),type:"major",val:7,vars(e){switch(e||t.race.brute||1){case.25:return[20,50];case.5:return[25,60];case 1:return[50,100];case 2:return[60,120];case 3:return[65,140]}}},angry:{name:z("trait_angry_name"),desc:z("trait_angry"),type:"major",val:-1,vars(e){switch(e||t.race.angry||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},lazy:{name:z("trait_lazy_name"),desc:z("trait_lazy"),type:"major",val:-4,vars(e){switch(e||t.race.lazy||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},curious:{name:z("trait_curious_name"),desc:z("trait_curious"),type:"major",val:4,vars(e){switch(e||t.race.curious||1){case.25:return[.03];case.5:return[.05];case 1:return[.1];case 2:return[.12];case 3:return[.13]}}},pack_mentality:{name:z("trait_pack_mentality_name"),desc:z("trait_pack_mentality"),type:"major",val:4,vars(e){switch(e||t.race.pack_mentality||1){case.25:return[.04,.016];case.5:return[.035,.018];case 1:return[.03,.02];case 2:return[.026,.022];case 3:return[.024,.023]}}},tracker:{name:z("trait_tracker_name"),desc:z("trait_tracker"),type:"major",val:2,vars(e){switch(e||t.race.tracker||1){case.25:return[10];case.5:return[15];case 1:return[20];case 2:return[25];case 3:return[30]}}},playful:{name:z("trait_playful_name"),desc:z("trait_playful"),type:"major",val:5,vars(e){switch(e||t.race.playful||1){case.25:return[.3];case.5:return[.4];case 1:return[.5];case 2:return[.6];case 3:return[.7]}}},freespirit:{name:z("trait_freespirit_name"),desc:z("trait_freespirit"),type:"major",val:-3,vars(e){switch(e||t.race.freespirit||1){case.25:return[65];case.5:return[60];case 1:return[50];case 2:return[35];case 3:return[25]}}},beast_of_burden:{name:z("trait_beast_of_burden_name"),desc:z("trait_beast_of_burden"),type:"major",val:3},sniper:{name:z("trait_sniper_name"),desc:z("trait_sniper"),type:"major",val:6,vars(e){switch(e||t.race.sniper||1){case.25:return[4];case.5:return[6];case 1:return[8];case 2:return[9];case 3:return[10]}}},hooved:{name:z("trait_hooved_name"),desc:z("trait_hooved"),type:"major",val:-4,vars(e){switch(e||t.race.hooved||1){case.25:return[130];case.5:return[120];case 1:return[100];case 2:return[80];case 3:return[70]}}},rage:{name:z("trait_rage_name"),desc:z("trait_rage"),type:"major",val:4,vars(e){switch(e||t.race.rage||1){case.25:return[.3,20];case.5:return[.5,30];case 1:return[1,50];case 2:return[1.25,60];case 3:return[1.4,65]}}},heavy:{name:z("trait_heavy_name"),desc:z("trait_heavy"),type:"major",val:-4,vars(e){switch(e||t.race.heavy||1){case.25:return[18,10];case.5:return[15,8];case 1:return[10,5];case 2:return[8,4];case 3:return[6,3]}}},gnawer:{name:z("trait_gnawer_name"),desc:z("trait_gnawer"),type:"major",val:-1,vars(e){switch(e||t.race.gnawer||1){case.25:return[.5];case.5:return[.4];case 1:return[.25];case 2:return[.2];case 3:return[.15]}}},calm:{name:z("trait_calm_name"),desc:z("trait_calm"),type:"major",val:6,vars(e){switch(e||t.race.calm||1){case.25:return[7];case.5:return[8];case 1:return[10];case 2:return[12];case 3:return[13]}}},pack_rat:{name:z("trait_pack_rat_name"),desc:z("trait_pack_rat"),type:"major",val:3,vars(e){switch(e||t.race.pack_rat||1){case.25:return[5,2];case.5:return[6,3];case 1:return[10,5];case 2:return[15,8];case 3:return[20,10]}}},paranoid:{name:z("trait_paranoid_name"),desc:z("trait_paranoid"),type:"major",val:-3,vars(e){switch(e||t.race.paranoid||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},greedy:{name:z("trait_greedy_name"),desc:z("trait_greedy"),type:"major",val:-5,vars(e){switch(e||t.race.greedy||1){case.25:return[17.5];case.5:return[15];case 1:return[12.5];case 2:return[10];case 3:return[8]}}},merchant:{name:z("trait_merchant_name"),desc:z("trait_merchant"),type:"major",val:3,vars(e){switch(e||t.race.merchant||1){case.25:return[10,3];case.5:return[15,5];case 1:return[25,10];case 2:return[35,12];case 3:return[40,13]}}},smart:{name:z("trait_smart_name"),desc:z("trait_smart"),type:"major",val:6,vars(e){switch(e||t.race.smart||1){case.25:return[3];case.5:return[5];case 1:return[10];case 2:return[12];case 3:return[13]}}},puny:{name:z("trait_puny_name"),desc:z("trait_puny"),type:"major",val:-4,vars(e){switch(e||t.race.puny||1){case.25:return[18];case.5:return[15];case 1:return[10];case 2:return[6];case 3:return[4]}}},dumb:{name:z("trait_dumb_name"),desc:z("trait_dumb"),type:"major",val:-5,vars(e){switch(e||t.race.dumb||1){case.25:return[7];case.5:return[6];case 1:return[5];case 2:return[4];case 3:return[3]}}},tough:{name:z("trait_tough_name"),desc:z("trait_tough"),type:"major",val:4,vars(e){switch(e||t.race.tough||1){case.25:return[10];case.5:return[15];case 1:return[25];case 2:return[35];case 3:return[40]}}},nearsighted:{name:z("trait_nearsighted_name"),desc:z("trait_nearsighted"),type:"major",val:-4,vars(e){switch(e||t.race.nearsighted||1){case.25:return[18];case.5:return[15];case 1:return[12];case 2:return[10];case 3:return[8]}}},intelligent:{name:z("trait_intelligent_name"),desc:z("trait_intelligent"),type:"major",val:7,vars(e){switch(e||t.race.intelligent||1){case.25:return[.08,.15];case.5:return[.1,.2];case 1:return[.125,.25];case 2:return[.14,.3];case 3:return[.15,.32]}}},regenerative:{name:z("trait_regenerative_name"),desc:z("trait_regenerative"),type:"major",val:8,vars:e=>[4],vars(e){switch(e||t.race.regenerative||1){case.25:return[2];case.5:return[3];case 1:return[4];case 2:return[5];case 3:return[6]}}},gluttony:{name:z("trait_gluttony_name"),desc:z("trait_gluttony"),type:"major",val:-2,vars(e){switch(e||t.race.gluttony||1){case.25:return[20];case.5:return[15];case 1:return[10];case 2:return[8];case 3:return[6]}}},slow:{name:z("trait_slow_name"),desc:z("trait_slow"),type:"major",val:-5,vars(e){switch(e||t.race.slow||1){case.25:return[13];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},armored:{name:z("trait_armored_name"),desc:z("trait_armored"),type:"major",val:4,vars(e){switch(e||t.race.armored||1){case.25:return[15,1];case.5:return[25,1];case 1:return[50,2];case 2:return[70,2];case 3:return[80,2]}}},optimistic:{name:z("trait_optimistic_name"),desc:z("trait_optimistic"),type:"major",val:5,vars(e){switch(e||t.race.optimistic||1){case.25:return[4,6];case.5:return[5,8];case 1:return[10,10];case 2:return[15,13];case 3:return[18,15]}}},chameleon:{name:z("trait_chameleon_name"),desc:z("trait_chameleon"),type:"major",val:6,vars(e){switch(e||t.race.chameleon||1){case.25:return[5,10];case.5:return[10,15];case 1:return[20,20];case 2:return[25,25];case 3:return[30,30]}}},slow_digestion:{name:z("trait_slow_digestion_name"),desc:z("trait_slow_digestion"),type:"major",val:1,vars(e){switch(e||t.race.slow_digestion||1){case.25:return[.3];case.5:return[.5];case 1:return[.75];case 2:return[1];case 3:return[1.25]}}},hard_of_hearing:{name:z("trait_hard_of_hearing_name"),desc:z("trait_hard_of_hearing"),type:"major",val:-3,vars(e){switch(e||t.race.hard_of_hearing||1){case.25:return[7];case.5:return[6];case 1:return[5];case 2:return[4];case 3:return[3]}}},resourceful:{name:z("trait_resourceful_name"),desc:z("trait_resourceful"),type:"major",val:4,vars(e){switch(e||t.race.resourceful||1){case.25:return[6];case.5:return[8];case 1:return[12];case 2:return[16];case 3:return[18]}}},selenophobia:{name:z("trait_selenophobia_name"),desc:z("trait_selenophobia"),type:"major",val:-6,vars(e){switch(e||t.race.selenophobia||1){case.25:return[2];case.5:return[3];case 1:return[4];case 2:return[5];case 3:return[6]}}},leathery:{name:z("trait_leathery_name"),desc:z("trait_leathery"),type:"major",val:2,vars(e){switch(e||t.race.leathery||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:return[1];case 3:return[0]}}},pessimistic:{name:z("trait_pessimistic_name"),desc:z("trait_pessimistic"),type:"major",val:-1,vars(e){switch(e||t.race.pessimistic||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:case 3:return[1]}}},hoarder:{name:z("trait_hoarder_name"),desc:z("trait_hoarder"),type:"major",val:4,vars(e){switch(e||t.race.hoarder||1){case.25:return[5];case.5:return[10];case 1:return[20];case 2:return[25];case 3:return[30]}}},solitary:{name:z("trait_solitary_name"),desc:z("trait_solitary"),type:"major",val:-1,vars(e){switch(e||t.race.solitary||1){case.25:return[.01,.025];case.5:return[.01,.02];case 1:return[.02,.02];case 2:return[.025,.02];case 3:return[.025,.015]}}},kindling_kindred:{name:z("trait_kindling_kindred_name"),desc:z("trait_kindling_kindred"),type:"major",val:8,vars(e){switch(e||t.race.kindling_kindred||1){case.25:return[10];case.5:return[8];case 1:return[5];case 2:return[4];case 3:return[3]}}},pyrophobia:{name:z("trait_pyrophobia_name"),desc:z("trait_pyrophobia"),type:"major",val:-4,vars(e){switch(e||t.race.pyrophobia||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},hyper:{name:z("trait_hyper_name"),desc:z("trait_hyper"),type:"major",val:4,vars(e){switch(e||t.race.hyper||1){case.25:return[2];case.5:return[3];case 1:return[5];case 2:return[6];case 3:return[7]}}},skittish:{name:z("trait_skittish_name"),desc:z("trait_skittish"),type:"major",val:-4,vars(e){switch(e||t.race.skittish||1){case.25:return[18];case.5:return[15];case 1:return[12];case 2:return[8];case 3:return[6]}}},fragrant:{name:z("trait_fragrant_name"),desc:z("trait_fragrant"),type:"major",val:-3,vars(e){switch(e||t.race.fragrant||1){case.25:return[35];case.5:return[30];case 1:return[20];case 2:return[15];case 3:return[12]}}},sticky:{name:z("trait_sticky_name"),desc:z("trait_sticky"),type:"major",val:3,vars(e){switch(e||t.race.sticky||1){case.25:return[5,5];case.5:return[10,8];case 1:return[20,15];case 2:return[25,18];case 3:return[30,20]}}},infectious:{name:z("trait_infectious_name"),desc:z("trait_infectious"),type:"major",val:4,vars(e){switch(e||t.race.infectious||1){case.25:return[1,2,3,7,18];case.5:return[1,2,4,8,20];case 1:return[2,3,5,10,25];case 2:return[2,4,6,12,30];case 3:return[3,4,7,13,32]}}},parasite:{name:z("trait_parasite_name"),desc:z("trait_parasite"),type:"major",val:-4},toxic:{name:z("trait_toxic_name"),desc:z("trait_toxic"),type:"major",val:5,vars(e){switch(e||t.race.toxic||1){case.25:return[5,3,10];case.5:return[10,5,15];case 1:return[20,8,30];case 2:return[25,10,40];case 3:return[30,12,45]}}},nyctophilia:{name:z("trait_nyctophilia_name"),desc:z("trait_nyctophilia"),type:"major",val:-3,vars(e){switch(e||t.race.nyctophilia||1){case.25:return[10,6];case.5:return[8,5];case 1:return[5,2];case 2:return[3,1];case 3:return[2,1]}}},infiltrator:{name:z("trait_infiltrator_name"),desc:z("trait_infiltrator"),type:"major",val:4,vars(e){switch(e||t.race.infiltrator||1){case.25:return[110];case.5:return[100];case 1:return[90];case 2:return[85];case 3:return[80]}}},hibernator:{name:z("trait_hibernator_name"),desc:z("trait_hibernator"),type:"major",val:-3,vars(e){switch(e||t.race.hibernator||1){case.25:return[15,8];case.5:return[20,8];case 1:return[25,8];case 2:return[30,6];case 3:return[35,5]}}},cannibalize:{name:z("trait_cannibalize_name"),desc:z("trait_cannibalize"),type:"major",val:5,vars(e){switch(e||t.race.cannibalize||1){case.25:return[8];case.5:return[10];case 1:return[15];case 2:return[20];case 3:return[22]}}},frail:{name:z("trait_frail_name"),desc:z("trait_frail"),type:"major",val:-5,vars(e){switch(e||t.race.frail||1){case.25:return[2,2];case.5:return[1,2];case 1:return[1,1];case 2:case 3:return[1,0]}}},malnutrition:{name:z("trait_malnutrition_name"),desc:z("trait_malnutrition"),type:"major",val:1,vars(e){switch(e||t.race.malnutrition||1){case.25:return[10];case.5:return[12];case 1:return[25];case 2:return[40];case 3:return[50]}}},claws:{name:z("trait_claws_name"),desc:z("trait_claws"),type:"major",val:5,vars(e){switch(e||t.race.claws||1){case.25:return[8];case.5:return[12];case 1:return[25];case 2:return[32];case 3:return[35]}}},atrophy:{name:z("trait_atrophy_name"),desc:z("trait_atrophy"),type:"major",val:-1,vars(e){switch(e||t.race.atrophy||1){case.25:return[.35];case.5:return[.25];case 1:return[.15];case 2:return[.1];case 3:return[.08]}}},hivemind:{name:z("trait_hivemind_name"),desc:z("trait_hivemind"),type:"major",val:9,vars(e){switch(e||t.race.hivemind||1){case.25:return[12];case.5:return[11];case 1:return[10];case 2:return[8];case 3:return[7]}}},tunneler:{name:z("trait_tunneler_name"),desc:z("trait_tunneler"),type:"major",val:2,vars(e){switch(e||t.race.tunneler||1){case.25:return[.002];case.5:return[.005];case 1:return[.01];case 2:return[.015];case 3:return[.018]}}},blood_thirst:{name:z("trait_blood_thirst_name"),desc:z("trait_blood_thirst"),type:"major",val:5,vars(e){switch(e||t.race.blood_thirst||1){case.25:return[25e4];case.5:return[5e5];case 1:return[1e6];case 2:return[2e6];case 3:return[4e6]}}},apex_predator:{name:z("trait_apex_predator_name"),desc:z("trait_apex_predator"),type:"major",val:6,vars(e){switch(e||t.race.apex_predator||1){case.25:return[15,20];case.5:return[20,30];case 1:return[30,50];case 2:return[40,60];case 3:return[45,65]}}},invertebrate:{name:z("trait_invertebrate_name"),desc:z("trait_invertebrate"),type:"major",val:-2,vars(e){switch(e||t.race.invertebrate||1){case.25:return[25];case.5:return[20];case 1:return[10];case 2:return[8];case 3:return[5]}}},suction_grip:{name:z("trait_suction_grip_name"),desc:z("trait_suction_grip"),type:"major",val:4,vars(e){switch(e||t.race.suction_grip||1){case.25:return[5];case.5:return[6];case 1:return[8];case 2:return[12];case 3:return[14]}}},befuddle:{name:z("trait_befuddle_name"),desc:z("trait_befuddle"),type:"major",val:4,vars(e){switch(e||t.race.befuddle||1){case.25:return[20];case.5:return[30];case 1:return[50];case 2:return[75];case 3:return[85]}}},environmentalist:{name:z("trait_environmentalist_name"),desc:z("trait_environmentalist"),type:"major",val:-5},unorganized:{name:z("trait_unorganized_name"),desc:z("trait_unorganized"),type:"major",val:-2,vars(e){switch(e||t.race.unorganized||1){case.25:return[90];case.5:return[80];case 1:return[50];case 2:return[40];case 3:return[30]}}},musical:{name:z("trait_musical_name"),desc:z("trait_musical"),type:"major",val:5,vars(e){switch(e||t.race.musical||1){case.25:return[.25];case.5:return[.5];case 1:return[1];case 2:return[1.1];case 3:return[1.2]}}},revive:{name:z("trait_revive_name"),desc:z("trait_revive"),type:"major",val:4,vars(e){switch(e||t.race.revive||1){case.25:return[7,5,2,8,6,3,4];case.5:return[6,4,2,7,5,2.5,4];case 1:return[5,3,1.5,6,4,2,3];case 2:return[4,2,1,5,3,1.5,2];case 3:return[3,1.5,1,4,2.5,1,2]}}},slow_regen:{name:z("trait_slow_regen_name"),desc:z("trait_slow_regen"),type:"major",val:-4,vars(e){switch(e||t.race.slow_regen||1){case.25:return[40];case.5:return[35];case 1:return[25];case 2:return[20];case 3:return[15]}}},forge:{name:z("trait_forge_name"),desc:z("trait_forge"),type:"major",val:4,vars(e){switch(e||t.race.forge||1){case.25:return[.5];case.5:return[1];case 1:return[2];case 2:return[2.5];case 3:return[3]}}},autoignition:{name:z("trait_autoignition_name"),desc:z("trait_autoignition"),type:"major",val:-4,vars(e){switch(e||t.race.autoignition||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:return[1.5];case 3:return[1]}}},blurry:{name:z("trait_blurry_name"),desc:z("trait_blurry"),type:"major",val:5,vars(e){switch(e||t.race.blurry||1){case.25:return[10];case.5:return[15];case 1:return[25];case 2:return[35];case 3:return[40]}}},snowy:{name:z("trait_snowy_name"),desc:z("trait_snowy"),type:"major",val:-3,vars(e){switch(e||t.race.snowy||1){case.25:return[4,10];case.5:return[3,8];case 1:return[2,5];case 2:return[2,4];case 3:return[1,3]}}},ravenous:{name:z("trait_ravenous_name"),desc:z("trait_ravenous"),type:"major",val:-5,vars(e){switch(e||t.race.ravenous||1){case.25:return[30,2];case.5:return[25,2];case 1:return[20,3];case 2:return[15,4];case 3:return[10,4]}}},ghostly:{name:z("trait_ghostly_name"),desc:z("trait_ghostly"),type:"major",val:5,vars(e){switch(e||t.race.ghostly||1){case.25:return[20,1.2,5];case.5:return[25,1.25,10];case 1:return[50,1.5,15];case 2:return[60,1.6,20];case 3:return[65,1.7,22]}}},lawless:{name:z("trait_lawless_name"),desc:z("trait_lawless"),type:"major",val:3,vars(e){switch(e||t.race.lawless||1){case.25:return[30];case.5:return[50];case 1:return[90];case 2:return[95];case 3:return[98]}}},mistrustful:{name:z("trait_mistrustful_name"),desc:z("trait_mistrustful"),type:"major",val:-1,vars(e){switch(e||t.race.mistrustful||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:case 3:return[1]}}},humpback:{name:z("trait_humpback_name"),desc:z("trait_humpback"),type:"major",val:4,vars(e){switch(e||t.race.humpback||1){case.25:return[.2,8];case.5:return[.25,10];case 1:return[.5,20];case 2:return[.75,25];case 3:return[.8,30]}}},thalassophobia:{name:z("trait_thalassophobia_name"),desc:z("trait_thalassophobia"),type:"major",val:-4},fiery:{name:z("trait_fiery_name"),desc:z("trait_fiery"),type:"major",val:10,vars(e){switch(e||t.race.fiery||1){case.25:return[30,15];case.5:return[40,18];case 1:return[65,25];case 2:return[70,35];case 3:return[72,38]}}},terrifying:{name:z("trait_terrifying_name"),desc:z("trait_terrifying"),type:"major",val:6,vars(e){switch(e||t.race.terrifying||1){case.25:return[8,20];case.5:return[10,25];case 1:return[12,32];case 2:return[12,34];case 3:return[12,36]}}},slaver:{name:z("trait_slaver_name"),desc:z("trait_slaver"),type:"major",val:12,vars(e){switch(e||t.race.slaver||1){case.25:return[.1];case.5:return[.14];case 1:return[.28];case 2:return[.3];case 3:return[.32]}}},compact:{name:z("trait_compact_name"),desc:z("trait_compact"),type:"major",val:10,vars(e){switch(e||t.race.compact||1){case.25:return[.005,.003];case.5:return[.01,.005];case 1:return[.015,.0075];case 2:return[.018,.0085];case 3:return[.02,.009]}}},conniving:{name:z("trait_conniving_name"),desc:z("trait_conniving"),type:"major",val:4,vars(e){switch(e||t.race.conniving||1){case.25:return[2,8];case.5:return[3,10];case 1:return[5,15];case 2:return[8,20];case 3:return[10,24]}}},pathetic:{name:z("trait_pathetic_name"),desc:z("trait_pathetic"),type:"major",val:-5,vars(e){switch(e||t.race.pathetic||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},spiritual:{name:z("trait_spiritual_name"),desc:z("trait_spiritual"),type:"major",val:4,vars(e){switch(e||t.race.spiritual||1){case.25:return[8];case.5:return[10];case 1:return[13];case 2:return[15];case 3:return[18]}}},truthful:{name:z("trait_truthful_name"),desc:z("trait_truthful"),type:"major",val:-7,vars(e){switch(e||t.race.truthful||1){case.25:return[75];case.5:return[65];case 1:return[50];case 2:return[30];case 3:return[20]}}},unified:{name:z("trait_unified_name"),desc:z("trait_unified"),type:"major",val:4,vars(e){switch(e||t.race.unified||1){case.25:return[0];case.5:return[1];case 1:return[3];case 2:return[5];case 3:return[7]}}},rainbow:{name:z("trait_rainbow_name"),desc:z("trait_rainbow"),type:"major",val:3,vars(e){switch(e||t.race.rainbow||1){case.25:return[20];case.5:return[30];case 1:return[50];case 2:return[80];case 3:return[100]}}},magnificent:{name:z("trait_magnificent_name"),desc:z("trait_magnificent"),type:"major",val:6,vars(e){switch(e||t.race.magnificent||1){case.25:return[300,1,.5,.75,1];case.5:return[350,2,.75,.8,1];case 1:return[400,3,1,1,1];case 2:return[450,3,1.5,1.5,1.5];case 3:return[500,3,2,2,2]}}},noble:{name:z("trait_noble_name"),desc:z("trait_noble"),type:"major",val:-3,vars(e){switch(e||t.race.noble||1){case.25:return[15,20];case.5:return[12,20];case 1:return[10,20];case 2:return[10,24];case 3:return[10,28]}}},imitation:{name:z("trait_imitation_name"),desc:z("trait_imitation"),type:"major",val:6,vars(e){switch(e||t.race.imitation||1){case.25:return[.25,.5];case.5:return[.25,1];case 1:return[.5,1];case 2:return[.5,2];case 3:return[1,2]}}},emotionless:{name:z("trait_emotionless_name"),desc:z("trait_emotionless"),type:"major",val:-4,vars(e){switch(e||t.race.emotionless||1){case.25:return[50,10];case.5:return[45,10];case 1:return[35,13];case 2:return[25,15];case 3:return[20,15]}}},logical:{name:z("trait_logical_name"),desc:z("trait_logical"),type:"major",val:6,vars(e){switch(e||t.race.logical||1){case.25:return[25,10];case.5:return[50,15];case 1:return[100,25];case 2:return[125,30];case 3:return[150,32]}}},shapeshifter:{name:z("trait_shapeshifter_name"),desc:z("trait_shapeshifter"),type:"major",val:10,vars(e){switch(e||t.race.shapeshifter||1){case.25:return[.25,.5];case.5:return[.25,1];case 1:return[.5,1];case 2:return[.5,2];case 3:return[1,2]}}},deconstructor:{name:z("trait_deconstructor_name"),desc:z("trait_deconstructor"),type:"major",val:-4,vars(e){switch(e||t.race.deconstructor||1){case.25:return[40];case.5:return[60];case 1:return[100];case 2:return[125];case 3:return[140]}}},linked:{name:z("trait_linked_name"),desc:z("trait_linked"),type:"major",val:4,vars(e){switch(e||t.race.linked||1){case.25:return[.03,40];case.5:return[.05,40];case 1:return[.1,80];case 2:return[.12,100];case 3:return[.14,100]}}},dark_dweller:{name:z("trait_dark_dweller_name"),desc:z("trait_dark_dweller"),type:"major",val:-3,vars(e){switch(e||t.race.dark_dweller||1){case.25:return[90];case.5:return[75];case 1:return[60];case 2:return[45];case 3:return[30]}}},swift:{name:z("trait_swift_name"),desc:z("trait_swift"),type:"major",val:10,vars(e){switch(e||t.race.swift||1){case.25:return[35,15];case.5:return[55,30];case 1:return[75,45];case 2:return[85,55];case 3:return[90,65]}}},anthropophagite:{name:z("trait_anthropophagite_name"),desc:z("trait_anthropophagite"),type:"major",val:-2,vars(e){switch(e||t.race.anthropophagite||1){case.25:return[.4];case.5:return[.65];case 1:return[1];case 2:return[1.5];case 3:return[2]}}},living_tool:{name:z("trait_living_tool_name"),desc:z("trait_living_tool"),type:"major",val:12,vars(e){switch(e||t.race.living_tool||1){case.25:return[.65,5];case.5:return[.8,12];case 1:return[1,25];case 2:return[1.1,35];case 3:return[1.2,42]}}},bloated:{name:z("trait_bloated_name"),desc:z("trait_bloated"),type:"major",val:-10,vars(e){switch(e||t.race.bloated||1){case.25:return[25];case.5:return[20];case 1:return[15];case 2:return[10];case 3:return[5]}}},ooze:{name:z("trait_ooze_name"),desc:z("trait_ooze"),type:"major",val:-50,vars(e){switch(e||t.race.ooze||1){case.25:return[20,25,40];case.5:return[15,20,35];case 1:return[12,15,30];case 2:return[10,12,25];case 3:return[8,10,20]}}},soul_eater:{name:z("trait_soul_eater_name"),desc:z("trait_soul_eater"),type:"special",val:0},untapped:{name:z("trait_untapped_name"),desc:z("trait_untapped"),type:"special",val:0},emfield:{name:z("trait_emfield_name"),desc:z("trait_emfield"),type:"special",val:-20},tactical:{name:z("trait_tactical_name"),desc:z("trait_tactical"),type:"minor",vars:e=>[5]},analytical:{name:z("trait_analytical_name"),desc:z("trait_analytical"),type:"minor",vars:e=>[1]},promiscuous:{name:z("trait_promiscuous_name"),desc:z("trait_promiscuous"),type:"minor",vars:e=>[1,.02]},resilient:{name:z("trait_resilient_name"),desc:z("trait_resilient"),type:"minor",vars:e=>[2]},cunning:{name:z("trait_cunning_name"),desc:z("trait_cunning"),type:"minor",vars:e=>[5]},hardy:{name:z("trait_hardy_name"),desc:z("trait_hardy"),type:"minor",vars:e=>[1]},ambidextrous:{name:z("trait_ambidextrous_name"),desc:z("trait_ambidextrous"),type:"minor",vars:e=>[3,2]},industrious:{name:z("trait_industrious_name"),desc:z("trait_industrious"),type:"minor",vars:e=>[2]},content:{name:z("trait_content_name"),desc:z("trait_content"),type:"minor"},fibroblast:{name:z("trait_fibroblast_name"),desc:z("trait_fibroblast"),type:"minor",vars:e=>[2]},metallurgist:{name:z("trait_metallurgist_name"),desc:z("trait_metallurgist"),type:"minor",vars:e=>[4]},gambler:{name:z("trait_gambler_name"),desc:z("trait_gambler"),type:"minor",vars:e=>[4]},persuasive:{name:z("trait_persuasive_name"),desc:z("trait_persuasive"),type:"minor",vars:e=>[1]},fortify:{name:z("trait_fortify_name"),desc:z("trait_fortify"),type:"special"},mastery:{name:z("trait_mastery_name"),desc:z("trait_mastery"),type:"special",vars:e=>[1]}},Ki={protoplasm:{name:z("race_protoplasm"),desc:z("race_protoplasm_desc"),type:"organism",home:z("race_prehistoric"),entity:"ooze",traits:{},solar:{red:z("race_human_solar_red"),hell:z("race_human_solar_hell"),gas:z("race_human_solar_gas"),gas_moon:z("race_human_solar_gas_moon"),dwarf:z("race_human_solar_dwarf")},fanaticism:"none",basic:()=>!1},human:{name:z("race_human"),desc:z("race_human_desc"),type:"humanoid",home:z("race_human_home"),entity:z("race_human_entity"),traits:{creative:1,diverse:1},solar:{red:z("race_human_solar_red"),hell:z("race_human_solar_hell"),gas:z("race_human_solar_gas"),gas_moon:z("race_human_solar_gas_moon"),dwarf:z("race_human_solar_dwarf")},fanaticism:"creative",basic:()=>!0},elven:{name:z("race_elven"),desc:z(Ti("elven")?"race_xmas_elf_desc":"race_elven_desc"),type:"humanoid",home:z(Ti("elven")?"race_xmas_elf_home":"race_elven_home"),entity:z("race_elven_entity"),traits:{studious:1,arrogant:1},solar:{red:z(Ti("elven")?"race_xmas_elf_solar_red":"race_elven_solar_red"),hell:z(Ti("elven")?"race_xmas_elf_solar_hell":"race_elven_solar_hell"),gas:z(Ti("elven")?"race_xmas_elf_solar_gas":"race_elven_solar_gas"),gas_moon:z(Ti("elven")?"race_xmas_elf_solar_gas_moon":"race_elven_solar_gas_moon"),dwarf:z(Ti("elven")?"race_xmas_elf_solar_dwarf":"race_elven_solar_dwarf")},fanaticism:"studious",basic:()=>!0},orc:{name:z("race_orc"),desc:z("race_orc_desc"),type:"humanoid",home:z("race_orc_home"),entity:z("race_orc_entity"),traits:{brute:1,angry:1},solar:{red:z("race_orc_solar_red"),hell:z("race_orc_solar_hell"),gas:z("race_orc_solar_gas"),gas_moon:z("race_orc_solar_gas_moon"),dwarf:z("race_orc_solar_dwarf")},fanaticism:"brute",basic:()=>!0},cath:{name:z("race_cath"),desc:z("race_cath_desc"),type:"carnivore",home:z("race_cath_home"),entity:z("race_cath_entity"),traits:{lazy:1,curious:1},solar:{red:z("race_cath_solar_red"),hell:z("race_cath_solar_hell"),gas:z("race_cath_solar_gas"),gas_moon:z("race_cath_solar_gas_moon"),dwarf:z("race_cath_solar_dwarf")},fanaticism:"curious",basic:()=>!0},wolven:{name:Ti("wolven")?z("race_rabbit"):z("race_wolven"),desc:Ti("wolven")?z("race_rabbit_desc"):z("race_wolven_desc"),type:"carnivore",home:Ti("wolven")?z("race_rabbit_home"):z("race_wolven_home"),entity:Ti("wolven")?z("race_rabbit_entity"):z("race_wolven_entity"),traits:{pack_mentality:1,tracker:1},solar:{red:Ti("wolven")?z("race_rabbit_solar_red"):z("race_wolven_solar_red"),hell:Ti("wolven")?z("race_rabbit_solar_hell"):z("race_wolven_solar_hell"),gas:Ti("wolven")?z("race_rabbit_solar_gas"):z("race_wolven_solar_gas"),gas_moon:Ti("wolven")?z("race_rabbit_solar_gas_moon"):z("race_wolven_solar_gas_moon"),dwarf:Ti("wolven")?z("race_rabbit_solar_dwarf"):z("race_wolven_solar_dwarf")},fanaticism:"tracker",basic:()=>!0},vulpine:{name:Ti("vulpine")?z("race_chocolate_rabbit"):z("magic"===t.race.universe?"race_kitsune":"race_vulpine"),desc:()=>Ti("vulpine")?z("race_chocolate_rabbit_desc"):z("race_vulpine_desc",[z("magic"===t.race.universe?"race_kitsune":"race_vulpine"),t.race.hasOwnProperty("fox_color")?z(`color_${t.race.fox_color}`):z("color_red")]),type:"carnivore",home:Ti("vulpine")?z("race_chocolate_rabbit_home"):z("race_vulpine_home"),entity:z("race_vulpine_entity"),traits:{playful:1,freespirit:1},solar:{red:Ti("vulpine")?z("race_chocolate_rabbit_solar_red"):z("race_vulpine_solar_red"),hell:Ti("vulpine")?z("race_chocolate_rabbit_solar_hell"):z("race_vulpine_solar_hell"),gas:Ti("vulpine")?z("race_chocolate_rabbit_solar_gas"):z("race_vulpine_solar_gas"),gas_moon:Ti("vulpine")?z("race_chocolate_rabbit_solar_gas_moon"):z("race_vulpine_solar_gas_moon"),dwarf:Ti("vulpine")?z("race_chocolate_rabbit_solar_dwarf"):z("race_vulpine_solar_dwarf")},fanaticism:"playful",basic:()=>!0},centaur:{name:z(Ti("centaur")?"race_reindeer":"race_centaur"),desc:z(Ti("centaur")?"race_reindeer_desc":"race_centaur_desc"),type:"herbivore",home:z(Ti("centaur")?"race_reindeer_home":"race_centaur_home"),entity:z(Ti("centaur")?"race_reindeer_entity":"race_centaur_entity"),traits:{sniper:1,hooved:1},solar:{red:z(Ti("centaur")?"race_reindeer_solar_red":"race_centaur_solar_red"),hell:z(Ti("centaur")?"race_reindeer_solar_hell":"race_centaur_solar_hell"),gas:z(Ti("centaur")?"race_reindeer_solar_gas":"race_centaur_solar_gas"),gas_moon:z(Ti("centaur")?"race_reindeer_solar_gas_moon":"race_centaur_solar_gas_moon"),dwarf:z(Ti("centaur")?"race_reindeer_solar_dwarf":"race_centaur_solar_dwarf")},fanaticism:"sniper",basic:()=>!0},rhinotaur:{name:z("race_rhinotaur"),desc:z("race_rhinotaur_desc"),type:"herbivore",home:z("race_rhinotaur_home"),entity:z("race_rhinotaur_entity"),traits:{rage:1,heavy:1},solar:{red:z("race_rhinotaur_solar_red"),hell:z("race_rhinotaur_solar_hell"),gas:z("race_rhinotaur_solar_gas"),gas_moon:z("race_rhinotaur_solar_gas_moon"),dwarf:z("race_rhinotaur_solar_dwarf")},fanaticism:"rage",basic:()=>!0},capybara:{name:z(Ti("capybara")?"race_donkey":"race_capybara"),desc:z(Ti("capybara")?"race_donkey_desc":"race_capybara_desc"),type:"herbivore",home:z(Ti("capybara")?"race_donkey_home":"race_capybara_home"),entity:z(Ti("capybara")?"race_donkey_entity":"race_capybara_entity"),traits:{gnawer:1,calm:1},solar:{red:z(Ti("capybara")?"race_donkey_solar_red":"race_capybara_solar_red"),hell:z(Ti("capybara")?"race_donkey_solar_hell":"race_capybara_solar_hell"),gas:z(Ti("capybara")?"race_donkey_solar_gas":"race_capybara_solar_gas"),gas_moon:z(Ti("capybara")?"race_donkey_solar_gas_moon":"race_capybara_solar_gas_moon"),dwarf:z(Ti("capybara")?"race_donkey_solar_dwarf":"race_capybara_solar_dwarf")},fanaticism:"calm",basic:()=>!0},kobold:{name:z("race_kobold"),desc:z("race_kobold_desc"),type:"small",home:z("race_kobold_home"),entity:z("race_kobold_entity"),traits:{pack_rat:1,paranoid:1},solar:{red:z("race_kobold_solar_red"),hell:z("race_kobold_solar_hell"),gas:z("race_kobold_solar_gas"),gas_moon:z("race_kobold_solar_gas_moon"),dwarf:z("race_kobold_solar_dwarf")},fanaticism:"pack_rat",basic:()=>!0},goblin:{name:z("race_goblin"),desc:z("race_goblin_desc"),type:"small",home:z("race_goblin_home"),entity:z("race_goblin_entity"),traits:{greedy:1,merchant:1},solar:{red:z("race_goblin_solar_red"),hell:z("race_goblin_solar_hell"),gas:z("race_goblin_solar_gas"),gas_moon:z("race_goblin_solar_gas_moon"),dwarf:z("race_goblin_solar_dwarf")},fanaticism:"merchant",basic:()=>!0},gnome:{name:z("race_gnome"),desc:z("race_gnome_desc"),type:"small",home:z("race_gnome_home"),entity:z("race_gnome_entity"),traits:{smart:1,puny:1},solar:{red:z("race_gnome_solar_red"),hell:z("race_gnome_solar_hell"),gas:z("race_gnome_solar_gas"),gas_moon:z("race_gnome_solar_gas_moon"),dwarf:z("race_gnome_solar_dwarf")},fanaticism:"smart",basic:()=>!0},ogre:{name:z("race_ogre"),desc:z("race_ogre_desc"),type:"giant",home:z("race_ogre_home"),entity:z("race_ogre_entity"),traits:{dumb:1,tough:1},solar:{red:z("race_ogre_solar_red"),hell:z("race_ogre_solar_hell"),gas:z("race_ogre_solar_gas"),gas_moon:z("race_ogre_solar_gas_moon"),dwarf:z("race_ogre_solar_dwarf")},fanaticism:"tough",basic:()=>!0},cyclops:{name:z("race_cyclops"),desc:z("race_cyclops_desc"),type:"giant",home:z("race_cyclops_home"),entity:z("race_cyclops_entity"),traits:{nearsighted:1,intelligent:1},solar:{red:z("race_cyclops_solar_red"),hell:z("race_cyclops_solar_hell"),gas:z("race_cyclops_solar_gas"),gas_moon:z("race_cyclops_solar_gas_moon"),dwarf:z("race_cyclops_solar_dwarf")},fanaticism:"intelligent",basic:()=>!0},troll:{name:z("race_troll"),desc:z("race_troll_desc"),type:"giant",home:z("race_troll_home"),entity:z("race_troll_entity"),traits:{regenerative:1,gluttony:1},solar:{red:z("race_troll_solar_red"),hell:z("race_troll_solar_hell"),gas:z("race_troll_solar_gas"),gas_moon:z("race_troll_solar_gas_moon"),dwarf:z("race_troll_solar_dwarf")},fanaticism:"regenerative",basic:()=>!0},tortoisan:{name:z("race_tortoisan"),desc:()=>z("race_tortoisan_desc",[t.race.hasOwnProperty("shell_color")?z(`color_${t.race.shell_color}`):z("color_green")]),type:"reptilian",home:z("race_tortoisan_home"),entity:z("race_tortoisan_entity"),traits:{slow:1,armored:1},solar:{red:z("race_tortoisan_solar_red"),hell:z("race_tortoisan_solar_hell"),gas:z("race_tortoisan_solar_gas"),gas_moon:z("race_tortoisan_solar_gas_moon"),dwarf:z("race_tortoisan_solar_dwarf")},fanaticism:"armored",basic:()=>!0},gecko:{name:z("race_gecko"),desc:z("race_gecko_desc"),type:"reptilian",home:z("race_gecko_home"),entity:z("race_gecko_entity"),traits:{optimistic:1,chameleon:1},solar:{red:z("race_gecko_solar_red"),hell:z("race_gecko_solar_hell"),gas:z("race_gecko_solar_gas"),gas_moon:z("race_gecko_solar_gas_moon"),dwarf:z("race_gecko_solar_dwarf")},fanaticism:"optimistic",basic:()=>!0},slitheryn:{name:z("race_slitheryn"),desc:z("race_slitheryn_desc"),type:"reptilian",home:z("race_slitheryn_home"),entity:z("race_slitheryn_entity"),traits:{slow_digestion:1,hard_of_hearing:1},solar:{red:z("race_slitheryn_solar_red"),hell:z("race_slitheryn_solar_hell"),gas:z("race_slitheryn_solar_gas"),gas_moon:z("race_slitheryn_solar_gas_moon"),dwarf:z("race_slitheryn_solar_dwarf")},fanaticism:"slow_digestion",basic:()=>!0},arraak:{name:z(Ti("arraak")?"race_turkey":"race_arraak"),desc:z(Ti("arraak")?"race_turkey_desc":"race_arraak_desc"),type:"avian",home:z(Ti("arraak")?"race_turkey_home":"race_arraak_home"),entity:z("race_arraak_entity"),traits:{resourceful:1,selenophobia:1},solar:{red:z(Ti("arraak")?"race_turkey_solar_red":"race_arraak_solar_red"),hell:z(Ti("arraak")?"race_turkey_solar_hell":"race_arraak_solar_hell"),gas:z(Ti("arraak")?"race_turkey_solar_gas":"race_arraak_solar_gas"),gas_moon:z(Ti("arraak")?"race_turkey_solar_gas_moon":"race_arraak_solar_gas_moon"),dwarf:z(Ti("arraak")?"race_turkey_solar_dwarf":"race_arraak_solar_dwarf")},fanaticism:"resourceful",basic:()=>!0},pterodacti:{name:z("race_pterodacti"),desc:z("race_pterodacti_desc"),type:"avian",home:z("race_pterodacti_home"),entity:z("race_pterodacti_entity"),traits:{leathery:1,pessimistic:1},solar:{red:z("race_pterodacti_solar_red"),hell:z("race_pterodacti_solar_hell"),gas:z("race_pterodacti_solar_gas"),gas_moon:z("race_pterodacti_solar_gas_moon"),dwarf:z("race_pterodacti_solar_dwarf")},fanaticism:"leathery",basic:()=>!0},dracnid:{name:z("race_dracnid"),desc:z("race_dracnid_desc"),type:"avian",home:z("race_dracnid_home"),entity:z("race_dracnid_entity"),traits:{hoarder:1,solitary:1},solar:{red:z("race_dracnid_solar_red"),hell:z("race_dracnid_solar_hell"),gas:z("race_dracnid_solar_gas"),gas_moon:z("race_dracnid_solar_gas_moon"),dwarf:z("race_dracnid_solar_dwarf")},fanaticism:"hoarder",basic:()=>!0},entish:{name:z(Ti("entish")?"race_spruce":"race_entish"),desc:z(Ti("entish")?"race_spruce_desc":"race_entish_desc"),type:"plant",home:z(Ti("entish")?"race_spruce_home":"race_entish_home"),entity:z(Ti("entish")?"race_spruce_entity":"race_entish_entity"),traits:{kindling_kindred:1,pyrophobia:1},solar:{red:z(Ti("entish")?"race_spruce_solar_red":"race_entish_solar_red"),hell:z(Ti("entish")?"race_spruce_solar_hell":"race_entish_solar_hell"),gas:z(Ti("entish")?"race_spruce_solar_gas":"race_entish_solar_gas"),gas_moon:z(Ti("entish")?"race_spruce_solar_gas_moon":"race_entish_solar_gas_moon"),dwarf:z(Ti("entish")?"race_spruce_solar_dwarf":"race_entish_solar_dwarf")},fanaticism:"kindling_kindred",basic:()=>!0},cacti:{name:z("race_cacti"),desc:z("race_cacti_desc"),type:"plant",home:z("race_cacti_home"),entity:z("race_cacti_entity"),traits:{hyper:1,skittish:1},solar:{red:z("race_cacti_solar_red"),hell:z("race_cacti_solar_hell"),gas:z("race_cacti_solar_gas"),gas_moon:z("race_cacti_solar_gas_moon"),dwarf:z("race_cacti_solar_dwarf")},fanaticism:"hyper",basic:()=>!0},pinguicula:{name:z("race_pinguicula"),desc:z("race_pinguicula_desc"),type:"plant",home:z("race_pinguicula_home"),entity:z("race_pinguicula_entity"),traits:{fragrant:1,sticky:1},solar:{red:z("race_pinguicula_solar_red"),hell:z("race_pinguicula_solar_hell"),gas:z("race_pinguicula_solar_gas"),gas_moon:z("race_pinguicula_solar_gas_moon"),dwarf:z("race_pinguicula_solar_dwarf")},fanaticism:"sticky",basic:()=>!0},sporgar:{name:z("race_sporgar"),desc:z("race_sporgar_desc"),type:"fungi",home:z("race_sporgar_home"),entity:z("race_sporgar_entity"),traits:{infectious:1,parasite:1},solar:{red:z("race_sporgar_solar_red"),hell:z("race_sporgar_solar_hell"),gas:z("race_sporgar_solar_gas"),gas_moon:z("race_sporgar_solar_gas_moon"),dwarf:z("race_sporgar_solar_dwarf")},fanaticism:"infectious",basic:()=>!1},shroomi:{name:z("race_shroomi"),desc:z("race_shroomi_desc"),type:"fungi",home:z("race_shroomi_home"),entity:z("race_shroomi_entity"),traits:{toxic:1,nyctophilia:1},solar:{red:z("race_shroomi_solar_red"),hell:z("race_shroomi_solar_hell"),gas:z("race_shroomi_solar_gas"),gas_moon:z("race_shroomi_solar_gas_moon"),dwarf:z("race_shroomi_solar_dwarf")},fanaticism:"toxic",basic:()=>!0},moldling:{name:z("race_moldling"),desc:z("race_moldling_desc"),type:"fungi",home:z("race_moldling_home"),entity:z("race_moldling_entity"),traits:{infiltrator:1,hibernator:1},solar:{red:z("race_moldling_solar_red"),hell:z("race_moldling_solar_hell"),gas:z("race_moldling_solar_gas"),gas_moon:z("race_moldling_solar_gas_moon"),dwarf:z("race_moldling_solar_dwarf")},fanaticism:"infiltrator",basic:()=>!0},mantis:{name:z("race_mantis"),desc:z("race_mantis_desc"),type:"insectoid",home:z("race_mantis_home"),entity:z("race_mantis_entity"),traits:{cannibalize:1,malnutrition:1},solar:{red:z("race_mantis_solar_red"),hell:z("race_mantis_solar_hell"),gas:z("race_mantis_solar_gas"),gas_moon:z("race_mantis_solar_gas_moon"),dwarf:z("race_mantis_solar_dwarf")},fanaticism:"cannibalize",basic:()=>!0},scorpid:{name:z("race_scorpid"),desc:z("race_scorpid_desc"),type:"insectoid",home:z("race_scorpid_home"),entity:z("race_scorpid_entity"),traits:{claws:1,atrophy:1},solar:{red:z("race_scorpid_solar_red"),hell:z("race_scorpid_solar_hell"),gas:z("race_scorpid_solar_gas"),gas_moon:z("race_scorpid_solar_gas_moon"),dwarf:z("race_scorpid_solar_dwarf")},fanaticism:"claws",basic:()=>!0},antid:{name:z("race_antid"),desc:z("race_antid_desc"),type:"insectoid",home:z("race_antid_home"),entity:z("race_antid_entity"),traits:{hivemind:1,tunneler:1},solar:{red:z("race_antid_solar_red"),hell:z("race_antid_solar_hell"),gas:z("race_antid_solar_gas"),gas_moon:z("race_antid_solar_gas_moon"),dwarf:z("race_antid_solar_dwarf")},fanaticism:"hivemind",basic:()=>!0},sharkin:{name:z("race_sharkin"),desc:z("race_sharkin_desc"),type:"aquatic",home:z("race_sharkin_home"),entity:z("race_sharkin_entity"),traits:{blood_thirst:1,apex_predator:1},solar:{red:z("race_sharkin_solar_red"),hell:z("race_sharkin_solar_hell"),gas:z("race_sharkin_solar_gas"),gas_moon:z("race_sharkin_solar_gas_moon"),dwarf:z("race_sharkin_solar_dwarf")},fanaticism:"blood_thirst",basic:()=>!!["oceanic","swamp"].includes(t.city.biome)},octigoran:{name:z("race_octigoran"),desc:z("race_octigoran_desc"),type:"aquatic",home:z("race_octigoran_home"),entity:z("race_octigoran_entity"),traits:{invertebrate:1,suction_grip:1},solar:{red:z("race_octigoran_solar_red"),hell:z("race_octigoran_solar_hell"),gas:z("race_octigoran_solar_gas"),gas_moon:z("race_octigoran_solar_gas_moon"),dwarf:z("race_octigoran_solar_dwarf")},fanaticism:"suction_grip",basic:()=>!!["oceanic","swamp"].includes(t.city.biome)},dryad:{name:z("race_dryad"),desc:z("race_dryad_desc"),type:"fey",home:z("race_dryad_home"),entity:z("race_dryad_entity"),traits:{befuddle:1,environmentalist:1,kindling_kindred:1},solar:{red:z("race_dryad_solar_red"),hell:z("race_dryad_solar_hell"),gas:z("race_dryad_solar_gas"),gas_moon:z("race_dryad_solar_gas_moon"),dwarf:z("race_dryad_solar_dwarf")},fanaticism:"befuddle",basic:()=>!!["forest","swamp","taiga"].includes(t.city.biome)},satyr:{name:z("race_satyr"),desc:z("race_satyr_desc"),type:"fey",home:z("race_satyr_home"),entity:z("race_satyr_entity"),traits:{unorganized:1,musical:1},solar:{red:z("race_satyr_solar_red"),hell:z("race_satyr_solar_hell"),gas:z("race_satyr_solar_gas"),gas_moon:z("race_satyr_solar_gas_moon"),dwarf:z("race_satyr_solar_dwarf")},fanaticism:"musical",basic:()=>!!["forest","swamp","taiga"].includes(t.city.biome)},phoenix:{name:z("race_phoenix"),desc:z("race_phoenix_desc"),type:"heat",home:z("race_phoenix_home"),entity:z("race_phoenix_entity"),traits:{revive:1,slow_regen:1},solar:{red:z("race_phoenix_solar_red"),hell:z("race_phoenix_solar_hell"),gas:z("race_phoenix_solar_gas"),gas_moon:z("race_phoenix_solar_gas_moon"),dwarf:z("race_phoenix_solar_dwarf")},fanaticism:"revive",basic:()=>!!["volcanic","ashland"].includes(t.city.biome)},salamander:{name:z("race_salamander"),desc:z("race_salamander_desc"),type:"heat",home:z("race_salamander_home"),entity:z("race_salamander_entity"),traits:{forge:1,autoignition:1},solar:{red:z("race_salamander_solar_red"),hell:z("race_salamander_solar_hell"),gas:z("race_salamander_solar_gas"),gas_moon:z("race_salamander_solar_gas_moon"),dwarf:z("race_salamander_solar_dwarf")},fanaticism:"forge",basic:()=>!!["volcanic","ashland"].includes(t.city.biome)},yeti:{name:z(Ti("yeti")?"race_snowman":"race_yeti"),desc:z(Ti("yeti")?"race_snowman_desc":"race_yeti_desc"),type:"polar",home:z(Ti("yeti")?"race_snowman_home":"race_yeti_home"),entity:z(Ti("yeti")?"race_snowman_entity":"race_yeti_entity"),traits:{blurry:1,snowy:1},solar:{red:z(Ti("yeti")?"race_snowman_solar_red":"race_yeti_solar_red"),hell:z(Ti("yeti")?"race_snowman_solar_hell":"race_yeti_solar_hell"),gas:z(Ti("yeti")?"race_snowman_solar_gas":"race_yeti_solar_gas"),gas_moon:z(Ti("yeti")?"race_snowman_solar_gas_moon":"race_yeti_solar_gas_moon"),dwarf:z(Ti("yeti")?"race_snowman_solar_dwarf":"race_yeti_solar_dwarf")},fanaticism:"blurry",basic:()=>!!["tundra","taiga"].includes(t.city.biome)},wendigo:{name:z(Ti("wendigo")?"race_krampus":"race_wendigo"),desc:z(Ti("wendigo")?"race_krampus_desc":"race_wendigo_desc"),type:"polar",home:z(Ti("wendigo")?"race_krampus_home":"race_wendigo_home"),entity:z(Ti("wendigo")?"race_krampus_entity":"race_wendigo_entity"),traits:{ravenous:1,ghostly:1,soul_eater:1},solar:{red:z(Ti("wendigo")?"race_krampus_solar_red":"race_wendigo_solar_red"),hell:z(Ti("wendigo")?"race_krampus_solar_hell":"race_wendigo_solar_hell"),gas:z(Ti("wendigo")?"race_krampus_solar_gas":"race_wendigo_solar_gas"),gas_moon:z(Ti("wendigo")?"race_krampus_solar_gas_moon":"race_wendigo_solar_gas_moon"),dwarf:z(Ti("wendigo")?"race_krampus_solar_dwarf":"race_wendigo_solar_dwarf")},fanaticism:"ghostly",basic:()=>!!["tundra","taiga"].includes(t.city.biome)},tuskin:{name:z("race_tuskin"),desc:z("race_tuskin_desc"),type:"sand",home:z("race_tuskin_home"),entity:z("race_tuskin_entity"),traits:{lawless:1,mistrustful:1},solar:{red:z("race_tuskin_solar_red"),hell:z("race_tuskin_solar_hell"),gas:z("race_tuskin_solar_gas"),gas_moon:z("race_tuskin_solar_gas_moon"),dwarf:z("race_tuskin_solar_dwarf")},fanaticism:"lawless",basic:()=>!!["desert","ashland"].includes(t.city.biome)},kamel:{name:z("race_kamel"),desc:z("race_kamel_desc"),type:"sand",home:z("race_kamel_home"),entity:z("race_kamel_entity"),traits:{humpback:1,thalassophobia:1},solar:{red:z("race_kamel_solar_red"),hell:z("race_kamel_solar_hell"),gas:z("race_kamel_solar_gas"),gas_moon:z("race_kamel_solar_gas_moon"),dwarf:z("race_kamel_solar_dwarf")},fanaticism:"humpback",basic:()=>!!["desert","ashland"].includes(t.city.biome)},balorg:{name:z("race_balorg"),desc:z("race_balorg_desc"),type:"demonic",home:z("race_balorg_home"),entity:z("race_balorg_entity"),traits:{fiery:1,terrifying:1,slaver:1},solar:{red:z("race_balorg_solar_red"),hell:z("race_balorg_solar_hell"),gas:z("race_balorg_solar_gas"),gas_moon:z("race_balorg_solar_gas_moon"),dwarf:z("race_balorg_solar_dwarf")},fanaticism:"fiery",basic:()=>"hellscape"===t.city.biome},imp:{name:z("race_imp"),desc:z("race_imp_desc"),type:"demonic",home:z("race_imp_home"),entity:z("race_imp_entity"),traits:{compact:1,conniving:1,pathetic:1},solar:{red:z("race_imp_solar_red"),hell:z("race_imp_solar_hell"),gas:z("race_imp_solar_gas"),gas_moon:z("race_imp_solar_gas_moon"),dwarf:z("race_imp_solar_dwarf")},fanaticism:"conniving",basic:()=>"hellscape"===t.city.biome},seraph:{name:z(Ti("seraph")?"race_cherub":"race_seraph"),desc:z(Ti("seraph")?"race_cherub_desc":"race_seraph_desc"),type:"angelic",home:z(Ti("seraph")?"race_cherub_home":"race_seraph_home"),entity:z(Ti("seraph")?"race_cherub_entity":"race_seraph_entity"),traits:{unified:1,spiritual:1,truthful:1},solar:{red:z(Ti("seraph")?"race_cherub_solar_red":"race_seraph_solar_red"),hell:z(Ti("seraph")?"race_cherub_solar_hell":"race_seraph_solar_hell"),gas:z(Ti("seraph")?"race_cherub_solar_gas":"race_seraph_solar_gas"),gas_moon:z(Ti("seraph")?"race_cherub_solar_gas_moon":"race_seraph_solar_gas_moon"),dwarf:z(Ti("seraph")?"race_cherub_solar_dwarf":"race_seraph_solar_dwarf")},fanaticism:"spiritual",basic:()=>"eden"===t.city.biome},unicorn:{name:z("race_unicorn"),desc:z("race_unicorn_desc"),type:"angelic",home:z("race_unicorn_home"),entity:z("race_unicorn_entity"),traits:{rainbow:1,magnificent:1,noble:1},solar:{red:z("race_unicorn_solar_red"),hell:z("race_unicorn_solar_hell"),gas:z("race_unicorn_solar_gas"),gas_moon:z("race_unicorn_solar_gas_moon"),dwarf:z("race_unicorn_solar_dwarf")},fanaticism:"magnificent",basic:()=>"eden"===t.city.biome},synth:{name:z("race_synth"),desc(){let e=t.race.hasOwnProperty("srace")?t.race.srace:"human";return z("race_synth_desc",[Ki[e].name])},type:"synthetic",home:z("race_synth_home"),entity:z("race_synth_entity"),traits:{imitation:1,emotionless:1,logical:1},solar:{red:z("race_synth_solar_red"),hell:z("race_synth_solar_hell"),gas:z("race_synth_solar_gas"),gas_moon:z("race_synth_solar_gas_moon"),dwarf:z("race_synth_solar_dwarf")},fanaticism:"logical",basic:()=>!1},nano:{name:z("race_nano"),desc:z("race_nano_desc"),type:"synthetic",home:z("race_nano_home"),entity:z("race_nano_entity"),traits:{deconstructor:1,linked:1,shapeshifter:1},solar:{red:z("race_nano_solar_red"),hell:z("race_nano_solar_hell"),gas:z("race_nano_solar_gas"),gas_moon:z("race_nano_solar_gas_moon"),dwarf:z("race_nano_solar_dwarf")},fanaticism:"shapeshifter",basic:()=>!1},ghast:{name:z("race_ghast"),desc:z("race_ghast_desc"),type:"eldritch",home:z("race_ghast_home"),entity:z("race_ghast_entity"),traits:{dark_dweller:1,swift:1,anthropophagite:1},solar:{red:z("race_ghast_solar_red"),hell:z("race_ghast_solar_hell"),gas:z("race_ghast_solar_gas"),gas_moon:z("race_ghast_solar_gas_moon"),dwarf:z("race_ghast_solar_dwarf")},fanaticism:"swift",basic:()=>!1},shoggoth:{name:z("race_shoggoth"),desc:z("race_shoggoth_desc"),type:"eldritch",home:z("race_shoggoth_home"),entity:z("race_shoggoth_entity"),traits:{living_tool:1,bloated:1},solar:{red:z("race_shoggoth_solar_red"),hell:z("race_shoggoth_solar_hell"),gas:z("race_shoggoth_solar_gas"),gas_moon:z("race_shoggoth_solar_gas_moon"),dwarf:z("race_shoggoth_solar_dwarf")},fanaticism:"living_tool",basic:()=>!1},junker:{name:Ti("junker")?z("race_ghoul"):z("race_junker"),desc:Ti("junker")?z("race_ghoul_desc"):z("race_junker_desc"),type:t.race.hasOwnProperty("jtype")?t.race.jtype:"humanoid",home:Ti("junker")?z("race_ghoul_home"):z("race_junker_home"),entity:Ti("junker")?z("race_ghoul_entity"):z("race_junker_entity"),traits:{diverse:1,arrogant:1,angry:1,lazy:1,paranoid:1,greedy:1,puny:1,dumb:1,nearsighted:1,gluttony:1,slow:1,hard_of_hearing:1,pessimistic:1,solitary:1,pyrophobia:1,skittish:1,nyctophilia:1,frail:1,atrophy:1,invertebrate:1,pathetic:1,hibernator:1,freespirit:1,heavy:1,gnawer:1,hooved:1},solar:{red:Ti("junker")?z("race_ghoul_solar_red"):z("race_junker_solar_red"),hell:Ti("junker")?z("race_ghoul_solar_hell"):z("race_junker_solar_hell"),gas:Ti("junker")?z("race_ghoul_solar_gas"):z("race_junker_solar_gas"),gas_moon:Ti("junker")?z("race_ghoul_solar_gas_moon"):z("race_junker_solar_gas_moon"),dwarf:Ti("junker")?z("race_ghoul_solar_dwarf"):z("race_junker_solar_dwarf")},fanaticism:"none",basic:()=>!1},sludge:{name:z("race_sludge"),desc:z("race_sludge_desc"),type:t.race.hasOwnProperty("jtype")?t.race.jtype:"humanoid",home:z("race_sludge_home"),entity:z("race_sludge_entity"),traits:{ooze:.25,diverse:.25,arrogant:.25,angry:.25,lazy:.25,hooved:.25,freespirit:.25,heavy:.25,gnawer:.25,paranoid:.25,greedy:.25,puny:.25,dumb:.25,nearsighted:.25,gluttony:.25,slow:.25,hard_of_hearing:.25,selenophobia:.25,pessimistic:.25,solitary:.25,pyrophobia:.25,skittish:.25,fragrant:.25,nyctophilia:.25,hibernator:.25,frail:.25,atrophy:.25,invertebrate:.25,unorganized:.25,slow_regen:.25,autoignition:.25,snowy:.25,mistrustful:.25,thalassophobia:.25,pathetic:.25,truthful:.25},solar:{red:z("race_sludge_solar_red"),hell:z("race_sludge_solar_hell"),gas:z("race_sludge_solar_gas"),gas_moon:z("race_sludge_solar_gas_moon"),dwarf:z("race_sludge_solar_dwarf")},fanaticism:"ooze",basic:()=>!1},custom:function(){if(t.hasOwnProperty("custom")&&t.custom.hasOwnProperty("race0")){let e={};for(let a=0;aEi[a].val&&(a=t.custom.race0.traits[e]);return{name:t.custom.race0.name,desc:t.custom.race0.desc,type:t.custom.race0.genus,home:t.custom.race0.home,entity:t.custom.race0.entity,traits:e,solar:{red:t.custom.race0.red,hell:t.custom.race0.hell,gas:t.custom.race0.gas,gas_moon:t.custom.race0.gas_moon,dwarf:t.custom.race0.dwarf},fanaticism:a,basic:()=>!1}}return{}}()},Di={organism:{},humanoid:{},carnivore:{},herbivore:{},omnivore:{},small:{},giant:{},reptilian:{},avian:{},insectoid:{},plant:{},fungi:{},aquatic:{},fey:{},heat:{},polar:{},sand:{},demonic:{},angelic:{},synthetic:{},eldritch:{}};function Bi(e,a){let r=1,i=K("theorist",1);!i||"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1-i/100);let s=K("inspirational",0);!s||"farmer"!==a&&"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1+s/100);let n=K("dirty_jobs",2);if(n&&"miner"===a&&(r*=1+n/100),t.race.rejuvenated&&["lumberjack","miner","factory"].includes(a)&&(r*=1.1),"lumberjack"===a&&t.race.evil&&!t.race.soul_eater&&(t.race.living_tool?r*=1+Ei.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.3*t.tech.science:0):r*=1+.4*(t.tech.reclaimer-1)),!t.race.powered||"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1+Ei.powered.vars()[1]/100),t.race.artifical&&"science"===a&&(r*=1+Ei.artifical.vars()[0]/100),t.race.hivemind&&"farmer"!==a&&!t.race.lone_survivor){let i=Ei.hivemind.vars()[0],s=.05;t.race.high_pop&&"army"!==a&&"hellArmy"!==a&&(i*=Ei.high_pop.vars()[0],s=.5/(Ei.hivemind.vars()[0]*Ei.high_pop.vars()[0])),r*=e<=i?e*s+(1-i*s):1-("army"===a||"hellArmy"===a?.99:t.race.high_pop?.985:.98)**(e-i)+1}let c=ts("antid");if(c>0&&(r*=1+(1-("army"===a||"hellArmy"===a?.99:t.race.high_pop?.985:.98)**(e*c/4))/2),t.race.cold_blooded&&"army"!==a&&"hellArmy"!==a&&"factory"!==a&&"science"!==a){switch(t.city.calendar.temp){case 0:r*=1-Ei.cold_blooded.vars()[0]/100;break;case 2:r*=1+Ei.cold_blooded.vars()[1]/100;break;default:r*=1}switch(t.city.calendar.weather){case 0:r*=1-Ei.cold_blooded.vars()[0]/100;break;case 2:r*=1+Ei.cold_blooded.vars()[1]/100;break;default:r*=1}}t.race.cannibalize&&t.city.s_alter&&t.city.s_alter.count>0&&("miner"===a&&t.city.s_alter.mine>0&&(r*=1+Ei.cannibalize.vars()[0]/100),"lumberjack"===a&&t.city.s_alter.harvest>0&&(r*=1+Ei.cannibalize.vars()[0]/100),("army"===a||"hellArmy"===a)&&t.city.s_alter.rage>0&&(r*=1+Ei.cannibalize.vars()[0]/100),"science"===a&&t.city.s_alter.mind>0&&(r*=1+Ei.cannibalize.vars()[0]/100));let o=ts("mantis");o>0&&("miner"===a&&(r*=1+Ei.cannibalize.vars(1)[0]/100*o),"lumberjack"===a&&(r*=1+Ei.cannibalize.vars(1)[0]/100*o),"army"!==a&&"hellArmy"!==a||(r*=1+Ei.cannibalize.vars(1)[0]/100*o),"science"===a&&(r*=1+Ei.cannibalize.vars(1)[0]/100*o)),!t.race.humpback||"miner"!==a&&"lumberjack"!==a||(r*=1+Ei.humpback.vars()[0]/100);let l=ts("kamel");l>0&&("miner"===a||"lumberjack"===a)&&(r*=1+Ei.humpback.vars(1)[0]/100*l),t.city.ptrait.includes("magnetic")&&"miner"===a&&(r*=ss.magnetic.vars()[2]),!t.race.weak||"miner"!==a&&"lumberjack"!==a||(r*=1-Ei.weak.vars()[0]/100),t.race.hydrophilic&&0===t.city.calendar.weather&&t.city.calendar.temp>0&&"factory"!==a&&(r*=.75),t.race.toxic&&"factory"===a&&(r*=1+Ei.toxic.vars()[2]/100);let _=ts("shroomi");if(_>0&&"factory"===a&&(r*=1+Ei.toxic.vars(1)[2]/100*_),t.race.hardy&&"factory"===a&&(r*=1+Ei.hardy.vars()[0]*t.race.hardy/100),t.race.analytical&&"science"===a&&(r*=1+Ei.analytical.vars()[0]*t.race.analytical/100),t.race.ooze&&(r*=1-Ei.ooze.vars()[0]/100),"democracy"===t.civic.govern.type&&(r*=1-Y.democracy()[1]/100),!t.tech.cyber_worker||"lumberjack"!==a&&"miner"!==a||(r*=1.25),"hunting"===a){t.race.tracker&&(r*=1+Ei.tracker.vars()[0]/100);let e=ts("wolven");e>0&&(r*=1+Ei.tracker.vars(1)[0]/100*e),t.race.beast&&(r*=1+(1===t.city.calendar.wind?Ei.beast.vars()[1]:Ei.beast.vars()[0])/100),t.race.apex_predator&&(r*=1+Ei.apex_predator.vars()[1]/100);let a=ts("sharkin");a>0&&(r*=1+Ei.apex_predator.vars(1)[1]/100*a),t.race.fiery&&(r*=1+Ei.fiery.vars()[1]/100);let i=ts("balorg");i>0&&(r*=1+Ei.fiery.vars(1)[1]/100*i),t.race.fragrant&&(r*=1-Ei.fragrant.vars()[0]/100),t.city.ptrait.includes("rage")&&(r*=ss.rage.vars()[1]),t.race.cunning&&(r*=1+Ei.cunning.vars()[0]*t.race.cunning/100),"savanna"===t.city.biome&&(r*=is.savanna.vars()[1]),t.race.dark_dweller&&2===t.city.calendar.weather&&(r*=1-Ei.dark_dweller.vars()[0]/100)}if("magic"===t.race.universe&&(r*="science"===a?.6:"army"===a||"hellArmy"===a?.75:.8,t.race.witch_hunter&&(r*=.75),t.race.hasOwnProperty("casting")&&t.race.casting["hellArmy"===a?"army":a])){let e=t.race.casting["hellArmy"===a?"army":a];t.race.witch_hunter?r*=1+e/(e+75)*2.5:r*=1+e/(e+75)}return t.race.living_tool&&"miner"===a&&(r*=1+Ei.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.12*t.tech.science:0)),t.race.high_pop&&(r=ke(r)),r}function Gi(e){let a=[];Object.keys(Ei).forEach((function(e){"minor"!==Ei[e].type||t.race[e]||a.push(e)})),0===a.length&&Object.keys(Ei).forEach((function(e){"minor"===Ei[e].type&&a.push(e)}));let r=a[Math.floor(m(0,a.length))];return t.race[r]?t.race[r]+=e:t.race[r]=e,r}function Ni(e,a,r){t.race.purgatory[e].hasOwnProperty(a)?(t[e][a]=t.race.purgatory[e][a],delete t.race.purgatory[e][a]):r&&(t[e][a]=r)}function Ri(e,a,r,i){t.race.purgatory[e].hasOwnProperty(a)?(t[e][a]=t.race.purgatory[e][a],delete t.race.purgatory[e][a]):t.race.purgatory[e].hasOwnProperty(r)?(t[e][a]=t.race.purgatory[e][r],delete t.race.purgatory[e][r]):i&&(t[e][a]=i)}function Hi(e,a){t[e].hasOwnProperty(a)&&(t.race.purgatory[e][a]=t[e][a],delete t[e][a])}function Ui(e,a){if(t.race.purgatory[e].hasOwnProperty(a))return t.race.purgatory[e][a]}function Vi(){Wi("Lumber"),Wi("Plywood"),ms(["city-graveyard","city-lumber_yard","city-sawmill"]),gs(["reclaimer","axe","saw"]),Hi("city","sawmill"),Hi("city","graveyard"),Hi("city","lumber_yard"),Hi("tech","axe"),Hi("tech","reclaimer"),Hi("tech","saw"),t.civic.lumberjack.display=!1,t.civic.lumberjack.workers=0,"lumberjack"===t.civic.d_job&&(t.civic.d_job=t.race.carnivore||t.race.soul_eater?"hunter":"unemployed"),t.race.casting&&(t.race.casting.total-=t.race.casting.lumberjack,t.race.casting.lumberjack=0,ki()),t.city.s_alter&&(t.city.s_alter.harvest=0)}function Wi(e){t.resource[e].display=!1,t.race.alchemy&&t.race.alchemy.hasOwnProperty(e)&&(t.resource.Mana.diff+=t.race.alchemy[e],t.race.alchemy[e]=0),t.interstellar.mass_ejector&&t.interstellar.mass_ejector.hasOwnProperty(e)&&(t.interstellar.mass_ejector.total-=t.interstellar.mass_ejector[e],t.interstellar.mass_ejector[e]=0),t.city.nanite_factory&&t.city.nanite_factory.hasOwnProperty(e)&&(t.city.nanite_factory[e]=0),t.portal.transport&&t.portal.transport.cargo.hasOwnProperty(e)&&(t.portal.transport.cargo.used-=t.portal.transport.cargo[e],t.portal.transport.cargo[e]=0),t.tech.foundry&&t.city.foundry.hasOwnProperty(e)&&(t.civic.craftsman.workers-=t.city.foundry[e],t.city.foundry.crafting-=t.city.foundry[e],t.city.foundry[e]=0,sa()),t.resource[e].hasOwnProperty("trade")&&(t.city.market.trade-=Math.abs(t.resource[e].trade),t.resource[e].trade=0),t.resource.Crates.amount+=t.resource[e].crates,t.resource[e].crates=0,t.resource.Containers.amount+=t.resource[e].containers,t.resource[e].containers=0}function Qi(){let e=Ur(Mr.tech.agriculture),a=Ur(Mr.tech.smokehouse),r=Ur(Mr.tech.reclaimer)||Ur(Mr.tech.stone_axe),s=Ur(Mr.tech.alt_lodge),n=Ur(Mr.tech.wind_plant),c=[],o=[];if(!t.race.artifical){if(["agriculture","farm","hunting","s_lodge","wind_plant","compost","soul_eater"].forEach((function(e){Hi("tech",e)})),["silo","farm","mill","windmill","smokehouse","lodge","compost","soul_well"].forEach((function(e){Hi("city",e)})),s){Ni("tech","s_lodge");let e=Ui("tech","farm")>=1||Ui("tech","hunting")>=2?1:0;e>0&&(!t.tech.s_lodge||t.tech.s_lodge=1&&Ri("city","lodge","farm",{count:0})}if(a){Ni("tech","hunting");let e=Ui("tech","farm")>=1||Ui("tech","s_lodge")>=1?2:Ui("tech","agriculture")>=3?1:0;e>0&&(!t.tech.hunting||t.tech.hunting=1&&Ri("city","smokehouse","silo",{count:0}),t.tech.hunting>=2&&!s&&Ri("city","lodge","farm",{count:0})}else o.push("hunting"),c.push("city-smokehouse"),s||o.push("city-lodge");if(e){Ni("tech","farm");let e=Ui("tech","hunting")>=2||Ui("tech","s_lodge")>=1?1:0;e>0&&(!t.tech.farm||t.tech.farm=1?3:Ui("tech","s_lodge")>=1?1:0;a>0&&(!t.tech.agriculture||t.tech.agriculture=1&&Ri("city","farm","lodge",{count:0}),t.tech.agriculture>=3&&Ri("city","silo","smokehouse",{count:0}),t.tech.agriculture>=4&&!n&&Ri("city","mill","windmill",{count:0,on:0})}else o.push("agriculture","farm"),c.push("city-farm","city-silo","city-mill");t.race.soul_eater?(Ni("tech","soul_eater"),Ni("city","soul_well")):(c.push("city-soul_well"),o.push("soul_eater")),t.race.detritivore?(Ni("tech","compost"),Ni("city","compost")):(o.push("compost"),c.push("city-compost")),n?(Ni("tech","wind_plant"),t.tech.wind_plant>=1&&Ri("city","windmill","mill",{count:0,on:0})):(o.push("wind_plant"),c.push("city-windmill"),delete i[z("city_mill_title2")])}let l=[],_=[];!t.race.orbit_decayed&&e&&t.tech.agriculture>=1&&t.city.farm.count>0?l.push("farmer"):_.push("farmer"),t.race.carnivore&&!t.race.herbivore||t.race.soul_eater||t.race.unfathomable?(l.push("hunter"),_.push("unemployed")):(_.push("hunter"),l.push("unemployed")),!t.race.orbit_decayed&&r?l.push("lumberjack"):_.push("lumberjack"),l.forEach((function(e){t.civic[e].display||(t.civic[e].workers=0,t.civic[e].display=!0)})),_.forEach((function(e){t.civic[e].display&&(t.civic.d_job===e&&(t.civic.d_job=l[0]),t.civic[l[0]].workers+=t.civic[e].workers,t.civic[e].workers=0,t.civic[e].display=!1)})),t.race.casting&&(e||(t.race.casting.total-=t.race.casting.farmer,t.race.casting.farmer=0),ki()),ms(c),gs(o),Na("Food")}function Ji(a){switch(a){case"high_pop":t.resource[t.race.species].amount=Math.round(t.resource[t.race.species].amount*Ei.high_pop.vars()[0]),t.civic.hasOwnProperty("garrison")&&(t.civic.garrison.workers=Math.round(t.civic.garrison.workers*Ei.high_pop.vars()[0]));break;case"kindling_kindred":if(t.race.smoldering)break;Vi();break;case"smoldering":if(t.resource.Chrysotile.display=!0,t.race.kindling_kindred)break;Vi();break;case"forge":ki();break;case"soul_eater":aa("lumberjack");case"detritivore":case"carnivore":case"herbivore":Qi();break;case"unfathomable":for(Qi(),t.city.hasOwnProperty("surfaceDwellers")||(t.city.surfaceDwellers=[]);t.city.surfaceDwellers.lengthEi.unfathomable.vars()[0]&&(t.city.surfaceDwellers.length=Ei.unfathomable.vars()[0]),t.race.psychic&&cs();break;case"flier":Na("Stone"),Na("Brick"),t.resource.Cement.display=!1,t.civic.cement_worker.display=!1,t.civic.cement_worker.workers=0,Hi("tech","cement"),Hi("city","cement_plant");break;case"sappy":"quarry_worker"===t.civic.d_job&&(t.civic.d_job="unemployed"),t.civic.quarry_worker.display=!1,t.civic.quarry_worker.workers=0,Na("Stone"),Hi("tech","hammer"),Hi("city","rock_quarry");break;case"apex_predator":gs(["armor"]),Hi("tech","armor");break;case"environmentalist":delete i[z("city_coal_power")],delete i[z("city_mana_engine")],delete i[z("city_oil_power")];break;case"terrifying":Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),t.settings.showMarket=!1,0===t.settings.marketTabs&&(t.settings.marketTabs=1),ms(["city-trade"]),gs(["trade"]),Hi("tech","trade"),Hi("city","trade");break;case"slaver":Ni("tech","slaves"),t.tech.slaves>=1&&(Ni("city","slave_pen",{count:0,slaves:0}),t.city.slave_pen.count>0&&!t.race.orbit_decayed&&(t.resource.Slave.display=!0));break;case"cannibalize":Ni("tech","sacrifice"),t.tech.mining&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0});break;case"magnificent":t.tech.theology>=2&&Ni("city","shrine",{count:0,morale:0,metal:0,know:0,tax:0});break;case"unified":t.tech.world_control=1,t.tech.unify=2,Ss($("#garrison")),Ss($("#c_garrison")),he($("#garrison"),!0),he($("#c_garrison"),!1);for(let e=0;e<3;e++){if(t.civic.foreign[`gov${e}`].occ){let a=ta("federation"===t.civic.govern.type?15:20);t.civic.garrison.max+=a,t.civic.garrison.workers+=a,t.civic.foreign[`gov${e}`].occ=!1}t.civic.foreign[`gov${e}`].buy=!1,t.civic.foreign[`gov${e}`].anx=!1,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none"}D("spy"),D("spyop");break;case"noble":t.civic.taxes.tax_rate<10?t.civic.taxes.tax_rate=10:t.civic.taxes.tax_rate>20&&(t.civic.taxes.tax_rate=20);break;case"toxic":"troll"===t.race.species&&t.tech.science&&t.tech.science>=8&&qn("godwin");break;case"thalassophobia":ms(["city-wharf"]),gs(["wharf"]),Hi("city","wharf");break;case"hooved":t.resource.Horseshoe.display=!0,t.race.hasOwnProperty("shoecnt")||(t.race.shoecnt=0);break;case"slow":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w?(ds("stop"),ds("start")):window.location.reload();case"hyper":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w?(ds("stop"),ds("start")):window.location.reload();case"calm":t.tech.primitive>=3&&(Ni("city","meditation",{count:0}),t.race.orbit_decayed||(t.resource.Zen.display=!0));break;case"blood_thirst":t.race.blood_thirst_count=1;break;case"deconstructor":t.resource.Nanite.display=!0,Ni("city","nanite_factory",{count:1,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Bolognium:0,Orichalcum:0});break;case"shapeshifter":Yi(!1,!0);break;case"imitation":Xi(!0);break;case"evil":Na("Lumber"),Na("Furs"),Na("Plywood");break;case"psychic":t.tech.psychic&&(t.resource.Energy.display=!0,t.settings.showPsychic=!0);break;case"ooze":t.tech.high_tech||"custom"===t.race.species||"sludge"===t.race.species||(t.race.gross_enabled=1),Ts(!0)}}function Zi(a,r){switch(a){case"high_pop":t.resource[t.race.species].amount=Math.round(t.resource[t.race.species].amount/Ei.high_pop.vars(r)[0]),t.civic.hasOwnProperty("garrison")&&(t.civic.garrison.workers=Math.round(t.civic.garrison.workers/Ei.high_pop.vars(r)[0]));break;case"kindling_kindred":if(t.race.smoldering)break;t.resource.Lumber.display=!0,t.tech.foundry&&(t.resource.Plywood.display=!0),t.race.casting&&ki(),Ni("city","sawmill"),Ni("city","graveyard"),Ni("city","lumber_yard"),Ni("tech","axe"),Ni("tech","reclaimer"),Ni("tech","saw"),!t.tech.axe&&!t.tech.reclaimer||t.race.orbit_decayed||(t.civic.lumberjack.display=!0);break;case"smoldering":if(Wi("Chrysotile"),t.race.kindling_kindred)break;t.resource.Lumber.display=!0,t.tech.foundry&&(t.resource.Plywood.display=!0),t.race.casting&&ki(),Ni("city","sawmill"),Ni("city","graveyard"),Ni("city","lumber_yard"),Ni("tech","axe"),Ni("tech","reclaimer"),Ni("tech","saw"),!t.tech.axe&&!t.tech.reclaimer||t.race.orbit_decayed||(t.civic.lumberjack.display=!0);break;case"forge":ki();break;case"soul_eater":aa("lumberjack");case"detritivore":case"carnivore":case"herbivore":case"unfathomable":Qi(),t.race.psychic&&cs();break;case"flier":Na("Stone"),Na("Brick"),Ni("tech","cement"),t.tech.cement&&(Ni("city","cement_plant"),t.resource.Cement.display=!0,t.civic.cement_worker.display=!0);break;case"sappy":Na("Stone"),Ni("tech","hammer"),t.tech.mining>=1&&(Ni("city","rock_quarry",{count:0,asbestos:0}),(t.city.rock_quarry&&t.city.rock_quarry.count>0||t.race.lone_survivor)&&(t.civic.quarry_worker.display=!0));break;case"apex_predator":Ni("tech","armor");break;case"environmentalist":delete i[z("city_hydro_power")],delete i[z("city_wind_power")];break;case"terrifying":t.settings.showMarket=!0,Ni("tech","trade"),Ni("city","trade");break;case"slaver":ms(["city-slave_pen"]),gs(["slaves"]),Hi("city","slave_pen"),Hi("tech","slaves"),t.resource.Slave.amount=0,t.resource.Slave.max=0,t.resource.Slave.display=!1,D("slave");break;case"cannibalize":ms(["city-s_alter"]),gs(["sacrifice"]),Hi("tech","sacrifice"),delete t.city.s_alter,D("sacrifice");break;case"magnificent":ms(["city-shrine"]),Hi("city","shrine");break;case"thalassophobia":t.tech.wharf&&Ni("city","wharf",{count:0});break;case"hooved":ms(["city-horseshoe","space-horseshoe"]),t.resource.Horseshoe.display=!1,D("horseshoe");break;case"slow":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w?(ds("stop"),ds("start")):window.location.reload();case"hyper":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w?(ds("stop"),ds("start")):window.location.reload();case"calm":ms(["city-meditation"]),t.resource.Zen.display=!1,Hi("city","meditation");break;case"blood_thirst":delete t.race.blood_thirst_count;break;case"deconstructor":ms(["city-nanite_factory"]),t.resource.Nanite.display=!1,Hi("city","nanite_factory");break;case"shapeshifter":Ss($("#sshifter")),Yi();break;case"imitation":t.race.iTraits&&(Object.keys(t.race.iTraits).forEach((function(e){if("imitation"!==e)if(0===t.race.iTraits[e]){let a=t.race[e];delete t.race[e],Zi(e,a)}else t.race[e]=t.race.iTraits[e]})),delete t.race.iTraits);break;case"evil":Na("Lumber"),Na("Furs"),Na("Plywood");break;case"psychic":t.resource.Energy.display=!1,t.settings.showPsychic=!1;break;case"ooze":delete t.race.gross_enabled,Ts(!0)}}function Xi(e){if(t.race.imitation&&t.race.srace){t.race.iTraits||(t.race.iTraits={}),t.race.shapeshifter&&Yi(t.race.ss_genus===Ki[t.race.srace].type&&"none",!0);let a=[];if(Object.keys(Li[Ki[t.race.srace].type]).forEach((function(e){t.race[e]||a.push(e)})),"custom"===t.race.srace){let e=["evil","evil"];Object.keys(Ki[t.race.srace].traits).forEach((function(t){Ei[t].val>Ei[e[0]].val?e[0]=t:Ei[t].val=0?t.race[e]=Ei.shapeshifter.vars()[0]:t.race[e]=Ei.shapeshifter.vars()[1],Ji(e),r.push(e))})),t.race.ss_genus=e),a){Ss($("#sshifter")),t.race.ss_genus=t.race.hasOwnProperty("ss_genus")?t.race.ss_genus:"none";let e="";Object.keys(Li).forEach((function(a){"synthetic"!==a&&"eldritch"!==a&&a!==Ki[t.race.species].type&&(!t.race.imitation||a!==Ki[t.race.srace].type)&&t.stats.achieve[`genus_${a}`]&&t.stats.achieve[`genus_${a}`].l>0&&(e+=`{{ '${a}' | genus }}`)})),$("#sshifter").append(`${z("trait_shapeshifter_name")}: \n \n {{ 'none' | genus }}${e}\n `),Cs({el:"#sshifter",data:t.race,methods:{setShape(e){Yi(e)}},filters:{genus:e=>z(`genelab_genus_${e}`)}})}t.race.ss_traits=r}function es(e,a){if(a=a||{},t.race[e]&&!a.force)switch(t.race[e]){case.25:return t.race[e]=a.down?.25:.5,!a.down;case.5:return t.race[e]=a.down?.25:1,!0;case 1:return t.race[e]=a.down?.5:2,!0;case 2:return t.race[e]=a.down?1:3,!0;case 3:return t.race[e]=a.down?2:3,!!a.down}else if(a.set)return t.race[e]=a.set,!0;return!1}function ts(e){if(t.race.unfathomable&&t.city.surfaceDwellers&&t.city.surfaceDwellers.includes(e)&&t.city.captive_housing){let a=t.city.surfaceDwellers.indexOf(e),r=t.city.captive_housing[`race${a}`];if(r>100&&(r=100),r>t.civic.torturer.workers){let e=r-t.civic.torturer.workers;r-=Math.ceil(e/3)}return r/100*((t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0)/5)}return 0}function as(e,a){switch(e){case"name":{let e={hooved:rs(!1),promiscuous:t.race.artifical?z("trait_promiscuous_synth_name"):Ei.promiscuous.name};return a?e[a]?e[a]:Ei[a].name:e}case"desc":{let e={hooved:rs(!0),promiscuous:t.race.artifical?z("trait_promiscuous_synth"):Ei.promiscuous.desc};return a?e[a]?e[a]:Ei[a].desc:e}}}function rs(e){return t.race.sludge?z(e?"trait_hooved_slime":"trait_hooved_slime_name"):["cath","wolven","dracnid","seraph","cyclops","kobold","tuskin","sharkin"].includes(t.race.species)?z(e?`trait_hooved_${t.race.species}`:`trait_hooved_${t.race.species}_name`):["humanoid","avian","plant","fungi","reptilian","fey","synthetic"].includes(Ki[t.race.species].type)?z(e?`trait_hooved_${Ki[t.race.species].type}`:`trait_hooved_${Ki[t.race.species].type}_name`):e?Ei.hooved.desc:Ei.hooved.name}Object.keys(Di).forEach((function(e){let t="organism"===e?"humanoid":e;Di[e].solar={titan:z(`genus_${t}_solar_titan`),enceladus:z(`genus_${t}_solar_enceladus`),triton:z(`genus_${t}_solar_triton`),eris:z(`genus_${t}_solar_eris`)}}));const is={grassland:{label:z("biome_grassland_name"),desc:z("biome_grassland"),vars:()=>t.race.rejuvenated?[1.25]:[1.2],wiki:["%"]},oceanic:{label:z("biome_oceanic_name"),desc:z("biome_oceanic"),vars:()=>t.race.rejuvenated?[1.25,1.12,.92]:[1.12,1.06,.95],wiki:["%","%","%"]},forest:{label:z("biome_forest_name"),desc:z("biome_forest"),vars:()=>t.race.rejuvenated?[1.35]:[1.2],wiki:["%"]},desert:{label:z("biome_desert_name"),desc:z("biome_desert"),vars:()=>t.race.rejuvenated?[1.35,1.18,.6]:[1.2,1.1,.75],wiki:["%","%","%"]},volcanic:{label:z("biome_volcanic_name"),desc:z("biome_volcanic"),vars:()=>t.race.rejuvenated?[.8,1.25,1.15]:[.9,1.12,1.08],wiki:["%","%","%"]},tundra:{label:z("biome_tundra_name"),desc:z("biome_tundra"),vars:()=>t.race.rejuvenated?[1.5,.8]:[1.25,.9],wiki:["%","%"]},savanna:{label:z("biome_savanna_name"),desc:z("biome_savanna"),vars:()=>t.race.rejuvenated?[1.18,1.25,.75]:[1.1,1.18,.8],wiki:["%","%","%"]},swamp:{label:z("biome_swamp_name"),desc:z("biome_swamp"),vars:()=>t.race.rejuvenated?[1.6,1.35,1.15,.78]:[1.4,1.25,1.1,.88],wiki:["%","%","%","%"]},ashland:{label:z("biome_ashland_name"),desc:z("biome_ashland"),vars:()=>t.race.rejuvenated?[.55,1.35,1.2]:[.62,1.25,1.1],wiki:["%","%","%"]},taiga:{label:z("biome_taiga_name"),desc:z("biome_taiga"),vars:()=>t.race.rejuvenated?[1.2,1.65,.88]:[1.1,1.5,.92],wiki:["%","%","%"]},hellscape:{label:z("biome_hellscape_name"),desc:z("biome_hellscape"),vars:()=>t.race.rejuvenated?[.2]:[.25],wiki:["%"]},eden:{label:z("biome_eden_name"),desc:z("biome_eden")}},ss={toxic:{label:z("planet_toxic"),desc:z("planet_toxic_desc"),vars:()=>t.race.rejuvenated?[2,1.5]:[1,1.25],wiki:["A","-%"]},mellow:{label:z("planet_mellow"),desc:z("planet_mellow_desc"),vars:()=>t.race.rejuvenated?[2,3,.88]:[1.5,2,.9],wiki:["%","A","%"]},rage:{label:z("planet_rage"),desc:z("planet_rage_desc"),vars:()=>t.race.rejuvenated?[1.1,1.05,1]:[1.05,1.02,1],wiki:["%","%","A"]},stormy:{label:z("planet_stormy"),desc:z("planet_stormy_desc")},ozone:{label:z("planet_ozone"),desc:z("planet_ozone_desc"),vars:()=>t.race.rejuvenated?[.18]:[.25],wiki:["-A"]},magnetic:{label:z("planet_magnetic"),desc:z("planet_magnetic_desc"),vars:()=>t.race.rejuvenated?[2,150,.98]:[1,100,.985],wiki:["A","A","%"]},trashed:{label:z("planet_trashed"),desc:z("planet_trashed_desc"),vars:()=>t.race.rejuvenated?[.8,1.2]:[.75,1],wiki:["%","%"]},elliptical:{label:z("planet_elliptical"),desc:z("planet_elliptical_desc")},flare:{label:z("planet_flare"),desc:z("planet_flare_desc")},dense:{label:z("planet_dense"),desc:z("planet_dense_desc"),vars:()=>t.race.rejuvenated?[1.5,1.2,1.35]:[1.2,1,1.2],wiki:["%","A","%"]},unstable:{label:z("planet_unstable"),desc:z("planet_unstable_desc")},permafrost:{label:z("planet_permafrost"),desc:z("planet_permafrost_desc"),vars:()=>t.race.rejuvenated?[.7,125]:[.75,100],wiki:["%","A"]},retrograde:{label:z("planet_retrograde"),desc:z("planet_retrograde_desc")}};function ns(e){e=e||[];let t=Object.keys(Ki).filter((function(t){return Ki[t].basic()&&!e.includes(t)}));return t[en(t)]}function cs(){if(!t.settings.tabLoad&&(2!==t.settings.civTabs||6!==t.settings.govTabs))return;let e=$("#psychicPowers");Ss(e),t.race.psychic&&t.tech.psychic&&(function(e){let a=$('
                  ');e.append(a),a.append($(`
                  ${z("psychic_boost_title")}
                  `));let r=$("
                  ");a.append(r);let i="";if(Object.keys(Fa).forEach((function(e){t.resource[e].display&&(i+=`${t.resource[e].name}`)})),r.append(`
                  ${i}
                  `),a.append('
                  '),t.tech.psychic>=4){let e=$(`
                  ${z("psychic_channel")}
                  `),t=$('{{ c.boost }}'),r=$(`«`),i=$(`»`);e.append(r),e.append(t),e.append(i),a.append(e)}let s=t.tech.psychic>=5?60:75,n=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;Cs({el:"#psychicBoost",data:{b:t.race.psychicPowers.boost,c:t.tech.psychic>=4?t.race.psychicPowers.channel:{}},methods:{boostVal(){t.resource.Energy.amount>=s&&(t.resource.Energy.amount-=s,t.race.psychicPowers.boostTime=72*n)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.boost--}},filters:{boost:e=>z("psychic_boost_button",[t.resource[e]?t.resource[e].name:"N/A",s]),boostTime:()=>t.race.psychicPowers.boostTime>0?z("psychic_boost_time",[t.race.psychicPowers.boostTime]):""}});const c=document.getElementById("psyhscrolltarget");c.addEventListener("wheel",(e=>{e.preventDefault(),c.scrollLeft+=e.deltaY})),ls("psychicBoost",(function(){return z("psychic_boost_desc",[Ei.psychic.vars()[3]])}),{elm:"#psychicBoost > div > button"})}(e),function(e){let a=$('
                  ');e.append(a),a.append($(`
                  ${z("psychic_murder_title")}
                  `)),a.append('
                  ');let r=t.tech.psychic>=5?8:10;Cs({el:"#psychicKill",data:{},methods:{murder(){t.resource.Energy.amount>=r&&t.resource[t.race.species].amount>=1&&(t.resource.Energy.amount-=r,t.resource[t.race.species].amount--,t.stats.psykill++,t.race.anthropophagite&&$s("Food",1e4*Ei.anthropophagite.vars()[0]),10===t.stats.psykill&&cs())}},filters:{kill:()=>z("psychic_murder_button",[r])}}),ls("psychicKill",(function(){return z("psychic_murder_desc")}),{elm:"#psychicKill > div > button"})}(e),t.tech.psychic>=2&&function(e){let a=$('
                  ');if(e.append(a),a.append($(`
                  ${z("psychic_assault_title")}
                  `)),a.append('
                  '),t.tech.psychic>=4){let e=$(`
                  ${z("psychic_channel")}
                  `),t=$('{{ assault }}'),r=$(`«`),i=$(`»`);e.append(r),e.append(t),e.append(i),a.append(e)}let r=t.tech.psychic>=5?36:45,i=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;Cs({el:"#psychicAssault",data:t.tech.psychic>=4?t.race.psychicPowers.channel:{},methods:{boostVal(){t.resource.Energy.amount>=r&&(t.resource.Energy.amount-=r,t.race.psychicPowers.assaultTime=72*i)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.assault--}},filters:{boost:()=>z("psychic_boost_button",[z("psychic_attack"),r]),boostTime:()=>t.race.psychicPowers.assaultTime>0?z("psychic_boost_time",[t.race.psychicPowers.assaultTime]):""}}),ls("psychicAssault",(function(){return z("psychic_assault_desc",[Ei.psychic.vars()[3]])}),{elm:"#psychicAssault > div > button"})}(e),t.tech.psychic>=3&&(t.race.psychicPowers.cash||(t.race.psychicPowers.cash=0),function(e){let a=$('
                  ');if(e.append(a),a.append($(`
                  ${z("psychic_profit_title")}
                  `)),a.append('
                  '),t.tech.psychic>=4){let e=$(`
                  ${z("psychic_channel")}
                  `),t=$('{{ cash }}'),r=$(`«`),i=$(`»`);e.append(r),e.append(t),e.append(i),a.append(e)}let r=t.tech.psychic>=5?52:65,i=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;Cs({el:"#psychicFinance",data:t.tech.psychic>=4?t.race.psychicPowers.channel:{},methods:{boostVal(){t.resource.Energy.amount>=r&&(t.resource.Energy.amount-=r,t.race.psychicPowers.cash=72*i)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.cash--}},filters:{boost:()=>z("psychic_boost_button",[z("psychic_profit"),r]),boostTime:()=>t.race.psychicPowers.cash>0?z("psychic_boost_time",[t.race.psychicPowers.cash]):""}}),ls("psychicFinance",(function(){return z("psychic_profit_desc",[Ei.psychic.vars()[3]])}),{elm:"#psychicFinance > div > button"})}(e)),t.tech.psychicthrall&&t.tech.unfathomable&&t.race.unfathomable&&(t.tech.psychicthrall>=2&&function(e){let a=$('
                  ');e.append(a),a.append($(`
                  ${z("psychic_stun_title")}
                  `)),a.append('
                  ');let r=t.tech.psychic>=5?80:100;Cs({el:"#psychicCapture",data:{},methods:{stun(){if(t.resource.Energy.amount>=r&&t.tech.unfathomable){let e=0;if(t.city.hasOwnProperty("surfaceDwellers"))for(let a=0;az("psychic_stun_button",[r])}}),ls("psychicCapture",(function(){return z("psychic_stun_desc")}),{elm:"#psychicCapture > div > button"})}(e),function(e){let a=$('
                  ');e.append(a),a.append($(`
                  ${z("psychic_mind_break_title")}
                  `)),a.append('
                  ');let r=t.tech.psychic>=5?64:80;Cs({el:"#psychicMindBreak",data:{},methods:{breakMind(){if(t.resource.Energy.amount>=r&&t.tech.unfathomable){let e=[];if(t.city.hasOwnProperty("surfaceDwellers"))for(let a=0;a0&&e.push(a);if(e.length>0){let a=e[Math.rand(0,e.length)];t.city.captive_housing[`jailrace${a}`]--,t.city.captive_housing[`race${a}`]++,t.resource.Energy.amount-=r}}}},filters:{break:()=>z("psychic_mind_break_button",[r])}}),ls("psychicMindBreak",(function(){return z("psychic_mind_break_desc")}),{elm:"#psychicMindBreak > div > button"})}(e)))}var os=!1;function ls(e,a,r){r||(r={}),r.hasOwnProperty("elm")||(r.elm="#"+e),r.hasOwnProperty("bind")||(r.bind=!0),r.hasOwnProperty("unbind")||(r.unbind=!0),r.hasOwnProperty("placement")||(r.placement="bottom"),r.bind&&$(r.elm).on(r.bind_mouse_enter?"mouseenter":"mouseover",(function(){(os||$("#popper").length>0)&&_s();let i=r.wide?" wide":"",s=r.classes?r.classes:"has-background-light has-text-dark pop-desc";var n=$(`
                  `);r.attach?$(r.attach).append(n):$("#main").append(n),a&&n.append("function"==typeof a?a({this:this,popper:n}):a),os=Popper.createPopper(r.self?this:$(r.elm)[0],document.querySelector("#popper"),{placement:r.placement,modifiers:[{name:"flip",enabled:!0},{name:"offset",options:{offset:r.offset?r.offset:[0,0]}}]}),n.show(),r.hasOwnProperty("in")&&"function"==typeof r.in&&r.in({this:this,popper:n,id:"popper"}),cn("firework")&&t[t.race.cataclysm||t.race.orbit_decayed?"space":"city"].firework.on>0&&$(n).append('')})),r.unbind&&("ontouchstart"in document.documentElement&&navigator.userAgent.match(t.settings.touch)?$(r.elm).on("touchend",(function(e){_s(),r.hasOwnProperty("out")&&"function"==typeof r.out&&r.out({this:this,popper:$("#popper"),id:"popper"})})):$(r.elm).on(r.bind_mouse_enter?"mouseleave":"mouseout",(function(){_s(),r.hasOwnProperty("out")&&"function"==typeof r.out&&r.out({this:this,popper:$("#popper"),id:"popper"})})))}function _s(e){e&&$("#popper").data("id")!==e||($("#popper").hide(),os&&(os.destroy(),os=!1),Ss($("#popper"),!0))}function ds(e){switch(e){case"stop":P.w?P.w.postMessage({loop:"clear"}):(clearInterval(j.main_loop),clearInterval(j.mid_loop),clearInterval(j.long_loop)),P.s=!1;break;case"start":if(P.resetTimers(),t.settings.gameSpeed=1,ps(),t.settings.at>0&&(t.settings.gameSpeed*=t.settings.atMultiplier),t.race.slow){const e=1-Ei.slow.vars()[0]/100;t.settings.gameSpeed*=e}if(t.race.hyper){const e=1+Ei.hyper.vars()[0]/100;t.settings.gameSpeed*=e}for(let e in P.timers)P.timers[e]/=t.settings.gameSpeed;P.w?(P.w.postMessage({loop:"short",period:P.timers.main}),P.w.postMessage({loop:"mid",period:P.timers.mid}),P.w.postMessage({loop:"long",period:P.timers.long})):(j.main_loop=setInterval((function(){fastLoop()}),P.timers.main),j.mid_loop=setInterval((function(){midLoop()}),P.timers.mid),j.long_loop=setInterval((function(){longLoop()}),P.timers.long)),P.s=!0}}function ps(){if(!t.stats.hasOwnProperty("current"))return;const e=Date.now()-t.stats.current;if(e>=12e4){const a=t.settings.at+2*e/3,r=288e5;t.settings.at=Math.min(a,r)}}function us(e,t){let a=Si(),r=[];switch(e){case"power":r=["city:transmitter","prtl_ruins:arcology","city:apartment","int_alpha:habitat","int_alpha:luxury_condo","spc_red:spaceport","spc_titan:titan_spaceport","spc_titan:electrolysis","int_alpha:starport","spc_dwarf:shipyard","spc_titan:ai_core2","spc_eris:drone_control","spc_titan:ai_colonist","int_blackhole:s_gate","gxy_gateway:starbase","spc_triton:fob","spc_enceladus:operating_base","spc_enceladus:zero_g_lab","spc_titan:sam","gxy_gateway:ship_dock","prtl_ruins:hell_forge","int_neutron:stellar_forge","int_neutron:citadel","tau_home:orbital_station","tau_red:orbital_platform","tau_gas:refueling_station","tau_home:tau_farm","tau_gas:ore_refinery","tau_gas:whaling_station","city:coal_mine","spc_moon:moon_base","spc_red:red_tower","spc_home:nav_beacon","int_proxima:xfer_station","gxy_stargate:telemetry_beacon","int_nebula:nexus","gxy_stargate:gateway_depot","spc_dwarf:elerium_contain","spc_gas:gas_mining","spc_belt:space_station","spc_gas_moon:outpost","gxy_gorddon:embassy","gxy_gorddon:dormitory","gxy_alien1:resort","spc_gas_moon:oil_extractor","int_alpha:int_factory","city:factory","spc_red:red_factory","spc_dwarf:world_controller","prtl_fortress:turret","prtl_badlands:war_drone","city:wardenclyffe","city:biolab","city:mine","city:rock_quarry","city:cement_plant","city:sawmill","city:mass_driver","int_neutron:neutron_miner","prtl_fortress:war_droid","prtl_pit:soul_forge","gxy_chthonian:excavator","int_blackhole:far_reach","prtl_badlands:sensor_drone","prtl_badlands:attractor","city:metal_refinery","gxy_stargate:gateway_station","gxy_alien1:vitreloy_plant","gxy_alien2:foothold","gxy_gorddon:symposium","int_blackhole:mass_ejector","city:casino","spc_hell:spc_casino","tau_home:tauceti_casino","prtl_fortress:repair_droid","gxy_stargate:defense_platform","prtl_ruins:guard_post","prtl_lake:cooling_tower","prtl_lake:harbour","prtl_spire:purifier","prtl_ruins:archaeology","prtl_pit:gun_emplacement","prtl_gate:gate_turret","prtl_pit:soul_attractor","prtl_gate:infernite_mine","int_sirius:ascension_trigger","spc_kuiper:orichalcum_mine","spc_kuiper:elerium_mine","spc_kuiper:uranium_mine","spc_kuiper:neutronium_mine","spc_dwarf:m_relay","tau_home:tau_factory","tau_home:infectious_disease_lab","tau_home:alien_outpost","tau_gas:womling_station","spc_red:atmo_terraformer","tau_star:matrix","tau_home:tau_cultural_center","prtl_pit:soul_capacitor","city:replicator"];break;case"moon":r=["spc_moon:helium_mine","spc_moon:iridium_mine","spc_moon:observatory"];break;case"red":r=["spc_red:living_quarters","spc_red:exotic_lab","spc_red:red_mine","spc_red:fabrication","spc_red:biodome","spc_red:vr_center"];break;case"belt":r=["spc_belt:elerium_ship","spc_belt:iridium_ship","spc_belt:iron_ship"];break;case"alpha":r=["int_alpha:fusion","int_alpha:mining_droid","int_alpha:processing","int_alpha:laboratory","int_alpha:g_factory","int_alpha:exchange","int_alpha:zoo"];break;case"nebula":r=["int_nebula:harvester","int_nebula:elerium_prospector"];break;case"gateway":r=["gxy_gateway:bolognium_ship","gxy_gateway:dreadnought","gxy_gateway:cruiser_ship","gxy_gateway:frigate_ship","gxy_gateway:corvette_ship","gxy_gateway:scout_ship"];break;case"alien2":r=["gxy_alien2:armed_miner","gxy_alien2:ore_processor","gxy_alien2:scavenger"];break;case"lake":r=["prtl_lake:bireme","prtl_lake:transport"];break;case"spire":r=["prtl_spire:port","prtl_spire:base_camp","prtl_spire:mechbay"];break;case"titan":r=["spc_titan:titan_quarters","spc_titan:titan_mine","spc_titan:g_factory","spc_titan:decoder"];break;case"enceladus":r=["spc_enceladus:water_freighter","spc_enceladus:operating_base","spc_enceladus:zero_g_lab"];break;case"eris":r=["spc_eris:shock_trooper","spc_eris:tank"];break;case"tau_home":r=["tau_home:colony","tau_home:tau_factory","tau_home:mining_pit","tau_home:infectious_disease_lab"];break;case"tau_red":r=["tau_red:womling_village","tau_red:womling_farm","tau_red:overseer","tau_red:womling_mine","tau_red:womling_fun","tau_red:womling_lab"];break;case"tau_roid":r=["tau_roid:mining_ship","tau_roid:whaling_ship"]}t&&(a[e].l.length=0),r.forEach((function(t){a[e].l.includes(t)||a[e].l.push(t)})),a[e].l.length>r.length&&a[e].l.forEach((function(t){r.includes(t)||a[e].l.splice(a[e].l.indexOf(t),1)}))}function hs(e,a,r,i,s){if(i=i||[],s||i.includes("all")||i.push("all"),a=a||"warning",i.includes(u.view)){let r=$('

                  '+e+"

                  ");$("#msgQueueLog").prepend(r),$("#msgQueueLog").children().length>t.settings.msgFilters[u.view].max&&$("#msgQueueLog").children().last().remove()}i.forEach((function(r){u[r].unshift({msg:e,color:a}),u[r].length>t.settings.msgFilters[r].max&&u[r].pop()})),r||i.forEach((function(r){t.lastMsg[r]&&(t.lastMsg[r].unshift({m:e,c:a}),t.lastMsg[r].length>t.settings.msgFilters[r].save&&t.lastMsg[r].splice(t.settings.msgFilters[r].save))}))}function ms(e){for(let a=t.queue.queue.length-1;a>=0;a--)e.includes(t.queue.queue[a].id)&&t.queue.queue.splice(a,1)}function gs(e){for(let a=t.r_queue.queue.length-1;a>=0;a--)e.includes(Mr.tech[t.r_queue.queue[a].type].grant[0])&&t.r_queue.queue.splice(a,1)}function vs(){let e=t.tech.queue>=2?t.tech.queue>=3?8:5:3;t.stats.feat.journeyman&&t.stats.feat.journeyman>=2&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>=2&&(e+=Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman)>=4?2:1),t.genes.queue&&t.genes.queue>=2&&(e*=2);let a=K("pragmatist",0);a&&(e=Math.round(e*(1+a/100))),t.queue.max=e}function fs(){let e=3;if(t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0){let a=Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman);e+=a>=3?a>=5?3:2:1}t.genes.queue&&t.genes.queue>=2&&(e*=2);let a=K("theorist",0);a&&(e=Math.round(e*(1+a/100))),t.r_queue.max=e}function ys(){!function(){let e=$("#buildQueue .buildList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}(),Ss($("#buildQueue")),$("#buildQueue").append($(`\n

                  ${z("building_queue")} ({{ | used_q }}/{{ max }})

                  \n \n `));let e=$('
                    ');$("#buildQueue").append(e),e.append($('
                  • {{ item.label }}{{ item.q | count }} [{{ item.time | time }}{{ item.t_max | max_t(item.time) }}]
                  • '));try{Cs({el:"#buildQueue",data:t.queue,methods:{remove(e){let a=y();for(let r=0;r0&&(t.queue.queue[e].q-=t.queue.queue[e].qs),t.queue.queue[e].q<=0){_s(`q${t.queue.queue[e].id}${e}`),t.queue.queue.splice(e,1),ys();break}},setID:e=>`q${t.queue.queue[e].id}${e}`,setData(e,a){let r,i=t.queue.queue[e].id.split("-");"arpa"===i[0].substring(0,4)?r=i[0].substring(4):"city"===i[0]||"evolution"===i[0]||"starDock"===i[0]?r=Mr[i[0]][i[1]]:Object.keys(Mr[i[0]]).forEach((function(e){Mr[i[0]][e].hasOwnProperty(i[1])&&(r=Mr[i[0]][e][i[1]])}));let s={};if(r.cost){let e=Ns(r);Object.keys(e).forEach((function(t){let r=e[t]();r>0&&(s[`${a}-${t}`]=r)}))}return s},pauseQueue(){$("#pausequeue").removeClass("play"),$("#pausequeue").removeClass("pause"),t.queue.pause?(t.queue.pause=!1,$("#pausequeue").addClass("play")):(t.queue.pause=!0,$("#pausequeue").addClass("pause"))},pausedesc:()=>t.queue.pause?z("queue_play"):z("queue_pause")},filters:{time:e=>zs(e),count:e=>e>1?` (${e})`:"",max_t:(e,t)=>t===e||t<0?"":` / ${zs(e)}`,used_q(){let e=0;for(let a=0;a=4&&(r.tech.whitehole=3,r.resource.Soul_Gem.amount+=10,r.resource.Knowledge.amount+=15e5,r.stats.know-=15e5),r.tech.hasOwnProperty("quaked")&&2===r.tech.quaked&&(r.tech.quaked=1,r.resource.Knowledge.amount+=5e5,r.stats.know-=5e5),r.tech.hasOwnProperty("corrupted_ai")&&3===r.tech.corrupted_ai&&(r.tech.corrupted_ai=1,r.resource.Knowledge.amount+=5e6,r.stats.know-=5e6)),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(r))),window.location.reload())};const ws=!1;function ks(e,t){try{t.debug_mode=ws,gtag("event",e,t)}catch(e){}}function $s(e,a,r,i){let s=t.resource[e].amount+a,n=!0;return s>t.resource[e].max&&-1!=t.resource[e].max?s=t.resource[e].max:s<0&&((!i||i&&-1*s>i)&&(n=!1),s=0),Number.isNaN(s)||(t.resource[e].amount=s,r||(t.resource[e].delta+=a,"Mana"===e&&a>0&&(t.resource[e].gen_d+=a))),n}function xs(e){let a=Ki[t.race.species].type;switch(a){case"animal":a="animalism";break;case"small":a="dwarfism";break;case"giant":a="gigantism";break;case"avian":case"reptilian":a="eggshell";break;case"fungi":a="chitin";break;case"insectoid":a="athropods";break;case"angelic":a="celestial";break;case"organism":a="sentience"}const r=e?[z("civics_gov_tp_name0"),z("civics_gov_tp_name1"),z("civics_gov_tp_name2"),z("civics_gov_tp_name3"),z("civics_gov_tp_name4"),z("civics_gov_tp_name5"),z("civics_gov_tp_name6"),z("civics_gov_tp_name7"),z("civics_gov_tp_name8"),z("civics_gov_tp_name9")]:[Ki[t.race.species].name,Ki[t.race.species].home,z(`biome_${t.city.biome}_name`),z(`evo_${a}_title`),z("civics_gov_name0"),z("civics_gov_name1"),z("civics_gov_name2"),z("civics_gov_name3"),z("civics_gov_name4"),z("civics_gov_name5"),z("civics_gov_name6"),z("civics_gov_name7"),z("civics_gov_name8"),z("civics_gov_name9"),z("civics_gov_name10"),z("civics_gov_name11")];return{s0:Math.rand(0,14),s1:r[Math.rand(0,r.length)]}}function qs(e,a,r,i,s){s||(s="city"),"micro"===t.race.universe&&(i-=Is("micro",!1)),t.race.small?i-=Ei.small.vars()[0]:t.race.large&&(i+=Ei.large.vars()[0]),t.race.compact&&(i-=Ei.compact.vars()[0]),!t.race.tunneler||"mine"!==e&&"coal_mine"!==e||(i-=Ei.tunneler.vars()[0]),!t.tech.housing_reduction||"basic_housing"!==e&&"cottage"!==e||(i-=.02*t.tech.housing_reduction),t.tech.housing_reduction&&"captive_housing"===e&&(i-=.01*t.tech.housing_reduction),"basic_housing"===e&&(t.race.solitary&&(i-=Ei.solitary.vars()[0]),t.race.pack_mentality&&(i+=Ei.pack_mentality.vars()[0])),"cottage"===e&&(t.race.solitary&&(i+=Ei.solitary.vars()[1]),t.race.pack_mentality&&(i-=Ei.pack_mentality.vars()[1])),"apartment"===e&&t.race.pack_mentality&&(i-=Ei.pack_mentality.vars()[1]),t.genes.creep&&!t.race.no_crispr?i-=.01*t.genes.creep:t.genes.creep&&t.race.no_crispr&&(i-=.002*t.genes.creep);let n=K("noquestions",0);n&&(i-=n),i<1.005&&(i=1.005);var c="citizen"===e?t.resource[t.race.species].amount:t[s][e]?t[s][e].count:0;return a&&(c+=a),Math.round(i**c*r)}function Ps(e,a,r,i,s,n){s||(s="space"),n=n||1.005,"micro"===t.race.universe&&(i-=Is("micro",!0)),t.genes.creep&&!t.race.no_crispr?i-=.01*t.genes.creep:t.genes.creep&&t.race.no_crispr&&(i-=.002*t.genes.creep),t.race.small&&(i-=Ei.small.vars()[1]),t.race.compact&&(i-=Ei.compact.vars()[1]),t.prestige.Harmony.count>0&&t.stats.achieve.ascended&&(i-=js());let c=K("noquestions",0);c&&(i-=c),i0&&t.stats.achieve.ascended){let e=0;switch(t.race.universe){case"heavy":t.stats.achieve.ascended.hasOwnProperty("h")&&(e=t.stats.achieve.ascended.h*t.prestige.Harmony.count);break;case"antimatter":t.stats.achieve.ascended.hasOwnProperty("a")&&(e=t.stats.achieve.ascended.a*t.prestige.Harmony.count);break;case"evil":t.stats.achieve.ascended.hasOwnProperty("e")&&(e=t.stats.achieve.ascended.e*t.prestige.Harmony.count);break;case"micro":t.stats.achieve.ascended.hasOwnProperty("m")&&(e=t.stats.achieve.ascended.m*t.prestige.Harmony.count);break;case"magic":t.stats.achieve.ascended.hasOwnProperty("mg")&&(e=t.stats.achieve.ascended.mg*t.prestige.Harmony.count);break;default:t.stats.achieve.ascended.hasOwnProperty("l")&&(e=t.stats.achieve.ascended.l*t.prestige.Harmony.count)}if(e>0)return e=.01*(Math.log(50+e)-3.912023005428146),+e.toFixed(5)}return 0}function Os(e,a,r,i){if(i=void 0===i||i,e.cost){let s=0,n=!1,c=!(!a||!a.id[e.id])&&a.id[e.id],o=Ns(e,c),l=!!a&&{},_=!!a&&{};a&&(Object.keys(a.r).forEach((function(e){l[e]=a.r[e]})),Object.keys(a.rr).forEach((function(e){_[e]=a.rr[e]})));let d=!1;t.interstellar.hasOwnProperty("mass_ejector")&&t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks&&Object.keys(t.race.governor.tasks).forEach((function(e){"trash"===t.race.governor.tasks[e]&&(d=!0)}));let p={};return Object.keys(o).forEach((function(e){if(s>=0&&!t.prestige.hasOwnProperty(e)&&!["Morale","HellArmy","Structs","Bool"].includes(e)){var r=Number(c?o[e](c):o[e]());if(r>0){let c="Species"===e?t.race.species:e,o="Supply"===e?t.portal.purifier.supply:Number(t.resource[c].amount),u="Supply"===e?t.portal.purifier.sup_max:t.resource[c].max,h="Supply"===e?t.portal.purifier.diff:t.resource[c].diff;if(d&&t.interstellar.mass_ejector[e]&&(h+=t.interstellar.mass_ejector[e],t.race.governor.config.trash.hasOwnProperty(e)&&(h-=Math.min(t.race.governor.config.trash[e].v,t.interstellar.mass_ejector[e]))),a&&(o+=h*(i?a.t.t:a.t.rt),a.r.hasOwnProperty(c)||(a.r[c]=0),a.rr.hasOwnProperty(c)||(a.rr[c]=0),i?(o-=Number(a.r[c]),a.r[c]+=r,a.rr[c]+=r):(o-=Number(a.rr[c]),a.rr[c]+=r),u>=0&&o>u&&(o=u)),r>o)if(h>0){let e=(r-o)/h;e>s&&(n=c,s=e),p[c]=e}else a&&(a.r=l,a.rr=_),s=-9999999,p[c]=99999999-h,(p[n]&&p[c]>p[n]||!p[n])&&(n=c)}}})),a&&s>=0&&(void 0===a.id[e.id]?a.id[e.id]=1:a.id[e.id]++,i&&(a.t.t+=s),a.t.rt+=s),r?{t:s,r:n,s:p}:s}return 0}function Ms(e,a,r,i){let s=!(!r||!r.id[e.id])&&r.id[e.id],n=Ae(e.cost,s),c=0,o=!!r&&{},l=!!r&&{},_=!1;r&&(Object.keys(r.r).forEach((function(e){o[e]=r.r[e]})),Object.keys(r.rr).forEach((function(e){l[e]=r.rr[e]})));let d=!1;t.interstellar.hasOwnProperty("mass_ejector")&&t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks&&Object.keys(t.race.governor.tasks).forEach((function(e){"trash"===t.race.governor.tasks[e]&&(d=!0)}));let p={};return Object.keys(n).forEach((function(e){if(c>=0){let i=Number(n[e](s))*a;if(i>0){let a=Number(t.resource[e].amount),s=t.resource[e].diff;if(r&&(d&&t.interstellar.mass_ejector[e]&&(s+=t.interstellar.mass_ejector[e],t.race.governor.config.trash.hasOwnProperty(e)&&(s-=Math.min(t.race.governor.config.trash[e].v,t.interstellar.mass_ejector[e]))),a+=s*r.t.t,r.r[e]?(a-=Number(r.r[e]),r.r[e]+=i):r.r[e]=i,r.rr[e]?r.rr[e]+=i:r.rr[e]=i,t.resource[e].max>=0&&a>t.resource[e].max&&(a=t.resource[e].max)),i>a)if(s>0){let t=(i-a)/s;t>c&&(c=t,_=e),p[e]=t}else r&&(r.r=o,r.rr=l),c=-9999999,p[e]=99999999-s,(p[_]&&p[e]>p[_]||!p[_])&&(_=e)}}})),r&&c>=0&&(void 0===r.id[e.id]?r.id[e.id]=1:r.id[e.id]++,r.t.t+=c,r.t.rt+=c),i?{t:c,r:_,s:p}:c}function Ss(e,t){if(e.find(".vb").each((function(){try{$(this)[0].__vue__.$destroy()}catch(e){}})),t){try{e[0].__vue__.$destroy()}catch(e){}e.remove()}else e.empty()}function Cs(e,t){if(t=t||"create",$(e.el).length>0&&void 0!==$(e.el)[0].__vue__)try{"update"===t?$(e.el)[0].__vue__.$forceUpdate():$(e.el)[0].__vue__.$destroy()}catch(e){}"create"===t&&(new Vue(e),$(e.el).addClass("vb"))}function zs(e){let t;if(e<0)t=z("time_never");else if((e=+e.toFixed(0))>60){let a=e%60,r=(e-a)/60;if(r>=60){let e=r%60,a=(r-e)/60;a>24?(e=a%24,t=`${(a-e)/24}d ${e}h`):(e=("0"+e).slice(-2),t=`${a}h ${e}m`)}else a=("0"+a).slice(-2),t=`${r}m ${a}s`}else t=`${e}s`;return t}function Fs(e){return"antimatter"===t.race.universe&&(e=+(e*=Is("antimatter")).toFixed(2)),"leo"===N()&&(e=+(e*=1+G("leo")[0]/100).toFixed(2)),e}function As(e){return t.race.emfield?+(1.5*e).toFixed(2):e}function Is(e,a,r,i){i||(i={});let s=void 0!==i.dark?i.dark:t.prestige.Dark.count,n=void 0!==i.harmony?i.harmony:t.prestige.Harmony.count,c=void 0!==i.sludge?i.sludge:t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge[xn(e)]?t.stats.achieve.extinct_sludge[xn(e)]:0;switch(e){case"standard":return"standard"===t.race.universe||r?(n>0&&(s*=1+.001*n),c&&(s*=1+.03*c),1+s/200):0;case"evil":return"evil"===t.race.universe||r?(n>0&&(s*=1+.01*n),c&&(s*=1+.03*c),1+(Math.log2(10+s)-3.321928094887362)/5):1;case"micro":return"micro"===t.race.universe||r?a?(n>0&&(s*=1+.01*n),s=.01+(Math.log(100+s)-4.605170185988092)/35,c&&(s*=1+.03*c),s>.04&&(s=.04),+s.toFixed(5)):(n>0&&(s*=1+.01*n),s=.02+(Math.log(100+s)-4.605170185988092)/20,c&&(s*=1+.03*c),s>.06&&(s=.06),+s.toFixed(5)):0;case"heavy":return"heavy"===t.race.universe||r?(n>0&&(s*=1+.01*n),c&&(s*=1+.03*c),.995**s):1;case"antimatter":return"antimatter"===t.race.universe||r?(n>0&&(s*=1+.01*n),c&&(s*=1+.03*c),1+(Math.log(50+s)-3.912023005428146)/5):0;case"magic":return"magic"===t.race.universe||r?(n>0&&(s*=1+.01*n),c&&(s*=1+.03*c),1+(Math.log(50+s)-3.912023005428146)/3):0}return 0}const Ts=function(e){return Ls&&!e?Ls:t.genes.challenge&&t.genes.challenge>=2?Ls=Es(t.race.universe):0};var Ls;function Es(e,a){if(t.genes.challenge&&t.genes.challenge>=2){let r=$n(e=e||t.race.universe),i="standard"===e?.25:.15,s=t.genes.challenge>=3?.15:.1;t.genes.challenge>=4&&"standard"!==e&&(i+=.05,s-=.05),t.race.weak_mastery&&"antimatter"===e&&(i/=10,s/=10),t.race.nerfed&&(i/="antimatter"===e?5:2,s/="antimatter"===e?5:2),t.race.ooze&&(i*=1-Ei.ooze.vars()[2]/100,s*=1-Ei.ooze.vars()[2]/100);let n=t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):0;n>0&&(i*=1+n/100,s*=1+n/100);let c=r.aLvl*i,o=0;return"standard"!==e&&(o=r.uLvl*s),t.genes.challenge>=5&&t.race.hasOwnProperty("mastery")&&(c*=1+Ei.mastery.vars()[0]*t.race.mastery/100,o*=1+Ei.mastery.vars()[0]*t.race.mastery/100),a?{g:c,u:o,m:c+o}:c+o}return a?{g:0,u:0,m:0}:0}const Ks=function(e){if(!Ds||e){let e=0;Object.keys(t.pillars).forEach((function(a){Ki[a]&&t.race.species===a?e+=4:Ki[a]&&e++})),Ds=[1+e/100,1+2*e/100]}return Ds};var Ds;function Bs(e,a,r,i){r=r||0;let s=(i=i||{}).genes;void 0===s&&(s=Mn()-1,s>4&&(s=4));let n=i.uni||t.race.universe;if("micro"===n&&(e*=.25),"antimatter"===n&&(e*=1.1),"heavy"===n&&"mad"!==a)switch(s){case 1:e*=1.1;break;case 2:e*=1.15;break;case 3:e*=1.2;break;case 4:e*=1.25;break;default:e*=1.05}switch((void 0!==i.tp?i.tp:t.race.truepath)&&(e*=1.1),s){case 1:return+(1.05*e).toFixed(r);case 2:return+(1.12*e).toFixed(r);case 3:return+(1.25*e).toFixed(r);case 4:return+(1.45*e).toFixed(r);default:return+e.toFixed(r)}}function Gs(e,a){let r={plasmid:0,phage:0,dark:0,harmony:0,artifact:0,cores:0};a||(a={});let i=a.genes,s=a.uni;s=s||t.race.universe;let n=0;if(void 0===a.cit){let e=t.civic.hasOwnProperty("garrison")?t.civic.garrison.workers:0;for(let a=0;a<3;a++)t.civic.foreign[`gov${a}`].occ&&(e+=ta("federation"===t.civic.govern.type?15:20));n=t.race.high_pop?Math.round(t.resource[t.race.species].amount/Ei.high_pop.vars()[0])+Math.round(e/Ei.high_pop.vars()[0]):t.resource[t.race.species].amount+e}else n=a.high_pop?Math.round(a.cit/Ei.high_pop.vars(a.high_pop)[0])+Math.round(a.sol/Ei.high_pop.vars(a.high_pop)[0]):a.cit+a.sol;let c=999,o=1e6,l=100,_=0,d=150;switch(e){case"mad":c=3,o=1e5,l=1.1,d=150,(void 0!==a.synth?a.synth:"synthetic"===Ki[t.race.species].type)&&(c=5,o=125e3,d=100);break;case"cataclysm":case"bioseed":c=3,o=5e4,l=1.015,_=1,d=400;break;case"ai":c=2.5,o=45e3,l=1.014,_=2,d=600;break;case"vacuum":case"bigbang":c=2.2,o=4e4,l=1.012,_=2.5,d=800;break;case"ascend":case"terraform":c=1.15,o=3e4,l=1.008,_=4,d=2e3;break;case"matrix":c=1.5,o=32e3,l=1.01,_=3.2,d=1800;break;case"retire":c=1.15,o=32e3,l=1.006,_=3.2,d=1800;break;case"eden":c=1,o=18e3,l=1.004,_=2.5,d=1800}if(d=void 0!==i?Math.floor(d*(1+(i+(a.tp?1:0))/8)):Math.floor(d*(1+(Mn()-(t.race.truepath?0:1))/8)),void 0===a.plas){let i=void 0!==a.know?a.know:t.stats.know,s=Math.round(n/c);for(;i>o;)s++,i-=o,o*=l;if(t.race.cataclysm?s+=300:t.race.lone_survivor&&(s+=800),r.plasmid=Bs(s,e,!1,a),!a.rawPlasmids&&r.plasmid>d){let e=r.plasmid-d;r.plasmid=d,e=Math.floor(e/(e+d)*d),r.plasmid+=e}}else r.plasmid=a.plas;if(r.phage=r.plasmid>0?Bs(Math.floor(Math.log2(r.plasmid)*Math.E*_),e,!1,a):0,"bigbang"===e){let e=a.exotic,i=a.mass;void 0===e&&t.interstellar&&t.interstellar.stellar_engine&&(e=t.interstellar.stellar_engine.exotic,i=t.interstellar.stellar_engine.mass);let s=+Math.log(1+40*e).toFixed(3);s+=+(Math.log2(i-7)/2.5).toFixed(3),s=Bs(s,"bigbang",3,a),r.dark=s}else if("vacuum"===e){let e=void 0!==a.mana?a.mana:t.resource.Mana.gen,i=+(Math.log2(e)/5).toFixed(3);i=Bs(i,"vacuum",3,a),r.dark=i}if(["ascend","descend","terraform"].includes(e)){let n=1;if(void 0===i?(n=Mn(),n>5&&(n=5)):n=i+1,"ascend"===e||"terraform"===e){switch(s){case"micro":n*=.25;break;case"heavy":n*=1.2;break;case"antimatter":n*=1.1}r.harmony=parseFloat(n.toFixed(2))}else if("descend"===e){let e="micro"===s?1:n,i=a.floor;void 0!==i?i++:i=t.portal.hasOwnProperty("spire")?t.portal.spire.count:0,[50,100].forEach((function(t){i>t&&e++})),r.artifact=e}}return"ai"===e&&(r.cores="micro"===s?2:5),r}function Ns(e,a,r){let i=e.cost||{};if((i.RNA||i.DNA)&&t.genes.evolve){var s={};return Object.keys(i).forEach((function(e){"RNA"!==e&&"DNA"!==e||(s[e]=function(){return Math.round(.8*i[e](a,r))})})),s}return i=function(e,a,r){if(t.race.bloated){let t=1+Ei.bloated.vars()[0]/100;var i={};return Object.keys(e).forEach((function(s){["Food","Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Alloy","Polymer","Iridium"].includes(s)?i[s]=function(){return e[s](a,r)*t}:i[s]=function(){return e[s](a,r)}})),i}return e}(i,a,r),i=function(e,a,r,i){if((i?i.truepath:t.race.truepath)&&(!a.hasOwnProperty("path")||!a.path.includes("truepath"))){var s={};return Object.keys(e).forEach((function(t){"Money"===t?s[t]=function(){return Math.round(3*e[t](r,i))}:["Structs","Knowledge","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe"].includes(t)?s[t]=function(){return e[t](r,i)}:s[t]=function(){return Math.round(2*e[t](r,i))}})),s}return e}(i,e,a,r),i=function(e,a,r){if(t.race.lone_survivor){var i={};return Object.keys(e).forEach((function(t){["Structs","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe"].includes(t)?i[t]=function(){return e[t](a,r)}:["Knowledge"].includes(t)?i[t]=function(){return Math.round(.5*e[t](a,r))}:["Money"].includes(t)?i[t]=function(){return Math.round(.22*e[t](a,r))}:["Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Quantium"].includes(t)?i[t]=function(){return Math.round(.14*e[t](a,r))}:i[t]=function(){return Math.round(.28*e[t](a,r))}})),i}return e}(i,a,r),i=function(e,a,r){if(t.race.inflation){var i={};return Object.keys(e).forEach((function(s){if("Money"===s){let n=1+t.race.inflation/75;i[s]=function(){return Math.round(e[s](a,r)*n)}}else i[s]=function(){return e[s](a,r)}})),i}return e}(i,a,r),i=function(e,a,r){if("technocracy"===t.civic.govern.type){let t=1+Y.technocracy()[1]/100;var i={};return Object.keys(e).forEach((function(s){if("Knowledge"===s){let t=1-Y.technocracy()[0]/100;i[s]=function(){return Math.round(e[s](a,r)*t)}}else i[s]="Money"===s||"Structs"===s||"Custom"===s?function(){return e[s](a,r)}:function(){return Math.round(e[s](a,r)*t)}})),i}return e}(i,a,r),i=function(e,a,r){if(t.race.flier&&(e.Stone||e.Cement)){var i={};let t=1-Ei.flier.vars()[0]/100;return Object.keys(e).forEach((function(s){"Stone"!==s||e.Cement?"Cement"===s?e.Stone?i.Stone=function(){return Math.round(e.Stone(a,r)*t+1.8*e[s](a,r)*t)||0}:i.Stone=function(){return Math.round(1.75*e[s](a,r)*t)}:i[s]=function(){return e[s](a,r)}:i[s]=function(){return Math.round(e[s](a,r)*t)||0}})),i}return e}(i,a,r),i=function(e,a,r){if(t.race.kindling_kindred&&(e.Lumber||e.Plywood)){var i={};let t=1+Ei.kindling_kindred.vars()[0]/100;return Object.keys(e).forEach((function(s){"Lumber"!==s&&"Plywood"!==s&&"Structs"!==s?i[s]=function(){return Math.round(e[s](a,r)*t)||0}:"Structs"===s&&(i[s]=function(){return e[s](a,r)})})),i}if(t.race.unfathomable&&t.city.captive_housing){let t=ts("entish");if(t>0){i={};let s=1-.4*t;return Object.keys(e).forEach((function(t){i[t]="Lumber"===t&&"Plywood"===t?function(){return Math.round(e[t](a,r)*s)||0}:function(){return e[t](a,r)}})),i}}return e}(i,a,r),i=function(e,a,r){if(t.race.smoldering){let i={};return Object.keys(e).forEach((function(t){if("Lumber"===t||"Plywood"===t){let s="Plywood"===t?2:1;i.Chrysotile=function(){return Math.round(e[t](a,r)*s)||0}}else["HellArmy","Structs","Chrysotile","Knowledge","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe","Mana","Energy"].includes(t)?i[t]=function(){return e[t](a,r)}:i[t]=function(){return Math.round(.9*e[t](a,r))}})),!i.hasOwnProperty("Chrysotile")&&e.hasOwnProperty("Money")&&t.tech.primitive&&t.tech.primitive>=3&&(i.Chrysotile=function(){let t=e.Money(a,r)||0;return t>0?Math.round(t/50):0}),i}return e}(i,a,r),i=function(e,a,r){let i=K("pragmatist",1),s=ts("gnome");if((t.race.smart||t.race.dumb||i||s>0)&&e.Knowledge){var n={};return Object.keys(e).forEach((function(c){n[c]="Knowledge"===c?function(){let n=e[c](a,r);return t.race.smart&&(n*=1-Ei.smart.vars()[0]/100),s>0&&(n*=1-Ei.smart.vars(1)[0]/100*s),t.race.dumb&&(n*=1+Ei.dumb.vars()[0]/100),i&&(n*=1+i/100),Math.round(n)}:function(){return e[c](a,r)}})),n}return e}(i,a,r),i=function(e,a,r){if(e.Cement&&t.tech.cement&&t.tech.cement>=2){let s=t.tech.cement>=3?.8:.9;var i={};return Object.keys(e).forEach((function(t){i[t]="Cement"===t?function(){return Math.round(e[t](a,r)*s)||0}:function(){return e[t](a,r)}})),i}return e}(i,a,r),i=function(e,t,a){let r=K("extravagant",0);if(r){var i={};return Object.keys(e).forEach((function(s){if("Money"===s){let n=1+r/100;i[s]=function(){return Math.round(e[s](t,a)*n)}}else i[s]=function(){return e[s](t,a)}})),i}return e}(i,a,r),i=function(e,a,r){if(t.race.heavy){var i={};return Object.keys(e).forEach((function(t){i[t]="Stone"===t||"Cement"===t||"Wrought_Iron"===t?function(){return Math.round(e[t](a,r)*(1+Ei.heavy.vars()[1]/100))}:function(){return e[t](a,r)}})),i}return e}(i,a,r),function(e,a,r){let i=ts("pterodacti");if((t.race.hollow_bones||i>0)&&(e.Plywood||e.Brick||e.Wrought_Iron||e.Sheet_Metal||e.Mythril||e.Aerogel||e.Nanoweave||e.Scarletite||e.Quantium)){var s={};return Object.keys(e).forEach((function(n){s[n]="Plywood"===n||"Brick"===n||"Wrought_Iron"===n||"Sheet_Metal"===n||"Mythril"===n||"Aerogel"===n||"Nanoweave"===n||"Scarletite"===n||"Quantium"===n?function(){let s=e[n](a,r);return t.race.hollow_bones&&(s*=1-Ei.hollow_bones.vars()[0]/100),i>0&&(s*=1-Ei.hollow_bones.vars(3)[0]/100*i),Math.round(s)}:function(){return e[n](a,r)}})),s}return e}(i,a,r)}function Rs(e){return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}function Hs(e){switch(e){case"star":return'';case"atom":return'';case"heavy":return'';case"evil":return'';case"micro":return'';case"magic":return'';case"rocket":return'';case"heart":return'';case"clover":return'';case"candy":return'';case"ghost":return'';case"turkey":return'';case"present":return'';case"nuclear":return'';case"zombie":return'';case"fire":return'';case"mask":return'';case"skull":return'';case"taijitu":return'';case"trash":return'';case"martini":return'';case"lightbulb":return'';case"bunny":return'';case"egg":return'';case"turtle":return'';case"candycorn":return'';case"banana":return'\n ';case"sun":return'';case"firework":return'';case"floppy":return'';case"slime":return'';case"lightning":return'\n \n '}}function Us(e){switch(e){case"star":return"0 0 640 640";case"atom":return"0 0 100 88.379";case"heavy":case"mask":return"0 0 24 24";case"evil":return"0 0 240 240";case"micro":return"0 0 276 276";case"magic":return"0 0 2666 2666";case"rocket":return"0 0 165 173";case"sun":return"0 0 48 48";case"heart":return"0 0 20 16";case"clover":return"0 0 660.51 780.1";case"candy":return"0 0 200 200";case"ghost":return"0 0 399 432.23";case"turkey":return"0 0 250 300";case"present":return"0 0 410.98 434.75";case"nuclear":return"0 0 101.22 101.22";case"zombie":return"0 0 175 304";case"fire":return"0 0 615.18 879.36";case"skull":return"0 0 256.27 300.86";case"taijitu":return"0 -10 256 256 ";case"pizza":return"0 0 217.444 144.397";case"trash":case"martini":return"0 0 15 15";case"party":return"0 0 528.69 983.1";case"lightbulb":return"0 0 100 156";case"bunny":case"ant":return"0 0 128 128";case"egg":return"0 0 273.61 295.02";case"turtle":return"20 40 270 50";case"candycorn":return"0 0 325 449.98";case"banana":return"0 0 113.38582 111.81719";case"firework":return"0 10 12 35";case"floppy":return"0 0 60 60";case"slime":return"0 0 552 495";case"lightning":return"0 0 16 16"}}function Vs(e,a){if("feat"===a)switch(e){case"steelem":return"nuclear";case"the_misery":return"zombie";case"ill_advised":return"fire";case"garbage_pie":return"trash";case"demon_slayer":return"skull";case"equilibrium":return"taijitu";case"utopia":return"martini";case"energetic":return"lightbulb";case"finish_line":return"turtle";case"banana":return"banana";case"digital_ascension":return"floppy";case"slime_lord":return"slime";case"annihilation":return"lightning";case"friday":return"mask";case"valentine":return"heart";case"leprechaun":return"clover";case"easter":return"bunny";case"launch_day":return"rocket";case"solstice":return"sun";case"firework":return"firework";case"egghunt":return"egg";case"halloween":return"ghost";case"trickortreat":return"candy";case"thanksgiving":return"turkey";case"xmas":return"present";default:return"star"}return t.settings.icon}function Ws(e,t,a,r,i){let s="";return r&&(s=`id="${r}" `),`${Hs(e)}`}function Qs(e,a){let r=on();const i=new Date;return r.active&&!t.special.egg[i.getFullYear()][`egg${e}`]?Ws("egg",a||16,2,`egg${e}`,'role="button" aria-label="Egg" '):""}function Js(e,a,r){let i=ln();const s=(new Date).getFullYear();let n=r?"trick":"treat";return i.active&&!t.special.trick[s][`${n}${e}`]?Ws(r?"ghost":"candycorn",a||16,2,`${n}${e}`,`role="button" aria-label="${r?"Ghost":"Candy Corn"}" `):""}function Zs(e,a,r,i,s,n){return t.stats.achieve[e]&&(s?t.stats.achieve[e][n]-1:t.stats.achieve[e][n])>0?`

                    ${Hs(r)}

                    `:""}function Xs(e,a,r,i,s){a||(a=10),r||(r=Vs(e,"achievement"));let n="";if(s)switch(s){case"standard":n+=Zs(e,a,r,z(t.settings.icon),i,"l");break;case"antimatter":n+=Zs(e,a,"atom",z("universe_antimatter"),i,"a");break;case"evil":n+=Zs(e,a,"evil",z("universe_evil"),i,"e");break;case"heavy":n+=Zs(e,a,"heavy",z("universe_heavy"),i,"h");break;case"micro":n+=Zs(e,a,"micro",z("universe_micro"),i,"m");break;case"magic":n+=Zs(e,a,"magic",z("universe_magic"),i,"mg")}else n+=Zs(e,a,r,z(t.settings.icon),i,"l"),n+=Zs(e,a,"atom",z("universe_antimatter"),i,"a"),n+=Zs(e,a,"evil",z("universe_evil"),i,"e"),n+=Zs(e,a,"heavy",z("universe_heavy"),i,"h"),n+=Zs(e,a,"micro",z("universe_micro"),i,"m"),n+=Zs(e,a,"magic",z("universe_magic"),i,"mg");return n}function Ys(e,t){return(t=t||{})[e]?t[e]:e<=1?1:t[e]=Ys(e-1,t)+Ys(e-2,t)}function en(e){var t=Object.keys(e);return t[t.length*Math.random()<<0]}function tn(e){switch(e){case 1:return z("basic");case 2:return z("plain");case 3:return z("bronze");case 4:return z("silver");case 5:return z("gold");default:return""}}function an(e,a){let r=0;if(a)Object.keys(a.ascended).forEach((function(e){r+=a.ascended[e]}));else if(t.stats.achieve.ascended)for(let e=0;e=1&&(i+=t.stats.achieve.technophobe.l);let s=0;for(let t=0;t=0&&(s>i&&(a-=i-s),s++),r-=a}return r}function rn(){t.stats.reset++,t.stats.tdays+=t.stats.days,t.stats.days=0,t.stats.tknow+=t.stats.know,t.stats.know=0,t.stats.tstarved+=t.stats.starved,t.stats.starved=0,t.stats.tdied+=t.stats.died,t.stats.died=0,t.stats.tsac+=t.stats.sac,t.stats.sac=0,t.stats.tcattle+=t.stats.cattle,t.stats.cattle=0,t.stats.tmurders+=t.stats.murders,t.stats.murders=0,t.stats.tpsykill+=t.stats.psykill,t.stats.psykill=0}function sn(e){if(null===e||"object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());if(Array.isArray(e)){var t=[];return e.forEach((function(e){t.push(sn(e))})),t}let a=new e.constructor;for(var r in e)e.hasOwnProperty(r)&&(a[r]=sn(e[r]));return a}function nn(e,a,r){switch(e){case"reverse":{let e=a.toLowerCase().split("").reverse().join("");return e.charAt(0).toUpperCase()+e.slice(1)}case"name":return cn("fool",2021)?nn("reverse",Ki[t.race.species].name):Ki[t.race.species].name;case"curve":return 1-(1-a)**(r||1.5)}return!1}function cn(e,a){switch(e){case"easter":return on();case"halloween":return ln();case"fool":{const e=new Date;return!(t.settings.boring||3!==e.getMonth()||1!==e.getDate()||a&&e.getFullYear()!==a)}case"launch_day":{const e=new Date;return!t.settings.boring&&4===e.getMonth()&&6===e.getDate()}case"summer":{const e=new Date;return!t.settings.boring&&5===e.getMonth()&&[20,21,22].includes(e.getDate())?(t.city.hasOwnProperty("foundry")&&!t.city.foundry.hasOwnProperty("Thermite")&&(t.city.foundry.Thermite=0),t.resource.hasOwnProperty("Thermite")||(t.resource.Thermite={name:z("resource_Thermite_name"),display:!1,value:0,amount:0,crates:0,diff:0,delta:0,max:-1,rate:0}),!0):(t.city.hasOwnProperty("foundry")&&t.city.foundry.hasOwnProperty("Thermite")&&(t.city.foundry.crafting-=t.city.foundry.Thermite,t.civic.craftsman.workers-=t.city.foundry.Thermite,t.civic[t.civic.d_job].workers+=t.city.foundry.Thermite,delete t.city.foundry.Thermite),!1)}case"firework":{const e=new Date;if(!t.settings.boring&&6===e.getMonth()&&[1,2,3,4].includes(e.getDate())){let e=t.race.cataclysm||t.race.orbit_decayed?"space":"city";return t[e].hasOwnProperty("firework")||(t[e].firework={count:0,on:0}),!0}return(t.city.hasOwnProperty("firework")||t.space.hasOwnProperty("firework"))&&(delete t.city.firework,delete t.space.firework),!1}}return!1}function on(){const e=new Date;let a=e.getFullYear();t.special.egg.hasOwnProperty(a)||(t.special.egg[a]={egg1:!1,egg2:!1,egg3:!1,egg4:!1,egg5:!1,egg6:!1,egg7:!1,egg8:!1,egg9:!1,egg10:!1,egg11:!1,egg12:!1}),t.special.egg.hasOwnProperty(a)&&!t.special.egg[a].hasOwnProperty("egg13")&&(t.special.egg[a].egg13=!1,t.special.egg[a].egg14=!1,t.special.egg[a].egg15=!1),t.special.egg.hasOwnProperty(a)&&!t.special.egg[a].hasOwnProperty("egg16")&&(t.special.egg[a].egg16=!1,t.special.egg[a].egg17=!1,t.special.egg[a].egg18=!1);let r=Math.floor,i=a%19,s=r(a/100),n=(s-r(s/4)-r((8*s+13)/25)+19*i+15)%30,c=n-r(n/28)*(1-r(29/(n+1))*r((21-i)/11)),o=c-(a+r(a/4)+c+2-s+r(s/4))%7,l=3+r((o+40)/44),_=o+28-31*r(l/4),d={date:[l-1,_],active:!1,endDate:[l-1,_],hint:!1,hintDate:[l-1,_],solve:!1,solveDate:[l-1,_]};return t.settings.boring||(d.endDate[1]+=10,(2===d.endDate[0]&&d.endDate[1]>31||3===d.endDate[0]&&d.endDate[1]>30)&&(d.endDate[1]-=2===d.endDate[0]?31:30,d.endDate[0]++),d.hintDate[1]+=1,(2===d.hintDate[0]&&d.hintDate[1]>31||3===d.hintDate[0]&&d.hintDate[1]>30)&&(d.hintDate[1]-=2===d.hintDate[0]?31:30,d.hintDate[0]++),d.solveDate[1]+=3,(2===d.solveDate[0]&&d.solveDate[1]>31||3===d.solveDate[0]&&d.solveDate[1]>30)&&(d.solveDate[1]-=2===d.solveDate[0]?31:30,d.solveDate[0]++),e.getMonth()>=d.date[0]&&e.getDate()>=d.date[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.active=!0,e.getMonth()>=d.hintDate[0]&&e.getDate()>=d.hintDate[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.hint=!0),e.getMonth()>=d.solveDate[0]&&e.getDate()>=d.solveDate[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.solve=!0))),d}function ln(){const e=new Date;let a=e.getFullYear();t.special.trick.hasOwnProperty(a)||(t.special.trick[a]={trick1:!1,trick2:!1,trick3:!1,trick4:!1,trick5:!1,trick6:!1,trick7:!1,treat1:!1,treat2:!1,treat3:!1,treat4:!1,treat5:!1,treat6:!1,treat7:!1});let r={date:[9,28],active:!1,endDate:[10,4],hint:!1,hintDate:[9,29],solve:!1,solveDate:[9,31]};if(t.settings.boring)return r;let i=new Date(`${r.date[0]+1}/${r.date[1]}/${a}`),s=new Date(`${r.endDate[0]+1}/${r.endDate[1]}/${a}`);return e>=i&&e<=s&&(r.active=!0,e>=new Date(`${r.hintDate[0]+1}/${r.hintDate[1]}/${a}`)&&e<=s&&(r.hint=!0),e>=new Date(`${r.solveDate[0]+1}/${r.solveDate[1]}/${a}`)&&e<=s&&(r.solve=!0)),r}function _n(){return t.race.magnificent&&t.city.hasOwnProperty("shrine")&&t.city.shrine.count>0}function dn(e){let a={mult:1,add:0};if(_n())switch(e){case"metal":a.mult+=+t.city.shrine.metal/100*Ei.magnificent.vars()[3];break;case"tax":a.mult+=+t.city.shrine.tax/100*Ei.magnificent.vars()[2];break;case"know":a.add+=+t.city.shrine.know*Ei.magnificent.vars()[0],a.mult+=+t.city.shrine.know*Ei.magnificent.vars()[1]/100;break;case"morale":a.add+=t.city.shrine.morale*Ei.magnificent.vars()[4]}return a}const pn={promiscuous:!1,revive:!1,fast_growth:!1,spores:!1,terrifying:!1,fibroblast:!0,hivemind:!0,imitation:!0,elusive:!0,chameleon:!0,blood_thirst:!0,selenophobia:!0,hooved:!0,anthropophagite:!0,unfathomable:!1,darkness:!1,living_tool:!1};function un(e,a){let r=Ei[e].hasOwnProperty("vars")?Ei[e].vars(a):[];return pn.hasOwnProperty(e)&&("fibroblast"===e?r=[5*r[0]]:"hivemind"===e&&t.race.high_pop?r=[r[0]*Ei.high_pop.vars()[0]]:"imitation"===e?r.push(Ki[t.race.srace||"protoplasm"].name):"elusive"===e?r=[Math.round(100*(1/30/(1/(30+r[0]))-1))]:"chameleon"===e?r=[r[0],Math.round(100*(1/30/(1/(30+r[1]))-1))]:"blood_thirst"===e?r=[Math.ceil(Math.log2(r[0]))]:"selenophobia"===e?r=[14-r[0],r[0]]:"hooved"===e?r.unshift(hn()):"anthropophagite"===e?r=[1e4*r[0]]:pn[e]||(r=[])),r}function hn(e){return t.race.sludge?e?"craft":z("resource_Beaker_name"):"cath"===t.race.species?e?"craft":z("resource_Box_name"):"wolven"===t.race.species?e?"craft":z("resource_ChewToy_name"):"dracnid"===t.race.species?e?"craft":z("resource_Hoard_name"):"seraph"===t.race.species?e?"forge":z("resource_Halo_name"):"cyclops"===t.race.species?e?"craft":z("resource_Monocle_name"):"kobold"===t.race.species?e?"craft":z("resource_Candle_name"):"tuskin"===t.race.species?e?"craft":z("resource_Goggles_name"):"sharkin"===t.race.species?e?"craft":z("resource_ToothSharpener_name"):"humanoid"===Ki[t.race.species].type?e?"craft":z("resource_Sandals_name"):"avian"===Ki[t.race.species].type?e?"craft":z("resource_Perch_name"):"plant"===Ki[t.race.species].type?e?"craft":z("resource_Planter_name"):"fungi"===Ki[t.race.species].type?e?"craft":z("resource_DampCloth_name"):"reptilian"===Ki[t.race.species].type?e?"craft":z("resource_HeatRock_name"):"fey"===Ki[t.race.species].type?e?"craft":z("resource_PixieDust_name"):"synthetic"===Ki[t.race.species].type?e?"craft":z("resource_Battery_name"):e?"forge":z("resource_Horseshoe_name")}const mn={infiltrator:[z("wiki_trait_effect_infiltrator_ex1"),z("wiki_trait_effect_infiltrator_ex2",[[`${z("tech_steel")}`,`${z("tech_electricity")}`,`${z("tech_electronics")}`,`${z("tech_fission")}`,`${z("tech_rocketry")}`,`${z("tech_artificial_intelligence")}`,`${z("tech_quantum_computing")}`,`${z("tech_virtual_reality")}`,`${z("tech_shields")}`,`${z("tech_ai_core")}`,`${z("tech_graphene_processing")}`,`${z("tech_nanoweave")}`,`${z("tech_orichalcum_analysis")}`,`${z("tech_infernium_fuel")}`].join(", ")])],heavy:[z("wiki_trait_effect_heavy_ex1",[gn("Stone"),gn("Cement"),gn("Wrought_Iron")])],sniper:[z("wiki_trait_effect_sniper_ex1")],hooved:[z("wiki_trait_effect_hooved_ex1",[hn(!1)]),z("wiki_trait_effect_hooved_ex2",[`${t.resource.hasOwnProperty("Lumber")?t.resource.Lumber.name:z("resource_Lumber_name")}`,`${t.resource.hasOwnProperty("Copper")?t.resource.Copper.name:z("resource_Copper_name")}`,`${t.resource.hasOwnProperty("Iron")?t.resource.Iron.name:z("resource_Iron_name")}`,`${t.resource.hasOwnProperty("Steel")?t.resource.Steel.name:z("resource_Steel_name")}`,`${t.resource.hasOwnProperty("Adamantite")?t.resource.Adamantite.name:z("resource_Adamantite_name")}`,`${t.resource.hasOwnProperty("Orichalcum")?t.resource.Orichalcum.name:z("resource_Orichalcum_name")}`,12,75,150,500,5e3]),z("wiki_trait_effect_hooved_ex3"),z("wiki_trait_effect_hooved_ex4",['5',hn(!1)]),z("wiki_trait_effect_hooved_ex5",[`${t.resource.hasOwnProperty("Lumber")?t.resource.Lumber.name:z("resource_Lumber_name")}`,`${t.resource.hasOwnProperty("Copper")?t.resource.Copper.name:z("resource_Copper_name")}`])],instinct:[z("wiki_trait_effect_instinct_ex1",[6.67,z("galaxy_chthonian"),10])],logical:[z("wiki_trait_effect_logical_ex1",[t.tech.hasOwnProperty("science")?t.tech.science:0,t.tech.hasOwnProperty("high_tech")?t.tech.high_tech:0])],high_pop:[z("wiki_trait_effect_high_pop_ex1")],flier:[z("wiki_trait_effect_flier_ex1")],unfathomable:[z("wiki_trait_effect_unfathomable_ex1"),z("wiki_trait_effect_unfathomable_ex2")]};function gn(e){return`${t.hasOwnProperty("resource")&&t.resource.hasOwnProperty(e)?t.resource[e].name:z(`resource_${e}_name`)}`}function vn(e,a,r){let i=r.fanatic||!1,s=r.tpage||!1,n=r.trank||!1,c=r.wiki||!1,o="",l=as("name",a),_=as("desc",a);s&&["genus","major"].includes(Ei[a].type)&&(o=`«${z("wiki_trait_rank")} {{ rank }}»`),c&&e.append(`

                    ${l}

                    ${o}
                    `),c&&(s&&Ei[a].hasOwnProperty("val")?e.append(`
                    ${z(`wiki_trait_${Ei[a].type}`)}${z("wiki_trait_value",[Ei[a].val])}
                    `):e.append(`
                    ${z(`wiki_trait_${Ei[a].type}`)}
                    `)),i&&c&&e.append(`
                    ${z("wiki_trait_fanaticism",[i])}
                    `),e.append(`
                    ${_}
                    `);let d="warning";if(Ei[a].hasOwnProperty("val")&&(d=Ei[a].val>=0?"success":"danger"),s&&["genus","major"].includes(Ei[a].type)?e.append(`
                    `):(c||t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0)&&e.append(`
                    ${z(`wiki_trait_effect_${a}`,un(a,n))}
                    `),mn[a]&&c&&mn[a].forEach((function(t){e.append(`
                    ${t}
                    `)})),s&&["genus","major"].includes(Ei[a].type)){let e={rank:t.race[a]||1};Cs({el:`#${Ei[a].type}_${a}`,data:e,methods:{getTraitDesc:e=>z(`wiki_trait_effect_${a}`,un(a,e)),up(){switch(e.rank){case.25:e.rank=.5;break;case.5:e.rank=1;break;case 1:e.rank=2;break;case 2:case 3:e.rank=3}},down(){switch(e.rank){case.25:case.5:e.rank=.25;break;case 1:e.rank=.5;break;case 2:e.rank=1;break;case 3:e.rank=2}}}})}}const fn={misc:["apocalypse","ascended","dreaded","anarchist","second_evolution","blackhole","warmonger","red_tactics","pacifist","neutralized","paradise","scrooge","madagascar_tree","godwin","laser_shark","infested","mass_starvation","colonist","world_domination","illuminati","syndicate","cult_of_personality","doomed","pandemonium","blood_war","landfill","seeder","miners_dream","shaken","blacken_the_sun","trade","resonance","enlightenment","gladiator","corrupted","red_dead"],species:["mass_extinction","extinct_human","extinct_elven","extinct_orc","extinct_cath","extinct_wolven","extinct_vulpine","extinct_centaur","extinct_rhinotaur","extinct_capybara","extinct_kobold","extinct_goblin","extinct_gnome","extinct_ogre","extinct_cyclops","extinct_troll","extinct_tortoisan","extinct_gecko","extinct_slitheryn","extinct_arraak","extinct_pterodacti","extinct_dracnid","extinct_entish","extinct_cacti","extinct_pinguicula","extinct_sporgar","extinct_shroomi","extinct_moldling","extinct_mantis","extinct_scorpid","extinct_antid","extinct_sharkin","extinct_octigoran","extinct_dryad","extinct_satyr","extinct_phoenix","extinct_salamander","extinct_yeti","extinct_wendigo","extinct_tuskin","extinct_kamel","extinct_balorg","extinct_imp","extinct_seraph","extinct_unicorn","extinct_synth","extinct_nano","extinct_ghast","extinct_shoggoth","extinct_junker","extinct_sludge","extinct_custom"],genus:["creator","genus_humanoid","genus_carnivore","genus_herbivore","genus_small","genus_giant","genus_reptilian","genus_avian","genus_insectoid","genus_plant","genus_fungi","genus_aquatic","genus_fey","genus_heat","genus_polar","genus_sand","genus_demonic","genus_angelic","genus_synthetic","genus_eldritch"],planet:["explorer","biome_grassland","biome_oceanic","biome_forest","biome_desert","biome_volcanic","biome_tundra","biome_savanna","biome_swamp","biome_ashland","biome_taiga","biome_hellscape","biome_eden","atmo_toxic","atmo_mellow","atmo_rage","atmo_stormy","atmo_ozone","atmo_magnetic","atmo_trashed","atmo_elliptical","atmo_flare","atmo_dense","atmo_unstable","atmo_permafrost","atmo_retrograde"],universe:["vigilante","squished","double_density","cross","macro","marble","heavyweight","whitehole","heavy","canceled","eviltwin","microbang","pw_apocalypse","fullmetal","pass","soul_sponge","nightmare"],challenge:["joyless","steelen","dissipated","technophobe","wheelbarrow","iron_will","failed_history","banana","pathfinder","ashanddust","exodus","obsolete","bluepill","retired","gross","lamentis","overlord","adam_eve"]},yn={colonist:[nn("name")]},bn={trade:[750,50]},wn={};Object.keys(fn).forEach((function(e){fn[e].forEach((t=>wn[t]={name:z(`achieve_${t}_name`),desc:bn[t]?z(`achieve_${t}_desc`,bn[t]):z(`achieve_${t}_desc`),flair:yn[t]?z(`achieve_${t}_flair`,yn[t]):z(`achieve_${t}_flair`),type:e}))}));const kn={utopia:{name:z("feat_utopia_name"),desc:z("feat_utopia_desc"),flair:z("feat_utopia_flair")},take_no_advice:{name:z("feat_take_no_advice_name"),desc:z("feat_take_no_advice_desc"),flair:z("feat_take_no_advice_flair")},ill_advised:{name:z("feat_ill_advised_name"),desc:z("feat_ill_advised_desc"),flair:z("feat_ill_advised_flair")},organ_harvester:{name:z("feat_organ_harvester_name"),desc:z("feat_organ_harvester_desc"),flair:z("feat_organ_harvester_flair")},the_misery:{name:z("feat_the_misery_name"),desc:z("feat_the_misery_desc"),flair:z("feat_the_misery_flair")},energetic:{name:z("feat_energetic_name"),desc:z("feat_energetic_desc"),flair:z("feat_energetic_flair")},garbage_pie:{name:z("feat_garbage_pie_name"),desc:z("feat_garbage_pie_desc"),flair:z("feat_garbage_pie_flair")},finish_line:{name:z("feat_finish_line_name"),desc:z("feat_finish_line_desc"),flair:z("feat_finish_line_flair")},blank_slate:{name:z("feat_blank_slate_name"),desc:z("feat_blank_slate_desc"),flair:z("feat_blank_slate_flair")},supermassive:{name:z("feat_supermassive_name"),desc:z("feat_supermassive_desc"),flair:z("feat_supermassive_flair")},steelem:{name:z("feat_steelem_name"),desc:z("feat_steelem_desc"),flair:z("feat_steelem_flair")},banana:{name:z("feat_banana_name"),desc:z("feat_banana_desc",[500,500]),flair:z("feat_banana_flair")},rocky_road:{name:z("feat_rocky_road_name"),desc:z("feat_rocky_road_desc"),flair:z("feat_rocky_road_flair")},demon_slayer:{name:z("feat_demon_slayer_name"),desc:z("feat_demon_slayer_desc"),flair:z("feat_demon_slayer_flair")},equilibrium:{name:z("feat_equilibrium_name"),desc:z("feat_equilibrium_desc"),flair:z("feat_equilibrium_flair")},digital_ascension:{name:z("feat_digital_ascension_name"),desc:z("feat_digital_ascension_desc"),flair:z("feat_digital_ascension_flair")},novice:{name:z("feat_novice_name"),desc:z("feat_achievement_hunter_desc",[10]),flair:z("feat_novice_flair")},journeyman:{name:z("feat_journeyman_name"),desc:z("feat_achievement_hunter_desc",[25]),flair:z("feat_journeyman_flair")},adept:{name:z("feat_adept_name"),desc:z("feat_achievement_hunter_desc",[50]),flair:z("feat_adept_flair")},master:{name:z("feat_master_name"),desc:z("feat_achievement_hunter_desc",[75]),flair:z("feat_master_flair")},grandmaster:{name:z("feat_grandmaster_name"),desc:z("feat_achievement_hunter_desc",[100]),flair:z("feat_grandmaster_flair")},nephilim:{name:z("feat_nephilim_name"),desc:z("feat_nephilim_desc"),flair:z("feat_nephilim_flair")},twisted:{name:z("feat_twisted_name"),desc:z("feat_twisted_desc"),flair:z("feat_twisted_flair")},slime_lord:{name:z("feat_slime_lord_name"),desc:z("feat_slime_lord_desc"),flair:z("feat_slime_lord_flair")},annihilation:{name:z("feat_annihilation_name"),desc:z("feat_annihilation_desc"),flair:z("feat_annihilation_flair")},friday:{name:z("feat_friday_name"),desc:z("feat_friday_desc"),flair:z("feat_friday_flair")},valentine:{name:z("feat_love_name"),desc:z("feat_love_desc"),flair:z("feat_love_flair")},leprechaun:{name:z("feat_leprechaun_name"),desc:z("feat_leprechaun_desc"),flair:z("feat_leprechaun_flair")},easter:{name:z("feat_easter_name"),desc:z("feat_easter_desc"),flair:z("feat_easter_flair")},egghunt:{name:z("feat_egghunt_name"),desc:z("feat_egghunt_desc"),flair:z("feat_egghunt_flair")},launch_day:{name:z("feat_launch_day_name"),desc:z("feat_launch_day_desc"),flair:z("feat_launch_day_flair")},solstice:{name:z("feat_solstice_name"),desc:z("feat_solstice_desc"),flair:z("feat_solstice_flair")},firework:{name:z("feat_firework_name"),desc:z("feat_firework_desc"),flair:z("feat_firework_flair")},halloween:{name:z("feat_boo_name"),desc:z("feat_boo_desc"),flair:z("feat_boo_flair")},trickortreat:{name:z("feat_trickortreat_name"),desc:z("feat_trickortreat_desc"),flair:z("feat_trickortreat_flair")},thanksgiving:{name:z("feat_gobble_gobble_name"),desc:z("feat_gobble_gobble_desc"),flair:z("feat_gobble_gobble_flair")},xmas:{name:z("feat_xmas_name"),desc:z("feat_xmas_desc"),flair:z("feat_xmas_flair")},fool:{name:z("feat_fool_name"),desc:z("feat_fool_desc"),flair:z("feat_fool_flair")}};{let e=$n();e.aLvl,e.uLvl}function $n(e){let a=xn(e=e||t.race.universe),r=0,i=0;return Object.keys(wn).forEach((function(e){t.stats.achieve[e]&&(r+=t.stats.achieve[e].l>5?5:t.stats.achieve[e].l,t.stats.achieve[e][a]&&(i+=t.stats.achieve[e][a]>5?5:t.stats.achieve[e][a]))})),{aLvl:r,uLvl:i}}function xn(e){switch(e=e||t.race.universe){case"evil":return"e";case"antimatter":return"a";case"heavy":return"h";case"micro":return"m";case"magic":return"mg";default:return"l"}}function qn(e,a,r,i){if("micro"!==t.race.universe&&!0===a)return!1;t.settings.msgFilters.achievements.unlocked||(t.settings.msgFilters.achievements.unlocked=!0,t.settings.msgFilters.achievements.vis=!0);let s=Mn(),n=!1,c=!1;(void 0===r||r>s)&&(r=s);let o=!0;if(void 0===t.stats.achieve[e]&&(t.stats.achieve[e]={l:0},o=!1),("micro"===t.race.universe&&!0===a||"micro"!==t.race.universe&&!0!==a)&&t.stats.achieve[e]&&t.stats.achieve[e].li)&&(r=i),!t.stats.feat[e]||t.stats.feat[e]&&t.stats.feat[e]5?5:t.stats.achieve[e].l,t.stats.achieve[e][c]&&(n+=t.stats.achieve[e][c]>5?5:t.stats.achieve[e][c]);let i=Xs(e,16,l,o);o&&t.stats.achieve[e].l>1||!o?a.append($(`
                    ${wn[e].name}${wn[e].desc}${i}
                    `)):o&&1===t.stats.achieve[e].l&&r--}})),o&&!t.stats.feat.fool){let e=$(`
                    ${kn.fool.name}${z("feat_fool_spoof")}
                    `);a.append(e)}else Object.keys(kn).forEach((function(e){let r=Vs(e,"feat");if(t.stats.feat[e]){let i=t.stats.feat[e]>1?`

                    ${Hs(r)}

                    `:"";if("easter"===e){let e=Qs(4,14);e.length>0&&(i=e)}a.append($(`
                    ${kn[e].name}${kn[e].desc}${i}
                    `))}}));let l=Js(5,12,!1);a.prepend(`
                    ${z("achieve_draw_achieve_earned",[r,i])}${l}
                    `),Cs({el:"#achievePanel",methods:{flair:e=>wn[e].flair,feat:e=>kn[e].flair}}),o&&!t.stats.feat.fool&&$("#thefool").on("mouseover",(function(){"micro"===t.race.universe?Pn("fool",!0):Pn("fool"),jn()}))}function On(){let e=Mn();$("#topBar span.flair")&&Ss($("#topBar span.flair"),!0);let a=Qs(1,14);if(a.length>0&&$("#topBar .planet").after($(a)),e>1&&0===$("#topBar .planet .flair").length){if(0===a.length){let t=Vs("topbar","challenge");$("#topBar .planet").after(`${Hs(t)}`)}let r="";t.race.no_plasmid&&(r+=`
                    ${z("evo_challenge_plasmid")}
                    `),t.race.weak_mastery&&(r+=`
                    ${z("evo_challenge_mastery")}
                    `),t.race.no_trade&&(r+=`
                    ${z("evo_challenge_trade")}
                    `),t.race.no_craft&&(r+=`
                    ${z("evo_challenge_craft")}
                    `),t.race.no_crispr&&(r+=`
                    ${z("evo_challenge_crispr")}
                    `),t.race.nerfed&&(r+=`
                    ${z("evo_challenge_nerfed")}
                    `),t.race.badgenes&&(r+=`
                    ${z("evo_challenge_badgenes")}
                    `),r.length>0&&$("#topBar .planetWrap .flair").append($(`
                    Active Challenge Genes
                    ${r}
                    `)),ls("topbarPlanet",(function(e){let t=$('
                    ');e.popper.append(t),t.append($(r))}),{elm:"#topBar .planetWrap .flair",classes:"has-background-light has-text-dark"})}}function Mn(){let e=1;return t.race.no_plasmid&&e++,t.race.no_trade&&e++,t.race.no_craft&&e++,t.race.no_crispr&&e++,t.race.weak_mastery&&e++,t.race.nerfed&&e++,t.race.badgenes&&e++,e>5&&(e=5),e}function Sn(){let e=Mn();for(let a=e;a>=0;a--)Cn("extinct_","mass_extinction",25,a),"evil"===t.race.universe&&zn("extinct_","vigilante",12,a),Cn("genus_","creator",9,a),Cn("biome_","explorer",6,a),"heavy"===t.race.universe&&zn("genus_","heavyweight",8,a);if(t.tech.supercollider&&t.tech.supercollider>=99&&qn("blackhole"),t.stats.starved>=100&&qn("mass_starvation"),Math.round(Math.log2(t.civic.garrison.protest+t.civic.garrison.fatigue))>=8&&qn("warmonger"),t.stats.died>=250&&qn("red_tactics"),t.interstellar.stellar_engine&&t.interstellar.stellar_engine.mass>=12&&qn("landfill"),t.interstellar.stellar_engine&&t.interstellar.stellar_engine.mass>=100&&Pn("supermassive"),t.tech.piracy&&t.tech.chthonian&&t.tech.chthonian>=2&&t.galaxy&&1===Mt("gxy_stargate")&&1===Mt("gxy_gateway")&&1===Mt("gxy_gorddon")&&1===Mt("gxy_alien1")&&1===Mt("gxy_alien2")&&1===Mt("gxy_chthonian")&&qn("neutralized"),cn("summer")&&t.resource.hasOwnProperty("Thermite")){let e=1e5+9e3*t.stats.reset;e>1e6&&(e=1e6),t.resource.Thermite.amount>e&&Pn("solstice","micro"===t.race.universe)}if(cn("firework")&&t[t.race.cataclysm||t.race.orbit_decayed?"space":"city"].firework.on>0&&Pn("firework","micro"===t.race.universe),t.city.morale.current>=200&&(qn("paradise"),t.city.morale.current>=500&&Pn("utopia")),t.resource.hasOwnProperty("Money")&&t.resource.Money.amount>=1e9&&qn("scrooge"),t.resource.hasOwnProperty("Money")&&t.race.inflation&&t.resource.Money.amount>=25e10&&qn("wheelbarrow"),t.civic.hasOwnProperty("govern")&&t.galaxy.hasOwnProperty("trade")&&t.city.hasOwnProperty("market")&&t.galaxy.trade.cur>=50&&t.city.market.trade>=750&&"federation"===t.civic.govern.type&&qn("trade"),t.tech.pillars){let e={},a=0,r=5;if(Object.keys(t.pillars).forEach((function(i){Ki[i]&&((!e[Ki[i].type]||t.pillars[i]>e[Ki[i].type])&&(e[Ki[i].type]=t.pillars[i]),t.pillars[i]=Object.keys(Li).length){let t=5;Object.keys(e).forEach((function(a){e[a]=Object.keys(Ki).length-1&&qn("resonance"),a>=50&&Pn("equilibrium",!1,r)}if(t.portal.hasOwnProperty("mechbay")&&t.tech.hasOwnProperty("hell_spire")&&t.tech.hell_spire>=9){let e=Object.keys(va).length,a={};Object.keys(t.stats.spire).forEach((function(r){let i={};Object.keys(t.stats.spire[r]).forEach((function(e){va[e]&&((!a.hasOwnProperty(e)||a[e]0&&(i[e]=t.stats.spire[r][e]))})),Object.keys(i).length===e&&qn("gladiator",!1,Math.min(...Object.values(i)),r)})),Object.keys(a).length===e&&qn("gladiator",!1,Math.min(...Object.values(a)),"l")}if(t.race.banana){let e=xn();t.tech.hasOwnProperty("monuments")&&t.tech.monuments>=50&&(t.stats.banana.b5[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b5.l=!0));let a=0,r=0;["b1","b2","b3","b4","b5"].forEach((function(i){t.stats.banana[i].l&&a++,"l"!==e&&t.stats.banana[i][e]&&r++})),a>0&&qn("banana",!1,a,"l"),r>0&&"l"!==e&&qn("banana",!1,r,e),t.interstellar.hasOwnProperty("stellar_engine")&&t.interstellar.stellar_engine.mass>=12&&0===t.interstellar.stellar_engine.exotic&&(t.stats.banana.b3[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b3.l=!0))}["l",xn()].forEach((function(e){let a=0;["ashanddust","exodus","obsolete","bluepill","retired"].forEach((function(r){t.stats.achieve[r]&&t.stats.achieve[r][e]&&t.stats.achieve[r][e]>=5&&a++})),a>0&&qn("pathfinder",!1,a,e)}));const a=new Date;let r=cn("easter"),i=cn("halloween"),s=a.getFullYear();if(!t.settings.boring&&13===a.getDate()&&5===a.getDay()&&t.resource[t.race.species].amount>=1){let e=!1;e=Pn("friday","micro"===t.race.universe),e&&t.resource[t.race.species].amount--}else if(t.settings.boring||1!==a.getMonth()||14!==a.getDate())if(t.settings.boring||2!==a.getMonth()||17!==a.getDate())if(r.active){Pn("easter","micro"===t.race.universe);let e=0;for(let a=1;a<=18;a++)t.special.egg[s][`egg${a}`]&&e++;e>=12&&Pn("egghunt","micro"===t.race.universe)}else if(cn("launch_day"))Pn("launch_day","micro"===t.race.universe);else if(i.active){let e=0;for(let a=1;a<=7;a++)t.special.trick[s][`trick${a}`]&&e++;for(let a=1;a<=7;a++)t.special.trick[s][`treat${a}`]&&e++;e>=12&&Pn("trickortreat","micro"===t.race.universe),9===a.getMonth()&&31===a.getDate()&&Pn("halloween","micro"===t.race.universe)}else!t.settings.boring&&10===a.getMonth()&&a.getDate()>=22&&a.getDate()<=28?Pn("thanksgiving","micro"===t.race.universe):t.settings.boring||11!==a.getMonth()||25!=a.getDate()||Pn("xmas","micro"===t.race.universe);else Pn("leprechaun","micro"===t.race.universe);else Pn("valentine","micro"===t.race.universe);!t.settings.boring&&3===a.getMonth()&&a.getDate()>=1&&a.getDate()<=3&&t.stats.feat.hasOwnProperty("fool")&&t.stats.feat.fool>0&&Pn("fool","micro"===t.race.universe),t.stats.dkills>=666e6&&Pn("demon_slayer");for(let a=e;a>=1;a--){let e=0;const r=Object.keys(wn);for(const i of r)t.stats.achieve[i]&&t.stats.achieve[i].l>=a&&e++;let i=[{c:10,f:"novice"},{c:25,f:"journeyman"},{c:50,f:"adept"},{c:75,f:"master"},{c:100,f:"grandmaster"}];for(let r=0;r<5;r++)e>=i[r].c&&(!t.stats.feat[i[r].f]||t.stats.feat[i[r].f]=i&&s++;if(s>=r&&(qn(a,!1,i),"standard"!==t.race.universe))switch(t.race.universe){case"evil":t.stats.achieve[a].e=void 0;break;case"antimatter":t.stats.achieve[a].a=void 0;break;case"heavy":t.stats.achieve[a].h=void 0;break;case"micro":t.stats.achieve[a].m=void 0;break;case"magic":t.stats.achieve[a].mg=void 0}}"standard"!==t.race.universe&&zn(e,a,r,i)}function zn(e,a,r,i){let s=!1;switch(t.race.universe){case"evil":(void 0===t.stats.achieve[a]||void 0===t.stats.achieve[a].e||t.stats.achieve[a].e=i&&s++;break;case"antimatter":t.stats.achieve[a]&&t.stats.achieve[a].a&&t.stats.achieve[a].a>=i&&s++;break;case"heavy":t.stats.achieve[a]&&t.stats.achieve[a].h&&t.stats.achieve[a].h>=i&&s++;break;case"micro":t.stats.achieve[a]&&t.stats.achieve[a].m&&t.stats.achieve[a].m>=i&&s++;break;case"magic":t.stats.achieve[a]&&t.stats.achieve[a].mg&&t.stats.achieve[a].mg>=i&&s++}s>=r&&qn(a,!1,i)}}const Fn={mastery:{name:z("mastery"),desc(){let e="";return Object.keys(Wt).forEach((function(a){let r=Es(a,!0);"standard"===a?e+=`${Wt[a].name}: ${z("perks_mastery_general",[`${+r.g.toFixed(2)}%`])}`:t.stats.achieve.whitehole&&(e+=`${Wt[a].name}: ${z("perks_mastery_general",[`${+r.g.toFixed(2)}%`])}, ${z("perks_mastery_universe",[`${+r.u.toFixed(2)}%`])}`)})),e},active:()=>!!(t.genes.challenge&&t.genes.challenge>=2),notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_unlocked_title")}`])]},blackhole:{name:z("achieve_blackhole_name"),desc:e=>z("achieve_perks_blackhole",[e?"5/10/15/20/25":t.stats.achieve.blackhole?5*t.stats.achieve.blackhole.l:5]),active:()=>!!(t.stats.achieve.blackhole&&t.stats.achieve.blackhole.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_blackhole_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_blackhole_name")}`])]},trade:{name:z("achieve_trade_name"),desc:e=>z("achieve_perks_trade",[e?"2/4/6/8/10":t.stats.achieve.trade?2*t.stats.achieve.trade.l:2,e?"1/2/3/4/5":t.stats.achieve.trade?t.stats.achieve.trade.l:1]),active:()=>!!(t.stats.achieve.trade&&t.stats.achieve.trade.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_trade_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_trade_name")}`])]},creator:{name:z("achieve_creator_name"),desc:e=>z("achieve_perks_creator",[e?"1.5/2/2.5/3/3.5":1+(t.stats.achieve.creator?.5*t.stats.achieve.creator.l:.5)]),active:()=>!!(t.stats.achieve.creator&&t.stats.achieve.creator.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_creator_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_creator_name")}`])]},mass_extinction:{name:z("achieve_mass_extinction_name"),group:[{desc:()=>z("achieve_perks_mass_extinction"),active:()=>!!(t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>=1)},{desc(e){let a=t.stats.achieve.mass_extinction?t.stats.achieve.mass_extinction.l:1;return z("achieve_perks_mass_extinction2",[e?"0/50/100/150/200":50*(a-1)])},active:()=>!!(t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_mass_extinction_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_mass_extinction_name")}`])]},doomed:{name:z("achieve_doomed_name"),desc:e=>z("achieve_perks_doomed"),active:()=>t.stats.portals>=1,notes:[z("wiki_perks_achievement_note",[`${z("achieve_doomed_name")}`])]},explorer:{name:z("achieve_explorer_name"),desc:e=>z("achieve_perks_explorer",[e?"1/2/3/4/5":t.stats.achieve.explorer?t.stats.achieve.explorer.l:1]),active:()=>!!(t.stats.achieve.explorer&&t.stats.achieve.explorer.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_explorer_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_explorer_name")}`])]},miners_dream:{name:z("achieve_miners_dream_name"),desc:e=>z("achieve_perks_miners_dream",[e?"1/2/3/5/7":t.stats.achieve.miners_dream?t.stats.achieve.miners_dream.l>=4?2*t.stats.achieve.miners_dream.l-3:t.stats.achieve.miners_dream.l:0]),active:()=>!!(t.stats.achieve.miners_dream&&t.stats.achieve.miners_dream.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_miners_dream_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_miners_dream_name")}`])]},extinct_junker:{name:z("achieve_extinct_junker_name"),desc:()=>z("achieve_perks_enlightened"),active:()=>!!(t.stats.achieve.extinct_junker&&t.stats.achieve.extinct_junker.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_extinct_junker_name")}`])]},joyless:{name:z("achieve_joyless_name"),desc:e=>z("achieve_perks_joyless",[e?"2/4/6/8/10":t.stats.achieve.joyless?2*t.stats.achieve.joyless.l:2]),active:()=>!!(t.stats.achieve.joyless&&t.stats.achieve.joyless.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_joyless_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_joyless_name")}`])]},steelen:{name:z("achieve_steelen_name"),desc:e=>z("achieve_perks_steelen",[e?"2/4/6/8/10":t.stats.achieve.steelen?2*t.stats.achieve.steelen.l:2]),active:()=>!!(t.stats.achieve.steelen&&t.stats.achieve.steelen.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_steelen_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_steelen_name")}`])]},wheelbarrow:{name:z("achieve_wheelbarrow_name"),desc:e=>z("achieve_perks_wheelbarrow",[e?"2/4/6/8/10":t.stats.achieve.wheelbarrow?2*t.stats.achieve.wheelbarrow.l:2]),active:()=>!!(t.stats.achieve.wheelbarrow&&t.stats.achieve.wheelbarrow.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_wheelbarrow_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_wheelbarrow_name")}`])]},extinct_sludge:{name:z("achieve_extinct_sludge_name"),group:[{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.l:3,z("universe_standard")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.l>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.h:3,z("universe_heavy")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.h>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.a:3,z("universe_antimatter")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.a>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.e:3,z("universe_evil")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.e>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.m:3,z("universe_micro")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.m>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.mg:3,z("universe_magic")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.mg>=1)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_extinct_sludge_name")}`]),z("wiki_perks_achievement_note_universe_scale",[`${z("achieve_extinct_sludge_name")}`])]},whitehole:{name:z("achieve_whitehole_name"),group:[{desc:()=>z("achieve_perks_whitehole"),active:()=>!!t.stats.achieve.whitehole},{desc:e=>z("achieve_perks_whitehole2",[e?"5/10/15/20/25":t.stats.achieve.whitehole?5*t.stats.achieve.whitehole.l:5]),active:()=>!!t.stats.achieve.whitehole},{desc:e=>z("achieve_perks_whitehole3",[e?"1/2/3/4/5":t.stats.achieve.whitehole?t.stats.achieve.whitehole.l:1]),active:()=>!!t.stats.achieve.whitehole}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_whitehole_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_whitehole_name")}`])]},heavyweight:{name:z("achieve_heavyweight_name"),desc:e=>z("achieve_perks_heavyweight",[e?"4/8/12/16/20":t.stats.achieve.heavyweight?4*t.stats.achieve.heavyweight.l:4]),active:()=>!!t.stats.achieve.heavyweight,notes:[z("wiki_perks_achievement_note",[`${z("achieve_heavyweight_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_heavyweight_name")}`])]},dissipated:{name:z("achieve_dissipated_name"),group:[{desc:()=>z("achieve_perks_dissipated1",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1)},{desc:e=>z("achieve_perks_dissipated2",[e?"1/2":t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=5?2:1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3)},{desc:()=>z("achieve_perks_dissipated3",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2)},{desc:()=>z("achieve_perks_dissipated4",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=4)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_dissipated_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_dissipated_name")}`])]},banana:{name:z("achieve_banana_name"),group:[{desc:()=>z("achieve_perks_banana1",[50]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=1)},{desc:()=>z("achieve_perks_banana2",[1]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=2)},{desc:()=>z("achieve_perks_banana3",[10]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=3)},{desc:()=>z("achieve_perks_banana4",[3]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=4)},{desc:()=>z("achieve_perks_banana5",[.01]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=5)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_banana_name")}`]),z("wiki_perks_achievement_note_task",[`${z("achieve_banana_name")}`]),z("wiki_perks_achievement_note_task_num",[1,`${z("wiki_achieve_banana1")}`]),z("wiki_perks_achievement_note_task_num",[2,`${z("wiki_achieve_banana2")}`]),z("wiki_perks_achievement_note_task_num",[3,`${z("wiki_achieve_banana3")}`]),z("wiki_perks_achievement_note_task_num",[4,`${z("wiki_achieve_banana4",[500])}`]),z("wiki_perks_achievement_note_task_num",[5,`${z("wiki_achieve_banana5",[50])}`])]},anarchist:{name:z("achieve_anarchist_name"),desc:e=>z("achieve_perks_anarchist",[e?"10/20/30/40/50":t.stats.achieve.anarchist?10*t.stats.achieve.anarchist.l:10]),active:()=>!!(t.stats.achieve.anarchist&&t.stats.achieve.anarchist.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_anarchist_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_anarchist_name")}`])]},ascended:{name:z("achieve_ascended_name"),group:[{desc(e){let a;if(e)a="1-30";else if(a=0,t.stats.achieve.ascended)for(let e=0;e!!(t.stats.achieve.ascended&&t.stats.achieve.ascended.l>=1)},{desc:()=>z("achieve_perks_ascended2",[js()]),active:()=>!!(t.stats.achieve.ascended&&t.stats.achieve.ascended[xn()]>=1)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_ascended_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_ascended_name")}`]),z("wiki_perks_achievement_note_universe",[`${z("achieve_ascended_name")}`])]},technophobe:{name:z("achieve_technophobe_name"),group:[{desc:()=>z("achieve_perks_technophobe1",[25]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1)},{desc(e){let a;if(e)a="10/25/30/35/40/45/50";else{a=t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=4?25:10;for(let e=1;e=5&&(a+=5)}return z("achieve_perks_technophobe2",[a])},active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2)},{desc(e){let a;if(e)a="1/2/3/4/5/6";else{a=1;for(let e=1;e=5&&(a+=1)}return z(e||a>1?"achieve_perks_technophobe3a":"achieve_perks_technophobe3",[a])},active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=3)},{desc:()=>z("achieve_perks_technophobe4",[10]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=5)},{desc:e=>z("achieve_perks_technophobe5",[e?"1/2/3/4/5":t.stats.achieve.technophobe?t.stats.achieve.technophobe.l:0]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_technophobe_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_technophobe_name")}`]),z("wiki_perks_achievement_note_universe",[`${z("achieve_technophobe_name")}`])]},iron_will:{name:z("achieve_iron_will_name"),group:[{desc:()=>z("achieve_perks_iron_will1",[.15]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1)},{desc:()=>z("achieve_perks_iron_will2",[10]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2)},{desc:()=>z("achieve_perks_iron_will3",[6]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3)},{desc:()=>z("achieve_perks_iron_will4",[1]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=4)},{desc:()=>z("achieve_perks_iron_will5"),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=5)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_iron_will_name")}`]),z("wiki_perks_achievement_note_ironwill",[`${z("evo_challenge_cataclysm")}`]),z("wiki_perks_achievement_note_ironwill2",[1,`${z("space_red_ziggurat_title")}`]),z("wiki_perks_achievement_note_ironwill3",[2,`${z("tech_elerium_mining")}`]),z("wiki_perks_achievement_note_ironwill3",[3,`${z("tech_lasers")}`]),z("wiki_perks_achievement_note_ironwill3",[4,`${z("tech_generational_ship")}`]),z("wiki_perks_achievement_note_ironwill4",[5,`${z("wiki_resets_bioseed")}`])]},failed_history:{name:z("achieve_failed_history_name"),desc:()=>z("achieve_perks_failed_history",[2]),active:()=>!!(t.stats.achieve.failed_history&&t.stats.achieve.failed_history.l>=5),notes:[z("wiki_perks_achievement_note",[`${z("achieve_failed_history_name")}`]),z("wiki_perks_achievement_note_failed_history",[`${z("evo_challenge_cataclysm")}`])]},lamentis:{name:z("achieve_lamentis_name"),group:[{desc:()=>z("achieve_perks_lamentis1",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=1)},{desc:()=>z("achieve_perks_lamentis2",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=2)},{desc:()=>z("achieve_perks_lamentis3",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=3)},{desc:()=>z("achieve_perks_lamentis4"),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=4)},{desc:()=>z("achieve_perks_lamentis5"),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_lamentis_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_lamentis_name")}`])]},soul_sponge:{name:z("achieve_soul_sponge_name"),desc:e=>z("achieve_perks_soul_sponge",[e?"100/200/300/400/500":t.stats.achieve.soul_sponge?100*t.stats.achieve.soul_sponge.mg:100]),active:()=>!!(t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_soul_sponge_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_soul_sponge_name")}`])]},nightmare:{name:z("achieve_nightmare_name"),desc:()=>z("achieve_perks_nightmare"),active:()=>!!(t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_nightmare_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_nightmare_name")}`])]},gladiator:{name:z("achieve_gladiator_name"),desc:e=>z("achieve_perks_gladiator",[e?"20/40/60/80/100":t.stats.achieve.gladiator?20*t.stats.achieve.gladiator.l:20]),active:()=>!!(t.stats.achieve.gladiator&&t.stats.achieve.gladiator.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_gladiator_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_gladiator_name")}`])]},pathfinder:{name:z("achieve_pathfinder_name"),group:[{desc:()=>z("achieve_perks_pathfinder1",[10]),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1)},{desc:()=>z("achieve_perks_pathfinder2",[10]),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2)},{desc:()=>z("achieve_perks_pathfinder3"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=3)},{desc:()=>z("achieve_perks_pathfinder4"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=4)},{desc:()=>z("achieve_perks_pathfinder5"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=5)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_pathfinder_name")}`]),z("wiki_perks_achievement_note_pathfinder",[`${z("evo_challenge_truepath")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_mad")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_bioseed")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_ai")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_matrix")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_retired")}`])]},overlord:{name:z("achieve_overlord_name"),desc(){let e=`
                    ${z("achieve_perks_overlord1",[10])}
                    `;return e+=`
                    ${z("achieve_perks_overlord2")}
                    `,e+=`
                    ${z("achieve_perks_overlord3")}
                    `,e+=`
                    ${z("achieve_perks_overlord4")}
                    `,e},active:()=>!!(t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5),notes:[z("wiki_perks_achievement_note",[`${z("achieve_overlord_name")}`])]},adam_eve:{name:z("achieve_adam_eve_name"),desc:()=>z("achieve_perks_adam_eve"),active:()=>!!(t.stats.achieve.adam_eve&&t.stats.achieve.adam_eve.l>=5),notes:[]},creep:{name:z("wiki_arpa_crispr_creep"),desc:e=>z("arpa_perks_creep",[e?"0.01/0.02/0.03/0.04/0.05":t.genes.creep?.01*t.genes.creep:0]),active:()=>!!t.genes.creep,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_genetic_memory_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_animus_title")}`,`${z("arpa_genepool_divine_remembrance_title")}`,`${z("arpa_genepool_divine_proportion_title")}`,`${z("arpa_genepool_genetic_repository_title")}`].join(", ")])]},store:{name:z("wiki_arpa_crispr_store"),desc(e){let a=e?"0.04/0.06/0.08":t.genes.store&&t.genes.store>1?2===t.genes.store?.06:.08:.04;return z(t.genes.store&&t.genes.store>=4?"arpa_perks_store2":"arpa_perks_store1",[a])},active:()=>!!t.genes.store,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_spatial_reasoning_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_spatial_superiority_title")}`,`${z("arpa_genepool_spatial_supremacy_title")}`,`${z("arpa_genepool_dimensional_warping_title")}`].join(", ")])]},evolve:{name:z("wiki_arpa_crispr_evolve"),group:[{desc:()=>z("arpa_perks_evolve"),active:()=>!!t.genes.evolve},{desc:()=>z("arpa_genepool_recombination_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=2)},{desc:()=>z("arpa_genepool_homologous_recombination_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=3)},{desc:()=>z("arpa_genepool_genetic_reshuffling_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=4)},{desc:()=>z("arpa_genepool_recombinant_dna_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=5)},{desc:()=>z("arpa_genepool_chimeric_dna_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=6)},{desc:()=>z("arpa_genepool_molecular_cloning_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=7)},{desc:()=>z("arpa_genepool_transgenes_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=8)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_morphogenesis_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_recombination_title")}`,`${z("arpa_genepool_homologous_recombination_title")}`,`${z("arpa_genepool_genetic_reshuffling_title")}`,`${z("arpa_genepool_recombinant_dna_title")}`,`${z("arpa_genepool_chimeric_dna_title")}`,`${z("arpa_genepool_molecular_cloning_title")}`,`${z("arpa_genepool_transgenes_title")}`].join(", ")])]},birth:{name:z("wiki_arpa_crispr_birth"),desc:()=>z("arpa_perks_birth"),active:()=>!!t.genes.birth,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_replication_title")}`])]},enhance:{name:z("wiki_arpa_crispr_enhance"),desc:()=>z("arpa_perks_enhance"),active:()=>!!t.genes.enhance,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_enhanced_muscle_fiber_title")}`])]},crafty:{name:z("wiki_arpa_crispr_crafty"),group:[{desc:()=>z("arpa_genepool_artificer_desc"),active:()=>!!t.genes.crafty},{desc:e=>z("arpa_genepool_crafting_desc",[e?"50/100":t.genes.crafty&&t.genes.crafty>=3?100:50]),active:()=>!!(t.genes.crafty&&t.genes.crafty>=2)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_artificer_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_detail_oriented_title")}`,`${z("arpa_genepool_rigorous_title")}`].join(", ")])]},governor:{name:z("wiki_arpa_crispr_governor"),desc:()=>z("arpa_perks_governor"),active:()=>!!t.genes.governor,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_governance_title")}`])]},synthesis:{name:z("wiki_arpa_crispr_synthesis"),desc:e=>z("arpa_genepool_synthesis_desc",[e?"2/3/4":t.genes.synthesis&&t.genes.synthesis>=2?t.genes.synthesis>=3?4:3:2,e?"10/25/50":t.genes.synthesis&&t.genes.synthesis>=2?t.genes.synthesis>=3?50:25:10]),active:()=>!!t.genes.synthesis,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_synthesis_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_karyokinesis_title")}`,`${z("arpa_genepool_cytokinesis_title")}`].join(", ")])]},challenge:{name:z("wiki_arpa_crispr_challenge"),group:[{desc:()=>z("arpa_perks_challenge"),active:()=>!!t.genes.challenge},{desc:()=>z("arpa_genepool_unlocked_desc"),active:()=>!!(t.genes.challenge&&t.genes.challenge>=2)},{desc:e=>z("arpa_perks_challenge2",[e?"60/80":t.genes.challenge&&t.genes.challenge>=4?80:60,e?"60/40":t.genes.challenge&&t.genes.challenge>=4?40:60]),active:()=>!!(t.genes.challenge&&t.genes.challenge>=3)},{desc:()=>z("arpa_perks_challenge3"),active:()=>!!(t.genes.challenge&&t.genes.challenge>=5)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_hardened_genes_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_unlocked_title")}`,`${z("arpa_genepool_universal_title")}`,`${z("arpa_genepool_standard_title")}`,`${z("arpa_genepool_mastered_title")}`].join(", ")]),z("wiki_perks_crispr_note_challenge",[z("arpa_genepool_universal_title"),z("arpa_genepool_standard_title")])]},ancients:{name:z("wiki_arpa_crispr_ancients"),group:[{desc:()=>z("arpa_perks_ancients"),active:()=>!!t.genes.ancients},{desc:()=>t.genes.ancients&&t.genes.ancients>=4?z("arpa_perks_ancients3"):z("arpa_perks_ancients2"),active:()=>!!(t.genes.ancients&&t.genes.ancients>=2)},{desc:e=>z("arpa_perks_ancients4",[e?"25/50":t.genes.ancients&&t.genes.ancients>=5?50:25]),active:()=>!!(t.genes.ancients&&t.genes.ancients>=3)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_ancients_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_faith_title")}`,`${z("arpa_genepool_devotion_title")}`,`${z("arpa_genepool_acolyte_title")}`,`${z("arpa_genepool_conviction_title")}`].join(", ")])]},trader:{name:z("wiki_arpa_crispr_trader"),desc:()=>z("arpa_genepool_negotiator_desc"),active:()=>!!t.genes.trader,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_negotiator_title")}`])]},transcendence:{name:z("wiki_arpa_crispr_transcendence"),desc:()=>z("arpa_genepool_transcendence_desc"),active:()=>!!t.genes.transcendence,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_transcendence_title")}`])]},queue:{name:z("wiki_arpa_crispr_queue"),group:[{desc:()=>z("arpa_genepool_geographer_desc"),active:()=>!!t.genes.queue},{desc:()=>z("arpa_genepool_architect_desc"),active:()=>!!(t.genes.queue&&t.genes.queue>=2)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_geographer_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_architect_title")}`].join(", ")])]},plasma:{name:z("wiki_arpa_crispr_plasma"),desc:e=>z("arpa_genepool_mitosis_desc",[e?"3/5":t.genes.plasma>=2?5:3]),active:()=>!!t.genes.plasma,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_mitosis_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_metaphase_title")}`].join(", ")])]},mutation:{name:z("wiki_arpa_crispr_mutation"),group:[{desc:()=>t.genes.mutation&&t.genes.mutation>1?z("arpa_perks_mutation2"):z("arpa_perks_mutation1"),active:()=>!!t.genes.mutation},{desc:()=>z("arpa_perks_mutation3"),active:()=>!!(t.genes.mutation&&t.genes.mutation>=3)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_mutation_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_transformation_title")}`,`${z("arpa_genepool_metamorphosis_title")}`].join(", ")])]},bleed:{name:z("wiki_arpa_crispr_bleed"),group:[{desc:()=>z("arpa_genepool_bleeding_effect_desc",[2.5]),active:()=>!!t.genes.bleed},{desc:()=>z("arpa_genepool_synchronicity_desc",[25]),active:()=>!!(t.genes.bleed&&t.genes.bleed>=2)},{desc:()=>z("arpa_genepool_astral_awareness_desc"),active:()=>!!(t.genes.bleed&&t.genes.bleed>=3)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_bleeding_effect_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_synchronicity_title")}`,`${z("arpa_genepool_astral_awareness_title")}`].join(", ")]),z("wiki_perks_crispr_note_bleed",[`${z("arpa_genepool_bleeding_effect_title")}`])]},blood:{name:z("wiki_arpa_crispr_blood"),group:[{desc:()=>z("arpa_genepool_blood_remembrance_desc"),active:()=>!!t.genes.blood},{desc:()=>z("arpa_genepool_blood_sacrifice_desc"),active:()=>!!(t.genes.blood&&t.genes.blood>=2)},{desc:()=>z("arpa_genepool_essence_absorber_desc"),active:()=>!!(t.genes.blood&&t.genes.blood>=3)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_blood_remembrance_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_blood_sacrifice_title")}`,`${z("arpa_genepool_essence_absorber_title")}`].join(", ")]),z("wiki_perks_crispr_note_blood",[z("arpa_genepool_blood_remembrance_title")])]},spire:{name:z("wiki_arpa_blood_spire"),group:[{desc:()=>z("arpa_blood_purify_desc"),active:()=>!!t.blood.spire},{desc:()=>z("arpa_blood_chum_desc"),active:()=>!!(t.blood.spire&&t.blood.spire>=2)}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_purify_title")}`]),z("wiki_perks_blood_note_upgrade",[[`${z("arpa_blood_chum_title")}`].join(", ")])]},lust:{name:z("wiki_arpa_blood_lust"),group:[{desc:e=>z("arpa_perks_lust",[e?.2:.2*(t.blood.lust?t.blood.lust:1)]),active:()=>!!t.blood.lust}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_lust_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_lust_title")])]},illuminate:{name:z("wiki_arpa_blood_illuminate"),group:[{desc:e=>z("arpa_perks_illuminate",[e?.01:.01*(t.blood.illuminate?t.blood.illuminate:1)]),active:()=>!!t.blood.illuminate}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_illuminate_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_illuminate_title")])]},greed:{name:z("wiki_arpa_blood_greed"),group:[{desc:e=>z("arpa_perks_greed",[e?1:1*(t.blood.greed?t.blood.greed:1)]),active:()=>!!t.blood.greed}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_greed_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_greed_title")])]},hoarder:{name:z("wiki_arpa_blood_hoarder"),group:[{desc:e=>z("arpa_perks_hoarder",[e?1:1*(t.blood.hoarder?t.blood.hoarder:1)]),active:()=>!!t.blood.hoarder}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_hoarder_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_hoarder_title")])]},artisan:{name:z("wiki_arpa_blood_artisan"),group:[{desc:e=>z("arpa_perks_artisan",[e?1:1*(t.blood.artisan?t.blood.artisan:1)]),active:()=>!!t.blood.artisan}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_artisan_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_artisan_title")])]},attract:{name:z("wiki_arpa_blood_attract"),group:[{desc:e=>z("arpa_perks_attract",[e?5:5*(t.blood.attract?t.blood.attract:1)]),active:()=>!!t.blood.attract}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_attract_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_attract_title")])]},wrath:{name:z("wiki_arpa_blood_wrath"),group:[{desc:e=>z("arpa_perks_wrath",[e?5:5*(t.blood.wrath?t.blood.wrath:1)]),active:()=>!!t.blood.wrath}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_wrath_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_wrath_title")])]},prepared:{name:z("wiki_arpa_blood_prepared"),group:[{desc:()=>z("arpa_blood_prepared_desc"),active:()=>!!t.blood.prepared},{desc:()=>z("arpa_blood_compact_desc"),active:()=>!!(t.blood.prepared&&t.blood.prepared>=2)}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_prepared_title")}`]),z("wiki_perks_blood_note_upgrade",[[`${z("arpa_blood_compact_title")}`].join(", ")])]},unbound:{name:z("wiki_arpa_blood_unbound"),group:[{desc:()=>z("arpa_blood_unbound_desc"),active:()=>!!t.blood.unbound},{desc:()=>z("arpa_blood_shadow_war_desc"),active:()=>!!(t.blood.unbound&&t.blood.unbound>=3)},{desc:e=>z("arpa_perks_unbound_resist",[e?"10/5":t.blood.unbound&&t.blood.unbound>=4?5:10]),active:()=>!!(t.blood.unbound&&t.blood.unbound>=2)}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_unbound_title")}`]),z("wiki_perks_blood_note_upgrade",[[`${z("arpa_blood_unbound_resistance_title")}`,`${z("arpa_blood_shadow_war_title")}`,`${z("arpa_blood_unbound_immunity_title")}`].join(", ")])]},aware:{name:z("wiki_arpa_blood_aware"),group:[{desc:()=>z("arpa_blood_blood_aware_desc"),active:()=>!!t.blood.aware}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_blood_aware_title")}`])]},harmonic:{name:z("harmonic"),group:[{desc(e){let t=Ks();return z("perks_harmonic",[e?`1-${Object.keys(Ki).length+2}`:+(100*(t[0]-1)).toFixed(0),e?"2-"+2*(Object.keys(Ki).length+2):+(100*(t[1]-1)).toFixed(0)])},active(){let e=Ks();return!!(t.pillars&&e[0]>1)}},{desc:e=>(Ks(),z("perks_harmonic2",[z("portal_west_tower"),z("portal_east_tower"),e?"12-"+12*(Object.keys(Ki).length-1):12*Object.keys(t.pillars).length])),active(){let e=Ks();return!!(t.pillars&&e[0]>1)}}],notes:[z("wiki_perks_harmonic_note1"),z("wiki_perks_harmonic_note2")]},novice:{name:z("perk_novice"),desc(e){let a=t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0?Math.min(t.stats.achieve.apocalypse.l,t.stats.feat.novice):1;return`
                    ${z("achieve_perks_novice",[e?"0.5/1/1.5/2/2.5":a/2,e?"0.25/0.5/0.75/1/1.25":a/4])}
                    ${z("achieve_perks_novice2")}
                    `},active:()=>!!(t.stats.feat.novice&&t.stats.mad>0),notes:[z("wiki_perks_progress_note1",[10,z("wiki_resets_mad")]),z("wiki_perks_progress_note2")]},journeyman:{name:z("perk_journeyman"),desc(e){let a=t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0?Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman):1;return e||a>1?`
                    ${z("achieve_perks_journeyman2",[e?"1/2/3":a>=3?a>=5?3:2:1,e?"1/2":a>=4?2:1])}
                    ${z("achieve_perks_journeyman3")}
                    `:`
                    ${z("achieve_perks_journeyman1",[1])}
                    ${z("achieve_perks_journeyman3")}
                    `},active:()=>!!(t.stats.feat.journeyman&&t.stats.bioseed>0),notes:[z("wiki_perks_progress_note1",[25,z("wiki_resets_bioseed")]),z("wiki_perks_progress_note2")]},adept:{name:z("perk_adept"),desc(e){let a=t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0?Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept):1;return z("achieve_perks_adept",[e?"100/200/300/400/500":100*a,e?"60/120/180/240/300":60*a])},active:()=>!!(t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0),notes:[z("wiki_perks_progress_note1",[50,z("wiki_resets_blackhole")]),z("wiki_perks_progress_note2")]},master:{name:z("perk_master"),desc(e){let a=t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0?Math.min(t.stats.achieve.ascended.l,t.stats.feat.master):1;return z("achieve_perks_master",[e?"1/2/3/4/5":a,e?"2/4/6/8/10":2*a,z("evo_mitochondria_title"),z("evo_eukaryotic_title"),z("evo_membrane_title"),z("evo_organelles_title"),z("evo_nucleus_title")])},active:()=>!!(t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0),notes:[z("wiki_perks_progress_note1",[75,z("wiki_resets_ascension")]),z("wiki_perks_progress_note2")]},grandmaster:{name:z("perk_grandmaster"),desc(e){let a=t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):1;return z("achieve_perks_grandmaster",[e?"1/2/3/4/5":a])},active:()=>!!(t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0),notes:[z("wiki_perks_progress_note1",[100,z("wiki_resets_infusion")]),z("wiki_perks_progress_note2")]}};function An(){Ss($("#perksPanel"));let e=$("#perksPanel"),t=!1;Object.keys(Fn).forEach((function(a){if(Fn[a].hasOwnProperty("group")){let r=!1,i=$(`
                    ${Fn[a].name}
                    `);Fn[a].group.forEach((function(e){e.active()&&(r=!0,i.append($(`
                    ${e.desc()}
                    `)))})),r&&(t=!0,e.append(i))}else Fn[a].active()&&(t=!0,e.append($(`
                    ${Fn[a].name}${Fn[a].desc()}
                    `)))})),t||e.append($(`
                    ${z("perks_none")}
                    `))}function In(e,t,a){if(!t.hasOwnProperty("name"))return;if(!t.hasOwnProperty("template"))return;t.hasOwnProperty("paragraphs")||(t.paragraphs=0),t.hasOwnProperty("text")||(t.text={}),t.hasOwnProperty("rawtext")||(t.rawtext={}),t.hasOwnProperty("para_data")||(t.para_data={}),t.hasOwnProperty("data_color")||(t.data_color={}),t.hasOwnProperty("data_link")||(t.data_link={}),t.hasOwnProperty("h_level")||(t.h_level=3),t.hasOwnProperty("header")||(t.header=!1),t.hasOwnProperty("full")||(t.full=!1),t.hasOwnProperty("break")||(t.break=!1),t.hasOwnProperty("default_color")||(t.default_color="warning"),t.hasOwnProperty("examples")||(t.examples=!1);let r=!1;a?r=a:(r=$(`
                    `),t.h_level&&r.append(`${t.label?t.label:z(`wiki_${t.template}_${t.name}`)}`));let i=[{s:1,e:t.break?t.break[0]-1:t.paragraphs}];if(t.break)for(let e=0;e');for(let r=e.s;r<=e.e;r++)if((t.text[r]||t.rawtext[r]||t.para_data[r])&&Array.isArray(t.para_data[r])){let e=t.para_data[r];if(t.data_link[r]&&Array.isArray(t.data_link[r]))for(let a=0;a${e[a]}`);let i=t.data_color[r]&&Array.isArray(t.data_color[r])?t.data_color[r]:t.para_data[r].map((e=>t.default_color));for(let t=0;t${e[t]}`);let s=t.rawtext[r]?t.rawtext[r]:z(t.text[r]?t.text[r]:`wiki_${t.template}_${t.name}_para${r}`,e);a.append(`${s}`)}else{let e=t.rawtext[r]?t.rawtext[r]:z(t.text[r]?t.text[r]:`wiki_${t.template}_${t.name}_para${r}`);a.append(`${e}`)}r.append(a)})),t.examples&&(r.append($(`
                    ${z("wiki_examples")}
                    `)),t.examples.forEach((function(e){r.append($(`
                    - ${e}
                    `))}))),a||e.append(r),r}function Tn(e,a,r,i){let s="string"==typeof a.title?a.title:a.title();if(r)e.append(`

                    ${s}

                    ${r}
                    `);else if(i)e.append(`

                    ${s}

                    `);else{let r=t.tech[a.grant[0]]&&t.tech[a.grant[0]]>=a.grant[1];e.append(`

                    ${s}

                    ${r?`${z("wiki_arpa_purchased")}`:""}${z(`wiki_tech_tree_${a.grant[0]}`)}: ${a.grant[1]}
                    `)}let n="string"==typeof a.desc?a.desc:a.desc(!0);n!==s&&e.append(`
                    ${n}
                    `);let c=$('
                    '),o=!1;if(a.hasOwnProperty("effect")){if(i){let e="string"==typeof a.effect&&a.effect;!1!==e?c.append(`
                    ${e}
                    `):c.append('
                    '),o=!0}else{let e="string"==typeof a.effect?a.effect:a.effect(!0);!1!==e&&(c.append(`
                    ${e}
                    `),o=!0)}e.append(c)}if(a.hasOwnProperty("cost")){let r=Ns(a,!0),s=o?$(`
                    `):$(`
                    `),n="";i&&(s.append($(`

                    ${z("wiki_calc_cost")}

                    `)),n=$(`

                    ${z("wiki_calc_cost_creep")}

                    `));let l=!1,_=function(e,t,a,r,c){i?(s.append($(`
                    ${a}{{ r.${e}.cost }}
                    `)),n.append($(`
                    {{ r.${e}.creep }}
                    `)),l=!0):t>0&&(s.append($(`
                    ${a}${x(t,1)}
                    `)),l=!0)},d="has-text-success";Object.keys(r).forEach((function(e){if("Structs"===e){let t=r[e]();Object.keys(t).forEach((function(e){Object.keys(t[e]).forEach((function(a){let r=t[e][a].hasOwnProperty("on")?t[e][a].on:t[e][a].count,c="";if(t[e][a].hasOwnProperty("s")){let r=t[e][a].s;c="string"==typeof Mr[e][r][a].title?Mr[e][r][a].title:Mr[e][r][a].title()}else c="string"==typeof Mr[e][a].title?Mr[e][a].title:Mr[e][a].title();s.append($(`
                    ${c}: ${r}
                    `)),i&&n.append($(`
                    ${z("wiki_calc_none")}
                    `)),l=!0}))}))}else if(["Plasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone","AntiPlasmid"].includes(e)){let a=e;"Plasmid"===e&&"antimatter"===t.race.universe&&(a="AntiPlasmid"),_(e,r[e](),z(`resource_${a}_name`)+": ",d)}else if("Supply"===e)_(e,r[e](),z(`resource_${e}_name`)+": ",d);else if("Custom"===e)s.append($(`
                    ${r[e]().label}
                    `)),l=!0;else if("Morale"!==e&&"Army"!==e&&"Bool"!==e){let a="Species"===e?t.race.species:e,i="Money"===a?"$":("HellArmy"===e?z("fortress_troops"):t.resource[a].name)+": ";i=i.replace("_"," "),_(e,r[e](),i,d)}})),l&&(a.hasOwnProperty("effect")||e.append(c),c.append(s),i&&c.append(n))}}function Ln(e,t,a,r){if("create"===e){let e=t?"string"==typeof t?$(`#${t}`):t:$("#content");Ss(e),e.addClass("flex");let a=$('
                    '),r=$('
                    '),i=$("
                      ");return e.append(a),e.append(r),r.append(i),a}{let e=$(`${r}`),s=$("
                    • ");s.append(e),$("#sideContent ul").append(s),i=a,e.click((function(){window.location.hash=`#${i}`,document.getElementById(i).scrollIntoView({block:"start",behavior:"smooth"})}))}var i}function En(e,t,a,r){Ln(e,t,a,"ᄂ"+r)}function Kn(e){return["moon","belt"].includes(e)?z("space_"+e+"_info_name"):["kuiper"].includes(e)?z("space_"+e+"_title"):Ut()[e]}function Dn(e,t,a,r){let i=$("
                      ");e.append(i),i.append(`{{ vis | label }}`);let s=$(``);i.append(s);let n=document.getElementById(t+a+"Section"),c={vis:!1};return Cs({el:`#${t}${a}Button`,data:c,methods:{show(){"block"===n.style.display?(n.style.display="none",c.vis=!1):(n.style.display="block",c.vis=!0)}},filters:{label:e=>z(e?"wiki_reveal_hide":"wiki_reveal_show",[r])}}),s}function Bn(e,t,a,r){r=r||z("wiki_calc_insert_"+a);let i=$("
                      ");e.append(i),i.append(`{{ vis | label }}`);let s=$(``);i.append(s);let n=document.getElementById(t+a+"Section"),c={vis:!1};return Cs({el:`#${t}${a}Button`,data:c,methods:{show(){"block"===n.style.display?(n.style.display="none",c.vis=!1):(n.style.display="block",c.vis=!0)}},filters:{label:e=>z(e?"wiki_calc_hide":"wiki_calc_show",[r])}}),s}function Gn(e){let t=$('
                      '),a=(r=e,(i={name:"planet",template:"planet",paragraphs:4,full:!0,para_data:{2:[365,"25%"],3:[4],4:["200-600"]}}).hasOwnProperty("h_level")||(i.h_level=2),i.header=!0,In(r,i,undefined));var r,i;In(e,{name:"geology",template:"planet",label:z("wiki_menu_planets"),paragraphs:4,h_level:2,para_data:{2:[2],3:["-10%","+19%"],4:[7,"+44%"]}},a);let s=Rn(is,$(`

                      ${z("wiki_planet_biome")}

                      `)),n=Rn(ss,$(`

                      ${z("wiki_planet_trait")}

                      `));t.append(s),t.append(n),e.append(t)}Da(!0);const Nn={oceanic:["trait","genus"],forest:["genus"],desert:["trait","genus"],volcanic:["weather","genus"],tundra:["weather","genus"],savanna:["condition"],swamp:["trait","trait2","genus","condition"],ashland:["weather","trait","genus","condition"],taiga:["weather","genus","condition"],hellscape:["weather","genus","universe"],eden:["geology","genus","universe"],stormy:["trait"],ozone:["trait"],trashed:["trait"],elliptical:["trait"],flare:["event"],unstable:["trait","event"],permafrost:["trait"],retrograde:["trait"]};function Rn(e,t){return Object.keys(e).forEach((function(a){let r=e[a],i=$(`
                      `);t.append(i),i.append(`

                      ${r.label}

                      `),i.append(`
                      ${r.desc}
                      `);let s=$('
                      ');if(r.vars&&r.wiki)for(let e=0;e${z(`wiki_planet_${a}${e}`,[Hn(r.vars()[e],t)])}
                      `))}i.append(s),Nn[a]&&Nn[a].forEach((function(e){i.append($(`
                      ${z(`wiki_planet_${a}_${e}`)}
                      `))}))})),t}function Hn(e,a){let r=e-1*("percent"===a||"inverted"===a?1:0);"inverted"!==a&&"inverted-decimal"!==a||(r*=-1,a="inverted"===a?"percent":"decimal");let i=(r>=0?"+":"")+r.toLocaleString(t.settings.locale,{style:a,maximumFractionDigits:2});return`${i}`}function Un(e,a){let r=Ln("create");switch(e){case"prehistoric":!function(e,a){let r="truepath"===a?"tp_structures":"structures";Object.keys(Mr.evolution).forEach((function(i){if(Mr.evolution[i].hasOwnProperty("title")&&("custom"!==i||t.hasOwnProperty("custom"))&&(!Mr.evolution[i].hasOwnProperty("wiki")||Mr.evolution[i].wiki)){let t=Mr.evolution[i].id.split("-"),s=$(`
                      `);e.append(s),Tn(s,Mr.evolution[i],!1,!0),Wn(s,"prehistoric",i),Yn(s,i,"prehistoric",!1,a),Ln("add",`prehistoric-${r}`,t[1],"function"==typeof Mr.evolution[i].title?Mr.evolution[i].title():Mr.evolution[i].title)}}))}(r,a);break;case"planetary":!function(e,t){let a="truepath"===t?"tp_structures":"structures";Object.keys(Mr.city).forEach((function(r){if((!Mr.city[r].hasOwnProperty("wiki")||Mr.city[r].wiki)&&(!Mr.city[r].hasOwnProperty("path")||Mr.city[r].path.includes(t))){let i=Mr.city[r].id.split("-"),s=$(`
                      `);e.append(s),Tn(s,Mr.city[r],!1,!0),Wn(s,"planetary",r),Yn(s,r,"planetary",!1,t),Ln("add",`planetary-${a}`,i[1],"function"==typeof Mr.city[r].title?Mr.city[r].title():Mr.city[r].title)}}))}(r,a);break;case"space":!function(e,t){let a="truepath"===t?"tp_structures":"structures";Object.keys(Mr.space).forEach((function(r){let i="string"==typeof Mr.space[r].info.name?Mr.space[r].info.name:Mr.space[r].info.name(),s="string"==typeof Mr.space[r].info.desc?Mr.space[r].info.desc:Mr.space[r].info.desc();Object.keys(Mr.space[r]).forEach((function(n){if("info"!==n&&(!Mr.space[r][n].hasOwnProperty("wiki")||Mr.space[r][n].wiki)&&(!Mr.space[r][n].hasOwnProperty("path")||Mr.space[r][n].path.includes(t))){let c=Mr.space[r][n].id.split("-"),o=$(`
                      `);e.append(o),Tn(o,Mr.space[r][n],`${i}`,!0),Wn(o,"space",n),Yn(o,n,"space",r,t),Ln("add",`space-${a}`,c[1],"function"==typeof Mr.space[r][n].title?Mr.space[r][n].title():Mr.space[r][n].title),ls(`pop${Mr.space[r][n].id}`,$(`
                      ${s}
                      `))}}))})),Object.keys(Mr.starDock).forEach((function(r){if("info"!==r&&(!Mr.starDock[r].hasOwnProperty("wiki")||Mr.starDock[r].wiki)&&(!Mr.starDock[r].hasOwnProperty("path")||Mr.starDock[r].path.includes(t))){let i=Mr.starDock[r].id.split("-"),s=$(`
                      `);e.append(s),Tn(s,Mr.starDock[r],`${z("space_gas_star_dock_title")}`,!0),Wn(s,"starDock",r),Yn(s,r,"starDock",!1,t),Ln("add",`space-${a}`,i[1],"function"==typeof Mr.starDock[r].title?Mr.starDock[r].title():Mr.starDock[r].title),ls(`pop${Mr.starDock[r].id}`,$(`
                      ${z("space_gas_star_dock_wiki")}
                      `))}}))}(r,a);break;case"interstellar":!function(e){Object.keys(Mr.interstellar).forEach((function(t){let a="string"==typeof Mr.interstellar[t].info.name?Mr.interstellar[t].info.name:Mr.interstellar[t].info.name(),r="string"==typeof Mr.interstellar[t].info.desc?Mr.interstellar[t].info.desc:Mr.interstellar[t].info.desc();Object.keys(Mr.interstellar[t]).forEach((function(i){if("info"!==i&&(!Mr.interstellar[t][i].hasOwnProperty("wiki")||Mr.interstellar[t][i].wiki)){let s=Mr.interstellar[t][i].id.split("-"),n=$(`
                      `);e.append(n),Tn(n,Mr.interstellar[t][i],`${a}`,!0),Wn(n,"interstellar",i),Yn(n,i,"interstellar",t),Ln("add","interstellar-structures",s[1],"function"==typeof Mr.interstellar[t][i].title?Mr.interstellar[t][i].title():Mr.interstellar[t][i].title),ls(`pop${Mr.interstellar[t][i].id}`,$(`
                      ${r}
                      `))}}))}))}(r);break;case"intergalactic":!function(e){Object.keys(Mr.galaxy).forEach((function(t){let a="string"==typeof Mr.galaxy[t].info.name?Mr.galaxy[t].info.name:Mr.galaxy[t].info.name(),r="string"==typeof Mr.galaxy[t].info.desc?Mr.galaxy[t].info.desc:Mr.galaxy[t].info.desc();Object.keys(Mr.galaxy[t]).forEach((function(i){if("info"!==i&&(!Mr.galaxy[t][i].hasOwnProperty("wiki")||Mr.galaxy[t][i].wiki)){let s=Mr.galaxy[t][i].id.split("-"),n=$(`
                      `);e.append(n),Tn(n,Mr.galaxy[t][i],`${a}`,!0),Wn(n,"intergalactic",i),Yn(n,i,"intergalactic",t),Ln("add","intergalactic-structures",s[1],"function"==typeof Mr.galaxy[t][i].title?Mr.galaxy[t][i].title():Mr.galaxy[t][i].title),ls(`pop${Mr.galaxy[t][i].id}`,$(`
                      ${r}
                      `))}}))}))}(r);break;case"hell":!function(e){Object.keys(Mr.portal).forEach((function(t){let a="string"==typeof Mr.portal[t].info.name?Mr.portal[t].info.name:Mr.portal[t].info.name(),r="string"==typeof Mr.portal[t].info.desc?Mr.portal[t].info.desc:Mr.portal[t].info.desc();Object.keys(Mr.portal[t]).forEach((function(i){if("info"!==i&&(!Mr.portal[t][i].hasOwnProperty("wiki")||Mr.portal[t][i].wiki)){let s=Mr.portal[t][i].id.split("-"),n=$(`
                      `);e.append(n),Tn(n,Mr.portal[t][i],`${a}`,!0),Wn(n,"hell",i),Yn(n,i,"hell",t),Ln("add","hell-structures",s[1],"function"==typeof Mr.portal[t][i].title?Mr.portal[t][i].title():Mr.portal[t][i].title),ls(`pop${Mr.portal[t][i].id}`,$(`
                      ${r}
                      `))}}))}))}(r);break;case"tauceti":!function(e){Object.keys(Mr.tauceti).forEach((function(t){let a="string"==typeof Mr.tauceti[t].info.name?Mr.tauceti[t].info.name:Mr.tauceti[t].info.name(),r="string"==typeof Mr.tauceti[t].info.desc?Mr.tauceti[t].info.desc:Mr.tauceti[t].info.desc();Object.keys(Mr.tauceti[t]).forEach((function(i){if("info"!==i&&(!Mr.tauceti[t][i].hasOwnProperty("wiki")||Mr.tauceti[t][i].wiki)){let s=Mr.tauceti[t][i].id.split("-"),n=$(`
                      `);e.append(n),Tn(n,Mr.tauceti[t][i],`${a}`,!0),Wn(n,"tauceti",i),Yn(n,i,"tauceti",t),Ln("add","tauceti-structures",s[1],"function"==typeof Mr.tauceti[t][i].title?Mr.tauceti[t][i].title():Mr.tauceti[t][i].title),ls(`pop${Mr.tauceti[t][i].id}`,$(`
                      ${r}
                      `))}}))}))}(r)}}const Vn={prehistoric:{},planetary:{slaughter:[z("wiki_structure_planetary_slaughter")]},space:{terraformer:[z("wiki_structure_space_terraformer")],terraform:[z("wiki_structure_space_terraformer")]},starDock:{geck:[z("wiki_structure_stardock_geck")]},interstellar:{},intergalactic:{},hell:{},tauceti:{}};function Wn(e,t,a){if(Vn[t].hasOwnProperty(a)){let r=$('
                      ');e.append(r);for(let e=0;e${Vn[t][a][e]}`)}}const Qn={include:{prehistoric:["membrane","organelles","nucleus","eukaryotic_cell","mitochondria"]},exclude:{planetary:["food","lumber","stone","chrysotile","slaughter","slave_market",""],space:["test_launch","moon_mission","terraform","red_mission","hell_mission","sun_mission","gas_mission","gas_moon_mission","belt_mission","dwarf_mission","titan_mission","enceladus_mission","triton_mission","kuiper_mission","eris_mission","crashed_ship","digsite"],starDock:["prep_ship","launch_ship"],interstellar:["alpha_mission","proxima_mission","nebula_mission","neutron_mission","blackhole_mission","jump_ship","wormhole_mission","sirius_mission","sirius_b","ascend"],intergalactic:["gateway_mission","gorddon_mission","alien2_mission","chthonian_mission"],hell:["pit_mission","assault_forge","ruins_mission","gate_mission","lake_mission","spire_mission","bribe_sphinx","spire_survey","spire"],tauceti:["home_mission","dismantle","excavate","alien_outpost","red_mission","matrix","roid_mission","alien_station_survey","contact","introduce","subjugate","gas_contest","gas_contest2","ignite_gas_giant","jeff","goe_facility"]},excludeCreep:{planetary:["horseshoe"],space:["horseshoe"],hell:["ancient_pillars","sphinx","waygate"],tauceti:["horseshoe"]},max:{prehistoric:{},planetary:{s_alter:1},space:{star_dock:1,terraformer:100,world_collider:1859,shipyard:1,mass_relay:100,fob:1,ai_core:100,jump_gate:100},starDock:{seeder:100},interstellar:{dyson:100,dyson_sphere:100,orichalcum_sphere:100,stellar_engine:100,stargate:200,space_elevator:100,gravity_dome:100,ascension_machine:100},intergalactic:{embassy:1,consulate:1},hell:{soul_forge:1,vault:2,ancient_pillars:Object.keys(Ki).length-1,west_tower:oa(),east_tower:oa(),bridge:10,sphinx:2,waygate:10},tauceti:{alien_outpost:1,jump_gate:100,ringworld:1e3,alien_station:100,matrioshka_brain:1e3,ignition_device:10}},count:{planetary:{horseshoe:t.race.shoecnt?t.race.shoecnt:0,assembly:t.resource[t.race.species]?t.resource[t.race.species].amount:0},space:{horseshoe:t.race.shoecnt?t.race.shoecnt:0,assembly:t.resource[t.race.species]?t.resource[t.race.species].amount:0},interstellar:{},intergalactic:{},hell:{ancient_pillars:Object.keys(t.pillars).length,sphinx:!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2,waygate:t.tech.waygate&&t.tech.waygate>=2?10:t.portal.waygate?t.portal.waygate.count:0},tauceti:{}},creepCalc:{planetary:{assembly:1e3},space:{assembly:1e3,swarm_satellite:200}}},Jn={mass_driver:{type:"field",min:0,import:()=>t.city.mass_driver?t.city.mass_driver.on:0}},Zn={fuelAdj:{inputs:["mass_driver"]}},Xn={terraformer:["truepath"]};function Yn(e,a,r,i,s){let n=!(!Qn.max[r]||!Qn.max[r][a])&&Qn.max[r][a],c={owned:0,costVis:!1,creepVis:!1,extra:{truepath:"truepath"===s}},o={},l=!1;switch(r){case"prehistoric":l=Mr.evolution[a],c.real_owned=t.evolution[a]?t.evolution[a].count:0;break;case"planetary":l=Mr.city[a],c.real_owned=t.city[a]?t.city[a].count:0;break;case"space":l=Mr.space[i][a],c.real_owned=t.space[a]?t.space[a].count:0;break;case"starDock":l=Mr.starDock[a],c.real_owned=t.starDock[a]?t.starDock[a].count:0;break;case"interstellar":l=Mr.interstellar[i][a],c.real_owned=t.interstellar[a]?t.interstellar[a].count:0;break;case"intergalactic":l=Mr.galaxy[i][a],c.real_owned=t.galaxy[a]?t.galaxy[a].count:0;break;case"hell":l=Mr.portal[i][a],c.real_owned=t.portal[a]?t.portal[a].count:0;break;case"tauceti":l=Mr.tauceti[i][a],c.real_owned=t.tauceti[a]?t.tauceti[a].count:0}Qn.count[r]&&Qn.count[r][a]&&(c.real_owned=Qn.count[r][a]);let _=function(){if(l.hasOwnProperty("effect")&&"string"!=typeof l.effect){let e=$(".effect",`#${a}`);Ss(e);let t=c.owned-c.real_owned;Xn[a]&&(t={count:t},Xn[a].forEach((function(e){"truepath"===e&&(t[e]="truepath"===s)}))),e.append(l.effect(t))}};_();let d=l.cost;d&&Object.keys(Ns(l)).forEach((function(e){o[e]={},"space"!==r||"Oil"!==e&&"Helium_3"!==e||Zn.fuelAdj.inputs.forEach((function(e){var t;t=e,c.extra[t]=Jn[t].import()}))}));let p=function(){let e=!1;if(d){let t=Ns(l,c.owned-c.real_owned,c.extra);Object.keys(o).forEach((function(a){if("Custom"===a)o[a].vis=!0;else{let e=t[a]?t[a](c.owned-c.real_owned,c.extra):0;o[a].vis=e>0,o[a].cost=x(e,1)}e=e||o[a].vis}))}c.costVis=e};p(),(Qn.include[r]&&Qn.include[r].includes(a)||Qn.exclude[r]&&!Qn.exclude[r].includes(a))&&(function(){let e=!1;if(d&&!n&&(!Qn.excludeCreep[r]||!Qn.excludeCreep[r].includes(a))&&"prehistoric"!==r){let t=Qn.creepCalc[r]&&Qn.creepCalc[r][a]?Qn.creepCalc[r][a]:100,i=t-1,s=Ns(l,t,c.extra),n=Ns(l,i,c.extra);Object.keys(o).forEach((function(a){s[a]&&(o[a].creep=+(s[a](t,c.extra)/n[a](i,c.extra)).toFixed(5),1===o[a].creep?o[a].creep=z("wiki_calc_none"):o[a].creep<1.005&&(o[a].creep=1.005),e=e||o[a].vis)}))}c.creepVis=e}(),e.append($(`\n
                      \n
                      \n
                      {{ | ownedLabel }} -+
                      \n
                      \n
                      \n \n
                      \n
                      \n `))),Cs({el:`#${a}`,data:{i:c,r:o},methods:{val(e){c[e]=Math.round(c[e]),c[e]&&c[e]<0?c[e]=0:n&&c[e]>n&&(c[e]=n),_(),p()},less(e){c[e]>0&&c[e]--},more(e){(!n||n&&c[e]=2,link:"wiki.html#discovery-tech-diplomacy"},{title:z("wiki_tech_special_trait",[z("trait_terrifying_name")]),color:!!t.race.terrifying,link:"wiki.html#traits-species-major_terrifying"}]}],socialist:[{category:"unique",subreqs:[{title:z("wiki_tech_special_tech",[z("tech_diplomacy")]),color:t.tech.trade&&t.tech.trade>=2,link:"wiki.html#discovery-tech-diplomacy"},{title:z("wiki_tech_special_trait",[z("trait_terrifying_name")]),color:!!t.race.terrifying,link:"wiki.html#traits-species-major_terrifying"}]}],federation:[{category:"unique",subreqs:[{title:z("wiki_tech_special_occupy"),color:ce(),link:"wiki.html#mechanics-gameplay-occupying"}]}],magocracy:[{category:"universe",subreqs:[{name:"magic"}]}],governor:[{category:"crispr",subreqs:[{name:"governance",tree:"governor",val:1}]},{category:"government",not:!0,subreqs:[{name:"anarchy"}]}],market:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],tax_rates:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],large_trades:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],corruption:[{category:"trait",not:!0,subreqs:[{name:"terrifying"},{name:"noble"}]}],massive_trades:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],trade:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],diplomacy:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],freight:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],wharf:[{category:"trait",not:!0,subreqs:[{name:"terrifying"},{name:"thalassophobia"}]}],reclaimer:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],iron_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],steel_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],titanium_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],alloy_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],mythril_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],adamantite_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],stone_axe:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],copper_axes:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],iron_saw:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],steel_saw:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],iron_axes:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],steel_axes:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],titanium_axes:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],chainsaws:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],copper_sledgehammer:[{category:"trait",not:!0,subreqs:[{name:"sappy"}]}],iron_sledgehammer:[{category:"trait",not:!0,subreqs:[{name:"sappy"}]}],steel_sledgehammer:[{category:"trait",not:!0,subreqs:[{name:"sappy"}]}],titanium_sledgehammer:[{category:"trait",not:!0,subreqs:[{name:"sappy"}]}],copper_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],iron_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],steel_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],titanium_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],adamantite_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],slave_pens:[{category:"trait",subreqs:[{name:"slaver"}]}],slave_market:[{category:"trait",subreqs:[{name:"slaver"}]}],ceremonial_dagger:[{category:"trait",subreqs:[{name:"cannibalize"}]}],last_rites:[{category:"trait",subreqs:[{name:"cannibalize"}]}],ancient_infusion:[{category:"trait",subreqs:[{name:"cannibalize"}]}],armor:[{category:"trait",not:!0,subreqs:[{name:"apex_predator"}]}],plate_armor:[{category:"trait",not:!0,subreqs:[{name:"apex_predator"}]}],kevlar:[{category:"trait",not:!0,subreqs:[{name:"apex_predator"}]}],nanoweave_vest:[{category:"trait",not:!0,subreqs:[{name:"apex_predator"}]}],mad:[{truepath:!0,category:"unique",subreqs:[{title:z("wiki_tech_special_unify"),color:!!t.tech.world_control,link:"wiki.html#globalized-tp_tech-unite"}]}],ancient_theology:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],study:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],encoding:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],deify:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],infusion:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],gps:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],genesis:[{category:"unique",subreqs:[{title:z("wiki_tech_special_genesis"),color:t.race.deterioration>=1}]}],veil:[{category:"universe",subreqs:[{name:"magic"}]}],mana_syphon:[{category:"universe",subreqs:[{name:"magic"}]}],mana:[{category:"universe",subreqs:[{name:"magic"}]}],ley_lines:[{category:"universe",subreqs:[{name:"magic"}]}],rituals:[{category:"universe",subreqs:[{name:"magic"}]}],crafting_ritual:[{category:"universe",subreqs:[{name:"magic"}]}],mana_nexus:[{category:"universe",subreqs:[{name:"magic"}]}],clerics:[{category:"universe",subreqs:[{name:"magic"}]},{category:"crispr",subreqs:[{name:"faith",tree:"ancients",val:2}]}],conjuring:[{category:"universe",subreqs:[{name:"magic"}]},{category:"scenario",not:!0,subreqs:[{name:"cataclysm"}]}],res_conjuring:[{category:"universe",subreqs:[{name:"magic"}]},{category:"scenario",not:!0,subreqs:[{name:"cataclysm"}]}],alchemy:[{category:"universe",subreqs:[{name:"magic"}]}],transmutation:[{category:"universe",subreqs:[{name:"magic"}]}],dark_bomb:[{category:"unique",subreqs:[{title:z("wiki_tech_special_demon_lord"),color:t.stats.hasOwnProperty("spire")&&t.stats.spire.hasOwnProperty(xn())&&t.stats.spire[xn()].hasOwnProperty("dlstr")&&t.stats.spire[xn()].dlstr>0,link:"wiki.html#mechanics-gameplay-dlord"}]}],terraforming:[{category:"challenge",subreqs:[{name:"orbitdecay"}]}],geck:[{category:"achieve",subreqs:[{name:"lamentis",val:5}]}],womling_fun:[{category:"unique",subreqs:[{title:z("tau_red_contact"),color:!!t.race.womling_friend,link:"wiki.html#tauceti-structures-contact"},{title:z("tau_red_introduce"),color:!!t.race.womling_god,link:"wiki.html#tauceti-structures-introduce"},{title:z("tau_red_subjugate"),color:!!t.race.womling_lord,link:"wiki.html#tauceti-structures-subjugate"}]}],isolation_protocol:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],focus_cure:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],decode_virus:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vaccine_campaign:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vax_strat1:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vax_strat2:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vax_strat3:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vax_strat4:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],cloning:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],clone_degredation:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],digital_paradise:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],ringworld:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],matrioshka_brain:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],ignition_device:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],replicator:[{category:"scenario",subreqs:[{name:"lone_survivor"}]}],womling_unlock:[{category:"scenario",subreqs:[{name:"lone_survivor"}]}],garden_of_eden:[{category:"scenario",subreqs:[{name:"lone_survivor"}]}]},cc={unification2:"unification",conjuring:"ley_lines",res_conjuring:"conjuring",bribe_sphinx:"miasma"};const oc={solar:"interstellar"},lc={interstellar:"solar"};function _c(e,a){let r=Ln("create"),i=[],s=[],n="truepath"===a?ac:tc,c="truepath"===a?"tp_tech":"tech";if(Object.keys(n).forEach((function(r){let c=n[r];if(c.hasOwnProperty("era")&&(c.era===e||c.era===oc[e])&&(!c.hasOwnProperty("wiki")||c.wiki)){let e=n[r].id.split("-"),o=$(`
                      `);if(Tn(o,c),function(e,t,a){let r=$('
                      ');if(e.append(r),ic.hasOwnProperty(t)&&"truepath"===a)for(let e=0;e${ic[t][e]}`);else if(rc.hasOwnProperty(t))for(let e=0;e${rc[t][e]}`);else r.append(`
                      ${z("wiki_tech_empty")}
                      `)}(o,r,a),function(e,a,r,i){let s=function(e){let t={},a="truepath"===e?ac:tc;return Object.keys(a).forEach((function(e){let a=Mr.tech[e];t[a.grant[0]]||(t[a.grant[0]]={});let r="string"==typeof Mr.tech[e].title?Mr.tech[e].title:Mr.tech[e].title();t[a.grant[0]][a.grant[1]]=[{name:e,title:r,era:Mr.tech[e].era}]})),t.primitive[2]=[{name:"bone_tools",title:z("tech_bone_tools"),era:"primitive"},{name:"wooden_tools",title:z("tech_wooden_tools"),era:"primitive"}],t.theology[3]=[{name:Mr.tech.fanaticism.wiki?"fanaticism":"alt_fanaticism",title:z("tech_fanaticism"),era:"civilized"},{name:Mr.tech.anthropology.wiki?"anthropology":"alt_anthropology",title:z("tech_anthropology"),era:"civilized"}],t.theology[5]=[{name:"deify",title:z("tech_deify"),era:"early_space"},{name:"study",title:z("tech_study"),era:"early_space"}],t.ancient_study[1]=[{name:"study",title:z("tech_study"),era:"early_space"}],t.ancient_deify[1]=[{name:"deify",title:z("tech_deify"),era:"early_space"}],"truepath"===e&&(t.unify[1]=[{name:"arpa",title:z("tech_arpa"),era:"globalized"}],t.isolation={},t.isolation[1]=[{name:"isolation_protocol",title:z("tech_isolation_protocol"),era:"tauceti"}],t.focus_cure={},t.focus_cure[1]=[{name:"focus_cure",title:z("tech_focus_cure"),era:"tauceti"}]),t}(i);if(Object.keys(a.reqs).length>0){let r={},n={};if(Object.keys(a.reqs).forEach((function(e){let i=t.tech[e]&&t.tech[e]>=a.reqs[e]?"success":"danger",c=e+a.reqs[e];s[e]&&s[e][a.reqs[e]]?(r[c]=[],s[e][a.reqs[e]].forEach((function(e){r[c].push({name:e.name,title:e.title,era:e.era,color:i})}))):sc[c]&&(n[c]={title:sc[c].title,link:sc[c].link,color:i})})),Object.keys(r).length>0){let t=!1,a=$(`
                      ${z("wiki_tech_req_tech")}
                      `);e.append(a),Object.keys(r).forEach((function(e){let s="",n=!1,c=!1;r[e].forEach((function(e){let t=`${e.title}`;c=e.color,n?s=z("wiki_tech_req_or",[s,t]):(n=!0,s=t)})),a.append(`${t?", ":""}${s}`),t=!0}))}if(Object.keys(n).length>0){let t=!1,a=$(`
                      ${z("wiki_tech_req_other")}
                      `);e.append(a),Object.keys(n).forEach((function(e){let r=n[e].link;r&&"truepath"===i&&(r=r.replace("-structures-","-tp_structures-"));let s=r?`${n[e].title}`:n[e].title;a.append(`${t?", ":""}${s}`),t=!0}))}}if(nc.hasOwnProperty(r)){let a=!1,s=$(`
                      ${z("wiki_tech_req_special")}
                      `),n=!1;nc[r].forEach((function(e){if(e.truepath&&"truepath"!==i)return;n=!0;let r=!1,c=!1,o="";e.subreqs.forEach((function(a){let s="",n=!1,l=!1;switch(e.category){case"species":s=z(`race_${a.name}`),n=`wiki.html#races-species-${a.name}`,l=t.race.species===a.name;break;case"genus":s=z(`genelab_genus_${a.name}`),l=Ki[t.race.species].type===a.name;break;case"trait":s=z(`trait_${a.name}_name`),n=`wiki.html#traits-species-${Ei[a.name].type}_${a.name}`,l=t.race[a.name];break;case"tech":s="string"==typeof Mr.tech[a.name].title?Mr.tech[a.name].title:Mr.tech[a.name].title(),n=`wiki.html#${Mr.tech[a.name].era}-tech-${a.name}`,l=t.tech[a.tree]&&t.genes[a.tree]>=a.val;break;case"universe":s=z(`universe_${a.name}`),n=`wiki.html#universes-gameplay-${a.name}`,l=t.race.universe===a.name;break;case"crispr":s=z(`arpa_genepool_${a.name}_title`),n=`wiki.html#crispr-prestige-${a.name}`,l=t.genes[a.tree]&&t.genes[a.tree]>=a.val;break;case"achieve":s=a.val+` ${Hs("star")} `+z(`achieve_${a.name}_name`),n=`wiki.html#perks-prestige-${a.name}`,l=t.stats.achieve[a.name]&&t.stats.achieve[a.name].l>=a.val;break;case"government":s=z(`govern_${a.name}`),n=`wiki.html#government-gameplay-${a.name}`,l=t.civic.govern&&t.civic.govern.type&&t.civic.govern.type===a.name;break;case"scenario":s=z(`wiki_challenges_scenarios_${a.name}`),n=`wiki.html#challenges-gameplay-scenarios_${a.name}`,l=t.race[a.name];break;case"challenge":s=z(`wiki_challenges_modes_${a.name}`),n=`wiki.html#challenges-gameplay-modes_${a.name}`,l=t.race[a.name];break;case"unique":s=a.title,n=a.link,l=a.color}n&&"truepath"===i&&(n=n.replace("-tech-","-tp_tech-")),c=c||l,e.not&&(l=!l),l=l?"success":"danger",s=n?`${s}`:`${s}`,r?o=z("wiki_tech_req_or",[o,s]):(r=!0,o=s)})),e.not&&(c=!c),c=c?"success":"danger","unique"!==e.category&&(o=z(`wiki_tech_special_${e.category}${e.not?"_not":""}`,[o])),s.append(`${a?", ":""}${o}`),a=!0})),n&&e.append(s)}}(o,c,r,a),c.cost.Knowledge)if(0===i.length)i[0]=[c,o];else{let e=c.cost.Knowledge(),t=i.length-1;for(;t>=0&&i[t][0].cost.Knowledge()>e;)i[t+1]=i[t],t--;i[t+1]=[c,o]}else s.push([c,o])}})),s.length>0)for(let e=0;e');e.append(a),Object.keys(kn).forEach((function(e){let r=$('
                      ');a.append(r);let i=t.stats.feat[e]&&t.stats.feat[e]>0?"warning":"fade",s=Vs(e,"feat"),n=t.stats.feat[e]>1?`

                      ${Hs(s)}

                      `:"";r.append(`${kn[e].name}${n}`),function(e,a){let r=a?`
                      ${kn[e].flair}
                      `:"";if("egghunt"===e){let a=(new Date).getFullYear(),i=`
                      ${z("wiki_feat_egghunt_found")}
                      `;for(let e=1;e<=18;e++)i+=`${z("wiki_feat_egghunt_num",[e])}`;i+="
                      ",ls(`f-${e}`,$(`
                      ${kn[e].desc}
                      ${z(`wiki_feat_${e}`)}
                      ${i}${r}`))}else if("trickortreat"===e){let a=(new Date).getFullYear(),i=`
                      ${z("wiki_feat_trickortreat_found")}
                      `;for(let e=1;e<=7;e++)i+=`${z("wiki_feat_treat_num",[e])}`;for(let e=1;e<=7;e++)i+=`${z("wiki_feat_trick_num",[e])}`;i+="
                      ",ls(`f-${e}`,$(`
                      ${kn[e].desc}
                      ${z(`wiki_feat_${e}`)}
                      ${i}${r}`))}else if("equilibrium"===e){let a={};t.pillars&&Object.keys(t.pillars).forEach((function(e){Ki[e]&&(a[e]=t.pillars[e])}));let i='
                      ';Object.keys(Ki).sort(((e,t)=>Ki[e].name.localeCompare(Ki[t].name))).forEach((function(e){"protoplasm"!==e&&("custom"!==e||"custom"===e&&t.stats.achieve.ascended)&&(a[e]&&a[e]>=1?i+=`${Ki[e].name}`:i+=`${Ki[e].name}`)})),i+="
                      ",ls(`f-${e}`,$(`
                      ${kn[e].desc}
                      ${z(`wiki_feat_${e}`)}
                      ${i}${r}`),{wide:!0})}else ls(`f-${e}`,$(`
                      ${kn[e].desc}
                      ${z(`wiki_feat_${e}`)}
                      ${r}`))}(e,"warning"===i)}))}()}}const pc={cross:["antimatter"],vigilante:["evil"],squished:["micro"],macro:["micro"],marble:["micro"],double_density:["heavy"],heavyweight:["heavy"],whitehole:["standard"],heavy:["heavy"],canceled:["antimatter"],eviltwin:["evil"],microbang:["micro"],pw_apocalypse:["magic"],pass:["magic"],fullmetal:["magic"],soul_sponge:["magic"],nightmare:["magic"]},uc={trade:[750,50]};function hc(e,a){let r=$("#content");Ss(r);let i=`\n \n `;r.append(i),Cs({el:"#filtering",methods:{universeSwap(e){hc(e,a)},filterSwap(t){hc(e,t)}}});let s=xn(e||"standard"),n={};Object.keys(wn).forEach((function(r){if(!e||!pc[r]||pc[r].indexOf(e)>-1){if("missing"===a&&t.stats.achieve[r]&&t.stats.achieve[r][s]&&t.stats.achieve[r][s]>0)return;if("obtained"===a&&!(t.stats.achieve[r]&&t.stats.achieve[r][s]&&t.stats.achieve[r][s]>0))return;if("incomplete"===a&&e&&t.stats.achieve[r]&&t.stats.achieve[r][s]&&t.stats.achieve[r][s]>4)return;if("completed"===a&&e&&!(t.stats.achieve[r]&&t.stats.achieve[r][s]&&t.stats.achieve[r][s]>4))return;if(("incomplete"===a||"completed"===a)&&!e){let e="universe"===wn[r].type?10:30;if("whitehole"===r&&(e=5),t.stats.achieve[r]&&Object.keys(t.stats.achieve[r]).forEach((a=>e-=t.stats.achieve[r][a])),"incomplete"===a&&e<=0)return;if("completed"===a&&e>0)return}n.hasOwnProperty(wn[r].type)?n[wn[r].type].push(r):n[wn[r].type]=[r]}})),Object.keys(n).forEach((function(a){r.append($(`

                      ${z(`wiki_achieve_${a}`)}

                      `));let i=$('
                      ');r.append(i),n[a].forEach((function(a){let r=$('
                      ');i.append(r);let n=t.stats.achieve[a]&&t.stats.achieve[a][s]&&t.stats.achieve[a][s]>0?"warning":"fade";r.append(`${wn[a].name}`);let c=Xs(a,16,!1,!1,e);r.append(`${c}`),function(e,a,r){let i=xn(r||"standard"),s=a?`
                      ${wn[e].flair}
                      `:"";if("mass_extinction"===e||"vigilante"===e){let a='
                      ';Object.keys(Ki).sort((function(e,t){return Ki[e].hasOwnProperty("name")&&Ki[t].hasOwnProperty("name")?Ki[e].name.localeCompare(Ki[t].name):0})).forEach((function(r){"protoplasm"!==r&&("custom"!==r||"custom"===r&&t.stats.achieve.ascended)&&(t.stats.achieve[`extinct_${r}`]&&("mass_extinction"===e?t.stats.achieve[`extinct_${r}`][i]>=0:t.stats.achieve[`extinct_${r}`].hasOwnProperty("e")&&t.stats.achieve[`extinct_${r}`].e>=0)?a+=`${Ki[r].name}`:a+=`${Ki[r].name}`)})),a+="
                      ",ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z(`wiki_achieve_${e}`)}
                      ${a}${s}`),{wide:!0})}else if("explorer"===e){let a='
                      ';Object.keys(is).sort(((e,t)=>is[e].label.localeCompare(is[t].label))).forEach((function(e){(!r||"hellscape"!==e&&"eden"!==e||"hellscape"===e&&"evil"!==r||"eden"===e&&"evil"===r)&&(t.stats.achieve[`biome_${e}`]&&t.stats.achieve[`biome_${e}`][i]>=0?a+=`${is[e].label}`:a+=`${is[e].label}`)})),a+="
                      ",ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z(`wiki_achieve_${e}`)}
                      ${a}${s}`))}else if("creator"===e||"heavyweight"===e){let a='
                      ';Object.keys(Li).sort().forEach((function(r){let s=["carnivore","herbivore","omnivore"].includes(r)?z(`evo_${r}_title`):z(`genelab_genus_${r}`);("creator"===e?t.stats.achieve[`genus_${r}`]&&t.stats.achieve[`genus_${r}`][i]>=0:t.stats.achieve[`genus_${r}`]&&t.stats.achieve[`genus_${r}`].h>=0)?a+=`${s}`:a+=`${s}`})),a+="
                      ",ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z(`wiki_achieve_${e}`)}
                      ${a}${s}`))}else if("enlightenment"===e){let a={};t.pillars&&Object.keys(t.pillars).forEach((function(e){Ki[e]&&(!a[Ki[e].type]||t.pillars[e]>a[Ki[e].type])&&(a[Ki[e].type]=t.pillars[e])}));let r='
                      ';Object.keys(Li).sort().forEach((function(e){let t=["carnivore","herbivore","omnivore"].includes(e)?z(`evo_${e}_title`):z(`genelab_genus_${e}`);a[e]&&a[e]>=1?r+=`${t}`:r+=`${t}`})),r+="
                      ",ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z(`wiki_achieve_${e}`)}
                      ${r}${s}`))}else if("gladiator"===e){let a='
                      ',n={};t.stats.spire&&Object.keys(t.stats.spire).forEach((function(e){r&&i!==e||Object.keys(t.stats.spire[e]).forEach((function(a){va[a]&&(!n.hasOwnProperty(a)||n[a]0?a+=`${z(`portal_mech_boss_${e}`)}`:a+=`${z(`portal_mech_boss_${e}`)}`})),a+="
                      ",ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z(`wiki_achieve_${e}`)}
                      ${a}${s}`),{wide:!0})}else if("banana"===e){let a='
                      ';a+=`
                      ${z("wiki_achieve_banana1")}
                      `,a+=`
                      ${z("wiki_achieve_banana2")}
                      `,a+=`
                      ${z("wiki_achieve_banana3")}
                      `,a+=`
                      ${z("wiki_achieve_banana4",[500])}
                      `,a+=`
                      ${z("wiki_achieve_banana5",[50])}
                      `,a+="
                      ",ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z(`wiki_achieve_${e}`)}
                      ${a}${s}`))}else if("pathfinder"===e){let a='
                      ';["ashanddust","exodus","obsolete","bluepill","retired"].forEach((function(e){let r=z(`achieve_${e}_name`);t.stats.achieve[e]&&t.stats.achieve[e][i]>=5?a+=`${r}`:a+=`${r}`})),a+="
                      ",ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z(`wiki_achieve_${e}`)}
                      ${a}${s}`))}else if("overlord"===e){let a='
                      ',i={subjugate:"lord",contact:"friend",introduced:"god"},n=xn(r||"standard");Object.keys(i).forEach((function(e){t.stats.womling[i[e]]&&t.stats.womling[i[e]][n]>0?a+=`${z(`wiki_achieve_overlord_${e}`)}`:a+=`${z(`wiki_achieve_overlord_${e}`)}`})),a+="
                      ",ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z(`wiki_achieve_${e}`)}
                      ${a}${s}`))}else if(e.includes("extinct_")&&"custom"!==e.substring(8)){let t=e.substring(8);ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z("wiki_achieve_extinct_race",[z(`race_${t}`)])}
                      ${s}`))}else if(e.includes("genus_")){let t=e.substring(6);ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z("wiki_achieve_genus_type",[z(`genelab_genus_${t}`)])}
                      ${s}`))}else if(e.includes("biome_")||e.includes("atmo_")){let t=e.substring(e.indexOf("_")+1);ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${z("wiki_achieve_planet_type",["b"===e.substring(0,1)?z(`biome_${t}_name`):z(`planet_${t}`)])}
                      ${s}`))}else{let t=uc[e]?z(`wiki_achieve_${e}`,uc[e]):z(`wiki_achieve_${e}`);ls(`a-${e}`,$(`
                      ${wn[e].desc}
                      ${t}
                      ${s}`))}}(a,"warning"===n,e)}))}))}function mc(e,t,a,r){r=r||{};let i=$(`\n
                      \n ${z("wiki_challenges_"+(t?"feats":"achievements"))}\n
                      \n `);e.append(i);let s=!1;a.forEach((function(e){let a=t?z(`feat_${e}_name`):r[e]?z(`achieve_${e}_name`):`${z(`achieve_${e}_name`)}`;i.append(`${s?", ":""}${a}`),s=!0}))}function gc(e,t){let a=$(`\n
                      \n ${z("wiki_challenges_requirements")}\n
                      \n `);e.append(a);let r=!1;t.forEach((function(e){let t=!1,i=!1,s="";e.subreqs.forEach((function(e){let a=e.text,r=e.link||!1,n=e.color;i=i||n,n=n?"success":"danger",a=r?`${a}`:`${a}`,t?s=z("wiki_tech_req_or",[s,a]):(t=!0,s=a)})),i=i?"success":"danger",s=z(e.text,[s]),a.append(`${r?", ":""}${s}`),r=!0}))}const vc={plasmid:["cit","sol","know","genes","reset","uni","high_pop","synth","tp"],anti:["cit","sol","know","genes","reset","high_pop","synth","tp"],phage:["plas","genes","reset","uni","tp"],dark:["mass","exotic","genes","uni"],vacuum:["mana","genes"],harmony:["genes","uni"],artifact:["genes","floor","micro"],cores:["micro"]};function fc(e,a,r,i){let s=r||a,n=a+(i||"")+(r||""),c=$(`
                      `);e.append(c);let o="";switch(i){case"mad":o+=z("wiki_calc_mad")+" ";break;case"bioseed":case"cataclysm":case"vacuum":case"terraform":o+=z("wiki_resets_"+i)+" ";break;case"bigbang":o+=z("wiki_resets_blackhole")+" ";break;case"ascend":o+=z("wiki_resets_ascension")+" ";break;case"descend":o+=z("wiki_resets_infusion")+" ";break;case"ai":o+=z("wiki_resets_ai")+" "}switch(s){case"plasmid":o+=z("resource_Plasmid_name");break;case"anti":o+=z("resource_AntiPlasmid_name");break;case"phage":o+=z("resource_Phage_name");break;case"dark":case"vacuum":o+=z("resource_Dark_name");break;case"harmony":o+=z("resource_Harmony_name");break;case"artifact":o+=z("resource_Artifact_name");break;case"cores":o+=z("resource_AICore_name")}c.append(`

                      ${z("wiki_calc_gains",[o])}

                      `);let l=$("
                      "),_=$("
                      ");c.append(l),c.append(_);let d={cit:0,sol:0,know:0,plas:0,mass:0,exotic:0,mana:0,floor:0,genes:0,uni:"standard"},p={cit:{val:void 0,use:!1},sol:{val:void 0,use:!1},know:{val:void 0,use:!1},plas:{val:void 0,use:!1},mass:{val:void 0,use:!1},exotic:{val:void 0,use:!1},mana:{val:void 0,use:!1},floor:{val:void 0,use:!1},genes:{val:void 0,use:!1},reset:{val:void 0,use:!1},uni:{val:void 0,use:!1},micro:{val:!1,use:!1},high_pop:{val:void 0,use:!1},synth:{val:!1,use:!1},tp:{val:!1,use:!1,enabled:!0}},u={standard:{use:!0},evil:{use:!0},antimatter:{use:!0},micro:{use:!0},heavy:{use:!0},magic:{use:!0}},h={mad:{use:!0},bioseed:{use:!0},cataclysm:{use:!0},bigbang:{use:!0},vacuum:{use:!0},terraform:{use:!0},ascend:{use:!0},descend:{use:!1},ai:{use:!0}},m={vis:!1},g={capVis:!1,overflowVis:!1,totalVis:!1,capVal:void 0,overflow:void 0,rawGains:void 0};vc[s].forEach((function(e){p[e].use=!0})),i&&(p.reset.val=i,p.reset.use=!1,"mad"!==i&&(p.synth.use=!1,p.synth.val=!1),"vacuum"===i&&(p.uni.use=!1,p.uni.val="magic"),"ai"===i?(p.tp.use=!1,p.tp.val=!0):["mad","bioseed","terraform"].includes(i)||(p.tp.use=!1,p.tp.val=!1));let v="";switch(s){case"plasmid":i||(u.antimatter.use=!1);break;case"anti":h.vacuum.use=!1;break;case"phage":h.mad.use=!1,h.descend.use=!1,v+="log2({{ i.plas.val, 'plasmids' | generic }}) * {{ i.reset.val | phageMulti }} * e * {{ i.genes.val | challenge}} * {{ i.uni.val | universe }} * 1.1";break;case"dark":p.reset.val="bigbang",u.magic.use=!1,v+="(ln(1 + ({{ i.exotic.val, 'exotic' | generic }} * 40)) + (log2({{ i.mass.val, 'mass' | generic }} - 7) / 2.5)) * {{ i.genes.val | challenge }} * {{ i.uni.val | universe }}";break;case"vacuum":p.reset.val="vacuum",p.uni.val="magic",v+="(log2({{ i.mana.val, 'mana' | generic }}) / 5) * {{ i.genes.val | challenge }}";break;case"harmony":p.reset.val="ascend",v+="(1 + {{ i.genes.val, 'genes' | generic }}) * {{ i.uni.val | universe }}";break;case"artifact":p.reset.val="descend",v+="1 + {{ i.genes.val, 'genes' | generic }} + {{ i.floor.val | floor }}";break;case"cores":p.reset.val="ai",v+='52'}"plasmid"===a?(v+=`\n
                      \n

                      ${z("wiki_calc_plasmid_cap_total",[z("anti"===s?"resource_AntiPlasmid_name":"resource_Plasmid_name")])}

                      \n
                      \n
                      \n {{ i.reset.val, i.synth.val | plasmidCap }} * (1 + (({{ i.genes.val, 'genes' | generic }} + 1) / 8)) = {{ | plasmidCapCalc }} = {{ pe.capVal }}\n
                      \n
                      \n

                      ${z("wiki_calc_plasmid_gains_raw",[z("anti"===s?"resource_AntiPlasmid_name":"resource_Plasmid_name")])}

                      \n
                      \n
                      \n `,v+="plasmid"===s?"\n ((({{ i.cit.val, 'citizens' | generic }} + {{ i.sol.val, 'soldiers' | generic }}) / {{ i.high_pop.val | highPopDivisor }} / {{ i.reset.val, i.synth.val | popDivisor }}) + (ln(1 + (({{ i.reset.val | knowMulti }} - 1) * {{ i.know.val, 'knowledge' | generic }} / {{ i.reset.val, i.synth.val | knowInc }})) / ln({{ i.reset.val | knowMulti }}))) * {{ i.genes.val | challenge }} * {{ i.uni.val | universe }} * 1.1\n ":"\n ((({{ i.cit.val, 'citizens' | generic }} + {{ i.sol.val, 'soldiers' | generic }}) / {{ i.high_pop.val | highPopDivisor }} / {{ i.reset.val, i.synth.val | popDivisor }}) + (ln(1 + (({{ i.reset.val | knowMulti }} - 1) * {{ i.know.val, 'knowledge' | generic }} / {{ i.reset.val, i.synth.val | knowInc }})) / ln({{ i.reset.val | knowMulti }}))) * {{ i.genes.val | challenge }} * 1.1 * 1.1\n ",v+=`\n = {{ | calc }}\n
                      \n
                      \n

                      ${z("wiki_calc_overflow")}

                      \n
                      \n
                      \n {{ pe.rawGains, 'plasmid_gains_raw' | generic }} - {{ pe.capVal, 'plasmid_cap_total' | generic }} = {{ pe.overflow, 'no_overflow' | generic }}\n
                      \n
                      \n

                      ${z("wiki_calc_plasmid_gains_total",[z("anti"===s?"resource_AntiPlasmid_name":"resource_Plasmid_name")])}

                      \n
                      \n
                      \n {{ pe.capVal, 'plasmid_cap_total' | generic }} + ({{ pe.overflow, 'overflow' | generic }} / ({{ pe.overflow, 'overflow' | generic }} + {{ pe.capVal, 'plasmid_cap_total' | generic }}) * {{ pe.capVal, 'plasmid_cap_total' | generic }}) = {{ | plasmidTotalCalc }}\n
                      \n `):v+=' = {{ | calc }}',l.append(v),_.append(`\n
                      \n
                      ${z("wiki_calc_citizens")}
                      \n
                      ${z("wiki_calc_soldiers")}
                      \n
                      ${z("wiki_calc_knowledge")}
                      \n
                      ${z("resource_Plasmid_plural_name")}
                      \n
                      ${z("wiki_calc_mass")}
                      \n
                      ${z("wiki_calc_exotic")}
                      \n
                      ${z("wiki_calc_mana")}
                      \n
                      ${z("wiki_calc_floor")}
                      \n
                      ${z("wiki_calc_genes")}
                      \n
                      ${z("wiki_calc_prestige")} \n \n {{ 'mad' | resetLabel }}\n {{ 'bioseed' | resetLabel }}\n {{ 'cataclysm' | resetLabel }}\n {{ 'bigbang' | resetLabel }}\n {{ 'vacuum' | resetLabel }}\n {{ 'terraform' | resetLabel }}\n {{ 'ascend' | resetLabel }}\n {{ 'descend' | resetLabel }}\n {{ 'ai' | resetLabel }}\n
                      \n
                      ${z("wiki_calc_universe")} \n \n {{ 'standard' | uniLabel }}\n {{ 'evil' | uniLabel }}\n {{ 'antimatter' | uniLabel }}\n {{ 'micro' | uniLabel }}\n {{ 'heavy' | uniLabel }}\n {{ 'magic' | uniLabel }}\n
                      \n
                      ${z("trait_high_pop_name")} \n \n {{ 0 | highPopLabel }}\n {{ 0.25 | highPopLabel }}\n {{ 0.5 | highPopLabel }}\n {{ 1 | highPopLabel }}\n {{ 2 | highPopLabel }}\n {{ 3 | highPopLabel }}\n
                      \n
                      ${z("universe_micro")}
                      \n
                      ${z("wiki_calc_synth")}
                      \n
                      ${z("wiki_calc_tp")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:"#"+n+"Calc",data:{i:p,u,r:h,s:m,pe:g},methods:{val(e){switch(e){case"cit":case"sol":case"know":case"plas":case"mass":case"exotic":case"mana":case"floor":p[e].val&&p[e].val<0&&(p[e].val=0);break;case"genes":p[e].val&&(p[e].val<0?p[e].val=0:p[e].val>4&&(p[e].val=4))}},pickReset(e){p.reset.val=e,Object.keys(u).forEach((function(e){u[e].use=!0})),"vacuum"===e?Object.keys(u).forEach((function(e){"magic"!==e&&(u[e].use=!1)})):"bigbang"===e&&(u.magic.use=!1),"plasmid"===a&&(u.antimatter.use=!1),p.synth.use="mad"===e,["mad","bioseed","terraform"].includes(e)?p.tp.enabled=!0:(p.tp.enabled=!1,p.tp.val="ai"===e)},pickUniverse(e){p.uni.val=e,"magic"===e?(h.bigbang.use=!1,h.vacuum.use=!0):(h.bigbang.use=!0,h.vacuum.use=!1),p.micro.val="micro"===e},pickHighPop(e){p.high_pop.val=e},resetInputs(){Object.keys(p).forEach((function(e){p[e].use&&(p[e].val=void 0)})),p.synth.use="plasmid"===a,["micro","synth","tp"].forEach((function(e){p[e].use&&(p[e].val=!1)})),p.tp.enabled=!0},importInputs(){p.cit.val=t.resource[t.race.species].amount,p.sol.val=t.civic.garrison?t.civic.garrison.workers:0;for(let e=0;e<3;e++)t.civic.foreign[`gov${e}`].occ&&(p.sol.val+=ta("federation"===t.civic.govern.type?15:20));p.know.val=t.stats.know,p.mass.val=t.interstellar.stellar_engine?t.interstellar.stellar_engine.mass:8,p.exotic.val=t.interstellar.stellar_engine?t.interstellar.stellar_engine.exotic:0,p.mana.val=t.resource.Mana.gen,p.floor.val=t.portal.spire?t.portal.spire.count-1:0,p.genes.val=Mn()-1;let e=t.race.universe;"dark"===s&&"magic"===e||"vacuum"===i||"bigbang"===e||(p.uni.val=e,"magic"===e?("bigbang"===p.reset.val&&(p.reset.val=void 0),h.bigbang.use=!1,h.vacuum.use=!0):("vacuum"===p.reset.val&&(p.reset.val=void 0),h.bigbang.use=!0,h.vacuum.use=!1),p.micro.val="micro"===e),p.high_pop.val=t.race.high_pop?t.race.high_pop:0,p.synth.val="synthetic"===Ki[t.race.species].type,p.tp.use&&p.reset.val&&["mad","bioseed","terraform"].includes(p.reset.val)&&(p.tp.val=!!t.race.truepath),p.reset.val&&"mad"!==p.reset.val&&"descend"!==p.reset.val&&(p.plas.val=Gs(p.reset.val,{cit:p.cit.val,sol:p.sol.val,know:p.know.val,uni:p.uni.val,genes:p.genes.val,high_pop:p.high_pop.val,tp:p.tp.val}).plasmid)}},filters:{generic:(e,t)=>void 0!==e?e:"plasmid_gains_raw"===t||"plasmid_cap_total"===t?z("wiki_calc_"+t,[z("anti"===s?"resource_AntiPlasmid_name":"resource_Plasmid_name")]):z("wiki_calc_"+t),floor(e){if(void 0===e)return z("wiki_calc_floor_bonus");let t=0;return[50,100].forEach((function(a){e>=a&&t++})),t},highPopDivisor:e=>e?Ei.high_pop.vars(e)[0]:1,popDivisor(e,t){switch(e){case"mad":if(t)return 5;case"cataclysm":case"bioseed":return 3;case"ai":return 2.5;case"vacuum":case"bigbang":return 2.2;case"ascend":case"terraform":return 1.15;default:return z("wiki_calc_pop_divisor")}},knowMulti(e){switch(e){case"mad":return 1.1;case"cataclysm":case"bioseed":return 1.015;case"ai":return 1.014;case"vacuum":case"bigbang":return 1.012;case"ascend":case"terraform":return 1.008;default:return z("wiki_calc_know_multi")}},knowInc(e,t){switch(e){case"mad":return t?125e3:1e5;case"cataclysm":case"bioseed":return 5e4;case"ai":return 45e3;case"vacuum":case"bigbang":return 4e4;case"ascend":case"terraform":return 3e4;default:return z("wiki_calc_know_inc")}},phageMulti(e){switch(e){case"cataclysm":case"bioseed":return 1;case"ai":return 2;case"vacuum":case"bigbang":return 2.5;case"ascend":case"terraform":return 4;default:return z("wiki_calc_phage_multi")}},plasmidCap(e,t){switch(e){case"mad":return t?100:150;case"cataclysm":case"bioseed":return 400;case"ai":return 600;case"vacuum":case"bigbang":return 800;case"ascend":case"terraform":return 2e3;default:return z("wiki_calc_plasmid_cap")}},plasmidCapCalc(){if(g.capVis=p.reset.val&&void 0!==p.genes.val,g.capVis){let e=0;switch(p.reset.val){case"mad":e=150,p.synth.val&&(e=100);break;case"cataclysm":case"bioseed":e=400;break;case"ai":e=600;break;case"vacuum":case"bigbang":e=800;break;case"ascend":case"terraform":e=2e3}return e*=1+(p.genes.val+1-(p.tp.val?0:1))/8,g.capVal=Math.floor(e),e}g.capVal=void 0},plasmidTotalCalc(){if(g.totalVis=g.overflow&&g.capVal,g.totalVis)return g.capVal+Math.floor(g.overflow/(g.overflow+g.capVal)*g.capVal)},challenge:e=>void 0!==e?Bs(1,"mad",2,{genes:e,uni:"standard",tp:!1}):z("wiki_calc_challenge_multi"),universe(e){if(!e)return z("wiki_calc_universe_multi");let t=p.genes.val||0;return"harmony"===s||"artifact"===s?(d.uni=p.uni.val,Gs(p.reset.val,d)[a]):+(Bs(1,p.reset.val,2,{genes:t,uni:e})/Bs(1,"mad",2,{genes:t,uni:"standard"})).toFixed(2)},calc(){let e=!0;if(Object.keys(p).forEach((function(t){p[t].use&&void 0===p[t].val&&(e=!1)})),m.vis=e,m.vis){let e={};vc[s].forEach((function(t){"reset"!==t&&("micro"!==t?e[t]=p[t].val:e.uni=p.micro.val?"micro":"standard")})),"anti"===s?e.uni="antimatter":"vacuum"===s&&(e.uni="magic"),"plasmid"===a&&(e.rawPlasmids=!0);let t=Gs(p.reset.val,e)[a];return"plasmid"===a&&(g.rawGains=t,g.overflow=void 0!==g.capVal&&t>g.capVal?t-g.capVal:void 0,g.overflowVis=void 0!==g.rawGains&&void 0!==g.capVal),t}"plasmid"===a&&(g.rawGains=void 0,g.overflow=void 0,g.overflowVis=!1)},resetLabel(e){switch(e){case"mad":return z("wiki_calc_mad");case"bioseed":case"cataclysm":case"vacuum":case"ai":case"terraform":return z("wiki_resets_"+e);case"bigbang":return z("wiki_resets_blackhole");case"ascend":return z("wiki_resets_ascension");case"descend":return z("wiki_resets_infusion")}return z("wiki_calc_prestige")},uniLabel:e=>z(e?"universe_"+e:"wiki_calc_universe"),highPopLabel:e=>void 0===e?z("wiki_calc_trait_undefined"):0===e?z("wiki_calc_trait_unowned"):e}})}function yc(e,a){let r=$(`
                      `);e.append(r);let i=z("anti"===a?"resource_AntiPlasmid_name":"resource_Plasmid_name");r.append(`

                      ${z("wiki_calc_bonuses",[z("wiki_calc_prod",[i])])}

                      `);let s=$("
                      "),n=$("
                      ");r.append(s),r.append(n);let c={plas:{val:void 0},phage:{val:void 0},antimatter:{val:!1}},o={underResult:{vis:!1,val:0},overResult:{vis:!1,val:0},bleed:{vis:"anti"===a}};s.append(`\n
                      \n ${z("wiki_calc_effective",[z("plasmid"===a?"resource_Plasmid_plural_name":"resource_AntiPlasmid_plural_name")])} {{ i.plas.val | effective }} - \n ${z("wiki_calc_softcap")} {{ i.phage.val | softcap }}\n
                      \n
                      \n ${z("wiki_calc_under_cap")}\n
                      \n
                      \n (ln(({{ i.plas.val, t | generic }} / {{ | bleedDiv }}) + 50) - 3.91202) / 2.888 / 3 = {{ false | calcUnder }} = +{{ true | calcUnder }}%\n
                      \n
                      \n ${z("wiki_calc_over_cap")}\n
                      \n
                      \n ((((ln({{ i.phage.val, 'phage' | generic }} + 300) - 3.91202)) / 2.888) + ((ln(({{ i.plas.val, t | generic }} / {{ | bleedDiv }}) + 1 - ({{ i.phage.val, 'phage' | generic }} + 250)) / ln2 / 250))) / 3 = {{ false | calcOver }} = +{{ true | calcOver }}%\n
                      \n `),n.append(`\n
                      \n
                      ${z("plasmid"===a?"resource_Plasmid_plural_name":"resource_AntiPlasmid_plural_name")}
                      \n
                      ${z("resource_Phage_name")}
                      \n
                      ${z("universe_antimatter")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:`#${a}ProdCalc`,data:{i:c,s:o,t:a},methods:{val(e){c[e].val&&c[e].val<0&&(c[e].val=0)},bleed(){c.antimatter.val&&"plasmid"===a||!c.antimatter.val&&"anti"===a?o.bleed.vis=!0:o.bleed.vis=!1},resetInputs(){c.plas.val=void 0,c.phage.val=void 0,c.antimatter.val=!1},importInputs(){c.plas.val="plasmid"===a?t.prestige.Plasmid.count:t.prestige.AntiPlasmid.count,c.phage.val=t.prestige.Phage.count,c.antimatter.val="antimatter"===t.race.universe}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"plasmid":return z("resource_Plasmid_plural_name");case"anti":return z("resource_AntiPlasmid_plural_name");case"phage":return z("resource_Phage_name")}},effective:e=>void 0===e?0:o.bleed.vis?e/("plasmid"===a?40:4):e,softcap:e=>250+(void 0===e?0:e),bleedDiv:()=>"plasmid"===a?40:4,calcUnder(e){if(e)return(100*o.underResult.val).toFixed(3);let t=c.plas.val;o.bleed.vis&&(t/="plasmid"===a?40:4);let r=!0;if((void 0===c.plas.val||t>250+c.phage.val)&&(r=!1),o.underResult.vis=r,o.underResult.vis){let e=+(Math.log(t+50)-3.91202).toFixed(5)/2.888;return"anti"===a&&(e/=3),o.underResult.val=e.toFixed(5),o.underResult.val}},calcOver(e){if(e)return(100*o.overResult.val).toFixed(3);let t=c.plas.val;o.bleed.vis&&(t/="plasmid"===a?40:4);let r=!0;if((void 0===c.phage.val||t<=250+c.phage.val)&&(r=!1),o.overResult.vis=r,o.overResult.vis){let e=+(Math.log(250+c.phage.val+50)-3.91202).toFixed(5)/2.888+Math.log(t+1-(250+c.phage.val))/Math.LN2/250;return"anti"===a&&(e/=3),o.overResult.val=e.toFixed(5),o.overResult.val}}}})}function bc(e,a){let r=$(`
                      `);e.append(r);let i=z("phage"===a?"resource_Phage_name":"anti"===a?"resource_AntiPlasmid_name":"resource_Plasmid_name"),s=z("phage"===a?"resource_Phage_name":"anti"===a?"resource_AntiPlasmid_plural_name":"resource_Plasmid_plural_name");r.append(`

                      ${z("wiki_calc_bonuses",[z("wiki_calc_store",[i])])}

                      `);let n=$("
                      "),c=$("
                      ");r.append(n),r.append(c);let o={res:{val:void 0},store:{val:void 0},antimatter:{val:!1,use:!0}};"phage"===a&&(o.antimatter.use=!1);let l={result:{vis:!1,val:0},bleed:{vis:"anti"===a}},_="";"phage"!==a&&(_+=`\n
                      \n ${z("wiki_calc_effective",[s])} {{ i.res.val | effective }}\n
                      \n `),_+='\n
                      \n ({{ i.res.val, t | generic }} / {{ | bleedDiv }}) * {{ i.store.val | storeVal }} = {{ false | calc }} = +{{ true | calc }}%\n
                      \n ',n.append(_),c.append(`\n
                      \n
                      ${s}
                      \n
                      ${z("wiki_tech_special_crispr",[z("wiki_arpa_crispr_store")])} \n \n {{ 0 | storeLabel }}\n {{ 1 | storeLabel }}\n {{ 2 | storeLabel }}\n {{ 3 | storeLabel }}\n {{ 4 | storeLabel }}\n
                      \n
                      ${z("universe_antimatter")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:`#${a}StoreCalc`,data:{i:o,s:l,t:a},methods:{val(){o.res.val&&o.res.val<0&&(o.res.val=0)},pickStore(e){o.store.val=e},bleed(){"phage"!==a&&(o.antimatter.val&&"plasmid"===a||!o.antimatter.val&&"anti"===a?l.bleed.vis=!0:l.bleed.vis=!1)},resetInputs(){o.res.val=void 0,o.store.val=void 0,o.antimatter.val=!1},importInputs(){o.res.val="phage"===a?t.prestige.Phage.count:"plasmid"===a?t.prestige.Plasmid.count:t.prestige.AntiPlasmid.count,o.store.val=t.genes.store||0,o.antimatter.val="antimatter"===t.race.universe}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"plasmid":return z("resource_Plasmid_plural_name");case"anti":return z("resource_AntiPlasmid_plural_name");case"phage":return z("resource_Phage_name")}},storeVal(e){if(void 0===e)return z("wiki_calc_store_multi");if(0===e||"phage"===a&&e<4)return 0;switch(e){case 1:return 4e-4;case 2:return 6e-4;default:return 8e-4}},effective:e=>void 0===e?0:l.bleed.vis?e/("plasmid"===a?40:4):e,storeLabel:e=>void 0===e?z("wiki_tech_special_crispr",[z("wiki_arpa_crispr_store")]):e?z("wiki_arpa_crispr_store")+": "+e:z("wiki_calc_not_owned"),bleedDiv:()=>"plasmid"===a?5:10,calc(e){if(e)return(100*l.result.val).toFixed(2);let t=o.res.val;if(l.bleed.vis&&(t/="plasmid"===a?5:10),l.result.vis=void 0!==o.res.val&&void 0!==o.store.val,l.result.vis){if(0===o.store.val||"phage"===a&&o.store.val<4)l.result.val=0;else switch(o.store.val){case 1:l.result.val=(4e-4*t).toFixed(4);break;case 2:l.result.val=(6e-4*t).toFixed(4);break;default:l.result.val=(8e-4*t).toFixed(4)}return l.result.val}}}})}function wc(e){let t=Ln("create",e),a=["mad","bioseed","blackhole","ascension","cataclysm","vacuum","infusion","ai","terraform"],r=a.map((e=>`${z(`wiki_resets_${e}`)}`));In(t,{name:"intro",template:"resets",paragraphs:3,h_level:2,para_data:{1:[a.length,r.slice(0,-1).join(", ")+`, & ${r[r.length-1]}`]},data_color:{1:["warning","plain"]}}),Ln("add","resets-prestige","intro",z("wiki_menu_intro"));let i=In(t,{name:"mad",template:"resets",paragraphs:9,break:[6,9],h_level:2,para_data:{3:[z("wiki_p_res_plasmids")],4:[z("tech_rocketry"),z("tech_mad")],5:[z("tab_civics"),z("tab_military")],6:[z("wiki_p_res_plasmids")],7:[z("wiki_p_res_plasmids")],9:[z("wiki_resets_mad")]},data_color:{3:["danger"],6:["danger"],7:["danger"]}});i=Bn(i,"mad","gain"),fc(i,"plasmid",!1,"mad"),Ln("add","resets-prestige","mad",z("wiki_resets_mad")),i=In(t,{name:"bioseed",template:"resets",paragraphs:12,break:[5,8,12],h_level:2,para_data:{2:[z("tech_genesis_ship")],3:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage")],4:[z("wiki_p_res_plasmids")],5:[z("tech_genesis_ship"),z("tech_star_dock")],6:[z("tech_interstellar"),z("tech_star_dock")],7:[z("tech_genesis_ship")],9:[z("tech_interstellar"),z("star_dock_probe_desc")],10:[z("wiki_planet_planet")],12:[z("wiki_resets_bioseed")]},data_color:{3:["danger","danger"],4:["danger"]},data_link:{10:["wiki.html#planets-gameplay"]}}),i=Bn(i,"bioseed","gain"),fc(i,"plasmid",!1,"bioseed"),fc(i,"phage",!1,"bioseed"),Ln("add","resets-prestige","bioseed",z("wiki_resets_bioseed"));let s=[];Object.keys(Wt).forEach((function(e){s.push(e)}));let n=s.map((e=>`${z(`universe_${e}`)}`));i=In(t,{name:"blackhole",template:"resets",paragraphs:12,break:[3,6,9,12],h_level:2,para_data:{2:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_dark")],3:[z("tech_dist_stellar_engine")],4:[z("tech_mass_ejector"),z("wiki_resets_blackhole_exotic"),.025,z("resource_Elerium_name"),z("resource_Infernite_name")],5:[z("wiki_p_res_dark")],6:[z("wiki_resets_blackhole_exotic"),z("tech_exotic_infusion")],7:[10,z("wiki_hell_soul_gem")],8:[z("tech_stabilize_blackhole"),z("wiki_resets_blackhole_exotic")],10:[s.length,n.slice(0,-1).join(", ")+`, ${z("or")} ${n[n.length-1]}`],12:[z("wiki_resets_blackhole")]},data_color:{2:["danger","danger","danger"],4:["warning","warning","warning","caution","caution"],5:["danger"],7:["warning","caution"],10:["warning","plain"]}}),i=Bn(i,"bigbang","gain"),fc(i,"plasmid",!1,"bigbang"),fc(i,"phage",!1,"bigbang"),fc(i,"dark",!1,"bigbang"),Ln("add","resets-prestige","blackhole",z("wiki_resets_blackhole")),i=In(t,{name:"vacuum",template:"resets",paragraphs:10,break:[4,8,10],h_level:2,para_data:{4:[80],6:[z("arpa_syphon_damage")],7:[80],8:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_dark")],9:[z("wiki_p_res_dark")],10:[z("wiki_resets_vacuum")]},data_color:{6:["danger"],8:["danger","danger","danger"],9:["danger"]}}),i=Bn(i,"vacuum","gain"),fc(i,"plasmid",!1,"vacuum"),fc(i,"phage",!1,"vacuum"),fc(i,"dark","vacuum","vacuum"),Ln("add","resets-prestige","vacuum",z("wiki_resets_vacuum")),i=In(t,{name:"ascension",template:"resets",paragraphs:10,break:[3,5,7,10],h_level:2,para_data:{2:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_harmony")],3:[z("interstellar_ascension_machine"),"10,000",z("interstellar_thermal_collector")],4:[100,25],7:["+2%"],8:["+2","+5%","+10%"],10:[z("wiki_resets_ascension")]},data_color:{2:["danger","danger","danger"]}}),i=Bn(i,"ascend","gain"),fc(i,"plasmid",!1,"ascend"),fc(i,"phage",!1,"ascend"),fc(i,"harmony",!1,"ascend"),Ln("add","resets-prestige","ascension",z("wiki_resets_ascension")),i=In(t,{name:"cataclysm",template:"resets",paragraphs:10,break:[4,7,10],h_level:2,para_data:{1:[z("planet_unstable")],2:[z("tech_world_collider")],3:[z("tech_dial_it_to_11"),z("tech_limit_collider")],6:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage")],10:[z("wiki_resets_cataclysm")]},data_color:{6:["danger","danger"]}}),i=Bn(i,"cataclysm","gain"),fc(i,"plasmid",!1,"cataclysm"),fc(i,"phage",!1,"cataclysm"),Ln("add","resets-prestige","cataclysm",z("wiki_resets_cataclysm")),i=In(t,{name:"terraform",template:"resets",paragraphs:19,break:[3,6,7,10,12,19],h_level:2,para_data:{1:[z("wiki_resets_terraform"),z("evo_challenge_orbit_decay")],2:[z("wiki_resets_ascension")],3:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_harmony")],7:[z("achieve_lamentis_name")],8:[1],10:[z("rejuvenated")],13:["10%"],14:["5%"],16:["2%","50%"],17:["50%"],19:[z("wiki_resets_terraform")]}}),i=Bn(i,"terraform","gain"),fc(i,"plasmid",!1,"terraform"),fc(i,"phage",!1,"terraform"),fc(i,"harmony",!1,"terraform"),Ln("add","resets-prestige","terraform",z("wiki_resets_terraform")),i=In(t,{name:"infusion",template:"resets",paragraphs:8,break:[4,8],h_level:2,para_data:{2:[z("resource_Artifact_name")],5:[z("resource_Demonic_Essence_name")],6:[z("resource_Demonic_Essence_name")],7:[z("achieve_corrupted_name")],8:[z("wiki_resets_infusion")]},data_color:{2:["danger"],7:["caution"]}}),i=Bn(i,"descend","gain"),fc(i,"artifact",!1,"descend"),Ln("add","resets-prestige","infusion",z("wiki_resets_infusion")),i=In(t,{name:"ai",template:"resets",paragraphs:8,break:[3,6,7,8],h_level:2,para_data:{2:[z("evo_challenge_truepath")],3:[z("space_ai_core"),z("wiki_resets_ai_drift"),"100%"],4:[z("tech_protocol66")],5:[z("space_ai_colonist_title"),z("space_decoder_title"),z("space_shock_trooper_title"),z("space_tank_title")],6:[z("wiki_resets_ai"),z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_ai_core")],7:[z("genelab_genus_synthetic")],8:[z("wiki_resets_ai")]},data_color:{6:["warning","danger","danger","danger"]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"],3:["wiki.html#space-tp_structures-ai_core"],4:["wiki.html#solar-tp_tech-protocol66"],5:["#space-tp_structures-ai_colonist","#space-tp_structures-decoder","#space-tp_structures-shock_trooper","#space-tp_structures-tank"]}}),i=Bn(i,"ai","gain"),fc(i,"plasmid",!1,"ai"),fc(i,"phage",!1,"ai"),fc(i,"cores",!1,"ai"),Ln("add","resets-prestige","ai",z("wiki_resets_ai")),i=In(t,{name:"matrix",template:"resets",paragraphs:6,break:[3,5,6],h_level:2,para_data:{2:[z("evo_challenge_truepath")],3:[z("tau_star_ringworld")],5:[z("wiki_resets_matrix"),z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("civics_servants")],6:[z("wiki_resets_matrix")]},data_color:{5:["warning","danger","danger","danger"]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"],3:["wiki.html#tauceti-structures-ringworld"]}}),i=Bn(i,"matrix","gain"),fc(i,"plasmid",!1,"matrix"),fc(i,"phage",!1,"matrix"),Ln("add","resets-prestige","matrix",z("wiki_resets_matrix")),i=In(t,{name:"retired",template:"resets",paragraphs:6,break:[3,5,6],h_level:2,para_data:{2:[z("evo_challenge_truepath")],3:[z("tech_matrioshka_brain"),z("tech_ignition_device")],5:[z("wiki_resets_retired"),z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("civics_servants")],6:[z("wiki_resets_retired")]},data_color:{5:["warning","danger","danger","danger"]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"],3:["wiki.html#tauceti-structures-matrioshka_brain","wiki.html#tauceti-structures-ignition_device"]}}),i=Bn(i,"retired","gain"),fc(i,"plasmid",!1,"retired"),fc(i,"phage",!1,"retired"),Ln("add","resets-prestige","retired",z("wiki_resets_retired")),i=In(t,{name:"eden",template:"resets",paragraphs:6,break:[3,5,6],h_level:2,para_data:{2:[z("evo_challenge_lone_survivor")],3:[z("tau_star_ringworld")],4:[z("tau_star_goe_facility")],5:[z("wiki_resets_eden"),z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("civics_servants")],6:[z("wiki_resets_eden")]},data_color:{5:["warning","danger","danger","danger"]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"],3:["wiki.html#tauceti-structures-ringworld"],4:["wiki.html#tauceti-structures-goe_facility"]}}),i=Bn(i,"eden","gain"),fc(i,"plasmid",!1,"eden"),fc(i,"phage",!1,"eden"),Ln("add","resets-prestige","eden",z("wiki_resets_eden"))}function kc(e){let a=$("#content");switch(Ss(a),e){case"basics":!function(e){In(e,{name:"start",template:"basics",paragraphs:2,h_level:2}),In(e,{name:"prehistoric",template:"basics",paragraphs:14,break:[2,6,13],h_level:2,para_data:{3:[z("resource_RNA_name"),z("resource_DNA_name")],4:[z("evo_organelles_title"),z("resource_RNA_name"),z("evo_nucleus_title"),z("resource_DNA_name")],5:[z("evo_membrane_title"),z("evo_eukaryotic_title"),z("evo_mitochondria_title")],7:[z("genelab_genus")],8:[3],13:[z("evo_sentience_title")]},data_link:{7:["wiki.html#races-species"]}}),In(e,{name:"civilization",template:"basics",paragraphs:14,break:[2,8,13],h_level:2,para_data:{3:[z("tab_civics")],4:[z("resource_Food_name"),z("job_farmer"),z("job_hunter")],5:["*"],8:[z("resource_Food_name")],9:[z("resource_Food_name"),z("hunger")],10:[z("resource_Food_name")],11:[z("resource_Food_name")],12:[z("resource_Food_name")],13:[z("resource_Knowledge_name")],14:[z("resource_Knowledge_name"),z("city_university")]}}),In(e,{name:"government",template:"basics",paragraphs:8,break:[4],h_level:2,para_data:{1:[z("tech_government"),z("tab_civics"),z("govern_anarchy")],2:[z("tech_government"),z("govern_anarchy")],3:[z("tech_government")],4:[z("morale")],5:[z("morale")],6:[z("morale"),z("job_entertainer"),z("morale_stress")],7:[z("morale_tax"),z("morale")],8:[25,100]}}),In(e,{name:"mad",template:"basics",paragraphs:4,h_level:2,para_data:{1:[z("wiki_resets_mad")],2:[z("wiki_basics_mad_reset"),z("tab_civics"),z("tab_military")],3:[z("tab_space")]},data_link:{2:["wiki.html#resets-prestige"]}})}(a);break;case"mechanics":!function(e){let a=Ln("create",e);In(a,{name:"save",template:"mechanics",label:z("wiki_mechanics_save"),paragraphs:8,break:[3,5],h_level:2,para_data:{1:["~5"],3:[z("wiki_mechanics_save_export")],4:[z("export")],5:[z("restore")],8:[z("restore")]}}),Ln("add","mechanics-gameplay","save",z("wiki_mechanics_save")),In(a,{name:"atime",template:"mechanics",label:z("wiki_mechanics_atime"),paragraphs:6,break:[4,6],h_level:2,para_data:{1:[z("wiki_mechanics_atime")],2:[2,z("wiki_mechanics_atime")],3:["2x",z("wiki_mechanics_atime")],4:[z("wiki_mechanics_atime"),8],5:[12,8,z("wiki_mechanics_atime")],6:[z("wiki_mechanics_atime")]}}),Ln("add","mechanics-gameplay","atime",z("wiki_mechanics_atime")),In(a,{name:"spack",template:"mechanics",label:z("wiki_mechanics_spack"),paragraphs:10,break:[4,6,7,8,9,10],h_level:2,para_data:{1:["UTF-8","JSON",".txt"],4:[`${z("wiki_mechanics_spack_para4_note")}`],6:[z("resource_Food_name"),z("wiki_mechanics_spack_para6_note1"),z("city_biolab"),z("wiki_mechanics_spack_para6_note2")]}}),Ln("add","mechanics-gameplay","spack",z("wiki_mechanics_spack")),In(a,{name:"job",template:"mechanics",label:z("wiki_mechanics_job"),paragraphs:9,break:[5],h_level:2,para_data:{1:[z("wiki_mechanics_job")],2:["*"],3:[z("wiki_mechanics_job")]}}),Ln("add","mechanics-gameplay","job",z("wiki_mechanics_job")),function(e){let a=$('
                      ');e.append(a);let r=$("
                      "),i=$("
                      "),s=$("
                      ");a.append(r),a.append(i),a.append(s);let n={job:{val:void 0},content:{vis:!1,val:void 0},freespirit:{vis:!1,val:void 0},mellow:{val:!1},dense:{vis:!1,val:!1,formVis:!1},workers:{val:void 0},playful:{vis:!1,val:!1},high_pop:{val:void 0},emotionless:{val:void 0},government:{val:void 0},annexed:{vis:!1,val:void 0},electricity:{vis:!1,val:!1},virtual_reality:{val:!1}},c={result:{vis:!1,val:void 0},total:{vis:!1,val:0}},o=["soldier"];Object.keys(Xt).forEach((function(e){"unemployed"!==e&&"forager"!==e&&o.push(e)}));let l=`\n
                      ${z("wiki_calc_job_stress_job")} \n `;o.forEach((function(e){l+=`\n {{ '${e}' | jobLabel }}`})),l+="\n
                      \n ",r.append(l),i.append(`\n
                      \n

                      ${z("wiki_calc_job_stress_divisor")}

                      \n
                      \n
                      \n ({{ i.job.val | stressDiv }} + ({{ i.content.val, 'content' | generic }} * {{ i.job.val | contentVal }}) {{ i.job.val | mellowOp }} - 1) / {{ i.freespirit.val, 'freespirit', 0 | traitVal }} = {{ | calc }}\n
                      \n
                      \n

                      ${z("wiki_calc_job_stress_generated")}

                      \n
                      \n
                      \n 0 * {{ i.workers.val, 'workers' | generic }} / {{ i.high_pop.val, 'high_pop', 0 | traitVal }} / {{ s.result.val, 'divisor' | generic }} * {{ i.emotionless.val, 'emotionless', 1 | traitVal }} * {{ i.government.val, i.electricity.val, i.virtual_reality.val | govVal }} * {{ i.annexed.val | anxVal }} = -{{ | calcTotal }}%\n
                      \n `),s.append(`\n
                      \n
                      ${z("wiki_calc_job_stress_content")}
                      \n
                      ${z("planet_mellow")}
                      \n
                      ${z("planet_dense")}
                      \n
                      ${z("trait_freespirit_name")} \n \n {{ 0 | traitLabel }}\n {{ 0.25 | traitLabel }}\n {{ 0.5 | traitLabel }}\n {{ 1 | traitLabel }}\n {{ 2 | traitLabel }}\n {{ 3 | traitLabel }}\n
                      \n
                      \n
                      \n
                      {{ i.job.val | workersLabel }}
                      \n
                      ${z("wiki_calc_job_stress_annexed")}
                      \n
                      ${z("civics_government")} \n \n {{ 'anarchy' | govLabel }}\n {{ 'autocracy' | govLabel }}\n {{ 'federation' | govLabel }}\n {{ 'socialist' | govLabel }}\n {{ 'other' | govLabel }}\n
                      \n
                      ${z("tech_electricity")}
                      \n
                      ${z("tech_virtual_reality")}
                      \n
                      ${z("trait_playful_name")}
                      \n
                      ${z("trait_high_pop_name")} \n \n {{ 0 | traitLabel }}\n {{ 0.25 | traitLabel }}\n {{ 0.5 | traitLabel }}\n {{ 1 | traitLabel }}\n {{ 2 | traitLabel }}\n {{ 3 | traitLabel }}\n
                      \n
                      ${z("trait_emotionless_name")} \n \n {{ 0 | traitLabel }}\n {{ 0.25 | traitLabel }}\n {{ 0.5 | traitLabel }}\n {{ 1 | traitLabel }}\n {{ 2 | traitLabel }}\n {{ 3 | traitLabel }}\n
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:"#jobStressCalc",data:{i:n,s:c},methods:{val(e){n[e].val&&n[e].val<0&&(n[e].val=0),"annexed"===e&&n[e].val>3&&(n[e].val=3)},pickJob(e){n.job.val=e,n.content.vis="hunter"!==e&&"soldier"!==e,n.freespirit.vis=!["hunter","soldier","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(e),n.dense.vis="miner"===e,n.playful.vis="hunter"===e},pickGov(e){n.government.val=e,n.annexed.vis="federation"!==e,n.electricity.vis="autocracy"===e},pickTrait(e,t){n[t].val=e},resetInputs(){n.job.val=void 0,n.content.val=void 0,n.content.vis=!1,n.freespirit.val=void 0,n.freespirit.vis=!1,n.mellow.val=!1,n.dense.val=!1,n.dense.vis=!1,n.workers.val=void 0,n.playful.val=!1,n.playful.vis=!1,n.government.val=void 0,n.annexed.val=void 0,n.annexed.vis=!1,n.electricity.val=!1,n.electricity.vis=!1,n.virtual_reality.val=!1,n.high_pop.val=void 0,n.emotionless.val=void 0,c.result.val=void 0},importInputs(){if(n.content.val=t.race.content?t.race.content:0,n.freespirit.val=t.race.freespirit?t.race.freespirit:0,n.mellow.val=!(!t.city.ptrait||!t.city.ptrait.includes("mellow")),n.dense.val=!(!t.city.ptrait||!t.city.ptrait.includes("dense")),n.workers.val="soldier"===n.job.val?t.civic.garrison&&t.civic.garrison.max?t.civic.garrison.max:0:t.civic[n.job.val]?t.civic[n.job.val].workers:0,n.playful.val=!!t.race.playful,n.high_pop.val=t.race.high_pop?t.race.high_pop:0,n.emotionless.val=t.race.emotionless?t.race.emotionless:0,t.civic.govern){let e=t.civic.govern.type;switch(e){case"autocracy":case"anarchy":case"socialist":case"federation":n.government.val=e;break;default:n.government.val="other"}n.annexed.vis="federation"!==e,n.electricity.vis="autocracy"===e}if(n.annexed.val=0,t.civic.foreign)for(let e=0;e<3;e++)t.civic.foreign["gov"+e].anx&&n.annexed.val++;n.electricity.val=!!t.tech.high_tech&&t.tech.high_tech>=2,n.virtual_reality.val=!!t.tech.high_tech&&t.tech.high_tech>=12}},filters:{generic:(e,t)=>("workers"===t&&"soldier"===n.job.val&&(t="soldiers"),void 0!==e?e:z("wiki_calc_job_stress_"+t)),jobLabel:e=>e?"soldier"===e?z("governor_soldier"):"titan_colonist"===e?z("job_colonist_tp",[Kn("titan")]):z("job_"+e):z("wiki_calc_job_stress_job"),workersLabel:e=>z("soldier"===e?"wiki_calc_job_stress_soldiers":"wiki_calc_job_stress_workers"),govLabel:e=>z(e?"other"===e?"wiki_calc_job_stress_government_other":"govern_"+e:"civics_government"),traitLabel:e=>void 0===e?z("wiki_calc_trait_undefined"):0===e?z("wiki_calc_trait_unowned"):e,stressDiv(e){if(!e)return z("base");switch(e){case"hunter":return 5;case"soldier":return 2;default:return t.civic[e].stress}},contentVal:e=>e?"hell_surveyor"===e?.2:.4:z("wiki_calc_job_stress_content_multi"),mellowOp(e){switch(e){case"hunter":case"soldier":return`* ${ss.mellow.vars()[0]}`;default:return`+ ${ss.mellow.vars()[1]}`}},govVal(e,t,a){if(!e)return z("wiki_calc_job_stress_government");switch(e){case"anarchy":return.5;case"autocracy":return t?a?1.1:1.18:1.25;case"socialist":return 1.1;default:return 1}},anxVal:e=>void 0!==e?+(1.1**e).toFixed(5):z("civics_spy_purchase_bd"),traitVal(e,t,a){switch(t){case"freespirit":return 1+Ei.freespirit.vars(e)[a]/100;case"high_pop":return Ei.high_pop.vars(e)[a];case"emotionless":return 1-Ei.emotionless.vars(e)[a]/100}},calc(){let e=void 0!==n.job.val&&void 0!==n.freespirit.val;if("hunter"!==n.job.val&&"soldier"!==n.job.val&&(e=e&&void 0!==n.content.val),c.result.vis=e,c.result.vis){let e="hunter"===n.job.val?5:"soldier"===n.job.val?2:t.civic[n.job.val].stress;return"hunter"===n.job.val||"soldier"===n.job.val?n.mellow.val&&(e*=ss.mellow.vars()[0]):(n.mellow.val&&(e+=ss.mellow.vars()[1]),e+=("hell_surveyor"===n.job.val?.2:.4)*n.content.val,n.dense.val&&"miner"===n.job.val&&(e-=ss.dense.vars()[1]),n.freespirit.val&&!["farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(n.job.val)&&(e/=1+Ei.freespirit.vars(n.freespirit.val)[0]/100)),c.result.val=+e.toFixed(4),c.result.val}c.result.val=void 0},calcTotal(){let e=n.playful.val&&"hunter"===n.job.val;if(e)c.total.vis=e,c.total.val=0;else if(e=c.result.vis&&n.government.val&&void 0!==n.workers.val&&void 0!==n.high_pop.val&&void 0!==n.emotionless.val,"federation"!==n.government.val&&(e=e&&void 0!==n.annexed.val),c.total.vis=e,c.total.vis){let e=n.workers.val/c.result.val;if("federation"!==n.government.val)switch(e*=1.1**n.annexed.val,n.government.val){case"anarchy":e/=2;break;case"autocracy":e*=n.electricity.val?n.virtual_reality.val?1.1:1.18:1.25;break;case"socialist":e*=1.1}n.high_pop.val&&(e/=Ei.high_pop.vars(n.high_pop.val)[0]),n.emotionless.val&&(e*=1-Ei.emotionless.vars(n.emotionless.val)[1]/100),c.total.val=+e.toFixed(3)}return c.total.val}}})}(Bn(In(a,{name:"job_stress",template:"mechanics",label:z("wiki_mechanics_job_stress"),paragraphs:7,break:[3,5,6,7],h_level:2,para_data:{2:[z("job_unemployed"),z("trait_content_name")],3:[z("wiki_calc_job_stress_divisor"),1],4:[z("trait_freespirit_name"),z("trait_content_name"),z("planet_mellow")],6:[z("trait_optimistic_name"),z("trait_pessimistic_name"),z("morale_stress"),z("morale")],7:[z("civics_garrison_annex")]},data_link:{2:[!1,"wiki.html#traits-species-minor_content"],4:["wiki.html#traits-species-major_freespirit","wiki.html#traits-species-minor_content","wiki.html#planets-gameplay-mellow"],6:["wiki.html#traits-species-major_optimistic","wiki.html#traits-species-major_pessimistic"]}}),"mechanics","job_stress",z("wiki_mechanics_job_stress"))),Ln("add","mechanics-gameplay","job_stress",z("wiki_mechanics_job_stress")),In(a,{name:"multiplier",template:"mechanics",label:z("wiki_mechanics_multiplier"),paragraphs:5,break:[4],h_level:2,para_data:{1:[z("wiki_mechanics_multiplier")],2:["10x",t.settings.keyMap.x10,"25x",t.settings.keyMap.x25,"100x",t.settings.keyMap.x100],4:[z("wiki_mechanics_multiplier")],5:[z("wiki_mechanics_multiplier")]},data_color:{2:["warning","caution","warning","caution","warning","caution"]}}),Ln("add","mechanics-gameplay","multiplier",z("wiki_mechanics_multiplier")),In(a,{name:"cost_creep",template:"mechanics",label:z("wiki_mechanics_cost_creep"),paragraphs:7,break:[4,7],h_level:2,para_data:{2:[z("resource_Lumber_name"),200,1.3,"200*1.3=260","200*1.3^2=338"],3:[z("wiki_menu_arpa")],5:[z("tech_steel_beams"),z("trait_large_name"),z("tab_arpa_crispr"),z("wiki_arpa_crispr_creep")],6:[z("trait_creative_name"),z("wiki_menu_arpa")],7:[1.005]},data_link:{3:["wiki.html#projects-arpa"],5:["wiki.html#discovery-tech-steel_beams","wiki.html#traits-species-genus_large",!1,"wiki.html#crispr-prestige-genetic_memory"],6:["wiki.html#traits-species-major_creative"]}}),Ln("add","mechanics-gameplay","cost_creep",z("wiki_mechanics_cost_creep")),In(a,{name:"queue",template:"mechanics",label:z("wiki_mechanics_queue"),paragraphs:13,break:[4,6,9,10,11,13],h_level:2,para_data:{1:[z("wiki_mechanics_queue"),z("tech_urban_planning")],2:[z("building_queue")],4:[z("wiki_mechanics_queue_research"),z("tech_assistant")],7:[z("q_key"),t.settings.keyMap.q],8:[z("q_key")],10:[z("q_any")],12:[z("q_merge")]},data_color:{7:["warning","caution"]}}),Ln("add","mechanics-gameplay","queue",z("wiki_mechanics_queue"));{let e=In(a,{name:"multipliers",template:"mechanics",label:z("wiki_mechanics_multipliers"),paragraphs:1,h_level:2});In(e,{name:"multipliers_prod",template:"mechanics",label:z("wiki_mechanics_multipliers"),paragraphs:4,break:[3,4],h_level:!1,para_data:{3:[z("wiki_mechanics_multipliers_struct"),z("wiki_mechanics_multipliers_bonus")]}}).append('
                      '),In(e,{name:"multipliers_dis",template:"mechanics",label:z("wiki_mechanics_multipliers"),paragraphs:7,break:[3,4],h_level:!1,para_data:{3:[z("wiki_mechanics_multipliers_base"),z("wiki_mechanics_multipliers_discount"),z("wiki_mechanics_multipliers_struct")],5:[z("city_mass_driver")],6:[100,z("city_mass_driver"),"5%",95,35.84],7:[100,.95,20,35.84]},data_link:{5:["wiki.html#planetary-structures-mass_driver"]}}),e.append(`
                      ${z("wiki_mechanics_multipliers_exception")}
                      `),Ln("add","mechanics-gameplay","multipliers",z("wiki_mechanics_multipliers"))}In(a,{name:"blocking",template:"mechanics",label:z("wiki_mechanics_blocking"),paragraphs:6,break:[4,6],h_level:2,para_data:{2:[z("color_red")],3:[z("color_orange")],5:[z("color_red")]},data_color:{2:["danger"],3:["caution"],5:["danger"]}}).append('
                      '),Ln("add","mechanics-gameplay","blocking",z("wiki_mechanics_blocking")),In(a,{name:"astro",template:"mechanics",label:z("wiki_mechanics_astro"),paragraphs:15,break:[3,4,5,6,7,8,9,10,11,12,13,14,15],h_level:2,para_data:{2:[12],3:[z("sign_aries"),z("sign_aries_symbol"),G("aries")[0]+"%"],4:[z("sign_taurus"),z("sign_taurus_symbol"),G("taurus")[0]+"%"],5:[z("sign_gemini"),z("sign_gemini_symbol"),G("gemini")[0]+"%"],6:[z("sign_cancer"),z("sign_cancer_symbol"),G("cancer")[0]],7:[z("sign_leo"),z("sign_leo_symbol"),G("leo")[0]+"%"],8:[z("sign_virgo"),z("sign_virgo_symbol"),G("virgo")[0]+"%"],9:[z("sign_libra"),z("sign_libra_symbol"),G("libra")[0]+"%"],10:[z("sign_scorpio"),z("sign_scorpio_symbol"),G("scorpio")[0]+"%"],11:[z("sign_sagittarius"),z("sign_sagittarius_symbol"),G("sagittarius")[0]+"%"],12:[z("sign_capricorn"),z("sign_capricorn_symbol"),G("capricorn")[0]+"%"],13:[z("sign_aquarius"),z("sign_aquarius_symbol"),G("aquarius")[0]+"%"],14:[z("sign_pisces"),z("sign_pisces_symbol")],15:[z(`sign_${N()}`)]},data_color:{3:["warning","caution","warning"],4:["warning","caution","warning"],5:["warning","caution","warning"],6:["warning","caution","warning"],7:["warning","caution","warning"],8:["warning","caution","warning"],9:["warning","caution","warning"],10:["warning","caution","warning"],11:["warning","caution","warning"],12:["warning","caution","warning"],13:["warning","caution","warning"],14:["warning","caution"],15:["caution"]}}),Ln("add","mechanics-gameplay","astro",z("wiki_mechanics_astro")),In(a,{name:"bank_vault",template:"mechanics",label:z("wiki_mechanics_bank_vault"),paragraphs:2,h_level:2,para_data:{1:[z("city_bank"),z("interstellar_exchange_title"),z("portal_arcology_title"),z("resource_Money_name"),z("wiki_mechanics_bank_vault"),z("space_red_spaceport_title"),z("wiki_challenges_scenarios_cataclysm")],2:[z("resource_Money_name"),z("city_bank"),z("tech_adamantite_vault"),z("governor_entrepreneur"),z("trait_paranoid_name"),z("tech_stock_market"),z("tech_unification"),z("wiki_challenges_modes_inflation")]},data_link:{1:["wiki.html#planetary-structures-bank","wiki.html#interstellar-structures-exchange","wiki.html#hell-structures-arcology",!1,!1,"wiki.html#space-structures-spaceport","wiki.html#challenges-gameplay-scenarios_cataclysm"],2:[!1,!1,"wiki.html#interstellar-tech-adamantite_vault","wiki.html#governor-gameplay-entrepreneur","wiki.html#traits-species-major_paranoid","wiki.html#projects-arpa-stock_exchange","wiki.html#early_space-tech-unification2","wiki.html#challenges-gameplay-modes_inflation"]}}),Ln("add","mechanics-gameplay","bank_vault",z("wiki_mechanics_bank_vault")),In(a,{name:"homeless",template:"mechanics",label:z("wiki_mechanics_homeless"),paragraphs:4,break:[3],h_level:2,para_data:{3:[z("arpa_projects_railway_title")]},data_link:{3:["wiki.html#projects-arpa-railway"]}}),Ln("add","mechanics-gameplay","homeless",z("wiki_mechanics_homeless")),function(e){let a=$('
                      ');e.append(a),a.append(`

                      ${z("wiki_mechanics_warmonger")}

                      `);let r=$("
                      "),i=$("
                      ");a.append(r),a.append(i);let s={fatigue:{val:void 0},protest:{val:void 0}},n={result:{vis:!1,val:0}};r.append(`\n
                      \n log2({{ i.fatigue.val, 'fatigue' | generic }} + {{ i.protest.val, 'protest' | generic }}) = {{ false | calc }} = {{ true | calc }}% ${z("wiki_mechanics_warmonger")}\n
                      \n `),i.append(`\n
                      \n
                      ${z("wiki_calc_warmonger_fatigue")}
                      \n
                      ${z("wiki_calc_warmonger_protest")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:"#warmongerCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.fatigue.val=void 0,s.protest.val=void 0},importInputs(){s.fatigue.val=t.civic.garrison&&t.civic.garrison.fatigue?t.civic.garrison.fatigue:0,s.protest.val=t.civic.garrison&&t.civic.garrison.protest?t.civic.garrison.protest:0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_warmonger_"+t),calc:e=>e?Math.round(n.result.val):(n.result.vis=void 0!==s.fatigue.val&&void 0!==s.protest.val&&s.fatigue.val+s.protest.val>=1,n.result.vis?(n.result.val=Math.log2(s.fatigue.val+s.protest.val),n.result.val):void 0)}})}(Bn(In(a,{name:"warmonger",template:"mechanics",label:z("wiki_mechanics_warmonger"),paragraphs:8,break:[4],h_level:2,para_data:{2:[z("trait_immoral_name")],3:[z("govern_autocracy"),z("trait_blood_thirst_name")],4:[z("wiki_calc_warmonger_fatigue"),z("wiki_calc_warmonger_protest")],5:[z("achieve_warmonger_name")],6:[z("wiki_calc_warmonger_fatigue"),1,z("wiki_calc_warmonger_protest")],7:[z("wiki_calc_warmonger_fatigue"),z("wiki_calc_warmonger_protest"),1,0],8:[`log2(${z("wiki_calc_warmonger_fatigue")} + ${z("wiki_calc_warmonger_protest")})`]},data_link:{2:["wiki.html#traits-species-genus_immoral"],3:["wiki.html#government-gameplay-autocracy","wiki.html#traits-species-major_blood_thirst"]}}),"mechanics","warmonger",z("wiki_mechanics_warmonger"))),Ln("add","mechanics-gameplay","warmonger",z("wiki_mechanics_warmonger")),function(e){let t=$('
                      ');e.append(t);let a=$("
                      "),r=$("
                      ");t.append(a),t.append(r);let i={military:{val:void 0},relations:{val:void 0},unrest:{val:void 0},spies:{val:void 0},infiltrator:{val:!1}},s={base:{vis:!1,val:void 0},total:{vis:!1,val:void 0}};a.append(`\n
                      \n

                      ${z("wiki_calc_spy_cost_base_title")}

                      \n
                      \n
                      \n ({{ i.military.val, 'mil_rate' | generic }} / 2) + ((100 - {{ i.relations.val, 'relations' | generic }}) / 2) - {{ i.unrest.val, 'unrest' | generic }} + 10 = {{ | calcBase }}\n
                      \n
                      \n

                      ${z("wiki_calc_spy_cost_total")}

                      \n
                      \n
                      \n ({{ s.base.val, 'unrest' | generic }} / 3)^({{ i.spies.val, 'spies' | generic }} + 1) + 500 = {{ | calcTotal }}\n
                      \n `),r.append(`\n
                      \n
                      ${z("civics_gov_mil_rate")}
                      \n
                      ${z("civics_gov_relations")}
                      \n
                      ${z("civics_gov_unrest")}
                      \n
                      \n
                      \n
                      ${z("wiki_calc_spy_cost_spies")}
                      \n
                      ${z("trait_infiltrator_name")}
                      \n
                      \n
                      \n \n
                      \n `),Cs({el:"#spyCostCalc",data:{i,s},methods:{val(e){i[e].val&&i[e].val<0&&(i[e].val=0),"military"!==e&&"spies"!==e&&i[e].val>100?i[e].val=100:"military"===e&&i[e].val<50&&(i[e].val=50)},resetInputs(){i.military.val=void 0,i.relations.val=void 0,i.unrest.val=void 0,i.spies.val=void 0,i.infiltrator.val=!1,s.base.val=void 0}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"spies":case"base":return z("wiki_calc_spy_cost_"+t);default:return z("civics_gov_"+t)}},calcBase(){if(s.base.vis=void 0!==i.military.val&&void 0!==i.relations.val&&void 0!==i.unrest.val,s.base.vis){let e=i.military.val/2+(100-i.relations.val)/2-i.unrest.val+10;return e<50&&(e=50),s.base.val=+e.toFixed(4),s.base.val}},calcTotal(){if(s.total.vis=void 0!==s.base.val&&void 0!==i.spies.val,s.total.vis){let e=s.base.val;return i.infiltrator.val&&(e/=3),s.total.val=+(e**(i.spies.val+1)+500).toFixed(2),s.total.val}}}})}(Bn(In(a,{name:"spy",template:"mechanics",label:z("wiki_mechanics_spy"),paragraphs:8,break:[3,4,5,6,7],h_level:2,para_data:{1:[z("tech_spy")],4:[1,z("civics_gov_relations"),z("civics_gov_mil_rate")],5:[2,z("civics_gov_mil_rate"),z("civics_gov_eco_rate")],6:[3,z("civics_gov_eco_rate"),z("civics_gov_unrest")],7:[4,z("civics_gov_unrest")],8:[4],9:[z("tech_espionage")]},data_link:{1:["wiki.html#civilized-tech-spy"],9:["wiki.html#civilized-tech-espionage"]}}),"mechanics","spy_cost")),Ln("add","mechanics-gameplay","spy",z("wiki_mechanics_spy")),function(e){let t=$('
                      ');e.append(t);let a=$("
                      "),r=$("
                      ");t.append(a),t.append(r);let i={relations:{val:void 0},economic:{val:void 0},unrest:{val:void 0}},s={annex:{vis:!1,val:void 0},purchase:{vis:!1,val:void 0}};a.append(`\n
                      \n

                      ${z("wiki_calc_occupation_annex")}

                      \n
                      \n
                      \n 300 - {{ i.relations.val, 'relations' | generic }} - {{ i.unrest.val, 'unrest' | generic }} = {{ | calcAnnex }}%\n
                      \n
                      \n

                      ${z("wiki_calc_occupation_purchase")}

                      \n
                      \n
                      \n ({{ i.economic.val, 'eco_rate' | generic }} * 15384) * (1 + (0.016 * (100 - {{ i.relations.val, 'relations' | generic }}))) * (1 - (0.0025 * {{ i.unrest.val, 'unrest' | generic }})) = {{ | calcPurchase }}\n
                      \n `),r.append(`\n
                      \n
                      ${z("civics_gov_relations")}
                      \n
                      ${z("civics_gov_eco_rate")}
                      \n
                      ${z("civics_gov_unrest")}
                      \n
                      \n
                      \n \n
                      \n `),Cs({el:"#occupationCalc",data:{i,s},methods:{val(e){i[e].val&&i[e].val<0&&(i[e].val=0),"economic"!==e&&i[e].val>100&&(i[e].val=100)},resetInputs(){i.relations.val=void 0,i.economic.val=void 0,i.unrest.val=void 0}},filters:{generic:(e,t)=>void 0!==e?e:z("civics_gov_"+t),calcAnnex(){if(s.annex.vis=void 0!==i.relations.val&&void 0!==i.unrest.val,s.annex.vis)return s.annex.val=300-i.relations.val-i.unrest.val,s.annex.val},calcPurchase(){if(s.purchase.vis=void 0!==i.relations.val&&void 0!==i.economic.val&&void 0!==i.unrest.val,s.purchase.vis)return s.purchase.val=+(15384*i.economic.val*(1+.016*(100-i.relations.val))*(1-.0025*i.unrest.val)).toFixed(0),s.purchase.val}}})}(Bn(In(a,{name:"occupying",template:"mechanics",label:z("wiki_mechanics_occupying"),paragraphs:20,break:[3,8,12,16,18,19,20],h_level:2,para_data:{1:[z("civics_foreign"),z("civics_garrison_tactic_siege"),z("civics_spy_annex"),z("civics_spy_purchase")],2:["+5%","+8%",z("govern_federation")],3:[z("civics_garrison_tactic_siege"),20],5:[z("civics_garrison"),z("civics_garrison_tactic_siege")],6:[z("civics_garrison_unoccupy"),z("tech_unification")],7:[z("govern_federation"),15],8:["50%",z("civics_gov_relations"),"50%",z("civics_gov_unrest"),`(300 - ${z("civics_gov_relations")} - ${z("civics_gov_unrest")})`,z("morale")],9:["50%",z("civics_gov_relations"),"50%",z("civics_gov_unrest"),z("civics_spy_annex")],10:[z("morale"),z("civics_spy_annex")],11:[z("morale_stress"),"1.1x",z("govern_federation")],12:[z("resource_Money_name")],13:[3,z("tech_spy"),z("civics_spy_purchase")],14:[z("wiki_mechanics_occupying_para14_note1",[z("civics_gov_eco_rate"),z("civics_gov_relations"),z("civics_gov_unrest")]),z("resource_Money_name"),z("civics_spy_purchase")],15:[z("civics_garrison_purchase"),z("resource_Money_name"),z("morale_tax"),"20%",z("govern_federation")],16:[z("tech_unification")],17:[z("civics_garrison_occupy")],18:[z("achieve_world_domination_name")],19:[z("achieve_illuminati_name")],20:[z("achieve_syndicate_name")]},data_link:{2:[!1,!1,"wiki.html#government-gameplay-federation"],6:[!1,"wiki.html#early_space-tech-unification2"],7:["wiki.html#government-gameplay-federation"],11:[!1,!1,"wiki.html#government-gameplay-federation"],15:[!1,!1,!1,!1,"wiki.html#government-gameplay-federation"],16:["wiki.html#early_space-tech-unification2"]}}),"mechanics","occupation")),Ln("add","mechanics-gameplay","occupying",z("wiki_mechanics_occupying")),In(a,{name:"religion",template:"mechanics",label:z("wiki_mechanics_religion"),paragraphs:20,break:[3,6,8,15,20],h_level:2,para_data:{1:[z("wiki_mechanics_religion")],3:[z("city_temple")],4:[z("city_temple"),z("resource_Plasmid_plural_name")],5:[z("evo_challenge_plasmid"),z("faith")],6:[z("tech_fanaticism"),z("tech_anthropology")],8:[z("tech_fanaticism"),z("tech_indoctrination"),z("tech_missionary"),z("tech_zealotry")],9:[z("tech_fanaticism")],10:[z("wiki_menu_species")],11:[5],12:[z("tech_indoctrination")],13:[z("tech_missionary")],14:[z("tech_zealotry")],15:[z("tech_anthropology"),z("tech_mythology"),z("tech_archaeology"),z("tech_merchandising")],16:[z("tech_anthropology")],17:[z("tech_mythology")],18:[z("tech_archaeology")],19:[z("tech_merchandising")],20:[z("tab_arpa_crispr"),z("wiki_arpa_crispr_transcendence")]},data_link:{10:["wiki.html#races-species"],20:["wiki.html#crispr-prestige","wiki.html#crispr-prestige-transcendence"]}}),Ln("add","mechanics-gameplay","religion",z("wiki_mechanics_religion"));{let e=`${Hs("star")}`,t=`${Hs("star")}`,r=`${Hs("star")}`,i=`${Hs("star")}`;In(a,{name:"challenge",template:"mechanics",label:z("wiki_mechanics_challenge"),paragraphs:15,break:[4,8,14],h_level:2,para_data:{1:[z("wiki_mechanics_challenge"),z("wiki_menu_prehistoric"),z("tab_arpa_crispr"),z("arpa_genepool_hardened_genes_title")],2:[4,z("evo_challenge_plasmid"),z("evo_challenge_trade"),z("evo_challenge_craft"),z("evo_challenge_crispr")],4:[z("evo_challenge_plasmid"),z("resource_Plasmid_plural_name")],5:[z("evo_challenge_trade")],6:[z("evo_challenge_craft")],7:[z("evo_challenge_crispr"),z("wiki_arpa_crispr_creep"),"20%"],8:[z("wiki_mechanics_challenge")],9:[1,e,z("plain"),"5%"],10:[2,t,z("bronze"),"12%"],11:[3,r,z("silver"),"25%"],12:[4,i,z("gold"),"45%"],14:[z("wiki_mechanics_challenge"),e]},data_color:{2:["caution","warning","warning","warning","warning"],7:["warning","warning","caution"],9:["caution",!1,"warning","warning"],10:["caution",!1,"warning","warning"],11:["caution",!1,"warning","warning"],12:["caution",!1,"warning","warning"]},data_link:{1:[!1,!1,"wiki.html#crispr-prestige","wiki.html#crispr-prestige-hardened_genes"],7:[!1,"wiki.html#crispr-prestige-genetic_memory",!1]}}),Ln("add","mechanics-gameplay","challenge",z("wiki_mechanics_challenge"))}In(a,{name:"mastery",template:"mechanics",label:z("mastery"),paragraphs:15,break:[3,8,10,13],h_level:2,para_data:{1:[z("mastery"),z("tab_arpa_crispr"),z("arpa_genepool_unlocked_title")],2:[z("mastery"),z("tab_achieve")],4:["0.15%","0.10%"],5:[1],6:[1,5],7:["1.25%"],9:[z("standard"),"0.25%"],10:[z("arpa_genepool_universal_title"),z("arpa_genepool_standard_title")],11:[z("arpa_genepool_universal_title"),"0.05%","0.10%","0.15%"],12:["0.30%","1.50%"],13:[z("arpa_genepool_standard_title"),"0.05%"],15:[z("arpa_genepool_standard_title"),"0.20%","0.10%"]},data_color:{4:["caution","caution"],5:["caution"],6:["caution","caution"],7:["caution"],9:[!1,"caution"],11:["warning","caution","caution","caution"],12:["caution","caution"],13:["warning","caution"],15:["warning","caution","caution"]},data_link:{1:[!1,"wiki.html#crispr-prestige","wiki.html#crispr-prestige-unlocked"],9:["wiki.html#universes-gameplay"],10:["wiki.html#crispr-prestige-universal","wiki.html#crispr-prestige-standard"]}}),Ln("add","mechanics-gameplay","mastery",z("mastery")),function(e){let a=$('
                      ');e.append(a);let r=$("
                      "),i=$("
                      ");a.append(r),a.append(i);let s={mutations:{val:void 0},days:{val:void 0}},n={game:{vis:!1,val:void 0},real:{vis:!1,val:void 0}};r.append(`\n
                      \n

                      ${z("wiki_calc_g_decay_game")}

                      \n
                      \n
                      \n (50000000 / (1 + {{ i.mutations.val, 'mutations' | generic }})) - {{ i.days.val, 'days' | generic }} = {{ false | calc }}\n
                      \n
                      \n

                      ${z("wiki_calc_g_decay_real")}

                      \n
                      \n
                      \n {{ s.game.val, 'game' | generic }} / 17280 = {{ true | calc }}\n
                      \n `),i.append(`\n
                      \n
                      ${z("wiki_calc_g_decay_mutations")}
                      \n
                      ${z("wiki_calc_g_decay_days")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:"#genomeDecayCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.mutations.val=void 0,s.days.val=void 0},importInputs(){s.mutations.val=t.race.mutation,s.days.val=t.stats.days}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_g_decay_"+t),calc:e=>e?n.real.val:(n.game.vis=void 0!==s.mutations.val&&void 0!==s.days.val,n.real.vis=n.game.vis,n.game.vis?(n.game.val=+(5e7/(1+s.mutations.val)-s.days.val).toFixed(0),n.real.val=+(n.game.val/17280).toFixed(6),n.game.val):(n.game.val=void 0,void(n.real.val=void 0)))}})}(Bn(In(a,{name:"genome_decay",template:"mechanics",label:z("wiki_mechanics_genome_decay"),paragraphs:4,break:[3],h_level:2,para_data:{1:[z("wiki_mechanics_genome_decay_para1_note1",[z("wiki_calc_g_decay_mutations")]),z("wiki_mechanics_genome_decay")],2:["2-3"],3:[z("wiki_mechanics_genome_decay"),z("resource_Plasmid_name"),"+0%"],4:[z("tech_genetic_decay"),z("trait_fortify_name"),z("wiki_mechanics_genome_decay"),z("resource_Plasmid_name"),"+0%"]},data_link:{4:["wiki.html#early_space-tech-genetic_decay","wiki.html#traits-species-special_fortify"]}}),"mechanics","g_decay",z("wiki_mechanics_genome_decay"))),Ln("add","mechanics-gameplay","genome_decay",z("wiki_mechanics_genome_decay")),In(a,{name:"crispr_mutation",template:"mechanics",label:z("wiki_mechanics_crispr_mutation"),paragraphs:5,break:[3],h_level:2,para_data:{1:[z("tab_arpa_crispr"),z("arpa_genepool_mutation_title"),z("resource_Plasmid_plural_name")],3:[z("tech_arpa"),z("tab_arpa_genetics")],4:["5x",z("wiki_mechanics_crispr_mutation_para4_note1")],5:[z("wiki_mechanics_custom"),z("race_sludge"),"10x"]},data_link:{1:[!1,"wiki.html#crispr-prestige-mutation","wiki.html#resources-prestige-plasmids"],4:[!1,"wiki.html#traits-species"],5:["wiki.html#custom-species","wiki.html#races-species-sludge"]}}),Ln("add","mechanics-gameplay","crispr_mutation",z("wiki_mechanics_crispr_mutation"));{let e=In(a,{name:"planet",template:"planet",label:z("wiki_menu_planets"),paragraphs:4,h_level:2,para_data:{2:[365,"25%"],3:[4],4:["200-600"]}});In(a,{name:"geology",template:"planet",label:z("wiki_menu_planets"),paragraphs:4,h_level:2,para_data:{2:[2],3:["-10%","+19%"],4:[7,"+44%"]}},e),In(a,{name:"seeother",template:"planet",label:z("wiki_menu_planets"),paragraphs:1,h_level:2,para_data:{1:[z("wiki_menu_planets")]},data_link:{1:["wiki.html#planets-gameplay"]}},e),Ln("add","mechanics-gameplay","planet",z("wiki_menu_planets"))}In(a,{name:"soul_gem",template:"hell",label:z("wiki_hell_soul_gem"),paragraphs:4,h_level:2,para_data:{1:[z("wiki_hell_soul_gem"),z("tab_portal")],3:[z("tech_demon_attractor")]}}),Ln("add","mechanics-gameplay","soul_gem",z("wiki_hell_soul_gem"));{let e=In(a,{name:"quantum",template:"mechanics",label:z("wiki_mechanics_quantum"),paragraphs:4,h_level:2,para_data:{1:[z("wiki_mechanics_quantum")],2:[z("tech_quantum_computing")],4:[z("interstellar_citadel_title")]},data_link:{2:["wiki.html#deep_space-tech-quantum_computing"],4:["wiki.html#interstellar-structures-citadel"]}});!function(e){let a=$('
                      ');e.append(a),a.append(`

                      ${z("wiki_mechanics_quantum")}

                      `);let r=$("
                      "),i=$("
                      ");a.append(r),a.append(i);let s={knowledge:{val:void 0},citadels:{val:void 0},cores:{val:void 0},supercore:{val:!1},linked:{val:void 0},citizens:{val:void 0}},n={linked:{val:void 0},result:{vis:!1,val:0}};r.append("\n
                      \n (ln(1 + ((1.1 - 1) * {{ i.knowledge.val, 'knowledge' | generic }} / 250000)) / ln(1.1)) * (1 + (0.05 * {{ i.citadels.val, 'citadels' | generic }})) * (2 - (0.99^{{ i.cores.val, 'cores' | generic }})) * 1.25 * {{ s.linked.val, 'linked' | generic }} = {{ | calc }}\n
                      \n "),i.append(`\n
                      \n
                      ${z("wiki_calc_q_level_knowledge")}
                      \n
                      ${z("wiki_calc_q_level_citadels")}
                      \n
                      ${z("wiki_calc_cores")}
                      \n
                      ${z("wiki_calc_q_level_supercore")}
                      \n
                      ${z("trait_linked_name")} \n \n {{ 0 | traitLabel }}\n {{ 0.25 | traitLabel }}\n {{ 0.5 | traitLabel }}\n {{ 1 | traitLabel }}\n {{ 2 | traitLabel }}\n {{ 3 | traitLabel }}\n
                      \n
                      ${z("wiki_calc_citizens")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:"#quantumLevelCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},pickTrait(e,t){s[t].val=e},resetInputs(){s.knowledge.val=void 0,s.citadels.val=void 0,s.cores.val=void 0,s.supercore.val=!1,s.linked.val=void 0,s.citizens.val=void 0},importInputs(){s.knowledge.val=t.resource.Knowledge.max,s.citadels.val=t.interstellar.citadel?t.interstellar.citadel.on:0,s.cores.val=t.prestige.AICore.count,s.supercore.val=!(!t.space.ai_core2||!t.space.ai_core2.on),s.linked.val=t.race.linked?t.race.linked:0,s.citizens.val=t.resource[t.race.species].amount}},filters:{generic:(e,t)=>void 0!==e?e:z("cores"===t?"wiki_calc_"+t:"wiki_calc_q_level_"+t),traitLabel:e=>void 0===e?z("wiki_calc_trait_undefined"):0===e?z("wiki_calc_trait_unowned"):e,calc(){let e=!0;if(s.linked.val>0)if(void 0!==s.citizens.val){let e=Ei.linked.vars(s.linked.val)[0]/100*s.citizens.val;e>Ei.linked.vars(s.linked.val)[1]/100&&(e-=Ei.linked.vars(s.linked.val)[1]/100,e/=e+200-Ei.linked.vars(s.linked.val)[1],e+=Ei.linked.vars(s.linked.val)[1]/100),n.linked.val=+(1+e).toFixed(4)}else n.linked.val=void 0,e=!1;if(n.result.vis=e&&void 0!==s.knowledge.val&&void 0!==s.citadels.val&&void 0!==s.cores.val,n.result.vis){let e=Math.log(1+(1.1-1)*s.knowledge.val/25e4)/Math.log(1.1)*(1+.05*s.citadels.val)*(2-.99**s.cores.val);return s.supercore.val&&(e*=1.25),n.linked.val&&(e*=n.linked.val),n.result.val=+e.toFixed(4),n.result.val}}}})}(Bn(e,"mechanics","quantum_level",z("wiki_mechanics_quantum"))),Ln("add","mechanics-gameplay","quantum",z("wiki_mechanics_quantum")),In(e,{name:"quantum_swarm_ai",template:"mechanics",label:z("tech_swarm_control_ai"),paragraphs:2,h_level:2,para_data:{1:[z("tech_quantum_computing"),z("space_sun_swarm_satellite_title"),z("space_sun_swarm_control_title")],2:[z("space_sun_swarm_control_title"),11,z("wiki_mechanics_quantum")]},data_link:{1:["wiki.html#deep_space-tech-swarm_control_ai","wiki.html#space-structures-swarm_satellite","wiki.html#space-structures-swarm_control"]}}),In(e,{name:"quantum_swarm",template:"mechanics",label:z("tech_quantum_swarm"),paragraphs:3,h_level:2,para_data:{1:[z("tech_quantum_swarm"),z("space_hell_swarm_plant_title")],2:["1%"],3:["95%"]},data_link:{1:["wiki.html#deep_space-tech-quantum_swarm","wiki.html#space-structures-swarm_plant"]}}),In(e,{name:"quantum_manufacture",template:"mechanics",label:z("tech_quantum_manufacturing"),paragraphs:4,break:[2,3,4],h_level:2,para_data:{1:[z("tech_quantum_manufacturing"),z("city_factory"),z("wiki_mechanics_quantum")],2:[z("modal_factory_lux")],3:[z("resource_Furs_name"),"(Q Level - 1) * 12.5"],4:["(Q Level - 1) * 50"]},data_link:{1:["wiki.html#deep_space-tech-quantum_manufacturing","wiki.html#planetary-structures-factory",!1]}}),In(e,{name:"quantum_cement_processing",template:"mechanics",label:z("tech_cement_processing"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("tech_cement_processing"),z("interstellar_citadel_title")],2:["(Q Level / 1.75) %"]},data_link:{1:["wiki.html#interstellar-tech-cement_processing","wiki.html#interstellar-structures-citadel"]}}),In(e,{name:"quantum_graph_processing",template:"mechanics",label:z("tech_graphene_processing"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("tech_graphene_processing"),z("interstellar_citadel_title")],2:["(Q Level / 5) %"]},data_link:{1:["wiki.html#intergalactic-tech-graphene_processing","wiki.html#interstellar-structures-citadel"]}}),In(e,{name:"quantum_ai_logistics",template:"mechanics",label:z("tech_ai_logistics"),paragraphs:3,break:[3],h_level:2,para_data:{1:[z("tech_ai_logistics"),z("interstellar_cargo_yard_title"),z("city_shed_title3")],2:[z("city_shed_title3")],3:[z("wiki_mechanics_quantum")]},data_link:{1:["wiki.html#interstellar-tech-ai_logistics","wiki.html#interstellar-structures-cargo_yard","wiki.html#interstellar-structures-warehouse"]}}),In(e,{name:"quantum_arcology",template:"mechanics",label:z("portal_arcology_title"),paragraphs:1,h_level:2,para_data:{1:[z("portal_arcology_title"),10]},data_link:{1:["wiki.html#hell-structures-arcology",!1]}})}!function(e){let a=$('
                      ');e.append(a);let r=$("
                      "),i=$("
                      ");a.append(r),a.append(i);let s=["Food","Lumber","Chrysotile","Stone","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal","Oil","Uranium","Steel","Titanium","Alloy","Polymer","Iridium","Helium_3","Deuterium","Neutronium","Adamantite","Infernite","Elerium","Nano_Tube","Graphene","Stanene","Bolognium","Vitreloy","Orichalcum","Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Aerogel","Nanoweave","Scarletite"],n={result:{vis:!1,kt:void 0,solar:void 0,MW:void 0,exoVis:!1,exotic:void 0,MWVis:!1,MWTot:void 0,timeVis:!1,timeTot:void 0}},c={solar_tot:{val:void 0},exotic_tot:{val:void 0},grav:{val:!0}},o=$("
                      "),l=$("
                      "),_=!0;i.append(o),s.forEach((function(e){_||l.append(" + "),_=!1,c[e]={val:void 0},o.append(`\n
                      ${z("resource_"+e+"_name")}
                      \n `),l.append(`({{ i.${e}.val, '${e}' | generic }} * ${Fa[e]})`)})),l.append(" = {{ true, 'kt' | calc }}"),r.append(`\n
                      \n

                      ${z("wiki_calc_mass_kt")}

                      \n
                      \n `),r.append(l),r.append(`\n
                      \n

                      ${z("wiki_calc_mass_solar")}

                      \n
                      \n
                      \n {{ s.result.kt, 'kt' | generic }} / 10000000000 = {{ false, 'solar' | calc }}\n
                      \n
                      \n

                      ${z("wiki_calc_mass_exotic")}

                      \n
                      \n
                      \n (({{ i.Infernite.val, 'Infernite' | generic }} * 222.666) + ({{ i.Elerium.val, 'Elerium' | generic }} * 297.115)) / 10000000000 = {{ | calcExotic }}\n
                      \n
                      \n

                      ${z("wiki_calc_mass_MW")}

                      \n
                      \n
                      \n ({{ s.result.solar, 'solar' | generic }} * {{ false | amountMW }}) + ({{ s.result.exotic, 'exotic' | generic }} * {{ true | amountMW }}) = {{ false, 'MW' | calc }}\n
                      \n
                      \n

                      ${z("wiki_calc_mass_MW_tot")}

                      \n
                      \n
                      \n 20 + (({{ i.solar_tot.val, 'solar_tot' | generic }} - 8) * {{ false | amountMW }}) + ({{ i.exotic_tot.val, 'exotic_tot' | generic }} * {{ true | amountMW }}) = {{ | calcMW }}\n
                      \n
                      \n

                      ${z("wiki_calc_mass_time_to_explode")}

                      \n
                      \n
                      \n (0.025 - {{ i.exotic_tot.val, 'exotic_tot' | generic }}) / {{ s.result.exotic, 'exotic' | generic }} = {{ | calcTime }}\n
                      \n `),i.append(`\n
                      \n
                      ${z("wiki_calc_mass_solar_tot")}
                      \n
                      ${z("wiki_calc_mass_exotic_tot")}
                      \n
                      ${z("tech_gravity_convection")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:"#massCalc",data:{i:c,s:n},methods:{val(e){"solar_tot"===e?c[e].val&&c[e].val<8&&(c[e].val=8):c[e].val&&c[e].val<0&&(c[e].val=0)},resetInputs(){s.forEach((function(e){c[e].val=void 0})),c.solar_tot.val=void 0,c.exotic_tot.val=void 0,c.grav.val=!0},importInputs(){t.interstellar.mass_ejector?s.forEach((function(e){c[e].val=t.interstellar.mass_ejector[e]})):s.forEach((function(e){c[e].val=0})),c.solar_tot.val=t.interstellar.stellar_engine?t.interstellar.stellar_engine.mass:8,t.tech.roid_eject&&(c.solar_tot.val+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12)),c.exotic_tot.val=t.interstellar.stellar_engine?t.interstellar.stellar_engine.exotic:0,c.grav.val=t.tech.gravity&&t.tech.gravity>=2}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"kt":case"solar":case"solar_tot":case"exotic":case"exotic_tot":case"MW":return z("wiki_calc_mass_"+t);default:return z("resource_"+t+"_name")+"/s"}},amountMW:e=>(c.grav.val?13.5:7.5)*(e?10:1),calc(e,t){if(e){let e=!0;if(s.forEach((function(t){e&&void 0===c[t].val&&(e=!1)})),n.result.vis=e,n.result.vis){let e=0;s.forEach((function(t){e+=c[t].val*Fa[t]})),n.result.kt=+e.toFixed(4),n.result.solar=+(e/1e10).toFixed(10),n.result.MW=+(n.result.solar*(c.grav.val?13.5:7.5)+n.result.exotic*(c.grav.val?135:75)).toFixed(10)}else n.result.kt=void 0,n.result.solar=void 0,n.result.mw=void 0}return n.result[t]},calcExotic(){if(void 0!==c.Infernite.val&&void 0!==c.Elerium.val)return n.result.exoVis=!0,n.result.exotic=+((c.Infernite.val*Fa.Infernite+c.Elerium.val*Fa.Elerium)/1e10).toFixed(10),n.result.exotic;n.result.exoVis=!1,n.result.exotic=void 0},calcMW(){if(void 0!==c.solar_tot.val&&void 0!==c.exotic_tot.val)return n.result.MWVis=!0,n.result.MWTot=+((c.solar_tot.val-8)*(c.grav.val?13.5:7.5)+c.exotic_tot.val*(c.grav.val?135:75)+20).toFixed(10),n.result.MWTot;n.result.MWVis=!1,n.result.MWTot=void 0},calcTime(){if(void 0!==c.exotic_tot.val&&n.result.exoVis)return n.result.timeVis=!0,c.exotic_tot.val>=.025?n.result.timeTot=z("wiki_calc_mass_time_reached"):0===n.result.exotic?n.result.timeTot=z("time_never"):n.result.timeTot=zs(Math.round((.025-c.exotic_tot.val)/n.result.exotic)),n.result.timeTot;n.result.timeVis=!1,n.result.timeTot=void 0}}})}(Bn(In(a,{name:"mass",template:"mechanics",label:z("wiki_mechanics_mass"),paragraphs:11,break:[5,9],h_level:2,para_data:{1:[z("tab_interstellar")],2:[z("tech_mass_ejector"),z("interstellar_mass_ejector"),z("tab_ejector")],4:[1e10.toLocaleString()],5:[z("universe_magic"),z("resource_Infernite_name"),z("resource_Elerium_name")],6:[.025,z("tech_stabilize_blackhole"),z("tech_exotic_infusion")],7:[z("tech_stabilize_blackhole"),0,40,z("tech_exotic_infusion"),z("wiki_resets_blackhole")],8:[z("tech_stabilize_blackhole"),.025],9:[z("interstellar_stellar_engine"),20,8],10:[1,7.5,z("interstellar_stellar_engine"),13.5,z("tech_gravity_convection")],11:[10]},data_link:{2:["wiki.html#interstellar-tech-mass_ejector","wiki.html#interstellar-structures-mass_ejector"],6:[!1,"wiki.html#interstellar-tech-stabilize_blackhole","wiki.html#interstellar-tech-infusion_confirm"],7:["wiki.html#interstellar-tech-stabilize_blackhole",!1,!1,"wiki.html#interstellar-tech-infusion_confirm","wiki.html#resets-prestige-blackhole"],8:["wiki.html#interstellar-tech-stabilize_blackhole"],9:["wiki.html#interstellar-structures-stellar_engine"],10:[!1,!1,"wiki.html#interstellar-structures-stellar_engine",!1,"wiki.html#interstellar-tech-gravity_convection"]}}),"eject","mass")),Ln("add","mechanics-gameplay","mass",z("wiki_mechanics_mass"));{let e=In(a,{name:"piracy",template:"mechanics",label:z("galaxy_piracy"),paragraphs:6,break:[4],h_level:2,para_data:{1:[z("galaxy_piracy"),z("wiki_menu_intergalactic")],2:[z("galaxy_embassy")],4:[z("tab_galactic"),z("galaxy_piracy"),z("galaxy_stargate")],5:[z("interstellar_stargate")]}});In(a,{name:"pirate_ramp",template:"mechanics",label:z("galaxy_piracy"),paragraphs:3,h_level:2,para_data:{1:[z("galaxy_stargate"),z("galaxy_gateway")],2:[z("tab_galactic")],3:[z("galaxy_embassy"),z("tech_xeno_gift"),z("galaxy_alien2_mission",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])]}},e),In(a,{name:"pirate_threat",template:"mechanics",label:z("galaxy_piracy"),paragraphs:7,break:[2,3,4,5,6,7],h_level:2,para_data:{1:[z("galaxy_armada")],2:[z("galaxy_gateway"),100,250,500],3:[z("galaxy_stargate"),100,250,500],4:[z("galaxy_gorddon"),800],5:[z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),1e3],6:[z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),2500],7:[z("galaxy_chthonian"),7500]},data_color:{2:["caution","warning","warning","warning"],3:["caution","warning","warning","warning"],4:["caution","warning"],5:["caution","warning"],6:["caution","warning"],7:["caution","warning"]}},e),Ln("add","mechanics-gameplay","piracy",z("galaxy_piracy"))}!function(e){let a=$('
                      ');e.append(a),a.append(`

                      ${z("wiki_calc_bonuses",[z("trait_untapped_name")])}

                      `);let r=$("
                      "),i=$("
                      ");a.append(r),a.append(i);let s={genes:{val:void 0}},n={result:{vis:!1,val:0}};r.append('\n
                      \n ({{ i.genes.val | generic }} / ({{ i.genes.val | generic }} + 20) / 10) + 0.00024 = {{ false | calc }} = +{{ true | calc }}%\n
                      \n '),i.append(`\n
                      \n
                      ${z("resource_Genes_name")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:"#untappedPotentialCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.genes.val=void 0},importInputs(){s.genes.val=t.custom?an({genus:t.custom.race0.genus,traitlist:t.custom.race0.traits}):0}},filters:{generic:e=>void 0!==e?e:z("resource_Genes_name"),calc:e=>e?(100*n.result.val).toFixed(3):(n.result.vis=s.genes.val,n.result.vis?(n.result.val=+(s.genes.val/(s.genes.val+20)/10+24e-5).toFixed(5),n.result.val):void 0)}})}(Bn(In(a,{name:"custom",template:"mechanics",label:z("wiki_mechanics_custom"),paragraphs:12,break:[3,5,9,11],h_level:2,para_data:{1:[z("wiki_resets_ascension")],2:[z("wiki_resets_ascension")],5:[z("resource_Genes_name")],6:[z("resource_Genes_name")],7:[2],8:[z("achieve_technophobe_name"),5,7],9:[z("tech_fanaticism"),z("tech_deify")],11:[0,z("resource_Genes_name")],12:[z("resource_Genes_name"),z("trait_untapped_name")]},data_link:{1:["wiki.html#resets-prestige-ascension"],2:["wiki.html#resets-prestige-ascension"],8:["wiki.html#perks-prestige-technophobe"],9:[t.genes.transcendence?"wiki.html#civilized-tech-alt_fanaticism":"wiki.html#civilized-tech-fanaticism","wiki.html#early_space-tech-deify"]}}),"mechanics","untapped",z("trait_untapped_name"))),Ln("add","mechanics-gameplay","custom",z("wiki_mechanics_custom"));{let e=In(a,{name:"pillar",template:"hell",label:z("wiki_mechanics_pillar"),paragraphs:5,h_level:2,para_data:{1:[z("portal_ruins_name")],2:["1%",z("harmonic")],3:["3%"],4:[z("harmonic"),"2%","6%"],5:[z("wiki_hell_pillar_para5d1"),12]},data_link:{5:["wiki.html#hell-structures-west_tower"]}});In(a,{name:"pillar",template:"mechanics",label:z("wiki_mechanics_pillar"),paragraphs:10,break:[4,6,8],h_level:2,para_data:{1:[z("tech_pillars"),z("resource_Harmony_name"),z("resource_Scarletite_name")],2:[z("resource_Scarletite_name"),1e6.toLocaleString(),125e3.toLocaleString()],3:[z("universe_micro")],4:[z("evo_challenge_genes"),z("harmonic")],5:[z("tech_scarletite"),z("evo_challenge_genes")],6:[z("achieve_resonance_name")],7:[z("achieve_resonance_name"),z("tech_scarletite")],8:[z("race_junker"),z("wiki_mechanics_custom"),z("achieve_enlightenment_name"),z("race_sludge")],9:[z("wiki_mechanics_custom")],10:[z("race_junker"),z("genelab_genus_humanoid"),z("race_sludge")]},data_link:{1:["wiki.html#dimensional-tech-pillars"],3:["wiki.html#universes-gameplay-micro"],5:["wiki.html#dimensional-tech-scarletite"],7:[!1,"wiki.html#dimensional-tech-scarletite"],8:["wiki.html#races-species-junker","wiki.html#mechanics-gameplay-custom",!1,"wiki.html#races-species-sludge"],9:["wiki.html#mechanics-gameplay-custom"],10:["wiki.html#races-species-junker",!1,"wiki.html#races-species-sludge"]}},e),Ln("add","mechanics-gameplay","pillar",z("wiki_mechanics_pillar"))}{let e=In(a,{name:"dlord",template:"mechanics",label:z("wiki_mechanics_dlord"),paragraphs:5,h_level:2,para_data:{1:[z("portal_waygate_title")],2:[z("resource_Demonic_Essence_name"),z("wiki_resets_infusion")],3:[z("wiki_resets_infusion"),"+1"],4:["+25%",z("wiki_resets_infusion")],5:[z("tech_dark_bomb"),z("wiki_resets_infusion")]},data_link:{1:["wiki.html#hell-structures-waygate"],2:[!1,"wiki.html#resets-prestige-infusion"],3:["wiki.html#resets-prestige-infusion"],4:[!1,"wiki.html#resets-prestige-infusion"],5:["wiki.html#dimensional-tech-dark_bomb","wiki.html#resets-prestige-infusion"]}});e.append(`\n

                      ${z("wiki_mechanics_dlord_str")}

                      \n `),Object.keys(Wt).forEach((function(a){let r=t.stats.spire[xn(a)]&&t.stats.spire[xn(a)].dlstr?z("wiki_mechanics_dlord_str_empowered",[t.stats.spire[xn(a)].dlstr]):z("wiki_mechanics_dlord_str_not_empowered");e.append(`\n
                      \n ${z("universe_"+a)}: ${r}\n
                      \n `)})),Ln("add","mechanics-gameplay","dlord",z("wiki_mechanics_dlord"))}{let e=In(a,{name:"syndicate",template:"mechanics",label:z("wiki_mechanics_syndicate"),paragraphs:2,h_level:2,para_data:{1:[z("wiki_mechanics_syndicate"),z("wiki_challenges_scenarios_truepath"),z("wiki_mechanics_syndicate_para1_note1"),z("tech_shipyard",[Ki[t.race.species?t.race.species:human].solar.dwarf])],2:[z("galaxy_piracy"),z("tab_galactic")]},data_link:{1:[!1,"wiki.html#challenges-gameplay-scenarios_truepath","wiki.html#progress-events-syndicate","wiki.html#solar-tp_tech-shipyard"],2:["wiki.html#mechanics-gameplay-piracy"]}}),r=In(e,{name:"syndicate_influence",template:"mechanics",label:z("wiki_mechanics_syndicate_influence"),paragraphs:3,break:[3],h_level:2,para_data:{1:[0],2:[z("space_mission_title",[Kn("triton")]),z("tech_data_analysis")],3:["1/10",1,Kn("triton"),"1/5"]},data_link:{2:["wiki.html#space-tp_structures-triton_mission","wiki.html#solar-tp_tech-data_analysis"]}});{let e=Dn(r,"mechanics","syndicate_influence_current",z("wiki_mechanics_syndicate_influence_current"));["moon","red","gas","gas_moon","belt","titan","enceladus","triton","kuiper","eris"].forEach((function(a){let r=t.space.syndicate&&t.space.syndicate["spc_"+a]?t.space.syndicate["spc_"+a]:0;e.append(`
                      ${Kn(a)}: ${r}`)}))}!function(e){let a=$('
                      ');e.append(a),a.append(`

                      ${z("wiki_calc_syndicate_caps")}

                      `);let r=$("
                      "),i=$("
                      ");a.append(r),a.append(i);let s={triton1:{val:!1},outer4:{val:!1}},n="";["moon","red","gas","gas_moon","belt","titan","enceladus","triton","kuiper","eris"].forEach((function(e){n+=`\n
                      \n ${Kn(e)}: {{ '${e}' | calc }}\n
                      \n `})),r.append(n),i.append(`\n
                      \n
                      ${z("space_mission_title",[Kn("triton")])}
                      \n
                      ${z("tech_data_analysis")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:"#syndicateCapCalc",data:{i:s},methods:{resetInputs(){s.triton1.val=!1,s.outer4.val=!1},importInputs(){s.triton1.val=t.tech.triton&&t.tech.triton>=1,s.outer4.val=t.tech.outer&&t.tech.outer>=4}},filters:{calc(e){switch(e){case"titan":return s.triton1.val?s.outer4.val?2e3:1e3:600;case"enceladus":return s.triton1.val?s.outer4.val?1500:1e3:600;case"triton":return s.triton1.val&&s.outer4.val?5e3:3e3;case"kuiper":return 2500;case"eris":return 7500;default:return 500}}}})}(Bn(r,"mechanics","syndicate_cap")),function(e){let a=$('
                      ');e.append(a);let r=$("
                      "),i=$("
                      ");a.append(r),a.append(i);let s={region:{val:void 0},relations:{val:void 0,vis:!1,alliance:!1,war:!1},triton1:{val:!1,vis:!1},outer4:{val:!1,vis:!1},ship_security:{val:void 0},base:{val:void 0,vis:!1},sam:{val:void 0,vis:!1},fob:{val:!1,vis:!1},intel:{val:void 0},syndicate:{val:void 0}},n={divisor:{vis:!1,val:void 0},region_security:{vis:!1,val:void 0},residual:{vis:!1,val:void 0},penalty:{vis:!1,val:void 0}};r.append(`\n
                      \n

                      ${z("wiki_calc_syndicate_penalty_divisor")}

                      - {{ i.relations.val | relationsType}}

                      \n
                      \n
                      \n {{ i.region.val | divisorBase }} + (25 * ({{ i.relations.val, 'relations' | generic }} - 90)) + (13 * ({{ i.relations.val, 'relations' | generic }} - 40)) = {{ | calcDivisor }}\n
                      \n
                      \n

                      ${z("wiki_calc_syndicate_penalty_region_security")}

                      \n
                      \n
                      \n ({{ i.ship_security.val, 'ship_security' | generic }} + (50 * {{ i.base.val, 'base' | generic }}) + (25 * {{ i.sam.val, 'sam' | generic }}) + 500) * ({{ i.intel.val, 'intel' | generic }} / 100) = {{ | calcSecurity }}\n
                      \n
                      \n

                      ${z("wiki_calc_syndicate_penalty_residual")}

                      \n
                      \n
                      \n {{ i.syndicate.val, 'syndicate' | generic }} - {{ s.region_security.val, 'region_security' | generic }} = {{ | calcResidual }}\n
                      \n
                      \n

                      ${z("wiki_mechanics_syndicate_penalty")}

                      \n
                      \n
                      \n {{ s.residual.val, 'residual' | generic }} / {{ s.divisor.val, 'divisor' | generic }} = {{ false | calcPenalty }} = -{{ true | calcPenalty }}%\n
                      \n `),i.append(`\n
                      \n
                      \n
                      \n ${z("wiki_calc_syndicate_penalty_region")}\n
                      \n
                      \n \n \n {{ 'moon' | regionLabel }}\n {{ 'red' | regionLabel }}\n {{ 'gas' | regionLabel }}\n {{ 'gas_moon' | regionLabel }}\n {{ 'belt' | regionLabel }}\n {{ 'titan' | regionLabel }}\n {{ 'enceladus' | regionLabel }}\n {{ 'triton' | regionLabel }}\n {{ 'kuiper' | regionLabel }}\n {{ 'eris' | regionLabel }}\n \n
                      \n
                      \n
                      ${z("wiki_calc_syndicate_penalty_rival_relations")}
                      \n
                      ${z("space_mission_title",[Kn("triton")])}
                      \n
                      ${z("tech_data_analysis")}
                      \n
                      ${z("wiki_calc_syndicate_penalty_ship_security")}
                      \n
                      ${z("tech_operating_base")}
                      \n
                      ${z("space_sam_title")}
                      \n
                      ${z("space_fob_title")}
                      \n
                      ${z("space_scan_effectiveness")}
                      \n
                      ${z("space_syndicate")}
                      \n
                      \n
                      \n \n \n
                      \n `);let c=function(e){switch(e){case"titan":return s.triton1.val?s.outer4.val?2e3:1e3:600;case"enceladus":return s.triton1.val?s.outer4.val?1500:1e3:600;case"triton":return s.triton1.val&&s.outer4.val?5e3:3e3;case"kuiper":return 2500;case"eris":return 7500;default:return 500}};Cs({el:"#syndicatePenaltyCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0),"relations"===e?s[e].val>100&&(s[e].val=100):"syndicate"===e&&s.region.val&&s[e].val>c(s.region.val)&&(s[e].val=c(s.region.val))},pickRegion(e){s.region.val=e,s.relations.vis=["moon","red","gas","gas_moon","belt"].includes(e),s.triton1.vis=["titan","enceladus","triton"].includes(e),s.syndicate.val&&s.syndicate.val>c(e)&&(s.syndicate.val=c(e)),s.base.vis="enceladus"===e,s.sam.vis="titan"===e,s.fob.vis="triton"===e},resetInputs(){s.region={val:void 0},s.relations={val:void 0,vis:!1,alliance:!1,war:!1},s.triton1={val:!1,vis:!1},s.outer4={val:!1,vis:!1},s.ship_security={val:void 0},s.base={val:void 0,vis:!1},s.sam={val:void 0,vis:!1},s.fob={val:!1,vis:!1},s.intel={val:void 0},s.syndicate={val:void 0}},importInputs(){t.civic.foreign&&t.civic.foreign.gov3&&(s.relations.val=100-t.civic.foreign.gov3.hstl),s.relations.alliance=s.relations.val>90,s.relations.war=s.relations.val<40,s.relations.vis=s.region.val&&["moon","red","gas","gas_moon","belt"].includes(s.region.val),s.triton1.vis=s.region.val&&["titan","enceladus","triton"].includes(s.region.val),s.triton1.val=t.tech.triton&&t.tech.triton>=1,s.outer4.val=t.tech.outer&&t.tech.outer>=4,s.region.val&&t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")&&(s.ship_security.val=0,s.intel.val=0,t.space.shipyard.ships.forEach((function(e){if(e.location==="spc_"+s.region.val&&0===e.transit&&e.fueled){let t=at(e);s.ship_security.val+=e.damage>0?Math.round(t*(100-e.damage)/100):t,s.intel.val+=_t(e)}})),"triton"===s.region.val&&t.space.fob&&t.space.fob.on>0&&(s.intel.val+=10),s.intel.val=(Math.round((s.intel.val-100)/(s.intel.val-100+200)*100)+100+25)/1.25,s.syndicate.val=t.space.syndicate&&t.space.syndicate["spc_"+s.region.val]?t.space.syndicate["spc_"+s.region.val]:0),s.base.val=t.space.operating_base?t.space.operating_base.on:0,s.base.vis=s.region.val&&"enceladus"===s.region.val,s.sam.val=t.space.sam?t.space.sam.on:0,s.sam.vis=s.region.val&&"titan"===s.region.val,s.fob.val=t.space.fob&&t.space.fob.on>0,s.fob.vis=s.region.val&&"triton"===s.region.val}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"base":return z("tech_operating_base");case"sam":case"fob":return z("space_"+t+"_title");case"intel":return z("space_scan_effectiveness");case"relations":return z("wiki_calc_syndicate_penalty_rival_relations");case"syndicate":return z("space_syndicate");default:return z("wiki_calc_syndicate_penalty_"+t)}},regionLabel:e=>e?Kn(e):z("wiki_calc_syndicate_penalty_region"),relationsType:e=>(e>90?(s.relations.alliance=!0,s.relations.war=!1):e<40?(s.relations.war=!0,s.relations.alliance=!1):(s.relations.war=!1,s.relations.alliance=!1),z(e<40?"wiki_calc_syndicate_penalty_rival_war":e>90?"wiki_calc_syndicate_penalty_rival_ally":"wiki_calc_syndicate_penalty_rival_neutral")),divisorBase(e){if(!e)return z("wiki_calc_syndicate_penalty_region_divisor_base");switch(e){case"moon":case"red":return 1250;case"gas":case"gas_moon":case"belt":return 1020;default:return c(e)}},calcDivisor(){if(s.region.val)if(["moon","red","gas","gas_moon","belt"].includes(s.region.val))if((s.relations.war||s.relations.alliance)&&void 0===s.relations.val)n.divisor.val=void 0,n.divisor.vis=!1;else{let e=0,t=["moon","red"].includes(s.region.val)?1250:1020;s.relations.war?e=13*(s.relations.val-40):s.relations.alliance&&(e=25*(s.relations.val-90)),n.divisor.val=t+e,n.divisor.vis=!0}else n.divisor.val=c(s.region.val),n.divisor.vis=!0;else n.divisor.val=void 0,n.divisor.vis=!1;return n.divisor.val},calcSecurity(){let e=0,t=void 0!==s.ship_security.val&&void 0!==s.intel.val;if(t){if(e+=s.ship_security.val,s.region.val)switch(s.region.val){case"enceladus":void 0!==s.base.val?e+=50*s.base.val:t=!1;break;case"titan":void 0!==s.sam.val?e+=25*s.sam.val:t=!1;break;case"triton":s.fob.val&&(e+=500)}t?(n.region_security.val=Math.round(e*(s.intel.val/100)),n.region_security.vis=t):(n.region_security.val=void 0,n.region_security.vis=!1)}else n.region_security.val=void 0,n.region_security.vis=!1;return n.region_security.val},calcResidual(){if(void 0!==s.syndicate.val&&void 0!==n.region_security.val){let e=s.syndicate.val-n.region_security.val;e<0&&(e=0),n.residual.val=e,n.residual.vis=!0}else n.residual.val=void 0,n.residual.vis=!1;return n.residual.val},calcPenalty:e=>e?(100*n.penalty.val).toFixed(2):(n.penalty.vis=void 0!==n.residual.val&&void 0!==n.divisor.val,n.penalty.vis?n.penalty.val=+(n.residual.val/n.divisor.val).toFixed(4):n.penalty.val=void 0,n.penalty.val)}})}(Bn(In(e,{name:"syndicate_penalty",template:"mechanics",label:z("wiki_mechanics_syndicate_penalty"),paragraphs:6,break:[2,4,5],h_level:2,para_data:{1:[z("galaxy_piracy"),z("portal_ruins_security")],2:[Kn("titan")],3:[z("civics_gov_relations"),z("wiki_mechanics_rival")],5:[z("galaxy_armada"),z("tab_galactic"),z("portal_ruins_security")],6:[z("portal_ruins_security"),z("firepower"),z("outer_shipyard_hull"),z("space_scan_effectiveness")]},data_link:{1:["wiki.html#mechanics-gameplay-piracy"]}}),"mechanics","syndicate_penalty",z("wiki_mechanics_syndicate_penalty"))),Ln("add","mechanics-gameplay","syndicate",z("wiki_mechanics_syndicate"))}{let e=In(a,{name:"tp_ships",template:"mechanics",label:z("wiki_mechanics_tp_ships"),paragraphs:2,h_level:2,para_data:{1:[z("outer_shipyard_title"),z("tab_shipyard"),z("tab_civics")],2:[z("tab_galactic"),z("galaxy_piracy")]},data_link:{1:["wiki.html#space-tp_structures-shipyard"],2:[!1,"wiki.html#mechanics-gameplay-piracy"]}});!function(e){let a=$('
                      ');e.append(a);let r=$("
                      "),i=$("
                      "),s=$("
                      ");a.append(r),a.append(i),a.append(s);let n={owned:{val:void 0},class:{val:void 0},power:{val:void 0},weapon:{val:void 0},armor:{val:void 0},engine:{val:void 0},sensor:{val:void 0}},c={Money:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Aluminium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Adamantite:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Steel:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Alloy:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Neutronium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Titanium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Copper:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Orichalcum:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Iridium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Iron:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Nano_Tube:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Quantium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1}},o={exp1:{val:void 0},exp2:{val:void 0},creep:{val:void 0}};r.append(`\n
                      \n
                      \n

                      ${z("wiki_calc_tp_ships_costs_base_costs")}

                      \n
                      \n
                      \n

                      ${z("resource_Money_name")}:

                      {{ i.class.val, 'class', 'Money' | getBase }}^{{ i.sensor.val, 'sensor', 'Money' | getExponent }} = {{ 'Money' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Aluminium_name")}:

                      {{ i.class.val, 'class', 'Aluminium' | getBase }} = {{ 'Aluminium' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Adamantite_name")}:

                      {{ i.class.val, 'class', 'Adamantite' | getBase }} = {{ 'Adamantite' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Steel_name")}:

                      {{ i.armor.val, 'armor', 'Steel' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Steel' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Alloy_name")}:

                      {{ i.armor.val, 'armor', 'Alloy' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Alloy' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Neutronium_name")}:

                      {{ i.armor.val, 'armor', 'Neutronium' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Neutronium' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Titanium_name")}:

                      {{ i.engine.val, 'engine', 'Titanium' | getBase }}^{{ s.exp2.val, 'exp2' | generic }} * 5 = {{ 'Titanium' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Copper_name")}:

                      {{ i.power.val, 'power', 'Copper' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Copper' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Orichalcum_name")}:

                      {{ i.power.val, 'power', 'Orichalcum' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Orichalcum' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Iridium_name")}:

                      ({{ i.power.val, 'power', 'Iridium' | getBase }}^{{ s.exp2.val, 'exp2' | generic }})^{{ i.weapon.val, 'weapon', 'Iridium' | getExponent }} * 50 = {{ 'Iridium' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Iron_name")}:

                      {{ i.weapon.val, 'weapon', 'Iron' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} * 10 = {{ 'Iron' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Nano_Tube_name")}:

                      {{ i.weapon.val, 'weapon', 'Nano_Tube' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Nano_Tube' | calcPre }}\n
                      \n
                      \n

                      ${z("resource_Quantium_name")}:

                      {{ i.weapon.val, 'weapon', 'Quantium' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Quantium' | calcPre }}\n
                      \n
                      \n `);let l='\n
                      \n
                      \n

                      {{ i.owned.val, i.class.val | finalLabel }}

                      \n
                      \n ';["Money","Aluminium","Adamantite","Steel","Alloy","Neutronium","Titanium","Copper","Orichalcum","Iridium","Iron","Nano_Tube","Quantium"].forEach((function(e){l+=`\n
                      \n

                      ${z("resource_"+e+"_name")}:

                      {{ r.${e}.preVal, 'base' | generic }} * 0.750.9(1 + ({{ i.owned.val, 'owned' | generic }} - 2) / 25 * {{ s.creep.val, 'creep' | generic }})3 * (1 + {{ i.owned.val, 'owned' | generic }}) = {{ '${e}' | calcFinal }}\n
                      \n `})),l+="
                      ",i.append(l),s.append(`\n
                      \n
                      ${z("wiki_calc_tp_ships_costs_owned")}
                      \n
                      \n
                      \n ${z("outer_shipyard_class")}\n
                      \n
                      \n \n \n {{ 'class', 'corvette' | genericLabel }}\n {{ 'class', 'frigate' | genericLabel }}\n {{ 'class', 'destroyer' | genericLabel }}\n {{ 'class', 'cruiser' | genericLabel }}\n {{ 'class', 'battlecruiser' | genericLabel }}\n {{ 'class', 'dreadnought' | genericLabel }}\n {{ 'class', 'explorer' | genericLabel }}\n \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_power")}\n
                      \n
                      \n \n \n {{ 'power', 'solar' | genericLabel }}\n {{ 'power', 'diesel' | genericLabel }}\n {{ 'power', 'fission' | genericLabel }}\n {{ 'power', 'fusion' | genericLabel }}\n {{ 'power', 'elerium' | genericLabel }}\n \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_weapon")}\n
                      \n
                      \n \n \n {{ 'weapon', 'railgun' | genericLabel }}\n {{ 'weapon', 'laser' | genericLabel }}\n {{ 'weapon', 'p_laser' | genericLabel }}\n {{ 'weapon', 'plasma' | genericLabel }}\n {{ 'weapon', 'phaser' | genericLabel }}\n {{ 'weapon', 'disruptor' | genericLabel }}\n \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_armor")}\n
                      \n
                      \n \n \n {{ 'armor', 'steel' | genericLabel }}\n {{ 'armor', 'alloy' | genericLabel }}\n {{ 'armor', 'neutronium' | genericLabel }}\n \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_engine")}\n
                      \n
                      \n \n \n {{ 'engine', 'ion' | genericLabel }}\n {{ 'engine', 'tie' | genericLabel }}\n {{ 'engine', 'pulse' | genericLabel }}\n {{ 'engine', 'photon' | genericLabel }}\n {{ 'engine', 'vacuum' | genericLabel }}\n {{ 'engine', 'emdrive' | genericLabel }}\n \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_sensor")}\n
                      \n
                      \n \n \n {{ 'sensor', 'visual' | genericLabel }}\n {{ 'sensor', 'radar' | genericLabel }}\n {{ 'sensor', 'lidar' | genericLabel }}\n {{ 'sensor', 'quantum' | genericLabel }}\n \n
                      \n
                      \n
                      \n
                      \n \n \n
                      \n `);let _=function(e,t){switch(t){case"sensor":switch(e){case"visual":return 1;case"radar":return 1.04;case"lidar":return 1.08;case"quantum":return 1.12}case"weapon":switch(e){case"railgun":return 1;case"laser":return 1.05;case"p_laser":return 1.035;case"plasma":return 1.1;case"phaser":return 1.15;case"disruptor":return 1.2}}};Cs({el:"#tpShipsCostsCalc",data:{i:n,r:c,s:o},methods:{val(e){n[e].val&&n[e].val<0&&(n[e].val=0)},pickGeneric(e,t){if(n[e].val=t,"class"===e){let e=1,a=1,r=1;switch(t){case"corvette":e=1,a=1,r=2;break;case"frigate":e=1.1,a=1.09,r=1.5;break;case"destroyer":e=1.2,a=1.18,r=1.2;break;case"cruiser":e=1.3,a=1.25;break;case"battlecruiser":e=1.35,a=1.3,r=.8;break;case"dreadnought":e=1.4,a=1.35,r=.5;break;case"explorer":e=1.45,a=1,r=5}o.exp1.val=e,o.exp2.val=a,o.creep.val=r}},resetInputs(){n.owned.val=void 0,n.class.val=void 0,n.power.val=void 0,n.weapon.val=void 0,n.armor.val=void 0,n.engine.val=void 0,n.sensor.val=void 0,["Money","Aluminium","Adamantite","Steel","Alloy","Neutronium","Titanium","Copper","Orichalcum","Iridium","Iron","Nano_Tube","Quantium"].forEach((function(e){c[e]={base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1}})),o.exp1.val=void 0,o.exp2.val=void 0,o.creep.val=void 0},importInputs(){if(n.class.val)if(t.space.shipyard&&t.space.shipyard.ships){let e=0;t.space.shipyard.ships.forEach((function(t){t.class===n.class.val&&e++})),n.owned.val=e}else n.owned.val=0}},filters:{finalLabel:(e,t)=>"explorer"===t?z("wiki_calc_tp_ships_costs_final_costs_explorer"):(0!==e&&1!==e&&(e=">1"),t=z(t?`outer_shipyard_class_${t}`:"outer_shipyard_class"),z("wiki_calc_tp_ships_costs_final_costs",[z("wiki_calc_tp_ships_costs_final_costs_owned",[e,t])])),generic:(e,t)=>void 0!==e?e:z("wiki_calc_tp_ships_costs_"+t),genericLabel:(e,t)=>z(t?`outer_shipyard_${e}_${t}`:`outer_shipyard_${e}`),getBase(e,t,a){if(!e)return z("wiki_calc_tp_ships_costs_res_base",[z(`outer_shipyard_${t}`)]);let r=0;switch(t){case"class":switch(e){case"corvette":r="Money"===a?25e5:"Aluminium"===a?5e5:0;break;case"frigate":r="Money"===a?5e6:"Aluminium"===a?125e4:0;break;case"destroyer":r="Money"===a?15e6:"Aluminium"===a?35e5:0;break;case"cruiser":r="Money"===a?5e7:"Aluminium"===a?0:1e6;break;case"battlecruiser":r="Money"===a?125e6:"Aluminium"===a?0:26e5;break;case"dreadnought":r="Money"===a?5e8:"Aluminium"===a?0:8e6;break;case"explorer":r="Money"===a?8e8:"Aluminium"===a?0:95e5}break;case"armor":switch(e){case"steel":r="Steel"===a?35e4:0;break;case"alloy":r="Alloy"===a?25e4:0;break;case"neutronium":r="Neutronium"===a?1e4:0}break;case"engine":switch(e){case"ion":r=75e3;break;case"tie":r=15e4;break;case"pulse":r=125e3;break;case"photon":r=21e4;break;case"vacuum":r=3e5;break;case"emdrive":r=125e4}break;case"power":let t=["dreadnought","explorer"].includes(n.class.val);switch(e){case"solar":case"diesel":r="Iridium"===a?15e3:"Orichalcum"===a&&t||"Copper"===a&&!t?4e4:0;break;case"fission":r="Iridium"===a?3e4:"Orichalcum"===a&&t||"Copper"===a&&!t?5e4:0;break;case"fusion":r="Iridium"===a?4e4:"Orichalcum"===a&&t||"Copper"===a&&!t?5e4:0;break;case"elerium":r="Iridium"===a?55e3:"Orichalcum"===a&&t||"Copper"===a&&!t?6e4:0}break;case"weapon":switch(e){case"railgun":r="Iron"===a?25e3:0;break;case"laser":case"p_laser":r="Nano_Tube"===a?12e3:0;break;case"plasma":r="Nano_Tube"===a?2e4:0;break;case"phaser":r="Quantium"===a?18e3:0;break;case"disruptor":r="Quantium"===a?35e3:0}}return c[a].base=r,r},getExponent:(e,t)=>e?_(e,t):z("wiki_calc_tp_ships_costs_res_exp",[z(`outer_shipyard_${t}`)]),calcPre(e){if(void 0!==c[e].base){let t=0,a=c[e].base;switch(e){case"Money":"explorer"===n.class.val?t=1:n.sensor.val&&(t=_(n.sensor.val,"sensor"));break;case"Steel":case"Alloy":case"Neutronium":case"Copper":case"Orichalcum":case"Iron":case"Nano_Tube":case"Quantium":o.exp1.val&&(t=o.exp1.val);break;case"Titanium":case"Iridium":o.exp2.val&&(t=o.exp2.val)}if(t){if("Iridium"!==e||n.weapon.val)return"Iridium"===e&&(a**=_(n.weapon.val,"weapon")),a**=t,"explorer"===n.class.val&&("Titanium"===e?a*=5:"Iron"===e?a*=10:"Iridium"===e&&(a*=50)),c[e].preVal=+a.toFixed(0),c[e].preVis=!0,c[e].preVal}else if("Aluminium"===e||"Adamantite"===e)return c[e].preVal=a,c[e].preVis=!0,c[e].preVal}c[e].preVal=void 0,c[e].preVis=!1},calcFinal(e){if(c[e].vis=void 0!==c[e].preVal&&void 0!==n.owned.val,c[e].vis){let t=n.owned.val;if("explorer"===n.class.val)c[e].val=+(c[e].preVal*(3*(t+1))).toFixed(0);else{let a=0===t?.75:1===t?.9:1+(t-2)/25*o.creep.val;c[e].val=+(c[e].preVal*a).toFixed(0)}return c[e].val}c[e].val=void 0}}})}(Bn(In(e,{name:"tp_ships_costs",template:"mechanics",label:z("wiki_mechanics_tp_ships_costs"),paragraphs:3,break:[3],h_level:2,para_data:{2:[z("outer_shipyard_class")],3:[z("outer_shipyard_class")]}}),"mechanics","tp_ships_costs",z("wiki_mechanics_tp_ships_costs")));{let t=Dn(In(e,{name:"tp_ships_crew",template:"mechanics",label:z("wiki_mechanics_tp_ships_crew"),paragraphs:1,h_level:2,para_data:{1:[z("outer_shipyard_class")]}}),"mechanics","tp_ships_crew",z("wiki_mechanics_tp_ships_crew"));["corvette","frigate","destroyer","cruiser","battlecruiser","dreadnought","explorer"].forEach((function(e){t.append(`
                      ${z("outer_shipyard_class_"+e)}: ${et({class:e})}`)}))}!function(e){let t=$('
                      ');e.append(t);let a=$("
                      "),r=$("
                      "),i=$("
                      ");t.append(a),t.append(r),t.append(i);let s={class:{val:void 0},power:{val:void 0},weapon:{val:void 0},engine:{val:void 0},sensor:{val:void 0}},n={genMulti:{val:void 0},useMulti:{val:void 0},power:{val:void 0,vis:!1},weapon:{val:void 0,vis:!1},engine:{val:void 0,vis:!1},sensor:{val:void 0,vis:!1},net:{val:void 0,vis:!1,neg:void 0}};a.append(`\n
                      \n
                      \n
                      \n ${z("outer_shipyard_class")}\n
                      \n
                      \n \n \n {{ 'class', 'corvette' | genericLabel }}\n {{ 'class', 'frigate' | genericLabel }}\n {{ 'class', 'destroyer' | genericLabel }}\n {{ 'class', 'cruiser' | genericLabel }}\n {{ 'class', 'battlecruiser' | genericLabel }}\n {{ 'class', 'dreadnought' | genericLabel }}\n {{ 'class', 'explorer' | genericLabel }}\n \n
                      \n
                      \n
                      \n `),r.append(`\n
                      \n
                      \n

                      ${z("wiki_calc_tp_ships_power_gen")}

                      \n
                      \n
                      \n {{ i.power.val, 'power' | genericVal }} * {{ s.genMulti.val, 'gen_multi' | generic }} = {{ | calcPower }}\n
                      \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_power")}\n
                      \n
                      \n \n \n {{ 'power', 'solar' | genericLabel }}\n {{ 'power', 'diesel' | genericLabel }}\n {{ 'power', 'fission' | genericLabel }}\n {{ 'power', 'fusion' | genericLabel }}\n {{ 'power', 'elerium' | genericLabel }}\n \n
                      \n
                      \n
                      \n `),i.append(`\n
                      \n
                      \n

                      ${z("wiki_calc_tp_ships_power_use",[z("outer_shipyard_weapon")])}

                      \n
                      \n
                      \n {{ i.weapon.val, 'weapon' | genericVal }} * {{ s.useMulti.val, 'use_multi' | generic }} = {{ | calcWeapon }}\n
                      \n
                      \n

                      ${z("wiki_calc_tp_ships_power_use",[z("outer_shipyard_engine")])}

                      \n
                      \n
                      \n {{ i.engine.val, 'engine' | genericVal }} * {{ s.useMulti.val, 'use_multi' | generic }} = {{ | calcEngine }}\n
                      \n
                      \n

                      ${z("wiki_calc_tp_ships_power_use",[z("outer_shipyard_sensor")])}

                      \n
                      \n
                      \n {{ i.sensor.val, 'sensor' | genericVal }} * {{ s.useMulti.val, 'use_multi' | generic }} = {{ | calcSensor }}\n
                      \n
                      \n

                      ${z("wiki_calc_tp_ships_power_net")}

                      \n
                      \n
                      \n {{ s.power.val, 'power' | genericResult }} - {{ s.weapon.val, 'weapon' | genericResult }} - {{ s.engine.val, 'engine' | genericResult }} - {{ s.sensor.val, 'sensor' | genericResult }} = {{ | calcNet }} = ${z("wiki_calc_tp_ships_power_net_pos")} = ${z("wiki_calc_tp_ships_power_net_neg")}\n
                      \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_weapon")}\n
                      \n
                      \n \n \n {{ 'weapon', 'railgun' | genericLabel }}\n {{ 'weapon', 'laser' | genericLabel }}\n {{ 'weapon', 'p_laser' | genericLabel }}\n {{ 'weapon', 'plasma' | genericLabel }}\n {{ 'weapon', 'phaser' | genericLabel }}\n {{ 'weapon', 'disruptor' | genericLabel }}\n \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_engine")}\n
                      \n
                      \n \n \n {{ 'engine', 'ion' | genericLabel }}\n {{ 'engine', 'tie' | genericLabel }}\n {{ 'engine', 'pulse' | genericLabel }}\n {{ 'engine', 'photon' | genericLabel }}\n {{ 'engine', 'vacuum' | genericLabel }}\n {{ 'engine', 'emdrive' | genericLabel }}\n \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_sensor")}\n
                      \n
                      \n \n \n {{ 'sensor', 'visual' | genericLabel }}\n {{ 'sensor', 'radar' | genericLabel }}\n {{ 'sensor', 'lidar' | genericLabel }}\n {{ 'sensor', 'quantum' | genericLabel }}\n \n
                      \n
                      \n
                      \n
                      \n \n
                      \n `),Cs({el:"#tpShipsPowerCalc",data:{i:s,s:n},methods:{pickGeneric(e,t){if(s[e].val=t,"class"===e){let e=1,a=1;switch(t){case"frigate":e=1.1,a=1.2;break;case"destroyer":e=1.5,a=1.65;break;case"cruiser":e=2,a=2.5;break;case"battlecruiser":e=2.5,a=3.5;break;case"dreadnought":e=5,a=6.5;break;case"explorer":e=6,a=2}n.genMulti.val=e,n.useMulti.val=a}},resetInputs(){s.class.val=void 0,s.power.val=void 0,s.weapon.val=void 0,s.engine.val=void 0,s.sensor.val=void 0,n.genMulti.val=void 0,n.useMulti.val=void 0,n.power.val=void 0,n.weapon.val=void 0,n.engine.val=void 0,n.sensor.val=void 0,n.net.val=void 0,n.power.vis=!1,n.weapon.vis=!1,n.engine.vis=!1,n.sensor.vis=!1,n.net.vis=!1,n.net.neg=void 0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_tp_ships_power_"+t),genericResult:(e,t)=>void 0!==e?e:"power"===t?z("wiki_calc_tp_ships_power_gen"):z("wiki_calc_tp_ships_power_use",[z(`outer_shipyard_${t}`)]),genericLabel:(e,t)=>z(t?`outer_shipyard_${e}_${t}`:`outer_shipyard_${e}`),genericVal(e,t){if(!e)return z("wiki_calc_tp_ships_power_base",[z(`outer_shipyard_${t}`)]);let a={};return a[t]=e,Math.abs(tt(a,"explorer"===s.class.val))},calcPower(){if(n.power.vis=s.class.val&&s.power.val,n.power.vis)return n.power.val=tt({class:s.class.val,power:s.power.val}),n.power.val},calcWeapon(){if(n.weapon.vis=s.class.val&&s.weapon.val,n.weapon.vis)return n.weapon.val=Math.abs(tt({class:s.class.val,weapon:s.weapon.val})),n.weapon.val},calcEngine(){if(n.engine.vis=s.class.val&&s.engine.val,n.engine.vis)return n.engine.val=Math.abs(tt({class:s.class.val,engine:s.engine.val})),n.engine.val},calcSensor(){if(n.sensor.vis=s.class.val&&s.sensor.val,n.sensor.vis)return n.sensor.val=Math.abs(tt({class:s.class.val,sensor:s.sensor.val})),n.sensor.val},calcNet(){if(n.net.vis=s.class.val&&s.power.val&&s.weapon.val&&s.engine.val&&s.sensor.val,n.net.vis)return n.net.val=tt({class:s.class.val,power:s.power.val,weapon:s.weapon.val,engine:s.engine.val,sensor:s.sensor.val}),n.net.neg=n.net.val<0,n.net.val;n.net.neg=void 0}}})}(Bn(In(e,{name:"tp_ships_power",template:"mechanics",label:z("wiki_mechanics_tp_ships_power"),paragraphs:4,break:[3],h_level:2,para_data:{3:[z("outer_shipyard_power"),z("outer_shipyard_class")],4:[z("outer_shipyard_weapon"),z("outer_shipyard_engine"),z("outer_shipyard_sensor"),z("outer_shipyard_class")]}}),"mechanics","tp_ships_power",z("wiki_mechanics_tp_ships_power"))),function(e){let t=$('
                      ');e.append(t),t.append(`

                      ${z("wiki_mechanics_tp_ships_firepower")}

                      `);let a=$("
                      "),r=$("
                      ");t.append(a),t.append(r);let i={weapon:{val:void 0},class:{val:void 0}},s={result:{vis:!1,val:0}};a.append('\n
                      \n {{ i.weapon.val | weaponVal }} * {{ i.class.val | classVal }} = {{ | calc }}\n
                      \n '),r.append(`\n
                      \n
                      \n
                      \n ${z("outer_shipyard_weapon")}\n
                      \n
                      \n \n \n {{ 'railgun' | weaponLabel }}\n {{ 'laser' | weaponLabel }}\n {{ 'p_laser' | weaponLabel }}\n {{ 'plasma' | weaponLabel }}\n {{ 'phaser' | weaponLabel }}\n {{ 'disruptor' | weaponLabel }}\n \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_class")}\n
                      \n
                      \n \n \n {{ 'corvette' | classLabel }}\n {{ 'frigate' | classLabel }}\n {{ 'destroyer' | classLabel }}\n {{ 'cruiser' | classLabel }}\n {{ 'battlecruiser' | classLabel }}\n {{ 'dreadnought' | classLabel }}\n {{ 'explorer' | classLabel }}\n \n
                      \n
                      \n
                      \n
                      \n \n
                      \n `),Cs({el:"#tpShipsFirepowerCalc",data:{i,s},methods:{pickWeapon(e){i.weapon.val=e},pickClass(e){i.class.val=e},resetInputs(){i.weapon.val=void 0,i.class.val=void 0}},filters:{weaponVal(e){switch(e){case"railgun":return 36;case"laser":return 64;case"p_laser":return 54;case"plasma":return 90;case"phaser":return 114;case"disruptor":return 156;default:return z("wiki_calc_tp_ships_firepower_weapon")}},classVal(e){switch(e){case"corvette":return 1;case"frigate":return 1.5;case"destroyer":return 2.75;case"cruiser":return 5.5;case"battlecruiser":return 10;case"dreadnought":return 22;case"explorer":return 1.2;default:return z("wiki_calc_tp_ships_firepower_class")}},weaponLabel:e=>z(e?"outer_shipyard_weapon_"+e:"outer_shipyard_weapon"),classLabel:e=>z(e?"outer_shipyard_class_"+e:"outer_shipyard_class"),calc(){if(s.result.vis=i.weapon.val&&i.class.val,s.result.vis)return s.result.val=at({weapon:i.weapon.val,class:i.class.val}),s.result.val}}})}(Bn(In(e,{name:"tp_ships_firepower",template:"mechanics",label:z("wiki_mechanics_tp_ships_firepower"),paragraphs:2,break:[3],h_level:2,para_data:{1:[z("firepower"),z("outer_shipyard_class"),z("outer_shipyard_weapon")],2:[z("firepower"),z("outer_shipyard_hull")]}}),"mechanics","tp_ships_firepower",z("wiki_mechanics_tp_ships_firepower"))),function(e){let t=$('
                      ');e.append(t),t.append(`

                      ${z("wiki_calc_tp_ships_hull_damage_range")}

                      `);let a=$("
                      "),r=$("
                      ");t.append(a),t.append(r);let i={hull:{val:void 0},triton:{val:!1}},s={result:{vis:!1,val:void 0}};a.append('\n
                      \n 1 - {{ | calc }}\n
                      \n '),r.append(`\n
                      \n
                      \n
                      \n ${z("outer_shipyard_armor")}\n
                      \n
                      \n \n \n {{ 'steel' | hullLabel }}\n {{ 'alloy' | hullLabel }}\n {{ 'neutronium' | hullLabel }}\n \n
                      \n
                      \n
                      ${Kn("triton")}
                      \n
                      \n
                      \n \n
                      \n `),Cs({el:"#tpShipsHullCalc",data:{i,s},methods:{pickHull(e){i.hull.val=e},resetInputs(){i.hull.val=void 0,i.triton.val=!1}},filters:{hullLabel:e=>z(e?"outer_shipyard_armor_"+e:"outer_shipyard_armor"),calc(){if(s.result.vis=i.hull.val,s.result.vis){let e=0;switch(i.hull.val){case"steel":e=8;break;case"alloy":e=6;break;case"neutronium":e=4}return i.triton.val&&(e*=2),s.result.val=e-1,s.result.val}}}})}(Bn(In(e,{name:"tp_ships_hull",template:"mechanics",label:z("wiki_mechanics_tp_ships_hull"),paragraphs:7,break:[3,6,7],h_level:2,para_data:{1:[z("firepower"),z("outer_shipyard_hull")],2:[z("outer_shipyard_hull"),"90%",z("firepower"),.9],3:[Kn("dwarf"),"1/10",z("outer_shipyard_hull")],4:[z("outer_shipyard_armor")],5:[Kn("triton")],6:["1%",z("outer_shipyard_hull")],7:[z("outer_shipyard_hull"),"10%"]}}),"mechanics","tp_ships_hull",z("wiki_calc_tp_ships_hull_damage_range")));let r=In(e,{name:"tp_ships_sensors",template:"mechanics",label:z("wiki_mechanics_tp_ships_sensors"),paragraphs:2,h_level:2,para_data:{1:[z("space_scan_effectiveness")],2:[z("space_scan_effectiveness"),z("outer_shipyard_sensors"),z("outer_shipyard_class"),z("outer_shipyard_sensor"),Kn("triton"),z("space_fob_title")]}});!function(e){let t=$('
                      ');e.append(t),t.append(`

                      ${z("wiki_calc_tp_ships_scan_ship")}

                      `);let a=$("
                      "),r=$("
                      ");t.append(a),t.append(r);let i={sensor:{val:void 0},class:{val:void 0}},s={result:{vis:!1,val:0}};a.append('\n
                      \n {{ i.sensor.val | sensorVal }} * {{ i.class.val | classVal }} = {{ | calc }}\n
                      \n '),r.append(`\n
                      \n
                      \n
                      \n ${z("outer_shipyard_sensor")}\n
                      \n
                      \n \n \n {{ 'visual' | sensorLabel }}\n {{ 'radar' | sensorLabel }}\n {{ 'lidar' | sensorLabel }}\n {{ 'quantum' | sensorLabel }}\n \n
                      \n
                      \n
                      \n
                      \n ${z("outer_shipyard_class")}\n
                      \n
                      \n \n \n {{ 'corvette' | classLabel }}\n {{ 'frigate' | classLabel }}\n {{ 'destroyer' | classLabel }}\n {{ 'cruiser' | classLabel }}\n {{ 'battlecruiser' | classLabel }}\n {{ 'dreadnought' | classLabel }}\n {{ 'explorer' | classLabel }}\n \n
                      \n
                      \n
                      \n
                      \n \n
                      \n `),Cs({el:"#tpShipsScanCalc",data:{i,s},methods:{pickSensor(e){i.sensor.val=e},pickClass(e){i.class.val=e},resetInputs(){i.sensor.val=void 0,i.class.val=void 0}},filters:{sensorVal(e){switch(e){case"visual":return 1;case"radar":return 10;case"lidar":return 18;case"quantum":return 32;default:return z("wiki_calc_tp_ships_scan_sensor")}},classVal(e){switch(e){case"corvette":case"frigate":return 2;case"destroyer":case"cruiser":return 1.5;case"battlecruiser":case"dreadnought":return 1;case"explorer":return 5;default:return z("wiki_calc_tp_ships_firepower_class")}},sensorLabel:e=>z(e?"outer_shipyard_sensor_"+e:"outer_shipyard_sensor"),classLabel:e=>z(e?"outer_shipyard_class_"+e:"outer_shipyard_class"),calc(){if(s.result.vis=i.sensor.val&&(i.class.val||"visual"===i.sensor.val),s.result.vis)return s.result.val=_t({sensor:i.sensor.val,class:i.class.val}),s.result.val}}})}(Bn(r,"mechanics","tp_ships_scan",z("wiki_calc_tp_ships_scan_ship"))),function(e){let t=$('
                      ');e.append(t);let a=$("
                      "),r=$("
                      ");t.append(a),t.append(r);let i={range:{val:void 0},triton:{val:!1},fob:{val:!1}},s={combined:{vis:!1,val:void 0},adjusted:{vis:!1,val:void 0,adjust:!1},intel:{vis:!1,val:void 0}};a.append(`\n
                      \n

                      ${z("wiki_calc_tp_ships_intel_combined_range")}

                      \n
                      \n
                      \n {{ i.range.val, 'ship_range' | generic }} + 10 = {{ | calcRange }}\n
                      \n
                      \n

                      ${z("wiki_calc_tp_ships_intel_adjusted_range_below",[z("wiki_calc_tp_ships_intel_adjusted_range"),z("wiki_calc_tp_ships_intel_combined_range")])}

                      \n
                      \n
                      \n {{ s.combined.val, 'combined_range' | generic }} = {{ | calcAdjusted }}\n
                      \n
                      \n

                      ${z("wiki_calc_tp_ships_intel_adjusted_range_above",[z("wiki_calc_tp_ships_intel_adjusted_range"),z("wiki_calc_tp_ships_intel_combined_range")])}

                      \n
                      \n
                      \n (({{ s.combined.val, 'combined_range' | generic }} - 100) / (({{ s.combined.val, 'combined_range' | generic }} - 100) + 200) * 100) + 100 = {{ | calcAdjusted }}\n
                      \n
                      \n

                      ${z("space_scan_effectiveness")}

                      \n
                      \n
                      \n ({{ s.adjusted.val, 'adjusted_range' | generic }} + 25) / 1.25 = {{ | calcIntel }}\n
                      \n `),r.append(`\n
                      \n
                      ${z("wiki_calc_tp_ships_intel_ship_range")}
                      \n
                      ${Kn("triton")}
                      \n
                      ${z("space_fob_title")}
                      \n
                      \n
                      \n \n
                      \n `),Cs({el:"#tpShipsIntelCalc",data:{i,s},methods:{val(e){i[e].val&&i[e].val<0&&(i[e].val=0)},resetInputs(){i.range.val=void 0,i.triton.val=!1,i.fob.val=!1}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_tp_ships_intel_"+t),calcRange(){if(s.combined.vis=void 0!==i.range.val,s.combined.vis)return s.combined.val=i.range.val+(i.triton.val&&i.fob.val?10:0),s.combined.val;s.combined.val=void 0},calcAdjusted(){if(s.adjusted.vis=void 0!==s.combined.val,s.adjusted.vis){let e=s.combined.val;return e>100?(e=(e-100)/(e-100+200)*100+100,s.adjusted.adjust=!0):s.adjusted.adjust=!1,s.adjusted.val=e,s.adjusted.val}s.adjusted.val=void 0},calcIntel(){if(s.intel.vis=void 0!==s.adjusted.val,s.intel.vis)return s.intel.val=(s.adjusted.val+25)/1.25,s.intel.val;s.intel.val=void 0}}})}(Bn(r,"mechanics","tp_ships_intel",z("space_scan_effectiveness"))),Ln("add","mechanics-gameplay","tp_ships",z("wiki_mechanics_tp_ships"))}In(a,{name:"seed",template:"mechanics",label:z("wiki_mechanics_seed"),paragraphs:14,break:[3,5,6,7,8,9,10,11,12,13,14],h_level:2,para_data:{4:[z("wiki_faq_q_soft_reset")],7:[z("evo_sentience_title")],8:[z("wiki_menu_combat"),z("trait_revive_name"),z("trait_infectious_name")],9:[z("civics_spy_influence"),z("civics_spy_sabotage"),z("civics_spy_incite")],10:[z("wiki_menu_major"),z("wiki_menu_minor")],11:[z("arpa_gene_mutation"),z("tech_fanaticism"),z("tech_deify"),z("tab_arpa_crispr"),z("wiki_arpa_crispr_evolve")],12:[z("governor")],13:[z("wiki_menu_planets"),z("wiki_resets_bioseed"),z("wiki_resets_blackhole"),z("wiki_resets_vacuum")],14:[z("portal_spire_name")]},data_link:{7:["wiki.html#prehistoric-structures-sentience"],8:["wiki.html#combat-gameplay","wiki.html#traits-species-major_revive","wiki.html#traits-species-major_infectious"],10:["wiki.html#major-events","wiki.html#minor-events"],11:[!1,t.genes.transcendence?"wiki.html#civilized-tech-alt_fanaticism":"wiki.html#civilized-tech-fanaticism","wiki.html#early_space-tech-deify",!1,"wiki.html#crispr-prestige-recombination"],12:["wiki.html#governor-gameplay"],13:["wiki.html#planets-gameplay","wiki.html#resets-prestige-bioseed","wiki.html#resets-prestige-blackhole","wiki.html#resets-prestige-vacuum"],14:["wiki.html#hell-gameplay-spire"]}}),Ln("add","mechanics-gameplay","seed",z("wiki_mechanics_seed"));{let e=Pr(!0),r=Pr(!1,!0),i=t.stats.hasOwnProperty("reset")?t.stats.reset:0,s=Math.floor(i/r.length);if(s>0)switch(s){case 1:e=`${e} ${z("wiki_mechanics_cheese_squared")}`;break;case 2:e=`${e} ${z("wiki_mechanics_cheese_cubed")}`;break;case 3:e=`${e} ${z("wiki_mechanics_cheese_tesseracted")}`;break;case 4:e=`${e} ${z("wiki_mechanics_cheese_penteracted")}`;break;case 5:e=`${e} ${z("wiki_mechanics_cheese_hexeracted")}`;break;case 6:e=`${e} ${z("wiki_mechanics_cheese_hepteracted")}`;break;case 7:e=`${e} ${z("wiki_mechanics_cheese_octeracted")}`;break;case 8:e=`${e} ${z("wiki_mechanics_cheese_enneracted")}`;break;case 9:e=`${e} ${z("wiki_mechanics_cheese_dekeracted")}`;break;default:e=`${e}^${s+1}`}let n=[];for(let e=0;e${z(`cheese_${r[e]}`)} (${e+1})`);In(a,{name:"cheese",template:"mechanics",label:z("wiki_mechanics_cheese"),paragraphs:5,break:[4,5],h_level:2,para_data:{1:[z("tech_swiss_bank",[z("cheese_swiss")])],2:[r.length,z("cheese_swiss")],3:[z("wiki_mechanics_cheese")],4:[z("wiki_mechanics_cheese"),e,i+1],5:[n.join(", ")]},data_color:{4:["warning","danger","caution"],5:[!1]}}),Ln("add","mechanics-gameplay","cheese",z("wiki_mechanics_cheese"))}{let e=In(a,{name:"thralls",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:9,break:[4,8],h_level:2,para_data:{1:[z("trait_unfathomable_name")],5:[100,100],8:[1]},data_link:{1:["wiki.html#traits-species-genus_unfathomable"]}});In(e,{name:"thralls_cath",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_cath"),3]}}),In(e,{name:"thralls_pterodacti",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_pterodacti"),3]}}),In(e,{name:"thralls_entish",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_entish"),"40%"]}}),In(e,{name:"thralls_cacti",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_cacti"),"32%"]}}),In(e,{name:"thralls_moldling",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:3,break:[3],h_level:!1,para_data:{1:[z("race_moldling")],2:[[`${z("tech_smelting")}`,`${z("tech_dynamite")}`,`${z("tech_portland_cement")}`,`${z("tech_oxygen_converter")}`,`${z("tech_machinery")}`,`${z("tech_uranium_storage")}`,`${Mr.tech.synthetic_fur.title()}`,`${z("tech_rover")}`,`${z("tech_starcharts")}`,`${z("tech_nano_tubes")}`,`${z("tech_stanene")}`,`${z("tech_hydroponics")}`,`${z("tech_orichalcum_panels")}`,`${z("tech_cybernetics")}`].join(", ")]},data_color:{2:[!1]}}),In(e,{name:"thralls_sharkin",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_sharkin")]}}),In(e,{name:"thralls_satyr",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_satyr")]}}),In(e,{name:"thralls_phoenix",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_phoenix"),"0.25"]}}),In(e,{name:"thralls_salamander",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_salamander"),"20%"]}}),In(e,{name:"thralls_unicorn",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_unicorn"),1]}}),Ln("add","mechanics-gameplay","thralls",z("wiki_mechanics_thralls"))}}(a);break;case"government":!function(e){let t=Ln("create",e);In(t,{name:"info",template:"government",label:z("tab_gov"),paragraphs:8,break:[3,6],h_level:2,para_data:{2:[z("govern_anarchy")],3:[z("civics_revolution")],4:[z("civics_revolution")],5:[1e3]},data_color:{2:["caution"]}}),Ln("add","government-gameplay","info",z("tab_gov"));let a={anarchy:{paragraphs:5,break:[2,5],para_data:{2:[10],3:["10th","0.25%","1/2"]}},autocracy:{paragraphs:4,break:[2,4],para_data:{2:["35%","25%"],3:["18%",z("tech_electricity"),"10%",z("tech_virtual_reality")]},para_color:{}},democracy:{paragraphs:6,break:[2,5],para_data:{2:[z("job_entertainer"),"20%"],3:[z("job_entertainer")],4:["25%",z("tech_electricity"),"30%",z("tech_virtual_reality")],5:["5%"],6:[z("job_farmer"),z("job_lumberjack"),z("job_quarry_worker"),z("job_miner"),z("job_crystal_miner"),z("job_coal_miner"),z("job_cement_worker"),z("job_professor"),z("job_scientist"),z("soldiers")]}},oligarchy:{paragraphs:5,break:[2,4,5],text:{1:"govern_oligarchy_desc",2:"govern_oligarchy_effect"},para_data:{2:[5,20],3:["2%",z("tech_electricity"),z("tech_virtual_reality")],4:["45%"],5:["0.5%","20%"]}},theocracy:{paragraphs:7,break:[2,6,7],para_data:{2:["12%"],3:["25%"],4:["50%"],6:["40%",z("tech_virtual_reality"),"25%",z("tech_metaphysics")]}},republic:{paragraphs:7,break:[2,5,6],para_data:{2:["25%"],3:["20%"],5:["30%",z("tech_virtual_reality"),"40%",z("tech_metaphysics")],6:["30%"],7:[30,90]},para_color:{}},socialist:{paragraphs:6,break:[2,6],para_data:{2:["35%"],3:["10%"],4:["10%"],5:["20%"],6:["42%",z("tech_virtual_reality"),"50%",z("tech_metaphysics")]}},corpocracy:{paragraphs:9,break:[2,8,9],para_data:{2:["50%"],3:["200%"],4:["150%"],5:["100%"],6:["10%"],7:["30%"],8:["5%",z("tech_virtual_reality")],9:["40%",z("tech_metaphysics")]}},technocracy:{paragraphs:5,break:[2,4],para_data:{2:["8%"],3:["10%"],4:["2%"],5:["1%",z("tech_virtual_reality"),z("tech_metaphysics")]}},federation:{paragraphs:7,break:[2,5,6],para_data:{2:["3%"],4:["25%"],5:["10%"],6:["25%","32%"],7:["36%",z("tech_virtual_reality"),"40%",z("tech_metaphysics")]}},magocracy:{paragraphs:5,break:[2,3,5],para_data:{2:["25%"],3:["25%"],4:["40%",z("tech_virtual_reality"),"50%",z("tech_metaphysics")]}}};Object.keys(a).forEach((function(e){In(t,{name:e,template:"government",label:z(`govern_${e}`),paragraphs:a[e].paragraphs,break:a[e].break,h_level:2,text:a[e].hasOwnProperty("text")?a[e].text:{1:`govern_${e}_desc`},para_data:a[e].hasOwnProperty("para_data")?a[e].para_data:{},para_color:a[e].hasOwnProperty("para_color")?a[e].para_color:{}}),Ln("add","government-gameplay",e,z(`govern_${e}`))}))}(a);break;case"governor":!function(e){let t=Ln("create",e);{let e=In(t,{name:"intro",template:"governor",label:z("governor"),paragraphs:4,h_level:2,para_data:{1:[z("arpa_genepool_governance_title")],2:[Object.keys(F).length]},data_link:{1:["wiki.html#crispr-prestige-governance"]}});Ln("add","governor-gameplay","intro",z("governor")),Object.keys(F).forEach((function(t){let a="";Object.keys(F[t].traits).forEach((function(e){a+=(A[e].hasOwnProperty("effect")?A[e].effect():"")+" "})),In(e,{name:t,template:"government",label:z(`governor_${t}`),paragraphs:2,break:[2],h_level:3,text:{1:`governor_${t}_desc`},rawtext:{2:a}}),Ln("add","governor-gameplay",t,z(`governor_${t}`))}))}{let e=In(t,{name:"task",template:"governor",paragraphs:2,h_level:2,para_data:{2:[3,z("governor_bureaucrat"),4],3:[Object.keys(B).length]}});Ln("add","governor-gameplay","task",z("wiki_governor_task"));{let t="tax";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:3,break:[3],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:"wiki_governor_task_unlock"},para_data:{3:[z("tech_tax_rates")]},data_link:{3:["wiki.html#civilized-tech-tax_rates"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="storage";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:3,break:[3],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:"wiki_governor_task_unlock"},para_data:{3:[z("tech_containerization")]},data_link:{3:["wiki.html#civilized-tech-containerization"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="bal_storage";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:4,break:[4],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:"wiki_governor_task_unlock"},para_data:{4:[z("tech_containerization")]},data_link:{4:["wiki.html#civilized-tech-containerization"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="merc";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:4,break:[4],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:"wiki_governor_task_unlock"},para_data:{4:[z("tech_mercs")]},data_link:{4:["wiki.html#civilized-tech-mercs"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="spy";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:3,break:[2,3],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:"wiki_governor_task_unlock",3:"wiki_governor_task_disabled"},para_data:{2:[z("tech_spy")],3:[z("tech_unification")]},data_link:{2:["wiki.html#civilized-tech-spy"],3:["wiki.html#early_space-tech-unification2"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="spyop";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:8,break:[2,3,4,5,6,7,8],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:`wiki_governor_task_${t}3`,5:`wiki_governor_task_${t}4`,6:`wiki_governor_task_${t}5`,7:"wiki_governor_task_unlock",8:"wiki_governor_task_disabled"},para_data:{2:[1,z("civics_spy_sabotage")],3:[2,z("civics_spy_influence")],4:[3,z("civics_spy_incite")],6:[z("civics_spy_sabotage"),z("civics_spy_incite"),z("civics_spy_influence")],7:[z("tech_espionage")],8:[z("tech_unification")]},data_link:{6:["wiki.html#civilized-tech-spy"],7:["wiki.html#early_space-tech-unification2"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="slave";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:2,break:[2],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:"wiki_governor_task_trait"},para_data:{2:[z("trait_slaver_name")]},data_link:{2:["wiki.html#traits-species-major_slaver"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="sacrifice";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:2,break:[2],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:"wiki_governor_task_trait"},para_data:{2:[z("trait_cannibalize_name")]},data_link:{2:["wiki.html#traits-species-major_cannibalize"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="horseshoe";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:2,break:[2],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:"wiki_governor_task_trait"},para_data:{1:[z(`city_${hn(!0)}`,[hn(!1)]),hn(!1)],2:[rs(!1)]},data_link:{2:["wiki.html#traits-species-major_hooved"]}}),Ln("add","governor-gameplay",t,z(`city_${hn(!0)}`,[hn(!1)]))}{let t="trash";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:7,break:[3,5,7],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:`wiki_governor_task_${t}3min`,5:`wiki_governor_task_${t}3a`,6:`wiki_governor_task_${t}3max`,7:`wiki_governor_task_${t}4`},para_data:{7:[z("interstellar_mass_ejector")]},data_link:{7:["wiki.html#interstellar-structures-mass_ejector"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="mech";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:4,break:[4],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:`wiki_governor_task_${t}4`},para_data:{4:[1,z("wiki_resets_infusion"),z("portal_spire_name")]},data_link:{4:[!1,"wiki.html#resets-prestige-infusion","wiki.html#hell-structures-spire"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}}}(a);break;case"combat":!function(e){let t=Ln("create",e);In(t,{name:"basics",template:"combat",label:z("wiki_combat_basics"),paragraphs:4,h_level:2}),Ln("add","combat-gameplay","basics",z("wiki_combat_basics")),In(t,{name:"campaign",template:"combat",label:z("wiki_combat_campaign"),paragraphs:14,break:[5,11],h_level:2,para_data:{1:[5,z("civics_garrison_tactic_ambush"),z("civics_garrison_tactic_raid"),z("civics_garrison_tactic_pillage"),z("civics_garrison_tactic_assault"),z("civics_garrison_tactic_siege")],3:[z("civics_garrison_tactic_ambush")],4:[z("civics_garrison_tactic_siege"),20],11:["0%","50%"],12:[50],13:["50%","100%"],14:["50%"]}}),Ln("add","combat-gameplay","campaign",z("wiki_combat_campaign")),In(t,{name:"loot",template:"combat",label:z("wiki_combat_loot"),paragraphs:30,break:[3,5,10,13,16,19,22,26,27,28,29,30],h_level:2,para_data:{2:[3,z("civics_garrison_campaign"),z("civics_gov_eco_rate"),z("civics_garrison_battalion")],3:[z("civics_garrison_campaign")],4:[4,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],5:[z("wiki_combat_loot_basic"),z("resource_Food_name"),z("resource_Lumber_name"),z("resource_Stone_name")],6:[z("wiki_combat_loot_common"),z("resource_Copper_name"),z("resource_Iron_name"),z("resource_Aluminium_name"),z("resource_Coal_name")],7:[z("wiki_combat_loot_rare"),z("resource_Cement_name"),z("resource_Steel_name")],8:[z("wiki_universe_magic"),z("wiki_combat_loot_rare"),z("resource_Crystal_name"),z("trait_terrifying_name"),z("resource_Titanium_name")],9:[z("wiki_combat_loot_money")],10:[z("civics_garrison_tactic_ambush"),3,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common")],11:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common")],12:[5],13:[z("civics_garrison_tactic_raid"),4,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],14:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],15:[10],16:[z("civics_garrison_tactic_pillage"),5,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],17:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],18:[25],19:[z("civics_garrison_tactic_assault"),5,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],20:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],21:[50],22:[z("civics_garrison_tactic_siege"),5,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],23:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],24:[z("civics_garrison_tactic_siege")],25:[999],28:["base loot * log(looters + 1)"],29:[z("civics_gov_eco_rate")],30:["floor(loot * economic rating / 100)"]},data_color:{5:["warning","caution","caution","caution"],6:["warning","caution","caution","caution","caution"],7:["warning","caution","caution"],8:["warning","warning","caution","warning","caution"],10:["warning","warning","caution","caution","caution"],11:["warning","caution","caution","caution"],13:["warning","warning","caution","caution","caution","caution"],14:["warning","caution","caution","caution","caution"],16:["warning","warning","caution","caution","caution","caution"],17:["warning","caution","caution","caution","caution"],19:["warning","warning","caution","caution","caution","caution"],20:["warning","caution","caution","caution","caution"],22:["warning","warning","caution","caution","caution","caution"],23:["warning","caution","caution","caution","caution"],28:["advanced"],30:["advanced"]}}),Ln("add","combat-gameplay","loot",z("wiki_combat_loot"))}(a);break;case"challenges":!function(e){let a=Ln("create",e);In(a,{name:"intro",template:"challenges",paragraphs:3,h_level:2,para_data:{2:[z("arpa_genepool_hardened_genes_title"),z("evo_bunker")],3:[z("evo_challenge_genes"),z("evo_challenge_run"),z("evo_scenario")]},data_link:{2:["wiki.html#crispr-prestige-hardened_genes"]}}),Ln("add","challenges-gameplay","intro",z("wiki_menu_intro"));{let e=In(a,{name:"genes_intro",template:"challenges",paragraphs:5,break:[4],h_level:2,para_data:{1:[z("evo_challenge_genes")],2:[z("mastery")],3:[z("mastery")],5:[z("evo_challenge_genes")]},data_link:{1:["wiki.html#mechanics-gameplay-challenge"],2:["wiki.html#mechanics-gameplay-mastery"],3:["wiki.html#mechanics-gameplay-mastery"]}});Ln("add","challenges-gameplay","genes_intro",z("wiki_challenges_genes_intro")),In(e,{name:"genes_plasmid",template:"challenges",paragraphs:4,break:[4],h_level:2,para_data:{1:[z("evo_challenge_plasmid"),z("wiki_challenges_gene"),z("resource_Plasmid_plural_name")],2:[z("city_temple"),z("resource_Plasmid_plural_name"),z("faith")],3:[z("resource_Plasmid_plural_name")],4:[z("wiki_challenges_gene"),z("universe_antimatter")]},data_link:{1:[!1,!1,"wiki.html#resources-prestige-plasmids"],2:["wiki.html#planetary-structures-temple"],4:[!1,"wiki.html#universes-gameplay-antimatter"]}}),En("add","challenges-gameplay","genes_plasmid",z("wiki_challenges_genes_plasmid")),In(e,{name:"genes_mastery",template:"challenges",paragraphs:2,break:[2],h_level:2,para_data:{1:[z("evo_challenge_mastery"),z("wiki_challenges_gene"),z("mastery"),"1/5","1/10"],2:[z("wiki_challenges_gene"),z("universe_antimatter")]},data_link:{1:[!1,!1,"wiki.html#mechanics-gameplay-mastery"],2:[!1,"wiki.html#universes-gameplay-antimatter"]}}),En("add","challenges-gameplay","genes_mastery",z("wiki_challenges_genes_mastery")),In(e,{name:"genes_trade",template:"challenges",paragraphs:2,h_level:2,para_data:{1:[z("evo_challenge_trade"),z("wiki_challenges_gene"),z("resource_market_buy"),z("resource_market_sell")],2:[z("resource_market_trade_routes")]}}),En("add","challenges-gameplay","genes_trade",z("wiki_challenges_genes_trade")),In(e,{name:"genes_craft",template:"challenges",paragraphs:2,h_level:2,para_data:{1:[z("evo_challenge_craft"),z("wiki_challenges_gene")],2:[z("job_craftsman")]}}),En("add","challenges-gameplay","genes_craft",z("wiki_challenges_genes_craft"));{let t=In(e,{name:"genes_crispr",template:"challenges",paragraphs:2,h_level:2,para_data:{1:[z("evo_challenge_crispr"),z("wiki_challenges_gene"),z("tab_arpa_crispr"),z("wiki_arpa_crispr_creep"),"1/5"]},data_link:{1:[!1,!1,!1,"wiki.html#crispr-prestige-genetic_memory"]}});t.find("div.para").append(`${z("wiki_challenges_genes_bad_para2")}`);let a=$(`\n
                      \n ${z("wiki_challenges_genes_crispr_para3")}\n
                      \n `);t.append(a);let r=!1;Ii.forEach((function(e){a.append(`${r?", ":""}${z("trait_"+e+"_name")}`),r=!0})),En("add","challenges-gameplay","genes_crispr",z("wiki_challenges_genes_crispr"))}In(e,{name:"genes_bad",template:"challenges",paragraphs:4,break:[3,4],h_level:2,para_data:{1:[1,2],4:[z("wiki_challenges_gene"),z("evo_challenge_truepath")]},data_link:{4:[!1,"wiki.html#challenges-gameplay-scenarios_truepath"]}}),En("add","challenges-gameplay","genes_bad",z("wiki_challenges_genes_bad"));{let a="antimatter"===t.race.universe?["20%","50%","50%","33%"]:["50%","20%","50%","33%"];In(e,{name:"genes_weak",template:"challenges",paragraphs:5,break:[2,3,4,5],h_level:2,para_data:{1:[a[0]],2:[a[1]],3:[a[2]],4:[a[3]],5:[z("wiki_challenges_gene"),z("evo_challenge_truepath")]},data_link:{5:[!1,"wiki.html#challenges-gameplay-scenarios_truepath"]}}),En("add","challenges-gameplay","genes_weak",z("wiki_challenges_genes_weak"))}}{let e=In(a,{name:"modes_intro",template:"challenges",paragraphs:2,h_level:2,para_data:{1:[z("evo_challenge_run"),z("evo_challenge_genes")],2:[z("wiki_challenges_mode")]}});Ln("add","challenges-gameplay","modes_intro",z("wiki_challenges_modes_intro")),mc(In(e,{name:"modes_joyless",template:"challenges",paragraphs:4,break:[3,4],h_level:2,para_data:{1:[z("evo_challenge_joyless"),z("wiki_challenges_mode"),z("tech_theatre")],2:[z("job_entertainer"),z("morale_broadcast"),_i(),z("morale")],3:[z("wiki_challenges_mode"),Mr.space.spc_red.biodome.title(),z("tech_theatre")],4:[z("wiki_challenges_scenarios_cataclysm"),z("wiki_challenges_scenario")]},data_link:{1:[!1,!1,"wiki.html#civilized-tech-theatre"],2:[!1,!1,"wiki.html#planetary-structures-wardenclyffe"],3:[!1,"wiki.html#space-structures-biodome","wiki.html#civilized-tech-theatre"],4:["wiki.html#challenges-gameplay-scenarios_cataclysm"]}}),!1,["joyless"]),En("add","challenges-gameplay","modes_joyless",z("wiki_challenges_modes_joyless"));{let t=In(e,{name:"modes_steelen",template:"challenges",paragraphs:4,break:[4],h_level:2,para_data:{1:[z("evo_challenge_steelen"),z("wiki_challenges_mode"),z("resource_Steel_name")+" "+z("modal_smelting"),z("resource_Steel_name")],2:[z("resource_Steel_name")],3:[z("tech_steel"),z("tech_bessemer_process"),z("tech_oxygen_converter"),z("tech_electric_arc_furnace")],4:[z("wiki_challenges_mode"),z("wiki_resets_bioseed")]},data_link:{3:["wiki.html#civilized-tech-steel","wiki.html#discovery-tech-bessemer_process","wiki.html#industrialized-tech-oxygen_converter","wiki.html#globalized-tech-electric_arc_furnace"],4:[!1,"wiki.html#resets-prestige-bioseed"]}});mc(t,!1,["steelen"]),mc(t,!0,["steelem"]),En("add","challenges-gameplay","modes_steelen",z("wiki_challenges_modes_steelen"))}{let a=In(e,{name:"modes_decay",template:"challenges",paragraphs:6,break:[4,6],h_level:2,para_data:{1:[z("evo_challenge_decay"),z("wiki_challenges_mode")],2:[z("resource_Money_name"),z("wiki_calc_citizens"),z("resource_Knowledge_name"),z("resource_Zen_name"),z("resource_Crates_plural"),z("resource_Containers_plural")],3:[50],4:["0/s"],6:[z("wiki_challenges_mode"),z("wiki_resets_blackhole"),z("wiki_resets_vacuum")]},data_link:{6:[!1,"wiki.html#resets-prestige-blackhole","wiki.html#resets-prestige-vacuum"]}});mc(a,!1,["dissipated"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_blackhole"),color:!!t.stats.achieve.whitehole,link:"wiki.html#resets-prestige-blackhole"}]}]),function(e){let t=$('
                      ');e.append(t);let a=$("
                      "),r=$("
                      ");t.append(a),t.append(r);let i={resource:{val:void 0},amount:{val:void 0}},s={result:{vis:!1,val:void 0}};a.append(`\n
                      \n

                      ${z("wiki_calc_decay_rate")}

                      \n
                      \n
                      \n {{ i.resource.val | base }} * 0.001 * ({{ i.amount.val, 'amount' | generic }} - 50) = {{ | calc }}\n
                      \n `);let n=$("
                      ");r.append(n);let c=`\n
                      ${z("wiki_calc_decay_resource")} \n \n `;Object.keys(za).forEach((function(e){c+=`\n {{ '${e}' | resLabel }}\n `})),c+="
                      ",n.append(c),n.append(`\n
                      ${z("wiki_calc_decay_amount")}
                      \n `),r.append(`\n
                      \n \n
                      \n `),Cs({el:"#decayCalc",data:{i,s},methods:{val(e){i[e].val&&i[e].val<0&&(i[e].val=0)},pickRes(e){i.resource.val=e},resetInputs(){i.resource.val=void 0,i.amount.val=void 0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_decay_"+t),base:e=>e?za[e]:z("wiki_calc_decay_base"),resLabel:e=>z(e?`resource_${e}_name`:"wiki_calc_decay_resource"),calc(){if(s.result.vis=void 0!==i.resource.val&&void 0!==i.amount.val&&i.amount.val>=50,s.result.vis)return s.result.val=.001*za[i.resource.val]*(i.amount.val-50),s.result.val}}})}(Bn(a,"challenges","decay",z("evo_challenge_decay"))),En("add","challenges-gameplay","modes_decay",z("wiki_challenges_modes_decay"))}{let a=In(e,{name:"modes_emfield",template:"challenges",paragraphs:5,break:[5],h_level:2,para_data:{1:[z("evo_challenge_emfield"),z("wiki_challenges_mode"),"50%",z("evo_challenge_discharge"),"50%"],2:[z("evo_challenge_discharge"),"-50%"],3:[z("city_cement_plant"),z("evo_challenge_discharge"),"50%"],4:[z("space_belt_elerium_ship_title"),z("evo_challenge_discharge"),"-25%"],5:[z("wiki_challenges_mode"),z("wiki_resets_ascension")]},data_link:{3:["wiki.html#planetary-structures-cement_plant"],4:["wiki.html#space-structures-elerium_ship"],5:[!1,"wiki.html#resets-prestige-ascension"]}});mc(a,!1,["technophobe"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"}]}]),En("add","challenges-gameplay","modes_emfield",z("wiki_challenges_modes_emfield"))}{let a=In(e,{name:"modes_inflation",template:"challenges",paragraphs:11,break:[4,9,10],h_level:2,para_data:{1:[z("evo_challenge_inflation"),z("wiki_challenges_mode"),z("resource_Money_name")],2:[1,10],3:[z("space_dwarf_collider_title"),z("interstellar_stellar_engine"),1],5:[z("resource_Money_name"),"+1.33%"],6:[z("modal_factory_lux"),"+0.08%",z("resource_Money_name")],7:[z("city_casino"),"+0.08%","+1%",z("resource_Money_name")],8:[z("wiki_mechanics_bank_vault"),"+0.8%",z("resource_Money_name")],9:[z("interstellar_exchange_title"),"2x",z("resource_Money_name"),z("evo_challenge_inflation")],10:[z("wiki_challenges_mode"),z("wiki_challenges_modes_inflation_para10_note1")],11:[z("evo_challenge_inflation")]},data_link:{3:["wiki.html#space-structures-world_collider","wiki.html#interstellar-structures-stellar_engine"],7:["wiki.html#planetary-structures-casino"],8:["wiki.html#mechanics-gameplay-bank_vault"],9:["wiki.html#interstellar-structures-exchange"]}});mc(a,!1,["wheelbarrow"]),gc(a,[{text:"wiki_challenges_reqs_achieve",subreqs:[{text:z("achieve_scrooge_name"),color:!!t.stats.achieve.scrooge}]}]),function(e){let a=$('
                      ');e.append(a);let r=$("
                      "),i=$("
                      ");a.append(r),a.append(i);let s={inflation:{val:void 0}},n={result:{vis:!1,cost:void 0,luxury:void 0,casino_prod:void 0,casino_store:void 0,bank_vault:void 0}};r.append(`\n
                      \n

                      ${z("wiki_calc_inflation_cost")}

                      \n
                      \n
                      \n {{ i.inflation.val, 'inflation' | generic }} / 75 = {{ 'cost' | calc }} = +{{ 'cost', true | calc }}%\n
                      \n
                      \n

                      ${z("wiki_calc_inflation_luxury")}

                      \n
                      \n
                      \n {{ i.inflation.val, 'inflation' | generic }} / 1250 = {{ 'luxury' | calc }} = +{{ 'luxury', true | calc }}%\n
                      \n
                      \n

                      ${z("wiki_calc_inflation_casino_prod")}

                      \n
                      \n
                      \n {{ i.inflation.val, 'inflation' | generic }} / 1250 = {{ 'casino_prod' | calc }} = +{{ 'casino_prod', true | calc }}%\n
                      \n
                      \n

                      ${z("wiki_calc_inflation_casino_store")}

                      \n
                      \n
                      \n {{ i.inflation.val, 'inflation' | generic }} / 100 = {{ 'casino_store' | calc }} = +{{ 'casino_store', true | calc }}%\n
                      \n
                      \n

                      ${z("wiki_calc_inflation_bank_vault")}

                      \n
                      \n
                      \n {{ i.inflation.val, 'inflation' | generic }} / 125 = {{ 'bank_vault' | calc }} = +{{ 'bank_vault', true | calc }}%\n
                      \n `),i.append(`\n
                      \n
                      ${z("wiki_calc_inflation")}
                      \n
                      \n
                      \n \n \n
                      \n `),Cs({el:"#inflationCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.inflation.val=void 0},importInputs(){s.inflation.val=t.race.inflation||0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_"+t),calc:(e,t)=>t?(100*n.result[e]).toFixed(3):("cost"===e&&(n.result.vis=void 0!==s.inflation.val,n.result.vis&&(n.result.cost=(s.inflation.val/75).toFixed(5),n.result.luxury=(s.inflation.val/1250).toFixed(5),n.result.casino_prod=(s.inflation.val/1250).toFixed(5),n.result.casino_store=(s.inflation.val/100).toFixed(5),n.result.bank_vault=(s.inflation.val/125).toFixed(5))),n.result[e])}})}(Bn(a,"challenges","inflation",z("evo_challenge_inflation"))),En("add","challenges-gameplay","modes_inflation",z("wiki_challenges_modes_inflation"))}{let a=In(e,{name:"modes_sludge",template:"challenges",paragraphs:7,break:[3,4,5,6,7],h_level:2,para_data:{1:[z("evo_challenge_sludge"),z("wiki_challenges_challenge"),z("race_sludge")],3:[z("race_sludge"),"10x",z("trait_ooze_name")],4:[z("evo_challenge_sludge")],5:[z("race_sludge"),z("wiki_resets_mad")],6:[z("race_sludge"),z("wiki_resets_cataclysm")],7:[z("wiki_challenges_scenarios_junker")]},data_link:{1:[!1,!1,"wiki.html#races-species-sludge"],3:[!1,!1,"wiki.html#traits-species-major_ooze"],5:[!1,"wiki.html#resets-prestige-mad"]}});mc(a,!1,["extinct_sludge","gross"],{gross:!0}),mc(a,!0,["slime_lord"]),gc(a,[{text:"wiki_challenges_reqs_achieve",subreqs:[{text:z("achieve_extinct_junker_name"),color:!!t.stats.achieve.extinct_junker}]},{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"},{text:z("wiki_resets_infusion"),color:!!t.stats.achieve.corrupted,link:"wiki.html#resets-prestige-infusion"}]}]),En("add","challenges-gameplay","modes_sludge",z("wiki_challenges_modes_sludge"))}{let a=In(e,{name:"modes_orbitdecay",template:"challenges",paragraphs:14,break:[5,8,9,10,11,12,13,14],h_level:2,para_data:{1:[z("evo_challenge_orbit_decay")],2:[5e3],5:[z("evo_challenge_orbit_decay")],6:[z("tech_era_intergalactic")],11:[z("space_moon_base_title"),2500],12:[z("space_red_spaceport_title"),z("space_belt_station_title"),1e3],13:[z("interstellar_alpha_starport_title"),100],14:[z("wiki_challenges_scenarios_cataclysm")]}});mc(a,!1,["lamentis"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_blackhole"),color:!!t.stats.achieve.whitehole,link:"wiki.html#resets-prestige-blackhole"},{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"}]}]),En("add","challenges-gameplay","modes_orbitdecay",z("wiki_challenges_modes_orbitdecay"))}{let a=In(e,{name:"modes_witchhunter",template:"challenges",paragraphs:7,break:[4],h_level:2,para_data:{1:[z("evo_challenge_witch_hunter")],4:["300%","150%","75%"],7:[100]}});mc(a,!1,["soul_sponge","nightmare"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:`${z("wiki_universe_magic")} ${z("wiki_resets_ascension")}`,color:!(!t.stats.achieve.ascended||!t.stats.achieve.ascended.mg),link:"wiki.html#resets-prestige-ascension"}]}]),En("add","challenges-gameplay","modes_witchhunter",z("wiki_challenges_modes_witchhunter"))}}{let e=In(a,{name:"scenarios_intro",template:"challenges",paragraphs:3,h_level:2,para_data:{1:[z("evo_scenario")],2:[z("evo_challenge_genes"),z("evo_challenge_run")],3:[z("evo_challenge_genes"),z("evo_challenge_run"),z("wiki_challenges_scenario")]}});Ln("add","challenges-gameplay","scenarios_intro",z("wiki_challenges_scenarios_intro"));{let t=In(e,{name:"scenarios_junker",template:"challenges",paragraphs:4,break:[3,4],h_level:2,para_data:{1:[z("evo_challenge_junker"),z("wiki_challenges_scenario"),z("race_junker")],3:[z("wiki_challenges_scenario"),z("wiki_resets_mad")],4:[z("wiki_challenges_modes_sludge")]},data_link:{1:[!1,!1,"wiki.html#races-species-junker"],3:[!1,"wiki.html#resets-prestige-mad"]}});mc(t,!1,["extinct_junker"]),mc(t,!0,["organ_harvester","the_misery","garbage_pie"]),En("add","challenges-gameplay","scenarios_junker",z("wiki_challenges_scenarios_junker"))}{let a=In(e,{name:"scenarios_cataclysm",template:"challenges",paragraphs:9,break:[4,5,6,8,9],h_level:2,para_data:{1:[z("evo_challenge_cataclysm"),z("wiki_challenges_scenario"),z("wiki_resets_cataclysm")],2:[z("evo_challenge_cataclysm"),z("city_casino"),Kn("hell")],4:[z("evo_challenge_cataclysm")],5:[z("civics_foreign"),z("tech_unification")],7:[z("trait_parasite_name"),"20x"],8:[z("resource_Plasmid_plural_name"),z("resource_AntiPlasmid_plural_name"),300,z("wiki_challenges_scenario"),z("resource_Phage_name")],9:[z("wiki_challenges_scenario"),z("wiki_resets_bioseed")]},data_link:{1:[!1,!1,"wiki.html#resets-prestige-cataclysm"],2:[!1,"wiki.html#space-structures-spc_casino"],5:[!1,"wiki.html#early_space-tech-unification2"],7:["wiki.html#traits-species-major_parasite"],8:["wiki.html#resources-prestige-plasmids","wiki.html#resources-prestige-antiplasmids",!1,!1,"wiki.html#resources-prestige-phage"],9:[!1,"wiki.html#resets-prestige-bioseed"]}});mc(a,!1,["iron_will","failed_history"]),mc(a,!0,["finish_line"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_cataclysm"),color:!!t.stats.achieve.shaken,link:"wiki.html#resets-prestige-cataclysm"}]}]),En("add","challenges-gameplay","scenarios_cataclysm",z("wiki_challenges_scenarios_cataclysm"))}{let a=In(e,{name:"scenarios_banana",template:"challenges",paragraphs:18,break:[2,4,5,8,9,10,18],h_level:2,para_data:{1:[z("evo_challenge_banana"),z("wiki_challenges_scenario"),z("resource_Money_name"),z("morale_tax")],2:[z("tech_unification"),z("evo_challenge_banana")],3:[z("tech_unification"),z("restore")],4:[z("morale_tax"),"95%",z("civics_tax_rates"),z("wiki_challenges_scenarios_banana_para4_note1")],5:[z("tab_market"),z("tech_sundial"),z("evo_challenge_banana"),1,z("resource_Food_name"),z("tech_trade")],6:[z("resource_market_trade_routes")],7:[z("resource_market_trade_routes"),10,25,z("tech_large_trades"),1e6,z("tech_massive_trades")],8:[z("civics_foreign"),"2x","50%"],9:[z("civics_garrison_soldiers"),"20%",z("tab_portal")],10:[z("galaxy_scout_ship"),7,10],11:[z("galaxy_corvette_ship"),21,30],12:[z("galaxy_frigate_ship"),56,80],13:[z("galaxy_cruiser_ship"),175,250],14:[z("galaxy_dreadnought"),1260,1800],15:[z("galaxy_armed_miner"),4,5],16:[z("galaxy_minelayer"),35,50],17:[z("galaxy_raider"),9,12],18:[z("wiki_challenges_scenario"),z("achieve_banana_name")]},data_link:{2:["wiki.html#early_space-tech-unification2"],3:["wiki.html#early_space-tech-unification2"],5:[!1,"wiki.html#primitive-tech-sundial",!1,!1,!1,"wiki.html#civilized-tech-trade"],7:[!1,!1,!1,"wiki.html#civilized-tech-large_trades",!1,"wiki.html#globalized-tech-massive_trades"],10:["wiki.html#intergalactic-structures-scout_ship"],11:["wiki.html#intergalactic-structures-corvette_ship"],12:["wiki.html#intergalactic-structures-frigate_ship"],13:["wiki.html#intergalactic-structures-cruiser_ship"],14:["wiki.html#intergalactic-structures-dreadnought"],15:["wiki.html#intergalactic-structures-armed_miner"],16:["wiki.html#intergalactic-structures-minelayer"],17:["wiki.html#intergalactic-structures-raider"],18:[!1,"wiki.html#perks-prestige-banana"]}});mc(a,!1,["banana"]),mc(a,!0,["banana"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_blackhole"),color:!!t.stats.achieve.whitehole,link:"wiki.html#resets-prestige-blackhole"},{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"}]}]),En("add","challenges-gameplay","scenarios_banana",z("wiki_challenges_scenarios_banana"))}{let a=In(e,{name:"scenarios_truepath",template:"challenges",paragraphs:5,break:[5],h_level:2,para_data:{1:[z("evo_challenge_truepath"),z("wiki_challenges_scenario")],2:[z("tech_era_deep_space")],3:[z("tech_era_interstellar"),z("tech_era_solar")]},data_link:{2:["wiki.html#deep_space-tech"],3:["wiki.html#interstellar-tech","wiki.html#solar-tp_tech"]}});In(a,{name:"scenarios_truepath_genes",template:"challenges",paragraphs:1,h_level:2,para_data:{1:[z("evo_challenge_plasmid"),z("evo_challenge_crispr"),z("evo_challenge_badgenes"),z("evo_challenge_nerfed")]},data_link:{1:["wiki.html#challenges-gameplay-genes_plasmid","wiki.html#challenges-gameplay-genes_crispr","wiki.html#challenges-gameplay-genes_bad","wiki.html#challenges-gameplay-genes_weak"]}}),In(a,{name:"scenarios_truepath_rival",template:"challenges",paragraphs:5,break:[2,3,5],h_level:2}),In(a,{name:"scenarios_truepath_syndicate",template:"challenges",paragraphs:2,h_level:2}),In(a,{name:"scenarios_truepath_costs",template:"challenges",paragraphs:4,break:[2,3,4],h_level:2,para_data:{2:["3x"],3:["2x"]}}),In(a,{name:"scenarios_truepath_market",template:"challenges",paragraphs:1,h_level:2,para_data:{1:["2x"]}}),In(a,{name:"scenarios_truepath_tax",template:"challenges",paragraphs:3,break:[2,4],h_level:2,para_data:{1:["50%"],2:[z("tech_merchandising"),z("city_temple")]}}),In(a,{name:"scenarios_truepath_money",template:"challenges",paragraphs:2,break:[2],h_level:2,para_data:{1:[z("city_bank"),"25%"],2:[z("city_casino"),"50%"]}}),In(a,{name:"scenarios_truepath_morale",template:"challenges",paragraphs:1,h_level:2,para_data:{1:["25%"]}}),In(a,{name:"scenarios_truepath_foreign",template:"challenges",paragraphs:1,h_level:2}),In(a,{name:"scenarios_truepath_fuel",template:"challenges",paragraphs:1,h_level:2,para_data:{1:["25%","150%"]}}),mc(a,!1,["pathfinder","overlord","ashanddust","exodus","obsolete","bluepill","retired"],{ashanddust:!0,exodus:!0,obsolete:!0,bluepill:!0,retired:!0}),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"},{text:z("wiki_resets_infusion"),color:!!t.stats.achieve.corrupted,link:"wiki.html#resets-prestige-infusion"}]}]),En("add","challenges-gameplay","scenarios_truepath",z("wiki_challenges_scenarios_truepath"))}{let a=In(e,{name:"scenarios_lone_survivor",template:"challenges",paragraphs:4,break:[4],h_level:2,para_data:{1:[z("evo_challenge_lone_survivor"),z("wiki_challenges_scenario"),z("tab_tauceti")],3:[z("evo_challenge_truepath")],4:[z("wiki_challenges_scenario"),z("wiki_resets_eden")]},data_link:{4:[!1,"wiki.html#resets-prestige-eden"]}});mc(a,!1,["adam_eve"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_retired"),color:!!t.stats.achieve.retired,link:"wiki.html#resets-prestige-retired"}]}]),En("add","challenges-gameplay","scenarios_lone_survivor",z("wiki_challenges_scenarios_lone_survivor"))}}}(a);break;case"resets":wc(a);break;case"planets":Gn(a);break;case"universes":!function(e){let t=Ln("create",e),a=[];Object.keys(Wt).forEach((function(e){a.push(e)}));let r=a.map((e=>`${z(`universe_${e}`)}`));In(t,{name:"intro",template:"universe",paragraphs:3,break:[2],h_level:2,para_data:{1:[a.length,r.slice(0,-1).join(", ")+`, ${z("or")} ${r[r.length-1]}`],2:[z("universe_standard")],3:[z("wiki_resets_blackhole")]},data_color:{1:["warning","plain"],2:["caution"]},data_link:{3:["wiki.html#resets-gameplay-blackhole"]}}),Ln("add","universes-gameplay","intro",z("wiki_menu_intro")),In(t,{name:"standard",template:"universe",paragraphs:3,break:[2],h_level:2,para_data:{1:[z("universe_standard")],2:[z("wiki_p_res_dark")],3:[z("wiki_p_res_dark"),+(100*(Is("standard",!1,!0)-1)).toFixed(3)+"%"]},data_color:{1:["caution"]}}),Ln("add","universes-gameplay","standard",z("wiki_universe_standard"));let i=+(100*(1.25+.5*Is("heavy",!1,!0)-1)).toFixed(3)+"%",s=+(100*(1.2+.3*Is("heavy",!1,!0)-1)).toFixed(3)+"%";In(t,{name:"heavy",template:"universe",paragraphs:9,break:[5,8],h_level:2,para_data:{1:[Wt.heavy.desc],2:[z("resource_Oil_name"),z("resource_Helium_3_name"),z("resource_Deuterium_name")],3:[z("tab_space"),"75%"],4:[z("tab_interstellar"),z("tab_galactic"),"50%"],5:[z("wiki_universe_heavy")],6:["5%",z("resource_Plasmid_plural_name"),z("resource_Phage_name"),z("resource_Dark_name")],7:[z("resource_Harmony_name"),"20%"],8:[z("wiki_p_res_dark")],9:[z("wiki_p_res_dark"),i,s]},data_color:{1:["plain"]},data_link:{6:["plain","wiki.html#resources-prestige-plasmids","wiki.html#resources-prestige-phage","wiki.html#resources-prestige-dark"],7:["wiki.html#resources-prestige-harmony","plain"]}}),Ln("add","universes-gameplay","heavy",z("wiki_universe_heavy")),In(t,{name:"antimatter",template:"universe",paragraphs:9,break:[3,6,8],h_level:2,para_data:{1:[z("universe_antimatter")],2:[z("resource_AntiPlasmid_plural_name"),z("resource_Plasmid_plural_name")],3:[z("evo_challenge_plasmid"),z("evo_challenge_mastery")],4:["50%"],5:["50%","6%"],7:["10%"],8:[z("wiki_p_res_dark")],9:[z("wiki_p_res_dark"),+(100*(Is("antimatter",!1,!0)-1)).toFixed(3)+"%"]},data_color:{1:["caution"]},data_link:{2:["wiki.html#resources-prestige-antiplasmids","wiki.html#resources-prestige-plasmids"]}}),Ln("add","universes-gameplay","antimatter",z("wiki_universe_antimatter")),In(t,{name:"evil",template:"universe",paragraphs:7,break:[2,5],h_level:2,para_data:{2:[z("trait_evil_name")],3:[z("trait_evil_name")],4:[z("biome_hellscape_name"),z("biome_eden_name")],5:[z("wiki_p_res_dark")],7:[z("wiki_p_res_dark"),+(100*(Is("evil",!1,!0)-1)).toFixed(3)+"%"]}}),Ln("add","universes-gameplay","evil",z("wiki_universe_evil")),In(t,{name:"micro",template:"universe",paragraphs:6,break:[2,4],h_level:2,para_data:{1:["75%"],4:[z("wiki_p_res_dark")],5:[z("wiki_p_res_dark"),Is("micro",!1,!0),Is("micro",!0,!0)],6:["1.005"]}}),Ln("add","universes-gameplay","micro",z("wiki_universe_micro")),In(t,{name:"magic",template:"universe",paragraphs:8,break:[4,7],h_level:2,para_data:{6:[80],7:[z("wiki_p_res_dark")],8:[z("wiki_p_res_dark"),+(100*(Is("magic",!1,!0)-1)).toFixed(3)+"%"]}}),Ln("add","universes-gameplay","magic",z("wiki_universe_magic"))}(a);break;case"hell":!function(e){let t=Ln("create",e);t.append(`

                      ${z("wiki_hell")}

                      `),In(t,{name:"threat",template:"hell",paragraphs:3,para_data:{1:["10,000"],2:["1000-1250"]},data_color:{1:["caution"],2:["warning"]}}),Ln("add","hell-gameplay","threat",z("wiki_hell_threat")),In(t,{name:"siege",template:"hell",paragraphs:5,para_data:{3:["5k+"]},data_color:{3:["caution"]}}),Ln("add","hell-gameplay","siege",z("wiki_hell_siege")),In(t,{name:"strategy",template:"hell",paragraphs:3}),Ln("add","hell-gameplay","strategy",z("wiki_hell_strategy"));let a=In(t,{name:"soul_gem",template:"hell",paragraphs:4,para_data:{1:[z("wiki_hell_soul_gem"),z("tab_portal")],3:[z("tech_demon_attractor")]}}),r=$("
                      ");a.append(r),Ln("add","hell-gameplay","soul_gem",z("wiki_hell_soul_gem")),In(t,{name:"infernite",template:"hell",paragraphs:4}),Ln("add","hell-gameplay","infernite",z("wiki_hell_infernite")),t.append(`

                      ${z("wiki_hell_deep")}

                      `),In(t,{name:"pit",template:"hell",paragraphs:3,para_data:{1:["1,000,000",z("galaxy_telemetry_beacon")],2:[z("portal_soul_forge_title")]},data_link:{1:[!1,"wiki.html#intergalactic-structures-telemetry_beacon"],2:["wiki.html#hell-structures-soul_forge"]}}),Ln("add","hell-gameplay","pit",z("wiki_hell_pit")),In(t,{name:"corrupted",template:"hell",paragraphs:3,para_data:{1:[z("tech_metaphysics"),z("portal_soul_forge_title"),z("resource_Corrupt_Gem_name")],2:[z("portal_ruins_name")],3:[z("tech_era_intergalactic")]},data_link:{1:["wiki.html#intergalactic-tech-metaphysics"]}}),Ln("add","hell-gameplay","corrupted",z("wiki_hell_corrupted"));let i=Ks();In(t,{name:"pillar",template:"hell",paragraphs:6,break:[4,5,6],para_data:{1:[z("portal_ruins_name")],2:["1%",z("harmonic")],3:["3%"],4:[z("harmonic"),"2%","6%"],5:[z("wiki_hell_pillar_para5d1"),12],6:[z("harmonic"),`${(100*(i[0]-1)).toFixed(0)}%`,`${(100*(i[1]-1)).toFixed(0)}%`]},data_link:{5:["wiki.html#hell-structures-west_tower"]}}),Ln("add","hell-gameplay","pillar",z("wiki_hell_pillar")),t.append(`

                      ${z("portal_spire_name")}

                      `),In(t,{name:"spire",template:"hell",paragraphs:5,break:[4],para_data:{4:[z("resource_Blood_Stone_name")],5:[z("wiki_resets_infusion")]},data_link:{5:["wiki.html#resets-prestige-infusion"]}}),Ln("add","hell-gameplay","spire",z("portal_spire_name"));{let e=In(t,{name:"mech",template:"hell",paragraphs:2,para_data:{2:[5,z("portal_mech_size_small"),z("portal_mech_size_medium"),z("portal_mech_size_large"),z("portal_mech_size_titan"),z("portal_mech_size_collector")]}}),a=fa("small");In(e,{name:"scout",template:"hell",paragraphs:10,break:[3,4,5,6,10],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_small")],2:[1,1,z("arpa_blood_prepared_title")],3:[(100*qa("small")).toFixed(2)],4:[ba("small"),a.c,a.s],5:[z("portal_mech_equip_jumpjet")],7:["1%"],8:[z("portal_spire_status_fog"),z("portal_spire_status_dark")],9:["100%"],10:["8%"]},data_link:{2:[!1,!1,"wiki.html#blood-prestige-prepared"]}});let r=fa("medium");In(e,{name:"standard",template:"hell",paragraphs:6,break:[3,4,5,6],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_medium")],2:[1,1,2,z("arpa_blood_prepared_title")],3:[(100*qa("medium")).toFixed(2)],4:[ba("medium"),r.c,r.s],5:[z("portal_mech_equip_jumpjet")],6:["5%"]},data_link:{2:[!1,!1,!1,"wiki.html#blood-prestige-prepared"]}});let i=fa("large");In(e,{name:"heavy",template:"hell",paragraphs:6,break:[3,4,5,6],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_large")],2:[2,2,3,z("arpa_blood_prepared_title")],3:[(100*qa("large")).toFixed(2)],4:[ba("large"),i.c,i.s],5:[z("portal_mech_equip_battery")]},data_link:{2:[!1,!1,!1,"wiki.html#blood-prestige-prepared"]}});let s=fa("titan");In(e,{name:"titan",template:"hell",paragraphs:7,break:[3,4,5,6,7],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_titan")],2:[4,4,5,z("arpa_blood_prepared_title")],3:[(100*qa("titan")).toFixed(2)],4:[ba("titan"),s.c,s.s],5:[z("portal_mech_equip_target")],7:["25%"]},data_link:{2:[!1,!1,!1,"wiki.html#blood-prestige-prepared"]}});let n=fa("collector");In(e,{name:"collector",template:"hell",paragraphs:5,break:[3,4,5],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_collector")],2:[2,3,z("arpa_blood_prepared_title")],3:[ba("collector"),n.c,n.s],4:[z("portal_mech_equip_jumpjet")]},data_link:{2:[!1,!1,"wiki.html#blood-prestige-prepared"]}}),Ln("add","hell-gameplay","mech",z("wiki_hell_mech"))}{let e=["wheel","tread","biped","quad","spider","hover"],a=["sand","swamp","forest","jungle","rocky","gravel","muddy","grass","brush","concrete"],r=[];r.push(e.length),e.forEach((function(e){r.push(z(`portal_mech_chassis_${e}`))}));let i=In(t,{name:"chassis",template:"hell",paragraphs:4,para_data:{1:r,2:[a.length]}});a.forEach((function(t){let a={};for(let r=1;r<=e.length;r++){let i=+(100*xa({chassis:e[r-1],size:"small"},t)).toFixed(1),s=+(100*xa({chassis:e[r-1],size:"large"},t)).toFixed(1);a[r+1]=`${z("wiki_hell_effectiveness",[`${z(`portal_mech_chassis_${e[r-1]}`)}`,`${i}%`,`${s}%`,'S','L'])}`}In(i,{name:`t_${t}`,template:"hell",label:z(`portal_spire_type_${t}`),paragraphs:7,break:[2,3,4,5,6,7],h_level:4,header:!0,text:{1:`portal_spire_type_${t}_desc`},rawtext:a,pclass:"col2 sk1"})})),Ln("add","hell-gameplay","chassis",z("wiki_hell_chassis"))}{let e=["laser","flame","plasma","kinetic","missile","sonic","shotgun","tesla"],a=In(t,{name:"monsters",template:"hell",paragraphs:4,para_data:{2:[e.length]}});Object.keys(va).forEach((function(t){let r={};for(let a=1;a<=e.length;a++){let i=+(100*(va[t].weapon.hasOwnProperty(e[a-1])?va[t].weapon[e[a-1]]:1)).toFixed(0);r[a]=`${z("wiki_hell_weapon_effect",[`${z(`portal_mech_weapon_${e[a-1]}`)}`,`${i}%`])}`}In(a,{name:`boss_${t}`,template:"hell",label:z(`portal_mech_boss_${t}`),paragraphs:8,break:[2,3,4,5,6,7,8],h_level:4,header:!0,rawtext:r,pclass:"col2"})})),Ln("add","hell-gameplay","monsters",z("wiki_hell_monsters"))}{let e=In(t,{name:"hazard",template:"hell",paragraphs:8,break:[3,4,5,6,7],para_data:{3:["+1","10+"],4:[`6/(105-${z("wiki_hell_hazard_para3_note")})`,"+1","25-100"],5:[`11/(260-${z("wiki_hell_hazard_para3_note")})`,"+1","101-250"],6:[`26/(1025-${z("wiki_hell_hazard_para3_note")})`,"+1","251-1000"],7:["-1"],8:[z("portal_spire_status_freeze"),z("portal_spire_status_hot"),z("portal_spire_status_rain"),z("portal_spire_status_hail")]}}),a={1:"wiki_hell_hazard_effect",2:"wiki_hell_hazard_counter"};In(e,{name:"h_freeze",template:"hell",label:z("portal_spire_status_freeze"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["75%"],2:[z("portal_mech_equip_radiator")]}}),In(e,{name:"h_hot",template:"hell",label:z("portal_spire_status_hot"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["75%"],2:[z("portal_mech_equip_coolant")]}}),In(e,{name:"h_corrosive",template:"hell",label:z("portal_spire_status_corrosive"),paragraphs:3,break:[2,3],h_level:4,header:!0,text:{1:"wiki_hell_hazard_effect",2:"wiki_hell_hazard_counter",3:"wiki_hell_hazard_partial"},para_data:{1:["75%"],2:[z("portal_mech_equip_ablative")],3:[z("portal_mech_equip_shields")]}}),In(e,{name:"h_humid",template:"hell",label:z("portal_spire_status_humid"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["25%"],2:[z("portal_mech_equip_seals")]}}),In(e,{name:"h_windy",template:"hell",label:z("portal_spire_status_windy"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_chassis"},para_data:{1:["50%",z("portal_mech_chassis_hover")]}}),In(e,{name:"h_hilly",template:"hell",label:z("portal_spire_status_hilly"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_not_chassis"},para_data:{1:["25%",z("portal_mech_chassis_spider")]}}),In(e,{name:"h_mountain",template:"hell",label:z("portal_spire_status_mountain"),paragraphs:2,break:[2],h_level:4,header:!0,text:{1:"wiki_hell_hazard_either",2:"wiki_hell_hazard_partial"},para_data:{1:["50%",z("portal_mech_chassis_spider"),z("portal_mech_equip_grapple")],2:[z("portal_mech_equip_flare")]}}),In(e,{name:"h_radioactive",template:"hell",label:z("portal_spire_status_radioactive"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["50%"],2:[z("portal_mech_equip_shields")]}}),In(e,{name:"h_quake",template:"hell",label:z("portal_spire_status_quake"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["75%"],2:[z("portal_mech_equip_stabilizer")]}}),In(e,{name:"h_dust",template:"hell",label:z("portal_spire_status_dust"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["50%"],2:[z("portal_mech_equip_seals")]}}),In(e,{name:"h_river",template:"hell",label:z("portal_spire_status_river"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_not_chassis"},para_data:{1:["35%",z("portal_mech_chassis_hover")]}}),In(e,{name:"h_tar",template:"hell",label:z("portal_spire_status_tar"),paragraphs:2,break:[2],h_level:4,header:!0,text:{1:"wiki_hell_hazard_not_chassis",2:"wiki_hell_hazard_worse"},para_data:{1:["25%",z("portal_mech_chassis_quad")],2:["50%",z("portal_mech_chassis_tread"),z("portal_mech_chassis_wheel")]}}),In(e,{name:"h_steam",template:"hell",label:z("portal_spire_status_steam"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["25%"],2:[z("portal_mech_equip_shields")]}}),In(e,{name:"h_flooded",template:"hell",label:z("portal_spire_status_flooded"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_not_chassis"},para_data:{1:["65%",z("portal_mech_chassis_hover")]}}),In(e,{name:"h_fog",template:"hell",label:z("portal_spire_status_fog"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["80%"],2:[z("portal_mech_equip_sonar")]}}),In(e,{name:"h_rain",template:"hell",label:z("portal_spire_status_rain"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["25%"],2:[z("portal_mech_equip_seals")]}}),In(e,{name:"h_hail",template:"hell",label:z("portal_spire_status_hail"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_either2"},para_data:{1:["25%",z("portal_mech_equip_ablative"),z("portal_mech_equip_shields")]}}),In(e,{name:"h_chasm",template:"hell",label:z("portal_spire_status_chasm"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["90%"],2:[z("portal_mech_equip_grapple")]}}),In(e,{name:"h_dark",template:"hell",label:z("portal_spire_status_dark"),paragraphs:3,break:[2,3],h_level:4,header:!0,text:{1:"wiki_hell_hazard_effect",2:"wiki_hell_hazard_counter",3:"wiki_hell_hazard_partial"},para_data:{1:["90%"],2:[z("portal_mech_equip_infrared")],3:[z("portal_mech_equip_flare")]}}),In(e,{name:"h_gravity",template:"hell",label:z("portal_spire_status_gravity"),paragraphs:3,break:[2,3],h_level:4,header:!0,text:{1:"wiki_hell_hazard_gravity",2:"wiki_hell_hazard_gravity",3:"wiki_hell_hazard_gravity"},para_data:{1:[z("portal_mech_size_medium"),"20%"],2:[z("portal_mech_size_large"),"55%"],3:[z("portal_mech_size_titan"),"75%"]}}),Ln("add","hell-gameplay","hazard",z("wiki_hell_hazard"))}{let e=In(t,{name:"equipment",template:"hell",paragraphs:1,h_level:2,para_data:{1:[z("portal_mech_equip_jumpjet"),z("portal_mech_equip_battery"),z("portal_mech_equip_target")]}});Ln("add","hell-gameplay","equipment",z("wiki_hell_equipment")),In(e,{name:"eq_jump",template:"hell",label:z("portal_mech_equip_jumpjet"),paragraphs:4,break:[4],h_level:3,header:!0,para_data:{1:[z("portal_mech_equip_jumpjet"),z("wiki_hell_scout"),z("wiki_hell_standard"),z("wiki_hell_collector")],2:["20%"],3:["10%",z("portal_spire_status_gravity")]}}),In(e,{name:"eq_battery",template:"hell",label:z("portal_mech_equip_battery"),paragraphs:2,h_level:3,header:!0,para_data:{1:[z("portal_mech_equip_battery"),z("wiki_hell_heavy")],2:["2%"]}}),In(e,{name:"eq_target",template:"hell",label:z("portal_mech_equip_target"),paragraphs:3,h_level:3,header:!0,para_data:{1:[z("portal_mech_equip_target"),z("wiki_hell_titan")],2:["25%"]}})}}(a)}}function $c(e){e.append(`
                      ${z("wiki_arpa_crispr")}
                      `);let a=$("
                      "),r=Ln("create",a);e.append(a),Object.keys(je).forEach((function(e){let a=je[e].id.split("-"),i=$(`
                      `);r.append(i),function(e,a){let r=!!(t.genes[je[a].grant[0]]&&t.genes[je[a].grant[0]]>=je[a].grant[1]);e.append(`

                      ${je[a].title}

                      ${r?`${z("wiki_arpa_purchased")}`:""}${z(`wiki_arpa_crispr_${je[a].grant[0]}`)}: ${je[a].grant[1]}
                      `);let i=$('
                      ');e.append(i),i.append(`
                      ${je[a].desc}
                      `);let s=$('
                      ');if(i.append(s),Object.keys(je[a].cost).forEach((function(e){let r=je[a].cost[e]();if(r>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let a=z(`resource_${e}_name`);s.append(`
                      ${a}: ${r}
                      `)}})),Object.keys(je[a].reqs).length>0){let r=$(`
                      ${z("wiki_arpa_crispr_req")}
                      `);e.append(r);let i=!1;Object.keys(je[a].reqs).forEach((function(e){let s=t.genes[e]&&t.genes[e]>=je[a].reqs[e]?"success":"danger";r.append(`${i?", ":""}${z(`wiki_arpa_crispr_${e}`)} ${je[a].reqs[e]}`),i=!0}))}if(xc.hasOwnProperty(a)){let t=!1,r=$(`
                      ${z("wiki_arpa_crispr_req_extra")}
                      `);e.append(r),Object.keys(xc[a]).forEach((function(e){let i=xc[a][e].color?"success":"danger",s=xc[a][e].link?`${xc[a][e].title}`:xc[a][e].title;r.append(`${t?", ":""}${s}`),t=!0}))}}(i,e),Ln("add","crispr-prestige",a[1],je[e].title)}))}const xc={universal:[{title:z("wiki_tech_special_universe_not",[z("universe_standard")]),color:"standard"!==t.race.universe,link:"wiki.html#universes-gameplay-standard"}],standard:[{title:z("wiki_tech_special_universe_not",[z("universe_standard")]),color:"standard"!==t.race.universe,link:"wiki.html#universes-gameplay-standard"}],ancients:[{title:z("wiki_arpa_crispr_special_ancients"),color:!!t.genes.old_gods,link:"wiki.html#resets-prestige-intro"}],bleeding_effect:[{title:z("wiki_tech_special_universe",[z("universe_antimatter")]),color:"antimatter"===t.race.universe,link:"wiki.html#universes-gameplay-antimatter"}],blood_remembrance:[{title:z("wiki_arpa_crispr_special_blood_remembrance"),color:t.prestige.Blood_Stone.count>=1,link:"wiki.html#resources-prestige-blood"}]};var qc={};function Pc(e){e.append(`
                      ${z("wiki_arpa_blood")}
                      `);let a=$("
                      "),r=Ln("create",a);e.append(a),Object.keys(Oe).forEach((function(e){let a=Oe[e].id.split("-"),i=$(`
                      `);r.append(i),function(e,a){let r=!!(t.blood[Oe[a].grant[0]]&&t.blood[Oe[a].grant[0]]>=Oe[a].grant[1]);e.append(`

                      ${Oe[a].title}

                      ${r?`${z("wiki_arpa_purchased")}`:""}${z(`wiki_arpa_blood_${Oe[a].grant[0]}`)}: ${Oe[a].grant[1]}
                      `);let i=$('
                      ');e.append(i),i.append(`
                      ${Oe[a].desc}
                      `);let s=$('
                      ');if(i.append(s),Object.keys(Oe[a].cost).forEach((function(e){let t=z(`resource_${e}_name`);if("*"===Oe[a].grant[1])s.append(`
                      ${t}: {{ r.${e}.cost }}
                      `);else{let r=Oe[a].cost[e]();r>0&&s.append(`
                      ${t}: ${r}
                      `)}})),Object.keys(Oe[a].reqs).length>0||Oe[a].hasOwnProperty("condition")){let r=$(`
                      ${z("wiki_arpa_crispr_req")}
                      `);e.append(r);let i=!1;if(Object.keys(Oe[a].reqs).length>0&&Object.keys(Oe[a].reqs).forEach((function(e){let s=t.blood[e]&&t.blood[e]>=Oe[a].reqs[e]?"success":"danger";r.append(`${i?", ":""}${z(`wiki_arpa_blood_${e}`)} ${Oe[a].reqs[e]}`),i=!0})),Oe[a].hasOwnProperty("condition")){let e=t.genes.blood&&t.genes.blood>=3?"success":"danger";r.append(`${i?", ":""}${z("wiki_arpa_crispr_blood")} 3`)}}"*"===Oe[a].grant[1]&&function(e,a){let r={owned:0},i={},s=Oe[a];r.real_owned=t.blood[a]?t.blood[a]:0;let n=s.cost;Object.keys(n).forEach((function(e){i[e]={}}));let c=function(){Object.keys(i).forEach((function(e){let t=n[e]?n[e](r.owned-r.real_owned):0;i[e].vis=t>0,i[e].cost=t}))};c(),e.append($(`\n
                      \n
                      \n
                      ${z("wiki_calc_level")} -+
                      \n
                      \n
                      \n \n
                      \n
                      \n `)),Cs({el:`#${a}`,data:{i:r,r:i},methods:{val(e){r[e]=Math.round(r[e]),r[e]&&r[e]<0&&(r[e]=0),c()},less(e){r[e]>0&&r[e]--},more(e){r[e]++},importInputs(){r.owned=r.real_owned}}})}(e,a)}(i,e),Ln("add","blood-prestige",a[1],Oe[e].title)}))}Object.keys(je).forEach((function(e){let t=je[e];qc[t.grant[0]]||(qc[t.grant[0]]={}),"string"==typeof je[e].title?je[e].title:je[e].title(),qc[t.grant[0]][t.grant[1]]={name:e}}));var jc={};Object.keys(Oe).forEach((function(e){let t=Oe[e];jc[t.grant[0]]||(jc[t.grant[0]]={}),"string"==typeof Oe[e].title?Oe[e].title:Oe[e].title(),jc[t.grant[0]][t.grant[1]]={name:e}}));const Oc={launch_facility:[z("wiki_arpa_project_launch_facility")],monument:[function(){let e=[z("arpa_project_monument_obelisk"),z("arpa_project_monument_statue"),z("arpa_project_monument_sculpture"),z("arpa_project_monument_monolith"),z("arpa_project_monument_pillar"),z("arpa_project_monument_megalith")],t=[z("resource_Stone_name"),z("resource_Aluminium_name"),z("resource_Steel_name"),z("resource_Cement_name"),z("resource_Bones_name"),z("resource_Crystal_name")],a=`
                      ${z("wiki_arpa_project_monument",[e.length,e.join(", ")])}
                      `;for(let r=0;r${z("wiki_arpa_project_monument_type",[`${e[r]}`,`${t[r]}`])}
                      `;return a}(),z("wiki_arpa_project_monument_random"),z("wiki_arpa_project_monument_exceptions")],railway:[z("wiki_arpa_project_railway_homeless",[3,7,11,17,25,38,59,100,225])],roid_eject:[z("wiki_arpa_project_roid_eject")],tp_depot:[z("wiki_arpa_project_depot")],nexus:[z("wiki_arpa_project_magic")],syphon:[z("wiki_arpa_project_magic")]};const Mc=[{version:"1.3.8",revision:"a",date:"6/1/2023",changes:["Fixed high pop scaling."]},{version:"1.3.8",date:"6/1/2023",changes:["Unfathomable bug fixes.","Psychic powers up time now scale with rank of Ancient Nightmare.","Additional Psychic power upgrades.","Intergalactic Raider renamed to Corsair."]},{version:"1.3.7",revision:"a",date:"5/30/2023",changes:["Fixed issue with drawing the same alien species twice in intergalactic content.","Adjusted Mana costs for some research techs in Witch Hunter."]},{version:"1.3.7",date:"5/29/2023",changes:["Added Magic universe exclusive challenge: Witch Hunter.","Reduced Encrypted Data cost of Data Analysis, Advanced Medkits, Automated Warehousing, Elerium Extraction, and Drone Warfare techs.","Star Forge smelting bonus rebalanced.","Antimatter Dark Energy effect now applies to Truepath Ship power generation.","Fixed Magocracy Crystal bonus.","Reduced Crystal cost of Alchemy.","Fixed Humpback trait rank scaling.","Infiltrator can now steal Alien Biotech on Truepath.","Fixed brownout issue with using Replicator Gov task when constructing a new powered building.","Fixed rejuvenated trashed planet bonus.","Fixed orbit period on reterraformed planets."]},{version:"1.3.6",date:"4/22/2023",changes:["Added Astrological signs.","Added Motivated Event.","Operating Bases now function as Hospitals in Orbit Decay scenario.","Stellar Forge is now locked to using Star Fuel for smelting.","Species with the Forge trait can now use Inferno Fuel and Star Fuel.","Reduced Wireless Signal needed to Contact womlings in Lone Survivor."]},{version:"1.3.5",revision:"c",date:"4/16/2023",changes:["Made Egg #17 easier to get in Cataclysm mode."]},{version:"1.3.5",revision:"b",date:"4/9/2023",changes:["Increased egg accessibility with certain traits or challenge modes."]},{version:"1.3.5",revision:"a",date:"4/8/2023",changes:["Fixed a bug that caused eggs 16-18 not to count for unlocking the egg hunt feat."]},{version:"1.3.5",date:"4/7/2023",changes:["Avian species now have the Flier trait.","Avian Rigid trait replaced with Sky Lover.","Added Wireless storage to High-Tech farm in isolation","Fixed truepath dreadnought power costs.","Fixed a bug that could assign extra challenge genes.","Fixed a bug with changing languages with active Tau Ceti content.","Fixed many issues with preload tab content in the early game."]},{version:"1.3.4",revision:"b",date:"3/30/2023",changes:["Prevented some bugs caused by distributed power mode from occurring.","You can now unlock World Domination, Illuminati, Syndicate, and Pacifist in Truepath."]},{version:"1.3.4",revision:"a",date:"3/25/2023",changes:["A restore point is now made if you select isolation protocol."]},{version:"1.3.4",date:"3/24/2023",changes:["Evolving Synth can now choose imitation race from any species killed by an AI Apocalypse.","Fixed issue with miscalculating low fuel usage for various power generating structures.","Extractor Ship Isolation output boosted by 20%.","Added additional Hooved reskins.","Fixed various issues with Preload Tab Content.","Explorer Ship config is now locked down for Engine, Sensor, and Weapon components.","Skilled Servants assigned to craft inactive resources will now be refunded."]},{version:"1.3.3",revision:"a",date:"3/20/2023",changes:["Fixed a bug that could cause the Test Launch to be unavailable."]},{version:"1.3.3",date:"3/15/2023",changes:["Rebalanced Soul Gem drop mechanics.","Added Annihilation Feat.","Added additional Mass Ejector Optimizer config mode.","Servants are no longer affected by most racial traits.","The Lone Survivor can no longer benefit from Hivemind.","Fixed High Pop issue with Pit Miners.","Fixed bug with unlocking Replicator without a Governor."]},{version:"1.3.2",revision:"c",date:"3/8/2023",changes:["Fixed cataclysm reset while having preload tab content enabled."]},{version:"1.3.2",revision:"b",date:"3/5/2023",changes:["Fixed Rock Quarry under industry tab for Smoldering players."]},{version:"1.3.2",revision:"a",date:"3/5/2023",changes:["Adjusted hell calculation."]},{version:"1.3.2",date:"3/4/2023",changes:["High-Tech Factory changed back to tool modifier, however value is increased from original 25% to 90%.","Advanced Material Synthesis increased from 50% to 65%.","Added new interaction between Hell Surveyors and Drone victims.","Fixed bug that would cause Replicator Governor task to swap resources when focusing a resource without a cap.","Fixed inability to produce Chrysotile in Isolation."]},{version:"1.3.1",date:"3/3/2023",changes:["Added Advanced Material Synthesis tech to Isolation path.","High-Tech Factory crafting bonus changed from a Tool modifier to a direct multiplier.","Updated Mass Ejector Optimizer logic.","Fixed a bug that broke Cataclysm reset.","Fixed fuel calculation bug with Moon Bases and Spaceports.","Fixed issue with self replicating Synth and Nano.","Fixed bugs with purchasing CRISPR techs in Antimatter universe."]},{version:"1.3.0",revision:"b",date:"3/1/2023",changes:["Fixed issue with Mass Ejector Optimizer gov task breaking the governor subtab."]},{version:"1.3.0",revision:"a",date:"3/1/2023",changes:["Fixed Antimatter universe."]},{version:"1.3.0",date:"3/1/2023",changes:["The True Path has been extended, explore Tau Ceti and expand your civilization.","Added Perks: Evolve Master and Evolve Grandmaster.","Added Distributed Low Power mode setting.","Added Precognition CRISPR upgrade.","Strong trait now buffs basic jobs but has a weaker effect on manual resource collection.","Ships in Truepath can now only be scrapped at the Shipyard.","Truepath Sensor Range and Costs adjusted. Range now depends partly on base ship class.","Queue stacks now indicate first block vs last blocking resource with a gradient indicator.","Added screen reader improvements for blocking resources.","You can no longer unlock Anarchist by Cataclysm.","Syndicate will now also steal food from Biodomes.","Reinforced Shed upgrade now requires unlocking Iron Mining.","You must now construct a Titan Habitat before a Titan Mine.","Removed dark background effect from modal popups.","Increased Entrepreneur Governor trade bonus from 75% to 125% and Bank capacity boost from 10% to 12%.","Increased Media Governor morale bonuses and Library bonus.","Increased Soldier Governor combat bonus from 5% to 25%.","Increased Educator Governor knowledge bonus from 5% to 6%.","Increased Spiritualist Governor worker bonus from 10% to 20% and tourism bonus from $2 to $5 per Temple.","Increased Noble Governor tax cap bonus from 10% to 20%.","Bluecollar Governor now increases output of Coal and Oil power plants and boosts Miners, Smelter, and Oil Derrick.","Bureaucrat Governor now provides a slight boost to government effects."]},{version:"1.2.21",date:"1/10/2023",changes:["New Achievement filtering options in Wiki.","Updated Chinese lang file.","Updated Korean lang file."]},{version:"1.2.20",date:"9/16/2022",changes:["New homelessness system.","Factory, Mining Droids, and Graphene Plants will remember resource assignment after a low power shutdown.","Terraforming and Ascension can no longer be queued or multi-clicked.","AI Cores show correct bonus in tooltip.","Stealing Rocketry will now unlock rival in Truepath.","Playful will no longer remove unemployed stress with no hunters.","Andromeda Citizens will no longer stick around if abandoned by a stargate shutdown.","Fixed various bugs with mutating in or out some traits.","Made some improvements for screen readers to determine active state of challenges."]},{version:"1.2.19",revision:"a",date:"8/21/2022",changes:["Home Planet Orbital structures are now merged with the Moon instead of Red Planet in Cataclysm."]},{version:"1.2.19",date:"8/20/2022",changes:["Added rank scaling effects to traits: Carnivore, Hooved, Leathery, Unified, & Magnificent.","Structures orbiting the home planet are now moved to the Red planet after Orbit Decay or during Cataclysm.","Fixed a bug with deactivating fuel consuming structures when fuel runs dry.","Already active Governor tasks will no longer display for assignment in other task slots.","Constructing a Stellar or Infernal Forge will now assign Iron as a default resource instead of nothing.","Buffed effects of Star Forge fueled smelting.","Fixed an incorrect source label for money storage in Orbit Decay."]},{version:"1.2.18",revision:"a",date:"8/14/2022",changes:["Fixed ARPA queueing."]},{version:"1.2.18",date:"8/14/2022",changes:["More accurate timers when using Governor Trash Management task.","Optimistic Min Morale effect now scales with trait rank.","Fixed TP loot table when Assaulting or Sieging rival."]},{version:"1.2.17",revision:"a",date:"8/10/2022",changes:["Cheese Event power is now scaled with your cheese level.","Fixed Soft Reset bug with Rejuvenated."]},{version:"1.2.17",date:"8/10/2022",changes:["New Hell stats tracking and analytics.","Fixed Genetics not unlocking in Cataclysm.","Fixed many High Pop scaling interactions.","Fixed some loading bugs with wiki when no save data is present.","Updated various wiki entries and calculators.","Updated Pig Latin."]},{version:"1.2.16",revision:"a",date:"8/8/2022",changes:["Fixed OD bugs with Ziggurat, Garage, and Fabrication.","Fixed Launch Facility sometimes getting stuck in queue."]},{version:"1.2.16",date:"8/4/2022",changes:["Added Orbit Decay Challenge.","Added Retrograde planetary trait.","New achievement: Better dead than red.","New CRISPR upgrade: Civil Service.","Other stuff the dev was too lazy to document."]},{version:"1.2.15",revision:"a",date:"7/1/2022",changes:["Fixed bug that prevented games without save data from loading."]},{version:"1.2.15",date:"7/1/2022",changes:["Firework Festival now starts on July 1st and ends July 4th.","Added Dracula theme by azzzertyy.","Fixed bug with Horseshoe governor and multiplier keys.","Fixed issues with starting Cataclysm as Synth.","Fixed bugs with wrong path techs being displayed.","Evil Synth now start with a Graveyard instead of a Lumberyard.","Deify and study can no longer be queued at same time.","Restore backup no longer requires double clicking to trigger confirmation box."]},{version:"1.2.14",revision:"a",date:"4/19/2022",changes:["Fixed some minor bugs.","Updated some translations."]},{version:"1.2.14",date:"4/1/2022",changes:["Added Titan Mine slider to Industry tab.","Added additional popup confirmation to Restore Backup.","Nanite Factory interface now has tooltips for each resource","The Vault Discovery event can no longer occur if there are 0 Archaeologists and/or if Suppression is at 0%","Fixed bugs related to unlocking the Fool feat.","Fixed bugs with Mass Ejector optimizor governor task."]},{version:"1.2.13",date:"3/31/2022",changes:["Restore Backup must now be clicked twice to trigger."]},{version:"1.2.12",revision:"c",date:"3/7/2022",changes:["Fixed Double Density achievement."]},{version:"1.2.12",revision:"b",date:"3/2/2022",changes:["Fixed logic fault with mech constructor inferno upgrades."]},{version:"1.2.12",revision:"a",date:"3/1/2022",changes:["Fixed some bugs with planet traits.","Fixed bug with attacking on Swamp planets."]},{version:"1.2.12",date:"2/28/2022",changes:["Planets can now have upto two traits.","Advanced Biomes: Savanna, Swamp, Ashland, and Taiga can now appear.","Added Permafrost planetary trait.","Forest Biome lumber bonus changed from 15% to 20%.","Exotic materials are now ranked higher by the Mass Optimizer governor task.","Repair droid effect on Carport repairs buffed from 5% to 8%.","You must now discover the Hell Vault through Archaeology.","Water now has Mass."]},{version:"1.2.11",date:"2/16/2022",changes:["Added Doomed achievement to the perks lists.","Added Governor CRISPR tree to perks list.","Updated prestige gain/bonus calculators.","Fixed Ritual Casting not showing up in Industry in Cataclysm.","Detritivores no longer see the Farming ritual.","Fixed Entertainer tooltip showing twice the effect of Musical.","Fixed Gauss Rifles showing the effect for Disruptor Rifles.","Fixed Water Freighter tooltip showing half the Helium-3 cost.","Fixed some affordability checks."]},{version:"1.2.10",date:"2/7/2022",changes:["Bioseed probes now have significantly less cost creep inside True Path scenario.","You can no longer manually buy or sell resources while the game is paused.","Fixed bug with High Pop trait and Savings Bonds granting too much money.","Minor bug fixes"]},{version:"1.2.9",date:"1/29/2022",changes:["Spies may now sell you out when caught or escape when failing a mission.","Infiltrator can now steal Quantium tech inside True Path.","Genetics Lab UI updated."]},{version:"1.2.8",revision:"a",date:"1/19/2022",changes:["Fixed Farmer per Farm scaling with High Pop trait.","Adjusted low end scaling of High Pop Hivemind trait.","Wireless Signal cost for Symposium lowered.","Added Anarchy scaling with High Pop"]},{version:"1.2.8",date:"1/19/2022",changes:["Insectoid genus redesigned with High Population trait.","Fixed bug that caused incorrect timer calculations when using Slow or Hyper trait at any rank other then 1."]},{version:"1.2.7",revision:"a",date:"1/11/2022",changes:["Fixed storage bug with standard universe."]},{version:"1.2.7",date:"1/11/2022",changes:["Failed Experiment Challenge mode.","Ziggurat bonus separated from base production of buildings.","Fixed bug that prevented smoldering races from being able to loot Chrysotile","Fixed bug that would cause Intergalactic Tech page in wiki not to load if you were playing in Antimatter universe."]},{version:"1.2.6",date:"12/24/2021",changes:["Fixed bug that prevented custom Synthetic race from showing if you refreshed the page.","Fixed bugs with Synthetic evolution and traits: Calm, Cannibalize, and Magnificent.","Fixed bugs with using the quick tab keys when preload tabs is enabled."]},{version:"1.2.5",date:"12/21/2021",changes:["Fixed bug that caused a planet to lose its geology traits after an AI reset.","Fixed bug with scavenger job description."]},{version:"1.2.4",date:"12/19/2021",changes:["Solar system now has elliptical orbits.","Fixed Evolve Adept Food bonus.","Rank of each aquired trait is now listed in genetics tab.","Crate/Container sources are now listed in resource popup.",'Manual buying/selling will auto scale down to prevent "waste".']},{version:"1.2.3",date:"12/16/2021",changes:["Expanded Festive Season to include additional species."]},{version:"1.2.2",date:"12/15/2021",changes:["Graphene Plants now show on industry tab for True Path.","Added entry for Festive Season into wiki.","The game wiki will now load without any game data."]},{version:"1.2.1",date:"12/14/2021",changes:["Smelter metals can now be reallocated without unassigning.","Increased accuracy of syndicate intel data","Fixed bug with removing Weak & Bad genes when toggling True Path.","Fixed bug with adding or removing Professors not updating indoctrination value.","Fixed bug with Planet Wiki entry that prevented some data from loading.","Added trait rankings to wiki."]},{version:"1.2.0",revision:"a",date:"12/12/2021",changes:["Fixed bug with Plasmid Storage.","Fixed bug with Befuddle trait and Espionage.","Fixed bug with Composting.","Updated Solar Map.","Added setting to enable mobile device support.","Minor buff to TP Frigate power."]},{version:"1.2.0",date:"12/12/2021",changes:["Unlock the True Path (Requires completion of Ascension or Demonic Infusion).","Using Fanaticism to gain an unempowered trait you already possess will now empower that trait.","Added option to Hell Fortress to prevent using ship crew as reinforcements.","Shrine Metal bonus now applies to Mining Droid Aluminium production.","Armored trait now prevents 50% of deaths.","Cannibalize healing now applies a percent based bonus instead of being equivalent to 3 5% Hospitals.","GruvBox Dark is now the default theme.","Added Evolve Adept Perk.","Themed several additional weapon techs in magic universe for immersion.","Smoldering and Chilled effects now display as Smoldering or Chilled in production breakdowns instead of Hot/Cold.","Improved touch device support."]},{version:"1.1.17",date:"11/28/2021",changes:["Job stress from Civilian Ship Crew is now calculated correctly.","Things will now show as unaffordable if they require a locked resource.","Added new entries to Mechanics section of Wiki: Job Stress, Cost Creep, and Warmonger.","Evolve Novice and Evolve Journeyman perk conditions updated."]},{version:"1.1.16",date:"10/30/2021",changes:["Ghost #3 can now be captured with Smoldering.","Ghost #7 can now be captured in Cataclysm mode.","Updated description of Trick or Treat feat.","Llamas will no longer harass carnivores, detritivores, and soul eaters by grazing their fields."]},{version:"1.1.15",date:"10/20/2021",changes:["Added buttons to pause queues.","Cracked Pylons now correctly add to Mana cap.","Pillar of Bones will no longer be rolled with the Smoldering trait.","Fixed bugs with removing Terrifying trait.","Fixed bug with items in queue blocking the next item when it couldn't be completed due to negative production of a resource.","The Tax-Morale governor task is now slightly smarter."]},{version:"1.1.14",revision:"a",date:"9/30/2021",changes:["Fixed Pylon bug with upgraded save games in Magic Cataclysm runs.","Fixed a Message Log filtering problem where some players might not unlock some options."]},{version:"1.1.14",date:"9/29/2021",changes:["New settings options for message log filters.","Added Cracked Pylons for Magic Cataclysm mode.","Conjuring is no longer researchable in Cataclysm mode.","Challenges section added to Wiki under Gameplay.","Smoldering Gnawer will now consume Stone instead of nothing."]},{version:"1.1.13",date:"9/5/2021",changes:["Expanded Mechanics entries in wiki.","Fixed some errors in wiki prestige calculators.","Added a Custom Lab calculator to wiki under species."]},{version:"1.1.12",date:"8/19/2021",changes:["Training Timer for Military tab.","Draggable config options for Spy Operator.","Bug fixes for log and queue windows."]},{version:"1.1.11",date:"8/12/2021",changes:["ARPA projects now contribute to inflation.","Mercenaries costs are now affected by inflation.","Trade is now affected by inflation.","Casino income is now affected by inflation.","Luxury Goods income is now affected by inflation.","Rescaled inflation levels.","Wheelbarrow achievement now requires $250 billion.","Inflation bug fixes.","New message log filters.","Fixed Luxury Goods tooltip money value."]},{version:"1.1.10",date:"8/8/2021",changes:["Added Inflation Challenge Mode. Requires Scrooge achievement to unlock.","Import/Export race feature added to Ascension lab.","Added merge options for queue.","Available space in queue is now shown.","Added Blackhole + Mass Ejector mechanic entry to wiki.","Fixed some display bugs with Alchemy.","Fixed bug where Protoplasm could be required by some structures late in hell phase."]},{version:"1.1.9",date:"7/7/2021",changes:["Firework festival bug fix for cataclysm mode."]},{version:"1.1.8",date:"7/3/2021",changes:["Added firework festival event (July 4th - July 8th).","Added Copper and Iron settings to Mass Ejector Optimizer task.","Current Quantum Level now shown on Citadel Stations.","Updated wiki prestige calculators.","Added a Quantum Level section to wiki."]},{version:"1.1.7",date:"6/29/2021",changes:["Added a Mass Ejector Optimizer governor task.","Fixed precision error with Tech Scavengers.","Prestige calculators added to wiki.","Progress related event section added to wiki.","Anti-plasmids gained from MAD in antimatter universe are now correctly calculated."]},{version:"1.1.6",date:"6/19/2021",changes:["Solstice event is now easier for less seasoned players.","Wharves are no longer affected by the Nomadic trait.","Decreased cost of Iron Horseshoes."]},{version:"1.1.5",date:"6/16/2021",changes:["Support for String Packs.","Separate research queue behavior option.","Balorg can now use the governor tax task."]},{version:"1.1.4",date:"6/11/2021",changes:["Fixed a bug that would sometimes cause mechs to be constructed without weapons.","Fixed a bug that would cause an open tooltip to change descriptions when a queue item completes."]},{version:"1.1.3",date:"6/7/2021",changes:["Improvements to tooltip reliability.","The first Horseshoes can now be constructed out of Lumber if available as a resource.","Horseshoe pacing updated, see Hooved entry in wiki for expanded information."]},{version:"1.1.2",date:"6/6/2021",changes:["Added Money Reserve % config value to Slave replacement task.","Various special buildings are now dropped from the queue if you remove their required trait.","Spy Operator will no longer attempt espionage against controlled cities.","Fixed many issues with labels not updating"]},{version:"1.1.1",date:"6/5/2021",changes:["Unifying during banana republic now triggers an automatic backup save.","Holding a key multiplier with the queue key will now queue mulitple of a building.","Dealmaker import bonus buffed from 40% to 75%.","Nerfed Beast trait to 8% hunting / 15% windy hunting / 10% soldier training.","Restored Cautious trait to Carnivore genus.","Added Money Reserve % config values to Merc and Spy recruiter tasks.","Horseshoes can now be queued.","Adamantite Horseshoes are now much cheaper.","Changed progression system for Horseshoe costs, will not change to next resource unless it's unlocked."]},{version:"1.1.0",date:"6/4/2021",changes:["Appoint a Governor to help run the everyday tasks, unlock in the CRISPR lab.","Animal genus split into 2 new beast genus: Carnivore & Herbivore.","Carnivore Species: Cath, Wolven, Vulpine.","Herbivore Species: Centaur, Rhinotaur, Capybara.","Cath, Wolven, and Centaur redesigned.","Spire Mech Combat rebalanced.","Titan mechs now have 4 weapon slots and an extra equipment slot.","New Equipment: Jump Jet (All but Heavy & Titan), Battery (Heavy Only), and Targeting Computer (Titan Only).","New Scavenger mech type","Reweighted Angelic genus trait costs.","Major event messages are now shown in a different color from minor ones.","Decreased frequency of minor events.","Smoldering no longer applies to a variety of special resources.","Frenzy renamed to Blood Thirst.","Madagascar Tree achievement now requires inheriting Blood Thirst instead of Carnivore.","Expanded Hell section of Wiki"]},{version:"1.0.43",date:"5/18/2021",changes:["Banana Smoothie will no longer unlock for free in alternate universes.","Added a Spire Floor clear timer for previously beaten monsters.","Gate Turrets now correctly contribute to demon kills."]},{version:"1.0.42",date:"5/4/2021",changes:["Minor bug fixes with new events."]},{version:"1.0.41",date:"5/3/2021",changes:["Added launch day event for May 6th.","New minor event system.","The same event can no longer trigger twice in a row."]},{version:"1.0.40",date:"4/11/2021",changes:["Special event race reskins will now persist after event ends until reset.","Added a warning to Unification tech if playing Banana Republic scenario."]},{version:"1.0.39",date:"4/9/2021",changes:["Added challenge win conditions to planet description popover."]},{version:"1.0.38",date:"4/4/2021",changes:["Fixed a bug that prevented some races from acquiring Egg #3."]},{version:"1.0.37",date:"4/3/2021",changes:["Fixed a bug with unlocking the Egg Hunt feat."]},{version:"1.0.36",date:"4/1/2021",changes:["Fool Feat will automatically upgrade to current challenge level for eligible players."]},{version:"1.0.35",date:"3/31/2021",changes:["Changed Blackhole objective of Banana Republic scenerio from stabilize a blackhole to Expand a blackhole to 12 solar mass without exotic matter.","Fixed Terrifying trade exploit in Banana Republic scenerio."]},{version:"1.0.34",date:"3/28/2021",changes:["Added the Banana Republic challenge.","Tax Riots will no longer cause loss of Artifacts, Blood Stones, and other key resources.","Cancel all routes option for trade screen.","Protests no longer apply their penalty twice.","Minor genetic traits can now be reordered by dragging.","Max trade routes per resource type are now governed by Large Trade and Massive Trade upgrades.","Misc minor bug fixes."]},{version:"1.0.33",date:"3/20/2021",changes:["Enhanced threat assessment for Spire.","Added a Save as File option for exporting game state."]},{version:"1.0.32",date:"3/19/2021",changes:["Unemployment Rework.","Fixed reactivity of some tooltips.","Fixed cut off tooltips on settings tab.","Xeno Tourism now requires 10 Monuments and Tourism."]},{version:"1.0.31",date:"3/15/2021",changes:["Alien 1 system is now named after their homeworld.","Alien 2 system is now named after their red planet.","Fixed various cut off tooltips."]},{version:"1.0.30",date:"3/4/2021",changes:["Wharves once again now grant the correct number of trade routes.","Fixed errors with Casino vault size.","Sacrificed Citizens stat for Mantis players.","Factory production can be assigned without first removing it from Alloy production."]},{version:"1.0.29",date:"2/25/2021",changes:["Evolved species will no longer be stuck in the queue after evolution.","Fixed potential viewport scrolling issues with Settings and Evolution tabs.","Added a warning for users running Evolve in multiple tabs.","The game will now remind players to backup their game data once every 100,000 game days."]},{version:"1.0.28",date:"2/21/2021",changes:["Queue can now be used during evolution stage if unlocked with CRISPR tech.","Fixed incorrect Scarletite costs with Wasteful trait.","Graphene Plants now default to Oil with Smoldering.","Fixed many string errors."]},{version:"1.0.27",date:"2/11/2021",changes:["Added Trade Federation achievement.","Added Mastery section to perks page.","Fixed aria label of jobs.","Squished achievement will now unlock from Blackhole or Demonic Infusion."]},{version:"1.0.26",date:"1/30/2021",changes:["Enhanced crafted material popovers.","Universe filters for wiki achievements page.","Cheese Guide."]},{version:"1.0.25",date:"1/23/2021",changes:["Added Piracy section to Wiki under Gameplay-Mechanics.","Numerous minor bug fixes."]},{version:"1.0.24",date:"1/17/2021",changes:["Evil Smoldering races can now research bone tools."]},{version:"1.0.23",date:"1/16/2021",changes:["Redesigned Heat based Genus mechanics.","Untapped Potential formula changed: now has diminishing returns for stacking unspent genes.","Faith now has an effect on auto crafting (Craftsmen Only).","Added new topics to Mechanics section of Wiki.","Minor bug fixes."]},{version:"1.0.22",date:"1/15/2021",changes:["Fixed Cataclysm mode game start."]},{version:"1.0.21",date:"1/10/2021",changes:["Gain upto 8 hours of accelerated time when game is stopped/closed.","Optimized tab content loading for performance.","Pause game feature."]},{version:"1.0.20",date:"12/29/2020",changes:["Fixed issue with keyup event not releasing multiplier keys."]},{version:"1.0.19",date:"12/28/2020",changes:["Studious now improves library knowledge by 10%.","Merchant now increases the amount of resources gained from trading by 10%.","Tracker raised from 10% to 20%.","Resourceful raised from 10% to 12%.","Claws raised from 20% to 25%.","Apex Predator combat bonus raised from 25% to 30%.","Forge Geothermal power boost raised from +1MW to +2MW.","Beast trait now boosts Hunting by 10% or 20% when windy and improves soldier training time by 20%.","Beast gene point cost changed from 2 to 3 points.","Top level tab quick selection key bindings (default 1-7)."]},{version:"1.0.18",date:"12/24/2020",changes:["Fixed issue with species costs on some techs requiring protoplasm without a reload."]},{version:"1.0.17",date:"12/19/2020",changes:["Larger font size modes.","Added descriptions for city sectors.","Last 3 event messages will now be preserved on reload.","Fixed Evolution bugs with Unbound Infusion active.","Improved timer accuracy of stacked queue items when No Queue Order is used."]},{version:"1.0.16",date:"12/16/2020",changes:["Dark Bomb: Kill and Reset the Demon Lord's accumulated strength using the new Dark Bomb.","Bonus Artifacts can now be earned during Demonic Infusion if Spire floor 50 or 100 are cleared.","Renamed the tech upgrade Purify to Enhanced Air Filters in order to prevent confusion with the Blood Infusion Purify."]},{version:"1.0.15",date:"12/12/2020",changes:["Redesigned Inferno Reactor, output is now tied to Infernal Forge.","Steel can once again be discovered by Ambush attacks.","Power Grid is now shown in Cataclysm.","Cataclysm reset no longer incorrectly grants Rapid Mutation or Ancient Ruins.","Many minor bug fixes."]},{version:"1.0.14",date:"12/8/2020",changes:["Vacuum Collapse no longer removes all charges of Corrupted bonus.","Vacuum Collapse now correctly increases Dark Energy earned on the stats page.","Lumber Ritual is no longer displayed to Evil races.","Multiplier keys now work when hiring mercenaries."]},{version:"1.0.13",date:"12/4/2020",changes:["Power Grid now correctly unlocks when gaining Electricity from Infiltrator trait.","Feats Garbage Pie and Finish Line can now be unlocked by Demonic Infusion."]},{version:"1.0.12",date:"12/4/2020",changes:["MechBay tab improvements.","Mechlist can now be reordered by dragging.","Power Grid can now control On/Off state.","Support type structures can now be controlled by the power grid."]},{version:"1.0.11",date:"12/2/2020",changes:["Fixed a memory leak.","Minor adjustments to GruvBox Dark theme.","Cheesy Goodness."]},{version:"1.0.10",date:"12/1/2020",changes:["Ascended buff now persists after Demonic Infusion.","New Themes: GruvBox Light, GruvBox Dark, and Orange Soda."]},{version:"1.0.9",date:"11/29/2020",changes:["Perks separated on to a separate tab under Stats.","Added Perks section to Wiki."]},{version:"1.0.8",date:"11/28/2020",changes:["Base Neutronium cost of Inferno Reactor lowered to 3,750,000.","Fixed Valdi genus traits after evolution.","Prepared rank 2 now correctly applies when building mechs.","Power Grid is now more strict in checking what is available.","Fixed bug that sometimes caused crafting to use a wrong Mastery value."]},{version:"1.0.7",date:"11/25/2020",changes:["Fixed a bug where Technocracy prevented Alien 2 & Chthonian invasions from working."]},{version:"1.0.6",date:"11/24/2020",changes:["Fixed Mechlab quick switch button.","Titan class mech power increased by 12.5%."]},{version:"1.0.5",date:"11/22/2020",changes:["Adjustable Power Grid","Light Theme bug fixes."]},{version:"1.0.4",date:"11/21/2020",changes:["Gains from Alchemy are now higher.","Any mixed fleet can now invade the Alien 2 and Chthonian systems as long as the invasion force is strong enough.","Alien 2 Invasion requires minimum of 400 fleet rating and at least 650 to take no losses.","Chthonian Invasion requires a minimum 1250 fleet rating, 2500 for average losses, and 4500 for minimum losses."]},{version:"1.0.3",date:"11/15/2020",changes:["Fixed compost heap values.","Added combat section to the wiki under gameplay.","Added Equilibrium feat for pillaring every species.","The Misery feat can now be earned from Demonic Infusion."]},{version:"1.0.2",date:"11/10/2020",changes:["Valdi now take your chosen Genus instead of humanoid.","Wrath Blood Infusion now properly applies to all Mech fights.","Artifacts can now be spent properly on the CRISPR tab.","Crystal trade prices adjusted.","Megalith base price reduced from 100k to 55k.","Many minor bug fixes."]},{version:"1.0.1",date:"11/08/2020",changes:["Fixed display bug with CRISPR costs and Technocracy.","Fixed issue with some Windmills not producing power.","The Resort now properly formats its vault size."]},{version:"1.0.0",date:"11/07/2020",changes:["Expanded Interdimensional content, delve deep into the hell dimension.","New Magic Universe.","Fling asteroids into the blackhole with the Asteroid Redirect ARPA project.","The same monument type will no longer be chosen twice in a row.","Evil races can now construct a Pillar of Bones monument type.","Democracy now only affects Entertainers.","Some government bonuses now scale with tech era.","Races with Detritivore can now build Windmills.","Base Aluminium income for plant based species is now roughly 10% higher.","Beast of Burden now grants an extra loot roll instead of a 10% boost.","Revamped combat loot formulas.","Build queue resource highlighting.","Low Contrast Dark Night Theme.","Ewnay igpay atinlay anguagelay."]},{version:"0.9.24",date:"11/1/2020",changes:["Holiday icons from feats earned with no stars can now be accessed.","Challenge feat icons still require at least 1 star."]},{version:"0.9.23",date:"10/30/2020",changes:["New settings option for people who hate fun.","Added ability for an obscure combination of settings and racial traits to get Ghost #3"]},{version:"0.9.22",date:"10/28/2020",changes:["Halloween cosmetic effects will now run for the duration of the Trick or Treat event instead of just on Halloween.","Ents, Dryads, and Salamanders can now find all the Ghosts.","A certain Ghost is now easier to obtain in Cataclysm.","Accessibility improvements for the event."]},{version:"0.9.21",date:"10/27/2020",changes:["Trick or Treat Event, runs from 10/28 - 11/4."]},{version:"0.9.20",date:"10/16/2020",changes:["Fixed bug with the holy trait that improperly applied its bonus."]},{version:"0.9.19",date:"9/1/2020",changes:["Swarm Control AI now provides a base increase of +2 before unlocking Quantum Computing.","Fixed bugs with manual crafting popover.","Fixed bug that stopped DNA & RNA generation during evolution if the Cataclysm scenario was toggled on."]},{version:"0.9.18",date:"8/28/2020",changes:["ARPA Queue timer fixes.","Swarm Control AI upgrade now make Control Stations scale with Quantum level."]},{version:"0.9.17",date:"8/22/2020",changes:["Fixed bug that prevented Cataclysm Ascension from completing.","Rank 1 sacrifice is slightly less effective","Rank 3 sacrifice is significantly more effective","New Research is now shown by Era."]},{version:"0.9.16",date:"8/12/2020",changes:["Bug Fixes by Beorseder:","Fixed issue where Exotic Materials Lab and Fortifications would clear current queue.","Fixed Scavengers not working during Cataclysm.","Fixed display bug with Galactic Exchange during Cataclysm.","Genomic Mutations no longer give the wrong number of Genes without Synthesis upgrades.","Genomic Mutations now tell how many Plasmids/Antiplasmids are gained from them.","Techs now display their requirements on the wiki."]},{version:"0.9.15",date:"8/10/2020",changes:["Tax revolts can no longer destroy Soul Gems.","If you lose your sample of Elerium before researching Elerium Mining it will now be replaced."]},{version:"0.9.14",date:"8/9/2020",changes:["Angelic races now have an innate bonus vs demonic creatures.","Enhanced Muscle Fibers added to perks page.","Genome sequencing will now be off by default in Cataclysm.","Reorganized achievements page in Wiki."]},{version:"0.9.13",date:"8/6/2020",changes:["Special resource descriptions now update."]},{version:"0.9.12",date:"8/3/2020",changes:["Added Crossed the Finish Line feat for Ascending with Cataclysm.","Adjusted many post World Collider Cataclysm things that referenced none existent planetary structures.","Added a fix for Stabilize Blackhole being stuck in an untriggerable state.","Upgrading achievements will now send a notification."]},{version:"0.9.11",date:"8/1/2020",changes:["Fixed a bug that caused Factories to charge the wrong amount of Polymer for producing Synthetic Furs."]},{version:"0.9.10",date:"7/30/2020",changes:["Expanded list of potential enemy city names.","Added Synthetic Fur option to Factories.","Restoring a backup after a Cataclysm will now allow you to Cataclysm again.","Fixed Lumber penalty on Desert worlds.","Many minor bug fixes."]},{version:"0.9.9",date:"7/21/2020",changes:["Added Devotion upgrade to ancients CRISPR line between Faith and Acolyte. The total cost is the same, it's just spread out more.","Players with Ancients 4 are granted Ancients 5 automatically, those with Ancients 3 are refunded 300 Plasmids.","Added Enhanced Muscle Fiber CRISPR upgrade.","High tax morale penalty under Oligarchy is now reduced.","Fixed bugs with Blackhole reset and restoring backups.","Fixed bug with adjusting taxes as a Noble race that would set it to the max."]},{version:"0.9.8",date:"7/18/2020",changes:["Czech translation by Mousesama","The slaves have staged a successful hunger strike to demand better living conditions, as a result slave pens can now only hold 4 slaves each.","Autocracy and Frenzy no longer block Immoral races from gaining a Warmonger bonus.","Geology traits now display under planet information.","Popovers added to building and research queues."]},{version:"0.9.7",date:"7/13/2020",changes:["Seasons no longer exist in Cataclysm mode.","It is no longer Sunny in Cataclysm mode.","Parasites are no longer unable to grow population in Cataclysm mode, but they do take a growth penalty.","Base Sawmill effect is now separated from lumberjack in production breakdown."]},{version:"0.9.6",date:"7/10/2020",changes:["Fixed bug with Infiltrator not unlocking Nanoweave.","Fixed bug with Railways not adding traderoutes correctly in Cataclysm mode."]},{version:"0.9.5",date:"7/6/2020",changes:["Fixed a bug that occurred when combining the Terrifying trait with the gold star Iron Will perk."]},{version:"0.9.4",date:"7/3/2020",changes:["Failed History perk raised from +1 Geothermal to +2 Geothermal energy.","Fixed Oligarchy tax riot immunity between 36%-45%.","Infiltrator can now steal Graphene Processing, Nanoweave, and Orichalcum Analysis techs."]},{version:"0.9.3",date:"7/1/2020",changes:["Increased base number of Plasmids earned in Cataclysm mode."]},{version:"0.9.2",date:"6/30/2020",changes:["Added Restore Backup option, restores game to just before your last prestige reset.","Extended Recombination CRISPR line.","When gaining a random minor trait from Fanaticism, you will now gain 5 ranks of it."]},{version:"0.9.1",date:"6/21/2020",changes:["Fixed Dyson Net."]},{version:"0.9.0",date:"6/21/2020",changes:["Added Scenarios Section to Evolution Challenges.","Added Cataclysm Scenario for those who value science over caution.","Genetic Dead End is now classified as a Scenario.","Plant genus redesign. Photosynth trait replaced with Sappy.","Added 3rd race option for Plant genus: Pinguicula.","Dyson Net now provides partial power as it is constructed.","Added Orichalcum upgrade for Dyson Sphere.","Added Xeno Tourism upgrade.","Added Fertility Clinic upgrade for Hospitals.","Added OTB, Online Gambling, & Bolognium Vault upgrade for Casinos.","Added Scrooge achievement.","Added Soul Link upgrade for Soul Forge/Soul Attractors.","Reduced Bolognium cost of Freighters & Corvette Ships.","Increased rating of Corvette Ships to 30.","Piracy will no longer start until after you construct the Embassy.","Reduced power requirement of Soul Forge and Soul Attractor.","Gun Emplacements and Soul Attractors are now more potent.","Reduced requirement of Demon Slayer feat to 666 Million demon kills."]},{version:"0.8.17",date:"5/30/2020",changes:["Added 3rd race option for Fungus genus: Moldling.","Fungi genus Spore trait replaced with Detritivore.","Casinos now start powered and generated money immediately.","Extreme Dazzle upgrade now boosts Casino income by 50%.","Reduced power requirement of Casino by 1.","Casino Max Morale boost no longer works unless casino is powered.","Occupation will now unlock Federation research.","Added Double Density achievement in heavyverse.","Stoned penalty on mellow planets raised to 10%.","Unemployed citizens on mellow planets no longer generate any stress (note: hunters are NOT unemployed).","Life on mellow planets is now overall less stressful.","Slaver trait rating raised to 12.","Barracks can now be switched off.","Space Stations will now automatically staff Space Miners from the default job when constructed.","Factories now default to producing Alloy instead of Nothing."]},{version:"0.8.16",date:"5/8/2020",changes:["Oceanic biome now applies a 6% bonus to Titanium from Steel smelting.","Oceanic biome now applies a 12% bonus to Titanium from Iron smelting.","Oceanic biome now applies a 5% penalty to Fur generation.","Tundra biome now applies a 25% bonus to Fur generation.","Tundra biome now applies a 10% penalty to Oil generation.","New planetary modifiers: Elliptical, Flare, Dense, and Unstable.","Oligarchy tax riot immunity raised from 35% to 45%."]},{version:"0.8.15",date:"5/2/2020",changes:["Grassland biome Food bonus raised to 20%.","Forest biome Lumber bonus raised to 15%.","Desert biome now applies a 25% Lumber penalty.","Desert biome now gives a 20% stone bonus and a 10% Oil bonus.","Volcanic biome now applies a 10% Food penalty.","Volcanic biome now gives an 8% Iron and 12% Copper bonus.","Added partial Korean translation.","Achievements in the wiki are now sorted Alphabetically.","Some achievements now show completion progress in the wiki."]},{version:"0.8.14",date:"4/30/2020",changes:["Post unification Federation now gives a 32% bonus (raised from 30%).","Federation now increases morale by 10%.","Socialist factory bonus is now 10% (raised from 5%).","Socialist crafting bonus is now 35% (raised from 25%).","Corpocracy factory bonus is now 30% (raised from 20%).","Corpocracy factory bonus now applies to Cement, Graphene, and Vitreloy.","Republic now increases morale by 20%.","Oligarchy tax revenue penalty is now 5% (lowered from 10%).","Oligarchy can now set taxes 20% higher then other governments (raised from 10%).","Technocracy now adds a 10% Knowledge gain bonus.","Autocracy governments are now immune to the warmonger penalty.","Priests now apply a bonus to Ziggurats under Theocracy.","Fixed display of Theocracy effect on temples. This gives a 12% bonus but was only displaying as a 5% increase.","Noble Oligarchy can now set their taxes as high as 40%."]},{version:"0.8.13",date:"4/29/2020",changes:["New research is now sorted by knowledge cost.","Added popover descriptions for prestige resources.","Harmony Crystals now boost standard Dark Energy by 0.1% instead of 0.01%.","Lots of minor bug fixes."]},{version:"0.8.12",date:"4/24/2020",changes:["Farming has been redesigned. Farms no longer directly generate food, Farmers now generate food in combination with Farms.","Added Energizer Feat for ascending without building any Thermal Collectors.","Bad traits no longer count for Ascension Species Creator complexity.","Dreaded Achievement will now unlock if you never researched dreadnoughts.","Fixed issue with some feats spamming the log due to micro achievements.","Fixed base training rate of soldiers.","Fixed bug with diverse trait that made it do the opposite of what it was suppose to do.",'Adjusted color of "purple" text on Night theme.',"Kilowatts are now Megawatts."]},{version:"0.8.11",date:"4/16/2020",changes:["Ascension reset no longer offers planet choices, instead your next race is created on the old planet with bonuses added to that planet.","Ascended planets now gain +2% to all geology deposits, +5% production, +10% storage, and +2 Sundial base Knowledge gain.","Unspent gene points in the Ascension Lab will be converted into Untapped Potential.","Ascension lab now has a complexity gene tax for adding more then 4 traits.","Technophobe perk now applies an additional bonus to custom race complexity.","Paranoid and Hoarder can now be combined.","Over capped slaves will now be released."]},{version:"0.8.10",date:"4/13/2020",changes:["Added EM (Electromagnetic) Field Challenge."]},{version:"0.8.9",date:"4/12/2020",changes:["Added a Feat for finding all the Eggs.","Current egg count can now be checked in the Wiki."]},{version:"0.8.8",date:"4/12/2020",changes:["Easter Event Activated","Event ends 10 days after the start of Easter."]},{version:"0.8.7",date:"4/11/2020",changes:["Fixed Pathetic trait."]},{version:"0.8.6",date:"4/11/2020",changes:["Fixed Brute trait.","Added section for Achievements and Feats to Wiki."]},{version:"0.8.5",date:"4/11/2020",changes:["Added New Work in Progress Game Wiki","Sentience is now more likely to grant a species where the extinction achievement has not yet been earned.","Sentience can now include custom races.","Incorporeal Existence research now costs Phage instead of Plasmids.","Ascension research now Plasmids instead of Phage.","The change log is now part of the Wiki."]},{version:"0.8.4",date:"4/4/2020",changes:["Fixed breaking bug with Rigid trait."]},{version:"0.8.3",date:"4/3/2020",changes:["Federation now reduces the soldier requirement of occupied cities by 5.","Fixed incorrect Industrious string."]},{version:"0.8.2",date:"3/30/2020",changes:["Piracy in the Gateway and Stargate regions ramp up more slowly as you explore Andromeda.","Fixed formatting of multiline Crafting Tooltip cost display.","Fixed incorrect string used by completed Dyson Sphere."]},{version:"0.8.1",date:"3/29/2020",changes:["Piracy now slowly takes effect in the Gateway System and Stargate region over 1000 days after piracy begins.","Purchasing Negotiator and levels of Persuasive will now update the regular Market as well as the Galactic Market.","Added new CRISPR upgrade effects from the Challenge, Ancients, and Trader trees to the perks list.","Queued Monuments will update their name in the queue when a Monument is constructed.","Fixed bug where ARPA projects at the end of the Queue while No Queue Order was active would cause No Queue Order to not work as intended.","The name of the trait gained from a Mutation in the message is now localized.","Adding Apex Predator will remove currently obtained Armor techs.",'Annexed/Purchased powers will now have a respective " - Annexed"/" - Purchased" tag next to their name, like Occupied powers do.',"Blackhole reset gives its proper reward again.","The amount of Gene/Phage levels of Minor Traits purchased is now affected by Multiplier Keys.","The amount of Ships moved from one area to another is now affected by Multiplier Keys.","Manual Crafting button tooltips are more informational.","Constructing the first Foundry of a game will log a message briefly explaining what Crafted Resources are and the ways to make them.","Informative messages (mission results, messages that explain newly unlocked mechanics, the Launch Facility message that informs the player of the space tab, etc.) are now displayed in blue, to separate them from less important messages.","Added the missing Wormhole Mission result string."]},{version:"0.8.0",date:"3/27/2020",changes:["Intergalactic Content.","Universe Mastery Rework.","-Each Universe now tracks its own mastery level responsible for 40% of the mastery bonus, the remaining 60% comes from the general mastery level.","-Standard Universe mastery rules remains unchanged.","Micro icons can now be earned for none Micro achievements. These will not count for standard mastery, only Micro mastery.","Unification 3.0, the unification system has been reworked.","Federation Government type.","New Faith CRISPR line of upgrades, unlocks priest job.","Universal, Standard and Mastered CRISPR Upgrades, for masters of the universes.","Added Negotiator CRISPR upgrade.","Added Persuasive Minor Gene.","Extended the Deify and Study Ancients tech trees.","Enhanced Droids upgrade for War Droids.","Repair Droids for Fortress.","Smoldering and Chilled now have reduced effectiveness after 100 stacks.","Removed Heavy Genus Feats, these were redundant with Universe Icons.","Blackhole reset now also grants species level extinction achievement.","Power cost of Mass Ejector increased to 3kW.","Genetics lab custom mutation costs rescaled to static values depending on the genetic trait.","Colonists will now be automatically assigned when a Living Quarter is completed if the default job has any available citizens.","Biodome redesigned, produces less food but increases living quarter capacity for Citizens.","More robust research categories.","Various racial traits now apply to ARPA projects.","Human Creative trait rescaled.","Large cost creep penalty reduced to 0.005 from 0.01.","Strong gathering bonus increased from 2 to 5.","Compact lowered from -0.02 to -0.015."]},{version:"0.7.28",date:"3/16/2020",changes:["Antimatter Universe now gives a 10% prestige bonus post MAD.","St. Patrick's Day event.","Blood War can no longer be earned by none demonic evil races.","Build Crate/Container buttons now update create/container values when upgraded by research."]},{version:"0.7.27",date:"3/10/2020",changes:["Memory leak fixes."]},{version:"0.7.26",date:"3/5/2020",changes:["Any race where the associated extinction achievement has been unlocked is now always available during evolution.","Joyless perk changed to +2% Max Morale per star level.","The effects of the Mass Extinction and Creator perks have been swapped.","Creator perk (old mass extinction) changed to 1.5x / 2x / 2.5x / 3x / 3.5x genes gained on mutation.","Minor traits bought with Phage now count twice when you complete evolution."]},{version:"0.7.25",date:"2/26/2020",changes:["Unicorn Shrine bonus is now determined by the moon phase when constructed.","Shrine Knowledge bonus now applies an additional affect to universities.","Smelters in Evil universe when using Kindling Kindred default to Flesh instead of Coal.","Evil Wendigo Smelters correctly display that they use 1 Flesh/s instead of 3 Souls/s. Also fixed the bug where they end up using 3 Flesh/s instead of 1.","Fixed bug where the Evil Wendigo Reclaimer description would show the Lumberjack description.","If Containers have not yet been unlocked as a resource, getting a Wharf will unlock it.","Fixed bug where, if Freight Trains was gotten after ARPA, the Railway project would need a refresh to appear."]},{version:"0.7.24",date:"2/12/2020",changes:["Special Prestige icons awarded to players from certain feats can now be set to replace the standard Star icon."]},{version:"0.7.23",date:"2/11/2020",changes:["Steelen Challenge now requires Bioseed as its win condition.","Added Feat for Blackhole reset with Steelen Challenge.","Added V-Day Event stuff."]},{version:"0.7.22",date:"2/9/2020",changes:["Steelen Challenge.","Graveyards are now removed upon gaining Kindling Kindred.","If Default job is set to Farmer/Lumberjack for Carnivore/Kindling Kindred, it will be changed to Unemployed upon adding those traits.","Fixed bug where gaining Carnivore and having no Grain Mills would make Smokehouses unpurchasable until refresh.","Cargo Yard now requires the construction of a Transfer Station to be unlocked.","Mitosis/Metaphase effect now appears on perks list."]},{version:"0.7.21",date:"1/28/2020",changes:["More bug fixes."]},{version:"0.7.20",date:"1/20/2020",changes:["Bug Fixes by Beorseder.","Fixed bug where purchasing Multicellular would double DNA generation from Nuclei instead of Bilateral Symmetry/Poikilohydric/Spores.","New population from the Infectious trait now go into the set Default job, instead of always Unemployed.","Controlled Mutation will no longer offer conflicting traits."]},{version:"0.7.19",date:"1/14/2020",changes:["Bug Fixes."]},{version:"0.7.18",date:"1/12/2020",changes:["Theocracy temple bonus raised from 5% to 12%.","Technocracy knowledge discount raised from 5% to 8%.","Corpocracy Casino Bonus raised from +100% to +200%.","Corpocracy Luxury Good Bonus raised from +50% to +150%.","Corpocracy Tourism Bonus raised from +50% to +100%.","Corpocracy morale penalty lowered from -15% to -10%.","Corpocracy Manufacturing Bonus raised from +15% to +20%.","Miner's Dream now scales the information that is revealed depending on the star level of the achievement.","Slaves now appear as a resource.","Alternate universes now award icons for complex achievements."]},{version:"0.7.17",date:"1/9/2020",changes:["Fixed an issue with displaying foreign powers in civics tab on unlock."]},{version:"0.7.16",date:"1/8/2020",changes:["Exploration Missions can be queued again.","The game will now notify the user if the current version is out of date.","Changes by Beorseder.","Geology deposit aesthetic changes on planet selection.","Miner's Dream Achievement & Perk."]},{version:"0.7.15",date:"1/7/2020",changes:["Queueing the World Collider will no longer lag the game.","Multi-segment projects will now have extra segments cleared from the queue on completion.","Spy and Government related popovers that would sometimes get stuck open will now clear.","Queued projects that will not complete due to lack of production will now display a green [Never] instead of -1 second timer.","Multi-segment projects no longer block queueing ARPA projects unless they consumed the entire queue space."]},{version:"0.7.14",date:"12/31/2019",changes:["Research Categorization option by Naryl."]},{version:"0.7.13",date:"12/30/2019",changes:["Gene decay will no longer result in a negative plasmid count.","Gene fortification is slightly more effective."]},{version:"0.7.12",date:"12/19/2019",changes:["Gene Fortification.","Fixed Cultural Supremacy popover."]},{version:"0.7.11",date:"12/15/2019",changes:["Decaying resources will now use a warning color if you are losing that resource but at a slower rate then the decay rate.","The most bottlenecked resource will now display in red while other trouble resources will be marked with an alert color.","CRISPR upgrades are now darkened when unaffordable.","Transfer Station now lists its uranium storage.","Wendigo bug fixes."]},{version:"0.7.10",date:"12/12/2019",changes:["Craftsman now continuously output product instead of once/twice a month.","Cumulative achievements now check for lower tier unlocks."]},{version:"0.7.9",date:"12/7/2019",changes:["Many bug fixes."]},{version:"0.7.8",date:"12/6/2019",changes:["The default job can now be set to: Unemployed, Farmer, Lumberjack, Quarry Worker, or Scavenger.","New line of feats for achievement hunting.","Novice Perk.","Journeyman Perk."]},{version:"0.7.7",date:"12/5/2019",changes:["Super projects now queue in larger batches.","Super projects now only report completion by the queue if actually complete instead of for each segment constructed."]},{version:"0.7.6",date:"12/2/2019",changes:["Adjacent queue items of the same type will now combine.","Architect now doubles queue sizes instead of adding a flat +2.","Misc minor bug fixes."]},{version:"0.7.5",date:"11/28/2019",changes:["Queueing 2x or more of the same building in a row will now stack them in the queue.","Queue timer now adjusts for cost creep.","ARPA Projects can now be queued.","Fixed a bug that could break the game when Yeti or Wendigo unlocked the genetics lab."]},{version:"0.7.4",date:"11/27/2019",changes:["Wendigo can now build hunting lodges.","Trade route prices are now tracked to 1 decimal.","Elusive spies will no longer be killed when they fail a mission.","Disruptor Rifles now require researching Quantum Entanglement."]},{version:"0.7.3",date:"11/26/2019",changes:["Night Theme trade volume control made more night theme friendly.","Contrast improvements for Night and R/G Theme."]},{version:"0.7.2",date:"11/24/2019",changes:["New market buy/sell volume control.","Large Trade upgrade now raises the buy/sell cap to 5,000.","Massive Trades upgrade now raises the buy/sell cap to 1,000,000.","Various bug fixes by Beorseder."]},{version:"0.7.1",date:"11/23/2019",changes:["Garrison controls reintegrated into government section.","Mutation plasmids now track correctly in no plasmid challenge runs.","Fixed many issues with foreign power name generation.","Feat star icon is no longer tiny."]},{version:"0.7.0",date:"11/21/2019",changes:["Establish a Government.","Battle rival cities.","Biome races added for Forest, Desert, Tundra, and Volcanic.","New ARPA Project: Railway.","New CRISPR upgrades: Mitosis & Metaphase.","Construct advanced AI stations in deep space.","Rapid Gene Sequencing upgrade.","Civics tab split into Government, Industry, and Military sections.","Inspiration no longer adds an upfront knowledge bonus.","Vigilante requirement lowered to 12.","Xenophobic replaced with Wasteful.","Added Rocky Road Feat.","Configurable number notations."]},{version:"0.6.27",date:"11/12/2019",changes:["Tundra planets are now always cold in winter.","Volcanic planets are now always hot in summer.","Stormy planets are now more likely to be windy.","Fixed issue with last rites not showing up as affordable.","2-4x Challenge Multipliers changed:.","2 Challenges: +12% Prestige.","3 Challenges: +25% Prestige.","4 Challenges: +45% Prestige.","Heavy Universe prestige bonus now scales with challenge level:.","0 Challenges: +5% Prestige.","1 Challenge: +10% Prestige.","2 Challenges: +15% Prestige.","3 Challenges: +20% Prestige.","4 Challenges: +25% Prestige."]},{version:"0.6.26",date:"11/7/2019",changes:["ARPA costs now update without mousing off and back on the buttons.","Fixed issues with incorrectly powering on newly built structures.","None-demonic evil smelters now correctly state they burn 1 flesh/s.","Added whitehole perk to stats page."]},{version:"0.6.25",date:"11/2/2019",changes:["Geology bonus is now preserved on MAD reset.","Key Mappings are now configurable for multiplier and queue keys."]},{version:"0.6.24",date:"10/31/2019",changes:["The Halloween feat will now unlock inside a micro universe."]},{version:"0.6.23",date:"10/28/2019",changes:["Exotic mass now counts towards Galactic Landfill and Supermassive.","Fixed issues with queue timers and kindling kindred trait.","Dark Energy now applies to windmills in antimatter universe."]},{version:"0.6.22",date:"10/26/2019",changes:["Game optimizations.","Bug fixes for queues.","Fixed bug with war droids."]},{version:"0.6.21",date:"10/24/2019",changes:["Freight Train upgrade now adds a trade route to freight yards instead of trade posts.","Toxic troll achievement.","Spatial reasoning rounding fix."]},{version:"0.6.20",date:"10/21/2019",changes:["Fixed application of plasmids with antiplasmids.","Updated description of bleeding effect.","Added achievement for synthesizing an anti-plasmid.","More readable achievement page."]},{version:"0.6.19",date:"10/20/2019",changes:["Fixed power errors with hell dimension turrets.","Crate/Container rounding is now applied after spatial reasoning.","Added extra text to the asteroid belt description to call out the necessity of assigning space miners.","Evil Ents can now burn flesh in the smelter."]},{version:"0.6.18",date:"10/16/2019",changes:["Swarm Satellite redesign.","Swarm Satellites cost and output decreased.","Control Stations can now control 10/18 swarm satellites.","Iron mining ship swarm plant discount now applies to all swarm plant costs.","New upgrades to increase output of swarm satellites."]},{version:"0.6.17",date:"10/14/2019",changes:['"Q" key now works with research queue.',"Added settings option to not enforce queue order.","Decay challenge no longer shows the star level for Joyless.","All universe types can now be seen on achievements.","Genus completion is now marked on sentience.","Challenges can now be toggled during evolution.","Inspiration event now gives a temporary buff to all science production.","Added Slave Market for slaver races to buy slaves as an alternative to catching them.","Added Crate/Container storage amount to the build crate/container tooltip.","Added a button to cancel all trade routes for each resource."]},{version:"0.6.16",date:"10/13/2019",changes:["Employment is now color coded depending on staffing levels.","GPS satellites now add additional trade routes.","Added stats tracking on reset mechanics used.","Added a message when completing the launch facility.","Added icons to challenges and races in evolution stage to indicate level of challenge completion."]},{version:"0.6.15",date:"10/11/2019",changes:["Added a settings option to disable the queue hot key.","The queue hot key is now disabled by default because it breaks the game for some users."]},{version:"0.6.14",date:"10/9/2019",changes:["Fixed several bugs with celestial races.","Only one demonic invasion event is now required to reach a hellscape planet.","New city categorization can now be switched off in the settings tab.","Holding Q while clicking a building will now queue it instead of constructing it."]},{version:"0.6.13",date:"10/7/2019",changes:["Fixed bioseed reset bug when seeding from a planet without a special property."]},{version:"0.6.12",date:"10/6/2019",changes:["Added a hire merc option to fortress, mercs hired here go directly to the fortress.","Default patrol size is now 10 instead of 4.","Adjusted margins in city tab/space tabs to slightly reduce vertical scrolling.","New Tower of Babel flair."]},{version:"0.6.11",date:"10/5/2019",changes:["New planetary modifiers: Toxic, Mellow, Rage, Stormy, Ozone, Magnetic, and Trashed.","City Categorization by NotOats.","Chinese Translation."]},{version:"0.6.10",date:"10/1/2019",changes:["Fixed issue with gene editing costing the wrong type of Plasmid.","Fixed Bone label in Graphene plant.","Fixed issue with Plywood not unlocking when removing Kindling Kindred trait."]},{version:"0.6.9",date:"9/30/2019",changes:["Antimatter Universe.","Bleeding Effect line of CRISPR upgrades, requires Anti-Plasmids to unlock.","Balorg can now unlock queues.","Fixed aria labels in mass ejector."]},{version:"0.6.8",date:"9/24/2019",changes:["Queue reordering no longer swaps the dragged item with the one in the target spot.","Added timers to research queue.","Cost adjustments are now applied to queue timers increasing their accuracy."]},{version:"0.6.7",date:"9/24/2019",changes:["Cath windmills now generate power instead of just looking pretty.","Fixed Spanish strings file, language now loads again."]},{version:"0.6.6",date:"9/23/2019",changes:["Added special tech tree to sacrificial altar to boost its effectiveness per sacrifice.","Restored windmills to cath.","Challenge Multiplier Dark Energy rounding calculation fixed.","Added extra information to blackhole description when it reaches destabilization point.","Added a warning to stabilize option that it will reset your exotic matter."]},{version:"0.6.5",date:"9/21/2019",changes:["Fixed display issue with frenzy appearing to never drop below 1%.","Updated the tooltip values on farms and farmers to include the hellscape penalty.","Fixed Evil Ents so they start with Gather Stone option."]},{version:"0.6.4",date:"9/19/2019",changes:["Fixed double windmill issue with evil universe races.","Spanish language updates.","Added warnings to challenge modes in micro universe that you will not receive credit."]},{version:"0.6.3",date:"9/17/2019",changes:["Restored broken perks."]},{version:"0.6.2",date:"9/17/2019",changes:["Bug Fixes."]},{version:"0.6.1",date:"9/17/2019",changes:["Universe Update, explore ~~ 4 ~~ 3 new universe types:.","Heavy Gravity Universe.","Micro Universe.","Evil Universe.","New Decay Challenge.","Antimatter universe is still forming, coming soon.","Dark Energy effects added, unique per universe type.","New Plasmid scaling formula.","Blackhole mass added to Stellar Engine.","Stuff I probably forgot about."]},{version:"0.5.18",date:"9/11/2019",changes:["Spanish translation provided by RanaPeluda.","Fixed Ent fanaticism.","Modals are no longer unnecessarily wide.","Smelter modal now shows the fuel production for each type."]},{version:"0.5.17",date:"9/5/2019",changes:["Mantis Frail trait replaced with new Cannibalize trait, eat your own citizens for buffs.","The Fortress will now remember the number of troops assigned to it and attempt to keep it at that level."]},{version:"0.5.16",date:"9/3/2019",changes:["Made some adjustments to Soul Gem drop odds.","Added a message when you discover your first Soul Gem."]},{version:"0.5.15",date:"9/1/2019",changes:["Portuguese translations updated by Rodrigodd."]},{version:"0.5.14",date:"9/1/2019",changes:["Buildings will no longer be added to the queue if holding down a multiplier key.","Fixed a problem with smelters that could cause their production to become stuck in a high state.","Fixed initial display state of containers in storage management tab."]},{version:"0.5.13",date:"8/30/2019",changes:["New layout for selecting challenge genes/modes during end of evolution stage.","Fixed bug with low support elerium miners that caused them to miscalculate miner outputs.","Added a threat level warning to fortress."]},{version:"0.5.12",date:"8/30/2019",changes:["Pacifist Achievement is now unlocked by unifying without ever initiating an attack."]},{version:"0.5.11",date:"8/28/2019",changes:["Fixed issue with nucleus DNA bonus not applying from correct cell stage evolutions.","Building timers now count down without refreshing the popover.","Long action titles will now wrap instead of overflowing the button.","Fixed a bug that could cause the research queue to clear items from the building queue."]},{version:"0.5.10",date:"8/28/2019",changes:["Fixed bug with some construction projects not refreshing the page after being built with the queue.","Space exploration missions can no longer be queued more then once at a time.","One off projects are now removed from the queue if completed manually.","Queue timers now track crafted resources.","Demonic attractor soul gem drop rate increase buffed from 5% to 8%.","Updated some fortress related tooltips.","Mousing over the star rating in the top left corner now lists which challenges are active.","Time until ready added to unaffordable actions."]},{version:"0.5.9",date:"8/27/2019",changes:["Active build queues wiped due do internal game breaking format change."]},{version:"0.5.8",date:"8/27/2019",changes:["Construction timers added to build queue.","Construction and research completed by queues are now logged to the message list.","Improved drag and drop support for queues."]},{version:"0.5.7",date:"8/25/2019",changes:["Drag support for queue sorting.","Fixed resource display bug that occurred when buying a mass ejector.","Minor traits now show the number of ranks from phage or genes spent."]},{version:"0.5.6",date:"8/23/2019",changes:["Building queue now works in space.","Added a separate research queue.","Fixed rock quarry awarding 4% stone bonus instead of the stated 2%.","Fixed rendering bugs with the blackhole and mass ejector."]},{version:"0.5.5",date:"8/22/2019",changes:["Bug Fixes for queueing system."]},{version:"0.5.4",date:"8/22/2019",changes:["Building Queue system v1.0.","Urban Planning, Zoning Permits, and Urbanization queue related techs.","New CRISPR upgrades for enhanced queueing."]},{version:"0.5.3",date:"8/20/2019",changes:["Stats and Achievements separated into separate sub tabs.","Disruptor rifle upgrade for soldiers.","Mass Ejector can no longer be unlocked before completing the Stellar Engine."]},{version:"0.5.2",date:"8/20/2019",changes:["Fixed misnamed mantis trait key.","Fixed Iron smelter paying out 10x intended amount."]},{version:"0.5.1",date:"8/20/2019",changes:["Disappearing craftsman fix."]},{version:"0.5.0",date:"8/19/2019",changes:["Interstellar space is now unlockable.","Interdimensional travel is now unlockable.","New management tab for Crates & Containers.","Power generation breakdown.","Improved resource breakdown layout.","Leathery trait buffed.","Chameleon trait now adds a combat rating bonus.","Optimistic now also applies to the minimum morale rating.","Smarter Smelter fuel switching.","New CRISPR unlocks."]},{version:"0.4.42",date:"8/16/2019",changes:["Fixed some screen reader issues with the crate modal launch button.","Added a warning to the Genetic Dead End challenge if you are on a hellscape planet."]},{version:"0.4.41",date:"8/15/2019",changes:["Joyless Challenge.","??? - Nothing to see here, move along."]},{version:"0.4.40",date:"8/9/2019",changes:["Changed No Crispr gene into the Weak Crispr gene."]},{version:"0.4.39",date:"8/6/2019",changes:["Genetic Disaster Challenge."]},{version:"0.4.38",date:"8/5/2019",changes:["Special action icon is now properly flagged as a button."]},{version:"0.4.37",date:"7/31/2019",changes:["ARIA Improvements for Factory and A.R.P.A."]},{version:"0.4.36",date:"7/27/2019",changes:["Slow and Hyper traits can now combine.","Added new achievements: Creator & Explorer.","Added perks for Mass Extinction, Creator, and Explorer."]},{version:"0.4.35",date:"7/25/2019",changes:["Centaur can now pick Fanaticism.","Challenge multiplier is now applied to phage gain."]},{version:"0.4.34",date:"7/23/2019",changes:["Fixed SR descriptions of buildings that lack affordability.","Fixed resource highlighting of buildings that have zero costs."]},{version:"0.4.33",date:"7/23/2019",changes:["Fixes for Ent Fanaticism not releasing some resources.","Aria improvements for the smelter modal.","Improved screen reader resource affordability description of buildings/research.","Resource highlighting on structures."]},{version:"0.4.32",date:"7/21/2019",changes:["Balorg slaver trait added.","Ziggurat bonus now applies to the oil extractor.","Geology Oil rich/poor no longer applies to oil extractor.","Added resource alternate row coloring.","Added an affordability hint for screen readers.","Fixed some bugs with awarding a random minor trait from fanaticism.","Dimensional Compression now charges the correct cost."]},{version:"0.4.31",date:"7/20/2019",changes:["Extreme Dazzle casino upgrade.","Metallurgist minor trait, buffs alloy.","Gambler minor trait, buffs casinos.","A.R.P.A. projects now use resource approximations for large numbers.","Cement Factory renamed to Cement Plant to reduce confusion with the regular Factory.","Key multipliers now work inside the factory modal.","Imps and Balorg now have access to advanced crafting tech.","Imps and Balorg now have access to windmills.","Balorg can now set their taxes below 10% and above 30%."]},{version:"0.4.30",date:"7/19/2019",changes:["Portuguese translation by Rodrigodd.","DNA Sequencer upgrade.","Gene Assembly cost increase to 200k.","Synthesis now applies a bonus to auto crafted genes.","Ambidextrous buffed.","Ambidextrous now has a greater effect on auto crafting."]},{version:"0.4.29",date:"7/18/2019",changes:["Genetic modification system, customize your race with minor traits.","Shotgun Sequencing upgrade for genome research.","Randomly gained minor traits will no longer stack unless they have all been unlocked.","Genes are now gained from random mutations.","Synthesis line of CRISPR upgrades.","Satellite and Observatory cost reductions.","Fibroblast minor trait.","Iridium is now unlocked by constructing an iridium mine instead of the moon base.","Helium-3 is now unlocked by constructing a helium-3 mine instead of the moon base.","Genome sequencing now defaults to on when first unlocked."]},{version:"0.4.28",date:"7/16/2019",changes:["Added missing hellscape achievement.","Fixed spatial reasoning and phage interaction.","Fixed warmonger unlocking requirement."]},{version:"0.4.27",date:"7/13/2019",changes:["Added special action description buttons for screen readers."]},{version:"0.4.26",date:"7/12/2019",changes:["Unlocked CRISPR upgrades are now listed as perks.","Control/Shift/Alt click now works with power on and off buttons."]},{version:"0.4.25",date:"7/11/2019",changes:["Quantum Manufacturing upgrade.","Quantum Swarm cost lowered from 465k to 450k."]},{version:"0.4.24",date:"7/10/2019",changes:["Thermomechanics upgrade for alloy production.","Ziggurats unlockable via ancients upgrade.","Cement factory has a more clear label in breakdown lists."]},{version:"0.4.23",date:"7/7/2019",changes:["Resources at the millions breakpoint and above are now shown with 2 significant decimal points.","Reduced the creep cost of Observatory.","Reduced the base knowledge cost of Observatory.","Reduced the Brick cost of Boot Camps.","Evil has been unleashed."]},{version:"0.4.22",date:"7/6/2019",changes:["Fixed issue with having exactly 251 Plasmids that would break your resources.","Fixed issue with planet generation that caused it to always use the same seed."]},{version:"0.4.21",date:"7/6/2019",changes:["Fixed unlocking of mass extinction achievement.","Fixed potential fuel consumption bug with power plants."]},{version:"0.4.20",date:"7/4/2019",changes:["Phage can now be earned from space resets, phage extends the plasmid diminishing return breakpoint.","Dimensional Warping crispr upgrade, applies phages to spatial reasoning.","Added special windmill tech for carnivore path to equalize power grid.","Space Stations now give 5 Elerium storage instead of 4."]},{version:"0.4.19",date:"7/2/2019",changes:["Fixed bugs with the hell planet and gas planet survey mission.","Fixed bug that prevented the planet description tooltip from triggering.","Aluminium now properly requires you to build a metal refinery."]},{version:"0.4.18",date:"7/1/2019",changes:["Planets choice now has more depth to it, each planet can be poor or rich in various resource types.","A mineral poor planet suffers anywhere from 1 to 10% penalty for that resource.","A mineral rich planet gains anywhere from 1 to 20% bonus for that resource.","The fire event no longer triggers for aquatic races.","The first interstellar probe now contributes to the number of potential target worlds.","All interstellar space probe costs are now cheaper."]},{version:"0.4.17",date:"6/29/2019",changes:["Added indication of current challenge level to top bar.","Added H tags for accessibility."]},{version:"0.4.16",date:"6/28/2019",changes:["New Hospital, heals wounded soldiers faster.","New Boot Camp, train new soldiers quicker.","Lowered research cost of Mass Driver from 170k to 160k.","Lowered Iridium cost of Mass Drivers.","Updated Mass Extinction unlock requirement."]},{version:"0.4.15",date:"6/28/2019",changes:["Global bonuses are now multiplicative instead of additive.","Decreased base Elerium cost of Exotic Lab by 4.","Creative trait decreases cost creep instead of providing a flat discount.","ARPA 100% button replaced with remaining percentage value.","New experimental military advice."]},{version:"0.4.14",date:"6/27/2019",changes:["Statues now cost Aluminium instead of Wrought Iron.","Nav Beacon now costs Aluminium instead of Iron.","Helium-3 Mine now costs Aluminium instead of Copper.","Elerium Mining Ship now costs Titanium instead of Iridium.","Iron Mining Ship now costs Aluminium instead of Titanium.","Dimension Compression upgrade now works correctly.","Aluminium can now be looted from battle."]},{version:"0.4.13",date:"6/26/2019",changes:["Aluminium resource added to the game, research Bayer Process to unlock Metal Refinery which in turn unlocks Aluminum.","New Metal Refinery structure for producing Aluminium.","Alloy is now made out of Aluminium and Copper.","Sheet Metal is now made out of Aluminium.","Oil Powerplant and Propellant Depot now cost Aluminium instead of Steel.","Some minor accessibility improvements."]},{version:"0.4.12",date:"6/24/2019",changes:["Blackhole achievement now gives a permanent perk for completing it, the perk strength depends on the achievement level.","Fixed issue with event timer being frozen after changing planets.","Fixed the unlocking of upgraded versions of some achievements.","Cost descriptions now show approximations above 10,000."]},{version:"0.4.11",date:"6/24/2019",changes:["Re-evaluated starvation breakpoint.","Added Infested Terran achievement.","Titanium price is now reset after unlocking Hunter Process.","Resources now have a 25% chance of their market price changing per day, up from 10%."]},{version:"0.4.10",date:"6/23/2019",changes:["Fixed stats tracking on demonic invasions so it actually tracks new invasions."]},{version:"0.4.9",date:"6/23/2019",changes:["Fabrication facilities now increase craftsman cap.","Added stats tracking on demonic invasions.","Detail Oriented buffed to 50% from 33%.","Rigorous buffed to 100% from 66%.","Crafting bonus now shown for each resource.","Temple Faith bonus now applies to crafting in no plasmid challenge mode.","Mastery bonus now applies to crafting."]},{version:"0.4.8",date:"6/22/2019",changes:["Fixed a bug that removed MAD when achieving unification.","Fixed missing options in evolution stage with picking avians after space reset."]},{version:"0.4.7",date:"6/21/2019",changes:["Activating challenge genes now provide a bonus to the number of plasmids earned."]},{version:"0.4.6",date:"6/21/2019",changes:["Reduced Nano Tube and Neutronium costs of bioseeder ship.","Reduced Mythril cost of Space Probes."]},{version:"0.4.5",date:"6/19/2019",changes:["Mastery Bonus now unlockable in CRISPR.","Fixed bug with elerium mining that could cause negative mining when you lacked asteroid miners.","Fixed low power warning not clearing when you have no buildings active.","Fixed Sporgar label of Cottages in Steel & Mythril Beams research.","Gene Mutation research will no longer turn off when you run out of knowledge, instead it will pause.","Human creative trait buffed from 2% to 5%.","Troll regenerative trait buffed to heal 4 wounded per day instead of 2.","Ogre tough trait buffed to 25% from 10%.","Gecko optimistic trait buffed to 10% from 2%.","Arraak resourceful trait buffed from 5% to 10%.","Dracnid hoarder trait buffed from 10% to 20%.","Shroomi toxic trait buffed from 10% to 25%.","Wolven pack mentality trait now applies to apartments.","Reduced Nano Tube cost of Mining Drones."]},{version:"0.4.4",date:"6/18/2019",changes:["Matter compression now applies to Wharves.","Xenophobia now applies to Wharves.","Plasmids earned by mutation now apply to no plasmid challenge run.","Reduced Nano Tube cost of Mining Drones."]},{version:"0.4.3",date:"6/17/2019",changes:["Challenge mode achievement tracking.","Vocational Training for craftsman.","Spelling and grammar fixes.","Fixed incorrect reject unity reward text."]},{version:"0.4.2",date:"6/16/2019",changes:["Added some clarification to breakdown of stress."]},{version:"0.4.1",date:"6/16/2019",changes:["Fixed a bug with factories converted from some pre 0.4.0 save files."]},{version:"0.4.0",date:"6/16/2019",changes:["Space reset option, control the destiny of your next race.","Challenge Modes.","New Stuff to discover.","New Achievements to unlock.","Added missing Cyclops racial trait.","World Domination, maybe.","Added soft reset option."]},{version:"0.3.12",date:"6/11/2019",changes:["Fixed bug with riot event that caused it to trigger on high morale instead of low morale."]},{version:"0.3.11",date:"6/10/2019",changes:["The Gas Moon and the Dwarf planets are now accessible.","New technologies based on new discoveries made in deep space.","Wharves can now be unlocked after discovering oil.","There is now an alternative method of unlocking steel.","Night Theme updated, popovers are no longer bright.","Trade route tooltips now include money being imported or exported.","New crispr upgrades for crafting.","Warmonger achievement requirement lowered from 10% to 8%."]},{version:"0.3.10",date:"6/9/2019",changes:["Added code to fix peculiar failed space launch game state."]},{version:"0.3.9",date:"6/8/2019",changes:["New official Evolve [Discord](https://discordapp.com/invite/dcwdQEr)."]},{version:"0.3.8",date:"6/7/2019",changes:["Fixed a problem with negative craftsman counts that could result from craftsman dying."]},{version:"0.3.7",date:"6/6/2019",changes:["Warmongering is now tracked and high casualties may impact morale.","Depleting the mercenary pool will temporarily increase their cost.","Three new achievements related to war."]},{version:"0.3.6",date:"6/5/2019",changes:["Fixed issue with production breakdowns not showing when income was only produced by trade.","Fixed issue that prevented affordability check from refreshing on space missions."]},{version:"0.3.5",date:"6/5/2019",changes:["Mythril Craftsman now unlock correctly.","Fixed a bug that could pause the game if you ran out of Titanium."]},{version:"0.3.4",date:"6/4/2019",changes:["The Asteroid Belt is now open for business.","Robotics Upgrades.","Automation renamed to Machinery.","Assembly Line upgrade for factory."]},{version:"0.3.3",date:"6/3/2019",changes:["New Orbit Structure: Navigation Beacon.","New Red Planet Structures: Space Control Tower and Space Factory.","Reduced number of monuments required to unlock tourism from 4 to 2.","Cement plant workers now round their contribution to 2 decimal places.","Red planet mining now correctly attributes to the red planet in breakdowns."]},{version:"0.3.2",date:"6/3/2019",changes:["Fixed bug that would let you launch the space missions without the proper resources, this would corrupt your game file and break the game.","Added code to detect games corrupted by the previous bug and fix them.","Fixed Fanaticism bug that wouldn't release lumberjacks when you have ent gods."]},{version:"0.3.1",date:"6/3/2019",changes:["Added building check redundancy to auto correct game states that shouldn't occur anyway."]},{version:"0.3.0",date:"6/2/2019",changes:["Space V1 Update.","This opens the first steps into space exploration, more to come... this is not the end.","Rebalanced storage caps to help the game feel more idle friendly."]},{version:"0.2.70",date:"6/2/2019",changes:["Fixed bug when picking Fanaticism with cath gods that wouldn't release your farmers.","Fixed bug when upgrading weapon technology that wouldn't immediately show the increase in army rating."]},{version:"0.2.69",date:"5/26/2019",changes:["Fixed bug which could let you get free barn or warehouse upgrade by essentially skipping over the tech.","Added aria button roles to many button like elements that were not technically buttons."]},{version:"0.2.68",date:"5/26/2019",changes:["Fixed bug with Rock Quarry that prevented the 2% bonus from working unless you had electricity unlocked."]},{version:"0.2.67",date:"5/24/2019",changes:["Revamp of farmer, lumberjack, and quarry worker jobs. These govern the most basic materials produced and can now assign as many workers as you like to these positions.","Farms now directly produce food instead of determining farmer cap.","Lumber Yards now increase lumber production instead of governing lumberjack cap.","Rock Quarry now increase stone production instead of governing quarry worker cap.","Sawmill powered on bonus reduced from 5% to 4%.","Rock Quarry powered on bonus reduced from 5% to 4%.","Stock Exchanges no longer cost Knowledge.","Fixed a display bug that could cause farmers to falsely show they produced more food then they actual did."]},{version:"0.2.66",date:"5/22/2019",changes:["Added alternate row coloring to the market to help distinguish rows."]},{version:"0.2.65",date:"5/21/2019",changes:["Sporgar race redesigned into a parasitic race that spreads through infecting victims."]},{version:"0.2.64",date:"5/20/2019",changes:["Currency is now required before unlocking Basic Storage.","Primitive Axes are no longer gated behind Basic Storage.","Foundry now requires Metal Working to unlock and no longer requires Cement.","Research tab now defaults back to new when resetting.","Fixed issue with not being able to buy something if you had consumption on a resource and the cost was the same as your max capacity.","Fixed issue with max affordability check not refreshing on evolution stage.","Experimental Red-Green color blind theme."]},{version:"0.2.63",date:"5/20/2019",changes:["Fixed an issue that accidentally set the default tax rate to 2% instead of 20% for new games."]},{version:"0.2.62",date:"5/19/2019",changes:["Tax system revamped. Taxes can now be adjusted more granularly and effect morale instead of production.","Cement is now a requirement for theology since cement is needed for temples."]},{version:"0.2.61",date:"5/19/2019",changes:["Every genus type now has its own evolution path."]},{version:"0.2.60",date:"5/18/2019",changes:["Rescaled crate/container volumes. There are now substantially less crates/containers but they do a lot more per crate/container.","Spatial Reasoning now correctly applies to crates & containers.","Increased base value of several major storage facilities.","Added storage timers.","A.R.P.A. costs in popover now update their affordability check.","Buildings and Research that can not be afforded due to low capacity are now marked in red text."]},{version:"0.2.59",date:"5/17/2019",changes:["Added additional validation to ensure save strings belong to evolve before importing.","Fixed army rating display when rating doesn't calculate to a whole number.","Fixed listing order of some resources.","Smelter Iron bonus breakdown fixed.","Added Selenophobia to breakdown lists."]},{version:"0.2.58",date:"5/15/2019",changes:["Settings option to disable multiplier keys."]},{version:"0.2.57",date:"5/15/2019",changes:["Added labor validation to coal miners.","Key Multipliers now work with job and trade route assignment."]},{version:"0.2.56",date:"5/15/2019",changes:["Added +- symbols to trade route to distinguish import vs export."]},{version:"0.2.55",date:"5/14/2019",changes:["Manually crafting resources now gets all the same bonuses as auto crafting.","Fixed Recombination crispr upgrade.","Death limits added to each war campaign level.","War assessment added for each war campaign level."]},{version:"0.2.54",date:"5/13/2019",changes:["Uranium Breakdown Fixes."]},{version:"0.2.53",date:"5/13/2019",changes:["Breakdown Accuracy Enhancements.","Some Kindling Kindred costs reduced.","Fixed bug related to Fanaticism and Ent gods with foundry workers assigned to make plywood.","Plasmid bonus now applies to the sundial.","Fixed some spelling errors."]},{version:"0.2.52",date:"5/11/2019",changes:["Completed research can now be viewed on a separate tab under research.","Removed Plywood requirement from Stock Exchange for players with Kindling Kindred trait.","Fixed a CSS issue in the A.R.P.A. projects tab."]},{version:"0.2.51",date:"5/11/2019",changes:["University starts slightly cheaper.","Added Spatial Superiority crispr upgrade.","Added Spatial Supremacy crispr upgrade.","Exporting a save string now automatically selects the text and copies it to the clipboard."]},{version:"0.2.50",date:"5/10/2019",changes:["Added new capacity breakdowns for various resources."]},{version:"0.2.49",date:"5/10/2019",changes:["Added changelog link to version listing.","Added protection against loading a corrupt save string.","Greedy trait is now less greedy.","Spelling error fixes."]},{version:"0.2.48",date:"5/8/2019",changes:["Resources that are at greater then 99% capacity now change color to indicate they are at cap.","Attacks from rival cities should no longer cause more wounded soldiers then you have.","Assigning craftsman when no citizens are free will no longer take the labor from another job."]},{version:"0.2.47",date:"5/8/2019",changes:["Gluttony trait lowered to 10% from 25% .","High Metabolism trait lowered to 5% from 10% .","Fixed Sheet Metal not being added to craftsman list when unlocked."]},{version:"0.2.46",date:"5/8/2019",changes:["The 5% library bonus was only applying to scientists which was not intended. This now applies to the sundial and professors as well."]},{version:"0.2.45",date:"5/8/2019",changes:["Fixed an issue that allowed you to get extra benefits from under-powered wardenclyffe towers and biolabs."]},{version:"0.2.44",date:"5/8/2019",changes:["Fixed Key Multipliers getting stuck down."]},{version:"0.2.43",date:"5/7/2019",changes:["Fixed bug that could cause player to get free extra crafted resources when using the +5 option.","Reordered buildings in Village tab to group them more logically."]},{version:"0.2.42",date:"5/7/2019",changes:["Fixed a bug that was causing soldiers to become immortal.","Fixed some bugs with morale that caused some weather patterns to apply a different value then was reported.","Added weather to Food breakdown."]},{version:"0.2.41",date:"5/7/2019",changes:["Added a 5% bonus to global knowledge production on libraries."]},{version:"0.2.40",date:"5/7/2019",changes:["The Hivemind trait no longer applies to farmers as this was especially punishing."]},{version:"0.2.39",date:"5/7/2019",changes:["Evolution 2.0: Redid the evolution stage of the game to make it feel less tedious and like it matters more to the next phase of the game.","Fixed a bug that has the intended effects of Pessimism and Optimism traits swapped."]},{version:"0.2.38",date:"5/6/2019",changes:["First public release."]}];function Sc(a,r,i){$("#content").removeClass("flex");var s,n=e.getItem("evolved")||!1;switch(n&&(s=JSON.parse(LZString.decompressFromUTF16(n)),t=s),ks("page_view",{page_title:`Evolve Wiki - ${a}`}),a){case"intro":Fc(),window.location.hash=`#${a}`;break;case"faq":!function(){let e=$("#content");Ss(e);let a=["update","hotkeys","sethotkeys","offline","moonphase","orbital","lumber","farm","steel","aluminium","titanium","titanium_balorg","polymer","mythril","neutronium","adamantite","infernite","graphene","stanene","aerogel","crates","soft_reset","hard_reset","combat","morale","stress","genetic_decay","cache","aphrodisiac","religion","tax_riots","race","weather","sundial","plasmid","plasmid_keep","plasmid_earn","crispr","creep","phage","phage_earn","phage_benefit","anti_plasmids","temple","temple_break","demonic","celestial","mastery","challenges","perks","feats","support","micro","valdi","quantum","quantum_level","exotic","soul_gem","soul_gem_spend","hell_patrol","surveyors","defense","infusion","dark_energy"],r={neutronium:[Ki[t.race.species].solar.gas_moon]};for(let t=0;t
                      ');e.append(i);let s=[];r.hasOwnProperty(a[t])&&(s=r[a[t]]),i.append(`

                      ${z(`wiki_faq_q_${a[t]}`)}

                      `),i.append(`
                      ${z(`wiki_faq_a_${a[t]}`,s)}
                      `)}}(),window.location.hash=`#${a}`;break;case"gameplay":kc(r),Cc(a,r,i);break;case"prestige":!function(e){let a=$("#content");switch(Ss(a),e){case"resets":wc(a);break;case"resources":!function(e){let a=Ln("create",e),r=In(a,{name:"plasmids",template:"p_res",paragraphs:2,h_level:2,para_data:{1:[250]},data_color:{1:["warning"]}}),i=Bn(r,"plasmid","gain");fc(i,"plasmid"),i=Bn(r,"plasmid","bonus"),yc(i,"plasmid"),bc(i,"plasmid"),Ln("add","resources-prestige","plasmids",z("wiki_p_res_plasmids")),r=In(a,{name:"antiplasmids",template:"p_res",paragraphs:5,h_level:2,para_data:{4:[z("arpa_genepool_bleeding_effect_title")]},data_link:{4:["wiki.html#crispr-prestige-bleeding_effect"]}}),i=Bn(r,"anti","gain"),fc(i,"plasmid","anti"),i=Bn(r,"anti","bonus"),yc(i,"anti"),bc(i,"anti"),Ln("add","resources-prestige","antiplasmids",z("wiki_p_res_antiplasmids")),r=In(a,{name:"phage",template:"p_res",paragraphs:4,h_level:2}),i=Bn(r,"phage","gain"),fc(i,"phage"),i=Bn(r,"phage","bonus"),bc(i,"phage"),Ln("add","resources-prestige","phage",z("wiki_p_res_phage"));let s=In(a,{name:"dark",template:"p_res",paragraphs:1,h_level:2}),n=$("
                      "),c=$('
                        ');s.append(n),n.append(c),c.append(`
                      • ${z("wiki_p_res_dark_standard")}
                      • `),c.append(`
                      • ${z("wiki_p_res_dark_evil")}
                      • `),c.append(`
                      • ${z("wiki_p_res_dark_heavy")}
                      • `),c.append(`
                      • ${z("wiki_p_res_dark_antimatter")}
                      • `),c.append(`
                      • ${z("wiki_p_res_dark_micro")}
                      • `),c.append(`
                      • ${z("wiki_p_res_dark_magic")}
                      • `),i=Bn(s,"dark","gain"),fc(i,"dark",!1,"bigbang"),fc(i,"dark","vacuum","vacuum"),i=Bn(s,"dark","bonus"),function(e){let a=$('
                        ');e.append(a),a.append(`

                        ${z("wiki_calc_bonuses",[z("resource_Dark_name")])}

                        `);let r=$("
                        "),i=$("
                        "),s=$("
                        ");a.append(r),a.append(i),a.append(s);let n={dark:{val:void 0},harmony:{val:void 0},sludge:{val:void 0},uni:{val:"standard"}},c={standard:{vis:!0,result:!1,val:0},evil:{vis:!1,result:!1,val:0},antimatter:{vis:!1,result:!1,val:0},micro:{vis:!1,result:!1,val1:0,val2:0},heavy:{vis:!1,result:!1,val1:0,val2:0},magic:{vis:!1,result:!1,val:0}};r.append(`\n
                        ${z("wiki_calc_universe")} \n \n {{ 'standard' | uniLabel }}\n {{ 'evil' | uniLabel }}\n {{ 'antimatter' | uniLabel }}\n {{ 'micro' | uniLabel }}\n {{ 'heavy' | uniLabel }}\n {{ 'magic' | uniLabel }}\n
                        \n `),i.append(`\n
                        \n
                        \n ${z("wiki_calc_bonuses",[z("wiki_calc_dark_standard")])}:\n
                        \n
                        \n ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.001)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03))) / 200 = {{ 'standard', false | calc }} = +{{ 'standard', true | calc }}%\n
                        \n
                        \n
                        \n
                        \n ${z("wiki_calc_bonuses",[z("wiki_calc_dark_evil")])}:\n
                        \n
                        \n (log2(10 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) - 3.321928094887362) / 5 = {{ 'evil', false | calc }} = +{{ 'evil', true | calc }}%\n
                        \n
                        \n
                        \n
                        \n ${z("wiki_calc_bonuses",[z("wiki_calc_dark_antimatter")])}:\n
                        \n
                        \n (ln(50 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) - 3.912023005428146) / 5 = {{ 'antimatter', false | calc }} = +{{ 'antimatter', true | calc }}%\n
                        \n
                        \n
                        \n
                        \n ${z("wiki_calc_creep_reduction",[z("wiki_calc_home")])} (${z("wiki_calc_cap",[.06])}):\n
                        \n
                        \n (0.02 + ((ln(100 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)))) - 4.605170185988092) / 20)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)) = {{ 'micro', false, 2 | calc }}\n
                        \n
                        \n ${z("wiki_calc_creep_reduction",[z("wiki_calc_not_home")])} (${z("wiki_calc_cap",[.04])}):\n
                        \n
                        \n (0.01 + ((ln(100 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)))) - 4.605170185988092) / 35)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)) = {{ 'micro', false, 1 | calc }}\n
                        \n
                        \n
                        \n
                        \n ${z("wiki_calc_dark_heavy",[z("wiki_menu_space")])}:\n
                        \n
                        \n 0.25 + (0.5 * 0.995^({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) = {{ 'heavy', false, 1 | calc }} = +{{ 'heavy', true, 1 | calc }}%\n
                        \n
                        \n ${z("wiki_calc_dark_heavy",[z("wiki_tech_req_or",[z("wiki_menu_interstellar"),z("wiki_menu_intergalactic")])])}:\n
                        \n
                        \n 0.2 + (0.3 * 0.995^({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) = {{ 'heavy', false, 2 | calc }} = +{{ 'heavy', true, 2 | calc }}%\n
                        \n
                        \n
                        \n
                        \n ${z("wiki_calc_bonuses",[z("wiki_calc_dark_magic")])}:\n
                        \n
                        \n (ln(50 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) - 3.912023005428146) / 3 = {{ 'magic', false | calc }} = +{{ 'magic', true | calc }}%\n
                        \n
                        \n `),s.append(`\n
                        \n
                        ${z("wiki_p_res_dark")}
                        \n
                        ${z("wiki_p_res_harmony")}
                        \n
                        ${z("wiki_calc_sludge_level")}
                        \n
                        \n
                        \n \n \n
                        \n `),Cs({el:"#darkBonusCalc",data:{i:n,s:c},methods:{val(e){n[e].val&&n[e].val<0?n[e].val=0:"sludge"===e&&n.sludge.val&&n.sludge.val>5&&(n.sludge.val=5)},pickUniverse(e){c[n.uni.val].vis=!1,n.uni.val=e,c[e].vis=!0},resetInputs(){n.dark.val=void 0,n.harmony.val=void 0,n.sludge.val=void 0,c[n.uni.val].vis=!1,n.uni.val="standard",c.standard.vis=!0},importInputs(){n.dark.val=t.prestige.Dark.count,n.harmony.val=t.prestige.Harmony.count,"bigbang"!==t.race.universe&&(c[n.uni.val].vis=!1,n.uni.val=t.race.universe,c[n.uni.val].vis=!0),n.sludge.val=t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge[xn(n.uni.val)]?t.stats.achieve.extinct_sludge[xn(n.uni.val)]:0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_p_res_"+t),sludgeLabel:e=>void 0!==e?e:z("wiki_calc_sludge_level"),uniLabel:e=>z(e?"universe_"+e:"wiki_calc_universe"),calc(e,t,a){if(e===n.uni.val){if(t)return"heavy"===e?(100*c[e][`val${a}`]).toFixed(3):(100*c[e].val).toFixed(3);if(c[e].result=void 0!==n.dark.val&&void 0!==n.harmony.val,c[e].result)switch(e){case"standard":case"evil":case"antimatter":case"magic":return c[e].val=+(Is(e,!1,!0,{dark:n.dark.val,harmony:n.harmony.val,sludge:n.sludge.val})-1).toFixed(6),c[e].val;case"micro":return c[e][`val${a}`]=Is(e,1===a,!0,{dark:n.dark.val,harmony:n.harmony.val,sludge:n.sludge.val}),c[e][`val${a}`];case"heavy":let t=Is(e,!1,!0,{dark:n.dark.val,harmony:n.harmony.val,sludge:n.sludge.val});return t=1===a?.25+.5*t:.2+.3*t,c[e][`val${a}`]=t.toFixed(5),c[e][`val${a}`]}}}}})}(i),Ln("add","resources-prestige","dark",z("wiki_p_res_dark")),r=In(a,{name:"harmony",template:"p_res",paragraphs:3,h_level:2}),i=Bn(r,"harmony","gain"),fc(i,"harmony"),i=Bn(r,"harmony","bonus"),function(e){let a=$('
                        ');e.append(a),a.append(`

                        ${z("wiki_calc_creep_reduction",[z("resource_Harmony_name")])}

                        `);let r=$("
                        "),i=$("
                        ");a.append(r),a.append(i);let s={harmony:{val:void 0},ascended:{val:void 0},uni:{val:"undefined"}},n={result:{vis:!1,val:0}};r.append("\n
                        \n (ln(50 + ({{ i.harmony.val, 'harmony' | generic }} * {{ i.ascended.val | ascendedLabel }})) - 3.912023005428146) * 0.01 = {{ | calc }}\n
                        \n "),i.append(`\n
                        \n
                        ${z("wiki_p_res_harmony")}
                        \n
                        ${z("wiki_calc_ascended_level")}
                        \n
                        \n
                        \n \n \n
                        \n `),Cs({el:"#harmonyCreepCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0?s[e].val=0:"ascended"===e&&s.ascended.val&&s.ascended.val>5&&(s.ascended.val=5)},resetInputs(){s.harmony.val=void 0,s.ascended.val=void 0},importInputs(){s.harmony.val=t.prestige.Harmony.count,s.ascended.val=t.stats.achieve.ascended&&t.stats.achieve.ascended[xn(t.race.universe||"standard")]?t.stats.achieve.ascended[xn(t.race.universe||"standard")]:0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_p_res_"+t),ascendedLabel:e=>void 0!==e?e:z("wiki_calc_ascended_level"),calc(){if(n.result.vis=void 0!==s.harmony.val&&void 0!==s.ascended.val,n.result.vis)return n.result.val=+(.01*(Math.log(50+s.harmony.val*s.ascended.val)-3.912023005428146)).toFixed(5),n.result.val}}})}(i),Ln("add","resources-prestige","harmony",z("wiki_p_res_harmony")),In(a,{name:"blood",template:"p_res",paragraphs:5,h_level:2,para_data:{2:[z("tab_arpa_blood")],3:[1,"1-5"],4:[z("arpa_genepool_blood_sacrifice_title")],5:[z("arpa_genepool_blood_remembrance_title")]},data_link:{2:["wiki.html#blood-prestige"],4:["wiki.html#crispr-prestige-blood_sacrifice"],5:["wiki.html#crispr-prestige-blood_remembrance"]}}),Ln("add","resources-prestige","blood",z("wiki_p_res_blood")),r=In(a,{name:"artifact",template:"p_res",paragraphs:3,h_level:2,para_data:{1:[z("wiki_resets_infusion")],2:[z("tab_arpa_blood")],3:[1,"5th"]},data_link:{1:["wiki.html#resets-prestige-infusion"],2:["wiki.html#blood-prestige"]}}),i=Bn(r,"artifact","gain"),fc(i,"artifact"),Ln("add","resources-prestige","artifact",z("wiki_p_res_artifact")),r=In(a,{name:"ai_core",template:"p_res",paragraphs:2,h_level:2,para_data:{1:[z("wiki_resets_ai")]},data_link:{1:["wiki.html#resets-prestige-ai"]}}),i=Bn(r,"cores","gain"),fc(i,"cores"),i=Bn(r,"cores","bonus"),function(e){let a=$('
                        ');e.append(a),a.append(`

                        ${z("wiki_calc_core_quantum")}

                        `);let r=$("
                        "),i=$("
                        ");a.append(r),a.append(i);let s={cores:{val:void 0}},n={result:{vis:!1,val:0}};r.append("\n
                        \n 1 - (0.99^{{ i.cores.val, 'cores' | generic }}) = {{ false | calc }} = +{{ true | calc }}%\n
                        \n "),i.append(`\n
                        \n
                        ${z("wiki_calc_cores")}
                        \n
                        \n
                        \n \n \n
                        \n `),Cs({el:"#coresQuantumCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.cores.val=void 0},importInputs(){s.cores.val=t.prestige.AICore.count}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_"+t),calc:e=>e?+(100*n.result.val).toFixed(2):(n.result.vis=void 0!==s.cores.val,n.result.vis?(n.result.val=+(1-.99**s.cores.val).toFixed(4),n.result.val):void 0)}})}(i),Ln("add","resources-prestige","ai_core",z("wiki_p_res_ai_core")),r=In(a,{name:"servants",template:"p_res",paragraphs:5,h_level:2,break:[3,4,5],para_data:{1:[z("wiki_resets_matrix"),z("wiki_resets_retired"),z("wiki_resets_eden")],5:[z("achieve_overlord_name")]},data_link:{1:["wiki.html#resets-prestige-matrix","wiki.html#resets-prestige-retired","wiki.html#resets-prestige-eden"],5:["wiki.html#perks-prestige-overlord"]}}),Ln("add","resources-prestige","servants",z("wiki_p_res_servants")),r=In(a,{name:"skilled_servants",template:"p_res",paragraphs:6,h_level:2,break:[3,4,5,6],para_data:{1:[z("wiki_resets_matrix"),z("wiki_resets_retired")],6:[z("achieve_pathfinder_name"),z("achieve_overlord_name")]},data_link:{1:["wiki.html#resets-prestige-matrix","wiki.html#resets-prestige-retired"],6:["wiki.html#perks-prestige-pathfinder","wiki.html#perks-prestige-overlord"]}}),Ln("add","resources-prestige","skilled_servants",z("wiki_p_res_skilled_servants"))}(a);break;case"crispr":$c(a);break;case"blood":Pc(a);break;case"perks":!function(e){let t=$("
                        "),a=Ln("create",t);e.append(t),Object.keys(Fn).forEach((function(e){!function(e,t){let a=$(`
                        `);if(Fn[t].hasOwnProperty("group")){let e=$(`
                        ${Fn[t].name}
                        `);Fn[t].group.forEach((function(t){e.append($(`
                        ${t.desc(!0)}
                        `))})),a.append(e)}else a.append($(`
                        ${Fn[t].name}
                        ${Fn[t].desc(!0)}
                        `));if(Fn[t].notes.length>0){let e=$('
                        ');Fn[t].notes.forEach((function(t){e.append(`
                        ${t}
                        `)})),a.append(e)}e.append(a)}(a,e),Ln("add","perks-prestige",`${e}`,Fn[e].name)}))}(a)}}(r),Cc(a,r,i);break;case"events":(function(e){let a=$("#content");switch(Ss(a),e){case"major":!function(e){let a=Ln("create",e);In(a,{name:"major_intro",template:"events",paragraphs:3,h_level:2,para_data:{1:[z("wiki_menu_major"),999,83],2:[z("wiki_menu_major")],3:[z("wiki_menu_major")]}}),Ln("add","major-events","major_intro",z("wiki_menu_intro"));{let e=In(a,{name:"replication",template:"events",label:z("wiki_events_replication"),paragraphs:1,h_level:2,para_data:{1:[1,z("wiki_events_replication_para1_note",[3])]}});In(a,{name:"evolution",template:"events",label:z("wiki_events_replication"),paragraphs:1,h_level:2},e),In(a,{name:"replication_examples",template:"events",label:z("wiki_events_replication"),h_level:2,examples:[z("event_dna",[10])]},e),Ln("add","major-events","replication",z("wiki_events_replication"))}{let e=In(a,{name:"rna_meteor",template:"events",label:z("wiki_events_rna_meteor"),paragraphs:1,h_level:2,para_data:{1:[1,z("wiki_events_rna_meteor_para1_note",[2])]}});In(a,{name:"evolution",template:"events",label:z("wiki_events_rna_meteor"),paragraphs:1,h_level:2},e),In(a,{name:"rna_meteor_examples",template:"events",label:z("wiki_events_rna_meteor"),h_level:2,examples:[z("event_rna",[22])]},e),Ln("add","major-events","rna_meteor",z("wiki_events_rna_meteor"))}In(a,{name:"inspiration",template:"events",label:z("wiki_events_inspiration"),paragraphs:1,h_level:2,para_data:{1:[300,600]},examples:[z("event_inspiration")]}),Ln("add","major-events","inspiration",z("wiki_events_inspiration")),In(a,{name:"motivation",template:"events",label:z("wiki_events_motivation"),paragraphs:3,h_level:2,para_data:{1:[300,600],2:["10%","13%"]},examples:[z("event_motivation")]}),Ln("add","major-events","motivation",z("wiki_events_motivation"));{let e=In(a,{name:"fire",template:"events",label:z("wiki_events_fire"),paragraphs:1,h_level:2,para_data:{1:[1,"25%"]}});In(a,{name:"fire_condition",template:"events",label:z("wiki_events_fire"),paragraphs:2,break:[2],h_level:2},e),In(a,{name:"fire_examples",template:"events",label:z("wiki_events_fire"),h_level:2,examples:[z("event_fire",[1337..toLocaleString()])]},e),Ln("add","major-events","fire",z("wiki_events_fire"))}{let e=In(a,{name:"flare",template:"events",label:z("wiki_events_flare"),paragraphs:3,h_level:2,para_data:{2:["10%"],3:["20%",20,200]}});In(a,{name:"flare_condition",template:"events",label:z("wiki_events_flare"),paragraphs:4,break:[2],h_level:2},e),In(a,{name:"flare_examples",template:"events",label:z("wiki_events_flare"),h_level:2,examples:[z("event_flare",[Ki[t.race.species].home,69]),z("event_flare2",[Ki[t.race.species].home,42])]},e),Ln("add","major-events","flare",z("wiki_events_flare"))}{let e=In(a,{name:"raid",template:"events",label:z("wiki_events_raid"),paragraphs:3,h_level:2,para_data:{2:["25%"]}});In(a,{name:"raid_condition",template:"events",label:z("wiki_events_raid"),paragraphs:2,h_level:2,para_data:{2:[z("wiki_challenges_scenarios_truepath")]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"]}},e),In(a,{name:"raid_examples",template:"events",label:z("wiki_events_raid"),h_level:2,examples:[z("event_raid1",[10,31]),z("event_raid2",[244,0,50])]},e),Ln("add","major-events","raid",z("wiki_events_raid"))}{let e=In(a,{name:"siege",template:"events",label:z("wiki_events_siege"),paragraphs:3,h_level:2,para_data:{2:["50%"]}});In(a,{name:"siege_condition",template:"events",label:z("wiki_events_siege"),paragraphs:3,h_level:2,para_data:{3:[z("wiki_challenges_scenarios_truepath")]},data_link:{3:["wiki.html#challenges-gameplay-scenarios_truepath"]}},e),In(a,{name:"siege_examples",template:"events",label:z("wiki_events_siege"),h_level:2,examples:[z("event_siege1",[30,49]),z("event_siege2",[500024..toLocaleString(),0,25])]},e),Ln("add","major-events","siege",z("wiki_events_siege"))}{let e=In(a,{name:"terrorist",template:"events",label:z("wiki_events_terrorist"),paragraphs:1,h_level:2});In(a,{name:"terrorist_condition",template:"events",label:z("wiki_events_terrorist"),paragraphs:2,h_level:2,para_data:{2:[z("wiki_challenges_scenarios_truepath")]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"]}},e),In(a,{name:"terrorist_examples",template:"events",label:z("wiki_events_terrorist"),h_level:2,examples:[z("event_terrorist1",[14]),z("event_terrorist2",[54,18])]},e),Ln("add","major-events","terrorist",z("wiki_events_terrorist"))}{let e=In(a,{name:"pillage",template:"events",label:z("wiki_events_pillage"),paragraphs:6,break:[5],h_level:2,para_data:{2:["25%"],3:["50%"],5:[z("civics_gov_relations"),"40%"]}});In(a,{name:"pillage_condition",template:"events",label:z("wiki_events_pillage"),paragraphs:1,h_level:2,para_data:{1:[z("wiki_challenges_scenarios_truepath")]},data_link:{1:["wiki.html#challenges-gameplay-scenarios_truepath"]}},e),In(a,{name:"pillage_examples",template:"events",label:z("wiki_events_pillage"),h_level:2,examples:[z("event_pillaged1",[z("civics_gov2",[z("civics_gov_name4")]),10,55]),z("event_pillaged2",[z("civics_gov6",[z("civics_gov_name9")]),40,25,[`5704490 ${z("resource_Lumber_name")}`,`2177130 ${z("resource_Stone_name")}`,`4259421 ${z("resource_Furs_name")}`,`6033892 ${z("resource_Copper_name")}`,`602938 ${z("resource_Iron_name")}`,`3389580 ${z("resource_Aluminium_name")}`,`3292455 ${z("resource_Cement_name")}`,`5394173 ${z("resource_Coal_name")}`,`47231 ${z("resource_Oil_name")}`,`9390 ${z("resource_Uranium_name")}`,`7016884 ${z("resource_Steel_name")}`,`52801 ${z("resource_Titanium_name")}`,`1163086 ${z("resource_Alloy_name")}`,`2053980 ${z("resource_Polymer_name")}`,`3179901 ${z("resource_Iridium_name")}`,`792693 ${z("resource_Helium_3_name")}`,`1219 ${z("resource_Elerium_name")}`,`65078 ${z("resource_Water_name")}`,`290451 ${z("resource_Neutronium_name")}`,`3059577 ${z("resource_Adamantite_name")}`,`5736560 ${z("resource_Nano_Tube_name")}`,`2494390 ${z("resource_Graphene_name")}`,`6836006 ${z("resource_Stanene_name")}`,`2264649 ${z("resource_Orichalcum_name")}`,"$19235850"].join(", ")])]},e),Ln("add","major-events","pillage",z("wiki_events_pillage"))}{let e=In(a,{name:"quake",template:"events",label:z("wiki_events_quake"),paragraphs:1,h_level:2});In(a,{name:"quake_condition",template:"events",label:z("wiki_events_quake"),paragraphs:2,break:[2],h_level:2},e),In(a,{name:"quake_examples",template:"events",label:z("wiki_events_quake"),h_level:2,examples:[z("event_quake",[t.race.cataclysm||t.race.orbit_decayed?Ki[t.race.species].solar.red:Ki[t.race.species].home])]},e),Ln("add","major-events","quake",z("wiki_events_quake"))}{let e=In(a,{name:"doom",template:"events",label:z("wiki_events_doom"),paragraphs:2,h_level:2});In(a,{name:"doom_condition",template:"events",label:z("wiki_events_doom"),paragraphs:2,break:[2],h_level:2},e),In(a,{name:"doom_examples",template:"events",label:z("wiki_events_doom"),h_level:2,examples:[z("event_doom",[Ki[t.race.species].solar.dwarf]),z("event_doom_alt",[Ki[t.race.species].solar.dwarf])]},e),Ln("add","major-events","doom",z("wiki_events_doom"))}{let e=In(a,{name:"dhorde",template:"events",label:z("wiki_events_dhorde"),paragraphs:1,h_level:2,para_data:{1:[2500,5e3]}});In(a,{name:"dhorde_condition",template:"events",label:z("wiki_events_dhorde"),paragraphs:1,h_level:2},e),In(a,{name:"dhorde_examples",template:"events",label:z("wiki_events_dhorde"),h_level:2,examples:[z("event_demon_influx",[3456..toLocaleString()])]},e),Ln("add","major-events","dhorde",z("wiki_events_dhorde"))}{let e=In(a,{name:"ruins",template:"events",label:z("wiki_events_ruins"),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("resource_Iron_name"),z("resource_Copper_name"),z("resource_Steel_name"),z("resource_Cement_name"),"25%"]}});In(a,{name:"ruins_condition",template:"events",label:z("wiki_events_ruins"),paragraphs:1,h_level:2},e),In(a,{name:"ruins_examples",template:"events",label:z("wiki_events_ruins"),h_level:2,examples:[z("event_ruins")]},e),Ln("add","major-events","ruins",z("wiki_events_ruins"))}{let e=In(a,{name:"taxrevolt",template:"events",label:z("wiki_events_taxrevolt"),paragraphs:2,h_level:2});In(a,{name:"taxrevolt_condition",template:"events",label:z("wiki_events_taxrevolt"),paragraphs:3,break:[2],h_level:2,para_data:{1:["> 25%","< 100%"],2:[z("govern_oligarchy"),"20%"],3:[z("governor_noble"),"10%"]}},e),In(a,{name:"taxrevolt_examples",template:"events",label:z("wiki_events_taxrevolt"),h_level:2,examples:[z("event_tax_revolt")]},e),Ln("add","major-events","taxrevolt",z("wiki_events_taxrevolt"))}{let e=In(a,{name:"slave",template:"events",label:z("wiki_events_slave"),paragraphs:2,break:[2],h_level:2});In(a,{name:"slave_condition",template:"events",label:z("wiki_events_slave"),paragraphs:1,h_level:2,para_data:{1:[z("trait_slaver_name")]}},e),In(a,{name:"slave_examples",template:"events",label:z("wiki_events_slave"),h_level:2,examples:[z("event_slave_death1"),z("event_slave_death2"),z("event_slave_death3"),z("event_slave_none")]},e),Ln("add","major-events","slave",z("wiki_events_slave"))}{let e=In(a,{name:"protest",template:"events",label:z("wiki_events_protest"),paragraphs:3,h_level:2,para_data:{1:[z("govern_republic")],2:["30%"],3:[30,90]}});In(a,{name:"protest_condition",template:"events",label:z("wiki_events_protest"),paragraphs:1,h_level:2,para_data:{1:[z("govern_republic")]}},e),In(a,{name:"protest_examples",template:"events",label:z("wiki_events_protest"),h_level:2,examples:[z("event_protest0",[pi("small")]),z("event_protest1"),z("event_protest2"),z("event_protest3"),z("event_protest4"),z("event_protest5"),z("event_protest6"),z("event_protest7"),z("event_protest8"),z("event_protest9")]},e),Ln("add","major-events","protest",z("wiki_events_protest"))}{let e=In(a,{name:"scandal",template:"events",label:z("wiki_events_scandal"),paragraphs:2,h_level:2,para_data:{1:[z("governor_media")],2:["8%",15,90]}});In(a,{name:"scandal_condition",template:"events",label:z("wiki_events_scandal"),paragraphs:1,h_level:2,para_data:{1:[z("governor_media")]}},e),In(a,{name:"scandal_examples",template:"events",label:z("wiki_events_scandal"),h_level:2,examples:[z("event_scandal0"),z("event_scandal1"),z("event_scandal2"),z("event_scandal3"),z("event_scandal4"),z("event_scandal5"),z("event_scandal6"),z("event_scandal7"),z("event_scandal8"),z("event_scandal9")]},e),Ln("add","major-events","scandal",z("wiki_events_scandal"))}{let e=In(a,{name:"spy",template:"events",label:z("wiki_events_spy"),paragraphs:1,h_level:2});In(a,{name:"spy_condition",template:"events",label:z("wiki_events_spy"),paragraphs:1,h_level:2},e),In(a,{name:"spy_examples",template:"events",label:z("wiki_events_spy"),h_level:2,examples:[z("event_spy",[Z(1)])]},e),Ln("add","major-events","spy",z("wiki_events_spy"))}{let e=In(a,{name:"mine_collapse",template:"events",label:z("wiki_events_mine_collapse"),paragraphs:1,h_level:2});In(a,{name:"mine_collapse_condition",template:"events",label:z("wiki_events_mine_collapse"),paragraphs:1,h_level:2},e),In(a,{name:"mine_collapse_examples",template:"events",label:z("wiki_events_mine_collapse"),h_level:2,examples:[z("event_mine_collapse")]},e),Ln("add","major-events","mine_collapse",z("wiki_events_mine_collapse"))}{let e=In(a,{name:"m_curious",template:"events",label:z("wiki_events_m_curious"),paragraphs:6,break:[2,3,4,5,6],h_level:2,para_data:{2:[z("wiki_events_m_curious_para2_note1",[5e4.toLocaleString(),5e6.toLocaleString(),z("resource_Money_name")]),z("wiki_events_m_curious_para2_note1",[100,1e5.toLocaleString(),z("resource_Steel_name")]),z("wiki_events_m_curious_para2_note1",[250,1e6.toLocaleString(),z("resource_Alloy_name")]),z("wiki_events_m_curious_para2_note1",[100,25e4.toLocaleString(),z("resource_Adamantite_name")]),z("wiki_events_m_curious_para2_note1",[500,5e4.toLocaleString(),z("resource_Bolognium_name")]),z("wiki_events_m_curious_para2_note2",[1,z("resource_Soul_Gem_name")])],3:[10],4:[600,1200],5:["5%",200,600],6:[z("race_cath"),"10%",500,1e3]}});In(a,{name:"m_curious_condition",template:"events",label:z("wiki_events_m_curious"),paragraphs:1,h_level:2,para_data:{1:[z("trait_curious_name")]}},e),In(a,{name:"m_curious_examples",template:"events",label:z("wiki_events_m_curious"),h_level:2,examples:[z("event_m_curious0",[Ki[t.race.species].name,444015..toLocaleString(),z("resource_Alloy_name")]),z("event_m_curious1",[Ki[t.race.species].name]),z("event_m_curious2",[Ki[t.race.species].name]),z("event_m_curious3",[Ki[t.race.species].name]),z("event_m_curious4a",[z("race_cath")]),z("event_m_curious4b",[z("race_octigoran")])]},e),Ln("add","major-events","m_curious",z("wiki_events_m_curious"))}}(a);break;case"minor":!function(e){let a=Ln("create",e);{let e=In(a,{name:"minor_intro",template:"events",paragraphs:1,h_level:2});In(a,{name:"major_intro",template:"events",paragraphs:3,h_level:2,para_data:{1:[z("wiki_menu_minor"),850,71],2:[z("wiki_menu_minor")],3:[z("wiki_menu_minor")]}},e),Ln("add","minor-events","minor_intro",z("wiki_menu_intro"))}{let e=In(a,{name:"curious",template:"events",label:z("wiki_events_curious"),paragraphs:2,break:[2],h_level:2});In(a,{name:"curious_condition",template:"events",label:z("wiki_events_curious"),paragraphs:1,h_level:2,para_data:{1:[z("trait_curious_name")]}},e),In(a,{name:"curious_examples",template:"events",label:z("wiki_events_curious"),h_level:2,examples:[z("event_curious0",[Ki[t.race.species].name]),z("event_curious1",[Ki[t.race.species].name]),z("event_curious2",[Ki[t.race.species].name]),z("event_curious3",[Ki[t.race.species].name]),z("event_curious4",[Ki[t.race.species].name]),z("event_curious5",[Ki[t.race.species].name]),z("event_curious6",[Ki[t.race.species].name]),z("event_curious7",[Ki[t.race.species].name]),z("event_curious8",[Ki[t.race.species].name]),z("event_curious9",[Ki[t.race.species].name])]},e),Ln("add","minor-events","curious",z("wiki_events_curious"))}{let e=In(a,{name:"slave_escape",template:"events",label:z("wiki_events_slave_escape"),paragraphs:2,break:[2],h_level:2});In(a,{name:"slave_escape_condition",template:"events",label:z("wiki_events_slave_escape"),paragraphs:1,h_level:2,para_data:{1:[z("trait_slaver_name")]}},e),In(a,{name:"slave_escape_examples",template:"events",label:z("wiki_events_slave_escape"),h_level:2,examples:[z("event_slave_escape1"),z("event_slave_escape2"),z("event_slave_death4"),z("event_slave_none")]},e),Ln("add","minor-events","slave_escape",z("wiki_events_slave_escape"))}{let e=In(a,{name:"shooting_star",template:"events",label:z("wiki_events_shooting_star"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_shooting_star"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"shooting_star_examples",template:"events",label:z("wiki_events_shooting_star"),h_level:2,examples:[z("event_shooting_star")]},e),Ln("add","minor-events","shooting_star",z("wiki_events_shooting_star"))}{let e=In(a,{name:"tumbleweed",template:"events",label:z("wiki_events_tumbleweed"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_tumbleweed"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"tumbleweed_examples",template:"events",label:z("wiki_events_tumbleweed"),h_level:2,examples:[z("event_tumbleweed")]},e),Ln("add","minor-events","tumbleweed",z("wiki_events_tumbleweed"))}{let e=In(a,{name:"flashmob",template:"events",label:z("wiki_events_flashmob"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_flashmob"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"flashmob_examples",template:"events",label:z("wiki_events_flashmob"),h_level:2,examples:[z("event_flashmob")]},e),Ln("add","minor-events","flashmob",z("wiki_events_flashmob"))}{let e=In(a,{name:"heatwave",template:"events",label:z("wiki_events_heatwave"),paragraphs:1,h_level:2,para_data:{1:[z("hot")]}});In(a,{name:"heatwave_condition",template:"events",label:z("wiki_events_heatwave"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club"),z("evo_challenge_cataclysm"),z("hot")]}},e),In(a,{name:"heatwave_examples",template:"events",label:z("wiki_events_heatwave"),h_level:2,examples:[z("event_heatwave")]},e),Ln("add","minor-events","heatwave",z("wiki_events_heatwave"))}{let e=In(a,{name:"coldsnap",template:"events",label:z("wiki_events_coldsnap"),paragraphs:1,h_level:2,para_data:{1:[z("cold")]}});In(a,{name:"coldsnap_condition",template:"events",label:z("wiki_events_coldsnap"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club"),z("evo_challenge_cataclysm"),z("cold")]}},e),In(a,{name:"coldsnap_examples",template:"events",label:z("wiki_events_coldsnap"),h_level:2,examples:[z("event_coldsnap")]},e),Ln("add","minor-events","coldsnap",z("wiki_events_coldsnap"))}{let e=In(a,{name:"cucumber",template:"events",label:z("wiki_events_cucumber"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_cucumber"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"cucumber_examples",template:"events",label:z("wiki_events_cucumber"),h_level:2,examples:[z("event_cucumber")]},e),Ln("add","minor-events","cucumber",z("wiki_events_cucumber"))}{let e=In(a,{name:"planking",template:"events",label:z("wiki_events_planking"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_planking"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"planking_examples",template:"events",label:z("wiki_events_planking"),h_level:2,examples:[z("event_planking")]},e),Ln("add","minor-events","planking",z("wiki_events_planking"))}{let e=In(a,{name:"furryfish",template:"events",label:z("wiki_events_furryfish"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_furryfish"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"furryfish_examples",template:"events",label:z("wiki_events_furryfish"),h_level:2,examples:[z("event_furryfish")]},e),Ln("add","minor-events","furryfish",z("wiki_events_furryfish"))}{let e=In(a,{name:"meteor_shower",template:"events",label:z("wiki_events_meteor_shower"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_meteor_shower"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"meteor_shower_examples",template:"events",label:z("wiki_events_meteor_shower"),h_level:2,examples:[z("event_meteor_shower")]},e),Ln("add","minor-events","meteor_shower",z("wiki_events_meteor_shower"))}{let e=In(a,{name:"hum",template:"events",label:z("wiki_events_hum"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_hum"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"hum_examples",template:"events",label:z("wiki_events_hum"),h_level:2,examples:[z("event_hum")]},e),Ln("add","minor-events","hum",z("wiki_events_hum"))}{let e=In(a,{name:"bloodrain",template:"events",label:z("wiki_events_bloodrain"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_bloodrain"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"bloodrain_examples",template:"events",label:z("wiki_events_bloodrain"),h_level:2,examples:[z("event_bloodrain")]},e),Ln("add","minor-events","bloodrain",z("wiki_events_bloodrain"))}{let e=In(a,{name:"haunting",template:"events",label:z("wiki_events_haunting"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_haunting"),paragraphs:1,h_level:2,para_data:{1:[z("tech_science")]}},e),In(a,{name:"haunting_examples",template:"events",label:z("wiki_events_haunting"),h_level:2,examples:[z("event_haunting")]},e),Ln("add","minor-events","haunting",z("wiki_events_haunting"))}{let e=In(a,{name:"mothman",template:"events",label:z("wiki_events_mothman"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_mothman"),paragraphs:1,h_level:2,para_data:{1:[z("tech_science")]}},e),In(a,{name:"mothman_examples",template:"events",label:z("wiki_events_mothman"),h_level:2,examples:[z("event_mothman")]},e),Ln("add","minor-events","mothman",z("wiki_events_mothman"))}{let e=In(a,{name:"dejavu",template:"events",label:z("wiki_events_dejavu"),paragraphs:1,h_level:2});In(a,{name:"dejavu_condition",template:"events",label:z("wiki_events_dejavu"),paragraphs:1,h_level:2},e),In(a,{name:"dejavu_examples",template:"events",label:z("wiki_events_dejavu"),h_level:2,examples:[z("event_dejavu")]},e),Ln("add","minor-events","dejavu",z("wiki_events_dejavu"))}{let e=In(a,{name:"dollar",template:"events",label:z("wiki_events_dollar"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_dollar"),paragraphs:1,h_level:2,para_data:{1:[z("tech_currency")]}},e),In(a,{name:"dollar_examples",template:"events",label:z("wiki_events_dollar"),h_level:2,examples:[z("event_dollar",[6])]},e),Ln("add","minor-events","dollar",z("wiki_events_dollar"))}{let e=In(a,{name:"pickpocket",template:"events",label:z("wiki_events_pickpocket"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_pickpocket"),paragraphs:1,h_level:2,para_data:{1:[z("tech_currency")]}},e),In(a,{name:"pickpocket_examples",template:"events",label:z("wiki_events_pickpocket"),h_level:2,examples:[z("event_pickpocket",[9])]},e),Ln("add","minor-events","pickpocket",z("wiki_events_pickpocket"))}{let e=In(a,{name:"bird",template:"events",label:z("wiki_events_bird"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_bird"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"bird_examples",template:"events",label:z("wiki_events_bird"),h_level:2,examples:[z("event_bird")]},e),Ln("add","minor-events","bird",z("wiki_events_bird"))}{let e=In(a,{name:"contest",template:"events",label:z("wiki_events_contest"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_contest"),paragraphs:1,h_level:2,para_data:{1:[z("tech_science")]}},e),In(a,{name:"contest_examples",template:"events",label:z("wiki_events_contest"),h_level:2,examples:[z("event_contest",[z("event_contest_place0"),z("event_contest_type0")]),z("event_contest",[z("event_contest_place1"),z("event_contest_type1")]),z("event_contest",[z("event_contest_place2"),z("event_contest_type2")]),z("event_contest",[z("event_contest_place0"),z("event_contest_type3")]),z("event_contest",[z("event_contest_place1"),z("event_contest_type4")]),z("event_contest",[z("event_contest_place2"),z("event_contest_type5")]),z("event_contest",[z("event_contest_place0"),z("event_contest_type6")]),z("event_contest",[z("event_contest_place1"),z("event_contest_type7")]),z("event_contest",[z("event_contest_place2"),z("event_contest_type8")]),z("event_contest",[z("event_contest_place0"),z("event_contest_type9")])]},e),Ln("add","minor-events","contest",z("wiki_events_contest"))}{let e=In(a,{name:"cloud",template:"events",label:z("wiki_events_cloud"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_cloud"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"cloud_examples",template:"events",label:z("wiki_events_cloud"),h_level:2,examples:[z("event_cloud",[z("event_cloud_type0")]),z("event_cloud",[z("event_cloud_type1")]),z("event_cloud",[z("event_cloud_type2")]),z("event_cloud",[z("event_cloud_type3")]),z("event_cloud",[z("event_cloud_type4")]),z("event_cloud",[z("event_cloud_type5")]),z("event_cloud",[z("event_cloud_type6")]),z("event_cloud",[z("event_cloud_type7")]),z("event_cloud",[z("event_cloud_type8")]),z("event_cloud",[z("event_cloud_type9")]),z("event_cloud",[z("event_cloud_type10")])]},e),Ln("add","minor-events","cloud",z("wiki_events_cloud"))}{let e=In(a,{name:"dark_cloud",template:"events",label:z("wiki_events_dark_cloud"),paragraphs:1,h_level:2,para_data:{1:[z("rain"),z("snow")]}});In(a,{name:"dark_cloud_condition",template:"events",label:z("wiki_events_dark_cloud"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club"),z("evo_challenge_cataclysm"),z("rain"),z("snow")]}},e),In(a,{name:"dark_cloud_examples",template:"events",label:z("wiki_events_dark_cloud"),h_level:2,examples:[z("event_dark_cloud")]},e),Ln("add","minor-events","dark_cloud",z("wiki_events_dark_cloud"))}{let e=In(a,{name:"gloom",template:"events",label:z("wiki_events_gloom"),paragraphs:1,h_level:2,para_data:{1:[z("cloudy")]}});In(a,{name:"gloom_condition",template:"events",label:z("wiki_events_gloom"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club"),z("evo_challenge_cataclysm"),z("cloudy")]}},e),In(a,{name:"gloom_examples",template:"events",label:z("wiki_events_gloom"),h_level:2,examples:[z("event_gloom")]},e),Ln("add","minor-events","gloom",z("wiki_events_gloom"))}{let e=In(a,{name:"tracks",template:"events",label:z("wiki_events_tracks"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_tracks"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"tracks_examples",template:"events",label:z("wiki_events_tracks"),h_level:2,examples:[z("event_tracks")]},e),Ln("add","minor-events","tracks",z("wiki_events_tracks"))}{let e=In(a,{name:"hoax",template:"events",label:z("wiki_events_hoax"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_hoax"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"hoax_examples",template:"events",label:z("wiki_events_hoax"),h_level:2,examples:[z("event_hoax")]},e),Ln("add","minor-events","hoax",z("wiki_events_hoax"))}{let e=In(a,{name:"burial",template:"events",label:z("wiki_events_burial"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_burial"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"burial_examples",template:"events",label:z("wiki_events_burial"),h_level:2,examples:[z("event_burial")]},e),Ln("add","minor-events","burial",z("wiki_events_burial"))}{let e=In(a,{name:"artifacts",template:"events",label:z("wiki_events_artifacts"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_artifacts"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"artifacts_examples",template:"events",label:z("wiki_events_artifacts"),h_level:2,examples:[z("event_artifacts")]},e),Ln("add","minor-events","artifacts",z("wiki_events_artifacts"))}{let e=In(a,{name:"parade",template:"events",label:z("wiki_events_parade"),paragraphs:1,h_level:2});In(a,{name:"parade_condition",template:"events",label:z("wiki_events_parade"),paragraphs:1,h_level:2},e),In(a,{name:"parade_examples",template:"events",label:z("wiki_events_parade"),h_level:2,examples:[z("event_parade")]},e),Ln("add","minor-events","parade",z("wiki_events_parade"))}{let e=In(a,{name:"crop_circle",template:"events",label:z("wiki_events_crop_circle"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_crop_circle"),paragraphs:1,h_level:2,para_data:{1:[z("tech_agriculture")]}},e),In(a,{name:"crop_circle_examples",template:"events",label:z("wiki_events_crop_circle"),h_level:2,examples:[z("event_crop_circle")]},e),Ln("add","minor-events","crop_circle",z("wiki_events_crop_circle"))}{let e=In(a,{name:"llama",template:"events",label:z("wiki_events_llama"),paragraphs:1,h_level:2,para_data:{1:[25,100]}});In(a,{name:"tech",template:"events",label:z("wiki_events_llama"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"llama_condition",template:"events",label:z("wiki_events_llama"),paragraphs:1,h_level:2,para_data:{1:[z("trait_carnivore_name"),z("trait_soul_eater_name"),z("trait_detritivore_name"),z("trait_artifical_name")]},data_link:{1:["wiki.html#traits-species-genus_carnivore","wiki.html#traits-species-special_soul_eater","wiki.html#traits-species-genus_detritivore","wiki.html#traits-species-genus_artifical"]}},e),In(a,{name:"llama_examples",template:"events",label:z("wiki_events_llama"),h_level:2,examples:[z("event_llama",[51])]},e),Ln("add","minor-events","llama",z("wiki_events_llama"))}{let e=In(a,{name:"cat",template:"events",label:z("wiki_events_cat"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_cat"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"cat_examples",template:"events",label:z("wiki_events_cat"),h_level:2,examples:[z("event_cat")]},e),Ln("add","minor-events","cat",z("wiki_events_cat"))}{let e=In(a,{name:"omen",template:"events",label:z("wiki_events_omen"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_omen"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"omen_examples",template:"events",label:z("wiki_events_omen"),h_level:2,examples:[z("event_omen")]},e),Ln("add","minor-events","omen",z("wiki_events_omen"))}{let e=In(a,{name:"theft",template:"events",label:z("wiki_events_theft"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_theft"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"theft_examples",template:"events",label:z("wiki_events_theft"),h_level:2,examples:[z("event_theft",[z("event_theft_type0")]),z("event_theft",[z("event_theft_type1")]),z("event_theft",[z("event_theft_type2")]),z("event_theft",[z("event_theft_type3")]),z("event_theft",[z("event_theft_type4")]),z("event_theft",[z("event_theft_type5")]),z("event_theft",[z("event_theft_type6")]),z("event_theft",[z("event_theft_type7")]),z("event_theft",[z("event_theft_type8")]),z("event_theft",[z("event_theft_type9")])]},e),Ln("add","minor-events","theft",z("wiki_events_theft"))}{let e=In(a,{name:"compass",template:"events",label:z("wiki_events_compass"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_compass"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mining")]}},e),In(a,{name:"compass_examples",template:"events",label:z("wiki_events_compass"),h_level:2,examples:[z("event_compass")]},e),Ln("add","minor-events","compass",z("wiki_events_compass"))}{let e=In(a,{name:"bone",template:"events",label:z("wiki_events_bone"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_bone"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"bone_examples",template:"events",label:z("wiki_events_bone"),h_level:2,examples:[z("event_bone")]},e),Ln("add","minor-events","bone",z("wiki_events_bone"))}{let e=In(a,{name:"delicacy",template:"events",label:z("wiki_events_delicacy"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_delicacy"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"delicacy_examples",template:"events",label:z("wiki_events_delicacy"),h_level:2,examples:[z("event_delicacy")]},e),Ln("add","minor-events","delicacy",z("wiki_events_delicacy"))}{let e=In(a,{name:"prank",template:"events",label:z("wiki_events_prank"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_prank"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"prank_examples",template:"events",label:z("wiki_events_prank"),h_level:2,examples:[z("event_prank",[z("event_prank_type0")]),z("event_prank",[z("event_prank_type1")]),z("event_prank",[z("event_prank_type2")]),z("event_prank",[z("event_prank_type3")]),z("event_prank",[z("event_prank_type4")]),z("event_prank",[z("event_prank_type5")]),z("event_prank",[z("event_prank_type6")]),z("event_prank",[z("event_prank_type7")]),z("event_prank",[z("event_prank_type8")]),z("event_prank",[z("event_prank_type9")])]},e),Ln("add","minor-events","prank",z("wiki_events_prank"))}{let e=In(a,{name:"graffiti",template:"events",label:z("wiki_events_graffiti"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_graffiti"),paragraphs:1,h_level:2,para_data:{1:[z("tech_science")]}},e),In(a,{name:"graffiti_examples",template:"events",label:z("wiki_events_graffiti"),h_level:2,examples:[z("event_graffiti")]},e),Ln("add","minor-events","graffiti",z("wiki_events_graffiti"))}{let e=In(a,{name:"soul",template:"events",label:z("wiki_events_soul"),paragraphs:1,h_level:2});In(a,{name:"soul_condition",template:"events",label:z("wiki_events_soul"),paragraphs:1,h_level:2,para_data:{1:[z("trait_soul_eater_name")]}},e),In(a,{name:"soul_examples",template:"events",label:z("wiki_events_soul"),h_level:2,examples:[z("event_soul")]},e),Ln("add","minor-events","soul",z("wiki_events_soul"))}{let e=t.stats.hasOwnProperty("reset")?t.stats.reset+1:1,r=+(e/(e+10)*11).toFixed(2),i=In(a,{name:"cheese",template:"events",label:z("wiki_events_cheese"),paragraphs:1,h_level:2,para_data:{1:[`${r}%`,10,9+e]}});In(a,{name:"tech",template:"events",label:z("wiki_events_cheese"),paragraphs:1,h_level:2,para_data:{1:[Pr()]}},i),In(a,{name:"cheese_examples",template:"events",label:z("wiki_events_cheese"),h_level:2,examples:[z("event_cheese")]},i),Ln("add","minor-events","cheese",z("wiki_events_cheese"))}{let e=In(a,{name:"tremor",template:"events",label:z("wiki_events_tremor"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_tremor"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"tremor_examples",template:"events",label:z("wiki_events_tremor"),h_level:2,examples:[z("event_tremor")]},e),Ln("add","minor-events","tremor",z("wiki_events_tremor"))}{let e=In(a,{name:"rumor",template:"events",label:z("wiki_events_rumor"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_rumor"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"rumor_examples",template:"events",label:z("wiki_events_rumor"),h_level:2,examples:[z("event_rumor",[z("event_rumor_type0")]),z("event_rumor",[z("event_rumor_type1")]),z("event_rumor",[z("event_rumor_type2")]),z("event_rumor",[z("event_rumor_type3")]),z("event_rumor",[z("event_rumor_type4")]),z("event_rumor",[z("event_rumor_type5")]),z("event_rumor",[z("event_rumor_type6")]),z("event_rumor",[z("event_rumor_type7")]),z("event_rumor",[z("event_rumor_type8")]),z("event_rumor",[z("event_rumor_type9")])]},e),Ln("add","minor-events","rumor",z("wiki_events_rumor"))}}(a);break;case"progress":!function(e){let a=Ln("create",e);In(a,{name:"progress_intro",template:"events",paragraphs:3,h_level:2}),Ln("add","progress-events","progress_intro",z("wiki_menu_intro"));{let e=In(a,{name:"steel",template:"events",label:z("wiki_events_steel"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("resource_Steel_name")],2:["0.08%"]}});In(a,{name:"steel_condition",template:"events",label:z("wiki_events_steel"),paragraphs:1,h_level:2,para_data:{1:[z("resource_Steel_name")]},examples:[z("steel_sample")]},e),Ln("add","progress-events","steel",z("wiki_events_steel"))}In(a,{name:"elerium",template:"events",label:z("wiki_events_elerium"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("resource_Elerium_name"),z("tech_elerium_mining")],2:[z("space_belt_iron_ship_title"),z("space_belt_iridium_ship_title"),"0.4%"]},data_link:{1:[!1,"wiki.html#deep_space-tech-elerium_mining"],2:["wiki.html#space-structures-iron_ship","wiki.html#space-structures-iridium_ship"]},examples:[z("discover_elerium")]}),Ln("add","progress-events","elerium",z("wiki_events_elerium")),In(a,{name:"oil",template:"events",label:z("wiki_events_oil"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("resource_Oil_name"),Kn("gas_moon"),z("space_gas_moon_oil_extractor_title")],2:[z("space_gas_moon_outpost_title"),"1%"]},data_link:{1:[!1,!1,"wiki.html#space-structures-oil_extractor"],2:["wiki.html#space-structures-outpost"]},examples:[z("discover_oil",[Kn("gas_moon")])]}),Ln("add","progress-events","oil",z("wiki_events_oil"));{let e=In(a,{name:"pit",template:"events",label:z("wiki_events_pit"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("portal_pit_name"),z("tab_portal"),z("portal_pit_mission_title")]},data_link:{1:[!1,!1,"wiki.html#hell-structures-pit_mission"]}});In(a,{name:"pit_condition",template:"events",label:z("wiki_events_pit"),paragraphs:1,h_level:2,para_data:{1:[1e6.toLocaleString(),z("galaxy_telemetry_beacon")]},data_link:{1:[!1,"wiki.html#intergalactic-structures-telemetry_beacon"]},examples:[z("portal_hell_pit_found")]},e),Ln("add","progress-events","pit",z("wiki_events_pit"))}{let e=In(a,{name:"alien_encounter",template:"events",label:z("wiki_events_alien_encounter"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("galaxy_scout_ship"),z("tech_xeno_linguistics"),z("galaxy_corvette_ship")],2:["10%"]},data_link:{1:["wiki.html#intergalactic-structures-scout_ship","wiki.html#intergalactic-tech-xeno_linguistics","wiki.html#intergalactic-tech-corvette_ship"]}});In(a,{name:"alien_encounter_condition",template:"events",label:z("wiki_events_alien_encounter"),paragraphs:1,h_level:2,para_data:{1:[z("galaxy_scout_ship")]},examples:[z("galaxy_encounter")]},e),Ln("add","progress-events","alien_encounter",z("wiki_events_alien_encounter"))}{let e=In(a,{name:"piracy",template:"events",label:z("wiki_events_piracy"),paragraphs:3,break:[3],h_level:2,para_data:{2:[z("galaxy_piracy")],3:["20%"]},data_link:{2:["wiki.html#mechanics-gameplay-piracy"]}});In(a,{name:"piracy_condition",template:"events",label:z("wiki_events_piracy"),paragraphs:1,h_level:2,para_data:{1:[z("galaxy_embassy")]},data_link:{1:["wiki.html#intergalactic-structures-embassy"]},examples:[z("galaxy_piracy_msg",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name])]},e),Ln("add","progress-events","piracy",z("wiki_events_piracy"))}In(a,{name:"alien_database",template:"events",label:z("wiki_events_alien_database"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("galaxy_scavenger"),z("tech_alien_database")],2:[z("galaxy_scavenger"),"2%"]},data_link:{1:["wiki.html#intergalactic-structures-scavenger"]},examples:[z("galaxy_scavenger_find")]}),Ln("add","progress-events","alien_database",z("wiki_events_alien_database"));{let e=In(a,{name:"corrupt_gem",template:"events",label:z("wiki_events_corrupt_gem"),paragraphs:4,break:[2],h_level:2,para_data:{1:[z("resource_Corrupt_Gem_name"),z("portal_soul_forge_title")],2:[z("resource_Soul_Gem_name"),z("portal_soul_forge_title"),z("portal_soul_attractor_title")],3:["1/(11-X)","X",z("portal_soul_attractor_title")],4:[9,z("portal_soul_attractor_title"),"9.09%",0,"50%"]},data_link:{1:[!1,"wiki.html#hell-structures-soul_forge"],2:[!1,!1,"wiki.html#hell-structures-soul_attractor"]}});In(a,{name:"corrupt_gem_condition",template:"events",label:z("wiki_events_corrupt_gem"),paragraphs:1,h_level:2,para_data:{1:[z("tech_metaphysics")]},data_link:{1:["wiki.html#intergalactic-tech-metaphysics"]},examples:[z("portal_corrupt_gem")]},e),Ln("add","progress-events","corrupt_gem",z("wiki_events_corrupt_gem"))}In(a,{name:"vault_find",template:"events",label:z("wiki_events_vault_find"),paragraphs:3,break:[2],h_level:2,para_data:{1:[z("job_archaeologist"),z("portal_vault_title"),z("portal_ruins_name")],2:[z("job_archaeologist"),"2.5%"],3:[z("job_archaeologist"),z("portal_ruins_supressed"),z("portal_ruins_name"),"0%","2.5%","100%"]},data_link:{1:[!1,"wiki.html#hell-structures-vault"]},examples:[z("portal_ruins_vault")]}),Ln("add","progress-events","vault_find",z("wiki_events_vault_find"));{let e=In(a,{name:"syndicate",template:"events",label:z("wiki_events_syndicate"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("tech_shipyard",[Kn("dwarf")])],2:["5%"]},data_link:{1:["wiki.html#solar-tp_tech-shipyard"]}});In(a,{name:"syndicate_condition",template:"events",label:z("wiki_events_syndicate"),paragraphs:1,h_level:2,para_data:{1:[z("tech_long_range_probes")]},data_link:{1:["wiki.html#solar-tp_tech-long_range_probes"]},examples:[z("outer_syndicate",[z("civics_gov5",[z("civics_gov_name1")])])]},e),Ln("add","progress-events","syndicate",z("wiki_events_syndicate"))}}(a);break;case"special":!function(e){let a=Ln("create",e);In(a,{name:"special_intro",template:"events",paragraphs:3,h_level:2,para_data:{3:[z("boring")]}}),Ln("add","special-events","special_intro",z("wiki_menu_intro"));{let e="crystal",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_friday_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="valentine",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:3,break:[2,3],h_level:2,para_data:{2:[z("feat_love_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="unlucky",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_leprechaun_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="fool",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_fool_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e=cn("easter");{let t="hopper",r=In(a,{name:t,template:"events",label:z(`wiki_events_${t}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_easter_name")]}});In(a,{name:`${t}_condition`,template:"events",label:z(`wiki_events_${t}`),paragraphs:2,break:[2],h_level:2,para_data:{1:[`${z(`month${e.date[0]}`)} ${e.date[1]}`]}},r),Ln("add","special-events",t,z(`wiki_events_${t}`))}{let r="egghunt",i=In(a,{name:r,template:"events",label:z(`wiki_events_${r}`),paragraphs:7,break:[2,3,4,6],h_level:2,para_data:{2:[z("feat_egghunt_name"),12,18],5:[z("trait_hyper_name"),z("trait_fast_growth_name"),z("trait_rainbow_name"),z("trait_optimistic_name")],7:[z("trait_cannibalize_name"),z("trait_rage_name"),z("trait_blood_thirst_name"),z("trait_sticky_name")]}}),s=["U2FsdGVkX1/PcdpekGFnkjSSCBa9yVo3z5xq3a2662iSlAA8yuaPEsK4Qyn5OSED","U2FsdGVkX180d8+Fl8mi96tY7KHkOWLkO0syi+BeZW47ga9AdJiBdbsksLaMTGvT","U2FsdGVkX19hHAatSiZiYe33Hx4u+bixNx4U7O4smhKVb/a+umB6MlIbgM3eE3UG","U2FsdGVkX188sIGEBwWHyzf0SkKQ027dzHZmkJp93FeXrXu70hD0KqYfoTxnbGqU","U2FsdGVkX18dLIKZyFStCpVKJrFAc36LF4uNcpuJd8CGU0yC1rPllsNfBHAhrfwT","U2FsdGVkX1/ZRiMKl3kG4PUQOx8bdgz7va6bLW3Gf5COBHAs7CMDITt7SDeIygvd","U2FsdGVkX19FZ4kZmquyj6NUTqo+AYS7U31mSik1W2Awdp5M6L1WlsG4Px8uUYUN","U2FsdGVkX1+9Eh/34O02cW0SuZg0rQYZnomSBjBQU4Q3VSU0y62ypmoJNjOb5Uix","U2FsdGVkX1+3qtRH9MVd1B8T+JP5DgnlER6u8P60vX/NVjLGuceG7DX+b2yPW3J5","U2FsdGVkX18JYj4R4QuZBpDdcsEjkYPAf3uNNIzu6Vs=","U2FsdGVkX1+Eq43UVbtPlveU6HqIU8PSHL8QH+FlUxWkhyB1S+QAVVM2z0OryeJd","U2FsdGVkX18brcDy1P4HEGkmTw5t19CgWEshDFRSByELjSG9MtvSdSBbj13JhYuG","U2FsdGVkX1/vr39YAfqKcFM7c8ed6Oi7lRrDYKDtfUJRKF3pcrIRAWc4FF/Tt5BjwaXOi0slDE9JmeIDifD2gw==","U2FsdGVkX19KtuHoWRLTz0wLH8D/fLoOriDsmk6agzT85xsAAXv26ILjSV2C8mpi","U2FsdGVkX18/Tyjq6czHYJKjJQPXcRCgqmZqu2AFmx2FddfQPzM+YkXXECLMVA+e","U2FsdGVkX19kn6Hj9vQq5JxU9dsKsu0U+qADHauwh7TPf1enfhF1VQamBs7VFuX5","U2FsdGVkX19ICmvq9eubXYyGpmRML9aqTzBZMRvvOWFMwp2IiJBUUpl4LgLJOwLqnEISPAepbrdrfJn8miQIgA==","U2FsdGVkX19P0vr33mSfkSTDVz7N3a59YF5Cc+/NMC0f1tT3fXJDLqZMi98gGOrv"],n=["U2FsdGVkX1+duY7hvIoeOGqas8WhBy8hojTLQ0OxadHBEDzOPwpc4K1Y6N+WyDah","U2FsdGVkX1+AQhvu619WY9xow4HmruRn5yJefuIkv3u7U6baVdV/mHLJfUaNmTE6","U2FsdGVkX1/whjtke2hryY9zWuV0MTzN2JKXaFyzwJXwtEx9+iLMbHkdVFwi6h63","U2FsdGVkX18FBXNUeu4NIIiy4Mmk++iyUIJKxFS/mZvAj98+eJR+SZj8xpXHTkia","U2FsdGVkX1/Imw6q6mixFM1BlgToue0NUqbCTHKuNZFHC1Vp7I934fUpj/xCFg33","U2FsdGVkX18h03LNWLTF59y343iStuLaS/0cgvLtKSMzm8UpzMVWBxwkGGSxDDPO","U2FsdGVkX18+W3R7IyisKi9TgzbkQ/636SJ7ubGsCx6Rz5GMxlTkbTVbOG6YFAC4Cle0TjI1riEzpGQtuCr6C+1mX3FdCLVz3oaGWqIajvI=","U2FsdGVkX18CjBzSHSIPZ07ZgvI6JgGiVIJE4ugYa2xWFeM1a/OnXrMT1sBpwmXwiHayBp1tdw83/4I55pGwpA==","U2FsdGVkX1+QWybO+rnrqxI23qXSKzevq0C/NPkX8/kd5h0xo20ozmxo4Pknui3G","U2FsdGVkX1//2GoF+3kVNPim1ThpVMgMCHEzSH0UZCrc4EIjktoxBC87gXddwhZR","U2FsdGVkX1/HQFE7BGTMIHN8G4pljsZlwtFaXHZh2U/VN4DD8lOL4OUYxnJUGr+g","U2FsdGVkX1/f1jFsIVKmxsXq85PuOj+fq+9WtYf1AZbPsuChio/XV6mpCxlTJz8X","U2FsdGVkX1+NRsztgBjDQeevIAYiHJ+X9dUERkDoYpLcvYAvWWzVvbjk4uq4dSMPEuykMqsZGGwvBtl1V0T+pO254xK8+5xWjZYnE9x6A+I=","U2FsdGVkX1//Crqk3ZOt8MHG/C4V91VEORQ3rQe4CEBHQhqfMD84PrEBZkwN7VpKvBgcg+2FsDknW+LDnNPIZA==","U2FsdGVkX1/bUrGTAmEkt6ukJKG8tIAIUVr4fnMFPsdamUtLJBGIG2dwQyaYywTD","U2FsdGVkX1/zl2y8RCXettY8EAPFE+cc/qImK4n5BocvEV2YvFKSyrOGxfLd3qBD","U2FsdGVkX19GszY2Yf01gUZnzs9F51vUgYu/FlRIPiFt9zasXhFP9tzX1en5/483mZeqi/uNRhV+zfoHd6qcYA==","U2FsdGVkX1+4syPwX9UT2KAsJj8uv43olf/GOTOudd/RbwnHsybitwYU4kk2ZVWx"];const c=(new Date).getFullYear(),o="egghunt";let l=`
                        ${z("wiki_feat_egghunt_found")}
                        `;l+='
                        ';for(let a=1;a<=18;a++){let r=t.special.egg.hasOwnProperty(c)&&t.special.egg[c][`egg${a}`]?"has-text-success":"has-text-danger",i=t.special.egg.hasOwnProperty(c)&&t.special.egg[c][`egg${a}`]?"found":"missing",_=`${z("wiki_events_hint_avail")} ${z(`month${e.hintDate[0]}`)} ${e.hintDate[1]}`;e.hint&&(_=''+CryptoJS.AES.decrypt(s[a-1],o).toString(CryptoJS.enc.Utf8)+"");let d=`${z("wiki_events_sol_avail")} ${z(`month${e.solveDate[0]}`)} ${e.solveDate[1]}`;e.solve&&(d=`${z("wiki_events_reveal_sol")}`),l+=`
                        ${z("wiki_feat_egghunt_num",[a])}${_}${d}
                        `}l+="
                        ",i.append(l),$(".eggsol").on("click",(function(){const e=$(this).attr("data-sol"),t=CryptoJS.AES.decrypt(e,o);$(this).html(t.toString(CryptoJS.enc.Utf8))})),In(a,{name:`${r}_condition`,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2,para_data:{1:[`${z(`month${e.date[0]}`)} ${e.date[1]}`,`${z(`month${e.endDate[0]}`)} ${e.endDate[1]}`]}},i),Ln("add","special-events",r,z(`wiki_events_${r}`))}}{let e="launch_day",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:3,break:[2,3],h_level:2,para_data:{2:[z("feat_launch_day_name")],3:["5%"]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e=t.hasOwnProperty("stats")?1e5+9e3*t.stats.reset:1e5;e>1e6&&(e=1e6);let r="solstice",i=In(a,{name:r,template:"events",label:z(`wiki_events_${r}`),paragraphs:4,break:[2,3,4],h_level:2,para_data:{1:[e.toLocaleString(),z(`wiki_events_${r}`)],2:[z("feat_solstice_name")]}});In(a,{name:`${r}_condition`,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2},i),Ln("add","special-events",r,z(`wiki_events_${r}`))}{let e=t.hasOwnProperty("stats")?1e5+9e3*t.stats.reset:1e5;e>1e6&&(e=1e6);let r="firework",i=In(a,{name:r,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_firework_name")]}});In(a,{name:`${r}_condition`,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2},i),Ln("add","special-events",r,z(`wiki_events_${r}`))}{let e="halloween",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_boo_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e=cn("halloween"),r="trickortreat",i=In(a,{name:r,template:"events",label:z(`wiki_events_${r}`),paragraphs:3,break:[2,3],h_level:2,para_data:{2:[z("feat_trickortreat_name"),12]}}),s=["U2FsdGVkX1/PDiFXguD51NL4kEt4e9qRJwl5IKNCQE9vI3XAoH5gDW28r2V4O5GY","U2FsdGVkX18xhhpvSSA7YALgn1lm1e+GylSzgVdoTnLXMzPLL1knLlINAS8l5ECGfvjo6CDFYnuvqaw/8BugAw==","U2FsdGVkX18g9cYmSZKe/VjFeCjuODnwnD+i+2ShpdeMI4uIIzbllcQFIWJaQw+EvsDu5DFBNCEuFOsWRFVMyA==","U2FsdGVkX1+nD+SyHpi39fhqppxDiF+UhJh3w0dhZ4IxuC1s3h0gTrgBI7IxVLrQ","U2FsdGVkX1+OfTMTHGhIpqmihvW7fMCt0q+bLWqhd7Z0Cj31jNUqmvBcxb6HzbGc4mL/msBX6PO5zpb4pBUzwA==","U2FsdGVkX1+hC03MwAyWdqH6ODAGNbgm7CRgC+0Wfreja2JZX7oPwYhPmfQXzn1RfeIncnkRTmdXGMqQ/mq2GQ==","U2FsdGVkX18cU5HWOtwNhFSnlxBHxpu5XEJBFj3EhtzU/PLXxynq5Rq9YGl23QNr"],n=["U2FsdGVkX1/bQrTdTtuTtXbxmJvxhHdsacfjyPKgyzXzthWNTsjaxqcCKjwjqCyG","U2FsdGVkX19tP6ZlSqvfdg6qaoOceA6978unLN8j9VIm5LUJSHUZm77zK1i1rWq3","U2FsdGVkX18Ex9HXV1+h+DIdFBxpNPI4Gl0E0EwOFbpyncN5gEfS8fWURvPT11S66x4swlZjnntbhMvDG+4SWg==","U2FsdGVkX1+xyixviw9PD/sRskoRG9owodNkZlwcAMSzQXe2PdAJPLwEBV9knjgGg11ws2eEBHXj7Y5j5SS7br+Uehaaj0MViyfxYdsZOEQ=","U2FsdGVkX18+2YEr0TG80mQY483i7yOr+Qnh66mOKEviX0ElRHI9VCha9TG+no1r","U2FsdGVkX1/Vuthb9MYQT02lO0ngkSI4f1tbvrrCwtVQiUTSIaVgDHVYYcIgfSl3WfiRhwGJWeP/6w+i7FEqaA==","U2FsdGVkX1/3Zbp0Tlqh/n5TKvOJEIuaf9/DcDFlDz1s2Tb+qbUS1GmPTzpP3xLu"],c=["U2FsdGVkX18m9z0oToDhhhmI0ugH5ykCrV1z64upZad/LXRYaFAyDT+O15+BXmJUKv7yY4YiBS6SYc65LJQjwEkMY5orIcyusiXtY9xnpRY=","U2FsdGVkX18eejrZNi9yF98CBO4KWjBLzo8HTBagKST0kjPmH48UuPWKG7Y3qyfeUyAFuDBnNRgdbgXXcWVPTE+3tbqcRiqAUZF8iLhXbmY=","U2FsdGVkX1/RKcVkvhY8bsGcXAQX3xJH4Ns/tUctQzK58oI9LJBxzIDyOHlPatn49avqw8r5lEmWyJOL2wyUjUPlYR/C9CjtO8t8oBW4ymWZRi66Ia0z1tMRHZyamonp","U2FsdGVkX18fvaoGr3U+o/m+xJLnbmVKJ1/GjNERP1ZDotBG7lD7vCtB1XyrCV0CvZXI9WK3r+FLD4rc7ZsLav77MTvQY+3pmwTYB841IxkUGCRE2mQYcr01xtxOPxMBMppChSZ8KJFgzfLhxL2rog==","U2FsdGVkX18MRMhu9I4km+hryh9dnvVBSkHdUPBgyHnKLsRB8PxpcJSFNq9b0plJ","U2FsdGVkX18IDZ0hUGT3xuDSi9EVacctj7h0BThWEgzIovJAieOvqXg/0wrZWHXQvyyVMsQtOdBls2nDjryxiw==","U2FsdGVkX1891SskU89HRmZPzhBcScrDGfGpJsp8F1qgVnsuON0h6WL69wEF9/uEpRi393mOXOrubNYVFzRgjwqERT3G/f6u/4bWXGSLpS8="],o=["U2FsdGVkX19wIpvvED4RfWp5UAJfJvmnyhdkqsfr3BlVH5YEdjGNy4mcTvuvuY/92b6F3aQJHx0vunDJ64hcezPUAM5P+E/iROMQoMDCTJwwni6SRCpJggAHSOBTovW0piVAnyt6WHsjiAmVQVo8Og==","U2FsdGVkX1+bLPNq0l72utbOUTZ+JAXIUcGrrXVneoHD/GTbFy4jqDcU++SxaFih2aKODyZx3/SPbm0pd4JIQlu3xgl/demBDPj7TRbatEOM7aTBJhke5jwSYuIPTwWm8eyO0FINhZqO94pV4BFmcYv7b1lkzFgiLEOX/5kV/qE=","U2FsdGVkX1/QQZqQ4S2CvR3IQFL5D1pWbqrntie8JAuZrYUIQoke13j6xzI3A2KVG3lE+IZZo6Ktn2zKJ8diaroUUB/CIP0DvewzzbNj7XT3d9G456ELSMjjgb8pKc586Mq661bEjCqm+Tz2DoMLtnzMaVIXPhqBBFutt2U7JwERvNiwBkX2YhyOD3QO/tcPmwKzLJ+cYjIDSEHeCVl/yeistKb5pQbrmPH4wHAKbVQNaiaOvIjee0wqttzpmcnNgx4axIi2FAqPpT2s1hHAmhUmeV0HKDxYQWgfntqRhe/k4ar1vrZ2QdhLozqDe35S","U2FsdGVkX1+Z3/SLqEmoDq377QCt49UMTneD9zo6FqTfFOab0SWGG8ioBZ1z+/v422HygjnuwD341scmcTuA/4Pz9APy3FQcCqA5Fw4hDed+LvjrecqEZogyCw1WVaCItGXZW9+TXM0/y6p7VXvuyw==","U2FsdGVkX19CLOS3ivLPeqIYtjSBdW1WT4UFvJjNDto6jy9751Q73OZF2JQlhgKyayhswWuEk+JGbYwLbDbWhJgZUR/R9hYJnw8/Wcay4eM=","U2FsdGVkX19Pm5I9mqzijXCNM3dk4ut0IDPpownMePohkcfE6jsuLA0dgzv9vp5tjEVPaUD/bqMgEzsD9svhOEJd+zlslkqIsBee6EJTO/4=","U2FsdGVkX19TcqGI2bk6XYN40buKCGWH58AjMFDNE/jawAK+II3s6TvoVCcXbZsKzLF2++aeUgq6Ag+TysbSf5/T3IHeqQQnjFGIkkzlmMJH9wROKLirkPSzsw8O6J1J"];const l=(new Date).getFullYear(),_="trickortreat";let d=`
                        ${z("wiki_feat_trick_found")}
                        `;d+='
                        ';for(let a=1;a<=s.length;a++){let r=t.special.trick.hasOwnProperty(l)&&t.special.trick[l][`treat${a}`]?"has-text-success":"has-text-danger",i=t.special.trick.hasOwnProperty(l)&&t.special.trick[l][`treat${a}`]?"found":"missing",c=`${z("wiki_events_hint_avail")} ${z(`month${e.hintDate[0]}`)} ${e.hintDate[1]}`;e.hint&&(c=''+CryptoJS.AES.decrypt(s[a-1],_).toString(CryptoJS.enc.Utf8)+""),d+=`
                        ${z("wiki_feat_treat_num",[a])}${c}
                        `;let o=`${z("wiki_events_sol_avail")} ${z(`month${e.solveDate[0]}`)} ${e.solveDate[1]}`;e.solve&&(o=`${z("wiki_events_reveal_sol")}`),d+=`
                        ${o}
                        `}d+="
                        ",i.append(d);let p=`
                        ${z("wiki_feat_treat_found")}
                        `;p+='
                        ';for(let a=1;a<=c.length;a++){let r=t.special.trick.hasOwnProperty(l)&&t.special.trick[l][`trick${a}`]?"has-text-success":"has-text-danger",i=t.special.trick.hasOwnProperty(l)&&t.special.trick[l][`trick${a}`]?"found":"missing",s=`${z("wiki_events_hint_avail")} ${z(`month${e.hintDate[0]}`)} ${e.hintDate[1]}`;e.hint&&(s=''+CryptoJS.AES.decrypt(c[a-1],_).toString(CryptoJS.enc.Utf8)+""),p+=`
                        ${z("wiki_feat_trick_num",[a])}${s}
                        `;let n=`${z("wiki_events_sol_avail")} ${z(`month${e.solveDate[0]}`)} ${e.solveDate[1]}`;e.solve&&(n=`${z("wiki_events_reveal_sol")}`),p+=`
                        ${n}
                        `}p+="
                        ",i.append(p),$(".totsol").on("click",(function(){const e=$(this).attr("data-sol"),t=CryptoJS.AES.decrypt(e,_);$(this).html(t.toString(CryptoJS.enc.Utf8))})),In(a,{name:`${r}_condition`,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2,para_data:{1:[`${z(`month${e.date[0]}`)} ${e.date[1]}`,`${z(`month${e.endDate[0]}`)} ${e.endDate[1]}`]}},i),Ln("add","special-events",r,z(`wiki_events_${r}`))}{let e="turkey",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:3,break:[2,3],h_level:2,para_data:{2:[z("feat_gobble_gobble_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="festive",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:1,h_level:2});["elven","centaur","capybara","wendigo","yeti","entish"].forEach((function(a){In(t,{name:a,template:`events_${e}`,label:z(`wiki_events_${e}`),paragraphs:2,h_level:0,para_data:{1:[z(`race_${a}`)]}})})),In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="xmas",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:6,break:[2,3,4,5,6],h_level:2,para_data:{2:[z("feat_xmas_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:1,h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}}(a)}})(r),Cc(a,r,i);break;case"species":"planets"===r?Gn():function(e){let a=$("#content");switch(Ss(a),e){case"races":!function(e){e=Ln("create",e);let a=[];Object.keys(Ki).forEach((function(r){if("custom"===r&&!t.custom.hasOwnProperty("race0")||"protoplasm"===r)return;let i=$(`
                        `);e.append(i),i.append(`

                        ${Ki[r].name}

                        ${z(`genelab_genus_${Ki[r].type}`)}
                        `),i.append(`
                        ${"string"==typeof Ki[r].desc?Ki[r].desc:Ki[r].desc()}
                        `);let s=[],n=function(e){const t=new Date;let a=on();switch(e){case"wolven":return a.active?[{t:"hyper",r:1},{t:"fast_growth",r:1},{t:"rainbow",r:1},{t:"optimistic",r:1}]:[];case"vulpine":return a.active?[{t:"cannibalize",r:1},{t:"rage",r:1},{t:"blood_thirst",r:1},{t:"sticky",r:1}]:[];case"elven":return 11===t.getMonth()&&t.getDate()>=17?[{t:"slaver",r:2},{t:"resourceful",r:.5},{t:"small",r:.25}]:[];case"capybara":return 11===t.getMonth()&&t.getDate()>=17?[{t:"beast_of_burden",r:1},{t:"pack_rat",r:.5},{t:"musical",r:.25}]:[];case"centaur":return 11===t.getMonth()&&t.getDate()>=17?[{t:"beast_of_burden",r:1},{t:"curious",r:.5},{t:"blissful",r:.25}]:[];case"wendigo":return 11===t.getMonth()&&t.getDate()>=17?[{t:"immoral",r:3},{t:"cannibalize",r:.5},{t:"claws",r:.25}]:[];case"yeti":return 11===t.getMonth()&&t.getDate()>=17?[{t:"scavenger",r:3},{t:"regenerative",r:.5},{t:"musical",r:.25}]:[];case"entish":return 11===t.getMonth()&&t.getDate()>=17?[{t:"photosynth",r:3},{t:"optimistic",r:.5},{t:"armored",r:.25}]:[];default:return[]}}(r),c=$('
                        ');Object.keys(Li[Ki[r].type]).sort().forEach((function(e){let t=`raceTrait${r}${e}`,a=Ki[r].fanaticism===e?"danger":"caution";c.append(`${Ei[e].name}`),s.push({t:e,r:1})})),Object.keys(Ki[r].traits).sort().forEach((function(e){let t=`raceTrait${r}${e}`,a=Ki[r].fanaticism===e?"danger":"info";c.append(`${Ei[e].name}`),s.push({t:e,r:Ki[r].traits[e]})}));for(let e=0;e${Ei[n[e].t].name}`),s.push(n[e])}i.append(c),a.push(r),ls(`genus${r}`,$(`
                        ${z(`genelab_genus_${Ki[r].type}_desc`)}
                        `),{wide:!0,classes:"w25"});for(let e=0;e");vn(a,s[e].t,{fanatic:s[e].t===Ki[r].fanaticism&&Ki[r].name,trank:s[e].r,wiki:!0}),ls(t,a,{wide:!0,classes:"w25"})}})),a.sort(((e,t)=>Ki[e].nameas("name",e).localeCompare(as("name",t)))).forEach((function(r){if(t[a].includes(Ei[r].type)){let t=$(`
                        `);e.append(t),vn(t,r,{tpage:!0,wiki:!0}),Ln("add","traits-species",`${Ei[r].type}_${r}`,as("name",r))}}))}(a);break;case"custom":!function(e){In(e,{name:"custom",template:"mechanics",label:z("wiki_mechanics_custom"),paragraphs:12,break:[3,5,9,11],full:!0,h_level:2,para_data:{1:[z("wiki_resets_ascension")],2:[z("wiki_resets_ascension")],5:[z("resource_Genes_name")],6:[z("resource_Genes_name")],7:[2],8:[z("achieve_technophobe_name"),5,7],9:[z("tech_fanaticism"),z("tech_deify")],11:[0,z("resource_Genes_name")],12:[z("resource_Genes_name"),z("trait_untapped_name")]},data_link:{1:["wiki.html#resets-prestige-ascension"],2:["wiki.html#resets-prestige-ascension"],8:["wiki.html#perks-prestige-technophobe"],9:[t.genes.transcendence?"wiki.html#civilized-tech-alt_fanaticism":"wiki.html#civilized-tech-fanaticism","wiki.html#early_space-tech-deify"]}});let a=$('
                        ');e.append(a),Qt(a)}(a)}}(r),Cc(a,r,i);break;case"structures":Un(r,"standard"),Cc(a,r,i);break;case"tech":_c(r,"standard"),Cc(a,r,i);break;case"tp_structures":Un(r,"truepath"),Cc(a,r,i);break;case"tp_tech":_c(r,"truepath"),Cc(a,r,i);break;case"arpa":!function(e){let a=$("#content");switch(Ss(a),e){case"projects":!function(e){e.append(`
                        ${z("wiki_arpa_projects")}
                        `);let a=$("
                        "),r=Ln("create",a);e.append(a),Object.keys(qe).forEach((function(e){let a=$(`
                        `);r.append(a),function(e,a){let r="string"==typeof qe[a].title?qe[a].title:qe[a].title(!0);e.append(`

                        ${r}

                        `);let i=$('
                        ');if(e.append(i),i.append(`
                        ${"string"==typeof qe[a].desc?qe[a].desc:qe[a].desc()}
                        `),i.append(`
                        ${"string"==typeof qe[a].effect?qe[a].effect:qe[a].effect()}
                        `),Oc[a]){let t=$("
                        ");e.append(t),function(e,t){let a=$('
                        ');if(e.append(a),Oc.hasOwnProperty(t))for(let e=0;e${Oc[t][e]}`)}(t,a)}!function(e,a){let r={owned:0,creepVis:!0,extra:{creative:!1}},i={};switch(a){case"monument":r.extra.m_type="Obelisk";break;case"launch_facility":r.creepVis=!1}let s=qe[a];r.real_owned=t.arpa[a]?t.arpa[a].rank:0;let n=$('
                        ');e.append(n);let c=$(`

                        ${z("wiki_calc_cost")}

                        `),o=$(`

                        ${z("wiki_calc_cost_creep")}

                        `);n.append(c),n.append(o);let l=s.cost;Object.keys(Ae(l)).forEach((function(e){i[e]={};let a="Money"===e?"$":t.resource[e].name+": ";c.append($(`
                        ${a}{{ r.${e}.cost }}
                        `)),o.append($(`
                        {{ r.${e}.creep }}
                        `))}));let _=function(){let e=Ae(l,r.owned-r.real_owned,r.extra);Object.keys(i).forEach((function(t){let a=e[t]?e[t](r.owned-r.real_owned,r.extra):0;i[t].vis=a>0,i[t].cost=x(a,1)}))};_();let d=function(){if("launch_facility"!==a){let e=Ae(l,100,r.extra),t=Ae(l,99,r.extra);Object.keys(i).forEach((function(a){e[a]&&(i[a].creep=+(e[a](100,r.extra)/t[a](99,r.extra)).toFixed(4))}))}};d();let p='\n
                        \n
                        ';"launch_facility"!==a&&(p+=`\n
                        ${z("wiki_calc_level")} -+
                        `),"monument"===a&&(p+=`\n
                        ${z("wiki_calc_m_type")} \n \n {{ 'Obelisk' | monumentLabel }}\n {{ 'Statue' | monumentLabel }}\n {{ 'Sculpture' | monumentLabel }}\n {{ 'Monolith' | monumentLabel }}\n {{ 'Pillar' | monumentLabel }}\n {{ 'Megalith' | monumentLabel }}\n
                        \n `),p+=`\n
                        ${z("trait_creative_name")}
                        \n
                        \n
                        \n \n
                        \n
                        \n `,e.append($(p)),Cs({el:`#${a}`,data:{i:r,r:i},methods:{val(e){r[e]=Math.round(r[e]),r[e]&&r[e]<0&&(r[e]=0),_()},less(e){r[e]>0&&r[e]--},more(e){r[e]++},pickMonument(e){r.extra.m_type=e,_(),d()},update(){_(),d()},importInputs(){"launch_facility"!==a&&(r.owned=r.real_owned),r.extra.creative=!!t.race.creative,"monument"===a&&t.arpa.m_type&&(r.extra.m_type=t.arpa.m_type)}},filters:{monumentLabel(e){switch(e){case"Obelisk":return z("arpa_project_monument_obelisk");case"Statue":return z("arpa_project_monument_statue");case"Sculpture":return z("arpa_project_monument_sculpture");case"Monolith":return z("arpa_project_monument_monolith");case"Pillar":return z("arpa_project_monument_pillar");case"Megalith":return z("arpa_project_monument_megalith")}}}})}(e,a)}(a,e),Ln("add","projects-arpa",e,"string"==typeof qe[e].title?qe[e].title:qe[e].title(!0))}))}(a);break;case"genetics":break;case"crispr":$c(a);break;case"blood":Pc(a)}}(r),Cc(a,r,i);break;case"achievements":"tracker"===r||dc(r),Cc(a,r,i);break;case"changelog":!function(){let e=$("#content");Ss(e);for(let t=0;t');e.append(a);let r=Mc[t].hasOwnProperty("revision")?Mc[t].revision:"";a.append(`

                        v${Mc[t].version}${r}

                        ${Mc[t].date}
                        `);for(let e=0;e${Mc[t].changes[e]}`)}}(),window.location.hash=`#${a}`}}function Cc(e,t,a){void 0===a?window.location.hash=`#${t}-${e}`:(window.location.hash=`#${t}-${e}-${a}`,setTimeout((function(){document.getElementById(a).scrollIntoView({block:"start",behavior:"smooth"})}),125))}function zc(e,t,a){let r=!!window.location.hash&&window.location.hash.substring(1).split("-"),i="";for(let s=0;s1&&r[1]===e[s].key?' :active="true" expanded':""}>`,i+=zc(e[s].submenu,!1,e[s].key),i+="";else{let n=!r&&t&&0===s||r&&r[0]===e[s].key?' :active="true"':"",c=a?`'${a}','${e[s].key}'`:`'${e[s].key}',false`;i+=``}return i}function Fc(){let e=$("#content");Ss(e);let a=`${["Beorseder","Rodrigodd","Volch"].join(', ').replace(/, ([^,]*)$/,", & $1")}`,r=t.beta?`beta v${t.version}.${t.beta}`:"v"+t.version;e.append(`
                        ${z("wiki_main_title")} - ${r}
                        `),e.append(`
                        ${z("wiki_main_author",["Demagorddon"])}
                        `),e.append(`
                        ${z("wiki_main_spoiler")}
                        `),e.append(`
                        ${z("wiki_main_blurb")}
                        `),e.append(`
                        ${z("wiki_main_contribution",[a])}
                        `),e.append(`
                        ${z("wiki_resources")}
                        `);let i=$('
                          ');e.append(i),i.append(`
                        • ${z("wiki_resources_begin_guide")} ${z("wiki_resources_by",["GreyCat"])}
                        • `),i.append(`
                        • ${z("wiki_resources_tracker")} ${z("wiki_resources_by",["Karsen777"])}
                        • `)}$("body").empty(),function(){$("body").append($(`

                          ${z("wiki_menu_evolve")}

                          `));let e=$('
                          ');$("body").append(e);let t=$('');e.append(t);let a=`",t.append(a),Cs({el:"#menu",data:{},methods:{loadPage(e,t){Sc(e,t)}}});let r=$('
                          ');if(e.append(r),window.location.hash){let e=window.location.hash.substring(1).split("-");e.length>1?e.length>2?Sc(e[1],e[0],e[2]):Sc(e[1],e[0]):Sc(e[0])}else Fc()}()})(); \ No newline at end of file +(()=>{"use strict";var e=window.localStorage,t={seed:1,warseed:1,resource:{},evolution:{},tech:{},city:{},space:{},interstellar:{},portal:{},tauceti:{},civic:{},race:{},genes:{},blood:{},stats:{start:Date.now(),days:0,tdays:0},event:{t:200,l:!1},m_event:{t:499,l:!1}},a={},r={c:{},p:{}},i={},s={},n={},c={},o={},l={},_=0;var d={},p={},u={view:"all"};const h=["all","progress","queue","building_queue","research_queue","combat","spy","events","major_events","minor_events","achievements","hell"];function m(e,a,r){return a=a||1,e=e||0,t[r?"warseed":"seed"]=(9301*t[r?"warseed":"seed"]+49297)%233280,e+t[r?"warseed":"seed"]/233280*(a-e)}Math.rand=function(e,t){return Math.floor(Math.random()*(t-e))+e},t.seed=2,t.warseed=2;{let a=e.getItem("evolved")||!1;if(a){let e=JSON.parse(LZString.decompressFromUTF16(a));e?t=e:v()}else v()}if(t.version||(t.version="0.2.0"),b(t.version)<2060&&Object.keys(t.resource).forEach((function(e){t.resource[e].crates&&(t.resource[e].crates=Math.ceil(t.resource[e].crates/5)),t.resource[e].containers&&(t.resource[e].containers=Math.ceil(t.resource[e].containers/5))})),b(t.version)<2062&&void 0!==t.civic.taxes)switch(Number(t.civic.taxes.tax_rate)){case 0:t.civic.taxes.tax_rate=0;break;case 1:t.civic.taxes.tax_rate=10;break;case 2:t.civic.taxes.tax_rate=20;break;case 3:t.civic.taxes.tax_rate=30;break;case 4:t.civic.taxes.tax_rate=40;break;case 5:t.civic.taxes.tax_rate=50}if(2062===b(t.version)&&void 0!==t.civic.taxes&&2==t.civic.taxes.tax_rate&&(t.civic.taxes.tax_rate=20),b(t.version)<2065&&void 0!==t.race&&"sporgar"===t.race.species&&(delete t.race.crafty,delete t.race.hydrophilic,t.race.infectious=1,t.race.parasite=1,!t.tech.military&&t.tech.primitive&&t.tech.primitive>=3&&(t.civic.garrison.display=!0,t.settings.showCivic=!0,t.city.garrison={count:0})),b(t.version)<3002&&t.space&&(t.tech.space&&t.tech.space>=4&&(t.space.living_quarters||(t.space.living_quarters={count:0,on:0}),t.space.garage||(t.space.garage={count:0}),t.space.red_mine||(t.space.red_mine={count:0,on:0}),t.space.fabrication||(t.space.fabrication={count:0,on:0}),t.space.laboratory||(t.space.laboratory={count:0,on:0})),t.tech.space&&t.tech.space>=3&&(t.space.iridium_mine||(t.space.iridium_mine={count:0,on:0}),t.space.helium_mine||(t.space.helium_mine={count:0,on:0})),t.tech.hell&&(t.space.geothermal||(t.space.geothermal={count:0,on:0}))),b(t.version)<3004&&t.settings&&t.settings.space&&t.settings.space.belt&&(t.space.space_station={count:0,on:0,support:0,s_max:0}),b(t.version)<4001&&t.city&&t.city.factory&&!t.city.factory.Nano&&(t.city.factory.Nano=0),b(t.version)<4003&&t.stats.achieve&&Object.keys(t.stats.achieve).forEach((function(e){t.stats.achieve[e]=1})),b(t.version)<4028&&t.stats.achieve&&t.stats.achieve.genus_demonic&&(t.stats.achieve.biome_hellscape=t.stats.achieve.genus_demonic),b(t.version)<4029&&t.race.mutation&&t.race.mutation>0){t.resource.Genes={name:"Genes",display:!0,value:0,amount:0,crates:0,diff:0,delta:0,max:-2,rate:0};for(let e=0;e=3&&(t.tech.wind_plant=1,t.tech.hunting=2);let e=["Human","Humano","Elf","Elfo","Orc","Cath","Wolven","Centaur","Centauro","Kobold","Goblin","Gnome","Ogre","Ogro","Cyclops","Ciclope","Troll","Tortoisan","Gecko","Slitheryn","Arraak","Pterodacti","Dracnid","Ent","Cacti","Sporgar","Shroomi","Mantis","Scorpid","Antid","Sharkin","Octigoran","Balorg","Imp"];for(let a=0;a0){let e=1;t.race.no_trade&&e++,t.race.no_craft&&e++,t.race.no_crispr&&e++,t.race.weak_mastery&&e++,t.stats.achieve.cross={l:e,a:e}}if(b(t.version)<7e3&&(t.civic.govern||(t.civic.govern={type:"oligarchy",rev:0,fr:0})),b(t.version)<7004&&t.queue&&t.queue.queue)for(let e=0;e0&&(t.stats.harmony=parseFloat(t.stats.harmony.toFixed(2)),t.race.Harmony.count=parseFloat(t.race.Harmony.count.toFixed(2))),b(t.version)<8017&&t.city.garrison&&(t.city.garrison.on=t.city.garrison.count),b(t.version)<9005&&t.race.hasOwnProperty("terrifying")&&t.tech.hasOwnProperty("gambling")&&!t.space.hasOwnProperty("spc_casino")&&(t.space.spc_casino={count:0,on:0}),b(t.version)<9009&&t.genes.hasOwnProperty("ancients")&&t.genes.ancients>=3&&(4===t.genes.ancients?t.genes.ancients=5:t.race.Plasmid.count+=300),b(t.version)<9010&&(["species","gods","old_gods"].forEach((e=>{"orge"===t.race[e]&&(t.race[e]="ogre")})),t.stats.hasOwnProperty("achieve")&&t.stats.achieve.hasOwnProperty("extinct_orge")&&(t.stats.achieve.extinct_ogre=t.stats.achieve.extinct_orge,delete t.stats.achieve.extinct_orge),t.resource.hasOwnProperty("orge")&&(t.resource.ogre=t.resource.orge,delete t.resource.orge),t.city&&t.city.factory&&!t.city.factory.Furs&&(t.city.factory.Furs=0)),b(t.version)<9014&&(["seraph","unicorn","custom"].forEach((e=>{t.race.species===e&&("custom"===e&&t.hasOwnProperty("custom")&&"angelic"===t.custom.race0.genus||"custom"!==e)&&(t.race.holy=1)})),t.hasOwnProperty("arpa")&&t.arpa.hasOwnProperty("sequence")&&(t.arpa.sequence.labs=0)),b(t.version)<1e5&&(delete t.city.lumber,delete t.city.stone,t.stats.dark=0,t.race.Dark&&(t.stats.dark=t.race.Dark.count),t.city.hasOwnProperty("smelter")&&(t.city.smelter.hasOwnProperty("Star")||(t.city.smelter.Star=0),t.city.smelter.hasOwnProperty("StarCap")||(t.city.smelter.StarCap=0),t.city.smelter.hasOwnProperty("Inferno")||(t.city.smelter.Inferno=0)),t.hasOwnProperty("warseed")||(t.warseed=t.seed+1,Math.war=t.hasOwnProperty("warseed")?t.warseed:t.seed),t.portal.hasOwnProperty("bireme")&&(t.portal.bireme.crew=0,t.portal.bireme.mil=0),t.portal.hasOwnProperty("transport")&&(t.portal.transport.crew=0,t.portal.transport.mil=0,t.portal.transport.cargo||(t.portal.transport.cargo={used:0,max:0,Crystal:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0})),t.hasOwnProperty("settings")&&t.settings.portal&&t.settings.portal.spire&&!t.portal.hasOwnProperty("purifier")&&(t.settings.portal.spire=!1),t.portal.hasOwnProperty("mechbay")&&!Array.isArray(t.portal.mechbay.mechs)&&(t.portal.mechbay.mechs=[]),t.portal.transport&&t.portal.transport.count>=1&&!t.tech.hell_spire&&(t.tech.hell_spire=1,t.settings.portal.spire=!0,t.settings.showCargo=!0,t.portal.purifier={count:0,on:0,support:0,s_max:0,supply:0,sup_max:100,diff:0},t.portal.port={count:0,on:0}),t.tech.hasOwnProperty("waygate")&&!t.portal.hasOwnProperty("waygate")&&delete t.tech.waygate,t.hasOwnProperty("blood")||(t.blood={})),b(t.version)<100013&&t.hasOwnProperty("settings")&&t.settings.hasOwnProperty("showPowerGrid")&&t.hasOwnProperty("race")&&t.race.infiltrator&&t.hasOwnProperty("tech")&&t.tech.hasOwnProperty("high_tech")&&t.tech.high_tech>=2&&(t.settings.showPowerGrid=!0),b(t.version)<100014&&(t.race.Dark&&(t.stats.dark=t.race.Dark.count),t.race.casting&&t.race.evil&&(t.race.casting.total-=t.race.casting.lumberjack,t.race.casting.lumberjack=0),t.queue&&t.queue.queue))for(let e=0;e=2,events:!0,major_events:!0,minor_events:!0,achievements:t.stats.achieve&&Object.keys(t.stats.achieve).length>0||t.stats.feat&&Object.keys(t.stats.feat).length>0,hell:t.settings.showPortal||t.stats.blackhole||t.stats.ascend||t.stats.descend}),t.race.hasOwnProperty("inflation")&&["supercollider","stock_exchange","launch_facility","monuments","railway","roid_eject","nexus","syphon"].forEach((function(e){t.tech.hasOwnProperty(e)&&(t.race.inflation+=10*t.tech[e])}))),b(t.version)<101012&&t.civic.garrison&&(t.civic.garrison.rate=0),b(t.version)<101014&&(t.hasOwnProperty("settings")&&t.settings.hasOwnProperty("msgFilters")&&Object.keys(t.settings.msgFilters).forEach((function(e){t.settings.msgFilters[e]={unlocked:!!t.settings.msgFilters[e],vis:!!t.settings.msgFilters[e],max:60,save:3}})),t.hasOwnProperty("lastMsg")&&t.lastMsg)){let e={};h.forEach((function(t){e[t]=[]})),t.lastMsg.forEach((function(t){t.t?t.t.forEach((function(a){e[a].push({m:t.m,c:t.c})})):e.all.push({m:t.m,c:t.c})})),t.lastMsg=e}if(b(t.version)<=101014&&!t.revision&&t.race.cataclysm&&t.race.universe&&"magic"===t.race.universe&&t.tech.magic&&t.tech.magic>=2&&(t.space.pylon={count:0}),b(t.version)<101015&&t.hasOwnProperty("special")&&t.special.hasOwnProperty("trick")&&(t.special.trick[2020]=JSON.parse(JSON.stringify(t.special.trick)),delete t.special.trick.trick1,delete t.special.trick.trick2,delete t.special.trick.trick3,delete t.special.trick.trick4,delete t.special.trick.trick5,delete t.special.trick.trick6,delete t.special.trick.trick7,delete t.special.trick.trick8,delete t.special.trick.trick9,delete t.special.trick.trick10,delete t.special.trick.trick11,delete t.special.trick.trick12),b(t.version)<102e3&&(t.hasOwnProperty("portal")&&t.portal.hasOwnProperty("fortress")&&!t.portal.fortress.hasOwnProperty("nocrew")&&(t.portal.fortress.nocrew=!1),t.city.hasOwnProperty("smelter")&&!t.city.smelter.hasOwnProperty("Iridium")&&(t.city.smelter.Iridium=0),t.hasOwnProperty("portal")&&t.portal.hasOwnProperty("mechbay")&&!t.portal.mechbay.hasOwnProperty("active")&&(t.portal.mechbay.active=0,t.portal.mechbay.scouts=0)),b(t.version)<102001&&(t.race.blood_thirst&&t.race.blood_thirst>3&&(t.race.blood_thirst=1),t.race.rainbow&&t.race.rainbow>3&&(t.race.rainbow=1)),b(t.version)<102005&&!t.stats.cores&&t.race.hasOwnProperty("AICore")&&(t.stats.cores=t.race.AICore.count),b(t.version)<102006&&t.race.artifical&&(t.race.calm&&(t.resource.hasOwnProperty("Zen")&&(t.resource.Zen.display=!0),t.city.meditation={count:0}),t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0})),b(t.version)<102007&&t.stats.hasOwnProperty("achieve")&&delete t.stats.achieve.extinct_sludge,b(t.version)<102012&&(t.city.hasOwnProperty("ptrait")&&(t.city.ptrait="none"===t.city.ptrait?[]:[t.city.ptrait]),t.tech.hell_ruins&&t.tech.hell_ruins>=3&&(t.tech.hell_vault=1)),b(t.version)<102015){if(t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks"))for(let e in t.race.governor.tasks)"asssemble"===t.race.governor.tasks[e]&&(t.race.governor.tasks[e]="assemble");t.settings&&t.settings.hasOwnProperty("restoreCheck")&&delete t.settings.restoreCheck}if(b(t.version)<102017&&(t.portal.hasOwnProperty("fortress")&&(t.portal.observe={settings:{expanded:!1,average:!1,hyperSlow:!1,display:"game_days",dropKills:!0,dropGems:!0},stats:{total:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0}},period:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0}}},graphID:0,graphs:{}}),t.tech.hasOwnProperty("genetics")&&t.tech.genetics>1&&t.hasOwnProperty("arpa")&&(t.arpa.hasOwnProperty("sequence")||(t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!1}),t.arpa.sequence.boost||(t.arpa.sequence.boost=!1),t.arpa.sequence.auto||(t.arpa.sequence.auto=!1),t.arpa.sequence.labs||(t.arpa.sequence.labs=0))),b(t.version)<102021&&t.hasOwnProperty("custom")&&!t.custom.hasOwnProperty("race0")){let e=t.race.hasOwnProperty("species")?t.race.species:"protoplasm";t.galaxy.hasOwnProperty("alien1")&&"custom"===t.galaxy.alien1.id&&(t.galaxy.alien1.id="human"===e?"elven":"human"),t.galaxy.hasOwnProperty("alien2")&&"custom"===t.galaxy.alien2.id&&(t.galaxy.alien2.id="orc"===e||"orc"===t.galaxy.alien1.id?"cath":"orc")}function g(){["reset","plasmid","antiplasmid","universes","phage","starved","tstarved","died","tdied","sac","tsac","know","tknow","portals","dkills","attacks","cfood","tfood","cstone","tstone","clumber","tlumber","mad","bioseed","cataclysm","blackhole","ascend","descend","terraform","aiappoc","matrix","retire","eden","geck","dark","harmony","blood","cores","artifact","cattle","tcattle","murders","tmurders","psykill","tpsykill"].forEach((function(e){t.stats.hasOwnProperty(e)||(t.stats[e]=0)})),t.stats.achieve||(t.stats.achieve={}),t.stats.feat||(t.stats.feat={}),t.stats.hasOwnProperty("womling")||(t.stats.womling={god:{l:0},lord:{l:0},friend:{l:0}}),t.stats.spire||(t.stats.spire={}),t.stats.synth||(t.stats.synth={}),t.stats.hasOwnProperty("banana")||(t.stats.banana={b1:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b2:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b3:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b4:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1},b5:{l:!1,h:!1,a:!1,e:!1,m:!1,mg:!1}})}if(b(t.version)<103e3&&(t.hasOwnProperty("tauceti")||(t.tauceti={}),"protoplasm"===t.race.species&&(t.evolution.hasOwnProperty("sexual_reproduction")&&(t.tech.evo=t.evolution.sexual_reproduction.count>0?2:1,delete t.evolution.sexual_reproduction),[["phagocytosis",{evo:3,evo_animal:1}],["chloroplasts",{evo:3,evo_plant:1}],["chitin",{evo:3,evo_fungi:1}],["exterminate",{evo:7,evo_synthetic:2}],["multicellular",{evo:4}],["spores",{evo:5}],["poikilohydric",{evo:5}],["bilateral_symmetry",{evo:5,evo_insectoid:1,evo_mammals:1,evo_eggshell:1,evo_aquatic:1,evo_fey:1,evo_sand:1,evo_heat:1,evo_polar:1}],["bryophyte",{evo:7}],["athropods",{evo:7,evo_insectoid:2}],["mammals",{evo:6,evo_humanoid:1,evo_giant:1,evo_small:1,evo_animalism:1,evo_demonic:1,evo_angelic:1}],["humanoid",{evo:7,evo_humanoid:2}],["gigantism",{evo:7,evo_giant:2}],["dwarfism",{evo:7,evo_small:2}],["animalism",{evo:7,evo_animalism:2}],["carnivore",{evo_animalism:3,evo_carnivore:2}],["herbivore",{evo_animalism:3,evo_herbivore:2}],["omnivore",{evo_animalism:3,evo_omnivore:2}],["celestial",{evo:7,evo_angelic:2}],["demonic",{evo:7,evo_demonic:2}],["aquatic",{evo:7,evo_aquatic:2}],["fey",{evo:7,evo_fey:2}],["heat",{evo:7,evo_heat:2}],["polar",{evo:7,evo_polar:2}],["sand",{evo:7,evo_sand:2}],["eggshell",{evo:6,evo_eggshell:2}],["endothermic",{evo:7,evo_avian:2}],["ectothermic",{evo:7,evo_reptilian:2}],["bunker",{evo_challenge:1}]].forEach((function(e){if(t.evolution.hasOwnProperty(e[0])&&t.evolution[e[0]].count>0)for(let[a,r]of Object.entries(e[1]))t.tech[a]=r;delete t.evolution[e[0]]})),t.evolution.mloaded=1,t.evolution.gmloaded=1)),b(t.version)<103001&&(t.hasOwnProperty("prestige")||(t.prestige={}),t.race.Plasmid&&t.race.Plasmid.hasOwnProperty("anti")&&(t.prestige.AntiPlasmid={count:t.race.Plasmid.anti}),["Plasmid","Phage","AICore","Dark","Harmony"].forEach((function(e){t.race.hasOwnProperty(e)&&(t.prestige[e]={count:t.race[e].count},delete t.race[e])})),["Artifact","Blood_Stone"].forEach((function(e){t.resource.hasOwnProperty(e)&&(t.prestige[e]={count:t.resource[e].amount},delete t.resource[e])})),!t.stats.hasOwnProperty("synth")&&t.race.hasOwnProperty("srace")&&(t.stats.synth={},t.stats.synth[t.race.srace]=!0),t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("config")&&t.race.governor.config.hasOwnProperty("trash")&&["Infernite","Elerium","Copper","Iron"].forEach((function(e){t.race.governor.config.trash.hasOwnProperty(e)&&"number"==typeof t.race.governor.config.trash[e]&&(t.race.governor.config.trash[e]={v:t.race.governor.config.trash[e],s:!0})}))),b(t.version)<103002&&t.portal.hasOwnProperty("observe")&&t.portal.observe.hasOwnProperty("stats")&&(t.portal.observe.stats.period.gems.surveyors=0,t.portal.observe.stats.total.gems.surveyors=0),t.version="1.3.8",t.revision="a",delete t.beta,t.hasOwnProperty("prestige")||(t.prestige={}),["Plasmid","AntiPlasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone"].forEach((function(e){t.prestige.hasOwnProperty(e)||(t.prestige[e]={count:0})})),t.hasOwnProperty("power")||(t.power=[]),t.hasOwnProperty("support")||(t.support={}),["moon","red","belt","alpha","nebula","gateway","alien2","lake","spire","titan","enceladus","eris","tau_home","tau_red","tau_roid"].forEach((function(e){t.support.hasOwnProperty(e)||(t.support[e]=[])})),t.civic.cement_worker&&.25===t.civic.cement_worker.impact&&(t.civic.cement_worker.impact=.4),t.settings||(t.settings={showEvolve:!0,showAchieve:!1,animated:!0,disableReset:!1,font:"standard",q_merge:"merge_nearby",cLabels:!0,theme:"gruvboxDark",locale:"en-US",icon:"star"}),t.settings.space||(t.settings.space={}),t.settings.space.hasOwnProperty("home")||(t.settings.space.home=!0),M(!1),t.settings.icon||(t.settings.icon="star"),t.settings.showResources||(t.settings.showResources=t.settings.showMarket),t.settings.showStorage||(t.city.warehouse||t.city.storage_yard?t.settings.showStorage=!0:t.settings.showStorage=!1),t.settings.hasOwnProperty("touch")||(t.settings.touch=!1),t.settings.hasOwnProperty("lowPowerBalance")||(t.settings.lowPowerBalance=!1),t.queue||(t.queue={display:!1,queue:[]}),t.r_queue||(t.r_queue={display:!1,queue:[]}),t.queue.rename||(t.queue.rename=!1),t.queue.max||(t.queue.max=0),t.r_queue.max||(t.r_queue.max=0),t.queue.pause||(t.queue.pause=!1),t.r_queue.pause||(t.r_queue.pause=!1),t.lastMsg||(t.lastMsg={}),t.settings.msgFilters||(t.settings.msgFilters={}),["all","progress","events","major_events","minor_events"].forEach((function(e){t.settings.msgFilters[e]||(t.settings.msgFilters[e]={unlocked:!0,vis:!0,max:60,save:3})})),h.forEach((function(e){t.lastMsg[e]||(t.lastMsg[e]=[]),t.settings.msgFilters[e]||(t.settings.msgFilters[e]={unlocked:!1,vis:!1,max:60,save:3})})),t.settings.msgQueueHeight||(t.settings.msgQueueHeight=$("#msgQueue").outerHeight(),t.settings.buildQueueHeight=$("#buildQueue").outerHeight()),t.space||(t.space={}),t.starDock||(t.starDock={}),t.interstellar||(t.interstellar={}),t.galaxy||(t.galaxy={}),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Bolognium&&(t.interstellar.mass_ejector.Bolognium=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Vitreloy&&(t.interstellar.mass_ejector.Vitreloy=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Orichalcum&&(t.interstellar.mass_ejector.Orichalcum=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Nanoweave&&(t.interstellar.mass_ejector.Nanoweave=0),t.interstellar.mass_ejector&&!t.interstellar.mass_ejector.Scarletite&&(t.interstellar.mass_ejector.Scarletite=0),t.hasOwnProperty("pillars")||(t.pillars={}),t.settings.space.alpha||(t.settings.space.alpha=!1,t.settings.space.proxima=!1,t.settings.space.nebula=!1,t.settings.space.neutron=!1,t.settings.space.blackhole=!1),t.settings.showAchieve||(t.settings.showAchieve=!1),t.settings.locale||(t.settings.locale="en-us"),void 0===t.settings.pause&&(t.settings.pause=!1),void 0===t.settings.mKeys&&(t.settings.mKeys=!0),void 0===t.settings.keyMap&&(t.settings.keyMap={x10:"Control",x25:"Shift",x100:"Alt",q:"q"}),void 0===t.settings.keyMap.showCiv&&(t.settings.keyMap.showCiv="1",t.settings.keyMap.showCivic="2",t.settings.keyMap.showResearch="3",t.settings.keyMap.showResources="4",t.settings.keyMap.showGenetics="5",t.settings.keyMap.showAchieve="6",t.settings.keyMap.settings="7"),delete t.settings.keyMap.d,void 0===t.settings.qAny&&(t.settings.qAny=!1),void 0===t.settings.sPackOn&&(t.settings.sPackOn=!0),void 0===t.settings.qAny_res&&(t.settings.qAny_res=!1),void 0===t.settings.sPackMsg&&(t.settings.sPackMsg=!1),void 0===t.settings.expose&&(t.settings.expose=!1),void 0===t.settings.tabLoad&&(t.settings.tabLoad=!1),void 0===t.settings.boring&&(t.settings.boring=!1),t.settings.hasOwnProperty("mtorder")||(t.settings.mtorder=[]),g(),t.race.seeded||(t.race.seeded=!1),t.race.deterioration||(t.race.deterioration=0),t.race.gene_fortify||(t.race.gene_fortify=0),t.race.old_gods||(t.race.old_gods="none"),t.race.universe||(t.race.universe="standard"),t.genes.minor||(t.genes.minor={}),t.race.minor||(t.race.minor={}),t.hasOwnProperty("govern")||(t.govern={governor:{},candidate:[],policy:{}}),t.settings.hasOwnProperty("showMil")||(t.settings.showMil=!0),t.settings.hasOwnProperty("showPowerGrid")||(t.settings.showPowerGrid=!!(t.hasOwnProperty("tech")&&t.tech.hasOwnProperty("high_tech")&&t.tech.high_tech>=2)),t.settings.affix||(t.settings.affix="si"),t.special||(t.special={}),t.special.gift||(t.special.gift={}),t.special.hasOwnProperty("egg")||(t.special.egg={}),t.special.hasOwnProperty("trick")||(t.special.trick={trick1:!1,trick2:!1,trick3:!1,trick4:!1,trick5:!1,trick6:!1,trick7:!1,trick8:!1,trick9:!1,trick10:!1,trick11:!1,trick12:!1}),t.civic.govern||(t.civic.govern={type:"oligarchy",rev:2e3,fr:0}),t.civic.govern.fr=0,t.hasOwnProperty("custom")||(t.custom={}),t.custom.hasOwnProperty("planet")&&t.custom.planet.hasOwnProperty("biome")&&delete t.custom.planet,t.city.hasOwnProperty("smelter")&&!t.city.smelter.hasOwnProperty("cap")&&(t.city.smelter.cap=0),t.civic.homeless||(t.civic.homeless=0),t.civic.foreign||(t.civic.foreign={gov0:{unrest:0,hstl:100,mil:100,eco:75,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov1:{unrest:0,hstl:0,mil:150,eco:100,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov2:{unrest:0,hstl:50,mil:250,eco:150,spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1}}),void 0===t.civic.foreign.gov0.trn&&(t.civic.foreign.gov0.trn=0,t.civic.foreign.gov1.trn=0,t.civic.foreign.gov2.trn=0,t.civic.foreign.gov0.sab=0,t.civic.foreign.gov1.sab=0,t.civic.foreign.gov2.sab=0,t.civic.foreign.gov0.act="none",t.civic.foreign.gov1.act="none",t.civic.foreign.gov2.act="none"),void 0!==t.civic.foreign.gov0.name&&"evo_organism_title"===t.civic.foreign.gov0.name.s1&&(t.civic.foreign.gov0.name.s1="Northern"),void 0!==t.civic.foreign.gov1.name&&"evo_organism_title"===t.civic.foreign.gov1.name.s1&&(t.civic.foreign.gov1.name.s1="Southern"),void 0!==t.civic.foreign.gov2.name&&"evo_organism_title"===t.civic.foreign.gov2.name.s1&&(t.civic.foreign.gov2.name.s1="Divine"),!t.race.evil&&t.race.immoral&&void 0!==t.race&&"wendigo"!==t.race.species)delete t.race.immoral;else if(void 0!==t.race&&"wendigo"===t.race.species){const e=new Date;t.settings.hasOwnProperty("boring")&&!t.settings.boring&&11===e.getMonth()&&e.getDate()>=17&&(t.race.immoral=3)}if(t.hasOwnProperty("special")&&t.special.hasOwnProperty("gift")){const e=new Date(t.stats.start),a=new Date;Object.keys(t.special.gift).forEach((function(r){let i=Number(r.substring(1,5));(i=1?t.civic.d_job="farmer":t.civic.d_job="unemployed"),t.settings.animated=!0,t.settings.disableReset=!1,t.arpa&&t.arpa.launch_facility&&t.arpa.launch_facility.rank>0&&!t.tech.space&&(t.tech.space=1);var f={x10:!1,x25:!1,x100:!1,q:!1};function y(){let e=1;return t.settings.mKeys&&(f.x10&&(e*=10),f.x25&&(e*=25),f.x100&&(e*=100)),e}function b(e){let t=e.split(".",3);return t[0]*=1e5,t[1]*=1e3,Number(t[0])+Number(t[1])+Number(t[2])}function w(){if($(window).width()>=1400&&$("#msgQueue:not(.right)")){let e=$("#buildQueue").detach();e.addClass("right"),e.removeClass("has-text-info");let t=$("#msgQueue").detach();t.addClass("right"),t.removeClass("has-text-info"),t.css("resize","none"),$("#queueColumn").addClass("is-one-quarter"),$("#queueColumn").append(e),$("#queueColumn").append(t),$("#mainColumn").removeClass("is-three-quarters"),$("#mainColumn").addClass("is-half")}else if($(window).width()<1400&&$("#msgQueue").hasClass("right")){let e=$("#buildQueue").detach();e.removeClass("right"),e.addClass("has-text-info");let t=$("#msgQueue").detach();t.removeClass("right"),t.addClass("has-text-info"),t.css("resize","vertical"),$("#queueColumn").removeClass("is-one-quarter"),$("#sideQueue").append(e),$("#sideQueue").append(t),$("#mainColumn").removeClass("is-half"),$("#mainColumn").addClass("is-three-quarters")}}var k={si:["K","M","G","T","P","E","Z","Y"],sci:["e3","e6","e9","e12","e15","e18","e21","e24"],sln:["K","M","B","t","q","Q","s","S"]};function x(e,a,r){let i=0,s="",n=e<0;return n&&(e*=-1),e<=9999?i=+e.toFixed(a):e<1e6?(s=k[t.settings.affix][0],i=r?+(e/1e3).toFixed(1):Math.floor(e/100)/10):e<1e9?(s=k[t.settings.affix][1],i=r?+(e/1e6).toFixed(1):Math.floor(e/1e4)/100):e<1e12?(s=k[t.settings.affix][2],i=r?+(e/1e9).toFixed(1):Math.floor(e/1e7)/100):e<1e15?(s=k[t.settings.affix][3],i=r?+(e/1e12).toFixed(1):Math.floor(e/1e10)/100):e<1e18?(s=k[t.settings.affix][4],i=r?+(e/1e15).toFixed(1):Math.floor(e/1e13)/100):e<1e21?(s=k[t.settings.affix][5],i=r?+(e/1e18).toFixed(1):Math.floor(e/1e16)/100):e<1e24?(s=k[t.settings.affix][6],i=r?+(e/1e21).toFixed(1):Math.floor(e/1e19)/100):(s=k[t.settings.affix][7],i=r?+(e/1e24).toFixed(1):Math.floor(e/1e22)/100),i>=100&&(i=+i.toFixed(1)),n&&(i*=-1),i+s}function q(e,t){var a=document.createElement("div"),r="speak-"+Date.now();a.setAttribute("id",r),a.setAttribute("aria-live",t||"polite"),a.classList.add("sr-only"),document.body.appendChild(a),window.setTimeout((function(){document.getElementById(r).innerHTML=e}),100),window.setTimeout((function(){document.body.removeChild(document.getElementById(r))}),1e3)}$(window).resize((function(){w()})),window.soft_reset=function(a){try{a=a&&"replicator"===a?"replicator":"soft",gtag("event","reset",{end:a})}catch(e){}a||O();let r=!!t.race.hasOwnProperty("srace")&&t.race.srace,i=t.race.hasOwnProperty("geck")?t.race.geck:0;t.race.hasOwnProperty("gecked")&&(i+=t.race.gecked,t.stats.geck-=t.race.gecked);let s={species:"protoplasm",universe:t.race.universe,seeded:t.race.seeded,probes:t.race.probes,seed:t.race.seed,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended,rejuvenated:!!t.race.hasOwnProperty("rejuvenated")&&t.race.rejuvenated};i>0&&(s.geck=i),r&&(s.srace=r),t.race.bigbang&&(s.bigbang=!0),t.race.gods&&(s.gods=t.race.gods),t.race.old_gods&&(s.old_gods=t.race.old_gods),t.race.rapid_mutation&&t.race.rapid_mutation>0&&(s.rapid_mutation=t.race.rapid_mutation),t.race.ancient_ruins&&t.race.ancient_ruins>0&&(s.ancient_ruins=t.race.ancient_ruins),t.race.bigbang&&(s.universe="bigbang"),t.race.hasOwnProperty("corruption")&&(s.corruption=t.race.corruption),t.race=s;let n=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,l=t.city.geology;t.city={calendar:{day:0,year:0,weather:2,temp:1,moon:0,wind:0,orbit:n},biome:c,ptrait:o,geology:l},t.tech.theology&&t.tech.theology>=1?t.tech={theology:1}:t.tech={},S(),t.new=!0,t.seed=Math.rand(0,1e4),t.warseed=Math.rand(0,1e4),t.stats.current=Date.now(),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()};var P={w:!1,s:!1,timers:{},resetTimers(){this.timers={main:250,mid:1e3,long:5e3}}},j={};function O(){h.forEach((function(e){"achievements"!==e&&(t.lastMsg[e]=[])}))}function M(e){let a={base:["showCiv","showCity","showIndustry","showPowerGrid","showMechLab","showShipYard","showResearch","showCivic","showMil","showResources","showMarket","showStorage","showGenetics","showSpace","showDeep","showGalactic","showPortal","showOuter","showTau","showEjector","showCargo","showAlchemy","showGovernor","arpa","showPsychic"],space:["moon","red","hell","sun","gas","gas_moon","belt","dwarf","alpha","proxima","nebula","neutron","blackhole","sirius","stargate","gateway","gorddon","alien1","alien2","chthonian","titan","enceladus","triton","eris","kuiper"],portal:["fortress","badlands","pit","ruins","gate","lake","spire"],tau:["home","red","roid","gas","gas2","star"]};Object.keys(a).forEach((function(r){"base"===r?a[r].forEach((function(a){t.settings.hasOwnProperty(a)&&!e||(t.settings[a]=!1)})):(t.settings.hasOwnProperty(r)||(t.settings[r]={}),a[r].forEach((function(a){t.settings[r].hasOwnProperty(a)&&!e||(t.settings[r][a]=!1)})))})),["civTabs","govTabs","govTabs2","hellTabs","resTabs","spaceTabs","marketTabs","statsTabs"].forEach((function(a){t.settings.hasOwnProperty(a)&&!e||(t.settings[a]=0)}))}function S(){P.w&&P.w.terminate(),t.queue={display:!1,queue:[]},t.r_queue={display:!1,queue:[]},t.space={},t.interstellar={},t.galaxy={},t.portal={},t.starDock={},t.tauceti={},t.civic={new:0},t.civic.foreign={gov0:{unrest:0,hstl:Math.floor(m(80,100)),mil:Math.floor(m(75,125)),eco:Math.floor(m(60,90)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov1:{unrest:0,hstl:Math.floor(m(0,20)),mil:Math.floor(m(125,175)),eco:Math.floor(m(80,120)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1},gov2:{unrest:0,hstl:Math.floor(m(40,60)),mil:Math.floor(m(200,300)),eco:Math.floor(m(130,170)),spy:0,esp:0,trn:0,sab:0,act:"none",occ:!1,anx:!1,buy:!1}},t.genes.blood||(t.prestige.Blood_Stone.count=0),t.resource={},t.evolution={},t.event={t:100,l:!1},t.m_event={t:499,l:!1},t.stats.days=0,t.stats.know=0,t.stats.starved=0,t.stats.died=0,t.stats.attacks=0,t.stats.dkills=0,t.stats.cfood=0,t.stats.cstone=0,t.stats.clumber=0,t.stats.sac=0,t.stats.cattle=0,t.stats.murders=0,t.settings.at=0,t.settings.showEvolve=!0,t.settings.space.home=!0,M(!0),t.settings.disableReset=!1,t.settings.pause=!1,t.arpa={},delete t.race.hrt,t.genes.queue&&(t.tech.queue=1,t.queue.display=!0)}let C;function z(e,a){let r=C[e];if(!r)return t.settings.expose&&(console.error(`string ${e} not found`),console.log(C)),e;if(a)if(a instanceof Array){for(let i=0;i{r=e})),"en-US"!=a){let e;try{$.getJSON(`strings/strings.${a}.json`,(t=>{e=t}))}catch(e){console.error(e,e.stack)}const i=r.length;e&&Object.assign(r,e),r.length!=i&&t.settings.expose&&console.error(`string.${a}.json has extra keys.`)}let i=e.getItem("string_pack")||!1;if(i&&t.settings.sPackOn){let e;try{e=JSON.parse(LZString.decompressFromUTF16(i))}catch(e){console.error(e,e.stack)}const a=r.length;e&&Object.assign(r,e),r.length!=a&&t.settings.expose&&console.error("string pack has extra keys.")}$.ajaxSetup({async:!0}),C=r}(t.settings.locale);const F={soldier:{name:z("governor_soldier"),desc:z("governor_soldier_desc"),title:[z("governor_soldier_t1"),z("governor_soldier_t2"),z("governor_soldier_t3")],traits:{tactician:1,militant:1}},criminal:{name:z("governor_criminal"),desc:z("governor_criminal_desc"),title:[z("governor_criminal_t1"),z("governor_criminal_t2"),{m:z("governor_criminal_t3m"),f:z("governor_criminal_t3f")}],traits:{noquestions:1,racketeer:1}},entrepreneur:{name:z("governor_entrepreneur"),desc:z("governor_entrepreneur_desc"),title:[z("governor_entrepreneur_t1"),z("governor_entrepreneur_t2"),{m:z("governor_entrepreneur_t3m"),f:z("governor_entrepreneur_t3f")}],traits:{dealmaker:1,risktaker:1}},educator:{name:z("governor_educator"),desc:z("governor_educator_desc"),title:[z("governor_educator_t1"),z("governor_educator_t2"),z("governor_educator_t3")],traits:{teacher:1,theorist:1}},spiritual:{name:z("governor_spiritual"),desc:z("governor_spiritual_desc"),title:[z("governor_spiritual_t1"),z("governor_spiritual_t2"),z("governor_spiritual_t3")],traits:{inspirational:1,pious:1}},bluecollar:{name:z("governor_bluecollar"),desc:z("governor_bluecollar_desc"),title:[{m:z("governor_bluecollar_t1m"),f:z("governor_bluecollar_t1f")},z("governor_bluecollar_t2"),{m:z("governor_bluecollar_t3m"),f:z("governor_bluecollar_t3f")}],traits:{pragmatist:1,dirty_jobs:1}},noble:{name:z("governor_noble"),desc:z("governor_noble_desc"),title:[{m:z("governor_noble_t1m"),f:z("governor_noble_t1f")},{m:z("governor_noble_t2m"),f:z("governor_noble_t2f")},{m:z("governor_noble_t3m"),f:z("governor_noble_t3f")},{m:z("governor_noble_t4m"),f:z("governor_noble_t4f")}],traits:{extravagant:1,aristocrat:1}},media:{name:z("governor_media"),desc:z("governor_media_desc"),title:[z("governor_media_t1"),{m:z("governor_media_t2m"),f:z("governor_media_t2f")},z("governor_media_t3")],traits:{gaslighter:1,muckraker:1}},sports:{name:z("governor_sports"),desc:z("governor_sports_desc"),title:[z("governor_sports_t1"),z("governor_sports_t2"),z("governor_sports_t3")],traits:{athleticism:1,nopain:1}},bureaucrat:{name:z("governor_bureaucrat"),desc:z("governor_bureaucrat_desc"),title:[z("governor_bureaucrat_t1"),{m:z("governor_bureaucrat_t2m"),f:z("governor_bureaucrat_t2f")},z("governor_bureaucrat_t3")],traits:{organizer:1}}},A={tactician:{name:z("gov_trait_tactician"),effect(){return z("gov_trait_tactician_effect",[$(this)[0].vars()[0]])},vars:()=>[25]},militant:{name:z("gov_trait_militant"),effect(){return z("gov_trait_militant_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[25,10]},noquestions:{name:z("gov_trait_noquestions"),effect(){return z("gov_trait_noquestions_effect",[$(this)[0].vars()[0]])},vars:()=>[.005]},racketeer:{name:z("gov_trait_racketeer"),effect(){return z("gov_trait_racketeer_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[20,35]},dealmaker:{name:z("gov_trait_dealmaker"),effect(){return z("gov_trait_dealmaker_effect",[$(this)[0].vars()[0]])},vars:()=>[125]},risktaker:{name:z("gov_trait_risktaker"),effect(){return z("gov_trait_risktaker_effect",[$(this)[0].vars()[0]])},vars:()=>[12]},teacher:{name:z("gov_trait_teacher"),effect(){return z("gov_trait_teacher_effect",[$(this)[0].vars()[0]])},vars:()=>[6]},theorist:{name:z("gov_trait_theorist"),effect(){return z("gov_trait_theorist_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,4]},inspirational:{name:z("gov_trait_inspirational"),effect(){return z("gov_trait_inspirational_effect",[$(this)[0].vars()[0]])},vars:()=>[20]},pious:{name:z("gov_trait_pious"),effect(){let e=$(this)[0].vars()[1],a=t.tech.monument&&t.tech.monument>=3&&s.s_gate?3:1;return e=("corpocracy"===t.civic.govern.type?2*e:e)*a,z("gov_trait_pious_effect",[$(this)[0].vars()[0],e])},vars:()=>[10,5]},pragmatist:{name:z("gov_trait_pragmatist"),effect(){return z("gov_trait_pragmatist_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,2]},dirty_jobs:{name:z("gov_trait_dirty_jobs"),effect(){return z("gov_trait_dirty_jobs_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[.015,1,10]},extravagant:{name:z("gov_trait_extravagant"),effect(){return z("gov_trait_extravagant_effect",[$(this)[0].vars()[0],pi("large",!0),$(this)[0].vars()[1],$(this)[0].vars()[2]+5])},vars:()=>[10,1.25,1]},aristocrat:{name:z("gov_trait_aristocrat"),effect(){return z("gov_trait_aristocrat_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[50,20,10]},gaslighter:{name:z("gov_trait_gaslighter"),effect(){return z("gov_trait_gaslighter_effect",[$(this)[0].vars()[0],_i(),$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[1,1,.5]},muckraker:{name:z("gov_trait_muckraker"),effect(){return z("gov_trait_muckraker_effect",[$(this)[0].vars()[1],$(this)[0].vars()[2]])},vars:()=>[8,12,3]},athleticism:{name:z("gov_trait_athleticism"),effect(){return z("gov_trait_athleticism_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1],$(this)[0].vars()[2],_i()])},vars:()=>[1.5,2,4]},nopain:{name:z("gov_trait_nopain"),effect(){return z("gov_trait_nopain_effect",[$(this)[0].vars()[0],$(this)[0].vars()[1]])},vars:()=>[50,10]},organizer:{name:z("gov_trait_organizer"),effect(){return z("gov_trait_organizer_effect",[$(this)[0].vars()[0]])},vars:()=>[t.genes.governor&&t.genes.governor>=2?2:1]}},I={humanoid:["Sanders","Smith","Geddon","Burgundy","Cristo","Crunch","Berg","Morros","Bower","Maximus"],carnivore:["Instinct","Prowl","Paws","Fluffy","Snarl","Claws","Fang","Stalker","Pounce","Sniff"],herbivore:["Sense","Grazer","Paws","Fluffy","Fern","Claws","Fang","Grass","Stampy","Sniff"],omnivore:["Pelt","Munchy","Paws","Fluffy","Snarl","Claws","Fang","Skavers","Pounce","Sniff"],small:["Bahgins","Banks","Shorty","Parte","Underfoot","Shrimp","Finkle","Littlefoot","Cub","Runt"],giant:["Slender","Titan","Colossus","Bean","Tower","Cloud","Bigfoot","Mountain","Crusher","Megaton"],reptilian:["Scale","Chimera","Ecto","Bask","Forks","Croc","Slither","Sunny","Coldfoot","Webtoe"],avian:["Sparrow","Soar","Shiney","Raven","Squaks","Eddy","Breeze","Flap","Kettle","Flock"],insectoid:["Compound","Centi","Hiver","Buzz","Carpace","Swarm","Devour","Carpi","Chitter","Burrow"],plant:["Grover","Blossom","Leaf","Sapper","Stem","Seed","Sprout","Greensly","Root","Fruit"],fungi:["Detritus","Psychedelic","Cap","Rotface","Patch","Spore","Infecto","Filament","Symbiote","Shade"],aquatic:["Seawolf","Finsley","Inko","Sucker","McBoatFace","Wave","Riptide","Shell","Coral","Pearl"],fey:["Whisper","Prank","Mischief","Flutter","Nature","Dirt","Story","Booker","Tales","Spirit"],heat:["Ash","Magnus","Pumice","Vulcano","Sweat","Flame","Lava","Ember","Smoke","Tinder","Spark"],polar:["Frosty","Snowball","Flake","Chiller","Frost","Cooler","Icecube","Arctic","Tundra","Avalanche"],sand:["Dune","Oasis","Sarlac","Spice","Quick","Grain","Spike","Storm","Glass","Castle"],demonic:["Yekun","Kesabel","Gadreel","Penemue","Abaddon","Azazyel","Leviathan","Samyaza","Kasyade","Typhon"],angelic:["Lightbringer","Illuminous","Sparks","Chrub","Halo","Star","Pompous","Radiant","Fluffy","Fabio"],synthetic:["HK47","D2R2","Bishop","Wally","Number5","Sunny","Data","Beta","Dot","Motoko"],eldritch:["Tentacle","Faceless","Horror","Darkness","Void","Dreamer","Mindflayer","Whisper","Paranoia","Empty"]};function T(e){let a=[],r=Ki[t.race.species].type,i=Object.keys(F),s=JSON.parse(JSON.stringify(I[r]));e=e||i.length;for(let t=0;t');$("#r_govern1").append(e);let a=$('
                          ');e.append(a);let r=$("
                          ");r.append($(`
                          ${z("governor_office",[t.race.governor.g.n])}
                          `)),r.append($(`
                          ${z("governor_background")}: ${F[t.race.governor.g.bg].name}
                          `)),a.append(r),a.append($(`
                          ${z("governor_fire")}
                          `));let i=[0,1,2];t.genes.governor&&t.genes.governor>=2&&(i.push(i.length),K("organizer",0)&&i.push(i.length)),K("organizer",0)&&i.push(i.length),i.forEach((function(t){let a=`{{ 'none' | label }}`;Object.keys(B).forEach((function(e){B[e].req()&&(a+=`{{ '${e}' | label }}`)})),e.append(`
                          ${z("gov_task",[t+1])}\n \n ${a}\n
                          `)})),t.race.governor.hasOwnProperty("config")||(t.race.governor.config={});let s=$('
                          ');e.append(s);{t.race.governor.config.hasOwnProperty("storage")||(t.race.governor.config.storage={crt:1e3,cnt:1e3});let e=$(`
                          ${z("gov_task_storage")}
                          `);s.append(e);let a=$('
                          ');e.append(a);let r=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood",i="Steel";a.append($(`${z("gov_task_storage_reserve",[t.resource[r].name])}`)),a.append($(`${z("gov_task_storage_reserve",[t.resource[i].name])}`))}{t.race.governor.config.hasOwnProperty("bal_storage")||(t.race.governor.config.bal_storage={}),t.race.governor.config.bal_storage.hasOwnProperty("adv")||(t.race.governor.config.bal_storage.adv=!1);let e=$(`
                          ${z("gov_task_bal_storage")}
                          ${z("advanced")}
                          `);s.append(e);let a=$('
                          ');e.append(a),Object.keys(t.resource).forEach((function(e){t.resource[e].stackable?(t.race.governor.config.bal_storage.hasOwnProperty(e)||(t.race.governor.config.bal_storage[e]="2"),a.append($(`
                          ${t.resource[e].name}\n \n 0x\n 1/2\n 1x\n 2x\n 3x\n 4x\n \n
                          `))):t.race.governor.config.bal_storage.hasOwnProperty(e)&&delete t.race.governor.config.bal_storage[e]}))}{t.race.governor.config.hasOwnProperty("merc")||(t.race.governor.config.merc={buffer:1,reserve:100});let e=$(`
                          ${z("gov_task_merc")}
                          `);s.append(e);let a=$('
                          ');e.append(a),a.append($(`${z("gov_task_merc_buffer")}`)),a.append($(`${z("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("spy")||(t.race.governor.config.spy={reserve:100});let e=$(`
                          ${z("gov_task_spy")}
                          `);s.append(e);let a=$('
                          ');e.append(a),a.append($(`${z("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("spyop")||(t.race.governor.config.spyop={},Object.keys(t.civic.foreign).forEach((function(e){t.race.governor.config.spyop[e]="gov3"===e?["influence","sabotage"]:["sabotage","incite","influence"]})));let e=$(`
                          ${z("gov_task_spyop")}
                          `);s.append(e),Object.keys(t.civic.foreign).forEach((function(a){if(a.substr(3,1)<3&&!t.tech.world_control||"gov3"===a&&t.tech.rival){let r=$("
                          ");e.append(r),r.append(`\n

                          ${z("gov_task_spyop_priority",[Z(a.substring(3))])}

                          \n
                            \n `);let i=$(`#spyopConfig${a}`);t.race.governor.config.spyop[a].forEach((function(e){i.append(`\n
                          • ${z("civics_spy_"+e)}
                          • \n `)}))}}))}{t.race.governor.config.hasOwnProperty("tax")||(t.race.governor.config.tax={min:20});let e=$(`
                            ${z("gov_task_tax")}
                            `);s.append(e);let a=$('
                            ');e.append(a),a.append($(`${z("gov_task_tax_min")}`))}{t.race.governor.config.hasOwnProperty("slave")||(t.race.governor.config.slave={reserve:100});let e=$(`
                            ${z("gov_task_slave")}
                            `);s.append(e);let a=$('
                            ');e.append(a),a.append($(`${z("gov_task_merc_reserve")}`))}{t.race.governor.config.hasOwnProperty("trash")||(t.race.governor.config.trash={}),["Infernite","Elerium","Copper","Iron"].forEach((function(e){t.race.governor.config.trash.hasOwnProperty(e)&&"object"==typeof t.race.governor.config.trash[e]&&null!==t.race.governor.config.trash[e]||(t.race.governor.config.trash[e]={v:0,s:!0})}));let e=$(`
                            ${z("gov_task_trash")}
                            `);s.append(e);let a=$('
                            ');e.append(a),Object.keys(t.race.governor.config.trash).forEach((function(e){a.append($(`
                            `))}))}{t.race.governor.config.hasOwnProperty("replicate")||(t.race.governor.config.replicate={}),t.race.governor.config.replicate.hasOwnProperty("pow")||(t.race.governor.config.replicate.pow={on:!1,cap:1e4,buffer:0}),t.race.governor.config.replicate.hasOwnProperty("res")||(t.race.governor.config.replicate.res={que:!0,neg:!0,cap:!0});let e=$(`
                            ${z("gov_task_replicate")}
                            `);s.append(e);let a=$('
                            ');e.append(a),a.append($(`
                            ${z("gov_task_replicate_auto")}
                            `)),a.append($(`${z("gov_task_replicate_pmax")}`)),a.append($(`${z("gov_task_replicate_buff")}`));let r=$('
                            ');e.append(r),r.append($(`
                            ${z("gov_task_replicate_que")}
                            `)),r.append($(`
                            ${z("gov_task_replicate_neg")}
                            `)),r.append($(`
                            ${z("gov_task_replicate_cap")}
                            `))}Cs({el:"#govOffice",data:{t:t.race.governor.tasks,c:t.race.governor.config,r:t.resource},methods:{setTask(e,a){t.race.governor.tasks[`t${a}`]=e,ks("govtask",{task:e}),Cs({el:"#race"},"update")},showTask:e=>Object.values(t.race.governor.tasks).includes(e),activeTask(e){let a=[];return t.race.hasOwnProperty("governor")&&Object.keys(t.race.governor.tasks).forEach((function(e){"none"!==t.race.governor.tasks[e]&&a.push(t.race.governor.tasks[e])})),!a.includes(e)},showStrRes:e=>t.resource[e].display,bStrEx:()=>t.race.governor.config.bal_storage.adv?"m":"",fire(){let e=(10+(t.race.governor.hasOwnProperty("f")?t.race.governor.f:0))**2-50,a="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";t.prestige[a].count>=e&&(t.prestige[a].count-=e,t.race.governor.candidates=T(10),t.race.governor.hasOwnProperty("f")?t.race.governor.f++:t.race.governor.f=1,delete t.race.governor.g,delete t.race.governor.tasks,ui(!1,["city-amphitheatre","city-apartment"]),vs(),fs(),L())},fireText(){let e=(10+(t.race.governor.hasOwnProperty("f")?t.race.governor.f:0))**2-50;return`
                            ${z("governor_fire")}
                            ${e} ${z("antimatter"===t.race.universe?"resource_AntiPlasmid_plural_name":"resource_Plasmid_plural_name")}
                            `},trashStrat(e){t.race.governor.config.trash[e].s=!t.race.governor.config.trash[e].s},trashLabel:e=>z(t.race.governor.config.trash[e].s?"gov_task_trash_max":"gov_task_trash_min",[t.resource[e].name])},filters:{label:e=>B[e]?"string"==typeof B[e].name?B[e].name:B[e].name():z(`gov_task_${e}`)}}),ls("govOffice",(function(){let e="";return Object.keys(F[t.race.governor.g.bg].traits).forEach((function(t){e+=(A[t].hasOwnProperty("effect")?A[t].effect():"")+" "})),e}),{elm:"#govOffice .bg"}),Object.keys(t.civic.foreign).forEach((function(e){!function(e){let a=$(`#spyopConfig${e}`)[0];a&&Sortable.create(a,{onEnd(a){let r=t.race.governor.config.spyop[e];r.splice(a.newDraggableIndex,0,r.splice(a.oldDraggableIndex,1)[0]),t.race.governor.config.spyop[e]=r,L()}})}(e)}))}():function(){let e=$('
                            ');$("#r_govern1").append(e),t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("candidates")||(t.race.governor={candidates:T(10)}),e.append($(`
                            ${z("governor_candidate")}${z("governor_background")}
                            `));for(let a=0;a${r.t} ${r.n}${F[r.bg].name}
                            `))}Cs({el:"#candidates",data:t.race.governor,methods:{appoint(e){if(t.genes.governor&&t.tech.governor){let a=t.race.governor.candidates[e];t.race.governor.g=a,delete t.race.governor.candidates,t.race.governor.tasks={t0:"none",t1:"none",t2:"none",t3:"none",t4:"none",t5:"none"},ui(!1,["city-amphitheatre","city-apartment"]),vs(),fs(),L(),ks("governor",{appoint:t.race.governor.g.bg})}}}}),t.race.governor.candidates.forEach((function(e){ls(`candidates-${e.bg}`,(function(){let t="";return Object.keys(F[e.bg].traits).forEach((function(e){t+=(A[e].hasOwnProperty("effect")?A[e].effect():"")+" "})),t}),{elm:`#candidates .${e.bg} .bg`})}))}())}function E(){Object.keys(t.civic.foreign).forEach((function(e){let t=$(`#spyopConfig${e}`)[0];if(t){let e=Sortable.get(t);e&&e.destroy()}}))}function K(e,a){return!(!t.race.hasOwnProperty("governor")||!t.race.governor.hasOwnProperty("g"))&&!!F[t.race.governor.g.bg].traits[e]&&A[e].vars()[a]}function D(e){if(t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks)for(let a=0;at.civic.taxes.display,task(){if($(this)[0].req()){let e=1;t.civic.taxes.tax_rate>=40&&(e+=.5),"oligarchy"===t.civic.govern.type&&t.civic.taxes.tax_rate>=20&&(e-=.5);let a=de("tax_cap",!1);if(t.city.morale.current<100&&t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?45:25))for(;t.city.morale.current<100&&t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?45:25);)de("adj_tax","sub");else t.city.morale.potential>=t.city.morale.cap+e&&t.civic.taxes.tax_ratet.race.governor.config.tax.min&&de("adj_tax","sub")}}},storage:{name:z("gov_task_storage"),req:()=>!!(Nr("storage_yard")&&t.tech.container&&t.resource.Crates.display),task(){if($(this)[0].req()){if(t.resource.Crates.amountr&&nr("crate",Math.floor((t.resource[e].amount-r)/a))}if(Nr("warehouse")&&t.resource.Containers.display&&t.resource.Containers.amounta&&nr("container",Math.floor((t.resource.Steel.amount-a)/e))}}}},bal_storage:{name:z("gov_task_bal_storage"),req:()=>!!(Nr("storage_yard")&&t.tech.container&&t.resource.Crates.display),task(){if($(this)[0].req()){let e=t.resource.Crates.amount,a=e,r=t.resource.Containers.amount,i=r,s=0,n=Object.keys(t.resource).slice().reverse();n.forEach((function(a){t.resource[a].display&&t.resource[a].stackable?(e+=t.resource[a].crates,r+=t.resource[a].containers,s++):(t.resource[a].crates=0,t.resource[a].containers=0)}));let c=Math.floor(e/s),o=Math.floor(r/s),l={Food:{m:.1,cap:100},Coal:{m:.25}};t.race.artifical&&delete l.Food,Object.keys(t.race.governor.config.bal_storage).forEach((function(e){let a=Number(t.race.governor.config.bal_storage[e]);"Coal"===e?l[e]={m:.125*a}:"Food"===e?l[e]={m:.05*a,cap:50*a}:t.resource[e]&&(l[e]={m:a})})),Object.keys(l).forEach((function(a){if(t.resource[a].display)if(l[a].hasOwnProperty("cap")){s--;{let r=Math.floor(c*l[a].m);l[a].hasOwnProperty("cap")&&r>l[a].cap&&(r=l[a].cap),t.resource[a].crates=r,e-=r}if(t.resource.Containers.display){let e=Math.floor(o*l[a].m);l[a].hasOwnProperty("cap")&&e>l[a].cap&&(e=l[a].cap),t.resource[a].containers=e,r-=e}}else s+=l[a].m-1})),c=0!==s?Math.floor(e/s):0,o=0!==s?Math.floor(r/s):0,e-=Math.floor(c*s),r-=Math.floor(o*s),n.forEach((function(a){if((!l[a]||!l[a].hasOwnProperty("cap"))&&(!t.race.artifical||"Food"!==a)&&t.resource[a].display&&t.resource[a].stackable){let i=l[a]?l[a].m:1,s=Math.floor(c>0?c*i:0);if(t.resource[a].crates=s,t.resource.Containers.display){let e=Math.floor(o>0?o*i:0);t.resource[a].containers=e}if(e>0&&i>=1){let r=Math.ceil(i/2);e0&&i>=1){let e=Math.ceil(i/2);r0&&(e>0||r>0);)_--,n.forEach((function(a){l[a]&&l[a].hasOwnProperty("cap")||t.race.artifical&&"Food"===a||t.resource[a].display&&t.resource[a].stackable&&(e>0&&(t.resource[a].crates++,e--),r>0&&(t.resource[a].containers++,r--))}));t.resource.Crates.amount=e,t.resource.Containers.amount=r,s&&(t.resource.Crates.max-=a,t.resource.Containers.max-=i)}}},assemble:{name:z("gov_task_assemble"),req:()=>!(!t.race.artifical||t.tech.focus_cure&&!(t.tech.focus_cure<7)),task(){$(this)[0].req()&&t.resource[t.race.species].max>t.resource[t.race.species].amount&&Mr.city.assembly.action()}},clone:{name:z("gov_task_clone"),req:()=>!!t.tech.cloning,task(){$(this)[0].req()&&t.resource[t.race.species].max>t.resource[t.race.species].amount&&Mr.tauceti.tau_home.cloning_facility.action()}},merc:{name:z("gov_task_merc"),req:()=>!(!Nr("garrison")||!t.tech.mercs),task(){if($(this)[0].req()){let e=t.resource.Money.max*(t.race.governor.config.merc.reserve/100);for(;t.civic.garrison.max>t.civic.garrison.workers+t.race.governor.config.merc.buffer&&t.resource.Money.amount>=de("m_cost")&&(t.resource.Money.amount+t.resource.Money.diff>=e||t.resource.Money.diff>=de("m_cost"));)de("m_buy")}}},spy:{name:z("gov_task_spy"),req:()=>!(t.tech.isolation||(!t.race.truepath||!t.tech.spy)&&(!t.tech.spy||t.tech.world_control||t.race.cataclysm)),task(){if($(this)[0].req()){let e=t.resource.Money.max*(t.race.governor.config.spy.reserve/100),a=t.race.truepath&&t.tech.rival?4:3;for(let r=t.tech.world_control?3:0;r=a&&(t.resource.Money.diff>=a||t.resource.Money.amount+t.resource.Money.diff>=e)&&de("t_spy",r)}}}},spyop:{name:z("gov_task_spyop"),req:()=>!(t.tech.isolation||!(t.race.truepath&&t.tech.spy&&t.tech.spy>=2)&&(!(t.tech.spy&&t.tech.spy>=2)||t.tech.world_control||t.race.cataclysm)),task(){if($(this)[0].req()){let e=t.race.truepath&&t.tech.rival?[0,1,2,3]:[0,1,2];t.tech.world_control&&(e=[3]),e.forEach((function(e){t.civic.foreign[`gov${e}`].sab<=0&&t.civic.foreign[`gov${e}`].spy>0&&!t.civic.foreign[`gov${e}`].anx&&!t.civic.foreign[`gov${e}`].buy&&!t.civic.foreign[`gov${e}`].occ&&t.race.governor.config.spyop[`gov${e}`].every((function(a){switch(a){case"influence":if(t.civic.foreign[`gov${e}`].hstl>0&&t.civic.foreign[`gov${e}`].spy>1)return de("s_influence",e),!1;break;case"sabotage":if(t.civic.foreign[`gov${e}`].mil>50)return de("s_sabotage",e),!1;break;case"incite":if(t.civic.foreign[`gov${e}`].unrest<100&&t.civic.foreign[`gov${e}`].spy>2&&e<3)return de("s_incite",e),!1}return!0}))}))}}},slave:{name:z("gov_task_slave"),req:()=>!(t.race.orbit_decayed||!Nr("slave_market")||!t.race.slaver||!t.city.slave_pen),task(){let e=t.resource.Money.max*(t.race.governor.config.slave.reserve/100),a=25e3;t.race.inflation&&(a*=1+t.race.inflation/100);let r=K("extravagant",0);r&&(a*=1+r/100),$(this)[0].req()&&t.resource.Money.amount>=a&&(t.resource.Money.diff>=a||t.resource.Money.amount+t.resource.Money.diff>=e)&&4*t.city.slave_pen.count>t.city.slave_pen.slaves&&Mr.city.slave_market.action()}},sacrifice:{name:z("gov_task_sacrifice"),req:()=>!!(Nr("s_alter")&&t.city.hasOwnProperty("s_alter")&&t.city.s_alter.count>=1),task(){$(this)[0].req()&&t.resource[t.race.species].amount===t.resource[t.race.species].max&&(!t.race.kindling_kindred&&!t.race.smoldering&&t.city.s_alter.harvest<=1e4||t.city.s_alter.mind<=1e4||t.city.s_alter.mine<=1e4||t.city.s_alter.rage<=1e4||t.city.s_alter.regen<=1e4)&&Mr.city.s_alter.action()}},horseshoe:{name:()=>z(`city_${hn(!0)}`,[hn(!1)]),req:()=>!!t.race.hooved,task(){let e=Mr.city.horseshoe.cost;if($(this)[0].req()&&ii(e)){e=Ns(Mr.city.horseshoe);let a="Copper",r=10;Object.keys(e).forEach((function(t){e[t]()>0&&(a=t,r=e[t]())})),t.resource[a].amount>r&&(t.resource[a].diff>=r||t.resource[a].amount+t.resource[a].diff>=t.resource[a].max)&&Mr.city.horseshoe.action()}}},trash:{name:z("gov_task_trash"),req:()=>!!(t.interstellar.mass_ejector&&t.interstellar.mass_ejector.count>=1),task(){let e=function(e){return"magic"===t.race.universe?Fa[e]:["Elerium","Infernite"].includes(e)?10*Fa[e]:Fa[e]},a=1e3*s.mass_ejector;Object.keys(Fa).sort(((t,a)=>e(t)0&&(s=0),t.race.governor.config.trash[e]||t.interstellar.mass_ejector.hasOwnProperty(e)&&t.resource[e].display&&t.resource[e].max>0&&t.interstellar.mass_ejector[e]+t.resource[e].diff>0&&t.resource[e].amount+i-s>=.999*t.resource[e].max-1){let r=0;if(t.resource[e].amount+i-s>=.999*t.resource[e].max-1||t.race.governor.config.trash[e]&&!t.race.governor.config.trash[e].s){const a=Math.floor(t.resource[e].diff/t.settings.gameSpeed);r=t.interstellar.mass_ejector[e]+a}t.race.governor.config.trash[e]&&r=.999*t.resource[e].max-1?r:r-Math.abs(t.race.governor.config.trash[e].v)),r>a&&(r=a),r<0&&(r=0),t.race.artifical&&"Food"===e&&(r=0),t.interstellar.mass_ejector[e]=r,a-=r}else t.interstellar.mass_ejector[e]=0})),t.interstellar.mass_ejector.total=1e3*s.mass_ejector-a}},mech:{name:z("gov_task_mech"),req:()=>!!(t.stats.achieve.hasOwnProperty("corrupted")&&t.stats.achieve.corrupted.l>0&&("prtl_spire","mechbay",Tt(na,"prtl_spire","mechbay"))&&t.portal.hasOwnProperty("mechbay")),task(){if($(this)[0].req()){let e="large",a=fa(e,!1),r=a.c,i=a.s,s=ba(e),n={type:{}};["small","medium","large","titan","collector"].forEach((function(e){n.type[e]=0,n[e]={chassis:{},weapon:{},equip:{}},["hover","spider","wheel","tread","biped","quad"].forEach((function(t){n[e].chassis[t]=0})),["plasma","laser","kinetic","shotgun","missile","flame","sonic","tesla"].map((e=>({sort:Math.random(),value:e}))).sort(((e,t)=>e.sort-t.sort)).map((e=>e.value)).forEach((function(t){n[e].weapon[t]=0})),["shields","flare","seals","grapple","sonar","ablative","radiator","infrared","coolant","stabilizer"].forEach((function(t){n[e].equip[t]=0}))})),t.portal.mechbay.mechs.forEach((function(e){n.type[e.size]++,n[e.size].chassis[e.chassis]++,e.hardpoint.forEach((function(t){n[e.size].weapon[t]++})),e.equip.forEach((function(t){n[e.size].equip[t]++}))})),n.type.large>=6&&n.type.small<12||n.type.large>=12&&n.type.titan>=2&&n.type.small<24?(e="small",a=fa(e,!1),r=a.c,i=a.s,s=ba(e)):n.type.large>=6&&n.type.medium<12?(e="medium",a=fa(e,!1),r=a.c,i=a.s,s=ba(e)):n.type.large>=12&&n.type.titan<2&&(a=fa("titan",!1),a.c<=t.portal.purifier.sup_max&&(e="titan",r=a.c,i=a.s,s=ba(e)));let c=t.portal.mechbay.max-t.portal.mechbay.bay;if(c=3){if(t.queue.queue.some((e=>["portal-purifier","portal-port","portal-base_camp","portal-mechbay","portal-waygate"].includes(e.id))))return;for(let s=0;st.portal.purifier.sup_max&&(l=t.portal.purifier.sup_max),l>=r&&t.resource.Soul_Gem.amount+o>=i){if(t.resource.Soul_Gem.amount+=o,t.resource.Soul_Gem.amount-=i,t.portal.purifier.supply=l,t.portal.purifier.supply-=r,t.portal.mechbay.mechs[s].infernal=!0,"small"===c.size&&0===c.equip.length)t.portal.mechbay.mechs[s].equip.push("special");else if("medium"===c.size&&1===c.equip.length||"large"===c.size&&2===c.equip.length||"titan"===c.size&&c.equip.length<5){let a="???";Object.keys(n[e].equip).forEach((function(t){("???"===a||n[e].equip[t]=r&&c>=s&&t.resource.Soul_Gem.amount>=i){let a=99,c="hover";Object.keys(n[e].chassis).forEach((function(t){n[e].chassis[t]!(!t.tech.replicator||!t.race.replicator),task(){if(t.race.governor.config.replicate.pow.on){let e=t.race.governor.config.replicate.pow.cap,a=t.race.governor.config.replicate.pow.buffer;if(t.city.power0){let e=t.city.power<0?Math.abs(t.city.power)+a:a-t.city.power;t.race.replicator.pow-=e,t.race.replicator.pow<0&&(t.race.replicator.pow=0)}else t.city.power>a&&t.race.replicator.powe&&(t.race.replicator.pow=e)):t.race.replicator.pow>e&&(t.race.replicator.pow=e);t.race.replicator.pow=Math.floor(t.race.replicator.pow)}let e=!1;for(let a=0;t.race.governor.config.replicate.res.que&&at.resource[e].display)),t.race.governor.config.replicate.res.neg&&t.resource[a[0]].diff<0&&(t.resource[a[0]].amount<=.95*t.resource[a[0]].max||-1===t.resource[a[0]].max))t.race.replicator.res=a[0];else if(-1!==t.resource[t.race.replicator.res].max&&t.race.governor.config.replicate.res.cap&&t.resource[t.race.replicator.res].amount>=t.resource[t.race.replicator.res].max){let r=a.filter((e=>t.resource[e].max>0));for(let a=0;a-1===t.resource[e].max));e.length>0&&(t.race.replicator.res=e[0])}}}}}};function G(e){switch(e){case"aries":case"capricorn":return[10];case"taurus":return[2];case"gemini":case"aquarius":return[20];case"cancer":case"sagittarius":return[5];case"leo":return[4];case"virgo":return[15];case"libra":return[25];case"scorpio":return[12,1];case"pisces":return[49,25]}}function N(){const e=new Date;return 0===e.getMonth()&&e.getDate()>=20||1===e.getMonth()&&e.getDate()<=18?"aquarius":1===e.getMonth()&&e.getDate()>=19||2===e.getMonth()&&e.getDate()<=20?"pisces":2===e.getMonth()&&e.getDate()>=21||3===e.getMonth()&&e.getDate()<=19?"aries":3===e.getMonth()&&e.getDate()>=20||4===e.getMonth()&&e.getDate()<=20?"taurus":4===e.getMonth()&&e.getDate()>=21||5===e.getMonth()&&e.getDate()<=21?"gemini":5===e.getMonth()&&e.getDate()>=22||6===e.getMonth()&&e.getDate()<=22?"cancer":6===e.getMonth()&&e.getDate()>=23||7===e.getMonth()&&e.getDate()<=22?"leo":7===e.getMonth()&&e.getDate()>=23||8===e.getMonth()&&e.getDate()<=22?"virgo":8===e.getMonth()&&e.getDate()>=23||9===e.getMonth()&&e.getDate()<=22?"libra":9===e.getMonth()&&e.getDate()>=23||10===e.getMonth()&&e.getDate()<=22?"scorpio":10===e.getMonth()&&e.getDate()>=23||11===e.getMonth()&&e.getDate()<=21?"sagittarius":11===e.getMonth()&&e.getDate()>=22||0===e.getMonth()&&e.getDate()<=19?"capricorn":"time itself is broken"}function R(){P.w&&P.w.terminate(),O(),ks("reset",{end:"descension"}),qn("squished",!0),qn(`extinct_${t.race.species}`),t.race.witch_hunter&&"magic"===t.race.universe?qn("nightmare"):qn("corrupted"),"angelic"===Ki[t.race.species].type&&Pn("twisted"),t.race.junker&&"junker"===t.race.species&&Pn("the_misery"),!t.race.modified&&t.race.junker&&"junker"===t.race.species&&Pn("garbage_pie"),t.race.cataclysm&&Pn("finish_line"),t.race.ooze&&"sludge"===t.race.species&&Pn("slime_lord");let a=Gs("descend");t.prestige.Artifact.count+=a.artifact,t.stats.artifact+=a.artifact;let r=xn();t.stats.spire.hasOwnProperty(r)&&(t.stats.spire[r].hasOwnProperty("lord")?t.stats.spire[r].lord++:t.stats.spire[r].lord=1,t.tech.dl_reset?t.stats.spire[r].dlstr=0:t.stats.spire[r].hasOwnProperty("dlstr")?t.stats.spire[r].dlstr++:t.stats.spire[r].dlstr=1);let i=t.race.species,s=t.race.gods,n=t.city.calendar.orbit,c=t.city.biome,o=t.city.ptrait,l=t.city.geology;t.stats.descend++,rn(),Sn();let _=!!t.race.hasOwnProperty("srace")&&t.race.srace;t.race={species:"protoplasm",gods:i,old_gods:s,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),corruption:5,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},_&&(t.race.srace=_),H({orbit:n,biome:c,ptrait:o,geology:l}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}function H(e){t.city={calendar:{day:0,year:0,weather:2,temp:1,moon:0,wind:0,orbit:e.orbit},biome:e.biome,ptrait:e.ptrait},e.geology&&(t.city.geology=e.geology),t.tech={theology:1},S(),t.new=!0,t.seed=Math.rand(0,1e4)}function U(){let e=xn();t.race.womling_friend?("m"!==e&&t.stats.womling.friend.l++,"l"!==e&&(t.stats.womling.friend.hasOwnProperty(e)||(t.stats.womling.friend[e]=0),t.stats.womling.friend[e]++)):t.race.womling_lord?("m"!==e&&t.stats.womling.lord.l++,"l"!==e&&(t.stats.womling.lord.hasOwnProperty(e)||(t.stats.womling.lord[e]=0),t.stats.womling.lord[e]++)):t.race.womling_god&&("m"!==e&&t.stats.womling.god.l++,"l"!==e&&(t.stats.womling.god.hasOwnProperty(e)||(t.stats.womling.god[e]=0),t.stats.womling.god[e]++)),t.stats.womling.friend.l>0&&t.stats.womling.lord.l>0&&t.stats.womling.god.l>0&&qn("overlord","m"===e,Mn(),"l"),t.stats.womling.friend[e]>0&&t.stats.womling.lord[e]>0&&t.stats.womling.god[e]>0&&qn("overlord","m"===e,Mn(),e)}function V(e){if(t.civic.taxes||(t.civic.taxes={tax_rate:20,display:!1}),!e&&(t.settings.tabLoad||2===t.settings.civTabs&&0===t.settings.govTabs)){var a=$('
                            '),r=$(`\n \n \n \n \n \n \n `);a.append(r),$("#r_civics").append(a),Cs({el:"#government .govTabs2",data:{t:t.civic.taxes,s:t.settings},methods:{vis:()=>!!t.tech.govern}}),function(e){var a=$('
                            ');e.append(a);var r=$(`
                            ${z("civics_government_type")} {{ type | govern }}
                            `);a.append(r);var i=$("
                            ");a.append(i);var s=$('');i.append(s);var n={template:''};Cs({el:"#govType",data:t.civic.govern,filters:{govern:e=>z(`govern_${e}`),set:e=>z("anarchy"===e?"civics_set_gov":"civics_revolution")},methods:{trigModal(){this.$buefy.modal.open({parent:this,component:n});var e=setInterval((function(){$("#modalBox").length>0&&(clearInterval(e),function(){$("#modalBox").append($(`

                            ${z("civics_government_type")}

                            `));let e=Qs(6,10);e.length>0&&$("#modalBoxTitle").append(e);let a=Js(6,14,!1);a.length>0&&$("#modalBoxTitle").append(a);var r=$('
                            ');$("#modalBox").append(r),t.tech.govern&&("autocracy"!==t.civic.govern.type&&r.append($(``)),"democracy"!==t.civic.govern.type&&r.append($(``)),"oligarchy"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_theo&&"theocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.govern>=2&&"republic"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_soc&&"socialist"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_corp&&"corpocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.govern>=3&&"technocracy"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_fed&&"federation"!==t.civic.govern.type&&r.append($(``)),t.tech.gov_mage&&"magocracy"!==t.civic.govern.type&&r.append($(``))),Cs({el:"#govModal",data:t.civic.govern,methods:{setGov(e){if(0===t.civic.govern.rev){let a=t.genes.governor&&"anarchy"===t.civic.govern.type;t.civic.govern.type=e;let r=1e3;t.tech.high_tech&&(r+=250,t.tech.high_tech>=3&&(r+=250),t.tech.high_tech>=6&&(r+=250)),t.tech.space_explore&&t.tech.space_explore>=3&&(r+=250),t.race.unorganized&&(r=Math.round(r*(1+Ei.unorganized.vars()[0]/100))),t.stats.achieve.anarchist&&(r=Math.round(r*(1-t.stats.achieve.anarchist.l/10))),t.race.lawless&&(r=Math.round(r/(100-Ei.lawless.vars()[0])));let i=ts("tuskin");i>0&&(r=Math.round(r/(100-Ei.lawless.vars(1)[0]*i)));let s=K("aristocrat",0);s&&(r=Math.round(r*(1-s/100))),t.civic.govern.rev=r+t.civic.govern.fr,a&&Qr(),Cs({el:"#govModal"},"destroy"),$(".modal-background").click(),_s()}}}}),ls("GovPop",(function(e){let a=$(e.this).data("gov"),r=t.tech.unify&&t.tech.unify>=2&&"federation"===a?"federation_alt":a;return"theocracy"===r&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display&&(r="theocracy_alt"),$(`
                            ${ee(a)}
                            ${X()[r]}
                            `)}),{elm:"#govModal button",self:!0,classes:"has-background-light has-text-dark"})}())}),50)},startrev(){t.civic.govern.fr=t.civic.govern.rev,t.civic.govern.rev=0},force:()=>t.civic.govern.rev>0?z("civics_force_rev_desc"):z("civics_force_rev_desc2"),vis:()=>!!t.tech.govern}}),ls("govLabel",(function(){let e=t.tech.unify&&t.tech.unify>=2&&"federation"===t.civic.govern.type?"federation_alt":t.civic.govern.type;return"theocracy"===e&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display&&(e="theocracy_alt"),$(`
                            ${ee(t.civic.govern.type)}
                            ${X()[e]}
                            `)})),ls("govTypeChange",(function(){return t.civic.govern.rev>0?z("civics_change_desc",[t.civic.govern.rev]):z("civics_change_desc2")}),{elm:"#govType .change"})}($("#r_govern0")),function(e){var a=$('
                            ');e.append(a);var r=$(`

                            ${z("civics_tax_rates")}

                            `);a.append(r);var i=$(''),s=$('«'),n=$('»');a.append(s),a.append(i),a.append(n),Cs({el:"#tax_rates",data:t.civic.taxes,filters:{tax_level(e){let a=Qs(11,14),r=Js(2,14,!1);return a.length>0&&(0===e&&!t.race.noble||10===e&&t.race.noble)?a:13===e&&r.length>0?r:`${e}%`}},methods:{add(){_e("add")},sub(){_e("sub")}}}),ls("taxRateLabel",(function(){return z("civics_tax_rates_desc")}),{classes:"has-background-light has-text-dark"})}($("#r_govern0"));var i=$('
                            ');$("#r_govern0").append(i),L()}}function W(){if(Q(),t.settings.tabLoad||2===t.settings.civTabs&&3===t.settings.govTabs){var a=$('
                            ');$("#military").append(a),$("#military").append($('
                            ')),he(a,!0),function(){if(t.race.sludge)return!1;if(0===$("#mad").length){let i="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");var a=$('
                            ');$("#military").append(a);var r=$('
                            ');a.append(r),r.append($(`
                            ${z("civics_mad_reset_desc",[i])}
                            `));let s=!(!t.race.hrt||!["wolven","vulpine"].includes(t.race.hrt));r.append($(`
                            `)),r.append($(`
                            `)),t.civic.mad.armed||($("#mad").addClass("armed"),$("#mad .arm").html(z(s?"civics_mad_disarm_grenades":"civics_mad_disarm_missiles"))),Cs({el:"#mad",data:t.civic.mad,methods:{launch(){if(!t.civic.mad.armed&&!t.race.cataclysm){$("body").addClass("nuke");let a=$('
                            ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),500),setTimeout((function(){a.addClass("b")}),600),setTimeout((function(){!function(){if(!t.civic.mad.armed&&!t.race.cataclysm){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"mad"});let a=t.race.species,r=t.race.gods,i=t.city.calendar.orbit,s=t.city.biome,n=t.city.ptrait,c=t.city.geology,o=Gs("mad");t.stats.mad++,rn(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),qn("apocalypse"),qn("squished",!0),qn(`extinct_${a}`),"anarchy"===t.civic.govern.type&&qn("anarchist"),"hellscape"===t.city.biome&&"demonic"!==Ki[t.race.species].type&&Pn("take_no_advice"),t.race.truepath&&qn("ashanddust"),Sn();let l=!!t.race.hasOwnProperty("srace")&&t.race.srace,_=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,rapid_mutation:1,ancient_ruins:1,universe:t.race.universe,seeded:!1,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},_>0&&(t.race.corruption=_),l&&(t.race.srace=l),H({orbit:i,biome:s,ptrait:n,geology:c}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}}()}),4e3)}},arm(){t.civic.mad.armed?($("#mad .arm").html(z(s?"civics_mad_disarm_grenades":"civics_mad_disarm_missiles")),t.civic.mad.armed=!1,$("#mad").addClass("armed")):($("#mad .arm").html(z(s?"civics_mad_arm_grenades":"civics_mad_arm_missiles")),t.civic.mad.armed=!0,$("#mad").removeClass("armed"))}}}),["mdarm","mdlaunch"].forEach((function(e){ls(`mad${e}`,(function(){return"{{ label() }}"}),{elm:`#mad .${e}`,in:function(a){Cs({el:`#${a.id} > span`,data:{test:"val"},methods:{label(){switch(e){case"mdarm":return t.tech.world_control&&!t.race.truepath?z("civics_mad_missiles_world_control_desc"):z(s?"civics_mad_missiles_desc_easter":"civics_mad_missiles_desc");case"mdlaunch":{let e=Gs("mad"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return z("civics_mad_missiles_warning",[e.plasmid,a])}}}}})},out:function(e){Cs({el:`#${e.id} > span`},"destroy")}})}))}}()}}function Q(){t.civic.garrison||(t.civic.garrison={display:!1,disabled:!1,rate:0,progress:0,tactic:0,workers:0,wounded:0,raid:0,max:0}),t.civic.garrison.mercs||(t.civic.garrison.mercs=!1),t.civic.garrison.fatigue||(t.civic.garrison.fatigue=0),t.civic.garrison.protest||(t.civic.garrison.protest=0),t.civic.garrison.m_use||(t.civic.garrison.m_use=0),t.civic.garrison.crew||(t.civic.garrison.crew=0),t.civic.mad||(t.civic.mad={display:!1,armed:!0})}function J(e){if(t.race.truepath){if(t.civic.foreign[`gov${e}`].hstl<10)return 1+(10-t.civic.foreign[`gov${e}`].hstl)/40;if(t.civic.foreign[`gov${e}`].hstl>60)return 1-(-60+t.civic.foreign[`gov${e}`].hstl)/160}return 1}function Z(e){if(void 0===t.civic.foreign[`gov${e}`].name){let a=xs();t.civic.foreign[`gov${e}`].name={s0:a.s0,s1:a.s1}}return z(`civics_gov${t.civic.foreign[`gov${e}`].name.s0}`,[t.civic.foreign[`gov${e}`].name.s1])}const X=function(){return{anarchy:z("govern_anarchy_effect"),autocracy:z("govern_autocracy_effect",Y.autocracy()),democracy:z("govern_democracy_effect",Y.democracy()),oligarchy:t.tech.high_tech&&t.tech.high_tech>=12?z("govern_oligarchy_effect_alt",[Y.oligarchy()[1]]):z("govern_oligarchy_effect",[Y.oligarchy()[0],Y.oligarchy()[1]]),theocracy:z("govern_theocracy_effect",Y.theocracy()),theocracy_alt:z("govern_theocracy_effect_alt",Y.theocracy()),republic:z("govern_republic_effect",Y.republic()),socialist:z("govern_socialist_effect",Y.socialist()),corpocracy:z("govern_corpocracy_effect",Y.corpocracy()),technocracy:t.tech.high_tech&&t.tech.high_tech>=16?z("govern_technocracy_effect_alt",[Y.technocracy()[0],Y.technocracy()[2]]):z("govern_technocracy_effect",Y.technocracy()),federation:z("govern_federation_effect",[Y.federation()[0],Y.federation()[1]]),federation_alt:z("govern_federation_effect_alt",[25,Y.federation()[2],Y.federation()[1]]),magocracy:z("govern_magocracy_effect",Y.magocracy())}},Y={autocracy:()=>[t.tech.high_tech&&t.tech.high_tech>=2?t.tech.high_tech>=12?10:18:25,K("organizer",0)?40:35],democracy:()=>[t.tech.high_tech&&t.tech.high_tech>=2?t.tech.high_tech>=12?30:25:20,K("organizer",0)?1:5],oligarchy:()=>[t.tech.high_tech&&t.tech.high_tech>=12?0:t.tech.high_tech&&t.tech.high_tech>=2?2:5,K("organizer",0)?25:20],theocracy:()=>[12,K("organizer",0)?10:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?25:40:50],republic:()=>[K("organizer",0)?30:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?40:30:20],socialist:()=>[t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?50:42:35,K("organizer",0)?12:10,10,K("organizer",0)?10:20],corpocracy:()=>[K("organizer",0)?220:200,K("organizer",0)?175:150,K("organizer",0)?110:100,t.tech.high_tech&&t.tech.high_tech>=12?5:10,t.tech.high_tech&&t.tech.high_tech>=16?40:30],technocracy:()=>[8,t.tech.high_tech&&t.tech.high_tech>=16?0:t.tech.high_tech&&t.tech.high_tech>=12?1:2,K("organizer",0)?18:10],federation:()=>[3,K("organizer",0)?12:10,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?40:36:32],magocracy:()=>[K("organizer",0)?30:25,t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?50:40:25]};function ee(e){return t.race.witch_hunter&&"magocracy"===e?z("witch_hunter_magocracy"):z(`govern_${e}_desc`)}function te(){if(0===$("#foreign").length&&!t.race.cataclysm&&(!t.tech.world_control||t.race.truepath)&&!t.tech.isolation){let a=$('
                            ');a.append($(`

                            ${z("civics_foreign")}

                            `)),$("#r_govern0").append(a);var e={template:''};let r=t.race.truepath?5:3;for(let e=0;e{{ '${e}' | gov }} - ${z("civics_garrison_occupy")} - ${z("civics_garrison_annex")} - ${z("civics_garrison_purchase")}
                            `);a.append(t);let r=$("
                            ");r.append($(``)),r.append($(``)),r.append($(``)),t.append(r),t.append($(`
                            ${z("civics_gov_mil_rate")}: {{ f${e}.mil | military(${e}) }} ({{ f${e}.mil }})
                            `)),t.append($(`
                            ${z("civics_gov_relations")}: {{ f${e}.hstl | relation }} ({{ f${e}.hstl | hate }})
                            `)),t.append($(`
                            ${z("civics_gov_eco_rate")}: {{ f${e}.eco | eco(${e}) }} ({{ f${e}.eco }})
                            `)),t.append($(`
                            ${z("civics_gov_unrest")}: {{ f${e}.unrest | discontent(${e}) }} ({{ f${e}.unrest | turmoil }})
                            `))}let i={f0:t.civic.foreign.gov0,f1:t.civic.foreign.gov1,f2:t.civic.foreign.gov2,t:t.tech,s:t.settings};t.race.truepath&&(i.f3=t.civic.foreign.gov3,i.f4=t.civic.foreign.gov4),Cs({el:"#foreign",data:i,filters:{military:(e,a)=>t.civic.foreign[`gov${a}`].spy>=1?z(e<50?"civics_gov_v_weak":e<75?"civics_gov_weak":e>300?"civics_gov_superpower":e>200?"civics_gov_v_strong":e>160?"civics_gov_strong":e>125?"civics_gov_above_average":"civics_gov_average"):"???",relation:e=>z(e>80?"civics_gov_hated":e>60?"civics_gov_hostile":e>40?"civics_gov_poor":e>25?"civics_gov_neutral":e>10?"civics_gov_liked":"civics_gov_good"),eco:(e,a)=>t.civic.foreign[`gov${a}`].spy>=2?z(e<60?"civics_gov_weak":e<80?"civics_gov_recession":e>120?"civics_gov_strong":"civics_gov_average"):"???",discontent:(e,a)=>t.civic.foreign[`gov${a}`].spy>=3?z(e<=0?"civics_gov_none":e<30?"civics_gov_low":e<60?"civics_gov_medium":e<90?"civics_gov_high":"civics_gov_extreme"):"???",gov:e=>Z(e),sab:e=>"none"===e?"":z(`civics_spy_${e}`),hate:e=>100-e+"%",turmoil:e=>`${e}%`},methods:{campaign(e){ve(e)},battleAssessment:e=>ge(e),trigModal(a){this.$buefy.modal.open({parent:this,component:e});var r=setInterval((function(){$("#modalBox").length>0&&(clearInterval(r),function(e){$("#modalBox").append($(`

                            ${z("civics_espionage_actions")}

                            `));var a=$('
                            ');$("#modalBox").append(a),t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(a.append($(``)),a.append($(``)),e<3&&a.append($(``)),e<3&&t.civic.foreign[`gov${e}`].hstl<=50&&t.civic.foreign[`gov${e}`].unrest>=50&&a.append($(``)),e<3&&t.civic.foreign[`gov${e}`].spy>=3&&a.append($(``))),Cs({el:"#espModal",data:t.civic.foreign[`gov${e}`],methods:{influence(e){t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(oe("influence",e),Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),_s())},sabotage(e){t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(oe("sabotage",e),Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),$("#popGov").hide(),_s())},incite(e){e>=3||t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=1&&(oe("incite",e),Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),_s())},annex(a){if(!(a>=3)&&t.civic.foreign[`gov${e}`].hstl<=50&&t.civic.foreign[`gov${e}`].unrest>=50&&t.city.morale.current>=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest&&t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&t.civic.foreign[`gov${a}`].sab<=0){let e=t.tech.spy>=4?150:300;t.race.befuddle&&(e=Math.round(e*(1-Ei.befuddle.vars()[0]/100)));let r=ts("dryad");r>0&&(e=Math.round(e*(1-Ei.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="annex",Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),_s()}},purchase(e){if(e>=3)return;let a=ne(e);if(a<=t.resource.Money.amount&&t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${e}`].spy>=3&&t.civic.foreign[`gov${e}`].sab<=0){t.resource.Money.amount-=a;let r=t.tech.spy>=4?150:300;t.race.befuddle&&(r=Math.round(r*(1-Ei.befuddle.vars()[0]/100)));let i=ts("dryad");i>0&&(r=Math.round(r*(1-Ei.befuddle.vars(1)[0]/100*i))),t.civic.foreign[`gov${e}`].sab=r,t.civic.foreign[`gov${e}`].act="purchase",Cs({el:"#espModal"},"destroy"),$(".modal-background").click(),_s()}}}}),ls("GovLabel",(function(a){let r=$(a.this).data("esp"),i="";if("purchase"===r){let t=ne(e).toLocaleString();i=z(`civics_spy_${r}_desc`,[Z(e),t])}else if("annex"===r)if(t.city.morale.current>=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest)i=z(`civics_spy_${r}_desc`,[Z(e)]);else{let a=200+t.civic.foreign[`gov${e}`].hstl-t.civic.foreign[`gov${e}`].unrest;i=z(`civics_spy_${r}_goal`,[Z(e),a])}else i=z(`civics_spy_${r}_desc`,[Z(e)]);let s="";return("influence"===r&&0===t.civic.foreign[`gov${e}`].hstl||"sabotage"===r&&t.civic.foreign[`gov${e}`].spy>=2&&50===t.civic.foreign[`gov${e}`].mil||"incite"===r&&t.civic.foreign[`gov${e}`].spy>=4&&100===t.civic.foreign[`gov${e}`].unrest)&&(s=`
                            ${z("civics_spy_warning")}
                            `),$(`${s}
                            ${i}
                            `)}),{elm:"#espModal button",self:!0,classes:"has-background-light has-text-dark"})}(a))}),50)},spy_disabled:e=>t.civic.foreign[`gov${e}`].trn>0||ie(e)>t.resource.Money.amount,spy(e){se(e)},spyDesc:e=>ae(e),espDesc:()=>re(),vis:()=>!(!t.civic.garrison.display||t.tech.world_control&&!t.race.truepath||t.race.cataclysm||t.tech.isolation),gvis:e=>!t.tech.isolation&&(e<=2?!t.tech.world_control:3===e&&!!t.tech.rival)}});for(let e=0;e{{ label() }}"}),{elm:`#gov${e} .attack`,in:function(t){Cs({el:`#${t.id} > span`,data:{test:"val"},methods:{label:()=>ge(e)}})},out:function(e){Cs({el:e.id},"destroy")}}),ls(`gov${e}ts`,(function(){return"{{ label() }}"}),{elm:`#gov${e} .tspy`,in:function(t){Cs({el:`#${t.id} > span`,data:{test:"val"},methods:{label:()=>ae(e)}})},out:function(e){Cs({el:e.id},"destroy")}}),ls(`gov${e}s`,(function(){return re()}),{elm:`#gov${e} .sspy`});t.race.truepath&&ls("garRivaldesc1",(function(){return z("civics_gov_tp_rival",[Z(3),Ki[t.race.species].home])}),{elm:"#gov3 > span"})}}function ae(e){return t.civic.foreign[`gov${e}`].trn>0?z("civics_progress"):z("civics_gov_spy_desc",[x(ie(e))])}function re(){return z("civics_gov_esp_desc")}function ie(e){let a=Math.round(t.civic.foreign[`gov${e}`].mil/2+t.civic.foreign[`gov${e}`].hstl/2-t.civic.foreign[`gov${e}`].unrest)+10;return a<50&&(a=50),t.race.infiltrator&&(a/=3),"scorpio"===N()&&(a*=1-G("scorpio")[0]/100),Math.round(a**(t.civic.foreign[`gov${e}`].spy+1))+500}function se(e){if(t.tech.spy&&t.civic.foreign[`gov${e}`].trn<=0){let a=ie(e);if(t.resource.Money.amount>=a){t.resource.Money.amount-=a;let r=300;t.tech.spy>=3&&t.city.boot_camp&&(r-=10*(t.race.orbit_decayed&&t.space.space_barracks?t.space.space_barracks.on:t.city.boot_camp.count),r<10&&(r=10)),t.race.infiltrator&&(r=Math.round(r/2)),t.civic.foreign[`gov${e}`].trn=r}}}function ne(e){let a=15384*t.civic.foreign[`gov${e}`].eco;return a*=1+1.6*t.civic.foreign[`gov${e}`].hstl/100,a*=1-.25*t.civic.foreign[`gov${e}`].unrest/100,+a.toFixed(0)}function ce(e){return e?t.tech.world_control||t.civic.foreign[e].occ||t.civic.foreign[e].anx||t.civic.foreign[e].buy:t.civic.foreign.gov0.occ||t.civic.foreign.gov1.occ||t.civic.foreign.gov2.occ||t.civic.foreign.gov0.anx||t.civic.foreign.gov1.anx||t.civic.foreign.gov2.anx||t.civic.foreign.gov0.buy||t.civic.foreign.gov1.buy||t.civic.foreign.gov2.buy}function oe(e,a){switch(e){case"influence":if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&t.civic.foreign[`gov${a}`].sab<=0){let e=t.tech.spy>=4?200:300;t.race.befuddle&&(e=Math.round(e*(1-Ei.befuddle.vars()[0]/100)));let r=ts("dryad");r>0&&(e=Math.round(e*(1-Ei.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="influence"}break;case"sabotage":if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&t.civic.foreign[`gov${a}`].sab<=0){let e=t.tech.spy>=4?400:600;t.race.befuddle&&(e=Math.round(e*(1-Ei.befuddle.vars()[0]/100)));let r=ts("dryad");r>0&&(e=Math.round(e*(1-Ei.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="sabotage"}break;case"incite":if(a>=3)break;if(t.tech.spy&&t.tech.spy>=2&&t.civic.foreign[`gov${a}`].spy>=1&&t.civic.foreign[`gov${a}`].sab<=0){let e=t.tech.spy>=4?600:900;t.race.befuddle&&(e=Math.round(e*(1-Ei.befuddle.vars()[0]/100)));let r=ts("dryad");r>0&&(e=Math.round(e*(1-Ei.befuddle.vars(1)[0]/100*r))),t.civic.foreign[`gov${a}`].sab=e,t.civic.foreign[`gov${a}`].act="incite"}}}function le(e){let a=!!(t.tech.currency&&t.tech.currency>=5);if(e)return!a&&!t.race.terrifying||t.race.noble?t.race.noble?Ei.noble.vars()[0]:10:0;{let e=30;t.race.noble?e=Ei.noble.vars()[1]:(a||t.race.terrifying)&&(e+=20),"oligarchy"===t.civic.govern.type&&(e+=Y.oligarchy()[1]);let r=K("aristocrat",1);return r&&(e+=r),e}}function _e(e,a){switch(e){case"add":{let e=a||y(),r=le(!1);t.race.noble?(t.civic.taxes.tax_rate+=e,t.civic.taxes.tax_rate>("oligarchy"===t.civic.govern.type?40:20)&&(t.civic.taxes.tax_rate="oligarchy"===t.civic.govern.type?40:20)):t.civic.taxes.tax_rater&&(t.civic.taxes.tax_rate=r))}break;case"sub":{let e=a||y(),r=le(!0);t.civic.taxes.tax_rate>r&&(t.civic.taxes.tax_rate-=e,t.civic.taxes.tax_rate25e3&&(e=25e3),t.civic.garrison.m_use>0&&(e*=1.1**t.civic.garrison.m_use),t.race.brute&&(e*=1-Ei.brute.vars()[0]/100);let a=ts("orc");return a>0&&(e*=1-Ei.brute.vars(1)[0]/100*a),t.race.inflation&&(e*=1+t.race.inflation/500),t.race.high_pop&&(e*=Ei.high_pop.vars()[1]/100),Math.round(e)}function ue(e){if(t.tech.mercs){let a=e||y(),r=!0;for(;r&&a>0;){let e=pe();t.civic.garrison.workers=e?(t.resource.Money.amount-=e,t.civic.garrison.workers++,t.civic.garrison.m_use++):r=!1,a--}}}function he(e,a){Ss(e),t.tech.world_control&&!t.race.truepath?e.append($(`

                            ${z("civics_garrison")}

                            - ${z("rating")} {{ g.workers | hell | rating }}
                            `)):e.append($(`

                            ${z("civics_garrison")}

                            - ${z("rating")} {{ g.workers | hell | rating }} / {{ g.raid | rating }}
                            `));var r=$('
                            ');e.append(r);var i=$('
                            ');r.append(i);let s=t.tech.world_control&&!t.race.truepath?z("civics_garrison_peacekeepers"):z("civics_garrison_soldiers");if(t.tech.isolation||(i.append($(`
                            ${s} / {{ g.max | s_max }}
                            `)),i.append($(`
                            ${z("civics_garrison_crew")} {{ g.crew }}
                            `)),i.append($(`
                            ${z("civics_garrison_wounded")}
                            `)),r.append($(`
                            `))),a){let a="";t.tech.isolation&&(a=Qs(8,12)),e.append($(`
                            ${z("civics_garrison_training")} - ${z("arpa_to_complete")} {{ g.rate, g.progress | trainTime }}${a} {{ g.progress }}%
                            `))}var n=$('
                            ');e.append(n);var c=$('
                            ');if(n.append(c),(!t.tech.world_control||t.race.truepath)&&!t.race.cataclysm&&!t.tech.isolation){var o=$(`
                            ${z("civics_garrison_campaign")}
                            `);c.append(o);var l=$('{{ g.tactic | tactics }}'),_=$('«'),d=$('»');o.append(_),o.append(l),o.append(d);var p=$(`
                            ${z("civics_garrison_battalion")}
                            `);c.append(p);var u=$('{{ g.raid }}'),h=$('«'),m=$('»');p.append(h),p.append(u),p.append(m),a&&(t.race.truepath&&t.tech.rival&&n.append($(`
                            ${Z(3)}
                            `)),t.tech.world_control||(n.append($(`
                            ${Z(0)}
                            `)),n.append($(`
                            ${Z(1)}
                            `)),n.append($(`
                            ${Z(2)}
                            `))))}let g={g:t.civic.garrison,g0:t.civic.foreign.gov0,g1:t.civic.foreign.gov1,g2:t.civic.foreign.gov2};if(t.race.truepath&&(g.g3=t.civic.foreign.gov3,g.g4=t.civic.foreign.gov4),Cs({el:a?"#garrison":"#c_garrison",data:g,methods:{hire(){ue()},campaign(e){ve(e)},next(){t.civic.garrison.tactic<4&&t.civic.garrison.tactic++},last(){t.civic.garrison.tactic>0&&t.civic.garrison.tactic--},aNext(){let e=y();t.civic.garrison.raidwe()&&(t.civic.garrison.raid=we()))},aLast(){let e=y();t.civic.garrison.raid>0&&(t.civic.garrison.raid-=e,t.civic.garrison.raid<0&&(t.civic.garrison.raid=0))},vis:()=>t.civic.garrison.display,rvis:()=>!(!t.tech.rival||t.tech.isolation)},filters:{tactics(e){switch(e){case 0:return z("civics_garrison_tactic_ambush");case 1:return z("civics_garrison_tactic_raid");case 2:return z("civics_garrison_tactic_pillage");case 3:return z("civics_garrison_tactic_assault");case 4:return z("civics_garrison_tactic_siege")}},rating:e=>+be(e,"army").toFixed(1),hell:e=>we(),stationed(e){let r=we(),i=t.race.cataclysm?13:31,s=r===i&&!a&&Js(2,14,!0);return r===i&&s.length>0?s:r},s_max:e=>we(!0),wounded(e){let t=Qs(8,12);return a&&0===e&&t.length>0?t:cn("fool",2021)?we()-e:e},trainTime:(e,t)=>zs(0===e?-1:(100-t)/(4*e))}}),["tactic","bat","soldier","crew","wounded","hmerc","defenseRating","offenseRating"].forEach((function(e){ls(a?`garrison${e}`:`cGarrison${e}`,(function(){return"{{ label() }}"}),{elm:`${a?"#garrison":"#c_garrison"} .${e}`,in:function(a){Cs({el:`#${a.id} > span`,data:{test:"val"},methods:{label(){switch(e){case"tactic":switch(t.civic.garrison.tactic){case 0:return z("civics_garrison_tactic_ambush_desc");case 1:return z("civics_garrison_tactic_raid_desc");case 2:return z("civics_garrison_tactic_pillage_desc");case 3:return z("civics_garrison_tactic_assault_desc");case 4:return z("civics_garrison_tactic_siege_desc",[ta("federation"===t.civic.govern.type?15:20)])}case"bat":return z("civics_garrison_army_label");case"soldier":return me();case"crew":return z("civics_garrison_crew_desc");case"wounded":return z("civics_garrison_wounded_desc");case"hmerc":return z("civics_garrison_hire_mercenary_cost",[Math.round(pe()).toLocaleString()]);case"defenseRating":return z("civics_garrison_defensive_rate");case"offenseRating":return z("civics_garrison_offensive_rate")}}}})},out:function(e){Cs({el:e.id},"destroy")}})})),a){let e=t.race.truepath?4:3;for(let t=0;t{{ label() }}"}),{elm:`#garrison .gov${t} button`,in:function(e){Cs({el:`#${e.id} > span`,data:{test:"val"},methods:{label:()=>ge(t)}})},out:function(e){Cs({el:e.id},"destroy")}});t.race.truepath&&!t.tech.isolation&&ls("garRivaldesc2",(function(){return z("civics_gov_tp_rival",[Z(3),Ki[t.race.species].home])}),{elm:"#garrison .gov3 > div"})}}function me(){let e=be(we(),"hunting"),a=[];if((!t.race.herbivore||t.race.carnivore)&&!t.race.artifical){let r=+(e/3).toFixed(2);a.push(r,t.resource.Food.name)}let r=+(e/10).toFixed(2);if(a.push(r,t.resource.Furs.name),t.race.evil&&!t.race.kindling_kindred&&!t.race.smoldering){let r=+(e/(t.race.soul_eater?3:5)).toFixed(2);a.push(r,t.resource.Lumber.name)}let i="civics_garrison_soldier_loot"+a.length/2;return z(t.race.evil&&t.race.soul_eater?"civics_garrison_soldier_evil_desc":"civics_garrison_soldier_desc")+z(i,a)}function ge(e){if(t.civic.foreign[`gov${e}`].occ)return z("civics_garrison_deoccupy_desc");if(t.civic.foreign[`gov${e}`].buy||t.civic.foreign[`gov${e}`].anx)return z("civics_garrison_secede_desc");if(t.civic.garrison.tactic<=1&&t.civic.foreign[`gov${e}`].spy<1||t.civic.garrison.tactic>=2&&t.civic.garrison.tactic<=3&&t.civic.foreign[`gov${e}`].spy<2||4===t.civic.garrison.tactic&&t.civic.foreign[`gov${e}`].spy<3)return z("civics_garrison_no_spy");let a=be(t.civic.garrison.raid,"army"),r=0;switch(t.civic.garrison.tactic){case 0:r=5;break;case 1:r=27.5;break;case 2:r=62.5;break;case 3:r=125;break;case 4:r=300}return r*=t.civic.foreign[`gov${e}`].mil/100,t.race.banana&&(r*=2),"swamp"===t.city.biome&&(r*=is.swamp.vars()[0]),cn("fool",2021)&&(r/=1.25),awe()?t.civic.garrison.raid=we():t.civic.garrison.raid<0&&(t.civic.garrison.raid=0),0===t.civic.garrison.raid)return void hs(z("civics_garrison_campaign_no_soldier"),"warning",!1,["combat"]);t.stats.attacks++;let a=t.race.claws?20:16,r=t.race.puny?3:5,i=Math.floor(m(r,a,!0))/10,s=be(t.civic.garrison.raid,"army")*i,n=0;switch(t.civic.garrison.tactic){case 0:n=m(0,10,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(0,2,!0));break;case 1:n=m(5,50,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(0,3,!0));break;case 2:n=m(25,100,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(1,5,!0));break;case 3:n=m(50,200,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(4,12,!0));break;case 4:n=m(100,500,!0),t.civic.foreign[`gov${e}`].hstl+=Math.floor(m(10,25,!0))}n=Math.floor(n*t.civic.foreign[`gov${e}`].mil/100),t.race.banana&&(n*=2),"swamp"===t.city.biome&&(n*=is.swamp.vars()[0]),t.race.mistrustful&&(t.civic.foreign[`gov${e}`].hstl+=Ei.mistrustful.vars()[0]),t.civic.foreign[`gov${e}`].hstl>100&&(t.civic.foreign[`gov${e}`].hstl=100),t.race.blood_thirst&&(t.race.blood_thirst_count+=Math.ceil(n/5),t.race.blood_thirst_count>Ei.blood_thirst.vars()[0]&&(t.race.blood_thirst_count=Ei.blood_thirst.vars()[0]));let c=0;if(t.civic.garrison.raid>t.civic.garrison.workers-t.civic.garrison.crew-t.civic.garrison.wounded&&(c=t.civic.garrison.raid-(t.civic.garrison.workers-t.civic.garrison.crew-t.civic.garrison.wounded)),t.civic.garrison.fatigue++,s>n){let a=Math.floor(t.civic.garrison.raid/(5-t.civic.garrison.tactic));a+=c,t.city.ptrait.includes("rage")&&(a+=ss.rage.vars()[2]),a<1&&(a=1),a>fe()&&(a=fe());let r=Math.floor(m(0,a,!0));t.race.frail&&(r+=Ei.frail.vars()[0]);let i=0;if(t.race.scales&&(i+=Ei.scales.vars()[0]),t.tech.armor&&(i+=t.tech.armor),t.race.high_pop&&(i+=Math.floor(m(0,i*Ei.high_pop.vars()[0],!0))),t.race.armored){let e=1-Ei.armored.vars()[0]/100;i+=Math.floor(r*e)}let s=ts("tortoisan");if(s>0){let e=1-Ei.armored.vars(1)[0]/100*s;i+=Math.floor(r*e)}if(t.civic.garrison.raid>c&&(r-=i),r<0&&(r=0),r>t.civic.garrison.raid&&(r=t.civic.garrison.raid),t.race.instinct){let e=Math.floor(r*(Ei.instinct.vars()[1]/100));r-=e,c+=e}t.civic.garrison.workers-=r,t.stats.died+=r,t.civic.garrison.protest+=r,r>c?(t.civic.garrison.wounded-=c,c=0):(t.civic.garrison.wounded-=r,c-=r),t.civic.garrison.wounded+=Math.floor(m(c,t.civic.garrison.raid-r,!0));let n={Money:0,Food:0,Lumber:0,Stone:0,Copper:0,Iron:0,Aluminium:0,Coal:0,Cement:0,Steel:0,Titanium:0,Crystal:0,Chrysotile:0,Furs:0,Iridium:0,Alloy:0,Polymer:0,Oil:0},o=3===e&&t.race.truepath?["Food","Lumber","Stone","Copper","Iron"]:["Food","Lumber","Stone"],l=3===e&&t.race.truepath?["Aluminium","Coal","Cement","Steel","Furs"]:["Copper","Iron","Aluminium","Coal"],_=3===e&&t.race.truepath?["Titanium","Oil","Iridium","Alloy","Polymer"]:["Cement","Steel"];t.race.artifical&&o.shift(),t.race.smoldering&&o.push("Chrysotile"),t.race.terrifying&&3!==e&&_.push("Titanium"),t.tech.magic&&_.push("Crystal");let d=["Money"];switch(t.civic.garrison.tactic){case 0:{let e=["Money"].concat(o,l);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))]),t.resource.Steel.amount<25&&t.tech.smelting&&1===t.tech.smelting&&0===Math.floor(m(0,20,!0))&&d.push("Steel")}break;case 1:{let e=["Money"].concat(o,l,_);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 2:{let e=["Money"].concat(o,l,_),a=l.concat(_);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),d.push(a[Math.floor(m(0,a.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 3:{let e=["Money"].concat(o,l,_);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(_[Math.floor(m(0,_.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}break;case 4:{let e=["Money"].concat(o,l,_);d.push(o[Math.floor(m(0,o.length,!0))]),d.push(l[Math.floor(m(0,l.length,!0))]),d.push(_[Math.floor(m(0,_.length,!0))]),d.push(e[Math.floor(m(0,e.length,!0))]),t.race.beast_of_burden&&d.push(e[Math.floor(m(0,e.length,!0))])}}let p=t.race.terrifying&&3!==e?Ei.terrifying.vars()[0]:12,u=t.race.terrifying&&3!==e?Ei.terrifying.vars()[1]:32;d.forEach((function(e){switch(e){case"Money":n[e]+=Math.floor(m(100,375,!0));break;case"Food":n[e]+=Math.floor(m(40,175,!0));break;case"Lumber":case"Stone":n[e]+=Math.floor(m(50,250,!0));break;case"Copper":case"Iron":case"Aluminium":n[e]+=Math.floor(m(35,125,!0));break;case"Coal":case"Cement":n[e]+=Math.floor(m(25,100,!0));break;case"Steel":case"Chrysotile":n[e]+=Math.floor(m(20,65,!0));break;case"Titanium":n[e]+=Math.floor(m(p,u,!0));break;case"Crystal":n[e]+=Math.floor(m(1,5,!0));break;case"Oil":n[e]+=Math.floor(m(20,50,!0));break;case"Iridium":n[e]+=Math.floor(m(2,30,!0));break;case"Alloy":case"Polymer":n[e]+=Math.floor(m(5,38,!0))}}));let h=z("civics_garrison_gained");t.resource.Money.display&&n.Money>0&&(n.Money=ye(n.Money,e),h+=z("civics_garrison_quant_money",[n.Money]),$s("Money",n.Money)),o.concat(l,_).forEach((function(a){n[a]>0&&(t.resource[a].display||"Steel"===a||"Titanium"===a)&&(n[a]=ye(n[a],e),h+=z("civics_garrison_quant_res",[n[a],t.resource[a].name]),$s(a,n[a]),"Steel"!==a&&"Titanium"!==a||(t.resource[a].display=!0))})),h=h.slice(0,-2),h+=".",hs(h,"warning",!1,["combat"]);let g=0;if(t.race.revive){switch(t.city.calendar.temp){case 0:g=Math.floor(m(0,Math.floor(r/Ei.revive.vars()[0]),!0));break;case 1:g=Math.floor(m(0,Math.floor(r/Ei.revive.vars()[1]),!0));break;case 2:g=Math.floor(m(0,Math.floor(r/Ei.revive.vars()[2]),!0))}t.civic.garrison.workers+=g}if(hs(g>0?z("civics_garrison_victorious_revive",[r,g]):z("civics_garrison_victorious",[r]),"success",!1,["combat"]),t.race.slaver&&t.city.slave_pen){let e=4*t.city.slave_pen.count;if(e>t.city.slave_pen.slaves){let a=Math.floor(m(0,t.civic.garrison.tactic+2,!0));a+t.city.slave_pen.slaves>e&&(a=e-t.city.slave_pen.slaves),a>0&&(t.city.slave_pen.slaves+=a,t.resource.Slave.amount=t.city.slave_pen.slaves,hs(z("civics_garrison_capture",[a]),"success",!1,["combat"]))}}if(t.race.infectious){let e=0;switch(t.civic.garrison.tactic){case 0:e=Math.floor(m(0,Ei.infectious.vars()[0],!0));break;case 1:e=Math.floor(m(0,Ei.infectious.vars()[1],!0));break;case 2:e=Math.floor(m(0,Ei.infectious.vars()[2],!0));break;case 3:e=Math.floor(m(0,Ei.infectious.vars()[3],!0));break;case 4:e=Math.floor(m(0,Ei.infectious.vars()[4],!0))}t.resource[t.race.species].amount+e>t.resource[t.race.species].max&&(e=t.resource[t.race.species].max-t.resource[t.race.species].amount),e>0&&(t.resource[t.race.species].amount+=e,"unemployed"!==t.civic.d_job&&(t.civic[t.civic.d_job].workers+=e),hs(1===e?z("civics_garrison_soldier_infected"):z("civics_garrison_soldiers_infected",[e]),"special",!1,["combat"]))}let v=ta("federation"===t.civic.govern.type?15:20);if(e<=2&&4===t.civic.garrison.tactic&&t.civic.garrison.workers>=v){let a=!t.tech.gov_fed&&!ce();if(t.civic.garrison.workers-=v,t.civic.foreign[`gov${e}`].occ=!0,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none",a&&Qr(),t.race.banana){let e=xn();t.stats.banana.b1[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b1.l=!0)}}}else{let e=t.civic.garrison.raid;e+=c,0===t.civic.garrison.tactic&&(e=Math.floor(e/2)),t.city.ptrait.includes("rage")&&(e+=ss.rage.vars()[2]),e<1&&(e=1),e>fe()&&(e=fe());let a=Math.floor(m(1,e,!0));t.race.frail&&(a+=t.civic.garrison.tactic+Ei.frail.vars()[1]);let r=0;if(t.race.scales&&(r+=Ei.scales.vars()[1]),t.tech.armor&&(r+=t.tech.armor),t.race.high_pop&&(r+=Math.floor(m(0,Math.floor(r*Ei.high_pop.vars()[0]/2),!0))),t.race.armored){let e=Ei.armored.vars()[0]/100;r+=Math.floor(a*e)}let i=ts("tortoisan");if(i>0){let e=Ei.armored.vars(1)[0]/100*i;r+=Math.floor(a*e)}if(t.civic.garrison.raid>c&&(a-=r),t.race.instinct){let e=Math.floor(a*(Ei.instinct.vars()[1]/100));a-=e,c+=e}a<1&&(a=1),a>t.civic.garrison.raid&&(a=t.civic.garrison.raid),t.civic.garrison.workers-=a,t.stats.died+=a,t.civic.garrison.protest+=a,a>c?(t.civic.garrison.wounded-=c,c=0):(t.civic.garrison.wounded-=a,c-=a),t.civic.garrison.wounded+=1+Math.floor(m(c,t.civic.garrison.raid-a,!0));let s=0;if(t.race.revive){switch(t.city.calendar.temp){case 0:s=Math.floor(m(0,Math.floor(a/Ei.revive.vars()[3]),!0));break;case 1:s=Math.floor(m(0,Math.floor(a/Ei.revive.vars()[4]),!0));break;case 2:s=Math.floor(m(0,Math.floor(a/Ei.revive.vars()[5]),!0))}t.civic.garrison.workers+=s}hs(s>0?z("civics_garrison_defeat_revive",[a,s]):z("civics_garrison_defeat",[a]),"danger",!1,["combat"])}t.civic.garrison.wounded>t.civic.garrison.workers-t.civic.garrison.crew?t.civic.garrison.wounded=t.civic.garrison.workers-t.civic.garrison.crew:t.civic.garrison.wounded<0&&(t.civic.garrison.wounded=0)}function fe(){let e=0,a=t.civic.garrison.raid;switch(t.civic.garrison.tactic){case 0:e=5;break;case 1:e=10;break;case 2:e=25;break;case 3:e=50;break;case 4:e=999}return t.race.high_pop&&(e=ta(e)),a>e&&(a=e),a}function ye(e,a){let r=fe();t.race.high_pop&&(r/=ta(1));let i=e*Math.log(r+1);switch(t.race.invertebrate&&(i*=1-Ei.invertebrate.vars()[0]/100),"evil"===t.race.universe&&(i*=Is("evil")),t.civic.garrison.tactic){case 1:i*=4;break;case 2:i*=30;break;case 3:i*=100;break;case 4:i*=400}return t.race.banana&&(i*=.5),"swamp"===t.city.biome&&(i*=is.swamp.vars()[1]),Math.floor(i*t.civic.foreign[`gov${a}`].eco/100)}function be(e,a,r){if(!t.civic.hasOwnProperty("garrison"))return 1;let i=0;"number"==typeof r?i=r:e>t.civic.garrison.workers-t.civic.garrison.wounded&&(i=e-(t.civic.garrison.workers-t.civic.garrison.wounded));let s=function(){let e=t.tech.military?t.tech.military>=5?t.tech.military-1:t.tech.military:1;if(t.tech.military&&t.tech.military>1){e-=t.tech.military>=11?2:1,t.race.sniper&&(e*=1+Ei.sniper.vars()[0]/100*e);let a=ts("centaur");a>0&&(e*=1+Ei.sniper.vars(1)[0]/100*e*a),e+=t.tech.military>=11?2:1}return e}(),n=ts("rhinotaur"),c=e-i/2;(t.race.rage||n>0)&&(c=e+(t.race.rage?i*Ei.rage.vars()[1]/100:0)+(n>0?i*Ei.rage.vars(1)[1]/100*n:0));let o=t.tech.military?c*s:c;if("army"===a||"hellArmy"===a){t.race.rage&&(o*=1+Ei.rage.vars()[0]/100*(t.civic.garrison.wounded||0)),n>0&&(o*=1+Ei.rage.vars(1)[0]/100*n*(t.civic.garrison.wounded||0)),t.race.puny&&(o*=1-Ei.puny.vars()[0]/100),t.race.claws&&(o*=1+Ei.claws.vars()[0]/100);let r=ts("scorpid");r>0&&(o*=1+Ei.claws.vars(1)[0]/100*r),t.race.chameleon&&(o*=1+Ei.chameleon.vars()[0]/100),t.race.cautious&&0===t.city.calendar.weather&&(o*=1-Ei.cautious.vars()[0]/100),t.race.apex_predator&&(o*=1+Ei.apex_predator.vars()[0]/100);let i=ts("sharkin");i>0&&(o*=1+Ei.apex_predator.vars(1)[0]/100*i),t.race.swift&&(o*=1+Ei.swift.vars()[0]/100),t.race.fiery&&(o*=1+Ei.fiery.vars()[0]/100);let s=ts("balorg");s>0&&(o*=1+Ei.fiery.vars(1)[0]/100*s),t.race.sticky&&(o*=1+Ei.sticky.vars()[1]/100);let c=ts("pinguicula");c>0&&(o*=1+Ei.sticky.vars(1)[1]/100*c),t.race.pathetic&&(o*=1-Ei.pathetic.vars()[0]/100),t.race.tactical&&(o*=1+Ei.tactical.vars()[0]*t.race.tactical/100),t.tech.fanaticism&&t.tech.fanaticism>=4&&(o*=1+.01*t.city.temple.count),t.race.holy&&"hellArmy"===a&&(o*=1+Ei.holy.vars()[0]/100);let l=ts("unicorn");l>0&&"hellArmy"===a&&(o*=1+Ei.holy.vars(1)[0]/100*l),t.race.banana&&"hellArmy"===a&&(o*=.8),"aries"===N()&&(o*=1+G("aries")[0]/100);let _=K("tactician",0);if(_&&(o*=1+_/100),t.city.ptrait.includes("rage")&&(o*=ss.rage.vars()[0]),t.race.parasite&&(1===e?o+=2:e>1&&(o+=4)),t.tech.psychic&&t.race.psychicPowers&&t.race.psychicPowers.hasOwnProperty("assaultTime")){let e=0;if(t.race.psychicPowers.assaultTime>0&&(e+=Ei.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(Ei.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.assault).toFixed(3)}o*=1+e}}return"hunting"===a&&t.race.unfathomable&&(o*=.66),t.race.rejuvenated&&(o*=1.05),"autocracy"===t.civic.govern.type&&(o*=1+Y.autocracy()[1]/100),o=Math.floor(o),o*Bi(e,a)}function we(e,a){if(!t.civic.garrison)return 0;let r=e?"max":"workers",i=t.portal.fortress?t.portal.fortress.garrison:0,s=t.space.fob&&!a?t.space.fob.troops:0;return t.civic.garrison[r]-t.civic.garrison.crew-i-s}function ke(e){return t.race.high_pop&&(e*=Ei.high_pop.vars()[1]/100),e}function $e(e,a){switch(e){case"transmitter":return 2.5;case"oil_well":{let e=t.tech.oil>=4?.48:.4;t.tech.oil>=7?e*=2:t.tech.oil>=5&&(e*=t.tech.oil>=6?1.75:1.25),t.city.geology.Oil&&(e*=t.city.geology.Oil+1),"desert"===t.city.biome?e*=is.desert.vars()[1]:"tundra"===t.city.biome?e*=is.tundra.vars()[1]:"taiga"===t.city.biome&&(e*=is.taiga.vars()[2]);let a=K("dirty_jobs",2);return a&&(e*=1+a/100),e}case"iridium_mine":switch(a){case"iridium":{let e=.035;t.city.geology.Iridium&&(e*=t.city.geology.Iridium+1);let a=e,r=J(3);return{b:a,g:r-1,f:a*r}}case"coal":return.55}case"helium_mine":{let e=.18,t=J(3);return{b:e,g:t-1,f:e*t}}case"red_mine":switch(a){case"copper":{let e=ke(.25),t=J(3);return{b:e,g:t-1,f:e*t}}case"titanium":{let e=ke(.02),t=J(3);return{b:e,g:t-1,f:e*t}}case"stone":return ke(.75);case"asbestos":return ke(1.25);case"aluminium":return ke(.066)}case"biodome":switch(a){case"food":return ke(.25);case"cat_food":return 2;case"lumber":return ke(1.5)}case"gas_mining":return t.tech.helium?.65:.5;case"outpost":{let e={b:.025,d:0,n:0};if(t.tech.drone){let a=t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3?.12:.06;e.d=t.space.drone.count*a,e.n=e.b*(1+e.d)}else e.n=e.b;return a?e:e.n}case"oil_extractor":{let e=t.tech.oil>=4?.48:.4;return t.tech.oil>=7?e*=2:t.tech.oil>=5&&(e*=t.tech.oil>=6?1.75:1.25),e}case"elerium_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?.009:.0075:.005;case"iridium_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?.1:.08:.055;case"iron_ship":return t.tech.asteroid>=6?t.tech.asteroid>=7?4:3:2;case"g_factory":if(t.race.truepath){if(t.tech.isolation)return 1.8;{let e=.05*(s.ai_colonist?t.civic.titan_colonist.workers+ta(s.ai_colonist):t.civic.titan_colonist.workers);return t.race.high_pop&&(e=ke(e)),e}}return.6;case"harvester":switch(a){case"helium":return.85;case"deuterium":return.15}case"elerium_prospector":return.014;case"neutron_miner":return.055;case"bolognium_ship":return.008;case"excavator":return.2;case"vitreloy_plant":{let e=.18;return"corpocracy"===t.civic.govern.type&&(e*=t.tech.high_tech&&t.tech.high_tech>=16?1.4:1.3),"socialist"===t.civic.govern.type&&(e*=1.1),e}case"infernite_mine":return.5*ga("gate").supress;case"water_freighter":return 1.25;case"titan_mine":switch(a){case"adamantite":return ke(.02)*(t.space.titan_mine?t.space.titan_mine.ratio:50)/100;case"aluminium":return ke(.12)*(100-(t.space.titan_mine?t.space.titan_mine.ratio:50))/100}case"lander":return 100===t.space.crashed_ship.count?.005:0;case"orichalcum_mine":return.08;case"uranium_mine":return.025;case"neutronium_mine":return.04;case"elerium_mine":return.009;case"shock_trooper":case"tank":return 100===t.space.digsite.count?.0018:0;case"mining_pit":{let e=0;switch(a){case"materials":e=t.tech.isolation?.12:.09;break;case"bolognium":e=t.tech.isolation?.0288:.0216;break;case"stone":e=t.tech.isolation?.8:.6;break;case"adamantite":e=t.tech.isolation?.448:.336;break;case"copper":e=.58;break;case"coal":e=.13;break;case"iron":e=.74;break;case"aluminium":e=.88;break;case"chrysotile":e=1.44}t.race.tough&&(e*=1+Ei.tough.vars()[0]/100);let r=ts("ogre");return r>0&&(e*=1+Ei.tough.vars(1)[0]/100*r),t.tech.tau_pit_mining&&(e*=1.18),e}case"tau_farm":switch(a){case"food":return t.tech.isolation?15:9;case"lumber":return t.tech.isolation?12:5.5;case"water":return.35}case"womling_mine":{let e=1;switch(t.tech.womling_mining&&(e+=.15*t.tech.womling_mining),t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5&&(e*=1.1),t.tech.womling_gene&&(e*=1.25),a){case"unobtainium":return.0305*e;case"uranium":return.047*e;case"titanium":return.616*e;case"copper":return 1.191*e;case"iron":return 1.377*e;case"aluminium":return 1.544*e;case"neutronium":return.382*e;case"iridium":return.535*e}}case"refueling_station":return t.tech.isolation?18.5:9.35;case"ore_refinery":return t.tech.tau_ore_mining?40:25;case"whaling_station":return 12;case"mining_ship":if(t.tauceti.patrol_ship){let e=1;return t.tauceti.patrol_ship.support>t.tauceti.patrol_ship.s_max&&(e=nn("curve",t.tauceti.patrol_ship.s_max/t.tauceti.patrol_ship.support,1.4)),(t.tech.tau_ore_mining&&t.tech.tau_ore_mining>=2?12:10)*e}return 0;case"mining_ship_ore":switch(a){case"iron":case"aluminium":return t.tech.isolation?2.22:1.85;case"iridium":case"neutronium":return t.tech.isolation?.42:.35;case"orichalcum":return t.tech.isolation?.3:.25;case"elerium":return t.tech.isolation?.024:.02}case"whaling_ship":if(t.tauceti.patrol_ship){let e=1;return t.tauceti.patrol_ship.support>t.tauceti.patrol_ship.s_max&&(e=nn("curve",t.tauceti.patrol_ship.s_max/t.tauceti.patrol_ship.support,1.4)),8*e}return 0;case"whaling_ship_oil":return t.tech.isolation?.78:.42;case"alien_outpost":return.01;case"psychic_boost":if(t.tech.psychic&&t.race.psychic&&t.race.psychicPowers&&t.race.psychicPowers.boost.r===a&&t.race.psychicPowers.hasOwnProperty("boostTime")){let e=0;if(t.race.psychicPowers.boostTime>0&&(e+=Ei.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(Ei.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.boost).toFixed(3)}return 1+e}return 1;case"psychic_cash":if(t.tech.psychic&&t.race.psychic&&t.race.psychicPowers&&t.race.psychicPowers.hasOwnProperty("cash")){let e=0;if(t.race.psychicPowers.cash>0&&(e+=Ei.psychic.vars()[3]/100),t.tech.psychic>=4&&t.race.psychicPowers.channel){let a=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;e+=+(Ei.psychic.vars()[3]/5e4*a*t.race.psychicPowers.channel.cash).toFixed(3)}return 1+e}return 1}}function xe(e){switch(e){case"Physics":Te();break;case"Genetics":Ee();break;case"Monument":return Ce();case"PhysicsTech":return qe;case"GeneTech":return je;case"BloodTech":return Oe;case"Crispr":Ke();break;case"Blood":De()}}const qe={lhc:{title:()=>cn("fool",2022)?z("arpa_projects_railway_title"):z("arpa_projects_lhc_title"),desc:()=>cn("fool",2022)?z("arpa_projects_railway_desc"):z("arpa_projects_lhc_desc"),reqs:{high_tech:6},grant:"supercollider",effect(e){if(cn("fool",2022)&&!e)return qe.railway.effect(!0);let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?t.race.cataclysm?20:8:t.race.cataclysm?10:4;return t.tech.storage>=6?t.tech.particles&&t.tech.particles>=4?t.race.cataclysm?z("arpa_projects_lhc_cataclysm3",[a]):z("arpa_projects_lhc_effect3",[a,t.race.orbit_decayed?z("space_home_satellite_title"):_i()]):t.race.cataclysm?z("arpa_projects_lhc_cataclysm2",[a]):z("arpa_projects_lhc_effect2",[a,t.race.orbit_decayed?z("space_home_satellite_title"):_i()]):t.race.cataclysm?z("arpa_projects_lhc_cataclysm1",[a]):t.tech.isolation?z("arpa_projects_lhc_iso1",[a,z("tech_infectious_disease_lab_alt")]):z("arpa_projects_lhc_effect1",[a,t.race.orbit_decayed?z("space_home_satellite_title"):_i()])},cost:{Money:(e,t)=>Ie("lhc",e,25e5,1.05,t),Knowledge:(e,t)=>Ie("lhc",e,5e5,1.05,t),Copper:(e,t)=>Ie("lhc",e,125e3,1.05,t),Cement:(e,t)=>Ie("lhc",e,25e4,1.05,t),Aluminium:(e,t)=>Ie("lhc",e,35e4,1.05,t),Titanium:(e,t)=>Ie("lhc",e,5e4,1.05,t),Polymer:(e,t)=>Ie("lhc",e,12e3,1.05,t)}},stock_exchange:{title:z("arpa_projects_stock_exchange_title"),desc:z("arpa_projects_stock_exchange_desc"),reqs:{banking:9},grant:"stock_exchange",effect:()=>t.tech.banking>=10?t.race.cataclysm?t.tech.gambling&&t.tech.gambling>=4?z("arpa_projects_stock_exchange_cataclysm2"):z("arpa_projects_stock_exchange_cataclysm1"):t.tech.gambling&&t.tech.gambling>=4?z("arpa_projects_stock_exchange_effect3"):z("arpa_projects_stock_exchange_effect2"):z("arpa_projects_stock_exchange_effect1"),cost:{Money:(e,t)=>Ie("stock_exchange",e,3e6,1.06,t),Plywood:(e,t)=>Ie("stock_exchange",e,25e3,1.06,t),Brick:(e,t)=>Ie("stock_exchange",e,2e4,1.06,t),Wrought_Iron:(e,t)=>Ie("stock_exchange",e,1e4,1.06,t)}},tp_depot:{title:z("galaxy_gateway_depot"),desc:z("arpa_projects_depot_desc"),reqs:{high_tech:6,storage:4},grant:"tp_depot",path:["truepath"],effect:()=>z(t.tech.isolation?"arpa_projects_depot_effect_iso":"arpa_projects_depot_effect",[5,50]),cost:{Money:(e,t)=>Ie("tp_depot",e,18e5,1.08,t),Stone:(e,t)=>Ie("tp_depot",e,75e4,1.08,t),Iron:(e,t)=>Ie("tp_depot",e,25e4,1.08,t),Alloy:(e,t)=>Ie("tp_depot",e,3e4,1.08,t)}},launch_facility:{id:"arpalaunch_facility",title:z("arpa_projects_launch_facility_title"),desc:z("arpa_projects_launch_facility_desc"),reqs:{high_tech:7},condition:()=>!t.race.cataclysm&&!t.race.lone_survivor,grant:"launch_facility",rank:1,queue_complete:()=>t.tech.space>=1?0:1,effect:()=>z("arpa_projects_launch_facility_effect1"),cost:{Money:e=>Ie("launch_facility",e,2e6,1.1),Knowledge:e=>Ie("launch_facility",e,5e5,1.1),Cement:e=>Ie("launch_facility",e,15e4,1.1),Oil:e=>Ie("launch_facility",e,2e4,1.1),Sheet_Metal:e=>Ie("launch_facility",e,15e3,1.1),Alloy:e=>Ie("launch_facility",e,25e3,1.1)}},monument:{title(e){if(e)return z("arpa_project_monument_title");switch(t.arpa.m_type){case"Obelisk":return z("arpa_project_monument_obelisk");case"Statue":return z("arpa_project_monument_statue");case"Sculpture":return z("arpa_project_monument_sculpture");case"Monolith":return z("arpa_project_monument_monolith");case"Pillar":return z("arpa_project_monument_pillar");case"Megalith":return z("arpa_project_monument_megalith")}},desc:z("arpa_projects_monument_desc"),reqs:{monument:1},grant:"monuments",effect(){let e=K("gaslighter",2);return z("arpa_projects_monument_effect1",[e?2-e:2])},cost:{Stone:(e,t)=>ze("Stone",e,t),Aluminium:(e,t)=>ze("Aluminium",e,t),Cement:(e,t)=>ze("Cement",e,t),Steel:(e,t)=>ze("Steel",e,t),Lumber:(e,t)=>ze("Lumber",e,t),Crystal:(e,t)=>ze("Crystal",e,t)}},railway:{title:()=>cn("fool",2022)?z("arpa_projects_lhc_title"):z("arpa_projects_railway_title"),desc:()=>cn("fool",2022)?z("arpa_projects_lhc_desc"):z("arpa_projects_railway_desc"),reqs:{high_tech:6,trade:3},grant:"railway",effect(e){if(cn("fool",2022)&&!e)return qe.lhc.effect(!0);let a=t.stats.achieve.banana&&t.stats.achieve.banana.l>=2?1:0,r=t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?3:2;return t.race.cataclysm||t.race.orbit_decayed?(a+=t.space.gps?Math.floor(t.space.gps.count/3):0,z("arpa_projects_railway_cataclysm1",[a,r,3,1])):(a+=t.city.storage_yard?Math.floor(t.city.storage_yard.count/6):0,z("arpa_projects_railway_effect1",[a,r,6,1]))},cost:{Money:(e,t)=>Ie("railway",e,25e5,1.08,t),Lumber:(e,t)=>Ie("railway",e,75e4,1.08,t),Iron:(e,t)=>Ie("railway",e,3e5,1.08,t),Steel:(e,t)=>Ie("railway",e,45e4,1.08,t)}},roid_eject:{title:()=>z("arpa_projects_roid_eject_title",[Pe()]),desc:()=>z(t.tech.roid_eject<=10?"arpa_projects_roid_eject_desc":"arpa_projects_roid_eject_desc2",[Pe()]),reqs:{blackhole:6,gateway:3},grant:"roid_eject",effect(){let e=0,a=0;return t.tech.roid_eject&&(e+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12),a=.225*(t.tech.roid_eject+1)*(1+(t.tech.roid_eject+1)/12)-e),`
                            ${z("arpa_projects_roid_eject_effect1")}
                            ${z("arpa_projects_roid_eject_effect2",[+e.toFixed(3),+a.toFixed(3),Pe()])}
                            `},cost:{Money:(e,t)=>Ie("roid_eject",e,1875e4,1.075,t),Deuterium:(e,t)=>Ie("roid_eject",e,375e3,1.075,t),Bolognium:(e,t)=>Ie("roid_eject",e,15e3,1.075,t)}},nexus:{title:z("arpa_projects_nexus_title"),desc:z("arpa_projects_nexus_desc"),reqs:{magic:5},grant:"nexus",effect:()=>t.tech.roguemagic&&t.tech.roguemagic>=7?`
                            ${z("arpa_projects_nexus_effect1",[5])}
                            ${z("witch_hunter_nexus",[8])}
                            `:z("arpa_projects_nexus_effect1",[5]),cost:{Money:(e,t)=>Ie("nexus",e,5e6,1.12,t),Crystal:(e,t)=>Ie("nexus",e,6e4,1.12,t),Iridium:(e,t)=>Ie("nexus",e,35e3,1.12,t)}},syphon:{title:z("arpa_syphon_title"),desc(){let e="";return e=t.tech.syphon&&t.tech.syphon>=0?`
                            ${z("arpa_syphon_desc")}
                            ${z("arpa_syphon_desc_warn2")}
                            `:`
                            ${z("arpa_syphon_desc")}
                            ${z("arpa_syphon_desc_warn1")}
                            `,t.race.witch_hunter&&(e+=`
                            ${z("witch_hunter_suspicion")}
                            `),e},reqs:{veil:2},grant:"syphon",effect(){let e=+(1/3*Is("magic")).toFixed(3);if(t.tech.syphon&&t.tech.syphon>=60){let t=Gs("vacuum"),a=z("resource_Plasmid_plural_name");return`
                            ${z("arpa_syphon_effect_main",[e])}
                            ${z("arpa_syphon_effect4")}
                            ${z("arpa_syphon_effect_reward",[t.plasmid,t.phage,t.dark,a,80])}
                            `}return t.tech.syphon&&t.tech.syphon>=40?`
                            ${z("arpa_syphon_effect_main",[e])}
                            ${z("arpa_syphon_effect3")}
                            `:t.tech.syphon&&t.tech.syphon>=20?`
                            ${z("arpa_syphon_effect_main",[e])}
                            ${z("arpa_syphon_effect2")}
                            `:`
                            ${z("arpa_syphon_effect_main",[e])}
                            ${z("arpa_syphon_effect1")}
                            `},cost:{Money:(e,t)=>Ie("syphon",e,75e5,1.025,t),Mana:(e,t)=>Ie("syphon",e,5e3,1.025,t),Crystal:(e,t)=>Ie("syphon",e,1e5,1.025,t),Infernite:(e,t)=>Ie("syphon",e,1e4,1.025,t)}}};function Pe(){return!t.tech.roid_eject||t.tech.roid_eject<=10?z("arpa_projects_roid_eject_asteroid"):t.tech.roid_eject<=25?z("arpa_projects_roid_eject_moon"):t.tech.roid_eject<=40?z("arpa_projects_roid_eject_dwarf"):t.tech.roid_eject<=60?z("arpa_projects_roid_eject_planet"):z("arpa_projects_roid_eject_remnant")}const je={genetic_memory:{id:"genes-genetic_memory",title:z("arpa_genepool_genetic_memory_title"),desc:z("arpa_genepool_genetic_memory_desc"),reqs:{},grant:["creep",1],cost:{Plasmid:()=>25},action:()=>!!Me("genetic_memory")},animus:{id:"genes-animus",title:z("arpa_genepool_animus_title"),desc:z("arpa_genepool_animus_desc"),reqs:{creep:1},grant:["creep",2],cost:{Plasmid:()=>75},action:()=>!!Me("animus")},divine_remembrance:{id:"genes-divine_remembrance",title:z("arpa_genepool_divine_remembrance_title"),desc:z("arpa_genepool_divine_remembrance_desc"),reqs:{creep:2},grant:["creep",3],cost:{Plasmid:()=>225},action:()=>!!Me("divine_remembrance")},divine_proportion:{id:"genes-divine_proportion",title:z("arpa_genepool_divine_proportion_title"),desc:z("arpa_genepool_divine_proportion_desc"),reqs:{creep:3},grant:["creep",4],cost:{Plasmid:()=>618},action:()=>!!Me("divine_proportion")},genetic_repository:{id:"genes-genetic_repository",title:z("arpa_genepool_genetic_repository_title"),desc:z("arpa_genepool_genetic_repository_desc"),reqs:{creep:4},grant:["creep",5],cost:{Plasmid:()=>999},action:()=>!!Me("genetic_repository")},spatial_reasoning:{id:"genes-spatial_reasoning",title:z("arpa_genepool_spatial_reasoning_title"),desc:z("arpa_genepool_spatial_reasoning_desc"),reqs:{},grant:["store",1],cost:{Plasmid:()=>50},action:()=>!!Me("spatial_reasoning")},spatial_superiority:{id:"genes-spatial_superiority",title:z("arpa_genepool_spatial_superiority_title"),desc:z("arpa_genepool_spatial_superiority_desc"),reqs:{store:1},grant:["store",2],cost:{Plasmid:()=>125},action:()=>!!Me("spatial_superiority")},spatial_supremacy:{id:"genes-spatial_supremacy",title:z("arpa_genepool_spatial_supremacy_title"),desc:z("arpa_genepool_spatial_supremacy_desc"),reqs:{store:2},grant:["store",3],cost:{Plasmid:()=>325},action:()=>!!Me("spatial_supremacy")},dimensional_warping:{id:"genes-dimensional_warping",title:z("arpa_genepool_dimensional_warping_title"),desc:z("arpa_genepool_dimensional_warping_desc"),reqs:{store:3},grant:["store",4],cost:{Plasmid:()=>500},action:()=>!!Me("dimensional_warping")},enhanced_muscle_fiber:{id:"genes-enhanced_muscle_fiber",title:z("arpa_genepool_enhanced_muscle_fiber_title"),desc:z("arpa_genepool_enhanced_muscle_fiber_desc"),reqs:{},grant:["enhance",1],cost:{Plasmid:()=>25},action:()=>!!Me("enhanced_muscle_fiber")},morphogenesis:{id:"genes-morphogenesis",title:z("arpa_genepool_morphogenesis_title"),desc:z("arpa_genepool_morphogenesis_desc"),reqs:{},grant:["evolve",1],cost:{Plasmid:()=>10},action:()=>!!Me("morphogenesis")},recombination:{id:"genes-recombination",title:z("arpa_genepool_recombination_title"),desc:z("arpa_genepool_recombination_desc"),reqs:{evolve:1},grant:["evolve",2],cost:{Plasmid:()=>35},action:()=>!!Me("recombination")},homologous_recombination:{id:"genes-homologous_recombination",title:z("arpa_genepool_homologous_recombination_title"),desc:z("arpa_genepool_homologous_recombination_desc"),reqs:{evolve:2},grant:["evolve",3],cost:{Plasmid:()=>70},action:()=>!!Me("homologous_recombination")},genetic_reshuffling:{id:"genes-genetic_reshuffling",title:z("arpa_genepool_genetic_reshuffling_title"),desc:z("arpa_genepool_genetic_reshuffling_desc"),reqs:{evolve:3},grant:["evolve",4],cost:{Plasmid:()=>175},action:()=>!!Me("genetic_reshuffling")},recombinant_dna:{id:"genes-recombinant_dna",title:z("arpa_genepool_recombinant_dna_title"),desc:z("arpa_genepool_recombinant_dna_desc"),reqs:{evolve:4},grant:["evolve",5],cost:{Plasmid:()=>440},action:()=>!!Me("recombinant_dna")},chimeric_dna:{id:"genes-chimeric_dna",title:z("arpa_genepool_chimeric_dna_title"),desc:z("arpa_genepool_chimeric_dna_desc"),reqs:{evolve:5},grant:["evolve",6],cost:{Plasmid:()=>1100},action:()=>!!Me("chimeric_dna")},molecular_cloning:{id:"genes-molecular_cloning",title:z("arpa_genepool_molecular_cloning_title"),desc:z("arpa_genepool_molecular_cloning_desc"),reqs:{evolve:6},grant:["evolve",7],cost:{Plasmid:()=>2750},action:()=>!!Me("molecular_cloning")},transgenes:{id:"genes-transgenes",title:z("arpa_genepool_transgenes_title"),desc:z("arpa_genepool_transgenes_desc"),reqs:{evolve:7},grant:["evolve",8],cost:{Plasmid:()=>6875},action:()=>!!Me("transgenes")},synthesis:{id:"genes-synthesis",title:z("arpa_genepool_synthesis_title"),desc:z("arpa_genepool_synthesis_desc",[2,10]),reqs:{evolve:1},grant:["synthesis",1],cost:{Plasmid:()=>25},action:()=>!!Me("synthesis")},karyokinesis:{id:"genes-karyokinesis",title:z("arpa_genepool_karyokinesis_title"),desc:z("arpa_genepool_synthesis_desc",[3,25]),reqs:{synthesis:1},grant:["synthesis",2],cost:{Plasmid:()=>40},action:()=>!!Me("karyokinesis")},cytokinesis:{id:"genes-cytokinesis",title:z("arpa_genepool_cytokinesis_title"),desc:z("arpa_genepool_synthesis_desc",[4,50]),reqs:{synthesis:2},grant:["synthesis",3],cost:{Plasmid:()=>55},action:()=>!!Me("cytokinesis")},mitosis:{id:"genes-mitosis",title:z("arpa_genepool_mitosis_title"),desc:z("arpa_genepool_mitosis_desc",[3]),reqs:{synthesis:3,evolve:2},grant:["plasma",1],cost:{Plasmid:()=>90},action:()=>!!Me("mitosis")},metaphase:{id:"genes-metaphase",title:z("arpa_genepool_metaphase_title"),desc:z("arpa_genepool_mitosis_desc",[5]),reqs:{plasma:1},grant:["plasma",2],cost:{Plasmid:()=>165},action:()=>!!Me("mitosis")},mutation:{id:"genes-mutation",title:z("arpa_genepool_mutation_title"),desc:z("arpa_genepool_mutation_desc"),reqs:{synthesis:3,creep:5},grant:["mutation",1],cost:{Plasmid:()=>1250},action:()=>!!Me("mutation")&&(t.genes.mutation=1,Ee(),!0)},transformation:{id:"genes-transformation",title:z("arpa_genepool_transformation_title"),desc:z("arpa_genepool_transformation_desc"),reqs:{mutation:1},grant:["mutation",2],cost:{Plasmid:()=>1500},action:()=>!!Me("transformation")&&(t.genes.mutation=2,Ee(),!0)},metamorphosis:{id:"genes-metamorphosis",title:z("arpa_genepool_metamorphosis_title"),desc:z("arpa_genepool_metamorphosis_desc"),reqs:{mutation:2},grant:["mutation",3],cost:{Plasmid:()=>1750},action:()=>!!Me("metamorphosis")&&(t.genes.mutation=3,Ee(),!0)},replication:{id:"genes-replication",title:z("arpa_genepool_replication_title"),desc:z("arpa_genepool_replication_desc"),reqs:{evolve:1},grant:["birth",1],cost:{Plasmid:()=>65},action:()=>!!Me("replication")},artificer:{id:"genes-artificer",title:z("arpa_genepool_artificer_title"),desc:z("arpa_genepool_artificer_desc"),reqs:{evolve:1},grant:["crafty",1],cost:{Plasmid:()=>45},action:()=>!!Me("artificer")},detail_oriented:{id:"genes-detail_oriented",title:z("arpa_genepool_detail_oriented_title"),desc:z("arpa_genepool_crafting_desc",["50"]),reqs:{crafty:1},grant:["crafty",2],cost:{Plasmid:()=>90},action:()=>!!Me("detail_oriented")},rigorous:{id:"genes-rigorous",title:z("arpa_genepool_rigorous_title"),desc:z("arpa_genepool_crafting_desc",["100"]),reqs:{crafty:2},grant:["crafty",3],cost:{Plasmid:()=>135},action:()=>!!Me("rigorous")},geographer:{id:"genes-geographer",title:z("arpa_genepool_geographer_title"),desc:z("arpa_genepool_geographer_desc"),reqs:{store:1},grant:["queue",1],cost:{Plasmid:()=>75},action:()=>!!Me("geographer")},architect:{id:"genes-architect",title:z("arpa_genepool_architect_title"),desc:z("arpa_genepool_architect_desc"),reqs:{queue:1},grant:["queue",2],cost:{Plasmid:()=>160},action:()=>!!Me("architect"),post(){vs(),fs()}},precognition:{id:"genes-precognition",title:z("arpa_genepool_precognition_title"),desc:z("arpa_genepool_precognition_desc"),reqs:{queue:2},grant:["queue",3],condition:()=>t.stats.aiappoc>0,cost:{Plasmid:()=>3500,Phage:()=>100,AICore:()=>1},action:()=>!!Me("precognition")},governance:{id:"genes-governance",title:z("arpa_genepool_governance_title"),desc:z("arpa_genepool_governance_desc"),reqs:{queue:2},grant:["governor",1],cost:{Plasmid:()=>300,Phage:()=>25},action:()=>!!Me("governance")},civil_service:{id:"genes-civil_service",title:z("arpa_genepool_civil_service_title"),desc:z("arpa_genepool_civil_service_desc"),reqs:{governor:1},grant:["governor",2],cost:{Plasmid:()=>1e3,Harmony:()=>1},action:()=>!!Me("civil_service"),post(){if(t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks"))for(let e=0;e<6;e++)t.race.governor.tasks.hasOwnProperty(`t${e}`)||(t.race.governor.tasks[`t${e}`]="none");L()}},hardened_genes:{id:"genes-hardened_genes",title:z("arpa_genepool_hardened_genes_title"),desc:z("arpa_genepool_hardened_genes_desc"),reqs:{},grant:["challenge",1],cost:{Plasmid:()=>5},action:()=>!!Me("hardened_genes")},unlocked:{id:"genes-unlocked",title:z("arpa_genepool_unlocked_title"),desc:z("arpa_genepool_unlocked_desc"),reqs:{challenge:1},grant:["challenge",2],cost:{Plasmid:()=>50},action:()=>!!Me("unlocked"),post(){Ts(!0)}},universal:{id:"genes-universal",title:z("arpa_genepool_universal_title"),desc:z("arpa_genepool_universal_desc"),reqs:{challenge:2},grant:["challenge",3],condition:()=>"standard"!==t.race.universe,cost:{Plasmid:()=>400},action:()=>!!Me("universal"),post(){Ts(!0)}},standard:{id:"genes-standard",title:z("arpa_genepool_standard_title"),desc:z("arpa_genepool_standard_desc"),reqs:{challenge:3},grant:["challenge",4],condition:()=>"standard"!==t.race.universe,cost:{Plasmid:()=>2500},action:()=>!!Me("standard"),post(){Ts(!0)}},mastered:{id:"genes-mastered",title:z("arpa_genepool_mastered_title"),desc:z("arpa_genepool_mastered_desc"),reqs:{challenge:4},grant:["challenge",5],cost:{Plasmid:()=>4e3},action:()=>!!Me("mastered")},negotiator:{id:"genes-negotiator",title:z("arpa_genepool_negotiator_title"),desc:z("arpa_genepool_negotiator_desc"),reqs:{challenge:2},grant:["trader",1],cost:{Plasmid:()=>750},action:()=>!!Me("negotiator")&&(t.genes.trader=1,Ge(),!0)},ancients:{id:"genes-ancients",title:z("arpa_genepool_ancients_title"),desc:z("arpa_genepool_ancients_desc"),reqs:{evolve:2},condition:()=>!!t.genes.old_gods,grant:["ancients",1],cost:{Plasmid:()=>120},action:()=>!!Me("ancients")&&(t.genes.ancients=1,Qr(),!0)},faith:{id:"genes-faith",title:z("arpa_genepool_faith_title"),desc:z("arpa_genepool_faith_desc"),reqs:{ancients:1},grant:["ancients",2],cost:{Plasmid:()=>300},action:()=>!!Me("faith")&&(t.civic.priest.display=!0,!0)},devotion:{id:"genes-devotion",title:z("arpa_genepool_devotion_title"),desc:z("arpa_genepool_devotion_desc"),reqs:{ancients:2},grant:["ancients",3],cost:{Plasmid:()=>600},action:()=>!!Me("devotion")},acolyte:{id:"genes-acolyte",title:z("arpa_genepool_acolyte_title"),desc:z("arpa_genepool_acolyte_desc"),reqs:{ancients:3},grant:["ancients",4],cost:{Plasmid:()=>1e3},action:()=>!!Me("acolyte")},conviction:{id:"genes-conviction",title:z("arpa_genepool_conviction_title"),desc:z("arpa_genepool_conviction_desc"),reqs:{ancients:4},grant:["ancients",5],cost:{Plasmid:()=>1500},action:()=>!!Me("conviction")},transcendence:{id:"genes-transcendence",title:z("arpa_genepool_transcendence_title"),desc:z("arpa_genepool_transcendence_desc"),reqs:{ancients:1,mutation:3},grant:["transcendence",1],cost:{Plasmid:()=>3e3},action:()=>!!Me("transcendence")&&(t.genes.transcendence=1,Qr(),!0)},bleeding_effect:{id:"genes-bleeding_effect",title:z("arpa_genepool_bleeding_effect_title"),desc:z("arpa_genepool_bleeding_effect_desc",[2.5]),reqs:{creep:2},grant:["bleed",1],condition:()=>"antimatter"===t.race.universe,cost:{Plasmid:()=>100},action:()=>!!Me("bleeding_effect")},synchronicity:{id:"genes-synchronicity",title:z("arpa_genepool_synchronicity_title"),desc:z("arpa_genepool_synchronicity_desc",[25]),reqs:{bleed:1},grant:["bleed",2],cost:{Plasmid:()=>500},action:()=>!!Me("synchronicity")},astral_awareness:{id:"genes-astral_awareness",title:z("arpa_genepool_astral_awareness_title"),desc:z("arpa_genepool_astral_awareness_desc"),reqs:{bleed:2},grant:["bleed",3],cost:{Plasmid:()=>1e3},action:()=>!!Me("astral_awareness")},blood_remembrance:{id:"genes-blood_remembrance",title:z("arpa_genepool_blood_remembrance_title"),desc:z("arpa_genepool_blood_remembrance_desc"),reqs:{},grant:["blood",1],condition:()=>t.prestige.Blood_Stone.count>=1,cost:{Plasmid:()=>1e3,Phage:()=>10},action:()=>!!Me("blood_remembrance")},blood_sacrifice:{id:"genes-blood_sacrifice",title:z("arpa_genepool_blood_sacrifice_title"),desc:z("arpa_genepool_blood_sacrifice_desc"),reqs:{blood:1},grant:["blood",2],cost:{Plasmid:()=>3e3,Phage:()=>100,Artifact:()=>1},action:()=>!!Me("blood_sacrifice")},essence_absorber:{id:"genes-essence_absorber",title:z("arpa_genepool_essence_absorber_title"),desc:z("arpa_genepool_essence_absorber_desc"),reqs:{blood:2},grant:["blood",3],cost:{Plasmid:()=>7500,Phage:()=>250,Artifact:()=>1},action:()=>!!Me("essence_absorber"),post(){De()}}},Oe={purify:{id:"blood-purify",title:z("arpa_blood_purify_title"),desc:z("arpa_blood_purify_desc"),reqs:{},grant:["spire",1],cost:{Blood_Stone:()=>10},action(){return!!Se($(this)[0].cost)}},chum:{id:"blood-chum",title:z("arpa_blood_chum_title"),desc:z("arpa_blood_chum_desc"),reqs:{spire:1},grant:["spire",2],cost:{Blood_Stone:()=>25},action(){return!!Se($(this)[0].cost)}},lust:{id:"blood-lust",title:z("arpa_blood_lust_title"),desc:z("arpa_blood_lust_desc"),reqs:{},grant:["lust","*"],cost:{Blood_Stone:e=>15*((e||0)+(t.blood.lust||0))+15,Artifact:e=>((e||0)+(t.blood.lust||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},illuminate:{id:"blood-illuminate",title:z("arpa_blood_illuminate_title"),desc:z("arpa_blood_illuminate_desc"),reqs:{},grant:["illuminate","*"],cost:{Blood_Stone:e=>12*((e||0)+(t.blood.illuminate||0))+12,Artifact:e=>((e||0)+(t.blood.illuminate||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},greed:{id:"blood-greed",title:z("arpa_blood_greed_title"),desc:z("arpa_blood_greed_desc"),reqs:{},grant:["greed","*"],cost:{Blood_Stone:e=>16*((e||0)+(t.blood.greed||0))+16,Artifact:e=>((e||0)+(t.blood.greed||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},hoarder:{id:"blood-hoarder",title:z("arpa_blood_hoarder_title"),desc:z("arpa_blood_hoarder_desc"),reqs:{},grant:["hoarder","*"],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:e=>14*((e||0)+(t.blood.hoarder||0))+14,Artifact:e=>((e||0)+(t.blood.hoarder||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},artisan:{id:"blood-artisan",title:z("arpa_blood_artisan_title"),desc:z("arpa_blood_artisan_desc"),reqs:{},grant:["artisan","*"],cost:{Blood_Stone:e=>8*((e||0)+(t.blood.artisan||0))+8,Artifact:e=>((e||0)+(t.blood.artisan||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},attract:{id:"blood-attract",title:z("arpa_blood_attract_title"),desc:z("arpa_blood_attract_desc"),reqs:{},grant:["attract","*"],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:e=>4*((e||0)+(t.blood.attract||0))+4,Artifact:e=>((e||0)+(t.blood.attract||0))%5==0?1:0},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},wrath:{id:"blood-wrath",title:z("arpa_blood_wrath_title"),desc:z("arpa_blood_wrath_desc"),reqs:{},grant:["wrath","*"],cost:{Blood_Stone:e=>2*((e||0)+(t.blood.wrath||0))+2,Artifact:()=>1},effect:()=>`${z("arpa_blood_repeat")}`,action(){return!!Se($(this)[0].cost)}},prepared:{id:"blood-prepared",title:z("arpa_blood_prepared_title"),desc:z("arpa_blood_prepared_desc"),reqs:{},grant:["prepared",1],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>50},action(){return!!Se($(this)[0].cost)},post(){ya()}},compact:{id:"blood-compact",title:z("arpa_blood_compact_title"),desc:z("arpa_blood_compact_desc"),reqs:{prepared:1},grant:["prepared",2],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>75},action(){return!!Se($(this)[0].cost)}},infernal:{id:"blood-infernal",title:z("arpa_blood_infernal_title"),desc:z("arpa_blood_infernal_desc"),reqs:{prepared:2},grant:["prepared",3],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>125,Artifact:()=>1},action(){return!!Se($(this)[0].cost)}},unbound:{id:"blood-unbound",title:z("arpa_blood_unbound_title"),desc:z("arpa_blood_unbound_desc"),reqs:{},grant:["unbound",1],cost:{Blood_Stone:()=>50},action(){return!!Se($(this)[0].cost)}},unbound_resistance:{id:"blood-unbound_resistance",title:z("arpa_blood_unbound_resistance_title"),desc:z("arpa_blood_unbound_resistance_desc"),reqs:{unbound:1},grant:["unbound",2],cost:{Blood_Stone:()=>100},action(){return!!Se($(this)[0].cost)}},shadow_war:{id:"blood-shadow_war",title:z("arpa_blood_shadow_war_title"),desc:z("arpa_blood_shadow_war_desc"),reqs:{unbound:2},grant:["unbound",3],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>250,Artifact:()=>2},action(){return!!Se($(this)[0].cost)}},unbound_immunity:{id:"blood-unbound_immunity",title:z("arpa_blood_unbound_immunity_title"),desc:z("arpa_blood_unbound_immunity_desc"),reqs:{unbound:3},grant:["unbound",4],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>500},action(){return!!Se($(this)[0].cost)}},blood_aware:{id:"blood-blood_aware",title:z("arpa_blood_blood_aware_title"),desc:z("arpa_blood_blood_aware_desc"),reqs:{},grant:["aware",1],condition:()=>!!(t.genes.blood&&t.genes.blood>=3),cost:{Blood_Stone:()=>10},action(){return!!Se($(this)[0].cost)}}};function Me(e){let a=!0,r=je[e].cost;return Object.keys(r).forEach((function(e){let i=e;"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].countNumber(t.resource[r].amount))return a=!1,!1})),a}(e=Ae(e))&&(Object.keys(e).forEach((function(a){t.resource[a].amount-=e[a]()/100})),!0)}function Ae(e,a,r){return e=function(e,a,r){if(r&&r.creative||!r&&t.race.creative){var i={};let t=ts("human");return Object.keys(e).forEach((function(s){i[s]=function(){let i=e[s](a,r);return i*=1-Ei.creative.vars()[1]/100,t>0&&(i*=1-Ei.creative.vars(1)[1]/100*t),i}})),i}return e}(e,a,r),Ns({cost:e},a,r)}function Ie(e,a,r,i,s){var n=t.arpa[e]?t.arpa[e].rank:0;return(s&&s.creative||!s&&t.race.creative)&&"syphon"!==e&&(i-=Ei.creative.vars()[0]),a&&(n+=a),Math.round(i**n*r)}function Te(){if(t.tech.high_tech&&t.tech.high_tech>=6){let e=$("#arpaPhysics");Ss(e),Object.keys(qe).forEach((function(a){!function(e,a){if(function(e){if(qe[e].condition&&!qe[e].condition())return!1;let a=t.race.truepath?"truepath":"standard";if(qe[e].hasOwnProperty("path")&&!qe[e].path.includes(a))return!1;var r=!0;return Object.keys(qe[e].reqs).forEach((function(a){(!t.tech[a]||t.tech[a]=qe[a].rank)return;let r=$(`
                            `);e.append(r);let i="string"==typeof qe[a].title?qe[a].title:qe[a].title(),s=$(`
                            ${i}{{ rank | level }}
                            `);r.append(s);let n=$('
                            {{ complete }}%
                            ');s.append(n);let c=$('
                            ');r.append(c),c.append($(``)),c.append($(``)),c.append($(``)),c.append($(``)),c.append($(``)),Cs({el:`#arpa${a}`,data:t.arpa[a],methods:{queue(e){if(t.tech.queue){let r=y();for(let i=0;i0))break;if("merge_never"!==t.settings.q_merge&&t.queue.queue.length>0&&t.queue.queue[t.queue.queue.length-1].id===r)t.queue.queue[t.queue.queue.length-1].q++;else{let a="string"==typeof qe[e].title?qe[e].title:qe[e].title();t.queue.queue.push({id:r,action:"arpa",type:e,label:a,cna:!1,time:0,q:1,qs:1,t_max:0})}ys()}}},build(e,a){!function(e,a,r,i){let s=!1;100===a&&(a=100-t.arpa[e].complete);for(let r=0;r=100&&(t.arpa[e].rank++,t.arpa[e].complete=0,t.tech[qe[e].grant]=t.arpa[e].rank,s=!0,"monument"===e&&(t.arpa.m_type=Ce(),$(`#arpa${e} .head .desc`).html(qe[e].title()),ui(!1,["arpamonument"])),"roid_eject"===e&&($(`#arpa${e} .head .desc`).html(qe[e].title()),ui(!1,["arparoid_eject"])),"launch_facility"===e&&(t.settings.showSpace=!0,t.tech.space=1,_s("popArpalaunch_facility"),[1,10,25,100].forEach((function(e){_s(`popArpalaunch_facility${e}`)})),ms(["arpalaunch_facility"]),Te(),Lt(),hs(z("arpa_projects_launch_facility_msg"),"info",!1,["progress"])),t.race.inflation&&(t.race.inflation+=10),Qr()));{let t=[1,10,25,100],a=$("#popper"),r=a.data("id");for(let i=0;iq(qe[a].desc),srLevel:()=>q(qe[a].effect()),arpaProjectSRCosts(e,a){let r="100"===e?100-t.arpa[a].complete:e;var i=`Construct ${r}%. Costs:`,s=Ae(qe[a].cost);return Object.keys(s).forEach((function(e){var a=+(s[e]()*(r/100)).toFixed(0);if(a>0){var n="Money"===e?"$":t.resource[e].name+": ",c=t.resource[e].amount>=a?"":` ${z("insufficient")} ${t.resource[e].name}.`;i+=` ${n} ${x(a,2)}.${c}`}})),i}},filters:{remain:e=>100-e,level:e=>z("arpa_level",[e])}}),ls(`popArpa${a}`,(function(){return qe[a].desc}),{elm:`#arpa${a} .head .desc`,classes:"has-background-light has-text-dark"}),ls(`popArpa${a}`,(function(){return qe[a].effect()}),{elm:`#arpa${a} .head .rank`,classes:"has-background-light has-text-dark"});let o=[1,10,25,100];for(let e=0;e1){let a=$('
                            ');e.append(a);let r=t.tech.genetics>2?z("arpa_gene_mutation"):z("arpa_sequence_genome");t.race.artifical&&(r=t.tech.genetics>2?z("arpa_code_modification"):z("arpa_decompile_source"));let i=$(`
                            ${r} - ${z("arpa_to_complete")}
                            `);a.append(i);let s=$(`{{ progress }}%`);a.append(s);let n=t.tech.genetics>2?z("arpa_mutate"):z("arpa_sequence");t.race.artifical&&(n=t.tech.genetics>2?z("arpa_modify"):z("arpa_decompile"));let c=$(``);if(a.append(c),t.tech.genetics>=5){let e=$(``);a.append(e)}if(t.tech.genetics>=6){let e=$(``);a.append(e)}if(t.tech.genetics>=7){let e=$(``);a.append(e)}t.arpa.sequence.on&&$("#arpaSequence button.seq").addClass("has-text-success"),t.arpa.sequence.boost&&$("#arpaSequence button.boost").addClass("has-text-success"),t.arpa.sequence.auto&&$("#arpaSequence button.auto").addClass("has-text-success"),Cs({el:"#arpaSequence",data:t.arpa.sequence,methods:{toggle(){t.arpa.sequence.on?(t.arpa.sequence.on=!1,$("#arpaSequence button.seq").removeClass("has-text-success")):(t.arpa.sequence.on=!0,$("#arpaSequence button.seq").addClass("has-text-success"))},booster(){t.arpa.sequence.boost?(t.arpa.sequence.boost=!1,$("#arpaSequence button.boost").removeClass("has-text-success")):(t.arpa.sequence.boost=!0,$("#arpaSequence button.boost").addClass("has-text-success"))},boostLabel:e=>z(t.race.artifical?"arpa_boost_artifical_label":"arpa_boost_label")+(e?t.arpa.sequence.boost?z("city_on"):z("city_off"):""),novo(){let e=y();for(let a=0;a=2e5;a++)t.resource.Knowledge.amount-=2e5,t.resource.Genes.amount++},novoLabel:()=>z(t.race.artifical?"arpa_novo_artifical_label":"arpa_novo_label",["200k"]),auto_seq(){t.arpa.sequence.auto?(t.arpa.sequence.auto=!1,$("#arpaSequence button.auto").removeClass("has-text-success")):(t.arpa.sequence.auto=!0,$("#arpaSequence button.auto").addClass("has-text-success"))},autoLabel:e=>z(t.race.artifical?"arpa_auto_compile_label":"arpa_auto_seq_label")+(e?t.arpa.sequence.boost?z("city_on"):z("city_off"):"")},filters:{timer(e){if(t.arpa.sequence.on&&t.arpa.sequence.labs>0){const a=e/(t.settings.gameSpeed*t.arpa.sequence.labs);return t.arpa.sequence.boost?zs(a/2):zs(a)}{let e=Qs(14,12);return e.length>0?e:z("time_never")}}}}),ls("popArpaSeq",(function(){return t.tech.genetics>2?t.race.artifical?z("arpa_modify_desc"):z("arpa_mutate_desc"):t.race.artifical?z("arpa_decompile_desc"):z("arpa_sequence_desc")}),{elm:"#arpaSequence .seqlbl",classes:"has-background-light has-text-dark"})}if(t.tech.genetics>2){let e=$('
                            ');$("#arpaGenetics").append(e);let a=$('
                            ');e.append(a),t.tech.decay&&t.tech.decay>=2&&(t.settings.mtorder.includes("fortify")||t.settings.mtorder.push("fortify")),Object.keys(t.race).forEach((function(e){Ei[e]&&"minor"===Ei[e].type&&(t.settings.mtorder.includes(e)||t.settings.mtorder.push(e))})),t.genes.challenge&&t.genes.challenge>=5&&(t.settings.mtorder.includes("mastery")||t.settings.mtorder.push("mastery"));let r=!1,i=[];t.settings.mtorder.forEach((function(e){(Ei[e]&&"minor"===Ei[e].type||"mastery"===e||"fortify"===e)&&("fortify"!==e||t.tech.decay&&t.tech.decay>=2)&&(!["promiscuous","content","resilient","industrious","tactical","fibroblast"].includes(e)&&t.race.lone_survivor||!t.race.lone_survivor)&&(r=!0,function(e,a){let r=$(`
                            `),i=$(`${t.resource.Genes.name} (${t.race.minor[a]||0})`);if(r.append(i),t.prestige.Phage.count>0){let e=$(`${z("resource_Phage_name")} (${t.genes.minor[a]||0})`);r.append(e)}let s=t.race[a]>1?`(${t.race[a]}) `:"";r.append(`${s}${as("name",a)}`),e.append(r)}(a,e),i.push(e))})),e.append(`
                            ${z("arpa_race_genetic_traids",[nn("name")])}
                            `);let s=as("name"),n=[],c=[],o=$('
                            ');e.append(o);let l=sn(t.race);cn("fool",2023)&&(l.hooved=1),Object.keys(l).forEach((function(e){if(Ei[e]&&"minor"!==Ei[e].type&&"special"!==Ei[e].type&&"evil"!==e&&"soul_eater"!==e&&"artifical"!==e){let a=!1;if(t.race.ss_traits&&t.race.ss_traits.includes(e)||t.race.iTraits&&t.race.iTraits.hasOwnProperty(e)?a=!0:("sludge"!==t.race.species||"ooze"!==e&&!t.race.modified)&&t.race.hasOwnProperty(e)||(a=!0),!a&&("major"===Ei[e].type&&t.genes.mutation||"genus"===Ei[e].type&&t.genes.mutation&&t.genes.mutation>=2)){let t=$('
                            '),a=$(`${z("arpa_remove_button")}`);n.push(e),t.append(a),t.append($(`${s[e]?s[e]:Ei[e].name} (${z("arpa_genepool_rank",[l[e]])})`)),o.append(t)}else c.push(e),o.append(`
                            ${s[e]?s[e]:Ei[e].name} (${z("arpa_genepool_rank",[l[e]])})
                            `)}}));let _=[];if(t.genes.mutation&&t.genes.mutation>=3&&("sludge"!==t.race.species||!t.race.modified)){e.append(`
                            ${z("arpa_race_genetic_gain")}
                            `);let a=["dumb","smart"];Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&"custom"!==e&&Ki[e].type===Ki[t.race.species].type&&Object.keys(Ki[e].traits).forEach((function(e){if(!t.race[e]&&"soul_eater"!==e){let r=a.indexOf(e);if(-1===r)_.push(e);else{let i=!1;switch(r%2){case 0:t.race[a[r+1]]&&(i=!0);break;case 1:t.race[a[r-1]]&&(i=!0)}i||_.push(e)}}}))}));let r=$('
                            ');e.append(r);for(let e=0;e<_.length;e++){let t=_[e],a=$('
                            '),i=$(`${z("arpa_gain_button")}`);a.append(i),a.append($(`${s[t]?s[t]:Ei[t].name}`)),r.append(a)}}r&&e.prepend(`
                            ${z("arpa_race_genetic_minor_traits",[nn("name")])}
                            `);let d=function(e){let a=5*Ei[e].val;return"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1),z("arpa_remove",[as("name",e),a,"antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name")])},p=function(e){let a=5*Ei[e].val;return"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1),z("arpa_gain",[as("name",e),a,"antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name")])},u=function(e){let a=Ys(t.race.minor[e]?t.race.minor[e]+4:4);return"mastery"===e&&(a*=5),z("arpa_gene_buy",[as("name",e),x(a),t.resource.Genes.name])},h=function(e){let a=Ys(t.genes.minor[e]?t.genes.minor[e]+4:4);return"mastery"===e&&(a*=2),z("arpa_phage_buy",[as("name",e),x(a),z("resource_Phage_name")])};Cs({el:"#geneticBreakdown",data:{genes:t.genes,race:t.race},methods:{gene(e){let a=0,r=y(),i=!0,s=!1;for(;a=r?(t.resource.Genes.amount-=r,t.race.minor[e]?t.race.minor[e]++:t.race.minor[e]=1,t.race[e]?t.race[e]++:t.race[e]=1,s=!0):i=!1,a++}s&&("mastery"===e&&Ts(!0),Ee(),"persuasive"===e&&Ge())},phage(e){let a=0,r=y(),i=!0,s=!1;for(;a=r?(t.prestige.Phage.count-=r,t.genes.minor[e]?t.genes.minor[e]++:t.genes.minor[e]=1,t.race[e]?t.race[e]++:t.race[e]=1,s=!0):i=!1,a++}s&&("mastery"===e&&Ts(!0),Ee(),"persuasive"===e&&Ge())},purge(e){if("sludge"===t.race.species&&(t.race.modified||"ooze"===e))return;let a=5*Ei[e].val;"custom"!==t.race.species&&"sludge"!==t.race.species||(a*=10),a<0&&(a*=-1);let r="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";if(t.prestige[r].count>=a){t.prestige[r].count-=a;let i=t.race[e];delete t.race[e],t.race.modified?t.race.modified++:t.race.modified=1,Zi(e,i),Ee(),Qr(),Wr();let s=0;Object.keys(t.race).forEach((function(e){!Ei[e]||"major"!=Ei[e].type&&"genus"!=Ei[e].type||"evil"===e||s++})),0===s&&Pn("blank_slate")}},gain(e){if("sludge"===t.race.species&&t.race.modified)return;let a=5*Ei[e].val;"sludge"===t.race.species&&(a*=2),"custom"===t.race.species&&(a*=10),a<0&&(a*=-1);let r="antimatter"===t.race.universe?"AntiPlasmid":"Plasmid";t.prestige[r].count>=a&&(t.prestige[r].count-=a,t.race[e]=1,t.race.modified?t.race.modified++:t.race.modified=1,Ji(e),Ee(),Qr(),Wr())},geneCost:e=>u(e),phageCost:e=>h(e),traitEffect:e=>z(`trait_${e}_effect`),removeCost:e=>d(e),addCost:e=>p(e),genePurchasable(e){let a=Ys(t.race.minor[e]?t.race.minor[e]+4:4);return"mastery"===e&&(a*=5),t.resource.Genes.amount>=a},phagePurchasable(e){let a=Ys(t.genes.minor[e]?t.genes.minor[e]+4:4);return"mastery"===e&&(a*=2),t.prestige.Phage.count>=a}}}),i.forEach((function(e){ls(`popGenetrait${e}`,(function(){return u(e)}),{elm:`#geneticBreakdown .t-${e} .gbuy`,classes:"has-background-light has-text-dark"}),t.prestige.Phage.count>0&&ls(`popGenetrait${e}`,(function(){return h(e)}),{elm:`#geneticBreakdown .t-${e} .pbuy`,classes:"has-background-light has-text-dark"}),ls(`popGenetrait${e}`,(function(){return t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0?`
                            ${as("desc",e)}
                            ${z(`trait_${e}_effect`)}
                            `:as("desc",e)}),{elm:`#geneticBreakdown .t-${e} .name`,classes:"has-background-light has-text-dark"})})),n.forEach((function(e){ls(`popRemoveBkdwn${e}`,(function(){return d(e)}),{elm:`#geneticBreakdown .remove${e}`,classes:"has-background-light has-text-dark"});let a=`raceTrait${e}`,r=$("
                            ");vn(r,e,{trank:t.race[e]}),ls(a,r,{wide:!0,classes:"w30"})})),c.forEach((function(e){let a=`raceTrait${e}`,r=$("
                            ");vn(r,e,{trank:t.race[e]}),ls(a,r,{elm:`#geneticBreakdown .trait${e}`,wide:!0,classes:"w30"})})),_.forEach((function(e){ls(`popAddBkdwn${e}`,(function(){return p(e)}),{elm:`#geneticBreakdown .add${e}`,classes:"has-background-light has-text-dark"});let a=`raceTrait${e}`,r=$("
                            ");vn(r,e,{trank:t.race[e]}),ls(a,r,{wide:!0,classes:"w30"})})),function(){let e=$("#geneticMinor")[0];e&&Sortable.create(e,{onEnd(e){let a=t.settings.mtorder;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.settings.mtorder=a,Ee()}})}()}}function Ke(){(t.tech.genetics&&t.tech.genetics>3||t.sim)&&(Ss($("#arpaCrispr")),$("#arpaCrispr").append(`
                            ${z("arpa_crispr_desc")}
                            `),$("#arpaCrispr").append('
                            '),Object.keys(Mr.genes).forEach((function(e){ti(Mr.genes[e].id),function(e){var a=!0;return Object.keys(Mr.genes[e].reqs).forEach((function(r){(!t.genes[r]||t.genes[r]=2&&(Ss($("#arpaBlood")),$("#arpaBlood").append(`
                            ${z("arpa_blood_desc")}
                            `),$("#arpaBlood").append('
                            '),Object.keys(Mr.blood).forEach((function(e){ti(Mr.blood[e].id),function(e){var a=!0;return Object.keys(Mr.blood[e].reqs).forEach((function(r){(!t.blood[r]||t.blood[r]
                            "),s=Ae(qe[a].cost);let n=Ms(qe[a],r/100,!1,!0);return Object.keys(s).forEach((function(e){var a=+(s[e]()*(r/100)).toFixed(0);if(a>0){var c="Money"===e?"$":t.resource[e].name+": ",o=t.resource[e].amount>=a?"has-text-dark":e===n.r?"has-text-danger":"has-text-alert";i.append($(`
                            ${c}${x(a,2)}
                            `))}})),i}function Ge(){Object.keys(t.resource).forEach((function(e){Cs({el:`#market-${e}`},"update")})),Cs({el:"#galaxyTrade"},"update")}const Ne={spc_titan:{info:{name:()=>Ut().titan,desc:()=>z("space_titan_info_desc",[Ut().titan,Ki[t.race.species].home]),support:"electrolysis",zone:"outer",syndicate:()=>!!(t.tech.titan&&t.tech.titan>=3&&t.tech.enceladus&&t.tech.enceladus>=2),syndicate_cap:()=>t.tech.triton?t.tech.outer>=4?2e3:1e3:600},titan_mission:{id:"space-titan_mission",title:()=>z("space_mission_title",[Ut().titan]),desc:()=>z("space_mission_desc",[Ut().titan]),reqs:{outer:1},grant:["titan",1],path:["truepath"],queue_complete:()=>t.tech.titan>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(25e4,!1,t).toFixed(0),Elerium:()=>100},effect:()=>z("space_titan_mission_effect",[Ut().titan]),action(){return!!ri($(this)[0])&&(hs(z("space_titan_mission_action",[Ut().titan,Ki[t.race.species].home]),"info",!1,["progress"]),!0)}},titan_spaceport:{id:"space-titan_spaceport",title:z("space_red_spaceport_title"),desc:`
                            ${z("space_red_spaceport_desc")}
                            ${z("requires_power")}
                            `,reqs:{titan:1},path:["truepath"],cost:{Money:e=>Ps("titan_spaceport",e,25e5,1.32),Lumber:e=>Ps("titan_spaceport",e,75e4,1.32),Cement:e=>Ps("titan_spaceport",e,35e4,1.32),Mythril:e=>Ps("titan_spaceport",e,1e4,1.32)},effect(){let e=t.resource.Water.display?`
                            ${z("plus_max_resource",[x(br(250)),t.resource.Water.name])}
                            `:"";return`${t.tech.enceladus&&t.tech.enceladus>=2?`
                            +${z("galaxy_alien2_support",[$(this)[0].support(),Ut().enceladus])}
                            `:""}${e}${t.tech.titan&&t.tech.titan>=5?`
                            ${z("space_titan_spaceport_storage",[25])}
                            `:""}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},support:()=>2,powered:()=>As(10),action(){return!!ri($(this)[0])&&(t.space.titan_spaceport.count++,Yr($(this)[0]),!0)},post(){1===t.tech.titan&&(t.tech.titan=2,Qr())}},electrolysis:{id:"space-electrolysis",title:z("space_electrolysis_title"),desc:()=>`
                            ${z("space_electrolysis_title")}
                            ${z("space_electrolysis_req",[t.resource.Water.name])}
                            `,reqs:{titan:3},path:["truepath"],cost:{Money:e=>Ps("electrolysis",e,1e6,1.25),Copper:e=>Ps("electrolysis",e,185e3,1.25),Steel:e=>Ps("electrolysis",e,22e4,1.25),Polymer:e=>Ps("electrolysis",e,38e4,1.25)},effect(){return`
                            +${z("galaxy_alien2_support",[$(this)[0].support(),Ut().titan])}
                            ${z("space_electrolysis_use",[$(this)[0].support_fuel().a,t.resource.Water.name,$(this)[0].powered()])}
                            `},support:()=>t.tech.titan_ai_core&&t.tech.titan_ai_core>=2&&s.ai_core2?3:2,support_fuel:()=>({r:"Water",a:35}),powered:()=>As(8),action(){return!!ri($(this)[0])&&(t.space.electrolysis.count++,Yr($(this)[0]),!0)},post(){3===t.tech.titan&&(t.tech.titan=4,Qr())}},hydrogen_plant:{id:"space-hydrogen_plant",title:z("space_hydrogen_plant_title"),desc:()=>`
                            ${z("space_hydrogen_plant_title")}
                            ${z("space_hydrogen_plant_req")}
                            `,reqs:{titan_power:1},path:["truepath"],cost:{Money:e=>Ps("hydrogen_plant",e,15e5,1.28),Iridium:e=>Ps("hydrogen_plant",e,292e3,1.28),Stanene:e=>Ps("hydrogen_plant",e,599e3,1.28),Cement:e=>Ps("hydrogen_plant",e,18e4,1.28)},effect(){return`${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${z("space_hydrogen_plant_effect",[1,z("space_electrolysis_title")])}`},support:()=>2,powered:()=>Fs(-22),action(){return!!ri($(this)[0])&&(t.space.hydrogen_plant.count++,t.space.electrolysis.on>t.space.hydrogen_plant.on&&t.space.hydrogen_plant.on++,!0)}},titan_quarters:{id:"space-titan_quarters",title:z("interstellar_habitat_title"),desc:()=>`
                            ${z("interstellar_habitat_title")}
                            ${z("space_habitat_req",[Ut().titan,t.resource.Food.name,t.resource.Water.name])}
                            `,reqs:{titan:4},path:["truepath"],cost:{Money:e=>Ps("titan_quarters",e,12e5,1.28),Furs:e=>Ps("titan_quarters",e,85e3,1.28),Plywood:e=>Ps("titan_quarters",e,1e5,1.28),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=ta(1);return`
                            ${z("space_used_support",[Ut().titan])}
                            ${z("plus_max_resource",[ta(1),t.race.truepath?z("job_colonist_tp",[Ut().titan]):z("colonist")])}
                            ${z("plus_max_resource",[e,z("citizen")])}
                            ${z("spend",[$(this)[0].support_fuel()[0].a,t.resource[$(this)[0].support_fuel()[0].r].name])}
                            ${z("spend",[$(this)[0].support_fuel()[1].a,t.resource[$(this)[0].support_fuel()[1].r].name])}
                            `},support:()=>-1,support_fuel:()=>[{r:"Water",a:12},{r:"Food",a:500}],powered:()=>As(1),action(){if(ri($(this)[0])){if(t.space.titan_quarters.count++,t.civic.titan_colonist.display=!0,t.space.electrolysis.support0)){let e=t.civic[t.civic.d_job].workers-ta(1)<0?t.civic[t.civic.d_job].workers:ta(1);t.civic[t.civic.d_job].workers-=e,t.civic.titan_colonist.workers+=e}return!0}return!1},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},titan_mine:{id:"space-titan_mine",title:z("space_red_mine_title"),desc:()=>`
                            ${z("space_red_mine_desc")}
                            ${z("space_support",[Ut().titan])}
                            `,reqs:{titan:4},condition:()=>!!(t.space.titan_quarters&&t.space.titan_quarters.count>0),path:["truepath"],cost:{Money:e=>Ps("titan_mine",e,475e3,1.28),Lumber:e=>Ps("titan_mine",e,568e3,1.28),Wrought_Iron:e=>Ps("titan_mine",e,25e4,1.28)},effect(){let e=$e("titan_mine","adamantite"),a=$e("titan_mine","aluminium"),r=+e.toFixed(3),i=+a.toFixed(3);return`
                            ${z("space_used_support",[Ut().titan])}
                            ${z("space_red_mine_effect",[r,t.resource.Adamantite.name])}
                            ${z("space_red_mine_effect",[i,t.resource.Aluminium.name])}
                            `},support:()=>-1,powered:()=>As(1),special:()=>!0,action(){return!!ri($(this)[0])&&(t.space.titan_mine.count++,t.resource.Adamantite.display=!0,t.space.electrolysis.supportPs("storehouse",e,175e3,1.28),Lumber:e=>Ps("storehouse",e,1e5,1.28),Aluminium:e=>Ps("storehouse",e,12e4,1.28),Cement:e=>Ps("storehouse",e,45e3,1.28)},wide:!0,res:()=>["Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Alloy","Polymer","Iridium","Chrysotile","Nano_Tube","Neutronium","Adamantite"],heavy:e=>!!["Copper","Iron","Steel","Titanium","Iridium","Neutronium","Adamantite"].includes(e),val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 3e3;case"Furs":return 1700;case"Copper":return 1520;case"Iron":return 1400;case"Aluminium":return 1280;case"Cement":return 1120;case"Coal":return 480;case"Steel":return 240;case"Titanium":return 160;case"Alloy":return 180;case"Polymer":return 150;case"Iridium":return 175;case"Nano_Tube":return 120;case"Neutronium":return 64;case"Adamantite":return 72;default:return 0}},effect(){let e='
                            ',a=mt("storehouse",!1),r=mt("storehouse",!0);for(const i of $(this)[0].res())if(t.resource[i].display){let s=$(this)[0].heavy(i);e+=`${z("plus_max_resource",[x(+(br($(this)[0].val(i))*(s?r:a)).toFixed(0),1),t.resource[i].name])}`}return e+="
                            ",e},action(){if(ri($(this)[0])){t.space.storehouse.count++;let e=mt("storehouse",!1),a=mt("storehouse",!0);for(const r of $(this)[0].res())if(t.resource[r].display){let i=$(this)[0].heavy(r);t.resource[r].max+=br($(this)[0].val(r))*(i?a:e)}return!0}return!1}},titan_bank:{id:"space-titan_bank",title:z("city_bank"),desc:()=>z("city_bank_desc",[Ut().titan]),reqs:{titan:6},path:["truepath"],cost:{Money:e=>Ps("titan_bank",e,25e5,1.32),Titanium:e=>Ps("titan_bank",e,38e4,1.32),Neutronium:e=>Ps("titan_bank",e,5e3,1.32)},effect(){let e=2*bi();return e=br(e),e=(+e.toFixed(0)).toLocaleString(),z("plus_max_resource",[`$${e}`,z("resource_Money_name")])},action(){return!!ri($(this)[0])&&(t.resource.Money.max+=br(1800),t.space.titan_bank.count++,!0)}},g_factory:{id:"space-g_factory",title:z("interstellar_g_factory_title"),desc:()=>`
                            ${z("interstellar_g_factory_title")}
                            ${z("space_support",[Ut().titan])}
                            `,reqs:{graphene:1},path:["truepath"],cost:{Money:e=>Ps("g_factory",e,95e4,1.28),Copper:e=>Ps("g_factory",e,165e3,1.28),Stone:e=>Ps("g_factory",e,22e4,1.28),Adamantite:e=>Ps("g_factory",e,12500,1.28)},effect(){let e=.05;return t.race.high_pop&&(e=+ke(e).toFixed(3)),`
                            ${z("space_used_support",[Ut().titan])}
                            ${z("space_red_mine_effect",[e,t.resource.Graphene.name])}
                            ${z("interstellar_g_factory_effect")}
                            `},support:()=>-1,powered:()=>As(1),special:!0,action(){return!!ri($(this)[0])&&(t.space.g_factory.count++,t.resource.Graphene.display=!0,t.space.electrolysis.support`
                            ${z("space_sam_desc")}
                            ${z("requires_power")}
                            `,reqs:{titan:7},path:["truepath"],cost:{Money:e=>Ps("sam",e,25e5,1.28),Steel:e=>Ps("sam",e,45e4,1.28),Elerium:e=>Ps("sam",e,120,1.28),Brick:e=>Ps("sam",e,16e4,1.28)},effect(){return`
                            ${z("galaxy_defense_platform_effect",[25])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(5),action(){return!!ri($(this)[0])&&(t.space.sam.count++,Yr($(this)[0]),!0)},post(){Cs({el:"#spc_titansynd"},"update")}},decoder:{id:"space-decoder",title:z("space_decoder_title"),desc:()=>`
                            ${z("space_decoder_title")}
                            ${z("requires_power_support_combo",[Ut().titan,t.resource.Cipher.name])}
                            `,reqs:{titan:8},path:["truepath"],cost:{Money:e=>Ps("decoder",e,125e5,1.275),Elerium:e=>Ps("decoder",e,750,1.275),Orichalcum:e=>Ps("decoder",e,33e4,1.275),Quantium:e=>Ps("decoder",e,18e4,1.275)},effect(){let e=$(this)[0].support_fuel().a,a=2500;t.race.high_pop&&(a=ke(a)),s.ai_core2&&(a*=1.25);let r=`
                            ${z("space_used_support",[Ut().titan])}
                            `;return r+=`
                            ${z("space_red_exotic_lab_effect1",[a])}
                            `,r+`
                            ${z("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
                            `},support:()=>-1,powered:()=>As(1),support_fuel:()=>({r:"Cipher",a:.06}),action(){return!!ri($(this)[0])&&(t.space.decoder.count++,t.space.electrolysis.support!t.space.hasOwnProperty("ai_core")||t.space.ai_core.count<100||e?`
                            ${z("space_ai_core")}
                            ${z("requires_segmemts",[100])}
                            `+(t.space.hasOwnProperty("ai_core")&&t.space.ai_core.count>=100?`
                            ${z("requires_power")}
                            `:""):`
                            ${z("space_ai_core")}
                            `,reqs:{titan:9},path:["truepath"],condition:()=>!(t.space.ai_core.count>=100),queue_size:10,queue_complete:()=>100-t.space.ai_core.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?25e5:0,Cement:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?18e4:0,Aluminium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?25e4:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?250:0,Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?125e3:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?5e4:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?1e5:0,Cipher:e=>(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0)<100?750:0},effect(e){let a=`
                            ${z("space_ai_core_effect")}
                            `,r=(e||0)+(t.space.hasOwnProperty("ai_core")?t.space.ai_core.count:0);return r<100?(a+=`
                            ${z("space_dwarf_collider_effect2",[100-r])}
                            `,a):Ne.spc_titan.ai_core2.effect()},action(){return!!(ri($(this)[0])&&t.space.ai_core.count<100)&&(t.space.ai_core.count++,t.space.ai_core.count>=100&&(t.tech.titan_ai_core=1,t.space.ai_core2={count:1,on:0},t.city.power>=Ne.spc_titan.ai_core2.powered()&&t.space.ai_core2.on++,Lt(),Qr()),!0)}},ai_core2:{id:"space-ai_core2",title:z("space_ai_core"),desc(){return`
                            ${z("space_ai_core")}
                            ${z("space_electrolysis_req",[t.resource[$(this)[0].p_fuel().r].name])}
                            `},reqs:{titan_ai_core:1},path:["truepath"],condition:()=>!!(t.space.hasOwnProperty("ai_core")&&t.space.ai_core.count>=100),wiki:!1,queue_complete:()=>0,cost:{},powered:()=>As(100),p_fuel:()=>({r:"Water",a:1e3}),effect(){let e=`
                            ${z("interstellar_citadel_stat",[+_.toFixed(1)])}
                            `;return e+=`
                            ${z("interstellar_citadel_effect",[25])}
                            ${z("space_ai_core_effect2",[25])}
                            `,t.tech.titan_ai_core&&t.tech.titan_ai_core>=2&&(e+=`
                            ${z("space_ai_core_effect3",[50])}
                            `),e+=`
                            ${z("space_electrolysis_use",[$(this)[0].p_fuel().a,t.resource[$(this)[0].p_fuel().r].name,$(this)[0].powered()])}
                            `,t.tech.titan_ai_core&&t.tech.titan_ai_core>=3&&(e+=`
                            ${z("space_ai_core_effect4",[+function(){let e=0;return s.ai_colonist&&n.decoder&&(e+=s.ai_colonist*n.decoder*.35),n.shock_trooper&&(e+=2*n.shock_trooper),n.tank&&(e+=2*n.tank),e>100&&(e=100),e}().toFixed(1)])}
                            `),e},action:()=>!1,flair:()=>t.space.hasOwnProperty("ai_core2")&&t.space.ai_core2.on>=1?z("space_ai_core_flair"):z("space_ai_core_flair2")},ai_colonist:{id:"space-ai_colonist",title:z("space_ai_colonist_title"),desc:()=>`
                            ${z("space_ai_colonist_title")}
                            ${z("requires_power")}
                            `,reqs:{titan_ai_core:3},path:["truepath"],cost:{Money:e=>Ps("ai_colonist",e,112e6,1.35),Alloy:e=>Ps("ai_colonist",e,75e4,1.35),Elerium:e=>Ps("ai_colonist",e,500,1.35),Nano_Tube:e=>Ps("ai_colonist",e,525e3,1.35),Quantium:e=>Ps("ai_colonist",e,15e4,1.35),Cipher:e=>Ps("ai_colonist",e,1e4,1.35)},effect(){return`
                            ${z("plus_max_resource",[ta(1),t.race.truepath?z("job_colonist_tp",[Ut().titan]):z("colonist")])}
                            ${z("space_ai_colonist_effect",[ta(1),Ut().titan])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(10),action(){return!!ri($(this)[0])&&(t.space.ai_colonist.count++,Yr($(this)[0]),!0)},flair:z("tech_combat_droids_flair")}},spc_enceladus:{info:{name:()=>Ut().enceladus,desc:()=>z("space_enceladus_info_desc",[Ut().enceladus,Ki[t.race.species].home]),support:"titan_spaceport",zone:"outer",syndicate:()=>!!(t.tech.titan&&t.tech.titan>=3&&t.tech.enceladus&&t.tech.enceladus>=2),syndicate_cap:()=>t.tech.triton?t.tech.outer>=4?1500:1e3:600},enceladus_mission:{id:"space-enceladus_mission",title:()=>z("space_mission_title",[Ut().enceladus]),desc:()=>z("space_mission_desc",[Ut().enceladus]),reqs:{outer:1},grant:["enceladus",1],path:["truepath"],queue_complete:()=>t.tech.enceladus>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(25e4,!1,t).toFixed(0),Elerium:()=>100},effect:()=>z("space_titan_mission_effect",[Ut().enceladus]),action(){return!!ri($(this)[0])&&(hs(z("space_enceladus_mission_action",[Ut().enceladus]),"info",!1,["progress"]),t.resource.Water.display=!0,!0)}},water_freighter:{id:"space-water_freighter",title:z("space_water_freighter_title"),desc:()=>`
                            ${z("space_water_freighter_title")}
                            ${z("space_support",[Ut().enceladus])}
                            `,reqs:{enceladus:2},path:["truepath"],cost:{Money:e=>Ps("water_freighter",e,45e4,1.25),Iron:e=>Ps("water_freighter",e,362e3,1.25),Nano_Tube:e=>Ps("water_freighter",e,125e3,1.25),Sheet_Metal:e=>Ps("water_freighter",e,75e3,1.25)},effect(e){let a=+Rt(5,!0,e).toFixed(2),r=+$e("water_freighter").toFixed(2);return`
                            ${z("space_used_support",[Ut().enceladus])}
                            ${z("produce",[r,t.resource.Water.name])}
                            ${z("space_belt_station_effect3",[a])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.space.water_freighter.count++,t.space.titan_spaceport.support`
                            ${z("tech_zero_g_lab")}
                            ${z("requires_power_support",[Ut().enceladus])}
                            `,reqs:{enceladus:3},path:["truepath"],cost:{Money:e=>Ps("zero_g_lab",e,5e6,1.25),Alloy:e=>Ps("zero_g_lab",e,125e3,1.25),Graphene:e=>Ps("zero_g_lab",e,225e3,1.25),Stanene:e=>Ps("zero_g_lab",e,6e5,1.25)},effect(){let e=lt("spc_enceladus"),a=Math.round(1e4*e),r=`
                            ${z("space_used_support",[Ut().enceladus])}
                            ${z("city_max_knowledge",[a])}
                            `;return t.resource.Quantium.display&&(r+=`
                            ${z("space_zero_g_lab_effect",[ta(1)])}
                            `),t.resource.Cipher.display&&(r+=`
                            ${z("plus_max_resource",[1e4,t.resource.Cipher.name])}
                            `),r+`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},support:()=>-1,powered:()=>As(12),action(){return!!ri($(this)[0])&&(t.space.zero_g_lab.count++,t.space.titan_spaceport.support`
                            ${z("tech_operating_base")}
                            ${z("requires_power_support",[Ut().enceladus])}
                            `,reqs:{enceladus:4},path:["truepath"],cost:{Money:e=>Ps("operating_base",e,75e5,1.3),Furs:e=>Ps("operating_base",e,5e5,1.3),Adamantite:e=>Ps("operating_base",e,375e3,1.3),Stanene:e=>Ps("operating_base",e,75e4,1.3),Mythril:e=>Ps("operating_base",e,225e3,1.3),Horseshoe:()=>t.race.hooved?4:0},effect(){let e=`
                            ${z("space_used_support",[Ut().enceladus])}
                            `;return e+=`
                            ${z("galaxy_defense_platform_effect",[50])}
                            `,e+=z("plus_max_resource",[ta(4),z("civics_garrison_soldiers")]),t.race.orbit_decayed&&(e+=`
                            ${z("city_hospital_effect",[5*t.tech.medic])}
                            `),e+`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},support:()=>-1,powered:()=>As(10),action(){return!!ri($(this)[0])&&(t.space.operating_base.count++,t.space.titan_spaceport.supportPs("munitions_depot",e,5e6,1.22),Iron:e=>Ps("munitions_depot",e,185e3,1.22),Sheet_Metal:e=>Ps("munitions_depot",e,1e5,1.22)},effect:()=>`
                            ${z("plus_max_crates",[25])}
                            ${z("plus_max_containers",[25])}
                            `,action(){return!!ri($(this)[0])&&(t.space.munitions_depot.count++,t.resource.Crates.max+=25,t.resource.Containers.max+=25,!0)}}},spc_triton:{info:{name:()=>Ut().triton,desc:()=>z("space_triton_info_desc",[Ut().triton,Ki[t.race.species].home]),zone:"outer",syndicate:()=>!!(t.tech.triton&&t.tech.triton>=2),syndicate_cap:()=>t.tech.outer&&t.tech.outer>=4?5e3:3e3,extra(e){t.tech.triton&&t.tech.triton>=3&&($(`#${e}`).append(`
                            ${z("space_ground_resist")}
                            `),Cs({el:`#${e}resist`,data:t.space.fob,methods:{threat(e,a){let r=t.civic.garrison.wounded-we();r<0&&(r=0);let i=+(e-be(a,"army",r)).toFixed(0);return i<0?0:i}}}))}},triton_mission:{id:"space-triton_mission",title:()=>z("space_mission_title",[Ut().triton]),desc:()=>z("space_mission_desc",[Ut().triton]),reqs:{outer:2},grant:["triton",1],path:["truepath"],queue_complete:()=>t.tech.triton>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(6e5,!1,t).toFixed(0),Elerium:()=>2500},effect:()=>z("space_triton_mission_effect",[Ut().triton]),action(){return!!ri($(this)[0])&&(hs(z("space_triton_mission_action",[Ut().triton]),"info",!1,["progress"]),t.space.syndicate.spc_triton=1250,t.space.syndicate.spc_titan+=250,t.space.syndicate.spc_enceladus+=250,!0)}},fob:{id:"space-fob",title:z("space_fob_title"),desc:()=>`
                            ${z("tech_fob")}
                            ${z("requires_power_combo",[t.resource.Helium_3.name])}
                            `,reqs:{triton:2},path:["truepath"],queue_complete:()=>1-t.space.fob.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,25e7,1.1),Copper:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,8e6,1.1),Uranium:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,5e4,1.1),Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,25e5,1.1),Graphene:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,3e6,1.1),Sheet_Metal:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,75e5,1.1),Quantium:e=>(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)>=1?0:Ps("fob",e,5e5,1.1),Horseshoe:e=>t.race.hooved&&(e||0)+(t.space.hasOwnProperty("fob")?t.space.fob.count:0)<1?10:0},effect(e){let a=we(),r=we(!0),i=`
                            ${z("galaxy_defense_platform_effect",[500])}
                            `;i+=z("plus_max_resource",[ta(10),z("civics_garrison_soldiers")]),i+=`
                            ${z("civics_garrison_soldiers")}: ${a} / ${r}
                            `,i+=`
                            ${z("civics_garrison_wounded")}: ${t.civic.garrison?t.civic.garrison.wounded:0}
                            `,i+=`
                            ${z("space_fob_landed",[t.space.fob?t.space.fob.troops:0])}
                            `;let s=+Rt(125,!0,e).toFixed(2);return i+`
                            ${z("requires_power_combo_effect",[$(this)[0].powered(),s,t.resource.Helium_3.name])}
                            `},powered:()=>As(50),action(){return!!(t.space.fob.count<1&&ri($(this)[0]))&&(t.space.fob.count++,Yr($(this)[0]),!0)},post(){2===t.tech.triton&&(t.tech.triton=3,Qr(),Lt(),hs(z("space_fob_msg"),"info",!1,["progress"]))}},lander:{id:"space-lander",title:z("space_lander_title"),desc:()=>`
                            ${z("space_lander_title")}
                            ${z("requires_soldiers")}
                            ${z("space_red_space_barracks_desc_req")}
                            `,reqs:{triton:3},path:["truepath"],cost:{Money:e=>Ps("lander",e,24e5,1.15),Aluminium:e=>Ps("lander",e,185e3,1.15),Neutronium:e=>Ps("lander",e,1e4,1.15),Nano_Tube:e=>Ps("lander",e,158e3,1.15)},powered:()=>As(1),effect(e){let a=+Rt(50,!0,e).toFixed(2),r="";return t.space.crashed_ship&&100===t.space.crashed_ship.count&&(r=`
                            ${z("space_lander_effect3",[$e("lander"),t.resource.Cipher.name])}
                            `),`
                            ${z("space_lander_effect",[Ut().triton])}
                            ${r}
                            ${z("space_lander_effect2",[ta(3)])}
                            ${z("space_red_space_barracks_effect2",[a])}
                            `},action(){return!!ri($(this)[0])&&(t.space.lander.count++,t.space.lander.on++,!0)}},crashed_ship:{id:"space-crashed_ship",title:z("space_crashed_ship_title"),desc:()=>`
                            ${z("space_crashed_ship_title")}
                            `,reqs:{triton:3},path:["truepath"],queue_complete:()=>0,cost:{},effect:()=>`
                            ${z("space_crashed_ship_effect",[t.space.crashed_ship?t.space.crashed_ship.count:0])}
                            `,action:()=>!1}},spc_kuiper:{info:{name:()=>z("space_kuiper_title"),desc:()=>z("space_kuiper_desc"),zone:"outer",syndicate:()=>!!t.tech.kuiper,syndicate_cap:()=>2500},kuiper_mission:{id:"space-kuiper_mission",title:()=>z("space_mission_title",[z("space_kuiper_title")]),desc:()=>z("space_mission_desc",[z("space_kuiper_title")]),reqs:{outer:7},grant:["kuiper",1],path:["truepath"],queue_complete:()=>t.tech.kuiper>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(1e6,!1,t).toFixed(0),Elerium:()=>1e3},effect:()=>z("space_kuiper_mission_effect"),action(){return!!ri($(this)[0])&&(t.space.orichalcum_mine={count:0,on:0},t.space.uranium_mine={count:0,on:0},t.space.neutronium_mine={count:0,on:0},t.space.syndicate.spc_kuiper=500,hs(z("space_kuiper_mission_action"),"info",!1,["progress"]),!0)}},orichalcum_mine:{id:"space-orichalcum_mine",title:()=>z("space_kuiper_mine",[t.resource.Orichalcum.name]),desc:()=>`
                            ${z("space_kuiper_mine",[t.resource.Orichalcum.name])}
                            ${z("requires_power_combo",[t.resource.Oil.name])}
                            `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Ps("orichalcum_mine",e,25e6,1.25),Graphene:e=>Ps("orichalcum_mine",e,9e5,1.25),Elerium:e=>Ps("orichalcum_mine",e,200,1.25),Mythril:e=>Ps("orichalcum_mine",e,45e4,1.25),Quantium:e=>Ps("orichalcum_mine",e,15e4,1.25)},effect(e){let a=+$e("orichalcum_mine").toFixed(3),r=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
                            ${z("gain",[a,z("resource_Orichalcum_name")])}
                            ${z("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
                            `},powered:()=>As(10),p_fuel:()=>({r:"Oil",a:200}),action(){return!!ri($(this)[0])&&(t.space.orichalcum_mine.count++,t.resource.Orichalcum.display=!0,Yr($(this)[0]),!0)}},uranium_mine:{id:"space-uranium_mine",title:()=>z("space_kuiper_mine",[t.resource.Uranium.name]),desc:()=>`
                            ${z("space_kuiper_mine",[t.resource.Uranium.name])}
                            ${z("requires_power_combo",[t.resource.Oil.name])}
                            `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Ps("uranium_mine",e,5e6,1.25),Iridium:e=>Ps("uranium_mine",e,25e4,1.25),Steel:e=>Ps("uranium_mine",e,62e4,1.25)},effect(e){let a=+$e("uranium_mine").toFixed(3),r=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
                            ${z("gain",[a,z("resource_Uranium_name")])}
                            ${z("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
                            `},powered:()=>As(5),p_fuel:()=>({r:"Oil",a:60}),action(){return!!ri($(this)[0])&&(t.space.uranium_mine.count++,Yr($(this)[0]),!0)}},neutronium_mine:{id:"space-neutronium_mine",title:()=>z("space_kuiper_mine",[t.resource.Neutronium.name]),desc:()=>`
                            ${z("space_kuiper_mine",[t.resource.Neutronium.name])}
                            ${z("requires_power_combo",[t.resource.Oil.name])}
                            `,reqs:{kuiper:1},path:["truepath"],cost:{Money:e=>Ps("neutronium_mine",e,8e6,1.25),Adamantite:e=>Ps("neutronium_mine",e,65e4,1.25),Stanene:e=>Ps("neutronium_mine",e,125e4,1.25)},effect(e){let a=+$e("neutronium_mine").toFixed(3),r=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
                            ${z("gain",[a,z("resource_Neutronium_name")])}
                            ${z("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
                            `},powered:()=>As(8),p_fuel:()=>({r:"Oil",a:60}),action(){return!!ri($(this)[0])&&(t.space.neutronium_mine.count++,Yr($(this)[0]),!0)}},elerium_mine:{id:"space-elerium_mine",title:()=>z("space_kuiper_mine",[t.resource.Elerium.name]),desc:()=>`
                            ${z("space_kuiper_mine",[t.resource.Elerium.name])}
                            ${z("requires_power_combo",[t.resource.Oil.name])}
                            `,reqs:{kuiper:2},path:["truepath"],cost:{Money:e=>Ps("elerium_mine",e,2e7,1.25),Titanium:e=>Ps("elerium_mine",e,25e4,1.25),Neutronium:e=>Ps("elerium_mine",e,12e4,1.25),Orichalcum:e=>Ps("elerium_mine",e,175e3,1.25)},effect(e){let a=+$e("elerium_mine").toFixed(3),r=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(1);return`
                            ${z("gain",[a,z("resource_Elerium_name")])}
                            ${z("requires_power_combo_effect",[$(this)[0].powered(),r,t.resource[$(this)[0].p_fuel().r].name])}
                            `},powered:()=>As(12),p_fuel:()=>({r:"Oil",a:125}),action(){return!!ri($(this)[0])&&(t.space.elerium_mine.count++,Yr($(this)[0]),!0)}}},spc_eris:{info:{name:()=>Ut().eris,desc:()=>z("space_eris_info_desc",[Ut().eris]),support:"drone_control",zone:"outer",syndicate:()=>!!t.tech.eris,syndicate_cap:()=>7500,extra(e){t.tech.eris&&1===t.tech.eris&&($(`#${e}`).append(`
                            ${z("space_scanned")} {{ eris_scan }}%
                            `),Cs({el:`#${e}scanned`,data:t.tech}))}},eris_mission:{id:"space-eris_mission",title:()=>z("space_mission_title",[Ut().eris]),desc:()=>z("space_mission_desc",[Ut().eris]),reqs:{outer:7},grant:["eris",1],path:["truepath"],queue_complete:()=>t.tech.eris>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(125e4,!1,t).toFixed(0),Elerium:()=>1250},effect:()=>z("space_eris_mission_effect",[Ut().eris]),action(){return!!ri($(this)[0])&&(t.space.syndicate.spc_eris=4e3,hs(z("space_eris_mission_action",[Ut().eris]),"info",!1,["progress"]),!0)}},drone_control:{id:"space-drone_control",title:()=>z("space_drone_control",[Ut().titan]),desc(){return`
                            ${z("space_drone_control",[Ut().titan])}
                            ${z("requires_power_combo",[t.resource[$(this)[0].p_fuel().r].name])}
                            `},reqs:{eris:3},path:["truepath"],cost:{Money:e=>Ps("drone_control",e,75e6,1.3),Neutronium:e=>Ps("drone_control",e,1e5,1.3),Stanene:e=>Ps("drone_control",e,45e4,1.3),Quantium:e=>Ps("drone_control",e,3e5,1.3)},effect(){let e=$(this)[0].p_fuel().a;return`
                            +${z("galaxy_alien2_support",[$(this)[0].support(),Ut().eris])}
                            ${z("requires_power_combo_effect",[$(this)[0].powered(),e,t.resource[$(this)[0].p_fuel().r].name])}
                            `},support:()=>5,powered:()=>As(25),p_fuel:()=>({r:"Uranium",a:5}),action(){return!!ri($(this)[0])&&(t.space.drone_control.count++,Yr($(this)[0]),!0)}},shock_trooper:{id:"space-shock_trooper",title:z("space_shock_trooper_title"),desc:()=>`
                            ${z("space_shock_trooper_title")}
                            ${z("space_support",[Ut().eris])}
                            `,reqs:{eris:3},path:["truepath"],cost:{Money:e=>Ps("shock_trooper",e,425e4,1.225),Polymer:e=>Ps("shock_trooper",e,375e3,1.225),Adamantite:e=>Ps("shock_trooper",e,5e5,1.225),Graphene:e=>Ps("shock_trooper",e,22e4,1.225),Elerium:e=>Ps("shock_trooper",e,350,1.225)},effect(){let e=Math.round(be(1,"army",0)*lt("spc_eris")),a=`
                            ${z("space_used_support",[Ut().eris])}
                            `;return t.space.digsite&&100===t.space.digsite.count&&(a=`
                            ${z("space_lander_effect3",[$e("shock_trooper"),t.resource.Cipher.name])}
                            `),a+`
                            ${z("space_digsite_offense",[e])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.space.shock_trooper.count++,t.space.drone_control.support`
                            ${z("space_tank_title")}
                            ${z("space_support",[Ut().eris])}
                            `,reqs:{eris:4},path:["truepath"],cost:{Money:e=>Ps("tank",e,1e8,1.25),Alloy:e=>Ps("tank",e,125e4,1.25),Orichalcum:e=>Ps("tank",e,6e5,1.25),Mythril:e=>Ps("tank",e,5e5,1.25),Uranium:e=>Ps("tank",e,25e3,1.25)},effect(){let e=Math.round(100*lt("spc_eris")),a=`
                            ${z("space_used_support",[Ut().eris])}
                            `;return t.space.digsite&&100===t.space.digsite.count&&(a=`
                            ${z("space_lander_effect3",[$e("tank"),t.resource.Cipher.name])}
                            `),a+`
                            ${z("space_digsite_offense",[e])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.space.tank.count++,t.space.drone_control.support`
                            ${z("space_digsite_title")}
                            `,reqs:{eris:3},path:["truepath"],queue_complete:()=>0,cost:{},effect:()=>`
                            ${z("space_crashed_ship_effect",[t.space.digsite?t.space.digsite.count:0])}
                            `,action:()=>!1}}},Re={tau_star:{info:{name:()=>z("tab_tauceti"),desc:()=>z("tau_star",[z("tab_tauceti"),z("space_sun_info_name")])},ringworld:{id:"tauceti-ringworld",title:z("tau_star_ringworld"),desc:e=>!t.tauceti.hasOwnProperty("ringworld")||t.tauceti.ringworld.count<1e3||e?`
                            ${z("tau_star_ringworld")}
                            ${z("requires_segmemts",[1e3])}
                            `:`
                            ${z("tau_star_ringworld")}
                            `,reqs:{matrix:2},path:["truepath"],queue_size:50,queue_complete:()=>1e3-t.tauceti.ringworld.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?1e7:1e8:0,Neutronium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?2e4:1e5:0,Nano_Tube:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?7e4:35e4:0,Adamantite:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?2e5:1e6:0,Bolognium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?17600:88e3:0,Orichalcum:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?25e3:125e3:0,Unobtainium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?t.race.lone_survivor?360:1800:0,Quantium:e=>(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0)<1e3?Ve(t.race.lone_survivor?10100:101e3):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("ringworld")?t.tauceti.ringworld.count:0);if(r<1e3){let e=1e3-r;a+=`
                            ${z("tau_star_ringworld_effect")}
                            `,a+=`
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}else a+=`
                            ${z("space_dwarf_reactor_effect1",[t.race.lone_survivor?100:1e4])}
                            `;return a},action(){return!!(ri($(this)[0])&&t.tauceti.ringworld.count<1e3)&&(t.tauceti.ringworld.count++,t.tauceti.ringworld.count>=1e3&&(t.race.lone_survivor?t.tech.eden=1:(t.tech.matrix=3,t.tauceti.matrix={count:1,on:0}),Je(),_s()),!0)}},matrix:{id:"tauceti-matrix",title:z("tau_star_matrix"),desc:()=>`
                            ${z("tau_star_matrix")}
                            ${z("requires_power")}
                            `,reqs:{matrix:3},condition:()=>t.tauceti.ringworld.count>=1e3,queue_complete:()=>0,cost:{},powered:()=>1e4,postPower(e){e?setTimeout((function(){t.tech.matrix=s.matrix?4:3,Je()}),250):(t.tech.matrix=3,Je())},effect(){let e=He(),t=$(this)[0].powered(),a=t>0?`
                            ${z("minus_power",[t])}
                            `:"";return`
                            ${z("tau_star_matrix_effect")}
                            ${e}${a}`},action:()=>!1},blue_pill:{id:"tauceti-blue_pill",title:z("tau_star_blue_pill"),desc:z("tau_star_blue_pill"),wiki:!1,reqs:{matrix:4},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=He();return`
                            ${z("tau_star_blue_pill_effect")}
                            ${e}`},action(){if(ri($(this)[0])){$("body").append('');const a=document.getElementById("matrix"),r=a.getContext("2d"),i=a.width=document.body.offsetWidth,s=a.height=document.body.offsetHeight,n=Math.floor(i/20)+1,c=Array(n).fill(0);function o(){r.fillStyle="#0001",r.fillRect(0,0,i,s),r.fillStyle="#0f0",r.font="15pt monospace",c.forEach(((e,t)=>{const a=String.fromCharCode(Math.rand(65382,65438)),i=20*t;r.fillText(a,i,e),e>100+1e4*Math.random()?c[t]=0:c[t]=e+20}))}return setInterval(o,50),setTimeout((function(){!function(){P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"matrix"});let a=t.race.species,r=t.race.gods,i=Ki[a].type,s=t.city.calendar.orbit,n=t.city.biome,c=t.city.ptrait,o=t.city.geology,l=Gs("matrix");qn(`biome_${n}`),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),qn(`genus_${i}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),qn("bluepill"),U(),Sn(),t.stats.matrix++,rn(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let _=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),_&&(t.race.srace=_),H({orbit:s,biome:n,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),5e3),!0}return!1}},goe_facility:{id:"tauceti-goe_facility",title:z("tau_star_goe_facility"),desc:()=>`
                            ${z("tau_star_goe_facility")}
                            `,reqs:{eden:2},condition:()=>t.tauceti.ringworld.count>=1e3,queue_complete:()=>0,cost:{Money:e=>1e6,Copper:e=>1e7,Graphene:e=>5e6,Stanene:e=>8e6,Elerium:e=>1e4},effect(){let e=function(){let e=Gs("eden"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                            ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                            ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                            ${z("tau_star_matrix_servants",[1])}
                            `}();return`
                            ${z("tau_star_goe_facility_effect")}
                            ${e}`},action(){if(ri($(this)[0])){let a=Ns(Re.tau_star.goe_facility);return Object.keys(a).forEach((function(e){t.resource[e].amount+=a[e]()})),function(){P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"eden"});let a=t.race.species,r=t.race.gods,i=Ki[a].type,s=t.city.calendar.orbit,n=t.city.biome,c=t.city.ptrait,o=t.city.geology,l=Gs("eden");qn(`biome_${n}`),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),qn(`genus_${i}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),qn("adam_eve"),U(),Sn(),t.stats.eden++,rn(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let _=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),_&&(t.race.srace=_),H({orbit:s,biome:n,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),!1}return!1}}},tau_home:{info:{name:()=>z("tau_planet",[Ki[t.race.species].home]),desc:()=>z("tau_home",[Ki[t.race.species].home]),support:"orbital_station",extra(e){t.tech.tau_home&&t.tech.tau_home>=2&&!Qe()&&($(`#${e}`).append(`
                            ${z("resource_Materials_name")} {{ amount | round }} / {{ max }}
                            `),Cs({el:`#${e}Mats`,data:t.resource.Materials,methods:{tauShow:()=>!Qe()},filters:{round:e=>+e.toFixed(0)}}))}},home_mission:{id:"tauceti-home_mission",title:()=>z("tau_new_mission_title",[Ki[t.race.species].home]),desc:()=>z("tau_new_mission_title",[Ki[t.race.species].home]),reqs:{tauceti:2},grant:["tau_home",1],path:["truepath"],queue_complete:()=>t.tech.tau_home>=1?0:1,cost:{Money:()=>1e9},effect:()=>z("tau_new_mission_effect",[Ki[t.race.species].home]),action(){return!!ri($(this)[0])&&(t.tauceti.colony={count:0,on:0},t.tauceti.mining_pit={count:0,on:0},hs(z("tau_home_mission_result",[Ki[t.race.species].home]),"info",!1,["progress"]),!0)}},dismantle:{id:"tauceti-dismantle",title:()=>z("tau_home_dismantle"),desc:()=>z("tau_home_dismantle"),reqs:{tau_home:1},grant:["tau_home",2],path:["truepath"],queue_complete:()=>t.tech.tau_home>=2?0:1,cost:{Money:()=>1e8},effect(){let e="Explorer";if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let a=t.space.shipyard.ships.findIndex((e=>"tauceti"===e.location&&"explorer"===e.class));-1!==a&&(e=t.space.shipyard.ships[a].name)}return z("tau_home_dismantle_effect",[e])},action(){let e=-1;if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")&&(e=t.space.shipyard.ships.findIndex((e=>"tauceti"===e.location&&"explorer"===e.class))),e>=0&&ri($(this)[0])){if(t.space.shipyard.ships.splice(e,1),t.tauceti.orbital_station.count++,t.tauceti.colony.count++,t.tauceti.mining_pit.count++,t.civic.pit_miner.display=!0,t.resource.Materials.display=!0,t.city.powered&&t.city.power>=Re.tau_home.orbital_station.powered()){t.tauceti.orbital_station.on++,t.tauceti.colony.on++,t.tauceti.mining_pit.on++;let e=ta(4);t.civic[t.civic.d_job].workers${z("tau_home_orbital_station")}
                            ${z("requires_power")}
                            `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Ps("orbital_station",e,8e7,1.3,"tauceti"),Materials:e=>Qe()?0:Ps("orbital_station",e,5e5,1.3,"tauceti"),Helium_3:e=>Qe()?Ps("orbital_station",e,Ht(25e4),1.3,"tauceti"):0,Copper:e=>Qe()?Ps("orbital_station",e,125e4,1.3,"tauceti"):0,Adamantite:e=>Qe()?Ps("orbital_station",e,9e5,1.3,"tauceti"):0},effect(){let e=br(15e3),a=+Ht($(this)[0].support_fuel().a).toFixed(1),r=`
                            ${z("space_red_spaceport_effect1",[z("tau_planet",[Ki[t.race.species].home]),$(this)[0].support()])}
                            `;return r+=`
                            ${z("plus_max_resource",[e.toLocaleString(),t.resource.Helium_3.name])}
                            `,r+=`
                            ${z("spend_power",[a,t.resource[$(this)[0].support_fuel().r].name,$(this)[0].powered()])}
                            `,r},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?t.race.lone_survivor?5:25:400}),support:()=>3,powered:()=>As(t.tech.isolation?t.race.lone_survivor?4:6:30),refresh:!0,action(){return!!ri($(this)[0])&&(t.tauceti.orbital_station.count++,Yr($(this)[0]),!0)}},colony:{id:"tauceti-colony",title:z("tau_home_colony"),desc:()=>`
                            ${z("tau_home_colony_desc",[Ki[t.race.species].home])}
                            ${z("requires_power_support_combo",[Ki[t.race.species].home,t.resource.Food.name])}
                            `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Ps("colony",e,1575e4,1.225,"tauceti"),Materials:e=>Qe()?0:Ps("colony",e,65e4,1.225,"tauceti"),Furs:e=>Qe()?Ps("colony",e,72e4,1.225,"tauceti"):0,Graphene:e=>Qe()?Ps("colony",e,485e3,1.225,"tauceti"):0,Brick:e=>Qe()?Ps("colony",e,Ve(88e4),1.225,"tauceti"):0},effect(){let e=$(this)[0].citizens(),a=t.tech.isolation?900:250,r=+$(this)[0].support_fuel().a.toFixed(1),i=`
                            ${z("tau_new_support",[$(this)[0].support(),Ki[t.race.species].home])}
                            `;if(t.race.lone_survivor||(i+=`
                            ${z("plus_max_citizens",[e])}
                            `),t.tech.isolation){let e=25*bi();e=br(e),e=(+e.toFixed(0)).toLocaleString(),i+=`
                            ${z("plus_max_resource",[`$${e}`,z("resource_Money_name")])}
                            `}if(i+=`
                            ${z("tau_home_colony_effect",[50,Ki[t.race.species].home])}
                            `,t.tech.isolation){let e=K("gaslighter",0);i+=`
                            ${z("space_red_vr_center_effect1",[2*(e?e+t.tech.broadcast:t.tech.broadcast)])}
                            `}return i+=`
                            ${z("plus_max_resource",[a,z("resource_Crates_name")])}
                            ${z("plus_max_resource",[a,z("resource_Containers_name")])}
                            `,t.race.lone_survivor?i+=`
                            ${z("gain",[-r,t.resource[$(this)[0].support_fuel().r].name])}
                            `:i+=`
                            ${z("spend",[r,t.resource[$(this)[0].support_fuel().r].name])}
                            `,i},support:()=>-2,support_fuel:()=>({r:"Food",a:t.tech.isolation?t.race.lone_survivor?-2:75:1e3}),powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.colony.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.colony.on++,!0)},citizens(){let e=t.tech.isolation?8:5;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),t.race.lone_survivor?0:e}},tau_housing:{id:"tauceti-tau_housing",title:()=>pi("small"),desc:z("city_basic_housing_desc"),desc(){return 1===$(this)[0].citizens()?z("city_basic_housing_desc"):z("city_basic_housing_desc_plural",[$(this)[0].citizens()])},category:"residential",reqs:{housing:1,isolation:1},condition:()=>!t.race.lone_survivor,cost:{Money:e=>Ps("tau_housing",e,15e4,1.15,"tauceti"),Lumber:e=>t.race.kindling_kindred||t.race.smoldering?0:Ps("tau_housing",e,125e3,1.25,"tauceti"),Stone:e=>t.race.kindling_kindred?Ps("tau_housing",e,125e3,1.25,"tauceti"):0,Chrysotile:e=>t.race.smoldering?Ps("tau_housing",e,5e4,1.25,"tauceti"):0,Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.sappy?`
                            ${z("plus_max_resource",[e,z("citizen")])}
                            ${z("city_grove_effect",[2.5])}
                            `:z("plus_max_resource",[e,z("citizen")])},action(){return!!ri($(this)[0])&&(t.tauceti.tau_housing.count++,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},captive_housing:Cr("captive_housing","tauceti"),pylon:{id:"tauceti-pylon",title:z("tau_home_pylon"),desc:z("tau_home_pylon"),reqs:{magic:2},condition:()=>!(!t.tech.isolation||!t.tauceti.hasOwnProperty("pylon")),cost:{Money:e=>Ps("pylon",e,50,1.48,"tauceti"),Stone:e=>Ps("pylon",e,100,1.42,"tauceti"),Crystal:e=>Ps("pylon",e,8,1.42,"tauceti")-3},effect(){let e=br(2);return`
                            ${z("gain",[+(.0125*Is("magic")).toFixed(3),t.resource.Mana.name])}
                            ${z("plus_max_resource",[e,t.resource.Mana.name])}
                            `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!ri($(this)[0])&&(t.tauceti.pylon.count++,t.resource.Mana.max+=br(2),!0)}},cloning_facility:{id:"tauceti-cloning_facility",title:z("tau_home_cloning"),desc:()=>z("tau_home_cloning_desc",[Ki[t.race.species].name]),category:"military",reqs:{cloning:1},path:["truepath"],queue_complete:()=>t.resource[t.race.species].max-t.resource[t.race.species].amount,cost:{Money:e=>t.resource[t.race.species].amount?Ps("citizen",e,Math.round((t.race.high_pop?1e5:125e3)/ta(1)),t.race.high_pop?1.01:1.02,"tauceti",t.race.high_pop?1.003:1.005):0,Copper:e=>!t.race.artifical||t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Ps("citizen",e,Math.round(50/ta(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0,Aluminium:e=>!t.race.artifical||t.race.deconstructor?0:t.resource[t.race.species].amount>=5?Ps("citizen",e,Math.round(50/ta(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0,Nanite:e=>t.race.deconstructor&&t.resource[t.race.species].amount>=3?Ps("citizen",e,Math.round(500/ta(1)),1.01,"tauceti",t.race.high_pop?1.0032:1.005):0},effect(){let e="";return t.resource[t.race.species].max===t.resource[t.race.species].amount&&(e=`
                            ${z("city_assembly_effect_warn")}
                            `),`
                            ${z("tau_home_cloning_effect",[Ki[t.race.species].name])}
                            ${e}`},action(){return!!(t.resource[t.race.species].max>t.resource[t.race.species].amount&&ri($(this)[0]))&&(t.resource[t.race.species].amount++,!0)}},horseshoe:Cr("horseshoe","tauceti"),bonfire:Cr("bonfire","tauceti"),firework:Cr("firework","tauceti"),assembly:Cr("assembly","tauceti"),nanite_factory:Cr("nanite_factory","tauceti"),tau_farm:{id:"tauceti-tau_farm",title:z("tau_home_tau_farm"),desc:()=>`
                            ${z("tau_home_tau_farm")}
                            ${z("requires_power")}
                            `,reqs:{tau_home:7},path:["truepath"],cost:{Money:e=>Ps("tau_farm",e,135e6,1.25,"tauceti"),Stone:e=>Ps("tau_farm",e,921e4,1.25,"tauceti"),Steel:e=>Ps("tau_farm",e,6295e3,1.25,"tauceti"),Water:e=>Ps("tau_farm",e,1e4,1.25,"tauceti")},effect(){let e=`
                            ${z("space_red_spaceport_effect1",[z("tau_planet",[Ki[t.race.species].home]),$(this)[0].support()])}
                            `;return e+=`
                            ${z("produce",[+$e("tau_farm","food").toFixed(2),t.resource.Food.name])}
                            `,t.race.kindling_kindred||t.race.smoldering||(e+=`
                            ${z("produce",[+$e("tau_farm","lumber").toFixed(2),t.resource.Lumber.name])}
                            `),t.tech.isolation&&(e+=`
                            ${z("produce",[+$e("tau_farm","water").toFixed(2),t.resource.Water.name])}
                            `,t.race.artifical&&(e+=`
                            ${z("city_transmitter_effect",[br(350)])}
                            `)),e+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,e},support:()=>1,powered:()=>Fs(t.tech.isolation?1:4),action(){return!!ri($(this)[0])&&(t.tauceti.tau_farm.count++,Yr($(this)[0]),!0)}},mining_pit:{id:"tauceti-mining_pit",title:z("tau_home_mining_pit"),desc:()=>`
                            ${z("tau_home_mining_pit")}
                            ${z("space_support",[Ki[t.race.species].home])}
                            `,reqs:{tau_home:2},path:["truepath"],cost:{Money:e=>Ps("mining_pit",e,425e4,1.225,"tauceti"),Materials:e=>Qe()?0:Ps("mining_pit",e,35e4,1.225,"tauceti"),Lumber:e=>Qe()?Ps("mining_pit",e,235e4,1.225,"tauceti"):0,Iron:e=>Qe()?Ps("mining_pit",e,835e3,1.225,"tauceti"):0},effect(){let e=`
                            ${z("tau_new_support",[$(this)[0].support(),Ki[t.race.species].home])}
                            `;if(e+=`
                            ${z("plus_max_resource",[ta(t.tech.isolation?6:8),z("job_pit_miner")])}
                            `,Qe())if(t.tech.isolation){if(t.race.lone_survivor){let a=[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name,t.resource.Copper.name,t.resource.Iron.name,t.resource.Aluminium.name,t.resource.Coal.name];t.race.smoldering?(a.push(t.resource.Chrysotile.name),e+=`
                            ${z("tau_home_mining_pit_effect2cs",a)}
                            `):e+=`
                            ${z("tau_home_mining_pit_effect2c",a)}
                            `}else{let a=[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name,t.resource.Copper.name,t.resource.Coal.name];t.race.smoldering?(a.push(t.resource.Chrysotile.name),e+=`
                            ${z("tau_home_mining_pit_effect2bs",a)}
                            `):e+=`
                            ${z("tau_home_mining_pit_effect2b",a)}
                            `}e+=`
                            ${z("tau_gas_womling_station_effect",[8,t.resource.Cement.name])}
                            `}else e+=`
                            ${z("tau_home_mining_pit_effect2",[t.resource.Bolognium.name,t.resource.Adamantite.name,t.resource.Stone.name])}
                            `;else e+=`
                            ${z("plus_max_resource",[1e6,z("resource_Materials_name")])}
                            `,e+=`
                            ${z("tau_home_mining_pit_effect",[t.resource.Materials.name])}
                            `;return e},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.mining_pit.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.mining_pit.on++,!0)}},excavate:{id:"tauceti-excavate",title:z("tau_home_excavate"),desc:()=>`
                            ${z("tau_home_excavate")}
                            `,reqs:{tau_home:2},grant:["tau_home",3],path:["truepath"],cost:{Money:e=>165e7,Materials:e=>75e4},effect:()=>z("tau_home_excavate_effect"),action(){return!!ri($(this)[0])&&(hs(z("tau_home_excavate_msg"),"info",!1,["progress"]),!0)}},alien_outpost:{id:"tauceti-alien_outpost",title:z("tech_alien_outpost"),desc:()=>`
                            ${z("tech_alien_outpost")}
                            ${z("requires_power")}
                            `,reqs:{tau_home:4},path:["truepath"],cost:{},queue_complete:()=>0,effect(){let e=`
                            ${z("plus_max_resource",["20%",z("resource_Knowledge_name")])}
                            `;return t.tech.isolation&&(e+=`
                            ${z("plus_max_resource",[(t.race.lone_survivor?35e5:65e5).toLocaleString(),z("resource_Knowledge_name")])}
                            `,e+=`
                            ${z("plus_max_resource",[2e5.toLocaleString(),t.resource.Cipher.name])}
                            `,e+=`
                            ${z("space_lander_effect3",[$e("alien_outpost"),t.resource.Cipher.name])}
                            `),t.tech.outpost_boost&&(e+=`
                            ${z("tech_alien_outpost_effect2")}
                            `),t.race.lone_survivor&&(e+=`
                            ${z("city_wardenclyffe_effect1",[ta(1),t.civic.professor.name])}
                            `),e+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,e},powered:()=>As(t.tech.isolation?t.race.lone_survivor?8:25:100),special:()=>!!t.tech.replicator,action:()=>!1},jump_gate:{id:"tauceti-jump_gate",title:z("tau_jump_gate"),desc:e=>!t.tauceti.hasOwnProperty("jump_gate")||t.tauceti.jump_gate.count<100||e?`
                            ${z("tau_jump_gate")}
                            ${z("requires_segmemts",[100])}
                            `:`
                            ${z("tau_jump_gate")}
                            `,reqs:{tauceti:3},condition:()=>t.tech.isolation?0:1,path:["truepath"],queue_size:10,queue_complete:()=>100-t.tauceti.jump_gate.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0)<100?1e6:0,Materials:e=>(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0)<100?12500:0},effect(e){let a=(e||0)+(t.tauceti.hasOwnProperty("jump_gate")?t.tauceti.jump_gate.count:0);if(a<100){let e=100-a;return`
                            ${z("tau_jump_gate_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}return z("tau_jump_gate_effect")},action(){return!!(ri($(this)[0])&&t.tauceti.jump_gate.count<100)&&(t.tauceti.jump_gate.count++,!0)}},fusion_generator:{id:"tauceti-fusion_generator",title:z("tech_fusion_generator"),desc:()=>`
                            ${z("tech_fusion_generator")}
                            ${z("requires_res",[t.resource.Helium_3.name])}
                            `,reqs:{tau_home:6},path:["truepath"],cost:{Money:e=>Ps("fusion_generator",e,188e6,1.25,"tauceti"),Iridium:e=>Ps("fusion_generator",e,555e4,1.25,"tauceti"),Stanene:e=>Ps("fusion_generator",e,7003500,1.25,"tauceti"),Sheet_Metal:e=>Ps("fusion_generator",e,Ve(95e3),1.25,"tauceti")},effect(){let e=+Ht($(this)[0].p_fuel().a).toFixed(1),a=`
                            ${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
                            `;return t.race.lone_survivor?a+=`
                            ${z("gain",[-e,t.resource[$(this)[0].p_fuel().r].name])}
                            `:a+=`
                            ${z("spend",[e,t.resource[$(this)[0].p_fuel().r].name])}
                            `,a},p_fuel:()=>({r:"Helium_3",a:t.tech.isolation?t.race.lone_survivor?-15:75:500}),powered:()=>Fs(-32),action(){return!!ri($(this)[0])&&(t.tauceti.fusion_generator.count++,t.tauceti.fusion_generator.on++,!0)}},repository:{id:"tauceti-repository",title:z("tech_repository"),desc:z("tech_repository"),reqs:{tau_home:5},path:["truepath"],cost:{Money:e=>Ps("repository",e,1028e4,1.28,"tauceti"),Iron:e=>Ps("repository",e,18e5,1.28,"tauceti"),Cement:e=>Ps("repository",e,15e5,1.28,"tauceti"),Neutronium:e=>Ps("repository",e,215e3,1.28,"tauceti")},wide:!0,res(){let e=["Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Crystal","Alloy","Polymer","Iridium","Chrysotile","Nano_Tube","Neutronium","Adamantite","Unobtainium"];return t.tech.isolation&&(e.push("Oil"),e.push("Helium_3"),e.push("Uranium"),e.push("Water")),e},val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 3e4;case"Crystal":return 10;case"Furs":return 17e3;case"Copper":return 15200;case"Iron":return 14e3;case"Aluminium":return 12800;case"Cement":return 11200;case"Coal":return 4800;case"Steel":return 2400;case"Titanium":return 1600;case"Alloy":return 1800;case"Polymer":return 1500;case"Iridium":return 1750;case"Nano_Tube":return 1200;case"Neutronium":return 640;case"Adamantite":return 720;case"Unobtainium":return 1e3;case"Oil":return 680;case"Helium_3":return 575;case"Uranium":return 125;case"Water":return 15;case"Elerium":return 3;default:return 0}},effect(){let e='
                            ',a=mt("repository");for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${z("plus_max_resource",[x(+(br($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return t.tech.isolation&&(e+=`${z("plus_max_resource",[250,z("resource_Crates_name")])}${z("plus_max_resource",[250,z("resource_Containers_name")])}`),e+="
                            ",e},action(){if(ri($(this)[0])){t.tauceti.repository.count++;let e=mt("repository");for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=br($(this)[0].val(a))*e);return!0}return!1}},tau_factory:{id:"tauceti-tau_factory",title:z("tau_home_tau_factory"),desc:()=>`
                            ${z("tau_home_tau_factory")}
                            ${z("requires_power_support",[Ki[t.race.species].home])}
                            `,reqs:{tau_home:8},path:["truepath"],cost:{Money:e=>Ps("tau_factory",e,269e6,1.25,"tauceti"),Titanium:e=>Ps("tau_factory",e,3e6,1.25,"tauceti"),Elerium:e=>Ps("tau_factory",e,850,1.25,"tauceti"),Bolognium:e=>Ps("tau_factory",e,25e4,1.25,"tauceti"),Quantium:e=>Ps("tau_factory",e,Ve(425e3),1.25,"tauceti")},effect(){let e=`
                            ${z("tau_new_support",[$(this)[0].support(),Ki[t.race.species].home])}
                            `;return e+=`
                            ${z("tau_home_tau_factory_effect",[t.tech.isolation?5:3])}
                            `,t.tech.isolation&&(t.race.flier||(e+=`
                            ${z("city_cement_plant_effect1",[ta(2)])}
                            `),e+=`
                            ${z("space_red_fabrication_effect1",[ta(5)])}
                            `),e+=`
                            ${z("city_crafted_mats",[t.tech.isolation?275:90])}
                            `,e+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,e},special:!0,support:()=>-1,powered:()=>As(t.tech.isolation?2:5),action(){return!!ri($(this)[0])&&(t.tauceti.tau_factory.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.tau_factory.on++,!0)}},infectious_disease_lab:{id:"tauceti-infectious_disease_lab",title:()=>t.tech.isolation?z("tech_infectious_disease_lab_alt"):z(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),desc(){return`
                            ${$(this)[0].title()}
                            ${z("requires_power_support",[Ki[t.race.species].home])}
                            `},reqs:{disease:1},path:["truepath"],cost:{Money:e=>Ps("infectious_disease_lab",e,1e9,1.25,"tauceti"),Alloy:e=>Ps("infectious_disease_lab",e,325e5,1.25,"tauceti"),Polymer:e=>Ps("infectious_disease_lab",e,5e7,1.25,"tauceti"),Bolognium:e=>Ps("infectious_disease_lab",e,25e5,1.25,"tauceti"),Unobtainium:e=>Ps("infectious_disease_lab",e,64e3,1.25,"tauceti")},effect(){let e=39616;if(t.tech.supercollider&&t.tech.isolation){let a=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}let a=`
                            ${z("tau_new_support",[$(this)[0].support(),Ki[t.race.species].home])}
                            `;return a+=`
                            ${z("city_max_knowledge",[Math.round(e).toLocaleString()])}
                            `,t.tech.isolation&&(a+=`
                            ${z("plus_max_resource",[br(375),z("resource_Elerium_name")])}
                            `,a+=`
                            ${z("city_wardenclyffe_effect1",[ta(2),t.civic.professor.name])}
                            `,a+=`
                            ${z("city_wardenclyffe_effect1",[ta(1),t.civic.scientist.name])}
                            `,a+=`
                            ${z("space_zero_g_lab_effect",[ta(1)])}
                            `,a+=`
                            ${z("city_library_effect",[75])}
                            `),t.tech.alien_crafting&&(a+=`
                            ${z("tau_gas_womling_station_effect",[65,t.resource.Quantium.name])}
                            `),t.tech.focus_cure&&(a+=`
                            ${z("tau_home_disease_lab_cure",[+t.tauceti.infectious_disease_lab.cure.toFixed(1)])}
                            `,t.race.hasOwnProperty("vax")&&(a+=`
                            ${z("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
                            `)),a+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,a},support:()=>-1,powered:()=>As(t.tech.isolation?t.race.lone_survivor?2:8:35),action(){return!!ri($(this)[0])&&(t.tauceti.infectious_disease_lab.count++,t.tauceti.orbital_station.support-$(this)[0].support()<=t.tauceti.orbital_station.s_max&&t.tauceti.infectious_disease_lab.on++,!0)},post(){1===t.tech.disease&&(t.tech.disease=2,hs(z("tau_plague4",[z("tab_tauceti")]),"info",!1,["progress"]),Qr())}},tauceti_casino:{id:"tauceti-tauceti_casino",title:z("city_casino"),desc:z("city_casino"),category:"commercial",reqs:{gambling:1,isolation:1},cost:{Money:e=>Ps("tauceti_casino",e,145e4,1.35,"tauceti"),Furs:e=>Ps("tauceti_casino",e,95e3,1.35,"tauceti"),Cement:e=>Ps("tauceti_casino",e,12e4,1.35,"tauceti"),Plywood:e=>Ps("tauceti_casino",e,Ve(55e3),1.35,"tauceti")},effect(){let e=$(this)[0].citizens(),a=t.race.lone_survivor?"":`
                            ${z("plus_max_resource",[e,z("citizen")])}
                            `;return a+=Kr(),a+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,a},powered:()=>As(t.race.lone_survivor?1:2),action(){return!!ri($(this)[0])&&(t.tauceti.tauceti_casino.count++,t.race.joyless||(t.civic.entertainer.max+=ta(1),t.civic.entertainer.display=!0),Yr($(this)[0]),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),t.race.lone_survivor?0:e},flair:z("city_casino_flair")},tau_cultural_center:{id:"tauceti-tau_cultural_center",title:z("tech_cultural_center"),desc(){return`
                            ${z("tech_cultural_center")}
                            ${z("space_electrolysis_req",[t.resource[$(this)[0].p_fuel().r].name])}
                            `},category:"commercial",reqs:{tau_culture:1},path:["truepath"],cost:{Money:e=>Ps("tau_cultural_center",e,9145e4,1.35,"tauceti"),Copper:e=>Ps("tau_cultural_center",e,585e4,1.35,"tauceti"),Coal:e=>Ps("tau_cultural_center",e,465e3,1.35,"tauceti"),Polymer:e=>Ps("tau_cultural_center",e,3792e3,1.35,"tauceti")},effect(){let e=1;"corpocracy"===t.civic.govern.type?e=2:"socialist"===t.civic.govern.type&&(e=.8);let a=20*e,r=5*e,i=15*e,s=`
                            ${z("tau_home_cultureal_effect1",[$(this)[0].p_fuel().a,t.resource[$(this)[0].p_fuel().r].name,$(this)[0].title])}
                            `;return s+=`
                            ${z("city_tourist_center_effect3",[a])}
                            `,s+=`
                            ${z("city_tourist_center_effect4",[r])}
                            `,s+=`
                            ${z("tau_home_cultureal_effect2",[8,z("tau_red_womlings")])}
                            `,t.tech.tau_culture>=2&&(s+=`
                            ${z("tau_home_cultureal_effect3",[i,z(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)])}
                            `),s+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,s},powered:()=>As(1),p_fuel:()=>({r:"Food",a:t.race.lone_survivor?25:500}),action(){return!!ri($(this)[0])&&(t.tauceti.tau_cultural_center.count++,t.tauceti.tau_cultural_center.on++,!0)}}},tau_red:{info:{name:()=>z("tau_planet",[Ut().red]),desc:()=>z("tau_red",[Ut().red]),support:"orbital_platform",extra(e){t.tech.tau_red&&t.tech.tau_red>=5&&($(`#${e}`).append(`
                            ${z("tau_red_womling_prod")} {{ prod }}%
                            `),Cs({el:`#${e}Womlings`,data:t.tauceti.overseer}))}},red_mission:{id:"tauceti-red_mission",title:()=>z("tau_new_mission_title",[Ut().red]),desc:()=>z("tau_new_mission_title",[Ut().red]),reqs:{tauceti:2},grant:["tau_red",1],path:["truepath"],queue_complete:()=>t.tech.tau_red>=1?0:1,cost:{Money:()=>1e9},effect:()=>z("tau_new_mission_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.tauceti.settlement={count:0,on:0},hs(z("tau_red_mission_result",[Ut().red]),"info",!1,["progress"]),!0)}},orbital_platform:{id:"tauceti-orbital_platform",title:z("tau_red_orbital_platform"),desc:`
                            ${z("tau_red_orbital_platform")}
                            ${z("requires_power")}
                            `,reqs:{tau_red:1,tauceti:4},path:["truepath"],cost:{Money:e=>Ps("orbital_platform",e,5e7,1.3,"tauceti"),Oil:e=>{return Qe()?Ps("orbital_platform",e,Ht((a=275e3,t.tech.womling_tech&&t.tech.womling_logistics&&t.tech.womling_logistics>=2&&(a*=.94**t.tech.womling_tech),a)),1.3,"tauceti"):0;var a},Aluminium:e=>Ps("orbital_platform",e,178e4,1.3,"tauceti"),Bolognium:e=>Ps("orbital_platform",e,45e4,1.3,"tauceti")},effect(){let e=br(17500),a=+Ht($(this)[0].support_fuel().a).toFixed(1),r=`
                            ${z("space_red_spaceport_effect1",[z("tau_planet",[Ut().red]),$(this)[0].support()])}
                            `;return r+=`
                            ${z("plus_max_resource",[e.toLocaleString(),t.resource.Oil.name])}
                            `,r+=`
                            ${z("spend_power",[a,t.resource[$(this)[0].support_fuel().r].name,$(this)[0].powered()])}
                            `,r},support_fuel:()=>({r:t.race.lone_survivor?"Helium_3":"Oil",a:t.tech.isolation?t.race.lone_survivor?8:32:125}),support(){let e=t.tech.womling_logistics?2.5:2;return t.race.lone_survivor&&(e*=2),e},powered:()=>As(t.tech.isolation?t.race.lone_survivor?2:3:18),refresh:!0,action(){return!(!Qe()||!ri($(this)[0])||(t.tauceti.orbital_platform.count++,Yr($(this)[0]),1===t.tech.tau_red&&(t.tech.tau_red=2,hs(z("tau_red_orbital_platform_msg",[z("tau_planet",[Ut().red]),z("tau_planet",[Ki[t.race.species].home])]),"info",!1,["progress"])),0))}},contact:{id:"tauceti-contact",title:()=>z("tau_red_contact"),desc:()=>z("tau_red_contact"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Money:()=>6e8,Food:()=>t.race.lone_survivor&&t.race.artifical?62e3:25e5},effect:()=>z("tau_red_contact_effect"),action(){return!!ri($(this)[0])&&(t.race.womling_friend=1,Ue(),!0)}},introduce:{id:"tauceti-introduce",title:()=>z("tau_red_introduce"),desc:()=>z("tau_red_introduce"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Knowledge:()=>7e6},effect:()=>z("tau_red_introduce_effect"),action(){return!!ri($(this)[0])&&(t.race.womling_god=1,Ue(),!0)}},subjugate:{id:"tauceti-subjugate",title:()=>z("tau_red_subjugate"),desc:()=>z("tau_red_subjugate"),reqs:{tau_red:4},grant:["tau_red",5],path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{Money:()=>285e7},effect:()=>z("tau_red_subjugate_effect"),action(){return!!ri($(this)[0])&&(t.race.womling_lord=1,Ue(),!0)}},jeff:{id:"tauceti-jeff",title:()=>z("tau_red_jeff"),desc:()=>z("tau_red_jeff"),reqs:{tau_red:5},path:["truepath"],queue_complete:()=>t.tech.tau_red>=5?0:1,cost:{},effect(){let e=t.tauceti.overseer?t.tauceti.overseer.injured:0;t.tauceti.overseer&&t.tauceti.overseer.pop${z("tau_red_jeff_effect1",[t.tauceti.overseer?t.tauceti.overseer.pop:0])}
                            `;return a+=`
                            ${z("tau_red_jeff_effect2",[t.tauceti.overseer?t.tauceti.overseer.working:0])}
                            `,a+=`
                            ${z("tau_red_jeff_effect3",[e])}
                            `,a+=`
                            ${z("tau_red_jeff_effect4",[t.tauceti.overseer?t.tauceti.overseer.loyal:0])}
                            `,a+=`
                            ${z("tau_red_jeff_effect5",[t.tauceti.overseer?t.tauceti.overseer.morale:0])}
                            `,t.tech.hasOwnProperty("womling_tech")&&(a+=`
                            ${z("tau_red_jeff_effect6",[t.tech.womling_tech])}
                            `),a+=`
                            ${z("job_farmer")}: ${t.tauceti.womling_farm?t.tauceti.womling_farm.farmers:0}
                            `,a+=`
                            ${z("job_miner")}: ${t.tauceti.womling_mine?t.tauceti.womling_mine.miners:0}
                            `,t.tauceti.womling_lab&&(a+=`
                            ${z("job_scientist")}: ${t.tauceti.womling_lab?t.tauceti.womling_lab.scientist:0}
                            `),a},action:()=>!1},overseer:{id:"tauceti-overseer",title(){return $(this)[0].name()},desc(){return`
                            ${$(this)[0].name()}
                            ${z("space_support",[Ut().red])}
                            `},name:()=>t.race.womling_lord?z("tau_red_overseer"):t.race.womling_god?z("tau_red_womgod"):z("tau_red_womally"),reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Ps("overseer",e,6e6,1.28,"tauceti"),Cement:e=>Ps("overseer",e,245e4,1.28,"tauceti"),Alloy:e=>t.race.womling_friend?Ps("overseer",e,185e4,1.28,"tauceti"):0,Neutronium:e=>t.race.womling_lord?Ps("overseer",e,165e3,1.28,"tauceti"):0,Titanium:e=>t.race.womling_god?Ps("overseer",e,225e4,1.28,"tauceti"):0},effect(){let e=`
                            ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                            `;return e+=`
                            ${z("tau_red_overseer_effect",[$(this)[0].val()])}
                            `,e},val(){let e=0;return t.race.womling_lord?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?12:10:t.race.womling_god?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?6:5:t.race.womling_friend&&(e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?10:8),t.race.lone_survivor&&(e*=2),e},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.overseer.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.overseer.on++,!0)}},womling_village:{id:"tauceti-womling_village",title:z("tau_red_womling_village"),desc:()=>`
                            ${z("tau_red_womling_village")}
                            ${z("space_support",[Ut().red])}
                            `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Ps("womling_village",e,1e7,1.28,"tauceti"),Stone:e=>Ps("womling_village",e,225e4,1.28,"tauceti"),Plywood:e=>Ps("womling_village",e,Ve(125e4),1.28,"tauceti"),Wrought_Iron:e=>Ps("womling_village",e,Ve(4e5),1.28,"tauceti")},effect(){let e=t.tech.womling_pop&&t.tech.womling_pop>=2?6:5,a=`
                            ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                            `;return a+=`
                            ${z("tau_red_womling_village_effect",[e])}
                            `,t.tech.tau_junksale&&(a+=`
                            ${z("tau_red_womling_village_effect2",[40,z(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`)])}
                            `),a},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_village.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_village.on++,!0)}},womling_farm:{id:"tauceti-womling_farm",title:z("tau_red_womling_farm"),desc:()=>`
                            ${z("tau_red_womling_farm")}
                            ${z("space_support",[Ut().red])}
                            `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Ps("womling_farm",e,24e6,1.28,"tauceti"),Iron:e=>Ps("womling_farm",e,95e5,1.28,"tauceti"),Water:e=>Ps("womling_farm",e,5e3,1.28,"tauceti")},effect(){let e=t.tech.womling_pop?16:12;t.tech.womling_gene&&(e+=4);let a=t.tauceti.hasOwnProperty("womling_farm")?t.tauceti.womling_farm.farmers:0,r=`
                            ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                            `;return r+=`
                            ${z("tau_red_womling_farm_effect",[e])}
                            `,r+=`
                            ${z("tau_red_womling_employ",[2])}
                            `,t.tech.isolation&&(r+=`
                            ${z("tau_red_womling_generate",[t.resource.Furs.name])}
                            `),r+=`
                            ${z("tau_red_womling_farm_effect2",[e/2*a])}
                            `,r},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_farm.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_farm.on++,!0)}},womling_mine:{id:"tauceti-womling_mine",title:z("tau_red_womling_mine"),desc:()=>`
                            ${z("tau_red_womling_mine")}
                            ${z("space_support",[Ut().red])}
                            `,reqs:{tau_red:5},path:["truepath"],cost:{Money:e=>Ps("womling_mine",e,125e5,1.28,"tauceti"),Lumber:e=>Ps("womling_mine",e,128e5,1.28,"tauceti"),Steel:e=>Ps("womling_mine",e,45e5,1.28,"tauceti")},effect(){let e=`
                            ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                            `;return t.tech.isolation?t.race.lone_survivor?e+=`
                            ${z("tau_red_womling_mine_effect_c",[t.resource.Unobtainium.name,t.resource.Uranium.name,t.resource.Titanium.name,t.resource.Iron.name,t.resource.Copper.name,t.resource.Aluminium.name,t.resource.Neutronium.name,t.resource.Iridium.name])}
                            `:e+=`
                            ${z("tau_red_womling_mine_effect_b",[t.resource.Unobtainium.name,t.resource.Uranium.name,t.resource.Titanium.name])}
                            `:e+=`
                            ${z("tau_red_womling_mine_effect_a",[t.resource.Unobtainium.name])}
                            `,e+=`
                            ${z("tau_red_womling_employ",[6])}
                            `,e},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_mine.count++,t.resource.Unobtainium.display=!0,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_mine.on++,!0)},flair:()=>z("tau_red_womling_mine_flair")},womling_fun:{id:"tauceti-womling_fun",title(){return $(this)[0].name()},desc(){return`
                            ${$(this)[0].name()}
                            ${z("space_support",[Ut().red])}
                            `},name:()=>t.race.womling_lord?z("tau_red_womling_fun1"):t.race.womling_god?z("tau_red_womling_fun2"):z("tau_red_womling_fun3"),reqs:{tau_red:6},path:["truepath"],cost:{Money:e=>Ps("womling_fun",e,38e5,1.28,"tauceti"),Food:e=>t.race.womling_friend?Ps("womling_fun",e,175e3,1.28,"tauceti"):0,Lumber:e=>Ps("womling_fun",e,5e5,1.28,"tauceti"),Stone:e=>Ps("womling_fun",e,5e5,1.28,"tauceti"),Furs:e=>t.race.womling_lord||t.race.womling_god?Ps("womling_fun",e,835e3,1.28,"tauceti"):0,Copper:e=>t.race.womling_lord?Ps("womling_fun",e,1125e3,1.28,"tauceti"):0,Alloy:e=>t.race.womling_god?Ps("womling_fun",e,656e3,1.28,"tauceti"):0,Water:e=>t.race.womling_friend?Ps("womling_fun",e,3500,1.28,"tauceti"):0},effect(){let e=`
                            ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                            `;return e+=`
                            ${z("tau_red_womling_fun_effect",[$(this)[0].val()])}
                            `,e},val(){let e=0;return t.race.womling_lord?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?24:20:t.race.womling_god?e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?12:10:t.race.womling_friend&&(e=t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5?18:15),t.race.lone_survivor&&(e*=2),e},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_fun.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_fun.on++,!0)}},womling_lab:{id:"tauceti-womling_lab",title:z("interstellar_laboratory_title"),desc:()=>`
                            ${z("interstellar_laboratory_title")}
                            ${z("space_support",[Ut().red])}
                            `,reqs:{tau_red:7},path:["truepath"],cost:{Money:e=>Ps("womling_lab",e,65e6,1.28,"tauceti"),Elerium:e=>Ps("womling_lab",e,1200,1.28,"tauceti"),Orichalcum:e=>Ps("womling_lab",e,25e5,1.28,"tauceti"),Unobtainium:e=>Ps("womling_lab",e,1e4,1.28,"tauceti"),Quantium:e=>Ps("womling_lab",e,Ve(95e3),1.28,"tauceti")},effect(){let e=t.tauceti.hasOwnProperty("overseer")?t.tauceti.overseer.prod:100,a=Math.round(25e3*e/100),r=`
                            ${z("tau_new_support",[$(this)[0].support(),Ut().red])}
                            `;return r+=`
                            ${z("tau_red_womling_lab_effect",[a])}
                            `,r+=`
                            ${z("tau_red_womling_employ_single",[1])}
                            `,r},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.womling_lab.count++,t.tauceti.orbital_platform.support-$(this)[0].support()<=t.tauceti.orbital_platform.s_max&&t.tauceti.womling_lab.on++,!0)}}},tau_gas:{info:{name(e,a){let r=a||"gas_name",i="gas_name"===r?0:1;if(e||t.race[r])switch(e||t.race[r]){case 1:{let e="antimatter"===t.race.universe?"plasmid":"antiplasmid";switch(Math.round(t.stats[e]+i)%3){case 1:return z("tau_planet",[Ut().gas]);case 2:return z("tau_gas_title0a",[Ut().gas]);default:return z("tau_gas_title0b",[Ut().gas])}}case 2:switch(Math.round(t.stats.reset+i)%3){case 1:return z("tau_gas_title1a");case 2:return z("tau_gas_title1b");default:return z("tau_gas_title1c")}case 3:switch(Math.round(t.stats.mad+i)%3){case 1:return z("tau_gas_title2a");case 2:return z("tau_gas_title2b");default:return z("tau_gas_title2c")}case 4:switch(Math.round(t.stats.bioseed+i)%3){case 1:return z("tau_gas_title3a",[Ki[t.race.gods].solar.gas]);case 2:return z("tau_gas_title3b",[Ki[t.race.old_gods].name]);default:return z("tau_gas_title3c",[Ki[t.race.species].name])}case 5:switch(Math.round(t.stats.portals+i)%3){case 1:return z("tau_gas_title4a",[Ut().gas]);case 2:return z("tau_gas_title4b",[nn("reverse",Ut().gas)]);default:return z("tau_gas_title4c")}case 6:switch(Math.round(t.stats.womling.friend.l+t.stats.womling.lord.l+t.stats.womling.god.l+i)%3){case 1:return z("tau_gas_title5a");case 2:return z("tau_gas_title5b");default:return z("tau_gas_title5c")}case 7:switch(Math.round(t.stats.tdays+i)%3){case 1:return z("tau_gas_title6a");case 2:return z("tau_gas_title6b");default:return z("tau_gas_title6c")}default:return z("gas_name"===r?"tau_gas_title":"tau_gas2_title")}return z("gas_name"===r?"tau_gas_title":"tau_gas2_title")},desc:()=>z("tau_gas_desc")},gas_contest:{id:"tauceti-gas_contest",title:()=>z("tau_gas_contest_title"),desc:()=>z("tau_gas_contest_title"),reqs:{tauceti:5},grant:["tau_gas",1],path:["truepath"],queue_complete:()=>t.tech.tau_gas>=1?0:1,cost:{Money:()=>1e7},effect:()=>t.race.lone_survivor?z("tau_gas_contest_effect_alt"):z("tau_gas_contest_effect"),action(){return!!ri($(this)[0])}},refueling_station:{id:"tauceti-refueling_station",title:()=>z("tau_gas_refueling_station_title"),desc:()=>`
                            ${z("tau_gas_refueling_station_title")}
                            ${z("requires_power")}
                            `,reqs:{tau_gas:2},path:["truepath"],cost:{Money:e=>Ps("refueling_station",e,68e6,1.28,"tauceti"),Graphene:e=>Ps("refueling_station",e,25e5,1.28,"tauceti"),Unobtainium:e=>Ps("refueling_station",e,5500,1.28,"tauceti"),Mythril:e=>Ps("refueling_station",e,Ve(6e4),1.28,"tauceti")},powered:()=>As(t.tech.isolation?2:5),effect(){let e=+$e("refueling_station").toFixed(2),a=br(1e4),r=`
                            ${z("space_gas_mining_effect1",[e])}
                            `;return r+=`
                            ${z("plus_max_resource",[a.toLocaleString(),t.resource.Helium_3.name])}
                            `,t.tech.tau_whale>=2&&(r+=`
                            ${z("plus_max_resource",[br(6500).toLocaleString(),t.resource.Oil.name])}
                            `),t.tech.isolation&&(r+=`
                            ${z("interstellar_g_factory_effect")}
                            `),r+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,r},special:()=>!!t.tech.isolation,action(){return!!ri($(this)[0])&&(t.tauceti.refueling_station.count++,Yr($(this)[0]),!0)},post(){2===t.tech.tau_gas&&(t.tech.tau_gas=3,Qr())}},ore_refinery:{id:"tauceti-ore_refinery",title:()=>z("tau_gas_ore_refinery_title"),desc:()=>`
                            ${z("tau_gas_ore_refinery_title")}
                            ${z("requires_power")}
                            `,reqs:{tau_gas:4},path:["truepath"],cost:{Money:e=>Ps("ore_refinery",e,52e6,1.28,"tauceti"),Iridium:e=>Ps("ore_refinery",e,16e5,1.28,"tauceti"),Unobtainium:e=>Ps("ore_refinery",e,800,1.28,"tauceti"),Sheet_Metal:e=>Ps("ore_refinery",e,Ve(118e3),1.28,"tauceti")},powered:()=>As(t.tech.isolation?2:8),effect(){let e=t.tauceti.hasOwnProperty("ore_refinery")?t.tauceti.ore_refinery.fill:0,a=t.tauceti.hasOwnProperty("ore_refinery")?t.tauceti.ore_refinery.max:0,r=+$e("ore_refinery").toFixed(2),i=`
                            ${z("tau_gas_ore_refinery_effect",[+e.toFixed(2)])}
                            `;return i+=`
                            ${z("tau_gas_ore_refinery_effect2",[a])}
                            `,i+=`
                            ${z("tau_gas_ore_refinery_effect3",[r])}
                            `,i+=`
                            ${z("interstellar_stellar_forge_effect3",[t.tech.isolation?12:4])}
                            `,i+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,i},special:!0,action(){return!!ri($(this)[0])&&(t.tauceti.ore_refinery.count++,t.city.powered&&t.city.power>=$(this)[0].powered()&&(t.tauceti.ore_refinery.on++,t.city.smelter.cap+=t.tech.isolation?12:2,t.city.smelter.Steel+=t.tech.isolation?12:2,t.race.evil?t.city.smelter.Wood+=t.tech.isolation?12:2:t.city.smelter.Oil+=t.tech.isolation?12:2),!0)},post(){3===t.tech.tau_roid&&(t.tech.tau_roid=4,Je(),Qr())}},whaling_station:{id:"tauceti-whaling_station",title:()=>z("tau_gas_whaling_station_title"),desc:()=>`
                            ${z("tau_gas_whaling_station_title")}
                            ${z("requires_power")}
                            `,reqs:{tau_whale:1},path:["truepath"],cost:{Money:e=>Ps("whaling_station",e,72e6,1.28,"tauceti"),Steel:e=>Ps("whaling_station",e,18e5,1.28,"tauceti"),Polymer:e=>Ps("whaling_station",e,955e3,1.28,"tauceti"),Orichalcum:e=>Ps("whaling_station",e,268e3,1.28,"tauceti")},powered:()=>As(t.tech.isolation?2:6),effect(){let e=t.tauceti.hasOwnProperty("whaling_station")?t.tauceti.whaling_station.fill:0,a=t.tauceti.hasOwnProperty("whaling_station")?t.tauceti.whaling_station.max:0,r=+$e("whaling_station").toFixed(2),i=`
                            ${z("tau_gas_whaling_station_effect",[+e.toFixed(2)])}
                            `;return i+=`
                            ${z("tau_gas_whaling_station_effect2",[a])}
                            `,i+=`
                            ${z("tau_gas_whaling_station_effect3",[r])}
                            `,i+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,i},action(){return!!ri($(this)[0])&&(t.tauceti.whaling_station.count++,Yr($(this)[0]),!0)},post(){1===t.tech.tau_whale&&(t.tech.tau_whale=2,Je())}},womling_station:{id:"tauceti-womling_station",title:()=>z("tau_gas_womling_station_title"),desc:()=>`
                            ${z("tau_gas_womling_station_desc")}
                            ${z("requires_power")}
                            `,reqs:{womling_technicians:1},path:["truepath"],cost:{Money:e=>Ps("womling_station",e,1334e5,1.26,"tauceti"),Furs:e=>Ps("womling_station",e,3805e3,1.26,"tauceti"),Aluminium:e=>Ps("womling_station",e,85e5,1.26,"tauceti"),Nano_Tube:e=>Ps("womling_station",e,909e3,1.26,"tauceti")},powered:()=>As(t.tech.isolation?3:6),effect(){let e=t.tech.isolation?30:8;t.tech.womling_gene&&(e*=1.25);let a=`
                            ${z("tau_gas_womling_station_effect",[e,Re.tau_gas.info.name()])}
                            `;return t.race.flier||(a+=`
                            ${z("city_cement_plant_effect1",[ta(1)])}
                            `),a+=`
                            ${z("space_red_fabrication_effect1",[ta(1)])}
                            `,a+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,a},action(){return!!ri($(this)[0])&&(t.tauceti.womling_station.count++,Yr($(this)[0]),!0)}}},tau_roid:{info:{name:()=>z("tau_roid_title"),desc:()=>z("tau_roid_desc"),support:"patrol_ship"},roid_mission:{id:"tauceti-roid_mission",title:()=>z("space_mission_title",[z("tau_roid_title")]),desc:()=>z("space_mission_desc",[z("tau_roid_title")]),reqs:{tauceti:5},grant:["tau_roid",1],path:["truepath"],queue_complete:()=>t.tech.tau_roid>=1?0:1,cost:{Helium_3:(e,t)=>+Ht(125e4).toFixed(0)},effect:()=>z("tau_roid_mission_effect",[z("tau_roid_title")]),action(){return!!ri($(this)[0])&&(hs(z("tau_roid_mission_result"),"info",!1,["progress"]),!0)}},patrol_ship:{id:"tauceti-patrol_ship",title:z("tau_roid_patrol_ship"),desc:()=>`
                            ${z("tau_roid_patrol_ship")}
                            ${z("requires_res",[t.resource.Helium_3.name])}
                            `,reqs:{tau_roid:3},path:["truepath"],cost:{Money:e=>Ps("patrol_ship",e,45e6,1.25,"tauceti"),Adamantite:e=>Ps("patrol_ship",e,18e5,1.25,"tauceti"),Elerium:e=>Ps("patrol_ship",e,520,1.25,"tauceti"),Stanene:e=>Ps("patrol_ship",e,2675e3,1.25,"tauceti"),Bolognium:e=>Ps("patrol_ship",e,115e4,1.25,"tauceti")},effect(){let e=+Ht($(this)[0].support_fuel().a).toFixed(1),a=`
                            ${z("tau_roid_patrol_ship_security",[$(this)[0].support()])}
                            `;return a+=`
                            ${z("tau_roid_patrol_ship_effect")}
                            `,a+=`
                            ${z("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
                            `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?15:250}),support:()=>1,powered:()=>As(1),refresh:!0,action(){return!!ri($(this)[0])&&(t.tauceti.patrol_ship.count++,t.tauceti.patrol_ship.on++,!0)}},mining_ship:{id:"tauceti-mining_ship",title:z("tau_roid_mining_ship"),desc:()=>`
                            ${z("tau_roid_mining_ship")}
                            `,reqs:{tau_roid:4},path:["truepath"],cost:{Money:e=>Ps("mining_ship",e,28e6,1.28,"tauceti"),Uranium:e=>Ps("mining_ship",e,12500,1.28,"tauceti"),Titanium:e=>Ps("mining_ship",e,22e5,1.28,"tauceti"),Alloy:e=>Ps("mining_ship",e,175e4,1.28,"tauceti")},effect(){let e=+Ht($(this)[0].support_fuel().a).toFixed(1),a=`
                            ${z("tau_roid_mining_ship_effect",[+$e("mining_ship").toFixed(2)])}
                            `;return a+=`
                            ${z("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
                            `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?12:75}),support:()=>-1,powered:()=>As(1),special:!0,action(){return!!ri($(this)[0])&&(t.tauceti.mining_ship.count++,t.tauceti.mining_ship.on++,!0)}},whaling_ship:{id:"tauceti-whaling_ship",title:z("tau_roid_whaling_ship"),desc:()=>`
                            ${z("tau_roid_whaling_ship")}
                            `,reqs:{tau_whale:2},path:["truepath"],cost:{Money:e=>Ps("whaling_ship",e,35e6,1.28,"tauceti"),Aluminium:e=>Ps("whaling_ship",e,34e5,1.28,"tauceti"),Neutronium:e=>Ps("whaling_ship",e,168e3,1.28,"tauceti"),Nano_Tube:e=>Ps("whaling_ship",e,8e5,1.28,"tauceti")},effect(){let e=+Ht($(this)[0].support_fuel().a).toFixed(1),a=`
                            ${z("tau_roid_whaling_ship_effect",[+$e("whaling_ship").toFixed(2)])}
                            `;return a+=`
                            ${z("spend",[e,t.resource[$(this)[0].support_fuel().r].name])}
                            `,a},support_fuel:()=>({r:"Helium_3",a:t.tech.isolation?14:90}),support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.tauceti.whaling_ship.count++,t.tauceti.whaling_ship.on++,!0)}}},tau_gas2:{info:{name:e=>Re.tau_gas.info.name(e||t.race.gas_name2||!1,"gas_name2"),desc:()=>z("tau_gas2_desc",[Re.tau_gas.info.name()])},gas_contest2:{id:"tauceti-gas_contest2",title:()=>z("tau_gas2_contest_title"),desc:()=>z("tau_gas2_contest_title"),reqs:{tau_gas2:1},grant:["tau_gas2",2],path:["truepath"],queue_complete:()=>t.tech.tau_gas2>=1?0:1,cost:{Money:()=>25e6},effect:()=>z("tau_gas2_contest_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tau_gas2_contest_flair")},alien_station_survey:{id:"tauceti-alien_station_survey",title:z("tau_gas2_alien_station"),desc:z("tau_gas2_alien_station"),reqs:{tau_gas2:3},grant:["tau_gas2",4],path:["truepath"],queue_complete:()=>t.tech.tau_gas3>=4?0:1,cost:{Money:()=>t.race.lone_survivor?15e8:3e9,Helium_3:()=>5e6},effect:()=>z("tau_gas2_alien_station_repair_effect",[Re.tau_gas2.info.name()]),action(){return!!ri($(this)[0])&&(t.tauceti.alien_station={count:0},hs(z("tau_gas2_alien_station_msg",[Re.tau_gas2.info.name()]),"info",!1,["progress"]),!0)}},alien_station:{id:"tauceti-alien_station",title:z("tau_gas2_alien_station"),desc:e=>!t.tauceti.hasOwnProperty("alien_station")||t.tauceti.alien_station.count<100||e?`
                            ${z("tau_gas2_alien_station")}
                            `+(t.tauceti.hasOwnProperty("alien_station")&&t.tauceti.alien_station.count>=100?`
                            ${z("space_dwarf_reactor_desc_req")}
                            `:`
                            ${z("tau_gas2_alien_station_repair")}
                            `):`
                            ${z("tau_gas2_alien_station")}
                            `,reqs:{tau_gas2:4},condition:()=>t.tauceti.alien_station.count<100,path:["truepath"],queue_size:5,queue_complete:()=>100-t.tauceti.alien_station.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?12e6:5e7:0,Aluminium:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?256e3:256e4:0,Polymer:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?198900:989e3:0,Mythril:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?Ve(125e3):0,Cipher:e=>(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0)<100?t.race.lone_survivor?256:2001:0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("alien_station")?t.tauceti.alien_station.count:0);return r<100?(a+=`
                            ${z("tau_gas2_alien_station_repaired",[r])}
                            `,a):Re.tau_gas2.alien_space_station.effect(e)},action(){return!!(ri($(this)[0])&&t.tauceti.alien_station.count<100)&&(t.tauceti.alien_station.count++,t.tauceti.alien_station.count>=100&&(t.tech.tau_gas2=5,t.tauceti.alien_space_station={count:1,on:0}),!0)},post(){t.resource.Elerium.diff>=10&&(t.tauceti.alien_space_station.on=1),Je()}},alien_space_station:{id:"tauceti-alien_space_station",title:z("tau_gas2_alien_station"),desc:()=>`
                            ${z("tau_gas2_alien_station")}
                            ${z("space_dwarf_reactor_desc_req")}
                            `,reqs:{tau_gas2:5},path:["truepath"],cost:{},queue_complete:()=>0,special:()=>!(!t.tech.tau_gas2||6!==t.tech.tau_gas2||t.tech.alien_data&&!(t.tech.alien_data<6)),wiki:!1,effect(){let e=$(this)[0].p_fuel().a,a=`
                            ${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
                            `;if(t.tech.tau_gas2&&t.tech.tau_gas2>=6&&t.tauceti.alien_space_station.hasOwnProperty("decrypted")){let e=t.race.lone_survivor?1e5:25e6,r=+(t.tauceti.alien_space_station.decrypted/e).toFixed(2);r>100&&(r=100),a+=`
                            ${z("tau_gas2_alien_station_effect",[r])}
                            `}return a+=`
                            ${z("spend",[e,t.resource[$(this)[0].p_fuel().r].name])}
                            `,a},p_fuel:()=>({r:"Elerium",a:t.race.lone_survivor?1:10}),powered:()=>Fs(-75),action:()=>!1},matrioshka_brain:{id:"tauceti-matrioshka_brain",title:z("tech_matrioshka_brain"),desc:e=>!t.tauceti.hasOwnProperty("matrioshka_brain")||t.tauceti.matrioshka_brain.count<1e3||e?`
                            ${z("tech_matrioshka_brain")}
                            ${z("requires_segmemts",[1e3])}
                            `:`
                            ${z("tech_matrioshka_brain")}
                            `,reqs:{tau_gas2:7},condition:()=>!!t.tauceti.matrioshka_brain,path:["truepath"],queue_size:50,queue_complete:()=>1e3-t.tauceti.matrioshka_brain.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?2e7:0,Neutronium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?45e3:0,Nano_Tube:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?16e4:0,Adamantite:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?666e3:0,Stanene:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?61600:0,Bolognium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?44e3:0,Unobtainium:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?1200:0,Mythril:e=>(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0)<1e3?Ve(64e3):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("matrioshka_brain")?t.tauceti.matrioshka_brain.count:0);return r<1e3&&(a+=`
                            ${z("tau_gas2_matrioshka_brain_seg",[1e3-r])}
                            `),a},action(){return!!(ri($(this)[0])&&t.tauceti.matrioshka_brain.count<1e3)&&(t.tauceti.matrioshka_brain.count++,t.tauceti.matrioshka_brain.count>=1e3&&(t.tech.m_brain=1),!0)}},ignition_device:{id:"tauceti-ignition_device",title:z("tech_ignition_device"),desc:e=>!t.tauceti.hasOwnProperty("ignition_device")||t.tauceti.ignition_device.count<10||e?`
                            ${z("tech_ignition_device")}
                            ${z("requires_segmemts",[10])}
                            `:`
                            ${z("tech_ignition_device")}
                            `,reqs:{tau_gas2:8},condition:()=>!!(t.tauceti.ignition_device&&t.tauceti.ignition_device.count<10),path:["truepath"],queue_size:1,queue_complete:()=>10-t.tauceti.ignition_device.count,cost:{Money:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?25e7:0,Uranium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?5e4:0,Elerium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?25e3:0,Graphene:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?225e5:0,Orichalcum:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?15e6:0,Quantium:e=>(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0)<10?Ve(8e6):0},effect(e){let a="",r=(e||0)+(t.tauceti.hasOwnProperty("ignition_device")?t.tauceti.ignition_device.count:0);return r<10&&(a+=`
                            ${z("tau_gas2_ignition_device_seg",[10-r])}
                            `),a},action(){return!!(ri($(this)[0])&&t.tauceti.ignition_device.count<10)&&(t.tauceti.ignition_device.count++,t.tauceti.ignition_device.count>=10&&(t.tech.m_ignite=1),!0)}},ignite_gas_giant:{id:"tauceti-ignite_gas_giant",title:()=>z("tau_gas2_ignite_gas_giant",[Re.tau_gas2.info.name()]),desc:()=>z("tau_gas2_ignite_gas_giant",[Re.tau_gas2.info.name()]),reqs:{tau_gas2:8,m_ignite:1},grant:["m_ignite",2],queue_size:1,queue_complete:()=>!1,path:["truepath"],cost:{Helium_3:()=>75e5},effect(){let e=`
                            ${z("tau_gas2_ignite_gas_giant_effect",[z("tech_matrioshka_brain")])}
                            `;return t.tech.m_brain?(e+=`
                            ${z("tau_gas2_ignite_gas_giant_effect3")}
                            `,e+=function(){let e=Gs("retire"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name"),r=t.stats.retire+1===t.stats.matrix?`
                            ${z("tau_star_matrix_skilled",[1])}
                            `:"";return`
                            ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                            ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                            ${z("tau_star_matrix_servants",[1])}
                            ${r}`}()):e+=`
                            ${z("tau_gas2_ignite_gas_giant_effect2",[z("tech_matrioshka_brain")])}
                            `,e},action(){return!(!t.tech.m_brain||!ri($(this)[0])||(function(){P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"retire"});let a=t.race.species,r=t.race.gods,i=Ki[a].type,s=t.city.calendar.orbit,n=t.city.biome,c=t.city.ptrait,o=t.city.geology,l=Gs("retire");qn(`biome_${n}`),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),qn(`genus_${i}`),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),qn("retired"),U(),Sn(),t.stats.retire++,rn(),"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,t.prestige.AICore.count+=l.cores,t.stats.cores+=l.cores;let _=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},d>0&&(t.race.corruption=d),_&&(t.race.srace=_),H({orbit:s,biome:n,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),0))}}}};for(let e=1;e<9;e++)Re.tau_gas[`gas_contest-a${e}`]={id:`tauceti-gas_contest-a${e}`,title:()=>Re.tau_gas.info.name(e),desc:()=>Re.tau_gas.info.name(e),reqs:{tau_gas:1},grant:["tau_gas",2],path:["truepath"],wiki:!1,queue_complete:()=>t.tech.tau_gas>=2?0:1,cost:{},effect:()=>z(8===e?"tau_gas_contest_reject":"tau_gas_contest_pick",[Re.tau_gas.info.name(e)]),action(){return!!ri($(this)[0])&&(t.race.gas_name=e,t.tauceti.refueling_station={count:0,on:0},!0)}},Re.tau_gas2[`gas_contest-b${e}`]={id:`tauceti-gas_contest-b${e}`,title:()=>Re.tau_gas2.info.name(e),desc:()=>Re.tau_gas2.info.name(e),reqs:{tau_gas2:2},grant:["tau_gas2",3],path:["truepath"],wiki:!1,queue_complete:()=>t.tech.tau_gas2>=3?0:1,cost:{},effect:()=>z(8===e?"tau_gas2_contest_reject":"tau_gas_contest_pick",[Re.tau_gas2.info.name(e)]),action(){return!!ri($(this)[0])&&(t.race.gas_name2=e,!0)}};function He(){let e=Gs("matrix"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name"),r=t.stats.retire===t.stats.matrix+1?`
                            ${z("tau_star_matrix_skilled",[1])}
                            `:"";return`
                            ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                            ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                            ${z("tau_star_matrix_servants",[1])}
                            ${r}`}function Ue(){t.tauceti.overseer={count:0,on:0,pop:0,working:0,injured:0,morale:0,loyal:0,prod:0},t.tauceti.womling_village=t.race.lone_survivor?{count:2,on:2}:{count:1,on:1},t.tauceti.womling_mine=t.race.lone_survivor?{count:1,on:1,miners:0}:{count:0,on:0,miners:0},t.tauceti.womling_farm={count:1,on:1,farmers:0},t.tauceti.womling_fun={count:0,on:0}}function Ve(e){return t.tech.womling_tech&&t.tech.womling_recycling&&t.tech.womling_recycling>=1&&(e*=(t.tech.isolation?.97:.98)**t.tech.womling_tech),e}function We(){return Ne}function Qe(){return!!(t.tech.tauceti&&t.tech.tauceti>=4)}function Je(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||6!==t.settings.spaceTabs))return;let e=$("#tauceti");Ss(e),e.append($(`

                            ${z("tab_tauceti")}

                            `)),!t.tech.tauceti||t.tech.tauceti<2||Object.keys(Re).forEach((function(a){let r=a.replace("tau_","");if(t.settings.tau[`${r}`]){let r="string"==typeof Re[a].info.name?Re[a].info.name:Re[a].info.name(),i="";if(Re[a].info.hasOwnProperty("prop")&&(i=Re[a].info.prop()),Re[a].info.support){let s=Re[a].info.support;Re[a].info.hide_support?e.append(`

                            ${r}

                            ${i}
                            `):e.append(`

                            ${r}

                            {{ support }}/{{ s_max }}${i}
                            `),Cs({el:`#sr${a}`,data:t.tauceti[s],filters:{filter(){return Re[a].info.filter(...arguments)}}})}else e.append(`

                            ${r}

                            ${i}
                            `);ls(a,(function(){return"string"==typeof Re[a].info.desc?Re[a].info.desc:Re[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(Re[a]).forEach((function(e){"info"!==e&&Tt(Re,a,e)&&Zr(Re[a][e],"tauceti",e)})),Re[a].info.hasOwnProperty("extra")&&Re[a].info.extra(a)}}))}function Ze(){if((t.settings.tabLoad||2===t.settings.civTabs&&5===t.settings.govTabs)&&(pt(),nt(),Ss($("#dwarfShipYard")),t.space.hasOwnProperty("shipyard")&&t.settings.showShipYard)){let e=$("#dwarfShipYard");t.space.shipyard.hasOwnProperty("blueprint")||(t.space.shipyard.blueprint={class:"corvette",armor:"steel",weapon:"railgun",engine:"ion",power:"diesel",sensor:"radar",name:Xe()});let a=$('
                            ');e.append(a);let r=$('
                            ');a.append(r),r.append(`
                            ${z("outer_shipyard_registry")}:
                            `),r.append(`
                            ${z("crew")}
                            `),r.append(`
                            ${z("power")}
                            `),r.append(`
                            ${z("firepower")}
                            `),r.append(`
                            ${z("outer_shipyard_sensors")}
                            `),r.append(`
                            ${z("speed")}
                            `),r.append(`
                            ${z("outer_shipyard_fuel")}
                            `),a.append('
                            ');let i=$('
                            ');a.append(i);let s={class:["corvette","frigate","destroyer","cruiser","battlecruiser","dreadnought","explorer"],power:["solar","diesel","fission","fusion","elerium"],weapon:["railgun","laser","p_laser","plasma","phaser","disruptor"],armor:["steel","alloy","neutronium"],engine:["ion","tie","pulse","photon","vacuum","emdrive"],sensor:["visual","radar","lidar","quantum"]};Object.keys(s).forEach((function(e){let t="";s[e].forEach((function(a,r){t+=`${z(`outer_shipyard_${e}_${a}`)}`})),i.append(`\n ${t}\n `)}));let n=$('
                            ');n.append(``),n.append(`${z("outer_shipyard_fleet_details")}`),n.append(`${z("outer_shipyard_fleet_sort")}`),a.append(n),n.append(`
                            ${z("outer_shipyard_park",[Ut().dwarf])}${z("outer_shipyard_map")}`),Ye();let c={template:''};Cs({el:"#shipPlans",data:{b:t.space.shipyard.blueprint,s:t.space.shipyard},methods:{setVal(e,a){"class"===e&&"explorer"===a?(t.space.shipyard.blueprint.engine="emdrive",t.space.shipyard.blueprint.weapon="railgun",t.tech.syard_armor>=3&&(t.space.shipyard.blueprint.armor="neutronium"),t.tech.syard_sensor>=4&&(t.space.shipyard.blueprint.sensor="quantum"),t.tech.syard_power>=4&&(t.space.shipyard.blueprint.power="elerium")):"class"===e&&"explorer"!==a&&"explorer"===t.space.shipyard.blueprint.class&&(t.space.shipyard.blueprint.engine="ion"),t.space.shipyard.blueprint[e]=a,Ye()},avail(e,a,r){if(!("class"!==e&&"engine"!==e||!t.tech.tauceti||"emdrive"!==r&&"explorer"!==r))return!0;if("explorer"===t.space.shipyard.blueprint.class){if("weapon"===e)return 1===a;if("engine"===e)return 6===a;if("sensor"===e)return 4===a}return t.tech[`syard_${e}`]>a},crewText:()=>et(t.space.shipyard.blueprint),powerText(){let e=tt(t.space.shipyard.blueprint);return e<0?`${e}kW`:`${e}kW`},fireText:()=>at(t.space.shipyard.blueprint),sensorText:()=>_t(t.space.shipyard.blueprint)+"km",speedText(){let e=7.695363719135802*rt(t.space.shipyard.blueprint);return Math.round(e)+"km/s"},fuelText(){let e=it(t.space.shipyard.blueprint);return e.res?`-${e.burn} ${t.resource[e.res].name}`:"N/A"},build(){if(tt(t.space.shipyard.blueprint)>=0){let e=st(t.space.shipyard.blueprint),a={};if(Object.keys(e).forEach((function(t){a[t]=function(){return e[t]}})),ri(!1,a)){let e=sn(t.space.shipyard.blueprint);e.location="spc_dwarf",e.xy=ut("spc_dwarf"),e.origin=sn(e.xy),e.destination=sn(e.xy),e.transit=0,e.dist=0,e.damage=0,e.fueled=!1,0===e.name.length&&(e.name=Xe());let a=1,r=e.name;for(;t.space.shipyard.ships.filter((e=>e.name===r)).length>0;)a++,r=e.name+` ${a}`;e.name=r,t.space.shipyard.ships.push(e),ct(),Ye(),t.space.shipyard.blueprint.name=Xe()}}},trigModal(){this.$buefy.modal.open({parent:this,component:c});let e=setInterval((function(){$("#modalBox").length>0&&(clearInterval(e),$("#modalBox").append($('

                            Solar System

                            ')),function(e){let t=$('
                            ').appendTo(e),a={},r={},i=!1;yt={},ft=20,t.append($('').on("mouseup mouseover mouseout",(()=>i=!1)).on("mousedown",(e=>{i=!0,r.x=e.clientX-yt.x,r.y=e.clientY-yt.y})).on("mousemove",(e=>{i&&(yt.x=e.clientX-r.x,yt.y=e.clientY-r.y,bt())})).on("wheel",(e=>(e.originalEvent.deltaY<0?(ft/=.8,yt.x=a.x+(yt.x-a.x)/.8,yt.y=a.y+(yt.y-a.y)/.8,bt()):(ft*=.8,yt.x=a.x+.8*(yt.x-a.x),yt.y=a.y+.8*(yt.y-a.y),bt()),!1))),$('').on("click",(()=>{ft/=.8,yt.x=a.x+(yt.x-a.x)/.8,yt.y=a.y+(yt.y-a.y)/.8,bt()})),$('').on("click",(()=>{ft*=.8,yt.x=a.x+.8*(yt.x-a.x),yt.y=a.y+.8*(yt.y-a.y),bt()})));let s=document.getElementById("mapCanvas").getBoundingClientRect();a.x=s.width/2,a.y=s.height/2,yt.x=a.x,yt.y=a.y,bt()}($("#modalBox")))}),50)},redraw(){ct()}},filters:{lbl:(e,t)=>z(`outer_shipyard_${t}_${e}`)}}),Object.keys(s).forEach((function(e){for(let t=0;t<$(`#shipPlans .${e}`).length;t++)ls(`shipPlans${e}${t}`,(function(t){let a=$(t.this).attr("data-val");return z(`outer_shipyard_${e}_${a}_desc`)}),{elm:`#shipPlans .${e}.a${t}`,placement:"right"})})),e.append($('
                            ')),ct()}}function Xe(){let e=["Trident","Spacewolf","Excalibur","Neptune","Deimos","Phobos","Enterprise","Intrepid","Daedalus","Odyssey","Endurance","Horizon","Hyperion","Icarus","Aurora","Axiom","Nemesis","Normandy","Orion","Prometheus","Vanguard","Discovery","Voyager","Defiant","Titan","Liberty","Destiny","Phoenix","Nautilus","Barracuda","Dolphin","Cuttlefish","Tiger Shark","Stingray","Swordfish","Triton","Dragon","Scorpion","Hagfish","Marlin","Galileo","Raven","Sarcophagus","Excelsior","Scimitar","Vengeance","Nomad","Nova","Olympus","Aegis","Agamemnon","Charon","Achilles","Apollo","Hermes","Hydra","Medusa","Talos","Zeus","Heracles","Cerberus","Acheron","Damocles","Juno","Persephone","Solaris","Victory","Hawk","Fury","Razor","Stinger","Outrider","Falcon","Vulture","Nirvana","Retribution","Swordbreaker","Valkyrie","Athena","Avalon","Merlin","Argonaut","Serenity","Gunstar","Ranger","Tantive","Cygnus","Nostromo","Reliant","Narcissus","Liberator","Sulaco","Infinity","Resolute","Wasp","Hornet","Independence","Gilgamesh","Midway","Concordia","Goliath","Cosmos","Express","Tigers Claw","Oberon","Minnow","Majestic","Spartacus","Colossi","Vigilant","Remorseless","Caelestis","Inquisitor","Atlas","Avenger","Dauntless","Nihilus","Thanatos","Stargazer","Xyzzy","Kraken","Xerxes","Spitfire","McShipFace","Monitor","Merrimack","Constitution","Ghost","Pequod","Arcadia","Corsair","Inferno","Jenny","Revenge","Red October","Jackdaw","Thorn","Caleuche","Valencia","Ourang","Deering","Baychimo","Octavius","Joyita","Lovibond","Celeste","Dutchman"],a=e[Math.rand(0,e.length)];return t.space.shipyard.ships.filter((e=>e.name===a)).length>0&&(a=function(){let e=["al","an","ar","as","at","ea","ed","en","er","es","ha","he","hi","in","is","it","le","me","nd","ne","ng","nt","on","or","ou","re","se","st","te","th","ti","to","ve","wa","all","and","are","but","ent","era","ere","eve","for","had","hat","hen","her","hin","his","ing","ion","ith","not","ome","oul","our","sho","ted","ter","tha","the","thi","tio","uld","ver","was","wit","you"],t=Math.rand(2,5),a="";for(let r=0;r${t.resource[a].name}${x(e[a])}`):$("#shipYardCosts").append(` | ${t.resource[a].name} ${x(e[a])}`)}))}function et(e){switch(e.class){case"corvette":return ta(2);case"frigate":return ta(3);case"destroyer":return ta(4);case"cruiser":return ta(6);case"battlecruiser":return ta(8);case"dreadnought":case"explorer":return ta(10)}}function tt(e,t){let a=0,r=1,i=1;switch(e.class){case"frigate":r=1.1,i=1.2;break;case"destroyer":r=1.5,i=1.65;break;case"cruiser":r=2,i=2.5;break;case"battlecruiser":r=2.5,i=3.5;break;case"dreadnought":r=5,i=6.5;break;case"explorer":r=6,i=2}switch(e.power){case"solar":a=Math.round(50*r);break;case"diesel":a=Math.round(100*r);break;case"fission":a=Math.round(150*r);break;case"fusion":a=Math.round(("explorer"===e.class||t?174:175)*r);break;case"elerium":a=Math.round(200*r)}switch(a=Math.round(Fs(a)),e.weapon){case"railgun":a-=Math.round(10*i);break;case"laser":a-=Math.round(30*i);break;case"p_laser":a-=Math.round(18*i);break;case"plasma":a-=Math.round(50*i);break;case"phaser":a-=Math.round(65*i);break;case"disruptor":a-=Math.round(100*i)}switch(e.engine){case"ion":a-=Math.round(25*i);break;case"tie":a-=Math.round(50*i);break;case"pulse":a-=Math.round(40*i);break;case"photon":a-=Math.round(75*i);break;case"vacuum":a-=Math.round(120*i);break;case"emdrive":a-=Math.round(("explorer"===e.class||t?515:1024)*i)}switch(e.sensor){case"radar":a-=Math.round(10*i);break;case"lidar":a-=Math.round(25*i);break;case"quantum":a-=Math.round(75*i)}return a}function at(e){let t=0;switch(e.weapon){case"railgun":t=36;break;case"laser":t=64;break;case"p_laser":t=54;break;case"plasma":t=90;break;case"phaser":t=114;break;case"disruptor":t=156}switch(e.class){case"corvette":return t;case"frigate":return Math.round(1.5*t);case"destroyer":return Math.round(2.75*t);case"cruiser":return Math.round(5.5*t);case"battlecruiser":return Math.round(10*t);case"dreadnought":return Math.round(22*t);case"explorer":return Math.round(1.2*t)}}function rt(e){let a=1;switch(e.class){case"corvette":a="neutronium"===e.armor?1.1:1;break;case"frigate":a="neutronium"===e.armor?1.35:1.25;break;case"destroyer":a="neutronium"===e.armor?1.95:1.8;break;case"cruiser":a="neutronium"===e.armor?3.5:3;break;case"battlecruiser":a="neutronium"===e.armor?4.8:4;break;case"dreadnought":a="neutronium"===e.armor?7.5:6;break;case"explorer":a=1}let r="spc_dwarf"===e.location&&s.m_relay&&0===e.transit&&t.space.m_relay&&t.space.m_relay.charged>=1e4?3:1;switch(e.engine){case"ion":return 12/a*r;case"tie":return 22/a*r;case"pulse":return 18/a*r;case"photon":return 30/a*r;case"vacuum":return 42/a*r;case"emdrive":return 37500/a*r}}function it(e){let t=!1,a=0;switch(e.power){case"diesel":t="Oil",a=8;break;case"fission":t="Uranium",a=.5;break;case"fusion":t="Helium_3",a=12;break;case"elerium":t="Elerium",a=1}switch(e.class){case"frigate":a*=1.25;break;case"destroyer":a*=1.5;break;case"cruiser":a*=2;break;case"battlecruiser":a*=3;break;case"dreadnought":a*=5;break;case"explorer":a*=25}return{res:t,burn:+a.toFixed(2)}}function st(e){let a={},r=1,i=1,s=1;switch(e.class){case"corvette":a.Money=25e5,a.Aluminium=5e5,r=1,i=1,s=2;break;case"frigate":a.Money=5e6,a.Aluminium=125e4,r=1.1,i=1.09,s=1.5;break;case"destroyer":a.Money=15e6,a.Aluminium=35e5,r=1.2,i=1.18,s=1.2;break;case"cruiser":a.Money=5e7,a.Adamantite=1e6,r=1.3,i=1.25;break;case"battlecruiser":a.Money=125e6,a.Adamantite=26e5,r=1.35,i=1.3,s=.8;break;case"dreadnought":a.Money=5e8,a.Adamantite=8e6,r=1.4,i=1.35,s=.5;break;case"explorer":a.Money=8e8,a.Adamantite=95e5,r=1.45,i=1}switch(e.armor){case"steel":a.Steel=Math.round(35e4**r);break;case"alloy":a.Alloy=Math.round(25e4**r);break;case"neutronium":a.Neutronium=Math.round(1e4**r)}switch(e.engine){case"ion":a.Titanium=Math.round(75e3**i);break;case"tie":a.Titanium=Math.round(15e4**i);break;case"pulse":a.Titanium=Math.round(125e3**i);break;case"photon":a.Titanium=Math.round(21e4**i);break;case"vacuum":a.Titanium=Math.round(3e5**i);break;case"emdrive":a.Titanium=Math.round(125e4**i)}let n=!!["dreadnought","explorer"].includes(e.class);switch(e.power){case"solar":case"diesel":a[n?"Orichalcum":"Copper"]=Math.round(4e4**r),a.Iridium=Math.round(15e3**i);break;case"fission":a[n?"Orichalcum":"Copper"]=Math.round(5e4**r),a.Iridium=Math.round(3e4**i);break;case"fusion":a[n?"Orichalcum":"Copper"]=Math.round(5e4**r),a.Iridium=Math.round(4e4**i);break;case"elerium":a[n?"Orichalcum":"Copper"]=Math.round(6e4**r),a.Iridium=Math.round(55e3**i)}if("explorer"!==e.class)switch(e.sensor){case"radar":a.Money=Math.round(a.Money**1.04);break;case"lidar":a.Money=Math.round(a.Money**1.08);break;case"quantum":a.Money=Math.round(a.Money**1.12)}switch(e.weapon){case"railgun":a.Iron=Math.round(25e3**r);break;case"laser":a.Iridium=Math.round(a.Iridium**1.05),a.Nano_Tube=Math.round(12e3**r);break;case"p_laser":a.Iridium=Math.round(a.Iridium**1.035),a.Nano_Tube=Math.round(12e3**r);break;case"plasma":a.Iridium=Math.round(a.Iridium**1.1),a.Nano_Tube=Math.round(2e4**r);break;case"phaser":a.Iridium=Math.round(a.Iridium**1.15),a.Quantium=Math.round(18e3**r);break;case"disruptor":a.Iridium=Math.round(a.Iridium**1.2),a.Quantium=Math.round(35e3**r)}"explorer"===e.class&&(a.Iron*=10,a.Titanium*=5,a.Iridium*=50);let c=0;t.space.shipyard.ships.forEach((function(t){t.class===e.class&&c++}));let o=1+(c-2)/25*s;return Object.keys(a).forEach((function(t){"explorer"===e.class?a[t]=Math.ceil(a[t]*(3*(c+1))):c<2?a[t]=Math.ceil(a[t]*(0===c?.75:.9)):c>2&&(a[t]=Math.ceil(a[t]*o))})),a}function nt(){let e=$("#shipList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}function ct(){if(nt(),Ss($("#shipList")),t.tech.isolation)return;let e=$("#shipList");if(t.space.shipyard.sort){let e={spc_dwarf:"a"};t.space.shipyard.ships=t.space.shipyard.ships.sort(((t,a)=>(e[t.location]?e[t.location]:t.location).localeCompare(e[a.location]?e[a.location]:a.location)))}const a=At();for(let r=0;r${e}`}}else Object.keys(a).forEach((function(e){if(i.location!==e&&(a[e].info.syndicate()||"spc_dwarf"===e)&&(!t.race.orbit_decayed||t.race.orbit_decayed&&"spc_moon"!==e)){let t="string"==typeof a[e].info.name?a[e].info.name:a[e].info.name();s+=`${t}`}}));let n="tauceti"===i.location?z("tech_era_tauceti"):"string"==typeof a[i.location].info.name?a[i.location].info.name:a[i.location].info.name(),c=`\n ${s}\n `;if(t.space.shipyard.expand){let t=`${z(`outer_shipyard_engine_${i.engine}`)} ${z(`outer_shipyard_class_${i.class}`)}`,a=$(`
                            `),s=$(`
                            ${i.name} | ${z("outer_shipyard_scrap")} | ${t} | ${z(`outer_shipyard_weapon_${i.weapon}`)} | ${z(`outer_shipyard_power_${i.power}`)} | ${z(`outer_shipyard_armor_${i.armor}`)} | ${z(`outer_shipyard_sensor_${i.sensor}`)}
                            `),n=$('
                            '),o=$('
                            '),l=$(`
                            ${c}
                            `);n.append(`${z("crew")} `),n.append(`${z("firepower")} `),n.append(`${z("outer_shipyard_sensors")} `),n.append(`${z("speed")} `),n.append(`${z("outer_shipyard_fuel")} `),n.append(`${z("outer_shipyard_hull")} `),o.append(``),a.append(s),a.append(n),a.append(o),a.append(l),e.append(a)}else{let t=$(`
                            `),a=$('
                            '),s=$('
                            '),n=$(`
                            ${c}
                            `);a.append(`${i.name} | `),a.append(`${z("firepower")} `),a.append(`${z("outer_shipyard_sensors")} `),a.append(`${z("speed")} `),a.append(`${z("outer_shipyard_fuel")} `),a.append(`${z("outer_shipyard_hull")} `),s.append(``),t.append(a),t.append(s),t.append(n),e.append(t)}Cs({el:`#shipReg${r}`,data:t.space.shipyard.ships[r],methods:{scrap(e){t.space.shipyard.ships[e]&&"spc_dwarf"===t.space.shipyard.ships[e].location&&(t.space.shipyard.ships.splice(e,1),ct(),Ye())},scrapAllowed:e=>!(!t.space.shipyard.ships[e]||"spc_dwarf"!==t.space.shipyard.ships[e].location),setLoc(e,a){let r=t.space.shipyard.ships[a];if(e!==r.location){let i=et(r),s=r.transit>0||"spc_dwarf"!==r.location;if(s||t.civic.garrison.workers-t.civic.garrison.crew>=i){let n=ot(r,e),c=ht(r.xy,n),o=rt(r);r.location=e,r.transit=Math.round(c/o),r.dist=Math.round(c/o),r.origin=sn(r.xy),r.destination={x:n.x,y:n.y},s||(t.civic.garrison.crew+=i),ct(),_s(`ship${a}loc${e}`)}}},crewText:e=>et(t.space.shipyard.ships[e]),fireText:e=>at(t.space.shipyard.ships[e]),sensorText:e=>_t(t.space.shipyard.ships[e])+"km",speedText(e){let a=7.695363719135802*rt(t.space.shipyard.ships[e]);return Math.round(a)+"km/s"},fuelText(e){let a=it(t.space.shipyard.ships[e]);return a.res?`${a.burn} ${t.resource[a.res].name}/s`:"N/A"},hullText:e=>100-t.space.shipyard.ships[e].damage+"%",hullDamage:e=>t.space.shipyard.ships[e].damage<=10?"has-text-success":t.space.shipyard.ships[e].damage>=40&&t.space.shipyard.ships[e].damage<65?"has-text-caution":t.space.shipyard.ships[e].damage>=65?"has-text-danger":"",dest(e){let r="explorer"===i.class?z("tech_era_tauceti"):"string"==typeof a[t.space.shipyard.ships[e].location].info.name?a[t.space.shipyard.ships[e].location].info.name:a[t.space.shipyard.ships[e].location].info.name();return z("outer_shipyard_arrive",[r,t.space.shipyard.ships[e].transit])},show:e=>t.space.shipyard.ships[e].transit>0}}),"explorer"===i.class?"tauceti"!==i.location&&ls(`ship${r}loctauceti`,(function(){return z("transit_time",[Math.round(ht(i.xy,ot(i,"tauceti"))/rt(i))])}),{elm:`#ship${r}loc .tauceti`,placement:"left"}):Object.keys(a).forEach((function(e){(a[e].info.syndicate()||"spc_dwarf"===e)&&i.location!==e&&ls(`ship${r}loc${e}`,(function(){return z("transit_time",[Math.round(ht(i.xy,ot(i,e))/rt(i))])}),{elm:`#ship${r}loc .${e}`,placement:"left"})}))}!function(){let e=$("#shipList")[0];Sortable.create(e,{onEnd(e){let a=t.space.shipyard.ships;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.space.shipyard.ships=a,ct()}})}()}function ot(e,a){if(-2===dt[a].orbit)return ut(a);let r=Math.sqrt((e.xy.x-vt(a))**2+e.xy.y**2),i=rt(e)/225,s=gt(1,a),n=Math.abs(r-dt[a].dist),c=Math.abs(r+dt[a].dist),o=Math.abs(r-dt[a].dist*s),l=Math.abs(r+dt[a].dist*s),_=Math.floor(Math.min(n,o,c,l)/i),d=Math.ceil(Math.max(n,o,c,l)/i);r>=dt[a].dist&&r<=dt[a].dist*s&&(_=0);let p=360/(-1===dt[a].orbit?t.city.calendar.orbit:dt[a].orbit),u=(t.space.position[a]+_*p)%360,h=Math.PI/180;for(let t=_;t<=d;t++){let r=gt(Math.cos(u*h)*dt[a].dist,a);r+=vt(a);let s=Math.sin(u*h)*dt[a].dist;if(Math.sqrt((r-e.xy.x)**2+(s-e.xy.y)**2)/i<=t)return{x:r,y:s};u=(u+p)%360}return ut(a)}function lt(e,a){if(!t.tech.isolation&&t.tech.syndicate&&t.race.truepath&&t.space.syndicate&&t.space.syndicate.hasOwnProperty(e)){let r=1e3,i=0;switch(t.civic.foreign.gov3.hstl<10?i=250-25*t.civic.foreign.gov3.hstl:t.civic.foreign.gov3.hstl>60&&(i=-13*(t.civic.foreign.gov3.hstl-60)),e){case"spc_home":case"spc_moon":case"spc_red":case"spc_hell":r=1250+i;break;case"spc_gas":case"spc_gas_moon":case"spc_belt":r=1020+i;break;case"spc_titan":case"spc_enceladus":case"spc_triton":case"spc_kuiper":case"spc_eris":r=Mr.space[e].info.syndicate_cap()}let c=t.space.syndicate[e],o=0,l=0,_=0;if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){if(t.space.shipyard.ships.forEach((function(t){if(t.location===e&&0===t.transit&&t.fueled){let e=at(t);o+=t.damage>0?Math.round(e*(100-t.damage)/100):e,l+=_t(t)}})),"spc_enceladus"===e&&Math.min(n.operating_base,s.operating_base)>0){let e=Math.min(n.operating_base,s.operating_base);o+=50*e}else"spc_titan"===e&&s.sam>0?o+=25*s.sam:"spc_triton"===e&&s.fob>0&&(o+=500,l+=10);l>100&&(l=Math.round((l-100)/(l-100+200)*100)+100),o=Math.round(o*((l+25)/125)),o>c&&(_=o-c),c=c-o>0?c-o:0}return a?{p:1-+(c/r).toFixed(4),r:c,s:l,o:_}:1-+(c/r).toFixed(4)}return a?{p:1,r:0,s:0,o:0}:1}function _t(e){let t=1;switch(e.class){case"corvette":case"frigate":t=2;break;case"destroyer":case"cruiser":t=1.5;break;case"explorer":t=5;break;default:t=1}switch(e.sensor){case"visual":return 1;case"radar":return 10*t;case"lidar":return 18*t;case"quantum":return 32*t}}const dt={spc_sun:{dist:0,orbit:0,size:2},spc_home:{dist:1,orbit:-1,size:.6},spc_moon:{dist:1.01,orbit:-1,size:.1,moon:!0},spc_red:{dist:1.524,orbit:687,size:.5},spc_hell:{dist:.4,orbit:88,size:.4},spc_venus:{dist:.7,orbit:225,size:.5},spc_gas:{dist:5.203,orbit:4330,size:1.25},spc_gas_moon:{dist:5.204,orbit:4330,size:.2,moon:!0},spc_belt:{dist:2.7,orbit:1642,size:.5,belt:!0},spc_dwarf:{dist:2.77,orbit:1682,size:.5},spc_saturn:{dist:9.539,orbit:10751,size:1.1},spc_titan:{dist:9.536,orbit:10751,size:.2,moon:!0},spc_enceladus:{dist:9.542,orbit:10751,size:.1,moon:!0},spc_uranus:{dist:19.8,orbit:30660,size:1},spc_neptune:{dist:30.08,orbit:60152,size:1},spc_triton:{dist:30.1,orbit:60152,size:.1,moon:!0},spc_kuiper:{dist:39.5,orbit:90498,size:.5,belt:!0},spc_eris:{dist:68,orbit:204060,size:.5,size:.5},tauceti:{dist:752568.8,orbit:-2,size:2}};function pt(){t.space.position||(t.space.position={}),Object.keys(dt).forEach((function(e){t.space.position.hasOwnProperty(e)||(t.space.position[e]=Math.rand(0,360))})),t.space.position.spc_home=t.space.position.spc_moon,t.space.position.spc_gas_moon=t.space.position.spc_gas,t.space.position.spc_titan=t.space.position.spc_enceladus,t.space.position.spc_saturn=t.space.position.spc_titan,t.space.position.spc_neptune=t.space.position.spc_triton}function ut(e){let a=gt(+Math.cos(t.space.position[e]*(Math.PI/180)).toFixed(5)*dt[e].dist,e),r=+Math.sin(t.space.position[e]*(Math.PI/180)).toFixed(5)*dt[e].dist;return a+=vt(e),{x:a,y:r}}function ht(e,t){return Math.ceil(225*Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2))}function mt(e,a){let r=1;switch(t.race.pack_rat&&(r*=1+Ei.pack_rat.vars()[1]/100),t.stats.achieve.blackhole&&(r*=1+.05*t.stats.achieve.blackhole.l),t.tech.world_control&&(r*=3),e){case"storehouse":s.titan_spaceport&&(r*=1+.25*s.titan_spaceport),a&&t.tech.shelving&&(r*=2),t.tech.shelving&&t.tech.shelving>=3&&(r*=1.5);case"repository":t.tech.isolation&&(r*=3,t.tech.tp_depot&&(r*=1+t.tech.tp_depot/20))}return r}function gt(e,a){if(-2!==dt[a].orbit){let r=1.075+dt[a].dist/100;t.city.ptrait.includes("elliptical")&&(r="spc_home"===a?1.5:1.275+dt[a].dist/100),e*=r}return e}function vt(e){if(-2!==dt[e].orbit){let a=dt[e].dist/3;return t.city.ptrait.includes("elliptical")&&"spc_home"===e&&(a+=.15),"spc_eris"===e&&(a+=25),a}return 0}var ft,yt;function bt(){let e=document.getElementById("mapCanvas"),a=e.getContext("2d");e.width=e.getBoundingClientRect().width,e.height=e.getBoundingClientRect().height,a.save(),a.fillStyle="#000000",a.fillRect(0,0,e.width,e.height),a.translate(yt.x,yt.y),a.scale(ft,ft);let r={};for(let[e,t]of Object.entries(dt))r[e]=ut(e);a.lineWidth=1/ft,a.strokeStyle="#c0c0c0";for(let[e,r]of Object.entries(dt))if(!r.moon&&-2!==r.orbit){a.beginPath(),r.belt||t.race.orbit_decayed&&"spc_home"===e?a.setLineDash([.01,.01]):a.setLineDash([]);let i=vt(e);a.ellipse(i,0,gt(r.dist,e),r.dist,0,0,2*Math.PI,!0),a.stroke()}a.fillStyle="#0000ff",a.strokeStyle="#0000ff";for(let e of t.space.shipyard.ships)e.transit>0&&(a.beginPath(),a.setLineDash([.1,.4]),a.moveTo(e.xy.x,e.xy.y),a.lineTo(e.destination.x,e.destination.y),a.stroke());for(let[e,i]of Object.entries(dt)){if(t.race.orbit_decayed&&["spc_home","spc_moon"].includes(e))continue;let s="558888";if(Mr.space[e]&&Mr.space[e].info.syndicate()&&t.settings.space[e.substring(4)]){let t=lt(e);s=((Math.round(255*(1-t))<<16)+(Math.round(255*t)<<8)).toString(16).padStart(6,0)}"spc_dwarf"===e?s="7132a8":"spc_sun"!==e&&"tauceti"!==e||(s="f8ff2b"),a.fillStyle="#"+s,a.beginPath();let n=i.size/10;if(i.moon)switch(e){case"spc_moon":a.arc(r[e].x+.05,r[e].y+.05,n,0,2*Math.PI,!0);break;case"spc_titan":a.arc(r[e].x-.2,r[e].y-.2,n,0,2*Math.PI,!0);break;default:a.arc(r[e].x+.2,r[e].y+.2,n,0,2*Math.PI,!0)}else{let t=i.size/10;a.arc(r[e].x,r[e].y,t,0,2*Math.PI,!0)}a.fill()}a.fillStyle="#0000ff",a.strokeStyle="#0000ff";for(let e of t.space.shipyard.ships)e.transit>0&&(a.beginPath(),a.arc(e.xy.x,e.xy.y,.1,0,2*Math.PI,!0),a.fill());a.shadowOffsetX=2,a.shadowOffsetY=2,a.shadowBlur=2,a.shadowColor="rgba(0, 0, 0, 0.5)",a.fillStyle="#009aff",a.font=20/ft+"px serif";for(let e of t.space.shipyard.ships)e.transit>0&&a.fillText(e.name,e.xy.x+.15,e.xy.y-.15);a.fillStyle="#ffa500",a.font=25/ft+"px serif";for(let[e,i]of Object.entries(dt))if(Mr.space[e]&&t.settings.space[e.substring(4)]){if(t.race.orbit_decayed&&["spc_home"].includes(e))continue;let s=Mr.space[e].info.name,n="function"==typeof s?s():s;if(i.moon)switch(e){case"spc_moon":a.fillText(n,r[e].x+.1,r[e].y+.1);break;case"spc_titan":a.fillText(n,r[e].x-.3,r[e].y-.3);break;default:a.fillText(n,r[e].x+.25,r[e].y+.2)}else"spc_sun"===e||a.fillText(n,r[e].x,r[e].y-.2*i.size)}a.restore()}function wt(e){switch(e){case"city":return t.resource[t.race.species]?t.resource[t.race.species].amount<=5?z("tab_city1"):t.resource[t.race.species].amount<=20?z("tab_city2"):t.resource[t.race.species].amount<=75?z("tab_city3"):t.resource[t.race.species].amount<=250?z("tab_city4"):t.resource[t.race.species].amount<=600?z("tab_city5"):t.resource[t.race.species].amount<=1200?z("tab_city6"):t.resource[t.race.species].amount<=2500?z("tab_city7"):z("tab_city8"):z("tab_city1");case"local_space":return z("sol_system",[t.race.truepath?Ki[t.race.species].home:nn("name")]);case"outer_local_space":return z("outer_sol_system",[t.race.truepath?Ki[t.race.species].home:nn("name")]);case"old":return z("tab_old_res");case"new":return z("tab_new_res");case"old_sr":return z("tab_old_sr_res");case"new_sr":return z("tab_new_sr_res");default:return z(e)}}function kt(e){switch(t.settings.tabLoad?ks("page_view",{page_title:"Evolve - All Tabs"}):(fi(),Ci(),wa(),Le(),E(),nt(),Ss($("#mTabCivil")),Ss($("#mTabCivic")),Ss($("#mTabResearch")),Ss($("#mTabResource")),Ss($("#mTabArpa")),Ss($("#mTabStats")),Ss($("#mTabObserve"))),e){case 0:t.settings.tabLoad||(ks("page_view",{page_title:"Evolve - Evolution"}),Tr());break;case 1:case"mTabCivil":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Civilization"}),$("#mTabCivil").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),Cs({el:"#mTabCivil",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(Ss($("#city")),Ss($("#space")),Ss($("#interstellar")),Ss($("#galaxy")),Ss($("#portal")),Ss($("#outerSol")),Ss($("#tauCeti")),e){case 0:Wr();break;case 1:case 2:case 3:case 5:Lt();break;case 4:ua();break;case 6:Je()}return e}},filters:{label:e=>wt(e)}}),"protoplasm"!==t.race.species&&(Wr(),Lt(),ua(),Je()),t.race.noexport&&("Race"===t.race.noexport?(Ss($("#city")),Qt()):"Planet"===t.race.noexport&&(Ss($("#city")),Jt()));break;case 2:case"mTabCivic":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Civics"}),$("#mTabCivic").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),Cs({el:"#mTabCivic",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(Ci(),E(),wa(),nt(),Ss($("#civic")),Ss($("#industry")),Ss($("#powerGrid")),Ss($("#military")),Ss($("#mechLab")),Ss($("#dwarfShipYard")),Ss($("#psychicPowers")),e){case 0:$("#civic").append($('
                            ')),Yt(),$("#civics").append($('
                            ')),V(),"protoplasm"===t.race.species||t.race.start_cataclysm||(Q(),he($("#c_garrison"),!1),te()),t.race.shapeshifter&&Yi(!1,!0);break;case 1:ki();break;case 2:Object.keys(Si()).forEach((function(e){us(e)})),Mi();break;case 3:"protoplasm"===t.race.species||t.race.start_cataclysm||(W(),ma($("#fortress"),!1));break;case 4:"protoplasm"===t.race.species||t.race.start_cataclysm||ya();break;case 5:t.race.truepath&&"protoplasm"!==t.race.species&&!t.race.start_cataclysm&&Ze();break;case 6:t.race.psychic&&t.tech.psychic&&"protoplasm"!==t.race.species&&cs()}return e}},filters:{label:e=>wt(e)}}),Object.keys(Si()).forEach((function(e){us(e)})),Mi(),$("#civic").append($('
                            ')),Yt(),$("#civics").append($('
                            ')),V(),"protoplasm"===t.race.species||t.race.start_cataclysm||(W(),he($("#c_garrison"),!1),ma($("#fortress"),!1),te(),ya(),t.race.truepath&&Ze(),t.race.psychic&&t.tech.psychic&&cs()),t.race.shapeshifter&&Yi(!1,!0),ki();break;case 3:case"mTabResearch":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Research"}),$("#mTabResearch").append('
                            \n \n \n \n \n \n \n \n '),Cs({el:"#mTabResearch",data:{s:t.settings,rq:t.r_queue},filters:{label:e=>wt(e)}}),vi(),"protoplasm"!==t.race.species&&Qr();break;case 4:case"mTabResource":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Resources"}),$("#mTabResource").append('\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),Cs({el:"#mTabResource",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(Ss($("#market")),Ss($("#resStorage")),Ss($("#resEjector")),Ss($("#resCargo")),Ss($("#resAlchemy")),e){case 0:Ka("market");break;case 1:Ka("storage");break;case 2:Ka("ejector");break;case 3:Ka("supply");break;case 4:Ka("alchemy")}return e}},filters:{label:e=>wt(e)}}),Ea(),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let r=a.resource[e].color,i=a.resource[e].tradable;if(a.resource[e].stackable){var s=$(`
                            `);$("#resStorage").append(s),er(`#stack-${e}`,s,e,r)}i&&(s=$(`
                            `),$("#market").append(s),Va(`#market-${e}`,s,e,r,!0)),Fa[e]&&mr(e,r),Aa[e]&&vr(e,r),za[e]&&"magic"===t.race.universe&&(t.resource[e].basic=i,yr(e,r,i))})),Ba();break;case 5:case"mTabArpa":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Arpa"}),$("#mTabArpa").append(`
                            \n \n \n \n \n \n \n
                            `),Cs({el:"#mTabArpa",data:{s:t.settings},filters:{label:e=>wt(e)}}),xe("Physics"),xe("Genetics"),xe("Crispr"),xe("Blood");break;case 6:case"mTabStats":t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Stats"}),$("#mTabStats").append('\n \n \n \n \n \n \n \n \n \n '),Cs({el:"#mTabStats",data:{s:t.settings},filters:{label:e=>wt(e)}}),function(){Ss($("#achieve")),Ss($("#stats"));let e=$('
                            ');$("#stats").append(e);let a=$('
                            ');$("#perks").append(a);let r=$('
                            ');$("#achieve").append(r),function(){Ss($("#statsPanel"));let e=$("#statsPanel");if(e.append(`
                            ${z("achieve_stats_overall")}
                            `),e.append(`
                            ${z("achieve_stats_plasmid_earned")} {{ s.plasmid | format }}
                            `),t.stats.antiplasmid>0&&e.append(`
                            ${z("achieve_stats_antiplasmid_earned")} {{ s.antiplasmid | format }}
                            `),t.stats.phage>0&&e.append(`
                            ${z("achieve_stats_phage_earned")} {{ s.phage | format }}
                            `),t.stats.dark>0&&e.append(`
                            ${z("achieve_stats_dark_earned")} {{ s.dark | format }}
                            `),t.stats.harmony>0&&e.append(`
                            ${z("achieve_stats_harmony_earned")} {{ s.harmony | format }}
                            `),t.stats.blood>0&&e.append(`
                            ${z("achieve_stats_blood_earned")} {{ s.blood | format }}
                            `),t.stats.artifact>0&&e.append(`
                            ${z("achieve_stats_artifact_earned")} {{ s.artifact | format }}
                            `),e.append(`
                            ${z("achieve_stats_knowledge_spent")} {{ s.know | t_know | format }}
                            `),e.append(`
                            ${z("achieve_stats_starved_to_death")} {{ s.starved | t_starved | format }}
                            `),e.append(`
                            ${z("achieve_stats_died_in_combat")} {{ s.died | t_died | format }}
                            `),e.append(`
                            ${z("achieve_stats_game_days_played")} {{ s.days | played | format }}
                            `),t.stats.portals>0&&e.append(`
                            ${z("achieve_stats_portals")} {{ s.portals | format }}
                            `),e.append(`
                            ${z("achieve_stats_total_resets")} {{ s.reset | format }}
                            `),t.stats.mad>0&&e.append(`
                            ${z("achieve_stats_mad_resets")} {{ s.mad | format }}
                            `),t.stats.bioseed>0&&e.append(`
                            ${z("achieve_stats_bioseed_resets")} {{ s.bioseed | format }}
                            `),t.stats.cataclysm>0&&e.append(`
                            ${z("achieve_stats_cataclysm_resets")} {{ s.cataclysm | format }}
                            `),t.stats.blackhole>0&&e.append(`
                            ${z("achieve_stats_blackhole_resets")} {{ s.blackhole | format }}
                            `),t.stats.ascend>0&&e.append(`
                            ${z("achieve_stats_ascension_resets")} {{ s.ascend | format }}
                            `),t.stats.descend>0&&e.append(`
                            ${z("achieve_stats_descension_resets")} {{ s.descend | format }}
                            `),t.stats.aiappoc>0&&e.append(`
                            ${z("achieve_stats_aiappoc_resets")} {{ s.aiappoc | format }}
                            `),t.stats.matrix>0&&e.append(`
                            ${z("achieve_stats_matrix_resets")} {{ s.matrix | format }}
                            `),t.stats.retire>0&&e.append(`
                            ${z("achieve_stats_retire_resets")} {{ s.retire | format }}
                            `),t.stats.eden>0&&e.append(`
                            ${z("achieve_stats_eden_resets")} {{ s.eden | format }}
                            `),t.stats.terraform>0&&e.append(`
                            ${z("achieve_stats_terraform_resets")} {{ s.terraform | format }}
                            `),t.stats.geck>0&&e.append(`
                            ${z("achieve_stats_gecks")} {{ s.geck | format }}
                            `),e.append(`
                            ${z("achieve_stats_current_game")}
                            `),e.append(`
                            ${z("achieve_stats_knowledge_spent")} {{ s.know | format }}
                            `),e.append(`
                            ${z("achieve_stats_starved_to_death")} {{ s.starved | format }}
                            `),e.append(`
                            ${z("achieve_stats_died_in_combat")} {{ s.died | format }}
                            `),e.append(`
                            ${z("achieve_stats_attacks_made")} {{ s.attacks | format }}
                            `),e.append(`
                            ${z("achieve_stats_game_days_played")} {{ s.days | format }}
                            `),t.stats.dkills>0&&e.append(`
                            ${z("achieve_stats_demons_kills")} {{ s.dkills | format }}
                            `),t.stats.sac>0&&e.append(`
                            ${z("achieve_stats_sacrificed")} {{ s.sac | format }}
                            `),t.stats.murders>0&&e.append(`
                            ${z("achieve_stats_murders")} {{ s.murders | format }}
                            `),t.stats.psykill>0&&e.append(`
                            ${z("achieve_stats_psymurders")} {{ s.psykill | format }}
                            `),t.resource.hasOwnProperty("Thermite")&&t.resource.Thermite.amount>0&&e.append(`
                            ${z("achieve_stats_thermite")} {{ r.Thermite.amount | res }}
                            `),ln().active){let a="";(t.stats.cfood>=13||t.race.cataclysm||t.race.orbit_decayed)&&(a=`${Js(7,12,!0)}`),e.append(`
                            ${z("achieve_stats_trickortreat")} {{ s.cfood | format }} ${a}
                            `)}Cs({el:"#statsPanel",data:{s:t.stats,r:t.resource},filters:{played:e=>e+t.stats.tdays,t_know:e=>e+t.stats.tknow,t_starved:e=>e+t.stats.tstarved,t_died:e=>e+t.stats.tdied,format:e=>e.toLocaleString(),res:e=>(+e.toFixed(2)).toLocaleString()}})}(),An(),$("body").hasClass("fool")?jn({fool:!0}):jn()}();break;case 7:t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Settings"});break;default:t.settings.tabLoad||ks("page_view",{page_title:"Evolve - Hell Observation"}),t.portal.observe&&Pa(!0)}$("#popper").length>0&&0===$(`#${$("#popper").data("id")}`).length&&_s()}const $t={spc_home:{info:{name:()=>Ki[t.race.species].home,desc:z("space_home_info_desc"),zone:"inner",syndicate:()=>!1},test_launch:{id:"space-test_launch",title:z("space_home_test_launch_title"),desc:z("space_home_test_launch_desc"),reqs:{space:1},grant:["space",2],queue_complete:()=>t.tech.space>=2?0:1,cost:{Money:()=>1e5,Oil:(e,t)=>Rt(7500,!1,t)},effect:z("space_home_test_launch_effect"),action(){if(ri($(this)[0])){if(t.race.truepath){let e=1;if(ce("gov0")||e++,ce("gov1")||e++,ce("gov2")||e++,0!==Math.floor(m(0,e)))return hs(z("space_home_test_launch_action_fail"),"danger",!1,["progress"]),0}return t.space.satellite={count:0},hs(z("space_home_test_launch_action"),"info",!1,["progress"]),!0}return!1}},satellite:{id:"space-satellite",title:z("space_home_satellite_title"),desc:z("space_home_satellite_desc"),reqs:{space:2},cost:{Money:e=>Ps("satellite",e,72e3,1.22),Knowledge:e=>Ps("satellite",e,28e3,1.22),Oil:(e,t)=>Ps("satellite",e,Rt(3200,!1,t),1.22),Alloy:e=>Ps("satellite",e,8e3,1.22)},effect(){let e=t.race.cataclysm||t.race.orbit_decayed?2e3:750;if((t.race.cataclysm||t.race.orbit_decayed)&&t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?5:10;e*=t.tech.supercollider/a+1}let a=t.race.cataclysm?z("space_moon_observatory_title"):t.race.orbit_decayed?z("city_university"):_i(),r=`
                            ${z("space_home_satellite_effect2",[a,t.race.cataclysm?25:t.race.orbit_decayed?12:4])}
                            `;return`
                            ${z("plus_max_resource",[e,z("resource_Knowledge_name")])}
                            ${r}
                            ${z("space_home_satellite_effect3",[t.civic.scientist?t.civic.scientist.name:z("job_scientist")])}
                            `},action(){return!!ri($(this)[0])&&(Ft("satellite"),t.resource.Knowledge.max+=750,!0)}},gps:{id:"space-gps",title:z("space_home_gps_title"),desc:()=>t.space.hasOwnProperty("gps")&&t.space.gps.count<4?`
                            ${z("space_home_gps_desc")}
                            ${z("space_home_gps_desc_req")}
                            `:`
                            ${z("space_home_gps_desc")}
                            `,reqs:{satellite:1},not_trait:["terrifying"],cost:{Money:e=>Ps("gps",e,75e3,1.18),Knowledge:e=>Ps("gps",e,5e4,1.18),Copper:e=>Ps("gps",e,6500,1.18),Oil:(e,t)=>Ps("gps",e,Rt(3500,!1,t),1.18),Titanium:e=>Ps("gps",e,8e3,1.18)},effect:e=>(e||0)+(t.space.hasOwnProperty("gps")?t.space.gps.count:0)<4?z("space_home_gps_effect_req"):`
                            ${z("space_home_gps_effect")}
                            ${z("space_home_gps_effect2",[2])}
                            `,action(){return!!ri($(this)[0])&&(Ft("gps"),!0)}},propellant_depot:{id:"space-propellant_depot",title:z("space_home_propellant_depot_title"),desc:z("space_home_propellant_depot_desc"),reqs:{space_explore:1},cost:{Money:e=>Ps("propellant_depot",e,55e3,1.35),Aluminium:e=>Ps("propellant_depot",e,22e3,1.35),Oil:(e,t)=>Ps("propellant_depot",e,Rt(5500,!1,t),1.35)},effect(){let e=br(1250)*(t.tech.world_control?1.5:1);if(t.resource.Helium_3.display){let a=br(1e3)*(t.tech.world_control?1.5:1);return`
                            ${z("plus_max_resource",[e,z("resource_Oil_name")])}
                            ${z("plus_max_resource",[a,z("resource_Helium_3_name")])}
                            `}return`
                            ${z("plus_max_resource",[e,z("resource_Oil_name")])}
                            `},action(){return!!ri($(this)[0])&&(Ft("propellant_depot"),t.resource.Oil.max+=br(1250)*(t.tech.world_control?1.5:1),t.resource.Helium_3.display&&(t.resource.Helium_3.max+=br(1e3)*(t.tech.world_control?1.5:1)),!0)}},nav_beacon:{id:"space-nav_beacon",title:()=>t.race.orbit_decayed?z("space_home_broadcast_beacon_title"):z("space_home_nav_beacon_title"),desc:`
                            ${z("space_home_nav_beacon_desc")}
                            ${z("requires_power")}
                            `,reqs:{luna:2},cost:{Money:e=>Ps("nav_beacon",e,75e3,1.32),Copper:e=>Ps("nav_beacon",e,38e3,1.32),Aluminium:e=>Ps("nav_beacon",e,44e3,1.32),Oil:(e,t)=>Ps("nav_beacon",e,Rt(12500,!1,t),1.32),Iridium:e=>Ps("nav_beacon",e,1200,1.32)},powered:()=>As(2),powerBalancer:()=>t.tech.luna&&t.tech.luna>=3?[{s:t.space.moon_base.s_max-t.space.moon_base.support},{s:t.space.spaceport.s_max-t.space.spaceport.support}]:[{s:t.space.moon_base.s_max-t.space.moon_base.support}],support:()=>1,effect(){let e="";return t.race.orbit_decayed&&t.tech.broadcast&&(e=`
                            ${z("space_red_vr_center_effect1",[t.tech.broadcast/2])}
                            `),`${t.race.orbit_decayed?"":`
                            ${z("space_home_nav_beacon_effect1")}
                            `}${t.tech.luna>=3?`
                            ${z("space_red_spaceport_effect1",[Ut().red,1])}
                            `:""}${e}
                            ${z("space_home_nav_beacon_effect2",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("nav_beacon"),Yr($(this)[0]),!0)}}},spc_moon:{info:{name:z("space_moon_info_name"),desc:()=>z("space_moon_info_desc",[Ki[t.race.species].home]),support:"moon_base",zone:"inner",syndicate:()=>!0},moon_mission:{id:"space-moon_mission",title:z("space_moon_mission_title"),desc:z("space_moon_mission_desc"),reqs:{space:2,space_explore:2},grant:["space",3],queue_complete:()=>t.tech.space>=3?0:1,cost:{Oil:(e,t)=>+Rt(12e3,!1,t).toFixed(0)},effect:z("space_moon_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("space_moon_mission_action"),"info",!1,["progress"]),t.space.iridium_mine={count:0,on:0},t.space.helium_mine={count:0,on:0},!0)}},moon_base:{id:"space-moon_base",title:z("space_moon_base_title"),desc:()=>`
                            ${z("space_moon_base_desc")}
                            ${z("requires_power_combo",[t.resource.Oil.name])}
                            `,reqs:{space:3},cost:{Money:e=>Ps("moon_base",e,22e3,1.32),Cement:e=>Ps("moon_base",e,18e3,1.32),Alloy:e=>Ps("moon_base",e,7800,1.32),Polymer:e=>Ps("moon_base",e,12500,1.32)},effect(e){let t=br(500),a=+Rt($(this)[0].support_fuel().a,!0,e).toFixed(2);return`
                            ${z("space_moon_base_effect1")}
                            ${z("plus_max_resource",[t,z("resource_Iridium_name")])}
                            ${z("space_moon_base_effect3",[a,$(this)[0].powered()])}
                            `},support:()=>2,support_fuel:()=>({r:"Oil",a:2}),powered:()=>As(4),powerBalancer:()=>[{s:t.space.moon_base.s_max-t.space.moon_base.support}],refresh:!0,action(){if(ri($(this)[0])){if(Ft("moon_base"),Yr($(this)[0]),1===t.space.moon_base.count&&(t.tech.moon=1),!t.tech.luna&&(t.tech.luna=1,t.race.truepath)){let e=z("space_moon_base_msg",[Z(3)]);t.civic.foreign.gov3.hstl<10?e=`${e} ${z("space_moon_base_msg_ally")}`:t.civic.foreign.gov3.hstl>60&&(e=`${e} ${z("space_moon_base_msg_hstl")}`),hs(e,"info",!1,["progress"])}return t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+2500&&(t.race.orbit_decay=t.stats.days+2500,hs(z("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0}return!1}},iridium_mine:{id:"space-iridium_mine",title:z("space_moon_iridium_mine_title"),desc:`
                            ${z("space_moon_iridium_mine_desc")}
                            ${z("space_support",[z("space_moon_info_name")])}
                            `,reqs:{space:3,luna:1},cost:{Money:e=>Ps("iridium_mine",e,42e3,1.35),Lumber:e=>Ps("iridium_mine",e,9e3,1.35),Titanium:e=>Ps("iridium_mine",e,17500,1.35)},effect(){let e=$e("iridium_mine","iridium"),a=+e.b.toFixed(3),r="";t.race.truepath&&(t.civic.foreign.gov3.hstl<10?r=`
                            ${z("space_rival_ally",[+(100*e.g).toFixed(1)])}
                            `:t.civic.foreign.gov3.hstl>60&&(r=`
                            ${z("space_rival_war",[+(100*e.g).toFixed(1)])}
                            `));let i=t.race.cataclysm?`
                            ${z("produce",[+$e("iridium_mine","coal").toFixed(2),t.resource.Coal.name])}
                            `:"",s=t.race.cataclysm?`
                            ${z("produce",[+($e("iridium_mine","coal")/48).toFixed(3),t.resource.Uranium.name])}
                            `:"";return`
                            ${z("space_used_support",[z("space_moon_info_name")])}
                            ${z("space_moon_iridium_mine_effect",[a])}
                            ${r}${i}${s}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.resource.Iridium.display=!0,Ft("iridium_mine"),t.resource.Mythril.display||(t.resource.Mythril.display=!0,sa()),t.space.moon_base.support${z("space_moon_helium_mine_desc")}
                            ${z("space_support",[z("space_moon_info_name")])}
                            `,reqs:{space:3,luna:1},cost:{Money:e=>Ps("helium_mine",e,38e3,1.35),Aluminium:e=>Ps("helium_mine",e,9e3,1.35),Steel:e=>Ps("helium_mine",e,17500,1.35)},effect(){let e=br(100),a=$e("helium_mine"),r=+a.b.toFixed(3),i="";return t.race.truepath&&(t.civic.foreign.gov3.hstl<10?i=`
                            ${z("space_rival_ally",[+(100*a.g).toFixed(1)])}
                            `:t.civic.foreign.gov3.hstl>60&&(i=`
                            ${z("space_rival_war",[+(100*a.g).toFixed(1)])}
                            `)),`
                            ${z("space_used_support",[z("space_moon_info_name")])}
                            ${z("space_moon_helium_mine_effect",[r])}
                            ${i}
                            ${z("plus_max_resource",[e,z("resource_Helium_3_name")])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.resource.Helium_3.display=!0,Ft("helium_mine"),t.space.moon_base.support${z("space_moon_observatory_desc")}
                            ${z("space_support",[z("space_moon_info_name")])}
                            `,reqs:{science:9,luna:1},cost:{Money:e=>Ps("observatory",e,2e5,1.28),Knowledge:e=>Ps("observatory",e,69e3,1.28),Stone:e=>Ps("observatory",e,125e3,1.28),Iron:e=>Ps("observatory",e,65e3,1.28),Iridium:e=>Ps("observatory",e,1250,1.28)},effect(){let e="";t.race.cataclysm&&(e=`
                            ${z("city_university_effect",[ta(1)])}
                            `);let a=5e3;t.race.cataclysm&&t.space.satellite&&t.space.satellite.count>0&&(a*=1+.25*t.space.satellite.count);let r=t.race.cataclysm?`
                            ${z("space_moon_observatory_cata_effect",[25])}
                            `:`
                            ${z("space_moon_observatory_effect",[5])}
                            `;return`
                            ${z("space_used_support",[z("space_moon_info_name")])}
                            ${e}
                            ${z("plus_max_resource",[a,z("resource_Knowledge_name")])}
                            ${r}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("observatory"),t.space.moon_base.supportUt().red,desc:()=>z("space_red_info_desc",[Ut().red]),support:"spaceport",zone:"inner",syndicate:()=>!0},red_mission:{id:"space-red_mission",title:()=>z("space_mission_title",[Ut().red]),desc:()=>z("space_mission_desc",[Ut().red]),reqs:{space:3,space_explore:3},grant:["space",4],queue_complete:()=>t.tech.space>=4?0:1,cost:{Helium_3:(e,t)=>+Rt(4500,!1,t).toFixed(0)},effect:()=>z("space_red_mission_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(hs(z("space_red_mission_action",[Ut().red]),"info",!1,["progress"]),t.space.living_quarters={count:0,on:0},t.space.garage={count:0},t.space.red_mine={count:0,on:0},t.space.fabrication={count:0,on:0},!0)}},spaceport:{id:"space-spaceport",title:z("space_red_spaceport_title"),desc:()=>`
                            ${z("space_red_spaceport_desc")}
                            ${z("requires_power_space",[t.resource.Food.name])}
                            `,reqs:{space:4},cost:{Money:e=>Ps("spaceport",e,47500,1.32),Iridium:e=>Ps("spaceport",e,1750,1.32),Mythril:e=>Ps("spaceport",e,25,1.32),Titanium:e=>Ps("spaceport",e,22500,1.32)},effect(e){let a=+Rt($(this)[0].support_fuel().a,!0,e).toFixed(2),r="";return(t.race.cataclysm||t.race.orbit_decayed)&&(r=`
                            ${z("plus_max_resource",[`$${br(4*bi())}`,z("resource_Money_name")])}
                            `),`
                            ${z("space_red_spaceport_effect1",[Ut().red,$(this)[0].support()])}
                            ${r}
                            ${z("space_red_spaceport_effect2",[a,$(this)[0].powered()])}
                            ${z("spend",[t.race.cataclysm?2:25,t.resource.Food.name])}
                            `},support(){let e=t.race.cataclysm||t.race.orbit_decayed?4:3;return t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=4&&e++,e},support_fuel:()=>({r:"Helium_3",a:1.25}),powered:()=>As(5),powerBalancer:()=>[{s:t.space.spaceport.s_max-t.space.spaceport.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("spaceport"),Yr($(this)[0]),t.tech.mars||(t.tech.mars=1),t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+1e3&&(t.race.orbit_decay=t.stats.days+1e3,hs(z("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0)}},red_tower:{id:"space-red_tower",title:z("space_red_tower_title"),desc:()=>`
                            ${z("space_red_tower_desc")}
                            ${z("requires_power")}
                            `,reqs:{mars:3},cost:{Money:e=>Ps("red_tower",e,225e3,1.28),Iron:e=>Ps("red_tower",e,22e3,1.28),Cement:e=>Ps("red_tower",e,15e3,1.28),Alloy:e=>Ps("red_tower",e,8e3,1.28)},effect(){return`
                            ${z("space_red_spaceport_effect1",[Ut().red,t.race.cataclysm?2:1])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(2),powerBalancer:()=>[{s:t.space.spaceport.s_max-t.space.spaceport.support}],support:()=>t.race.cataclysm?2:1,action(){return!!ri($(this)[0])&&(Ft("red_tower"),Yr($(this)[0]),!0)}},captive_housing:Cr("captive_housing","space"),terraformer:{id:"space-terraformer",title:z("space_terraformer"),desc:e=>!t.space.hasOwnProperty("terraformer")||t.space.terraformer.count<100||e?`
                            ${z("space_terraformer")}
                            ${z("requires_segmemts",[100])}
                            `+(t.space.hasOwnProperty("terraformer")&&t.space.terraformer.count>=100?`
                            ${z("requires_power")}
                            `:""):`
                            ${z("space_terraformer")}
                            `,reqs:{terraforming:1},condition:()=>!(t.space.terraformer.count>=100),queue_size:5,queue_complete:()=>100-t.space.terraformer.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?75e5:75e6:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?25e4:75e4:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?1e3:0,Bolognium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:1e5:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?12e3:25e4:0,Soul_Gem:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:1:0,Nanoweave:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100?t.race.truepath?0:75e3:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100&&t.race.truepath?75e3:0,Cipher:e=>(e||0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0)<100&&t.race.truepath?1e3:0},effect(e){let a=(e?e.count:0)+(t.space.hasOwnProperty("terraformer")?t.space.terraformer.count:0);if(a<100){let e=100-a;return`
                            ${z("space_terraformer_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}return $t.spc_red.atmo_terraformer.effect(e)},action(){return!!(ri($(this)[0])&&t.space.terraformer.count<100)&&(Ft("terraformer","space"),t.space.terraformer.count>=100&&(t.tech.terraforming=2,t.space.atmo_terraformer={count:1,on:0},Lt(),_s()),!0)}},atmo_terraformer:{id:"space-atmo_terraformer",title:z("space_terraformer"),desc:()=>`
                            ${z("space_terraformer")}
                            ${z("requires_power")}
                            `,wiki:!1,reqs:{terraforming:2},condition:()=>t.space.terraformer.count>=100,queue_complete:()=>0,cost:{},powered:e=>As((e?e.truepath:t.race.truepath)?500:5e3),postPower(e){e?setTimeout((function(){t.tech.terraforming=s.atmo_terraformer?3:2,Lt()}),250):(t.tech.terraforming=2,Lt())},effect(e){let t=Pt(),a=$(this)[0].powered(e),r=a>0?`
                            ${z("minus_power",[a])}
                            `:"";return`
                            ${z("space_terraformer_effect2")}
                            ${t}${r}`},action:()=>!1},terraform:{id:"space-terraform",title:z("space_terraform"),desc:z("space_terraform"),reqs:{terraforming:3},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=Pt();return`
                            ${z("space_terraform_effect")}
                            ${e}`},action(){return!!ri($(this)[0])&&(Jt(),!0)}},assembly:Cr("assembly","space"),living_quarters:{id:"space-living_quarters",title:z("space_red_living_quarters_title"),desc:()=>`
                            ${z("space_red_living_quarters_desc")}
                            ${z("space_support",[Ut().red])}
                            `,reqs:{mars:1},cost:{Money:e=>Ps("living_quarters",e,Bt(38e3),1.28),Steel:e=>Ps("living_quarters",e,Bt(15e3),1.28),Polymer:e=>Ps("living_quarters",e,Bt(9500),1.28),Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens(),a="";return(t.race.cataclysm||t.race.orbit_decayed)&&(a=`
                            ${z("plus_max_resource",[`$${br(t.tech.home_safe>=2?t.tech.home_safe>=3?"100000":"50000":"25000")}`,z("resource_Money_name")])}
                            `),`
                            ${z("space_used_support",[Ut().red])}
                            ${a}
                            ${z("plus_max_resource",[ta(1),t.race.truepath?z("job_colonist_tp",[Ut().red]):z("colonist")])}
                            ${z("plus_max_resource",[e,z("citizen")])}
                            `},support:()=>-1,powered:()=>As(1),action(){if(ri($(this)[0])){if(Ft("living_quarters"),t.civic.colonist.display=!0,t.space.spaceport.support0)){let e=t.civic[t.civic.d_job].workers-ta(1)<0?t.civic[t.civic.d_job].workers:ta(1);t.civic[t.civic.d_job].workers-=e,t.civic.colonist.workers+=e}return!0}return!1},citizens(){let e=t.race.cataclysm||t.race.orbit_decayed?2:1;return n.biodome&&(e+=(t.tech.mars>=6?.1:.05)*n.biodome),+ta(e).toFixed(2)}},pylon:{id:"space-pylon",title:z("space_red_pylon"),desc:z("space_red_pylon"),reqs:{magic:2},condition:()=>!(!t.race.cataclysm&&!t.race.orbit_decayed),cost:{Money:e=>Ps("pylon",e,10,1.48),Stone:e=>Ps("pylon",e,12,1.42),Crystal:e=>Ps("pylon",e,8,1.42)-3},effect(){let e=br(2);return`
                            ${z("gain",[+(.005*Is("magic")).toFixed(3),t.resource.Mana.name])}
                            ${z("plus_max_resource",[e,t.resource.Mana.name])}
                            `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!ri($(this)[0])&&(t.space.pylon.count++,t.resource.Mana.max+=br(2),!0)}},vr_center:{id:"space-vr_center",title:z("space_red_vr_center_title"),desc:()=>`
                            ${z("space_red_vr_center_desc")}
                            ${z("space_support",[Ut().red])}
                            `,reqs:{mars:1,broadcast:3},cost:{Money:e=>Ps("vr_center",e,38e4,1.25),Copper:e=>Ps("vr_center",e,55e3,1.25),Stanene:e=>Ps("vr_center",e,1e5,1.25),Soul_Gem:e=>Ps("vr_center",e,1,1.25)},effect(){let e=K("gaslighter",1),a=e?e+1:1;return t.race.orbit_decayed&&(a+=2),`
                            ${z("space_used_support",[Ut().red])}
                            ${z("space_red_vr_center_effect1",[a])}
                            ${z("space_red_vr_center_effect2",[2])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("vr_center"),t.space.spaceport.support`
                            ${z("space_red_garage_desc")}
                            `,reqs:{mars:1},cost:{Money:e=>Ps("garage",e,75e3,1.28),Iron:e=>Ps("garage",e,12e3,1.28),Brick:e=>Ps("garage",e,3e3,1.28),Sheet_Metal:e=>Ps("garage",e,1500,1.28)},wide:!0,res(){let e=["Copper","Iron","Cement","Steel","Titanium","Alloy","Nano_Tube","Neutronium","Infernite"];return(t.race.cataclysm||t.race.orbit_decayed)&&(e.push("Polymer"),e.push("Coal"),e.push("Lumber"),e.push("Chrysotile"),e.push("Stone"),e.push("Furs")),e},heavy:e=>!!["Copper","Iron","Steel","Titanium","Neutronium","Infernite"].includes(e),val(e){switch(e){case"Copper":return 6500;case"Iron":return 5500;case"Cement":return t.race.cataclysm?10500:6e3;case"Steel":return 4500;case"Titanium":return 3500;case"Alloy":case"Polymer":return 2500;case"Nano_Tube":return 25e3;case"Neutronium":return 125;case"Infernite":return 75;case"Coal":return 1500;case"Lumber":case"Chrysotile":case"Stone":return 7500;case"Furs":return 2200;default:return 0}},multiplier(e){let a=t.tech.particles>=4?1+t.tech.supercollider/20:1;return(t.tech.world_control||t.race.cataclysm||t.race.orbit_decayed)&&(a*=2),t.tech.shelving&&t.tech.shelving>=3&&(a*=1.5),a*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,e&&t.tech.shelving&&t.tech.shelving>=2?3*a:a},effect(){let e=$(this)[0].multiplier(!1),a=$(this)[0].multiplier(!0),r=t.tech.particles>=4?20+t.tech.supercollider:20;(t.tech.world_control||t.race.cataclysm||t.race.orbit_decayed)&&(r+=10);let i=t.race.cataclysm||t.race.orbit_decayed?`${z("plus_max_resource",[r,z("resource_Crates_name")])}`:"",s='
                            ';s+=`${z("plus_max_resource",[r,z("resource_Containers_name")])}${i}`;for(const r of $(this)[0].res())if(t.resource[r].display){let i=$(this)[0].heavy(r);s+=`${z("plus_max_resource",[x(+(br($(this)[0].val(r))*(i?a:e)).toFixed(0),1),t.resource[r].name])}`}return s+="
                            ",s},action(){if(ri($(this)[0])){Ft("garage");let e=$(this)[0].multiplier(!1),a=$(this)[0].multiplier(!0);for(const r of $(this)[0].res())if(t.resource[r].display){let i=$(this)[0].heavy(r);t.resource[r].max+=br($(this)[0].val(r))*(i?a:e)}return!0}return!1}},red_mine:{id:"space-red_mine",title:z("space_red_mine_title"),desc:()=>`
                            ${z("space_red_mine_desc")}
                            ${z("space_support",[Ut().red])}
                            `,reqs:{mars:1},cost:{Money:e=>Ps("red_mine",e,5e4,1.32),Lumber:e=>Ps("red_mine",e,65e3,1.32),Iron:e=>Ps("red_mine",e,33e3,1.32)},effect(){let e=$e("red_mine","copper"),a=$e("red_mine","titanium"),r=+e.b.toFixed(3),i=+a.b.toFixed(3),s="";t.race.truepath&&(t.civic.foreign.gov3.hstl<10?s=`
                            ${z("space_rival_ally",[+(100*e.g).toFixed(1)])}
                            `:t.civic.foreign.gov3.hstl>60&&(s=`
                            ${z("space_rival_war",[+(100*e.g).toFixed(1)])}
                            `));let n=t.race.orbit_decayed?`
                            ${z("city_mine_effect1",[ta(1)])}
                            ${z("city_coal_mine_effect1",[ta(1)])}
                            `:"",c=t.race.cataclysm||t.race.orbit_decayed&&!t.race.sappy?`
                            ${z("space_red_mine_effect",[+$e("red_mine","stone").toFixed(2),t.resource.Stone.name])}
                            `:"",o=t.race.cataclysm||t.race.orbit_decayed&&t.race.smoldering?`
                            ${z("space_red_mine_effect",[+$e("red_mine","asbestos").toFixed(2),t.resource.Chrysotile.name])}
                            `:"",l=t.race.cataclysm||t.race.orbit_decayed?`
                            ${z("space_red_mine_effect",[+$e("red_mine","aluminium").toFixed(2),t.resource.Aluminium.name])}
                            `:"";return`
                            ${z("space_used_support",[Ut().red])}
                            ${n}
                            ${z("space_red_mine_effect",[r,t.resource.Copper.name])}
                            ${z("space_red_mine_effect",[i,t.resource.Titanium.name])}
                            ${s}${o}${c}${l}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("red_mine"),t.space.spaceport.support`
                            ${z("space_red_fabrication_desc")}
                            ${z("space_support",[Ut().red])}
                            `,reqs:{mars:1},cost:{Money:e=>Ps("fabrication",e,9e4,1.32),Copper:e=>Ps("fabrication",e,25e3,1.32),Cement:e=>Ps("fabrication",e,12e3,1.32),Wrought_Iron:e=>Ps("fabrication",e,1200,1.32)},effect(){let e=t.race.cataclysm&&!t.race.flier?`
                            ${z("city_cement_plant_effect1",[ta(1)])}
                            `:"",a=t.race.cataclysm||t.race.orbit_decayed?5:2;return t.race.high_pop&&(a=ke(a)),`
                            ${z("space_used_support",[Ut().red])}
                            ${z("space_red_fabrication_effect1",[ta(1)])}
                            ${e}
                            ${z("space_red_fabrication_effect2",[a])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("fabrication"),t.space.spaceport.support`
                            ${z("space_red_factory_desc")}
                            ${z("requires_power_combo",[t.resource.Helium_3.name])}
                            `,reqs:{mars:4},cost:{Money:e=>Ps("red_factory",e,75e3,1.32),Brick:e=>Ps("red_factory",e,1e4,1.32),Coal:e=>Ps("red_factory",e,7500,1.32),Mythril:e=>Ps("red_factory",e,50,1.32)},effect(e){let a=`
                            ${z("space_red_factory_effect1")}
                            `;return t.tech.foundry>=7&&(a+=`
                            ${z("space_red_factory_effect2")}
                            `),t.race.orbit_decayed&&!t.race.flier&&(a+=`
                            ${z("city_cement_plant_effect1",[ta(1)])}
                            `),a+=`
                            ${z("space_red_factory_effect3",[+Rt(1,!0,e).toFixed(2),$(this)[0].powered()])}
                            `,a},powered:()=>As(3),special:!0,action(){return!!ri($(this)[0])&&(t.space.red_factory.count++,Yr($(this)[0])&&t.city.factory.Alloy++,t.settings.showIndustry=!0,ki(),!0)}},nanite_factory:Cr("nanite_factory","space"),biodome:{id:"space-biodome",title:()=>t.race.artifical?z("space_red_signal_tower_title"):t.race.soul_eater?z("space_red_asphodel_title"):z("space_red_biodome_title"),desc(){let e;return e=t.race.artifical?`
                            ${z("space_red_signal_tower_title")}
                            `:t.race.soul_eater?`
                            ${z("space_red_asphodel_desc")}
                            `:t.race.carnivore?`
                            ${z("space_red_biodome_desc_carn")}
                            `:`
                            ${z("space_red_biodome_desc",[Ut().red])}
                            `,`
                            ${e}
                            ${z("space_support",[Ut().red])}
                            `},reqs:{mars:2},cost:{Money:e=>Ps("biodome",e,45e3,1.28),Lumber:e=>Ps("biodome",e,65e3,1.28),Brick:e=>Ps("biodome",e,1e3,1.28),Nanite:e=>t.race.deconstructor?Ps("biodome",e,75,1.28):0},effect(){let e=+$e("biodome","food").toFixed(2),a=t.race.cataclysm||t.race.orbit_decayed?`
                            ${z("produce",[+$e("biodome","cat_food").toFixed(2),t.resource.Food.name])}
                            `:"",r=!t.race.cataclysm&&!t.race.orbit_decayed||t.race.kindling_kindred?"":`
                            ${z("space_red_mine_effect",[+$e("biodome","lumber").toFixed(2),t.resource.Lumber.name])}
                            `,i=t.tech.mars>=6?.1:.05,s=t.race.artifical?z("city_transmitter_effect",[br(500)]):z("plus_max_resource",[br(100),z("resource_Food_name")]),n=t.race.artifical||t.race.orbit_decayed?`
                            ${s}${z("space_used_support",[Ut().red])}
                            ${a}
                            ${z("space_red_biodome_effect",[e,t.resource.Food.name])}
                            ${z("space_red_biodome_effect2",[+ta(i).toFixed(2)])}
                            ${r}${n}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("biodome"),t.race.cataclysm||(qn("colonist"),t.race.joyless&&(qn("joyless"),delete t.race.joyless,Qr())),t.space.spaceport.supportt.race.artifical?z("space_red_signal_tower_flair"):t.race.soul_eater?z("space_red_asphodel_flair"):t.race.carnivore?z("space_red_biodome_flair_carn"):z("space_red_biodome_flair")},red_university:{id:"space-red_university",title:z("city_university"),desc:()=>z("city_university_desc",[Ut().red]),reqs:{mars:1},trait:["orbit_decayed"],cost:{Money:e=>Ps("university",e,900,1.5,"city")-500,Lumber:e=>Ps("university",e,500,1.36,"city")-200,Stone:e=>Ps("university",e,750,1.36,"city")-350,Crystal:e=>"magic"===t.race.universe?Ps("university",e,5,1.36,"city"):0},wiki:!1,effect:()=>Mr.city.university.effect(),action(){if(ri($(this)[0])){let e=t.tech.science&&t.tech.science>=8?700:500;if(t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,t.city.university.count++,t.space.red_university.count=t.city.university.count,t.civic.professor.display=!0,t.civic.professor.max=t.city.university.count,!0}return!1}},exotic_lab:{id:"space-exotic_lab",title:z("space_red_exotic_lab_title"),desc:()=>`
                            ${z("space_red_exotic_lab_desc")}
                            ${z("space_support",[Ut().red])}
                            `,reqs:{mars:5},cost:{Money:e=>Ps("exotic_lab",e,75e4,1.28),Steel:e=>Ps("exotic_lab",e,1e5,1.28),Mythril:e=>Ps("exotic_lab",e,1e3,1.28),Elerium:e=>Ps("exotic_lab",e,20,1.28)-4},effect(){let e=500;t.tech.science>=13&&t.interstellar.laboratory&&c.laboratory&&(e+=25*c.laboratory),t.tech.ancient_study&&t.tech.ancient_study>=2&&(e+=15*t.space.ziggurat.count),t.tech.mass>=2&&s.mass_driver&&(e+=ke(s.mass_driver*t.civic.scientist.workers)),t.tech.science>=21&&(e*=1.45),t.race.high_pop&&(e=ke(e));let a=br(10),r="",i="";return(t.race.cataclysm||t.race.orbit_decayed)&&(r=`
                            ${z("city_wardenclyffe_effect1",[ta(1),t.civic.scientist.name])}
                            `,e*=1+.25*n.observatory,t.tech.science>=15&&(i=`
                            ${z("city_wardenclyffe_effect4",[2])}
                            `)),`
                            ${z("space_used_support",[Ut().red])}
                            ${r}${i}
                            ${z("space_red_exotic_lab_effect1",[+e.toFixed(0)])}
                            ${z("plus_max_resource",[a,z("resource_Elerium_name")])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("exotic_lab"),t.space.spaceport.support`
                            ${z("space_red_exotic_lab_flair1")}
                            ${z("space_red_exotic_lab_flair2")}
                            `},ziggurat:{id:"space-ziggurat",title:z("space_red_ziggurat_title"),desc:()=>`
                            ${z("space_red_ziggurat_desc",["none"!==t.race.old_gods?Ki[t.race.old_gods.toLowerCase()].entity:Ki[t.race.species].entity])}
                            `,reqs:{theology:4},cost:{Money:e=>Ps("ziggurat",e,6e5,1.28),Stone:e=>Ps("ziggurat",e,25e4,1.28),Aluminium:e=>Ps("ziggurat",e,7e4,1.28),Mythril:e=>Ps("ziggurat",e,250,1.28)},effect(){let e=t.tech.ancient_study?.6:.4;if(t.tech.ancient_deify&&t.tech.ancient_deify>=2&&n.exotic_lab&&(e+=.01*n.exotic_lab),"theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let a=.002;t.race.high_pop&&(a=ke(a)),e+=a*t.civic.priest.workers}t.race.ooze&&(e*=1-Ei.ooze.vars()[1]/100),t.race.high_pop&&(e=ke(e)),e=+e.toFixed(2);let a=t.race.truepath?[e,Ki[t.race.species].home]:[e],r=`
                            ${z(t.race.truepath?"space_red_ziggurat_effect_tp":"space_red_ziggurat_effect",a)}
                            `;return t.tech.ancient_study&&t.tech.ancient_study>=2&&(r+=`
                            ${z("interstellar_laboratory_effect",[3])}
                            `),(t.race.cataclysm||t.race.orbit_decayed)&&(r+=Er()),t.genes.ancients&&t.genes.ancients>=4&&(r+=`
                            ${z("city_temple_effect6",[ta(1)])}
                            `),r},action(){return!!ri($(this)[0])&&(Ft("ziggurat"),t.genes.ancients&&t.genes.ancients>=4&&(t.civic.priest.display=!0),t.race.cataclysm&&qn("iron_will",!1,1),!0)}},space_barracks:{id:"space-space_barracks",title:z("space_red_space_barracks_title"),desc:()=>`
                            ${z("space_red_space_barracks_desc")}
                            ${z("space_red_space_barracks_desc_req")}
                            `,reqs:{marines:1},cost:{Money:e=>Ps("space_barracks",e,35e4,1.28),Alloy:e=>Ps("space_barracks",e,65e3,1.28),Iridium:e=>Ps("space_barracks",e,22500,1.28),Wrought_Iron:e=>Ps("space_barracks",e,12500,1.28),Horseshoe:()=>t.race.hooved?2:0},effect(e){let a=t.race.orbit_decayed?Mr.city.boot_camp.effect():"",r=+Rt(2,!0,e).toFixed(2),i=t.tech.marines>=2?ta(4):ta(2),s=t.race.cataclysm?"":`
                            ${z("space_red_space_barracks_effect3",[t.resource.Food.name])}
                            `;return`
                            ${z("plus_max_soldiers",[i])}
                            ${a}
                            ${z("space_red_space_barracks_effect2",[r])}
                            ${s}`},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("space_barracks"),t.space.space_barracks.on++,!0)},flair:()=>z("space_red_space_barracks_flair")},bonfire:Cr("bonfire","space"),horseshoe:Cr("horseshoe","space")},spc_hell:{info:{name:()=>Ut().hell,desc:()=>z("space_hell_info_desc",[Ut().hell]),zone:"inner",syndicate:()=>!1},hell_mission:{id:"space-hell_mission",title:()=>z("space_mission_title",[Ut().hell]),desc:()=>z("space_mission_desc",[Ut().hell]),reqs:{space:3,space_explore:3},grant:["hell",1],queue_complete:()=>t.tech.hell>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(6500,!1,t).toFixed(0)},effect:()=>z("space_hell_mission_effect1",[Ut().hell]),action(){return!!ri($(this)[0])&&(hs(z("space_hell_mission_action",[Ut().hell]),"info",!1,["progress"]),t.space.geothermal={count:0,on:0},!0)}},geothermal:{id:"space-geothermal",title:z("space_hell_geothermal_title"),desc:()=>`
                            ${z("space_hell_geothermal_desc")}
                            ${z("space_hell_geothermal_desc_req")}
                            `,reqs:{hell:1},cost:{Money:e=>Ps("geothermal",e,38e3,1.35),Steel:e=>Ps("geothermal",e,15e3,1.35),Polymer:e=>Ps("geothermal",e,9500,1.35)},effect(e){let a=+Rt($(this)[0].p_fuel().a,!0,e).toFixed(2);return`${t.race.cataclysm||t.race.orbit_decayed?`
                            ${z("interstellar_stellar_forge_effect3",[1])}
                            `:""}${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${z("space_belt_station_effect3",[a])}`},special:()=>!(!t.race.cataclysm&&!t.race.orbit_decayed),powered(){let e=-8;return t.race.forge&&(e-=Ei.forge.vars()[0]),t.stats.achieve.failed_history&&t.stats.achieve.failed_history.l>=5&&(e-=2),Fs(e)},p_fuel:()=>({r:"Helium_3",a:.5}),action(){return!!ri($(this)[0])&&(Ft("geothermal"),t.space.geothermal.on++,!0)}},hell_smelter:{id:"space-hell_smelter",title:()=>z("space_hell_smelter_title",[Ut().hell]),desc:()=>z("space_hell_smelter_title",[Ut().hell]),reqs:{hell:1,m_smelting:1},path:["truepath"],cost:{Money:e=>Ps("hell_smelter",e,25e4,1.24),Adamantite:e=>Ps("hell_smelter",e,15e3,1.24)},effect:()=>`
                            ${z("interstellar_stellar_forge_effect3",[2])}
                            `,special:!0,action(){return!!ri($(this)[0])&&(Ft("hell_smelter"),t.city.smelter.cap+=2,t.city.smelter.Steel+=2,t.city.smelter.Oil+=2,!0)}},spc_casino:{id:"space-spc_casino",title:z("city_casino"),desc:z("city_casino"),category:"commercial",reqs:{hell:1,gambling:1},condition:()=>!!(t.race.cataclysm||t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=5),cost:{Money:e=>Ps("spc_casino",e,4e5,1.35),Furs:e=>Ps("spc_casino",e,75e3,1.35),Cement:e=>Ps("spc_casino",e,1e5,1.35),Plywood:e=>Ps("spc_casino",e,2e4,1.35)},effect(){let e=Kr();return e+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,e},powered:()=>As(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2?2:3),action(){return!!ri($(this)[0])&&(t.space.spc_casino.count++,t.race.joyless||(t.civic.entertainer.max+=ta(1),t.civic.entertainer.display=!0),Yr($(this)[0]),!0)},flair:z("city_casino_flair")},swarm_plant:{id:"space-swarm_plant",title:z("space_hell_swarm_plant_title"),desc:()=>`
                            ${z("space_hell_swarm_plant_desc")}
                            `,reqs:{solar:4,hell:1},cost:{Money:e=>Ps("swarm_plant",e,Gt(75e3),1.28),Iron:e=>Ps("swarm_plant",e,Gt(65e3),1.28),Neutronium:e=>Ps("swarm_plant",e,Gt(75),1.28),Brick:e=>Ps("swarm_plant",e,Gt(2500),1.28),Mythril:e=>Ps("swarm_plant",e,Gt(100),1.28)},effect(){let e=t.tech.swarm?.88:.94;return t.tech.swarm>=3&&(e-=_/100),e<.05&&(e=.05),e=+(100*(1-e)).toFixed(2),z("space_hell_swarm_plant_effect1",[e])},action(){return!!ri($(this)[0])&&(Ft("swarm_plant"),!0)}},firework:Cr("firework","space")},spc_sun:{info:{name:()=>z("space_sun_info_name"),desc:()=>z("space_sun_info_desc",[Ki[t.race.species].home]),support:"swarm_control",zone:"inner",syndicate:()=>!1},sun_mission:{id:"space-sun_mission",title:()=>z("space_sun_mission_title"),desc:()=>z("space_sun_mission_desc"),reqs:{space_explore:4},grant:["solar",1],queue_complete:()=>t.tech.solar>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(15e3,!1,t).toFixed(0)},effect:()=>z("space_sun_mission_effect1"),action(){return!!ri($(this)[0])}},swarm_control:{id:"space-swarm_control",title:z("space_sun_swarm_control_title"),desc:()=>`
                            ${z("space_sun_swarm_control_desc")}
                            `,reqs:{solar:3},cost:{Money:e=>Ps("swarm_control",e,1e5,1.3),Knowledge:e=>Ps("swarm_control",e,6e4,1.3),Alloy:e=>Ps("swarm_control",e,7500,1.3),Helium_3:(e,t)=>Ps("swarm_control",e,Rt(2e3,!1,t),1.3),Mythril:e=>Ps("swarm_control",e,250,1.3)},effect(){return z("space_sun_swarm_control_effect1",[$(this)[0].support()])},support:()=>t.tech.swarm&&t.tech.swarm>=2?t.tech.high_tech>=11?11+Math.round(_):12:10,action(){return!!ri($(this)[0])&&(Ft("swarm_control"),t.space.swarm_control.s_max+=$(this)[0].support(),!0)}},swarm_satellite:{id:"space-swarm_satellite",title:z("space_sun_swarm_satellite_title"),desc:()=>`
                            ${z("space_sun_swarm_satellite_desc")}
                            ${z("space_sun_swarm_satellite_desc_req")}
                            `,reqs:{solar:3},cost:{Money:e=>Ps("swarm_satellite",e,Nt(5e3),1.1),Copper:e=>Ps("swarm_satellite",e,Nt(2500),1.1),Iridium:e=>Ps("swarm_satellite",e,Nt(150),1.1),Helium_3:(e,t)=>Ps("swarm_satellite",e,Nt(Rt(50,!1,t)),1.1)},effect(){let e=.35;return t.tech.swarm>=4&&(e+=.15*(t.tech.swarm-3)),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1&&(e+=.15),t.blood.illuminate&&(e+=.01*t.blood.illuminate),e=+e.toFixed(2),`${z("space_dwarf_reactor_effect1",[Fs(e)])}, ${z("space_sun_swarm_satellite_effect1",[1])}`},support:()=>-1,action(){return!!ri($(this)[0])&&(Ft("swarm_satellite"),t.space.swarm_control.support++,!0)}},jump_gate:{id:"space-jump_gate",title:z("tau_jump_gate"),desc:e=>!t.space.hasOwnProperty("jump_gate")||t.space.jump_gate.count<100||e?`
                            ${z("tau_jump_gate")}
                            ${z("requires_segmemts",[100])}
                            `:`
                            ${z("tau_jump_gate")}
                            `,reqs:{tauceti:3},path:["truepath"],queue_size:10,queue_complete:()=>100-t.space.jump_gate.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?1e6:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?5e4:0,Adamantite:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?12500:0,Graphene:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?42e3:0,Orichalcum:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?35e3:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0)<100?25e3:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("jump_gate")?t.space.jump_gate.count:0);if(a<100){let e=100-a;return`
                            ${z("tau_jump_gate_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}return z("tau_jump_gate_effect")},action(){return!!(ri($(this)[0])&&t.space.jump_gate.count<100)&&(t.space.jump_gate.count++,!0)}}},spc_gas:{info:{name:()=>Ut().gas,desc:()=>z("space_gas_info_desc",[Ut().gas,Ki[t.race.species].home]),zone:"outer",syndicate:()=>!0},gas_mission:{id:"space-gas_mission",title:()=>z("space_mission_title",[Ut().gas]),desc:()=>z("space_mission_desc",[Ut().gas]),reqs:{space:4,space_explore:4},grant:["space",5],queue_complete:()=>t.tech.space>=5?0:1,cost:{Helium_3:(e,t)=>+Rt(12500,!1,t).toFixed(0)},effect:()=>z("space_gas_mission_effect",[Ut().gas]),action(){return!!ri($(this)[0])&&(hs(z("space_gas_mission_action",[Ut().gas]),"info",!1,["progress"]),t.settings.space.gas_moon=!0,t.settings.space.belt=!0,t.space.space_station={count:0,on:0,support:0,s_max:0},!0)}},gas_mining:{id:"space-gas_mining",title:z("space_gas_mining_title"),desc:()=>`
                            ${z("space_gas_mining_desc")}
                            ${z("requires_power")}
                            `,reqs:{gas_giant:1},cost:{Money:e=>Ps("gas_mining",e,25e4,1.32),Uranium:e=>Ps("gas_mining",e,500,1.32),Alloy:e=>Ps("gas_mining",e,1e4,1.32),Helium_3:(e,t)=>Ps("gas_mining",e,Rt(2500,!1,t),1.32),Mythril:e=>Ps("gas_mining",e,25,1.32)},effect(){return`
                            ${z("space_gas_mining_effect1",[+$e("gas_mining").toFixed(2)])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(2),action(){return!!ri($(this)[0])&&(Ft("gas_mining"),Yr($(this)[0]),!0)}},gas_storage:{id:"space-gas_storage",title:()=>z("space_gas_storage_title",[Ut().gas]),desc:()=>`
                            ${z("space_gas_storage_desc")}
                            `,reqs:{gas_giant:1},cost:{Money:e=>Ps("gas_storage",e,125e3,1.32),Iridium:e=>Ps("gas_storage",e,3e3,1.32),Sheet_Metal:e=>Ps("gas_storage",e,2e3,1.32),Helium_3:(e,t)=>Ps("gas_storage",e,Rt(1e3,!1,t),1.32)},effect(){let e=br(3500)*(t.tech.world_control?1.5:1),a=br(2500)*(t.tech.world_control?1.5:1),r=br(1e3)*(t.tech.world_control?1.5:1);return`
                            ${z("plus_max_resource",[e,z("resource_Oil_name")])}
                            ${z("plus_max_resource",[a,z("resource_Helium_3_name")])}
                            ${z("plus_max_resource",[r,z("resource_Uranium_name")])}
                            `},action(){return!!ri($(this)[0])&&(Ft("gas_storage"),!0)}},star_dock:{id:"space-star_dock",title:()=>z("space_gas_star_dock_title"),desc:()=>`
                            ${z("space_gas_star_dock_title")}
                            ${z("space_gas_star_dock_desc_req")}
                            `,reqs:{genesis:3},queue_complete:()=>1-t.space.star_dock.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?15e5:0,Steel:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?5e5:0,Helium_3:(e,a)=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?Math.round(Rt(1e4,!1,a)):0,Nano_Tube:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?25e4:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("star_dock")?t.space.star_dock.count:0)===0?1e4:0},effect:()=>`
                            ${z("space_gas_star_dock_effect1")}
                            `,special:!0,action(){return!(0!==t.space.star_dock.count||!ri($(this)[0])||(Ft("star_dock"),0))}}},spc_gas_moon:{info:{name:()=>Ut().gas_moon,desc:()=>z("space_gas_moon_info_desc",[Ut().gas_moon,Ut().gas]),zone:"outer",syndicate:()=>!0},gas_moon_mission:{id:"space-gas_moon_mission",title:()=>z("space_mission_title",[Ut().gas_moon]),desc:()=>z("space_mission_desc",[Ut().gas_moon]),reqs:{space:5},grant:["space",6],queue_complete:()=>t.tech.space>=6?0:1,cost:{Helium_3:(e,t)=>+Rt(3e4,!1,t).toFixed(0)},effect:()=>z("space_gas_moon_mission_effect",[Ut().gas_moon]),action(){return!!ri($(this)[0])&&(hs(z("space_gas_moon_mission_action",[Ut().gas_moon]),"info",!1,["progress"]),t.space.outpost={count:0,on:0},t.tech.gas_moon=1,!0)}},outpost:{id:"space-outpost",title:z("space_gas_moon_outpost_title"),desc:()=>`
                            ${z("space_gas_moon_outpost_desc")}
                            ${z("requires_power_combo",[t.resource.Oil.name])}
                            `,reqs:{gas_moon:1},cost:{Money:e=>Ps("outpost",e,666e3,1.3),Titanium:e=>Ps("outpost",e,18e3,1.3),Iridium:e=>Ps("outpost",e,2500,1.3),Helium_3:(e,t)=>Ps("outpost",e,Rt(6e3,!1,t),1.3),Mythril:e=>Ps("outpost",e,300,1.3)},effect(e){let t=+$e("outpost").toFixed(3),a=br(500),r=+Rt(2,!0,e).toFixed(2);return`
                            ${z("space_gas_moon_outpost_effect1",[t])}
                            ${z("plus_max_resource",[a,z("resource_Neutronium_name")])}
                            ${z("space_gas_moon_outpost_effect3",[r,$(this)[0].powered()])}
                            `},powered:()=>As(3),powerBalancer:()=>[{r:"Neutronium",k:"lpmod"}],action(){return!!ri($(this)[0])&&(Ft("outpost"),t.resource.Neutronium.display=!0,Yr($(this)[0]),!0)}},drone:{id:"space-drone",title:z("space_gas_moon_drone_title"),desc:()=>`
                            ${z("space_gas_moon_drone_desc")}
                            `,reqs:{gas_moon:1,drone:1},cost:{Money:e=>Ps("drone",e,25e4,1.3),Steel:e=>Ps("drone",e,2e4,1.3),Neutronium:e=>Ps("drone",e,500,1.3),Elerium:e=>Ps("drone",e,25,1.3),Nano_Tube:e=>Ps("drone",e,45e3,1.3)},effect:()=>`
                            ${z("space_gas_moon_drone_effect1",[t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3?12:6])}
                            `,action(){return!!ri($(this)[0])&&(Ft("drone"),!0)}},oil_extractor:{id:"space-oil_extractor",title:z("space_gas_moon_oil_extractor_title"),desc:()=>`
                            ${z("space_gas_moon_oil_extractor_title")}
                            ${z("requires_power")}
                            `,reqs:{gas_moon:2},cost:{Money:e=>Ps("oil_extractor",e,666e3,1.3),Polymer:e=>Ps("oil_extractor",e,7500,1.3),Helium_3:(e,t)=>Ps("oil_extractor",e,Rt(2500,!1,t),1.3),Wrought_Iron:e=>Ps("oil_extractor",e,5e3,1.3)},effect(){return`${z("space_gas_moon_oil_extractor_effect1",[+$e("oil_extractor").toFixed(2)])}, ${z("minus_power",[$(this)[0].powered()])}`},powered:()=>As(1),powerBalancer:()=>[{r:"Oil",k:"lpmod"}],action(){return!!ri($(this)[0])&&(Ft("oil_extractor"),Yr($(this)[0]),!0)}}},spc_belt:{info:{name:()=>z("space_belt_info_name"),desc:()=>t.space.space_station&&t.space.space_station.count>0?`
                            ${z("space_belt_info_desc",[Ut().red,Ut().gas])}
                            ${z("space_belt_info_desc2")}
                            `:z("space_belt_info_desc",[Ut().red,Ut().gas]),support:"space_station",zone:"inner",syndicate:()=>!0},belt_mission:{id:"space-belt_mission",title:()=>z("space_belt_mission_title"),desc:()=>z("space_belt_mission_desc"),reqs:{space:5},grant:["asteroid",1],queue_complete:()=>t.tech.asteroid>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(25e3,!1,t).toFixed(0)},effect:()=>z("space_belt_mission_effect1"),action(){return!!ri($(this)[0])&&(hs(z("space_belt_mission_action"),"info",!1,["progress"]),t.settings.space.dwarf=!0,!0)}},space_station:{id:"space-space_station",title:z("space_belt_station_title"),desc:()=>`
                            ${z("space_belt_station_desc")}
                            ${z("requires_power_space",[t.resource.Food.name])}
                            `,reqs:{asteroid:2},cost:{Money:e=>Ps("space_station",e,25e4,1.3),Iron:e=>Ps("space_station",e,85e3,1.3),Polymer:e=>Ps("space_station",e,18e3,1.3),Iridium:e=>Ps("space_station",e,2800,1.28),Helium_3:(e,t)=>Ps("space_station",e,Rt(2e3,!1,t),1.3),Mythril:e=>Ps("space_station",e,75,1.25)},effect(e){let a=+Rt(2.5,!0,e).toFixed(2),r=t.race.cataclysm?1:10,i=br(5),s=t.tech.asteroid>=5?`
                            ${z("plus_max_resource",[i,z("resource_Elerium_name")])}
                            `:"";return`
                            ${z("plus_max_space_miners",[ta(3)])}
                            ${s}
                            ${z("space_belt_station_effect3",[a])}
                            ${z("space_belt_station_effect4",[r,$(this)[0].powered(),t.resource.Food.name])}
                            `},support:()=>ta(3),powered:()=>As(3),refresh:!0,action(){if(ri($(this)[0])){if(Ft("space_station"),t.civic.space_miner.display=!0,t.tech.asteroid<3&&(t.tech.asteroid=3),Yr($(this)[0])&&t.civic[t.civic.d_job].workers>0){let e=ta(3);t.civic[t.civic.d_job].workers-e<0&&(e=t.civic[t.civic.d_job].workers),t.civic[t.civic.d_job].workers-=e,t.civic.space_miner.workers+=e}return t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+1e3&&(t.race.orbit_decay=t.stats.days+1e3,hs(z("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0}return!1}},elerium_ship:{id:"space-elerium_ship",title:z("space_belt_elerium_ship_title"),desc:()=>z("space_belt_elerium_ship_title"),reqs:{asteroid:5},cost:{Money:e=>Ps("elerium_ship",e,5e5,1.3),Uranium:e=>Ps("elerium_ship",e,2500,1.3),Titanium:e=>Ps("elerium_ship",e,1e4,1.3),Mythril:e=>Ps("elerium_ship",e,500,1.3),Helium_3:(e,t)=>Ps("elerium_ship",e,Rt(5e3,!1,t),1.3)},effect(){let e=+$e("elerium_ship").toFixed(4);return`
                            ${z("space_belt_elerium_ship_effect1",[ta(2)])}
                            ${z("space_belt_elerium_ship_effect2",[e])}
                            `},support:()=>ta(-2),powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("elerium_ship"),t.space.space_station.support+1z("space_belt_iridium_ship_title"),reqs:{asteroid:3},cost:{Money:e=>Ps("iridium_ship",e,12e4,1.3),Uranium:e=>Ps("iridium_ship",e,1e3,1.3),Alloy:e=>Ps("iridium_ship",e,48e3,1.3),Iridium:e=>Ps("iridium_ship",e,2800,1.3),Helium_3:(e,t)=>Ps("iridium_ship",e,Rt(1800,!1,t),1.3)},effect(){let e=+$e("iridium_ship").toFixed(3);return`
                            ${z("space_belt_iridium_ship_effect1",[ta(1)])}
                            ${z("space_belt_iridium_ship_effect2",[e])}
                            `},support:()=>ta(-1),powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("iridium_ship"),t.space.space_station.supportz("space_belt_iron_ship_title"),reqs:{asteroid:3},cost:{Money:e=>Ps("iron_ship",e,8e4,1.3),Steel:e=>Ps("iron_ship",e,42e3,1.3),Aluminium:e=>Ps("iron_ship",e,38e3,1.3),Polymer:e=>Ps("iron_ship",e,16e3,1.3),Helium_3:(e,t)=>Ps("iron_ship",e,Rt(1200,!1,t),1.3)},effect(){let e=+$e("iron_ship").toFixed(2);return t.tech.solar&&t.tech.solar>=5?`
                            ${z("space_belt_iron_ship_effect1",[ta(1)])}
                            ${z("space_belt_iron_ship_effect2",[e])}
                            ${z("space_belt_iron_ship_effect3")}
                            `:`
                            ${z("space_belt_iron_ship_effect1",[ta(1)])}
                            ${z("space_belt_iron_ship_effect2",[e])}
                            `},support:()=>ta(-1),powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("iron_ship"),t.space.space_station.supportUt().dwarf,desc:()=>z("space_dwarf_info_desc",[Ut().dwarf]),zone:"inner",syndicate:()=>!1},dwarf_mission:{id:"space-dwarf_mission",title:()=>z("space_mission_title",[Ut().dwarf]),desc:()=>z("space_mission_desc",[Ut().dwarf]),reqs:{asteroid:1,elerium:1},grant:["dwarf",1],queue_complete:()=>t.tech.dwarf>=1?0:1,cost:{Helium_3:(e,t)=>+Rt(45e3,!1,t).toFixed(0)},effect:()=>z("space_dwarf_mission_effect1",[Ut().dwarf]),action(){return!!ri($(this)[0])&&(hs(z("space_dwarf_mission_action",[Ut().dwarf]),"info",!1,["progress"]),t.space.elerium_contain={count:0,on:0},!0)}},elerium_contain:{id:"space-elerium_contain",title:z("space_dwarf_elerium_contain_title"),desc:()=>`
                            ${z("space_dwarf_elerium_contain_title")}
                            ${z("requires_power")}
                            `,reqs:{dwarf:1},cost:{Money:e=>Ps("elerium_contain",e,8e5,1.28),Cement:e=>Ps("elerium_contain",e,12e4,1.28),Iridium:e=>Ps("elerium_contain",e,5e4,1.28),Neutronium:e=>Ps("elerium_contain",e,250,1.28)},effect(){return`
                            ${z("plus_max_resource",[br(100),z("resource_Elerium_name")])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(6),action(){return!!ri($(this)[0])&&(Ft("elerium_contain"),Yr($(this)[0]),!0)}},e_reactor:{id:"space-e_reactor",title:z("space_dwarf_reactor_title"),desc:()=>`
                            ${z("space_dwarf_reactor_title")}
                            ${z("space_dwarf_reactor_desc_req")}
                            `,reqs:{elerium:2},cost:{Money:e=>Ps("e_reactor",e,125e4,1.28),Steel:e=>Ps("e_reactor",e,35e4,1.28),Neutronium:e=>Ps("e_reactor",e,1250,1.28),Mythril:e=>Ps("e_reactor",e,2500,1.28)},effect(){let e=$(this)[0].p_fuel().a;return`
                            ${z("space_dwarf_reactor_effect1",[-1*$(this)[0].powered()])}
                            ${z("space_dwarf_reactor_effect2",[e])}
                            `},powered:()=>Fs(-25),p_fuel:()=>({r:"Elerium",a:.05}),action(){return!!ri($(this)[0])&&(Ft("e_reactor"),t.space.e_reactor.on++,!0)}},world_collider:{id:"space-world_collider",title:z("space_dwarf_collider_title"),desc(e){if(!t.space.hasOwnProperty("world_collider")||t.space.world_collider.count<1859||e)return`
                            ${z("space_dwarf_collider_desc")}
                            ${z("space_dwarf_collider_desc_req")}
                            `+(t.space.hasOwnProperty("world_collider")&&t.space.world_collider.count>=1859?`
                            ${z("requires_power")}
                            `:"")},reqs:{science:10},path:["standard"],condition:()=>t.space.world_collider.count<1859,queue_size:100,queue_complete:()=>1859-t.space.world_collider.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?25e3:0,Copper:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?750:0,Alloy:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?125:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?12:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?1:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0)<1859?10:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("world_collider")?t.space.world_collider.count:0);if(a<1859){let e=1859-a;return`
                            ${z("space_dwarf_collider_effect1")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}return $t.spc_dwarf.world_controller.effect()},action(){if(t.space.world_collider.count<1859&&ri($(this)[0])){if(Ft("world_collider"),t.space.world_collider.count>=1859){if(t.tech.science=11,t.space.world_controller={count:1,on:0},Qr(),Lt(),t.race.banana){let e=xn();t.stats.banana.b2[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b2.l=!0)}_s()}return!0}return!1},flair:z("space_dwarf_collider_flair")},world_controller:{id:"space-world_controller",title:z("space_dwarf_collider_title"),desc:()=>`
                            ${z("space_dwarf_collider_title")}
                            ${z("requires_power")}
                            `,wiki:!1,reqs:{science:11},path:["standard"],condition:()=>!(t.space.world_collider.count<1859),queue_complete:()=>0,cost:{},effect(){let e=25;return t.interstellar.far_reach&&s.far_reach>0&&(e+=1*s.far_reach),t.tech.science>=19&&(e+=15),`
                            ${z("plus_max_resource",[e+"%",z("resource_Knowledge_name")])}
                            ${z("space_dwarf_controller_effect3")}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(20),action:()=>!1,flair:z("space_dwarf_controller_flair")},shipyard:{id:"space-shipyard",title:z("outer_shipyard_title"),desc:()=>`
                            ${z("outer_shipyard_title")}
                            ${z("requires_power")}
                            `,reqs:{shipyard:1},path:["truepath"],cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e7:0,Aluminium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e6:0,Titanium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?65e4:0,Iridium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?25e4:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?1e4:0,Mythril:e=>(e||0)+(t.space.hasOwnProperty("shipyard")?t.space.shipyard.count:0)<1?5e5:0},queue_complete:()=>1-t.space.shipyard.count,effect(){return`
                            ${z("outer_shipyard_effect")}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(50),special:!0,sAction(){s.shipyard&&(t.settings.civTabs=2,t.settings.govTabs=5,t.settings.tabLoad||(kt("mTabCivic"),_s("space-shipyard")))},action(){return!!(t.space.shipyard.count<1&&ri($(this)[0]))&&(Ft("shipyard"),Yr($(this)[0])&&(t.settings.showShipYard=!0),t.tech.syard_class=2,t.tech.syard_armor=3,t.tech.syard_weapon=1,t.tech.syard_engine=2,t.tech.syard_power=3,t.tech.syard_sensor=3,!0)}},mass_relay:{id:"space-mass_relay",title:z("space_dwarf_mass_relay_title"),desc(e){if(!t.space.hasOwnProperty("mass_relay")||t.space.mass_relay.count<100||e)return`
                            ${z("space_dwarf_mass_relay_title")}
                            ${z("requires_segmemts",[100])}
                            `},reqs:{outer:5},path:["truepath"],condition:()=>t.space.mass_relay.count<100,queue_size:5,queue_complete:()=>100-t.space.mass_relay.count,cost:{Money:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?1e7:0,Neutronium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?7500:0,Adamantite:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?18e3:0,Elerium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?125:0,Stanene:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?1e5:0,Quantium:e=>(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0)<100?25e3:0},effect(e){let a=(e||0)+(t.space.hasOwnProperty("mass_relay")?t.space.mass_relay.count:0);if(a<100){let e=100-a;return`
                            ${z("space_dwarf_mass_relay_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}return $t.spc_dwarf.m_relay.effect()},action(){return!!(t.space.mass_relay.count<100&&ri($(this)[0]))&&(t.space.mass_relay.count++,t.space.mass_relay.count>=100&&(t.tech.outer=6,t.space.m_relay={count:1,on:1,charged:0},Qr(),Lt(),_s()),!0)}},m_relay:{id:"space-m_relay",title:z("space_dwarf_mass_relay_title"),desc:()=>`
                            ${z("space_dwarf_mass_relay_title")}
                            ${z("requires_power")}
                            `,reqs:{outer:6},path:["truepath"],condition:()=>t.space.mass_relay.count>=100,wiki:!1,queue_complete:()=>0,cost:{},powered:()=>As(100),effect(){let e=Math.floor(t.space.m_relay.charged/10)/10;return`
                            ${z("space_dwarf_mass_relay_effect2",[Ut().dwarf])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            ${z("space_dwarf_mass_relay_charged",[e])}
                            `},action:()=>!1}},spc_titan:We().spc_titan,spc_enceladus:We().spc_enceladus,spc_triton:We().spc_triton,spc_kuiper:We().spc_kuiper,spc_eris:We().spc_eris},xt={int_alpha:{info:{name:z("interstellar_alpha_name"),desc:()=>t.tech.alpha?z("interstellar_alpha_desc2",[Ki[t.race.species].home]):z("interstellar_alpha_desc1",[Ki[t.race.species].home]),support:"starport"},alpha_mission:{id:"interstellar-alpha_mission",title:z("space_mission_title",[z("interstellar_alpha_name")]),desc:z("space_mission_desc",[z("interstellar_alpha_name")]),reqs:{ftl:2},grant:["alpha",1],queue_complete:()=>t.tech.alpha>=1?0:1,cost:{Helium_3:()=>+Ht(4e4).toFixed(0)},effect:z("interstellar_alpha_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("interstellar_alpha_mission_result"),"info",!1,["progress"]),t.interstellar.nexus={count:0,on:0,support:0,s_max:0},t.interstellar.warehouse={count:0},!0)}},starport:{id:"interstellar-starport",title:z("interstellar_alpha_starport_title"),desc:()=>`
                            ${z("interstellar_alpha_starport_desc")}
                            ${z("requires_power_space",[t.resource.Food.name])}
                            `,reqs:{alpha:1},cost:{Money:e=>Ps("starport",e,1e6,1.3,"interstellar"),Aluminium:e=>Ps("starport",e,4e5,1.3,"interstellar"),Neutronium:e=>Ps("starport",e,1e3,1.3,"interstellar"),Elerium:e=>Ps("starport",e,100,1.3,"interstellar")},effect(){let e=+Ht(5).toFixed(2);return`
                            ${z("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
                            ${z("interstellar_alpha_starport_effect2",[e,$(this)[0].powered()])}
                            ${z("interstellar_alpha_starport_effect3",[100,t.resource.Food.name])}
                            `},support:()=>5,powered:()=>As(10),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("starport","interstellar"),t.settings.space.proxima=!0,t.settings.space.nebula=!0,Yr($(this)[0]),1===t.tech.alpha&&(t.tech.alpha=2,t.interstellar.mining_droid={count:0,on:0,adam:0,uran:0,coal:0,alum:0}),t.race.orbit_decay&&t.race.orbit_decay>t.stats.days+100&&(t.race.orbit_decay=t.stats.days+100,hs(z("evo_challenge_orbit_decayed_accelerated",[t.race.orbit_decay-t.stats.days]),"info",!1,["progress"])),!0)}},habitat:{id:"interstellar-habitat",title:z("interstellar_habitat_title"),desc:`
                            ${z("interstellar_habitat_desc")}
                            ${z("requires_power")}
                            `,reqs:{alpha:3},cost:{Money:e=>Ps("habitat",e,8e5,1.25,"interstellar"),Furs:e=>Ps("habitat",e,38e3,1.25,"interstellar"),Adamantite:e=>Ps("habitat",e,3200,1.25,"interstellar"),Plywood:e=>Ps("habitat",e,1e4,1.25,"interstellar"),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return`
                            ${z("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
                            ${z("plus_max_citizens",[e])}, ${z("minus_power",[$(this)[0].powered()])}
                            `},support:()=>1,powered:()=>As(2),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],action(){return!!ri($(this)[0])&&(Ft("habitat","interstellar"),Yr($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens()),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},mining_droid:{id:"interstellar-mining_droid",title:z("interstellar_mining_droid_title"),desc:`
                            ${z("interstellar_mining_droid_title")}
                            ${z("space_support",[z("interstellar_alpha_name")])}
                            `,reqs:{alpha:2},cost:{Money:e=>Ps("mining_droid",e,65e4,1.28,"interstellar"),Steel:e=>Ps("mining_droid",e,12e4,1.28,"interstellar"),Nano_Tube:e=>Ps("mining_droid",e,75e3,1.28,"interstellar"),Elerium:e=>Ps("mining_droid",e,50,1.28,"interstellar")},effect:()=>`
                            ${z("space_used_support",[z("interstellar_alpha_name")])}
                            ${z("interstellar_mining_droid_effect")}
                            `,support:()=>-1,powered:()=>As(1),special:!0,refresh:!0,action(){return!!ri($(this)[0])&&(Ft("mining_droid","interstellar"),t.resource.Adamantite.display=!0,t.interstellar.starport.support${z("interstellar_processing_title")}
                            ${z("space_support",[z("interstellar_alpha_name")])}
                            `,reqs:{droids:1},cost:{Money:e=>Ps("processing",e,35e4,1.28,"interstellar"),Iron:e=>Ps("processing",e,18e4,1.28,"interstellar"),Aluminium:e=>Ps("processing",e,6e4,1.28,"interstellar"),Iridium:e=>Ps("processing",e,5e3,1.28,"interstellar")},effect(){let e=12;return t.tech.ai_core&&t.tech.ai_core>=2&&s.citadel>0&&(e+=2*s.citadel),`
                            ${z("space_used_support",[z("interstellar_alpha_name")])}
                            ${z("interstellar_processing_effect",[e])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("processing","interstellar"),t.interstellar.starport.support`
                            ${z("interstellar_fusion_title")}
                            ${z("requires_power_support_combo",[z("interstellar_alpha_name"),t.resource.Deuterium.name])}
                            `,reqs:{fusion:1},cost:{Money:e=>Ps("fusion",e,99e4,1.28,"interstellar"),Iridium:e=>Ps("fusion",e,44e3,1.28,"interstellar"),Infernite:e=>Ps("fusion",e,350,1.28,"interstellar"),Brick:e=>Ps("fusion",e,18e3,1.28,"interstellar")},effect(){return`
                            ${z("space_used_support",[z("interstellar_alpha_name")])}
                            ${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}, ${z("interstellar_fusion_effect",[1.25])}
                            `},support:()=>-1,powered:()=>Fs(-22),p_fuel:()=>({r:"Deuterium",a:1.25}),action(){return!!ri($(this)[0])&&(Ft("fusion","interstellar"),t.interstellar.starport.support"magic"===t.race.universe?z("tech_sanctum"):z("interstellar_laboratory_title"),desc:`
                            ${z("magic"===t.race.universe?"tech_sanctum":"interstellar_laboratory_title")}
                            ${z("space_support",[z("interstellar_alpha_name")])}
                            `,reqs:{science:12},cost:{Money:e=>Ps("laboratory",e,75e4,1.28,"interstellar"),Crystal:e=>"magic"===t.race.universe?Ps("laboratory",e,1200,1.28,"interstellar"):0,Titanium:e=>Ps("laboratory",e,12e4,1.28,"interstellar"),Alloy:e=>Ps("laboratory",e,95e3,1.28,"interstellar"),Mythril:e=>Ps("laboratory",e,8500,1.28,"interstellar")},effect(){let e=1e4;t.tech.science>=15&&(e*=1+.02*(t.race.cataclysm||t.race.orbit_decayed?n.exotic_lab:t.city.wardenclyffe.count)),(t.race.cataclysm||t.race.orbit_decayed&&s.s_gate&&o.scavenger)&&(e*=1+o.scavenger*+(.75*Mt("gxy_alien2")).toFixed(1)),t.tech.science>=21&&(e*=1.45),e=Math.round(e);let a="";t.tech.science>=16&&(a=`
                            ${z("city_wardenclyffe_effect1",[ta(1),t.civic.scientist.name])}
                            `);let r=`
                            ${z("space_used_support",[z("interstellar_alpha_name")])}
                            ${a}
                            ${z("city_max_knowledge",[e])}
                            `;return t.tech.science>=13&&(r+=`
                            ${z("interstellar_laboratory_effect",[5])}
                            `),"magic"===t.race.universe&&(r+=`
                            ${z("plus_max_resource",[br(12),t.resource.Mana.name])}
                            `),r},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("laboratory","interstellar"),t.interstellar.starport.support${z("interstellar_exchange_title")}
                            ${z("space_support",[z("interstellar_alpha_name")])}
                            `,reqs:{banking:12},cost:{Money:e=>Ps("exchange",e,68e4,1.28,"interstellar"),Stone:e=>Ps("exchange",e,115e3,1.28,"interstellar"),Adamantite:e=>Ps("exchange",e,55e3,1.28,"interstellar"),Graphene:e=>Ps("exchange",e,78e3,1.28,"interstellar")},effect(){let e=t.race.cataclysm||t.race.orbit_decayed?s.spaceport:t.city.bank?t.city.bank.count:0,a=t.race.cataclysm||t.race.orbit_decayed?4*bi():bi(),r=br(t.city.bank?a*e/18:0);return t.race.inflation&&(r*=2),t.tech.banking>=13&&(t.galaxy.freighter&&(r*=1+.03*o.freighter),t.galaxy.super_freighter&&(r*=1+.08*o.super_freighter)),r=+r.toFixed(0),`
                            ${z("space_used_support",[z("interstellar_alpha_name")])}
                            ${z("plus_max_resource",[`$${r.toLocaleString()}`,z("resource_Money_name")])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("exchange","interstellar"),t.interstellar.starport.support${z("interstellar_g_factory_title")}
                            ${z("space_support",[z("interstellar_alpha_name")])}
                            `,reqs:{graphene:1},cost:{Money:e=>Ps("g_factory",e,95e4,1.28,"interstellar"),Copper:e=>Ps("g_factory",e,165e3,1.28,"interstellar"),Cement:e=>Ps("g_factory",e,22e4,1.28,"interstellar"),Infernite:e=>Ps("g_factory",e,750,1.28,"interstellar")},effect:()=>`
                            ${z("space_used_support",[z("interstellar_alpha_name")])}
                            ${z("interstellar_g_factory_effect")}
                            `,support:()=>-1,powered:()=>As(1),special:!0,action(){return!!ri($(this)[0])&&(Ft("g_factory","interstellar"),t.resource.Graphene.display=!0,t.interstellar.starport.support`
                            ${z("interstellar_int_factory_title")}
                            ${z("requires_power_combo",[t.resource.Deuterium.name])}
                            `,reqs:{alpha:4},cost:{Money:e=>Ps("int_factory",e,25e6,1.26,"interstellar"),Coal:e=>Ps("int_factory",e,1e7,1.26,"interstellar"),Brick:e=>Ps("int_factory",e,75e4,1.26,"interstellar"),Bolognium:e=>Ps("int_factory",e,5e4,1.26,"interstellar")},effect(){let e=+Ht(5).toFixed(2);return`
                            ${z("interstellar_int_factory_effect")}
                            ${z("city_crafted_mats",[10])}
                            ${z("interstellar_fusion_effect",[e])} ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(5),special:!0,action(){return!!ri($(this)[0])&&(Ft("int_factory","interstellar"),Yr($(this)[0])&&(t.city.factory.Alloy+=2,ki()),!0)}},luxury_condo:{id:"interstellar-luxury_condo",title:z("tech_luxury_condo"),desc:`
                            ${z("tech_luxury_condo")}
                            ${z("requires_power")}
                            `,reqs:{alpha:5},cost:{Money:e=>Ps("luxury_condo",e,25e6,1.25,"interstellar"),Neutronium:e=>Ps("luxury_condo",e,75e3,1.25,"interstellar"),Stanene:e=>Ps("luxury_condo",e,23e4,1.25,"interstellar"),Orichalcum:e=>Ps("luxury_condo",e,65e3,1.25,"interstellar"),Nanoweave:e=>Ps("luxury_condo",e,12500,1.25,"interstellar"),Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens(),t=br(75e4);return`
                            ${z("plus_max_citizens",[e])}, ${z("minus_power",[$(this)[0].powered()])}
                            ${z("plus_max_resource",[`$${t.toLocaleString()}`,z("resource_Money_name")])}
                            `},powered:()=>As(3),action(){return!!ri($(this)[0])&&(Ft("luxury_condo","interstellar"),Yr($(this)[0])&&(t.resource[t.race.species].max+=2),!0)},citizens(){let e=2;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},zoo:{id:"interstellar-zoo",title:z("tech_zoo"),desc:()=>`
                            ${z("tech_zoo")}
                            ${z("requires_power_support_combo",[z("interstellar_alpha_name"),t.resource.Food.name])}
                            `,reqs:{zoo:1},cost:{Money:e=>Ps("zoo",e,5e7,1.24,"interstellar"),Polymer:e=>Ps("zoo",e,6e6,1.24,"interstellar"),Infernite:e=>Ps("zoo",e,75e3,1.24,"interstellar"),Brick:e=>Ps("zoo",e,2e6,1.24,"interstellar")},effect:()=>`
                            ${z("space_used_support",[z("interstellar_alpha_name")])}
                            ${z("space_red_vr_center_effect1",[5])}
                            ${z("space_red_vr_center_effect2",[2])}
                            ${z("interstellar_alpha_starport_effect3",[12e3,t.resource.Food.name])}
                            `,powered:()=>As(3),action(){return!!ri($(this)[0])&&(Ft("zoo","interstellar"),t.interstellar.starport.supportt.tech.storage<=2?z("city_shed_title1"):t.tech.storage>=4?z("city_shed_title3"):z("city_shed_title2"),desc(){let e=t.tech.storage>=3?t.tech.storage>=4?z("city_shed_desc_size3"):z("city_shed_desc_size2"):z("city_shed_desc_size1");return z("city_shed_desc",[e])},reqs:{alpha:2},cost:{Money:e=>Ps("warehouse",e,175e3,1.28,"interstellar"),Lumber:e=>Ps("warehouse",e,1e5,1.28,"interstellar"),Aluminium:e=>Ps("warehouse",e,12e4,1.28,"interstellar"),Cement:e=>Ps("warehouse",e,45e3,1.28,"interstellar")},res(){let e=["Lumber","Stone","Chrysotile","Furs","Copper","Iron","Aluminium","Cement","Coal","Nano_Tube","Neutronium","Adamantite","Infernite"];return t.tech.storage>=3&&t.resource.Steel.display&&e.push("Steel"),t.tech.storage>=4&&t.resource.Titanium.display&&e.push("Titanium"),e},val(e){switch(e){case"Lumber":case"Stone":case"Chrysotile":return 750;case"Furs":return 425;case"Copper":return 380;case"Iron":return 350;case"Aluminium":return 320;case"Cement":return 280;case"Coal":return 120;case"Steel":return 60;case"Titanium":return 40;case"Nano_Tube":return 30;case"Neutronium":return 8;case"Adamantite":return 18;case"Infernite":return 5;default:return 0}},wide:!0,effect(){let e='
                            ',a=Gr();for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${z("plus_max_resource",[x(+(br($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return e+="
                            ",e},action(){if(ri($(this)[0])){Ft("warehouse","interstellar");let e=Gr();for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=br($(this)[0].val(a)*e));return!0}return!1}}},int_proxima:{info:{name:z("interstellar_proxima_name"),desc:()=>t.tech.proxima?z("interstellar_proxima_desc2"):z("interstellar_proxima_desc1")},proxima_mission:{id:"interstellar-proxima_mission",title:z("space_mission_title",[z("interstellar_proxima_name")]),desc:z("space_mission_desc",[z("interstellar_proxima_name")]),reqs:{alpha:1},grant:["proxima",1],queue_complete:()=>t.tech.proxima>=1?0:1,cost:{Helium_3:()=>+Ht(42e3).toFixed(0)},effect:z("interstellar_proxima_mission_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.xfer_station={count:0,on:0},hs(z("interstellar_proxima_mission_result"),"info",!1,["progress"]),!0)}},xfer_station:{id:"interstellar-xfer_station",title:z("interstellar_xfer_station_title"),desc:()=>`
                            ${z("interstellar_xfer_station_desc")}
                            ${z("requires_power_combo",[t.resource.Uranium.name])}
                            `,reqs:{proxima:1},cost:{Money:e=>Ps("xfer_station",e,12e5,1.28,"interstellar"),Neutronium:e=>Ps("xfer_station",e,1500,1.28,"interstellar"),Adamantite:e=>Ps("xfer_station",e,6e3,1.28,"interstellar"),Polymer:e=>Ps("xfer_station",e,12e3,1.28,"interstellar"),Wrought_Iron:e=>Ps("xfer_station",e,3500,1.28,"interstellar")},effect(){let e=br(5e3),a=br(4e3),r=br(2500),i="";return t.resource.Deuterium.display&&(i=`
                            ${z("plus_max_resource",[br(2e3),z("resource_Deuterium_name")])}
                            `),`
                            ${z("interstellar_alpha_starport_effect1",[$(this)[0].support()])}
                            ${z("plus_max_resource",[a,z("resource_Oil_name")])}
                            ${z("plus_max_resource",[e,z("resource_Helium_3_name")])}
                            ${z("plus_max_resource",[r,z("resource_Uranium_name")])}
                            ${i}
                            ${z("city_fission_power_effect",[.28])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},support:()=>1,powered:()=>As(1),powerBalancer:()=>[{s:t.interstellar.starport.s_max-t.interstellar.starport.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("xfer_station","interstellar"),Yr($(this)[0])&&(t.resource.Uranium.max+=br(2500),t.resource.Helium_3.max+=br(5e3),t.resource.Oil.max+=br(4e3),t.resource.Deuterium.max+=br(2e3)),1===t.tech.proxima&&(t.tech.proxima=2,t.interstellar.cargo_yard={count:0}),!0)}},cargo_yard:{id:"interstellar-cargo_yard",title:z("interstellar_cargo_yard_title"),desc:z("interstellar_cargo_yard_title"),reqs:{proxima:2},cost:{Money:e=>Ps("cargo_yard",e,275e3,1.28,"interstellar"),Graphene:e=>Ps("cargo_yard",e,7500,1.28,"interstellar"),Mythril:e=>Ps("cargo_yard",e,6e3,1.28,"interstellar")},effect(){let e=br(200),a=br(150),r=`
                            ${z("plus_max_resource",[50,z("resource_Crates_name")])}
                            ${z("plus_max_resource",[50,z("resource_Containers_name")])}
                            `;return r+=`
                            ${z("plus_max_resource",[e,z("resource_Neutronium_name")])}
                            ${z("plus_max_resource",[a,z("resource_Infernite_name")])}
                            `,t.tech.storage>=7&&(r+=`
                            ${z("interstellar_cargo_yard_effect",[+_.toFixed(3)])}
                            `),r},action(){return!!ri($(this)[0])&&(Ft("cargo_yard","interstellar"),!0)}},cruiser:{id:"interstellar-cruiser",title:z("interstellar_cruiser_title"),desc:z("interstellar_cruiser_title"),reqs:{cruiser:1},cost:{Money:e=>Ps("cruiser",e,875e3,1.28,"interstellar"),Aluminium:e=>Ps("cruiser",e,195e3,1.28,"interstellar"),Deuterium:e=>Ps("cruiser",e,+Ht(1500).toFixed(0),1.28,"interstellar"),Neutronium:e=>Ps("cruiser",e,2e3,1.28,"interstellar"),Aerogel:e=>Ps("cruiser",e,250,1.28,"interstellar"),Horseshoe:()=>t.race.hooved?3:0},powered:()=>As(1),effect(){let e=+Ht(6).toFixed(2);return`
                            ${z("plus_max_soldiers",[ta(3)])}
                            ${z("space_belt_station_effect3",[e])}
                            `},action(){return!!ri($(this)[0])&&(Ft("cruiser","interstellar"),t.interstellar.cruiser.on++,!0)}},dyson:{id:"interstellar-dyson",title:z("interstellar_dyson_title"),desc:e=>!t.interstellar.hasOwnProperty("dyson")||t.interstellar.dyson.count<100||e?`
                            ${z("interstellar_dyson_title")}
                            ${z("requires_segmemts",[100])}
                            `:`
                            ${z("interstellar_dyson_title")}
                            `,reqs:{proxima:3},queue_size:10,queue_complete:()=>100-t.interstellar.dyson.count,condition:()=>!(t.interstellar.dyson.count>=100&&t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?25e4:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?1e4:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?25:0,Stanene:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0)<100?1e5:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("dyson")?t.interstellar.dyson.count:0);if(a<100){let e=a>0?`
                            ${z("space_dwarf_reactor_effect1",[Fs(1.25*a)])}
                            `:"",t=100-a;return`
                            ${z("interstellar_dyson_effect")}
                            ${e}
                            ${z("space_dwarf_collider_effect2",[t])}
                            `}return z("interstellar_dyson_complete",[Fs(175)])},action(){return!!(ri($(this)[0])&&t.interstellar.dyson.count<100)&&(Ft("dyson","interstellar"),t.interstellar.dyson.count>=100&&Qr(),!0)}},dyson_sphere:{id:"interstellar-dyson_sphere",title:z("interstellar_dyson_sphere_title"),desc:e=>!t.interstellar.hasOwnProperty("dyson_sphere")||t.interstellar.dyson_sphere.count<100||e?`
                            ${z("interstellar_dyson_sphere_title")}
                            ${z("requires_segmemts",[100])}
                            `:`
                            ${z("interstellar_dyson_sphere_title")}
                            `,reqs:{proxima:3,dyson:1},queue_size:10,queue_complete:()=>100-t.interstellar.dyson_sphere.count,condition:()=>!!(t.interstellar.dyson.count>=100&&t.tech.dyson&&1===t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?5e6:0,Bolognium:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?25e3:0,Vitreloy:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?1250:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("dyson_sphere")?t.interstellar.dyson_sphere.count:0);if(a<100){let e=175+5*a,t=100-a;return`
                            ${z("interstellar_dyson_sphere_effect")}
                            ${z("space_dwarf_reactor_effect1",[Fs(e)])}
                            ${z("space_dwarf_collider_effect2",[t])}
                            `}return z("interstellar_dyson_sphere_complete",[Fs(750)])},action(){return!!(ri($(this)[0])&&t.interstellar.dyson_sphere.count<100)&&(Ft("dyson_sphere","interstellar"),t.interstellar.dyson_sphere.count>=100&&Qr(),!0)}},orichalcum_sphere:{id:"interstellar-orichalcum_sphere",title:z("interstellar_dyson_sphere_title"),desc:e=>!t.interstellar.hasOwnProperty("orichalcum_sphere")||t.interstellar.orichalcum_sphere.count<100||e?`
                            ${z("interstellar_orichalcum_sphere_desc")}
                            ${z("requires_segmemts",[100])}
                            `:`
                            ${z("interstellar_orichalcum_sphere_desc")}
                            `,reqs:{proxima:3,dyson:2},queue_size:10,queue_complete:()=>100-t.interstellar.orichalcum_sphere.count,condition:()=>!!(t.interstellar.dyson_sphere.count>=100&&t.tech.dyson&&2===t.tech.dyson),cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0)<100?25e6:0,Orichalcum:e=>(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("orichalcum_sphere")?t.interstellar.orichalcum_sphere.count:0);if(a<100){let e=750+8*a,t=100-a;return`
                            ${z("interstellar_orichalcum_sphere_effect")}
                            ${z("space_dwarf_reactor_effect1",[Fs(e)])}
                            ${z("space_dwarf_collider_effect2",[t])}
                            `}return z("interstellar_dyson_sphere_complete",[Fs(1750)])},action(){return!!(ri($(this)[0])&&t.interstellar.orichalcum_sphere.count<100)&&(Ft("orichalcum_sphere","interstellar"),t.interstellar.orichalcum_sphere.count>=100&&qn("blacken_the_sun"),!0)}}},int_nebula:{info:{name:z("interstellar_nebula_name"),desc:()=>t.tech.nebula?z("interstellar_nebula_desc2"):z("interstellar_nebula_desc1"),support:"nexus"},nebula_mission:{id:"interstellar-nebula_mission",title:z("space_mission_title",[z("interstellar_nebula_name")]),desc:z("space_mission_desc",[z("interstellar_nebula_name")]),reqs:{alpha:1},grant:["nebula",1],queue_complete:()=>t.tech.nebula>=1?0:1,cost:{Helium_3:()=>+Ht(55e3).toFixed(0)},effect:z("interstellar_nebula_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("interstellar_nebula_mission_result"),"info",!1,["progress"]),!0)}},nexus:{id:"interstellar-nexus",title:z("interstellar_nexus_title"),desc:()=>`
                            ${z("interstellar_nexus_title")}
                            ${z("requires_power_combo",[t.resource.Money.name])}
                            `,reqs:{nebula:1},cost:{Money:e=>Ps("nexus",e,9e5,1.24,"interstellar"),Adamantite:e=>Ps("nexus",e,7500,1.24,"interstellar"),Infernite:e=>Ps("nexus",e,250,1.24,"interstellar"),Sheet_Metal:e=>Ps("nexus",e,14e3,1.24,"interstellar"),Nano_Tube:e=>Ps("nexus",e,17500,1.24,"interstellar")},effect(){let e=br(3500),t=br(4e3),a=br(3e3),r=br(25);return`
                            ${z("interstellar_nexus_effect1",[$(this)[0].support()])}
                            ${z("plus_max_resource",[e,z("resource_Oil_name")])}
                            ${z("plus_max_resource",[t,z("resource_Helium_3_name")])}
                            ${z("plus_max_resource",[a,z("resource_Deuterium_name")])}
                            ${z("plus_max_resource",[r,z("resource_Elerium_name")])}
                            ${z("interstellar_nexus_effect2",[$(this)[0].powered(),350])}
                            `},support:()=>2,powered:()=>As(8),powerBalancer:()=>[{s:t.interstellar.nexus.s_max-t.interstellar.nexus.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("nexus","interstellar"),t.resource.Deuterium.display=!0,1===t.tech.nebula&&(t.interstellar.harvester={count:0,on:0},t.tech.nebula=2),Yr($(this)[0])&&(t.resource.Oil.max+=br(2500),t.resource.Helium_3.max+=br(4e3),t.resource.Deuterium.max+=br(3e3),t.resource.Elerium.max+=br(25)),!0)}},harvester:{id:"interstellar-harvester",title:z("interstellar_harvester_title"),desc:`
                            ${z("interstellar_harvester_title")}
                            ${z("space_support",[z("interstellar_nebula_name")])}
                            `,reqs:{nebula:2},cost:{Money:e=>Ps("harvester",e,65e4,1.28,"interstellar"),Copper:e=>Ps("harvester",e,8e4,1.28,"interstellar"),Alloy:e=>Ps("harvester",e,45e3,1.28,"interstellar"),Iridium:e=>Ps("harvester",e,8e3,1.28,"interstellar")},effect(){let e=+$e("harvester","helium").toFixed(3),a=+$e("harvester","deuterium").toFixed(3),r=t.tech.ram_scoop?`
                            ${z("interstellar_harvester_effect",[a])}
                            `:"";return`
                            ${z("space_used_support",[z("interstellar_nebula_name")])}
                            ${z("space_gas_mining_effect1",[e])}
                            ${r}`},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("harvester","interstellar"),t.interstellar.nexus.support${z("interstellar_elerium_prospector_title")}
                            ${z("space_support",[z("interstellar_nebula_name")])}
                            `,reqs:{nebula:3},cost:{Money:e=>Ps("elerium_prospector",e,825e3,1.28,"interstellar"),Steel:e=>Ps("elerium_prospector",e,18e3,1.28,"interstellar"),Polymer:e=>Ps("elerium_prospector",e,22e3,1.28,"interstellar"),Graphene:e=>Ps("elerium_prospector",e,82e3,1.28,"interstellar"),Stanene:e=>Ps("elerium_prospector",e,57e3,1.28,"interstellar")},effect(){let e=+$e("elerium_prospector").toFixed(3);return`
                            ${z("space_used_support",[z("interstellar_nebula_name")])}
                            ${z("space_belt_elerium_ship_effect2",[e])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("elerium_prospector","interstellar"),t.interstellar.nexus.supportt.tech.neutron?z("interstellar_neutron_desc2",[Ki[t.race.species].home]):z("interstellar_neutron_desc1")},neutron_mission:{id:"interstellar-neutron_mission",title:z("space_mission_title",[z("interstellar_neutron_name")]),desc:z("space_mission_desc",[z("interstellar_neutron_name")]),reqs:{nebula:1,high_tech:14},grant:["neutron",1],queue_complete:()=>t.tech.neutron>=1?0:1,cost:{Helium_3:()=>+Ht(6e4).toFixed(0),Deuterium:()=>+Ht(1e4).toFixed(0)},effect:z("interstellar_neutron_mission_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.neutron_miner={count:0,on:0},hs(z("interstellar_neutron_mission_result"),"info",!1,["progress"]),!0)}},neutron_miner:{id:"interstellar-neutron_miner",title:z("interstellar_neutron_miner_title"),desc:()=>`
                            ${z("interstellar_neutron_miner_desc")}
                            ${z("requires_power_combo",[t.resource.Helium_3.name])}
                            `,reqs:{neutron:1},cost:{Money:e=>Ps("neutron_miner",e,1e6,1.32,"interstellar"),Titanium:e=>Ps("neutron_miner",e,45e3,1.32,"interstellar"),Stanene:e=>Ps("neutron_miner",e,88e3,1.32,"interstellar"),Elerium:e=>Ps("neutron_miner",e,20,1.32,"interstellar"),Aerogel:e=>Ps("neutron_miner",e,50,1.32,"interstellar")},effect(){let e=+$e("neutron_miner").toFixed(3),t=br(500),a=+Ht(3).toFixed(2);return`
                            ${z("space_gas_moon_outpost_effect1",[e])}
                            ${z("plus_max_resource",[t,z("resource_Neutronium_name")])}
                            ${z("interstellar_alpha_starport_effect2",[a,$(this)[0].powered()])}
                            `},powered:()=>As(6),powerBalancer:()=>[{r:"Neutronium",k:"lpmod"}],action(){return!!ri($(this)[0])&&(Ft("neutron_miner","interstellar"),Yr($(this)[0]),!0)}},citadel:{id:"interstellar-citadel",title:z("interstellar_citadel_title"),desc:`
                            ${z("interstellar_citadel_desc")}
                            ${z("requires_power")}
                            `,reqs:{neutron:1,high_tech:15},cost:{Money:e=>Ps("citadel",e,5e6,1.25,"interstellar"),Knowledge:e=>Ps("citadel",e,15e5,1.15,"interstellar"),Graphene:e=>Ps("citadel",e,5e4,1.25,"interstellar"),Stanene:e=>Ps("citadel",e,1e5,1.25,"interstellar"),Elerium:e=>Ps("citadel",e,250,1.25,"interstellar"),Soul_Gem:e=>Ps("citadel",e,1,1.25,"interstellar")},wide:!0,effect(){let e=`
                            ${z("interstellar_citadel_stat",[+_.toFixed(1)])}
                            ${z("interstellar_citadel_effect",[5])}
                            `;if(t.tech.ai_core){let a=+(_/1.75).toFixed(1);t.race.flier||(e+=`
                            ${z("interstellar_citadel_effect2",[a])}
                            `),t.tech.ai_core>=2&&(e+=`
                            ${z("interstellar_citadel_effect3",[2])}
                            `),t.tech.ai_core>=3&&(e+=`
                            ${z("interstellar_citadel_effect4",[+(_/5).toFixed(1)])}
                            `)}return`${e}
                            ${z("interstellar_citadel_power",[$(this)[0].powered(),As(2.5)])}
                            `},powered:()=>s.citadel&&s.citadel>1?As(30+2.5*(s.citadel-1)):As(30),action(){return!!ri($(this)[0])&&(Ft("citadel","interstellar"),Yr($(this)[0]),!0)},flair:()=>z("interstellar_citadel_flair")},stellar_forge:{id:"interstellar-stellar_forge",title:z("interstellar_stellar_forge_title"),desc:`
                            ${z("interstellar_stellar_forge_title")}
                            ${z("requires_power")}
                            `,reqs:{star_forge:1},cost:{Money:e=>Ps("stellar_forge",e,12e5,1.25,"interstellar"),Iridium:e=>Ps("stellar_forge",e,25e4,1.25,"interstellar"),Bolognium:e=>Ps("stellar_forge",e,35e3,1.25,"interstellar"),Aerogel:e=>Ps("stellar_forge",e,75e3,1.25,"interstellar")},effect(){let e=`
                            ${z("city_foundry_effect1",[ta(2)])}
                            ${z("interstellar_stellar_forge_effect",[10])}
                            ${z("interstellar_stellar_forge_effect2",[5])}
                            `;return t.tech.star_forge&&t.tech.star_forge>=2&&(e+=`
                            ${z("interstellar_stellar_forge_effect3",[2])}
                            `),`${e}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(3),special:!0,action(){return!!ri($(this)[0])&&(Ft("stellar_forge","interstellar"),Yr($(this)[0])&&t.tech.star_forge>=2&&(t.city.smelter.cap+=2,t.city.smelter.Star+=2,t.city.smelter.StarCap+=2,t.city.smelter.Iron+=2),!0)},flair:()=>z("interstellar_stellar_forge_flair")}},int_blackhole:{info:{name:z("interstellar_blackhole_name"),desc(){let e=Ki[t.race.species].home;if(t.tech.blackhole>=5){let a=+t.interstellar.stellar_engine.mass.toFixed(10),r=+t.interstellar.stellar_engine.exotic.toFixed(10);if(t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12)),t.tech.whitehole){let i=Gs("bigbang"),s="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                            ${z("interstellar_blackhole_desc4",[e,a,r])}
                            ${z("interstellar_blackhole_desc5",[i.plasmid,i.phage,i.dark,s])}
                            `}return t.interstellar.stellar_engine.exotic>0?z("interstellar_blackhole_desc4",[e,a,r]):z("interstellar_blackhole_desc3",[e,a])}return t.tech.blackhole?z("interstellar_blackhole_desc2",[e]):z("interstellar_blackhole_desc1",[e])}},blackhole_mission:{id:"interstellar-blackhole_mission",title:z("space_mission_title",[z("interstellar_blackhole_name")]),desc:z("space_mission_desc",[z("interstellar_blackhole_name")]),reqs:{nebula:1},grant:["blackhole",1],queue_complete:()=>t.tech.blackhole>=1?0:1,cost:{Helium_3:()=>+Ht(75e3).toFixed(0),Deuterium:()=>+Ht(25e3).toFixed(0)},effect:z("interstellar_blackhole_mission_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.far_reach={count:0,on:0},hs(z("interstellar_blackhole_mission_result"),"info",!1,["progress"]),!0)}},far_reach:{id:"interstellar-far_reach",title:z("interstellar_far_reach"),desc:`
                            ${z("interstellar_far_reach_desc")}
                            ${z("requires_power")}
                            `,reqs:{blackhole:1},cost:{Money:e=>Ps("far_reach",e,1e6,1.32,"interstellar"),Knowledge:e=>Ps("far_reach",e,1e5,1.32,"interstellar"),Neutronium:e=>Ps("far_reach",e,2500,1.32,"interstellar"),Elerium:e=>Ps("far_reach",e,100,1.32,"interstellar"),Aerogel:e=>Ps("far_reach",e,1e3,1.32,"interstellar")},effect(){return`
                            ${z("interstellar_far_reach_effect",[1])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(5),action(){return!!ri($(this)[0])&&(Ft("far_reach","interstellar"),Yr($(this)[0]),1===t.tech.blackhole&&(t.tech.blackhole=2,Qr()),!0)},flair:z("interstellar_far_reach_flair")},stellar_engine:{id:"interstellar-stellar_engine",title:z("interstellar_stellar_engine"),desc:e=>!t.interstellar.hasOwnProperty("stellar_engine")||t.interstellar.stellar_engine.count<100||e?`
                            ${z("interstellar_stellar_engine")}
                            ${z("requires_segmemts",[100])}
                            `:`
                            ${z("interstellar_stellar_engine")}
                            `,reqs:{blackhole:3},queue_size:10,queue_complete:()=>100-t.interstellar.stellar_engine.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?5e5:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?450:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?17500:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?225:0,Graphene:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?45e3:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?250:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0)<100?75:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("stellar_engine")?t.interstellar.stellar_engine.count:0);if(a<100){let e=100-a;return`
                            ${z("interstellar_stellar_engine_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}{let e=t.tech.gravity&&t.tech.gravity>=2?13.5:7.5,a=t.interstellar.stellar_engine?t.interstellar.stellar_engine.mass:8;t.tech.roid_eject&&(a+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12));let r=Fs(+(20+(a-8)*e+(t.interstellar.stellar_engine?t.interstellar.stellar_engine.exotic:0)*e*10).toFixed(2));if(t.tech.blackhole>=5){let e=+t.interstellar.stellar_engine.exotic.toFixed(10),i=t.interstellar.stellar_engine.exotic>0?z("interstellar_stellar_engine_effect3",[a,e]):z("interstellar_stellar_engine_effect2",[a]);return`
                            ${z("interstellar_stellar_engine_complete",[r])}
                            ${i}
                            `}return z("interstellar_stellar_engine_complete",[r])}},action(){return!!(ri($(this)[0])&&t.interstellar.stellar_engine.count<100)&&(Ft("stellar_engine","interstellar"),t.interstellar.stellar_engine.count>=100&&3===t.tech.blackhole&&(t.tech.blackhole=4,Qr()),!0)}},mass_ejector:{id:"interstellar-mass_ejector",title:z("interstellar_mass_ejector"),desc:`
                            ${z("interstellar_mass_ejector")}
                            ${z("requires_power")}
                            `,reqs:{blackhole:5},cost:{Money:e=>Ps("mass_ejector",e,75e4,1.25,"interstellar"),Adamantite:e=>Ps("mass_ejector",e,125e3,1.25,"interstellar"),Infernite:e=>Ps("mass_ejector",e,275,1.25,"interstellar"),Elerium:e=>Ps("mass_ejector",e,100,1.25,"interstellar"),Mythril:e=>Ps("mass_ejector",e,1e4,1.25,"interstellar")},effect(){return`
                            ${z("interstellar_mass_ejector_effect")}, ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(3),special:!0,sAction(){t.settings.civTabs=4,t.settings.marketTabs=2,t.settings.tabLoad||(kt("mTabResource"),_s("interstellar-mass_ejector"))},action(){return!!ri($(this)[0])&&(0===t.interstellar.mass_ejector.count&&hs(z("interstellar_mass_ejector_msg"),"info",!1,["progress"]),t.settings.showEjector=!0,Ft("mass_ejector","interstellar"),Yr($(this)[0]),Ss($("#resources")),Da(),!0)},flair:()=>z("interstellar_mass_ejector_flair")},jump_ship:{id:"interstellar-jump_ship",title:z("interstellar_jump_ship"),desc:z("interstellar_jump_ship_desc"),reqs:{stargate:1},grant:["stargate",2],queue_complete:()=>t.tech.stargate>=2?0:1,cost:{Money:()=>2e7,Copper:()=>24e5,Aluminium:()=>4e6,Titanium:()=>125e4,Adamantite:()=>75e4,Stanene:()=>9e5,Aerogel:()=>1e5},effect:z("interstellar_jump_ship_effect"),action(){return!!ri($(this)[0])}},wormhole_mission:{id:"interstellar-wormhole_mission",title:z("space_mission_title",[z("interstellar_wormhole_name")]),desc:z("space_mission_desc",[z("interstellar_wormhole_name")]),reqs:{stargate:2},grant:["stargate",3],queue_complete:()=>t.tech.stargate>=3?0:1,cost:{Helium_3:()=>+Ht(15e4).toFixed(0),Deuterium:()=>+Ht(75e3).toFixed(0)},effect:z("interstellar_wormhole_mission_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.stargate={count:0},t.galaxy.gateway_station={count:0,on:0},hs(z("interstellar_wormhole_mission_result"),"info",!1,["progress"]),!0)}},stargate:{id:"interstellar-stargate",title:z("interstellar_stargate"),desc:e=>!t.interstellar.hasOwnProperty("stargate")||t.interstellar.stargate.count<200||e?`
                            ${z("interstellar_stargate")}
                            ${z("requires_segmemts",[200])}
                            `+(t.interstellar.hasOwnProperty("stargate")&&t.interstellar.stargate.count>=200?`
                            ${z("requires_power")}
                            `:""):`
                            ${z("interstellar_stargate")}
                            `,reqs:{stargate:3},condition:()=>!(t.interstellar.stargate.count>=200),queue_size:10,queue_complete:()=>200-t.interstellar.stargate.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?1e6:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?4800:0,Infernite:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?666:0,Elerium:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?75:0,Nano_Tube:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?12e3:0,Stanene:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?6e4:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0)<200?3200:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("stargate")?t.interstellar.stargate.count:0);if(a<200){let e=200-a;return`
                            ${z("interstellar_stargate_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}return xt.int_blackhole.s_gate.effect()},action(){return!!(ri($(this)[0])&&t.interstellar.stargate.count<200)&&(Ft("stargate","interstellar"),t.interstellar.stargate.count>=200&&(t.tech.stargate=4,t.interstellar.s_gate={count:1,on:0},t.city.power>=xt.int_blackhole.s_gate.powered()&&t.interstellar.s_gate.on++,Kt(),_s()),!0)}},s_gate:{id:"interstellar-s_gate",title:z("interstellar_stargate"),desc:()=>`
                            ${z("interstellar_stargate")}
                            ${z("requires_power")}
                            `,reqs:{stargate:4},condition:()=>t.interstellar.stargate.count>=200,wiki:!1,queue_complete:()=>0,cost:{},powered:()=>As(250),effect(){return`
                            ${z("interstellar_s_gate_effect")}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action:()=>!1}},int_sirius:{info:{name:()=>t.tech.ascension>=3?z("interstellar_sirius_b_name"):z("interstellar_sirius_name"),desc:()=>t.tech.ascension>=3?z("interstellar_sirius_b_desc"):z("interstellar_sirius_desc",[Ki[t.race.species].home])},sirius_mission:{id:"interstellar-sirius_mission",title:z("space_mission_title",[z("interstellar_sirius_name")]),desc:z("space_mission_desc",[z("interstellar_sirius_name")]),reqs:{ascension:2},grant:["ascension",3],queue_complete:()=>t.tech.ascension>=3?0:1,cost:{Helium_3:()=>+Ht(48e4).toFixed(0),Deuterium:()=>+Ht(225e3).toFixed(0)},effect:()=>z("interstellar_sirius_mission_effect",[nn("name"),Ki[t.race.species].home]),action(){return!!ri($(this)[0])}},sirius_b:{id:"interstellar-sirius_b",title:z("interstellar_sirius_b"),desc:z("interstellar_sirius_b"),reqs:{ascension:3},grant:["ascension",4],queue_complete:()=>t.tech.ascension>=4?0:1,cost:{Knowledge:()=>2e7},effect:()=>z("interstellar_sirius_b_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.space_elevator={count:0},!0)}},space_elevator:{id:"interstellar-space_elevator",title:z("interstellar_space_elevator"),desc:e=>!t.interstellar.hasOwnProperty("space_elevator")||t.interstellar.space_elevator.count<100||e?`
                            ${z("interstellar_space_elevator")}
                            ${z("requires_segmemts",[100])}
                            `:`
                            ${z("interstellar_space_elevator")}
                            `,reqs:{ascension:4},condition:()=>!(t.interstellar.space_elevator.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.space_elevator.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?2e7:0,Nano_Tube:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?5e5:0,Bolognium:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?1e5:0,Mythril:e=>(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0)<100?125e3:0},effect(e){let a=`
                            ${z("interstellar_space_elevator_effect")}
                            `,r=(e||0)+(t.interstellar.hasOwnProperty("space_elevator")?t.interstellar.space_elevator.count:0);return r<100&&(a+=`
                            ${z("space_dwarf_collider_effect2",[100-r])}
                            `),a},action(){return!!(ri($(this)[0])&&t.interstellar.space_elevator.count<100)&&(Ft("space_elevator","interstellar"),t.interstellar.space_elevator.count>=100&&(t.tech.ascension=5,t.interstellar.gravity_dome={count:0},Kt(),_s()),!0)}},gravity_dome:{id:"interstellar-gravity_dome",title:z("interstellar_gravity_dome"),desc:e=>!t.interstellar.hasOwnProperty("gravity_dome")||t.interstellar.gravity_dome.count<100||e?`
                            ${z("interstellar_gravity_dome")}
                            ${z("requires_segmemts",[100])}
                            `:`
                            ${z("interstellar_gravity_dome")}
                            `,reqs:{ascension:5},condition:()=>!(t.interstellar.gravity_dome.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.gravity_dome.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?35e6:0,Cement:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?125e4:0,Adamantite:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?65e4:0,Aerogel:e=>(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0)<100?18e4:0},effect(e){let a=`
                            ${z("interstellar_gravity_dome_effect",[Ki[t.race.species].home])}
                            `,r=(e||0)+(t.interstellar.hasOwnProperty("gravity_dome")?t.interstellar.gravity_dome.count:0);return r<100&&(a+=`
                            ${z("space_dwarf_collider_effect2",[100-r])}
                            `),a},action(){return!!(ri($(this)[0])&&t.interstellar.gravity_dome.count<100)&&(Ft("gravity_dome","interstellar"),t.interstellar.gravity_dome.count>=100&&(t.tech.ascension=6,t.interstellar.ascension_machine={count:0},t.interstellar.thermal_collector={count:0},Kt(),_s()),!0)}},ascension_machine:{id:"interstellar-ascension_machine",title:z("interstellar_ascension_machine"),desc:e=>!t.interstellar.hasOwnProperty("ascension_machine")||t.interstellar.ascension_machine.count<100||e?`
                            ${z("interstellar_ascension_machine")}
                            ${z("requires_segmemts",[100])}
                            `+(t.interstellar.hasOwnProperty("ascension_machine")&&t.interstellar.ascension_machine.count>=100?`
                            ${z("requires_power")}
                            `:""):`
                            ${z("interstellar_ascension_machine")}
                            `,reqs:{ascension:6},condition:()=>!(t.interstellar.ascension_machine.count>=100),queue_size:5,queue_complete:()=>100-t.interstellar.ascension_machine.count,cost:{Money:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e6:0,Alloy:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e4:0,Neutronium:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?1e3:0,Orichalcum:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?25e4:0,Nanoweave:e=>(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.interstellar.hasOwnProperty("ascension_machine")?t.interstellar.ascension_machine.count:0);if(a<100){let e=100-a;return`
                            ${z("interstellar_ascension_machine_effect",[nn("name")])}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}return xt.int_sirius.ascension_trigger.effect()},action(){return!!(ri($(this)[0])&&t.interstellar.ascension_machine.count<100)&&(Ft("ascension_machine","interstellar"),t.interstellar.ascension_machine.count>=100&&(t.tech.ascension=7,t.interstellar.ascension_trigger={count:1,on:0},Kt(),_s()),!0)}},ascension_trigger:{id:"interstellar-ascension_trigger",title:z("interstellar_ascension_machine"),desc:()=>`
                            ${z("interstellar_ascension_machine")}
                            ${z("requires_power")}
                            `,wiki:!1,reqs:{ascension:7},condition:()=>t.interstellar.ascension_machine.count>=100,queue_complete:()=>0,cost:{},powered(){let e=100;if(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2){e+=t.stats.achieve.technophobe.l>=4?25:10;for(let a=1;a=5&&(e+=5)}let a=Math.round(As(1e4)-e*(t.interstellar.hasOwnProperty("thermal_collector")?t.interstellar.thermal_collector.count:0));return a<0&&(a=0),a},postPower(e){e?setTimeout((function(){t.tech.ascension=s.ascension_trigger?8:7,Kt()}),250):(t.tech.ascension=7,Kt())},effect(){let e=qt(),t=$(this)[0].powered(),a=t>0?`
                            ${z("minus_power",[t])}
                            `:"";return`
                            ${z("interstellar_ascension_trigger_effect")}
                            ${e}${a}`},action:()=>!1},ascend:{id:"interstellar-ascend",title:z("interstellar_ascend"),desc:z("interstellar_ascend"),reqs:{ascension:8},queue_complete:()=>0,no_multi:!0,cost:{},effect(){let e=qt();return`
                            ${z("interstellar_ascend_effect")}
                            ${e}`},action(){return!!ri($(this)[0])&&(Qt(),!0)}},thermal_collector:{id:"interstellar-thermal_collector",title:z("interstellar_thermal_collector"),desc:z("interstellar_thermal_collector"),reqs:{ascension:6},cost:{Money:e=>Ps("thermal_collector",e,5e6,1.08,"interstellar"),Infernite:e=>Ps("thermal_collector",e,25e3,1.08,"interstellar"),Stanene:e=>Ps("thermal_collector",e,1e6,1.08,"interstellar"),Vitreloy:e=>Ps("thermal_collector",e,1e5,1.08,"interstellar")},effect(){let e=100;if(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2){e+=t.stats.achieve.technophobe.l>=4?25:10;for(let a=1;a=5&&(e+=5)}return z("interstellar_thermal_collector_effect",[e])},action(){return!!ri($(this)[0])&&(Ft("thermal_collector","interstellar"),!0)}}}};function qt(){let e=Gs("ascend"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                            ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                            ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                            ${z("interstellar_ascension_trigger_effect2",[e.harmony,z("resource_Harmony_name")])}
                            ${z("interstellar_ascension_trigger_effect3")}
                            `}function Pt(){let e=Gs("terraform"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                            ${z("interstellar_ascension_trigger_effect2",[e.plasmid,a])}
                            ${z("interstellar_ascension_trigger_effect2",[e.phage,z("resource_Phage_name")])}
                            ${z("interstellar_ascension_trigger_effect2",[e.harmony,z("resource_Harmony_name")])}
                            ${z("space_terraformer_effect3")}
                            `}const jt={gxy_gateway:{info:{name:z("galaxy_gateway"),desc:()=>z("galaxy_gateway_desc"),control:()=>({name:nn("name"),color:"success"}),support:"starbase"},gateway_mission:{id:"galaxy-gateway_mission",title:z("galaxy_gateway_mission"),desc:z("galaxy_gateway_mission"),reqs:{gateway:1},grant:["gateway",2],queue_complete:()=>t.tech.gateway>=2?0:1,cost:{Helium_3:()=>+Ht(212e3).toFixed(0),Deuterium:()=>+Ht(11e4).toFixed(0)},effect:z("galaxy_gateway_mission_effect"),action(){return!!ri($(this)[0])&&(St(),t.galaxy.defense={gxy_stargate:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_gateway:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_gorddon:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_alien1:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_alien2:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0},gxy_chthonian:{scout_ship:0,corvette_ship:0,frigate_ship:0,cruiser_ship:0,dreadnought:0}},!0)}},starbase:{id:"galaxy-starbase",title:z("galaxy_starbase"),desc:()=>`
                            ${z("galaxy_starbase")}
                            ${z("requires_power_space",[t.resource.Food.name])}
                            `,reqs:{gateway:2},cost:{Money:e=>Ps("starbase",e,42e5,1.25,"galaxy"),Elerium:e=>Ps("starbase",e,1e3,1.25,"galaxy"),Mythril:e=>Ps("starbase",e,9e4,1.25,"galaxy"),Graphene:e=>Ps("starbase",e,32e4,1.25,"galaxy"),Horseshoe:()=>t.race.hooved?5:0},effect(){let e=+Ht(25).toFixed(2),a=t.tech.marines>=2?ta(8):ta(5);return`
                            ${z("galaxy_defense_platform_effect",[25])}
                            ${z("galaxy_gateway_support",[$(this)[0].support()])}
                            ${z("plus_max_soldiers",[a])}
                            ${z("interstellar_alpha_starport_effect2",[e,$(this)[0].powered()])}
                            ${z("interstellar_alpha_starport_effect3",[250,t.resource.Food.name])}
                            `},support:()=>2,powered:()=>As(s.s_gate?12:0),powerBalancer:()=>[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("starbase","galaxy"),Yr($(this)[0]),2===t.tech.gateway&&(t.galaxy.bolognium_ship={count:0,on:0,crew:0},t.tech.gateway=3),!0)}},ship_dock:{id:"galaxy-ship_dock",title:z("galaxy_ship_dock"),desc:`
                            ${z("galaxy_ship_dock")}
                            ${z("requires_power")}
                            `,reqs:{gateway:4},cost:{Money:e=>Ps("ship_dock",e,36e5,1.25,"galaxy"),Steel:e=>Ps("ship_dock",e,88e4,1.25,"galaxy"),Aluminium:e=>Ps("ship_dock",e,12e5,1.25,"galaxy"),Bolognium:e=>Ps("ship_dock",e,75e3,1.25,"galaxy")},effect(){return`
                            ${z("galaxy_ship_dock_effect",[.25])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},support:()=>s.starbase?.25*s.starbase:0,powered:()=>As(s.s_gate?4:0),powerBalancer:()=>[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],action(){return!!ri($(this)[0])&&(Ft("ship_dock","galaxy"),Yr($(this)[0]),!0)}},bolognium_ship:{id:"galaxy-bolognium_ship",title:z("galaxy_bolognium_ship"),desc:()=>`
                            ${z("galaxy_bolognium_ship_desc")}
                            ${z("galaxy_starbase_support",[z("resource_Helium_3_name")])}
                            `,reqs:{gateway:3},cost:{Money:e=>Ps("bolognium_ship",e,14e5,1.22,"galaxy"),Iron:e=>Ps("bolognium_ship",e,56e4,1.22,"galaxy"),Infernite:e=>Ps("bolognium_ship",e,1800,1.22,"galaxy"),Nano_Tube:e=>Ps("bolognium_ship",e,475e3,1.22,"galaxy")},effect(){let e=+$e("bolognium_ship").toFixed(3),a=+Ht($(this)[0].ship.helium).toFixed(2);return`
                            ${z("gain",[e,z("resource_Bolognium_name")])}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                            ${z("spend",[a,t.resource.Helium_3.name])}
                            `},support:()=>-1,ship:{civ:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2,mil:()=>0,helium:5},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("bolognium_ship","galaxy"),t.resource.Bolognium.display=!0,t.civic.crew.display=!0,t.galaxy.starbase.support`
                            ${z("galaxy_scout_ship")}
                            ${z("galaxy_starbase_support",[z("resource_Helium_3_name")])}
                            `,reqs:{andromeda:1},cost:{Money:e=>Ps("scout_ship",e,16e5,1.25,"galaxy"),Titanium:e=>Ps("scout_ship",e,325e3,1.25,"galaxy"),Graphene:e=>Ps("scout_ship",e,118e3,1.25,"galaxy"),Soul_Gem:e=>Ps("scout_ship",e,1,1.02,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2),a=t.tech.science>=17?`
                            ${z("galaxy_scout_ship_effect2",[25])}
                            `:"";return`
                            ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                            ${z("galaxy_scout_ship_effect")}
                            ${a}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                            ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                            ${z("spend",[e,t.resource.Helium_3.name])}
                            `},support:()=>-1,ship:{civ:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,mil:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,helium:6,rating:()=>t.race.banana?7:10},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("scout_ship","galaxy"),t.galaxy.defense.gxy_gateway.scout_ship++,t.galaxy.starbase.support`
                            ${z("galaxy_corvette_ship")}
                            ${z("galaxy_starbase_support",[z("resource_Helium_3_name")])}
                            `,reqs:{andromeda:2},cost:{Money:e=>Ps("corvette_ship",e,45e5,1.25,"galaxy"),Steel:e=>Ps("corvette_ship",e,175e4,1.25,"galaxy"),Infernite:e=>Ps("corvette_ship",e,16e3,1.25,"galaxy"),Bolognium:e=>Ps("corvette_ship",e,35e3,1.25,"galaxy"),Soul_Gem:e=>Ps("corvette_ship",e,1,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return`
                            ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                            ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                            ${z("spend",[e,t.resource.Helium_3.name])}
                            `},support:()=>-1,ship:{civ:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2,mil:()=>t.race.high_pop?3*Ei.high_pop.vars()[0]:3,helium:10,rating:()=>t.race.banana?21:30},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("corvette_ship","galaxy"),t.galaxy.defense.gxy_gateway.corvette_ship++,t.galaxy.starbase.support`
                            ${z("galaxy_frigate_ship")}
                            ${z("galaxy_starbase_support",[z("resource_Helium_3_name")])}
                            `,reqs:{andromeda:3},cost:{Money:e=>Ps("frigate_ship",e,18e6,1.25,"galaxy"),Elerium:e=>Ps("frigate_ship",e,1250,1.25,"galaxy"),Mythril:e=>Ps("frigate_ship",e,35e4,1.25,"galaxy"),Sheet_Metal:e=>Ps("frigate_ship",e,8e5,1.25,"galaxy"),Soul_Gem:e=>Ps("frigate_ship",e,2,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return`
                            ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                            ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                            ${z("spend",[e,t.resource.Helium_3.name])}
                            `},support:()=>-2,ship:{civ:()=>t.race.high_pop?3*Ei.high_pop.vars()[0]:3,mil:()=>t.race.high_pop?5*Ei.high_pop.vars()[0]:5,helium:25,rating:()=>t.race.banana?56:80},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("frigate_ship","galaxy"),t.galaxy.defense.gxy_gateway.frigate_ship++,t.galaxy.starbase.support+1`
                            ${z("galaxy_cruiser_ship")}
                            ${z("galaxy_starbase_support",[z("resource_Deuterium_name")])}
                            `,reqs:{andromeda:4},cost:{Money:e=>Ps("cruiser_ship",e,75e6,1.25,"galaxy"),Copper:e=>Ps("cruiser_ship",e,6e6,1.25,"galaxy"),Adamantite:e=>Ps("cruiser_ship",e,1e6,1.25,"galaxy"),Vitreloy:e=>Ps("cruiser_ship",e,75e4,1.25,"galaxy"),Elerium:e=>Ps("cruiser_ship",e,1800,1.25,"galaxy"),Soul_Gem:e=>Ps("cruiser_ship",e,5,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.deuterium).toFixed(2);return`
                            ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                            ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                            ${z("spend",[e,t.resource.Deuterium.name])}
                            `},support:()=>-3,ship:{civ:()=>t.race.high_pop?6*Ei.high_pop.vars()[0]:6,mil:()=>t.race.high_pop?10*Ei.high_pop.vars()[0]:10,deuterium:25,rating:()=>t.race.banana?175:250},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("cruiser_ship","galaxy"),t.galaxy.defense.gxy_gateway.cruiser_ship++,t.galaxy.starbase.support+2`
                            ${z("galaxy_dreadnought")}
                            ${z("galaxy_starbase_support",[z("resource_Deuterium_name")])}
                            `,reqs:{andromeda:5},cost:{Money:e=>Ps("dreadnought",e,225e6,1.25,"galaxy"),Neutronium:e=>Ps("dreadnought",e,25e4,1.25,"galaxy"),Bolognium:e=>Ps("dreadnought",e,15e5,1.25,"galaxy"),Vitreloy:e=>Ps("dreadnought",e,1e6,1.25,"galaxy"),Infernite:e=>Ps("dreadnought",e,4e5,1.25,"galaxy"),Aerogel:e=>Ps("dreadnought",e,8e5,1.25,"galaxy"),Soul_Gem:e=>Ps("dreadnought",e,25,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.deuterium).toFixed(2);return`
                            ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                            ${z("galaxy_gateway_used_support",[-$(this)[0].support()])}
                            ${z("spend",[e,t.resource.Deuterium.name])}
                            `},support:()=>-5,ship:{civ:()=>t.race.high_pop?10*Ei.high_pop.vars()[0]:10,mil:()=>t.race.high_pop?20*Ei.high_pop.vars()[0]:20,deuterium:80,rating:()=>t.race.banana?1260:1800},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("dreadnought","galaxy"),t.galaxy.defense.gxy_gateway.dreadnought++,t.galaxy.starbase.support+2t.tech.piracy?z("galaxy_stargate_desc_alt"):z("galaxy_stargate_desc"),control:()=>({name:nn("name"),color:"success"})},gateway_station:{id:"galaxy-gateway_station",title:z("galaxy_gateway_station"),desc:()=>`
                            ${z("galaxy_gateway_station_desc")}
                            ${z("requires_power")}
                            `,reqs:{stargate:4},cost:{Money:e=>Ps("gateway_station",e,5e6,1.25,"galaxy"),Aluminium:e=>Ps("gateway_station",e,52e4,1.25,"galaxy"),Polymer:e=>Ps("gateway_station",e,35e4,1.25,"galaxy"),Neutronium:e=>Ps("gateway_station",e,17500,1.25,"galaxy")},effect(){let e=br(2e3),a=br(4500),r=br(50),i="";return t.tech.gateway&&t.tech.gateway>=2&&(i=`
                            ${z("galaxy_gateway_support",[$(this)[0].support()])}
                            `),`${i}
                            ${z("plus_max_resource",[e,z("resource_Helium_3_name")])}
                            ${z("plus_max_resource",[a,z("resource_Deuterium_name")])}
                            ${z("plus_max_resource",[r,z("resource_Elerium_name")])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},support:()=>.5,powered:()=>As(s.s_gate?4:0),powerBalancer:()=>!t.galaxy.hasOwnProperty("starbase")&&[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],refresh:!0,action(){return!!ri($(this)[0])&&(Ft("gateway_station","galaxy"),t.resource.Helium_3.max+=br(2e3),t.resource.Deuterium.max+=br(4500),4===t.tech.stargate&&(t.galaxy.telemetry_beacon={count:0,on:0},t.tech.stargate=5),Yr($(this)[0]),!0)}},telemetry_beacon:{id:"galaxy-telemetry_beacon",title:z("galaxy_telemetry_beacon"),desc:()=>`
                            ${z("galaxy_telemetry_beacon")}
                            ${z("requires_power")}
                            `,reqs:{stargate:5},cost:{Money:e=>Ps("telemetry_beacon",e,225e4,1.25,"galaxy"),Copper:e=>Ps("telemetry_beacon",e,685e3,1.25,"galaxy"),Alloy:e=>Ps("telemetry_beacon",e,425e3,1.25,"galaxy"),Iridium:e=>Ps("telemetry_beacon",e,177e3,1.25,"galaxy")},effect(){let e=t.tech.telemetry?1200:800;t.tech.science>=17&&(e+=25*o.scout_ship);let a=s.telemetry_beacon?e*s.telemetry_beacon:0,r="";return t.tech.gateway&&t.tech.gateway>=2&&(r=`
                            ${z("galaxy_gateway_support",[$(this)[0].support()])}
                            `),`${r}
                            ${z("galaxy_telemetry_beacon_effect1",[e])}
                            ${z("galaxy_telemetry_beacon_effect2",[a])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},support:()=>t.tech.telemetry?.75:.5,powered:()=>As(s.s_gate?4:0),powerBalancer:()=>!t.galaxy.hasOwnProperty("starbase")&&[{s:t.galaxy.starbase.s_max-t.galaxy.starbase.support}],postPower(e){let a=e?s.telemetry_beacon+y():s.telemetry_beacon-y();a>t.galaxy.telemetry_beacon.count?a=t.galaxy.telemetry_beacon.count:a<0&&(a=0),s.telemetry_beacon=a,ai($(this)[0],"galaxy","telemetry_beacon")},action(){return!!ri($(this)[0])&&(Ft("telemetry_beacon","galaxy"),Yr($(this)[0])&&(t.resource.Knowledge.max+=1750),t.tech.gateway||(t.galaxy.starbase={count:0,on:0,support:0,s_max:0},t.settings.space.gateway=!0,t.tech.gateway=1,Dt()),!0)}},gateway_depot:{id:"galaxy-gateway_depot",title:z("galaxy_gateway_depot"),desc:`
                            ${z("galaxy_gateway_depot")}
                            `,reqs:{gateway:5},cost:{Money:e=>Ps("gateway_depot",e,4e6,1.25,"galaxy"),Neutronium:e=>Ps("gateway_depot",e,8e4,1.25,"galaxy"),Stanene:e=>Ps("gateway_depot",e,5e5,1.25,"galaxy"),Vitreloy:e=>Ps("gateway_depot",e,2500,1.25,"galaxy")},wide:!0,effect(){let e=t.tech.world_control?150:100,a=br(200),r=Ct(),i=x(+br(3e3*r).toFixed(0),1),s=x(+br(25e4*r).toFixed(0),1),n=x(+br(9001*r).toFixed(0),1),c=x(+br(6660*r).toFixed(0),1),o='
                            ';return o+=`${z("plus_max_crates",[e])}${z("plus_max_containers",[e])}`,o+=`${z("plus_max_resource",[i,t.resource.Uranium.name])}`,o+=`${z("plus_max_resource",[s,t.resource.Nano_Tube.name])}`,o+=`${z("plus_max_resource",[n,t.resource.Neutronium.name])}`,o+=`${z("plus_max_resource",[c,t.resource.Infernite.name])}`,o+="
                            ",`${o}
                            ${z("galaxy_gateway_depot_effect",[a,z("resource_Elerium_name")])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(s.s_gate?10:0),action(){if(ri($(this)[0])){Ft("gateway_depot","galaxy");let e=Ct();return t.resource.Uranium.max+=br(3e3*e),t.resource.Nano_Tube.max+=br(25e4*e),t.resource.Neutronium.max+=br(9001*e),t.resource.Infernite.max+=br(6660*e),Yr($(this)[0]),!0}return!1}},defense_platform:{id:"galaxy-defense_platform",title:z("galaxy_defense_platform"),desc:()=>`
                            ${z("galaxy_defense_platform")}
                            ${z("requires_power")}
                            `,reqs:{stargate:6},cost:{Money:e=>Ps("defense_platform",e,75e4,1.25,"galaxy"),Adamantite:e=>Ps("defense_platform",e,425e3,1.25,"galaxy"),Elerium:e=>Ps("defense_platform",e,800,1.25,"galaxy"),Vitreloy:e=>Ps("defense_platform",e,1250,1.25,"galaxy"),Wrought_Iron:e=>Ps("defense_platform",e,75e3,1.25,"galaxy")},effect(){return`
                            ${z("galaxy_defense_platform_effect",[20])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(s.s_gate?5:0),postPower(e){Cs({el:"#gxy_stargate"},"update")},action(){return!!ri($(this)[0])&&(Ft("defense_platform","galaxy"),Yr($(this)[0]),!0)},post(){Cs({el:"#gxy_stargate"},"update")}}},gxy_gorddon:{info:{name:z("galaxy_gorddon"),desc:()=>z("galaxy_gorddon_desc"),control:()=>({name:Ki[t.galaxy.alien1.id].name,color:"advanced"})},gorddon_mission:{id:"galaxy-gorddon_mission",title:z("galaxy_gorddon_mission"),desc:z("galaxy_gorddon_mission_desc"),reqs:{xeno:2},grant:["xeno",3],queue_complete:()=>t.tech.xeno>=3?0:1,cost:{Structs:()=>({galaxy:{scout_ship:{s:"gxy_gateway",count:2,on:2},corvette_ship:{s:"gxy_gateway",count:1,on:1}}}),Helium_3:()=>+Ht(23e4).toFixed(0),Deuterium:()=>+Ht(125e3).toFixed(0)},effect:z("galaxy_gorddon_mission_effect"),action(){if(ri($(this)[0])){St(),t.galaxy.defense.gxy_gateway.scout_ship-=2,t.galaxy.defense.gxy_gorddon.scout_ship+=2,t.galaxy.defense.gxy_gateway.corvette_ship--,t.galaxy.defense.gxy_gorddon.corvette_ship++;let e=Ki[t.galaxy.alien1.id].name,a=Ki[t.galaxy.alien1.id].entity,r=Ki[t.galaxy.alien2.id].name;return hs(z("galaxy_gorddon_mission_result",[a,e,Ki[t.galaxy.alien2.id].entity,r]),"info",!1,["progress"]),!0}return!1}},embassy:{id:"galaxy-embassy",title:z("galaxy_embassy"),desc:()=>`
                            ${z("galaxy_embassy")}
                            ${z("requires_power_combo",[t.resource.Food.name])}
                            `,reqs:{xeno:4},queue_complete:()=>1-t.galaxy.embassy.count,cost:{Money:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?3e7:0,Lumber:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?38e6:0,Stone:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?32e6:0,Furs:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?18e6:0,Wrought_Iron:e=>(e||0)+(t.galaxy.hasOwnProperty("embassy")?t.galaxy.embassy.count:0)<1?6e6:0},effect(){let e="";return t.tech.xeno>=11&&(e=`
                            ${z("plus_max_citizens",[$(this)[0].citizens()])}
                            `),`
                            ${z("galaxy_embassy_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
                            ${e}
                            ${z("interstellar_alpha_starport_effect3",[7500,t.resource.Food.name])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(s.s_gate?25:0),refresh:!0,action(){return!!(t.galaxy.embassy.count<1&&ri($(this)[0]))&&(Ft("embassy","galaxy"),Yr($(this)[0]),4===t.tech.xeno&&(t.tech.xeno=5,t.galaxy.freighter={count:0,on:0,crew:0},t.galaxy.trade={max:0,cur:0,f0:0,f1:0,f2:0,f3:0,f4:0,f5:0,f6:0,f7:0,f8:0},Ss($("#resources")),Da(),hs(z("galaxy_embassy_complete",[Ki[t.galaxy.alien1.id].name,Ki[t.galaxy.alien2.id].name]),"info",!1,["progress"])),!0)},citizens(){let e=20;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},dormitory:{id:"galaxy-dormitory",title:z("galaxy_dormitory"),desc:()=>`
                            ${z("galaxy_dormitory")}
                            ${z("requires_power")}
                            `,reqs:{xeno:6},cost:{Money:e=>Ps("dormitory",e,1e7,1.25,"galaxy"),Furs:e=>Ps("dormitory",e,7e5,1.25,"galaxy"),Cement:e=>Ps("dormitory",e,12e5,1.25,"galaxy"),Plywood:e=>Ps("dormitory",e,85e3,1.25,"galaxy"),Horseshoe:()=>t.race.hooved?3:0},effect(){return`
                            ${z("requires_res",[z("galaxy_embassy")])}
                            ${z("plus_max_citizens",[$(this)[0].citizens()])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(3),action(){return!!ri($(this)[0])&&(Ft("dormitory","galaxy"),Yr($(this)[0]),!0)},citizens(){let e=3;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},symposium:{id:"galaxy-symposium",title:z("galaxy_symposium"),desc:()=>`
                            ${z("galaxy_symposium")}
                            ${z("requires_power")}
                            `,reqs:{xeno:6},cost:{Money:e=>Ps("symposium",e,8e6,1.25,"galaxy"),Food:e=>t.race.ravenous?0:Ps("symposium",e,t.race.artifical?45e3:125e3,1.25,"galaxy"),Lumber:e=>Ps("symposium",e,46e4,1.25,"galaxy"),Brick:e=>Ps("symposium",e,261600,1.25,"galaxy")},effect(){let e="";return t.tech.xeno>=7&&(e=`
                            ${z("galaxy_symposium_effect3",[+ke(300).toFixed(2)])}
                            `),`
                            ${z("galaxy_symposium_effect",[1750])}
                            ${z("galaxy_symposium_effect2",[650])}
                            ${e}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(4),action(){return!!ri($(this)[0])&&(Ft("symposium","galaxy"),Yr($(this)[0]),!0)}},freighter:{id:"galaxy-freighter",title:z("galaxy_freighter"),desc:()=>`
                            ${z("galaxy_freighter")}
                            ${z("galaxy_crew_fuel",[z("resource_Helium_3_name")])}
                            `,reqs:{xeno:5},cost:{Money:e=>Ps("freighter",e,6e6,1.2,"galaxy"),Uranium:e=>Ps("freighter",e,1e4,1.2,"galaxy"),Adamantite:e=>Ps("freighter",e,46e4,1.2,"galaxy"),Stanene:e=>Ps("freighter",e,261600,1.2,"galaxy"),Bolognium:e=>Ps("freighter",e,66e3,1.2,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2),a="";return t.tech.banking>=13&&(a=`
                            ${z("interstellar_exchange_boost",[3])}
                            `),`
                            ${z("galaxy_freighter_effect",[2,Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
                            ${a}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("spend",[e,t.resource.Helium_3.name])}
                            `},ship:{civ:()=>t.race.high_pop?3*Ei.high_pop.vars()[0]:3,mil:()=>0,helium:12},special:!0,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("freighter","galaxy"),t.galaxy.freighter.on++,t.resource.Vitreloy.display=!0,!0)}}},gxy_alien1:{info:{name:()=>z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),desc:()=>z("galaxy_alien1_desc",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home,Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),control:()=>({name:Ki[t.galaxy.alien1.id].name,color:"advanced"})},consulate:{id:"galaxy-consulate",title:z("galaxy_consulate"),desc:()=>z("galaxy_consulate_desc",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),reqs:{xeno:8},queue_complete:()=>1-t.galaxy.consulate.count,cost:{Money:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?9e7:0,Stone:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?75e6:0,Furs:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?3e7:0,Iron:e=>(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?45e6:0,Horseshoe:e=>t.race.hooved&&(e||0)+(t.galaxy.hasOwnProperty("consulate")?t.galaxy.consulate.count:0)<1?10:0},effect(){return z("plus_max_citizens",[$(this)[0].citizens()])},refresh:!0,action(){return!!(ri($(this)[0])&&t.galaxy.consulate.count<1)&&(Ft("consulate","galaxy"),t.galaxy.resort={count:0,on:0},t.galaxy.super_freighter={count:0,on:0,crew:0},t.tech.xeno=9,!0)},citizens(){let e=10;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},resort:{id:"galaxy-resort",title:z("galaxy_resort"),desc:()=>`
                            ${z("galaxy_resort")}
                            ${z("requires_power")}
                            `,reqs:{xeno:9},cost:{Money:e=>Ps("resort",e,33e6,1.25,"galaxy"),Stone:e=>Ps("resort",e,25e6,1.25,"galaxy"),Furs:e=>Ps("resort",e,1e7,1.25,"galaxy"),Oil:e=>Ps("resort",e,Ht(125e3),1.25,"galaxy")},effect(){return`
                            ${z("plus_max_citizens",[3])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},effect(){let e=br(t.tech.world_control?1875e3:15e5),a=t.race.joyless?"":`
                            ${z("city_max_entertainer",[ta(2)])}
                            `;return`
                            ${z("plus_max_resource",[`$${e.toLocaleString()}`,z("resource_Money_name")])}
                            ${a}
                            ${z("space_red_vr_center_effect2",[2])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(5),action(){return!!ri($(this)[0])&&(Ft("resort","galaxy"),Yr($(this)[0]),!0)}},vitreloy_plant:{id:"galaxy-vitreloy_plant",title:z("galaxy_vitreloy_plant"),desc:()=>`
                            ${z("galaxy_vitreloy_plant")}
                            ${z("galaxy_vitreloy_plant_desc")}
                            `,reqs:{xeno:10},cost:{Money:e=>Ps("vitreloy_plant",e,35e6,1.25,"galaxy"),Cement:e=>Ps("vitreloy_plant",e,18e5,1.25,"galaxy"),Neutronium:e=>Ps("vitreloy_plant",e,25e4,1.25,"galaxy"),Iridium:e=>Ps("vitreloy_plant",e,85e4,1.25,"galaxy"),Aerogel:e=>Ps("vitreloy_plant",e,4e5,1.25,"galaxy")},effect(){return`
                            ${z("galaxy_vitreloy_plant_effect",[+$e("vitreloy_plant").toFixed(2)])}
                            ${z("galaxy_vitreloy_plant_effect2",[2.5,100])}
                            ${z("galaxy_vitreloy_plant_effect3",[5e4,$(this)[0].powered()])}
                            `},powered:()=>As(10),action(){return!!ri($(this)[0])&&(Ft("vitreloy_plant","galaxy"),Yr($(this)[0]),!0)}},super_freighter:{id:"galaxy-super_freighter",title:z("galaxy_super_freighter"),desc:()=>`
                            ${z("galaxy_super_freighter")}
                            ${z("galaxy_crew_fuel",[z("resource_Helium_3_name")])}
                            `,reqs:{xeno:9},cost:{Money:e=>Ps("super_freighter",e,28e6,1.2,"galaxy"),Aluminium:e=>Ps("super_freighter",e,35e5,1.2,"galaxy"),Alloy:e=>Ps("super_freighter",e,1e6,1.2,"galaxy"),Graphene:e=>Ps("super_freighter",e,75e4,1.2,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2),a="";return t.tech.banking>=13&&(a=`
                            ${z("interstellar_exchange_boost",[8])}
                            `),`
                            ${z("galaxy_freighter_effect",[5,Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name])}
                            ${a}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("spend",[e,t.resource.Helium_3.name])}
                            `},ship:{civ:()=>t.race.high_pop?5*Ei.high_pop.vars()[0]:5,mil:()=>0,helium:25},special:!0,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("super_freighter","galaxy"),t.galaxy.super_freighter.on++,!0)}}},gxy_alien2:{info:{name:()=>z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),desc:()=>z("galaxy_alien2_desc",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red,Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),control:()=>({name:Ki[t.galaxy.alien2.id].name,color:"danger"}),support:"foothold"},alien2_mission:{id:"galaxy-alien2_mission",title:()=>z("galaxy_alien2_mission",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),desc:()=>z("galaxy_alien2_mission_desc",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),reqs:{andromeda:4},grant:["conflict",1],queue_complete:()=>t.tech.conflict>=1?0:1,cost:{Custom(){if(t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_alien2")){let e=0;return Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]})),{label:z("galaxy_fleet_rating",[`400
                            `]),met:!(e<400)}}return{label:z("galaxy_fleet_rating",['400']),met:!1}}},effect(){let e=0;t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_alien2")&&Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]}));let a=e>=650?`${z("galaxy_piracy_low")}`:`${z("galaxy_piracy_avg")}`;return`
                            ${z("galaxy_alien2_mission_effect2",[e])}
                            ${z("galaxy_alien2_mission_effect3",[a])}
                            ${z("galaxy_alien2_mission_effect",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name])}
                            `},action(){if(ri($(this)[0])){let e=0;if(Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_alien2[a]})),e>=400){if(hs(z("galaxy_alien2_mission_result2",[Ki[t.galaxy.alien2.id].solar.red]),"info",!1,["progress"]),e<650){let e=80;t.race.instinct&&(e/=2);let a=[];Object.keys(t.galaxy.defense.gxy_alien2).forEach((function(r){for(let i=0;i0&&(e-=jt.gxy_gateway[r].ship.rating(),a.push(r))})),hs(z("galaxy_chthonian_mission_result_losses",[a.map((e=>z(`galaxy_${e}`))).join(", ")]),"danger",!1,["progress"]);for(let e=0;e`
                            ${z("galaxy_foothold")}
                            ${z("requires_power_combo",[t.resource.Elerium.name])}
                            `,reqs:{conflict:1},cost:{Money:e=>Ps("foothold",e,25e6,1.25,"galaxy"),Titanium:e=>Ps("foothold",e,3e6,1.25,"galaxy"),Polymer:e=>Ps("foothold",e,175e4,1.25,"galaxy"),Iridium:e=>Ps("foothold",e,9e5,1.25,"galaxy"),Bolognium:e=>Ps("foothold",e,5e4,1.25,"galaxy")},effect(){return`
                            ${z("galaxy_defense_platform_effect",[50])}
                            ${z("galaxy_foothold_effect",[$(this)[0].support(),Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
                            ${z("galaxy_foothold_effect2",[2.5,$(this)[0].powered()])}
                            `},support:()=>4,powered:()=>As(s.s_gate?20:0),powerBalancer:()=>[{s:t.galaxy.foothold.s_max-t.galaxy.foothold.support}],action(){return!!ri($(this)[0])&&(Ft("foothold","galaxy"),Yr($(this)[0]),1===t.tech.conflict&&(t.galaxy.armed_miner={count:0,on:0,crew:0,mil:0},t.tech.conflict=2,Dt(),Qr()),!0)}},armed_miner:{id:"galaxy-armed_miner",title:z("galaxy_armed_miner"),desc:()=>`
                            ${z("galaxy_armed_miner")}
                            `,reqs:{conflict:2},cost:{Money:e=>Ps("armed_miner",e,5e6,1.25,"galaxy"),Steel:e=>Ps("armed_miner",e,18e5,1.25,"galaxy"),Stanene:e=>Ps("armed_miner",e,1975e3,1.25,"galaxy"),Vitreloy:e=>Ps("armed_miner",e,2e4,1.25,"galaxy"),Soul_Gem:e=>Ps("armed_miner",e,1,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return`
                            ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                            ${z("gain",[.032,z("resource_Bolognium_name")])}
                            ${z("gain",[.23,z("resource_Adamantite_name")])}
                            ${z("gain",[.65,z("resource_Iridium_name")])}
                            ${z("galaxy_alien2_support",[$(this)[0].support(),Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                            ${z("spend",[e,t.resource.Helium_3.name])}
                            `},ship:{civ:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2,mil:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,helium:10,rating:()=>t.race.banana?4:5},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("armed_miner","galaxy"),t.galaxy.foothold.support`
                            ${z("galaxy_ore_processor")}
                            `,reqs:{conflict:3},cost:{Money:e=>Ps("ore_processor",e,3e6,1.25,"galaxy"),Iron:e=>Ps("ore_processor",e,5e6,1.25,"galaxy"),Coal:e=>Ps("ore_processor",e,375e4,1.25,"galaxy"),Graphene:e=>Ps("ore_processor",e,225e4,1.25,"galaxy")},effect(){return`
                            ${z("galaxy_ore_processor_effect",[10])}
                            ${z("galaxy_alien2_support",[$(this)[0].support(),Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
                            `},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("ore_processor","galaxy"),t.galaxy.foothold.supportPs("scavenger",e,75e5,1.25,"galaxy"),Alloy:e=>Ps("scavenger",e,125e4,1.25,"galaxy"),Aluminium:e=>Ps("scavenger",e,68e5,1.25,"galaxy"),Neutronium:e=>Ps("scavenger",e,75e3,1.25,"galaxy"),Elerium:e=>Ps("scavenger",e,750,1.25,"galaxy")},effect(){let e=Mt("gxy_alien2"),a=Math.round(25e3*e),r=+Ht($(this)[0].ship.helium).toFixed(2),i=t.race.cataclysm?`
                            ${z("galaxy_scavenger_effect2_cata",[+(100*e*.75).toFixed(1)])}
                            `:`
                            ${z("galaxy_scavenger_effect2",[+(100*e/4).toFixed(1)])}
                            `;return`
                            ${z("galaxy_scavenger_effect",[a])}
                            ${i}
                            ${z("galaxy_alien2_support",[$(this)[0].support(),Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            ${z("spend",[r,t.resource.Helium_3.name])}
                            `},ship:{civ:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,mil:()=>0,helium:12},support:()=>-1,powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("scavenger","galaxy"),t.galaxy.foothold.supportz("galaxy_chthonian"),desc:()=>z("galaxy_chthonian_desc",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),control:()=>({name:Ki[t.galaxy.alien2.id].name,color:"danger"})},chthonian_mission:{id:"galaxy-chthonian_mission",title:()=>z("galaxy_alien2_mission",[z("galaxy_chthonian")]),desc:()=>z("galaxy_alien2_mission_desc",[z("galaxy_chthonian")]),reqs:{chthonian:1},grant:["chthonian",2],queue_complete:()=>t.tech.chthonian>=2?0:1,cost:{Custom(){if(t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_chthonian")){let e=0;return Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]})),{label:z("galaxy_fleet_rating",[`1250
                            `]),met:!(e<1250)}}return{label:z("galaxy_fleet_rating",['1250']),met:!1}}},effect(){let e=0;t.galaxy.hasOwnProperty("defense")&&t.galaxy.defense.hasOwnProperty("gxy_chthonian")&&Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]}));let a=e>=4500?`${z("galaxy_piracy_low")}`:e>=2500?`${z("galaxy_piracy_avg")}`:`${z("galaxy_piracy_high")}`;return`
                            ${z("galaxy_alien2_mission_effect2",[e])}
                            ${z("galaxy_alien2_mission_effect3",[a])}
                            ${z("galaxy_alien2_mission_effect",[z("galaxy_chthonian")])}
                            `},action(){if(ri($(this)[0])){let e=0;if(Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(a){e+=jt.gxy_gateway[a].ship.rating()*t.galaxy.defense.gxy_chthonian[a]})),e>=1250){let a=500,r=[];hs(z("galaxy_chthonian_mission_result"),"info",!1,["progress"]),e>=2500&&(a=e>=4500?80:160),t.race.instinct&&(a/=2),Object.keys(t.galaxy.defense.gxy_chthonian).forEach((function(e){for(let i=0;i0&&(a-=jt.gxy_gateway[e].ship.rating(),r.push(e))})),hs(z("galaxy_chthonian_mission_result_losses",[r.map((e=>z(`galaxy_${e}`))).join(", ")]),"danger",!1,["progress"]);for(let e=0;e`
                            ${z("galaxy_minelayer")}
                            `,reqs:{chthonian:2},cost:{Money:e=>Ps("minelayer",e,9e6,1.25,"galaxy"),Iron:e=>Ps("minelayer",e,48e5,1.25,"galaxy"),Nano_Tube:e=>Ps("minelayer",e,125e4,1.25,"galaxy"),Nanoweave:e=>Ps("minelayer",e,1e5,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return`
                            ${z("galaxy_defense_platform_effect",[$(this)[0].ship.rating()])}
                            ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                            ${z("spend",[e,t.resource.Helium_3.name])}
                            `},ship:{civ:()=>0,mil:()=>t.race.high_pop?1*Ei.high_pop.vars()[0]:1,helium:8,rating:()=>t.race.banana?35:50},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("minelayer","galaxy"),t.galaxy.minelayer.on++,!0)},postPower(){Cs({el:"#gxy_chthonian"},"update")},post(){Cs({el:"#gxy_chthonian"},"update")}},excavator:{id:"galaxy-excavator",title:z("galaxy_excavator"),desc:()=>`
                            ${z("galaxy_excavator")}
                            `,reqs:{chthonian:3},cost:{Money:e=>Ps("excavator",e,12e6,1.25,"galaxy"),Polymer:e=>Ps("excavator",e,44e5,1.25,"galaxy"),Iridium:e=>Ps("excavator",e,36e5,1.25,"galaxy"),Mythril:e=>Ps("excavator",e,18e4,1.25,"galaxy")},effect(){return`
                            ${z("gain",[+$e("excavator").toFixed(3),z("resource_Orichalcum_name")])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(8),powerBalancer:()=>[{r:"Orichalcum",p:$e("excavator")}],action(){return!!ri($(this)[0])&&(Ft("excavator","galaxy"),Yr($(this)[0]),!0)}},raider:{id:"galaxy-raider",title:z("galaxy_raider"),desc:()=>`
                            ${z("galaxy_raider")}
                            `,reqs:{chthonian:3},cost:{Money:e=>Ps("raider",e,12e6,1.25,"galaxy"),Titanium:e=>Ps("raider",e,125e4,1.25,"galaxy"),Bolognium:e=>Ps("raider",e,6e5,1.25,"galaxy"),Vitreloy:e=>Ps("raider",e,125e3,1.25,"galaxy"),Stanene:e=>Ps("raider",e,825e3,1.25,"galaxy")},effect(){let e=+Ht($(this)[0].ship.helium).toFixed(2);return Mt("gxy_chthonian"),`
                            ${z("galaxy_ship_rating",[$(this)[0].ship.rating()])}
                            ${z("gain",[.65,z("resource_Deuterium_name")])}
                            ${z("gain",[.05,z("resource_Vitreloy_name")])}
                            ${z("gain",[2.3,z("resource_Polymer_name")])}
                            ${z("gain",[.8,z("resource_Neutronium_name")])}
                            ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                            ${z("spend",[e,t.resource.Helium_3.name])}
                            `},ship:{civ:()=>0,mil:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2,helium:18,rating:()=>t.race.banana?9:12},powered:()=>As(1),action(){return!!ri($(this)[0])&&(Ft("raider","galaxy"),t.galaxy.raider.on++,!0)},postPower(){Cs({el:"#gxy_chthonian"},"update")},post(){Cs({el:"#gxy_chthonian"},"update")}}}};function Ot(e){let t="space";return"int_"===e.substr(0,4)?t="interstellar":"prtl_"===e.substr(0,5)?t="portal":"gxy_"===e.substr(0,4)?t="galaxy":"tau_"===e.substr(0,4)&&(t="tauceti"),t}function Mt(e,a,r){if(t.tech.piracy&&!t.race.truepath){let i=0,n=["dreadnought","cruiser_ship","frigate_ship","corvette_ship","scout_ship"];for(let a=0;ac?c:i))/c)*l+(1-l))*(a?1:Mt("gxy_stargate")):(1-(c-(i>c?c:i))/c)*l+(1-l)}return 1}function St(){let e=["protoplasm",t.race.species];t.city.hasOwnProperty("surfaceDwellers")&&e.push(...t.city.surfaceDwellers),t.custom.hasOwnProperty("race0")||e.push("custom");let a=Object.keys(Ki).filter((function(t){return!["demonic","eldritch"].includes(Ki[t].type)&&!e.includes(t)})),r=en(a);t.galaxy.alien1={id:a[r]},e.push(a[r]),a=Object.keys(Ki).filter((function(t){return!["angelic"].includes(Ki[t].type)&&!e.includes(t)}));let i=en(a);t.galaxy.alien2={id:a[i]}}function Ct(){let e=1;return t.race.pack_rat&&(e*=1.05),t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),e*=t.tech.world_control?2:1,e}const zt={satellite:{count:0},propellant_depot:{count:0},gps:{count:0},nav_beacon:{count:0,on:0},moon_base:{count:0,on:0,support:0,s_max:0},iridium_mine:{count:0,on:0},helium_mine:{count:0,on:0},observatory:{count:0,on:0},spaceport:{count:0,on:0,support:0,s_max:0},red_tower:{count:0,on:0},living_quarters:{count:0,on:0},vr_center:{count:0,on:0},garage:{count:0},red_mine:{count:0,on:0},fabrication:{count:0,on:0},red_factory:{count:0,on:0},exotic_lab:{count:0,on:0},ziggurat:{count:0},space_barracks:{count:0,on:0},biodome:{count:0,on:0},laboratory:{count:0,on:0},geothermal:{count:0,on:0},swarm_plant:{count:0},swarm_control:{count:0,support:0,s_max:0},swarm_satellite:{count:0},gas_mining:{count:0,on:0},gas_storage:{count:0},star_dock:{count:0,ship:0,probe:0,template:"human"},outpost:{count:0,on:0},drone:{count:0},oil_extractor:{count:0,on:0},space_station:{count:0,on:0,support:0,s_max:0},iridium_ship:{count:0,on:0},elerium_ship:{count:0,on:0},elerium_prospector:{count:0,on:0},iron_ship:{count:0,on:0},elerium_contain:{count:0,on:0},e_reactor:{count:0,on:0},world_collider:{count:0},world_controller:{count:0,on:0},starport:{count:0,on:0,support:0,s_max:0},mining_droid:{count:0,on:0,adam:0,uran:0,coal:0,alum:0},processing:{count:0,on:0},habitat:{count:0,on:0},fusion:{count:0,on:0},laboratory:{count:0,on:0},exchange:{count:0,on:0},warehouse:{count:0},xfer_station:{count:0,on:0},cargo_yard:{count:0},cruiser:{count:0,on:0},dyson:{count:0},nexus:{count:0,on:0,support:0,s_max:0},harvester:{count:0,on:0},far_reach:{count:0,on:0},stellar_engine:{count:0,mass:8,exotic:0},mass_ejector:{count:0,on:0,total:0,mass:0,Food:0,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0},stargate:{count:0},gateway_station:{count:0,on:0},s_gate:{count:0,on:0},starbase:{count:0,on:0,support:0,s_max:0},bolognium_ship:{count:0,on:0,crew:0},scout_ship:{count:0,on:0,crew:0,mil:0},corvette_ship:{count:0,on:0,crew:0,mil:0},frigate_ship:{count:0,on:0,crew:0,mil:0},cruiser_ship:{count:0,on:0,crew:0,mil:0},dreadnought:{count:0,on:0,crew:0,mil:0},foothold:{count:0,on:0,support:0,s_max:0},turret:{count:0,on:0},carport:{count:0,damaged:0,repair:0},war_droid:{count:0,on:0},repair_droid:{count:0,on:0},war_drones:{count:0,on:0},sensor_drone:{count:0,on:0},attractor:{count:0,on:0}};function Ft(e,a){a||(a="space"),t[a][e]||(t[a][e]=zt[e]),t[a][e].count++}function At(e,t){return e&&t?$t[e][t]:$t}function It(e,t,a){switch(e){case"space":return Tt($t,t,a);case"interstellar":return Tt(xt,t,a);case"galaxy":return Tt(jt,t,a)}}function Tt(e,a,r){let i=t.race.truepath?"truepath":"standard";if(e[a][r].hasOwnProperty("path")&&!e[a][r].path.includes(i))return!1;var s=!0;return Object.keys(e[a][r].reqs).forEach((function(i){(!t.tech[i]||t.tech[i]=e[a][r].grant[1]&&(s=!1),s}function Lt(){(t.settings.tabLoad||1===t.settings.civTabs)&&(Et("inner"),t.race.truepath&&Et("outer"),Kt(),Dt())}function Et(e){if(e||(e=5===t.settings.spaceTabs?"outer":"inner"),!t.settings.tabLoad&&(1!==t.settings.civTabs||![1,5].includes(t.settings.spaceTabs)||1===t.settings.civTabs&&1===t.settings.spaceTabs&&"inner"!==e||5===t.settings.spaceTabs&&"outer"!==e))return;let a="inner"===e?$("#space"):$("#outerSol");if(Ss(a),a.append($(`

                            ${z("inner"===e?"tab_space":"tab_outer_space")}

                            `)),!t.settings.showSpace)return!1;let r=[];Object.keys($t).forEach((function(e){t.race.orbit_decayed||t.race.cataclysm?"spc_home"!==e&&(r.push(e),(t.race.orbit_decayed&&"spc_red"===e||t.race.cataclysm&&"spc_moon"===e)&&r.push("spc_home")):r.push(e)})),r.forEach((function(r){let i=r.replace("spc_","");if(t.settings.space[`${i}`]){if(t.race.truepath&&$t[r].info.zone!==e)return;let i="string"==typeof $t[r].info.name?$t[r].info.name:$t[r].info.name(),s=!(!t.race.orbit_decayed&&!t.race.cataclysm);if(s&&"spc_home"!==r||!s){if($t[r].info.support){let e=$t[r].info.support;t.space[e].hasOwnProperty("support")||(t.space[e].support=0,t.space[e].s_max=0),a.append(`

                            ${i}

                            {{ support }}/{{ s_max }}
                            `),Cs({el:`#sr${r}`,data:t.space[e]})}else a.append(`

                            ${i}

                            `);t.race.truepath&&$t[r].info.hasOwnProperty("syndicate")&&$t[r].info.syndicate()&&t.tech.syndicate&&($(`#${r}`).append(`
                            `),$(`#${r}synd`).append(`${z("space_syndicate")} `),$(`#${r}synd`).append(`${z("space_scan_effectiveness")} `),$(`#${r}synd`).append(`${z("space_overkill")} `),Cs({el:`#${r}synd`,data:t.space.syndicate,methods:{threat(e){if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let t=lt(e,!0);if(t.s>=10)return t.s>=50?t.r:Math.round(t.r*t.s*.02)}return"???"},scan:e=>t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")?+((lt(e,!0).s+25)/1.25).toFixed(1)+"%":z("galaxy_piracy_none"),overkill(e){if(t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")){let t=lt(e,!0);return t.s>=100?t.o:0}return 0}}}),$t[r].info.hasOwnProperty("extra")&&$t[r].info.extra(r))}ls(r,(function(){return"string"==typeof $t[r].info.desc?$t[r].info.desc:$t[r].info.desc()}),{elm:`#${r} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys($t[r]).forEach((function(t){"info"!==t&&Tt($t,r,t)&&Zr($t[r][t],"inner"===e?"space":"outerSol",t)}))}}))}function Kt(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||2!==t.settings.spaceTabs))return;let e=$("#interstellar");if(Ss(e),e.append($(`

                            ${z("tab_interstellar")}

                            `)),!t.settings.showDeep)return!1;Object.keys(xt).forEach((function(a){let r=a.replace("int_","");if(t.settings.space[`${r}`]){let r="string"==typeof xt[a].info.name?xt[a].info.name:xt[a].info.name();if(xt[a].info.support){let i=xt[a].info.support;t.interstellar[i].hasOwnProperty("support")||(t.interstellar[i].support=0,t.interstellar[i].s_max=0),e.append(`

                            ${r}

                            {{ support }}/{{ s_max }}
                            `),Cs({el:`#sr${a}`,data:t.interstellar[i]})}else e.append(`

                            ${r}

                            `);ls(a,(function(){return"string"==typeof xt[a].info.desc?xt[a].info.desc:xt[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),Object.keys(xt[a]).forEach((function(e){"info"!==e&&Tt(xt,a,e)&&Zr(xt[a][e],"interstellar",e)}))}}))}function Dt(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||3!==t.settings.spaceTabs))return;let e=$("#galaxy");if(Ss(e),e.append($(`

                            ${z("tab_galactic")}

                            `)),!t.settings.showGalactic)return!1;!function(e,a){if(t.tech.piracy&&!t.race.truepath){let r=$(`

                            ${z("galaxy_armada")}

                            `);e.append(r);let i=t.tech.world_control?z("civics_garrison_peacekeepers"):z("civics_garrison_soldiers");r.append($("|")),r.append($(`${i} {{ g.workers | stationed }} / {{ g.max | s_max }}`)),r.append($("|")),r.append($(`${z("job_crew_mil")} {{ g.crew }}`)),r.append($("|")),r.append($(`${z("job_crew_civ")} {{ c.workers }} / {{ c.max }}`)),Cs({el:`#h${a}`,data:{g:t.civic.garrison,c:t.civic.crew},filters:{stationed:e=>we(),s_max:e=>we(!0)}}),["soldier","crew1","crew2"].forEach((function(e){ls(`h${a}${e}`,(function(){switch(e){case"soldier":return me();case"crew1":return z("civics_garrison_crew_desc");case"crew2":return z("job_crew_desc")}}),{elm:`#h${a} span.${e}`})}));let s=$(`
                            `);e.append(s);let n=["scout_ship","corvette_ship","frigate_ship","cruiser_ship","dreadnought"],c=[];for(let e=0;e<6;e++){let e=$('
                            ');c.push(e),s.append(e)}for(let e=0;e${jt.gxy_gateway[n[e]].title}
                            `);c[e+1].append(t)}c[0].append($("")),c[0].append($(`${jt.gxy_gateway.info.name}`));for(let e=0;e{{ gateway.${n[e]} }}
                            `);c[e+1].append(t)}Object.keys(t.galaxy.defense).forEach((function(e){let a=e.substring(4);if(t.settings.space[a]&&"gateway"!==a){let r=$(`${"string"==typeof jt[e].info.name?jt[e].info.name:jt[e].info.name()}`);c[0].append(r);for(let r=0;r
                            '),i=$(`«`),s=$(`{{ ${a}.${n[r]} }}`),o=$(`»`);c[r+1].append(t),t.append(i),t.append(s),t.append(o)}}})),Cs({el:`#${a}`,data:{stargate:t.galaxy.defense.gxy_stargate,gateway:t.galaxy.defense.gxy_gateway,gorddon:t.galaxy.defense.gxy_gorddon,alien1:t.galaxy.defense.gxy_alien1,alien2:t.galaxy.defense.gxy_alien2,chthonian:t.galaxy.defense.gxy_chthonian,t:t.tech},methods:{sub(e,a){if(t.galaxy.defense[e][a]>0){let r=y();r>t.galaxy.defense[e][a]&&(r=t.galaxy.defense[e][a]),t.galaxy.defense.gxy_gateway[a]+=r,t.galaxy.defense[e][a]-=r}},add(e,a){if(t.galaxy.defense.gxy_gateway[a]>0){let r=y();r>t.galaxy.defense.gxy_gateway[a]&&(r=t.galaxy.defense.gxy_gateway[a]),t.galaxy.defense.gxy_gateway[a]-=r,t.galaxy.defense[e][a]+=r}}}}),Object.keys(t.galaxy.defense).forEach((function(e){let a=e.substring(4);t.settings.space[a]&&ls(`armada${a}`,(function(){return`
                            ${"string"==typeof jt[e].info.desc?jt[e].info.desc:jt[e].info.desc()}
                            `}))}));for(let e=0;e`);e.append(i);let s=$(`

                            ${r}

                            `);i.append(s),t.tech.xeno&&t.tech.xeno>=3&&i.append(`{{ r.control().name }}`);let n={el:`#${a}`,data:{r:jt[a].info},methods:{threat(e){let a=t.race.infiltrator?1:2;if(t.galaxy.defense[e].scout_ship>=a){let t=100*(1-Mt(e,!0));return t=t<1?Math.ceil(t):Math.round(t),0===t?"has-text-success":t<=20?"has-text-advanced":t<=40?"has-text-info":t<=60?"has-text-warning":t<=80?"has-text-caution":"has-text-danger"}return"has-text-danger"}},filters:{pirate(e){let a=t.race.infiltrator?1:2;if(t.galaxy.defense[e].scout_ship>=a){let a=100*(1-Mt(e,!0));a=a<1?Math.ceil(a):Math.round(a);let r=t.race.infiltrator?3:4;return t.galaxy.defense[e].scout_ship>=r?`${a}%`:z(0===a?"galaxy_piracy_none":a<=20?"galaxy_piracy_vlow":a<=40?"galaxy_piracy_low":a<=60?"galaxy_piracy_avg":a<=80?"galaxy_piracy_high":"galaxy_piracy_vhigh")}return"???"},defense:e=>Mt(e,!0,!0)}};if(jt[a].info.support){let e=jt[a].info.support;t.galaxy[e]&&(t.galaxy[e].hasOwnProperty("support")||(t.galaxy[e].support=0,t.galaxy[e].s_max=0),i.append('{{ s.support }}/{{ s.s_max }}'),n.data.s=t.galaxy[e])}t.tech.piracy&&i.append(`
                            ${z("galaxy_piracy_threat",[Ki[t.galaxy.alien2.id].name])}{{ '${a}' | pirate }}|${z("galaxy_armada")}: {{ '${a}' | defense }}
                            `),Cs(n),ls(a,(function(){return"string"==typeof jt[a].info.desc?jt[a].info.desc:jt[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),ls(a,(function(){return z("galaxy_control",[jt[a].info.control().name,r])}),{elm:`#${a} .regionControl`,classes:"has-background-light has-text-dark"}),Object.keys(jt[a]).forEach((function(e){"info"!==e&&Tt(jt,a,e)&&Zr(jt[a][e],"galaxy",e)}))}}))}function Bt(e){return t.tech.space_housing&&(e*=.8**t.tech.space_housing),e}function Gt(e){return t.tech.solar&&t.tech.solar>=5&&n.iron_ship&&(e*=.95**n.iron_ship),e}function Nt(e){if(t.space.swarm_plant){let a=t.tech.swarm?.88:.94;t.tech.swarm>=3&&(a-=_/100),a<.05&&(a=.05),e*=a**t.space.swarm_plant.count}return e}function Rt(e,a,r){return r=r||{},"heavy"===t.race.universe&&(e*=1.25+.5*Is("heavy")),t.race.truepath&&(e*=a?2.5:1.25),t.city.mass_driver&&s.mass_driver?e*=(t.race.truepath?.94:.95)**s.mass_driver:r.mass_driver&&(e*=.95**r.mass_driver),t.stats.achieve.heavyweight&&(e*=.96**t.stats.achieve.heavyweight.l),t.city.ptrait.includes("dense")&&(e*=ss.dense.vars()[2]),t.race.cataclysm&&(e*=.2),t.race.heavy&&(e*=1+Ei.heavy.vars()[0]/100),cn("launch_day")&&(e*=.95),e}function Ht(e){return"heavy"===t.race.universe&&(e*=1.2+.3*Is("heavy")),t.stats.achieve.heavyweight&&(e*=.96**t.stats.achieve.heavyweight.l),t.race.heavy&&(e*=1+Ei.heavy.vars()[0]/100),cn("launch_day")&&(e*=.95),e}function Ut(){let e={red:Ki[t.race.species].solar.red,hell:Ki[t.race.species].solar.hell,gas:Ki[t.race.species].solar.gas,gas_moon:Ki[t.race.species].solar.gas_moon,dwarf:Ki[t.race.species].solar.dwarf,titan:Di[Ki[t.race.species].type].solar.titan,enceladus:Di[Ki[t.race.species].type].solar.enceladus,triton:Di[Ki[t.race.species].type].solar.triton,eris:Di[Ki[t.race.species].type].solar.eris};if("custom"===t.race.species)for(let a of["titan","enceladus","triton","eris"])t.custom.race0.hasOwnProperty(a)&&(e[a]=t.custom.race0[a]);return e}const Vt=["l","h","a","e","m","mg"],Wt={standard:{name:z("universe_standard"),desc:z("universe_standard_desc"),effect:z("universe_standard_effect")},heavy:{name:z("universe_heavy"),desc:z("universe_heavy_desc"),effect:z("universe_heavy_effect",[5])},antimatter:{name:z("universe_antimatter"),desc:z("universe_antimatter_desc"),effect:z("universe_antimatter_effect")},evil:{name:z("universe_evil"),desc:z("universe_evil_desc"),effect:z("universe_evil_effect")},micro:{name:z("universe_micro"),desc:z("universe_micro_desc"),effect:z("universe_micro_effect",[75])},magic:{name:z("universe_magic"),desc:z("universe_magic_desc"),effect:z("universe_magic_effect")}};function Qt(a){a||t.race.noexport||(P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),qn(`biome_${t.city.biome}`),qn(`genus_${Ki[t.race.species].type}`),t.race.witch_hunter&&"magic"===t.race.universe?qn("soul_sponge"):(qn("ascended"),0===t.interstellar.thermal_collector.count&&Pn("energetic")),"junker"===t.race.species&&Pn("the_misery"),!t.race.modified&&t.race.junker&&"junker"===t.race.species&&Pn("garbage_pie"),t.race.emfield&&qn("technophobe"),t.race.cataclysm&&Pn("finish_line"),t.race.noexport="Race",Ss($("#city")),t.settings.showCity=!0,t.settings.showCivic=!1,t.settings.showResearch=!1,t.settings.showResources=!1,t.settings.showGenetics=!1,t.settings.showSpace=!1,t.settings.showDeep=!1,t.settings.showGalactic=!1,t.settings.showPortal=!1,t.settings.spaceTabs=0);let r=$('
                            '),i={ascended:{},technophobe:t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l?t.stats.achieve.technophobe.l:0};if(a?a.append(r):$("#city").append(r),r.append(`

                            ${z("genelab_title")}

                            - ${z("genelab_genes")} {{ g.genes }} - ${z("trait_untapped_name")}: {{ g.genes | untapped }}
                            `),a){r.append(`\n
                            ${z("achieve_ascended_name")}
                            \n `);let e=$("
                            ");r.append(e),Object.keys(Wt).forEach((function(a){i.ascended[a]=t.stats.achieve.ascended&&t.stats.achieve.ascended.hasOwnProperty(xn(a))?t.stats.achieve.ascended[xn(a)]:0,e.append(`\n
                            ${z("universe_"+a)}
                            \n `)})),r.append(`\n
                            ${z("achieve_technophobe_name")}
                            \n
                            \n
                            \n
                            \n `)}let s=$(`
                            ${z("genelab_name")}
                            ${z("genelab_entity")}
                            ${z("genelab_home")}
                            ${z("genelab_desc")}
                            `);r.append(s);let n=$(`
                            \n
                            ${z("genelab_red")}
                            \n
                            ${z("genelab_hell")}
                            \n
                            ${z("genelab_gas")}
                            \n
                            ${z("genelab_gas_moon")}
                            \n
                            ${z("genelab_dwarf")}
                            `);r.append(n);let c=$(`
                            \n
                            ${z("genelab_titan")}
                            \n
                            ${z("genelab_enceladus")}
                            \n
                            ${z("genelab_triton")}
                            \n
                            ${z("genelab_eris")}
                            `);r.append(c);let o=$('
                            ');r.append(o);let l=!1,_=`
                            ${z("genelab_genus")}
                            ",o.append($(_));let d=`
                            ${z("genelab_traits")}
                            ",o.append($(d));let h=`\n
                            \n \n
                            \n
                            \n
                            \n \n \n \n
                            \n
                            \n {{ err.msg }}\n
                            \n `;a||(h+=`\n
                            \n \n
                            \n `),r.append(h);var g=t.hasOwnProperty("custom")&&t.custom.hasOwnProperty("race0")?{name:t.custom.race0.name,desc:t.custom.race0.desc,entity:t.custom.race0.entity,home:t.custom.race0.home,red:t.custom.race0.red,hell:t.custom.race0.hell,gas:t.custom.race0.gas,gas_moon:t.custom.race0.gas_moon,dwarf:t.custom.race0.dwarf,titan:t.custom.race0.titan||Ut().titan,enceladus:t.custom.race0.enceladus||Ut().enceladus,triton:t.custom.race0.triton||Ut().triton,eris:t.custom.race0.eris||Ut().eris,genes:0,genus:t.custom.race0.genus,traitlist:t.custom.race0.traits}:{name:"Zombie",desc:"Zombies aren't so much a species as they are the shambling remains of a race who succumbed to a nightmarish virus. Yet somehow they continue to drone on.",entity:"rotting bipedal creatures",home:"Grave",red:"Brains",hell:"Rigor Mortis",gas:"Decompose",gas_moon:"Bones",dwarf:"Double Tap",titan:"Necromancer",enceladus:"Skeleton",triton:"Rot",eris:"Zombieland",genes:10,genus:l,traitlist:[]};for(let e=g.traitlist.length-1;e>=0;e--)Ei.hasOwnProperty(g.traitlist[e])&&"major"===Ei[g.traitlist[e]].type||g.traitlist.splice(e,1);g.genes=an(g,!!a&&i);let v={msg:""};Cs({el:"#celestialLab",data:{g,w:i,err:v},methods:{val(e){"technophobe"===e?i.technophobe<0?i.technophobe=0:i.technophobe>5&&(i.technophobe=5):i.ascended[e]<0?i.ascended[e]=0:i.ascended[e]>5&&(i.ascended[e]=5)},geneEdit(){g.genes=an(g,!!a&&i)},setRace(){an(g)>=0&&g.name.length>0&&g.desc.length>0&&g.entity.length>0&&g.home.length>0&&g.red.length>0&&g.hell.length>0&&g.gas.length>0&&g.gas_moon.length>0&&g.dwarf.length>0&&(t.custom.race0={name:g.name,desc:g.desc,entity:g.entity,home:g.home,red:g.red,hell:g.hell,gas:g.gas,gas_moon:g.gas_moon,dwarf:g.dwarf,titan:g.titan,enceladus:g.enceladus,triton:g.triton,eris:g.eris,genus:g.genus,traits:g.traitlist},function(){O(),ks("reset",{end:"ascend"});let a=t.race.species,r=t.race.gods,i=t.city.calendar.orbit,s=t.city.biome,n=t.city.ptrait,c=t.city.geology,o=Gs("ascend");t.stats.ascend++,rn(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),t.prestige.Harmony.count=parseFloat((t.prestige.Harmony.count+o.harmony).toFixed(2)),t.stats.harmony=parseFloat((t.stats.harmony+o.harmony).toFixed(2)),n.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),void 0===t.tech.world_control&&qn("cult_of_personality");let l=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0&&l++})),l>=4&&qn("miners_dream"),t.galaxy.hasOwnProperty("dreadnought")&&0!==t.galaxy.dreadnought.count||qn("dreaded"),t.race.modified||"synth"!==t.race.species&&"nano"!==t.race.species||!t.race.emfield||Pn("digital_ascension"),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),Sn();let _=!!t.race.hasOwnProperty("srace")&&t.race.srace,d=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!0},d>0&&(t.race.corruption=d),_&&(t.race.srace=_),Object.keys(c).forEach((function(e){c[e]+=.02})),H({orbit:i,biome:s,ptrait:n,geology:c}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}())},allowed:e=>!("synthetic"===g.genus||!["deconstructor","imitation"].includes(e)||(g.traitlist.includes(e)&&g.traitlist.splice(g.traitlist.indexOf(e),1),0)),reset(){g.name="",g.desc="",g.entity="",g.home="",g.red="",g.hell="",g.gas="",g.gas_moon="",g.dwarf="",g.titan="",g.enceladus="",g.triton="",g.eris="",g.genus=l,g.traitlist=[],g.genes=an(g,!!a&&i)},customImport(){let e=document.getElementById("customFile").files[0];if(e){let r=new FileReader;r.readAsText(e,"UTF-8"),r.onload=function(r){let s="";try{s=JSON.parse(r.target.result)}catch{return void(v.msg=z("string_pack_error",[e.name]))}let n=!1;if(Object.keys(g).forEach((function(e){s[e]&&typeof g[e]!=typeof s[e]&&(n=!0)})),n)return v.msg=z("string_pack_error",[e.name]),void console.log("format fail");Object.keys(g).forEach((function(e){s[e]&&(g[e]=s[e])})),["name","home","red","hell","gas","gas_moon","dwarf","titan","enceladus","triton","eris"].forEach((function(e){!s[e]&&["titan","enceladus","triton","eris"].includes(e)?g[e]=z(`genus_${g.genus}_solar_${e}`):g[e].length>20&&(g[e]=g[e].substring(0,20))})),g.entity.length>40&&(g.entity=g.entity.substring(0,40)),g.desc.length>255&&(g.desc=g.desc.substring(0,255)),a||t.stats.achieve[`genus_${g.genus}`]&&t.stats.achieve[`genus_${g.genus}`].l>0||(g.genus=l);let c=[];for(let e=0;e{const r=document.createElement("a"),i=new Blob([e],{type:"text/plain"});r.href=URL.createObjectURL(i),r.download=t,r.click(),URL.revokeObjectURL(r.href)})(JSON.stringify(g,null,4),`evolve-custom-${g.name}.txt`)}},filters:{cost(e){if(Ei[e].val>=0){let r=2;a?r+=i.technophobe:t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1&&(r+=t.stats.achieve.technophobe.l);let s=Ei[e].val,n=0;for(let e=0;e=0&&n++;return g.traitlist.includes(e)&&n--,n>r&&(s+=n-r),s}return Ei[e].val},untapped:e=>`+${e>0?+(100*(e/(e+20)/10+24e-5)).toFixed(3):0}%`}}),Object.keys(Li).forEach((function(e){t.stats.achieve[`genus_${e}`]&&t.stats.achieve[`genus_${e}`].l>0&&ls(`celestialLabgenusSelection${e}`,(function(){let t=$(`
                            ${z(`genelab_genus_${e}_desc`)}
                            `);return Object.keys(Li[e]).forEach((function(e){if(Ei[e]){let a=$("
                            ");vn(a,e,{trank:1}),t.append(a)}})),t}),{elm:`#celestialLab .genus_selection .${e}`,classes:"w30",wide:!0})})),Object.keys(u).sort().forEach((function(e){Ei.hasOwnProperty(e)&&"major"===Ei[e].type&&ls(`celestialLabtraitSelection${e}`,(function(){let t=$("
                            ");return vn(t,e,{trank:1}),t}),{elm:`#celestialLab .trait_selection .t${e}`,classes:"w30",wide:!0})}))}function Jt(a){a||t.race.noexport||(P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),qn(`biome_${t.city.biome}`),qn(`genus_${Ki[t.race.species].type}`),qn("lamentis"),"junker"===t.race.species&&Pn("the_misery"),t.race.noexport="Planet",Ss($("#city")),t.settings.showCity=!0,t.settings.showCivic=!1,t.settings.showResearch=!1,t.settings.showResources=!1,t.settings.showGenetics=!1,t.settings.showSpace=!1,t.settings.showDeep=!1,t.settings.showGalactic=!1,t.settings.showPortal=!1,t.settings.spaceTabs=0);let r=$('
                            '),i={ascended:{},lamentis:t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l?t.stats.achieve.lamentis.l:0};a?a.append(r):$("#city").append(r),r.append(`

                            ${z("planetlab_title")}

                            - ${z("planetlab_points")} {{ p.pts }}
                            `);let s=$('
                            ');r.append(s);let n=!1,c=`
                            ${z("wiki_planet_biome")}
                            ",s.append($(c));let o=`
                            ${z("wiki_planet_trait")}
                            ",s.append($(o));let l={},_=["Copper","Iron","Aluminium","Coal","Oil","Titanium","Uranium"];t.stats.achieve.whitehole&&_.push("Iridium");let d=`
                            ${z("planetlab_res")}
                            ",s.append($(d));let p={biome:n,pts:0,traitlist:[],geology:l,orbit:t.city.calendar.orbit};if(t.custom.hasOwnProperty("planet")){let e=xn();if(t.custom.planet.hasOwnProperty(e)){let a="s";t.custom.planet[e][a]&&(p=sn(t.custom.planet[e][a]),p.orbit=t.city.calendar.orbit,_.forEach((function(e){p.geology.hasOwnProperty(e)?p.geology[e]*=100:p.geology[e]=0})))}}p.pts=Zt(p);let u=`
                            \n
                            \n \n
                            \n `;a||(u+=`\n
                            \n \n
                            \n `),u+="
                            ",r.append(u),Cs({el:"#celestialLab",data:{p,w:i},methods:{pEdit(){p.pts=Zt(p)},setPlanet(){if(Zt(p)>=0){Object.keys(p.geology).forEach((function(e){0===p.geology[e]?delete p.geology[e]:p.geology[e]/=100})),t.custom.hasOwnProperty("planet")||(t.custom.planet={});let a=xn();t.custom.planet.hasOwnProperty(a)||(t.custom.planet[a]={s:!1});let r="s";t.custom.planet[a][r]=sn(p),delete t.custom.planet[a][r].pts,function(a){O(),ks("reset",{end:"terraform"});let r=t.race.species,i=t.race.gods,s=t.city.calendar.orbit,n=a.biome,c=a.traitlist,o=a.geology,l=Gs("terraform");t.stats.terraform++,rn(),t.prestige.Phage.count+=l.phage,t.stats.phage+=l.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=l.plasmid,t.stats.antiplasmid+=l.plasmid):(t.prestige.Plasmid.count+=l.plasmid,t.stats.plasmid+=l.plasmid),t.prestige.Harmony.count=parseFloat((t.prestige.Harmony.count+l.harmony).toFixed(2)),t.stats.harmony=parseFloat((t.stats.harmony+l.harmony).toFixed(2)),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),void 0===t.tech.world_control&&qn("cult_of_personality");let _=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0&&_++})),_>=4&&qn("miners_dream"),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross"),Sn();let d=!!t.race.hasOwnProperty("srace")&&t.race.srace,p=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:r,old_gods:i,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended,rejuvenated:!0},p>0&&(t.race.corruption=p),d&&(t.race.srace=d),H({orbit:s,biome:n,ptrait:c,geology:o}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(p)}},reset(){p.traitlist=[],Object.keys(p.geology).forEach((function(e){p.geology[e]=0})),p.pts=Zt(p)},less(e){p.geology[e]-=y(),p.geology[e]<-20&&(p.geology[e]=-20)},more(e){p.geology[e]+=y();let a=30;t.stats.achieve.whitehole&&(a+=5*t.stats.achieve.whitehole.l),"eden"===p.biome&&(a+=5),p.geology[e]>a&&(p.geology[e]=a)}},filters:{res:e=>p.geology[e]}})}function Zt(e,a){let r=("eden"===e.biome?0:10)+(t.stats.achieve.lamentis?10*t.stats.achieve.lamentis.l:0);t.race.truepath&&(r*=2),r-=e.traitlist.length**3;let i=0;return Object.keys(e.geology).forEach((function(t){0!==e.geology[t]&&(r-=e.geology[t],i++)})),i>3&&(r-=(i-3)**2),r}const Xt={unemployed:function(e){let a=z("job_unemployed_desc");return"unemployed"!==t.civic.d_job||e||(a=a+" "+z("job_default",[z("job_unemployed")])),a},hunter:function(e){let a=z("job_hunter_desc",[t.resource.Food.name]);return t.race.unfathomable&&(a=z("job_eld_hunter_desc")),t.race.artifical?a=t.race.soul_eater?z("job_art_demon_hunter_desc",[t.resource.Furs.name,t.resource.Lumber.name]):z("job_art_hunter_desc",[t.resource.Furs.name]):t.race.soul_eater&&"wendigo"!==t.race.species&&(a=z(t.race.evil?"job_evil_hunter_desc":"job_not_evil_hunter_desc",[t.resource.Food.name,t.resource.Lumber.name,t.resource.Furs.name])),"hunter"!==t.civic.d_job||e||(a=a+" "+z("job_default",[t.race.unfathomable?z("job_raider"):z("job_hunter")])),a},forager:function(e){let a=z("job_forager_desc");return"forager"!==t.civic.d_job||e||(a=a+" "+z("job_default",[z("job_forager")])),a},farmer:function(e){let a=+ia(!0,e).toFixed(2),r=+ia(!1,e).toFixed(2);e||(a=+ea(a,"farmer").toFixed(2),r=+ea(r,"farmer").toFixed(2));let i=t.race.high_pop&&!e?z("job_farmer_desc_hp",[a,t.resource.Food.name,ta(1),r,ta(1)*t.city.farm.count]):z("job_farmer_desc",[a,t.resource.Food.name,t.city.farm.count,r]);return"farmer"!==t.civic.d_job||e||(i=i+" "+z("job_default",[z("job_farmer")])),i},lumberjack:function(e){let a=e&&t.race.servants?t.race.servants.jobs.lumberjack:t.civic.lumberjack.workers,r=t.civic.lumberjack.impact;if(e||(a=+ea(a,"lumberjack").toFixed(2),r=+ea(r,"lumberjack").toFixed(2)),!t.race.evil||t.race.soul_eater&&"wendigo"!==t.race.species){let i=1+(t.tech.axe&&t.tech.axe>0?.35*(t.tech.axe-1):0);e||(i*=Bi(a,"lumberjack")),"forest"===t.city.biome&&(r*=is.forest.vars()[0]),"savanna"===t.city.biome&&(r*=is.savanna.vars()[2]),"desert"===t.city.biome&&(r*=is.desert.vars()[2]),"swamp"===t.city.biome&&(r*=is.swamp.vars()[2]),"taiga"===t.city.biome&&(r*=is.taiga.vars()[0]);let s=z("job_lumberjack_desc",[+(r*i).toFixed(2),t.resource.Lumber.name]);return"lumberjack"!==t.civic.d_job||e||(s=s+" "+z("job_default",[z("job_lumberjack")])),s}{let i=1;e||(i*=Bi(a,"lumberjack"));let s=+(r*i).toFixed(2),n=+(r/4*i).toFixed(2),c="wendigo"===t.race.species?z("job_reclaimer_desc2",[s]):z("job_reclaimer_desc",[s,n]);return"lumberjack"!==t.civic.d_job||e||(c=c+" "+z("job_default",[z("job_reclaimer")])),c}},quarry_worker:function(e){let a=e&&t.race.servants?t.race.servants.jobs.quarry_worker:t.civic.quarry_worker.workers,r=t.civic.quarry_worker.impact;e||(a=+ea(a,"quarry_worker").toFixed(2),r=+ea(r,"quarry_worker").toFixed(2));let i=1+(t.tech.hammer&&t.tech.hammer>0?.4*t.tech.hammer:0);e||(i*=Bi(a,"miner")),"desert"===t.city.biome&&(i*=is.desert.vars()[0]),"swamp"===t.city.biome&&(i*=is.swamp.vars()[3]),t.tech.explosives&&t.tech.explosives>=2&&(i*=t.tech.explosives>=3?1.75:1.5);let s=+(r*i).toFixed(1),n=t.resource.Aluminium.display?z("job_quarry_worker_desc2",[s,t.resource.Stone.name,t.resource.Aluminium.name]):z("job_quarry_worker_desc1",[s,t.resource.Stone.name]);return t.race.smoldering&&(n=n+" "+z("job_quarry_worker_smoldering",[t.resource.Chrysotile.name])),"quarry_worker"!==t.civic.d_job||e||(n=n+" "+z("job_default",[z("job_quarry_worker")])),n},crystal_miner:function(e){let a=e&&t.race.servants?t.race.servants.jobs.crystal_miner:t.civic.crystal_miner.workers,r=t.civic.crystal_miner.impact,i=1;e||(a=+ea(a,"crystal_miner").toFixed(2),r=+ea(r,"crystal_miner").toFixed(2),i*=Bi(a,"miner"));let s=z("job_crystal_miner_desc",[+(r*i).toFixed(2),t.resource.Crystal.name]);return"crystal_miner"!==t.civic.d_job||e||(s=s+" "+z("job_default",[z("job_crystal_miner")])),s},scavenger:function(e){let a=Ei.scavenger.vars()[0];t.city.ptrait.includes("trashed")&&t.race.scavenger&&(a*=1+Ei.scavenger.vars()[1]/100),t.race.high_pop&&!e&&(a*=Ei.high_pop.vars()[1]/100),e||(a=+ea(a,"scavenger").toFixed(2));let r=z("job_scavenger_desc",[Ki[t.race.species].home,a]);return"scavenger"!==t.civic.d_job||e||(r=r+" "+z("job_default",[z("job_scavenger")])),r},torturer:function(){return z("job_torturer_desc")},miner:function(){return t.tech.mining>=3?t.race.sappy&&t.tech.alumina?z("job_miner_desc2_amber"):z("job_miner_desc2"):z("job_miner_desc1")},coal_miner:function(){return t.tech.uranium?z("job_coal_miner_desc2"):z("job_coal_miner_desc1")},craftsman:function(){return z("job_craftsman_desc")},cement_worker:function(){let e=t.race.high_pop?3/Ei.high_pop.vars()[0]:3;"ashland"===t.city.biome&&(e*=is.ashland.vars()[1]),e=+ea(e,"cement_worker").toFixed(2);let a=+ea(t.civic.cement_worker.impact,"cement_worker").toFixed(2)*(t.tech.cement>=4?1.2:1)*Bi(t.civic.cement_worker.workers,"factory");return"ashland"===t.city.biome&&(a*=is.ashland.vars()[1]),a=+a.toFixed(2),t.race.sappy?z("job_cement_worker_amber_desc",[a]):z("job_cement_worker_desc",[a,e])},banker:function(){let e=100*+ea(t.civic.banker.impact,"banker").toFixed(2);return t.tech.banking>=10&&(e+=2*t.tech.stock_exchange),t.race.truthful&&(e*=1-Ei.truthful.vars()[0]/100),"republic"===t.civic.govern.type&&(e*=1.25),t.race.high_pop&&(e*=Ei.high_pop.vars()[1]/100),e=+e.toFixed(0),z("job_banker_desc",[e])},entertainer:function(){let e=t.tech.theatre;t.race.musical&&(e+=Ei.musical.vars()[0]),t.race.emotionless&&(e*=1-Ei.emotionless.vars()[0]/100),t.race.high_pop&&(e*=Ei.high_pop.vars()[1]/100),e=+ea(e,"entertainer").toFixed(2);let a=t.race.high_pop?Ei.high_pop.vars()[1]/100:1;return a=+ea(a,"entertainer").toFixed(2),t.tech.superstar?z("job_entertainer_desc2",[e,a]):z("job_entertainer_desc",[+e.toFixed(2)])},priest:function(){let e="";return e="theocracy"===t.civic.govern.type&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display?z("job_priest_desc2"):z("job_priest_desc"),t.tech.cleric&&(e+=` ${z("job_priest_desc3")}`),e},professor:function(){let e=+ea(1,"professor"),a=+(t.race.studious?t.civic.professor.impact+Ei.studious.vars()[0]:t.civic.professor.impact),r=ts("elven");return r>0&&(a+=Ei.studious.vars(1)[0]*r),e*=a,e*=t.race.pompous?1-Ei.pompous.vars()[0]/100:1,e*=Bi(t.civic.professor.workers,"science"),t.tech.anthropology&&t.tech.anthropology>=3&&(e*=1+.05*t.city.temple.count),"theocracy"===t.civic.govern.type&&(e*=.75),e=+e.toFixed(2),z("job_professor_desc",[e])},scientist:function(){let e=+ea(t.civic.scientist.impact,"scientist").toFixed(2);return e*=Bi(t.civic.scientist.workers,"science"),t.tech.science>=6&&t.city.wardenclyffe&&(e*=1+t.civic.professor.workers*t.city.wardenclyffe.on*.01),t.space.satellite&&(e*=1+.01*t.space.satellite.count),"theocracy"===t.civic.govern.type&&(e*=t.tech.high_tech&&t.tech.high_tech>=12?t.tech.high_tech>=16?.75:.6:.5),e=+e.toFixed(2),"magic"===t.race.universe?z("job_wizard_desc",[e,+(.025*Is("magic")).toFixed(4)]):z("job_scientist_desc",[e])},colonist:()=>z(t.race.truepath?"job_colonist_desc_tp":"job_colonist_desc",[Ut().red]),titan_colonist:()=>z("job_colonist_desc_tp",[Ut().titan]),space_miner:()=>z("job_space_miner_desc"),hell_surveyor:()=>z("job_hell_surveyor_desc"),archaeologist(){let e=75*(s.arcology||0),a=(be(t.portal.guard_post.on,"hellArmy",0)+e)/5e3;a=a>1?1:a;let r=25e4;return t.race.high_pop&&(r*=Ei.high_pop.vars()[1]/100),z("job_archaeologist_desc",[Math.round(r*a).toLocaleString()])},pit_miner:()=>z("job_pit_miner_desc",[z("tau_planet",[Ki[t.race.species].home])]),crew:()=>z("job_crew_desc")};function Yt(e){e||$("#civics").append($(`

                            ${z("civics_jobs")}

                            `)),ra("unemployed",e,0,0,"warning"),ra("hunter",e,0,0),ra("forager",e,0,0),ra("farmer",e,.82,5),ra("lumberjack",e,1,5),ra("quarry_worker",e,1,5),ra("crystal_miner",e,.1,5),ra("scavenger",e,.12,5),ra("torturer",e,1,3,"advanced"),ra("miner",e,1,4,"advanced"),ra("coal_miner",e,.2,4,"advanced"),ra("craftsman",e,1,5,"advanced"),ra("cement_worker",e,.4,5,"advanced"),ra("entertainer",e,1,10,"advanced"),ra("priest",e,1,3,"advanced"),ra("professor",e,.5,6,"advanced"),ra("scientist",e,1,5,"advanced"),ra("banker",e,.1,6,"advanced"),ra("colonist",e,1,5,"advanced"),ra("titan_colonist",e,1,5,"advanced"),ra("space_miner",e,1,5,"advanced"),ra("hell_surveyor",e,1,1,"advanced"),ra("archaeologist",e,1,1,"advanced"),ra("pit_miner",e,1,4.5,"advanced"),ra("crew",e,1,4,"alert"),e||t.race.start_cataclysm||(sa(),t.race.servants&&function(){if(Ss($("#servants")),t.race.servants){var e=$(`

                            ${z("civics_servants")}

                            {{ s.used }} / {{ s.max }}
                            `);$("#servants").append(e),["hunter","forager","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].forEach((function(e){ra(e,"servant")})),Cs({el:"#servantList",data:{s:t.race.servants},methods:{level:()=>0===t.race.servants.used?"count has-text-danger":t.race.servants.used===t.race.servants.max?"count has-text-success":t.race.servants.used<=t.race.servants.max/3?"count has-text-caution":t.race.servants.used<=.66*t.race.servants.max?"count has-text-warning":t.race.servants.used`),_=c?$('
                            '):$(`
                            `);if(n&&"unemployed"!==e){let t=$(`

                            {{ civic.${e}.name }}

                            {{ civic.${e}.workers | adjust('${e}') }} / {{ civic.${e}.max | adjust('${e}') }}
                            `);l.append(t)}else{n=n||"info";let t=c?$(`

                            {{ civic.${e}.name }}

                            {{ sjob.${e} }}
                            `):$(``);l.append(t)}if(l.append(_),$(c?"#servants":"#jobs").append(l),"crew"!==e){var d=$(`«`),p=$(`»`);_.append(d),_.append(p)}Cs(c?{el:`#${o}`,data:{civic:t.civic,sjob:t.race.servants.jobs},methods:{showJob:e=>t.civic[e].display||"scavenger"===e&&t.race.servants.force_scavenger,add(){let a=y();for(let r=0;rt.race.servants.used;r++)t.race.servants.jobs[e]++,t.race.servants.used++},sub(){let a=y();for(let r=0;r0;r++)t.race.servants.jobs[e]--,t.race.servants.used--}}}:{el:`#${o}`,data:{civic:t.civic},methods:{showJob:e=>t.civic[e].display,add(){let a=y();for(let r=0;r0;r++)t.civic[e].workers++,t.civic[t.civic.d_job].workers--,t.civic[e].assigned=t.civic[e].workers},sub(){let a=y();for(let r=0;r0;r++)t.civic[e].workers--,t.civic[t.civic.d_job].workers++,t.civic[e].assigned=t.civic[e].workers},level:e=>0===t.civic[e].workers?"count has-text-danger":t.civic[e].workers===t.civic[e].max?"count has-text-success":t.civic[e].workers<=t.civic[e].max/3?"count has-text-caution":t.civic[e].workers<=.66*t.civic[e].max?"count has-text-warning":t.civic[e].workerst.civic.d_job===e},filters:{d_state:e=>t.civic.d_job===e?"*":"",event(a){if("unemployed"===e&&t.civic.unemployed.display||"hunter"===e&&!t.civic.unemployed.display){let e=Qs(3,14);if(0===a&&e.length>0)return e}return a},adjust:(e,t)=>"titan_colonist"===t&&s.ai_colonist?e+ta(s.ai_colonist):e}}),ls(o,(function(){return Xt[e](c)}),{elm:`#${o} .job_label`,classes:"has-background-light has-text-dark"})}}function ia(e,a){let r=t.civic.farmer.impact;return e&&(r+=t.tech.agriculture&&t.tech.agriculture>=2?1.15:.65),t.race.living_tool&&!a?r*=1+(t.tech.science&&t.tech.science>0?t.tech.science/5:0):r*=1+(t.tech.hoe&&t.tech.hoe>0?t.tech.hoe/3:0),r*="grassland"===t.city.biome?is.grassland.vars()[0]:1,r*="savanna"===t.city.biome?is.savanna.vars()[0]:1,r*="ashland"===t.city.biome?is.ashland.vars()[0]:1,r*="volcanic"===t.city.biome?is.volcanic.vars()[0]:1,r*="hellscape"===t.city.biome?is.hellscape.vars()[0]:1,r*=t.city.ptrait.includes("trashed")?ss.trashed.vars()[0]:1,a||(r*=Bi(t.civic.farmer.workers,"farmer")),r*=t.tech.agriculture>=7?1.1:1,r*=t.race.low_light?1-Ei.low_light.vars()[0]/100:1,a&&(r*=ta(1)),r}function sa(e){if(Ss($(e?"#skilledServants":"#foundry")),t.city.foundry&&t.city.foundry.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation){let a=$(e?"#skilledServants":"#foundry"),r=e?"{{ s.sused }} / {{ s.smax }}":"{{ f.crafting }} / {{ c.max }}",i=$(`

                            ${z(e?"civics_skilled_servants":"craftsman_assigned")}

                            ${r}
                            `);a.append(i);let c=cn("summer"),o=["Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Aerogel","Nanoweave"];e||(o.push("Scarletite"),o.push("Quantium")),c&&!e&&o.push("Thermite");for(let r=0;r');a.append(s);let n,c=$('
                            ');n="Scarletite"===i&&t.portal.hasOwnProperty("hell_forge")?$(`

                            ${r}

                            {{ f.${i} }} / {{ p.on | maxScar }}
                            `):"Quantium"===i&&(t.space.hasOwnProperty("zero_g_lab")||t.tauceti.hasOwnProperty("infectious_disease_lab"))?$(`

                            ${r}

                            {{ f.${i} }} / {{ e.on | maxQuantium }}
                            `):$(`

                            ${r}

                            ${e?`{{ s.sjobs.${i} }}`:`{{ f.${i} }}`}
                            `),s.append(n),s.append(c),a.append(s);let o=$(`«`),l=$(`»`);c.append(o),c.append(l)}}let l=t.portal.hasOwnProperty("hell_forge")?{c:t.civic.craftsman,p:t.portal.hell_forge}:{c:t.civic.craftsman,e:t.space.hasOwnProperty("zero_g_lab")||t.tauceti.hasOwnProperty("infectious_disease_lab")?t.tech.isolation?t.tauceti.infectious_disease_lab:t.space.zero_g_lab:{count:0,on:0}};e?l.s=t.race.servants:l.f=t.city.foundry,Cs({el:e?"#skilledServants":"#foundry",data:l,methods:{add(a){let r=y(),i=-1;"Scarletite"===a?(i=s.hell_forge||0,t.race.high_pop&&(i*=Ei.high_pop.vars()[0])):"Quantium"===a&&(i=t.tech.isolation?Math.min(n.infectious_disease_lab,s.infectious_disease_lab)||0:Math.min(n.zero_g_lab,s.zero_g_lab)||0,t.race.high_pop&&(i*=Ei.high_pop.vars()[0]));for(let s=0;s0&&(-1===i||i>t.city.foundry[a])))break;t.civic.craftsman.workers++,t.city.foundry.crafting++,t.city.foundry[a]++,t.civic[t.civic.d_job].workers--}},sub(a){let r=y();for(let i=0;i0))break;t.race.servants.sjobs[a]--,t.race.servants.sused--}else{if(!(t.city.foundry[a]>0))break;t.city.foundry[a]--,t.civic.craftsman.workers--,t.city.foundry.crafting--,t.civic[t.civic.d_job].workers++}},level(){let a=e?t.race.servants.sused:t.civic.craftsman.workers,r=e?t.race.servants.smax:t.civic.craftsman.max;return 0===a?"count has-text-danger":a===r?"count has-text-success":a<=r/3?"count has-text-caution":a<=.66*r?"count has-text-warning":a"),a=t.resource[r].name,i=Ta(r,"auto").multiplier,s=t.genes.crafty?2:1,n=+t.resource[r].diff.toFixed(2),c=+(100*i).toFixed(0);e.append($(`
                            ${z("craftsman_hover_bonus",[c.toLocaleString(),a])}
                            `)),e.append($(`
                            ${z("craftsman_hover_prod",[n.toLocaleString(),a])}
                            `));let o=Ia();for(let a=0;a${z("craftsman_hover_cost",[i,t.resource[o[r][a].r].name])}
                            `))}return e};tr(e?`scraft${r}`:`craft${r}`,r,"auto",a)}}e?ls("servantFoundry",(function(){return z("civics_skilled_servants_desc")}),{elm:"#skilledServants .foundry",classes:"has-background-light has-text-dark"}):ls("craftsmenFoundry",(function(){return z("job_craftsman_hover")}),{elm:"#foundry .foundry",classes:"has-background-light has-text-dark"}),t.race.servants&&!e&&t.race.servants.smax>0&&sa(!0)}}const na={prtl_fortress:{info:{name:z("portal_fortress_name"),desc:z("portal_fortress_desc"),repair(){let e=200;return s.repair_droid&&(e*=.95**s.repair_droid),Math.round(e)}},turret:{id:"portal-turret",title:()=>z(t.tech.turret?t.tech.turret>=2?"portal_turret_title3":"portal_turret_title2":"portal_turret_title1"),desc:()=>`
                            ${z(t.tech.turret?t.tech.turret>=2?"portal_turret_title3":"portal_turret_title2":"portal_turret_title1")}
                            ${z("requires_power")}
                            `,reqs:{portal:2},cost:{Money:e=>Ps("turret",e,35e4,1.28,"portal"),Copper:e=>Ps("turret",e,5e4,1.28,"portal"),Adamantite:e=>Ps("turret",e,8e3,1.28,"portal"),Elerium:e=>Ps("turret",e,15,1.28,"portal"),Nano_Tube:e=>Ps("turret",e,28e3,1.28,"portal")},powered:()=>As(t.tech.turret?4+t.tech.turret:4),postPower(e){s.turret=t.portal.turret.on,Cs({el:"#fort"},"update")},effect(){let e=t.tech.turret?t.tech.turret>=2?70:50:35,a=$(this)[0].powered();return`
                            ${z("portal_turret_effect",[e])}
                            ${z("minus_power",[a])}
                            `},action(){return!!ri($(this)[0])&&(Ft("turret","portal"),Yr($(this)[0])&&(s.turret++,Cs({el:"#fort"},"update")),!0)}},carport:{id:"portal-carport",title:z("portal_carport_title"),desc:()=>z("portal_carport_desc",[1]),reqs:{portal:2},cost:{Money:e=>Ps("carport",e,25e4,1.3,"portal"),Cement:e=>Ps("carport",e,18e3,1.3,"portal"),Oil:e=>Ps("carport",e,6500,1.3,"portal"),Plywood:e=>Ps("carport",e,8500,1.3,"portal")},repair(){let e=180;return s.repair_droid&&(e*=.92**s.repair_droid),Math.round(e)},effect:()=>`${z("portal_carport_effect",[1])}`,action(){return!!ri($(this)[0])&&(Ft("carport","portal"),t.civic.hell_surveyor.display=!0,t.resource.Infernite.display=!0,t.tech.infernite||(t.tech.infernite=1,Qr()),!0)}},war_droid:{id:"portal-war_droid",title:z("portal_war_droid_title"),desc:()=>`
                            ${z("portal_war_droid_title")}
                            ${z("requires_power")}
                            `,reqs:{portal:5},cost:{Money:e=>Ps("war_droid",e,495e3,1.26,"portal"),Neutronium:e=>Ps("war_droid",e,1250,1.26,"portal"),Elerium:e=>Ps("war_droid",e,18,1.26,"portal"),Stanene:e=>Ps("war_droid",e,37500,1.26,"portal"),Soul_Gem:e=>Ps("war_droid",e,1,1.26,"portal")},powered:()=>As(2),effect(){return`
                            ${z("portal_war_droid_effect")}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("war_droid","portal"),Yr($(this)[0]),!0)},flair:z("portal_war_droid_flair")},repair_droid:{id:"portal-repair_droid",title:z("portal_repair_droid_title"),desc:()=>`
                            ${z("portal_repair_droid_title")}
                            ${z("requires_power")}
                            `,reqs:{portal:6},cost:{Money:e=>Ps("repair_droid",e,444e3,1.26,"portal"),Iron:e=>Ps("repair_droid",e,88e3,1.26,"portal"),Iridium:e=>Ps("repair_droid",e,17616,1.26,"portal"),Infernite:e=>Ps("repair_droid",e,666,1.26,"portal"),Soul_Gem:e=>Ps("repair_droid",e,1,1.15,"portal")},powered:()=>As(3),effect(){return`
                            ${z("portal_repair_droid_effect",[5])}
                            ${z("portal_repair_droid_effect2",[8])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("repair_droid","portal"),Yr($(this)[0]),!0)},flair:z("portal_repair_droid_flair")}},prtl_badlands:{info:{name:z("portal_badlands_name"),desc:z("portal_badlands_desc")},war_drone:{id:"portal-war_drone",title:z("portal_war_drone_title"),desc:()=>`
                            ${z("portal_war_drone_title")}
                            ${z("requires_power")}
                            `,reqs:{portal:3},powered:()=>As(5),cost:{Money:e=>Ps("war_drone",e,65e4,1.28,"portal"),Alloy:e=>Ps("war_drone",e,6e4,1.28,"portal"),Graphene:e=>Ps("war_drone",e,1e5,1.28,"portal"),Elerium:e=>Ps("war_drone",e,25,1.28,"portal"),Soul_Gem:e=>Ps("war_drone",e,1,1.28,"portal")},effect(){return`
                            ${z("portal_war_drone_effect")}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("war_drone","portal"),Yr($(this)[0]),!0)},flair:z("portal_war_drone_flair")},sensor_drone:{id:"portal-sensor_drone",title:z("portal_sensor_drone_title"),desc:()=>`
                            ${z("portal_sensor_drone_title")}
                            ${z("requires_power")}
                            `,reqs:{infernite:2},powered:()=>As(3),cost:{Money:e=>Ps("sensor_drone",e,5e5,1.25,"portal"),Polymer:e=>Ps("sensor_drone",e,25e3,1.25,"portal"),Adamantite:e=>Ps("sensor_drone",e,12500,1.25,"portal"),Infernite:e=>Ps("sensor_drone",e,100,1.25,"portal")},effect(){let e=t.tech.infernite>=4?t.tech.infernite>=6?50:20:10,a=t.tech.infernite>=6?2500:1e3,r=t.race.cataclysm?`
                            ${z("space_moon_observatory_cata_effect",[2])}
                            `:`
                            ${z("space_moon_observatory_effect",[2])}
                            ${z("portal_sensor_drone_effect2",[2])}
                            `,i=t.tech.science>=14?`
                            ${z("city_max_knowledge",[a])}
                            ${r}`:"";return`
                            ${z("portal_sensor_drone_effect",[e])}
                            ${i}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("sensor_drone","portal"),Yr($(this)[0]),!0)}},attractor:{id:"portal-attractor",title:z("portal_attractor_title"),desc:()=>`
                            ${z("portal_attractor_title")}
                            ${z("requires_power")}
                            `,reqs:{portal:4},powered:()=>As(3),cost:{Money:e=>Ps("attractor",e,35e4,1.25,"portal"),Aluminium:e=>Ps("attractor",e,175e3,1.25,"portal"),Stanene:e=>Ps("attractor",e,9e4,1.25,"portal")},effect(){return`
                            ${z("portal_attractor_effect1")}
                            ${z("portal_attractor_effect2",[t.resource.Soul_Gem.name])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("attractor","portal"),Yr($(this)[0]),!0)}}},prtl_pit:{info:{name:z("portal_pit_name"),desc:z("portal_pit_desc")},pit_mission:{id:"portal-pit_mission",title:z("portal_pit_mission_title"),desc:z("portal_pit_mission_title"),reqs:{hell_pit:1},grant:["hell_pit",2],queue_complete:()=>t.tech.hell_pit>=2?0:1,cost:{Money:()=>5e6,Helium_3:()=>3e5,Deuterium:()=>2e5},effect:z("portal_pit_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_pit_mission_result"),"info",!1,["progress","hell"]),!0)}},assault_forge:{id:"portal-assault_forge",title:z("portal_assault_forge_title"),desc:z("portal_assault_forge_title"),reqs:{hell_pit:2},grant:["hell_pit",3],queue_complete:()=>t.tech.hell_pit>=3?0:1,cost:{Money:()=>1e7,HellArmy:()=>Math.round(650/be(1,"hellArmy")),Cement:()=>1e7,Adamantite:()=>125e4,Elerium:()=>2400,Stanene:()=>9e5},effect:z("portal_assault_forge_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_assault_forge_result"),"info",!1,["progress","hell"]),!0)}},soul_forge:{id:"portal-soul_forge",title:z("portal_soul_forge_title"),desc:()=>`
                            ${z("portal_soul_forge_desc")}
                            ${z("requires_power")}
                            `,reqs:{hell_pit:4},queue_complete:()=>1-t.portal.soul_forge.count,powered:()=>As(30),postPower(e){Cs({el:"#fort"},"update")},cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?25e6:0,Graphene:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?15e5:0,Infernite:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?25e3:0,Bolognium:e=>(e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)<1?1e5:0},effect(e){let a=`
                            ${z("portal_soul_forge_effect",[t.resource.Soul_Gem.name])}
                            `;if((e||0)+(t.portal.hasOwnProperty("soul_forge")?t.portal.soul_forge.count:0)>=1){let e=t.tech.hell_pit>=6?75e4:1e6;t.tech.hell_pit>=7&&s.soul_attractor>0&&(e*=.97**s.soul_attractor),a+=`
                            ${z("portal_soul_forge_effect2",[t.portal.soul_forge?t.portal.soul_forge.kills.toLocaleString():0,Math.round(e).toLocaleString()])}
                            `}return`${a}
                            ${z("portal_soul_forge_soldiers",[da()])}, ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!(ri($(this)[0])&&t.portal.soul_forge.count<1)&&(Ft("soul_forge","portal"),Yr($(this)[0]),!0)}},gun_emplacement:{id:"portal-gun_emplacement",title:z("portal_gun_emplacement_title"),desc:()=>`
                            ${z("portal_gun_emplacement_title")}
                            ${z("requires_power")}
                            `,reqs:{hell_gun:1},powered:()=>As(3),cost:{Money:e=>Ps("gun_emplacement",e,4e6,1.25,"portal"),Coal:e=>Ps("gun_emplacement",e,25e4,1.25,"portal"),Steel:e=>Ps("gun_emplacement",e,12e5,1.25,"portal"),Wrought_Iron:e=>Ps("gun_emplacement",e,2e5,1.25,"portal")},effect(){let e=t.tech.hell_gun>=2?2:1,a=t.tech.hell_gun>=2?35:20,r=t.tech.hell_gun>=2?75:40;return`
                            ${z("portal_gun_emplacement_effect",[e])}
                            ${z("portal_gun_emplacement_effect2",[a,r])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("gun_emplacement","portal"),Yr($(this)[0]),!0)}},soul_attractor:{id:"portal-soul_attractor",title:z("portal_soul_attractor_title"),desc:()=>`
                            ${z("portal_soul_attractor_title")}
                            ${z("requires_power")}
                            `,reqs:{hell_pit:5},powered:()=>As(4),cost:{Money:e=>Ps("soul_attractor",e,12e6,1.25,"portal"),Stone:e=>Ps("soul_attractor",e,23e6,1.25,"portal"),Nano_Tube:e=>Ps("soul_attractor",e,314159,1.25,"portal"),Vitreloy:e=>Ps("soul_attractor",e,1618,1.25,"portal"),Aerogel:e=>Ps("soul_attractor",e,18e4,1.25,"portal")},effect(){let e=t.tech.hell_pit>=7?`
                            ${z("portal_soul_attractor_effect2",[3])}
                            `:"",a=t.blood.attract?5*t.blood.attract:0;return`
                            ${z("portal_soul_attractor_effect",[40+a,120+a])}
                            ${e}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("soul_attractor","portal"),Yr($(this)[0]),!0)}},soul_capacitor:{id:"portal-soul_capacitor",title:z("portal_soul_capacitor_title"),desc:()=>`
                            ${z("portal_soul_capacitor_desc")}
                            ${z("requires_power")}
                            `,reqs:{forbidden:2},powered:()=>As(125),queue_complete:()=>40-t.portal.soul_capacitor.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,75e7,1.01,"portal"),Crystal:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,125e4,1.01,"portal"),Adamantite:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,65e5,1.01,"portal"),Infernite:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,1e4,1.01,"portal"),Stanene:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,25e5,1.01,"portal"),Bolognium:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,1e6,1.01,"portal"),Soul_Gem:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,3,1.01,"portal"),Mythril:e=>(e||0)+(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.count:0)>=40?0:Ps("soul_capacitor",e,125e4,1.01,"portal")},effect(){let e=t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.ecap:0,a=`
                            ${z("portal_soul_capacitor_effect",[(t.portal.hasOwnProperty("soul_capacitor")?t.portal.soul_capacitor.energy:0).toLocaleString()])}
                            `;return a+=`
                            ${z("portal_soul_capacitor_effect2",[e.toLocaleString()])}
                            `,a+=`
                            ${z("portal_soul_capacitor_effect3",[25e5.toLocaleString()])}
                            `,a+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,a},action(){return!!(t.portal.soul_capacitor.count<40&&ri($(this)[0]))&&(t.portal.soul_capacitor.count++,Yr($(this)[0]),!0)},postPower(){ai($(this)[0],"portal","soul_capacitor")}},absorption_chamber:{id:"portal-absorption_chamber",title:z("portal_absorption_chamber_title"),desc:e=>!t.interstellar.hasOwnProperty("absorption_chamber")||t.portal.absorption_chamber.count<100||e?`
                            ${z("portal_absorption_chamber_title")}
                            ${z("requires_segmemts",[100])}
                            `:`
                            ${z("portal_absorption_chamber_title")}
                            `,reqs:{forbidden:3},queue_size:5,queue_complete:()=>100-t.portal.absorption_chamber.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e6:0,Alloy:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e4:0,Neutronium:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?125e3:0,Elerium:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?1e3:0,Orichalcum:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?25e4:0,Nanoweave:e=>(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0)<100?75e3:0},effect(e){let a=(e||0)+(t.portal.hasOwnProperty("absorption_chamber")?t.portal.absorption_chamber.count:0);if(a<100){let e=100-a;return`
                            ${z("portal_absorption_chamber_incomplete")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}if(5===t.tech.forbidden)return`
                            ${z("portal_absorption_chamber_effect_eld",[1e8.toLocaleString()])}
                            ${z("tech_demonic_infusion_effect2",[Gs("descend").artifact])}
                            `;{let e=qt();return`
                            ${z("portal_absorption_chamber_effect",[1e8.toLocaleString()])}
                            ${e}
                            `}},action(){if(ri($(this)[0])){if(t.portal.absorption_chamber.count<100)return Ft("absorption_chamber","portal"),t.portal.absorption_chamber.count>=100&&(t.tech.forbidden=4),!0;if(t.portal.soul_capacitor.energy>=1e8)return 5===t.tech.forbidden?R():Qt(),!0}return!1}}},prtl_ruins:{info:{name:z("portal_ruins_name"),desc:z("portal_ruins_desc"),support:"guard_post",prop(){let e=` - ${z("portal_ruins_security")}: {{ on | filter('army') }}`;return e+=` - ${z("portal_ruins_supressed")}: {{ on | filter('sup') }}`,e},filter(e,t){let a=ga("ruins");switch(t){case"army":return Math.round(a.rating);case"sup":return+(100*a.supress).toFixed(2)+"%"}}},ruins_mission:{id:"portal-ruins_mission",title:z("portal_ruins_mission_title"),desc:z("portal_ruins_mission_title"),reqs:{hell_ruins:1},grant:["hell_ruins",2],queue_complete:()=>t.tech.hell_ruins>=2?0:1,cost:{Money:()=>1e8,Oil:()=>5e5,Helium_3:()=>5e5},effect:z("portal_ruins_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_ruins_mission_result"),"info",!1,["progress","hell"]),t.portal.vault={count:0},t.portal.stonehedge={count:0},t.portal.archaeology={count:0,on:0},!0)}},guard_post:{id:"portal-guard_post",title:z("portal_guard_post_title"),desc:()=>`
                            ${z("portal_guard_post_title")}
                            ${z("requires_soldiers")}
                            ${z("requires_power")}
                            `,reqs:{hell_ruins:2},cost:{Money:e=>Ps("guard_post",e,8e6,1.06,"portal"),Lumber:e=>Ps("guard_post",e,65e5,1.06,"portal"),Sheet_Metal:e=>Ps("guard_post",e,3e5,1.06,"portal")},powered:()=>As(5),support:()=>1,effect(){let e=t.race.holy?1+Ei.holy.vars()[1]/100:1,a=ts("unicorn");return a>0&&(e*=1+Ei.holy.vars(1)[1]/100*a),`
                            ${z("portal_guard_post_effect1",[Math.round(e*be(ta(1),"hellArmy",0))])}
                            ${z("portal_guard_post_effect2",[ta(1),$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("guard_post","portal"),t.portal.guard_post.on++,!0)},postPower(){Cs({el:"#srprtl_ruins"},"update"),Cs({el:"#srprtl_gate"},"update")}},vault:{id:"portal-vault",title:z("portal_vault_title"),desc:z("portal_vault_title"),reqs:{hell_ruins:2,hell_vault:1},condition:()=>!(t.portal.vault.count>=2),queue_complete:()=>2-t.portal.vault.count,cost:{Soul_Gem:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===0?100:0,Money:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?25e7:0,Adamantite:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?125e5:0,Orichalcum:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)===1?3e7:0},effect:e=>(e||0)+(t.portal.hasOwnProperty("vault")?t.portal.vault.count:0)<1?z("portal_vault_effect",[100]):z("portal_vault_effect2"),action(){return!!(t.portal.vault.count<2&&ri($(this)[0]))&&(Ft("vault","portal"),2===t.portal.vault.count&&(t.tech.hell_ruins=3,t.resource.Codex.display=!0,t.resource.Codex.amount=1,hs(z("portal_vault_result"),"info",!1,["progress","hell"])),!0)},post(){2===t.portal.vault.count&&(Qr(),ua(),_s())}},archaeology:{id:"portal-archaeology",title:z("portal_archaeology_title"),desc:()=>`
                            ${z("portal_archaeology_title")}
                            ${z("requires_security")}
                            ${z("requires_power")}
                            `,reqs:{hell_ruins:2},cost:{Money:e=>Ps("archaeology",e,1e8,1.25,"portal"),Titanium:e=>Ps("archaeology",e,375e4,1.25,"portal"),Mythril:e=>Ps("archaeology",e,125e4,1.25,"portal")},powered:()=>As(8),effect(){return`
                            ${z("portal_archaeology_effect",[ta(2)])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){if(ri($(this)[0])){if(Ft("archaeology","portal"),t.civic.archaeologist.display=!0,Yr($(this)[0])&&t.civic[t.civic.d_job].workers>0){let e=t.civic[t.civic.d_job].workers-ta(2)<0?t.civic[t.civic.d_job].workers:ta(2);t.civic[t.civic.d_job].workers-=e,t.civic.archaeologist.workers+=e}return!0}return!1}},arcology:{id:"portal-arcology",title:z("portal_arcology_title"),desc:()=>`
                            ${z("portal_arcology_title")}
                            ${z("requires_security")}
                            ${z("requires_power")}
                            `,reqs:{housing:4},cost:{Money:e=>Ps("arcology",e,18e7,1.22,"portal"),Graphene:e=>Ps("arcology",e,75e5,1.22,"portal"),Bolognium:e=>Ps("arcology",e,28e5,1.22,"portal"),Orichalcum:e=>Ps("arcology",e,55e5,1.22,"portal"),Nanoweave:e=>Ps("arcology",e,65e4,1.22,"portal"),Horseshoe:()=>t.race.hooved?13:0},powered:()=>As(25),effect(){let e=ga("ruins"),t=br(8*bi()*e.supress);t=+t.toFixed(0);let a=10*Math.round(_),r=`
                            ${z("plus_max_resource",[a,z("resource_Crates_name")])}
                            ${z("plus_max_resource",[a,z("resource_Containers_name")])}
                            `;return`
                            ${z("plus_max_resource",[`$${t.toLocaleString()}`,z("resource_Money_name")])}
                            ${z("plus_max_citizens",[$(this)[0].citizens()])}
                            ${z("plus_max_resource",[ta(5),z("civics_garrison_soldiers")])}
                            ${z("portal_guard_post_effect1",[75])}
                            ${r}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("arcology","portal"),Yr($(this)[0])&&(t.resource[t.race.species].max+=8),!0)},post(){Cs({el:"#srprtl_ruins"},"update"),Qr()},postPower(){Cs({el:"#srprtl_ruins"},"update"),Cs({el:"#srprtl_gate"},"update")},citizens(){let e=8;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},hell_forge:{id:"portal-hell_forge",title:z("portal_hell_forge_title"),desc:()=>`
                            ${z("portal_hell_forge_title")}
                            ${z("requires_security")}
                            ${z("requires_power")}
                            `,reqs:{scarletite:1},cost:{Money:e=>Ps("hell_forge",e,25e7,1.15,"portal"),Coal:e=>Ps("hell_forge",e,165e4,1.22,"portal"),Steel:e=>Ps("hell_forge",e,38e5,1.22,"portal"),Iridium:e=>Ps("hell_forge",e,12e5,1.22,"portal"),Neutronium:e=>Ps("hell_forge",e,28e4,1.22,"portal"),Soul_Gem:e=>Ps("hell_forge",e,5,1.22,"portal")},powered:()=>As(12),special:!0,effect(){let e=+(75*ga("ruins").supress).toFixed(1),a=t.tech.inferno_power?`
                            ${z("portal_hell_forge_effect2",[10,z("portal_inferno_power_title")])}
                            `:"";return`
                            ${z("portal_hell_forge_effect",[ta(1)])}
                            ${a}
                            ${z("interstellar_stellar_forge_effect3",[3])}
                            ${z("interstellar_stellar_forge_effect",[e])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("hell_forge","portal"),Yr($(this)[0])&&(t.city.smelter.cap+=3,t.city.smelter.Oil+=3,t.city.smelter.Iron+=3),!0)},post(){sa()},postPower(e){if(!e&&t.portal.hell_forge.on`
                            ${z("portal_inferno_power_title")}
                            `,reqs:{inferno_power:1},cost:{Money:e=>Ps("inferno_power",e,275e6,1.16,"portal"),Neutronium:e=>Ps("inferno_power",e,375e4,1.18,"portal"),Stanene:e=>Ps("inferno_power",e,12e6,1.18,"portal"),Bolognium:e=>Ps("inferno_power",e,8e6,1.18,"portal")},powered(){let e=20;return s.hasOwnProperty("hell_forge")&&(e+=10*s.hell_forge),Fs(-e)},fuel:{Infernite:5,Coal:100,Oil:80},effect(){let e=$(this)[0].fuel;return`
                            ${z("space_dwarf_reactor_effect1",[-$(this)[0].powered()])}
                            ${z("portal_inferno_power_effect",[e.Infernite,t.resource.Infernite.name,e.Coal,t.resource.Coal.name,e.Oil,t.resource.Oil.name])}
                            `},action(){return!!ri($(this)[0])&&(Ft("inferno_power","portal"),t.portal.inferno_power.on++,!0)},post(){Cs({el:"#foundry"},"update")}},ancient_pillars:{id:"portal-ancient_pillars",title:z("portal_ancient_pillars_title"),desc:z("portal_ancient_pillars_desc"),reqs:{hell_ruins:2},queue_complete:()=>t.tech.pillars&&1===t.tech.pillars&&"micro"!==t.race.universe?1:0,cost:{Harmony:e=>void 0!==e?e+Object.keys(t.pillars).lengthObject.keys(Ki).length-1,on:()=>Object.keys(t.pillars).length,effect(e){let a=(e||0)+Object.keys(t.pillars).length;return a>=1?`
                            ${z("portal_ancient_pillars_effect2",[Object.keys(Ki).length-1,a])}
                            `:`
                            ${z("portal_ancient_pillars_effect",[Object.keys(Ki).length-1])}
                            `},action(){return!(!t.tech.pillars||1!==t.tech.pillars||"micro"===t.race.universe||!ri($(this)[0])||(t.pillars[t.race.species]=Mn(),t.tech.pillars=2,br(0,!1,!0),Ks(!0),oa(!0),qn("resonance"),Cs({el:"#portal-ancient_pillars"},"update"),0))}}},prtl_gate:{info:{name:z("portal_gate_name"),desc:()=>`${z("portal_gate_desc")} ${z(t.tech.wtower&&t.tech.etower?"portal_gate_open":"portal_gate_closed")}`,support:"guard_post",hide_support:!0,prop(){let e=` - ${z("portal_ruins_security")}: {{ on | filter('army') }}`;return e+=` - ${z("portal_ruins_supressed")}: {{ on | filter('sup') }}`,e},filter(e,t){let a=ga("gate");switch(t){case"army":return Math.round(a.rating);case"sup":return+(100*a.supress).toFixed(2)+"%"}}},gate_mission:{id:"portal-gate_mission",title:z("portal_gate_mission_title"),desc:z("portal_gate_mission_title"),reqs:{high_tech:18},grant:["hell_gate",1],queue_complete:()=>t.tech.hell_gate>=1?0:1,cost:{Money:()=>25e7,Knowledge:()=>275e5},effect:z("portal_gate_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_gate_mission_result"),"info",!1,["progress","hell"]),!0)}},west_tower:{id:"portal-west_tower",title:z("portal_west_tower"),desc(e){let a=oa();return!t.portal.hasOwnProperty("west_tower")||t.portal.west_tower.count${z("portal_west_tower")}
                            ${z("requires_segmemts",[a])}
                            `:`
                            ${z("portal_west_tower")}
                            `},reqs:{hell_gate:2},queue_size:25,queue_complete:()=>oa()-t.portal.west_tower.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)(e||0)+(t.portal.hasOwnProperty("west_tower")?t.portal.west_tower.count:0)${z("portal_tower_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            ${z("portal_tower_effect2")}
                            `}return z("portal_tower_effect")},action(){return!!(t.portal.west_tower.count=oa()&&(t.tech.wtower=1,t.tech.wtower&&t.tech.etower&&!t.tech.hell_lake&&(t.tech.hell_lake=1,t.settings.portal.lake=!0,t.portal.harbour={count:0,on:0,support:0,s_max:0},hs(z("portal_gate_open"),"info",!1,["progress","hell"]),ua()))}},east_tower:{id:"portal-east_tower",title:z("portal_east_tower"),desc(e){let a=oa();return!t.portal.hasOwnProperty("east_tower")||t.portal.east_tower.count${z("portal_east_tower")}
                            ${z("requires_segmemts",[a])}
                            `:`
                            ${z("portal_east_tower")}
                            `},reqs:{hell_gate:2},queue_size:25,queue_complete:()=>oa()-t.portal.east_tower.count,cost:{Money:e=>(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)(e||0)+(t.portal.hasOwnProperty("east_tower")?t.portal.east_tower.count:0)${z("portal_tower_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            ${z("portal_tower_effect2")}
                            `}return z("portal_tower_effect")},action(){return!!(t.portal.east_tower.count=oa()&&(t.tech.etower=1,t.tech.wtower&&t.tech.etower&&!t.tech.hell_lake&&(t.tech.hell_lake=1,t.settings.portal.lake=!0,t.portal.harbour={count:0,on:0,support:0,s_max:0},hs(z("portal_gate_open"),"info",!1,["progress","hell"]),ua()))}},gate_turret:{id:"portal-gate_turret",title:z("portal_gate_turret_title"),desc:()=>`
                            ${z("portal_gate_turret_title")}
                            ${z("requires_power")}
                            `,reqs:{hell_gate:3},powered:()=>As(6),cost:{Money:e=>Ps("gate_turret",e,375e4,1.22,"portal"),Iron:e=>Ps("gate_turret",e,425e4,1.22,"portal"),Elerium:e=>Ps("gate_turret",e,275,1.22,"portal"),Stanene:e=>Ps("gate_turret",e,85e4,1.22,"portal")},effect(){let e=100;t.race.holy&&(e*=1+Ei.holy.vars()[1]/100);let a=ts("unicorn");a>0&&(e*=1+Ei.holy.vars(1)[1]/100*a);let r=t.tech.hell_gun>=2?65:40,i=t.tech.hell_gun>=2?100:60;return`
                            ${z("portal_gate_turret_effect",[Math.round(e)])}
                            ${z("portal_gate_turret_effect2",[r,i])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("gate_turret","portal"),Yr($(this)[0]),!0)},postPower(){Cs({el:"#srprtl_gate"},"update")}},infernite_mine:{id:"portal-infernite_mine",title:z("portal_infernite_mine_title"),desc:()=>`
                            ${z("portal_infernite_mine_title")}
                            ${z("requires_security")}
                            ${z("requires_power")}
                            `,reqs:{hell_gate:4},powered:()=>As(5),powerBalancer:()=>[{r:"Infernite",k:"lpmod"}],cost:{Money:e=>Ps("infernite_mine",e,75e6,1.26,"portal"),Alloy:e=>Ps("infernite_mine",e,245e4,1.26,"portal"),Orichalcum:e=>Ps("infernite_mine",e,165e4,1.26,"portal"),Wrought_Iron:e=>Ps("infernite_mine",e,68e4,1.26,"portal")},effect(){return`
                            ${z("portal_infernite_mine_effect",[+$e("infernite_mine").toFixed(3)])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("infernite_mine","portal"),Yr($(this)[0]),!0)}}},prtl_lake:{info:{name:z("portal_lake_name"),desc:z("portal_lake_desc"),support:"harbour"},lake_mission:{id:"portal-lake_mission",title:z("portal_lake_mission_title"),desc:z("portal_lake_mission_title"),reqs:{hell_lake:1},grant:["hell_lake",2],queue_complete:()=>t.tech.hell_lake>=2?0:1,cost:{Money:()=>5e8,Oil:()=>75e4,Helium_3:()=>6e5},effect:z("portal_lake_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_lake_mission_result"),"info",!1,["progress","hell"]),!0)}},harbour:{id:"portal-harbour",title:z("portal_harbour_title"),desc:()=>`
                            ${z("portal_harbour_title")}
                            ${z("requires_power")}
                            `,reqs:{hell_lake:3},powered:()=>+As(500*.92**(s.cooling_tower||0)).toFixed(2),support:()=>1,cost:{Money:e=>Ps("harbour",e,225e6,ca(1.18),"portal"),Cement:e=>Ps("harbour",e,5e7,ca(1.18),"portal"),Iridium:e=>Ps("harbour",e,75e5,ca(1.18),"portal"),Infernite:e=>Ps("harbour",e,8e5,ca(1.18),"portal"),Stanene:e=>Ps("harbour",e,175e5,ca(1.18),"portal")},wide:!0,res:()=>["Oil","Alloy","Polymer","Iridium","Helium_3","Deuterium","Neutronium","Adamantite","Infernite","Nano_Tube","Graphene","Stanene","Bolognium","Orichalcum"],val(e){switch(e){case"Oil":return 3e4;case"Alloy":case"Polymer":return 25e4;case"Iridium":return 2e5;case"Helium_3":return 18e3;case"Deuterium":return 12e3;case"Neutronium":return 18e4;case"Adamantite":return 15e4;case"Infernite":return 75e3;case"Nano_Tube":return 75e4;case"Graphene":case"Stanene":return 12e5;case"Bolognium":case"Orichalcum":return 13e4;default:return 0}},effect(){let e='
                            ';for(const a of $(this)[0].res())t.resource[a].display&&(e+=`${z("plus_max_resource",[x(+br($(this)[0].val(a)).toFixed(0),1),t.resource[a].name])}`);return e+="
                            ",`
                            ${z("portal_harbour_effect",[1])}
                            ${e}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){if(ri($(this)[0])){if(Ft("harbour","portal"),Yr($(this)[0]))for(const e of $(this)[0].res())t.resource[e].display&&(t.resource[e].max+=br($(this)[0].val(e)));return!0}return!1}},cooling_tower:{id:"portal-cooling_tower",title:z("portal_cooling_tower_title"),desc:()=>`
                            ${z("portal_cooling_tower_title")}
                            ${z("requires_power")}
                            `,reqs:{hell_lake:6},powered:()=>As(10),cost:{Money:e=>Ps("cooling_tower",e,25e7,1.2,"portal"),Polymer:e=>Ps("cooling_tower",e,12e6,1.2,"portal"),Orichalcum:e=>Ps("cooling_tower",e,85e5,1.2,"portal"),Brick:e=>Ps("cooling_tower",e,25e4,1.2,"portal")},effect(){return`
                            ${z("portal_cooling_tower_effect",[8])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("cooling_tower","portal"),Yr($(this)[0]),!0)}},bireme:{id:"portal-bireme",title:z("portal_bireme_title"),desc:()=>`
                            ${z("portal_bireme_title")}
                            ${z("space_support",[z("lake")])}
                            `,reqs:{hell_lake:4},powered:()=>As(1),support:()=>-1,cost:{Money:e=>Ps("bireme",e,19e7,1.24,"portal"),Helium_3:e=>Ps("bireme",e,225e3,1.24,"portal"),Adamantite:e=>Ps("bireme",e,15e6,1.24,"portal"),Nano_Tube:e=>Ps("bireme",e,18e6,1.24,"portal"),Soul_Gem:e=>Ps("bireme",e,10,1.24,"portal"),Scarletite:e=>Ps("bireme",e,125e3,1.24,"portal")},effect(){let e=t.blood.spire&&t.blood.spire>=2?20:15;return`
                            ${z("space_used_support",[z("lake")])}
                            ${z("portal_bireme_effect",[e])}
                            ${z("galaxy_starbase_mil_crew",[$(this)[0].ship.mil()])}
                            `},ship:{civ:()=>0,mil:()=>t.race.high_pop?2*Ei.high_pop.vars()[0]:2},action(){return!!ri($(this)[0])&&(Ft("bireme","portal"),t.portal.harbour.support`
                            ${z("portal_transport_title")}
                            ${z("space_support",[z("lake")])}
                            `,reqs:{hell_lake:5},powered:()=>As(1),support:()=>-1,cost:{Money:e=>Ps("transport",e,3e8,1.22,"portal"),Oil:e=>Ps("transport",e,18e4,1.22,"portal"),Alloy:e=>Ps("transport",e,18e6,1.22,"portal"),Graphene:e=>Ps("transport",e,125e5,1.22,"portal"),Soul_Gem:e=>Ps("transport",e,5,1.22,"portal"),Scarletite:e=>Ps("transport",e,25e4,1.22,"portal")},effect(){let e=+((t.blood.spire&&t.blood.spire>=2?.8:.85)**(o.bireme||0)*100).toFixed(1);return`
                            ${z("space_used_support",[z("lake")])}
                            ${z("portal_transport_effect",[5])}
                            ${z("portal_transport_effect2",[e])}
                            ${z("galaxy_starbase_civ_crew",[$(this)[0].ship.civ()])}
                            `},special:!0,sAction(){t.settings.civTabs=4,t.settings.marketTabs=3,t.settings.tabLoad||(kt("mTabResource"),_s("portal-transport"))},ship:{civ:()=>t.race.high_pop?3*Ei.high_pop.vars()[0]:3,mil:()=>0},action(){return!!ri($(this)[0])&&(Ft("transport","portal"),t.portal.harbour.support` - ${z("portal_spire_supply")}: {{ supply | filter }} / {{ sup_max }} (+{{ diff | filter(2) }}/s)`,filter:(e,t)=>t?+e.toFixed(t):Math.floor(e)},spire_mission:{id:"portal-spire_mission",title:z("portal_spire_mission_title"),desc:z("portal_spire_mission_title"),reqs:{hell_spire:1},grant:["hell_spire",2],queue_complete:()=>t.tech.hell_spire>=2?0:1,cost:{Species:()=>Rs(50),Oil:()=>9e5,Helium_3:()=>75e4,Structs:()=>({portal:{bireme:{s:"prtl_lake",count:1,on:1},transport:{s:"prtl_lake",count:1,on:1}}})},effect:z("portal_spire_mission_effect"),action(){return!!ri($(this)[0])&&(hs(z("portal_spire_mission_result"),"info",!1,["progress","hell"]),!0)},flair:z("portal_spire_mission_flair")},purifier:{id:"portal-purifier",title:z("portal_purifier_title"),desc:()=>`
                            ${z("portal_purifier_desc")}
                            ${z("requires_power")}
                            `,reqs:{hell_spire:3},cost:{Money:e=>Ps("purifier",e,85e6,ca(1.15),"portal"),Supply:e=>t.portal.purifier&&0===t.portal.purifier.count?100:Ps("purifier",e,4200,ca(1.2),"portal")},powered:()=>As(125),support:()=>t.tech.b_stone&&t.tech.b_stone>=3?1.25:1,effect(){return`
                            ${z("portal_purifier_effect",[$(this)[0].support()])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(Ft("purifier","portal"),Yr($(this)[0]),!0)}},port:{id:"portal-port",title:z("portal_port_title"),desc:()=>`
                            ${z("portal_port_title")}
                            ${z("portal_spire_support")}
                            `,reqs:{hell_spire:3},cost:{Money:e=>Ps("port",e,135e6,ca(1.2),"portal"),Supply:e=>t.portal.hasOwnProperty("port")&&0===t.portal.port.count?100:Ps("port",e,6250,ca(1.2),"portal")},powered:()=>As(1),support:()=>-1,effect(){let e=1e4;return l.base_camp&&(e*=1+.4*l.base_camp),`
                            ${z("portal_port_effect1",[$(this)[0].support()])}
                            ${z("portal_port_effect2",[Math.round(e)])}
                            `},action(){return!!ri($(this)[0])&&(Ft("port","portal"),t.portal.purifier.support`
                            ${z("portal_base_camp_title")}
                            ${z("portal_spire_support")}
                            `,reqs:{hell_spire:4},cost:{Money:e=>Ps("base_camp",e,425e6,ca(1.2),"portal"),Supply:e=>Ps("base_camp",e,5e4,ca(1.2),"portal")},powered:()=>As(1),support:()=>-1,effect(){return`
                            ${z("portal_port_effect1",[$(this)[0].support()])}
                            ${z("portal_base_camp_effect",[40])}
                            `},action(){return!!ri($(this)[0])&&(Ft("base_camp","portal"),t.portal.purifier.support!t.portal.hasOwnProperty("bridge")||t.portal.bridge.count<10||e?`
                            ${z("portal_bridge_title")}
                            ${z("requires_segmemts",[10])}
                            `:`
                            ${z("portal_bridge_title")}
                            `,reqs:{hell_spire:5},queue_size:1,queue_complete:()=>10-t.portal.bridge.count,cost:{Species:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?Rs(10):0,Money:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?5e8:0,Supply:e=>(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0)<10?1e5:0},effect(e){let a=(e||0)+(t.portal.hasOwnProperty("bridge")?t.portal.bridge.count:0);if(a<10){let e=10-a;return`
                            ${z("portal_bridge_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            ${z("portal_bridge_effect2")}
                            `}return z("portal_bridge_complete")},action(){return!!(t.portal.bridge.count<10&&ri($(this)[0]))&&(Ft("bridge","portal"),t.portal.bridge.count>=10&&(t.portal.sphinx={count:0},t.tech.hell_spire=6,ua()),!0)}},sphinx:{id:"portal-sphinx",title:()=>7===t.tech.hell_spire?z("portal_sphinx_solve"):z("portal_sphinx_title"),desc:z("portal_sphinx_desc"),reqs:{hell_spire:6},queue_complete:()=>8-t.tech.hell_spire,cost:{Knowledge(e){let a=(e||0)+(!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2);return 1===a?5e7:0===a?4e7:0}},effect(e){let a=(e||0)+(!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2);return z(1===a?"portal_sphinx_effect2":2===a?"portal_sphinx_effect3":"portal_sphinx_effect")},action(){if(ri($(this)[0])){if(6===t.tech.hell_spire)return t.tech.hell_spire=7,hs(z("portal_sphinx_msg"),"info",!1,["progress","hell"]),ua(),!0;if(7===t.tech.hell_spire)return t.tech.hell_spire=8,ua(),hs(z("portal_sphinx_answer_msg"),"info",!1,["progress","hell"]),!0}return!1}},bribe_sphinx:{id:"portal-bribe_sphinx",title:z("portal_sphinx_bribe"),desc:z("portal_sphinx_desc"),reqs:{hell_spire:7},condition:()=>!(!t.tech.hell_spire||7!==t.tech.hell_spire||t.tech.sphinx_bribe),cost:{Soul_Gem:()=>250,Supply:()=>5e5},effect:()=>z("portal_sphinx_bribe_effect"),action(){return!(!ri($(this)[0])||7!==t.tech.hell_spire||t.tech.sphinx_bribe||(t.tech.sphinx_bribe=1,t.resource.Codex.display=!0,t.resource.Codex.amount=1,hs(z("portal_sphinx_bribe_msg"),"info",!1,["progress","hell"]),0))},post(){t.tech.sphinx_bribe&&(Qr(),ua(),_s("portal-bribe_sphinx"))}},spire_survey:{id:"portal-spire_survey",title:z("portal_spire_survey_title"),desc:z("portal_spire_survey_title"),reqs:{hell_spire:8},grant:["hell_spire",9],queue_complete:()=>t.tech.hell_spire>=9?0:1,cost:{Oil:()=>12e5,Helium_3:()=>9e5},effect:z("portal_spire_survey_effect"),action(){return!!ri($(this)[0])&&(t.portal.mechbay={count:0,on:0,bay:0,max:0,active:0,scouts:0,mechs:[]},t.portal.spire={count:1,progress:0,boss:"",type:"",status:{}},function(){let e=["sand","swamp","forest","jungle","rocky","gravel","muddy","grass","brush","concrete"];if(t.portal.spire.type=e[Math.floor(m(0,e.length))],t.portal.spire.count>=10){t.portal.spire.status={};let e=["freeze","hot","corrosive","humid","windy","hilly","mountain","radioactive","quake","dust","river","tar","steam","flooded","fog","rain","hail","chasm","dark","gravity"];if($a(e[Math.floor(m(0,e.length))]),t.portal.spire.count>=25&&t.portal.spire.count<=100){let a=105-t.portal.spire.count;Math.floor(m(0,a)<=5)&&$a(e[Math.floor(m(0,e.length))])}else if(t.portal.spire.count>100&&t.portal.spire.count<=250){$a(e[Math.floor(m(0,e.length))]);let a=260-t.portal.spire.count;Math.floor(m(0,a)<=10)&&$a(e[Math.floor(m(0,e.length))])}else if(t.portal.spire.count>250&&t.portal.spire.count<=1e3){$a(e[Math.floor(m(0,e.length))]),$a(e[Math.floor(m(0,e.length))]);let a=1025-t.portal.spire.count;Math.floor(m(0,a)<=25)&&$a(e[Math.floor(m(0,e.length))])}else t.portal.spire.count>1e3&&($a(e[Math.floor(m(0,e.length))]),$a(e[Math.floor(m(0,e.length))]),$a(e[Math.floor(m(0,e.length))]))}let a=Object.keys(va).filter((function(e){let a=Object.keys(va[e].nozone);return!a.some((e=>Object.keys(t.portal.spire.status).includes(e)))&&!a.includes(t.portal.spire.type)}));t.portal.spire.boss=a[Math.floor(m(0,a.length))]}(),hs(z("portal_spire_survey_msg"),"info",!1,["progress","hell"]),!0)},post(){t.tech.hell_spire&&9===t.tech.hell_spire&&(ua(),_s("portal-spire_survey"))}},mechbay:{id:"portal-mechbay",title:z("portal_mechbay_title"),desc:()=>`
                            ${z("portal_mechbay_title")}
                            ${z("portal_spire_support")}
                            `,reqs:{hell_spire:9},cost:{Money:e=>Ps("mechbay",e,1e8,1.2,"portal"),Supply:e=>Ps("mechbay",e,25e4,1.2,"portal")},powered:()=>As(1),support:()=>-1,special:!0,sAction(){t.settings.civTabs=2,t.settings.govTabs=4,t.settings.tabLoad||(kt("mTabCivic"),_s("portal-mechbay"))},effect(){let e=t.portal.hasOwnProperty("mechbay")?t.portal.mechbay.bay:0,a=t.portal.hasOwnProperty("mechbay")?t.portal.mechbay.max:0;return`
                            ${z("portal_port_effect1",[$(this)[0].support()])}
                            ${z("portal_mechbay_effect")}
                            ${z("portal_mechbay_effect2",[e,a])}
                            `},action(){return!!ri($(this)[0])&&(Ft("mechbay","portal"),t.portal.purifier.support0,cost:{},effect(){let e=t.portal.hasOwnProperty("spire")?t.portal.spire.count:0,a=t.portal.hasOwnProperty("spire")?`${z(`portal_spire_type_${t.portal.spire.type}`)}`:"?",r="";t.portal.hasOwnProperty("spire")&&Object.keys(t.portal.spire.status).length>0&&(r=`
                            ${z("portal_spire_hazard",[Object.keys(t.portal.spire.status).map((e=>`${z(`portal_spire_status_${e}`)}`)).join(", ")])}
                            `);let i=t.portal.hasOwnProperty("spire")?`${+t.portal.spire.progress.toFixed(3)}%`:"0%",s=`
                            ${z("portal_spire_effect",[e])}
                            ${z("portal_spire_type",[a])}
                            ${r}
                            ${z("portal_spire_progress",[i])}
                            `,n=t.portal.hasOwnProperty("spire")?t.portal.spire.boss:"crazed",c=`
                            ${z("portal_spire_mob",[`${z(`portal_mech_boss_${n}`)}`])}
                            `,o="???",l="???";if(t.stats.spire){let e=function(e){let t="laser",a="laser";return Object.keys(va[e].weapon).forEach((function(r){va[e].weapon[r]>va[e].weapon[t]&&(t=r),va[e].weapon[r]0&&(o=z(`portal_mech_weapon_${e.w}`)),t>=5&&(l=z(`portal_mech_weapon_${e.r}`))}return`
                            ${s}
                            ${c}
                            ${z("portal_spire_mob_weak",[`${o}`])}
                            ${z("portal_spire_mob_resist",[`${l}`])}
                            `},mscan(){let e=0;return Object.keys(t.stats.spire).forEach((function(a){let r=t.portal.hasOwnProperty("spire")?t.portal.spire.boss:"crazed";t.stats.spire.hasOwnProperty(a)&&t.stats.spire[a].hasOwnProperty(r)&&t.stats.spire[a][r]>e&&(e=t.stats.spire[a][r])})),e},wide:!0,action:()=>!1},waygate:{id:"portal-waygate",title:z("portal_waygate_title"),desc:e=>!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2||e?`
                            ${z("portal_waygate_title")}
                            ${z("requires_segmemts",[10])}
                            `:`
                            ${z("portal_waygate_title")}
                            `,reqs:{waygate:1},queue_size:1,queue_complete:()=>t.tech.waygate>=2?0:10-t.portal.waygate.count,cost:{Species:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?Rs(25):0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?Rs(25):0,Money:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?1e9:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?1e9:0,Supply:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?5e5:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?5e5:0,Blood_Stone:e=>e?e+(t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0)<10?5:0:!t.portal.hasOwnProperty("waygate")||t.tech.waygate&&t.tech.waygate<2?5:0},powered:()=>t.portal.hasOwnProperty("waygate")&&t.portal.waygate.count>=10?1:0,power_reqs:{waygate:2},effect(e){let a=(e||0)+(t.tech.waygate&&t.tech.waygate>=2?10:t.portal.hasOwnProperty("waygate")?t.portal.waygate.count:0);if(a>=10){let e=t.portal.hasOwnProperty("waygate")?`${+t.portal.waygate.progress.toFixed(3)}%`:"0%";return`
                            ${z("portal_waygate_open")}
                            ${z("portal_waygate_progress",[e])}
                            `}{let e=10-a;return`
                            ${z("portal_waygate_effect")}
                            ${z("space_dwarf_collider_effect2",[e])}
                            `}},action(){return!!(t.portal.waygate.count<10&&t.tech.waygate&&1===t.tech.waygate&&ri($(this)[0]))&&(Ft("waygate","portal"),t.portal.waygate.count>=10&&(t.tech.waygate=2,t.portal.waygate.count=1,ua()),!0)}}}};function ca(e){let a=t.portal.hasOwnProperty("spire")&&t.blood.spire?e-(t.portal.spire.count-1)/2500:e;return a>=1.01?a:1.01}const oa=function(e){return la&&!e||(la=1e3,t.hasOwnProperty("pillars")&&Object.keys(t.pillars).forEach((function(e){t.pillars[e]&&(la-=12)}))),la};var la;function _a(e){let t=ga("gate");return Math.round(e/(t.supress>.01?t.supress:.01))}function da(){let e=Math.round(650/be(1,"hellArmy"));return s.gun_emplacement&&(e-=s.gun_emplacement*(t.tech.hell_gun>=2?2:1),e<0&&(e=0)),e}function pa(){return na}function ua(){if(!t.settings.tabLoad&&(1!==t.settings.civTabs||4!==t.settings.spaceTabs))return;let e=$("#portal");Ss(e),e.append($(`

                            ${z("tab_portal")}

                            `)),!t.tech.portal||t.tech.portal<2||Object.keys(na).forEach((function(a){let r=a.replace("prtl_","");if(t.settings.portal[`${r}`]){let r="string"==typeof na[a].info.name?na[a].info.name:na[a].info.name(),i="";if(na[a].info.hasOwnProperty("prop")&&(i=na[a].info.prop()),na[a].info.support){let s=na[a].info.support;na[a].info.hide_support?e.append(`

                            ${r}

                            ${i}
                            `):e.append(`

                            ${r}

                            {{ support }}/{{ s_max }}${i}
                            `),Cs({el:`#sr${a}`,data:t.portal[s],filters:{filter(){return na[a].info.filter(...arguments)}}})}else e.append(`

                            ${r}

                            ${i}
                            `);ls(a,(function(){return"string"==typeof na[a].info.desc?na[a].info.desc:na[a].info.desc()}),{elm:`#${a} h3.name`,classes:"has-background-light has-text-dark"}),"prtl_fortress"===a&&ma(e,!0),Object.keys(na[a]).forEach((function(e){"info"!==e&&Tt(na,a,e)&&Zr(na[a][e],"portal",e)}))}}))}function ha(e){switch(e){case"hostiles":return t.portal.fortress.threat>=2e3?`${z("fortress_threat",[t.portal.fortress.threat])} ${z("fortress_threat_high")}`:t.portal.fortress.threat<1e3?`${z("fortress_threat",[t.portal.fortress.threat])} ${z("fortress_threat_low")}`:`${z("fortress_threat",[t.portal.fortress.threat])} ${z("fortress_threat_medium")}`;case"threatLevel":{let e=t.portal.fortress.threat;return e<1e3?`${z("fortress_threat_level")} ${z("fortress_threat_level1")}`:e<1500?`${z("fortress_threat_level")} ${z("fortress_threat_level2")}`:e>=5e3?`${z("fortress_threat_level")} ${z("fortress_threat_level6")}`:e>=3e3?`${z("fortress_threat_level")} ${z("fortress_threat_level5")}`:e>=2e3?`${z("fortress_threat_level")} ${z("fortress_threat_level4")}`:`${z("fortress_threat_level")} ${z("fortress_threat_level3")}`}case"hireLabel":return z("civics_garrison_hire_mercenary_cost",[Math.round(de("m_cost")).toLocaleString()])}}function ma(e,a){if(!t.settings.tabLoad)switch(t.settings.civTabs){case 1:if(4!==t.settings.spaceTabs)return;break;case 2:if(3!==t.settings.govTabs)return;break;default:return}if(!t.tech.portal||t.tech.portal<2)return;let r=a?"fort":"gFort",i=a?$(`
                            `):$("#gFort");a?e.append(i):(i.length>0?Ss(i):(i=$(`
                            `),e.append(i)),i.append(`

                            ${z("portal_fortress_name")}

                            `));let n=$("
                            ");i.append(n);let c=$(`${z("fortress_defense")} {{ f.garrison | defensive }}`);n.append(c);let o=$(`${z("fortress_spotted")} {{ f.threat }}`);n.append(o);let l=$('{{ f.threat | threat }}');n.append(l);let _=$("
                            ");i.append(_),_.append($(`${z("fortress_wall")} {{ Math.ceil(f.walls) }}%`));let d=$("
                            ");i.append(d),d.append($(`${z("fortress_army")}`)),d.append($('«')),d.append($('{{ f.garrison | patrolling }}')),d.append($('»')),d.append($(`${z("fortress_patrol")}`)),d.append($('«')),d.append($('{{ f.patrols }}')),d.append($('»')),d.append($(`${z("fortress_patrol_size")}`)),d.append($('«')),d.append($('{{ f.patrol_size }}')),d.append($('»')),d.append($(``));let p="light"===t.settings.theme?' type="is-light"':' type="is-dark"',u=$("
                            ");d.append(u),u.append($(`${z("fortress_patrol_reports")}`)),u.append($(`${z("fortress_surv_reports")}`)),u.append($(`${z("fortress_nocrew")}`)),a&&i.append($(`
                            ${z("civics_garrison_training")} - ${z("arpa_to_complete")} {{ g.rate, g.progress | trainTime }} {{ g.progress }}%
                            `)),Cs({el:`#${r}`,data:{f:t.portal.fortress,g:t.civic.garrison,s:t.settings},methods:{defense:()=>z("fortress_defense"),hostiles:()=>ha("hostiles"),threatLevel:()=>ha("threatLevel"),aNext(){let e=y();t.portal.fortress.garrisont.civic.garrison.workers&&(t.portal.fortress.garrison=t.civic.garrison.workers),t.portal.fortress.assigned=t.portal.fortress.garrison,Cs({el:"#garrison"},"update"))},aLast(){let e=y(),a=t.portal.fortress.patrols*t.portal.fortress.patrol_size;s.soul_forge&&(a+=da()),t.portal.hasOwnProperty("guard_post")&&(a+=ta(t.portal.guard_post.on)),t.portal.fortress.garrison>a&&(t.portal.fortress.garrison-=e,t.portal.fortress.garrison0&&(t.portal.fortress.patrols-=e,t.portal.fortress.patrols<0&&(t.portal.fortress.patrols=0))},patSizeInc(){let e=y();t.portal.fortress.patrol_size1&&(t.portal.fortress.patrol_size-=e,t.portal.fortress.patrol_size<1&&(t.portal.fortress.patrol_size=1))},wall(){let e=t.portal.fortress.walls;return e>=75?"has-text-success":e<=25?"has-text-danger":"has-text-warning"},threaten(){let e=t.portal.fortress.threat;return e<1e3?"has-text-success":e>=2e3?"has-text-danger":"has-text-warning"},hire(){let e=y(),a=!0;for(;a&&e>0;){let r=Math.round(1.24**t.civic.garrison.workers*75)-50;r>25e3&&(r=25e3),t.civic.garrison.m_use>0&&(r*=1.1**t.civic.garrison.m_use),t.race.brute&&(r/=2),r=Math.round(r),t.civic.garrison.workers=r?(t.resource.Money.amount-=r,t.civic.garrison.workers++,t.civic.garrison.m_use++,t.portal.fortress.garrison++,t.portal.fortress.assigned=t.portal.fortress.garrison,Cs({el:"#garrison"},"update")):a=!1,e--}},hireLabel:()=>ha("hireLabel"),observation(){t.settings.civTabs=$("#mainTabs > nav ul li").length-1,t.settings.tabLoad||Pa()}},filters:{defensive:e=>function(e){let a=e-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(s.soul_forge){let e=da();e<=a&&(a-=e)}t.portal.hasOwnProperty("guard_post")&&(a-=ta(t.portal.guard_post.on));let r=0;if(t.civic.garrison.wounded>t.civic.garrison.workers-t.portal.fortress.garrison&&(r=t.civic.garrison.wounded-(t.civic.garrison.workers-t.portal.fortress.garrison),r>a&&(r=a)),s.war_droid){let e=s.war_droid-t.portal.fortress.patrols>0?s.war_droid-t.portal.fortress.patrols:0;a+=t.tech.hdroid?ta(2*e):ta(e)}let i=t.tech.turret?t.tech.turret>=2?70:50:35;return Math.round(be(a,"hellArmy",r))+(s.turret?s.turret*i:0)}(e),patrolling(e){let a=e-t.portal.fortress.patrols*t.portal.fortress.patrol_size;if(s.soul_forge){let e=da();e<=a&&(a-=e)}return t.portal.hasOwnProperty("guard_post")&&(a-=ta(t.portal.guard_post.on)),a},threat:e=>z(e<1e3?"fortress_threat_level1":e<1500?"fortress_threat_level2":e>=5e3?"fortress_threat_level6":e>=3e3?"fortress_threat_level5":e>=2e3?"fortress_threat_level4":"fortress_threat_level3"),trainTime:(e,t)=>zs(0===e?-1:(100-t)/(4*e))}}),["hostiles","threatLevel","armyLabel","patLabel","patSizeLabel","hireLabel"].forEach((function(e){ls(`hf${r}${e}`,(function(){switch(e){case"hostiles":case"threatLevel":return ha("hostiles");case"armyLabel":return z("fortress_stationed");case"patLabel":return z("fortress_patrol_desc",[t.portal.fortress.patrols]);case"patSizeLabel":return z("fortress_patrol_size_desc",[t.portal.fortress.patrol_size]);case"hireLabel":return ha("hireLabel")}}),{elm:`#${r} span.${e}`})})),ls(`hf${r}observe`,(function(){return z("hell_observation_tooltip")}),{elm:`#${r} button.observe`})}function ga(e,a){switch(e){case"ruins":{let e=a||ta(s.guard_post),r=75*(s.arcology||0),i=be(e,"hellArmy",0);t.race.holy&&(i*=1+Ei.holy.vars()[1]/100);let n=ts("unicorn");n>0&&(i*=1+Ei.holy.vars(1)[1]/100*n);let c=(i+r)/5e3;return{supress:c>1?1:c,rating:i+r}}case"gate":{let e=ga("ruins",a),r=100*(s.gate_turret||0);t.race.holy&&(r*=1+Ei.holy.vars()[1]/100);let i=ts("unicorn");i>0&&(r*=1+Ei.holy.vars(1)[1]/100*i);let n=(e.rating+r)/7500;return{supress:n>1?1:n,rating:e.rating+r}}default:return 0}}const va={fire_elm:{weapon:{laser:1.05,flame:0,plasma:.25,kinetic:.5,missile:.5,sonic:1,shotgun:.75,tesla:.65},nozone:{freeze:!0,flooded:!0},amp:{hot:1.75,humid:.8,steam:.9}},water_elm:{weapon:{laser:.65,flame:.5,plasma:1,kinetic:.2,missile:.5,sonic:.5,shotgun:.25,tesla:.75},nozone:{hot:!0,freeze:!0},amp:{steam:1.5,river:1.1,flooded:2,rain:1.75,humid:1.25}},rock_golem:{weapon:{laser:1,flame:.5,plasma:1,kinetic:.65,missile:.95,sonic:.75,shotgun:.35,tesla:0},nozone:{},amp:{}},bone_golem:{weapon:{laser:.45,flame:.35,plasma:.55,kinetic:1,missile:1,sonic:.75,shotgun:.75,tesla:.15},nozone:{},amp:{}},mech_dino:{weapon:{laser:.85,flame:.05,plasma:.55,kinetic:.45,missile:.5,sonic:.35,shotgun:.5,tesla:1},nozone:{},amp:{}},plant:{weapon:{laser:.42,flame:1,plasma:.65,kinetic:.2,missile:.25,sonic:.75,shotgun:.35,tesla:.38},nozone:{},amp:{}},crazed:{weapon:{laser:.5,flame:.85,plasma:.65,kinetic:1,missile:.35,sonic:.15,shotgun:.95,tesla:.6},nozone:{},amp:{}},minotaur:{weapon:{laser:.32,flame:.5,plasma:.82,kinetic:.44,missile:1,sonic:.15,shotgun:.2,tesla:.35},nozone:{},amp:{}},ooze:{weapon:{laser:.2,flame:.65,plasma:1,kinetic:0,missile:0,sonic:.85,shotgun:0,tesla:.15},nozone:{},amp:{}},zombie:{weapon:{laser:.35,flame:1,plasma:.45,kinetic:.08,missile:.8,sonic:.18,shotgun:.95,tesla:.05},nozone:{},amp:{}},raptor:{weapon:{laser:.68,flame:.55,plasma:.85,kinetic:1,missile:.44,sonic:.22,shotgun:.33,tesla:.66},nozone:{},amp:{}},frost_giant:{weapon:{laser:.9,flame:.82,plasma:1,kinetic:.25,missile:.08,sonic:.45,shotgun:.28,tesla:.5},nozone:{hot:!0},amp:{freeze:2.5,hail:1.65}},swarm:{weapon:{laser:.02,flame:1,plasma:.04,kinetic:.01,missile:.08,sonic:.66,shotgun:.38,tesla:.45},nozone:{},amp:{}},dragon:{weapon:{laser:.18,flame:0,plasma:.12,kinetic:.35,missile:1,sonic:.22,shotgun:.65,tesla:.15},nozone:{},amp:{}},mech_dragon:{weapon:{laser:.84,flame:.1,plasma:.68,kinetic:.18,missile:.75,sonic:.22,shotgun:.28,tesla:1},nozone:{},amp:{}},construct:{weapon:{laser:.5,flame:.2,plasma:.6,kinetic:.34,missile:.9,sonic:.08,shotgun:.28,tesla:1},nozone:{},amp:{}},beholder:{weapon:{laser:.75,flame:.15,plasma:1,kinetic:.45,missile:.05,sonic:.01,shotgun:.12,tesla:.3},nozone:{},amp:{}},worm:{weapon:{laser:.55,flame:.38,plasma:.45,kinetic:.2,missile:.05,sonic:1,shotgun:.02,tesla:.01},nozone:{},amp:{}},hydra:{weapon:{laser:.85,flame:.75,plasma:.85,kinetic:.25,missile:.45,sonic:.5,shotgun:.6,tesla:.65},nozone:{},amp:{}},colossus:{weapon:{laser:1,flame:.05,plasma:.75,kinetic:.45,missile:1,sonic:.35,shotgun:.35,tesla:.5},nozone:{},amp:{}},lich:{weapon:{laser:.1,flame:.1,plasma:.1,kinetic:.45,missile:.75,sonic:.35,shotgun:.75,tesla:.5},nozone:{},amp:{}},ape:{weapon:{laser:1,flame:.95,plasma:.85,kinetic:.5,missile:.5,sonic:.05,shotgun:.35,tesla:.68},nozone:{},amp:{}},bandit:{weapon:{laser:.65,flame:.5,plasma:.85,kinetic:1,missile:.5,sonic:.25,shotgun:.75,tesla:.25},nozone:{},amp:{}},croc:{weapon:{laser:.65,flame:.05,plasma:.6,kinetic:.5,missile:.5,sonic:1,shotgun:.2,tesla:.75},nozone:{},amp:{}},djinni:{weapon:{laser:0,flame:.35,plasma:1,kinetic:.15,missile:0,sonic:.65,shotgun:.22,tesla:.4},nozone:{},amp:{}},snake:{weapon:{laser:.5,flame:.5,plasma:.5,kinetic:.5,missile:.5,sonic:.5,shotgun:.5,tesla:.5},nozone:{},amp:{}},centipede:{weapon:{laser:.5,flame:.85,plasma:.95,kinetic:.65,missile:.6,sonic:0,shotgun:.5,tesla:.01},nozone:{},amp:{}},spider:{weapon:{laser:.65,flame:1,plasma:.22,kinetic:.75,missile:.15,sonic:.38,shotgun:.9,tesla:.18},nozone:{},amp:{}},manticore:{weapon:{laser:.05,flame:.25,plasma:.95,kinetic:.5,missile:.15,sonic:.48,shotgun:.4,tesla:.6},nozone:{},amp:{}},fiend:{weapon:{laser:.75,flame:.25,plasma:.5,kinetic:.25,missile:.75,sonic:.25,shotgun:.5,tesla:.5},nozone:{},amp:{}},bat:{weapon:{laser:.16,flame:.18,plasma:.12,kinetic:.25,missile:.02,sonic:1,shotgun:.9,tesla:.58},nozone:{},amp:{}},medusa:{weapon:{laser:.35,flame:.1,plasma:.3,kinetic:.95,missile:1,sonic:.15,shotgun:.88,tesla:.26},nozone:{},amp:{}},ettin:{weapon:{laser:.5,flame:.35,plasma:.8,kinetic:.5,missile:.25,sonic:.3,shotgun:.6,tesla:.09},nozone:{},amp:{}},faceless:{weapon:{laser:.6,flame:.28,plasma:.6,kinetic:0,missile:.05,sonic:.8,shotgun:.15,tesla:1},nozone:{},amp:{}},enchanted:{weapon:{laser:1,flame:.02,plasma:.95,kinetic:.2,missile:.7,sonic:.05,shotgun:.65,tesla:.01},nozone:{},amp:{}},gargoyle:{weapon:{laser:.15,flame:.4,plasma:.3,kinetic:.5,missile:.5,sonic:.85,shotgun:1,tesla:.2},nozone:{},amp:{}},chimera:{weapon:{laser:.38,flame:.6,plasma:.42,kinetic:.85,missile:.35,sonic:.5,shotgun:.65,tesla:.8},nozone:{},amp:{}},gorgon:{weapon:{laser:.65,flame:.65,plasma:.65,kinetic:.65,missile:.65,sonic:.65,shotgun:.65,tesla:.65},nozone:{},amp:{}},kraken:{weapon:{laser:.75,flame:.35,plasma:.75,kinetic:.35,missile:.5,sonic:.18,shotgun:.05,tesla:.85},nozone:{},amp:{}},homunculus:{weapon:{laser:.05,flame:1,plasma:.1,kinetic:.85,missile:.65,sonic:.5,shotgun:.75,tesla:.2},nozone:{},amp:{}}};function fa(e,a){let r=9999,i=1e7;switch(e){case"small":{let e=t.blood.prepared&&t.blood.prepared>=2?5e4:75e3;i=a?2.5*e:e,r=a?20:1}break;case"medium":i=a?45e4:18e4,r=a?100:4;break;case"large":i=a?925e3:375e3,r=a?500:20;break;case"titan":i=a?15e5:75e4,r=a?1500:75;break;case"collector":{let e=t.blood.prepared&&t.blood.prepared>=2?8e3:1e4;i=a?2.5*e:e,r=1}}return{s:r,c:i}}function ya(){if((t.settings.tabLoad||2===t.settings.civTabs&&4===t.settings.govTabs)&&(Ss($("#mechLab")),t.portal.hasOwnProperty("mechbay")&&t.settings.showMechLab)){let e=$("#mechLab");t.portal.mechbay.hasOwnProperty("blueprint")||(t.portal.mechbay.blueprint={size:"small",hardpoint:["laser"],chassis:"tread",equip:[],infernal:!1});let a=$('
                            ');e.append(a);let r=$(`
                            ${z("portal_mech_assembly")} - {{ b.size | slabel }} {{ b.chassis | clabel }}
                            `);a.append(r),r.append(` | ${z("portal_mech_bay_space")}: {{ m.bay }} / {{ m.max }}`),r.append(` | ${z("portal_mech_sup_avail")}: {{ p.supply | round }} / {{ p.sup_max }}`);let i=t.blood.prepared&&t.blood.prepared>=3?`${z("portal_mech_infernal")} (${z("portal_mech_infernal_effect",[25])})`:"";a.append(`
                            ${z("portal_mech_space")} {{ b.size | bay }} | ${z("portal_mech_cost")} {{ b.size | price }} | ${z("portal_mech_soul",[t.resource.Soul_Gem.name])} {{ b.size | soul }}${i}
                            `),a.append("
                            {{ b.size | desc }}
                            ");let s=$('
                            ');a.append(s);let n="";["small","medium","large","titan","collector"].forEach((function(e,t){n+=`${z(`portal_mech_size_${e}`)}`})),s.append(`\n ${n}\n `);let c="";["wheel","tread","biped","quad","spider","hover"].forEach((function(e,t){c+=`${z(`portal_mech_chassis_${e}`)}`})),s.append(`\n ${c}\n `);for(let e=0;e<4;e++){let t="";["laser","kinetic","shotgun","missile","flame","plasma","sonic","tesla"].forEach((function(a,r){t+=`${z(`portal_mech_weapon_${a}`)}`})),s.append(`\n ${t}\n `)}let o=t.blood.prepared?5:4;for(let e=0;e{{ '${a}' | equipment }}`})),s.append(`\n ${t}\n `)}a.append(`
                            `),Cs({el:"#mechAssembly",data:{p:t.portal.purifier,m:t.portal.mechbay,b:t.portal.mechbay.blueprint},methods:{build(){let e=fa(t.portal.mechbay.blueprint.size,t.portal.mechbay.blueprint.infernal),a=e.c,r=e.s,i=ba(t.portal.mechbay.blueprint.size),s=t.portal.mechbay.max-t.portal.mechbay.bay;if(t.portal.purifier.supply>=a&&s>=i&&t.resource.Soul_Gem.amount>=r){t.portal.purifier.supply-=a,t.resource.Soul_Gem.amount-=r;let e=sn(t.portal.mechbay.blueprint);t.portal.mechbay.mechs.push(e),t.portal.mechbay.bay+=i,t.portal.mechbay.active++}},setSize(e){switch(t.portal.mechbay.blueprint.size=e,"collector"===e?t.portal.mechbay.blueprint.hardpoint.length=0:"small"===e||"medium"===e?(0===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push("laser"),t.portal.mechbay.blueprint.hardpoint.length=1):(0===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push("laser"),1===t.portal.mechbay.blueprint.hardpoint.length&&t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"plasma":"laser"),"titan"===e?2===t.portal.mechbay.blueprint.hardpoint.length&&(t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"shotgun":"laser"),t.portal.mechbay.blueprint.hardpoint.push(t.portal.mechbay.blueprint.hardpoint.includes("laser")?"kinetic":"laser")):t.portal.mechbay.blueprint.hardpoint.length=2),e){case"small":t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?1:0;break;case"medium":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("shields"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?2:1;break;case"collector":case"large":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length<2&&t.portal.mechbay.blueprint.equip.push("shields"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("grapple"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?3:2;break;case"titan":t.portal.mechbay.blueprint.equip.length<1&&t.portal.mechbay.blueprint.equip.push("special"),t.portal.mechbay.blueprint.equip.length<2&&t.portal.mechbay.blueprint.equip.push("shields"),t.portal.mechbay.blueprint.equip.length<3&&t.portal.mechbay.blueprint.equip.push("grapple"),t.portal.mechbay.blueprint.equip.length<4&&t.portal.mechbay.blueprint.equip.push("seals"),t.blood.prepared&&t.portal.mechbay.blueprint.equip.push("stabilizer"),t.portal.mechbay.blueprint.equip.length=t.blood.prepared?5:4}},setType(e){t.portal.mechbay.blueprint.chassis=e},setWep(e,a){t.portal.mechbay.blueprint.hardpoint[a]=e,Cs({el:"#mechAssembly"},"update")},setEquip(e,a){t.portal.mechbay.blueprint.equip[a]=e,Cs({el:"#mechAssembly"},"update")},vis:e=>"collector"!==t.portal.mechbay.blueprint.size&&(0===e||"large"===t.portal.mechbay.blueprint.size&&e<2||"titan"===t.portal.mechbay.blueprint.size),eVis(e){let a=t.blood.prepared?1:0;switch(t.portal.mechbay.blueprint.size){case"small":return 1===a&&0===e;case"medium":return e<=0+a;case"collector":case"large":return e<=1+a;case"titan":return!0}}},filters:{bay:e=>ba(e),price:e=>fa(e,t.portal.mechbay.blueprint.infernal).c,soul:e=>fa(e,t.portal.mechbay.blueprint.infernal).s,slabel:e=>z(`portal_mech_size_${e}`),clabel:e=>z(`portal_mech_chassis_${e}`),wlabel:e=>z(`portal_mech_weapon_${e}`),desc:e=>z(`portal_mech_size_${e}_desc`),round:e=>Math.round(e),equipment(e){if("special"!==e)return z(`portal_mech_equip_${e}`);let a="jumpjet";switch(t.portal.mechbay.blueprint.size){case"large":a="battery";break;case"titan":a="target"}return z(`portal_mech_equip_${a}`)}}}),["size","chassis","weapon","equip"].forEach((function(e){let a=1;"weapon"===e?a=4:"equip"===e&&(a=o);for(let r=0;r');e.append(l),wa(),Ss($("#mechList")),$("#mechList").append(`\n
                            \n ${z("portal_mech_scrap")}\n | ${z("portal_mech")} #{{index + 1}}: \n {{ mech.infernal ? "${z("portal_mech_infernal")} " : "" }}{{ mech | size }} {{ mech | chassis }}\n
                            \n
                            \n \n
                            \n
                            \n \n
                            \n
                            \n
                            `),Cs({el:"#mechList",data:t.portal.mechbay,methods:{scrap(e){if(t.portal.mechbay.mechs[e]){let a=fa(t.portal.mechbay.mechs[e].size,t.portal.mechbay.mechs[e].infernal),r=ba(t.portal.mechbay.mechs[e].size);t.portal.purifier.supply+=Math.floor(a.c/3),t.resource.Soul_Gem.amount+=Math.floor(a.s/2),t.portal.purifier.supply>t.portal.purifier.sup_max&&(t.portal.purifier.supply=t.portal.purifier.sup_max),t.portal.mechbay.mechs.splice(e,1),t.portal.mechbay.bay-=r,t.portal.mechbay.active--}}},filters:{equipment(e,t){if("special"!==e)return z(`portal_mech_equip_${e}`);let a="jumpjet";switch(t){case"large":a="battery";break;case"titan":a="target"}return z(`portal_mech_equip_${a}`)},weapon:e=>z(`portal_mech_weapon_${e}`),size:e=>z(`portal_mech_size_${e.size}`),chassis:e=>z(`portal_mech_chassis_${e.chassis}`)}}),function(){let e=$("#mechList")[0];Sortable.create(e,{onEnd(e){let a=e.from.querySelectorAll(":scope > .mechRow");e.from.insertBefore(e.item,a[e.oldIndex+(e.oldIndex>e.newIndex)]);let r=t.portal.mechbay.mechs;r.splice(e.newDraggableIndex,0,r.splice(e.oldDraggableIndex,1)[0]),ka()}})}(),$("#mechList .scrap").each((function(e,a){ls(`mechList-scrap${e}`,(function(){let a=fa(t.portal.mechbay.mechs[e].size,t.portal.mechbay.mechs[e].infernal);return z("portal_mech_scrap_refund",[Math.floor(a.c/3),Math.floor(a.s/2)])}),{elm:a})}))}}function ba(e){switch(e){case"small":return 2;case"medium":return t.blood.prepared&&t.blood.prepared>=2?4:5;case"large":return t.blood.prepared&&t.blood.prepared>=2?8:10;case"titan":return t.blood.prepared&&t.blood.prepared>=2?20:25;case"collector":return 1;case"default":return 25}}function wa(){let e=$("#mechList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}function ka(){let e=25*(l.mechbay||0),a=0,r=0,i=0;for(let s of t.portal.mechbay.mechs)a+=ba(s.size),a<=e&&(r++,"small"===s.size&&i++);t.portal.mechbay.bay=a,t.portal.mechbay.max=e,t.portal.mechbay.active=r,t.portal.mechbay.scouts=i}function $a(e){t.portal.spire.status.freeze||t.portal.spire.status.hot?"freeze"!==e&&"hot"!==e&&(t.portal.spire.status[e]=!0):t.portal.spire.status.rain||t.portal.spire.status.hail?"rain"!==e&&"hail"!==e&&(t.portal.spire.status[e]=!0):t.portal.spire.status[e]=!0}function xa(e,a){let r=a||t.portal.spire.type,i=1;switch(e.chassis){case"wheel":switch(r){case"sand":i=["small","medium"].includes(e.size)?.9:.85;break;case"swamp":i=["small","medium"].includes(e.size)?.35:.18;break;case"jungle":i=["small","medium"].includes(e.size)?.92:.85;break;case"rocky":i=["small","medium"].includes(e.size)?.65:.5;break;case"gravel":i=["small","medium"].includes(e.size)?1:.95;break;case"muddy":i=["small","medium"].includes(e.size)?.85:.58;break;case"grass":i=["small","medium"].includes(e.size)?1.3:1.2;break;case"brush":i=["small","medium"].includes(e.size)?.9:.8;break;case"concrete":i=["small","medium"].includes(e.size)?1.1:1}break;case"tread":switch(r){case"sand":i=["small","medium"].includes(e.size)?1.15:1.1;break;case"swamp":i=["small","medium"].includes(e.size)?.55:.4;break;case"forest":i=["small","medium"].includes(e.size)?1:.95;break;case"jungle":i=["small","medium"].includes(e.size)?.95:.9;break;case"rocky":i=["small","medium"].includes(e.size)?.65:.5;break;case"gravel":i=["small","medium"].includes(e.size)?1.3:1.2;break;case"muddy":i=["small","medium"].includes(e.size)?.88:.72}break;case"biped":switch(r){case"sand":i=["small","medium"].includes(e.size)?.78:.65;break;case"swamp":i=["small","medium"].includes(e.size)?.68:.5;break;case"forest":i=["small","medium"].includes(e.size)?1:.95;break;case"jungle":i=["small","medium"].includes(e.size)?.82:.7;break;case"rocky":i=["small","medium"].includes(e.size)?.48:.4;break;case"muddy":i=["small","medium"].includes(e.size)?.85:.7;break;case"grass":i=["small","medium"].includes(e.size)?1.25:1.2;break;case"brush":i=["small","medium"].includes(e.size)?.92:.85}break;case"quad":switch(r){case"sand":i=["small","medium"].includes(e.size)?.86:.75;break;case"swamp":i=["small","medium"].includes(e.size)?.58:.42;break;case"forest":i=["small","medium"].includes(e.size)?1.25:1.2;break;case"rocky":case"brush":i=["small","medium"].includes(e.size)?.95:.9;break;case"gravel":i=["small","medium"].includes(e.size)?.9:.8;break;case"muddy":i=["small","medium"].includes(e.size)?.68:.5;break;case"grass":i=["small","medium"].includes(e.size)?1:.95}break;case"spider":switch(r){case"sand":i=["small","medium"].includes(e.size)?.75:.65;break;case"swamp":i=["small","medium"].includes(e.size)?.9:.78;break;case"forest":i=["small","medium"].includes(e.size)?.82:.75;break;case"jungle":i=["small","medium"].includes(e.size)?.77:.65;break;case"rocky":i=["small","medium"].includes(e.size)?1.25:1.2;break;case"gravel":i=["small","medium"].includes(e.size)?.86:.75;break;case"muddy":i=["small","medium"].includes(e.size)?.92:.82;break;case"brush":i=["small","medium"].includes(e.size)?1:.95}break;case"hover":switch(r){case"swamp":i=["small","medium"].includes(e.size)?1.35:1.2;break;case"forest":i=["small","medium"].includes(e.size)?.65:.48;break;case"jungle":i=["small","medium"].includes(e.size)?.55:.35;break;case"rocky":i=["small","medium"].includes(e.size)?.82:.68;break;case"muddy":i=["small","medium"].includes(e.size)?1.15:1.08;break;case"brush":i=["small","medium"].includes(e.size)?.78:.7}}return i}function qa(e){switch(e){case"small":return.0025;case"medium":return.0075;case"large":return.01;case"titan":return.012;default:return 0}}function Pa(e){if(!t.settings.tabLoad&&t.settings.civTabs!==$("#mainTabs > nav ul li").length-1&&!e)return;let a=$("#mTabObserve");Ss(a);let r=$('
                            ');if(a.append(r),r.append(`\n \n \n \n \n \n \n `),Cs({el:"#hellObservations",data:{s:t.settings},methods:{swapTab(e){if(!t.settings.tabLoad)switch(Ss($("#h_Report")),Ss($("#h_Analysis")),e){case 0:Ma();break;case 1:ja()}return e}}}),t.settings.tabLoad)Ma(),ja();else switch(t.settings.hellTabs){case 0:Ma();break;case 1:ja()}}function ja(){if(!t.settings.tabLoad&&1!==t.settings.hellTabs)return;let e=$("#h_Analysis"),a=$('
                            ');e.append(a);let r=$("
                            ");a.append(r);let i=$('
                            ');a.append(i);let s=$('
                            ');i.append(s);let n=$('
                            '),c=$('
                            ');s.append(n),s.append(c),r.append(`\n
                            \n

                            ${z("tab_settings")}

                            \n
                            \n
                            \n ${z("hell_analysis_expanded")}\n ${z("hell_analysis_average")}\n ${z("hell_analysis_hyperSlow")}\n
                            \n
                            \n ${z("hell_analysis_time_game_days")}\n ${z("hell_analysis_time_seconds")}\n ${z("hell_analysis_time_minutes")}\n ${z("hell_analysis_time_hours")}\n ${z("hell_analysis_time_days")}\n
                            \n `),Cs({el:"#hellAnalysis",data:{s:t.portal.observe.settings,r:t.race}});let o=function(e,t){e=e.toFixed(t);let a=Math.floor(e),r=(+(e-a).toFixed(t)).toString().substring(1);return a.toLocaleString()+r},l=function(e,a,r){if(e){switch("game_days"!==r&&t.portal.observe.settings.hyperSlow&&(t.race.slow&&(a*=1+Ei.slow.vars()[0]/100),t.race.hyper&&(a*=1-Ei.hyper.vars()[0]/100)),e/=a,r){case"seconds":e/=5;break;case"minutes":e*=12;break;case"hours":e*=720;break;case"days":e*=17280}e=t.portal.observe.settings.expanded?o(e,5):x(e,5,!0)}return z("hell_analysis_time_average",[e,z(`hell_analysis_time_${r}_abbr`)])},_=function(e,a){if(!e)return;let r=$(`#${e}`);Ss(r),r.append(`\n

                            ${z("hell_analysis_"+a)}

                            ${"period"===a?'

                            {{ | resetLabel }}

                            ':""}
                            \n

                            {{ st.${a}.start | startLabel }}

                            \n

                            {{ st.${a}.days, s.display | time }}

                            \n

                            {{ st.${a}.kills, 'kills', s.average | genericMulti }}

                            {{ s.dropKills | dropdownLabel }}

                            \n
                            \n

                            {{ st.${a}.kills.drones, 'kills_drones', s.average | genericSub }}

                            \n

                            {{ st.${a}.kills.patrols, 'kills_patrols', s.average | genericSub }}

                            \n

                            {{ st.${a}.kills.sieges, 'kills_sieges', s.average | genericSub }}

                            \n

                            {{ st.${a}.kills.guns, 'kills_guns', s.average | genericSub }}

                            \n

                            {{ st.${a}.kills.soul_forge, 'kills_soul_forge', s.average | genericSub }}

                            \n

                            {{ st.${a}.kills.turrets, 'kills_turrets', s.average | genericSub }}

                            \n
                            \n

                            {{ st.${a}.gems, 'gems', s.average | genericMulti }}

                            {{ s.dropGems | dropdownLabel }}

                            \n
                            \n

                            {{ st.${a}.gems.patrols, 'gems_patrols', s.average | genericSub }}

                            \n

                            {{ st.${a}.gems.guns, 'gems_guns', s.average | genericSub }}

                            \n

                            {{ st.${a}.gems.soul_forge, 'gems_soul_forge', s.average | genericSub }}

                            \n

                            {{ st.${a}.gems.crafted, 'gems_crafted', s.average | genericSub }}

                            \n

                            {{ st.${a}.gems.turrets, 'gems_turrets', s.average | genericSub }}

                            \n

                            {{ st.${a}.gems.surveyors, 'gems_surveyors', s.average | genericSub }}

                            \n
                            \n

                            {{ st.${a}.wounded, 'wounded', s.average | generic }}

                            \n

                            {{ st.${a}.died, 'died', s.average | generic }}

                            \n

                            {{ st.${a}.revived, 'revived', s.average | generic }}

                            \n

                            {{ st.${a}.surveyors, 'surveyors', s.average | generic }}

                            \n

                            {{ st.${a}.sieges, 'sieges', s.average | generic }}

                            \n `),Cs({el:`#${e}`,data:{st:t.portal.observe.stats,s:t.portal.observe.settings,p:t.portal,r:t.race,sg:t.resource.Soul_Gem},methods:{resetObservations(){Object.keys(t.portal.observe.stats.period).forEach((function(e){["kills","gems"].includes(e)?Object.keys(t.portal.observe.stats.period[e]).forEach((function(a){t.portal.observe.stats.period[e][a]=0})):"start"===e?t.portal.observe.stats.period.start={year:t.city.calendar.year,day:t.city.calendar.day}:t.portal.observe.stats.period[e]=0}))},toggleDropdown(e){t.portal.observe.settings[e]=!t.portal.observe.settings[e]}},filters:{generic:(e,r,i)=>z("hell_analysis_number_display",i?[z(`hell_analysis_${r}`),l(e,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]:[z(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+e.toFixed(5)).toLocaleString():x(e,5,!0)]),genericSub:(e,r,i)=>i?"ᄂ"+z("hell_analysis_number_display",[z(`hell_analysis_${r}`),l(e,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]):"ᄂ"+z("hell_analysis_number_display",[z(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+e.toFixed(5)).toLocaleString():x(e,5,!0)]),genericMulti(e,r,i){let s=0;return Object.keys(e).forEach((function(t){s+=e[t]})),z("hell_analysis_number_display",i?[z(`hell_analysis_${r}`),l(s,t.portal.observe.stats[a].days,t.portal.observe.settings.display)]:[z(`hell_analysis_${r}`),t.portal.observe.settings.expanded?(+s.toFixed(5)).toLocaleString():x(s,5,!0)])},time(e,a){switch("game_days"!==a&&t.portal.observe.settings.hyperSlow&&(t.race.slow&&(e*=1+Ei.slow.vars()[0]/100),t.race.hyper&&(e*=1-Ei.hyper.vars()[0]/100)),a){case"seconds":e*=5;break;case"minutes":e/=12;break;case"hours":e/=720;break;case"days":e/=17280}return z("hell_analysis_time",[z(`hell_analysis_time_${a}`),t.portal.observe.settings.expanded?o(e,8):x(e,5,!0)])},resetLabel:()=>z("hell_analysis_period_reset"),startLabel:e=>z("hell_analysis_start",[e.year,e.day]),dropdownLabel:e=>e?"⮝":"⮟"}})};_("hellAnalysisTotal","total"),_("hellAnalysisPeriod","period"),a=$("#hellAnalysis");let d=$("
                            ");a.append(d),d.append(`

                            ${z("hell_graph_create")}

                            `);let p=$('
                            ');d.append(p),Cs({el:"#hellGraphCreator",methods:{createGraph(){this.$buefy.modal.open({parent:this,component:{template:''}});let e=setInterval((function(){if($("#modalBox").length>0){clearInterval(e),$("#modalBox").append($(`

                            ${z("hell_graph_title")}

                            `));var a=$('
                            ');$("#modalBox").append(a);let r=$('
                            ');a.append(r);let i={chartType:"pie",name:"",chartName:"",data:[],radioFake:"",showGroups:!0},s={show:!1,message:""};r.append(`\n

                            ${z("hell_graph_name")}

                            \n `),r.append(`\n
                            \n
                            \n

                            ${z("hell_graph_type")}

                            \n
                            \n
                            \n ${z("hell_graph_pie")}\n
                            \n
                            \n `);let n=$('
                            ');r.append(n),n.append(`

                            ${z("hell_graph_data")}

                            `),Object.keys(t.portal.observe.stats).forEach((function(e){["kills","gems"].forEach((function(t){n.append(`
                            \n ${z("hell_graph_datapoint",[z(`hell_analysis_${e}`),z(`hell_analysis_${t}`)])}\n
                            `)}))})),r.append(`\n
                            \n
                            \n

                            {{ e.message }}

                            \n
                            \n
                            \n \n
                            \n
                            \n `),Cs({el:"#specialModal",data:{s:i,e:s,sg:t.resource.Soul_Gem},methods:{nameUpdate(e){i.chartName!==e&&(s.show=!1,i.chartName=e)},dataOptions(e){switch(e){case"pie":i.showGroups=!0;break;case"bar":i.showGroups=!1}},setData(e,t){s.show=!1,i.data=[e,t]},createGraph(){if(!i.name)return s.show=!0,void(s.message=z("hell_graph_error_name_blank"));if(0===i.data.length)return s.show=!0,void(s.message=z("hell_graph_error_data_missing"));let e=[],a=[];"pie"===i.chartType&&Object.keys(t.portal.observe.stats[i.data[0]][i.data[1]]).forEach((function(t){e.push(z(`hell_analysis_${i.data[1]}_${t}`)),a.push([i.data[0],i.data[1],t])}));let r=function(e,a,r,i,s){let n=`hellGraph-${t.portal.observe.graphID}`;return t.portal.observe.graphID++,t.portal.observe.graphs[n]={id:n,chartID:`${n}-chart`,name:e,type:a,labels:r,data:i,settings:s},n}(i.chartName,i.chartType,e,a,{title:i.chartName});Oa(p,t.portal.observe.graphs[r]),document.dispatchEvent(new KeyboardEvent("keydown",{key:"Escape"})),document.dispatchEvent(new KeyboardEvent("keyup",{key:"Escape"}))}}})}}),50)}}}),Object.keys(t.portal.observe.graphs).forEach((function(e){Oa(p,t.portal.observe.graphs[e])}))}function Oa(e,a){let r=a.id;p[r]&&p[r].graph.destroy();let i=$(`
                            `);e.append(i),i.append(`
                            \n
                            \n

                            \n

                            Delete

                            \n
                            \n
                            \n

                            ${a.name}

                            \n
                            \n
                            `);let s=$('
                            ');i.append(s),Cs({el:`#graph-${r}-controls`,methods:{deleteGraph(){p[r].graph.destroy(),delete p[r],delete t.portal.observe.graphs[r],Ss($(`#graph-${r}-container`),!0)}}});let n=$(``);s.append(n),p[r]={data:a.data},"pie"===a.type&&(p[r].graph=function(e,a,r,i){let s=[];return r.forEach((function(e){s.push(3===e.length?t.portal.observe.stats[e[0]][e[1]][e[2]]:t.portal.observe.stats[e[0]][e[1]])})),new Chart(e,{type:"pie",data:{labels:a,datasets:[{data:s,backgroundColor:["rgb(255, 99, 132)","rgb(54, 162, 235)","rgb(255, 205, 86)","rgb(201, 203, 207)","rgb(75, 192, 192)","#B86BFF","#48c774"],hoverOffset:4}]},options:{plugins:{legend:{display:!1}}}})}(n,a.labels,a.data,a.settings))}function Ma(){if(!t.settings.tabLoad&&0!==t.settings.hellTabs)return;Sa();let e="",a=$("#h_Report"),r=$('
                            ');a.append(r);let i=$('
                            ');r.append(i),i.append(`

                            ${z("hell_report_log")}

                            \n \n \n\t\t \n \n
                            `);let s=$('
                            ');i.append(s),r.append($('
                            '));let n={year:0,day:0};Object.keys(d).length&&(n.year=Object.keys(d)[0].split("-")[1],n.day=Object.keys(d[`year-${n.year}`])[0].split("-")[1]);let c=function(a,r){for(Sa(!0)&&(e="",a=Object.keys(d)[0].split("-")[1],r=Object.keys(d[`year-${n.year}`])[0].split("-")[1]);a${z("year")+" "+a+" | "+z("day")+" "+r}${d[`year-${a}`][`day-${r}`].foundGem?'':""}\n `+e;r=1}for(;r${z("year")+" "+a+" | "+z("day")+" "+r}${d[`year-${a}`][`day-${r}`].foundGem?``:""}\n `+e;n.year=a,n.day=r;let i=$("#hellReportList");Ss(i),i.append(e),Cs({el:"#hellReportList",methods:{reportLoad(e,t){o(e,t)}}})},o=function(e,a){if(!e||!a)return;let r=$("#hellReportDisplay");Ss(r);let i=d[`year-${e}`][`day-${a}`],s=$('
                            ');r.append(s);let n=0,c=0;if(Object.keys(i.stats.kills).forEach((function(e){n+=i.stats.kills[e]})),Object.keys(i.stats.gems).forEach((function(e){c+=i.stats.gems[e]})),s.append(`

                            ${z("hell_report_log_stats",[e,a])}

                            `),s.append(`
                            \n

                            ${z("hell_report_log_stats_kills",[n])}

                            \n

                            ${z("hell_report_log_stats_gems",[c])}

                            \n

                            ${z("hell_report_log_stats_wounded",[i.stats.wounded])}

                            \n

                            ${z("hell_report_log_stats_died",[i.stats.died])}

                            \n
                            `),r.append(`

                            ${z("hell_report_log_report",[e,a])}

                            `),r.append(`

                            ${z("hell_report_log_start",[i.start])}

                            `),i.drones&&Object.keys(i.drones).forEach((function(e){let t=i.drones[e],a=z("hell_report_log_obj_counter",[z("portal_war_drone_title"),e]);t.encounter?r.append(`

                            ${z("hell_report_log_encounter",[a,t.kills])}

                            `):r.append(`

                            ${z("hell_report_log_encounter_fail",[a])}

                            `)})),i.patrols&&Object.keys(i.patrols).forEach((function(e){let a=i.patrols[e],s=z("hell_report_log_obj_counter",[z("hell_report_log_patrol"),e]);if(s=a.droid?z("hell_report_log_patrol_droid",[s]):s,a.encounter){let e=$("

                            ");a.ambush?e.append(`${z("hell_report_log_patrol_ambush",[s,a.kills])}`):e.append(`${z("hell_report_log_encounter",[s,a.kills])}`),a.wounded&&e.append(`${a.wounded>1?z("hell_report_log_patrol_wounded_plural",[a.wounded]):z("hell_report_log_patrol_wounded")}`),a.died&&e.append(`${a.died>1?z("hell_report_log_patrol_killed_plural",[a.died]):z("hell_report_log_patrol_killed")}`),a.gem>0&&e.append(`${z("hell_report_log_soul_find",[t.resource.Soul_Gem.name,a.gem])}`),r.append(e)}else r.append(`

                            ${z("hell_report_log_encounter_fail",[s])}

                            `)})),i.surveyor_finds&&Object.keys(i.surveyor_finds).forEach((function(e){let a=i.surveyor_finds[e],s=z("hell_report_log_obj_counter",[z("job_hell_surveyor"),e]),n=$("

                            ");n.append(`${z("hell_report_log_search",[s,a.bodies])}`),a.gem>0&&n.append(`${z("hell_report_log_soul_search",[t.resource.Soul_Gem.name,a.gem])}`),r.append(n)})),i.revived&&r.append(`

                            ${i.revived>1?z("hell_report_log_revived_plural",[i.revived]):z("hell_report_log_revived")}

                            `),i.patrols_lost&&r.append(`

                            ${z("hell_report_log_patrols_lost",[i.patrols_lost])}

                            `),i.siege&&(i.siege.destroyed?r.append(`

                            ${z("hell_report_log_siege",[i.siege.surveyors,i.siege.soldiers,i.siege.kills])}

                            `):r.append(`

                            ${z("hell_report_log_siege_fail",[i.siege.damage,i.siege.kills])}

                            `)),i.demons&&r.append(`

                            ${z("hell_report_log_demons",[i.demons])}

                            `),i.surveyors&&r.append(`

                            ${i.surveyors>1?z("hell_report_log_surveyors_plural",[i.surveyors]):z("hell_report_log_surveyors")}

                            `),i.soul_attractors&&r.append(`

                            ${z("hell_report_log_soul_attractors",[i.soul_attractors])}

                            `),i.gun_emplacements&&Object.keys(i.gun_emplacements).forEach((function(e){let a=$("

                            "),s=i.gun_emplacements[e],n=z("hell_report_log_obj_counter",[z("portal_gun_emplacement_title"),e]);a.append($(`${z("hell_report_log_misc_kills",[n,s.kills,z("portal_pit_name")])}`)),s.gem&&a.append(`${z("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),r.append(a)})),i.soul_forge){let e=$("

                            ");e.append(`${z("hell_report_log_soul_forge",[i.soul_forge.kills])}`),i.soul_forge.gem&&e.append(`${z("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),i.soul_forge.gem_craft&&e.append(`${z("hell_report_log_soul_craft",[i.soul_forge.corrupt?z("resource_Corrupt_Gem_name"):t.resource.Soul_Gem.name])}`),r.append(e)}i.gate_turrets&&Object.keys(i.gate_turrets).forEach((function(e){let a=$("

                            "),s=i.gate_turrets[e],n=z("hell_report_log_obj_counter",[z("portal_gate_turret_title"),e]);a.append(`${z("hell_report_log_misc_kills",[n,s.kills,z("portal_gate_name")])}`),s.gem&&a.append(`${z("hell_report_log_soul_find",[t.resource.Soul_Gem.name,1])}`),r.append(a)})),Cs({el:"#hellReportDisplay",data:{g:t.resource.Soul_Gem}})};if(0!==n.day){c(n.year,n.day);let e=n.year,a=n.day;a-1==0?(e--,a=t.city.calendar.orbit):a--,o(e,a)}else n.year=t.city.calendar.year,n.day=t.city.calendar.day;Cs({el:"#hellReportLogTitle",methods:{updateList(){c(n.year,n.day)}}}),ls("hellReportLogs",(function(){return z("hell_report_log_tooltip",[2500])}),{elm:"#hellReport .reportList div:first-child h2"})}function Sa(e){if(!document.getElementById("hellReportList")||e){let e=!1,a=2500,r=(Object.keys(d).length-1)*t.city.calendar.orbit+t.city.calendar.day;if(r>a){let i=Object.keys(d[Object.keys(d)[0]]).length;for(r-t.city.calendar.orbit+i>a&&(e=!0,r-=i,delete d[Object.keys(d)[0]]);r>a;)r-=t.city.calendar.orbit,delete d[Object.keys(d)[0]]}return e}}const Ca={Food:5,Lumber:5,Chrysotile:5,Stone:5,Crystal:6,Furs:8,Copper:25,Iron:40,Aluminium:50,Cement:15,Coal:20,Oil:75,Uranium:550,Steel:100,Titanium:150,Alloy:350,Polymer:250,Iridium:420,Helium_3:620,Deuterium:950,Elerium:2e3,Water:2,Neutronium:1500,Adamantite:2250,Infernite:2750,Nano_Tube:750,Graphene:3e3,Stanene:3600,Bolognium:9e3,Vitreloy:10200,Orichalcum:99e3,Horseshoe:0,Nanite:0,Genes:0,Soul_Gem:0,Corrupt_Gem:0,Codex:0,Cipher:0,Demonic_Essence:0},za={Food:2,Lumber:2,Chrysotile:1,Stone:2,Crystal:.4,Furs:1,Copper:1,Iron:1,Aluminium:1,Cement:1,Coal:1,Oil:.5,Uranium:.12,Steel:.5,Titanium:.25,Alloy:.2,Polymer:.2,Iridium:.1,Helium_3:.1,Deuterium:.1,Elerium:.02,Water:2,Neutronium:.05,Adamantite:.05,Infernite:.01,Nano_Tube:.1,Graphene:.1,Stanene:.1,Bolognium:.12,Vitreloy:.12,Orichalcum:.05},Fa={Food:4.355,Lumber:7.668,Chrysotile:15.395,Stone:20.017,Crystal:5.062,Furs:13.009,Copper:63.546,Iron:55.845,Aluminium:26.9815,Cement:20.009,Coal:12.0107,Oil:5.342,Uranium:238.0289,Steel:55.9,Titanium:47.867,Alloy:45.264,Polymer:120.054,Iridium:192.217,Helium_3:3.0026,Deuterium:2.014,Neutronium:248.74,Adamantite:178.803,Infernite:222.666,Elerium:297.115,Nano_Tube:15.083,Graphene:26.9615,Stanene:33.9615,Bolognium:75.898,Unobtainium:168.59,Vitreloy:41.08,Orichalcum:237.8,Water:18.01,Plywood:7.666,Brick:20.009,Wrought_Iron:55.845,Sheet_Metal:26.9815,Mythril:94.239,Aerogel:7.84,Nanoweave:23.71,Scarletite:188.6,Quantium:241.35},Aa={Lumber:{in:.5,out:25e3},Chrysotile:{in:.5,out:25e3},Stone:{in:.5,out:25e3},Crystal:{in:3,out:25e3},Furs:{in:3,out:25e3},Copper:{in:1.5,out:25e3},Iron:{in:1.5,out:25e3},Aluminium:{in:2.5,out:25e3},Cement:{in:3,out:25e3},Coal:{in:1.5,out:25e3},Oil:{in:2.5,out:12e3},Uranium:{in:5,out:300},Steel:{in:3,out:25e3},Titanium:{in:3,out:25e3},Alloy:{in:6,out:25e3},Polymer:{in:6,out:25e3},Iridium:{in:8,out:25e3},Helium_3:{in:4.5,out:12e3},Deuterium:{in:4,out:1e3},Neutronium:{in:15,out:1e3},Adamantite:{in:12.5,out:1e3},Infernite:{in:25,out:250},Elerium:{in:30,out:250},Nano_Tube:{in:6.5,out:1e3},Graphene:{in:5,out:1e3},Stanene:{in:4.5,out:1e3},Bolognium:{in:18,out:1e3},Vitreloy:{in:14,out:1e3},Orichalcum:{in:10,out:1e3},Plywood:{in:10,out:250},Brick:{in:10,out:250},Wrought_Iron:{in:10,out:250},Sheet_Metal:{in:10,out:250},Mythril:{in:12.5,out:250},Aerogel:{in:16.5,out:250},Nanoweave:{in:18,out:250},Scarletite:{in:35,out:250}};function Ia(){let e={Plywood:[{r:"Lumber",a:100}],Brick:t.race.flier?[{r:"Stone",a:60}]:[{r:"Cement",a:40}],Wrought_Iron:[{r:"Iron",a:80}],Sheet_Metal:[{r:"Aluminium",a:120}],Mythril:[{r:"Iridium",a:100},{r:"Alloy",a:250}],Aerogel:[{r:"Graphene",a:2500},{r:"Infernite",a:50}],Nanoweave:[{r:"Nano_Tube",a:1e3},{r:"Vitreloy",a:40}],Scarletite:[{r:"Iron",a:25e4},{r:"Adamantite",a:7500},{r:"Orichalcum",a:500}],Quantium:[{r:"Nano_Tube",a:1e3},{r:"Graphene",a:1e3},{r:"Elerium",a:25}],Thermite:[{r:"Iron",a:180},{r:"Aluminium",a:60}]};if(t.race.wasteful){let t=1+Ei.wasteful.vars()[0]/100;Object.keys(e).forEach((function(a){for(let r=0;r=2){let e=t.tech.foundry>=5?t.tech.foundry>=8?.08:.05:.03;La.general.add.push({name:z("city_foundry"),manual:t.city.foundry.count*e,auto:t.city.foundry.count*e})}if(t.tech.foundry>=3&&Object.keys(La).forEach((function(e){t.city.foundry[e]&&t.city.foundry[e]>1&&La[e].add.push({name:z("tech_apprentices"),manual:(t.city.foundry[e]-1)*ke(.03),auto:(t.city.foundry[e]-1)*ke(.03)})})),t.tech.foundry>=4&&t.city.sawmill&&La.Plywood.add.push({name:z("city_sawmill"),manual:.02*t.city.sawmill.count,auto:.02*t.city.sawmill.count}),t.tech.foundry>=6&&La.Brick.add.push({name:z("city_foundry"),manual:.02*t.city.foundry.count,auto:.02*t.city.foundry.count}),t.tech.foundry>=7&&(La.general.add.push({name:z("city_factory")+` (${z("tab_city5")})`,manual:.05*s.factory,auto:.05*s.factory}),t.tech.mars>=4&&La.general.add.push({name:z("city_factory")+` (${z("tab_space")})`,manual:.05*s.red_factory,auto:.05*s.red_factory}),t.interstellar.int_factory&&s.int_factory&&La.general.add.push({name:z("interstellar_int_factory_title"),manual:.1*s.int_factory,auto:.1*s.int_factory})),t.space.fabrication&&n.fabrication&&La.general.add.push({name:z("space_red_fabrication_title"),manual:n.fabrication*t.civic.colonist.workers*ke(e?.05:.02),auto:n.fabrication*t.civic.colonist.workers*ke(e?.05:.02)}),s.stellar_forge&&(La.Mythril.add.push({name:z("interstellar_stellar_forge_title"),manual:.05*s.stellar_forge,auto:.05*s.stellar_forge}),La.general.add.push({name:z("interstellar_stellar_forge_title"),manual:0,auto:.1*s.stellar_forge})),s.hell_forge){let e=ga("ruins");La.general.add.push({name:z("portal_hell_forge_title"),manual:0,auto:.75*s.hell_forge*e.supress}),La.Scarletite.multi.push({name:z("portal_ruins_supressed"),manual:1,auto:e.supress})}if(t.tauceti.tau_factory&&n.tau_factory&&La.general.add.push({name:z("tau_home_tau_factory"),manual:0,auto:n.tau_factory*(t.tech.isolation?2.75:.9)}),t.tech.isolation&&t.tauceti.colony&&n.colony&&La.general.add.push({name:z("tau_home_colony"),manual:.5*n.colony,auto:.5*n.colony}),n.zero_g_lab&&s.zero_g_lab||n.infectious_disease_lab&&s.infectious_disease_lab){let e=lt("spc_enceladus");La.Quantium.multi.push({name:z("space_syndicate"),manual:1,auto:e})}if(t.tech.alien_crafting&&n.infectious_disease_lab&&s.infectious_disease_lab){let e=1+.65*Math.min(n.infectious_disease_lab,s.infectious_disease_lab);La.Quantium.multi.push({name:z("tech_infectious_disease_lab_alt"),manual:1,auto:e})}if(t.race.crafty&&La.general.add.push({name:z("wiki_arpa_crispr_crafty"),manual:.03,auto:.03}),t.race.ambidextrous&&La.general.add.push({name:z("trait_ambidextrous_name"),manual:Ei.ambidextrous.vars()[0]*t.race.ambidextrous/100,auto:Ei.ambidextrous.vars()[0]*t.race.ambidextrous/100}),t.race.rigid&&La.general.add.push({name:z("trait_rigid_name"),manual:-Ei.rigid.vars()[0]/100,auto:-Ei.rigid.vars()[0]/100}),"socialist"===t.civic.govern.type&&La.general.multi.push({name:z("govern_socialist"),manual:1+Y.socialist()[0]/100,auto:1+Y.socialist()[0]/100}),t.race.casting&&t.race.casting.crafting){let e=1+t.race.casting.crafting/(t.race.casting.crafting+75),a=1+2*t.race.casting.crafting/(2*t.race.casting.crafting+75);La.general.multi.push({name:z("modal_pylon_casting"),manual:e,auto:a})}"magic"===t.race.universe&&La.general.multi.push({name:z("universe_magic"),manual:.8,auto:.8}),t.tech.v_train&&La.general.multi.push({name:z("tech_vocational_training"),manual:1,auto:2}),t.genes.crafty&&La.general.multi.push({name:z("tab_arpa_crispr")+" "+z("wiki_arpa_crispr_crafty"),manual:1,auto:1+.5*(t.genes.crafty-1)}),t.race.living_tool&&La.general.multi.push({name:z("trait_living_tool_name"),manual:1,auto:1+Ei.living_tool.vars()[1]/100}),t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=1&&La.general.multi.push({name:z("evo_challenge_orbit_decay"),manual:1,auto:1.1}),t.race.ambidextrous&&La.general.multi.push({name:z("trait_ambidextrous_name"),manual:1,auto:1+Ei.ambidextrous.vars()[1]*t.race.ambidextrous/100}),t.blood.artisan&&La.general.multi.push({name:z("tab_arpa_blood")+" "+z("arpa_blood_artisan_title"),manual:1,auto:1+t.blood.artisan/100});let a=function(){if(t.race.no_plasmid||"antimatter"===t.race.universe){let e=!(!t.race.cataclysm&&!t.race.orbit_decayed);if(e&&t.space.ziggurat&&t.space.ziggurat.count||t.city.temple&&t.city.temple.count){let a=t.tech.anthropology&&t.tech.anthropology>=1?.016:.01;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=t.civic.professor.workers*("antimatter"===t.race.universe?2e-4:4e-4);t.race.high_pop&&(e=ke(e)),a+=e}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?15e-5:t.genes.ancients>=3?125e-6:1e-4;t.race.high_pop&&(e=ke(e)),a+=e*t.civic.priest.workers}"antimatter"===t.race.universe?a/=t.race.nerfed?3:2:t.race.nerfed&&(a/=2),t.race.spiritual&&(a*=1+Ei.spiritual.vars()[0]/100);let r=ts("seraph");return r>0&&(a*=1+Ei.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1.12),t.race.ooze&&(a*=1-Ei.ooze.vars()[1]/100),(e?t.space.ziggurat.count:t.city.temple.count)*a}}return 0}();a>0&&La.general.multi.push({name:z("faith"),manual:1,auto:1+a/("antimatter"===t.race.universe?1.5:3)}),t.prestige.Plasmid.count>0&&La.general.multi.push({name:z("resource_Plasmid_plural_name"),manual:kr()/8+1,auto:kr()/8+1}),t.genes.challenge&&t.genes.challenge>=2&&La.general.multi.push({name:z("mastery"),manual:1+Ts()/(t.race.weak_mastery?50:100),auto:1+Ts()/(t.race.weak_mastery?50:100)})}});var La;function Ea(e){if(e)switch(e){case"market":dr();break;case"storage":pr();break;case"ejector":hr();break;case"supply":gr();break;case"alchemy":fr()}else dr(),pr(),hr(),gr(),fr()}function Ka(e){"market"===e?(Ea("market"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;if(a.resource[e].tradable){var r=$(`
                            `);$("#market").append(r),Va(`#market-${e}`,r,e,t,!0)}})),Ba()):"storage"===e?(Ea("storage"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;if(a.resource[e].stackable){var r=$(`
                            `);$("#resStorage").append(r),er(`#stack-${e}`,r,e,t)}})),Ba()):"ejector"===e?(Ea("ejector"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;Fa[e]&&mr(e,t)}))):"supply"===e?(Ea("supply"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color;Aa[e]&&vr(e,t)}))):"alchemy"===e&&(Ea("alchemy"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let r=a.resource[e].color,i=a.resource[e].tradable;za[e]&&"magic"===t.race.universe&&(t.resource[e].basic=i,yr(e,r,i))})))}function Da(e){if("protoplasm"===t.race.species){let a=100;t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1&&(a+=50*(t.stats.achieve.mass_extinction.l-1)),Ga("RNA",e,a,1,!1),Ga("DNA",e,a,1,!1)}Ga("Money",e,1e3,1,!1,!1,"success"),Ga(t.race.species,e,0,0,!1,!1,"warning"),Ga("Slave",e,0,0,!1,!1,"warning"),Ga("Mana",e,0,1,!1,!1,"warning"),Ga("Energy",e,0,0,!1,!1,"warning"),Ga("Sus",e,0,0,!1,!1,"warning"),Ga("Knowledge",e,100,1,!1,!1,"warning"),Ga("Zen",e,0,0,!1,!1,"warning"),Ga("Crates",e,0,0,!1,!1,"warning"),Ga("Containers",e,0,0,!1,!1,"warning"),Ga("Food",e,250,1,!0,!0),Ga("Lumber",e,200,1,!0,!0),Ga("Chrysotile",e,200,1,!0,!0),Ga("Stone",e,200,1,!0,!0),Ga("Crystal",e,200,1,!0,!0),Ga("Furs",e,100,1,!0,!0),Ga("Copper",e,100,1,!0,!0),Ga("Iron",e,100,1,!0,!0),Ga("Aluminium",e,50,1,!0,!0),Ga("Cement",e,100,1,!0,!0),Ga("Coal",e,50,1,!0,!0),Ga("Oil",e,0,1,!0,!1),Ga("Uranium",e,10,1,!0,!1),Ga("Steel",e,50,1,!0,!0),Ga("Titanium",e,50,1,!0,!0),Ga("Alloy",e,50,1,!0,!0),Ga("Polymer",e,50,1,!0,!0),Ga("Iridium",e,0,1,!0,!0),Ga("Helium_3",e,0,1,!0,!1),Ga("Water",e,0,1,!1,!1,"advanced"),Ga("Deuterium",e,0,1,!1,!1,"advanced"),Ga("Neutronium",e,0,1,!1,!1,"advanced"),Ga("Adamantite",e,0,1,!1,!0,"advanced"),Ga("Infernite",e,0,1,!1,!1,"advanced"),Ga("Elerium",e,1,1,!1,!1,"advanced"),Ga("Nano_Tube",e,0,1,!1,!1,"advanced"),Ga("Graphene",e,0,1,!1,!0,"advanced"),Ga("Stanene",e,0,1,!1,!0,"advanced"),Ga("Bolognium",e,0,1,!1,!0,"advanced"),Ga("Vitreloy",e,0,1,!1,!0,"advanced"),Ga("Orichalcum",e,0,1,!1,!0,"advanced"),Ga("Unobtainium",e,0,1,!1,!1,"advanced"),Ga("Materials",e,0,1,!1,!1,"advanced"),Ga("Horseshoe",e,-2,0,!1,!1,"advanced"),Ga("Nanite",e,0,1,!1,!1,"advanced"),Ga("Genes",e,-2,0,!1,!1,"advanced"),Ga("Soul_Gem",e,-2,0,!1,!1,"advanced"),Ga("Plywood",e,-1,0,!1,!1,"danger"),Ga("Brick",e,-1,0,!1,!1,"danger"),Ga("Wrought_Iron",e,-1,0,!1,!1,"danger"),Ga("Sheet_Metal",e,-1,0,!1,!1,"danger"),Ga("Mythril",e,-1,0,!1,!1,"danger"),Ga("Aerogel",e,-1,0,!1,!1,"danger"),Ga("Nanoweave",e,-1,0,!1,!1,"danger"),Ga("Scarletite",e,-1,0,!1,!1,"danger"),Ga("Quantium",e,-1,0,!1,!1,"danger"),Ga("Corrupt_Gem",e,-2,0,!1,!1,"caution"),Ga("Codex",e,-2,0,!1,!1,"caution"),Ga("Cipher",e,0,1,!1,!1,"caution"),Ga("Demonic_Essence",e,-2,0,!1,!1,"caution"),e||(Ra("Blood_Stone","caution"),Ra("Artifact","caution"),Ra("Plasmid"),Ra("AntiPlasmid"),Ra("Phage"),Ra("Dark"),Ra("Harmony"),Ra("AICore"))}function Ba(){"protoplasm"!==t.race.species&&(function(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=t.race.no_trade?" nt":"";var a=$(`
                            ${z("resource_market_trade_routes")} / {{ mtrade }}
                            `);a.append($(`${z("cancel_all_routes")}`)),$("#market").append(a),Cs({el:"#tradeTotal",data:t.city.market,methods:{zero(){Object.keys(t.resource).forEach((function(e){t.resource[e].trade&&(t.city.market.trade-=Math.abs(t.resource[e].trade),t.resource[e].trade=0,rr(e))}))}},filters:{tdeCnt(e){let a=Qs(17,11);return(100===e&&!t.tech.isolation&&!t.race.cataclysm||10===e&&(t.tech.isolation||t.race.cataclysm))&&a.length>0?"10"+a:e}}}),ls("tradeTotalPopover",(function(){let e=$('
                            ');return r.hasOwnProperty("t_route")&&Object.keys(r.t_route).forEach((function(t){r.t_route[t]>0&&e.append(``)})),e.append(``),e}),{elm:"#tradeTotalPopover > span"})}(),(t.settings.tabLoad||4===t.settings.civTabs&&0===t.settings.marketTabs)&&($("#market").append($(`

                            ${z("galaxy_trade")}

                            `)),Qa()),function(){if(t.settings.tabLoad||4===t.settings.civTabs&&1===t.settings.marketTabs){var e=$(`
                            ${z("resource_Crates_name")}{{ cr.amount }} / {{ cr.max }}${z("resource_Containers_name")}{{ cn.amount }} / {{ cn.max }}
                            `);$("#resStorage").append(e),Cs({el:"#crateTotal",data:{cr:t.resource.Crates,cn:t.resource.Containers}})}}())}function Ga(e,r,i,s,n,c,o){if(o=o||"info",t.resource[e]||(t.resource[e]={}),Na(e),t.race.artifical&&"Food"===e&&(c=!1),r)return;var l;t.resource[e].hasOwnProperty("display")||(t.resource[e].display=!1),t.resource[e].hasOwnProperty("value")||(t.resource[e].value=t.race.truepath?2*Ca[e]:Ca[e]),t.resource[e].hasOwnProperty("amount")||(t.resource[e].amount=0),t.resource[e].hasOwnProperty("max")||(t.resource[e].max=i),t.resource[e].hasOwnProperty("diff")||(t.resource[e].diff=0),t.resource[e].hasOwnProperty("delta")||(t.resource[e].delta=0),t.resource[e].hasOwnProperty("rate")||(t.resource[e].rate=s),"Mana"===e&&(t.resource[e].gen=0,t.resource[e].gen_d=0),t.resource[e].stackable=c,t.resource[e].crates||(t.resource[e].crates=0),t.resource[e].containers||(t.resource[e].containers=0),!t.resource[e].trade&&n&&(t.resource[e].trade=0),l=-1===t.resource[e].max||-2===t.resource[e].max?$(`

                            {{ name | namespace }}

                            {{ amount | diffSize }}
                            `):$(`

                            {{ name | namespace }}

                            {{ amount | size }} / {{ max | size }}
                            `),c?l.append($(`+`)):(-1!==i||-1===i&&0===s&&t.race.no_craft||"Scarletite"===e||"Quantium"===e)&&l.append($(""));let _=!1;if(0!==s||-1===i&&0===s&&t.race.no_craft||"Scarletite"===e||"Quantium"===e)l.append($(`{{ diff | diffSize }} /s`));else if(-1!==i||t.race.no_craft||"Scarletite"===e||"Quantium"===e)l.append($(""));else{let t=$('');l.append(t);let a=[1,5];for(let r=0;r+${a[r]}
                            `));t.append($(`+A`)),_=!0}$("#resources").append(l);var d={template:''};if(Cs({el:`#res${e}`,data:t.resource[e],filters:{size:function(e){return e?x(e,0):e},diffSize:function(a){return"Horseshoe"===e&&!t.race.hooved&&cn("fool",2023)&&(a=5),x(a,2)},namespace:e=>e.replace("_"," ")},methods:{resRate:e=>`${e} ${x(t.resource[e].diff,2)} per second`,trigModal(){this.$buefy.modal.open({parent:this,component:d});var a=setInterval((function(){$("#modalBox").length>0&&(clearInterval(a),function(e){$("#modalBox").append($('

                            {{ name }} - {{ amount | size }}/{{ max | size }}

                            '));let a=$('
                            ');if($("#modalBox").append(a),"Food"===e&&!t.race.artifical||t.race.artifical&&"Coal"===e){let e=Qs(7,10);e.length>0&&$("#modalBoxTitle").prepend(e)}if("Stone"===e){let e=Js(1,12,!1);e.length>0&&$("#modalBoxTitle").prepend(e)}let r=$('
                            ');a.append(r),r.append($(`
                            ${z("resource_modal_crate_owned")} {{ crates.amount }}/{{ crates.max }}${z("resource_modal_crate_assigned")} {{ res.crates }}
                            `));let i=$(``),s=$(``),n=$(``);if(r.append(i),r.append(s),r.append(n),Cs({el:"#modalCrates",data:{crates:t.resource.Crates,res:t.resource[e]},methods:{buildCrate(){cr()},subCrate(e){Ja(e)},addCrate(e){Za(e)}}}),t.resource.Containers.display){let r=$('
                            ');a.append(r),r.append($(`
                            ${z("resource_modal_container_owned")} {{ containers.amount }}/{{ containers.max }}${z("resource_modal_container_assigned")} {{ res.containers }}
                            `));let i=$(``),s=$(``),n=$(``);r.append(i),r.append(s),r.append(n),Cs({el:"#modalContainers",data:{containers:t.resource.Containers,res:t.resource[e]},methods:{buildContainer(){or()},removeContainer(e){Xa(e)},addContainer(e){Ya(e)}}})}Cs({el:"#modalBoxTitle",data:t.resource[e],filters:{size:function(e){return x(e,0)},diffSize:function(e){return x(e,2)}}}),["modalCrates","modalContainers"].forEach((function(e){["assign","unassign","construct"].forEach((function(t){ls(`${e}${t}`,function(e,t){if("modalContainers"===e){let e=_r();switch(t){case"assign":return z("resource_modal_container_assign_desc",[e]);case"unassign":return z("resource_modal_container_unassign_desc",[e]);case"construct":return sr()}}else{let e=lr();switch(t){case"assign":return z("resource_modal_crate_assign_desc",[e]);case"unassign":return z("resource_modal_crate_unassign_desc",[e]);case"construct":return ir()}}}(e,t),{elm:$(`#${e} > .${t}`),attach:"#main"})}))}))}(e))}),50)},showTrigger:()=>t.resource.Crates.display,craft(e,a){if(!t.race.no_craft){let r=Ta(e,"manual").multiplier,i=Ia(),s=Math.floor(t.resource[i[e][0].r].amount/i[e][0].a);for(let a=1;a${t.resource[i[e][s].r].name} ${n}`}return r}}}),ar(`cnt${e}`,e,"c"),_){let a=[1,5,"A"];for(let r=0;r"),s=e,n=a[r],c=+(100*Ta(s,"manual").multiplier).toFixed(0);i.append($(`
                            ${z("manual_crafting_hover_bonus",[c.toLocaleString(),t.resource[s].name])}
                            `));let o=Ia(),l=$(`
                            ${z("manual_crafting_hover_craft")}
                            `),_=0;if("number"!=typeof n){if(_=t.resource[o[s][0].r].amount/o[s][0].a,o[s].length>1)for(let e=1;e${x(c/100*_,1)} ${t.resource[s].name}`))}else{_=y()*n;let e=x(c/100*_,1);l.append($(`${e} ${t.resource[s].name}`))}let d=$(`
                            ${z("manual_crafting_hover_use")}
                            `);for(let e=0;e${x(_*o[s][e].a,1)} ${t.resource[o[s][e].r].name}`)),e+1, "));return i.append(l),i.append(d),i};tr(`inc${e}${a[r]}`,e,"manual",i)}}c&&ls(`con${e}`,(function(){var a=$(`
                            ${z("resource_Crates_plural")} ${t.resource[e].crates}
                            `);return t.tech.steel_container&&a.append($(`
                            ${z("resource_Containers_plural")} ${t.resource[e].containers}
                            `)),a})),e!==t.race.species&&"Crates"!==e&&"Containers"!==e&&-1!==i?ar(`inc${e}`,e,"p"):-1===i&&tr(`inc${e}`,e,"auto"),$(`#res${e}`).on("mouseover",(function(){$(`.res-${e}`).each((function(){t.resource[e].amount>=$(this).attr(`data-${e}`)?$(this).addClass("hl-ca"):$(this).addClass("hl-cna")}))})),$(`#res${e}`).on("mouseout",(function(){$(`.res-${e}`).each((function(){$(this).removeClass("hl-ca"),$(this).removeClass("hl-cna")}))})),void 0===a.resource&&(a.resource={}),a.resource[e]={color:o,tradable:n,stackable:c}}function Na(e){if(e===t.race.species?t.resource[e].name=nn("name"):t.resource[e].name="Money"===e?"$":z(`resource_${e}_name`),cn("fool",2022))switch(e){case"Lumber":t.resource[e].name=z("resource_Stone_name");break;case"Stone":t.resource[e].name=z("resource_Lumber_name");break;case"Copper":t.resource[e].name=z("resource_Iron_name");break;case"Iron":t.resource[e].name=z("resource_Copper_name");break;case"Steel":t.resource[e].name=z("resource_Titanium_name");break;case"Titanium":t.resource[e].name=z("resource_Steel_name");break;case"Coal":t.resource[e].name=z("resource_Oil_name");break;case"Oil":t.resource[e].name=z("resource_Coal_name");break;case"Alloy":t.resource[e].name=z("resource_Polymer_name");break;case"Polymer":t.resource[e].name=z("resource_Alloy_name");break;case"Graphene":t.resource[e].name=z("resource_Stanene_name");break;case"Stanene":t.resource[e].name=z("resource_Graphene_name");break;case"Plywood":t.resource[e].name=z("resource_Brick_name");break;case"Brick":t.resource[e].name=z("resource_Plywood_name");break;case"Genes":t.resource[e].name=z("resource_Soul_Gem_name");break;case"Soul_Gem":t.resource[e].name=z("resource_Genes_name");break;case"Slave":t.resource[e].name=z("resource_Peon_name")}if("Horseshoe"===e&&(t.resource[e].name=hn()),t.race.artifical&&"Genes"===e&&(t.resource[e].name=z("resource_Program_name")),t.race.sappy)"Stone"===e&&(t.resource[e].name=z("resource_Amber_name"));else if(t.race.flier)switch(e){case"Stone":t.resource[e].name=z("resource_Clay_name");break;case"Brick":t.resource[e].name=z("resource_Mud_Brick_name")}if(t.race.soul_eater&&"Food"===e&&(t.resource[e].name=z("resource_Souls_name")),t.race.evil)switch(e){case"Lumber":t.resource[e].name=z("resource_Bones_name");break;case"Furs":t.resource[e].name=z("resource_Flesh_name");break;case"Plywood":t.resource[e].name=z("resource_Boneweave_name")}if(t.race.artifical&&"Food"===e&&(t.resource[e].name=z("resource_Signal_name")),cn("halloween").active)switch(e){case"Food":t.resource[e].name=z("resource_Candy_name");break;case"Lumber":t.resource[e].name=z("resource_Bones_name");break;case"Stone":t.resource[e].name=z("resource_RockCandy_name");break;case"Furs":t.resource[e].name=z("resource_Webs_name");break;case"Plywood":t.resource[e].name=z("resource_Boneweave_name");break;case"Brick":t.resource[e].name=z("resource_Tombstone_name");break;case"Soul_Gem":t.resource[e].name=z("resource_CandyCorn_name")}}function Ra(e,a){if($(`#res${e}`).length){let t=$(`#res${e}`);return t.detach(),void $("#resources").append(t)}a=a||"special";var r=$(`
                            ${z(`resource_${e}_name`)}{{ count | round }}
                            `);$("#resources").append(r),Cs({el:`#res${e}`,data:t.prestige[e],filters:{round:e=>+e.toFixed(3)}}),"Artifact"!==e&&"Blood_Stone"!==e&&ls(`res${e}`,(function(){let a=$("
                            ");switch(e){case"Plasmid":let r=t.race.no_plasmid?Math.min(t.race.p_mutation,t.prestige.Plasmid.count):t.prestige.Plasmid.count;if(a.append($(`${z(`resource_${e}_desc`,[r,+(100*kr("plasmid")).toFixed(2)])}`)),t.genes.store&&("antimatter"!==t.race.universe||t.genes.bleed>=3)){let e=br(1,"plasmid");e>1&&a.append($(` ${z("resource_Plasmid_desc2",[+(100*(e-1)).toFixed(2)])}`))}break;case"AntiPlasmid":a.append($(`${z(`resource_${e}_desc`,[t.prestige.AntiPlasmid.count,+(100*kr("antiplasmid")).toFixed(2)])}`));let i=br(1,"anti");t.genes.store&&("antimatter"===t.race.universe||t.genes.bleed>=3)&&i>1&&a.append($(` ${z("resource_Plasmid_desc2",[+(100*(i-1)).toFixed(2)])}`));break;case"Phage":a.append($(`${z(t.prestige.AntiPlasmid.count>0?"resource_Phage_desc2":"resource_Phage_desc",[250+t.prestige.Phage.count])}`));let s=br(1,"phage");t.genes.store&&t.genes.store>=4&&s>1&&a.append($(` ${z("resource_Plasmid_desc2",[+(100*(s-1)).toFixed(2)])}`));break;case"Dark":switch(t.race.universe){case"standard":a.append($(`${z(`resource_${e}_desc_s`,[+(100*(Is("standard")-1)).toFixed(2)])}`));break;case"evil":a.append($(`${z(`resource_${e}_desc_e`,[+(100*(Is("evil")-1)).toFixed(2)])}`));break;case"micro":a.append($(`${z(`resource_${e}_desc_m`,[Is("micro",!1),Is("micro",!0)])}`));break;case"heavy":let t=Is("heavy"),r=.25+.5*t,i=.2+.3*t;a.append($(`${z(`resource_${e}_desc_h`,[+(100*r).toFixed(4),+(100*i).toFixed(4)])}`));break;case"antimatter":a.append($(`${z(`resource_${e}_desc_a`,[+(100*(Is("antimatter")-1)).toFixed(2)])}`));break;case"magic":a.append($(`${z(`resource_${e}_desc_mg`,[z("resource_Mana_name"),+(100*(Is("magic")-1)).toFixed(2)])}`))}break;case"Harmony":a.append($(`${z(`resource_${e}_desc`,["standard"===t.race.universe?.1:1,js()])}`));break;case"AICore":let n=+(100*(1-.99**t.prestige.AICore.count)).toFixed(2);a.append($(`${z(`resource_${e}_desc`,[n])}`))}return a}))}function Ha(e){let a=t.tech.currency>=6?-1e6:t.tech.currency>=4?-100:-25;if(t.race.banana){let r=!1;if(Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&t.resource[e].trade<0&&(r=e)})),r&&r!==e)return!1;a=t.tech.currency>=6?-1e6:t.tech.currency>=4?-25:-10}return!(t.resource[e].trade<=a)}function Ua(e){let a=t.tech.currency>=6?1e6:t.tech.currency>=4?100:25;return!(t.resource[e].trade>=a)}function Va(e,a,r,i,s){if((t.settings.tabLoad||4===t.settings.civTabs&&0===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==r)){if(s&&a.append($(`

                            {{ r.name | namespace }}

                            `)),t.race.no_trade||(a.append($(`${z("resource_market_buy")}`)),a.append($(`\${{ r.value | buy }}`)),a.append($(`${z("resource_market_sell")}`)),a.append($(`\${{ r.value | sell }}`))),s&&(t.race.banana&&"Food"===r||t.tech.trade&&!t.race.terrifying)){let e=$(`${z("resource_market_routes")}`);a.append(e),e.append($(`-`)),e.append($('')),e.append($(`+`)),e.append($(`${z("cancel_routes")}`)),rr(r)}Cs({el:e,data:{r:t.resource[r],m:t.city.market},methods:{aSell(e){let a=1===za[e]?z("resource_market_unit"):z("resource_market_units"),r=function(e){let a=4;t.race.merchant&&(a*=1-Ei.merchant.vars()[0]/100);let r=ts("goblin");r>0&&(a*=1-Ei.merchant.vars(1)[0]/100*r),t.race.asymmetrical&&(a*=1+Ei.asymmetrical.vars()[0]/100),t.race.conniving&&a--;let i=t.resource[e].value*za[e]/a;if(t.city.wharf&&(i*=1+.01*t.city.wharf.count),t.space.gps&&t.space.gps.count>3&&(i*=1+.01*t.space.gps.count),t.tech.railway){let e=t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?.03:.02;i*=1+t.tech.railway*e}return t.race.truepath&&!t.race.lone_survivor&&(i*=1-t.civic.foreign.gov3.hstl/101),t.race.inflation&&(i*=1+t.race.inflation/500),t.race.witch_hunter&&t.resource.Sus.amount>50&&(i*=1-(t.resource.Sus.amount-50)/52),i*=$e("psychic_cash"),i=+i.toFixed(1),i}(e),i=za[e];if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),i*=1-e/100}return i=+i.toFixed(3),z("resource_market_auto_sell_desc",[i,a,r])},aBuy(e){let a=za[e],r=K("dealmaker",0);r&&(a*=1+r/100),t.race.persuasive&&(a*=1+t.race.persuasive/100),t.race.merchant&&(a*=1+Ei.merchant.vars()[1]/100);let i=ts("goblin");if(i>0&&(a*=1+Ei.merchant.vars(1)[1]/100*i),t.genes.trader&&(a*=1+Ts()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1+e/50}t.race.truepath&&(a*=1-t.civic.foreign.gov3.hstl/101),a=+a.toFixed(3);let s=z(1===a?"resource_market_unit":"resource_market_units"),n=function(e){let a=t.resource[e].value;t.race.arrogant&&(a*=1+Ei.arrogant.vars()[0]/100),t.race.conniving&&(a*=1-Ei.conniving.vars()[0]/100);let r=ts("imp");r>0&&(a*=1-Ei.conniving.vars(1)[0]/100*r);let i=a*za[e];return t.city.wharf&&(i*=.99**t.city.wharf.count),t.space.gps&&t.space.gps.count>3&&(i*=.99**t.space.gps.count),t.tech.railway&&(i*=(t.stats.achieve.banana&&t.stats.achieve.banana.l>=1?.97:.98)**t.tech.railway),t.race.truepath&&!t.race.lone_survivor&&(i*=1+t.civic.foreign.gov3.hstl/101),t.race.inflation&&(i*=1+t.race.inflation/300),t.race.quarantine&&(i*=1+Math.round(t.race.quarantine**3.5)),t.race.witch_hunter&&t.resource.Sus.amount>50&&(i*=1+(t.resource.Sus.amount-50)/8),i=+i.toFixed(1),i}(e);return z("resource_market_auto_buy_desc",[a,s,n])},purchase(e){if(!t.race.no_trade&&!t.settings.pause){let a=t.city.market.qty,r=t.resource[e].value;t.race.arrogant&&(r*=1+Ei.arrogant.vars()[0]/100),t.race.conniving&&(r*=1-Ei.conniving.vars()[0]/100);let i=ts("imp");i>0&&(r*=1-Ei.conniving.vars(1)[0]/100*i);let s=Math.floor(Math.min(a,t.resource.Money.amount/r,t.resource[e].max-t.resource[e].amount));s>0&&(t.resource[e].amount+=s,t.resource.Money.amount-=Math.round(r*s),t.resource[e].value+=Number((s/Math.rand(1e3,1e4)).toFixed(2)))}},sell(e){if(!t.race.no_trade&&!t.settings.pause){let a=t.city.market.qty,r=4;t.race.merchant&&(r*=1-Ei.merchant.vars()[0]/100);let i=ts("goblin");i>0&&(r*=1-Ei.merchant.vars(1)[0]/100*i),t.race.asymmetrical&&(r*=1+Ei.asymmetrical.vars()[0]/100),t.race.conniving&&(r*=1-Ei.conniving.vars()[1]/100);let s=ts("imp");s>0&&(r*=1-Ei.conniving.vars(1)[1]/100*s);let n=t.resource[e].value/r,c=Math.floor(Math.min(a,t.resource[e].amount,(t.resource.Money.max-t.resource.Money.amount)/n));c>0&&(t.resource[e].amount-=c,t.resource.Money.amount+=Math.round(n*c),t.resource[e].value-=Number((c/Math.rand(1e3,1e4)).toFixed(2)),t.resource[e].value0&&(a+=t.resource[r].trade)})),e<=a)break}if(t.resource[e].trade>=0){if(!(Ua(e)&&t.city.market.trade(t.race.arrogant&&(e*=1+Ei.arrogant.vars()[0]/100),x(e*t.city.market.qty,0)),sell(e){let a=4;t.race.merchant&&(a*=1-Ei.merchant.vars()[0]/100);let r=ts("goblin");return r>0&&(a*=1-Ei.merchant.vars(1)[0]/100*r),t.race.asymmetrical&&(a*=1+Ei.asymmetrical.vars()[0]/100),x(e*t.city.market.qty/a,0)},trade(e){if("Stone"===r&&(31===e||-31===e)){let e=Js(3,12,!1);if(e.length>0)return e}return e<0?"-"+(e=0-e):e>0?`+${e}`:0},namespace:e=>e.replace("_"," ")}})}}function Wa(){return[{buy:{res:"Deuterium",vol:5},sell:{res:"Helium_3",vol:25}},{buy:{res:"Neutronium",vol:2.5},sell:{res:"Copper",vol:200}},{buy:{res:"Adamantite",vol:3},sell:{res:"Iron",vol:300}},{buy:{res:"Elerium",vol:1},sell:{res:"Oil",vol:125}},{buy:{res:"Nano_Tube",vol:10},sell:{res:"Titanium",vol:20}},{buy:{res:"Graphene",vol:25},sell:{res:t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Lumber",vol:1e3}},{buy:{res:"Stanene",vol:40},sell:{res:"Aluminium",vol:800}},{buy:{res:"Bolognium",vol:.75},sell:{res:"Uranium",vol:4}},{buy:{res:"Vitreloy",vol:1},sell:{res:"Infernite",vol:1}}]}function Qa(e){let a=e||$("#galaxyTrade");if(e||Ss($("#galaxyTrade")),t.galaxy.trade){a.append($(`
                            ${z("galaxy_trade")}
                            `));let e=Wa();for(let r=0;r');a.append(i),i.append($(`${t.resource[e[r].buy.res].name}`)),i.append($(`+{{ '${r}' | t_vol }}/s`)),i.append($(`${t.resource[e[r].sell.res].name}`)),i.append($(`-{{ '${r}' | s_vol }}/s`));let s=$(`${z("resource_market_routes")}`);i.append(s);let n=z("galaxy_freighter_assign",[t.resource[e[r].buy.res].name,t.resource[e[r].sell.res].name]),c=z("galaxy_freighter_unassign",[t.resource[e[r].buy.res].name,t.resource[e[r].sell.res].name]);s.append($(`-`)),s.append($(`{{ g.f${r} }}`)),s.append($(`+`)),s.append($(`${z("cancel_routes")}`))}let r=$(`
                            ${z("resource_market_galactic_trade_routes")} {{ g.cur }} / {{ g.max }}
                            `);r.append($(`${z("cancel_all_routes")}`)),a.append(r)}Cs({el:e?"#specialModal":"#galaxyTrade",data:{g:t.galaxy.trade,t:t.tech},methods:{less(e){let a=y();t.galaxy.trade[`f${e}`]>=a?(t.galaxy.trade[`f${e}`]-=a,t.galaxy.trade.cur-=a):(t.galaxy.trade.cur-=t.galaxy.trade[`f${e}`],t.galaxy.trade[`f${e}`]=0)},more(e){let a=y();t.galaxy.trade.curt.galaxy.trade.max-t.galaxy.trade.cur&&(a=t.galaxy.trade.max-t.galaxy.trade.cur),t.galaxy.trade[`f${e}`]+=a,t.galaxy.trade.cur+=a)},zero(e){if(e)t.galaxy.trade.cur-=t.galaxy.trade[`f${e}`],t.galaxy.trade[`f${e}`]=0;else{let e=Wa();for(let a=0;ae},filters:{t_vol(e){let a=Wa()[e].buy.vol;t.race.persuasive&&(a*=1+t.race.persuasive/100),t.race.merchant&&(a*=1+Ei.merchant.vars()[1]/100);let r=ts("goblin");if(r>0&&(a*=1+Ei.merchant.vars(1)[1]/100*r),t.genes.trader&&(a*=1+Ts()/100),t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1+e/50}return a=+a.toFixed(2),a},s_vol(e){let a=Wa()[e].sell.vol;if(t.stats.achieve.hasOwnProperty("trade")){let e=t.stats.achieve.trade.l;e>5&&(e=5),a*=1-e/100}return a=+a.toFixed(2),a}}}),ls("galacticTradeTotal",(function(){let e=$('
                            ');return r.hasOwnProperty("gt_route")&&Object.keys(r.gt_route).forEach((function(t){r.gt_route[t]>0&&e.append(``)})),e.append(``),e}),{elm:"#galacticTradeTotal > span"})}function Ja(e){let a=y(),r=lr();a>t.resource[e].crates&&(a=t.resource[e].crates),a>0&&(t.resource.Crates.amount+=a,t.resource.Crates.max+=a,t.resource[e].crates-=a,t.resource[e].max-=r*a)}function Za(e){let a=y(),r=lr();a>t.resource.Crates.amount&&(a=t.resource.Crates.amount),a>0&&(t.resource.Crates.amount-=a,t.resource.Crates.max-=a,t.resource[e].crates+=a,t.resource[e].max+=r*a)}function Xa(e){let a=y(),r=_r();a>t.resource[e].containers&&(a=t.resource[e].containers),a>0&&(t.resource.Containers.amount+=a,t.resource.Containers.max+=a,t.resource[e].containers-=a,t.resource[e].max-=r*a)}function Ya(e){let a=y(),r=_r();a>t.resource.Containers.amount&&(a=t.resource.Containers.amount),a>0&&(t.resource.Containers.amount-=a,t.resource.Containers.max-=a,t.resource[e].containers+=a,t.resource[e].max+=r*a)}function er(e,a,r,i){if(t.settings.tabLoad||4===t.settings.civTabs&&1===t.settings.marketTabs){if(a.append($(`

                            {{ name }}

                            `)),t.resource.Crates.display){let e=$(`${z("resource_Crates_name")}`);a.append(e),e.append($(`«`)),e.append($(``)),e.append($(`»`))}if(t.resource.Containers.display){let e=$(`${z("resource_Containers_name")}`);a.append(e),e.append($(`«`)),e.append($('')),e.append($(`»`))}Cs({el:e,data:t.resource[r],methods:{addCrate(e){Za(e)},subCrate(e){Ja(e)},addCon(e){Ya(e)},subCon(e){Xa(e)}},filters:{trick(e){if("Stone"===r&&10===t.resource[r].crates&&31===t.resource[r].containers){let e=Js(4,13,!0);if(e.length>0)return e}return e},cCnt(e,a){if("Food"===a&&!t.race.artifical||t.race.artifical&&"Coal"===a){let t=Qs(13,10);if(10===e&&t.length>0)return"1"+t}return e}}})}}function tr(e,a,i,s){ls(`${e}`,(function(){let e=$('
                            {{ res.name | namespace }}
                            '),n=$('
                            ');e.append(n);let c=Ta(a,i),o=$("
                            ");n.append(o),"auto"===i&&r.p[a]&&Object.keys(r.p[a]).forEach((function(e){let t=r.p[a][e],i=parseFloat(t.slice(0,-1));if(0!=i&&!isNaN(i)){let t=i>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),o.append(``)}})),Object.keys(c.multi_bd).forEach((function(e){let t=c.multi_bd[e],a=parseFloat(t.slice(0,-1));if(0!=a&&!isNaN(a)){let t=a>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),o.append(``)}}));let l=$('
                            '),_=$(`
                            ${z("craft_tools_multi")}
                            `);l.append(_);let d=0;if(Object.keys(c.add_bd).forEach((function(e){let t=c.add_bd[e],a=parseFloat(t.slice(0,-1));if(0!=a&&!isNaN(a)){d++;let t=a>0?"success":"danger",r=e.replace(/\+.+$/,"");e=e.replace(/'/g,"\\'"),l.append(``)}})),d>0&&n.append(l),r.p.consume&&r.p.consume[a]){let e=$('
                            '),t=0;Object.keys(r.p.consume[a]).forEach((function(i){let s=r.p.consume[a][i];if(0!=s&&!isNaN(s)){t++;let r=s>0?"success":"danger",n=i.replace(/\+.+$/,"");i=i.replace(/'/g,"\\'"),e.append(``)}})),t>0&&n.append(e)}return t.resource[a].diff<0&&t.resource[a].amount>0&&e.append(``),s&&(e.append(''),e.append(s)),e}),{in:function(){Cs({el:"#popper > div",data:{[a]:r.p[a],res:t.resource[a],consume:r.p.consume,craft:Ta(a,i)},filters:{translate(e){let t=e[e.length-1],a=parseFloat(e.slice(0,-1)),r=a>0&&a<1||a<0&&a>-1?4:a>0&&a<10||a<0&&a>-10?3:2;a=+a.toFixed(r);let i="%"===t?"%":"";return a>0?"+"+x(a,r)+i:a<0?x(a,r)+i:void 0},fix:e=>e+"v",counter(e){let r=+(e/-t.resource[a].diff).toFixed(0);if(r>60){let e=r%60,t=(r-e)/60;if(t>=60){let e=t%60;return`${(t-e)/60}h ${e}m`}return`${t}m ${e}s`}return`${r}s`},namespace:e=>e.replace("_"," ")}})},out:function(){Cs({el:"#popper > div"},"destroy")},classes:"breakdown has-background-light has-text-dark",prop:{modifiers:{preventOverflow:{enabled:!1},hide:{enabled:!1}}}})}function ar(e,a,i){ls(`${e}`,(function(){let e=$('
                            {{ res.name | namespace }}
                            '),s=$('
                            ');e.append(s);let n=!1;if(r[i][a]){let e=$("
                            ");s.append(e);let t=[a];t.push("Global");for(var c=0;c0?"success":"danger",i=t.replace(/\+.+$/,"");t=t.replace(/'/g,"\\'"),e.append(``)}}))}}if(r[i].consume&&r[i].consume[a]){let e=$(`
                            `),t=0;Object.keys(r[i].consume[a]).forEach((function(s){let n=r[i].consume[a][s];if(0!=n&&!isNaN(n)){t++;let r=n>0?"success":"danger",i=s.replace(/\+.+$/,"");s=s.replace(/'/g,"\\'"),e.append(``)}})),t>0&&s.append(e)}if("p"===i){let r=t.resource[a].diff>0?"success":"danger";e.append(``)}return e}),{in:function(){Cs({el:"#popper > div",data:{Global:r[i].Global,[a]:r[i][a],consume:r[i].consume,res:t.resource[a]},filters:{translate(e){let t=e[e.length-1],a=parseFloat(e.slice(0,-1)),r=a>0&&a<1||a<0&&a>-1?4:a>0&&a<10||a<0&&a>-10?3:2,i="%"===t?"%":"";return a>0?"+"+x(a,r)+i:a<0?x(a,r)+i:void 0},fix:e=>e+"v",counter(e){let r=t.resource[a].diff,i=0;if(r<0?(r*=-1,i=+(e/r).toFixed(0)):i=+((t.resource[a].max-e)/r).toFixed(0),i===1/0||Number.isNaN(i))return"Never";if(i>60){let e=i%60,t=(i-e)/60;if(t>=60){let e=t%60;return`${(t-e)/60}h ${e}m`}return`${t}m ${e}s`}return`${i}s`},direction:e=>z(e>=0?"to_full":"to_empty"),namespace:e=>e.replace("_"," ")}})},out:function(){Cs({el:"#popper > div"},"destroy")},classes:"breakdown has-background-light has-text-dark",prop:{modifiers:{preventOverflow:{enabled:!1},hide:{enabled:!1}}}})}function rr(e){$(`#market-${e} .trade .current`).removeClass("has-text-warning"),$(`#market-${e} .trade .current`).removeClass("has-text-danger"),$(`#market-${e} .trade .current`).removeClass("has-text-success"),t.resource[e].trade>0?$(`#market-${e} .trade .current`).addClass("has-text-success"):t.resource[e].trade<0?$(`#market-${e} .trade .current`).addClass("has-text-danger"):$(`#market-${e} .trade .current`).addClass("has-text-warning")}function ir(){let e=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?t.resource.Chrysotile.name:t.resource.Stone.name:t.resource.Plywood?t.resource.Plywood.name:z("resource_Plywood_name");return z("resource_modal_crate_construct_desc",[t.race.kindling_kindred||t.race.smoldering?200:10,e,lr()])}function sr(){return z("resource_modal_container_construct_desc",[125,_r()])}function nr(e,t){switch(e){case"crate":cr(t);break;case"container":or(t)}}function cr(e){let a=e||y(),r=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood",i=t.race.kindling_kindred||t.race.smoldering?200:10;a+t.resource.Crates.amount>t.resource.Crates.max&&(a=t.resource.Crates.max-t.resource.Crates.amount),t.resource[r].amount=i*a&&t.resource.Crates.amountt.resource.Containers.max&&(a=t.resource.Containers.max-t.resource.Containers.amount),t.resource.Steel.amount<125*a&&(a=Math.floor(t.resource.Steel.amount/125)),t.resource.Steel.amount>=125*a&&t.resource.Containers.amount=2?500:350;t.tech.container&&t.tech.container>=4&&(e+=t.tech.container>=5?500:250),t.tech.container&&t.tech.container>=6&&(e+=t.tech.container>=7?1200:500),t.tech.container&&t.tech.container>=8&&(e+=4e3),t.race.pack_rat&&(e*=1+Ei.pack_rat.vars()[0]/100);let a=ts("kobold");return a>0&&(e*=1+Ei.pack_rat.vars(1)[0]/100*a),t.stats.achieve.banana&&t.stats.achieve.banana.l>=3&&(e*=1.1),e*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,Math.round(br(e))}function _r(){let e=t.tech.steel_container&&t.tech.steel_container>=3?1200:800;t.tech.steel_container&&t.tech.steel_container>=4&&(e+=t.tech.steel_container>=5?1e3:400),t.tech.steel_container&&t.tech.steel_container>=6&&(e+=t.tech.steel_container>=7?7500:1e3),t.tech.steel_container&&t.tech.steel_container>=8&&(e+=8e3),t.race.pack_rat&&(e*=1+Ei.pack_rat.vars()[0]/100);let a=ts("kobold");return a>0&&(e*=1+Ei.pack_rat.vars(1)[0]/100*a),e*=t.stats.achieve.blackhole?1+.05*t.stats.achieve.blackhole.l:1,Math.round(br(e))}function dr(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=$(`

                            ${z("resource_market")}

                            `);Ss($("#market")),$("#market").append(e),function(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||0!==t.settings.marketTabs))return;let e=$("#market-qty");Ss(e),t.race.no_trade||(e.append($(`

                            ${z("resource_trade_qty")}

                            `)),e.append($('-+'))),Cs({el:"#market-qty",data:t.city.market,methods:{val(){t.city.market.qty<1?t.city.market.qty=1:t.city.market.qty>ur()&&(t.city.market.qty=ur())},limit:()=>ur(),less(){t.city.market.qty-=y()},more(){t.city.market.qty+=y()}}})}()}function pr(){if(!t.settings.tabLoad&&(4!==t.settings.civTabs||1!==t.settings.marketTabs))return;let e=$(`

                            ${z("tab_storage")}

                            `);Ss($("#resStorage")),$("#resStorage").append(e),t.resource.Crates&&t.resource.Containers&&(e.append($(``)),e.append($(``)),Cs({el:"#createHead",data:{cr:t.resource.Crates,cn:t.resource.Containers},methods:{crate(){cr()},container(){or()},buildCrateDesc:()=>ir(),buildContainerDesc:()=>sr()}}))}function ur(){return t.tech.currency>=6?1e6:t.tech.currency>=4?5e3:100}function hr(){if((t.settings.tabLoad||4===t.settings.civTabs&&2===t.settings.marketTabs)&&(Ss($("#resEjector")),t.interstellar.mass_ejector)){let e=$(`

                            ${z("interstellar_mass_ejector_vol")}

                            `);$("#resEjector").append(e);let a=$('');e.append(a),a.append($(`{{ total }} / {{ on | max }}{{ on | real }}${z("interstellar_mass_ejector_mass")}: {{ mass | approx }} kt/s`)),Cs({el:"#eject",data:t.interstellar.mass_ejector,filters:{max:e=>1e3*e,real:e=>s.mass_ejectorx(e,2)}})}}function mr(e,a){if((t.settings.tabLoad||4===t.settings.civTabs&&2===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==e)&&Fa[e]&&t.interstellar.mass_ejector){"magic"===t.race.universe||"Elerium"!==e&&"Infernite"!==e||(a="caution");let r=$(`

                            ${t.resource[e].name}

                            `);$("#resEjector").append(r);let i=$('');r.append(i),i.append($(`«`)),i.append($(`{{ e.${e} }}`)),i.append($(`»`)),i.append($(`${z("interstellar_mass_ejector_per")}: ${Fa[e]} kt`)),t.interstellar.mass_ejector.hasOwnProperty(e)||(t.interstellar.mass_ejector[e]=0),Cs({el:`#eject${e}`,data:{r:t.resource[e],e:t.interstellar.mass_ejector},methods:{ejectMore(e){let a=y();a+t.interstellar.mass_ejector.total>1e3*s.mass_ejector&&(a=1e3*s.mass_ejector-t.interstellar.mass_ejector.total),t.interstellar.mass_ejector[e]+=a,t.interstellar.mass_ejector.total+=a},ejectLess(e){let a=y();a>t.interstellar.mass_ejector[e]&&(a=t.interstellar.mass_ejector[e]),t.interstellar.mass_ejector[e]>0&&(t.interstellar.mass_ejector[e]-=a,t.interstellar.mass_ejector.total-=a)}}})}}function gr(){if((t.settings.tabLoad||4===t.settings.civTabs&&3===t.settings.marketTabs)&&(Ss($("#resCargo")),t.portal.transport)){let e=$(`

                            ${z("portal_transport_supply")}

                            `);$("#resCargo").append(e);let a=$('{{ used }} / {{ max }}');e.append(a),Cs({el:"#spireSupply",data:t.portal.transport.cargo})}}function vr(e,a){if((t.settings.tabLoad||4===t.settings.civTabs&&3===t.settings.marketTabs)&&Aa[e]&&t.portal.transport){let r=$(`

                            ${t.resource[e].name}

                            `);$("#resCargo").append(r);let i=$('');r.append(i),i.append($(`«`)),i.append($(`{{ e.${e} }}`)),i.append($(`»`));let s=x(Aa[e].out);i.append($(`${z("portal_transport_item",[`${s}`,`${Aa[e].in}`])}`)),t.portal.transport.cargo.hasOwnProperty(e)||(t.portal.transport.cargo[e]=0),Cs({el:`#supply${e}`,data:{r:t.resource[e],e:t.portal.transport.cargo},methods:{supplyMore(e){let a=y();a+t.portal.transport.cargo.used>t.portal.transport.cargo.max&&(a=t.portal.transport.cargo.max-t.portal.transport.cargo.used,t.portal.transport.cargo[e]+a<0&&(a=-t.portal.transport.cargo[e])),t.portal.transport.cargo[e]+=a,t.portal.transport.cargo.used+=a},supplyLess(e){let a=y();a>t.portal.transport.cargo[e]&&(a=t.portal.transport.cargo[e]),t.portal.transport.cargo[e]>0&&(t.portal.transport.cargo[e]-=a,t.portal.transport.cargo.used-=a)}}})}}function fr(){(t.settings.tabLoad||4===t.settings.civTabs&&4===t.settings.marketTabs)&&Ss($("#resAlchemy"))}function yr(e,a,r){if((t.settings.tabLoad||4===t.settings.civTabs&&4===t.settings.marketTabs)&&(!t.race.artifical||"Food"!==e)&&t.tech.alchemy&&(r||t.tech.alchemy>=2)&&"Crystal"!==e){let i=$(`

                            ${t.resource[e].name}

                            `);$("#resAlchemy").append(i);let s=$('');i.append(s),s.append($(`«`)),s.append($(`{{ a.${e} }}`)),s.append($(`»`)),t.race.alchemy.hasOwnProperty(e)||(t.race.alchemy[e]=0),Cs({el:`#alchemy${e}`,data:{r:t.resource[e],a:t.race.alchemy},methods:{addSpell(e){let a=y();for(let r=0;r=1;r++)t.race.alchemy[e]++,t.resource.Mana.diff--},subSpell(e){let a=y();for(let r=0;r0;r++)t.race.alchemy[e]--,t.resource.Mana.diff++}}}),ls(`alchemy${e}`,(function(){let a=r&&t.tech.alchemy>=2?8*za[e]:2*za[e];return t.race.witch_hunter&&(a*=3),t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg&&(a*=t.stats.achieve.soul_sponge.mg+1),$(`
                            ${z("resource_alchemy",[1,z("resource_Mana_name"),.15,z("resource_Crystal_name"),+a.toFixed(2),t.resource[e].name])}
                            `)}),{elm:`#alchemy${e} h3`})}}const br=(wr={},function(e,a,r){let i=a||"a",s=[t.race.universe,t.prestige.Plasmid.count,t.prestige.AntiPlasmid.count,t.prestige.Phage.count,t.race.no_plasmid||"0",t.race.p_mutation||"0",t.race.nerfed||"0",t.genes.store||"0",t.genes.bleed||"0",t.city.temple?t.city.temple.count:"0",t.space.ziggurat?t.space.ziggurat.count:"0",t.race.cataclysm?t.race.cataclysm:"0",t.race.orbit_decayed?t.race.orbit_decayed:"0",t.genes.ancients||"0",t.civic.priest?t.civic.priest.workers:"0"].join("-");if(wr[i]||(wr[i]={}),!wr[i][s]||r){let e=1,r=!(!t.race.cataclysm&&!t.race.orbit_decayed);if(t.genes.store){let r=0;if(!a||a&&("plasmid"===a&&"antimatter"!==t.race.universe||"anti"===a&&"antimatter"===t.race.universe)){r="antimatter"===t.race.universe?t.prestige.AntiPlasmid.count:t.prestige.Plasmid.count;let e=r;t.race.no_plasmid?e=Math.min(t.race.p_mutation,r):t.race.nerfed&&(e=Math.floor(r/("antimatter"===t.race.universe?2:5))),r=Math.round(e*(t.race.nerfed?.5:1))}(!a||a&&"phage"===a)&&t.genes.store>=4&&(r+=Math.round(t.prestige.Phage.count*(t.race.nerfed?1/3:1)));let i=t.genes.store>=2?t.genes.store>=3?1250:1666:2500;if("antimatter"===t.race.universe&&(i*=2),t.genes.bleed&&t.genes.bleed>=3&&(!a||a&&("plasmid"===a&&"antimatter"===t.race.universe||"anti"===a&&"antimatter"!==t.race.universe))){let e="antimatter"===t.race.universe?t.prestige.Plasmid.count/5:t.prestige.AntiPlasmid.count/10;r+=Math.round(e*(t.race.nerfed?.5:1))}e*=1+r/i}if("standard"===t.race.universe&&(e*=Is("standard")),"antimatter"===t.race.universe&&(!r&&t.city.temple&&t.city.temple.count||r&&t.space.ziggurat&&t.space.ziggurat.count)){let a=.06;if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.0012:t.genes.ancients>=3?.001:8e-4;t.race.high_pop&&(e=ke(e)),a+=e*t.civic.priest.workers}e*=1+(r?t.space.ziggurat.count:t.city.temple.count)*a}!a&&t.pillars&&(e*=Ks()[1]),wr[i]={},wr[i][s]=e}return a?wr[i][s]*e:Math.round(wr[i][s]*e)});var wr;const kr=($r={},function(e){let a=[t.race.universe,t.prestige.Plasmid.count,t.prestige.AntiPlasmid.count,t.prestige.Phage.count,t.civic.govern.type,t.civic.professor.assigned,t.genes.bleed||"0",t.race.decayed||"0",t.race.gene_fortify||"0",t.tech.anthropology||"0",t.tech.fanaticism||"0",t.race.nerfed||"0",t.race.no_plasmid||"0",t.genes.ancients||"0",t.city.temple?t.city.temple.count:"0",t.space.ziggurat?t.space.ziggurat.count:"0",t.civic.priest?t.civic.priest.workers:"0",t.race.orbit_decayed?t.race.orbit_decayed:"0",t.race.spiritual||"0",t.tech.outpost_boost||"0",s.alien_outpost||"0"].join("-");if(!$r[a]){let e=0,r=0;if("antimatter"!==t.race.universe||t.genes.bleed){let a=t.race.no_plasmid?Math.min(t.race.p_mutation,t.prestige.Plasmid.count):t.prestige.Plasmid.count;"antimatter"===t.race.universe&&t.genes.bleed&&(a*=.025),t.race.decayed&&(a-=Math.round((t.stats.days-t.race.decayed)/(300+6*t.race.gene_fortify)));let r=250+t.prestige.Phage.count;e=a>r?+(Math.log(r+50)-3.91202).toFixed(5)/2.888+Math.log(a+1-r)/Math.LN2/250:a<0?0:+(Math.log(a+50)-3.91202).toFixed(5)/2.888,t.tech.outpost_boost&&t.race.truepath&&s.alien_outpost&&(e*=2);let i=0;if(t.race.orbit_decayed&&t.space.ziggurat?i=t.space.ziggurat.count:t.city.temple&&(i=t.city.temple.count),i>0&&!t.race.no_plasmid&&"antimatter"!==t.race.universe){let a=t.tech.anthropology&&t.tech.anthropology>=1?.08:.05;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=.002*t.civic.professor.workers;t.race.high_pop&&(e=ke(e)),a+=e}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.0015:t.genes.ancients>=3?.00125:.001;t.race.high_pop&&(e=ke(e)),a+=e*t.civic.priest.workers}t.race.spiritual&&(a*=1+Ei.spiritual.vars()[0]/100);let r=ts("seraph");r>0&&(a*=1+Ei.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1.12),t.race.ooze&&(a*=1-Ei.ooze.vars()[1]/100),t.race.orbit_decayed&&t.race.truepath&&(a*=.1),e*=1+i*a}}if("antimatter"===t.race.universe||t.genes.bleed&&t.genes.bleed>=2){let e=t.prestige.AntiPlasmid.count;"antimatter"!==t.race.universe&&t.genes.bleed&&t.genes.bleed>=2&&(e*=.25),t.race.decayed&&(e-=Math.round((t.stats.days-t.race.decayed)/(300+6*t.race.gene_fortify)));let a=250+t.prestige.Phage.count;r=e>a?+(Math.log(a+50)-3.91202).toFixed(5)/2.888+Math.log(e+1-a)/Math.LN2/250:e<0?0:+(Math.log(e+50)-3.91202).toFixed(5)/2.888,t.tech.outpost_boost&&t.race.truepath&&s.alien_outpost&&(r*=2),r/=3}t.race.nerfed&&("antimatter"===t.race.universe?(e/=2,r/=2):(e/=5,r/=5)),($r={})[a]=[(1+e)*(1+r)-1,e,r]}return e&&"raw"===e?$r[a]:e&&"plasmid"===e?$r[a][1]:e&&"antiplasmid"===e?$r[a][2]:$r[a][0]});var $r;const xr={club:{id:"tech-club",title:z("tech_club"),desc:z("tech_club_desc"),category:"agriculture",era:"primitive",reqs:{},grant:["primitive",1],cost:{Lumber:()=>t.race.kindling_kindred||t.race.smoldering?0:5,Stone:()=>t.race.kindling_kindred||t.race.smoldering?5:0},action(){return!!ri($(this)[0])&&(t.resource.Food.display=!0,!0)}},bone_tools:{id:"tech-bone_tools",title:z("tech_bone_tools"),desc:z("tech_bone_tools_desc"),category:"stone_gathering",era:"primitive",reqs:{primitive:1},grant:["primitive",2],condition:()=>!(t.race.soul_eater&&!t.race.evil),cost:{Food:()=>t.race.evil&&!t.race.smoldering?0:10,Lumber:()=>t.race.evil&&!t.race.smoldering?10:0},action(){return!!ri($(this)[0])&&(t.resource.Stone.display=!0,t.race.smoldering&&(t.resource.Chrysotile.display=!0),!0)}},wooden_tools:{id:"tech-wooden_tools",title:()=>t.race.kindling_kindred?z("tech_bone_tools"):z("tech_wooden_tools"),desc:()=>t.race.kindling_kindred?z("tech_bone_tools_desc"):z("tech_wooden_tools_desc"),category:"stone_gathering",era:"primitive",reqs:{primitive:1},grant:["primitive",2],condition:()=>!(!t.race.soul_eater||t.race.evil),cost:{Lumber:()=>10},action(){return!!ri($(this)[0])&&(t.resource.Stone.display=!0,t.race.smoldering&&(t.resource.Chrysotile.display=!0),!0)}},sundial:{id:"tech-sundial",title:()=>t.race.unfathomable?z("tech_moondial"):z("tech_sundial"),desc:()=>t.race.unfathomable?z("tech_moondial_desc"):z("tech_sundial_desc"),category:"science",era:"primitive",reqs:{primitive:2},grant:["primitive",3],cost:{Lumber:()=>8,Stone:()=>10},effect:()=>t.race.unfathomable?z("tech_moondial_effect"):z("tech_sundial_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_sundial_msg"),"info",!1,["progress"]),t.resource.Knowledge.display=!0,t.city.calendar.day++,t.race.infectious&&(t.civic.garrison.display=!0,t.settings.showCivic=!0,t.city.garrison={count:0,on:0}),t.race.banana&&!t.race.terrifying&&(t.settings.showResources=!0,t.settings.showMarket=!0,t.resource.Money.display=!0,t.city.market.active=!0,t.tech.currency=2),t.race.calm&&(t.resource.Zen.display=!0,t.city.meditation={count:0}),!0)}},housing:{id:"tech-housing",title:z("tech_housing"),desc:z("tech_housing_desc"),category:"housing",era:"civilized",reqs:{primitive:3},grant:["housing",1],cost:{Knowledge:()=>10},effect:z("tech_housing_effect"),action(){return!!ri($(this)[0])&&(t.city.basic_housing={count:0},!0)}},cottage:{id:"tech-cottage",title:()=>pi("medium"),desc:z("tech_cottage_desc"),category:"housing",era:"civilized",reqs:{housing:1,cement:1,mining:3},grant:["housing",2],cost:{Knowledge:()=>3600},effect:z("tech_cottage_effect"),action(){return!!ri($(this)[0])&&(t.city.cottage={count:0},!0)}},apartment:{id:"tech-apartment",title:()=>pi("large"),desc:()=>pi("large"),category:"housing",era:"discovery",reqs:{housing:2,high_tech:2},grant:["housing",3],cost:{Knowledge:()=>15750},effect:z("tech_apartment_effect"),action(){return!!ri($(this)[0])&&(t.city.apartment={count:0,on:0},!0)}},arcology:{id:"tech-arcology",title:z("tech_arcology"),desc:z("tech_arcology"),category:"housing",era:"dimensional",reqs:{hell_ruins:4,housing:3,high_tech:17},grant:["housing",4],cost:{Knowledge:()=>25e6},effect:()=>z("tech_arcology_effect"),action(){return!!ri($(this)[0])&&(t.portal.arcology={count:0,on:0},!0)}},steel_beams:{id:"tech-steel_beams",title:z("tech_steel_beams"),desc:z("tech_housing_cost"),category:"housing",era:"discovery",reqs:{housing:2,smelting:2},not_trait:["cataclysm","lone_survivor"],grant:["housing_reduction",1],cost:{Knowledge:()=>11250,Steel:()=>2500},effect:()=>z("tech_steel_beams_effect",[pi("small"),pi("medium")]),action(){return!!ri($(this)[0])}},mythril_beams:{id:"tech-mythril_beams",title:z("tech_mythril_beams"),desc:z("tech_housing_cost"),category:"housing",era:"early_space",reqs:{housing_reduction:1,space:3},grant:["housing_reduction",2],cost:{Knowledge:()=>175e3,Mythril:()=>1e3},effect:()=>z("tech_mythril_beams_effect",[pi("small"),pi("medium")]),action(){return!!ri($(this)[0])}},neutronium_walls:{id:"tech-neutronium_walls",title:z("tech_neutronium_walls"),desc:z("tech_housing_cost"),category:"housing",era:"deep_space",reqs:{housing_reduction:2,gas_moon:1},grant:["housing_reduction",3],cost:{Knowledge:()=>3e5,Neutronium:()=>850},effect:()=>z("tech_neutronium_walls_effect",[pi("small"),pi("medium")]),action(){return!!ri($(this)[0])}},bolognium_alloy_beams:{id:"tech-bolognium_alloy_beams",title:z("tech_bolognium_alloy_beams"),desc:z("tech_housing_cost"),category:"housing",era:"intergalactic",reqs:{housing_reduction:3,gateway:3},grant:["housing_reduction",4],cost:{Knowledge:()=>375e4,Adamantite:()=>25e5,Bolognium:()=>1e5},effect:()=>z("tech_bolognium_alloy_beams_effect",[pi("small"),pi("medium")]),action(){return!!ri($(this)[0])}},aphrodisiac:{id:"tech-aphrodisiac",title:z("tech_aphrodisiac"),desc:z("tech_aphrodisiac_desc"),category:"housing",era:"civilized",reqs:{housing:2},grant:["reproduction",1],not_trait:["artifical"],cost:{Knowledge:()=>4500},effect:z("tech_aphrodisiac_effect"),action(){return!!ri($(this)[0])}},fertility_clinic:{id:"tech-fertility_clinic",title:z("tech_fertility_clinic"),desc:z("tech_fertility_clinic"),category:"housing",era:"intergalactic",reqs:{reproduction:1,xeno:6},not_trait:["cataclysm"],grant:["reproduction",2],cost:{Knowledge:()=>45e5},effect:z("tech_fertility_clinic_effect"),action(){return!!ri($(this)[0])}},captive_housing:{id:"tech-captive_housing",title:z("tech_captive_housing"),desc:z("tech_captive_housing"),category:"eldritch",era:"civilized",reqs:{housing:1},trait:["unfathomable"],grant:["unfathomable",1],cost:{Knowledge:()=>12},effect:z("tech_captive_housing_effect"),action(){return!!ri($(this)[0])&&(t.city.captive_housing={count:0,cattle:0,cattleCatch:0,race0:0,jailrace0:0,race1:0,jailrace1:0,race2:0,jailrace2:0,raceCap:0,cattleCap:0},!0)}},torture:{id:"tech-torture",title:z("tech_torture"),desc:z("tech_torture"),category:"eldritch",era:"civilized",reqs:{unfathomable:1},trait:["unfathomable"],grant:["unfathomable",2],cost:{Knowledge:()=>25},effect:z("tech_torture_effect"),action(){return!!ri($(this)[0])&&(t.civic.torturer.display=!0,!0)}},thrall_quarters:{id:"tech-thrall_quarters",title:z("tech_thrall_quarters"),desc:z("tech_thrall_quarters"),category:"eldritch",era:"civilized",reqs:{unfathomable:2,high_tech:6},trait:["unfathomable"],grant:["unfathomable",3],cost:{Knowledge:()=>95e3,Cement:()=>5e4,Wrought_Iron:()=>12500},effect:z("tech_thrall_quarters_effect"),action(){return!!ri($(this)[0])&&(t.civic.torturer.display=!0,!0)}},psychic_energy:{id:"tech-psychic_energy",title:z("tech_psychic_energy"),desc:z("tech_psychic_energy"),category:"eldritch",era:"civilized",reqs:{housing:1},condition:()=>t.settings.showCivic,trait:["psychic"],grant:["psychic",1],cost:{Knowledge:()=>15},effect:z("tech_psychic_energy_effect"),action(){return!!ri($(this)[0])&&(t.resource.Energy.display=!0,t.settings.showPsychic=!0,t.race.psychicPowers={boost:{r:"Food"},boostTime:0},!0)},post(){cs()}},psychic_attack:{id:"tech-psychic_attack",title:z("tech_psychic_attack"),desc:z("tech_psychic_attack"),category:"eldritch",era:"civilized",reqs:{psychic:1,military:1},condition:()=>t.stats.psykill>=10,trait:["psychic"],grant:["psychic",2],cost:{Knowledge:()=>100},effect:z("tech_psychic_attack_effect"),action(){return!!ri($(this)[0])&&(t.race.psychicPowers.assaultTime=0,!0)},post(){cs()}},psychic_finance:{id:"tech-psychic_finance",title:z("tech_psychic_finance"),desc:z("tech_psychic_finance"),category:"eldritch",era:"civilized",reqs:{psychic:2,high_tech:4},trait:["psychic"],grant:["psychic",3],cost:{Knowledge:()=>65e3},effect:z("tech_psychic_finance_effect"),action(){return!!ri($(this)[0])&&(t.race.psychicPowers.cash=0,!0)},post(){cs()}},psychic_channeling:{id:"tech-psychic_channeling",title:z("tech_psychic_channeling"),desc:z("tech_psychic_channeling"),category:"eldritch",era:"deep_space",reqs:{psychic:3,high_tech:10},trait:["psychic"],grant:["psychic",4],cost:{Knowledge:()=>36e4},effect:z("tech_psychic_channeling_effect"),action(){return!!ri($(this)[0])&&(t.race.psychicPowers.channel={cash:0,assault:0,boost:0},!0)},post(){cs()}},psychic_efficiency:{id:"tech-psychic_efficiency",title:z("tech_psychic_efficiency"),desc:z("tech_psychic_efficiency"),category:"eldritch",era:"intergalactic",reqs:{psychic:4,high_tech:16},trait:["psychic"],grant:["psychic",5],cost:{Knowledge:()=>525e4},effect:z("tech_psychic_efficiency_effect"),action(){return!!ri($(this)[0])},post(){cs()}},mind_break:{id:"tech-mind_break",title:z("tech_mind_break"),desc:z("tech_mind_break"),category:"eldritch",era:"civilized",reqs:{psychic:2,high_tech:1,unfathomable:2},trait:["psychic"],grant:["psychicthrall",1],cost:{Knowledge:()=>7e3},effect:z("tech_mind_break_effect"),action(){return!!ri($(this)[0])},post(){cs()}},psychic_stun:{id:"tech-psychic_stun",title:z("tech_psychic_stun"),desc:z("tech_psychic_stun"),category:"eldritch",era:"civilized",reqs:{psychicthrall:1,high_tech:3,unfathomable:2},trait:["psychic"],grant:["psychicthrall",2],cost:{Knowledge:()=>32e3},effect:z("tech_psychic_stun_effect"),action(){return!!ri($(this)[0])},post(){cs()}},spear:{id:"tech-spear",title:z("tech_spear"),desc:z("tech_spear_desc"),category:"foraging",era:"civilized",reqs:{primitive:3,storage:1},trait:["forager"],grant:["foraging",1],cost:{Knowledge:()=>110,Stone:()=>75},effect:z("tech_spear_effect"),action(){return!!ri($(this)[0])}},bronze_spear:{id:"tech-bronze_spear",title:z("tech_bronze_spear"),desc:z("tech_bronze_spear_desc"),category:"foraging",era:"civilized",reqs:{foraging:1,mining:2},trait:["forager"],grant:["foraging",2],cost:{Knowledge:()=>525,Copper:()=>50},effect:z("tech_bronze_spear_effect"),action(){return!!ri($(this)[0])}},iron_spear:{id:"tech-iron_spear",title:z("tech_iron_spear"),desc:z("tech_iron_spear_desc"),category:"foraging",era:"civilized",reqs:{foraging:2,mining:3},trait:["forager"],grant:["foraging",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1650:3300,Iron:()=>375},effect:z("tech_bronze_spear_effect"),action(){return!!ri($(this)[0])}},dowsing_rod:{id:"tech-dowsing_rod",title:z("tech_dowsing_rod"),desc:z("tech_dowsing_rod_desc"),category:"foraging",era:"civilized",reqs:{foraging:1,mining:2},trait:["forager"],grant:["dowsing",1],cost:{Knowledge:()=>450,Lumber:()=>750},effect:z("tech_dowsing_rod_effect"),action(){return!!ri($(this)[0])}},metal_detector:{id:"tech-metal_detector",title:z("tech_metal_detector"),desc:z("tech_metal_detector_desc"),category:"foraging",era:"civilized",reqs:{dowsing:1,high_tech:4},trait:["forager"],grant:["dowsing",2],cost:{Knowledge:()=>65e3},effect:z("tech_metal_detector_effect"),action(){return!!ri($(this)[0])}},smokehouse:{id:"tech-smokehouse",title:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("city_smokehouse_easter"):z("tech_smokehouse"),desc:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("tech_smokehouse_easter_desc"):z("tech_smokehouse_desc"),category:"storage",era:"civilized",reqs:{primitive:3,storage:1},trait:["carnivore"],not_trait:["cataclysm","artifical","soul_eater","herbivore","lone_survivor"],grant:["hunting",1],cost:{Knowledge:()=>80},effect:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("tech_smokehouse_easter_effect"):z("tech_smokehouse_effect"),action(){return!!ri($(this)[0])&&(Ri("city","smokehouse","silo",{count:0}),!0)},post(){t.tech.s_lodge&&(t.tech.hunting=2)}},lodge:{id:"tech-lodge",title:z("tech_lodge"),desc:z("tech_lodge"),wiki:!!t.race.carnivore,category:"agriculture",era:"civilized",reqs:{hunting:1,housing:1,currency:1},condition:()=>!t.tech.s_lodge,grant:["hunting",2],cost:{Knowledge:()=>180},effect:z("tech_lodge_effect"),action(){return!!ri($(this)[0])&&(Ri("city","lodge","farm",{count:0}),!0)}},alt_lodge:{id:"tech-alt_lodge",title(){return this.condition()?z("tech_lodge_alt"):z("tech_lodge")},desc(){return this.condition()?z("tech_lodge_alt"):z("tech_lodge")},wiki:!t.race.carnivore,category:"housing",era:"civilized",reqs:{housing:1,currency:1},grant:["s_lodge",1],condition:()=>!!(("wendigo"===t.race.species||t.race.detritivore)&&!t.race.carnivore&&!t.race.herbivore||t.race.carnivore&&t.race.soul_eater||t.race.artifical||t.race.unfathomable),cost:{Knowledge:()=>t.race.artifical?1e4:180},effect(){return this.condition()?z("tech_lodge_effect_alt"):z("tech_lodge_effect")},action(){return!!ri($(this)[0])&&(Ri("city","lodge","farm",{count:0}),!0)}},soul_well:{id:"tech-soul_well",title:z("tech_soul_well"),desc:z("tech_soul_well"),category:"souls",era:"civilized",reqs:{primitive:3},trait:["soul_eater"],not_trait:["cataclysm","artifical","lone_survivor"],grant:["soul_eater",1],cost:{Knowledge:()=>10},effect:z("tech_soul_well_effect"),action(){return!!ri($(this)[0])&&(t.city.soul_well={count:0},!0)}},compost:{id:"tech-compost",title:z("tech_compost"),desc:z("tech_compost_desc"),category:"compost",era:"civilized",reqs:{primitive:3},trait:["detritivore"],not_trait:["cataclysm","artifical","lone_survivor"],grant:["compost",1],cost:{Knowledge:()=>10},effect:z("tech_compost_effect"),action(){return!!ri($(this)[0])&&(t.city.compost={count:0,on:0},!0)}},hot_compost:{id:"tech-hot_compost",title:z("tech_hot_compost"),desc:z("tech_hot_compost"),category:"compost",era:"civilized",reqs:{compost:1},trait:["detritivore"],grant:["compost",2],cost:{Knowledge:()=>100},effect:z("tech_hot_compost_effect"),action(){return!!ri($(this)[0])}},mulching:{id:"tech-mulching",title:z("tech_mulching"),desc:z("tech_mulching"),category:"compost",era:"civilized",reqs:{compost:2,mining:3},trait:["detritivore"],grant:["compost",3],cost:{Knowledge:()=>3200},effect:z("tech_mulching_effect"),action(){return!!ri($(this)[0])}},adv_mulching:{id:"tech-adv_mulching",title:z("tech_adv_mulching"),desc:z("tech_adv_mulching"),category:"compost",era:"discovery",reqs:{compost:3,high_tech:2},trait:["detritivore"],grant:["compost",4],cost:{Knowledge:()=>16e3},effect:z("tech_adv_mulching_effect"),action(){return!!ri($(this)[0])}},agriculture:{id:"tech-agriculture",title:z("tech_agriculture"),desc:z("tech_agriculture_desc"),category:"agriculture",era:"civilized",reqs:{primitive:3},condition:()=>!(!t.race.herbivore&&(t.race.carnivore||t.race.detritivore||t.race.soul_eater)),not_trait:["cataclysm","artifical","lone_survivor","unfathomable"],grant:["agriculture",1],cost:{Knowledge:()=>10},effect:z("tech_agriculture_effect"),action(){return!!ri($(this)[0])&&(Ri("city","farm","lodge",{count:0}),!0)}},farm_house:{id:"tech-farm_house",title:z("tech_farm_house"),desc:z("tech_farm_house_desc"),category:"housing",era:"civilized",reqs:{agriculture:1,housing:1,currency:1},grant:["farm",1],cost:{Money:()=>50,Knowledge:()=>180},effect:z("tech_farm_house_effect"),action(){return!!ri($(this)[0])}},irrigation:{id:"tech-irrigation",title:z("tech_irrigation"),desc:z("tech_irrigation_desc"),category:"agriculture",era:"civilized",reqs:{agriculture:1},grant:["agriculture",2],cost:{Knowledge:()=>55},effect:z("tech_irrigation_effect"),action(){return!!ri($(this)[0])}},silo:{id:"tech-silo",title:z("tech_silo"),desc:z("tech_silo_desc"),category:"storage",era:"civilized",reqs:{agriculture:2,storage:1},grant:["agriculture",3],cost:{Knowledge:()=>80},effect:z("tech_silo_effect"),action(){return!!ri($(this)[0])&&(Ri("city","silo","smokehouse",{count:0}),!0)}},mill:{id:"tech-mill",title:z("tech_mill"),desc:z("tech_mill_desc"),category:"agriculture",era:"civilized",reqs:{agriculture:3,mining:3},grant:["agriculture",4],cost:{Knowledge:()=>5400},effect:z("tech_mill_effect"),action(){return!!ri($(this)[0])&&(Ri("city","mill","windmill",{count:0,on:0}),!0)}},windmill:{id:"tech-windmill",title:z("tech_windmill"),desc:z("tech_windmill_desc"),category:"agriculture",era:"discovery",reqs:{agriculture:4,high_tech:1},grant:["agriculture",5],cost:{Knowledge:()=>16200},effect:z("tech_windmill_effect"),action(){return!!ri($(this)[0])}},windturbine:{id:"tech-windturbine",title:z("tech_windturbine"),desc:z("tech_windturbine"),category:"power_generation",era:"globalized",reqs:{agriculture:5,high_tech:4},grant:["agriculture",6],cost:{Knowledge:()=>66e3},effect:z("tech_windturbine_effect"),action(){return!!ri($(this)[0])}},wind_plant:{id:"tech-wind_plant",title:()=>t.race.unfathomable?z("tech_watermill"):z("tech_windmill"),desc:()=>t.race.unfathomable?z("tech_watermill"):z("tech_windmill"),category:"power_generation",era:"globalized",reqs:{high_tech:4},condition:()=>!!(t.race.carnivore||t.race.detritivore||t.race.artifical||t.race.soul_eater||t.race.unfathomable),not_trait:["herbivore"],grant:["wind_plant",1],cost:{Knowledge:()=>66e3},effect:()=>t.race.unfathomable?z("tech_watermill_effect"):z("tech_wind_plant_effect"),action(){return!!ri($(this)[0])&&(Ri("city","windmill","mill",{count:0,on:0}),!0)}},gmfood:{id:"tech-gmfood",title:z("tech_gmfood"),desc:z("tech_gmfood_desc"),category:"agriculture",era:"globalized",reqs:{agriculture:6,genetics:1},grant:["agriculture",7],cost:{Knowledge:()=>95e3},effect:z("tech_gmfood_effect"),action(){return!!ri($(this)[0])}},foundry:{id:"tech-foundry",title:z("tech_foundry"),desc:z("tech_foundry"),category:"crafting",era:"civilized",reqs:{mining:2},grant:["foundry",1],cost:{Knowledge:()=>650},effect:z("tech_foundry_effect"),action(){return!!ri($(this)[0])&&(t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},!0)}},artisans:{id:"tech-artisans",title:z("tech_artisans"),desc:z("tech_artisans"),category:"crafting",era:"civilized",reqs:{foundry:1},grant:["foundry",2],cost:{Knowledge:()=>1500},effect:z("tech_artisans_effect"),action(){return!!ri($(this)[0])}},apprentices:{id:"tech-apprentices",title:z("tech_apprentices"),desc:z("tech_apprentices"),category:"crafting",era:"civilized",reqs:{foundry:2},grant:["foundry",3],cost:{Knowledge:()=>3200},effect:z("tech_apprentices_effect"),action(){return!!ri($(this)[0])}},carpentry:{id:"tech-carpentry",title:z("tech_carpentry"),desc:z("tech_carpentry"),category:"crafting",era:"civilized",reqs:{foundry:3,saw:1},grant:["foundry",4],not_trait:["evil"],cost:{Knowledge:()=>5200},effect:z("tech_carpentry_effect"),action(){return!!ri($(this)[0])}},demonic_craftsman:{id:"tech-demonic_craftsman",title:z("tech_master_craftsman"),desc:z("tech_master_craftsman"),category:"crafting",era:"discovery",wiki:!!t.race.evil,reqs:{foundry:3},grant:["foundry",5],trait:["evil"],cost:{Knowledge:()=>12e3},effect:z("tech_master_craftsman_effect"),action(){return!!ri($(this)[0])}},master_craftsman:{id:"tech-master_craftsman",title:z("tech_master_craftsman"),desc:z("tech_master_craftsman"),category:"crafting",era:"discovery",wiki:!t.race.evil,reqs:{foundry:4},grant:["foundry",5],not_trait:["evil"],cost:{Knowledge:()=>12e3},effect:z("tech_master_craftsman_effect"),action(){return!!ri($(this)[0])}},brickworks:{id:"tech-brickworks",title:z("tech_brickworks"),desc:z("tech_brickworks"),category:"crafting",era:"discovery",reqs:{foundry:5},grant:["foundry",6],cost:{Knowledge:()=>18500},effect:z("tech_brickworks_effect"),action(){return!!ri($(this)[0])}},machinery:{id:"tech-machinery",title:z("tech_machinery"),desc:z("tech_machinery"),category:"crafting",era:"globalized",reqs:{foundry:6,high_tech:4},grant:["foundry",7],cost:{Knowledge:()=>66e3},effect:z("tech_machinery_effect"),action(){return!!ri($(this)[0])}},cnc_machine:{id:"tech-cnc_machine",title:z("tech_cnc_machine"),desc:z("tech_cnc_machine"),category:"crafting",era:"globalized",reqs:{foundry:7,high_tech:8},grant:["foundry",8],cost:{Knowledge:()=>132e3},effect:z("tech_cnc_machine_effect"),action(){return!!ri($(this)[0])}},vocational_training:{id:"tech-vocational_training",title:z("tech_vocational_training"),desc:z("tech_vocational_training"),category:"crafting",era:"industrialized",reqs:{foundry:1,high_tech:3},grant:["v_train",1],cost:{Knowledge:()=>3e4},effect:z("tech_vocational_training_effect"),action(){return!!ri($(this)[0])}},stellar_forge:{id:"tech-stellar_forge",title:z("tech_stellar_forge"),desc:z("tech_stellar_forge"),category:"crafting",era:"intergalactic",reqs:{foundry:8,high_tech:15,gateway:3,neutron:1},grant:["star_forge",1],cost:{Knowledge:()=>45e5},effect:z("tech_stellar_forge_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.stellar_forge={count:0,on:0},!0)}},stellar_smelting:{id:"tech-stellar_smelting",title:z("tech_stellar_smelting"),desc:z("tech_stellar_smelting"),category:"crafting",era:"intergalactic",reqs:{star_forge:1,xeno:4},grant:["star_forge",2],cost:{Knowledge:()=>5e6,Vitreloy:()=>1e4},effect:z("tech_stellar_smelting_effect"),action(){return!!ri($(this)[0])},post(){ki()}},assembly_line:{id:"tech-assembly_line",title:z("tech_assembly_line"),desc:z("tech_assembly_line"),category:"crafting",era:"globalized",reqs:{high_tech:4},grant:["factory",1],cost:{Knowledge:()=>72e3,Copper:()=>125e3},effect:`${z("tech_assembly_line_effect")} ${z("tech_factory_warning")}`,action(){return!!ri($(this)[0])}},automation:{id:"tech-automation",title:z("tech_automation"),desc:z("tech_automation"),category:"crafting",era:"early_space",reqs:{high_tech:8,factory:1},grant:["factory",2],cost:{Knowledge:()=>165e3},effect:`${z("tech_automation_effect")} ${z("tech_factory_warning")}`,action(){return!!ri($(this)[0])}},laser_cutters:{id:"tech-laser_cutters",title:z("tech_laser_cutters"),desc:z("tech_laser_cutters"),category:"crafting",era:"deep_space",reqs:{high_tech:9,factory:2},grant:["factory",3],cost:{Knowledge:()=>3e5,Elerium:()=>200},effect:`${z("tech_laser_cutters_effect")} ${z("tech_factory_warning")}`,action(){return!!ri($(this)[0])}},high_tech_factories:{id:"tech-high_tech_factories",title:z("tech_high_tech_factories"),desc:z("tech_high_tech_factories"),category:"crafting",era:"intergalactic",reqs:{high_tech:17,alpha:4,factory:3},grant:["factory",4],cost:{Knowledge:()=>135e5,Vitreloy:()=>5e5,Orichalcum:()=>3e5},effect:`${z("tech_high_tech_factories_effect")} ${z("tech_factory_warning")}`,action(){return!!ri($(this)[0])}},theatre:{id:"tech-theatre",title:z("tech_theatre"),desc:z("tech_theatre"),category:"entertainment",era:"civilized",reqs:{housing:1,currency:1,cement:1},grant:["theatre",1],not_trait:["joyless"],cost:{Knowledge:()=>750},effect:z("tech_theatre_effect"),action(){return!!ri($(this)[0])&&(t.city.amphitheatre={count:0},!0)}},playwright:{id:"tech-playwright",title:z("tech_playwright"),desc:z("tech_playwright"),category:"entertainment",era:"civilized",reqs:{theatre:1,science:2},grant:["theatre",2],cost:{Knowledge:()=>1080},effect:z("tech_playwright_effect"),action(){return!!ri($(this)[0])}},magic:{id:"tech-magic",title:()=>"magic"===t.race.universe?z("tech_illusionist"):z("tech_magic"),desc:()=>"magic"===t.race.universe?z("tech_illusionist"):z("tech_magic"),category:"entertainment",era:"discovery",reqs:{theatre:2,high_tech:1},grant:["theatre",3],cost:{Knowledge:()=>7920},effect:z("tech_magic_effect"),effect:()=>"magic"===t.race.universe?z("tech_illusionist_effect"):z("tech_magic_effect"),action(){return!!ri($(this)[0])}},superstars:{id:"tech-superstars",title:z("tech_superstars"),desc:z("tech_superstars"),category:"entertainment",era:"interstellar",reqs:{theatre:3,high_tech:12},grant:["superstar",1],cost:{Knowledge:()=>66e4},effect:z("tech_superstars_effect"),action(){return!!ri($(this)[0])}},radio:{id:"tech-radio",title:z("tech_radio"),desc:z("tech_radio"),category:"entertainment",era:"discovery",reqs:{theatre:3,high_tech:2},grant:["broadcast",1],cost:{Knowledge:()=>16200},effect:()=>z("tech_radio_effect",[_i()]),action(){return!!ri($(this)[0])}},tv:{id:"tech-tv",title:z("tech_tv"),desc:z("tech_tv"),category:"entertainment",era:"globalized",reqs:{broadcast:1,high_tech:4},grant:["broadcast",2],cost:{Knowledge:()=>67500},effect:()=>z("tech_tv_effect",[_i()]),action(){return!!ri($(this)[0])}},vr_center:{id:"tech-vr_center",title:z("tech_vr_center"),desc:z("tech_vr_center"),category:"entertainment",era:"interstellar",reqs:{broadcast:2,high_tech:12,stanene:1},grant:["broadcast",3],cost:{Knowledge:()=>62e4},effect:()=>z("tech_vr_center_effect"),action(){return!!ri($(this)[0])&&(t.space.vr_center={count:0,on:0},!0)}},zoo:{id:"tech-zoo",title:z("tech_zoo"),desc:z("tech_zoo"),category:"entertainment",era:"dimensional",reqs:{hell_ruins:2},grant:["zoo",1],cost:{Knowledge:()=>225e5},effect:()=>z("tech_zoo_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.zoo={count:0,on:0},!0)}},casino:{id:"tech-casino",title:z("tech_casino"),desc:z("tech_casino"),category:"entertainment",era:"globalized",reqs:{high_tech:4,currency:5},grant:["gambling",1],cost:{Knowledge:()=>95e3},effect:z("tech_casino_effect"),action(){return!!ri($(this)[0])&&(t.city.casino={count:0,on:0},t.space.spc_casino={count:0,on:0},!0)}},dazzle:{id:"tech-dazzle",title:z("tech_dazzle"),desc:z("tech_dazzle"),category:"banking",era:"globalized",reqs:{gambling:1},grant:["gambling",2],cost:{Knowledge:()=>125e3},effect:z("tech_dazzle_effect"),action(){return!!ri($(this)[0])}},casino_vault:{id:"tech-casino_vault",title:z("tech_casino_vault"),desc:z("tech_casino_vault"),category:"banking",era:"early_space",reqs:{gambling:2,space:3},grant:["gambling",3],cost:{Knowledge:()=>145e3,Iridium:()=>2500},effect:z("tech_casino_vault_effect"),action(){return!!ri($(this)[0])}},otb:{id:"tech-otb",title:z("tech_otb"),desc:z("tech_otb"),category:"banking",era:"deep_space",reqs:{gambling:3,banking:10,high_tech:10},grant:["gambling",4],cost:{Knowledge:()=>39e4},effect:z("tech_otb_effect"),action(){return!!ri($(this)[0])}},online_gambling:{id:"tech-online_gambling",title:z("tech_online_gambling"),desc:z("tech_online_gambling"),category:"banking",era:"interstellar",reqs:{gambling:4,banking:12},grant:["gambling",5],cost:{Knowledge:()=>8e5},effect:z("tech_online_gambling_effect"),action(){return!!ri($(this)[0])}},bolognium_vaults:{id:"tech-bolognium_vaults",title:z("tech_bolognium_vaults"),desc:z("tech_bolognium_vaults"),category:"banking",era:"intergalactic",reqs:{gambling:5,gateway:3},grant:["gambling",6],cost:{Knowledge:()=>39e5,Bolognium:()=>18e4},effect:z("tech_bolognium_vaults_effect"),action(){return!!ri($(this)[0])}},mining:{id:"tech-mining",title:()=>t.race.sappy?z("tech_amber"):z("tech_mining"),desc:()=>t.race.sappy?z("tech_amber"):z("tech_mining_desc"),category:"mining",era:"civilized",reqs:{primitive:3},grant:["mining",1],cost:{Knowledge:()=>45},effect:()=>t.race.sappy?z("tech_amber_effect"):z(t.race.flier?"tech_mining_effect_alt":"tech_mining_effect"),action(){return!!ri($(this)[0])&&(t.city.rock_quarry={count:0,on:0,asbestos:50},t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),!0)}},bayer_process:{id:"tech-bayer_process",title:z("tech_bayer_process"),desc:z("tech_bayer_process_desc"),category:"mining",era:"civilized",reqs:{smelting:2},grant:["alumina",1],cost:{Knowledge:()=>4500},effect:()=>t.race.sappy?z("tech_bayer_process_effect_alt"):z("tech_bayer_process_effect"),action(){return!!ri($(this)[0])&&(t.city.metal_refinery={count:0,on:0},sa(),!0)}},elysis_process:{id:"tech-elysis_process",title:z("tech_elysis_process"),desc:z("tech_elysis_process"),category:"mining",era:"interstellar",reqs:{alumina:1,stanene:1,graphene:1},path:["standard","truepath"],not_trait:["cataclysm","lone_survivor"],grant:["alumina",2],cost:{Knowledge:()=>675e3,Graphene:()=>45e3,Stanene:()=>75e3},effect:z("tech_elysis_process_effect"),action(){return!!ri($(this)[0])}},smelting:{id:"tech-smelting",title:z("tech_smelting"),desc:z("tech_smelting_desc"),category:"mining",era:"civilized",reqs:{mining:3},grant:["smelting",1],cost:{Knowledge:()=>4050},effect:z("tech_smelting_effect"),action(){return!!ri($(this)[0])&&(t.city.smelter={count:0,cap:0,Wood:0,Coal:0,Oil:0,Star:0,StarCap:0,Inferno:0,Iron:0,Steel:0,Iridium:0},!0)},post(){t.race.steelen&&(t.tech.smelting=2,Qr())}},steel:{id:"tech-steel",title:z("tech_steel"),desc:z("tech_steel_desc"),category:"mining",era:"civilized",reqs:{smelting:1,mining:4},grant:["smelting",2],condition:()=>!t.race.steelen,cost:{Knowledge:()=>4950,Steel:()=>25},effect:z("tech_steel_effect"),action(){return!!ri($(this)[0])&&(t.resource.Steel.display=!0,!0)},post(){ki(),cs()}},blast_furnace:{id:"tech-blast_furnace",title:z("tech_blast_furnace"),desc:z("tech_blast_furnace"),category:"mining",era:"discovery",reqs:{smelting:2},grant:["smelting",3],cost:{Knowledge:()=>13500,Coal:()=>2e3},effect:z("tech_blast_furnace_effect"),action(){return!!ri($(this)[0])},post(){t.race.steelen&&(t.tech.smelting=6,Qr())}},bessemer_process:{id:"tech-bessemer_process",title:z("tech_bessemer_process"),desc:z("tech_bessemer_process"),category:"mining",era:"discovery",reqs:{smelting:3},grant:["smelting",4],condition:()=>!t.race.steelen,cost:{Knowledge:()=>19800,Coal:()=>5e3},effect:z("tech_bessemer_process_effect"),action(){return!!ri($(this)[0])}},oxygen_converter:{id:"tech-oxygen_converter",title:z("tech_oxygen_converter"),desc:z("tech_oxygen_converter"),category:"mining",era:"industrialized",reqs:{smelting:4,high_tech:3},grant:["smelting",5],condition:()=>!t.race.steelen,cost:{Knowledge:()=>46800,Coal:()=>1e4},effect:z("tech_oxygen_converter_effect"),action(){return!!ri($(this)[0])}},electric_arc_furnace:{id:"tech-electric_arc_furnace",title:z("tech_electric_arc_furnace"),desc:z("tech_electric_arc_furnace"),category:"mining",era:"globalized",reqs:{smelting:5,high_tech:4},grant:["smelting",6],condition:()=>!t.race.steelen,cost:{Knowledge:()=>85500,Copper:()=>25e3},effect:z("tech_electric_arc_furnace_effect"),action(){return!!ri($(this)[0])}},hellfire_furnace:{id:"tech-hellfire_furnace",title:z("tech_hellfire_furnace"),desc:z("tech_hellfire_furnace"),category:"mining",era:"interstellar",reqs:{smelting:6,infernite:1},grant:["smelting",7],cost:{Knowledge:()=>615e3,Infernite:()=>2e3,Soul_Gem:()=>2},effect:z("tech_hellfire_furnace_effect"),action(){return!!ri($(this)[0])}},infernium_fuel:{id:"tech-infernium_fuel",title:z("tech_infernium_fuel"),desc:z("tech_infernium_fuel"),category:"mining",era:"dimensional",reqs:{smelting:7,hell_ruins:4},grant:["smelting",8],cost:{Knowledge:()=>275e5,Coal:()=>45e6,Oil:()=>5e5,Infernite:()=>75e4},effect:z("tech_infernium_fuel_effect"),action(){return!!ri($(this)[0])},post(){ki()}},iridium_smelting_perk:{id:"tech-iridium_smelting_perk",title:z("tech_iridium_smelting"),desc:z("tech_iridium_smelting"),category:"mining",era:"early_space",path:["standard"],reqs:{smelting:6,space:3},condition:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=3),grant:["irid_smelting",1],cost:{Knowledge:()=>35e4,Mythril:()=>2500},effect:z("tech_iridium_smelting_effect"),action(){return!!ri($(this)[0])}},rotary_kiln:{id:"tech-rotary_kiln",title:z("tech_rotary_kiln"),desc:z("tech_rotary_kiln"),category:"mining",era:"industrialized",reqs:{smelting:3,high_tech:3},grant:["copper",1],cost:{Knowledge:()=>57600,Coal:()=>8e3},effect:z("tech_rotary_kiln_effect"),action(){return!!ri($(this)[0])}},metal_working:{id:"tech-metal_working",title:z("tech_metal_working"),desc:z("tech_metal_working_desc"),category:"mining",era:"civilized",reqs:{mining:1},grant:["mining",2],cost:{Knowledge:()=>350},effect:z("tech_metal_working_effect"),action(){return!!ri($(this)[0])&&(t.city.mine={count:0,on:0},!0)}},iron_mining:{id:"tech-iron_mining",title:z("tech_iron_mining"),desc:z("tech_iron_mining_desc"),category:"mining",era:"civilized",reqs:{mining:2},grant:["mining",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?500:2500},effect:z("tech_iron_mining_effect"),action(){return!!ri($(this)[0])&&(t.resource.Iron.display=!0,t.city.foundry&&t.city.foundry.count>0&&(t.resource.Wrought_Iron.display=!0,sa()),!0)},post(){cs()}},coal_mining:{id:"tech-coal_mining",title:z("tech_coal_mining"),desc:z("tech_coal_mining_desc"),category:"power_generation",era:"civilized",reqs:{mining:3},grant:["mining",4],cost:{Knowledge:()=>4320},effect:z("tech_coal_mining_effect"),action(){return!!ri($(this)[0])&&(t.city.coal_mine={count:0,on:0},t.resource.Coal.display=!0,!0)},post(){cs()}},storage:{id:"tech-storage",title:z("tech_storage"),desc:z("tech_storage_desc"),category:"storage",era:"civilized",reqs:{primitive:3,currency:1},grant:["storage",1],cost:{Knowledge:()=>20},effect:z("tech_storage_effect"),action(){return!!ri($(this)[0])&&(t.city.shed={count:0},!0)}},reinforced_shed:{id:"tech-reinforced_shed",title:z("tech_reinforced_shed"),desc:z("tech_reinforced_shed_desc"),category:"storage",era:"civilized",reqs:{storage:1,cement:1,mining:3},grant:["storage",2],cost:{Money:()=>3750,Knowledge:()=>2550,Iron:()=>750,Cement:()=>500},effect:z("tech_reinforced_shed_effect"),action(){return!!ri($(this)[0])}},barns:{id:"tech-barns",title:z("tech_barns"),desc:z("tech_barns_desc"),category:"storage",era:"discovery",reqs:{storage:2,smelting:2,alumina:1},grant:["storage",3],cost:{Knowledge:()=>15750,Aluminium:()=>3e3,Steel:()=>3e3},effect:z("tech_barns_effect"),action(){return!!ri($(this)[0])},post(){ui(!1,["city-shed"])}},warehouse:{id:"tech-warehouse",title:z("tech_warehouse"),desc:z("tech_warehouse_desc"),category:"storage",era:"industrialized",reqs:{storage:3,high_tech:3,smelting:2},grant:["storage",4],cost:{Knowledge:()=>40500,Titanium:()=>3e3},effect:z("tech_warehouse_effect"),action(){return!!ri($(this)[0])},post(){ui(!1,["city-shed"])}},cameras:{id:"tech-cameras",title:z("tech_cameras"),desc:z("tech_cameras_desc"),category:"storage",era:"globalized",reqs:{storage:4,high_tech:4},grant:["storage",5],cost:{Money:()=>9e4,Knowledge:()=>65e3},effect:z("tech_cameras_effect"),action(){return!!ri($(this)[0])}},pocket_dimensions:{id:"tech-pocket_dimensions",title:z("tech_pocket_dimensions"),desc:z("tech_pocket_dimensions_desc"),category:"storage",era:"early_space",path:["standard"],reqs:{particles:1,storage:5},grant:["storage",6],cost:{Knowledge:()=>108e3},effect:z("tech_pocket_dimensions_effect"),action(){return!!ri($(this)[0])}},ai_logistics:{id:"tech-ai_logistics",title:z("tech_ai_logistics"),desc:z("tech_ai_logistics"),category:"storage",era:"interstellar",reqs:{storage:6,proxima:2,science:13},grant:["storage",7],cost:{Knowledge:()=>65e4},effect:z("tech_ai_logistics_effect"),action(){return!!ri($(this)[0])}},containerization:{id:"tech-containerization",title:z("tech_containerization"),desc:z("tech_containerization_desc"),category:"storage",era:"civilized",reqs:{cement:1,mining:1,storage:1,science:1},grant:["container",1],cost:{Knowledge:()=>2700},effect:z("tech_containerization_effect"),action(){return!!ri($(this)[0])&&(t.city.storage_yard={count:0},!0)}},reinforced_crates:{id:"tech-reinforced_crates",title:z("tech_reinforced_crates"),desc:z("tech_reinforced_crates"),category:"storage",era:"civilized",reqs:{container:1,smelting:2},grant:["container",2],cost:{Knowledge:()=>6750,Sheet_Metal:()=>100},effect(){if(t.race.smoldering||t.race.kindling_kindred||t.race.evil){let e=z("resource_Bones_name");return t.race.smoldering?e=z("resource_Chrysotile_name"):t.race.kindling_kindred&&(e=z("resource_Stone_name")),z("tech_reinforced_crates_alt_effect",[e])}return z("tech_reinforced_crates_effect")},action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},cranes:{id:"tech-cranes",title:z("tech_cranes"),desc:z("tech_cranes_desc"),category:"storage",era:"discovery",reqs:{container:2,high_tech:2},grant:["container",3],cost:{Knowledge:()=>18e3,Copper:()=>1e3,Steel:()=>2500},effect:z("tech_cranes_effect"),action(){return!!ri($(this)[0])}},titanium_crates:{id:"tech-titanium_crates",title:()=>z("tech_titanium_crates",[t.resource.Titanium.name]),desc:()=>z("tech_titanium_crates",[t.resource.Titanium.name]),category:"storage",era:"globalized",reqs:{container:3,titanium:1},grant:["container",4],cost:{Knowledge:()=>67500,Titanium:()=>1e3},effect:()=>z("tech_titanium_crates_effect",[t.resource.Titanium.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},mythril_crates:{id:"tech-mythril_crates",title:()=>z("tech_mythril_crates",[t.resource.Mythril.name]),desc:()=>z("tech_mythril_crates",[t.resource.Mythril.name]),category:"storage",era:"early_space",reqs:{container:4,space:3},grant:["container",5],cost:{Knowledge:()=>145e3,Mythril:()=>350},effect:()=>z("tech_mythril_crates_effect",[t.resource.Mythril.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},infernite_crates:{id:"tech-infernite_crates",title:()=>z("tech_crates",[t.resource.Infernite.name]),desc:()=>z("tech_infernite_crates_desc",[t.resource.Infernite.name]),category:"storage",era:"interstellar",reqs:{container:5,infernite:1},grant:["container",6],cost:{Knowledge:()=>575e3,Infernite:()=>1e3},effect:()=>z("tech_infernite_crates_effect",[t.resource.Infernite.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},graphene_crates:{id:"tech-graphene_crates",title:()=>z("tech_crates",[t.resource.Graphene.name]),desc:()=>z("tech_crates",[t.resource.Graphene.name]),category:"storage",era:"interstellar",path:["standard","truepath"],reqs:{container:6,graphene:1},grant:["container",7],cost:{Knowledge:()=>725e3,Graphene:()=>75e3},effect:()=>z("tech_graphene_crates_effect",[t.resource.Graphene.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},bolognium_crates:{id:"tech-bolognium_crates",title:()=>z("tech_crates",[t.resource.Bolognium.name]),desc:()=>z("tech_crates",[t.resource.Bolognium.name]),category:"storage",era:"intergalactic",reqs:{container:7,gateway:3},grant:["container",8],cost:{Knowledge:()=>342e4,Bolognium:()=>9e4},effect:()=>z("tech_bolognium_crates_effect",[t.resource.Bolognium.name]),action(){return!!ri($(this)[0])}},steel_containers:{id:"tech-steel_containers",title:()=>z("tech_containers",[t.resource.Steel.name]),desc:()=>z("tech_steel_containers_desc",[t.resource.Steel.name]),category:"storage",era:"discovery",reqs:{smelting:2,container:1},grant:["steel_container",1],cost:{Knowledge:()=>9e3,Steel:()=>250},effect(){if(t.race.smoldering||t.race.kindling_kindred||t.race.evil){let e=t.race.kindling_kindred||t.race.smoldering?t.race.smoldering?"Chrysotile":"Stone":"Plywood";return z("tech_steel_containers_alt_effect",[t.resource[e].name,t.resource.Steel.name])}return z("tech_steel_containers_effect",[t.resource.Steel.name])},action(){return!!ri($(this)[0])&&(t.city.warehouse={count:0},!0)}},gantry_crane:{id:"tech-gantry_crane",title:z("tech_gantry_crane"),desc:z("tech_gantry_crane_desc"),category:"storage",era:"discovery",reqs:{steel_container:1,high_tech:2},grant:["steel_container",2],cost:{Knowledge:()=>22500,Steel:()=>5e3},effect:z("tech_gantry_crane_effect"),action(){return!!ri($(this)[0])}},alloy_containers:{id:"tech-alloy_containers",title:()=>z("tech_containers",[t.resource.Alloy.name]),desc:()=>z("tech_alloy_containers_desc",[t.resource.Alloy.name]),category:"storage",era:"industrialized",reqs:{steel_container:2,storage:4},grant:["steel_container",3],cost:{Knowledge:()=>49500,Alloy:()=>2500},effect:()=>z("tech_alloy_containers_effect",[t.resource.Alloy.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},mythril_containers:{id:"tech-mythril_containers",title:()=>z("tech_containers",[t.resource.Mythril.name]),desc:()=>z("tech_mythril_containers_desc",[t.resource.Mythril.name]),category:"storage",era:"early_space",reqs:{steel_container:3,space:3},grant:["steel_container",4],cost:{Knowledge:()=>165e3,Mythril:()=>500},effect:()=>z("tech_mythril_containers_effect",[t.resource.Mythril.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},adamantite_containers:{id:"tech-adamantite_containers",title:()=>z("tech_containers",[t.resource.Adamantite.name]),desc:()=>z("tech_adamantite_containers_desc",[t.resource.Adamantite.name]),category:"storage",era:"interstellar",reqs:{steel_container:4,alpha:2},grant:["steel_container",5],cost:{Knowledge:()=>525e3,Adamantite:()=>17500},effect:()=>z("tech_adamantite_containers_effect",[t.resource.Adamantite.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},aerogel_containers:{id:"tech-aerogel_containers",title:()=>z("tech_containers",[t.resource.Aerogel.name]),desc:()=>z("tech_containers",[t.resource.Aerogel.name]),category:"storage",era:"interstellar",reqs:{steel_container:5,aerogel:1},grant:["steel_container",6],cost:{Knowledge:()=>775e3,Aerogel:()=>500},effect:()=>z("tech_aerogel_containers_effect",[t.resource.Aerogel.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},bolognium_containers:{id:"tech-bolognium_containers",title:()=>z("tech_containers",[t.resource.Bolognium.name]),desc:()=>z("tech_containers",[t.resource.Bolognium.name]),category:"storage",era:"intergalactic",reqs:{steel_container:6,gateway:3},grant:["steel_container",7],cost:{Knowledge:()=>35e5,Bolognium:()=>125e3},effect:()=>z("tech_bolognium_containers_effect",[t.resource.Bolognium.name]),action(){return!!ri($(this)[0])}},nanoweave_containers:{id:"tech-nanoweave_containers",title:()=>z("tech_nanoweave_containers",[t.resource.Nanoweave.name]),desc:()=>z("tech_nanoweave_containers",[t.resource.Nanoweave.name]),category:"storage",era:"intergalactic",reqs:{steel_container:7,nanoweave:1},grant:["steel_container",8],cost:{Knowledge:()=>9e6,Nanoweave:()=>5e4},effect:()=>z("tech_nanoweave_containers_effect",[t.resource.Nanoweave.name]),action(){return!!ri($(this)[0])}},evil_planning:{id:"tech-evil_planning",title:z("tech_urban_planning"),desc:z("tech_urban_planning"),category:"queues",era:"civilized",wiki:!!t.race.terrifying,reqs:{banking:2},grant:["queue",1],trait:["terrifying"],cost:{Knowledge:()=>2500},effect:z("tech_urban_planning_effect"),action(){return!!ri($(this)[0])&&(t.queue.display=!0,!0)},post(){vs()}},urban_planning:{id:"tech-urban_planning",title:z("tech_urban_planning"),desc:z("tech_urban_planning"),category:"queues",era:"civilized",wiki:!t.race.terrifying,reqs:{banking:2,currency:2},grant:["queue",1],not_trait:["terrifying"],cost:{Knowledge:()=>2500},effect:z("tech_urban_planning_effect"),action(){return!!ri($(this)[0])&&(t.queue.display=!0,t.settings.msgFilters.queue.unlocked||(t.settings.msgFilters.queue.unlocked=!0,t.settings.msgFilters.queue.vis=!0),!0)},post(){vs()}},zoning_permits:{id:"tech-zoning_permits",title:z("tech_zoning_permits"),desc:z("tech_zoning_permits"),category:"queues",era:"industrialized",reqs:{queue:1,high_tech:3},grant:["queue",2],cost:{Knowledge:()=>28e3},effect:()=>z("tech_zoning_permits_effect",[t.genes.queue&&t.genes.queue>=2?4:2]),action(){return!!ri($(this)[0])},post(){vs()}},urbanization:{id:"tech-urbanization",title:z("tech_urbanization"),desc:z("tech_urbanization"),category:"queues",era:"globalized",reqs:{queue:2,high_tech:6},grant:["queue",3],cost:{Knowledge:()=>95e3},effect:()=>z("tech_urbanization_effect",[t.genes.queue&&t.genes.queue>=2?6:3]),action(){return!!ri($(this)[0])},post(){vs()}},assistant:{id:"tech-assistant",title:z("tech_assistant"),desc:z("tech_assistant"),category:"queues",era:"civilized",reqs:{queue:1,science:4},grant:["r_queue",1],cost:{Knowledge:()=>5e3},effect:z("tech_assistant_effect"),action(){return!!ri($(this)[0])&&(t.r_queue.display=!0,t.settings.msgFilters.building_queue.unlocked||(t.settings.msgFilters.building_queue.unlocked=!0,t.settings.msgFilters.building_queue.vis=!0,t.settings.msgFilters.research_queue.unlocked=!0,t.settings.msgFilters.research_queue.vis=!0),!0)},post(){fs(),t.settings.tabLoad&&$("#resQueue").removeAttr("style")}},government:{id:"tech-government",title:z("tech_government"),desc:z("tech_government_desc"),category:"government",era:"civilized",reqs:{currency:1},grant:["govern",1],cost:{Knowledge:()=>750},effect:z("tech_government_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#govType"},"update"),Cs({el:"#foreign"},"update"),Cs({el:"#government .govTabs2"},"update"),t.settings.tabLoad&&$("#government .govTabs2").removeAttr("style")}},theocracy:{id:"tech-theocracy",title:z("govern_theocracy"),desc:z("govern_theocracy"),category:"government",era:"civilized",reqs:{govern:1,theology:2},grant:["gov_theo",1],cost:{Knowledge:()=>1200},effect:z("tech_theocracy_effect"),action(){return!!ri($(this)[0])}},republic:{id:"tech-republic",title:z("govern_republic"),desc:z("govern_republic"),category:"government",era:"discovery",reqs:{govern:1},condition:()=>!!(t.tech.trade&&t.tech.trade>=2||t.race.terrifying),grant:["govern",2],cost:{Knowledge:()=>17e3},effect:z("tech_republic_effect"),action(){return!!ri($(this)[0])}},socialist:{id:"tech-socialist",title:z("govern_socialist"),desc:z("govern_socialist"),category:"government",era:"discovery",reqs:{govern:1},condition:()=>!!(t.tech.trade&&t.tech.trade>=2||t.race.terrifying),grant:["gov_soc",1],cost:{Knowledge:()=>17e3},effect:z("tech_socialist_effect"),action(){return!!ri($(this)[0])}},corpocracy:{id:"tech-corpocracy",title:z("govern_corpocracy"),desc:z("govern_corpocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},grant:["gov_corp",1],cost:{Knowledge:()=>26e3},effect:z("tech_corpocracy_effect"),action(){return!!ri($(this)[0])}},technocracy:{id:"tech-technocracy",title:z("govern_technocracy"),desc:z("govern_technocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},grant:["govern",3],cost:{Knowledge:()=>26e3},effect:z("tech_technocracy_effect"),action(){return!!ri($(this)[0])}},federation:{id:"tech-federation",title:z("govern_federation"),desc:z("govern_federation"),category:"government",era:"early_space",reqs:{govern:2},condition:()=>t.tech.unify&&t.tech.unify>=2||ce(),grant:["gov_fed",1],cost:{Knowledge:()=>3e4},effect:z("tech_federation_effect"),action(){return!!ri($(this)[0])}},magocracy:{id:"tech-magocracy",title:z("govern_magocracy"),desc:z("govern_magocracy"),category:"government",era:"industrialized",reqs:{govern:2,high_tech:3},condition:()=>"magic"===t.race.universe,grant:["gov_mage",1],cost:{Knowledge:()=>26e3},effect:z("tech_magocracy_effect"),action(){return!!ri($(this)[0])}},governor:{id:"tech-governor",title:z("tech_governor"),desc:z("tech_governor"),category:"government",era:"civilized",reqs:{govern:1},condition:()=>!(!t.genes.governor||"anarchy"===t.civic.govern.type),grant:["governor",1],cost:{Knowledge:()=>1e3},effect:z("tech_governor_effect"),action(){return!!ri($(this)[0])&&(t.settings.showGovernor=!0,!0)},post(){L()}},spy:{id:"tech-spy",title:z("tech_spy"),desc:z("tech_spy"),category:"spies",era:"civilized",reqs:{govern:1},grant:["spy",1],cost:{Knowledge:()=>1250},effect:z("tech_spy_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#foreign"},"update")}},espionage:{id:"tech-espionage",title:z("tech_espionage"),desc:z("tech_espionage"),category:"spies",era:"discovery",reqs:{spy:1,high_tech:1},grant:["spy",2],cost:{Knowledge:()=>7500},effect:z("tech_espionage_effect"),action(){return!!ri($(this)[0])&&(t.settings.msgFilters.spy.unlocked||(t.settings.msgFilters.spy.unlocked=!0,t.settings.msgFilters.spy.vis=!0),!0)},post(){Cs({el:"#foreign"},"update")}},spy_training:{id:"tech-spy_training",title:z("tech_spy_training"),desc:z("tech_spy_training"),category:"spies",era:"discovery",reqs:{spy:2,boot_camp:1},grant:["spy",3],cost:{Knowledge:()=>1e4},effect:z("tech_spy_training_effect"),action(){return!!ri($(this)[0])}},spy_gadgets:{id:"tech-spy_gadgets",title:z("tech_spy_gadgets"),desc:z("tech_spy_gadgets"),category:"spies",era:"discovery",reqs:{spy:3,high_tech:2},grant:["spy",4],cost:{Knowledge:()=>15e3},effect:z("tech_spy_gadgets_effect"),action(){return!!ri($(this)[0])}},code_breakers:{id:"tech-code_breakers",title:z("tech_code_breakers"),desc:z("tech_code_breakers"),category:"spies",era:"industrialized",reqs:{spy:4,high_tech:4},grant:["spy",5],cost:{Knowledge:()=>55e3},effect:z("tech_code_breakers_effect"),action(){return!!ri($(this)[0])}},currency:{id:"tech-currency",title:z("tech_currency"),desc:z("tech_currency_desc"),category:"banking",era:"civilized",reqs:{housing:1},grant:["currency",1],cost:{Knowledge:()=>22,Lumber:()=>10},effect:z("tech_currency_effect"),action(){return!!ri($(this)[0])&&(t.resource.Money.display=!0,!0)}},market:{id:"tech-market",title:z("tech_market"),desc:z("tech_market_desc"),category:"banking",era:"civilized",reqs:{banking:1,govern:1},not_trait:["terrifying"],grant:["currency",2],cost:{Knowledge:()=>t.race.banana?300:1800},effect:z("tech_market_effect"),action(){return!!ri($(this)[0])&&(t.settings.showResources=!0,t.settings.showMarket=!0,!0)}},tax_rates:{id:"tech-tax_rates",title:z("tech_tax_rates"),desc:z("tech_tax_rates_desc"),category:"banking",era:"civilized",reqs:{banking:2,currency:2,queue:1},not_trait:["terrifying"],grant:["currency",3],cost:{Knowledge:()=>3375},effect:z("tech_tax_rates_effect"),action(){return!!ri($(this)[0])&&(t.civic.taxes.display=!0,!0)}},large_trades:{id:"tech-large_trades",title:z("tech_large_trades"),desc:z("tech_large_trades_desc"),category:"market",era:"civilized",reqs:{currency:3},not_trait:["terrifying"],grant:["currency",4],cost:{Knowledge:()=>6750},effect:z("tech_large_trades_effect"),action(){return!!ri($(this)[0])},post(){t.race.noble&&(t.tech.currency=5,Qr())}},corruption:{id:"tech-corruption",title:z("tech_corruption"),desc:z("tech_corruption_desc"),category:"banking",era:"industrialized",reqs:{currency:4,high_tech:3},not_trait:["terrifying","noble"],grant:["currency",5],cost:{Knowledge:()=>36e3},effect:z("tech_corruption_effect"),action(){return!!ri($(this)[0])}},massive_trades:{id:"tech-massive_trades",title:z("tech_massive_trades"),desc:z("tech_massive_trades_desc"),category:"market",era:"globalized",reqs:{currency:5,high_tech:4},not_trait:["terrifying"],grant:["currency",6],cost:{Knowledge:()=>108e3},effect:z("tech_massive_trades_effect"),action(){return!!ri($(this)[0])}},trade:{id:"tech-trade",title:z("tech_trade"),desc:z("tech_trade_desc"),category:"market",era:"civilized",reqs:{currency:2,military:1},not_trait:["terrifying"],grant:["trade",1],cost:{Knowledge:()=>t.race.banana?1200:4500},effect:z("tech_trade_effect"),action(){return!!ri($(this)[0])&&(t.city.trade={count:0},t.city.market.active=!0,!0)}},diplomacy:{id:"tech-diplomacy",title:z("tech_diplomacy"),desc:z("tech_diplomacy_desc"),category:"market",era:"discovery",reqs:{trade:1,high_tech:1},not_trait:["terrifying"],grant:["trade",2],cost:{Knowledge:()=>16200},effect:z("tech_diplomacy_effect"),action(){return!!ri($(this)[0])}},freight:{id:"tech-freight",title:z("tech_freight"),desc:z("tech_freight_desc"),category:"market",era:"industrialized",reqs:{trade:2,high_tech:3},not_trait:["terrifying"],grant:["trade",3],cost:{Knowledge:()=>37800},effect:z("tech_freight_effect"),action(){return!!ri($(this)[0])},post(){t.tech.high_tech>=6&&xe("Physics")}},wharf:{id:"tech-wharf",title:z("tech_wharf"),desc:z("tech_wharf_desc"),category:"market",era:"industrialized",reqs:{trade:1,high_tech:3,oil:1},not_trait:["thalassophobia"],grant:["wharf",1],cost:{Knowledge:()=>44e3},effect:z("tech_wharf_effect"),action(){return!!ri($(this)[0])&&(t.city.wharf={count:0},!0)}},banking:{id:"tech-banking",title:z("tech_banking"),desc:z("tech_banking_desc"),category:"banking",era:"civilized",reqs:{currency:1},grant:["banking",1],cost:{Knowledge:()=>90},effect:z("tech_banking_effect"),action(){return!!ri($(this)[0])&&(t.city.bank={count:0},!0)}},investing:{id:"tech-investing",title:z("tech_investing"),desc:z("tech_investing_desc"),category:"banking",era:"civilized",reqs:{banking:1},grant:["banking",2],cost:{Money:()=>2500,Knowledge:()=>900},effect:z("tech_investing_effect"),action(){return!!ri($(this)[0])&&(t.civic.banker.display=!0,!0)}},vault:{id:"tech-vault",title:z("tech_vault"),desc:z("tech_vault_desc"),category:"banking",era:"civilized",reqs:{banking:2,cement:1},grant:["banking",3],cost:{Money:()=>2e3,Knowledge:()=>3600,Iron:()=>500,Cement:()=>750},effect:z("tech_vault_effect"),action(){return!!ri($(this)[0])}},bonds:{id:"tech-bonds",title:z("tech_bonds"),desc:z("tech_bonds"),category:"banking",era:"civilized",reqs:{banking:3},grant:["banking",4],cost:{Money:()=>2e4,Knowledge:()=>5e3},effect:z("tech_bonds_effect"),action(){return!!ri($(this)[0])}},steel_vault:{id:"tech-steel_vault",title:z("tech_steel_vault"),desc:z("tech_steel_vault"),category:"banking",era:"civilized",reqs:{banking:4,smelting:2},grant:["banking",5],cost:{Money:()=>3e4,Knowledge:()=>6750,Steel:()=>3e3},effect:z("tech_steel_vault_effect"),action(){return!!ri($(this)[0])}},eebonds:{id:"tech-eebonds",title:z("tech_eebonds"),desc:z("tech_eebonds"),category:"banking",era:"discovery",reqs:{banking:5,high_tech:1},grant:["banking",6],cost:{Money:()=>75e3,Knowledge:()=>18e3},effect:z("tech_eebonds_effect"),action(){return!!ri($(this)[0])}},swiss_banking:{id:"tech-swiss_banking",title:Pr(),desc:Pr(),category:"banking",era:"industrialized",reqs:{banking:6},grant:["banking",7],cost:{Money:()=>125e3,Knowledge:()=>45e3},effect:z("tech_swiss_banking_effect"),action(){return!!ri($(this)[0])}},safety_deposit:{id:"tech-safety_deposit",title:z("tech_safety_deposit"),desc:z("tech_safety_deposit"),category:"banking",era:"globalized",reqs:{banking:7,high_tech:4},grant:["banking",8],cost:{Money:()=>25e4,Knowledge:()=>67500},effect:z("tech_safety_deposit_effect"),action(){return!!ri($(this)[0])}},stock_market:{id:"tech-stock_market",title:z("tech_stock_market"),desc:z("tech_stock_market"),category:"arpa",era:"globalized",reqs:{banking:8,high_tech:6},grant:["banking",9],cost:{Money:()=>325e3,Knowledge:()=>108e3},effect:z("tech_stock_market_effect"),action(){return!!ri($(this)[0])},post(){xe("Physics")}},hedge_funds:{id:"tech-hedge_funds",title:z("tech_hedge_funds"),desc:z("tech_hedge_funds"),category:"banking",era:"early_space",reqs:{banking:9,stock_exchange:1},grant:["banking",10],cost:{Money:()=>375e3,Knowledge:()=>126e3},effect:z("tech_hedge_funds_effect"),action(){return!!ri($(this)[0])}},four_oh_one:{id:"tech-four_oh_one",title:z("tech_four_oh_one"),desc:z("tech_four_oh_one"),category:"banking",era:"early_space",reqs:{banking:10},grant:["banking",11],cost:{Money:()=>425e3,Knowledge:()=>144e3},effect:z("tech_four_oh_one_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_four_oh_one_flair")},exchange:{id:"tech-exchange",title:z("tech_exchange"),desc:z("tech_exchange"),category:"banking",era:"interstellar",reqs:{banking:11,alpha:2,graphene:1},grant:["banking",12],cost:{Money:()=>1e6,Knowledge:()=>675e3},effect:z("tech_exchange_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.exchange={count:0,on:0},!0)}},foreign_investment:{id:"tech-foreign_investment",title:z("tech_foreign_investment"),desc:z("tech_foreign_investment"),category:"banking",era:"intergalactic",reqs:{banking:12,xeno:10},grant:["banking",13],cost:{Money:()=>1e8,Knowledge:()=>8e6},effect:z("tech_foreign_investment_effect"),action(){return!!ri($(this)[0])}},mythril_vault:{id:"tech-mythril_vault",title:z("tech_mythril_vault"),desc:z("tech_mythril_vault"),category:"banking",era:"early_space",reqs:{banking:5,space:3},grant:["vault",1],cost:{Money:()=>5e5,Knowledge:()=>15e4,Mythril:()=>750},effect:z("tech_mythril_vault_effect"),action(){return!!ri($(this)[0])}},neutronium_vault:{id:"tech-neutronium_vault",title:z("tech_neutronium_vault"),desc:z("tech_neutronium_vault"),category:"banking",era:"deep_space",reqs:{vault:1,gas_moon:1},grant:["vault",2],cost:{Money:()=>75e4,Knowledge:()=>28e4,Neutronium:()=>650},effect:z("tech_neutronium_vault_effect"),action(){return!!ri($(this)[0])}},adamantite_vault:{id:"tech-adamantite_vault",title:z("tech_adamantite_vault"),desc:z("tech_adamantite_vault"),category:"banking",era:"interstellar",reqs:{vault:2,alpha:2},grant:["vault",3],cost:{Money:()=>2e6,Knowledge:()=>56e4,Adamantite:()=>2e4},effect:z("tech_adamantite_vault_effect"),action(){return!!ri($(this)[0])}},graphene_vault:{id:"tech-graphene_vault",title:z("tech_graphene_vault"),desc:z("tech_graphene_vault"),category:"banking",era:"interstellar",path:["standard","truepath"],reqs:{vault:3,graphene:1},grant:["vault",4],cost:{Money:()=>3e6,Knowledge:()=>75e4,Graphene:()=>4e5},effect:z("tech_graphene_vault_effect"),action(){return!!ri($(this)[0])}},home_safe:{id:"tech-home_safe",title:z("tech_home_safe"),desc:z("tech_home_safe"),category:"banking",era:"discovery",reqs:{banking:5},grant:["home_safe",1],cost:{Money:()=>42e3,Knowledge:()=>8e3,Steel:()=>4500},effect:z("tech_home_safe_effect"),action(){return!!ri($(this)[0])}},fire_proof_safe:{id:"tech-fire_proof_safe",title:z("tech_fire_proof_safe"),desc:z("tech_fire_proof_safe"),category:"banking",era:"early_space",reqs:{home_safe:1,space:3},grant:["home_safe",2],cost:{Money:()=>25e4,Knowledge:()=>12e4,Iridium:()=>1e3},effect:z("tech_fire_proof_safe_effect"),action(){return!!ri($(this)[0])}},tamper_proof_safe:{id:"tech-tamper_proof_safe",title:z("tech_tamper_proof_safe"),desc:z("tech_tamper_proof_safe"),category:"banking",era:"interstellar",reqs:{home_safe:2,infernite:1},grant:["home_safe",3],cost:{Money:()=>25e5,Knowledge:()=>6e5,Infernite:()=>800},effect:z("tech_tamper_proof_safe_effect"),action(){return!!ri($(this)[0])}},monument:{id:"tech-monument",title:z("tech_monument"),desc:z("tech_monument"),category:"arpa",era:"globalized",reqs:{high_tech:6},grant:["monument",1],cost:{Knowledge:()=>12e4},effect:z("tech_monument_effect"),action(){return!!ri($(this)[0])&&(t.arpa.m_type=xe("Monument"),!0)},post(){xe("Physics")}},tourism:{id:"tech-tourism",title:z("tech_tourism"),desc:z("tech_tourism"),category:"banking",era:"early_space",reqs:{monuments:2,monument:1},not_trait:["cataclysm","lone_survivor"],grant:["monument",2],cost:{Knowledge:()=>15e4},effect:z("tech_tourism_effect"),action(){return!!ri($(this)[0])&&(t.city.tourist_center={count:0,on:0},!0)}},xeno_tourism:{id:"tech-xeno_tourism",title:z("tech_xeno_tourism"),desc:z("tech_xeno_tourism"),category:"banking",era:"intergalactic",reqs:{monument:2,xeno:10,monuments:10},not_trait:["cataclysm"],grant:["monument",3],cost:{Knowledge:()=>8e6},effect:z("tech_xeno_tourism_effect"),action(){return!!ri($(this)[0])}},science:{id:"tech-science",title:z("tech_science"),desc:z("tech_science_desc"),category:"science",era:"civilized",reqs:{housing:1},grant:["science",1],cost:{Knowledge:()=>65},effect:z("tech_science_effect"),action(){return!!ri($(this)[0])&&(t.city.university={count:0},!0)}},library:{id:"tech-library",title:z("tech_library"),desc:z("tech_library_desc"),category:"science",era:"civilized",reqs:{science:1,cement:1},grant:["science",2],cost:{Knowledge:()=>720},effect:z("tech_library_effect"),action(){return!!ri($(this)[0])&&(t.city.library={count:0},!0)}},thesis:{id:"tech-thesis",title:z("tech_thesis"),desc:z("tech_thesis_desc"),category:"science",era:"civilized",reqs:{science:2},grant:["science",3],cost:{Knowledge:()=>1125},effect:z("tech_thesis_effect"),action(){return!!ri($(this)[0])}},research_grant:{id:"tech-research_grant",title:z("tech_research_grant"),desc:z("tech_research_grant_desc"),category:"science",era:"civilized",reqs:{science:3},grant:["science",4],cost:{Knowledge:()=>3240},effect:z("tech_research_grant_effect"),action(){return!!ri($(this)[0])}},scientific_journal:{id:"tech-scientific_journal",title:()=>"magic"===t.race.universe?z("tech_magic_tomes"):z("tech_scientific_journal"),desc:()=>"magic"===t.race.universe?z("tech_magic_tomes_desc"):z("tech_scientific_journal_desc"),category:"science",era:"industrialized",reqs:{science:4,high_tech:3},grant:["science",5],cost:{Knowledge:()=>27e3},effect:()=>"magic"===t.race.universe?z("tech_magic_tomes_effect"):z("tech_scientific_journal_effect"),action(){return!!ri($(this)[0])}},adjunct_professor:{id:"tech-adjunct_professor",title:z("tech_adjunct_professor"),desc:z("tech_adjunct_professor"),category:"science",era:"industrialized",reqs:{science:5},grant:["science",6],cost:{Knowledge:()=>36e3},effect:()=>z("tech_adjunct_professor_effect",[_i(),t.civic.scientist?t.civic.scientist.name:z("job_scientist")]),action(){return!!ri($(this)[0])}},tesla_coil:{id:"tech-tesla_coil",title:z("tech_tesla_coil"),desc:z("tech_tesla_coil_desc"),category:"science",era:"industrialized",reqs:{science:6,high_tech:3},grant:["science",7],cost:{Knowledge:()=>51750},effect:()=>z("tech_tesla_coil_effect",[_i()]),action(){return!!ri($(this)[0])}},internet:{id:"tech-internet",title:z("tech_internet"),desc:z("tech_internet"),category:"science",era:"globalized",reqs:{science:7,high_tech:4},grant:["science",8],cost:{Knowledge:()=>61200},effect:z("tech_internet_effect"),action(){return!!ri($(this)[0])&&(t.race.toxic&&"troll"===t.race.species&&qn("godwin"),!0)}},observatory:{id:"tech-observatory",title:z("tech_observatory"),desc:z("tech_observatory"),category:"science",era:"early_space",reqs:{science:8,space:3,luna:1},grant:["science",9],cost:{Knowledge:()=>148e3},effect:z("tech_observatory_effect"),action(){return!!ri($(this)[0])&&(t.space.observatory={count:0,on:0},!0)}},world_collider:{id:"tech-world_collider",title:z("tech_world_collider"),desc:z("tech_world_collider"),category:"science",era:"deep_space",path:["standard"],reqs:{science:9,elerium:2},grant:["science",10],cost:{Knowledge:()=>35e4},effect:()=>z("tech_world_collider_effect",[Ut().dwarf]),action(){return!!ri($(this)[0])&&(t.space.world_collider={count:0},t.space.world_controller={count:0,on:0},!0)},flair:`
                            ${z("tech_world_collider_flair1")}
                            ${z("tech_world_collider_flair2")}
                            `},laboratory:{id:"tech-laboratory",title:()=>"magic"===t.race.universe?z("tech_sanctum"):z("tech_laboratory"),desc:()=>"magic"===t.race.universe?z("tech_sanctum"):z("tech_laboratory_desc"),category:"science",era:"interstellar",reqs:{science:11,alpha:2},grant:["science",12],cost:{Knowledge:()=>5e5},effect:()=>"magic"===t.race.universe?z("tech_sanctum_effect"):z("tech_laboratory_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.laboratory={count:0,on:0},!0)},flair:()=>"magic"===t.race.universe?z("tech_sanctum_flair"):z("tech_laboratory_flair")},virtual_assistant:{id:"tech-virtual_assistant",title:z("tech_virtual_assistant"),desc:z("tech_virtual_assistant"),category:"science",era:"interstellar",reqs:{science:12,high_tech:12},grant:["science",13],cost:{Knowledge:()=>635e3},effect:()=>"magic"===t.race.universe?z("tech_virtual_assistant_magic_effect"):z("tech_virtual_assistant_effect"),action(){return!!ri($(this)[0])}},dimensional_readings:{id:"tech-dimensional_readings",title:z("tech_dimensional_readings"),desc:z("tech_dimensional_readings"),category:"science",era:"interstellar",reqs:{science:13,infernite:2},grant:["science",14],cost:{Knowledge:()=>75e4},effect:()=>z("tech_dimensional_readings_effect"),action(){return!!ri($(this)[0])}},quantum_entanglement:{id:"tech-quantum_entanglement",title:z("tech_quantum_entanglement"),desc:z("tech_quantum_entanglement"),category:"science",era:"interstellar",reqs:{science:14,neutron:1},grant:["science",15],cost:{Knowledge:()=>85e4,Neutronium:()=>7500,Soul_Gem:()=>2},effect:()=>z("tech_quantum_entanglement_effect",[2,"magic"===t.race.universe?z("tech_sanctum"):z("interstellar_laboratory_title"),_i()]),action(){return!!ri($(this)[0])}},expedition:{id:"tech-expedition",title:()=>"magic"===t.race.universe?z("tech_expedition_wiz"):z("tech_expedition"),desc:()=>"magic"===t.race.universe?z("tech_expedition_wiz"):z("tech_expedition"),category:"science",era:"intergalactic",reqs:{science:15,xeno:4},grant:["science",16],cost:{Knowledge:()=>535e4},effect:()=>"magic"===t.race.universe?z("tech_expedition_wiz_effect"):z("tech_expedition_effect"),action(){return!!ri($(this)[0])}},subspace_sensors:{id:"tech-subspace_sensors",title:z("tech_subspace_sensors"),desc:z("tech_subspace_sensors"),category:"science",era:"intergalactic",reqs:{science:16,high_tech:16},grant:["science",17],cost:{Knowledge:()=>6e6},effect:()=>z("tech_subspace_sensors_effect"),action(){return!!ri($(this)[0])}},alien_database:{id:"tech-alien_database",title:z("tech_alien_database"),desc:z("tech_alien_database"),category:"progress",era:"intergalactic",reqs:{science:17,conflict:5},grant:["science",18],cost:{Knowledge:()=>825e4},effect:()=>z("tech_alien_database_effect"),action(){return!!ri($(this)[0])}},orichalcum_capacitor:{id:"tech-orichalcum_capacitor",title:z("tech_orichalcum_capacitor"),desc:z("tech_orichalcum_capacitor"),category:"science",era:"intergalactic",reqs:{science:18,high_tech:17},grant:["science",19],cost:{Knowledge:()=>125e5,Orichalcum:()=>25e4},effect:()=>z("tech_orichalcum_capacitor_effect"),action(){return!!ri($(this)[0])}},advanced_biotech:{id:"tech-advanced_biotech",title:z("tech_advanced_biotech"),desc:z("tech_advanced_biotech"),category:"science",era:"dimensional",reqs:{science:19,high_tech:18},grant:["science",20],cost:{Knowledge:()=>255e5},effect:()=>z("tech_advanced_biotech_effect"),action(){return!!ri($(this)[0])}},codex_infinium:{id:"tech-codex_infinium",title:z("tech_codex_infinium"),desc:z("tech_codex_infinium"),category:"science",era:"dimensional",reqs:{science:20,sphinx_bribe:1},grant:["science",21],cost:{Knowledge:()=>401e5,Codex:()=>1},effect:()=>z("tech_codex_infinium_effect"),action(){return!!ri($(this)[0])&&(t.resource.Codex.display=!1,!0)}},bioscience:{id:"tech-bioscience",title:z("tech_bioscience"),desc:z("tech_bioscience_desc"),category:"science",era:"globalized",reqs:{science:8},grant:["genetics",1],cost:{Knowledge:()=>67500},effect:z("tech_bioscience_effect"),action(){return!!ri($(this)[0])&&(t.city.biolab={count:0},!0)}},genetics:{id:"tech-genetics",title:z("tech_genetics"),desc:z("tech_genetics"),category:"arpa",era:"globalized",reqs:{genetics:1,high_tech:6},grant:["genetics",2],cost:{Knowledge:()=>108e3},effect:z("tech_genetics_effect"),action(){return!!ri($(this)[0])&&(t.settings.arpa.genetics=!0,t.arpa.sequence||(t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!t.race.cataclysm&&!t.race.orbit_decayed,boost:!1,auto:!1,labs:0}),!0)},post(){xe("Genetics")}},crispr:{id:"tech-crispr",title:z("tech_crispr"),desc:z("tech_crispr"),category:"genes",era:"globalized",reqs:{genetics:3},grant:["genetics",4],cost:{Knowledge:()=>125e3},effect:()=>t.race.artifical?z("tech_crispr_effect_artifical"):z("tech_crispr_effect"),action(){return!!ri($(this)[0])&&(t.settings.arpa.crispr=!0,t.settings.arpa.arpaTabs=2,!0)},post(){xe("Genetics"),xe("Crispr")}},shotgun_sequencing:{id:"tech-shotgun_sequencing",title:z("tech_shotgun_sequencing"),desc:()=>t.race.artifical?z("tech_shotgun_sequencing_desc_artifical"):z("tech_shotgun_sequencing_desc"),category:"genes",era:"early_space",reqs:{genetics:4},grant:["genetics",5],cost:{Knowledge:()=>165e3},effect:()=>t.race.artifical?z("tech_shotgun_sequencing_effect_artifical"):z("tech_shotgun_sequencing_effect"),action(){return!!ri($(this)[0])&&(t.arpa.sequence.boost=!0,!0)},post(){xe("Genetics")}},de_novo_sequencing:{id:"tech-de_novo_sequencing",title:z("tech_de_novo_sequencing"),desc:z("tech_de_novo_sequencing"),category:"genes",era:"early_space",reqs:{genetics:5},grant:["genetics",6],cost:{Knowledge:()=>22e4},effect:()=>t.race.artifical?z("tech_de_novo_sequencing_effect_artifical"):z("tech_de_novo_sequencing_effect"),action(){return!!ri($(this)[0])&&(t.resource.Genes.display=!0,!0)},post(){xe("Genetics")}},dna_sequencer:{id:"tech-dna_sequencer",title:()=>t.race.artifical?z("tech_code_sequencer"):z("tech_dna_sequencer"),desc:()=>t.race.artifical?z("tech_code_sequencer"):z("tech_dna_sequencer"),category:"genes",era:"deep_space",reqs:{genetics:6},grant:["genetics",7],cost:{Knowledge:()=>3e5},effect:()=>t.race.artifical?z("tech_code_sequencer_effect"):z("tech_dna_sequencer_effect"),action(){return!!ri($(this)[0])&&(t.arpa.sequence.auto=!0,!0)},post(){xe("Genetics")}},rapid_sequencing:{id:"tech-rapid_sequencing",title:()=>t.race.artifical?z("tech_agile_development"):z("tech_rapid_sequencing"),desc:()=>t.race.artifical?z("tech_agile_development"):z("tech_rapid_sequencing"),category:"genes",era:"interstellar",path:["standard","truepath"],reqs:{genetics:7,high_tech:12},grant:["genetics",8],cost:{Knowledge:()=>8e5},effect:()=>t.race.artifical?z("tech_agile_development_effect"):z("tech_rapid_sequencing_effect"),action(){return!!ri($(this)[0])}},mad_science:{id:"tech-mad_science",title:()=>"magic"===t.race.universe?z("tech_sages"):z("tech_mad_science"),desc:()=>"magic"===t.race.universe?z("tech_sages"):z("tech_mad_science"),category:"science",era:"discovery",reqs:{science:2,smelting:2},grant:["high_tech",1],cost:{Money:()=>1e4,Mana:()=>"magic"===t.race.universe?50:0,Knowledge:()=>6750,Crystal:()=>"magic"===t.race.universe?1e3:0,Aluminium:()=>750},effect:()=>"magic"===t.race.universe?z("tech_sages_effect"):z("tech_mad_science_effect"),action(){return!!ri($(this)[0])&&(t.race.terrifying&&(t.civic.taxes.display=!0),t.city.wardenclyffe={count:0,on:0},!0)}},electricity:{id:"tech-electricity",title:z("tech_electricity"),desc:z("tech_electricity"),category:"power_generation",era:"discovery",reqs:{high_tech:1},grant:["high_tech",2],cost:{Knowledge:()=>13500,Copper:()=>1e3},effect:z("tech_electricity_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_electricity_msg"),"info",!1,["progress"]),t.city.power=0,t.city.powered=!0,t.city.coal_power={count:0,on:0},t.settings.showPowerGrid=!0,Mi(),!0)}},matter_replicator:{id:"tech-matter_replicator",title:()=>"antimatter"!==t.race.universe||t.race.amexplode?z("tech_replicator"):z("tech_antireplicator"),desc:()=>"antimatter"!==t.race.universe||t.race.amexplode?z("tech_replicator"):z("tech_antireplicator"),category:"special",era:"discovery",reqs:{high_tech:2},condition:()=>!!(t.stats.achieve.adam_eve&&t.stats.achieve.adam_eve.l>=5),not_trait:["lone_survivor"],grant:["replicator",1],cost:{Knowledge:()=>25e3},effect:()=>"antimatter"!==t.race.universe||t.race.amexplode?z("tech_replicator_effect_alt"):z("tech_antireplicator_effect_alt"),action(){if(ri($(this)[0])){if("antimatter"===t.race.universe&&t.race.amexplode){Pn("annihilation"),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),$("body").addClass("nuke");let a=$('
                            ');$("body").append(a),setTimeout((function(){a.addClass("burn")}),500),setTimeout((function(){a.addClass("b")}),600),setTimeout((function(){window.soft_reset()}),4e3)}else t.race.replicator={res:"Stone",pow:1};return!0}return!1},post(){L()}},industrialization:{id:"tech-industrialization",title:z("tech_industrialization"),desc:z("tech_industrialization"),category:"progress",era:"industrialized",reqs:{high_tech:2,cement:2,steel_container:1},grant:["high_tech",3],cost:{Knowledge:()=>25200},effect:z("tech_industrialization_effect"),action(){return!!ri($(this)[0])&&(t.resource.Titanium.display=!0,t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:0,Nano:0,Stanene:0},!0)},post(){cs()}},electronics:{id:"tech-electronics",title:z("tech_electronics"),desc:z("tech_electronics"),category:"progress",era:"industrialized",reqs:{high_tech:3,titanium:1},grant:["high_tech",4],cost:{Knowledge:()=>5e4},effect:z("tech_electronics_effect"),action(){return!!ri($(this)[0])&&(t.race.terrifying&&(t.tech.gambling=1,t.city.casino={count:0,on:0},t.space.spc_casino={count:0,on:0}),!0)}},fission:{id:"tech-fission",title:z("tech_fission"),desc:z("tech_fission"),category:"progress",era:"globalized",reqs:{high_tech:4,uranium:1},grant:["high_tech",5],cost:{Knowledge:()=>77400,Uranium:()=>10},effect:z("tech_fission_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_fission_msg"),"info",!1,["progress"]),t.city.fission_power={count:0,on:0},!0)}},arpa:{id:"tech-arpa",title:z("tech_arpa"),desc:z("tech_arpa_desc"),category:"arpa",era:"globalized",reqs:{high_tech:5},grant:["high_tech",6],cost:{Knowledge:()=>9e4},effect:z("tech_arpa_effect"),action(){return!!ri($(this)[0])&&(t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.race.truepath&&!t.tech.unify&&(t.tech.unify=1),!0)},post(){xe("Physics")}},rocketry:{id:"tech-rocketry",title:z("tech_rocketry"),desc:z("tech_rocketry"),category:"arpa",era:"globalized",reqs:{high_tech:6},grant:["high_tech",7],cost:{Knowledge:()=>112500,Oil:()=>t.city.ptrait.includes("dense")?8e3:6800},effect:z("tech_rocketry_effect"),action(){return!!ri($(this)[0])&&(t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,hs(z("civics_rival_unlocked",[Z(3)]),"info",!1,["progress","combat"])),!0)},post(){xe("Physics")}},robotics:{id:"tech-robotics",title:z("tech_robotics"),desc:z("tech_robotics"),category:"progress",era:"globalized",reqs:{high_tech:7},grant:["high_tech",8],cost:{Knowledge:()=>125e3},effect:z("tech_robotics_effect"),action(){return!!ri($(this)[0])}},lasers:{id:"tech-lasers",title:z("tech_lasers"),desc:z("tech_lasers_desc"),category:"progress",era:"deep_space",reqs:{high_tech:8,space:3,supercollider:1,elerium:1},grant:["high_tech",9],cost:{Knowledge:()=>28e4,Elerium:()=>100},effect:z("tech_lasers_effect"),action(){return!!ri($(this)[0])&&(t.race.cataclysm&&qn("iron_will",!1,3),!0)}},artifical_intelligence:{id:"tech-artifical_intelligence",title:z("tech_artificial_intelligence"),desc:z("tech_artificial_intelligence"),category:"progress",era:"deep_space",reqs:{high_tech:9},grant:["high_tech",10],cost:{Knowledge:()=>325e3},effect:z("tech_artificial_intelligence_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_artificial_intelligence_flair")},quantum_computing:{id:"tech-quantum_computing",title:z("tech_quantum_computing"),desc:z("tech_quantum_computing"),category:"progress",era:"deep_space",reqs:{high_tech:10,nano:1},grant:["high_tech",11],cost:{Knowledge:()=>435e3,Elerium:()=>250,Nano_Tube:()=>1e5},effect:z("tech_quantum_computing_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_quantum_computing_flair")},virtual_reality:{id:"tech-virtual_reality",title:z("tech_virtual_reality"),desc:z("tech_virtual_reality"),category:"progress",era:"interstellar",reqs:{high_tech:11,alpha:2,infernite:1,stanene:1},grant:["high_tech",12],cost:{Knowledge:()=>6e5,Stanene:()=>1250,Soul_Gem:()=>1},effect:z("tech_virtual_reality_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_virtual_reality_flair")},plasma:{id:"tech-plasma",title:z("tech_plasma"),desc:z("tech_plasma"),category:"progress",era:"interstellar",path:["standard","truepath"],reqs:{high_tech:12},grant:["high_tech",13],cost:{Knowledge:()=>755e3,Infernite:()=>t.race.truepath?0:1e3,Stanene:()=>t.race.truepath?1e6:25e4},effect:z("tech_plasma_effect"),action(){return!!ri($(this)[0])}},shields:{id:"tech-shields",title:z("tech_shields"),desc:z("tech_shields"),category:"stellar_engine",era:"interstellar",reqs:{high_tech:13},grant:["high_tech",14],cost:{Knowledge:()=>85e4},effect:z("tech_shields_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.neutron=!0,t.settings.space.blackhole=!0,!0)}},ai_core:{id:"tech-ai_core",title:z("tech_ai_core"),desc:z("tech_ai_core"),category:"ai_core",era:"interstellar",reqs:{high_tech:14,science:15,blackhole:3},grant:["high_tech",15],cost:{Knowledge:()=>15e5},effect:z("tech_ai_core_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.citadel={count:0,on:0},!0)}},metaphysics:{id:"tech-metaphysics",title:z("tech_metaphysics"),desc:z("tech_metaphysics"),category:"progress",era:"intergalactic",reqs:{high_tech:15,xeno:5},grant:["high_tech",16],cost:{Knowledge:()=>5e6,Vitreloy:()=>1e4,Soul_Gem:()=>10},effect:()=>z("tech_metaphysics_effect"),action(){return!!ri($(this)[0])}},orichalcum_analysis:{id:"tech-orichalcum_analysis",title:z("tech_orichalcum_analysis"),desc:z("tech_orichalcum_analysis"),category:"progress",era:"intergalactic",reqs:{high_tech:16,chthonian:3},grant:["high_tech",17],cost:{Knowledge:()=>122e5,Orichalcum:()=>1e5},effect:()=>z("tech_orichalcum_analysis_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_orichalcum_analysis_result"),"info",!1,["progress"]),!0)}},cybernetics:{id:"tech-cybernetics",title:z("tech_cybernetics"),desc:z("tech_cybernetics"),category:"progress",era:"dimensional",reqs:{high_tech:17,hell_ruins:4},grant:["high_tech",18],cost:{Knowledge:()=>25e6,Adamantite:()=>125e5,Stanene:()=>5e7,Vitreloy:()=>1e7},effect:()=>z("tech_cybernetics_effect"),action(){return!!ri($(this)[0])}},blood_pact:{id:"tech-blood_pact",title:z("tech_blood_pact"),desc:z("tech_blood_pact"),category:"hell_dimension",era:"dimensional",reqs:{high_tech:18,b_stone:1},grant:["b_stone",2],cost:{Knowledge:()=>52e6,Blood_Stone:()=>1},effect:()=>z("tech_blood_pact_effect"),action(){return!!ri($(this)[0])&&(t.settings.arpa.blood=!0,xe("Crispr"),!0)},post(){xe("Blood")}},purify:{id:"tech-purify",title:z("tech_purify"),desc:z("tech_purify"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:3,b_stone:2},grant:["b_stone",3],cost:{Knowledge:()=>525e5,Blood_Stone:()=>1},effect:()=>z("tech_purify_effect"),action(){return!!ri($(this)[0])}},waygate:{id:"tech-waygate",title:z("tech_waygate"),desc:z("tech_waygate"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:10,b_stone:2},grant:["waygate",1],cost:{Knowledge:()=>55e6},effect:()=>z("tech_waygate_effect"),action(){return!!ri($(this)[0])&&(t.portal.waygate={count:0,progress:0,on:0},!0)}},demonic_infusion:{id:"tech-demonic_infusion",title:z("tech_demonic_infusion"),desc:z("tech_demonic_infusion"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:10,b_stone:2,waygate:3},grant:["waygate",4],not_trait:["witch_hunter"],cost:{Species:()=>Rs(1e3),Knowledge:()=>55e6,Demonic_Essence:()=>1},effect:()=>`
                            ${z("tech_demonic_infusion_effect")}
                            ${z("tech_demonic_infusion_effect2",[Gs("descend").artifact])}
                            `,action(){return t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),ri($(this)[0])&&R(),!1}},gate_key:{id:"tech-gate_key",title:z("tech_gate_key"),desc:z("tech_gate_key"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:1},grant:["hell_gate",2],cost:{Knowledge:()=>3e7},effect:()=>z("tech_gate_key_effect"),action(){return!!ri($(this)[0])&&(t.portal.west_tower={count:0,on:0},t.portal.east_tower={count:0,on:0},!0)}},gate_turret:{id:"tech-gate_turret",title:z("tech_gate_turret"),desc:z("tech_gate_turret"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:2},grant:["hell_gate",3],cost:{Knowledge:()=>32e6},effect:()=>z("tech_gate_turret_effect"),action(){return!!ri($(this)[0])&&(t.portal.gate_turret={count:0,on:0},!0)}},infernite_mine:{id:"tech-infernite_mine",title:z("tech_infernite_mine"),desc:z("tech_infernite_mine"),category:"hell_dimension",era:"dimensional",reqs:{hell_gate:3},grant:["hell_gate",4],cost:{Knowledge:()=>325e5},effect:()=>z("tech_infernite_mine_effect"),action(){return!!ri($(this)[0])&&(t.portal.infernite_mine={count:0,on:0},!0)}},study_corrupt_gem:{id:"tech-study_corrupt_gem",title:z("tech_study_corrupt_gem"),desc:z("tech_study_corrupt_gem"),category:"hell_dimension",era:"intergalactic",reqs:{high_tech:16,corrupt:1},grant:["corrupt",2],trait:["witch_hunter"],cost:{Mana:()=>t.race.no_plasmid?1e4:5e4,Knowledge:()=>185e5,Corrupt_Gem:()=>1},effect:()=>z("tech_study_corrupt_gem_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_study_corrupt_gem_result"),"info",!1,["progress","hell"]),t.resource.Corrupt_Gem.display=!1,!0)}},soul_binding:{id:"tech-soul_binding",title:z("tech_soul_binding"),desc:z("tech_soul_binding"),category:"hell_dimension",era:"intergalactic",reqs:{corrupt:2,science:19},grant:["forbidden",1],trait:["witch_hunter"],cost:{Knowledge:()=>19e6},effect:()=>z("tech_soul_binding_effect"),action(){return!!ri($(this)[0])}},soul_capacitor:{id:"tech-soul_capacitor",title:z("tech_soul_capacitor"),desc:z("tech_soul_capacitor"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:1},grant:["forbidden",2],trait:["witch_hunter"],cost:{Knowledge:()=>195e5},effect:()=>z("tech_soul_capacitor_effect"),action(){return!!ri($(this)[0])&&(t.portal.soul_capacitor={count:0,on:0,energy:0,ecap:0},!0)}},soul_capacitor:{id:"tech-soul_capacitor",title:z("tech_soul_capacitor"),desc:z("tech_soul_capacitor"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:1},grant:["forbidden",2],trait:["witch_hunter"],cost:{Knowledge:()=>195e5},effect:()=>z("tech_soul_capacitor_effect"),action(){return!!ri($(this)[0])&&(t.portal.soul_capacitor={count:0,on:0,energy:0,ecap:0},!0)}},absorption_chamber:{id:"tech-absorption_chamber",title:z("tech_absorption_chamber"),desc:z("tech_absorption_chamber"),category:"hell_dimension",era:"intergalactic",reqs:{forbidden:2},grant:["forbidden",3],trait:["witch_hunter"],cost:{Knowledge:()=>2e7},effect:()=>z("tech_absorption_chamber_effect"),action(){return!!ri($(this)[0])&&(t.portal.absorption_chamber={count:0},!0)}},corrupt_gem_analysis:{id:"tech-corrupt_gem_analysis",title:z("tech_corrupt_gem_analysis"),desc:z("tech_corrupt_gem_analysis"),category:"hell_dimension",era:"dimensional",reqs:{high_tech:16,corrupt:1},grant:["corrupt",2],not_trait:["witch_hunter"],cost:{Species:()=>1,Knowledge:()=>22e6,Corrupt_Gem:()=>1},effect:()=>z("tech_corrupt_gem_analysis_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_corrupt_gem_analysis_result"),"info",!1,["progress","hell"]),t.resource.Corrupt_Gem.display=!1,!0)}},hell_search:{id:"tech-hell_search",title:z("tech_hell_search"),desc:z("tech_hell_search"),category:"hell_dimension",era:"dimensional",reqs:{corrupt:2},grant:["hell_ruins",1],cost:{Knowledge:()=>221e5,Structs:()=>({portal:{sensor_drone:{s:"prtl_badlands",count:25,on:25}}})},effect:()=>z("tech_hell_search_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_hell_search_result"),"info",!1,["progress","hell"]),t.settings.portal.ruins=!0,t.settings.portal.gate=!0,t.portal.guard_post={count:0,on:0,support:0,s_max:0},!0)}},codex_infernium:{id:"tech-codex_infernium",title:z("tech_codex_infernium"),desc:z("tech_codex_infernium"),category:"progress",era:"dimensional",reqs:{hell_ruins:3},grant:["hell_ruins",4],cost:{Knowledge:()=>235e5,Codex:()=>1},effect:()=>z("tech_codex_infernium_effect"),action(){return!!ri($(this)[0])&&(t.resource.Codex.display=!1,!0)}},lake_analysis:{id:"tech-lake_analysis",title:z("tech_lake_analysis"),desc:z("tech_lake_analysis"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:2},grant:["hell_lake",3],cost:{Knowledge:()=>34e6},effect:()=>z("tech_lake_analysis_effect"),action(){return!!ri($(this)[0])}},lake_threat:{id:"tech-lake_threat",title:z("tech_lake_threat"),desc:z("tech_lake_threat"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:3},grant:["hell_lake",4],cost:{Knowledge:()=>345e5},effect:()=>z("tech_lake_threat_effect"),action(){return!!ri($(this)[0])&&(t.portal.bireme={count:0,on:0,crew:0,mil:0},hs(z("tech_lake_threat_result"),"info",!1,["progress","hell"]),!0)}},lake_transport:{id:"tech-lake_transport",title:z("tech_lake_transport"),desc:z("tech_lake_transport"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:4},grant:["hell_lake",5],cost:{Knowledge:()=>35e6},effect:()=>z("tech_lake_transport_effect"),action(){return!!ri($(this)[0])&&(t.portal.transport={count:0,on:0,crew:0,mil:0,cargo:{used:0,max:0,Crystal:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0}},!0)}},cooling_tower:{id:"tech-cooling_tower",title:z("tech_cooling_tower"),desc:z("tech_cooling_tower"),category:"hell_dimension",era:"dimensional",reqs:{hell_lake:5},grant:["hell_lake",6],cost:{Knowledge:()=>375e5},effect:()=>z("tech_cooling_tower_effect"),action(){return!!ri($(this)[0])&&(t.portal.cooling_tower={count:0,on:0},!0)}},miasma:{id:"tech-miasma",title:z("tech_miasma"),desc:z("tech_miasma"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:2},grant:["hell_spire",3],cost:{Knowledge:()=>3825e4},effect:()=>z("tech_miasma_effect"),action(){return!!ri($(this)[0])&&(t.portal.port={count:0},!0)}},incorporeal:{id:"tech-incorporeal",title:z("tech_incorporeal"),desc:z("tech_incorporeal"),category:"special",era:"intergalactic",reqs:{science:19},grant:["ascension",1],not_trait:["orbit_decay","witch_hunter"],cost:{Knowledge:()=>175e5,Phage:()=>25},effect:()=>z("tech_incorporeal_effect"),action(){return!!ri($(this)[0])}},tech_ascension:{id:"tech-tech_ascension",title:z("tech_ascension"),desc:z("tech_ascension"),category:"special",era:"intergalactic",reqs:{ascension:1},grant:["ascension",2],not_trait:["orbit_decay","witch_hunter"],cost:{Knowledge:()=>185e5,Plasmid:()=>100},effect:()=>z("tech_ascension_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.sirius=!0,!0)}},terraforming:{id:"tech-terraforming",title:z("tech_terraforming"),desc:z("tech_terraforming"),category:"special",era:"intergalactic",reqs:{science:19},path:["standard"],grant:["terraforming",1],trait:["orbit_decay"],cost:{Knowledge:()=>18e6},effect:()=>z("tech_terraforming_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.terraformer={count:0},!0)}},cement_processing:{id:"tech-cement_processing",title:z("tech_cement_processing"),desc:z("tech_cement_processing"),category:"ai_core",era:"interstellar",reqs:{high_tech:15},not_trait:["flier"],grant:["ai_core",1],cost:{Knowledge:()=>175e4},effect:z("tech_cement_processing_effect"),action(){return!!ri($(this)[0])}},adamantite_processing_flier:{id:"tech-adamantite_processing_flier",title:z("tech_adamantite_processing"),desc:z("tech_adamantite_processing"),category:"ai_core",era:"interstellar",reqs:{high_tech:15},trait:["flier"],grant:["ai_core",2],cost:{Knowledge:()=>2e6},effect:z("tech_adamantite_processing_effect"),action(){return!!ri($(this)[0])}},adamantite_processing:{id:"tech-adamantite_processing",title:z("tech_adamantite_processing"),desc:z("tech_adamantite_processing"),category:"ai_core",era:"interstellar",reqs:{ai_core:1},not_trait:["flier"],grant:["ai_core",2],cost:{Knowledge:()=>2e6},effect:z("tech_adamantite_processing_effect"),action(){return!!ri($(this)[0])}},graphene_processing:{id:"tech-graphene_processing",title:z("tech_graphene_processing"),desc:z("tech_graphene_processing"),category:"ai_core",era:"intergalactic",reqs:{ai_core:2},grant:["ai_core",3],cost:{Knowledge:()=>25e5},effect:z("tech_graphene_processing_effect"),action(){return!!ri($(this)[0])}},fusion_power:{id:"tech-fusion_power",title:z("tech_fusion_power"),desc:z("tech_fusion_power"),category:"power_generation",era:"interstellar",reqs:{ram_scoop:1},grant:["fusion",1],cost:{Knowledge:()=>64e4},effect:z("tech_fusion_power_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.fusion={count:0,on:0},!0)}},infernium_power:{id:"tech-infernium_power",title:z("tech_infernium_power"),desc:z("tech_infernium_power"),category:"power_generation",era:"dimensional",reqs:{smelting:8,hell_ruins:4},grant:["inferno_power",1],cost:{Knowledge:()=>3e7},effect:z("tech_infernium_power_effect"),action(){return!!ri($(this)[0])&&(t.portal.inferno_power={count:0,on:0},!0)}},thermomechanics:{id:"tech-thermomechanics",title:z("tech_thermomechanics"),desc:z("tech_thermomechanics_desc"),category:"crafting",era:"industrialized",reqs:{high_tech:4},grant:["alloy",1],cost:{Knowledge:()=>6e4},effect:()=>z("tech_thermomechanics_effect"),action(){return!!ri($(this)[0])}},quantum_manufacturing:{id:"tech-quantum_manufacturing",title:z("tech_quantum_manufacturing"),desc:z("tech_quantum_manufacturing"),category:"crafting",era:"deep_space",reqs:{high_tech:11},grant:["q_factory",1],cost:{Knowledge:()=>465e3},effect:z("tech_quantum_manufacturing_effect"),action(){return!!ri($(this)[0])}},worker_drone:{id:"tech-worker_drone",title:z("tech_worker_drone"),desc:z("tech_worker_drone"),category:"mining",era:"deep_space",reqs:{nano:1},grant:["drone",1],cost:{Knowledge:()=>4e5},effect:()=>z("tech_worker_drone_effect",[Ut().gas_moon]),action(){return!!ri($(this)[0])&&(t.space.drone={count:0},!0)}},uranium:{id:"tech-uranium",title:z("tech_uranium"),desc:z("tech_uranium"),category:"power_generation",era:"globalized",reqs:{high_tech:4},grant:["uranium",1],cost:{Knowledge:()=>72e3},effect:z("tech_uranium_effect"),action(){return!!ri($(this)[0])&&(t.resource.Uranium.display=!0,!0)},post(){cs()}},uranium_storage:{id:"tech-uranium_storage",title:z("tech_uranium_storage"),desc:z("tech_uranium_storage"),category:"storage",era:"globalized",reqs:{uranium:1},grant:["uranium",2],cost:{Knowledge:()=>75600,Alloy:()=>2500},effect:z("tech_uranium_storage_effect"),action(){return!!ri($(this)[0])}},uranium_ash:{id:"tech-uranium_ash",title:z("tech_uranium_ash"),desc:z("tech_uranium_ash"),category:"power_generation",era:"globalized",reqs:{uranium:2},grant:["uranium",3],cost:{Knowledge:()=>122e3},effect:z("tech_uranium_ash_effect"),action(){return!!ri($(this)[0])}},breeder_reactor:{id:"tech-breeder_reactor",title:z("tech_breeder_reactor"),desc:z("tech_breeder_reactor"),category:"power_generation",era:"early_space",reqs:{high_tech:5,uranium:3,space:3},grant:["uranium",4],cost:{Knowledge:()=>16e4,Uranium:()=>250,Iridium:()=>1e3},effect:z("tech_breeder_reactor_effect"),action(){return!!ri($(this)[0])}},mine_conveyor:{id:"tech-mine_conveyor",title:z("tech_mine_conveyor"),desc:z("tech_mine_conveyor"),category:"mining",era:"discovery",reqs:{high_tech:2},grant:["mine_conveyor",1],cost:{Knowledge:()=>16200,Copper:()=>2250,Steel:()=>1750},effect:z("tech_mine_conveyor_effect"),action(){return!!ri($(this)[0])}},oil_well:{id:"tech-oil_well",title:z("tech_oil_well"),desc:z("tech_oil_well"),category:"power_generation",era:"industrialized",reqs:{high_tech:3},grant:["oil",1],cost:{Knowledge:()=>27e3},effect:z("tech_oil_well_effect"),action(){return!!ri($(this)[0])&&(t.city.oil_well={count:0},!0)}},oil_depot:{id:"tech-oil_depot",title:z("tech_oil_depot"),desc:z("tech_oil_depot"),category:"storage",era:"industrialized",reqs:{oil:1},grant:["oil",2],cost:{Knowledge:()=>32e3},effect:z("tech_oil_depot_effect"),action(){return!!ri($(this)[0])&&(t.city.oil_depot={count:0},!0)}},oil_power:{id:"tech-oil_power",title:()=>t.race.environmentalist?z("city_wind_power"):z("tech_oil_power"),desc:()=>t.race.environmentalist?z("city_wind_power"):z("tech_oil_power"),category:"power_generation",era:"industrialized",reqs:{oil:2},grant:["oil",3],cost:{Knowledge:()=>44e3},effect:()=>t.race.environmentalist?z("tech_wind_power_effect"):z("tech_oil_power_effect"),action(){return!!ri($(this)[0])&&(t.city.oil_power={count:0,on:0},!0)}},titanium_drills:{id:"tech-titanium_drills",title:z("tech_titanium_drills"),desc:z("tech_titanium_drills"),category:"power_generation",era:"industrialized",reqs:{oil:3},grant:["oil",4],cost:{Knowledge:()=>54e3,Titanium:()=>3500},effect:z("tech_titanium_drills_effect"),action(){return!!ri($(this)[0])}},alloy_drills:{id:"tech-alloy_drills",title:z("tech_alloy_drills"),desc:z("tech_alloy_drills"),category:"power_generation",era:"globalized",reqs:{oil:4},grant:["oil",5],cost:{Knowledge:()=>77e3,Alloy:()=>1e3},effect:z("tech_alloy_drills_effect"),action(){return!!ri($(this)[0])}},fracking:{id:"tech-fracking",title:z("tech_fracking"),desc:z("tech_fracking"),category:"power_generation",era:"globalized",reqs:{oil:5,high_tech:6},grant:["oil",6],cost:{Knowledge:()=>132e3},effect:z("tech_fracking_effect"),action(){return!!ri($(this)[0])}},mythril_drills:{id:"tech-mythril_drills",title:z("tech_mythril_drills"),desc:z("tech_mythril_drills"),category:"power_generation",era:"early_space",reqs:{oil:6,space:3},grant:["oil",7],cost:{Knowledge:()=>165e3,Mythril:()=>100},effect:z("tech_mythril_drills_effect"),action(){return!!ri($(this)[0])}},mass_driver:{id:"tech-mass_driver",title:z("tech_mass_driver"),desc:z("tech_mass_driver"),category:"power_generation",era:"early_space",reqs:{oil:6,space:3},grant:["mass",1],cost:{Knowledge:()=>16e4},effect:z("tech_mass_driver_effect"),action(){return!!ri($(this)[0])&&(t.city.mass_driver={count:0,on:0},!0)}},orichalcum_driver:{id:"tech-orichalcum_driver",title:z("tech_orichalcum_driver"),desc:z("tech_orichalcum_driver"),category:"science",era:"intergalactic",reqs:{mass:1,science:19},grant:["mass",2],not_trait:["orbit_decayed"],cost:{Knowledge:()=>14e6,Orichalcum:()=>4e5},effect:()=>z("tech_orichalcum_driver_effect"),action(){return!!ri($(this)[0])&&(t.space.terraformer={count:0},!0)}},polymer:{id:"tech-polymer",title:z("tech_polymer"),desc:z("tech_polymer"),category:"crafting",era:"globalized",reqs:{genetics:1},grant:["polymer",1],cost:{Knowledge:()=>8e4,Oil:()=>5e3,Alloy:()=>450},effect:z("tech_polymer_effect"),action(){return!!ri($(this)[0])&&(t.resource.Polymer.display=!0,hs(z("tech_polymer_avail"),"info",!1,["progress"]),!0)},post(){ki(),cs()}},fluidized_bed_reactor:{id:"tech-fluidized_bed_reactor",title:z("tech_fluidized_bed_reactor"),desc:z("tech_fluidized_bed_reactor"),category:"crafting",era:"globalized",reqs:{polymer:1,high_tech:6},grant:["polymer",2],cost:{Knowledge:()=>99e3},effect:z("tech_fluidized_bed_reactor_effect"),action(){return!!ri($(this)[0])}},synthetic_fur:{id:"tech-synthetic_fur",title:()=>t.race.evil?z("tech_faux_leather"):z("tech_synthetic_fur"),desc:()=>t.race.evil?z("tech_faux_leather"):z("tech_synthetic_fur"),category:"crafting",era:"globalized",reqs:{polymer:1},grant:["synthetic_fur",1],cost:{Knowledge:()=>1e5,Polymer:()=>2500},effect:()=>t.race.evil?z("tech_faux_leather_effect"):z("tech_synthetic_fur_effect"),action(){return!!ri($(this)[0])},post(){ki()}},nanoweave:{id:"tech-nanoweave",title:z("tech_nanoweave"),desc:z("tech_nanoweave"),category:"crafting",era:"intergalactic",reqs:{science:18},grant:["nanoweave",1],cost:{Knowledge:()=>85e5,Nano_Tube:()=>5e6,Vitreloy:()=>25e4},effect:z("tech_nanoweave_effect"),action(){return!!ri($(this)[0])&&(t.resource.Nanoweave.display=!0,hs(z("tech_nanoweave_avail"),"info",!1,["progress"]),sa(),!0)},post(){cs()}},stanene:{id:"tech-stanene",title:z("tech_stanene"),desc:z("tech_stanene"),category:"crafting",era:"interstellar",reqs:{infernite:1},grant:["stanene",1],cost:{Knowledge:()=>59e4,Aluminium:()=>5e5,Infernite:()=>1e3},effect:z("tech_stanene_effect"),action(){return!!ri($(this)[0])&&(t.resource.Stanene.display=!0,hs(z("tech_stanene_avail"),"info",!1,["progress"]),!0)},post(){ki(),cs()}},nano_tubes:{id:"tech-nano_tubes",title:z("tech_nano_tubes"),desc:z("tech_nano_tubes"),category:"crafting",era:"deep_space",reqs:{high_tech:10},grant:["nano",1],cost:{Knowledge:()=>375e3,Coal:()=>1e5,Neutronium:()=>1e3},effect:z("tech_nano_tubes_effect"),action(){return!!ri($(this)[0])&&(t.resource.Nano_Tube.display=!0,hs(z("tech_nano_tubes_msg"),"info",!1,["progress"]),!0)},post(){ki(),cs()}},scarletite:{id:"tech-scarletite",title:z("tech_scarletite"),desc:z("tech_scarletite"),category:"crafting",era:"dimensional",reqs:{hell_ruins:4},grant:["scarletite",1],cost:{Knowledge:()=>2675e4,Iron:()=>1e8,Adamantite:()=>15e6,Orichalcum:()=>8e6},effect:z("tech_scarletite_effect"),action(){if(ri($(this)[0])){if(t.resource.Scarletite.display=!0,t.portal.hell_forge={count:0,on:0},hs(z("tech_scarletite_avail"),"info",!1,["progress"]),sa(),"micro"===t.race.universe||t.pillars[t.race.species]){let e=Mn();e>t.pillars[t.race.species]&&(t.pillars[t.race.species]=e),t.tech.pillars=2}else t.tech.fusable=1;return!0}return!1},post(){cs()}},pillars:{id:"tech-pillars",title:z("tech_pillars"),desc:z("tech_pillars"),category:"hell_dimension",era:"dimensional",reqs:{scarletite:1,fusable:1},grant:["pillars",1],cost:{Knowledge:()=>3e7},effect:z("tech_pillars_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_pillars_msg",[Ki[t.race.species].entity]),"info",!1,["progress","hell"]),!0)}},reclaimer:{id:"tech-reclaimer",title:z("tech_reclaimer"),desc:z("tech_reclaimer_desc"),category:"reclaimer",era:"civilized",reqs:{primitive:3},grant:["reclaimer",1],trait:["evil"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>45,Lumber:()=>20,Stone:()=>20},effect:z("tech_reclaimer_effect"),action(){return!!ri($(this)[0])&&(t.civic.lumberjack.name=z("job_reclaimer"),t.civic.lumberjack.display=!0,t.city.graveyard={count:0},!0)}},shovel:{id:"tech-shovel",title:z("tech_shovel"),desc:z("tech_shovel"),category:"reclaimer",era:"civilized",reqs:{reclaimer:1,mining:2},grant:["reclaimer",2],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>540,Copper:()=>25},effect:z("tech_shovel_effect"),action(){return!!ri($(this)[0])}},iron_shovel:{id:"tech-iron_shovel",title:z("tech_iron_shovel"),desc:z("tech_iron_shovel"),category:"reclaimer",era:"civilized",reqs:{reclaimer:2,mining:3},grant:["reclaimer",3],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>2700,Iron:()=>250},effect:z("tech_iron_shovel_effect"),action(){return!!ri($(this)[0])}},steel_shovel:{id:"tech-steel_shovel",title:z("tech_steel_shovel"),desc:z("tech_steel_shovel"),category:"reclaimer",era:"discovery",reqs:{reclaimer:3,smelting:2},grant:["reclaimer",4],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>9e3,Steel:()=>250},effect:z("tech_steel_shovel_effect"),action(){return!!ri($(this)[0])}},titanium_shovel:{id:"tech-titanium_shovel",title:z("tech_titanium_shovel"),desc:z("tech_titanium_shovel"),category:"reclaimer",era:"industrialized",reqs:{reclaimer:4,high_tech:3},grant:["reclaimer",5],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>38e3,Titanium:()=>350},effect:z("tech_titanium_shovel_effect"),action(){return!!ri($(this)[0])}},alloy_shovel:{id:"tech-alloy_shovel",title:z("tech_alloy_shovel"),desc:z("tech_alloy_shovel"),category:"reclaimer",era:"globalized",reqs:{reclaimer:5,high_tech:4},grant:["reclaimer",6],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>67500,Alloy:()=>750},effect:z("tech_alloy_shovel_effect"),action(){return!!ri($(this)[0])}},mythril_shovel:{id:"tech-mythril_shovel",title:z("tech_mythril_shovel"),desc:z("tech_mythril_shovel"),category:"reclaimer",era:"early_space",reqs:{reclaimer:6,space:3},grant:["reclaimer",7],trait:["evil"],not_trait:["living_tool"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>16e4,Mythril:()=>880},effect:z("tech_mythril_shovel_effect"),action(){return!!ri($(this)[0])}},adamantite_shovel:{id:"tech-adamantite_shovel",title:z("tech_adamantite_shovel"),desc:z("tech_adamantite_shovel"),category:"reclaimer",era:"interstellar",reqs:{reclaimer:7,alpha:2},grant:["reclaimer",8],trait:["evil"],condition:()=>!(t.race.kindling_kindred||t.race.smoldering||"wendigo"!==t.race.species&&t.race.soul_eater),cost:{Knowledge:()=>525e3,Adamantite:()=>1e4},effect:z("tech_adamantite_shovel_effect"),action(){return!!ri($(this)[0])}},stone_axe:{id:"tech-stone_axe",title:()=>z("tech_stone_axe"),desc:()=>z("tech_stone_axe_desc"),category:"lumber_gathering",reqs:{primitive:3},era:"civilized",grant:["axe",1],not_trait:["kindling_kindred","smoldering","evil","cataclysm"],cost:{Knowledge:()=>45,Lumber:()=>20,Stone:()=>20},effect:()=>t.race.living_tool?z("tech_basic_livingtools"):t.race.sappy?z("tech_amber_axe_effect"):z("tech_stone_axe_effect"),action(){return!!ri($(this)[0])&&(t.civic.lumberjack.display=!0,t.city.lumber_yard={count:0},!0)}},copper_axes:{id:"tech-copper_axes",title:z("tech_copper_axes"),desc:z("tech_copper_axes_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:1,mining:2},not_trait:["living_tool"],grant:["axe",2],cost:{Knowledge:()=>540,Copper:()=>25},effect:z("tech_copper_axes_effect"),action(){return!!ri($(this)[0])}},iron_saw:{id:"tech-iron_saw",title:z("tech_iron_saw"),desc:z("tech_iron_saw_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:1,mining:3},grant:["saw",1],not_trait:["lone_survivor"],cost:{Knowledge:()=>3375,Iron:()=>400},effect:z("tech_iron_saw_effect"),action(){return!!ri($(this)[0])&&(t.city.sawmill={count:0,on:0},!0)}},steel_saw:{id:"tech-steel_saw",title:z("tech_steel_saw"),desc:z("tech_steel_saw_desc"),category:"lumber_gathering",era:"discovery",reqs:{smelting:2,saw:1},grant:["saw",2],cost:{Knowledge:()=>10800,Steel:()=>400},effect:z("tech_steel_saw_effect"),action(){return!!ri($(this)[0])}},iron_axes:{id:"tech-iron_axes",title:z("tech_iron_axes"),desc:z("tech_iron_axes_desc"),category:"lumber_gathering",era:"civilized",reqs:{axe:2,mining:3},not_trait:["living_tool"],grant:["axe",3],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1350:2700,Iron:()=>250},effect:z("tech_iron_axes_effect"),action(){return!!ri($(this)[0])}},steel_axes:{id:"tech-steel_axes",title:z("tech_steel_axes"),desc:z("tech_steel_axes_desc"),category:"lumber_gathering",era:"discovery",reqs:{axe:3,smelting:2},not_trait:["living_tool"],grant:["axe",4],cost:{Knowledge:()=>9e3,Steel:()=>250},effect:z("tech_steel_axes_effect"),action(){return!!ri($(this)[0])}},titanium_axes:{id:"tech-titanium_axes",title:z("tech_titanium_axes"),desc:z("tech_titanium_axes_desc"),category:"lumber_gathering",era:"industrialized",reqs:{axe:4,high_tech:3},not_trait:["living_tool"],grant:["axe",5],cost:{Knowledge:()=>38e3,Titanium:()=>350},effect:z("tech_titanium_axes_effect"),action(){return!!ri($(this)[0])}},chainsaws:{id:"tech-chainsaws",title:z("tech_chainsaws"),desc:z("tech_chainsaws_desc"),category:"lumber_gathering",era:"interstellar",reqs:{axe:5,alpha:2},not_trait:["living_tool"],grant:["axe",6],cost:{Knowledge:()=>56e4,Oil:()=>1e4,Adamantite:()=>2e3},effect:z("tech_chainsaws_effect"),action(){return!!ri($(this)[0])},flair:()=>`
                            ${z("tech_chainsaws_flair1")}
                            ${z("tech_chainsaws_flair2")}
                            `},copper_sledgehammer:{id:"tech-copper_sledgehammer",title:z("tech_copper_sledgehammer"),desc:z("tech_copper_sledgehammer_desc"),category:"stone_gathering",era:"civilized",reqs:{mining:2},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",1],cost:{Knowledge:()=>540,Copper:()=>25},effect:z("tech_copper_sledgehammer_effect"),action(){return!!ri($(this)[0])}},iron_sledgehammer:{id:"tech-iron_sledgehammer",title:z("tech_iron_sledgehammer"),desc:z("tech_iron_sledgehammer_desc"),category:"stone_gathering",era:"civilized",reqs:{hammer:1,mining:3},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1350:2700,Iron:()=>250},effect:z("tech_iron_sledgehammer_effect"),action(){return!!ri($(this)[0])}},steel_sledgehammer:{id:"tech-steel_sledgehammer",title:z("tech_steel_sledgehammer"),desc:z("tech_steel_sledgehammer_desc"),category:"stone_gathering",era:"discovery",reqs:{hammer:2,smelting:2},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",3],cost:{Knowledge:()=>7200,Steel:()=>250},effect:z("tech_steel_sledgehammer_effect"),action(){return!!ri($(this)[0])}},titanium_sledgehammer:{id:"tech-titanium_sledgehammer",title:z("tech_titanium_sledgehammer"),desc:z("tech_titanium_sledgehammer_desc"),category:"stone_gathering",era:"industrialized",reqs:{hammer:3,high_tech:3},not_trait:["cataclysm","sappy","living_tool"],grant:["hammer",4],cost:{Knowledge:()=>4e4,Titanium:()=>400},effect:z("tech_titanium_sledgehammer_effect"),action(){return!!ri($(this)[0])}},copper_pickaxe:{id:"tech-copper_pickaxe",title:z("tech_copper_pickaxe"),desc:z("tech_copper_pickaxe_desc"),category:"mining",era:"civilized",reqs:{mining:2},not_trait:["cataclysm","living_tool"],grant:["pickaxe",1],cost:{Knowledge:()=>675,Copper:()=>25},effect:z("tech_copper_pickaxe_effect"),action(){return!!ri($(this)[0])}},iron_pickaxe:{id:"tech-iron_pickaxe",title:z("tech_iron_pickaxe"),desc:z("tech_iron_pickaxe_desc"),category:"mining",era:"civilized",reqs:{pickaxe:1,mining:3},not_trait:["cataclysm","living_tool"],grant:["pickaxe",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1600:3200,Iron:()=>250},effect:z("tech_iron_pickaxe_effect"),action(){return!!ri($(this)[0])}},steel_pickaxe:{id:"tech-steel_pickaxe",title:z("tech_steel_pickaxe"),desc:z("tech_steel_pickaxe_desc"),category:"mining",era:"discovery",reqs:{pickaxe:2,smelting:2},not_trait:["living_tool"],grant:["pickaxe",3],cost:{Knowledge:()=>9e3,Steel:()=>250},effect:z("tech_steel_pickaxe_effect"),action(){return!!ri($(this)[0])}},jackhammer:{id:"tech-jackhammer",title:z("tech_jackhammer"),desc:z("tech_jackhammer_desc"),category:"mining",era:"discovery",reqs:{pickaxe:3,high_tech:2},not_trait:["living_tool"],grant:["pickaxe",4],cost:{Knowledge:()=>22500,Copper:()=>5e3},effect:z("tech_jackhammer_effect"),action(){return!!ri($(this)[0])}},jackhammer_mk2:{id:"tech-jackhammer_mk2",title:z("tech_jackhammer_mk2"),desc:z("tech_jackhammer_mk2"),category:"mining",era:"globalized",reqs:{pickaxe:4,high_tech:4},not_trait:["living_tool"],grant:["pickaxe",5],cost:{Knowledge:()=>67500,Titanium:()=>2e3,Alloy:()=>500},effect:z("tech_jackhammer_mk2_effect"),action(){return!!ri($(this)[0])}},adamantite_hammer:{id:"tech-adamantite_hammer",title:z("tech_adamantite_hammer"),desc:z("tech_adamantite_hammer"),category:"mining",era:"interstellar",reqs:{pickaxe:5,alpha:2},not_trait:["living_tool"],grant:["pickaxe",6],cost:{Knowledge:()=>535e3,Adamantite:()=>12500},effect:z("tech_adamantite_hammer_effect"),action(){return!!ri($(this)[0])}},copper_hoe:{id:"tech-copper_hoe",title:z("tech_copper_hoe"),desc:z("tech_copper_hoe_desc"),category:"agriculture",era:"civilized",reqs:{mining:2,agriculture:1},not_trait:["cataclysm","living_tool"],grant:["hoe",1],cost:{Knowledge:()=>720,Copper:()=>50},effect:z("tech_copper_hoe_effect"),action(){return!!ri($(this)[0])}},iron_hoe:{id:"tech-iron_hoe",title:z("tech_iron_hoe"),desc:z("tech_iron_hoe_desc"),category:"agriculture",era:"civilized",reqs:{hoe:1,mining:3,agriculture:1},not_trait:["living_tool"],grant:["hoe",2],cost:{Knowledge:()=>t.city.ptrait.includes("unstable")?1800:3600,Iron:()=>500},effect:z("tech_iron_hoe_effect"),action(){return!!ri($(this)[0])}},steel_hoe:{id:"tech-steel_hoe",title:z("tech_steel_hoe"),desc:z("tech_steel_hoe_desc"),category:"agriculture",era:"discovery",reqs:{hoe:2,smelting:2,agriculture:1},not_trait:["living_tool"],grant:["hoe",3],cost:{Knowledge:()=>12600,Steel:()=>500},effect:z("tech_steel_hoe_effect"),action(){return!!ri($(this)[0])}},titanium_hoe:{id:"tech-titanium_hoe",title:z("tech_titanium_hoe"),desc:z("tech_titanium_hoe_desc"),category:"agriculture",era:"industrialized",reqs:{hoe:3,high_tech:3,agriculture:1},not_trait:["living_tool"],grant:["hoe",4],cost:{Knowledge:()=>44e3,Titanium:()=>500},effect:z("tech_titanium_hoe_effect"),action(){return!!ri($(this)[0])}},adamantite_hoe:{id:"tech-adamantite_hoe",title:z("tech_adamantite_hoe"),desc:z("tech_adamantite_hoe_desc"),category:"agriculture",era:"interstellar",reqs:{hoe:4,alpha:2},not_trait:["living_tool"],grant:["hoe",5],cost:{Knowledge:()=>53e4,Adamantite:()=>1e3},effect:z("tech_adamantite_hoe_effect"),action(){return!!ri($(this)[0])}},cyber_limbs:{id:"tech-cyber_limbs",title:z("tech_cyber_limbs"),desc:z("tech_cyber_limbs"),category:"mining",era:"dimensional",reqs:{high_tech:18},grant:["cyber_worker",1],cost:{Knowledge:()=>27e6},effect:z("tech_cyber_limbs_effect"),action(){return!!ri($(this)[0])}},slave_pens:{id:"tech-slave_pens",title:z("tech_slave_pens"),desc:z("tech_slave_pens"),category:"slaves",era:"civilized",reqs:{military:1,mining:1},not_trait:["cataclysm","lone_survivor"],grant:["slaves",1],trait:["slaver"],cost:{Knowledge:()=>150},effect:z("tech_slave_pens_effect"),action(){return!!ri($(this)[0])&&(t.city.slave_pen={count:0,slaves:0},!0)}},slave_market:{id:"tech-slave_market",title:z("tech_slave_market"),desc:z("tech_slave_market"),category:"slaves",era:"discovery",reqs:{slaves:1,high_tech:1},grant:["slaves",2],trait:["slaver"],cost:{Knowledge:()=>8e3},effect:z("tech_slave_market_effect"),action(){return!!ri($(this)[0])}},ceremonial_dagger:{id:"tech-ceremonial_dagger",title:z("tech_ceremonial_dagger"),desc:z("tech_ceremonial_dagger"),category:"sacrifice",era:"civilized",reqs:{mining:1},grant:["sacrifice",1],trait:["cannibalize"],not_trait:["cataclysm","lone_survivor"],cost:{Knowledge:()=>60},effect:z("tech_ceremonial_dagger_effect"),action(){return!!ri($(this)[0])}},last_rites:{id:"tech-last_rites",title:z("tech_last_rites"),desc:z("tech_last_rites"),category:"sacrifice",era:"civilized",reqs:{sacrifice:1,theology:2},grant:["sacrifice",2],trait:["cannibalize"],cost:{Knowledge:()=>1e3},effect:z("tech_last_rites_effect"),action(){return!!ri($(this)[0])}},ancient_infusion:{id:"tech-ancient_infusion",title:z("tech_ancient_infusion"),desc:z("tech_ancient_infusion"),category:"sacrifice",era:"early_space",reqs:{sacrifice:2,theology:4},grant:["sacrifice",3],trait:["cannibalize"],cost:{Knowledge:()=>182e3},effect:z("tech_ancient_infusion_effect"),action(){return!!ri($(this)[0])}},garrison:{id:"tech-garrison",title:z("tech_garrison"),desc:z("tech_garrison_desc"),category:"military",era:"civilized",reqs:{science:1,housing:1},grant:["military",1],cost:{Knowledge:()=>70},effect:z("tech_garrison_effect"),action(){return!!ri($(this)[0])&&(t.city.garrison={count:0,on:0},!0)}},mercs:{id:"tech-mercs",title:z("tech_mercs"),desc:z("tech_mercs_desc"),category:"military",era:"civilized",reqs:{military:1},grant:["mercs",1],not_trait:["lone_survivor"],cost:{Money:()=>1e4,Knowledge:()=>4500},effect:z("tech_mercs_effect"),action(){return!!ri($(this)[0])&&(t.civic.garrison.mercs=!0,!0)}},signing_bonus:{id:"tech-signing_bonus",title:z("tech_signing_bonus"),desc:z("tech_signing_bonus_desc"),category:"military",era:"industrialized",reqs:{mercs:1,high_tech:3},grant:["mercs",2],cost:{Money:()=>5e4,Knowledge:()=>32e3},effect:z("tech_signing_bonus_effect"),action(){return!!ri($(this)[0])}},hospital:{id:"tech-hospital",title:z("tech_hospital"),desc:z("tech_hospital"),category:"military",era:"civilized",reqs:{military:1,alumina:1},grant:["medic",1],not_trait:["artifical"],cost:{Knowledge:()=>5e3},effect:z("tech_hospital_effect"),action(){return!!ri($(this)[0])&&(t.city.hospital={count:0},!0)}},bac_tanks:{id:"tech-bac_tanks",title:()=>t.race.artifical?z("tech_repair_subroutines"):z("tech_bac_tanks"),desc:()=>t.race.artifical?z("tech_repair_subroutines"):z("tech_bac_tanks_desc"),category:"military",era:"interstellar",reqs:{medic:1,infernite:1},grant:["medic",2],cost:{Knowledge:()=>6e5,Infernite:()=>250},effect:()=>t.race.artifical?z("tech_repair_subroutines_effect"):z("tech_bac_tanks_effect"),action(){return!!ri($(this)[0])}},boot_camp:{id:"tech-boot_camp",title:z("tech_boot_camp"),desc:z("tech_boot_camp_desc"),category:"military",era:"discovery",reqs:{high_tech:1},grant:["boot_camp",1],cost:{Knowledge:()=>8e3},effect:z("tech_boot_camp_effect"),action(){return!!ri($(this)[0])&&(t.city.boot_camp={count:0},!0)}},vr_training:{id:"tech-vr_training",title:z("tech_vr_training"),desc:z("tech_vr_training"),category:"military",era:"interstellar",path:["standard","truepath"],reqs:{boot_camp:1,high_tech:12},not_trait:["cataclysm","lone_survivor"],grant:["boot_camp",2],cost:{Knowledge:()=>625e3},effect:()=>z("tech_vr_training_effect"),action(){return!!ri($(this)[0])}},bows:{id:"tech-bows",title:z("tech_bows"),desc:z("tech_bows_desc"),category:"military",era:"civilized",reqs:{military:1},grant:["military",2],cost:{Knowledge:()=>225,Lumber:()=>250},effect:z("tech_bows_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},flintlock_rifle:{id:"tech-flintlock_rifle",title:()=>"magic"===t.race.universe?z("tech_magic_arrow"):z("tech_flintlock_rifle"),desc:()=>"magic"===t.race.universe?z("tech_magic_arrow"):z("tech_flintlock_rifle"),category:"military",era:"civilized",reqs:{military:2,explosives:1},grant:["military",3],cost:{Knowledge:()=>5400,Coal:()=>"magic"===t.race.universe?0:750,Mana:()=>"magic"===t.race.universe?100:0},effect:()=>"magic"===t.race.universe?z("tech_magic_arrow_effect"):z("tech_flintlock_rifle_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},machine_gun:{id:"tech-machine_gun",title:()=>"magic"===t.race.universe?z("tech_fire_mage"):z("tech_machine_gun"),desc:()=>"magic"===t.race.universe?z("tech_fire_mage"):z("tech_machine_gun"),category:"military",era:"industrialized",reqs:{military:3,oil:1},grant:["military",4],cost:{Mana:()=>"magic"===t.race.universe?300:0,Knowledge:()=>33750,Oil:()=>1500},effect:z("tech_machine_gun_effect"),effect:()=>"magic"===t.race.universe?z("tech_fire_mage_effect"):z("tech_machine_gun_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},bunk_beds:{id:"tech-bunk_beds",title:z("tech_bunk_beds"),desc:z("tech_bunk_beds"),category:"military",era:"globalized",reqs:{military:4,high_tech:4},grant:["military",5],cost:{Knowledge:()=>76500,Furs:()=>25e3,Alloy:()=>3e3},effect:z("tech_bunk_beds_effect"),action(){return!!ri($(this)[0])}},rail_guns:{id:"tech-rail_guns",title:()=>"magic"===t.race.universe?z("tech_lightning_caster"):z("tech_rail_guns"),desc:()=>"magic"===t.race.universe?z("tech_lightning_caster"):z("tech_rail_guns"),category:"military",era:"early_space",reqs:{military:5,mass:1},grant:["military",6],cost:{Mana:()=>"magic"===t.race.universe?450:0,Knowledge:()=>2e5,Iridium:()=>2500},effect:()=>"magic"===t.race.universe?z("tech_lightning_caster_effect"):z("tech_rail_guns_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},laser_rifles:{id:"tech-laser_rifles",title:()=>"magic"===t.race.universe?z("tech_mana_rifles"):z("tech_laser_rifles"),desc:()=>"magic"===t.race.universe?z("tech_mana_rifles"):z("tech_laser_rifles"),category:"military",era:"deep_space",reqs:{military:6,high_tech:9,elerium:1},grant:["military",7],cost:{Knowledge:()=>325e3,Elerium:()=>250},effect:()=>"magic"===t.race.universe?z("tech_mana_rifles_effect"):z("tech_laser_rifles_effect"),action(){return!!ri($(this)[0])&&("sharkin"===t.race.species&&qn("laser_shark"),!0)},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},plasma_rifles:{id:"tech-plasma_rifles",title:()=>"magic"===t.race.universe?z("tech_focused_rifles"):z("tech_plasma_rifles"),desc:()=>"magic"===t.race.universe?z("tech_focused_rifles"):z("tech_plasma_rifles"),category:"military",era:"interstellar",reqs:{military:7,high_tech:13},grant:["military",8],path:["standard","truepath"],cost:{Knowledge:()=>78e4,Elerium:()=>t.race.truepath?1e3:500},effect:()=>"magic"===t.race.universe?z("tech_focused_rifles_effect"):z("tech_plasma_rifles_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},disruptor_rifles:{id:"tech-disruptor_rifles",title:()=>"magic"===t.race.universe?z("tech_magic_missile"):z("tech_disruptor_rifles"),desc:()=>"magic"===t.race.universe?z("tech_magic_missile"):z("tech_disruptor_rifles"),category:"military",era:"interstellar",reqs:{military:8,high_tech:14,science:15,infernite:1},grant:["military",9],cost:{Knowledge:()=>1e6,Infernite:()=>1e3},effect:()=>"magic"===t.race.universe?z("tech_magic_missile_effect"):z("tech_disruptor_rifles_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},gauss_rifles:{id:"tech-gauss_rifles",title:()=>"magic"===t.race.universe?z("tech_magicword_kill"):z("tech_gauss_rifles"),desc:()=>"magic"===t.race.universe?z("tech_magicword_kill"):z("tech_gauss_rifles"),category:"military",era:"intergalactic",reqs:{military:9,science:18},grant:["military",10],cost:{Knowledge:()=>95e5,Bolognium:()=>1e5},effect:()=>"magic"===t.race.universe?z("tech_magicword_kill_effect"):z("tech_gauss_rifles_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},cyborg_soldiers:{id:"tech-cyborg_soldiers",title:z("tech_cyborg_soldiers"),desc:z("tech_cyborg_soldiers"),category:"military",era:"dimensional",reqs:{military:10,high_tech:18},grant:["military",11],cost:{Knowledge:()=>26e6,Adamantite:()=>8e6,Bolognium:()=>4e6,Orichalcum:()=>6e6},effect:z("tech_cyborg_soldiers_effect"),action(){return!!ri($(this)[0])},post(){Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update")}},space_marines:{id:"tech-space_marines",title:z("tech_space_marines"),desc:z("tech_space_marines_desc"),category:"military",era:"early_space",reqs:{space:3,mars:2},grant:["marines",1],cost:{Knowledge:()=>21e4},effect:()=>`
                            ${z("tech_space_marines_effect",[Ut().red])}
                            `,action(){return!!ri($(this)[0])&&(t.space.space_barracks={count:0,on:0},!0)},flair:z("tech_space_marines_flair")},hammocks:{id:"tech-hammocks",title:z("tech_hammocks"),desc:z("tech_hammocks"),category:"military",era:"intergalactic",reqs:{marines:1,nanoweave:1},grant:["marines",2],cost:{Knowledge:()=>89e5,Nanoweave:()=>3e4},effect:()=>z("tech_hammocks_effect"),action(){return!!ri($(this)[0])}},cruiser:{id:"tech-cruiser",title:z("tech_cruiser"),desc:z("tech_cruiser"),category:"military",era:"interstellar",reqs:{high_tech:14,proxima:2,aerogel:1},grant:["cruiser",1],cost:{Knowledge:()=>86e4},effect:z("tech_cruiser_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.cruiser={count:0,on:0},!0)}},armor:{id:"tech-armor",title:z("tech_armor"),desc:z("tech_armor_desc"),category:"military",era:"civilized",reqs:{military:1},not_trait:["apex_predator"],grant:["armor",1],cost:{Money:()=>250,Knowledge:()=>225,Furs:()=>250},effect:z("tech_armor_effect"),action(){return!!ri($(this)[0])}},plate_armor:{id:"tech-plate_armor",title:z("tech_plate_armor"),desc:z("tech_plate_armor_desc"),category:"military",era:"civilized",reqs:{armor:1,mining:3},grant:["armor",2],cost:{Knowledge:()=>3400,Iron:()=>600},effect:z("tech_plate_armor_effect"),action(){return!!ri($(this)[0])}},kevlar:{id:"tech-kevlar",title:z("tech_kevlar"),desc:z("tech_kevlar_desc"),category:"military",era:"globalized",reqs:{armor:2,polymer:1},grant:["armor",3],cost:{Knowledge:()=>86e3,Polymer:()=>750},effect:z("tech_kevlar_effect"),action(){return!!ri($(this)[0])}},nanoweave_vest:{id:"tech-nanoweave_vest",title:z("tech_nanoweave_vest"),desc:z("tech_nanoweave_vest"),category:"military",era:"intergalactic",reqs:{armor:3,nanoweave:1},grant:["armor",4],cost:{Knowledge:()=>925e4,Nanoweave:()=>75e3},effect:z("tech_nanoweave_vest_effect"),action(){return!!ri($(this)[0])}},laser_turret:{id:"tech-laser_turret",title:z("tech_laser_turret"),desc:z("tech_laser_turret"),category:"hell_dimension",era:"interstellar",reqs:{high_tech:9,portal:2},grant:["turret",1],cost:{Knowledge:()=>6e5,Elerium:()=>100},effect:()=>`
                            ${z("tech_laser_turret_effect1")}
                            ${z("tech_laser_turret_effect2")}
                            `,action(){return!!ri($(this)[0])},post(){Cs({el:"#fort"},"update"),ui(!1,["portal-turret"])}},plasma_turret:{id:"tech-plasma_turret",title:z("tech_plasma_turret"),desc:z("tech_plasma_turret"),category:"hell_dimension",era:"interstellar",reqs:{high_tech:13,turret:1},grant:["turret",2],cost:{Knowledge:()=>76e4,Elerium:()=>350},effect:()=>`
                            ${z("tech_plasma_turret_effect")}
                            ${z("tech_laser_turret_effect2")}
                            `,action(){return!!ri($(this)[0])},post(){Cs({el:"#fort"},"update"),ui(!1,["portal-turret"])}},black_powder:{id:"tech-black_powder",title:()=>"magic"===t.race.universe?z("tech_magic_powder"):z("tech_black_powder"),desc:()=>"magic"===t.race.universe?z("tech_magic_powder_desc"):z("tech_black_powder_desc"),category:"progress",era:"civilized",reqs:{mining:4},grant:["explosives",1],cost:{Knowledge:()=>4500,Mana:()=>"magic"===t.race.universe?100:0,Crystal:()=>"magic"===t.race.universe?250:0,Coal:()=>"magic"===t.race.universe?300:500},effect:()=>"magic"===t.race.universe?z("tech_magic_powder_effect"):z("tech_black_powder_effect"),action(){return!!ri($(this)[0])}},dynamite:{id:"tech-dynamite",title:z("tech_dynamite"),desc:z("tech_dynamite"),category:"mining",era:"civilized",reqs:{explosives:1},grant:["explosives",2],cost:{Knowledge:()=>4800,Coal:()=>750},effect:z("tech_dynamite_effect"),action(){return!!ri($(this)[0])}},anfo:{id:"tech-anfo",title:z("tech_anfo"),desc:z("tech_anfo"),category:"mining",era:"industrialized",reqs:{explosives:2,oil:1},grant:["explosives",3],cost:{Knowledge:()=>42e3,Oil:()=>2500},effect:z("tech_anfo_effect"),action(){return!!ri($(this)[0])}},mad:{id:"tech-mad",title:z("tech_mad"),desc:z("tech_mad_desc"),category:"special",era:"globalized",reqs:{uranium:1,explosives:3,high_tech:7},not_trait:["cataclysm","lone_survivor"],grant:["mad",1],condition:()=>!(t.race.sludge||t.race.truepath&&!t.tech.world_control),cost:{Knowledge:()=>12e4,Oil:()=>t.city.ptrait.includes("dense")?1e4:8500,Uranium:()=>1250},effect:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("tech_mad_effect_easter"):z("tech_mad_effect"),action(){return!!ri($(this)[0])&&(t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?hs(z("tech_mad_info_easter"),"info",!1,["progress"]):hs(z("tech_mad_info"),"info",!1,["progress"]),t.civic.mad.display=!0,!0)}},cement:{id:"tech-cement",title:z("tech_cement"),desc:z("tech_cement_desc"),category:"cement",era:"civilized",reqs:{mining:1,storage:1,science:1},not_trait:["flier"],grant:["cement",1],cost:{Knowledge:()=>500},effect:z("tech_cement_effect"),action(){return!!ri($(this)[0])&&(t.city.cement_plant={count:0,on:0},!0)}},rebar:{id:"tech-rebar",title:z("tech_rebar"),desc:z("tech_rebar"),category:"cement",era:"civilized",reqs:{mining:3,cement:1},not_trait:["flier"],grant:["cement",2],cost:{Knowledge:()=>3200,Iron:()=>750},effect:z("tech_rebar_effect"),action(){return!!ri($(this)[0])}},steel_rebar:{id:"tech-steel_rebar",title:z("tech_steel_rebar"),desc:z("tech_steel_rebar"),category:"cement",era:"civilized",reqs:{smelting:2,cement:2},not_trait:["flier"],grant:["cement",3],cost:{Knowledge:()=>6750,Steel:()=>750},effect:z("tech_steel_rebar_effect"),action(){return!!ri($(this)[0])}},portland_cement:{id:"tech-portland_cement",title:z("tech_portland_cement"),desc:z("tech_portland_cement"),category:"cement",era:"industrialized",reqs:{cement:3,high_tech:3},not_trait:["flier"],grant:["cement",4],cost:{Knowledge:()=>32e3},effect:z("tech_portland_cement_effect"),action(){return!!ri($(this)[0])}},screw_conveyor:{id:"tech-screw_conveyor",title:z("tech_screw_conveyor"),desc:z("tech_screw_conveyor"),category:"cement",era:"globalized",reqs:{cement:4,high_tech:4},not_trait:["flier"],grant:["cement",5],cost:{Knowledge:()=>72e3},effect:z("tech_screw_conveyor_effect"),action(){return!!ri($(this)[0])}},adamantite_screws:{id:"tech-adamantite_screws",title:z("tech_adamantite_screws"),desc:z("tech_adamantite_screws"),category:"cement",era:"interstellar",reqs:{cement:5,alpha:2},not_trait:["cataclysm","flier"],grant:["cement",6],cost:{Knowledge:()=>5e5,Adamantite:()=>1e4},effect:z("tech_adamantite_screws_effect",[3]),action(){return!!ri($(this)[0])}},hunter_process:{id:"tech-hunter_process",title:z("tech_hunter_process"),desc:z("tech_hunter_process"),category:"mining",era:"industrialized",reqs:{high_tech:3,smelting:2},grant:["titanium",1],cost:{Knowledge:()=>45e3,Titanium:()=>1e3},effect:z("tech_hunter_process_effect"),action(){return!!ri($(this)[0])&&(t.resource.Titanium.value=Ca.Titanium,!0)}},kroll_process:{id:"tech-kroll_process",title:z("tech_kroll_process"),desc:z("tech_kroll_process"),category:"mining",era:"globalized",reqs:{titanium:1,high_tech:4},grant:["titanium",2],cost:{Knowledge:()=>78e3,Titanium:()=>1e4},effect:z("tech_kroll_process_effect"),action(){return!!ri($(this)[0])}},cambridge_process:{id:"tech-cambridge_process",title:z("tech_cambridge_process"),desc:z("tech_cambridge_process"),category:"mining",era:"early_space",reqs:{titanium:2,supercollider:1},grant:["titanium",3],cost:{Knowledge:()=>135e3,Titanium:()=>17500},effect:z("tech_cambridge_process_effect"),action(){return!!ri($(this)[0])}},pynn_partical:{id:"tech-pynn_partical",title:z("tech_pynn_partical"),desc:z("tech_pynn_partical"),category:"progress",era:"early_space",path:["standard"],reqs:{supercollider:1},grant:["particles",1],cost:{Knowledge:()=>1e5},effect:z("tech_pynn_partical_effect"),action(){return!!ri($(this)[0])}},matter_compression:{id:"tech-matter_compression",title:z("tech_matter_compression"),desc:z("tech_matter_compression"),category:"storage",era:"early_space",path:["standard"],reqs:{particles:1},grant:["particles",2],cost:{Knowledge:()=>112500},effect:z("tech_matter_compression_effect"),action(){return!!ri($(this)[0])}},higgs_boson:{id:"tech-higgs_boson",title:z("tech_higgs_boson"),desc:z("tech_higgs_boson"),category:"science",era:"early_space",path:["standard"],reqs:{particles:2,supercollider:2},grant:["particles",3],cost:{Knowledge:()=>125e3},effect:z("tech_higgs_boson_effect"),action(){return!!ri($(this)[0])}},dimensional_compression:{id:"tech-dimensional_compression",title:z("tech_dimensional_compression"),desc:z("tech_dimensional_compression"),category:"storage",era:"interstellar",reqs:{particles:3,science:11,supercollider:3},grant:["particles",4],cost:{Knowledge:()=>425e3},effect:z("tech_dimensional_compression_effect"),action(){return!!ri($(this)[0])}},theology:{id:"tech-theology",title:z("tech_theology"),desc:z("tech_theology"),category:"religion",era:"civilized",reqs:{theology:1,housing:1,cement:1},grant:["theology",2],cost:{Knowledge:()=>900},effect:z("tech_theology_effect"),action(){return!!ri($(this)[0])&&(t.city.temple={count:0},t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0}),t.genes.ancients&&t.genes.ancients>=2&&(t.civic.priest.display=!0),!0)}},fanaticism:{id:"tech-fanaticism",title:z("tech_fanaticism"),desc:z("tech_fanaticism"),category:"religion",era:"civilized",wiki:!t.genes.transcendence,reqs:{theology:2},grant:["theology",3],not_gene:["transcendence"],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-anthropology"===e.id)),cost:{Knowledge:()=>2500},effect:`
                            ${z("tech_fanaticism_effect")}
                            ${z("tech_fanaticism_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.tech.fanaticism=1,t.race.gods===t.race.species&&qn("second_evolution"),mi(t.race.gods),!0)}},alt_fanaticism:{id:"tech-alt_fanaticism",title:z("tech_fanaticism"),desc:z("tech_fanaticism"),category:"religion",era:"civilized",wiki:!!t.genes.transcendence,reqs:{theology:2},grant:["fanaticism",1],gene:["transcendence"],cost:{Knowledge:()=>2500},effect:`
                            ${z("tech_fanaticism_effect")}
                            `,action(){return!!ri($(this)[0])&&(2===t.tech.theology&&(t.tech.theology=3),t.race.gods===t.race.species&&qn("second_evolution"),mi(t.race.gods),!0)}},ancient_theology:{id:"tech-ancient_theology",title:z("tech_ancient_theology"),desc:z("tech_ancient_theology"),category:"religion",era:"early_space",reqs:{theology:3,mars:2},grant:["theology",4],condition:()=>!!t.genes.ancients,cost:{Knowledge:()=>18e4},effect:()=>z("tech_ancient_theology_effect",["none"!==t.race.old_gods?Ki[t.race.old_gods.toLowerCase()].entity:Ki[t.race.species].entity,"none"!==t.race.gods?Ki[t.race.gods.toLowerCase()].entity:Ki[t.race.species].entity]),action(){return!!ri($(this)[0])&&(t.space.ziggurat={count:0},!0)}},study:{id:"tech-study",title:z("tech_study"),desc:z("tech_study_desc"),category:"religion",era:"early_space",reqs:{theology:4},grant:["theology",5],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-deify"===e.id)),cost:{Knowledge:()=>195e3},effect:()=>`
                            ${z("tech_study_effect",["none"!==t.race.old_gods?Ki[t.race.old_gods.toLowerCase()].entity:Ki[t.race.species].entity])}
                            ${z("tech_study_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.tech.ancient_study=1,!0)}},encoding:{id:"tech-encoding",title:z("tech_encoding"),desc:z("tech_encoding_desc"),category:"religion",era:"deep_space",reqs:{ancient_study:1,mars:5},grant:["ancient_study",2],cost:{Knowledge:()=>268e3},effect:()=>`
                            ${z("tech_encoding_effect")}
                            `,action(){return!!ri($(this)[0])}},deify:{id:"tech-deify",title:z("tech_deify"),desc:z("tech_deify_desc"),category:"religion",era:"early_space",reqs:{theology:4},grant:["theology",5],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-study"===e.id)),cost:{Knowledge:()=>195e3},effect:()=>`
                            ${z("tech_deify_effect",["none"!==t.race.old_gods?Ki[t.race.old_gods.toLowerCase()].entity:Ki[t.race.species].entity])}
                            ${z("tech_deify_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.tech.ancient_deify=1,mi(t.race.old_gods),xe("Genetics"),!0)}},infusion:{id:"tech-infusion",title:z("tech_infusion"),desc:z("tech_infusion_desc"),category:"religion",era:"deep_space",reqs:{ancient_deify:1,mars:5},grant:["ancient_deify",2],cost:{Knowledge:()=>268e3},effect:()=>`
                            ${z("tech_infusion_effect")}
                            `,action(){return!!ri($(this)[0])}},indoctrination:{id:"tech-indoctrination",title:z("tech_indoctrination"),desc:z("tech_indoctrination"),category:"religion",era:"civilized",reqs:{fanaticism:1},grant:["fanaticism",2],cost:{Knowledge:()=>5e3},effect:z("tech_indoctrination_effect"),action(){return!!ri($(this)[0])},post(){t.race.terrifying&&(t.tech.fanaticism=3,Qr())}},missionary:{id:"tech-missionary",title:z("tech_missionary"),desc:z("tech_missionary"),category:"religion",era:"discovery",reqs:{fanaticism:2},not_trait:["terrifying"],grant:["fanaticism",3],cost:{Knowledge:()=>1e4},effect:z("tech_missionary_effect"),action(){return!!ri($(this)[0])}},zealotry:{id:"tech-zealotry",title:z("tech_zealotry"),desc:z("tech_zealotry"),category:"religion",era:"discovery",reqs:{fanaticism:3},grant:["fanaticism",4],cost:{Knowledge:()=>25e3},effect:z("tech_zealotry_effect"),action(){return!!ri($(this)[0])}},anthropology:{id:"tech-anthropology",title:z("tech_anthropology"),desc:z("tech_anthropology"),category:"religion",era:"civilized",wiki:!t.genes.transcendence,reqs:{theology:2},grant:["theology",3],not_gene:["transcendence"],no_queue:()=>!!t.r_queue.queue.some((e=>"tech-fanaticism"===e.id)),cost:{Knowledge:()=>2500},effect:`
                            ${z("tech_anthropology_effect")}
                            ${z("tech_anthropology_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.tech.anthropology=1,!0)}},alt_anthropology:{id:"tech-alt_anthropology",title:z("tech_anthropology"),desc:z("tech_anthropology"),category:"religion",era:"civilized",wiki:!!t.genes.transcendence,reqs:{theology:2},grant:["anthropology",1],gene:["transcendence"],cost:{Knowledge:()=>2500},effect:`
                            ${z("tech_anthropology_effect")}
                            `,action(){return!!ri($(this)[0])&&(2===t.tech.theology&&(t.tech.theology=3),!0)}},mythology:{id:"tech-mythology",title:z("tech_mythology"),desc:z("tech_mythology"),category:"religion",era:"civilized",reqs:{anthropology:1},grant:["anthropology",2],cost:{Knowledge:()=>5e3},effect:z("tech_mythology_effect"),action(){return!!ri($(this)[0])}},archaeology:{id:"tech-archaeology",title:z("tech_archaeology"),desc:z("tech_archaeology"),category:"science",era:"discovery",reqs:{anthropology:2},grant:["anthropology",3],cost:{Knowledge:()=>1e4},effect:z("tech_archaeology_effect"),action(){return!!ri($(this)[0])}},merchandising:{id:"tech-merchandising",title:z("tech_merchandising"),desc:z("tech_merchandising"),category:"banking",era:"discovery",reqs:{anthropology:3},grant:["anthropology",4],cost:{Knowledge:()=>25e3},effect:()=>t.race.truepath?z("tech_merchandising_effect_tp"):z("tech_merchandising_effect"),action(){return!!ri($(this)[0])}},astrophysics:{id:"tech-astrophysics",title:z("tech_astrophysics"),desc:z("tech_astrophysics_desc"),category:"storage",era:"early_space",reqs:{space:2},grant:["space_explore",1],cost:{Knowledge:()=>125e3},effect:z("tech_astrophysics_effect"),action(){return!!ri($(this)[0])&&(t.space.propellant_depot={count:0},!0)}},rover:{id:"tech-rover",title:z("tech_rover"),desc:z("tech_rover"),category:"space_exploration",era:"early_space",reqs:{space_explore:1},grant:["space_explore",2],cost:{Knowledge:()=>135e3,Alloy:()=>22e3,Polymer:()=>18e3,Uranium:()=>750},effect:z("tech_rover_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.moon=!0,t.space.moon_base={count:0,on:0,support:0,s_max:0},!0)}},probes:{id:"tech-probes",title:z("tech_probes"),desc:z("tech_probes"),category:"space_exploration",era:"early_space",reqs:{space_explore:2},grant:["space_explore",3],cost:{Knowledge:()=>168e3,Steel:()=>1e5,Iridium:()=>5e3,Uranium:()=>2250,Helium_3:()=>3500},effect:z("tech_probes_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.red=!0,t.settings.space.hell=!0,t.space.spaceport={count:0,on:0,support:0,s_max:0},!0)}},starcharts:{id:"tech-starcharts",title:z("tech_starcharts"),desc:z("tech_starcharts"),category:"space_exploration",era:"early_space",reqs:{space_explore:3,science:9},grant:["space_explore",4],cost:{Knowledge:()=>185e3},effect:z("tech_starcharts_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.gas=!0,t.settings.space.sun=!0,t.race.truepath&&(t.settings.showOuter=!0),t.space.swarm_control={count:0,support:0,s_max:0},!0)}},colonization:{id:"tech-colonization",title:z("tech_colonization"),desc:()=>z("tech_colonization_desc",[Ut().red]),category:"agriculture",era:"early_space",reqs:{space:4,mars:1},grant:["mars",2],cost:{Knowledge:()=>172e3},effect:()=>z(t.race.artifical?"tech_colonization_artifical_effect":"tech_colonization_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.biodome={count:0,on:0},!0)}},red_tower:{id:"tech-red_tower",title:()=>z("tech_red_tower",[Ut().red]),desc:()=>z("tech_red_tower",[Ut().red]),category:"space_exploration",era:"early_space",reqs:{mars:2},grant:["mars",3],cost:{Knowledge:()=>195e3},effect:()=>z("tech_red_tower_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.red_tower={count:0,on:0},!0)}},space_manufacturing:{id:"tech-space_manufacturing",title:z("tech_space_manufacturing"),desc:z("tech_space_manufacturing_desc"),category:"crafting",era:"early_space",reqs:{mars:3},grant:["mars",4],cost:{Knowledge:()=>22e4},effect:()=>z("tech_space_manufacturing_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.red_factory={count:0,on:0},!0)}},exotic_lab:{id:"tech-exotic_lab",title:z("tech_exotic_lab"),desc:z("tech_exotic_lab_desc"),category:"science",era:"deep_space",reqs:{mars:4,asteroid:5},grant:["mars",5],cost:{Knowledge:()=>25e4},effect:z("tech_exotic_lab_effect"),action(){return!!ri($(this)[0])&&(t.space.exotic_lab={count:0,on:0},!0)}},hydroponics:{id:"tech-hydroponics",title:z("tech_hydroponics"),desc:()=>z("tech_hydroponics"),category:"agriculture",era:"intergalactic",reqs:{mars:5,gateway:3},grant:["mars",6],cost:{Knowledge:()=>3e6,Bolognium:()=>5e5},effect:()=>z("tech_hydroponics_effect"),action(){return!!ri($(this)[0])}},dyson_sphere:{id:"tech-dyson_sphere",title:z("tech_dyson_sphere"),desc:z("tech_dyson_sphere"),category:"power_generation",era:"early_space",reqs:{solar:1},grant:["solar",2],cost:{Knowledge:()=>195e3},effect:z("tech_dyson_sphere_effect"),action(){return!!ri($(this)[0])}},dyson_swarm:{id:"tech-dyson_swarm",title:z("tech_dyson_swarm"),desc:z("tech_dyson_swarm"),category:"power_generation",era:"early_space",reqs:{solar:2},grant:["solar",3],cost:{Knowledge:()=>21e4},effect:z("tech_dyson_swarm_effect"),action(){return!!ri($(this)[0])&&(t.space.swarm_satellite={count:0},!0)}},swarm_plant:{id:"tech-swarm_plant",title:z("tech_swarm_plant"),desc:z("tech_swarm_plant"),category:"power_generation",era:"deep_space",reqs:{solar:3,hell:1,gas_moon:1},grant:["solar",4],cost:{Knowledge:()=>25e4},effect:()=>z("tech_swarm_plant_effect",[Ki[t.race.species].home,Ut().hell]),action(){return!!ri($(this)[0])&&(t.space.swarm_plant={count:0},!0)}},space_sourced:{id:"tech-space_sourced",title:z("tech_space_sourced"),desc:z("tech_space_sourced_desc"),category:"power_generation",era:"deep_space",reqs:{solar:4,asteroid:3},grant:["solar",5],cost:{Knowledge:()=>3e5},effect:z("tech_space_sourced_effect"),action(){return!!ri($(this)[0])}},swarm_plant_ai:{id:"tech-swarm_plant_ai",title:z("tech_swarm_plant_ai"),desc:z("tech_swarm_plant_ai"),category:"power_generation",era:"deep_space",reqs:{solar:4,high_tech:10},grant:["swarm",1],cost:{Knowledge:()=>335e3},effect:z("tech_swarm_plant_ai_effect"),action(){return!!ri($(this)[0])}},swarm_control_ai:{id:"tech-swarm_control_ai",title:z("tech_swarm_control_ai"),desc:z("tech_swarm_control_ai"),category:"power_generation",era:"deep_space",reqs:{swarm:1},grant:["swarm",2],cost:{Knowledge:()=>36e4},effect:z("tech_swarm_control_ai_effect"),action(){return!!ri($(this)[0])}},quantum_swarm:{id:"tech-quantum_swarm",title:z("tech_quantum_swarm"),desc:z("tech_quantum_swarm"),category:"power_generation",era:"deep_space",reqs:{swarm:2,high_tech:11},grant:["swarm",3],cost:{Knowledge:()=>45e4},effect:z("tech_quantum_swarm_effect"),action(){return!!ri($(this)[0])}},perovskite_cell:{id:"tech-perovskite_cell",title:z("tech_perovskite_cell"),desc:z("tech_perovskite_cell"),category:"power_generation",era:"interstellar",reqs:{swarm:3},grant:["swarm",4],path:["standard","truepath"],cost:{Knowledge:()=>525e3,Titanium:()=>1e5},effect:z("tech_perovskite_cell_effect"),action(){return!!ri($(this)[0])}},swarm_convection:{id:"tech-swarm_convection",title:z("tech_swarm_convection"),desc:z("tech_swarm_convection"),category:"power_generation",era:"interstellar",reqs:{swarm:4,stanene:1},grant:["swarm",5],path:["standard","truepath"],cost:{Knowledge:()=>725e3,Stanene:()=>1e5},effect:z("tech_swarm_convection_effect"),action(){return!!ri($(this)[0])}},orichalcum_panels:{id:"tech-orichalcum_panels",title:z("tech_orichalcum_panels"),desc:z("tech_orichalcum_panels"),category:"power_generation",era:"intergalactic",reqs:{high_tech:17,swarm:5},grant:["swarm",6],cost:{Knowledge:()=>14e6,Orichalcum:()=>125e3},effect:()=>z("tech_orichalcum_panels_effect"),action(){return!!ri($(this)[0])}},dyson_net:{id:"tech-dyson_net",title:z("tech_dyson_net"),desc:z("tech_dyson_net"),category:"power_generation",era:"interstellar",reqs:{solar:3,proxima:2,stanene:1},grant:["proxima",3],cost:{Knowledge:()=>8e5},effect:z("tech_dyson_net_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.dyson={count:0},!0)}},dyson_sphere2:{id:"tech-dyson_sphere2",title:z("tech_dyson_sphere"),desc:z("tech_dyson_sphere"),category:"power_generation",era:"intergalactic",reqs:{proxima:3,piracy:1},grant:["dyson",1],cost:{Knowledge:()=>5e6},effect:z("tech_dyson_sphere2_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.dyson_sphere={count:0},!0)}},orichalcum_sphere:{id:"tech-orichalcum_sphere",title:z("tech_orichalcum_sphere"),desc:z("tech_orichalcum_sphere"),category:"power_generation",era:"intergalactic",reqs:{dyson:1,science:19},condition:()=>!!(t.interstellar.dyson_sphere&&t.interstellar.dyson_sphere.count>=100),grant:["dyson",2],cost:{Knowledge:()=>175e5,Orichalcum:()=>25e4},effect:z("tech_orichalcum_sphere_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.orichalcum_sphere={count:0},!0)}},gps:{id:"tech-gps",title:z("tech_gps"),desc:z("tech_gps"),category:"market",era:"early_space",reqs:{space_explore:1},not_trait:["terrifying"],grant:["satellite",1],cost:{Knowledge:()=>15e4},effect:z("tech_gps_effect"),action(){return!!ri($(this)[0])&&(t.space.gps={count:0},!0)}},nav_beacon:{id:"tech-nav_beacon",title:z("tech_nav_beacon"),desc:z("tech_nav_beacon"),category:"space_exploration",era:"early_space",reqs:{luna:1},grant:["luna",2],cost:{Knowledge:()=>18e4},effect:z("tech_nav_beacon_effect"),action(){return!!ri($(this)[0])&&(t.space.nav_beacon={count:0,on:0},!0)}},subspace_signal:{id:"tech-subspace_signal",title:z("tech_subspace_signal"),desc:z("tech_subspace_signal"),category:"space_exploration",era:"interstellar",reqs:{science:13,luna:2,stanene:1},grant:["luna",3],cost:{Knowledge:()=>7e5,Stanene:()=>125e3},effect:()=>z("tech_subspace_signal_effect",[Ut().red]),action(){return!!ri($(this)[0])}},atmospheric_mining:{id:"tech-atmospheric_mining",title:z("tech_atmospheric_mining"),desc:z("tech_atmospheric_mining"),category:"power_generation",era:"early_space",reqs:{space:5},grant:["gas_giant",1],cost:{Knowledge:()=>19e4},effect:z("tech_atmospheric_mining_effect"),action(){return!!ri($(this)[0])&&(t.space.gas_mining={count:0,on:0},t.space.gas_storage={count:0},!0)}},helium_attractor:{id:"tech-helium_attractor",title:z("tech_helium_attractor"),desc:z("tech_helium_attractor"),category:"power_generation",era:"deep_space",reqs:{gas_giant:1,elerium:1},grant:["helium",1],cost:{Knowledge:()=>29e4,Elerium:()=>250},effect:()=>z("tech_helium_attractor_effect",[Ut().gas]),action(){return!!ri($(this)[0])}},ram_scoops:{id:"tech-ram_scoops",title:z("tech_ram_scoops"),desc:z("tech_ram_scoops"),category:"power_generation",era:"interstellar",reqs:{nebula:2},grant:["ram_scoop",1],cost:{Knowledge:()=>58e4},effect:()=>z("tech_ram_scoops_effect"),action(){return!!ri($(this)[0])}},elerium_prospecting:{id:"tech-elerium_prospecting",title:z("tech_elerium_prospecting"),desc:z("tech_elerium_prospecting"),category:"space_mining",era:"interstellar",reqs:{nebula:2},grant:["nebula",3],cost:{Knowledge:()=>61e4},effect:()=>z("tech_elerium_prospecting_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.elerium_prospector={count:0,on:0},!0)}},zero_g_mining:{id:"tech-zero_g_mining",title:z("tech_zero_g_mining"),desc:z("tech_zero_g_mining"),category:"space_mining",era:"early_space",reqs:{asteroid:1,high_tech:8},grant:["asteroid",2],cost:{Knowledge:()=>21e4},effect:z("tech_zero_g_mining_effect"),action(){return!!ri($(this)[0])&&(t.space.space_station={count:0,on:0,support:0,s_max:0},t.space.iridium_ship={count:0,on:0},t.space.iron_ship={count:0,on:0},!0)}},elerium_mining:{id:"tech-elerium_mining",title:z("tech_elerium_mining"),desc:z("tech_elerium_mining"),category:"space_mining",era:"deep_space",reqs:{asteroid:4},grant:["asteroid",5],cost:{Knowledge:()=>235e3,Elerium:()=>t.race.truepath?.5:1},effect:z("tech_elerium_mining_effect"),action(){return!!ri($(this)[0])&&(t.space.elerium_ship={count:0,on:0},t.race.cataclysm&&qn("iron_will",!1,2),!0)}},laser_mining:{id:"tech-laser_mining",title:z("tech_laser_mining"),desc:z("tech_laser_mining"),category:"space_mining",era:"deep_space",reqs:{asteroid:5,elerium:1,high_tech:9},grant:["asteroid",6],cost:{Knowledge:()=>35e4},effect:z("tech_laser_mining_effect"),action(){return!!ri($(this)[0])}},plasma_mining:{id:"tech-plasma_mining",title:z("tech_plasma_mining"),desc:z("tech_plasma_mining"),category:"space_mining",era:"interstellar",reqs:{asteroid:6,high_tech:13},grant:["asteroid",7],path:["standard","truepath"],cost:{Knowledge:()=>825e3},effect:z("tech_plasma_mining_effect"),action(){return!!ri($(this)[0])}},elerium_tech:{id:"tech-elerium_tech",title:z("tech_elerium_tech"),desc:z("tech_elerium_tech"),category:"space_mining",era:"deep_space",reqs:{asteroid:5},grant:["elerium",1],cost:{Knowledge:()=>275e3,Elerium:()=>20},effect:z("tech_elerium_tech_effect"),action(){return!!ri($(this)[0])}},elerium_reactor:{id:"tech-elerium_reactor",title:z("tech_elerium_reactor"),desc:z("tech_elerium_reactor"),category:"power_generation",era:"deep_space",reqs:{dwarf:1,elerium:1},grant:["elerium",2],cost:{Knowledge:()=>325e3,Elerium:()=>180},effect:z("tech_elerium_reactor_effect"),action(){return!!ri($(this)[0])&&(t.space.e_reactor={count:0,on:0},!0)}},neutronium_housing:{id:"tech-neutronium_housing",title:z("tech_neutronium_housing"),desc:z("tech_neutronium_housing"),category:"housing",era:"deep_space",reqs:{gas_moon:1},grant:["space_housing",1],cost:{Knowledge:()=>275e3,Neutronium:()=>350},effect:()=>z("tech_neutronium_housing_effect",[Ut().red]),action(){return!!ri($(this)[0])}},unification:{id:"tech-unification",title:z("tech_unification"),desc:()=>z("tech_unification_desc",[Ki[t.race.species].home]),category:"special",era:"early_space",path:["standard"],reqs:{mars:2},grant:["unify",1],cost:{Knowledge:()=>2e5},effect:z("tech_unification_effect"),action(){return!!ri($(this)[0])}},unification2:{id:"tech-unification2",title:z("tech_unification"),desc:()=>z("tech_unification_desc",[Ki[t.race.species].home]),category:"special",era:"early_space",path:["standard"],reqs:{unify:1},grant:["unify",2],cost:{Bool(){let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].buy||t.civic.foreign[`gov${a}`].anx)&&e++;return 3===e}},effect(){let e=t.race.banana?`
                            ${z("tech_unification_banana")}
                            `:"";return`
                            ${z("tech_unification_effect2")}
                            ${z("tech_unification_warning")}
                            ${e}`},action(){return!!ri($(this)[0])&&(t.race.banana&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),delete t.race.banana),t.civic.foreign.gov0.occ&&t.civic.foreign.gov1.occ&&t.civic.foreign.gov2.occ&&qn("world_domination"),t.civic.foreign.gov0.anx&&t.civic.foreign.gov1.anx&&t.civic.foreign.gov2.anx&&qn("illuminati"),t.civic.foreign.gov0.buy&&t.civic.foreign.gov1.buy&&t.civic.foreign.gov2.buy&&qn("syndicate"),0===t.stats.attacks&&qn("pacifist"),qr(),!0)}},unite:{id:"tech-unite",title:z("tech_unite"),desc:()=>z("tech_unite_desc"),category:"special",era:"globalized",path:["truepath"],reqs:{unify:1},grant:["unify",2],cost:{Bool(){let e=0;for(let a=0;a<3;a++)(t.civic.foreign[`gov${a}`].occ||t.civic.foreign[`gov${a}`].buy||t.civic.foreign[`gov${a}`].anx)&&e++;return 3===e}},effect:()=>`
                            ${z("tech_unite_effect")}
                            ${z("tech_unification_effect2")}
                            `,action(){return!!ri($(this)[0])&&(t.race.banana&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),delete t.race.banana),t.civic.foreign.gov0.occ&&t.civic.foreign.gov1.occ&&t.civic.foreign.gov2.occ&&qn("world_domination"),t.civic.foreign.gov0.anx&&t.civic.foreign.gov1.anx&&t.civic.foreign.gov2.anx&&qn("illuminati"),t.civic.foreign.gov0.buy&&t.civic.foreign.gov1.buy&&t.civic.foreign.gov2.buy&&qn("syndicate"),0===t.stats.attacks&&qn("pacifist"),qr(),t.race.truepath&&!t.tech.rival&&(t.tech.rival=1,hs(z("civics_rival_unlocked",[Z(3)]),"info",!1,["progress","combat"])),!0)}},genesis:{id:"tech-genesis",title:z("tech_genesis"),desc:z("tech_genesis"),category:"special",era:"deep_space",reqs:{high_tech:10,genesis:1},grant:["genesis",2],cost:{Knowledge:()=>35e4},effect:z("tech_genesis_effect"),action(){return!!ri($(this)[0])}},star_dock:{id:"tech-star_dock",title:z("tech_star_dock"),desc:z("tech_star_dock"),category:"special",era:"deep_space",reqs:{genesis:2,space:5,high_tech:10},grant:["genesis",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>38e4},effect:z("tech_star_dock_effect"),action(){return!!ri($(this)[0])&&(t.space.star_dock={count:0,ship:0,probe:0,template:t.race.species},!0)}},interstellar:{id:"tech-interstellar",title:z("tech_interstellar"),desc:z("tech_interstellar"),category:"space_exploration",era:"deep_space",reqs:{genesis:3},grant:["genesis",4],cost:{Knowledge:()=>4e5},effect:z("tech_interstellar_effect"),action(){return!!ri($(this)[0])&&(t.starDock.probes={count:0},!0)}},genesis_ship:{id:"tech-genesis_ship",title:()=>t.race.cataclysm?z("tech_generational_ship"):z("tech_genesis_ship"),desc:()=>t.race.cataclysm?z("tech_generational_ship"):z("tech_genesis_ship"),category:"special",era:"deep_space",reqs:{genesis:4},grant:["genesis",5],cost:{Knowledge:()=>425e3},effect:()=>t.race.cataclysm?z("tech_generational_effect"):z("tech_genesis_ship_effect"),action(){return!!ri($(this)[0])&&(t.starDock.seeder={count:0},t.race.cataclysm&&qn("iron_will",!1,4),!0)}},geck:{id:"tech-geck",title:()=>z("tech_geck"),desc:()=>z("tech_geck_desc"),category:"special",era:"deep_space",reqs:{genesis:5},grant:["geck",1],condition:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5),cost:{Knowledge:()=>5e5},effect:()=>z("tech_geck_effect"),action(){return!!ri($(this)[0])&&(t.starDock.geck={count:0},!0)}},genetic_decay:{id:"tech-genetic_decay",title:z("tech_genetic_decay"),desc:z("tech_genetic_decay"),category:"genes",era:"early_space",reqs:{decay:1},grant:["decay",2],cost:{Knowledge:()=>2e5},effect:z("tech_genetic_decay_effect"),action(){return!!ri($(this)[0])}},stabilize_decay:{id:"tech-stabilize_decay",title:z("tech_stabilize_decay"),desc:z("tech_stabilize_decay"),category:"genes",era:"dimensional",reqs:{decay:2,high_tech:18},grant:["decay",3],cost:{Knowledge:()=>5e7,Blood_Stone:()=>1},effect:z("tech_stabilize_decay_effect"),action(){return!!ri($(this)[0])}},tachyon:{id:"tech-tachyon",title:z("tech_tachyon"),desc:z("tech_tachyon"),category:"progress",era:"interstellar",reqs:{wsc:1},grant:["ftl",1],cost:{Knowledge:()=>435e3},effect:z("tech_tachyon_effect"),action(){return!!ri($(this)[0])}},warp_drive:{id:"tech-warp_drive",title:z("tech_warp_drive"),desc:z("tech_warp_drive"),category:"space_exploration",era:"interstellar",reqs:{ftl:1},grant:["ftl",2],cost:{Knowledge:()=>45e4},effect:z("tech_warp_drive_effect"),action(){return!!ri($(this)[0])&&(t.settings.showDeep=!0,t.settings.space.alpha=!0,t.interstellar.starport={count:0,on:0,support:0,s_max:0},!0)}},habitat:{id:"tech-habitat",title:z("tech_habitat"),desc:z("tech_habitat_desc"),category:"housing",era:"interstellar",reqs:{alpha:2,droids:1},grant:["alpha",3],cost:{Knowledge:()=>48e4},effect:z("tech_habitat_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.habitat={count:0,on:0},!0)}},graphene:{id:"tech-graphene",title:z("tech_graphene"),desc:z("tech_graphene"),category:"crafting",era:"interstellar",reqs:{alpha:3,infernite:1},grant:["graphene",1],cost:{Knowledge:()=>54e4,Adamantite:()=>1e4},effect:z("tech_graphene_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},!0)}},aerogel:{id:"tech-aerogel",title:z("tech_aerogel"),desc:z("tech_aerogel"),category:"crafting",era:"interstellar",reqs:{graphene:1,science:13},grant:["aerogel",1],cost:{Knowledge:()=>75e4,Graphene:()=>5e4,Infernite:()=>500},effect:z("tech_aerogel_effect"),action(){return!!ri($(this)[0])&&(t.resource.Aerogel.display=!0,sa(),!0)},post(){cs()}},mega_manufacturing:{id:"tech-mega_manufacturing",title:z("tech_mega_manufacturing"),desc:z("tech_mega_manufacturing"),category:"crafting",era:"intergalactic",reqs:{high_tech:16,alpha:3},grant:["alpha",4],cost:{Knowledge:()=>565e4},effect:()=>z("tech_mega_manufacturing_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.int_factory={count:0,on:0},!0)}},luxury_condo:{id:"tech-luxury_condo",title:z("tech_luxury_condo"),desc:z("tech_luxury_condo"),category:"housing",era:"intergalactic",reqs:{high_tech:17,alpha:4},grant:["alpha",5],cost:{Knowledge:()=>15e6},effect:()=>z("tech_luxury_condo_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.luxury_condo={count:0,on:0},!0)}},stellar_engine:{id:"tech-stellar_engine",title:z("tech_stellar_engine"),desc:z("tech_stellar_engine"),category:"stellar_engine",era:"interstellar",reqs:{blackhole:2},grant:["blackhole",3],cost:{Knowledge:()=>1e6},effect:z("tech_stellar_engine_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.stellar_engine={count:0,mass:8,exotic:0},!0)}},mass_ejector:{id:"tech-mass_ejector",title:z("tech_mass_ejector"),desc:z("tech_mass_ejector"),category:"stellar_engine",era:"interstellar",reqs:{blackhole:4},grant:["blackhole",5],cost:{Knowledge:()=>11e5},effect:z("tech_mass_ejector_effect"),action(){return!!ri($(this)[0])&&(t.interstellar.mass_ejector={count:0,on:0,total:0,mass:0,Food:0,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0,Plywood:0,Brick:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0},!0)}},asteroid_redirect:{id:"tech-asteroid_redirect",title:z("tech_asteroid_redirect"),desc:z("tech_asteroid_redirect"),category:"stellar_engine",era:"intergalactic",reqs:{blackhole:5,gateway:3},grant:["blackhole",6],cost:{Knowledge:()=>35e5},effect:z("tech_asteroid_redirect_effect"),action(){return!!ri($(this)[0])},post(){xe("Physics")}},exotic_infusion:{id:"tech-exotic_infusion",title:z("tech_exotic_infusion"),desc:z("tech_exotic_infusion"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:1},grant:["whitehole",2],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect:()=>`
                            ${z("tech_exotic_infusion_effect",[t.resource.Soul_Gem.name])}
                            ${z("tech_exotic_infusion_effect2")}
                            `,action(){return!!ii($(this)[0])},flair:()=>z("tech_exotic_infusion_flair")},infusion_check:{id:"tech-infusion_check",title:z("tech_infusion_check"),desc:z("tech_infusion_check"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:2},grant:["whitehole",3],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect:()=>`
                            ${z("tech_infusion_check_effect")}
                            ${z("tech_exotic_infusion_effect2")}
                            `,action(){return!!ii($(this)[0])},flair:()=>z("tech_infusion_check_flair")},infusion_confirm:{id:"tech-infusion_confirm",title:z("tech_infusion_confirm"),desc:z("tech_infusion_confirm"),category:"stellar_engine",era:"interstellar",reqs:{whitehole:3},grant:["whitehole",4],cost:{Knowledge:()=>15e5,Soul_Gem:()=>10},effect(){let e=Gs("bigbang"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name"),r=`
                            ${z("wiki_tech_infusion_confirm_gains",[e.plasmid,e.phage,e.dark,a])}
                            `;return`
                            ${z("tech_infusion_confirm_effect")}
                            ${z("tech_exotic_infusion_effect2")}
                            ${r}`},action(){if(ri($(this)[0])){if(t.tech.whitehole>=4)return;t.tech.whitehole=4;let a=$('
                            ');return $("body").append(a),setTimeout((function(){a.addClass("burn")}),125),setTimeout((function(){a.addClass("b")}),150),setTimeout((function(){a.addClass("c")}),2e3),setTimeout((function(){!function(){switch(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"blackhole"}),qn(`extinct_${t.race.species}`),t.race.universe){case"heavy":qn("heavy");break;case"antimatter":qn("canceled");break;case"evil":qn("eviltwin");break;case"micro":qn("microbang",!0);break;case"standard":qn("whitehole")}t.space.hasOwnProperty("spaceport")&&0===t.space.spaceport.count&&qn("red_dead"),qn("squished",!0),"evil"===t.race.universe&&"angelic"===Ki[t.race.species].type&&Pn("nephilim"),t.race.junker&&"junker"===t.race.species&&Pn("the_misery"),t.race.decay&&qn("dissipated"),t.race.steelen&&Pn("steelem");let a=t.race.species,r=t.race.gods,i=t.city.calendar.orbit,s=t.city.biome,n=t.city.ptrait,c=Gs("bigbang");Sn(),t.stats.blackhole++,rn(),t.prestige.Phage.count+=c.phage,t.stats.phage+=c.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=c.plasmid,t.stats.antiplasmid+=c.plasmid):(t.prestige.Plasmid.count+=c.plasmid,t.stats.plasmid+=c.plasmid),t.prestige.Dark.count=+(t.prestige.Dark.count+c.dark).toFixed(3),t.stats.dark=+(t.stats.dark+c.dark).toFixed(3),t.stats.universes++;let o=!!t.race.hasOwnProperty("srace")&&t.race.srace,l=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,universe:"bigbang",seeded:!0,bigbang:!0,probes:4,seed:Math.floor(m(1e4)),ascended:!1},l>0&&(t.race.corruption=l),o&&(t.race.srace=o),H({orbit:i,biome:s,ptrait:n,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),4e3),!1}return!1},flair:()=>z("tech_infusion_confirm_flair")},stabilize_blackhole:{id:"tech-stabilize_blackhole",title:z("tech_stabilize_blackhole"),desc:()=>`
                            ${z("tech_stabilize_blackhole")}
                            ${z("tech_stabilize_blackhole2")}
                            `,category:"stellar_engine",era:"interstellar",reqs:{whitehole:1},grant:["stablized",1],cost:{Knowledge:()=>15e5,Neutronium:()=>2e4},effect:z("tech_stabilize_blackhole_effect"),action(){if(ri($(this)[0])){if(t.interstellar.stellar_engine.mass+=2e4*Fa.Neutronium/1e10,t.interstellar.stellar_engine.mass+=40*t.interstellar.stellar_engine.exotic,t.interstellar.stellar_engine.exotic=0,delete t.tech.whitehole,t.race.banana&&t.interstellar.stellar_engine.mass>=12){let e=xn();t.stats.banana.b3[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b3.l=!0)}return!0}return!1}},veil:{id:"tech-veil",title:z("tech_veil"),desc:z("tech_veil"),category:"magic",era:"interstellar",reqs:{blackhole:2},condition:()=>"magic"===t.race.universe,grant:["veil",1],cost:{Knowledge:()=>125e4},effect:z("tech_veil_effect"),action(){return!!ri($(this)[0])}},mana_syphon:{id:"tech-mana_syphon",title:z("tech_mana_syphon"),desc:z("tech_mana_syphon"),category:"magic",era:"interstellar",reqs:{veil:1},condition:()=>"magic"===t.race.universe,grant:["veil",2],cost:{Knowledge:()=>15e5},effect:z("tech_mana_syphon_effect"),action(){return!!ri($(this)[0])},post(){xe("Physics")}},gravitational_waves:{id:"tech-gravitational_waves",title:z("tech_gravitational_waves"),desc:z("tech_gravitational_waves"),category:"power_generation",era:"interstellar",reqs:{blackhole:4},grant:["gravity",1],cost:{Knowledge:()=>125e4},effect:z("tech_gravitational_waves_effect"),action(){return!!ri($(this)[0])}},gravity_convection:{id:"tech-gravity_convection",title:z("tech_gravity_convection"),desc:z("tech_gravity_convection"),category:"power_generation",era:"interstellar",reqs:{gravity:1},grant:["gravity",2],cost:{Knowledge:()=>135e4},effect:z("tech_gravity_convection_effect"),action(){return!!ri($(this)[0])}},wormholes:{id:"tech-wormholes",title:z("tech_wormholes"),desc:z("tech_wormholes"),category:"space_exploration",era:"intergalactic",reqs:{gravity:1,science:15},grant:["stargate",1],cost:{Knowledge:()=>225e4},effect:z("tech_wormholes_effect"),action(){return!!ri($(this)[0])}},portal:{id:"tech-portal",title:z("tech_portal"),desc:z("tech_portal_desc"),category:"hell_dimension",era:"interstellar",reqs:{wsc:1},grant:["portal",1],cost:{Knowledge:()=>5e5},effect:z("tech_portal_effect"),action(){return!!ri($(this)[0])}},fortifications:{id:"tech-fortifications",title:z("tech_fort"),desc:z("tech_fort_desc"),category:"hell_dimension",era:"interstellar",reqs:{portal:1},grant:["portal",2],cost:{Knowledge:()=>55e4,Stone:()=>1e6},effect:z("tech_fort_effect"),action(){return!!ri($(this)[0])&&(t.settings.showPortal=!0,t.settings.portal.fortress=!0,t.settings.msgFilters.hell.unlocked||(t.settings.msgFilters.hell.unlocked=!0,t.settings.msgFilters.hell.vis=!0),t.portal.fortress={threat:1e4,garrison:0,walls:100,repair:0,patrols:0,patrol_size:10,siege:999,notify:"Yes",s_ntfy:"Yes",nocrew:!1},t.portal.turret={count:0,on:0},t.portal.carport={count:0,damaged:0,repair:0},"demonic"===Ki[t.race.species].type?qn("blood_war"):qn("pandemonium"),t.portal.observe={settings:{expanded:!1,average:!1,hyperSlow:!1,display:"game_days",dropKills:!0,dropGems:!0},stats:{total:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}},period:{start:{year:t.city.calendar.year,day:t.city.calendar.day},days:0,wounded:0,died:0,revived:0,surveyors:0,sieges:0,kills:{drones:0,patrols:0,sieges:0,guns:0,soul_forge:0,turrets:0},gems:{patrols:0,guns:0,soul_forge:0,crafted:0,turrets:0,surveyors:0}}},graphID:0,graphs:{}},!0)},post(){Pa()}},war_drones:{id:"tech-war_drones",title:z("tech_war_drones"),desc:z("tech_war_drones"),category:"hell_dimension",era:"interstellar",reqs:{portal:2,graphene:1},grant:["portal",3],cost:{Knowledge:()=>7e5},effect:z("tech_war_drones_effect"),action(){return!!ri($(this)[0])&&(t.settings.portal.badlands=!0,t.portal.war_drone={count:0,on:0},!0)}},demon_attractor:{id:"tech-demon_attractor",title:z("tech_demon_attractor"),desc:z("tech_demon_attractor"),category:"hell_dimension",era:"interstellar",reqs:{portal:3,stanene:1},grant:["portal",4],cost:{Knowledge:()=>745e3},effect:z("tech_demon_attractor_effect"),action(){return!!ri($(this)[0])&&(t.portal.attractor={count:0,on:0},!0)}},combat_droids:{id:"tech-combat_droids",title:z("tech_combat_droids"),desc:z("tech_combat_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:4},grant:["portal",5],cost:{Knowledge:()=>762e3,Soul_Gem:()=>1},effect:z("tech_combat_droids_effect"),action(){return!!ri($(this)[0])&&(t.portal.war_droid={count:0,on:0},!0)},flair:()=>z("tech_combat_droids_flair")},repair_droids:{id:"tech-repair_droids",title:z("tech_repair_droids"),desc:z("tech_repair_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:5},grant:["portal",6],cost:{Knowledge:()=>794e3,Soul_Gem:()=>1},effect:z("tech_repair_droids_effect"),action(){return!!ri($(this)[0])&&(t.portal.repair_droid={count:0,on:0},!0)}},advanced_predators:{id:"tech-advanced_predators",title:z("tech_advanced_predators"),desc:z("tech_advanced_predators"),category:"hell_dimension",era:"intergalactic",reqs:{portal:6,xeno:4},grant:["portal",7],cost:{Knowledge:()=>5e6,Bolognium:()=>5e5,Vitreloy:()=>25e4},effect:z("tech_advanced_predators_effect"),action(){return!!ri($(this)[0])}},enhanced_droids:{id:"tech-enhanced_droids",title:z("tech_enhanced_droids"),desc:z("tech_enhanced_droids"),category:"hell_dimension",era:"interstellar",reqs:{portal:5,military:9},grant:["hdroid",1],cost:{Knowledge:()=>105e4},effect:z("tech_enhanced_droids_effect"),action(){return!!ri($(this)[0])}},sensor_drone:{id:"tech-sensor_drone",title:z("tech_sensor_drone"),desc:z("tech_sensor_drone"),category:"hell_dimension",era:"interstellar",reqs:{portal:3,infernite:1,stanene:1,graphene:1},grant:["infernite",2],cost:{Knowledge:()=>725e3},effect:z("tech_sensor_drone_effect"),action(){return!!ri($(this)[0])&&(t.portal.sensor_drone={count:0,on:0},!0)}},map_terrain:{id:"tech-map_terrain",title:z("tech_map_terrain"),desc:z("tech_map_terrain"),category:"hell_dimension",era:"interstellar",reqs:{infernite:2},grant:["infernite",3],cost:{Knowledge:()=>948e3},effect:()=>z("tech_map_terrain_effect"),action(){return!!ri($(this)[0])}},calibrated_sensors:{id:"tech-calibrated_sensors",title:z("tech_calibrated_sensors"),desc:z("tech_calibrated_sensors"),category:"hell_dimension",era:"interstellar",reqs:{infernite:3},grant:["infernite",4],cost:{Knowledge:()=>1125e3,Infernite:()=>3500},effect:()=>z("tech_calibrated_sensors_effect"),action(){return!!ri($(this)[0])}},shield_generator:{id:"tech-shield_generator",title:z("tech_shield_generator"),desc:z("tech_shield_generator"),category:"hell_dimension",era:"intergalactic",reqs:{high_tech:14,gateway:3,infernite:4},grant:["infernite",5],cost:{Knowledge:()=>268e4,Bolognium:()=>75e3},effect:()=>z("tech_shield_generator_effect"),action(){return!!ri($(this)[0])}},enhanced_sensors:{id:"tech-enhanced_sensors",title:z("tech_enhanced_sensors"),desc:z("tech_enhanced_sensors"),category:"hell_dimension",era:"intergalactic",reqs:{infernite:5,xeno:4},grant:["infernite",6],cost:{Knowledge:()=>475e4,Vitreloy:()=>25e3},effect:()=>z("tech_enhanced_sensors_effect"),action(){return!!ri($(this)[0])}},xeno_linguistics:{id:"tech-xeno_linguistics",title:z("tech_xeno_linguistics"),desc:z("tech_xeno_linguistics"),category:"andromeda",era:"intergalactic",reqs:{xeno:1},grant:["xeno",2],cost:{Knowledge:()=>3e6},effect:()=>z("tech_xeno_linguistics_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.gorddon=!0,!0)}},xeno_culture:{id:"tech-xeno_culture",title:z("tech_xeno_culture"),desc:z("tech_xeno_culture"),category:"progress",era:"intergalactic",reqs:{xeno:3},grant:["xeno",4],cost:{Knowledge:()=>34e5},effect:()=>z("tech_xeno_culture_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name,Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].entity]),action(){return!!ri($(this)[0])&&(t.galaxy.embassy={count:0,on:0},!0)}},cultural_exchange:{id:"tech-cultural_exchange",title:z("tech_cultural_exchange"),desc:z("tech_cultural_exchange"),category:"andromeda",era:"intergalactic",reqs:{xeno:5},grant:["xeno",6],cost:{Knowledge:()=>355e4},effect:()=>z("tech_cultural_exchange_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!ri($(this)[0])&&(t.galaxy.symposium={count:0,on:0},t.galaxy.dormitory={count:0,on:0},!0)}},shore_leave:{id:"tech-shore_leave",title:z("tech_shore_leave"),desc:z("tech_shore_leave"),category:"science",era:"intergalactic",reqs:{andromeda:3,xeno:6},grant:["xeno",7],cost:{Knowledge:()=>46e5},effect:()=>z("tech_shore_leave_effect"),action(){return!!ri($(this)[0])}},xeno_gift:{id:"tech-xeno_gift",title:z("tech_xeno_gift"),desc:z("tech_xeno_gift"),category:"andromeda",era:"intergalactic",reqs:{high_tech:16,xeno:7},grant:["xeno",8],cost:{Knowledge:()=>65e5,Infernite:()=>125e3},effect:()=>z("tech_xeno_gift_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.consulate={count:0},t.settings.space.alien1=!0,hs(z("tech_xeno_gift_msg",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),"info",!1,["progress"]),!0)}},industrial_partnership:{id:"tech-industrial_partnership",title:z("tech_industrial_partnership"),desc:()=>z("tech_industrial_partnership"),category:"andromeda",era:"intergalactic",reqs:{xeno:9},grant:["xeno",10],cost:{Knowledge:()=>725e4},effect:()=>z("tech_industrial_partnership_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!ri($(this)[0])&&(t.galaxy.vitreloy_plant={count:0,on:0},!0)}},embassy_housing:{id:"tech-embassy_housing",title:z("tech_embassy_housing"),desc:()=>z("tech_embassy_housing"),category:"andromeda",era:"intergalactic",reqs:{xeno:10,science:18},grant:["xeno",11],cost:{Knowledge:()=>1075e4},effect:()=>z("tech_embassy_housing_effect",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].name]),action(){return!!ri($(this)[0])}},advanced_telemetry:{id:"tech-advanced_telemetry",title:z("tech_advanced_telemetry"),desc:z("tech_advanced_telemetry"),category:"science",era:"intergalactic",reqs:{xeno:5},grant:["telemetry",1],cost:{Knowledge:()=>42e5,Vitreloy:()=>1e4},effect:()=>z("tech_advanced_telemetry_effect"),action(){return!!ri($(this)[0])}},defense_platform:{id:"tech-defense_platform",title:z("galaxy_defense_platform"),desc:z("galaxy_defense_platform"),category:"andromeda",era:"intergalactic",reqs:{stargate:5,piracy:1},grant:["stargate",6],cost:{Knowledge:()=>485e4},effect:z("tech_defense_platform_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.defense_platform={count:0,on:0},!0)}},scout_ship:{id:"tech-scout_ship",title:z("galaxy_scout_ship"),desc:z("galaxy_scout_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{gateway:3},grant:["andromeda",1],cost:{Knowledge:()=>26e5},effect:()=>z("tech_scout_ship_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.scout_ship={count:0,on:0,crew:0,mil:0},!0)}},corvette_ship:{id:"tech-corvette_ship",title:z("galaxy_corvette_ship"),desc:z("galaxy_corvette_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:1,xeno:1},grant:["andromeda",2],cost:{Knowledge:()=>32e5},effect:()=>z("tech_corvette_ship_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.corvette_ship={count:0,on:0,crew:0,mil:0},!0)}},frigate_ship:{id:"tech-frigate_ship",title:z("galaxy_frigate_ship"),desc:z("galaxy_frigate_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:2,xeno:6},grant:["andromeda",3],cost:{Knowledge:()=>4e6},effect:()=>z("tech_frigate_ship_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.frigate_ship={count:0,on:0,crew:0,mil:0},Lt(),!0)}},cruiser_ship:{id:"tech-cruiser_ship",title:z("galaxy_cruiser_ship"),desc:z("galaxy_cruiser_ship"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:3,xeno:10},grant:["andromeda",4],cost:{Knowledge:()=>75e5},effect:()=>z("tech_cruiser_ship_effect",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),action(){return!!ri($(this)[0])&&(t.galaxy.cruiser_ship={count:0,on:0,crew:0,mil:0},t.galaxy.foothold={count:0,on:0,support:0,s_max:0},t.settings.space.alien2=!0,Lt(),!0)}},dreadnought:{id:"tech-dreadnought",title:z("galaxy_dreadnought"),desc:z("galaxy_dreadnought"),category:"andromeda_ships",era:"intergalactic",reqs:{andromeda:4,science:18},grant:["andromeda",5],cost:{Knowledge:()=>1e7},effect:()=>z("tech_dreadnought_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.dreadnought={count:0,on:0,crew:0,mil:0},Lt(),!0)}},ship_dock:{id:"tech-ship_dock",title:z("galaxy_ship_dock"),desc:z("galaxy_ship_dock"),category:"andromeda_ships",era:"intergalactic",reqs:{gateway:3,xeno:6},grant:["gateway",4],cost:{Knowledge:()=>39e5},effect:()=>z("tech_ship_dock_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.ship_dock={count:0,on:0},!0)}},ore_processor:{id:"tech-ore_processor",title:z("galaxy_ore_processor"),desc:z("galaxy_ore_processor"),category:"space_mining",era:"intergalactic",reqs:{conflict:2},grant:["conflict",3],cost:{Knowledge:()=>75e5},effect:()=>z("tech_ore_processor_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.ore_processor={count:0,on:0},!0)}},scavenger:{id:"tech-scavenger",title:z("galaxy_scavenger"),desc:z("galaxy_scavenger"),category:"science",era:"intergalactic",reqs:{conflict:3},grant:["conflict",4],cost:{Knowledge:()=>8e6},effect:()=>z("tech_scavenger_effect",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),action(){return!!ri($(this)[0])&&(t.galaxy.scavenger={count:0,on:0,crew:0},!0)}},coordinates:{id:"tech-coordinates",title:z("tech_coordinates"),desc:z("tech_coordinates"),category:"andromeda",era:"intergalactic",reqs:{science:18,conflict:5},grant:["chthonian",1],cost:{Knowledge:()=>1e7},effect:()=>z("tech_coordinates_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.minelayer={count:0,on:0,crew:0,mil:0},t.settings.space.chthonian=!0,!0)}},chthonian_survey:{id:"tech-chthonian_survey",title:z("tech_chthonian_survey"),desc:z("tech_chthonian_survey"),category:"space_mining",era:"intergalactic",reqs:{chthonian:2},grant:["chthonian",3],cost:{Knowledge:()=>118e5},effect:()=>z("tech_chthonian_survey_effect"),action(){return!!ri($(this)[0])&&(t.resource.Orichalcum.display=!0,t.galaxy.excavator={count:0,on:0},t.galaxy.raider={count:0,on:0,crew:0,mil:0},hs(z("tech_chthonian_survey_result"),"info",!1,["progress"]),!0)},post(){cs()}},gateway_depot:{id:"tech-gateway_depot",title:z("galaxy_gateway_depot"),desc:z("galaxy_gateway_depot"),category:"storage",era:"intergalactic",reqs:{gateway:4},grant:["gateway",5],cost:{Knowledge:()=>435e4},effect:()=>z("tech_gateway_depot_effect"),action(){return!!ri($(this)[0])&&(t.galaxy.gateway_depot={count:0,on:0},!0)}},soul_forge:{id:"tech-soul_forge",title:z("portal_soul_forge_title"),desc:z("portal_soul_forge_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:3},grant:["hell_pit",4],cost:{Knowledge:()=>275e4},effect:()=>z("tech_soul_forge_effect"),action(){return!!ri($(this)[0])&&(t.portal.soul_forge={count:0,on:0,kills:0},!0)}},soul_attractor:{id:"tech-soul_attractor",title:z("portal_soul_attractor_title"),desc:z("portal_soul_attractor_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:4,high_tech:16},grant:["hell_pit",5],cost:{Knowledge:()=>55e5},effect:()=>z("tech_soul_attractor_effect"),action(){return!!ri($(this)[0])&&(t.portal.soul_attractor={count:0,on:0},!0)}},soul_absorption:{id:"tech-soul_absorption",title:z("tech_soul_absorption"),desc:z("tech_soul_absorption"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:5},grant:["hell_pit",6],cost:{Knowledge:()=>6e6,Infernite:()=>25e4},effect:()=>z("tech_soul_absorption_effect"),action(){return!!ri($(this)[0])}},soul_link:{id:"tech-soul_link",title:z("tech_soul_link"),desc:z("tech_soul_link"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:6},grant:["hell_pit",7],cost:{Knowledge:()=>75e5,Vitreloy:()=>25e4},effect:()=>z("tech_soul_link_effect"),action(){return!!ri($(this)[0])}},gun_emplacement:{id:"tech-gun_emplacement",title:z("portal_gun_emplacement_title"),desc:z("portal_gun_emplacement_title"),category:"hell_dimension",era:"intergalactic",reqs:{hell_pit:4},grant:["hell_gun",1],cost:{Knowledge:()=>3e6},effect:()=>z("tech_gun_emplacement_effect"),action(){return!!ri($(this)[0])&&(t.portal.gun_emplacement={count:0,on:0},!0)}},advanced_emplacement:{id:"tech-advanced_emplacement",title:z("tech_advanced_emplacement"),desc:z("tech_advanced_emplacement"),category:"hell_dimension",era:"intergalactic",reqs:{hell_gun:1,high_tech:17},grant:["hell_gun",2],cost:{Knowledge:()=>125e5,Orichalcum:()=>18e4},effect:()=>z("tech_advanced_emplacement_effect"),action(){return!!ri($(this)[0])}},dial_it_to_11:{id:"tech-dial_it_to_11",title:z("tech_dial_it_to_11"),desc:z("tech_dial_it_to_11"),category:"science",wiki:!1,era:"deep_space",reqs:{quaked:1},grant:["quaked",2],cost:{Knowledge:()=>5e5},condition:()=>!(t.race.sludge&&!t.race.cataclysm),effect(){let e=Gs("cataclysm"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                            ${z("tech_dial_it_to_11_effect",[Ut().dwarf,t.race.cataclysm?Ut().red:Ki[t.race.species].home])}
                            ${z("tech_dial_it_to_11_effect2")}
                            ${z("star_dock_genesis_effect2",[e.plasmid,a])}
                            ${z("star_dock_genesis_effect3",[e.phage])}
                            `},action(){return!!ri($(this)[0])&&($("#main").addClass("earthquake"),setTimeout((function(){$("#main").removeClass("earthquake"),function(){if(t.city.ptrait.includes("unstable")&&t.tech.quaked){P.w&&P.w.terminate(),t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),ks("reset",{end:"cataclysm"}),O();let a=Gs("cataclysm");t.stats.cataclysm++,rn(),t.prestige.Phage.count+=a.phage,t.stats.phage+=a.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=a.plasmid,t.stats.antiplasmid+=a.plasmid):(t.prestige.Plasmid.count+=a.plasmid,t.stats.plasmid+=a.plasmid),qn("squished",!0),qn(`extinct_${t.race.species}`),"hellscape"===t.city.biome&&"demonic"!==Ki[t.race.species].type&&Pn("take_no_advice"),Sn(),qn("shaken"),t.race.cataclysm&&qn("failed_history");let r=!!t.race.hasOwnProperty("srace")&&t.race.srace,i=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:t.race.species,gods:t.race.gods,old_gods:t.race.old_gods,universe:t.race.universe,seeded:!1,ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},i>0&&(t.race.corruption=i),r&&(t.race.srace=r),H({orbit:t.city.calendar.orbit,biome:t.city.biome,ptrait:t.city.ptrait,geology:t.city.geology}),"antimatter"===t.race.universe?t.race.weak_mastery=1:t.race.no_plasmid=1;let s=["crispr","trade","craft"];for(let e=0;ez("tech_dial_it_to_11_flair")},limit_collider:{id:"tech-limit_collider",title:z("tech_limit_collider"),desc:z("tech_limit_collider"),category:"science",wiki:!1,era:"deep_space",reqs:{quaked:1},grant:["quaked",2],cost:{Knowledge:()=>5e5},effect:()=>z("tech_limit_collider_effect"),action(){return!!ri($(this)[0])}},mana:{id:"tech-mana",title:z("tech_mana"),desc:z("tech_mana"),category:"magic",era:"civilized",reqs:{primitive:3},grant:["magic",1],condition:()=>"magic"===t.race.universe,cost:{Knowledge:()=>25},effect:()=>z("tech_mana_effect"),action(){return!!ri($(this)[0])&&(t.resource.Mana.display=!0,t.resource.Crystal.display=!0,t.civic.crystal_miner.display=!0,t.race.witch_hunter&&(t.resource.Sus.display=!0),!0)},flair:z("tech_mana_flair"),post(){cs()}},ley_lines:{id:"tech-ley_lines",title:z("tech_ley_lines"),desc:z("tech_ley_lines"),category:"magic",era:"civilized",reqs:{magic:1},grant:["magic",2],condition:()=>"magic"===t.race.universe,cost:{Knowledge:()=>40},effect:()=>z("tech_ley_lines_effect"),action(){return!!ri($(this)[0])&&(t.tech.isolation?t.tauceti.pylon={count:0}:t.race.cataclysm||t.race.orbit_decayed?t.space.pylon={count:0}:t.city.pylon={count:0},!0)}},rituals:{id:"tech-rituals",title:z("tech_rituals"),desc:z("tech_rituals"),category:"magic",era:"civilized",reqs:{magic:2},grant:["magic",3],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>25,Knowledge:()=>750,Crystal:()=>50},effect:()=>z("tech_rituals_effect"),action(){return!!ri($(this)[0])&&(t.race.casting={farmer:0,miner:0,lumberjack:0,science:0,factory:0,army:0,hunting:0,crafting:0,total:0},t.settings.showIndustry=!0,!0)},post(){ki()}},crafting_ritual:{id:"tech-crafting_ritual",title:z("tech_crafting_ritual"),desc:z("tech_crafting_ritual"),category:"magic",era:"discovery",reqs:{magic:3,foundry:5},grant:["magic",4],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>100,Knowledge:()=>15e3,Crystal:()=>2500},effect:()=>z("tech_crafting_ritual_effect"),action(){return!!ri($(this)[0])&&(t.race.casting.crafting=0,!0)},post(){ki()}},mana_nexus:{id:"tech-mana_nexus",title:z("tech_mana_nexus"),desc:z("tech_mana_nexus"),category:"magic",era:"early_space",reqs:{magic:4,space:3,luna:1},grant:["magic",5],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>500,Knowledge:()=>16e4,Crystal:()=>2500},effect:()=>z("tech_mana_nexus_effect"),action(){return!!ri($(this)[0])},post(){xe("Physics")}},clerics:{id:"tech-clerics",title:z("tech_clerics"),desc:z("tech_clerics"),category:"magic",era:"civilized",reqs:{magic:3},grant:["cleric",1],condition:()=>!!("magic"===t.race.universe&&t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display),cost:{Mana:()=>100,Knowledge:()=>2e3,Crystal:()=>100},effect:()=>z("tech_clerics_effect"),action(){return!!ri($(this)[0])}},conjuring:{id:"tech-conjuring",title:z("tech_conjuring"),desc:z("tech_conjuring_desc"),category:"magic",era:"civilized",reqs:{magic:1},grant:["conjuring",1],not_trait:["cataclysm"],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>2,Crystal:()=>5},effect:()=>z("tech_conjuring_effect"),action(){return!!ri($(this)[0])}},res_conjuring:{id:"tech-res_conjuring",title:z("tech_res_conjuring"),desc:z("tech_res_conjuring"),category:"magic",era:"civilized",reqs:{conjuring:1},grant:["conjuring",2],not_trait:["cataclysm"],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>5,Crystal:()=>10},effect:()=>z("tech_res_conjuring_effect"),action(){return!!ri($(this)[0])}},alchemy:{id:"tech-alchemy",title:z("tech_alchemy"),desc:z("tech_alchemy"),category:"magic",era:"discovery",reqs:{magic:3,high_tech:1},grant:["alchemy",1],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>100,Knowledge:()=>1e4,Crystal:()=>250},effect:()=>z("tech_alchemy_effect"),action(){return!!ri($(this)[0])&&(t.race.alchemy={Food:0,Lumber:0,Stone:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Deuterium:0,Neutronium:0,Adamantite:0,Infernite:0,Elerium:0,Nano_Tube:0,Graphene:0,Stanene:0,Bolognium:0,Vitreloy:0,Orichalcum:0},t.settings.showAlchemy=!0,!0)},post(){Ss($("#resources")),Da(),t.settings.tabLoad&&Ka("alchemy")}},transmutation:{id:"tech-transmutation",title:z("tech_transmutation"),desc:z("tech_transmutation"),category:"magic",era:"intergalactic",reqs:{alchemy:1,high_tech:16},grant:["alchemy",2],condition:()=>"magic"===t.race.universe,cost:{Mana:()=>1250,Knowledge:()=>55e5,Crystal:()=>1e6},effect:()=>z("tech_transmutation_effect"),action(){return!!ri($(this)[0])},post(){Ss($("#resources")),Da()}},secret_society:{id:"tech-secret_society",title:z("tech_secret_society"),desc:z("tech_secret_society"),category:"magic",era:"civilized",reqs:{magic:1},grant:["roguemagic",1],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>10,Knowledge:()=>45},effect:()=>z("tech_secret_society_effect"),action(){return!!ri($(this)[0])}},cultists:{id:"tech-cultists",title:z("tech_cultists"),desc:z("tech_cultists"),category:"magic",era:"civilized",reqs:{roguemagic:1,cleric:1},grant:["roguemagic",2],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>250,Knowledge:()=>2125},effect:()=>z("tech_cultists_effect"),action(){return!!ri($(this)[0])}},conceal_ward:{id:"tech-conceal_ward",title:z("tech_conceal_ward"),desc:z("tech_conceal_ward"),category:"magic",era:"discovery",reqs:{roguemagic:2,theatre:3},grant:["roguemagic",3],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>500,Knowledge:()=>8200,Crystal:()=>1e3},effect:()=>z("tech_conceal_ward_effect"),action(){return!!ri($(this)[0])&&(t.city.conceal_ward={count:0},t.space.conceal_ward={count:0},!0)}},subtle_rituals:{id:"tech-subtle_rituals",title:z("tech_subtle_rituals"),desc:z("tech_subtle_rituals"),category:"magic",era:"discovery",reqs:{roguemagic:3,magic:4},grant:["roguemagic",4],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>100,Knowledge:()=>15e3,Crystal:()=>2500},effect:()=>z("tech_subtle_rituals_effect"),action(){return!!ri($(this)[0])}},pylon_camouflage:{id:"tech-pylon_camouflage",title:z("tech_pylon_camouflage"),desc:z("tech_pylon_camouflage"),category:"magic",era:"industrialized",reqs:{roguemagic:4,high_tech:3},grant:["roguemagic",5],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>1e3,Knowledge:()=>3e4,Crystal:()=>3750},effect:()=>z("tech_pylon_camouflage_effect"),action(){return!!ri($(this)[0])}},fake_tech:{id:"tech-fake_tech",title:z("tech_fake_tech"),desc:z("tech_fake_tech"),category:"magic",era:"industrialized",reqs:{roguemagic:5,high_tech:4},grant:["roguemagic",6],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>2250,Knowledge:()=>6e4},effect:()=>z("tech_fake_tech_effect"),action(){return!!ri($(this)[0])}},concealment:{id:"tech-concealment",title:z("tech_concealment"),desc:z("tech_concealment"),category:"magic",era:"early_space",reqs:{roguemagic:6,magic:5},grant:["roguemagic",7],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>3e3,Knowledge:()=>185e3},effect:()=>z("tech_concealment_effect"),action(){return!!ri($(this)[0])}},improved_concealment:{id:"tech-improved_concealment",title:z("tech_improved_concealment"),desc:z("tech_improved_concealment"),category:"magic",era:"intergalactic",reqs:{roguemagic:7,forbidden:1},grant:["roguemagic",8],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>t.race.no_plasmid?6e3:25e3,Knowledge:()=>2e7},effect:()=>z("tech_improved_concealment_effect"),action(){return!!ri($(this)[0])}},outerplane_summon:{id:"tech-outerplane_summon",title:z("tech_outerplane_summon"),desc:z("tech_outerplane_summon"),category:"magic",era:"dimensional",reqs:{roguemagic:8,forbidden:4,hell_spire:10,b_stone:2,waygate:3},grant:["forbidden",5],condition:()=>!("magic"!==t.race.universe||!t.race.witch_hunter),cost:{Mana:()=>t.race.no_plasmid?12e3:6e4,Knowledge:()=>6e7,Demonic_Essence:()=>1},effect:()=>z("tech_outerplane_summon_effect"),action(){return!!ri($(this)[0])}},dark_bomb:{id:"tech-dark_bomb",title:z("tech_dark_bomb"),desc:z("tech_dark_bomb"),category:"hell_dimension",era:"dimensional",reqs:{},reqs:{hell_spire:10,b_stone:2,waygate:2,sphinx_bribe:1},condition(){let e=xn();return!!(t.stats.spire.hasOwnProperty(e)&&t.stats.spire[e].hasOwnProperty("dlstr")&&t.stats.spire[e].dlstr>0)},grant:["dl_reset",1],cost:{Knowledge:()=>65e6,Soul_Gem:()=>5e3,Blood_Stone:()=>25,Dark:()=>1,Supply:()=>1e6},effect:()=>z("tech_dark_bomb_effect"),action(){return!!ri($(this)[0])&&(t.portal.waygate.progress=100,t.portal.waygate.on=0,t.tech.waygate=3,t.resource.Demonic_Essence.display=!0,t.resource.Demonic_Essence.amount=1,!0)},flair:()=>z("tech_dark_bomb_flair")},bribe_sphinx:{id:"tech-bribe_sphinx",title:z("portal_sphinx_bribe"),desc:z("portal_sphinx_bribe"),category:"hell_dimension",era:"dimensional",reqs:{hell_spire:8},grant:["sphinx_bribe",1],cost:{Soul_Gem:()=>250,Supply:()=>5e5},effect:()=>z("tech_bribe_sphinx_effect"),action(){return!!ri($(this)[0])&&(t.resource.Codex.display=!0,t.resource.Codex.amount=1,hs(z("tech_bribe_sphinx_msg"),"info",!1,["progress","hell"]),!0)}},alien_biotech:{id:"tech-alien_biotech",title:z("tech_alien_biotech"),desc:z("tech_alien_biotech"),category:"science",era:"solar",reqs:{genetics:8,kuiper:1},grant:["biotech",1],path:["truepath"],cost:{Knowledge:()=>24e5,Orichalcum:()=>125e3,Cipher:()=>15e3},effect:()=>z(t.race.orbit_decayed?"tech_alien_biotech_effect_alt":"tech_alien_biotech_effect"),action(){return!!ri($(this)[0])}},zero_g_lab:{id:"tech-zero_g_lab",title:z("tech_zero_g_lab"),desc:z("tech_zero_g_lab"),category:"science",era:"solar",path:["truepath"],reqs:{high_tech:13,graphene:1,enceladus:2},grant:["enceladus",3],cost:{Knowledge:()=>9e5},effect:z("tech_zero_g_lab_effect"),action(){return!!ri($(this)[0])&&(t.space.zero_g_lab={count:0,on:0},!0)}},operating_base:{id:"tech-operating_base",title:z("tech_operating_base"),desc:z("tech_operating_base"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{enceladus:3,triton:1},grant:["enceladus",4],cost:{Knowledge:()=>14e5},effect:()=>z("tech_operating_base_effect",[Ut().enceladus]),action(){return!!ri($(this)[0])&&(t.space.operating_base={count:0,on:0},!0)}},munitions_depot:{id:"tech-munitions_depot",title:z("tech_munitions_depot"),desc:z("tech_munitions_depot"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{enceladus:4},grant:["enceladus",5],cost:{Knowledge:()=>15e5},effect:()=>z("tech_munitions_depot_effect"),action(){return!!ri($(this)[0])&&(t.space.munitions_depot={count:0},!0)}},fob:{id:"tech-fob",title:z("tech_fob"),desc:z("tech_fob"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{triton:1},grant:["triton",2],cost:{Knowledge:()=>145e4},effect:()=>z("tech_fob_effect",[Ut().triton]),action(){return!!ri($(this)[0])&&(t.space.fob={count:0,on:0,troops:0,enemy:0},t.space.lander={count:0,on:0},t.space.crashed_ship={count:0},!0)}},bac_tanks_tp:{id:"tech-bac_tanks_tp",title:z("tech_bac_tanks"),desc:z("tech_bac_tanks_desc"),category:"military",era:"solar",path:["truepath"],reqs:{medic:1,triton:2},grant:["medic",2],cost:{Knowledge:()=>175e4},effect:z("tech_bac_tanks_effect"),action(){return!!ri($(this)[0])}},medkit:{id:"tech-medkit",title:z("tech_medkit"),desc:z("tech_medkit"),category:"military",era:"solar",path:["truepath"],reqs:{medic:2,outer:4},grant:["medic",3],cost:{Knowledge:()=>225e4,Quantium:()=>25e4,Cipher:()=>8e3},effect:z("tech_medkit_effect"),action(){return!!ri($(this)[0])}},sam_site:{id:"tech-sam_site",title:z("tech_sam_site"),desc:z("tech_sam_site"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{titan:6,triton:1},grant:["titan",7],cost:{Knowledge:()=>1475e3},effect:()=>z("tech_sam_site_effect",[Ut().titan]),action(){return!!ri($(this)[0])&&(t.space.sam={count:0,on:0},!0)}},data_cracker:{id:"tech-data_cracker",title:z("tech_data_cracker"),desc:z("tech_data_cracker"),category:"science",era:"solar",path:["truepath"],reqs:{titan:7,kuiper:1},grant:["titan",8],cost:{Knowledge:()=>275e4,Cipher:()=>25e3},effect:()=>z("tech_data_cracker_effect",[t.resource.Cipher.name]),action(){return!!ri($(this)[0])&&(t.space.decoder={count:0,on:0},!0)}},ai_core_tp:{id:"tech-ai_core_tp",title:z("tech_ai_core"),desc:z("tech_ai_core"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan:8},grant:["titan",9],cost:{Knowledge:()=>3e6,Cipher:()=>1e5},effect:z("tech_ai_core_effect"),action(){return!!ri($(this)[0])&&(t.space.ai_core={count:0},!0)}},ai_optimizations:{id:"tech-ai_optimizations",title:z("tech_ai_optimizations"),desc:z("tech_ai_optimizations"),category:"ai_core",era:"solar",path:["truepath"],reqs:{eris:3,titan:9,titan_ai_core:1,dig_control:1},grant:["titan_ai_core",2],cost:{Knowledge:()=>375e4,Cipher:()=>75e3},effect:z("tech_ai_optimizations_effect"),action(){return!!ri($(this)[0])},class:"synth"},synthetic_life:{id:"tech-synthetic_life",title:z("tech_synthetic_life"),desc:z("tech_synthetic_life"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:2},grant:["titan_ai_core",3],cost:{Knowledge:()=>4e6,Cipher:()=>75e3},effect:z("tech_synthetic_life_effect"),action(){return!!ri($(this)[0])&&(t.space.ai_colonist={count:0,on:0},!0)},class:"synth"},protocol66:{id:"tech-protocol66",title:z("tech_protocol66"),desc:z("tech_protocol66"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:3,corrupted_ai:1},grant:["corrupted_ai",2],cost:{Knowledge:()=>5e6},effect:z("tech_protocol66_effect"),action(){return!!ii($(this)[0])},flair:z("tech_protocol66_flair"),class:"synth"},protocol66a:{id:"tech-protocol66a",title:z("tech_protocol66"),desc:z("tech_protocol66"),category:"ai_core",era:"solar",path:["truepath"],reqs:{titan_ai_core:3,corrupted_ai:2},wiki:!1,grant:["corrupted_ai",3],cost:{Knowledge:()=>5e6},effect(){let e=Gs("ai"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name"),r=`
                            ${z("tech_protocol66a_effect_gains",[e.plasmid,a,e.phage,e.cores])}
                            `;return`
                            ${z("tech_protocol66a_effect")}
                            ${r}`},action(){return!!ri($(this)[0])&&(P.w&&P.w.terminate(),_s(),$("body").append('
                            '),$("#aiAppoc").addClass("noise-wrapper"),$("#aiAppoc > div").addClass("noise"),setTimeout((function(){$("body").append('
                            '),$("body").append('
                            '),$("#deadAirTop").animate({height:"50%",opacity:1},400),$("#deadAirBottom").animate({height:"50%",opacity:1},400)}),3e3),setTimeout((function(){!function(){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"ai apocalypse"}),qn(`extinct_${t.race.species}`),qn("obsolete"),qn("squished",!0),t.race.junker&&"junker"===t.race.species&&Pn("the_misery");let a=t.race.species,r=t.race.gods,i=t.city.calendar.orbit,s=t.city.biome,n=t.city.ptrait,c=t.city.geology,o=Gs("ai");Sn(),t.stats.aiappoc++,rn(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),t.prestige.AICore.count+=o.cores,t.stats.cores+=o.cores;let l="synthetic"!==Ki[a].type?a:t.race.hasOwnProperty("srace")?t.race.srace:a;t.stats.synth[l]=!0;let _=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0;t.race={species:"protoplasm",gods:a,old_gods:r,srace:l,universe:t.race.universe,seeded:!1,seed:Math.floor(m(1e4)),ascended:!!t.race.hasOwnProperty("ascended")&&t.race.ascended},_>0&&(t.race.corruption=_),H({orbit:i,biome:s,ptrait:n,geology:c}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}()}),4e3),!0)},flair:z("tech_protocol66a_flair"),class:"synth"},terraforming_tp:{id:"tech-terraforming_tp",title:z("tech_terraforming"),desc:z("tech_terraforming"),category:"special",era:"solar",reqs:{dig_control:1,eris:2,titan_ai_core:2},path:["truepath"],grant:["terraforming",1],trait:["orbit_decay"],cost:{Knowledge:()=>5e6},effect:()=>z("tech_terraforming_effect",[Ut().red]),action(){return!!ri($(this)[0])&&(t.space.terraformer={count:0},!0)}},quantium:{id:"tech-quantium",title:z("tech_quantium"),desc:z("tech_quantium"),category:"crafting",era:"solar",path:["truepath"],reqs:{supercollider:10,enceladus:3},grant:["quantium",1],cost:{Knowledge:()=>1e6,Elerium:()=>1e3,Nano_Tube:()=>1e6,Graphene:()=>1e6},effect:z("tech_quantium_effect"),action(){return!!ri($(this)[0])&&(t.resource.Quantium.display=!0,!0)},post(){cs()}},anitgrav_bunk:{id:"tech-anitgrav_bunk",title:z("tech_anitgrav_bunk"),desc:z("tech_anitgrav_bunk"),category:"military",era:"solar",path:["truepath"],reqs:{marines:1,quantium:1},grant:["marines",2],cost:{Knowledge:()=>125e4,Quantium:()=>5e5},effect:()=>z("tech_anitgrav_bunk_effect",[z("space_red_space_barracks_title")]),action(){return!!ri($(this)[0])}},higgs_boson_tp:{id:"tech-higgs_boson_tp",title:z("tech_higgs_boson"),desc:z("tech_higgs_boson"),category:"science",era:"early_space",path:["truepath"],reqs:{supercollider:2},grant:["tp_particles",1],cost:{Knowledge:()=>125e3},effect:z("tech_higgs_boson_effect"),action(){return!!ri($(this)[0])}},long_range_probes:{id:"tech-long_range_probes",title:z("tech_long_range_probes"),desc:z("tech_long_range_probes"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{high_tech:10,elerium:1},grant:["outer",1],cost:{Knowledge:()=>4e5,Uranium:()=>2e4,Iridium:()=>25e4,Neutronium:()=>3e3,Elerium:()=>350},effect:z("tech_long_range_probes_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.titan=!0,t.settings.space.enceladus=!0,t.space.titan_spaceport={count:0,on:0,support:0,s_max:0},t.space.electrolysis={count:0,on:0,support:0,s_max:0},!0)}},strange_signal:{id:"tech-strange_signal",title:z("tech_strange_signal"),desc:z("tech_strange_signal"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:1,syard_sensor:4},grant:["outer",2],cost:{Knowledge:()=>135e4},effect:z("tech_strange_signal_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.triton=!0,!0)}},data_analysis:{id:"tech-data_analysis",title:z("tech_data_analysis"),desc:z("tech_data_analysis"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:3},grant:["outer",4],cost:{Knowledge:()=>18e5,Cipher:()=>12500},effect:z("tech_data_analysis_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_data_analysis_result"),"info",!1,["progress"]),t.space.syndicate.spc_titan+=500,t.space.syndicate.spc_enceladus+=250,t.space.syndicate.spc_triton+=1e3,!0)}},mass_relay:{id:"tech-mass_relay",title:z("tech_mass_relay"),desc:z("tech_mass_relay"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:4},grant:["outer",5],cost:{Knowledge:()=>22e5,Cipher:()=>4e4},effect:z("tech_mass_relay_effect"),action(){return!!ri($(this)[0])&&(t.space.mass_relay={count:0},!0)}},nav_data:{id:"tech-nav_data",title:z("tech_nav_data"),desc:z("tech_nav_data"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:6},grant:["outer",7],cost:{Knowledge:()=>225e4,Cipher:()=>6e4},effect:z("tech_nav_data_effect"),action(){return!!ri($(this)[0])&&(t.settings.space.eris=!0,t.settings.space.kuiper=!0,t.tech.eris_scan=0,t.space.drone_control={count:0,on:0,support:0,s_max:0},hs(z("tech_nav_data_result",[Ut().eris]),"info",!1,["progress"]),!0)}},sensor_logs:{id:"tech-sensor_logs",title:z("tech_sensor_logs"),desc:z("tech_sensor_logs"),category:"space_exploration",era:"solar",path:["truepath"],reqs:{outer:7},grant:["outer",8],cost:{Knowledge:()=>35e5,Cipher:()=>65e3},effect:z("tech_sensor_logs_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_sensor_logs_result"),"info",!1,["progress"]),!0)}},dronewar:{id:"tech-dronewar",title:z("tech_dronewar"),desc:z("tech_dronewar"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{eris:2,titan_ai_core:1},grant:["eris",3],cost:{Knowledge:()=>32e5,Cipher:()=>25e3},effect:()=>z("tech_dronewar_effect",[Ut().eris]),action(){return!!ri($(this)[0])&&(t.space.shock_trooper={count:0,on:0},t.space.digsite={count:0,enemy:1e4},!0)}},drone_tank:{id:"tech-drone_tank",title:z("tech_drone_tank"),desc:z("tech_drone_tank"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{eris:3},grant:["eris",4],cost:{Knowledge:()=>34e5,Cipher:()=>5e4},effect:z("tech_drone_tank_effect"),action(){return!!ri($(this)[0])&&(t.space.tank={count:0,on:0},!0)}},stanene_tp:{id:"tech-stanene_tp",title:z("tech_stanene"),desc:z("tech_stanene"),category:"crafting",era:"solar",path:["truepath"],reqs:{titan:1,enceladus:1},grant:["stanene",1],cost:{Knowledge:()=>525e3,Aluminium:()=>5e5,Nano_Tube:()=>1e5},effect:z("tech_stanene_effect"),action(){return!!ri($(this)[0])&&(t.resource.Stanene.display=!0,hs(z("tech_stanene_avail"),"info",!1,["progress"]),!0)},post(){ki(),cs()}},graphene_tp:{id:"tech-graphene_tp",title:z("tech_graphene"),desc:z("tech_graphene"),category:"crafting",era:"solar",path:["truepath"],reqs:{titan:5},grant:["graphene",1],cost:{Knowledge:()=>64e4,Adamantite:()=>25e3},effect:z("tech_graphene_effect"),action(){return!!ri($(this)[0])&&(t.space.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},!0)}},virtual_reality_tp:{id:"tech-virtual_reality_tp",title:z("tech_virtual_reality"),desc:z("tech_virtual_reality"),category:"progress",era:"solar",path:["truepath"],reqs:{high_tech:11,titan:4,stanene:1},grant:["high_tech",12],cost:{Knowledge:()=>616e3,Nano_Tube:()=>1e6,Stanene:()=>125e3},effect:z("tech_virtual_reality_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_virtual_reality_flair")},electrolysis:{id:"tech-electrolysis",title:z("tech_electrolysis"),desc:z("tech_electrolysis"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:2,enceladus:1},grant:["titan",3],cost:{Knowledge:()=>465e3},effect:()=>z("tech_electrolysis_effect",[Ut().titan,t.resource.Water.name]),action(){return!!ri($(this)[0])&&(t.space.titan_quarters={count:0,on:0},t.space.titan_mine={count:0,on:0,ratio:90},!0)}},storehouse:{id:"tech-storehouse",title:()=>z("tech_storehouse",[Ut().titan]),desc:()=>z("tech_storehouse",[Ut().titan]),category:"storage",era:"solar",path:["truepath"],reqs:{titan:4},grant:["titan",5],cost:{Knowledge:()=>5e5},effect:()=>z("tech_storehouse_effect",[Ut().titan]),action(){return!!ri($(this)[0])&&(t.space.storehouse={count:0},!0)}},adamantite_vault_tp:{id:"tech-adamantite_vault_tp",title:z("tech_adamantite_vault"),desc:z("tech_adamantite_vault"),category:"banking",era:"solar",path:["truepath"],reqs:{vault:2,titan:4},grant:["vault",3],cost:{Money:()=>2e6,Knowledge:()=>56e4,Adamantite:()=>2e4},effect:z("tech_adamantite_vault_effect"),action(){return!!ri($(this)[0])}},titan_bank:{id:"tech-titan_bank",title:()=>z("tech_titan_bank",[Ut().titan]),desc:()=>z("tech_titan_bank",[Ut().titan]),category:"storage",era:"solar",path:["truepath"],reqs:{titan:5},grant:["titan",6],cost:{Knowledge:()=>6e5},effect:()=>z("tech_titan_bank_effect",[Ut().titan]),action(){return!!ri($(this)[0])&&(t.space.titan_bank={count:0},!0)}},hydrogen_plant:{id:"tech-hydrogen_plant",title:z("tech_hydrogen_plant"),desc:z("tech_hydrogen_plant"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:4,stanene:1},grant:["titan_power",1],cost:{Knowledge:()=>55e4},effect:()=>z("tech_hydrogen_plant_effect"),action(){return!!ri($(this)[0])&&(t.space.hydrogen_plant={count:0,on:0},!0)}},water_mining:{id:"tech-water_mining",title:z("tech_water_mining"),desc:z("tech_water_mining"),category:"power_generation",era:"solar",path:["truepath"],reqs:{titan:2,enceladus:1},grant:["enceladus",2],cost:{Knowledge:()=>45e4},effect:()=>z("tech_water_mining_effect",[Ut().enceladus,Ki[t.race.species].home,t.resource.Water.name]),action(){return!!ri($(this)[0])&&(t.space.water_freighter={count:0,on:0},!0)}},mercury_smelting:{id:"tech-mercury_smelting",title:z("tech_mercury_smelting"),desc:z("tech_mercury_smelting"),category:"mining",era:"solar",path:["truepath"],reqs:{hell:1,titan:4,smelting:6},grant:["m_smelting",1],cost:{Knowledge:()=>625e3,Adamantite:()=>5e4},effect:()=>z("tech_mercury_smelting_effect",[Ut().hell]),action(){return!!ri($(this)[0])&&(t.space.hell_smelter={count:0},!0)}},iridium_smelting:{id:"tech-iridium_smelting",title:z("tech_iridium_smelting"),desc:z("tech_iridium_smelting"),category:"mining",era:"solar",path:["truepath"],reqs:{m_smelting:1,graphene:1},grant:["m_smelting",2],cost:{Knowledge:()=>825e3,Graphene:()=>125e3},effect:z("tech_iridium_smelting_effect"),action(){return!!ri($(this)[0])}},adamantite_crates:{id:"tech-adamantite_crates",title:z("tech_adamantite_crates"),desc:z("tech_adamantite_crates_desc"),category:"storage",era:"solar",path:["truepath"],reqs:{container:5,titan:4},grant:["container",6],cost:{Knowledge:()=>525e3,Adamantite:()=>12500},effect:z("tech_adamantite_crates_effect"),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},bolognium_crates_tp:{id:"tech-bolognium_crates_tp",title:()=>z("tech_crates",[t.resource.Bolognium.name]),desc:()=>z("tech_crates",[t.resource.Bolognium.name]),category:"storage",era:"tauceti",path:["truepath"],reqs:{container:7,tauceti:4},grant:["container",8],cost:{Knowledge:()=>616e4,Bolognium:()=>75e4},effect:()=>z("tech_bolognium_crates_effect",[t.resource.Bolognium.name]),action(){return!!ri($(this)[0])}},adamantite_containers_tp:{id:"tech-adamantite_containers_tp",title:()=>z("tech_containers",[t.resource.Adamantite.name]),desc:()=>z("tech_adamantite_containers_desc",[t.resource.Adamantite.name]),category:"storage",era:"solar",path:["truepath"],reqs:{steel_container:4,titan:4},grant:["steel_container",5],cost:{Knowledge:()=>575e3,Adamantite:()=>17500},effect:()=>z("tech_adamantite_containers_effect",[t.resource.Adamantite.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},quantium_containers:{id:"tech-quantium_containers",title:()=>z("tech_containers",[t.resource.Quantium.name]),desc:()=>z("tech_containers",[t.resource.Quantium.name]),category:"storage",era:"solar",path:["truepath"],reqs:{steel_container:5,quantium:1},grant:["steel_container",6],cost:{Knowledge:()=>115e4,Quantium:()=>1e5},effect:()=>z("tech_quantium_containers_effect",[t.resource.Quantium.name]),action(){return!!ri($(this)[0])&&(Cs({el:"#createHead"},"update"),!0)}},unobtainium_containers:{id:"tech-unobtainium_containers",title:()=>z("tech_containers",[t.resource.Unobtainium.name]),desc:()=>z("tech_containers",[t.resource.Unobtainium.name]),category:"storage",era:"tauceti",path:["truepath"],reqs:{steel_container:6,tau_red:7},grant:["steel_container",7],cost:{Knowledge:()=>725e4,Unobtainium:()=>7500},effect:()=>z("tech_bolognium_containers_effect",[t.resource.Unobtainium.name]),action(){return!!ri($(this)[0])}},reinforced_shelving:{id:"tech-reinforced_shelving",title:z("tech_reinforced_shelving"),desc:z("tech_reinforced_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{graphene:1,titan:5},grant:["shelving",1],cost:{Knowledge:()=>85e4,Adamantite:()=>35e4,Graphene:()=>25e4},effect:z("tech_reinforced_shelving_effect"),action(){return!!ri($(this)[0])}},garage_shelving:{id:"tech-garage_shelving",title:z("tech_garage_shelving"),desc:z("tech_garage_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{shelving:1,quantium:1},grant:["shelving",2],cost:{Knowledge:()=>125e4,Quantium:()=>75e3},effect:z("tech_garage_shelving_effect"),action(){return!!ri($(this)[0])}},warehouse_shelving:{id:"tech-warehouse_shelving",title:z("tech_warehouse_shelving"),desc:z("tech_warehouse_shelving"),category:"storage",era:"solar",path:["truepath"],reqs:{shelving:2,quantium:1,outer:4},grant:["shelving",3],cost:{Knowledge:()=>225e4,Quantium:()=>1e6,Cipher:()=>25e3},effect:z("tech_warehouse_shelving_effect"),action(){return!!ri($(this)[0])}},elerium_extraction:{id:"tech-elerium_extraction",title:z("tech_elerium_extraction"),desc:z("tech_elerium_extraction"),category:"mining",era:"solar",path:["truepath"],reqs:{kuiper:1},grant:["kuiper",2],cost:{Knowledge:()=>25e5,Orichalcum:()=>1e5,Cipher:()=>12e3},effect:()=>z("tech_elerium_extraction_effect"),action(){return!!ri($(this)[0])&&(t.space.elerium_mine={count:0,on:0},!0)}},orichalcum_panels_tp:{id:"tech-orichalcum_panels_tp",title:z("tech_orichalcum_panels"),desc:z("tech_orichalcum_panels"),category:"power_generation",era:"solar",path:["truepath"],reqs:{kuiper:1,swarm:5},grant:["swarm",6],cost:{Knowledge:()=>24e5,Orichalcum:()=>125e3},effect:()=>z("tech_orichalcum_panels_effect"),action(){return!!ri($(this)[0])}},shipyard:{id:"tech-shipyard",title:()=>z("tech_shipyard",[Ut().dwarf]),desc:()=>z("tech_shipyard",[Ut().dwarf]),category:"space_militarization",era:"solar",path:["truepath"],reqs:{outer:1,syndicate:1},grant:["shipyard",1],cost:{Knowledge:()=>42e4},effect:()=>z("tech_shipyard_effect",[Ut().dwarf]),action(){return!!ri($(this)[0])&&(t.space.shipyard={count:0,on:0,ships:[],expand:!0,sort:!0},pt(),!0)}},ship_lasers:{id:"tech-ship_lasers",title:z("tech_ship_lasers"),desc:z("tech_ship_lasers"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{military:7,syard_weapon:1},grant:["syard_weapon",2],cost:{Knowledge:()=>425e3,Elerium:()=>500},effect:z("tech_ship_lasers_effect"),action(){return!!ri($(this)[0])}},pulse_lasers:{id:"tech-pulse_lasers",title:z("tech_pulse_lasers"),desc:z("tech_pulse_lasers"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:2},grant:["syard_weapon",3],cost:{Knowledge:()=>5e5,Elerium:()=>750},effect:z("tech_pulse_lasers_effect"),action(){return!!ri($(this)[0])}},ship_plasma:{id:"tech-ship_plasma",title:z("tech_ship_plasma"),desc:z("tech_ship_plasma"),category:"space_militarization",era:"solar",reqs:{high_tech:13,syard_weapon:3},grant:["syard_weapon",4],path:["truepath"],cost:{Knowledge:()=>88e4,Elerium:()=>2500},effect:z("tech_ship_plasma_effect"),action(){return!!ri($(this)[0])}},ship_phaser:{id:"tech-ship_phaser",title:z("tech_ship_phaser"),desc:z("tech_ship_phaser"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:4,quantium:1},grant:["syard_weapon",5],cost:{Knowledge:()=>1225e3,Quantium:()=>75e3},effect:z("tech_ship_phaser_effect"),action(){return!!ri($(this)[0])}},ship_disruptor:{id:"tech-ship_disruptor",title:z("tech_ship_disruptor"),desc:z("tech_ship_disruptor"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_weapon:5,outer:4},grant:["syard_weapon",6],cost:{Knowledge:()=>2e6,Cipher:()=>25e3},effect:z("tech_ship_disruptor_effect"),action(){return!!ri($(this)[0])}},destroyer_ship:{id:"tech-destroyer_ship",title:z("tech_destroyer_ship"),desc:z("tech_destroyer_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:2},grant:["syard_class",3],cost:{Knowledge:()=>465e3},effect:z("tech_destroyer_ship_effect"),action(){return!!ri($(this)[0])}},cruiser_ship_tp:{id:"tech-cruiser_ship_tp",title:z("tech_cruiser_ship"),desc:z("tech_cruiser_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:3,titan:4},grant:["syard_class",4],cost:{Knowledge:()=>75e4,Adamantite:()=>5e4},effect:z("tech_cruiser_ship_tp"),action(){return!!ri($(this)[0])}},h_cruiser_ship:{id:"tech-h_cruiser_ship",title:z("tech_h_cruiser_ship"),desc:z("tech_h_cruiser_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:4,triton:1},grant:["syard_class",5],cost:{Knowledge:()=>15e5},effect:z("tech_h_cruiser_ship_effect"),action(){return!!ri($(this)[0])}},dreadnought_ship:{id:"tech-dreadnought_ship",title:z("tech_dreadnought_ship"),desc:z("tech_dreadnought_ship"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_class:5,kuiper:1},grant:["syard_class",6],cost:{Knowledge:()=>25e5,Cipher:()=>1e4},effect:z("tech_dreadnought_ship_effect"),action(){return!!ri($(this)[0])}},pulse_engine:{id:"tech-pulse_engine",title:z("outer_shipyard_engine_pulse"),desc:z("outer_shipyard_engine_pulse"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:2,stanene:1},grant:["syard_engine",3],cost:{Knowledge:()=>555e3,Stanene:()=>25e4},effect:z("tech_pulse_engine_effect"),action(){return!!ri($(this)[0])}},photon_engine:{id:"tech-photon_engine",title:z("outer_shipyard_engine_photon"),desc:z("outer_shipyard_engine_photon"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:3,quantium:1},grant:["syard_engine",4],cost:{Knowledge:()=>115e4,Quantium:()=>5e4},effect:z("tech_photon_engine_effect"),action(){return!!ri($(this)[0])}},vacuum_drive:{id:"tech-vacuum_drive",title:z("outer_shipyard_engine_vacuum"),desc:z("outer_shipyard_engine_vacuum"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_engine:4,outer:4},grant:["syard_engine",5],cost:{Knowledge:()=>185e4,Cipher:()=>1e4},effect:z("outer_shipyard_engine_vacuum_desc"),action(){return!!ri($(this)[0])}},ship_fusion:{id:"tech-ship_fusion",title:z("tech_fusion_generator"),desc:z("tech_fusion_generator"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_power:3,quantium:1},grant:["syard_power",4],cost:{Knowledge:()=>11e5,Quantium:()=>65e3},effect:z("tech_fusion_generator_effect"),action(){return!!ri($(this)[0])}},ship_elerium:{id:"tech-ship_elerium",title:z("tech_elerium_generator"),desc:z("tech_elerium_generator"),category:"space_militarization",era:"solar",path:["truepath"],reqs:{syard_power:4,outer:4},grant:["syard_power",5],cost:{Knowledge:()=>19e5,Cipher:()=>18e3},effect:z("tech_elerium_generator_effect"),action(){return!!ri($(this)[0])}},quantum_signatures:{id:"tech-quantum_signatures",title:z("tech_quantum_signatures"),desc:z("tech_quantum_signatures"),category:"progress",era:"solar",path:["truepath"],reqs:{quantium:1,syard_sensor:3},grant:["syard_sensor",4],cost:{Knowledge:()=>105e4,Quantium:()=>1e4},effect:z("tech_quantum_signatures_effect"),action(){return!!ri($(this)[0])}},interstellar_drive:{id:"tech-interstellar_drive",title:z("tech_interstellar_drive"),desc:z("tech_interstellar_drive"),category:"progress",era:"tauceti",path:["truepath"],reqs:{outer:8,titan_ai_core:2,syard_sensor:4},grant:["tauceti",1],cost:{Knowledge:()=>45e5,Quantium:()=>25e4,Cipher:()=>75e3},effect:z("tech_interstellar_drive_effect"),action(){return!!ri($(this)[0])}},alien_outpost:{id:"tech-alien_outpost",title:z("tech_alien_outpost"),desc:z("tech_alien_outpost"),category:"science",era:"tauceti",path:["truepath"],reqs:{tauceti:2,tau_home:3},grant:["tau_home",4],cost:{Knowledge:()=>5e6,Cipher:()=>1e5},effect:z("tech_alien_outpost_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.alien_outpost={count:1,on:0},t.tauceti.jump_gate={count:0},t.space.jump_gate={count:0},hs(z("tech_alien_outpost_msg"),"info",!1,["progress"]),!0)}},jumpgates:{id:"tech-jumpgates",title:z("tech_jumpgates"),desc:z("tech_jumpgates"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tauceti:2,tau_home:4},grant:["tauceti",3],cost:{Knowledge:()=>6e6},effect:z("tech_jumpgates_effect"),action(){return!!ri($(this)[0])}},system_survey:{id:"tech-system_survey",title:z("tech_system_survey"),desc:z("tech_system_survey"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tauceti:4,womling_tech:1},grant:["tauceti",5],cost:{Knowledge:()=>7e6},effect:z("tech_system_survey_effect"),action(){return!!ri($(this)[0])&&(t.settings.tau.roid=!0,t.settings.tau.gas=!0,t.tauceti.patrol_ship={count:0,on:0,support:0,s_max:0},!0)}},repository:{id:"tech-repository",title:z("tech_repository"),desc:z("tech_repository"),category:"storage",era:"tauceti",path:["truepath"],reqs:{tauceti:4,tau_home:4},grant:["tau_home",5],cost:{Knowledge:()=>65e5},effect:z("tech_repository_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.repository={count:0},!0)}},fusion_generator:{id:"tech-fusion_generator",title:z("tech_fusion_power"),desc:z("tech_fusion_power"),category:"power_generation",era:"tauceti",path:["truepath"],reqs:{tau_home:5},grant:["tau_home",6],cost:{Knowledge:()=>675e4},effect:z("tech_tau_fusion_power_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.fusion_generator={count:0,on:0},!0)}},tau_cultivation:{id:"tech-tau_cultivation",title:z("tech_tau_cultivation"),desc:z("tech_tau_cultivation"),category:"agriculture",era:"tauceti",path:["truepath"],reqs:{tau_home:6},grant:["tau_home",7],cost:{Knowledge:()=>69e5},effect:()=>z("tech_tau_cultivation_effect",[Ki[t.race.species].home]),action(){return!!ri($(this)[0])&&(t.tauceti.tau_farm={count:0,on:0},!0)}},tau_manufacturing:{id:"tech-tau_manufacturing",title:z("tech_tau_manufacturing"),desc:z("tech_tau_manufacturing"),category:"crafting",era:"tauceti",path:["truepath"],reqs:{tau_home:7},grant:["tau_home",8],cost:{Knowledge:()=>725e4},effect:()=>z("tech_tau_manufacturing_effect",[Ki[t.race.species].home]),action(){return!!ri($(this)[0])&&(t.tauceti.tau_factory={count:0,on:0},!0)}},weasels:{id:"tech-weasels",title:z("tech_weasels"),desc:z("tech_weasels"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:2},grant:["tau_red",3],cost:{Knowledge:()=>625e4},effect:()=>z("tech_weasels_effect",[z("tau_planet",[Ut().red])]),action(){return!!ri($(this)[0])&&(hs(z("tech_weasels_msg",[z("tau_planet",[Ut().red])]),"info",!1,["progress"]),!0)}},jeff:{id:"tech-jeff",title:z("tech_jeff"),desc:z("tech_jeff"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:3},grant:["tau_red",4],cost:{Knowledge:()=>638e4},effect:()=>z("tech_jeff_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_jeff_effect_msg",[]),"info",!1,["progress"]),!0)}},womling_fun:{id:"tech-womling_fun",title:z("tech_womling_fun"),desc:z("tech_womling_fun"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:5},grant:["tau_red",6],cost:{Knowledge:()=>665e4},effect:()=>z("tech_womling_fun_effect"),action(){return!!ri($(this)[0])}},womling_lab:{id:"tech-womling_lab",title:z("tech_womling_lab"),desc:z("tech_womling_lab"),category:"womling",era:"tauceti",path:["truepath"],reqs:{tau_red:6},grant:["tau_red",7],cost:{Knowledge:()=>69e5},effect:()=>z("tech_womling_lab_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.womling_lab={count:0,on:0,scientist:0,tech:0},t.tech.womling_tech=0,!0)}},womling_mining:{id:"tech-womling_mining",title:z("tech_womling_mining"),desc:z("tech_womling_mining"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:1},grant:["womling_mining",1],cost:{Knowledge:()=>71e5},effect:()=>z("tech_womling_mining_effect"),action(){return!!ri($(this)[0])}},womling_firstaid:{id:"tech-womling_firstaid",title:z("tech_womling_firstaid"),desc:z("tech_womling_firstaid"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:2},grant:["womling_firstaid",1],cost:{Knowledge:()=>735e4},effect:()=>z("tech_womling_firstaid_effect"),action(){return!!ri($(this)[0])}},womling_logistics:{id:"tech-womling_logistics",title:z("tech_womling_logistics"),desc:z("tech_womling_logistics"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:3},grant:["womling_logistics",1],cost:{Knowledge:()=>765e4},effect:()=>z("tech_womling_logistics_effect",[z("tau_red_orbital_platform")]),action(){return!!ri($(this)[0])}},womling_repulser:{id:"tech-womling_repulser",title:z("tech_womling_repulser"),desc:z("tech_womling_repulser"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:4,womling_logistics:1},grant:["womling_logistics",2],cost:{Knowledge:()=>79e5},effect:()=>z("tech_womling_repulser_effect",[t.resource.Oil.name,z("tau_red_orbital_platform")]),action(){return!!ri($(this)[0])}},womling_farming:{id:"tech-womling_farming",title:z("tech_womling_farming"),desc:z("tech_womling_farming"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:5},grant:["womling_pop",1],cost:{Knowledge:()=>82e5},effect:()=>z("tech_womling_farming_effect"),action(){return!!ri($(this)[0])}},womling_housing:{id:"tech-womling_housing",title:z("tech_womling_housing"),desc:z("tech_womling_housing"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:6,womling_pop:1},grant:["womling_pop",2],cost:{Knowledge:()=>85e5},effect:()=>z("tech_womling_housing_effect"),action(){return!!ri($(this)[0])}},womling_support:{id:"tech-womling_support",title:z("tech_womling_support"),desc:z("tech_womling_support"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:7,tau_gas:4},grant:["womling_technicians",1],cost:{Knowledge:()=>885e4},effect:()=>`
                            ${z("tech_womling_support_effect")}
                            `,action(){return!!ri($(this)[0])&&(t.tauceti.womling_station={count:0,on:0},!0)}},womling_recycling:{id:"tech-womling_recycling",title:z("tech_womling_recycling"),desc:z("tech_womling_recycling"),category:"womling",era:"tauceti",path:["truepath"],reqs:{womling_tech:8},grant:["womling_recycling",1],cost:{Knowledge:()=>955e4},effect:()=>`
                            ${z("tech_womling_recycling_effect")}
                            `,action(){return!!ri($(this)[0])}},asteroid_analysis:{id:"tech-asteroid_analysis",title:z("tech_asteroid_analysis"),desc:z("tech_asteroid_analysis"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_roid:1},grant:["tau_roid",2],cost:{Knowledge:()=>735e4},effect:()=>z("tech_asteroid_analysis_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_asteroid_analysis_msg"),"info",!1,["progress"]),!0)}},shark_repellent:{id:"tech-shark_repellent",title:z("tech_shark_repellent"),desc:z("tech_shark_repellent"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_roid:2},grant:["tau_roid",3],cost:{Knowledge:()=>74e5},effect:()=>z("tech_shark_repellent_effect"),action(){return!!ri($(this)[0])&&(hs(z("tech_shark_repellent_msg"),"info",!1,["progress"]),!0)}},belt_mining:{id:"tech-belt_mining",title:z("tech_belt_mining"),desc:z("tech_belt_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{tau_gas:3,tau_roid:3},grant:["tau_gas",4],cost:{Knowledge:()=>765e4},effect:()=>z("tech_belt_mining_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.ore_refinery={count:0,on:0,max:0,fill:0},t.tauceti.mining_ship={count:0,on:0,common:50,uncommon:50,rare:50},!0)}},adv_belt_mining:{id:"tech-adv_belt_mining",title:z("tech_adv_belt_mining"),desc:z("tech_adv_belt_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{tau_roid:4},grant:["tau_roid",5],cost:{Knowledge:()=>79e5},effect:()=>z("tech_adv_belt_mining_effect"),action(){return!!ri($(this)[0])}},space_whaling:{id:"tech-space_whaling",title:z("tech_space_whaling"),desc:z("tech_space_whaling"),category:"whaling",era:"tauceti",path:["truepath"],reqs:{tau_gas:3,tau_roid:3},grant:["tau_whale",1],cost:{Knowledge:()=>75e5},effect:()=>z("tech_space_whaling_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.whaling_station={count:0,on:0,max:0,fill:0},t.tauceti.whaling_ship={count:0,on:0},!0)}},infectious_disease_lab:{id:"tech-infectious_disease_lab",title:()=>z(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),desc:()=>z(t.race.artifical?"tech_infectious_disease_lab_s":"tech_infectious_disease_lab"),category:"science",era:"tauceti",path:["truepath"],reqs:{plague:2},grant:["disease",1],cost:{Knowledge:()=>825e4},effect:()=>z(t.race.artifical?"tech_infectious_disease_lab_effect_s":"tech_infectious_disease_lab_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.infectious_disease_lab={count:0,on:0,cure:0},!0)}},isolation_protocol:{id:"tech-isolation_protocol",title:z("tech_isolation_protocol"),desc:z("tech_isolation_protocol"),category:"plague",era:"tauceti",path:["truepath"],reqs:{disease:2},grant:["disease",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>85e5},effect:()=>`
                            ${z("tech_isolation_protocol_effect",[z("tab_tauceti")])}
                            ${z("tech_isolation_protocol_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),t.tech.isolation=1,function(){let e={city:{},space:{},ships:[]};e.ships=[...t.space.shipyard.ships],t.space.shipyard.ships=[],t.settings.spaceTabs=6,t.settings.showSpace=!1,t.settings.showOuter=!1,t.settings.showCity=!1,t.settings.showShipYard=!1,5===t.settings.govTabs&&(t.settings.govTabs=0),nt(),Ss($("#shipList")),Object.keys(Mr.city).forEach((function(a){t.city.hasOwnProperty(a)&&t.city[a].hasOwnProperty("count")&&(t.race.hooved&&Mr.city[a].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Mr.city[a].cost.Horseshoe()*t.city[a].count),e.city[a]={c:t.city[a].count},t.city[a].count=0,t.city[a].hasOwnProperty("on")&&(e.city[a].o=t.city[a].on,t.city[a].on=0))})),["spc_home","spc_moon","spc_red","spc_hell","spc_sun","spc_gas","spc_gas_moon","spc_belt","spc_dwarf","spc_titan","spc_enceladus","spc_triton","spc_kuiper","spc_eris"].forEach((function(a){Object.keys(Mr.space[a]).forEach((function(r){t.space.hasOwnProperty(r)&&t.space[r].hasOwnProperty("count")&&(t.race.hooved&&Mr.space[a][r].cost.hasOwnProperty("Horseshoe")&&(t.race.shoecnt-=Mr.space[a][r].cost.Horseshoe()*t.space[r].count),e.space[r]={c:t.space[r].count},t.space[r].count=0,t.space[r].hasOwnProperty("on")&&(e.space[r].o=t.space[r].on,t.space[r].on=0))}))})),t.race.hooved&&t.race.shoecnt<5&&(t.race.shoecnt=5),t.resource.Zen.display&&(t.resource.Zen.display=!1),t.resource.Slave.display&&(t.resource.Slave.display=!1,t.resource.Slave.amount=0,D("slave")),t.race.deconstructor&&xi.forEach((function(e){t.city.nanite_factory[e]=0})),Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),Object.keys(Xt).forEach((function(e){["professor","scientist","pit_miner","cement_worker","craftsman"].includes(e)||(t.civic[e].workers=0,t.civic[e].assigned=0)})),["forager","farmer","lumberjack","quarry_worker","miner","coal_miner","priest","colonist","titan_colonist","space_miner"].forEach((function(e){t.civic[e].display=!1})),t.civic.hunter.display?t.civic.d_job="hunter":t.civic.d_job="unemployed",t.arpa.sequence&&(t.arpa.sequence.on=!1,t.arpa.sequence.boost=!1);for(let e of Object.values(t.race.purgatory.city))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);for(let e of Object.values(t.race.purgatory.space))e.hasOwnProperty("count")&&(e.count=0),e.hasOwnProperty("on")&&(e.on=0);if(t.queue.hasOwnProperty("queue"))for(let e=t.queue.queue.length-1;e>=0;e--){let a=t.queue.queue[e];"city"!==a.action&&"space"!==a.action&&"starDock"!==a.action||t.queue.queue.splice(e,1)}t.tech.magic&&t.tech.magic>=2&&(t.tauceti.pylon={count:0},t.race.casting&&Object.keys(t.race.casting).forEach((function(e){t.race.casting[0]=0}))),t.tauceti.tauceti_casino={count:0,on:0},t.tauceti.tau_housing={count:0};let a=n.colony*Re.tau_home.colony.citizens();t.resource[t.race.species].amount>a&&(t.resource[t.race.species].amount=a),D("spy"),D("spyop"),Ss($("#infoTimer")),t.race.inactive=e}(),!0)}},focus_cure:{id:"tech-focus_cure",title:z("tech_focus_cure"),desc:z("tech_focus_cure"),category:"plague",era:"tauceti",path:["truepath"],reqs:{disease:2},grant:["disease",3],not_trait:["lone_survivor"],cost:{Knowledge:()=>85e5},effect:()=>`
                            ${z("tech_focus_cure_effect",[z("tab_tauceti")])}
                            ${z("tech_focus_cure_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.tech.focus_cure=1,!0)}},decode_virus:{id:"tech-decode_virus",title:z("tech_decode_virus"),desc:z("tech_decode_virus"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:1},grant:["focus_cure",2],cost:{Knowledge:()=>9e6},effect:()=>`
                            ${z(t.race.artifical?"tech_decode_virus_effect_s":"tech_decode_virus_effect")}
                            `,action(){return!!ri($(this)[0])&&(t.race.artifical?hs(z("tech_decode_virus_msg1s",[Mr.tauceti.tau_home.infectious_disease_lab.title()]),"info",!1,["progress"]):hs(z("tech_decode_virus_msg1",[Mr.tauceti.tau_home.infectious_disease_lab.title()]),"info",!1,["progress"]),!0)}},vaccine_campaign:{id:"tech-vaccine_campaign",title:z("tech_vaccine_campaign"),desc:z("tech_vaccine_campaign"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:3},grant:["focus_cure",4],cost:{Knowledge:()=>925e4},effect:()=>`
                            ${z("tech_vaccine_campaign_effect",[t.race.artifical?Mr.city.boot_camp.title():Mr.city.hospital.title])}
                            `,action(){return!!ri($(this)[0])&&(t.race.vax=0,!0)}},vax_strat1:{id:"tech-vax_strat1",title:z("tech_vax_strat1"),desc:z("tech_vax_strat1"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
                            ${z("tech_vax_strat1_effect")}
                            ${z("tech_vax_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.tech.vax_p=1,hs(z("tech_vax_strat1_msg"),"info",!1,["progress"]),!0)}},vax_strat2:{id:"tech-vax_strat2",title:z("tech_vax_strat2"),desc:z("tech_vax_strat2"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
                            ${z("tech_vax_strat2_effect")}
                            ${z("tech_vax_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.tech.vax_f=1,hs(z("tech_vax_strat2_msg"),"info",!1,["progress"]),!0)}},vax_strat3:{id:"tech-vax_strat3",title:z("tech_vax_strat3"),desc:z("tech_vax_strat3"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
                            ${z("tech_vax_strat3_effect")}
                            ${z("tech_vax_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.tech.vax_s=1,hs(z("tech_vax_strat3_msg"),"info",!1,["progress"]),!0)}},vax_strat4:{id:"tech-vax_strat4",title:z("tech_vax_strat4"),desc:z("tech_vax_strat4"),category:"plague",era:"tauceti",path:["truepath"],reqs:{focus_cure:5},grant:["focus_cure",6],cost:{Knowledge:()=>95e5},effect:()=>`
                            ${z("tech_vax_strat4_effect")}
                            ${z("tech_vax_warning")}
                            `,action(){return!!ri($(this)[0])&&(t.tech.vax_c=1,hs(z("tech_vax_strat4_msg"),"info",!1,["progress"]),!0)}},cloning:{id:"tech-cloning",title:z("tech_cloning"),desc:z("tech_cloning"),category:"housing",era:"tauceti",path:["truepath"],reqs:{focus_cure:7},grant:["cloning",1],cost:{Knowledge:()=>975e4},effect:()=>`
                            ${z(t.race.artifical?"tech_cloning_effect_s":"tech_cloning_effect")}
                            `,action(){return!!ri($(this)[0])&&(t.tauceti.cloning_facility={count:0,on:0},!0)}},clone_degradation:{id:"tech-clone_degradation",title:z("tech_clone_degradation"),desc:z("tech_clone_degradation"),category:"progress",era:"tauceti",path:["truepath"],reqs:{cloning:1},grant:["cloning",2],cost:{Knowledge:()=>1e7},effect:()=>`
                            ${z("tech_clone_degradation_effect")}
                            `,action(){return!!ri($(this)[0])&&(hs(z("tech_clone_degradation_msg"),"info",!1,["progress"]),!0)}},digital_paradise:{id:"tech-digital_paradise",title:z("tech_digital_paradise"),desc:z("tech_digital_paradise"),category:"progress",era:"tauceti",path:["truepath"],reqs:{cloning:2},grant:["matrix",1],cost:{Knowledge:()=>105e5,Cipher:()=>2e5},effect:()=>`
                            ${z("tech_digital_paradise_effect")}
                            `,action(){return!!ri($(this)[0])}},ringworld:{id:"tech-ringworld",title:z("tech_ringworld"),desc:z("tech_ringworld"),category:"progress",era:"tauceti",path:["truepath"],reqs:{matrix:1},grant:["matrix",2],cost:{Money:()=>3e9,Knowledge:()=>11e6},effect:()=>`
                            ${z("tech_ringworld_effect")}
                            `,action(){return!!ri($(this)[0])&&(t.settings.tau.star=!0,t.tauceti.ringworld={count:0},!0)}},iso_gambling:{id:"tech-iso_gambling",title:z("tech_iso_gambling"),desc:z("tech_iso_gambling"),category:"banking",era:"tauceti",reqs:{gambling:4,isolation:1},grant:["iso_gambling",1],cost:{Knowledge:()=>865e4},effect:z("tech_iso_gambling_effect",[5]),action(){return!!ri($(this)[0])}},outpost_boost:{id:"tech-outpost_boost",title:()=>z("tech_outpost_boost"),desc:()=>z("tech_outpost_boost"),category:"special",era:"tauceti",path:["truepath"],reqs:{tau_home:4,isolation:1},grant:["outpost_boost",1],cost:{Knowledge:()=>89e5},effect:()=>z("tech_outpost_boost_effect"),action(){return!!ri($(this)[0])},flair:()=>z("tech_outpost_boost_flair")},cultural_center:{id:"tech-cultural_center",title:z("tech_cultural_center"),desc:z("tech_cultural_center"),category:"banking",era:"tauceti",path:["truepath"],reqs:{iso_gambling:1,isolation:1},grant:["tau_culture",1],cost:{Knowledge:()=>885e4},effect:z("tech_cultural_center_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.tau_cultural_center={count:0,on:0},!0)},flair:()=>z("tech_cultural_center_flair")},outer_tau_survey:{id:"tech-outer_tau_survey",title:z("tech_outer_tau_survey"),desc:z("tech_outer_tau_survey"),category:"progress",era:"tauceti",path:["truepath"],reqs:{outpost_boost:1,plague:5},grant:["tau_gas2",1],cost:{Knowledge:()=>91e5,Helium_3:()=>+Ht(5e6).toFixed(0)},effect:z("tech_outer_tau_survey_effect"),action(){return!!ri($(this)[0])&&(t.settings.tau.gas2=!0,!0)}},alien_research:{id:"tech-alien_research",title:z("tech_alien_research"),desc:z("tech_alien_research"),category:"progress",era:"tauceti",path:["truepath"],reqs:{tau_gas2:5},grant:["tau_gas2",6],cost:{Knowledge:()=>935e4},effect:z("tech_alien_research_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.alien_space_station.decrypted=0,t.tauceti.alien_space_station.focus=95,hs(z("tech_alien_research_msg"),"info",!1,["progress"]),!0)}},womling_gene_therapy:{id:"tech-womling_gene_therapy",title:z("tech_womling_gene_therapy"),desc:z("tech_womling_gene_therapy"),category:"womling",era:"tauceti",path:["truepath"],reqs:{alien_data:1},grant:["womling_gene",1],cost:{Knowledge:()=>952e4},effect:z("tech_womling_gene_therapy_effect"),action(){return!!ri($(this)[0])}},food_culture:{id:"tech-food_culture",title:()=>z("tech_food_culture",[z(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),desc:()=>z("tech_food_culture",[z(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`)]),category:"banking",era:"tauceti",path:["truepath"],reqs:{alien_data:2,tau_culture:1},grant:["tau_culture",2],cost:{Knowledge:()=>941e4},effect:()=>z("tech_food_culture_effect",[z(`tau_gas2_alien_station_data2_r${t.race.tau_food_item||0}`),z("tech_cultural_center")]),action(){return!!ri($(this)[0])}},advanced_refinery:{id:"tech-advanced_refinery",title:z("tech_advanced_refinery"),desc:z("tech_advanced_refinery"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:3},grant:["tau_ore_mining",1],cost:{Knowledge:()=>968e4},effect:()=>z("tech_advanced_refinery_effect"),action(){return!!ri($(this)[0])}},advanced_pit_mining:{id:"tech-advanced_pit_mining",title:z("tech_advanced_pit_mining"),desc:z("tech_advanced_pit_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:3},grant:["tau_pit_mining",1],cost:{Knowledge:()=>972e4},effect:()=>z("tech_advanced_pit_mining_effect"),action(){return!!ri($(this)[0])}},useless_junk:{id:"tech-useless_junk",title:z("tech_useless_junk"),desc:z("tech_useless_junk"),category:"womling",era:"tauceti",path:["truepath"],reqs:{alien_data:4},grant:["tau_junksale",1],cost:{Knowledge:()=>955e4},effect:()=>z("tech_useless_junk_effect",[z(`tau_gas2_alien_station_data4_r${t.race.tau_junk_item||0}`),z("tau_red_womlings")]),action(){return!!ri($(this)[0])}},advanced_asteroid_mining:{id:"tech-advanced_asteroid_mining",title:z("tech_advanced_asteroid_mining"),desc:z("tech_advanced_asteroid_mining"),category:"space_mining",era:"tauceti",path:["truepath"],reqs:{alien_data:5,tau_ore_mining:1},grant:["tau_ore_mining",2],cost:{Knowledge:()=>975e4},effect:()=>z("tech_advanced_asteroid_mining_effect",[z("tau_roid_mining_ship")]),action(){return!!ri($(this)[0])}},advanced_material_synthesis:{id:"tech-advanced_material_synthesis",title:z("tech_advanced_material_synthesis"),desc:z("tech_advanced_material_synthesis"),category:"crafting",era:"tauceti",path:["truepath"],reqs:{alien_data:5,disease:1},grant:["alien_crafting",1],cost:{Knowledge:()=>988e4},effect:()=>z("tech_advanced_material_synthesis_effect",[t.resource.Quantium.name]),action(){return!!ri($(this)[0])}},matrioshka_brain:{id:"tech-matrioshka_brain",title:z("tech_matrioshka_brain"),desc:z("tech_matrioshka_brain"),category:"progress",era:"tauceti",path:["truepath"],reqs:{alien_data:6,tau_gas2:6},grant:["tau_gas2",7],not_trait:["lone_survivor"],cost:{Knowledge:()=>1e7},effect:()=>z("tech_matrioshka_brain_effect",[Mr.tauceti.tau_gas2.info.name()]),action(){return!!ri($(this)[0])&&(t.tauceti.matrioshka_brain={count:0},!0)}},ignition_device:{id:"tech-ignition_device",title:z("tech_ignition_device"),desc:z("tech_ignition_device"),category:"progress",era:"tauceti",path:["truepath"],reqs:{alien_data:6,tau_gas2:7},grant:["tau_gas2",8],cost:{Knowledge:()=>105e5},effect:()=>z("tech_ignition_device_effect",[Mr.tauceti.tau_gas2.info.name()]),action(){return!!ri($(this)[0])&&(t.tauceti.ignition_device={count:0},t.tauceti.hasOwnProperty("matrioshka_brain")||(t.tauceti.matrioshka_brain={count:0}),!0)}},replicator:{id:"tech-replicator",title:()=>"antimatter"===t.race.universe?z("tech_antireplicator"):z("tech_replicator"),desc:()=>"antimatter"===t.race.universe?z("tech_antireplicator"):z("tech_replicator"),category:"special",era:"tauceti",path:["truepath"],reqs:{tau_home:4,isolation:1},trait:["lone_survivor"],grant:["replicator",1],cost:{Knowledge:()=>625e4},effect:()=>"antimatter"===t.race.universe?z("tech_antireplicator_effect"):z("tech_replicator_effect"),action(){return!!ri($(this)[0])&&(t.race.replicator={res:"Unobtainium",pow:1},!0)}},womling_unlock:{id:"tech-womling_unlock",title:z("tech_womling_unlock"),desc:z("tech_womling_unlock"),category:"womling",era:"tauceti",path:["truepath"],reqs:{replicator:1},trait:["lone_survivor"],grant:["tau_red",4],cost:{Knowledge:()=>65e5},effect:()=>z("tech_womling_unlock_effect",[z("tau_planet",[Ut().red])]),action(){return!!ri($(this)[0])&&(t.settings.tau.red=!0,t.tauceti.orbital_platform.count=1,t.tauceti.orbital_platform.on=1,!0)}},garden_of_eden:{id:"tech-garden_of_eden",title:z("tech_garden_of_eden"),desc:z("tech_garden_of_eden"),category:"special",era:"tauceti",path:["truepath"],reqs:{eden:1},grant:["eden",2],cost:{Knowledge:()=>1e7},effect:()=>z("tech_garden_of_eden_effect"),action(){return!!ri($(this)[0])&&(t.tauceti.goe_facility={count:0},!0)}}};function qr(){t.tech.world_control=1,Ss($("#garrison")),Ss($("#c_garrison")),he($("#garrison"),!0),he($("#c_garrison"),!1);for(let e=0;e<3;e++){if(t.civic.foreign[`gov${e}`].occ){let a=ta("federation"===t.civic.govern.type?15:20);t.civic.garrison.max+=a,t.civic.garrison.workers+=a,t.civic.foreign[`gov${e}`].occ=!1}t.civic.foreign[`gov${e}`].buy=!1,t.civic.foreign[`gov${e}`].anx=!1,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none"}D("spy"),D("spyop")}function Pr(e,a){let r=["swiss","gouda","cheddar","brie","feta","ricotta","goat","mascarpone","bleu","colby_jack","camembert","gorgonzola","mozzarella","roquefort","provolone","monterey_jack","muenster","cambozola","jarlsberg","bocconcini","cantal","emmental","havarti","burrata","cottage","asiago","wensleydale","pepper_jack","queso_blanco","pecorino","raclette","fontina","reblochon","port_salut","brillat_savarin","cream","stilton","taleggio","manchego","edam","gruyeye","parmigiano_reggiano","epoisses","comte","caciocavallo","teleme","grana_padano","chaumes","morbier","halloumi","lancashire","bleu_de_gex","fourme_d_ambert","fromage_blanc","red_leicester","bleu_d_auvergne","pont_l_eveque","jl_grubb","castello_blue","wagasi","ayibe","caravane","limburger","herve","kashkaval","sirene","paski_sir","akkawi","olomoucke_syrecky","anari","danbo","hermelín","trappista","stinking_bishop","banbury","sulguni","hofoingi","urda","golka","rokpol","telemea","bryndza","parenica","kackavalj","liptauer","greve","korbaciky","herrgardsost","vasterbottensost","mish","anejo","quesillo","nacho","reggianito","catupiry","queso_paipa","canastra","port_wine","cados","brie_de_meaux"];if(a)return r;let i=(t.stats.hasOwnProperty("reset")?t.stats.reset:0)%r.length;return e?z(`cheese_${r[i]}`):z("tech_swiss_bank",[z(`cheese_${r[i]}`)])}const jr={standard:["primitive","discovery","civilized","industrialized","globalized","early_space","deep_space","interstellar","intergalactic","dimensional"],truepath:["primitive","discovery","civilized","industrialized","globalized","early_space","deep_space","solar","tauceti"]};function Or(e){if(e){let t={};return Object.keys(xr).forEach((function(a){(jr[e].includes(xr[a].era)||xr[a].hasOwnProperty("path"))&&(!xr[a].hasOwnProperty("path")||xr[a].hasOwnProperty("path")&&xr[a].path.includes(e))&&(t[a]=xr[a])})),t}return xr}const Mr={evolution:{rna:{id:"evolution-rna",title:z("resource_RNA_name"),desc:()=>z("evo_rna",[t.race.rapid_mutation?2:1]),condition:()=>t.resource.hasOwnProperty("RNA")&&t.resource.RNA.display&&!t.race.evoFinalMenu,action:()=>(t.resource.RNA.amount0},dna:{id:"evolution-dna",title:z("evo_dna_title"),desc:z("evo_dna_desc"),condition:()=>t.resource.hasOwnProperty("DNA")&&t.resource.DNA.display&&!t.race.evoFinalMenu,cost:{RNA:()=>2},action:()=>(t.resource.RNA.amount>=2&&t.resource.DNA.amount0},membrane:{id:"evolution-membrane",title:z("evo_membrane_title"),desc:z("evo_membrane_desc"),condition:()=>t.evolution.hasOwnProperty("membrane")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("membrane",2,2,e)},effect:()=>z("evo_membrane_effect",[t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5]),action(){return!!ri($(this)[0])&&(t.resource.RNA.max+=t.evolution.mitochondria?5*t.evolution.mitochondria.count+5:5,t.evolution.membrane.count++,!0)}},organelles:{id:"evolution-organelles",title:z("evo_organelles_title"),desc:z("evo_organelles_desc"),condition:()=>t.evolution.hasOwnProperty("organelles")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("organelles",12,8,e),DNA:e=>Dr("organelles",4,4,e)},effect(){let e=t.race.rapid_mutation?2:1;return t.evolution.sexual_reproduction&&t.evolution.sexual_reproduction.count>0&&e++,z("evo_organelles_effect",[e])},action(){return!!ri($(this)[0])&&(t.evolution.organelles.count++,!0)}},nucleus:{id:"evolution-nucleus",title:z("evo_nucleus_title"),desc:z("evo_nucleus_desc"),condition:()=>t.evolution.hasOwnProperty("nucleus")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("nucleus",38,t.tech.evo&&t.tech.evo>=4?16:32,e),DNA:e=>Dr("nucleus",18,t.tech.evo&&t.tech.evo>=4?12:16,e)},effect:()=>z("evo_nucleus_effect",[t.evolution.bilateral_symmetry&&t.evolution.bilateral_symmetry.count>0||t.evolution.poikilohydric&&t.evolution.poikilohydric.count>0||t.evolution.spores&&t.evolution.spores.count>0?2:1]),action(){return!!ri($(this)[0])&&(t.evolution.nucleus.count++,!0)}},eukaryotic_cell:{id:"evolution-eukaryotic_cell",title:z("evo_eukaryotic_title"),desc:z("evo_eukaryotic_desc"),condition:()=>t.evolution.hasOwnProperty("eukaryotic_cell")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("eukaryotic_cell",20,20,e),DNA:e=>Dr("eukaryotic_cell",40,12,e)},effect:()=>z("evo_eukaryotic_effect",[t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10]),action(){return!!ri($(this)[0])&&(t.evolution.eukaryotic_cell.count++,t.resource.DNA.max+=t.evolution.mitochondria?10*t.evolution.mitochondria.count+10:10,!0)}},mitochondria:{id:"evolution-mitochondria",title:z("evo_mitochondria_title"),desc:z("evo_mitochondria_desc"),condition:()=>t.evolution.hasOwnProperty("mitochondria")&&!t.race.evoFinalMenu,cost:{RNA:e=>Dr("mitochondria",75,50,e),DNA:e=>Dr("mitochondria",65,35,e)},effect:z("evo_mitochondria_effect"),action(){return!!ri($(this)[0])&&(t.evolution.mitochondria.count++,!0)}},sexual_reproduction:{id:"evolution-sexual_reproduction",title:z("evo_sexual_reproduction_title"),desc:z("evo_sexual_reproduction_desc"),reqs:{evo:1},grant:["evo",2],condition:()=>t.tech.evo&&1===t.tech.evo,cost:{DNA:()=>150},effect:z("evo_sexual_reproduction_effect"),action(){return!!ri($(this)[0])&&(t.evolution.final=20,!0)},queue_complete:()=>t.tech.evo&&1===t.tech.evo?1:0},phagocytosis:{id:"evolution-phagocytosis",title:z("evo_phagocytosis_title"),desc:z("evo_phagocytosis_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>t.tech.evo&&2===t.tech.evo,cost:{DNA:()=>175},effect:z("evo_phagocytosis_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_animal=1,t.evolution.final=40,!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0},chloroplasts:{id:"evolution-chloroplasts",title:()=>t.evolution.gselect?z("genelab_genus_plant"):z("evo_chloroplasts_title"),desc:z("evo_chloroplasts_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>zr(2),cost:{DNA:()=>175},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_chloroplasts_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_chloroplasts_effect"),action(){return!!ri($(this)[0])&&(t.evolution.gselect?(t.tech.evo=7,t.tech.evo_plant=2,t.evolution.final=100):(t.tech.evo_plant=1,t.evolution.final=40),!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Xs("genus_plant")},chitin:{id:"evolution-chitin",title:()=>t.evolution.gselect?z("genelab_genus_fungi"):z("evo_chitin_title"),desc:z("evo_chitin_desc"),reqs:{evo:2},grant:["evo",3],condition:()=>zr(2),cost:{DNA:()=>175},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_chitin_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_chitin_effect"),action(){return!!ri($(this)[0])&&(t.evolution.gselect?(t.tech.evo=7,t.tech.evo_fungi=2,t.evolution.final=100):(t.tech.evo_fungi=1,t.evolution.final=40),!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Xs("genus_fungi")},exterminate:{id:"evolution-exterminate",title:()=>t.evolution.gselect?z("genelab_genus_synthetic"):z("evo_exterminate_title"),desc:z("evo_exterminate_desc"),reqs:{evo:2},grant:["evo",7],condition:()=>zr(2)&&t.stats.achieve.obsolete&&t.stats.achieve.obsolete.l>=5,cost:{DNA:()=>200},effect:()=>z("evo_exterminate_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_synthetic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&2===t.tech.evo?1:0,emblem:()=>Xs("genus_synthetic")},multicellular:{id:"evolution-multicellular",title:z("evo_multicellular_title"),desc:z("evo_multicellular_desc"),reqs:{evo:3},grant:["evo",4],condition:()=>t.tech.evo&&3===t.tech.evo,cost:{DNA:()=>200},effect:z("evo_multicellular_effect"),action(){return!!ri($(this)[0])&&(t.evolution.final=60,!0)},queue_complete:()=>t.tech.evo&&3===t.tech.evo?1:0},spores:{id:"evolution-spores",title:z("evo_spores_title"),desc:z("evo_spores_desc"),reqs:{evo:4,evo_fungi:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:z("evo_nucleus_boost"),action(){return!!ri($(this)[0])&&(t.evolution.final=80,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},poikilohydric:{id:"evolution-poikilohydric",title:z("evo_poikilohydric_title"),desc:z("evo_poikilohydric_desc"),reqs:{evo:4,evo_plant:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:z("evo_nucleus_boost"),action(){return!!ri($(this)[0])&&(t.evolution.final=80,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},bilateral_symmetry:{id:"evolution-bilateral_symmetry",title:z("evo_bilateral_symmetry_title"),desc:z("evo_bilateral_symmetry_desc"),reqs:{evo:4,evo_animal:1},grant:["evo",5],condition:()=>t.tech.evo&&4===t.tech.evo,cost:{DNA:()=>230},effect:z("evo_nucleus_boost"),action(){return!!ri($(this)[0])&&(t.evolution.final=80,t.tech.evo_insectoid=1,t.tech.evo_mammals=1,t.tech.evo_eggshell=1,t.tech.evo_eldritch=1,t.tech.evo_aquatic=1,t.tech.evo_fey=1,t.tech.evo_sand=1,t.tech.evo_heat=1,t.tech.evo_polar=1,!0)},queue_complete:()=>t.tech.evo&&4===t.tech.evo?1:0},bryophyte:{id:"evolution-bryophyte",title:z("evo_bryophyte_title"),desc:z("evo_bryophyte_desc"),reqs:{evo:5},grant:["evo",7],condition:()=>!(!t.tech.evo_plant&&!t.tech.evo_fungi)&&zr(5),cost:{DNA:()=>260},effect:z("evo_bryophyte_effect"),action(){return!!ri($(this)[0])&&(t.evolution.final=100,t.tech.evo_fungi&&(t.tech.evo_fungi=2),t.tech.evo_plant&&(t.tech.evo_plant=2),!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},athropods:{id:"evolution-athropods",title:z("evo_athropods_title"),desc:z("evo_athropods_desc"),reqs:{evo:5,evo_insectoid:1},grant:["evo",7],condition:()=>zr(5),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_athropods_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_athropods_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_insectoid=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_insectoid")},mammals:{id:"evolution-mammals",title:z("evo_mammals_title"),desc:z("evo_mammals_desc"),reqs:{evo:5,evo_mammals:1},grant:["evo",6],condition:()=>t.tech.evo&&5===t.tech.evo,cost:{DNA:()=>245},effect:z("evo_mammals_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_humanoid=1,t.tech.evo_giant=1,t.tech.evo_small=1,t.tech.evo_animalism=1,t.tech.evo_demonic=1,t.tech.evo_angelic=1,t.evolution.final=90,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},humanoid:{id:"evolution-humanoid",title:z("evo_humanoid_title"),desc:z("evo_humanoid_desc"),reqs:{evo:6,evo_humanoid:1},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_humanoid_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_humanoid_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_humanoid=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_humanoid")},gigantism:{id:"evolution-gigantism",title:z("evo_gigantism_title"),desc:z("evo_gigantism_desc"),reqs:{evo:6,evo_giant:1},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_gigantism_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_gigantism_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_giant=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_giant")},dwarfism:{id:"evolution-dwarfism",title:z("evo_dwarfism_title"),desc:z("evo_dwarfism_desc"),reqs:{evo:6,evo_small:1},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_dwarfism_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_dwarfism_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_small=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_small")},animalism:{id:"evolution-animalism",title:z("evo_animalism_title"),desc:z("evo_animalism_desc"),reqs:{evo:6,evo_animalism:1},grant:["evo",7],condition:()=>zr(6)&&t.tech.evo_animalism&&1===t.tech.evo_animalism,cost:{DNA:()=>250},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_animalism_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_animalism_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_animalism=2,t.evolution.final=95,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo&&1===t.tech.evo_animalism?1:0},carnivore:{id:"evolution-carnivore",title:z("evo_carnivore_title"),desc:z("evo_carnivore_desc"),reqs:{evo_animalism:2},grant:["evo_animalism",3],condition:()=>zr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_carnivore_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_carnivore_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo=7,t.tech.evo_carnivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Xs("genus_carnivore")},herbivore:{id:"evolution-herbivore",title:z("evo_herbivore_title"),desc:z("evo_herbivore_desc"),reqs:{evo_animalism:2},grant:["evo_animalism",3],condition:()=>zr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_herbivore_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_herbivore_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo=7,t.tech.evo_herbivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Xs("genus_herbivore")},omnivore:{id:"evolution-omnivore",title:z("evo_omnivore_title"),desc:z("evo_omnivore_desc"),reqs:{evo_animalism:2,locked:1},grant:["evo_animalism",3],condition:()=>zr(7)&&t.tech.evo_animalism&&2===t.tech.evo_animalism,cost:{DNA:()=>255},wiki:!1,effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_omnivore_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_omnivore_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_omnivore=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&7===t.tech.evo&&2===t.tech.evo_animalism?1:0,emblem:()=>Xs("genus_omnivore")},celestial:{id:"evolution-celestial",title:z("evo_celestial_title"),desc:z("evo_celestial_desc"),reqs:{evo:6,evo_angelic:1},grant:["evo",7],condition:()=>!!("eden"===t.city.biome||t.blood.unbound&&t.blood.unbound>=3)&&zr(6),cost:{DNA:()=>260},effect:()=>z("evo_celestial_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_angelic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_angelic")},demonic:{id:"evolution-demonic",title:z("evo_demonic_title"),desc:z("evo_demonic_desc"),reqs:{evo:6,evo_demonic:1},grant:["evo",7],condition:()=>!!("hellscape"===t.city.biome||t.blood.unbound&&t.blood.unbound>=3)&&zr(6),cost:{DNA:()=>260},effect:()=>"hellscape"===t.city.biome&&"evil"===t.race.universe?`
                            ${z("evo_demonic_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_demonic_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_demonic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_demonic")},eldritch:{id:"evolution-eldritch",title:z("evo_eldritch_title"),desc:z("evo_eldritch_desc"),reqs:{evo:5,evo_eldritch:1},grant:["evo",7],condition:()=>!(!t.stats.achieve.nightmare||!t.stats.achieve.nightmare.mg)&&zr(5),cost:{DNA:()=>260},effect:z("evo_eldritch_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_eldritch=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_eldritch")},aquatic:{id:"evolution-aquatic",title:z("evo_aquatic_title"),desc:z("evo_aquatic_desc"),reqs:{evo:5,evo_aquatic:1},grant:["evo",7],condition:()=>!(!["oceanic","swamp"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_aquatic_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_aquatic=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_aquatic")},fey:{id:"evolution-fey",title:z("evo_fey_title"),desc:z("evo_fey_desc"),reqs:{evo:5,evo_fey:1},grant:["evo",7],condition:()=>!(!["forest","swamp","taiga"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_fey_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_fey=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_fey")},heat:{id:"evolution-heat",title:z("evo_heat_title"),desc:z("evo_heat_desc"),reqs:{evo:5,evo_heat:1},grant:["evo",7],condition:()=>!(!["volcanic","ashland"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_heat_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_heat=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_heat")},polar:{id:"evolution-polar",title:z("evo_polar_title"),desc:z("evo_polar_desc"),reqs:{evo:5,evo_polar:1},grant:["evo",7],condition:()=>!(!["tundra","taiga"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_polar_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_polar=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_polar")},sand:{id:"evolution-sand",title:z("evo_sand_title"),desc:z("evo_sand_desc"),reqs:{evo:5,evo_sand:1},grant:["evo",7],condition:()=>!(!["desert","ashland"].includes(t.city.biome)&&!t.blood.unbound)&&zr(5),cost:{DNA:()=>260},effect:z("evo_sand_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_sand=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0,emblem:()=>Xs("genus_sand")},eggshell:{id:"evolution-eggshell",title:z("evo_eggshell_title"),desc:z("evo_eggshell_desc"),reqs:{evo:5,evo_eggshell:1},grant:["evo",6],condition:()=>t.tech.evo&&5===t.tech.evo&&!t.evolution.gselect,cost:{DNA:()=>245},effect:()=>"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_eggshell_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_eggshell_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_eggshell=2,t.evolution.final=90,!0)},queue_complete:()=>t.tech.evo&&5===t.tech.evo?1:0},endothermic:{id:"evolution-endothermic",title:()=>t.evolution.gselect?z("genelab_genus_avian"):z("evo_endothermic_title"),desc:z("evo_endothermic_desc"),reqs:{evo:6,evo_eggshell:2},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:z("evo_endothermic_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_avian=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_avian")},ectothermic:{id:"evolution-ectothermic",title:()=>t.evolution.gselect?z("genelab_genus_reptilian"):z("evo_ectothermic_title"),desc:z("evo_ectothermic_desc"),reqs:{evo:6,evo_eggshell:2},grant:["evo",7],condition:()=>zr(6),cost:{DNA:()=>260},effect:z("evo_ectothermic_effect"),action(){return!!ri($(this)[0])&&(t.tech.evo_reptilian=2,t.evolution.final=100,!0)},queue_complete:()=>t.tech.evo&&6===t.tech.evo?1:0,emblem:()=>Xs("genus_reptilian")},sentience:{id:"evolution-sentience",title:z("evo_sentience_title"),desc:z("evo_sentience_desc"),reqs:{evo:7},grant:["evo",8],condition:()=>t.tech.evo&&7===t.tech.evo&&100===t.evolution.final,cost:{RNA:()=>300,DNA:()=>300},effect:()=>t.evolution.exterminate?z("evo_sentience_ai_effect"):z("evo_sentience_effect"),action(){if(ri($(this)[0])){let e=[],a="humanoid";for(let e in Li)if(t.tech[`evo_${e}`]&&t.tech[`evo_${e}`]>=2){a=e;break}if(t.race.junker||t.race.sludge){let r=t.race.sludge?"sludge":"junker";t.race.jtype=a,e.push(r)}else for(let t in Fr){let r=Fr[t];Ki[r].type===a&&e.push(r)}t.race.species=e[Math.floor(m(0,e.length))],t.stats.achieve[`extinct_${t.race.species}`]&&t.stats.achieve[`extinct_${t.race.species}`].l>=1&&(t.race.species=e[Math.floor(m(0,e.length))]),hi()}return!1},emblem(){for(let e in Fr){let a=Fr[e];if(t.tech[`evo_${Ki[a].type}`]&&t.tech[`evo_${Ki[a].type}`]>=2)return Xs(`genus_${Ki[a].type}`)}return""},queue_complete:()=>t.tech.evo&&7===t.tech.evo?1:0}},city:{gift:{id:"city-gift",title:z("city_gift"),desc:z("city_gift_desc"),wiki:!1,category:"outskirts",reqs:{primitive:1},queue_complete:()=>0,not_tech:["santa"],not_trait:["cataclysm","lone_survivor"],class:["hgift"],condition(){const e=new Date;if(11!==e.getMonth()||11===e.getMonth()&&(e.getDate()<=16||e.getDate()>=25)){let e=!1;return t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(a){t.special.gift[a]&&(e=!0)})),e}return!1},count(){let e=0;return t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(a){t.special.gift[a]&&e++})),e},action(){if(!t.settings.pause){const e=new Date;let a=!1;if(t.special&&t.special.gift&&Object.keys(t.special.gift).forEach((function(e){t.special.gift[e]&&(a=e)})),11!==e.getMonth()||11===e.getMonth()&&(e.getDate()<=16||e.getDate()>=25))if("g2019"===a)t.special&&t.special.gift&&(delete t.special.gift[a],"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=100,t.stats.antiplasmid+=100,hs(z("city_gift_msg",[100,z("arpa_genepool_effect_antiplasmid")]),"info",!1,["events"])):(t.prestige.Plasmid.count+=100,t.stats.plasmid+=100,hs(z("city_gift_msg",[100,z("arpa_genepool_effect_plasmid")]),"info",!1,["events"])),Wr());else if(t.special&&t.special.gift){delete t.special.gift[a];let e=100+(t.stats.hasOwnProperty("reset")?t.stats.reset:0)+(t.stats.hasOwnProperty("mad")?t.stats.mad:0),r=(t.stats.hasOwnProperty("bioseed")?t.stats.bioseed:0)+(t.stats.hasOwnProperty("cataclysm")?t.stats.cataclysm:0),i=[];if(t.stats.died+t.stats.tdied>0){let e=t.stats.died+t.stats.tdied;t.resource.Coal.amount+=e,i.push(`${e.toLocaleString()} ${z("resource_Coal_name")}`)}if("antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=e,t.stats.antiplasmid+=e,i.push(`${e.toLocaleString()} ${z("resource_AntiPlasmid_plural_name")}`)):(t.prestige.Plasmid.count+=e,t.stats.plasmid+=e,i.push(`${e.toLocaleString()} ${z("resource_Plasmid_plural_name")}`)),r>0&&(t.prestige.Phage.count+=r,t.stats.phage+=r,i.push(`${r.toLocaleString()} ${z("resource_Phage_name")}`)),t.stats.hasOwnProperty("achieve")){let e=t.stats.achieve.whitehole?t.stats.achieve.whitehole.l:0;e+=t.stats.achieve.heavy?t.stats.achieve.heavy.l:0,e+=t.stats.achieve.canceled?t.stats.achieve.canceled.l:0,e+=t.stats.achieve.eviltwin?t.stats.achieve.eviltwin.l:0,e+=t.stats.achieve.microbang?t.stats.achieve.microbang.l:0,e+=t.stats.achieve.pw_apocalypse?t.stats.achieve.pw_apocalypse.l:0;let r=t.stats.achieve.ascended?t.stats.achieve.ascended.l:0,s=t.stats.achieve.corrupted?t.stats.achieve.corrupted.l:0,n=t.stats.achieve.obsolete?t.stats.achieve.obsolete.l:0;if(e>30&&(e=30),r>5&&(r=5),s>5&&(s=5),e>0){let a=+(e/7.5).toFixed(2);t.prestige.Dark.count+=a,t.stats.dark+=a,i.push(`${a} ${z("resource_Dark_name")}`)}if(r>0&&(t.prestige.Harmony.count+=r,t.stats.harmony+=r,i.push(`${r} ${z("resource_Harmony_name")}`)),s>0){let e=5*s,a=s;t.prestige.Blood_Stone.count+=e,t.stats.blood+=e,t.prestige.Artifact.count+=a,t.stats.artifact+=a,i.push(`${e} ${z("resource_Blood_Stone_name")}`),i.push(`${a} ${z("resource_Artifact_name")}`)}"g2020"!==a&&n>0&&(t.prestige.AICore.count+=n,t.stats.cores+=n,i.push(`${n} ${z("resource_AICore_name")}`))}hs(z("city_gift2_msg",[i.join(", ")]),"info",!1,["events"]),Wr()}}return!1},touchlabel:z("open")},food:{id:"city-food",title:()=>ln().active?t.tech.conjuring?z("city_trick_conjure"):z("city_trick"):t.tech.conjuring?z("city_food_conjure"):z("city_food"),desc(){let e=$(this)[0].val(!1);return ln().active?t.tech.conjuring?z("city_trick_conjure_desc",[e]):z("city_trick_desc",[e]):t.tech.conjuring?z("city_food_conjure_desc",[e]):z("city_food_desc",[e])},category:"outskirts",reqs:{primitive:1},not_trait:["soul_eater","cataclysm","artifical"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring?1:0},action(){return t.settings.pause||(t.resource.Food.amount=1&&(a*=10,t.resource.Food.amountln().active?t.tech.conjuring&&t.tech.conjuring>=2?z("city_dig_conjour"):z("city_dig"):t.tech.conjuring&&t.tech.conjuring>=2?z("city_lumber_conjure"):z("city_lumber"),desc(){let e=$(this)[0].val(!1);return ln().active?t.tech.conjuring&&t.tech.conjuring>=2?z("city_dig_conjour_desc",[e]):z("city_dig_desc",[e]):t.tech.conjuring&&t.tech.conjuring>=2?z("city_lumber_conjure_desc",[e]):z("city_lumber_desc",[e])},category:"outskirts",reqs:{},not_trait:["evil","cataclysm"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||(t.resource.Lumber.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Lumber.amountt.tech.conjuring&&t.tech.conjuring>=2?z("city_conjour",[t.resource.Stone.name]):z("city_gather",[t.resource.Stone.name]),desc(){let e=$(this)[0].val(!1);return t.tech.conjuring&&t.tech.conjuring>=2?z("city_stone_conjour_desc",[e,t.resource.Stone.name]):z(t.race.sappy?"city_amber_desc":"city_stone_desc",[e,t.resource.Stone.name])},category:"outskirts",reqs:{primitive:2},not_trait:["cataclysm","lone_survivor"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||(t.resource.Stone.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Stone.amountt.tech.conjuring&&t.tech.conjuring>=2?z("city_chrysotile_conjour"):z("city_gather",[t.resource.Chrysotile.name]),desc(){let e=$(this)[0].val(!1);return t.tech.conjuring&&t.tech.conjuring>=2?z("city_stone_conjour_desc",[e,t.resource.Chrysotile.name]):z("city_stone_desc",[e,t.resource.Chrysotile.name])},category:"outskirts",reqs:{primitive:2},trait:["smoldering"],not_trait:["cataclysm","lone_survivor"],queue_complete:()=>0,cost:{Mana:()=>t.tech.conjuring&&t.tech.conjuring>=2?1:0},action(){return t.settings.pause||t.resource.Chrysotile.amount=2&&t.resource.Mana.amount>=1&&(a*=10,t.resource.Chrysotile.amountt.race.soul_eater?t.tech.primitive?t.resource.hasOwnProperty("furs")&&t.resource.Furs.display?z("city_evil_desc3"):z("city_evil_desc2"):z("city_evil_desc1"):t.resource.hasOwnProperty("furs")&&t.resource.Furs.display?z("city_evil_desc4"):z("city_evil_desc1"),category:"outskirts",reqs:{},trait:["evil"],not_trait:["kindling_kindred","smoldering","cataclysm"],queue_complete:()=>0,action(){if(!t.settings.pause){let e=t.race.strong?Ei.strong.vars()[0]:1;t.genes.enhance&&(e*=2),t.race.smoldering||(t.resource.Lumber.amount25e3},queue_complete:()=>t.city.slave_pen?4*t.city.slave_pen.count-t.city.slave_pen.slaves:0,action(){return!!(t.city.slave_pen&&4*t.city.slave_pen.count>t.city.slave_pen.slaves&&ri($(this)[0]))&&(t.city.slave_pen.slaves++,t.resource.Slave.amount=t.city.slave_pen.slaves,!0)},touchlabel:z("purchase")},s_alter:{id:"city-s_alter",title:z("city_s_alter"),desc:()=>t.city.hasOwnProperty("s_alter")&&t.city.s_alter.count>=1?`
                            ${z("city_s_alter")}
                            ${z("city_s_alter_desc")}
                            `:z("city_s_alter"),category:"outskirts",reqs:{mining:1},trait:["cannibalize"],not_trait:["cataclysm","lone_survivor"],inflation:!1,cost:{Stone:e=>(e||0)+(t.city.hasOwnProperty("s_alter")?t.city.s_alter.count:0)>=1?0:100},effect(){let e=`
                            ${z("city_s_alter_sacrifice",[t.civic[t.civic.d_job]?t.civic[t.civic.d_job].workers:0])}
                            `;if(t.city.hasOwnProperty("s_alter")&&t.city.s_alter.rage>0&&(e+=`
                            ${z("city_s_alter_rage",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.rage)])}
                            `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.regen>0&&(e+=`
                            ${z("city_s_alter_regen",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.regen)])}
                            `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.mind>0&&(e+=`
                            ${z("city_s_alter_mind",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.mind)])}
                            `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.mine>0&&(e+=`
                            ${z("city_s_alter_mine",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.mine)])}
                            `),t.city.hasOwnProperty("s_alter")&&t.city.s_alter.harvest>0){let a=t.race.evil&&!t.race.soul_eater?z("job_reclaimer"):z("job_lumberjack");e+=`
                            ${z("city_s_alter_harvest",[Ei.cannibalize.vars()[0],zs(t.city.s_alter.harvest),a])}
                            `}return e},action(){if(ri($(this)[0])){if(0===t.city.s_alter.count)t.city.s_alter.count++;else if(t.civic[t.civic.d_job].workers>0){t.resource[t.race.species].amount--,t.civic[t.civic.d_job].workers--,t.stats.sac++,t.resource.Food.amount+=Math.rand(250,1e3);let e=300,a=600;if(t.tech.sacrifice)switch(t.tech.sacrifice){case 1:e=600,a=1500;break;case 2:e=1800,a=3600;break;case 3:e=5400,a=16200}switch(t.race.kindling_kindred||t.race.smoldering?Math.rand(0,4):Math.rand(0,5)){case 0:t.city.s_alter.rage+=Math.rand(e,a);break;case 1:t.city.s_alter.mind+=Math.rand(e,a);break;case 2:t.city.s_alter.regen+=Math.rand(e,a);break;case 3:t.city.s_alter.mine+=Math.rand(e,a);break;case 4:t.city.s_alter.harvest+=Math.rand(e,a)}}return!0}return!1},touchlabel:z("tech_dist_sacrifice")},basic_housing:{id:"city-basic_housing",title:()=>di(),desc:z("city_basic_housing_desc"),desc(){return 1===$(this)[0].citizens()?z("city_basic_housing_desc"):z("city_basic_housing_desc_plural",[$(this)[0].citizens()])},category:"residential",reqs:{housing:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.basic_housing?t.city.basic_housing.count:0)+e>=5?qs("basic_housing",e,20,1.17):0),Lumber:e=>t.race.kindling_kindred||t.race.smoldering?0:qs("basic_housing",e,10,1.23),Stone:e=>t.race.kindling_kindred?qs("basic_housing",e,10,1.23):0,Chrysotile:e=>t.race.smoldering?qs("basic_housing",e,10,1.23):0,Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.sappy?`
                            ${z("plus_max_resource",[e,z("citizen")])}
                            ${z("city_grove_effect",[2.5])}
                            `:z("plus_max_resource",[e,z("citizen")])},action(){return!!ri($(this)[0])&&(t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=$(this)[0].citizens(),t.city.basic_housing.count++,t.settings.showCivic=!0,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},cottage:{id:"city-cottage",title:()=>pi("medium"),desc(){return z("city_cottage_desc",[$(this)[0].citizens()])},category:"residential",reqs:{housing:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("cottage",e,900,1.15),Plywood:e=>qs("cottage",e,25,1.25),Brick:e=>qs("cottage",e,20,1.25),Wrought_Iron:e=>qs("cottage",e,15,1.25),Iron:e=>t.city.ptrait.includes("unstable")?qs("cottage",e,5,1.25):0,Horseshoe:()=>t.race.hooved?2:0},effect(){let e=$(this)[0].citizens();if(t.tech.home_safe){let a=br(t.tech.home_safe>=2?t.tech.home_safe>=3?5e3:2e3:1e3);return`
                            ${z("plus_max_citizens",[e])}
                            ${z("plus_max_resource",[`$${a.toLocaleString()}`,z("resource_Money_name")])}
                            `}return z("plus_max_citizens",[e])},action(){return!!ri($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens(),t.city.cottage.count++,!0)},citizens(){let e=2;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},apartment:{id:"city-apartment",title:()=>pi("large"),desc(){return`
                            ${z("city_apartment_desc",[$(this)[0].citizens()])}
                            ${z("requires_power")}
                            `},category:"residential",reqs:{housing:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("apartment",e,1750,1.26)-500,Crystal:e=>"magic"===t.race.universe?qs("apartment",e,25,1.22):0,Furs:e=>qs("apartment",e,725,1.32)-500,Copper:e=>qs("apartment",e,650,1.32)-500,Cement:e=>qs("apartment",e,700,1.32)-500,Steel:e=>qs("apartment",e,800,1.32)-500,Horseshoe:()=>t.race.hooved?5:0},effect(){let e=K("extravagant",2),a=$(this)[0].citizens();if(t.tech.home_safe){let r=br(t.tech.home_safe>=2?t.tech.home_safe>=3?1e4:5e3:2e3);return e&&(r*=2),`
                            ${z("plus_max_citizens",[a])}. ${z("minus_power",[$(this)[0].powered()])}
                            ${z("plus_max_resource",[`$${r.toLocaleString()}`,z("resource_Money_name")])}
                            `}return`${z("plus_max_citizens",[a])}. ${z("minus_power",[$(this)[0].powered()])}`},powered:()=>As(K("extravagant",1)||1),action(){return!!ri($(this)[0])&&(t.city.apartment.count++,Yr($(this)[0])&&(t.resource[t.race.species].max+=$(this)[0].citizens()),!0)},citizens(){let e=K("extravagant",2),a=e?5+e:5;return t.race.high_pop&&(a*=Ei.high_pop.vars()[0]),a}},lodge:{id:"city-lodge",title:z("city_lodge"),desc:()=>t.race.detritivore?z("city_lodge_desc_alt"):z("city_lodge_desc"),category:"residential",reqs:{housing:1,currency:1},not_trait:["cataclysm","lone_survivor"],condition:()=>!!((t.race.soul_eater||t.race.detritivore||t.race.artifical||t.race.unfathomable)&&t.tech.s_lodge||t.tech.hunting&&t.tech.hunting>=2),cost:{Money:e=>qs("lodge",e,50,1.32),Lumber:e=>qs("lodge",e,20,1.36),Stone:e=>qs("lodge",e,10,1.36),Horseshoe:()=>t.race.hooved?1:0},effect(){let e=$(this)[0].citizens();return t.race.carnivore&&!t.race.artifical?`
                            ${z("plus_max_resource",[e,z("citizen")])}
                            ${z("city_lodge_effect",[5])}
                            `:z("plus_max_resource",[e,z("citizen")])},action(){return!!ri($(this)[0])&&(t.city.lodge.count++,t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=1,t.settings.showCivic=!0,!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}},smokehouse:{id:"city-smokehouse",title:()=>t.race.hrt&&["wolven","vulpine"].includes(t.race.hrt)?z("city_smokehouse_easter"):z("city_smokehouse"),desc:z("city_smokehouse_desc"),category:"trade",reqs:{hunting:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("smokehouse",e,85,1.32),Lumber:e=>qs("smokehouse",e,65,1.36),Stone:e=>qs("smokehouse",e,50,1.36)},effect:()=>`
                            ${z("plus_max_resource",[Br(br(100)),z("resource_Food_name")])}
                            ${z("city_smokehouse_effect",[10])}
                            `,action(){return!!ri($(this)[0])&&(t.city.smokehouse.count++,t.resource.Food.max+=Br(br(100)),!0)}},soul_well:{id:"city-soul_well",title:z("city_soul_well"),desc:z("city_soul_well_desc"),category:"trade",reqs:{soul_eater:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.soul_well?t.city.soul_well.count:0)+e>=3?qs("soul_well",e,50,1.32):0),Lumber:e=>qs("soul_well",e,20,1.36),Stone:e=>qs("soul_well",e,10,1.36)},effect(){let e=Br(br(500));return`
                            ${z("city_soul_well_effect",[t.race.ghostly?2+Ei.ghostly.vars()[1]:2])}
                            ${z("plus_max_resource",[e,z("resource_Souls_name")])}
                            `},action(){return!!ri($(this)[0])&&(t.city.soul_well.count++,t.resource.Food.max+=Br(br(500)),!0)}},slave_pen:{id:"city-slave_pen",title:z("city_slave_pen"),desc:z("city_slave_pen"),category:"commercial",reqs:{slaves:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("slave_pen",e,250,1.32),Lumber:e=>qs("slave_pen",e,100,1.36),Stone:e=>qs("slave_pen",e,75,1.36),Copper:e=>qs("slave_pen",e,10,1.36),Nanite:e=>t.race.deconstructor?qs("slave_pen",e,4,1.36):0},effect(){let e=t.city.slave_pen?4*t.city.slave_pen.count:4,a=t.city.slave_pen?t.city.slave_pen.slaves:0;return`
                            ${z("city_slave_pen_effect",[4])}
                            ${z("city_slave_pen_effect2",[a,e])}
                            `},action(){return!!ri($(this)[0])&&(t.city.slave_pen.count++,t.resource.Slave.display=!0,t.resource.Slave.amount=t.city.slave_pen.slaves,t.resource.Slave.max=4*t.city.slave_pen.count,!0)}},transmitter:{id:"city-transmitter",title:z("city_transmitter"),desc:()=>`
                            ${z("city_transmitter_desc")}
                            ${z("requires_power")}
                            `,category:"residential",reqs:{high_tech:4},trait:["artifical"],cost:{Money:e=>t.city.transmitter&&t.city.transmitter.count>=3?qs("transmitter",e,50,1.32):0,Copper:e=>qs("transmitter",e,20,1.36),Steel:e=>qs("transmitter",e,10,1.36)},effect(){let e=+$e("transmitter").toFixed(2),a=br(100);return`
                            ${z("gain",[e,t.resource.Food.name])}
                            ${z("city_transmitter_effect",[a])}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `},powered:()=>As(.5),powerBalancer:()=>[{r:"Food",k:"lpmod"}],action(){return!!ri($(this)[0])&&(t.city.transmitter.count++,Yr($(this)[0]),!0)}},captive_housing:Cr("captive_housing","city"),farm:{id:"city-farm",title:z("city_farm"),desc:z("city_farm_desc"),category:"residential",reqs:{agriculture:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.farm?t.city.farm.count:0)+e>=3?qs("farm",e,50,1.32):0),Lumber:e=>qs("farm",e,20,1.36),Stone:e=>qs("farm",e,10,1.36),Horseshoe:e=>t.race.hooved&&(t.city.farm?t.city.farm.count:0)+(e||0)>=2?1:0},effect(){let e=$(this)[0].citizens();return t.tech.farm?`
                            ${z("city_farm_effect")}
                            ${z("plus_max_resource",[e,z("citizen")])}
                            `:z("city_farm_effect")},action(){return!!ri($(this)[0])&&(t.city.farm.count++,t.civic.farmer.display=!0,t.tech.farm&&(t.resource[t.race.species].display=!0,t.resource[t.race.species].max+=$(this)[0].citizens(),t.settings.showCivic=!0),!0)},citizens(){let e=1;return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e},flair:()=>t.tech.agriculture>=7?z("city_farm_flair2"):z("city_farm_flair1")},compost:{id:"city-compost",title:z("city_compost_heap"),desc:z("city_compost_heap_desc"),category:"residential",reqs:{compost:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.compost?t.city.compost.count:0)+e>=3?qs("compost",e,50,1.32):0),Lumber:e=>qs("compost",e,12,1.36),Stone:e=>qs("compost",e,12,1.36)},effect(){let e=1.2+.8*(t.tech.compost?t.tech.compost:0);e*="grassland"===t.city.biome?is.grassland.vars()[0]:1,e*="savanna"===t.city.biome?is.savanna.vars()[0]:1,e*="ashland"===t.city.biome?is.ashland.vars()[0]:1,e*="volcanic"===t.city.biome?is.volcanic.vars()[0]:1,e*="hellscape"===t.city.biome?is.hellscape.vars()[0]:1,e*=t.city.ptrait.includes("trashed")?ss.trashed.vars()[0]:1,e=+e.toFixed(2);let a=Br(br(200)),r=t.race.kindling_kindred?"":`
                            ${z("city_compost_heap_effect2",[.5,t.resource.Lumber.name])}
                            `;return`
                            ${z("city_compost_heap_effect",[e])}
                            ${z("city_compost_heap_effect3",[a])}
                            ${r}`},switchable:()=>!0,action(){return!!ri($(this)[0])&&(t.city.compost.count++,t.city.compost.on++,t.resource.Food.max+=Br(br(200)),!0)}},mill:{id:"city-mill",title:()=>t.tech.agriculture>=5?z("city_mill_title2"):z("city_mill_title1"),desc(){let e=t.tech.agriculture>=5?5:3;return t.tech.agriculture>=6?z("city_mill_desc2",[e,-1*$(this)[0].powered()]):z("city_mill_desc1",[e])},category:"utility",reqs:{agriculture:4},not_tech:["wind_plant"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("mill",e,1e3,1.31),Lumber:e=>qs("mill",e,600,1.33),Iron:e=>qs("mill",e,150,1.33),Cement:e=>qs("mill",e,125,1.33)},powered:()=>t.race.environmentalist?-1.5:-1,power_reqs:{agriculture:6},effect:()=>t.tech.agriculture>=6&&`${z("city_on")} ${z("city_mill_effect1")} ${z("city_off")} ${z("city_mill_effect2")}`,action(){return!!ri($(this)[0])&&(t.city.mill.count++,!0)}},windmill:{id:"city-windmill",title:()=>t.race.unfathomable?z("tech_watermill"):z("city_mill_title2"),desc:()=>t.race.unfathomable?z("tech_watermill"):z("city_mill_title2"),wiki:!1,category:"utility",reqs:{wind_plant:1},not_trait:["cataclysm","lone_survivor"],powered:()=>t.race.environmentalist?-1.5:-1,power_reqs:{false:1},cost:{Money:e=>qs("windmill",e,1e3,1.31),Lumber:e=>qs("windmill",e,600,1.33),Iron:e=>qs("windmill",e,150,1.33),Cement:e=>qs("windmill",e,125,1.33)},effect(){return`
                            ${z("space_dwarf_reactor_effect1",[-1*$(this)[0].powered()])}
                            `},action(){return!!ri($(this)[0])&&(t.city.windmill.count++,!0)}},silo:{id:"city-silo",title:z("city_silo"),desc:z("city_food_storage"),category:"trade",reqs:{agriculture:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("silo",e,85,1.32),Lumber:e=>qs("silo",e,65,1.36),Stone:e=>qs("silo",e,50,1.36),Iron:e=>(t.city.silo?t.city.silo.count:0)+(e||0)>=4&&t.city.ptrait.includes("unstable")?qs("silo",e,10,1.36):0},effect:()=>z("plus_max_resource",[Br(br(500)),z("resource_Food_name")]),action(){return!!ri($(this)[0])&&(t.city.silo.count++,t.resource.Food.max+=Br(br(500)),!0)}},assembly:Cr("assembly","city"),garrison:{id:"city-garrison",title:()=>t.race.flier?z("city_garrison_flier"):z("city_garrison"),desc:z("city_garrison_desc"),category:"military",reqs:{military:1,housing:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("garrison",e,240,1.5),Stone:e=>qs("garrison",e,260,1.46),Iron:e=>(t.city.garrison?t.city.garrison.count:0)+(e||0)>=4&&t.city.ptrait.includes("unstable")?qs("garrison",e,50,1.4):0,Horseshoe:()=>t.race.hooved?t.race.chameleon?1:2:0},effect(){let e=t.tech.military>=5?ta(3):ta(2);return t.race.chameleon&&e--,z("plus_max_resource",[e,z("civics_garrison_soldiers")])},switchable:()=>!0,action(){if(ri($(this)[0])){t.settings.showMil=!0,t.settings.msgFilters.combat.unlocked||(t.settings.msgFilters.combat.unlocked=!0,t.settings.msgFilters.combat.vis=!0),t.civic.garrison.display||(t.civic.garrison.display=!0,Cs({el:"#garrison"},"update"),Cs({el:"#c_garrison"},"update"));let e=t.tech.military>=5?3:2;return t.race.chameleon&&(e-=t.city.garrison.count),t.civic.garrison.max+=e,t.city.garrison.count++,t.city.garrison.on++,t.resource.Furs.display=!0,!0}return!1}},hospital:{id:"city-hospital",title:z("city_hospital"),desc:z("city_hospital_desc"),category:"military",reqs:{medic:1},not_trait:["cataclysm","artifical"],cost:{Money:e=>qs("hospital",e,22e3,1.32),Furs:e=>qs("hospital",e,4e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?qs("hospital",e,500,1.32):0,Aluminium:e=>qs("hospital",e,1e4,1.32)},effect(){let e=t.tech.reproduction&&t.tech.reproduction>=2?`
                            ${z("city_hospital_effect2")}
                            `:"",a=`
                            ${z("city_hospital_effect",[5*t.tech.medic])}
                            ${e}`;return!t.race.artifical&&t.race.hasOwnProperty("vax")&&(a+=`
                            ${z("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
                            `),a},action(){return!!ri($(this)[0])&&(t.city.hospital.count++,!0)}},boot_camp:{id:"city-boot_camp",title:()=>t.race.artifical?z("city_boot_camp_art"):z("city_boot_camp"),desc:()=>t.race.artifical?z("city_boot_camp_art_desc",[Ki[t.race.species].name]):z("city_boot_camp_desc"),category:"military",reqs:{boot_camp:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("boot_camp",e,5e4,1.32),Lumber:e=>qs("boot_camp",e,21500,1.32),Iron:e=>t.city.ptrait.includes("unstable")?qs("boot_camp",e,300,1.32):0,Aluminium:e=>qs("boot_camp",e,12e3,1.32),Brick:e=>qs("boot_camp",e,1400,1.32)},effect(){let e=t.tech.boot_camp>=2?8:5;t.blood.lust&&(e+=.2*t.blood.lust);let a=K("militant",0);a&&(e*=1+a/100);let r=t.tech.spy&&t.tech.spy>=3?`
                            ${z("city_boot_camp_effect",[e])}
                            ${z("city_boot_camp_effect2",[10])}
                            `:`
                            ${z("city_boot_camp_effect",[e])}
                            `;return t.race.artifical&&!t.race.orbit_decayed&&(r+=`
                            ${z("city_boot_camp_art_effect",[5*(t.tech.medic||1)])}
                            `),t.race.artifical&&t.race.hasOwnProperty("vax")&&(desc+=`
                            ${z("tau_home_disease_lab_vax",[+t.race.vax.toFixed(2)])}
                            `),r},action(){return!!ri($(this)[0])&&(t.city.boot_camp.count++,!0)}},shed:{id:"city-shed",title:()=>t.tech.storage<=2?z("city_shed_title1"):t.tech.storage>=4?z("city_shed_title3"):z("city_shed_title2"),desc(){let e=t.tech.storage>=3?t.tech.storage>=4?z("city_shed_desc_size3"):z("city_shed_desc_size2"):z("city_shed_desc_size1");return z("city_shed_desc",[e])},category:"trade",reqs:{storage:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("shed",e,75,1.22),Lumber:e=>t.tech.storage&&t.tech.storage<4?qs("shed",e,55,1.32):0,Stone:e=>t.tech.storage&&t.tech.storage<3?qs("shed",e,45,1.32):0,Iron:e=>t.tech.storage&&t.tech.storage>=4?qs("shed",e,22,1.32):0,Cement:e=>t.tech.storage&&t.tech.storage>=3?qs("shed",e,18,1.32):0},res(){let e=["Lumber","Stone","Chrysotile","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal"];return t.tech.storage>=3&&t.resource.Steel.display&&e.push("Steel"),t.tech.storage>=4&&t.resource.Titanium.display&&e.push("Titanium"),t.tech.shelving&&t.tech.shelving>=3&&t.resource.Graphene.display&&e.push("Graphene"),t.tech.shelving&&t.tech.shelving>=3&&t.resource.Stanene.display&&e.push("Stanene"),t.race.unfathomable&&e.push("Food"),e},val(e){switch(e){case"Food":return 50;case"Lumber":case"Stone":case"Chrysotile":return 300;case"Crystal":return 8;case"Furs":case"Iron":return 125;case"Copper":case"Aluminium":return 90;case"Cement":return 100;case"Coal":return 75;case"Steel":return 40;case"Titanium":return 20;case"Graphene":return 15;case"Stanene":return 25;default:return 0}},effect(){let e='
                            ',a=Gr();for(const r of $(this)[0].res())t.resource[r].display&&(e+=`${z("plus_max_resource",[x(+(br($(this)[0].val(r))*a).toFixed(0),1),t.resource[r].name])}`);return e+="
                            ",e},wide:!0,action(){if(ri($(this)[0])){t.city.shed.count++;let e=Gr();for(const a of $(this)[0].res())t.resource[a].display&&(t.resource[a].max+=br($(this)[0].val(a)*e));return!0}return!1}},storage_yard:{id:"city-storage_yard",title:z("city_storage_yard"),desc:z("city_storage_yard_desc"),category:"trade",reqs:{container:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("storage_yard",e,10,yi(1.36)),Brick:e=>qs("storage_yard",e,3,yi(1.35)),Wrought_Iron:e=>qs("storage_yard",e,5,yi(1.35))},effect(){let e=t.tech.container>=3?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.tech.trade&&t.tech.trade>=3?`
                            ${z("plus_max_resource",[e,z("resource_Crates_name")])}
                            ${z("city_trade_effect",[1])}
                            `:z("plus_max_resource",[e,z("resource_Crates_name")])},action(){if(ri($(this)[0])){!1===t.resource.Crates.display&&hs(z("city_storage_yard_msg"),"info",!1,["progress"]),t.city.storage_yard.count++,t.settings.showResources=!0,t.settings.showStorage=!0,t.settings.showMarket||(t.settings.marketTabs=1);let e=t.tech.container>=3?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Crates.max+=e,t.resource.Crates.display||(t.resource.Crates.display=!0,Ss($("#resources")),Da(),t.settings.tabLoad&&(Ka("storage"),L())),!0}return!1}},warehouse:{id:"city-warehouse",title:z("city_warehouse"),desc:z("city_warehouse_desc"),category:"trade",reqs:{steel_container:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("warehouse",e,400,yi(1.26)),Cement:e=>qs("warehouse",e,75,yi(1.26)),Sheet_Metal:e=>qs("warehouse",e,25,yi(1.25))},effect(){let e=t.tech.steel_container>=2?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),z("plus_max_resource",[e,z("resource_Containers_name")])},action(){if(ri($(this)[0])){!1===t.resource.Containers.display&&hs(z("city_warehouse_msg"),"info",!1,["progress"]),t.city.warehouse.count++,t.settings.showResources=!0,t.settings.showStorage=!0;let e=t.tech.steel_container>=2?20:10;return t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2&&(e+=10),t.tech.world_control&&(e+=10),t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Containers.max+=e,t.resource.Containers.display||(t.resource.Containers.display=!0,Ss($("#resources")),Da(),t.settings.tabLoad&&Ka("storage")),!0}return!1}},bank:{id:"city-bank",title:z("city_bank"),desc:()=>z("city_bank_desc",[Ki[t.race.species].home]),category:"commercial",reqs:{banking:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("bank",e,250,1.35),Lumber:e=>qs("bank",e,75,1.32),Stone:e=>qs("bank",e,100,1.35),Iron:e=>(t.city.bank?t.city.bank.count:0)+(e||0)>=2&&t.city.ptrait.includes("unstable")?qs("bank",e,30,1.3):0},effect(){let e=bi();return e=br(e),e=(+e.toFixed(0)).toLocaleString(),t.tech.banking>=2?`
                            ${z("plus_max_resource",[`$${e}`,z("resource_Money_name")])}
                            ${z("plus_max_resource",[ta(1),z("banker_name")])}
                            `:z("plus_max_resource",[`$${e}`,z("resource_Money_name")])},action(){return!!ri($(this)[0])&&(t.resource.Money.max+=br(1800),t.city.bank.count++,t.civic.banker.max=ta(t.city.bank.count),!0)}},pylon:{id:"city-pylon",title:z("city_pylon"),desc:z("city_pylon"),category:"industrial",reqs:{magic:2},not_trait:["cataclysm","orbit_decayed"],cost:{Money:e=>(e=e||0,(t.city.pylon?t.city.pylon.count:0)+e>=2?qs("pylon",e,10,1.48):0),Stone:e=>qs("pylon",e,12,1.42),Crystal:e=>qs("pylon",e,8,1.42)-3},effect(){let e=br(5);return`
                            ${z("gain",[+(.01*Is("magic")).toFixed(3),t.resource.Mana.name])}
                            ${z("plus_max_resource",[e,t.resource.Mana.name])}
                            `},special:()=>!!(t.tech.magic&&t.tech.magic>=3),action(){return!!ri($(this)[0])&&(t.city.pylon.count++,t.resource.Mana.max+=br(5),!0)}},conceal_ward:{id:"city-conceal_ward",title:z("city_conceal_ward"),desc:z("city_conceal_ward"),category:"industrial",reqs:{roguemagic:3},not_trait:["cataclysm","orbit_decayed"],cost:{Money:e=>qs("conceal_ward",e,500,1.25),Mana:e=>{return qs("conceal_ward",e,(a=42,t.tech.nexus&&t.tech.roguemagic&&t.tech.roguemagic>=7&&(a*=.92**t.tech.nexus),a),1.25);var a},Crystal:e=>qs("conceal_ward",e,5,1.25)},effect:()=>`
                            ${z("city_conceal_ward_effect",[t.tech.roguemagic&&t.tech.roguemagic>=8?1.25:1])}
                            `,action(){return!!ri($(this)[0])&&(t.city.conceal_ward.count++,!0)}},graveyard:{id:"city-graveyard",title:z("city_graveyard"),desc:z("city_graveyard_desc"),category:"industrial",reqs:{reclaimer:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.graveyard?t.city.graveyard.count:0)+e>=5?qs("graveyard",e,5,1.85):0),Lumber:e=>qs("graveyard",e,2,1.95),Stone:e=>qs("graveyard",e,6,1.9)},effect(){let e=Br(br(100));return`
                            ${z("city_graveyard_effect",[8])}
                            ${z("plus_max_resource",[e,t.resource.Lumber.name])}
                            `},action(){return!!ri($(this)[0])&&(t.city.graveyard.count++,t.resource.Lumber.max+=Br(br(100)),!0)}},lumber_yard:{id:"city-lumber_yard",title:z("city_lumber_yard"),desc:z("city_lumber_yard_desc"),category:"industrial",reqs:{axe:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>(e=e||0,(t.city.lumber_yard?t.city.lumber_yard.count:0)+e>=5?qs("lumber_yard",e,5,1.85):0),Lumber:e=>qs("lumber_yard",e,6,1.9),Stone:e=>qs("lumber_yard",e,2,1.95)},effect(){let e=Br(br(100));return`
                            ${z("city_lumber_yard_effect",[2])}
                            ${z("plus_max_resource",[e,t.resource.Lumber.name])}
                            `},action(){return!!ri($(this)[0])&&(t.city.lumber_yard.count++,t.civic.lumberjack.display=!0,t.resource.Lumber.max+=Br(br(100)),!0)}},sawmill:{id:"city-sawmill",title:z("city_sawmill"),desc:z("city_sawmill_desc"),category:"industrial",reqs:{saw:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("sawmill",e,3e3,1.26),Iron:e=>qs("sawmill",e,400,1.26),Cement:e=>qs("sawmill",e,420,1.26)},effect(){let e=t.tech.saw>=2?8:5,a=`
                            ${z("plus_max_resource",[Br(br(200)),t.resource.Lumber.name])}
                            ${z("city_lumber_yard_effect",[e])}
                            `;return t.tech.foundry&&t.tech.foundry>=4&&(a+=`
                            ${z("city_sawmill_effect2",[2])}
                            `),t.city.powered&&(a+=`
                            ${z("city_sawmill_effect3",[4,$(this)[0].powered()])}
                            `),a},powered:()=>As(1),powerBalancer:()=>!!t.city.sawmill.hasOwnProperty("psaw")&&[{r:"Lumber",k:"psaw"}],action(){return!!ri($(this)[0])&&(t.city.sawmill.count++,t.resource.Lumber.max+=Br(br(200)),Yr($(this)[0]),!0)}},rock_quarry:{id:"city-rock_quarry",title:()=>t.race.flier?z("city_rock_quarry_alt"):z("city_rock_quarry"),desc:()=>t.race.flier?z("city_rock_quarry_desc_alt",[t.resource.Stone.name]):z("city_rock_quarry_desc"),category:"industrial",reqs:{mining:1},not_trait:["cataclysm","sappy"],cost:{Money:e=>(e=e||0,(t.city.rock_quarry?t.city.rock_quarry.count:0)+e>=2?qs("rock_quarry",e,20,1.45):0),Lumber:e=>qs("rock_quarry",e,50,1.36),Stone:e=>qs("rock_quarry",e,10,1.36)},effect(){let e=Br(br(100)),a=t.race.smoldering?`
                            ${z("plus_max_resource",[e,t.resource.Chrysotile.name])}
                            `:"";return t.tech.mine_conveyor?`
                            ${z("city_rock_quarry_effect1",[2])}
                            ${z("plus_max_resource",[e,t.resource.Stone.name])}
                            ${a}
                            ${z("city_rock_quarry_effect2",[4,$(this)[0].powered()])}
                            `:`
                            ${z("city_rock_quarry_effect1",[2])}
                            ${z("plus_max_resource",[e,t.resource.Stone.name])}
                            ${a}`},special:()=>!!t.race.smoldering,powered:()=>As(1),powerBalancer:()=>!!t.city.rock_quarry.hasOwnProperty("cnvay")&&(t.city.hasOwnProperty("metal_refinery")&&t.city.rock_quarry.hasOwnProperty("almcvy")?[{r:"Stone",k:"cnvay"},{r:"Aluminium",k:"almcvy"}]:[{r:"Stone",k:"cnvay"}]),power_reqs:{mine_conveyor:1},action(){if(ri($(this)[0])){t.city.rock_quarry.count++,t.civic.quarry_worker.display=!0;let e=Br(br(100));return t.resource.Stone.max+=e,t.race.smoldering&&t.resource.Chrysotile.display&&(t.settings.showCivic=!0,t.settings.showIndustry=!0,t.resource.Chrysotile.max+=e),t.tech.mine_conveyor&&Yr($(this)[0]),!0}return!1}},cement_plant:{id:"city-cement_plant",title:z("city_cement_plant"),desc:z("city_cement_plant_desc"),category:"industrial",reqs:{cement:1},not_trait:["cataclysm","lone_survivor","flier"],cost:{Money:e=>qs("cement_plant",e,3e3,1.5),Lumber:e=>qs("cement_plant",e,1800,1.36),Stone:e=>qs("cement_plant",e,2e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?qs("cement_plant",e,275,1.32):0},effect(){if(t.tech.cement>=5){let e=t.tech.cement>=6?8:5;return`
                            ${z("city_cement_plant_effect1",[ta(2)])}
                            ${z("city_cement_plant_effect2",[$(this)[0].powered(),e])}
                            `}return z("city_cement_plant_effect1",[ta(2)])},powered:()=>As(2),powerBalancer:()=>!!t.city.cement_plant.hasOwnProperty("cnvay")&&[{r:"Cement",k:"cnvay"}],power_reqs:{cement:5},action(){return!!ri($(this)[0])&&(t.resource.Cement.display=!0,t.city.cement_plant.count++,t.civic.cement_worker.display=!0,t.civic.cement_worker.max=t.city.cement_plant.count*ta(2),t.tech.cement&&t.tech.cement>=5&&Yr($(this)[0]),!0)}},foundry:{id:"city-foundry",title:z("city_foundry"),desc:z("city_foundry_desc"),category:"industrial",reqs:{foundry:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("foundry",e,750,1.36),Stone:e=>qs("foundry",e,100,1.36),Copper:e=>qs("foundry",e,250,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("foundry",e,40,1.36):0},effect(){let e=`
                            ${z("city_foundry_effect1",[ta(1)])}
                            `;return t.tech.foundry>=2&&(e+=`
                            ${z("city_crafted_mats",[t.tech.foundry>=5?t.tech.foundry>=8?8:5:3])}
                            `),t.tech.foundry>=6&&(e+=`
                            ${z("city_foundry_effect2",[2])}
                            `),e},action(){return!!ri($(this)[0])&&(0===t.city.foundry.count&&(t.race.no_craft?hs(z("city_foundry_msg2"),"info",!1,["progress"]):hs(z("city_foundry_msg1"),"info",!1,["progress"])),t.city.foundry.count++,t.civic.craftsman.max+=ta(1),t.civic.craftsman.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.resource.Plywood.display=!0),t.resource.Brick.display=!0,t.resource.Iron.display&&(t.resource.Wrought_Iron.display=!0),t.resource.Aluminium.display&&(t.resource.Sheet_Metal.display=!0),sa(),!0)}},factory:{id:"city-factory",title:z("city_factory"),desc:`
                            ${z("city_factory_desc")}
                            ${z("requires_power")}
                            `,category:"industrial",reqs:{high_tech:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("factory",e,25e3,ci(1.32)),Cement:e=>qs("factory",e,1e3,ci(1.32)),Steel:e=>qs("factory",e,7500,ci(1.32)),Titanium:e=>qs("factory",e,2500,ci(1.32))},effect(){let e=`
                            ${z("city_factory_effect")}
                            ${z("minus_power",[$(this)[0].powered()])}
                            `;return t.tech.foundry>=7&&(e+=`
                            ${z("city_crafted_mats",[5])}
                            `),e},powered:()=>As(3),special:!0,action(){return!!ri($(this)[0])&&(t.city.factory.count++,t.resource.Alloy.display=!0,t.tech.polymer&&(t.resource.Polymer.display=!0),Yr($(this)[0])&&t.city.factory.Alloy++,t.settings.showIndustry=!0,ki(),!0)}},nanite_factory:Cr("nanite_factory","city"),smelter:{id:"city-smelter",title:z("city_smelter"),desc:z("city_smelter_desc"),category:"industrial",reqs:{smelting:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("smelter",e,1e3,ci(1.32)),Iron:e=>qs("smelter",e,500,ci(1.33))},effect(){var e=t.tech.smelting>=3?t.tech.smelting>=7?15:12:10;return t.race.pyrophobia&&(e*=.9),t.tech.smelting>=2&&!t.race.steelen?z("city_smelter_effect2",[e]):z("city_smelter_effect1",[e])},special:!0,action(){return!!ri($(this)[0])&&(t.city.smelter.count++,t.race.kindling_kindred||t.race.smoldering||t.race.artifical?t.race.artifical?t.city.smelter.Oil++:t.race.evil?t.city.smelter.Wood++:t.city.smelter.Coal++:t.city.smelter.Wood++,t.city.smelter.Iron++,t.settings.showIndustry=!0,ki(),!0)},flair:`
                            ${z("city_smelter_flair1")}
                            ${z("city_smelter_flair2")}
                            `},metal_refinery:{id:"city-metal_refinery",title:z("city_metal_refinery"),desc:z("city_metal_refinery_desc"),category:"industrial",reqs:{alumina:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("metal_refinery",e,2500,1.35),Iron:e=>t.city.ptrait.includes("unstable")?qs("metal_refinery",e,125,1.35):0,Steel:e=>qs("metal_refinery",e,350,1.35)},powered:()=>As(2),powerBalancer:()=>!!t.city.metal_refinery.hasOwnProperty("pwr")&&[{r:"Aluminium",k:"cnvay"}],power_reqs:{alumina:2},effect(){let e=t.race.sappy?"city_metal_refinery_effect_alt":"city_metal_refinery_effect";return t.tech.alumina>=2?`${z(e,[6])} ${z("city_metal_refinery_effect2",[6,12,$(this)[0].powered()])}`:z(e,[6])},action(){return!!ri($(this)[0])&&(t.city.metal_refinery.count++,t.resource.Aluminium.display=!0,t.city.foundry&&t.city.foundry.count>0&&!t.resource.Sheet_Metal.display&&(t.resource.Sheet_Metal.display=!0,sa()),t.tech.alumina>=2&&Yr($(this)[0]),!0)}},mine:{id:"city-mine",title:z("city_mine"),desc:z("city_mine_desc"),category:"industrial",reqs:{mining:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("mine",e,60,ci(1.6)),Lumber:e=>qs("mine",e,175,ci(1.38))},effect(){return t.tech.mine_conveyor?`
                            ${z("city_mine_effect1",[ta(1)])}
                            ${z("city_mine_effect2",[$(this)[0].powered(),5])}
                            `:z("city_mine_effect1",[ta(1)])},powered:()=>As(1),powerBalancer:()=>!(!t.city.mine.hasOwnProperty("cpow")||!t.city.mine.hasOwnProperty("ipow"))&&[{r:"Copper",k:"cpow"},{r:"Iron",k:"ipow"}],power_reqs:{mine_conveyor:1},action(){return!!ri($(this)[0])&&(t.city.mine.count++,t.resource.Copper.display=!0,t.civic.miner.display=!0,t.civic.miner.max=ta(t.city.mine.count),t.tech.mine_conveyor&&Yr($(this)[0]),!0)},flair:()=>"avian"===Ki[t.race.species].type?z("city_mine_flair_avian"):""},coal_mine:{id:"city-coal_mine",title:z("city_coal_mine"),desc:z("city_coal_mine_desc"),category:"industrial",reqs:{mining:4},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("coal_mine",e,480,ci(1.4)),Lumber:e=>qs("coal_mine",e,250,ci(1.36)),Iron:e=>t.city.ptrait.includes("unstable")?qs("coal_mine",e,28,ci(1.36)):0,Wrought_Iron:e=>qs("coal_mine",e,18,ci(1.36))},effect(){return t.tech.mine_conveyor?`
                            ${z("city_coal_mine_effect1",[ta(1)])}
                            ${z("city_coal_mine_effect2",[$(this)[0].powered(),5])}
                            `:z("city_coal_mine_effect1",[ta(1)])},powered:()=>As(1),powerBalancer:()=>t.city.coal_mine.hasOwnProperty("cpow")&&t.city.coal_mine.hasOwnProperty("upow")&&t.resource.Uranium.display?[{r:"Coal",k:"cpow"},{r:"Uranium",k:"upow"}]:!!t.city.coal_mine.hasOwnProperty("cpow")&&[{r:"Coal",k:"cpow"}],power_reqs:{mine_conveyor:1},action(){return!!ri($(this)[0])&&(t.city.coal_mine.count++,t.resource.Coal.display=!0,t.civic.coal_miner.display=!0,t.civic.coal_miner.max=ta(t.city.coal_mine.count),t.tech.mine_conveyor&&Yr($(this)[0]),!0)}},oil_well:{id:"city-oil_well",title:z("city_oil_well"),desc:z("city_oil_well_desc"),category:"industrial",reqs:{oil:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("oil_well",e,5e3,ci(1.5)),Iron:e=>t.city.ptrait.includes("unstable")?qs("oil_well",e,450,ci(1.5)):0,Cement:e=>qs("oil_well",e,5250,ci(1.5)),Steel:e=>qs("oil_well",e,6e3,ci(1.5))},effect:()=>z("city_oil_well_effect",[+$e("oil_well").toFixed(2),br(500)]),action(){return!!ri($(this)[0])&&(t.city.oil_well.count++,t.resource.Oil.max+=br(500),1===t.city.oil_well.count&&(t.resource.Oil.display=!0,ki()),!0)},flair:z("city_oil_well_flair")},oil_depot:{id:"city-oil_depot",title:z("city_oil_depot"),desc:z("city_oil_depot_desc"),category:"trade",reqs:{oil:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("oil_depot",e,2500,ci(1.46)),Iron:e=>t.city.ptrait.includes("unstable")?qs("oil_depot",e,325,ci(1.36)):0,Cement:e=>qs("oil_depot",e,3750,ci(1.46)),Sheet_Metal:e=>qs("oil_depot",e,100,ci(1.45))},effect(){let e=br(1e3);e*=t.tech.world_control?1.5:1;let a=`
                            ${z("plus_max_resource",[e,t.resource.Oil.name])}.
                            `;if(t.resource.Helium_3.display){let e=br(400);e*=t.tech.world_control?1.5:1,a+=`
                            ${z("plus_max_resource",[e,t.resource.Helium_3.name])}.
                            `}if(t.tech.uranium>=2){let e=br(250);e*=t.tech.world_control?1.5:1,a+=`
                            ${z("plus_max_resource",[e,t.resource.Uranium.name])}.
                            `}return a},action(){return!!ri($(this)[0])&&(t.city.oil_depot.count++,t.resource.Oil.max+=br(1e3)*(t.tech.world_control?1.5:1),t.resource.Helium_3.display&&(t.resource.Helium_3.max+=br(400)*(t.tech.world_control?1.5:1)),t.tech.uranium>=2&&(t.resource.Uranium.max+=br(250)*(t.tech.world_control?1.5:1)),!0)}},trade:{id:"city-trade",title:z("city_trade"),desc:z("city_trade_desc"),category:"trade",reqs:{trade:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("trade",e,500,1.36),Lumber:e=>qs("trade",e,125,1.36),Stone:e=>qs("trade",e,50,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("trade",e,15,1.36):0,Furs:e=>qs("trade",e,65,1.36)},effect(){let e=t.race.xenophobic||t.race.nomadic?t.tech.trade:t.tech.trade+1;return t.tech.trade&&t.tech.trade>=3&&e--,t.race.flier&&(e+=Ei.flier.vars()[1]),z("city_trade_effect",[e])},action(){if(ri($(this)[0])){t.city.trade.count++;let e=t.race.xenophobic||t.race.nomadic?t.tech.trade:t.tech.trade+1;return t.tech.trade&&t.tech.trade>=3&&e--,t.city.market.mtrade+=e,!0}return!1}},wharf:{id:"city-wharf",title:z("city_wharf"),desc:z("city_wharf_desc"),category:"trade",era:"industrialized",reqs:{wharf:1},not_trait:["thalassophobia","cataclysm"],cost:{Money:e=>qs("wharf",e,62e3,1.32),Lumber:e=>qs("wharf",e,44e3,1.32),Iron:e=>t.city.ptrait.includes("unstable")?qs("wharf",e,200,1.32):0,Cement:e=>qs("wharf",e,3e3,1.32),Oil:e=>qs("wharf",e,750,1.32)},effect(){let e=t.tech.world_control?15:10;return t.tech.particles&&t.tech.particles>=2&&(e*=2),`
                            ${z("city_trade_effect",[2])}
                            ${z("city_wharf_effect")}
                            ${z("plus_max_crates",[e])}
                            ${z("plus_max_containers",[e])}
                            `},action(){if(ri($(this)[0])){!1===t.resource.Containers.display&&(hs(z("city_warehouse_msg"),"info",!1,["progress"]),t.resource.Containers.display=!0,Ss($("#resources")),Da()),t.city.wharf.count++,t.city.market.mtrade+=2;let e=t.tech.world_control?15:10;return t.tech.particles&&t.tech.particles>=2&&(e*=2),t.resource.Crates.max+=e,t.resource.Containers.max+=e,!0}return!1}},tourist_center:{id:"city-tourist_center",title:z("city_tourist_center"),desc:z("city_tourist_center_desc"),category:"commercial",reqs:{monument:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("tourist_center",e,1e5,1.36),Stone:e=>qs("tourist_center",e,25e3,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("tourist_center",e,1e3,1.36):0,Furs:e=>qs("tourist_center",e,7500,1.36),Plywood:e=>qs("tourist_center",e,5e3,1.36)},effect(){let e=t.tech.monument&&t.tech.monument>=3&&s.s_gate?3:1,a=("corpocracy"===t.civic.govern.type?2:1)*e,r=("corpocracy"===t.civic.govern.type?10:5)*e,i=("corpocracy"===t.civic.govern.type?4:2)*e,n="";t.stats.achieve.banana&&t.stats.achieve.banana.l>=4&&(n=`
                            ${z("city_tourist_center_effect5",[("corpocracy"===t.civic.govern.type?6:3)*e])}
                            `);let c="",o=K("pious",1);return o&&(c=`
                            ${z("city_tourist_center_effect6",[("corpocracy"===t.civic.govern.type?2*o:o)*e])}
                            `),`
                            ${z("city_tourist_center_effect1",[t.resource.Food.name])}
                            ${z("city_tourist_center_effect2",[a,Mr.city.amphitheatre.title()])}
                            ${z("city_tourist_center_effect3",[r])}
                            ${z("city_tourist_center_effect4",[i])}
                            ${n}${c}`},powered:()=>As(1),action(){return!!ri($(this)[0])&&(t.city.tourist_center.count++,t.city.tourist_center.on++,!0)}},amphitheatre:{id:"city-amphitheatre",title:()=>z(K("athleticism",0)?"city_stadium":"city_amphitheatre"),desc:()=>z(K("athleticism",0)?"city_stadium":"city_amphitheatre_desc"),category:"commercial",reqs:{theatre:1},not_trait:["joyless","cataclysm"],cost:{Money:e=>qs("amphitheatre",e,500,1.55),Lumber:e=>qs("amphitheatre",e,50,1.75),Stone:e=>qs("amphitheatre",e,200,1.75),Iron:e=>t.city.ptrait.includes("unstable")?qs("amphitheatre",e,18,1.36):0},effect(){let e=K("athleticism",0);return`
                            ${z("city_max_entertainer",[ta(K("athleticism",1)||1)])}
                            ${z("city_max_morale",[e||1])}
                            `},action(){return!!ri($(this)[0])&&(t.city.amphitheatre.count++,t.civic.entertainer.max+=ta(1),t.civic.entertainer.display=!0,!0)},flair:()=>z(K("athleticism",0)?"city_stadium_flair":"city_amphitheatre_flair")},casino:{id:"city-casino",title:z("city_casino"),desc:z("city_casino"),category:"commercial",reqs:{gambling:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("casino",e,35e4,1.35),Iron:e=>t.city.ptrait.includes("unstable")?qs("casino",e,2e3,1.35):0,Furs:e=>qs("casino",e,6e4,1.35),Plywood:e=>qs("casino",e,1e4,1.35),Brick:e=>qs("casino",e,6e3,1.35)},effect(){let e=Kr();return e+=`
                            ${z("minus_power",[$(this)[0].powered()])}
                            `,e},powered:()=>As(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2?2:3),action(){return!!ri($(this)[0])&&(t.city.casino.count++,t.race.joyless||(t.civic.entertainer.max+=ta(1),t.civic.entertainer.display=!0),Yr($(this)[0]),!0)},flair:z("city_casino_flair")},temple:{id:"city-temple",title:z("city_temple"),desc:()=>z("city_temple_desc",["none"!==t.race.gods?Ki[t.race.gods.toLowerCase()].entity:Ki[t.race.species].entity]),category:"commercial",reqs:{theology:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("temple",e,50,1.36),Lumber:e=>qs("temple",e,25,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("temple",e,6,1.36):0,Furs:e=>qs("temple",e,15,1.36),Cement:e=>qs("temple",e,10,1.36)},effect(){let e=Er();return t.genes.ancients&&t.genes.ancients>=2&&(e+=`
                            ${z("city_temple_effect6",[ta(1)])}
                            `),e},action(){return!!ri($(this)[0])&&(t.genes.ancients&&t.genes.ancients>=2&&(t.civic.priest.display=!0),t.city.temple.count++,!0)}},shrine:{id:"city-shrine",title:z("city_shrine"),desc:()=>z("city_shrine_desc"),category:"commercial",reqs:{theology:2},trait:["magnificent"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("shrine",e,75,1.32),Stone:e=>qs("shrine",e,65,1.32),Furs:e=>qs("shrine",e,10,1.32),Copper:e=>qs("shrine",e,15,1.32)},effect(){let e=`
                            ${z("city_shrine_effect")}
                            `;if(t.city.shrine&&t.city.shrine.morale>0&&(e+=`
                            ${z("city_shrine_morale",[+dn("morale").add.toFixed(1)])}
                            `),t.city.shrine&&t.city.shrine.metal>0&&(e+=`
                            ${z("city_shrine_metal",[+(100*(dn("metal").mult-1)).toFixed(1)])}
                            `),t.city.shrine&&t.city.shrine.know>0){let t=dn("know");e+=`
                            ${z("city_shrine_know",[(+t.add.toFixed(1)).toLocaleString()])}
                            `,e+=`
                            ${z("city_shrine_know2",[+(100*(t.mult-1)).toFixed(1)])}
                            `}return t.city.shrine&&t.city.shrine.tax>0&&(e+=`
                            ${z("city_shrine_tax",[+(100*(dn("tax").mult-1)).toFixed(1)])}
                            `),e},action(){if(ri($(this)[0])){if(t.city.shrine.count++,t.city.calendar.moon>0&&t.city.calendar.moon<7)t.city.shrine.morale++;else if(t.city.calendar.moon>7&&t.city.calendar.moon<14)t.city.shrine.metal++;else if(t.city.calendar.moon>14&&t.city.calendar.moon<21)t.city.shrine.know++;else if(t.city.calendar.moon>21)t.city.shrine.tax++;else switch(Math.floor(m(0,4))){case 0:t.city.shrine.morale++;break;case 1:t.city.shrine.metal++;break;case 2:t.city.shrine.know++;break;case 3:t.city.shrine.tax++}return!0}return!1}},meditation:{id:"city-meditation",title:z("city_meditation"),desc:z("city_meditation"),category:"commercial",reqs:{primitive:3},trait:["calm"],not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("meditation",e,50,1.2),Stone:e=>qs("meditation",e,25,1.2),Furs:e=>qs("meditation",e,8,1.2)},effect(){let e=t.resource.Zen.amount/(t.resource.Zen.amount+5e3);return`
                            ${z("city_meditation_effect",[Ei.calm.vars()[0]])}
                            ${z("city_meditation_effect2",[2])}
                            ${z("city_meditation_effect3",[1])}
                            ${z("city_meditation_effect4",[`${(100*e).toFixed(2)}%`])}
                            `},action(){return!!ri($(this)[0])&&(t.city.meditation.count++,t.resource.Zen.max+=Ei.calm.vars()[0],!0)}},university:{id:"city-university",title:z("city_university"),desc:()=>z("city_university_desc",[Ki[t.race.species].home]),category:"science",reqs:{science:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("university",e,900,1.5)-500,Lumber:e=>qs("university",e,500,1.36)-200,Stone:e=>qs("university",e,750,1.36)-350,Crystal:e=>"magic"===t.race.universe?qs("university",e,5,1.36):0,Iron:e=>(t.city.university?t.city.university.count:0)+(e||0)>=3&&t.city.ptrait.includes("unstable")?qs("university",e,25,1.36):0},effect(){let e=+$(this)[0].knowVal().toFixed(0);return`
                            ${z("city_university_effect",[ta(1)])}
                            ${z("city_max_knowledge",[e.toLocaleString()])}
                            `},knowVal(){let e=1,a=t.tech.science&&t.tech.science>=8?700:500;t.city.ptrait.includes("permafrost")&&(a+=ss.permafrost.vars()[1]),t.tech.science>=4&&(e+=.02*t.city.library.count),t.space.observatory&&t.space.observatory.count>0&&(e+=.05*n.observatory),t.portal.sensor_drone&&t.tech.science>=14&&(e+=.02*s.sensor_drone),t.race.hard_of_hearing&&(e*=1-Ei.hard_of_hearing.vars()[0]/100),t.race.curious&&(e*=1+Ei.curious.vars()[0]/100*t.resource[t.race.species].amount);let r=ts("cath");if(r>0&&(e*=1+Ei.curious.vars(3)[0]*r),s.s_gate&&o.scavenger){let t=Mt("gxy_alien2");e*=1+o.scavenger*t/4}let i=K("teacher",0);i&&(e*=1+i/100);let c=K("athleticism",2);c&&(e*=1-c/100),_n()&&(e*=dn("know").mult);let l=a*e;if(t.tech.supercollider){let e=t.tech.tp_particles||t.tech.particles&&t.tech.particles>=3?12.5:25;l*=t.tech.supercollider/e+1}return t.race.orbit_decayed&&(t.space.satellite&&(l*=1+.12*t.space.satellite.count),t.tech.biotech&&t.tech.biotech>=1&&(l*=2)),l},action(){if(ri($(this)[0])){let e=t.tech.science&&t.tech.science>=8?700:500;if(t.tech.science>=4&&(e*=1+.02*t.city.library.count),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,t.city.university.count++,t.civic.professor.display=!0,t.civic.professor.max=t.city.university.count,!0}return!1}},library:{id:"city-library",title:z("city_library"),desc:()=>z("city_library_desc",[Ki[t.race.species].home]),category:"science",reqs:{science:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("library",e,45,1.2),Crystal:e=>"magic"===t.race.universe?qs("library",e,2,1.2):0,Iron:e=>t.city.ptrait.includes("unstable")?qs("library",e,4,1.2):0,Furs:e=>qs("library",e,22,1.2),Plywood:e=>qs("library",e,20,1.2),Brick:e=>qs("library",e,15,1.2)},effect(){let e=125;t.race.nearsighted&&(e*=1-Ei.nearsighted.vars()[0]/100),t.race.studious&&(e*=1+Ei.studious.vars()[1]/100);let a=ts("elven");if(a>0&&(e*=1+Ei.studious.vars(1)[1]/100*a),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*t.city.temple.count),t.tech.science&&t.tech.science>=5){let a=ea(t.civic.scientist.workers,"scientist");t.race.high_pop&&(a=ke(a)),e*=1+.12*a}let r=K("teacher",0);r&&(e*=1+r/100);let i=K("athleticism",2);i&&(e*=1-i/100);let s=K("muckraker",1);s&&(e*=1+s/100),e=+e.toFixed(0);let n=K("muckraker",2),c=n?5-n:5;return t.race.autoignition&&(c-=Ei.autoignition.vars()[0],c<0&&(c=0)),`
                            ${z("city_max_knowledge",[e.toLocaleString()])}
                            ${z("city_library_effect",[c])}
                            `},action(){if(ri($(this)[0])){let e=125;return t.race.nearsighted&&(e*=1-Ei.nearsighted.vars()[0]/100),t.tech.science&&t.tech.science>=8&&(e*=1.4),t.tech.anthropology&&t.tech.anthropology>=2&&(e*=1+.05*t.city.temple.count),t.tech.science&&t.tech.science>=5&&(e*=1+.12*ea(t.civic.scientist.workers,"scientist")),e=+e.toFixed(1),t.resource.Knowledge.max+=e,t.city.library.count++,t.tech.science&&t.tech.science>=3&&(t.civic.professor.impact=.5+.01*t.city.library.count),!0}return!1},flair:z("city_library_flair")},wardenclyffe:{id:"city-wardenclyffe",title:()=>_i(),desc:z("city_wardenclyffe_desc"),category:"science",reqs:{high_tech:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("wardenclyffe",e,5e3,1.22),Knowledge:e=>qs("wardenclyffe",e,t.race.logical?1e3-Ei.logical.vars()[0]:1e3,1.22),Crystal:e=>"magic"===t.race.universe?qs("wardenclyffe",e,100,1.22):0,Copper:e=>qs("wardenclyffe",e,500,1.22),Iron:e=>t.city.ptrait.includes("unstable")?qs("wardenclyffe",e,75,1.22):0,Cement:e=>qs("wardenclyffe",e,350,1.22),Sheet_Metal:e=>qs("wardenclyffe",e,125,1.2),Nanite:e=>t.race.deconstructor?qs("wardenclyffe",e,50,1.18):0},effect(){let e=1e3;if(t.city.ptrait.includes("magnetic")&&(e+=ss.magnetic.vars()[1]),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}t.space.satellite&&(e*=1+.04*t.space.satellite.count);let a=K("athleticism",2);a&&(e*=1-a/100),e=+e.toFixed(0);let r=`
                            ${z("city_wardenclyffe_effect1",[ta(1),t.civic.scientist?t.civic.scientist.name:z("job_scientist")])}
                            ${z("city_max_knowledge",[e.toLocaleString()])}
                            `;if(t.city.powered){let e=t.tech.science>=7?2500:2e3;if(t.city.ptrait.includes("magnetic")&&(e+=ss.magnetic.vars()[1]),t.space.satellite&&(e*=1+.04*t.space.satellite.count),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}let a=K("athleticism",2);if(a&&(e*=1-a/100),e=+e.toFixed(1),t.tech.science>=15&&(r+=`
                            ${z("city_wardenclyffe_effect4",[2])}
                            `),"magic"===t.race.universe&&(r+=`
                            ${z("plus_max_resource",[br(8),t.resource.Mana.name])}
                            `),t.tech.broadcast){let a=t.tech.broadcast;r+=`
                            ${z("city_wardenclyffe_effect3",[$(this)[0].powered(),e.toLocaleString(),a])}
                            `}else r+=`
                            ${z("city_wardenclyffe_effect2",[$(this)[0].powered(),e.toLocaleString()])}
                            `;t.race.artifical&&(r+=`
                            ${z("city_transmitter_effect",[br(250)])}As(2),action(){if(ri($(this)[0])){let e=1e3;if(t.city.wardenclyffe.count++,t.civic.scientist.display=!0,t.civic.scientist.max=t.city.wardenclyffe.count,Yr($(this)[0])&&(e=t.tech.science>=7?2500:2e3),t.tech.supercollider){let a=t.tech.particles&&t.tech.particles>=3?12.5:25;e*=t.tech.supercollider/a+1}return t.resource.Knowledge.max+=e,!0}return!1},flair:()=>"magic"===t.race.universe?`
                            ${z("city_wizard_tower_flair")}
                            `:t.race.evil?`
                            ${z("city_babel_flair")}
                            `:`
                            ${z("city_wardenclyffe_flair1")}
                            ${z("city_wardenclyffe_flair2")}
                            `},biolab:{id:"city-biolab",title:z("city_biolab"),desc:`
                            ${z("city_biolab_desc")}
                            ${z("requires_power")}
                            `,category:"science",reqs:{genetics:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("biolab",e,25e3,1.3),Knowledge:e=>qs("biolab",e,5e3,1.3),Copper:e=>qs("biolab",e,1250,1.3),Iron:e=>t.city.ptrait.includes("unstable")?qs("biolab",e,160,1.3):0,Alloy:e=>qs("biolab",e,350,1.3)},effect(){let e=3e3;return t.portal.sensor_drone&&t.tech.science>=14&&(e*=1+.02*s.sensor_drone),t.tech.science>=20&&(e*=3),t.tech.science>=21&&(e*=1.45),t.tech.biotech>=1&&(e*=2.5),e=+e.toFixed(0),`${z("city_max_knowledge",[e.toLocaleString()])}, ${z("minus_power",[$(this)[0].powered()])}`},powered:()=>As(2),action(){return!!ri($(this)[0])&&(t.city.biolab.count++,Yr($(this)[0])&&(t.resource.Knowledge.max+=3e3),!0)}},coal_power:{id:"city-coal_power",title:()=>t.race.environmentalist?z("city_hydro_power"):z("magic"===t.race.universe?"city_mana_engine":"city_coal_power"),desc:()=>t.race.environmentalist?`
                            ${z("city_hydro_power_desc")}
                            `:`
                            ${z("magic"===t.race.universe?"city_mana_engine_desc":"city_coal_power_desc")}
                            ${z("requires_res",[z("magic"===t.race.universe?"resource_Mana_name":"resource_Coal_name")])}
                            `,category:"utility",reqs:{high_tech:2},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("coal_power",e,1e4,ci(1.22)),Crystal:e=>"magic"===t.race.universe?qs("coal_power",e,125,ci(1.22)):0,Copper:e=>qs("coal_power",e,1800,ci(1.22))-1e3,Iron:e=>t.city.ptrait.includes("unstable")?qs("coal_power",e,175,ci(1.22)):0,Cement:e=>qs("coal_power",e,600,ci(1.22)),Steel:e=>qs("coal_power",e,2e3,ci(1.22))-1e3},effect(){let e="magic"===t.race.universe?.05:.35,a=-$(this)[0].powered();return t.race.environmentalist?`+${a}MW`:`+${a}MW. ${z("magic"===t.race.universe?"city_mana_engine_effect":"city_coal_power_effect",[e])}`},powered(){let e=t.race.environmentalist?t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1?-5:-4:t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1?-6:-5,a=K("dirty_jobs",1);return a&&(e-=a),Fs(e)},p_fuel:()=>"magic"===t.race.universe?{r:"Mana",a:t.race.environmentalist?0:.05}:{r:"Coal",a:t.race.environmentalist?0:.35},action(){return!!ri($(this)[0])&&(t.city.coal_power.count++,t.city.coal_power.on++,t.city.power+=5,!0)}},oil_power:{id:"city-oil_power",title:()=>t.race.environmentalist?z("city_wind_power"):z("city_oil_power"),desc:()=>t.race.environmentalist?`
                            ${z("city_wind_power_desc")}
                            `:`
                            ${z("city_oil_power_desc")}
                            ${z("requires_res",[z("resource_Oil_name")])}
                            `,category:"utility",reqs:{oil:3},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("oil_power",e,5e4,ci(1.22)),Copper:e=>qs("oil_power",e,6500,ci(1.22))+1e3,Iron:e=>t.city.ptrait.includes("unstable")?qs("oil_power",e,180,ci(1.22)):0,Aluminium:e=>qs("oil_power",e,12e3,ci(1.22)),Cement:e=>qs("oil_power",e,5600,ci(1.22))+1e3},effect(){let e=-$(this)[0].powered();return t.race.environmentalist?`+${e}MW`:`+${e}MW. ${z("city_oil_power_effect",[.65])}`},powered(){let e=0;if(t.race.environmentalist)if(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3){let a=1===t.city.calendar.wind?-7:-5;e=t.stats.achieve.dissipated.l>=5?a-2:a-1}else e=1===t.city.calendar.wind?-7:-5;else e=t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3?t.stats.achieve.dissipated.l>=5?-8:-7:-6;let a=K("dirty_jobs",1);return a&&(e-=a),Fs(e)},p_fuel:()=>({r:"Oil",a:t.race.environmentalist?0:.65}),action(){return!!ri($(this)[0])&&(t.city.oil_power.count++,t.city.oil_power.on++,t.city.power+=6,!0)}},fission_power:{id:"city-fission_power",title:z("city_fission_power"),desc:`
                            ${z("city_fission_power_desc")}
                            ${z("requires_res",[z("resource_Uranium_name")])}
                            `,category:"utility",reqs:{high_tech:5},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("fission_power",e,25e4,1.36),Copper:e=>qs("fission_power",e,13500,1.36),Iron:e=>t.city.ptrait.includes("unstable")?qs("fission_power",e,1750,1.36):0,Cement:e=>qs("fission_power",e,10800,1.36),Titanium:e=>qs("fission_power",e,7500,1.36)},effect(){return`+${-$(this)[0].powered()}MW. ${z("city_fission_power_effect",[.1])}`},powered:()=>Fs(t.tech.uranium>=4?-18:-14),p_fuel:()=>({r:"Uranium",a:.1}),action(){return!!ri($(this)[0])&&(t.city.fission_power.count++,t.city.fission_power.on++,t.city.power+=14,!0)}},mass_driver:{id:"city-mass_driver",title:z("city_mass_driver"),desc:`
                            ${z("city_mass_driver_desc")}
                            ${z("requires_power")}
                            `,category:"utility",reqs:{mass:1},not_trait:["cataclysm","lone_survivor"],cost:{Money:e=>qs("mass_driver",e,375e3,1.32),Copper:e=>qs("mass_driver",e,33e3,1.32),Iron:e=>qs("mass_driver",e,42500,1.32),Iridium:e=>qs("mass_driver",e,2200,1.32)},effect(){return`${t.tech.mass>=2?`
                            ${z("city_mass_driver_effect2",[1,t.civic.scientist.name])}
                            `:""}${z("city_mass_driver_effect",[t.race.truepath?6:5,nn("name")])} ${z("minus_power",[$(this)[0].powered()])}`},powered(){let e=t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=4?4:5;return As(t.tech.mass>=2?e-1:e)},action(){return!!ri($(this)[0])&&(t.city.mass_driver.count++,Yr($(this)[0]),!0)}},replicator:{id:"city-replicator",title:z("tech_replicator"),desc:z("tech_replicator"),category:"utility",reqs:{special_hack:1},cost:{},wiki:!1,effect:()=>"fake structure",powered:()=>1,action:()=>!1}},tech:Or(),arpa:xe("PhysicsTech"),genes:xe("GeneTech"),blood:xe("BloodTech"),space:At(),interstellar:xt,galaxy:jt,starDock:{probes:{id:"starDock-probes",title:z("star_dock_probe"),desc:()=>`
                            ${z("star_dock_probe_desc")}
                            `,reqs:{genesis:4},cost:{Money:e=>qs("probes",e,35e4,t.race.truepath?1.125:1.25,"starDock"),Alloy:e=>qs("probes",e,75e3,t.race.truepath?1.125:1.25,"starDock"),Polymer:e=>qs("probes",e,85e3,t.race.truepath?1.125:1.25,"starDock"),Iridium:e=>qs("probes",e,12e3,t.race.truepath?1.125:1.25,"starDock"),Mythril:e=>qs("probes",e,3500,t.race.truepath?1.125:1.25,"starDock")},effect:()=>`
                            ${z("star_dock_probe_effect")}
                            `,action(){return!!ri($(this)[0])&&(t.starDock.probes.count++,!0)}},geck:{id:"starDock-geck",title:z("tech_geck"),desc:()=>`
                            ${z("tech_geck_desc")}
                            `,reqs:{geck:1},condition:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5),queue_complete:()=>0,no_multi:!0,cost:{Money:e=>qs("geck",e,1e6,1.25,"starDock"),Elerium:e=>qs("geck",e,1e3,1.25,"starDock"),Plasmid:e=>qs("geck",e,25,1.4,"starDock")},effect:()=>`
                            ${z("star_dock_geck_effect")}
                            `,action(){return!!ri($(this)[0])&&(t.starDock.geck.count++,!0)}},seeder:{id:"starDock-seeder",title:()=>t.race.cataclysm?z("star_dock_exodus"):z("star_dock_seeder"),desc(){let e=t.race.cataclysm?z("star_dock_exodus"):z("star_dock_seeder");return t.starDock.seeder&&t.starDock.seeder.count>=100?`
                            ${e}
                            ${z("star_dock_seeder_desc2")}
                            `:`
                            ${e}
                            ${z("star_dock_seeder_desc1")}
                            `},reqs:{genesis:5},queue_size:10,queue_complete:()=>100-t.starDock.seeder.count,cost:{Money:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?1e5:0,Steel:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?25e3:0,Neutronium:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?240:0,Elerium:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?10:0,Nano_Tube:e=>(e||0)+(t.starDock.hasOwnProperty("seeder")?t.starDock.seeder.count:0)<100?12e3:0},effect(e){let a=(e||0)+(t.starDock.seeder?t.starDock.seeder.count:0),r=a<100?z("star_dock_seeder_status1",[100-a]):z("star_dock_seeder_status2");return`
                            ${t.race.cataclysm?z("star_dock_exodus_effect"):z("star_dock_seeder_effect")}
                            ${r}
                            `},action(){return!!(t.starDock.seeder.count<100&&ri($(this)[0]))&&(t.starDock.seeder.count++,t.starDock.seeder.count>=100&&(t.tech.genesis=6,_s("starDock-seeder"),Ss($("#modalBox")),oi(Mr.space.spc_gas.star_dock,"star_dock")),!0)}},prep_ship:{id:"starDock-prep_ship",title:z("star_dock_prep"),desc:()=>`
                            ${t.race.cataclysm?z("star_dock_prep_cata_desc"):z("star_dock_prep_desc")}
                            ${z("star_dock_genesis_desc2")}
                            `,reqs:{genesis:6},queue_complete:()=>0,cost:{},effect(){let e=Gs("bioseed"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                            ${t.race.cataclysm?z("star_dock_prep_cata_effect"):z("star_dock_prep_effect")}
                            ${z("star_dock_genesis_effect2",[e.plasmid,a])}
                            ${z("star_dock_genesis_effect3",[e.phage])}
                            `},action:()=>(t.tech.genesis=7,_s("starDock-prep_ship"),Ss($("#modalBox")),oi(Mr.space.spc_gas.star_dock,"star_dock"),!0)},launch_ship:{id:"starDock-launch_ship",title:z("star_dock_genesis"),desc:()=>`
                            ${t.race.cataclysm?z("star_dock_prep_cata_effect"):z("star_dock_genesis_desc1")}
                            ${z("star_dock_genesis_desc2")}
                            `,reqs:{genesis:7},queue_complete:()=>0,cost:{},effect(){let e=Gs("bioseed"),a="antimatter"===t.race.universe?z("resource_AntiPlasmid_plural_name"):z("resource_Plasmid_plural_name");return`
                            ${t.race.cataclysm?z("star_dock_genesis_cata_effect1"):z("star_dock_genesis_effect1")}
                            ${z("star_dock_genesis_effect2",[e.plasmid,a])}
                            ${z("star_dock_genesis_effect3",[e.phage])}
                            `},action:()=>(function(){t.sim||e.setItem("evolveBak",LZString.compressToUTF16(JSON.stringify(t))),O(),ks("reset",{end:"bioseed"});let a=t.race.species,r=t.race.gods,i=Ki[a].type,s=t.city.calendar.orbit,n=t.city.biome,c=t.city.ptrait,o=Gs("bioseed");t.stats.bioseed++,rn(),t.prestige.Phage.count+=o.phage,t.stats.phage+=o.phage,"antimatter"===t.race.universe?(t.prestige.AntiPlasmid.count+=o.plasmid,t.stats.antiplasmid+=o.plasmid):(t.prestige.Plasmid.count+=o.plasmid,t.stats.plasmid+=o.plasmid),qn("seeder"),qn(`biome_${n}`),c.forEach((function(e){ss.hasOwnProperty(e)&&qn(`atmo_${e}`)})),qn(`genus_${i}`),t.race.truepath&&qn("exodus"),c.includes("dense")&&"heavy"===t.race.universe&&qn("double_density"),t.race.junker&&"junker"===t.race.species&&Pn("organ_harvester"),"hellscape"===t.city.biome&&"demonic"!==Ki[t.race.species].type&&Pn("ill_advised"),void 0===t.tech.world_control&&qn("cult_of_personality"),t.race.cataclysm&&qn("iron_will",!1,5),t.race.gross_enabled&&t.race.ooze&&"custom"!==t.race.species&&"sludge"!==t.race.species&&qn("gross");let l=0,_=0;Object.keys(t.city.geology).forEach((function(e){t.city.geology[e]>0?l++:t.city.geology[e]<0&&_++})),l>=4&&qn("miners_dream"),_>=3&&Pn("rocky_road"),t.race.steelen&&t.race.steelen>=1&&qn("steelen"),"micro"===t.race.universe&&(t.race.small||t.race.compact?qn("macro",!0):qn("marble",!0)),Sn();let d=!!t.race.hasOwnProperty("srace")&&t.race.srace,p=t.race.hasOwnProperty("corruption")&&t.race.corruption>1?t.race.corruption-1:0,u=t.starDock.probes.count+1,h=t.starDock.hasOwnProperty("geck")?t.starDock.geck.count:0;t.stats.achieve.explorer&&(u+=t.stats.achieve.explorer.l),t.race={species:"protoplasm",gods:a,old_gods:r,universe:t.race.universe,seeded:!0,probes:u,geck:h,seed:Math.floor(m(1e4)),ascended:!1},p>0&&(t.race.corruption=p),d&&(t.race.srace=d),H({orbit:s,biome:n,ptrait:c,geology:!1}),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),window.location.reload()}(),!1)}},portal:pa(),tauceti:Re};function Sr(){let a=$("#evolution .evolving").nextAll();Object.values(a).forEach((function(e){Ss($(e),!0)})),Ss($("#evolution .evolving"),!0),t.evolution.bunker={count:1},ti(Mr.evolution.bunker.id),li(),t.race.truepath||t.race.lone_survivor?(t.evolution.nerfed={count:0},t.evolution.badgenes={count:0}):("antimatter"===t.race.universe?t.evolution.mastery={count:0}:t.evolution.plasmid={count:0},t.evolution.crispr={count:0}),t.evolution.trade={count:0},t.evolution.craft={count:0},t.evolution.junker={count:0},t.evolution.joyless={count:0},t.evolution.steelen={count:0},(t.stats.achieve.whitehole||t.sim)&&(t.evolution.decay={count:0}),(t.stats.achieve.ascended||t.sim)&&(t.evolution.emfield={count:0}),(t.stats.achieve.scrooge||t.sim)&&(t.evolution.inflation={count:0}),(t.stats.achieve.shaken||t.sim)&&(t.evolution.cataclysm={count:0}),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&(t.evolution.banana={count:0},t.evolution.orbit_decay={count:0}),"standard"===t.race.universe&&(t.stats.achieve.whitehole||t.sim),"heavy"===t.race.universe&&(t.stats.achieve.seeder&&t.stats.achieve.seeder.h||t.sim),"magic"===t.race.universe&&(t.stats.achieve.ascended&&t.stats.achieve.ascended.mg||t.sim)&&(t.evolution.witch_hunter={count:0}),"evil"===t.race.universe&&(t.stats.achieve.corrupted&&t.stats.achieve.corrupted.e||t.sim),(t.stats.achieve.ascended||t.stats.achieve.corrupted||t.sim)&&(t.evolution.truepath={count:0}),((t.stats.achieve.ascended||t.stats.achieve.corrupted)&&t.stats.achieve.extinct_junker||t.sim)&&(t.evolution.sludge={count:0}),(t.stats.achieve.bluepill||t.sim)&&(t.evolution.simulation={count:0}),(t.stats.achieve.retired||t.sim)&&(t.evolution.lone_survivor={count:0}),function(){let e=$('
                            ');$("#evolution").append(e),e.append($(`

                            ${z("evo_challenge_genes")}

                            `)),e.append($(`
                            ${z("evo_challenge_genes_desc")}
                            `)),t.genes.challenge&&t.genes.challenge>=2&&e.append($(`
                            ${z("evo_challenge_genes_mastery")}
                            `))}(),t.race.truepath||t.race.lone_survivor?Jr("evolution","nerfed"):"antimatter"===t.race.universe?Jr("evolution","mastery"):Jr("evolution","plasmid"),Jr("evolution","trade"),Jr("evolution","craft"),t.race.truepath||t.race.lone_survivor?Jr("evolution","badgenes"):Jr("evolution","crispr"),function(){let e=$('
                            ');$("#evolution").append(e),e.append($(`

                            ${z("evo_challenge_run")}

                            `)),e.append($(`
                            ${z("evo_challenge_run_desc")}
                            `))}(),Jr("evolution","joyless"),Jr("evolution","steelen"),(t.stats.achieve.whitehole||t.sim)&&Jr("evolution","decay"),(t.stats.achieve.ascended||t.sim)&&Jr("evolution","emfield"),(t.stats.achieve.scrooge||t.sim)&&Jr("evolution","inflation"),((t.stats.achieve.ascended||t.stats.achieve.corrupted)&&t.stats.achieve.extinct_junker||t.sim)&&Jr("evolution","sludge"),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&Jr("evolution","orbit_decay"),"standard"===t.race.universe&&(t.stats.achieve.whitehole||t.sim),"heavy"===t.race.universe&&(t.stats.achieve.seeder&&t.stats.achieve.seeder.h||t.sim),"magic"===t.race.universe&&(t.stats.achieve.ascended&&t.stats.achieve.ascended.mg||t.sim)&&Jr("evolution","witch_hunter"),"evil"===t.race.universe&&(t.stats.achieve.corrupted&&t.stats.achieve.corrupted.e||t.sim),t.hasOwnProperty("beta")&&!t.sim&&Jr("evolution","simulation"),function(){let e=$('
                            ');$("#evolution").append(e),e.append($(`

                            ${z("evo_scenario")}

                            `)),e.append($(`
                            ${z("evo_scenario_desc")}
                            `))}(),Jr("evolution","junker"),(t.stats.achieve.shaken||t.sim)&&Jr("evolution","cataclysm"),(t.stats.achieve.whitehole||t.stats.achieve.ascended||t.sim)&&Jr("evolution","banana"),(t.stats.achieve.ascended||t.stats.achieve.corrupted||t.sim)&&Jr("evolution","truepath"),(t.stats.achieve.retired||t.sim)&&Jr("evolution","lone_survivor"),t.sim?function(){let a=$('
                            ');$("#evolution").append(a),a.append($(`

                            ${z("evo_challenge_simulation")}

                            `)),a.append($(`
                            ${z("evo_challenge_simulation_desc")}
                            `)),a.append($(``)),Cs({el:"#simSection",data:{},methods:{exitsim(){t.hasOwnProperty("sim")&&(t.stats=sn(t.sim.stats),t.prestige=sn(t.sim.prestige),t.genes=sn(t.sim.genes),t.blood=sn(t.sim.blood),t.pillars=sn(t.sim.pillars),t.race=sn(t.sim.race),delete t.sim,t.race.species="protoplasm",delete t.race.simulation,e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w&&P.w.terminate(),window.location.reload())}}})}():t.race.simulation&&function(){let e=$('
                            ');$("#evolution").append(e),e.append($(`

                            ${z("evo_challenge_simulation")}

                            `)),e.append($(`
                            ${z("evo_challenge_simulation_desc")}
                            `));let a=$($('
                            '));e.append(a),t.race.simConfig||(t.race.simConfig={}),["Plasmid","AntiPlasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone"].forEach((function(e){t.race.simConfig[e]=t.race.simConfig[e]||0,a.append($(`
                            ${z(`resource_${e}_name`)}
                            `))})),Cs({el:"#simSection",data:t.race.simConfig})}()}function Cr(e,a){let r=t.race.orbit_decay?"orbit_decayed":"cataclysm",i=function(e,t,a){return"space"===a?e.hasOwnProperty("trait")?e.trait.push(t):e.trait=[t]:"tauceti"===a?e.reqs.isolation=1:e.hasOwnProperty("not_trait")?e.not_trait.push(t):e.not_trait=[t],e};switch(e){case"bonfire":return i({id:`${a}-bonfire`,title:z("city_bonfire"),desc:z("city_bonfire_desc"),category:"outskirts",wiki:!1,reqs:{primitive:3},condition:()=>cn("summer"),queue_complete:()=>0,effect(){let e=2.5*t.resource.Thermite.diff/(2.5*t.resource.Thermite.diff+500)*500,a=1e5+9e3*t.stats.reset;a>1e6&&(a=1e6);let r=t.resource.Thermite.amount${z("city_bonfire_effect3",[a.toLocaleString()])}
                            ${z("city_bonfire_effect4",[(+t.resource.Thermite.amount.toFixed(0)).toLocaleString(),a.toLocaleString()])}
                            `:"";return`
                            ${z("city_bonfire_effect",[t.resource.Thermite.diff])}
                            ${z("city_bonfire_effect2",[+e.toFixed(1)])}
                            ${r}`},action:()=>!1,flair:()=>z("city_bonfire_flair")},r,a);case"firework":return i({id:`${a}-firework`,title:z("city_firework"),desc:z("city_firework"),category:"outskirts",wiki:!1,reqs:{mining:3},condition:()=>cn("firework")&&(t.tech.cement||t.race.flier),cost:{Money:()=>0===t[a].firework.count?5e4:0,Iron:()=>0===t[a].firework.count?7500:0,Cement:()=>0===t[a].firework.count?1e4:0},queue_complete:()=>1-t[a].firework.count,switchable:()=>!0,effect:()=>0===t[a].firework.count?z("city_firework_build"):z("city_firework_effect"),action(){return!(0!==t[a].firework.count||!ri($(this)[0])||(t[a].firework.count=1,0))}},r,a);case"assembly":{let e=function(e){let a=ke(e);return t.race.promiscuous&&(a/=1+Ei.promiscuous.vars()[1]*t.race.promiscuous),Math.round(a)};return i({id:`${a}-assembly`,title:z("city_assembly"),desc:()=>z("city_assembly_desc",[Ki[t.race.species].name]),category:"military",reqs:{},trait:["artifical"],queue_complete:()=>t.resource[t.race.species].max-t.resource[t.race.species].amount,cost:{Money:a=>t.resource[t.race.species].amount?qs("citizen",a,e(125),1.01):0,Copper:a=>t.race.deconstructor?0:t.resource[t.race.species].amount>=5?qs("citizen",a,e(50),1.01):0,Aluminium:a=>t.race.deconstructor?0:t.resource[t.race.species].amount>=5?qs("citizen",a,e(50),1.01):0,Nanite:a=>t.race.deconstructor&&t.resource[t.race.species].amount>=3?qs("citizen",a,e(500),1.01):0},effect(){let e="";return t.resource[t.race.species].max===t.resource[t.race.species].amount&&(e=`
                            ${z("city_assembly_effect_warn")}
                            `),`
                            ${z("city_assembly_effect",[Ki[t.race.species].name])}
                            ${e}`},action(){return!!(t.race.vax&&t.race.vax>=100)||!!(t.resource[t.race.species].max>t.resource[t.race.species].amount&&ri($(this)[0]))&&(t.resource[t.race.species].amount++,!0)}},r,a)}case"nanite_factory":return i({id:`${a}-nanite_factory`,title:z("city_nanite_factory"),desc:z("city_nanite_factory"),category:"industrial",reqs:{},trait:["deconstructor"],region:"city",cost:{Money:e=>qs("nanite_factory",e,25e3,ci(1.25)),Copper:e=>qs("nanite_factory",e,1200,ci(1.25)),Steel:e=>qs("nanite_factory",e,1e3,ci(1.25))},effect(){let e=br(2500);return`
                            ${z("city_nanite_factory_effect",[t.resource.Nanite.name])}
                            ${z("plus_max_resource",[e,t.resource.Nanite.name])}.
                            `},special:!0,action(){return!!ri($(this)[0])&&(t.city.nanite_factory.count++,t.settings.showIndustry=!0,ki(),!0)},flair:z("city_nanite_factory_flair")},r,a);case"captive_housing":return i({id:`${a}-captive_housing`,title:z("city_captive_housing"),desc:z("city_captive_housing_desc"),category:"residential",reqs:{unfathomable:1},trait:["unfathomable"],region:"city",cost:{Money:e=>qs("captive_housing",e,40,1.35),Lumber:e=>qs("captive_housing",e,30,1.35),Stone:e=>qs("captive_housing",e,18,1.35)},effect(){let e="";t.race.artifical||t.race.detritivore||t.race.carnivore||t.race.soul_eater||(e+=`
                            ${z("city_captive_housing_cattle",[t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.cattle:0,t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.cattleCap:0])}
                            `);let a=0;if(t.city.hasOwnProperty("surfaceDwellers"))for(let r=0;r${z("city_captive_housing_broken",[Ki[i].name,s])}`,e+=`
                            ${z("city_captive_housing_untrained",[Ki[i].name,n])}
                            `}return e+=`
                            ${z("city_captive_housing_capacity",[a,t.city.hasOwnProperty("captive_housing")?t.city.captive_housing.raceCap:0])}
                            `,t.tech.unfathomable&&t.tech.unfathomable>=2&&(e+=`
                            ${z("plus_max_resource",[1,z("job_torturer")])}
                            `),e},action(){if(ri($(this)[0])){t.city.captive_housing.count++;let e=t.city.captive_housing.count;return t.city.captive_housing.raceCap=e*(t.tech.unfathomable&&t.tech.unfathomable>=3?3:2),t.city.captive_housing.cattleCap=5*e,!0}return!1}},r,a);case"horseshoe":return i({id:`${a}-horseshoe`,title:()=>z(`city_${hn(!0)}`,[hn(!1)]),desc:()=>z(`city_${hn(!0)}_desc`,[hn(!1)]),category:"outskirts",reqs:{primitive:3},condition:()=>t.race.hooved||cn("fool",2023),inflation:!1,cost:{Lumber(e){let a=(t.race.shoecnt||0)+(e||0);return t.race.kindling_kindred||t.race.smoldering||t.resource.Copper.display&&!(a<=12)?0:Math.round((a>12?25:5)*(a<=5?1:a-4)*(Ei.hooved.vars()[0]/100))},Copper(e){let a=(t.race.shoecnt||0)+(e||0),r=!t.race.kindling_kindred&&!t.race.smoldering;return(!r||r&&a>12&&t.resource.Copper.display)&&(!t.resource.Iron.display||a<=75)?Math.round((a>75?20:5)*(a<=12?1:a-11)*(Ei.hooved.vars()[0]/100)):0},Iron(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Iron.display&&a>75&&(!t.resource.Steel.display||a<=150)?Math.round((a<=150?12:28)*a*(Ei.hooved.vars()[0]/100)):0},Steel(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Steel.display&&a>150&&(!t.resource.Adamantite.display||a<=500)?Math.round((a<=500?40:100)*a*(Ei.hooved.vars()[0]/100)):0},Adamantite(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Adamantite.display&&a>500&&(!t.resource.Orichalcum.display||a<=5e3)?Math.round((a<=5e3?5:25)*a*(Ei.hooved.vars()[0]/100)):0},Orichalcum(e){let a=(t.race.shoecnt||0)+(e||0);return t.resource.Orichalcum.display&&a>5e3?Math.round((25*a-12e4)*(Ei.hooved.vars()[0]/100)):0}},action(){return!(t.race.hooved||!cn("fool",2023))||!(!t.resource.Horseshoe.display||!ri($(this)[0]))&&(t.resource.Horseshoe.amount++,t.race.shoecnt++,!(5001===t.race.shoecnt&&t.resource.Orichalcum.display||501===t.race.shoecnt&&t.resource.Adamantite.display||151===t.race.shoecnt&&t.resource.Steel.display||76===t.race.shoecnt&&t.resource.Iron.display||13===t.race.shoecnt&&t.resource.Copper.display&&t.resource.Lumber.display)||0)}},r,a)}}function zr(e,a){a=a||"evo";let r=t.evolution.final||0;return(t.tech[a]&&t.tech[a]===e||t.evolution.gselect)&&r<100}const Fr=["human","orc","elven","troll","ogre","cyclops","kobold","goblin","gnome","cath","wolven","vulpine","centaur","rhinotaur","capybara","tortoisan","gecko","slitheryn","arraak","pterodacti","dracnid","sporgar","shroomi","moldling","mantis","scorpid","antid","entish","cacti","pinguicula","sharkin","octigoran","dryad","satyr","phoenix","salamander","yeti","wendigo","tuskin","kamel","imp","balorg","seraph","unicorn","synth","nano","ghast","shoggoth","custom"];if(Fr.forEach((e=>Mr.evolution[e]={id:`evolution-${e}`,title:()=>Ki[e].name,desc:()=>`${z("evo_evolve")} ${Ki[e].name}`,reqs:{evo:7},grant:["evo",8],condition:()=>(t.race.seeded||t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>=1||t.stats.achieve[`extinct_${e}`]&&t.stats.achieve[`extinct_${e}`].l>=1)&&t.tech[`evo_${Ki[e].type}`]>=2&&100===t.evolution.final&&!t.race.evoFinalMenu,cost:{RNA:()=>320,DNA:()=>320},race:!0,effect:()=>`${"string"==typeof Ki[e].desc?Ki[e].desc:Ki[e].desc()} ${z("evo_complete")}`,action(){if(ri($(this)[0])){if(["synth","custom"].includes(e))return function(e){if(("synth"===e||"custom"===e&&t.custom.race0.traits.includes("imitation"))&&Object.keys(t.stats.synth).length>1)return t.race.evoFinalMenu=e,Tr(),!0;t.race.species=e,hi()}(e);t.race.species=e,hi()}return!1},queue_complete:()=>t.tech.evo&&7===t.tech.evo?1:0,emblem:()=>Xs(`extinct_${e}`)})),Object.keys(t.stats.synth).length>1){let e=sn(Fr);e.push("junker"),e.push("sludge"),e.forEach((e=>Mr.evolution[`s-${e}`]={id:`evolution-s-${e}`,title:()=>Ki[e].name,desc:()=>`${z("evo_imitate")} ${Ki[e].name}`,reqs:{evo:8},grant:["evo",9],condition:()=>t.stats.synth[e]&&t.race.evoFinalMenu,cost:{},race:!0,effect:()=>z("evo_imitate_race",[Ki[e].name]),action:()=>(t.stats.synth[e]&&(t.race.species=t.race.evoFinalMenu,t.race.srace=e,hi()),!1),queue_complete:()=>t.tech.evo&&8===t.tech.evo?1:0}))}const Ar={plasmid:"no_plasmid",mastery:"weak_mastery",trade:"no_trade",craft:"no_craft",crispr:"no_crispr",nerfed:"nerfed",badgenes:"badgenes"};Object.keys(Ar).forEach((e=>Mr.evolution[e]={id:`evolution-${e}`,title:z(`evo_challenge_${e}`),desc:z(`evo_challenge_${e}`),condition:()=>t.evolution.hasOwnProperty(e),cost:{DNA:()=>10},challenge:!0,effect:()=>Lr(e),action(){return ri($(this)[0])&&(t.race[Ar[e]]?(delete t.race[Ar[e]],$(`#${$(this)[0].id}`).removeClass("hl"),(t.race.truepath||t.race.lone_survivor)&&(delete t.race.nerfed,delete t.race.badgenes),["junker","cataclysm","banana","truepath","lone_survivor"].forEach((function(e){delete t.race[e],$(`#evolution-${e}`).removeClass("hl")}))):(t.race[Ar[e]]=1,$(`#${$(this)[0].id}`).addClass("hl")),Sr(),On()),!1},highlight:()=>!!t.race[Ar[e]],queue_complete:()=>0}));const Ir={joyless:{t:"c",e:"joyless"},steelen:{t:"c",e:"steelen"},decay:{t:"c",e:"dissipated"},emfield:{t:"c",e:"technophobe"},inflation:{t:"c",e:"wheelbarrow"},sludge:{t:"c",e:"extinct_sludge"},orbit_decay:{t:"c",e:"lamentis"},witch_hunter:{t:"c",e:"soul_sponge"},simulation:{t:"c",e:"thereisnospoon"},junker:{t:"s",e:"extinct_junker"},cataclysm:{t:"s",e:"iron_will"},banana:{t:"s",e:"banana"},truepath:{t:"s",e:"pathfinder"},lone_survivor:{t:"s",e:"adam_eve"}};function Tr(){if((t.settings.tabLoad||0===t.settings.civTabs)&&"bigbang"!==t.race.universe&&(!t.race.seeded||t.race.chose)){if(t.tech.evo_challenge){let e=$("#evolution .evolving").nextAll();Object.values(e).forEach((function(e){Ss($(e),!0)})),Ss($("#evolution .evolving"),!0)}Object.keys(Mr.evolution).forEach((function(e){if(!Mr.evolution[e].challenge){ti(Mr.evolution[e].id);var a=!0;Mr.evolution[e].hasOwnProperty("reqs")&&Object.keys(Mr.evolution[e].reqs).forEach((function(r){(!t.tech[r]||t.tech[r]=2&&li(),t.tech.evo_challenge&&Sr())}}function Lr(e){switch(e){case"nerfed":return z(`evo_challenge_${e}_effect`,"antimatter"===t.race.universe?["20%","50%","50%","33%"]:["50%","20%","50%","33%"]);case"badgenes":return z(`evo_challenge_${e}_effect`,[1,2]);case"orbit_decay":return Ts()>=100?`
                            ${z("evo_challenge_orbit_decay_effect",[5e3])}
                            ${z("evo_challenge_scenario_failwarn")}
                            `:`
                            ${z("evo_challenge_orbit_decay_effect",[5e3])}
                            ${z("evo_challenge_scenario_failwarn")}
                            ${z("evo_challenge_scenario_warn")}
                            `;case"junker":return"hellscape"===t.city.biome&&"evil"!==t.race.universe?`
                            ${z("evo_challenge_junker_effect")}
                            ${z("evo_warn_unwise")}
                            `:z("evo_challenge_junker_effect");case"cataclysm":return Ts()>=50?`
                            ${z("evo_challenge_cataclysm_effect")}
                            ${z("evo_challenge_cataclysm_warn")}
                            `:`
                            ${z("evo_challenge_cataclysm_effect")}
                            ${z("evo_challenge_scenario_warn")}
                            `;default:return z(`evo_challenge_${e}_effect`)}}function Er(){let e;if("antimatter"===t.race.universe||t.race.no_plasmid){let a=t.tech.anthropology&&t.tech.anthropology>=1?1.6:1;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=ea(t.civic.professor.workers,"professor")*("antimatter"===t.race.universe?.02:.04);t.race.high_pop&&(e=ke(e)),a+=+e.toFixed(2)}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.015:t.genes.ancients>=3?.0125:.01;t.race.high_pop&&(e=ke(e)),a+=e*ea(t.civic.priest.workers,"priest")}"antimatter"===t.race.universe&&(a/=2),t.race.spiritual&&(a*=1+Ei.spiritual.vars()[0]/100);let r=ts("seraph");if(r>0&&(a*=1+Ei.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1+Y.theocracy()[0]/100),t.race.ooze&&(a*=1-Ei.ooze.vars()[1]/100),a=+a.toFixed(3),e=`
                            ${z("city_temple_effect1",[a])}
                            `,"antimatter"===t.race.universe){let a=6;if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.12:t.genes.ancients>=3?.1:.08;t.race.high_pop&&(e=ke(e)),a+=e*ea(t.civic.priest.workers,"priest")}e+=`
                            ${z("city_temple_effect5",[a.toFixed(2)])}
                            `}}else{let a=t.tech.anthropology&&t.tech.anthropology>=1?8:5;if(t.tech.fanaticism&&t.tech.fanaticism>=2){let e=.2*ea(t.civic.professor.workers,"professor");t.race.high_pop&&(e=ke(e)),a+=+e.toFixed(1)}if(t.genes.ancients&&t.genes.ancients>=2&&t.civic.priest.display){let e=t.genes.ancients>=5?.15:t.genes.ancients>=3?.125:.1;t.race.high_pop&&(e=ke(e)),a+=e*ea(t.civic.priest.workers,"priest")}t.race.spiritual&&(a*=1+Ei.spiritual.vars()[0]/100);let r=ts("seraph");r>0&&(a*=1+Ei.spiritual.vars(1)[0]/100*r),"theocracy"===t.civic.govern.type&&(a*=1+Y.theocracy()[0]/100),t.race.ooze&&(a*=1-Ei.ooze.vars()[1]/100),t.race.orbit_decayed&&t.race.truepath&&(a*=.1),a=+a.toFixed(3),e=`
                            ${z("city_temple_effect2",[a])}
                            `}return t.tech.fanaticism&&t.tech.fanaticism>=3&&(e+=`
                            ${z("city_temple_effect3")}
                            `),t.tech.anthropology&&t.tech.anthropology>=4&&(e+=`
                            ${t.race.truepath?z("city_temple_effect_tp",[2,25]):z("city_temple_effect4")}
                            `),e}function Kr(){let e=t.tech.gambling>=3?6e4:4e4;t.tech.gambling>=5&&(e+=t.tech.gambling>=6?24e4:6e4),e=br(e),t.race.gambler&&(e*=1+.04*t.race.gambler),t.tech.world_control&&(e*=1.25),t.race.truepath&&(e*=1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(e*=1+.05*t.tech.stock_exchange),t.race.inflation&&(e*=1+t.race.inflation/100),t.tech.isolation&&(e*=5.5),e=Math.round(e);let a=t.race.joyless?"":`
                            ${z("city_max_entertainer",[ta(1)])}
                            `,r=t.race.orbit_decayed||t.tech.isolation?`
                            ${z("plus_max_resource",[ta(1),z("banker_name")])}
                            `:"",i=`
                            ${z("plus_max_resource",[`$${e.toLocaleString()}`,z("resource_Money_name")])}
                            ${a}${r}
                            ${z("city_max_morale",[1])}
                            `,s=Math.log2(1+t.resource[t.race.species].amount)*(t.race.gambler?2.5+t.race.gambler/10:2.5);return t.tech.gambling&&t.tech.gambling>=2&&(s*=t.tech.gambling>=5?2:1.5),t.tech.stock_exchange&&t.tech.gambling>=4&&(s*=1+.01*t.tech.stock_exchange),"corpocracy"===t.civic.govern.type&&(s*=3),"socialist"===t.civic.govern.type&&(s*=.8),t.race.inflation&&(s*=1+t.race.inflation/1250),t.tech.isolation&&(s*=1.25,t.tech.iso_gambling&&(s*=1+.05*ea(t.civic.banker.workers,"banker"))),s=+s.toFixed(2),i+=`
                            ${z("tech_casino_effect2",[s])}
                            `,i}function Dr(e,a,r,i){return((t.evolution.hasOwnProperty(e)?t.evolution[e].count:0)+(i||0))*r+a}function Br(e){return t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),Math.round(e)}function Gr(){let e=1.25*(t.tech.storage-1)+1;t.tech.storage>=3&&(e*=t.tech.storage>=4?3:1.5),t.race.pack_rat&&(e*=1+Ei.pack_rat.vars()[1]/100);let a=ts("kobold");return a>0&&(e*=1+Ei.pack_rat.vars(1)[1]/100*a),t.tech.storage>=6&&(e*=1+t.tech.supercollider/20),t.tech.tp_depot&&(e*=1+t.tech.tp_depot/20),t.tech.shelving&&t.tech.shelving>=3&&(e*=1.5),t.stats.achieve.blackhole&&(e*=1+.05*t.stats.achieve.blackhole.l),e*=t.tech.world_control?3:1,t.race.ascended&&(e*=1.1),t.blood.hoarder&&(e*=1+t.blood.hoarder/100),t.tech.storage>=7&&t.interstellar.cargo_yard&&(e*=1+t.interstellar.cargo_yard.count*_/100),e}function Nr(e){if((t.race.kindling_kindred||t.race.smoldering)&&"lumber"===e)return!1;if((t.race.kindling_kindred||t.race.smoldering)&&"stone"===e)return!0;let a=t.race.truepath?"truepath":"standard";if(Mr.city[e].hasOwnProperty("path")&&!Mr.city[e].path.includes(a))return!1;var r=!0;return Object.keys(Mr.city[e].reqs).forEach((function(a){(!t.tech[a]||t.tech[a]=3&&(i=!0,t.r_queue.queue.forEach((function(e){Hr(e.type,!1)&&(a[Mr[e.action][e.type].grant[0]]={v:Mr[e.action][e.type].grant[1],a:e.type})})),Object.keys(s).forEach((function(r){let s=t.tech[r]||0;Rr(r,t.tech[r])||(!a[r]||a[r].vs+1)&&(i=!1)}))),!(!r&&!i||t.tech[Mr.tech[e].grant[0]]&&!(t.tech[Mr.tech[e].grant[0]]`).appendTo("#city").append(`

                            ${z(`city_dist_${a}`)}

                            `),e[a].forEach((function(e){Jr("city",e)})),ls(`dist-${a}`,(function(){return z(`city_dist_${a}_desc`)}),{elm:`#city-dist-${a} h3`,classes:"has-background-light has-text-dark"})}}))}function Qr(){if(!t.settings.tabLoad&&3!==t.settings.civTabs)return;let e={},a={},r={},i=[],s=[],n=[];["primitive","civilized","discovery","industrialized","globalized","early_space","deep_space","interstellar","intergalactic"].forEach((function(e){r[e]=[]}));const c={interstellar:"solar"};let o={};Object.keys(Mr.tech).forEach((function(l){if(!function(e){let a=t.race.truepath?"truepath":"standard";return!(!jr[a].includes(Mr.tech[e].era)&&!Mr.tech[e].hasOwnProperty("path")||Mr.tech[e].hasOwnProperty("path")&&!Mr.tech[e].path.includes(a))}(l))return;ti(Mr.tech[l].id);let _=function(e){let a=Mr.tech[e].grant[0];if(t.tech[a]&&t.tech[a]>=Mr.tech[e].grant[1]){if("fanaticism"!==e&&"anthropology"!==e&&"deify"!==e&&"study"!==e)return!0;if("fanaticism"===e&&t.tech.fanaticism)return!0;if("anthropology"===e&&t.tech.anthropology)return!0;if("deify"===e&&t.tech.ancient_deify)return!0;if("study"===e&&t.tech.ancient_study)return!0}return!1}(l),d=Mr.tech[l],p="category"in d?d.category:"research";if(_||-1!==i.indexOf(p)||i.push(p),_&&-1===s.indexOf(p)&&s.push(p),-1===n.indexOf(p)&&n.push(p),!0===_)p in a||(a[p]=[]),a[p].push(l);else{let a=Mr.tech[l];if(!Ur(a))return;let i=Hr(l,o);if(!i)return;p in e||(e[p]=[]);let s=t.race.truepath&&c[a.era]?c[a.era]:a.era;r.hasOwnProperty(s)||(r[s]=[]),r[s].push({t:l,p:"precog"===i})}})),Ss($("#tech")),Object.keys(r).forEach((function(e){r[e].length>0&&($("#tech").append(`

                            ${z(`tech_era_${e}`)}

                            `),r[e].sort((function(e,t){return null==Mr.tech[e.t].cost.Knowledge?-1:null==Mr.tech[t.t].cost.Knowledge||Mr.tech[e.t].cost.Knowledge()>Mr.tech[t.t].cost.Knowledge()?1:-1})),r[e].forEach((function(e){Jr("tech",e.t,!1,!!e.p&&o)})))})),n.forEach((function(e){Ss($(`#tech-dist-${e}`),!0),Ss($(`#tech-dist-old-${e}`),!0)})),s.forEach((function(e){if(!(e in a))return;$(`
                            `).appendTo("#oldTech").append(`

                            ${z(`tech_dist_${e}`)}

                            `);let t=Js(4,12,!1);t.length>0&&"science"===e&&$("#tech-dist-old-science h3").append(t),a[e].forEach((function(e){Jr("tech",e,!0,!1)}))}))}function Jr(e,t,a,r){Zr(Mr[e][t],e,t,a,r)}function Zr(e,a,r,i,s){if(!1===Ur(e))return;let n=a;"outerSol"===a&&(a="space"),e.region&&(a=e.region),e.powered&&!t[a][r].on&&(t[a][r].on=0);let c=e.id;ti(c);let o="";s&&e&&e.reqs&&Object.keys(e.reqs).forEach((function(e){s[e]&&(o+=` data-req-${e}="${s[e].a}"`)}));let l,_=e.highlight&&e.highlight()?$(`
                            `):$(`
                            `);if(ii(e,!1,["genes","blood"].includes(a))||_.addClass("cna"),ii(e,!0,["genes","blood"].includes(a))||_.addClass("cnam"),i)l=$('{{ title }}');else{let t="",r="";if(e.cost){let i="genes"!==a&&"blood"!==a?Ns(e):e.cost;Object.keys(i).forEach((function(e){let a=i[e]();a>0&&(t+=` res-${e}`,r+=` data-${e}="${a}"`)}))}let i="";e.class&&(i="function"==typeof e.class?` ${e.class()}`:` ${e.class}`),s&&(i=" precog");let n=e.highlight?e.highlight()?`${z("active")}`:`${z("not_active")}`:"";l=$(`${n}{{ title }} description`)}if(_.append(l),e.hasOwnProperty("special")&&("function"==typeof e.special&&e.special()||!0===e.special)){let e=$('
                            \n \n
                            ');_.append(e)}if(e.on||e.off){if(e.on){let e=$('');_.append(e)}if(e.off){let e=$('');_.append(e)}}else if(e.powered&&t.tech.high_tech&&t.tech.high_tech>=2&&Vr(e)||e.switchable&&e.switchable()){let t=$(``),a=$(``);_.append(t),_.append(a)}if(e.count){let t=e.count();t>1&&l.append($(`${t}`))}else"tech"!==a&&t[a]&&t[a][r]&&t[a][r].count>=0?l.append($('{{ act.count }}')):"blood"===a&&t[a]&&t[a][e.grant[0]]&&t[a][e.grant[0]]>0&&"*"===e.grant[1]&&l.append($(` ${t[a][e.grant[0]]} `));if("tech"!==a&&t[a]&&t[a][r]&&void 0!==t[a][r].repair&&l.append($('
                            ')),i?$("#oldTech").append(_):$("#"+n).append(_),"tech"!==a&&t[a]&&t[a][r]&&0===t[a][r].count&&($(`#${c} .count`).css("display","none"),$(`#${c} .special`).css("display","none"),$(`#${c} .on`).css("display","none"),$(`#${c} .off`).css("display","none")),e.emblem){let t=e.emblem();_.append($(t))}let d={template:''};Cs({el:"#"+c,data:{title:"string"==typeof e.title?e.title:e.title(),act:t[a][r]},methods:{action(){"ontouchstart"in document.documentElement&&navigator.userAgent.match(t.settings.touch)||Xr(e,a,r)},describe(){q(function(e,a){let r="string"==typeof e.desc?e.desc:e.desc();if(r+=". ",e.cost&&!a){r=ii(e)?r+z("affordable")+". ":r+z("not_affordable")+". ",r+="Costs: ";let a=e.id.split("-")[0];var i="genes"!==a&&"blood"!==a?Ns(e):e.cost;Object.keys(i).forEach((function(e){if("Custom"===e){let t=i[e]();r+=t.label}else if("Structs"===e){let a=i[e]();Object.keys(a).forEach((function(e){Object.keys(a[e]).forEach((function(i){let s="";if(a[e][i].hasOwnProperty("s")){let t=a[e][i].s;s="string"==typeof Mr[e][t][i].title?Mr[e][t][i].title:Mr[e][t][i].title()}else s="string"==typeof Mr[e][i].title?Mr[e][i].title:Mr[e][i].title();r+=`${s}. `,t[e][i]?a[e][i].count>t[e][i].count?r+=`${z("insufficient")} ${s}. `:a[e][i].hasOwnProperty("on")&&a[e][i].on>t[e][i].on&&(r+=`${z("insufficient")} ${s} enabled. `):r+=`${z("insufficient")} ${s}. `}))}))}else if(t.prestige.hasOwnProperty(e)){let a=i[e]();if(a>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let i=z(`resource_${e}_name`);r+=`${i}: ${a}. `,t.prestige[e].count0){let i=z(`resource_${e}_name`);r+=`${i}: ${a}. `,t.portal.purifier.supply0){let e="Money"===s?"$":t.resource[s].name+": ";e=e.replace("_"," ");let i=x(a,1);r+=`${e}${i}. `,t.resource[s].amount0&&(clearInterval(t),oi(e,r))}),50)}},on_label:()=>`on: ${t[a][r].on}`,off_label:()=>"off: "+(t[a][r].count-t[a][r].on),power_on(){let i=y();for(let e=0;e0;e++)t[a][r].on--;e.postPower&&setTimeout((function(){e.postPower(!1)}),250)},repair:()=>t[a][r].repair,repairMax:()=>e.repair()},filters:{val(t){switch(t){case"on":return e.on();case"off":return e.off()}},p_off(e,i){let s=t[a][r].count-e;if("city-casino"===i&&!t.race.cataclysm&&!t.race.orbit_decayed||"space-spc_casino"===i&&(t.race.cataclysm||t.race.orbit_decayed)||"tauceti-tauceti_casino"===i&&t.tech.isolation){let e=Qs(5,12);if(0===s&&e.length>0)return e}return s},p_on(e,a){if("city-biolab"===a&&!t.race.cataclysm&&!t.race.orbit_decayed||(t.race.cataclysm||t.race.orbit_decayed)&&"space-exotic_lab"===a||t.tech.isolation&&"tauceti-infectious_disease_lab"===a){let t=Qs(12,12);if(0===e&&t.length>0)return t}else if("city-garrison"===a||"space-space_barracks"===a){let t=Js(1,14,!0);if(e===("city-garrison"===a?13:0)&&t.length>0)return t}return e},title:e=>e,options:e=>z("action_options",[e])}}),ls(c,(function(){}),{in:function(s){ei(s.popper,e,t[a][r],i,a,r)},out:function(){Cs({el:"#popTimer"},"destroy")},attach:"starDock"===a?"body .modal":"#main",wide:e.wide})}function Xr(e,a,r){if("spcdock-launch_ship"===e.id)e.action();else switch(a){case"tech":if(t.settings.qKey&&f.q||!Hr(r,!1)||!e.action()){if((!e.no_queue||!e.no_queue())&&t.tech.r_queue&&t.r_queue.queue.length0){let o=t.settings.qKey?i:1;o>t.queue.max-s&&(o=t.queue.max-s);let l=e.queue_size?e.queue_size:1;if(e.region&&(a=e.id.split("-")[0]),"merge_never"!==t.settings.q_merge)t.queue.queue.length>0&&t.queue.queue[t.queue.queue.length-1].id===e.id?t.queue.queue[t.queue.queue.length-1].q+=Math.min(c,l*o):t.queue.queue.push({id:e.id,action:a,type:r,label:"string"==typeof e.title?e.title:e.title(),cna:!1,time:0,q:Math.min(c,l*o),qs:l,t_max:0,bres:!1});else for(let i=0;i0;i++)t.queue.queue.push({id:e.id,action:a,type:r,label:"string"==typeof e.title?e.title:e.title(),cna:!1,time:0,q:Math.min(c,l),qs:l,t_max:0,bres:!1}),c-=l;n=!0}}break}t.race.inflation&&t.tech.primitive&&(e.hasOwnProperty("inflation")&&!e.inflation||t.race.inflation++),s=!0}if(s&&(function(e,a,r){if(!ii(e)){let t=e.id;$(`#${t}`).addClass("cna")}if(e.grant){let a=e.grant[0];(!t.tech[a]||t.tech[a]a?(s.q=a,a=0):a-=s.q)}}n&&ys();break}}}function Yr(e,a){let r=e.id.split("-");if(t.hasOwnProperty(r[0])&&t[r[0]].hasOwnProperty(r[1])&&e.hasOwnProperty("powered")){let i=t.city.power;return t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks")&&t.race.hasOwnProperty("replicator")&&Object.values(t.race.governor.tasks).includes("replicate")&&t.race.governor.config.replicate.pow.on&&t.race.replicator.pow>0&&(i+=t.race.replicator.pow),!(t.city.hasOwnProperty("powered")&&i>=e.powered()&&(t[r[0]][r[1]].on++,t.race.hasOwnProperty("governor")&&t.race.governor.hasOwnProperty("tasks")&&t.race.hasOwnProperty("replicator")&&Object.values(t.race.governor.tasks).includes("replicate")&&t.race.governor.config.replicate.pow.on&&t.race.replicator.pow>0&&(t.city.power-=e.powered(),B.replicate.task()),a&&"function"==typeof a))||a(e)}return!1}function ei(e,a,r,i,s,n,c){Ss(e);var o="string"==typeof a.desc?a.desc:a.desc();c=c||!1;let l=!1;!(s&&n&&"ontouchstart"in document.documentElement&&navigator.userAgent.match(/Mobi/)&&t.settings.touch)||(l=$(`${a.hasOwnProperty("touchlabel")?a.touchlabel:z("construct")}`),e.append(l),$("#touchButton").on("touchstart",(function(){Xr(a,s,n)}))),e.append($(`
                            ${o}
                            `));let _=a.id.split("-")[0];a.category&&"tech"===_&&!i&&e.append($(`
                            ${z("tech_dist_category")}: ${z(`tech_dist_${a.category}`)}
                            `));let d=Os(a,!1,!0);if(a.cost&&!i){let r=!0;var p=$('
                            '),u="genes"!==_&&"blood"!==_?Ns(a):a.cost;Object.keys(u).forEach((function(e){if("Custom"===e){let t=u[e]();p.append($(`
                            ${t.label}
                            `)),r=!1}else if("Structs"===e){let a=u[e]();Object.keys(a).forEach((function(e){Object.keys(a[e]).forEach((function(i){let s=a[e][i].hasOwnProperty("on")?a[e][i].on:a[e][i].count,n="has-text-dark",c="";t[e][i]?a[e][i].count>t[e][i].count?(n="has-text-danger",c=' (blocking resource)'):a[e][i].hasOwnProperty("on")&&a[e][i].on>t[e][i].on&&(n="has-text-alert"):(n="has-text-danger",c=' (blocking resource)');let o="";if(a[e][i].hasOwnProperty("s")){let t=a[e][i].s;o="string"==typeof Mr[e][t][i].title?Mr[e][t][i].title:Mr[e][t][i].title()}else o="string"==typeof Mr[e][i].title?Mr[e][i].title:Mr[e][i].title();r=!1,p.append($(`
                            ${o}: ${s}${c}
                            `))}))}))}else if(t.prestige.hasOwnProperty(e)){let a=u[e]();if(a>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let i=z(`resource_${e}_name`),s="has-text-dark",n="";t.prestige[e].count(blocking resource)'),r=!1,p.append($(`
                            ${i}: ${a}${n}
                            `))}}else if("Supply"===e){let a=u[e]();if(a>0){let i=z(`resource_${e}_name`),s="has-text-dark",n="";t.portal.purifier.supply(blocking resource)'),r=!1,p.append($(`
                            ${i}: ${a}${n}
                            `))}}else if("Morale"!==e&&"Army"!==e&&"Bool"!==e){let a=u[e]();if(a>0){let i="",s="Species"===e?t.race.species:e;if("HellArmy"===e){let n=z("fortress_troops"),c="has-text-dark";t.portal.fortress.garrison-t.portal.fortress.patrols*t.portal.fortress.patrol_size(blocking resource)'):c="has-text-alert"),r=!1,p.append($(`
                            ${n}: ${a}${i}
                            `))}else{let i="Money"===s?"$":t.resource[s].name+": ";i=i.replace("_"," ");let n="has-text-dark",o="";t.resource[s].amount(blocking resource)'):n="has-text-alert",c&&c!==e&&d.r===s?(n+=" grad-from-left",o=' (first blocking resource)'):c&&c===e&&d.r!==s&&(n+=" grad-from-left-warn")):c&&c===e&&(n+=" grad-from-right",o=' (last blocking resource)');let l=x(a,1);r=!1,p.append($(`
                            ${i}${l}${o}
                            `))}}}})),r||e.append(p)}if(a.effect){var h="string"==typeof a.effect?a.effect:a.effect();h&&e.append($(`
                            ${h}
                            `))}if(a.flair){var m="string"==typeof a.flair?a.flair:a.flair();e.append($(`
                            ${m}
                            `)),e.addClass("flair")}if(a.reqs){let t=[];if(Object.keys(a.reqs).forEach((function(e){let r=$(`#${a.id}`).attr(`data-req-${e}`);r&&t.push("string"==typeof Mr.tech[r].title?Mr.tech[r].title:Mr.tech[r].title())})),t.length>0){let a=t.join(", ");e.append($(`
                            ${z("requires_tech",[a])}
                            `))}}if(!i&&"blood"!==a.id.substring(0,5)&&!ii(a)&&ii(a,!0)){if("string"==typeof r&&"notimer"===r)return;if(r&&r.time)e.append($('
                            {{ time | timer }}
                            ')),Cs({el:"#popTimer",data:r,filters:{timer:e=>z("action_ready",[e])}});else{let t=zs(d.t);e.append($(`
                            ${z("action_ready",[t])}
                            `))}}("portal-spire"===a.id||"portal-waygate"===a.id&&t.tech.waygate>=2)&&r&&r.time&&(e.append($('
                            {{ time | timer }}
                            ')),Cs({el:"#popTimer",data:r,filters:{timer:e=>z("floor_clearing",[!a.hasOwnProperty("mscan")||a.hasOwnProperty("mscan")&&a.mscan()>0?e:"???"])}}))}function ti(e){Ss($(`#${e}`),!0),_s(e)}function ai(e,a,r){var i=e.id;t[a]&&t[a][r]&&t[a][r].count&&($(`#${i} .count`).html(t[a][r].count),t[a][r]&&t[a][r].count>0&&($(`#${i} .count`).css("display","inline-block"),$(`#${i} .special`).css("display","block"),$(`#${i} .on`).css("display","block"),$(`#${i} .off`).css("display","block"))),$("#popper").data("id")===i&&ei($("#popper"),e,t[a][r],!1,a,r)}function ri(e,a){return!!si(a=a||Ns(e))&&(Object.keys(a).forEach((function(e){if(t.prestige.hasOwnProperty(e)){let r=a[e]();"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].count-=r}else if("Supply"===e){let r=a[e]();t.portal.purifier.supply-=r}else if("Morale"!==e&&"Army"!==e&&"HellArmy"!==e&&"Structs"!==e&&"Bool"!==e&&"Custom"!==e){let r=a[e](),i="Species"===e?t.race.species:e;t.resource[i].amount-=r,"Knowledge"===i&&(t.stats.know+=r)}})),!0)}function ii(e,a,r){if(e.cost){let n=r?e.cost:Ns(e);return a?(i=n,s=!0,Object.keys(i).forEach((function(e){if("Custom"===e);else if("Structs"===e){if(!ni(i[e]()))return void(s=!1)}else if(t.prestige.hasOwnProperty(e)){let a=e;if("Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid"),t.prestige[e].count0||t.resource[r].max>=0&&a>Number(t.resource[r].max)&&-1!==Number(t.resource[r].max))return void(s=!1)}})),s):si(n)}var i,s;return!0}function si(e){var a=!0;return Object.keys(e).forEach((function(r){if("Custom"===r){if(!e[r]().met)return void(a=!1)}else if("Structs"===r){if(!ni(e[r]()))return void(a=!1)}else if(t.prestige.hasOwnProperty(r)){let i=r;if("Plasmid"===r&&"antimatter"===t.race.universe&&(r="AntiPlasmid"),t.prestige[r].count=0&&i>t.resource[s].max;if(i>Number(t.resource[s].amount)+t.resource[s].diff||n)return void(a=!1)}})),a}function ni(e){let a=!0;return Object.keys(e).forEach((function(r){t.hasOwnProperty(r)?Object.keys(e[r]).forEach((function(i){t[r].hasOwnProperty(i)?(t[r][i].count${r}

                            `));var i=$('
                            ');switch($("#modalBox").append(i),a){case"smelter":case"hell_smelter":case"stellar_forge":case"hell_forge":case"geothermal":case"ore_refinery":wi("smelter",i);break;case"factory":case"red_factory":case"int_factory":case"tau_factory":wi("factory",i);break;case"star_dock":!function(e){if(t.tech.genesis<4){let t=$(`
                            ${z("stardock_warn")}
                            `);return void e.append(t)}let a=$('
                            ');e.append(a),Zr(Mr.starDock.probes,"starDock","probes"),t.tech.geck&&t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5&&Zr(Mr.starDock.geck,"starDock","geck"),t.tech.genesis>=5&&Zr(Mr.starDock.seeder,"starDock","seeder"),6===t.tech.genesis&&Zr(Mr.starDock.prep_ship,"starDock","prep_ship"),t.tech.genesis>=7&&Zr(Mr.starDock.launch_ship,"starDock","launch_ship")}(i);break;case"mining_droid":wi("droid",i);break;case"g_factory":case"refueling_station":wi("graphene",i);break;case"freighter":case"super_freighter":Qa(i);break;case"pylon":wi("pylon",i);break;case"rock_quarry":wi("rock_quarry",i);break;case"titan_mine":wi("titan_mine",i);break;case"mining_ship":wi("mining_ship",i);break;case"alien_space_station":wi("alien_space_station",i);break;case"nanite_factory":wi("nanite_factory",i);break;case"alien_outpost":wi("replicator",i)}}function li(){Ss($("#evolution .evolving"),!0);let e=$(`
                            ${t.evolution.final}%
                            `);$("#evolution").append(e)}function _i(){return"magic"===t.race.universe?z("city_wizard_tower_title"):t.race.evil?z("city_babel_title"):z("city_wardenclyffe")}function di(){switch(t.race.species){case"orc":return z("city_basic_housing_orc_title");case"wolven":return z("city_basic_housing_wolven_title");case"sporgar":return z("city_basic_housing_sporgar_title");case"dracnid":case"balorg":return z("city_basic_housing_title7");case"imp":return z("city_basic_housing_title8");case"seraph":return z("city_basic_housing_seraph_title");case"unicorn":return z("city_basic_housing_unicorn_title")}switch(Ki[t.race.species].type){case"avian":return z("city_basic_housing_nest_title");case"plant":return z("city_basic_housing_entish_title");case"sand":return z("city_basic_housing_sand_title");case"polar":return z("city_basic_housing_polar_title");case"eldritch":return z("city_basic_housing_eldritch_title")}return t.city.ptrait.includes("trashed")?z("city_basic_housing_trash_title"):z("city_basic_housing_title")}function pi(e,a){switch(e){case"small":return di();case"medium":return function(){switch(t.race.species){case"sporgar":return z("city_cottage_title2");case"balorg":return z("city_cottage_title3");case"imp":return z("city_basic_housing_title7");case"seraph":return z("city_cottage_title4");case"unicorn":return z("city_cottage_title5");case"dracnid":return z("city_cottage_title7")}switch(Ki[t.race.species].type){case"avian":return z("city_cottage_title6");case"eldritch":return z("city_cottage_title8")}return z("city_cottage_title1")}();case"large":return function(e){if(!e&&K("extravagant",0))return z("city_mansion");if("sporgar"===t.race.species)return z("city_apartment_title2");switch(Ki[t.race.species].type){case"avian":return z("city_apartment_title5");case"sand":return z("city_apartment_title6");case"demonic":return z("city_apartment_title3");case"angelic":return z("city_apartment_title4");case"giant":return z("city_apartment_title7");case"eldritch":return z("city_apartment_title8")}return z("city_apartment_title1")}(a)}}function ui(e,a){if(t.tech.queue&&t.queue.display){let e=["space","interstellar","galaxy","portal","tauceti"];for(let r=0;r-1)if(e.includes(i.action)){let e=!0;Object.keys(Mr[i.action]).forEach((function(a){Mr[i.action][a][i.type]&&e&&(t.queue.queue[r].label="string"==typeof Mr[i.action][a][i.type].title?Mr[i.action][a][i.type].title:Mr[i.action][a][i.type].title(),e=!1)}))}else Mr[i.action][i.type]&&(t.queue.queue[r].label="string"==typeof Mr[i.action][i.type].title?Mr[i.action][i.type].title:Mr[i.action][i.type].title())}}if(e&&t.tech.r_queue&&t.r_queue.display)for(let e=0;e=4&&es(e)})),Object.keys(Ki[t.race.species].traits).forEach((function(e){es(e,{set:Ki[t.race.species].traits[e]})})),t.race.imitation&&t.race.srace&&Xi(!1),Object.keys(t.tech).forEach((function(e){"evo_"===e.substring(0,4)&&delete t.tech[e]})),delete t.tech.evo,t.evolution={};const s=new Date;!t.settings.boring&&11===s.getMonth()&&s.getDate()>=17&&("elven"===t.race.species?(es("slaver",{set:2}),es("resourceful",{set:.5}),es("small",{set:.25})):"capybara"===t.race.species?(es("beast_of_burden",{set:1}),es("pack_rat",{set:.5}),es("musical",{set:.25})):"centaur"===t.race.species?(es("beast_of_burden",{set:1}),es("curious",{set:.5}),es("blissful",{set:.25})):"wendigo"===t.race.species?(es("immoral",{set:3}),es("cannibalize",{set:.5}),es("claws",{set:.25})):"yeti"===t.race.species?(es("scavenger",{set:3}),es("regenerative",{set:.5}),es("musical",{set:.25})):"entish"===t.race.species&&(es("photosynth",{set:3}),es("optimistic",{set:.5}),es("armored",{set:.25})));const n=cn("easter");if("wolven"===t.race.species&&n.active?(es("hyper",{set:1}),es("fast_growth",{set:1}),es("rainbow",{set:1}),es("optimistic",{set:1})):"vulpine"===t.race.species&&n.active&&(es("cannibalize",{set:2}),es("rage",{set:1}),es("blood_thirst",{set:1}),es("sticky",{set:1})),t.race.no_crispr||t.race.badgenes){let e=t.race.badgenes?3:1;for(let a=0;a=2)for(let e=1;e<8;e++)t.genes.evolve>=e+1&&Gi(e);let l=xs();t.civic.foreign.gov0.name={s0:l.s0,s1:l.s1};let _=xs();for(;l.s0===_.s0&&l.s1===_.s1;)_=xs();t.civic.foreign.gov1.name={s0:_.s0,s1:_.s1};let d=xs();for(;l.s0===d.s0&&l.s1===d.s1||_.s0===d.s0&&_.s1===d.s1;)d=xs();if(t.civic.foreign.gov2.name={s0:d.s0,s1:d.s1},t.race.truepath||t.race.lone_survivor){t.civic.foreign.gov0.mil=Math.round(1.5*t.civic.foreign.gov0.mil),t.civic.foreign.gov1.mil=Math.round(1.4*t.civic.foreign.gov1.mil),t.civic.foreign.gov2.mil=Math.round(1.25*t.civic.foreign.gov2.mil),t.civic.foreign.gov3={unrest:0,hstl:Math.floor(m(20,40)),mil:Math.floor(m(650,750)),eco:Math.floor(m(250,300)),spy:0,esp:0,trn:0,sab:0,act:"none"};let e=xs(!0);t.civic.foreign.gov3.name={s0:e.s0,s1:e.s1},t.civic.foreign.gov4={unrest:0,hstl:100,mil:300,eco:100,spy:0,esp:0,trn:0,sab:0,act:"none"};let a=xs(!0);for(;a.s1===e.s1;)a=xs(!0);t.civic.foreign.gov4.name={s0:99,s1:a.s1}}if(t.race.cataclysm?hs(z("cataclysm_sentience",[Ki[t.race.species].home,nn("name")]),"info",!1,["progress"]):hs(z("sentience",[z("genelab_genus_"+Ki[t.race.species].type),Ki[t.race.species].entity,nn("name")]),"info",!1,["progress"]),t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1&&(t.resource.Steel.display=!0,t.resource.Steel.amount=25,t.stats.achieve.technophobe.l>=3)){t.race.truepath||(t.resource.Soul_Gem.display=!0);let e=1;for(let a=1;a=5&&e++;t.resource.Soul_Gem.amount=e}if("tortoisan"===t.race.species){let e=Math.floor(m(100));t.race.shell_color=99===e?"rainbow":e>=97&&e<=98?"white":e>=93&&e<=96?"red":e>=89&&e<=92?"orange":e>=85&&e<=88?"yellow":e>=75&&e<=84?"purple":e>=65&&e<=74?"blue":"green"}if("vulpine"===t.race.species){let e=Math.floor(m(100));t.race.fox_color=e>=85?"white":e>=70&&e<=84?"tan":e>=55&&e<=69?"silver":e>=35&&e<=54?"grey":"red"}if(Ks(!0),t.blood.aware&&(t.settings.arpa.blood=!0,t.tech.b_stone=2),Yt(!0),Q(),V(!0),t.race.shapeshifter&&Yi(!1,!0),t.race.carnivore||t.race.soul_eater||t.race.unfathomable?(t.civic.d_job="hunter",t.civic.hunter.display=!0):t.race.forager?(t.civic.d_job="forager",t.civic.forager.display=!0):(t.civic.d_job="unemployed",t.civic.unemployed.display=!0),t.race.hooved&&(t.resource.Horseshoe.display=!0,t.resource.Horseshoe.amount=5,t.race.shoecnt=5),t.race.deconstructor&&(t.resource.Nanite.display=!0,t.city.nanite_factory={count:1,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Bolognium:0,Orichalcum:0},t.settings.showIndustry=!0),Ts(!0),(t.race.truepath||t.race.lone_survivor)&&Object.keys(Ca).forEach((function(e){t.resource.hasOwnProperty(e)&&(t.resource[e].value=2*Ca[e])})),Ti(t.race.species,!0),ks("sentience",{species:t.race.species,challenge:Mn()-1}),t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0){let e=Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept);t.resource.Food.amount+=100*e,t.resource.Stone.max+=60*e,t.resource.Stone.amount+=100*e,t.race.smoldering?(t.resource.Chrysotile.max+=60*e,t.resource.Chrysotile.amount+=100*e):(t.resource.Lumber.max+=60*e,t.resource.Lumber.amount+=100*e)}t.race.cataclysm?t.race.cataclysm&&(t.tech.unify=2,t.tech.spy=5,t.tech.primitive=3,t.tech.currency=6,t.tech.govern=3,t.tech.boot_camp=1,t.tech.medic=1,t.tech.military=5,t.tech.marines=1,t.tech.explosives=3,t.tech.trade=3,t.tech.wharf=1,t.tech.banking=6,t.tech.gambling=1,t.tech.home_safe=1,t.tech.housing=3,t.tech.smelting=3,t.tech.copper=1,t.tech.storage=5,t.tech.container=4,t.tech.steel_container=3,t.tech.mining=4,t.tech.oil=7,t.tech.mass=1,t.tech.alumina=1,t.tech.titanium=2,t.tech.polymer=2,t.tech.uranium=4,t.tech.foundry=7,t.tech.factory=1,t.tech.theatre=3,t.tech.broadcast=2,t.tech.mine_conveyor=1,t.tech.science=9,t.tech.high_tech=7,t.tech.genetics=1,t.tech.theology=2,t.tech.space=6,t.tech.solar=3,t.tech.luna=2,t.tech.hell=1,t.tech.mars=5,t.tech.gas_giant=1,t.tech.gas_moon=2,t.tech.asteroid=3,t.tech.satellite=1,t.tech.space_explore=4,t.tech.genesis=2,t.settings.showSpace=!0,t.settings.space.home=!0,t.settings.space.moon=!0,t.settings.space.red=!0,t.settings.space.hell=!0,t.settings.space.sun=!0,t.settings.space.gas=!0,t.settings.space.gas_moon=!0,t.settings.space.belt=!0,t.settings.space.dwarf=!0,t.settings.showCity=!1,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.settings.civTabs=1,t.settings.spaceTabs=1,t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Food.display=!0,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Cement.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Uranium.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Alloy.display=!0,t.resource.Polymer.display=!0,t.resource.Iridium.display=!0,t.resource.Helium_3.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Mythril.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.resource.Lumber.max=9e4,t.resource.Lumber.amount=9e4,t.resource.Plywood.amount=5e4),t.race.smoldering&&(t.resource.Chrysotile.display=!0,t.resource.Chrysotile.max=9e4,t.resource.Chrysotile.amount=9e4),t.resource[t.race.species].max=8,t.resource[t.race.species].amount=8,t.resource.Crates.amount=20,t.resource.Containers.amount=20,t.resource.Money.max=225e3,t.resource.Money.amount=225e3,t.resource.Food.max=1e3,t.resource.Food.amount=1e3,t.resource.Oil.max=1e3,t.resource.Oil.amount=1e3,t.resource.Helium_3.max=1e3,t.resource.Helium_3.amount=1e3,t.resource.Uranium.max=1e3,t.resource.Uranium.amount=1e3,t.resource.Stone.max=9e4,t.resource.Stone.amount=9e4,t.resource.Furs.max=4e4,t.resource.Furs.amount=4e4,t.resource.Copper.max=75e3,t.resource.Copper.amount=75e3,t.resource.Iron.max=75e3,t.resource.Iron.amount=75e3,t.resource.Steel.max=75e3,t.resource.Steel.amount=75e3,t.resource.Aluminium.max=75e3,t.resource.Aluminium.amount=75e3,t.resource.Cement.max=75e3,t.resource.Cement.amount=75e3,t.resource.Titanium.max=75e3,t.resource.Titanium.amount=75e3,t.resource.Coal.max=1e4,t.resource.Coal.amount=1e4,t.resource.Alloy.max=2e4,t.resource.Alloy.amount=2e4,t.resource.Polymer.max=2e4,t.resource.Polymer.amount=2e4,t.resource.Iridium.max=1e3,t.resource.Iridium.amount=1e3,t.resource.Brick.amount=5e4,t.resource.Wrought_Iron.amount=5e4,t.resource.Sheet_Metal.amount=5e4,t.resource.Mythril.amount=8e3,t.resource.Iridium.crates=5,t.resource.Iridium.containers=5,t.civic.taxes.display=!0,t.civic.professor.display=!0,t.civic.scientist.display=!0,t.civic.colonist.display=!0,t.civic.space_miner.display=!0,t.race.flier||(t.tech.cement=5,t.civic.cement_worker.display=!0,t.civic.cement_worker.max=1,t.civic.cement_worker.workers=1),t.civic.colonist.max=4,t.civic.colonist.workers=4,t.civic.space_miner.max=3,t.civic.space_miner.workers=2,t.civic.professor.max=1,t.civic.professor.workers=1,t.city.calendar.day++,t.city.market.active=!0,t.city.power=0,t.city.powered=!0,t.race.artifical&&(t.city.transmitter={count:0,on:0}),t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:0,cap:2,Wood:0,Coal:0,Oil:2,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:1,Iridium:0},t.city.fission_power={count:0,on:0},t.city.oil_power={count:0,on:0},t.city.coal_power={count:0,on:0},t.city.mass_driver={count:0,on:0},t.city.mine={count:0,on:0},t.city.coal_mine={count:0,on:0},t.city.oil_well={count:0},t.city.oil_depot={count:0},t.city.garrison={count:0,on:0},t.city.basic_housing={count:0},t.city.cottage={count:0},t.city.apartment={count:0,on:0},t.city.amphitheatre={count:0},t.city.casino={count:0,on:0},t.city.rock_quarry={count:0,on:0,asbestos:50},t.city.metal_refinery={count:0,on:0},t.city.storage_yard={count:0},t.city.warehouse={count:0},t.city.trade={count:0},t.city.wharf={count:0},t.city.bank={count:0},t.city.tourist_center={count:0,on:0},t.city.university={count:0},t.city.library={count:0},t.city.wardenclyffe={count:0,on:0},t.city.biolab={count:0,on:0},t.city.lumber_yard={count:0},t.city.sawmill={count:0,on:0},t.city.temple={count:0},t.space.satellite={count:1},t.space.propellant_depot={count:1},t.space.gps={count:4},t.space.nav_beacon={count:1,on:1},t.space.moon_base={count:1,on:1,support:3,s_max:3},t.space.iridium_mine={count:1,on:1},t.space.helium_mine={count:1,on:1},t.space.observatory={count:1,on:1},t.space.spaceport={count:2,on:2,support:8,s_max:10},t.space.red_tower={count:1,on:1},t.space.living_quarters={count:4,on:4},t.space.vr_center={count:0,on:0},t.space.garage={count:1},t.space.red_mine={count:1,on:1},t.space.fabrication={count:1,on:1},t.space.red_factory={count:1,on:1},t.space.exotic_lab={count:1,on:1},t.space.ziggurat={count:0},t.space.space_barracks={count:1,on:1},t.space.biodome={count:2,on:2},t.space.laboratory={count:0,on:0},t.space.geothermal={count:2,on:2},t.space.spc_casino={count:0,on:0},t.space.swarm_plant={count:0},t.space.swarm_control={count:5,support:40,s_max:50},t.space.swarm_satellite={count:40},t.space.gas_mining={count:2,on:2},t.space.gas_storage={count:1},t.space.outpost={count:0,on:0},t.space.drone={count:0},t.space.oil_extractor={count:2,on:2},t.space.space_station={count:1,on:1,support:0,s_max:3},t.space.iridium_ship={count:1,on:1},t.space.elerium_ship={count:0,on:0},t.space.elerium_prospector={count:0,on:0},t.space.iron_ship={count:1,on:1},t.space.elerium_contain={count:0,on:0},t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:2,wounded:0,raid:0,max:2},Wr(),Qr(),Lt(),xe("Physics"),sa()):t.race.lone_survivor?t.race.lone_survivor&&(t.tech.alloy=1,t.tech.alumina=2,t.tech.asteroid=7,t.tech.banking=11,t.tech.biotech=1,t.tech.boot_camp=2,t.tech.broadcast=2,t.tech.container=7,t.tech.copper=1,t.tech.currency=6,t.tech.disease=2,t.tech.drone=1,t.tech.elerium=2,t.tech.explosives=3,t.tech.factory=3,t.tech.foundry=8,t.tech.gambling=4,t.tech.gas_giant=1,t.tech.gas_moon=2,t.tech.genesis=2,t.tech.genetics=2,t.tech.gov_corp=1,t.tech.gov_fed=1,t.tech.gov_soc=1,t.tech.gov_theo=1,t.tech.govern=3,t.tech.graphene=1,t.tech.helium=1,t.tech.hell=1,t.tech.high_tech=13,t.tech.home_safe=2,t.tech.housing=3,t.tech.housing_reduction=3,t.tech.kuiper=2,t.tech.launch_facility=1,t.tech.luna=2,t.tech.m_smelting=2,t.tech.marines=2,t.tech.mars=5,t.tech.mass=1,t.tech.medic=3,t.tech.military=8,t.tech.mine_conveyor=1,t.tech.mining=4,t.tech.monument=1,t.tech.nano=1,t.tech.oil=7,t.tech.outer=8,t.tech.pickaxe=5,t.tech.polymer=2,t.tech.primitive=3,t.tech.q_factory=1,t.tech.quantium=1,t.tech.queue=3,t.tech.r_queue=1,t.tech.reproduction=1,t.tech.rival=1,t.tech.satellite=1,t.tech.science=9,t.tech.shelving=3,t.tech.shipyard=1,t.tech.smelting=6,t.tech.solar=5,t.tech.space=6,t.tech.space_explore=4,t.tech.space_housing=1,t.tech.spy=5,t.tech.stanene=1,t.tech.steel_container=6,t.tech.storage=5,t.tech.swarm=6,t.tech.syard_armor=3,t.tech.syard_class=6,t.tech.syard_engine=5,t.tech.syard_power=5,t.tech.syard_sensor=4,t.tech.syard_weapon=6,t.tech.syndicate=0,t.tech.synthetic_fur=1,t.tech.tau_home=6,t.tech.tauceti=4,t.tech.theatre=3,t.tech.theology=2,t.tech.titan=9,t.tech.titan_ai_core=3,t.tech.titan_power=1,t.tech.titanium=3,t.tech.trade=3,t.tech.unify=2,t.tech.uranium=4,t.tech.v_train=1,t.tech.vault=4,t.tech.wharf=1,t.tech.world_control=1,t.tech.wsc=0,t.race.flier||(t.tech.cement=5,t.resource.Cement.display=!0),"magic"===t.race.universe&&(t.tech.gov_mage=1,t.tech.magic=4,t.tech.conjuring=2,t.resource.Mana.display=!0,t.resource.Crystal.display=!0,t.civic.crystal_miner.display=!0,t.tauceti.pylon={count:0},t.race.casting={farmer:0,miner:0,lumberjack:0,science:0,factory:0,army:0,hunting:0,crafting:0,total:0,crafting:0}),t.settings.showSpace=!1,t.settings.showTau=!0,t.settings.tau.home=!0,t.settings.showCity=!1,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.settings.civTabs=1,t.settings.spaceTabs=6,t.settings.showGenetics=!0,t.settings.arpa.physics=!0,t.settings.arpa.genetics=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.resource.Food.display=!0,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Uranium.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Alloy.display=!0,t.resource.Polymer.display=!0,t.resource.Iridium.display=!0,t.resource.Helium_3.display=!0,t.resource.Water.display=!0,t.resource.Neutronium.display=!0,t.resource.Adamantite.display=!0,t.resource.Elerium.display=!0,t.resource.Nano_Tube.display=!0,t.resource.Graphene.display=!0,t.resource.Stanene.display=!0,t.resource.Orichalcum.display=!0,t.resource.Bolognium.display=!0,t.resource.Unobtainium.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Mythril.display=!0,t.resource.Quantium.display=!0,t.resource.Cipher.display=!0,t.race.kindling_kindred||t.race.smoldering||(t.civic.lumberjack.display=!0,t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.resource.Lumber.max=1e7,t.resource.Lumber.amount=1e7,t.resource.Plywood.amount=25e5,t.resource.Lumber.crates=25,t.resource.Lumber.containers=25,t.tech.axe=5),t.race.smoldering&&(t.resource.Chrysotile.display=!0,t.resource.Chrysotile.max=5e6,t.resource.Chrysotile.amount=5e6),t.race.sappy||(t.tech.hammer=4),t.race.apex_predator||(t.tech.armor=3),t.resource[t.race.species].max=1,t.resource[t.race.species].amount=1,t.resource.Crates.amount=1e3,t.resource.Containers.amount=1e3,t.resource.Money.max=1e9,t.resource.Money.amount=1e9,t.resource.Knowledge.max=8e6,t.resource.Knowledge.amount=8e6,t.resource.Food.max=1e4,t.resource.Food.amount=1e4,t.resource.Oil.max=5e5,t.resource.Oil.amount=5e5,t.resource.Helium_3.max=5e5,t.resource.Helium_3.amount=5e5,t.resource.Water.max=25e3,t.resource.Water.amount=25e3,t.resource.Uranium.max=5e5,t.resource.Uranium.amount=5e5,t.resource.Stone.max=1e7,t.resource.Stone.amount=1e7,t.resource.Furs.max=5e6,t.resource.Furs.amount=5e6,t.resource.Copper.max=5e6,t.resource.Copper.amount=5e6,t.resource.Iron.max=5e6,t.resource.Iron.amount=5e6,t.resource.Steel.max=5e6,t.resource.Steel.amount=5e6,t.resource.Aluminium.max=5e6,t.resource.Aluminium.amount=5e6,t.resource.Cement.max=5e6,t.resource.Cement.amount=5e6,t.resource.Titanium.max=5e6,t.resource.Titanium.amount=5e6,t.resource.Coal.max=5e6,t.resource.Coal.amount=5e6,t.resource.Alloy.max=5e6,t.resource.Alloy.amount=5e6,t.resource.Polymer.max=5e6,t.resource.Polymer.amount=5e6,t.resource.Iridium.max=5e6,t.resource.Iridium.amount=5e6,t.resource.Neutronium.max=5e5,t.resource.Neutronium.amount=5e5,t.resource.Adamantite.max=5e6,t.resource.Adamantite.amount=5e6,t.resource.Elerium.max=1e3,t.resource.Elerium.amount=1e3,t.resource.Nano_Tube.max=5e6,t.resource.Nano_Tube.amount=5e6,t.resource.Graphene.max=5e6,t.resource.Graphene.amount=5e6,t.resource.Stanene.max=5e6,t.resource.Stanene.amount=5e6,t.resource.Bolognium.max=5e6,t.resource.Bolognium.amount=5e6,t.resource.Orichalcum.max=5e6,t.resource.Orichalcum.amount=5e6,t.resource.Brick.amount=25e5,t.resource.Wrought_Iron.amount=25e5,t.resource.Sheet_Metal.amount=25e5,t.resource.Mythril.amount=25e5,t.resource.Quantium.amount=25e5,t.race.artifical||(t.resource.Food.crates=10,t.resource.Food.containers=10),t.resource.Stone.crates=25,t.resource.Stone.containers=25,t.resource.Furs.crates=25,t.resource.Furs.containers=25,t.resource.Coal.crates=10,t.resource.Coal.containers=10,t.resource.Copper.crates=25,t.resource.Copper.containers=25,t.resource.Iron.crates=25,t.resource.Iron.containers=25,t.resource.Aluminium.crates=25,t.resource.Aluminium.containers=25,t.resource.Steel.crates=25,t.resource.Steel.containers=25,t.resource.Titanium.crates=25,t.resource.Titanium.containers=25,t.resource.Alloy.crates=25,t.resource.Alloy.containers=25,t.resource.Polymer.crates=25,t.resource.Polymer.containers=25,t.resource.Iridium.crates=25,t.resource.Iridium.containers=25,t.resource.Adamantite.crates=25,t.resource.Adamantite.containers=25,t.resource.Graphene.crates=25,t.resource.Graphene.containers=25,t.resource.Stanene.crates=25,t.resource.Stanene.containers=25,t.resource.Bolognium.crates=25,t.resource.Bolognium.containers=25,t.resource.Orichalcum.crates=25,t.resource.Orichalcum.containers=25,t.civic.taxes.display=!0,t.race.flier||(t.civic.cement_worker.display=!0,t.resource.Cement.crates=25,t.resource.Cement.containers=25),t.race.sappy||(t.civic.quarry_worker.display=!0),t.civic.professor.display=!0,t.civic.scientist.display=!0,t.civic.banker.display=!0,t.civic.pit_miner.display=!0,t.civic.professor.max=1,t.civic.professor.workers=1,t.city.calendar.day++,t.city.market.active=!0,t.city.power=0,t.city.powered=!0,t.race.artifical&&(t.city.transmitter={count:0,on:0}),t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:0,cap:2,Wood:0,Coal:0,Oil:2,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:1,Iridium:0},t.city.amphitheatre={count:0},t.city.apartment={count:0,on:0},t.city.bank={count:0},t.city.basic_housing={count:0},t.city.biolab={count:0,on:0},t.city.boot_camp={count:0},t.city.casino={count:0,on:0},t.city.cement_plant={count:0,on:0},t.city.coal_mine={count:0,on:0},t.city.coal_power={count:0,on:0},t.city.cottage={count:0},t.city.fission_power={count:0,on:0},t.city.garrison={count:0,on:0},t.city.hospital={count:0},t.city.library={count:0},t.city.lumber_yard={count:0},t.city.mass_driver={count:0,on:0},t.city.metal_refinery={count:0,on:0},t.city.mine={count:0,on:0},t.city.oil_depot={count:0},t.city.oil_power={count:0,on:0},t.city.oil_well={count:0},t.city.rock_quarry={count:0,on:0,asbestos:50},t.city.sawmill={count:0,on:0},t.city.shed={count:0,on:0},t.city.storage_yard={count:0},t.city.temple={count:0},t.city.tourist_center={count:0,on:0},t.city.trade={count:0},t.city.university={count:0},t.city.wardenclyffe={count:0,on:0},t.city.warehouse={count:0},t.city.wharf={count:0},t.space.ai_colonist={count:0,on:0},t.space.ai_core={count:100},t.space.ai_core2={count:0,on:0},t.space.biodome={count:0,on:0},t.space.crashed_ship={count:100},t.space.decoder={count:0,on:0},t.space.digsite={count:0},t.space.drone={count:0},t.space.drone_control={count:0,on:0},t.space.e_reactor={count:0,on:0},t.space.electrolysis={count:0,on:0,support:0,s_max:0},t.space.elerium_contain={count:0,on:0},t.space.elerium_mine={count:0,on:0},t.space.elerium_ship={count:0,on:0},t.space.exotic_lab={count:0,on:0},t.space.fabrication={count:0,on:0},t.space.fob={count:0,on:0,troops:0,enemy:0},t.space.g_factory={count:0,on:0,Lumber:0,Coal:0,Oil:0},t.space.garage={count:0},t.space.gas_mining={count:0,on:0},t.space.gas_storage={count:0},t.space.geothermal={count:0,on:0},t.space.gps={count:0},t.space.helium_mine={count:0,on:0},t.space.hell_smelter={count:0,on:0},t.space.hydrogen_plant={count:0,on:0},t.space.iridium_mine={count:0,on:0},t.space.iridium_ship={count:0,on:0},t.space.iron_ship={count:0,on:0},t.space.lander={count:0,on:0},t.space.living_quarters={count:0,on:0},t.space.m_relay={count:0,on:0},t.space.mass_relay={count:100},t.space.moon_base={count:0,on:0,support:0,s_max:0},t.space.munitions_depot={count:0},t.space.nav_beacon={count:0,on:0},t.space.neutronium_mine={count:0,on:0},t.space.observatory={count:0,on:0},t.space.oil_extractor={count:0,on:0},t.space.operating_base={count:0,on:0},t.space.orichalcum_mine={count:0,on:0},t.space.outpost={count:0,on:0},t.space.propellant_depot={count:0},t.space.red_factory={count:0,on:0},t.space.red_mine={count:0,on:0},t.space.red_tower={count:0,on:0},t.space.satellite={count:0},t.space.shipyard={count:0,on:0,ships:[],expand:!1,sort:!0},t.space.shock_trooper={count:0,on:0},t.space.space_barracks={count:0,on:0},t.space.space_station={count:0,on:0,support:0,s_max:0},t.space.spaceport={count:0,on:0,support:0,s_max:0},t.space.spc_casino={count:0,on:0},t.space.storehouse={count:0},t.space.swarm_control={count:0,support:0,s_max:0},t.space.swarm_plant={count:0},t.space.swarm_satellite={count:0},t.space.tank={count:0,on:0},t.space.titan_bank={count:0},t.space.titan_mine={count:0,on:0},t.space.titan_quarters={count:0,on:0},t.space.titan_spaceport={count:0,on:0,support:0,s_max:0},t.space.uranium_mine={count:0,on:0},t.space.vr_center={count:0,on:0},t.space.water_freighter={count:0,on:0},t.space.zero_g_lab={count:0,on:0},t.space.ziggurat={count:0},t.tauceti.alien_outpost={count:1,on:1},t.tauceti.colony={count:1,on:1},t.tauceti.fusion_generator={count:1,on:1},t.tauceti.infectious_disease_lab={count:0,on:0,cure:0},t.tauceti.mining_pit={count:1,on:1},t.tauceti.orbital_platform={count:0,on:0,support:0,s_max:0},t.tauceti.orbital_station={count:1,on:1,support:0,s_max:0},t.tauceti.refueling_station={count:0,on:0},t.tauceti.repository={count:2},t.tauceti.tauceti_casino={count:0,on:0},t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:2,wounded:0,raid:0,max:2},t.arpa.sequence={max:5e4,progress:0,time:5e4,on:!0,boost:!1,auto:!1,labs:0},t.tech.stock_exchange=0,t.tech.monuments=0,t.tech.supercollider=0,t.tech.tp_depot=0,t.tech.railway=0,t.tech.isolation=1,t.race.truepath=1,t.arpa.m_type=xe("Monument"),Qr(),Je(),xe("Physics"),sa()):t.race.artifical&&t.race.artifical&&(t.tech.spy=5,t.tech.primitive=3,t.tech.currency=6,t.tech.govern=3,t.tech.boot_camp=1,t.tech.medic=1,t.tech.military=5,t.tech.explosives=3,t.tech.trade=3,t.tech.banking=6,t.tech.home_safe=1,t.tech.housing=3,t.tech.smelting=3,t.tech.copper=1,t.tech.storage=5,t.tech.container=4,t.tech.steel_container=3,t.tech.mining=4,t.tech.pickaxe=2,t.tech.hammer=2,t.tech.oil=3,t.tech.alumina=1,t.tech.titanium=1,t.tech.foundry=7,t.tech.factory=1,t.tech.theatre=3,t.tech.broadcast=1,t.tech.science=7,t.tech.high_tech=4,t.tech.theology=2,t.settings.showIndustry=!0,t.settings.showPowerGrid=!0,t.settings.showResearch=!0,t.settings.showCivic=!0,t.settings.showMil=!0,t.settings.showResources=!0,t.settings.showMarket=!0,t.settings.showStorage=!0,t.resource[t.race.species].display=!0,t.resource.Knowledge.display=!0,t.resource.Money.display=!0,t.resource.Food.display=!0,t.resource.Money.amount=1e3,t.resource.Stone.display=!0,t.resource.Furs.display=!0,t.resource.Copper.display=!0,t.resource.Iron.display=!0,t.resource.Aluminium.display=!0,t.resource.Coal.display=!0,t.resource.Oil.display=!0,t.resource.Steel.display=!0,t.resource.Titanium.display=!0,t.resource.Brick.display=!0,t.resource.Wrought_Iron.display=!0,t.resource.Sheet_Metal.display=!0,t.resource.Crates.display=!0,t.resource.Containers.display=!0,t.race.flier||(t.tech.cement=5,t.resource.Cement.display=!0),t.race.kindling_kindred||t.race.smoldering||(t.race.evil?(t.tech.reclaimer=3,t.city.graveyard={count:1}):(t.tech.axe=3,t.tech.saw=2,t.city.lumber_yard={count:1},t.city.sawmill={count:0,on:0}),t.resource.Lumber.display=!0,t.resource.Plywood.display=!0,t.civic.lumberjack.display=!0),t.race.smoldering&&(t.resource.Chrysotile.display=!0),t.resource[t.race.species].max=0,t.resource[t.race.species].amount=0,t.resource.Crates.amount=10,t.resource.Containers.amount=10,t.civic.taxes.display=!0,t.civic.miner.display=!0,t.civic.coal_miner.display=!0,t.civic.quarry_worker.display=!0,t.civic.professor.display=!0,t.civic.scientist.display=!0,t.race.flier||(t.civic.cement_worker.display=!0),t.civic.banker.display=!0,t.city.calendar.day++,t.city.market.active=!0,t.city.power=7.5,t.city.powered=!0,t.city.factory={count:0,on:0,Lux:0,Furs:0,Alloy:0,Polymer:1,Nano:0,Stanene:0},t.city.foundry={count:0,crafting:0,Plywood:0,Brick:0,Bronze:0,Wrought_Iron:0,Sheet_Metal:0,Mythril:0,Aerogel:0,Nanoweave:0,Scarletite:0,Quantium:0},t.city.smelter={count:1,cap:0,Wood:0,Coal:0,Oil:1,Star:0,StarCap:0,Inferno:0,Iron:1,Steel:0,Iridium:0},t.city.oil_power={count:1,on:1},t.city.coal_power={count:0,on:0},t.city.transmitter={count:1,on:1},t.city.mine={count:1,on:0},t.city.coal_mine={count:1,on:0},t.city.oil_well={count:1},t.city.oil_depot={count:1},t.city.cement_plant={count:1,on:0},t.city.garrison={count:0,on:0},t.city.boot_camp={count:0},t.city.basic_housing={count:0},t.city.cottage={count:0},t.city.apartment={count:0,on:0},t.city.amphitheatre={count:0},t.city.rock_quarry={count:1,on:0,asbestos:50},t.city.metal_refinery={count:1,on:0},t.city.shed={count:2},t.city.storage_yard={count:1},t.city.warehouse={count:1},t.city.trade={count:0},t.city.wharf={count:0},t.city.bank={count:1},t.city.university={count:1},t.city.library={count:1},t.city.wardenclyffe={count:0,on:0},t.city.temple={count:0},t.race.calm&&(t.resource.Zen.display=!0,t.city.meditation={count:0}),t.race.cannibalize&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0}),t.race.magnificent&&(t.city.shrine={count:0,morale:0,metal:0,know:0,tax:0}),t.civic.govern.type="technocracy",t.civic.garrison={display:!0,disabled:!1,progress:0,tactic:0,workers:0,wounded:0,raid:0,max:0},Wr(),Qr(),sa()),t.settings.tabLoad?(Wr(),W(),he($("#c_garrison"),!1),te(),t.race.cataclysm||t.race.lone_survivor?(Ss($("#r_civics")),V(),ki(),Ea("market"),Ea("storage"),a.hasOwnProperty("resource")&&Object.keys(a.resource).forEach((function(e){let t=a.resource[e].color,r=a.resource[e].tradable;if(a.resource[e].stackable){var i=$(`
                            `);$("#resStorage").append(i),er(`#stack-${e}`,i,e,t)}r&&(i=$(`
                            `),$("#market").append(i),Va(`#market-${e}`,i,e,t,!0))})),Ba(),xe("Genetics"),xe("Crispr"),xe("Blood")):t.sim&&(xe("Crispr"),xe("Blood"))):kt("mTabCivil"),t.queue.hasOwnProperty("queue")&&(t.queue.queue=[]),(t.race.slow||t.race.hyper||"junker"===t.race.species)&&(e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w&&P.w.terminate(),window.location.reload())}function mi(e){switch(Ki[e].fanaticism){case"smart":t.race.dumb?(Gi(5),xe("Genetics")):gi("smart");break;case"infectious":gi("infectious"),"human"===t.race.species&&qn("infested");break;case"blood_thirst":gi("blood_thirst"),"entish"===t.race.species&&qn("madagascar_tree");break;case"none":Gi(5),xe("Genetics");break;default:gi(Ki[e].fanaticism)}}function gi(e){t.race[e]?es(e)?"imitation"===e?Xi(!0):"shapeshifter"===e&&Yi(t.race.ss_genus):(Gi(5),xe("Genetics")):(t.race[e]=1,Ji(e))}function vi(){if(!t.settings.tabLoad&&3!==t.settings.civTabs)return;fi(),Ss($("#resQueue")),$("#resQueue").append($(`\n

                            ${z("research_queue")} ({{ queue.length }}/{{ max }})

                            \n \n `));let e=$('
                              ');$("#resQueue").append(e),e.append($('
                            • {{ item.label }} [{{ item.time | time }}]
                            • '));try{Cs({el:"#resQueue",data:t.r_queue,methods:{remove(e){_s(`rq${t.r_queue.queue[e].id}`),t.r_queue.queue.splice(e,1),vi(),Qr()},setID:e=>`rq${t.r_queue.queue[e].id}`,pauseRQueue(){$("#pauserqueue").removeClass("play"),$("#pauserqueue").removeClass("pause"),t.r_queue.pause?(t.r_queue.pause=!1,$("#pauserqueue").addClass("play")):(t.r_queue.pause=!0,$("#pauserqueue").addClass("pause"))},pausedesc:()=>t.r_queue.pause?z("r_queue_play"):z("r_queue_pause")},filters:{time:e=>zs(e)}}),function(){let e=$("#resQueue .buildList")[0];Sortable.create(e,{onEnd(e){let a=t.r_queue.queue;a.splice(e.newDraggableIndex,0,a.splice(e.oldDraggableIndex,1)[0]),t.r_queue.queue=a,vi()}}),function(){for(let e=0;e=5?e-.01:e}function bi(){let e=1800;t.tech.vault>=1?e=7500*(t.tech.vault+1):t.tech.banking>=5?e=9e3:t.tech.banking>=3&&(e=4e3),t.race.paranoid&&(e*=1-Ei.paranoid.vars()[0]/100),t.race.hoarder&&(e*=1+Ei.hoarder.vars()[0]/100);let a=ts("dracnid");a>0&&(e*=1+Ei.hoarder.vars(1)[0]/100*a),t.tech.banking>=7&&(e*=1+ke(.05*ea(t.civic.banker.workers,"banker"))),t.tech.banking>=8&&(e+=ke(25*t.resource[t.race.species].amount)),t.tech.stock_exchange&&(e*=1+.1*t.tech.stock_exchange),t.tech.world_control&&(e*=1.25),t.race.truepath&&(e*=1.25),t.blood.greed&&(e*=1+t.blood.greed/100),t.stats.achieve.wheelbarrow&&(e*=1+t.stats.achieve.wheelbarrow.l/50),t.race.inflation&&(e*=1+t.race.inflation/125);let r=K("risktaker",0);return r&&(e*=1+r/100),e}function wi(e,a,r){switch(e){case"smelter":!function(e,a){let r=$(`
                              ${z("modal_smelter_fuel")}: {{s.count | on}}/{{ s.cap }}
                              `);if(e.append(r),e.hasClass("modalBody")){let e=Qs(10);e.length>0&&r.prepend(e)}if(a&&t.race.forge&&t.race.steelen){let e=Js(3,12,!0);e.length>0&&r.prepend(e)}let i=e.hasClass("modalBody")?"mSmelterFuels":"smelterFuels",s=$(`
                              `);if(e.append(s),!t.race.forge){if(!t.race.kindling_kindred&&!t.race.smoldering||t.race.evil){let e=t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?t.resource.Food.name:t.resource.Furs.name:t.resource.Lumber.name,a=$(`${e} {{ s.Wood }}`),r=$('«'),i=$('»');s.append(r),s.append(a),s.append(i)}if(t.resource.Coal.display){let e=$(`${t.resource.Coal.name} `),a=$('«'),r=$('»');s.append(a),s.append(e),s.append(r)}}if(t.race.forge){let e=$(`${z("trait_forge_name")} {{ s.Oil }}`);s.append(e)}else if(t.resource.Oil.display){let e=$(`${t.resource.Oil.name} {{ s.Oil }}`),a=$('«'),r=$('»');s.append(a),s.append(e),s.append(r)}if(t.tech.star_forge&&t.tech.star_forge>=2){let e=$(`${z("star")} {{ s.Star }}`);s.append(e)}if(t.tech.smelting&&t.tech.smelting>=8){let e=$(`${z("modal_smelter_inferno")} {{ s.Inferno }}`),t=$('«'),a=$('»');s.append(t),s.append(e),s.append(a)}let n=$('
                              ');e.append(n);let c=!!(t.tech.irid_smelting||t.tech.m_smelting&&t.tech.m_smelting>=2);if(t.resource.Iridium.display&&c||t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen){let a=$(`
                              `);e.append(a),a.append(`
                              ${z("modal_smelter_type")}: {{s.count | son}}/{{ s.cap | on }}
                              `);let r=$('
                              ');a.append(r);let i=$(`${t.resource.Iron.name} {{ s.Iron }}`),s=$('«'),n=$('»');if(r.append(s),r.append(i),r.append(n),t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen){let e=$(`${t.resource.Steel.name} {{ s.Steel }}`),a=$('«'),i=$('»');r.append(a),r.append(e),r.append(i)}if(t.resource.Iridium.display&&c){let e=$(`${t.resource.Iridium.name} {{ s.Iridium }}`),a=$('«'),i=$('»');r.append(a),r.append(e),r.append(i)}}function o(e){switch(e){case"wood":return z("modal_build_wood",[t.race.evil?t.race.soul_eater&&"wendigo"!==t.race.species&&!t.race.artifical?t.resource.Food.name:t.resource.Furs.name:t.resource.Lumber.name,t.race.evil&&!t.race.soul_eater||"wendigo"===t.race.species?1:3]);case"coal":{let e=t.race.kindling_kindred?.15:.25;return t.tech.uranium&&t.tech.uranium>=3?z("modal_build_coal2",[e,z("resource_Coal_name"),z("resource_Uranium_name")]):z("modal_build_coal1",[e,z("resource_Coal_name")])}case"oil":return t.race.forge?z("modal_build_forge"):z("modal_build_oil",["0.35",z("resource_Oil_name")]);case"star":return t.tech.irid_smelting?z("modal_build_star2",[z("resource_Titanium_name"),z("resource_Iridium_name")]):z("modal_build_star",[z("resource_Titanium_name")]);case"inferno":{let e=35,t=.5;return z("modal_build_inferno",[50,z("resource_Coal_name"),e,z("resource_Oil_name"),t,z("resource_Infernite_name")])}}}function l(e){if("steel"===e){let e=t.tech.smelting>=4?1.2:1;return t.tech.smelting>=5&&(e*=1.2),t.tech.smelting>=6&&(e*=1.2),t.tech.smelting>=7&&(e*=1.25),t.race.pyrophobia&&(e*=.9),z("modal_smelter_steel",[+e.toFixed(3),z("resource_Steel_name"),z("resource_Coal_name"),z("resource_Iron_name")])}if("iridium"===e){let e=t.tech.smelting>=7?6.25:5;return t.race.pyrophobia&&(e*=.9),z("modal_smelter_iron",[+e.toFixed(3),z("resource_Iridium_name")])}{let e=t.tech.smelting>=3?t.tech.smelting>=7?15:12:10;return t.race.pyrophobia&&(e*=.9),z("modal_smelter_iron",[+e.toFixed(3),z("resource_Iron_name")])}}Cs({el:a||"#specialModal",data:{s:t.city.smelter,lum:t.resource.Lumber,coal:t.resource.Coal,oil:t.resource.Oil,food:t.resource.Food,fur:t.resource.Furs},methods:{addFuel(e){let a=y();for(let r=0;r=t.city.smelter.StarCap)break;if(a0))break;"Wood"!==e&&t.city.smelter.Wood>0?(t.city.smelter.Wood--,t.city.smelter[e]++):"Coal"!==e&&t.city.smelter.Coal>0?(t.city.smelter.Coal--,t.city.smelter[e]++):"Oil"!==e&&t.city.smelter.Oil>0?(t.city.smelter.Oil--,t.city.smelter[e]++):"Inferno"!==e&&t.city.smelter.Inferno>0&&(t.city.smelter.Inferno--,t.city.smelter[e]++)}}},subFuel(e){let a=y();for(let r=0;r0;r++){t.city.smelter[e]--,t.race.forge&&"Inferno"===e&&t.city.smelter.Oil++;let a=t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno;t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium>a&&(t.city.smelter.Iron>0?t.city.smelter.Iron--:t.city.smelter.Steel>0?t.city.smelter.Steel--:t.city.smelter.Iridium>0&&t.city.smelter.Iridium--)}},mLabel:e=>l(e),addMetal(e){let a=y();for(let r=0;r0&&"Iron"!==e)t.city.smelter.Iron--,t.city.smelter[e]++;else if(t.city.smelter.Steel>0&&"Steel"!==e)t.city.smelter.Steel--,t.city.smelter[e]++;else{if(!(t.city.smelter.Iridium>0&&"Iridium"!==e))break;t.city.smelter.Iridium--,t.city.smelter[e]++}}},subMetal(e){let a=y();t.city.smelter[e]-=a,t.city.smelter[e]<0&&(t.city.smelter[e]=0)},buildLabel:e=>o(e),ariaCount:e=>` ${t.city.smelter[e]} ${e} fueled.`,ariaProd:e=>`. ${t.city.smelter[e]} producing ${e}.`,net:e=>t.resource[e].diff>=0?"has-text-success":"has-text-danger",level:()=>ji(t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,t.city.smelter.count)},filters:{on:e=>t.city.smelter.Wood+t.city.smelter.Coal+t.city.smelter.Oil+t.city.smelter.Star+t.city.smelter.Inferno,son:e=>t.city.smelter.Iron+t.city.smelter.Steel+t.city.smelter.Iridium,diffSize:e=>e>0?`+${x(e,2)}`:x(e,2),spook(e){if(a&&((t.race.kindling_kindred||t.race.smoldering)&&(6===t.city.smelter.Steel||6===t.city.smelter.Iron)||6===t.city.smelter.Wood)&&6===t.city.smelter.Coal&&6===t.city.smelter.Oil){let e=Js(3,12,!0);if(e.length>0)return e}return e},altspook(e){if(a&&t.race.forge&&6===t.city.smelter.Steel){let e=Js(3,12,!0);if(e.length>0)return e}return e}}});let _=e.hasClass("modalBody")?"mSmelterFuels":"smelterFuels";if(["wood","coal","oil","star","inferno"].forEach((function(e){ls(`${_}${e}`,(function(){return o(e)}),{elm:$(`#${_} > .${e}`),attach:"#main"})})),t.resource.Steel.display&&t.tech.smelting>=2&&!t.race.steelen||t.resource.Iridium.display&&c){let a=e.hasClass("modalBody")?"mSmelterMats":"smelterMats";["iron","steel","iridium"].forEach((function(e){("steel"!==e||t.resource.Steel.display&&!t.race.steelen)&&("iridium"!==e||t.resource.Iridium.display&&c)&&ls(`${a}${e}`,(function(){return l(e)}),{elm:$(`#${a} span.${e}`),attach:"#main"})}))}}(a,r);break;case"factory":!function(e,a){let r=$(`
                              ${z("modal_factory_operate")}: {{count | on}}/{{ on | max }}
                              `);e.append(r);let i=$(`
                              ${z("modal_factory_lux")}
                              `);e.append(i);let c=$(''),o=$('«'),l=$('»');if(i.append(o),i.append(c),i.append(l),t.tech.synthetic_fur){let a=$(`
                              ${t.race.evil?z("resource_Flesh_name"):z("resource_Furs_name")}
                              `);e.append(a);let r=$('{{ Furs }}'),i=$('«'),s=$('»');a.append(i),a.append(r),a.append(s)}let _=$(`
                              ${z("resource_Alloy_name")}
                              `);e.append(_);let d=$('{{ Alloy }}'),p=$('«'),u=$('»');if(_.append(p),_.append(d),_.append(u),t.tech.polymer){let t=$(`
                              ${z("resource_Polymer_name")}
                              `);e.append(t);let a=$('{{ Polymer }}'),r=$('«'),i=$('»');t.append(r),t.append(a),t.append(i)}if(t.tech.nano){let t=$(`
                              ${z("resource_Nano_Tube_name")}
                              `);e.append(t);let a=$('{{ Nano }}'),r=$('«'),i=$('»');t.append(r),t.append(a),t.append(i)}if(t.tech.stanene){let t=$(`
                              ${z("resource_Stanene_name")}
                              `);e.append(t);let a=$('{{ Stanene }}'),r=$('«'),i=$('»');t.append(r),t.append(a),t.append(i)}function h(e){let a=!!t.tech.factory;switch(e){case"Lux":{let e=+t.resource[t.race.species].amount*(a?$i.Lux.demand[t.tech.factory]:$i.Lux.demand[0]);return e=function(e){t.race.toxic&&(e*=1+Ei.toxic.vars()[0]/100);let a=ts("shroomi");return a>0&&(e*=1+Ei.toxic.vars(1)[0]/100*a),"corpocracy"===t.civic.govern.type&&(e*=2.5),"socialist"===t.civic.govern.type&&(e*=.8),t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2&&(e*=1.1),t.race.inflation&&(e*=1+t.race.inflation/1250),t.tech.isolation&&(e*=1+.5*(n.colony||0)),e*=$e("psychic_cash")}(e).toFixed(2),z("modal_factory_lux_label",[a?$i.Lux.fur[t.tech.factory]:$i.Lux.fur[0],t.resource.Furs.name,e])}case"Furs":{let e=a?$i.Furs.money[t.tech.factory]:$i.Furs.money[0],r=a?$i.Furs.polymer[t.tech.factory]:$i.Furs.polymer[0];return z("modal_factory_alloy_label",[e,z("resource_Money_name"),r,z("resource_Polymer_name"),t.race.evil?z("resource_Flesh_name"):z("resource_Furs_name")])}case"Alloy":{let e=a?$i.Alloy.copper[t.tech.factory]:$i.Alloy.copper[0],r=a?$i.Alloy.aluminium[t.tech.factory]:$i.Alloy.aluminium[0];return z("modal_factory_alloy_label",[e,z("resource_Copper_name"),r,z("resource_Aluminium_name"),z("resource_Alloy_name")])}case"Polymer":if(t.race.kindling_kindred||t.race.smoldering)return z("modal_factory_polymer_label2",[a?$i.Polymer.oil_kk[t.tech.factory]:$i.Polymer.oil_kk[0],z("resource_Oil_name"),z("resource_Polymer_name")]);{let e=a?$i.Polymer.oil[t.tech.factory]:$i.Polymer.oil[0],r=a?$i.Polymer.lumber[t.tech.factory]:$i.Polymer.lumber[0];return z("modal_factory_polymer_label1",[e,z("resource_Oil_name"),r,t.resource.Lumber.name,z("resource_Polymer_name")])}case"Nano":{let e=a?$i.Nano_Tube.coal[t.tech.factory]:$i.Nano_Tube.coal[0],r=a?$i.Nano_Tube.neutronium[t.tech.factory]:$i.Nano_Tube.neutronium[0];return z("modal_factory_nano_label",[e,z("resource_Coal_name"),r,z("resource_Neutronium_name"),z("resource_Nano_Tube_name")])}case"Stanene":{let e=a?$i.Stanene.aluminium[t.tech.factory]:$i.Stanene.aluminium[0],r=a?$i.Stanene.nano[t.tech.factory]:$i.Stanene.nano[0];return z("modal_factory_stanene_label",[e,z("resource_Aluminium_name"),r,z("resource_Nano_Tube_name"),z("resource_Stanene_name")])}}}Cs({el:a||"#specialModal",data:t.city.factory,methods:{subItem:function(e){let a=y();for(var r=0;r0;r++)t.city.factory[e]--},addItem:function(e){let a=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;t.interstellar.int_factory&&s.int_factory&&(a+=2*s.int_factory),t.tauceti.tau_factory&&n.tau_factory&&(a+=n.tau_factory*(t.tech.isolation?5:3));let r=y();for(var i=0;i0))break;t.city.factory.Alloy--,t.city.factory[e]++}}},buildLabel:function(e){return h(e)},ariaProd:e=>`. ${t.city.factory[e]} factories producing ${e}.`,level(){let e=t.city.factory.Lux+t.city.factory.Furs+t.city.factory.Alloy+t.city.factory.Polymer+t.city.factory.Nano+t.city.factory.Stanene,a=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;return t.interstellar.int_factory&&s.int_factory&&(a+=2*s.int_factory),t.tauceti.tau_factory&&n.tau_factory&&(a+=n.tau_factory*(t.tech.isolation?5:3)),ji(e,a)}},filters:{on:()=>t.city.factory.Lux+t.city.factory.Furs+t.city.factory.Alloy+t.city.factory.Polymer+t.city.factory.Nano+t.city.factory.Stanene,max(){let e=t.space.red_factory?t.space.red_factory.on+t.city.factory.on:t.city.factory.on;return t.interstellar.int_factory&&s.int_factory&&(e+=2*s.int_factory),t.tauceti.tau_factory&&n.tau_factory&&(e+=n.tau_factory*(t.tech.isolation?5:3)),e},spook(e){if(3===t.city.factory.Lux&&a){let e=Js(6,12,!0);if(e.length>0)return e}return e}}}),["Lux","Furs","Alloy","Polymer","Nano","Stanene"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iFactory";ls(`${a}${t}`,(function(){return h(t)}),{elm:$(`#${a} .factory > .${t}`),attach:"#main"})}))}(a,r);break;case"droid":!function(e,a){let r=$(`
                              ${z("modal_factory_operate")}: {{count | on}}/{{ on | max }}
                              `);e.append(r);let i=$(`
                              ${z("resource_Adamantite_name")}
                              `);e.append(i);let s=$('{{ adam }}'),n=$('«'),c=$('»');i.append(n),i.append(s),i.append(c);let o=$(`
                              ${z("resource_Uranium_name")}
                              `);e.append(o);let l=$('{{ uran }}'),_=$('«'),d=$('»');o.append(_),o.append(l),o.append(d);let p=$(`
                              ${z("resource_Coal_name")}
                              `);e.append(p);let u=$('{{ coal }}'),h=$('«'),m=$('»');p.append(h),p.append(u),p.append(m);let g=$(`
                              ${z("resource_Aluminium_name")}
                              `);e.append(g);let v=$('{{ alum }}'),f=$('«'),b=$('»');function w(e){switch(e){case"adam":return z("modal_droid_res_label",[z("resource_Adamantite_name")]);case"uran":return z("modal_droid_res_label",[z("resource_Uranium_name")]);case"coal":return z("modal_droid_res_label",[z("resource_Coal_name")]);case"alum":return z("modal_droid_res_label",[z("resource_Aluminium_name")])}}g.append(f),g.append(v),g.append(b),Cs({el:a||"#specialModal",data:t.interstellar.mining_droid,methods:{subItem:function(e){let a=y();for(var r=0;r0;r++)t.interstellar.mining_droid[e]--},addItem:function(e){let a=y();for(var r=0;r`. ${t.interstellar.mining_droid[e]} driod mining ${e}.`,level:()=>ji(t.interstellar.mining_droid.adam+t.interstellar.mining_droid.uran+t.interstellar.mining_droid.coal+t.interstellar.mining_droid.alum,t.interstellar.mining_droid.on)},filters:{on:()=>t.interstellar.mining_droid.adam+t.interstellar.mining_droid.uran+t.interstellar.mining_droid.coal+t.interstellar.mining_droid.alum,max:()=>t.interstellar.mining_droid.on}}),["adam","uran","coal","alum"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iDroid";ls(`${a}${t}`,(function(){return w(t)}),{elm:$(`#${a} .factory > .${t}`),attach:"#main"})}))}(a,r);break;case"graphene":!function(e,a){let r=t.race.truepath?"space":"interstellar",i=$(`
                              ${z("modal_smelter_fuel")}: {{count | on}}/{{ on | max }}
                              `);e.append(i);let s=$("
                              ");if(e.append(s),!t.race.kindling_kindred&&!t.race.smoldering){let e=t.resource.Lumber.name,a=$(`${e} {{ Lumber }}`),r=$('«'),i=$('»');s.append(r),s.append(a),s.append(i)}if(t.resource.Coal.display){let e=$(`${t.resource.Coal.name} {{ Coal }}`),a=$('«'),r=$('»');s.append(a),s.append(e),s.append(r)}if(t.resource.Oil.display){let e=$(`${t.resource.Oil.name} {{ Oil }}`),a=$('«'),r=$('»');s.append(a),s.append(e),s.append(r)}function n(e){switch(e){case"wood":return z("modal_graphene_produce",[350,t.race.evil?z("resource_Bones_name"):z("resource_Lumber_name"),z("resource_Graphene_name")]);case"coal":return z("modal_graphene_produce",[25,z("resource_Coal_name"),z("resource_Graphene_name")]);case"oil":return z("modal_graphene_produce",[15,z("resource_Oil_name"),z("resource_Graphene_name")])}}Cs({el:a||"#specialModal",data:t[r].g_factory,methods:{subWood(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Lumber--},addWood(){let e=y();for(let a=0;a0))break;t[r].g_factory.Oil>t[r].g_factory.Coal?t[r].g_factory.Coal>0?t[r].g_factory.Coal--:t[r].g_factory.Oil--:t[r].g_factory.Oil>0?t[r].g_factory.Oil--:t[r].g_factory.Coal--,t[r].g_factory.Lumber++}},subCoal(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Coal--},addCoal(){let e=y();for(let a=0;a0))break;t[r].g_factory.Lumber>0?t[r].g_factory.Lumber--:t[r].g_factory.Oil--,t[r].g_factory.Coal++}},subOil(){let e=y();for(let a=0;a0;a++)t[r].g_factory.Oil--},addOil(){let e=y();for(let a=0;a0))break;t[r].g_factory.Lumber>0?t[r].g_factory.Lumber--:t[r].g_factory.Coal--,t[r].g_factory.Oil++}},buildLabel:e=>n(e),ariaCount:e=>` ${t[r].g_factory[e]} ${e} fueled.`,ariaProd:e=>`. ${t[r].g_factory[e]} producing ${e}.`,level:()=>ji(t[r].g_factory.Lumber+t[r].g_factory.Coal+t[r].g_factory.Oil,t[r].g_factory.on)},filters:{on:function(e){return t[r].g_factory.Lumber+t[r].g_factory.Coal+t[r].g_factory.Oil}}}),["wood","coal","oil"].forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iGraphene";ls(`${a}${t}`,(function(){return n(t)}),{elm:$(`#${a} > div > .${t}`),attach:"#main"})}))}(a,r);break;case"pylon":!function(e,a){let r=$(`
                              ${z("modal_pylon_casting")}: {{total | drain}}
                              `);e.append(r);let i=$('
                              ');e.append(i);let s=[];function n(e){let a=+Pi(t.race.casting[e]).toFixed(4),r=+(Pi(t.race.casting[e]+1)-Pi(t.race.casting[e])).toFixed(4),i=+(t.race.casting[e]/(t.race.casting[e]+75)*100).toFixed(2);return"crafting"===e?z("modal_pylon_casting_label_crafting",[a,i,+(2*t.race.casting[e]/(2*t.race.casting[e]+75)*100).toFixed(2),r]):z("modal_pylon_casting_label",[z(`modal_pylon_spell_${e}`),a,r,i])}s=t.race.orbit_decayed?["miner","science","factory","army","hunting","crafting"]:t.race.cataclysm?["science","factory","army","hunting","crafting"]:t.race.unfathomable?["miner","lumberjack","science","factory","army","hunting","crafting"]:["farmer","miner","lumberjack","science","factory","army","hunting","crafting"],t.tech.magic&&t.tech.magic>=3&&s.forEach((function(e){if("crafting"!==e&&"lumberjack"!==e&&"farmer"!==e||"farmer"===e&&!t.race.detritivore&&!t.race.carnivore&&!t.race.soul_eater&&!t.race.artifical||"lumberjack"===e&&!t.race.kindling_kindred&&!t.race.smoldering&&!t.race.evil||"crafting"===e&&t.tech.magic>=4){let t=$(`${z(`modal_pylon_spell_${e}`)} {{ ${e} }}`),a=$(`«`),r=$(`»`);i.append(a),i.append(t),i.append(r)}})),Cs({el:a||"#specialModal",data:t.race.casting,methods:{buildLabel:e=>n(e),addSpell(e){let a=y();for(let r=0;r=a))break;t.race.casting[e]++,t.race.casting.total++,t.resource.Mana.diff-=a}},subSpell(e){let a=y();for(let r=0;r0;r++)t.race.casting[e]--,t.race.casting.total--},ariaCount:e=>` ${e} casting.`,level:()=>ji(t.race.casting.total,t.resource.Mana.gen,!0)},filters:{drain:function(e){let a=0;return s.forEach((function(e){t.race.casting[e]&&t.race.casting[e]>0&&(a+=Pi(t.race.casting[e]))})),z("modal_pylon_casting_cost",[+a.toFixed(3)])}}}),s.forEach((function(t){let a=e.hasClass("modalBody")?"specialModal":"iPylon";ls(`${a}${t}`,(function(){return n(t)}),{elm:$(`#${a} > .pylon > .${t}`),attach:"#main"})}))}(a,r);break;case"rock_quarry":!function(e,a){e.append($(`
                              ${z("modal_quarry_ratio",[t.resource.Chrysotile.name])}
                              `));let r=$('
                              «»
                              ');e.append(r),Cs({el:a||"#specialModal",data:t.city.rock_quarry,methods:{sub(){let e=y();t.city.rock_quarry.asbestos>0&&(t.city.rock_quarry.asbestos-=e,t.city.rock_quarry.asbestos<0&&(t.city.rock_quarry.asbestos=0))},add(){let e=y();t.city.rock_quarry.asbestos<100&&(t.city.rock_quarry.asbestos+=e,t.city.rock_quarry.asbestos>100&&(t.city.rock_quarry.asbestos=100))}}})}(a,r);break;case"titan_mine":!function(e,a){e.append($(`
                              ${z("modal_quarry_ratio",[t.resource.Adamantite.name])}
                              `));let r=$('
                              «»
                              ');e.append(r),Cs({el:a||"#specialModal",data:t.space.titan_mine,methods:{sub(){let e=y();t.space.titan_mine.ratio>0&&(t.space.titan_mine.ratio-=e,t.space.titan_mine.ratio<0&&(t.space.titan_mine.ratio=0))},add(){let e=y();t.space.titan_mine.ratio<100&&(t.space.titan_mine.ratio+=e,t.space.titan_mine.ratio>100&&(t.space.titan_mine.ratio=100))}}})}(a,r);break;case"nanite_factory":!function(e,a){let r=$(`
                              ${z("modal_factory_operate")}: {{count | on}}/{{ count | max }}
                              `);e.append(r);let i=e.hasClass("modalBody")?"mNFactoryRes":"NFactoryRes",s=$(`
                              `);e.append(s),xi.forEach((function(e){if(t.resource[e].display){let a=$(`${t.resource[e].name} {{ ${e} }}`),r=$(`«`),i=$(`»`);s.append(r),s.append(a),s.append(i)}})),Cs({el:a||"#specialModal",data:t.city.nanite_factory,methods:{subItem:function(e){let a=y();t.city.nanite_factory[e]-=a,t.city.nanite_factory[e]<0&&(t.city.nanite_factory[e]=0)},addItem:function(e){let a=y(),r=0;xi.forEach((function(e){r+=t.city.nanite_factory[e]}));let i=50*t.city.nanite_factory.count-r;a>i&&(a=i),a>0&&(t.city.nanite_factory[e]+=a)},eatLabel:e=>`Consume ${e} to produce ${t.resource.Nanite.name}`,level(){let e=0;xi.forEach((function(a){e+=t.city.nanite_factory[a]}));let a=t.city.nanite_factory.count;return ji(e,a)}},filters:{on(){let e=0;return xi.forEach((function(a){e+=t.city.nanite_factory[a]})),e},max:()=>50*t.city.nanite_factory.count}}),xi.forEach((function(a){let r=e.hasClass("modalBody")?"specialModal":"iNFactory";ls(`${r}${a}`,(function(){return function(e){let a=+(Fa[e]/100*(Ei.deconstructor.vars()[0]/100)).toFixed(4),r=+(t.city.nanite_factory[e]*a).toFixed(4);return z("modal_nfactory_resource_label",[1,t.resource[e].name,a,t.resource.Nanite.name,t.city.nanite_factory[e],r])}(a)}),{elm:$(`#${r} > .fuels > .${a}`),attach:"#main"})}))}(a,r);break;case"mining_ship":!function(e,a){e.append($(`
                              ${z("tau_roid_mining_ship_ratio",[t.resource.Iron.name,t.resource.Aluminium.name])}
                              `));let r=$('
                              «»
                              ');e.append(r),e.append($(`
                              ${z("tau_roid_mining_ship_ratio",[t.resource.Iridium.name,t.resource.Neutronium.name])}
                              `));let i=$('
                              «»
                              ');if(e.append(i),t.tech.tau_roid>=5){e.append($(`
                              ${z("tau_roid_mining_ship_ratio",[t.resource.Orichalcum.name,t.resource.Elerium.name])}
                              `));let a=$('
                              «»
                              ');e.append(a)}Cs({el:a||"#specialModal",data:t.tauceti.mining_ship,methods:{sub(e){let a=y();t.tauceti.mining_ship[e]>0&&(t.tauceti.mining_ship[e]-=a,t.tauceti.mining_ship[e]<0&&(t.tauceti.mining_ship[e]=0))},add(e){let a=y();t.tauceti.mining_ship[e]<100&&(t.tauceti.mining_ship[e]+=a,t.tauceti.mining_ship[e]>100&&(t.tauceti.mining_ship[e]=100))}}})}(a,r);break;case"alien_space_station":!function(e,a){e.append($(`
                              ${z("tau_gas2_alien_station_focus",[t.resource.Knowledge.name])}
                              `));let r=$('
                              «»
                              ');e.append(r),Cs({el:a||"#specialModal",data:t.tauceti.alien_space_station,methods:{sub(e){let a=y();t.tauceti.alien_space_station[e]>0&&(t.tauceti.alien_space_station[e]-=a,t.tauceti.alien_space_station[e]<0&&(t.tauceti.alien_space_station[e]=0))},add(e){let a=y();t.tauceti.alien_space_station[e]<100&&(t.tauceti.alien_space_station[e]+=a,t.tauceti.alien_space_station[e]>100&&(t.tauceti.alien_space_station[e]=100))}}})}(a,r);break;case"replicator":!function(e,a){if(t.race.replicator){e.append($(`
                              ${"antimatter"===t.race.universe?z("tech_antireplicator"):z("tech_replicator")}
                              `));let r=$('
                              ');if(e.append(r),a){let e="";Object.keys(Fa).forEach((function(a){e+=`${t.resource[a].name}`})),r.append(`
                              \n ${e}\n
                              `)}else{let e="";Object.keys(Fa).forEach((function(a){t.resource[a].display&&(e+=`${t.resource[a].name}`)})),r.append(`
                              ${e}
                              `)}let i=a?$("
                              "):$('
                              ');r.append(i);let s=$('{{ pow }}MW'),n=$('«'),c=$('»');if(i.append(n),i.append(s),i.append(c),e.append('
                              {{ res | result }}
                              '),Cs({el:a||"#specialModal",data:t.race.replicator,methods:{less(){let e=y();t.race.replicator.pow>0&&(t.race.replicator.pow-=e,t.race.replicator.pow<0&&(t.race.replicator.pow=0))},more(){let e=y();t.race.replicator.pow+=e},setVal(e){t.resource[e].display&&(t.race.replicator.res=e)},avail:e=>t.resource[e].display,aria:()=>t.race.replicator.pow+"MW"},filters:{resName:e=>t.resource[e].name,result:e=>z("tau_replicator",[qi(e,t.race.replicator.pow).toFixed(3),t.resource[e].name])}}),!a){const e=document.getElementById("hscrolltarget");e.addEventListener("wheel",(t=>{t.preventDefault(),e.scrollLeft+=t.deltaY}))}}}(a,r)}}function ki(){if(t.settings.tabLoad||2===t.settings.civTabs&&1===t.settings.govTabs){if(Ss($("#industry")),t.city.smelter&&(t.city.smelter.count>0||t.race.cataclysm||t.race.orbit_decayed||t.tech.isolation)){var e=$(`

                              ${z("city_smelter")}

                              `);$("#industry").append(e),wi("smelter",e,"#iSmelter")}if(t.city.factory&&t.city.factory.count>0||t.space.red_factory&&t.space.red_factory.count>0||t.tauceti.tau_factory&&t.tauceti.tau_factory.count>0){var a=$(`

                              ${z("city_factory")}

                              `);$("#industry").append(a),wi("factory",a,"#iFactory")}if(t.interstellar.mining_droid&&t.interstellar.mining_droid.count>0){var r=$(`

                              ${z("interstellar_mining_droid_title")}

                              `);$("#industry").append(r),wi("droid",r,"#iDroid")}if(t.interstellar.g_factory&&t.interstellar.g_factory.count>0||t.space.g_factory&&(t.space.g_factory.count>0||t.tauceti.refueling_station&&t.tauceti.refueling_station.count>0)){var i=$(`

                              ${z("interstellar_g_factory_title")}

                              `);$("#industry").append(i),wi("graphene",i,"#iGraphene")}if(t.race.casting&&(t.city.pylon||t.space.pylon||t.tauceti.pylon)){var s=$(`

                              ${z("city_pylon")}

                              `);$("#industry").append(s),wi("pylon",s,"#iPylon")}if(t.race.smoldering&&t.city.rock_quarry&&!t.race.cataclysm&&!t.race.orbit_decayed&&!t.tech.isolation){var n=$(`

                              ${z("city_rock_quarry")}

                              `);$("#industry").append(n),wi("rock_quarry",n,"#iQuarry")}if(t.space.titan_mine&&t.space.titan_mine.count>0&&(n=$(`

                              ${z("city_mine")}

                              `),$("#industry").append(n),wi("titan_mine",n,"#iTMine")),t.tech.tau_roid&&t.tech.tau_roid>=4&&t.tauceti.mining_ship){var c=$(`

                              ${z("tau_roid_mining_ship")}

                              `);$("#industry").append(c),wi("mining_ship",c,"#iMiningShip")}if(t.tech.tau_gas2&&6===t.tech.tau_gas2&&t.tauceti.alien_space_station&&(!t.tech.alien_data||t.tech.alien_data<6)){var o=$(`

                              ${z("tau_gas2_alien_station")}

                              `);$("#industry").append(o),wi("alien_space_station",o,"#iAlienSpaceStation")}if(t.race.deconstructor&&t.city.nanite_factory){var l=$(`

                              ${z("city_nanite_factory")}

                              `);$("#industry").append(l),wi("nanite_factory",l,"#iNFactory")}if(t.race.replicator&&t.tech.replicator){var _=$(`

                              ${"antimatter"===t.race.universe?z("tech_antireplicator"):z("tech_replicator")}

                              `);$("#industry").append(_),wi("replicator",_,"#iReplicator")}}}Object.keys(Ir).forEach((e=>Mr.evolution[e]={id:`evolution-${e}`,title:z(`evo_challenge_${e}`),desc(){let a="";return"micro"===t.race.universe&&(a+=`
                              ${z("evo_challenge_micro_warn")}
                              `),a+=`
                              ${z(`evo_challenge_${e}_desc`)}
                              `,["sludge","junker"].includes(e)&&(a+=`
                              ${z("evo_start")}
                              `),a},condition:()=>t.evolution.hasOwnProperty(e),cost:{DNA:()=>"c"===Ir[e].t?25:50},challenge:!0,effect:()=>Lr(e),action(){return ri($(this)[0])&&("c"===Ir[e].t?function(e){t.race[e]?(delete t.race[e],$(`#evolution-${e}`).removeClass("hl"),"sludge"===e&&Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).removeClass("is-hidden")}))):(t.race[e]=1,$(`#evolution-${e}`).addClass("hl"),"sludge"===e&&(Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).addClass("is-hidden")})),t.race.junker&&delete t.race.junker),"orbit_decay"===e&&(delete t.race.cataclysm,t.race.lone_survivor&&(delete t.race.lone_survivor,["nerfed","badgenes"].forEach((function(e){delete t.race[Ar[e]]}))))),Sr(),On()}(e):function(e){if(t.race.sludge||Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).removeClass("is-hidden")})),t.race[e])delete t.race[e],$(`#evolution-${e}`).removeClass("hl"),["nerfed","badgenes"].forEach((function(e){delete t.race[Ar[e]]}));else{["junker","cataclysm","banana","truepath","lone_survivor"].forEach((function(e){delete t.race[e],$(`#evolution-${e}`).removeClass("hl")})),t.race[e]=1,$(`#evolution-${e}`).addClass("hl"),"junker"===e&&(Object.keys(Ki).forEach((function(e){"junker"!==e&&"sludge"!==e&&$(`#evolution-${e}`).addClass("is-hidden")})),t.race.sludge&&delete t.race.sludge),"cataclysm"!==e&&"lone_survivor"!==e||delete t.race.orbit_decay,"truepath"===e||"lone_survivor"===e?(t.race.nerfed=1,["crispr","plasmid","mastery"].forEach((function(e){delete t.race[Ar[e]]}))):(["nerfed","badgenes"].forEach((function(e){delete t.race[Ar[e]]})),"antimatter"===t.race.universe?(t.race.weak_mastery=1,$("#evolution-mastery").hasClass("hl")||$("#evolution-mastery").addClass("hl")):(t.race.no_plasmid=1,$("#evolution-plasmid").hasClass("hl")||$("#evolution-plasmid").addClass("hl")));let a="truepath"===e||"lone_survivor"===e?["badgenes","trade","craft"]:["crispr","trade","craft"];for(let e=0;eXs(Ir[e].e),highlight:()=>!!t.race[e],queue_complete:()=>0})),Mr.evolution.bunker={id:"evolution-bunker",title:z("evo_bunker"),desc:()=>`
                              ${z("evo_bunker")}
                              ${z("evo_challenge")}
                              `,reqs:{evo:6},grant:["evo_challenge",1],condition:()=>t.genes.challenge&&100===t.evolution.final&&!t.race.evoFinalMenu,cost:{DNA:()=>10},effect:z("evo_bunker_effect"),action(){return!!ri($(this)[0])},queue_complete:()=>t.tech.evo_challenge?0:1,flair:z("evo_bunker_flair")};const $i={Lux:{demand:[.14,.21,.28,.35,.42],fur:[2,3,4,5,6]},Furs:{money:[10,15,20,25,30],polymer:[1.5,2.25,3,3.75,4.5],output:[1,1.5,2,2.5,3]},Alloy:{copper:[.75,1.12,1.49,1.86,2.23],aluminium:[1,1.5,2,2.5,3],output:[.075,.112,.149,.186,.223]},Polymer:{oil_kk:[.22,.33,.44,.55,.66],oil:[.18,.27,.36,.45,.54],lumber:[15,22,29,36,43],output:[.125,.187,.249,.311,.373]},Nano_Tube:{coal:[8,12,16,20,24],neutronium:[.05,.075,.1,.125,.15],output:[.2,.3,.4,.5,.6]},Stanene:{aluminium:[30,45,60,75,90],nano:[.02,.03,.04,.05,.06],output:[.6,.9,1.2,1.5,1.8]}},xi=["Lumber","Chrysotile","Stone","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal","Oil","Uranium","Steel","Titanium","Alloy","Polymer","Iridium","Helium_3","Water","Deuterium","Neutronium","Adamantite","Bolognium","Orichalcum"];function qi(e,a){return t.race.lone_survivor?17.5*_/Fa[e]*a:12.5*(_||1)/Fa[e]*a**.75}function Pi(e,t){return e*((1+(t=void 0===t?.0025:t))**e-1)}function ji(e,t,a){return e<=0?a?"has-text-success":"has-text-danger":e>=t?a?"has-text-danger":"has-text-success":e<=t/3?a?"has-text-info":"has-text-caution":e<=.66*t?"has-text-warning":e
                              ${z("power_grid_header")}
                              Distribute Low Power
                              `),Cs({el:"#powerModeSwitch",data:t.settings}),Object.keys(e).forEach((function(a){if(!e[a].s)return;let r="";"power"===a&&(r=Js(7,12,!1)),e[a].r&&e[a].rs&&t[e[a].r][e[a].rs]?($("#powerGrid").append(`
                              ${e[a].n} {{ support }}/{{ s_max }}
                              `),Cs({el:`#pg${a}sup`,data:t[e[a].r][e[a].rs]})):$("#powerGrid").append(`
                              ${e[a].n}${r}
                              `);let i=$(`
                              `);$("#powerGrid").append(i);let s=0;for(let r=0;r`);c.append(` ${_}${d}`),c.append('{{ on | off }} {{ on }}'),c.append('« »'),i.append(c),Cs({el:`#pg${l.id}${a}`,data:t[o][n[1]],methods:{power_on(){let e=y();for(let a=0;a0;a++)t[o][n[1]].on--;l.postPower&&setTimeout((function(){l.postPower(!1)}),250)},higher(){let t=$(`#pg${l.id}${a}`).attr("data-idx"),r=$(`#pg${l.id}${a}`).prevAll('.circuit:not(".inactive")').attr("data-idx");if(r>=0){let i=e[a].l;i.splice(r,0,i.splice(t,1)[0]),e[a].l=i,Mi()}},lower(){let t=$(`#pg${l.id}${a}`).attr("data-idx"),r=$(`#pg${l.id}${a}`).nextAll('.circuit:not(".inactive")').attr("data-idx");if(rt[o][n[1]].count-e,idx(e){let t=Qs(18,11);return 10===e&&t.length>0?"1"+t:e}}})}else{let e=$(`
                              `);e.append(`${_}${d}`),i.append(e)}}!function(e){let t=$(`#grid${e}`)[0],a=Si();Sortable.create(t,{onEnd(t){let r=a[e].l;r.splice(t.newDraggableIndex,0,r.splice(t.oldDraggableIndex,1)[0]),a[e].l=r,Mi()}})}(a);let n=$(`
                              `);$("#powerGrid").append(n),Cs({el:`#${a}GridReset`,data:{},methods:{resetGrid(e){us(e,!0),Mi()}}})}))}function Si(){return{power:{l:t.power,n:z("power"),s:!0,r:!1,rs:!1},moon:{l:t.support.moon,n:z("space_moon_info_name"),s:t.settings.space.moon,r:"space",rs:"moon_base"},red:{l:t.support.red,n:Ut().red,s:t.settings.space.red,r:"space",rs:"spaceport"},belt:{l:t.support.belt,n:z("space_belt_info_name"),s:t.settings.space.belt,r:"space",rs:"space_station"},alpha:{l:t.support.alpha,n:z("interstellar_alpha_name"),s:t.settings.space.alpha,r:"interstellar",rs:"starport"},nebula:{l:t.support.nebula,n:z("interstellar_nebula_name"),s:t.settings.space.nebula,r:"interstellar",rs:"nexus"},gateway:{l:t.support.gateway,n:z("galaxy_gateway"),s:t.settings.space.gateway,r:"galaxy",rs:"starbase"},alien2:{l:t.support.alien2,n:z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name]),s:t.settings.space.alien2,r:"galaxy",rs:"foothold"},lake:{l:t.support.lake,n:z("portal_lake_name"),s:t.settings.portal.lake,r:"portal",rs:"harbour"},spire:{l:t.support.spire,n:z("portal_spire_name"),s:t.settings.portal.spire,r:"portal",rs:"purifier"},titan:{l:t.support.titan,n:Ut().titan,s:t.settings.space.titan,r:"space",rs:"electrolysis"},enceladus:{l:t.support.enceladus,n:Ut().enceladus,s:t.settings.space.enceladus,r:"space",rs:"titan_spaceport"},eris:{l:t.support.eris,n:Ut().eris,s:t.settings.space.eris,r:"space",rs:"drone_control"},tau_home:{l:t.support.tau_home,n:z("tau_planet",[Ki[t.race.species].home]),s:t.settings.tau.home,r:"tauceti",rs:"orbital_station"},tau_red:{l:t.support.tau_red,n:z("tau_planet",[Ut().red]),s:t.settings.tau.red,r:"tauceti",rs:"orbital_platform"},tau_roid:{l:t.support.tau_roid,n:z("tau_roid_title"),s:t.settings.tau.roid,r:"tauceti",rs:"patrol_ship"}}}function Ci(e){e=e||Si(),Object.keys(e).forEach((function(e){let t=$(`#grid${e}`)[0];if(t){let e=Sortable.get(t);e&&e.destroy()}}))}const zi=new Date,Fi=on(),Ai=ln(),Ii=["diverse","arrogant","angry","lazy","paranoid","greedy","puny","dumb","nearsighted","gluttony","slow","hard_of_hearing","pessimistic","solitary","pyrophobia","skittish","nyctophilia","frail","atrophy","invertebrate","pathetic","invertebrate","unorganized","slow_regen","snowy","mistrustful","fragrant","freespirit","hooved","heavy","gnawer"];function Ti(e,a){if(t.settings.boring)return t.race.hrt&&delete t.race.hrt,!1;switch(e){case"elven":case"capybara":case"centaur":case"wendigo":case"entish":case"yeti":return!!(11===zi.getMonth()&&zi.getDate()>=17||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"wolven":case"vulpine":return!!(Fi.active||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"arraak":return!!(10===zi.getMonth()&&zi.getDate()>=22&&zi.getDate()<=28||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"seraph":return!!(1===zi.getMonth()&&14===zi.getDate()||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0);case"junker":return!!(Ai.active||t.race.hrt&&t.race.hrt===e)&&(a&&(t.race.hrt=e),!0)}return!1}const Li={humanoid:{adaptable:1,wasteful:1},carnivore:{carnivore:1,beast:1,cautious:1},herbivore:{herbivore:1,instinct:1},small:{small:1,weak:1},giant:{large:1,strong:1},reptilian:{cold_blooded:1,scales:1},avian:{flier:1,hollow_bones:1,sky_lover:1},insectoid:{high_pop:1,fast_growth:1,high_metabolism:1},plant:{sappy:1,asymmetrical:1},fungi:{detritivore:1,spongy:1},aquatic:{submerged:1,low_light:1},fey:{elusive:1,iron_allergy:1},heat:{smoldering:1,cold_intolerance:1},polar:{chilled:1,heat_intolerance:1},sand:{scavenger:1,nomadic:1},demonic:{immoral:1,evil:1,soul_eater:1},angelic:{blissful:1,pompous:1,holy:1},synthetic:{artifical:1,powered:1},eldritch:{psychic:1,tormented:1,darkness:1,unfathomable:1}},Ei={adaptable:{name:z("trait_adaptable_name"),desc:z("trait_adaptable"),type:"genus",val:3,vars(e){switch(e||t.race.adaptable||1){case.25:return[3];case.5:return[5];case 1:return[10];case 2:return[15];case 3:return[20]}}},wasteful:{name:z("trait_wasteful_name"),desc:z("trait_wasteful"),type:"genus",val:-3,vars(e){switch(e||t.race.wasteful||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[6];case 3:return[4]}}},xenophobic:{name:z("trait_xenophobic_name"),desc:z("trait_xenophobic"),type:"genus",val:-5},carnivore:{name:z("trait_carnivore_name"),desc:z("trait_carnivore"),type:"genus",val:3,vars(e){switch(e||t.race.carnivore||1){case.25:return[65];case.5:return[60];case 1:return[50];case 2:return[40];case 3:return[35]}}},beast:{name:z("trait_beast_name"),desc:z("trait_beast"),type:"genus",val:2,vars(e){switch(e||t.race.beast||1){case.25:return[4,8,4];case.5:return[5,10,5];case 1:return[8,15,10];case 2:return[10,20,15];case 3:return[12,24,20]}}},cautious:{name:z("trait_cautious_name"),desc:z("trait_cautious"),type:"genus",val:-2,vars(e){switch(e||t.race.cautious||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},herbivore:{name:z("trait_herbivore_name"),desc:z("trait_herbivore"),type:"genus",val:-7},instinct:{name:z("trait_instinct_name"),desc:z("trait_instinct"),type:"genus",val:5,vars(e){switch(e||t.race.instinct||1){case.25:return[3,15];case.5:return[5,25];case 1:return[10,50];case 2:return[15,60];case 3:return[20,65]}}},small:{name:z("trait_small_name"),desc:z("trait_small"),type:"genus",val:6,vars(e){switch(e||t.race.small||1){case.25:return[.0025,.0015];case.5:return[.005,.0025];case 1:return[.01,.005];case 2:return[.0125,.006];case 3:return[.015,.0075]}}},weak:{name:z("trait_weak_name"),desc:z("trait_weak"),type:"genus",val:-3,vars(e){switch(e||t.race.weak||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},large:{name:z("trait_large_name"),desc:z("trait_large"),type:"genus",val:-5,vars(e){switch(e||t.race.large||1){case.25:return[.007];case.5:return[.006];case 1:return[.005];case 2:return[.004];case 3:return[.003]}}},strong:{name:z("trait_strong_name"),desc:z("trait_strong"),type:"genus",val:5,vars(e){switch(e||t.race.strong||1){case.25:return[2,1.25];case.5:return[3,1.5];case 1:return[4,2];case 2:return[5,2.25];case 3:return[6,2.5]}}},cold_blooded:{name:z("trait_cold_blooded_name"),desc:z("trait_cold_blooded"),type:"genus",val:-2,vars(e){switch(e||t.race.cold_blooded||1){case.25:return[30,6];case.5:return[25,8];case 1:return[20,10];case 2:return[15,15];case 3:return[12,18]}}},scales:{name:z("trait_scales_name"),desc:z("trait_scales"),type:"genus",val:5,vars(e){switch(e||t.race.scales||1){case.25:return[1,0,1];case.5:return[1,1,1];case 1:return[2,1,1];case 2:return[2,2,1];case 3:return[2,2,2]}}},flier:{name:z("trait_flier_name"),desc:z("trait_flier"),type:"genus",val:3,vars(e){switch(e||t.race.flier||1){case.25:return[10,0];case.5:return[15,0];case 1:return[25,1];case 2:return[40,1];case 3:return[50,2]}}},hollow_bones:{name:z("trait_hollow_bones_name"),desc:z("trait_hollow_bones"),type:"genus",val:2,vars(e){switch(e||t.race.hollow_bones||1){case.25:return[1];case.5:return[2];case 1:return[5];case 2:return[8];case 3:return[10]}}},sky_lover:{name:z("trait_sky_lover_name"),desc:z("trait_sky_lover"),type:"genus",val:-2,vars(e){switch(e||t.race.sky_lover||1){case.25:return[40];case.5:return[30];case 1:return[20];case 2:return[15];case 3:return[10]}}},rigid:{name:z("trait_rigid_name"),desc:z("trait_rigid"),type:"genus",val:-2,vars(e){switch(e||t.race.rigid||1){case.25:return[3];case.5:return[2];case 1:return[1];case 2:return[.5];case 3:return[.4]}}},high_pop:{name:z("trait_high_pop_name"),desc:z("trait_high_pop"),type:"genus",val:3,vars(e){switch(e||t.race.high_pop||1){case.25:return[2,50,1.5];case.5:return[3,34,2.5];case 1:return[4,26,3.5];case 2:return[5,21.2,4.5];case 3:return[6,18,5.5]}}},fast_growth:{name:z("trait_fast_growth_name"),desc:z("trait_fast_growth"),type:"genus",val:2,vars(e){switch(e||t.race.fast_growth||1){case.25:return[1.5,1];case.5:return[2,1];case 1:return[2,2];case 2:return[2.5,3];case 3:return[3,3]}}},high_metabolism:{name:z("trait_high_metabolism_name"),desc:z("trait_high_metabolism"),type:"genus",val:-1,vars(e){switch(e||t.race.high_metabolism||1){case.25:return[10];case.5:return[8];case 1:return[5];case 2:return[2];case 3:return[1]}}},photosynth:{name:z("trait_photosynth_name"),desc:z("trait_photosynth"),type:"genus",val:3,vars(e){switch(e||t.race.photosynth||1){case.25:return[10,5,4];case.5:return[20,10,5];case 1:return[40,20,10];case 2:return[50,30,15];case 3:return[60,35,20]}}},sappy:{name:z("trait_sappy_name"),desc:z("trait_sappy",[z("resource_Amber_name")]),type:"genus",val:4,vars(e){switch(e||t.race.sappy||1){case.25:return[.4];case.5:return[.5];case 1:return[.6];case 2:return[.65];case 3:return[.7]}}},asymmetrical:{name:z("trait_asymmetrical_name"),desc:z("trait_asymmetrical"),type:"genus",val:-3,vars(e){switch(e||t.race.asymmetrical||1){case.25:return[30];case.5:return[25];case 1:return[20];case 2:return[15];case 3:return[10]}}},detritivore:{name:z("trait_detritivore_name"),desc:z("trait_detritivore"),type:"genus",val:2,vars(e){switch(e||t.race.detritivore||1){case.25:return[65];case.5:return[72];case 1:return[80];case 2:return[85];case 3:return[90]}}},spores:{name:z("trait_spores_name"),desc:z("trait_spores"),type:"genus",val:2,vars(e){switch(e||t.race.spores||1){case.25:return[1,1.5,1];case.5:return[2,1.5,1];case 1:return[2,2,1];case 2:return[2,2.5,2];case 3:return[2,3,2]}}},spongy:{name:z("trait_spongy_name"),desc:z("trait_spongy"),type:"genus",val:-2},submerged:{name:z("trait_submerged_name"),desc:z("trait_submerged"),type:"genus",val:3},low_light:{name:z("trait_low_light_name"),desc:z("trait_low_light"),type:"genus",val:-2,vars(e){switch(e||t.race.low_light||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},elusive:{name:z("trait_elusive_name"),desc:z("trait_elusive"),type:"genus",val:7,vars(e){switch(e||t.race.elusive||1){case.25:return[10];case.5:return[15];case 1:return[20];case 2:return[25];case 3:return[30]}}},iron_allergy:{name:z("trait_iron_allergy_name"),desc:z("trait_iron_allergy"),type:"genus",val:-4,vars(e){switch(e||t.race.iron_allergy||1){case.25:return[40];case.5:return[35];case 1:return[25];case 2:return[18];case 3:return[15]}}},smoldering:{name:z("trait_smoldering_name"),desc:z("trait_smoldering"),type:"genus",val:7,vars(e){switch(e||t.race.smoldering||1){case.25:return[3,.14,.08];case.5:return[4,.18,.1];case 1:return[5,.35,.2];case 2:return[10,.38,.22];case 3:return[12,.4,.24]}}},cold_intolerance:{name:z("trait_cold_intolerance_name"),desc:z("trait_cold_intolerance"),type:"genus",val:-4,vars(e){switch(e||t.race.cold_intolerance||1){case.25:return[.35];case.5:return[.3];case 1:return[.25];case 2:return[.2];case 3:return[.18]}}},chilled:{name:z("trait_chilled_name"),desc:z("trait_chilled"),type:"genus",val:7,vars(e){switch(e||t.race.chilled||1){case.25:return[1,.14,.08,5,2,20];case.5:return[2,.18,.1,10,5,18];case 1:return[5,.35,.2,20,10,15];case 2:return[10,.38,.22,25,12,10];case 3:return[12,.4,.24,30,14,8]}}},heat_intolerance:{name:z("trait_heat_intolerance_name"),desc:z("trait_heat_intolerance"),type:"genus",val:-4,vars(e){switch(e||t.race.heat_intolerance||1){case.25:return[.35];case.5:return[.3];case 1:return[.25];case 2:return[.2];case 3:return[.18]}}},scavenger:{name:z("trait_scavenger_name"),desc:z("trait_scavenger"),type:"genus",val:3,vars(e){switch(e||t.race.scavenger||1){case.25:return[.08,20];case.5:return[.1,22];case 1:return[.12,25];case 2:return[.14,30];case 3:return[.16,32]}}},nomadic:{name:z("trait_nomadic_name"),desc:z("trait_nomadic"),type:"genus",val:-5},immoral:{name:z("trait_immoral_name"),desc:z("trait_immoral"),type:"genus",val:4,vars(e){switch(e||t.race.immoral||1){case.25:return[-30];case.5:return[-20];case 1:return[0];case 2:return[20];case 3:return[30]}}},evil:{name:z("trait_evil_name"),desc:z("trait_evil"),type:"genus",val:0},blissful:{name:z("trait_blissful_name"),desc:z("trait_blissful"),type:"genus",val:3,vars(e){switch(e||t.race.blissful||1){case.25:return[70];case.5:return[60];case 1:return[50];case 2:return[40];case 3:return[30]}}},pompous:{name:z("trait_pompous_name"),desc:z("trait_pompous"),type:"genus",val:-6,vars(e){switch(e||t.race.pompous||1){case.25:return[85];case.5:return[80];case 1:return[75];case 2:return[65];case 3:return[60]}}},holy:{name:z("trait_holy_name"),desc:z("trait_holy"),type:"genus",val:4,vars(e){switch(e||t.race.holy||1){case.25:return[25,10];case.5:return[30,15];case 1:return[50,25];case 2:return[60,35];case 3:return[65,40]}}},artifical:{name:z("trait_artifical_name"),desc:z("trait_artifical"),type:"genus",val:5,vars(e){switch(e||t.race.artifical||1){case.25:return[5];case.5:return[10];case 1:return[20];case 2:return[25];case 3:return[30]}}},powered:{name:z("trait_powered_name"),desc:z("trait_powered"),type:"genus",val:-6,vars(e){switch(e||t.race.powered||1){case.25:return[.35,5];case.5:return[.3,8];case 1:return[.2,16];case 2:return[.1,20];case 3:return[.05,24]}}},psychic:{name:z("trait_psychic_name"),desc:z("trait_psychic"),type:"genus",val:10,vars(e){switch(e||t.race.psychic||1){case.25:return[.35,5,.01,20];case.5:return[.65,10,.025,30];case 1:return[1,15,.05,40];case 2:return[1.25,20,.075,50];case 3:return[1.5,25,.1,60]}}},tormented:{name:z("trait_tormented_name"),desc:z("trait_tormented"),type:"genus",val:-25,vars(e){switch(e||t.race.tormented||1){case.25:return[99];case.5:return[95];case 1:return[90];case 2:return[80];case 3:return[75]}}},darkness:{name:z("trait_darkness_name"),desc:z("trait_darkness"),type:"genus",val:1,vars(e){switch(e||t.race.darkness||1){case.25:return[1];case.5:return[2];case 1:return[3];case 2:return[4];case 3:return[5]}}},unfathomable:{name:z("trait_unfathomable_name"),desc:z("trait_unfathomable"),type:"genus",val:15,vars(e){switch(e||t.race.unfathomable||1){case.25:return[1,.5,.05];case.5:return[1,.65,.08];case 1:return[2,.8,.1];case 2:return[2,.9,.12];case 3:return[3,1,.13]}}},creative:{name:z("trait_creative_name"),desc:z("trait_creative"),type:"major",val:8,vars(e){switch(e||t.race.creative||1){case.25:return[.0015,5];case.5:return[.0025,10];case 1:return[.005,20];case 2:return[.006,22];case 3:return[.0065,24]}}},diverse:{name:z("trait_diverse_name"),desc:z("trait_diverse"),type:"major",val:-4,vars(e){switch(e||t.race.diverse||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},studious:{name:z("trait_studious_name"),desc:z("trait_studious"),type:"major",val:2,vars(e){switch(e||t.race.studious||1){case.25:return[.1,6];case.5:return[.15,8];case 1:return[.25,10];case 2:return[.35,12];case 3:return[.4,14]}}},arrogant:{name:z("trait_arrogant_name"),desc:z("trait_arrogant"),type:"major",val:-2,vars(e){switch(e||t.race.arrogant||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},brute:{name:z("trait_brute_name"),desc:z("trait_brute"),type:"major",val:7,vars(e){switch(e||t.race.brute||1){case.25:return[20,50];case.5:return[25,60];case 1:return[50,100];case 2:return[60,120];case 3:return[65,140]}}},angry:{name:z("trait_angry_name"),desc:z("trait_angry"),type:"major",val:-1,vars(e){switch(e||t.race.angry||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},lazy:{name:z("trait_lazy_name"),desc:z("trait_lazy"),type:"major",val:-4,vars(e){switch(e||t.race.lazy||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},curious:{name:z("trait_curious_name"),desc:z("trait_curious"),type:"major",val:4,vars(e){switch(e||t.race.curious||1){case.25:return[.03];case.5:return[.05];case 1:return[.1];case 2:return[.12];case 3:return[.13]}}},pack_mentality:{name:z("trait_pack_mentality_name"),desc:z("trait_pack_mentality"),type:"major",val:4,vars(e){switch(e||t.race.pack_mentality||1){case.25:return[.04,.016];case.5:return[.035,.018];case 1:return[.03,.02];case 2:return[.026,.022];case 3:return[.024,.023]}}},tracker:{name:z("trait_tracker_name"),desc:z("trait_tracker"),type:"major",val:2,vars(e){switch(e||t.race.tracker||1){case.25:return[10];case.5:return[15];case 1:return[20];case 2:return[25];case 3:return[30]}}},playful:{name:z("trait_playful_name"),desc:z("trait_playful"),type:"major",val:5,vars(e){switch(e||t.race.playful||1){case.25:return[.3];case.5:return[.4];case 1:return[.5];case 2:return[.6];case 3:return[.7]}}},freespirit:{name:z("trait_freespirit_name"),desc:z("trait_freespirit"),type:"major",val:-3,vars(e){switch(e||t.race.freespirit||1){case.25:return[65];case.5:return[60];case 1:return[50];case 2:return[35];case 3:return[25]}}},beast_of_burden:{name:z("trait_beast_of_burden_name"),desc:z("trait_beast_of_burden"),type:"major",val:3},sniper:{name:z("trait_sniper_name"),desc:z("trait_sniper"),type:"major",val:6,vars(e){switch(e||t.race.sniper||1){case.25:return[4];case.5:return[6];case 1:return[8];case 2:return[9];case 3:return[10]}}},hooved:{name:z("trait_hooved_name"),desc:z("trait_hooved"),type:"major",val:-4,vars(e){switch(e||t.race.hooved||1){case.25:return[130];case.5:return[120];case 1:return[100];case 2:return[80];case 3:return[70]}}},rage:{name:z("trait_rage_name"),desc:z("trait_rage"),type:"major",val:4,vars(e){switch(e||t.race.rage||1){case.25:return[.3,20];case.5:return[.5,30];case 1:return[1,50];case 2:return[1.25,60];case 3:return[1.4,65]}}},heavy:{name:z("trait_heavy_name"),desc:z("trait_heavy"),type:"major",val:-4,vars(e){switch(e||t.race.heavy||1){case.25:return[18,10];case.5:return[15,8];case 1:return[10,5];case 2:return[8,4];case 3:return[6,3]}}},gnawer:{name:z("trait_gnawer_name"),desc:z("trait_gnawer"),type:"major",val:-1,vars(e){switch(e||t.race.gnawer||1){case.25:return[.5];case.5:return[.4];case 1:return[.25];case 2:return[.2];case 3:return[.15]}}},calm:{name:z("trait_calm_name"),desc:z("trait_calm"),type:"major",val:6,vars(e){switch(e||t.race.calm||1){case.25:return[7];case.5:return[8];case 1:return[10];case 2:return[12];case 3:return[13]}}},pack_rat:{name:z("trait_pack_rat_name"),desc:z("trait_pack_rat"),type:"major",val:3,vars(e){switch(e||t.race.pack_rat||1){case.25:return[5,2];case.5:return[6,3];case 1:return[10,5];case 2:return[15,8];case 3:return[20,10]}}},paranoid:{name:z("trait_paranoid_name"),desc:z("trait_paranoid"),type:"major",val:-3,vars(e){switch(e||t.race.paranoid||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},greedy:{name:z("trait_greedy_name"),desc:z("trait_greedy"),type:"major",val:-5,vars(e){switch(e||t.race.greedy||1){case.25:return[17.5];case.5:return[15];case 1:return[12.5];case 2:return[10];case 3:return[8]}}},merchant:{name:z("trait_merchant_name"),desc:z("trait_merchant"),type:"major",val:3,vars(e){switch(e||t.race.merchant||1){case.25:return[10,3];case.5:return[15,5];case 1:return[25,10];case 2:return[35,12];case 3:return[40,13]}}},smart:{name:z("trait_smart_name"),desc:z("trait_smart"),type:"major",val:6,vars(e){switch(e||t.race.smart||1){case.25:return[3];case.5:return[5];case 1:return[10];case 2:return[12];case 3:return[13]}}},puny:{name:z("trait_puny_name"),desc:z("trait_puny"),type:"major",val:-4,vars(e){switch(e||t.race.puny||1){case.25:return[18];case.5:return[15];case 1:return[10];case 2:return[6];case 3:return[4]}}},dumb:{name:z("trait_dumb_name"),desc:z("trait_dumb"),type:"major",val:-5,vars(e){switch(e||t.race.dumb||1){case.25:return[7];case.5:return[6];case 1:return[5];case 2:return[4];case 3:return[3]}}},tough:{name:z("trait_tough_name"),desc:z("trait_tough"),type:"major",val:4,vars(e){switch(e||t.race.tough||1){case.25:return[10];case.5:return[15];case 1:return[25];case 2:return[35];case 3:return[40]}}},nearsighted:{name:z("trait_nearsighted_name"),desc:z("trait_nearsighted"),type:"major",val:-4,vars(e){switch(e||t.race.nearsighted||1){case.25:return[18];case.5:return[15];case 1:return[12];case 2:return[10];case 3:return[8]}}},intelligent:{name:z("trait_intelligent_name"),desc:z("trait_intelligent"),type:"major",val:7,vars(e){switch(e||t.race.intelligent||1){case.25:return[.08,.15];case.5:return[.1,.2];case 1:return[.125,.25];case 2:return[.14,.3];case 3:return[.15,.32]}}},regenerative:{name:z("trait_regenerative_name"),desc:z("trait_regenerative"),type:"major",val:8,vars:e=>[4],vars(e){switch(e||t.race.regenerative||1){case.25:return[2];case.5:return[3];case 1:return[4];case 2:return[5];case 3:return[6]}}},gluttony:{name:z("trait_gluttony_name"),desc:z("trait_gluttony"),type:"major",val:-2,vars(e){switch(e||t.race.gluttony||1){case.25:return[20];case.5:return[15];case 1:return[10];case 2:return[8];case 3:return[6]}}},slow:{name:z("trait_slow_name"),desc:z("trait_slow"),type:"major",val:-5,vars(e){switch(e||t.race.slow||1){case.25:return[13];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},armored:{name:z("trait_armored_name"),desc:z("trait_armored"),type:"major",val:4,vars(e){switch(e||t.race.armored||1){case.25:return[15,1];case.5:return[25,1];case 1:return[50,2];case 2:return[70,2];case 3:return[80,2]}}},optimistic:{name:z("trait_optimistic_name"),desc:z("trait_optimistic"),type:"major",val:5,vars(e){switch(e||t.race.optimistic||1){case.25:return[4,6];case.5:return[5,8];case 1:return[10,10];case 2:return[15,13];case 3:return[18,15]}}},chameleon:{name:z("trait_chameleon_name"),desc:z("trait_chameleon"),type:"major",val:6,vars(e){switch(e||t.race.chameleon||1){case.25:return[5,10];case.5:return[10,15];case 1:return[20,20];case 2:return[25,25];case 3:return[30,30]}}},slow_digestion:{name:z("trait_slow_digestion_name"),desc:z("trait_slow_digestion"),type:"major",val:1,vars(e){switch(e||t.race.slow_digestion||1){case.25:return[.3];case.5:return[.5];case 1:return[.75];case 2:return[1];case 3:return[1.25]}}},hard_of_hearing:{name:z("trait_hard_of_hearing_name"),desc:z("trait_hard_of_hearing"),type:"major",val:-3,vars(e){switch(e||t.race.hard_of_hearing||1){case.25:return[7];case.5:return[6];case 1:return[5];case 2:return[4];case 3:return[3]}}},resourceful:{name:z("trait_resourceful_name"),desc:z("trait_resourceful"),type:"major",val:4,vars(e){switch(e||t.race.resourceful||1){case.25:return[6];case.5:return[8];case 1:return[12];case 2:return[16];case 3:return[18]}}},selenophobia:{name:z("trait_selenophobia_name"),desc:z("trait_selenophobia"),type:"major",val:-6,vars(e){switch(e||t.race.selenophobia||1){case.25:return[2];case.5:return[3];case 1:return[4];case 2:return[5];case 3:return[6]}}},leathery:{name:z("trait_leathery_name"),desc:z("trait_leathery"),type:"major",val:2,vars(e){switch(e||t.race.leathery||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:return[1];case 3:return[0]}}},pessimistic:{name:z("trait_pessimistic_name"),desc:z("trait_pessimistic"),type:"major",val:-1,vars(e){switch(e||t.race.pessimistic||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:case 3:return[1]}}},hoarder:{name:z("trait_hoarder_name"),desc:z("trait_hoarder"),type:"major",val:4,vars(e){switch(e||t.race.hoarder||1){case.25:return[5];case.5:return[10];case 1:return[20];case 2:return[25];case 3:return[30]}}},solitary:{name:z("trait_solitary_name"),desc:z("trait_solitary"),type:"major",val:-1,vars(e){switch(e||t.race.solitary||1){case.25:return[.01,.025];case.5:return[.01,.02];case 1:return[.02,.02];case 2:return[.025,.02];case 3:return[.025,.015]}}},kindling_kindred:{name:z("trait_kindling_kindred_name"),desc:z("trait_kindling_kindred"),type:"major",val:8,vars(e){switch(e||t.race.kindling_kindred||1){case.25:return[10];case.5:return[8];case 1:return[5];case 2:return[4];case 3:return[3]}}},pyrophobia:{name:z("trait_pyrophobia_name"),desc:z("trait_pyrophobia"),type:"major",val:-4,vars(e){switch(e||t.race.pyrophobia||1){case.25:return[14];case.5:return[12];case 1:return[10];case 2:return[8];case 3:return[6]}}},hyper:{name:z("trait_hyper_name"),desc:z("trait_hyper"),type:"major",val:4,vars(e){switch(e||t.race.hyper||1){case.25:return[2];case.5:return[3];case 1:return[5];case 2:return[6];case 3:return[7]}}},skittish:{name:z("trait_skittish_name"),desc:z("trait_skittish"),type:"major",val:-4,vars(e){switch(e||t.race.skittish||1){case.25:return[18];case.5:return[15];case 1:return[12];case 2:return[8];case 3:return[6]}}},fragrant:{name:z("trait_fragrant_name"),desc:z("trait_fragrant"),type:"major",val:-3,vars(e){switch(e||t.race.fragrant||1){case.25:return[35];case.5:return[30];case 1:return[20];case 2:return[15];case 3:return[12]}}},sticky:{name:z("trait_sticky_name"),desc:z("trait_sticky"),type:"major",val:3,vars(e){switch(e||t.race.sticky||1){case.25:return[5,5];case.5:return[10,8];case 1:return[20,15];case 2:return[25,18];case 3:return[30,20]}}},infectious:{name:z("trait_infectious_name"),desc:z("trait_infectious"),type:"major",val:4,vars(e){switch(e||t.race.infectious||1){case.25:return[1,2,3,7,18];case.5:return[1,2,4,8,20];case 1:return[2,3,5,10,25];case 2:return[2,4,6,12,30];case 3:return[3,4,7,13,32]}}},parasite:{name:z("trait_parasite_name"),desc:z("trait_parasite"),type:"major",val:-4},toxic:{name:z("trait_toxic_name"),desc:z("trait_toxic"),type:"major",val:5,vars(e){switch(e||t.race.toxic||1){case.25:return[5,3,10];case.5:return[10,5,15];case 1:return[20,8,30];case 2:return[25,10,40];case 3:return[30,12,45]}}},nyctophilia:{name:z("trait_nyctophilia_name"),desc:z("trait_nyctophilia"),type:"major",val:-3,vars(e){switch(e||t.race.nyctophilia||1){case.25:return[10,6];case.5:return[8,5];case 1:return[5,2];case 2:return[3,1];case 3:return[2,1]}}},infiltrator:{name:z("trait_infiltrator_name"),desc:z("trait_infiltrator"),type:"major",val:4,vars(e){switch(e||t.race.infiltrator||1){case.25:return[110];case.5:return[100];case 1:return[90];case 2:return[85];case 3:return[80]}}},hibernator:{name:z("trait_hibernator_name"),desc:z("trait_hibernator"),type:"major",val:-3,vars(e){switch(e||t.race.hibernator||1){case.25:return[15,8];case.5:return[20,8];case 1:return[25,8];case 2:return[30,6];case 3:return[35,5]}}},cannibalize:{name:z("trait_cannibalize_name"),desc:z("trait_cannibalize"),type:"major",val:5,vars(e){switch(e||t.race.cannibalize||1){case.25:return[8];case.5:return[10];case 1:return[15];case 2:return[20];case 3:return[22]}}},frail:{name:z("trait_frail_name"),desc:z("trait_frail"),type:"major",val:-5,vars(e){switch(e||t.race.frail||1){case.25:return[2,2];case.5:return[1,2];case 1:return[1,1];case 2:case 3:return[1,0]}}},malnutrition:{name:z("trait_malnutrition_name"),desc:z("trait_malnutrition"),type:"major",val:1,vars(e){switch(e||t.race.malnutrition||1){case.25:return[10];case.5:return[12];case 1:return[25];case 2:return[40];case 3:return[50]}}},claws:{name:z("trait_claws_name"),desc:z("trait_claws"),type:"major",val:5,vars(e){switch(e||t.race.claws||1){case.25:return[8];case.5:return[12];case 1:return[25];case 2:return[32];case 3:return[35]}}},atrophy:{name:z("trait_atrophy_name"),desc:z("trait_atrophy"),type:"major",val:-1,vars(e){switch(e||t.race.atrophy||1){case.25:return[.35];case.5:return[.25];case 1:return[.15];case 2:return[.1];case 3:return[.08]}}},hivemind:{name:z("trait_hivemind_name"),desc:z("trait_hivemind"),type:"major",val:9,vars(e){switch(e||t.race.hivemind||1){case.25:return[12];case.5:return[11];case 1:return[10];case 2:return[8];case 3:return[7]}}},tunneler:{name:z("trait_tunneler_name"),desc:z("trait_tunneler"),type:"major",val:2,vars(e){switch(e||t.race.tunneler||1){case.25:return[.002];case.5:return[.005];case 1:return[.01];case 2:return[.015];case 3:return[.018]}}},blood_thirst:{name:z("trait_blood_thirst_name"),desc:z("trait_blood_thirst"),type:"major",val:5,vars(e){switch(e||t.race.blood_thirst||1){case.25:return[25e4];case.5:return[5e5];case 1:return[1e6];case 2:return[2e6];case 3:return[4e6]}}},apex_predator:{name:z("trait_apex_predator_name"),desc:z("trait_apex_predator"),type:"major",val:6,vars(e){switch(e||t.race.apex_predator||1){case.25:return[15,20];case.5:return[20,30];case 1:return[30,50];case 2:return[40,60];case 3:return[45,65]}}},invertebrate:{name:z("trait_invertebrate_name"),desc:z("trait_invertebrate"),type:"major",val:-2,vars(e){switch(e||t.race.invertebrate||1){case.25:return[25];case.5:return[20];case 1:return[10];case 2:return[8];case 3:return[5]}}},suction_grip:{name:z("trait_suction_grip_name"),desc:z("trait_suction_grip"),type:"major",val:4,vars(e){switch(e||t.race.suction_grip||1){case.25:return[5];case.5:return[6];case 1:return[8];case 2:return[12];case 3:return[14]}}},befuddle:{name:z("trait_befuddle_name"),desc:z("trait_befuddle"),type:"major",val:4,vars(e){switch(e||t.race.befuddle||1){case.25:return[20];case.5:return[30];case 1:return[50];case 2:return[75];case 3:return[85]}}},environmentalist:{name:z("trait_environmentalist_name"),desc:z("trait_environmentalist"),type:"major",val:-5},unorganized:{name:z("trait_unorganized_name"),desc:z("trait_unorganized"),type:"major",val:-2,vars(e){switch(e||t.race.unorganized||1){case.25:return[90];case.5:return[80];case 1:return[50];case 2:return[40];case 3:return[30]}}},musical:{name:z("trait_musical_name"),desc:z("trait_musical"),type:"major",val:5,vars(e){switch(e||t.race.musical||1){case.25:return[.25];case.5:return[.5];case 1:return[1];case 2:return[1.1];case 3:return[1.2]}}},revive:{name:z("trait_revive_name"),desc:z("trait_revive"),type:"major",val:4,vars(e){switch(e||t.race.revive||1){case.25:return[7,5,2,8,6,3,4];case.5:return[6,4,2,7,5,2.5,4];case 1:return[5,3,1.5,6,4,2,3];case 2:return[4,2,1,5,3,1.5,2];case 3:return[3,1.5,1,4,2.5,1,2]}}},slow_regen:{name:z("trait_slow_regen_name"),desc:z("trait_slow_regen"),type:"major",val:-4,vars(e){switch(e||t.race.slow_regen||1){case.25:return[40];case.5:return[35];case 1:return[25];case 2:return[20];case 3:return[15]}}},forge:{name:z("trait_forge_name"),desc:z("trait_forge"),type:"major",val:4,vars(e){switch(e||t.race.forge||1){case.25:return[.5];case.5:return[1];case 1:return[2];case 2:return[2.5];case 3:return[3]}}},autoignition:{name:z("trait_autoignition_name"),desc:z("trait_autoignition"),type:"major",val:-4,vars(e){switch(e||t.race.autoignition||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:return[1.5];case 3:return[1]}}},blurry:{name:z("trait_blurry_name"),desc:z("trait_blurry"),type:"major",val:5,vars(e){switch(e||t.race.blurry||1){case.25:return[10];case.5:return[15];case 1:return[25];case 2:return[35];case 3:return[40]}}},snowy:{name:z("trait_snowy_name"),desc:z("trait_snowy"),type:"major",val:-3,vars(e){switch(e||t.race.snowy||1){case.25:return[4,10];case.5:return[3,8];case 1:return[2,5];case 2:return[2,4];case 3:return[1,3]}}},ravenous:{name:z("trait_ravenous_name"),desc:z("trait_ravenous"),type:"major",val:-5,vars(e){switch(e||t.race.ravenous||1){case.25:return[30,2];case.5:return[25,2];case 1:return[20,3];case 2:return[15,4];case 3:return[10,4]}}},ghostly:{name:z("trait_ghostly_name"),desc:z("trait_ghostly"),type:"major",val:5,vars(e){switch(e||t.race.ghostly||1){case.25:return[20,1.2,5];case.5:return[25,1.25,10];case 1:return[50,1.5,15];case 2:return[60,1.6,20];case 3:return[65,1.7,22]}}},lawless:{name:z("trait_lawless_name"),desc:z("trait_lawless"),type:"major",val:3,vars(e){switch(e||t.race.lawless||1){case.25:return[30];case.5:return[50];case 1:return[90];case 2:return[95];case 3:return[98]}}},mistrustful:{name:z("trait_mistrustful_name"),desc:z("trait_mistrustful"),type:"major",val:-1,vars(e){switch(e||t.race.mistrustful||1){case.25:return[4];case.5:return[3];case 1:return[2];case 2:case 3:return[1]}}},humpback:{name:z("trait_humpback_name"),desc:z("trait_humpback"),type:"major",val:4,vars(e){switch(e||t.race.humpback||1){case.25:return[.2,8];case.5:return[.25,10];case 1:return[.5,20];case 2:return[.75,25];case 3:return[.8,30]}}},thalassophobia:{name:z("trait_thalassophobia_name"),desc:z("trait_thalassophobia"),type:"major",val:-4},fiery:{name:z("trait_fiery_name"),desc:z("trait_fiery"),type:"major",val:10,vars(e){switch(e||t.race.fiery||1){case.25:return[30,15];case.5:return[40,18];case 1:return[65,25];case 2:return[70,35];case 3:return[72,38]}}},terrifying:{name:z("trait_terrifying_name"),desc:z("trait_terrifying"),type:"major",val:6,vars(e){switch(e||t.race.terrifying||1){case.25:return[8,20];case.5:return[10,25];case 1:return[12,32];case 2:return[12,34];case 3:return[12,36]}}},slaver:{name:z("trait_slaver_name"),desc:z("trait_slaver"),type:"major",val:12,vars(e){switch(e||t.race.slaver||1){case.25:return[.1];case.5:return[.14];case 1:return[.28];case 2:return[.3];case 3:return[.32]}}},compact:{name:z("trait_compact_name"),desc:z("trait_compact"),type:"major",val:10,vars(e){switch(e||t.race.compact||1){case.25:return[.005,.003];case.5:return[.01,.005];case 1:return[.015,.0075];case 2:return[.018,.0085];case 3:return[.02,.009]}}},conniving:{name:z("trait_conniving_name"),desc:z("trait_conniving"),type:"major",val:4,vars(e){switch(e||t.race.conniving||1){case.25:return[2,8];case.5:return[3,10];case 1:return[5,15];case 2:return[8,20];case 3:return[10,24]}}},pathetic:{name:z("trait_pathetic_name"),desc:z("trait_pathetic"),type:"major",val:-5,vars(e){switch(e||t.race.pathetic||1){case.25:return[35];case.5:return[30];case 1:return[25];case 2:return[20];case 3:return[15]}}},spiritual:{name:z("trait_spiritual_name"),desc:z("trait_spiritual"),type:"major",val:4,vars(e){switch(e||t.race.spiritual||1){case.25:return[8];case.5:return[10];case 1:return[13];case 2:return[15];case 3:return[18]}}},truthful:{name:z("trait_truthful_name"),desc:z("trait_truthful"),type:"major",val:-7,vars(e){switch(e||t.race.truthful||1){case.25:return[75];case.5:return[65];case 1:return[50];case 2:return[30];case 3:return[20]}}},unified:{name:z("trait_unified_name"),desc:z("trait_unified"),type:"major",val:4,vars(e){switch(e||t.race.unified||1){case.25:return[0];case.5:return[1];case 1:return[3];case 2:return[5];case 3:return[7]}}},rainbow:{name:z("trait_rainbow_name"),desc:z("trait_rainbow"),type:"major",val:3,vars(e){switch(e||t.race.rainbow||1){case.25:return[20];case.5:return[30];case 1:return[50];case 2:return[80];case 3:return[100]}}},magnificent:{name:z("trait_magnificent_name"),desc:z("trait_magnificent"),type:"major",val:6,vars(e){switch(e||t.race.magnificent||1){case.25:return[300,1,.5,.75,1];case.5:return[350,2,.75,.8,1];case 1:return[400,3,1,1,1];case 2:return[450,3,1.5,1.5,1.5];case 3:return[500,3,2,2,2]}}},noble:{name:z("trait_noble_name"),desc:z("trait_noble"),type:"major",val:-3,vars(e){switch(e||t.race.noble||1){case.25:return[15,20];case.5:return[12,20];case 1:return[10,20];case 2:return[10,24];case 3:return[10,28]}}},imitation:{name:z("trait_imitation_name"),desc:z("trait_imitation"),type:"major",val:6,vars(e){switch(e||t.race.imitation||1){case.25:return[.25,.5];case.5:return[.25,1];case 1:return[.5,1];case 2:return[.5,2];case 3:return[1,2]}}},emotionless:{name:z("trait_emotionless_name"),desc:z("trait_emotionless"),type:"major",val:-4,vars(e){switch(e||t.race.emotionless||1){case.25:return[50,10];case.5:return[45,10];case 1:return[35,13];case 2:return[25,15];case 3:return[20,15]}}},logical:{name:z("trait_logical_name"),desc:z("trait_logical"),type:"major",val:6,vars(e){switch(e||t.race.logical||1){case.25:return[25,10];case.5:return[50,15];case 1:return[100,25];case 2:return[125,30];case 3:return[150,32]}}},shapeshifter:{name:z("trait_shapeshifter_name"),desc:z("trait_shapeshifter"),type:"major",val:10,vars(e){switch(e||t.race.shapeshifter||1){case.25:return[.25,.5];case.5:return[.25,1];case 1:return[.5,1];case 2:return[.5,2];case 3:return[1,2]}}},deconstructor:{name:z("trait_deconstructor_name"),desc:z("trait_deconstructor"),type:"major",val:-4,vars(e){switch(e||t.race.deconstructor||1){case.25:return[40];case.5:return[60];case 1:return[100];case 2:return[125];case 3:return[140]}}},linked:{name:z("trait_linked_name"),desc:z("trait_linked"),type:"major",val:4,vars(e){switch(e||t.race.linked||1){case.25:return[.03,40];case.5:return[.05,40];case 1:return[.1,80];case 2:return[.12,100];case 3:return[.14,100]}}},dark_dweller:{name:z("trait_dark_dweller_name"),desc:z("trait_dark_dweller"),type:"major",val:-3,vars(e){switch(e||t.race.dark_dweller||1){case.25:return[90];case.5:return[75];case 1:return[60];case 2:return[45];case 3:return[30]}}},swift:{name:z("trait_swift_name"),desc:z("trait_swift"),type:"major",val:10,vars(e){switch(e||t.race.swift||1){case.25:return[35,15];case.5:return[55,30];case 1:return[75,45];case 2:return[85,55];case 3:return[90,65]}}},anthropophagite:{name:z("trait_anthropophagite_name"),desc:z("trait_anthropophagite"),type:"major",val:-2,vars(e){switch(e||t.race.anthropophagite||1){case.25:return[.4];case.5:return[.65];case 1:return[1];case 2:return[1.5];case 3:return[2]}}},living_tool:{name:z("trait_living_tool_name"),desc:z("trait_living_tool"),type:"major",val:12,vars(e){switch(e||t.race.living_tool||1){case.25:return[.65,5];case.5:return[.8,12];case 1:return[1,25];case 2:return[1.1,35];case 3:return[1.2,42]}}},bloated:{name:z("trait_bloated_name"),desc:z("trait_bloated"),type:"major",val:-10,vars(e){switch(e||t.race.bloated||1){case.25:return[25];case.5:return[20];case 1:return[15];case 2:return[10];case 3:return[5]}}},ooze:{name:z("trait_ooze_name"),desc:z("trait_ooze"),type:"major",val:-50,vars(e){switch(e||t.race.ooze||1){case.25:return[20,25,40];case.5:return[15,20,35];case 1:return[12,15,30];case 2:return[10,12,25];case 3:return[8,10,20]}}},soul_eater:{name:z("trait_soul_eater_name"),desc:z("trait_soul_eater"),type:"special",val:0},untapped:{name:z("trait_untapped_name"),desc:z("trait_untapped"),type:"special",val:0},emfield:{name:z("trait_emfield_name"),desc:z("trait_emfield"),type:"special",val:-20},tactical:{name:z("trait_tactical_name"),desc:z("trait_tactical"),type:"minor",vars:e=>[5]},analytical:{name:z("trait_analytical_name"),desc:z("trait_analytical"),type:"minor",vars:e=>[1]},promiscuous:{name:z("trait_promiscuous_name"),desc:z("trait_promiscuous"),type:"minor",vars:e=>[1,.02]},resilient:{name:z("trait_resilient_name"),desc:z("trait_resilient"),type:"minor",vars:e=>[2]},cunning:{name:z("trait_cunning_name"),desc:z("trait_cunning"),type:"minor",vars:e=>[5]},hardy:{name:z("trait_hardy_name"),desc:z("trait_hardy"),type:"minor",vars:e=>[1]},ambidextrous:{name:z("trait_ambidextrous_name"),desc:z("trait_ambidextrous"),type:"minor",vars:e=>[3,2]},industrious:{name:z("trait_industrious_name"),desc:z("trait_industrious"),type:"minor",vars:e=>[2]},content:{name:z("trait_content_name"),desc:z("trait_content"),type:"minor"},fibroblast:{name:z("trait_fibroblast_name"),desc:z("trait_fibroblast"),type:"minor",vars:e=>[2]},metallurgist:{name:z("trait_metallurgist_name"),desc:z("trait_metallurgist"),type:"minor",vars:e=>[4]},gambler:{name:z("trait_gambler_name"),desc:z("trait_gambler"),type:"minor",vars:e=>[4]},persuasive:{name:z("trait_persuasive_name"),desc:z("trait_persuasive"),type:"minor",vars:e=>[1]},fortify:{name:z("trait_fortify_name"),desc:z("trait_fortify"),type:"special"},mastery:{name:z("trait_mastery_name"),desc:z("trait_mastery"),type:"special",vars:e=>[1]}},Ki={protoplasm:{name:z("race_protoplasm"),desc:z("race_protoplasm_desc"),type:"organism",home:z("race_prehistoric"),entity:"ooze",traits:{},solar:{red:z("race_human_solar_red"),hell:z("race_human_solar_hell"),gas:z("race_human_solar_gas"),gas_moon:z("race_human_solar_gas_moon"),dwarf:z("race_human_solar_dwarf")},fanaticism:"none",basic:()=>!1},human:{name:z("race_human"),desc:z("race_human_desc"),type:"humanoid",home:z("race_human_home"),entity:z("race_human_entity"),traits:{creative:1,diverse:1},solar:{red:z("race_human_solar_red"),hell:z("race_human_solar_hell"),gas:z("race_human_solar_gas"),gas_moon:z("race_human_solar_gas_moon"),dwarf:z("race_human_solar_dwarf")},fanaticism:"creative",basic:()=>!0},elven:{name:z("race_elven"),desc:z(Ti("elven")?"race_xmas_elf_desc":"race_elven_desc"),type:"humanoid",home:z(Ti("elven")?"race_xmas_elf_home":"race_elven_home"),entity:z("race_elven_entity"),traits:{studious:1,arrogant:1},solar:{red:z(Ti("elven")?"race_xmas_elf_solar_red":"race_elven_solar_red"),hell:z(Ti("elven")?"race_xmas_elf_solar_hell":"race_elven_solar_hell"),gas:z(Ti("elven")?"race_xmas_elf_solar_gas":"race_elven_solar_gas"),gas_moon:z(Ti("elven")?"race_xmas_elf_solar_gas_moon":"race_elven_solar_gas_moon"),dwarf:z(Ti("elven")?"race_xmas_elf_solar_dwarf":"race_elven_solar_dwarf")},fanaticism:"studious",basic:()=>!0},orc:{name:z("race_orc"),desc:z("race_orc_desc"),type:"humanoid",home:z("race_orc_home"),entity:z("race_orc_entity"),traits:{brute:1,angry:1},solar:{red:z("race_orc_solar_red"),hell:z("race_orc_solar_hell"),gas:z("race_orc_solar_gas"),gas_moon:z("race_orc_solar_gas_moon"),dwarf:z("race_orc_solar_dwarf")},fanaticism:"brute",basic:()=>!0},cath:{name:z("race_cath"),desc:z("race_cath_desc"),type:"carnivore",home:z("race_cath_home"),entity:z("race_cath_entity"),traits:{lazy:1,curious:1},solar:{red:z("race_cath_solar_red"),hell:z("race_cath_solar_hell"),gas:z("race_cath_solar_gas"),gas_moon:z("race_cath_solar_gas_moon"),dwarf:z("race_cath_solar_dwarf")},fanaticism:"curious",basic:()=>!0},wolven:{name:Ti("wolven")?z("race_rabbit"):z("race_wolven"),desc:Ti("wolven")?z("race_rabbit_desc"):z("race_wolven_desc"),type:"carnivore",home:Ti("wolven")?z("race_rabbit_home"):z("race_wolven_home"),entity:Ti("wolven")?z("race_rabbit_entity"):z("race_wolven_entity"),traits:{pack_mentality:1,tracker:1},solar:{red:Ti("wolven")?z("race_rabbit_solar_red"):z("race_wolven_solar_red"),hell:Ti("wolven")?z("race_rabbit_solar_hell"):z("race_wolven_solar_hell"),gas:Ti("wolven")?z("race_rabbit_solar_gas"):z("race_wolven_solar_gas"),gas_moon:Ti("wolven")?z("race_rabbit_solar_gas_moon"):z("race_wolven_solar_gas_moon"),dwarf:Ti("wolven")?z("race_rabbit_solar_dwarf"):z("race_wolven_solar_dwarf")},fanaticism:"tracker",basic:()=>!0},vulpine:{name:Ti("vulpine")?z("race_chocolate_rabbit"):z("magic"===t.race.universe?"race_kitsune":"race_vulpine"),desc:()=>Ti("vulpine")?z("race_chocolate_rabbit_desc"):z("race_vulpine_desc",[z("magic"===t.race.universe?"race_kitsune":"race_vulpine"),t.race.hasOwnProperty("fox_color")?z(`color_${t.race.fox_color}`):z("color_red")]),type:"carnivore",home:Ti("vulpine")?z("race_chocolate_rabbit_home"):z("race_vulpine_home"),entity:z("race_vulpine_entity"),traits:{playful:1,freespirit:1},solar:{red:Ti("vulpine")?z("race_chocolate_rabbit_solar_red"):z("race_vulpine_solar_red"),hell:Ti("vulpine")?z("race_chocolate_rabbit_solar_hell"):z("race_vulpine_solar_hell"),gas:Ti("vulpine")?z("race_chocolate_rabbit_solar_gas"):z("race_vulpine_solar_gas"),gas_moon:Ti("vulpine")?z("race_chocolate_rabbit_solar_gas_moon"):z("race_vulpine_solar_gas_moon"),dwarf:Ti("vulpine")?z("race_chocolate_rabbit_solar_dwarf"):z("race_vulpine_solar_dwarf")},fanaticism:"playful",basic:()=>!0},centaur:{name:z(Ti("centaur")?"race_reindeer":"race_centaur"),desc:z(Ti("centaur")?"race_reindeer_desc":"race_centaur_desc"),type:"herbivore",home:z(Ti("centaur")?"race_reindeer_home":"race_centaur_home"),entity:z(Ti("centaur")?"race_reindeer_entity":"race_centaur_entity"),traits:{sniper:1,hooved:1},solar:{red:z(Ti("centaur")?"race_reindeer_solar_red":"race_centaur_solar_red"),hell:z(Ti("centaur")?"race_reindeer_solar_hell":"race_centaur_solar_hell"),gas:z(Ti("centaur")?"race_reindeer_solar_gas":"race_centaur_solar_gas"),gas_moon:z(Ti("centaur")?"race_reindeer_solar_gas_moon":"race_centaur_solar_gas_moon"),dwarf:z(Ti("centaur")?"race_reindeer_solar_dwarf":"race_centaur_solar_dwarf")},fanaticism:"sniper",basic:()=>!0},rhinotaur:{name:z("race_rhinotaur"),desc:z("race_rhinotaur_desc"),type:"herbivore",home:z("race_rhinotaur_home"),entity:z("race_rhinotaur_entity"),traits:{rage:1,heavy:1},solar:{red:z("race_rhinotaur_solar_red"),hell:z("race_rhinotaur_solar_hell"),gas:z("race_rhinotaur_solar_gas"),gas_moon:z("race_rhinotaur_solar_gas_moon"),dwarf:z("race_rhinotaur_solar_dwarf")},fanaticism:"rage",basic:()=>!0},capybara:{name:z(Ti("capybara")?"race_donkey":"race_capybara"),desc:z(Ti("capybara")?"race_donkey_desc":"race_capybara_desc"),type:"herbivore",home:z(Ti("capybara")?"race_donkey_home":"race_capybara_home"),entity:z(Ti("capybara")?"race_donkey_entity":"race_capybara_entity"),traits:{gnawer:1,calm:1},solar:{red:z(Ti("capybara")?"race_donkey_solar_red":"race_capybara_solar_red"),hell:z(Ti("capybara")?"race_donkey_solar_hell":"race_capybara_solar_hell"),gas:z(Ti("capybara")?"race_donkey_solar_gas":"race_capybara_solar_gas"),gas_moon:z(Ti("capybara")?"race_donkey_solar_gas_moon":"race_capybara_solar_gas_moon"),dwarf:z(Ti("capybara")?"race_donkey_solar_dwarf":"race_capybara_solar_dwarf")},fanaticism:"calm",basic:()=>!0},kobold:{name:z("race_kobold"),desc:z("race_kobold_desc"),type:"small",home:z("race_kobold_home"),entity:z("race_kobold_entity"),traits:{pack_rat:1,paranoid:1},solar:{red:z("race_kobold_solar_red"),hell:z("race_kobold_solar_hell"),gas:z("race_kobold_solar_gas"),gas_moon:z("race_kobold_solar_gas_moon"),dwarf:z("race_kobold_solar_dwarf")},fanaticism:"pack_rat",basic:()=>!0},goblin:{name:z("race_goblin"),desc:z("race_goblin_desc"),type:"small",home:z("race_goblin_home"),entity:z("race_goblin_entity"),traits:{greedy:1,merchant:1},solar:{red:z("race_goblin_solar_red"),hell:z("race_goblin_solar_hell"),gas:z("race_goblin_solar_gas"),gas_moon:z("race_goblin_solar_gas_moon"),dwarf:z("race_goblin_solar_dwarf")},fanaticism:"merchant",basic:()=>!0},gnome:{name:z("race_gnome"),desc:z("race_gnome_desc"),type:"small",home:z("race_gnome_home"),entity:z("race_gnome_entity"),traits:{smart:1,puny:1},solar:{red:z("race_gnome_solar_red"),hell:z("race_gnome_solar_hell"),gas:z("race_gnome_solar_gas"),gas_moon:z("race_gnome_solar_gas_moon"),dwarf:z("race_gnome_solar_dwarf")},fanaticism:"smart",basic:()=>!0},ogre:{name:z("race_ogre"),desc:z("race_ogre_desc"),type:"giant",home:z("race_ogre_home"),entity:z("race_ogre_entity"),traits:{dumb:1,tough:1},solar:{red:z("race_ogre_solar_red"),hell:z("race_ogre_solar_hell"),gas:z("race_ogre_solar_gas"),gas_moon:z("race_ogre_solar_gas_moon"),dwarf:z("race_ogre_solar_dwarf")},fanaticism:"tough",basic:()=>!0},cyclops:{name:z("race_cyclops"),desc:z("race_cyclops_desc"),type:"giant",home:z("race_cyclops_home"),entity:z("race_cyclops_entity"),traits:{nearsighted:1,intelligent:1},solar:{red:z("race_cyclops_solar_red"),hell:z("race_cyclops_solar_hell"),gas:z("race_cyclops_solar_gas"),gas_moon:z("race_cyclops_solar_gas_moon"),dwarf:z("race_cyclops_solar_dwarf")},fanaticism:"intelligent",basic:()=>!0},troll:{name:z("race_troll"),desc:z("race_troll_desc"),type:"giant",home:z("race_troll_home"),entity:z("race_troll_entity"),traits:{regenerative:1,gluttony:1},solar:{red:z("race_troll_solar_red"),hell:z("race_troll_solar_hell"),gas:z("race_troll_solar_gas"),gas_moon:z("race_troll_solar_gas_moon"),dwarf:z("race_troll_solar_dwarf")},fanaticism:"regenerative",basic:()=>!0},tortoisan:{name:z("race_tortoisan"),desc:()=>z("race_tortoisan_desc",[t.race.hasOwnProperty("shell_color")?z(`color_${t.race.shell_color}`):z("color_green")]),type:"reptilian",home:z("race_tortoisan_home"),entity:z("race_tortoisan_entity"),traits:{slow:1,armored:1},solar:{red:z("race_tortoisan_solar_red"),hell:z("race_tortoisan_solar_hell"),gas:z("race_tortoisan_solar_gas"),gas_moon:z("race_tortoisan_solar_gas_moon"),dwarf:z("race_tortoisan_solar_dwarf")},fanaticism:"armored",basic:()=>!0},gecko:{name:z("race_gecko"),desc:z("race_gecko_desc"),type:"reptilian",home:z("race_gecko_home"),entity:z("race_gecko_entity"),traits:{optimistic:1,chameleon:1},solar:{red:z("race_gecko_solar_red"),hell:z("race_gecko_solar_hell"),gas:z("race_gecko_solar_gas"),gas_moon:z("race_gecko_solar_gas_moon"),dwarf:z("race_gecko_solar_dwarf")},fanaticism:"optimistic",basic:()=>!0},slitheryn:{name:z("race_slitheryn"),desc:z("race_slitheryn_desc"),type:"reptilian",home:z("race_slitheryn_home"),entity:z("race_slitheryn_entity"),traits:{slow_digestion:1,hard_of_hearing:1},solar:{red:z("race_slitheryn_solar_red"),hell:z("race_slitheryn_solar_hell"),gas:z("race_slitheryn_solar_gas"),gas_moon:z("race_slitheryn_solar_gas_moon"),dwarf:z("race_slitheryn_solar_dwarf")},fanaticism:"slow_digestion",basic:()=>!0},arraak:{name:z(Ti("arraak")?"race_turkey":"race_arraak"),desc:z(Ti("arraak")?"race_turkey_desc":"race_arraak_desc"),type:"avian",home:z(Ti("arraak")?"race_turkey_home":"race_arraak_home"),entity:z("race_arraak_entity"),traits:{resourceful:1,selenophobia:1},solar:{red:z(Ti("arraak")?"race_turkey_solar_red":"race_arraak_solar_red"),hell:z(Ti("arraak")?"race_turkey_solar_hell":"race_arraak_solar_hell"),gas:z(Ti("arraak")?"race_turkey_solar_gas":"race_arraak_solar_gas"),gas_moon:z(Ti("arraak")?"race_turkey_solar_gas_moon":"race_arraak_solar_gas_moon"),dwarf:z(Ti("arraak")?"race_turkey_solar_dwarf":"race_arraak_solar_dwarf")},fanaticism:"resourceful",basic:()=>!0},pterodacti:{name:z("race_pterodacti"),desc:z("race_pterodacti_desc"),type:"avian",home:z("race_pterodacti_home"),entity:z("race_pterodacti_entity"),traits:{leathery:1,pessimistic:1},solar:{red:z("race_pterodacti_solar_red"),hell:z("race_pterodacti_solar_hell"),gas:z("race_pterodacti_solar_gas"),gas_moon:z("race_pterodacti_solar_gas_moon"),dwarf:z("race_pterodacti_solar_dwarf")},fanaticism:"leathery",basic:()=>!0},dracnid:{name:z("race_dracnid"),desc:z("race_dracnid_desc"),type:"avian",home:z("race_dracnid_home"),entity:z("race_dracnid_entity"),traits:{hoarder:1,solitary:1},solar:{red:z("race_dracnid_solar_red"),hell:z("race_dracnid_solar_hell"),gas:z("race_dracnid_solar_gas"),gas_moon:z("race_dracnid_solar_gas_moon"),dwarf:z("race_dracnid_solar_dwarf")},fanaticism:"hoarder",basic:()=>!0},entish:{name:z(Ti("entish")?"race_spruce":"race_entish"),desc:z(Ti("entish")?"race_spruce_desc":"race_entish_desc"),type:"plant",home:z(Ti("entish")?"race_spruce_home":"race_entish_home"),entity:z(Ti("entish")?"race_spruce_entity":"race_entish_entity"),traits:{kindling_kindred:1,pyrophobia:1},solar:{red:z(Ti("entish")?"race_spruce_solar_red":"race_entish_solar_red"),hell:z(Ti("entish")?"race_spruce_solar_hell":"race_entish_solar_hell"),gas:z(Ti("entish")?"race_spruce_solar_gas":"race_entish_solar_gas"),gas_moon:z(Ti("entish")?"race_spruce_solar_gas_moon":"race_entish_solar_gas_moon"),dwarf:z(Ti("entish")?"race_spruce_solar_dwarf":"race_entish_solar_dwarf")},fanaticism:"kindling_kindred",basic:()=>!0},cacti:{name:z("race_cacti"),desc:z("race_cacti_desc"),type:"plant",home:z("race_cacti_home"),entity:z("race_cacti_entity"),traits:{hyper:1,skittish:1},solar:{red:z("race_cacti_solar_red"),hell:z("race_cacti_solar_hell"),gas:z("race_cacti_solar_gas"),gas_moon:z("race_cacti_solar_gas_moon"),dwarf:z("race_cacti_solar_dwarf")},fanaticism:"hyper",basic:()=>!0},pinguicula:{name:z("race_pinguicula"),desc:z("race_pinguicula_desc"),type:"plant",home:z("race_pinguicula_home"),entity:z("race_pinguicula_entity"),traits:{fragrant:1,sticky:1},solar:{red:z("race_pinguicula_solar_red"),hell:z("race_pinguicula_solar_hell"),gas:z("race_pinguicula_solar_gas"),gas_moon:z("race_pinguicula_solar_gas_moon"),dwarf:z("race_pinguicula_solar_dwarf")},fanaticism:"sticky",basic:()=>!0},sporgar:{name:z("race_sporgar"),desc:z("race_sporgar_desc"),type:"fungi",home:z("race_sporgar_home"),entity:z("race_sporgar_entity"),traits:{infectious:1,parasite:1},solar:{red:z("race_sporgar_solar_red"),hell:z("race_sporgar_solar_hell"),gas:z("race_sporgar_solar_gas"),gas_moon:z("race_sporgar_solar_gas_moon"),dwarf:z("race_sporgar_solar_dwarf")},fanaticism:"infectious",basic:()=>!1},shroomi:{name:z("race_shroomi"),desc:z("race_shroomi_desc"),type:"fungi",home:z("race_shroomi_home"),entity:z("race_shroomi_entity"),traits:{toxic:1,nyctophilia:1},solar:{red:z("race_shroomi_solar_red"),hell:z("race_shroomi_solar_hell"),gas:z("race_shroomi_solar_gas"),gas_moon:z("race_shroomi_solar_gas_moon"),dwarf:z("race_shroomi_solar_dwarf")},fanaticism:"toxic",basic:()=>!0},moldling:{name:z("race_moldling"),desc:z("race_moldling_desc"),type:"fungi",home:z("race_moldling_home"),entity:z("race_moldling_entity"),traits:{infiltrator:1,hibernator:1},solar:{red:z("race_moldling_solar_red"),hell:z("race_moldling_solar_hell"),gas:z("race_moldling_solar_gas"),gas_moon:z("race_moldling_solar_gas_moon"),dwarf:z("race_moldling_solar_dwarf")},fanaticism:"infiltrator",basic:()=>!0},mantis:{name:z("race_mantis"),desc:z("race_mantis_desc"),type:"insectoid",home:z("race_mantis_home"),entity:z("race_mantis_entity"),traits:{cannibalize:1,malnutrition:1},solar:{red:z("race_mantis_solar_red"),hell:z("race_mantis_solar_hell"),gas:z("race_mantis_solar_gas"),gas_moon:z("race_mantis_solar_gas_moon"),dwarf:z("race_mantis_solar_dwarf")},fanaticism:"cannibalize",basic:()=>!0},scorpid:{name:z("race_scorpid"),desc:z("race_scorpid_desc"),type:"insectoid",home:z("race_scorpid_home"),entity:z("race_scorpid_entity"),traits:{claws:1,atrophy:1},solar:{red:z("race_scorpid_solar_red"),hell:z("race_scorpid_solar_hell"),gas:z("race_scorpid_solar_gas"),gas_moon:z("race_scorpid_solar_gas_moon"),dwarf:z("race_scorpid_solar_dwarf")},fanaticism:"claws",basic:()=>!0},antid:{name:z("race_antid"),desc:z("race_antid_desc"),type:"insectoid",home:z("race_antid_home"),entity:z("race_antid_entity"),traits:{hivemind:1,tunneler:1},solar:{red:z("race_antid_solar_red"),hell:z("race_antid_solar_hell"),gas:z("race_antid_solar_gas"),gas_moon:z("race_antid_solar_gas_moon"),dwarf:z("race_antid_solar_dwarf")},fanaticism:"hivemind",basic:()=>!0},sharkin:{name:z("race_sharkin"),desc:z("race_sharkin_desc"),type:"aquatic",home:z("race_sharkin_home"),entity:z("race_sharkin_entity"),traits:{blood_thirst:1,apex_predator:1},solar:{red:z("race_sharkin_solar_red"),hell:z("race_sharkin_solar_hell"),gas:z("race_sharkin_solar_gas"),gas_moon:z("race_sharkin_solar_gas_moon"),dwarf:z("race_sharkin_solar_dwarf")},fanaticism:"blood_thirst",basic:()=>!!["oceanic","swamp"].includes(t.city.biome)},octigoran:{name:z("race_octigoran"),desc:z("race_octigoran_desc"),type:"aquatic",home:z("race_octigoran_home"),entity:z("race_octigoran_entity"),traits:{invertebrate:1,suction_grip:1},solar:{red:z("race_octigoran_solar_red"),hell:z("race_octigoran_solar_hell"),gas:z("race_octigoran_solar_gas"),gas_moon:z("race_octigoran_solar_gas_moon"),dwarf:z("race_octigoran_solar_dwarf")},fanaticism:"suction_grip",basic:()=>!!["oceanic","swamp"].includes(t.city.biome)},dryad:{name:z("race_dryad"),desc:z("race_dryad_desc"),type:"fey",home:z("race_dryad_home"),entity:z("race_dryad_entity"),traits:{befuddle:1,environmentalist:1,kindling_kindred:1},solar:{red:z("race_dryad_solar_red"),hell:z("race_dryad_solar_hell"),gas:z("race_dryad_solar_gas"),gas_moon:z("race_dryad_solar_gas_moon"),dwarf:z("race_dryad_solar_dwarf")},fanaticism:"befuddle",basic:()=>!!["forest","swamp","taiga"].includes(t.city.biome)},satyr:{name:z("race_satyr"),desc:z("race_satyr_desc"),type:"fey",home:z("race_satyr_home"),entity:z("race_satyr_entity"),traits:{unorganized:1,musical:1},solar:{red:z("race_satyr_solar_red"),hell:z("race_satyr_solar_hell"),gas:z("race_satyr_solar_gas"),gas_moon:z("race_satyr_solar_gas_moon"),dwarf:z("race_satyr_solar_dwarf")},fanaticism:"musical",basic:()=>!!["forest","swamp","taiga"].includes(t.city.biome)},phoenix:{name:z("race_phoenix"),desc:z("race_phoenix_desc"),type:"heat",home:z("race_phoenix_home"),entity:z("race_phoenix_entity"),traits:{revive:1,slow_regen:1},solar:{red:z("race_phoenix_solar_red"),hell:z("race_phoenix_solar_hell"),gas:z("race_phoenix_solar_gas"),gas_moon:z("race_phoenix_solar_gas_moon"),dwarf:z("race_phoenix_solar_dwarf")},fanaticism:"revive",basic:()=>!!["volcanic","ashland"].includes(t.city.biome)},salamander:{name:z("race_salamander"),desc:z("race_salamander_desc"),type:"heat",home:z("race_salamander_home"),entity:z("race_salamander_entity"),traits:{forge:1,autoignition:1},solar:{red:z("race_salamander_solar_red"),hell:z("race_salamander_solar_hell"),gas:z("race_salamander_solar_gas"),gas_moon:z("race_salamander_solar_gas_moon"),dwarf:z("race_salamander_solar_dwarf")},fanaticism:"forge",basic:()=>!!["volcanic","ashland"].includes(t.city.biome)},yeti:{name:z(Ti("yeti")?"race_snowman":"race_yeti"),desc:z(Ti("yeti")?"race_snowman_desc":"race_yeti_desc"),type:"polar",home:z(Ti("yeti")?"race_snowman_home":"race_yeti_home"),entity:z(Ti("yeti")?"race_snowman_entity":"race_yeti_entity"),traits:{blurry:1,snowy:1},solar:{red:z(Ti("yeti")?"race_snowman_solar_red":"race_yeti_solar_red"),hell:z(Ti("yeti")?"race_snowman_solar_hell":"race_yeti_solar_hell"),gas:z(Ti("yeti")?"race_snowman_solar_gas":"race_yeti_solar_gas"),gas_moon:z(Ti("yeti")?"race_snowman_solar_gas_moon":"race_yeti_solar_gas_moon"),dwarf:z(Ti("yeti")?"race_snowman_solar_dwarf":"race_yeti_solar_dwarf")},fanaticism:"blurry",basic:()=>!!["tundra","taiga"].includes(t.city.biome)},wendigo:{name:z(Ti("wendigo")?"race_krampus":"race_wendigo"),desc:z(Ti("wendigo")?"race_krampus_desc":"race_wendigo_desc"),type:"polar",home:z(Ti("wendigo")?"race_krampus_home":"race_wendigo_home"),entity:z(Ti("wendigo")?"race_krampus_entity":"race_wendigo_entity"),traits:{ravenous:1,ghostly:1,soul_eater:1},solar:{red:z(Ti("wendigo")?"race_krampus_solar_red":"race_wendigo_solar_red"),hell:z(Ti("wendigo")?"race_krampus_solar_hell":"race_wendigo_solar_hell"),gas:z(Ti("wendigo")?"race_krampus_solar_gas":"race_wendigo_solar_gas"),gas_moon:z(Ti("wendigo")?"race_krampus_solar_gas_moon":"race_wendigo_solar_gas_moon"),dwarf:z(Ti("wendigo")?"race_krampus_solar_dwarf":"race_wendigo_solar_dwarf")},fanaticism:"ghostly",basic:()=>!!["tundra","taiga"].includes(t.city.biome)},tuskin:{name:z("race_tuskin"),desc:z("race_tuskin_desc"),type:"sand",home:z("race_tuskin_home"),entity:z("race_tuskin_entity"),traits:{lawless:1,mistrustful:1},solar:{red:z("race_tuskin_solar_red"),hell:z("race_tuskin_solar_hell"),gas:z("race_tuskin_solar_gas"),gas_moon:z("race_tuskin_solar_gas_moon"),dwarf:z("race_tuskin_solar_dwarf")},fanaticism:"lawless",basic:()=>!!["desert","ashland"].includes(t.city.biome)},kamel:{name:z("race_kamel"),desc:z("race_kamel_desc"),type:"sand",home:z("race_kamel_home"),entity:z("race_kamel_entity"),traits:{humpback:1,thalassophobia:1},solar:{red:z("race_kamel_solar_red"),hell:z("race_kamel_solar_hell"),gas:z("race_kamel_solar_gas"),gas_moon:z("race_kamel_solar_gas_moon"),dwarf:z("race_kamel_solar_dwarf")},fanaticism:"humpback",basic:()=>!!["desert","ashland"].includes(t.city.biome)},balorg:{name:z("race_balorg"),desc:z("race_balorg_desc"),type:"demonic",home:z("race_balorg_home"),entity:z("race_balorg_entity"),traits:{fiery:1,terrifying:1,slaver:1},solar:{red:z("race_balorg_solar_red"),hell:z("race_balorg_solar_hell"),gas:z("race_balorg_solar_gas"),gas_moon:z("race_balorg_solar_gas_moon"),dwarf:z("race_balorg_solar_dwarf")},fanaticism:"fiery",basic:()=>"hellscape"===t.city.biome},imp:{name:z("race_imp"),desc:z("race_imp_desc"),type:"demonic",home:z("race_imp_home"),entity:z("race_imp_entity"),traits:{compact:1,conniving:1,pathetic:1},solar:{red:z("race_imp_solar_red"),hell:z("race_imp_solar_hell"),gas:z("race_imp_solar_gas"),gas_moon:z("race_imp_solar_gas_moon"),dwarf:z("race_imp_solar_dwarf")},fanaticism:"conniving",basic:()=>"hellscape"===t.city.biome},seraph:{name:z(Ti("seraph")?"race_cherub":"race_seraph"),desc:z(Ti("seraph")?"race_cherub_desc":"race_seraph_desc"),type:"angelic",home:z(Ti("seraph")?"race_cherub_home":"race_seraph_home"),entity:z(Ti("seraph")?"race_cherub_entity":"race_seraph_entity"),traits:{unified:1,spiritual:1,truthful:1},solar:{red:z(Ti("seraph")?"race_cherub_solar_red":"race_seraph_solar_red"),hell:z(Ti("seraph")?"race_cherub_solar_hell":"race_seraph_solar_hell"),gas:z(Ti("seraph")?"race_cherub_solar_gas":"race_seraph_solar_gas"),gas_moon:z(Ti("seraph")?"race_cherub_solar_gas_moon":"race_seraph_solar_gas_moon"),dwarf:z(Ti("seraph")?"race_cherub_solar_dwarf":"race_seraph_solar_dwarf")},fanaticism:"spiritual",basic:()=>"eden"===t.city.biome},unicorn:{name:z("race_unicorn"),desc:z("race_unicorn_desc"),type:"angelic",home:z("race_unicorn_home"),entity:z("race_unicorn_entity"),traits:{rainbow:1,magnificent:1,noble:1},solar:{red:z("race_unicorn_solar_red"),hell:z("race_unicorn_solar_hell"),gas:z("race_unicorn_solar_gas"),gas_moon:z("race_unicorn_solar_gas_moon"),dwarf:z("race_unicorn_solar_dwarf")},fanaticism:"magnificent",basic:()=>"eden"===t.city.biome},synth:{name:z("race_synth"),desc(){let e=t.race.hasOwnProperty("srace")?t.race.srace:"human";return z("race_synth_desc",[Ki[e].name])},type:"synthetic",home:z("race_synth_home"),entity:z("race_synth_entity"),traits:{imitation:1,emotionless:1,logical:1},solar:{red:z("race_synth_solar_red"),hell:z("race_synth_solar_hell"),gas:z("race_synth_solar_gas"),gas_moon:z("race_synth_solar_gas_moon"),dwarf:z("race_synth_solar_dwarf")},fanaticism:"logical",basic:()=>!1},nano:{name:z("race_nano"),desc:z("race_nano_desc"),type:"synthetic",home:z("race_nano_home"),entity:z("race_nano_entity"),traits:{deconstructor:1,linked:1,shapeshifter:1},solar:{red:z("race_nano_solar_red"),hell:z("race_nano_solar_hell"),gas:z("race_nano_solar_gas"),gas_moon:z("race_nano_solar_gas_moon"),dwarf:z("race_nano_solar_dwarf")},fanaticism:"shapeshifter",basic:()=>!1},ghast:{name:z("race_ghast"),desc:z("race_ghast_desc"),type:"eldritch",home:z("race_ghast_home"),entity:z("race_ghast_entity"),traits:{dark_dweller:1,swift:1,anthropophagite:1},solar:{red:z("race_ghast_solar_red"),hell:z("race_ghast_solar_hell"),gas:z("race_ghast_solar_gas"),gas_moon:z("race_ghast_solar_gas_moon"),dwarf:z("race_ghast_solar_dwarf")},fanaticism:"swift",basic:()=>!1},shoggoth:{name:z("race_shoggoth"),desc:z("race_shoggoth_desc"),type:"eldritch",home:z("race_shoggoth_home"),entity:z("race_shoggoth_entity"),traits:{living_tool:1,bloated:1},solar:{red:z("race_shoggoth_solar_red"),hell:z("race_shoggoth_solar_hell"),gas:z("race_shoggoth_solar_gas"),gas_moon:z("race_shoggoth_solar_gas_moon"),dwarf:z("race_shoggoth_solar_dwarf")},fanaticism:"living_tool",basic:()=>!1},junker:{name:Ti("junker")?z("race_ghoul"):z("race_junker"),desc:Ti("junker")?z("race_ghoul_desc"):z("race_junker_desc"),type:t.race.hasOwnProperty("jtype")?t.race.jtype:"humanoid",home:Ti("junker")?z("race_ghoul_home"):z("race_junker_home"),entity:Ti("junker")?z("race_ghoul_entity"):z("race_junker_entity"),traits:{diverse:1,arrogant:1,angry:1,lazy:1,paranoid:1,greedy:1,puny:1,dumb:1,nearsighted:1,gluttony:1,slow:1,hard_of_hearing:1,pessimistic:1,solitary:1,pyrophobia:1,skittish:1,nyctophilia:1,frail:1,atrophy:1,invertebrate:1,pathetic:1,hibernator:1,freespirit:1,heavy:1,gnawer:1,hooved:1},solar:{red:Ti("junker")?z("race_ghoul_solar_red"):z("race_junker_solar_red"),hell:Ti("junker")?z("race_ghoul_solar_hell"):z("race_junker_solar_hell"),gas:Ti("junker")?z("race_ghoul_solar_gas"):z("race_junker_solar_gas"),gas_moon:Ti("junker")?z("race_ghoul_solar_gas_moon"):z("race_junker_solar_gas_moon"),dwarf:Ti("junker")?z("race_ghoul_solar_dwarf"):z("race_junker_solar_dwarf")},fanaticism:"none",basic:()=>!1},sludge:{name:z("race_sludge"),desc:z("race_sludge_desc"),type:t.race.hasOwnProperty("jtype")?t.race.jtype:"humanoid",home:z("race_sludge_home"),entity:z("race_sludge_entity"),traits:{ooze:.25,diverse:.25,arrogant:.25,angry:.25,lazy:.25,hooved:.25,freespirit:.25,heavy:.25,gnawer:.25,paranoid:.25,greedy:.25,puny:.25,dumb:.25,nearsighted:.25,gluttony:.25,slow:.25,hard_of_hearing:.25,selenophobia:.25,pessimistic:.25,solitary:.25,pyrophobia:.25,skittish:.25,fragrant:.25,nyctophilia:.25,hibernator:.25,frail:.25,atrophy:.25,invertebrate:.25,unorganized:.25,slow_regen:.25,autoignition:.25,snowy:.25,mistrustful:.25,thalassophobia:.25,pathetic:.25,truthful:.25},solar:{red:z("race_sludge_solar_red"),hell:z("race_sludge_solar_hell"),gas:z("race_sludge_solar_gas"),gas_moon:z("race_sludge_solar_gas_moon"),dwarf:z("race_sludge_solar_dwarf")},fanaticism:"ooze",basic:()=>!1},custom:function(){if(t.hasOwnProperty("custom")&&t.custom.hasOwnProperty("race0")){let e={};for(let a=0;aEi[a].val&&(a=t.custom.race0.traits[e]);return{name:t.custom.race0.name,desc:t.custom.race0.desc,type:t.custom.race0.genus,home:t.custom.race0.home,entity:t.custom.race0.entity,traits:e,solar:{red:t.custom.race0.red,hell:t.custom.race0.hell,gas:t.custom.race0.gas,gas_moon:t.custom.race0.gas_moon,dwarf:t.custom.race0.dwarf},fanaticism:a,basic:()=>!1}}return{}}()},Di={organism:{},humanoid:{},carnivore:{},herbivore:{},omnivore:{},small:{},giant:{},reptilian:{},avian:{},insectoid:{},plant:{},fungi:{},aquatic:{},fey:{},heat:{},polar:{},sand:{},demonic:{},angelic:{},synthetic:{},eldritch:{}};function Bi(e,a){let r=1,i=K("theorist",1);!i||"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1-i/100);let s=K("inspirational",0);!s||"farmer"!==a&&"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1+s/100);let n=K("dirty_jobs",2);if(n&&"miner"===a&&(r*=1+n/100),t.race.rejuvenated&&["lumberjack","miner","factory"].includes(a)&&(r*=1.1),"lumberjack"===a&&t.race.evil&&!t.race.soul_eater&&(t.race.living_tool?r*=1+Ei.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.3*t.tech.science:0):r*=1+.4*(t.tech.reclaimer-1)),!t.race.powered||"factory"!==a&&"miner"!==a&&"lumberjack"!==a||(r*=1+Ei.powered.vars()[1]/100),t.race.artifical&&"science"===a&&(r*=1+Ei.artifical.vars()[0]/100),t.race.hivemind&&"farmer"!==a&&!t.race.lone_survivor){let i=Ei.hivemind.vars()[0],s=.05;t.race.high_pop&&"army"!==a&&"hellArmy"!==a&&(i*=Ei.high_pop.vars()[0],s=.5/(Ei.hivemind.vars()[0]*Ei.high_pop.vars()[0])),r*=e<=i?e*s+(1-i*s):1-("army"===a||"hellArmy"===a?.99:t.race.high_pop?.985:.98)**(e-i)+1}let c=ts("antid");if(c>0&&(r*=1+(1-("army"===a||"hellArmy"===a?.99:t.race.high_pop?.985:.98)**(e*c/4))/2),t.race.cold_blooded&&"army"!==a&&"hellArmy"!==a&&"factory"!==a&&"science"!==a){switch(t.city.calendar.temp){case 0:r*=1-Ei.cold_blooded.vars()[0]/100;break;case 2:r*=1+Ei.cold_blooded.vars()[1]/100;break;default:r*=1}switch(t.city.calendar.weather){case 0:r*=1-Ei.cold_blooded.vars()[0]/100;break;case 2:r*=1+Ei.cold_blooded.vars()[1]/100;break;default:r*=1}}t.race.cannibalize&&t.city.s_alter&&t.city.s_alter.count>0&&("miner"===a&&t.city.s_alter.mine>0&&(r*=1+Ei.cannibalize.vars()[0]/100),"lumberjack"===a&&t.city.s_alter.harvest>0&&(r*=1+Ei.cannibalize.vars()[0]/100),("army"===a||"hellArmy"===a)&&t.city.s_alter.rage>0&&(r*=1+Ei.cannibalize.vars()[0]/100),"science"===a&&t.city.s_alter.mind>0&&(r*=1+Ei.cannibalize.vars()[0]/100));let o=ts("mantis");o>0&&("miner"===a&&(r*=1+Ei.cannibalize.vars(1)[0]/100*o),"lumberjack"===a&&(r*=1+Ei.cannibalize.vars(1)[0]/100*o),"army"!==a&&"hellArmy"!==a||(r*=1+Ei.cannibalize.vars(1)[0]/100*o),"science"===a&&(r*=1+Ei.cannibalize.vars(1)[0]/100*o)),!t.race.humpback||"miner"!==a&&"lumberjack"!==a||(r*=1+Ei.humpback.vars()[0]/100);let l=ts("kamel");l>0&&("miner"===a||"lumberjack"===a)&&(r*=1+Ei.humpback.vars(1)[0]/100*l),t.city.ptrait.includes("magnetic")&&"miner"===a&&(r*=ss.magnetic.vars()[2]),!t.race.weak||"miner"!==a&&"lumberjack"!==a||(r*=1-Ei.weak.vars()[0]/100),t.race.hydrophilic&&0===t.city.calendar.weather&&t.city.calendar.temp>0&&"factory"!==a&&(r*=.75),t.race.toxic&&"factory"===a&&(r*=1+Ei.toxic.vars()[2]/100);let _=ts("shroomi");if(_>0&&"factory"===a&&(r*=1+Ei.toxic.vars(1)[2]/100*_),t.race.hardy&&"factory"===a&&(r*=1+Ei.hardy.vars()[0]*t.race.hardy/100),t.race.analytical&&"science"===a&&(r*=1+Ei.analytical.vars()[0]*t.race.analytical/100),t.race.ooze&&(r*=1-Ei.ooze.vars()[0]/100),"democracy"===t.civic.govern.type&&(r*=1-Y.democracy()[1]/100),!t.tech.cyber_worker||"lumberjack"!==a&&"miner"!==a||(r*=1.25),"hunting"===a){t.race.tracker&&(r*=1+Ei.tracker.vars()[0]/100);let e=ts("wolven");e>0&&(r*=1+Ei.tracker.vars(1)[0]/100*e),t.race.beast&&(r*=1+(1===t.city.calendar.wind?Ei.beast.vars()[1]:Ei.beast.vars()[0])/100),t.race.apex_predator&&(r*=1+Ei.apex_predator.vars()[1]/100);let a=ts("sharkin");a>0&&(r*=1+Ei.apex_predator.vars(1)[1]/100*a),t.race.fiery&&(r*=1+Ei.fiery.vars()[1]/100);let i=ts("balorg");i>0&&(r*=1+Ei.fiery.vars(1)[1]/100*i),t.race.fragrant&&(r*=1-Ei.fragrant.vars()[0]/100),t.city.ptrait.includes("rage")&&(r*=ss.rage.vars()[1]),t.race.cunning&&(r*=1+Ei.cunning.vars()[0]*t.race.cunning/100),"savanna"===t.city.biome&&(r*=is.savanna.vars()[1]),t.race.dark_dweller&&2===t.city.calendar.weather&&(r*=1-Ei.dark_dweller.vars()[0]/100)}if("magic"===t.race.universe&&(r*="science"===a?.6:"army"===a||"hellArmy"===a?.75:.8,t.race.witch_hunter&&(r*=.75),t.race.hasOwnProperty("casting")&&t.race.casting["hellArmy"===a?"army":a])){let e=t.race.casting["hellArmy"===a?"army":a];t.race.witch_hunter?r*=1+e/(e+75)*2.5:r*=1+e/(e+75)}return t.race.living_tool&&"miner"===a&&(r*=1+Ei.living_tool.vars()[0]*(t.tech.science&&t.tech.science>0?.12*t.tech.science:0)),t.race.high_pop&&(r=ke(r)),r}function Gi(e){let a=[];Object.keys(Ei).forEach((function(e){"minor"!==Ei[e].type||t.race[e]||a.push(e)})),0===a.length&&Object.keys(Ei).forEach((function(e){"minor"===Ei[e].type&&a.push(e)}));let r=a[Math.floor(m(0,a.length))];return t.race[r]?t.race[r]+=e:t.race[r]=e,r}function Ni(e,a,r){t.race.purgatory[e].hasOwnProperty(a)?(t[e][a]=t.race.purgatory[e][a],delete t.race.purgatory[e][a]):r&&(t[e][a]=r)}function Ri(e,a,r,i){t.race.purgatory[e].hasOwnProperty(a)?(t[e][a]=t.race.purgatory[e][a],delete t.race.purgatory[e][a]):t.race.purgatory[e].hasOwnProperty(r)?(t[e][a]=t.race.purgatory[e][r],delete t.race.purgatory[e][r]):i&&(t[e][a]=i)}function Hi(e,a){t[e].hasOwnProperty(a)&&(t.race.purgatory[e][a]=t[e][a],delete t[e][a])}function Ui(e,a){if(t.race.purgatory[e].hasOwnProperty(a))return t.race.purgatory[e][a]}function Vi(){Wi("Lumber"),Wi("Plywood"),ms(["city-graveyard","city-lumber_yard","city-sawmill"]),gs(["reclaimer","axe","saw"]),Hi("city","sawmill"),Hi("city","graveyard"),Hi("city","lumber_yard"),Hi("tech","axe"),Hi("tech","reclaimer"),Hi("tech","saw"),t.civic.lumberjack.display=!1,t.civic.lumberjack.workers=0,"lumberjack"===t.civic.d_job&&(t.civic.d_job=t.race.carnivore||t.race.soul_eater?"hunter":"unemployed"),t.race.casting&&(t.race.casting.total-=t.race.casting.lumberjack,t.race.casting.lumberjack=0,ki()),t.city.s_alter&&(t.city.s_alter.harvest=0)}function Wi(e){t.resource[e].display=!1,t.race.alchemy&&t.race.alchemy.hasOwnProperty(e)&&(t.resource.Mana.diff+=t.race.alchemy[e],t.race.alchemy[e]=0),t.interstellar.mass_ejector&&t.interstellar.mass_ejector.hasOwnProperty(e)&&(t.interstellar.mass_ejector.total-=t.interstellar.mass_ejector[e],t.interstellar.mass_ejector[e]=0),t.city.nanite_factory&&t.city.nanite_factory.hasOwnProperty(e)&&(t.city.nanite_factory[e]=0),t.portal.transport&&t.portal.transport.cargo.hasOwnProperty(e)&&(t.portal.transport.cargo.used-=t.portal.transport.cargo[e],t.portal.transport.cargo[e]=0),t.tech.foundry&&t.city.foundry.hasOwnProperty(e)&&(t.civic.craftsman.workers-=t.city.foundry[e],t.city.foundry.crafting-=t.city.foundry[e],t.city.foundry[e]=0,sa()),t.resource[e].hasOwnProperty("trade")&&(t.city.market.trade-=Math.abs(t.resource[e].trade),t.resource[e].trade=0),t.resource.Crates.amount+=t.resource[e].crates,t.resource[e].crates=0,t.resource.Containers.amount+=t.resource[e].containers,t.resource[e].containers=0}function Qi(){let e=Ur(Mr.tech.agriculture),a=Ur(Mr.tech.smokehouse),r=Ur(Mr.tech.reclaimer)||Ur(Mr.tech.stone_axe),s=Ur(Mr.tech.alt_lodge),n=Ur(Mr.tech.wind_plant),c=[],o=[];if(!t.race.artifical){if(["agriculture","farm","hunting","s_lodge","wind_plant","compost","soul_eater"].forEach((function(e){Hi("tech",e)})),["silo","farm","mill","windmill","smokehouse","lodge","compost","soul_well"].forEach((function(e){Hi("city",e)})),s){Ni("tech","s_lodge");let e=Ui("tech","farm")>=1||Ui("tech","hunting")>=2?1:0;e>0&&(!t.tech.s_lodge||t.tech.s_lodge=1&&Ri("city","lodge","farm",{count:0})}if(a){Ni("tech","hunting");let e=Ui("tech","farm")>=1||Ui("tech","s_lodge")>=1?2:Ui("tech","agriculture")>=3?1:0;e>0&&(!t.tech.hunting||t.tech.hunting=1&&Ri("city","smokehouse","silo",{count:0}),t.tech.hunting>=2&&!s&&Ri("city","lodge","farm",{count:0})}else o.push("hunting"),c.push("city-smokehouse"),s||o.push("city-lodge");if(e){Ni("tech","farm");let e=Ui("tech","hunting")>=2||Ui("tech","s_lodge")>=1?1:0;e>0&&(!t.tech.farm||t.tech.farm=1?3:Ui("tech","s_lodge")>=1?1:0;a>0&&(!t.tech.agriculture||t.tech.agriculture=1&&Ri("city","farm","lodge",{count:0}),t.tech.agriculture>=3&&Ri("city","silo","smokehouse",{count:0}),t.tech.agriculture>=4&&!n&&Ri("city","mill","windmill",{count:0,on:0})}else o.push("agriculture","farm"),c.push("city-farm","city-silo","city-mill");t.race.soul_eater?(Ni("tech","soul_eater"),Ni("city","soul_well")):(c.push("city-soul_well"),o.push("soul_eater")),t.race.detritivore?(Ni("tech","compost"),Ni("city","compost")):(o.push("compost"),c.push("city-compost")),n?(Ni("tech","wind_plant"),t.tech.wind_plant>=1&&Ri("city","windmill","mill",{count:0,on:0})):(o.push("wind_plant"),c.push("city-windmill"),delete i[z("city_mill_title2")])}let l=[],_=[];!t.race.orbit_decayed&&e&&t.tech.agriculture>=1&&t.city.farm.count>0?l.push("farmer"):_.push("farmer"),t.race.carnivore&&!t.race.herbivore||t.race.soul_eater||t.race.unfathomable?(l.push("hunter"),_.push("unemployed")):(_.push("hunter"),l.push("unemployed")),!t.race.orbit_decayed&&r?l.push("lumberjack"):_.push("lumberjack"),l.forEach((function(e){t.civic[e].display||(t.civic[e].workers=0,t.civic[e].display=!0)})),_.forEach((function(e){t.civic[e].display&&(t.civic.d_job===e&&(t.civic.d_job=l[0]),t.civic[l[0]].workers+=t.civic[e].workers,t.civic[e].workers=0,t.civic[e].display=!1)})),t.race.casting&&(e||(t.race.casting.total-=t.race.casting.farmer,t.race.casting.farmer=0),ki()),ms(c),gs(o),Na("Food")}function Ji(a){switch(a){case"high_pop":t.resource[t.race.species].amount=Math.round(t.resource[t.race.species].amount*Ei.high_pop.vars()[0]),t.civic.hasOwnProperty("garrison")&&(t.civic.garrison.workers=Math.round(t.civic.garrison.workers*Ei.high_pop.vars()[0]));break;case"kindling_kindred":if(t.race.smoldering)break;Vi();break;case"smoldering":if(t.resource.Chrysotile.display=!0,t.race.kindling_kindred)break;Vi();break;case"forge":ki();break;case"soul_eater":aa("lumberjack");case"detritivore":case"carnivore":case"herbivore":Qi();break;case"unfathomable":for(Qi(),t.city.hasOwnProperty("surfaceDwellers")||(t.city.surfaceDwellers=[]);t.city.surfaceDwellers.lengthEi.unfathomable.vars()[0]&&(t.city.surfaceDwellers.length=Ei.unfathomable.vars()[0]),t.race.psychic&&cs();break;case"flier":Na("Stone"),Na("Brick"),t.resource.Cement.display=!1,t.civic.cement_worker.display=!1,t.civic.cement_worker.workers=0,Hi("tech","cement"),Hi("city","cement_plant");break;case"sappy":"quarry_worker"===t.civic.d_job&&(t.civic.d_job="unemployed"),t.civic.quarry_worker.display=!1,t.civic.quarry_worker.workers=0,Na("Stone"),Hi("tech","hammer"),Hi("city","rock_quarry");break;case"apex_predator":gs(["armor"]),Hi("tech","armor");break;case"environmentalist":delete i[z("city_coal_power")],delete i[z("city_mana_engine")],delete i[z("city_oil_power")];break;case"terrifying":Object.keys(t.resource).forEach((function(e){t.resource[e].hasOwnProperty("trade")&&(t.resource[e].trade=0)})),t.settings.showMarket=!1,0===t.settings.marketTabs&&(t.settings.marketTabs=1),ms(["city-trade"]),gs(["trade"]),Hi("tech","trade"),Hi("city","trade");break;case"slaver":Ni("tech","slaves"),t.tech.slaves>=1&&(Ni("city","slave_pen",{count:0,slaves:0}),t.city.slave_pen.count>0&&!t.race.orbit_decayed&&(t.resource.Slave.display=!0));break;case"cannibalize":Ni("tech","sacrifice"),t.tech.mining&&(t.city.s_alter={count:0,rage:0,mind:0,regen:0,mine:0,harvest:0});break;case"magnificent":t.tech.theology>=2&&Ni("city","shrine",{count:0,morale:0,metal:0,know:0,tax:0});break;case"unified":t.tech.world_control=1,t.tech.unify=2,Ss($("#garrison")),Ss($("#c_garrison")),he($("#garrison"),!0),he($("#c_garrison"),!1);for(let e=0;e<3;e++){if(t.civic.foreign[`gov${e}`].occ){let a=ta("federation"===t.civic.govern.type?15:20);t.civic.garrison.max+=a,t.civic.garrison.workers+=a,t.civic.foreign[`gov${e}`].occ=!1}t.civic.foreign[`gov${e}`].buy=!1,t.civic.foreign[`gov${e}`].anx=!1,t.civic.foreign[`gov${e}`].sab=0,t.civic.foreign[`gov${e}`].act="none"}D("spy"),D("spyop");break;case"noble":t.civic.taxes.tax_rate<10?t.civic.taxes.tax_rate=10:t.civic.taxes.tax_rate>20&&(t.civic.taxes.tax_rate=20);break;case"toxic":"troll"===t.race.species&&t.tech.science&&t.tech.science>=8&&qn("godwin");break;case"thalassophobia":ms(["city-wharf"]),gs(["wharf"]),Hi("city","wharf");break;case"hooved":t.resource.Horseshoe.display=!0,t.race.hasOwnProperty("shoecnt")||(t.race.shoecnt=0);break;case"slow":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w?(ds("stop"),ds("start")):window.location.reload();case"hyper":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w?(ds("stop"),ds("start")):window.location.reload();case"calm":t.tech.primitive>=3&&(Ni("city","meditation",{count:0}),t.race.orbit_decayed||(t.resource.Zen.display=!0));break;case"blood_thirst":t.race.blood_thirst_count=1;break;case"deconstructor":t.resource.Nanite.display=!0,Ni("city","nanite_factory",{count:1,Lumber:0,Chrysotile:0,Stone:0,Crystal:0,Furs:0,Copper:0,Iron:0,Aluminium:0,Cement:0,Coal:0,Oil:0,Uranium:0,Steel:0,Titanium:0,Alloy:0,Polymer:0,Iridium:0,Helium_3:0,Water:0,Deuterium:0,Neutronium:0,Adamantite:0,Bolognium:0,Orichalcum:0});break;case"shapeshifter":Yi(!1,!0);break;case"imitation":Xi(!0);break;case"evil":Na("Lumber"),Na("Furs"),Na("Plywood");break;case"psychic":t.tech.psychic&&(t.resource.Energy.display=!0,t.settings.showPsychic=!0);break;case"ooze":t.tech.high_tech||"custom"===t.race.species||"sludge"===t.race.species||(t.race.gross_enabled=1),Ts(!0)}}function Zi(a,r){switch(a){case"high_pop":t.resource[t.race.species].amount=Math.round(t.resource[t.race.species].amount/Ei.high_pop.vars(r)[0]),t.civic.hasOwnProperty("garrison")&&(t.civic.garrison.workers=Math.round(t.civic.garrison.workers/Ei.high_pop.vars(r)[0]));break;case"kindling_kindred":if(t.race.smoldering)break;t.resource.Lumber.display=!0,t.tech.foundry&&(t.resource.Plywood.display=!0),t.race.casting&&ki(),Ni("city","sawmill"),Ni("city","graveyard"),Ni("city","lumber_yard"),Ni("tech","axe"),Ni("tech","reclaimer"),Ni("tech","saw"),!t.tech.axe&&!t.tech.reclaimer||t.race.orbit_decayed||(t.civic.lumberjack.display=!0);break;case"smoldering":if(Wi("Chrysotile"),t.race.kindling_kindred)break;t.resource.Lumber.display=!0,t.tech.foundry&&(t.resource.Plywood.display=!0),t.race.casting&&ki(),Ni("city","sawmill"),Ni("city","graveyard"),Ni("city","lumber_yard"),Ni("tech","axe"),Ni("tech","reclaimer"),Ni("tech","saw"),!t.tech.axe&&!t.tech.reclaimer||t.race.orbit_decayed||(t.civic.lumberjack.display=!0);break;case"forge":ki();break;case"soul_eater":aa("lumberjack");case"detritivore":case"carnivore":case"herbivore":case"unfathomable":Qi(),t.race.psychic&&cs();break;case"flier":Na("Stone"),Na("Brick"),Ni("tech","cement"),t.tech.cement&&(Ni("city","cement_plant"),t.resource.Cement.display=!0,t.civic.cement_worker.display=!0);break;case"sappy":Na("Stone"),Ni("tech","hammer"),t.tech.mining>=1&&(Ni("city","rock_quarry",{count:0,asbestos:0}),(t.city.rock_quarry&&t.city.rock_quarry.count>0||t.race.lone_survivor)&&(t.civic.quarry_worker.display=!0));break;case"apex_predator":Ni("tech","armor");break;case"environmentalist":delete i[z("city_hydro_power")],delete i[z("city_wind_power")];break;case"terrifying":t.settings.showMarket=!0,Ni("tech","trade"),Ni("city","trade");break;case"slaver":ms(["city-slave_pen"]),gs(["slaves"]),Hi("city","slave_pen"),Hi("tech","slaves"),t.resource.Slave.amount=0,t.resource.Slave.max=0,t.resource.Slave.display=!1,D("slave");break;case"cannibalize":ms(["city-s_alter"]),gs(["sacrifice"]),Hi("tech","sacrifice"),delete t.city.s_alter,D("sacrifice");break;case"magnificent":ms(["city-shrine"]),Hi("city","shrine");break;case"thalassophobia":t.tech.wharf&&Ni("city","wharf",{count:0});break;case"hooved":ms(["city-horseshoe","space-horseshoe"]),t.resource.Horseshoe.display=!1,D("horseshoe");break;case"slow":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w?(ds("stop"),ds("start")):window.location.reload();case"hyper":e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(t))),P.w?(ds("stop"),ds("start")):window.location.reload();case"calm":ms(["city-meditation"]),t.resource.Zen.display=!1,Hi("city","meditation");break;case"blood_thirst":delete t.race.blood_thirst_count;break;case"deconstructor":ms(["city-nanite_factory"]),t.resource.Nanite.display=!1,Hi("city","nanite_factory");break;case"shapeshifter":Ss($("#sshifter")),Yi();break;case"imitation":t.race.iTraits&&(Object.keys(t.race.iTraits).forEach((function(e){if("imitation"!==e)if(0===t.race.iTraits[e]){let a=t.race[e];delete t.race[e],Zi(e,a)}else t.race[e]=t.race.iTraits[e]})),delete t.race.iTraits);break;case"evil":Na("Lumber"),Na("Furs"),Na("Plywood");break;case"psychic":t.resource.Energy.display=!1,t.settings.showPsychic=!1;break;case"ooze":delete t.race.gross_enabled,Ts(!0)}}function Xi(e){if(t.race.imitation&&t.race.srace){t.race.iTraits||(t.race.iTraits={}),t.race.shapeshifter&&Yi(t.race.ss_genus===Ki[t.race.srace].type&&"none",!0);let a=[];if(Object.keys(Li[Ki[t.race.srace].type]).forEach((function(e){t.race[e]||a.push(e)})),"custom"===t.race.srace){let e=["evil","evil"];Object.keys(Ki[t.race.srace].traits).forEach((function(t){Ei[t].val>Ei[e[0]].val?e[0]=t:Ei[t].val=0?t.race[e]=Ei.shapeshifter.vars()[0]:t.race[e]=Ei.shapeshifter.vars()[1],Ji(e),r.push(e))})),t.race.ss_genus=e),a){Ss($("#sshifter")),t.race.ss_genus=t.race.hasOwnProperty("ss_genus")?t.race.ss_genus:"none";let e="";Object.keys(Li).forEach((function(a){"synthetic"!==a&&"eldritch"!==a&&a!==Ki[t.race.species].type&&(!t.race.imitation||a!==Ki[t.race.srace].type)&&t.stats.achieve[`genus_${a}`]&&t.stats.achieve[`genus_${a}`].l>0&&(e+=`{{ '${a}' | genus }}`)})),$("#sshifter").append(`${z("trait_shapeshifter_name")}: \n \n {{ 'none' | genus }}${e}\n `),Cs({el:"#sshifter",data:t.race,methods:{setShape(e){Yi(e)}},filters:{genus:e=>z(`genelab_genus_${e}`)}})}t.race.ss_traits=r}function es(e,a){if(a=a||{},t.race[e]&&!a.force)switch(t.race[e]){case.25:return t.race[e]=a.down?.25:.5,!a.down;case.5:return t.race[e]=a.down?.25:1,!0;case 1:return t.race[e]=a.down?.5:2,!0;case 2:return t.race[e]=a.down?1:3,!0;case 3:return t.race[e]=a.down?2:3,!!a.down}else if(a.set)return t.race[e]=a.set,!0;return!1}function ts(e){if(t.race.unfathomable&&t.city.surfaceDwellers&&t.city.surfaceDwellers.includes(e)&&t.city.captive_housing){let a=t.city.surfaceDwellers.indexOf(e),r=t.city.captive_housing[`race${a}`];if(r>100&&(r=100),r>t.civic.torturer.workers){let e=r-t.civic.torturer.workers;r-=Math.ceil(e/3)}return r/100*((t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0)/5)}return 0}function as(e,a){switch(e){case"name":{let e={hooved:rs(!1),promiscuous:t.race.artifical?z("trait_promiscuous_synth_name"):Ei.promiscuous.name};return a?e[a]?e[a]:Ei[a].name:e}case"desc":{let e={hooved:rs(!0),promiscuous:t.race.artifical?z("trait_promiscuous_synth"):Ei.promiscuous.desc};return a?e[a]?e[a]:Ei[a].desc:e}}}function rs(e){return t.race.sludge?z(e?"trait_hooved_slime":"trait_hooved_slime_name"):["cath","wolven","dracnid","seraph","cyclops","kobold","tuskin","sharkin"].includes(t.race.species)?z(e?`trait_hooved_${t.race.species}`:`trait_hooved_${t.race.species}_name`):["humanoid","avian","plant","fungi","reptilian","fey","synthetic"].includes(Ki[t.race.species].type)?z(e?`trait_hooved_${Ki[t.race.species].type}`:`trait_hooved_${Ki[t.race.species].type}_name`):e?Ei.hooved.desc:Ei.hooved.name}Object.keys(Di).forEach((function(e){let t="organism"===e?"humanoid":e;Di[e].solar={titan:z(`genus_${t}_solar_titan`),enceladus:z(`genus_${t}_solar_enceladus`),triton:z(`genus_${t}_solar_triton`),eris:z(`genus_${t}_solar_eris`)}}));const is={grassland:{label:z("biome_grassland_name"),desc:z("biome_grassland"),vars:()=>t.race.rejuvenated?[1.25]:[1.2],wiki:["%"]},oceanic:{label:z("biome_oceanic_name"),desc:z("biome_oceanic"),vars:()=>t.race.rejuvenated?[1.25,1.12,.92]:[1.12,1.06,.95],wiki:["%","%","%"]},forest:{label:z("biome_forest_name"),desc:z("biome_forest"),vars:()=>t.race.rejuvenated?[1.35]:[1.2],wiki:["%"]},desert:{label:z("biome_desert_name"),desc:z("biome_desert"),vars:()=>t.race.rejuvenated?[1.35,1.18,.6]:[1.2,1.1,.75],wiki:["%","%","%"]},volcanic:{label:z("biome_volcanic_name"),desc:z("biome_volcanic"),vars:()=>t.race.rejuvenated?[.8,1.25,1.15]:[.9,1.12,1.08],wiki:["%","%","%"]},tundra:{label:z("biome_tundra_name"),desc:z("biome_tundra"),vars:()=>t.race.rejuvenated?[1.5,.8]:[1.25,.9],wiki:["%","%"]},savanna:{label:z("biome_savanna_name"),desc:z("biome_savanna"),vars:()=>t.race.rejuvenated?[1.18,1.25,.75]:[1.1,1.18,.8],wiki:["%","%","%"]},swamp:{label:z("biome_swamp_name"),desc:z("biome_swamp"),vars:()=>t.race.rejuvenated?[1.6,1.35,1.15,.78]:[1.4,1.25,1.1,.88],wiki:["%","%","%","%"]},ashland:{label:z("biome_ashland_name"),desc:z("biome_ashland"),vars:()=>t.race.rejuvenated?[.55,1.35,1.2]:[.62,1.25,1.1],wiki:["%","%","%"]},taiga:{label:z("biome_taiga_name"),desc:z("biome_taiga"),vars:()=>t.race.rejuvenated?[1.2,1.65,.88]:[1.1,1.5,.92],wiki:["%","%","%"]},hellscape:{label:z("biome_hellscape_name"),desc:z("biome_hellscape"),vars:()=>t.race.rejuvenated?[.2]:[.25],wiki:["%"]},eden:{label:z("biome_eden_name"),desc:z("biome_eden")}},ss={toxic:{label:z("planet_toxic"),desc:z("planet_toxic_desc"),vars:()=>t.race.rejuvenated?[2,1.5]:[1,1.25],wiki:["A","-%"]},mellow:{label:z("planet_mellow"),desc:z("planet_mellow_desc"),vars:()=>t.race.rejuvenated?[2,3,.88]:[1.5,2,.9],wiki:["%","A","%"]},rage:{label:z("planet_rage"),desc:z("planet_rage_desc"),vars:()=>t.race.rejuvenated?[1.1,1.05,1]:[1.05,1.02,1],wiki:["%","%","A"]},stormy:{label:z("planet_stormy"),desc:z("planet_stormy_desc")},ozone:{label:z("planet_ozone"),desc:z("planet_ozone_desc"),vars:()=>t.race.rejuvenated?[.18]:[.25],wiki:["-A"]},magnetic:{label:z("planet_magnetic"),desc:z("planet_magnetic_desc"),vars:()=>t.race.rejuvenated?[2,150,.98]:[1,100,.985],wiki:["A","A","%"]},trashed:{label:z("planet_trashed"),desc:z("planet_trashed_desc"),vars:()=>t.race.rejuvenated?[.8,1.2]:[.75,1],wiki:["%","%"]},elliptical:{label:z("planet_elliptical"),desc:z("planet_elliptical_desc")},flare:{label:z("planet_flare"),desc:z("planet_flare_desc")},dense:{label:z("planet_dense"),desc:z("planet_dense_desc"),vars:()=>t.race.rejuvenated?[1.5,1.2,1.35]:[1.2,1,1.2],wiki:["%","A","%"]},unstable:{label:z("planet_unstable"),desc:z("planet_unstable_desc")},permafrost:{label:z("planet_permafrost"),desc:z("planet_permafrost_desc"),vars:()=>t.race.rejuvenated?[.7,125]:[.75,100],wiki:["%","A"]},retrograde:{label:z("planet_retrograde"),desc:z("planet_retrograde_desc")}};function ns(e){e=e||[];let t=Object.keys(Ki).filter((function(t){return Ki[t].basic()&&!e.includes(t)}));return t[en(t)]}function cs(){if(!t.settings.tabLoad&&(2!==t.settings.civTabs||6!==t.settings.govTabs))return;let e=$("#psychicPowers");Ss(e),t.race.psychic&&t.tech.psychic&&(function(e){let a=$('
                              ');e.append(a),a.append($(`
                              ${z("psychic_boost_title")}
                              `));let r=$("
                              ");a.append(r);let i="";if(Object.keys(Fa).forEach((function(e){t.resource[e].display&&(i+=`${t.resource[e].name}`)})),r.append(`
                              ${i}
                              `),a.append('
                              '),t.tech.psychic>=4){let e=$(`
                              ${z("psychic_channel")}
                              `),t=$('{{ c.boost }}'),r=$(`«`),i=$(`»`);e.append(r),e.append(t),e.append(i),a.append(e)}let s=t.tech.psychic>=5?60:75,n=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;Cs({el:"#psychicBoost",data:{b:t.race.psychicPowers.boost,c:t.tech.psychic>=4?t.race.psychicPowers.channel:{}},methods:{boostVal(){t.resource.Energy.amount>=s&&(t.resource.Energy.amount-=s,t.race.psychicPowers.boostTime=72*n)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.boost--}},filters:{boost:e=>z("psychic_boost_button",[t.resource[e]?t.resource[e].name:"N/A",s]),boostTime:()=>t.race.psychicPowers.boostTime>0?z("psychic_boost_time",[t.race.psychicPowers.boostTime]):""}});const c=document.getElementById("psyhscrolltarget");c.addEventListener("wheel",(e=>{e.preventDefault(),c.scrollLeft+=e.deltaY})),ls("psychicBoost",(function(){return z("psychic_boost_desc",[Ei.psychic.vars()[3]])}),{elm:"#psychicBoost > div > button"})}(e),function(e){let a=$('
                              ');e.append(a),a.append($(`
                              ${z("psychic_murder_title")}
                              `)),a.append('
                              ');let r=t.tech.psychic>=5?8:10;Cs({el:"#psychicKill",data:{},methods:{murder(){t.resource.Energy.amount>=r&&t.resource[t.race.species].amount>=1&&(t.resource.Energy.amount-=r,t.resource[t.race.species].amount--,t.stats.psykill++,t.race.anthropophagite&&$s("Food",1e4*Ei.anthropophagite.vars()[0]),10===t.stats.psykill&&cs())}},filters:{kill:()=>z("psychic_murder_button",[r])}}),ls("psychicKill",(function(){return z("psychic_murder_desc")}),{elm:"#psychicKill > div > button"})}(e),t.tech.psychic>=2&&function(e){let a=$('
                              ');if(e.append(a),a.append($(`
                              ${z("psychic_assault_title")}
                              `)),a.append('
                              '),t.tech.psychic>=4){let e=$(`
                              ${z("psychic_channel")}
                              `),t=$('{{ assault }}'),r=$(`«`),i=$(`»`);e.append(r),e.append(t),e.append(i),a.append(e)}let r=t.tech.psychic>=5?36:45,i=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;Cs({el:"#psychicAssault",data:t.tech.psychic>=4?t.race.psychicPowers.channel:{},methods:{boostVal(){t.resource.Energy.amount>=r&&(t.resource.Energy.amount-=r,t.race.psychicPowers.assaultTime=72*i)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.assault--}},filters:{boost:()=>z("psychic_boost_button",[z("psychic_attack"),r]),boostTime:()=>t.race.psychicPowers.assaultTime>0?z("psychic_boost_time",[t.race.psychicPowers.assaultTime]):""}}),ls("psychicAssault",(function(){return z("psychic_assault_desc",[Ei.psychic.vars()[3]])}),{elm:"#psychicAssault > div > button"})}(e),t.tech.psychic>=3&&(t.race.psychicPowers.cash||(t.race.psychicPowers.cash=0),function(e){let a=$('
                              ');if(e.append(a),a.append($(`
                              ${z("psychic_profit_title")}
                              `)),a.append('
                              '),t.tech.psychic>=4){let e=$(`
                              ${z("psychic_channel")}
                              `),t=$('{{ cash }}'),r=$(`«`),i=$(`»`);e.append(r),e.append(t),e.append(i),a.append(e)}let r=t.tech.psychic>=5?52:65,i=t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg?t.stats.achieve.nightmare.mg:0;Cs({el:"#psychicFinance",data:t.tech.psychic>=4?t.race.psychicPowers.channel:{},methods:{boostVal(){t.resource.Energy.amount>=r&&(t.resource.Energy.amount-=r,t.race.psychicPowers.cash=72*i)},add(){let e=y();for(let a=0;a0;a++)t.race.psychicPowers.channel.cash--}},filters:{boost:()=>z("psychic_boost_button",[z("psychic_profit"),r]),boostTime:()=>t.race.psychicPowers.cash>0?z("psychic_boost_time",[t.race.psychicPowers.cash]):""}}),ls("psychicFinance",(function(){return z("psychic_profit_desc",[Ei.psychic.vars()[3]])}),{elm:"#psychicFinance > div > button"})}(e)),t.tech.psychicthrall&&t.tech.unfathomable&&t.race.unfathomable&&(t.tech.psychicthrall>=2&&function(e){let a=$('
                              ');e.append(a),a.append($(`
                              ${z("psychic_stun_title")}
                              `)),a.append('
                              ');let r=t.tech.psychic>=5?80:100;Cs({el:"#psychicCapture",data:{},methods:{stun(){if(t.resource.Energy.amount>=r&&t.tech.unfathomable){let e=0;if(t.city.hasOwnProperty("surfaceDwellers"))for(let a=0;az("psychic_stun_button",[r])}}),ls("psychicCapture",(function(){return z("psychic_stun_desc")}),{elm:"#psychicCapture > div > button"})}(e),function(e){let a=$('
                              ');e.append(a),a.append($(`
                              ${z("psychic_mind_break_title")}
                              `)),a.append('
                              ');let r=t.tech.psychic>=5?64:80;Cs({el:"#psychicMindBreak",data:{},methods:{breakMind(){if(t.resource.Energy.amount>=r&&t.tech.unfathomable){let e=[];if(t.city.hasOwnProperty("surfaceDwellers"))for(let a=0;a0&&e.push(a);if(e.length>0){let a=e[Math.rand(0,e.length)];t.city.captive_housing[`jailrace${a}`]--,t.city.captive_housing[`race${a}`]++,t.resource.Energy.amount-=r}}}},filters:{break:()=>z("psychic_mind_break_button",[r])}}),ls("psychicMindBreak",(function(){return z("psychic_mind_break_desc")}),{elm:"#psychicMindBreak > div > button"})}(e)))}var os=!1;function ls(e,a,r){r||(r={}),r.hasOwnProperty("elm")||(r.elm="#"+e),r.hasOwnProperty("bind")||(r.bind=!0),r.hasOwnProperty("unbind")||(r.unbind=!0),r.hasOwnProperty("placement")||(r.placement="bottom"),r.bind&&$(r.elm).on(r.bind_mouse_enter?"mouseenter":"mouseover",(function(){(os||$("#popper").length>0)&&_s();let i=r.wide?" wide":"",s=r.classes?r.classes:"has-background-light has-text-dark pop-desc";var n=$(`
                              `);r.attach?$(r.attach).append(n):$("#main").append(n),a&&n.append("function"==typeof a?a({this:this,popper:n}):a),os=Popper.createPopper(r.self?this:$(r.elm)[0],document.querySelector("#popper"),{placement:r.placement,modifiers:[{name:"flip",enabled:!0},{name:"offset",options:{offset:r.offset?r.offset:[0,0]}}]}),n.show(),r.hasOwnProperty("in")&&"function"==typeof r.in&&r.in({this:this,popper:n,id:"popper"}),cn("firework")&&t[t.race.cataclysm||t.race.orbit_decayed?"space":"city"].firework.on>0&&$(n).append('')})),r.unbind&&("ontouchstart"in document.documentElement&&navigator.userAgent.match(t.settings.touch)?$(r.elm).on("touchend",(function(e){_s(),r.hasOwnProperty("out")&&"function"==typeof r.out&&r.out({this:this,popper:$("#popper"),id:"popper"})})):$(r.elm).on(r.bind_mouse_enter?"mouseleave":"mouseout",(function(){_s(),r.hasOwnProperty("out")&&"function"==typeof r.out&&r.out({this:this,popper:$("#popper"),id:"popper"})})))}function _s(e){e&&$("#popper").data("id")!==e||($("#popper").hide(),os&&(os.destroy(),os=!1),Ss($("#popper"),!0))}function ds(e){switch(e){case"stop":P.w?P.w.postMessage({loop:"clear"}):(clearInterval(j.main_loop),clearInterval(j.mid_loop),clearInterval(j.long_loop)),P.s=!1;break;case"start":if(P.resetTimers(),t.settings.gameSpeed=1,ps(),t.settings.at>0&&(t.settings.gameSpeed*=t.settings.atMultiplier),t.race.slow){const e=1-Ei.slow.vars()[0]/100;t.settings.gameSpeed*=e}if(t.race.hyper){const e=1+Ei.hyper.vars()[0]/100;t.settings.gameSpeed*=e}P.timers.mid/=t.settings.gameSpeed,P.timers.long/=t.settings.gameSpeed,P.w?(P.w.postMessage({loop:"short",period:P.timers.main}),P.w.postMessage({loop:"mid",period:P.timers.mid}),P.w.postMessage({loop:"long",period:P.timers.long})):(j.main_loop=setInterval((function(){fastLoop()}),P.timers.main),j.mid_loop=setInterval((function(){midLoop()}),P.timers.mid),j.long_loop=setInterval((function(){longLoop()}),P.timers.long)),P.s=!0}}function ps(){if(!t.stats.hasOwnProperty("current"))return;const e=Date.now()-t.stats.current;if(e>=12e4){const a=t.settings.at+2*e/3,r=288e5;t.settings.at=Math.min(a,r)}}function us(e,t){let a=Si(),r=[];switch(e){case"power":r=["city:transmitter","prtl_ruins:arcology","city:apartment","int_alpha:habitat","int_alpha:luxury_condo","spc_red:spaceport","spc_titan:titan_spaceport","spc_titan:electrolysis","int_alpha:starport","spc_dwarf:shipyard","spc_titan:ai_core2","spc_eris:drone_control","spc_titan:ai_colonist","int_blackhole:s_gate","gxy_gateway:starbase","spc_triton:fob","spc_enceladus:operating_base","spc_enceladus:zero_g_lab","spc_titan:sam","gxy_gateway:ship_dock","prtl_ruins:hell_forge","int_neutron:stellar_forge","int_neutron:citadel","tau_home:orbital_station","tau_red:orbital_platform","tau_gas:refueling_station","tau_home:tau_farm","tau_gas:ore_refinery","tau_gas:whaling_station","city:coal_mine","spc_moon:moon_base","spc_red:red_tower","spc_home:nav_beacon","int_proxima:xfer_station","gxy_stargate:telemetry_beacon","int_nebula:nexus","gxy_stargate:gateway_depot","spc_dwarf:elerium_contain","spc_gas:gas_mining","spc_belt:space_station","spc_gas_moon:outpost","gxy_gorddon:embassy","gxy_gorddon:dormitory","gxy_alien1:resort","spc_gas_moon:oil_extractor","int_alpha:int_factory","city:factory","spc_red:red_factory","spc_dwarf:world_controller","prtl_fortress:turret","prtl_badlands:war_drone","city:wardenclyffe","city:biolab","city:mine","city:rock_quarry","city:cement_plant","city:sawmill","city:mass_driver","int_neutron:neutron_miner","prtl_fortress:war_droid","prtl_pit:soul_forge","gxy_chthonian:excavator","int_blackhole:far_reach","prtl_badlands:sensor_drone","prtl_badlands:attractor","city:metal_refinery","gxy_stargate:gateway_station","gxy_alien1:vitreloy_plant","gxy_alien2:foothold","gxy_gorddon:symposium","int_blackhole:mass_ejector","city:casino","spc_hell:spc_casino","tau_home:tauceti_casino","prtl_fortress:repair_droid","gxy_stargate:defense_platform","prtl_ruins:guard_post","prtl_lake:cooling_tower","prtl_lake:harbour","prtl_spire:purifier","prtl_ruins:archaeology","prtl_pit:gun_emplacement","prtl_gate:gate_turret","prtl_pit:soul_attractor","prtl_gate:infernite_mine","int_sirius:ascension_trigger","spc_kuiper:orichalcum_mine","spc_kuiper:elerium_mine","spc_kuiper:uranium_mine","spc_kuiper:neutronium_mine","spc_dwarf:m_relay","tau_home:tau_factory","tau_home:infectious_disease_lab","tau_home:alien_outpost","tau_gas:womling_station","spc_red:atmo_terraformer","tau_star:matrix","tau_home:tau_cultural_center","prtl_pit:soul_capacitor","city:replicator"];break;case"moon":r=["spc_moon:helium_mine","spc_moon:iridium_mine","spc_moon:observatory"];break;case"red":r=["spc_red:living_quarters","spc_red:exotic_lab","spc_red:red_mine","spc_red:fabrication","spc_red:biodome","spc_red:vr_center"];break;case"belt":r=["spc_belt:elerium_ship","spc_belt:iridium_ship","spc_belt:iron_ship"];break;case"alpha":r=["int_alpha:fusion","int_alpha:mining_droid","int_alpha:processing","int_alpha:laboratory","int_alpha:g_factory","int_alpha:exchange","int_alpha:zoo"];break;case"nebula":r=["int_nebula:harvester","int_nebula:elerium_prospector"];break;case"gateway":r=["gxy_gateway:bolognium_ship","gxy_gateway:dreadnought","gxy_gateway:cruiser_ship","gxy_gateway:frigate_ship","gxy_gateway:corvette_ship","gxy_gateway:scout_ship"];break;case"alien2":r=["gxy_alien2:armed_miner","gxy_alien2:ore_processor","gxy_alien2:scavenger"];break;case"lake":r=["prtl_lake:bireme","prtl_lake:transport"];break;case"spire":r=["prtl_spire:port","prtl_spire:base_camp","prtl_spire:mechbay"];break;case"titan":r=["spc_titan:titan_quarters","spc_titan:titan_mine","spc_titan:g_factory","spc_titan:decoder"];break;case"enceladus":r=["spc_enceladus:water_freighter","spc_enceladus:operating_base","spc_enceladus:zero_g_lab"];break;case"eris":r=["spc_eris:shock_trooper","spc_eris:tank"];break;case"tau_home":r=["tau_home:colony","tau_home:tau_factory","tau_home:mining_pit","tau_home:infectious_disease_lab"];break;case"tau_red":r=["tau_red:womling_village","tau_red:womling_farm","tau_red:overseer","tau_red:womling_mine","tau_red:womling_fun","tau_red:womling_lab"];break;case"tau_roid":r=["tau_roid:mining_ship","tau_roid:whaling_ship"]}t&&(a[e].l.length=0),r.forEach((function(t){a[e].l.includes(t)||a[e].l.push(t)})),a[e].l.length>r.length&&a[e].l.forEach((function(t){r.includes(t)||a[e].l.splice(a[e].l.indexOf(t),1)}))}function hs(e,a,r,i,s){if(i=i||[],s||i.includes("all")||i.push("all"),a=a||"warning",i.includes(u.view)){let r=$('

                              '+e+"

                              ");$("#msgQueueLog").prepend(r),$("#msgQueueLog").children().length>t.settings.msgFilters[u.view].max&&$("#msgQueueLog").children().last().remove()}i.forEach((function(r){u[r].unshift({msg:e,color:a}),u[r].length>t.settings.msgFilters[r].max&&u[r].pop()})),r||i.forEach((function(r){t.lastMsg[r]&&(t.lastMsg[r].unshift({m:e,c:a}),t.lastMsg[r].length>t.settings.msgFilters[r].save&&t.lastMsg[r].splice(t.settings.msgFilters[r].save))}))}function ms(e){for(let a=t.queue.queue.length-1;a>=0;a--)e.includes(t.queue.queue[a].id)&&t.queue.queue.splice(a,1)}function gs(e){for(let a=t.r_queue.queue.length-1;a>=0;a--)e.includes(Mr.tech[t.r_queue.queue[a].type].grant[0])&&t.r_queue.queue.splice(a,1)}function vs(){let e=t.tech.queue>=2?t.tech.queue>=3?8:5:3;t.stats.feat.journeyman&&t.stats.feat.journeyman>=2&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>=2&&(e+=Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman)>=4?2:1),t.genes.queue&&t.genes.queue>=2&&(e*=2);let a=K("pragmatist",0);a&&(e=Math.round(e*(1+a/100))),t.queue.max=e}function fs(){let e=3;if(t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0){let a=Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman);e+=a>=3?a>=5?3:2:1}t.genes.queue&&t.genes.queue>=2&&(e*=2);let a=K("theorist",0);a&&(e=Math.round(e*(1+a/100))),t.r_queue.max=e}function ys(){!function(){let e=$("#buildQueue .buildList")[0];if(e){let t=Sortable.get(e);t&&t.destroy()}}(),Ss($("#buildQueue")),$("#buildQueue").append($(`\n

                              ${z("building_queue")} ({{ | used_q }}/{{ max }})

                              \n \n `));let e=$('
                                ');$("#buildQueue").append(e),e.append($('
                              • {{ item.label }}{{ item.q | count }} [{{ item.time | time }}{{ item.t_max | max_t(item.time) }}]
                              • '));try{Cs({el:"#buildQueue",data:t.queue,methods:{remove(e){let a=y();for(let r=0;r0&&(t.queue.queue[e].q-=t.queue.queue[e].qs),t.queue.queue[e].q<=0){_s(`q${t.queue.queue[e].id}${e}`),t.queue.queue.splice(e,1),ys();break}},setID:e=>`q${t.queue.queue[e].id}${e}`,setData(e,a){let r,i=t.queue.queue[e].id.split("-");"arpa"===i[0].substring(0,4)?r=i[0].substring(4):"city"===i[0]||"evolution"===i[0]||"starDock"===i[0]?r=Mr[i[0]][i[1]]:Object.keys(Mr[i[0]]).forEach((function(e){Mr[i[0]][e].hasOwnProperty(i[1])&&(r=Mr[i[0]][e][i[1]])}));let s={};if(r.cost){let e=Ns(r);Object.keys(e).forEach((function(t){let r=e[t]();r>0&&(s[`${a}-${t}`]=r)}))}return s},pauseQueue(){$("#pausequeue").removeClass("play"),$("#pausequeue").removeClass("pause"),t.queue.pause?(t.queue.pause=!1,$("#pausequeue").addClass("play")):(t.queue.pause=!0,$("#pausequeue").addClass("pause"))},pausedesc:()=>t.queue.pause?z("queue_play"):z("queue_pause")},filters:{time:e=>zs(e),count:e=>e>1?` (${e})`:"",max_t:(e,t)=>t===e||t<0?"":` / ${zs(e)}`,used_q(){let e=0;for(let a=0;a=4&&(r.tech.whitehole=3,r.resource.Soul_Gem.amount+=10,r.resource.Knowledge.amount+=15e5,r.stats.know-=15e5),r.tech.hasOwnProperty("quaked")&&2===r.tech.quaked&&(r.tech.quaked=1,r.resource.Knowledge.amount+=5e5,r.stats.know-=5e5),r.tech.hasOwnProperty("corrupted_ai")&&3===r.tech.corrupted_ai&&(r.tech.corrupted_ai=1,r.resource.Knowledge.amount+=5e6,r.stats.know-=5e6)),e.setItem("evolved",LZString.compressToUTF16(JSON.stringify(r))),window.location.reload())};const ws=!1;function ks(e,t){try{t.debug_mode=ws,gtag("event",e,t)}catch(e){}}function $s(e,a,r,i){let s=t.resource[e].amount+a,n=!0;return s>t.resource[e].max&&-1!=t.resource[e].max?s=t.resource[e].max:s<0&&((!i||i&&-1*s>i)&&(n=!1),s=0),Number.isNaN(s)||(t.resource[e].amount=s,r||(t.resource[e].delta+=a,"Mana"===e&&a>0&&(t.resource[e].gen_d+=a))),n}function xs(e){let a=Ki[t.race.species].type;switch(a){case"animal":a="animalism";break;case"small":a="dwarfism";break;case"giant":a="gigantism";break;case"avian":case"reptilian":a="eggshell";break;case"fungi":a="chitin";break;case"insectoid":a="athropods";break;case"angelic":a="celestial";break;case"organism":a="sentience"}const r=e?[z("civics_gov_tp_name0"),z("civics_gov_tp_name1"),z("civics_gov_tp_name2"),z("civics_gov_tp_name3"),z("civics_gov_tp_name4"),z("civics_gov_tp_name5"),z("civics_gov_tp_name6"),z("civics_gov_tp_name7"),z("civics_gov_tp_name8"),z("civics_gov_tp_name9")]:[Ki[t.race.species].name,Ki[t.race.species].home,z(`biome_${t.city.biome}_name`),z(`evo_${a}_title`),z("civics_gov_name0"),z("civics_gov_name1"),z("civics_gov_name2"),z("civics_gov_name3"),z("civics_gov_name4"),z("civics_gov_name5"),z("civics_gov_name6"),z("civics_gov_name7"),z("civics_gov_name8"),z("civics_gov_name9"),z("civics_gov_name10"),z("civics_gov_name11")];return{s0:Math.rand(0,14),s1:r[Math.rand(0,r.length)]}}function qs(e,a,r,i,s){s||(s="city"),"micro"===t.race.universe&&(i-=Is("micro",!1)),t.race.small?i-=Ei.small.vars()[0]:t.race.large&&(i+=Ei.large.vars()[0]),t.race.compact&&(i-=Ei.compact.vars()[0]),!t.race.tunneler||"mine"!==e&&"coal_mine"!==e||(i-=Ei.tunneler.vars()[0]),!t.tech.housing_reduction||"basic_housing"!==e&&"cottage"!==e||(i-=.02*t.tech.housing_reduction),t.tech.housing_reduction&&"captive_housing"===e&&(i-=.01*t.tech.housing_reduction),"basic_housing"===e&&(t.race.solitary&&(i-=Ei.solitary.vars()[0]),t.race.pack_mentality&&(i+=Ei.pack_mentality.vars()[0])),"cottage"===e&&(t.race.solitary&&(i+=Ei.solitary.vars()[1]),t.race.pack_mentality&&(i-=Ei.pack_mentality.vars()[1])),"apartment"===e&&t.race.pack_mentality&&(i-=Ei.pack_mentality.vars()[1]),t.genes.creep&&!t.race.no_crispr?i-=.01*t.genes.creep:t.genes.creep&&t.race.no_crispr&&(i-=.002*t.genes.creep);let n=K("noquestions",0);n&&(i-=n),i<1.005&&(i=1.005);var c="citizen"===e?t.resource[t.race.species].amount:t[s][e]?t[s][e].count:0;return a&&(c+=a),Math.round(i**c*r)}function Ps(e,a,r,i,s,n){s||(s="space"),n=n||1.005,"micro"===t.race.universe&&(i-=Is("micro",!0)),t.genes.creep&&!t.race.no_crispr?i-=.01*t.genes.creep:t.genes.creep&&t.race.no_crispr&&(i-=.002*t.genes.creep),t.race.small&&(i-=Ei.small.vars()[1]),t.race.compact&&(i-=Ei.compact.vars()[1]),t.prestige.Harmony.count>0&&t.stats.achieve.ascended&&(i-=js());let c=K("noquestions",0);c&&(i-=c),i0&&t.stats.achieve.ascended){let e=0;switch(t.race.universe){case"heavy":t.stats.achieve.ascended.hasOwnProperty("h")&&(e=t.stats.achieve.ascended.h*t.prestige.Harmony.count);break;case"antimatter":t.stats.achieve.ascended.hasOwnProperty("a")&&(e=t.stats.achieve.ascended.a*t.prestige.Harmony.count);break;case"evil":t.stats.achieve.ascended.hasOwnProperty("e")&&(e=t.stats.achieve.ascended.e*t.prestige.Harmony.count);break;case"micro":t.stats.achieve.ascended.hasOwnProperty("m")&&(e=t.stats.achieve.ascended.m*t.prestige.Harmony.count);break;case"magic":t.stats.achieve.ascended.hasOwnProperty("mg")&&(e=t.stats.achieve.ascended.mg*t.prestige.Harmony.count);break;default:t.stats.achieve.ascended.hasOwnProperty("l")&&(e=t.stats.achieve.ascended.l*t.prestige.Harmony.count)}if(e>0)return e=.01*(Math.log(50+e)-3.912023005428146),+e.toFixed(5)}return 0}function Os(e,a,r,i){if(i=void 0===i||i,e.cost){let s=0,n=!1,c=!(!a||!a.id[e.id])&&a.id[e.id],o=Ns(e,c),l=!!a&&{},_=!!a&&{};a&&(Object.keys(a.r).forEach((function(e){l[e]=a.r[e]})),Object.keys(a.rr).forEach((function(e){_[e]=a.rr[e]})));let d=!1;t.interstellar.hasOwnProperty("mass_ejector")&&t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks&&Object.keys(t.race.governor.tasks).forEach((function(e){"trash"===t.race.governor.tasks[e]&&(d=!0)}));let p={};return Object.keys(o).forEach((function(e){if(s>=0&&!t.prestige.hasOwnProperty(e)&&!["Morale","HellArmy","Structs","Bool"].includes(e)){var r=Number(c?o[e](c):o[e]());if(r>0){let c="Species"===e?t.race.species:e,o="Supply"===e?t.portal.purifier.supply:Number(t.resource[c].amount),u="Supply"===e?t.portal.purifier.sup_max:t.resource[c].max,h="Supply"===e?t.portal.purifier.diff:t.resource[c].diff;if(d&&t.interstellar.mass_ejector[e]&&(h+=t.interstellar.mass_ejector[e],t.race.governor.config.trash.hasOwnProperty(e)&&(h-=Math.min(t.race.governor.config.trash[e].v,t.interstellar.mass_ejector[e]))),a&&(o+=h*(i?a.t.t:a.t.rt),a.r.hasOwnProperty(c)||(a.r[c]=0),a.rr.hasOwnProperty(c)||(a.rr[c]=0),i?(o-=Number(a.r[c]),a.r[c]+=r,a.rr[c]+=r):(o-=Number(a.rr[c]),a.rr[c]+=r),u>=0&&o>u&&(o=u)),r>o)if(h>0){let e=(r-o)/h;e>s&&(n=c,s=e),p[c]=e}else a&&(a.r=l,a.rr=_),s=-9999999,p[c]=99999999-h,(p[n]&&p[c]>p[n]||!p[n])&&(n=c)}}})),a&&s>=0&&(void 0===a.id[e.id]?a.id[e.id]=1:a.id[e.id]++,i&&(a.t.t+=s),a.t.rt+=s),r?{t:s,r:n,s:p}:s}return 0}function Ms(e,a,r,i){let s=!(!r||!r.id[e.id])&&r.id[e.id],n=Ae(e.cost,s),c=0,o=!!r&&{},l=!!r&&{},_=!1;r&&(Object.keys(r.r).forEach((function(e){o[e]=r.r[e]})),Object.keys(r.rr).forEach((function(e){l[e]=r.rr[e]})));let d=!1;t.interstellar.hasOwnProperty("mass_ejector")&&t.genes.governor&&t.tech.governor&&t.race.governor&&t.race.governor.g&&t.race.governor.tasks&&Object.keys(t.race.governor.tasks).forEach((function(e){"trash"===t.race.governor.tasks[e]&&(d=!0)}));let p={};return Object.keys(n).forEach((function(e){if(c>=0){let i=Number(n[e](s))*a;if(i>0){let a=Number(t.resource[e].amount),s=t.resource[e].diff;if(r&&(d&&t.interstellar.mass_ejector[e]&&(s+=t.interstellar.mass_ejector[e],t.race.governor.config.trash.hasOwnProperty(e)&&(s-=Math.min(t.race.governor.config.trash[e].v,t.interstellar.mass_ejector[e]))),a+=s*r.t.t,r.r[e]?(a-=Number(r.r[e]),r.r[e]+=i):r.r[e]=i,r.rr[e]?r.rr[e]+=i:r.rr[e]=i,t.resource[e].max>=0&&a>t.resource[e].max&&(a=t.resource[e].max)),i>a)if(s>0){let t=(i-a)/s;t>c&&(c=t,_=e),p[e]=t}else r&&(r.r=o,r.rr=l),c=-9999999,p[e]=99999999-s,(p[_]&&p[e]>p[_]||!p[_])&&(_=e)}}})),r&&c>=0&&(void 0===r.id[e.id]?r.id[e.id]=1:r.id[e.id]++,r.t.t+=c,r.t.rt+=c),i?{t:c,r:_,s:p}:c}function Ss(e,t){if(e.find(".vb").each((function(){try{$(this)[0].__vue__.$destroy()}catch(e){}})),t){try{e[0].__vue__.$destroy()}catch(e){}e.remove()}else e.empty()}function Cs(e,t){if(t=t||"create",$(e.el).length>0&&void 0!==$(e.el)[0].__vue__)try{"update"===t?$(e.el)[0].__vue__.$forceUpdate():$(e.el)[0].__vue__.$destroy()}catch(e){}"create"===t&&(new Vue(e),$(e.el).addClass("vb"))}function zs(e){let t;if(e<0)t=z("time_never");else if((e=+e.toFixed(0))>60){let a=e%60,r=(e-a)/60;if(r>=60){let e=r%60,a=(r-e)/60;a>24?(e=a%24,t=`${(a-e)/24}d ${e}h`):(e=("0"+e).slice(-2),t=`${a}h ${e}m`)}else a=("0"+a).slice(-2),t=`${r}m ${a}s`}else t=`${e}s`;return t}function Fs(e){return"antimatter"===t.race.universe&&(e=+(e*=Is("antimatter")).toFixed(2)),"leo"===N()&&(e=+(e*=1+G("leo")[0]/100).toFixed(2)),e}function As(e){return t.race.emfield?+(1.5*e).toFixed(2):e}function Is(e,a,r,i){i||(i={});let s=void 0!==i.dark?i.dark:t.prestige.Dark.count,n=void 0!==i.harmony?i.harmony:t.prestige.Harmony.count,c=void 0!==i.sludge?i.sludge:t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge[xn(e)]?t.stats.achieve.extinct_sludge[xn(e)]:0;switch(e){case"standard":return"standard"===t.race.universe||r?(n>0&&(s*=1+.001*n),c&&(s*=1+.03*c),1+s/200):0;case"evil":return"evil"===t.race.universe||r?(n>0&&(s*=1+.01*n),c&&(s*=1+.03*c),1+(Math.log2(10+s)-3.321928094887362)/5):1;case"micro":return"micro"===t.race.universe||r?a?(n>0&&(s*=1+.01*n),s=.01+(Math.log(100+s)-4.605170185988092)/35,c&&(s*=1+.03*c),s>.04&&(s=.04),+s.toFixed(5)):(n>0&&(s*=1+.01*n),s=.02+(Math.log(100+s)-4.605170185988092)/20,c&&(s*=1+.03*c),s>.06&&(s=.06),+s.toFixed(5)):0;case"heavy":return"heavy"===t.race.universe||r?(n>0&&(s*=1+.01*n),c&&(s*=1+.03*c),.995**s):1;case"antimatter":return"antimatter"===t.race.universe||r?(n>0&&(s*=1+.01*n),c&&(s*=1+.03*c),1+(Math.log(50+s)-3.912023005428146)/5):0;case"magic":return"magic"===t.race.universe||r?(n>0&&(s*=1+.01*n),c&&(s*=1+.03*c),1+(Math.log(50+s)-3.912023005428146)/3):0}return 0}const Ts=function(e){return Ls&&!e?Ls:t.genes.challenge&&t.genes.challenge>=2?Ls=Es(t.race.universe):0};var Ls;function Es(e,a){if(t.genes.challenge&&t.genes.challenge>=2){let r=$n(e=e||t.race.universe),i="standard"===e?.25:.15,s=t.genes.challenge>=3?.15:.1;t.genes.challenge>=4&&"standard"!==e&&(i+=.05,s-=.05),t.race.weak_mastery&&"antimatter"===e&&(i/=10,s/=10),t.race.nerfed&&(i/="antimatter"===e?5:2,s/="antimatter"===e?5:2),t.race.ooze&&(i*=1-Ei.ooze.vars()[2]/100,s*=1-Ei.ooze.vars()[2]/100);let n=t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):0;n>0&&(i*=1+n/100,s*=1+n/100);let c=r.aLvl*i,o=0;return"standard"!==e&&(o=r.uLvl*s),t.genes.challenge>=5&&t.race.hasOwnProperty("mastery")&&(c*=1+Ei.mastery.vars()[0]*t.race.mastery/100,o*=1+Ei.mastery.vars()[0]*t.race.mastery/100),a?{g:c,u:o,m:c+o}:c+o}return a?{g:0,u:0,m:0}:0}const Ks=function(e){if(!Ds||e){let e=0;Object.keys(t.pillars).forEach((function(a){Ki[a]&&t.race.species===a?e+=4:Ki[a]&&e++})),Ds=[1+e/100,1+2*e/100]}return Ds};var Ds;function Bs(e,a,r,i){r=r||0;let s=(i=i||{}).genes;void 0===s&&(s=Mn()-1,s>4&&(s=4));let n=i.uni||t.race.universe;if("micro"===n&&(e*=.25),"antimatter"===n&&(e*=1.1),"heavy"===n&&"mad"!==a)switch(s){case 1:e*=1.1;break;case 2:e*=1.15;break;case 3:e*=1.2;break;case 4:e*=1.25;break;default:e*=1.05}switch((void 0!==i.tp?i.tp:t.race.truepath)&&(e*=1.1),s){case 1:return+(1.05*e).toFixed(r);case 2:return+(1.12*e).toFixed(r);case 3:return+(1.25*e).toFixed(r);case 4:return+(1.45*e).toFixed(r);default:return+e.toFixed(r)}}function Gs(e,a){let r={plasmid:0,phage:0,dark:0,harmony:0,artifact:0,cores:0};a||(a={});let i=a.genes,s=a.uni;s=s||t.race.universe;let n=0;if(void 0===a.cit){let e=t.civic.hasOwnProperty("garrison")?t.civic.garrison.workers:0;for(let a=0;a<3;a++)t.civic.foreign[`gov${a}`].occ&&(e+=ta("federation"===t.civic.govern.type?15:20));n=t.race.high_pop?Math.round(t.resource[t.race.species].amount/Ei.high_pop.vars()[0])+Math.round(e/Ei.high_pop.vars()[0]):t.resource[t.race.species].amount+e}else n=a.high_pop?Math.round(a.cit/Ei.high_pop.vars(a.high_pop)[0])+Math.round(a.sol/Ei.high_pop.vars(a.high_pop)[0]):a.cit+a.sol;let c=999,o=1e6,l=100,_=0,d=150;switch(e){case"mad":c=3,o=1e5,l=1.1,d=150,(void 0!==a.synth?a.synth:"synthetic"===Ki[t.race.species].type)&&(c=5,o=125e3,d=100);break;case"cataclysm":case"bioseed":c=3,o=5e4,l=1.015,_=1,d=400;break;case"ai":c=2.5,o=45e3,l=1.014,_=2,d=600;break;case"vacuum":case"bigbang":c=2.2,o=4e4,l=1.012,_=2.5,d=800;break;case"ascend":case"terraform":c=1.15,o=3e4,l=1.008,_=4,d=2e3;break;case"matrix":c=1.5,o=32e3,l=1.01,_=3.2,d=1800;break;case"retire":c=1.15,o=32e3,l=1.006,_=3.2,d=1800;break;case"eden":c=1,o=18e3,l=1.004,_=2.5,d=1800}if(d=void 0!==i?Math.floor(d*(1+(i+(a.tp?1:0))/8)):Math.floor(d*(1+(Mn()-(t.race.truepath?0:1))/8)),void 0===a.plas){let i=void 0!==a.know?a.know:t.stats.know,s=Math.round(n/c);for(;i>o;)s++,i-=o,o*=l;if(t.race.cataclysm?s+=300:t.race.lone_survivor&&(s+=800),r.plasmid=Bs(s,e,!1,a),!a.rawPlasmids&&r.plasmid>d){let e=r.plasmid-d;r.plasmid=d,e=Math.floor(e/(e+d)*d),r.plasmid+=e}}else r.plasmid=a.plas;if(r.phage=r.plasmid>0?Bs(Math.floor(Math.log2(r.plasmid)*Math.E*_),e,!1,a):0,"bigbang"===e){let e=a.exotic,i=a.mass;void 0===e&&t.interstellar&&t.interstellar.stellar_engine&&(e=t.interstellar.stellar_engine.exotic,i=t.interstellar.stellar_engine.mass);let s=+Math.log(1+40*e).toFixed(3);s+=+(Math.log2(i-7)/2.5).toFixed(3),s=Bs(s,"bigbang",3,a),r.dark=s}else if("vacuum"===e){let e=void 0!==a.mana?a.mana:t.resource.Mana.gen,i=+(Math.log2(e)/5).toFixed(3);i=Bs(i,"vacuum",3,a),r.dark=i}if(["ascend","descend","terraform"].includes(e)){let n=1;if(void 0===i?(n=Mn(),n>5&&(n=5)):n=i+1,"ascend"===e||"terraform"===e){switch(s){case"micro":n*=.25;break;case"heavy":n*=1.2;break;case"antimatter":n*=1.1}r.harmony=parseFloat(n.toFixed(2))}else if("descend"===e){let e="micro"===s?1:n,i=a.floor;void 0!==i?i++:i=t.portal.hasOwnProperty("spire")?t.portal.spire.count:0,[50,100].forEach((function(t){i>t&&e++})),r.artifact=e}}return"ai"===e&&(r.cores="micro"===s?2:5),r}function Ns(e,a,r){let i=e.cost||{};if((i.RNA||i.DNA)&&t.genes.evolve){var s={};return Object.keys(i).forEach((function(e){"RNA"!==e&&"DNA"!==e||(s[e]=function(){return Math.round(.8*i[e](a,r))})})),s}return i=function(e,a,r){if(t.race.bloated){let t=1+Ei.bloated.vars()[0]/100;var i={};return Object.keys(e).forEach((function(s){["Food","Lumber","Stone","Furs","Copper","Iron","Aluminium","Cement","Coal","Steel","Titanium","Alloy","Polymer","Iridium"].includes(s)?i[s]=function(){return e[s](a,r)*t}:i[s]=function(){return e[s](a,r)}})),i}return e}(i,a,r),i=function(e,a,r,i){if((i?i.truepath:t.race.truepath)&&(!a.hasOwnProperty("path")||!a.path.includes("truepath"))){var s={};return Object.keys(e).forEach((function(t){"Money"===t?s[t]=function(){return Math.round(3*e[t](r,i))}:["Structs","Knowledge","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe"].includes(t)?s[t]=function(){return e[t](r,i)}:s[t]=function(){return Math.round(2*e[t](r,i))}})),s}return e}(i,e,a,r),i=function(e,a,r){if(t.race.lone_survivor){var i={};return Object.keys(e).forEach((function(t){["Structs","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe"].includes(t)?i[t]=function(){return e[t](a,r)}:["Knowledge"].includes(t)?i[t]=function(){return Math.round(.5*e[t](a,r))}:["Money"].includes(t)?i[t]=function(){return Math.round(.22*e[t](a,r))}:["Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Quantium"].includes(t)?i[t]=function(){return Math.round(.14*e[t](a,r))}:i[t]=function(){return Math.round(.28*e[t](a,r))}})),i}return e}(i,a,r),i=function(e,a,r){if(t.race.inflation){var i={};return Object.keys(e).forEach((function(s){if("Money"===s){let n=1+t.race.inflation/75;i[s]=function(){return Math.round(e[s](a,r)*n)}}else i[s]=function(){return e[s](a,r)}})),i}return e}(i,a,r),i=function(e,a,r){if("technocracy"===t.civic.govern.type){let t=1+Y.technocracy()[1]/100;var i={};return Object.keys(e).forEach((function(s){if("Knowledge"===s){let t=1-Y.technocracy()[0]/100;i[s]=function(){return Math.round(e[s](a,r)*t)}}else i[s]="Money"===s||"Structs"===s||"Custom"===s?function(){return e[s](a,r)}:function(){return Math.round(e[s](a,r)*t)}})),i}return e}(i,a,r),i=function(e,a,r){if(t.race.flier&&(e.Stone||e.Cement)){var i={};let t=1-Ei.flier.vars()[0]/100;return Object.keys(e).forEach((function(s){"Stone"!==s||e.Cement?"Cement"===s?e.Stone?i.Stone=function(){return Math.round(e.Stone(a,r)*t+1.8*e[s](a,r)*t)||0}:i.Stone=function(){return Math.round(1.75*e[s](a,r)*t)}:i[s]=function(){return e[s](a,r)}:i[s]=function(){return Math.round(e[s](a,r)*t)||0}})),i}return e}(i,a,r),i=function(e,a,r){if(t.race.kindling_kindred&&(e.Lumber||e.Plywood)){var i={};let t=1+Ei.kindling_kindred.vars()[0]/100;return Object.keys(e).forEach((function(s){"Lumber"!==s&&"Plywood"!==s&&"Structs"!==s?i[s]=function(){return Math.round(e[s](a,r)*t)||0}:"Structs"===s&&(i[s]=function(){return e[s](a,r)})})),i}if(t.race.unfathomable&&t.city.captive_housing){let t=ts("entish");if(t>0){i={};let s=1-.4*t;return Object.keys(e).forEach((function(t){i[t]="Lumber"===t&&"Plywood"===t?function(){return Math.round(e[t](a,r)*s)||0}:function(){return e[t](a,r)}})),i}}return e}(i,a,r),i=function(e,a,r){if(t.race.smoldering){let i={};return Object.keys(e).forEach((function(t){if("Lumber"===t||"Plywood"===t){let s="Plywood"===t?2:1;i.Chrysotile=function(){return Math.round(e[t](a,r)*s)||0}}else["HellArmy","Structs","Chrysotile","Knowledge","Custom","Soul_Gem","Plasmid","Phage","Dark","Harmony","Blood_Stone","Artifact","Corrupt_Gem","Codex","Demonic_Essence","Horseshoe","Mana","Energy"].includes(t)?i[t]=function(){return e[t](a,r)}:i[t]=function(){return Math.round(.9*e[t](a,r))}})),!i.hasOwnProperty("Chrysotile")&&e.hasOwnProperty("Money")&&t.tech.primitive&&t.tech.primitive>=3&&(i.Chrysotile=function(){let t=e.Money(a,r)||0;return t>0?Math.round(t/50):0}),i}return e}(i,a,r),i=function(e,a,r){let i=K("pragmatist",1),s=ts("gnome");if((t.race.smart||t.race.dumb||i||s>0)&&e.Knowledge){var n={};return Object.keys(e).forEach((function(c){n[c]="Knowledge"===c?function(){let n=e[c](a,r);return t.race.smart&&(n*=1-Ei.smart.vars()[0]/100),s>0&&(n*=1-Ei.smart.vars(1)[0]/100*s),t.race.dumb&&(n*=1+Ei.dumb.vars()[0]/100),i&&(n*=1+i/100),Math.round(n)}:function(){return e[c](a,r)}})),n}return e}(i,a,r),i=function(e,a,r){if(e.Cement&&t.tech.cement&&t.tech.cement>=2){let s=t.tech.cement>=3?.8:.9;var i={};return Object.keys(e).forEach((function(t){i[t]="Cement"===t?function(){return Math.round(e[t](a,r)*s)||0}:function(){return e[t](a,r)}})),i}return e}(i,a,r),i=function(e,t,a){let r=K("extravagant",0);if(r){var i={};return Object.keys(e).forEach((function(s){if("Money"===s){let n=1+r/100;i[s]=function(){return Math.round(e[s](t,a)*n)}}else i[s]=function(){return e[s](t,a)}})),i}return e}(i,a,r),i=function(e,a,r){if(t.race.heavy){var i={};return Object.keys(e).forEach((function(t){i[t]="Stone"===t||"Cement"===t||"Wrought_Iron"===t?function(){return Math.round(e[t](a,r)*(1+Ei.heavy.vars()[1]/100))}:function(){return e[t](a,r)}})),i}return e}(i,a,r),function(e,a,r){let i=ts("pterodacti");if((t.race.hollow_bones||i>0)&&(e.Plywood||e.Brick||e.Wrought_Iron||e.Sheet_Metal||e.Mythril||e.Aerogel||e.Nanoweave||e.Scarletite||e.Quantium)){var s={};return Object.keys(e).forEach((function(n){s[n]="Plywood"===n||"Brick"===n||"Wrought_Iron"===n||"Sheet_Metal"===n||"Mythril"===n||"Aerogel"===n||"Nanoweave"===n||"Scarletite"===n||"Quantium"===n?function(){let s=e[n](a,r);return t.race.hollow_bones&&(s*=1-Ei.hollow_bones.vars()[0]/100),i>0&&(s*=1-Ei.hollow_bones.vars(3)[0]/100*i),Math.round(s)}:function(){return e[n](a,r)}})),s}return e}(i,a,r)}function Rs(e){return t.race.high_pop&&(e*=Ei.high_pop.vars()[0]),e}function Hs(e){switch(e){case"star":return'';case"atom":return'';case"heavy":return'';case"evil":return'';case"micro":return'';case"magic":return'';case"rocket":return'';case"heart":return'';case"clover":return'';case"candy":return'';case"ghost":return'';case"turkey":return'';case"present":return'';case"nuclear":return'';case"zombie":return'';case"fire":return'';case"mask":return'';case"skull":return'';case"taijitu":return'';case"trash":return'';case"martini":return'';case"lightbulb":return'';case"bunny":return'';case"egg":return'';case"turtle":return'';case"candycorn":return'';case"banana":return'\n ';case"sun":return'';case"firework":return'';case"floppy":return'';case"slime":return'';case"lightning":return'\n \n '}}function Us(e){switch(e){case"star":return"0 0 640 640";case"atom":return"0 0 100 88.379";case"heavy":case"mask":return"0 0 24 24";case"evil":return"0 0 240 240";case"micro":return"0 0 276 276";case"magic":return"0 0 2666 2666";case"rocket":return"0 0 165 173";case"sun":return"0 0 48 48";case"heart":return"0 0 20 16";case"clover":return"0 0 660.51 780.1";case"candy":return"0 0 200 200";case"ghost":return"0 0 399 432.23";case"turkey":return"0 0 250 300";case"present":return"0 0 410.98 434.75";case"nuclear":return"0 0 101.22 101.22";case"zombie":return"0 0 175 304";case"fire":return"0 0 615.18 879.36";case"skull":return"0 0 256.27 300.86";case"taijitu":return"0 -10 256 256 ";case"pizza":return"0 0 217.444 144.397";case"trash":case"martini":return"0 0 15 15";case"party":return"0 0 528.69 983.1";case"lightbulb":return"0 0 100 156";case"bunny":case"ant":return"0 0 128 128";case"egg":return"0 0 273.61 295.02";case"turtle":return"20 40 270 50";case"candycorn":return"0 0 325 449.98";case"banana":return"0 0 113.38582 111.81719";case"firework":return"0 10 12 35";case"floppy":return"0 0 60 60";case"slime":return"0 0 552 495";case"lightning":return"0 0 16 16"}}function Vs(e,a){if("feat"===a)switch(e){case"steelem":return"nuclear";case"the_misery":return"zombie";case"ill_advised":return"fire";case"garbage_pie":return"trash";case"demon_slayer":return"skull";case"equilibrium":return"taijitu";case"utopia":return"martini";case"energetic":return"lightbulb";case"finish_line":return"turtle";case"banana":return"banana";case"digital_ascension":return"floppy";case"slime_lord":return"slime";case"annihilation":return"lightning";case"friday":return"mask";case"valentine":return"heart";case"leprechaun":return"clover";case"easter":return"bunny";case"launch_day":return"rocket";case"solstice":return"sun";case"firework":return"firework";case"egghunt":return"egg";case"halloween":return"ghost";case"trickortreat":return"candy";case"thanksgiving":return"turkey";case"xmas":return"present";default:return"star"}return t.settings.icon}function Ws(e,t,a,r,i){let s="";return r&&(s=`id="${r}" `),`${Hs(e)}`}function Qs(e,a){let r=on();const i=new Date;return r.active&&!t.special.egg[i.getFullYear()][`egg${e}`]?Ws("egg",a||16,2,`egg${e}`,'role="button" aria-label="Egg" '):""}function Js(e,a,r){let i=ln();const s=(new Date).getFullYear();let n=r?"trick":"treat";return i.active&&!t.special.trick[s][`${n}${e}`]?Ws(r?"ghost":"candycorn",a||16,2,`${n}${e}`,`role="button" aria-label="${r?"Ghost":"Candy Corn"}" `):""}function Zs(e,a,r,i,s,n){return t.stats.achieve[e]&&(s?t.stats.achieve[e][n]-1:t.stats.achieve[e][n])>0?`

                                ${Hs(r)}

                                `:""}function Xs(e,a,r,i,s){a||(a=10),r||(r=Vs(e,"achievement"));let n="";if(s)switch(s){case"standard":n+=Zs(e,a,r,z(t.settings.icon),i,"l");break;case"antimatter":n+=Zs(e,a,"atom",z("universe_antimatter"),i,"a");break;case"evil":n+=Zs(e,a,"evil",z("universe_evil"),i,"e");break;case"heavy":n+=Zs(e,a,"heavy",z("universe_heavy"),i,"h");break;case"micro":n+=Zs(e,a,"micro",z("universe_micro"),i,"m");break;case"magic":n+=Zs(e,a,"magic",z("universe_magic"),i,"mg")}else n+=Zs(e,a,r,z(t.settings.icon),i,"l"),n+=Zs(e,a,"atom",z("universe_antimatter"),i,"a"),n+=Zs(e,a,"evil",z("universe_evil"),i,"e"),n+=Zs(e,a,"heavy",z("universe_heavy"),i,"h"),n+=Zs(e,a,"micro",z("universe_micro"),i,"m"),n+=Zs(e,a,"magic",z("universe_magic"),i,"mg");return n}function Ys(e,t){return(t=t||{})[e]?t[e]:e<=1?1:t[e]=Ys(e-1,t)+Ys(e-2,t)}function en(e){var t=Object.keys(e);return t[t.length*Math.random()<<0]}function tn(e){switch(e){case 1:return z("basic");case 2:return z("plain");case 3:return z("bronze");case 4:return z("silver");case 5:return z("gold");default:return""}}function an(e,a){let r=0;if(a)Object.keys(a.ascended).forEach((function(e){r+=a.ascended[e]}));else if(t.stats.achieve.ascended)for(let e=0;e=1&&(i+=t.stats.achieve.technophobe.l);let s=0;for(let t=0;t=0&&(s>i&&(a-=i-s),s++),r-=a}return r}function rn(){t.stats.reset++,t.stats.tdays+=t.stats.days,t.stats.days=0,t.stats.tknow+=t.stats.know,t.stats.know=0,t.stats.tstarved+=t.stats.starved,t.stats.starved=0,t.stats.tdied+=t.stats.died,t.stats.died=0,t.stats.tsac+=t.stats.sac,t.stats.sac=0,t.stats.tcattle+=t.stats.cattle,t.stats.cattle=0,t.stats.tmurders+=t.stats.murders,t.stats.murders=0,t.stats.tpsykill+=t.stats.psykill,t.stats.psykill=0}function sn(e){if(null===e||"object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());if(Array.isArray(e)){var t=[];return e.forEach((function(e){t.push(sn(e))})),t}let a=new e.constructor;for(var r in e)e.hasOwnProperty(r)&&(a[r]=sn(e[r]));return a}function nn(e,a,r){switch(e){case"reverse":{let e=a.toLowerCase().split("").reverse().join("");return e.charAt(0).toUpperCase()+e.slice(1)}case"name":return cn("fool",2021)?nn("reverse",Ki[t.race.species].name):Ki[t.race.species].name;case"curve":return 1-(1-a)**(r||1.5)}return!1}function cn(e,a){switch(e){case"easter":return on();case"halloween":return ln();case"fool":{const e=new Date;return!(t.settings.boring||3!==e.getMonth()||1!==e.getDate()||a&&e.getFullYear()!==a)}case"launch_day":{const e=new Date;return!t.settings.boring&&4===e.getMonth()&&6===e.getDate()}case"summer":{const e=new Date;return!t.settings.boring&&5===e.getMonth()&&[20,21,22].includes(e.getDate())?(t.city.hasOwnProperty("foundry")&&!t.city.foundry.hasOwnProperty("Thermite")&&(t.city.foundry.Thermite=0),t.resource.hasOwnProperty("Thermite")||(t.resource.Thermite={name:z("resource_Thermite_name"),display:!1,value:0,amount:0,crates:0,diff:0,delta:0,max:-1,rate:0}),!0):(t.city.hasOwnProperty("foundry")&&t.city.foundry.hasOwnProperty("Thermite")&&(t.city.foundry.crafting-=t.city.foundry.Thermite,t.civic.craftsman.workers-=t.city.foundry.Thermite,t.civic[t.civic.d_job].workers+=t.city.foundry.Thermite,delete t.city.foundry.Thermite),!1)}case"firework":{const e=new Date;if(!t.settings.boring&&6===e.getMonth()&&[1,2,3,4].includes(e.getDate())){let e=t.race.cataclysm||t.race.orbit_decayed?"space":"city";return t[e].hasOwnProperty("firework")||(t[e].firework={count:0,on:0}),!0}return(t.city.hasOwnProperty("firework")||t.space.hasOwnProperty("firework"))&&(delete t.city.firework,delete t.space.firework),!1}}return!1}function on(){const e=new Date;let a=e.getFullYear();t.special.egg.hasOwnProperty(a)||(t.special.egg[a]={egg1:!1,egg2:!1,egg3:!1,egg4:!1,egg5:!1,egg6:!1,egg7:!1,egg8:!1,egg9:!1,egg10:!1,egg11:!1,egg12:!1}),t.special.egg.hasOwnProperty(a)&&!t.special.egg[a].hasOwnProperty("egg13")&&(t.special.egg[a].egg13=!1,t.special.egg[a].egg14=!1,t.special.egg[a].egg15=!1),t.special.egg.hasOwnProperty(a)&&!t.special.egg[a].hasOwnProperty("egg16")&&(t.special.egg[a].egg16=!1,t.special.egg[a].egg17=!1,t.special.egg[a].egg18=!1);let r=Math.floor,i=a%19,s=r(a/100),n=(s-r(s/4)-r((8*s+13)/25)+19*i+15)%30,c=n-r(n/28)*(1-r(29/(n+1))*r((21-i)/11)),o=c-(a+r(a/4)+c+2-s+r(s/4))%7,l=3+r((o+40)/44),_=o+28-31*r(l/4),d={date:[l-1,_],active:!1,endDate:[l-1,_],hint:!1,hintDate:[l-1,_],solve:!1,solveDate:[l-1,_]};return t.settings.boring||(d.endDate[1]+=10,(2===d.endDate[0]&&d.endDate[1]>31||3===d.endDate[0]&&d.endDate[1]>30)&&(d.endDate[1]-=2===d.endDate[0]?31:30,d.endDate[0]++),d.hintDate[1]+=1,(2===d.hintDate[0]&&d.hintDate[1]>31||3===d.hintDate[0]&&d.hintDate[1]>30)&&(d.hintDate[1]-=2===d.hintDate[0]?31:30,d.hintDate[0]++),d.solveDate[1]+=3,(2===d.solveDate[0]&&d.solveDate[1]>31||3===d.solveDate[0]&&d.solveDate[1]>30)&&(d.solveDate[1]-=2===d.solveDate[0]?31:30,d.solveDate[0]++),e.getMonth()>=d.date[0]&&e.getDate()>=d.date[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.active=!0,e.getMonth()>=d.hintDate[0]&&e.getDate()>=d.hintDate[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.hint=!0),e.getMonth()>=d.solveDate[0]&&e.getDate()>=d.solveDate[1]&&e.getMonth()<=d.endDate[0]&&e.getDate()<=d.endDate[1]&&(d.solve=!0))),d}function ln(){const e=new Date;let a=e.getFullYear();t.special.trick.hasOwnProperty(a)||(t.special.trick[a]={trick1:!1,trick2:!1,trick3:!1,trick4:!1,trick5:!1,trick6:!1,trick7:!1,treat1:!1,treat2:!1,treat3:!1,treat4:!1,treat5:!1,treat6:!1,treat7:!1});let r={date:[9,28],active:!1,endDate:[10,4],hint:!1,hintDate:[9,29],solve:!1,solveDate:[9,31]};if(t.settings.boring)return r;let i=new Date(`${r.date[0]+1}/${r.date[1]}/${a}`),s=new Date(`${r.endDate[0]+1}/${r.endDate[1]}/${a}`);return e>=i&&e<=s&&(r.active=!0,e>=new Date(`${r.hintDate[0]+1}/${r.hintDate[1]}/${a}`)&&e<=s&&(r.hint=!0),e>=new Date(`${r.solveDate[0]+1}/${r.solveDate[1]}/${a}`)&&e<=s&&(r.solve=!0)),r}function _n(){return t.race.magnificent&&t.city.hasOwnProperty("shrine")&&t.city.shrine.count>0}function dn(e){let a={mult:1,add:0};if(_n())switch(e){case"metal":a.mult+=+t.city.shrine.metal/100*Ei.magnificent.vars()[3];break;case"tax":a.mult+=+t.city.shrine.tax/100*Ei.magnificent.vars()[2];break;case"know":a.add+=+t.city.shrine.know*Ei.magnificent.vars()[0],a.mult+=+t.city.shrine.know*Ei.magnificent.vars()[1]/100;break;case"morale":a.add+=t.city.shrine.morale*Ei.magnificent.vars()[4]}return a}const pn={promiscuous:!1,revive:!1,fast_growth:!1,spores:!1,terrifying:!1,fibroblast:!0,hivemind:!0,imitation:!0,elusive:!0,chameleon:!0,blood_thirst:!0,selenophobia:!0,hooved:!0,anthropophagite:!0,unfathomable:!1,darkness:!1,living_tool:!1};function un(e,a){let r=Ei[e].hasOwnProperty("vars")?Ei[e].vars(a):[];return pn.hasOwnProperty(e)&&("fibroblast"===e?r=[5*r[0]]:"hivemind"===e&&t.race.high_pop?r=[r[0]*Ei.high_pop.vars()[0]]:"imitation"===e?r.push(Ki[t.race.srace||"protoplasm"].name):"elusive"===e?r=[Math.round(100*(1/30/(1/(30+r[0]))-1))]:"chameleon"===e?r=[r[0],Math.round(100*(1/30/(1/(30+r[1]))-1))]:"blood_thirst"===e?r=[Math.ceil(Math.log2(r[0]))]:"selenophobia"===e?r=[14-r[0],r[0]]:"hooved"===e?r.unshift(hn()):"anthropophagite"===e?r=[1e4*r[0]]:pn[e]||(r=[])),r}function hn(e){return t.race.sludge?e?"craft":z("resource_Beaker_name"):"cath"===t.race.species?e?"craft":z("resource_Box_name"):"wolven"===t.race.species?e?"craft":z("resource_ChewToy_name"):"dracnid"===t.race.species?e?"craft":z("resource_Hoard_name"):"seraph"===t.race.species?e?"forge":z("resource_Halo_name"):"cyclops"===t.race.species?e?"craft":z("resource_Monocle_name"):"kobold"===t.race.species?e?"craft":z("resource_Candle_name"):"tuskin"===t.race.species?e?"craft":z("resource_Goggles_name"):"sharkin"===t.race.species?e?"craft":z("resource_ToothSharpener_name"):"humanoid"===Ki[t.race.species].type?e?"craft":z("resource_Sandals_name"):"avian"===Ki[t.race.species].type?e?"craft":z("resource_Perch_name"):"plant"===Ki[t.race.species].type?e?"craft":z("resource_Planter_name"):"fungi"===Ki[t.race.species].type?e?"craft":z("resource_DampCloth_name"):"reptilian"===Ki[t.race.species].type?e?"craft":z("resource_HeatRock_name"):"fey"===Ki[t.race.species].type?e?"craft":z("resource_PixieDust_name"):"synthetic"===Ki[t.race.species].type?e?"craft":z("resource_Battery_name"):e?"forge":z("resource_Horseshoe_name")}const mn={infiltrator:[z("wiki_trait_effect_infiltrator_ex1"),z("wiki_trait_effect_infiltrator_ex2",[[`${z("tech_steel")}`,`${z("tech_electricity")}`,`${z("tech_electronics")}`,`${z("tech_fission")}`,`${z("tech_rocketry")}`,`${z("tech_artificial_intelligence")}`,`${z("tech_quantum_computing")}`,`${z("tech_virtual_reality")}`,`${z("tech_shields")}`,`${z("tech_ai_core")}`,`${z("tech_graphene_processing")}`,`${z("tech_nanoweave")}`,`${z("tech_orichalcum_analysis")}`,`${z("tech_infernium_fuel")}`].join(", ")])],heavy:[z("wiki_trait_effect_heavy_ex1",[gn("Stone"),gn("Cement"),gn("Wrought_Iron")])],sniper:[z("wiki_trait_effect_sniper_ex1")],hooved:[z("wiki_trait_effect_hooved_ex1",[hn(!1)]),z("wiki_trait_effect_hooved_ex2",[`${t.resource.hasOwnProperty("Lumber")?t.resource.Lumber.name:z("resource_Lumber_name")}`,`${t.resource.hasOwnProperty("Copper")?t.resource.Copper.name:z("resource_Copper_name")}`,`${t.resource.hasOwnProperty("Iron")?t.resource.Iron.name:z("resource_Iron_name")}`,`${t.resource.hasOwnProperty("Steel")?t.resource.Steel.name:z("resource_Steel_name")}`,`${t.resource.hasOwnProperty("Adamantite")?t.resource.Adamantite.name:z("resource_Adamantite_name")}`,`${t.resource.hasOwnProperty("Orichalcum")?t.resource.Orichalcum.name:z("resource_Orichalcum_name")}`,12,75,150,500,5e3]),z("wiki_trait_effect_hooved_ex3"),z("wiki_trait_effect_hooved_ex4",['5',hn(!1)]),z("wiki_trait_effect_hooved_ex5",[`${t.resource.hasOwnProperty("Lumber")?t.resource.Lumber.name:z("resource_Lumber_name")}`,`${t.resource.hasOwnProperty("Copper")?t.resource.Copper.name:z("resource_Copper_name")}`])],instinct:[z("wiki_trait_effect_instinct_ex1",[6.67,z("galaxy_chthonian"),10])],logical:[z("wiki_trait_effect_logical_ex1",[t.tech.hasOwnProperty("science")?t.tech.science:0,t.tech.hasOwnProperty("high_tech")?t.tech.high_tech:0])],high_pop:[z("wiki_trait_effect_high_pop_ex1")],flier:[z("wiki_trait_effect_flier_ex1")],unfathomable:[z("wiki_trait_effect_unfathomable_ex1"),z("wiki_trait_effect_unfathomable_ex2")]};function gn(e){return`${t.hasOwnProperty("resource")&&t.resource.hasOwnProperty(e)?t.resource[e].name:z(`resource_${e}_name`)}`}function vn(e,a,r){let i=r.fanatic||!1,s=r.tpage||!1,n=r.trank||!1,c=r.wiki||!1,o="",l=as("name",a),_=as("desc",a);s&&["genus","major"].includes(Ei[a].type)&&(o=`«${z("wiki_trait_rank")} {{ rank }}»`),c&&e.append(`

                                ${l}

                                ${o}
                                `),c&&(s&&Ei[a].hasOwnProperty("val")?e.append(`
                                ${z(`wiki_trait_${Ei[a].type}`)}${z("wiki_trait_value",[Ei[a].val])}
                                `):e.append(`
                                ${z(`wiki_trait_${Ei[a].type}`)}
                                `)),i&&c&&e.append(`
                                ${z("wiki_trait_fanaticism",[i])}
                                `),e.append(`
                                ${_}
                                `);let d="warning";if(Ei[a].hasOwnProperty("val")&&(d=Ei[a].val>=0?"success":"danger"),s&&["genus","major"].includes(Ei[a].type)?e.append(`
                                `):(c||t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0)&&e.append(`
                                ${z(`wiki_trait_effect_${a}`,un(a,n))}
                                `),mn[a]&&c&&mn[a].forEach((function(t){e.append(`
                                ${t}
                                `)})),s&&["genus","major"].includes(Ei[a].type)){let e={rank:t.race[a]||1};Cs({el:`#${Ei[a].type}_${a}`,data:e,methods:{getTraitDesc:e=>z(`wiki_trait_effect_${a}`,un(a,e)),up(){switch(e.rank){case.25:e.rank=.5;break;case.5:e.rank=1;break;case 1:e.rank=2;break;case 2:case 3:e.rank=3}},down(){switch(e.rank){case.25:case.5:e.rank=.25;break;case 1:e.rank=.5;break;case 2:e.rank=1;break;case 3:e.rank=2}}}})}}const fn={misc:["apocalypse","ascended","dreaded","anarchist","second_evolution","blackhole","warmonger","red_tactics","pacifist","neutralized","paradise","scrooge","madagascar_tree","godwin","laser_shark","infested","mass_starvation","colonist","world_domination","illuminati","syndicate","cult_of_personality","doomed","pandemonium","blood_war","landfill","seeder","miners_dream","shaken","blacken_the_sun","trade","resonance","enlightenment","gladiator","corrupted","red_dead"],species:["mass_extinction","extinct_human","extinct_elven","extinct_orc","extinct_cath","extinct_wolven","extinct_vulpine","extinct_centaur","extinct_rhinotaur","extinct_capybara","extinct_kobold","extinct_goblin","extinct_gnome","extinct_ogre","extinct_cyclops","extinct_troll","extinct_tortoisan","extinct_gecko","extinct_slitheryn","extinct_arraak","extinct_pterodacti","extinct_dracnid","extinct_entish","extinct_cacti","extinct_pinguicula","extinct_sporgar","extinct_shroomi","extinct_moldling","extinct_mantis","extinct_scorpid","extinct_antid","extinct_sharkin","extinct_octigoran","extinct_dryad","extinct_satyr","extinct_phoenix","extinct_salamander","extinct_yeti","extinct_wendigo","extinct_tuskin","extinct_kamel","extinct_balorg","extinct_imp","extinct_seraph","extinct_unicorn","extinct_synth","extinct_nano","extinct_ghast","extinct_shoggoth","extinct_junker","extinct_sludge","extinct_custom"],genus:["creator","genus_humanoid","genus_carnivore","genus_herbivore","genus_small","genus_giant","genus_reptilian","genus_avian","genus_insectoid","genus_plant","genus_fungi","genus_aquatic","genus_fey","genus_heat","genus_polar","genus_sand","genus_demonic","genus_angelic","genus_synthetic","genus_eldritch"],planet:["explorer","biome_grassland","biome_oceanic","biome_forest","biome_desert","biome_volcanic","biome_tundra","biome_savanna","biome_swamp","biome_ashland","biome_taiga","biome_hellscape","biome_eden","atmo_toxic","atmo_mellow","atmo_rage","atmo_stormy","atmo_ozone","atmo_magnetic","atmo_trashed","atmo_elliptical","atmo_flare","atmo_dense","atmo_unstable","atmo_permafrost","atmo_retrograde"],universe:["vigilante","squished","double_density","cross","macro","marble","heavyweight","whitehole","heavy","canceled","eviltwin","microbang","pw_apocalypse","fullmetal","pass","soul_sponge","nightmare"],challenge:["joyless","steelen","dissipated","technophobe","wheelbarrow","iron_will","failed_history","banana","pathfinder","ashanddust","exodus","obsolete","bluepill","retired","gross","lamentis","overlord","adam_eve"]},yn={colonist:[nn("name")]},bn={trade:[750,50]},wn={};Object.keys(fn).forEach((function(e){fn[e].forEach((t=>wn[t]={name:z(`achieve_${t}_name`),desc:bn[t]?z(`achieve_${t}_desc`,bn[t]):z(`achieve_${t}_desc`),flair:yn[t]?z(`achieve_${t}_flair`,yn[t]):z(`achieve_${t}_flair`),type:e}))}));const kn={utopia:{name:z("feat_utopia_name"),desc:z("feat_utopia_desc"),flair:z("feat_utopia_flair")},take_no_advice:{name:z("feat_take_no_advice_name"),desc:z("feat_take_no_advice_desc"),flair:z("feat_take_no_advice_flair")},ill_advised:{name:z("feat_ill_advised_name"),desc:z("feat_ill_advised_desc"),flair:z("feat_ill_advised_flair")},organ_harvester:{name:z("feat_organ_harvester_name"),desc:z("feat_organ_harvester_desc"),flair:z("feat_organ_harvester_flair")},the_misery:{name:z("feat_the_misery_name"),desc:z("feat_the_misery_desc"),flair:z("feat_the_misery_flair")},energetic:{name:z("feat_energetic_name"),desc:z("feat_energetic_desc"),flair:z("feat_energetic_flair")},garbage_pie:{name:z("feat_garbage_pie_name"),desc:z("feat_garbage_pie_desc"),flair:z("feat_garbage_pie_flair")},finish_line:{name:z("feat_finish_line_name"),desc:z("feat_finish_line_desc"),flair:z("feat_finish_line_flair")},blank_slate:{name:z("feat_blank_slate_name"),desc:z("feat_blank_slate_desc"),flair:z("feat_blank_slate_flair")},supermassive:{name:z("feat_supermassive_name"),desc:z("feat_supermassive_desc"),flair:z("feat_supermassive_flair")},steelem:{name:z("feat_steelem_name"),desc:z("feat_steelem_desc"),flair:z("feat_steelem_flair")},banana:{name:z("feat_banana_name"),desc:z("feat_banana_desc",[500,500]),flair:z("feat_banana_flair")},rocky_road:{name:z("feat_rocky_road_name"),desc:z("feat_rocky_road_desc"),flair:z("feat_rocky_road_flair")},demon_slayer:{name:z("feat_demon_slayer_name"),desc:z("feat_demon_slayer_desc"),flair:z("feat_demon_slayer_flair")},equilibrium:{name:z("feat_equilibrium_name"),desc:z("feat_equilibrium_desc"),flair:z("feat_equilibrium_flair")},digital_ascension:{name:z("feat_digital_ascension_name"),desc:z("feat_digital_ascension_desc"),flair:z("feat_digital_ascension_flair")},novice:{name:z("feat_novice_name"),desc:z("feat_achievement_hunter_desc",[10]),flair:z("feat_novice_flair")},journeyman:{name:z("feat_journeyman_name"),desc:z("feat_achievement_hunter_desc",[25]),flair:z("feat_journeyman_flair")},adept:{name:z("feat_adept_name"),desc:z("feat_achievement_hunter_desc",[50]),flair:z("feat_adept_flair")},master:{name:z("feat_master_name"),desc:z("feat_achievement_hunter_desc",[75]),flair:z("feat_master_flair")},grandmaster:{name:z("feat_grandmaster_name"),desc:z("feat_achievement_hunter_desc",[100]),flair:z("feat_grandmaster_flair")},nephilim:{name:z("feat_nephilim_name"),desc:z("feat_nephilim_desc"),flair:z("feat_nephilim_flair")},twisted:{name:z("feat_twisted_name"),desc:z("feat_twisted_desc"),flair:z("feat_twisted_flair")},slime_lord:{name:z("feat_slime_lord_name"),desc:z("feat_slime_lord_desc"),flair:z("feat_slime_lord_flair")},annihilation:{name:z("feat_annihilation_name"),desc:z("feat_annihilation_desc"),flair:z("feat_annihilation_flair")},friday:{name:z("feat_friday_name"),desc:z("feat_friday_desc"),flair:z("feat_friday_flair")},valentine:{name:z("feat_love_name"),desc:z("feat_love_desc"),flair:z("feat_love_flair")},leprechaun:{name:z("feat_leprechaun_name"),desc:z("feat_leprechaun_desc"),flair:z("feat_leprechaun_flair")},easter:{name:z("feat_easter_name"),desc:z("feat_easter_desc"),flair:z("feat_easter_flair")},egghunt:{name:z("feat_egghunt_name"),desc:z("feat_egghunt_desc"),flair:z("feat_egghunt_flair")},launch_day:{name:z("feat_launch_day_name"),desc:z("feat_launch_day_desc"),flair:z("feat_launch_day_flair")},solstice:{name:z("feat_solstice_name"),desc:z("feat_solstice_desc"),flair:z("feat_solstice_flair")},firework:{name:z("feat_firework_name"),desc:z("feat_firework_desc"),flair:z("feat_firework_flair")},halloween:{name:z("feat_boo_name"),desc:z("feat_boo_desc"),flair:z("feat_boo_flair")},trickortreat:{name:z("feat_trickortreat_name"),desc:z("feat_trickortreat_desc"),flair:z("feat_trickortreat_flair")},thanksgiving:{name:z("feat_gobble_gobble_name"),desc:z("feat_gobble_gobble_desc"),flair:z("feat_gobble_gobble_flair")},xmas:{name:z("feat_xmas_name"),desc:z("feat_xmas_desc"),flair:z("feat_xmas_flair")},fool:{name:z("feat_fool_name"),desc:z("feat_fool_desc"),flair:z("feat_fool_flair")}};{let e=$n();e.aLvl,e.uLvl}function $n(e){let a=xn(e=e||t.race.universe),r=0,i=0;return Object.keys(wn).forEach((function(e){t.stats.achieve[e]&&(r+=t.stats.achieve[e].l>5?5:t.stats.achieve[e].l,t.stats.achieve[e][a]&&(i+=t.stats.achieve[e][a]>5?5:t.stats.achieve[e][a]))})),{aLvl:r,uLvl:i}}function xn(e){switch(e=e||t.race.universe){case"evil":return"e";case"antimatter":return"a";case"heavy":return"h";case"micro":return"m";case"magic":return"mg";default:return"l"}}function qn(e,a,r,i){if("micro"!==t.race.universe&&!0===a)return!1;t.settings.msgFilters.achievements.unlocked||(t.settings.msgFilters.achievements.unlocked=!0,t.settings.msgFilters.achievements.vis=!0);let s=Mn(),n=!1,c=!1;(void 0===r||r>s)&&(r=s);let o=!0;if(void 0===t.stats.achieve[e]&&(t.stats.achieve[e]={l:0},o=!1),("micro"===t.race.universe&&!0===a||"micro"!==t.race.universe&&!0!==a)&&t.stats.achieve[e]&&t.stats.achieve[e].li)&&(r=i),!t.stats.feat[e]||t.stats.feat[e]&&t.stats.feat[e]5?5:t.stats.achieve[e].l,t.stats.achieve[e][c]&&(n+=t.stats.achieve[e][c]>5?5:t.stats.achieve[e][c]);let i=Xs(e,16,l,o);o&&t.stats.achieve[e].l>1||!o?a.append($(`
                                ${wn[e].name}${wn[e].desc}${i}
                                `)):o&&1===t.stats.achieve[e].l&&r--}})),o&&!t.stats.feat.fool){let e=$(`
                                ${kn.fool.name}${z("feat_fool_spoof")}
                                `);a.append(e)}else Object.keys(kn).forEach((function(e){let r=Vs(e,"feat");if(t.stats.feat[e]){let i=t.stats.feat[e]>1?`

                                ${Hs(r)}

                                `:"";if("easter"===e){let e=Qs(4,14);e.length>0&&(i=e)}a.append($(`
                                ${kn[e].name}${kn[e].desc}${i}
                                `))}}));let l=Js(5,12,!1);a.prepend(`
                                ${z("achieve_draw_achieve_earned",[r,i])}${l}
                                `),Cs({el:"#achievePanel",methods:{flair:e=>wn[e].flair,feat:e=>kn[e].flair}}),o&&!t.stats.feat.fool&&$("#thefool").on("mouseover",(function(){"micro"===t.race.universe?Pn("fool",!0):Pn("fool"),jn()}))}function On(){let e=Mn();$("#topBar span.flair")&&Ss($("#topBar span.flair"),!0);let a=Qs(1,14);if(a.length>0&&$("#topBar .planet").after($(a)),e>1&&0===$("#topBar .planet .flair").length){if(0===a.length){let t=Vs("topbar","challenge");$("#topBar .planet").after(`${Hs(t)}`)}let r="";t.race.no_plasmid&&(r+=`
                                ${z("evo_challenge_plasmid")}
                                `),t.race.weak_mastery&&(r+=`
                                ${z("evo_challenge_mastery")}
                                `),t.race.no_trade&&(r+=`
                                ${z("evo_challenge_trade")}
                                `),t.race.no_craft&&(r+=`
                                ${z("evo_challenge_craft")}
                                `),t.race.no_crispr&&(r+=`
                                ${z("evo_challenge_crispr")}
                                `),t.race.nerfed&&(r+=`
                                ${z("evo_challenge_nerfed")}
                                `),t.race.badgenes&&(r+=`
                                ${z("evo_challenge_badgenes")}
                                `),r.length>0&&$("#topBar .planetWrap .flair").append($(`
                                Active Challenge Genes
                                ${r}
                                `)),ls("topbarPlanet",(function(e){let t=$('
                                ');e.popper.append(t),t.append($(r))}),{elm:"#topBar .planetWrap .flair",classes:"has-background-light has-text-dark"})}}function Mn(){let e=1;return t.race.no_plasmid&&e++,t.race.no_trade&&e++,t.race.no_craft&&e++,t.race.no_crispr&&e++,t.race.weak_mastery&&e++,t.race.nerfed&&e++,t.race.badgenes&&e++,e>5&&(e=5),e}function Sn(){let e=Mn();for(let a=e;a>=0;a--)Cn("extinct_","mass_extinction",25,a),"evil"===t.race.universe&&zn("extinct_","vigilante",12,a),Cn("genus_","creator",9,a),Cn("biome_","explorer",6,a),"heavy"===t.race.universe&&zn("genus_","heavyweight",8,a);if(t.tech.supercollider&&t.tech.supercollider>=99&&qn("blackhole"),t.stats.starved>=100&&qn("mass_starvation"),Math.round(Math.log2(t.civic.garrison.protest+t.civic.garrison.fatigue))>=8&&qn("warmonger"),t.stats.died>=250&&qn("red_tactics"),t.interstellar.stellar_engine&&t.interstellar.stellar_engine.mass>=12&&qn("landfill"),t.interstellar.stellar_engine&&t.interstellar.stellar_engine.mass>=100&&Pn("supermassive"),t.tech.piracy&&t.tech.chthonian&&t.tech.chthonian>=2&&t.galaxy&&1===Mt("gxy_stargate")&&1===Mt("gxy_gateway")&&1===Mt("gxy_gorddon")&&1===Mt("gxy_alien1")&&1===Mt("gxy_alien2")&&1===Mt("gxy_chthonian")&&qn("neutralized"),cn("summer")&&t.resource.hasOwnProperty("Thermite")){let e=1e5+9e3*t.stats.reset;e>1e6&&(e=1e6),t.resource.Thermite.amount>e&&Pn("solstice","micro"===t.race.universe)}if(cn("firework")&&t[t.race.cataclysm||t.race.orbit_decayed?"space":"city"].firework.on>0&&Pn("firework","micro"===t.race.universe),t.city.morale.current>=200&&(qn("paradise"),t.city.morale.current>=500&&Pn("utopia")),t.resource.hasOwnProperty("Money")&&t.resource.Money.amount>=1e9&&qn("scrooge"),t.resource.hasOwnProperty("Money")&&t.race.inflation&&t.resource.Money.amount>=25e10&&qn("wheelbarrow"),t.civic.hasOwnProperty("govern")&&t.galaxy.hasOwnProperty("trade")&&t.city.hasOwnProperty("market")&&t.galaxy.trade.cur>=50&&t.city.market.trade>=750&&"federation"===t.civic.govern.type&&qn("trade"),t.tech.pillars){let e={},a=0,r=5;if(Object.keys(t.pillars).forEach((function(i){Ki[i]&&((!e[Ki[i].type]||t.pillars[i]>e[Ki[i].type])&&(e[Ki[i].type]=t.pillars[i]),t.pillars[i]=Object.keys(Li).length){let t=5;Object.keys(e).forEach((function(a){e[a]=Object.keys(Ki).length-1&&qn("resonance"),a>=50&&Pn("equilibrium",!1,r)}if(t.portal.hasOwnProperty("mechbay")&&t.tech.hasOwnProperty("hell_spire")&&t.tech.hell_spire>=9){let e=Object.keys(va).length,a={};Object.keys(t.stats.spire).forEach((function(r){let i={};Object.keys(t.stats.spire[r]).forEach((function(e){va[e]&&((!a.hasOwnProperty(e)||a[e]0&&(i[e]=t.stats.spire[r][e]))})),Object.keys(i).length===e&&qn("gladiator",!1,Math.min(...Object.values(i)),r)})),Object.keys(a).length===e&&qn("gladiator",!1,Math.min(...Object.values(a)),"l")}if(t.race.banana){let e=xn();t.tech.hasOwnProperty("monuments")&&t.tech.monuments>=50&&(t.stats.banana.b5[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b5.l=!0));let a=0,r=0;["b1","b2","b3","b4","b5"].forEach((function(i){t.stats.banana[i].l&&a++,"l"!==e&&t.stats.banana[i][e]&&r++})),a>0&&qn("banana",!1,a,"l"),r>0&&"l"!==e&&qn("banana",!1,r,e),t.interstellar.hasOwnProperty("stellar_engine")&&t.interstellar.stellar_engine.mass>=12&&0===t.interstellar.stellar_engine.exotic&&(t.stats.banana.b3[e]=!0,"m"!==e&&"l"!==e&&(t.stats.banana.b3.l=!0))}["l",xn()].forEach((function(e){let a=0;["ashanddust","exodus","obsolete","bluepill","retired"].forEach((function(r){t.stats.achieve[r]&&t.stats.achieve[r][e]&&t.stats.achieve[r][e]>=5&&a++})),a>0&&qn("pathfinder",!1,a,e)}));const a=new Date;let r=cn("easter"),i=cn("halloween"),s=a.getFullYear();if(!t.settings.boring&&13===a.getDate()&&5===a.getDay()&&t.resource[t.race.species].amount>=1){let e=!1;e=Pn("friday","micro"===t.race.universe),e&&t.resource[t.race.species].amount--}else if(t.settings.boring||1!==a.getMonth()||14!==a.getDate())if(t.settings.boring||2!==a.getMonth()||17!==a.getDate())if(r.active){Pn("easter","micro"===t.race.universe);let e=0;for(let a=1;a<=18;a++)t.special.egg[s][`egg${a}`]&&e++;e>=12&&Pn("egghunt","micro"===t.race.universe)}else if(cn("launch_day"))Pn("launch_day","micro"===t.race.universe);else if(i.active){let e=0;for(let a=1;a<=7;a++)t.special.trick[s][`trick${a}`]&&e++;for(let a=1;a<=7;a++)t.special.trick[s][`treat${a}`]&&e++;e>=12&&Pn("trickortreat","micro"===t.race.universe),9===a.getMonth()&&31===a.getDate()&&Pn("halloween","micro"===t.race.universe)}else!t.settings.boring&&10===a.getMonth()&&a.getDate()>=22&&a.getDate()<=28?Pn("thanksgiving","micro"===t.race.universe):t.settings.boring||11!==a.getMonth()||25!=a.getDate()||Pn("xmas","micro"===t.race.universe);else Pn("leprechaun","micro"===t.race.universe);else Pn("valentine","micro"===t.race.universe);!t.settings.boring&&3===a.getMonth()&&a.getDate()>=1&&a.getDate()<=3&&t.stats.feat.hasOwnProperty("fool")&&t.stats.feat.fool>0&&Pn("fool","micro"===t.race.universe),t.stats.dkills>=666e6&&Pn("demon_slayer");for(let a=e;a>=1;a--){let e=0;const r=Object.keys(wn);for(const i of r)t.stats.achieve[i]&&t.stats.achieve[i].l>=a&&e++;let i=[{c:10,f:"novice"},{c:25,f:"journeyman"},{c:50,f:"adept"},{c:75,f:"master"},{c:100,f:"grandmaster"}];for(let r=0;r<5;r++)e>=i[r].c&&(!t.stats.feat[i[r].f]||t.stats.feat[i[r].f]=i&&s++;if(s>=r&&(qn(a,!1,i),"standard"!==t.race.universe))switch(t.race.universe){case"evil":t.stats.achieve[a].e=void 0;break;case"antimatter":t.stats.achieve[a].a=void 0;break;case"heavy":t.stats.achieve[a].h=void 0;break;case"micro":t.stats.achieve[a].m=void 0;break;case"magic":t.stats.achieve[a].mg=void 0}}"standard"!==t.race.universe&&zn(e,a,r,i)}function zn(e,a,r,i){let s=!1;switch(t.race.universe){case"evil":(void 0===t.stats.achieve[a]||void 0===t.stats.achieve[a].e||t.stats.achieve[a].e=i&&s++;break;case"antimatter":t.stats.achieve[a]&&t.stats.achieve[a].a&&t.stats.achieve[a].a>=i&&s++;break;case"heavy":t.stats.achieve[a]&&t.stats.achieve[a].h&&t.stats.achieve[a].h>=i&&s++;break;case"micro":t.stats.achieve[a]&&t.stats.achieve[a].m&&t.stats.achieve[a].m>=i&&s++;break;case"magic":t.stats.achieve[a]&&t.stats.achieve[a].mg&&t.stats.achieve[a].mg>=i&&s++}s>=r&&qn(a,!1,i)}}const Fn={mastery:{name:z("mastery"),desc(){let e="";return Object.keys(Wt).forEach((function(a){let r=Es(a,!0);"standard"===a?e+=`${Wt[a].name}: ${z("perks_mastery_general",[`${+r.g.toFixed(2)}%`])}`:t.stats.achieve.whitehole&&(e+=`${Wt[a].name}: ${z("perks_mastery_general",[`${+r.g.toFixed(2)}%`])}, ${z("perks_mastery_universe",[`${+r.u.toFixed(2)}%`])}`)})),e},active:()=>!!(t.genes.challenge&&t.genes.challenge>=2),notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_unlocked_title")}`])]},blackhole:{name:z("achieve_blackhole_name"),desc:e=>z("achieve_perks_blackhole",[e?"5/10/15/20/25":t.stats.achieve.blackhole?5*t.stats.achieve.blackhole.l:5]),active:()=>!!(t.stats.achieve.blackhole&&t.stats.achieve.blackhole.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_blackhole_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_blackhole_name")}`])]},trade:{name:z("achieve_trade_name"),desc:e=>z("achieve_perks_trade",[e?"2/4/6/8/10":t.stats.achieve.trade?2*t.stats.achieve.trade.l:2,e?"1/2/3/4/5":t.stats.achieve.trade?t.stats.achieve.trade.l:1]),active:()=>!!(t.stats.achieve.trade&&t.stats.achieve.trade.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_trade_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_trade_name")}`])]},creator:{name:z("achieve_creator_name"),desc:e=>z("achieve_perks_creator",[e?"1.5/2/2.5/3/3.5":1+(t.stats.achieve.creator?.5*t.stats.achieve.creator.l:.5)]),active:()=>!!(t.stats.achieve.creator&&t.stats.achieve.creator.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_creator_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_creator_name")}`])]},mass_extinction:{name:z("achieve_mass_extinction_name"),group:[{desc:()=>z("achieve_perks_mass_extinction"),active:()=>!!(t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>=1)},{desc(e){let a=t.stats.achieve.mass_extinction?t.stats.achieve.mass_extinction.l:1;return z("achieve_perks_mass_extinction2",[e?"0/50/100/150/200":50*(a-1)])},active:()=>!!(t.stats.achieve.mass_extinction&&t.stats.achieve.mass_extinction.l>1)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_mass_extinction_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_mass_extinction_name")}`])]},doomed:{name:z("achieve_doomed_name"),desc:e=>z("achieve_perks_doomed"),active:()=>t.stats.portals>=1,notes:[z("wiki_perks_achievement_note",[`${z("achieve_doomed_name")}`])]},explorer:{name:z("achieve_explorer_name"),desc:e=>z("achieve_perks_explorer",[e?"1/2/3/4/5":t.stats.achieve.explorer?t.stats.achieve.explorer.l:1]),active:()=>!!(t.stats.achieve.explorer&&t.stats.achieve.explorer.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_explorer_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_explorer_name")}`])]},miners_dream:{name:z("achieve_miners_dream_name"),desc:e=>z("achieve_perks_miners_dream",[e?"1/2/3/5/7":t.stats.achieve.miners_dream?t.stats.achieve.miners_dream.l>=4?2*t.stats.achieve.miners_dream.l-3:t.stats.achieve.miners_dream.l:0]),active:()=>!!(t.stats.achieve.miners_dream&&t.stats.achieve.miners_dream.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_miners_dream_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_miners_dream_name")}`])]},extinct_junker:{name:z("achieve_extinct_junker_name"),desc:()=>z("achieve_perks_enlightened"),active:()=>!!(t.stats.achieve.extinct_junker&&t.stats.achieve.extinct_junker.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_extinct_junker_name")}`])]},joyless:{name:z("achieve_joyless_name"),desc:e=>z("achieve_perks_joyless",[e?"2/4/6/8/10":t.stats.achieve.joyless?2*t.stats.achieve.joyless.l:2]),active:()=>!!(t.stats.achieve.joyless&&t.stats.achieve.joyless.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_joyless_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_joyless_name")}`])]},steelen:{name:z("achieve_steelen_name"),desc:e=>z("achieve_perks_steelen",[e?"2/4/6/8/10":t.stats.achieve.steelen?2*t.stats.achieve.steelen.l:2]),active:()=>!!(t.stats.achieve.steelen&&t.stats.achieve.steelen.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_steelen_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_steelen_name")}`])]},wheelbarrow:{name:z("achieve_wheelbarrow_name"),desc:e=>z("achieve_perks_wheelbarrow",[e?"2/4/6/8/10":t.stats.achieve.wheelbarrow?2*t.stats.achieve.wheelbarrow.l:2]),active:()=>!!(t.stats.achieve.wheelbarrow&&t.stats.achieve.wheelbarrow.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_wheelbarrow_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_wheelbarrow_name")}`])]},extinct_sludge:{name:z("achieve_extinct_sludge_name"),group:[{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.l:3,z("universe_standard")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.l>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.h:3,z("universe_heavy")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.h>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.a:3,z("universe_antimatter")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.a>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.e:3,z("universe_evil")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.e>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.m:3,z("universe_micro")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.m>=1)},{desc:e=>z("achieve_perks_extinct_sludge",[e?"3/6/9/12/15":t.stats.achieve.extinct_sludge?3*t.stats.achieve.extinct_sludge.mg:3,z("universe_magic")]),active:()=>!!(t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge.mg>=1)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_extinct_sludge_name")}`]),z("wiki_perks_achievement_note_universe_scale",[`${z("achieve_extinct_sludge_name")}`])]},whitehole:{name:z("achieve_whitehole_name"),group:[{desc:()=>z("achieve_perks_whitehole"),active:()=>!!t.stats.achieve.whitehole},{desc:e=>z("achieve_perks_whitehole2",[e?"5/10/15/20/25":t.stats.achieve.whitehole?5*t.stats.achieve.whitehole.l:5]),active:()=>!!t.stats.achieve.whitehole},{desc:e=>z("achieve_perks_whitehole3",[e?"1/2/3/4/5":t.stats.achieve.whitehole?t.stats.achieve.whitehole.l:1]),active:()=>!!t.stats.achieve.whitehole}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_whitehole_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_whitehole_name")}`])]},heavyweight:{name:z("achieve_heavyweight_name"),desc:e=>z("achieve_perks_heavyweight",[e?"4/8/12/16/20":t.stats.achieve.heavyweight?4*t.stats.achieve.heavyweight.l:4]),active:()=>!!t.stats.achieve.heavyweight,notes:[z("wiki_perks_achievement_note",[`${z("achieve_heavyweight_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_heavyweight_name")}`])]},dissipated:{name:z("achieve_dissipated_name"),group:[{desc:()=>z("achieve_perks_dissipated1",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=1)},{desc:e=>z("achieve_perks_dissipated2",[e?"1/2":t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=5?2:1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=3)},{desc:()=>z("achieve_perks_dissipated3",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=2)},{desc:()=>z("achieve_perks_dissipated4",[1]),active:()=>!!(t.stats.achieve.dissipated&&t.stats.achieve.dissipated.l>=4)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_dissipated_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_dissipated_name")}`])]},banana:{name:z("achieve_banana_name"),group:[{desc:()=>z("achieve_perks_banana1",[50]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=1)},{desc:()=>z("achieve_perks_banana2",[1]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=2)},{desc:()=>z("achieve_perks_banana3",[10]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=3)},{desc:()=>z("achieve_perks_banana4",[3]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=4)},{desc:()=>z("achieve_perks_banana5",[.01]),active:()=>!!(t.stats.achieve.banana&&t.stats.achieve.banana.l>=5)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_banana_name")}`]),z("wiki_perks_achievement_note_task",[`${z("achieve_banana_name")}`]),z("wiki_perks_achievement_note_task_num",[1,`${z("wiki_achieve_banana1")}`]),z("wiki_perks_achievement_note_task_num",[2,`${z("wiki_achieve_banana2")}`]),z("wiki_perks_achievement_note_task_num",[3,`${z("wiki_achieve_banana3")}`]),z("wiki_perks_achievement_note_task_num",[4,`${z("wiki_achieve_banana4",[500])}`]),z("wiki_perks_achievement_note_task_num",[5,`${z("wiki_achieve_banana5",[50])}`])]},anarchist:{name:z("achieve_anarchist_name"),desc:e=>z("achieve_perks_anarchist",[e?"10/20/30/40/50":t.stats.achieve.anarchist?10*t.stats.achieve.anarchist.l:10]),active:()=>!!(t.stats.achieve.anarchist&&t.stats.achieve.anarchist.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_anarchist_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_anarchist_name")}`])]},ascended:{name:z("achieve_ascended_name"),group:[{desc(e){let a;if(e)a="1-30";else if(a=0,t.stats.achieve.ascended)for(let e=0;e!!(t.stats.achieve.ascended&&t.stats.achieve.ascended.l>=1)},{desc:()=>z("achieve_perks_ascended2",[js()]),active:()=>!!(t.stats.achieve.ascended&&t.stats.achieve.ascended[xn()]>=1)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_ascended_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_ascended_name")}`]),z("wiki_perks_achievement_note_universe",[`${z("achieve_ascended_name")}`])]},technophobe:{name:z("achieve_technophobe_name"),group:[{desc:()=>z("achieve_perks_technophobe1",[25]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1)},{desc(e){let a;if(e)a="10/25/30/35/40/45/50";else{a=t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=4?25:10;for(let e=1;e=5&&(a+=5)}return z("achieve_perks_technophobe2",[a])},active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=2)},{desc(e){let a;if(e)a="1/2/3/4/5/6";else{a=1;for(let e=1;e=5&&(a+=1)}return z(e||a>1?"achieve_perks_technophobe3a":"achieve_perks_technophobe3",[a])},active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=3)},{desc:()=>z("achieve_perks_technophobe4",[10]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=5)},{desc:e=>z("achieve_perks_technophobe5",[e?"1/2/3/4/5":t.stats.achieve.technophobe?t.stats.achieve.technophobe.l:0]),active:()=>!!(t.stats.achieve.technophobe&&t.stats.achieve.technophobe.l>=1)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_technophobe_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_technophobe_name")}`]),z("wiki_perks_achievement_note_universe",[`${z("achieve_technophobe_name")}`])]},iron_will:{name:z("achieve_iron_will_name"),group:[{desc:()=>z("achieve_perks_iron_will1",[.15]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=1)},{desc:()=>z("achieve_perks_iron_will2",[10]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=2)},{desc:()=>z("achieve_perks_iron_will3",[6]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=3)},{desc:()=>z("achieve_perks_iron_will4",[1]),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=4)},{desc:()=>z("achieve_perks_iron_will5"),active:()=>!!(t.stats.achieve.iron_will&&t.stats.achieve.iron_will.l>=5)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_iron_will_name")}`]),z("wiki_perks_achievement_note_ironwill",[`${z("evo_challenge_cataclysm")}`]),z("wiki_perks_achievement_note_ironwill2",[1,`${z("space_red_ziggurat_title")}`]),z("wiki_perks_achievement_note_ironwill3",[2,`${z("tech_elerium_mining")}`]),z("wiki_perks_achievement_note_ironwill3",[3,`${z("tech_lasers")}`]),z("wiki_perks_achievement_note_ironwill3",[4,`${z("tech_generational_ship")}`]),z("wiki_perks_achievement_note_ironwill4",[5,`${z("wiki_resets_bioseed")}`])]},failed_history:{name:z("achieve_failed_history_name"),desc:()=>z("achieve_perks_failed_history",[2]),active:()=>!!(t.stats.achieve.failed_history&&t.stats.achieve.failed_history.l>=5),notes:[z("wiki_perks_achievement_note",[`${z("achieve_failed_history_name")}`]),z("wiki_perks_achievement_note_failed_history",[`${z("evo_challenge_cataclysm")}`])]},lamentis:{name:z("achieve_lamentis_name"),group:[{desc:()=>z("achieve_perks_lamentis1",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=1)},{desc:()=>z("achieve_perks_lamentis2",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=2)},{desc:()=>z("achieve_perks_lamentis3",["10%"]),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=3)},{desc:()=>z("achieve_perks_lamentis4"),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=4)},{desc:()=>z("achieve_perks_lamentis5"),active:()=>!!(t.stats.achieve.lamentis&&t.stats.achieve.lamentis.l>=5)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_lamentis_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_lamentis_name")}`])]},soul_sponge:{name:z("achieve_soul_sponge_name"),desc:e=>z("achieve_perks_soul_sponge",[e?"100/200/300/400/500":t.stats.achieve.soul_sponge?100*t.stats.achieve.soul_sponge.mg:100]),active:()=>!!(t.stats.achieve.soul_sponge&&t.stats.achieve.soul_sponge.mg>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_soul_sponge_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_soul_sponge_name")}`])]},nightmare:{name:z("achieve_nightmare_name"),desc:()=>z("achieve_perks_nightmare"),active:()=>!!(t.stats.achieve.nightmare&&t.stats.achieve.nightmare.mg>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_nightmare_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_nightmare_name")}`])]},gladiator:{name:z("achieve_gladiator_name"),desc:e=>z("achieve_perks_gladiator",[e?"20/40/60/80/100":t.stats.achieve.gladiator?20*t.stats.achieve.gladiator.l:20]),active:()=>!!(t.stats.achieve.gladiator&&t.stats.achieve.gladiator.l>=1),notes:[z("wiki_perks_achievement_note",[`${z("achieve_gladiator_name")}`]),z("wiki_perks_achievement_note_scale",[`${z("achieve_gladiator_name")}`])]},pathfinder:{name:z("achieve_pathfinder_name"),group:[{desc:()=>z("achieve_perks_pathfinder1",[10]),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=1)},{desc:()=>z("achieve_perks_pathfinder2",[10]),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=2)},{desc:()=>z("achieve_perks_pathfinder3"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=3)},{desc:()=>z("achieve_perks_pathfinder4"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=4)},{desc:()=>z("achieve_perks_pathfinder5"),active:()=>!!(t.stats.achieve.pathfinder&&t.stats.achieve.pathfinder.l>=5)}],notes:[z("wiki_perks_achievement_note",[`${z("achieve_pathfinder_name")}`]),z("wiki_perks_achievement_note_pathfinder",[`${z("evo_challenge_truepath")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_mad")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_bioseed")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_ai")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_matrix")}`]),z("wiki_perks_achievement_note_pathfinder_reset",[`${z("wiki_resets_retired")}`])]},overlord:{name:z("achieve_overlord_name"),desc(){let e=`
                                ${z("achieve_perks_overlord1",[10])}
                                `;return e+=`
                                ${z("achieve_perks_overlord2")}
                                `,e+=`
                                ${z("achieve_perks_overlord3")}
                                `,e+=`
                                ${z("achieve_perks_overlord4")}
                                `,e},active:()=>!!(t.stats.achieve.overlord&&t.stats.achieve.overlord.l>=5),notes:[z("wiki_perks_achievement_note",[`${z("achieve_overlord_name")}`])]},adam_eve:{name:z("achieve_adam_eve_name"),desc:()=>z("achieve_perks_adam_eve"),active:()=>!!(t.stats.achieve.adam_eve&&t.stats.achieve.adam_eve.l>=5),notes:[]},creep:{name:z("wiki_arpa_crispr_creep"),desc:e=>z("arpa_perks_creep",[e?"0.01/0.02/0.03/0.04/0.05":t.genes.creep?.01*t.genes.creep:0]),active:()=>!!t.genes.creep,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_genetic_memory_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_animus_title")}`,`${z("arpa_genepool_divine_remembrance_title")}`,`${z("arpa_genepool_divine_proportion_title")}`,`${z("arpa_genepool_genetic_repository_title")}`].join(", ")])]},store:{name:z("wiki_arpa_crispr_store"),desc(e){let a=e?"0.04/0.06/0.08":t.genes.store&&t.genes.store>1?2===t.genes.store?.06:.08:.04;return z(t.genes.store&&t.genes.store>=4?"arpa_perks_store2":"arpa_perks_store1",[a])},active:()=>!!t.genes.store,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_spatial_reasoning_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_spatial_superiority_title")}`,`${z("arpa_genepool_spatial_supremacy_title")}`,`${z("arpa_genepool_dimensional_warping_title")}`].join(", ")])]},evolve:{name:z("wiki_arpa_crispr_evolve"),group:[{desc:()=>z("arpa_perks_evolve"),active:()=>!!t.genes.evolve},{desc:()=>z("arpa_genepool_recombination_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=2)},{desc:()=>z("arpa_genepool_homologous_recombination_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=3)},{desc:()=>z("arpa_genepool_genetic_reshuffling_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=4)},{desc:()=>z("arpa_genepool_recombinant_dna_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=5)},{desc:()=>z("arpa_genepool_chimeric_dna_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=6)},{desc:()=>z("arpa_genepool_molecular_cloning_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=7)},{desc:()=>z("arpa_genepool_transgenes_desc"),active:()=>!!(t.genes.evolve&&t.genes.evolve>=8)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_morphogenesis_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_recombination_title")}`,`${z("arpa_genepool_homologous_recombination_title")}`,`${z("arpa_genepool_genetic_reshuffling_title")}`,`${z("arpa_genepool_recombinant_dna_title")}`,`${z("arpa_genepool_chimeric_dna_title")}`,`${z("arpa_genepool_molecular_cloning_title")}`,`${z("arpa_genepool_transgenes_title")}`].join(", ")])]},birth:{name:z("wiki_arpa_crispr_birth"),desc:()=>z("arpa_perks_birth"),active:()=>!!t.genes.birth,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_replication_title")}`])]},enhance:{name:z("wiki_arpa_crispr_enhance"),desc:()=>z("arpa_perks_enhance"),active:()=>!!t.genes.enhance,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_enhanced_muscle_fiber_title")}`])]},crafty:{name:z("wiki_arpa_crispr_crafty"),group:[{desc:()=>z("arpa_genepool_artificer_desc"),active:()=>!!t.genes.crafty},{desc:e=>z("arpa_genepool_crafting_desc",[e?"50/100":t.genes.crafty&&t.genes.crafty>=3?100:50]),active:()=>!!(t.genes.crafty&&t.genes.crafty>=2)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_artificer_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_detail_oriented_title")}`,`${z("arpa_genepool_rigorous_title")}`].join(", ")])]},governor:{name:z("wiki_arpa_crispr_governor"),desc:()=>z("arpa_perks_governor"),active:()=>!!t.genes.governor,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_governance_title")}`])]},synthesis:{name:z("wiki_arpa_crispr_synthesis"),desc:e=>z("arpa_genepool_synthesis_desc",[e?"2/3/4":t.genes.synthesis&&t.genes.synthesis>=2?t.genes.synthesis>=3?4:3:2,e?"10/25/50":t.genes.synthesis&&t.genes.synthesis>=2?t.genes.synthesis>=3?50:25:10]),active:()=>!!t.genes.synthesis,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_synthesis_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_karyokinesis_title")}`,`${z("arpa_genepool_cytokinesis_title")}`].join(", ")])]},challenge:{name:z("wiki_arpa_crispr_challenge"),group:[{desc:()=>z("arpa_perks_challenge"),active:()=>!!t.genes.challenge},{desc:()=>z("arpa_genepool_unlocked_desc"),active:()=>!!(t.genes.challenge&&t.genes.challenge>=2)},{desc:e=>z("arpa_perks_challenge2",[e?"60/80":t.genes.challenge&&t.genes.challenge>=4?80:60,e?"60/40":t.genes.challenge&&t.genes.challenge>=4?40:60]),active:()=>!!(t.genes.challenge&&t.genes.challenge>=3)},{desc:()=>z("arpa_perks_challenge3"),active:()=>!!(t.genes.challenge&&t.genes.challenge>=5)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_hardened_genes_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_unlocked_title")}`,`${z("arpa_genepool_universal_title")}`,`${z("arpa_genepool_standard_title")}`,`${z("arpa_genepool_mastered_title")}`].join(", ")]),z("wiki_perks_crispr_note_challenge",[z("arpa_genepool_universal_title"),z("arpa_genepool_standard_title")])]},ancients:{name:z("wiki_arpa_crispr_ancients"),group:[{desc:()=>z("arpa_perks_ancients"),active:()=>!!t.genes.ancients},{desc:()=>t.genes.ancients&&t.genes.ancients>=4?z("arpa_perks_ancients3"):z("arpa_perks_ancients2"),active:()=>!!(t.genes.ancients&&t.genes.ancients>=2)},{desc:e=>z("arpa_perks_ancients4",[e?"25/50":t.genes.ancients&&t.genes.ancients>=5?50:25]),active:()=>!!(t.genes.ancients&&t.genes.ancients>=3)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_ancients_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_faith_title")}`,`${z("arpa_genepool_devotion_title")}`,`${z("arpa_genepool_acolyte_title")}`,`${z("arpa_genepool_conviction_title")}`].join(", ")])]},trader:{name:z("wiki_arpa_crispr_trader"),desc:()=>z("arpa_genepool_negotiator_desc"),active:()=>!!t.genes.trader,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_negotiator_title")}`])]},transcendence:{name:z("wiki_arpa_crispr_transcendence"),desc:()=>z("arpa_genepool_transcendence_desc"),active:()=>!!t.genes.transcendence,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_transcendence_title")}`])]},queue:{name:z("wiki_arpa_crispr_queue"),group:[{desc:()=>z("arpa_genepool_geographer_desc"),active:()=>!!t.genes.queue},{desc:()=>z("arpa_genepool_architect_desc"),active:()=>!!(t.genes.queue&&t.genes.queue>=2)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_geographer_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_architect_title")}`].join(", ")])]},plasma:{name:z("wiki_arpa_crispr_plasma"),desc:e=>z("arpa_genepool_mitosis_desc",[e?"3/5":t.genes.plasma>=2?5:3]),active:()=>!!t.genes.plasma,notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_mitosis_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_metaphase_title")}`].join(", ")])]},mutation:{name:z("wiki_arpa_crispr_mutation"),group:[{desc:()=>t.genes.mutation&&t.genes.mutation>1?z("arpa_perks_mutation2"):z("arpa_perks_mutation1"),active:()=>!!t.genes.mutation},{desc:()=>z("arpa_perks_mutation3"),active:()=>!!(t.genes.mutation&&t.genes.mutation>=3)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_mutation_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_transformation_title")}`,`${z("arpa_genepool_metamorphosis_title")}`].join(", ")])]},bleed:{name:z("wiki_arpa_crispr_bleed"),group:[{desc:()=>z("arpa_genepool_bleeding_effect_desc",[2.5]),active:()=>!!t.genes.bleed},{desc:()=>z("arpa_genepool_synchronicity_desc",[25]),active:()=>!!(t.genes.bleed&&t.genes.bleed>=2)},{desc:()=>z("arpa_genepool_astral_awareness_desc"),active:()=>!!(t.genes.bleed&&t.genes.bleed>=3)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_bleeding_effect_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_synchronicity_title")}`,`${z("arpa_genepool_astral_awareness_title")}`].join(", ")]),z("wiki_perks_crispr_note_bleed",[`${z("arpa_genepool_bleeding_effect_title")}`])]},blood:{name:z("wiki_arpa_crispr_blood"),group:[{desc:()=>z("arpa_genepool_blood_remembrance_desc"),active:()=>!!t.genes.blood},{desc:()=>z("arpa_genepool_blood_sacrifice_desc"),active:()=>!!(t.genes.blood&&t.genes.blood>=2)},{desc:()=>z("arpa_genepool_essence_absorber_desc"),active:()=>!!(t.genes.blood&&t.genes.blood>=3)}],notes:[z("wiki_perks_crispr_note",[`${z("arpa_genepool_blood_remembrance_title")}`]),z("wiki_perks_crispr_note_upgrade",[[`${z("arpa_genepool_blood_sacrifice_title")}`,`${z("arpa_genepool_essence_absorber_title")}`].join(", ")]),z("wiki_perks_crispr_note_blood",[z("arpa_genepool_blood_remembrance_title")])]},spire:{name:z("wiki_arpa_blood_spire"),group:[{desc:()=>z("arpa_blood_purify_desc"),active:()=>!!t.blood.spire},{desc:()=>z("arpa_blood_chum_desc"),active:()=>!!(t.blood.spire&&t.blood.spire>=2)}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_purify_title")}`]),z("wiki_perks_blood_note_upgrade",[[`${z("arpa_blood_chum_title")}`].join(", ")])]},lust:{name:z("wiki_arpa_blood_lust"),group:[{desc:e=>z("arpa_perks_lust",[e?.2:.2*(t.blood.lust?t.blood.lust:1)]),active:()=>!!t.blood.lust}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_lust_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_lust_title")])]},illuminate:{name:z("wiki_arpa_blood_illuminate"),group:[{desc:e=>z("arpa_perks_illuminate",[e?.01:.01*(t.blood.illuminate?t.blood.illuminate:1)]),active:()=>!!t.blood.illuminate}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_illuminate_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_illuminate_title")])]},greed:{name:z("wiki_arpa_blood_greed"),group:[{desc:e=>z("arpa_perks_greed",[e?1:1*(t.blood.greed?t.blood.greed:1)]),active:()=>!!t.blood.greed}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_greed_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_greed_title")])]},hoarder:{name:z("wiki_arpa_blood_hoarder"),group:[{desc:e=>z("arpa_perks_hoarder",[e?1:1*(t.blood.hoarder?t.blood.hoarder:1)]),active:()=>!!t.blood.hoarder}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_hoarder_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_hoarder_title")])]},artisan:{name:z("wiki_arpa_blood_artisan"),group:[{desc:e=>z("arpa_perks_artisan",[e?1:1*(t.blood.artisan?t.blood.artisan:1)]),active:()=>!!t.blood.artisan}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_artisan_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_artisan_title")])]},attract:{name:z("wiki_arpa_blood_attract"),group:[{desc:e=>z("arpa_perks_attract",[e?5:5*(t.blood.attract?t.blood.attract:1)]),active:()=>!!t.blood.attract}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_attract_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_attract_title")])]},wrath:{name:z("wiki_arpa_blood_wrath"),group:[{desc:e=>z("arpa_perks_wrath",[e?5:5*(t.blood.wrath?t.blood.wrath:1)]),active:()=>!!t.blood.wrath}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_wrath_title")}`]),z("wiki_perks_blood_note_repeat",[z("arpa_blood_wrath_title")])]},prepared:{name:z("wiki_arpa_blood_prepared"),group:[{desc:()=>z("arpa_blood_prepared_desc"),active:()=>!!t.blood.prepared},{desc:()=>z("arpa_blood_compact_desc"),active:()=>!!(t.blood.prepared&&t.blood.prepared>=2)}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_prepared_title")}`]),z("wiki_perks_blood_note_upgrade",[[`${z("arpa_blood_compact_title")}`].join(", ")])]},unbound:{name:z("wiki_arpa_blood_unbound"),group:[{desc:()=>z("arpa_blood_unbound_desc"),active:()=>!!t.blood.unbound},{desc:()=>z("arpa_blood_shadow_war_desc"),active:()=>!!(t.blood.unbound&&t.blood.unbound>=3)},{desc:e=>z("arpa_perks_unbound_resist",[e?"10/5":t.blood.unbound&&t.blood.unbound>=4?5:10]),active:()=>!!(t.blood.unbound&&t.blood.unbound>=2)}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_unbound_title")}`]),z("wiki_perks_blood_note_upgrade",[[`${z("arpa_blood_unbound_resistance_title")}`,`${z("arpa_blood_shadow_war_title")}`,`${z("arpa_blood_unbound_immunity_title")}`].join(", ")])]},aware:{name:z("wiki_arpa_blood_aware"),group:[{desc:()=>z("arpa_blood_blood_aware_desc"),active:()=>!!t.blood.aware}],notes:[z("wiki_perks_blood_note",[`${z("arpa_blood_blood_aware_title")}`])]},harmonic:{name:z("harmonic"),group:[{desc(e){let t=Ks();return z("perks_harmonic",[e?`1-${Object.keys(Ki).length+2}`:+(100*(t[0]-1)).toFixed(0),e?"2-"+2*(Object.keys(Ki).length+2):+(100*(t[1]-1)).toFixed(0)])},active(){let e=Ks();return!!(t.pillars&&e[0]>1)}},{desc:e=>(Ks(),z("perks_harmonic2",[z("portal_west_tower"),z("portal_east_tower"),e?"12-"+12*(Object.keys(Ki).length-1):12*Object.keys(t.pillars).length])),active(){let e=Ks();return!!(t.pillars&&e[0]>1)}}],notes:[z("wiki_perks_harmonic_note1"),z("wiki_perks_harmonic_note2")]},novice:{name:z("perk_novice"),desc(e){let a=t.stats.feat.novice&&t.stats.achieve.apocalypse&&t.stats.achieve.apocalypse.l>0?Math.min(t.stats.achieve.apocalypse.l,t.stats.feat.novice):1;return`
                                ${z("achieve_perks_novice",[e?"0.5/1/1.5/2/2.5":a/2,e?"0.25/0.5/0.75/1/1.25":a/4])}
                                ${z("achieve_perks_novice2")}
                                `},active:()=>!!(t.stats.feat.novice&&t.stats.mad>0),notes:[z("wiki_perks_progress_note1",[10,z("wiki_resets_mad")]),z("wiki_perks_progress_note2")]},journeyman:{name:z("perk_journeyman"),desc(e){let a=t.stats.feat.journeyman&&t.stats.achieve.seeder&&t.stats.achieve.seeder.l>0?Math.min(t.stats.achieve.seeder.l,t.stats.feat.journeyman):1;return e||a>1?`
                                ${z("achieve_perks_journeyman2",[e?"1/2/3":a>=3?a>=5?3:2:1,e?"1/2":a>=4?2:1])}
                                ${z("achieve_perks_journeyman3")}
                                `:`
                                ${z("achieve_perks_journeyman1",[1])}
                                ${z("achieve_perks_journeyman3")}
                                `},active:()=>!!(t.stats.feat.journeyman&&t.stats.bioseed>0),notes:[z("wiki_perks_progress_note1",[25,z("wiki_resets_bioseed")]),z("wiki_perks_progress_note2")]},adept:{name:z("perk_adept"),desc(e){let a=t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0?Math.min(t.stats.achieve.whitehole.l,t.stats.feat.adept):1;return z("achieve_perks_adept",[e?"100/200/300/400/500":100*a,e?"60/120/180/240/300":60*a])},active:()=>!!(t.stats.feat.adept&&t.stats.achieve.whitehole&&t.stats.achieve.whitehole.l>0),notes:[z("wiki_perks_progress_note1",[50,z("wiki_resets_blackhole")]),z("wiki_perks_progress_note2")]},master:{name:z("perk_master"),desc(e){let a=t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0?Math.min(t.stats.achieve.ascended.l,t.stats.feat.master):1;return z("achieve_perks_master",[e?"1/2/3/4/5":a,e?"2/4/6/8/10":2*a,z("evo_mitochondria_title"),z("evo_eukaryotic_title"),z("evo_membrane_title"),z("evo_organelles_title"),z("evo_nucleus_title")])},active:()=>!!(t.stats.feat.master&&t.stats.achieve.ascended&&t.stats.achieve.ascended.l>0),notes:[z("wiki_perks_progress_note1",[75,z("wiki_resets_ascension")]),z("wiki_perks_progress_note2")]},grandmaster:{name:z("perk_grandmaster"),desc(e){let a=t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0?Math.min(t.stats.achieve.corrupted.l,t.stats.feat.grandmaster):1;return z("achieve_perks_grandmaster",[e?"1/2/3/4/5":a])},active:()=>!!(t.stats.feat.grandmaster&&t.stats.achieve.corrupted&&t.stats.achieve.corrupted.l>0),notes:[z("wiki_perks_progress_note1",[100,z("wiki_resets_infusion")]),z("wiki_perks_progress_note2")]}};function An(){Ss($("#perksPanel"));let e=$("#perksPanel"),t=!1;Object.keys(Fn).forEach((function(a){if(Fn[a].hasOwnProperty("group")){let r=!1,i=$(`
                                ${Fn[a].name}
                                `);Fn[a].group.forEach((function(e){e.active()&&(r=!0,i.append($(`
                                ${e.desc()}
                                `)))})),r&&(t=!0,e.append(i))}else Fn[a].active()&&(t=!0,e.append($(`
                                ${Fn[a].name}${Fn[a].desc()}
                                `)))})),t||e.append($(`
                                ${z("perks_none")}
                                `))}function In(e,t,a){if(!t.hasOwnProperty("name"))return;if(!t.hasOwnProperty("template"))return;t.hasOwnProperty("paragraphs")||(t.paragraphs=0),t.hasOwnProperty("text")||(t.text={}),t.hasOwnProperty("rawtext")||(t.rawtext={}),t.hasOwnProperty("para_data")||(t.para_data={}),t.hasOwnProperty("data_color")||(t.data_color={}),t.hasOwnProperty("data_link")||(t.data_link={}),t.hasOwnProperty("h_level")||(t.h_level=3),t.hasOwnProperty("header")||(t.header=!1),t.hasOwnProperty("full")||(t.full=!1),t.hasOwnProperty("break")||(t.break=!1),t.hasOwnProperty("default_color")||(t.default_color="warning"),t.hasOwnProperty("examples")||(t.examples=!1);let r=!1;a?r=a:(r=$(`
                                `),t.h_level&&r.append(`${t.label?t.label:z(`wiki_${t.template}_${t.name}`)}`));let i=[{s:1,e:t.break?t.break[0]-1:t.paragraphs}];if(t.break)for(let e=0;e');for(let r=e.s;r<=e.e;r++)if((t.text[r]||t.rawtext[r]||t.para_data[r])&&Array.isArray(t.para_data[r])){let e=t.para_data[r];if(t.data_link[r]&&Array.isArray(t.data_link[r]))for(let a=0;a${e[a]}`);let i=t.data_color[r]&&Array.isArray(t.data_color[r])?t.data_color[r]:t.para_data[r].map((e=>t.default_color));for(let t=0;t${e[t]}`);let s=t.rawtext[r]?t.rawtext[r]:z(t.text[r]?t.text[r]:`wiki_${t.template}_${t.name}_para${r}`,e);a.append(`${s}`)}else{let e=t.rawtext[r]?t.rawtext[r]:z(t.text[r]?t.text[r]:`wiki_${t.template}_${t.name}_para${r}`);a.append(`${e}`)}r.append(a)})),t.examples&&(r.append($(`
                                ${z("wiki_examples")}
                                `)),t.examples.forEach((function(e){r.append($(`
                                - ${e}
                                `))}))),a||e.append(r),r}function Tn(e,a,r,i){let s="string"==typeof a.title?a.title:a.title();if(r)e.append(`

                                ${s}

                                ${r}
                                `);else if(i)e.append(`

                                ${s}

                                `);else{let r=t.tech[a.grant[0]]&&t.tech[a.grant[0]]>=a.grant[1];e.append(`

                                ${s}

                                ${r?`${z("wiki_arpa_purchased")}`:""}${z(`wiki_tech_tree_${a.grant[0]}`)}: ${a.grant[1]}
                                `)}let n="string"==typeof a.desc?a.desc:a.desc(!0);n!==s&&e.append(`
                                ${n}
                                `);let c=$('
                                '),o=!1;if(a.hasOwnProperty("effect")){if(i){let e="string"==typeof a.effect&&a.effect;!1!==e?c.append(`
                                ${e}
                                `):c.append('
                                '),o=!0}else{let e="string"==typeof a.effect?a.effect:a.effect(!0);!1!==e&&(c.append(`
                                ${e}
                                `),o=!0)}e.append(c)}if(a.hasOwnProperty("cost")){let r=Ns(a,!0),s=o?$(`
                                `):$(`
                                `),n="";i&&(s.append($(`

                                ${z("wiki_calc_cost")}

                                `)),n=$(`

                                ${z("wiki_calc_cost_creep")}

                                `));let l=!1,_=function(e,t,a,r,c){i?(s.append($(`
                                ${a}{{ r.${e}.cost }}
                                `)),n.append($(`
                                {{ r.${e}.creep }}
                                `)),l=!0):t>0&&(s.append($(`
                                ${a}${x(t,1)}
                                `)),l=!0)},d="has-text-success";Object.keys(r).forEach((function(e){if("Structs"===e){let t=r[e]();Object.keys(t).forEach((function(e){Object.keys(t[e]).forEach((function(a){let r=t[e][a].hasOwnProperty("on")?t[e][a].on:t[e][a].count,c="";if(t[e][a].hasOwnProperty("s")){let r=t[e][a].s;c="string"==typeof Mr[e][r][a].title?Mr[e][r][a].title:Mr[e][r][a].title()}else c="string"==typeof Mr[e][a].title?Mr[e][a].title:Mr[e][a].title();s.append($(`
                                ${c}: ${r}
                                `)),i&&n.append($(`
                                ${z("wiki_calc_none")}
                                `)),l=!0}))}))}else if(["Plasmid","Phage","Dark","Harmony","AICore","Artifact","Blood_Stone","AntiPlasmid"].includes(e)){let a=e;"Plasmid"===e&&"antimatter"===t.race.universe&&(a="AntiPlasmid"),_(e,r[e](),z(`resource_${a}_name`)+": ",d)}else if("Supply"===e)_(e,r[e](),z(`resource_${e}_name`)+": ",d);else if("Custom"===e)s.append($(`
                                ${r[e]().label}
                                `)),l=!0;else if("Morale"!==e&&"Army"!==e&&"Bool"!==e){let a="Species"===e?t.race.species:e,i="Money"===a?"$":("HellArmy"===e?z("fortress_troops"):t.resource[a].name)+": ";i=i.replace("_"," "),_(e,r[e](),i,d)}})),l&&(a.hasOwnProperty("effect")||e.append(c),c.append(s),i&&c.append(n))}}function Ln(e,t,a,r){if("create"===e){let e=t?"string"==typeof t?$(`#${t}`):t:$("#content");Ss(e),e.addClass("flex");let a=$('
                                '),r=$('
                                '),i=$("
                                  ");return e.append(a),e.append(r),r.append(i),a}{let e=$(`${r}`),s=$("
                                • ");s.append(e),$("#sideContent ul").append(s),i=a,e.click((function(){window.location.hash=`#${i}`,document.getElementById(i).scrollIntoView({block:"start",behavior:"smooth"})}))}var i}function En(e,t,a,r){Ln(e,t,a,"ᄂ"+r)}function Kn(e){return["moon","belt"].includes(e)?z("space_"+e+"_info_name"):["kuiper"].includes(e)?z("space_"+e+"_title"):Ut()[e]}function Dn(e,t,a,r){let i=$("
                                  ");e.append(i),i.append(`{{ vis | label }}`);let s=$(``);i.append(s);let n=document.getElementById(t+a+"Section"),c={vis:!1};return Cs({el:`#${t}${a}Button`,data:c,methods:{show(){"block"===n.style.display?(n.style.display="none",c.vis=!1):(n.style.display="block",c.vis=!0)}},filters:{label:e=>z(e?"wiki_reveal_hide":"wiki_reveal_show",[r])}}),s}function Bn(e,t,a,r){r=r||z("wiki_calc_insert_"+a);let i=$("
                                  ");e.append(i),i.append(`{{ vis | label }}`);let s=$(``);i.append(s);let n=document.getElementById(t+a+"Section"),c={vis:!1};return Cs({el:`#${t}${a}Button`,data:c,methods:{show(){"block"===n.style.display?(n.style.display="none",c.vis=!1):(n.style.display="block",c.vis=!0)}},filters:{label:e=>z(e?"wiki_calc_hide":"wiki_calc_show",[r])}}),s}function Gn(e){let t=$('
                                  '),a=(r=e,(i={name:"planet",template:"planet",paragraphs:4,full:!0,para_data:{2:[365,"25%"],3:[4],4:["200-600"]}}).hasOwnProperty("h_level")||(i.h_level=2),i.header=!0,In(r,i,undefined));var r,i;In(e,{name:"geology",template:"planet",label:z("wiki_menu_planets"),paragraphs:4,h_level:2,para_data:{2:[2],3:["-10%","+19%"],4:[7,"+44%"]}},a);let s=Rn(is,$(`

                                  ${z("wiki_planet_biome")}

                                  `)),n=Rn(ss,$(`

                                  ${z("wiki_planet_trait")}

                                  `));t.append(s),t.append(n),e.append(t)}Da(!0);const Nn={oceanic:["trait","genus"],forest:["genus"],desert:["trait","genus"],volcanic:["weather","genus"],tundra:["weather","genus"],savanna:["condition"],swamp:["trait","trait2","genus","condition"],ashland:["weather","trait","genus","condition"],taiga:["weather","genus","condition"],hellscape:["weather","genus","universe"],eden:["geology","genus","universe"],stormy:["trait"],ozone:["trait"],trashed:["trait"],elliptical:["trait"],flare:["event"],unstable:["trait","event"],permafrost:["trait"],retrograde:["trait"]};function Rn(e,t){return Object.keys(e).forEach((function(a){let r=e[a],i=$(`
                                  `);t.append(i),i.append(`

                                  ${r.label}

                                  `),i.append(`
                                  ${r.desc}
                                  `);let s=$('
                                  ');if(r.vars&&r.wiki)for(let e=0;e${z(`wiki_planet_${a}${e}`,[Hn(r.vars()[e],t)])}
                                  `))}i.append(s),Nn[a]&&Nn[a].forEach((function(e){i.append($(`
                                  ${z(`wiki_planet_${a}_${e}`)}
                                  `))}))})),t}function Hn(e,a){let r=e-1*("percent"===a||"inverted"===a?1:0);"inverted"!==a&&"inverted-decimal"!==a||(r*=-1,a="inverted"===a?"percent":"decimal");let i=(r>=0?"+":"")+r.toLocaleString(t.settings.locale,{style:a,maximumFractionDigits:2});return`${i}`}function Un(e,a){let r=Ln("create");switch(e){case"prehistoric":!function(e,a){let r="truepath"===a?"tp_structures":"structures";Object.keys(Mr.evolution).forEach((function(i){if(Mr.evolution[i].hasOwnProperty("title")&&("custom"!==i||t.hasOwnProperty("custom"))&&(!Mr.evolution[i].hasOwnProperty("wiki")||Mr.evolution[i].wiki)){let t=Mr.evolution[i].id.split("-"),s=$(`
                                  `);e.append(s),Tn(s,Mr.evolution[i],!1,!0),Wn(s,"prehistoric",i),Yn(s,i,"prehistoric",!1,a),Ln("add",`prehistoric-${r}`,t[1],"function"==typeof Mr.evolution[i].title?Mr.evolution[i].title():Mr.evolution[i].title)}}))}(r,a);break;case"planetary":!function(e,t){let a="truepath"===t?"tp_structures":"structures";Object.keys(Mr.city).forEach((function(r){if((!Mr.city[r].hasOwnProperty("wiki")||Mr.city[r].wiki)&&(!Mr.city[r].hasOwnProperty("path")||Mr.city[r].path.includes(t))){let i=Mr.city[r].id.split("-"),s=$(`
                                  `);e.append(s),Tn(s,Mr.city[r],!1,!0),Wn(s,"planetary",r),Yn(s,r,"planetary",!1,t),Ln("add",`planetary-${a}`,i[1],"function"==typeof Mr.city[r].title?Mr.city[r].title():Mr.city[r].title)}}))}(r,a);break;case"space":!function(e,t){let a="truepath"===t?"tp_structures":"structures";Object.keys(Mr.space).forEach((function(r){let i="string"==typeof Mr.space[r].info.name?Mr.space[r].info.name:Mr.space[r].info.name(),s="string"==typeof Mr.space[r].info.desc?Mr.space[r].info.desc:Mr.space[r].info.desc();Object.keys(Mr.space[r]).forEach((function(n){if("info"!==n&&(!Mr.space[r][n].hasOwnProperty("wiki")||Mr.space[r][n].wiki)&&(!Mr.space[r][n].hasOwnProperty("path")||Mr.space[r][n].path.includes(t))){let c=Mr.space[r][n].id.split("-"),o=$(`
                                  `);e.append(o),Tn(o,Mr.space[r][n],`${i}`,!0),Wn(o,"space",n),Yn(o,n,"space",r,t),Ln("add",`space-${a}`,c[1],"function"==typeof Mr.space[r][n].title?Mr.space[r][n].title():Mr.space[r][n].title),ls(`pop${Mr.space[r][n].id}`,$(`
                                  ${s}
                                  `))}}))})),Object.keys(Mr.starDock).forEach((function(r){if("info"!==r&&(!Mr.starDock[r].hasOwnProperty("wiki")||Mr.starDock[r].wiki)&&(!Mr.starDock[r].hasOwnProperty("path")||Mr.starDock[r].path.includes(t))){let i=Mr.starDock[r].id.split("-"),s=$(`
                                  `);e.append(s),Tn(s,Mr.starDock[r],`${z("space_gas_star_dock_title")}`,!0),Wn(s,"starDock",r),Yn(s,r,"starDock",!1,t),Ln("add",`space-${a}`,i[1],"function"==typeof Mr.starDock[r].title?Mr.starDock[r].title():Mr.starDock[r].title),ls(`pop${Mr.starDock[r].id}`,$(`
                                  ${z("space_gas_star_dock_wiki")}
                                  `))}}))}(r,a);break;case"interstellar":!function(e){Object.keys(Mr.interstellar).forEach((function(t){let a="string"==typeof Mr.interstellar[t].info.name?Mr.interstellar[t].info.name:Mr.interstellar[t].info.name(),r="string"==typeof Mr.interstellar[t].info.desc?Mr.interstellar[t].info.desc:Mr.interstellar[t].info.desc();Object.keys(Mr.interstellar[t]).forEach((function(i){if("info"!==i&&(!Mr.interstellar[t][i].hasOwnProperty("wiki")||Mr.interstellar[t][i].wiki)){let s=Mr.interstellar[t][i].id.split("-"),n=$(`
                                  `);e.append(n),Tn(n,Mr.interstellar[t][i],`${a}`,!0),Wn(n,"interstellar",i),Yn(n,i,"interstellar",t),Ln("add","interstellar-structures",s[1],"function"==typeof Mr.interstellar[t][i].title?Mr.interstellar[t][i].title():Mr.interstellar[t][i].title),ls(`pop${Mr.interstellar[t][i].id}`,$(`
                                  ${r}
                                  `))}}))}))}(r);break;case"intergalactic":!function(e){Object.keys(Mr.galaxy).forEach((function(t){let a="string"==typeof Mr.galaxy[t].info.name?Mr.galaxy[t].info.name:Mr.galaxy[t].info.name(),r="string"==typeof Mr.galaxy[t].info.desc?Mr.galaxy[t].info.desc:Mr.galaxy[t].info.desc();Object.keys(Mr.galaxy[t]).forEach((function(i){if("info"!==i&&(!Mr.galaxy[t][i].hasOwnProperty("wiki")||Mr.galaxy[t][i].wiki)){let s=Mr.galaxy[t][i].id.split("-"),n=$(`
                                  `);e.append(n),Tn(n,Mr.galaxy[t][i],`${a}`,!0),Wn(n,"intergalactic",i),Yn(n,i,"intergalactic",t),Ln("add","intergalactic-structures",s[1],"function"==typeof Mr.galaxy[t][i].title?Mr.galaxy[t][i].title():Mr.galaxy[t][i].title),ls(`pop${Mr.galaxy[t][i].id}`,$(`
                                  ${r}
                                  `))}}))}))}(r);break;case"hell":!function(e){Object.keys(Mr.portal).forEach((function(t){let a="string"==typeof Mr.portal[t].info.name?Mr.portal[t].info.name:Mr.portal[t].info.name(),r="string"==typeof Mr.portal[t].info.desc?Mr.portal[t].info.desc:Mr.portal[t].info.desc();Object.keys(Mr.portal[t]).forEach((function(i){if("info"!==i&&(!Mr.portal[t][i].hasOwnProperty("wiki")||Mr.portal[t][i].wiki)){let s=Mr.portal[t][i].id.split("-"),n=$(`
                                  `);e.append(n),Tn(n,Mr.portal[t][i],`${a}`,!0),Wn(n,"hell",i),Yn(n,i,"hell",t),Ln("add","hell-structures",s[1],"function"==typeof Mr.portal[t][i].title?Mr.portal[t][i].title():Mr.portal[t][i].title),ls(`pop${Mr.portal[t][i].id}`,$(`
                                  ${r}
                                  `))}}))}))}(r);break;case"tauceti":!function(e){Object.keys(Mr.tauceti).forEach((function(t){let a="string"==typeof Mr.tauceti[t].info.name?Mr.tauceti[t].info.name:Mr.tauceti[t].info.name(),r="string"==typeof Mr.tauceti[t].info.desc?Mr.tauceti[t].info.desc:Mr.tauceti[t].info.desc();Object.keys(Mr.tauceti[t]).forEach((function(i){if("info"!==i&&(!Mr.tauceti[t][i].hasOwnProperty("wiki")||Mr.tauceti[t][i].wiki)){let s=Mr.tauceti[t][i].id.split("-"),n=$(`
                                  `);e.append(n),Tn(n,Mr.tauceti[t][i],`${a}`,!0),Wn(n,"tauceti",i),Yn(n,i,"tauceti",t),Ln("add","tauceti-structures",s[1],"function"==typeof Mr.tauceti[t][i].title?Mr.tauceti[t][i].title():Mr.tauceti[t][i].title),ls(`pop${Mr.tauceti[t][i].id}`,$(`
                                  ${r}
                                  `))}}))}))}(r)}}const Vn={prehistoric:{},planetary:{slaughter:[z("wiki_structure_planetary_slaughter")]},space:{terraformer:[z("wiki_structure_space_terraformer")],terraform:[z("wiki_structure_space_terraformer")]},starDock:{geck:[z("wiki_structure_stardock_geck")]},interstellar:{},intergalactic:{},hell:{},tauceti:{}};function Wn(e,t,a){if(Vn[t].hasOwnProperty(a)){let r=$('
                                  ');e.append(r);for(let e=0;e${Vn[t][a][e]}`)}}const Qn={include:{prehistoric:["membrane","organelles","nucleus","eukaryotic_cell","mitochondria"]},exclude:{planetary:["food","lumber","stone","chrysotile","slaughter","slave_market",""],space:["test_launch","moon_mission","terraform","red_mission","hell_mission","sun_mission","gas_mission","gas_moon_mission","belt_mission","dwarf_mission","titan_mission","enceladus_mission","triton_mission","kuiper_mission","eris_mission","crashed_ship","digsite"],starDock:["prep_ship","launch_ship"],interstellar:["alpha_mission","proxima_mission","nebula_mission","neutron_mission","blackhole_mission","jump_ship","wormhole_mission","sirius_mission","sirius_b","ascend"],intergalactic:["gateway_mission","gorddon_mission","alien2_mission","chthonian_mission"],hell:["pit_mission","assault_forge","ruins_mission","gate_mission","lake_mission","spire_mission","bribe_sphinx","spire_survey","spire"],tauceti:["home_mission","dismantle","excavate","alien_outpost","red_mission","matrix","roid_mission","alien_station_survey","contact","introduce","subjugate","gas_contest","gas_contest2","ignite_gas_giant","jeff","goe_facility"]},excludeCreep:{planetary:["horseshoe"],space:["horseshoe"],hell:["ancient_pillars","sphinx","waygate"],tauceti:["horseshoe"]},max:{prehistoric:{},planetary:{s_alter:1},space:{star_dock:1,terraformer:100,world_collider:1859,shipyard:1,mass_relay:100,fob:1,ai_core:100,jump_gate:100},starDock:{seeder:100},interstellar:{dyson:100,dyson_sphere:100,orichalcum_sphere:100,stellar_engine:100,stargate:200,space_elevator:100,gravity_dome:100,ascension_machine:100},intergalactic:{embassy:1,consulate:1},hell:{soul_forge:1,vault:2,ancient_pillars:Object.keys(Ki).length-1,west_tower:oa(),east_tower:oa(),bridge:10,sphinx:2,waygate:10},tauceti:{alien_outpost:1,jump_gate:100,ringworld:1e3,alien_station:100,matrioshka_brain:1e3,ignition_device:10}},count:{planetary:{horseshoe:t.race.shoecnt?t.race.shoecnt:0,assembly:t.resource[t.race.species]?t.resource[t.race.species].amount:0},space:{horseshoe:t.race.shoecnt?t.race.shoecnt:0,assembly:t.resource[t.race.species]?t.resource[t.race.species].amount:0},interstellar:{},intergalactic:{},hell:{ancient_pillars:Object.keys(t.pillars).length,sphinx:!t.tech.hell_spire||t.tech.hell_spire<7?0:7===t.tech.hell_spire?1:2,waygate:t.tech.waygate&&t.tech.waygate>=2?10:t.portal.waygate?t.portal.waygate.count:0},tauceti:{}},creepCalc:{planetary:{assembly:1e3},space:{assembly:1e3,swarm_satellite:200}}},Jn={mass_driver:{type:"field",min:0,import:()=>t.city.mass_driver?t.city.mass_driver.on:0}},Zn={fuelAdj:{inputs:["mass_driver"]}},Xn={terraformer:["truepath"]};function Yn(e,a,r,i,s){let n=!(!Qn.max[r]||!Qn.max[r][a])&&Qn.max[r][a],c={owned:0,costVis:!1,creepVis:!1,extra:{truepath:"truepath"===s}},o={},l=!1;switch(r){case"prehistoric":l=Mr.evolution[a],c.real_owned=t.evolution[a]?t.evolution[a].count:0;break;case"planetary":l=Mr.city[a],c.real_owned=t.city[a]?t.city[a].count:0;break;case"space":l=Mr.space[i][a],c.real_owned=t.space[a]?t.space[a].count:0;break;case"starDock":l=Mr.starDock[a],c.real_owned=t.starDock[a]?t.starDock[a].count:0;break;case"interstellar":l=Mr.interstellar[i][a],c.real_owned=t.interstellar[a]?t.interstellar[a].count:0;break;case"intergalactic":l=Mr.galaxy[i][a],c.real_owned=t.galaxy[a]?t.galaxy[a].count:0;break;case"hell":l=Mr.portal[i][a],c.real_owned=t.portal[a]?t.portal[a].count:0;break;case"tauceti":l=Mr.tauceti[i][a],c.real_owned=t.tauceti[a]?t.tauceti[a].count:0}Qn.count[r]&&Qn.count[r][a]&&(c.real_owned=Qn.count[r][a]);let _=function(){if(l.hasOwnProperty("effect")&&"string"!=typeof l.effect){let e=$(".effect",`#${a}`);Ss(e);let t=c.owned-c.real_owned;Xn[a]&&(t={count:t},Xn[a].forEach((function(e){"truepath"===e&&(t[e]="truepath"===s)}))),e.append(l.effect(t))}};_();let d=l.cost;d&&Object.keys(Ns(l)).forEach((function(e){o[e]={},"space"!==r||"Oil"!==e&&"Helium_3"!==e||Zn.fuelAdj.inputs.forEach((function(e){var t;t=e,c.extra[t]=Jn[t].import()}))}));let p=function(){let e=!1;if(d){let t=Ns(l,c.owned-c.real_owned,c.extra);Object.keys(o).forEach((function(a){if("Custom"===a)o[a].vis=!0;else{let e=t[a]?t[a](c.owned-c.real_owned,c.extra):0;o[a].vis=e>0,o[a].cost=x(e,1)}e=e||o[a].vis}))}c.costVis=e};p(),(Qn.include[r]&&Qn.include[r].includes(a)||Qn.exclude[r]&&!Qn.exclude[r].includes(a))&&(function(){let e=!1;if(d&&!n&&(!Qn.excludeCreep[r]||!Qn.excludeCreep[r].includes(a))&&"prehistoric"!==r){let t=Qn.creepCalc[r]&&Qn.creepCalc[r][a]?Qn.creepCalc[r][a]:100,i=t-1,s=Ns(l,t,c.extra),n=Ns(l,i,c.extra);Object.keys(o).forEach((function(a){s[a]&&(o[a].creep=+(s[a](t,c.extra)/n[a](i,c.extra)).toFixed(5),1===o[a].creep?o[a].creep=z("wiki_calc_none"):o[a].creep<1.005&&(o[a].creep=1.005),e=e||o[a].vis)}))}c.creepVis=e}(),e.append($(`\n
                                  \n
                                  \n
                                  {{ | ownedLabel }} -+
                                  \n
                                  \n
                                  \n \n
                                  \n
                                  \n `))),Cs({el:`#${a}`,data:{i:c,r:o},methods:{val(e){c[e]=Math.round(c[e]),c[e]&&c[e]<0?c[e]=0:n&&c[e]>n&&(c[e]=n),_(),p()},less(e){c[e]>0&&c[e]--},more(e){(!n||n&&c[e]=2,link:"wiki.html#discovery-tech-diplomacy"},{title:z("wiki_tech_special_trait",[z("trait_terrifying_name")]),color:!!t.race.terrifying,link:"wiki.html#traits-species-major_terrifying"}]}],socialist:[{category:"unique",subreqs:[{title:z("wiki_tech_special_tech",[z("tech_diplomacy")]),color:t.tech.trade&&t.tech.trade>=2,link:"wiki.html#discovery-tech-diplomacy"},{title:z("wiki_tech_special_trait",[z("trait_terrifying_name")]),color:!!t.race.terrifying,link:"wiki.html#traits-species-major_terrifying"}]}],federation:[{category:"unique",subreqs:[{title:z("wiki_tech_special_occupy"),color:ce(),link:"wiki.html#mechanics-gameplay-occupying"}]}],magocracy:[{category:"universe",subreqs:[{name:"magic"}]}],governor:[{category:"crispr",subreqs:[{name:"governance",tree:"governor",val:1}]},{category:"government",not:!0,subreqs:[{name:"anarchy"}]}],market:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],tax_rates:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],large_trades:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],corruption:[{category:"trait",not:!0,subreqs:[{name:"terrifying"},{name:"noble"}]}],massive_trades:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],trade:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],diplomacy:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],freight:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],wharf:[{category:"trait",not:!0,subreqs:[{name:"terrifying"},{name:"thalassophobia"}]}],reclaimer:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],iron_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],steel_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],titanium_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],alloy_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],mythril_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],adamantite_shovel:[{category:"universe",subreqs:[{name:"evil"}]},{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"}]},{category:"genus",not:!0,subreqs:[{name:"angelic"},{name:"demonic"}]}],stone_axe:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],copper_axes:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],iron_saw:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],steel_saw:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],iron_axes:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],steel_axes:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],titanium_axes:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],chainsaws:[{category:"trait",not:!0,subreqs:[{name:"kindling_kindred"},{name:"smoldering"},{name:"evil"}]}],copper_sledgehammer:[{category:"trait",not:!0,subreqs:[{name:"sappy"}]}],iron_sledgehammer:[{category:"trait",not:!0,subreqs:[{name:"sappy"}]}],steel_sledgehammer:[{category:"trait",not:!0,subreqs:[{name:"sappy"}]}],titanium_sledgehammer:[{category:"trait",not:!0,subreqs:[{name:"sappy"}]}],copper_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],iron_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],steel_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],titanium_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],adamantite_hoe:[{category:"trait",not:!0,subreqs:[{name:"carnivore"},{name:"soul_eater"},{name:"detritivore"}]}],slave_pens:[{category:"trait",subreqs:[{name:"slaver"}]}],slave_market:[{category:"trait",subreqs:[{name:"slaver"}]}],ceremonial_dagger:[{category:"trait",subreqs:[{name:"cannibalize"}]}],last_rites:[{category:"trait",subreqs:[{name:"cannibalize"}]}],ancient_infusion:[{category:"trait",subreqs:[{name:"cannibalize"}]}],armor:[{category:"trait",not:!0,subreqs:[{name:"apex_predator"}]}],plate_armor:[{category:"trait",not:!0,subreqs:[{name:"apex_predator"}]}],kevlar:[{category:"trait",not:!0,subreqs:[{name:"apex_predator"}]}],nanoweave_vest:[{category:"trait",not:!0,subreqs:[{name:"apex_predator"}]}],mad:[{truepath:!0,category:"unique",subreqs:[{title:z("wiki_tech_special_unify"),color:!!t.tech.world_control,link:"wiki.html#globalized-tp_tech-unite"}]}],ancient_theology:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],study:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],encoding:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],deify:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],infusion:[{category:"crispr",subreqs:[{name:"ancients",tree:"ancients",val:1}]}],gps:[{category:"trait",not:!0,subreqs:[{name:"terrifying"}]}],genesis:[{category:"unique",subreqs:[{title:z("wiki_tech_special_genesis"),color:t.race.deterioration>=1}]}],veil:[{category:"universe",subreqs:[{name:"magic"}]}],mana_syphon:[{category:"universe",subreqs:[{name:"magic"}]}],mana:[{category:"universe",subreqs:[{name:"magic"}]}],ley_lines:[{category:"universe",subreqs:[{name:"magic"}]}],rituals:[{category:"universe",subreqs:[{name:"magic"}]}],crafting_ritual:[{category:"universe",subreqs:[{name:"magic"}]}],mana_nexus:[{category:"universe",subreqs:[{name:"magic"}]}],clerics:[{category:"universe",subreqs:[{name:"magic"}]},{category:"crispr",subreqs:[{name:"faith",tree:"ancients",val:2}]}],conjuring:[{category:"universe",subreqs:[{name:"magic"}]},{category:"scenario",not:!0,subreqs:[{name:"cataclysm"}]}],res_conjuring:[{category:"universe",subreqs:[{name:"magic"}]},{category:"scenario",not:!0,subreqs:[{name:"cataclysm"}]}],alchemy:[{category:"universe",subreqs:[{name:"magic"}]}],transmutation:[{category:"universe",subreqs:[{name:"magic"}]}],dark_bomb:[{category:"unique",subreqs:[{title:z("wiki_tech_special_demon_lord"),color:t.stats.hasOwnProperty("spire")&&t.stats.spire.hasOwnProperty(xn())&&t.stats.spire[xn()].hasOwnProperty("dlstr")&&t.stats.spire[xn()].dlstr>0,link:"wiki.html#mechanics-gameplay-dlord"}]}],terraforming:[{category:"challenge",subreqs:[{name:"orbitdecay"}]}],geck:[{category:"achieve",subreqs:[{name:"lamentis",val:5}]}],womling_fun:[{category:"unique",subreqs:[{title:z("tau_red_contact"),color:!!t.race.womling_friend,link:"wiki.html#tauceti-structures-contact"},{title:z("tau_red_introduce"),color:!!t.race.womling_god,link:"wiki.html#tauceti-structures-introduce"},{title:z("tau_red_subjugate"),color:!!t.race.womling_lord,link:"wiki.html#tauceti-structures-subjugate"}]}],isolation_protocol:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],focus_cure:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],decode_virus:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vaccine_campaign:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vax_strat1:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vax_strat2:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vax_strat3:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],vax_strat4:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],cloning:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],clone_degredation:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],digital_paradise:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],ringworld:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],matrioshka_brain:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],ignition_device:[{category:"scenario",not:!0,subreqs:[{name:"lone_survivor"}]}],replicator:[{category:"scenario",subreqs:[{name:"lone_survivor"}]}],womling_unlock:[{category:"scenario",subreqs:[{name:"lone_survivor"}]}],garden_of_eden:[{category:"scenario",subreqs:[{name:"lone_survivor"}]}]},cc={unification2:"unification",conjuring:"ley_lines",res_conjuring:"conjuring",bribe_sphinx:"miasma"};const oc={solar:"interstellar"},lc={interstellar:"solar"};function _c(e,a){let r=Ln("create"),i=[],s=[],n="truepath"===a?ac:tc,c="truepath"===a?"tp_tech":"tech";if(Object.keys(n).forEach((function(r){let c=n[r];if(c.hasOwnProperty("era")&&(c.era===e||c.era===oc[e])&&(!c.hasOwnProperty("wiki")||c.wiki)){let e=n[r].id.split("-"),o=$(`
                                  `);if(Tn(o,c),function(e,t,a){let r=$('
                                  ');if(e.append(r),ic.hasOwnProperty(t)&&"truepath"===a)for(let e=0;e${ic[t][e]}`);else if(rc.hasOwnProperty(t))for(let e=0;e${rc[t][e]}`);else r.append(`
                                  ${z("wiki_tech_empty")}
                                  `)}(o,r,a),function(e,a,r,i){let s=function(e){let t={},a="truepath"===e?ac:tc;return Object.keys(a).forEach((function(e){let a=Mr.tech[e];t[a.grant[0]]||(t[a.grant[0]]={});let r="string"==typeof Mr.tech[e].title?Mr.tech[e].title:Mr.tech[e].title();t[a.grant[0]][a.grant[1]]=[{name:e,title:r,era:Mr.tech[e].era}]})),t.primitive[2]=[{name:"bone_tools",title:z("tech_bone_tools"),era:"primitive"},{name:"wooden_tools",title:z("tech_wooden_tools"),era:"primitive"}],t.theology[3]=[{name:Mr.tech.fanaticism.wiki?"fanaticism":"alt_fanaticism",title:z("tech_fanaticism"),era:"civilized"},{name:Mr.tech.anthropology.wiki?"anthropology":"alt_anthropology",title:z("tech_anthropology"),era:"civilized"}],t.theology[5]=[{name:"deify",title:z("tech_deify"),era:"early_space"},{name:"study",title:z("tech_study"),era:"early_space"}],t.ancient_study[1]=[{name:"study",title:z("tech_study"),era:"early_space"}],t.ancient_deify[1]=[{name:"deify",title:z("tech_deify"),era:"early_space"}],"truepath"===e&&(t.unify[1]=[{name:"arpa",title:z("tech_arpa"),era:"globalized"}],t.isolation={},t.isolation[1]=[{name:"isolation_protocol",title:z("tech_isolation_protocol"),era:"tauceti"}],t.focus_cure={},t.focus_cure[1]=[{name:"focus_cure",title:z("tech_focus_cure"),era:"tauceti"}]),t}(i);if(Object.keys(a.reqs).length>0){let r={},n={};if(Object.keys(a.reqs).forEach((function(e){let i=t.tech[e]&&t.tech[e]>=a.reqs[e]?"success":"danger",c=e+a.reqs[e];s[e]&&s[e][a.reqs[e]]?(r[c]=[],s[e][a.reqs[e]].forEach((function(e){r[c].push({name:e.name,title:e.title,era:e.era,color:i})}))):sc[c]&&(n[c]={title:sc[c].title,link:sc[c].link,color:i})})),Object.keys(r).length>0){let t=!1,a=$(`
                                  ${z("wiki_tech_req_tech")}
                                  `);e.append(a),Object.keys(r).forEach((function(e){let s="",n=!1,c=!1;r[e].forEach((function(e){let t=`${e.title}`;c=e.color,n?s=z("wiki_tech_req_or",[s,t]):(n=!0,s=t)})),a.append(`${t?", ":""}${s}`),t=!0}))}if(Object.keys(n).length>0){let t=!1,a=$(`
                                  ${z("wiki_tech_req_other")}
                                  `);e.append(a),Object.keys(n).forEach((function(e){let r=n[e].link;r&&"truepath"===i&&(r=r.replace("-structures-","-tp_structures-"));let s=r?`${n[e].title}`:n[e].title;a.append(`${t?", ":""}${s}`),t=!0}))}}if(nc.hasOwnProperty(r)){let a=!1,s=$(`
                                  ${z("wiki_tech_req_special")}
                                  `),n=!1;nc[r].forEach((function(e){if(e.truepath&&"truepath"!==i)return;n=!0;let r=!1,c=!1,o="";e.subreqs.forEach((function(a){let s="",n=!1,l=!1;switch(e.category){case"species":s=z(`race_${a.name}`),n=`wiki.html#races-species-${a.name}`,l=t.race.species===a.name;break;case"genus":s=z(`genelab_genus_${a.name}`),l=Ki[t.race.species].type===a.name;break;case"trait":s=z(`trait_${a.name}_name`),n=`wiki.html#traits-species-${Ei[a.name].type}_${a.name}`,l=t.race[a.name];break;case"tech":s="string"==typeof Mr.tech[a.name].title?Mr.tech[a.name].title:Mr.tech[a.name].title(),n=`wiki.html#${Mr.tech[a.name].era}-tech-${a.name}`,l=t.tech[a.tree]&&t.genes[a.tree]>=a.val;break;case"universe":s=z(`universe_${a.name}`),n=`wiki.html#universes-gameplay-${a.name}`,l=t.race.universe===a.name;break;case"crispr":s=z(`arpa_genepool_${a.name}_title`),n=`wiki.html#crispr-prestige-${a.name}`,l=t.genes[a.tree]&&t.genes[a.tree]>=a.val;break;case"achieve":s=a.val+` ${Hs("star")} `+z(`achieve_${a.name}_name`),n=`wiki.html#perks-prestige-${a.name}`,l=t.stats.achieve[a.name]&&t.stats.achieve[a.name].l>=a.val;break;case"government":s=z(`govern_${a.name}`),n=`wiki.html#government-gameplay-${a.name}`,l=t.civic.govern&&t.civic.govern.type&&t.civic.govern.type===a.name;break;case"scenario":s=z(`wiki_challenges_scenarios_${a.name}`),n=`wiki.html#challenges-gameplay-scenarios_${a.name}`,l=t.race[a.name];break;case"challenge":s=z(`wiki_challenges_modes_${a.name}`),n=`wiki.html#challenges-gameplay-modes_${a.name}`,l=t.race[a.name];break;case"unique":s=a.title,n=a.link,l=a.color}n&&"truepath"===i&&(n=n.replace("-tech-","-tp_tech-")),c=c||l,e.not&&(l=!l),l=l?"success":"danger",s=n?`${s}`:`${s}`,r?o=z("wiki_tech_req_or",[o,s]):(r=!0,o=s)})),e.not&&(c=!c),c=c?"success":"danger","unique"!==e.category&&(o=z(`wiki_tech_special_${e.category}${e.not?"_not":""}`,[o])),s.append(`${a?", ":""}${o}`),a=!0})),n&&e.append(s)}}(o,c,r,a),c.cost.Knowledge)if(0===i.length)i[0]=[c,o];else{let e=c.cost.Knowledge(),t=i.length-1;for(;t>=0&&i[t][0].cost.Knowledge()>e;)i[t+1]=i[t],t--;i[t+1]=[c,o]}else s.push([c,o])}})),s.length>0)for(let e=0;e');e.append(a),Object.keys(kn).forEach((function(e){let r=$('
                                  ');a.append(r);let i=t.stats.feat[e]&&t.stats.feat[e]>0?"warning":"fade",s=Vs(e,"feat"),n=t.stats.feat[e]>1?`

                                  ${Hs(s)}

                                  `:"";r.append(`${kn[e].name}${n}`),function(e,a){let r=a?`
                                  ${kn[e].flair}
                                  `:"";if("egghunt"===e){let a=(new Date).getFullYear(),i=`
                                  ${z("wiki_feat_egghunt_found")}
                                  `;for(let e=1;e<=18;e++)i+=`${z("wiki_feat_egghunt_num",[e])}`;i+="
                                  ",ls(`f-${e}`,$(`
                                  ${kn[e].desc}
                                  ${z(`wiki_feat_${e}`)}
                                  ${i}${r}`))}else if("trickortreat"===e){let a=(new Date).getFullYear(),i=`
                                  ${z("wiki_feat_trickortreat_found")}
                                  `;for(let e=1;e<=7;e++)i+=`${z("wiki_feat_treat_num",[e])}`;for(let e=1;e<=7;e++)i+=`${z("wiki_feat_trick_num",[e])}`;i+="
                                  ",ls(`f-${e}`,$(`
                                  ${kn[e].desc}
                                  ${z(`wiki_feat_${e}`)}
                                  ${i}${r}`))}else if("equilibrium"===e){let a={};t.pillars&&Object.keys(t.pillars).forEach((function(e){Ki[e]&&(a[e]=t.pillars[e])}));let i='
                                  ';Object.keys(Ki).sort(((e,t)=>Ki[e].name.localeCompare(Ki[t].name))).forEach((function(e){"protoplasm"!==e&&("custom"!==e||"custom"===e&&t.stats.achieve.ascended)&&(a[e]&&a[e]>=1?i+=`${Ki[e].name}`:i+=`${Ki[e].name}`)})),i+="
                                  ",ls(`f-${e}`,$(`
                                  ${kn[e].desc}
                                  ${z(`wiki_feat_${e}`)}
                                  ${i}${r}`),{wide:!0})}else ls(`f-${e}`,$(`
                                  ${kn[e].desc}
                                  ${z(`wiki_feat_${e}`)}
                                  ${r}`))}(e,"warning"===i)}))}()}}const pc={cross:["antimatter"],vigilante:["evil"],squished:["micro"],macro:["micro"],marble:["micro"],double_density:["heavy"],heavyweight:["heavy"],whitehole:["standard"],heavy:["heavy"],canceled:["antimatter"],eviltwin:["evil"],microbang:["micro"],pw_apocalypse:["magic"],pass:["magic"],fullmetal:["magic"],soul_sponge:["magic"],nightmare:["magic"]},uc={trade:[750,50]};function hc(e,a){let r=$("#content");Ss(r);let i=`\n \n `;r.append(i),Cs({el:"#filtering",methods:{universeSwap(e){hc(e,a)},filterSwap(t){hc(e,t)}}});let s=xn(e||"standard"),n={};Object.keys(wn).forEach((function(r){if(!e||!pc[r]||pc[r].indexOf(e)>-1){if("missing"===a&&t.stats.achieve[r]&&t.stats.achieve[r][s]&&t.stats.achieve[r][s]>0)return;if("obtained"===a&&!(t.stats.achieve[r]&&t.stats.achieve[r][s]&&t.stats.achieve[r][s]>0))return;if("incomplete"===a&&e&&t.stats.achieve[r]&&t.stats.achieve[r][s]&&t.stats.achieve[r][s]>4)return;if("completed"===a&&e&&!(t.stats.achieve[r]&&t.stats.achieve[r][s]&&t.stats.achieve[r][s]>4))return;if(("incomplete"===a||"completed"===a)&&!e){let e="universe"===wn[r].type?10:30;if("whitehole"===r&&(e=5),t.stats.achieve[r]&&Object.keys(t.stats.achieve[r]).forEach((a=>e-=t.stats.achieve[r][a])),"incomplete"===a&&e<=0)return;if("completed"===a&&e>0)return}n.hasOwnProperty(wn[r].type)?n[wn[r].type].push(r):n[wn[r].type]=[r]}})),Object.keys(n).forEach((function(a){r.append($(`

                                  ${z(`wiki_achieve_${a}`)}

                                  `));let i=$('
                                  ');r.append(i),n[a].forEach((function(a){let r=$('
                                  ');i.append(r);let n=t.stats.achieve[a]&&t.stats.achieve[a][s]&&t.stats.achieve[a][s]>0?"warning":"fade";r.append(`${wn[a].name}`);let c=Xs(a,16,!1,!1,e);r.append(`${c}`),function(e,a,r){let i=xn(r||"standard"),s=a?`
                                  ${wn[e].flair}
                                  `:"";if("mass_extinction"===e||"vigilante"===e){let a='
                                  ';Object.keys(Ki).sort((function(e,t){return Ki[e].hasOwnProperty("name")&&Ki[t].hasOwnProperty("name")?Ki[e].name.localeCompare(Ki[t].name):0})).forEach((function(r){"protoplasm"!==r&&("custom"!==r||"custom"===r&&t.stats.achieve.ascended)&&(t.stats.achieve[`extinct_${r}`]&&("mass_extinction"===e?t.stats.achieve[`extinct_${r}`][i]>=0:t.stats.achieve[`extinct_${r}`].hasOwnProperty("e")&&t.stats.achieve[`extinct_${r}`].e>=0)?a+=`${Ki[r].name}`:a+=`${Ki[r].name}`)})),a+="
                                  ",ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z(`wiki_achieve_${e}`)}
                                  ${a}${s}`),{wide:!0})}else if("explorer"===e){let a='
                                  ';Object.keys(is).sort(((e,t)=>is[e].label.localeCompare(is[t].label))).forEach((function(e){(!r||"hellscape"!==e&&"eden"!==e||"hellscape"===e&&"evil"!==r||"eden"===e&&"evil"===r)&&(t.stats.achieve[`biome_${e}`]&&t.stats.achieve[`biome_${e}`][i]>=0?a+=`${is[e].label}`:a+=`${is[e].label}`)})),a+="
                                  ",ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z(`wiki_achieve_${e}`)}
                                  ${a}${s}`))}else if("creator"===e||"heavyweight"===e){let a='
                                  ';Object.keys(Li).sort().forEach((function(r){let s=["carnivore","herbivore","omnivore"].includes(r)?z(`evo_${r}_title`):z(`genelab_genus_${r}`);("creator"===e?t.stats.achieve[`genus_${r}`]&&t.stats.achieve[`genus_${r}`][i]>=0:t.stats.achieve[`genus_${r}`]&&t.stats.achieve[`genus_${r}`].h>=0)?a+=`${s}`:a+=`${s}`})),a+="
                                  ",ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z(`wiki_achieve_${e}`)}
                                  ${a}${s}`))}else if("enlightenment"===e){let a={};t.pillars&&Object.keys(t.pillars).forEach((function(e){Ki[e]&&(!a[Ki[e].type]||t.pillars[e]>a[Ki[e].type])&&(a[Ki[e].type]=t.pillars[e])}));let r='
                                  ';Object.keys(Li).sort().forEach((function(e){let t=["carnivore","herbivore","omnivore"].includes(e)?z(`evo_${e}_title`):z(`genelab_genus_${e}`);a[e]&&a[e]>=1?r+=`${t}`:r+=`${t}`})),r+="
                                  ",ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z(`wiki_achieve_${e}`)}
                                  ${r}${s}`))}else if("gladiator"===e){let a='
                                  ',n={};t.stats.spire&&Object.keys(t.stats.spire).forEach((function(e){r&&i!==e||Object.keys(t.stats.spire[e]).forEach((function(a){va[a]&&(!n.hasOwnProperty(a)||n[a]0?a+=`${z(`portal_mech_boss_${e}`)}`:a+=`${z(`portal_mech_boss_${e}`)}`})),a+="
                                  ",ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z(`wiki_achieve_${e}`)}
                                  ${a}${s}`),{wide:!0})}else if("banana"===e){let a='
                                  ';a+=`
                                  ${z("wiki_achieve_banana1")}
                                  `,a+=`
                                  ${z("wiki_achieve_banana2")}
                                  `,a+=`
                                  ${z("wiki_achieve_banana3")}
                                  `,a+=`
                                  ${z("wiki_achieve_banana4",[500])}
                                  `,a+=`
                                  ${z("wiki_achieve_banana5",[50])}
                                  `,a+="
                                  ",ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z(`wiki_achieve_${e}`)}
                                  ${a}${s}`))}else if("pathfinder"===e){let a='
                                  ';["ashanddust","exodus","obsolete","bluepill","retired"].forEach((function(e){let r=z(`achieve_${e}_name`);t.stats.achieve[e]&&t.stats.achieve[e][i]>=5?a+=`${r}`:a+=`${r}`})),a+="
                                  ",ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z(`wiki_achieve_${e}`)}
                                  ${a}${s}`))}else if("overlord"===e){let a='
                                  ',i={subjugate:"lord",contact:"friend",introduced:"god"},n=xn(r||"standard");Object.keys(i).forEach((function(e){t.stats.womling[i[e]]&&t.stats.womling[i[e]][n]>0?a+=`${z(`wiki_achieve_overlord_${e}`)}`:a+=`${z(`wiki_achieve_overlord_${e}`)}`})),a+="
                                  ",ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z(`wiki_achieve_${e}`)}
                                  ${a}${s}`))}else if(e.includes("extinct_")&&"custom"!==e.substring(8)){let t=e.substring(8);ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z("wiki_achieve_extinct_race",[z(`race_${t}`)])}
                                  ${s}`))}else if(e.includes("genus_")){let t=e.substring(6);ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z("wiki_achieve_genus_type",[z(`genelab_genus_${t}`)])}
                                  ${s}`))}else if(e.includes("biome_")||e.includes("atmo_")){let t=e.substring(e.indexOf("_")+1);ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${z("wiki_achieve_planet_type",["b"===e.substring(0,1)?z(`biome_${t}_name`):z(`planet_${t}`)])}
                                  ${s}`))}else{let t=uc[e]?z(`wiki_achieve_${e}`,uc[e]):z(`wiki_achieve_${e}`);ls(`a-${e}`,$(`
                                  ${wn[e].desc}
                                  ${t}
                                  ${s}`))}}(a,"warning"===n,e)}))}))}function mc(e,t,a,r){r=r||{};let i=$(`\n
                                  \n ${z("wiki_challenges_"+(t?"feats":"achievements"))}\n
                                  \n `);e.append(i);let s=!1;a.forEach((function(e){let a=t?z(`feat_${e}_name`):r[e]?z(`achieve_${e}_name`):`${z(`achieve_${e}_name`)}`;i.append(`${s?", ":""}${a}`),s=!0}))}function gc(e,t){let a=$(`\n
                                  \n ${z("wiki_challenges_requirements")}\n
                                  \n `);e.append(a);let r=!1;t.forEach((function(e){let t=!1,i=!1,s="";e.subreqs.forEach((function(e){let a=e.text,r=e.link||!1,n=e.color;i=i||n,n=n?"success":"danger",a=r?`${a}`:`${a}`,t?s=z("wiki_tech_req_or",[s,a]):(t=!0,s=a)})),i=i?"success":"danger",s=z(e.text,[s]),a.append(`${r?", ":""}${s}`),r=!0}))}const vc={plasmid:["cit","sol","know","genes","reset","uni","high_pop","synth","tp"],anti:["cit","sol","know","genes","reset","high_pop","synth","tp"],phage:["plas","genes","reset","uni","tp"],dark:["mass","exotic","genes","uni"],vacuum:["mana","genes"],harmony:["genes","uni"],artifact:["genes","floor","micro"],cores:["micro"]};function fc(e,a,r,i){let s=r||a,n=a+(i||"")+(r||""),c=$(`
                                  `);e.append(c);let o="";switch(i){case"mad":o+=z("wiki_calc_mad")+" ";break;case"bioseed":case"cataclysm":case"vacuum":case"terraform":o+=z("wiki_resets_"+i)+" ";break;case"bigbang":o+=z("wiki_resets_blackhole")+" ";break;case"ascend":o+=z("wiki_resets_ascension")+" ";break;case"descend":o+=z("wiki_resets_infusion")+" ";break;case"ai":o+=z("wiki_resets_ai")+" "}switch(s){case"plasmid":o+=z("resource_Plasmid_name");break;case"anti":o+=z("resource_AntiPlasmid_name");break;case"phage":o+=z("resource_Phage_name");break;case"dark":case"vacuum":o+=z("resource_Dark_name");break;case"harmony":o+=z("resource_Harmony_name");break;case"artifact":o+=z("resource_Artifact_name");break;case"cores":o+=z("resource_AICore_name")}c.append(`

                                  ${z("wiki_calc_gains",[o])}

                                  `);let l=$("
                                  "),_=$("
                                  ");c.append(l),c.append(_);let d={cit:0,sol:0,know:0,plas:0,mass:0,exotic:0,mana:0,floor:0,genes:0,uni:"standard"},p={cit:{val:void 0,use:!1},sol:{val:void 0,use:!1},know:{val:void 0,use:!1},plas:{val:void 0,use:!1},mass:{val:void 0,use:!1},exotic:{val:void 0,use:!1},mana:{val:void 0,use:!1},floor:{val:void 0,use:!1},genes:{val:void 0,use:!1},reset:{val:void 0,use:!1},uni:{val:void 0,use:!1},micro:{val:!1,use:!1},high_pop:{val:void 0,use:!1},synth:{val:!1,use:!1},tp:{val:!1,use:!1,enabled:!0}},u={standard:{use:!0},evil:{use:!0},antimatter:{use:!0},micro:{use:!0},heavy:{use:!0},magic:{use:!0}},h={mad:{use:!0},bioseed:{use:!0},cataclysm:{use:!0},bigbang:{use:!0},vacuum:{use:!0},terraform:{use:!0},ascend:{use:!0},descend:{use:!1},ai:{use:!0}},m={vis:!1},g={capVis:!1,overflowVis:!1,totalVis:!1,capVal:void 0,overflow:void 0,rawGains:void 0};vc[s].forEach((function(e){p[e].use=!0})),i&&(p.reset.val=i,p.reset.use=!1,"mad"!==i&&(p.synth.use=!1,p.synth.val=!1),"vacuum"===i&&(p.uni.use=!1,p.uni.val="magic"),"ai"===i?(p.tp.use=!1,p.tp.val=!0):["mad","bioseed","terraform"].includes(i)||(p.tp.use=!1,p.tp.val=!1));let v="";switch(s){case"plasmid":i||(u.antimatter.use=!1);break;case"anti":h.vacuum.use=!1;break;case"phage":h.mad.use=!1,h.descend.use=!1,v+="log2({{ i.plas.val, 'plasmids' | generic }}) * {{ i.reset.val | phageMulti }} * e * {{ i.genes.val | challenge}} * {{ i.uni.val | universe }} * 1.1";break;case"dark":p.reset.val="bigbang",u.magic.use=!1,v+="(ln(1 + ({{ i.exotic.val, 'exotic' | generic }} * 40)) + (log2({{ i.mass.val, 'mass' | generic }} - 7) / 2.5)) * {{ i.genes.val | challenge }} * {{ i.uni.val | universe }}";break;case"vacuum":p.reset.val="vacuum",p.uni.val="magic",v+="(log2({{ i.mana.val, 'mana' | generic }}) / 5) * {{ i.genes.val | challenge }}";break;case"harmony":p.reset.val="ascend",v+="(1 + {{ i.genes.val, 'genes' | generic }}) * {{ i.uni.val | universe }}";break;case"artifact":p.reset.val="descend",v+="1 + {{ i.genes.val, 'genes' | generic }} + {{ i.floor.val | floor }}";break;case"cores":p.reset.val="ai",v+='52'}"plasmid"===a?(v+=`\n
                                  \n

                                  ${z("wiki_calc_plasmid_cap_total",[z("anti"===s?"resource_AntiPlasmid_name":"resource_Plasmid_name")])}

                                  \n
                                  \n
                                  \n {{ i.reset.val, i.synth.val | plasmidCap }} * (1 + (({{ i.genes.val, 'genes' | generic }} + 1) / 8)) = {{ | plasmidCapCalc }} = {{ pe.capVal }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_plasmid_gains_raw",[z("anti"===s?"resource_AntiPlasmid_name":"resource_Plasmid_name")])}

                                  \n
                                  \n
                                  \n `,v+="plasmid"===s?"\n ((({{ i.cit.val, 'citizens' | generic }} + {{ i.sol.val, 'soldiers' | generic }}) / {{ i.high_pop.val | highPopDivisor }} / {{ i.reset.val, i.synth.val | popDivisor }}) + (ln(1 + (({{ i.reset.val | knowMulti }} - 1) * {{ i.know.val, 'knowledge' | generic }} / {{ i.reset.val, i.synth.val | knowInc }})) / ln({{ i.reset.val | knowMulti }}))) * {{ i.genes.val | challenge }} * {{ i.uni.val | universe }} * 1.1\n ":"\n ((({{ i.cit.val, 'citizens' | generic }} + {{ i.sol.val, 'soldiers' | generic }}) / {{ i.high_pop.val | highPopDivisor }} / {{ i.reset.val, i.synth.val | popDivisor }}) + (ln(1 + (({{ i.reset.val | knowMulti }} - 1) * {{ i.know.val, 'knowledge' | generic }} / {{ i.reset.val, i.synth.val | knowInc }})) / ln({{ i.reset.val | knowMulti }}))) * {{ i.genes.val | challenge }} * 1.1 * 1.1\n ",v+=`\n = {{ | calc }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_overflow")}

                                  \n
                                  \n
                                  \n {{ pe.rawGains, 'plasmid_gains_raw' | generic }} - {{ pe.capVal, 'plasmid_cap_total' | generic }} = {{ pe.overflow, 'no_overflow' | generic }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_plasmid_gains_total",[z("anti"===s?"resource_AntiPlasmid_name":"resource_Plasmid_name")])}

                                  \n
                                  \n
                                  \n {{ pe.capVal, 'plasmid_cap_total' | generic }} + ({{ pe.overflow, 'overflow' | generic }} / ({{ pe.overflow, 'overflow' | generic }} + {{ pe.capVal, 'plasmid_cap_total' | generic }}) * {{ pe.capVal, 'plasmid_cap_total' | generic }}) = {{ | plasmidTotalCalc }}\n
                                  \n `):v+=' = {{ | calc }}',l.append(v),_.append(`\n
                                  \n
                                  ${z("wiki_calc_citizens")}
                                  \n
                                  ${z("wiki_calc_soldiers")}
                                  \n
                                  ${z("wiki_calc_knowledge")}
                                  \n
                                  ${z("resource_Plasmid_plural_name")}
                                  \n
                                  ${z("wiki_calc_mass")}
                                  \n
                                  ${z("wiki_calc_exotic")}
                                  \n
                                  ${z("wiki_calc_mana")}
                                  \n
                                  ${z("wiki_calc_floor")}
                                  \n
                                  ${z("wiki_calc_genes")}
                                  \n
                                  ${z("wiki_calc_prestige")} \n \n {{ 'mad' | resetLabel }}\n {{ 'bioseed' | resetLabel }}\n {{ 'cataclysm' | resetLabel }}\n {{ 'bigbang' | resetLabel }}\n {{ 'vacuum' | resetLabel }}\n {{ 'terraform' | resetLabel }}\n {{ 'ascend' | resetLabel }}\n {{ 'descend' | resetLabel }}\n {{ 'ai' | resetLabel }}\n
                                  \n
                                  ${z("wiki_calc_universe")} \n \n {{ 'standard' | uniLabel }}\n {{ 'evil' | uniLabel }}\n {{ 'antimatter' | uniLabel }}\n {{ 'micro' | uniLabel }}\n {{ 'heavy' | uniLabel }}\n {{ 'magic' | uniLabel }}\n
                                  \n
                                  ${z("trait_high_pop_name")} \n \n {{ 0 | highPopLabel }}\n {{ 0.25 | highPopLabel }}\n {{ 0.5 | highPopLabel }}\n {{ 1 | highPopLabel }}\n {{ 2 | highPopLabel }}\n {{ 3 | highPopLabel }}\n
                                  \n
                                  ${z("universe_micro")}
                                  \n
                                  ${z("wiki_calc_synth")}
                                  \n
                                  ${z("wiki_calc_tp")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:"#"+n+"Calc",data:{i:p,u,r:h,s:m,pe:g},methods:{val(e){switch(e){case"cit":case"sol":case"know":case"plas":case"mass":case"exotic":case"mana":case"floor":p[e].val&&p[e].val<0&&(p[e].val=0);break;case"genes":p[e].val&&(p[e].val<0?p[e].val=0:p[e].val>4&&(p[e].val=4))}},pickReset(e){p.reset.val=e,Object.keys(u).forEach((function(e){u[e].use=!0})),"vacuum"===e?Object.keys(u).forEach((function(e){"magic"!==e&&(u[e].use=!1)})):"bigbang"===e&&(u.magic.use=!1),"plasmid"===a&&(u.antimatter.use=!1),p.synth.use="mad"===e,["mad","bioseed","terraform"].includes(e)?p.tp.enabled=!0:(p.tp.enabled=!1,p.tp.val="ai"===e)},pickUniverse(e){p.uni.val=e,"magic"===e?(h.bigbang.use=!1,h.vacuum.use=!0):(h.bigbang.use=!0,h.vacuum.use=!1),p.micro.val="micro"===e},pickHighPop(e){p.high_pop.val=e},resetInputs(){Object.keys(p).forEach((function(e){p[e].use&&(p[e].val=void 0)})),p.synth.use="plasmid"===a,["micro","synth","tp"].forEach((function(e){p[e].use&&(p[e].val=!1)})),p.tp.enabled=!0},importInputs(){p.cit.val=t.resource[t.race.species].amount,p.sol.val=t.civic.garrison?t.civic.garrison.workers:0;for(let e=0;e<3;e++)t.civic.foreign[`gov${e}`].occ&&(p.sol.val+=ta("federation"===t.civic.govern.type?15:20));p.know.val=t.stats.know,p.mass.val=t.interstellar.stellar_engine?t.interstellar.stellar_engine.mass:8,p.exotic.val=t.interstellar.stellar_engine?t.interstellar.stellar_engine.exotic:0,p.mana.val=t.resource.Mana.gen,p.floor.val=t.portal.spire?t.portal.spire.count-1:0,p.genes.val=Mn()-1;let e=t.race.universe;"dark"===s&&"magic"===e||"vacuum"===i||"bigbang"===e||(p.uni.val=e,"magic"===e?("bigbang"===p.reset.val&&(p.reset.val=void 0),h.bigbang.use=!1,h.vacuum.use=!0):("vacuum"===p.reset.val&&(p.reset.val=void 0),h.bigbang.use=!0,h.vacuum.use=!1),p.micro.val="micro"===e),p.high_pop.val=t.race.high_pop?t.race.high_pop:0,p.synth.val="synthetic"===Ki[t.race.species].type,p.tp.use&&p.reset.val&&["mad","bioseed","terraform"].includes(p.reset.val)&&(p.tp.val=!!t.race.truepath),p.reset.val&&"mad"!==p.reset.val&&"descend"!==p.reset.val&&(p.plas.val=Gs(p.reset.val,{cit:p.cit.val,sol:p.sol.val,know:p.know.val,uni:p.uni.val,genes:p.genes.val,high_pop:p.high_pop.val,tp:p.tp.val}).plasmid)}},filters:{generic:(e,t)=>void 0!==e?e:"plasmid_gains_raw"===t||"plasmid_cap_total"===t?z("wiki_calc_"+t,[z("anti"===s?"resource_AntiPlasmid_name":"resource_Plasmid_name")]):z("wiki_calc_"+t),floor(e){if(void 0===e)return z("wiki_calc_floor_bonus");let t=0;return[50,100].forEach((function(a){e>=a&&t++})),t},highPopDivisor:e=>e?Ei.high_pop.vars(e)[0]:1,popDivisor(e,t){switch(e){case"mad":if(t)return 5;case"cataclysm":case"bioseed":return 3;case"ai":return 2.5;case"vacuum":case"bigbang":return 2.2;case"ascend":case"terraform":return 1.15;default:return z("wiki_calc_pop_divisor")}},knowMulti(e){switch(e){case"mad":return 1.1;case"cataclysm":case"bioseed":return 1.015;case"ai":return 1.014;case"vacuum":case"bigbang":return 1.012;case"ascend":case"terraform":return 1.008;default:return z("wiki_calc_know_multi")}},knowInc(e,t){switch(e){case"mad":return t?125e3:1e5;case"cataclysm":case"bioseed":return 5e4;case"ai":return 45e3;case"vacuum":case"bigbang":return 4e4;case"ascend":case"terraform":return 3e4;default:return z("wiki_calc_know_inc")}},phageMulti(e){switch(e){case"cataclysm":case"bioseed":return 1;case"ai":return 2;case"vacuum":case"bigbang":return 2.5;case"ascend":case"terraform":return 4;default:return z("wiki_calc_phage_multi")}},plasmidCap(e,t){switch(e){case"mad":return t?100:150;case"cataclysm":case"bioseed":return 400;case"ai":return 600;case"vacuum":case"bigbang":return 800;case"ascend":case"terraform":return 2e3;default:return z("wiki_calc_plasmid_cap")}},plasmidCapCalc(){if(g.capVis=p.reset.val&&void 0!==p.genes.val,g.capVis){let e=0;switch(p.reset.val){case"mad":e=150,p.synth.val&&(e=100);break;case"cataclysm":case"bioseed":e=400;break;case"ai":e=600;break;case"vacuum":case"bigbang":e=800;break;case"ascend":case"terraform":e=2e3}return e*=1+(p.genes.val+1-(p.tp.val?0:1))/8,g.capVal=Math.floor(e),e}g.capVal=void 0},plasmidTotalCalc(){if(g.totalVis=g.overflow&&g.capVal,g.totalVis)return g.capVal+Math.floor(g.overflow/(g.overflow+g.capVal)*g.capVal)},challenge:e=>void 0!==e?Bs(1,"mad",2,{genes:e,uni:"standard",tp:!1}):z("wiki_calc_challenge_multi"),universe(e){if(!e)return z("wiki_calc_universe_multi");let t=p.genes.val||0;return"harmony"===s||"artifact"===s?(d.uni=p.uni.val,Gs(p.reset.val,d)[a]):+(Bs(1,p.reset.val,2,{genes:t,uni:e})/Bs(1,"mad",2,{genes:t,uni:"standard"})).toFixed(2)},calc(){let e=!0;if(Object.keys(p).forEach((function(t){p[t].use&&void 0===p[t].val&&(e=!1)})),m.vis=e,m.vis){let e={};vc[s].forEach((function(t){"reset"!==t&&("micro"!==t?e[t]=p[t].val:e.uni=p.micro.val?"micro":"standard")})),"anti"===s?e.uni="antimatter":"vacuum"===s&&(e.uni="magic"),"plasmid"===a&&(e.rawPlasmids=!0);let t=Gs(p.reset.val,e)[a];return"plasmid"===a&&(g.rawGains=t,g.overflow=void 0!==g.capVal&&t>g.capVal?t-g.capVal:void 0,g.overflowVis=void 0!==g.rawGains&&void 0!==g.capVal),t}"plasmid"===a&&(g.rawGains=void 0,g.overflow=void 0,g.overflowVis=!1)},resetLabel(e){switch(e){case"mad":return z("wiki_calc_mad");case"bioseed":case"cataclysm":case"vacuum":case"ai":case"terraform":return z("wiki_resets_"+e);case"bigbang":return z("wiki_resets_blackhole");case"ascend":return z("wiki_resets_ascension");case"descend":return z("wiki_resets_infusion")}return z("wiki_calc_prestige")},uniLabel:e=>z(e?"universe_"+e:"wiki_calc_universe"),highPopLabel:e=>void 0===e?z("wiki_calc_trait_undefined"):0===e?z("wiki_calc_trait_unowned"):e}})}function yc(e,a){let r=$(`
                                  `);e.append(r);let i=z("anti"===a?"resource_AntiPlasmid_name":"resource_Plasmid_name");r.append(`

                                  ${z("wiki_calc_bonuses",[z("wiki_calc_prod",[i])])}

                                  `);let s=$("
                                  "),n=$("
                                  ");r.append(s),r.append(n);let c={plas:{val:void 0},phage:{val:void 0},antimatter:{val:!1}},o={underResult:{vis:!1,val:0},overResult:{vis:!1,val:0},bleed:{vis:"anti"===a}};s.append(`\n
                                  \n ${z("wiki_calc_effective",[z("plasmid"===a?"resource_Plasmid_plural_name":"resource_AntiPlasmid_plural_name")])} {{ i.plas.val | effective }} - \n ${z("wiki_calc_softcap")} {{ i.phage.val | softcap }}\n
                                  \n
                                  \n ${z("wiki_calc_under_cap")}\n
                                  \n
                                  \n (ln(({{ i.plas.val, t | generic }} / {{ | bleedDiv }}) + 50) - 3.91202) / 2.888 / 3 = {{ false | calcUnder }} = +{{ true | calcUnder }}%\n
                                  \n
                                  \n ${z("wiki_calc_over_cap")}\n
                                  \n
                                  \n ((((ln({{ i.phage.val, 'phage' | generic }} + 300) - 3.91202)) / 2.888) + ((ln(({{ i.plas.val, t | generic }} / {{ | bleedDiv }}) + 1 - ({{ i.phage.val, 'phage' | generic }} + 250)) / ln2 / 250))) / 3 = {{ false | calcOver }} = +{{ true | calcOver }}%\n
                                  \n `),n.append(`\n
                                  \n
                                  ${z("plasmid"===a?"resource_Plasmid_plural_name":"resource_AntiPlasmid_plural_name")}
                                  \n
                                  ${z("resource_Phage_name")}
                                  \n
                                  ${z("universe_antimatter")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:`#${a}ProdCalc`,data:{i:c,s:o,t:a},methods:{val(e){c[e].val&&c[e].val<0&&(c[e].val=0)},bleed(){c.antimatter.val&&"plasmid"===a||!c.antimatter.val&&"anti"===a?o.bleed.vis=!0:o.bleed.vis=!1},resetInputs(){c.plas.val=void 0,c.phage.val=void 0,c.antimatter.val=!1},importInputs(){c.plas.val="plasmid"===a?t.prestige.Plasmid.count:t.prestige.AntiPlasmid.count,c.phage.val=t.prestige.Phage.count,c.antimatter.val="antimatter"===t.race.universe}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"plasmid":return z("resource_Plasmid_plural_name");case"anti":return z("resource_AntiPlasmid_plural_name");case"phage":return z("resource_Phage_name")}},effective:e=>void 0===e?0:o.bleed.vis?e/("plasmid"===a?40:4):e,softcap:e=>250+(void 0===e?0:e),bleedDiv:()=>"plasmid"===a?40:4,calcUnder(e){if(e)return(100*o.underResult.val).toFixed(3);let t=c.plas.val;o.bleed.vis&&(t/="plasmid"===a?40:4);let r=!0;if((void 0===c.plas.val||t>250+c.phage.val)&&(r=!1),o.underResult.vis=r,o.underResult.vis){let e=+(Math.log(t+50)-3.91202).toFixed(5)/2.888;return"anti"===a&&(e/=3),o.underResult.val=e.toFixed(5),o.underResult.val}},calcOver(e){if(e)return(100*o.overResult.val).toFixed(3);let t=c.plas.val;o.bleed.vis&&(t/="plasmid"===a?40:4);let r=!0;if((void 0===c.phage.val||t<=250+c.phage.val)&&(r=!1),o.overResult.vis=r,o.overResult.vis){let e=+(Math.log(250+c.phage.val+50)-3.91202).toFixed(5)/2.888+Math.log(t+1-(250+c.phage.val))/Math.LN2/250;return"anti"===a&&(e/=3),o.overResult.val=e.toFixed(5),o.overResult.val}}}})}function bc(e,a){let r=$(`
                                  `);e.append(r);let i=z("phage"===a?"resource_Phage_name":"anti"===a?"resource_AntiPlasmid_name":"resource_Plasmid_name"),s=z("phage"===a?"resource_Phage_name":"anti"===a?"resource_AntiPlasmid_plural_name":"resource_Plasmid_plural_name");r.append(`

                                  ${z("wiki_calc_bonuses",[z("wiki_calc_store",[i])])}

                                  `);let n=$("
                                  "),c=$("
                                  ");r.append(n),r.append(c);let o={res:{val:void 0},store:{val:void 0},antimatter:{val:!1,use:!0}};"phage"===a&&(o.antimatter.use=!1);let l={result:{vis:!1,val:0},bleed:{vis:"anti"===a}},_="";"phage"!==a&&(_+=`\n
                                  \n ${z("wiki_calc_effective",[s])} {{ i.res.val | effective }}\n
                                  \n `),_+='\n
                                  \n ({{ i.res.val, t | generic }} / {{ | bleedDiv }}) * {{ i.store.val | storeVal }} = {{ false | calc }} = +{{ true | calc }}%\n
                                  \n ',n.append(_),c.append(`\n
                                  \n
                                  ${s}
                                  \n
                                  ${z("wiki_tech_special_crispr",[z("wiki_arpa_crispr_store")])} \n \n {{ 0 | storeLabel }}\n {{ 1 | storeLabel }}\n {{ 2 | storeLabel }}\n {{ 3 | storeLabel }}\n {{ 4 | storeLabel }}\n
                                  \n
                                  ${z("universe_antimatter")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:`#${a}StoreCalc`,data:{i:o,s:l,t:a},methods:{val(){o.res.val&&o.res.val<0&&(o.res.val=0)},pickStore(e){o.store.val=e},bleed(){"phage"!==a&&(o.antimatter.val&&"plasmid"===a||!o.antimatter.val&&"anti"===a?l.bleed.vis=!0:l.bleed.vis=!1)},resetInputs(){o.res.val=void 0,o.store.val=void 0,o.antimatter.val=!1},importInputs(){o.res.val="phage"===a?t.prestige.Phage.count:"plasmid"===a?t.prestige.Plasmid.count:t.prestige.AntiPlasmid.count,o.store.val=t.genes.store||0,o.antimatter.val="antimatter"===t.race.universe}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"plasmid":return z("resource_Plasmid_plural_name");case"anti":return z("resource_AntiPlasmid_plural_name");case"phage":return z("resource_Phage_name")}},storeVal(e){if(void 0===e)return z("wiki_calc_store_multi");if(0===e||"phage"===a&&e<4)return 0;switch(e){case 1:return 4e-4;case 2:return 6e-4;default:return 8e-4}},effective:e=>void 0===e?0:l.bleed.vis?e/("plasmid"===a?40:4):e,storeLabel:e=>void 0===e?z("wiki_tech_special_crispr",[z("wiki_arpa_crispr_store")]):e?z("wiki_arpa_crispr_store")+": "+e:z("wiki_calc_not_owned"),bleedDiv:()=>"plasmid"===a?5:10,calc(e){if(e)return(100*l.result.val).toFixed(2);let t=o.res.val;if(l.bleed.vis&&(t/="plasmid"===a?5:10),l.result.vis=void 0!==o.res.val&&void 0!==o.store.val,l.result.vis){if(0===o.store.val||"phage"===a&&o.store.val<4)l.result.val=0;else switch(o.store.val){case 1:l.result.val=(4e-4*t).toFixed(4);break;case 2:l.result.val=(6e-4*t).toFixed(4);break;default:l.result.val=(8e-4*t).toFixed(4)}return l.result.val}}}})}function wc(e){let t=Ln("create",e),a=["mad","bioseed","blackhole","ascension","cataclysm","vacuum","infusion","ai","terraform"],r=a.map((e=>`${z(`wiki_resets_${e}`)}`));In(t,{name:"intro",template:"resets",paragraphs:3,h_level:2,para_data:{1:[a.length,r.slice(0,-1).join(", ")+`, & ${r[r.length-1]}`]},data_color:{1:["warning","plain"]}}),Ln("add","resets-prestige","intro",z("wiki_menu_intro"));let i=In(t,{name:"mad",template:"resets",paragraphs:9,break:[6,9],h_level:2,para_data:{3:[z("wiki_p_res_plasmids")],4:[z("tech_rocketry"),z("tech_mad")],5:[z("tab_civics"),z("tab_military")],6:[z("wiki_p_res_plasmids")],7:[z("wiki_p_res_plasmids")],9:[z("wiki_resets_mad")]},data_color:{3:["danger"],6:["danger"],7:["danger"]}});i=Bn(i,"mad","gain"),fc(i,"plasmid",!1,"mad"),Ln("add","resets-prestige","mad",z("wiki_resets_mad")),i=In(t,{name:"bioseed",template:"resets",paragraphs:12,break:[5,8,12],h_level:2,para_data:{2:[z("tech_genesis_ship")],3:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage")],4:[z("wiki_p_res_plasmids")],5:[z("tech_genesis_ship"),z("tech_star_dock")],6:[z("tech_interstellar"),z("tech_star_dock")],7:[z("tech_genesis_ship")],9:[z("tech_interstellar"),z("star_dock_probe_desc")],10:[z("wiki_planet_planet")],12:[z("wiki_resets_bioseed")]},data_color:{3:["danger","danger"],4:["danger"]},data_link:{10:["wiki.html#planets-gameplay"]}}),i=Bn(i,"bioseed","gain"),fc(i,"plasmid",!1,"bioseed"),fc(i,"phage",!1,"bioseed"),Ln("add","resets-prestige","bioseed",z("wiki_resets_bioseed"));let s=[];Object.keys(Wt).forEach((function(e){s.push(e)}));let n=s.map((e=>`${z(`universe_${e}`)}`));i=In(t,{name:"blackhole",template:"resets",paragraphs:12,break:[3,6,9,12],h_level:2,para_data:{2:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_dark")],3:[z("tech_dist_stellar_engine")],4:[z("tech_mass_ejector"),z("wiki_resets_blackhole_exotic"),.025,z("resource_Elerium_name"),z("resource_Infernite_name")],5:[z("wiki_p_res_dark")],6:[z("wiki_resets_blackhole_exotic"),z("tech_exotic_infusion")],7:[10,z("wiki_hell_soul_gem")],8:[z("tech_stabilize_blackhole"),z("wiki_resets_blackhole_exotic")],10:[s.length,n.slice(0,-1).join(", ")+`, ${z("or")} ${n[n.length-1]}`],12:[z("wiki_resets_blackhole")]},data_color:{2:["danger","danger","danger"],4:["warning","warning","warning","caution","caution"],5:["danger"],7:["warning","caution"],10:["warning","plain"]}}),i=Bn(i,"bigbang","gain"),fc(i,"plasmid",!1,"bigbang"),fc(i,"phage",!1,"bigbang"),fc(i,"dark",!1,"bigbang"),Ln("add","resets-prestige","blackhole",z("wiki_resets_blackhole")),i=In(t,{name:"vacuum",template:"resets",paragraphs:10,break:[4,8,10],h_level:2,para_data:{4:[80],6:[z("arpa_syphon_damage")],7:[80],8:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_dark")],9:[z("wiki_p_res_dark")],10:[z("wiki_resets_vacuum")]},data_color:{6:["danger"],8:["danger","danger","danger"],9:["danger"]}}),i=Bn(i,"vacuum","gain"),fc(i,"plasmid",!1,"vacuum"),fc(i,"phage",!1,"vacuum"),fc(i,"dark","vacuum","vacuum"),Ln("add","resets-prestige","vacuum",z("wiki_resets_vacuum")),i=In(t,{name:"ascension",template:"resets",paragraphs:10,break:[3,5,7,10],h_level:2,para_data:{2:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_harmony")],3:[z("interstellar_ascension_machine"),"10,000",z("interstellar_thermal_collector")],4:[100,25],7:["+2%"],8:["+2","+5%","+10%"],10:[z("wiki_resets_ascension")]},data_color:{2:["danger","danger","danger"]}}),i=Bn(i,"ascend","gain"),fc(i,"plasmid",!1,"ascend"),fc(i,"phage",!1,"ascend"),fc(i,"harmony",!1,"ascend"),Ln("add","resets-prestige","ascension",z("wiki_resets_ascension")),i=In(t,{name:"cataclysm",template:"resets",paragraphs:10,break:[4,7,10],h_level:2,para_data:{1:[z("planet_unstable")],2:[z("tech_world_collider")],3:[z("tech_dial_it_to_11"),z("tech_limit_collider")],6:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage")],10:[z("wiki_resets_cataclysm")]},data_color:{6:["danger","danger"]}}),i=Bn(i,"cataclysm","gain"),fc(i,"plasmid",!1,"cataclysm"),fc(i,"phage",!1,"cataclysm"),Ln("add","resets-prestige","cataclysm",z("wiki_resets_cataclysm")),i=In(t,{name:"terraform",template:"resets",paragraphs:19,break:[3,6,7,10,12,19],h_level:2,para_data:{1:[z("wiki_resets_terraform"),z("evo_challenge_orbit_decay")],2:[z("wiki_resets_ascension")],3:[z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_harmony")],7:[z("achieve_lamentis_name")],8:[1],10:[z("rejuvenated")],13:["10%"],14:["5%"],16:["2%","50%"],17:["50%"],19:[z("wiki_resets_terraform")]}}),i=Bn(i,"terraform","gain"),fc(i,"plasmid",!1,"terraform"),fc(i,"phage",!1,"terraform"),fc(i,"harmony",!1,"terraform"),Ln("add","resets-prestige","terraform",z("wiki_resets_terraform")),i=In(t,{name:"infusion",template:"resets",paragraphs:8,break:[4,8],h_level:2,para_data:{2:[z("resource_Artifact_name")],5:[z("resource_Demonic_Essence_name")],6:[z("resource_Demonic_Essence_name")],7:[z("achieve_corrupted_name")],8:[z("wiki_resets_infusion")]},data_color:{2:["danger"],7:["caution"]}}),i=Bn(i,"descend","gain"),fc(i,"artifact",!1,"descend"),Ln("add","resets-prestige","infusion",z("wiki_resets_infusion")),i=In(t,{name:"ai",template:"resets",paragraphs:8,break:[3,6,7,8],h_level:2,para_data:{2:[z("evo_challenge_truepath")],3:[z("space_ai_core"),z("wiki_resets_ai_drift"),"100%"],4:[z("tech_protocol66")],5:[z("space_ai_colonist_title"),z("space_decoder_title"),z("space_shock_trooper_title"),z("space_tank_title")],6:[z("wiki_resets_ai"),z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("wiki_p_res_ai_core")],7:[z("genelab_genus_synthetic")],8:[z("wiki_resets_ai")]},data_color:{6:["warning","danger","danger","danger"]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"],3:["wiki.html#space-tp_structures-ai_core"],4:["wiki.html#solar-tp_tech-protocol66"],5:["#space-tp_structures-ai_colonist","#space-tp_structures-decoder","#space-tp_structures-shock_trooper","#space-tp_structures-tank"]}}),i=Bn(i,"ai","gain"),fc(i,"plasmid",!1,"ai"),fc(i,"phage",!1,"ai"),fc(i,"cores",!1,"ai"),Ln("add","resets-prestige","ai",z("wiki_resets_ai")),i=In(t,{name:"matrix",template:"resets",paragraphs:6,break:[3,5,6],h_level:2,para_data:{2:[z("evo_challenge_truepath")],3:[z("tau_star_ringworld")],5:[z("wiki_resets_matrix"),z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("civics_servants")],6:[z("wiki_resets_matrix")]},data_color:{5:["warning","danger","danger","danger"]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"],3:["wiki.html#tauceti-structures-ringworld"]}}),i=Bn(i,"matrix","gain"),fc(i,"plasmid",!1,"matrix"),fc(i,"phage",!1,"matrix"),Ln("add","resets-prestige","matrix",z("wiki_resets_matrix")),i=In(t,{name:"retired",template:"resets",paragraphs:6,break:[3,5,6],h_level:2,para_data:{2:[z("evo_challenge_truepath")],3:[z("tech_matrioshka_brain"),z("tech_ignition_device")],5:[z("wiki_resets_retired"),z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("civics_servants")],6:[z("wiki_resets_retired")]},data_color:{5:["warning","danger","danger","danger"]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"],3:["wiki.html#tauceti-structures-matrioshka_brain","wiki.html#tauceti-structures-ignition_device"]}}),i=Bn(i,"retired","gain"),fc(i,"plasmid",!1,"retired"),fc(i,"phage",!1,"retired"),Ln("add","resets-prestige","retired",z("wiki_resets_retired")),i=In(t,{name:"eden",template:"resets",paragraphs:6,break:[3,5,6],h_level:2,para_data:{2:[z("evo_challenge_lone_survivor")],3:[z("tau_star_ringworld")],4:[z("tau_star_goe_facility")],5:[z("wiki_resets_eden"),z("wiki_p_res_plasmids"),z("wiki_p_res_phage"),z("civics_servants")],6:[z("wiki_resets_eden")]},data_color:{5:["warning","danger","danger","danger"]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"],3:["wiki.html#tauceti-structures-ringworld"],4:["wiki.html#tauceti-structures-goe_facility"]}}),i=Bn(i,"eden","gain"),fc(i,"plasmid",!1,"eden"),fc(i,"phage",!1,"eden"),Ln("add","resets-prestige","eden",z("wiki_resets_eden"))}function kc(e){let a=$("#content");switch(Ss(a),e){case"basics":!function(e){In(e,{name:"start",template:"basics",paragraphs:2,h_level:2}),In(e,{name:"prehistoric",template:"basics",paragraphs:14,break:[2,6,13],h_level:2,para_data:{3:[z("resource_RNA_name"),z("resource_DNA_name")],4:[z("evo_organelles_title"),z("resource_RNA_name"),z("evo_nucleus_title"),z("resource_DNA_name")],5:[z("evo_membrane_title"),z("evo_eukaryotic_title"),z("evo_mitochondria_title")],7:[z("genelab_genus")],8:[3],13:[z("evo_sentience_title")]},data_link:{7:["wiki.html#races-species"]}}),In(e,{name:"civilization",template:"basics",paragraphs:14,break:[2,8,13],h_level:2,para_data:{3:[z("tab_civics")],4:[z("resource_Food_name"),z("job_farmer"),z("job_hunter")],5:["*"],8:[z("resource_Food_name")],9:[z("resource_Food_name"),z("hunger")],10:[z("resource_Food_name")],11:[z("resource_Food_name")],12:[z("resource_Food_name")],13:[z("resource_Knowledge_name")],14:[z("resource_Knowledge_name"),z("city_university")]}}),In(e,{name:"government",template:"basics",paragraphs:8,break:[4],h_level:2,para_data:{1:[z("tech_government"),z("tab_civics"),z("govern_anarchy")],2:[z("tech_government"),z("govern_anarchy")],3:[z("tech_government")],4:[z("morale")],5:[z("morale")],6:[z("morale"),z("job_entertainer"),z("morale_stress")],7:[z("morale_tax"),z("morale")],8:[25,100]}}),In(e,{name:"mad",template:"basics",paragraphs:4,h_level:2,para_data:{1:[z("wiki_resets_mad")],2:[z("wiki_basics_mad_reset"),z("tab_civics"),z("tab_military")],3:[z("tab_space")]},data_link:{2:["wiki.html#resets-prestige"]}})}(a);break;case"mechanics":!function(e){let a=Ln("create",e);In(a,{name:"save",template:"mechanics",label:z("wiki_mechanics_save"),paragraphs:8,break:[3,5],h_level:2,para_data:{1:["~5"],3:[z("wiki_mechanics_save_export")],4:[z("export")],5:[z("restore")],8:[z("restore")]}}),Ln("add","mechanics-gameplay","save",z("wiki_mechanics_save")),In(a,{name:"atime",template:"mechanics",label:z("wiki_mechanics_atime"),paragraphs:6,break:[4,6],h_level:2,para_data:{1:[z("wiki_mechanics_atime")],2:[2,z("wiki_mechanics_atime")],3:["2x",z("wiki_mechanics_atime")],4:[z("wiki_mechanics_atime"),8],5:[12,8,z("wiki_mechanics_atime")],6:[z("wiki_mechanics_atime")]}}),Ln("add","mechanics-gameplay","atime",z("wiki_mechanics_atime")),In(a,{name:"spack",template:"mechanics",label:z("wiki_mechanics_spack"),paragraphs:10,break:[4,6,7,8,9,10],h_level:2,para_data:{1:["UTF-8","JSON",".txt"],4:[`${z("wiki_mechanics_spack_para4_note")}`],6:[z("resource_Food_name"),z("wiki_mechanics_spack_para6_note1"),z("city_biolab"),z("wiki_mechanics_spack_para6_note2")]}}),Ln("add","mechanics-gameplay","spack",z("wiki_mechanics_spack")),In(a,{name:"job",template:"mechanics",label:z("wiki_mechanics_job"),paragraphs:9,break:[5],h_level:2,para_data:{1:[z("wiki_mechanics_job")],2:["*"],3:[z("wiki_mechanics_job")]}}),Ln("add","mechanics-gameplay","job",z("wiki_mechanics_job")),function(e){let a=$('
                                  ');e.append(a);let r=$("
                                  "),i=$("
                                  "),s=$("
                                  ");a.append(r),a.append(i),a.append(s);let n={job:{val:void 0},content:{vis:!1,val:void 0},freespirit:{vis:!1,val:void 0},mellow:{val:!1},dense:{vis:!1,val:!1,formVis:!1},workers:{val:void 0},playful:{vis:!1,val:!1},high_pop:{val:void 0},emotionless:{val:void 0},government:{val:void 0},annexed:{vis:!1,val:void 0},electricity:{vis:!1,val:!1},virtual_reality:{val:!1}},c={result:{vis:!1,val:void 0},total:{vis:!1,val:0}},o=["soldier"];Object.keys(Xt).forEach((function(e){"unemployed"!==e&&"forager"!==e&&o.push(e)}));let l=`\n
                                  ${z("wiki_calc_job_stress_job")} \n `;o.forEach((function(e){l+=`\n {{ '${e}' | jobLabel }}`})),l+="\n
                                  \n ",r.append(l),i.append(`\n
                                  \n

                                  ${z("wiki_calc_job_stress_divisor")}

                                  \n
                                  \n
                                  \n ({{ i.job.val | stressDiv }} + ({{ i.content.val, 'content' | generic }} * {{ i.job.val | contentVal }}) {{ i.job.val | mellowOp }} - 1) / {{ i.freespirit.val, 'freespirit', 0 | traitVal }} = {{ | calc }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_job_stress_generated")}

                                  \n
                                  \n
                                  \n 0 * {{ i.workers.val, 'workers' | generic }} / {{ i.high_pop.val, 'high_pop', 0 | traitVal }} / {{ s.result.val, 'divisor' | generic }} * {{ i.emotionless.val, 'emotionless', 1 | traitVal }} * {{ i.government.val, i.electricity.val, i.virtual_reality.val | govVal }} * {{ i.annexed.val | anxVal }} = -{{ | calcTotal }}%\n
                                  \n `),s.append(`\n
                                  \n
                                  ${z("wiki_calc_job_stress_content")}
                                  \n
                                  ${z("planet_mellow")}
                                  \n
                                  ${z("planet_dense")}
                                  \n
                                  ${z("trait_freespirit_name")} \n \n {{ 0 | traitLabel }}\n {{ 0.25 | traitLabel }}\n {{ 0.5 | traitLabel }}\n {{ 1 | traitLabel }}\n {{ 2 | traitLabel }}\n {{ 3 | traitLabel }}\n
                                  \n
                                  \n
                                  \n
                                  {{ i.job.val | workersLabel }}
                                  \n
                                  ${z("wiki_calc_job_stress_annexed")}
                                  \n
                                  ${z("civics_government")} \n \n {{ 'anarchy' | govLabel }}\n {{ 'autocracy' | govLabel }}\n {{ 'federation' | govLabel }}\n {{ 'socialist' | govLabel }}\n {{ 'other' | govLabel }}\n
                                  \n
                                  ${z("tech_electricity")}
                                  \n
                                  ${z("tech_virtual_reality")}
                                  \n
                                  ${z("trait_playful_name")}
                                  \n
                                  ${z("trait_high_pop_name")} \n \n {{ 0 | traitLabel }}\n {{ 0.25 | traitLabel }}\n {{ 0.5 | traitLabel }}\n {{ 1 | traitLabel }}\n {{ 2 | traitLabel }}\n {{ 3 | traitLabel }}\n
                                  \n
                                  ${z("trait_emotionless_name")} \n \n {{ 0 | traitLabel }}\n {{ 0.25 | traitLabel }}\n {{ 0.5 | traitLabel }}\n {{ 1 | traitLabel }}\n {{ 2 | traitLabel }}\n {{ 3 | traitLabel }}\n
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:"#jobStressCalc",data:{i:n,s:c},methods:{val(e){n[e].val&&n[e].val<0&&(n[e].val=0),"annexed"===e&&n[e].val>3&&(n[e].val=3)},pickJob(e){n.job.val=e,n.content.vis="hunter"!==e&&"soldier"!==e,n.freespirit.vis=!["hunter","soldier","farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(e),n.dense.vis="miner"===e,n.playful.vis="hunter"===e},pickGov(e){n.government.val=e,n.annexed.vis="federation"!==e,n.electricity.vis="autocracy"===e},pickTrait(e,t){n[t].val=e},resetInputs(){n.job.val=void 0,n.content.val=void 0,n.content.vis=!1,n.freespirit.val=void 0,n.freespirit.vis=!1,n.mellow.val=!1,n.dense.val=!1,n.dense.vis=!1,n.workers.val=void 0,n.playful.val=!1,n.playful.vis=!1,n.government.val=void 0,n.annexed.val=void 0,n.annexed.vis=!1,n.electricity.val=!1,n.electricity.vis=!1,n.virtual_reality.val=!1,n.high_pop.val=void 0,n.emotionless.val=void 0,c.result.val=void 0},importInputs(){if(n.content.val=t.race.content?t.race.content:0,n.freespirit.val=t.race.freespirit?t.race.freespirit:0,n.mellow.val=!(!t.city.ptrait||!t.city.ptrait.includes("mellow")),n.dense.val=!(!t.city.ptrait||!t.city.ptrait.includes("dense")),n.workers.val="soldier"===n.job.val?t.civic.garrison&&t.civic.garrison.max?t.civic.garrison.max:0:t.civic[n.job.val]?t.civic[n.job.val].workers:0,n.playful.val=!!t.race.playful,n.high_pop.val=t.race.high_pop?t.race.high_pop:0,n.emotionless.val=t.race.emotionless?t.race.emotionless:0,t.civic.govern){let e=t.civic.govern.type;switch(e){case"autocracy":case"anarchy":case"socialist":case"federation":n.government.val=e;break;default:n.government.val="other"}n.annexed.vis="federation"!==e,n.electricity.vis="autocracy"===e}if(n.annexed.val=0,t.civic.foreign)for(let e=0;e<3;e++)t.civic.foreign["gov"+e].anx&&n.annexed.val++;n.electricity.val=!!t.tech.high_tech&&t.tech.high_tech>=2,n.virtual_reality.val=!!t.tech.high_tech&&t.tech.high_tech>=12}},filters:{generic:(e,t)=>("workers"===t&&"soldier"===n.job.val&&(t="soldiers"),void 0!==e?e:z("wiki_calc_job_stress_"+t)),jobLabel:e=>e?"soldier"===e?z("governor_soldier"):"titan_colonist"===e?z("job_colonist_tp",[Kn("titan")]):z("job_"+e):z("wiki_calc_job_stress_job"),workersLabel:e=>z("soldier"===e?"wiki_calc_job_stress_soldiers":"wiki_calc_job_stress_workers"),govLabel:e=>z(e?"other"===e?"wiki_calc_job_stress_government_other":"govern_"+e:"civics_government"),traitLabel:e=>void 0===e?z("wiki_calc_trait_undefined"):0===e?z("wiki_calc_trait_unowned"):e,stressDiv(e){if(!e)return z("base");switch(e){case"hunter":return 5;case"soldier":return 2;default:return t.civic[e].stress}},contentVal:e=>e?"hell_surveyor"===e?.2:.4:z("wiki_calc_job_stress_content_multi"),mellowOp(e){switch(e){case"hunter":case"soldier":return`* ${ss.mellow.vars()[0]}`;default:return`+ ${ss.mellow.vars()[1]}`}},govVal(e,t,a){if(!e)return z("wiki_calc_job_stress_government");switch(e){case"anarchy":return.5;case"autocracy":return t?a?1.1:1.18:1.25;case"socialist":return 1.1;default:return 1}},anxVal:e=>void 0!==e?+(1.1**e).toFixed(5):z("civics_spy_purchase_bd"),traitVal(e,t,a){switch(t){case"freespirit":return 1+Ei.freespirit.vars(e)[a]/100;case"high_pop":return Ei.high_pop.vars(e)[a];case"emotionless":return 1-Ei.emotionless.vars(e)[a]/100}},calc(){let e=void 0!==n.job.val&&void 0!==n.freespirit.val;if("hunter"!==n.job.val&&"soldier"!==n.job.val&&(e=e&&void 0!==n.content.val),c.result.vis=e,c.result.vis){let e="hunter"===n.job.val?5:"soldier"===n.job.val?2:t.civic[n.job.val].stress;return"hunter"===n.job.val||"soldier"===n.job.val?n.mellow.val&&(e*=ss.mellow.vars()[0]):(n.mellow.val&&(e+=ss.mellow.vars()[1]),e+=("hell_surveyor"===n.job.val?.2:.4)*n.content.val,n.dense.val&&"miner"===n.job.val&&(e-=ss.dense.vars()[1]),n.freespirit.val&&!["farmer","lumberjack","quarry_worker","crystal_miner","scavenger"].includes(n.job.val)&&(e/=1+Ei.freespirit.vars(n.freespirit.val)[0]/100)),c.result.val=+e.toFixed(4),c.result.val}c.result.val=void 0},calcTotal(){let e=n.playful.val&&"hunter"===n.job.val;if(e)c.total.vis=e,c.total.val=0;else if(e=c.result.vis&&n.government.val&&void 0!==n.workers.val&&void 0!==n.high_pop.val&&void 0!==n.emotionless.val,"federation"!==n.government.val&&(e=e&&void 0!==n.annexed.val),c.total.vis=e,c.total.vis){let e=n.workers.val/c.result.val;if("federation"!==n.government.val)switch(e*=1.1**n.annexed.val,n.government.val){case"anarchy":e/=2;break;case"autocracy":e*=n.electricity.val?n.virtual_reality.val?1.1:1.18:1.25;break;case"socialist":e*=1.1}n.high_pop.val&&(e/=Ei.high_pop.vars(n.high_pop.val)[0]),n.emotionless.val&&(e*=1-Ei.emotionless.vars(n.emotionless.val)[1]/100),c.total.val=+e.toFixed(3)}return c.total.val}}})}(Bn(In(a,{name:"job_stress",template:"mechanics",label:z("wiki_mechanics_job_stress"),paragraphs:7,break:[3,5,6,7],h_level:2,para_data:{2:[z("job_unemployed"),z("trait_content_name")],3:[z("wiki_calc_job_stress_divisor"),1],4:[z("trait_freespirit_name"),z("trait_content_name"),z("planet_mellow")],6:[z("trait_optimistic_name"),z("trait_pessimistic_name"),z("morale_stress"),z("morale")],7:[z("civics_garrison_annex")]},data_link:{2:[!1,"wiki.html#traits-species-minor_content"],4:["wiki.html#traits-species-major_freespirit","wiki.html#traits-species-minor_content","wiki.html#planets-gameplay-mellow"],6:["wiki.html#traits-species-major_optimistic","wiki.html#traits-species-major_pessimistic"]}}),"mechanics","job_stress",z("wiki_mechanics_job_stress"))),Ln("add","mechanics-gameplay","job_stress",z("wiki_mechanics_job_stress")),In(a,{name:"multiplier",template:"mechanics",label:z("wiki_mechanics_multiplier"),paragraphs:5,break:[4],h_level:2,para_data:{1:[z("wiki_mechanics_multiplier")],2:["10x",t.settings.keyMap.x10,"25x",t.settings.keyMap.x25,"100x",t.settings.keyMap.x100],4:[z("wiki_mechanics_multiplier")],5:[z("wiki_mechanics_multiplier")]},data_color:{2:["warning","caution","warning","caution","warning","caution"]}}),Ln("add","mechanics-gameplay","multiplier",z("wiki_mechanics_multiplier")),In(a,{name:"cost_creep",template:"mechanics",label:z("wiki_mechanics_cost_creep"),paragraphs:7,break:[4,7],h_level:2,para_data:{2:[z("resource_Lumber_name"),200,1.3,"200*1.3=260","200*1.3^2=338"],3:[z("wiki_menu_arpa")],5:[z("tech_steel_beams"),z("trait_large_name"),z("tab_arpa_crispr"),z("wiki_arpa_crispr_creep")],6:[z("trait_creative_name"),z("wiki_menu_arpa")],7:[1.005]},data_link:{3:["wiki.html#projects-arpa"],5:["wiki.html#discovery-tech-steel_beams","wiki.html#traits-species-genus_large",!1,"wiki.html#crispr-prestige-genetic_memory"],6:["wiki.html#traits-species-major_creative"]}}),Ln("add","mechanics-gameplay","cost_creep",z("wiki_mechanics_cost_creep")),In(a,{name:"queue",template:"mechanics",label:z("wiki_mechanics_queue"),paragraphs:13,break:[4,6,9,10,11,13],h_level:2,para_data:{1:[z("wiki_mechanics_queue"),z("tech_urban_planning")],2:[z("building_queue")],4:[z("wiki_mechanics_queue_research"),z("tech_assistant")],7:[z("q_key"),t.settings.keyMap.q],8:[z("q_key")],10:[z("q_any")],12:[z("q_merge")]},data_color:{7:["warning","caution"]}}),Ln("add","mechanics-gameplay","queue",z("wiki_mechanics_queue"));{let e=In(a,{name:"multipliers",template:"mechanics",label:z("wiki_mechanics_multipliers"),paragraphs:1,h_level:2});In(e,{name:"multipliers_prod",template:"mechanics",label:z("wiki_mechanics_multipliers"),paragraphs:4,break:[3,4],h_level:!1,para_data:{3:[z("wiki_mechanics_multipliers_struct"),z("wiki_mechanics_multipliers_bonus")]}}).append('
                                  '),In(e,{name:"multipliers_dis",template:"mechanics",label:z("wiki_mechanics_multipliers"),paragraphs:7,break:[3,4],h_level:!1,para_data:{3:[z("wiki_mechanics_multipliers_base"),z("wiki_mechanics_multipliers_discount"),z("wiki_mechanics_multipliers_struct")],5:[z("city_mass_driver")],6:[100,z("city_mass_driver"),"5%",95,35.84],7:[100,.95,20,35.84]},data_link:{5:["wiki.html#planetary-structures-mass_driver"]}}),e.append(`
                                  ${z("wiki_mechanics_multipliers_exception")}
                                  `),Ln("add","mechanics-gameplay","multipliers",z("wiki_mechanics_multipliers"))}In(a,{name:"blocking",template:"mechanics",label:z("wiki_mechanics_blocking"),paragraphs:6,break:[4,6],h_level:2,para_data:{2:[z("color_red")],3:[z("color_orange")],5:[z("color_red")]},data_color:{2:["danger"],3:["caution"],5:["danger"]}}).append('
                                  '),Ln("add","mechanics-gameplay","blocking",z("wiki_mechanics_blocking")),In(a,{name:"astro",template:"mechanics",label:z("wiki_mechanics_astro"),paragraphs:15,break:[3,4,5,6,7,8,9,10,11,12,13,14,15],h_level:2,para_data:{2:[12],3:[z("sign_aries"),z("sign_aries_symbol"),G("aries")[0]+"%"],4:[z("sign_taurus"),z("sign_taurus_symbol"),G("taurus")[0]+"%"],5:[z("sign_gemini"),z("sign_gemini_symbol"),G("gemini")[0]+"%"],6:[z("sign_cancer"),z("sign_cancer_symbol"),G("cancer")[0]],7:[z("sign_leo"),z("sign_leo_symbol"),G("leo")[0]+"%"],8:[z("sign_virgo"),z("sign_virgo_symbol"),G("virgo")[0]+"%"],9:[z("sign_libra"),z("sign_libra_symbol"),G("libra")[0]+"%"],10:[z("sign_scorpio"),z("sign_scorpio_symbol"),G("scorpio")[0]+"%"],11:[z("sign_sagittarius"),z("sign_sagittarius_symbol"),G("sagittarius")[0]+"%"],12:[z("sign_capricorn"),z("sign_capricorn_symbol"),G("capricorn")[0]+"%"],13:[z("sign_aquarius"),z("sign_aquarius_symbol"),G("aquarius")[0]+"%"],14:[z("sign_pisces"),z("sign_pisces_symbol")],15:[z(`sign_${N()}`)]},data_color:{3:["warning","caution","warning"],4:["warning","caution","warning"],5:["warning","caution","warning"],6:["warning","caution","warning"],7:["warning","caution","warning"],8:["warning","caution","warning"],9:["warning","caution","warning"],10:["warning","caution","warning"],11:["warning","caution","warning"],12:["warning","caution","warning"],13:["warning","caution","warning"],14:["warning","caution"],15:["caution"]}}),Ln("add","mechanics-gameplay","astro",z("wiki_mechanics_astro")),In(a,{name:"bank_vault",template:"mechanics",label:z("wiki_mechanics_bank_vault"),paragraphs:2,h_level:2,para_data:{1:[z("city_bank"),z("interstellar_exchange_title"),z("portal_arcology_title"),z("resource_Money_name"),z("wiki_mechanics_bank_vault"),z("space_red_spaceport_title"),z("wiki_challenges_scenarios_cataclysm")],2:[z("resource_Money_name"),z("city_bank"),z("tech_adamantite_vault"),z("governor_entrepreneur"),z("trait_paranoid_name"),z("tech_stock_market"),z("tech_unification"),z("wiki_challenges_modes_inflation")]},data_link:{1:["wiki.html#planetary-structures-bank","wiki.html#interstellar-structures-exchange","wiki.html#hell-structures-arcology",!1,!1,"wiki.html#space-structures-spaceport","wiki.html#challenges-gameplay-scenarios_cataclysm"],2:[!1,!1,"wiki.html#interstellar-tech-adamantite_vault","wiki.html#governor-gameplay-entrepreneur","wiki.html#traits-species-major_paranoid","wiki.html#projects-arpa-stock_exchange","wiki.html#early_space-tech-unification2","wiki.html#challenges-gameplay-modes_inflation"]}}),Ln("add","mechanics-gameplay","bank_vault",z("wiki_mechanics_bank_vault")),In(a,{name:"homeless",template:"mechanics",label:z("wiki_mechanics_homeless"),paragraphs:4,break:[3],h_level:2,para_data:{3:[z("arpa_projects_railway_title")]},data_link:{3:["wiki.html#projects-arpa-railway"]}}),Ln("add","mechanics-gameplay","homeless",z("wiki_mechanics_homeless")),function(e){let a=$('
                                  ');e.append(a),a.append(`

                                  ${z("wiki_mechanics_warmonger")}

                                  `);let r=$("
                                  "),i=$("
                                  ");a.append(r),a.append(i);let s={fatigue:{val:void 0},protest:{val:void 0}},n={result:{vis:!1,val:0}};r.append(`\n
                                  \n log2({{ i.fatigue.val, 'fatigue' | generic }} + {{ i.protest.val, 'protest' | generic }}) = {{ false | calc }} = {{ true | calc }}% ${z("wiki_mechanics_warmonger")}\n
                                  \n `),i.append(`\n
                                  \n
                                  ${z("wiki_calc_warmonger_fatigue")}
                                  \n
                                  ${z("wiki_calc_warmonger_protest")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:"#warmongerCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.fatigue.val=void 0,s.protest.val=void 0},importInputs(){s.fatigue.val=t.civic.garrison&&t.civic.garrison.fatigue?t.civic.garrison.fatigue:0,s.protest.val=t.civic.garrison&&t.civic.garrison.protest?t.civic.garrison.protest:0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_warmonger_"+t),calc:e=>e?Math.round(n.result.val):(n.result.vis=void 0!==s.fatigue.val&&void 0!==s.protest.val&&s.fatigue.val+s.protest.val>=1,n.result.vis?(n.result.val=Math.log2(s.fatigue.val+s.protest.val),n.result.val):void 0)}})}(Bn(In(a,{name:"warmonger",template:"mechanics",label:z("wiki_mechanics_warmonger"),paragraphs:8,break:[4],h_level:2,para_data:{2:[z("trait_immoral_name")],3:[z("govern_autocracy"),z("trait_blood_thirst_name")],4:[z("wiki_calc_warmonger_fatigue"),z("wiki_calc_warmonger_protest")],5:[z("achieve_warmonger_name")],6:[z("wiki_calc_warmonger_fatigue"),1,z("wiki_calc_warmonger_protest")],7:[z("wiki_calc_warmonger_fatigue"),z("wiki_calc_warmonger_protest"),1,0],8:[`log2(${z("wiki_calc_warmonger_fatigue")} + ${z("wiki_calc_warmonger_protest")})`]},data_link:{2:["wiki.html#traits-species-genus_immoral"],3:["wiki.html#government-gameplay-autocracy","wiki.html#traits-species-major_blood_thirst"]}}),"mechanics","warmonger",z("wiki_mechanics_warmonger"))),Ln("add","mechanics-gameplay","warmonger",z("wiki_mechanics_warmonger")),function(e){let t=$('
                                  ');e.append(t);let a=$("
                                  "),r=$("
                                  ");t.append(a),t.append(r);let i={military:{val:void 0},relations:{val:void 0},unrest:{val:void 0},spies:{val:void 0},infiltrator:{val:!1}},s={base:{vis:!1,val:void 0},total:{vis:!1,val:void 0}};a.append(`\n
                                  \n

                                  ${z("wiki_calc_spy_cost_base_title")}

                                  \n
                                  \n
                                  \n ({{ i.military.val, 'mil_rate' | generic }} / 2) + ((100 - {{ i.relations.val, 'relations' | generic }}) / 2) - {{ i.unrest.val, 'unrest' | generic }} + 10 = {{ | calcBase }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_spy_cost_total")}

                                  \n
                                  \n
                                  \n ({{ s.base.val, 'unrest' | generic }} / 3)^({{ i.spies.val, 'spies' | generic }} + 1) + 500 = {{ | calcTotal }}\n
                                  \n `),r.append(`\n
                                  \n
                                  ${z("civics_gov_mil_rate")}
                                  \n
                                  ${z("civics_gov_relations")}
                                  \n
                                  ${z("civics_gov_unrest")}
                                  \n
                                  \n
                                  \n
                                  ${z("wiki_calc_spy_cost_spies")}
                                  \n
                                  ${z("trait_infiltrator_name")}
                                  \n
                                  \n
                                  \n \n
                                  \n `),Cs({el:"#spyCostCalc",data:{i,s},methods:{val(e){i[e].val&&i[e].val<0&&(i[e].val=0),"military"!==e&&"spies"!==e&&i[e].val>100?i[e].val=100:"military"===e&&i[e].val<50&&(i[e].val=50)},resetInputs(){i.military.val=void 0,i.relations.val=void 0,i.unrest.val=void 0,i.spies.val=void 0,i.infiltrator.val=!1,s.base.val=void 0}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"spies":case"base":return z("wiki_calc_spy_cost_"+t);default:return z("civics_gov_"+t)}},calcBase(){if(s.base.vis=void 0!==i.military.val&&void 0!==i.relations.val&&void 0!==i.unrest.val,s.base.vis){let e=i.military.val/2+(100-i.relations.val)/2-i.unrest.val+10;return e<50&&(e=50),s.base.val=+e.toFixed(4),s.base.val}},calcTotal(){if(s.total.vis=void 0!==s.base.val&&void 0!==i.spies.val,s.total.vis){let e=s.base.val;return i.infiltrator.val&&(e/=3),s.total.val=+(e**(i.spies.val+1)+500).toFixed(2),s.total.val}}}})}(Bn(In(a,{name:"spy",template:"mechanics",label:z("wiki_mechanics_spy"),paragraphs:8,break:[3,4,5,6,7],h_level:2,para_data:{1:[z("tech_spy")],4:[1,z("civics_gov_relations"),z("civics_gov_mil_rate")],5:[2,z("civics_gov_mil_rate"),z("civics_gov_eco_rate")],6:[3,z("civics_gov_eco_rate"),z("civics_gov_unrest")],7:[4,z("civics_gov_unrest")],8:[4],9:[z("tech_espionage")]},data_link:{1:["wiki.html#civilized-tech-spy"],9:["wiki.html#civilized-tech-espionage"]}}),"mechanics","spy_cost")),Ln("add","mechanics-gameplay","spy",z("wiki_mechanics_spy")),function(e){let t=$('
                                  ');e.append(t);let a=$("
                                  "),r=$("
                                  ");t.append(a),t.append(r);let i={relations:{val:void 0},economic:{val:void 0},unrest:{val:void 0}},s={annex:{vis:!1,val:void 0},purchase:{vis:!1,val:void 0}};a.append(`\n
                                  \n

                                  ${z("wiki_calc_occupation_annex")}

                                  \n
                                  \n
                                  \n 300 - {{ i.relations.val, 'relations' | generic }} - {{ i.unrest.val, 'unrest' | generic }} = {{ | calcAnnex }}%\n
                                  \n
                                  \n

                                  ${z("wiki_calc_occupation_purchase")}

                                  \n
                                  \n
                                  \n ({{ i.economic.val, 'eco_rate' | generic }} * 15384) * (1 + (0.016 * (100 - {{ i.relations.val, 'relations' | generic }}))) * (1 - (0.0025 * {{ i.unrest.val, 'unrest' | generic }})) = {{ | calcPurchase }}\n
                                  \n `),r.append(`\n
                                  \n
                                  ${z("civics_gov_relations")}
                                  \n
                                  ${z("civics_gov_eco_rate")}
                                  \n
                                  ${z("civics_gov_unrest")}
                                  \n
                                  \n
                                  \n \n
                                  \n `),Cs({el:"#occupationCalc",data:{i,s},methods:{val(e){i[e].val&&i[e].val<0&&(i[e].val=0),"economic"!==e&&i[e].val>100&&(i[e].val=100)},resetInputs(){i.relations.val=void 0,i.economic.val=void 0,i.unrest.val=void 0}},filters:{generic:(e,t)=>void 0!==e?e:z("civics_gov_"+t),calcAnnex(){if(s.annex.vis=void 0!==i.relations.val&&void 0!==i.unrest.val,s.annex.vis)return s.annex.val=300-i.relations.val-i.unrest.val,s.annex.val},calcPurchase(){if(s.purchase.vis=void 0!==i.relations.val&&void 0!==i.economic.val&&void 0!==i.unrest.val,s.purchase.vis)return s.purchase.val=+(15384*i.economic.val*(1+.016*(100-i.relations.val))*(1-.0025*i.unrest.val)).toFixed(0),s.purchase.val}}})}(Bn(In(a,{name:"occupying",template:"mechanics",label:z("wiki_mechanics_occupying"),paragraphs:20,break:[3,8,12,16,18,19,20],h_level:2,para_data:{1:[z("civics_foreign"),z("civics_garrison_tactic_siege"),z("civics_spy_annex"),z("civics_spy_purchase")],2:["+5%","+8%",z("govern_federation")],3:[z("civics_garrison_tactic_siege"),20],5:[z("civics_garrison"),z("civics_garrison_tactic_siege")],6:[z("civics_garrison_unoccupy"),z("tech_unification")],7:[z("govern_federation"),15],8:["50%",z("civics_gov_relations"),"50%",z("civics_gov_unrest"),`(300 - ${z("civics_gov_relations")} - ${z("civics_gov_unrest")})`,z("morale")],9:["50%",z("civics_gov_relations"),"50%",z("civics_gov_unrest"),z("civics_spy_annex")],10:[z("morale"),z("civics_spy_annex")],11:[z("morale_stress"),"1.1x",z("govern_federation")],12:[z("resource_Money_name")],13:[3,z("tech_spy"),z("civics_spy_purchase")],14:[z("wiki_mechanics_occupying_para14_note1",[z("civics_gov_eco_rate"),z("civics_gov_relations"),z("civics_gov_unrest")]),z("resource_Money_name"),z("civics_spy_purchase")],15:[z("civics_garrison_purchase"),z("resource_Money_name"),z("morale_tax"),"20%",z("govern_federation")],16:[z("tech_unification")],17:[z("civics_garrison_occupy")],18:[z("achieve_world_domination_name")],19:[z("achieve_illuminati_name")],20:[z("achieve_syndicate_name")]},data_link:{2:[!1,!1,"wiki.html#government-gameplay-federation"],6:[!1,"wiki.html#early_space-tech-unification2"],7:["wiki.html#government-gameplay-federation"],11:[!1,!1,"wiki.html#government-gameplay-federation"],15:[!1,!1,!1,!1,"wiki.html#government-gameplay-federation"],16:["wiki.html#early_space-tech-unification2"]}}),"mechanics","occupation")),Ln("add","mechanics-gameplay","occupying",z("wiki_mechanics_occupying")),In(a,{name:"religion",template:"mechanics",label:z("wiki_mechanics_religion"),paragraphs:20,break:[3,6,8,15,20],h_level:2,para_data:{1:[z("wiki_mechanics_religion")],3:[z("city_temple")],4:[z("city_temple"),z("resource_Plasmid_plural_name")],5:[z("evo_challenge_plasmid"),z("faith")],6:[z("tech_fanaticism"),z("tech_anthropology")],8:[z("tech_fanaticism"),z("tech_indoctrination"),z("tech_missionary"),z("tech_zealotry")],9:[z("tech_fanaticism")],10:[z("wiki_menu_species")],11:[5],12:[z("tech_indoctrination")],13:[z("tech_missionary")],14:[z("tech_zealotry")],15:[z("tech_anthropology"),z("tech_mythology"),z("tech_archaeology"),z("tech_merchandising")],16:[z("tech_anthropology")],17:[z("tech_mythology")],18:[z("tech_archaeology")],19:[z("tech_merchandising")],20:[z("tab_arpa_crispr"),z("wiki_arpa_crispr_transcendence")]},data_link:{10:["wiki.html#races-species"],20:["wiki.html#crispr-prestige","wiki.html#crispr-prestige-transcendence"]}}),Ln("add","mechanics-gameplay","religion",z("wiki_mechanics_religion"));{let e=`${Hs("star")}`,t=`${Hs("star")}`,r=`${Hs("star")}`,i=`${Hs("star")}`;In(a,{name:"challenge",template:"mechanics",label:z("wiki_mechanics_challenge"),paragraphs:15,break:[4,8,14],h_level:2,para_data:{1:[z("wiki_mechanics_challenge"),z("wiki_menu_prehistoric"),z("tab_arpa_crispr"),z("arpa_genepool_hardened_genes_title")],2:[4,z("evo_challenge_plasmid"),z("evo_challenge_trade"),z("evo_challenge_craft"),z("evo_challenge_crispr")],4:[z("evo_challenge_plasmid"),z("resource_Plasmid_plural_name")],5:[z("evo_challenge_trade")],6:[z("evo_challenge_craft")],7:[z("evo_challenge_crispr"),z("wiki_arpa_crispr_creep"),"20%"],8:[z("wiki_mechanics_challenge")],9:[1,e,z("plain"),"5%"],10:[2,t,z("bronze"),"12%"],11:[3,r,z("silver"),"25%"],12:[4,i,z("gold"),"45%"],14:[z("wiki_mechanics_challenge"),e]},data_color:{2:["caution","warning","warning","warning","warning"],7:["warning","warning","caution"],9:["caution",!1,"warning","warning"],10:["caution",!1,"warning","warning"],11:["caution",!1,"warning","warning"],12:["caution",!1,"warning","warning"]},data_link:{1:[!1,!1,"wiki.html#crispr-prestige","wiki.html#crispr-prestige-hardened_genes"],7:[!1,"wiki.html#crispr-prestige-genetic_memory",!1]}}),Ln("add","mechanics-gameplay","challenge",z("wiki_mechanics_challenge"))}In(a,{name:"mastery",template:"mechanics",label:z("mastery"),paragraphs:15,break:[3,8,10,13],h_level:2,para_data:{1:[z("mastery"),z("tab_arpa_crispr"),z("arpa_genepool_unlocked_title")],2:[z("mastery"),z("tab_achieve")],4:["0.15%","0.10%"],5:[1],6:[1,5],7:["1.25%"],9:[z("standard"),"0.25%"],10:[z("arpa_genepool_universal_title"),z("arpa_genepool_standard_title")],11:[z("arpa_genepool_universal_title"),"0.05%","0.10%","0.15%"],12:["0.30%","1.50%"],13:[z("arpa_genepool_standard_title"),"0.05%"],15:[z("arpa_genepool_standard_title"),"0.20%","0.10%"]},data_color:{4:["caution","caution"],5:["caution"],6:["caution","caution"],7:["caution"],9:[!1,"caution"],11:["warning","caution","caution","caution"],12:["caution","caution"],13:["warning","caution"],15:["warning","caution","caution"]},data_link:{1:[!1,"wiki.html#crispr-prestige","wiki.html#crispr-prestige-unlocked"],9:["wiki.html#universes-gameplay"],10:["wiki.html#crispr-prestige-universal","wiki.html#crispr-prestige-standard"]}}),Ln("add","mechanics-gameplay","mastery",z("mastery")),function(e){let a=$('
                                  ');e.append(a);let r=$("
                                  "),i=$("
                                  ");a.append(r),a.append(i);let s={mutations:{val:void 0},days:{val:void 0}},n={game:{vis:!1,val:void 0},real:{vis:!1,val:void 0}};r.append(`\n
                                  \n

                                  ${z("wiki_calc_g_decay_game")}

                                  \n
                                  \n
                                  \n (50000000 / (1 + {{ i.mutations.val, 'mutations' | generic }})) - {{ i.days.val, 'days' | generic }} = {{ false | calc }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_g_decay_real")}

                                  \n
                                  \n
                                  \n {{ s.game.val, 'game' | generic }} / 17280 = {{ true | calc }}\n
                                  \n `),i.append(`\n
                                  \n
                                  ${z("wiki_calc_g_decay_mutations")}
                                  \n
                                  ${z("wiki_calc_g_decay_days")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:"#genomeDecayCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.mutations.val=void 0,s.days.val=void 0},importInputs(){s.mutations.val=t.race.mutation,s.days.val=t.stats.days}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_g_decay_"+t),calc:e=>e?n.real.val:(n.game.vis=void 0!==s.mutations.val&&void 0!==s.days.val,n.real.vis=n.game.vis,n.game.vis?(n.game.val=+(5e7/(1+s.mutations.val)-s.days.val).toFixed(0),n.real.val=+(n.game.val/17280).toFixed(6),n.game.val):(n.game.val=void 0,void(n.real.val=void 0)))}})}(Bn(In(a,{name:"genome_decay",template:"mechanics",label:z("wiki_mechanics_genome_decay"),paragraphs:4,break:[3],h_level:2,para_data:{1:[z("wiki_mechanics_genome_decay_para1_note1",[z("wiki_calc_g_decay_mutations")]),z("wiki_mechanics_genome_decay")],2:["2-3"],3:[z("wiki_mechanics_genome_decay"),z("resource_Plasmid_name"),"+0%"],4:[z("tech_genetic_decay"),z("trait_fortify_name"),z("wiki_mechanics_genome_decay"),z("resource_Plasmid_name"),"+0%"]},data_link:{4:["wiki.html#early_space-tech-genetic_decay","wiki.html#traits-species-special_fortify"]}}),"mechanics","g_decay",z("wiki_mechanics_genome_decay"))),Ln("add","mechanics-gameplay","genome_decay",z("wiki_mechanics_genome_decay")),In(a,{name:"crispr_mutation",template:"mechanics",label:z("wiki_mechanics_crispr_mutation"),paragraphs:5,break:[3],h_level:2,para_data:{1:[z("tab_arpa_crispr"),z("arpa_genepool_mutation_title"),z("resource_Plasmid_plural_name")],3:[z("tech_arpa"),z("tab_arpa_genetics")],4:["5x",z("wiki_mechanics_crispr_mutation_para4_note1")],5:[z("wiki_mechanics_custom"),z("race_sludge"),"10x"]},data_link:{1:[!1,"wiki.html#crispr-prestige-mutation","wiki.html#resources-prestige-plasmids"],4:[!1,"wiki.html#traits-species"],5:["wiki.html#custom-species","wiki.html#races-species-sludge"]}}),Ln("add","mechanics-gameplay","crispr_mutation",z("wiki_mechanics_crispr_mutation"));{let e=In(a,{name:"planet",template:"planet",label:z("wiki_menu_planets"),paragraphs:4,h_level:2,para_data:{2:[365,"25%"],3:[4],4:["200-600"]}});In(a,{name:"geology",template:"planet",label:z("wiki_menu_planets"),paragraphs:4,h_level:2,para_data:{2:[2],3:["-10%","+19%"],4:[7,"+44%"]}},e),In(a,{name:"seeother",template:"planet",label:z("wiki_menu_planets"),paragraphs:1,h_level:2,para_data:{1:[z("wiki_menu_planets")]},data_link:{1:["wiki.html#planets-gameplay"]}},e),Ln("add","mechanics-gameplay","planet",z("wiki_menu_planets"))}In(a,{name:"soul_gem",template:"hell",label:z("wiki_hell_soul_gem"),paragraphs:4,h_level:2,para_data:{1:[z("wiki_hell_soul_gem"),z("tab_portal")],3:[z("tech_demon_attractor")]}}),Ln("add","mechanics-gameplay","soul_gem",z("wiki_hell_soul_gem"));{let e=In(a,{name:"quantum",template:"mechanics",label:z("wiki_mechanics_quantum"),paragraphs:4,h_level:2,para_data:{1:[z("wiki_mechanics_quantum")],2:[z("tech_quantum_computing")],4:[z("interstellar_citadel_title")]},data_link:{2:["wiki.html#deep_space-tech-quantum_computing"],4:["wiki.html#interstellar-structures-citadel"]}});!function(e){let a=$('
                                  ');e.append(a),a.append(`

                                  ${z("wiki_mechanics_quantum")}

                                  `);let r=$("
                                  "),i=$("
                                  ");a.append(r),a.append(i);let s={knowledge:{val:void 0},citadels:{val:void 0},cores:{val:void 0},supercore:{val:!1},linked:{val:void 0},citizens:{val:void 0}},n={linked:{val:void 0},result:{vis:!1,val:0}};r.append("\n
                                  \n (ln(1 + ((1.1 - 1) * {{ i.knowledge.val, 'knowledge' | generic }} / 250000)) / ln(1.1)) * (1 + (0.05 * {{ i.citadels.val, 'citadels' | generic }})) * (2 - (0.99^{{ i.cores.val, 'cores' | generic }})) * 1.25 * {{ s.linked.val, 'linked' | generic }} = {{ | calc }}\n
                                  \n "),i.append(`\n
                                  \n
                                  ${z("wiki_calc_q_level_knowledge")}
                                  \n
                                  ${z("wiki_calc_q_level_citadels")}
                                  \n
                                  ${z("wiki_calc_cores")}
                                  \n
                                  ${z("wiki_calc_q_level_supercore")}
                                  \n
                                  ${z("trait_linked_name")} \n \n {{ 0 | traitLabel }}\n {{ 0.25 | traitLabel }}\n {{ 0.5 | traitLabel }}\n {{ 1 | traitLabel }}\n {{ 2 | traitLabel }}\n {{ 3 | traitLabel }}\n
                                  \n
                                  ${z("wiki_calc_citizens")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:"#quantumLevelCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},pickTrait(e,t){s[t].val=e},resetInputs(){s.knowledge.val=void 0,s.citadels.val=void 0,s.cores.val=void 0,s.supercore.val=!1,s.linked.val=void 0,s.citizens.val=void 0},importInputs(){s.knowledge.val=t.resource.Knowledge.max,s.citadels.val=t.interstellar.citadel?t.interstellar.citadel.on:0,s.cores.val=t.prestige.AICore.count,s.supercore.val=!(!t.space.ai_core2||!t.space.ai_core2.on),s.linked.val=t.race.linked?t.race.linked:0,s.citizens.val=t.resource[t.race.species].amount}},filters:{generic:(e,t)=>void 0!==e?e:z("cores"===t?"wiki_calc_"+t:"wiki_calc_q_level_"+t),traitLabel:e=>void 0===e?z("wiki_calc_trait_undefined"):0===e?z("wiki_calc_trait_unowned"):e,calc(){let e=!0;if(s.linked.val>0)if(void 0!==s.citizens.val){let e=Ei.linked.vars(s.linked.val)[0]/100*s.citizens.val;e>Ei.linked.vars(s.linked.val)[1]/100&&(e-=Ei.linked.vars(s.linked.val)[1]/100,e/=e+200-Ei.linked.vars(s.linked.val)[1],e+=Ei.linked.vars(s.linked.val)[1]/100),n.linked.val=+(1+e).toFixed(4)}else n.linked.val=void 0,e=!1;if(n.result.vis=e&&void 0!==s.knowledge.val&&void 0!==s.citadels.val&&void 0!==s.cores.val,n.result.vis){let e=Math.log(1+(1.1-1)*s.knowledge.val/25e4)/Math.log(1.1)*(1+.05*s.citadels.val)*(2-.99**s.cores.val);return s.supercore.val&&(e*=1.25),n.linked.val&&(e*=n.linked.val),n.result.val=+e.toFixed(4),n.result.val}}}})}(Bn(e,"mechanics","quantum_level",z("wiki_mechanics_quantum"))),Ln("add","mechanics-gameplay","quantum",z("wiki_mechanics_quantum")),In(e,{name:"quantum_swarm_ai",template:"mechanics",label:z("tech_swarm_control_ai"),paragraphs:2,h_level:2,para_data:{1:[z("tech_quantum_computing"),z("space_sun_swarm_satellite_title"),z("space_sun_swarm_control_title")],2:[z("space_sun_swarm_control_title"),11,z("wiki_mechanics_quantum")]},data_link:{1:["wiki.html#deep_space-tech-swarm_control_ai","wiki.html#space-structures-swarm_satellite","wiki.html#space-structures-swarm_control"]}}),In(e,{name:"quantum_swarm",template:"mechanics",label:z("tech_quantum_swarm"),paragraphs:3,h_level:2,para_data:{1:[z("tech_quantum_swarm"),z("space_hell_swarm_plant_title")],2:["1%"],3:["95%"]},data_link:{1:["wiki.html#deep_space-tech-quantum_swarm","wiki.html#space-structures-swarm_plant"]}}),In(e,{name:"quantum_manufacture",template:"mechanics",label:z("tech_quantum_manufacturing"),paragraphs:4,break:[2,3,4],h_level:2,para_data:{1:[z("tech_quantum_manufacturing"),z("city_factory"),z("wiki_mechanics_quantum")],2:[z("modal_factory_lux")],3:[z("resource_Furs_name"),"(Q Level - 1) * 12.5"],4:["(Q Level - 1) * 50"]},data_link:{1:["wiki.html#deep_space-tech-quantum_manufacturing","wiki.html#planetary-structures-factory",!1]}}),In(e,{name:"quantum_cement_processing",template:"mechanics",label:z("tech_cement_processing"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("tech_cement_processing"),z("interstellar_citadel_title")],2:["(Q Level / 1.75) %"]},data_link:{1:["wiki.html#interstellar-tech-cement_processing","wiki.html#interstellar-structures-citadel"]}}),In(e,{name:"quantum_graph_processing",template:"mechanics",label:z("tech_graphene_processing"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("tech_graphene_processing"),z("interstellar_citadel_title")],2:["(Q Level / 5) %"]},data_link:{1:["wiki.html#intergalactic-tech-graphene_processing","wiki.html#interstellar-structures-citadel"]}}),In(e,{name:"quantum_ai_logistics",template:"mechanics",label:z("tech_ai_logistics"),paragraphs:3,break:[3],h_level:2,para_data:{1:[z("tech_ai_logistics"),z("interstellar_cargo_yard_title"),z("city_shed_title3")],2:[z("city_shed_title3")],3:[z("wiki_mechanics_quantum")]},data_link:{1:["wiki.html#interstellar-tech-ai_logistics","wiki.html#interstellar-structures-cargo_yard","wiki.html#interstellar-structures-warehouse"]}}),In(e,{name:"quantum_arcology",template:"mechanics",label:z("portal_arcology_title"),paragraphs:1,h_level:2,para_data:{1:[z("portal_arcology_title"),10]},data_link:{1:["wiki.html#hell-structures-arcology",!1]}})}!function(e){let a=$('
                                  ');e.append(a);let r=$("
                                  "),i=$("
                                  ");a.append(r),a.append(i);let s=["Food","Lumber","Chrysotile","Stone","Crystal","Furs","Copper","Iron","Aluminium","Cement","Coal","Oil","Uranium","Steel","Titanium","Alloy","Polymer","Iridium","Helium_3","Deuterium","Neutronium","Adamantite","Infernite","Elerium","Nano_Tube","Graphene","Stanene","Bolognium","Vitreloy","Orichalcum","Plywood","Brick","Wrought_Iron","Sheet_Metal","Mythril","Aerogel","Nanoweave","Scarletite"],n={result:{vis:!1,kt:void 0,solar:void 0,MW:void 0,exoVis:!1,exotic:void 0,MWVis:!1,MWTot:void 0,timeVis:!1,timeTot:void 0}},c={solar_tot:{val:void 0},exotic_tot:{val:void 0},grav:{val:!0}},o=$("
                                  "),l=$("
                                  "),_=!0;i.append(o),s.forEach((function(e){_||l.append(" + "),_=!1,c[e]={val:void 0},o.append(`\n
                                  ${z("resource_"+e+"_name")}
                                  \n `),l.append(`({{ i.${e}.val, '${e}' | generic }} * ${Fa[e]})`)})),l.append(" = {{ true, 'kt' | calc }}"),r.append(`\n
                                  \n

                                  ${z("wiki_calc_mass_kt")}

                                  \n
                                  \n `),r.append(l),r.append(`\n
                                  \n

                                  ${z("wiki_calc_mass_solar")}

                                  \n
                                  \n
                                  \n {{ s.result.kt, 'kt' | generic }} / 10000000000 = {{ false, 'solar' | calc }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_mass_exotic")}

                                  \n
                                  \n
                                  \n (({{ i.Infernite.val, 'Infernite' | generic }} * 222.666) + ({{ i.Elerium.val, 'Elerium' | generic }} * 297.115)) / 10000000000 = {{ | calcExotic }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_mass_MW")}

                                  \n
                                  \n
                                  \n ({{ s.result.solar, 'solar' | generic }} * {{ false | amountMW }}) + ({{ s.result.exotic, 'exotic' | generic }} * {{ true | amountMW }}) = {{ false, 'MW' | calc }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_mass_MW_tot")}

                                  \n
                                  \n
                                  \n 20 + (({{ i.solar_tot.val, 'solar_tot' | generic }} - 8) * {{ false | amountMW }}) + ({{ i.exotic_tot.val, 'exotic_tot' | generic }} * {{ true | amountMW }}) = {{ | calcMW }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_mass_time_to_explode")}

                                  \n
                                  \n
                                  \n (0.025 - {{ i.exotic_tot.val, 'exotic_tot' | generic }}) / {{ s.result.exotic, 'exotic' | generic }} = {{ | calcTime }}\n
                                  \n `),i.append(`\n
                                  \n
                                  ${z("wiki_calc_mass_solar_tot")}
                                  \n
                                  ${z("wiki_calc_mass_exotic_tot")}
                                  \n
                                  ${z("tech_gravity_convection")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:"#massCalc",data:{i:c,s:n},methods:{val(e){"solar_tot"===e?c[e].val&&c[e].val<8&&(c[e].val=8):c[e].val&&c[e].val<0&&(c[e].val=0)},resetInputs(){s.forEach((function(e){c[e].val=void 0})),c.solar_tot.val=void 0,c.exotic_tot.val=void 0,c.grav.val=!0},importInputs(){t.interstellar.mass_ejector?s.forEach((function(e){c[e].val=t.interstellar.mass_ejector[e]})):s.forEach((function(e){c[e].val=0})),c.solar_tot.val=t.interstellar.stellar_engine?t.interstellar.stellar_engine.mass:8,t.tech.roid_eject&&(c.solar_tot.val+=.225*t.tech.roid_eject*(1+t.tech.roid_eject/12)),c.exotic_tot.val=t.interstellar.stellar_engine?t.interstellar.stellar_engine.exotic:0,c.grav.val=t.tech.gravity&&t.tech.gravity>=2}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"kt":case"solar":case"solar_tot":case"exotic":case"exotic_tot":case"MW":return z("wiki_calc_mass_"+t);default:return z("resource_"+t+"_name")+"/s"}},amountMW:e=>(c.grav.val?13.5:7.5)*(e?10:1),calc(e,t){if(e){let e=!0;if(s.forEach((function(t){e&&void 0===c[t].val&&(e=!1)})),n.result.vis=e,n.result.vis){let e=0;s.forEach((function(t){e+=c[t].val*Fa[t]})),n.result.kt=+e.toFixed(4),n.result.solar=+(e/1e10).toFixed(10),n.result.MW=+(n.result.solar*(c.grav.val?13.5:7.5)+n.result.exotic*(c.grav.val?135:75)).toFixed(10)}else n.result.kt=void 0,n.result.solar=void 0,n.result.mw=void 0}return n.result[t]},calcExotic(){if(void 0!==c.Infernite.val&&void 0!==c.Elerium.val)return n.result.exoVis=!0,n.result.exotic=+((c.Infernite.val*Fa.Infernite+c.Elerium.val*Fa.Elerium)/1e10).toFixed(10),n.result.exotic;n.result.exoVis=!1,n.result.exotic=void 0},calcMW(){if(void 0!==c.solar_tot.val&&void 0!==c.exotic_tot.val)return n.result.MWVis=!0,n.result.MWTot=+((c.solar_tot.val-8)*(c.grav.val?13.5:7.5)+c.exotic_tot.val*(c.grav.val?135:75)+20).toFixed(10),n.result.MWTot;n.result.MWVis=!1,n.result.MWTot=void 0},calcTime(){if(void 0!==c.exotic_tot.val&&n.result.exoVis)return n.result.timeVis=!0,c.exotic_tot.val>=.025?n.result.timeTot=z("wiki_calc_mass_time_reached"):0===n.result.exotic?n.result.timeTot=z("time_never"):n.result.timeTot=zs(Math.round((.025-c.exotic_tot.val)/n.result.exotic)),n.result.timeTot;n.result.timeVis=!1,n.result.timeTot=void 0}}})}(Bn(In(a,{name:"mass",template:"mechanics",label:z("wiki_mechanics_mass"),paragraphs:11,break:[5,9],h_level:2,para_data:{1:[z("tab_interstellar")],2:[z("tech_mass_ejector"),z("interstellar_mass_ejector"),z("tab_ejector")],4:[1e10.toLocaleString()],5:[z("universe_magic"),z("resource_Infernite_name"),z("resource_Elerium_name")],6:[.025,z("tech_stabilize_blackhole"),z("tech_exotic_infusion")],7:[z("tech_stabilize_blackhole"),0,40,z("tech_exotic_infusion"),z("wiki_resets_blackhole")],8:[z("tech_stabilize_blackhole"),.025],9:[z("interstellar_stellar_engine"),20,8],10:[1,7.5,z("interstellar_stellar_engine"),13.5,z("tech_gravity_convection")],11:[10]},data_link:{2:["wiki.html#interstellar-tech-mass_ejector","wiki.html#interstellar-structures-mass_ejector"],6:[!1,"wiki.html#interstellar-tech-stabilize_blackhole","wiki.html#interstellar-tech-infusion_confirm"],7:["wiki.html#interstellar-tech-stabilize_blackhole",!1,!1,"wiki.html#interstellar-tech-infusion_confirm","wiki.html#resets-prestige-blackhole"],8:["wiki.html#interstellar-tech-stabilize_blackhole"],9:["wiki.html#interstellar-structures-stellar_engine"],10:[!1,!1,"wiki.html#interstellar-structures-stellar_engine",!1,"wiki.html#interstellar-tech-gravity_convection"]}}),"eject","mass")),Ln("add","mechanics-gameplay","mass",z("wiki_mechanics_mass"));{let e=In(a,{name:"piracy",template:"mechanics",label:z("galaxy_piracy"),paragraphs:6,break:[4],h_level:2,para_data:{1:[z("galaxy_piracy"),z("wiki_menu_intergalactic")],2:[z("galaxy_embassy")],4:[z("tab_galactic"),z("galaxy_piracy"),z("galaxy_stargate")],5:[z("interstellar_stargate")]}});In(a,{name:"pirate_ramp",template:"mechanics",label:z("galaxy_piracy"),paragraphs:3,h_level:2,para_data:{1:[z("galaxy_stargate"),z("galaxy_gateway")],2:[z("tab_galactic")],3:[z("galaxy_embassy"),z("tech_xeno_gift"),z("galaxy_alien2_mission",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red])]}},e),In(a,{name:"pirate_threat",template:"mechanics",label:z("galaxy_piracy"),paragraphs:7,break:[2,3,4,5,6,7],h_level:2,para_data:{1:[z("galaxy_armada")],2:[z("galaxy_gateway"),100,250,500],3:[z("galaxy_stargate"),100,250,500],4:[z("galaxy_gorddon"),800],5:[z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien1")?t.galaxy.alien1.id:t.race.species].home]),1e3],6:[z("galaxy_alien",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].solar.red]),2500],7:[z("galaxy_chthonian"),7500]},data_color:{2:["caution","warning","warning","warning"],3:["caution","warning","warning","warning"],4:["caution","warning"],5:["caution","warning"],6:["caution","warning"],7:["caution","warning"]}},e),Ln("add","mechanics-gameplay","piracy",z("galaxy_piracy"))}!function(e){let a=$('
                                  ');e.append(a),a.append(`

                                  ${z("wiki_calc_bonuses",[z("trait_untapped_name")])}

                                  `);let r=$("
                                  "),i=$("
                                  ");a.append(r),a.append(i);let s={genes:{val:void 0}},n={result:{vis:!1,val:0}};r.append('\n
                                  \n ({{ i.genes.val | generic }} / ({{ i.genes.val | generic }} + 20) / 10) + 0.00024 = {{ false | calc }} = +{{ true | calc }}%\n
                                  \n '),i.append(`\n
                                  \n
                                  ${z("resource_Genes_name")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:"#untappedPotentialCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.genes.val=void 0},importInputs(){s.genes.val=t.custom?an({genus:t.custom.race0.genus,traitlist:t.custom.race0.traits}):0}},filters:{generic:e=>void 0!==e?e:z("resource_Genes_name"),calc:e=>e?(100*n.result.val).toFixed(3):(n.result.vis=s.genes.val,n.result.vis?(n.result.val=+(s.genes.val/(s.genes.val+20)/10+24e-5).toFixed(5),n.result.val):void 0)}})}(Bn(In(a,{name:"custom",template:"mechanics",label:z("wiki_mechanics_custom"),paragraphs:12,break:[3,5,9,11],h_level:2,para_data:{1:[z("wiki_resets_ascension")],2:[z("wiki_resets_ascension")],5:[z("resource_Genes_name")],6:[z("resource_Genes_name")],7:[2],8:[z("achieve_technophobe_name"),5,7],9:[z("tech_fanaticism"),z("tech_deify")],11:[0,z("resource_Genes_name")],12:[z("resource_Genes_name"),z("trait_untapped_name")]},data_link:{1:["wiki.html#resets-prestige-ascension"],2:["wiki.html#resets-prestige-ascension"],8:["wiki.html#perks-prestige-technophobe"],9:[t.genes.transcendence?"wiki.html#civilized-tech-alt_fanaticism":"wiki.html#civilized-tech-fanaticism","wiki.html#early_space-tech-deify"]}}),"mechanics","untapped",z("trait_untapped_name"))),Ln("add","mechanics-gameplay","custom",z("wiki_mechanics_custom"));{let e=In(a,{name:"pillar",template:"hell",label:z("wiki_mechanics_pillar"),paragraphs:5,h_level:2,para_data:{1:[z("portal_ruins_name")],2:["1%",z("harmonic")],3:["3%"],4:[z("harmonic"),"2%","6%"],5:[z("wiki_hell_pillar_para5d1"),12]},data_link:{5:["wiki.html#hell-structures-west_tower"]}});In(a,{name:"pillar",template:"mechanics",label:z("wiki_mechanics_pillar"),paragraphs:10,break:[4,6,8],h_level:2,para_data:{1:[z("tech_pillars"),z("resource_Harmony_name"),z("resource_Scarletite_name")],2:[z("resource_Scarletite_name"),1e6.toLocaleString(),125e3.toLocaleString()],3:[z("universe_micro")],4:[z("evo_challenge_genes"),z("harmonic")],5:[z("tech_scarletite"),z("evo_challenge_genes")],6:[z("achieve_resonance_name")],7:[z("achieve_resonance_name"),z("tech_scarletite")],8:[z("race_junker"),z("wiki_mechanics_custom"),z("achieve_enlightenment_name"),z("race_sludge")],9:[z("wiki_mechanics_custom")],10:[z("race_junker"),z("genelab_genus_humanoid"),z("race_sludge")]},data_link:{1:["wiki.html#dimensional-tech-pillars"],3:["wiki.html#universes-gameplay-micro"],5:["wiki.html#dimensional-tech-scarletite"],7:[!1,"wiki.html#dimensional-tech-scarletite"],8:["wiki.html#races-species-junker","wiki.html#mechanics-gameplay-custom",!1,"wiki.html#races-species-sludge"],9:["wiki.html#mechanics-gameplay-custom"],10:["wiki.html#races-species-junker",!1,"wiki.html#races-species-sludge"]}},e),Ln("add","mechanics-gameplay","pillar",z("wiki_mechanics_pillar"))}{let e=In(a,{name:"dlord",template:"mechanics",label:z("wiki_mechanics_dlord"),paragraphs:5,h_level:2,para_data:{1:[z("portal_waygate_title")],2:[z("resource_Demonic_Essence_name"),z("wiki_resets_infusion")],3:[z("wiki_resets_infusion"),"+1"],4:["+25%",z("wiki_resets_infusion")],5:[z("tech_dark_bomb"),z("wiki_resets_infusion")]},data_link:{1:["wiki.html#hell-structures-waygate"],2:[!1,"wiki.html#resets-prestige-infusion"],3:["wiki.html#resets-prestige-infusion"],4:[!1,"wiki.html#resets-prestige-infusion"],5:["wiki.html#dimensional-tech-dark_bomb","wiki.html#resets-prestige-infusion"]}});e.append(`\n

                                  ${z("wiki_mechanics_dlord_str")}

                                  \n `),Object.keys(Wt).forEach((function(a){let r=t.stats.spire[xn(a)]&&t.stats.spire[xn(a)].dlstr?z("wiki_mechanics_dlord_str_empowered",[t.stats.spire[xn(a)].dlstr]):z("wiki_mechanics_dlord_str_not_empowered");e.append(`\n
                                  \n ${z("universe_"+a)}: ${r}\n
                                  \n `)})),Ln("add","mechanics-gameplay","dlord",z("wiki_mechanics_dlord"))}{let e=In(a,{name:"syndicate",template:"mechanics",label:z("wiki_mechanics_syndicate"),paragraphs:2,h_level:2,para_data:{1:[z("wiki_mechanics_syndicate"),z("wiki_challenges_scenarios_truepath"),z("wiki_mechanics_syndicate_para1_note1"),z("tech_shipyard",[Ki[t.race.species?t.race.species:human].solar.dwarf])],2:[z("galaxy_piracy"),z("tab_galactic")]},data_link:{1:[!1,"wiki.html#challenges-gameplay-scenarios_truepath","wiki.html#progress-events-syndicate","wiki.html#solar-tp_tech-shipyard"],2:["wiki.html#mechanics-gameplay-piracy"]}}),r=In(e,{name:"syndicate_influence",template:"mechanics",label:z("wiki_mechanics_syndicate_influence"),paragraphs:3,break:[3],h_level:2,para_data:{1:[0],2:[z("space_mission_title",[Kn("triton")]),z("tech_data_analysis")],3:["1/10",1,Kn("triton"),"1/5"]},data_link:{2:["wiki.html#space-tp_structures-triton_mission","wiki.html#solar-tp_tech-data_analysis"]}});{let e=Dn(r,"mechanics","syndicate_influence_current",z("wiki_mechanics_syndicate_influence_current"));["moon","red","gas","gas_moon","belt","titan","enceladus","triton","kuiper","eris"].forEach((function(a){let r=t.space.syndicate&&t.space.syndicate["spc_"+a]?t.space.syndicate["spc_"+a]:0;e.append(`
                                  ${Kn(a)}: ${r}`)}))}!function(e){let a=$('
                                  ');e.append(a),a.append(`

                                  ${z("wiki_calc_syndicate_caps")}

                                  `);let r=$("
                                  "),i=$("
                                  ");a.append(r),a.append(i);let s={triton1:{val:!1},outer4:{val:!1}},n="";["moon","red","gas","gas_moon","belt","titan","enceladus","triton","kuiper","eris"].forEach((function(e){n+=`\n
                                  \n ${Kn(e)}: {{ '${e}' | calc }}\n
                                  \n `})),r.append(n),i.append(`\n
                                  \n
                                  ${z("space_mission_title",[Kn("triton")])}
                                  \n
                                  ${z("tech_data_analysis")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:"#syndicateCapCalc",data:{i:s},methods:{resetInputs(){s.triton1.val=!1,s.outer4.val=!1},importInputs(){s.triton1.val=t.tech.triton&&t.tech.triton>=1,s.outer4.val=t.tech.outer&&t.tech.outer>=4}},filters:{calc(e){switch(e){case"titan":return s.triton1.val?s.outer4.val?2e3:1e3:600;case"enceladus":return s.triton1.val?s.outer4.val?1500:1e3:600;case"triton":return s.triton1.val&&s.outer4.val?5e3:3e3;case"kuiper":return 2500;case"eris":return 7500;default:return 500}}}})}(Bn(r,"mechanics","syndicate_cap")),function(e){let a=$('
                                  ');e.append(a);let r=$("
                                  "),i=$("
                                  ");a.append(r),a.append(i);let s={region:{val:void 0},relations:{val:void 0,vis:!1,alliance:!1,war:!1},triton1:{val:!1,vis:!1},outer4:{val:!1,vis:!1},ship_security:{val:void 0},base:{val:void 0,vis:!1},sam:{val:void 0,vis:!1},fob:{val:!1,vis:!1},intel:{val:void 0},syndicate:{val:void 0}},n={divisor:{vis:!1,val:void 0},region_security:{vis:!1,val:void 0},residual:{vis:!1,val:void 0},penalty:{vis:!1,val:void 0}};r.append(`\n
                                  \n

                                  ${z("wiki_calc_syndicate_penalty_divisor")}

                                  - {{ i.relations.val | relationsType}}

                                  \n
                                  \n
                                  \n {{ i.region.val | divisorBase }} + (25 * ({{ i.relations.val, 'relations' | generic }} - 90)) + (13 * ({{ i.relations.val, 'relations' | generic }} - 40)) = {{ | calcDivisor }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_syndicate_penalty_region_security")}

                                  \n
                                  \n
                                  \n ({{ i.ship_security.val, 'ship_security' | generic }} + (50 * {{ i.base.val, 'base' | generic }}) + (25 * {{ i.sam.val, 'sam' | generic }}) + 500) * ({{ i.intel.val, 'intel' | generic }} / 100) = {{ | calcSecurity }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_syndicate_penalty_residual")}

                                  \n
                                  \n
                                  \n {{ i.syndicate.val, 'syndicate' | generic }} - {{ s.region_security.val, 'region_security' | generic }} = {{ | calcResidual }}\n
                                  \n
                                  \n

                                  ${z("wiki_mechanics_syndicate_penalty")}

                                  \n
                                  \n
                                  \n {{ s.residual.val, 'residual' | generic }} / {{ s.divisor.val, 'divisor' | generic }} = {{ false | calcPenalty }} = -{{ true | calcPenalty }}%\n
                                  \n `),i.append(`\n
                                  \n
                                  \n
                                  \n ${z("wiki_calc_syndicate_penalty_region")}\n
                                  \n
                                  \n \n \n {{ 'moon' | regionLabel }}\n {{ 'red' | regionLabel }}\n {{ 'gas' | regionLabel }}\n {{ 'gas_moon' | regionLabel }}\n {{ 'belt' | regionLabel }}\n {{ 'titan' | regionLabel }}\n {{ 'enceladus' | regionLabel }}\n {{ 'triton' | regionLabel }}\n {{ 'kuiper' | regionLabel }}\n {{ 'eris' | regionLabel }}\n \n
                                  \n
                                  \n
                                  ${z("wiki_calc_syndicate_penalty_rival_relations")}
                                  \n
                                  ${z("space_mission_title",[Kn("triton")])}
                                  \n
                                  ${z("tech_data_analysis")}
                                  \n
                                  ${z("wiki_calc_syndicate_penalty_ship_security")}
                                  \n
                                  ${z("tech_operating_base")}
                                  \n
                                  ${z("space_sam_title")}
                                  \n
                                  ${z("space_fob_title")}
                                  \n
                                  ${z("space_scan_effectiveness")}
                                  \n
                                  ${z("space_syndicate")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `);let c=function(e){switch(e){case"titan":return s.triton1.val?s.outer4.val?2e3:1e3:600;case"enceladus":return s.triton1.val?s.outer4.val?1500:1e3:600;case"triton":return s.triton1.val&&s.outer4.val?5e3:3e3;case"kuiper":return 2500;case"eris":return 7500;default:return 500}};Cs({el:"#syndicatePenaltyCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0),"relations"===e?s[e].val>100&&(s[e].val=100):"syndicate"===e&&s.region.val&&s[e].val>c(s.region.val)&&(s[e].val=c(s.region.val))},pickRegion(e){s.region.val=e,s.relations.vis=["moon","red","gas","gas_moon","belt"].includes(e),s.triton1.vis=["titan","enceladus","triton"].includes(e),s.syndicate.val&&s.syndicate.val>c(e)&&(s.syndicate.val=c(e)),s.base.vis="enceladus"===e,s.sam.vis="titan"===e,s.fob.vis="triton"===e},resetInputs(){s.region={val:void 0},s.relations={val:void 0,vis:!1,alliance:!1,war:!1},s.triton1={val:!1,vis:!1},s.outer4={val:!1,vis:!1},s.ship_security={val:void 0},s.base={val:void 0,vis:!1},s.sam={val:void 0,vis:!1},s.fob={val:!1,vis:!1},s.intel={val:void 0},s.syndicate={val:void 0}},importInputs(){t.civic.foreign&&t.civic.foreign.gov3&&(s.relations.val=100-t.civic.foreign.gov3.hstl),s.relations.alliance=s.relations.val>90,s.relations.war=s.relations.val<40,s.relations.vis=s.region.val&&["moon","red","gas","gas_moon","belt"].includes(s.region.val),s.triton1.vis=s.region.val&&["titan","enceladus","triton"].includes(s.region.val),s.triton1.val=t.tech.triton&&t.tech.triton>=1,s.outer4.val=t.tech.outer&&t.tech.outer>=4,s.region.val&&t.space.hasOwnProperty("shipyard")&&t.space.shipyard.hasOwnProperty("ships")&&(s.ship_security.val=0,s.intel.val=0,t.space.shipyard.ships.forEach((function(e){if(e.location==="spc_"+s.region.val&&0===e.transit&&e.fueled){let t=at(e);s.ship_security.val+=e.damage>0?Math.round(t*(100-e.damage)/100):t,s.intel.val+=_t(e)}})),"triton"===s.region.val&&t.space.fob&&t.space.fob.on>0&&(s.intel.val+=10),s.intel.val=(Math.round((s.intel.val-100)/(s.intel.val-100+200)*100)+100+25)/1.25,s.syndicate.val=t.space.syndicate&&t.space.syndicate["spc_"+s.region.val]?t.space.syndicate["spc_"+s.region.val]:0),s.base.val=t.space.operating_base?t.space.operating_base.on:0,s.base.vis=s.region.val&&"enceladus"===s.region.val,s.sam.val=t.space.sam?t.space.sam.on:0,s.sam.vis=s.region.val&&"titan"===s.region.val,s.fob.val=t.space.fob&&t.space.fob.on>0,s.fob.vis=s.region.val&&"triton"===s.region.val}},filters:{generic(e,t){if(void 0!==e)return e;switch(t){case"base":return z("tech_operating_base");case"sam":case"fob":return z("space_"+t+"_title");case"intel":return z("space_scan_effectiveness");case"relations":return z("wiki_calc_syndicate_penalty_rival_relations");case"syndicate":return z("space_syndicate");default:return z("wiki_calc_syndicate_penalty_"+t)}},regionLabel:e=>e?Kn(e):z("wiki_calc_syndicate_penalty_region"),relationsType:e=>(e>90?(s.relations.alliance=!0,s.relations.war=!1):e<40?(s.relations.war=!0,s.relations.alliance=!1):(s.relations.war=!1,s.relations.alliance=!1),z(e<40?"wiki_calc_syndicate_penalty_rival_war":e>90?"wiki_calc_syndicate_penalty_rival_ally":"wiki_calc_syndicate_penalty_rival_neutral")),divisorBase(e){if(!e)return z("wiki_calc_syndicate_penalty_region_divisor_base");switch(e){case"moon":case"red":return 1250;case"gas":case"gas_moon":case"belt":return 1020;default:return c(e)}},calcDivisor(){if(s.region.val)if(["moon","red","gas","gas_moon","belt"].includes(s.region.val))if((s.relations.war||s.relations.alliance)&&void 0===s.relations.val)n.divisor.val=void 0,n.divisor.vis=!1;else{let e=0,t=["moon","red"].includes(s.region.val)?1250:1020;s.relations.war?e=13*(s.relations.val-40):s.relations.alliance&&(e=25*(s.relations.val-90)),n.divisor.val=t+e,n.divisor.vis=!0}else n.divisor.val=c(s.region.val),n.divisor.vis=!0;else n.divisor.val=void 0,n.divisor.vis=!1;return n.divisor.val},calcSecurity(){let e=0,t=void 0!==s.ship_security.val&&void 0!==s.intel.val;if(t){if(e+=s.ship_security.val,s.region.val)switch(s.region.val){case"enceladus":void 0!==s.base.val?e+=50*s.base.val:t=!1;break;case"titan":void 0!==s.sam.val?e+=25*s.sam.val:t=!1;break;case"triton":s.fob.val&&(e+=500)}t?(n.region_security.val=Math.round(e*(s.intel.val/100)),n.region_security.vis=t):(n.region_security.val=void 0,n.region_security.vis=!1)}else n.region_security.val=void 0,n.region_security.vis=!1;return n.region_security.val},calcResidual(){if(void 0!==s.syndicate.val&&void 0!==n.region_security.val){let e=s.syndicate.val-n.region_security.val;e<0&&(e=0),n.residual.val=e,n.residual.vis=!0}else n.residual.val=void 0,n.residual.vis=!1;return n.residual.val},calcPenalty:e=>e?(100*n.penalty.val).toFixed(2):(n.penalty.vis=void 0!==n.residual.val&&void 0!==n.divisor.val,n.penalty.vis?n.penalty.val=+(n.residual.val/n.divisor.val).toFixed(4):n.penalty.val=void 0,n.penalty.val)}})}(Bn(In(e,{name:"syndicate_penalty",template:"mechanics",label:z("wiki_mechanics_syndicate_penalty"),paragraphs:6,break:[2,4,5],h_level:2,para_data:{1:[z("galaxy_piracy"),z("portal_ruins_security")],2:[Kn("titan")],3:[z("civics_gov_relations"),z("wiki_mechanics_rival")],5:[z("galaxy_armada"),z("tab_galactic"),z("portal_ruins_security")],6:[z("portal_ruins_security"),z("firepower"),z("outer_shipyard_hull"),z("space_scan_effectiveness")]},data_link:{1:["wiki.html#mechanics-gameplay-piracy"]}}),"mechanics","syndicate_penalty",z("wiki_mechanics_syndicate_penalty"))),Ln("add","mechanics-gameplay","syndicate",z("wiki_mechanics_syndicate"))}{let e=In(a,{name:"tp_ships",template:"mechanics",label:z("wiki_mechanics_tp_ships"),paragraphs:2,h_level:2,para_data:{1:[z("outer_shipyard_title"),z("tab_shipyard"),z("tab_civics")],2:[z("tab_galactic"),z("galaxy_piracy")]},data_link:{1:["wiki.html#space-tp_structures-shipyard"],2:[!1,"wiki.html#mechanics-gameplay-piracy"]}});!function(e){let a=$('
                                  ');e.append(a);let r=$("
                                  "),i=$("
                                  "),s=$("
                                  ");a.append(r),a.append(i),a.append(s);let n={owned:{val:void 0},class:{val:void 0},power:{val:void 0},weapon:{val:void 0},armor:{val:void 0},engine:{val:void 0},sensor:{val:void 0}},c={Money:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Aluminium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Adamantite:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Steel:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Alloy:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Neutronium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Titanium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Copper:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Orichalcum:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Iridium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Iron:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Nano_Tube:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1},Quantium:{base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1}},o={exp1:{val:void 0},exp2:{val:void 0},creep:{val:void 0}};r.append(`\n
                                  \n
                                  \n

                                  ${z("wiki_calc_tp_ships_costs_base_costs")}

                                  \n
                                  \n
                                  \n

                                  ${z("resource_Money_name")}:

                                  {{ i.class.val, 'class', 'Money' | getBase }}^{{ i.sensor.val, 'sensor', 'Money' | getExponent }} = {{ 'Money' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Aluminium_name")}:

                                  {{ i.class.val, 'class', 'Aluminium' | getBase }} = {{ 'Aluminium' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Adamantite_name")}:

                                  {{ i.class.val, 'class', 'Adamantite' | getBase }} = {{ 'Adamantite' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Steel_name")}:

                                  {{ i.armor.val, 'armor', 'Steel' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Steel' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Alloy_name")}:

                                  {{ i.armor.val, 'armor', 'Alloy' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Alloy' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Neutronium_name")}:

                                  {{ i.armor.val, 'armor', 'Neutronium' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Neutronium' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Titanium_name")}:

                                  {{ i.engine.val, 'engine', 'Titanium' | getBase }}^{{ s.exp2.val, 'exp2' | generic }} * 5 = {{ 'Titanium' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Copper_name")}:

                                  {{ i.power.val, 'power', 'Copper' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Copper' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Orichalcum_name")}:

                                  {{ i.power.val, 'power', 'Orichalcum' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Orichalcum' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Iridium_name")}:

                                  ({{ i.power.val, 'power', 'Iridium' | getBase }}^{{ s.exp2.val, 'exp2' | generic }})^{{ i.weapon.val, 'weapon', 'Iridium' | getExponent }} * 50 = {{ 'Iridium' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Iron_name")}:

                                  {{ i.weapon.val, 'weapon', 'Iron' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} * 10 = {{ 'Iron' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Nano_Tube_name")}:

                                  {{ i.weapon.val, 'weapon', 'Nano_Tube' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Nano_Tube' | calcPre }}\n
                                  \n
                                  \n

                                  ${z("resource_Quantium_name")}:

                                  {{ i.weapon.val, 'weapon', 'Quantium' | getBase }}^{{ s.exp1.val, 'exp1' | generic }} = {{ 'Quantium' | calcPre }}\n
                                  \n
                                  \n `);let l='\n
                                  \n
                                  \n

                                  {{ i.owned.val, i.class.val | finalLabel }}

                                  \n
                                  \n ';["Money","Aluminium","Adamantite","Steel","Alloy","Neutronium","Titanium","Copper","Orichalcum","Iridium","Iron","Nano_Tube","Quantium"].forEach((function(e){l+=`\n
                                  \n

                                  ${z("resource_"+e+"_name")}:

                                  {{ r.${e}.preVal, 'base' | generic }} * 0.750.9(1 + ({{ i.owned.val, 'owned' | generic }} - 2) / 25 * {{ s.creep.val, 'creep' | generic }})3 * (1 + {{ i.owned.val, 'owned' | generic }}) = {{ '${e}' | calcFinal }}\n
                                  \n `})),l+="
                                  ",i.append(l),s.append(`\n
                                  \n
                                  ${z("wiki_calc_tp_ships_costs_owned")}
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_class")}\n
                                  \n
                                  \n \n \n {{ 'class', 'corvette' | genericLabel }}\n {{ 'class', 'frigate' | genericLabel }}\n {{ 'class', 'destroyer' | genericLabel }}\n {{ 'class', 'cruiser' | genericLabel }}\n {{ 'class', 'battlecruiser' | genericLabel }}\n {{ 'class', 'dreadnought' | genericLabel }}\n {{ 'class', 'explorer' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_power")}\n
                                  \n
                                  \n \n \n {{ 'power', 'solar' | genericLabel }}\n {{ 'power', 'diesel' | genericLabel }}\n {{ 'power', 'fission' | genericLabel }}\n {{ 'power', 'fusion' | genericLabel }}\n {{ 'power', 'elerium' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_weapon")}\n
                                  \n
                                  \n \n \n {{ 'weapon', 'railgun' | genericLabel }}\n {{ 'weapon', 'laser' | genericLabel }}\n {{ 'weapon', 'p_laser' | genericLabel }}\n {{ 'weapon', 'plasma' | genericLabel }}\n {{ 'weapon', 'phaser' | genericLabel }}\n {{ 'weapon', 'disruptor' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_armor")}\n
                                  \n
                                  \n \n \n {{ 'armor', 'steel' | genericLabel }}\n {{ 'armor', 'alloy' | genericLabel }}\n {{ 'armor', 'neutronium' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_engine")}\n
                                  \n
                                  \n \n \n {{ 'engine', 'ion' | genericLabel }}\n {{ 'engine', 'tie' | genericLabel }}\n {{ 'engine', 'pulse' | genericLabel }}\n {{ 'engine', 'photon' | genericLabel }}\n {{ 'engine', 'vacuum' | genericLabel }}\n {{ 'engine', 'emdrive' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_sensor")}\n
                                  \n
                                  \n \n \n {{ 'sensor', 'visual' | genericLabel }}\n {{ 'sensor', 'radar' | genericLabel }}\n {{ 'sensor', 'lidar' | genericLabel }}\n {{ 'sensor', 'quantum' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n \n \n
                                  \n `);let _=function(e,t){switch(t){case"sensor":switch(e){case"visual":return 1;case"radar":return 1.04;case"lidar":return 1.08;case"quantum":return 1.12}case"weapon":switch(e){case"railgun":return 1;case"laser":return 1.05;case"p_laser":return 1.035;case"plasma":return 1.1;case"phaser":return 1.15;case"disruptor":return 1.2}}};Cs({el:"#tpShipsCostsCalc",data:{i:n,r:c,s:o},methods:{val(e){n[e].val&&n[e].val<0&&(n[e].val=0)},pickGeneric(e,t){if(n[e].val=t,"class"===e){let e=1,a=1,r=1;switch(t){case"corvette":e=1,a=1,r=2;break;case"frigate":e=1.1,a=1.09,r=1.5;break;case"destroyer":e=1.2,a=1.18,r=1.2;break;case"cruiser":e=1.3,a=1.25;break;case"battlecruiser":e=1.35,a=1.3,r=.8;break;case"dreadnought":e=1.4,a=1.35,r=.5;break;case"explorer":e=1.45,a=1,r=5}o.exp1.val=e,o.exp2.val=a,o.creep.val=r}},resetInputs(){n.owned.val=void 0,n.class.val=void 0,n.power.val=void 0,n.weapon.val=void 0,n.armor.val=void 0,n.engine.val=void 0,n.sensor.val=void 0,["Money","Aluminium","Adamantite","Steel","Alloy","Neutronium","Titanium","Copper","Orichalcum","Iridium","Iron","Nano_Tube","Quantium"].forEach((function(e){c[e]={base:void 0,preVal:void 0,preVis:!1,val:void 0,vis:!1}})),o.exp1.val=void 0,o.exp2.val=void 0,o.creep.val=void 0},importInputs(){if(n.class.val)if(t.space.shipyard&&t.space.shipyard.ships){let e=0;t.space.shipyard.ships.forEach((function(t){t.class===n.class.val&&e++})),n.owned.val=e}else n.owned.val=0}},filters:{finalLabel:(e,t)=>"explorer"===t?z("wiki_calc_tp_ships_costs_final_costs_explorer"):(0!==e&&1!==e&&(e=">1"),t=z(t?`outer_shipyard_class_${t}`:"outer_shipyard_class"),z("wiki_calc_tp_ships_costs_final_costs",[z("wiki_calc_tp_ships_costs_final_costs_owned",[e,t])])),generic:(e,t)=>void 0!==e?e:z("wiki_calc_tp_ships_costs_"+t),genericLabel:(e,t)=>z(t?`outer_shipyard_${e}_${t}`:`outer_shipyard_${e}`),getBase(e,t,a){if(!e)return z("wiki_calc_tp_ships_costs_res_base",[z(`outer_shipyard_${t}`)]);let r=0;switch(t){case"class":switch(e){case"corvette":r="Money"===a?25e5:"Aluminium"===a?5e5:0;break;case"frigate":r="Money"===a?5e6:"Aluminium"===a?125e4:0;break;case"destroyer":r="Money"===a?15e6:"Aluminium"===a?35e5:0;break;case"cruiser":r="Money"===a?5e7:"Aluminium"===a?0:1e6;break;case"battlecruiser":r="Money"===a?125e6:"Aluminium"===a?0:26e5;break;case"dreadnought":r="Money"===a?5e8:"Aluminium"===a?0:8e6;break;case"explorer":r="Money"===a?8e8:"Aluminium"===a?0:95e5}break;case"armor":switch(e){case"steel":r="Steel"===a?35e4:0;break;case"alloy":r="Alloy"===a?25e4:0;break;case"neutronium":r="Neutronium"===a?1e4:0}break;case"engine":switch(e){case"ion":r=75e3;break;case"tie":r=15e4;break;case"pulse":r=125e3;break;case"photon":r=21e4;break;case"vacuum":r=3e5;break;case"emdrive":r=125e4}break;case"power":let t=["dreadnought","explorer"].includes(n.class.val);switch(e){case"solar":case"diesel":r="Iridium"===a?15e3:"Orichalcum"===a&&t||"Copper"===a&&!t?4e4:0;break;case"fission":r="Iridium"===a?3e4:"Orichalcum"===a&&t||"Copper"===a&&!t?5e4:0;break;case"fusion":r="Iridium"===a?4e4:"Orichalcum"===a&&t||"Copper"===a&&!t?5e4:0;break;case"elerium":r="Iridium"===a?55e3:"Orichalcum"===a&&t||"Copper"===a&&!t?6e4:0}break;case"weapon":switch(e){case"railgun":r="Iron"===a?25e3:0;break;case"laser":case"p_laser":r="Nano_Tube"===a?12e3:0;break;case"plasma":r="Nano_Tube"===a?2e4:0;break;case"phaser":r="Quantium"===a?18e3:0;break;case"disruptor":r="Quantium"===a?35e3:0}}return c[a].base=r,r},getExponent:(e,t)=>e?_(e,t):z("wiki_calc_tp_ships_costs_res_exp",[z(`outer_shipyard_${t}`)]),calcPre(e){if(void 0!==c[e].base){let t=0,a=c[e].base;switch(e){case"Money":"explorer"===n.class.val?t=1:n.sensor.val&&(t=_(n.sensor.val,"sensor"));break;case"Steel":case"Alloy":case"Neutronium":case"Copper":case"Orichalcum":case"Iron":case"Nano_Tube":case"Quantium":o.exp1.val&&(t=o.exp1.val);break;case"Titanium":case"Iridium":o.exp2.val&&(t=o.exp2.val)}if(t){if("Iridium"!==e||n.weapon.val)return"Iridium"===e&&(a**=_(n.weapon.val,"weapon")),a**=t,"explorer"===n.class.val&&("Titanium"===e?a*=5:"Iron"===e?a*=10:"Iridium"===e&&(a*=50)),c[e].preVal=+a.toFixed(0),c[e].preVis=!0,c[e].preVal}else if("Aluminium"===e||"Adamantite"===e)return c[e].preVal=a,c[e].preVis=!0,c[e].preVal}c[e].preVal=void 0,c[e].preVis=!1},calcFinal(e){if(c[e].vis=void 0!==c[e].preVal&&void 0!==n.owned.val,c[e].vis){let t=n.owned.val;if("explorer"===n.class.val)c[e].val=+(c[e].preVal*(3*(t+1))).toFixed(0);else{let a=0===t?.75:1===t?.9:1+(t-2)/25*o.creep.val;c[e].val=+(c[e].preVal*a).toFixed(0)}return c[e].val}c[e].val=void 0}}})}(Bn(In(e,{name:"tp_ships_costs",template:"mechanics",label:z("wiki_mechanics_tp_ships_costs"),paragraphs:3,break:[3],h_level:2,para_data:{2:[z("outer_shipyard_class")],3:[z("outer_shipyard_class")]}}),"mechanics","tp_ships_costs",z("wiki_mechanics_tp_ships_costs")));{let t=Dn(In(e,{name:"tp_ships_crew",template:"mechanics",label:z("wiki_mechanics_tp_ships_crew"),paragraphs:1,h_level:2,para_data:{1:[z("outer_shipyard_class")]}}),"mechanics","tp_ships_crew",z("wiki_mechanics_tp_ships_crew"));["corvette","frigate","destroyer","cruiser","battlecruiser","dreadnought","explorer"].forEach((function(e){t.append(`
                                  ${z("outer_shipyard_class_"+e)}: ${et({class:e})}`)}))}!function(e){let t=$('
                                  ');e.append(t);let a=$("
                                  "),r=$("
                                  "),i=$("
                                  ");t.append(a),t.append(r),t.append(i);let s={class:{val:void 0},power:{val:void 0},weapon:{val:void 0},engine:{val:void 0},sensor:{val:void 0}},n={genMulti:{val:void 0},useMulti:{val:void 0},power:{val:void 0,vis:!1},weapon:{val:void 0,vis:!1},engine:{val:void 0,vis:!1},sensor:{val:void 0,vis:!1},net:{val:void 0,vis:!1,neg:void 0}};a.append(`\n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_class")}\n
                                  \n
                                  \n \n \n {{ 'class', 'corvette' | genericLabel }}\n {{ 'class', 'frigate' | genericLabel }}\n {{ 'class', 'destroyer' | genericLabel }}\n {{ 'class', 'cruiser' | genericLabel }}\n {{ 'class', 'battlecruiser' | genericLabel }}\n {{ 'class', 'dreadnought' | genericLabel }}\n {{ 'class', 'explorer' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n `),r.append(`\n
                                  \n
                                  \n

                                  ${z("wiki_calc_tp_ships_power_gen")}

                                  \n
                                  \n
                                  \n {{ i.power.val, 'power' | genericVal }} * {{ s.genMulti.val, 'gen_multi' | generic }} = {{ | calcPower }}\n
                                  \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_power")}\n
                                  \n
                                  \n \n \n {{ 'power', 'solar' | genericLabel }}\n {{ 'power', 'diesel' | genericLabel }}\n {{ 'power', 'fission' | genericLabel }}\n {{ 'power', 'fusion' | genericLabel }}\n {{ 'power', 'elerium' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n `),i.append(`\n
                                  \n
                                  \n

                                  ${z("wiki_calc_tp_ships_power_use",[z("outer_shipyard_weapon")])}

                                  \n
                                  \n
                                  \n {{ i.weapon.val, 'weapon' | genericVal }} * {{ s.useMulti.val, 'use_multi' | generic }} = {{ | calcWeapon }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_tp_ships_power_use",[z("outer_shipyard_engine")])}

                                  \n
                                  \n
                                  \n {{ i.engine.val, 'engine' | genericVal }} * {{ s.useMulti.val, 'use_multi' | generic }} = {{ | calcEngine }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_tp_ships_power_use",[z("outer_shipyard_sensor")])}

                                  \n
                                  \n
                                  \n {{ i.sensor.val, 'sensor' | genericVal }} * {{ s.useMulti.val, 'use_multi' | generic }} = {{ | calcSensor }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_tp_ships_power_net")}

                                  \n
                                  \n
                                  \n {{ s.power.val, 'power' | genericResult }} - {{ s.weapon.val, 'weapon' | genericResult }} - {{ s.engine.val, 'engine' | genericResult }} - {{ s.sensor.val, 'sensor' | genericResult }} = {{ | calcNet }} = ${z("wiki_calc_tp_ships_power_net_pos")} = ${z("wiki_calc_tp_ships_power_net_neg")}\n
                                  \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_weapon")}\n
                                  \n
                                  \n \n \n {{ 'weapon', 'railgun' | genericLabel }}\n {{ 'weapon', 'laser' | genericLabel }}\n {{ 'weapon', 'p_laser' | genericLabel }}\n {{ 'weapon', 'plasma' | genericLabel }}\n {{ 'weapon', 'phaser' | genericLabel }}\n {{ 'weapon', 'disruptor' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_engine")}\n
                                  \n
                                  \n \n \n {{ 'engine', 'ion' | genericLabel }}\n {{ 'engine', 'tie' | genericLabel }}\n {{ 'engine', 'pulse' | genericLabel }}\n {{ 'engine', 'photon' | genericLabel }}\n {{ 'engine', 'vacuum' | genericLabel }}\n {{ 'engine', 'emdrive' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_sensor")}\n
                                  \n
                                  \n \n \n {{ 'sensor', 'visual' | genericLabel }}\n {{ 'sensor', 'radar' | genericLabel }}\n {{ 'sensor', 'lidar' | genericLabel }}\n {{ 'sensor', 'quantum' | genericLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n \n
                                  \n `),Cs({el:"#tpShipsPowerCalc",data:{i:s,s:n},methods:{pickGeneric(e,t){if(s[e].val=t,"class"===e){let e=1,a=1;switch(t){case"frigate":e=1.1,a=1.2;break;case"destroyer":e=1.5,a=1.65;break;case"cruiser":e=2,a=2.5;break;case"battlecruiser":e=2.5,a=3.5;break;case"dreadnought":e=5,a=6.5;break;case"explorer":e=6,a=2}n.genMulti.val=e,n.useMulti.val=a}},resetInputs(){s.class.val=void 0,s.power.val=void 0,s.weapon.val=void 0,s.engine.val=void 0,s.sensor.val=void 0,n.genMulti.val=void 0,n.useMulti.val=void 0,n.power.val=void 0,n.weapon.val=void 0,n.engine.val=void 0,n.sensor.val=void 0,n.net.val=void 0,n.power.vis=!1,n.weapon.vis=!1,n.engine.vis=!1,n.sensor.vis=!1,n.net.vis=!1,n.net.neg=void 0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_tp_ships_power_"+t),genericResult:(e,t)=>void 0!==e?e:"power"===t?z("wiki_calc_tp_ships_power_gen"):z("wiki_calc_tp_ships_power_use",[z(`outer_shipyard_${t}`)]),genericLabel:(e,t)=>z(t?`outer_shipyard_${e}_${t}`:`outer_shipyard_${e}`),genericVal(e,t){if(!e)return z("wiki_calc_tp_ships_power_base",[z(`outer_shipyard_${t}`)]);let a={};return a[t]=e,Math.abs(tt(a,"explorer"===s.class.val))},calcPower(){if(n.power.vis=s.class.val&&s.power.val,n.power.vis)return n.power.val=tt({class:s.class.val,power:s.power.val}),n.power.val},calcWeapon(){if(n.weapon.vis=s.class.val&&s.weapon.val,n.weapon.vis)return n.weapon.val=Math.abs(tt({class:s.class.val,weapon:s.weapon.val})),n.weapon.val},calcEngine(){if(n.engine.vis=s.class.val&&s.engine.val,n.engine.vis)return n.engine.val=Math.abs(tt({class:s.class.val,engine:s.engine.val})),n.engine.val},calcSensor(){if(n.sensor.vis=s.class.val&&s.sensor.val,n.sensor.vis)return n.sensor.val=Math.abs(tt({class:s.class.val,sensor:s.sensor.val})),n.sensor.val},calcNet(){if(n.net.vis=s.class.val&&s.power.val&&s.weapon.val&&s.engine.val&&s.sensor.val,n.net.vis)return n.net.val=tt({class:s.class.val,power:s.power.val,weapon:s.weapon.val,engine:s.engine.val,sensor:s.sensor.val}),n.net.neg=n.net.val<0,n.net.val;n.net.neg=void 0}}})}(Bn(In(e,{name:"tp_ships_power",template:"mechanics",label:z("wiki_mechanics_tp_ships_power"),paragraphs:4,break:[3],h_level:2,para_data:{3:[z("outer_shipyard_power"),z("outer_shipyard_class")],4:[z("outer_shipyard_weapon"),z("outer_shipyard_engine"),z("outer_shipyard_sensor"),z("outer_shipyard_class")]}}),"mechanics","tp_ships_power",z("wiki_mechanics_tp_ships_power"))),function(e){let t=$('
                                  ');e.append(t),t.append(`

                                  ${z("wiki_mechanics_tp_ships_firepower")}

                                  `);let a=$("
                                  "),r=$("
                                  ");t.append(a),t.append(r);let i={weapon:{val:void 0},class:{val:void 0}},s={result:{vis:!1,val:0}};a.append('\n
                                  \n {{ i.weapon.val | weaponVal }} * {{ i.class.val | classVal }} = {{ | calc }}\n
                                  \n '),r.append(`\n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_weapon")}\n
                                  \n
                                  \n \n \n {{ 'railgun' | weaponLabel }}\n {{ 'laser' | weaponLabel }}\n {{ 'p_laser' | weaponLabel }}\n {{ 'plasma' | weaponLabel }}\n {{ 'phaser' | weaponLabel }}\n {{ 'disruptor' | weaponLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_class")}\n
                                  \n
                                  \n \n \n {{ 'corvette' | classLabel }}\n {{ 'frigate' | classLabel }}\n {{ 'destroyer' | classLabel }}\n {{ 'cruiser' | classLabel }}\n {{ 'battlecruiser' | classLabel }}\n {{ 'dreadnought' | classLabel }}\n {{ 'explorer' | classLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n \n
                                  \n `),Cs({el:"#tpShipsFirepowerCalc",data:{i,s},methods:{pickWeapon(e){i.weapon.val=e},pickClass(e){i.class.val=e},resetInputs(){i.weapon.val=void 0,i.class.val=void 0}},filters:{weaponVal(e){switch(e){case"railgun":return 36;case"laser":return 64;case"p_laser":return 54;case"plasma":return 90;case"phaser":return 114;case"disruptor":return 156;default:return z("wiki_calc_tp_ships_firepower_weapon")}},classVal(e){switch(e){case"corvette":return 1;case"frigate":return 1.5;case"destroyer":return 2.75;case"cruiser":return 5.5;case"battlecruiser":return 10;case"dreadnought":return 22;case"explorer":return 1.2;default:return z("wiki_calc_tp_ships_firepower_class")}},weaponLabel:e=>z(e?"outer_shipyard_weapon_"+e:"outer_shipyard_weapon"),classLabel:e=>z(e?"outer_shipyard_class_"+e:"outer_shipyard_class"),calc(){if(s.result.vis=i.weapon.val&&i.class.val,s.result.vis)return s.result.val=at({weapon:i.weapon.val,class:i.class.val}),s.result.val}}})}(Bn(In(e,{name:"tp_ships_firepower",template:"mechanics",label:z("wiki_mechanics_tp_ships_firepower"),paragraphs:2,break:[3],h_level:2,para_data:{1:[z("firepower"),z("outer_shipyard_class"),z("outer_shipyard_weapon")],2:[z("firepower"),z("outer_shipyard_hull")]}}),"mechanics","tp_ships_firepower",z("wiki_mechanics_tp_ships_firepower"))),function(e){let t=$('
                                  ');e.append(t),t.append(`

                                  ${z("wiki_calc_tp_ships_hull_damage_range")}

                                  `);let a=$("
                                  "),r=$("
                                  ");t.append(a),t.append(r);let i={hull:{val:void 0},triton:{val:!1}},s={result:{vis:!1,val:void 0}};a.append('\n
                                  \n 1 - {{ | calc }}\n
                                  \n '),r.append(`\n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_armor")}\n
                                  \n
                                  \n \n \n {{ 'steel' | hullLabel }}\n {{ 'alloy' | hullLabel }}\n {{ 'neutronium' | hullLabel }}\n \n
                                  \n
                                  \n
                                  ${Kn("triton")}
                                  \n
                                  \n
                                  \n \n
                                  \n `),Cs({el:"#tpShipsHullCalc",data:{i,s},methods:{pickHull(e){i.hull.val=e},resetInputs(){i.hull.val=void 0,i.triton.val=!1}},filters:{hullLabel:e=>z(e?"outer_shipyard_armor_"+e:"outer_shipyard_armor"),calc(){if(s.result.vis=i.hull.val,s.result.vis){let e=0;switch(i.hull.val){case"steel":e=8;break;case"alloy":e=6;break;case"neutronium":e=4}return i.triton.val&&(e*=2),s.result.val=e-1,s.result.val}}}})}(Bn(In(e,{name:"tp_ships_hull",template:"mechanics",label:z("wiki_mechanics_tp_ships_hull"),paragraphs:7,break:[3,6,7],h_level:2,para_data:{1:[z("firepower"),z("outer_shipyard_hull")],2:[z("outer_shipyard_hull"),"90%",z("firepower"),.9],3:[Kn("dwarf"),"1/10",z("outer_shipyard_hull")],4:[z("outer_shipyard_armor")],5:[Kn("triton")],6:["1%",z("outer_shipyard_hull")],7:[z("outer_shipyard_hull"),"10%"]}}),"mechanics","tp_ships_hull",z("wiki_calc_tp_ships_hull_damage_range")));let r=In(e,{name:"tp_ships_sensors",template:"mechanics",label:z("wiki_mechanics_tp_ships_sensors"),paragraphs:2,h_level:2,para_data:{1:[z("space_scan_effectiveness")],2:[z("space_scan_effectiveness"),z("outer_shipyard_sensors"),z("outer_shipyard_class"),z("outer_shipyard_sensor"),Kn("triton"),z("space_fob_title")]}});!function(e){let t=$('
                                  ');e.append(t),t.append(`

                                  ${z("wiki_calc_tp_ships_scan_ship")}

                                  `);let a=$("
                                  "),r=$("
                                  ");t.append(a),t.append(r);let i={sensor:{val:void 0},class:{val:void 0}},s={result:{vis:!1,val:0}};a.append('\n
                                  \n {{ i.sensor.val | sensorVal }} * {{ i.class.val | classVal }} = {{ | calc }}\n
                                  \n '),r.append(`\n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_sensor")}\n
                                  \n
                                  \n \n \n {{ 'visual' | sensorLabel }}\n {{ 'radar' | sensorLabel }}\n {{ 'lidar' | sensorLabel }}\n {{ 'quantum' | sensorLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n ${z("outer_shipyard_class")}\n
                                  \n
                                  \n \n \n {{ 'corvette' | classLabel }}\n {{ 'frigate' | classLabel }}\n {{ 'destroyer' | classLabel }}\n {{ 'cruiser' | classLabel }}\n {{ 'battlecruiser' | classLabel }}\n {{ 'dreadnought' | classLabel }}\n {{ 'explorer' | classLabel }}\n \n
                                  \n
                                  \n
                                  \n
                                  \n \n
                                  \n `),Cs({el:"#tpShipsScanCalc",data:{i,s},methods:{pickSensor(e){i.sensor.val=e},pickClass(e){i.class.val=e},resetInputs(){i.sensor.val=void 0,i.class.val=void 0}},filters:{sensorVal(e){switch(e){case"visual":return 1;case"radar":return 10;case"lidar":return 18;case"quantum":return 32;default:return z("wiki_calc_tp_ships_scan_sensor")}},classVal(e){switch(e){case"corvette":case"frigate":return 2;case"destroyer":case"cruiser":return 1.5;case"battlecruiser":case"dreadnought":return 1;case"explorer":return 5;default:return z("wiki_calc_tp_ships_firepower_class")}},sensorLabel:e=>z(e?"outer_shipyard_sensor_"+e:"outer_shipyard_sensor"),classLabel:e=>z(e?"outer_shipyard_class_"+e:"outer_shipyard_class"),calc(){if(s.result.vis=i.sensor.val&&(i.class.val||"visual"===i.sensor.val),s.result.vis)return s.result.val=_t({sensor:i.sensor.val,class:i.class.val}),s.result.val}}})}(Bn(r,"mechanics","tp_ships_scan",z("wiki_calc_tp_ships_scan_ship"))),function(e){let t=$('
                                  ');e.append(t);let a=$("
                                  "),r=$("
                                  ");t.append(a),t.append(r);let i={range:{val:void 0},triton:{val:!1},fob:{val:!1}},s={combined:{vis:!1,val:void 0},adjusted:{vis:!1,val:void 0,adjust:!1},intel:{vis:!1,val:void 0}};a.append(`\n
                                  \n

                                  ${z("wiki_calc_tp_ships_intel_combined_range")}

                                  \n
                                  \n
                                  \n {{ i.range.val, 'ship_range' | generic }} + 10 = {{ | calcRange }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_tp_ships_intel_adjusted_range_below",[z("wiki_calc_tp_ships_intel_adjusted_range"),z("wiki_calc_tp_ships_intel_combined_range")])}

                                  \n
                                  \n
                                  \n {{ s.combined.val, 'combined_range' | generic }} = {{ | calcAdjusted }}\n
                                  \n
                                  \n

                                  ${z("wiki_calc_tp_ships_intel_adjusted_range_above",[z("wiki_calc_tp_ships_intel_adjusted_range"),z("wiki_calc_tp_ships_intel_combined_range")])}

                                  \n
                                  \n
                                  \n (({{ s.combined.val, 'combined_range' | generic }} - 100) / (({{ s.combined.val, 'combined_range' | generic }} - 100) + 200) * 100) + 100 = {{ | calcAdjusted }}\n
                                  \n
                                  \n

                                  ${z("space_scan_effectiveness")}

                                  \n
                                  \n
                                  \n ({{ s.adjusted.val, 'adjusted_range' | generic }} + 25) / 1.25 = {{ | calcIntel }}\n
                                  \n `),r.append(`\n
                                  \n
                                  ${z("wiki_calc_tp_ships_intel_ship_range")}
                                  \n
                                  ${Kn("triton")}
                                  \n
                                  ${z("space_fob_title")}
                                  \n
                                  \n
                                  \n \n
                                  \n `),Cs({el:"#tpShipsIntelCalc",data:{i,s},methods:{val(e){i[e].val&&i[e].val<0&&(i[e].val=0)},resetInputs(){i.range.val=void 0,i.triton.val=!1,i.fob.val=!1}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_tp_ships_intel_"+t),calcRange(){if(s.combined.vis=void 0!==i.range.val,s.combined.vis)return s.combined.val=i.range.val+(i.triton.val&&i.fob.val?10:0),s.combined.val;s.combined.val=void 0},calcAdjusted(){if(s.adjusted.vis=void 0!==s.combined.val,s.adjusted.vis){let e=s.combined.val;return e>100?(e=(e-100)/(e-100+200)*100+100,s.adjusted.adjust=!0):s.adjusted.adjust=!1,s.adjusted.val=e,s.adjusted.val}s.adjusted.val=void 0},calcIntel(){if(s.intel.vis=void 0!==s.adjusted.val,s.intel.vis)return s.intel.val=(s.adjusted.val+25)/1.25,s.intel.val;s.intel.val=void 0}}})}(Bn(r,"mechanics","tp_ships_intel",z("space_scan_effectiveness"))),Ln("add","mechanics-gameplay","tp_ships",z("wiki_mechanics_tp_ships"))}In(a,{name:"seed",template:"mechanics",label:z("wiki_mechanics_seed"),paragraphs:14,break:[3,5,6,7,8,9,10,11,12,13,14],h_level:2,para_data:{4:[z("wiki_faq_q_soft_reset")],7:[z("evo_sentience_title")],8:[z("wiki_menu_combat"),z("trait_revive_name"),z("trait_infectious_name")],9:[z("civics_spy_influence"),z("civics_spy_sabotage"),z("civics_spy_incite")],10:[z("wiki_menu_major"),z("wiki_menu_minor")],11:[z("arpa_gene_mutation"),z("tech_fanaticism"),z("tech_deify"),z("tab_arpa_crispr"),z("wiki_arpa_crispr_evolve")],12:[z("governor")],13:[z("wiki_menu_planets"),z("wiki_resets_bioseed"),z("wiki_resets_blackhole"),z("wiki_resets_vacuum")],14:[z("portal_spire_name")]},data_link:{7:["wiki.html#prehistoric-structures-sentience"],8:["wiki.html#combat-gameplay","wiki.html#traits-species-major_revive","wiki.html#traits-species-major_infectious"],10:["wiki.html#major-events","wiki.html#minor-events"],11:[!1,t.genes.transcendence?"wiki.html#civilized-tech-alt_fanaticism":"wiki.html#civilized-tech-fanaticism","wiki.html#early_space-tech-deify",!1,"wiki.html#crispr-prestige-recombination"],12:["wiki.html#governor-gameplay"],13:["wiki.html#planets-gameplay","wiki.html#resets-prestige-bioseed","wiki.html#resets-prestige-blackhole","wiki.html#resets-prestige-vacuum"],14:["wiki.html#hell-gameplay-spire"]}}),Ln("add","mechanics-gameplay","seed",z("wiki_mechanics_seed"));{let e=Pr(!0),r=Pr(!1,!0),i=t.stats.hasOwnProperty("reset")?t.stats.reset:0,s=Math.floor(i/r.length);if(s>0)switch(s){case 1:e=`${e} ${z("wiki_mechanics_cheese_squared")}`;break;case 2:e=`${e} ${z("wiki_mechanics_cheese_cubed")}`;break;case 3:e=`${e} ${z("wiki_mechanics_cheese_tesseracted")}`;break;case 4:e=`${e} ${z("wiki_mechanics_cheese_penteracted")}`;break;case 5:e=`${e} ${z("wiki_mechanics_cheese_hexeracted")}`;break;case 6:e=`${e} ${z("wiki_mechanics_cheese_hepteracted")}`;break;case 7:e=`${e} ${z("wiki_mechanics_cheese_octeracted")}`;break;case 8:e=`${e} ${z("wiki_mechanics_cheese_enneracted")}`;break;case 9:e=`${e} ${z("wiki_mechanics_cheese_dekeracted")}`;break;default:e=`${e}^${s+1}`}let n=[];for(let e=0;e${z(`cheese_${r[e]}`)} (${e+1})`);In(a,{name:"cheese",template:"mechanics",label:z("wiki_mechanics_cheese"),paragraphs:5,break:[4,5],h_level:2,para_data:{1:[z("tech_swiss_bank",[z("cheese_swiss")])],2:[r.length,z("cheese_swiss")],3:[z("wiki_mechanics_cheese")],4:[z("wiki_mechanics_cheese"),e,i+1],5:[n.join(", ")]},data_color:{4:["warning","danger","caution"],5:[!1]}}),Ln("add","mechanics-gameplay","cheese",z("wiki_mechanics_cheese"))}{let e=In(a,{name:"thralls",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:9,break:[4,8],h_level:2,para_data:{1:[z("trait_unfathomable_name")],5:[100,100],8:[1]},data_link:{1:["wiki.html#traits-species-genus_unfathomable"]}});In(e,{name:"thralls_cath",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_cath"),3]}}),In(e,{name:"thralls_pterodacti",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_pterodacti"),3]}}),In(e,{name:"thralls_entish",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_entish"),"40%"]}}),In(e,{name:"thralls_cacti",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_cacti"),"32%"]}}),In(e,{name:"thralls_moldling",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:3,break:[3],h_level:!1,para_data:{1:[z("race_moldling")],2:[[`${z("tech_smelting")}`,`${z("tech_dynamite")}`,`${z("tech_portland_cement")}`,`${z("tech_oxygen_converter")}`,`${z("tech_machinery")}`,`${z("tech_uranium_storage")}`,`${Mr.tech.synthetic_fur.title()}`,`${z("tech_rover")}`,`${z("tech_starcharts")}`,`${z("tech_nano_tubes")}`,`${z("tech_stanene")}`,`${z("tech_hydroponics")}`,`${z("tech_orichalcum_panels")}`,`${z("tech_cybernetics")}`].join(", ")]},data_color:{2:[!1]}}),In(e,{name:"thralls_sharkin",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_sharkin")]}}),In(e,{name:"thralls_satyr",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_satyr")]}}),In(e,{name:"thralls_phoenix",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_phoenix"),"0.25"]}}),In(e,{name:"thralls_salamander",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_salamander"),"20%"]}}),In(e,{name:"thralls_unicorn",template:"mechanics",label:z("wiki_mechanics_thralls"),paragraphs:1,h_level:!1,para_data:{1:[z("race_unicorn"),1]}}),Ln("add","mechanics-gameplay","thralls",z("wiki_mechanics_thralls"))}}(a);break;case"government":!function(e){let t=Ln("create",e);In(t,{name:"info",template:"government",label:z("tab_gov"),paragraphs:8,break:[3,6],h_level:2,para_data:{2:[z("govern_anarchy")],3:[z("civics_revolution")],4:[z("civics_revolution")],5:[1e3]},data_color:{2:["caution"]}}),Ln("add","government-gameplay","info",z("tab_gov"));let a={anarchy:{paragraphs:5,break:[2,5],para_data:{2:[10],3:["10th","0.25%","1/2"]}},autocracy:{paragraphs:4,break:[2,4],para_data:{2:["35%","25%"],3:["18%",z("tech_electricity"),"10%",z("tech_virtual_reality")]},para_color:{}},democracy:{paragraphs:6,break:[2,5],para_data:{2:[z("job_entertainer"),"20%"],3:[z("job_entertainer")],4:["25%",z("tech_electricity"),"30%",z("tech_virtual_reality")],5:["5%"],6:[z("job_farmer"),z("job_lumberjack"),z("job_quarry_worker"),z("job_miner"),z("job_crystal_miner"),z("job_coal_miner"),z("job_cement_worker"),z("job_professor"),z("job_scientist"),z("soldiers")]}},oligarchy:{paragraphs:5,break:[2,4,5],text:{1:"govern_oligarchy_desc",2:"govern_oligarchy_effect"},para_data:{2:[5,20],3:["2%",z("tech_electricity"),z("tech_virtual_reality")],4:["45%"],5:["0.5%","20%"]}},theocracy:{paragraphs:7,break:[2,6,7],para_data:{2:["12%"],3:["25%"],4:["50%"],6:["40%",z("tech_virtual_reality"),"25%",z("tech_metaphysics")]}},republic:{paragraphs:7,break:[2,5,6],para_data:{2:["25%"],3:["20%"],5:["30%",z("tech_virtual_reality"),"40%",z("tech_metaphysics")],6:["30%"],7:[30,90]},para_color:{}},socialist:{paragraphs:6,break:[2,6],para_data:{2:["35%"],3:["10%"],4:["10%"],5:["20%"],6:["42%",z("tech_virtual_reality"),"50%",z("tech_metaphysics")]}},corpocracy:{paragraphs:9,break:[2,8,9],para_data:{2:["50%"],3:["200%"],4:["150%"],5:["100%"],6:["10%"],7:["30%"],8:["5%",z("tech_virtual_reality")],9:["40%",z("tech_metaphysics")]}},technocracy:{paragraphs:5,break:[2,4],para_data:{2:["8%"],3:["10%"],4:["2%"],5:["1%",z("tech_virtual_reality"),z("tech_metaphysics")]}},federation:{paragraphs:7,break:[2,5,6],para_data:{2:["3%"],4:["25%"],5:["10%"],6:["25%","32%"],7:["36%",z("tech_virtual_reality"),"40%",z("tech_metaphysics")]}},magocracy:{paragraphs:5,break:[2,3,5],para_data:{2:["25%"],3:["25%"],4:["40%",z("tech_virtual_reality"),"50%",z("tech_metaphysics")]}}};Object.keys(a).forEach((function(e){In(t,{name:e,template:"government",label:z(`govern_${e}`),paragraphs:a[e].paragraphs,break:a[e].break,h_level:2,text:a[e].hasOwnProperty("text")?a[e].text:{1:`govern_${e}_desc`},para_data:a[e].hasOwnProperty("para_data")?a[e].para_data:{},para_color:a[e].hasOwnProperty("para_color")?a[e].para_color:{}}),Ln("add","government-gameplay",e,z(`govern_${e}`))}))}(a);break;case"governor":!function(e){let t=Ln("create",e);{let e=In(t,{name:"intro",template:"governor",label:z("governor"),paragraphs:4,h_level:2,para_data:{1:[z("arpa_genepool_governance_title")],2:[Object.keys(F).length]},data_link:{1:["wiki.html#crispr-prestige-governance"]}});Ln("add","governor-gameplay","intro",z("governor")),Object.keys(F).forEach((function(t){let a="";Object.keys(F[t].traits).forEach((function(e){a+=(A[e].hasOwnProperty("effect")?A[e].effect():"")+" "})),In(e,{name:t,template:"government",label:z(`governor_${t}`),paragraphs:2,break:[2],h_level:3,text:{1:`governor_${t}_desc`},rawtext:{2:a}}),Ln("add","governor-gameplay",t,z(`governor_${t}`))}))}{let e=In(t,{name:"task",template:"governor",paragraphs:2,h_level:2,para_data:{2:[3,z("governor_bureaucrat"),4],3:[Object.keys(B).length]}});Ln("add","governor-gameplay","task",z("wiki_governor_task"));{let t="tax";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:3,break:[3],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:"wiki_governor_task_unlock"},para_data:{3:[z("tech_tax_rates")]},data_link:{3:["wiki.html#civilized-tech-tax_rates"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="storage";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:3,break:[3],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:"wiki_governor_task_unlock"},para_data:{3:[z("tech_containerization")]},data_link:{3:["wiki.html#civilized-tech-containerization"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="bal_storage";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:4,break:[4],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:"wiki_governor_task_unlock"},para_data:{4:[z("tech_containerization")]},data_link:{4:["wiki.html#civilized-tech-containerization"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="merc";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:4,break:[4],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:"wiki_governor_task_unlock"},para_data:{4:[z("tech_mercs")]},data_link:{4:["wiki.html#civilized-tech-mercs"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="spy";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:3,break:[2,3],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:"wiki_governor_task_unlock",3:"wiki_governor_task_disabled"},para_data:{2:[z("tech_spy")],3:[z("tech_unification")]},data_link:{2:["wiki.html#civilized-tech-spy"],3:["wiki.html#early_space-tech-unification2"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="spyop";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:8,break:[2,3,4,5,6,7,8],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:`wiki_governor_task_${t}3`,5:`wiki_governor_task_${t}4`,6:`wiki_governor_task_${t}5`,7:"wiki_governor_task_unlock",8:"wiki_governor_task_disabled"},para_data:{2:[1,z("civics_spy_sabotage")],3:[2,z("civics_spy_influence")],4:[3,z("civics_spy_incite")],6:[z("civics_spy_sabotage"),z("civics_spy_incite"),z("civics_spy_influence")],7:[z("tech_espionage")],8:[z("tech_unification")]},data_link:{6:["wiki.html#civilized-tech-spy"],7:["wiki.html#early_space-tech-unification2"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="slave";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:2,break:[2],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:"wiki_governor_task_trait"},para_data:{2:[z("trait_slaver_name")]},data_link:{2:["wiki.html#traits-species-major_slaver"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="sacrifice";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:2,break:[2],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:"wiki_governor_task_trait"},para_data:{2:[z("trait_cannibalize_name")]},data_link:{2:["wiki.html#traits-species-major_cannibalize"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="horseshoe";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:2,break:[2],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:"wiki_governor_task_trait"},para_data:{1:[z(`city_${hn(!0)}`,[hn(!1)]),hn(!1)],2:[rs(!1)]},data_link:{2:["wiki.html#traits-species-major_hooved"]}}),Ln("add","governor-gameplay",t,z(`city_${hn(!0)}`,[hn(!1)]))}{let t="trash";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:7,break:[3,5,7],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:`wiki_governor_task_${t}3min`,5:`wiki_governor_task_${t}3a`,6:`wiki_governor_task_${t}3max`,7:`wiki_governor_task_${t}4`},para_data:{7:[z("interstellar_mass_ejector")]},data_link:{7:["wiki.html#interstellar-structures-mass_ejector"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}{let t="mech";In(e,{name:t,template:"government",label:z(`gov_task_${t}`),paragraphs:4,break:[4],h_level:3,text:{1:`wiki_governor_task_${t}1`,2:`wiki_governor_task_${t}2`,3:`wiki_governor_task_${t}3`,4:`wiki_governor_task_${t}4`},para_data:{4:[1,z("wiki_resets_infusion"),z("portal_spire_name")]},data_link:{4:[!1,"wiki.html#resets-prestige-infusion","wiki.html#hell-structures-spire"]}}),Ln("add","governor-gameplay",t,z(`gov_task_${t}`))}}}(a);break;case"combat":!function(e){let t=Ln("create",e);In(t,{name:"basics",template:"combat",label:z("wiki_combat_basics"),paragraphs:4,h_level:2}),Ln("add","combat-gameplay","basics",z("wiki_combat_basics")),In(t,{name:"campaign",template:"combat",label:z("wiki_combat_campaign"),paragraphs:14,break:[5,11],h_level:2,para_data:{1:[5,z("civics_garrison_tactic_ambush"),z("civics_garrison_tactic_raid"),z("civics_garrison_tactic_pillage"),z("civics_garrison_tactic_assault"),z("civics_garrison_tactic_siege")],3:[z("civics_garrison_tactic_ambush")],4:[z("civics_garrison_tactic_siege"),20],11:["0%","50%"],12:[50],13:["50%","100%"],14:["50%"]}}),Ln("add","combat-gameplay","campaign",z("wiki_combat_campaign")),In(t,{name:"loot",template:"combat",label:z("wiki_combat_loot"),paragraphs:30,break:[3,5,10,13,16,19,22,26,27,28,29,30],h_level:2,para_data:{2:[3,z("civics_garrison_campaign"),z("civics_gov_eco_rate"),z("civics_garrison_battalion")],3:[z("civics_garrison_campaign")],4:[4,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],5:[z("wiki_combat_loot_basic"),z("resource_Food_name"),z("resource_Lumber_name"),z("resource_Stone_name")],6:[z("wiki_combat_loot_common"),z("resource_Copper_name"),z("resource_Iron_name"),z("resource_Aluminium_name"),z("resource_Coal_name")],7:[z("wiki_combat_loot_rare"),z("resource_Cement_name"),z("resource_Steel_name")],8:[z("wiki_universe_magic"),z("wiki_combat_loot_rare"),z("resource_Crystal_name"),z("trait_terrifying_name"),z("resource_Titanium_name")],9:[z("wiki_combat_loot_money")],10:[z("civics_garrison_tactic_ambush"),3,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common")],11:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common")],12:[5],13:[z("civics_garrison_tactic_raid"),4,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],14:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],15:[10],16:[z("civics_garrison_tactic_pillage"),5,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],17:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],18:[25],19:[z("civics_garrison_tactic_assault"),5,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],20:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],21:[50],22:[z("civics_garrison_tactic_siege"),5,z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],23:[z("trait_beast_of_burden_name"),z("wiki_combat_loot_money"),z("wiki_combat_loot_basic"),z("wiki_combat_loot_common"),z("wiki_combat_loot_rare")],24:[z("civics_garrison_tactic_siege")],25:[999],28:["base loot * log(looters + 1)"],29:[z("civics_gov_eco_rate")],30:["floor(loot * economic rating / 100)"]},data_color:{5:["warning","caution","caution","caution"],6:["warning","caution","caution","caution","caution"],7:["warning","caution","caution"],8:["warning","warning","caution","warning","caution"],10:["warning","warning","caution","caution","caution"],11:["warning","caution","caution","caution"],13:["warning","warning","caution","caution","caution","caution"],14:["warning","caution","caution","caution","caution"],16:["warning","warning","caution","caution","caution","caution"],17:["warning","caution","caution","caution","caution"],19:["warning","warning","caution","caution","caution","caution"],20:["warning","caution","caution","caution","caution"],22:["warning","warning","caution","caution","caution","caution"],23:["warning","caution","caution","caution","caution"],28:["advanced"],30:["advanced"]}}),Ln("add","combat-gameplay","loot",z("wiki_combat_loot"))}(a);break;case"challenges":!function(e){let a=Ln("create",e);In(a,{name:"intro",template:"challenges",paragraphs:3,h_level:2,para_data:{2:[z("arpa_genepool_hardened_genes_title"),z("evo_bunker")],3:[z("evo_challenge_genes"),z("evo_challenge_run"),z("evo_scenario")]},data_link:{2:["wiki.html#crispr-prestige-hardened_genes"]}}),Ln("add","challenges-gameplay","intro",z("wiki_menu_intro"));{let e=In(a,{name:"genes_intro",template:"challenges",paragraphs:5,break:[4],h_level:2,para_data:{1:[z("evo_challenge_genes")],2:[z("mastery")],3:[z("mastery")],5:[z("evo_challenge_genes")]},data_link:{1:["wiki.html#mechanics-gameplay-challenge"],2:["wiki.html#mechanics-gameplay-mastery"],3:["wiki.html#mechanics-gameplay-mastery"]}});Ln("add","challenges-gameplay","genes_intro",z("wiki_challenges_genes_intro")),In(e,{name:"genes_plasmid",template:"challenges",paragraphs:4,break:[4],h_level:2,para_data:{1:[z("evo_challenge_plasmid"),z("wiki_challenges_gene"),z("resource_Plasmid_plural_name")],2:[z("city_temple"),z("resource_Plasmid_plural_name"),z("faith")],3:[z("resource_Plasmid_plural_name")],4:[z("wiki_challenges_gene"),z("universe_antimatter")]},data_link:{1:[!1,!1,"wiki.html#resources-prestige-plasmids"],2:["wiki.html#planetary-structures-temple"],4:[!1,"wiki.html#universes-gameplay-antimatter"]}}),En("add","challenges-gameplay","genes_plasmid",z("wiki_challenges_genes_plasmid")),In(e,{name:"genes_mastery",template:"challenges",paragraphs:2,break:[2],h_level:2,para_data:{1:[z("evo_challenge_mastery"),z("wiki_challenges_gene"),z("mastery"),"1/5","1/10"],2:[z("wiki_challenges_gene"),z("universe_antimatter")]},data_link:{1:[!1,!1,"wiki.html#mechanics-gameplay-mastery"],2:[!1,"wiki.html#universes-gameplay-antimatter"]}}),En("add","challenges-gameplay","genes_mastery",z("wiki_challenges_genes_mastery")),In(e,{name:"genes_trade",template:"challenges",paragraphs:2,h_level:2,para_data:{1:[z("evo_challenge_trade"),z("wiki_challenges_gene"),z("resource_market_buy"),z("resource_market_sell")],2:[z("resource_market_trade_routes")]}}),En("add","challenges-gameplay","genes_trade",z("wiki_challenges_genes_trade")),In(e,{name:"genes_craft",template:"challenges",paragraphs:2,h_level:2,para_data:{1:[z("evo_challenge_craft"),z("wiki_challenges_gene")],2:[z("job_craftsman")]}}),En("add","challenges-gameplay","genes_craft",z("wiki_challenges_genes_craft"));{let t=In(e,{name:"genes_crispr",template:"challenges",paragraphs:2,h_level:2,para_data:{1:[z("evo_challenge_crispr"),z("wiki_challenges_gene"),z("tab_arpa_crispr"),z("wiki_arpa_crispr_creep"),"1/5"]},data_link:{1:[!1,!1,!1,"wiki.html#crispr-prestige-genetic_memory"]}});t.find("div.para").append(`${z("wiki_challenges_genes_bad_para2")}`);let a=$(`\n
                                  \n ${z("wiki_challenges_genes_crispr_para3")}\n
                                  \n `);t.append(a);let r=!1;Ii.forEach((function(e){a.append(`${r?", ":""}${z("trait_"+e+"_name")}`),r=!0})),En("add","challenges-gameplay","genes_crispr",z("wiki_challenges_genes_crispr"))}In(e,{name:"genes_bad",template:"challenges",paragraphs:4,break:[3,4],h_level:2,para_data:{1:[1,2],4:[z("wiki_challenges_gene"),z("evo_challenge_truepath")]},data_link:{4:[!1,"wiki.html#challenges-gameplay-scenarios_truepath"]}}),En("add","challenges-gameplay","genes_bad",z("wiki_challenges_genes_bad"));{let a="antimatter"===t.race.universe?["20%","50%","50%","33%"]:["50%","20%","50%","33%"];In(e,{name:"genes_weak",template:"challenges",paragraphs:5,break:[2,3,4,5],h_level:2,para_data:{1:[a[0]],2:[a[1]],3:[a[2]],4:[a[3]],5:[z("wiki_challenges_gene"),z("evo_challenge_truepath")]},data_link:{5:[!1,"wiki.html#challenges-gameplay-scenarios_truepath"]}}),En("add","challenges-gameplay","genes_weak",z("wiki_challenges_genes_weak"))}}{let e=In(a,{name:"modes_intro",template:"challenges",paragraphs:2,h_level:2,para_data:{1:[z("evo_challenge_run"),z("evo_challenge_genes")],2:[z("wiki_challenges_mode")]}});Ln("add","challenges-gameplay","modes_intro",z("wiki_challenges_modes_intro")),mc(In(e,{name:"modes_joyless",template:"challenges",paragraphs:4,break:[3,4],h_level:2,para_data:{1:[z("evo_challenge_joyless"),z("wiki_challenges_mode"),z("tech_theatre")],2:[z("job_entertainer"),z("morale_broadcast"),_i(),z("morale")],3:[z("wiki_challenges_mode"),Mr.space.spc_red.biodome.title(),z("tech_theatre")],4:[z("wiki_challenges_scenarios_cataclysm"),z("wiki_challenges_scenario")]},data_link:{1:[!1,!1,"wiki.html#civilized-tech-theatre"],2:[!1,!1,"wiki.html#planetary-structures-wardenclyffe"],3:[!1,"wiki.html#space-structures-biodome","wiki.html#civilized-tech-theatre"],4:["wiki.html#challenges-gameplay-scenarios_cataclysm"]}}),!1,["joyless"]),En("add","challenges-gameplay","modes_joyless",z("wiki_challenges_modes_joyless"));{let t=In(e,{name:"modes_steelen",template:"challenges",paragraphs:4,break:[4],h_level:2,para_data:{1:[z("evo_challenge_steelen"),z("wiki_challenges_mode"),z("resource_Steel_name")+" "+z("modal_smelting"),z("resource_Steel_name")],2:[z("resource_Steel_name")],3:[z("tech_steel"),z("tech_bessemer_process"),z("tech_oxygen_converter"),z("tech_electric_arc_furnace")],4:[z("wiki_challenges_mode"),z("wiki_resets_bioseed")]},data_link:{3:["wiki.html#civilized-tech-steel","wiki.html#discovery-tech-bessemer_process","wiki.html#industrialized-tech-oxygen_converter","wiki.html#globalized-tech-electric_arc_furnace"],4:[!1,"wiki.html#resets-prestige-bioseed"]}});mc(t,!1,["steelen"]),mc(t,!0,["steelem"]),En("add","challenges-gameplay","modes_steelen",z("wiki_challenges_modes_steelen"))}{let a=In(e,{name:"modes_decay",template:"challenges",paragraphs:6,break:[4,6],h_level:2,para_data:{1:[z("evo_challenge_decay"),z("wiki_challenges_mode")],2:[z("resource_Money_name"),z("wiki_calc_citizens"),z("resource_Knowledge_name"),z("resource_Zen_name"),z("resource_Crates_plural"),z("resource_Containers_plural")],3:[50],4:["0/s"],6:[z("wiki_challenges_mode"),z("wiki_resets_blackhole"),z("wiki_resets_vacuum")]},data_link:{6:[!1,"wiki.html#resets-prestige-blackhole","wiki.html#resets-prestige-vacuum"]}});mc(a,!1,["dissipated"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_blackhole"),color:!!t.stats.achieve.whitehole,link:"wiki.html#resets-prestige-blackhole"}]}]),function(e){let t=$('
                                  ');e.append(t);let a=$("
                                  "),r=$("
                                  ");t.append(a),t.append(r);let i={resource:{val:void 0},amount:{val:void 0}},s={result:{vis:!1,val:void 0}};a.append(`\n
                                  \n

                                  ${z("wiki_calc_decay_rate")}

                                  \n
                                  \n
                                  \n {{ i.resource.val | base }} * 0.001 * ({{ i.amount.val, 'amount' | generic }} - 50) = {{ | calc }}\n
                                  \n `);let n=$("
                                  ");r.append(n);let c=`\n
                                  ${z("wiki_calc_decay_resource")} \n \n `;Object.keys(za).forEach((function(e){c+=`\n {{ '${e}' | resLabel }}\n `})),c+="
                                  ",n.append(c),n.append(`\n
                                  ${z("wiki_calc_decay_amount")}
                                  \n `),r.append(`\n
                                  \n \n
                                  \n `),Cs({el:"#decayCalc",data:{i,s},methods:{val(e){i[e].val&&i[e].val<0&&(i[e].val=0)},pickRes(e){i.resource.val=e},resetInputs(){i.resource.val=void 0,i.amount.val=void 0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_decay_"+t),base:e=>e?za[e]:z("wiki_calc_decay_base"),resLabel:e=>z(e?`resource_${e}_name`:"wiki_calc_decay_resource"),calc(){if(s.result.vis=void 0!==i.resource.val&&void 0!==i.amount.val&&i.amount.val>=50,s.result.vis)return s.result.val=.001*za[i.resource.val]*(i.amount.val-50),s.result.val}}})}(Bn(a,"challenges","decay",z("evo_challenge_decay"))),En("add","challenges-gameplay","modes_decay",z("wiki_challenges_modes_decay"))}{let a=In(e,{name:"modes_emfield",template:"challenges",paragraphs:5,break:[5],h_level:2,para_data:{1:[z("evo_challenge_emfield"),z("wiki_challenges_mode"),"50%",z("evo_challenge_discharge"),"50%"],2:[z("evo_challenge_discharge"),"-50%"],3:[z("city_cement_plant"),z("evo_challenge_discharge"),"50%"],4:[z("space_belt_elerium_ship_title"),z("evo_challenge_discharge"),"-25%"],5:[z("wiki_challenges_mode"),z("wiki_resets_ascension")]},data_link:{3:["wiki.html#planetary-structures-cement_plant"],4:["wiki.html#space-structures-elerium_ship"],5:[!1,"wiki.html#resets-prestige-ascension"]}});mc(a,!1,["technophobe"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"}]}]),En("add","challenges-gameplay","modes_emfield",z("wiki_challenges_modes_emfield"))}{let a=In(e,{name:"modes_inflation",template:"challenges",paragraphs:11,break:[4,9,10],h_level:2,para_data:{1:[z("evo_challenge_inflation"),z("wiki_challenges_mode"),z("resource_Money_name")],2:[1,10],3:[z("space_dwarf_collider_title"),z("interstellar_stellar_engine"),1],5:[z("resource_Money_name"),"+1.33%"],6:[z("modal_factory_lux"),"+0.08%",z("resource_Money_name")],7:[z("city_casino"),"+0.08%","+1%",z("resource_Money_name")],8:[z("wiki_mechanics_bank_vault"),"+0.8%",z("resource_Money_name")],9:[z("interstellar_exchange_title"),"2x",z("resource_Money_name"),z("evo_challenge_inflation")],10:[z("wiki_challenges_mode"),z("wiki_challenges_modes_inflation_para10_note1")],11:[z("evo_challenge_inflation")]},data_link:{3:["wiki.html#space-structures-world_collider","wiki.html#interstellar-structures-stellar_engine"],7:["wiki.html#planetary-structures-casino"],8:["wiki.html#mechanics-gameplay-bank_vault"],9:["wiki.html#interstellar-structures-exchange"]}});mc(a,!1,["wheelbarrow"]),gc(a,[{text:"wiki_challenges_reqs_achieve",subreqs:[{text:z("achieve_scrooge_name"),color:!!t.stats.achieve.scrooge}]}]),function(e){let a=$('
                                  ');e.append(a);let r=$("
                                  "),i=$("
                                  ");a.append(r),a.append(i);let s={inflation:{val:void 0}},n={result:{vis:!1,cost:void 0,luxury:void 0,casino_prod:void 0,casino_store:void 0,bank_vault:void 0}};r.append(`\n
                                  \n

                                  ${z("wiki_calc_inflation_cost")}

                                  \n
                                  \n
                                  \n {{ i.inflation.val, 'inflation' | generic }} / 75 = {{ 'cost' | calc }} = +{{ 'cost', true | calc }}%\n
                                  \n
                                  \n

                                  ${z("wiki_calc_inflation_luxury")}

                                  \n
                                  \n
                                  \n {{ i.inflation.val, 'inflation' | generic }} / 1250 = {{ 'luxury' | calc }} = +{{ 'luxury', true | calc }}%\n
                                  \n
                                  \n

                                  ${z("wiki_calc_inflation_casino_prod")}

                                  \n
                                  \n
                                  \n {{ i.inflation.val, 'inflation' | generic }} / 1250 = {{ 'casino_prod' | calc }} = +{{ 'casino_prod', true | calc }}%\n
                                  \n
                                  \n

                                  ${z("wiki_calc_inflation_casino_store")}

                                  \n
                                  \n
                                  \n {{ i.inflation.val, 'inflation' | generic }} / 100 = {{ 'casino_store' | calc }} = +{{ 'casino_store', true | calc }}%\n
                                  \n
                                  \n

                                  ${z("wiki_calc_inflation_bank_vault")}

                                  \n
                                  \n
                                  \n {{ i.inflation.val, 'inflation' | generic }} / 125 = {{ 'bank_vault' | calc }} = +{{ 'bank_vault', true | calc }}%\n
                                  \n `),i.append(`\n
                                  \n
                                  ${z("wiki_calc_inflation")}
                                  \n
                                  \n
                                  \n \n \n
                                  \n `),Cs({el:"#inflationCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.inflation.val=void 0},importInputs(){s.inflation.val=t.race.inflation||0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_"+t),calc:(e,t)=>t?(100*n.result[e]).toFixed(3):("cost"===e&&(n.result.vis=void 0!==s.inflation.val,n.result.vis&&(n.result.cost=(s.inflation.val/75).toFixed(5),n.result.luxury=(s.inflation.val/1250).toFixed(5),n.result.casino_prod=(s.inflation.val/1250).toFixed(5),n.result.casino_store=(s.inflation.val/100).toFixed(5),n.result.bank_vault=(s.inflation.val/125).toFixed(5))),n.result[e])}})}(Bn(a,"challenges","inflation",z("evo_challenge_inflation"))),En("add","challenges-gameplay","modes_inflation",z("wiki_challenges_modes_inflation"))}{let a=In(e,{name:"modes_sludge",template:"challenges",paragraphs:7,break:[3,4,5,6,7],h_level:2,para_data:{1:[z("evo_challenge_sludge"),z("wiki_challenges_challenge"),z("race_sludge")],3:[z("race_sludge"),"10x",z("trait_ooze_name")],4:[z("evo_challenge_sludge")],5:[z("race_sludge"),z("wiki_resets_mad")],6:[z("race_sludge"),z("wiki_resets_cataclysm")],7:[z("wiki_challenges_scenarios_junker")]},data_link:{1:[!1,!1,"wiki.html#races-species-sludge"],3:[!1,!1,"wiki.html#traits-species-major_ooze"],5:[!1,"wiki.html#resets-prestige-mad"]}});mc(a,!1,["extinct_sludge","gross"],{gross:!0}),mc(a,!0,["slime_lord"]),gc(a,[{text:"wiki_challenges_reqs_achieve",subreqs:[{text:z("achieve_extinct_junker_name"),color:!!t.stats.achieve.extinct_junker}]},{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"},{text:z("wiki_resets_infusion"),color:!!t.stats.achieve.corrupted,link:"wiki.html#resets-prestige-infusion"}]}]),En("add","challenges-gameplay","modes_sludge",z("wiki_challenges_modes_sludge"))}{let a=In(e,{name:"modes_orbitdecay",template:"challenges",paragraphs:14,break:[5,8,9,10,11,12,13,14],h_level:2,para_data:{1:[z("evo_challenge_orbit_decay")],2:[5e3],5:[z("evo_challenge_orbit_decay")],6:[z("tech_era_intergalactic")],11:[z("space_moon_base_title"),2500],12:[z("space_red_spaceport_title"),z("space_belt_station_title"),1e3],13:[z("interstellar_alpha_starport_title"),100],14:[z("wiki_challenges_scenarios_cataclysm")]}});mc(a,!1,["lamentis"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_blackhole"),color:!!t.stats.achieve.whitehole,link:"wiki.html#resets-prestige-blackhole"},{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"}]}]),En("add","challenges-gameplay","modes_orbitdecay",z("wiki_challenges_modes_orbitdecay"))}{let a=In(e,{name:"modes_witchhunter",template:"challenges",paragraphs:7,break:[4],h_level:2,para_data:{1:[z("evo_challenge_witch_hunter")],4:["300%","150%","75%"],7:[100]}});mc(a,!1,["soul_sponge","nightmare"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:`${z("wiki_universe_magic")} ${z("wiki_resets_ascension")}`,color:!(!t.stats.achieve.ascended||!t.stats.achieve.ascended.mg),link:"wiki.html#resets-prestige-ascension"}]}]),En("add","challenges-gameplay","modes_witchhunter",z("wiki_challenges_modes_witchhunter"))}}{let e=In(a,{name:"scenarios_intro",template:"challenges",paragraphs:3,h_level:2,para_data:{1:[z("evo_scenario")],2:[z("evo_challenge_genes"),z("evo_challenge_run")],3:[z("evo_challenge_genes"),z("evo_challenge_run"),z("wiki_challenges_scenario")]}});Ln("add","challenges-gameplay","scenarios_intro",z("wiki_challenges_scenarios_intro"));{let t=In(e,{name:"scenarios_junker",template:"challenges",paragraphs:4,break:[3,4],h_level:2,para_data:{1:[z("evo_challenge_junker"),z("wiki_challenges_scenario"),z("race_junker")],3:[z("wiki_challenges_scenario"),z("wiki_resets_mad")],4:[z("wiki_challenges_modes_sludge")]},data_link:{1:[!1,!1,"wiki.html#races-species-junker"],3:[!1,"wiki.html#resets-prestige-mad"]}});mc(t,!1,["extinct_junker"]),mc(t,!0,["organ_harvester","the_misery","garbage_pie"]),En("add","challenges-gameplay","scenarios_junker",z("wiki_challenges_scenarios_junker"))}{let a=In(e,{name:"scenarios_cataclysm",template:"challenges",paragraphs:9,break:[4,5,6,8,9],h_level:2,para_data:{1:[z("evo_challenge_cataclysm"),z("wiki_challenges_scenario"),z("wiki_resets_cataclysm")],2:[z("evo_challenge_cataclysm"),z("city_casino"),Kn("hell")],4:[z("evo_challenge_cataclysm")],5:[z("civics_foreign"),z("tech_unification")],7:[z("trait_parasite_name"),"20x"],8:[z("resource_Plasmid_plural_name"),z("resource_AntiPlasmid_plural_name"),300,z("wiki_challenges_scenario"),z("resource_Phage_name")],9:[z("wiki_challenges_scenario"),z("wiki_resets_bioseed")]},data_link:{1:[!1,!1,"wiki.html#resets-prestige-cataclysm"],2:[!1,"wiki.html#space-structures-spc_casino"],5:[!1,"wiki.html#early_space-tech-unification2"],7:["wiki.html#traits-species-major_parasite"],8:["wiki.html#resources-prestige-plasmids","wiki.html#resources-prestige-antiplasmids",!1,!1,"wiki.html#resources-prestige-phage"],9:[!1,"wiki.html#resets-prestige-bioseed"]}});mc(a,!1,["iron_will","failed_history"]),mc(a,!0,["finish_line"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_cataclysm"),color:!!t.stats.achieve.shaken,link:"wiki.html#resets-prestige-cataclysm"}]}]),En("add","challenges-gameplay","scenarios_cataclysm",z("wiki_challenges_scenarios_cataclysm"))}{let a=In(e,{name:"scenarios_banana",template:"challenges",paragraphs:18,break:[2,4,5,8,9,10,18],h_level:2,para_data:{1:[z("evo_challenge_banana"),z("wiki_challenges_scenario"),z("resource_Money_name"),z("morale_tax")],2:[z("tech_unification"),z("evo_challenge_banana")],3:[z("tech_unification"),z("restore")],4:[z("morale_tax"),"95%",z("civics_tax_rates"),z("wiki_challenges_scenarios_banana_para4_note1")],5:[z("tab_market"),z("tech_sundial"),z("evo_challenge_banana"),1,z("resource_Food_name"),z("tech_trade")],6:[z("resource_market_trade_routes")],7:[z("resource_market_trade_routes"),10,25,z("tech_large_trades"),1e6,z("tech_massive_trades")],8:[z("civics_foreign"),"2x","50%"],9:[z("civics_garrison_soldiers"),"20%",z("tab_portal")],10:[z("galaxy_scout_ship"),7,10],11:[z("galaxy_corvette_ship"),21,30],12:[z("galaxy_frigate_ship"),56,80],13:[z("galaxy_cruiser_ship"),175,250],14:[z("galaxy_dreadnought"),1260,1800],15:[z("galaxy_armed_miner"),4,5],16:[z("galaxy_minelayer"),35,50],17:[z("galaxy_raider"),9,12],18:[z("wiki_challenges_scenario"),z("achieve_banana_name")]},data_link:{2:["wiki.html#early_space-tech-unification2"],3:["wiki.html#early_space-tech-unification2"],5:[!1,"wiki.html#primitive-tech-sundial",!1,!1,!1,"wiki.html#civilized-tech-trade"],7:[!1,!1,!1,"wiki.html#civilized-tech-large_trades",!1,"wiki.html#globalized-tech-massive_trades"],10:["wiki.html#intergalactic-structures-scout_ship"],11:["wiki.html#intergalactic-structures-corvette_ship"],12:["wiki.html#intergalactic-structures-frigate_ship"],13:["wiki.html#intergalactic-structures-cruiser_ship"],14:["wiki.html#intergalactic-structures-dreadnought"],15:["wiki.html#intergalactic-structures-armed_miner"],16:["wiki.html#intergalactic-structures-minelayer"],17:["wiki.html#intergalactic-structures-raider"],18:[!1,"wiki.html#perks-prestige-banana"]}});mc(a,!1,["banana"]),mc(a,!0,["banana"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_blackhole"),color:!!t.stats.achieve.whitehole,link:"wiki.html#resets-prestige-blackhole"},{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"}]}]),En("add","challenges-gameplay","scenarios_banana",z("wiki_challenges_scenarios_banana"))}{let a=In(e,{name:"scenarios_truepath",template:"challenges",paragraphs:5,break:[5],h_level:2,para_data:{1:[z("evo_challenge_truepath"),z("wiki_challenges_scenario")],2:[z("tech_era_deep_space")],3:[z("tech_era_interstellar"),z("tech_era_solar")]},data_link:{2:["wiki.html#deep_space-tech"],3:["wiki.html#interstellar-tech","wiki.html#solar-tp_tech"]}});In(a,{name:"scenarios_truepath_genes",template:"challenges",paragraphs:1,h_level:2,para_data:{1:[z("evo_challenge_plasmid"),z("evo_challenge_crispr"),z("evo_challenge_badgenes"),z("evo_challenge_nerfed")]},data_link:{1:["wiki.html#challenges-gameplay-genes_plasmid","wiki.html#challenges-gameplay-genes_crispr","wiki.html#challenges-gameplay-genes_bad","wiki.html#challenges-gameplay-genes_weak"]}}),In(a,{name:"scenarios_truepath_rival",template:"challenges",paragraphs:5,break:[2,3,5],h_level:2}),In(a,{name:"scenarios_truepath_syndicate",template:"challenges",paragraphs:2,h_level:2}),In(a,{name:"scenarios_truepath_costs",template:"challenges",paragraphs:4,break:[2,3,4],h_level:2,para_data:{2:["3x"],3:["2x"]}}),In(a,{name:"scenarios_truepath_market",template:"challenges",paragraphs:1,h_level:2,para_data:{1:["2x"]}}),In(a,{name:"scenarios_truepath_tax",template:"challenges",paragraphs:3,break:[2,4],h_level:2,para_data:{1:["50%"],2:[z("tech_merchandising"),z("city_temple")]}}),In(a,{name:"scenarios_truepath_money",template:"challenges",paragraphs:2,break:[2],h_level:2,para_data:{1:[z("city_bank"),"25%"],2:[z("city_casino"),"50%"]}}),In(a,{name:"scenarios_truepath_morale",template:"challenges",paragraphs:1,h_level:2,para_data:{1:["25%"]}}),In(a,{name:"scenarios_truepath_foreign",template:"challenges",paragraphs:1,h_level:2}),In(a,{name:"scenarios_truepath_fuel",template:"challenges",paragraphs:1,h_level:2,para_data:{1:["25%","150%"]}}),mc(a,!1,["pathfinder","overlord","ashanddust","exodus","obsolete","bluepill","retired"],{ashanddust:!0,exodus:!0,obsolete:!0,bluepill:!0,retired:!0}),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_ascension"),color:!!t.stats.achieve.ascended,link:"wiki.html#resets-prestige-ascension"},{text:z("wiki_resets_infusion"),color:!!t.stats.achieve.corrupted,link:"wiki.html#resets-prestige-infusion"}]}]),En("add","challenges-gameplay","scenarios_truepath",z("wiki_challenges_scenarios_truepath"))}{let a=In(e,{name:"scenarios_lone_survivor",template:"challenges",paragraphs:4,break:[4],h_level:2,para_data:{1:[z("evo_challenge_lone_survivor"),z("wiki_challenges_scenario"),z("tab_tauceti")],3:[z("evo_challenge_truepath")],4:[z("wiki_challenges_scenario"),z("wiki_resets_eden")]},data_link:{4:[!1,"wiki.html#resets-prestige-eden"]}});mc(a,!1,["adam_eve"]),gc(a,[{text:"wiki_challenges_reqs_reset",subreqs:[{text:z("wiki_resets_retired"),color:!!t.stats.achieve.retired,link:"wiki.html#resets-prestige-retired"}]}]),En("add","challenges-gameplay","scenarios_lone_survivor",z("wiki_challenges_scenarios_lone_survivor"))}}}(a);break;case"resets":wc(a);break;case"planets":Gn(a);break;case"universes":!function(e){let t=Ln("create",e),a=[];Object.keys(Wt).forEach((function(e){a.push(e)}));let r=a.map((e=>`${z(`universe_${e}`)}`));In(t,{name:"intro",template:"universe",paragraphs:3,break:[2],h_level:2,para_data:{1:[a.length,r.slice(0,-1).join(", ")+`, ${z("or")} ${r[r.length-1]}`],2:[z("universe_standard")],3:[z("wiki_resets_blackhole")]},data_color:{1:["warning","plain"],2:["caution"]},data_link:{3:["wiki.html#resets-gameplay-blackhole"]}}),Ln("add","universes-gameplay","intro",z("wiki_menu_intro")),In(t,{name:"standard",template:"universe",paragraphs:3,break:[2],h_level:2,para_data:{1:[z("universe_standard")],2:[z("wiki_p_res_dark")],3:[z("wiki_p_res_dark"),+(100*(Is("standard",!1,!0)-1)).toFixed(3)+"%"]},data_color:{1:["caution"]}}),Ln("add","universes-gameplay","standard",z("wiki_universe_standard"));let i=+(100*(1.25+.5*Is("heavy",!1,!0)-1)).toFixed(3)+"%",s=+(100*(1.2+.3*Is("heavy",!1,!0)-1)).toFixed(3)+"%";In(t,{name:"heavy",template:"universe",paragraphs:9,break:[5,8],h_level:2,para_data:{1:[Wt.heavy.desc],2:[z("resource_Oil_name"),z("resource_Helium_3_name"),z("resource_Deuterium_name")],3:[z("tab_space"),"75%"],4:[z("tab_interstellar"),z("tab_galactic"),"50%"],5:[z("wiki_universe_heavy")],6:["5%",z("resource_Plasmid_plural_name"),z("resource_Phage_name"),z("resource_Dark_name")],7:[z("resource_Harmony_name"),"20%"],8:[z("wiki_p_res_dark")],9:[z("wiki_p_res_dark"),i,s]},data_color:{1:["plain"]},data_link:{6:["plain","wiki.html#resources-prestige-plasmids","wiki.html#resources-prestige-phage","wiki.html#resources-prestige-dark"],7:["wiki.html#resources-prestige-harmony","plain"]}}),Ln("add","universes-gameplay","heavy",z("wiki_universe_heavy")),In(t,{name:"antimatter",template:"universe",paragraphs:9,break:[3,6,8],h_level:2,para_data:{1:[z("universe_antimatter")],2:[z("resource_AntiPlasmid_plural_name"),z("resource_Plasmid_plural_name")],3:[z("evo_challenge_plasmid"),z("evo_challenge_mastery")],4:["50%"],5:["50%","6%"],7:["10%"],8:[z("wiki_p_res_dark")],9:[z("wiki_p_res_dark"),+(100*(Is("antimatter",!1,!0)-1)).toFixed(3)+"%"]},data_color:{1:["caution"]},data_link:{2:["wiki.html#resources-prestige-antiplasmids","wiki.html#resources-prestige-plasmids"]}}),Ln("add","universes-gameplay","antimatter",z("wiki_universe_antimatter")),In(t,{name:"evil",template:"universe",paragraphs:7,break:[2,5],h_level:2,para_data:{2:[z("trait_evil_name")],3:[z("trait_evil_name")],4:[z("biome_hellscape_name"),z("biome_eden_name")],5:[z("wiki_p_res_dark")],7:[z("wiki_p_res_dark"),+(100*(Is("evil",!1,!0)-1)).toFixed(3)+"%"]}}),Ln("add","universes-gameplay","evil",z("wiki_universe_evil")),In(t,{name:"micro",template:"universe",paragraphs:6,break:[2,4],h_level:2,para_data:{1:["75%"],4:[z("wiki_p_res_dark")],5:[z("wiki_p_res_dark"),Is("micro",!1,!0),Is("micro",!0,!0)],6:["1.005"]}}),Ln("add","universes-gameplay","micro",z("wiki_universe_micro")),In(t,{name:"magic",template:"universe",paragraphs:8,break:[4,7],h_level:2,para_data:{6:[80],7:[z("wiki_p_res_dark")],8:[z("wiki_p_res_dark"),+(100*(Is("magic",!1,!0)-1)).toFixed(3)+"%"]}}),Ln("add","universes-gameplay","magic",z("wiki_universe_magic"))}(a);break;case"hell":!function(e){let t=Ln("create",e);t.append(`

                                  ${z("wiki_hell")}

                                  `),In(t,{name:"threat",template:"hell",paragraphs:3,para_data:{1:["10,000"],2:["1000-1250"]},data_color:{1:["caution"],2:["warning"]}}),Ln("add","hell-gameplay","threat",z("wiki_hell_threat")),In(t,{name:"siege",template:"hell",paragraphs:5,para_data:{3:["5k+"]},data_color:{3:["caution"]}}),Ln("add","hell-gameplay","siege",z("wiki_hell_siege")),In(t,{name:"strategy",template:"hell",paragraphs:3}),Ln("add","hell-gameplay","strategy",z("wiki_hell_strategy"));let a=In(t,{name:"soul_gem",template:"hell",paragraphs:4,para_data:{1:[z("wiki_hell_soul_gem"),z("tab_portal")],3:[z("tech_demon_attractor")]}}),r=$("
                                  ");a.append(r),Ln("add","hell-gameplay","soul_gem",z("wiki_hell_soul_gem")),In(t,{name:"infernite",template:"hell",paragraphs:4}),Ln("add","hell-gameplay","infernite",z("wiki_hell_infernite")),t.append(`

                                  ${z("wiki_hell_deep")}

                                  `),In(t,{name:"pit",template:"hell",paragraphs:3,para_data:{1:["1,000,000",z("galaxy_telemetry_beacon")],2:[z("portal_soul_forge_title")]},data_link:{1:[!1,"wiki.html#intergalactic-structures-telemetry_beacon"],2:["wiki.html#hell-structures-soul_forge"]}}),Ln("add","hell-gameplay","pit",z("wiki_hell_pit")),In(t,{name:"corrupted",template:"hell",paragraphs:3,para_data:{1:[z("tech_metaphysics"),z("portal_soul_forge_title"),z("resource_Corrupt_Gem_name")],2:[z("portal_ruins_name")],3:[z("tech_era_intergalactic")]},data_link:{1:["wiki.html#intergalactic-tech-metaphysics"]}}),Ln("add","hell-gameplay","corrupted",z("wiki_hell_corrupted"));let i=Ks();In(t,{name:"pillar",template:"hell",paragraphs:6,break:[4,5,6],para_data:{1:[z("portal_ruins_name")],2:["1%",z("harmonic")],3:["3%"],4:[z("harmonic"),"2%","6%"],5:[z("wiki_hell_pillar_para5d1"),12],6:[z("harmonic"),`${(100*(i[0]-1)).toFixed(0)}%`,`${(100*(i[1]-1)).toFixed(0)}%`]},data_link:{5:["wiki.html#hell-structures-west_tower"]}}),Ln("add","hell-gameplay","pillar",z("wiki_hell_pillar")),t.append(`

                                  ${z("portal_spire_name")}

                                  `),In(t,{name:"spire",template:"hell",paragraphs:5,break:[4],para_data:{4:[z("resource_Blood_Stone_name")],5:[z("wiki_resets_infusion")]},data_link:{5:["wiki.html#resets-prestige-infusion"]}}),Ln("add","hell-gameplay","spire",z("portal_spire_name"));{let e=In(t,{name:"mech",template:"hell",paragraphs:2,para_data:{2:[5,z("portal_mech_size_small"),z("portal_mech_size_medium"),z("portal_mech_size_large"),z("portal_mech_size_titan"),z("portal_mech_size_collector")]}}),a=fa("small");In(e,{name:"scout",template:"hell",paragraphs:10,break:[3,4,5,6,10],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_small")],2:[1,1,z("arpa_blood_prepared_title")],3:[(100*qa("small")).toFixed(2)],4:[ba("small"),a.c,a.s],5:[z("portal_mech_equip_jumpjet")],7:["1%"],8:[z("portal_spire_status_fog"),z("portal_spire_status_dark")],9:["100%"],10:["8%"]},data_link:{2:[!1,!1,"wiki.html#blood-prestige-prepared"]}});let r=fa("medium");In(e,{name:"standard",template:"hell",paragraphs:6,break:[3,4,5,6],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_medium")],2:[1,1,2,z("arpa_blood_prepared_title")],3:[(100*qa("medium")).toFixed(2)],4:[ba("medium"),r.c,r.s],5:[z("portal_mech_equip_jumpjet")],6:["5%"]},data_link:{2:[!1,!1,!1,"wiki.html#blood-prestige-prepared"]}});let i=fa("large");In(e,{name:"heavy",template:"hell",paragraphs:6,break:[3,4,5,6],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_large")],2:[2,2,3,z("arpa_blood_prepared_title")],3:[(100*qa("large")).toFixed(2)],4:[ba("large"),i.c,i.s],5:[z("portal_mech_equip_battery")]},data_link:{2:[!1,!1,!1,"wiki.html#blood-prestige-prepared"]}});let s=fa("titan");In(e,{name:"titan",template:"hell",paragraphs:7,break:[3,4,5,6,7],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_titan")],2:[4,4,5,z("arpa_blood_prepared_title")],3:[(100*qa("titan")).toFixed(2)],4:[ba("titan"),s.c,s.s],5:[z("portal_mech_equip_target")],7:["25%"]},data_link:{2:[!1,!1,!1,"wiki.html#blood-prestige-prepared"]}});let n=fa("collector");In(e,{name:"collector",template:"hell",paragraphs:5,break:[3,4,5],h_level:4,header:!0,para_data:{1:[z("portal_mech_size_collector")],2:[2,3,z("arpa_blood_prepared_title")],3:[ba("collector"),n.c,n.s],4:[z("portal_mech_equip_jumpjet")]},data_link:{2:[!1,!1,"wiki.html#blood-prestige-prepared"]}}),Ln("add","hell-gameplay","mech",z("wiki_hell_mech"))}{let e=["wheel","tread","biped","quad","spider","hover"],a=["sand","swamp","forest","jungle","rocky","gravel","muddy","grass","brush","concrete"],r=[];r.push(e.length),e.forEach((function(e){r.push(z(`portal_mech_chassis_${e}`))}));let i=In(t,{name:"chassis",template:"hell",paragraphs:4,para_data:{1:r,2:[a.length]}});a.forEach((function(t){let a={};for(let r=1;r<=e.length;r++){let i=+(100*xa({chassis:e[r-1],size:"small"},t)).toFixed(1),s=+(100*xa({chassis:e[r-1],size:"large"},t)).toFixed(1);a[r+1]=`${z("wiki_hell_effectiveness",[`${z(`portal_mech_chassis_${e[r-1]}`)}`,`${i}%`,`${s}%`,'S','L'])}`}In(i,{name:`t_${t}`,template:"hell",label:z(`portal_spire_type_${t}`),paragraphs:7,break:[2,3,4,5,6,7],h_level:4,header:!0,text:{1:`portal_spire_type_${t}_desc`},rawtext:a,pclass:"col2 sk1"})})),Ln("add","hell-gameplay","chassis",z("wiki_hell_chassis"))}{let e=["laser","flame","plasma","kinetic","missile","sonic","shotgun","tesla"],a=In(t,{name:"monsters",template:"hell",paragraphs:4,para_data:{2:[e.length]}});Object.keys(va).forEach((function(t){let r={};for(let a=1;a<=e.length;a++){let i=+(100*(va[t].weapon.hasOwnProperty(e[a-1])?va[t].weapon[e[a-1]]:1)).toFixed(0);r[a]=`${z("wiki_hell_weapon_effect",[`${z(`portal_mech_weapon_${e[a-1]}`)}`,`${i}%`])}`}In(a,{name:`boss_${t}`,template:"hell",label:z(`portal_mech_boss_${t}`),paragraphs:8,break:[2,3,4,5,6,7,8],h_level:4,header:!0,rawtext:r,pclass:"col2"})})),Ln("add","hell-gameplay","monsters",z("wiki_hell_monsters"))}{let e=In(t,{name:"hazard",template:"hell",paragraphs:8,break:[3,4,5,6,7],para_data:{3:["+1","10+"],4:[`6/(105-${z("wiki_hell_hazard_para3_note")})`,"+1","25-100"],5:[`11/(260-${z("wiki_hell_hazard_para3_note")})`,"+1","101-250"],6:[`26/(1025-${z("wiki_hell_hazard_para3_note")})`,"+1","251-1000"],7:["-1"],8:[z("portal_spire_status_freeze"),z("portal_spire_status_hot"),z("portal_spire_status_rain"),z("portal_spire_status_hail")]}}),a={1:"wiki_hell_hazard_effect",2:"wiki_hell_hazard_counter"};In(e,{name:"h_freeze",template:"hell",label:z("portal_spire_status_freeze"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["75%"],2:[z("portal_mech_equip_radiator")]}}),In(e,{name:"h_hot",template:"hell",label:z("portal_spire_status_hot"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["75%"],2:[z("portal_mech_equip_coolant")]}}),In(e,{name:"h_corrosive",template:"hell",label:z("portal_spire_status_corrosive"),paragraphs:3,break:[2,3],h_level:4,header:!0,text:{1:"wiki_hell_hazard_effect",2:"wiki_hell_hazard_counter",3:"wiki_hell_hazard_partial"},para_data:{1:["75%"],2:[z("portal_mech_equip_ablative")],3:[z("portal_mech_equip_shields")]}}),In(e,{name:"h_humid",template:"hell",label:z("portal_spire_status_humid"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["25%"],2:[z("portal_mech_equip_seals")]}}),In(e,{name:"h_windy",template:"hell",label:z("portal_spire_status_windy"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_chassis"},para_data:{1:["50%",z("portal_mech_chassis_hover")]}}),In(e,{name:"h_hilly",template:"hell",label:z("portal_spire_status_hilly"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_not_chassis"},para_data:{1:["25%",z("portal_mech_chassis_spider")]}}),In(e,{name:"h_mountain",template:"hell",label:z("portal_spire_status_mountain"),paragraphs:2,break:[2],h_level:4,header:!0,text:{1:"wiki_hell_hazard_either",2:"wiki_hell_hazard_partial"},para_data:{1:["50%",z("portal_mech_chassis_spider"),z("portal_mech_equip_grapple")],2:[z("portal_mech_equip_flare")]}}),In(e,{name:"h_radioactive",template:"hell",label:z("portal_spire_status_radioactive"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["50%"],2:[z("portal_mech_equip_shields")]}}),In(e,{name:"h_quake",template:"hell",label:z("portal_spire_status_quake"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["75%"],2:[z("portal_mech_equip_stabilizer")]}}),In(e,{name:"h_dust",template:"hell",label:z("portal_spire_status_dust"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["50%"],2:[z("portal_mech_equip_seals")]}}),In(e,{name:"h_river",template:"hell",label:z("portal_spire_status_river"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_not_chassis"},para_data:{1:["35%",z("portal_mech_chassis_hover")]}}),In(e,{name:"h_tar",template:"hell",label:z("portal_spire_status_tar"),paragraphs:2,break:[2],h_level:4,header:!0,text:{1:"wiki_hell_hazard_not_chassis",2:"wiki_hell_hazard_worse"},para_data:{1:["25%",z("portal_mech_chassis_quad")],2:["50%",z("portal_mech_chassis_tread"),z("portal_mech_chassis_wheel")]}}),In(e,{name:"h_steam",template:"hell",label:z("portal_spire_status_steam"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["25%"],2:[z("portal_mech_equip_shields")]}}),In(e,{name:"h_flooded",template:"hell",label:z("portal_spire_status_flooded"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_not_chassis"},para_data:{1:["65%",z("portal_mech_chassis_hover")]}}),In(e,{name:"h_fog",template:"hell",label:z("portal_spire_status_fog"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["80%"],2:[z("portal_mech_equip_sonar")]}}),In(e,{name:"h_rain",template:"hell",label:z("portal_spire_status_rain"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["25%"],2:[z("portal_mech_equip_seals")]}}),In(e,{name:"h_hail",template:"hell",label:z("portal_spire_status_hail"),paragraphs:1,h_level:4,header:!0,text:{1:"wiki_hell_hazard_either2"},para_data:{1:["25%",z("portal_mech_equip_ablative"),z("portal_mech_equip_shields")]}}),In(e,{name:"h_chasm",template:"hell",label:z("portal_spire_status_chasm"),paragraphs:2,break:[2],h_level:4,header:!0,text:a,para_data:{1:["90%"],2:[z("portal_mech_equip_grapple")]}}),In(e,{name:"h_dark",template:"hell",label:z("portal_spire_status_dark"),paragraphs:3,break:[2,3],h_level:4,header:!0,text:{1:"wiki_hell_hazard_effect",2:"wiki_hell_hazard_counter",3:"wiki_hell_hazard_partial"},para_data:{1:["90%"],2:[z("portal_mech_equip_infrared")],3:[z("portal_mech_equip_flare")]}}),In(e,{name:"h_gravity",template:"hell",label:z("portal_spire_status_gravity"),paragraphs:3,break:[2,3],h_level:4,header:!0,text:{1:"wiki_hell_hazard_gravity",2:"wiki_hell_hazard_gravity",3:"wiki_hell_hazard_gravity"},para_data:{1:[z("portal_mech_size_medium"),"20%"],2:[z("portal_mech_size_large"),"55%"],3:[z("portal_mech_size_titan"),"75%"]}}),Ln("add","hell-gameplay","hazard",z("wiki_hell_hazard"))}{let e=In(t,{name:"equipment",template:"hell",paragraphs:1,h_level:2,para_data:{1:[z("portal_mech_equip_jumpjet"),z("portal_mech_equip_battery"),z("portal_mech_equip_target")]}});Ln("add","hell-gameplay","equipment",z("wiki_hell_equipment")),In(e,{name:"eq_jump",template:"hell",label:z("portal_mech_equip_jumpjet"),paragraphs:4,break:[4],h_level:3,header:!0,para_data:{1:[z("portal_mech_equip_jumpjet"),z("wiki_hell_scout"),z("wiki_hell_standard"),z("wiki_hell_collector")],2:["20%"],3:["10%",z("portal_spire_status_gravity")]}}),In(e,{name:"eq_battery",template:"hell",label:z("portal_mech_equip_battery"),paragraphs:2,h_level:3,header:!0,para_data:{1:[z("portal_mech_equip_battery"),z("wiki_hell_heavy")],2:["2%"]}}),In(e,{name:"eq_target",template:"hell",label:z("portal_mech_equip_target"),paragraphs:3,h_level:3,header:!0,para_data:{1:[z("portal_mech_equip_target"),z("wiki_hell_titan")],2:["25%"]}})}}(a)}}function $c(e){e.append(`
                                  ${z("wiki_arpa_crispr")}
                                  `);let a=$("
                                  "),r=Ln("create",a);e.append(a),Object.keys(je).forEach((function(e){let a=je[e].id.split("-"),i=$(`
                                  `);r.append(i),function(e,a){let r=!!(t.genes[je[a].grant[0]]&&t.genes[je[a].grant[0]]>=je[a].grant[1]);e.append(`

                                  ${je[a].title}

                                  ${r?`${z("wiki_arpa_purchased")}`:""}${z(`wiki_arpa_crispr_${je[a].grant[0]}`)}: ${je[a].grant[1]}
                                  `);let i=$('
                                  ');e.append(i),i.append(`
                                  ${je[a].desc}
                                  `);let s=$('
                                  ');if(i.append(s),Object.keys(je[a].cost).forEach((function(e){let r=je[a].cost[e]();if(r>0){"Plasmid"===e&&"antimatter"===t.race.universe&&(e="AntiPlasmid");let a=z(`resource_${e}_name`);s.append(`
                                  ${a}: ${r}
                                  `)}})),Object.keys(je[a].reqs).length>0){let r=$(`
                                  ${z("wiki_arpa_crispr_req")}
                                  `);e.append(r);let i=!1;Object.keys(je[a].reqs).forEach((function(e){let s=t.genes[e]&&t.genes[e]>=je[a].reqs[e]?"success":"danger";r.append(`${i?", ":""}${z(`wiki_arpa_crispr_${e}`)} ${je[a].reqs[e]}`),i=!0}))}if(xc.hasOwnProperty(a)){let t=!1,r=$(`
                                  ${z("wiki_arpa_crispr_req_extra")}
                                  `);e.append(r),Object.keys(xc[a]).forEach((function(e){let i=xc[a][e].color?"success":"danger",s=xc[a][e].link?`${xc[a][e].title}`:xc[a][e].title;r.append(`${t?", ":""}${s}`),t=!0}))}}(i,e),Ln("add","crispr-prestige",a[1],je[e].title)}))}const xc={universal:[{title:z("wiki_tech_special_universe_not",[z("universe_standard")]),color:"standard"!==t.race.universe,link:"wiki.html#universes-gameplay-standard"}],standard:[{title:z("wiki_tech_special_universe_not",[z("universe_standard")]),color:"standard"!==t.race.universe,link:"wiki.html#universes-gameplay-standard"}],ancients:[{title:z("wiki_arpa_crispr_special_ancients"),color:!!t.genes.old_gods,link:"wiki.html#resets-prestige-intro"}],bleeding_effect:[{title:z("wiki_tech_special_universe",[z("universe_antimatter")]),color:"antimatter"===t.race.universe,link:"wiki.html#universes-gameplay-antimatter"}],blood_remembrance:[{title:z("wiki_arpa_crispr_special_blood_remembrance"),color:t.prestige.Blood_Stone.count>=1,link:"wiki.html#resources-prestige-blood"}]};var qc={};function Pc(e){e.append(`
                                  ${z("wiki_arpa_blood")}
                                  `);let a=$("
                                  "),r=Ln("create",a);e.append(a),Object.keys(Oe).forEach((function(e){let a=Oe[e].id.split("-"),i=$(`
                                  `);r.append(i),function(e,a){let r=!!(t.blood[Oe[a].grant[0]]&&t.blood[Oe[a].grant[0]]>=Oe[a].grant[1]);e.append(`

                                  ${Oe[a].title}

                                  ${r?`${z("wiki_arpa_purchased")}`:""}${z(`wiki_arpa_blood_${Oe[a].grant[0]}`)}: ${Oe[a].grant[1]}
                                  `);let i=$('
                                  ');e.append(i),i.append(`
                                  ${Oe[a].desc}
                                  `);let s=$('
                                  ');if(i.append(s),Object.keys(Oe[a].cost).forEach((function(e){let t=z(`resource_${e}_name`);if("*"===Oe[a].grant[1])s.append(`
                                  ${t}: {{ r.${e}.cost }}
                                  `);else{let r=Oe[a].cost[e]();r>0&&s.append(`
                                  ${t}: ${r}
                                  `)}})),Object.keys(Oe[a].reqs).length>0||Oe[a].hasOwnProperty("condition")){let r=$(`
                                  ${z("wiki_arpa_crispr_req")}
                                  `);e.append(r);let i=!1;if(Object.keys(Oe[a].reqs).length>0&&Object.keys(Oe[a].reqs).forEach((function(e){let s=t.blood[e]&&t.blood[e]>=Oe[a].reqs[e]?"success":"danger";r.append(`${i?", ":""}${z(`wiki_arpa_blood_${e}`)} ${Oe[a].reqs[e]}`),i=!0})),Oe[a].hasOwnProperty("condition")){let e=t.genes.blood&&t.genes.blood>=3?"success":"danger";r.append(`${i?", ":""}${z("wiki_arpa_crispr_blood")} 3`)}}"*"===Oe[a].grant[1]&&function(e,a){let r={owned:0},i={},s=Oe[a];r.real_owned=t.blood[a]?t.blood[a]:0;let n=s.cost;Object.keys(n).forEach((function(e){i[e]={}}));let c=function(){Object.keys(i).forEach((function(e){let t=n[e]?n[e](r.owned-r.real_owned):0;i[e].vis=t>0,i[e].cost=t}))};c(),e.append($(`\n
                                  \n
                                  \n
                                  ${z("wiki_calc_level")} -+
                                  \n
                                  \n
                                  \n \n
                                  \n
                                  \n `)),Cs({el:`#${a}`,data:{i:r,r:i},methods:{val(e){r[e]=Math.round(r[e]),r[e]&&r[e]<0&&(r[e]=0),c()},less(e){r[e]>0&&r[e]--},more(e){r[e]++},importInputs(){r.owned=r.real_owned}}})}(e,a)}(i,e),Ln("add","blood-prestige",a[1],Oe[e].title)}))}Object.keys(je).forEach((function(e){let t=je[e];qc[t.grant[0]]||(qc[t.grant[0]]={}),"string"==typeof je[e].title?je[e].title:je[e].title(),qc[t.grant[0]][t.grant[1]]={name:e}}));var jc={};Object.keys(Oe).forEach((function(e){let t=Oe[e];jc[t.grant[0]]||(jc[t.grant[0]]={}),"string"==typeof Oe[e].title?Oe[e].title:Oe[e].title(),jc[t.grant[0]][t.grant[1]]={name:e}}));const Oc={launch_facility:[z("wiki_arpa_project_launch_facility")],monument:[function(){let e=[z("arpa_project_monument_obelisk"),z("arpa_project_monument_statue"),z("arpa_project_monument_sculpture"),z("arpa_project_monument_monolith"),z("arpa_project_monument_pillar"),z("arpa_project_monument_megalith")],t=[z("resource_Stone_name"),z("resource_Aluminium_name"),z("resource_Steel_name"),z("resource_Cement_name"),z("resource_Bones_name"),z("resource_Crystal_name")],a=`
                                  ${z("wiki_arpa_project_monument",[e.length,e.join(", ")])}
                                  `;for(let r=0;r${z("wiki_arpa_project_monument_type",[`${e[r]}`,`${t[r]}`])}
                                  `;return a}(),z("wiki_arpa_project_monument_random"),z("wiki_arpa_project_monument_exceptions")],railway:[z("wiki_arpa_project_railway_homeless",[3,7,11,17,25,38,59,100,225])],roid_eject:[z("wiki_arpa_project_roid_eject")],tp_depot:[z("wiki_arpa_project_depot")],nexus:[z("wiki_arpa_project_magic")],syphon:[z("wiki_arpa_project_magic")]};const Mc=[{version:"1.3.8",revision:"a",date:"6/1/2023",changes:["Fixed high pop scaling."]},{version:"1.3.8",date:"6/1/2023",changes:["Unfathomable bug fixes.","Psychic powers up time now scale with rank of Ancient Nightmare.","Additional Psychic power upgrades.","Intergalactic Raider renamed to Corsair."]},{version:"1.3.7",revision:"a",date:"5/30/2023",changes:["Fixed issue with drawing the same alien species twice in intergalactic content.","Adjusted Mana costs for some research techs in Witch Hunter."]},{version:"1.3.7",date:"5/29/2023",changes:["Added Magic universe exclusive challenge: Witch Hunter.","Reduced Encrypted Data cost of Data Analysis, Advanced Medkits, Automated Warehousing, Elerium Extraction, and Drone Warfare techs.","Star Forge smelting bonus rebalanced.","Antimatter Dark Energy effect now applies to Truepath Ship power generation.","Fixed Magocracy Crystal bonus.","Reduced Crystal cost of Alchemy.","Fixed Humpback trait rank scaling.","Infiltrator can now steal Alien Biotech on Truepath.","Fixed brownout issue with using Replicator Gov task when constructing a new powered building.","Fixed rejuvenated trashed planet bonus.","Fixed orbit period on reterraformed planets."]},{version:"1.3.6",date:"4/22/2023",changes:["Added Astrological signs.","Added Motivated Event.","Operating Bases now function as Hospitals in Orbit Decay scenario.","Stellar Forge is now locked to using Star Fuel for smelting.","Species with the Forge trait can now use Inferno Fuel and Star Fuel.","Reduced Wireless Signal needed to Contact womlings in Lone Survivor."]},{version:"1.3.5",revision:"c",date:"4/16/2023",changes:["Made Egg #17 easier to get in Cataclysm mode."]},{version:"1.3.5",revision:"b",date:"4/9/2023",changes:["Increased egg accessibility with certain traits or challenge modes."]},{version:"1.3.5",revision:"a",date:"4/8/2023",changes:["Fixed a bug that caused eggs 16-18 not to count for unlocking the egg hunt feat."]},{version:"1.3.5",date:"4/7/2023",changes:["Avian species now have the Flier trait.","Avian Rigid trait replaced with Sky Lover.","Added Wireless storage to High-Tech farm in isolation","Fixed truepath dreadnought power costs.","Fixed a bug that could assign extra challenge genes.","Fixed a bug with changing languages with active Tau Ceti content.","Fixed many issues with preload tab content in the early game."]},{version:"1.3.4",revision:"b",date:"3/30/2023",changes:["Prevented some bugs caused by distributed power mode from occurring.","You can now unlock World Domination, Illuminati, Syndicate, and Pacifist in Truepath."]},{version:"1.3.4",revision:"a",date:"3/25/2023",changes:["A restore point is now made if you select isolation protocol."]},{version:"1.3.4",date:"3/24/2023",changes:["Evolving Synth can now choose imitation race from any species killed by an AI Apocalypse.","Fixed issue with miscalculating low fuel usage for various power generating structures.","Extractor Ship Isolation output boosted by 20%.","Added additional Hooved reskins.","Fixed various issues with Preload Tab Content.","Explorer Ship config is now locked down for Engine, Sensor, and Weapon components.","Skilled Servants assigned to craft inactive resources will now be refunded."]},{version:"1.3.3",revision:"a",date:"3/20/2023",changes:["Fixed a bug that could cause the Test Launch to be unavailable."]},{version:"1.3.3",date:"3/15/2023",changes:["Rebalanced Soul Gem drop mechanics.","Added Annihilation Feat.","Added additional Mass Ejector Optimizer config mode.","Servants are no longer affected by most racial traits.","The Lone Survivor can no longer benefit from Hivemind.","Fixed High Pop issue with Pit Miners.","Fixed bug with unlocking Replicator without a Governor."]},{version:"1.3.2",revision:"c",date:"3/8/2023",changes:["Fixed cataclysm reset while having preload tab content enabled."]},{version:"1.3.2",revision:"b",date:"3/5/2023",changes:["Fixed Rock Quarry under industry tab for Smoldering players."]},{version:"1.3.2",revision:"a",date:"3/5/2023",changes:["Adjusted hell calculation."]},{version:"1.3.2",date:"3/4/2023",changes:["High-Tech Factory changed back to tool modifier, however value is increased from original 25% to 90%.","Advanced Material Synthesis increased from 50% to 65%.","Added new interaction between Hell Surveyors and Drone victims.","Fixed bug that would cause Replicator Governor task to swap resources when focusing a resource without a cap.","Fixed inability to produce Chrysotile in Isolation."]},{version:"1.3.1",date:"3/3/2023",changes:["Added Advanced Material Synthesis tech to Isolation path.","High-Tech Factory crafting bonus changed from a Tool modifier to a direct multiplier.","Updated Mass Ejector Optimizer logic.","Fixed a bug that broke Cataclysm reset.","Fixed fuel calculation bug with Moon Bases and Spaceports.","Fixed issue with self replicating Synth and Nano.","Fixed bugs with purchasing CRISPR techs in Antimatter universe."]},{version:"1.3.0",revision:"b",date:"3/1/2023",changes:["Fixed issue with Mass Ejector Optimizer gov task breaking the governor subtab."]},{version:"1.3.0",revision:"a",date:"3/1/2023",changes:["Fixed Antimatter universe."]},{version:"1.3.0",date:"3/1/2023",changes:["The True Path has been extended, explore Tau Ceti and expand your civilization.","Added Perks: Evolve Master and Evolve Grandmaster.","Added Distributed Low Power mode setting.","Added Precognition CRISPR upgrade.","Strong trait now buffs basic jobs but has a weaker effect on manual resource collection.","Ships in Truepath can now only be scrapped at the Shipyard.","Truepath Sensor Range and Costs adjusted. Range now depends partly on base ship class.","Queue stacks now indicate first block vs last blocking resource with a gradient indicator.","Added screen reader improvements for blocking resources.","You can no longer unlock Anarchist by Cataclysm.","Syndicate will now also steal food from Biodomes.","Reinforced Shed upgrade now requires unlocking Iron Mining.","You must now construct a Titan Habitat before a Titan Mine.","Removed dark background effect from modal popups.","Increased Entrepreneur Governor trade bonus from 75% to 125% and Bank capacity boost from 10% to 12%.","Increased Media Governor morale bonuses and Library bonus.","Increased Soldier Governor combat bonus from 5% to 25%.","Increased Educator Governor knowledge bonus from 5% to 6%.","Increased Spiritualist Governor worker bonus from 10% to 20% and tourism bonus from $2 to $5 per Temple.","Increased Noble Governor tax cap bonus from 10% to 20%.","Bluecollar Governor now increases output of Coal and Oil power plants and boosts Miners, Smelter, and Oil Derrick.","Bureaucrat Governor now provides a slight boost to government effects."]},{version:"1.2.21",date:"1/10/2023",changes:["New Achievement filtering options in Wiki.","Updated Chinese lang file.","Updated Korean lang file."]},{version:"1.2.20",date:"9/16/2022",changes:["New homelessness system.","Factory, Mining Droids, and Graphene Plants will remember resource assignment after a low power shutdown.","Terraforming and Ascension can no longer be queued or multi-clicked.","AI Cores show correct bonus in tooltip.","Stealing Rocketry will now unlock rival in Truepath.","Playful will no longer remove unemployed stress with no hunters.","Andromeda Citizens will no longer stick around if abandoned by a stargate shutdown.","Fixed various bugs with mutating in or out some traits.","Made some improvements for screen readers to determine active state of challenges."]},{version:"1.2.19",revision:"a",date:"8/21/2022",changes:["Home Planet Orbital structures are now merged with the Moon instead of Red Planet in Cataclysm."]},{version:"1.2.19",date:"8/20/2022",changes:["Added rank scaling effects to traits: Carnivore, Hooved, Leathery, Unified, & Magnificent.","Structures orbiting the home planet are now moved to the Red planet after Orbit Decay or during Cataclysm.","Fixed a bug with deactivating fuel consuming structures when fuel runs dry.","Already active Governor tasks will no longer display for assignment in other task slots.","Constructing a Stellar or Infernal Forge will now assign Iron as a default resource instead of nothing.","Buffed effects of Star Forge fueled smelting.","Fixed an incorrect source label for money storage in Orbit Decay."]},{version:"1.2.18",revision:"a",date:"8/14/2022",changes:["Fixed ARPA queueing."]},{version:"1.2.18",date:"8/14/2022",changes:["More accurate timers when using Governor Trash Management task.","Optimistic Min Morale effect now scales with trait rank.","Fixed TP loot table when Assaulting or Sieging rival."]},{version:"1.2.17",revision:"a",date:"8/10/2022",changes:["Cheese Event power is now scaled with your cheese level.","Fixed Soft Reset bug with Rejuvenated."]},{version:"1.2.17",date:"8/10/2022",changes:["New Hell stats tracking and analytics.","Fixed Genetics not unlocking in Cataclysm.","Fixed many High Pop scaling interactions.","Fixed some loading bugs with wiki when no save data is present.","Updated various wiki entries and calculators.","Updated Pig Latin."]},{version:"1.2.16",revision:"a",date:"8/8/2022",changes:["Fixed OD bugs with Ziggurat, Garage, and Fabrication.","Fixed Launch Facility sometimes getting stuck in queue."]},{version:"1.2.16",date:"8/4/2022",changes:["Added Orbit Decay Challenge.","Added Retrograde planetary trait.","New achievement: Better dead than red.","New CRISPR upgrade: Civil Service.","Other stuff the dev was too lazy to document."]},{version:"1.2.15",revision:"a",date:"7/1/2022",changes:["Fixed bug that prevented games without save data from loading."]},{version:"1.2.15",date:"7/1/2022",changes:["Firework Festival now starts on July 1st and ends July 4th.","Added Dracula theme by azzzertyy.","Fixed bug with Horseshoe governor and multiplier keys.","Fixed issues with starting Cataclysm as Synth.","Fixed bugs with wrong path techs being displayed.","Evil Synth now start with a Graveyard instead of a Lumberyard.","Deify and study can no longer be queued at same time.","Restore backup no longer requires double clicking to trigger confirmation box."]},{version:"1.2.14",revision:"a",date:"4/19/2022",changes:["Fixed some minor bugs.","Updated some translations."]},{version:"1.2.14",date:"4/1/2022",changes:["Added Titan Mine slider to Industry tab.","Added additional popup confirmation to Restore Backup.","Nanite Factory interface now has tooltips for each resource","The Vault Discovery event can no longer occur if there are 0 Archaeologists and/or if Suppression is at 0%","Fixed bugs related to unlocking the Fool feat.","Fixed bugs with Mass Ejector optimizor governor task."]},{version:"1.2.13",date:"3/31/2022",changes:["Restore Backup must now be clicked twice to trigger."]},{version:"1.2.12",revision:"c",date:"3/7/2022",changes:["Fixed Double Density achievement."]},{version:"1.2.12",revision:"b",date:"3/2/2022",changes:["Fixed logic fault with mech constructor inferno upgrades."]},{version:"1.2.12",revision:"a",date:"3/1/2022",changes:["Fixed some bugs with planet traits.","Fixed bug with attacking on Swamp planets."]},{version:"1.2.12",date:"2/28/2022",changes:["Planets can now have upto two traits.","Advanced Biomes: Savanna, Swamp, Ashland, and Taiga can now appear.","Added Permafrost planetary trait.","Forest Biome lumber bonus changed from 15% to 20%.","Exotic materials are now ranked higher by the Mass Optimizer governor task.","Repair droid effect on Carport repairs buffed from 5% to 8%.","You must now discover the Hell Vault through Archaeology.","Water now has Mass."]},{version:"1.2.11",date:"2/16/2022",changes:["Added Doomed achievement to the perks lists.","Added Governor CRISPR tree to perks list.","Updated prestige gain/bonus calculators.","Fixed Ritual Casting not showing up in Industry in Cataclysm.","Detritivores no longer see the Farming ritual.","Fixed Entertainer tooltip showing twice the effect of Musical.","Fixed Gauss Rifles showing the effect for Disruptor Rifles.","Fixed Water Freighter tooltip showing half the Helium-3 cost.","Fixed some affordability checks."]},{version:"1.2.10",date:"2/7/2022",changes:["Bioseed probes now have significantly less cost creep inside True Path scenario.","You can no longer manually buy or sell resources while the game is paused.","Fixed bug with High Pop trait and Savings Bonds granting too much money.","Minor bug fixes"]},{version:"1.2.9",date:"1/29/2022",changes:["Spies may now sell you out when caught or escape when failing a mission.","Infiltrator can now steal Quantium tech inside True Path.","Genetics Lab UI updated."]},{version:"1.2.8",revision:"a",date:"1/19/2022",changes:["Fixed Farmer per Farm scaling with High Pop trait.","Adjusted low end scaling of High Pop Hivemind trait.","Wireless Signal cost for Symposium lowered.","Added Anarchy scaling with High Pop"]},{version:"1.2.8",date:"1/19/2022",changes:["Insectoid genus redesigned with High Population trait.","Fixed bug that caused incorrect timer calculations when using Slow or Hyper trait at any rank other then 1."]},{version:"1.2.7",revision:"a",date:"1/11/2022",changes:["Fixed storage bug with standard universe."]},{version:"1.2.7",date:"1/11/2022",changes:["Failed Experiment Challenge mode.","Ziggurat bonus separated from base production of buildings.","Fixed bug that prevented smoldering races from being able to loot Chrysotile","Fixed bug that would cause Intergalactic Tech page in wiki not to load if you were playing in Antimatter universe."]},{version:"1.2.6",date:"12/24/2021",changes:["Fixed bug that prevented custom Synthetic race from showing if you refreshed the page.","Fixed bugs with Synthetic evolution and traits: Calm, Cannibalize, and Magnificent.","Fixed bugs with using the quick tab keys when preload tabs is enabled."]},{version:"1.2.5",date:"12/21/2021",changes:["Fixed bug that caused a planet to lose its geology traits after an AI reset.","Fixed bug with scavenger job description."]},{version:"1.2.4",date:"12/19/2021",changes:["Solar system now has elliptical orbits.","Fixed Evolve Adept Food bonus.","Rank of each aquired trait is now listed in genetics tab.","Crate/Container sources are now listed in resource popup.",'Manual buying/selling will auto scale down to prevent "waste".']},{version:"1.2.3",date:"12/16/2021",changes:["Expanded Festive Season to include additional species."]},{version:"1.2.2",date:"12/15/2021",changes:["Graphene Plants now show on industry tab for True Path.","Added entry for Festive Season into wiki.","The game wiki will now load without any game data."]},{version:"1.2.1",date:"12/14/2021",changes:["Smelter metals can now be reallocated without unassigning.","Increased accuracy of syndicate intel data","Fixed bug with removing Weak & Bad genes when toggling True Path.","Fixed bug with adding or removing Professors not updating indoctrination value.","Fixed bug with Planet Wiki entry that prevented some data from loading.","Added trait rankings to wiki."]},{version:"1.2.0",revision:"a",date:"12/12/2021",changes:["Fixed bug with Plasmid Storage.","Fixed bug with Befuddle trait and Espionage.","Fixed bug with Composting.","Updated Solar Map.","Added setting to enable mobile device support.","Minor buff to TP Frigate power."]},{version:"1.2.0",date:"12/12/2021",changes:["Unlock the True Path (Requires completion of Ascension or Demonic Infusion).","Using Fanaticism to gain an unempowered trait you already possess will now empower that trait.","Added option to Hell Fortress to prevent using ship crew as reinforcements.","Shrine Metal bonus now applies to Mining Droid Aluminium production.","Armored trait now prevents 50% of deaths.","Cannibalize healing now applies a percent based bonus instead of being equivalent to 3 5% Hospitals.","GruvBox Dark is now the default theme.","Added Evolve Adept Perk.","Themed several additional weapon techs in magic universe for immersion.","Smoldering and Chilled effects now display as Smoldering or Chilled in production breakdowns instead of Hot/Cold.","Improved touch device support."]},{version:"1.1.17",date:"11/28/2021",changes:["Job stress from Civilian Ship Crew is now calculated correctly.","Things will now show as unaffordable if they require a locked resource.","Added new entries to Mechanics section of Wiki: Job Stress, Cost Creep, and Warmonger.","Evolve Novice and Evolve Journeyman perk conditions updated."]},{version:"1.1.16",date:"10/30/2021",changes:["Ghost #3 can now be captured with Smoldering.","Ghost #7 can now be captured in Cataclysm mode.","Updated description of Trick or Treat feat.","Llamas will no longer harass carnivores, detritivores, and soul eaters by grazing their fields."]},{version:"1.1.15",date:"10/20/2021",changes:["Added buttons to pause queues.","Cracked Pylons now correctly add to Mana cap.","Pillar of Bones will no longer be rolled with the Smoldering trait.","Fixed bugs with removing Terrifying trait.","Fixed bug with items in queue blocking the next item when it couldn't be completed due to negative production of a resource.","The Tax-Morale governor task is now slightly smarter."]},{version:"1.1.14",revision:"a",date:"9/30/2021",changes:["Fixed Pylon bug with upgraded save games in Magic Cataclysm runs.","Fixed a Message Log filtering problem where some players might not unlock some options."]},{version:"1.1.14",date:"9/29/2021",changes:["New settings options for message log filters.","Added Cracked Pylons for Magic Cataclysm mode.","Conjuring is no longer researchable in Cataclysm mode.","Challenges section added to Wiki under Gameplay.","Smoldering Gnawer will now consume Stone instead of nothing."]},{version:"1.1.13",date:"9/5/2021",changes:["Expanded Mechanics entries in wiki.","Fixed some errors in wiki prestige calculators.","Added a Custom Lab calculator to wiki under species."]},{version:"1.1.12",date:"8/19/2021",changes:["Training Timer for Military tab.","Draggable config options for Spy Operator.","Bug fixes for log and queue windows."]},{version:"1.1.11",date:"8/12/2021",changes:["ARPA projects now contribute to inflation.","Mercenaries costs are now affected by inflation.","Trade is now affected by inflation.","Casino income is now affected by inflation.","Luxury Goods income is now affected by inflation.","Rescaled inflation levels.","Wheelbarrow achievement now requires $250 billion.","Inflation bug fixes.","New message log filters.","Fixed Luxury Goods tooltip money value."]},{version:"1.1.10",date:"8/8/2021",changes:["Added Inflation Challenge Mode. Requires Scrooge achievement to unlock.","Import/Export race feature added to Ascension lab.","Added merge options for queue.","Available space in queue is now shown.","Added Blackhole + Mass Ejector mechanic entry to wiki.","Fixed some display bugs with Alchemy.","Fixed bug where Protoplasm could be required by some structures late in hell phase."]},{version:"1.1.9",date:"7/7/2021",changes:["Firework festival bug fix for cataclysm mode."]},{version:"1.1.8",date:"7/3/2021",changes:["Added firework festival event (July 4th - July 8th).","Added Copper and Iron settings to Mass Ejector Optimizer task.","Current Quantum Level now shown on Citadel Stations.","Updated wiki prestige calculators.","Added a Quantum Level section to wiki."]},{version:"1.1.7",date:"6/29/2021",changes:["Added a Mass Ejector Optimizer governor task.","Fixed precision error with Tech Scavengers.","Prestige calculators added to wiki.","Progress related event section added to wiki.","Anti-plasmids gained from MAD in antimatter universe are now correctly calculated."]},{version:"1.1.6",date:"6/19/2021",changes:["Solstice event is now easier for less seasoned players.","Wharves are no longer affected by the Nomadic trait.","Decreased cost of Iron Horseshoes."]},{version:"1.1.5",date:"6/16/2021",changes:["Support for String Packs.","Separate research queue behavior option.","Balorg can now use the governor tax task."]},{version:"1.1.4",date:"6/11/2021",changes:["Fixed a bug that would sometimes cause mechs to be constructed without weapons.","Fixed a bug that would cause an open tooltip to change descriptions when a queue item completes."]},{version:"1.1.3",date:"6/7/2021",changes:["Improvements to tooltip reliability.","The first Horseshoes can now be constructed out of Lumber if available as a resource.","Horseshoe pacing updated, see Hooved entry in wiki for expanded information."]},{version:"1.1.2",date:"6/6/2021",changes:["Added Money Reserve % config value to Slave replacement task.","Various special buildings are now dropped from the queue if you remove their required trait.","Spy Operator will no longer attempt espionage against controlled cities.","Fixed many issues with labels not updating"]},{version:"1.1.1",date:"6/5/2021",changes:["Unifying during banana republic now triggers an automatic backup save.","Holding a key multiplier with the queue key will now queue mulitple of a building.","Dealmaker import bonus buffed from 40% to 75%.","Nerfed Beast trait to 8% hunting / 15% windy hunting / 10% soldier training.","Restored Cautious trait to Carnivore genus.","Added Money Reserve % config values to Merc and Spy recruiter tasks.","Horseshoes can now be queued.","Adamantite Horseshoes are now much cheaper.","Changed progression system for Horseshoe costs, will not change to next resource unless it's unlocked."]},{version:"1.1.0",date:"6/4/2021",changes:["Appoint a Governor to help run the everyday tasks, unlock in the CRISPR lab.","Animal genus split into 2 new beast genus: Carnivore & Herbivore.","Carnivore Species: Cath, Wolven, Vulpine.","Herbivore Species: Centaur, Rhinotaur, Capybara.","Cath, Wolven, and Centaur redesigned.","Spire Mech Combat rebalanced.","Titan mechs now have 4 weapon slots and an extra equipment slot.","New Equipment: Jump Jet (All but Heavy & Titan), Battery (Heavy Only), and Targeting Computer (Titan Only).","New Scavenger mech type","Reweighted Angelic genus trait costs.","Major event messages are now shown in a different color from minor ones.","Decreased frequency of minor events.","Smoldering no longer applies to a variety of special resources.","Frenzy renamed to Blood Thirst.","Madagascar Tree achievement now requires inheriting Blood Thirst instead of Carnivore.","Expanded Hell section of Wiki"]},{version:"1.0.43",date:"5/18/2021",changes:["Banana Smoothie will no longer unlock for free in alternate universes.","Added a Spire Floor clear timer for previously beaten monsters.","Gate Turrets now correctly contribute to demon kills."]},{version:"1.0.42",date:"5/4/2021",changes:["Minor bug fixes with new events."]},{version:"1.0.41",date:"5/3/2021",changes:["Added launch day event for May 6th.","New minor event system.","The same event can no longer trigger twice in a row."]},{version:"1.0.40",date:"4/11/2021",changes:["Special event race reskins will now persist after event ends until reset.","Added a warning to Unification tech if playing Banana Republic scenario."]},{version:"1.0.39",date:"4/9/2021",changes:["Added challenge win conditions to planet description popover."]},{version:"1.0.38",date:"4/4/2021",changes:["Fixed a bug that prevented some races from acquiring Egg #3."]},{version:"1.0.37",date:"4/3/2021",changes:["Fixed a bug with unlocking the Egg Hunt feat."]},{version:"1.0.36",date:"4/1/2021",changes:["Fool Feat will automatically upgrade to current challenge level for eligible players."]},{version:"1.0.35",date:"3/31/2021",changes:["Changed Blackhole objective of Banana Republic scenerio from stabilize a blackhole to Expand a blackhole to 12 solar mass without exotic matter.","Fixed Terrifying trade exploit in Banana Republic scenerio."]},{version:"1.0.34",date:"3/28/2021",changes:["Added the Banana Republic challenge.","Tax Riots will no longer cause loss of Artifacts, Blood Stones, and other key resources.","Cancel all routes option for trade screen.","Protests no longer apply their penalty twice.","Minor genetic traits can now be reordered by dragging.","Max trade routes per resource type are now governed by Large Trade and Massive Trade upgrades.","Misc minor bug fixes."]},{version:"1.0.33",date:"3/20/2021",changes:["Enhanced threat assessment for Spire.","Added a Save as File option for exporting game state."]},{version:"1.0.32",date:"3/19/2021",changes:["Unemployment Rework.","Fixed reactivity of some tooltips.","Fixed cut off tooltips on settings tab.","Xeno Tourism now requires 10 Monuments and Tourism."]},{version:"1.0.31",date:"3/15/2021",changes:["Alien 1 system is now named after their homeworld.","Alien 2 system is now named after their red planet.","Fixed various cut off tooltips."]},{version:"1.0.30",date:"3/4/2021",changes:["Wharves once again now grant the correct number of trade routes.","Fixed errors with Casino vault size.","Sacrificed Citizens stat for Mantis players.","Factory production can be assigned without first removing it from Alloy production."]},{version:"1.0.29",date:"2/25/2021",changes:["Evolved species will no longer be stuck in the queue after evolution.","Fixed potential viewport scrolling issues with Settings and Evolution tabs.","Added a warning for users running Evolve in multiple tabs.","The game will now remind players to backup their game data once every 100,000 game days."]},{version:"1.0.28",date:"2/21/2021",changes:["Queue can now be used during evolution stage if unlocked with CRISPR tech.","Fixed incorrect Scarletite costs with Wasteful trait.","Graphene Plants now default to Oil with Smoldering.","Fixed many string errors."]},{version:"1.0.27",date:"2/11/2021",changes:["Added Trade Federation achievement.","Added Mastery section to perks page.","Fixed aria label of jobs.","Squished achievement will now unlock from Blackhole or Demonic Infusion."]},{version:"1.0.26",date:"1/30/2021",changes:["Enhanced crafted material popovers.","Universe filters for wiki achievements page.","Cheese Guide."]},{version:"1.0.25",date:"1/23/2021",changes:["Added Piracy section to Wiki under Gameplay-Mechanics.","Numerous minor bug fixes."]},{version:"1.0.24",date:"1/17/2021",changes:["Evil Smoldering races can now research bone tools."]},{version:"1.0.23",date:"1/16/2021",changes:["Redesigned Heat based Genus mechanics.","Untapped Potential formula changed: now has diminishing returns for stacking unspent genes.","Faith now has an effect on auto crafting (Craftsmen Only).","Added new topics to Mechanics section of Wiki.","Minor bug fixes."]},{version:"1.0.22",date:"1/15/2021",changes:["Fixed Cataclysm mode game start."]},{version:"1.0.21",date:"1/10/2021",changes:["Gain upto 8 hours of accelerated time when game is stopped/closed.","Optimized tab content loading for performance.","Pause game feature."]},{version:"1.0.20",date:"12/29/2020",changes:["Fixed issue with keyup event not releasing multiplier keys."]},{version:"1.0.19",date:"12/28/2020",changes:["Studious now improves library knowledge by 10%.","Merchant now increases the amount of resources gained from trading by 10%.","Tracker raised from 10% to 20%.","Resourceful raised from 10% to 12%.","Claws raised from 20% to 25%.","Apex Predator combat bonus raised from 25% to 30%.","Forge Geothermal power boost raised from +1MW to +2MW.","Beast trait now boosts Hunting by 10% or 20% when windy and improves soldier training time by 20%.","Beast gene point cost changed from 2 to 3 points.","Top level tab quick selection key bindings (default 1-7)."]},{version:"1.0.18",date:"12/24/2020",changes:["Fixed issue with species costs on some techs requiring protoplasm without a reload."]},{version:"1.0.17",date:"12/19/2020",changes:["Larger font size modes.","Added descriptions for city sectors.","Last 3 event messages will now be preserved on reload.","Fixed Evolution bugs with Unbound Infusion active.","Improved timer accuracy of stacked queue items when No Queue Order is used."]},{version:"1.0.16",date:"12/16/2020",changes:["Dark Bomb: Kill and Reset the Demon Lord's accumulated strength using the new Dark Bomb.","Bonus Artifacts can now be earned during Demonic Infusion if Spire floor 50 or 100 are cleared.","Renamed the tech upgrade Purify to Enhanced Air Filters in order to prevent confusion with the Blood Infusion Purify."]},{version:"1.0.15",date:"12/12/2020",changes:["Redesigned Inferno Reactor, output is now tied to Infernal Forge.","Steel can once again be discovered by Ambush attacks.","Power Grid is now shown in Cataclysm.","Cataclysm reset no longer incorrectly grants Rapid Mutation or Ancient Ruins.","Many minor bug fixes."]},{version:"1.0.14",date:"12/8/2020",changes:["Vacuum Collapse no longer removes all charges of Corrupted bonus.","Vacuum Collapse now correctly increases Dark Energy earned on the stats page.","Lumber Ritual is no longer displayed to Evil races.","Multiplier keys now work when hiring mercenaries."]},{version:"1.0.13",date:"12/4/2020",changes:["Power Grid now correctly unlocks when gaining Electricity from Infiltrator trait.","Feats Garbage Pie and Finish Line can now be unlocked by Demonic Infusion."]},{version:"1.0.12",date:"12/4/2020",changes:["MechBay tab improvements.","Mechlist can now be reordered by dragging.","Power Grid can now control On/Off state.","Support type structures can now be controlled by the power grid."]},{version:"1.0.11",date:"12/2/2020",changes:["Fixed a memory leak.","Minor adjustments to GruvBox Dark theme.","Cheesy Goodness."]},{version:"1.0.10",date:"12/1/2020",changes:["Ascended buff now persists after Demonic Infusion.","New Themes: GruvBox Light, GruvBox Dark, and Orange Soda."]},{version:"1.0.9",date:"11/29/2020",changes:["Perks separated on to a separate tab under Stats.","Added Perks section to Wiki."]},{version:"1.0.8",date:"11/28/2020",changes:["Base Neutronium cost of Inferno Reactor lowered to 3,750,000.","Fixed Valdi genus traits after evolution.","Prepared rank 2 now correctly applies when building mechs.","Power Grid is now more strict in checking what is available.","Fixed bug that sometimes caused crafting to use a wrong Mastery value."]},{version:"1.0.7",date:"11/25/2020",changes:["Fixed a bug where Technocracy prevented Alien 2 & Chthonian invasions from working."]},{version:"1.0.6",date:"11/24/2020",changes:["Fixed Mechlab quick switch button.","Titan class mech power increased by 12.5%."]},{version:"1.0.5",date:"11/22/2020",changes:["Adjustable Power Grid","Light Theme bug fixes."]},{version:"1.0.4",date:"11/21/2020",changes:["Gains from Alchemy are now higher.","Any mixed fleet can now invade the Alien 2 and Chthonian systems as long as the invasion force is strong enough.","Alien 2 Invasion requires minimum of 400 fleet rating and at least 650 to take no losses.","Chthonian Invasion requires a minimum 1250 fleet rating, 2500 for average losses, and 4500 for minimum losses."]},{version:"1.0.3",date:"11/15/2020",changes:["Fixed compost heap values.","Added combat section to the wiki under gameplay.","Added Equilibrium feat for pillaring every species.","The Misery feat can now be earned from Demonic Infusion."]},{version:"1.0.2",date:"11/10/2020",changes:["Valdi now take your chosen Genus instead of humanoid.","Wrath Blood Infusion now properly applies to all Mech fights.","Artifacts can now be spent properly on the CRISPR tab.","Crystal trade prices adjusted.","Megalith base price reduced from 100k to 55k.","Many minor bug fixes."]},{version:"1.0.1",date:"11/08/2020",changes:["Fixed display bug with CRISPR costs and Technocracy.","Fixed issue with some Windmills not producing power.","The Resort now properly formats its vault size."]},{version:"1.0.0",date:"11/07/2020",changes:["Expanded Interdimensional content, delve deep into the hell dimension.","New Magic Universe.","Fling asteroids into the blackhole with the Asteroid Redirect ARPA project.","The same monument type will no longer be chosen twice in a row.","Evil races can now construct a Pillar of Bones monument type.","Democracy now only affects Entertainers.","Some government bonuses now scale with tech era.","Races with Detritivore can now build Windmills.","Base Aluminium income for plant based species is now roughly 10% higher.","Beast of Burden now grants an extra loot roll instead of a 10% boost.","Revamped combat loot formulas.","Build queue resource highlighting.","Low Contrast Dark Night Theme.","Ewnay igpay atinlay anguagelay."]},{version:"0.9.24",date:"11/1/2020",changes:["Holiday icons from feats earned with no stars can now be accessed.","Challenge feat icons still require at least 1 star."]},{version:"0.9.23",date:"10/30/2020",changes:["New settings option for people who hate fun.","Added ability for an obscure combination of settings and racial traits to get Ghost #3"]},{version:"0.9.22",date:"10/28/2020",changes:["Halloween cosmetic effects will now run for the duration of the Trick or Treat event instead of just on Halloween.","Ents, Dryads, and Salamanders can now find all the Ghosts.","A certain Ghost is now easier to obtain in Cataclysm.","Accessibility improvements for the event."]},{version:"0.9.21",date:"10/27/2020",changes:["Trick or Treat Event, runs from 10/28 - 11/4."]},{version:"0.9.20",date:"10/16/2020",changes:["Fixed bug with the holy trait that improperly applied its bonus."]},{version:"0.9.19",date:"9/1/2020",changes:["Swarm Control AI now provides a base increase of +2 before unlocking Quantum Computing.","Fixed bugs with manual crafting popover.","Fixed bug that stopped DNA & RNA generation during evolution if the Cataclysm scenario was toggled on."]},{version:"0.9.18",date:"8/28/2020",changes:["ARPA Queue timer fixes.","Swarm Control AI upgrade now make Control Stations scale with Quantum level."]},{version:"0.9.17",date:"8/22/2020",changes:["Fixed bug that prevented Cataclysm Ascension from completing.","Rank 1 sacrifice is slightly less effective","Rank 3 sacrifice is significantly more effective","New Research is now shown by Era."]},{version:"0.9.16",date:"8/12/2020",changes:["Bug Fixes by Beorseder:","Fixed issue where Exotic Materials Lab and Fortifications would clear current queue.","Fixed Scavengers not working during Cataclysm.","Fixed display bug with Galactic Exchange during Cataclysm.","Genomic Mutations no longer give the wrong number of Genes without Synthesis upgrades.","Genomic Mutations now tell how many Plasmids/Antiplasmids are gained from them.","Techs now display their requirements on the wiki."]},{version:"0.9.15",date:"8/10/2020",changes:["Tax revolts can no longer destroy Soul Gems.","If you lose your sample of Elerium before researching Elerium Mining it will now be replaced."]},{version:"0.9.14",date:"8/9/2020",changes:["Angelic races now have an innate bonus vs demonic creatures.","Enhanced Muscle Fibers added to perks page.","Genome sequencing will now be off by default in Cataclysm.","Reorganized achievements page in Wiki."]},{version:"0.9.13",date:"8/6/2020",changes:["Special resource descriptions now update."]},{version:"0.9.12",date:"8/3/2020",changes:["Added Crossed the Finish Line feat for Ascending with Cataclysm.","Adjusted many post World Collider Cataclysm things that referenced none existent planetary structures.","Added a fix for Stabilize Blackhole being stuck in an untriggerable state.","Upgrading achievements will now send a notification."]},{version:"0.9.11",date:"8/1/2020",changes:["Fixed a bug that caused Factories to charge the wrong amount of Polymer for producing Synthetic Furs."]},{version:"0.9.10",date:"7/30/2020",changes:["Expanded list of potential enemy city names.","Added Synthetic Fur option to Factories.","Restoring a backup after a Cataclysm will now allow you to Cataclysm again.","Fixed Lumber penalty on Desert worlds.","Many minor bug fixes."]},{version:"0.9.9",date:"7/21/2020",changes:["Added Devotion upgrade to ancients CRISPR line between Faith and Acolyte. The total cost is the same, it's just spread out more.","Players with Ancients 4 are granted Ancients 5 automatically, those with Ancients 3 are refunded 300 Plasmids.","Added Enhanced Muscle Fiber CRISPR upgrade.","High tax morale penalty under Oligarchy is now reduced.","Fixed bugs with Blackhole reset and restoring backups.","Fixed bug with adjusting taxes as a Noble race that would set it to the max."]},{version:"0.9.8",date:"7/18/2020",changes:["Czech translation by Mousesama","The slaves have staged a successful hunger strike to demand better living conditions, as a result slave pens can now only hold 4 slaves each.","Autocracy and Frenzy no longer block Immoral races from gaining a Warmonger bonus.","Geology traits now display under planet information.","Popovers added to building and research queues."]},{version:"0.9.7",date:"7/13/2020",changes:["Seasons no longer exist in Cataclysm mode.","It is no longer Sunny in Cataclysm mode.","Parasites are no longer unable to grow population in Cataclysm mode, but they do take a growth penalty.","Base Sawmill effect is now separated from lumberjack in production breakdown."]},{version:"0.9.6",date:"7/10/2020",changes:["Fixed bug with Infiltrator not unlocking Nanoweave.","Fixed bug with Railways not adding traderoutes correctly in Cataclysm mode."]},{version:"0.9.5",date:"7/6/2020",changes:["Fixed a bug that occurred when combining the Terrifying trait with the gold star Iron Will perk."]},{version:"0.9.4",date:"7/3/2020",changes:["Failed History perk raised from +1 Geothermal to +2 Geothermal energy.","Fixed Oligarchy tax riot immunity between 36%-45%.","Infiltrator can now steal Graphene Processing, Nanoweave, and Orichalcum Analysis techs."]},{version:"0.9.3",date:"7/1/2020",changes:["Increased base number of Plasmids earned in Cataclysm mode."]},{version:"0.9.2",date:"6/30/2020",changes:["Added Restore Backup option, restores game to just before your last prestige reset.","Extended Recombination CRISPR line.","When gaining a random minor trait from Fanaticism, you will now gain 5 ranks of it."]},{version:"0.9.1",date:"6/21/2020",changes:["Fixed Dyson Net."]},{version:"0.9.0",date:"6/21/2020",changes:["Added Scenarios Section to Evolution Challenges.","Added Cataclysm Scenario for those who value science over caution.","Genetic Dead End is now classified as a Scenario.","Plant genus redesign. Photosynth trait replaced with Sappy.","Added 3rd race option for Plant genus: Pinguicula.","Dyson Net now provides partial power as it is constructed.","Added Orichalcum upgrade for Dyson Sphere.","Added Xeno Tourism upgrade.","Added Fertility Clinic upgrade for Hospitals.","Added OTB, Online Gambling, & Bolognium Vault upgrade for Casinos.","Added Scrooge achievement.","Added Soul Link upgrade for Soul Forge/Soul Attractors.","Reduced Bolognium cost of Freighters & Corvette Ships.","Increased rating of Corvette Ships to 30.","Piracy will no longer start until after you construct the Embassy.","Reduced power requirement of Soul Forge and Soul Attractor.","Gun Emplacements and Soul Attractors are now more potent.","Reduced requirement of Demon Slayer feat to 666 Million demon kills."]},{version:"0.8.17",date:"5/30/2020",changes:["Added 3rd race option for Fungus genus: Moldling.","Fungi genus Spore trait replaced with Detritivore.","Casinos now start powered and generated money immediately.","Extreme Dazzle upgrade now boosts Casino income by 50%.","Reduced power requirement of Casino by 1.","Casino Max Morale boost no longer works unless casino is powered.","Occupation will now unlock Federation research.","Added Double Density achievement in heavyverse.","Stoned penalty on mellow planets raised to 10%.","Unemployed citizens on mellow planets no longer generate any stress (note: hunters are NOT unemployed).","Life on mellow planets is now overall less stressful.","Slaver trait rating raised to 12.","Barracks can now be switched off.","Space Stations will now automatically staff Space Miners from the default job when constructed.","Factories now default to producing Alloy instead of Nothing."]},{version:"0.8.16",date:"5/8/2020",changes:["Oceanic biome now applies a 6% bonus to Titanium from Steel smelting.","Oceanic biome now applies a 12% bonus to Titanium from Iron smelting.","Oceanic biome now applies a 5% penalty to Fur generation.","Tundra biome now applies a 25% bonus to Fur generation.","Tundra biome now applies a 10% penalty to Oil generation.","New planetary modifiers: Elliptical, Flare, Dense, and Unstable.","Oligarchy tax riot immunity raised from 35% to 45%."]},{version:"0.8.15",date:"5/2/2020",changes:["Grassland biome Food bonus raised to 20%.","Forest biome Lumber bonus raised to 15%.","Desert biome now applies a 25% Lumber penalty.","Desert biome now gives a 20% stone bonus and a 10% Oil bonus.","Volcanic biome now applies a 10% Food penalty.","Volcanic biome now gives an 8% Iron and 12% Copper bonus.","Added partial Korean translation.","Achievements in the wiki are now sorted Alphabetically.","Some achievements now show completion progress in the wiki."]},{version:"0.8.14",date:"4/30/2020",changes:["Post unification Federation now gives a 32% bonus (raised from 30%).","Federation now increases morale by 10%.","Socialist factory bonus is now 10% (raised from 5%).","Socialist crafting bonus is now 35% (raised from 25%).","Corpocracy factory bonus is now 30% (raised from 20%).","Corpocracy factory bonus now applies to Cement, Graphene, and Vitreloy.","Republic now increases morale by 20%.","Oligarchy tax revenue penalty is now 5% (lowered from 10%).","Oligarchy can now set taxes 20% higher then other governments (raised from 10%).","Technocracy now adds a 10% Knowledge gain bonus.","Autocracy governments are now immune to the warmonger penalty.","Priests now apply a bonus to Ziggurats under Theocracy.","Fixed display of Theocracy effect on temples. This gives a 12% bonus but was only displaying as a 5% increase.","Noble Oligarchy can now set their taxes as high as 40%."]},{version:"0.8.13",date:"4/29/2020",changes:["New research is now sorted by knowledge cost.","Added popover descriptions for prestige resources.","Harmony Crystals now boost standard Dark Energy by 0.1% instead of 0.01%.","Lots of minor bug fixes."]},{version:"0.8.12",date:"4/24/2020",changes:["Farming has been redesigned. Farms no longer directly generate food, Farmers now generate food in combination with Farms.","Added Energizer Feat for ascending without building any Thermal Collectors.","Bad traits no longer count for Ascension Species Creator complexity.","Dreaded Achievement will now unlock if you never researched dreadnoughts.","Fixed issue with some feats spamming the log due to micro achievements.","Fixed base training rate of soldiers.","Fixed bug with diverse trait that made it do the opposite of what it was suppose to do.",'Adjusted color of "purple" text on Night theme.',"Kilowatts are now Megawatts."]},{version:"0.8.11",date:"4/16/2020",changes:["Ascension reset no longer offers planet choices, instead your next race is created on the old planet with bonuses added to that planet.","Ascended planets now gain +2% to all geology deposits, +5% production, +10% storage, and +2 Sundial base Knowledge gain.","Unspent gene points in the Ascension Lab will be converted into Untapped Potential.","Ascension lab now has a complexity gene tax for adding more then 4 traits.","Technophobe perk now applies an additional bonus to custom race complexity.","Paranoid and Hoarder can now be combined.","Over capped slaves will now be released."]},{version:"0.8.10",date:"4/13/2020",changes:["Added EM (Electromagnetic) Field Challenge."]},{version:"0.8.9",date:"4/12/2020",changes:["Added a Feat for finding all the Eggs.","Current egg count can now be checked in the Wiki."]},{version:"0.8.8",date:"4/12/2020",changes:["Easter Event Activated","Event ends 10 days after the start of Easter."]},{version:"0.8.7",date:"4/11/2020",changes:["Fixed Pathetic trait."]},{version:"0.8.6",date:"4/11/2020",changes:["Fixed Brute trait.","Added section for Achievements and Feats to Wiki."]},{version:"0.8.5",date:"4/11/2020",changes:["Added New Work in Progress Game Wiki","Sentience is now more likely to grant a species where the extinction achievement has not yet been earned.","Sentience can now include custom races.","Incorporeal Existence research now costs Phage instead of Plasmids.","Ascension research now Plasmids instead of Phage.","The change log is now part of the Wiki."]},{version:"0.8.4",date:"4/4/2020",changes:["Fixed breaking bug with Rigid trait."]},{version:"0.8.3",date:"4/3/2020",changes:["Federation now reduces the soldier requirement of occupied cities by 5.","Fixed incorrect Industrious string."]},{version:"0.8.2",date:"3/30/2020",changes:["Piracy in the Gateway and Stargate regions ramp up more slowly as you explore Andromeda.","Fixed formatting of multiline Crafting Tooltip cost display.","Fixed incorrect string used by completed Dyson Sphere."]},{version:"0.8.1",date:"3/29/2020",changes:["Piracy now slowly takes effect in the Gateway System and Stargate region over 1000 days after piracy begins.","Purchasing Negotiator and levels of Persuasive will now update the regular Market as well as the Galactic Market.","Added new CRISPR upgrade effects from the Challenge, Ancients, and Trader trees to the perks list.","Queued Monuments will update their name in the queue when a Monument is constructed.","Fixed bug where ARPA projects at the end of the Queue while No Queue Order was active would cause No Queue Order to not work as intended.","The name of the trait gained from a Mutation in the message is now localized.","Adding Apex Predator will remove currently obtained Armor techs.",'Annexed/Purchased powers will now have a respective " - Annexed"/" - Purchased" tag next to their name, like Occupied powers do.',"Blackhole reset gives its proper reward again.","The amount of Gene/Phage levels of Minor Traits purchased is now affected by Multiplier Keys.","The amount of Ships moved from one area to another is now affected by Multiplier Keys.","Manual Crafting button tooltips are more informational.","Constructing the first Foundry of a game will log a message briefly explaining what Crafted Resources are and the ways to make them.","Informative messages (mission results, messages that explain newly unlocked mechanics, the Launch Facility message that informs the player of the space tab, etc.) are now displayed in blue, to separate them from less important messages.","Added the missing Wormhole Mission result string."]},{version:"0.8.0",date:"3/27/2020",changes:["Intergalactic Content.","Universe Mastery Rework.","-Each Universe now tracks its own mastery level responsible for 40% of the mastery bonus, the remaining 60% comes from the general mastery level.","-Standard Universe mastery rules remains unchanged.","Micro icons can now be earned for none Micro achievements. These will not count for standard mastery, only Micro mastery.","Unification 3.0, the unification system has been reworked.","Federation Government type.","New Faith CRISPR line of upgrades, unlocks priest job.","Universal, Standard and Mastered CRISPR Upgrades, for masters of the universes.","Added Negotiator CRISPR upgrade.","Added Persuasive Minor Gene.","Extended the Deify and Study Ancients tech trees.","Enhanced Droids upgrade for War Droids.","Repair Droids for Fortress.","Smoldering and Chilled now have reduced effectiveness after 100 stacks.","Removed Heavy Genus Feats, these were redundant with Universe Icons.","Blackhole reset now also grants species level extinction achievement.","Power cost of Mass Ejector increased to 3kW.","Genetics lab custom mutation costs rescaled to static values depending on the genetic trait.","Colonists will now be automatically assigned when a Living Quarter is completed if the default job has any available citizens.","Biodome redesigned, produces less food but increases living quarter capacity for Citizens.","More robust research categories.","Various racial traits now apply to ARPA projects.","Human Creative trait rescaled.","Large cost creep penalty reduced to 0.005 from 0.01.","Strong gathering bonus increased from 2 to 5.","Compact lowered from -0.02 to -0.015."]},{version:"0.7.28",date:"3/16/2020",changes:["Antimatter Universe now gives a 10% prestige bonus post MAD.","St. Patrick's Day event.","Blood War can no longer be earned by none demonic evil races.","Build Crate/Container buttons now update create/container values when upgraded by research."]},{version:"0.7.27",date:"3/10/2020",changes:["Memory leak fixes."]},{version:"0.7.26",date:"3/5/2020",changes:["Any race where the associated extinction achievement has been unlocked is now always available during evolution.","Joyless perk changed to +2% Max Morale per star level.","The effects of the Mass Extinction and Creator perks have been swapped.","Creator perk (old mass extinction) changed to 1.5x / 2x / 2.5x / 3x / 3.5x genes gained on mutation.","Minor traits bought with Phage now count twice when you complete evolution."]},{version:"0.7.25",date:"2/26/2020",changes:["Unicorn Shrine bonus is now determined by the moon phase when constructed.","Shrine Knowledge bonus now applies an additional affect to universities.","Smelters in Evil universe when using Kindling Kindred default to Flesh instead of Coal.","Evil Wendigo Smelters correctly display that they use 1 Flesh/s instead of 3 Souls/s. Also fixed the bug where they end up using 3 Flesh/s instead of 1.","Fixed bug where the Evil Wendigo Reclaimer description would show the Lumberjack description.","If Containers have not yet been unlocked as a resource, getting a Wharf will unlock it.","Fixed bug where, if Freight Trains was gotten after ARPA, the Railway project would need a refresh to appear."]},{version:"0.7.24",date:"2/12/2020",changes:["Special Prestige icons awarded to players from certain feats can now be set to replace the standard Star icon."]},{version:"0.7.23",date:"2/11/2020",changes:["Steelen Challenge now requires Bioseed as its win condition.","Added Feat for Blackhole reset with Steelen Challenge.","Added V-Day Event stuff."]},{version:"0.7.22",date:"2/9/2020",changes:["Steelen Challenge.","Graveyards are now removed upon gaining Kindling Kindred.","If Default job is set to Farmer/Lumberjack for Carnivore/Kindling Kindred, it will be changed to Unemployed upon adding those traits.","Fixed bug where gaining Carnivore and having no Grain Mills would make Smokehouses unpurchasable until refresh.","Cargo Yard now requires the construction of a Transfer Station to be unlocked.","Mitosis/Metaphase effect now appears on perks list."]},{version:"0.7.21",date:"1/28/2020",changes:["More bug fixes."]},{version:"0.7.20",date:"1/20/2020",changes:["Bug Fixes by Beorseder.","Fixed bug where purchasing Multicellular would double DNA generation from Nuclei instead of Bilateral Symmetry/Poikilohydric/Spores.","New population from the Infectious trait now go into the set Default job, instead of always Unemployed.","Controlled Mutation will no longer offer conflicting traits."]},{version:"0.7.19",date:"1/14/2020",changes:["Bug Fixes."]},{version:"0.7.18",date:"1/12/2020",changes:["Theocracy temple bonus raised from 5% to 12%.","Technocracy knowledge discount raised from 5% to 8%.","Corpocracy Casino Bonus raised from +100% to +200%.","Corpocracy Luxury Good Bonus raised from +50% to +150%.","Corpocracy Tourism Bonus raised from +50% to +100%.","Corpocracy morale penalty lowered from -15% to -10%.","Corpocracy Manufacturing Bonus raised from +15% to +20%.","Miner's Dream now scales the information that is revealed depending on the star level of the achievement.","Slaves now appear as a resource.","Alternate universes now award icons for complex achievements."]},{version:"0.7.17",date:"1/9/2020",changes:["Fixed an issue with displaying foreign powers in civics tab on unlock."]},{version:"0.7.16",date:"1/8/2020",changes:["Exploration Missions can be queued again.","The game will now notify the user if the current version is out of date.","Changes by Beorseder.","Geology deposit aesthetic changes on planet selection.","Miner's Dream Achievement & Perk."]},{version:"0.7.15",date:"1/7/2020",changes:["Queueing the World Collider will no longer lag the game.","Multi-segment projects will now have extra segments cleared from the queue on completion.","Spy and Government related popovers that would sometimes get stuck open will now clear.","Queued projects that will not complete due to lack of production will now display a green [Never] instead of -1 second timer.","Multi-segment projects no longer block queueing ARPA projects unless they consumed the entire queue space."]},{version:"0.7.14",date:"12/31/2019",changes:["Research Categorization option by Naryl."]},{version:"0.7.13",date:"12/30/2019",changes:["Gene decay will no longer result in a negative plasmid count.","Gene fortification is slightly more effective."]},{version:"0.7.12",date:"12/19/2019",changes:["Gene Fortification.","Fixed Cultural Supremacy popover."]},{version:"0.7.11",date:"12/15/2019",changes:["Decaying resources will now use a warning color if you are losing that resource but at a slower rate then the decay rate.","The most bottlenecked resource will now display in red while other trouble resources will be marked with an alert color.","CRISPR upgrades are now darkened when unaffordable.","Transfer Station now lists its uranium storage.","Wendigo bug fixes."]},{version:"0.7.10",date:"12/12/2019",changes:["Craftsman now continuously output product instead of once/twice a month.","Cumulative achievements now check for lower tier unlocks."]},{version:"0.7.9",date:"12/7/2019",changes:["Many bug fixes."]},{version:"0.7.8",date:"12/6/2019",changes:["The default job can now be set to: Unemployed, Farmer, Lumberjack, Quarry Worker, or Scavenger.","New line of feats for achievement hunting.","Novice Perk.","Journeyman Perk."]},{version:"0.7.7",date:"12/5/2019",changes:["Super projects now queue in larger batches.","Super projects now only report completion by the queue if actually complete instead of for each segment constructed."]},{version:"0.7.6",date:"12/2/2019",changes:["Adjacent queue items of the same type will now combine.","Architect now doubles queue sizes instead of adding a flat +2.","Misc minor bug fixes."]},{version:"0.7.5",date:"11/28/2019",changes:["Queueing 2x or more of the same building in a row will now stack them in the queue.","Queue timer now adjusts for cost creep.","ARPA Projects can now be queued.","Fixed a bug that could break the game when Yeti or Wendigo unlocked the genetics lab."]},{version:"0.7.4",date:"11/27/2019",changes:["Wendigo can now build hunting lodges.","Trade route prices are now tracked to 1 decimal.","Elusive spies will no longer be killed when they fail a mission.","Disruptor Rifles now require researching Quantum Entanglement."]},{version:"0.7.3",date:"11/26/2019",changes:["Night Theme trade volume control made more night theme friendly.","Contrast improvements for Night and R/G Theme."]},{version:"0.7.2",date:"11/24/2019",changes:["New market buy/sell volume control.","Large Trade upgrade now raises the buy/sell cap to 5,000.","Massive Trades upgrade now raises the buy/sell cap to 1,000,000.","Various bug fixes by Beorseder."]},{version:"0.7.1",date:"11/23/2019",changes:["Garrison controls reintegrated into government section.","Mutation plasmids now track correctly in no plasmid challenge runs.","Fixed many issues with foreign power name generation.","Feat star icon is no longer tiny."]},{version:"0.7.0",date:"11/21/2019",changes:["Establish a Government.","Battle rival cities.","Biome races added for Forest, Desert, Tundra, and Volcanic.","New ARPA Project: Railway.","New CRISPR upgrades: Mitosis & Metaphase.","Construct advanced AI stations in deep space.","Rapid Gene Sequencing upgrade.","Civics tab split into Government, Industry, and Military sections.","Inspiration no longer adds an upfront knowledge bonus.","Vigilante requirement lowered to 12.","Xenophobic replaced with Wasteful.","Added Rocky Road Feat.","Configurable number notations."]},{version:"0.6.27",date:"11/12/2019",changes:["Tundra planets are now always cold in winter.","Volcanic planets are now always hot in summer.","Stormy planets are now more likely to be windy.","Fixed issue with last rites not showing up as affordable.","2-4x Challenge Multipliers changed:.","2 Challenges: +12% Prestige.","3 Challenges: +25% Prestige.","4 Challenges: +45% Prestige.","Heavy Universe prestige bonus now scales with challenge level:.","0 Challenges: +5% Prestige.","1 Challenge: +10% Prestige.","2 Challenges: +15% Prestige.","3 Challenges: +20% Prestige.","4 Challenges: +25% Prestige."]},{version:"0.6.26",date:"11/7/2019",changes:["ARPA costs now update without mousing off and back on the buttons.","Fixed issues with incorrectly powering on newly built structures.","None-demonic evil smelters now correctly state they burn 1 flesh/s.","Added whitehole perk to stats page."]},{version:"0.6.25",date:"11/2/2019",changes:["Geology bonus is now preserved on MAD reset.","Key Mappings are now configurable for multiplier and queue keys."]},{version:"0.6.24",date:"10/31/2019",changes:["The Halloween feat will now unlock inside a micro universe."]},{version:"0.6.23",date:"10/28/2019",changes:["Exotic mass now counts towards Galactic Landfill and Supermassive.","Fixed issues with queue timers and kindling kindred trait.","Dark Energy now applies to windmills in antimatter universe."]},{version:"0.6.22",date:"10/26/2019",changes:["Game optimizations.","Bug fixes for queues.","Fixed bug with war droids."]},{version:"0.6.21",date:"10/24/2019",changes:["Freight Train upgrade now adds a trade route to freight yards instead of trade posts.","Toxic troll achievement.","Spatial reasoning rounding fix."]},{version:"0.6.20",date:"10/21/2019",changes:["Fixed application of plasmids with antiplasmids.","Updated description of bleeding effect.","Added achievement for synthesizing an anti-plasmid.","More readable achievement page."]},{version:"0.6.19",date:"10/20/2019",changes:["Fixed power errors with hell dimension turrets.","Crate/Container rounding is now applied after spatial reasoning.","Added extra text to the asteroid belt description to call out the necessity of assigning space miners.","Evil Ents can now burn flesh in the smelter."]},{version:"0.6.18",date:"10/16/2019",changes:["Swarm Satellite redesign.","Swarm Satellites cost and output decreased.","Control Stations can now control 10/18 swarm satellites.","Iron mining ship swarm plant discount now applies to all swarm plant costs.","New upgrades to increase output of swarm satellites."]},{version:"0.6.17",date:"10/14/2019",changes:['"Q" key now works with research queue.',"Added settings option to not enforce queue order.","Decay challenge no longer shows the star level for Joyless.","All universe types can now be seen on achievements.","Genus completion is now marked on sentience.","Challenges can now be toggled during evolution.","Inspiration event now gives a temporary buff to all science production.","Added Slave Market for slaver races to buy slaves as an alternative to catching them.","Added Crate/Container storage amount to the build crate/container tooltip.","Added a button to cancel all trade routes for each resource."]},{version:"0.6.16",date:"10/13/2019",changes:["Employment is now color coded depending on staffing levels.","GPS satellites now add additional trade routes.","Added stats tracking on reset mechanics used.","Added a message when completing the launch facility.","Added icons to challenges and races in evolution stage to indicate level of challenge completion."]},{version:"0.6.15",date:"10/11/2019",changes:["Added a settings option to disable the queue hot key.","The queue hot key is now disabled by default because it breaks the game for some users."]},{version:"0.6.14",date:"10/9/2019",changes:["Fixed several bugs with celestial races.","Only one demonic invasion event is now required to reach a hellscape planet.","New city categorization can now be switched off in the settings tab.","Holding Q while clicking a building will now queue it instead of constructing it."]},{version:"0.6.13",date:"10/7/2019",changes:["Fixed bioseed reset bug when seeding from a planet without a special property."]},{version:"0.6.12",date:"10/6/2019",changes:["Added a hire merc option to fortress, mercs hired here go directly to the fortress.","Default patrol size is now 10 instead of 4.","Adjusted margins in city tab/space tabs to slightly reduce vertical scrolling.","New Tower of Babel flair."]},{version:"0.6.11",date:"10/5/2019",changes:["New planetary modifiers: Toxic, Mellow, Rage, Stormy, Ozone, Magnetic, and Trashed.","City Categorization by NotOats.","Chinese Translation."]},{version:"0.6.10",date:"10/1/2019",changes:["Fixed issue with gene editing costing the wrong type of Plasmid.","Fixed Bone label in Graphene plant.","Fixed issue with Plywood not unlocking when removing Kindling Kindred trait."]},{version:"0.6.9",date:"9/30/2019",changes:["Antimatter Universe.","Bleeding Effect line of CRISPR upgrades, requires Anti-Plasmids to unlock.","Balorg can now unlock queues.","Fixed aria labels in mass ejector."]},{version:"0.6.8",date:"9/24/2019",changes:["Queue reordering no longer swaps the dragged item with the one in the target spot.","Added timers to research queue.","Cost adjustments are now applied to queue timers increasing their accuracy."]},{version:"0.6.7",date:"9/24/2019",changes:["Cath windmills now generate power instead of just looking pretty.","Fixed Spanish strings file, language now loads again."]},{version:"0.6.6",date:"9/23/2019",changes:["Added special tech tree to sacrificial altar to boost its effectiveness per sacrifice.","Restored windmills to cath.","Challenge Multiplier Dark Energy rounding calculation fixed.","Added extra information to blackhole description when it reaches destabilization point.","Added a warning to stabilize option that it will reset your exotic matter."]},{version:"0.6.5",date:"9/21/2019",changes:["Fixed display issue with frenzy appearing to never drop below 1%.","Updated the tooltip values on farms and farmers to include the hellscape penalty.","Fixed Evil Ents so they start with Gather Stone option."]},{version:"0.6.4",date:"9/19/2019",changes:["Fixed double windmill issue with evil universe races.","Spanish language updates.","Added warnings to challenge modes in micro universe that you will not receive credit."]},{version:"0.6.3",date:"9/17/2019",changes:["Restored broken perks."]},{version:"0.6.2",date:"9/17/2019",changes:["Bug Fixes."]},{version:"0.6.1",date:"9/17/2019",changes:["Universe Update, explore ~~ 4 ~~ 3 new universe types:.","Heavy Gravity Universe.","Micro Universe.","Evil Universe.","New Decay Challenge.","Antimatter universe is still forming, coming soon.","Dark Energy effects added, unique per universe type.","New Plasmid scaling formula.","Blackhole mass added to Stellar Engine.","Stuff I probably forgot about."]},{version:"0.5.18",date:"9/11/2019",changes:["Spanish translation provided by RanaPeluda.","Fixed Ent fanaticism.","Modals are no longer unnecessarily wide.","Smelter modal now shows the fuel production for each type."]},{version:"0.5.17",date:"9/5/2019",changes:["Mantis Frail trait replaced with new Cannibalize trait, eat your own citizens for buffs.","The Fortress will now remember the number of troops assigned to it and attempt to keep it at that level."]},{version:"0.5.16",date:"9/3/2019",changes:["Made some adjustments to Soul Gem drop odds.","Added a message when you discover your first Soul Gem."]},{version:"0.5.15",date:"9/1/2019",changes:["Portuguese translations updated by Rodrigodd."]},{version:"0.5.14",date:"9/1/2019",changes:["Buildings will no longer be added to the queue if holding down a multiplier key.","Fixed a problem with smelters that could cause their production to become stuck in a high state.","Fixed initial display state of containers in storage management tab."]},{version:"0.5.13",date:"8/30/2019",changes:["New layout for selecting challenge genes/modes during end of evolution stage.","Fixed bug with low support elerium miners that caused them to miscalculate miner outputs.","Added a threat level warning to fortress."]},{version:"0.5.12",date:"8/30/2019",changes:["Pacifist Achievement is now unlocked by unifying without ever initiating an attack."]},{version:"0.5.11",date:"8/28/2019",changes:["Fixed issue with nucleus DNA bonus not applying from correct cell stage evolutions.","Building timers now count down without refreshing the popover.","Long action titles will now wrap instead of overflowing the button.","Fixed a bug that could cause the research queue to clear items from the building queue."]},{version:"0.5.10",date:"8/28/2019",changes:["Fixed bug with some construction projects not refreshing the page after being built with the queue.","Space exploration missions can no longer be queued more then once at a time.","One off projects are now removed from the queue if completed manually.","Queue timers now track crafted resources.","Demonic attractor soul gem drop rate increase buffed from 5% to 8%.","Updated some fortress related tooltips.","Mousing over the star rating in the top left corner now lists which challenges are active.","Time until ready added to unaffordable actions."]},{version:"0.5.9",date:"8/27/2019",changes:["Active build queues wiped due do internal game breaking format change."]},{version:"0.5.8",date:"8/27/2019",changes:["Construction timers added to build queue.","Construction and research completed by queues are now logged to the message list.","Improved drag and drop support for queues."]},{version:"0.5.7",date:"8/25/2019",changes:["Drag support for queue sorting.","Fixed resource display bug that occurred when buying a mass ejector.","Minor traits now show the number of ranks from phage or genes spent."]},{version:"0.5.6",date:"8/23/2019",changes:["Building queue now works in space.","Added a separate research queue.","Fixed rock quarry awarding 4% stone bonus instead of the stated 2%.","Fixed rendering bugs with the blackhole and mass ejector."]},{version:"0.5.5",date:"8/22/2019",changes:["Bug Fixes for queueing system."]},{version:"0.5.4",date:"8/22/2019",changes:["Building Queue system v1.0.","Urban Planning, Zoning Permits, and Urbanization queue related techs.","New CRISPR upgrades for enhanced queueing."]},{version:"0.5.3",date:"8/20/2019",changes:["Stats and Achievements separated into separate sub tabs.","Disruptor rifle upgrade for soldiers.","Mass Ejector can no longer be unlocked before completing the Stellar Engine."]},{version:"0.5.2",date:"8/20/2019",changes:["Fixed misnamed mantis trait key.","Fixed Iron smelter paying out 10x intended amount."]},{version:"0.5.1",date:"8/20/2019",changes:["Disappearing craftsman fix."]},{version:"0.5.0",date:"8/19/2019",changes:["Interstellar space is now unlockable.","Interdimensional travel is now unlockable.","New management tab for Crates & Containers.","Power generation breakdown.","Improved resource breakdown layout.","Leathery trait buffed.","Chameleon trait now adds a combat rating bonus.","Optimistic now also applies to the minimum morale rating.","Smarter Smelter fuel switching.","New CRISPR unlocks."]},{version:"0.4.42",date:"8/16/2019",changes:["Fixed some screen reader issues with the crate modal launch button.","Added a warning to the Genetic Dead End challenge if you are on a hellscape planet."]},{version:"0.4.41",date:"8/15/2019",changes:["Joyless Challenge.","??? - Nothing to see here, move along."]},{version:"0.4.40",date:"8/9/2019",changes:["Changed No Crispr gene into the Weak Crispr gene."]},{version:"0.4.39",date:"8/6/2019",changes:["Genetic Disaster Challenge."]},{version:"0.4.38",date:"8/5/2019",changes:["Special action icon is now properly flagged as a button."]},{version:"0.4.37",date:"7/31/2019",changes:["ARIA Improvements for Factory and A.R.P.A."]},{version:"0.4.36",date:"7/27/2019",changes:["Slow and Hyper traits can now combine.","Added new achievements: Creator & Explorer.","Added perks for Mass Extinction, Creator, and Explorer."]},{version:"0.4.35",date:"7/25/2019",changes:["Centaur can now pick Fanaticism.","Challenge multiplier is now applied to phage gain."]},{version:"0.4.34",date:"7/23/2019",changes:["Fixed SR descriptions of buildings that lack affordability.","Fixed resource highlighting of buildings that have zero costs."]},{version:"0.4.33",date:"7/23/2019",changes:["Fixes for Ent Fanaticism not releasing some resources.","Aria improvements for the smelter modal.","Improved screen reader resource affordability description of buildings/research.","Resource highlighting on structures."]},{version:"0.4.32",date:"7/21/2019",changes:["Balorg slaver trait added.","Ziggurat bonus now applies to the oil extractor.","Geology Oil rich/poor no longer applies to oil extractor.","Added resource alternate row coloring.","Added an affordability hint for screen readers.","Fixed some bugs with awarding a random minor trait from fanaticism.","Dimensional Compression now charges the correct cost."]},{version:"0.4.31",date:"7/20/2019",changes:["Extreme Dazzle casino upgrade.","Metallurgist minor trait, buffs alloy.","Gambler minor trait, buffs casinos.","A.R.P.A. projects now use resource approximations for large numbers.","Cement Factory renamed to Cement Plant to reduce confusion with the regular Factory.","Key multipliers now work inside the factory modal.","Imps and Balorg now have access to advanced crafting tech.","Imps and Balorg now have access to windmills.","Balorg can now set their taxes below 10% and above 30%."]},{version:"0.4.30",date:"7/19/2019",changes:["Portuguese translation by Rodrigodd.","DNA Sequencer upgrade.","Gene Assembly cost increase to 200k.","Synthesis now applies a bonus to auto crafted genes.","Ambidextrous buffed.","Ambidextrous now has a greater effect on auto crafting."]},{version:"0.4.29",date:"7/18/2019",changes:["Genetic modification system, customize your race with minor traits.","Shotgun Sequencing upgrade for genome research.","Randomly gained minor traits will no longer stack unless they have all been unlocked.","Genes are now gained from random mutations.","Synthesis line of CRISPR upgrades.","Satellite and Observatory cost reductions.","Fibroblast minor trait.","Iridium is now unlocked by constructing an iridium mine instead of the moon base.","Helium-3 is now unlocked by constructing a helium-3 mine instead of the moon base.","Genome sequencing now defaults to on when first unlocked."]},{version:"0.4.28",date:"7/16/2019",changes:["Added missing hellscape achievement.","Fixed spatial reasoning and phage interaction.","Fixed warmonger unlocking requirement."]},{version:"0.4.27",date:"7/13/2019",changes:["Added special action description buttons for screen readers."]},{version:"0.4.26",date:"7/12/2019",changes:["Unlocked CRISPR upgrades are now listed as perks.","Control/Shift/Alt click now works with power on and off buttons."]},{version:"0.4.25",date:"7/11/2019",changes:["Quantum Manufacturing upgrade.","Quantum Swarm cost lowered from 465k to 450k."]},{version:"0.4.24",date:"7/10/2019",changes:["Thermomechanics upgrade for alloy production.","Ziggurats unlockable via ancients upgrade.","Cement factory has a more clear label in breakdown lists."]},{version:"0.4.23",date:"7/7/2019",changes:["Resources at the millions breakpoint and above are now shown with 2 significant decimal points.","Reduced the creep cost of Observatory.","Reduced the base knowledge cost of Observatory.","Reduced the Brick cost of Boot Camps.","Evil has been unleashed."]},{version:"0.4.22",date:"7/6/2019",changes:["Fixed issue with having exactly 251 Plasmids that would break your resources.","Fixed issue with planet generation that caused it to always use the same seed."]},{version:"0.4.21",date:"7/6/2019",changes:["Fixed unlocking of mass extinction achievement.","Fixed potential fuel consumption bug with power plants."]},{version:"0.4.20",date:"7/4/2019",changes:["Phage can now be earned from space resets, phage extends the plasmid diminishing return breakpoint.","Dimensional Warping crispr upgrade, applies phages to spatial reasoning.","Added special windmill tech for carnivore path to equalize power grid.","Space Stations now give 5 Elerium storage instead of 4."]},{version:"0.4.19",date:"7/2/2019",changes:["Fixed bugs with the hell planet and gas planet survey mission.","Fixed bug that prevented the planet description tooltip from triggering.","Aluminium now properly requires you to build a metal refinery."]},{version:"0.4.18",date:"7/1/2019",changes:["Planets choice now has more depth to it, each planet can be poor or rich in various resource types.","A mineral poor planet suffers anywhere from 1 to 10% penalty for that resource.","A mineral rich planet gains anywhere from 1 to 20% bonus for that resource.","The fire event no longer triggers for aquatic races.","The first interstellar probe now contributes to the number of potential target worlds.","All interstellar space probe costs are now cheaper."]},{version:"0.4.17",date:"6/29/2019",changes:["Added indication of current challenge level to top bar.","Added H tags for accessibility."]},{version:"0.4.16",date:"6/28/2019",changes:["New Hospital, heals wounded soldiers faster.","New Boot Camp, train new soldiers quicker.","Lowered research cost of Mass Driver from 170k to 160k.","Lowered Iridium cost of Mass Drivers.","Updated Mass Extinction unlock requirement."]},{version:"0.4.15",date:"6/28/2019",changes:["Global bonuses are now multiplicative instead of additive.","Decreased base Elerium cost of Exotic Lab by 4.","Creative trait decreases cost creep instead of providing a flat discount.","ARPA 100% button replaced with remaining percentage value.","New experimental military advice."]},{version:"0.4.14",date:"6/27/2019",changes:["Statues now cost Aluminium instead of Wrought Iron.","Nav Beacon now costs Aluminium instead of Iron.","Helium-3 Mine now costs Aluminium instead of Copper.","Elerium Mining Ship now costs Titanium instead of Iridium.","Iron Mining Ship now costs Aluminium instead of Titanium.","Dimension Compression upgrade now works correctly.","Aluminium can now be looted from battle."]},{version:"0.4.13",date:"6/26/2019",changes:["Aluminium resource added to the game, research Bayer Process to unlock Metal Refinery which in turn unlocks Aluminum.","New Metal Refinery structure for producing Aluminium.","Alloy is now made out of Aluminium and Copper.","Sheet Metal is now made out of Aluminium.","Oil Powerplant and Propellant Depot now cost Aluminium instead of Steel.","Some minor accessibility improvements."]},{version:"0.4.12",date:"6/24/2019",changes:["Blackhole achievement now gives a permanent perk for completing it, the perk strength depends on the achievement level.","Fixed issue with event timer being frozen after changing planets.","Fixed the unlocking of upgraded versions of some achievements.","Cost descriptions now show approximations above 10,000."]},{version:"0.4.11",date:"6/24/2019",changes:["Re-evaluated starvation breakpoint.","Added Infested Terran achievement.","Titanium price is now reset after unlocking Hunter Process.","Resources now have a 25% chance of their market price changing per day, up from 10%."]},{version:"0.4.10",date:"6/23/2019",changes:["Fixed stats tracking on demonic invasions so it actually tracks new invasions."]},{version:"0.4.9",date:"6/23/2019",changes:["Fabrication facilities now increase craftsman cap.","Added stats tracking on demonic invasions.","Detail Oriented buffed to 50% from 33%.","Rigorous buffed to 100% from 66%.","Crafting bonus now shown for each resource.","Temple Faith bonus now applies to crafting in no plasmid challenge mode.","Mastery bonus now applies to crafting."]},{version:"0.4.8",date:"6/22/2019",changes:["Fixed a bug that removed MAD when achieving unification.","Fixed missing options in evolution stage with picking avians after space reset."]},{version:"0.4.7",date:"6/21/2019",changes:["Activating challenge genes now provide a bonus to the number of plasmids earned."]},{version:"0.4.6",date:"6/21/2019",changes:["Reduced Nano Tube and Neutronium costs of bioseeder ship.","Reduced Mythril cost of Space Probes."]},{version:"0.4.5",date:"6/19/2019",changes:["Mastery Bonus now unlockable in CRISPR.","Fixed bug with elerium mining that could cause negative mining when you lacked asteroid miners.","Fixed low power warning not clearing when you have no buildings active.","Fixed Sporgar label of Cottages in Steel & Mythril Beams research.","Gene Mutation research will no longer turn off when you run out of knowledge, instead it will pause.","Human creative trait buffed from 2% to 5%.","Troll regenerative trait buffed to heal 4 wounded per day instead of 2.","Ogre tough trait buffed to 25% from 10%.","Gecko optimistic trait buffed to 10% from 2%.","Arraak resourceful trait buffed from 5% to 10%.","Dracnid hoarder trait buffed from 10% to 20%.","Shroomi toxic trait buffed from 10% to 25%.","Wolven pack mentality trait now applies to apartments.","Reduced Nano Tube cost of Mining Drones."]},{version:"0.4.4",date:"6/18/2019",changes:["Matter compression now applies to Wharves.","Xenophobia now applies to Wharves.","Plasmids earned by mutation now apply to no plasmid challenge run.","Reduced Nano Tube cost of Mining Drones."]},{version:"0.4.3",date:"6/17/2019",changes:["Challenge mode achievement tracking.","Vocational Training for craftsman.","Spelling and grammar fixes.","Fixed incorrect reject unity reward text."]},{version:"0.4.2",date:"6/16/2019",changes:["Added some clarification to breakdown of stress."]},{version:"0.4.1",date:"6/16/2019",changes:["Fixed a bug with factories converted from some pre 0.4.0 save files."]},{version:"0.4.0",date:"6/16/2019",changes:["Space reset option, control the destiny of your next race.","Challenge Modes.","New Stuff to discover.","New Achievements to unlock.","Added missing Cyclops racial trait.","World Domination, maybe.","Added soft reset option."]},{version:"0.3.12",date:"6/11/2019",changes:["Fixed bug with riot event that caused it to trigger on high morale instead of low morale."]},{version:"0.3.11",date:"6/10/2019",changes:["The Gas Moon and the Dwarf planets are now accessible.","New technologies based on new discoveries made in deep space.","Wharves can now be unlocked after discovering oil.","There is now an alternative method of unlocking steel.","Night Theme updated, popovers are no longer bright.","Trade route tooltips now include money being imported or exported.","New crispr upgrades for crafting.","Warmonger achievement requirement lowered from 10% to 8%."]},{version:"0.3.10",date:"6/9/2019",changes:["Added code to fix peculiar failed space launch game state."]},{version:"0.3.9",date:"6/8/2019",changes:["New official Evolve [Discord](https://discordapp.com/invite/dcwdQEr)."]},{version:"0.3.8",date:"6/7/2019",changes:["Fixed a problem with negative craftsman counts that could result from craftsman dying."]},{version:"0.3.7",date:"6/6/2019",changes:["Warmongering is now tracked and high casualties may impact morale.","Depleting the mercenary pool will temporarily increase their cost.","Three new achievements related to war."]},{version:"0.3.6",date:"6/5/2019",changes:["Fixed issue with production breakdowns not showing when income was only produced by trade.","Fixed issue that prevented affordability check from refreshing on space missions."]},{version:"0.3.5",date:"6/5/2019",changes:["Mythril Craftsman now unlock correctly.","Fixed a bug that could pause the game if you ran out of Titanium."]},{version:"0.3.4",date:"6/4/2019",changes:["The Asteroid Belt is now open for business.","Robotics Upgrades.","Automation renamed to Machinery.","Assembly Line upgrade for factory."]},{version:"0.3.3",date:"6/3/2019",changes:["New Orbit Structure: Navigation Beacon.","New Red Planet Structures: Space Control Tower and Space Factory.","Reduced number of monuments required to unlock tourism from 4 to 2.","Cement plant workers now round their contribution to 2 decimal places.","Red planet mining now correctly attributes to the red planet in breakdowns."]},{version:"0.3.2",date:"6/3/2019",changes:["Fixed bug that would let you launch the space missions without the proper resources, this would corrupt your game file and break the game.","Added code to detect games corrupted by the previous bug and fix them.","Fixed Fanaticism bug that wouldn't release lumberjacks when you have ent gods."]},{version:"0.3.1",date:"6/3/2019",changes:["Added building check redundancy to auto correct game states that shouldn't occur anyway."]},{version:"0.3.0",date:"6/2/2019",changes:["Space V1 Update.","This opens the first steps into space exploration, more to come... this is not the end.","Rebalanced storage caps to help the game feel more idle friendly."]},{version:"0.2.70",date:"6/2/2019",changes:["Fixed bug when picking Fanaticism with cath gods that wouldn't release your farmers.","Fixed bug when upgrading weapon technology that wouldn't immediately show the increase in army rating."]},{version:"0.2.69",date:"5/26/2019",changes:["Fixed bug which could let you get free barn or warehouse upgrade by essentially skipping over the tech.","Added aria button roles to many button like elements that were not technically buttons."]},{version:"0.2.68",date:"5/26/2019",changes:["Fixed bug with Rock Quarry that prevented the 2% bonus from working unless you had electricity unlocked."]},{version:"0.2.67",date:"5/24/2019",changes:["Revamp of farmer, lumberjack, and quarry worker jobs. These govern the most basic materials produced and can now assign as many workers as you like to these positions.","Farms now directly produce food instead of determining farmer cap.","Lumber Yards now increase lumber production instead of governing lumberjack cap.","Rock Quarry now increase stone production instead of governing quarry worker cap.","Sawmill powered on bonus reduced from 5% to 4%.","Rock Quarry powered on bonus reduced from 5% to 4%.","Stock Exchanges no longer cost Knowledge.","Fixed a display bug that could cause farmers to falsely show they produced more food then they actual did."]},{version:"0.2.66",date:"5/22/2019",changes:["Added alternate row coloring to the market to help distinguish rows."]},{version:"0.2.65",date:"5/21/2019",changes:["Sporgar race redesigned into a parasitic race that spreads through infecting victims."]},{version:"0.2.64",date:"5/20/2019",changes:["Currency is now required before unlocking Basic Storage.","Primitive Axes are no longer gated behind Basic Storage.","Foundry now requires Metal Working to unlock and no longer requires Cement.","Research tab now defaults back to new when resetting.","Fixed issue with not being able to buy something if you had consumption on a resource and the cost was the same as your max capacity.","Fixed issue with max affordability check not refreshing on evolution stage.","Experimental Red-Green color blind theme."]},{version:"0.2.63",date:"5/20/2019",changes:["Fixed an issue that accidentally set the default tax rate to 2% instead of 20% for new games."]},{version:"0.2.62",date:"5/19/2019",changes:["Tax system revamped. Taxes can now be adjusted more granularly and effect morale instead of production.","Cement is now a requirement for theology since cement is needed for temples."]},{version:"0.2.61",date:"5/19/2019",changes:["Every genus type now has its own evolution path."]},{version:"0.2.60",date:"5/18/2019",changes:["Rescaled crate/container volumes. There are now substantially less crates/containers but they do a lot more per crate/container.","Spatial Reasoning now correctly applies to crates & containers.","Increased base value of several major storage facilities.","Added storage timers.","A.R.P.A. costs in popover now update their affordability check.","Buildings and Research that can not be afforded due to low capacity are now marked in red text."]},{version:"0.2.59",date:"5/17/2019",changes:["Added additional validation to ensure save strings belong to evolve before importing.","Fixed army rating display when rating doesn't calculate to a whole number.","Fixed listing order of some resources.","Smelter Iron bonus breakdown fixed.","Added Selenophobia to breakdown lists."]},{version:"0.2.58",date:"5/15/2019",changes:["Settings option to disable multiplier keys."]},{version:"0.2.57",date:"5/15/2019",changes:["Added labor validation to coal miners.","Key Multipliers now work with job and trade route assignment."]},{version:"0.2.56",date:"5/15/2019",changes:["Added +- symbols to trade route to distinguish import vs export."]},{version:"0.2.55",date:"5/14/2019",changes:["Manually crafting resources now gets all the same bonuses as auto crafting.","Fixed Recombination crispr upgrade.","Death limits added to each war campaign level.","War assessment added for each war campaign level."]},{version:"0.2.54",date:"5/13/2019",changes:["Uranium Breakdown Fixes."]},{version:"0.2.53",date:"5/13/2019",changes:["Breakdown Accuracy Enhancements.","Some Kindling Kindred costs reduced.","Fixed bug related to Fanaticism and Ent gods with foundry workers assigned to make plywood.","Plasmid bonus now applies to the sundial.","Fixed some spelling errors."]},{version:"0.2.52",date:"5/11/2019",changes:["Completed research can now be viewed on a separate tab under research.","Removed Plywood requirement from Stock Exchange for players with Kindling Kindred trait.","Fixed a CSS issue in the A.R.P.A. projects tab."]},{version:"0.2.51",date:"5/11/2019",changes:["University starts slightly cheaper.","Added Spatial Superiority crispr upgrade.","Added Spatial Supremacy crispr upgrade.","Exporting a save string now automatically selects the text and copies it to the clipboard."]},{version:"0.2.50",date:"5/10/2019",changes:["Added new capacity breakdowns for various resources."]},{version:"0.2.49",date:"5/10/2019",changes:["Added changelog link to version listing.","Added protection against loading a corrupt save string.","Greedy trait is now less greedy.","Spelling error fixes."]},{version:"0.2.48",date:"5/8/2019",changes:["Resources that are at greater then 99% capacity now change color to indicate they are at cap.","Attacks from rival cities should no longer cause more wounded soldiers then you have.","Assigning craftsman when no citizens are free will no longer take the labor from another job."]},{version:"0.2.47",date:"5/8/2019",changes:["Gluttony trait lowered to 10% from 25% .","High Metabolism trait lowered to 5% from 10% .","Fixed Sheet Metal not being added to craftsman list when unlocked."]},{version:"0.2.46",date:"5/8/2019",changes:["The 5% library bonus was only applying to scientists which was not intended. This now applies to the sundial and professors as well."]},{version:"0.2.45",date:"5/8/2019",changes:["Fixed an issue that allowed you to get extra benefits from under-powered wardenclyffe towers and biolabs."]},{version:"0.2.44",date:"5/8/2019",changes:["Fixed Key Multipliers getting stuck down."]},{version:"0.2.43",date:"5/7/2019",changes:["Fixed bug that could cause player to get free extra crafted resources when using the +5 option.","Reordered buildings in Village tab to group them more logically."]},{version:"0.2.42",date:"5/7/2019",changes:["Fixed a bug that was causing soldiers to become immortal.","Fixed some bugs with morale that caused some weather patterns to apply a different value then was reported.","Added weather to Food breakdown."]},{version:"0.2.41",date:"5/7/2019",changes:["Added a 5% bonus to global knowledge production on libraries."]},{version:"0.2.40",date:"5/7/2019",changes:["The Hivemind trait no longer applies to farmers as this was especially punishing."]},{version:"0.2.39",date:"5/7/2019",changes:["Evolution 2.0: Redid the evolution stage of the game to make it feel less tedious and like it matters more to the next phase of the game.","Fixed a bug that has the intended effects of Pessimism and Optimism traits swapped."]},{version:"0.2.38",date:"5/6/2019",changes:["First public release."]}];function Sc(a,r,i){$("#content").removeClass("flex");var s,n=e.getItem("evolved")||!1;switch(n&&(s=JSON.parse(LZString.decompressFromUTF16(n)),t=s),ks("page_view",{page_title:`Evolve Wiki - ${a}`}),a){case"intro":Fc(),window.location.hash=`#${a}`;break;case"faq":!function(){let e=$("#content");Ss(e);let a=["update","hotkeys","sethotkeys","offline","moonphase","orbital","lumber","farm","steel","aluminium","titanium","titanium_balorg","polymer","mythril","neutronium","adamantite","infernite","graphene","stanene","aerogel","crates","soft_reset","hard_reset","combat","morale","stress","genetic_decay","cache","aphrodisiac","religion","tax_riots","race","weather","sundial","plasmid","plasmid_keep","plasmid_earn","crispr","creep","phage","phage_earn","phage_benefit","anti_plasmids","temple","temple_break","demonic","celestial","mastery","challenges","perks","feats","support","micro","valdi","quantum","quantum_level","exotic","soul_gem","soul_gem_spend","hell_patrol","surveyors","defense","infusion","dark_energy"],r={neutronium:[Ki[t.race.species].solar.gas_moon]};for(let t=0;t
                                  ');e.append(i);let s=[];r.hasOwnProperty(a[t])&&(s=r[a[t]]),i.append(`

                                  ${z(`wiki_faq_q_${a[t]}`)}

                                  `),i.append(`
                                  ${z(`wiki_faq_a_${a[t]}`,s)}
                                  `)}}(),window.location.hash=`#${a}`;break;case"gameplay":kc(r),Cc(a,r,i);break;case"prestige":!function(e){let a=$("#content");switch(Ss(a),e){case"resets":wc(a);break;case"resources":!function(e){let a=Ln("create",e),r=In(a,{name:"plasmids",template:"p_res",paragraphs:2,h_level:2,para_data:{1:[250]},data_color:{1:["warning"]}}),i=Bn(r,"plasmid","gain");fc(i,"plasmid"),i=Bn(r,"plasmid","bonus"),yc(i,"plasmid"),bc(i,"plasmid"),Ln("add","resources-prestige","plasmids",z("wiki_p_res_plasmids")),r=In(a,{name:"antiplasmids",template:"p_res",paragraphs:5,h_level:2,para_data:{4:[z("arpa_genepool_bleeding_effect_title")]},data_link:{4:["wiki.html#crispr-prestige-bleeding_effect"]}}),i=Bn(r,"anti","gain"),fc(i,"plasmid","anti"),i=Bn(r,"anti","bonus"),yc(i,"anti"),bc(i,"anti"),Ln("add","resources-prestige","antiplasmids",z("wiki_p_res_antiplasmids")),r=In(a,{name:"phage",template:"p_res",paragraphs:4,h_level:2}),i=Bn(r,"phage","gain"),fc(i,"phage"),i=Bn(r,"phage","bonus"),bc(i,"phage"),Ln("add","resources-prestige","phage",z("wiki_p_res_phage"));let s=In(a,{name:"dark",template:"p_res",paragraphs:1,h_level:2}),n=$("
                                  "),c=$('
                                    ');s.append(n),n.append(c),c.append(`
                                  • ${z("wiki_p_res_dark_standard")}
                                  • `),c.append(`
                                  • ${z("wiki_p_res_dark_evil")}
                                  • `),c.append(`
                                  • ${z("wiki_p_res_dark_heavy")}
                                  • `),c.append(`
                                  • ${z("wiki_p_res_dark_antimatter")}
                                  • `),c.append(`
                                  • ${z("wiki_p_res_dark_micro")}
                                  • `),c.append(`
                                  • ${z("wiki_p_res_dark_magic")}
                                  • `),i=Bn(s,"dark","gain"),fc(i,"dark",!1,"bigbang"),fc(i,"dark","vacuum","vacuum"),i=Bn(s,"dark","bonus"),function(e){let a=$('
                                    ');e.append(a),a.append(`

                                    ${z("wiki_calc_bonuses",[z("resource_Dark_name")])}

                                    `);let r=$("
                                    "),i=$("
                                    "),s=$("
                                    ");a.append(r),a.append(i),a.append(s);let n={dark:{val:void 0},harmony:{val:void 0},sludge:{val:void 0},uni:{val:"standard"}},c={standard:{vis:!0,result:!1,val:0},evil:{vis:!1,result:!1,val:0},antimatter:{vis:!1,result:!1,val:0},micro:{vis:!1,result:!1,val1:0,val2:0},heavy:{vis:!1,result:!1,val1:0,val2:0},magic:{vis:!1,result:!1,val:0}};r.append(`\n
                                    ${z("wiki_calc_universe")} \n \n {{ 'standard' | uniLabel }}\n {{ 'evil' | uniLabel }}\n {{ 'antimatter' | uniLabel }}\n {{ 'micro' | uniLabel }}\n {{ 'heavy' | uniLabel }}\n {{ 'magic' | uniLabel }}\n
                                    \n `),i.append(`\n
                                    \n
                                    \n ${z("wiki_calc_bonuses",[z("wiki_calc_dark_standard")])}:\n
                                    \n
                                    \n ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.001)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03))) / 200 = {{ 'standard', false | calc }} = +{{ 'standard', true | calc }}%\n
                                    \n
                                    \n
                                    \n
                                    \n ${z("wiki_calc_bonuses",[z("wiki_calc_dark_evil")])}:\n
                                    \n
                                    \n (log2(10 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) - 3.321928094887362) / 5 = {{ 'evil', false | calc }} = +{{ 'evil', true | calc }}%\n
                                    \n
                                    \n
                                    \n
                                    \n ${z("wiki_calc_bonuses",[z("wiki_calc_dark_antimatter")])}:\n
                                    \n
                                    \n (ln(50 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) - 3.912023005428146) / 5 = {{ 'antimatter', false | calc }} = +{{ 'antimatter', true | calc }}%\n
                                    \n
                                    \n
                                    \n
                                    \n ${z("wiki_calc_creep_reduction",[z("wiki_calc_home")])} (${z("wiki_calc_cap",[.06])}):\n
                                    \n
                                    \n (0.02 + ((ln(100 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)))) - 4.605170185988092) / 20)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)) = {{ 'micro', false, 2 | calc }}\n
                                    \n
                                    \n ${z("wiki_calc_creep_reduction",[z("wiki_calc_not_home")])} (${z("wiki_calc_cap",[.04])}):\n
                                    \n
                                    \n (0.01 + ((ln(100 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)))) - 4.605170185988092) / 35)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)) = {{ 'micro', false, 1 | calc }}\n
                                    \n
                                    \n
                                    \n
                                    \n ${z("wiki_calc_dark_heavy",[z("wiki_menu_space")])}:\n
                                    \n
                                    \n 0.25 + (0.5 * 0.995^({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) = {{ 'heavy', false, 1 | calc }} = +{{ 'heavy', true, 1 | calc }}%\n
                                    \n
                                    \n ${z("wiki_calc_dark_heavy",[z("wiki_tech_req_or",[z("wiki_menu_interstellar"),z("wiki_menu_intergalactic")])])}:\n
                                    \n
                                    \n 0.2 + (0.3 * 0.995^({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) = {{ 'heavy', false, 2 | calc }} = +{{ 'heavy', true, 2 | calc }}%\n
                                    \n
                                    \n
                                    \n
                                    \n ${z("wiki_calc_bonuses",[z("wiki_calc_dark_magic")])}:\n
                                    \n
                                    \n (ln(50 + ({{ i.dark.val, 'dark' | generic }} * (1 + ({{ i.harmony.val, 'harmony' | generic }} * 0.01)) * (1 + ({{ i.sludge.val | sludgeLabel }} * 0.03)))) - 3.912023005428146) / 3 = {{ 'magic', false | calc }} = +{{ 'magic', true | calc }}%\n
                                    \n
                                    \n `),s.append(`\n
                                    \n
                                    ${z("wiki_p_res_dark")}
                                    \n
                                    ${z("wiki_p_res_harmony")}
                                    \n
                                    ${z("wiki_calc_sludge_level")}
                                    \n
                                    \n
                                    \n \n \n
                                    \n `),Cs({el:"#darkBonusCalc",data:{i:n,s:c},methods:{val(e){n[e].val&&n[e].val<0?n[e].val=0:"sludge"===e&&n.sludge.val&&n.sludge.val>5&&(n.sludge.val=5)},pickUniverse(e){c[n.uni.val].vis=!1,n.uni.val=e,c[e].vis=!0},resetInputs(){n.dark.val=void 0,n.harmony.val=void 0,n.sludge.val=void 0,c[n.uni.val].vis=!1,n.uni.val="standard",c.standard.vis=!0},importInputs(){n.dark.val=t.prestige.Dark.count,n.harmony.val=t.prestige.Harmony.count,"bigbang"!==t.race.universe&&(c[n.uni.val].vis=!1,n.uni.val=t.race.universe,c[n.uni.val].vis=!0),n.sludge.val=t.stats.achieve.extinct_sludge&&t.stats.achieve.extinct_sludge[xn(n.uni.val)]?t.stats.achieve.extinct_sludge[xn(n.uni.val)]:0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_p_res_"+t),sludgeLabel:e=>void 0!==e?e:z("wiki_calc_sludge_level"),uniLabel:e=>z(e?"universe_"+e:"wiki_calc_universe"),calc(e,t,a){if(e===n.uni.val){if(t)return"heavy"===e?(100*c[e][`val${a}`]).toFixed(3):(100*c[e].val).toFixed(3);if(c[e].result=void 0!==n.dark.val&&void 0!==n.harmony.val,c[e].result)switch(e){case"standard":case"evil":case"antimatter":case"magic":return c[e].val=+(Is(e,!1,!0,{dark:n.dark.val,harmony:n.harmony.val,sludge:n.sludge.val})-1).toFixed(6),c[e].val;case"micro":return c[e][`val${a}`]=Is(e,1===a,!0,{dark:n.dark.val,harmony:n.harmony.val,sludge:n.sludge.val}),c[e][`val${a}`];case"heavy":let t=Is(e,!1,!0,{dark:n.dark.val,harmony:n.harmony.val,sludge:n.sludge.val});return t=1===a?.25+.5*t:.2+.3*t,c[e][`val${a}`]=t.toFixed(5),c[e][`val${a}`]}}}}})}(i),Ln("add","resources-prestige","dark",z("wiki_p_res_dark")),r=In(a,{name:"harmony",template:"p_res",paragraphs:3,h_level:2}),i=Bn(r,"harmony","gain"),fc(i,"harmony"),i=Bn(r,"harmony","bonus"),function(e){let a=$('
                                    ');e.append(a),a.append(`

                                    ${z("wiki_calc_creep_reduction",[z("resource_Harmony_name")])}

                                    `);let r=$("
                                    "),i=$("
                                    ");a.append(r),a.append(i);let s={harmony:{val:void 0},ascended:{val:void 0},uni:{val:"undefined"}},n={result:{vis:!1,val:0}};r.append("\n
                                    \n (ln(50 + ({{ i.harmony.val, 'harmony' | generic }} * {{ i.ascended.val | ascendedLabel }})) - 3.912023005428146) * 0.01 = {{ | calc }}\n
                                    \n "),i.append(`\n
                                    \n
                                    ${z("wiki_p_res_harmony")}
                                    \n
                                    ${z("wiki_calc_ascended_level")}
                                    \n
                                    \n
                                    \n \n \n
                                    \n `),Cs({el:"#harmonyCreepCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0?s[e].val=0:"ascended"===e&&s.ascended.val&&s.ascended.val>5&&(s.ascended.val=5)},resetInputs(){s.harmony.val=void 0,s.ascended.val=void 0},importInputs(){s.harmony.val=t.prestige.Harmony.count,s.ascended.val=t.stats.achieve.ascended&&t.stats.achieve.ascended[xn(t.race.universe||"standard")]?t.stats.achieve.ascended[xn(t.race.universe||"standard")]:0}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_p_res_"+t),ascendedLabel:e=>void 0!==e?e:z("wiki_calc_ascended_level"),calc(){if(n.result.vis=void 0!==s.harmony.val&&void 0!==s.ascended.val,n.result.vis)return n.result.val=+(.01*(Math.log(50+s.harmony.val*s.ascended.val)-3.912023005428146)).toFixed(5),n.result.val}}})}(i),Ln("add","resources-prestige","harmony",z("wiki_p_res_harmony")),In(a,{name:"blood",template:"p_res",paragraphs:5,h_level:2,para_data:{2:[z("tab_arpa_blood")],3:[1,"1-5"],4:[z("arpa_genepool_blood_sacrifice_title")],5:[z("arpa_genepool_blood_remembrance_title")]},data_link:{2:["wiki.html#blood-prestige"],4:["wiki.html#crispr-prestige-blood_sacrifice"],5:["wiki.html#crispr-prestige-blood_remembrance"]}}),Ln("add","resources-prestige","blood",z("wiki_p_res_blood")),r=In(a,{name:"artifact",template:"p_res",paragraphs:3,h_level:2,para_data:{1:[z("wiki_resets_infusion")],2:[z("tab_arpa_blood")],3:[1,"5th"]},data_link:{1:["wiki.html#resets-prestige-infusion"],2:["wiki.html#blood-prestige"]}}),i=Bn(r,"artifact","gain"),fc(i,"artifact"),Ln("add","resources-prestige","artifact",z("wiki_p_res_artifact")),r=In(a,{name:"ai_core",template:"p_res",paragraphs:2,h_level:2,para_data:{1:[z("wiki_resets_ai")]},data_link:{1:["wiki.html#resets-prestige-ai"]}}),i=Bn(r,"cores","gain"),fc(i,"cores"),i=Bn(r,"cores","bonus"),function(e){let a=$('
                                    ');e.append(a),a.append(`

                                    ${z("wiki_calc_core_quantum")}

                                    `);let r=$("
                                    "),i=$("
                                    ");a.append(r),a.append(i);let s={cores:{val:void 0}},n={result:{vis:!1,val:0}};r.append("\n
                                    \n 1 - (0.99^{{ i.cores.val, 'cores' | generic }}) = {{ false | calc }} = +{{ true | calc }}%\n
                                    \n "),i.append(`\n
                                    \n
                                    ${z("wiki_calc_cores")}
                                    \n
                                    \n
                                    \n \n \n
                                    \n `),Cs({el:"#coresQuantumCalc",data:{i:s,s:n},methods:{val(e){s[e].val&&s[e].val<0&&(s[e].val=0)},resetInputs(){s.cores.val=void 0},importInputs(){s.cores.val=t.prestige.AICore.count}},filters:{generic:(e,t)=>void 0!==e?e:z("wiki_calc_"+t),calc:e=>e?+(100*n.result.val).toFixed(2):(n.result.vis=void 0!==s.cores.val,n.result.vis?(n.result.val=+(1-.99**s.cores.val).toFixed(4),n.result.val):void 0)}})}(i),Ln("add","resources-prestige","ai_core",z("wiki_p_res_ai_core")),r=In(a,{name:"servants",template:"p_res",paragraphs:5,h_level:2,break:[3,4,5],para_data:{1:[z("wiki_resets_matrix"),z("wiki_resets_retired"),z("wiki_resets_eden")],5:[z("achieve_overlord_name")]},data_link:{1:["wiki.html#resets-prestige-matrix","wiki.html#resets-prestige-retired","wiki.html#resets-prestige-eden"],5:["wiki.html#perks-prestige-overlord"]}}),Ln("add","resources-prestige","servants",z("wiki_p_res_servants")),r=In(a,{name:"skilled_servants",template:"p_res",paragraphs:6,h_level:2,break:[3,4,5,6],para_data:{1:[z("wiki_resets_matrix"),z("wiki_resets_retired")],6:[z("achieve_pathfinder_name"),z("achieve_overlord_name")]},data_link:{1:["wiki.html#resets-prestige-matrix","wiki.html#resets-prestige-retired"],6:["wiki.html#perks-prestige-pathfinder","wiki.html#perks-prestige-overlord"]}}),Ln("add","resources-prestige","skilled_servants",z("wiki_p_res_skilled_servants"))}(a);break;case"crispr":$c(a);break;case"blood":Pc(a);break;case"perks":!function(e){let t=$("
                                    "),a=Ln("create",t);e.append(t),Object.keys(Fn).forEach((function(e){!function(e,t){let a=$(`
                                    `);if(Fn[t].hasOwnProperty("group")){let e=$(`
                                    ${Fn[t].name}
                                    `);Fn[t].group.forEach((function(t){e.append($(`
                                    ${t.desc(!0)}
                                    `))})),a.append(e)}else a.append($(`
                                    ${Fn[t].name}
                                    ${Fn[t].desc(!0)}
                                    `));if(Fn[t].notes.length>0){let e=$('
                                    ');Fn[t].notes.forEach((function(t){e.append(`
                                    ${t}
                                    `)})),a.append(e)}e.append(a)}(a,e),Ln("add","perks-prestige",`${e}`,Fn[e].name)}))}(a)}}(r),Cc(a,r,i);break;case"events":(function(e){let a=$("#content");switch(Ss(a),e){case"major":!function(e){let a=Ln("create",e);In(a,{name:"major_intro",template:"events",paragraphs:3,h_level:2,para_data:{1:[z("wiki_menu_major"),999,83],2:[z("wiki_menu_major")],3:[z("wiki_menu_major")]}}),Ln("add","major-events","major_intro",z("wiki_menu_intro"));{let e=In(a,{name:"replication",template:"events",label:z("wiki_events_replication"),paragraphs:1,h_level:2,para_data:{1:[1,z("wiki_events_replication_para1_note",[3])]}});In(a,{name:"evolution",template:"events",label:z("wiki_events_replication"),paragraphs:1,h_level:2},e),In(a,{name:"replication_examples",template:"events",label:z("wiki_events_replication"),h_level:2,examples:[z("event_dna",[10])]},e),Ln("add","major-events","replication",z("wiki_events_replication"))}{let e=In(a,{name:"rna_meteor",template:"events",label:z("wiki_events_rna_meteor"),paragraphs:1,h_level:2,para_data:{1:[1,z("wiki_events_rna_meteor_para1_note",[2])]}});In(a,{name:"evolution",template:"events",label:z("wiki_events_rna_meteor"),paragraphs:1,h_level:2},e),In(a,{name:"rna_meteor_examples",template:"events",label:z("wiki_events_rna_meteor"),h_level:2,examples:[z("event_rna",[22])]},e),Ln("add","major-events","rna_meteor",z("wiki_events_rna_meteor"))}In(a,{name:"inspiration",template:"events",label:z("wiki_events_inspiration"),paragraphs:1,h_level:2,para_data:{1:[300,600]},examples:[z("event_inspiration")]}),Ln("add","major-events","inspiration",z("wiki_events_inspiration")),In(a,{name:"motivation",template:"events",label:z("wiki_events_motivation"),paragraphs:3,h_level:2,para_data:{1:[300,600],2:["10%","13%"]},examples:[z("event_motivation")]}),Ln("add","major-events","motivation",z("wiki_events_motivation"));{let e=In(a,{name:"fire",template:"events",label:z("wiki_events_fire"),paragraphs:1,h_level:2,para_data:{1:[1,"25%"]}});In(a,{name:"fire_condition",template:"events",label:z("wiki_events_fire"),paragraphs:2,break:[2],h_level:2},e),In(a,{name:"fire_examples",template:"events",label:z("wiki_events_fire"),h_level:2,examples:[z("event_fire",[1337..toLocaleString()])]},e),Ln("add","major-events","fire",z("wiki_events_fire"))}{let e=In(a,{name:"flare",template:"events",label:z("wiki_events_flare"),paragraphs:3,h_level:2,para_data:{2:["10%"],3:["20%",20,200]}});In(a,{name:"flare_condition",template:"events",label:z("wiki_events_flare"),paragraphs:4,break:[2],h_level:2},e),In(a,{name:"flare_examples",template:"events",label:z("wiki_events_flare"),h_level:2,examples:[z("event_flare",[Ki[t.race.species].home,69]),z("event_flare2",[Ki[t.race.species].home,42])]},e),Ln("add","major-events","flare",z("wiki_events_flare"))}{let e=In(a,{name:"raid",template:"events",label:z("wiki_events_raid"),paragraphs:3,h_level:2,para_data:{2:["25%"]}});In(a,{name:"raid_condition",template:"events",label:z("wiki_events_raid"),paragraphs:2,h_level:2,para_data:{2:[z("wiki_challenges_scenarios_truepath")]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"]}},e),In(a,{name:"raid_examples",template:"events",label:z("wiki_events_raid"),h_level:2,examples:[z("event_raid1",[10,31]),z("event_raid2",[244,0,50])]},e),Ln("add","major-events","raid",z("wiki_events_raid"))}{let e=In(a,{name:"siege",template:"events",label:z("wiki_events_siege"),paragraphs:3,h_level:2,para_data:{2:["50%"]}});In(a,{name:"siege_condition",template:"events",label:z("wiki_events_siege"),paragraphs:3,h_level:2,para_data:{3:[z("wiki_challenges_scenarios_truepath")]},data_link:{3:["wiki.html#challenges-gameplay-scenarios_truepath"]}},e),In(a,{name:"siege_examples",template:"events",label:z("wiki_events_siege"),h_level:2,examples:[z("event_siege1",[30,49]),z("event_siege2",[500024..toLocaleString(),0,25])]},e),Ln("add","major-events","siege",z("wiki_events_siege"))}{let e=In(a,{name:"terrorist",template:"events",label:z("wiki_events_terrorist"),paragraphs:1,h_level:2});In(a,{name:"terrorist_condition",template:"events",label:z("wiki_events_terrorist"),paragraphs:2,h_level:2,para_data:{2:[z("wiki_challenges_scenarios_truepath")]},data_link:{2:["wiki.html#challenges-gameplay-scenarios_truepath"]}},e),In(a,{name:"terrorist_examples",template:"events",label:z("wiki_events_terrorist"),h_level:2,examples:[z("event_terrorist1",[14]),z("event_terrorist2",[54,18])]},e),Ln("add","major-events","terrorist",z("wiki_events_terrorist"))}{let e=In(a,{name:"pillage",template:"events",label:z("wiki_events_pillage"),paragraphs:6,break:[5],h_level:2,para_data:{2:["25%"],3:["50%"],5:[z("civics_gov_relations"),"40%"]}});In(a,{name:"pillage_condition",template:"events",label:z("wiki_events_pillage"),paragraphs:1,h_level:2,para_data:{1:[z("wiki_challenges_scenarios_truepath")]},data_link:{1:["wiki.html#challenges-gameplay-scenarios_truepath"]}},e),In(a,{name:"pillage_examples",template:"events",label:z("wiki_events_pillage"),h_level:2,examples:[z("event_pillaged1",[z("civics_gov2",[z("civics_gov_name4")]),10,55]),z("event_pillaged2",[z("civics_gov6",[z("civics_gov_name9")]),40,25,[`5704490 ${z("resource_Lumber_name")}`,`2177130 ${z("resource_Stone_name")}`,`4259421 ${z("resource_Furs_name")}`,`6033892 ${z("resource_Copper_name")}`,`602938 ${z("resource_Iron_name")}`,`3389580 ${z("resource_Aluminium_name")}`,`3292455 ${z("resource_Cement_name")}`,`5394173 ${z("resource_Coal_name")}`,`47231 ${z("resource_Oil_name")}`,`9390 ${z("resource_Uranium_name")}`,`7016884 ${z("resource_Steel_name")}`,`52801 ${z("resource_Titanium_name")}`,`1163086 ${z("resource_Alloy_name")}`,`2053980 ${z("resource_Polymer_name")}`,`3179901 ${z("resource_Iridium_name")}`,`792693 ${z("resource_Helium_3_name")}`,`1219 ${z("resource_Elerium_name")}`,`65078 ${z("resource_Water_name")}`,`290451 ${z("resource_Neutronium_name")}`,`3059577 ${z("resource_Adamantite_name")}`,`5736560 ${z("resource_Nano_Tube_name")}`,`2494390 ${z("resource_Graphene_name")}`,`6836006 ${z("resource_Stanene_name")}`,`2264649 ${z("resource_Orichalcum_name")}`,"$19235850"].join(", ")])]},e),Ln("add","major-events","pillage",z("wiki_events_pillage"))}{let e=In(a,{name:"quake",template:"events",label:z("wiki_events_quake"),paragraphs:1,h_level:2});In(a,{name:"quake_condition",template:"events",label:z("wiki_events_quake"),paragraphs:2,break:[2],h_level:2},e),In(a,{name:"quake_examples",template:"events",label:z("wiki_events_quake"),h_level:2,examples:[z("event_quake",[t.race.cataclysm||t.race.orbit_decayed?Ki[t.race.species].solar.red:Ki[t.race.species].home])]},e),Ln("add","major-events","quake",z("wiki_events_quake"))}{let e=In(a,{name:"doom",template:"events",label:z("wiki_events_doom"),paragraphs:2,h_level:2});In(a,{name:"doom_condition",template:"events",label:z("wiki_events_doom"),paragraphs:2,break:[2],h_level:2},e),In(a,{name:"doom_examples",template:"events",label:z("wiki_events_doom"),h_level:2,examples:[z("event_doom",[Ki[t.race.species].solar.dwarf]),z("event_doom_alt",[Ki[t.race.species].solar.dwarf])]},e),Ln("add","major-events","doom",z("wiki_events_doom"))}{let e=In(a,{name:"dhorde",template:"events",label:z("wiki_events_dhorde"),paragraphs:1,h_level:2,para_data:{1:[2500,5e3]}});In(a,{name:"dhorde_condition",template:"events",label:z("wiki_events_dhorde"),paragraphs:1,h_level:2},e),In(a,{name:"dhorde_examples",template:"events",label:z("wiki_events_dhorde"),h_level:2,examples:[z("event_demon_influx",[3456..toLocaleString()])]},e),Ln("add","major-events","dhorde",z("wiki_events_dhorde"))}{let e=In(a,{name:"ruins",template:"events",label:z("wiki_events_ruins"),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("resource_Iron_name"),z("resource_Copper_name"),z("resource_Steel_name"),z("resource_Cement_name"),"25%"]}});In(a,{name:"ruins_condition",template:"events",label:z("wiki_events_ruins"),paragraphs:1,h_level:2},e),In(a,{name:"ruins_examples",template:"events",label:z("wiki_events_ruins"),h_level:2,examples:[z("event_ruins")]},e),Ln("add","major-events","ruins",z("wiki_events_ruins"))}{let e=In(a,{name:"taxrevolt",template:"events",label:z("wiki_events_taxrevolt"),paragraphs:2,h_level:2});In(a,{name:"taxrevolt_condition",template:"events",label:z("wiki_events_taxrevolt"),paragraphs:3,break:[2],h_level:2,para_data:{1:["> 25%","< 100%"],2:[z("govern_oligarchy"),"20%"],3:[z("governor_noble"),"10%"]}},e),In(a,{name:"taxrevolt_examples",template:"events",label:z("wiki_events_taxrevolt"),h_level:2,examples:[z("event_tax_revolt")]},e),Ln("add","major-events","taxrevolt",z("wiki_events_taxrevolt"))}{let e=In(a,{name:"slave",template:"events",label:z("wiki_events_slave"),paragraphs:2,break:[2],h_level:2});In(a,{name:"slave_condition",template:"events",label:z("wiki_events_slave"),paragraphs:1,h_level:2,para_data:{1:[z("trait_slaver_name")]}},e),In(a,{name:"slave_examples",template:"events",label:z("wiki_events_slave"),h_level:2,examples:[z("event_slave_death1"),z("event_slave_death2"),z("event_slave_death3"),z("event_slave_none")]},e),Ln("add","major-events","slave",z("wiki_events_slave"))}{let e=In(a,{name:"protest",template:"events",label:z("wiki_events_protest"),paragraphs:3,h_level:2,para_data:{1:[z("govern_republic")],2:["30%"],3:[30,90]}});In(a,{name:"protest_condition",template:"events",label:z("wiki_events_protest"),paragraphs:1,h_level:2,para_data:{1:[z("govern_republic")]}},e),In(a,{name:"protest_examples",template:"events",label:z("wiki_events_protest"),h_level:2,examples:[z("event_protest0",[pi("small")]),z("event_protest1"),z("event_protest2"),z("event_protest3"),z("event_protest4"),z("event_protest5"),z("event_protest6"),z("event_protest7"),z("event_protest8"),z("event_protest9")]},e),Ln("add","major-events","protest",z("wiki_events_protest"))}{let e=In(a,{name:"scandal",template:"events",label:z("wiki_events_scandal"),paragraphs:2,h_level:2,para_data:{1:[z("governor_media")],2:["8%",15,90]}});In(a,{name:"scandal_condition",template:"events",label:z("wiki_events_scandal"),paragraphs:1,h_level:2,para_data:{1:[z("governor_media")]}},e),In(a,{name:"scandal_examples",template:"events",label:z("wiki_events_scandal"),h_level:2,examples:[z("event_scandal0"),z("event_scandal1"),z("event_scandal2"),z("event_scandal3"),z("event_scandal4"),z("event_scandal5"),z("event_scandal6"),z("event_scandal7"),z("event_scandal8"),z("event_scandal9")]},e),Ln("add","major-events","scandal",z("wiki_events_scandal"))}{let e=In(a,{name:"spy",template:"events",label:z("wiki_events_spy"),paragraphs:1,h_level:2});In(a,{name:"spy_condition",template:"events",label:z("wiki_events_spy"),paragraphs:1,h_level:2},e),In(a,{name:"spy_examples",template:"events",label:z("wiki_events_spy"),h_level:2,examples:[z("event_spy",[Z(1)])]},e),Ln("add","major-events","spy",z("wiki_events_spy"))}{let e=In(a,{name:"mine_collapse",template:"events",label:z("wiki_events_mine_collapse"),paragraphs:1,h_level:2});In(a,{name:"mine_collapse_condition",template:"events",label:z("wiki_events_mine_collapse"),paragraphs:1,h_level:2},e),In(a,{name:"mine_collapse_examples",template:"events",label:z("wiki_events_mine_collapse"),h_level:2,examples:[z("event_mine_collapse")]},e),Ln("add","major-events","mine_collapse",z("wiki_events_mine_collapse"))}{let e=In(a,{name:"m_curious",template:"events",label:z("wiki_events_m_curious"),paragraphs:6,break:[2,3,4,5,6],h_level:2,para_data:{2:[z("wiki_events_m_curious_para2_note1",[5e4.toLocaleString(),5e6.toLocaleString(),z("resource_Money_name")]),z("wiki_events_m_curious_para2_note1",[100,1e5.toLocaleString(),z("resource_Steel_name")]),z("wiki_events_m_curious_para2_note1",[250,1e6.toLocaleString(),z("resource_Alloy_name")]),z("wiki_events_m_curious_para2_note1",[100,25e4.toLocaleString(),z("resource_Adamantite_name")]),z("wiki_events_m_curious_para2_note1",[500,5e4.toLocaleString(),z("resource_Bolognium_name")]),z("wiki_events_m_curious_para2_note2",[1,z("resource_Soul_Gem_name")])],3:[10],4:[600,1200],5:["5%",200,600],6:[z("race_cath"),"10%",500,1e3]}});In(a,{name:"m_curious_condition",template:"events",label:z("wiki_events_m_curious"),paragraphs:1,h_level:2,para_data:{1:[z("trait_curious_name")]}},e),In(a,{name:"m_curious_examples",template:"events",label:z("wiki_events_m_curious"),h_level:2,examples:[z("event_m_curious0",[Ki[t.race.species].name,444015..toLocaleString(),z("resource_Alloy_name")]),z("event_m_curious1",[Ki[t.race.species].name]),z("event_m_curious2",[Ki[t.race.species].name]),z("event_m_curious3",[Ki[t.race.species].name]),z("event_m_curious4a",[z("race_cath")]),z("event_m_curious4b",[z("race_octigoran")])]},e),Ln("add","major-events","m_curious",z("wiki_events_m_curious"))}}(a);break;case"minor":!function(e){let a=Ln("create",e);{let e=In(a,{name:"minor_intro",template:"events",paragraphs:1,h_level:2});In(a,{name:"major_intro",template:"events",paragraphs:3,h_level:2,para_data:{1:[z("wiki_menu_minor"),850,71],2:[z("wiki_menu_minor")],3:[z("wiki_menu_minor")]}},e),Ln("add","minor-events","minor_intro",z("wiki_menu_intro"))}{let e=In(a,{name:"curious",template:"events",label:z("wiki_events_curious"),paragraphs:2,break:[2],h_level:2});In(a,{name:"curious_condition",template:"events",label:z("wiki_events_curious"),paragraphs:1,h_level:2,para_data:{1:[z("trait_curious_name")]}},e),In(a,{name:"curious_examples",template:"events",label:z("wiki_events_curious"),h_level:2,examples:[z("event_curious0",[Ki[t.race.species].name]),z("event_curious1",[Ki[t.race.species].name]),z("event_curious2",[Ki[t.race.species].name]),z("event_curious3",[Ki[t.race.species].name]),z("event_curious4",[Ki[t.race.species].name]),z("event_curious5",[Ki[t.race.species].name]),z("event_curious6",[Ki[t.race.species].name]),z("event_curious7",[Ki[t.race.species].name]),z("event_curious8",[Ki[t.race.species].name]),z("event_curious9",[Ki[t.race.species].name])]},e),Ln("add","minor-events","curious",z("wiki_events_curious"))}{let e=In(a,{name:"slave_escape",template:"events",label:z("wiki_events_slave_escape"),paragraphs:2,break:[2],h_level:2});In(a,{name:"slave_escape_condition",template:"events",label:z("wiki_events_slave_escape"),paragraphs:1,h_level:2,para_data:{1:[z("trait_slaver_name")]}},e),In(a,{name:"slave_escape_examples",template:"events",label:z("wiki_events_slave_escape"),h_level:2,examples:[z("event_slave_escape1"),z("event_slave_escape2"),z("event_slave_death4"),z("event_slave_none")]},e),Ln("add","minor-events","slave_escape",z("wiki_events_slave_escape"))}{let e=In(a,{name:"shooting_star",template:"events",label:z("wiki_events_shooting_star"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_shooting_star"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"shooting_star_examples",template:"events",label:z("wiki_events_shooting_star"),h_level:2,examples:[z("event_shooting_star")]},e),Ln("add","minor-events","shooting_star",z("wiki_events_shooting_star"))}{let e=In(a,{name:"tumbleweed",template:"events",label:z("wiki_events_tumbleweed"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_tumbleweed"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"tumbleweed_examples",template:"events",label:z("wiki_events_tumbleweed"),h_level:2,examples:[z("event_tumbleweed")]},e),Ln("add","minor-events","tumbleweed",z("wiki_events_tumbleweed"))}{let e=In(a,{name:"flashmob",template:"events",label:z("wiki_events_flashmob"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_flashmob"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"flashmob_examples",template:"events",label:z("wiki_events_flashmob"),h_level:2,examples:[z("event_flashmob")]},e),Ln("add","minor-events","flashmob",z("wiki_events_flashmob"))}{let e=In(a,{name:"heatwave",template:"events",label:z("wiki_events_heatwave"),paragraphs:1,h_level:2,para_data:{1:[z("hot")]}});In(a,{name:"heatwave_condition",template:"events",label:z("wiki_events_heatwave"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club"),z("evo_challenge_cataclysm"),z("hot")]}},e),In(a,{name:"heatwave_examples",template:"events",label:z("wiki_events_heatwave"),h_level:2,examples:[z("event_heatwave")]},e),Ln("add","minor-events","heatwave",z("wiki_events_heatwave"))}{let e=In(a,{name:"coldsnap",template:"events",label:z("wiki_events_coldsnap"),paragraphs:1,h_level:2,para_data:{1:[z("cold")]}});In(a,{name:"coldsnap_condition",template:"events",label:z("wiki_events_coldsnap"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club"),z("evo_challenge_cataclysm"),z("cold")]}},e),In(a,{name:"coldsnap_examples",template:"events",label:z("wiki_events_coldsnap"),h_level:2,examples:[z("event_coldsnap")]},e),Ln("add","minor-events","coldsnap",z("wiki_events_coldsnap"))}{let e=In(a,{name:"cucumber",template:"events",label:z("wiki_events_cucumber"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_cucumber"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"cucumber_examples",template:"events",label:z("wiki_events_cucumber"),h_level:2,examples:[z("event_cucumber")]},e),Ln("add","minor-events","cucumber",z("wiki_events_cucumber"))}{let e=In(a,{name:"planking",template:"events",label:z("wiki_events_planking"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_planking"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"planking_examples",template:"events",label:z("wiki_events_planking"),h_level:2,examples:[z("event_planking")]},e),Ln("add","minor-events","planking",z("wiki_events_planking"))}{let e=In(a,{name:"furryfish",template:"events",label:z("wiki_events_furryfish"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_furryfish"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"furryfish_examples",template:"events",label:z("wiki_events_furryfish"),h_level:2,examples:[z("event_furryfish")]},e),Ln("add","minor-events","furryfish",z("wiki_events_furryfish"))}{let e=In(a,{name:"meteor_shower",template:"events",label:z("wiki_events_meteor_shower"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_meteor_shower"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"meteor_shower_examples",template:"events",label:z("wiki_events_meteor_shower"),h_level:2,examples:[z("event_meteor_shower")]},e),Ln("add","minor-events","meteor_shower",z("wiki_events_meteor_shower"))}{let e=In(a,{name:"hum",template:"events",label:z("wiki_events_hum"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_hum"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"hum_examples",template:"events",label:z("wiki_events_hum"),h_level:2,examples:[z("event_hum")]},e),Ln("add","minor-events","hum",z("wiki_events_hum"))}{let e=In(a,{name:"bloodrain",template:"events",label:z("wiki_events_bloodrain"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_bloodrain"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"bloodrain_examples",template:"events",label:z("wiki_events_bloodrain"),h_level:2,examples:[z("event_bloodrain")]},e),Ln("add","minor-events","bloodrain",z("wiki_events_bloodrain"))}{let e=In(a,{name:"haunting",template:"events",label:z("wiki_events_haunting"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_haunting"),paragraphs:1,h_level:2,para_data:{1:[z("tech_science")]}},e),In(a,{name:"haunting_examples",template:"events",label:z("wiki_events_haunting"),h_level:2,examples:[z("event_haunting")]},e),Ln("add","minor-events","haunting",z("wiki_events_haunting"))}{let e=In(a,{name:"mothman",template:"events",label:z("wiki_events_mothman"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_mothman"),paragraphs:1,h_level:2,para_data:{1:[z("tech_science")]}},e),In(a,{name:"mothman_examples",template:"events",label:z("wiki_events_mothman"),h_level:2,examples:[z("event_mothman")]},e),Ln("add","minor-events","mothman",z("wiki_events_mothman"))}{let e=In(a,{name:"dejavu",template:"events",label:z("wiki_events_dejavu"),paragraphs:1,h_level:2});In(a,{name:"dejavu_condition",template:"events",label:z("wiki_events_dejavu"),paragraphs:1,h_level:2},e),In(a,{name:"dejavu_examples",template:"events",label:z("wiki_events_dejavu"),h_level:2,examples:[z("event_dejavu")]},e),Ln("add","minor-events","dejavu",z("wiki_events_dejavu"))}{let e=In(a,{name:"dollar",template:"events",label:z("wiki_events_dollar"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_dollar"),paragraphs:1,h_level:2,para_data:{1:[z("tech_currency")]}},e),In(a,{name:"dollar_examples",template:"events",label:z("wiki_events_dollar"),h_level:2,examples:[z("event_dollar",[6])]},e),Ln("add","minor-events","dollar",z("wiki_events_dollar"))}{let e=In(a,{name:"pickpocket",template:"events",label:z("wiki_events_pickpocket"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_pickpocket"),paragraphs:1,h_level:2,para_data:{1:[z("tech_currency")]}},e),In(a,{name:"pickpocket_examples",template:"events",label:z("wiki_events_pickpocket"),h_level:2,examples:[z("event_pickpocket",[9])]},e),Ln("add","minor-events","pickpocket",z("wiki_events_pickpocket"))}{let e=In(a,{name:"bird",template:"events",label:z("wiki_events_bird"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_bird"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"bird_examples",template:"events",label:z("wiki_events_bird"),h_level:2,examples:[z("event_bird")]},e),Ln("add","minor-events","bird",z("wiki_events_bird"))}{let e=In(a,{name:"contest",template:"events",label:z("wiki_events_contest"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_contest"),paragraphs:1,h_level:2,para_data:{1:[z("tech_science")]}},e),In(a,{name:"contest_examples",template:"events",label:z("wiki_events_contest"),h_level:2,examples:[z("event_contest",[z("event_contest_place0"),z("event_contest_type0")]),z("event_contest",[z("event_contest_place1"),z("event_contest_type1")]),z("event_contest",[z("event_contest_place2"),z("event_contest_type2")]),z("event_contest",[z("event_contest_place0"),z("event_contest_type3")]),z("event_contest",[z("event_contest_place1"),z("event_contest_type4")]),z("event_contest",[z("event_contest_place2"),z("event_contest_type5")]),z("event_contest",[z("event_contest_place0"),z("event_contest_type6")]),z("event_contest",[z("event_contest_place1"),z("event_contest_type7")]),z("event_contest",[z("event_contest_place2"),z("event_contest_type8")]),z("event_contest",[z("event_contest_place0"),z("event_contest_type9")])]},e),Ln("add","minor-events","contest",z("wiki_events_contest"))}{let e=In(a,{name:"cloud",template:"events",label:z("wiki_events_cloud"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_cloud"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"cloud_examples",template:"events",label:z("wiki_events_cloud"),h_level:2,examples:[z("event_cloud",[z("event_cloud_type0")]),z("event_cloud",[z("event_cloud_type1")]),z("event_cloud",[z("event_cloud_type2")]),z("event_cloud",[z("event_cloud_type3")]),z("event_cloud",[z("event_cloud_type4")]),z("event_cloud",[z("event_cloud_type5")]),z("event_cloud",[z("event_cloud_type6")]),z("event_cloud",[z("event_cloud_type7")]),z("event_cloud",[z("event_cloud_type8")]),z("event_cloud",[z("event_cloud_type9")]),z("event_cloud",[z("event_cloud_type10")])]},e),Ln("add","minor-events","cloud",z("wiki_events_cloud"))}{let e=In(a,{name:"dark_cloud",template:"events",label:z("wiki_events_dark_cloud"),paragraphs:1,h_level:2,para_data:{1:[z("rain"),z("snow")]}});In(a,{name:"dark_cloud_condition",template:"events",label:z("wiki_events_dark_cloud"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club"),z("evo_challenge_cataclysm"),z("rain"),z("snow")]}},e),In(a,{name:"dark_cloud_examples",template:"events",label:z("wiki_events_dark_cloud"),h_level:2,examples:[z("event_dark_cloud")]},e),Ln("add","minor-events","dark_cloud",z("wiki_events_dark_cloud"))}{let e=In(a,{name:"gloom",template:"events",label:z("wiki_events_gloom"),paragraphs:1,h_level:2,para_data:{1:[z("cloudy")]}});In(a,{name:"gloom_condition",template:"events",label:z("wiki_events_gloom"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club"),z("evo_challenge_cataclysm"),z("cloudy")]}},e),In(a,{name:"gloom_examples",template:"events",label:z("wiki_events_gloom"),h_level:2,examples:[z("event_gloom")]},e),Ln("add","minor-events","gloom",z("wiki_events_gloom"))}{let e=In(a,{name:"tracks",template:"events",label:z("wiki_events_tracks"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_tracks"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"tracks_examples",template:"events",label:z("wiki_events_tracks"),h_level:2,examples:[z("event_tracks")]},e),Ln("add","minor-events","tracks",z("wiki_events_tracks"))}{let e=In(a,{name:"hoax",template:"events",label:z("wiki_events_hoax"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_hoax"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"hoax_examples",template:"events",label:z("wiki_events_hoax"),h_level:2,examples:[z("event_hoax")]},e),Ln("add","minor-events","hoax",z("wiki_events_hoax"))}{let e=In(a,{name:"burial",template:"events",label:z("wiki_events_burial"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_burial"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"burial_examples",template:"events",label:z("wiki_events_burial"),h_level:2,examples:[z("event_burial")]},e),Ln("add","minor-events","burial",z("wiki_events_burial"))}{let e=In(a,{name:"artifacts",template:"events",label:z("wiki_events_artifacts"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_artifacts"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"artifacts_examples",template:"events",label:z("wiki_events_artifacts"),h_level:2,examples:[z("event_artifacts")]},e),Ln("add","minor-events","artifacts",z("wiki_events_artifacts"))}{let e=In(a,{name:"parade",template:"events",label:z("wiki_events_parade"),paragraphs:1,h_level:2});In(a,{name:"parade_condition",template:"events",label:z("wiki_events_parade"),paragraphs:1,h_level:2},e),In(a,{name:"parade_examples",template:"events",label:z("wiki_events_parade"),h_level:2,examples:[z("event_parade")]},e),Ln("add","minor-events","parade",z("wiki_events_parade"))}{let e=In(a,{name:"crop_circle",template:"events",label:z("wiki_events_crop_circle"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_crop_circle"),paragraphs:1,h_level:2,para_data:{1:[z("tech_agriculture")]}},e),In(a,{name:"crop_circle_examples",template:"events",label:z("wiki_events_crop_circle"),h_level:2,examples:[z("event_crop_circle")]},e),Ln("add","minor-events","crop_circle",z("wiki_events_crop_circle"))}{let e=In(a,{name:"llama",template:"events",label:z("wiki_events_llama"),paragraphs:1,h_level:2,para_data:{1:[25,100]}});In(a,{name:"tech",template:"events",label:z("wiki_events_llama"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"llama_condition",template:"events",label:z("wiki_events_llama"),paragraphs:1,h_level:2,para_data:{1:[z("trait_carnivore_name"),z("trait_soul_eater_name"),z("trait_detritivore_name"),z("trait_artifical_name")]},data_link:{1:["wiki.html#traits-species-genus_carnivore","wiki.html#traits-species-special_soul_eater","wiki.html#traits-species-genus_detritivore","wiki.html#traits-species-genus_artifical"]}},e),In(a,{name:"llama_examples",template:"events",label:z("wiki_events_llama"),h_level:2,examples:[z("event_llama",[51])]},e),Ln("add","minor-events","llama",z("wiki_events_llama"))}{let e=In(a,{name:"cat",template:"events",label:z("wiki_events_cat"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_cat"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"cat_examples",template:"events",label:z("wiki_events_cat"),h_level:2,examples:[z("event_cat")]},e),Ln("add","minor-events","cat",z("wiki_events_cat"))}{let e=In(a,{name:"omen",template:"events",label:z("wiki_events_omen"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_omen"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"omen_examples",template:"events",label:z("wiki_events_omen"),h_level:2,examples:[z("event_omen")]},e),Ln("add","minor-events","omen",z("wiki_events_omen"))}{let e=In(a,{name:"theft",template:"events",label:z("wiki_events_theft"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_theft"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"theft_examples",template:"events",label:z("wiki_events_theft"),h_level:2,examples:[z("event_theft",[z("event_theft_type0")]),z("event_theft",[z("event_theft_type1")]),z("event_theft",[z("event_theft_type2")]),z("event_theft",[z("event_theft_type3")]),z("event_theft",[z("event_theft_type4")]),z("event_theft",[z("event_theft_type5")]),z("event_theft",[z("event_theft_type6")]),z("event_theft",[z("event_theft_type7")]),z("event_theft",[z("event_theft_type8")]),z("event_theft",[z("event_theft_type9")])]},e),Ln("add","minor-events","theft",z("wiki_events_theft"))}{let e=In(a,{name:"compass",template:"events",label:z("wiki_events_compass"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_compass"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mining")]}},e),In(a,{name:"compass_examples",template:"events",label:z("wiki_events_compass"),h_level:2,examples:[z("event_compass")]},e),Ln("add","minor-events","compass",z("wiki_events_compass"))}{let e=In(a,{name:"bone",template:"events",label:z("wiki_events_bone"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_bone"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"bone_examples",template:"events",label:z("wiki_events_bone"),h_level:2,examples:[z("event_bone")]},e),Ln("add","minor-events","bone",z("wiki_events_bone"))}{let e=In(a,{name:"delicacy",template:"events",label:z("wiki_events_delicacy"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_delicacy"),paragraphs:1,h_level:2,para_data:{1:[z("tech_mad_science")]}},e),In(a,{name:"delicacy_examples",template:"events",label:z("wiki_events_delicacy"),h_level:2,examples:[z("event_delicacy")]},e),Ln("add","minor-events","delicacy",z("wiki_events_delicacy"))}{let e=In(a,{name:"prank",template:"events",label:z("wiki_events_prank"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_prank"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"prank_examples",template:"events",label:z("wiki_events_prank"),h_level:2,examples:[z("event_prank",[z("event_prank_type0")]),z("event_prank",[z("event_prank_type1")]),z("event_prank",[z("event_prank_type2")]),z("event_prank",[z("event_prank_type3")]),z("event_prank",[z("event_prank_type4")]),z("event_prank",[z("event_prank_type5")]),z("event_prank",[z("event_prank_type6")]),z("event_prank",[z("event_prank_type7")]),z("event_prank",[z("event_prank_type8")]),z("event_prank",[z("event_prank_type9")])]},e),Ln("add","minor-events","prank",z("wiki_events_prank"))}{let e=In(a,{name:"graffiti",template:"events",label:z("wiki_events_graffiti"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_graffiti"),paragraphs:1,h_level:2,para_data:{1:[z("tech_science")]}},e),In(a,{name:"graffiti_examples",template:"events",label:z("wiki_events_graffiti"),h_level:2,examples:[z("event_graffiti")]},e),Ln("add","minor-events","graffiti",z("wiki_events_graffiti"))}{let e=In(a,{name:"soul",template:"events",label:z("wiki_events_soul"),paragraphs:1,h_level:2});In(a,{name:"soul_condition",template:"events",label:z("wiki_events_soul"),paragraphs:1,h_level:2,para_data:{1:[z("trait_soul_eater_name")]}},e),In(a,{name:"soul_examples",template:"events",label:z("wiki_events_soul"),h_level:2,examples:[z("event_soul")]},e),Ln("add","minor-events","soul",z("wiki_events_soul"))}{let e=t.stats.hasOwnProperty("reset")?t.stats.reset+1:1,r=+(e/(e+10)*11).toFixed(2),i=In(a,{name:"cheese",template:"events",label:z("wiki_events_cheese"),paragraphs:1,h_level:2,para_data:{1:[`${r}%`,10,9+e]}});In(a,{name:"tech",template:"events",label:z("wiki_events_cheese"),paragraphs:1,h_level:2,para_data:{1:[Pr()]}},i),In(a,{name:"cheese_examples",template:"events",label:z("wiki_events_cheese"),h_level:2,examples:[z("event_cheese")]},i),Ln("add","minor-events","cheese",z("wiki_events_cheese"))}{let e=In(a,{name:"tremor",template:"events",label:z("wiki_events_tremor"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_tremor"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"tremor_examples",template:"events",label:z("wiki_events_tremor"),h_level:2,examples:[z("event_tremor")]},e),Ln("add","minor-events","tremor",z("wiki_events_tremor"))}{let e=In(a,{name:"rumor",template:"events",label:z("wiki_events_rumor"),paragraphs:1,h_level:2});In(a,{name:"tech",template:"events",label:z("wiki_events_rumor"),paragraphs:1,h_level:2,para_data:{1:[z("tech_club")]}},e),In(a,{name:"rumor_examples",template:"events",label:z("wiki_events_rumor"),h_level:2,examples:[z("event_rumor",[z("event_rumor_type0")]),z("event_rumor",[z("event_rumor_type1")]),z("event_rumor",[z("event_rumor_type2")]),z("event_rumor",[z("event_rumor_type3")]),z("event_rumor",[z("event_rumor_type4")]),z("event_rumor",[z("event_rumor_type5")]),z("event_rumor",[z("event_rumor_type6")]),z("event_rumor",[z("event_rumor_type7")]),z("event_rumor",[z("event_rumor_type8")]),z("event_rumor",[z("event_rumor_type9")])]},e),Ln("add","minor-events","rumor",z("wiki_events_rumor"))}}(a);break;case"progress":!function(e){let a=Ln("create",e);In(a,{name:"progress_intro",template:"events",paragraphs:3,h_level:2}),Ln("add","progress-events","progress_intro",z("wiki_menu_intro"));{let e=In(a,{name:"steel",template:"events",label:z("wiki_events_steel"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("resource_Steel_name")],2:["0.08%"]}});In(a,{name:"steel_condition",template:"events",label:z("wiki_events_steel"),paragraphs:1,h_level:2,para_data:{1:[z("resource_Steel_name")]},examples:[z("steel_sample")]},e),Ln("add","progress-events","steel",z("wiki_events_steel"))}In(a,{name:"elerium",template:"events",label:z("wiki_events_elerium"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("resource_Elerium_name"),z("tech_elerium_mining")],2:[z("space_belt_iron_ship_title"),z("space_belt_iridium_ship_title"),"0.4%"]},data_link:{1:[!1,"wiki.html#deep_space-tech-elerium_mining"],2:["wiki.html#space-structures-iron_ship","wiki.html#space-structures-iridium_ship"]},examples:[z("discover_elerium")]}),Ln("add","progress-events","elerium",z("wiki_events_elerium")),In(a,{name:"oil",template:"events",label:z("wiki_events_oil"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("resource_Oil_name"),Kn("gas_moon"),z("space_gas_moon_oil_extractor_title")],2:[z("space_gas_moon_outpost_title"),"1%"]},data_link:{1:[!1,!1,"wiki.html#space-structures-oil_extractor"],2:["wiki.html#space-structures-outpost"]},examples:[z("discover_oil",[Kn("gas_moon")])]}),Ln("add","progress-events","oil",z("wiki_events_oil"));{let e=In(a,{name:"pit",template:"events",label:z("wiki_events_pit"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("portal_pit_name"),z("tab_portal"),z("portal_pit_mission_title")]},data_link:{1:[!1,!1,"wiki.html#hell-structures-pit_mission"]}});In(a,{name:"pit_condition",template:"events",label:z("wiki_events_pit"),paragraphs:1,h_level:2,para_data:{1:[1e6.toLocaleString(),z("galaxy_telemetry_beacon")]},data_link:{1:[!1,"wiki.html#intergalactic-structures-telemetry_beacon"]},examples:[z("portal_hell_pit_found")]},e),Ln("add","progress-events","pit",z("wiki_events_pit"))}{let e=In(a,{name:"alien_encounter",template:"events",label:z("wiki_events_alien_encounter"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("galaxy_scout_ship"),z("tech_xeno_linguistics"),z("galaxy_corvette_ship")],2:["10%"]},data_link:{1:["wiki.html#intergalactic-structures-scout_ship","wiki.html#intergalactic-tech-xeno_linguistics","wiki.html#intergalactic-tech-corvette_ship"]}});In(a,{name:"alien_encounter_condition",template:"events",label:z("wiki_events_alien_encounter"),paragraphs:1,h_level:2,para_data:{1:[z("galaxy_scout_ship")]},examples:[z("galaxy_encounter")]},e),Ln("add","progress-events","alien_encounter",z("wiki_events_alien_encounter"))}{let e=In(a,{name:"piracy",template:"events",label:z("wiki_events_piracy"),paragraphs:3,break:[3],h_level:2,para_data:{2:[z("galaxy_piracy")],3:["20%"]},data_link:{2:["wiki.html#mechanics-gameplay-piracy"]}});In(a,{name:"piracy_condition",template:"events",label:z("wiki_events_piracy"),paragraphs:1,h_level:2,para_data:{1:[z("galaxy_embassy")]},data_link:{1:["wiki.html#intergalactic-structures-embassy"]},examples:[z("galaxy_piracy_msg",[Ki[t.galaxy.hasOwnProperty("alien2")?t.galaxy.alien2.id:t.race.species].name])]},e),Ln("add","progress-events","piracy",z("wiki_events_piracy"))}In(a,{name:"alien_database",template:"events",label:z("wiki_events_alien_database"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("galaxy_scavenger"),z("tech_alien_database")],2:[z("galaxy_scavenger"),"2%"]},data_link:{1:["wiki.html#intergalactic-structures-scavenger"]},examples:[z("galaxy_scavenger_find")]}),Ln("add","progress-events","alien_database",z("wiki_events_alien_database"));{let e=In(a,{name:"corrupt_gem",template:"events",label:z("wiki_events_corrupt_gem"),paragraphs:4,break:[2],h_level:2,para_data:{1:[z("resource_Corrupt_Gem_name"),z("portal_soul_forge_title")],2:[z("resource_Soul_Gem_name"),z("portal_soul_forge_title"),z("portal_soul_attractor_title")],3:["1/(11-X)","X",z("portal_soul_attractor_title")],4:[9,z("portal_soul_attractor_title"),"9.09%",0,"50%"]},data_link:{1:[!1,"wiki.html#hell-structures-soul_forge"],2:[!1,!1,"wiki.html#hell-structures-soul_attractor"]}});In(a,{name:"corrupt_gem_condition",template:"events",label:z("wiki_events_corrupt_gem"),paragraphs:1,h_level:2,para_data:{1:[z("tech_metaphysics")]},data_link:{1:["wiki.html#intergalactic-tech-metaphysics"]},examples:[z("portal_corrupt_gem")]},e),Ln("add","progress-events","corrupt_gem",z("wiki_events_corrupt_gem"))}In(a,{name:"vault_find",template:"events",label:z("wiki_events_vault_find"),paragraphs:3,break:[2],h_level:2,para_data:{1:[z("job_archaeologist"),z("portal_vault_title"),z("portal_ruins_name")],2:[z("job_archaeologist"),"2.5%"],3:[z("job_archaeologist"),z("portal_ruins_supressed"),z("portal_ruins_name"),"0%","2.5%","100%"]},data_link:{1:[!1,"wiki.html#hell-structures-vault"]},examples:[z("portal_ruins_vault")]}),Ln("add","progress-events","vault_find",z("wiki_events_vault_find"));{let e=In(a,{name:"syndicate",template:"events",label:z("wiki_events_syndicate"),paragraphs:2,break:[2],h_level:2,para_data:{1:[z("tech_shipyard",[Kn("dwarf")])],2:["5%"]},data_link:{1:["wiki.html#solar-tp_tech-shipyard"]}});In(a,{name:"syndicate_condition",template:"events",label:z("wiki_events_syndicate"),paragraphs:1,h_level:2,para_data:{1:[z("tech_long_range_probes")]},data_link:{1:["wiki.html#solar-tp_tech-long_range_probes"]},examples:[z("outer_syndicate",[z("civics_gov5",[z("civics_gov_name1")])])]},e),Ln("add","progress-events","syndicate",z("wiki_events_syndicate"))}}(a);break;case"special":!function(e){let a=Ln("create",e);In(a,{name:"special_intro",template:"events",paragraphs:3,h_level:2,para_data:{3:[z("boring")]}}),Ln("add","special-events","special_intro",z("wiki_menu_intro"));{let e="crystal",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_friday_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="valentine",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:3,break:[2,3],h_level:2,para_data:{2:[z("feat_love_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="unlucky",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_leprechaun_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="fool",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_fool_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e=cn("easter");{let t="hopper",r=In(a,{name:t,template:"events",label:z(`wiki_events_${t}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_easter_name")]}});In(a,{name:`${t}_condition`,template:"events",label:z(`wiki_events_${t}`),paragraphs:2,break:[2],h_level:2,para_data:{1:[`${z(`month${e.date[0]}`)} ${e.date[1]}`]}},r),Ln("add","special-events",t,z(`wiki_events_${t}`))}{let r="egghunt",i=In(a,{name:r,template:"events",label:z(`wiki_events_${r}`),paragraphs:7,break:[2,3,4,6],h_level:2,para_data:{2:[z("feat_egghunt_name"),12,18],5:[z("trait_hyper_name"),z("trait_fast_growth_name"),z("trait_rainbow_name"),z("trait_optimistic_name")],7:[z("trait_cannibalize_name"),z("trait_rage_name"),z("trait_blood_thirst_name"),z("trait_sticky_name")]}}),s=["U2FsdGVkX1/PcdpekGFnkjSSCBa9yVo3z5xq3a2662iSlAA8yuaPEsK4Qyn5OSED","U2FsdGVkX180d8+Fl8mi96tY7KHkOWLkO0syi+BeZW47ga9AdJiBdbsksLaMTGvT","U2FsdGVkX19hHAatSiZiYe33Hx4u+bixNx4U7O4smhKVb/a+umB6MlIbgM3eE3UG","U2FsdGVkX188sIGEBwWHyzf0SkKQ027dzHZmkJp93FeXrXu70hD0KqYfoTxnbGqU","U2FsdGVkX18dLIKZyFStCpVKJrFAc36LF4uNcpuJd8CGU0yC1rPllsNfBHAhrfwT","U2FsdGVkX1/ZRiMKl3kG4PUQOx8bdgz7va6bLW3Gf5COBHAs7CMDITt7SDeIygvd","U2FsdGVkX19FZ4kZmquyj6NUTqo+AYS7U31mSik1W2Awdp5M6L1WlsG4Px8uUYUN","U2FsdGVkX1+9Eh/34O02cW0SuZg0rQYZnomSBjBQU4Q3VSU0y62ypmoJNjOb5Uix","U2FsdGVkX1+3qtRH9MVd1B8T+JP5DgnlER6u8P60vX/NVjLGuceG7DX+b2yPW3J5","U2FsdGVkX18JYj4R4QuZBpDdcsEjkYPAf3uNNIzu6Vs=","U2FsdGVkX1+Eq43UVbtPlveU6HqIU8PSHL8QH+FlUxWkhyB1S+QAVVM2z0OryeJd","U2FsdGVkX18brcDy1P4HEGkmTw5t19CgWEshDFRSByELjSG9MtvSdSBbj13JhYuG","U2FsdGVkX1/vr39YAfqKcFM7c8ed6Oi7lRrDYKDtfUJRKF3pcrIRAWc4FF/Tt5BjwaXOi0slDE9JmeIDifD2gw==","U2FsdGVkX19KtuHoWRLTz0wLH8D/fLoOriDsmk6agzT85xsAAXv26ILjSV2C8mpi","U2FsdGVkX18/Tyjq6czHYJKjJQPXcRCgqmZqu2AFmx2FddfQPzM+YkXXECLMVA+e","U2FsdGVkX19kn6Hj9vQq5JxU9dsKsu0U+qADHauwh7TPf1enfhF1VQamBs7VFuX5","U2FsdGVkX19ICmvq9eubXYyGpmRML9aqTzBZMRvvOWFMwp2IiJBUUpl4LgLJOwLqnEISPAepbrdrfJn8miQIgA==","U2FsdGVkX19P0vr33mSfkSTDVz7N3a59YF5Cc+/NMC0f1tT3fXJDLqZMi98gGOrv"],n=["U2FsdGVkX1+duY7hvIoeOGqas8WhBy8hojTLQ0OxadHBEDzOPwpc4K1Y6N+WyDah","U2FsdGVkX1+AQhvu619WY9xow4HmruRn5yJefuIkv3u7U6baVdV/mHLJfUaNmTE6","U2FsdGVkX1/whjtke2hryY9zWuV0MTzN2JKXaFyzwJXwtEx9+iLMbHkdVFwi6h63","U2FsdGVkX18FBXNUeu4NIIiy4Mmk++iyUIJKxFS/mZvAj98+eJR+SZj8xpXHTkia","U2FsdGVkX1/Imw6q6mixFM1BlgToue0NUqbCTHKuNZFHC1Vp7I934fUpj/xCFg33","U2FsdGVkX18h03LNWLTF59y343iStuLaS/0cgvLtKSMzm8UpzMVWBxwkGGSxDDPO","U2FsdGVkX18+W3R7IyisKi9TgzbkQ/636SJ7ubGsCx6Rz5GMxlTkbTVbOG6YFAC4Cle0TjI1riEzpGQtuCr6C+1mX3FdCLVz3oaGWqIajvI=","U2FsdGVkX18CjBzSHSIPZ07ZgvI6JgGiVIJE4ugYa2xWFeM1a/OnXrMT1sBpwmXwiHayBp1tdw83/4I55pGwpA==","U2FsdGVkX1+QWybO+rnrqxI23qXSKzevq0C/NPkX8/kd5h0xo20ozmxo4Pknui3G","U2FsdGVkX1//2GoF+3kVNPim1ThpVMgMCHEzSH0UZCrc4EIjktoxBC87gXddwhZR","U2FsdGVkX1/HQFE7BGTMIHN8G4pljsZlwtFaXHZh2U/VN4DD8lOL4OUYxnJUGr+g","U2FsdGVkX1/f1jFsIVKmxsXq85PuOj+fq+9WtYf1AZbPsuChio/XV6mpCxlTJz8X","U2FsdGVkX1+NRsztgBjDQeevIAYiHJ+X9dUERkDoYpLcvYAvWWzVvbjk4uq4dSMPEuykMqsZGGwvBtl1V0T+pO254xK8+5xWjZYnE9x6A+I=","U2FsdGVkX1//Crqk3ZOt8MHG/C4V91VEORQ3rQe4CEBHQhqfMD84PrEBZkwN7VpKvBgcg+2FsDknW+LDnNPIZA==","U2FsdGVkX1/bUrGTAmEkt6ukJKG8tIAIUVr4fnMFPsdamUtLJBGIG2dwQyaYywTD","U2FsdGVkX1/zl2y8RCXettY8EAPFE+cc/qImK4n5BocvEV2YvFKSyrOGxfLd3qBD","U2FsdGVkX19GszY2Yf01gUZnzs9F51vUgYu/FlRIPiFt9zasXhFP9tzX1en5/483mZeqi/uNRhV+zfoHd6qcYA==","U2FsdGVkX1+4syPwX9UT2KAsJj8uv43olf/GOTOudd/RbwnHsybitwYU4kk2ZVWx"];const c=(new Date).getFullYear(),o="egghunt";let l=`
                                    ${z("wiki_feat_egghunt_found")}
                                    `;l+='
                                    ';for(let a=1;a<=18;a++){let r=t.special.egg.hasOwnProperty(c)&&t.special.egg[c][`egg${a}`]?"has-text-success":"has-text-danger",i=t.special.egg.hasOwnProperty(c)&&t.special.egg[c][`egg${a}`]?"found":"missing",_=`${z("wiki_events_hint_avail")} ${z(`month${e.hintDate[0]}`)} ${e.hintDate[1]}`;e.hint&&(_=''+CryptoJS.AES.decrypt(s[a-1],o).toString(CryptoJS.enc.Utf8)+"");let d=`${z("wiki_events_sol_avail")} ${z(`month${e.solveDate[0]}`)} ${e.solveDate[1]}`;e.solve&&(d=`${z("wiki_events_reveal_sol")}`),l+=`
                                    ${z("wiki_feat_egghunt_num",[a])}${_}${d}
                                    `}l+="
                                    ",i.append(l),$(".eggsol").on("click",(function(){const e=$(this).attr("data-sol"),t=CryptoJS.AES.decrypt(e,o);$(this).html(t.toString(CryptoJS.enc.Utf8))})),In(a,{name:`${r}_condition`,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2,para_data:{1:[`${z(`month${e.date[0]}`)} ${e.date[1]}`,`${z(`month${e.endDate[0]}`)} ${e.endDate[1]}`]}},i),Ln("add","special-events",r,z(`wiki_events_${r}`))}}{let e="launch_day",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:3,break:[2,3],h_level:2,para_data:{2:[z("feat_launch_day_name")],3:["5%"]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e=t.hasOwnProperty("stats")?1e5+9e3*t.stats.reset:1e5;e>1e6&&(e=1e6);let r="solstice",i=In(a,{name:r,template:"events",label:z(`wiki_events_${r}`),paragraphs:4,break:[2,3,4],h_level:2,para_data:{1:[e.toLocaleString(),z(`wiki_events_${r}`)],2:[z("feat_solstice_name")]}});In(a,{name:`${r}_condition`,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2},i),Ln("add","special-events",r,z(`wiki_events_${r}`))}{let e=t.hasOwnProperty("stats")?1e5+9e3*t.stats.reset:1e5;e>1e6&&(e=1e6);let r="firework",i=In(a,{name:r,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_firework_name")]}});In(a,{name:`${r}_condition`,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2},i),Ln("add","special-events",r,z(`wiki_events_${r}`))}{let e="halloween",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2,para_data:{2:[z("feat_boo_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e=cn("halloween"),r="trickortreat",i=In(a,{name:r,template:"events",label:z(`wiki_events_${r}`),paragraphs:3,break:[2,3],h_level:2,para_data:{2:[z("feat_trickortreat_name"),12]}}),s=["U2FsdGVkX1/PDiFXguD51NL4kEt4e9qRJwl5IKNCQE9vI3XAoH5gDW28r2V4O5GY","U2FsdGVkX18xhhpvSSA7YALgn1lm1e+GylSzgVdoTnLXMzPLL1knLlINAS8l5ECGfvjo6CDFYnuvqaw/8BugAw==","U2FsdGVkX18g9cYmSZKe/VjFeCjuODnwnD+i+2ShpdeMI4uIIzbllcQFIWJaQw+EvsDu5DFBNCEuFOsWRFVMyA==","U2FsdGVkX1+nD+SyHpi39fhqppxDiF+UhJh3w0dhZ4IxuC1s3h0gTrgBI7IxVLrQ","U2FsdGVkX1+OfTMTHGhIpqmihvW7fMCt0q+bLWqhd7Z0Cj31jNUqmvBcxb6HzbGc4mL/msBX6PO5zpb4pBUzwA==","U2FsdGVkX1+hC03MwAyWdqH6ODAGNbgm7CRgC+0Wfreja2JZX7oPwYhPmfQXzn1RfeIncnkRTmdXGMqQ/mq2GQ==","U2FsdGVkX18cU5HWOtwNhFSnlxBHxpu5XEJBFj3EhtzU/PLXxynq5Rq9YGl23QNr"],n=["U2FsdGVkX1/bQrTdTtuTtXbxmJvxhHdsacfjyPKgyzXzthWNTsjaxqcCKjwjqCyG","U2FsdGVkX19tP6ZlSqvfdg6qaoOceA6978unLN8j9VIm5LUJSHUZm77zK1i1rWq3","U2FsdGVkX18Ex9HXV1+h+DIdFBxpNPI4Gl0E0EwOFbpyncN5gEfS8fWURvPT11S66x4swlZjnntbhMvDG+4SWg==","U2FsdGVkX1+xyixviw9PD/sRskoRG9owodNkZlwcAMSzQXe2PdAJPLwEBV9knjgGg11ws2eEBHXj7Y5j5SS7br+Uehaaj0MViyfxYdsZOEQ=","U2FsdGVkX18+2YEr0TG80mQY483i7yOr+Qnh66mOKEviX0ElRHI9VCha9TG+no1r","U2FsdGVkX1/Vuthb9MYQT02lO0ngkSI4f1tbvrrCwtVQiUTSIaVgDHVYYcIgfSl3WfiRhwGJWeP/6w+i7FEqaA==","U2FsdGVkX1/3Zbp0Tlqh/n5TKvOJEIuaf9/DcDFlDz1s2Tb+qbUS1GmPTzpP3xLu"],c=["U2FsdGVkX18m9z0oToDhhhmI0ugH5ykCrV1z64upZad/LXRYaFAyDT+O15+BXmJUKv7yY4YiBS6SYc65LJQjwEkMY5orIcyusiXtY9xnpRY=","U2FsdGVkX18eejrZNi9yF98CBO4KWjBLzo8HTBagKST0kjPmH48UuPWKG7Y3qyfeUyAFuDBnNRgdbgXXcWVPTE+3tbqcRiqAUZF8iLhXbmY=","U2FsdGVkX1/RKcVkvhY8bsGcXAQX3xJH4Ns/tUctQzK58oI9LJBxzIDyOHlPatn49avqw8r5lEmWyJOL2wyUjUPlYR/C9CjtO8t8oBW4ymWZRi66Ia0z1tMRHZyamonp","U2FsdGVkX18fvaoGr3U+o/m+xJLnbmVKJ1/GjNERP1ZDotBG7lD7vCtB1XyrCV0CvZXI9WK3r+FLD4rc7ZsLav77MTvQY+3pmwTYB841IxkUGCRE2mQYcr01xtxOPxMBMppChSZ8KJFgzfLhxL2rog==","U2FsdGVkX18MRMhu9I4km+hryh9dnvVBSkHdUPBgyHnKLsRB8PxpcJSFNq9b0plJ","U2FsdGVkX18IDZ0hUGT3xuDSi9EVacctj7h0BThWEgzIovJAieOvqXg/0wrZWHXQvyyVMsQtOdBls2nDjryxiw==","U2FsdGVkX1891SskU89HRmZPzhBcScrDGfGpJsp8F1qgVnsuON0h6WL69wEF9/uEpRi393mOXOrubNYVFzRgjwqERT3G/f6u/4bWXGSLpS8="],o=["U2FsdGVkX19wIpvvED4RfWp5UAJfJvmnyhdkqsfr3BlVH5YEdjGNy4mcTvuvuY/92b6F3aQJHx0vunDJ64hcezPUAM5P+E/iROMQoMDCTJwwni6SRCpJggAHSOBTovW0piVAnyt6WHsjiAmVQVo8Og==","U2FsdGVkX1+bLPNq0l72utbOUTZ+JAXIUcGrrXVneoHD/GTbFy4jqDcU++SxaFih2aKODyZx3/SPbm0pd4JIQlu3xgl/demBDPj7TRbatEOM7aTBJhke5jwSYuIPTwWm8eyO0FINhZqO94pV4BFmcYv7b1lkzFgiLEOX/5kV/qE=","U2FsdGVkX1/QQZqQ4S2CvR3IQFL5D1pWbqrntie8JAuZrYUIQoke13j6xzI3A2KVG3lE+IZZo6Ktn2zKJ8diaroUUB/CIP0DvewzzbNj7XT3d9G456ELSMjjgb8pKc586Mq661bEjCqm+Tz2DoMLtnzMaVIXPhqBBFutt2U7JwERvNiwBkX2YhyOD3QO/tcPmwKzLJ+cYjIDSEHeCVl/yeistKb5pQbrmPH4wHAKbVQNaiaOvIjee0wqttzpmcnNgx4axIi2FAqPpT2s1hHAmhUmeV0HKDxYQWgfntqRhe/k4ar1vrZ2QdhLozqDe35S","U2FsdGVkX1+Z3/SLqEmoDq377QCt49UMTneD9zo6FqTfFOab0SWGG8ioBZ1z+/v422HygjnuwD341scmcTuA/4Pz9APy3FQcCqA5Fw4hDed+LvjrecqEZogyCw1WVaCItGXZW9+TXM0/y6p7VXvuyw==","U2FsdGVkX19CLOS3ivLPeqIYtjSBdW1WT4UFvJjNDto6jy9751Q73OZF2JQlhgKyayhswWuEk+JGbYwLbDbWhJgZUR/R9hYJnw8/Wcay4eM=","U2FsdGVkX19Pm5I9mqzijXCNM3dk4ut0IDPpownMePohkcfE6jsuLA0dgzv9vp5tjEVPaUD/bqMgEzsD9svhOEJd+zlslkqIsBee6EJTO/4=","U2FsdGVkX19TcqGI2bk6XYN40buKCGWH58AjMFDNE/jawAK+II3s6TvoVCcXbZsKzLF2++aeUgq6Ag+TysbSf5/T3IHeqQQnjFGIkkzlmMJH9wROKLirkPSzsw8O6J1J"];const l=(new Date).getFullYear(),_="trickortreat";let d=`
                                    ${z("wiki_feat_trick_found")}
                                    `;d+='
                                    ';for(let a=1;a<=s.length;a++){let r=t.special.trick.hasOwnProperty(l)&&t.special.trick[l][`treat${a}`]?"has-text-success":"has-text-danger",i=t.special.trick.hasOwnProperty(l)&&t.special.trick[l][`treat${a}`]?"found":"missing",c=`${z("wiki_events_hint_avail")} ${z(`month${e.hintDate[0]}`)} ${e.hintDate[1]}`;e.hint&&(c=''+CryptoJS.AES.decrypt(s[a-1],_).toString(CryptoJS.enc.Utf8)+""),d+=`
                                    ${z("wiki_feat_treat_num",[a])}${c}
                                    `;let o=`${z("wiki_events_sol_avail")} ${z(`month${e.solveDate[0]}`)} ${e.solveDate[1]}`;e.solve&&(o=`${z("wiki_events_reveal_sol")}`),d+=`
                                    ${o}
                                    `}d+="
                                    ",i.append(d);let p=`
                                    ${z("wiki_feat_treat_found")}
                                    `;p+='
                                    ';for(let a=1;a<=c.length;a++){let r=t.special.trick.hasOwnProperty(l)&&t.special.trick[l][`trick${a}`]?"has-text-success":"has-text-danger",i=t.special.trick.hasOwnProperty(l)&&t.special.trick[l][`trick${a}`]?"found":"missing",s=`${z("wiki_events_hint_avail")} ${z(`month${e.hintDate[0]}`)} ${e.hintDate[1]}`;e.hint&&(s=''+CryptoJS.AES.decrypt(c[a-1],_).toString(CryptoJS.enc.Utf8)+""),p+=`
                                    ${z("wiki_feat_trick_num",[a])}${s}
                                    `;let n=`${z("wiki_events_sol_avail")} ${z(`month${e.solveDate[0]}`)} ${e.solveDate[1]}`;e.solve&&(n=`${z("wiki_events_reveal_sol")}`),p+=`
                                    ${n}
                                    `}p+="
                                    ",i.append(p),$(".totsol").on("click",(function(){const e=$(this).attr("data-sol"),t=CryptoJS.AES.decrypt(e,_);$(this).html(t.toString(CryptoJS.enc.Utf8))})),In(a,{name:`${r}_condition`,template:"events",label:z(`wiki_events_${r}`),paragraphs:2,break:[2],h_level:2,para_data:{1:[`${z(`month${e.date[0]}`)} ${e.date[1]}`,`${z(`month${e.endDate[0]}`)} ${e.endDate[1]}`]}},i),Ln("add","special-events",r,z(`wiki_events_${r}`))}{let e="turkey",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:3,break:[2,3],h_level:2,para_data:{2:[z("feat_gobble_gobble_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="festive",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:1,h_level:2});["elven","centaur","capybara","wendigo","yeti","entish"].forEach((function(a){In(t,{name:a,template:`events_${e}`,label:z(`wiki_events_${e}`),paragraphs:2,h_level:0,para_data:{1:[z(`race_${a}`)]}})})),In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:2,break:[2],h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}{let e="xmas",t=In(a,{name:e,template:"events",label:z(`wiki_events_${e}`),paragraphs:6,break:[2,3,4,5,6],h_level:2,para_data:{2:[z("feat_xmas_name")]}});In(a,{name:`${e}_condition`,template:"events",label:z(`wiki_events_${e}`),paragraphs:1,h_level:2},t),Ln("add","special-events",e,z(`wiki_events_${e}`))}}(a)}})(r),Cc(a,r,i);break;case"species":"planets"===r?Gn():function(e){let a=$("#content");switch(Ss(a),e){case"races":!function(e){e=Ln("create",e);let a=[];Object.keys(Ki).forEach((function(r){if("custom"===r&&!t.custom.hasOwnProperty("race0")||"protoplasm"===r)return;let i=$(`
                                    `);e.append(i),i.append(`

                                    ${Ki[r].name}

                                    ${z(`genelab_genus_${Ki[r].type}`)}
                                    `),i.append(`
                                    ${"string"==typeof Ki[r].desc?Ki[r].desc:Ki[r].desc()}
                                    `);let s=[],n=function(e){const t=new Date;let a=on();switch(e){case"wolven":return a.active?[{t:"hyper",r:1},{t:"fast_growth",r:1},{t:"rainbow",r:1},{t:"optimistic",r:1}]:[];case"vulpine":return a.active?[{t:"cannibalize",r:1},{t:"rage",r:1},{t:"blood_thirst",r:1},{t:"sticky",r:1}]:[];case"elven":return 11===t.getMonth()&&t.getDate()>=17?[{t:"slaver",r:2},{t:"resourceful",r:.5},{t:"small",r:.25}]:[];case"capybara":return 11===t.getMonth()&&t.getDate()>=17?[{t:"beast_of_burden",r:1},{t:"pack_rat",r:.5},{t:"musical",r:.25}]:[];case"centaur":return 11===t.getMonth()&&t.getDate()>=17?[{t:"beast_of_burden",r:1},{t:"curious",r:.5},{t:"blissful",r:.25}]:[];case"wendigo":return 11===t.getMonth()&&t.getDate()>=17?[{t:"immoral",r:3},{t:"cannibalize",r:.5},{t:"claws",r:.25}]:[];case"yeti":return 11===t.getMonth()&&t.getDate()>=17?[{t:"scavenger",r:3},{t:"regenerative",r:.5},{t:"musical",r:.25}]:[];case"entish":return 11===t.getMonth()&&t.getDate()>=17?[{t:"photosynth",r:3},{t:"optimistic",r:.5},{t:"armored",r:.25}]:[];default:return[]}}(r),c=$('
                                    ');Object.keys(Li[Ki[r].type]).sort().forEach((function(e){let t=`raceTrait${r}${e}`,a=Ki[r].fanaticism===e?"danger":"caution";c.append(`${Ei[e].name}`),s.push({t:e,r:1})})),Object.keys(Ki[r].traits).sort().forEach((function(e){let t=`raceTrait${r}${e}`,a=Ki[r].fanaticism===e?"danger":"info";c.append(`${Ei[e].name}`),s.push({t:e,r:Ki[r].traits[e]})}));for(let e=0;e${Ei[n[e].t].name}`),s.push(n[e])}i.append(c),a.push(r),ls(`genus${r}`,$(`
                                    ${z(`genelab_genus_${Ki[r].type}_desc`)}
                                    `),{wide:!0,classes:"w25"});for(let e=0;e");vn(a,s[e].t,{fanatic:s[e].t===Ki[r].fanaticism&&Ki[r].name,trank:s[e].r,wiki:!0}),ls(t,a,{wide:!0,classes:"w25"})}})),a.sort(((e,t)=>Ki[e].nameas("name",e).localeCompare(as("name",t)))).forEach((function(r){if(t[a].includes(Ei[r].type)){let t=$(`
                                    `);e.append(t),vn(t,r,{tpage:!0,wiki:!0}),Ln("add","traits-species",`${Ei[r].type}_${r}`,as("name",r))}}))}(a);break;case"custom":!function(e){In(e,{name:"custom",template:"mechanics",label:z("wiki_mechanics_custom"),paragraphs:12,break:[3,5,9,11],full:!0,h_level:2,para_data:{1:[z("wiki_resets_ascension")],2:[z("wiki_resets_ascension")],5:[z("resource_Genes_name")],6:[z("resource_Genes_name")],7:[2],8:[z("achieve_technophobe_name"),5,7],9:[z("tech_fanaticism"),z("tech_deify")],11:[0,z("resource_Genes_name")],12:[z("resource_Genes_name"),z("trait_untapped_name")]},data_link:{1:["wiki.html#resets-prestige-ascension"],2:["wiki.html#resets-prestige-ascension"],8:["wiki.html#perks-prestige-technophobe"],9:[t.genes.transcendence?"wiki.html#civilized-tech-alt_fanaticism":"wiki.html#civilized-tech-fanaticism","wiki.html#early_space-tech-deify"]}});let a=$('
                                    ');e.append(a),Qt(a)}(a)}}(r),Cc(a,r,i);break;case"structures":Un(r,"standard"),Cc(a,r,i);break;case"tech":_c(r,"standard"),Cc(a,r,i);break;case"tp_structures":Un(r,"truepath"),Cc(a,r,i);break;case"tp_tech":_c(r,"truepath"),Cc(a,r,i);break;case"arpa":!function(e){let a=$("#content");switch(Ss(a),e){case"projects":!function(e){e.append(`
                                    ${z("wiki_arpa_projects")}
                                    `);let a=$("
                                    "),r=Ln("create",a);e.append(a),Object.keys(qe).forEach((function(e){let a=$(`
                                    `);r.append(a),function(e,a){let r="string"==typeof qe[a].title?qe[a].title:qe[a].title(!0);e.append(`

                                    ${r}

                                    `);let i=$('
                                    ');if(e.append(i),i.append(`
                                    ${"string"==typeof qe[a].desc?qe[a].desc:qe[a].desc()}
                                    `),i.append(`
                                    ${"string"==typeof qe[a].effect?qe[a].effect:qe[a].effect()}
                                    `),Oc[a]){let t=$("
                                    ");e.append(t),function(e,t){let a=$('
                                    ');if(e.append(a),Oc.hasOwnProperty(t))for(let e=0;e${Oc[t][e]}`)}(t,a)}!function(e,a){let r={owned:0,creepVis:!0,extra:{creative:!1}},i={};switch(a){case"monument":r.extra.m_type="Obelisk";break;case"launch_facility":r.creepVis=!1}let s=qe[a];r.real_owned=t.arpa[a]?t.arpa[a].rank:0;let n=$('
                                    ');e.append(n);let c=$(`

                                    ${z("wiki_calc_cost")}

                                    `),o=$(`

                                    ${z("wiki_calc_cost_creep")}

                                    `);n.append(c),n.append(o);let l=s.cost;Object.keys(Ae(l)).forEach((function(e){i[e]={};let a="Money"===e?"$":t.resource[e].name+": ";c.append($(`
                                    ${a}{{ r.${e}.cost }}
                                    `)),o.append($(`
                                    {{ r.${e}.creep }}
                                    `))}));let _=function(){let e=Ae(l,r.owned-r.real_owned,r.extra);Object.keys(i).forEach((function(t){let a=e[t]?e[t](r.owned-r.real_owned,r.extra):0;i[t].vis=a>0,i[t].cost=x(a,1)}))};_();let d=function(){if("launch_facility"!==a){let e=Ae(l,100,r.extra),t=Ae(l,99,r.extra);Object.keys(i).forEach((function(a){e[a]&&(i[a].creep=+(e[a](100,r.extra)/t[a](99,r.extra)).toFixed(4))}))}};d();let p='\n
                                    \n
                                    ';"launch_facility"!==a&&(p+=`\n
                                    ${z("wiki_calc_level")} -+
                                    `),"monument"===a&&(p+=`\n
                                    ${z("wiki_calc_m_type")} \n \n {{ 'Obelisk' | monumentLabel }}\n {{ 'Statue' | monumentLabel }}\n {{ 'Sculpture' | monumentLabel }}\n {{ 'Monolith' | monumentLabel }}\n {{ 'Pillar' | monumentLabel }}\n {{ 'Megalith' | monumentLabel }}\n
                                    \n `),p+=`\n
                                    ${z("trait_creative_name")}
                                    \n
                                    \n
                                    \n \n
                                    \n
                                    \n `,e.append($(p)),Cs({el:`#${a}`,data:{i:r,r:i},methods:{val(e){r[e]=Math.round(r[e]),r[e]&&r[e]<0&&(r[e]=0),_()},less(e){r[e]>0&&r[e]--},more(e){r[e]++},pickMonument(e){r.extra.m_type=e,_(),d()},update(){_(),d()},importInputs(){"launch_facility"!==a&&(r.owned=r.real_owned),r.extra.creative=!!t.race.creative,"monument"===a&&t.arpa.m_type&&(r.extra.m_type=t.arpa.m_type)}},filters:{monumentLabel(e){switch(e){case"Obelisk":return z("arpa_project_monument_obelisk");case"Statue":return z("arpa_project_monument_statue");case"Sculpture":return z("arpa_project_monument_sculpture");case"Monolith":return z("arpa_project_monument_monolith");case"Pillar":return z("arpa_project_monument_pillar");case"Megalith":return z("arpa_project_monument_megalith")}}}})}(e,a)}(a,e),Ln("add","projects-arpa",e,"string"==typeof qe[e].title?qe[e].title:qe[e].title(!0))}))}(a);break;case"genetics":break;case"crispr":$c(a);break;case"blood":Pc(a)}}(r),Cc(a,r,i);break;case"achievements":"tracker"===r||dc(r),Cc(a,r,i);break;case"changelog":!function(){let e=$("#content");Ss(e);for(let t=0;t');e.append(a);let r=Mc[t].hasOwnProperty("revision")?Mc[t].revision:"";a.append(`

                                    v${Mc[t].version}${r}

                                    ${Mc[t].date}
                                    `);for(let e=0;e${Mc[t].changes[e]}`)}}(),window.location.hash=`#${a}`}}function Cc(e,t,a){void 0===a?window.location.hash=`#${t}-${e}`:(window.location.hash=`#${t}-${e}-${a}`,setTimeout((function(){document.getElementById(a).scrollIntoView({block:"start",behavior:"smooth"})}),125))}function zc(e,t,a){let r=!!window.location.hash&&window.location.hash.substring(1).split("-"),i="";for(let s=0;s1&&r[1]===e[s].key?' :active="true" expanded':""}>`,i+=zc(e[s].submenu,!1,e[s].key),i+="";else{let n=!r&&t&&0===s||r&&r[0]===e[s].key?' :active="true"':"",c=a?`'${a}','${e[s].key}'`:`'${e[s].key}',false`;i+=``}return i}function Fc(){let e=$("#content");Ss(e);let a=`${["Beorseder","Rodrigodd","Volch"].join(', ').replace(/, ([^,]*)$/,", & $1")}`,r=t.beta?`beta v${t.version}.${t.beta}`:"v"+t.version;e.append(`
                                    ${z("wiki_main_title")} - ${r}
                                    `),e.append(`
                                    ${z("wiki_main_author",["Demagorddon"])}
                                    `),e.append(`
                                    ${z("wiki_main_spoiler")}
                                    `),e.append(`
                                    ${z("wiki_main_blurb")}
                                    `),e.append(`
                                    ${z("wiki_main_contribution",[a])}
                                    `),e.append(`
                                    ${z("wiki_resources")}
                                    `);let i=$('
                                      ');e.append(i),i.append(`
                                    • ${z("wiki_resources_begin_guide")} ${z("wiki_resources_by",["GreyCat"])}
                                    • `),i.append(`
                                    • ${z("wiki_resources_tracker")} ${z("wiki_resources_by",["Karsen777"])}
                                    • `)}$("body").empty(),function(){$("body").append($(`

                                      ${z("wiki_menu_evolve")}

                                      `));let e=$('
                                      ');$("body").append(e);let t=$('');e.append(t);let a=`",t.append(a),Cs({el:"#menu",data:{},methods:{loadPage(e,t){Sc(e,t)}}});let r=$('
                                      ');if(e.append(r),window.location.hash){let e=window.location.hash.substring(1).split("-");e.length>1?e.length>2?Sc(e[1],e[0],e[2]):Sc(e[1],e[0]):Sc(e[0])}else Fc()}()})(); \ No newline at end of file