code:
App.Medicine.Surgery.Reactions.NewEars = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {he, his} = 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 the bandages around ${his} ears are removed, ${he}`);
		if (slave.fetish === "mindbroken") {
			r.push(`returns to ${his} normal activities, none the wiser.`);
		} else {
			r.push(`initially believes nothing has changed, but soon discovers ${his} hearing is no longer technologically enhanced.`);
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.OFNewEars = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Replace";
	}

	get description() {
		return "remove cochlear implants before implanting organic cochleae";
	}

	get healthCost() {
		return 20;
	}

	apply(cheat) {
		this._slave.hears = 0;
		this._slave.earImplant = 0;
		return this._assemble(new App.Medicine.Surgery.Reactions.NewEars());
	}
};


code:
App.Medicine.Surgery.Reactions.Undeafen = class extends App.Medicine.Surgery.SimpleReaction {
	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 invasive 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.`);
		if (this._hasEmotion(slave)) {
			if (slave.devotion > 50) {
				r.push(`${He} loved you before, but ${he}'s very grateful, and more trusting, too. ${He} never realized just how nice your voice was, and now ${he} can't get your words out of ${his} mind.`);
				if (slave.relationship === 0) {
					slave.relationship = -2;
				}
			} else if (slave.devotion > 20) {
				r.push(`${He} accepted you as ${his} owner before, but ${he}'s <span class="devotion inc">very grateful,</span> and <span class="trust inc">more trusting,</span> too.`);
			} else {
				r.push(`${He} hardly knows what to make of this wonderful present from someone ${he} hates, and struggles with suspicion that the gift conceals some sort of snare. After a while, though, ${he} accepts that you truly did help ${him}, and might be trustworthy.`);
			}
			reaction.devotion += 25;
			reaction.trust += 25;
		}
		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.OFUndeafen = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Implant";
	}

	get healthCost() {
		return 20;
	}

	apply(cheat) {
		this._slave.hears = 0;
		return this._assemble(new App.Medicine.Surgery.Reactions.Undeafen());
	}
};

repo_name: Banyanael/fc

license: mit


code:
App.Medicine.Surgery.Reactions.Race = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him, himself} = getPronouns(slave);
		const r = [];

		if (slave.fetish === "mindbroken") {
			if (canSee(slave)) {
				r.push(`${He} pauses when ${he} sees the changes to ${his} body, unable to comprehend them.`);
			} else {
				r.push(`${He} can't discern the changes to ${his} race and likely never will.`);
			}
			r.push(`As with all invasive surgery <span class="health dec">${his} health has been affected.</span>`);
		} else if (slave.devotion > 50) {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`examines ${his} new self in the mirror`);
			} else if (canHear(slave)) {
				r.push(`listens to the description of ${his} new self`);
			} else {
				r.push(`gets a feel for the changes to ${his} body`);
			}
			r.push(`with approval.`);
			if (slave.race === slave.origRace) {
				r.push(`${He} recognizes ${himself} as ${he} was, and`);
			} else {
				r.push(`${He} doesn't recognize ${himself} quite yet, but`);
			}
			r.push(`${he} hopes you'll like ${his} new appearance better and use ${him} more frequently as a result. ${He}'s happy with your changes to ${his} racial appearance. As with all invasive surgery ${his} health has been affected.`);
			reaction.devotion += 4;
		} else if (slave.devotion >= -20) {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`examines ${his} new self in the mirror`);
			} else if (canHear(slave)) {
				r.push(`listens to the description of ${his} new self`);
			} else {
				r.push(`gets a feel for the changes to ${his} body`);
			}
			r.push(`with hesitation.`);
			if (slave.race === slave.origRace) {
				r.push(`${He} recognizes ${himself} as ${he} was, and`);
			} else {
				r.push(`${He} doesn't recognize ${himself} quite yet, but`);
			}
			r.push(`${he} hopes you'll like ${his} new appearance better and treat ${him} more kindly as a result. As with all invasive surgery ${his} health has been affected. ${He} is sensibly fearful of your total power over ${his} body.`);
			reaction.trust -= 5;
		} else {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`examines ${his} new self in the mirror`);
			} else if (canHear(slave)) {
				r.push(`listens to the description of ${his} new self`);
			} else {
				r.push(`gets a feel for the changes to ${his} body`);
			}
			r.push(`with revulsion.`);
			if (slave.race === slave.origRace) {
				r.push(`${He} recognizes ${himself} as ${he} was, which ${he} loves, and`);
			} else {
				r.push(`${He} doesn't recognize ${himself} quite yet, which ${he} hates, though`);
			}
			r.push(`${he} hopes you'll like ${his} new appearance better and punish ${him} less cruelly as a result. For now, <span class="devotion dec">${he} seems to view this`);
			if (slave.race !== slave.origRace) {
				r.push(`fake`);
			}
			r.push(`racial appearance as a cruel imposition. As with all invasive surgery ${his} health has been affected. ${He} is terribly afraid of your total power over ${his} body.`);
			reaction.trust -= 10;
			reaction.devotion -= 5;
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.Race = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {FC.Race} race
	 */
	constructor(slave, race) {
		super(slave);
		this.race = race;
	}

	get name() {
		return App.Data.misc.filterRaces.get(this.race);
	}

	get healthCost() {
		return 20;
	}

	apply(cheat) {
		this._slave.race = this.race;
		this._slave.skin = randomRaceSkin(this.race);
		this._slave.hColor = randomRaceHair(this.race);
		setEyeColor(this._slave, randomRaceEye(this.race));
		return this._assemble(new App.Medicine.Surgery.Reactions.Race());
	}
};


