Bellies + Genitals hide fix

Can now how have bellies
This commit is contained in:
QuoteFox
2021-01-25 18:34:52 +00:00
parent 128bbba467
commit d1f8f37c32
10 changed files with 141 additions and 8 deletions
+26
View File
@@ -134,6 +134,8 @@ GLOBAL_LIST_EMPTY(preferences_datums)
"cock_color" = "fff",
"has_sheath" = FALSE,
"sheath_color" = "fff",
"has_belly" = FALSE,
"belly_color" = "fff",
"has_balls" = FALSE,
"balls_internal" = FALSE,
"balls_color" = "fff",
@@ -891,6 +893,17 @@ GLOBAL_LIST_EMPTY(preferences_datums)
dat += "<a style='display:block;width:50px' href='?_src_=prefs;preference=breasts_fluid;task=input'>Nothing?</a>"
//This else is a safeguard for errors, and if it happened, they wouldn't be able to change this pref,
//DO NOT REMOVE IT UNLESS YOU HAVE A GOOD IDEA
dat += APPEARANCE_CATEGORY_COLUMN
dat += "<h3>Belly</h3>"
dat += "<a style='display:block;width:50px' href='?_src_=prefs;preference=has_belly'>[features["has_belly"] == TRUE ? "Yes" : "No"]</a>"
if(features["has_belly"])
if(pref_species.use_skintones && features["genitals_use_skintone"] == TRUE)
dat += "<b>Color:</b></a><BR>"
dat += "<span style='border: 1px solid #161616; background-color: #[skintone2hex(skin_tone)];'>&nbsp;&nbsp;&nbsp;</span>(Skin tone overriding)<br>"
else
dat += "<b>Color:</b></a><BR>"
dat += "<span style='border: 1px solid #161616; background-color: #[features["belly_color"]];'>&nbsp;&nbsp;&nbsp;</span> <a href='?_src_=prefs;preference=belly_color;task=input'>Change</a><br>"
dat += "</td>"
dat += "</td>"
@@ -2170,6 +2183,17 @@ GLOBAL_LIST_EMPTY(preferences_datums)
else
to_chat(user,"<span class='danger'>Invalid color. Your color is not bright enough.</span>")
if("belly_color")
var/new_bellycolor = input(user, "Belly Color:", "Character Preference") as color|null
if(new_bellycolor)
var/temp_hsv = RGBtoHSV(new_bellycolor)
if(new_bellycolor == "#000000")
features["belly_color"] = pref_species.default_color
else if((MUTCOLORS_PARTSONLY in pref_species.species_traits) || ReadHSV(temp_hsv)[3] >= ReadHSV("#202020")[3])
features["belly_color"] = sanitize_hexcolor(new_bellycolor)
else
to_chat(user,"<span class='danger'>Invalid color. Your color is not bright enough.</span>")
if("balls_shape")
var/new_shape
new_shape = input(user, "Testicle Type:", "Character Preference") as null|anything in GLOB.balls_shapes_list
@@ -2375,6 +2399,8 @@ GLOBAL_LIST_EMPTY(preferences_datums)
features["has_cock"] = !features["has_cock"]
if(features["has_cock"] == FALSE)
features["has_balls"] = FALSE
if("has_belly")
features["has_belly"] = !features["has_belly"]
if("has_balls")
features["has_balls"] = !features["has_balls"]
if("has_ovi")
@@ -411,6 +411,9 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
//womb features
S["feature_has_womb"] >> features["has_womb"]
S["feature_can_get_preg"] >> features["can_get_preg"] //hyperstation 13
//balls features
S["feature_has_belly"] >> features["has_belly"]
S["feature_belly_color"] >> features["belly_color"]
//flavor text
//Let's make our players NOT cry desperately as we wipe their savefiles of their special snowflake texts:
if((S["flavor_text"] != "") && (S["flavor_text"] != null) && S["flavor_text"]) //If old text isn't null and isn't "" but still exists.