From 86a825bb9fc23f19e91567473949bedc96966cc7 Mon Sep 17 00:00:00 2001 From: keronshb Date: Fri, 28 May 2021 15:57:16 -0400 Subject: [PATCH 1/3] Space Adapt outline --- code/datums/mutations/space_adaptation.dm | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/code/datums/mutations/space_adaptation.dm b/code/datums/mutations/space_adaptation.dm index 8b2263c2f2..d3783f5d87 100644 --- a/code/datums/mutations/space_adaptation.dm +++ b/code/datums/mutations/space_adaptation.dm @@ -8,23 +8,17 @@ time_coeff = 5 instability = 30 -/datum/mutation/human/space_adaptation/New(class_ = MUT_OTHER, timer, datum/mutation/human/copymut) - ..() - if(!(type in visual_indicators)) - visual_indicators[type] = list(mutable_appearance('icons/effects/genetics.dmi', "space_adapt", -MUTATIONS_LAYER)) - -/datum/mutation/human/space_adaptation/get_visual_indicator() - return visual_indicators[type][1] - /datum/mutation/human/space_adaptation/on_acquiring(mob/living/carbon/human/owner) if(..()) return ADD_TRAIT(owner, TRAIT_RESISTCOLD, "cold_resistance") ADD_TRAIT(owner, TRAIT_RESISTLOWPRESSURE, "cold_resistance") + owner.add_filter("space_glow", 2, list("type" = "outline", "color" = "#ffe46bd8", "size" = 2)) /datum/mutation/human/space_adaptation/on_losing(mob/living/carbon/human/owner) if(..()) return REMOVE_TRAIT(owner, TRAIT_RESISTCOLD, "cold_resistance") REMOVE_TRAIT(owner, TRAIT_RESISTLOWPRESSURE, "cold_resistance") + owner.remove_filter("space_glow") From c1a9f9cfe9676488213cfc372be359db0b140eb6 Mon Sep 17 00:00:00 2001 From: keronshb Date: Fri, 28 May 2021 17:40:43 -0400 Subject: [PATCH 2/3] GLOW ANIMATION --- code/datums/mutations/space_adaptation.dm | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/code/datums/mutations/space_adaptation.dm b/code/datums/mutations/space_adaptation.dm index d3783f5d87..d06ab90958 100644 --- a/code/datums/mutations/space_adaptation.dm +++ b/code/datums/mutations/space_adaptation.dm @@ -14,6 +14,13 @@ ADD_TRAIT(owner, TRAIT_RESISTCOLD, "cold_resistance") ADD_TRAIT(owner, TRAIT_RESISTLOWPRESSURE, "cold_resistance") owner.add_filter("space_glow", 2, list("type" = "outline", "color" = "#ffe46bd8", "size" = 2)) + addtimer(CALLBACK(src, .proc/glow_loop, owner), rand(1,19)) + +/datum/mutation/human/space_adaptation/proc/glow_loop(mob/living/carbon/human/owner) + var/filter = owner.get_filter("space_glow") + if(filter) + animate(filter, alpha = 110, time = 15, loop = -1) + animate(alpha = 40, time = 25) /datum/mutation/human/space_adaptation/on_losing(mob/living/carbon/human/owner) if(..()) From ed929dda12ed5b4eba2aa89e9a5c7eb55fb730d0 Mon Sep 17 00:00:00 2001 From: keronshb Date: Wed, 9 Jun 2021 15:12:22 -0400 Subject: [PATCH 3/3] Changes up the animation a bit --- code/datums/mutations/space_adaptation.dm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/datums/mutations/space_adaptation.dm b/code/datums/mutations/space_adaptation.dm index d06ab90958..4431720375 100644 --- a/code/datums/mutations/space_adaptation.dm +++ b/code/datums/mutations/space_adaptation.dm @@ -13,14 +13,14 @@ return ADD_TRAIT(owner, TRAIT_RESISTCOLD, "cold_resistance") ADD_TRAIT(owner, TRAIT_RESISTLOWPRESSURE, "cold_resistance") - owner.add_filter("space_glow", 2, list("type" = "outline", "color" = "#ffe46bd8", "size" = 2)) + owner.add_filter("space_glow", 2, list("type" = "outline", "color" = "#ffe46bd8", "size" = 1)) addtimer(CALLBACK(src, .proc/glow_loop, owner), rand(1,19)) /datum/mutation/human/space_adaptation/proc/glow_loop(mob/living/carbon/human/owner) var/filter = owner.get_filter("space_glow") if(filter) - animate(filter, alpha = 110, time = 15, loop = -1) - animate(alpha = 40, time = 25) + animate(filter, alpha = 190, time = 15, loop = -1) + animate(alpha = 110, time = 25) /datum/mutation/human/space_adaptation/on_losing(mob/living/carbon/human/owner) if(..())