code:
App.Medicine.Surgery.Reactions.RetrogradeVirusInjectionNCS = class extends App.Medicine.Surgery.SimpleReaction {
	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 = [];
		const physicalChanges = [];
		const statusChanges = [];

		let hairChanges = 0;
		let hair = '';
		let sense;
		let r = [];

		r.push(`The procedure spans the week, with ${him} spending every other day in the surgery room for a series of 4 sets of injections. A few hours after each session, ${he} feels terribly ill. ${He} doesn't quite understand what it's about, just that ${he} feels pretty bad. The process involves`);
		if (V.PC.skill.medicine >= 100) {
			r.push(`you`);
		} else {
			r.push(`the remote surgeon`);
		}
		r.push(`injecting the serum across ${his} body entire body, every few`);
		if (V.showInches === 2) {
			r.push(`inches,`);
		} else {
			r.push(`centimeters,`);
		}
		r.push(`leaving small needle marks that fade out within minutes. Despite not leaving a lasting evidence, the process is very invasive work, and leaves ${him} feeling weak and tired.`);
		reaction.longReaction.push(r);
		r = [];

		// Generate the changes, into variables to set contexts.
		const hairLand = hasBothLegs(slave) ? `at ${his} feet` : `below ${him}`;
		if (slave.physicalAge > pubertyAge - 2) {
			if (slave.underArmHStyle !== "hairless" && slave.underArmHStyle !== "bald") {
				hairChanges++;
				slave.underArmHStyle = "bald";
				hair = `The first thing ${he} notices is that ${his} armpit hair has just fallen out, in a small pile ${hairLand}.`;
				if (slave.pubicHStyle !== "hairless" && slave.pubicHStyle !== "bald") {
					hairChanges++;
					slave.pubicHStyle = "bald";
					hair = `${hair} The same thing happens to ${his} pubic hair.`;
				}
			} else if (slave.pubicHStyle !== "hairless" && slave.pubicHStyle !== "bald") {
				hairChanges++;
				slave.pubicHStyle = "bald";
				hair = `The first thing ${he} notices is that ${his} pubic hair has just fallen out, in a small pile ${hairLand}.`;
			}
		}
		if (canSee(slave)) {
			sense = "see";
			r.push(`${He} inspects ${himself} in the mirror.`);
		} else if (!hasAnyArms(slave)) {
			sense = "feel";
			r.push(`${He} examines ${himself} with ${his} own ${hasBothArms(slave) ? "hands" : "hand"}.`);
		} else if (canHear(slave)) {
			sense = "hear";
			r.push(`${He} listens as a menial slave describes ${his} new looks.`);
		} else {
			sense = "sense";
			r.push(`${He} can vaguely feel the changes to ${his} body, even in ${his} current state.`);
		}
		if (slave.dick > 2) {
			genitalChanges.push('dick');
			slave.dick -= 1;
		}
		if (slave.balls > 2) {
			genitalChanges.push('balls');
			slave.balls -= 1;
		}
		if (slave.geneMods.rapidCellGrowth !== 1) {
			if (slave.scrotum > 1) {
				genitalChanges.push('scrotum');
				slave.scrotum -= 1;
			}
		}
		if (slave.clit > 1) {
			genitalChanges.push('clit');
			slave.clit -= 1;
		}
		if (slave.labia > 1) {
			genitalChanges.push('labia');
			slave.labia -= 1;
		}
		if (slave.boobs - slave.boobsImplant - slave.boobsMilk > 300) {
			genitalChanges.push('boobs');
			slave.boobs -= Math.round(slave.boobs * .1);
		}
		if ((slave.shoulders - Math.abs(slave.shouldersImplant) > -1) && (slave.hips - Math.abs(slave.hipsImplant) > -1)) {
			physicalChanges.push(`both ${his} hips and shoulders are <span class="change negative">less wide,</span>`);
			slave.hips -= 1;
			slave.shoulders -= 1;
		} else if (slave.shoulders - Math.abs(slave.shouldersImplant) > -1) {
			physicalChanges.push(`${his} shoulders are <span class="change negative">less wide,</span>`);
			slave.shoulders -= 1;
		} else if (slave.hips - Math.abs(slave.hipsImplant) > -1) {
			physicalChanges.push(`${his} hips are <span class="change negative">less wide,</span>`);
			slave.hips -= 1;
		}
		if (slave.visualAge < 18) {
			const averageHeight = Height.mean(slave);
			const heightDelta = slave.height - averageHeight;
			let shrinkage;
			if (slave.height > 126 || heightDelta > 0) {
				if (heightDelta > 15) {
					shrinkage = 5;
				} else if (heightDelta > 5) {
					shrinkage = 4;
				} else if (heightDelta > -5) {
					shrinkage = 3;
				} else if (heightDelta > -15) {
					shrinkage = 2;
				} else {
					shrinkage = 1;
				}
				physicalChanges.push(`${he} is a little <span class="change negative">shorter,</span>`);
				slave.height -= shrinkage;
			}
		}
		if (slave.visualAge > 18) {
			statusChanges.push(`${He} feels a little <span class="change negative">younger.</span>`);
			slave.visualAge -= 1;
		}
		if (slave.voice.isBetween(0, 3)) {
			let voiceReaction = [`${He} hears ${his} voice coming out as <span class="change negative">higher</span> and more ${slave.voice < 2 ? "feminine" : "girly"} than it was before.`];
			if (slave.devotion > 20) {
				voiceReaction.push(`${He} laughs at ${his} new voice happily as ${he} gets used to it.`);
			} else if (slave.devotion >= -20) {
				voiceReaction.push(`${He} laughs grimly at ${himself} as ${he} gets used to it.`);
			} else {
				voiceReaction.push(`It comes out far higher than it was before, ${he} feels this new voice does not belong to ${him}.`);
			}
			statusChanges.push(voiceReaction.join(" "));
			slave.voice += 1;
		}
		// Handle the display of the changes for the newly NCS'ed slave.
		const numberChanges = hairChanges + statusChanges.length + physicalChanges.length + genitalChanges.length;
		if (numberChanges <= 0) {
			r.push(`Despite the long and arduous treatment, ${he} has no idea what all of it was for. ${He} stands before you`);
			if (slave.devotion > 20) {
				r.push(`eager to learn what it's all about.`);
			} else if (slave.devotion >= -20) {
				r.push(`worried to discover what's happened to ${him}.`);
			} else {
				r.push(`anxious about what you did to ${him}, dreading the news.`);
			}
		} else {
			r.push(`Over the course of the treatment, ${he} begins to feel the initial effects and on inspection, when ${he}`);
			if (!hasAnyLegs(slave)) {
				r.push(`is carried`);
			} else if (canWalk(slave)) {
				r.push(`walks`);
			} else {
				r.push(`is escorted`);
			}
			r.push(`out of the surgery room, ${he} feels somehow smaller and changed in`);
			if (numberChanges === 1) {
				r.push(`at least one way.`);
			} else if (numberChanges === 2) {
				r.push(`two ways.`);
			} else {
				r.push(`several ways.`);
			}
			reaction.longReaction.push(r);
			r = [];
			if (hair !== '') {
				r.push(hair);
			}
			if (genitalChanges.length > 0) {
				r.push(`${He} can ${sense} that ${his} junk is different now, it seems ${his}`);
				if (genitalChanges.length > 2) {
					for (let i = 0; i < genitalChanges.length; i++) {
						if (i < genitalChanges.length - 1) {
							r.push(`${genitalChanges[i]},`);
						} else {
							r.push(`and ${genitalChanges[i]}.`);
						}
					}
					r.push(`have all become <span class="change negative">smaller.</span>`);
				} else if (genitalChanges.length > 1) {
					r.push(`${genitalChanges[0]}, and ${genitalChanges[1]} have both become <span class="change negative">smaller.</span>`);
				} else {
					r.push(`${genitalChanges[0]} has become <span class="change negative">smaller.</span>`);
				}
			}
			if (physicalChanges.length > 0) {
				r.push(`${He} can`);
				if (genitalChanges.length > 0 || hairChanges > 0) {
					r.push(`also`);
				}
				r.push(`${sense} that ${his} body has some physical changes, it seems to ${him} that ${toSentence(physicalChanges)}`);
				const reaction = ['comes as a bit of a surprise', 'comes as quite a shock', `confirms ${his} suspicions`, `doesn't seem to phase ${him}`, `${he} finds interesting`, `${he} can't get over`].random() + '.';
				r.push(`which ${reaction}`);
			}
			if (statusChanges.length > 0) {
				r.push(`${He} can feel some`);
				if (genitalChanges.length > 0 || physicalChanges.length > 0 || hairChanges > 0) {
					r.push(`other`);
				}
				r.push(`changes that are a little harder to describe.`);
				for (let i = 0; i < statusChanges.length; i++) {
					r.push(statusChanges[i]);
				}
			}
		}

		reaction.longReaction.push(r);
		r = [];
		r.push(`You explain that ${he}'s never going to grow older and ${he}'ll stay younger. You sit back and let ${him} absorb that data for a moment.`);
		reaction.longReaction.push(r);
		r = [];
		if (slave.fetish === "mindbroken") {
			r.push(`${He} doesn't seem to comprehend what this means for ${him}.`);
		} else if (slave.devotion > 20) {
			r.push(`${He} is <span class="devotion inc">happy</span> with how young ${his} body has become${(slave.visualAge > 26) ? ` and is excited about the process continuing` : ``}. ${He} is already wondering what new kinky things you have planned for ${him}.`);
			reaction.trust += 5;
			reaction.devotion += 5;
			if (slave.visualAge > 26) {
				reaction.devotion += 5;
			}
		} else if (slave.devotion >= -20) {
			r.push(`${He} isn't thrilled with ${his} new younger body, but it doesn't bother ${him} much, since ${he} knows it just better secures ${his} position in your arcology.`);
			if (slave.visualAge > 26) {
				r.push(`${He} does feel a little extra <span class="trust inc">trust</span> that you would spend so much on an older slave like ${him}.`);
				reaction.trust += 5;
			}
		} else {
			r.push(`${He} is <span class="devotion dec">sad</span> and <span class="trust dec">frightened</span> that you would force this curse of non-aging on ${him}.`);
			reaction.trust -= 5;
			reaction.devotion -= 5;
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.RetrogradeVirusInjectionNCS = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Induced NCS treatment";
	}

	get description() {
		const {his} = getPronouns(this.originalSlave);
		return `This will induce NCS in ${his} genetic code`;
	}

	get healthCost() {
		return 80;
	}

	get _workCost() {
		return super._workCost * 4;
	}

	apply(cheat) {
		this._slave.geneMods.NCS = 1;
		this._slave.chem += 40;
		return this._assemble(new App.Medicine.Surgery.Reactions.RetrogradeVirusInjectionNCS());
	}
};


code:
App.Medicine.Surgery.Reactions.GeneTreatment = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him} = getPronouns(slave);
		const r = [];

		r.push(`The procedure spans the week, with ${him} spending every other day in the surgery room for a series of 4 sets of injections. A few hours after each session, ${he} feels terribly ill. ${He} doesn't quite understand what it's about, just that ${he} feels pretty bad. The process involves`);
		if (V.PC.skill.medicine >= 100) {
			r.push(`you`);
		} else {
			r.push(`the remote surgeon`);
		}
		r.push(`injecting the serum across ${his} entire body, every few`);
		if (V.showInches === 2) {
			r.push(`inches,`);
		} else {
			r.push(`centimeters,`);
		}
		r.push(`leaving small needle marks that fade out within minutes. Despite not leaving a lasting evidence, the process is very invasive work, and leaves ${him} feeling weak and tired.`);

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.ElasticityTreatment = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Increased elasticity treatment";
	}

	get description() {
		const {his} = getPronouns(this.originalSlave);
		return `this will alter ${his} genetic code to encourage ${his} body to stretch`;
	}

	get _workCost() {
		return super._workCost * 4;
	}

	get healthCost() {
		return 40;
	}

	apply(cheat) {
		this._slave.geneMods.rapidCellGrowth = 1;
		this._slave.chem += 100;
		return this._assemble(new App.Medicine.Surgery.Reactions.GeneTreatment());
	}
};

App.Medicine.Surgery.Procedures.ImmortalityTreatment = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Immortality";
	}

	get description() {
		const {his} = getPronouns(this.originalSlave);
		return `this will alter ${his} genetic code to reverse and prevent aging, effectively thwarting the rigors of old age`;
	}

	get _workCost() {
		return super._workCost * 4;
	}

	get healthCost() {
		return 40;
	}

	get note() {
		return App.UI.DOM.makeElement("span", `Post operation, high levels of DNA toxicity may be identified within the patient. Placement within a modern and staffed Clinic is highly recommended.`, ["warning"]);
	}

	apply(cheat) {
		this._slave.geneMods.immortality = 1;
		this._slave.chem += 1000;
		if (V.clinic) {
			assignJob(this.originalSlave, Job.CLINIC);
		}
		return this._assemble(new App.Medicine.Surgery.Reactions.GeneTreatment());
	}
};

App.Medicine.Surgery.Procedures.milkFlavoring = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Bio-engineered milk flavoring";
	}

	get description() {
		const {his} = getPronouns(this.originalSlave);
		return `This will alter ${his} genetics to allow flavored milk`;
	}

	get cost() {
		return super.cost * 1.5;
	}

	get healthCost() {
		return 15;
	}

	apply(cheat) {
		this._slave.milkFlavor = "natural";
		this._slave.chem += 100;
		return this._assemble(new App.Medicine.Surgery.Reactions.GeneTreatment());
	}
};

App.Medicine.Surgery.Procedures.RemoveGene = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {string} gene
	 * @param {string} title
	 */
	constructor(slave, gene, title) {
		super(slave);
		this.gene = gene;
		this.title = title;
	}

	get name() {
		return this.title;
	}

	get description() {
		return `Applying a retro-virus treatment radically increases carcinogen buildup`;
	}

	get _workCost() {
		return super._workCost * 4;
	}

	get healthCost() {
		return 40;
	}

	apply(cheat) {
		if (this.gene === "albinism") {
			induceAlbinism(this._slave, 0);
		} else {
			this._slave.geneticQuirks[this.gene] = 0;
		}
		this._slave.chem += 100;
		return this._assemble(new App.Medicine.Surgery.Reactions.GeneTreatment());
	}
};

App.Medicine.Surgery.Procedures.AddGene = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {string} gene
	 * @param {boolean} [activation=false] Activation or inducement
	 */
	constructor(slave, gene, activation = false) {
		super(slave);
		this.gene = gene;
		this.activation = activation;
		this.geneData = App.Data.geneticQuirks.get(gene);
	}

	get name() {
		if (this.activation) {
			return `${capFirstChar(this.geneData.title)} activation treatment`;
		} else {
			return `Induced ${this.geneData.title} treatment`;
		}
	}

	get description() {
		const r = [];
		if (!this.activation) {
			const {his} = getPronouns(this.originalSlave);
			r.push(`This will induce ${this.geneData.title} in ${his} genetic code.`);
		}
		r.push(`Applying a retro-virus treatment radically increases carcinogen buildup`);
		return r.join(" ");
	}

	get _workCost() {
		return super._workCost * (this.activation ? 4 : 10);
	}

	get healthCost() {
		return 40;
	}

	apply(cheat) {
		if (this.gene === "albinism") {
			induceAlbinism(this._slave, 2);
		} else {
			this._slave.geneticQuirks[this.gene] = 2;
		}
		this._slave.chem += 100;
		return this._assemble(new App.Medicine.Surgery.Reactions.GeneTreatment());
	}
};


