Fixes an exploit with the power gloves (#19502)

This commit is contained in:
BiancaWilkson
2022-10-24 21:48:42 +01:00
committed by GitHub
parent 2c5d9ffb43
commit 2c65e0901c
2 changed files with 4 additions and 0 deletions
+3
View File
@@ -60,6 +60,9 @@
to_chat(user, "<span class='warning'>There is no cable here to power the gloves.</span>")
return
var/turf/target_turf = get_turf(A)
if(get_dist(T, target_turf) > P.shock_range)
to_chat(user, "<span class='warning'>The target is too far away.</span>")
return
target_turf.hotspot_expose(2000, 400)
playsound(user.loc, 'sound/effects/eleczap.ogg', 40, 1)
+1
View File
@@ -17,6 +17,7 @@
var/last_shocked = 0
var/shock_delay = 40
var/unlimited_power = FALSE // Does this really need explanation?
var/shock_range = 7
/obj/item/clothing/gloves/color/yellow/power/detailed_examine_antag()
return "These are a pair of power gloves, and can be used to fire bolts of electricity while standing over powered power cables."