Exemplo n.º 1
0
        public void LoadProxies()
        {
            if (!File.Exists(@"Engine\" + @"KrakenServerProxy.txt"))
            {
                return;
            }

            try
            {
                using (StreamReader reader = new StreamReader(@"Engine\" + @"KrakenServerProxy.txt"))
                {
                    while (!reader.EndOfStream)
                    {
                        ProxyHolder newProxy = new ProxyHolder();
                        newProxy.LoadFromString(reader.ReadLine());
                        Proxies.Add(newProxy);
                    }
                    reader.Close();
                }
            }
            catch
            {
                // ignored
            }

            if (_krakenClient != null)
            {
                _krakenClient.InsertProxies(Proxies);
            }
        }