diff --git a/src/events/scheduled/seCoursing.js b/src/events/scheduled/seCoursing.js index f76d9b760cc9d9a8977889785308652318a3783f..0a456dd394ef4c389eb8a634f0480ebe6441aadb 100644 --- a/src/events/scheduled/seCoursing.js +++ b/src/events/scheduled/seCoursing.js @@ -17,7 +17,7 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { V.nextButton = "Continue"; V.nextLink = "Scheduled Event"; V.coursed = 1; - let _seed = 0; + let caught = false; let phallus; const activeLurcher = getSlave(V.LurcherID); @@ -25,6 +25,30 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { He, His, he, him, himself, his, wife, woman } = getPronouns(activeLurcher); + + /** @type {Array<"housewife" | "heavily pregnant" | "virgin" | "disobedient young" | "huge balled" | "feminized" | "disobedient young dickgirl">} */ + const possibleOrigins = []; + if (V.seeDicks !== 100) { + possibleOrigins.push("housewife"); + if (V.seePreg !== 0) { + possibleOrigins.push("heavily pregnant"); + } + possibleOrigins.push("virgin"); + possibleOrigins.push("disobedient young"); + } + if (V.seeDicks !== 0) { + possibleOrigins.push("huge balled"); + possibleOrigins.push("feminized"); + possibleOrigins.push("disobedient young dickgirl"); + } + + const table = App.UI.DOM.appendNewElement("table", node, null, "invisible"); + const hares = [ + genHare(1), + genHare(2), + genHare(3) + ]; + App.Events.drawEventArt(node, activeLurcher, "no clothing"); r.push(`It's time to go coursing. You meet with fellow members of the Coursing Association while the automated maintenance drones clear the plaza and lay down the green, sharing a refined discussion of recent events`); @@ -104,41 +128,10 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { r.push(`${activeLurcher.slaveName} looks at you questioningly, wondering which of the dinging bells ${he} should try to chase down and molest.`); } App.Events.addParagraph(node, r); - r = []; - const possibleOrigins = []; - if (V.seeDicks !== 100) { - possibleOrigins.push("housewife"); - if (V.seePreg !== 0) { - possibleOrigins.push("heavily pregnant"); - } - possibleOrigins.push("virgin"); - possibleOrigins.push("disobedient young"); + for (const hare of hares) { + table.append(hare.row); } - if (V.seeDicks !== 0) { - possibleOrigins.push("huge balled"); - possibleOrigins.push("feminized"); - possibleOrigins.push("disobedient young dickgirl"); - } - - /* - // <style> a table is used here because very short hare descriptions cause images to indent oddly if they are shown. This ensures they are always directly below each other. - r.push(`table.coursing {`); - r.push(`border-style: hidden;`); - r.push(`empty-cells: hide;`); - r.push(`border-collapse: separate;`); - r.push(`border-spacing: 0px 15px;`); - // } - // </style> - // <table class="coursing" border="1"> - */ - const table = App.UI.DOM.appendNewElement("table", node, null, "invisible"); - const hare1 = genHare(1); - table.append(hare1.row); - const hare2 = genHare(2); - table.append(hare2.row); - const hare3 = genHare(3); - table.append(hare3.row); /** @returns {hareResults} */ function genHare(num) { @@ -290,7 +283,7 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { r.push(`To accommodate your blind lurcher, a bell is fastened around ${his2} neck.`); } } else if (origin === "heavily pregnant") { - r.push(`is ${addA(slave.race)} ${girl2}, young and healthy but <span class="pink">heavily pregnant.</span> ${He2}'s probably been selected to be a hare as a joke, or because someone hates ${him2}. `); + r.push(`is ${addA(slave.race)} ${girl2}, young and healthy but <span class="pink">heavily pregnant.</span> ${He2}'s probably been selected to be a hare as a joke, or because someone hates ${him2}.`); if (!canSee(activeLurcher)) { r.push(`To accommodate your blind lurcher, a bell is attached to ${his2} popped navel.`); } @@ -300,22 +293,22 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { r.push(`To accommodate your blind lurcher, a bell is fastened around ${his2} neck.`); } } else if (origin === "disobedient young") { - r.push(`is a fit young ${slave.race} ${girl2}, and is far more watchful and alert than ${his2} fellow hares. ${He2} may be a <span class="pink">disobedient slave</span> here because ${he2} was difficult to train. `); + r.push(`is a fit young ${slave.race} ${girl2}, and is far more watchful and alert than ${his2} fellow hares. ${He2} may be a <span class="pink">disobedient slave</span> here because ${he2} was difficult to train.`); if (!canSee(activeLurcher)) { r.push(`To accommodate your blind lurcher, a bell is fastened around ${his2} neck.`); } } else if (origin === "disobedient young dickgirl") { - r.push(`is a strong young ${slave.race} slave who retains ${his2} cock and balls, and looks determined. Perhaps ${he2}'s a <span class="pink">resistant dickgirl</span> who's been difficult to turn into a good girl. `); + r.push(`is a strong young ${slave.race} slave who retains ${his2} cock and balls, and looks determined. Perhaps ${he2}'s a <span class="pink">resistant dickgirl</span> who's been difficult to turn into a good girl.`); if (!canSee(activeLurcher)) { r.push(`To accommodate your blind lurcher, a bell is fastened around ${his2} cock.`); } } else if (origin === "huge balled") { - r.push(`is ${addA(slave.race)} slave whose distinguishing characteristic is a dangling scrotum and a pair of <span class="pink">huge balls.</span> This impediment bumps against ${his2} thighs as ${he2}'s made ready. `); + r.push(`is ${addA(slave.race)} slave whose distinguishing characteristic is a dangling scrotum and a pair of <span class="pink">huge balls.</span> This impediment bumps against ${his2} thighs as ${he2}'s made ready.`); if (!canSee(activeLurcher)) { r.push(`To accommodate your blind lurcher, a bell is fastened around ${his2} hefty testicles.`); } } else if (origin === "feminized") { - r.push(`is ${addA(slave.race)} bitch with a tiny dick who has been <span class="pink">heavily feminized,</span> yet seems terrified and very new to slavery. ${His2} fake tits and girly behavior must be from ${his2} life before ${he2} was a slave. `); + r.push(`is ${addA(slave.race)} bitch with a tiny dick who has been <span class="pink">heavily feminized,</span> yet seems terrified and very new to slavery. ${His2} fake tits and girly behavior must be from ${his2} life before ${he2} was a slave.`); if (!canSee(activeLurcher)) { r.push(`To accommodate your blind lurcher, a bell is fastened around ${his2} neck.`); } @@ -458,7 +451,7 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { } else { r.push(`gently point ${him} towards the target hare without letting the other competitors or their lurchers see.`); } - r.push(`Then, you gently push ${him} down into ${his} starting crouch. The umpire trips the hares' releases, a few `); + r.push(`Then, you gently push ${him} down into ${his} starting crouch. The umpire trips the hares' releases, a few`); if (V.showInches === 2) { r.push(`yards`); } else { @@ -574,7 +567,7 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { r.push(`${He} seems terrified that ${his} water might break if ${he} tried to move too fast.`); lurcherSpeed -= 10; } else if (activeLurcher.belly >= 120000) { - r.push(`${He} can barely move ${himself}, let alone consider chasing something with ${his} titanic `); + r.push(`${He} can barely move ${himself}, let alone consider chasing something with ${his} titanic`); if (activeLurcher.bellyImplant > 100) { r.push(`belly implant`); } else { @@ -583,7 +576,7 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { r.push(`in the way.`); lurcherSpeed -= 20; } else if (activeLurcher.belly >= 60000) { - r.push(`${He} can barely waddle with ${his} `); + r.push(`${He} can barely waddle with ${his}`); if (activeLurcher.bellyImplant > 100) { r.push(`enormous belly implant.`); } else { @@ -591,7 +584,7 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { } lurcherSpeed -= 10; } else if (activeLurcher.belly >= 10000 && activeLurcher.bellyFluid < 2000) { - r.push(`${He} can barely waddle along with ${his} huge `); + r.push(`${He} can barely waddle along with ${his} huge`); if (activeLurcher.bellyImplant > 100) { r.push(`belly implant.`); } else { @@ -609,15 +602,15 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { lurcherSpeed -= 1; } if (activeLurcher.bellyFluid >= 10000) { - r.push(`${His} hugely bloated, `); + r.push(`${His} hugely bloated,`); r.push(`${activeLurcher.inflationType}-filled belly is taut and painful, forcing ${him} to a slow waddle.`); lurcherSpeed -= 5; } else if (activeLurcher.bellyFluid >= 5000) { - r.push(`${His} bloated, `); + r.push(`${His} bloated,`); r.push(`${activeLurcher.inflationType}-stuffed belly is constantly jiggling and moving, making it extremely difficult to run.`); lurcherSpeed -= 4; } else if (activeLurcher.bellyFluid >= 2000) { - r.push(`${His} distended, `); + r.push(`${His} distended,`); r.push(`${activeLurcher.inflationType}-belly is uncomfortable and heavy, slowing ${him} down.`); lurcherSpeed -= 2; } @@ -662,62 +655,62 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { r.push(`listens for a nearby bell.`); } - // Retarget - const hareNumbers = [1, 2, 3]; - if (obj.speed2 < obj.speed3) { - obj = hare2; - } else { - obj = hare3; - } - ({ - He2, - he2, his2, him2, himself2, woman2, girl2 - } = getPronouns(obj.slave).appendSuffix("2")); - if (canSee(activeLurcher)) { - r.push(`Seeing that the ${obj.origin} hare is slower,`); - } else { - r.push(`hearing the ${obj.origin} hare's bell nearby,`); - } - r.push(`${he} angles after ${him2} instead.`); - if (obj.speed >= lurcherSpeed) { - r.push(`${He} does no better with ${his} new target; ${his} course is over.`); - } else if (random(1, 2) === 1) { - r.push(`One of ${his} rival lurchers has the same idea, however, and tries to trip ${him} up.`); - if (!canSee(activeLurcher)) { - r.push(`Unable to see it coming, ${he} goes down with a crash; ${his} course is over.`); - } else if (activeLurcher.skill.combat === 1) { - r.push(`${He} parries the attempt with contemptuous ease and catches up to ${his} new target.`); - _seed = 1; - } else if (activeLurcher.tail === "combat") { - r.push(`${He} lashes out at ${his} competitor with ${his} combat tail; ${his} rival stumbles in surprise, and ${he} easily catches up to ${his} new target.`); - _seed = 1; - } else if (activeLurcher.muscles > 30) { - r.push(`${He} muscles through the attempt and catches up to ${his} new target.`); - _seed = 1; + // Secondary target + const slowHare = hares.find(h => h.speed < obj.speed); + if (slowHare) { + obj = slowHare; + ({ + He2, + he2, his2, him2, himself2, woman2, girl2 + } = getPronouns(obj.slave).appendSuffix("2")); + if (canSee(activeLurcher)) { + r.push(`Seeing that the ${obj.origin} hare is slower,`); + } else { + r.push(`hearing the ${obj.origin} hare's bell nearby,`); + } + r.push(`${he} angles after ${him2} instead.`); + if (obj.speed >= lurcherSpeed) { + r.push(`${He} does no better with ${his} new target; ${his} course is over.`); + } else if (random(1, 2) === 1) { + r.push(`One of ${his} rival lurchers has the same idea, however, and tries to trip ${him} up.`); + if (!canSee(activeLurcher)) { + r.push(`Unable to see it coming, ${he} goes down with a crash; ${his} course is over.`); + } else if (activeLurcher.skill.combat === 1) { + r.push(`${He} parries the attempt with contemptuous ease and catches up to ${his} new target.`); + caught = true; + } else if (activeLurcher.tail === "combat") { + r.push(`${He} lashes out at ${his} competitor with ${his} combat tail; ${his} rival stumbles in surprise, and ${he} easily catches up to ${his} new target.`); + caught = true; + } else if (activeLurcher.muscles > 30) { + r.push(`${He} muscles through the attempt and catches up to ${his} new target.`); + caught = true; + } else { + r.push(`${He} goes down with a crash; ${his} course is over.`); + } } else { - r.push(`${He} goes down with a crash; ${his} course is over.`); + r.push(`${He} manages to overtake ${his} new target.`); + caught = true; } } else { - r.push(`${He} manages to overtake ${his} new target.`); - _seed = 1; + r.push(`${He} is stymied as every hare is faster than his ${obj.origin} hare.`); } } else { r.push(`${He} rapidly overtakes the ${obj.origin} hare.`); - _seed = 1; + caught = true; } App.Events.addParagraph(result, r); r = []; - if (_seed === 1) { + if (caught === true) { if (obj.origin === "heavily pregnant") { r.push(`${His} quarry is unwilling to be tackled, probably out of fear for ${his2} baby, and flings ${himself2} down as soon as${activeLurcher.slaveName} gets near.`); if (!canSee(activeLurcher)) { - r.push(` ${He2} screams as ${he2} sees${activeLurcher.slaveName} preparing to dive on ${him2}, alerting the blind lurcher that ${his} prey has already surrendered.`); + r.push(`${He2} screams as ${he2} sees${activeLurcher.slaveName} preparing to dive on ${him2}, alerting the blind lurcher that ${his} prey has already surrendered.`); } } else if (!canSee(activeLurcher) && random(1, 3) === 1) { - r.push(`${His} prey takes advantage of ${his} lack of eyesight, baiting${activeLurcher.slaveName} to dive in the wrong direction. As ${he} rises to ${his} feet, the slave is too far gone to make another lunge. _activeLurcher.slaveName's course is over.`); - _seed = 0; + r.push(`${His} prey takes advantage of ${his} lack of eyesight, baiting${activeLurcher.slaveName} to dive in the wrong direction. As ${he} rises to ${his} feet, the slave is too far gone to make another lunge. ${activeLurcher.slaveName}'s course is over.`); + caught = false; } else if (activeLurcher.skill.combat === 1) { r.push(`${His} tackle is expert: ${he} wraps ${his} quarry up and pulls ${him2} down, falling on top of the struggling body.`); } else if (activeLurcher.muscles > 30) { @@ -725,42 +718,42 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { } else if (obj.origin === "virgin") { if (random(1, 3) === 1) { r.push(`The young slave manages to evade ${his} inexpert tackle, however, and there is no space for another before ${he} crosses the plaza.${activeLurcher.slaveName}'s course is over.`); - _seed = 0; + caught = false; } else { r.push(`${His} tackle is inexpert, but the young slave stumbles and falls anyway.`); } } else if (obj.origin === "housewife") { if (random(1, 4) === 1) { r.push(`The spoiled slave shows surprising agility, however, and evades${activeLurcher.slaveName}'s inexpert attempts to tackle all the way across the plaza. ${His} course is over.`); - _seed = 0; + caught = false; } else { r.push(`${His} tackle is inexpert, but the top-heavy bimbo goes down anyway.`); } } else if (obj.origin === "feminized") { if (random(1, 4) === 1) { r.push(`The sissy bitch shows surprising agility, however, and evades${activeLurcher.slaveName}'s inexpert attempts to tackle all the way across the plaza. ${His} course is over.`); - _seed = 0; + caught = false; } else { r.push(`${His} tackle is inexpert, but the sissy bitch goes down with a wail.`); } } else if (obj.origin === "huge balled") { if (random(1, 4) === 1) { r.push(`The slave shows surprising agility despite ${his2} flopping ballsack, and evades${activeLurcher.slaveName}'s inexpert attempts to tackle all the way across the plaza. ${His} course is over.`); - _seed = 0; + caught = false; } else { r.push(`${His} tackle is inexpert, but the slave goes down, screaming with pain when ${his2} balls get trapped under their combined weight.`); } } else { if (random(1, 2) === 1) { r.push(`The determined young slave evades ${his} inexpert attempts to tackle all the way across the plaza, however.${activeLurcher.slaveName}'s course is over.`); - _seed = 0; + caught = false; } else { r.push(`${His} tackle is inexpert, but the determined slave is unlucky, stumbling and going down anyway.`); } } } - if (_seed === 1) { + if (caught === true) { r.push(`The hare knows that once ${his2} knees touched the field, ${his2} chance at freedom was gone. ${He2} begins to cry`); if (phallus === "huge dick") { r.push(`and then scream as${activeLurcher.slaveName}`); @@ -858,47 +851,47 @@ App.Events.SECoursing = class SECoursing extends App.Events.BaseEvent { if (activeLurcher.fetish === "sadist") { r.push(`<span class="hotpink">What is finest in life,</span> in the mind of your sadistic lurcher?`); if (obj.origin === "virgin") { - r.push(`To sodomize a virgin asshole, and to `); + r.push(`To sodomize a virgin asshole, and to`); if (canHear(activeLurcher)) { r.push(`hear`); } else { r.push(`feel`); } - r.push(` screams of anal pain.`); + r.push(`screams of anal pain.`); } else if (obj.origin === "heavily pregnant") { - r.push(`To molest a pregnant slut, and `); + r.push(`To molest a pregnant slut, and`); if (canHear(activeLurcher)) { r.push(`hear`); } else { r.push(`see`); } - r.push(` ${him2} sob with fear.`); + r.push(`${him2} sob with fear.`); } else if (obj.origin === "housewife") { - r.push(`To rape a stuck-up bitch, and `); + r.push(`To rape a stuck-up bitch, and`); if (canHear(activeLurcher)) { r.push(`hear`); } else { r.push(`see`); } - r.push(` ${him2} cry with anal pain.`); + r.push(`${him2} cry with anal pain.`); } else if (obj.origin === "feminized") { - r.push(`To rape a sissy's asspussy, and `); + r.push(`To rape a sissy's asspussy, and`); if (canHear(activeLurcher)) { r.push(`hear`); } else { r.push(`see`); } - r.push(` ${him2} squeal.`); + r.push(`${him2} squeal.`); } else if (obj.origin === "huge balled") { r.push(`To abuse defenseless testicles, and make their owner scream.`); } else { - r.push(`To rape a struggling victim, and `); + r.push(`To rape a struggling victim, and`); if (canTaste(activeLurcher)) { r.push(`taste`); } else { r.push(`drink`); } - r.push(` ${his2} tears of defeat.`); + r.push(`${his2} tears of defeat.`); } activeLurcher.devotion += 5; } else if (activeLurcher.fetish === "pregnancy" && obj.origin === "heavily pregnant") {