示例#1
0
        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);
        }
示例#2
0
 private BattleServer(CustomSevSetting setting) : base(setting)
 {
     maxBattleNum = Math.Max(8, setting.battleMaxNum);
     StartUpdateThread();
 }