From 7b5c5c2a134ae691a8351a9d21a9bd2ddfb99559 Mon Sep 17 00:00:00 2001 From: Aurorablade Date: Mon, 22 Feb 2016 06:03:11 -0500 Subject: [PATCH] shade on shade off --- code/modules/clothing/glasses/glasses.dm | 14 ++++++++++++++ .../mob/living/carbon/human/species/species.dm | 6 ------ 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/code/modules/clothing/glasses/glasses.dm b/code/modules/clothing/glasses/glasses.dm index 69058e5e3f9..a9e5a8e2fe7 100644 --- a/code/modules/clothing/glasses/glasses.dm +++ b/code/modules/clothing/glasses/glasses.dm @@ -218,6 +218,20 @@ var/punused = null action_button_name = "YEAH!" +/obj/item/clothing/glasses/sunglasses/noir/equipped(mob/user, slot) + if(slot == slot_glasses) + if(color_view && user.client && !user.client.color) + if(user.mind && (user.mind.assigned_role == "Detective")) + animate(user.client, color = color_view, time = 10) + //H.client.color = G.color_view + + ..(user, slot) + +/obj/item/clothing/glasses/sunglasses/noir/dropped(mob/user) + if(user.client && user.client.color) + animate(user.client, color = null, time = 10) + //H.client.color = null + ..(user) /obj/item/clothing/glasses/sunglasses/noir/attack_self() pun() diff --git a/code/modules/mob/living/carbon/human/species/species.dm b/code/modules/mob/living/carbon/human/species/species.dm index 4682f8b65d9..75b82119fd6 100644 --- a/code/modules/mob/living/carbon/human/species/species.dm +++ b/code/modules/mob/living/carbon/human/species/species.dm @@ -432,12 +432,6 @@ if(!G.see_darkness) H.see_invisible = SEE_INVISIBLE_MINIMUM - if(G.color_view && H.client && !H.client.color) - if(H.mind && (H.mind.assigned_role == "Detective")) - animate(H.client, color = G.color_view, time = 10) - else - if(H.client && H.client.color) - animate(H.client, color = null, time = 10) if(H.head) if(istype(H.head, /obj/item/clothing/head))