mirror of
https://github.com/RaidMax/IW4M-Admin.git
synced 2025-06-10 23:31:13 -05:00
[webfront] search by ip and name
[application] levels set properly with multiple GUIDs [stats] require 3 hours of playtime for top stats recognition [application] configurable rcon polling rate
This commit is contained in:
@ -15,6 +15,7 @@ namespace IW4MAdmin.Application.EventParsers
|
||||
string[] lineSplit = logLine.Split(';');
|
||||
string cleanedEventLine = Regex.Replace(lineSplit[0], @"([0-9]+:[0-9]+ |^[0-9]+ )", "").Trim();
|
||||
|
||||
// kill
|
||||
if (cleanedEventLine[0] == 'K')
|
||||
{
|
||||
if (!server.CustomCallback)
|
||||
@ -30,7 +31,7 @@ namespace IW4MAdmin.Application.EventParsers
|
||||
}
|
||||
}
|
||||
|
||||
if(cleanedEventLine.Contains("JoinTeam"))
|
||||
if (cleanedEventLine.Contains("JoinTeam"))
|
||||
{
|
||||
return new GameEvent()
|
||||
{
|
||||
@ -91,6 +92,7 @@ namespace IW4MAdmin.Application.EventParsers
|
||||
};
|
||||
}
|
||||
|
||||
// damage
|
||||
if (cleanedEventLine[0] == 'D')
|
||||
{
|
||||
if (Regex.Match(cleanedEventLine, @"^(D);((?:bot[0-9]+)|(?:[A-Z]|[0-9])+);([0-9]+);(axis|allies);(.+);((?:[A-Z]|[0-9])+);([0-9]+);(axis|allies);(.+);((?:[0-9]+|[a-z]+|_)+);([0-9]+);((?:[A-Z]|_)+);((?:[a-z]|_)+)$").Success)
|
||||
@ -106,6 +108,27 @@ namespace IW4MAdmin.Application.EventParsers
|
||||
}
|
||||
}
|
||||
|
||||
// join
|
||||
if (cleanedEventLine[0] == 'J')
|
||||
{
|
||||
var regexMatch = Regex.Match(cleanedEventLine, @"^(J;)(.{4,32});([0-9]+);(.*)$");
|
||||
if (regexMatch.Success)
|
||||
{
|
||||
return new GameEvent()
|
||||
{
|
||||
Type = GameEvent.EventType.Join,
|
||||
Data = cleanedEventLine,
|
||||
Owner = server,
|
||||
Origin = new Player()
|
||||
{
|
||||
Name = regexMatch.Groups[4].ToString(),
|
||||
NetworkId = regexMatch.Groups[2].ToString().ConvertLong(),
|
||||
ClientNumber = Convert.ToInt32(regexMatch.Groups[3].ToString())
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
if (cleanedEventLine.Contains("ExitLevel"))
|
||||
{
|
||||
return new GameEvent()
|
||||
|
Reference in New Issue
Block a user