From 1d95c75e453bfc75893499e60a73198af3ba75bc Mon Sep 17 00:00:00 2001
From: DCoded <dcoded@live.com>
Date: Mon, 26 Nov 2018 22:42:37 -0500
Subject: [PATCH] Added chastity

---
 devNotes/twine JS.txt                         | 25 ++++++------
 slave variables documentation - Pregmod.txt   |  1 +
 src/facilities/nursery/childInteract.tw       |  1 +
 .../nursery/longChildDescription.tw           |  2 +-
 src/js/eventSelectionJS.tw                    | 28 +++++++-------
 src/js/slaveSummaryWidgets.tw                 |  3 ++
 src/pregmod/organFarmOptions.tw               |  4 ++
 src/pregmod/widgets/deathWidgets.tw           |  2 +-
 src/uncategorized/RESS.tw                     |  2 +-
 src/uncategorized/longSlaveDescription.tw     |  4 +-
 src/uncategorized/randomIndividualEvent.tw    |  2 +-
 src/uncategorized/reStandardPunishment.tw     |  2 +-
 src/uncategorized/saRelationships.tw          |  6 +--
 src/uncategorized/saRivalries.tw              |  2 +-
 src/uncategorized/saRules.tw                  | 38 +++++++++----------
 src/uncategorized/slaveAssignmentsReport.tw   |  2 +-
 src/uncategorized/slaveInteract.tw            |  1 +
 src/uncategorized/walkPast.tw                 |  2 +-
 18 files changed, 71 insertions(+), 56 deletions(-)

