mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-21 19:17:50 +01:00
Stunglove overhaul: part one.
Stun gloves are now made by wiring a pair of gloves, and then attaching a battery- this shows up on the object sprite, but not on your character. Stungloves use 2500 charge per stun! This means that some low capacity batteries will make useless stungloves. To get your old inconspicous gloves back, simply cut away the wire and battery. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2439 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
/obj/item/clothing/gloves/attackby(obj/item/weapon/W, mob/user)
|
||||
if(istype(W, /obj/item/weapon/cable_coil))
|
||||
var/obj/item/weapon/cable_coil/C = W
|
||||
if(!wired)
|
||||
if(C.amount >= 2)
|
||||
C.amount -= 2
|
||||
wired = 1
|
||||
user << "You wrap some wires around [src]."
|
||||
update_icon()
|
||||
else
|
||||
user << "There is not enough wire to cover [src]."
|
||||
else
|
||||
user << "[src] are already wired."
|
||||
|
||||
else if(istype(W, /obj/item/weapon/cell))
|
||||
if(!wired)
|
||||
user << "[src] need to be wired first."
|
||||
else if(!cell)
|
||||
user.drop_item()
|
||||
W.loc = src
|
||||
cell = W
|
||||
user << "You attach a cell to [src]."
|
||||
update_icon()
|
||||
else
|
||||
user << "[src] already have a cell."
|
||||
|
||||
else if(istype(W, /obj/item/weapon/wirecutters))
|
||||
if(cell)
|
||||
user << "You cut the cell away from [src]."
|
||||
cell.loc = get_turf(src.loc)
|
||||
cell = 0
|
||||
update_icon()
|
||||
return
|
||||
if(wired) //wires disappear into the void because fuck that shit
|
||||
user << "You cut the wires away from [src]."
|
||||
wired = 0
|
||||
update_icon()
|
||||
..()
|
||||
return
|
||||
|
||||
/obj/item/clothing/gloves/update_icon() //beep beep this'll probably break everything
|
||||
..()
|
||||
overlays = null
|
||||
if(wired)
|
||||
overlays += "gloves_wire"
|
||||
if(cell)
|
||||
overlays += "gloves_cell"
|
||||
Reference in New Issue
Block a user