mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-21 19:17:50 +01:00
Fixes [Re]Vitiligo (#20384)
* Fix [Re]Vitiligo * Remove redundant function call * Readability
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
AC.flags = flags
|
||||
AC.ui_interact(user)
|
||||
|
||||
/mob/living/carbon/human/proc/change_gender(new_gender, update_dna = 1)
|
||||
/mob/living/carbon/human/proc/change_gender(new_gender, update_dna = TRUE)
|
||||
var/obj/item/organ/external/head/H = bodyparts_by_name["head"]
|
||||
if(gender == new_gender || (gender == PLURAL && !dna.species.has_gender))
|
||||
return
|
||||
@@ -21,9 +21,9 @@
|
||||
|
||||
if(update_dna)
|
||||
update_dna()
|
||||
sync_organ_dna(assimilate = 0)
|
||||
sync_organ_dna(assimilate = FALSE)
|
||||
update_body()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_hair(hair_style, fluff)
|
||||
var/obj/item/organ/external/head/H = get_organ("head")
|
||||
@@ -37,7 +37,7 @@
|
||||
|
||||
update_hair()
|
||||
update_inv_glasses()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_facial_hair(facial_hair_style)
|
||||
var/obj/item/organ/external/head/H = get_organ("head")
|
||||
@@ -47,7 +47,7 @@
|
||||
H.f_style = facial_hair_style
|
||||
|
||||
update_fhair()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_head_accessory(head_accessory_style)
|
||||
var/obj/item/organ/external/head/H = get_organ("head")
|
||||
@@ -59,7 +59,7 @@
|
||||
H.ha_style = head_accessory_style
|
||||
|
||||
update_head_accessory()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_markings(marking_style, location = "body")
|
||||
if(!marking_style || m_styles[location] == marking_style || !(marking_style in GLOB.marking_styles_list))
|
||||
@@ -100,7 +100,7 @@
|
||||
stop_tail_wagging()
|
||||
else
|
||||
update_markings()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_body_accessory(body_accessory_style)
|
||||
var/found
|
||||
@@ -112,7 +112,7 @@
|
||||
for(var/B in GLOB.body_accessory_by_name)
|
||||
if(B == body_accessory_style)
|
||||
body_accessory = GLOB.body_accessory_by_name[body_accessory_style]
|
||||
found = 1
|
||||
found = TRUE
|
||||
|
||||
if(!found)
|
||||
return
|
||||
@@ -140,7 +140,7 @@
|
||||
update_body(TRUE) //Update the body and force limb icon regeneration to update the head with the new icon.
|
||||
if(wear_mask)
|
||||
update_inv_wear_mask()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/reset_hair()
|
||||
reset_head_hair()
|
||||
@@ -255,7 +255,7 @@
|
||||
H.sec_hair_colour = colour
|
||||
|
||||
update_hair()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_facial_hair_color(colour = "#000000", secondary)
|
||||
var/obj/item/organ/external/head/H = get_organ("head")
|
||||
@@ -274,7 +274,7 @@
|
||||
H.sec_facial_colour = colour
|
||||
|
||||
update_fhair()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_head_accessory_color(colour = "#000000")
|
||||
var/obj/item/organ/external/head/H = get_organ("head")
|
||||
@@ -287,7 +287,7 @@
|
||||
H.headacc_colour = colour
|
||||
|
||||
update_head_accessory()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_marking_color(colour = "#000000", location = "body")
|
||||
if(colour == m_colours[location])
|
||||
@@ -299,7 +299,7 @@
|
||||
update_tail_layer()
|
||||
else
|
||||
update_markings()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
|
||||
/mob/living/carbon/human/proc/change_skin_color(colour = "#000000")
|
||||
@@ -309,8 +309,7 @@
|
||||
skin_colour = colour
|
||||
|
||||
force_update_limbs()
|
||||
update_body()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_skin_tone(tone)
|
||||
if(s_tone == tone || !((dna.species.bodyflags & HAS_SKIN_TONE) || (dna.species.bodyflags & HAS_ICON_SKIN_TONE)))
|
||||
@@ -319,8 +318,7 @@
|
||||
s_tone = tone
|
||||
|
||||
force_update_limbs()
|
||||
update_body()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/human/proc/change_hair_gradient(style, offset_raw, color, alpha)
|
||||
var/obj/item/organ/external/head/H = get_organ("head")
|
||||
@@ -346,12 +344,12 @@
|
||||
dna.ready_dna(src)
|
||||
SEND_SIGNAL(src, COMSIG_HUMAN_UPDATE_DNA)
|
||||
|
||||
/mob/living/carbon/human/proc/generate_valid_species(check_whitelist = 1, list/whitelist = list(), list/blacklist = list())
|
||||
/mob/living/carbon/human/proc/generate_valid_species(check_whitelist = TRUE, list/whitelist = list(), list/blacklist = list())
|
||||
var/list/valid_species = new()
|
||||
for(var/current_species_name in GLOB.all_species)
|
||||
var/datum/species/current_species = GLOB.all_species[current_species_name]
|
||||
|
||||
if(check_whitelist && !check_rights(R_ADMIN, 0, src)) //If we're using the whitelist, make sure to check it!
|
||||
if(check_whitelist && !check_rights(R_ADMIN, FALSE, src)) //If we're using the whitelist, make sure to check it!
|
||||
if(whitelist.len && !(current_species_name in whitelist))
|
||||
continue
|
||||
if(blacklist.len && (current_species_name in blacklist))
|
||||
|
||||
Reference in New Issue
Block a user