code:
App.Medicine.Surgery.Reactions.Fuckdoll = class extends App.Medicine.Surgery.SimpleReaction {
	get removeJob() {
		return true;
	}

	intro(slave) {
		const r = [];
		r.push(`As the remote surgery's long recovery cycle completes, your new Fuckdoll`);
		if (hasAnyLegs(slave)) {
			r.push(`stumbles`);
		} else {
			r.push(`is carried`);
		}
		r.push(`out of the surgery room. The only`);
		if (slave.vagina > -1) {
			r.push(`areas of skin visible are those around its vulva and anus`);
		} else {
			r.push(`area of skin visible is that around its anus${(slave.lips > 95) ? `, though its lips are also visible as its facepussy makes the standard Fuckdoll mouth insert unnecessary` : ``}. You can see it starting to struggle against the constricting material of the Fuckdoll suit as the sedation wears off. Other than the tiny area of exposed skin and the slight movement, there's no indication that the sex doll in front of you is alive at all.`);
		}
		return r;
	}

	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 = [];

		let relatedCount = 0;
		for (const relation of relations) {
			const {he2, his2} = getPronouns(relation).appendSuffix("2");
			if (isParentP(slave, relation) || isParentP(relation, slave)) {
				r.push(`${relation.slaveName} will be horrified and afraid when ${he2} finds out that ${his2} ${relativeTerm(relation, slave)} is now a Fuckdoll.`);
				relation.devotion -= 40;
				relation.trust -= 40;
				relatedCount++;
			}
			switch (areSisters(slave, relation)) {
				case 1:
					r.push(`${relation.slaveName} will be <span class="devotion dec">horrified</span> and <span class="trust dec">afraid</span> when ${he2} finds out that ${his2} twin is now a Fuckdoll. Is ${he2} next?`);
					relation.devotion -= 50;
					relation.trust -= 50;
					relatedCount++;
					break;
				case 2:
					r.push(`${relation.slaveName} will be <span class="devotion dec">horrified</span> and <span class="trust dec">afraid</span> when ${he2} finds out that ${his2} ${sister} is now a Fuckdoll.`);
					relation.devotion -= 40;
					relation.trust -= 40;
					relatedCount++;
					break;
				case 3:
					r.push(`${relation.slaveName} will be <span class="devotion dec">horrified</span> and <span class="trust dec">afraid</span> when ${he2} finds out that ${his2} half-${sister} is now a Fuckdoll.`);
					relation.devotion -= 30;
					relation.trust -= 30;
					relatedCount++;
			}
		}
		if (relatedCount > 0) {
			reaction.shortReaction.push(`${His} ${relatedCount > 0 ? "relatives" : "relative"} will be <span class="devotion dec">horrified</span> and <span class="trust dec">afraid</span> when they find out about ${his} fate.`);
		}
		if (slave.relationship > 0) {
			const rel = getSlave(slave.relationshipTarget);
			if (rel) {
				const {he2, his2} = getPronouns(rel).appendSuffix("2");
				const relTerm = relativeTerm(rel, slave);
				r.push(`${rel.slaveName} will be <span class="devotion dec">horrified</span> and <span class="trust dec">afraid</span> when ${he2} finds out that ${his2}`);
				if (relTerm !== null) {
					r.push(`${relTerm} and`);
				}
				let name;
				if (slave.relationship > 4) {
					name = wife;
				} else if (slave.relationship > 3) {
					name = `lover`;
				} else if (slave.relationship > 2) {
					name = `intimate friend`;
				} else if (slave.relationship > 1) {
					name = `best friend`;
				} else {
					name = `friend`;
				}
				r.push(`${name} is now a Fuckdoll.`);
				reaction.shortReaction.push(`${His} ${name} will be <span class="devotion dec">horrified</span> and <span class="trust dec">afraid</span> when they find out about ${his} fate.`);
				rel.devotion -= slave.relationship * 10;
				rel.trust -= slave.relationship * 10;
				rel.relationship = 0;
				rel.relationshipTarget = 0;
			}
		} else if (slave.relationship < 0) {
			r.push(`${His} slave relationship to you is effectively over, since everyone in the world outside ${his} suit is created equal to ${him}. ${He}'ll probably forget to distinguish your`);
			if (V.PC.dick !== 0) {
				r.push(`dick if it's pushed inside ${his}`);
			} else {
				r.push(`pussy if it's pressed against ${his} face hole`);
			}
			r.push(`soon enough.`);
		}
		if (slave.rivalry !== 0) {
			const rival = getSlave(slave.rivalryTarget);
			if (rival) {
				const {he2} = getPronouns(rival).appendSuffix("2");
				r.push(`Naturally, ${his} rivalry with ${rival.slaveName} is over. ${rival.slaveName} will be pleased ${he2} doesn't have to see ${slave.slaveName} any more, though being a Fuckdoll is terrifying enough that it's not likely ${he2}'ll derive much satisfaction from it.`);
				rival.rivalry = 0;
				rival.rivalryTarget = 0;
			}
		}
		slave.relationship = 0;
		slave.relationshipTarget = 0;
		slave.rivalry = 0;
		slave.rivalryTarget = 0;

		reaction.longReaction.push(r);
		r = [];
		r.push(`The Fuckdoll suit's systems connect to the arcology and run a full systems check. The reports waterfall down the nearest wallscreen, moving from the top of the Fuckdoll down. The simple brain activity sensor is showing elevated readings as ${slave.slaveName} desperately tries to find ${his} bearings.`);
		if (slave.hLength > 20) {
			r.push(`The twin tails of hair sticking out of the suit material that covers ${his} scalp are waving from side to side slightly as ${he} struggles.`);
		}
		if (getBestVision(slave) > 0) {
			r.push(`The suit does not have holes for vision, worsening the disorientation.`);
		}
		if (slave.voice === 0) {
			r.push(`${His} breath rushes in and`);
		} else {
			r.push(`Incoherent moans are coming`);
		}
		r.push(`out of ${his}`);
		if (slave.lips > 95) {
			r.push(`facepussy.`);
		} else {
			r.push(`mouth insert.`);
		}
		r.push(`The suit can stimulate every intimate area that it covers with vibration, electrostimulation, warmth, and cold, and ${slave.slaveName} must be in agony as it tests these systems.`);

		reaction.longReaction.push(r);
		r = [];

		r.push(`The suit includes a network of small tubes filled with hydraulic fluid, and tiny pumps to move it around. This is necessary to keep the Fuckdoll's internal temperature stable, but it can also be used to restrict ${his} movements. The suit is doing so now; the Fuckdoll is desperately attempting to move, but the suit won't let ${him}.`);
		if (hasAnyProstheticLimbs(slave)) {
			r.push(`Its P-Limbs have been removed, since they aren't compatible with Fuckdoll suits.`);
			removeLimbs(slave, "all");
		}
		if (isAmputee(slave)) {
			r.push(`The Fuckdoll's limbless torso rocks back and forth slightly.`);
		} else {
			if (hasBothLegs(slave)) {
				r.push(`${He}'s rocking back and forth slightly on ${his} heeled boots, which are designed for stability.`);
			} else if (hasAnyLegs(slave)) {
				r.push(`${He}'s rocking back and forth slightly on ${his} single heeled boot, which is designed for great stability.`);
			} else {
				r.push(`The Fuckdoll's legless torso rocks back and forth slightly.`);
			}
		}
		r.push(`The heart rate reading is so high that the Fuckdoll is receiving drugs to calm ${him} down and prevent damage; the suit can deliver these and any other necessary pharmaceuticals by intravenous shunt. Farther down, on the Fuckdoll's side over ${his} ribcage, there are a pair of metal ports. These allow ${him} to be fed.`);
		if (slave.belly > 1500) {
			r.push(`The suit does not cover ${his}`);
			if (slave.bellyPreg > 1500) {
				r.push(`pregnant`);
			} else {
				r.push(`rounded`);
			}
			r.push(`belly, which is allowed to protrude from a hole in the material.`);
		}

		reaction.longReaction.push(r);
		r = [];
		r.push(`The Fuckdoll's rear hole is extremely eye-catching from behind, since it's the only area of skin visible from that angle across ${his} body, which is a featureless expanse of dull latex-like material.`);
		if (slave.vagina > -1) {
			r.push(`From ${his} other side, ${his} front hole stands out likewise.`);
		}
		if (slave.dick > 0) {
			r.push(`${His} penis has its own pouch in the material.`);
		}
		r.push(`The Fuckdoll continues to struggle. Since ${he} is new, ${he} is not yet able to obey the tonal command system the suit uses to transfer orders to its inhabitant, who cannot otherwise hear. ${He} will have to learn by painful experience, and eventually, that is all ${he} will know.`);

		return reaction;
	}
};

App.Medicine.Surgery.Procedures.Fuckdoll = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Encase in a Fuckdoll suit";
	}

	get _workCost() {
		return 0;
	}

	apply(cheat) {
		beginFuckdoll(this._slave);
		SetBellySize(this._slave);
		return this._assemble(new App.Medicine.Surgery.Reactions.Fuckdoll());
	}
};


code:
App.Medicine.Surgery.Reactions.FuckdollExtraction = class extends App.Medicine.Surgery.SimpleReaction {
	intro(slave) {
		const r = [];
		r.push(`As the remote surgery's long recovery cycle completes, ${slave.slaveName}`);
		if (!hasAnyLegs(slave)) {
			r.push(`is carried`);
		} else if (canWalk(slave)) {
			r.push(`walks`);
		} else {
			r.push(`is escorted`);
		}
		r.push(`out of the surgery room.`);
		return r;
	}

	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.`);
		if (getBestVision(slave) > 0) {
			r.push(`You're denied any reaction from ${him} to the sight of ${himself} in the mirror outside the recovery area, as ${he}'s wearing a pair of very dark glasses ${he}'ll have to keep on for a few hours yet. ${He}'s been denied almost all vision for a long time, and though ${his} recovery included light therapy, ${he}'s still very sensitive to it.`);
		}
		if (slave.fetish === "mindbroken") {
			r.push(`${His} mind remains just as broken outside the suit as it was inside it. In many ways, ${he}'s as much of a living sex toy now as ${he} was when ${he} was a Fuckdoll; ${he}'s unresponsive to almost everything, though ${he} will probably still understand how to get fucked. ${His} personality is probably somewhere back there in the Fuckdoll maintenance areas, like the scraps of the suit that was just cut off ${him}. Just another piece of refuse.`);
		} else if (slave.fuckdoll > 20) {
			r.push(`Though ${he} retains possession of some of ${his} faculties, ${he}'s been severely affected by the weeks ${he}'s spent as a living sex toy. Any joy or relief at being liberated from the Fuckdoll suit is probably being suppressed by the similarity of the extraction procedure to the routine suit maintenance ${he} received weekly. If ${he} even understands that ${he}'s been freed, ${he}'s been trained so thoroughly that ${he} will struggle to adapt to life more complex than tonal commands and sexual use.`);
		} else {
			r.push(`Though ${he} hasn't been a Fuckdoll long enough to be permanently damaged, ${he}'s so emotionally exhausted by everything ${he}'s experienced over the past few weeks that ${he} betrays no relief or joy, or even any fear that ${he}'ll be turned into a Fuckdoll again. ${His} posture bespeaks something like apathy. ${He} should reawaken gradually, but for now ${he}'s still actively remembering how to live as a human, rather than as a living sex toy.`);
		}
		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.FuckdollExtraction = class extends App.Medicine.Surgery.Procedure {
	get name() {
		const {him} = getPronouns(this.originalSlave);
		return `Extract ${him}`;
	}

	get _workCost() {
		return 0;
	}

	apply(cheat) {
		this._slave.fuckdoll = 0;
		this._slave.clothes = "no clothing";
		this._slave.shoes = "none";
		return this._assemble(new App.Medicine.Surgery.Reactions.FuckdollExtraction());
	}
};


