mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 12:07:27 +01:00
Refactors Electrocution and Tesla Zapping (#15357)
* Refactors Electrocution and Tesla Zapping---Improves Supermatter and Tesla * forgot this one * fixes and styling * last tidbits hopefully * machine frames * use flags * styling
This commit is contained in:
@@ -349,11 +349,6 @@
|
||||
BD.attack_hand(usr)
|
||||
open()
|
||||
|
||||
/obj/structure/closet/tesla_act(var/power)
|
||||
..()
|
||||
visible_message("<span class='danger'>[src] is blown apart by the bolt of electricity!</span>", "<span class='danger'>You hear a metallic screeching sound.</span>")
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/closet/get_remote_view_fullscreens(mob/user)
|
||||
if(user.stat == DEAD || !(user.sight & (SEEOBJS|SEEMOBS)))
|
||||
user.overlay_fullscreen("remote_view", /obj/screen/fullscreen/impaired, 1)
|
||||
|
||||
@@ -254,7 +254,7 @@
|
||||
var/obj/structure/cable/C = T.get_cable_node()
|
||||
if(C)
|
||||
playsound(src, 'sound/magic/lightningshock.ogg', 100, TRUE, extrarange = 5)
|
||||
tesla_zap(src, 3, C.newavail() * 0.01) //Zap for 1/100 of the amount of power. At a million watts in the grid, it will be as powerful as a tesla revolver shot.
|
||||
tesla_zap(src, 3, C.newavail() * 0.01, ZAP_MOB_DAMAGE | ZAP_OBJ_DAMAGE | ZAP_MOB_STUN | ZAP_ALLOW_DUPLICATES) //Zap for 1/100 of the amount of power. At a million watts in the grid, it will be as powerful as a tesla revolver shot.
|
||||
C.add_delayedload(C.newavail() * 0.0375) // you can gain up to 3.5 via the 4x upgrades power is halved by the pole so thats 2x then 1X then .5X for 3.5x the 3 bounces shock.
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -122,7 +122,7 @@
|
||||
if(!shockcd)
|
||||
if(isliving(user))
|
||||
var/mob/living/M = user
|
||||
M.electrocute_act(15, "Energy Barrier", safety = TRUE)
|
||||
M.electrocute_act(15, "Energy Barrier")
|
||||
shockcd = TRUE
|
||||
addtimer(CALLBACK(src, .proc/cooldown), 5)
|
||||
|
||||
@@ -134,6 +134,6 @@
|
||||
return
|
||||
|
||||
var/mob/living/M = AM
|
||||
M.electrocute_act(15, "Energy Barrier", safety = TRUE)
|
||||
M.electrocute_act(15, "Energy Barrier")
|
||||
shockcd = TRUE
|
||||
addtimer(CALLBACK(src, .proc/cooldown), 5)
|
||||
|
||||
Reference in New Issue
Block a user