From 878e85e4156fe03b0c3d2c8b006388333ff6e5b7 Mon Sep 17 00:00:00 2001 From: Arkerthan <arkerthan@gmail.com> Date: Sat, 31 Jul 2021 21:29:49 +0200 Subject: [PATCH] refactor surgery reaction to accept slave surgery diffs and make procedures return them --- js/004-base/SurgeryEffect.js | 9 +++-- js/004-base/SurgeryProcedure.js | 23 +++++++++++-- js/medicine/surgery/eye/blind.js | 8 ++--- js/medicine/surgery/eye/eyeBlur.js | 8 ++--- js/medicine/surgery/eye/eyeFix.js | 8 ++--- js/medicine/surgery/eye/removeEyes.js | 14 ++++---- js/medicine/surgery/face/age.js | 10 +++--- js/medicine/surgery/face/face.js | 33 +++++++----------- js/medicine/surgery/hair/bodyHairRemoval.js | 17 +++++----- js/medicine/surgery/hair/eyebrowRemoval.js | 11 +++--- js/medicine/surgery/hair/hairRemoval.js | 14 ++++---- .../surgery/reaction/addAnimalBalls.js | 4 +-- .../surgery/reaction/addAnimalOvaries.js | 4 +-- js/medicine/surgery/reaction/addBalls.js | 4 +-- js/medicine/surgery/reaction/addDick.js | 4 +-- js/medicine/surgery/reaction/addForeskin.js | 4 +-- js/medicine/surgery/reaction/addOvaries.js | 4 +-- js/medicine/surgery/reaction/addProstate.js | 4 +-- js/medicine/surgery/reaction/addScrotum.js | 4 +-- js/medicine/surgery/reaction/addTesticles.js | 4 +-- js/medicine/surgery/reaction/amp.js | 4 +-- js/medicine/surgery/reaction/anus.js | 4 +-- js/medicine/surgery/reaction/areolae.js | 4 +-- .../surgery/reaction/asexualReproOvaries.js | 4 +-- js/medicine/surgery/reaction/bellyDown.js | 4 +-- js/medicine/surgery/reaction/bellyIn.js | 4 +-- js/medicine/surgery/reaction/bellyInMale.js | 4 +-- js/medicine/surgery/reaction/bellyOut.js | 4 +-- js/medicine/surgery/reaction/bellyUp.js | 4 +-- js/medicine/surgery/reaction/boobs.js | 4 +-- js/medicine/surgery/reaction/boobsLoss.js | 4 +-- js/medicine/surgery/reaction/braces.js | 4 +-- js/medicine/surgery/reaction/breastLift.js | 4 +-- .../surgery/reaction/breastReconstruction.js | 4 +-- .../reaction/breastShapePreservation.js | 4 +-- .../breastShapePreservationFailure.js | 4 +-- js/medicine/surgery/reaction/butt.js | 4 +-- js/medicine/surgery/reaction/buttLoss.js | 4 +-- js/medicine/surgery/reaction/cervixPump.js | 4 +-- .../surgery/reaction/cervixPumpAnus.js | 4 +-- js/medicine/surgery/reaction/chemCastrate.js | 4 +-- js/medicine/surgery/reaction/chop.js | 4 +-- js/medicine/surgery/reaction/circumcision.js | 4 +-- .../surgery/reaction/clitoralEnlargement.js | 4 +-- .../surgery/reaction/clitoralReduction.js | 4 +-- .../surgery/reaction/cochlearImplant.js | 4 +-- js/medicine/surgery/reaction/deafen.js | 4 +-- js/medicine/surgery/reaction/desmell.js | 4 +-- js/medicine/surgery/reaction/detaste.js | 4 +-- js/medicine/surgery/reaction/earFix.js | 4 +-- js/medicine/surgery/reaction/earGone.js | 4 +-- js/medicine/surgery/reaction/earMajor.js | 4 +-- js/medicine/surgery/reaction/earMinor.js | 4 +-- js/medicine/surgery/reaction/earMuffle.js | 4 +-- js/medicine/surgery/reaction/earRestore.js | 4 +-- js/medicine/surgery/reaction/ejaculation.js | 4 +-- js/medicine/surgery/reaction/electrolarynx.js | 4 +-- .../surgery/reaction/endEjaculation.js | 4 +-- js/medicine/surgery/reaction/endLactation.js | 4 +-- js/medicine/surgery/reaction/endPrecum.js | 4 +-- js/medicine/surgery/reaction/fang.js | 4 +-- js/medicine/surgery/reaction/fangs.js | 4 +-- js/medicine/surgery/reaction/fatGraft.js | 4 +-- js/medicine/surgery/reaction/fertility.js | 4 +-- js/medicine/surgery/reaction/foreskinTuck.js | 4 +-- js/medicine/surgery/reaction/freshOvaries.js | 4 +-- js/medicine/surgery/reaction/fuckdoll.js | 4 +-- .../surgery/reaction/fuckdollExtraction.js | 4 +-- js/medicine/surgery/reaction/geld.js | 4 +-- js/medicine/surgery/reaction/herm.js | 4 +-- js/medicine/surgery/reaction/horn.js | 4 +-- js/medicine/surgery/reaction/hornGone.js | 4 +-- js/medicine/surgery/reaction/insemination.js | 4 +-- js/medicine/surgery/reaction/labiaplasty.js | 4 +-- js/medicine/surgery/reaction/lactation.js | 4 +-- js/medicine/surgery/reaction/lipo.js | 4 +-- js/medicine/surgery/reaction/liposuction.js | 4 +-- js/medicine/surgery/reaction/lips.js | 4 +-- js/medicine/surgery/reaction/maleToFemale.js | 4 +-- js/medicine/surgery/reaction/mastectomy.js | 4 +-- .../surgery/reaction/mastectomyPlus.js | 4 +-- js/medicine/surgery/reaction/mindbreak.js | 4 +-- js/medicine/surgery/reaction/mpreg.js | 4 +-- js/medicine/surgery/reaction/mpregRemoved.js | 4 +-- js/medicine/surgery/reaction/mute.js | 4 +-- js/medicine/surgery/reaction/newEars.js | 4 +-- js/medicine/surgery/reaction/newEyes.js | 4 +-- js/medicine/surgery/reaction/newVoice.js | 4 +-- js/medicine/surgery/reaction/nippleCunts.js | 4 +-- js/medicine/surgery/reaction/noneToFemale.js | 4 +-- js/medicine/surgery/reaction/ocularImplant.js | 4 +-- .../surgery/reaction/ocularImplantForBlind.js | 4 +-- js/medicine/surgery/reaction/oral.js | 4 +-- .../surgery/reaction/ovaImplantChanged.js | 4 +-- .../surgery/reaction/pLimbInterface.js | 4 +-- .../surgery/reaction/pLimbInterface1.js | 4 +-- .../surgery/reaction/pLimbInterface2.js | 4 +-- .../surgery/reaction/pLimbInterface3.js | 4 +-- js/medicine/surgery/reaction/precum.js | 4 +-- js/medicine/surgery/reaction/preg.js | 4 +-- js/medicine/surgery/reaction/preg1hack.js | 4 +-- js/medicine/surgery/reaction/pregRemove.js | 4 +-- js/medicine/surgery/reaction/prostate.js | 4 +-- js/medicine/surgery/reaction/race.js | 4 +-- js/medicine/surgery/reaction/relocate.js | 4 +-- js/medicine/surgery/reaction/removeBraces.js | 4 +-- .../surgery/reaction/removeCosmeticBraces.js | 4 +-- js/medicine/surgery/reaction/resmell.js | 4 +-- .../surgery/reaction/restoreHairBrow.js | 4 +-- .../surgery/reaction/restoreHairHead.js | 4 +-- .../surgery/reaction/restoreHairPits.js | 4 +-- .../surgery/reaction/restoreHairPubes.js | 4 +-- js/medicine/surgery/reaction/restoreVoice.js | 4 +-- js/medicine/surgery/reaction/retaste.js | 4 +-- .../reaction/retrogradeVirusInjectionNCS.js | 4 +-- js/medicine/surgery/reaction/ribs.js | 4 +-- js/medicine/surgery/reaction/scrotalTuck.js | 4 +-- js/medicine/surgery/reaction/sharp.js | 4 +-- js/medicine/surgery/reaction/sterilize.js | 4 +-- js/medicine/surgery/reaction/tailInterface.js | 4 +-- js/medicine/surgery/reaction/teeth.js | 4 +-- js/medicine/surgery/reaction/treatment.js | 4 +-- js/medicine/surgery/reaction/tummyTuck.js | 4 +-- js/medicine/surgery/reaction/unblind.js | 4 +-- js/medicine/surgery/reaction/undeafen.js | 4 +-- js/medicine/surgery/reaction/vagina.js | 4 +-- .../surgery/reaction/vaginalRemoval.js | 4 +-- js/medicine/surgery/reaction/vasectomy.js | 4 +-- js/medicine/surgery/reaction/vasectomyUndo.js | 4 +-- js/medicine/surgery/reaction/voiceLower.js | 4 +-- js/medicine/surgery/reaction/voiceRaise.js | 4 +-- js/medicine/surgery/reaction/womb.js | 4 +-- js/medicine/surgery/structural/heels.js | 22 ++++++------ js/medicine/surgery/structural/height.js | 28 +++++++-------- js/medicine/surgery/structural/hips.js | 20 +++++------ js/medicine/surgery/structural/shoulders.js | 20 +++++------ src/js/utilsSlave.js | 24 +++++++------ src/npc/surgery/surgery.js | 34 +++++++++++-------- src/npc/surgery/surgeryDegradation.js | 6 ++-- 139 files changed, 407 insertions(+), 386 deletions(-) diff --git a/js/004-base/SurgeryEffect.js b/js/004-base/SurgeryEffect.js index 12d03d71e9a..e0f299b9ba8 100644 --- a/js/004-base/SurgeryEffect.js +++ b/js/004-base/SurgeryEffect.js @@ -27,8 +27,9 @@ App.Medicine.Surgery.SimpleReaction = class { /** * @param {App.Entity.SlaveState} slave + * @param {Partial<App.Entity.SlaveState>} diff */ - intro(slave) { + intro(slave, diff) { const {he, his, himself} = getPronouns(slave); const r = []; @@ -73,18 +74,20 @@ App.Medicine.Surgery.SimpleReaction = class { /** * @param {App.Entity.SlaveState} slave + * @param {Partial<App.Entity.SlaveState>} diff * @returns {reactionResult} */ - reaction(slave) { + reaction(slave, diff) { return this._createReactionResult(); } /** * @param {App.Entity.SlaveState} slave + * @param {Partial<App.Entity.SlaveState>} diff * @param {reactionResult} previousReaction * @returns {reactionResult} */ - outro(slave, previousReaction) { + outro(slave, diff, previousReaction) { const reaction = this._createReactionResult(); if (V.PC.skill.medicine < 100) { return reaction; diff --git a/js/004-base/SurgeryProcedure.js b/js/004-base/SurgeryProcedure.js index 60f146ccabc..efbbdfc478f 100644 --- a/js/004-base/SurgeryProcedure.js +++ b/js/004-base/SurgeryProcedure.js @@ -3,7 +3,15 @@ App.Medicine.Surgery.Procedure = class { * @param {App.Entity.SlaveState} slave */ constructor(slave) { - this.slave = slave; + /** + * @type {FC.Util.DiffRecorder<App.Entity.SlaveState>} + * @protected + */ + this._slave = App.Utils.Diff.getProxy(slave); + } + + get originalSlave() { + return this._slave.diffOriginal; } // eslint-disable-next-line jsdoc/require-returns-check @@ -33,7 +41,18 @@ App.Medicine.Surgery.Procedure = class { // eslint-disable-next-line jsdoc/require-returns-check /** * @param {boolean} cheat - * @returns {App.Medicine.Surgery.SimpleReaction} + * @returns {[Partial<App.Entity.SlaveState>, App.Medicine.Surgery.SimpleReaction]} */ apply(cheat) { throw new Error("Method 'apply()' must be implemented."); } + + /** + * Convenience function to prepare the return value for apply() + * + * @param {App.Medicine.Surgery.SimpleReaction} reaction + * @returns {[Partial<App.Entity.SlaveState>, App.Medicine.Surgery.SimpleReaction]} + * @protected + */ + _assemble(reaction) { + return [this._slave.diffChange, reaction]; + } }; diff --git a/js/medicine/surgery/eye/blind.js b/js/medicine/surgery/eye/blind.js index 0b02a9ff706..cc5f35337e0 100644 --- a/js/medicine/surgery/eye/blind.js +++ b/js/medicine/surgery/eye/blind.js @@ -1,8 +1,8 @@ App.Medicine.Surgery.Reactions.Blind = class extends App.Medicine.Surgery.SimpleReaction { get removeJob() { return true; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his} = getPronouns(slave); const r = []; r.push(`The laser eye surgery is brief, with <span class="health dec">nothing more than minor health effects.</span> As soon as ${he} is allowed to open ${his} eyes and look around, ${he} begins to glance back and forth frantically, not immediately understanding that this darkness is ${his} new reality.`); @@ -38,7 +38,7 @@ App.Medicine.Surgery.Procedures.Blind = class extends App.Medicine.Surgery.Proce get healthCost() { return 5; } apply(cheat) { - eyeSurgery(this.slave, this.side, "blind"); - return new App.Medicine.Surgery.Reactions.Blind(); + eyeSurgery(this._slave, this.side, "blind"); + return this._assemble(new App.Medicine.Surgery.Reactions.Blind()); } }; diff --git a/js/medicine/surgery/eye/eyeBlur.js b/js/medicine/surgery/eye/eyeBlur.js index 12d4b8f004c..84260238f43 100644 --- a/js/medicine/surgery/eye/eyeBlur.js +++ b/js/medicine/surgery/eye/eyeBlur.js @@ -1,6 +1,6 @@ App.Medicine.Surgery.Reactions.EyeBlur = class extends App.Medicine.Surgery.SimpleReaction { - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; @@ -38,7 +38,7 @@ App.Medicine.Surgery.Procedures.EyeBlur = class extends App.Medicine.Surgery.Pro get healthCost() { return 5; } apply(cheat) { - eyeSurgery(this.slave, this.side, "blur"); - return new App.Medicine.Surgery.Reactions.EyeBlur(); + eyeSurgery(this._slave, this.side, "blur"); + return this._assemble(new App.Medicine.Surgery.Reactions.EyeBlur()); } }; diff --git a/js/medicine/surgery/eye/eyeFix.js b/js/medicine/surgery/eye/eyeFix.js index f54b27c7245..756904fa35a 100644 --- a/js/medicine/surgery/eye/eyeFix.js +++ b/js/medicine/surgery/eye/eyeFix.js @@ -1,6 +1,6 @@ App.Medicine.Surgery.Reactions.EyeFix = class extends App.Medicine.Surgery.SimpleReaction { - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; @@ -37,7 +37,7 @@ App.Medicine.Surgery.Procedures.EyeFix = class extends App.Medicine.Surgery.Proc get healthCost() { return 5; } apply(cheat) { - eyeSurgery(this.slave, this.side, "fix"); - return new App.Medicine.Surgery.Reactions.EyeFix(); + eyeSurgery(this._slave, this.side, "fix"); + return this._assemble(new App.Medicine.Surgery.Reactions.EyeFix()); } }; diff --git a/js/medicine/surgery/eye/removeEyes.js b/js/medicine/surgery/eye/removeEyes.js index c363c8ce134..065c19b55df 100644 --- a/js/medicine/surgery/eye/removeEyes.js +++ b/js/medicine/surgery/eye/removeEyes.js @@ -1,8 +1,8 @@ App.Medicine.Surgery.Reactions.RemoveEyes = class extends App.Medicine.Surgery.SimpleReaction { get removeJob() { return true; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his} = getPronouns(slave); const r = []; r.push(`Surgery doesn't take long, but since it was invasive there are <span class="health dec">moderate health consequences.</span> As anesthesia wears off ${he} tries to open ${his} eyes and finds ${he} is unable to.`); @@ -24,8 +24,8 @@ App.Medicine.Surgery.Reactions.RemoveEyes = class extends App.Medicine.Surgery.S }; App.Medicine.Surgery.Reactions.RemoveBlindEyes = class extends App.Medicine.Surgery.SimpleReaction { - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {he, His, his} = getPronouns(slave); const r = []; r.push(`Surgery doesn't take long, but since it was invasive there are <span class="health dec">moderate health consequences.</span> As anesthesia wears off ${he} tries to open ${his} eyes and finds ${he} is unable to.`); @@ -58,10 +58,10 @@ App.Medicine.Surgery.Procedures.RemoveEyes = class extends App.Medicine.Surgery. get healthCost() { return 5; } apply(cheat) { - const reaction = getBestVision(this.slave) > 0 ? + const reaction = getBestVision(this._slave) > 0 ? new App.Medicine.Surgery.Reactions.RemoveEyes() : new App.Medicine.Surgery.Reactions.RemoveBlindEyes(); - eyeSurgery(this.slave, this.side, "remove"); - return reaction; + eyeSurgery(this._slave, this.side, "remove"); + return this._assemble(reaction); } }; diff --git a/js/medicine/surgery/face/age.js b/js/medicine/surgery/face/age.js index 72a06948f3c..44f9af6ccdc 100644 --- a/js/medicine/surgery/face/age.js +++ b/js/medicine/surgery/face/age.js @@ -1,6 +1,6 @@ App.Medicine.Surgery.Reactions.Age = class extends App.Medicine.Surgery.SimpleReaction { - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; @@ -46,8 +46,8 @@ App.Medicine.Surgery.Procedures.AgeLift = class extends App.Medicine.Surgery.Pro get healthCost() { return 10; } apply(cheat) { - applyAgeImplant(this.slave); - this.slave.faceImplant = Math.clamp(this.slave.faceImplant + faceSurgeryArtificiality(), 0, 100); - return new App.Medicine.Surgery.Reactions.Age(); + applyAgeImplant(this._slave); + this._slave.faceImplant = Math.clamp(this._slave.faceImplant + faceSurgeryArtificiality(), 0, 100); + return this._assemble(new App.Medicine.Surgery.Reactions.Age()); } }; diff --git a/js/medicine/surgery/face/face.js b/js/medicine/surgery/face/face.js index cfbbae7aa30..b255e1bb888 100644 --- a/js/medicine/surgery/face/face.js +++ b/js/medicine/surgery/face/face.js @@ -1,18 +1,10 @@ App.Medicine.Surgery.Reactions.Face = class extends App.Medicine.Surgery.SimpleReaction { - /** - * @param {number} oldFace - */ - constructor(oldFace) { - super(); - this.oldFace = oldFace; - } - - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; - r.push(faceIncreaseDesc(slave, this.oldFace)); + r.push(faceIncreaseDesc(slave, diff.face)); if (slave.fetish === "mindbroken") { r.push(`${He} doesn't notice the improvements to ${his} face, but ${he}'s not the one looking at it. As with all surgery <span class="health dec">${his} health has been slightly affected.</span>`); } else if (slave.devotion > 50) { @@ -61,7 +53,7 @@ App.Medicine.Surgery.Procedures.FaceShape = class extends App.Medicine.Surgery.P } get name() { - if (this.targetShape === "androgynous" && this.slave.faceShape === "masculine") { + if (this.targetShape === "androgynous" && this._slave.faceShape === "masculine") { return `Soften to androgynous`; } else if (this.targetShape === "normal") { return `Make conventionally feminine`; @@ -73,11 +65,11 @@ App.Medicine.Surgery.Procedures.FaceShape = class extends App.Medicine.Surgery.P get healthCost() { return 10; } apply(cheat) { - const oldFace = this.slave.face; - this.slave.faceShape = this.targetShape; - faceIncreaseAction(this.slave, 20); - this.slave.faceImplant = Math.clamp(this.slave.faceImplant + faceSurgeryArtificiality(), 0, 100); - return new App.Medicine.Surgery.Reactions.Face(oldFace); + this._slave.faceShape = this.targetShape; + faceIncreaseAction(this._slave, 20); + this._slave.faceImplant = Math.clamp(this._slave.faceImplant + faceSurgeryArtificiality(), 0, 100); + return this._assemble(new App.Medicine.Surgery.Reactions.Face()); + } }; @@ -87,9 +79,8 @@ App.Medicine.Surgery.Procedures.FaceAttractiveness = class extends App.Medicine. get healthCost() { return 10; } apply(cheat) { - const oldFace = this.slave.face; - faceIncreaseAction(this.slave, 20); - this.slave.faceImplant = Math.clamp(this.slave.faceImplant + faceSurgeryArtificiality(), 0, 100); - return new App.Medicine.Surgery.Reactions.Face(oldFace); + faceIncreaseAction(this._slave, 20); + this._slave.faceImplant = Math.clamp(this._slave.faceImplant + faceSurgeryArtificiality(), 0, 100); + return this._assemble(new App.Medicine.Surgery.Reactions.Face()); } }; diff --git a/js/medicine/surgery/hair/bodyHairRemoval.js b/js/medicine/surgery/hair/bodyHairRemoval.js index f61c65dbaff..f752c63b7e0 100644 --- a/js/medicine/surgery/hair/bodyHairRemoval.js +++ b/js/medicine/surgery/hair/bodyHairRemoval.js @@ -1,9 +1,8 @@ App.Medicine.Surgery.Reactions.BodyHairRemoval = class extends App.Medicine.Surgery.SimpleReaction { - get invasive() { return false; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him} = getPronouns(slave); let r = []; @@ -48,19 +47,19 @@ App.Medicine.Surgery.Reactions.BodyHairRemoval = class extends App.Medicine.Surg App.Medicine.Surgery.Procedures.BodyHairRemoval = class extends App.Medicine.Surgery.Procedure { get name() { - const {his} = getPronouns(this.slave); + const {his} = getPronouns(this._slave); return `Surgically remove ${his} ability to grow body hair`; } get healthCost() { return 0; } apply(cheat) { - if (this.slave.underArmHStyle !== "hairless") { - this.slave.underArmHStyle = "bald"; + if (this._slave.underArmHStyle !== "hairless") { + this._slave.underArmHStyle = "bald"; } - if (this.slave.pubicHStyle !== "hairless") { - this.slave.pubicHStyle = "bald"; + if (this._slave.pubicHStyle !== "hairless") { + this._slave.pubicHStyle = "bald"; } - return new App.Medicine.Surgery.Reactions.BodyHairRemoval(); + return this._assemble(new App.Medicine.Surgery.Reactions.BodyHairRemoval()); } }; diff --git a/js/medicine/surgery/hair/eyebrowRemoval.js b/js/medicine/surgery/hair/eyebrowRemoval.js index 0bc21f7e570..30e98125c06 100644 --- a/js/medicine/surgery/hair/eyebrowRemoval.js +++ b/js/medicine/surgery/hair/eyebrowRemoval.js @@ -1,9 +1,8 @@ App.Medicine.Surgery.Reactions.EyebrowRemoval = class extends App.Medicine.Surgery.SimpleReaction { - get invasive() { return false; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him} = getPronouns(slave); let r = []; @@ -44,15 +43,15 @@ App.Medicine.Surgery.Reactions.EyebrowRemoval = class extends App.Medicine.Surge App.Medicine.Surgery.Procedures.EyebrowRemoval = class extends App.Medicine.Surgery.Procedure { get name() { - const {his} = getPronouns(this.slave); + const {his} = getPronouns(this._slave); return `Surgically remove ${his} ability to grow eyebrows`; } get healthCost() { return 0; } apply(cheat) { - this.slave.eyebrowHStyle = "bald"; - return new App.Medicine.Surgery.Reactions.EyebrowRemoval(); + this._slave.eyebrowHStyle = "bald"; + return this._assemble(new App.Medicine.Surgery.Reactions.EyebrowRemoval()); } }; diff --git a/js/medicine/surgery/hair/hairRemoval.js b/js/medicine/surgery/hair/hairRemoval.js index e53a6719db6..316ba4e6338 100644 --- a/js/medicine/surgery/hair/hairRemoval.js +++ b/js/medicine/surgery/hair/hairRemoval.js @@ -1,8 +1,8 @@ App.Medicine.Surgery.Reactions.HairRemoval = class extends App.Medicine.Surgery.SimpleReaction { get invasive() { return false; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); let r = []; @@ -53,16 +53,16 @@ App.Medicine.Surgery.Reactions.HairRemoval = class extends App.Medicine.Surgery. App.Medicine.Surgery.Procedures.HairRemoval = class extends App.Medicine.Surgery.Procedure { get name() { - const {his} = getPronouns(this.slave); + const {his} = getPronouns(this._slave); return `Surgically remove ${his} ability to grow hair`; } get healthCost() { return 0; } apply(cheat) { - this.slave.bald = 1; - this.slave.hStyle = "bald"; - this.slave.eyebrowHStyle = "bald"; - return new App.Medicine.Surgery.Reactions.HairRemoval(); + this._slave.bald = 1; + this._slave.hStyle = "bald"; + this._slave.eyebrowHStyle = "bald"; + return this._assemble(new App.Medicine.Surgery.Reactions.HairRemoval()); } }; diff --git a/js/medicine/surgery/reaction/addAnimalBalls.js b/js/medicine/surgery/reaction/addAnimalBalls.js index 2299fd284f2..31267edc883 100644 --- a/js/medicine/surgery/reaction/addAnimalBalls.js +++ b/js/medicine/surgery/reaction/addAnimalBalls.js @@ -2,8 +2,8 @@ class AddAnimalBalls extends App.Medicine.Surgery.Reaction { get key() { return "addAnimalBalls"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/addAnimalOvaries.js b/js/medicine/surgery/reaction/addAnimalOvaries.js index ed4563ea5be..01d38eab7e3 100644 --- a/js/medicine/surgery/reaction/addAnimalOvaries.js +++ b/js/medicine/surgery/reaction/addAnimalOvaries.js @@ -2,8 +2,8 @@ class AddAnimalOvaries extends App.Medicine.Surgery.Reaction { get key() { return "addAnimalOvaries"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/addBalls.js b/js/medicine/surgery/reaction/addBalls.js index 4fe6d0339c6..df5f74a6f39 100644 --- a/js/medicine/surgery/reaction/addBalls.js +++ b/js/medicine/surgery/reaction/addBalls.js @@ -2,8 +2,8 @@ class AddBalls extends App.Medicine.Surgery.Reaction { get key() { return "addBalls"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/addDick.js b/js/medicine/surgery/reaction/addDick.js index b09f5315eae..33ca8ad7453 100644 --- a/js/medicine/surgery/reaction/addDick.js +++ b/js/medicine/surgery/reaction/addDick.js @@ -2,8 +2,8 @@ class AddDick extends App.Medicine.Surgery.Reaction { get key() { return "addDick"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/addForeskin.js b/js/medicine/surgery/reaction/addForeskin.js index 359bd6bd4e9..ed2275e3936 100644 --- a/js/medicine/surgery/reaction/addForeskin.js +++ b/js/medicine/surgery/reaction/addForeskin.js @@ -2,8 +2,8 @@ class AddForeskin extends App.Medicine.Surgery.Reaction { get key() { return "addForeskin"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/addOvaries.js b/js/medicine/surgery/reaction/addOvaries.js index a899fe3060d..1898640f95c 100644 --- a/js/medicine/surgery/reaction/addOvaries.js +++ b/js/medicine/surgery/reaction/addOvaries.js @@ -2,8 +2,8 @@ class AddOvaries extends App.Medicine.Surgery.Reaction { get key() { return "addOvaries"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/addProstate.js b/js/medicine/surgery/reaction/addProstate.js index 6a2bdcc91db..ea6f0f7a498 100644 --- a/js/medicine/surgery/reaction/addProstate.js +++ b/js/medicine/surgery/reaction/addProstate.js @@ -2,8 +2,8 @@ class AddProstate extends App.Medicine.Surgery.Reaction { get key() { return "addProstate"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/addScrotum.js b/js/medicine/surgery/reaction/addScrotum.js index bb04c2a7a24..50994ee2f6c 100644 --- a/js/medicine/surgery/reaction/addScrotum.js +++ b/js/medicine/surgery/reaction/addScrotum.js @@ -2,8 +2,8 @@ class AddScrotum extends App.Medicine.Surgery.Reaction { get key() { return "addScrotum"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/addTesticles.js b/js/medicine/surgery/reaction/addTesticles.js index 467bc2c7c8a..26b04a06faf 100644 --- a/js/medicine/surgery/reaction/addTesticles.js +++ b/js/medicine/surgery/reaction/addTesticles.js @@ -2,8 +2,8 @@ class AddTesticles extends App.Medicine.Surgery.Reaction { get key() { return "addTesticles"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/amp.js b/js/medicine/surgery/reaction/amp.js index d0be8c29e1b..867e5449a4e 100644 --- a/js/medicine/surgery/reaction/amp.js +++ b/js/medicine/surgery/reaction/amp.js @@ -2,8 +2,8 @@ class Amp extends App.Medicine.Surgery.Reaction { get key() { return "amp"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const r = []; V.nextButton = " "; diff --git a/js/medicine/surgery/reaction/anus.js b/js/medicine/surgery/reaction/anus.js index f0208d73394..db50699466d 100644 --- a/js/medicine/surgery/reaction/anus.js +++ b/js/medicine/surgery/reaction/anus.js @@ -2,8 +2,8 @@ class Anus extends App.Medicine.Surgery.Reaction { get key() { return "anus"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/areolae.js b/js/medicine/surgery/reaction/areolae.js index 3a28554f103..41209b94a9b 100644 --- a/js/medicine/surgery/reaction/areolae.js +++ b/js/medicine/surgery/reaction/areolae.js @@ -2,8 +2,8 @@ class Areolae extends App.Medicine.Surgery.Reaction { get key() { return "areolae"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/asexualReproOvaries.js b/js/medicine/surgery/reaction/asexualReproOvaries.js index f9b07959104..73ee4768d64 100644 --- a/js/medicine/surgery/reaction/asexualReproOvaries.js +++ b/js/medicine/surgery/reaction/asexualReproOvaries.js @@ -2,8 +2,8 @@ class AsexualReproOvaries extends App.Medicine.Surgery.Reaction { get key() { return "asexualReproOvaries"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, girl} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/bellyDown.js b/js/medicine/surgery/reaction/bellyDown.js index 0684142ae2b..0945756c41c 100644 --- a/js/medicine/surgery/reaction/bellyDown.js +++ b/js/medicine/surgery/reaction/bellyDown.js @@ -2,8 +2,8 @@ class BellyDown extends App.Medicine.Surgery.Reaction { get key() { return "bellyDown"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/bellyIn.js b/js/medicine/surgery/reaction/bellyIn.js index 83a78f5d658..4f9f66c442f 100644 --- a/js/medicine/surgery/reaction/bellyIn.js +++ b/js/medicine/surgery/reaction/bellyIn.js @@ -2,8 +2,8 @@ class BellyIn extends App.Medicine.Surgery.Reaction { get key() { return "bellyIn"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/bellyInMale.js b/js/medicine/surgery/reaction/bellyInMale.js index 37f239899d3..0a1e2023739 100644 --- a/js/medicine/surgery/reaction/bellyInMale.js +++ b/js/medicine/surgery/reaction/bellyInMale.js @@ -2,8 +2,8 @@ class BellyInMale extends App.Medicine.Surgery.Reaction { get key() { return "bellyInMale"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/bellyOut.js b/js/medicine/surgery/reaction/bellyOut.js index b0877d960b4..48145aad5cf 100644 --- a/js/medicine/surgery/reaction/bellyOut.js +++ b/js/medicine/surgery/reaction/bellyOut.js @@ -2,8 +2,8 @@ class BellyOut extends App.Medicine.Surgery.Reaction { get key() { return "bellyOut"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/bellyUp.js b/js/medicine/surgery/reaction/bellyUp.js index c180352f627..c8b0a2f0182 100644 --- a/js/medicine/surgery/reaction/bellyUp.js +++ b/js/medicine/surgery/reaction/bellyUp.js @@ -2,8 +2,8 @@ class BellyUp extends App.Medicine.Surgery.Reaction { get key() { return "bellyUp"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const heGlaresDaggers = canSee(slave) ? `${he} glares daggers` : `${his} face contorts with distaste`; const r = []; diff --git a/js/medicine/surgery/reaction/boobs.js b/js/medicine/surgery/reaction/boobs.js index b14c453838c..1f156b867f1 100644 --- a/js/medicine/surgery/reaction/boobs.js +++ b/js/medicine/surgery/reaction/boobs.js @@ -2,8 +2,8 @@ class Boobs extends App.Medicine.Surgery.Reaction { get key() { return "boobs"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const heGlaresDaggers = canSee(slave) ? `${he} glares daggers` : `${his} face contorts with distaste`; const r = []; diff --git a/js/medicine/surgery/reaction/boobsLoss.js b/js/medicine/surgery/reaction/boobsLoss.js index d5f3ba5b67a..6cc0e677df8 100644 --- a/js/medicine/surgery/reaction/boobsLoss.js +++ b/js/medicine/surgery/reaction/boobsLoss.js @@ -2,8 +2,8 @@ class BoobsLoss extends App.Medicine.Surgery.Reaction { get key() { return "boobsLoss"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/braces.js b/js/medicine/surgery/reaction/braces.js index beca381a2ed..975ee42bad7 100644 --- a/js/medicine/surgery/reaction/braces.js +++ b/js/medicine/surgery/reaction/braces.js @@ -6,8 +6,8 @@ get permanentChanges() { return false; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/breastLift.js b/js/medicine/surgery/reaction/breastLift.js index 385226a0521..a5ef5705736 100644 --- a/js/medicine/surgery/reaction/breastLift.js +++ b/js/medicine/surgery/reaction/breastLift.js @@ -2,8 +2,8 @@ class BreastLift extends App.Medicine.Surgery.Reaction { get key() { return "breastLift"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/breastReconstruction.js b/js/medicine/surgery/reaction/breastReconstruction.js index 4053e22b25c..c594971c4d2 100644 --- a/js/medicine/surgery/reaction/breastReconstruction.js +++ b/js/medicine/surgery/reaction/breastReconstruction.js @@ -2,8 +2,8 @@ class BreastReconstruction extends App.Medicine.Surgery.Reaction { get key() { return "breastReconstruction"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/breastShapePreservation.js b/js/medicine/surgery/reaction/breastShapePreservation.js index b3c127357f7..8ba6a60628d 100644 --- a/js/medicine/surgery/reaction/breastShapePreservation.js +++ b/js/medicine/surgery/reaction/breastShapePreservation.js @@ -2,8 +2,8 @@ class BreastShapePreservation extends App.Medicine.Surgery.Reaction { get key() { return "breastShapePreservation"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/breastShapePreservationFailure.js b/js/medicine/surgery/reaction/breastShapePreservationFailure.js index 137ae4f9a15..e467cd5b95a 100644 --- a/js/medicine/surgery/reaction/breastShapePreservationFailure.js +++ b/js/medicine/surgery/reaction/breastShapePreservationFailure.js @@ -6,8 +6,8 @@ return []; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; const heGlaresDaggers = (canSee(slave)) ? `${he} glares daggers` : `${his} face contorts with distaste`; diff --git a/js/medicine/surgery/reaction/butt.js b/js/medicine/surgery/reaction/butt.js index 3981c66c95f..56b2ce1bdef 100644 --- a/js/medicine/surgery/reaction/butt.js +++ b/js/medicine/surgery/reaction/butt.js @@ -2,8 +2,8 @@ class Butt extends App.Medicine.Surgery.Reaction { get key() { return "butt"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/buttLoss.js b/js/medicine/surgery/reaction/buttLoss.js index 2d8dcd134f9..98c27ad2df0 100644 --- a/js/medicine/surgery/reaction/buttLoss.js +++ b/js/medicine/surgery/reaction/buttLoss.js @@ -2,8 +2,8 @@ class ButtLoss extends App.Medicine.Surgery.Reaction { get key() { return "buttLoss"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/cervixPump.js b/js/medicine/surgery/reaction/cervixPump.js index d89699cb777..7a721b2abfc 100644 --- a/js/medicine/surgery/reaction/cervixPump.js +++ b/js/medicine/surgery/reaction/cervixPump.js @@ -2,8 +2,8 @@ class CervixPump extends App.Medicine.Surgery.Reaction { get key() { return "cervixPump"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/cervixPumpAnus.js b/js/medicine/surgery/reaction/cervixPumpAnus.js index 958d8001811..baa39da746e 100644 --- a/js/medicine/surgery/reaction/cervixPumpAnus.js +++ b/js/medicine/surgery/reaction/cervixPumpAnus.js @@ -2,8 +2,8 @@ class CervixPumpAnus extends App.Medicine.Surgery.Reaction { get key() { return "cervixPumpA"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/chemCastrate.js b/js/medicine/surgery/reaction/chemCastrate.js index 731a0720a74..f78044f2bb3 100644 --- a/js/medicine/surgery/reaction/chemCastrate.js +++ b/js/medicine/surgery/reaction/chemCastrate.js @@ -4,8 +4,8 @@ get invasive() { return false; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/chop.js b/js/medicine/surgery/reaction/chop.js index e8281dff3df..9087341b223 100644 --- a/js/medicine/surgery/reaction/chop.js +++ b/js/medicine/surgery/reaction/chop.js @@ -2,8 +2,8 @@ class Chop extends App.Medicine.Surgery.Reaction { get key() { return "chop"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/circumcision.js b/js/medicine/surgery/reaction/circumcision.js index 26ee4d4f2be..f8e9eeda596 100644 --- a/js/medicine/surgery/reaction/circumcision.js +++ b/js/medicine/surgery/reaction/circumcision.js @@ -2,8 +2,8 @@ class Circumcision extends App.Medicine.Surgery.Reaction { get key() { return "circumcision"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/clitoralEnlargement.js b/js/medicine/surgery/reaction/clitoralEnlargement.js index 2e2b494dd6e..85c7fb6c0dd 100644 --- a/js/medicine/surgery/reaction/clitoralEnlargement.js +++ b/js/medicine/surgery/reaction/clitoralEnlargement.js @@ -2,8 +2,8 @@ class ClitoralEnlargement extends App.Medicine.Surgery.Reaction { get key() { return "clitoral enlargement"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/clitoralReduction.js b/js/medicine/surgery/reaction/clitoralReduction.js index 83c4d85ed96..8baeb65dce3 100644 --- a/js/medicine/surgery/reaction/clitoralReduction.js +++ b/js/medicine/surgery/reaction/clitoralReduction.js @@ -2,8 +2,8 @@ class ClitoralReduction extends App.Medicine.Surgery.Reaction { get key() { return "clitoral reduction"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/cochlearImplant.js b/js/medicine/surgery/reaction/cochlearImplant.js index 00dd3831fa2..d602e9331e7 100644 --- a/js/medicine/surgery/reaction/cochlearImplant.js +++ b/js/medicine/surgery/reaction/cochlearImplant.js @@ -2,8 +2,8 @@ class CochlearImplant extends App.Medicine.Surgery.Reaction { get key() { return "cochlear implant"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/deafen.js b/js/medicine/surgery/reaction/deafen.js index f4340c7ab5f..b9aa9178b3f 100644 --- a/js/medicine/surgery/reaction/deafen.js +++ b/js/medicine/surgery/reaction/deafen.js @@ -2,8 +2,8 @@ class Deafen extends App.Medicine.Surgery.Reaction { get key() { return "deafen"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/desmell.js b/js/medicine/surgery/reaction/desmell.js index 812e314f443..812fbec2c85 100644 --- a/js/medicine/surgery/reaction/desmell.js +++ b/js/medicine/surgery/reaction/desmell.js @@ -2,8 +2,8 @@ class Desmell extends App.Medicine.Surgery.Reaction { get key() { return "desmell"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/detaste.js b/js/medicine/surgery/reaction/detaste.js index 920b0d0c852..5c8e5e3bfdc 100644 --- a/js/medicine/surgery/reaction/detaste.js +++ b/js/medicine/surgery/reaction/detaste.js @@ -2,8 +2,8 @@ class Detaste extends App.Medicine.Surgery.Reaction { get key() { return "detaste"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/earFix.js b/js/medicine/surgery/reaction/earFix.js index bd2854ed52e..96e1a816958 100644 --- a/js/medicine/surgery/reaction/earFix.js +++ b/js/medicine/surgery/reaction/earFix.js @@ -2,8 +2,8 @@ class EarFix extends App.Medicine.Surgery.Reaction { get key() { return "earFix"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/earGone.js b/js/medicine/surgery/reaction/earGone.js index 20b2a344deb..eca7400bae7 100644 --- a/js/medicine/surgery/reaction/earGone.js +++ b/js/medicine/surgery/reaction/earGone.js @@ -2,8 +2,8 @@ class EarGone extends App.Medicine.Surgery.Reaction { get key() { return "earGone"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/earMajor.js b/js/medicine/surgery/reaction/earMajor.js index 1c28a90029b..ba0ce0e6b18 100644 --- a/js/medicine/surgery/reaction/earMajor.js +++ b/js/medicine/surgery/reaction/earMajor.js @@ -2,8 +2,8 @@ class EarMajor extends App.Medicine.Surgery.Reaction { get key() { return "earMajor"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/earMinor.js b/js/medicine/surgery/reaction/earMinor.js index 3be3fb38146..a480f7d78c4 100644 --- a/js/medicine/surgery/reaction/earMinor.js +++ b/js/medicine/surgery/reaction/earMinor.js @@ -2,8 +2,8 @@ class EarMinor extends App.Medicine.Surgery.Reaction { get key() { return "earMinor"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/earMuffle.js b/js/medicine/surgery/reaction/earMuffle.js index f751392a7c5..cfbf772e9cc 100644 --- a/js/medicine/surgery/reaction/earMuffle.js +++ b/js/medicine/surgery/reaction/earMuffle.js @@ -2,8 +2,8 @@ class EarMuffle extends App.Medicine.Surgery.Reaction { get key() { return "earMuffle"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/earRestore.js b/js/medicine/surgery/reaction/earRestore.js index 08593020029..8ff076bfa2b 100644 --- a/js/medicine/surgery/reaction/earRestore.js +++ b/js/medicine/surgery/reaction/earRestore.js @@ -2,8 +2,8 @@ class EarRestore extends App.Medicine.Surgery.Reaction { get key() { return "earRestore"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/ejaculation.js b/js/medicine/surgery/reaction/ejaculation.js index 9725306a590..545b5d2358b 100644 --- a/js/medicine/surgery/reaction/ejaculation.js +++ b/js/medicine/surgery/reaction/ejaculation.js @@ -2,8 +2,8 @@ class Ejaculation extends App.Medicine.Surgery.Reaction { get key() { return "ejaculation"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/electrolarynx.js b/js/medicine/surgery/reaction/electrolarynx.js index da09e237e2f..15e0f761592 100644 --- a/js/medicine/surgery/reaction/electrolarynx.js +++ b/js/medicine/surgery/reaction/electrolarynx.js @@ -2,8 +2,8 @@ class Electrolarynx extends App.Medicine.Surgery.Reaction { get key() { return "electrolarynx"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/endEjaculation.js b/js/medicine/surgery/reaction/endEjaculation.js index fed430448b1..ea4d1c620d4 100644 --- a/js/medicine/surgery/reaction/endEjaculation.js +++ b/js/medicine/surgery/reaction/endEjaculation.js @@ -2,8 +2,8 @@ class EndEjaculation extends App.Medicine.Surgery.Reaction { get key() { return "endejac"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/endLactation.js b/js/medicine/surgery/reaction/endLactation.js index a649b8e24d7..0d6f0ea8afb 100644 --- a/js/medicine/surgery/reaction/endLactation.js +++ b/js/medicine/surgery/reaction/endLactation.js @@ -2,8 +2,8 @@ class EndLactation extends App.Medicine.Surgery.Reaction { get key() { return "endlac"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/endPrecum.js b/js/medicine/surgery/reaction/endPrecum.js index 407ca25b311..4cc7471bea6 100644 --- a/js/medicine/surgery/reaction/endPrecum.js +++ b/js/medicine/surgery/reaction/endPrecum.js @@ -2,8 +2,8 @@ class EndPrecum extends App.Medicine.Surgery.Reaction { get key() { return "endprecum"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {he, His, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/fang.js b/js/medicine/surgery/reaction/fang.js index a77912ca1bf..ce228c3974b 100644 --- a/js/medicine/surgery/reaction/fang.js +++ b/js/medicine/surgery/reaction/fang.js @@ -2,8 +2,8 @@ class Fang extends App.Medicine.Surgery.Reaction { get key() { return "fang"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/fangs.js b/js/medicine/surgery/reaction/fangs.js index 38eaaa1a7ce..f7ecf2abadc 100644 --- a/js/medicine/surgery/reaction/fangs.js +++ b/js/medicine/surgery/reaction/fangs.js @@ -2,8 +2,8 @@ class Fangs extends App.Medicine.Surgery.Reaction { get key() { return "fangs"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/fatGraft.js b/js/medicine/surgery/reaction/fatGraft.js index 2415c49e37a..d2e59855687 100644 --- a/js/medicine/surgery/reaction/fatGraft.js +++ b/js/medicine/surgery/reaction/fatGraft.js @@ -2,8 +2,8 @@ class FatGraft extends App.Medicine.Surgery.Reaction { get key() { return "fat graft"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/fertility.js b/js/medicine/surgery/reaction/fertility.js index 891b9c8ddc9..9463965e559 100644 --- a/js/medicine/surgery/reaction/fertility.js +++ b/js/medicine/surgery/reaction/fertility.js @@ -2,8 +2,8 @@ class Fertility extends App.Medicine.Surgery.Reaction { get key() { return "fert"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/foreskinTuck.js b/js/medicine/surgery/reaction/foreskinTuck.js index fc2bbbcca3b..21e4bb858c4 100644 --- a/js/medicine/surgery/reaction/foreskinTuck.js +++ b/js/medicine/surgery/reaction/foreskinTuck.js @@ -2,8 +2,8 @@ class ForeskinTuck extends App.Medicine.Surgery.Reaction { get key() { return "foreskinTuck"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/freshOvaries.js b/js/medicine/surgery/reaction/freshOvaries.js index 9bc9f5a4716..72a223c966a 100644 --- a/js/medicine/surgery/reaction/freshOvaries.js +++ b/js/medicine/surgery/reaction/freshOvaries.js @@ -2,8 +2,8 @@ class FreshOvaries extends App.Medicine.Surgery.Reaction { get key() { return "freshOvaries"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/fuckdoll.js b/js/medicine/surgery/reaction/fuckdoll.js index 3e37ba1027a..2eae08d38d6 100644 --- a/js/medicine/surgery/reaction/fuckdoll.js +++ b/js/medicine/surgery/reaction/fuckdoll.js @@ -21,8 +21,8 @@ return r; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, sister, wife} = getPronouns(slave); const relations = V.slaves.filter((s) => areRelated(s, slave) && (s.ID !== slave.relationshipTarget)); let r = []; diff --git a/js/medicine/surgery/reaction/fuckdollExtraction.js b/js/medicine/surgery/reaction/fuckdollExtraction.js index 9ec9c26d6fb..f782591a350 100644 --- a/js/medicine/surgery/reaction/fuckdollExtraction.js +++ b/js/medicine/surgery/reaction/fuckdollExtraction.js @@ -16,8 +16,8 @@ return r; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; r.push(`If you were expecting a great return to humanity after extracting ${him} from ${his} Fuckdoll suit, you're to be disappointed.`); diff --git a/js/medicine/surgery/reaction/geld.js b/js/medicine/surgery/reaction/geld.js index df1a0d50361..4beca584b69 100644 --- a/js/medicine/surgery/reaction/geld.js +++ b/js/medicine/surgery/reaction/geld.js @@ -2,8 +2,8 @@ class Geld extends App.Medicine.Surgery.Reaction { get key() { return "geld"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/herm.js b/js/medicine/surgery/reaction/herm.js index 33618c5a373..87000a76838 100644 --- a/js/medicine/surgery/reaction/herm.js +++ b/js/medicine/surgery/reaction/herm.js @@ -2,8 +2,8 @@ class Herm extends App.Medicine.Surgery.Reaction { get key() { return "herm"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const {he: heP} = getPronouns(V.PC); const r = []; diff --git a/js/medicine/surgery/reaction/horn.js b/js/medicine/surgery/reaction/horn.js index 31e3c22070b..0b0c91b7279 100644 --- a/js/medicine/surgery/reaction/horn.js +++ b/js/medicine/surgery/reaction/horn.js @@ -2,8 +2,8 @@ class Horn extends App.Medicine.Surgery.Reaction { get key() { return "horn"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/hornGone.js b/js/medicine/surgery/reaction/hornGone.js index 96d62f48010..7127c8b0f9d 100644 --- a/js/medicine/surgery/reaction/hornGone.js +++ b/js/medicine/surgery/reaction/hornGone.js @@ -2,8 +2,8 @@ class HornGone extends App.Medicine.Surgery.Reaction { get key() { return "hornGone"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/insemination.js b/js/medicine/surgery/reaction/insemination.js index d8ea7999059..7a35cdb6828 100644 --- a/js/medicine/surgery/reaction/insemination.js +++ b/js/medicine/surgery/reaction/insemination.js @@ -6,8 +6,8 @@ get permanentChanges() { return false; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/labiaplasty.js b/js/medicine/surgery/reaction/labiaplasty.js index 87a8f5a5d75..a4480fe5d39 100644 --- a/js/medicine/surgery/reaction/labiaplasty.js +++ b/js/medicine/surgery/reaction/labiaplasty.js @@ -2,8 +2,8 @@ class Labiaplasty extends App.Medicine.Surgery.Reaction { get key() { return "labiaplasty"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/lactation.js b/js/medicine/surgery/reaction/lactation.js index f19997830ea..c6e99eac5e8 100644 --- a/js/medicine/surgery/reaction/lactation.js +++ b/js/medicine/surgery/reaction/lactation.js @@ -2,8 +2,8 @@ class Lactation extends App.Medicine.Surgery.Reaction { get key() { return "lactation"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/lipo.js b/js/medicine/surgery/reaction/lipo.js index 4d15e32d08c..535413ef1ba 100644 --- a/js/medicine/surgery/reaction/lipo.js +++ b/js/medicine/surgery/reaction/lipo.js @@ -2,8 +2,8 @@ class Lipo extends App.Medicine.Surgery.Reaction { get key() { return "lipo"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/liposuction.js b/js/medicine/surgery/reaction/liposuction.js index 5b1829e0bcc..6e7cd41e9cf 100644 --- a/js/medicine/surgery/reaction/liposuction.js +++ b/js/medicine/surgery/reaction/liposuction.js @@ -2,8 +2,8 @@ class Liposuction extends App.Medicine.Surgery.Reaction { get key() { return "liposuction"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/lips.js b/js/medicine/surgery/reaction/lips.js index 801dc62b813..d790a1be1bc 100644 --- a/js/medicine/surgery/reaction/lips.js +++ b/js/medicine/surgery/reaction/lips.js @@ -2,8 +2,8 @@ class Lips extends App.Medicine.Surgery.Reaction { get key() { return "lips"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/maleToFemale.js b/js/medicine/surgery/reaction/maleToFemale.js index 0f187848e95..48b2aaa2494 100644 --- a/js/medicine/surgery/reaction/maleToFemale.js +++ b/js/medicine/surgery/reaction/maleToFemale.js @@ -2,8 +2,8 @@ class MaletoFemale extends App.Medicine.Surgery.Reaction { get key() { return "mtf"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/mastectomy.js b/js/medicine/surgery/reaction/mastectomy.js index 91c897c3b09..f0acf350dc1 100644 --- a/js/medicine/surgery/reaction/mastectomy.js +++ b/js/medicine/surgery/reaction/mastectomy.js @@ -2,8 +2,8 @@ class Mastectomy extends App.Medicine.Surgery.Reaction { get key() { return "mastectomy"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/mastectomyPlus.js b/js/medicine/surgery/reaction/mastectomyPlus.js index 94f54aaad50..e1223d403c7 100644 --- a/js/medicine/surgery/reaction/mastectomyPlus.js +++ b/js/medicine/surgery/reaction/mastectomyPlus.js @@ -2,8 +2,8 @@ class MastectomyPlus extends App.Medicine.Surgery.Reaction { get key() { return "mastectomy+"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/mindbreak.js b/js/medicine/surgery/reaction/mindbreak.js index 5a8af13da0e..c3a63cc8d36 100644 --- a/js/medicine/surgery/reaction/mindbreak.js +++ b/js/medicine/surgery/reaction/mindbreak.js @@ -4,8 +4,8 @@ get removeJob() { return true; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, His, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/mpreg.js b/js/medicine/surgery/reaction/mpreg.js index 4ef887f510a..7152eda77f2 100644 --- a/js/medicine/surgery/reaction/mpreg.js +++ b/js/medicine/surgery/reaction/mpreg.js @@ -2,8 +2,8 @@ class MPreg extends App.Medicine.Surgery.Reaction { get key() { return "mpreg"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/mpregRemoved.js b/js/medicine/surgery/reaction/mpregRemoved.js index f646617d009..5b22f1d9629 100644 --- a/js/medicine/surgery/reaction/mpregRemoved.js +++ b/js/medicine/surgery/reaction/mpregRemoved.js @@ -2,8 +2,8 @@ class MPregRemoved extends App.Medicine.Surgery.Reaction { get key() { return "mpreg removed"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/mute.js b/js/medicine/surgery/reaction/mute.js index 8874edca4fb..9bc41e03476 100644 --- a/js/medicine/surgery/reaction/mute.js +++ b/js/medicine/surgery/reaction/mute.js @@ -2,8 +2,8 @@ class Mute extends App.Medicine.Surgery.Reaction { get key() { return "mute"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/newEars.js b/js/medicine/surgery/reaction/newEars.js index b4cb684f1c8..0eb0d396131 100644 --- a/js/medicine/surgery/reaction/newEars.js +++ b/js/medicine/surgery/reaction/newEars.js @@ -2,8 +2,8 @@ class NewEars extends App.Medicine.Surgery.Reaction { get key() { return "newEars"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/newEyes.js b/js/medicine/surgery/reaction/newEyes.js index c8d37f82f44..b9213bfd677 100644 --- a/js/medicine/surgery/reaction/newEyes.js +++ b/js/medicine/surgery/reaction/newEyes.js @@ -2,8 +2,8 @@ class NewEyes extends App.Medicine.Surgery.Reaction { get key() { return "newEyes"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/newVoice.js b/js/medicine/surgery/reaction/newVoice.js index dce1e1b7f3a..711e47b36a7 100644 --- a/js/medicine/surgery/reaction/newVoice.js +++ b/js/medicine/surgery/reaction/newVoice.js @@ -2,8 +2,8 @@ class NewVoice extends App.Medicine.Surgery.Reaction { get key() { return "newVoice"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/nippleCunts.js b/js/medicine/surgery/reaction/nippleCunts.js index 453de0b6063..838471ca442 100644 --- a/js/medicine/surgery/reaction/nippleCunts.js +++ b/js/medicine/surgery/reaction/nippleCunts.js @@ -2,8 +2,8 @@ class NippleCunts extends App.Medicine.Surgery.Reaction { get key() { return "nippleCunts"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/noneToFemale.js b/js/medicine/surgery/reaction/noneToFemale.js index e1ba89f0878..5ba77dba983 100644 --- a/js/medicine/surgery/reaction/noneToFemale.js +++ b/js/medicine/surgery/reaction/noneToFemale.js @@ -2,8 +2,8 @@ class NoneToFemale extends App.Medicine.Surgery.Reaction { get key() { return "ntf"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself, hers} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/ocularImplant.js b/js/medicine/surgery/reaction/ocularImplant.js index b87247a9e7e..c477c4af3dc 100644 --- a/js/medicine/surgery/reaction/ocularImplant.js +++ b/js/medicine/surgery/reaction/ocularImplant.js @@ -2,8 +2,8 @@ class OcularImplant extends App.Medicine.Surgery.Reaction { get key() { return "ocular implant"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/ocularImplantForBlind.js b/js/medicine/surgery/reaction/ocularImplantForBlind.js index 44fe5fb1861..1b78e510901 100644 --- a/js/medicine/surgery/reaction/ocularImplantForBlind.js +++ b/js/medicine/surgery/reaction/ocularImplantForBlind.js @@ -2,8 +2,8 @@ class OcularImplantForBlind extends App.Medicine.Surgery.Reaction { get key() { return "ocular implant for blind"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; r.push(`The implant surgery is <span class="health dec">invasive</span> and ${he} spends some time in the autosurgery recovering. As soon as ${he} is allowed to open ${his} eyes and look around, ${his} gaze flicks from object to object with manic speed as ${his} new eyes deliver nearly overwhelming amount of visual information. Seeing the world as it is is a gift that those who do not need it cannot properly understand.`); diff --git a/js/medicine/surgery/reaction/oral.js b/js/medicine/surgery/reaction/oral.js index 082f818b052..13cc9de8abf 100644 --- a/js/medicine/surgery/reaction/oral.js +++ b/js/medicine/surgery/reaction/oral.js @@ -2,8 +2,8 @@ class Oral extends App.Medicine.Surgery.Reaction { get key() { return "oral"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/ovaImplantChanged.js b/js/medicine/surgery/reaction/ovaImplantChanged.js index 1b41538b9a1..6943d9fc3e9 100644 --- a/js/medicine/surgery/reaction/ovaImplantChanged.js +++ b/js/medicine/surgery/reaction/ovaImplantChanged.js @@ -2,8 +2,8 @@ class OvaImplantChanged extends App.Medicine.Surgery.Reaction { get key() { return "ovaImplant changed"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/pLimbInterface.js b/js/medicine/surgery/reaction/pLimbInterface.js index 4b1e1a909ba..20038351b0c 100644 --- a/js/medicine/surgery/reaction/pLimbInterface.js +++ b/js/medicine/surgery/reaction/pLimbInterface.js @@ -2,8 +2,8 @@ class PLimbInterface extends App.Medicine.Surgery.Reaction { get key() { return "PLimb interface"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const r = []; V.nextButton = " "; diff --git a/js/medicine/surgery/reaction/pLimbInterface1.js b/js/medicine/surgery/reaction/pLimbInterface1.js index 16020fdff6a..d694c871280 100644 --- a/js/medicine/surgery/reaction/pLimbInterface1.js +++ b/js/medicine/surgery/reaction/pLimbInterface1.js @@ -2,8 +2,8 @@ class PLimbInterface1 extends App.Medicine.Surgery.Reaction { get key() { return "PLimb interface1"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, hers} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/pLimbInterface2.js b/js/medicine/surgery/reaction/pLimbInterface2.js index f7756b3c168..57d26f78592 100644 --- a/js/medicine/surgery/reaction/pLimbInterface2.js +++ b/js/medicine/surgery/reaction/pLimbInterface2.js @@ -2,8 +2,8 @@ class PLimbInterface2 extends App.Medicine.Surgery.Reaction { get key() { return "PLimb interface2"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, hers} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/pLimbInterface3.js b/js/medicine/surgery/reaction/pLimbInterface3.js index 475ac751248..3d7bbb14303 100644 --- a/js/medicine/surgery/reaction/pLimbInterface3.js +++ b/js/medicine/surgery/reaction/pLimbInterface3.js @@ -2,8 +2,8 @@ class PLimbInterface3 extends App.Medicine.Surgery.Reaction { get key() { return "PLimb interface3"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, hers, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/precum.js b/js/medicine/surgery/reaction/precum.js index 07f4a0464b6..8c330a430f7 100644 --- a/js/medicine/surgery/reaction/precum.js +++ b/js/medicine/surgery/reaction/precum.js @@ -2,8 +2,8 @@ class Precum extends App.Medicine.Surgery.Reaction { get key() { return "precum"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/preg.js b/js/medicine/surgery/reaction/preg.js index 3ff922700a1..15ab52579bf 100644 --- a/js/medicine/surgery/reaction/preg.js +++ b/js/medicine/surgery/reaction/preg.js @@ -2,8 +2,8 @@ class Preg extends App.Medicine.Surgery.Reaction { get key() { return "preg"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); let r = []; diff --git a/js/medicine/surgery/reaction/preg1hack.js b/js/medicine/surgery/reaction/preg1hack.js index 8d69e51fa95..122d4d9f85a 100644 --- a/js/medicine/surgery/reaction/preg1hack.js +++ b/js/medicine/surgery/reaction/preg1hack.js @@ -2,8 +2,8 @@ class Preg1Hack extends App.Medicine.Surgery.Reaction { get key() { return "preg1hack"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/pregRemove.js b/js/medicine/surgery/reaction/pregRemove.js index 7c5529c747b..89e0b099b4a 100644 --- a/js/medicine/surgery/reaction/pregRemove.js +++ b/js/medicine/surgery/reaction/pregRemove.js @@ -2,8 +2,8 @@ class PregRemove extends App.Medicine.Surgery.Reaction { get key() { return "pregRemove"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/prostate.js b/js/medicine/surgery/reaction/prostate.js index 32f06d7d038..664c7b532db 100644 --- a/js/medicine/surgery/reaction/prostate.js +++ b/js/medicine/surgery/reaction/prostate.js @@ -2,8 +2,8 @@ class Prostate extends App.Medicine.Surgery.Reaction { get key() { return "prostate"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/race.js b/js/medicine/surgery/reaction/race.js index 238ff4e3663..af852fa640e 100644 --- a/js/medicine/surgery/reaction/race.js +++ b/js/medicine/surgery/reaction/race.js @@ -2,8 +2,8 @@ class Race extends App.Medicine.Surgery.Reaction { get key() { return "race"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/relocate.js b/js/medicine/surgery/reaction/relocate.js index 27d75ed661e..e8dc27bb9e2 100644 --- a/js/medicine/surgery/reaction/relocate.js +++ b/js/medicine/surgery/reaction/relocate.js @@ -2,8 +2,8 @@ class Relocate extends App.Medicine.Surgery.Reaction { get key() { return "relocate"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/removeBraces.js b/js/medicine/surgery/reaction/removeBraces.js index 5b35aa2c9c7..81afca27be3 100644 --- a/js/medicine/surgery/reaction/removeBraces.js +++ b/js/medicine/surgery/reaction/removeBraces.js @@ -6,8 +6,8 @@ get permanentChanges() { return false; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/removeCosmeticBraces.js b/js/medicine/surgery/reaction/removeCosmeticBraces.js index 29276eda4d4..979b9c66528 100644 --- a/js/medicine/surgery/reaction/removeCosmeticBraces.js +++ b/js/medicine/surgery/reaction/removeCosmeticBraces.js @@ -6,8 +6,8 @@ get permanentChanges() { return false; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/resmell.js b/js/medicine/surgery/reaction/resmell.js index 6924d60d509..53d8485fed7 100644 --- a/js/medicine/surgery/reaction/resmell.js +++ b/js/medicine/surgery/reaction/resmell.js @@ -2,8 +2,8 @@ class Resmell extends App.Medicine.Surgery.Reaction { get key() { return "resmell"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/restoreHairBrow.js b/js/medicine/surgery/reaction/restoreHairBrow.js index 73af6f18f37..8c28dca9110 100644 --- a/js/medicine/surgery/reaction/restoreHairBrow.js +++ b/js/medicine/surgery/reaction/restoreHairBrow.js @@ -7,8 +7,8 @@ return [`As the remote surgery's long recovery cycle completes, ${slave.slaveName} begins to stir.`]; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/restoreHairHead.js b/js/medicine/surgery/reaction/restoreHairHead.js index f68528a327a..2f685824921 100644 --- a/js/medicine/surgery/reaction/restoreHairHead.js +++ b/js/medicine/surgery/reaction/restoreHairHead.js @@ -7,8 +7,8 @@ return [`As the remote surgery's long recovery cycle completes, ${slave.slaveName} begins to stir.`]; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/restoreHairPits.js b/js/medicine/surgery/reaction/restoreHairPits.js index 018b1970fca..f844dd361cf 100644 --- a/js/medicine/surgery/reaction/restoreHairPits.js +++ b/js/medicine/surgery/reaction/restoreHairPits.js @@ -7,8 +7,8 @@ return [`As the remote surgery's long recovery cycle completes, ${slave.slaveName} begins to stir.`]; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const pubertyAge = Math.min(slave.pubertyAgeXX, slave.pubertyAgeXY); const r = []; diff --git a/js/medicine/surgery/reaction/restoreHairPubes.js b/js/medicine/surgery/reaction/restoreHairPubes.js index cf9b9545033..48491a9ca32 100644 --- a/js/medicine/surgery/reaction/restoreHairPubes.js +++ b/js/medicine/surgery/reaction/restoreHairPubes.js @@ -7,8 +7,8 @@ return [`As the remote surgery's long recovery cycle completes, ${slave.slaveName} begins to stir.`]; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const pubertyAge = Math.min(slave.pubertyAgeXX, slave.pubertyAgeXY); const r = []; diff --git a/js/medicine/surgery/reaction/restoreVoice.js b/js/medicine/surgery/reaction/restoreVoice.js index 149e95d55be..3ad5537d80d 100644 --- a/js/medicine/surgery/reaction/restoreVoice.js +++ b/js/medicine/surgery/reaction/restoreVoice.js @@ -2,8 +2,8 @@ class RestoreVoice extends App.Medicine.Surgery.Reaction { get key() { return "restoreVoice"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/retaste.js b/js/medicine/surgery/reaction/retaste.js index a4129427a0c..df86d09cbf4 100644 --- a/js/medicine/surgery/reaction/retaste.js +++ b/js/medicine/surgery/reaction/retaste.js @@ -2,8 +2,8 @@ class Retaste extends App.Medicine.Surgery.Reaction { get key() { return "retaste"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/retrogradeVirusInjectionNCS.js b/js/medicine/surgery/reaction/retrogradeVirusInjectionNCS.js index 25a58e09577..7d081e89fd6 100644 --- a/js/medicine/surgery/reaction/retrogradeVirusInjectionNCS.js +++ b/js/medicine/surgery/reaction/retrogradeVirusInjectionNCS.js @@ -2,8 +2,8 @@ class RetrogradeVirusInjectionNCS extends App.Medicine.Surgery.Reaction { get key() { return "retrograde virus injection NCS"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const pubertyAge = Math.min(slave.pubertyAgeXX, slave.pubertyAgeXY); const genitalChanges = []; diff --git a/js/medicine/surgery/reaction/ribs.js b/js/medicine/surgery/reaction/ribs.js index 397c64cf0fa..bc4aaabbbcd 100644 --- a/js/medicine/surgery/reaction/ribs.js +++ b/js/medicine/surgery/reaction/ribs.js @@ -2,8 +2,8 @@ class Ribs extends App.Medicine.Surgery.Reaction { get key() { return "ribs"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/scrotalTuck.js b/js/medicine/surgery/reaction/scrotalTuck.js index c108746d120..c6dd71d3de6 100644 --- a/js/medicine/surgery/reaction/scrotalTuck.js +++ b/js/medicine/surgery/reaction/scrotalTuck.js @@ -2,8 +2,8 @@ class ScrotalTuck extends App.Medicine.Surgery.Reaction { get key() { return "scrotalTuck"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/sharp.js b/js/medicine/surgery/reaction/sharp.js index 6e4cf8a167f..213349656ad 100644 --- a/js/medicine/surgery/reaction/sharp.js +++ b/js/medicine/surgery/reaction/sharp.js @@ -2,8 +2,8 @@ class Sharp extends App.Medicine.Surgery.Reaction { get key() { return "sharp"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/sterilize.js b/js/medicine/surgery/reaction/sterilize.js index e5c089faac5..475c43a3e84 100644 --- a/js/medicine/surgery/reaction/sterilize.js +++ b/js/medicine/surgery/reaction/sterilize.js @@ -2,8 +2,8 @@ class Sterilize extends App.Medicine.Surgery.Reaction { get key() { return "ster"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/tailInterface.js b/js/medicine/surgery/reaction/tailInterface.js index 42a5c303c1b..591047ec685 100644 --- a/js/medicine/surgery/reaction/tailInterface.js +++ b/js/medicine/surgery/reaction/tailInterface.js @@ -2,8 +2,8 @@ class TailInterface extends App.Medicine.Surgery.Reaction { get key() { return "tailInterface"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/teeth.js b/js/medicine/surgery/reaction/teeth.js index 0e89280c636..40d1c81b5a9 100644 --- a/js/medicine/surgery/reaction/teeth.js +++ b/js/medicine/surgery/reaction/teeth.js @@ -2,8 +2,8 @@ class Teeth extends App.Medicine.Surgery.Reaction { get key() { return "teeth"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/treatment.js b/js/medicine/surgery/reaction/treatment.js index a169bf8f176..fac094c49e3 100644 --- a/js/medicine/surgery/reaction/treatment.js +++ b/js/medicine/surgery/reaction/treatment.js @@ -3,8 +3,8 @@ // unifies "elasticity treatment", "immortality treatment" and "gene treatment" get key() { return "gene treatment"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/tummyTuck.js b/js/medicine/surgery/reaction/tummyTuck.js index fe658950dec..3ea39e57162 100644 --- a/js/medicine/surgery/reaction/tummyTuck.js +++ b/js/medicine/surgery/reaction/tummyTuck.js @@ -2,8 +2,8 @@ class TummyTuck extends App.Medicine.Surgery.Reaction { get key() { return "tummyTuck"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/unblind.js b/js/medicine/surgery/reaction/unblind.js index 4ef399825c4..b4d911f4adf 100644 --- a/js/medicine/surgery/reaction/unblind.js +++ b/js/medicine/surgery/reaction/unblind.js @@ -2,8 +2,8 @@ class Unblind extends App.Medicine.Surgery.Reaction { get key() { return "unblind"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; r.push(`The eye surgery is <span class="health dec">invasive</span> and ${he} spends some time in the autosurgery recovering. As soon as ${he} is allowed to open ${his} eyes and look around, ${his} gaze flicks from object to object with manic speed as ${he} processes ${his} new vision. Seeing the world as it is is a gift that those who do not need it cannot properly understand.`); diff --git a/js/medicine/surgery/reaction/undeafen.js b/js/medicine/surgery/reaction/undeafen.js index 842aa16cf3e..9ace8a302d5 100644 --- a/js/medicine/surgery/reaction/undeafen.js +++ b/js/medicine/surgery/reaction/undeafen.js @@ -2,8 +2,8 @@ class Undeafen extends App.Medicine.Surgery.Reaction { get key() { return "undeafen"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; r.push(`The inner ear surgery is <span class="health dec">invasive</span> and ${he} spends some time in the autosurgery recovering. As soon as the bandages around ${his} ears are removed, ${his} head tilts towards any source of sound with manic speed as ${he} processes ${his} new hearing. Hearing the world as it is is a gift that those who do not need it cannot properly understand.`); diff --git a/js/medicine/surgery/reaction/vagina.js b/js/medicine/surgery/reaction/vagina.js index cd5087e7525..618caf66707 100644 --- a/js/medicine/surgery/reaction/vagina.js +++ b/js/medicine/surgery/reaction/vagina.js @@ -2,8 +2,8 @@ class Vagina extends App.Medicine.Surgery.Reaction { get key() { return "vagina"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/vaginalRemoval.js b/js/medicine/surgery/reaction/vaginalRemoval.js index dd78d84a405..d4b6537d73a 100644 --- a/js/medicine/surgery/reaction/vaginalRemoval.js +++ b/js/medicine/surgery/reaction/vaginalRemoval.js @@ -2,8 +2,8 @@ class VaginaRemoval extends App.Medicine.Surgery.Reaction { get key() { return "vaginaRemoval"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him, himself} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/vasectomy.js b/js/medicine/surgery/reaction/vasectomy.js index db71e80a7a2..8b3d5086a13 100644 --- a/js/medicine/surgery/reaction/vasectomy.js +++ b/js/medicine/surgery/reaction/vasectomy.js @@ -2,8 +2,8 @@ class Vasectomy extends App.Medicine.Surgery.Reaction { get key() { return "vasectomy"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/vasectomyUndo.js b/js/medicine/surgery/reaction/vasectomyUndo.js index 6a1248601ca..714145dd43c 100644 --- a/js/medicine/surgery/reaction/vasectomyUndo.js +++ b/js/medicine/surgery/reaction/vasectomyUndo.js @@ -2,8 +2,8 @@ class VasectomyUndo extends App.Medicine.Surgery.Reaction { get key() { return "vasectomy undo"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/voiceLower.js b/js/medicine/surgery/reaction/voiceLower.js index 6c681158656..af789d351f3 100644 --- a/js/medicine/surgery/reaction/voiceLower.js +++ b/js/medicine/surgery/reaction/voiceLower.js @@ -2,8 +2,8 @@ class VoiceLower extends App.Medicine.Surgery.Reaction { get key() { return "voice2"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself, hers} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/voiceRaise.js b/js/medicine/surgery/reaction/voiceRaise.js index 3c06e2c7eb5..14a46663870 100644 --- a/js/medicine/surgery/reaction/voiceRaise.js +++ b/js/medicine/surgery/reaction/voiceRaise.js @@ -2,8 +2,8 @@ class VoiceRaise extends App.Medicine.Surgery.Reaction { get key() { return "voice"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him, himself, hers} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/reaction/womb.js b/js/medicine/surgery/reaction/womb.js index 5a40a650f43..3970231e394 100644 --- a/js/medicine/surgery/reaction/womb.js +++ b/js/medicine/surgery/reaction/womb.js @@ -2,8 +2,8 @@ class Womb extends App.Medicine.Surgery.Reaction { get key() { return "womb"; } - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {he, his, him} = getPronouns(slave); const r = []; diff --git a/js/medicine/surgery/structural/heels.js b/js/medicine/surgery/structural/heels.js index 924b170407d..32dc4cc9e5a 100644 --- a/js/medicine/surgery/structural/heels.js +++ b/js/medicine/surgery/structural/heels.js @@ -1,6 +1,6 @@ App.Medicine.Surgery.Reactions.ShortenTendons = class extends App.Medicine.Surgery.SimpleReaction { - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, His, his, him} = getPronouns(slave); const r = []; @@ -41,8 +41,8 @@ App.Medicine.Surgery.Reactions.ShortenTendons = class extends App.Medicine.Surge }; App.Medicine.Surgery.Reactions.ReplaceTendons = class extends App.Medicine.Surgery.SimpleReaction { - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; @@ -65,16 +65,16 @@ App.Medicine.Surgery.Procedures.ShortenTendons = class extends App.Medicine.Surg get name() { return "Shorten tendons"; } get description() { - const {him} = getPronouns(this.slave); + const {him} = getPronouns(this._slave); return `Prevents ${him} from walking in anything but very high heels`; } get healthCost() { return 20; } apply(cheat) { - this.slave.heels = 1; - this.slave.shoes = "heels"; - return new App.Medicine.Surgery.Reactions.ShortenTendons(); + this._slave.heels = 1; + this._slave.shoes = "heels"; + return this._assemble(new App.Medicine.Surgery.Reactions.ShortenTendons()); } }; @@ -85,8 +85,8 @@ App.Medicine.Surgery.Procedures.ReplaceTendons = class extends App.Medicine.Surg get healthCost() { return 10; } apply(cheat) { - this.slave.heels = 0; - this.slave.shoes = "none"; - return new App.Medicine.Surgery.Reactions.ReplaceTendons(); + this._slave.heels = 0; + this._slave.shoes = "none"; + return this._assemble(new App.Medicine.Surgery.Reactions.ReplaceTendons()); } }; diff --git a/js/medicine/surgery/structural/height.js b/js/medicine/surgery/structural/height.js index 0ca2bc438f3..ec9af2f5953 100644 --- a/js/medicine/surgery/structural/height.js +++ b/js/medicine/surgery/structural/height.js @@ -1,6 +1,6 @@ App.Medicine.Surgery.Reactions.Height = class extends App.Medicine.Surgery.SimpleReaction { - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; @@ -25,11 +25,11 @@ App.Medicine.Surgery.Reactions.Height = class extends App.Medicine.Surgery.Simpl App.Medicine.Surgery.Procedures.IncreaseHeight = class extends App.Medicine.Surgery.Procedure { get name() { - if (this.slave.heightImplant === 0) { + if (this._slave.heightImplant === 0) { return "Lengthen major bones"; - } else if (this.slave.heightImplant >= 1) { + } else if (this._slave.heightImplant >= 1) { return "Advanced height gain surgery"; - } else if (this.slave.heightImplant === -1) { + } else if (this._slave.heightImplant === -1) { return "Reverse existing height surgery"; } else { return "Revert a stage of existing height surgery"; @@ -39,20 +39,20 @@ App.Medicine.Surgery.Procedures.IncreaseHeight = class extends App.Medicine.Surg get healthCost() { return 40; } apply(cheat) { - this.slave.heightImplant += 1; - this.slave.height += 10; - return new App.Medicine.Surgery.Reactions.ShortenTendons(); + this._slave.heightImplant += 1; + this._slave.height += 10; + return this._assemble(new App.Medicine.Surgery.Reactions.ShortenTendons()); } }; App.Medicine.Surgery.Procedures.DecreaseHeight = class extends App.Medicine.Surgery.Procedure { get name() { - if (this.slave.heightImplant === 0) { + if (this._slave.heightImplant === 0) { return "Shorten major bones"; - } else if (this.slave.heightImplant <= -1) { + } else if (this._slave.heightImplant <= -1) { return "Advanced height reduction surgery"; - } else if (this.slave.heightImplant === 1) { + } else if (this._slave.heightImplant === 1) { return "Reverse existing height surgery"; } else { return "Revert a stage of existing height surgery"; @@ -62,8 +62,8 @@ App.Medicine.Surgery.Procedures.DecreaseHeight = class extends App.Medicine.Surg get healthCost() { return 40; } apply(cheat) { - this.slave.heightImplant -= 1; - this.slave.height -= 10; - return new App.Medicine.Surgery.Reactions.ShortenTendons(); + this._slave.heightImplant -= 1; + this._slave.height -= 10; + return this._assemble(new App.Medicine.Surgery.Reactions.ShortenTendons()); } }; diff --git a/js/medicine/surgery/structural/hips.js b/js/medicine/surgery/structural/hips.js index 47b0eaee477..be184d8e1d4 100644 --- a/js/medicine/surgery/structural/hips.js +++ b/js/medicine/surgery/structural/hips.js @@ -1,6 +1,6 @@ App.Medicine.Surgery.Reactions.Hips = class extends App.Medicine.Surgery.SimpleReaction { - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; @@ -23,26 +23,26 @@ App.Medicine.Surgery.Reactions.Hips = class extends App.Medicine.Surgery.SimpleR }; App.Medicine.Surgery.Procedures.BroadenPelvis = class extends App.Medicine.Surgery.Procedure { - get name() { return this.slave.shouldersImplant === 0 ? "Broaden pelvis" : "Advanced pelvis broadening"; } + get name() { return this._slave.shouldersImplant === 0 ? "Broaden pelvis" : "Advanced pelvis broadening"; } get healthCost() { return 40; } apply(cheat) { - this.slave.hipsImplant++; - this.slave.hips++; - return new App.Medicine.Surgery.Reactions.Hips(); + this._slave.hipsImplant++; + this._slave.hips++; + return this._assemble(new App.Medicine.Surgery.Reactions.Hips()); } }; App.Medicine.Surgery.Procedures.NarrowPelvis = class extends App.Medicine.Surgery.Procedure { - get name() { return this.slave.shouldersImplant === 0 ? "Narrow pelvis" : "Advanced pelvis narrowing"; } + get name() { return this._slave.shouldersImplant === 0 ? "Narrow pelvis" : "Advanced pelvis narrowing"; } get healthCost() { return 40; } apply(cheat) { - this.slave.hipsImplant--; - this.slave.hips--; - return new App.Medicine.Surgery.Reactions.Hips(); + this._slave.hipsImplant--; + this._slave.hips--; + return this._assemble(new App.Medicine.Surgery.Reactions.Hips()); } }; diff --git a/js/medicine/surgery/structural/shoulders.js b/js/medicine/surgery/structural/shoulders.js index 587971e0095..4ebd4d154cf 100644 --- a/js/medicine/surgery/structural/shoulders.js +++ b/js/medicine/surgery/structural/shoulders.js @@ -1,6 +1,6 @@ App.Medicine.Surgery.Reactions.Shoulders = class extends App.Medicine.Surgery.SimpleReaction { - reaction(slave) { - const reaction = super.reaction(slave); + reaction(slave, diff) { + const reaction = super.reaction(slave, diff); const {He, he, his, him} = getPronouns(slave); const r = []; @@ -24,25 +24,25 @@ App.Medicine.Surgery.Reactions.Shoulders = class extends App.Medicine.Surgery.Si App.Medicine.Surgery.Procedures.BroadenShoulders = class extends App.Medicine.Surgery.Procedure { - get name() { return this.slave.shouldersImplant === 0 ? "Restructure shoulders more broadly" : "Advanced shoulder broadening surgery"; } + get name() { return this._slave.shouldersImplant === 0 ? "Restructure shoulders more broadly" : "Advanced shoulder broadening surgery"; } get healthCost() { return 40; } apply(cheat) { - this.slave.shouldersImplant++; - this.slave.shoulders++; - return new App.Medicine.Surgery.Reactions.Shoulders(); + this._slave.shouldersImplant++; + this._slave.shoulders++; + return this._assemble(new App.Medicine.Surgery.Reactions.Shoulders()); } }; App.Medicine.Surgery.Procedures.NarrowShoulders = class extends App.Medicine.Surgery.Procedure { - get name() { return this.slave.shouldersImplant === 0 ? "Restructure shoulders more narrowly" : "Advanced shoulder narrowing surgery"; } + get name() { return this._slave.shouldersImplant === 0 ? "Restructure shoulders more narrowly" : "Advanced shoulder narrowing surgery"; } get healthCost() { return 40; } apply(cheat) { - this.slave.shouldersImplant--; - this.slave.shoulders--; - return new App.Medicine.Surgery.Reactions.Shoulders(); + this._slave.shouldersImplant--; + this._slave.shoulders--; + return this._assemble(new App.Medicine.Surgery.Reactions.Shoulders()); } }; diff --git a/src/js/utilsSlave.js b/src/js/utilsSlave.js index 05f7401ddcc..8740161a1e0 100644 --- a/src/js/utilsSlave.js +++ b/src/js/utilsSlave.js @@ -3009,7 +3009,11 @@ globalThis.parentNames = function(parent, child) { globalThis.faceIncrease = function(slave, amount) { const oldFace = slave.face; faceIncreaseAction(slave, amount); - return faceIncreaseDesc(slave, oldFace); + const newFace = slave.face; + slave.face = oldFace; + const desc = faceIncreaseDesc(slave, newFace); + slave.face = newFace; + return desc; }; /** @@ -3024,28 +3028,28 @@ globalThis.faceIncreaseAction = function(slave, amount) { }; /** - * Describes the slave face changes AFTER they were applied to the slave + * Describes the slave face changes BEFORE they are applied to the slave * * @param {App.Entity.SlaveState} slave - * @param {number} oldFace + * @param {number} newFace * @returns {string} */ -globalThis.faceIncreaseDesc = function(slave, oldFace) { +globalThis.faceIncreaseDesc = function(slave, newFace) { const pronouns = getPronouns(slave); const his = pronouns.possessive; const His = capFirstChar(his); let r = ""; - if (oldFace <= -95) { + if (slave.face <= -95) { r += `<span class="green">${His} face is no longer horrifying,</span> and is now merely ugly.`; - } else if (oldFace <= -40 && slave.face > -40) { + } else if (slave.face <= -40 && newFace > -40) { r += `<span class="green">${His} face is no longer ugly,</span> and is now merely unattractive.`; - } else if (oldFace <= -10 && slave.face > -10) { + } else if (slave.face <= -10 && newFace > -10) { r += `<span class="green">${His} face is no longer unattractive,</span> and is now somewhat tolerable.`; - } else if (oldFace <= 10 && slave.face > 10) { + } else if (slave.face <= 10 && newFace > 10) { r += `<span class="green">${His} face is now decently attractive,</span> rather than merely tolerable.`; - } else if (oldFace <= 40 && slave.face > 40) { + } else if (slave.face <= 40 && newFace > 40) { r += `<span class="green">${His} face is now quite beautiful,</span> rather than merely pretty.`; - } else if (oldFace <= 95 && slave.face > 95) { + } else if (slave.face <= 95 && newFace > 95) { r += `<span class="green">${His} face is now perfect.</span> It's difficult to imagine how it could be any more beautiful.`; } return r; diff --git a/src/npc/surgery/surgery.js b/src/npc/surgery/surgery.js index 28a08180ed0..4e997fe5ce4 100644 --- a/src/npc/surgery/surgery.js +++ b/src/npc/surgery/surgery.js @@ -128,7 +128,7 @@ App.Medicine.Surgery.makeObjectLink = function(passage, surgery, slave, cheat = * @param {boolean} cheat */ App.Medicine.Surgery.makeLink = function(procedure, refresh, cheat) { - const slave = procedure.slave; + const slave = procedure.originalSlave; return App.UI.DOM.link(procedure.name, apply, [], "", tooltip()); function healthCosts() { @@ -167,20 +167,32 @@ App.Medicine.Surgery.makeLink = function(procedure, refresh, cheat) { } } - const reaction = procedure.apply(cheat); - showSlaveReaction(reaction); + const [diff, reaction] = procedure.apply(cheat); + const f = makeSlaveReaction(diff, reaction); + + App.Utils.Diff.applyDiff(slave, diff); + + // Refresh the surgery options or wherever the surgery originated + refresh(); + + // Finally show the slaves reaction + Dialog.setup(procedure.name); + Dialog.append(f); + Dialog.open(); } /** + * @param {Partial<App.Entity.SlaveState>} diff * @param {App.Medicine.Surgery.SimpleReaction} reaction + * @returns {DocumentFragment} */ - function showSlaveReaction(reaction) { + function makeSlaveReaction(diff, reaction) { const f = new DocumentFragment(); let r = []; - r.push(...reaction.intro(slave)); + r.push(...reaction.intro(slave, diff)); - const resultMain = reaction.reaction(slave); + const resultMain = reaction.reaction(slave, diff); for (const p of resultMain.longReaction) { r.push(...p); App.Events.addParagraph(f, r); @@ -189,7 +201,7 @@ App.Medicine.Surgery.makeLink = function(procedure, refresh, cheat) { slave.devotion += resultMain.devotion; slave.trust += resultMain.trust; - const resultOutro = reaction.outro(slave, resultMain); + const resultOutro = reaction.outro(slave, diff, resultMain); for (const p of resultOutro.longReaction) { r.push(...p); App.Events.addParagraph(f, r); @@ -204,13 +216,7 @@ App.Medicine.Surgery.makeLink = function(procedure, refresh, cheat) { removeJob(slave, slave.assignment); } - // Refresh the surgery options or wherever the surgery originated - refresh(); - - // Finally show the slaves reaction - Dialog.setup(procedure.name); - Dialog.append(f); - Dialog.open(); + return f; } }; diff --git a/src/npc/surgery/surgeryDegradation.js b/src/npc/surgery/surgeryDegradation.js index 8faca667bca..a7983a8dd3e 100644 --- a/src/npc/surgery/surgeryDegradation.js +++ b/src/npc/surgery/surgeryDegradation.js @@ -49,9 +49,9 @@ App.UI.SlaveInteract.surgeryDegradation = function(slave) { removeJob(slave, slave.assignment); } - r.push(...reaction.intro(slave)); + r.push(...reaction.intro(slave, {})); - const resultMain = reaction.reaction(slave); + const resultMain = reaction.reaction(slave, {}); for (const p of resultMain.longReaction) { r.push(...p); App.Events.addParagraph(el, r); @@ -60,7 +60,7 @@ App.UI.SlaveInteract.surgeryDegradation = function(slave) { slave.devotion += resultMain.devotion; slave.trust += resultMain.trust; - const resultOutro = reaction.outro(slave, resultMain); + const resultOutro = reaction.outro(slave, {}, resultMain); for (const p of resultOutro.longReaction) { r.push(...p); App.Events.addParagraph(el, r); -- GitLab