code:
App.Medicine.Surgery.Reactions.Mindbreak = class extends App.Medicine.Surgery.SimpleReaction {
	get removeJob() {
		return true;
	}

	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, His, his, him} = getPronouns(slave);
		const r = [];

		r.push(`${His} gaze is placid and empty.`);
		if (canSee(slave)) {
			r.push(`${He} looks at`);
		} else if (canHear(slave)) {
			r.push(`You cough, causing ${him} to turn to face`);
		} else {
			r.push(`${He} does not respond to your touch, so you turn ${his} head to face`);
		}
		r.push(`you, and there is nothing there: no recognition, no fear, no love. Nothing. <span class="mindbreak">${He} will forget this in a few hours. ${He} will forget everything in a few hours.</span>`);

		reaction.shortReaction.push(`${His} mind is broken, any defining characteristics <span class="mindbreak">are gone.</span>`);

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.Mindbreak = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Chemically lobotomize";
	}

	get description() {
		const {his} = getPronouns(this.originalSlave);
		return `Warning: this is permanent and irreversible. It will destroy ${his} will and ${his} ability to remember anything but the simplest skills.`;
	}

	get healthCost() {
		return 20;
	}

	apply(cheat) {
		applyMindbroken(this._slave);
		return this._assemble(new App.Medicine.Surgery.Reactions.Mindbreak());
	}
};


code:
App.Medicine.Surgery.Reactions.Blind = class extends App.Medicine.Surgery.SimpleReaction {
	get removeJob() { return true; }

	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 nothing more than minor health effects. 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.`);
		if (this._hasEmotion(slave)) {
			if (slave.devotion > 50) {
				r.push(`When ${he} finally figures it out, ${he} begins to weep, not understanding why it's necessary that ${he} be unable to see. After a short cry that trails off into a few sniffles, ${he} carries on.`);
			} else if (slave.devotion > 20) {
				r.push(`When ${he} finally figures it out, ${he} begins to bawl, not understanding what ${he} did to earn this. After a short expurgation of grief and terror, ${he} takes a deep breath and visibly suppresses ${his} emotions.`);
				reaction.trust -= 20;
			} else {
				r.push(`When ${he} realizes what's happened, ${his} face clouds with rage. Reflexively, ${he} begins to peer around, looking for the source of ${his} woes. ${He} finally understands the true use of blindness when ${he} realizes ${he} won't be able to tell where you are, where anyone is, or even where ${he} is. ${His} well being is now firmly in the hands of someone ${he} distrusts. ${He} begins to shake with fear.`);
				reaction.trust -= 8;
				reaction.devotion -= 8;
			}
		}
		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.Blind = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {FC.BodySideAll} side
	 */
	constructor(slave, side) {
		super(slave);
		this.side = side;
	}

	get name() { return `Blind ${this.side} ${this.side === "both" ? "eyes" : "eye"}`; }

	get healthCost() { return 5; }

	apply(cheat) {
		eyeSurgery(this._slave, this.side, "blind");
		return this._assemble(new App.Medicine.Surgery.Reactions.Blind());
	}
};


code:
App.Medicine.Surgery.Reactions.EyeBlur = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his} = getPronouns(slave);
		const r = [];

		r.push(`The laser eye surgery is brief, with nothing more than minor health effects. 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 blurred world is ${his} new reality.`);
		if (this._hasEmotion(slave)) {
			if (slave.devotion > 50) {
				r.push(`When ${he} finally figures it out, ${he} begins to weep, not understanding why it's necessary that ${he} not be able to see clearly. After a short cry that trails off into a few sniffles, ${he} carries on.`);
			} else if (slave.devotion > 20) {
				r.push(`When ${he} finally figures it out, ${he} begins to bawl, not understanding what ${he} did to earn this. After a short expurgation of grief and terror, ${he} takes a deep breath and visibly suppresses ${his} emotions.`);
				reaction.trust -= 5;
			} else {
				r.push(`When ${he} realizes what's happened, ${his} face clouds with rage. Reflexively, ${he} begins to peer around, looking for the source of ${his} woes. ${He} finally understands the true import of blurred vision when ${he} has trouble telling if anyone's close, and begins to shake with fear.`);
				reaction.trust -= 10;
				reaction.devotion -= 10;
			}
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.EyeBlur = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {FC.BodySideAll} side
	 */
	constructor(slave, side) {
		super(slave);
		this.side = side;
	}

	get name() { return `Blur ${this.side} ${this.side === "both" ? "eyes" : "eye"}`; }

	get healthCost() { return 5; }

	apply(cheat) {
		eyeSurgery(this._slave, this.side, "blur");
		return this._assemble(new App.Medicine.Surgery.Reactions.EyeBlur());
	}
};


code:
App.Medicine.Surgery.Reactions.EyeFix = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him} = getPronouns(slave);
		const r = [];

		r.push(`The laser eye surgery is brief, with nothing more than minor health effects. 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} newly clear vision. Seeing the world as it is without glasses or contact lenses is a gift that those who do not need it cannot properly understand.`);
		if (this._hasEmotion(slave)) {
			if (slave.devotion > 50) {
				r.push(`${He} loved you before, but ${he}'s <span class="devotion inc">very grateful,</span> and <span class="trust inc">more trusting,</span> too.`);
			} else if (slave.devotion >= -20) {
				r.push(`${He} accepted you as ${his} owner before, but ${he}'s <span class="devotion inc">very grateful,</span> and <span class="trust inc">more trusting,</span> too.`);
			} else {
				r.push(`${He} hardly knows what to make of this wonderful present from someone ${he} hates, and struggles with suspicion that the gift conceals some sort of snare. After a while, though, ${he} accepts that you truly did help ${him}, and might be trustworthy.`);
			}
			reaction.devotion += 5;
			reaction.trust += 5;
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.EyeFix = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {FC.BodySideAll} side
	 */
	constructor(slave, side) {
		super(slave);
		this.side = side;
	}

	get name() { return `Fix ${this.side} ${this.side === "both" ? "eyes" : "eye"}`; }

	get healthCost() { return 5; }

	apply(cheat) {
		eyeSurgery(this._slave, this.side, "fix");
		return this._assemble(new App.Medicine.Surgery.Reactions.EyeFix());
	}
};


code:
App.Medicine.Surgery.Reactions.NewEyes = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {he, his, him} = getPronouns(slave);
		const r = [];

		r.push(`The implant surgery is invasive and ${he} spends some time in the autosurgery recovering. As soon as ${he} is allowed to open ${his} eyes and look around, ${he} notices nothing has changed; though the next time ${he} looks in the mirror, ${he}'ll see a pair of familiar ${App.Desc.eyesColor(slave)} peering back at ${him}.`);

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.OFNewEyes = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {"left"|"right"} side
	 */
	constructor(slave, side) {
		super(slave);
		this._side = side;
	}

	get name() {
		return getLeftEyeType(this.originalSlave) === 2 ? "Replace" : "Implant";
	}

	get description() {
		return getLeftEyeType(this.originalSlave) === 2 ? "replace the existing ocular implant with an organic eye" : "";
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		eyeSurgery(this._slave, this._side, "normal");
		return this._assemble(new App.Medicine.Surgery.Reactions.NewEyes());
	}
};


code:
App.Medicine.Surgery.Reactions.OcularImplant = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him} = getPronouns(slave);
		const r = [];

		r.push(`The implant surgery is invasive and ${he} spends some time in the autosurgery recovering. When ${he} is allowed to open ${his} eyes the amount of visual information makes ${him} reel.`);
		if (this._hasEmotion(slave)) {
			if (slave.devotion > 50) {
				r.push(`${He} is <span class="devotion inc">grateful</span> for ${his} improved vision, and knowing how much you invested in ${him} makes ${him} <span class="trust inc">trust you more</span> as well.`);
				reaction.devotion += 10;
				reaction.trust += 10;
			} else if (slave.devotion > 20) {
				r.push(`${He} has mixed feelings about ${his} new eyes, but ${he}'s aware how valuable such implants are, and ${he} already accepted that you have complete control over ${his} body.`);
				reaction.devotion += 5;
				reaction.trust += 10;
			} else {
				r.push(`${He} is <span class="trust dec">disturbed</span> that you replaced ${his} eyes with artificial ones and afraid of increased control over ${him} that such device grants.`);
				reaction.devotion -= 5; // TODO: text says trust, but devotion changed?
			}
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Reactions.OcularImplantForBlind = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him} = getPronouns(slave);
		const r = [];
		r.push(`The implant surgery is invasive 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.`);
		if (this._hasEmotion(slave)) {
			if (slave.devotion > 50) {
				r.push(`${He} loved you before, but ${he}'s very grateful, and more trusting, too. ${He} never realized just how good you looked, and now ${he} can't get your image out of ${his} mind.`);
				if (slave.relationship === 0) {
					slave.relationship = -2;
				}
			} else if (slave.devotion > 20) {
				r.push(`${He} accepted you as ${his} owner before, but ${he}'s <span class="devotion inc">very grateful,</span> and <span class="trust inc">more trusting,</span> too.`);
			} else {
				r.push(`${He} hardly knows what to make of this wonderful present from someone ${he} hates, and struggles with suspicion that the gift conceals some sort of snare. After a while, though, ${he} accepts that you truly did help ${him}, and might be trustworthy.`);
			}
			reaction.devotion += 25;
			reaction.trust += 25;
		}
		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.OcularImplant = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {FC.BodySideAll}side
	 */
	constructor(slave, side) {
		super(slave);
		this.side = side;
	}

	get name() {
		if (this.side === "both") {
			return "Give both eyes ocular implants";
		}
		return `Give ${this.side} eye ocular implant`;
	}

	get healthCost() {
		return 5;
	}

	apply(cheat) {
		eyeSurgery(this._slave, this.side, "cybernetic");
		if (getBestVision(this.originalSlave) > 0) {
			return this._assemble(new App.Medicine.Surgery.Reactions.OcularImplant());
		} else {
			return this._assemble(new App.Medicine.Surgery.Reactions.OcularImplantForBlind());
		}
	}
};


