From d79cc5f85dff714e577c6ca1982f477fd2058f77 Mon Sep 17 00:00:00 2001 From: silicons <2003111+silicons@users.noreply.github.com> Date: Tue, 4 Aug 2020 20:57:37 -0700 Subject: [PATCH] oof --- code/modules/mob/say.dm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/code/modules/mob/say.dm b/code/modules/mob/say.dm index 3ceafe4a11..c7bf88f63b 100644 --- a/code/modules/mob/say.dm +++ b/code/modules/mob/say.dm @@ -43,6 +43,11 @@ if(GLOB.say_disabled) //This is here to try to identify lag problems to_chat(usr, "Speech is currently admin-disabled.") return + + if(length(message) > MAX_MESSAGE_LEN) + to_chat(user, message) + to_chat(user, "^^^----- The preceeding message has been DISCARDED for being over the maximum length of [max_length*2] bytes. It has NOT been sent! -----^^^") + return message = trim(copytext_char(sanitize(message), 1, MAX_MESSAGE_LEN)) clear_typing_indicator() // clear it immediately!