From dad0a49a6616893da8dde42c7b5987afb6772d18 Mon Sep 17 00:00:00 2001 From: Runa Dacino Date: Fri, 1 Jul 2022 16:22:42 +0200 Subject: [PATCH] Ports ability to make press camera drones Ports ability to make press camera drones Ports https://github.com/Baystation12/Baystation12/pull/14875 1. Get Robot head 2. Infrared sensor (like you would for TTV or grenades) -> Makes the assembly. Looks like robot head. 3. Add robot camera (from fabricator) 4. Add Tape recorder 5. Add 6 wires 6. Use wirecutters on assembly 7. Add 1 steel 8. Done Tested on current build, works like a charm. Works with both empty and full tape recorder. --- code/game/objects/items/devices/tvcamera.dm | 79 ++++++++++++++++++++- 1 file changed, 76 insertions(+), 3 deletions(-) diff --git a/code/game/objects/items/devices/tvcamera.dm b/code/game/objects/items/devices/tvcamera.dm index 78f5a381c70..849a649894f 100644 --- a/code/game/objects/items/devices/tvcamera.dm +++ b/code/game/objects/items/devices/tvcamera.dm @@ -48,7 +48,7 @@ add_fingerprint(user) user.set_machine(src) show_ui(user) - + /obj/item/device/tvcamera/proc/show_ui(mob/user) var/dat = list() dat += "Channel name is: [channel ? channel : "unidentified broadcast"]
" @@ -93,7 +93,7 @@ /obj/item/device/tvcamera/proc/show_tvs(atom/thing) if(showing) hide_tvs(showing) - + showing = weakref(thing) showing_name = "[thing]" for(var/obj/machinery/computer/security/telescreen/entertainment/ES as anything in GLOB.entertainment_screens) @@ -126,7 +126,7 @@ /obj/item/device/tvcamera/process() if(!showing) return PROCESS_KILL - + var/atom/A = showing.resolve() if(!A || QDELETED(A)) show_tvs(loc) @@ -148,3 +148,76 @@ H.update_inv_l_hand() H.update_inv_belt() + +//Assembly by roboticist + +/obj/item/robot_parts/head/attackby(var/obj/item/device/assembly/S, mob/user as mob) + if(!istype(S, /obj/item/device/assembly/infra)) + ..() + return + var/obj/item/weapon/TVAssembly/A = new(user) + qdel(S) + user.put_in_hands(A) + to_chat(user, "You add the infrared sensor to the robot head.") + user.drop_from_inventory(src) + qdel(src) + + +/obj/item/weapon/TVAssembly + name = "\improper TV Camera Assembly" + desc = "A robotic head with an infrared sensor inside." + icon = 'icons/obj/robot_parts.dmi' + icon_state = "head" + item_state = "head" + var/buildstep = 0 + w_class = ITEMSIZE_LARGE + +/obj/item/weapon/TVAssembly/attackby(W, mob/user) + switch(buildstep) + if(0) + if(istype(W, /obj/item/robot_parts/robot_component/camera)) + var/obj/item/robot_parts/robot_component/camera/CA = W + to_chat(user, "You add the camera module to [src]") + user.drop_item() + qdel(CA) + desc = "This TV camera assembly has a camera module." + buildstep++ + if(1) + if(istype(W, /obj/item/device/taperecorder)) + var/obj/item/device/taperecorder/T = W + user.drop_item() + qdel(T) + buildstep++ + to_chat(user, "You add the tape recorder to [src]") + if(2) + if(istype(W, /obj/item/stack/cable_coil)) + var/obj/item/stack/cable_coil/C = W + if(!C.use(3)) + to_chat(user, "You need six cable coils to wire the devices.") + ..() + return + C.use(3) + buildstep++ + to_chat(user, "You wire the assembly") + desc = "This TV camera assembly has wires sticking out" + return + if(3) + if(istype(W, /obj/item/weapon/tool/wirecutters)) + to_chat(user, " You trim the wires.") + buildstep++ + desc = "This TV camera assembly needs casing." + return + if(4) + if(istype(W, /obj/item/stack/material/steel)) + var/obj/item/stack/material/steel/S = W + buildstep++ + S.use(1) + to_chat(user, "You encase the assembly in a Ward-Takeshi casing.") + var/turf/T = get_turf(src) + new /obj/item/device/tvcamera(T) + user.drop_from_inventory(src) + qdel(src) + return + + ..() +