mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-22 12:29:46 +01:00
Spy Bug Fixes (#20651)
- [x] Spy Bugs do not work across z-levels - [x] Spy Bug labeling - [x] Spy bugs have radio wierdness Touchup to Spy Bugs to make them work after changes have negatively impacted them. --------- Signed-off-by: Ben <91219575+Ben10083@users.noreply.github.com> Co-authored-by: Ben10083 <Ben10083@users.noreply.github.com> Co-authored-by: hazelrat <83198434+hazelrat@users.noreply.github.com> Co-authored-by: Cody Brittain <1779662+Generalcamo@users.noreply.github.com>
This commit is contained in:
co-authored by
Ben10083
hazelrat
Cody Brittain
parent
e3f2b7de80
commit
61954b6cca
@@ -29,7 +29,7 @@
|
||||
. = ..()
|
||||
if(distance <= 0)
|
||||
. += "It's a tiny camera, microphone, and transmission device in a happy union."
|
||||
. += "Needs to be both configured and brought in contact with monitor device to be fully functional."
|
||||
. += "Needs to be both configured and brought in contact with monitor device to be fully functional. A pen can also be used to label the device on a given network."
|
||||
|
||||
/obj/item/device/spy_bug/attack_self(mob/user)
|
||||
radio.set_broadcasting(!radio.get_broadcasting())
|
||||
@@ -44,11 +44,17 @@
|
||||
var/obj/item/device/spy_monitor/SM = attacking_item
|
||||
SM.pair(src, user)
|
||||
return TRUE
|
||||
if(attacking_item.ispen())
|
||||
var/n_tag = sanitizeSafe( tgui_input_text(user, "What would you like to label the camera?", "Bug Labelling", default = camera.c_tag, max_length = MAX_NAME_LEN), MAX_NAME_LEN )
|
||||
if(Adjacent(user) && user.stat == CONSCIOUS && n_tag)
|
||||
camera.c_tag = n_tag
|
||||
camera.name = "[camera.initial_name] - [n_tag]"
|
||||
return TRUE
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/item/device/spy_bug/hear_talk(mob/M, var/msg, verb, datum/language/speaking)
|
||||
radio.hear_talk(M, msg, speaking)
|
||||
radio.hear_talk(M, msg, verb, speaking)
|
||||
|
||||
|
||||
/obj/item/device/spy_monitor
|
||||
@@ -108,17 +114,17 @@
|
||||
selected_camera = cameras[1]
|
||||
view_camera(user)
|
||||
|
||||
operating = 1
|
||||
operating = TRUE
|
||||
while(selected_camera && Adjacent(user))
|
||||
selected_camera = tgui_input_list(user, "Select camera bug to view.", "Spy Monitor", cameras)
|
||||
selected_camera = null
|
||||
operating = 0
|
||||
operating = FALSE
|
||||
|
||||
/obj/item/device/spy_monitor/proc/view_camera(mob/user)
|
||||
spawn(0)
|
||||
while(selected_camera && Adjacent(user))
|
||||
var/turf/T = get_turf(selected_camera)
|
||||
if(!T || !(T.z == user.z || !is_station_level(T.z) || !is_station_level(user.z)) || !selected_camera.can_use())
|
||||
if(!T || !(T.z in GetConnectedZlevels(user.z)) || !selected_camera.can_use())
|
||||
user.unset_machine()
|
||||
user.reset_view(null)
|
||||
to_chat(user, SPAN_NOTICE("[selected_camera] unavailable."))
|
||||
@@ -149,14 +155,17 @@
|
||||
// These cheap toys are accessible from the mercenary camera console as well
|
||||
network = list(NETWORK_MERCENARY)
|
||||
active_power_usage = 0
|
||||
/// Set on Initialize(), simulates initial() but for the name variable so we can restore it when needed
|
||||
var/initial_name
|
||||
|
||||
/obj/machinery/camera/spy/Initialize()
|
||||
. = ..()
|
||||
name = "DV-136ZB #[rand(1000,9999)]"
|
||||
initial_name = name
|
||||
c_tag = name
|
||||
|
||||
/obj/machinery/camera/spy/check_eye(var/mob/user as mob)
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
/obj/item/device/radio/spy
|
||||
canhear_range = 7
|
||||
|
||||
Reference in New Issue
Block a user