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

implement more robust command api and login

improve web console command response reliability and consistency
This commit is contained in:
RaidMax
2021-01-17 21:58:18 -06:00
parent 17dd35c4bb
commit c231c6b610
12 changed files with 260 additions and 56 deletions

View File

@ -172,22 +172,6 @@ namespace SharedLibraryCore
Console.WriteLine(message.StripColors());
Console.ForegroundColor = ConsoleColor.Gray;
}
// prevent this from queueing up too many command responses
if (CommandResult.Count > 15)
{
CommandResult.RemoveAt(0);
}
// it was a remote command so we need to add it to the command result queue
if (target.ClientNumber < 0)
{
CommandResult.Add(new CommandResponseInfo()
{
Response = message.StripColors(),
ClientId = target.ClientId
});
}
}
/// <summary>
@ -347,8 +331,5 @@ namespace SharedLibraryCore
// only here for performance
private readonly bool CustomSayEnabled;
private readonly string CustomSayName;
//Remote
public IList<CommandResponseInfo> CommandResult = new List<CommandResponseInfo>();
}
}