Merge pull request #13375 from timothyteakettle/emp-rework
the emp rework (emp severity reduces as you move from epicentre, severity is 1-100)
This commit is contained in:
@@ -61,24 +61,18 @@
|
||||
playsound(src,'sound/effects/sparks4.ogg',50,1)
|
||||
qdel(src)
|
||||
|
||||
/obj/item/wormhole_jaunter/emp_act(power)
|
||||
/obj/item/wormhole_jaunter/emp_act(severity)
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
|
||||
var/mob/M = loc
|
||||
if(istype(M))
|
||||
var/triggered = FALSE
|
||||
if(M.get_item_by_slot(SLOT_BELT) == src)
|
||||
if(power == 1)
|
||||
triggered = TRUE
|
||||
else if(power == 2 && prob(50))
|
||||
triggered = TRUE
|
||||
|
||||
if(triggered)
|
||||
M.visible_message("<span class='warning'>[src] overloads and activates!</span>")
|
||||
SSblackbox.record_feedback("tally", "jaunter", 1, "EMP") // EMP accidental activation
|
||||
activate(M)
|
||||
if(prob(severity))
|
||||
M.visible_message("<span class='warning'>[src] overloads and activates!</span>")
|
||||
SSblackbox.record_feedback("tally", "jaunter", 1, "EMP") // EMP accidental activation
|
||||
activate(M)
|
||||
|
||||
/obj/item/wormhole_jaunter/proc/chasm_react(mob/source, datum/component/chasm/C)
|
||||
to_chat(source, "Your [name] activates, saving you from the chasm!</span>")
|
||||
|
||||
Reference in New Issue
Block a user