diff --git a/devNotes/twine JS.txt b/devNotes/twine JS.txt
index 3fe7d35ca5c..d1e805d9e43 100644
--- a/devNotes/twine JS.txt	
+++ b/devNotes/twine JS.txt	
@@ -4378,7 +4378,7 @@ if(eventSlave.fetish != "mindbroken") {
 						if(eventSlave.energy > 40) {
 							if(canPenetrate(eventSlave)) {
 								if(canSee(eventSlave)) {
-									if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+									if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 										State.variables.RETSevent.push("interslave begging");
 									}
 								}
@@ -4395,7 +4395,7 @@ if(eventSlave.fetish != "mindbroken") {
 							if(eventSlave.belly < 100000) {
 								if(eventSlave.lactation) {
 									if(eventSlave.nipples != "fuckable") {
-										if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+										if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 											State.variables.RETSevent.push("incestuous nursing");
 										}
 									}
@@ -4405,7 +4405,7 @@ if(eventSlave.fetish != "mindbroken") {
 					}
 				}
 			} else {
-				if(eventSlave.devotion > 20 && (eventSlave.sexualQuirk == "perverted" || eventSlave.energy > 80) && eventSlave.belly < 100000 && eventSlave.lactation > 0 && eventSlave.nipples != "fuckable" && eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.daughters > 0) {
+				if (eventSlave.devotion > 20 && (eventSlave.sexualQuirk == "perverted" || eventSlave.energy > 80) && eventSlave.belly < 100000 && eventSlave.lactation > 0 && eventSlave.nipples != "fuckable" && eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity" && eventSlave.daughters > 0) {
 					State.variables.RETSevent.push("incestuous nursing");
 				}
 			}
@@ -4608,7 +4608,7 @@ if(eventSlave.fetish != "mindbroken") {
 
 			if(State.variables.REAnalCowgirlSubIDs.length > 1 || (State.variables.REAnalCowgirlSubIDs.length == 1 && eventSlave.ID != State.variables.REAnalCowgirlSubIDs[0])) {
 				if(eventSlave.devotion > 20) {
-					if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+					if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 						if(eventSlave.fetish == "buttslut" || eventSlave.fetish == "sadist" || eventSlave.fetish == "dom") {
 							if((eventSlave.dickAccessory != "chastity" && eventSlave.dickAccessory != "combined chastity") || eventSlave.dick == 0) {
 								State.variables.RETSevent.push("anal cowgirl");
@@ -5533,7 +5533,7 @@ if(eventSlave.fetish != "mindbroken") {
 			}
 		}
 
-		if(eventSlave.releaseRules == "restrictive") {
+		if (eventSlave.releaseRules == "restrictive" || eventSlave.releaseRules != "chastity") {
 			if(eventSlave.need) {
 				if(eventSlave.devotion <= 95) {
 					if(eventSlave.trust >= -20) {
@@ -5550,7 +5550,7 @@ if(eventSlave.fetish != "mindbroken") {
 			}
 		}
 
-		if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+		if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 			if(canPenetrate(eventSlave)) {
 				State.variables.RESSevent.push("slave dick on slave");
 			}
@@ -5953,7 +5953,7 @@ if(eventSlave.fetish != "mindbroken") {
 		}
 	}
 
-	if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+	if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 		if(eventSlave.clit > 2) {
 			State.variables.RESSevent.push("slave clit on slave");
 		}
@@ -6241,7 +6241,7 @@ if(eventSlave.fetish != "mindbroken") {
 						if(eventSlave.energy > 40) {
 							if(canPenetrate(eventSlave)) {
 								if(canSee(eventSlave)) {
-									if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+									if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 										State.variables.RETSevent.push("interslave begging");
 									}
 								}
@@ -6258,7 +6258,7 @@ if(eventSlave.fetish != "mindbroken") {
 							if(eventSlave.belly < 100000) {
 								if(eventSlave.lactation) {
 									if(eventSlave.nipples != "fuckable") {
-										if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+										if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 											State.variables.RETSevent.push("incestuous nursing");
 										}
 									}
@@ -6942,7 +6942,7 @@ if(eventSlave.fetish != "mindbroken") {
 			}
 		}
 
-		if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+		if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 			if(canPenetrate(eventSlave)) {
 				State.variables.RESSevent.push("slave dick on slave");
 			}
@@ -7161,7 +7161,7 @@ if(eventSlave.fetish != "mindbroken") {
 		}
 	}
 
-	if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+	if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 		if(eventSlave.clit > 2) {
 			State.variables.RESSevent.push("slave clit on slave");
 		}
@@ -21801,6 +21801,9 @@ window.SlaveSummaryUncached = (function(){
 			case "masturbation":
 				r += `<strong>MaR:M</strong>`;
 				break;
+			case "chastity":
+				r += `<strong>MaR:C</strong>`;
+				break;
 			default:
 				r += `<strong>MaR:R</strong>`;
 				break;
diff --git a/slave variables documentation - Pregmod.txt b/slave variables documentation - Pregmod.txt
index 370d2f3406a..1d5bcb2eba0 100644
--- a/slave variables documentation - Pregmod.txt	
+++ b/slave variables documentation - Pregmod.txt	
@@ -2212,6 +2212,7 @@ releaseRules:
 "sapphic"
 "masturbation"
 "restrictive"
+"chastity"
 
 relationshipRules:
 
diff --git a/src/facilities/nursery/childInteract.tw b/src/facilities/nursery/childInteract.tw
index 8587c55deb7..4efaca4cde3 100644
--- a/src/facilities/nursery/childInteract.tw
+++ b/src/facilities/nursery/childInteract.tw
@@ -1240,6 +1240,7 @@ Typical reward: ''<span id="standardReward">$activeSlave.standardReward</span>.'
 	<<link "Restrict $him to masturbation only">><<set $activeSlave.releaseRules = "masturbation">><<replace "#releaseRules">>$activeSlave.releaseRules<</replace>><</link>> |
 <</if>>
 <<link "Only with you">><<set $activeSlave.releaseRules = "restrictive">><<replace "#releaseRules">>$activeSlave.releaseRules<</replace>><</link>>
+<<link "Have $him remain chaste">><<set $activeSlave.releaseRules = "chastity">><<replace "#releaseRules">>$activeSlave.releaseRules<</replace>><</link>>
 
 <<if $activeSlave.clitPiercing == 3>>
 	<br>&nbsp;&nbsp;&nbsp;&nbsp;
diff --git a/src/facilities/nursery/longChildDescription.tw b/src/facilities/nursery/longChildDescription.tw
index 633d4fceace..f2a408aca9b 100644
--- a/src/facilities/nursery/longChildDescription.tw
+++ b/src/facilities/nursery/longChildDescription.tw
@@ -1632,7 +1632,7 @@ $He is
 		$He has a large, liver-colored birthmark, detracting from $his beauty.
 	<</if>>
 	<<if ($activeSlave.skin == "tanned") && ($activeSlave.origSkin != "tanned")>>
-		<<if ($activeSlave.releaseRules != "restrictive" && $activeSlave.releaseRules != "masturbation")>>
+		<<if ($activeSlave.releaseRules != "restrictive" && $activeSlave.releaseRules != "masturbation" && $activeSlave.releaseRules != "chastity")>>
 			<<if ($activeSlave.fetishStrength > 60) && ($activeSlave.fetishKnown == 1)>>
 				$His tan is slightly uneven, since $he enjoys
 				<<if ($activeSlave.fetish == "buttslut")>>
diff --git a/src/js/eventSelectionJS.tw b/src/js/eventSelectionJS.tw
index 599682f4317..0a88f3f58ee 100644
--- a/src/js/eventSelectionJS.tw
+++ b/src/js/eventSelectionJS.tw
@@ -22,7 +22,7 @@ if(eventSlave.fetish != "mindbroken") {
 						if(eventSlave.energy > 40) {
 							if(canPenetrate(eventSlave)) {
 								if(canSee(eventSlave)) {
-									if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+									if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 										State.variables.RETSevent.push("interslave begging");
 									}
 								}
@@ -39,7 +39,7 @@ if(eventSlave.fetish != "mindbroken") {
 							if(eventSlave.belly < 100000) {
 								if(eventSlave.lactation) {
 									if(eventSlave.nipples != "fuckable") {
-										if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+										if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 											State.variables.RETSevent.push("incestuous nursing");
 										}
 									}
@@ -49,7 +49,7 @@ if(eventSlave.fetish != "mindbroken") {
 					}
 				}
 			} else {
-				if(eventSlave.devotion > 20 && (eventSlave.sexualQuirk == "perverted" || eventSlave.energy > 80) && eventSlave.belly < 100000 && eventSlave.lactation > 0 && eventSlave.nipples != "fuckable" && eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.daughters > 0) {
+				if (eventSlave.devotion > 20 && (eventSlave.sexualQuirk == "perverted" || eventSlave.energy > 80) && eventSlave.belly < 100000 && eventSlave.lactation > 0 && eventSlave.nipples != "fuckable" && eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity" && eventSlave.daughters > 0) {
 					State.variables.RETSevent.push("incestuous nursing");
 				}
 			}
@@ -252,7 +252,7 @@ if(eventSlave.fetish != "mindbroken") {
 
 			if(State.variables.REAnalCowgirlSubIDs.length > 1 || (State.variables.REAnalCowgirlSubIDs.length == 1 && eventSlave.ID != State.variables.REAnalCowgirlSubIDs[0])) {
 				if(eventSlave.devotion > 20) {
-					if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+					if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 						if(eventSlave.fetish == "buttslut" || eventSlave.fetish == "sadist" || eventSlave.fetish == "dom") {
 							if((eventSlave.dickAccessory != "chastity" && eventSlave.dickAccessory != "combined chastity") || eventSlave.dick == 0) {
 								State.variables.RETSevent.push("anal cowgirl");
@@ -1177,7 +1177,7 @@ if(eventSlave.fetish != "mindbroken") {
 			}
 		}
 
-		if(eventSlave.releaseRules == "restrictive") {
+		if (eventSlave.releaseRules == "restrictive" || eventSlave.releaseRules == "chastity") {
 			if(eventSlave.need) {
 				if(eventSlave.devotion <= 95) {
 					if(eventSlave.trust >= -20) {
@@ -1194,7 +1194,7 @@ if(eventSlave.fetish != "mindbroken") {
 			}
 		}
 
-		if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+		if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 			if(canPenetrate(eventSlave)) {
 				State.variables.RESSevent.push("slave dick on slave");
 			}
@@ -1597,13 +1597,13 @@ if(eventSlave.fetish != "mindbroken") {
 		}
 	}
 
-	if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+	if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 		if(eventSlave.clit > 2) {
 			State.variables.RESSevent.push("slave clit on slave");
 		}
 	}
 
-	if(eventSlave.releaseRules != "restrictive") {
+	if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "chastity") {
 		if(eventSlave.dick > 4) {
 			if(eventSlave.amp != 1){
 				if(canAchieveErection(eventSlave)) {
@@ -1625,7 +1625,7 @@ if(eventSlave.fetish != "mindbroken") {
 		}
 	}
 
-	if(eventSlave.releaseRules != "restrictive") {
+	if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "chastity") {
 		if(eventSlave.belly < 300000) {
 			if(eventSlave.anus > 2) {
 				if(eventSlave.fetish == "buttslut" || eventSlave.energy > 95) {
@@ -1885,7 +1885,7 @@ if(eventSlave.fetish != "mindbroken") {
 						if(eventSlave.energy > 40) {
 							if(canPenetrate(eventSlave)) {
 								if(canSee(eventSlave)) {
-									if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+									if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 										State.variables.RETSevent.push("interslave begging");
 									}
 								}
@@ -1902,7 +1902,7 @@ if(eventSlave.fetish != "mindbroken") {
 							if(eventSlave.belly < 100000) {
 								if(eventSlave.lactation) {
 									if(eventSlave.nipples != "fuckable") {
-										if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+										if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 											State.variables.RETSevent.push("incestuous nursing");
 										}
 									}
@@ -1912,7 +1912,7 @@ if(eventSlave.fetish != "mindbroken") {
 					}
 				}
 			} else {
-				if(eventSlave.devotion > 20 && (eventSlave.sexualQuirk == "perverted" || eventSlave.energy > 80) && eventSlave.belly < 100000 && eventSlave.lactation > 0 && eventSlave.nipples != "fuckable" && eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.daughters > 0) {
+				if (eventSlave.devotion > 20 && (eventSlave.sexualQuirk == "perverted" || eventSlave.energy > 80) && eventSlave.belly < 100000 && eventSlave.lactation > 0 && eventSlave.nipples != "fuckable" && eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity" && eventSlave.daughters > 0) {
 					State.variables.RETSevent.push("incestuous nursing");
 				}
 			}
@@ -2586,7 +2586,7 @@ if(eventSlave.fetish != "mindbroken") {
 			}
 		}
 
-		if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+		if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 			if(canPenetrate(eventSlave)) {
 				State.variables.RESSevent.push("slave dick on slave");
 			}
@@ -2805,7 +2805,7 @@ if(eventSlave.fetish != "mindbroken") {
 		}
 	}
 
-	if(eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation") {
+	if (eventSlave.releaseRules != "restrictive" && eventSlave.releaseRules != "masturbation" && eventSlave.releaseRules != "chastity") {
 		if(eventSlave.clit > 2) {
 			State.variables.RESSevent.push("slave clit on slave");
 		}
diff --git a/src/js/slaveSummaryWidgets.tw b/src/js/slaveSummaryWidgets.tw
index 2957128b33e..58a2abe9d36 100644
--- a/src/js/slaveSummaryWidgets.tw
+++ b/src/js/slaveSummaryWidgets.tw
@@ -403,6 +403,9 @@ window.SlaveSummaryUncached = (function(){
 			case "masturbation":
 				r += `<strong>MaR:M</strong>`;
 				break;
+			case "chastity":
+				r += `<strong>MaR:C</strong>`;
+				break;
 			default:
 				r += `<strong>MaR:R</strong>`;
 				break;
diff --git a/src/pregmod/organFarmOptions.tw b/src/pregmod/organFarmOptions.tw
index d323e60acc7..6c7aa753471 100644
--- a/src/pregmod/organFarmOptions.tw
+++ b/src/pregmod/organFarmOptions.tw
@@ -186,6 +186,7 @@ The fabricator is ready to grow an organ for $him. Extract tissue to begin growi
 		<<goto "Remote Surgery">>
 	<</link>> //Costs <<print cashFormat(10000)>> and requires a vagina for successful implantation//
 <</if>>
+/*
 <<if $animalOvaries != 0>>
 	<<if $slaveOrgans.pigOvaries != 1>>
 		<br>&nbsp;&nbsp;&nbsp;&nbsp;
@@ -228,6 +229,7 @@ The fabricator is ready to grow an organ for $him. Extract tissue to begin growi
 		<</link>> //Costs <<print cashFormat(10000)>> and requires a vagina for successful implantation//
 	<</if>>
 <</if>>
+*/
 <<if $youngerOvaries == 1>>
 	<<if $slaveOrgans.freshOvaries != 1>>
 		<br>&nbsp;&nbsp;&nbsp;&nbsp;
@@ -287,6 +289,7 @@ The fabricator is ready to grow an organ for $him. Extract tissue to begin growi
 			<<goto "Remote Surgery">>
 		<</link>> //Costs <<print cashFormat(20000)>> and the slave must not have female reproductive organs for successful implantation//
 	<</if>>
+	/*
 	<<if $animalMpreg != 0>>
 		<<if $slaveOrgans.mpregPig != 1>>
 			<br>&nbsp;&nbsp;&nbsp;&nbsp;
@@ -328,6 +331,7 @@ The fabricator is ready to grow an organ for $him. Extract tissue to begin growi
 				<<goto "Remote Surgery">>
 			<</link>> //Costs <<print cashFormat(20000)>> and the slave must not have female reproductive organs for successful implantation//
 		<</if>>
+		*/
 	<</if>>
 <</if>>
 
diff --git a/src/pregmod/widgets/deathWidgets.tw b/src/pregmod/widgets/deathWidgets.tw
index f7a18e17ed4..03905d29ce2 100644
--- a/src/pregmod/widgets/deathWidgets.tw
+++ b/src/pregmod/widgets/deathWidgets.tw
@@ -35,7 +35,7 @@ As $args[0].slaveName is going about $his business with $his overfilled $args[0]
 		<<elseif _deathSeed > 25>>
 			$He is found dead in the showers, having slipped sometime earlier.
 		<<else>>
-			<<if $args[0].releaseRules != "restrictive" && $args[0].releaseRules != "masturbation">>
+			<<if $args[0].releaseRules != "restrictive" && $args[0].releaseRules != "masturbation" && $args[0].releaseRules != "chastity">>
 				$He is found dead in the bed of another slave, having died during intercourse. $His lover is not taking it well.
 			<<else>>
 				$He is found dead in the cafeteria, having died during breakfast; $he ruined the day for a number of your slaves.
diff --git a/src/uncategorized/RESS.tw b/src/uncategorized/RESS.tw
index f03d8fff3c6..94514109c85 100644
--- a/src/uncategorized/RESS.tw
+++ b/src/uncategorized/RESS.tw
@@ -18719,7 +18719,7 @@ You tell her kindly that you understand, and that $he'll be trained to address t
 		<<if $activeSlave.belly >= 10000>> You spread your legs as you shift into a more comfortable position, stealthily showing mercy since $he can't possibly keep her <<if $activeSlave.bellyPreg >= 3000>>full-term belly<<else>>_belly belly<</if>> off you otherwise.<</if>> $He bobs up and down, getting you off without ever touching you<<if $PC.dick == 1>>, other than the contact between your penis and the inside of $his body, of course<</if>>.
 		<<if $activeSlave.energy > 80>>
 			$He has such a powerful sex drive that even this sterile intercourse brings $him to orgasm.
-		<<elseif $activeSlave.releaseRules == "restrictive">>
+		<<elseif $activeSlave.releaseRules == "restrictive" || $activeSlave.releaseRules == "chastity">>
 			$He obeys the rules about orgasm and hasn't gotten off as part of her assignment recently, so $he orgasms despite the sterility of the intercourse.
 		<<else>>
 			$He does not orgasm, serving you properly and showing appropriate disregard for her own pleasure.
diff --git a/src/uncategorized/longSlaveDescription.tw b/src/uncategorized/longSlaveDescription.tw
index 3fd698baf33..e0e97a683ae 100644
--- a/src/uncategorized/longSlaveDescription.tw
+++ b/src/uncategorized/longSlaveDescription.tw
@@ -294,6 +294,8 @@ is
 			<</if>>
 		<<elseif $activeSlave.releaseRules == "permissive">>
 			and $he is allowed to masturbate.
+		<<elseif $activeSlave.releaseRules == "chastity">>
+			and $he is to remain completely chaste.
 		<</if>>
 	<</if>>
 
@@ -2021,7 +2023,7 @@ $He is
 		$He has a large, liver-colored birthmark, detracting from $his beauty.
 	<</if>>
 	<<if ($activeSlave.skin == "tanned") && ($activeSlave.origSkin != "tanned")>>
-		<<if ($activeSlave.releaseRules != "restrictive" && $activeSlave.releaseRules != "masturbation")>>
+		<<if ($activeSlave.releaseRules != "restrictive" && $activeSlave.releaseRules != "masturbation" && $activeSlave.releaseRules != "chastity")>>
 			<<if ($activeSlave.fetishStrength > 60) && ($activeSlave.fetishKnown == 1)>>
 				$His tan is slightly uneven, since $he enjoys
 				<<if ($activeSlave.fetish == "buttslut")>>
diff --git a/src/uncategorized/randomIndividualEvent.tw b/src/uncategorized/randomIndividualEvent.tw
index 75978ee01a4..fd6a5971334 100644
--- a/src/uncategorized/randomIndividualEvent.tw
+++ b/src/uncategorized/randomIndividualEvent.tw
@@ -69,7 +69,7 @@
 							<<if $slaves[$i].boobs > 3000>>
 								<<set $REBoobCollisionSubIDs.push($slaves[$i].ID)>>
 							<</if>>
-							<<if $slaves[$i].releaseRules != "restrictive" && $slaves[$i].releaseRules != "masturbation">>
+							<<if $slaves[$i].releaseRules != "restrictive" && $slaves[$i].releaseRules != "masturbation" && $slaves[$i].releaseRules != "chastity">>
 								<<if $slaves[$i].energy > 40>>
 									<<if canDoVaginal($slaves[$i]) || canDoAnal($slaves[$i])>>
 										<<set $REInterslaveBeggingIDs.push($slaves[$i].ID)>>
diff --git a/src/uncategorized/reStandardPunishment.tw b/src/uncategorized/reStandardPunishment.tw
index 7e625f7dbff..aac9aba41d8 100644
--- a/src/uncategorized/reStandardPunishment.tw
+++ b/src/uncategorized/reStandardPunishment.tw
@@ -42,7 +42,7 @@
 	<</if>>
 <<else>>
 	<<if $activeSlave.energy > 40>>
-	<<if $activeSlave.releaseRules != "restrictive" && $activeSlave.releaseRules != "masturbation">>
+	<<if $activeSlave.releaseRules != "restrictive" && $activeSlave.releaseRules != "masturbation" && $activeSlave.releaseRules != "chastity">>
 		<<set _sins.push("slave molestation")>>
 	<</if>>
 	<</if>>
diff --git a/src/uncategorized/saRelationships.tw b/src/uncategorized/saRelationships.tw
index 77db8f24084..f0a4a52b377 100644
--- a/src/uncategorized/saRelationships.tw
+++ b/src/uncategorized/saRelationships.tw
@@ -182,7 +182,7 @@
 					<</if>>
 					<</if>>
 				<<elseif mutualChildren(_SlaveI, _SlaveJ, $slaves) > 0>>
-					<<if (_SlaveI.releaseRules != "restrictive") && _SlaveI.releaseRules != "masturbation">>
+					<<if (_SlaveI.releaseRules != "restrictive") && _SlaveI.releaseRules != "masturbation" && _SlaveI.releaseRules != "chastity">>
 						<<if _SlaveJ.relationshipRules == "permissive">>
 							_SlaveI.slaveName and _SlaveJ.slaveName have <<if mutualChildren(_SlaveI, _SlaveJ, $slaves) == 0>>a child<<else>>children<</if>> living in your penthouse, so it's not surprising that their offspring brings them together. They have @@.lightgreen;become friends@@ for their child's sake.
 							<<set _SlaveJ.relationship = 1, _SlaveJ.relationshipTarget = _SlaveI.ID, _SlaveI.relationship = 1, _SlaveI.relationshipTarget = _SlaveJ.ID>>
@@ -193,7 +193,7 @@
 						<</if>>
 					<</if>>
 				<<elseif _SlaveJ.fetish == _SlaveI.fetish>>
-					<<if (_SlaveI.fetish != "none") && (_SlaveI.releaseRules != "restrictive") && _SlaveI.releaseRules != "masturbation">>
+					<<if (_SlaveI.fetish != "none") && (_SlaveI.releaseRules != "restrictive") && _SlaveI.releaseRules != "masturbation" _SlaveI.releaseRules != "chastity">>
 						<<if _SlaveJ.relationshipRules == "permissive">>
 							_SlaveI.slaveName and _SlaveJ.slaveName share sexual inclinations, so it's only natural that they @@.lightgreen;become friends with benefits.@@
 							<<set _SlaveJ.relationship = 3, _SlaveJ.relationshipTarget = _SlaveI.ID, _SlaveI.relationship = 3, _SlaveI.relationshipTarget = _SlaveJ.ID>>
@@ -1341,7 +1341,7 @@
 			<</if>>
 		<</if>> /* closes extended family mode */
 
-		<<if _SlaveI.releaseRules != "restrictive" && _SlaveI.releaseRules != "masturbation">>
+		<<if _SlaveI.releaseRules != "restrictive" && _SlaveI.releaseRules != "masturbation" && _SlaveI.releaseRules != "chastity">>
 			<<if (_SlaveI.sexualQuirk == "size queen") && (canPenetrate(_SlaveJ))>>
 			<<if _SlaveJ.dick > 5>>
 				She's @@.hotpink;very happy@@ with her romantic status, since it means she gets monster cock.
diff --git a/src/uncategorized/saRivalries.tw b/src/uncategorized/saRivalries.tw
index 189c5c51fb2..f256937b04a 100644
--- a/src/uncategorized/saRivalries.tw
+++ b/src/uncategorized/saRivalries.tw
@@ -147,7 +147,7 @@
 	<<else>>
 		<<if $slaves[$i].need>>
 			<<if $universalRulesConsent == 0>>
-				<<if $slaves[$i].releaseRules != "restrictive" && $slaves[$i].releaseRules != "masturbation">>
+				<<if $slaves[$i].releaseRules != "restrictive" && $slaves[$i].releaseRules != "masturbation" && $slaves[$i].releaseRules != "chastity">>
 					<<if $slaves[_j].releaseRules != "restrictive">>
 						<<if $slaves[$i].fetishKnown>>
 							<<if $slaves[$i].fetish == "sadist">>
diff --git a/src/uncategorized/saRules.tw b/src/uncategorized/saRules.tw
index 3cabb32a9f8..981d850ef0b 100644
--- a/src/uncategorized/saRules.tw
+++ b/src/uncategorized/saRules.tw
@@ -22,7 +22,7 @@
 						<<set $slaves[$i].trust -= 1>>
 					<</if>>
 					<<set $slaves[$i].need -= 20>>
-				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off at work, so being unable to sate $his urges doesn't affect $him seriously.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -46,7 +46,7 @@
 				is frigid and has little interest in getting off<<if ($slaves[$i].releaseRules != "permissive")>>, making the rule restricting $his sexual outlets superfluous<</if>>.	
 				<<set $slaves[$i].need = 0>>
 			<<elseif $slaves[$i].need < $slaves[$i].energy*0.5>>
-				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off at work, so being forbidden from masturbation doesn't really bother $him.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -190,7 +190,7 @@
 						<<set $slaves[$i].trust -= 1>>
 					<</if>>
 					<<set $slaves[$i].need -= 20>>
-				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off at work, so being forbidden to masturbate doesn't affect $him seriously.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -513,7 +513,7 @@
 				is frigid and has little interest in getting off<<if ($slaves[$i].releaseRules != "permissive")>>, making the rule restricting $his sexual outlets superfluous<</if>>.	
 				<<set $slaves[$i].need = 0>>
 			<<elseif $slaves[$i].need < $slaves[$i].energy*0.5>>
-				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off at work, so being forbidden from masturbation doesn't really bother $him.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -665,7 +665,7 @@
 						<<set $slaves[$i].trust -= 1>>
 					<</if>>
 					<<set $slaves[$i].need -= 20>>
-				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off at work, so being forbidden to masturbate doesn't affect $him seriously.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -961,7 +961,7 @@
 				is frigid and has little interest in getting off<<if ($slaves[$i].releaseRules != "permissive")>>, making the rule restricting $his sexual outlets superfluous<</if>>.	
 				<<set $slaves[$i].need = 0>>
 			<<elseif $slaves[$i].need < $slaves[$i].energy*0.5>>
-				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off at work, so being forbidden from masturbation doesn't really bother $him.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -1590,7 +1590,7 @@
 				is frigid and has little interest in getting off<<if ($slaves[$i].releaseRules != "permissive")>>, making the rule restricting $his sexual outlets superfluous<</if>>.	
 				<<set $slaves[$i].need = 0>>
 			<<elseif $slaves[$i].need < $slaves[$i].energy*0.5>>
-				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off while relieving $his charges, so being forbidden from masturbation doesn't really bother $him.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -2069,7 +2069,7 @@
 				is frigid and has little interest in getting off<<if ($slaves[$i].releaseRules != "permissive")>>, making the rule restricting $his sexual outlets superfluous<</if>>.	
 				<<set $slaves[$i].need = 0>>
 			<<elseif $slaves[$i].need < $slaves[$i].energy*0.5>>
-				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off while relieving $his charges, so being forbidden from masturbation doesn't really bother $him.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -2564,7 +2564,7 @@
 				is frigid and has little interest in getting off<<if ($slaves[$i].releaseRules != "permissive")>>, making the rule restricting $his sexual outlets superfluous<</if>>.	
 				<<set $slaves[$i].need = 0>>
 			<<elseif $slaves[$i].need < $slaves[$i].energy*0.5>>
-				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off with $his students, so being forbidden from masturbation doesn't really bother $him.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -2741,7 +2741,7 @@
 						<<set $slaves[$i].trust -= 1>>
 					<</if>>
 					<<set $slaves[$i].need -= 20>>
-				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off during class, so being forbidden to masturbate doesn't affect $him seriously.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -3035,7 +3035,7 @@
 				is frigid and has little interest in getting off<<if ($slaves[$i].releaseRules != "permissive")>>, making the rule restricting $his sexual outlets superfluous<</if>>.	
 				<<set $slaves[$i].need = 0>>
 			<<elseif $slaves[$i].need < $slaves[$i].energy*0.5>>
-				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off while performing $his duties, so being forbidden from masturbation doesn't really bother $him.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -3180,7 +3180,7 @@
 						<<set $slaves[$i].trust -= 1>>
 					<</if>>
 					<<set $slaves[$i].need -= 20>>
-				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off at work, so being forbidden to masturbate doesn't affect $him seriously.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -3508,7 +3508,7 @@
 				is frigid and has little interest in getting off<<if ($slaves[$i].releaseRules != "permissive")>>, making the rule restricting $his sexual outlets superfluous<</if>>.	
 				<<set $slaves[$i].need = 0>>
 			<<elseif $slaves[$i].need < $slaves[$i].energy*0.5>>
-				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off while performing $his duties, so being forbidden from masturbation doesn't really bother $him.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -3669,7 +3669,7 @@
 							<<set $slaves[$i].trust -= 1>>
 						<</if>>
 						<<set $slaves[$i].need -= 20>>
-					<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+					<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 						gets off from being milked, so being forbidden to masturbate doesn't affect $him seriously.
 						<<set $slaves[$i].need -= 20>>
 					<<else>>
@@ -4041,7 +4041,7 @@
 				is frigid and has little interest in getting off<<if ($slaves[$i].releaseRules != "permissive")>>, making the rule restricting $his sexual outlets superfluous<</if>>.	
 				<<set $slaves[$i].need = 0>>
 			<<elseif $slaves[$i].need < $slaves[$i].energy*0.5>>
-				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<if ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off while performing $his duties, so being forbidden from masturbation doesn't really bother $him.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -4186,7 +4186,7 @@
 						<<set $slaves[$i].trust -= 1>>
 					<</if>>
 					<<set $slaves[$i].need -= 20>>
-				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off from working as a farmhand, so being forbidden to masturbate doesn't affect $him seriously.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -4620,7 +4620,7 @@
 						<<set $slaves[$i].trust -= 1>>
 					<</if>>
 					<<set $slaves[$i].need -= 20>>
-				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off regularly, so being forbidden to masturbate doesn't affect $him seriously.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -4772,7 +4772,7 @@
 						<<set $slaves[$i].trust -= 1>>
 					<</if>>
 					<<set $slaves[$i].need -= 20>>
-				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off with $HeadGirl.slaveName, so being forbidden to masturbate doesn't affect $him seriously.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
@@ -4921,7 +4921,7 @@
 						<<set $slaves[$i].trust -= 1>>
 					<</if>>
 					<<set $slaves[$i].need -= 20>>
-				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation")>>
+				<<elseif ($slaves[$i].releaseRules != "permissive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 					gets off at work, so being forbidden to masturbate doesn't affect $him seriously.
 					<<set $slaves[$i].need -= 20>>
 				<<else>>
diff --git a/src/uncategorized/slaveAssignmentsReport.tw b/src/uncategorized/slaveAssignmentsReport.tw
index 058facc5f3c..ec39a886a71 100644
--- a/src/uncategorized/slaveAssignmentsReport.tw
+++ b/src/uncategorized/slaveAssignmentsReport.tw
@@ -27,7 +27,7 @@
 	<<set $slaves[$i].oralSkill = 0>>
 <</if>>
 
-<<if ($seeDicks > 0) && (canPenetrate($slaves[$i])) && ($slaves[$i].releaseRules != "restrictive") && ($slaves[$i].releaseRules != "masturbation")>>
+<<if ($seeDicks > 0) && (canPenetrate($slaves[$i])) && ($slaves[$i].releaseRules != "restrictive") && ($slaves[$i].releaseRules != "masturbation") && ($slaves[$i].releaseRules != "chastity")>>
 	<<set $averageDick += $slaves[$i].dick, $slavesWithWorkingDicks++>>
 <</if>>
 
diff --git a/src/uncategorized/slaveInteract.tw b/src/uncategorized/slaveInteract.tw
index 8a845c06c8a..f5f7222aad2 100644
--- a/src/uncategorized/slaveInteract.tw
+++ b/src/uncategorized/slaveInteract.tw
@@ -1608,6 +1608,7 @@ Hormones: <strong><span id="hormones">
 		<<link "Restrict $him to masturbation only">><<set $activeSlave.releaseRules = "masturbation">><<replace "#releaseRules">>$activeSlave.releaseRules<</replace>><</link>> |
 	<</if>>
 	<<link "Only with you">><<set $activeSlave.releaseRules = "restrictive">><<replace "#releaseRules">>$activeSlave.releaseRules<</replace>><</link>>
+	<<link "Have $him remain chaste">><<set $activeSlave.releaseRules = "chastity">><<replace "#releaseRules>>">>$activeSlave.releaseRules<</replace>><</link>>
 <</if>>
 
 <<if $activeSlave.clitPiercing == 3>>
diff --git a/src/uncategorized/walkPast.tw b/src/uncategorized/walkPast.tw
index 317a241563b..44e97b43540 100644
--- a/src/uncategorized/walkPast.tw
+++ b/src/uncategorized/walkPast.tw
@@ -48,7 +48,7 @@
 
 	<<= rivalSlave($activeSlave, _seed)>>
 
-<<elseif ($partner == "relationship") && ($activeSlave.relationship >= 3) && ($activeSlave.releaseRules !== "restrictive") && ($activeSlave.releaseRules !== "masturbation")>>
+<<elseif ($partner == "relationship") && ($activeSlave.relationship >= 3) && ($activeSlave.releaseRules !== "restrictive") && ($activeSlave.releaseRules !== "masturbation") ($activeSlave.releaseRules !== "chastity")>>
 	<<set _partnerSlave = getSlave($activeSlave.relationshipTarget)>>
 	<<setLocalPronouns _partnerSlave 2>>
 	<<if ndef _partnerSlave>>
-- 
GitLab