public static BattleServer StartNew(CustomSevSetting setting) { ProtocolManager.InitCodeGenerator(0xB001, 0xB001); var sev = new BattleServer(setting); var ipa = string.IsNullOrEmpty(setting.host) ? IPAddress.Any : IPAddress.Parse(setting.host); sev.Start(new IPEndPoint(ipa, setting.port)); return(sev); }
private BattleServer(CustomSevSetting setting) : base(setting) { maxBattleNum = Math.Max(8, setting.battleMaxNum); StartUpdateThread(); }