diff --git a/code/__HELPERS/icons.dm b/code/__HELPERS/icons.dm index 24e39ff16c..73b494e989 100644 --- a/code/__HELPERS/icons.dm +++ b/code/__HELPERS/icons.dm @@ -920,8 +920,9 @@ world // From /datum/preferences/proc/copy_appearance_to body.age = original.age body.gender = original.gender - body.ethnicity = original.ethnicity + body.skin_color = original.skin_color body.body_type = original.body_type + body.body_size = original.body_size body.r_eyes = original.r_eyes body.g_eyes = original.g_eyes diff --git a/code/__HELPERS/mobs.dm b/code/__HELPERS/mobs.dm index 9aa1bdc3ea..38d84c2922 100644 --- a/code/__HELPERS/mobs.dm +++ b/code/__HELPERS/mobs.dm @@ -1,11 +1,14 @@ #define isdeaf(A) (ismob(A) && ((A?:sdisabilities & DISABILITY_DEAF) || A?:ear_deaf)) #define xeno_hivenumber(A) (isxeno(A) ? A?:hivenumber : FALSE) -/proc/random_ethnicity() - return pick(GLOB.ethnicities_list) +/proc/random_skin_color() + return pick(GLOB.skin_color_list) /proc/random_body_type() - return pick(GLOB.body_types_list) + return pick(GLOB.body_type_list) + +/proc/random_body_size() + return pick(GLOB.body_size_list) /proc/random_hair_style(gender, species = "Human") var/h_style = "Crewcut" diff --git a/code/__HELPERS/sanitize_values.dm b/code/__HELPERS/sanitize_values.dm index 85e102a3c1..decec60d36 100644 --- a/code/__HELPERS/sanitize_values.dm +++ b/code/__HELPERS/sanitize_values.dm @@ -45,18 +45,24 @@ else return default return default -/proc/sanitize_ethnicity(ethnicity, default = "Western") - if (ethnicity in GLOB.ethnicities_list) - return ethnicity +/proc/sanitize_skin_color(skin_color, default = "Pale 2") + if(skin_color in GLOB.skin_color_list) + return skin_color return default -/proc/sanitize_body_type(body_type, default = "Mesomorphic (Average)") - if (body_type in GLOB.body_types_list) +/proc/sanitize_body_type(body_type, default = "Lean") + if(body_type in GLOB.body_type_list) return body_type return default +/proc/sanitize_body_size(body_size, default = "Average") + if(body_size in GLOB.body_size_list) + return body_size + + return default + /proc/sanitize_hexcolor(color, default="#000000") if(!istext(color)) return default var/len = length(color) diff --git a/code/_globalvars/global_lists.dm b/code/_globalvars/global_lists.dm index 3ba92a7c4d..c2cfb8263f 100644 --- a/code/_globalvars/global_lists.dm +++ b/code/_globalvars/global_lists.dm @@ -198,10 +198,11 @@ GLOBAL_LIST_INIT(custom_event_info_list, setup_custom_event_info()) GLOBAL_LIST_INIT(poster_designs, subtypesof(/datum/poster)) //Preferences stuff - // Ethnicities -GLOBAL_REFERENCE_LIST_INDEXED(ethnicities_list, /datum/ethnicity, name) // Stores /datum/ethnicity indexed by name - // Body Types -GLOBAL_REFERENCE_LIST_INDEXED(body_types_list, /datum/body_type, name) // Stores /datum/body_type indexed by name + // Skin colors +GLOBAL_REFERENCE_LIST_INDEXED(skin_color_list, /datum/skin_color, name) // Stores /datum/skin_color indexed by name + // Body +GLOBAL_REFERENCE_LIST_INDEXED(body_type_list, /datum/body_type, name) // Stores /datum/body_type indexed by name +GLOBAL_REFERENCE_LIST_INDEXED(body_size_list, /datum/body_size, name) // Stores /datum/body_size indexed by name //Hairstyles GLOBAL_REFERENCE_LIST_INDEXED(hair_styles_list, /datum/sprite_accessory/hair, name) //stores /datum/sprite_accessory/hair indexed by name GLOBAL_REFERENCE_LIST_INDEXED(facial_hair_styles_list, /datum/sprite_accessory/facial_hair, name) //stores /datum/sprite_accessory/facial_hair indexed by name diff --git a/code/datums/datacore.dm b/code/datums/datacore.dm index 7c50c34338..26ef0e5d0a 100644 --- a/code/datums/datacore.dm +++ b/code/datums/datacore.dm @@ -355,31 +355,38 @@ GLOBAL_DATUM_INIT(data_core, /datum/datacore, new) var/icon/icobase = H.species.icobase var/icon/temp - var/datum/ethnicity/ET = GLOB.ethnicities_list[H.ethnicity] - var/datum/body_type/B = GLOB.body_types_list[H.body_type] + var/datum/skin_color/set_skin_color = GLOB.skin_color_list[H.skin_color] + var/datum/body_type/set_body_type = GLOB.body_type_list[H.body_type] + var/datum/body_size/set_body_size = GLOB.body_size_list[H.body_size] - var/e_icon - var/b_icon + var/skin_color_icon + var/body_type_icon + var/body_size_icon - if (!ET) - e_icon = "western" + if(!set_skin_color) + skin_color_icon = "pale2" else - e_icon = ET.icon_name + skin_color_icon = set_skin_color.icon_name - if (!B) - b_icon = "mesomorphic" + if(!set_body_type) + body_type_icon = "lean" else - b_icon = B.icon_name + body_type_icon = set_body_type.icon_name - preview_icon = new /icon(icobase, get_limb_icon_name(H.species, b_icon, H.gender, "torso", e_icon)) - temp = new /icon(icobase, get_limb_icon_name(H.species, b_icon, H.gender, "groin", e_icon)) + if(!set_body_size) + body_size_icon = "avg" + else + body_size_icon = set_body_size.icon_name + + preview_icon = new /icon(icobase, get_limb_icon_name(H.species, body_size_icon, body_type_icon, H.gender, "torso", skin_color_icon)) + temp = new /icon(icobase, get_limb_icon_name(H.species, body_size_icon, body_type_icon, H.gender, "groin", skin_color_icon)) preview_icon.Blend(temp, ICON_OVERLAY) - temp = new /icon(icobase, get_limb_icon_name(H.species, b_icon, H.gender, "head", e_icon)) + temp = new /icon(icobase, get_limb_icon_name(H.species, body_size_icon, body_type_icon, H.gender, "head", skin_color_icon)) preview_icon.Blend(temp, ICON_OVERLAY) for(var/obj/limb/E in H.limbs) if(E.status & LIMB_DESTROYED) continue - temp = new /icon(icobase, get_limb_icon_name(H.species, b_icon, H.gender, E.name, e_icon)) + temp = new /icon(icobase, get_limb_icon_name(H.species, body_size_icon, body_type_icon, H.gender, E.name, skin_color_icon)) if(E.status & LIMB_ROBOT) temp.MapColors(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(0,0,0)) preview_icon.Blend(temp, ICON_OVERLAY) diff --git a/code/defines/procs/records.dm b/code/defines/procs/records.dm index a1e2ade2b7..b4612f10f4 100644 --- a/code/defines/procs/records.dm +++ b/code/defines/procs/records.dm @@ -6,7 +6,7 @@ G.fields["real_rank"] = "Unassigned" G.fields["sex"] = "Male" G.fields["age"] = "Unknown" - G.fields["ethnicity"] = "Unknown" + G.fields["skin_color"] = "Unknown" G.fields["p_stat"] = "Active" G.fields["m_stat"] = "Stable" G.fields["species"] = "Human" diff --git a/code/modules/client/preferences.dm b/code/modules/client/preferences.dm index 262ae11219..f6aa0a9018 100644 --- a/code/modules/client/preferences.dm +++ b/code/modules/client/preferences.dm @@ -152,8 +152,10 @@ var/const/MAX_SAVE_SLOTS = 10 var/g_eyes = 0 //Eye color var/b_eyes = 0 //Eye color var/species = "Human" //Species datum to use. - var/ethnicity = "Western" // Ethnicity - var/body_type = "Mesomorphic (Average)" // Body Type + var/ethnicity = "Western" //Legacy, kept to update save files + var/skin_color = "Pale 2" // Skin color + var/body_size = "Average" // Body Size + var/body_type = "Lean" // Body Type var/language = "None" //Secondary language var/list/gear //Custom/fluff item loadout. var/preferred_squad = "None" @@ -333,8 +335,9 @@ var/const/MAX_SAVE_SLOTS = 10 dat += "®" dat += "Age: [age]
" dat += "Gender: [gender == MALE ? "Male" : "Female"]
" - dat += "Ethnicity: [ethnicity]
" - dat += "Body Type: [body_type]
" + dat += "Skin Color: [skin_color]
" + dat += "Body Size: [body_size]
" + dat += "Body Muscularity: [body_type]
" dat += "Traits: Character Traits" dat += "
" @@ -1183,10 +1186,12 @@ var/const/MAX_SAVE_SLOTS = 10 real_name = character_origin.generate_human_name(gender) if ("age") age = rand(AGE_MIN, AGE_MAX) - if ("ethnicity") - ethnicity = random_ethnicity() + if ("skin_color") + skin_color = random_skin_color() if ("body_type") body_type = random_body_type() + if ("body_size") + body_size = random_body_size() if ("hair") r_hair = rand(0,255) g_hair = rand(0,255) @@ -1545,18 +1550,24 @@ var/const/MAX_SAVE_SLOTS = 10 if(new_h_gradient_style) grad_style = new_h_gradient_style - if ("ethnicity") - var/new_ethnicity = tgui_input_list(user, "Choose your character's ethnicity:", "Character Preferences", GLOB.ethnicities_list) + if ("skin_color") + var/new_skin_color = tgui_input_list(user, "Choose your character's skin color:", "Character Preferences", GLOB.skin_color_list) - if (new_ethnicity) - ethnicity = new_ethnicity + if (new_skin_color) + skin_color = new_skin_color if ("body_type") - var/new_body_type = tgui_input_list(user, "Choose your character's body type:", "Character Preferences", GLOB.body_types_list) + var/new_body_type = tgui_input_list(user, "Choose your character's body type:", "Character Preferences", GLOB.body_type_list) if (new_body_type) body_type = new_body_type + if ("body_size") + var/new_body_size = tgui_input_list(user, "Choose your character's body size:", "Character Preferences", GLOB.body_size_list) + + if (new_body_size) + body_size = new_body_size + if("facial") var/new_facial = input(user, "Choose your character's facial-hair color:", "Character Preference", rgb(r_facial, g_facial, b_facial)) as color|null if(new_facial) @@ -2047,8 +2058,9 @@ var/const/MAX_SAVE_SLOTS = 10 character.age = age character.gender = gender - character.ethnicity = ethnicity + character.skin_color = skin_color character.body_type = body_type + character.body_size = body_size character.r_eyes = r_eyes character.g_eyes = g_eyes @@ -2120,15 +2132,16 @@ var/const/MAX_SAVE_SLOTS = 10 message_admins("[character] ([character.ckey]) has spawned with their gender as plural or neuter. Please notify coders.") character.gender = MALE -// Transfers the character's physical characteristics (age, gender, ethnicity, etc) to the mob +// Transfers the character's physical characteristics (age, gender, skin color, etc) to the mob /datum/preferences/proc/copy_appearance_to(mob/living/carbon/human/character, safety = 0) if(!istype(character)) return character.age = age character.gender = gender - character.ethnicity = ethnicity + character.skin_color = skin_color character.body_type = body_type + character.body_size = body_size character.r_eyes = r_eyes character.g_eyes = g_eyes diff --git a/code/modules/client/preferences_savefile.dm b/code/modules/client/preferences_savefile.dm index 44af545e2e..1403b64bc4 100644 --- a/code/modules/client/preferences_savefile.dm +++ b/code/modules/client/preferences_savefile.dm @@ -1,5 +1,5 @@ #define SAVEFILE_VERSION_MIN 8 -#define SAVEFILE_VERSION_MAX 24 +#define SAVEFILE_VERSION_MAX 25 //handles converting savefiles to new formats //MAKE SURE YOU KEEP THIS UP TO DATE! @@ -110,6 +110,53 @@ S.cd = "/" + if(savefile_version < 25) + var/ethnicity + var/skin_color = "pale2" + S["ethnicity"] >> ethnicity + switch(ethnicity) + if("anglo") + skin_color = "pale2" + if("western") + skin_color = "tan2" + if("germanic") + skin_color = "pale2" + if("scandinavian") + skin_color = "pale3" + if("baltic") + skin_color = "pale3" + if("sinoorient") + skin_color = "pale1" + if("southorient") + skin_color = "tan1" + if("indian") + skin_color = "tan3" + if("sino") + skin_color = "tan1" + if("mesoamerican") + skin_color = "tan3" + if("northamerican") + skin_color = "tan3" + if("southamerican") + skin_color = "tan2" + if("circumpolar") + skin_color = "tan1" + if("northafrican") + skin_color = "tan3" + if("centralafrican") + skin_color = "dark1" + if("costalafrican") + skin_color = "dark3" + if("persian") + skin_color = "tan3" + if("levant") + skin_color = "tan3" + if("australasian") + skin_color = "dark2" + if("polynesian") + skin_color = "tan3" + S["skin_color"] << skin_color + savefile_version = SAVEFILE_VERSION_MAX return 1 @@ -472,7 +519,9 @@ S["gender"] >> gender S["age"] >> age S["ethnicity"] >> ethnicity + S["skin_color"] >> skin_color S["body_type"] >> body_type + S["body_size"] >> body_size S["language"] >> language S["spawnpoint"] >> spawnpoint @@ -549,8 +598,9 @@ be_random_body = sanitize_integer(be_random_body, 0, 1, initial(be_random_body)) gender = sanitize_gender(gender) age = sanitize_integer(age, AGE_MIN, AGE_MAX, initial(age)) - ethnicity = sanitize_ethnicity(ethnicity) + skin_color = sanitize_skin_color(skin_color) body_type = sanitize_body_type(body_type) + body_size = sanitize_body_size(body_size) r_hair = sanitize_integer(r_hair, 0, 255, initial(r_hair)) g_hair = sanitize_integer(g_hair, 0, 255, initial(g_hair)) b_hair = sanitize_integer(b_hair, 0, 255, initial(b_hair)) @@ -628,7 +678,9 @@ S["gender"] << gender S["age"] << age S["ethnicity"] << ethnicity + S["skin_color"] << skin_color S["body_type"] << body_type + S["body_size"] << body_size S["language"] << language S["hair_red"] << r_hair S["hair_green"] << g_hair diff --git a/code/modules/gear_presets/fun.dm b/code/modules/gear_presets/fun.dm index 2e17dfe9ef..687fca47f7 100644 --- a/code/modules/gear_presets/fun.dm +++ b/code/modules/gear_presets/fun.dm @@ -299,7 +299,7 @@ new_human.change_real_name(new_human, "Ivan") new_human.f_style = "Shaved" new_human.h_style = "Shaved Head" - new_human.ethnicity = "Scandinavian" + new_human.skin_color = "pale3" new_human.r_hair = 165 new_human.g_hair = 42 new_human.b_hair = 42 @@ -362,7 +362,7 @@ new_human.b_facial = 51 new_human.h_style = "Mullet" new_human.f_style = "Full English" - new_human.ethnicity = "Anglo" + new_human.skin_color = "pale2" new_human.r_eyes = 102 //Brown eyes. new_human.g_eyes = 51 new_human.b_eyes = 0 diff --git a/code/modules/gear_presets/yautja.dm b/code/modules/gear_presets/yautja.dm index 27eac7215f..8ffd8664a9 100644 --- a/code/modules/gear_presets/yautja.dm +++ b/code/modules/gear_presets/yautja.dm @@ -12,13 +12,13 @@ /datum/equipment_preset/yautja/load_race(mob/living/carbon/human/new_human, client/mob_client) new_human.set_species(SPECIES_YAUTJA) - new_human.ethnicity = "tan" + new_human.skin_color = "tan" new_human.body_type = "pred" //can be removed in future for body types if(!mob_client) mob_client = new_human.client if(mob_client?.prefs) new_human.h_style = mob_client.prefs.predator_h_style - new_human.ethnicity = mob_client.prefs.predator_skin_color + new_human.skin_color = mob_client.prefs.predator_skin_color /datum/equipment_preset/yautja/load_id(mob/living/carbon/human/new_human) new_human.job = rank diff --git a/code/modules/mob/living/carbon/human/human_defines.dm b/code/modules/mob/living/carbon/human/human_defines.dm index cd6abd2262..a3424a1815 100644 --- a/code/modules/mob/living/carbon/human/human_defines.dm +++ b/code/modules/mob/living/carbon/human/human_defines.dm @@ -25,8 +25,9 @@ var/g_eyes = 0 var/b_eyes = 0 - var/ethnicity = "Western" // Ethnicity - var/body_type = "Mesomorphic (Average)" // Body Type + var/skin_color = "Pale 2" // Skin color + var/body_size = "Average" // Body Size + var/body_type = "Lean" // Body Buffness //Skin color var/r_skin = 0 diff --git a/code/modules/mob/living/carbon/human/human_helpers.dm b/code/modules/mob/living/carbon/human/human_helpers.dm index a98de60d3e..9a3b796764 100644 --- a/code/modules/mob/living/carbon/human/human_helpers.dm +++ b/code/modules/mob/living/carbon/human/human_helpers.dm @@ -9,72 +9,65 @@ g = "f" return g -/proc/get_limb_icon_name(datum/species/S, body_type, gender, limb_name, ethnicity) - if(S.uses_ethnicity) +/proc/get_limb_icon_name(datum/species/S, body_size, body_type, gender, limb_name, skin_color) + if(S.uses_skin_color) + if(S.special_body_types) + switch(limb_name) + if("torso") + return "[skin_color]_torso_[body_size]_[body_type]" + if("chest") + return "[skin_color]_torso_[body_size]_[body_type]" + if("head") + return "[skin_color]_[limb_name]" + if("groin") + return "[skin_color]_[limb_name]_[body_size]" + + if(!S.special_body_types) + switch(limb_name) + if("torso") + return "[skin_color]_torso_[body_type]_[get_gender_name(gender)]" + if("chest") + return "[skin_color]_torso_[body_type]_[get_gender_name(gender)]" + if("head") + return "[skin_color]_[limb_name]_[get_gender_name(gender)]" + if("groin") + return "[skin_color]_[limb_name]_[body_type]_[get_gender_name(gender)]" switch(limb_name) - if ("torso") - return "[ethnicity]_torso_[body_type]_[get_gender_name(gender)]" - - if ("chest") - return "[ethnicity]_torso_[body_type]_[get_gender_name(gender)]" - - if ("head") - return "[ethnicity]_[limb_name]_[get_gender_name(gender)]" - - if ("groin") - return "[ethnicity]_[limb_name]_[get_gender_name(gender)]" - if("synthetic head") return "head_[get_gender_name(gender)]" - if ("r_arm") - return "[ethnicity]_right_arm" - - if ("right arm") - return "[ethnicity]_right_arm" - - if ("l_arm") - return "[ethnicity]_left_arm" - - if ("left arm") - return "[ethnicity]_left_arm" - - if ("r_leg") - return "[ethnicity]_right_leg" - - if ("right leg") - return "[ethnicity]_right_leg" - - if ("l_leg") - return "[ethnicity]_left_leg" - - if ("left leg") - return "[ethnicity]_left_leg" - - if ("r_hand") - return "[ethnicity]_right_hand" - - if ("right hand") - return "[ethnicity]_right_hand" - - if ("l_hand") - return "[ethnicity]_left_hand" - - if ("left hand") - return "[ethnicity]_left_hand" - - if ("r_foot") - return "[ethnicity]_right_foot" - - if ("right foot") - return "[ethnicity]_right_foot" - - if ("l_foot") - return "[ethnicity]_left_foot" - - if ("left foot") - return "[ethnicity]_left_foot" - + if("r_arm") + return "[skin_color]_right_arm" + if("right arm") + return "[skin_color]_right_arm" + if("l_arm") + return "[skin_color]_left_arm" + if("left arm") + return "[skin_color]_left_arm" + if("r_leg") + return "[skin_color]_right_leg" + if("right leg") + return "[skin_color]_right_leg" + if("l_leg") + return "[skin_color]_left_leg" + if("left leg") + return "[skin_color]_left_leg" + if("r_hand") + return "[skin_color]_right_hand" + if("right hand") + return "[skin_color]_right_hand" + if("l_hand") + return "[skin_color]_left_hand" + if("left hand") + return "[skin_color]_left_hand" + if("r_foot") + return "[skin_color]_right_foot" + if("right foot") + return "[skin_color]_right_foot" + if("l_foot") + return "[skin_color]_left_foot" + if("left foot") + return "[skin_color]_left_foot" else message_admins("DEBUG: Something called get_limb_icon_name() incorrectly, they use the name [limb_name]") return null @@ -147,28 +140,37 @@ return null /mob/living/carbon/human/proc/set_limb_icons() - var/datum/ethnicity/E = GLOB.ethnicities_list[ethnicity] - var/datum/body_type/B = GLOB.body_types_list[body_type] + var/datum/skin_color/set_skin_color = GLOB.skin_color_list[skin_color] + var/datum/body_size/set_body_size = GLOB.body_size_list[body_size] + var/datum/body_type/set_body_type = GLOB.body_type_list[body_type] - var/e_icon - var/b_icon + var/skin_color_icon + var/body_size_icon + var/body_type_icon - if (!E) - e_icon = "western" + if(!set_skin_color) + skin_color_icon = "pale2" else - e_icon = E.icon_name + skin_color_icon = set_skin_color.icon_name - if (!B) - b_icon = "mesomorphic" + if(!set_body_size) + body_size_icon = "avg" else - b_icon = B.icon_name + body_size_icon = set_body_size.icon_name + + + if(!set_body_type) + body_type_icon = "lean" + else + body_type_icon = set_body_type.icon_name if(isspeciesyautja(src)) - e_icon = src.ethnicity - b_icon = src.body_type + skin_color_icon = skin_color + body_size_icon = body_size + body_type_icon = body_type - for(var/obj/limb/L in limbs) - L.icon_name = get_limb_icon_name(species, b_icon, gender, L.display_name, e_icon) + for(var/obj/limb/L as anything in limbs) + L.icon_name = get_limb_icon_name(species, body_size_icon, body_type_icon, gender, L.display_name, skin_color_icon) /mob/living/carbon/human/can_inject(mob/user, error_msg, target_zone) if(species?.flags & IS_SYNTHETIC) diff --git a/code/modules/mob/living/carbon/human/species/human.dm b/code/modules/mob/living/carbon/human/species/human.dm index add78365a3..a50b6a9285 100644 --- a/code/modules/mob/living/carbon/human/species/human.dm +++ b/code/modules/mob/living/carbon/human/species/human.dm @@ -88,7 +88,8 @@ unarmed_type = /datum/unarmed_attack/punch flags = HAS_SKIN_TONE|HAS_LIPS|HAS_UNDERWEAR|HAS_HARDCRIT mob_flags = KNOWS_TECHNOLOGY - uses_ethnicity = TRUE + uses_skin_color = TRUE + special_body_types = TRUE /datum/species/human/handle_on_fire(humanoidmob) . = ..() diff --git a/code/modules/mob/living/carbon/human/species/species.dm b/code/modules/mob/living/carbon/human/species/species.dm index d2177cf49a..da14b0f88f 100644 --- a/code/modules/mob/living/carbon/human/species/species.dm +++ b/code/modules/mob/living/carbon/human/species/species.dm @@ -14,7 +14,8 @@ var/icobase_source // if we want to use sourcing system var/deform_source var/eyes = "eyes_s" // Icon for eyes. - var/uses_ethnicity = FALSE //Set to TRUE to load proper ethnicities and what have you + var/uses_skin_color = FALSE //Set to TRUE to load proper skin_colors and what have you + var/special_body_types = FALSE var/primitive // Lesser form, if any (ie. monkey for humans) var/tail // Name of tail image in species effects icon file. diff --git a/code/modules/mob/living/carbon/human/species/synthetic.dm b/code/modules/mob/living/carbon/human/species/synthetic.dm index d521ed2a63..b418c0acb0 100644 --- a/code/modules/mob/living/carbon/human/species/synthetic.dm +++ b/code/modules/mob/living/carbon/human/species/synthetic.dm @@ -2,7 +2,8 @@ group = SPECIES_SYNTHETIC name = SYNTH_GEN_THREE name_plural = "synthetics" - uses_ethnicity = TRUE //Uses ethnic presets + uses_skin_color = TRUE //Uses skin color presets + special_body_types = TRUE unarmed_type = /datum/unarmed_attack/punch/synthetic pain_type = /datum/pain/synthetic @@ -58,7 +59,8 @@ /datum/species/synthetic/gen_one name = SYNTH_GEN_ONE - uses_ethnicity = FALSE + uses_skin_color = FALSE + special_body_types = FALSE mob_inherent_traits = list(TRAIT_SUPER_STRONG, TRAIT_INTENT_EYES) hair_color = "#000000" @@ -67,12 +69,14 @@ /datum/species/synthetic/gen_two name = SYNTH_GEN_TWO - uses_ethnicity = FALSE //2nd gen uses generic human look + uses_skin_color = FALSE //2nd gen uses generic human look + special_body_types = FALSE /datum/species/synthetic/colonial name = SYNTH_COLONY name_plural = "Colonial Synthetics" - uses_ethnicity = TRUE + uses_skin_color = TRUE + special_body_types = TRUE brute_mod = 0.8 burn_mod = 0.8 mob_inherent_traits = list(TRAIT_SUPER_STRONG) @@ -84,11 +88,12 @@ /datum/species/synthetic/colonial/colonial_gen_two name = SYNTH_COLONY_GEN_TWO - uses_ethnicity = FALSE //2nd gen uses generic human look + uses_skin_color = FALSE //2nd gen uses generic human look /datum/species/synthetic/colonial/colonial_gen_one name = SYNTH_COLONY_GEN_ONE - uses_ethnicity = FALSE + uses_skin_color = FALSE + special_body_types = FALSE mob_inherent_traits = list(TRAIT_SUPER_STRONG, TRAIT_INTENT_EYES) //sets colonial_gen_one synth's hair to black hair_color = "#000000" @@ -100,7 +105,8 @@ /datum/species/synthetic/colonial/combat name = SYNTH_COMBAT name_plural = "Combat Synthetics" - uses_ethnicity = FALSE + uses_skin_color = FALSE + special_body_types = FALSE mob_inherent_traits = list(TRAIT_SUPER_STRONG, TRAIT_INTENT_EYES) brute_mod = 0.5 @@ -121,7 +127,7 @@ /datum/species/synthetic/infiltrator name = SYNTH_INFILTRATOR name_plural = "Infiltrator Synthetics" - uses_ethnicity = TRUE + uses_skin_color = TRUE mob_inherent_traits = list(TRAIT_SUPER_STRONG, TRAIT_INFILTRATOR_SYNTH) bloodsplatter_type = /obj/effect/temp_visual/dir_setting/bloodsplatter/human diff --git a/code/modules/mob/living/carbon/human/species/working_joe/_species.dm b/code/modules/mob/living/carbon/human/species/working_joe/_species.dm index 292c302f93..b0dd35c74b 100644 --- a/code/modules/mob/living/carbon/human/species/working_joe/_species.dm +++ b/code/modules/mob/living/carbon/human/species/working_joe/_species.dm @@ -2,7 +2,7 @@ name = SYNTH_WORKING_JOE name_plural = "Working Joes" death_message = "violently gargles fluid and seizes up, the glow in their eyes dimming..." - uses_ethnicity = FALSE + uses_skin_color = FALSE burn_mod = 0.65 // made for hazardous environments, withstanding temperatures up to 1210 degrees mob_inherent_traits = list(TRAIT_SUPER_STRONG, TRAIT_INTENT_EYES, TRAIT_EMOTE_CD_EXEMPT, TRAIT_CANNOT_EAT, TRAIT_UNSTRIPPABLE) diff --git a/code/modules/mob/living/carbon/human/species/yautja/_species.dm b/code/modules/mob/living/carbon/human/species/yautja/_species.dm index f8ecb3e059..ec82a58dff 100644 --- a/code/modules/mob/living/carbon/human/species/yautja/_species.dm +++ b/code/modules/mob/living/carbon/human/species/yautja/_species.dm @@ -6,7 +6,7 @@ burn_mod = 0.65 reagent_tag = IS_YAUTJA mob_flags = KNOWS_TECHNOLOGY - uses_ethnicity = TRUE + uses_skin_color = TRUE flags = IS_WHITELISTED|HAS_SKIN_COLOR|NO_CLONE_LOSS|NO_POISON|NO_NEURO|SPECIAL_BONEBREAK|NO_SHRAPNEL|HAS_HARDCRIT mob_inherent_traits = list( TRAIT_YAUTJA_TECH, diff --git a/code/modules/mob/new_player/body.dm b/code/modules/mob/new_player/body.dm new file mode 100644 index 0000000000..9f2b3e8182 --- /dev/null +++ b/code/modules/mob/new_player/body.dm @@ -0,0 +1,31 @@ +/datum/body_type + var/name + var/icon_name + +/datum/body_type/twig + name = "No Muscles" + icon_name = "twig" + +/datum/body_type/lean + name = "Lean" + icon_name = "lean" + +/datum/body_type/ripped + name = "Ripped" + icon_name = "buff" + +/datum/body_size + var/name + var/icon_name + +/datum/body_size/thin + name = "Thin" + icon_name = "sml" + +/datum/body_size/average + name = "Average" + icon_name = "avg" + +/datum/body_size/large + name = "Large" + icon_name = "lrg" diff --git a/code/modules/mob/new_player/body_type.dm b/code/modules/mob/new_player/body_type.dm deleted file mode 100644 index ad35dc2fee..0000000000 --- a/code/modules/mob/new_player/body_type.dm +++ /dev/null @@ -1,15 +0,0 @@ -/datum/body_type - var/name - var/icon_name - -/datum/body_type/ectomorphic - name = "Ectomorphic (Underweight)" - icon_name = "ecto" - -/datum/body_type/mesomorphic - name = "Mesomorphic (Average)" - icon_name = "meso" - -/datum/body_type/endomorphic - name = "Endomorphic (Overweight)" - icon_name = "endo" diff --git a/code/modules/mob/new_player/ethnicity.dm b/code/modules/mob/new_player/ethnicity.dm deleted file mode 100644 index 433a370f56..0000000000 --- a/code/modules/mob/new_player/ethnicity.dm +++ /dev/null @@ -1,114 +0,0 @@ -/datum/ethnicity - var/name - var/icon_name - var/ethnic_category - -/datum/ethnicity/anglo - name = "Anglo" - icon_name = "anglo" - ethnic_category = "European" - -/datum/ethnicity/western - name = "Western" - icon_name = "western" - ethnic_category = "European" - -/datum/ethnicity/germanic - name = "Germanic" - icon_name = "germanic" - ethnic_category = "European" - -/datum/ethnicity/scandinavian - name = "Scandinavian" - icon_name = "scandinavian" - ethnic_category = "European" - -/datum/ethnicity/baltic - name = "Baltic" - icon_name = "baltic" - ethnic_category = "European" - -/datum/ethnicity/sinoorient - name = "Sino-Orient" - icon_name = "sinoorient" - ethnic_category = "Oriental" - -/datum/ethnicity/eastorient - name = "East-Orient" - icon_name = "eastorient" - ethnic_category = "Oriental" - -/datum/ethnicity/southorient - name = "South-Orient" - icon_name = "southasian" - ethnic_category = "Oriental" - -/datum/ethnicity/indian - name = "Indian" - icon_name = "indian" - ethnic_category = "Oriental" - -/datum/ethnicity/sino - name = "Eurasian" - icon_name = "eurasian" - ethnic_category = "Oriental" - -/datum/ethnicity/mesoamerican - name = "Mesoamerican" - icon_name = "mesoamerican" - ethnic_category = "American" - -/datum/ethnicity/northamerican - name = "North American" - icon_name = "northamerican" - ethnic_category = "American" - -/datum/ethnicity/southamerican - name = "South American" - icon_name = "southamerican" - ethnic_category = "American" - -/datum/ethnicity/circumpolar - name = "Circumpolar" - icon_name = "circumpolar" - ethnic_category = "American" - -/datum/ethnicity/northafrican - name = "North African" - icon_name = "northafrican" - ethnic_category = "African" - -/datum/ethnicity/centralafrican - name = "Central African" - icon_name = "centralafrican" - ethnic_category = "African" - -/datum/ethnicity/costalafrican - name = "Coastal African" - icon_name = "costalafrican" - ethnic_category = "African" - -/datum/ethnicity/persian - name = "Persian" - icon_name = "persian" - ethnic_category = "Middle Eastern" - -/datum/ethnicity/arabian - name = "Arabian" - icon_name = "arabian" - ethnic_category = "Middle Eastern" - -/datum/ethnicity/levant - name = "Levant" - icon_name = "levant" - ethnic_category = "Middle Eastern" - -/datum/ethnicity/australasian - name = "Australasian" - icon_name = "australasian" - ethnic_category = "Oceania" - -/datum/ethnicity/polynesian - name = "Polynesian" - icon_name = "polynesian" - ethnic_category = "Oceania" diff --git a/code/modules/mob/new_player/preferences_setup.dm b/code/modules/mob/new_player/preferences_setup.dm index 5c2f73922c..b76f980480 100644 --- a/code/modules/mob/new_player/preferences_setup.dm +++ b/code/modules/mob/new_player/preferences_setup.dm @@ -6,8 +6,9 @@ else gender = FEMALE - ethnicity = random_ethnicity() + skin_color = random_skin_color() body_type = random_body_type() + body_size = random_body_size() h_style = random_hair_style(gender, species) f_style = random_facial_hair_style(gender, species) diff --git a/code/modules/mob/new_player/skin_color.dm b/code/modules/mob/new_player/skin_color.dm new file mode 100644 index 0000000000..f3158613c3 --- /dev/null +++ b/code/modules/mob/new_player/skin_color.dm @@ -0,0 +1,47 @@ +/datum/skin_color + var/name + var/icon_name + +/datum/skin_color/cmplayer + name = "Extra Pale" + icon_name = "cmp1" + +/datum/skin_color/pale1 + name = "Pale 1" + icon_name = "pale1" + +/datum/skin_color/pale2 + name = "Pale 2" + icon_name = "pale2" + +/datum/skin_color/pale3 + name = "Pale 3" + icon_name = "pale3" + +/datum/skin_color/tan1 + name = "Tan 1" + icon_name = "tan1" + +/datum/skin_color/tan2 + name = "Tan 2" + icon_name = "tan2" + +/datum/skin_color/tan3 + name = "Tan 3" + icon_name = "tan3" + +/datum/skin_color/dark1 + name = "Dark 1" + icon_name = "dark1" + +/datum/skin_color/dark2 + name = "Dark 2" + icon_name = "dark2" + +/datum/skin_color/dark3 + name = "Dark 3" + icon_name = "dark3" + +/datum/skin_color/melanated + name = "Melanated" + icon_name = "mel1" diff --git a/code/modules/mob/new_player/sprite_accessories/undershirt.dm b/code/modules/mob/new_player/sprite_accessories/undershirt.dm index 39f0e3ddd1..5919b75636 100644 --- a/code/modules/mob/new_player/sprite_accessories/undershirt.dm +++ b/code/modules/mob/new_player/sprite_accessories/undershirt.dm @@ -112,12 +112,6 @@ GLOBAL_LIST_INIT_TYPED(undershirt_f, /datum/sprite_accessory/undershirt, setup_u gender = FEMALE camo_conforming = TRUE -/datum/sprite_accessory/undershirt/halter_top - name = "Haltertop" - icon_state = "halter" - gender = FEMALE - camo_conforming = TRUE - /datum/sprite_accessory/undershirt/strapless_bra name = "Strapless Bra" icon_state = "strapless" diff --git a/code/modules/mob/new_player/sprite_accessories/underwear.dm b/code/modules/mob/new_player/sprite_accessories/underwear.dm index 200f3f2f67..869179619e 100644 --- a/code/modules/mob/new_player/sprite_accessories/underwear.dm +++ b/code/modules/mob/new_player/sprite_accessories/underwear.dm @@ -58,29 +58,33 @@ GLOBAL_LIST_INIT_TYPED(underwear_f, /datum/sprite_accessory/underwear, setup_und if("s") name += " (Snow)" -// Plural +// Both /datum/sprite_accessory/underwear/boxers name = "Boxers" icon_state = "boxers" - gender = PLURAL + gender = NEUTER camo_conforming = TRUE -// Male /datum/sprite_accessory/underwear/briefs name = "Briefs" icon_state = "briefs" - gender = MALE + gender = NEUTER camo_conforming = TRUE -// Female -/datum/sprite_accessory/underwear/panties - name = "Panties" - icon_state = "panties" - gender = FEMALE +/datum/sprite_accessory/underwear/lowriders + name = "Lowriders" + icon_state = "lowriders" + gender = NEUTER camo_conforming = TRUE -/datum/sprite_accessory/underwear/thong - name = "Thong" - icon_state = "thong" - gender = FEMALE +/datum/sprite_accessory/underwear/satin + name = "Satin" + icon_state = "satin" + gender = NEUTER + camo_conforming = TRUE + +/datum/sprite_accessory/underwear/tanga + name = "Tanga" + icon_state = "tanga" + gender = NEUTER camo_conforming = TRUE diff --git a/code/modules/organs/limb_objects.dm b/code/modules/organs/limb_objects.dm index 734f303c7f..4bc3ae5cfa 100644 --- a/code/modules/organs/limb_objects.dm +++ b/code/modules/organs/limb_objects.dm @@ -22,27 +22,34 @@ icon = base - var/datum/ethnicity/E = GLOB.ethnicities_list[H.ethnicity] - var/datum/body_type/B = GLOB.body_types_list[H.body_type] + var/datum/skin_color/set_skin_color = GLOB.skin_color_list[H.skin_color] + var/datum/body_type/set_body_type = GLOB.body_type_list[H.body_type] + var/datum/body_size/set_body_size = GLOB.body_size_list[H.body_size] - var/e_icon - var/b_icon + var/skin_color_icon + var/body_type_icon + var/body_size_icon - if (!E) - e_icon = "western" + if(!set_skin_color) + skin_color_icon = "pale2" else - e_icon = E.icon_name + skin_color_icon = set_skin_color.icon_name - if (!B) - b_icon = "mesomorphic" + if(!set_body_type) + body_type_icon = "lean" else - b_icon = B.icon_name + body_type_icon = set_body_type.icon_name + + if(!set_body_size) + body_size_icon = "avg" + else + body_size_icon = set_body_size.icon_name if(isspeciesyautja(H)) - e_icon = H.ethnicity - b_icon = H.body_type + skin_color_icon = H.skin_color + body_type_icon = H.body_type - icon_state = "[get_limb_icon_name(H.species, b_icon, H.gender, name, e_icon)]" + icon_state = "[get_limb_icon_name(H.species, body_size_icon, body_type_icon, H.gender, name, skin_color_icon)]" setDir(SOUTH) apply_transform(turn(transform, rand(70,130))) diff --git a/code/modules/organs/limbs.dm b/code/modules/organs/limbs.dm index de7adcf2ae..99a104ea55 100644 --- a/code/modules/organs/limbs.dm +++ b/code/modules/organs/limbs.dm @@ -71,11 +71,14 @@ var/status = LIMB_ORGANIC var/processing = FALSE - /// ethnicity of the owner, used for limb appearance, set in [/obj/limb/proc/update_limb()] - var/ethnicity = "western" + /// skin color of the owner, used for limb appearance, set in [/obj/limb/proc/update_limb()] + var/skin_color = "Pale 2" - /// body type of the owner, used for limb appearance, set in [/obj/limb/proc/update_limb()] - var/body_type = "mesomorphic" + /// body size of the owner, used for limb appearance, set in [/obj/limb/proc/update_limb()] + var/body_size = "Average" + + /// body muscularity of the owner, used for limb appearance, set in [/obj/limb/proc/update_limb()] + var/body_type = "Lean" /// species of the owner, used for limb appearance, set in [/obj/limb/proc/update_limb()] var/datum/species/species @@ -686,22 +689,29 @@ This function completely restores a damaged organ to perfect condition. /obj/limb/proc/update_limb() SHOULD_CALL_PARENT(TRUE) - var/datum/ethnicity/owner_ethnicity = GLOB.ethnicities_list[owner?.ethnicity] + var/datum/skin_color/owner_skin_color = GLOB.skin_color_list[owner?.skin_color] - if(owner_ethnicity) - ethnicity = owner_ethnicity.icon_name + if(owner_skin_color) + skin_color = owner_skin_color.icon_name else - ethnicity = "western" + skin_color = "pale2" - var/datum/body_type/owner_body_type = GLOB.body_types_list[owner?.body_type] + var/datum/body_type/owner_body_type = GLOB.body_type_list[owner?.body_type] if(owner_body_type) body_type = owner_body_type.icon_name else - body_type = "mesomorphic" + body_type = "lean" + + var/datum/body_type/owner_body_size = GLOB.body_size_list[owner?.body_size] + + if(owner_body_size) + body_size = owner_body_size.icon_name + else + body_size = "avg" if(isspeciesyautja(owner)) - ethnicity = owner.ethnicity + skin_color = owner.skin_color body_type = owner.body_type species = owner?.species ? owner.species : GLOB.all_species[SPECIES_HUMAN] @@ -731,7 +741,7 @@ This function completely restores a damaged organ to perfect condition. return limb.icon = species.icobase - limb.icon_state = "[get_limb_icon_name(species, body_type, limb_gender, icon_name, ethnicity)]" + limb.icon_state = "[get_limb_icon_name(species, body_size, body_type, limb_gender, icon_name, skin_color)]" . += limb @@ -741,7 +751,7 @@ This function completely restores a damaged organ to perfect condition. /obj/limb/proc/get_limb_icon_key() SHOULD_CALL_PARENT(TRUE) - return "[species.name]-[body_type]-[limb_gender]-[icon_name]-[ethnicity]-[status]" + return "[species.name]-[body_size]-[body_type]-[limb_gender]-[icon_name]-[skin_color]-[status]" // new damage icon system // returns just the brute/burn damage code diff --git a/colonialmarines.dme b/colonialmarines.dme index ec5420b558..d75338ecfe 100644 --- a/colonialmarines.dme +++ b/colonialmarines.dme @@ -2129,12 +2129,12 @@ #include "code\modules\mob\living\simple_animal\hostile\retaliate\clown.dm" #include "code\modules\mob\living\simple_animal\hostile\retaliate\drone.dm" #include "code\modules\mob\living\simple_animal\hostile\retaliate\retaliate.dm" -#include "code\modules\mob\new_player\body_type.dm" -#include "code\modules\mob\new_player\ethnicity.dm" +#include "code\modules\mob\new_player\body.dm" #include "code\modules\mob\new_player\login.dm" #include "code\modules\mob\new_player\logout.dm" #include "code\modules\mob\new_player\new_player.dm" #include "code\modules\mob\new_player\preferences_setup.dm" +#include "code\modules\mob\new_player\skin_color.dm" #include "code\modules\mob\new_player\sprite_accessories\facial_hair.dm" #include "code\modules\mob\new_player\sprite_accessories\hair.dm" #include "code\modules\mob\new_player\sprite_accessories\hair_gradients.dm" diff --git a/icons/mob/humans/species/r_human.dmi b/icons/mob/humans/species/r_human.dmi index 3e8f63d9f3..4ab300efe5 100644 Binary files a/icons/mob/humans/species/r_human.dmi and b/icons/mob/humans/species/r_human.dmi differ diff --git a/icons/mob/humans/species/r_predator.dmi b/icons/mob/humans/species/r_predator.dmi index e8fe1c1170..192f7d698b 100644 Binary files a/icons/mob/humans/species/r_predator.dmi and b/icons/mob/humans/species/r_predator.dmi differ diff --git a/icons/mob/humans/undershirt.dmi b/icons/mob/humans/undershirt.dmi index 225d413ae0..468778851c 100644 Binary files a/icons/mob/humans/undershirt.dmi and b/icons/mob/humans/undershirt.dmi differ diff --git a/icons/mob/humans/underwear.dmi b/icons/mob/humans/underwear.dmi index b639d0a615..3276ca12ae 100644 Binary files a/icons/mob/humans/underwear.dmi and b/icons/mob/humans/underwear.dmi differ