public static ServerCommandHandler GetInstance() { if (instance == null) { instance = new ServerCommandHandler(); } return(instance); }
public Server(int port) { this.port = port; connections = new List <Connection>(); tickrate = new System.Timers.Timer(1000 / 128); tickrate.AutoReset = true; tickrate.Elapsed += onTimerEvent; command_handler = ServerCommandHandler.GetInstance(); handle = command_handler; }