Adds an Escape Menu (#72906)

This commit is contained in:
Mothblocks
2023-01-26 00:25:16 -08:00
committed by GitHub
parent 908bab48a0
commit 9d0cdfe909
36 changed files with 873 additions and 78 deletions
+35 -20
View File
@@ -326,13 +326,12 @@
var/name_key_with_link = key_name(src, TRUE, TRUE)
if(ambiguious_recipient == EXTERNAL_PM_USER)
to_chat(src,
type = MESSAGE_TYPE_ADMINPM,
html = span_notice("PM to-<b>Admins</b>: [span_linkify(raw_message)]"),
confidential = TRUE)
var/datum/admin_help/new_admin_help = admin_ticket_log(src,
"<font color='red'>Reply PM from-<b>[name_key_with_link]</b> to <i>External</i>: [keyword_parsed_msg]</font>",
player_message = "<font color='red'>Reply PM from-<b>[name_key_with_link]</b> to <i>External</i>: [send_message]</font>")
new_admin_help.reply_to_admins_notification(raw_message)
var/new_help_id = new_admin_help?.id
externalreplyamount--
@@ -409,10 +408,12 @@
type = MESSAGE_TYPE_ADMINPM,
html = "<font color='red' size='4'><b>-- Administrator private message --</b></font>",
confidential = TRUE)
to_chat(recipient,
type = MESSAGE_TYPE_ADMINPM,
html = span_adminsay("Admin PM from-<b>[link_to_us]</b>: [span_linkify(send_message)]"),
confidential = TRUE)
recipient.receive_ahelp(
link_to_us,
span_linkify(send_message),
)
to_chat(recipient,
type = MESSAGE_TYPE_ADMINPM,
html = span_adminsay("<i>Click on the administrator's name to reply.</i>"),
@@ -474,10 +475,12 @@
// Admin on admin violence first
if(our_holder)
to_chat(recipient,
type = MESSAGE_TYPE_ADMINPM,
html = span_danger("Admin PM from-<b>[name_key_with_link]</b>: [span_linkify(keyword_parsed_msg)]"),
confidential = TRUE)
recipient.receive_ahelp(
name_key_with_link,
span_linkify(keyword_parsed_msg),
"danger",
)
to_chat(src,
type = MESSAGE_TYPE_ADMINPM,
html = span_notice("Admin PM to-<b>[their_name_with_link]</b>: [span_linkify(keyword_parsed_msg)]"),
@@ -510,11 +513,10 @@
type = MESSAGE_TYPE_ADMINPM,
html = span_danger("[replymsg]"),
confidential = TRUE)
to_chat(src,
type = MESSAGE_TYPE_ADMINPM,
html = span_notice("PM to-<b>Admins</b>: [span_linkify(send_message)]"),
confidential = TRUE)
ticket.reply_to_admins_notification(send_message)
SSblackbox.LogAhelp(ticket_id, "Reply", send_message, recip_ckey, our_ckey)
return TRUE
/// Notifies all admins about the existance of an admin pm, then logs the pm
@@ -726,10 +728,12 @@
type = MESSAGE_TYPE_ADMINPM,
html = "<font color='red' size='4'><b>-- Administrator private message --</b></font>",
confidential = TRUE)
to_chat(recipient,
type = MESSAGE_TYPE_ADMINPM,
html = span_adminsay("Admin PM from-<b><a href='?priv_msg=[stealthkey]'>[adminname]</A></b>: [message]"),
confidential = TRUE)
recipient.receive_ahelp(
"<a href='?priv_msg=[stealthkey]'>[adminname]</a>",
message,
)
to_chat(recipient,
type = MESSAGE_TYPE_ADMINPM,
html = span_adminsay("<i>Click on the administrator's name to reply.</i>"),
@@ -775,6 +779,17 @@
return GLOB.directory[searching_ckey]
/client/proc/receive_ahelp(reply_to, message, span_class = "adminsay")
to_chat(
src,
type = MESSAGE_TYPE_ADMINPM,
html = "<span class='[span_class]'>Admin PM from-<b>[reply_to]</b>: [message]</span>",
confidential = TRUE,
)
current_ticket?.player_replied = FALSE
SEND_SIGNAL(src, COMSIG_ADMIN_HELP_RECEIVED, message)
#undef EXTERNAL_PM_USER
#undef EXTERNALREPLYCOUNT