Plasma Cutter Things (#8445)

Plasma cutters can now have their power cells removed with screwdrivers, and replaced by using the power cells on them.
Plasma cutters now do 20 damage, up from 15.
More things can now be disassembled with the plasma cutter. Non-reinforced walls, non-reinforced tables, grills, machine frames.
This commit is contained in:
Geeves
2020-03-21 12:46:25 +01:00
committed by GitHub
parent d46857cf5c
commit 28391cad07
6 changed files with 79 additions and 15 deletions
+9 -1
View File
@@ -92,12 +92,20 @@
src.health -= damage*0.2
spawn(0) healthcheck() //spawn to make sure we return properly if the grille is deleted
/obj/structure/grille/attackby(obj/item/W as obj, mob/user as mob)
/obj/structure/grille/attackby(obj/item/W, mob/user)
if(W.iswirecutter())
if(!shock(user, 100))
playsound(loc, 'sound/items/Wirecutter.ogg', 100, 1)
new /obj/item/stack/rods(get_turf(src), destroyed ? 1 : 2)
qdel(src)
else if(istype(W, /obj/item/gun/energy/plasmacutter))
var/obj/item/gun/energy/plasmacutter/PC = W
if(!PC.power_supply)
to_chat(user, SPAN_WARNING("\The [src] doesn't have a power supply installed!"))
return
playsound(get_turf(src), PC.fire_sound, 100, TRUE)
new /obj/item/stack/rods(get_turf(src), destroyed ? 1 : 2)
qdel(src)
else if((W.isscrewdriver()) && (istype(loc, /turf/simulated) || anchored))
if(!shock(user, 90))
playsound(loc, 'sound/items/Screwdriver.ogg', 100, 1)