diff --git a/code/controllers/subsystem/chat.dm b/code/controllers/subsystem/chat.dm index 6ba6a7b177..8d4de0c091 100644 --- a/code/controllers/subsystem/chat.dm +++ b/code/controllers/subsystem/chat.dm @@ -29,6 +29,7 @@ SUBSYSTEM_DEF(chat) target = GLOB.clients //Some macros remain in the string even after parsing and fuck up the eventual output + var/original_message = message message = replacetext(message, "\improper", "") message = replacetext(message, "\proper", "") if(handle_whitespace) @@ -45,6 +46,12 @@ SUBSYSTEM_DEF(chat) for(var/I in target) var/client/C = CLIENT_FROM_VAR(I) //Grab us a client if possible + if(!C) + return + + //Send it to the old style output window. + SEND_TEXT(C, original_message) + if(!C?.chatOutput || C.chatOutput.broken) //A player who hasn't updated his skin file. continue @@ -57,6 +64,12 @@ SUBSYSTEM_DEF(chat) else var/client/C = CLIENT_FROM_VAR(target) //Grab us a client if possible + if(!C) + return + + //Send it to the old style output window. + SEND_TEXT(C, original_message) + if(!C?.chatOutput || C.chatOutput.broken) //A player who hasn't updated his skin file. return