From 7b822b9278dc8f80631b69c6fd1e2a736ebb5e32 Mon Sep 17 00:00:00 2001 From: Blank_Alt <12406-Blank_Alt@users.noreply.gitgud.io> Date: Sat, 13 Mar 2021 05:28:14 +0000 Subject: [PATCH] Devoted tiwns to JS --- devNotes/jsEventCreationGuide.md | 6 +- src/endWeek/nextWeek/resetGlobals.js | 2 - src/events/randomEvent.js | 1 + src/events/reDevotedTwins.js | 95 +++++++++++++++++++ src/uncategorized/randomNonindividualEvent.tw | 12 --- src/uncategorized/reDevotedTwins.tw | 65 ------------- 6 files changed, 100 insertions(+), 81 deletions(-) create mode 100644 src/events/reDevotedTwins.js delete mode 100644 src/uncategorized/reDevotedTwins.tw diff --git a/devNotes/jsEventCreationGuide.md b/devNotes/jsEventCreationGuide.md index d80ac7cfa6f..65709fcdeff 100644 --- a/devNotes/jsEventCreationGuide.md +++ b/devNotes/jsEventCreationGuide.md @@ -100,5 +100,7 @@ If everything works as intended you should see output ## Examples # Single slave -[src/events/RESS/devotedFearfulSlave.js](src/events/RESS/devotedFearfulSlave.js) -which was converted as apart of https://gitgud.io/pregmodfan/fc-pregmod/-/merge_requests/8843. \ No newline at end of file +[src/events/RESS/devotedFearfulSlave.js](src/events/RESS/devotedFearfulSlave.js) which was converted as apart of https://gitgud.io/pregmodfan/fc-pregmod/-/merge_requests/8843. + +# Dual slave +[src/events/reDevotedTwins.js](src/events/reDevotedTwins.js) which was converted as apart of https://gitgud.io/pregmodfan/fc-pregmod/-/merge_requests/9043. \ No newline at end of file diff --git a/src/endWeek/nextWeek/resetGlobals.js b/src/endWeek/nextWeek/resetGlobals.js index f1fdc241ee7..000255c8a53 100644 --- a/src/endWeek/nextWeek/resetGlobals.js +++ b/src/endWeek/nextWeek/resetGlobals.js @@ -10,8 +10,6 @@ App.EndWeek.resetGlobals = function() { V.daughterSlave = -1; V.devMother = -1; V.devDaughter = -1; - V.alphaTwin = -1; - V.betaTwin = -1; V.youngerSister = -1; V.olderSister = -1; V.boobsID = -1; diff --git a/src/events/randomEvent.js b/src/events/randomEvent.js index 113713da759..21b7af47d9f 100644 --- a/src/events/randomEvent.js +++ b/src/events/randomEvent.js @@ -86,6 +86,7 @@ App.Events.getNonindividualEvents = function() { new App.Events.RERelativeRecruiter(), new App.Events.REStaffedMorning(), new App.Events.REFullBed(), + new App.Events.REDevotedTwins(), new App.Events.RERoyalBlood(), new App.Events.REArcologyInspection(), diff --git a/src/events/reDevotedTwins.js b/src/events/reDevotedTwins.js new file mode 100644 index 00000000000..77ea3b5a025 --- /dev/null +++ b/src/events/reDevotedTwins.js @@ -0,0 +1,95 @@ +App.Events.REDevotedTwins = class REDevotedTwins extends App.Events.BaseEvent { + eventPrerequisites() { + // Conditional example + return [ + () => V.seeIncest === 1 + ]; + } + + actorPrerequisites() { + return [ + [ + s => s.sisters > 0, + s => s.anus > 0, + s => s.devotion > 50, + s => canWalk(s) + ], + [ + s => areSisters(s, getSlave(this.actors[0])) === 1, + s => s.anus > 0, + s => s.devotion > 50, + s => canWalk(s) + ] + ]; + } + + execute(node) { + /** @type {Array<App.Entity.SlaveState>} */ + let [alphaTwin, betaTwin] = this.actors.map(a => getSlave(a)); + + V.nextButton = "Continue"; + V.nextLink = "RIE Eligibility Check"; + + App.Events.drawEventArt(node, [alphaTwin, betaTwin]); + + let t = []; + + t.push(`${alphaTwin.slaveName} and ${betaTwin.slaveName} are such good and devoted slaves that they happily do everything together.`); + t.push(`They sleep ${hasBothArms(alphaTwin) && hasBothArms(betaTwin) ? "in each other's arms" : 'together'}, bathe together, work together whenever they can, and fuck together.`); + t.push("For a while they masturbated together until they became so habituated to sexual slavery that they stopped seeing much distinction between masturbation and sex with one another."); + t.push("At the moment, they're getting ready for their day, chatting quietly and helping each other."); + + App.Events.addParagraph(node, t); + + App.Events.addResponses(node, [ + new App.Events.Result(`Take them out for the morning`, morningWalk), + new App.Events.Result(`Use them side by side`, threesome) + ]); + + function morningWalk() { + t = []; + t.push(`You head out of your penthouse with a pretty sex slave under each arm.`); + t.push(`They're attentive companions, doing everything they can to mirror each other as they show off their bodies to onlookers.`); + t.push(`It's a bright, sunny day, so you walk them up and down a busy glassed-in galleria.`); + t.push(`They clearly expect you to fuck them in public, but for once you just enjoy a couple of hours with them.`); + t.push(`They start disappointed that you aren't going to use them, but they quickly get over it and enjoy preening under your arms.`); + t.push(`<span class="trust inc">They have both become more trusting of you,</span> and <span class="green">your reputation has increased considerably.</span>`); + + for (const slave of [alphaTwin, betaTwin]) { + slave.trust += 4; + repX(2500, "event", slave); + } + return t; + } + + function threesome() { + t = []; + t.push(`Slave twins inevitably get used to threesomes with their sibling, and ${alphaTwin.slaveName} and ${betaTwin.slaveName} are no exception.`); + t.push(`They greet you with every appearance of arousal and begin a carefully balanced routine — foreplay with you, of course, but whatever parts of them aren't working on you work on the other slave.`); + t.push(`They stroke you while making out, stroke each other while sucking you to rock hardness, and finger each others' holes while`); + if (V.PC.vagina !== -1) { + t.push(`crowding their faces against your pussy.`); + t.push(`You reach down and seize a nipple in each hand, pulling them upward so they can suck your nipples instead; they use manual stimulation to keep you going while they do.`); + t.push(`With one straddling each of your thighs, grinding shamelessly, you can reach around and molest their butts with your own hands.`); + } else { + t.push(`rubbing four breasts up and down your dick. Since you only have one cock, the symmetry ends when you start fucking them.`); + t.push(`As you switch from hole to hole, whichever twin isn't getting fucked at the moment uses their mouth and hands to stimulate your balls and their twin's fuckhole as you pound it.`); + t.push(`When you finally cum in ${betaTwin.slaveName}, ${alphaTwin.slaveName} sucks it out and they kiss deeply to share your ejaculate.`); + } + t.push(`<span class="devotion inc">They have both become more devoted to you.</span>`); + + for (const slave of [alphaTwin, betaTwin]) { + slave.devotion += 4; + if (canDoAnal(slave)) { + actX(slave, "anal"); + } else if (canDoVaginal(slave)) { + actX(slave, "vaginal"); + } else { + actX(slave, "oral"); + } + } + + return t; + } + } +}; diff --git a/src/uncategorized/randomNonindividualEvent.tw b/src/uncategorized/randomNonindividualEvent.tw index e8d8ccfdc6e..0cdf92e9fed 100644 --- a/src/uncategorized/randomNonindividualEvent.tw +++ b/src/uncategorized/randomNonindividualEvent.tw @@ -143,18 +143,6 @@ <</if>> <</for>> - <<set _twins = _relatedSlaves.filter(function(s) { return s.sisters > 0 && s.anus > 0 && s.devotion > 50 && canWalk(s); })>> - <<for _twins.length > 0>> - <<set $alphaTwin = _twins.pluck()>> - <<set $betaTwin = randomTwinSister($alphaTwin)>> - <<if (def $betaTwin) && ($betaTwin.anus > 0) && ($betaTwin.devotion > 50) && canWalk($betaTwin)>> - <<set $events.push("RE devoted twins")>> - <<set $alphaTwin = $alphaTwin.ID>> - <<set $betaTwin = $betaTwin.ID>> - <<break>> - <</if>> - <</for>> - <</if>> /* Fetish Interest Events */ diff --git a/src/uncategorized/reDevotedTwins.tw b/src/uncategorized/reDevotedTwins.tw deleted file mode 100644 index e70b2682b02..00000000000 --- a/src/uncategorized/reDevotedTwins.tw +++ /dev/null @@ -1,65 +0,0 @@ -:: RE devoted twins [nobr] - -<<set $nextButton = "Continue", $nextLink = "RIE Eligibility Check">> - -<<set $i = $slaveIndices[$alphaTwin]>> -<<set $j = $slaveIndices[$betaTwin]>> - -<span id="art-frame"> - /* 000-250-006 */ - <<if $seeImages == 1>> - <div class="imageColumn"> - <div class="imageRef medImg"> - <<SlaveArt $slaves[$j] 2 0>> - </div> - <div class="imageRef medImg"> - <<SlaveArt $slaves[$i] 2 0>> - </div> - </div> - <</if>> - /* 000-250-006 */ -</span> - -$slaves[$i].slaveName and $slaves[$j].slaveName are such good and devoted slaves that they happily do everything together. They sleep <<if hasBothArms($slaves[$i]) && hasBothArms($slaves[$j])>>in each other's arms<<else>>together<</if>>, bathe together, work together whenever they can, and fuck together. For a while they masturbated together until they became so habituated to sexual slavery that they stopped seeing much distinction between masturbation and sex with one another. At the moment, they're getting ready for their day, chatting quietly and helping each other. -<br><br> -<span id="result"> -<<link "Take them out for the morning">> - <<replace "#result">> - <br>You head out of your penthouse with a pretty sex slave under each arm. They're attentive companions, doing everything they can to mirror each other as they show off their bodies to onlookers. It's a bright, sunny day, so you walk them up and down a busy glassed-in galleria. They clearly expect you to fuck them in public, but for once you just enjoy a couple of hours with them. They start disappointed that you aren't going to use them, but they quickly get over it and enjoy preening under your arms. - @@.mediumaquamarine;They have both become more trusting of you,@@ and @@.green;your reputation has increased considerably.@@ - <<set $slaves[$i].trust += 4, $slaves[$j].trust += 4>> - <<run repX(2500, "event", $slaves[$i])>> - <<run repX(2500, "event", $slaves[$j])>> - <</replace>> -<</link>> -<br><<link "Use them side by side">> - <<replace "#result">> - <br>Slave twins inevitably get used to threesomes with their sibling, and $slaves[$i].slaveName and $slaves[$j].slaveName are no exception. They greet you with every appearance of arousal and begin a carefully balanced routine — foreplay with you, of course, but whatever parts of them aren't working on you work on the other slave. They stroke you while making out, stroke each other while sucking you to rock hardness, and finger each others' holes while <<if $PC.vagina != -1>>crowding their faces against your pussy. You reach down and seize a nipple in each hand, pulling them upward so they can suck your nipples instead; they use manual stimulation to keep you going while they do. With one straddling each of your thighs, grinding shamelessly, you can reach around and molest their butts with your own hands.<<else>>rubbing four breasts up and down your dick. Since you only have one cock, the symmetry ends when you start fucking them. As you switch from hole to hole, whichever twin isn't getting fucked at the moment uses their mouth and hands to stimulate your balls and their twin's fuckhole as you pound it. When you finally cum in $slaves[$j].slaveName, $slaves[$i].slaveName sucks it out and they kiss deeply to share your ejaculate.<</if>> @@.hotpink;They have both become more devoted to you.@@ - - <<set $slaves[$i].devotion += 4, $slaves[$j].devotion += 4>> - - <<if canDoAnal($slaves[$i])>> - <<set $slaves[$i].counter.anal += 1>> - <<set $analTotal += 1>> - <<elseif canDoVaginal($slaves[$i])>> - <<set $slaves[$i].counter.vaginal += 1>> - <<set $vaginalTotal += 1>> - <<else>> - <<set $slaves[$i].counter.oral += 1>> - <<set $oralTotal += 1>> - <</if>> - - <<if canDoAnal($slaves[$j])>> - <<set $slaves[$j].counter.anal += 1>> - <<set $analTotal += 1>> - <<elseif canDoVaginal($slaves[$j])>> - <<set $slaves[$j].counter.vaginal += 1>> - <<set $vaginalTotal += 1>> - <<else>> - <<set $slaves[$j].counter.oral += 1>> - <<set $oralTotal += 1>> - <</if>> - - <</replace>> -<</link>> -</span> -- GitLab