code:
App.Medicine.Surgery.Reactions.RemoveEyes = class extends App.Medicine.Surgery.SimpleReaction {
	get removeJob() { return true; }

	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 moderate health consequences. As anesthesia wears off ${he} tries to open ${his} eyes and finds ${he} is unable to.`);
		if (this._hasEmotion(slave)) {
			if (slave.devotion > 50) {
				r.push(`When ${he} realizes why, ${he} begins to weep, not understanding what ${he} did to deserve this. After a short cry that trails off into a few sniffles, ${he} carries on.`);
			} else if (slave.devotion > 20) {
				r.push(`When ${he} realizes why, ${he} begins to bawl, not understanding what ${he} did to earn this. After a short expurgation of grief and terror, ${he} takes a deep breath and visibly suppresses ${his} emotions.`);
				reaction.trust -= 20;
			} else {
				r.push(`When ${he} realizes what's happened, ${his} face clouds with rage. Reflexively, ${he} swings ${his} head around, looking for the source of ${his} woes. ${He} finally understands the true use of blindness when ${he} realizes ${he} won't be able to tell where you are, where anyone is, or even where ${he} is. ${His} well being is now firmly in the hands of someone ${he} distrusts. ${He} begins to shake with fear.`);
				reaction.trust -= 8;
				reaction.devotion -= 8;
			}
		}
		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Reactions.RemoveBlindEyes = class extends App.Medicine.Surgery.SimpleReaction {
	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 moderate health consequences. As anesthesia wears off ${he} tries to open ${his} eyes and finds ${he} is unable to.`);
		if (this._hasEmotion(slave)) {
			if (slave.devotion > 50) {
				r.push(`When ${he} realizes why, ${he} seems surprised since ${he} doesn't see the point of such procedure. As ${he} was already blind, ${his} mental state remains unaffected.`);
			} else {
				r.push(`${His} face twists in distaste. Such pointless and invasive procedure drives home just how <span class="trust dec">expendable</span> ${he} is to you.`);
				reaction.devotion -= 5;
			}
		}
		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.RemoveEyes = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {FC.BodySideAll} side
	 */
	constructor(slave, side) {
		super(slave);
		this.side = side;
	}

	get name() { return `Remove ${this.side} ${this.side === "both" ? "eyes" : "eye"}`; }

	get healthCost() { return 5; }

	apply(cheat) {
		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 this._assemble(reaction);
	}
};


code:
App.Medicine.Surgery.Reactions.Unblind = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him} = getPronouns(slave);
		const r = [];
		r.push(`The eye surgery is invasive 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.`);
		if (this._hasEmotion(slave)) {
			reaction.devotion += 25;
			reaction.trust += 25;
			if (slave.devotion > 50) {
				r.push(`${He} loved you before, but ${he}'s very grateful, and more trusting, too. ${He} never realized just how good you looked, and now ${he} can't get your image out of ${his} mind.`);
				if (slave.relationship === 0) {
					reaction.shortReaction.push(`${He} now loves you with all ${he} has.`);
					slave.relationship = -2;
				}
			} else if (slave.devotion > 20) {
				r.push(`${He} accepted you as ${his} owner before, but ${he}'s <span class="devotion inc">very grateful,</span> and <span class="trust inc">more trusting,</span> too.`);
			} else {
				r.push(`${He} hardly knows what to make of this wonderful present from someone ${he} hates, and struggles with suspicion that the gift conceals some sort of snare. After a while, though, ${he} accepts that you truly did help ${him}, and might be trustworthy.`);
			}
		}
		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.OFUnblind = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {"left"|"right"} side
	 */
	constructor(slave, side) {
		super(slave);
		this._side = side;
	}

	get name() {
		return "Implant";
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		eyeSurgery(this._slave, this._side, "normal");
		return this._assemble(new App.Medicine.Surgery.Reactions.Unblind());
	}
};


code:
App.Medicine.Surgery.Reactions.Age = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him} = getPronouns(slave);
		const r = [];

		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) {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`examines ${his} younger self in the mirror with approval.`);
			} else {
				r.push(`listens closely to the description of ${his} new younger self with approval.`);
			}
			r.push(`${He} doesn't recognize ${his} youthful yet artificial appearance yet, but ${he} resolves to back ${his} new appearance up with youthful energy and cheer. ${He}'s very happy you used surgery to reverse ${his} apparent aging. As with all surgery ${his} health has been slightly affected.`);
			reaction.devotion += 10;
		} else if (slave.devotion >= -20) {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`examines youthful yet artificial appearance in the mirror`);
			} else {
				r.push(`listens to the description of ${his} youthful yet artificial appearance`);
			}
			r.push(`with hesitation. The cosmetic surgery is extremely well done, and ${he} eventually decides that being subjected to surgery without ${his} consent is acceptable, if it's being used to make ${him} look so young and pretty. As with all surgery ${his} health has been slightly affected.`);
			reaction.devotion += 4;
		} else {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`examines ${his} youthful yet artificial appearance in the mirror`);
			} else {
				r.push(`listens to the description of ${his} youthful yet artificial appearance`);
			}
			r.push(`with confusion. The cosmetic surgery is extremely well done, and ${he} eventually decides that being subjected to surgery without ${his} consent isn't worth fighting against, if it's being used to make ${him} look younger. As with all surgery ${his} health has been slightly affected. ${He} is sensibly fearful of your total power over ${his} body.`);
			reaction.trust -= 5;
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.AgeLift = class extends App.Medicine.Surgery.Procedure {
	get name() { return "Age lift"; }

	get healthCost() { return 10; }

	apply(cheat) {
		applyAgeImplant(this._slave);
		this._slave.faceImplant = Math.clamp(this._slave.faceImplant + faceSurgeryArtificiality(), 0, 100);
		return this._assemble(new App.Medicine.Surgery.Reactions.Age());
	}
};


code:
App.Medicine.Surgery.Reactions.Face = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him, himself} = getPronouns(slave);
		const r = [];

		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) {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`examines ${his} new self in the mirror with approval. ${He} doesn't recognize ${himself} quite yet, but ${he}`);
			} else {
				r.push(`listens closely to the description of ${his} new face. ${He}`);
			}
			r.push(`hopes you'll like ${his} new face better and use ${him} more frequently as a result. ${He}'s happy with your changes to ${his} face. As with all surgery ${his} health has been slightly affected.`);
			reaction.devotion += 4;
		} else if (slave.devotion >= -20) {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`examines ${his} new self in the mirror with hesitation. ${He} doesn't recognize ${himself} quite yet, but ${he}`);
			} else {
				r.push(`listens closely to the description of ${his} new face. ${He}`);
			}
			r.push(`hopes you'll like ${his} new face better and treat ${him} more kindly as a result. As with all surgery ${his} health has been slightly affected. ${He} is sensibly fearful of your total power over ${his} body.`);
			reaction.trust -= 5;
		} else {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`examines ${his} new self in the mirror with revulsion. ${He} doesn't recognize ${himself} quite yet,`);
			} else {
				r.push(`listens closely to the description of ${his} new face,`);
			}
			r.push(`which ${he} hates, though ${he} hopes you'll like ${his} new face better and punish ${him} less cruelly as a result. For now, ${he} seems to view this fake face as a cruel imposition. As with all surgery ${his} health has been slightly affected. ${He} is terribly afraid of your total power over ${his} body.`);
			reaction.trust -= 10;
			reaction.devotion -= 5;
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.FaceShape = class extends App.Medicine.Surgery.Procedure {
	/**
	 * @param {App.Entity.SlaveState} slave
	 * @param {string} targetShape
	 */
	constructor(slave, targetShape) {
		super(slave);
		this.targetShape = targetShape;
	}

	get name() {
		if (this.targetShape === "androgynous" && this._slave.faceShape === "masculine") {
			return `Soften to androgynous`;
		} else if (this.targetShape === "normal") {
			return `Make conventionally feminine`;
		} else {
			return capFirstChar(this.targetShape);
		}
	}

	get healthCost() { return 10; }

	apply(cheat) {
		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());

	}
};

App.Medicine.Surgery.Procedures.FaceAttractiveness = class extends App.Medicine.Surgery.Procedure {
	get name() { return "Just improve attractiveness"; }

	get healthCost() { return 10; }

	apply(cheat) {
		faceIncreaseAction(this._slave, 20);
		this._slave.faceImplant = Math.clamp(this._slave.faceImplant + faceSurgeryArtificiality(), 0, 100);
		return this._assemble(new App.Medicine.Surgery.Reactions.Face());
	}
};


