[MIRROR] Small hulk cleanup / nukes TRAIT_IGNOREDAMAGESLOWDOWN (#28882)

* Small hulk cleanup / nukes `TRAIT_IGNOREDAMAGESLOWDOWN` (#85003)

## About The Pull Request

I was investigating a bug with hulk in which using it while damaged
doesn't put you back on full speed

I noticed `TRAIT_IGNOREDAMAGESLOWDOWN` on its own was subtly broken, in
that it did nothing if the user did not call `updatehealth` afterwards

And guess what, most (if not all) uses of the trait did not do this, so
it never applied correctly

So I nuked the trait entirely, made all uses of it use the same thing
morphine uses (`/datum/movespeed_modifier/damage_slowdown`)

And since I was auditing this I saw the ball module was broke, it
removed the immunity but never added it. Quick fix

I also cleaned up some Hulk stuff while I was in the area because I was
in the area. I removed all instances of `check_mutation` and replaced it
with trait checking because it made more sense.

I also also fixed a bug with the simple flying element never removing on
detach because I touched something that uses it for the above change.

## Changelog

🆑 Melbert
fix: Using hulk (and a myriad of similar effects) now properly updates
your movespeed to ignore the damage movespeed penalty
fix: Some things which temporarily make you fly don't make you fly
forever
fix: MODsuit ball module now properly makes you immune to damage
movespeed penalty when in ball form
fix: Adding Hulk via VV dropdown doesn't default to adding the strongest
hulk available (that which is used by the medieval pirates)
/🆑

* Small hulk cleanup / nukes `TRAIT_IGNOREDAMAGESLOWDOWN`

---------

Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
This commit is contained in:
SkyratBot
2024-07-17 21:02:21 +05:30
committed by GitHub
co-authored by MrMelbert
parent 336a88c7a9
commit f033ac05a8
20 changed files with 52 additions and 50 deletions
+1 -1
View File
@@ -72,7 +72,6 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
// Trait added to the user of a hippocratic oath status effect
#define TRAIT_HIPPOCRATIC_OATH "hippocratic_oath"
#define TRAIT_IGNORESLOWDOWN "ignoreslow"
#define TRAIT_IGNOREDAMAGESLOWDOWN "ignoredamageslowdown"
/// Makes it so the mob can use guns regardless of tool user status
#define TRAIT_GUN_NATURAL "gunnatural"
/// Causes death-like unconsciousness
@@ -970,6 +969,7 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
/// changelings with this trait can no longer talk over the hivemind
#define TRAIT_CHANGELING_HIVEMIND_MUTE "ling_mute"
/// This guy is a hulk! (Bulky and green, lacks tact)
#define TRAIT_HULK "hulk"
/// Isn't attacked harmfully by blob structures
#define TRAIT_BLOB_ALLY "blob_ally"
-2
View File
@@ -225,8 +225,6 @@
#define SPEED_TRAIT "speed_trait"
/// Trait given to mobs that have been autopsied
#define AUTOPSY_TRAIT "autopsy_trait"
/// Trait given by [/datum/status_effect/blessing_of_insanity]
#define MAD_WIZARD_TRAIT "mad_wizard_trait"
///From the market_crash event
#define MARKET_CRASH_EVENT_TRAIT "crashed_market_event"
-1
View File
@@ -278,7 +278,6 @@ GLOBAL_LIST_INIT(traits_by_type, list(
"TRAIT_HUSK" = TRAIT_HUSK,
"TRAIT_ID_APPRAISER" = TRAIT_ID_APPRAISER,
"TRAIT_IGNORE_ELEVATION" = TRAIT_IGNORE_ELEVATION,
"TRAIT_IGNOREDAMAGESLOWDOWN" = TRAIT_IGNOREDAMAGESLOWDOWN,
"TRAIT_IGNORESLOWDOWN" = TRAIT_IGNORESLOWDOWN,
"TRAIT_IGNORING_GRAVITY" = TRAIT_IGNORING_GRAVITY,
"TRAIT_ILLITERATE" = TRAIT_ILLITERATE,
-1
View File
@@ -101,7 +101,6 @@ GLOBAL_LIST_INIT(admin_visible_traits, list(
"TRAIT_HOLY" = TRAIT_HOLY,
"TRAIT_HUSK" = TRAIT_HUSK,
"TRAIT_IGNORE_ELEVATION" = TRAIT_IGNORE_ELEVATION,
"TRAIT_IGNOREDAMAGESLOWDOWN" = TRAIT_IGNOREDAMAGESLOWDOWN,
"TRAIT_IGNORESLOWDOWN" = TRAIT_IGNORESLOWDOWN,
"TRAIT_ILLITERATE" = TRAIT_ILLITERATE,
"TRAIT_IMMOBILIZED" = TRAIT_IMMOBILIZED,
+1
View File
@@ -17,6 +17,7 @@
/datum/element/simple_flying/Detach(datum/target)
. = ..()
UnregisterSignal(target, COMSIG_MOB_STATCHANGE)
REMOVE_TRAIT(target, TRAIT_MOVE_FLYING, ELEMENT_TRAIT(type))
///signal called by the stat of the target changing
/datum/element/simple_flying/proc/on_stat_change(mob/living/target, new_stat)
+1 -2
View File
@@ -188,8 +188,7 @@
return FALSE
if(!(carp_user.mobility_flags & MOBILITY_USE)) //NO UNABLE TO USE
return FALSE
var/datum/dna/dna = carp_user.has_dna()
if(dna?.check_mutation(/datum/mutation/human/hulk)) //NO HULK
if(HAS_TRAIT(carp_user, TRAIT_HULK)) //NO HULK
return FALSE
if(!isturf(carp_user.loc)) //NO MOTHERFLIPPIN MECHS!
return FALSE
+4 -3
View File
@@ -17,7 +17,6 @@
mutation_traits = list(
TRAIT_CHUNKYFINGERS,
TRAIT_HULK,
TRAIT_IGNOREDAMAGESLOWDOWN,
TRAIT_PUSHIMMUNE,
TRAIT_STUNIMMUNE,
)
@@ -38,6 +37,7 @@
owner.add_mood_event("hulk", /datum/mood_event/hulk)
RegisterSignal(owner, COMSIG_LIVING_EARLY_UNARMED_ATTACK, PROC_REF(on_attack_hand))
RegisterSignal(owner, COMSIG_MOB_CLICKON, PROC_REF(check_swing))
owner.add_movespeed_mod_immunities("hulk", /datum/movespeed_modifier/damage_slowdown)
/datum/mutation/human/hulk/proc/on_attack_hand(mob/living/carbon/human/source, atom/target, proximity, modifiers)
SIGNAL_HANDLER
@@ -99,6 +99,7 @@
owner.clear_mood_event("hulk")
UnregisterSignal(owner, COMSIG_LIVING_EARLY_UNARMED_ATTACK)
UnregisterSignal(owner, COMSIG_MOB_CLICKON)
owner.remove_movespeed_mod_immunities("hulk", /datum/movespeed_modifier/damage_slowdown)
/// How many steps it takes to throw the mob
#define HULK_TAILTHROW_STEPS 28
@@ -258,6 +259,7 @@
log_combat(the_hulk, yeeted_person, "has thrown by tail")
/datum/mutation/human/hulk/wizardly
name = "Hulk (Magical)"
species_allowed = null //yes skeleton/lizard hulk - note that species that dont have skintone changing (like skellies) get custom handling
health_req = 0
instability = 0
@@ -265,19 +267,18 @@
/// List of traits to add/remove when someone gets this mutation.
mutation_traits = list(
TRAIT_HULK,
TRAIT_IGNOREDAMAGESLOWDOWN,
TRAIT_PUSHIMMUNE,
TRAIT_STUNIMMUNE,
) // no chunk
/datum/mutation/human/hulk/superhuman
name = "Hulk (Super)"
health_req = 0
instability = 0
/// List of traits to add/remove when someone gets this mutation.
mutation_traits = list(
TRAIT_CHUNKYFINGERS,
TRAIT_HULK,
TRAIT_IGNOREDAMAGESLOWDOWN,
TRAIT_NOSOFTCRIT,
TRAIT_NOHARDCRIT,
TRAIT_PUSHIMMUNE,
+8 -6
View File
@@ -84,7 +84,7 @@
icon_state = "blooddrunk"
/datum/status_effect/blooddrunk/on_apply()
ADD_TRAIT(owner, TRAIT_IGNOREDAMAGESLOWDOWN, BLOODDRUNK_TRAIT)
owner.add_movespeed_mod_immunities(id, /datum/movespeed_modifier/damage_slowdown)
if(ishuman(owner))
var/mob/living/carbon/human/human_owner = owner
human_owner.physiology.brute_mod *= 0.1
@@ -104,7 +104,7 @@
human_owner.physiology.tox_mod *= 10
human_owner.physiology.oxy_mod *= 10
human_owner.physiology.stamina_mod *= 10
REMOVE_TRAIT(owner, TRAIT_IGNOREDAMAGESLOWDOWN, BLOODDRUNK_TRAIT)
owner.remove_movespeed_mod_immunities(id, /datum/movespeed_modifier/damage_slowdown)
owner.remove_stun_absorption(id)
//Used by changelings to rapidly heal
@@ -383,7 +383,7 @@
show_duration = TRUE
/datum/status_effect/regenerative_core/on_apply()
ADD_TRAIT(owner, TRAIT_IGNOREDAMAGESLOWDOWN, STATUS_EFFECT_TRAIT)
owner.add_movespeed_mod_immunities(id, /datum/movespeed_modifier/damage_slowdown)
owner.adjustBruteLoss(-25)
owner.adjustStaminaLoss(-40) //Skyrat edit. Removes stamina on usage of regen core.
owner.adjustFireLoss(-25)
@@ -395,7 +395,7 @@
return TRUE
/datum/status_effect/regenerative_core/on_remove()
REMOVE_TRAIT(owner, TRAIT_IGNOREDAMAGESLOWDOWN, STATUS_EFFECT_TRAIT)
owner.remove_movespeed_mod_immunities(id, /datum/movespeed_modifier/damage_slowdown)
/datum/status_effect/lightningorb
id = "Lightning Orb"
@@ -571,7 +571,8 @@
owner.AddElement(/datum/element/forced_gravity, 0)
owner.AddElement(/datum/element/simple_flying)
owner.add_stun_absorption(source = id, priority = 4)
owner.add_traits(list(TRAIT_IGNOREDAMAGESLOWDOWN, TRAIT_FREE_HYPERSPACE_MOVEMENT), MAD_WIZARD_TRAIT)
owner.add_movespeed_mod_immunities(id, /datum/movespeed_modifier/damage_slowdown)
ADD_TRAIT(owner, TRAIT_FREE_HYPERSPACE_MOVEMENT, id)
owner.playsound_local(get_turf(owner), 'sound/chemistry/ahaha.ogg', vol = 100, vary = TRUE, use_reverb = TRUE)
return TRUE
@@ -588,7 +589,8 @@
owner.RemoveElement(/datum/element/forced_gravity, 0)
owner.RemoveElement(/datum/element/simple_flying)
owner.remove_stun_absorption(id)
owner.remove_traits(list(TRAIT_IGNOREDAMAGESLOWDOWN, TRAIT_FREE_HYPERSPACE_MOVEMENT), MAD_WIZARD_TRAIT)
owner.remove_movespeed_mod_immunities(id, /datum/movespeed_modifier/damage_slowdown)
REMOVE_TRAIT(owner, TRAIT_FREE_HYPERSPACE_MOVEMENT, id)
/// Gives you a brief period of anti-gravity
/datum/status_effect/jump_jet
@@ -345,7 +345,7 @@
// Hulk and body temperature
var/datum/species/targetspecies = humantarget.dna.species
var/mutant = humantarget.dna.check_mutation(/datum/mutation/human/hulk)
var/mutant = HAS_TRAIT(humantarget, TRAIT_HULK)
render_list += "<span class='info ml-1'>Species: [targetspecies.name][mutant ? "-derived mutant" : ""]</span>\n"
var/core_temperature_message = "Core temperature: [round(humantarget.coretemperature-T0C, 0.1)] &deg;C ([round(humantarget.coretemperature*1.8-459.67,0.1)] &deg;F)"
+8 -10
View File
@@ -58,10 +58,9 @@
/// Triggered on wield of two handed item
/// Specific hulk checks due to reflection chance for balance issues and switches hitsounds.
/obj/item/dualsaber/proc/on_wield(obj/item/source, mob/living/carbon/user)
if(user?.has_dna())
if(user.dna.check_mutation(/datum/mutation/human/hulk))
to_chat(user, span_warning("You lack the grace to wield this!"))
return COMPONENT_TWOHANDED_BLOCK_WIELD
if(user && HAS_TRAIT(user, TRAIT_HULK))
to_chat(user, span_warning("You lack the grace to wield this!"))
return COMPONENT_TWOHANDED_BLOCK_WIELD
update_weight_class(w_class_on)
hitsound = 'sound/weapons/blade1.ogg'
START_PROCESSING(SSobj, src)
@@ -125,12 +124,11 @@
. = ..()
/obj/item/dualsaber/attack(mob/target, mob/living/carbon/human/user)
if(user.has_dna())
if(user.dna.check_mutation(/datum/mutation/human/hulk))
to_chat(user, span_warning("You grip the blade too hard and accidentally drop it!"))
if(HAS_TRAIT(src, TRAIT_WIELDED))
user.dropItemToGround(src, force=TRUE)
return
if(HAS_TRAIT(user, TRAIT_HULK))
to_chat(user, span_warning("You grip the blade too hard and accidentally drop it!"))
if(HAS_TRAIT(src, TRAIT_WIELDED))
user.dropItemToGround(src, force=TRUE)
return
..()
if(!HAS_TRAIT(src, TRAIT_WIELDED))
return
+2 -2
View File
@@ -143,7 +143,7 @@
affix_desc = "on [target.p_their()] sensitive antennae"
affix_desc_target = "on your highly sensitive antennae"
brutal_noogie = TRUE
if(user.dna?.check_mutation(/datum/mutation/human/hulk))
if(HAS_TRAIT(user, TRAIT_HULK))
prefix_desc = "sickeningly brutal"
brutal_noogie = TRUE
@@ -178,7 +178,7 @@
var/damage = rand(1, 5)
if(HAS_TRAIT(target, TRAIT_ANTENNAE))
damage += rand(3,7)
if(user.dna?.check_mutation(/datum/mutation/human/hulk))
if(HAS_TRAIT(user, TRAIT_HULK))
damage += rand(3,7)
if(damage >= 5)
@@ -14,7 +14,7 @@
if(!.)
return FALSE
if(HAS_TRAIT_FROM(user, TRAIT_IGNOREDAMAGESLOWDOWN, CHANGELING_TRAIT))
if(HAS_TRAIT_FROM(user, TRAIT_PARALYSIS_L_ARM, CHANGELING_TRAIT) || HAS_TRAIT_FROM(user, TRAIT_PARALYSIS_R_ARM, CHANGELING_TRAIT))
user.balloon_alert(user, "already boosted!")
return FALSE
@@ -40,7 +40,8 @@
var/our_leg_zones = (GLOB.all_body_zones - GLOB.leg_zones)
user.regenerate_limbs(excluded_zones = our_leg_zones) // why is this exclusive rather than inclusive
user.add_traits(list(TRAIT_IGNOREDAMAGESLOWDOWN, TRAIT_PARALYSIS_L_ARM, TRAIT_PARALYSIS_R_ARM), CHANGELING_TRAIT)
user.add_traits(list(TRAIT_PARALYSIS_L_ARM, TRAIT_PARALYSIS_R_ARM), CHANGELING_TRAIT)
user.add_movespeed_mod_immunities(type, /datum/movespeed_modifier/damage_slowdown)
// Revert above mob changes.
addtimer(CALLBACK(src, PROC_REF(unsting_action), user), 20 SECONDS, TIMER_UNIQUE|TIMER_OVERRIDE)
@@ -57,4 +58,5 @@
/datum/action/changeling/adrenaline/proc/unsting_action(mob/living/user)
to_chat(user, span_changeling("The muscles in our limbs shift back to their usual places."))
user.remove_traits(list(TRAIT_IGNOREDAMAGESLOWDOWN, TRAIT_PARALYSIS_L_ARM, TRAIT_PARALYSIS_R_ARM), CHANGELING_TRAIT)
user.remove_traits(list(TRAIT_PARALYSIS_L_ARM, TRAIT_PARALYSIS_R_ARM), CHANGELING_TRAIT)
user.remove_movespeed_mod_immunities(type, /datum/movespeed_modifier/damage_slowdown)
@@ -220,7 +220,6 @@
/// A static list of traits we give to the heretic when on rust.
var/static/list/conditional_immunities = list(
TRAIT_BOMBIMMUNE,
TRAIT_IGNOREDAMAGESLOWDOWN,
TRAIT_IGNORESLOWDOWN,
TRAIT_NO_SLIP_ALL,
TRAIT_NOBREATH,
@@ -306,7 +305,7 @@
*
* Gives our heretic ([source]) buffs if they stand on rust.
*/
/datum/heretic_knowledge/ultimate/rust_final/proc/on_move(mob/source, atom/old_loc, dir, forced, list/old_locs)
/datum/heretic_knowledge/ultimate/rust_final/proc/on_move(mob/living/source, atom/old_loc, dir, forced, list/old_locs)
SIGNAL_HANDLER
// If we're on a rusty turf, and haven't given out our traits, buff our guy
@@ -314,12 +313,14 @@
if(HAS_TRAIT(our_turf, TRAIT_RUSTY))
if(!immunities_active)
source.add_traits(conditional_immunities, type)
source.add_movespeed_mod_immunities(type, /datum/movespeed_modifier/damage_slowdown)
immunities_active = TRUE
// If we're not on a rust turf, and we have given out our traits, nerf our guy
else
if(immunities_active)
source.remove_traits(conditional_immunities, type)
source.remove_movespeed_mod_immunities(type, /datum/movespeed_modifier/damage_slowdown)
immunities_active = FALSE
/**
@@ -53,11 +53,11 @@
alert_type = /atom/movable/screen/alert/status_effect/marshal
/datum/status_effect/marshal/on_apply()
ADD_TRAIT(owner, TRAIT_IGNOREDAMAGESLOWDOWN, STATUS_EFFECT_TRAIT)
owner.add_movespeed_mod_immunities(id, /datum/movespeed_modifier/damage_slowdown)
return TRUE
/datum/status_effect/marshal/on_remove()
REMOVE_TRAIT(owner, TRAIT_IGNOREDAMAGESLOWDOWN, STATUS_EFFECT_TRAIT)
owner.remove_movespeed_mod_immunities(id, /datum/movespeed_modifier/damage_slowdown)
/datum/status_effect/marshal/tick(seconds_between_ticks)
if(!iscarbon(owner))
@@ -52,10 +52,9 @@
if(!has_crit)
return
playsound(target, 'sound/effects/wounds/crackandbleed.ogg', 100, TRUE)
var/datum/dna/target_dna = target.has_dna()
if(target.stat == DEAD)
user.visible_message(span_warning("[user] gores [target] with [src]!"), span_warning("You gore [target] with [src], which doesn't accomplish much, but it does make you feel a little better."))
else if(!target_dna?.check_mutation(/datum/mutation/human/hulk) && (iscarbon(target) || issilicon(target)))
else if(!HAS_TRAIT(target, TRAIT_HULK) && (iscarbon(target) || issilicon(target)))
user.visible_message(span_boldwarning("[user] gores [target] with [src], bringing them to a halt!"), span_userdanger("You gore [target] with [src], bringing them to a halt!"))
target.Paralyze(issilicon(target) ? 2 SECONDS : 1 SECONDS)
else
@@ -552,7 +552,7 @@
#undef CPR_PANIC_SPEED
/mob/living/carbon/human/cuff_resist(obj/item/I)
if(dna?.check_mutation(/datum/mutation/human/hulk))
if(HAS_TRAIT(src, TRAIT_HULK))
say(pick(";RAAAAAAAARGH!", ";HNNNNNNNNNGGGGGGH!", ";GWAAAAAAAARRRHHH!", "NNNNNNNNGGGGGGGGHH!", ";AAAAAAARRRGH!" ), forced = "hulk")
if(..(I, cuff_break = FAST_CUFFBREAK))
dropItemToGround(I)
@@ -1053,10 +1053,6 @@
/mob/living/carbon/human/updatehealth()
. = ..()
if(HAS_TRAIT(src, TRAIT_IGNOREDAMAGESLOWDOWN))
remove_movespeed_modifier(/datum/movespeed_modifier/damage_slowdown)
remove_movespeed_modifier(/datum/movespeed_modifier/damage_slowdown_flying)
return
var/health_deficiency = max((maxHealth - health), staminaloss)
if(health_deficiency >= 40)
add_or_update_variable_movespeed_modifier(/datum/movespeed_modifier/damage_slowdown, TRUE, multiplicative_slowdown = health_deficiency / 75)
@@ -499,6 +499,7 @@
mod.wearer.add_traits(user_traits, MOD_TRAIT)
mod.wearer.RemoveElement(/datum/element/footstep, FOOTSTEP_MOB_HUMAN, 1, -6)
mod.wearer.AddElement(/datum/element/footstep, FOOTSTEP_OBJ_ROBOT, 1, -6, sound_vary = TRUE)
mod.wearer.add_movespeed_mod_immunities(MOD_TRAIT, /datum/movespeed_modifier/damage_slowdown)
mod.wearer.add_movespeed_modifier(/datum/movespeed_modifier/sphere)
RegisterSignal(mod.wearer, COMSIG_MOB_STATCHANGE, PROC_REF(on_statchange))
@@ -22,7 +22,7 @@
C.adjust_confusion_up_to(15 SECONDS, 30 SECONDS) // SKYRAT EDIT ADDITION - Electrode jitteriness
C.add_mood_event("tased", /datum/mood_event/tased)
SEND_SIGNAL(C, COMSIG_LIVING_MINOR_SHOCK)
if(C.dna && C.dna.check_mutation(/datum/mutation/human/hulk))
if(HAS_TRAIT(C, TRAIT_HULK))
C.say(pick(";RAAAAAAAARGH!", ";HNNNNNNNNNGGGGGGH!", ";GWAAAAAAAARRRHHH!", "NNNNNNNNGGGGGGGGHH!", ";AAAAAAARRRGH!" ), forced = "hulk")
else if(!C.check_stun_immunity(CANKNOCKDOWN))
addtimer(CALLBACK(C, TYPE_PROC_REF(/mob/living/carbon, do_jitter_animation), 20), 0.5 SECONDS)
@@ -423,8 +423,7 @@
return NONE
if(!isliving(target))
return NONE
var/datum/dna/dna = source.has_dna()
if(dna?.check_mutation(/datum/mutation/human/hulk)) //NO HULK
if(HAS_TRAIT(source, TRAIT_HULK)) //NO HULK
return NONE
if(!source.can_unarmed_attack())
return COMPONENT_SKIP_ATTACK
@@ -120,6 +120,7 @@
. = ..()
UnregisterSignal(implant_owner, signalCache)
UnregisterSignal(implant_owner, COMSIG_LIVING_ENTER_STAMCRIT)
remove_stun_buffs(implant_owner)
/obj/item/organ/internal/cyberimp/brain/anti_stun/on_mob_insert(mob/living/carbon/receiver)
. = ..()
@@ -151,10 +152,8 @@
sparks.set_up(5, 1, src)
sparks.start()
owner.add_traits(list(TRAIT_IGNOREDAMAGESLOWDOWN, TRAIT_BATON_RESISTANCE, TRAIT_STUNIMMUNE), REF(src))
addtimer(TRAIT_CALLBACK_REMOVE(owner, TRAIT_IGNOREDAMAGESLOWDOWN, REF(src)), stun_resistance_time)
addtimer(TRAIT_CALLBACK_REMOVE(owner, TRAIT_BATON_RESISTANCE, REF(src)), stun_resistance_time)
addtimer(TRAIT_CALLBACK_REMOVE(owner, TRAIT_STUNIMMUNE, REF(src)), stun_resistance_time)
give_stun_buffs(owner)
addtimer(CALLBACK(src, PROC_REF(remove_stun_buffs), owner), stun_resistance_time)
COOLDOWN_START(src, implant_cooldown, 60 SECONDS)
addtimer(CALLBACK(src, PROC_REF(implant_ready)),60 SECONDS)
@@ -163,6 +162,14 @@
if(owner)
to_chat(owner, span_purple("Your rebooter implant is ready."))
/obj/item/organ/internal/cyberimp/brain/anti_stun/proc/give_stun_buffs(mob/living/give_to = owner)
give_to.add_traits(list(TRAIT_STUNIMMUNE, TRAIT_BATON_RESISTANCE), REF(src))
give_to.add_movespeed_mod_immunities(REF(src), /datum/movespeed_modifier/damage_slowdown)
/obj/item/organ/internal/cyberimp/brain/anti_stun/proc/remove_stun_buffs(mob/living/remove_from = owner)
remove_from.remove_traits(list(TRAIT_STUNIMMUNE, TRAIT_BATON_RESISTANCE), REF(src))
remove_from.remove_movespeed_mod_immunities(REF(src), /datum/movespeed_modifier/damage_slowdown)
/obj/item/organ/internal/cyberimp/brain/anti_stun/emp_act(severity)
. = ..()
if((organ_flags & ORGAN_FAILING) || . & EMP_PROTECT_SELF)