Disables random hair (#16451)

Changed character setup to only change your hair on species swapping if the new species is not allowed to use the current hairstyle.
This commit is contained in:
SatinIsle
2024-10-12 16:16:34 +02:00
committed by GitHub
parent 1e3f0d5a01
commit 0c9eac6408
@@ -725,7 +725,8 @@ var/global/list/valid_bloodtypes = list("A+", "A-", "B+", "B-", "AB+", "AB-", "O
var/list/valid_hairstyles = pref.get_valid_hairstyles()
if(valid_hairstyles.len)
pref.h_style = pick(valid_hairstyles)
if(!(pref.h_style in valid_hairstyles))
pref.h_style = pick(valid_hairstyles)
else
//this shouldn't happen
pref.h_style = hair_styles_list["Bald"]
@@ -734,7 +735,8 @@ var/global/list/valid_bloodtypes = list("A+", "A-", "B+", "B-", "AB+", "AB-", "O
var/list/valid_facialhairstyles = pref.get_valid_facialhairstyles()
if(valid_facialhairstyles.len)
pref.f_style = pick(valid_facialhairstyles)
if(!(pref.f_style in valid_facialhairstyles))
pref.f_style = pick(valid_facialhairstyles)
else
//this shouldn't happen
pref.f_style = facial_hair_styles_list["Shaved"]