From 6733d6debbed492f6521c8adb3f48d4fb1fd048b Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Sat, 14 Nov 2020 21:33:12 +0100 Subject: [PATCH] [MIRROR] fixes the flags of some shocks (#1685) * fixes the flags of some shocks (#54906) ## About The Pull Request The shocks from the shock touch mutation now ignore insulated gloves, because you're touching your victim's body, not giving them a handshake. The shocks from punching charged energy fields (special holosigns from emagged cyborgs) now DON'T ignore insulated gloves, because you're literally punching them with your hand. The shocks from running into charged energy fields now DON'T ignore insulated gloves, to be consistent with things like electrified doors. The shocks from the on_mob_life() effect of liquid electricity now ignore insulated gloves, like the shocks from the on_mob_life() effect of teslium do (thanks for pointing this out, Angustmeta!). ## Why It's Good For The Game Logical sense and consistency in what forms of protection shocks check for are good things, I think. * fixes the flags of some shocks Co-authored-by: ATH1909 <42606352+ATH1909@users.noreply.github.com> --- code/datums/mutations/touch.dm | 2 +- code/game/objects/structures/holosign.dm | 4 ++-- code/modules/reagents/chemistry/reagents/food_reagents.dm | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/code/datums/mutations/touch.dm b/code/datums/mutations/touch.dm index 00746e51788..73decd6293d 100644 --- a/code/datums/mutations/touch.dm +++ b/code/datums/mutations/touch.dm @@ -32,7 +32,7 @@ return if(iscarbon(target)) var/mob/living/carbon/C = target - if(C.electrocute_act(15, user, 1, SHOCK_NOSTUN))//doesnt stun. never let this stun + if(C.electrocute_act(15, user, 1, SHOCK_NOGLOVES | SHOCK_NOSTUN))//doesnt stun. never let this stun C.dropItemToGround(C.get_active_held_item()) C.dropItemToGround(C.get_inactive_held_item()) C.add_confusion(15) diff --git a/code/game/objects/structures/holosign.dm b/code/game/objects/structures/holosign.dm index 9030b525114..3db53c4b159 100644 --- a/code/game/objects/structures/holosign.dm +++ b/code/game/objects/structures/holosign.dm @@ -183,7 +183,7 @@ if(!shockcd) if(ismob(user)) var/mob/living/M = user - M.electrocute_act(15,"Energy Barrier", flags = SHOCK_NOGLOVES) + M.electrocute_act(15,"Energy Barrier") shockcd = TRUE addtimer(CALLBACK(src, .proc/cooldown), 5) @@ -195,6 +195,6 @@ return var/mob/living/M = AM - M.electrocute_act(15,"Energy Barrier", flags = SHOCK_NOGLOVES) + M.electrocute_act(15,"Energy Barrier") shockcd = TRUE addtimer(CALLBACK(src, .proc/cooldown), 5) diff --git a/code/modules/reagents/chemistry/reagents/food_reagents.dm b/code/modules/reagents/chemistry/reagents/food_reagents.dm index 6b5568bc9b3..0664a08f8a2 100755 --- a/code/modules/reagents/chemistry/reagents/food_reagents.dm +++ b/code/modules/reagents/chemistry/reagents/food_reagents.dm @@ -755,8 +755,8 @@ stomach.adjust_charge(reac_volume * REM * 20) /datum/reagent/consumable/liquidelectricity/on_mob_life(mob/living/carbon/M) - if(prob(25) && !isethereal(M)) - M.electrocute_act(rand(10,15), "Liquid Electricity in their body", 1) //lmao at the newbs who eat energy bars + if(prob(25) && !isethereal(M)) //lmao at the newbs who eat energy bars + M.electrocute_act(rand(10,15), "Liquid Electricity in their body", 1, SHOCK_NOGLOVES) //the shock is coming from inside the house playsound(M, "sparks", 50, TRUE, SHORT_RANGE_SOUND_EXTRARANGE) return ..()