From 65fd10893d36acefbcee4ad4f55aa65f4db4c5c5 Mon Sep 17 00:00:00 2001 From: MoreRobustThanYou Date: Tue, 30 Jan 2018 02:42:42 -0500 Subject: [PATCH] Announced messages while drunk will be slurred (#34651) * Announced messages while drunk will be slurred * Minor announcements, too! * Update requests_console.dm * Update communications.dm * Fixup. * Update requests_console.dm --- code/controllers/subsystem/communications.dm | 2 +- code/game/machinery/requests_console.dm | 3 +++ code/modules/mob/living/say.dm | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/code/controllers/subsystem/communications.dm b/code/controllers/subsystem/communications.dm index fcf7dba607e..d4838a21c3c 100644 --- a/code/controllers/subsystem/communications.dm +++ b/code/controllers/subsystem/communications.dm @@ -23,7 +23,7 @@ SUBSYSTEM_DEF(communications) minor_announce(html_decode(input),"[user.name] Announces:") silicon_message_cooldown = world.time + COMMUNICATION_COOLDOWN_AI else - priority_announce(html_decode(input), null, 'sound/misc/announce.ogg', "Captain") + priority_announce(html_decode(user.treat_message(input)), null, 'sound/misc/announce.ogg', "Captain") nonsilicon_message_cooldown = world.time + COMMUNICATION_COOLDOWN log_talk(user,"[key_name(user)] has made a priority announcement: [input]",LOGSAY) message_admins("[key_name_admin(user)] has made a priority announcement.") diff --git a/code/game/machinery/requests_console.dm b/code/game/machinery/requests_console.dm index c65b9a321ab..3e870bb46c5 100644 --- a/code/game/machinery/requests_console.dm +++ b/code/game/machinery/requests_console.dm @@ -302,6 +302,9 @@ GLOBAL_LIST_EMPTY(allConsoles) if(href_list["sendAnnouncement"]) if(!announcementConsole) return + if(isliving(usr)) + var/mob/living/L = usr + message = L.treat_message(message) minor_announce(message, "[department] Announcement:") GLOB.news_network.SubmitArticle(message, department, "Station Announcements", null) log_talk(usr,"[key_name(usr)] has made a station announcement: [message]",LOGSAY) diff --git a/code/modules/mob/living/say.dm b/code/modules/mob/living/say.dm index 650ac3e1a65..737069a44d9 100644 --- a/code/modules/mob/living/say.dm +++ b/code/modules/mob/living/say.dm @@ -381,4 +381,4 @@ GLOBAL_LIST_INIT(department_radio_keys, list( if(.) return . - . = ..() + . = ..() \ No newline at end of file