mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-09 16:12:17 +00:00
[MIRROR] JSON Logging Refactor (#11623)
Co-authored-by: Selis <12716288+ItsSelis@users.noreply.github.com> Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
272afa33c8
commit
5a62077f2c
@@ -381,7 +381,7 @@
|
||||
if(text)
|
||||
exonet.send_message(their_address, "text", text)
|
||||
im_list += list(list("address" = exonet.address, "to_address" = their_address, "im" = text))
|
||||
log_pda("(COMM: [src]) sent \"[text]\" to [exonet.get_atom_from_address(their_address)]", ui.user)
|
||||
ui.user.log_talk("(COMM: [src]) sent \"[text]\" to [exonet.get_atom_from_address(their_address)]", LOG_PDA)
|
||||
var/obj/item/communicator/comm = exonet.get_atom_from_address(their_address)
|
||||
to_chat(ui.user, span_notice("[icon2html(src, ui.user.client)] Sent message to [istype(comm, /obj/item/communicator) ? comm.owner : comm.name], <b>\"[text]\"</b> (<a href='byond://?src=\ref[src];action=Reply;target=\ref[exonet.get_atom_from_address(comm.exonet.address)]'>Reply</a>)"))
|
||||
for(var/mob/M in GLOB.player_list)
|
||||
|
||||
@@ -107,7 +107,7 @@
|
||||
if(message)
|
||||
exonet.send_message(comm.exonet.address, "text", message)
|
||||
im_list += list(list("address" = exonet.address, "to_address" = comm.exonet.address, "im" = message))
|
||||
log_pda("(COMM: [src]) sent \"[message]\" to [exonet.get_atom_from_address(comm.exonet.address)]", usr)
|
||||
usr.client.mob.log_talk("(COMM: [src]) sent \"[message]\" to [exonet.get_atom_from_address(comm.exonet.address)]", LOG_PDA)
|
||||
to_chat(usr, span_notice("[icon2html(src,usr.client)] Sent message to [istype(comm, /obj/item/communicator) ? comm.owner : comm.name], <b>\"[message]\"</b> (<a href='byond://?src=\ref[src];action=Reply;target=\ref[exonet.get_atom_from_address(comm.exonet.address)]'>Reply</a>)"))
|
||||
|
||||
// Verb: text_communicator()
|
||||
@@ -159,7 +159,7 @@
|
||||
|
||||
to_chat(src, span_notice("You have sent '[text_message]' to [chosen_communicator]."))
|
||||
exonet_messages.Add(span_bold("To [chosen_communicator]:") + "<br>[text_message]")
|
||||
log_pda("(DCOMM: [src]) sent \"[text_message]\" to [chosen_communicator]", src)
|
||||
log_talk("(DCOMM: [src]) sent \"[text_message]\" to [chosen_communicator]", LOG_PDA)
|
||||
for(var/mob/M in GLOB.player_list)
|
||||
if(M.stat == DEAD && M.client?.prefs?.read_preference(/datum/preference/toggle/ghost_ears))
|
||||
if(isnewplayer(M) || M.forbid_seeing_deadchat)
|
||||
|
||||
@@ -133,3 +133,58 @@
|
||||
/obj/item/encryptionkey/ent
|
||||
name = "entertainment encryption key"
|
||||
channels = list(CHANNEL_ENTERTAINMENT = 1)
|
||||
|
||||
/obj/item/encryptionkey/heads/hop
|
||||
name = "head of personnel's encryption key"
|
||||
icon_state = "hop_cypherkey"
|
||||
channels = list(CHANNEL_SUPPLY = 1, CHANNEL_SERVICE = 1, CHANNEL_COMMAND = 1, CHANNEL_SECURITY = 1, CHANNEL_EXPLORATION = 1)
|
||||
|
||||
/obj/item/encryptionkey/heads/ai_integrated
|
||||
name = "ai integrated encryption key"
|
||||
desc = "Integrated encryption key"
|
||||
icon_state = "cap_cypherkey"
|
||||
channels = list(CHANNEL_COMMAND = 1, CHANNEL_SECURITY = 1, CHANNEL_ENGINEERING = 1, CHANNEL_SCIENCE = 1, CHANNEL_MEDICAL = 1, CHANNEL_SUPPLY = 1, CHANNEL_SERVICE = 1, CHANNEL_AI_PRIVATE = 1, CHANNEL_EXPLORATION = 1)
|
||||
|
||||
/obj/item/encryptionkey/heads/captain
|
||||
name = "site manager's encryption key"
|
||||
icon_state = "cap_cypherkey"
|
||||
channels = list(CHANNEL_COMMAND = 1, CHANNEL_SECURITY = 1, CHANNEL_ENGINEERING = 1, CHANNEL_SCIENCE = 1, CHANNEL_MEDICAL = 1, CHANNEL_SUPPLY = 1, CHANNEL_SERVICE = 1, CHANNEL_EXPLORATION = 1)
|
||||
|
||||
/obj/item/encryptionkey/heads/rd
|
||||
name = "research director's encryption key"
|
||||
icon_state = "rd_cypherkey"
|
||||
channels = list(CHANNEL_COMMAND = 1, CHANNEL_SCIENCE = 1)
|
||||
|
||||
/obj/item/encryptionkey/ert
|
||||
channels = list(CHANNEL_RESPONSE_TEAM = 1, CHANNEL_SCIENCE = 1, CHANNEL_COMMAND = 1, CHANNEL_MEDICAL = 1, CHANNEL_ENGINEERING = 1, CHANNEL_SECURITY = 1, CHANNEL_SUPPLY = 1, CHANNEL_SERVICE = 1, CHANNEL_EXPLORATION = 1)
|
||||
|
||||
/obj/item/encryptionkey/omni //Literally only for the admin intercoms
|
||||
channels = list(CHANNEL_MERCENARY = 1, CHANNEL_RAIDER = 1, CHANNEL_RESPONSE_TEAM = 1, CHANNEL_SCIENCE = 1, CHANNEL_COMMAND = 1, CHANNEL_MEDICAL = 1, CHANNEL_ENGINEERING = 1, CHANNEL_SECURITY = 1, CHANNEL_SUPPLY = 1, CHANNEL_SERVICE = 1, CHANNEL_EXPLORATION = 1)
|
||||
|
||||
/obj/item/encryptionkey/pathfinder
|
||||
name = "pathfinder's encryption key"
|
||||
icon_state = "com_cypherkey"
|
||||
channels = list(CHANNEL_COMMAND = 1, CHANNEL_EXPLORATION = 1)
|
||||
|
||||
/obj/item/encryptionkey/qm
|
||||
name = "quartermaster's encryption key"
|
||||
icon_state = "qm_cypherkey"
|
||||
channels = list(CHANNEL_COMMAND = 1, CHANNEL_SUPPLY = 1)
|
||||
|
||||
/obj/item/encryptionkey/pilot
|
||||
name = "pilot's encryption key"
|
||||
icon_state = "cypherkey"
|
||||
channels = list(CHANNEL_EXPLORATION = 1)
|
||||
|
||||
/obj/item/encryptionkey/explorer
|
||||
name = "away team's encryption key"
|
||||
icon_state = "rob_cypherkey"
|
||||
channels = list(CHANNEL_EXPLORATION = 1)
|
||||
|
||||
/obj/item/encryptionkey/sar
|
||||
name = "fm's encryption key"
|
||||
icon_state = "med_cypherkey"
|
||||
channels = list(CHANNEL_MEDICAL = 1, CHANNEL_EXPLORATION = 1)
|
||||
|
||||
/obj/item/encryptionkey/talon
|
||||
channels = list(CHANNEL_TALON = 1)
|
||||
|
||||
@@ -119,3 +119,18 @@ GLOBAL_LIST_EMPTY(active_radio_jammers)
|
||||
cut_overlays()
|
||||
add_overlay("jammer_overlay_[overlay_percent]")
|
||||
last_overlay_percent = overlay_percent
|
||||
|
||||
//Unlimited use, unlimited range jammer for admins. Turn it on, drop it somewhere, it works.
|
||||
/obj/item/radio_jammer/admin
|
||||
jam_range = 255
|
||||
tick_cost = 0
|
||||
|
||||
/proc/is_vore_jammed(var/obj/radio)
|
||||
var/atom/current = radio
|
||||
while(current.loc)
|
||||
if(isbelly(current.loc))
|
||||
var/obj/belly/B = current.loc
|
||||
if(B.mode_flags & DM_FLAG_JAMSENSORS)
|
||||
return TRUE
|
||||
current = current.loc
|
||||
return FALSE
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
//Unlimited use, unlimited range jammer for admins. Turn it on, drop it somewhere, it works.
|
||||
/obj/item/radio_jammer/admin
|
||||
jam_range = 255
|
||||
tick_cost = 0
|
||||
|
||||
/proc/is_vore_jammed(var/obj/radio)
|
||||
var/atom/current = radio
|
||||
while(current.loc)
|
||||
if(isbelly(current.loc))
|
||||
var/obj/belly/B = current.loc
|
||||
if(B.mode_flags & DM_FLAG_JAMSENSORS)
|
||||
return TRUE
|
||||
current = current.loc
|
||||
return FALSE
|
||||
@@ -82,7 +82,7 @@
|
||||
AIO.link_radio(src)
|
||||
break
|
||||
if(!bs_tx_weakref)
|
||||
testing("A radio [src] at [x],[y],[z] specified bluespace prelink IDs, but the machines with corresponding IDs ([bs_tx_preload_id], [bs_rx_preload_id]) couldn't be found.")
|
||||
log_mapping("A radio [src] at [x],[y],[z] specified bluespace prelink IDs, but the machines with corresponding IDs ([bs_tx_preload_id], [bs_rx_preload_id]) couldn't be found.")
|
||||
|
||||
if(bs_rx_preload_id)
|
||||
var/found = 0
|
||||
@@ -100,7 +100,7 @@
|
||||
found = 1
|
||||
break
|
||||
if(!found)
|
||||
testing("A radio [src] at [x],[y],[z] specified bluespace prelink IDs, but the machines with corresponding IDs ([bs_tx_preload_id], [bs_rx_preload_id]) couldn't be found.")
|
||||
log_mapping("A radio [src] at [x],[y],[z] specified bluespace prelink IDs, but the machines with corresponding IDs ([bs_tx_preload_id], [bs_rx_preload_id]) couldn't be found.")
|
||||
|
||||
/obj/item/radio/Destroy()
|
||||
qdel(wires)
|
||||
@@ -821,3 +821,35 @@ GLOBAL_DATUM(autospeaker, /mob/living/silicon/ai/announcer)
|
||||
bs_rx_preload_id = "Broadcaster A" //Recveive from a transmitter
|
||||
|
||||
#undef CANBROADCAST_INNERBOX
|
||||
|
||||
/obj/item/radio/phone
|
||||
subspace_transmission = TRUE
|
||||
canhear_range = 0
|
||||
adhoc_fallback = TRUE
|
||||
|
||||
/obj/item/radio/emergency
|
||||
name = "Medbay Emergency Radio Link"
|
||||
icon_state = "med_walkietalkie"
|
||||
frequency = MED_I_FREQ
|
||||
subspace_transmission = TRUE
|
||||
adhoc_fallback = TRUE
|
||||
|
||||
/obj/item/radio/emergency/Initialize(mapload)
|
||||
. = ..()
|
||||
internal_channels = GLOB.default_medbay_channels.Copy()
|
||||
|
||||
/obj/item/bluespaceradio/tether_prelinked
|
||||
name = "bluespace radio (tether)"
|
||||
handset = /obj/item/radio/bluespacehandset/linked/tether_prelinked
|
||||
|
||||
/obj/item/radio/bluespacehandset/linked/tether_prelinked
|
||||
bs_tx_preload_id = "tether_rx" //Transmit to a receiver
|
||||
bs_rx_preload_id = "tether_tx" //Recveive from a transmitter
|
||||
|
||||
/obj/item/bluespaceradio/talon_prelinked
|
||||
name = "bluespace radio (talon)"
|
||||
handset = /obj/item/radio/bluespacehandset/linked/talon_prelinked
|
||||
|
||||
/obj/item/radio/bluespacehandset/linked/talon_prelinked
|
||||
bs_tx_preload_id = "talon_aio" //Transmit to a receiver
|
||||
bs_rx_preload_id = "talon_aio" //Recveive from a transmitter
|
||||
|
||||
@@ -1,33 +0,0 @@
|
||||
/obj/item/radio/phone
|
||||
subspace_transmission = TRUE
|
||||
canhear_range = 0
|
||||
adhoc_fallback = TRUE
|
||||
|
||||
/obj/item/radio/emergency
|
||||
name = "Medbay Emergency Radio Link"
|
||||
icon_state = "med_walkietalkie"
|
||||
frequency = MED_I_FREQ
|
||||
subspace_transmission = TRUE
|
||||
adhoc_fallback = TRUE
|
||||
|
||||
/obj/item/radio/emergency/Initialize(mapload)
|
||||
. = ..()
|
||||
internal_channels = GLOB.default_medbay_channels.Copy()
|
||||
|
||||
|
||||
|
||||
/obj/item/bluespaceradio/tether_prelinked
|
||||
name = "bluespace radio (tether)"
|
||||
handset = /obj/item/radio/bluespacehandset/linked/tether_prelinked
|
||||
|
||||
/obj/item/radio/bluespacehandset/linked/tether_prelinked
|
||||
bs_tx_preload_id = "tether_rx" //Transmit to a receiver
|
||||
bs_rx_preload_id = "tether_tx" //Recveive from a transmitter
|
||||
|
||||
/obj/item/bluespaceradio/talon_prelinked
|
||||
name = "bluespace radio (talon)"
|
||||
handset = /obj/item/radio/bluespacehandset/linked/talon_prelinked
|
||||
|
||||
/obj/item/radio/bluespacehandset/linked/talon_prelinked
|
||||
bs_tx_preload_id = "talon_aio" //Transmit to a receiver
|
||||
bs_rx_preload_id = "talon_aio" //Recveive from a transmitter
|
||||
@@ -60,7 +60,7 @@
|
||||
return
|
||||
var/atom/movable/AM = WF.resolve()
|
||||
if(isnull(AM))
|
||||
log_debug("DEBUG: HasProximity called without reference on [src].")
|
||||
log_runtime("DEBUG: HasProximity called without reference on [src].")
|
||||
attached_device?.HasProximity(T, WF, old_loc)
|
||||
|
||||
/obj/item/transfer_valve/Moved(old_loc, direction, forced)
|
||||
|
||||
@@ -114,5 +114,5 @@ var/datum/uplink_random_selection/all_uplink_selection = new/datum/uplink_random
|
||||
|
||||
/proc/debug_uplink_item_assoc_list()
|
||||
for(var/key in uplink.items_assoc)
|
||||
to_world("[key] - [uplink.items_assoc[key]]")
|
||||
to_chat(world, "[key] - [uplink.items_assoc[key]]")
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user