code:
App.Medicine.Surgery.Reactions.Lips = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, himself} = getPronouns(slave);
		const r = [];

		if (slave.fetish === "mindbroken") {
			r.push(`${He} vaguely realizes ${his} mouth doesn't move as well as it used to. As with all surgery <span class="health dec">${his} health has been slightly affected.</span>`);
		} else if (slave.devotion > 20 && this._strongKnownFetish(slave, "cumslut")) {
			r.push(`${He} licks ${his} new lips experimentally but doesn't lose much time before turning to you with ${his} mouth open and ready. ${He}'s still sore, so ${he}'s careful, but ${he} runs ${his} wet tongue over ${his} lips, already panting at the thought of sucking dick. If ${he} had much in the way of oral skills, they've likely suffered. ${He}'s happy with your changes to ${his} lips, so much so that ${he} now trusts your plans for ${his} body. As with all surgery ${his} health has been slightly affected.`);
			reaction.trust += 4;
			reaction.devotion += 4;
			if (slave.skill.oral > 10) {
				slave.skill.oral -= 10;
			}
		} else if (slave.devotion > 50) {
			r.push(`${He} puckers ${his} new lips experimentally and turns to you with a smile to show them off. ${He}'s still sore, so ${he}'s careful as ${he} blows you an awkward kiss. If ${he} had much in the way of oral skills, they've likely suffered. ${He}'s happy with your changes to ${his} lips. As with all surgery ${his} health has been slightly affected.`);
			reaction.devotion += 4;
			if (slave.skill.oral > 10) {
				slave.skill.oral -= 10;
			}
		} else if (slave.devotion >= -20) {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`eyes`);
			} else {
				r.push(`puckers`);
			}
			r.push(`${his} new lips skeptically. ${He}'s still sore, so ${he} doesn't touch them. ${He}'s come to terms with the fact that ${he}'s a slave, so ${he} expected something like this when ${he} was sent to the surgery. ${He} isn't much affected mentally, but if ${he} had much in the way of oral skills, they've likely suffered. As with all surgery ${his} health has been slightly affected. ${He} is sensibly fearful of your total power over ${his} body.`);
			reaction.trust -= 5;
			if (slave.skill.oral > 10) {
				slave.skill.oral -= 10;
			}
		} else {
			r.push(`${He}`);
			if (canSee(slave)) {
				r.push(`eyes`);
			} else {
				r.push(`puckers`);
			}
			r.push(`${his} new lips with resentment. ${He}'s still sore, so ${he} doesn't touch them, but ${canSee(slave) ? `${he} glares daggers` : `${his} face contorts with distaste`}. ${He} still thinks of ${himself} as a person, so ${he} isn't used to the idea of being surgically altered to suit your every whim. If ${he} had much in the way of oral skills, they've likely suffered. For now, ${he} seems to view these fake lips as a cruel imposition. As with all surgery ${his} health has been slightly affected. ${He} is terribly afraid of your total power over ${his} body.`);
			reaction.trust -= 10;
			reaction.devotion -= 5;
			if (slave.skill.oral > 10) {
				slave.skill.oral -= 10;
			}
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

/**
 * @type {FC.Medicine.AssetSizingProcedureSet}
 */
App.Medicine.Surgery.Procedures.lipImplantProcedure = function() {
	class Fill extends App.Medicine.Surgery.Procedures.FillSizingImplantProcedure {
		get name() {
			return "Replace with the next size up";
		}

		get description() {
			return '';
		}
	}

	/**
	 * @template {FC.Medicine.SizingImplantProcedureConstructor} T
	 * @param {T} Procedure
	 * @param {ConstructorParameters<T>} args
	 */
	function makeProcedure(Procedure, args) {
		return new (class extends Procedure {
			_doTargetGain() {
				return new App.Medicine.Surgery.Reactions.Lips();
			}

			_doTargetLoss() {
				return new App.Medicine.Surgery.Reactions.Lips();
			}

			/**
			 * @param {number} volume
			 * @returns {string}
			 */
			_volumeStr(volume) {
				return '';
			}

			/**
			 * @param {number} volume
			 * @returns {string}
			 */
			_fleshExcessStr(volume) {
				return App.Utils.expandHTML(`${Math.round(100. * volume / App.Medicine.fleshSize(this.originalSlave, "lips"))} %`);
			}

			// overridden because slaves do not have the lipsImplantType property (yet?)
			_setSlaveImplantType() {}
		})(...args);
	}

	class Reduce extends App.Medicine.Surgery.Procedure {
		/**
		 * @param {FC.SlaveState} slave
		 * @param {string} name
		 * @param {number} amount
		 */
		constructor(slave, name, amount) {
			super(slave);
			this._name = name;
			this._amount = amount;
		}

		get name() {
			return `${this._name.toUpperFirst()} lips`;
		}

		get healthCost() {
			return 10;
		}

		apply(cheat) {
			this._slave.lips -= this._amount;
			return this._assemble(new App.Medicine.Surgery.Reactions.Lips());
		}
	}

	return {
		install: (slave, type, size, fleshExcess) =>
			makeProcedure(App.Medicine.Surgery.Procedures.InstallSizingImplantProcedure, [slave, "lips", type, size, fleshExcess]),
		replace: (slave, type, size, fleshExcess) =>
			makeProcedure(App.Medicine.Surgery.Procedures.ReplaceSizingImplantProcedure, [slave, "lips", type, size, fleshExcess]),
		remove: (slave) =>
			makeProcedure(App.Medicine.Surgery.Procedures.RemoveSizingImplantProcedure, [slave, "lips"]),

		fill: (slave, amount) =>
			makeProcedure(Fill, [slave, "lips", amount]),
		drain: (slave, amount) =>
			makeProcedure(App.Medicine.Surgery.Procedures.DrainSizingImplantProcedure, [slave, "lips", amount]),

		reduce: (slave, name, amount) => new Reduce(slave, name, amount)
	};
}();


code:
App.Medicine.Surgery.Reactions.Anus = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him} = getPronouns(slave);
		const r = [];

		if (slave.fetish === "mindbroken") {
			r.push(`${He} leaves the surgery with a terribly sore rear end and little desire to mess with it. As with all surgery <span class="health dec">${his} health has been slightly affected.</span>`);
		} else {
			if (this._strongKnownFetish(slave, "buttslut")) {
				r.push(`${He} leaves the surgery with a terribly sore rear end. ${He} is filled with joy at the prospect of having a tight butt all over again, so much so that ${he} now trusts your plans for ${his} body. If ${he} had much in the way of anal skills, they've likely suffered. As with all surgery ${his} health has been slightly affected.`);
				reaction.trust += 4;
				reaction.devotion += 10;
			} else if (slave.devotion > 50) {
				r.push(`${He} leaves the surgery with a terribly sore rear end. ${He}'s a bit anxious at the prospect of the pain having to get back to a loose asshole the hard way, but ${he}'s happy that you think ${him} worth the effort of surgical improvement. If ${he} had much in the way of anal skills, they've likely suffered. As with all surgery ${his} health has been slightly affected.`);
				reaction.devotion += 4;
			} else if (slave.devotion >= -20) {
				r.push(`${He} leaves the surgery with a terribly sore rear end. ${He} knows ${he}'ll have to endure the pain of being fucked in a tight asshole again soon enough, but trepidation is nothing new for ${him}. If ${he} had much in the way of anal skills, they've likely suffered. As with all surgery ${his} health has been slightly affected. ${He} is sensibly fearful of your total power over ${his} body.`);
				reaction.trust -= 5;
			} else {
				r.push(`${He} leaves the surgery with a terribly sore rear end. ${He}'s horrified at surgical alteration of ${his} rear end, and knows that this means that ${he}'ll have to take the pain of sodomy in a tight ass all over again. If ${he} had much in the way of anal skills, they've likely suffered. As with all surgery ${his} health has been slightly affected. ${He} is terribly afraid of your total power over ${his} most intimate parts.`);
				reaction.trust -= 10;
				reaction.devotion -= 5;
			}
			if (slave.skill.anal > 10) {
				slave.skill.anal -= 10;
			}
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.RepairAnus = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Repair asshole";
	}

	get description() {
		const {his} = getPronouns(this.originalSlave);
		return `This will reduce ${his} anal skills`;
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.anus = 3;
		return this._assemble(new App.Medicine.Surgery.Reactions.Anus());
	}
};

App.Medicine.Surgery.Procedures.TightenAnus = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Tighten asshole";
	}

	get description() {
		const {his} = getPronouns(this.originalSlave);
		return `This will reduce ${his} anal skills`;
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.anus = 1;
		return this._assemble(new App.Medicine.Surgery.Reactions.Anus());
	}
};

App.Medicine.Surgery.Procedures.RestoreAnalVirginity = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Restore anal virginity";
	}

	get description() {
		const {his} = getPronouns(this.originalSlave);
		return `This will reduce ${his} anal skills`;
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.anus = 0;
		return this._assemble(new App.Medicine.Surgery.Reactions.Anus());
	}
};


code:
App.Medicine.Surgery.Reactions.ChemCastrate = class extends App.Medicine.Surgery.SimpleReaction {
	get invasive() {
		return false;
	}

	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his} = getPronouns(slave);
		const r = [];

		r.push(`${He} knows something has been done to ${his} testicles, but ${he} can't feel anything off about them. Since the surgery was nothing more than a simple injection, ${he} has been spared any pain.`);

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.ChemCastrate = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Chemically castrate";
	}

	apply(cheat) {
		this._slave.ballType = "sterile";
		return this._assemble(new App.Medicine.Surgery.Reactions.ChemCastrate());
	}
};


code:
App.Medicine.Surgery.Reactions.Chop = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, His, his, him, himself} = getPronouns(slave);
		const r = [];

		if (slave.fetish === "mindbroken") {
			r.push(`Surprisingly, ${he} already realized while exiting that ${his} genitalia was completely reshaped. The reasons why are lost to ${him}, though.`);
		} else if (slave.vagina === -1) {
			r.push(`Of course, ${he} already realized while exiting that something very dear to ${him} has been taken away.`);
			if (slave.devotion > 50 && slave.sexualFlaw === "self hating") {
				r.push(`Strong emotions play out on ${his} face as ${he} experiences a watershed in ${his} life of sexual slavery, perhaps the most radical one ${he}'ll ever experience. ${He} loves you with all ${his} being, and truly hates ${himself}. ${He} finds ${himself} in an emotional place where ${he}'s willing to accept having had you cut ${his} dick off. ${He} knows ${he}'s a worthless piece of trash, and realizes that if you feel like trimming useless bits off ${him}, that's your prerogative. In moments, ${he}'s confirmed in total, final, fanatical submission to your will. It's almost frightening.`);
				reaction.devotion += 50;
			} else if (slave.devotion > 20 && slave.fetishKnown === 1 && slave.fetishStrength > 95 && slave.fetish === "buttslut") {
				r.push(`${He}'s such a complete buttslut, though, that ${he} finds ${he} doesn't really care. ${He} never really paid much attention to ${his} own dick; for ${him}, sex is about the phalli that get rammed up ${his} ass. And you didn't take that from ${him}. If anything, ${he}'s reassured by the implicit promise that ${he}'ll never be anything but a butthole slut, and of course is forced even further into submission to your will.`);
				reaction.devotion += 8;
				reaction.trust += 8;
			} else if (slave.devotion > 20 && slave.fetishKnown === 1 && slave.fetishStrength > 95 && slave.fetish === "cumslut") {
				r.push(`${He}'s such an oral slut, though, that ${he} finds ${he} doesn't really care. ${He} never really paid much attention to ${his} dick; for ${him}, sex is about what ${he} gets to suck. As far as ${he}'s concerned, you've simply confirmed that ${his} most important hole is the one in ${his} face. If anything, ${he}'s reassured by the implicit promise that ${he}'ll never be anything more than a nice inviting facepussy, and of course, ${he}'s forced even further into submission to your will.`);
				reaction.devotion += 8;
				reaction.trust += 8;
			} else if (slave.devotion > 20 && slave.fetishKnown === 1 && slave.fetishStrength > 95 && slave.fetish === "submissive") {
				r.push(`${He}'s such a total submissive, though, that ${he} accepts even this. Having ${his} cock removed, reducing ${him} to a sexually helpless place where ${he} can only receive pleasure by being penetrated, is perhaps the final step in sexual slavery, and ${he}'s a little awed by it. If anything, ${he}'s reassured by the implicit promise that ${his} body exists for the sexual gratification of others, and of course, ${he}'s forced even further into submission to your will.`);
				reaction.devotion += 8;
				reaction.trust += 8;
			} else if (slave.devotion > 95) {
				r.push(`Doubt, fear, and even nausea play across ${his} face, but ${he}'s so worshipful of you that ${he} masters them all, accepting that this is your will. There's surprisingly little mental effect on ${him}. The horror of having ${his} dick cut off is so strong that it breaks through to ${him}, and the only way ${he} can find to deal with it is to think about it as little as possible. ${He} falls back on worshipful duty.`);
			} else if (slave.devotion > 50) {
				r.push(`${He}'s devoted to you, but doubt and fear play across ${his} face as ${he} comes to terms with what's happened. ${He} does not see how having ${his} dick removed will improve ${his} sexual slavery. ${He} does not rage or scream, but ${he} does cry, sadly wondering whether ${he}'s valuable to you at all, or if ${he}'s just a surgical plaything to be degraded. ${He}'s very frightened that you'll cut off more of ${his} remaining parts.`);
				reaction.trust -= 10;
				reaction.devotion -= 10;
			} else if (slave.devotion > 20) {
				r.push(`${He}'s properly broken to slavery, but this is much too far. Having ${his} dick cut off cuts straight through ${his} conditioning, and tears roll down ${his} face as the horrible permanence of what's happened to ${him} really sinks in. Open anger begins to become apparent through ${his} tears; ${he} thought that ${his} obedience merited better than this, and ${he}'s extremely terrified to find that despite being a decent slave, ${he} remains a surgical playground.`);
				reaction.trust -= 20;
				reaction.devotion -= 20;
			} else {
				r.push(`${He}'s horrified almost beyond the ability of ${his} mind to comprehend. ${His} face takes on a blank look as ${he} goes into shock. There's no screaming and no tears, not yet; it will take ${his} time to process what's happened to ${him}. Without a doubt, ${he}'ll be absolutely filled by rage and terror.`);
				reaction.trust -= 40;
				reaction.devotion -= 40;
			}
		} else {
			r.push(`Of course, ${he} already realized while exiting that ${his} genitalia has been radically simplified. As a herm slave ${he} knew this day might come,`);
			if (slave.devotion > 50) {
				r.push(`and ${his} face is a strange mix of hope, happiness, satisfaction, and the tiniest tinge of soul-crushing sadness as ${he}`);
				if (canSee(slave)) {
					r.push(`views`);
				} else {
					r.push(`feels`);
				}
				r.push(`the vagina that is all that remains of ${his} once-unique hermaphroditic genitalia. <span class="devotion inc">${He} has become more submissive due to your radical reshaping of ${his} body.</span>`);
				reaction.devotion += 4;
			} else if (slave.devotion > 20) {
				r.push(`and ${his} face is a strange mix of fear, hope, and resignation as ${he}`);
				if (canSee(slave)) {
					r.push(`views`);
				} else {
					r.push(`feels`);
				}
				r.push(`the vagina that is all that remains of ${his} once-unique hermaphroditic genitalia. Eventually ${his} shoulders slump and ${he} tries to carry on. ${He} will struggle with feelings of confusion and loss. ${He} is terribly afraid of your total power over ${his} body.`);
				reaction.trust -= 10;
				reaction.devotion -= 5;
			} else {
				r.push(`but expectations and the reality are two different things. ${He}'s beside ${himself}, weeping gently.`);
				if (hasAnyArms(slave)) {
					r.push(`${He} absently moves a hand to where ${his} penis would have been and snatches it away with a sob.`);
				}
				r.push(`<span class="devotion dec">The surgical invasion has filled ${him} with horror and anger.</span> ${He} is <span class="trust dec">cripplingly afraid</span> of your total power over ${his} body.`);
				reaction.trust -= 20;
				reaction.devotion -= 20;
			}
		}
		r.push(`Naturally, <span class="health dec">${his} health has been greatly affected</span> by such serious surgery.`);

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.ChopPenis = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Remove penis";
	}

	get invasive() {
		return true;
	}

	apply(cheat) {
		surgeryAmp(this._slave, "dick");
		return this._assemble(new App.Medicine.Surgery.Reactions.Chop());
	}
};


