Added some convenient console commands

This commit is contained in:
juanjp600
2017-06-22 19:51:19 -03:00
parent 72d5cb227b
commit be2074b4f0
6 changed files with 93 additions and 20 deletions
@@ -1249,7 +1249,7 @@ namespace Barotrauma.Networking
GameMain.GameScreen.Select();
AddChatMessage("Press TAB to chat. Use \"r;\" to talk through the radio.", ChatMessageType.Server);
GameMain.NetLobbyScreen.StartButtonEnabled = true;
gameStarted = true;
@@ -1411,6 +1411,13 @@ namespace Barotrauma.Networking
KickClient(client, ban, range);
}
public void KickPlayer(int id,bool ban,bool range=false)
{
Client client = connectedClients.Find(c => c.ID == id);
KickClient(client, ban, range);
}
public void KickClient(NetConnection conn, bool ban = false, bool range = false)
{
Client client = connectedClients.Find(c => c.Connection == conn);