From 45e8cc20d845dded29601c725d49628fa24413a5 Mon Sep 17 00:00:00 2001 From: klorpa <30924131+klorpa@users.noreply.github.com> Date: Sat, 30 Mar 2019 12:48:01 -0500 Subject: [PATCH] WorksGood --- src/js/rulesAssistantOptions.js | 2 + src/js/utilJS.js | 2 +- src/uncategorized/BackwardsCompatibility.tw | 2 +- src/uncategorized/RESS.tw | 2 + src/uncategorized/salon.tw | 75 +++++++++++---------- src/utility/descriptionWidgetsStyle.tw | 2 +- 6 files changed, 45 insertions(+), 40 deletions(-) diff --git a/src/js/rulesAssistantOptions.js b/src/js/rulesAssistantOptions.js index 7d49049dce1..af2198d9ac8 100644 --- a/src/js/rulesAssistantOptions.js +++ b/src/js/rulesAssistantOptions.js @@ -3667,6 +3667,8 @@ window.rulesAssistantOptions = (function() { ["black"], ["ebony"], ["pure black"], + ["sun tanned"], + ["spray tanned"], ["dyed red"], ["dyed green"], ["dyed blue"], diff --git a/src/js/utilJS.js b/src/js/utilJS.js index 6a246ad8819..930d58a6c24 100644 --- a/src/js/utilJS.js +++ b/src/js/utilJS.js @@ -1620,7 +1620,7 @@ window.randomRaceHair = function(raceName) { window.skinToneLevel = function(skinTone) { if (!setup.naturalSkins.includes(skinTone)) { - return null; + return undefined; } else { let skinNumber; let skinToMelanin = { diff --git a/src/uncategorized/BackwardsCompatibility.tw b/src/uncategorized/BackwardsCompatibility.tw index 39c4acb81a7..437ae410e82 100644 --- a/src/uncategorized/BackwardsCompatibility.tw +++ b/src/uncategorized/BackwardsCompatibility.tw @@ -2814,7 +2814,7 @@ Setting missing slave variables: <<case "bronzed">> <<set _Slave.skin = "bronze">> <<case "darkened">> - <<set _Slave.skin = "olive">> + <<set _Slave.skin = "dark">> <<case "natural">> <</switch>> diff --git a/src/uncategorized/RESS.tw b/src/uncategorized/RESS.tw index 213b25c4ca7..44756a6f6ad 100644 --- a/src/uncategorized/RESS.tw +++ b/src/uncategorized/RESS.tw @@ -428,6 +428,8 @@ It's an unusually nice day, with mild sunshine, light breezes, and nothing offen $His $activeSlave.skin doesn't tan much, so $he's just out here to bask in its warmth. $His body shines with lotion from a bottle lying next to $him, but it's just general-purpose stuff. <<elseif ($activeSlave.skin == "sun tanned")>> $His tanned skin shines with lotion from a bottle lying next to $him. +<<elseif ($activeSlave.skin == "spray tanned")>> + Since $is fake tan would otherwise be (rather ironically) ruined by the sun, $his skin shines with sunblock lotion from a bottle lying next to $him. <<else>> $His skin shines with sunblock lotion from a bottle lying next to $him. It would be foolish of $him to let the sun ruin $his $activeSlave.skin skin. <</if>> diff --git a/src/uncategorized/salon.tw b/src/uncategorized/salon.tw index a8781fe938c..5cb722470de 100644 --- a/src/uncategorized/salon.tw +++ b/src/uncategorized/salon.tw @@ -607,10 +607,6 @@ Treat nails: <</if>> /* SKIN */ -<<set $darkenableSkin = ["pure white", "ivory", "white", "extremely pale", "very pale", "pale", "extremely fair", "very fair", "fair", "light", "light olive", "tan", "olive", "bronze", "dark olive"]>> -<<set $lightenableSkin = ["light", "light olive", "tan", "olive", "bronze", "dark olive", "dark", "light beige", "beige", "dark beige", "light brown", "brown", "dark brown", "black", "ebony", "pure black"]>> -<<set $bleachableSkin = ["ivory", "white", "extremely pale", "very pale", "pale", "extremely fair", "very fair", "fair", "light", "light olive", "tan", "olive", "bronze", "dark olive", "dark", "light beige", "beige", "dark beige", "light brown", "brown", "dark brown", "black", "ebony", "pure black"]>> -<<set $blackenableSkin = ["pure white", "ivory", "white", "extremely pale", "very pale", "pale", "extremely fair", "very fair", "fair", "light", "light olive", "tan", "olive", "bronze", "dark olive", "dark", "light beige", "beige", "dark beige", "light brown", "brown", "dark brown", "black", "ebony"]>> <<set $dyedSkin = ["dyed red", "dyed green", "dyed blue", "dyed pink", "dyed gray", "tiger striped", "camouflage patterned"]>> <br><br> @@ -618,48 +614,53 @@ $His skin is $activeSlave.skin. <<if ($dyedSkin.indexOf($activeSlave.skin) != -1)>> [[Remove coloring|Salon][$activeSlave.skin = $activeSlave.origSkin,cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] +<<elseif (($activeSlave.skin == "sun tanned") || ($activeSlave.skin == "spray tanned"))>> + [[Remove tanning|Salon][$activeSlave.skin = $activeSlave.origSkin,cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] <</if>> <<if ($dyedSkin.indexOf($activeSlave.skin) == -1)>> <br> - Change skin tone: - <<set _needsSpacers = 0>> - <<if ($bleachableSkin.indexOf($activeSlave.skin) != -1)>> - <<if _needsSpacers == 1>> | <</if>> - [[Bleach|Salon][$activeSlave.skin = changeSkinTone($activeSlave.skin, -2),cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] - <<set _needsSpacers = 1>> - <</if>> - <<if ($lightenableSkin.indexOf($activeSlave.skin) != -1)>> - <<if _needsSpacers == 1>> | <</if>> - [[Lighten|Salon][$activeSlave.skin = changeSkinTone($activeSlave.skin, -1),cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] - <<set _needsSpacers = 1>> - <</if>> - <<if ($darkenableSkin.indexOf($activeSlave.skin) != -1)>> - <<if _needsSpacers == 1>> | <</if>> - [[Darken|Salon][$activeSlave.skin = changeSkinTone($activeSlave.skin, 1),cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] - <<set _needsSpacers = 1>> - <</if>> - <<if ($blackenableSkin.indexOf($activeSlave.skin) != -1)>> - <<if _needsSpacers == 1>> | <</if>> - [[Blacken|Salon][$activeSlave.skin = changeSkinTone($activeSlave.skin, 2),cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] - <<set _needsSpacers = 1>> - <</if>> - <br> <<if ($activeSlave.skin == "sun tanned" || $activeSlave.skin == "spray tanned")>> - [["Remove " + $his + " tanning"|Salon][$activeSlave.skin = $activeSlave.origSkin,cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] + $His skin tanning must be removed before any advanced procedure to change $his skin color. <<else>> - <<if ($activeSlave.skin != "sun tanned")>> - <<if (skinToneLevel($activeSlave.skin) < 6)>> - $His skin is so light in color that any attempt at natural tanning is more likely to damage $his skin. - <<elseif (skinToneLevel($activeSlave.skin) > 20)>> - $His skin is so dark in color that any attempt at natural tanning is not likely to appear on $his skin. - <<else>> - [["Sun tan " + $his + " skin"|Salon][$activeSlave.skin = "sun tanned",cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] - <</if>> + Change skin tone: + <<set _needsSpacers = 0>> + <<if (skinToneLevel($activeSlave.skin) > 1)>> + <<if _needsSpacers == 1>> | <</if>> + [[Bleach|Salon][$activeSlave.skin = changeSkinTone($activeSlave.skin, -2),cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] + <<set _needsSpacers = 1>> + <</if>> + <<if (skinToneLevel($activeSlave.skin) > 8)>> + <<if _needsSpacers == 1>> | <</if>> + [[Lighten|Salon][$activeSlave.skin = changeSkinTone($activeSlave.skin, -1),cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] + <<set _needsSpacers = 1>> + <</if>> + <<if (skinToneLevel($activeSlave.skin) < 18)>> + <<if _needsSpacers == 1>> | <</if>> + [[Darken|Salon][$activeSlave.skin = changeSkinTone($activeSlave.skin, 1),cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] + <<set _needsSpacers = 1>> + <</if>> + <<if (skinToneLevel($activeSlave.skin) < 25)>> + <<if _needsSpacers == 1>> | <</if>> + [[Blacken|Salon][$activeSlave.skin = changeSkinTone($activeSlave.skin, 2),cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] + <<set _needsSpacers = 1>> + <</if>> + <</if>> + <br> + <<set _needsSpacers = 0>> + <<if ($activeSlave.skin != "sun tanned")>> + <<if (skinToneLevel($activeSlave.skin) < 6)>> + $His skin is so light in color that any attempt at natural tanning is more likely to damage $his skin. + <<elseif (skinToneLevel($activeSlave.skin) > 20)>> + $His skin is so dark in color that any attempt at natural tanning is not likely to appear on $his skin. + <<else>> + [["Sun tan " + $his + " skin"|Salon][$activeSlave.skin = "sun tanned",cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] + <<set _needsSpacers = 1>> <</if>> <</if>> <<if ($activeSlave.skin != "spray tanned")>> - [["Spray tan " + $his + " skin"|Salon][$activeSlave.skin = "spray tanned",cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] + <<if _needsSpacers == 1>> | <</if>> + [["Spray tan " + $his + " skin"|Salon][$activeSlave.skin = "spray tanned",cashX(forceNeg($modCost), "slaveMod", $activeSlave)]] <</if>> <</if>> diff --git a/src/utility/descriptionWidgetsStyle.tw b/src/utility/descriptionWidgetsStyle.tw index 5c86218eff5..69d3db3d6eb 100644 --- a/src/utility/descriptionWidgetsStyle.tw +++ b/src/utility/descriptionWidgetsStyle.tw @@ -294,7 +294,7 @@ $activeSlave.slaveName is which lacks arm or leg holes, so $his limbless torso is in a net. <<else>> <<if (($activeSlave.nails == 2) || ($activeSlave.nails == 7) || ($activeSlave.nails == 9)) && (($activeSlave.makeup == 3) || ($activeSlave.makeup == 6) || ($activeSlave.nails == 8))>> - $activeSlave.hColor to match $his unicolor style, + $activeSlave.hColor to match $his monochrome style, <<elseif (skinToneLevel($activeSlave.skin) > 22)>> in white to create a striking contrast with $his $activeSlave.skin skin, <<elseif ($activeSlave.addict > 5)>> -- GitLab