From acb5c39b598e176fed23cf9b4a10c86152161128 Mon Sep 17 00:00:00 2001 From: Ghommie <42542238+Ghommie@users.noreply.github.com> Date: Sun, 12 Apr 2020 07:47:28 +0200 Subject: [PATCH 1/2] Fixes the phantom thief component for the Xth time. --- code/datums/components/phantomthief.dm | 8 ++++---- code/modules/clothing/glasses/phantomthief.dm | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/code/datums/components/phantomthief.dm b/code/datums/components/phantomthief.dm index ede222d001..57ab75f7a3 100644 --- a/code/datums/components/phantomthief.dm +++ b/code/datums/components/phantomthief.dm @@ -1,8 +1,8 @@ //This component applies a customizable drop_shadow filter to its wearer when they toggle combat mode on or off. This can stack. /datum/component/wearertargeting/phantomthief - dupe_mode = COMPONENT_DUPE_UNIQUE_PASSARGS - signals = list(COMSIG_LIVING_COMBAT_ENABLED) + dupe_mode = COMPONENT_DUPE_ALLOWED + signals = list(COMSIG_LIVING_COMBAT_ENABLED, COMSIG_LIVING_COMBAT_DISABLED) proctype = .proc/handlefilterstuff var/filter_x var/filter_y @@ -19,8 +19,8 @@ filter_color = _color valid_slots = _valid_slots -/datum/component/wearertargeting/phantomthief/proc/handlefilterstuff(datum/source, mob/user, combatmodestate) - if(!combatmodestate) +/datum/component/wearertargeting/phantomthief/proc/handlefilterstuff(mob/living/user, was_forced = FALSE) + if(!(user.combat_flags & COMBAT_FLAG_COMBAT_ACTIVE)) user.remove_filter("phantomthief") else user.add_filter("phantomthief", 4, list(type = "drop_shadow", x = filter_x, y = filter_y, size = filter_size, color = filter_color)) diff --git a/code/modules/clothing/glasses/phantomthief.dm b/code/modules/clothing/glasses/phantomthief.dm index 1c9afcfd6f..f02984e8e8 100644 --- a/code/modules/clothing/glasses/phantomthief.dm +++ b/code/modules/clothing/glasses/phantomthief.dm @@ -23,8 +23,8 @@ else . += "[DisplayTimeText(nextadrenalinepop - world.time)] left before the adrenaline injector can be used again." -/obj/item/clothing/glasses/phantomthief/syndicate/proc/injectadrenaline(mob/user, combatmodestate) - if(istype(user) && combatmodestate && world.time >= nextadrenalinepop) +/obj/item/clothing/glasses/phantomthief/syndicate/proc/injectadrenaline(mob/living/user, was_forced = FALSE) + if(combatmodestate && world.time >= nextadrenalinepop) nextadrenalinepop = world.time + 5 MINUTES user.reagents.add_reagent(/datum/reagent/syndicateadrenals, 5) user.playsound_local(user, 'sound/misc/adrenalinject.ogg', 100, 0, pressure_affected = FALSE) From 13f9c3c235e4d46bf97678b3912392dc0fa2fd77 Mon Sep 17 00:00:00 2001 From: Ghom <42542238+Ghommie@users.noreply.github.com> Date: Sun, 12 Apr 2020 08:03:30 +0200 Subject: [PATCH 2/2] Update phantomthief.dm --- code/modules/clothing/glasses/phantomthief.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/clothing/glasses/phantomthief.dm b/code/modules/clothing/glasses/phantomthief.dm index f02984e8e8..fa0eea3ca3 100644 --- a/code/modules/clothing/glasses/phantomthief.dm +++ b/code/modules/clothing/glasses/phantomthief.dm @@ -24,7 +24,7 @@ . += "[DisplayTimeText(nextadrenalinepop - world.time)] left before the adrenaline injector can be used again." /obj/item/clothing/glasses/phantomthief/syndicate/proc/injectadrenaline(mob/living/user, was_forced = FALSE) - if(combatmodestate && world.time >= nextadrenalinepop) + if(user.combat_flags & COMBAT_FLAG_COMBAT_TOGGLED && world.time >= nextadrenalinepop) nextadrenalinepop = world.time + 5 MINUTES user.reagents.add_reagent(/datum/reagent/syndicateadrenals, 5) user.playsound_local(user, 'sound/misc/adrenalinject.ogg', 100, 0, pressure_affected = FALSE)