Renamed variables:

b_type to blood_type
h_color to hair_color
f_color to facial_hair_color
f_style to facial_hair_style
h_style to hair_style
This commit is contained in:
carnie
2013-08-01 13:48:41 +01:00
parent 3236425152
commit 02be173c60
32 changed files with 316 additions and 314 deletions
+38 -38
View File
@@ -42,13 +42,13 @@ datum/preferences
var/be_random_name = 0 //whether we are a random name every round
var/gender = MALE //gender of character (well duh)
var/age = 30 //age of character
var/b_type = "A+" //blood type (not-chooseable)
var/blood_type = "A+" //blood type (not-chooseable)
var/underwear = "Nude" //underwear type
var/backbag = 2 //backpack type
var/h_style = "Bald" //Hair type
var/h_color = "000" //Hair color
var/f_style = "Shaved" //Face hair type
var/f_color = "000" //Facial hair color
var/hair_style = "Bald" //Hair type
var/hair_color = "000" //Hair color
var/facial_hair_style = "Shaved" //Face hair type
var/facial_hair_color = "000" //Facial hair color
var/skin_tone = "caucasian1" //Skin color
var/eye_color = "000" //Eye color
@@ -81,7 +81,7 @@ datum/preferences
var/unlock_content = 0
/datum/preferences/New(client/C)
b_type = random_blood_type()
blood_type = random_blood_type()
ooccolor = normal_ooc_colour
if(istype(C))
if(!IsGuestKey(C.key))
@@ -161,7 +161,7 @@ datum/preferences
dat += "<table width='100%'><tr><td width='24%' valign='top'>"
dat += "<b>Blood Type:</b> [b_type]<BR>"
dat += "<b>Blood Type:</b> [blood_type]<BR>"
dat += "<b>Skin Tone:</b><BR><a href='?_src_=prefs;preference=s_tone;task=input'>[skin_tone]</a><BR>"
dat += "<b>Underwear:</b><BR><a href ='?_src_=prefs;preference=underwear;task=input'>[underwear]</a><BR>"
dat += "<b>Backpack:</b><BR><a href ='?_src_=prefs;preference=bag;task=input'>[backbaglist[backbag]]</a><BR>"
@@ -171,16 +171,16 @@ datum/preferences
dat += "<h3>Hair Style</h3>"
dat += "<a href='?_src_=prefs;preference=h_style;task=input'>[h_style]</a><BR>"
dat += "<span style='border:1px solid #161616; background-color: #[h_color];'>&nbsp;&nbsp;&nbsp;</span> <a href='?_src_=prefs;preference=hair;task=input'>Change</a><BR>"
dat += "<a href='?_src_=prefs;preference=hair_style;task=input'>[hair_style]</a><BR>"
dat += "<span style='border:1px solid #161616; background-color: #[hair_color];'>&nbsp;&nbsp;&nbsp;</span> <a href='?_src_=prefs;preference=hair;task=input'>Change</a><BR>"
dat += "</td><td valign='top' width='28%'>"
dat += "<h3>Facial Hair Style</h3>"
dat += "<a href='?_src_=prefs;preference=f_style;task=input'>[f_style]</a><BR>"
dat += "<span style='border: 1px solid #161616; background-color: #[f_color];'>&nbsp;&nbsp;&nbsp;</span> <a href='?_src_=prefs;preference=facial;task=input'>Change</a><BR>"
dat += "<a href='?_src_=prefs;preference=facial_hair_style;task=input'>[facial_hair_style]</a><BR>"
dat += "<span style='border: 1px solid #161616; background-color: #[facial_hair_color];'>&nbsp;&nbsp;&nbsp;</span> <a href='?_src_=prefs;preference=facial;task=input'>Change</a><BR>"
dat += "</td><td valign='top'>"
@@ -520,13 +520,13 @@ datum/preferences
if("age")
age = rand(AGE_MIN, AGE_MAX)
if("hair")
h_color = random_short_color()
if("h_style")
h_style = random_hair_style(gender)
hair_color = random_short_color()
if("hair_style")
hair_style = random_hair_style(gender)
if("facial")
f_color = random_short_color()
if("f_style")
f_style = random_facial_hair_style(gender)
facial_hair_color = random_short_color()
if("facial_hair_style")
facial_hair_style = random_facial_hair_style(gender)
if("underwear")
underwear = random_underwear(gender)
if("eyes")
@@ -565,31 +565,31 @@ datum/preferences
if("hair")
var/new_hair = input(user, "Choose your character's hair colour:", "Character Preference") as null|color
if(new_hair)
h_color = sanitize_hexcolor(new_hair)
hair_color = sanitize_hexcolor(new_hair)
if("h_style")
var/new_h_style
if("hair_style")
var/new_hair_style
if(gender == MALE)
new_h_style = input(user, "Choose your character's hair style:", "Character Preference") as null|anything in hair_styles_male_list
new_hair_style = input(user, "Choose your character's hair style:", "Character Preference") as null|anything in hair_styles_male_list
else
new_h_style = input(user, "Choose your character's hair style:", "Character Preference") as null|anything in hair_styles_female_list
if(new_h_style)
h_style = new_h_style
new_hair_style = input(user, "Choose your character's hair style:", "Character Preference") as null|anything in hair_styles_female_list
if(new_hair_style)
hair_style = new_hair_style
if("facial")
var/new_facial = input(user, "Choose your character's facial-hair colour:", "Character Preference") as null|color
if(new_facial)
f_color = sanitize_hexcolor(new_facial)
facial_hair_color = sanitize_hexcolor(new_facial)
if("f_style")
var/new_f_style
if("facial_hair_style")
var/new_facial_hair_style
if(gender == MALE)
new_f_style = input(user, "Choose your character's facial-hair style:", "Character Preference") as null|anything in facial_hair_styles_male_list
new_facial_hair_style = input(user, "Choose your character's facial-hair style:", "Character Preference") as null|anything in facial_hair_styles_male_list
else
new_f_style = input(user, "Choose your character's facial-hair style:", "Character Preference") as null|anything in facial_hair_styles_female_list
if(new_f_style)
f_style = new_f_style
new_facial_hair_style = input(user, "Choose your character's facial-hair style:", "Character Preference") as null|anything in facial_hair_styles_female_list
if(new_facial_hair_style)
facial_hair_style = new_facial_hair_style
if("underwear")
var/new_underwear
@@ -630,8 +630,8 @@ datum/preferences
else
gender = MALE
underwear = random_underwear(gender)
f_style = random_facial_hair_style(gender)
h_style = random_hair_style(gender)
facial_hair_style = random_facial_hair_style(gender)
hair_style = random_hair_style(gender)
if("hear_adminhelps")
toggles ^= SOUND_ADMINHELP
@@ -708,15 +708,15 @@ datum/preferences
character.gender = gender
character.age = age
character.b_type = b_type
character.blood_type = blood_type
character.eye_color = eye_color
character.h_color = h_color
character.f_color = f_color
character.hair_color = hair_color
character.facial_hair_color = facial_hair_color
character.skin_tone = skin_tone
character.h_style = h_style
character.f_style = f_style
character.hair_style = hair_style
character.facial_hair_style = facial_hair_style
character.underwear = underwear
if(backbag > 3 || backbag < 1)
+14 -14
View File
@@ -157,12 +157,12 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
S["name_is_always_random"] >> be_random_name
S["gender"] >> gender
S["age"] >> age
S["hair_color"] >> h_color
S["facial_hair_color"] >> f_color
S["hair_color"] >> hair_color
S["facial_hair_color"] >> facial_hair_color
S["eye_color"] >> eye_color
S["skin_tone"] >> skin_tone
S["hair_style_name"] >> h_style
S["facial_style_name"] >> f_style
S["hair_style_name"] >> hair_style
S["facial_style_name"] >> facial_hair_style
S["underwear"] >> underwear
S["backbag"] >> backbag
@@ -189,16 +189,16 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
be_random_name = sanitize_integer(be_random_name, 0, 1, initial(be_random_name))
gender = sanitize_gender(gender)
if(gender == MALE)
h_style = sanitize_inlist(h_style, hair_styles_male_list)
f_style = sanitize_inlist(f_style, facial_hair_styles_male_list)
hair_style = sanitize_inlist(hair_style, hair_styles_male_list)
facial_hair_style = sanitize_inlist(facial_hair_style, facial_hair_styles_male_list)
underwear = sanitize_inlist(underwear, underwear_m)
else
h_style = sanitize_inlist(h_style, hair_styles_female_list)
f_style = sanitize_inlist(f_style, facial_hair_styles_female_list)
hair_style = sanitize_inlist(hair_style, hair_styles_female_list)
facial_hair_style = sanitize_inlist(facial_hair_style, facial_hair_styles_female_list)
underwear = sanitize_inlist(underwear, underwear_f)
age = sanitize_integer(age, AGE_MIN, AGE_MAX, initial(age))
h_color = sanitize_hexcolor(h_color, 3, 0)
f_color = sanitize_hexcolor(f_color, 3, 0)
hair_color = sanitize_hexcolor(hair_color, 3, 0)
facial_hair_color = sanitize_hexcolor(facial_hair_color, 3, 0)
eye_color = sanitize_hexcolor(eye_color, 3, 0)
skin_tone = sanitize_inlist(skin_tone, skin_tones)
backbag = sanitize_integer(backbag, 1, backbaglist.len, initial(backbag))
@@ -230,12 +230,12 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
S["name_is_always_random"] << be_random_name
S["gender"] << gender
S["age"] << age
S["hair_color"] << h_color
S["facial_hair_color"] << f_color
S["hair_color"] << hair_color
S["facial_hair_color"] << facial_hair_color
S["eye_color"] << eye_color
S["skin_tone"] << skin_tone
S["hair_style_name"] << h_style
S["facial_style_name"] << f_style
S["hair_style_name"] << hair_style
S["facial_style_name"] << facial_hair_style
S["underwear"] << underwear
S["backbag"] << backbag