Update genitals.dm

This commit is contained in:
Ghom
2020-02-13 08:25:44 +01:00
committed by GitHub
parent 1ef3f45f89
commit e4a20a16a4

View File

@@ -248,12 +248,15 @@
if(QDELETED(src))
return
var/static/list/relevant_layers
var/static/list/layers_num
if(!relevant_layers)
relevant_layers = list()
relevant_layers["[GENITALS_BEHIND_LAYER]"] = "BEHIND"
relevant_layers["[GENITALS_FRONT_LAYER]"] = "FRONT"
for(var/L in relevant_layers)
LAZYSET(layers_num, L, text2num(L))
for(var/L in relevant_layers) //Less hardcode
remove_overlay(tex2num(L))
remove_overlay(layers_num[L])
remove_overlay(GENITALS_EXPOSED_LAYER)
if(!LAZYLEN(internal_organs) || ((NOGENITALS in dna.species.species_traits) && !genital_override) || HAS_TRAIT(src, TRAIT_HUSK))
return
@@ -320,14 +323,14 @@
standing += genital_overlay
if(LAZYLEN(standing))
overlays_standing[text2num(layer)] = standing
overlays_standing[layers_num[layer]] = standing
if(LAZYLEN(fully_exposed))
overlays_standing[GENITALS_EXPOSED_LAYER] = fully_exposed
apply_overlay(GENITALS_EXPOSED_LAYER)
for(var/L in relevant_layers)
apply_overlay(L)
apply_overlay(layers_num[L])
//Checks to see if organs are new on the mob, and changes their colours so that they don't get crazy colours.