From cb97acd2daa1f0477c92002cf7e2515bb6e6ef5e Mon Sep 17 00:00:00 2001 From: mochi Date: Mon, 3 Aug 2020 17:47:57 +0200 Subject: [PATCH 1/2] Fix lips drawing over masks --- code/modules/mob/living/carbon/human/human.dm | 3 ++- code/modules/mob/living/carbon/human/update_icons.dm | 10 +++++----- code/modules/surgery/organs/organ_icon.dm | 5 ++++- 3 files changed, 11 insertions(+), 7 deletions(-) diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 16f1738d2f6..50a94013188 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -1465,12 +1465,13 @@ var/obj/item/organ/internal/eyes/eyes = get_int_organ(/obj/item/organ/internal/eyes) var/obj/item/organ/internal/cyberimp/eyes/eye_implant = get_int_organ(/obj/item/organ/internal/cyberimp/eyes) if(istype(dna.species) && dna.species.eyes) - var/icon/eyes_icon = new /icon('icons/mob/human_face.dmi', dna.species.eyes) + var/icon/eyes_icon if(eye_implant) //Eye implants override native DNA eye colo(u)r eyes_icon = eye_implant.generate_icon() else if(eyes) eyes_icon = eyes.generate_icon() else //Error 404: Eyes not found! + eyes_icon = new('icons/mob/human_face.dmi', dna.species.eyes) eyes_icon.Blend("#800000", ICON_ADD) return eyes_icon diff --git a/code/modules/mob/living/carbon/human/update_icons.dm b/code/modules/mob/living/carbon/human/update_icons.dm index 1f38e564928..98ae6824ad9 100644 --- a/code/modules/mob/living/carbon/human/update_icons.dm +++ b/code/modules/mob/living/carbon/human/update_icons.dm @@ -273,11 +273,6 @@ GLOBAL_LIST_EMPTY(damage_icon_parts) overlays_standing[UNDERWEAR_LAYER] = mutable_appearance(underwear_standing, layer = -UNDERWEAR_LAYER) apply_overlay(UNDERWEAR_LAYER) - if(lip_style && (LIPS in dna.species.species_traits)) - var/mutable_appearance/lips = mutable_appearance('icons/mob/human_face.dmi', "lips_[lip_style]_s") - lips.color = lip_color - standing += lips - overlays_standing[BODY_LAYER] = standing apply_overlay(BODY_LAYER) //tail @@ -1307,6 +1302,11 @@ GLOBAL_LIST_EMPTY(damage_icon_parts) else . += "#000000" + if(lip_color && (LIPS in dna.species.species_traits)) + . += "[lip_color]" + else + . += "#000000" + for(var/organ_tag in dna.species.has_limbs) var/obj/item/organ/external/part = bodyparts_by_name[organ_tag] if(isnull(part)) diff --git a/code/modules/surgery/organs/organ_icon.dm b/code/modules/surgery/organs/organ_icon.dm index 2a3b94ca249..b41ef824508 100644 --- a/code/modules/surgery/organs/organ_icon.dm +++ b/code/modules/surgery/organs/organ_icon.dm @@ -107,7 +107,10 @@ GLOBAL_LIST_EMPTY(limb_icon_cache) add_overlay(eyes_icon) if(owner.lip_style && (LIPS in dna.species.species_traits)) - add_overlay(mutable_appearance('icons/mob/human_face.dmi', "lips_[owner.lip_style]_s")) //Hefty icon not necessary. + var/icon/lips_icon = new('icons/mob/human_face.dmi', "lips_[owner.lip_style]_s") + lips_icon.Blend(owner.lip_color, ICON_MULTIPLY) + mob_icon.Blend(lips_icon, ICON_OVERLAY) + add_overlay(lips_icon) var/head_marking = owner.m_styles["head"] if(head_marking) From 346b54ad26f8ba86fa6162afde2455ec178d0d4a Mon Sep 17 00:00:00 2001 From: mochi Date: Wed, 19 Aug 2020 09:44:24 +0200 Subject: [PATCH 2/2] Fix random lipstick colour always defaulting to white --- code/game/objects/items/weapons/cosmetics.dm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/code/game/objects/items/weapons/cosmetics.dm b/code/game/objects/items/weapons/cosmetics.dm index 42f65141094..fcfe183dddf 100644 --- a/code/game/objects/items/weapons/cosmetics.dm +++ b/code/game/objects/items/weapons/cosmetics.dm @@ -55,16 +55,15 @@ /obj/item/lipstick/random/Initialize(mapload) . = ..() - var/lscolor = pick(lipstick_colors) // A random color is picked from the var defined initially in a new var. - colour = lipstick_colors[lscolor] // The color of the lipstick is pulled from the new variable (right hand side, HTML & Hex RGB) - name = "[lscolor] lipstick" // The new variable is also used to match the name to the color of the lipstick. Kudos to Desolate & Lemon + colour = pick(lipstick_colors) + name = "[colour] lipstick" /obj/item/lipstick/attack_self(mob/user) cut_overlays() to_chat(user, "You twist \the [src] [open ? "closed" : "open"].") open = !open if(open) - var/image/colored = mutable_appearance('icons/obj/items.dmi', "lipstick_uncap_color") + var/mutable_appearance/colored = mutable_appearance('icons/obj/items.dmi', "lipstick_uncap_color") colored.color = lipstick_colors[colour] icon_state = "lipstick_uncap" add_overlay(colored)