From a70d009609955fb7693ea9ee758eb147f8f2db5d Mon Sep 17 00:00:00 2001
From: j <okp57855@psoxs.com>
Date: Sat, 31 Mar 2018 21:11:22 +1300
Subject: [PATCH] Additional MoreSugarCube.State's caught.

---
 src/pregmod/editGenetics.tw      | 2 +-
 src/uncategorized/wardrobeUse.tw | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/pregmod/editGenetics.tw b/src/pregmod/editGenetics.tw
index 171bd10489c..bcd746c7ac7 100644
--- a/src/pregmod/editGenetics.tw
+++ b/src/pregmod/editGenetics.tw
@@ -191,7 +191,7 @@
 		if(id === 0) { return '<i>unknown</i>'; }
 		if(id === -1) {
 			/* The PC */
-			return tmpl.birthFullName(SugarCube.State.variables.PC) + ' (PC)';
+			return tmpl.birthFullName(State.variables.PC) + ' (PC)';
 		} else {
 			var parent = SugarCube.State.variables.genePool.find(function(s) { return s.ID === id; });
 			return (parent ? tmpl.birthFullName(parent) : '<i>missing</i>') + ' (' + id + ')';
diff --git a/src/uncategorized/wardrobeUse.tw b/src/uncategorized/wardrobeUse.tw
index 21166aaaa22..2ba5d839121 100644
--- a/src/uncategorized/wardrobeUse.tw
+++ b/src/uncategorized/wardrobeUse.tw
@@ -319,7 +319,7 @@ Clothes: ''<span id="clothes">$activeSlave.clothes</span>.''
 	<</if>>
 	/* Display an HTML5 color picker */
 	/* This is hackish due to direct accessment of SugarCube internal data structure. Improvements are welcome. */
-	<<print '<input type="color" value="'+_clothingBaseColor+'" onInput="SugarCube.State.variables.activeSlave.clothingBaseColor = event.target.value;">'>>
+	<<print '<input type="color" value="'+_clothingBaseColor+'" onInput="State.variables.activeSlave.clothingBaseColor = event.target.value;">'>>
 	<<link "use default color">>
 		<<run delete $activeSlave.clothingBaseColor >>
 		/* reload passage to display everything correctly */
@@ -501,7 +501,7 @@ Clothes: ''<span id="clothes">$activeSlave.clothes</span>.''
 	<</if>>
 	/* Display an HTML5 color picker */
 	/* This is hackish due to direct accessment of SugarCube internal data structure. Improvements are welcome. */
-	<<print '<input type="color" value="'+_shoeColour+'" onInput="SugarCube.State.variables.activeSlave.shoeColor = event.target.value;">'>>
+	<<print '<input type="color" value="'+_shoeColour+'" onInput="State.variables.activeSlave.shoeColor = event.target.value;">'>>
 	<<link "use default color">>
 		<<run delete $activeSlave.shoeColor >>
 		/* reload passage to display everything correctly */
-- 
GitLab