Пример #1
0
 public void BindServer(BattleServer battleServer)
 {
     if (battleServer == null)
     {
         LOG.Error("Bind battleserver failed:server is null!");
         return;
     }
     lock (allBattleServersLock)
     {
         AllBattleServers.Add(battleServer);
     }
 }
Пример #2
0
 internal void DistoryServer(BattleServer battleServer)
 {
     if (battleServer == null)
     {
         LOG.Error("Bind battleserver failed:server is null!");
         return;
     }
     lock (allBattleServersLock)
     {
         AllBattleServers.Remove(battleServer);
         string key = battleServer.GetKey();
         BattleServerList.Remove(key);
     }
 }