From cceb41b5302270855bae689eaf728ac184ed1713 Mon Sep 17 00:00:00 2001
From: lowercasedonkey <lowercasedonkey@gmail.com>
Date: Wed, 22 Apr 2020 18:47:27 -0400
Subject: [PATCH] sort each category smallest to largest

---
 src/interaction/slaveInteract.js | 94 ++++++++++++++++----------------
 1 file changed, 47 insertions(+), 47 deletions(-)

diff --git a/src/interaction/slaveInteract.js b/src/interaction/slaveInteract.js
index c2ad4192080..246a234f4f8 100644
--- a/src/interaction/slaveInteract.js
+++ b/src/interaction/slaveInteract.js
@@ -364,6 +364,13 @@ App.UI.SlaveInteract.drugs = function(slave) {
 		}
 
 		// Nipples
+		if (V.arcologies[0].FSSlimnessEnthusiastResearch === 1) {
+			if (slave.nipples === "huge" || slave.nipples === "puffy" || slave.nipples === "cute") {
+				nipples.push({text: `Nipple reducers`, updateSlave: {drugs: `nipple atrophiers`}});
+			} else {
+				nipples.push({text: `Nipple reducers`, disabled: `Nipples are ${slave.nipples}`});
+			}
+		}
 		if(V.dispensary) {
 			if ((["inverted", "partially inverted", "cute", "tiny", "puffy"].includes(slave.nipples))) {
 				nipples.push({text: `Nipple enhancers`, updateSlave: {drugs: `nipple enhancers`}});
@@ -373,15 +380,15 @@ App.UI.SlaveInteract.drugs = function(slave) {
 				nipples.push({text: `Nipple enhancers`, disabled: `Has no effect on ${slave.nipples} nipples`});
 			}
 		}
+
+		// Butt
 		if (V.arcologies[0].FSSlimnessEnthusiastResearch === 1) {
-			if (slave.nipples === "huge" || slave.nipples === "puffy" || slave.nipples === "cute") {
-				nipples.push({text: `Nipple reducers`, updateSlave: {drugs: `nipple atrophiers`}});
+			if (slave.butt - slave.buttImplant > 0) {
+				butt.push({text: `Butt reducers`, updateSlave: {drugs: `butt redistributors`}});
 			} else {
-				nipples.push({text: `Nipple reducers`, disabled: `Nipples are ${slave.nipples}`});
+				butt.push({text: `Butt reducers`, disabled: `Butt is too small`});
 			}
 		}
-
-		// Butt
 		if (slave.butt < 9) {
 			butt.push({text: `Buttocks`, updateSlave: {drugs: `butt injections`}});
 			butt.push({text: `Intensive Buttocks`, updateSlave: {drugs: `intensive butt injections`}});
@@ -395,20 +402,8 @@ App.UI.SlaveInteract.drugs = function(slave) {
 				butt.push({text: `Hyper Buttocks`, disabled: `Butt is too large`});
 			}
 		}
-		if (V.arcologies[0].FSSlimnessEnthusiastResearch === 1) {
-			if (slave.butt - slave.buttImplant > 0) {
-				butt.push({text: `Butt reducers`, updateSlave: {drugs: `butt redistributors`}});
-			} else {
-				butt.push({text: `Butt reducers`, disabled: `Butt is too small`});
-			}
-		}
 
 		// Lips
-		if (slave.lips <= 95 || (slave.lips <= 85 && V.seeExtreme !== 1)) {
-			lips.push({text: `Lips`, updateSlave: {drugs: `lip injections`}});
-		} else {
-			lips.push({text: `Lips`, disabled: `Lips are too large`});
-		}
 		if (V.arcologies[0].FSSlimnessEnthusiastResearch === 1) {
 			if (slave.lips - slave.lipsImplant > 0) {
 				lips.push({text: `Lip reducers`, updateSlave: {drugs: `lip atrophiers`}});
@@ -416,6 +411,11 @@ App.UI.SlaveInteract.drugs = function(slave) {
 				lips.push({text: `Lip reducers`, disabled: `Lips are too small`});
 			}
 		}
+		if (slave.lips <= 95 || (slave.lips <= 85 && V.seeExtreme !== 1)) {
+			lips.push({text: `Lips`, updateSlave: {drugs: `lip injections`}});
+		} else {
+			lips.push({text: `Lips`, disabled: `Lips are too large`});
+		}
 
 		// Fertility
 		fertility.push({text: `Fertility`, updateSlave: {drugs: `fertility drugs`}});
@@ -424,6 +424,16 @@ App.UI.SlaveInteract.drugs = function(slave) {
 		}
 
 		// Dick/clit
+		if (V.arcologies[0].FSSlimnessEnthusiastResearch === 1) {
+			if (slave.dick > 1) {
+				dick.push({text: `Penis reducers`, updateSlave: {drugs: `penis atrophiers`}});
+			} else if (slave.dick === 1) {
+				dick.push({text: `Penis reducers`, disabled: `Dick is already at minimum size`});
+			}
+			if (slave.clit > 0) {
+				dick.push({text: `Clitoris reducers`, updateSlave: {drugs: `clitoris atrophiers`}});
+			}
+		}
 		if (slave.dick > 0) {
 			if (slave.dick < 10) {
 				dick.push({text: `Penis enhancement`, updateSlave: {drugs: `penis enhancement`}});
@@ -454,28 +464,11 @@ App.UI.SlaveInteract.drugs = function(slave) {
 				}
 			}
 		}
-		if (V.arcologies[0].FSSlimnessEnthusiastResearch === 1) {
-			if (slave.dick > 1) {
-				dick.push({text: `Penis reducers`, updateSlave: {drugs: `penis atrophiers`}});
-			} else if (slave.dick === 1) {
-				dick.push({text: `Penis reducers`, disabled: `Dick is already at minimum size`});
-			}
-			if (slave.clit > 0) {
-				dick.push({text: `Clitoris reducers`, updateSlave: {drugs: `clitoris atrophiers`}});
-			}
-		}
 		if (slave.dick > 0 && slave.dick < 11 && !canAchieveErection(slave) && slave.chastityPenis !== 1) {
 			dick.push({text: `Erectile dysfunction circumvention`, updateSlave: {drugs: `priapism agents`}});
 		}
 
 		// Balls
-		if (slave.balls > 0) {
-			balls.push({text: `Testicle enhancement`, updateSlave: {drugs: `testicle enhancement`}});
-			balls.push({text: `Intensive testicle enhancement`, updateSlave: {drugs: `intensive testicle enhancement`}});
-			if (V.arcologies[0].FSAssetExpansionistResearch === 1) {
-				balls.push({text: `Hyper testicle enhancement`, updateSlave: {drugs: `hyper testicle enhancement`}});
-			}
-		}
 		if (V.arcologies[0].FSSlimnessEnthusiastResearch === 1) {
 			if (slave.balls > 1) {
 				balls.push({text: `Testicle reducers`, updateSlave: {drugs: `testicle atrophiers`}});
@@ -483,6 +476,13 @@ App.UI.SlaveInteract.drugs = function(slave) {
 				balls.push({text: `Testicle reducers`, disabled: `Balls are already at minimum size`});
 			}
 		}
+		if (slave.balls > 0) {
+			balls.push({text: `Testicle enhancement`, updateSlave: {drugs: `testicle enhancement`}});
+			balls.push({text: `Intensive testicle enhancement`, updateSlave: {drugs: `intensive testicle enhancement`}});
+			if (V.arcologies[0].FSAssetExpansionistResearch === 1) {
+				balls.push({text: `Hyper testicle enhancement`, updateSlave: {drugs: `hyper testicle enhancement`}});
+			}
+		}
 
 		// Hormones
 		if (V.precociousPuberty === 1 && V.pubertyHormones === 1 && (slave.breedingMark !== 1 || V.propOutcome === 0 || V.eugenicsFullControl === 1 || V.arcologies[0].FSRestart === "unset")) {
@@ -493,30 +493,22 @@ App.UI.SlaveInteract.drugs = function(slave) {
 				hormones.push({text: `Male hormone injections`, updateSlave: {drugs: `male hormone injections`}});
 			}
 		}
-		hormones.push({text: `Hormone enhancers`, updateSlave: {drugs: `hormone enhancers`}});
 		hormones.push({text: `Hormone blockers`, updateSlave: {drugs: `hormone blockers`}});
+		hormones.push({text: `Hormone enhancers`, updateSlave: {drugs: `hormone enhancers`}});
 
 		// Misc
-		if (V.growthStim === 1) {
-			if (canImproveHeight(slave)) {
-				misc.push({text: `Growth Stimulants`, updateSlave: {drugs: `growth stimulants`}});
-			} else {
-				misc.push({text: `Growth Stimulants`, disabled: `Cannot increase height further`});
-			}
-		}
 		if (V.arcologies[0].FSSlimnessEnthusiastResearch === 1) {
 			if (slave.labia > 0) {
 				misc.push({text: `Labia reducers`, updateSlave: {drugs: `labia atrophiers`}});
 			}
 		}
-		if (V.arcologies[0].FSYouthPreferentialistResearch === 1) {
-			if (slave.visualAge > 18) {
-				misc.push({text: `Anti-aging cream`, updateSlave: {drugs: `anti-aging cream`}});
+		if (V.growthStim === 1) {
+			if (canImproveHeight(slave)) {
+				misc.push({text: `Growth Stimulants`, updateSlave: {drugs: `growth stimulants`}});
 			} else {
-				misc.push({text: `Anti-aging cream`, disabled: `Slave already looks young enough`});
+				misc.push({text: `Growth Stimulants`, disabled: `Cannot increase height further`});
 			}
 		}
-		misc.push({text: `Steroids`, updateSlave: {drugs: `steroids`}});
 		if (V.arcologies[0].FSSlimnessEnthusiastResearch === 1) {
 			if (slave.weight > -95) {
 				misc.push({text: `Weight loss pills`, updateSlave: {drugs: `appetite suppressors`}});
@@ -524,9 +516,17 @@ App.UI.SlaveInteract.drugs = function(slave) {
 				misc.push({text: `Weight loss pills`, disabled: `Slave is already at low weight`});
 			}
 		}
+		misc.push({text: `Steroids`, updateSlave: {drugs: `steroids`}});
 		if (slave.boobs > 250 && slave.boobShape !== "saggy" && V.purchasedSagBGone === 1) {
 			misc.push({text: `Sag-B-Gone breast lifting cream`, updateSlave: {drugs: `sag-B-gone`}});
 		}
+		if (V.arcologies[0].FSYouthPreferentialistResearch === 1) {
+			if (slave.visualAge > 18) {
+				misc.push({text: `Anti-aging cream`, updateSlave: {drugs: `anti-aging cream`}});
+			} else {
+				misc.push({text: `Anti-aging cream`, disabled: `Slave already looks young enough`});
+			}
+		}
 	}
 
 	let title = document.createElement('div');
-- 
GitLab