From fbabd14798d583e4370e8de8403533da0fbc1a94 Mon Sep 17 00:00:00 2001 From: CitadelStationBot Date: Mon, 7 Aug 2017 12:26:15 -0500 Subject: [PATCH] Fixes adminhelp sending the wrong message to players --- code/modules/admin/verbs/adminhelp.dm | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/code/modules/admin/verbs/adminhelp.dm b/code/modules/admin/verbs/adminhelp.dm index 0177798e25..44755c46fc 100644 --- a/code/modules/admin/verbs/adminhelp.dm +++ b/code/modules/admin/verbs/adminhelp.dm @@ -194,7 +194,7 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new) AddInteraction("[key_name_admin(usr)] PM'd [LinkedReplyName()]") message_admins("Ticket [TicketHref("#[id]")] created") else - MessageNoRecipient(parsed_message) + MessageNoRecipient(msg, parsed_message) //send it to irc if nobody is on and tell us how many were on var/admin_number_present = send2irc_adminless_only(initiator_ckey, "Ticket #[id]: [name]") @@ -249,18 +249,19 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new) //message from the initiator without a target, all admins will see this //won't bug irc -/datum/admin_help/proc/MessageNoRecipient(msg) +/datum/admin_help/proc/MessageNoRecipient(msg, parsed_msg) var/ref_src = "\ref[src]" - var/chat_msg = "Ticket [TicketHref("#[id]", ref_src)]: [LinkedReplyName(ref_src)] [FullMonty(ref_src)]: [msg]" + //Message to be sent to all admins + var/admin_msg = "Ticket [TicketHref("#[id]", ref_src)]: [LinkedReplyName(ref_src)] [FullMonty(ref_src)]: [parsed_msg]" AddInteraction("[LinkedReplyName(ref_src)]: [msg]") + //send this msg to all admins - for(var/client/X in GLOB.admins) if(X.prefs.toggles & SOUND_ADMINHELP) X << 'sound/effects/adminhelp.ogg' window_flash(X, ignorepref = TRUE) - to_chat(X, chat_msg) + to_chat(X, admin_msg) //show it to the person adminhelping too to_chat(initiator, "PM to-Admins: [msg]")