Ninja File Structure Rework

Restructures the ninja files into a more spaced-out version, compliments
of /TG/. The energy katana is also their handiwork.

Add an emag act to crates and lockers instead of handling everything in
attackby.
This commit is contained in:
SamCroswell
2015-03-13 20:42:54 -04:00
parent addfbe449e
commit 62ae69c816
36 changed files with 764 additions and 414 deletions

View File

@@ -295,19 +295,23 @@
if(is_type_in_list(W, list(/obj/item/stack/packageWrap, /obj/item/stack/cable_coil, /obj/item/device/radio/electropack, /obj/item/weapon/wirecutters)))
return ..()
if(locked && (istype(W, /obj/item/weapon/card/emag)||istype(W, /obj/item/weapon/melee/energy/blade)))
overlays += sparks
spawn(6) overlays -= sparks //Tried lots of stuff but nothing works right. so i have to use this *sadface*
playsound(src.loc, "sparks", 60, 1)
src.locked = 0
src.broken = 1
update_icon()
user << "<span class='notice'>You unlock \the [src].</span>"
emag_act()
return
if(!opened)
src.togglelock(user)
return
return ..()
/obj/structure/closet/crate/secure/emag_act()
overlays += sparks
spawn(6) overlays -= sparks //Tried lots of stuff but nothing works right. so i have to use this *sadface*
playsound(src.loc, "sparks", 60, 1)
src.locked = 0
src.broken = 1
update_icon()
usr << "<span class='notice'>You unlock \the [src].</span>"
return
/obj/structure/closet/crate/secure/emp_act(severity)
for(var/obj/O in src)
O.emp_act(severity)