diff --git a/src/005-passages/introPassages.js b/src/005-passages/introPassages.js index ea227a96396adf44ce73ea99752c7aad000eaa21..0934ab27c40e57bc77e0319efa790e01a20af1ba 100644 --- a/src/005-passages/introPassages.js +++ b/src/005-passages/introPassages.js @@ -12,3 +12,27 @@ new App.DomPassage("Acquisition", new App.DomPassage("Customize Slave Trade", () => { return App.Intro.CustomSlaveTrade(); }); new App.DomPassage("Starting Girls", () => { return App.StartingGirls.passage(); }); + +new App.DomPassage("Gender Intro", () => { return App.Intro.genderIntro(); }); + +new App.DomPassage("PC Experience Intro", () => { return App.Intro.PCExperienceIntro(); }); + +new App.DomPassage("Economy Intro", () => { return App.Intro.economyIntro(); }); + +new App.DomPassage("Trade Intro", () => { return App.Intro.tradeIntro(); }); + +new App.DomPassage("Extreme Intro", () => { return App.Intro.extremeIntro(); }); + +new App.DomPassage("Slave Age Intro", () => { return App.Intro.slaveAgeIntro(); }); + +new App.DomPassage("PC Rumor Intro", () => { return App.Intro.PCRumorIntro(); }); + +new App.DomPassage("Terrain Intro", () => { return App.Intro.terrainIntro(); }); + +new App.DomPassage("Takeover Target", () => { return App.Intro.takeoverTarget(); }); + +new App.DomPassage("PC Preg Intro", () => { return App.Intro.PCPregIntro(); }); + +new App.DomPassage("PC Appearance Intro", () => { return App.Intro.PCAppearanceIntro(); }); + +new App.DomPassage("Location Intro", () => { return App.Intro.locationIntro(); }); diff --git a/src/events/intro/economyIntro.js b/src/events/intro/economyIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..1615ac57489e69838da30ae43c4474b2f2293ea6 --- /dev/null +++ b/src/events/intro/economyIntro.js @@ -0,0 +1,90 @@ +App.Intro.economyIntro = function() { + const node = new DocumentFragment(); + // :: Economy Intro [nobr] + + App.Events.addParagraph(node, [ + `It is the year 2037, and the past 21 years have not been kind. The world is starting to fall apart. The climate is deteriorating, resources are being exhausted, and there are more people to feed every year. Technology is advancing, but not fast enough to save everyone. <span class="intro question"></span>`, + ]); + + if (V.PC.career === "arcology owner" || V.saveImported === 1) { + setTimeout(() => Engine.play("Takeover Target"), Engine.minDomActionDelay); + } + + const options = new App.UI.OptionsGroup(); + + const difficultyComment = new Map([ + [1, `Not truly dire. Not yet.`], + [2, `Getting a touch dire.`], + [3, `Very serious.`], + [4, `It won't be pretty.`], + [5, `This is the last dance.`], + ]); + + options.addOption(`Exactly how bad is the situation?`, "baseDifficulty") + .addValue(`Very Easy`, 1).addCallback(() => V.economy = 200) + .addValue(`Easy`, 2).addCallback(() => V.economy = 125) + .addValue(`Very serious (default)`, 3).addCallback(() => V.economy = 100) + .addValue(`Hard`, 4).addCallback(() => V.economy = 80) + .addValue(`Very Hard`, 5).addCallback(() => V.economy = 67) + .addComment(difficultyComment.get(V.baseDifficulty)); + + const difficultyComment2 = new Map([ + [0, `Barely noticeable, for now.`], + [1, `A slow decline.`], + [2, `It's visibly deteriorating before your eyes.`], + [4, `It's going to hell in a handbasket.`], + ]); + + if (V.difficultySwitch === 0) { + options.addOption(`How fast is it crumbling?`, "difficultySwitch") + .addValue(`Vanilla`, 0) + .addValue(`Harder`, 1); + } else { + options.addOption(`How fast is it crumbling?`, "econRate") + .addValue(`Return to vanilla`, 0).addCallback(() => { + V.econRate = 0; + V.difficultySwitch = 0; + }) + .addValue(`Easy`, 1).addCallback(() => V.econRate = 1) + .addValue(`Default Difficulty`, 2).addCallback(() => V.econRate = 2) + .addValue(`Hard`, 4).addCallback(() => V.econRate = 4) + .addComment(`Some economic content requires this to be set to harder than vanilla ${difficultyComment2.get(V.econRate)}`); + } + node.append(options.render()); + + /* Not functional yet, place V.incomeRate = 1 in storyInit when ready for use + //<div> + r.push(`All the things you need to run your arcology are getting more expensive`); + if (V.incomeMod === 0) { + r.push(`while all forms of income`); + //<span style="font-weight:Bold">remain static</span>. [[Easier|Economy Intro][V.incomeRate = 1]] + } else if (V.incomeMod === 1) { + r.push(`while all forms of income <span style="font-weight:Bold">rise but cannot keep pace</span>. [[Easier|Economy Intro][${V.incomeRate} = 2]] | [[Harder|Economy Intro][V.incomeRate = 0]]`); + } else { + r.push(`but luckily all forms of income <span style="font-weight:Bold">rise in lockstep</span>. [[Harder|Economy Intro][${V.incomeRate} = 1]]`); + } + //</div> + + //<div> + [[Play with static economy|Economy Intro][V.difficultySwitch = 0]] + //</div> + */ + // </p> + // <p> + + App.Events.addResponses(node, [ + new App.Events.Result(`Next`, next), + new App.Events.Result(`Skip Intro`, skip, `This will preclude you from taking over an established arcology.`), + ]); + + return node; + + function next() { + Engine.play("Trade Intro"); + return ``; + } + function skip() { + Engine.play("Intro Summary"); + return ``; + } +}; diff --git a/src/events/intro/economyIntro.tw b/src/events/intro/economyIntro.tw deleted file mode 100644 index 10720c1b440ecaf435084d99d829aa9fedd809af..0000000000000000000000000000000000000000 --- a/src/events/intro/economyIntro.tw +++ /dev/null @@ -1,160 +0,0 @@ -:: Economy Intro [nobr] - -<<if $PC.career == "arcology owner" || $saveImported == 1>> - <<goto "Takeover Target">> -<<else>> - <p> - It is the year 2037, and the past 21 years have not been kind. The world is starting to fall apart. The climate is deteriorating, resources are being exhausted, and there are more people to feed every year. Technology is advancing, but not fast enough to save everyone. <span class="intro question">Exactly how bad is the situation?</span> - </p> - <p> - <<if $baseDifficulty == 1>> - <div> - <span style="font-weight:Bold"> - Not truly dire. Not yet. - </span> - <span class="note"> - Very Easy - </span> - </div> - <div> - [[Harder|Economy Intro][$economy = 125, $baseDifficulty = 2]] - </div> - <<elseif $baseDifficulty == 2>> - <div> - <span style="font-weight:Bold"> - Getting a touch dire. - </span> - <span class="note"> - Easy - </span> - </div> - <div> - [[Harder|Economy Intro][$economy = 100, $baseDifficulty = 3]] | [[Easier|Economy Intro][$economy = 200, $baseDifficulty = 1]] - </div> - <<elseif $baseDifficulty == 3>> - <div> - <span style="font-weight:Bold"> - Very serious. - </span> - <span class="note"> - Default Difficulty - </span> - </div> - <div> - [[Harder|Economy Intro][$economy = 80, $baseDifficulty = 4]] | [[Easier|Economy Intro][$economy = 125, $baseDifficulty = 2]] - </div> - <<elseif $baseDifficulty == 4>> - <div> - <span style="font-weight:Bold"> - It won't be pretty. - </span> - <span class="note"> - Hard - </span> - </div> - <div> - [[Harder|Economy Intro][$economy = 67, $baseDifficulty = 5]] | [[Easier|Economy Intro][$economy = 100, $baseDifficulty = 3]] - </div> - <<else>> - <div> - <span style="font-weight:Bold"> - This is the last dance. - </span> - </div> - <div> - <span class="note"> - Very Hard - </span> - </div> - <div> - [[Easier|Economy Intro][$economy = 80, $baseDifficulty = 4]] - </div> - <</if>> - </p> - - /*Economy settings*/ - <p> - <span class="intro question"> - How fast is it crumbling? - </span> - <span class="note"> - Some economic content requires this to be set to harder than vanilla - </span> - <<if $difficultySwitch == 0>> - <div> - <span style="font-weight:Bold"> - Barely noticeable, for now. - </span> - <span class="note"> - Vanilla - </span> - </div> - <div> - [[Harder|Economy Intro][$econRate = 1, $difficultySwitch = 1]] - </div> - <<elseif $econRate == 1>> - <div> - <span style="font-weight:Bold"> - A slow decline. - </span> - <span class="note"> - Easy - </span> - </div> - <div> - [[Harder|Economy Intro][$econRate = 2]] | [[Easier|Economy Intro][$difficultySwitch = 0]] - </div> - <<elseif $econRate == 2>> - <div> - <span style="font-weight:Bold"> - It's visibly deteriorating before your eyes. - </span> - <span class="note"> - Default Difficulty - </span> - </div> - <div> - [[Harder|Economy Intro][$econRate = 4]] | [[Easier|Economy Intro][$econRate = 1]] - </div> - <<else>> - <div> - <span style="font-weight:Bold"> - It's going to hell in a handbasket. - </span> - <span class="note"> - Hard - </span> - </div> - <div> - [[Easier|Economy Intro][$econRate = 2]] - </div> - <</if>> - - /* Not functional yet, place $incomeRate = 1 in storyInit when ready for use - <div> - All the things you need to run your arcology are getting more expensive - <<if $incomeMod == 0>> - while all forms of income - <span style="font-weight:Bold">remain static</span>. [[Easier|Economy Intro][$incomeRate = 1]] - <<elseif $incomeMod == 1>> - while all forms of income <span style="font-weight:Bold">rise but cannot keep pace</span>. [[Easier|Economy Intro][$incomeRate = 2]] | [[Harder|Economy Intro][$incomeRate = 0]] - <<else>> - but luckily all forms of income <span style="font-weight:Bold">rise in lockstep</span>. [[Harder|Economy Intro][$incomeRate = 1]] - <</if>> - </div> - - <div> - [[Play with static economy|Economy Intro][$difficultySwitch = 0]] - </div> - */ - </p> - <p> - [[Next|Trade Intro]] - </p> - <p> - [[Skip Intro|Intro Summary]] - <span class="note"> - This will preclude you from taking over an established arcology. - </span> - </p> -<</if>> diff --git a/src/events/intro/extremeIntro.js b/src/events/intro/extremeIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..97877f834d4077c4146de7f56aed5cb94dca7b3f --- /dev/null +++ b/src/events/intro/extremeIntro.js @@ -0,0 +1,44 @@ +App.Intro.extremeIntro = function() { + const node = new DocumentFragment(); + // :: :: Extreme Intro [nobr] + + App.Events.addParagraph(node, [ + `The early Free Cities were wild places where the writ of law did not run. In some of the most depraved, slaves' bodies, minds and even lives were playthings of the wealthy and powerful. Though modern Free Cities are tremendously varied, a majority of the new communities made a choice about whether extreme practices were a flaw in a lawless society or one of its benefits.`, + App.UI.DOM.makeElement("span", `How did most Free Cities react to the excesses of the early days?`, ["intro", "question"]) + ]); + + App.Events.addResponses(node, [ + new App.Events.Result(`They drew back from them.`, drewBack, `Extreme content such as amputation and castration will not appear.`), + new App.Events.Result(`They reveled in them.`, reveled, `Extreme content will appear.`), + new App.Events.Result(`They drew back from them, but remained creative.`, creative, `Extreme content will not appear, but hyper-pregnancy related content might appear.`), + new App.Events.Result(`They reveled in them and were particularly inventive.`, inventive, `Extreme content will appear, including hyper-pregnancy related content`), + ]); + + return node; + + function drewBack() { + V.seeExtreme = 0; + Engine.play("Gender Intro"); + return ``; + } + + function reveled() { + V.seeExtreme = 1; + Engine.play("Gender Intro"); + return ``; + } + + function creative() { + V.seeExtreme = 0; + V.seeHyperPreg = 1; + Engine.play("Gender Intro"); + return ``; + } + + function inventive() { + V.seeExtreme = 0; + V.seeHyperPreg = 1; + Engine.play("Gender Intro"); + return ``; + } +}; diff --git a/src/events/intro/extremeIntro.tw b/src/events/intro/extremeIntro.tw deleted file mode 100644 index ef80ed1d7064149cf406ad9f61c67c3d1d0400a5..0000000000000000000000000000000000000000 --- a/src/events/intro/extremeIntro.tw +++ /dev/null @@ -1,33 +0,0 @@ -:: Extreme Intro [nobr] - -<p> - The early Free Cities were wild places where the writ of law did not run. In some of the most depraved, slaves' bodies, minds and even lives were playthings of the wealthy and powerful. Though modern Free Cities are tremendously varied, a majority of the new communities made a choice about whether extreme practices were a flaw in a lawless society or one of its benefits. - <span class="intro question"> - How did most Free Cities react to the excesses of the early days? - </span> -</p> - -<div> - [[They drew back from them.|Gender Intro][$seeExtreme = 0]] - <span class="note"> - Extreme content such as amputation and castration will not appear. - </span> -</div> -<div> - [[They reveled in them.|Gender Intro][$seeExtreme = 1]] - <span class="note"> - Extreme content will appear. - </span> -</div> -<div> - [[They drew back from them, but remained creative.|Gender Intro][$seeExtreme = 0,$seeHyperPreg = 1]] - <span class="note"> - Extreme content will not appear, but hyper-pregnancy related content might appear. - </span> -</div> -<div> - [[They reveled in them and were particularly inventive.|Gender Intro][$seeExtreme = 1,$seeHyperPreg = 1]] - <span class="note"> - Extreme content will appear, including hyper-pregnancy related content - </span> -</div> diff --git a/src/events/intro/genderIntro.js b/src/events/intro/genderIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..0cc4392a9c8139147419b50812c011db8166561f --- /dev/null +++ b/src/events/intro/genderIntro.js @@ -0,0 +1,42 @@ +App.Intro.genderIntro = function() { + const node = new DocumentFragment(); + + App.Events.addParagraph(node, [ + `The Free Cities are sexually libertine places, and sexual slavery is ubiquitous. Some of the early Free Cities upheld or even strengthened traditional gender roles, expecting men to be men and women to be women. Others subscribed to an interesting refinement of those gender roles, considering any sex slave female, regardless of her biology. A small minority even went so far as to strongly favor societal feminization of slaves born male; in these, biologically female slaves were a rare sight.`, + App.UI.DOM.makeElement("span", `Which kind of Free City came to predominate?`, ["intro", "question"]) + ]); + + App.Events.addResponses(node, [ + new App.Events.Result(`Free Cities that were open-minded about who could be a slave girl.`, open, `Default setting. The majority of slaves will be biologically female, and all content will be available.`), + new App.Events.Result(`Free Cities that understood that girls are girls.`, girlIsGirl, `Almost all slaves will be biologically female, restricting some content.`), + new App.Events.Result(`Free Cities that understood that girls are girls with some exceptions.`, exceptions, `This option will make almost all generated slaves female, but will allow for the attachment of a certain organ through surgery.`), + new App.Events.Result(`Free Cities that preferred girls with dicks.`, slaveIsBoy, `Almost all slaves will be biologically male, restricting some content.`), + ]); + + return node; + + function open() { + V.seeDicks = 25; + Engine.play("Slave Age Intro"); + return ``; + } + + function girlIsGirl() { + V.seeDicks = 0; + Engine.play("Slave Age Intro"); + return ``; + } + + function exceptions() { + V.seeDicks = 0; + V.makeDicks = 1; + Engine.play("Slave Age Intro"); + return ``; + } + + function slaveIsBoy() { + V.seeDicks = 100; + Engine.play("Slave Age Intro"); + return ``; + } +}; diff --git a/src/events/intro/genderIntro.tw b/src/events/intro/genderIntro.tw deleted file mode 100644 index 14bfee13676febc9a0e716c0c42226de4cf63689..0000000000000000000000000000000000000000 --- a/src/events/intro/genderIntro.tw +++ /dev/null @@ -1,33 +0,0 @@ -:: Gender Intro [nobr] - -<p> - The Free Cities are sexually libertine places, and sexual slavery is ubiquitous. Some of the early Free Cities upheld or even strengthened traditional gender roles, expecting men to be men and women to be women. Others subscribed to an interesting refinement of those gender roles, considering any sex slave female, regardless of her biology. A small minority even went so far as to strongly favor societal feminization of slaves born male; in these, biologically female slaves were a rare sight. - <span class="intro question"> - Which kind of Free City came to predominate? - </span> -</p> - -<div> - [[Free Cities that were open-minded about who could be a slave girl.|Slave Age Intro][$seeDicks = 25]] - <span class="note"> - Default setting. The majority of slaves will be biologically female, and all content will be available. - </span> -</div> -<div> - [[Free Cities that understood that girls are girls.|Slave Age Intro][$seeDicks = 0]] - <span class="note"> - Almost all slaves will be biologically female, restricting some content. - </span> -</div> -<div> - [[Free Cities that understood that girls are girls with some exceptions.|Slave Age Intro][$makeDicks = 1, $seeDicks = 0]] - <span class="note"> - This option will make almost all generated slaves female, but will allow for the attachment of a certain organ through surgery. - </span> -</div> -<div> - [[Free Cities that preferred girls with dicks.|Slave Age Intro][$seeDicks = 100]] - <span class="note"> - Almost all slaves will be biologically male, restricting some content. - </span> -</div> diff --git a/src/events/intro/locationIntro.js b/src/events/intro/locationIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..9e82f64df529b97eab0771c324403f05cce9fa72 --- /dev/null +++ b/src/events/intro/locationIntro.js @@ -0,0 +1,37 @@ +App.Intro.locationIntro = function() { + // :: Location Intro + const node = new DocumentFragment(); + + App.Events.addParagraph(node, [ + `As the old countries crumble and technology stagnates, the gap between rich and poor increases. In order to continue living a good life without having their property taken by the mob, many of the wealthy and powerful come together to form 'Free Cities.' These are new cities on undeveloped land, in remote areas, or even afloat, fully free of any allegiance or law. These new cities are built on new ideas, with most buildings designed as futuristic, self-contained 'arcologies.' An arcology and everything in it is usually owned by a single person. And you're determined that you will soon be one of those single people.`, + App.UI.DOM.makeElement("span", `In what part of the world is your new arcology going to be located?`, ["intro", "question"]) + ]); + + const continents = new Map([ + ["North America", "English"], + ["South America", "Spanish"], + ["Brazil", "Portuguese"], + ["Central Europe", "German"], + ["Western Europe", "English"], + ["Eastern Europe", "Russian"], + ["Southern Europe", "Italian"], + ["Scandinavia", "Norwegian"], + ["the Middle East", "Arabic"], + ["Africa", "Arabic"], + ["Asia", "Chinese"], + ["Japan", "Japanese"], + ["Australia", "English"], + ]); + + const linkArray = []; + for (const [name, language] of continents) { + linkArray.push(App.UI.DOM.passageLink( + name, + "Intro Summary", + () => V.language = language + )); + } + node.append(App.UI.DOM.generateLinksStrip(linkArray)); + + return node; +}; diff --git a/src/events/intro/locationIntro.tw b/src/events/intro/locationIntro.tw deleted file mode 100644 index 8a2c442268b0d4d4b44dbfb575778e68d031220d..0000000000000000000000000000000000000000 --- a/src/events/intro/locationIntro.tw +++ /dev/null @@ -1,25 +0,0 @@ -:: Location Intro [nobr] - -<p> - As the old countries crumble and technology stagnates, the gap between rich and poor increases. In order to continue living a good life without having their property taken by the mob, many of the wealthy and powerful come together to form 'Free Cities.' These are new cities on undeveloped land, in remote areas, or even afloat, fully free of any allegiance or law. These new cities are built on new ideas, with most buildings designed as futuristic, self-contained 'arcologies.' An arcology and everything in it is usually owned by a single person. And you're determined that you will soon be one of those single people. - <span class="intro question">In what part of the world is your new arcology going to be located?</span> -</p> - -<p> - [[North America|Intro Summary][$continent = "North America", $language = "English"]] - | [[South America|Intro Summary][$continent = "South America", $language = "Spanish"]] - | [[Brazil|Intro Summary][$continent = "Brazil", $language = "Portuguese"]] - | [[Central Europe|Intro Summary][$continent = "Central Europe", $language = "German"]] - | [[Western Europe|Intro Summary][$continent = "Western Europe", $language = "English"]] - | [[Eastern Europe|Intro Summary][$continent = "Eastern Europe", $language = "Russian"]] - | [[Southern Europe|Intro Summary][$continent = "Southern Europe", $language = "Italian"]] - | [[Scandinavia|Intro Summary][$continent = "Scandinavia", $language = "Norwegian"]] - | [[the Middle East|Intro Summary][$continent = "the Middle East", $language = "Arabic"]] - | [[Africa|Intro Summary][$continent = "Africa", $language = "Arabic"]] - | [[Asia|Intro Summary][$continent = "Asia", $language = "Chinese"]] - | [[Japan|Intro Summary][$continent = "Japan", $language = "Japanese"]] - | [[Australia|Intro Summary][$continent = "Australia", $language = "English"]] - <div> - //Slaves from countries in the selected continent will appear more frequently.// - </div> -</p> diff --git a/src/events/intro/pcAppearanceIntro.js b/src/events/intro/pcAppearanceIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..82cefc77e27c4a39910e0bd2721fc940d1a3728d --- /dev/null +++ b/src/events/intro/pcAppearanceIntro.js @@ -0,0 +1,28 @@ +App.Intro.PCAppearanceIntro = function() { + const node = new DocumentFragment(); + // :: PC Appearance Intro [nobr] + node.append( + `Race and appearance are largely irrelevant in the Free Cities; there are only the free and the enslaved.`, + App.UI.DOM.makeElement("div", `Appearance only, will mostly have a superficial effect (unless you make a big deal out of it).`, ["indent", "note"]) + ); + + const _options = new App.UI.OptionsGroup(); + App.UI.Player.appearance(_options); + node.append(_options.render()); + + if (isFertile(V.PC)) { + App.UI.DOM.appendNewElement("div", node, App.UI.DOM.passageLink( + "Continue player character customization", + "PC Preg Intro", + () => resetEyeColor(V.PC) + )); + } else { + App.UI.DOM.appendNewElement("div", node, App.UI.DOM.passageLink( + "Finish player character customization", + "PC Experience Intro", + () => resetEyeColor(V.PC) + )); + } + + return node; +}; diff --git a/src/events/intro/pcAppearanceIntro.tw b/src/events/intro/pcAppearanceIntro.tw deleted file mode 100644 index e982aa0d9f2fba6a8a77381876e23bbf9fe15557..0000000000000000000000000000000000000000 --- a/src/events/intro/pcAppearanceIntro.tw +++ /dev/null @@ -1,19 +0,0 @@ -:: PC Appearance Intro [nobr] - -<p> - Race and appearance are largely irrelevant in the Free Cities; there are only the free and the enslaved. - <div class="indent note"> - Appearance only, will mostly have a superficial effect (unless you make a big deal out of it). - </div> -</p> -<<set _options = new App.UI.OptionsGroup()>> -<<run App.UI.Player.appearance(_options)>> -<<includeDOM _options.render()>> - -<p> - <<if isFertile(V.PC)>> - [[Continue player character customization|PC Preg Intro][resetEyeColor($PC)]] - <<else>> - [[Finish player character customization|PC Experience Intro][resetEyeColor($PC)]] - <</if>> -</p> diff --git a/src/events/intro/pcExperienceIntro.js b/src/events/intro/pcExperienceIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..2eac848cc97a4b85b6a075f0b1672cb0ce5517b2 --- /dev/null +++ b/src/events/intro/pcExperienceIntro.js @@ -0,0 +1,125 @@ +App.Intro.PCExperienceIntro = function() { + // :: PC Experience Intro [nobr] + const node = new DocumentFragment(); + + V.showSecExp = V.showSecExp || 0; + + if (V.PC.career === "arcology owner") { + setTimeout(() => Engine.play("PC Rumor Intro"), Engine.minDomActionDelay); + } + if (!V.disableForcedCareers) { + V.disableForcedCareers = V.PC.actualAge >= 22 ? 1 : 0; + } + App.Events.addParagraph(node, [ + `You're a relative unknown in the Free Cities, but it's clear you're already accomplished. The meek and average cannot aspire to acquire arcologies. You've got all the necessary skills to take over an arcology and succeed as its owner, but you should be able to leverage the skills and experience you retain from your past, too.`, + App.UI.DOM.makeElement("span", `What career brought you to the Free Cities?`, ["intro", "question"]) + ]); + + makeOption( + "Idle wealth", "wealth", + App.Events.makeNode([`Start with <span class="cash inc">extra money.</span>${(V.showSecExp === 1) ? ` However, you will find it <span class="red">harder to maintain authority,</span> but <span class="cash inc">propaganda hub upgrades will be cheaper.</span>` : ``} Your starting slaves will have two free levels of <span class="cyan">sex skills</span> available.`]) + ); + + makeOption( + "Venture capitalism", "capitalist", + App.Events.makeNode([`You will be more <span class="green">effective at business pursuits.</span>${(V.showSecExp === 1) ? ` In addition, <span class="cash inc">propaganda hub upgrades will be cheaper.</span>` : ``} Your starting slaves will have a free level of <span class="cyan">prostitution skill</span> available.`]) + ); + + makeOption( + "Private military work", "mercenary", + App.Events.makeNode([ + `You retain mercenary contacts ${(V.showSecExp === 1) ? `and your security skills will make it <span class="green">easier to keep the arcology safe.</span> Also, <span class="cash inc">security HQ upgrades will be cheaper.</span>` : `and security skills.`}`, + `Your starting slaves will have <span class="green">free trust available.</span>` + ]) + ); + + makeOption( + "Slaving", "slaver", + App.Events.makeNode([ + `Your slave breaking experience will be useful. ${(V.showSecExp === 1) ? `You will find that authority will be <span class="green">easier to maintain</span> and <span class="cash inc">security HQ upgrades will be cheaper.</span>` : ""}`, `Your starting slaves will have free <span class="hotpink">devotion</span> available.` + ]) + ); + + makeOption( + "Engineering", "engineer", + App.Events.makeNode([`<span class="cash inc">Upgrading the arcology will be cheaper.</span> Also, the arcology will start with <span class="cash inc">basic economic upgrades</span> already installed.`]) + ); + + makeOption( + "Surgery", "medicine", + App.Events.makeNode([`Surgery will be <span class="cash inc">cheaper</span> and <span class="green">healthier</span> and <span class="cash inc">drug upgrades will be cheaper.</span> Your starting slaves will have free implants available.`]) + ); + + makeOption( + "Minor celebrity", "celebrity", + App.Events.makeNode([ + `Start with <span class="green">extra reputation.</span>${(V.showSecExp === 1) ? ` In addition, <span class="cash inc">propaganda hub upgrades will be cheaper.</span>` : ``}`, + `Your starting slaves will have a free level of <span class="cyan">entertainment skill</span> available.` + ]) + ); + + makeOption( + "Sex industry", "escort", + App.Events.makeNode([ + `As an ex-whore, you will find it <span class="red">hard to maintain reputation</span>${(V.showSecExp === 1) ? `, <span class="red">in addition to authority</span>` : ``}.`, + `Your starting slaves will have a free level of <span class="cyan">sex skills</span> available, along with a free level of <span class="cyan">entertainment and prostitution.</span>`]) + ); + + makeOption( + "Servant", "servant", + App.Events.makeNode([ + `As an ex-servant, you will find it <span class="red">hard to maintain reputation</span>${(V.showSecExp === 1) ? `, <span class="red">in addition to authority</span>` : ``}.`, `You know how to <span class="cash inc">lower your upkeep,</span> but <span class="red">not much else.</span> Your starting slaves will have free <span class="mediumaquamarine">trust</span> and <span class="hotpink">devotion.</span>` + ]) + ); + + makeOption( + "Gang affiliation", "gang", + App.Events.makeNode([ + `As an ex-gang member, you know how to haggle slaves.${(V.showSecExp === 1) ? `In addition, asserting your authority <span class="green">will be easier</span> and <span class="cash inc">security HQ upgrades will be cheaper.</span>` : ``}`, `However, you will <span class="red">find reputation quite hard</span> to maintain. Your starting slaves will be <span class="green">fitter</span> and possess a free level of <span class="cyan">combat skill.</span>` + ]) + ); + + makeOption( + "Incursion Specialist", "BlackHat", + App.Events.makeNode([ + `As an ex-hacker, you know how to gain access computer systems and other devices. <span class="green">Certain upgrades will be cheaper</span> and you may find alternative approaches to problems.${(V.showSecExp === 1) ? `However, you will <span class="red">find authority quite hard</span> to maintain.` : ""}`, + `Your starting slaves will have a free level of <span class="cyan">intelligence</span>.` + ]) + ); + + function makeOption(linkTitle, career, desc) { + App.UI.DOM.appendNewElement("div", node, App.UI.DOM.passageLink( + linkTitle, + "PC Rumor Intro", + () => V.PC.career = App.UI.Player.assignCareerByAge(career) + )); + + App.UI.DOM.appendNewElement("div", node, desc, ["indent", "note"]); + } + + const options = new App.UI.OptionsGroup(); + + options.addOption(`Security Expansion Mod effects`, "showSecExp") + .addValueList([ + ["Hide", 0], + ["Show", 1], + ]); + + const option = options.addOption(`Forced career choices`, "disableForcedCareers") + .addValue("Disable", 0); + let r = []; + if (V.PC.actualAge < 14) { + r.push(`Due to your young age, you will be given the child variant of your chosen career line.`); + } else if (V.PC.actualAge < 22) { + r.push(`Due to your age, you will be given the inexperienced variant of your chosen career line.`); + } + r.push(`Over time and with effort, you will be capable of achieving everything of importance in the adult careers.`); + option.addComment(r.join(" ")); + if (V.PC.actualAge < 22) { + option.addValue("Enable", 1) + .addComment("Use age based careers."); + } + node.append(options.render()); + + return node; +}; diff --git a/src/events/intro/pcExperienceIntro.tw b/src/events/intro/pcExperienceIntro.tw deleted file mode 100644 index 137604a09654c94de2023a77bb4342327cc7eb83..0000000000000000000000000000000000000000 --- a/src/events/intro/pcExperienceIntro.tw +++ /dev/null @@ -1,162 +0,0 @@ -:: PC Experience Intro [nobr] - -<<if $PC.career == "arcology owner">> - <<goto "PC Rumor Intro">> -<<else>> - <<if !$disableForcedCareers>> - <<set $disableForcedCareers = $PC.actualAge >= 22 ? 1 : 0>> - <</if>> - - <p> - You're a relative unknown in the Free Cities, but it's clear you're already accomplished. The meek and average cannot aspire to acquire arcologies. You've got all the necessary skills to take over an arcology and succeed as its owner, but you should be able to leverage the skills and experience you retain from your past, too. - <span class="intro question"> - What career brought you to the Free Cities? - </span> - </p> - - <div> - [[Idle wealth|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("wealth")]] - </div> - <div class="indent note"> - Start with <span class="cash inc">extra money.</span> - <<if $showSecExp == 1>> - However, you will find it @@.red;harder to maintain authority,@@ but <span class="cash inc">propaganda hub upgrades will be cheaper.</span> - <</if>> - Your starting slaves will have two free levels of @@.cyan;sex skills@@ available. - </div> - - <div> - [[Venture capitalism|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("capitalist")]] - </div> - <div class="indent note"> - You will be more @@.green;effective at business pursuits.@@ - <<if $showSecExp == 1>> - In addition, <span class="cash inc">propaganda hub upgrades will be cheaper.</span> - <</if>> - Your starting slaves will have a free level of @@.cyan;prostitution skill@@ available. - </div> - - <div> - [[Private military work|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("mercenary")]] - </div> - <div class="indent note"> - You retain mercenary contacts - <<if $showSecExp == 1>> - and your security skills will make it @@.green;easier to keep the arcology safe.@@ Also, <span class="cash inc">security HQ upgrades will be cheaper.</span> - <<else>> - and security skills. - <</if>> - Your starting slaves will have @@.green;free trust available.@@ - </div> - - <div> - [[Slaving|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("slaver")]] - </div> - <div class="indent note"> - Your slave breaking experience will be useful. - <<if $showSecExp == 1>> - You will find that authority will be @@.green;easier to maintain@@ and <span class="cash inc">security HQ upgrades will be cheaper.</span> - <</if>> - Your starting slaves will have free @@.hotpink;devotion@@ available. - </div> - - <div> - [[Engineering|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("engineer")]] - </div> - <div class="indent note"> - <span class="cash inc">Upgrading the arcology will be cheaper.</span> Also, the arcology will start with <span class="cash inc">basic economic upgrades</span> already installed. - </div> - - <div> - [[Surgery|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("medicine")]] - </div> - <div class="indent note"> - Surgery will be <span class="cash inc">cheaper</span> and @@.green;healthier@@ and <span class="cash inc">drug upgrades will be cheaper.</span> Your starting slaves will have free implants available. - </div> - - <div> - [[Minor celebrity|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("celebrity")]] - </div> - <div class="indent note"> - Start with @@.green;extra reputation.@@ - <<if $showSecExp == 1>> - In addition, <span class="cash inc">propaganda hub upgrades will be cheaper.</span> - <</if>> - Your starting slaves will have a free level of @@.cyan;entertainment skill@@ available. - </div> - - <div> - [[Sex industry|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("escort")]] - </div> - <div class="indent note"> - As an ex-whore, you will find it @@.red;hard to maintain reputation@@<<if $showSecExp == 1>>, @@.red;in addition to authority@@<</if>>. - Your starting slaves will have a free level of @@.cyan;sex skills@@ available, along with a free level of @@.cyan;entertainment and prostitution.@@ - </div> - - <div> - [[Servant|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("servant")]] - </div> - <div class="indent note"> - As an ex-servant, you will find it @@.red;hard to maintain reputation@@<<if $showSecExp == 1>>, @@.red;in addition to authority@@<</if>>. - You know how to <span class="cash inc">lower your upkeep,</span> but @@.red;not much else.@@ Your starting slaves will have free @@.mediumaquamarine;trust@@ and @@.hotpink;devotion.@@ - </div> - - <div> - [[Gang affiliation|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("gang")]] - </div> - <div class="indent note"> - As an ex-gang member, you know how to haggle slaves. - <<if $showSecExp == 1>> - In addition, asserting your authority @@.green;will be easier@@ and <span class="cash inc">security HQ upgrades will be cheaper.</span> - <</if>> - However, you will @@.red;find reputation quite hard@@ to maintain. Your starting slaves will be @@.green;fitter@@ and possess a free level of @@.cyan;combat skill.@@ - </div> - - <div> - [[Incursion Specialist|PC Rumor Intro][$PC.career = App.UI.Player.assignCareerByAge("BlackHat")]] - </div> - <div class="indent note"> - As an ex-hacker, you know how to gain access computer systems and other devices. @@.green;Certain upgrades will be cheaper@@ and you may find alternative approaches to problems. - <<if $showSecExp == 1>> - However, you will @@.red;find authority quite hard@@ to maintain. - <</if>> - Your starting slaves will have a free level of @@.cyan;intelligence@@. - </div> -<</if>> - -<p> - <<if $showSecExp == 1>> - <<link "Hide Security Expansion Mod effects" "PC Experience Intro">> - <<set $showSecExp = 0>> - <</link>> - <<else>> - <<link "Show Security Expansion Mod effects" "PC Experience Intro">> - <<set $showSecExp = 1>> - <</link>> - <</if>> -</p> - -<p> - <<if $disableForcedCareers != 1>> - <<link "Disable forced career choices" "PC Experience Intro">> - <<set $disableForcedCareers = 1>> - <</link>> - <div class="indent note"> - <<if $PC.actualAge < 14>> - Due to your young age, you will be given the child variant of your chosen career line. - <<elseif $PC.actualAge < 22>> - Due to your age, you will be given the inexperienced variant of your chosen career line. - <</if>> - Over time and with effort, you will be capable of achieving everything of importance in the adult careers. - </div> - <<else>> - <<if $PC.actualAge < 22>> - <<link "Enable forced career choices" "PC Experience Intro">> - <<set $disableForcedCareers = 0>> - <</link>> - <div class="indent note"> - Use age based careers. - </div> - <</if>> - <</if>> -</p> \ No newline at end of file diff --git a/src/events/intro/pcPregIntro.js b/src/events/intro/pcPregIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..c88aee7211753fe7468c040cae790ef7889f7255 --- /dev/null +++ b/src/events/intro/pcPregIntro.js @@ -0,0 +1,131 @@ +App.Intro.PCPregIntro = function() { + const node = new DocumentFragment(); + // :: PC Preg Intro [nobr] + + App.Events.addParagraph(node, [ + `You have a working female reproductive system, and thus, a menstrual cycle. Women already face hardships as slaveowners and arcology owners, and being with child, coupled with a strong societal aversion to the dominant being penetrated, leads most pregnant owners to find themselves in dire situations. As an added precaution, since nothing stops an owner from hooking up with another owner, contraceptives are common amongst free women.`, + App.UI.DOM.makeElement("span", `What's your stance on taking contraceptives?`, ["intro", "question"]) + ]); + + // <p> + let r = []; + let linkArray = []; + r.push(`You're`); + if (V.PC.preg === -1) { + r.push(`not interested in being a mother.`); + linkArray.push(App.UI.DOM.passageLink( + "Risky", + "PC Preg Intro", + () => V.PC.preg = 0 + )); + } else if (V.PC.preg === 0) { + r.push(`fertile and you know the risks.`); + linkArray.push(App.UI.DOM.passageLink( + "Safe", + "PC Preg Intro", + () => V.PC.preg = -1 + )); + linkArray.push(App.UI.DOM.passageLink( + "About that...", + "PC Preg Intro", + () => V.PC.preg = 10 + )); + } else if (V.PC.preg > 42) { + r.push(`proudly pregnant with octuplets and they are coming right now.`); + linkArray.push(App.UI.DOM.passageLink( + "Not pregnant", + "PC Preg Intro", + () => { + V.PC.preg = 0; + V.PC.pregType = 0; + V.PC.labor = 0; + } + )); + } else if (V.PC.preg > 37) { + r.push(`${V.PC.preg} weeks pregnant and very close to being due.`); + linkArray.push(App.UI.DOM.passageLink( + "Not pregnant", + "PC Preg Intro", + () => { + V.PC.preg = 0; + V.PC.pregType = 0; + } + )); + linkArray.push(App.UI.DOM.passageLink( + "Overdid the fertility agents", + "PC Preg Intro", + () => { + V.PC.preg = 43; + V.PC.pregType = 8; + V.PC.labor = 1; + } + )); + } else { + r.push(`already pregnant.`); + linkArray.push(App.UI.DOM.passageLink( + "Fertile", + "PC Preg Intro", + () => V.PC.preg = 0 + )); + linkArray.push(App.UI.DOM.passageLink( + "Make that very pregnant", + "PC Preg Intro", + () => V.PC.preg = 40 + )); + } + App.Events.addParagraph(node, [ + r.join(" "), + App.UI.DOM.generateLinksStrip(linkArray), + App.UI.DOM.makeElement("span", `Being or becoming pregnant will raise difficulty.`, "note") + ]); + + App.UI.DOM.appendNewElement("p", node, `Hormones can be an interesting thing, but how do they affect you?`, ["intro", "question"]); + + // <p> + r = []; + linkArray = []; + r.push(`You're`); + if (V.PC.pregMood === 1) { + r.push(`gentle and motherly when you're hormonal.`); + } else if (V.PC.pregMood === 0) { + r.push(`in complete control of yourself.`); + } else { + r.push(`aggressive and domineering when you're hormonal.`); + } + if (V.PC.pregMood !== 0) { + r.push(`gentle and motherly when you're hormonal.`); + linkArray.push(App.UI.DOM.passageLink( + "Normal", + "PC Preg Intro", + () => V.PC.pregMood = 0 + )); + } + if (V.PC.pregMood !== 1) { + r.push(`in complete control of yourself.`); + linkArray.push(App.UI.DOM.passageLink( + "Motherly", + "PC Preg Intro", + () => V.PC.pregMood = 1 + )); + } + if (V.PC.pregMood !== 2) { + linkArray.push(App.UI.DOM.passageLink( + "Aggressive", + "PC Preg Intro", + () => V.PC.pregMood = 2 + )); + } + + App.Events.addParagraph(node, [ + r.join(" "), + App.UI.DOM.generateLinksStrip(linkArray), + App.UI.DOM.makeElement("span", `Hormone induced moods may alter some sex scenes, as well as change slaves' reactions to you.`, "note") + ]); + + App.UI.DOM.appendNewElement("p", node, App.UI.DOM.passageLink( + "Confirm player character customization", + "PC Experience Intro" + )); + return node; +}; + diff --git a/src/events/intro/pcPregIntro.tw b/src/events/intro/pcPregIntro.tw deleted file mode 100644 index 78ffe760712e87a063df04f0cf8f60a1c576f4a7..0000000000000000000000000000000000000000 --- a/src/events/intro/pcPregIntro.tw +++ /dev/null @@ -1,58 +0,0 @@ -:: PC Preg Intro [nobr] - -<p> - You have a working female reproductive system, and thus, a menstrual cycle. Women already face hardships as slaveowners and arcology owners, and being with child, coupled with a strong societal aversion to the dominant being penetrated, leads most pregnant owners to find themselves in dire situations. As an added precaution, since nothing stops an owner from hooking up with another owner, contraceptives are common amongst free women. -</p> - -<p class="intro question"> - What's your stance on taking contraceptives? -</p> - -<p> - You're - <<if $PC.preg == -1>> - not interested in being a mother. - [[Risky|PC Preg Intro][$PC.preg = 0]] - <<elseif $PC.preg == 0>> - fertile and you know the risks. - [[Safe|PC Preg Intro][$PC.preg = -1]] | [[About that...|PC Preg Intro][$PC.preg = 10]] - <<elseif $PC.preg > 42>> - proudly pregnant with octuplets and they are coming right now. - [[Not pregnant|PC Preg Intro][$PC.preg = 0, $PC.pregType = 0, $PC.labor = 0]] - <<elseif $PC.preg > 37>> - <<print $PC.preg>> weeks pregnant and very close to being due. - [[Not pregnant|PC Preg Intro][$PC.preg = 0, $PC.pregType = 0]] - | [[Overdid the fertility agents|PC Preg Intro][$PC.preg = 43, $PC.pregType = 8, $PC.labor = 1]] - <<else>> - already pregnant. - [[Fertile|PC Preg Intro][$PC.preg = 0]] - | [[Make that very pregnant|PC Preg Intro][$PC.preg = 40]] - <</if>> - <div class="indent note"> - Being or becoming pregnant will raise difficulty. - </div> -</p> - -<p class="intro question"> - Hormones can be an interesting thing, but how do they affect you? -</p> - -<p> - You're - <<if $PC.pregMood == 1>> - gentle and motherly when you're hormonal. - [[Normal|PC Preg Intro][$PC.pregMood = 0]] | [[Aggressive|PC Preg Intro][$PC.pregMood = 2]] - <<elseif $PC.pregMood == 0>> - in complete control of yourself. - [[Motherly|PC Preg Intro][$PC.pregMood = 1]] | [[Aggressive|PC Preg Intro][$PC.pregMood = 2]] - <<else>> - aggressive and domineering when you're hormonal. - [[Normal|PC Preg Intro][$PC.pregMood = 0]] | [[Motherly|PC Preg Intro][$PC.pregMood = 1]] - <</if>> - <div class="indent note"> - Hormone induced moods may alter some sex scenes, as well as change slaves' reactions to you. - </div> -</p> -<p> - [[Confirm player character customization|PC Experience Intro]] -</p> diff --git a/src/events/intro/pcRumorIntro.js b/src/events/intro/pcRumorIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..c722522f481a025e287de6aa60f49d356c93d9db --- /dev/null +++ b/src/events/intro/pcRumorIntro.js @@ -0,0 +1,48 @@ +App.Intro.PCRumorIntro = function() { + // :: PC Experience Intro [nobr] + const node = new DocumentFragment(); + + delete V.showSecExp; + + App.Events.addParagraph(node, [ + `Who you are is something that you will have to define for yourself through your actions. Once you own an arcology, no one will be in a position to apply moral scorekeeping to you. In the brave new world of the Free Cities, you will be free to define yourself as the sum of your actions, rather than as the product of your past. The first decision that will define who you are as an arcology owner is your choice of method in acquiring one.`, + App.UI.DOM.makeElement("span", `What approach will you take?`, ["intro", "question"]) + ]); + + makeOption( + "A judicious application of funds", "wealth", + App.Events.makeNode([`Start with <span class="cash inc">extra money,</span> since you were wealthy enough to buy an arcology.`]) + ); + + makeOption( + "Hard work and diligence", "diligence", + App.Events.makeNode([`New slaves will <span class="hotpink">hate you less,</span> since it will be known that you worked hard to earn your position.`]) + ); + + makeOption( + "The remorseless use of force", "force", + App.Events.makeNode([`New slaves <span class="gold">will fear you more,</span> since rumors about your violent takeover will inevitably circulate.`]) + ); + + makeOption( + "Clever social engineering", "social engineering", + App.Events.makeNode([`Start with the <span class="green">first societal option unlocked,</span> since you manipulated the arcology's citizens.`]) + ); + + makeOption( + "Blind luck", "luck", + App.Events.makeNode([`Start with a <span class="green">good reputation,</span> since the story of your unlikely accession will be famous.`]) + ); + + return node; + + function makeOption(linkTitle, career, desc) { + App.UI.DOM.appendNewElement("div", node, App.UI.DOM.passageLink( + linkTitle, + "Takeover Target", + () => V.PC.rumor = desc + )); + + App.UI.DOM.appendNewElement("div", node, desc, ["indent", "note"]); + } +}; diff --git a/src/events/intro/pcRumorIntro.tw b/src/events/intro/pcRumorIntro.tw deleted file mode 100644 index b68fcbe357dd9dfd84fd2f57f7f63ce558c8b879..0000000000000000000000000000000000000000 --- a/src/events/intro/pcRumorIntro.tw +++ /dev/null @@ -1,44 +0,0 @@ -:: PC Rumor Intro [nobr] - -<<unset $showSecExp>> -<p> - Who you are is something that you will have to define for yourself through your actions. Once you own an arcology, no one will be in a position to apply moral scorekeeping to you. In the brave new world of the Free Cities, you will be free to define yourself as the sum of your actions, rather than as the product of your past. The first decision that will define who you are as an arcology owner is your choice of method in acquiring one. - <span class="intro question"> - What approach will you take? - </span> -</p> - -<div> - [[A judicious application of funds|Takeover Target][$PC.rumor = "wealth"]] -</div> -<div class="indent note"> - Start with <span class="cash inc">extra money,</span> since you were wealthy enough to buy an arcology. -</div> - -<div> - [[Hard work and diligence|Takeover Target][$PC.rumor = "diligence"]] -</div> -<div class="indent note"> - New slaves will @@.hotpink;hate you less,@@ since it will be known that you worked hard to earn your position. -</div> - -<div> - [[The remorseless use of force|Takeover Target][$PC.rumor = "force"]] -</div> -<div class="indent note"> - New slaves @@.gold;will fear you more,@@ since rumors about your violent takeover will inevitably circulate. -</div> - -<div> - [[Clever social engineering|Takeover Target][$PC.rumor = "social engineering"]] -</div> -<div class="indent note"> - Start with the @@.green;first societal option unlocked,@@ since you manipulated the arcology's citizens. -</div> - -<div> - [[Blind luck|Takeover Target][$PC.rumor = "luck"]] -</div> -<div class="indent note"> - Start with a @@.green;good reputation,@@ since the story of your unlikely accession will be famous. -</div> diff --git a/src/events/intro/slaveAgeIntro.js b/src/events/intro/slaveAgeIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..570e53552460281e0b487103fb6b390ee02ec317 --- /dev/null +++ b/src/events/intro/slaveAgeIntro.js @@ -0,0 +1,51 @@ +App.Intro.slaveAgeIntro = function() { + const node = new DocumentFragment(); + // :: Slave Age Intro [nobr] + + App.UI.DOM.appendNewElement("p", node, `Do you want to see content involving girls younger than 18 in this game?`, ["intro", "question"]); + + makeOption([ + App.UI.DOM.passageLink("No.", "PC Body Intro", () => { + V.minimumSlaveAge = 18; + V.pedo_mode = 0; + }), + App.UI.DOM.makeElement("span", `All slaves will be at least 18 years old, and slavery of children will be illegal in the Free Cities.`, "note") + ]); + + makeOption([ + `Yes, I wish to see girls as young as`, + App.UI.DOM.makeTextBox(V.minimumSlaveAge, (v) => V.minimumSlaveAge = v, true), + App.UI.DOM.passageLink("Continue.", "PC Body Intro", () => { + V.pedo_mode = 0; + }), + ]); + + makeOption([ + `Yes, and`, + App.UI.DOM.passageLink("I just want lots of lolis.", "PC Body Intro", () => { + V.minimumSlaveAge = 3; + V.pedo_mode = 1; + }), + App.UI.DOM.makeElement("span", `Nearly all randomly generated slaves will be under the age of 18, although custom slaves and slaves related to specific events may be older.`, "note") + ]); + + makeOption([ + `Yes,`, + App.UI.DOM.passageLink("I wish to see them grow up and become fertile.", "PC Body Intro", () => { + V.minimumSlaveAge = 3; + V.pedo_mode = 0; + V.precociousPuberty = 1; + V.loliGrow = 1; + V.fertilityAge = 10; + V.potencyAge = 12; + V.seeAge = 1; + }), + App.UI.DOM.makeElement("span", `Preset. Slaves' age will be random from minimal possible age. They can be made fertile younger than normal puberty age (10) in some cases, and grow up naturally.`, "note") + ]); + + return node; + + function makeOption(array) { + App.UI.DOM.appendNewElement("div", node, App.Events.makeNode(array)); + } +}; diff --git a/src/events/intro/slaveAgeIntro.tw b/src/events/intro/slaveAgeIntro.tw deleted file mode 100644 index 844f1f0718f7af3a09198590ccb3e5cd6cc87d5d..0000000000000000000000000000000000000000 --- a/src/events/intro/slaveAgeIntro.tw +++ /dev/null @@ -1,27 +0,0 @@ -:: Slave Age Intro [nobr] - -<p class="intro question"> - Do you want to see content involving girls younger than 18 in this game? -</p> - -<div> - [[No.|PC Body Intro][$minimumSlaveAge = 18, $pedo_mode = 0]] - <span class="note"> - All slaves will be at least 18 years old, and slavery of children will be illegal in the Free Cities. - </span> -</div> -<div> - Yes, I wish to see girls as young as <<textbox "$minimumSlaveAge" $minimumSlaveAge "PC Body Intro">> [[Continue|PC Body Intro][$pedo_mode = 0]] -</div> -<div> - Yes, and [[I just want lots of lolis.|PC Body Intro][$minimumSlaveAge = 3, $pedo_mode = 1]] - <span class="note"> - Nearly all randomly generated slaves will be under the age of 18, although custom slaves and slaves related to specific events may be older. - </span> -</div> -<div> - Yes, [[I wish to see them grow up and become fertile.|PC Body Intro][$minimumSlaveAge = 3, $pedo_mode = 0, $precociousPuberty = 1, $loliGrow = 1, $fertilityAge = 10, $potencyAge = 12, $seeAge = 1]] - <span class="note"> - Preset. Slaves' age will be random from minimal possible age. They can be made fertile younger than normal puberty age (10) in some cases, and grow up naturally. - </span> -</div> diff --git a/src/events/intro/takeoverTarget.js b/src/events/intro/takeoverTarget.js new file mode 100644 index 0000000000000000000000000000000000000000..ae52407a0cde46d8da4457b2195fec3ee10056c5 --- /dev/null +++ b/src/events/intro/takeoverTarget.js @@ -0,0 +1,54 @@ +App.Intro.takeoverTarget = function() { + // :: Takeover Target [nobr] + const node = new DocumentFragment(); + let r = []; + r.push(`Before you deploy the`); + if (V.PC.rumor === "wealth") { + r.push(`financial reserves that`); + } else if (V.PC.rumor === "diligence") { + r.push(`carefully constructed plan that`); + } else if (V.PC.rumor === "force") { + r.push(`mercenaries and`); + if (V.continent === "Eastern Europe") { // maskirovka// + } else { + r.push(`cover plan`); + } + r.push(`that`); + } else if (V.PC.rumor === "social engineering") { + r.push(`clever social manipulation that`); + } else { + r.push(`optimistic plan you hope`); + } + r.push(`will allow you to take over an arcology, you need to select a target. There are a number of vulnerable arcologies that you could`); + if (V.PC.rumor === "wealth") { + r.push(`attempt a hostile takeover of`); + } else if (V.PC.rumor === "diligence") { + r.push(`work to take over`); + } else if (V.PC.rumor === "force") { + r.push(`attack`); + } else if (V.PC.rumor === "social engineering") { + r.push(`infiltrate`); + } else { + r.push(`aspire to take over`); + } + r.push(`with a reasonable chance of success. Free Cities are volatile places, even compared to the troubled state of the rest of the world. There are always arcologies whose owners are on the brink of failure, and you could target one of them.`); + if (V.PC.career === "arcology owner") { + r.push(`(Since you've <span class="springgreen">owned an arcology before,</span> you identify more potential target arcologies than a novice might.)`); + } + r.push(`Alternatively, arcologies are being built every day, and their owners' control is often uncertain.`); + + r.push(App.UI.DOM.makeElement("div", `Which arcology will you target?`, ["intro", "question"])); + App.Events.addParagraph(node, r); + + const card = App.UI.DOM.appendNewElement("div", node, null, "card"); + card.append(App.UI.DOM.passageLink( + "A newly constructed arcology", + "Terrain Intro", + () => V.targetArcology.fs = "New" + )); + App.UI.DOM.appendNewElement("div", card, `With many new arcologies being constructed, you will be able to select which area of the world and type of Free City you'd like your target arcology to be located in.`, ["indent", "note"]); + App.UI.DOM.appendNewElement("div", card, `Recommended for new players.`, ["indent", "note"]); + + node.append(App.Intro.generateEstablishedArcologies()); + return node; +}; diff --git a/src/events/intro/takeoverTarget.tw b/src/events/intro/takeoverTarget.tw deleted file mode 100644 index ec3784d8f6ca7add0e509f84fd69c632cd5b1a44..0000000000000000000000000000000000000000 --- a/src/events/intro/takeoverTarget.tw +++ /dev/null @@ -1,46 +0,0 @@ -:: Takeover Target [nobr] - -<p> - Before you deploy the - <<if $PC.rumor == "wealth">> - financial reserves that - <<elseif $PC.rumor == "diligence">> - carefully constructed plan that - <<elseif $PC.rumor == "force">> - mercenaries and <<if $continent == "Eastern Europe">>//maskirovka//<<else>>cover plan<</if>> that - <<elseif $PC.rumor == "social engineering">> - clever social manipulation that - <<else>> - optimistic plan you hope - <</if>> - will allow you to take over an arcology, you need to select a target. There are a number of vulnerable arcologies that you could - <<if $PC.rumor == "wealth">> - attempt a hostile takeover of - <<elseif $PC.rumor == "diligence">> - work to take over - <<elseif $PC.rumor == "force">> - attack - <<elseif $PC.rumor == "social engineering">> - infiltrate - <<else>> - aspire to take over - <</if>> - with a reasonable chance of success. Free Cities are volatile places, even compared to the troubled state of the rest of the world. There are always arcologies whose owners are on the brink of failure, and you could target one of them. - <<if $PC.career == "arcology owner">>(Since you've @@.springgreen;owned an arcology before,@@ you identify more potential target arcologies than a novice might.)<</if>> - Alternatively, arcologies are being built every day, and their owners' control is often uncertain. - <span class="intro question"> - Which arcology will you target? - </span> -</p> - -<div class="card"> -[[A newly constructed arcology|Terrain Intro][$targetArcology.fs = "New"]] -<div class="indent note"> - With many new arcologies being constructed, you will be able to select which area of the world and type of Free City you'd like your target arcology to be located in. -</div> -<div class="indent note"> - Recommended for new players. -</div> -</div> - -<<includeDOM App.Intro.generateEstablishedArcologies()>> diff --git a/src/events/intro/terrainIntro.js b/src/events/intro/terrainIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..d9aa6ce2347382b8b41731c83d916851890e0da5 --- /dev/null +++ b/src/events/intro/terrainIntro.js @@ -0,0 +1,97 @@ +App.Intro.terrainIntro = function() { + // :: Terrain Intro [nobr] + const node = new DocumentFragment(); + + App.Events.addParagraph(node, [`The Free Cities are located wherever the rule of law is weak enough or permissive enough to allow a small area to secede, and where founders can afford to buy an area on which to build.`]); + + App.Events.addParagraph(node, [`Many Free Cities are therefore located in marginal, rural terrain. Founding a Free City in such an area is easy, and can usually be accomplished with the indifference or even connivance of the old country from which it secedes. After all, the potential commercial benefits are great, and the loss of underused land is only significant in the moral sense.`]); + + App.Events.addParagraph(node, [`Some Free Cities are located on water. Though some areas of shallow sea over the continental shelves hide valuable resources, others are neglected. Arcologies are such massive structures that it is very possible to design them to float anchored to the seabed.`]); + + App.Events.addParagraph(node, [`Finally, a few Free Cities have been carved out from old world cities. Urban decay has left the hearts of many cities ripe for this. Many old world countries resist this kind of secession, but this rarest, smallest, and densest kind of Free City can offer its surrounding nation a great deal of economic advantage.`]); + + App.UI.DOM.appendNewElement("p", node, `Which kind of Free City hosts your arcology?`, ["intro", "question"]); + + let card = App.UI.DOM.appendNewElement("div", node, App.UI.DOM.passageLink( + "Urban", + "Location Intro", + () => V.terrain = "urban" + ), "card"); + cardLine(`<span class="noteworthy">Low</span> minimum slave value and initial <span class="noteworthy">bear market</span> for slaves.`); + cardLine(`<span class="positive">High</span> ease of commerce with the old world.`); + cardLine(`<span class="positive">High</span> access to refugees and other desperate people.`); + cardLine(`<span class="warning">Low</span> cultural independence.`); + cardLine(`Unusually compact arcology with few manufacturing sectors.`); + + card = App.UI.DOM.appendNewElement("div", node, App.UI.DOM.passageLink( + "Rural", + "Location Intro", + () => V.terrain = "rural" + ), "card"); + cardLine(`High</span> minimum slave value and initial <span class="noteworthy">bull market</span> for slaves.`); + cardLine(`Moderate ease of commerce with the old world.`); + cardLine(`Moderate access to refugees and other desperate people.`); + cardLine(`Moderate cultural independence.`); + cardLine(`Widespread arcology with many manufacturing sectors.`); + + card = App.UI.DOM.appendNewElement("div", node, App.UI.DOM.passageLink( + "Ravine", + "Location Intro", + () => V.terrain = "ravine" + ), "card"); + cardLine(`<span class="noteworthy">High</span> minimum slave value and initial <span class="noteworthy">bull market</span> for slaves.`); + cardLine(`<span class="warning">Low</span> ease of commerce with the old world.`); + cardLine(`<span class="warning">Very low</span> access to refugees and other desperate people.`); + cardLine(`<span class="positive">High</span> cultural independence.`); + cardLine(`The arcology mostly being hidden inside the ravine leads to an unusual layout.`); + + card = App.UI.DOM.appendNewElement("div", node, App.UI.DOM.passageLink( + "Marine", + "Location Intro", + () => V.terrain = "marine" + ), "card"); + cardLine(`Moderate minimum slave value and initially balanced market for slaves.`); + cardLine(`Moderate ease of commerce with the old world.`); + cardLine(`<span class="warning">Low</span> access to refugees and other desperate people.`); + cardLine(`<span class="positive">High</span> cultural independence.`); + cardLine(`Large amount of markets and an extra shop sector.`); + + card = App.UI.DOM.appendNewElement("div", node, App.UI.DOM.passageLink( + "Oceanic", + "Location Intro", + () => V.terrain = "oceanic" + ), "card"); + cardLine(`<span class="noteworthy">High</span> minimum slave value and initial <span class="noteworthy">bull market</span> for slaves.`); + cardLine(`Moderate ease of commerce with the old world.`); + cardLine(`<span class="warning">Very low</span> access to refugees and other desperate people.`); + cardLine(`<span class="positive">Very high</span> cultural independence.`); + cardLine(`This unique location attracts the wealthy leading to initial luxury apartments.`); + cardLine(`Ensures access to slaves from all over the world and will not associate the arcology with a continent.`); + if (V.showSecExp === 1) { + cardLine(`Oceanic arcologies will not be subjects of attacks.`); + } + + function cardLine(string) { + App.Events.addNode(card, [string], "div", "indent"); + } + + if (V.showSecExp === 1) { + App.UI.DOM.link( + "Hide Security Expansion Mod effects", + () => { + V.showSecExp = 0; + App.UI.reload(); + } + ); + } else { + App.UI.DOM.link( + "Show Security Expansion Mod effects", + () => { + V.showSecExp = 1; + App.UI.reload(); + } + ); + } + + return node; +}; diff --git a/src/events/intro/terrainIntro.tw b/src/events/intro/terrainIntro.tw deleted file mode 100644 index 91b3275ee3713901c8146a4c08eaca54baa3515e..0000000000000000000000000000000000000000 --- a/src/events/intro/terrainIntro.tw +++ /dev/null @@ -1,74 +0,0 @@ -:: Terrain Intro [nobr] - -<p> - The Free Cities are located wherever the rule of law is weak enough or permissive enough to allow a small area to secede, and where founders can afford to buy an area on which to build. -</p> -<p> - Many Free Cities are therefore located in marginal, rural terrain. Founding a Free City in such an area is easy, and can usually be accomplished with the indifference or even connivance of the old country from which it secedes. After all, the potential commercial benefits are great, and the loss of underused land is only significant in the moral sense. -</p> -<p> - Some Free Cities are located on water. Though some areas of shallow sea over the continental shelves hide valuable resources, others are neglected. Arcologies are such massive structures that it is very possible to design them to float anchored to the seabed. -</p> -<p> - Finally, a few Free Cities have been carved out from old world cities. Urban decay has left the hearts of many cities ripe for this. Many old world countries resist this kind of secession, but this rarest, smallest, and densest kind of Free City can offer its surrounding nation a great deal of economic advantage. -</p> -<p> - <span class="intro question">Which kind of Free City hosts your arcology?</span> -</p> - -<div class="card"> - [[Urban|Location Intro][$terrain = "urban"]] - <div class="indent"><span class="noteworthy">Low</span> minimum slave value and initial <span class="noteworthy">bear market</span> for slaves.</div> - <div class="indent"><span class="positive">High</span> ease of commerce with the old world.</div> - <div class="indent"><span class="positive">High</span> access to refugees and other desperate people.</div> - <div class="indent"><span class="warning">Low</span> cultural independence.</div> - <div class="indent">Unusually compact arcology with few manufacturing sectors.</div> -</div> -<div class="card"> - [[Rural|Location Intro][$terrain = "rural"]] - <div class="indent"><span class="noteworthy">High</span> minimum slave value and initial <span class="noteworthy">bull market</span> for slaves.</div> - <div class="indent">Moderate ease of commerce with the old world.</div> - <div class="indent">Moderate access to refugees and other desperate people.</div> - <div class="indent">Moderate cultural independence.</div> - <div class="indent">Widespread arcology with many manufacturing sectors.</div> -</div> -<div class="card"> - [[Ravine|Location Intro][$terrain = "ravine"]] - <div class="indent"><span class="noteworthy">High</span> minimum slave value and initial <span class="noteworthy">bull market</span> for slaves.</div> - <div class="indent"><span class="warning">Low</span> ease of commerce with the old world.</div> - <div class="indent"><span class="warning">Very low</span> access to refugees and other desperate people.</div> - <div class="indent"><span class="positive">High</span> cultural independence.</div> - <div class="indent">The arcology mostly being hidden inside the ravine leads to an unusual layout.</div> -</div> -<div class="card"> - [[Marine|Location Intro][$terrain = "marine"]] - <div class="indent">Moderate minimum slave value and initially balanced market for slaves.</div> - <div class="indent">Moderate ease of commerce with the old world.</div> - <div class="indent"><span class="warning">Low</span> access to refugees and other desperate people.</div> - <div class="indent"><span class="positive">High</span> cultural independence.</div> - <div class="indent">Large amount of markets and an extra shop sector.</div> -</div> -<div class="card"> - [[Oceanic|Intro Summary][$terrain = "oceanic"]] - <div class="indent"><span class="noteworthy">High</span> minimum slave value and initial <span class="noteworthy">bull market</span> for slaves.</div> - <div class="indent">Moderate ease of commerce with the old world.</div> - <div class="indent"><span class="warning">Very low</span> access to refugees and other desperate people.</div> - <div class="indent"><span class="positive">Very high</span> cultural independence.</div> - <div class="indent">This unique location attracts the wealthy leading to initial luxury apartments.</div> - <div class="indent">Ensures access to slaves from all over the world and will not associate the arcology with a continent.</div> - <<if $showSecExp == 1>> - <div class="indent">Oceanic arcologies will not be subjects of attacks.</div> - <</if>> -</div> - -<p> - <<if $showSecExp == 1>> - <<link "Hide Security Expansion Mod effects" "Terrain Intro">> - <<set $showSecExp = 0>> - <</link>> - <<else>> - <<link "Show Security Expansion Mod effects" "Terrain Intro">> - <<set $showSecExp = 1>> - <</link>> - <</if>> -</p> diff --git a/src/events/intro/tradeIntro.js b/src/events/intro/tradeIntro.js new file mode 100644 index 0000000000000000000000000000000000000000..ef7f39db17c74be9390096cf03f6e27f3c49be34 --- /dev/null +++ b/src/events/intro/tradeIntro.js @@ -0,0 +1,39 @@ +App.Intro.tradeIntro = function() { + const node = new DocumentFragment(); + // :: Trade Intro [nobr] + + App.Events.addParagraph(node, [ + `Most of the Free Cities are run on radically libertarian or even anarcho-capitalist principles. The first Free Cities experimented with indentured servitude, and this rapidly developed into widespread slavery. By now, the Free Cities collectively are a fundamentally slaveowning society and maintain a thriving slave trade that feeds off the terrible conditions in parts of the old world.`, + App.UI.DOM.makeElement("span", `What attitude have the old world countries generally taken towards this trade?`, ["intro", "question"]) + ]); + + App.Events.addResponses(node, [ + new App.Events.Result(`They've turned a blind eye, or even been complicit.`, complicit, `Slaves from all across the world will appear.`), + new App.Events.Result(`They've done what little they can to stop it.`, little, `Almost all slaves will be from the continent where the arcology is located.`), + new App.Events.Result(`Reactions have been mixed.`, mixed, `This will bypass arcology location restrictions, allowing you to adjust the nationalities encountered when buying non-customizable slaves.`), + ]); + + return node; + + function complicit() { + V.internationalTrade = 1; + V.customVariety = 0; + Engine.play("Extreme Intro"); + return ``; + } + + function little() { + V.internationalTrade = 0; + V.customVariety = 0; + Engine.play("Extreme Intro"); + return ``; + } + + function mixed() { + V.internationalTrade = 0; + V.customVariety = 1; + V.customWA = 1; + Engine.play("Customize Slave Trade"); + return ``; + } +}; diff --git a/src/events/intro/tradeIntro.tw b/src/events/intro/tradeIntro.tw deleted file mode 100644 index c6b6086bb7cd0678698133946aa5e4579475b228..0000000000000000000000000000000000000000 --- a/src/events/intro/tradeIntro.tw +++ /dev/null @@ -1,31 +0,0 @@ -:: Trade Intro [nobr] - -<p> - Most of the Free Cities are run on radically libertarian or even anarcho-capitalist principles. The first Free Cities experimented with indentured servitude, and this rapidly developed into widespread slavery. By now, the Free Cities collectively are a fundamentally slaveowning society and maintain a thriving slave trade that feeds off the terrible conditions in parts of the old world. - <span class="intro question"> - What attitude have the old world countries generally taken towards this trade? - </span> -</p> -<p> - <div> - [[They've turned a blind eye, or even been complicit.|Extreme Intro][$internationalTrade = 1, $customVariety = 0]] - <span class="note"> - Slaves from all across the world will appear. - </span> - </div> - <div> - [[They've done what little they can to stop it.|Extreme Intro][$internationalTrade = 0, $customVariety = 0]] - <span class="note"> - Almost all slaves will be from the continent where the arcology is located. - </span> - </div> - <div> - <<link "Reactions have been mixed.">> - <<set $internationalTrade = 0, $customVariety = 1, $customWA = 1>> - <<goto "Customize Slave Trade">> - <</link>> - <span class="note"> - This will bypass arcology location restrictions, allowing you to adjust the nationalities encountered when buying non-customizable slaves. - </span> - </div> -</p> \ No newline at end of file