From 5ff171b50a354ed17454cb0bdec483f90f8ea366 Mon Sep 17 00:00:00 2001
From: Trashman1138 <11461-Trashman1138@users.noreply.gitgud.io>
Date: Wed, 3 Jul 2019 19:34:07 -0700
Subject: [PATCH] Well hung quirk assignment made gender-flipped mirror image
 of fertility quirk assignment.

---
 src/js/generateGenetics.js | 45 ++++++++++++++++++--------------------
 1 file changed, 21 insertions(+), 24 deletions(-)

diff --git a/src/js/generateGenetics.js b/src/js/generateGenetics.js
index 58ed075e216..e5772686d4b 100644
--- a/src/js/generateGenetics.js
+++ b/src/js/generateGenetics.js
@@ -715,7 +715,7 @@ window.generateGenetics = (function() {
 		// Normal male, carrier female:				50% of daughters carriers,	50% of sons carriers						genetotal 1
 		// Carrier male, normal female:				100% of daughters carriers, sons normal									genetotal 1
 		
-		// Sex-linked traits (fertility-affecting, well-hung) left handled by the old method
+		// Sex-linked traits (fertility-affecting, well-hung) left handled by the old method; latter made mirror image to former.
 		
 		// fertility
 		if (mother.geneticQuirks.fertility === 2) {
@@ -833,29 +833,26 @@ window.generateGenetics = (function() {
 
 		// well hung
 		if (father !== 0) {
-			if (mother.geneticQuirks.wellHung + father.geneticQuirks.wellHung >= 3) {
-				if (sex === "XY") {
-					quirks.wellHung = 2;
-				} else {
-					quirks.wellHung = 1;
-				}
-			} else if (mother.geneticQuirks.wellHung + father.geneticQuirks.wellHung >= 1) {
-				chance = jsRandom(0, 1000);
-				if (chance > 750) {
-					quirks.wellHung = 1;
-				}
-			}
-		} else if (mother.geneticQuirks.wellHung === 2) {
-			chance = jsRandom(0, 1000);
-			if (sex === "XY") {
-				if (chance > 900) {
-					quirks.wellHung = 2;
-				} else if (chance > 200) {
-					quirks.wellHung = 1;
-				}
-			} else {
-				if (chance > 500) {
-					quirks.wellHung = 1;
+		    if (father.geneticQuirks.wellHung === 2) {
+			    if (sex === "XY") {
+    				quirks.wellHung = 2;
+			    } else {
+				    quirks.wellHung = 1;
+			    }
+		    } else if (father.geneticQuirks.wellHung === 1) {
+			    chance = jsRandom(0, 1000);
+				if (mother.geneticQuirks.wellHung >= 1) {
+					if (sex === "XY") {
+						if (chance > 750) {
+							quirks.wellHung = 2;
+						} else if (chance > 700) {
+							quirks.wellHung = 1;
+						}
+					} else {
+						if (chance > 700) {
+							quirks.wellHung = 1;
+						}
+					}
 				}
 			}
 		}
-- 
GitLab