public static bool StopMooNet() { if (MooNetServer == null) { return(false); } Logger.Warn("Stopping MooNet-Server.."); MooNetServer.Shutdown(); MooNetServerThread.Abort(); MooNetServer = null; return(true); }
public static bool StartMooNet() { if (MooNetServer != null) { return(false); } MooNetServer = new MooNetServer(); MooNetServerThread = new Thread(MooNetServer.Run) { IsBackground = true, CurrentCulture = CultureInfo.InvariantCulture }; MooNetServerThread.Start(); return(true); }