mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-20 03:25:49 +01:00
Initial commit containing all the necessary code files that allow Tajaran, Unathi, and Skrell to change both their hair and body color to match. NO MORE GREEN/GREY!
Conflicts: code/modules/client/preferences.dm code/modules/mob/living/carbon/human/human_defines.dm code/modules/mob/living/carbon/species.dm code/setup.dm
This commit is contained in:
@@ -67,7 +67,10 @@ datum/preferences
|
||||
var/r_facial = 0 //Face hair color
|
||||
var/g_facial = 0 //Face hair color
|
||||
var/b_facial = 0 //Face hair color
|
||||
var/s_tone = 0 //Skin color
|
||||
var/s_tone = 0 //Skin tone
|
||||
var/r_skin = 0 //Skin color
|
||||
var/g_skin = 0 //Skin color
|
||||
var/b_skin = 0 //Skin color
|
||||
var/r_eyes = 0 //Eye color
|
||||
var/g_eyes = 0 //Eye color
|
||||
var/b_eyes = 0 //Eye color
|
||||
@@ -182,10 +185,10 @@ datum/preferences
|
||||
dat += "<br>"
|
||||
dat += "Species: <a href='?_src_=prefs;preference=species;task=input'>[species]</a><br>"
|
||||
dat += "Secondary Language:<br><a href='?_src_=prefs;preference=language;task=input'>[language]</a><br>"
|
||||
dat += "Accent: <a href='?_src_=prefs;preference=accent;task=input'>[accent]</a><br>"
|
||||
/* dat += "Accent: <a href='?_src_=prefs;preference=accent;task=input'>[accent]</a><br>"
|
||||
dat += "Voice: <a href='?_src_=prefs;preference=voice;task=input'>[voice]</a><br>"
|
||||
dat += "Pitch: <a href='?_src_=prefs;preference=pitch;task=input'>[pitch]</a><br>"
|
||||
dat += "Talking Speed: <a href='?_src_=prefs;preference=talkspeed;task=input'>[talkspeed]</a><br>"
|
||||
dat += "Talking Speed: <a href='?_src_=prefs;preference=talkspeed;task=input'>[talkspeed]</a><br>"*/
|
||||
dat += "Blood Type: <a href='?_src_=prefs;preference=b_type;task=input'>[b_type]</a><br>"
|
||||
dat += "Skin Tone: <a href='?_src_=prefs;preference=s_tone;task=input'>[-s_tone + 35]/220<br></a>"
|
||||
// dat += "Skin pattern: <a href='byond://?src=\ref[user];preference=skin_style;task=input'>Adjust</a><br>"
|
||||
@@ -296,7 +299,10 @@ datum/preferences
|
||||
dat += " Style: <a href='?_src_=prefs;preference=f_style;task=input'>[f_style]</a><br>"
|
||||
|
||||
dat += "<br><b>Eyes</b><br>"
|
||||
dat += "<a href='?_src_=prefs;preference=eyes;task=input'>Change Color</a> <font face='fixedsys' size='3' color='#[num2hex(r_eyes, 2)][num2hex(g_eyes, 2)][num2hex(b_eyes, 2)]'><table style='display:inline;' bgcolor='#[num2hex(r_eyes, 2)][num2hex(g_eyes, 2)][num2hex(b_eyes)]'><tr><td>__</td></tr></table></font>"
|
||||
dat += "<a href='?_src_=prefs;preference=eyes;task=input'>Change Color</a> <font face='fixedsys' size='3' color='#[num2hex(r_eyes, 2)][num2hex(g_eyes, 2)][num2hex(b_eyes, 2)]'><table style='display:inline;' bgcolor='#[num2hex(r_eyes, 2)][num2hex(g_eyes, 2)][num2hex(b_eyes)]'><tr><td>__</td></tr></table></font><br>"
|
||||
|
||||
dat += "<br><b>Body Color</b><br>"
|
||||
dat += "<a href='?_src_=prefs;preference=skin;task=input'>Change Color</a> <font face='fixedsys' size='3' color='#[num2hex(r_skin, 2)][num2hex(g_skin, 2)][num2hex(b_skin, 2)]'><table style='display:inline;' bgcolor='#[num2hex(r_skin, 2)][num2hex(g_skin, 2)][num2hex(b_skin)]'><tr><td>__</td></tr></table></font>"
|
||||
|
||||
dat += "</td></tr></table><hr><center>"
|
||||
|
||||
@@ -932,6 +938,10 @@ datum/preferences
|
||||
b_eyes = rand(0,255)
|
||||
if("s_tone")
|
||||
s_tone = random_skin_tone()
|
||||
if("s_color")
|
||||
r_skin = rand(0,255)
|
||||
g_skin = rand(0,255)
|
||||
b_skin = rand(0,255)
|
||||
if("bag")
|
||||
backbag = rand(1,4)
|
||||
/*if("skin_style")
|
||||
@@ -1143,6 +1153,14 @@ datum/preferences
|
||||
if(new_s_tone)
|
||||
s_tone = 35 - max(min( round(new_s_tone), 220),1)
|
||||
|
||||
if("skin")
|
||||
if(species == "Unathi" || species == "Tajaran" || species == "Skrell")
|
||||
var/new_skin = input(user, "Choose your character's skin colour: ", "Character Preference") as color|null
|
||||
if(new_skin)
|
||||
r_skin = hex2num(copytext(new_skin, 2, 4))
|
||||
g_skin = hex2num(copytext(new_skin, 4, 6))
|
||||
b_skin = hex2num(copytext(new_skin, 6, 8))
|
||||
|
||||
if("ooccolor")
|
||||
var/new_ooccolor = input(user, "Choose your OOC colour:", "Game Preference") as color|null
|
||||
if(new_ooccolor)
|
||||
@@ -1376,6 +1394,10 @@ datum/preferences
|
||||
character.g_facial = g_facial
|
||||
character.b_facial = b_facial
|
||||
|
||||
character.r_skin = r_skin
|
||||
character.g_skin = g_skin
|
||||
character.b_skin = b_skin
|
||||
|
||||
character.s_tone = s_tone
|
||||
|
||||
character.h_style = h_style
|
||||
|
||||
@@ -270,6 +270,9 @@
|
||||
S["facial_green"] >> g_facial
|
||||
S["facial_blue"] >> b_facial
|
||||
S["skin_tone"] >> s_tone
|
||||
S["skin_red"] >> r_skin
|
||||
S["skin_green"] >> g_skin
|
||||
S["skin_blue"] >> b_skin
|
||||
S["hair_style_name"] >> h_style
|
||||
S["facial_style_name"] >> f_style
|
||||
S["eyes_red"] >> r_eyes
|
||||
@@ -323,6 +326,9 @@
|
||||
g_facial = sanitize_integer(g_facial, 0, 255, initial(g_facial))
|
||||
b_facial = sanitize_integer(b_facial, 0, 255, initial(b_facial))
|
||||
s_tone = sanitize_integer(s_tone, -185, 34, initial(s_tone))
|
||||
r_skin = sanitize_integer(r_facial, 0, 255, initial(r_skin))
|
||||
g_skin = sanitize_integer(r_facial, 0, 255, initial(g_skin))
|
||||
b_skin = sanitize_integer(r_facial, 0, 255, initial(b_skin))
|
||||
h_style = sanitize_inlist(h_style, hair_styles_list, initial(h_style))
|
||||
f_style = sanitize_inlist(f_style, facial_hair_styles_list, initial(f_style))
|
||||
r_eyes = sanitize_integer(r_eyes, 0, 255, initial(r_eyes))
|
||||
@@ -371,7 +377,10 @@
|
||||
S["facial_red"] << r_facial
|
||||
S["facial_green"] << g_facial
|
||||
S["facial_blue"] << b_facial
|
||||
S["skin_tone"] << s_tone
|
||||
S["skin_tone"] >> s_tone
|
||||
S["skin_red"] << r_skin
|
||||
S["skin_green"] << g_skin
|
||||
S["skin_blue"] << b_skin
|
||||
S["hair_style_name"] << h_style
|
||||
S["facial_style_name"] << f_style
|
||||
S["eyes_red"] << r_eyes
|
||||
|
||||
Reference in New Issue
Block a user