IW4M-Admin/SharedLibraryCore/Helpers/MessageToken.cs
RaidMax e8dff01c41 re-added the kill server command (can only be used if run as admin)
less warns when using a disposed socket
topstats added to tokens as {{TOPSTATS}}
fixed topstats reporting for only a single server
added fix to iw4 regex for negative score
tokens now support multiple lines (using Environment.NewLine to separate)
localization includes culture again
2018-05-05 15:36:26 -05:00

21 lines
449 B
C#

using System;
namespace SharedLibraryCore.Helpers
{
public class MessageToken
{
public string Name { get; private set; }
Func<Server, string> Value;
public MessageToken(string Name, Func<Server, string> Value)
{
this.Name = Name;
this.Value = Value;
}
public string Process(Server server)
{
return this.Value(server);
}
}
}