1
0
mirror of https://github.com/RaidMax/IW4M-Admin.git synced 2025-06-10 23:31:13 -05:00

Merge branch 'release/pre' of github.com:RaidMax/IW4M-Admin into release/pre

This commit is contained in:
RaidMax
2023-05-01 21:41:08 -05:00
2 changed files with 9 additions and 5 deletions

View File

@ -588,11 +588,15 @@ namespace IW4MAdmin.Application.EventParsers
return null;
}
var message = matchResult.Values[Configuration.Say.GroupMapping[ParserRegex.GroupType.Message]]
.Replace(Configuration.LocalizeText, "")
.Trim();
var message = new string(matchResult.Values[Configuration.Say.GroupMapping[ParserRegex.GroupType.Message]]
.Where(c => !char.IsControl(c)).ToArray());
if (message.Length <= 0)
if (message.StartsWith("/"))
{
message = message[1..];
}
if (String.IsNullOrEmpty(message))
{
return null;
}