mirror of
https://github.com/RaidMax/IW4M-Admin.git
synced 2025-06-10 15:20:48 -05:00
feature(parser): Option to override special localize character
This commit is contained in:
@ -29,6 +29,7 @@ namespace IW4MAdmin.Application.EventParsers
|
||||
Configuration = new DynamicEventParserConfiguration(parserRegexFactory)
|
||||
{
|
||||
GameDirectory = "main",
|
||||
LocalizeText = "\x15",
|
||||
};
|
||||
|
||||
Configuration.Say.Pattern = @"^(say|sayteam);(-?[A-Fa-f0-9_]{1,32}|bot[0-9]+|0);([0-9]+);([^;]*);(.*)$";
|
||||
@ -185,7 +186,7 @@ namespace IW4MAdmin.Application.EventParsers
|
||||
if (matchResult.Success)
|
||||
{
|
||||
var message = matchResult.Values[Configuration.Say.GroupMapping[ParserRegex.GroupType.Message]]
|
||||
.Replace("\x15", "")
|
||||
.Replace(Configuration.LocalizeText, "")
|
||||
.Trim();
|
||||
|
||||
if (message.Length > 0)
|
||||
|
@ -14,6 +14,7 @@ namespace IW4MAdmin.Application.EventParsers
|
||||
{
|
||||
public string GameDirectory { get; set; }
|
||||
public ParserRegex Say { get; set; }
|
||||
public string LocalizeText { get; set; }
|
||||
public ParserRegex Join { get; set; }
|
||||
public ParserRegex JoinTeam { get; set; }
|
||||
public ParserRegex Quit { get; set; }
|
||||
|
Reference in New Issue
Block a user