From 987c0c35da13e29f55cfd7e1fa2c3ae92ee00e28 Mon Sep 17 00:00:00 2001 From: ktccd Date: Tue, 22 Aug 2017 02:03:29 +0200 Subject: [PATCH] Makes Taurs not render human legs (#2448) Since taurs use their own sprite legs instead, we'll rely on those. This'll fix some fringe cases with nagas and the problem with driders completely covering their front drider legs. This will introduce some weirdness with cutting off limbs, since taur sprites have NO support for this, but I would need to completely refactor how we handle taurs to split up their sprites like that... And I'm not THAT good. --- .../modules/mob/living/carbon/human/update_icons.dm | 13 +++++++++++++ code/modules/mob/living/carbon/update_icons.dm | 11 +++++++++++ 2 files changed, 24 insertions(+) diff --git a/code/modules/mob/living/carbon/human/update_icons.dm b/code/modules/mob/living/carbon/human/update_icons.dm index 1aef45aff8..a9d6bda10a 100644 --- a/code/modules/mob/living/carbon/human/update_icons.dm +++ b/code/modules/mob/living/carbon/human/update_icons.dm @@ -521,8 +521,21 @@ generate/load female uniform sprites matching all previously decided variables . += "-[gender]" + + var/is_taur = FALSE + var/mob/living/carbon/human/H = src + if(("taur" in H.dna.species.mutant_bodyparts) && (H.dna.features["taur"] != "None")) + is_taur = TRUE + + for(var/X in bodyparts) var/obj/item/bodypart/BP = X + + if(istype(BP, /obj/item/bodypart/r_leg) || istype(BP, /obj/item/bodypart/l_leg)) + if(is_taur) + continue + + . += "-[BP.body_zone]" if(BP.status == BODYPART_ORGANIC) . += "-organic" diff --git a/code/modules/mob/living/carbon/update_icons.dm b/code/modules/mob/living/carbon/update_icons.dm index 46f9efad07..d2013f458d 100644 --- a/code/modules/mob/living/carbon/update_icons.dm +++ b/code/modules/mob/living/carbon/update_icons.dm @@ -234,11 +234,22 @@ if(limb_icon_cache[icon_render_key]) load_limb_from_cache() return + //Taur code goes here, since humans just inherit this proc + var/is_taur = FALSE + if(ishuman(src)) + var/mob/living/carbon/human/H = src + if(("taur" in H.dna.species.mutant_bodyparts) && (H.dna.features["taur"] != "None")) + is_taur = TRUE //GENERATE NEW LIMBS var/list/new_limbs = list() for(var/X in bodyparts) var/obj/item/bodypart/BP = X + + if(istype(BP, /obj/item/bodypart/r_leg) || istype(BP, /obj/item/bodypart/l_leg)) + if(is_taur) + continue + new_limbs += BP.get_limb_icon() if(new_limbs.len) overlays_standing[BODYPARTS_LAYER] = new_limbs