code:
App.Medicine.Surgery.Reactions.Circumcision = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, himself} = getPronouns(slave);
		const r = [];

		if (slave.dick > 0) {
			if (slave.fetish === "mindbroken") {
				r.push(`${He} exits the surgery gingerly, since ${he} can feel that something was done to ${his} dick. Since it is still there, ${he} doesn't understand what changed. Circumcision of an adult is not a trivial procedure, so ${his} health has been slightly affected.`);
			} else if (slave.devotion > 50) {
				r.push(`${He} exits the surgery gingerly, since ${he} can feel that something was done to ${his} dick. ${He} examines it carefully`);
				if (canSee(slave)) {
					r.push(`in the mirror.`);
				} else {
					r.push(`by feeling alone.`);
				}
				r.push(`Realizing that ${he}'s been circumcised, ${he}'s very happy you'd take an interest in ${his} penis, and looks forward to having a slightly easier time keeping ${himself} clean through ${his} life as a sex slave. Circumcision of an adult is not a trivial procedure, so ${his} health has been slightly affected.`);
				reaction.devotion += 4;
			} else if (slave.devotion > 20) {
				r.push(`${He} exits the surgery gingerly, since ${he} can feel that something was done to ${his} dick. ${He} examines it carefully`);
				if (canSee(slave)) {
					r.push(`in the mirror.`);
				} else {
					r.push(`by feeling alone.`);
				}
				r.push(`Realizing that ${he}'s been circumcised, ${he}'s flooded with relief. ${He}'s so elated that ${he} hasn't been severely damaged that ${he} doesn't mind your taking surgical control of ${his} member. Circumcision of an adult is not a trivial procedure, so ${his} health has been slightly affected.`);
			} else {
				r.push(`${He} exits the surgery gingerly, since ${he} can feel that something was done to ${his} dick. ${He} examines it carefully`);
				if (canSee(slave)) {
					r.push(`in the mirror.`);
				} else {
					r.push(`by feeling alone.`);
				}
				r.push(`Realizing that ${he}'s been circumcised, ${he}'s flooded with relief, since ${he} was afraid that you'd done something far more terrible. Once ${he} has time to think about it, though, ${he}'s somewhat resentful, since ${he} naturally feels a certain proprietary interest in ${his} own penis. Circumcision of an adult is not a trivial procedure, so ${his} health has been slightly affected.`);
				reaction.devotion -= 5;
			}
		} else {
			if (slave.fetish === "mindbroken") {
				r.push(`${He} exits the surgery gingerly, since ${he} can feel that something was done to ${his} crotch. Since everything is still there, ${he} doesn't understand what changed. ${his} health has been slightly affected.`);
			} else if (slave.devotion > 50) {
				r.push(`${He} exits the surgery gingerly, since ${he} can feel that ${his} crotch was operated on. ${He} examines it carefully`);
				if (canSee(slave)) {
					r.push(`in the mirror.`);
				} else {
					r.push(`by feeling alone.`);
				}
				r.push(`Realizing that ${he}'s been circumcised, ${he}'s very happy you'd take an interest in ${his} sex, and looks forward to having a slightly easier time keeping ${himself} clean through ${his} life as a sex slave. ${his} health has been slightly affected.`);
				reaction.devotion += 4;
			} else if (slave.devotion > 20) {
				r.push(`${He} exits the surgery gingerly, since ${he} can feel that ${his} crotch was operated on. ${He} examines it carefully`);
				if (canSee(slave)) {
					r.push(`in the mirror.`);
				} else {
					r.push(`by feeling alone.`);
				}
				r.push(`Realizing that ${he}'s been circumcised, ${he}'s flooded with relief. ${He}'s so elated that ${he} hasn't been severely damaged that ${he} doesn't mind minor surgical alteration. ${his} health has been slightly affected.`);
			} else {
				r.push(`${He} exits the surgery gingerly, since ${he} can feel that ${his} crotch was operated on. ${He} examines it carefully`);
				if (canSee(slave)) {
					r.push(`in the mirror.`);
				} else {
					r.push(`by feeling alone.`);
				}
				r.push(`Realizing that ${he}'s been circumcised, ${he}'s flooded with relief, since ${he} was afraid that you'd done something far more terrible. Once ${he} has time to think about it, though, ${he}'s somewhat resentful, since ${he} naturally feels a certain proprietary interest in ${his} sex. ${his} health has been slightly affected.`);
				reaction.devotion -= 5;
			}
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.RemoveClitHood = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Remove clitoral hood";
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.foreskin = 0;
		return this._assemble(new App.Medicine.Surgery.Reactions.Circumcision());
	}
};

App.Medicine.Surgery.Procedures.RemoveForeskin = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Remove foreskin";
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.foreskin = 0;
		return this._assemble(new App.Medicine.Surgery.Reactions.Circumcision());
	}
};


code:
App.Medicine.Surgery.Reactions.ClitoralEnlargement = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, His, his} = getPronouns(slave);
		const r = [];

		if (slave.fetish === "mindbroken") {
			r.push(`${He} leaves the surgery with a terribly sore pussy and little desire to mess with it. As with all surgery <span class="health dec">${his} health has been slightly affected.</span>`);
		} else if (slave.energy > 95) {
			r.push(`${He} leaves the surgery with a terribly sore pussy. ${He} is filled with joy at the thought that ${his} pussy will now be more appealing to ${his} ${getWrittenTitle(slave)}; ${his} sensitivity has been increased, raising ${his} sex drive slightly. As with all surgery ${his} health has been slightly affected.`);
			reaction.trust += 4;
			reaction.devotion += 10;
			slave.energy += 1;
		} else if (slave.devotion > 50) {
			r.push(`${He} leaves the surgery with a terribly sore pussy. ${He}'s happy that you think ${his} pussy worth the effort of surgical improvement; ${his} sensitivity has been increased, raising ${his} sex drive slightly. As with all surgery ${his} health has been slightly affected.`);
			reaction.devotion += 4;
			slave.energy += 1;
		} else if (slave.devotion >= -20) {
			r.push(`${He} leaves the surgery with a terribly sore pussy. ${He}'s somewhat revolted by the surgery, but as far as ${he}'s concerned, the short recovery period will mean a time during which ${he} can be sure no one will use ${his} pussy. ${His} sensitivity has been increased, raising ${his} sex drive slightly. As with all surgery ${his} health has been slightly affected. ${He} is sensibly fearful of your total power over ${his} body.`);
			reaction.trust -= 5;
			slave.energy += 1;
		} else {
			r.push(`${He} leaves the surgery with a terribly sore pussy. ${He}'s horrified at surgical alteration of ${his} womanhood; this is probably more of an invasion than ${he} could readily imagine before today. ${His} sensitivity has been increased, raising ${his} sex drive slightly. As with all surgery ${his} health has been slightly affected. ${He} is terribly afraid of your total power over ${his} most intimate parts.`);
			reaction.trust -= 10;
			reaction.devotion -= 5;
			slave.energy += 1;
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.ClitoralEnlargement = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Increase clit";
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.clit += 1;
		return this._assemble(new App.Medicine.Surgery.Reactions.ClitoralEnlargement());
	}
};


