using System; using System.Collections.Generic; using System.Linq; using Microsoft.Xna.Framework; using Microsoft.Xna.Framework.Graphics; using Microsoft.Xna.Framework.Input; using Barotrauma.Networking; using Barotrauma.Items.Components; using System.Text; using FarseerPhysics; namespace Barotrauma { static partial class DebugConsole { public static List QueuedCommands = new List(); public static void Update() { lock (QueuedCommands) { while (QueuedCommands.Count>0) { ExecuteCommand(QueuedCommands[0], GameMain.Instance); QueuedCommands.RemoveAt(0); } } } private static bool ExecProjSpecific(string[] commands) { switch (commands[0].ToLower()) { case "restart": case "reset": DebugConsole.NewMessage("*****************", Color.Lime); DebugConsole.NewMessage("RESTARTING SERVER", Color.Lime); DebugConsole.NewMessage("*****************", Color.Lime); GameMain.Instance.CloseServer(); GameMain.Instance.StartServer(); break; case "exit": case "close": case "quit": GameMain.ShouldRun = false; break; case "say": case "msg": string text = ""; for (int i=1;i