Construction Update

This commit is contained in:
SinTwo
2016-03-22 16:37:45 -04:00
parent fbbfb78dec
commit b356f5cf21
154 changed files with 2223 additions and 926 deletions

View File

@@ -36,6 +36,7 @@ var/const/HOLOPAD_MODE = RANGE_BASED
desc = "It's a floor-mounted device for projecting holographic images. It is activated remotely."
icon_state = "holopad0"
show_messages = 1
circuit = /obj/item/weapon/circuitboard/holopad
layer = TURF_LAYER+0.1 //Preventing mice and drones from sneaking under them.
@@ -47,6 +48,30 @@ var/const/HOLOPAD_MODE = RANGE_BASED
var/last_request = 0 //to prevent request spam. ~Carn
var/holo_range = 5 // Change to change how far the AI can move away from the holopad before deactivating.
/obj/machinery/hologram/holopad/attackby(obj/item/I as obj, user as mob)
if(istype(I, /obj/item/weapon/screwdriver) && circuit)
user << "<span class='notice'>You start removing the glass.</span>"
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
if(do_after(user, 20))
var/obj/structure/frame/A = new /obj/structure/frame( src.loc )
var/obj/item/weapon/circuitboard/M = new circuit( A )
A.circuit = M
A.anchored = 1
A.density = 1
A.frame_type = "holopad"
for (var/obj/C in src)
C.forceMove(loc)
user << "<span class='notice'>You remove the glass.</span>"
A.state = 4
A.icon_state = "holopad_4"
M.deconstruct(src)
for (var/mob/living/silicon/ai/master in masters)
clear_holo(master)
qdel(src)
else
src.attack_hand(user)
return
/obj/machinery/hologram/holopad/attack_hand(var/mob/living/carbon/human/user) //Carn: Hologram requests.
if(!istype(user))
return