Merge pull request #604 from LetterJay/Species_Layers
Fix for incorrect/missing extra layers
This commit is contained in:
@@ -67,7 +67,7 @@
|
|||||||
|
|
||||||
//Eyes
|
//Eyes
|
||||||
var/obj/item/organ/eyes/mutanteyes = /obj/item/organ/eyes
|
var/obj/item/organ/eyes/mutanteyes = /obj/item/organ/eyes
|
||||||
|
|
||||||
//Ears
|
//Ears
|
||||||
var/obj/item/organ/ears/mutantears = /obj/item/organ/ears
|
var/obj/item/organ/ears/mutantears = /obj/item/organ/ears
|
||||||
|
|
||||||
@@ -497,6 +497,8 @@
|
|||||||
|
|
||||||
var/g = (H.gender == FEMALE) ? "f" : "m"
|
var/g = (H.gender == FEMALE) ? "f" : "m"
|
||||||
|
|
||||||
|
var/image/I
|
||||||
|
|
||||||
for(var/layer in relevant_layers)
|
for(var/layer in relevant_layers)
|
||||||
var/layertext = mutant_bodyparts_layertext(layer)
|
var/layertext = mutant_bodyparts_layertext(layer)
|
||||||
|
|
||||||
@@ -561,9 +563,9 @@
|
|||||||
S = /datum/sprite_accessory/slimecoon_snout*/
|
S = /datum/sprite_accessory/slimecoon_snout*/
|
||||||
if(!S || S.icon_state == "none")
|
if(!S || S.icon_state == "none")
|
||||||
continue
|
continue
|
||||||
|
|
||||||
var/mutable_appearance/accessory_overlay = mutable_appearance(S.icon, layer = -layer)
|
var/mutable_appearance/accessory_overlay = mutable_appearance(S.icon, layer = -layer)
|
||||||
|
|
||||||
//A little rename so we don't have to use tail_lizard or tail_human when naming the sprites.
|
//A little rename so we don't have to use tail_lizard or tail_human when naming the sprites.
|
||||||
if(bodypart == "tail_lizard" || bodypart == "tail_human" || bodypart == "mam_tail" || bodypart == "slimecoontail" || bodypart == "xenotail")
|
if(bodypart == "tail_lizard" || bodypart == "tail_human" || bodypart == "mam_tail" || bodypart == "slimecoontail" || bodypart == "xenotail")
|
||||||
bodypart = "tail"
|
bodypart = "tail"
|
||||||
@@ -574,11 +576,15 @@
|
|||||||
if(bodypart == "xenohead")
|
if(bodypart == "xenohead")
|
||||||
bodypart = "xhead"
|
bodypart = "xhead"
|
||||||
|
|
||||||
|
var/icon_string
|
||||||
|
|
||||||
if(S.gender_specific)
|
if(S.gender_specific)
|
||||||
accessory_overlay.icon_state = "[g]_[bodypart]_[S.icon_state]_[layertext]"
|
accessory_overlay.icon_state = "[g]_[bodypart]_[S.icon_state]_[layertext]"
|
||||||
else
|
else
|
||||||
accessory_overlay.icon_state = "m_[bodypart]_[S.icon_state]_[layertext]"
|
accessory_overlay.icon_state = "m_[bodypart]_[S.icon_state]_[layertext]"
|
||||||
|
|
||||||
|
I = image("icon" = S.icon, "icon_state" = icon_string, "layer" =- layer)
|
||||||
|
|
||||||
if(S.center)
|
if(S.center)
|
||||||
accessory_overlay = center_image(accessory_overlay, S.dimension_x, S.dimension_y)
|
accessory_overlay = center_image(accessory_overlay, S.dimension_x, S.dimension_y)
|
||||||
|
|
||||||
@@ -624,86 +630,78 @@
|
|||||||
inner_accessory_overlay = center_image(inner_accessory_overlay, S.dimension_x, S.dimension_y)
|
inner_accessory_overlay = center_image(inner_accessory_overlay, S.dimension_x, S.dimension_y)
|
||||||
|
|
||||||
standing += inner_accessory_overlay
|
standing += inner_accessory_overlay
|
||||||
|
|
||||||
if(S.extra) //apply the extra overlay, if there is one
|
if(S.extra) //apply the extra overlay, if there is one
|
||||||
var/mutable_appearance/extra_accessory_overlay = mutable_appearance(S.icon, layer = -layer)
|
|
||||||
if(S.gender_specific)
|
if(S.gender_specific)
|
||||||
extra_accessory_overlay.icon_state = "[g]_[bodypart]_extra_[S.icon_state]_[layertext]"
|
icon_string = "[g]_[bodypart]_extra_[S.icon_state]_[layertext]"
|
||||||
else
|
else
|
||||||
extra_accessory_overlay.icon_state = "m_[bodypart]_extra_[S.icon_state]_[layertext]"
|
icon_string = "m_[bodypart]_extra_[S.icon_state]_[layertext]"
|
||||||
|
|
||||||
|
I = image("icon" = S.icon, "icon_state" = icon_string, "layer" =- layer)
|
||||||
|
|
||||||
if(S.center)
|
if(S.center)
|
||||||
extra_accessory_overlay.icon_state = center_image(extra_accessory_overlay, S.dimension_x, S.dimension_y)
|
I = center_image(I,S.dimension_x,S.dimension_y)
|
||||||
|
|
||||||
if(!forced_colour)
|
switch(S.extra_color_src) //change the color of the extra overlay
|
||||||
switch(S.extra_color_src) //change the color of the extra overlay
|
if(MUTCOLORS)
|
||||||
if(MUTCOLORS)
|
if(fixed_mut_color)
|
||||||
if(fixed_mut_color)
|
I.color = "#[fixed_mut_color]"
|
||||||
extra_accessory_overlay.color = "#[fixed_mut_color]"
|
else
|
||||||
else
|
I.color = "#[H.dna.features["mcolor"]]"
|
||||||
extra_accessory_overlay.color = "#[H.dna.features["mcolor"]]"
|
if(MUTCOLORS2)
|
||||||
if(MUTCOLORS2)
|
if(fixed_mut_color2)
|
||||||
if(fixed_mut_color2)
|
I.color = "#[fixed_mut_color2]"
|
||||||
extra_accessory_overlay.color = "#[fixed_mut_color2]"
|
else
|
||||||
else
|
I.color = "#[H.dna.features["mcolor2"]]"
|
||||||
extra_accessory_overlay.color = "#[H.dna.features["mcolor2"]]"
|
if(MUTCOLORS3)
|
||||||
if(MUTCOLORS3)
|
if(fixed_mut_color3)
|
||||||
if(fixed_mut_color3)
|
I.color = "#[fixed_mut_color3]"
|
||||||
extra_accessory_overlay.color = "#[fixed_mut_color3]"
|
else
|
||||||
else
|
I.color = "#[H.dna.features["mcolor3"]]"
|
||||||
extra_accessory_overlay.color = "#[H.dna.features["mcolor3"]]"
|
if(HAIR)
|
||||||
if(HAIR)
|
if(hair_color == "mutcolor")
|
||||||
if(hair_color == "mutcolor")
|
I.color = "#[H.dna.features["mcolor"]]"
|
||||||
extra_accessory_overlay.color = "#[H.dna.features["mcolor"]]"
|
else
|
||||||
else
|
I.color = "#[H.hair_color]"
|
||||||
extra_accessory_overlay.color = "#[H.hair_color]"
|
if(FACEHAIR)
|
||||||
if(FACEHAIR)
|
I.color = "#[H.facial_hair_color]"
|
||||||
extra_accessory_overlay.color = "#[H.facial_hair_color]"
|
if(EYECOLOR)
|
||||||
if(EYECOLOR)
|
I.color = "#[H.eye_color]"
|
||||||
extra_accessory_overlay.color = "#[H.eye_color]"
|
standing += I
|
||||||
else
|
|
||||||
extra_accessory_overlay.color = forced_colour
|
|
||||||
standing += extra_accessory_overlay
|
|
||||||
|
|
||||||
if(S.extra2) //apply the extra overlay, if there is one
|
if(S.extra2) //apply the extra overlay, if there is one
|
||||||
var/mutable_appearance/extra2_accessory_overlay = mutable_appearance(S.icon, layer = -layer)
|
|
||||||
if(S.gender_specific)
|
if(S.gender_specific)
|
||||||
extra2_accessory_overlay.icon_state = "[g]_[bodypart]_extra2_[S.icon_state]_[layertext]"
|
icon_string = "[g]_[bodypart]_extra2_[S.icon_state]_[layertext]"
|
||||||
else
|
else
|
||||||
extra2_accessory_overlay.icon_state = "m_[bodypart]_extra2_[S.icon_state]_[layertext]"
|
icon_string = "m_[bodypart]_extra2_[S.icon_state]_[layertext]"
|
||||||
|
|
||||||
|
I = image("icon" = S.icon, "icon_state" = icon_string, "layer" =- layer)
|
||||||
|
|
||||||
if(S.center)
|
if(S.center)
|
||||||
extra2_accessory_overlay.icon_state = center_image(extra2_accessory_overlay, S.dimension_x, S.dimension_y)
|
I = center_image(I,S.dimension_x,S.dimension_y)
|
||||||
|
|
||||||
if(!forced_colour)
|
switch(S.extra2_color_src) //change the color of the extra overlay
|
||||||
switch(S.extra_color_src) //change the color of the extra overlay
|
if(MUTCOLORS)
|
||||||
if(MUTCOLORS)
|
if(fixed_mut_color)
|
||||||
if(fixed_mut_color)
|
I.color = "#[fixed_mut_color]"
|
||||||
extra2_accessory_overlay.color = "#[fixed_mut_color]"
|
else
|
||||||
else
|
I.color = "#[H.dna.features["mcolor"]]"
|
||||||
extra2_accessory_overlay.color = "#[H.dna.features["mcolor"]]"
|
if(MUTCOLORS2)
|
||||||
if(MUTCOLORS2)
|
if(fixed_mut_color2)
|
||||||
if(fixed_mut_color2)
|
I.color = "#[fixed_mut_color2]"
|
||||||
extra2_accessory_overlay.color = "#[fixed_mut_color2]"
|
else
|
||||||
else
|
I.color = "#[H.dna.features["mcolor2"]]"
|
||||||
extra2_accessory_overlay.color = "#[H.dna.features["mcolor2"]]"
|
if(MUTCOLORS3)
|
||||||
if(MUTCOLORS3)
|
if(fixed_mut_color3)
|
||||||
if(fixed_mut_color3)
|
I.color = "#[fixed_mut_color3]"
|
||||||
extra2_accessory_overlay.color = "#[fixed_mut_color3]"
|
else
|
||||||
else
|
I.color = "#[H.dna.features["mcolor3"]]"
|
||||||
extra2_accessory_overlay.color = "#[H.dna.features["mcolor3"]]"
|
if(HAIR)
|
||||||
if(HAIR)
|
if(hair_color == "mutcolor")
|
||||||
if(hair_color == "mutcolor")
|
I.color = "#[H.dna.features["mcolor"]]"
|
||||||
extra2_accessory_overlay.color = "#[H.dna.features["mcolor"]]"
|
else
|
||||||
else
|
I.color = "#[H.hair_color]"
|
||||||
extra2_accessory_overlay.color = "#[H.hair_color]"
|
standing += I
|
||||||
if(FACEHAIR)
|
|
||||||
extra2_accessory_overlay.color = "#[H.facial_hair_color]"
|
|
||||||
if(EYECOLOR)
|
|
||||||
extra2_accessory_overlay.color = "#[H.eye_color]"
|
|
||||||
else
|
|
||||||
extra2_accessory_overlay.color = forced_colour
|
|
||||||
standing += extra2_accessory_overlay
|
|
||||||
|
|
||||||
H.overlays_standing[layer] = standing.Copy()
|
H.overlays_standing[layer] = standing.Copy()
|
||||||
standing = list()
|
standing = list()
|
||||||
|
|||||||
Reference in New Issue
Block a user