code:
App.Medicine.Surgery.Reactions.ClitoralReduction = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his} = getPronouns(slave);
		const r = [];

		if (slave.fetish === "mindbroken") {
			r.push(`${He} leaves the surgery with a terribly sore pussy and little desire to mess with it. As with all surgery <span class="health dec">${his} health has been slightly affected.</span>`);
		} else if (slave.energy > 95) {
			r.push(`${He} leaves the surgery with a terribly sore pussy. ${He} is filled with joy at the thought that ${his} pussy will now be more appealing to ${his} ${getWrittenTitle(slave)}; ${his} sensitivity has been reduced, reducing ${his} sex drive slightly. As with all surgery ${his} health has been slightly affected.`);
			reaction.trust += 4;
			reaction.devotion += 10;
			slave.energy -= 5;
		} else if (slave.devotion > 50) {
			r.push(`${He} leaves the surgery with a terribly sore pussy. ${He}'s happy that you think ${his} pussy worth the effort of surgical improvement, although ${his} sensitivity has been reduced, reducing ${his} sex drive slightly. As with all surgery ${his} health has been slightly affected.`);
			reaction.devotion += 4;
			slave.energy -= 5;
		} else if (slave.devotion >= -20) {
			r.push(`${He} leaves the surgery with a terribly sore pussy. ${He}'s somewhat revolted by the surgery, but as far as ${he}'s concerned, the short recovery period will mean a time during which ${he} can be sure no one will use ${his} pussy. The reduced sensitivity has noticeably reduced ${his} sex drive. As with all surgery ${his} health has been slightly affected. ${He} is sensibly fearful of your total power over ${his} body.`);
			reaction.trust -= 5;
			slave.energy -= 10;
		} else {
			r.push(`${He} leaves the surgery with a terribly sore pussy. ${He}'s horrified at surgical alteration of ${his} womanhood; this is probably more of an invasion than ${he} could readily imagine before today and ${his} sex drive takes a heavy hit. As with all surgery ${his} health has been slightly affected. ${He} is terribly afraid of your total power over ${his} most intimate parts.`);
			reaction.trust -= 10;
			reaction.devotion -= 5;
			slave.energy -= 20;
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.ClitoralReduction = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Apply clitoral reduction";
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.clit = 0;
		return this._assemble(new App.Medicine.Surgery.Reactions.ClitoralReduction());
	}
};


code:
App.Medicine.Surgery.Reactions.Ejaculation = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, His, his, him, himself} = getPronouns(slave);
		const r = [];

		r.push(`${His} groin is a little sore, and ${he} examines it closely, finding it slightly swollen. Near the end of ${his} close inspection of ${his} own private parts, though, ${he} happens to stimulate ${himself}, unintentionally, and just a little. That's enough. ${He} begins to leak excessive precum, as usual, but a distinct pressure begins building in ${his} loins. ${He} groans as the swelling rises before bucking and orgasming uncontrollably, coating ${himself} and the bed in a layer of fluid.`);
		if (this._hasEmotion(slave)) {
			if (slave.devotion > 50) {
				r.push(`${He}'s delighted. ${He}'s such a good sex slave that the lewdness of extra large ejaculations is exciting to ${him}. That, and the extra length of ${his} climax wasn't bad either.`);
				reaction.devotion += 4;
			} else if (slave.devotion >= -20) {
				r.push(`${He} obviously doesn't know what to think at first. Just brushing ${his} private parts resulted in a huge mess, a somewhat exciting prospect, but ${he}'s realizing that this is going to be rather inconvenient, if not moist. Still, having such a lewd change made to ${his} body affects ${his} feelings towards you; ${he} is sensibly fearful of your total power over ${him}.`);
				reaction.trust -= 5;
			} else {
				r.push(`${He} feared the worst when ${he} realized that something had been done to ${him} down there, and ${he}'s initially relieved to find that ${he}'s intact and apparently functional. But ${he}'s been invaded in an extremely personal way, and resents having you tamper with ${his} private parts. Furthermore, ${he} is sensibly fearful of your total power over ${him}.`);
				reaction.trust -= 5;
				reaction.devotion -= 5;
			}
		}
		r.push(`As with all surgery <span class="health dec">${his} health has been slightly affected.</span>`);

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.EjaculationBooster = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Implant prostate with an ejaculation boosting implant";
	}

	get description() {
		const {his} = getPronouns(this.originalSlave);
		return `This will thin ${his} ejaculate but greatly increase its quantity`;
	}

	get healthCost() {
		return 20;
	}

	apply(cheat) {
		this._slave.prostate = 3;
		return this._assemble(new App.Medicine.Surgery.Reactions.Ejaculation());
	}
};


code:
App.Medicine.Surgery.Reactions.EndEjaculation = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, His, his} = getPronouns(slave);
		const r = [];

		r.push(`${His} groin is a little sore, and ${he} examines it closely, but ${he} can't find much difference other than the swelling in ${his} crotch has gone down. ${He}'ll realize later when ${his} next ejaculation is rather underwhelming from what ${he} has become accustomed to. As with all surgery ${his} health has been slightly affected.`);

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.RemoveEjaculationBooster = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Remove ejaculation implant";
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.prostate = 2;
		return this._assemble(new App.Medicine.Surgery.Reactions.EndEjaculation());
	}
};


code:
App.Medicine.Surgery.Reactions.EndPrecum = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {he, His, his, him} = getPronouns(slave);
		const r = [];

		r.push(`${His} groin is a little sore, and ${he} examines it closely, but ${he} can't find much difference. ${His} generous production of precum won't tail off for some time, until the slow-release drugs are completely flushed from ${his} system. Even then, the only real change for ${him} will be a little less inconvenience. As with all surgery ${his} health has been slightly affected.`);

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.EndPrecum = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Remove drug implant";
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.prostate = 1;
		return this._assemble(new App.Medicine.Surgery.Reactions.EndPrecum());
	}
};


code:
App.Medicine.Surgery.Reactions.Fertility = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, him} = getPronouns(slave);
		const r = [];

		if (slave.fetish === "mindbroken") {
			r.push(`${He} leaves the surgery with nothing but a nonspecific ache in ${his} lower abdomen, but lacks the mental faculties to realize that ${he} now has a chance to get pregnant. As with all surgery ${his} health has been slightly affected.`);
		} else if (this._strongKnownFetish(slave, "pregnancy") || slave.origin === "$He sold $himself to you in the hope of someday bearing children.") {
			r.push(`${He} leaves the surgery with nothing but a nonspecific ache in ${his} lower abdomen, but ${he} knows enough about surgery and sex slaves to know that it means ${he} now has a chance to get pregnant. ${He} is filled with joy whenever ${he} thinks about the fact that feeling a life growing within ${him} is now, at last, a possibility. ${He}'s so pleased that ${he} now trusts your plans for ${his} body. As with all surgery ${his} health has been slightly affected.`);
			reaction.trust += 4;
			reaction.devotion += 5;
		} else if (slave.devotion > 50) {
			r.push(`${He} leaves the surgery with nothing but a nonspecific ache in ${his} lower abdomen, but ${he} knows enough about surgery and sex slaves to know that it means ${he} now has a chance to get pregnant. ${He}'s grateful that you think ${him} worthy of breeding, and even a little nervous about how ${he}'ll perform as a breeder. As with all surgery ${his} health has been slightly affected.`);
			reaction.devotion += 4;
		} else if (slave.devotion >= -20) {
			r.push(`${He} leaves the surgery with nothing but a nonspecific ache in ${his} lower abdomen, but ${he} knows enough about surgery and sex slaves to know that it means ${he} may now be impregnated. ${He} understands the realities of ${his} life as a slave, and that being bred was a possibility, so it isn't much of a shock. As with all surgery ${his} health has been slightly affected. ${He} is sensibly fearful of your total power over ${his} body.`);
			reaction.trust -= 5;
		} else {
			r.push(`${He} leaves the surgery with nothing but a nonspecific ache in ${his} lower abdomen, but ${he} knows enough about surgery and sex slaves to know that it means ${he} may now be impregnated. ${He} does not understand the realities of ${his} life as a slave at a core level, so ${he}'s terrified and angry at the potential that ${he}'ll be bred. As with all surgery ${his} health has been slightly affected. ${He} is sensibly fearful of your total power over ${his} body.`);
			reaction.trust -= 5;
			reaction.devotion -= 5;
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.RestoreFertility = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Restore fertility";
	}

	get healthCost() {
		return 10;
	}

	apply(cheat) {
		this._slave.preg = 0;
		return this._assemble(new App.Medicine.Surgery.Reactions.Fertility());
	}
};


code:
App.Medicine.Surgery.Reactions.ForeskinTuck = class extends App.Medicine.Surgery.SimpleReaction {
	reaction(slave, diff) {
		const reaction = super.reaction(slave, diff);
		const {He, he, his, himself} = getPronouns(slave);
		const r = [];

		if (slave.fetish === "mindbroken") {
			r.push(`${He} exits the surgery gingerly, since ${he} can feel that something was done to ${his} dick. Since it is still there, ${he} doesn't understand what changed. ${his} health has been slightly affected.`);
		} else if (slave.devotion > 50) {
			r.push(`${He} exits the surgery gingerly, since ${he} can feel that something was done to ${his} dick. ${He} examines it carefully`);
			if (canSee(slave)) {
				r.push(`in the mirror.`);
			} else {
				r.push(`by feeling alone.`);
			}
			r.push(`Realizing that ${his} foreskin fits comfortably, ${he}'s very happy you'd take an interest in ${his} penis, and looks forward to having a slightly easier time keeping ${himself} clean through ${his} life as a sex slave.`);
			if (canAchieveErection(slave)) {
				r.push(`${He} also can't wait`);
				if (canSee(slave)) {
					r.push(`for the show during`);
				} else {
					r.push(`to feel`);
				}
				r.push(`${his} next erection.`);
			}
			r.push(`<span class="health dec">${his} health has been slightly affected.</span>`);
			reaction.devotion += 4;
		} else if (slave.devotion > 20) {
			r.push(`${He} exits the surgery gingerly, since ${he} can feel that something was done to ${his} dick. ${He} examines it carefully`);
			if (canSee(slave)) {
				r.push(`in the mirror.`);
			} else {
				r.push(`by feeling alone.`);
			}
			r.push(`Realizing that ${his} foreskin fits comfortably, ${he}'s flooded with relief. ${He}'s so elated that ${he} hasn't been severely damaged that ${he} doesn't mind your taking surgical control of ${his} member. ${his} health has been slightly affected.`);
		} else {
			r.push(`${He} exits the surgery gingerly, since ${he} can feel that something was done to ${his} dick. ${He} examines it carefully`);
			if (canSee(slave)) {
				r.push(`in the mirror.`);
			} else {
				r.push(`by feeling alone.`);
			}
			r.push(`Realizing that ${his} foreskin fits comfortably, ${he}'s flooded with relief, since ${he} was afraid that you'd done something far more terrible. Once ${he} has time to think about it, though, ${he}'s somewhat resentful, since ${he} naturally feels a certain proprietary interest in ${his} own penis. ${his} health has been slightly affected.`);
			reaction.devotion -= 5;
		}

		reaction.longReaction.push(r);
		return reaction;
	}
};

App.Medicine.Surgery.Procedures.ForeskinTuck = class extends App.Medicine.Surgery.Procedure {
	get name() {
		return "Remove excess foreskin";
	}

	get healthCost() {
		return 5;
	}

	apply(cheat) {
		this._slave.foreskin = this._slave.dick;
		return this._assemble(new App.Medicine.Surgery.Reactions.ForeskinTuck());
	}
};