diff --git a/code/modules/clothing/suits/armor.dm b/code/modules/clothing/suits/armor.dm index ece01941410..3e827ba2ff6 100644 --- a/code/modules/clothing/suits/armor.dm +++ b/code/modules/clothing/suits/armor.dm @@ -146,7 +146,8 @@ name = "reactive armor" desc = "Doesn't seem to do much for some reason." var/active = 0 - var/reactivearmor_cooldown = 0//cooldown specific to reactive armor + var/reactivearmor_cooldown_duration = 0 //cooldown specific to reactive armor + var/reactivearmor_cooldown = 0 icon_state = "reactiveoff" item_state = "reactiveoff" blood_overlay_type = "armor" @@ -173,6 +174,7 @@ active = 0 src.icon_state = "reactiveoff" src.item_state = "reactiveoff" + reactivearmor_cooldown = world.time + 200 ..() //When the wearer gets hit, this armor will teleport the user a short distance away (to safety or to more danger, no one knows. That's the fun of it!) @@ -181,6 +183,7 @@ desc = "Someone seperated our Research Director from his own head!" var/tele_range = 6 var/rad_amount= 15 + reactivearmor_cooldown_duration = 100 /obj/item/clothing/suit/armor/reactive/teleport/hit_reaction(mob/living/carbon/human/owner, attack_text, final_block_chance) if(!active) @@ -207,39 +210,43 @@ return H.forceMove(picked) H.rad_act(rad_amount) - reactivearmor_cooldown = world.time + 100 + reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration return 1 return 0 -/obj/item/clothing/suit/armor/reactive/teleport/emp_act(severity) - ..() - reactivearmor_cooldown = world.time + 200 - /obj/item/clothing/suit/armor/reactive/fire name = "reactive incendiary armor" - + desc = "An experimental suit of armor with a reactive sensor array rigged to a flame emitter. For the stylish pyromaniac." /obj/item/clothing/suit/armor/reactive/fire/hit_reaction(mob/living/carbon/human/owner, attack_text) if(!active) return 0 if(prob(hit_reaction_chance)) + if(world.time < reactivearmor_cooldown) + owner.visible_message("The reactive incendiary armor on [owner] activates, but fails to send out flames as it is still recharging its flame jets!") + return owner.visible_message("The [src] blocks the [attack_text], sending out jets of flame!") for(var/mob/living/carbon/C in range(6, owner)) if(C != owner) C.fire_stacks += 8 C.IgniteMob() owner.fire_stacks = -20 + reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration return 1 return 0 /obj/item/clothing/suit/armor/reactive/stealth name = "reactive stealth armor" + desc = "An experimental suit of armor that renders the wearer invisible on detection of imminent harm, and creates a decoy that runs away from the owner. You can't fight what you can't see." /obj/item/clothing/suit/armor/reactive/stealth/hit_reaction(mob/living/carbon/human/owner, attack_text) if(!active) return 0 if(prob(hit_reaction_chance)) + if(world.time < reactivearmor_cooldown) + owner.visible_message("The reactive stealth system on [owner] activates, but is still recharging its holographic emitters!") + return var/mob/living/simple_animal/hostile/illusion/escape/E = new(owner.loc) E.Copy_Parent(owner, 50) E.GiveTarget(owner) //so it starts running right away @@ -248,15 +255,23 @@ owner.visible_message("[owner] is hit by [attack_text] in the chest!") //We pretend to be hit, since blocking it would stop the message otherwise spawn(40) owner.alpha = initial(owner.alpha) + reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration return 1 /obj/item/clothing/suit/armor/reactive/tesla name = "reactive tesla armor" + desc = "An experimental suit of armor with sensitive detectors hooked up to a huge capacitor grid, with emitters strutting out of it. Zap." /obj/item/clothing/suit/armor/reactive/tesla/hit_reaction(mob/living/carbon/human/owner, attack_text) if(!active) return 0 if(prob(hit_reaction_chance)) + if(world.time < reactivearmor_cooldown) + var/datum/effect_system/spark_spread/sparks = new /datum/effect_system/spark_spread + sparks.set_up(1, 1, src) + sparks.start() + owner.visible_message("The tesla capacitors on [owner]'s reactive telsa armor are still recharging! The armor merely emits some sparks.") + return owner.visible_message("The [src] blocks the [attack_text], sending out arcs of lightning!") for(var/mob/living/M in view(6, owner)) if(M == owner) @@ -264,9 +279,49 @@ owner.Beam(M,icon_state="lightning[rand(1, 12)]",icon='icons/effects/effects.dmi',time=5) M.adjustFireLoss(25) playsound(M, 'sound/machines/defib_zap.ogg', 50, 1, -1) + reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration return 1 -//All of the armor below is mostly unused +/obj/item/clothing/suit/armor/reactive/table + name = "reactive table armor" + desc = "If you can't beat the memes, embrace them." + var/tele_range = 10 + +/obj/item/clothing/suit/armor/reactive/table/hit_reaction(mob/living/carbon/human/owner, attack_text) + if(!active) + return 0 + if(prob(hit_reaction_chance)) + var/mob/living/carbon/human/H = owner + if(world.time < reactivearmor_cooldown) + owner.visible_message("The reactive table armor's fabricators are still on cooldown!") + return + owner.visible_message("The reactive teleport system flings [H] clear of [attack_text] and slams them into a fabricated table!") + owner.visible_message("[H] GOES ON THE TABLE!!!") + owner.Weaken(2) + var/list/turfs = new/list() + for(var/turf/T in orange(tele_range, H)) + if(T.density) + continue + if(T.x>world.maxx-tele_range || T.xworld.maxy-tele_range || T.y