From 56b56ef2b96de6d7428e7e3583f5d0fcaeb5bfad Mon Sep 17 00:00:00 2001 From: ChillerDragon Date: Fri, 23 Aug 2024 19:20:15 +0800 Subject: [PATCH] Fix save code not being censored in streamer mode Closed #8790 --- src/game/client/components/chat.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/game/client/components/chat.cpp b/src/game/client/components/chat.cpp index 1ca2c8e08..e73b94f73 100644 --- a/src/game/client/components/chat.cpp +++ b/src/game/client/components/chat.cpp @@ -992,7 +992,11 @@ void CChat::OnPrepareLines(float y) const char *pText = Line.m_aText; if(Config()->m_ClStreamerMode && Line.m_ClientId == SERVER_MSG) { - if(str_startswith(Line.m_aText, "Team save in progress. You'll be able to load with '/load") && str_endswith(Line.m_aText, "if it fails")) + if(str_startswith(Line.m_aText, "Team save in progress. You'll be able to load with '/load ") && str_endswith(Line.m_aText, "'")) + { + pText = "Team save in progress. You'll be able to load with '/load ***'"; + } + else if(str_startswith(Line.m_aText, "Team save in progress. You'll be able to load with '/load") && str_endswith(Line.m_aText, "if it fails")) { pText = "Team save in progress. You'll be able to load with '/load ***' if save is successful or with '/load *** *** ***' if it fails"; }