mirror of
https://github.com/SteamRE/DepotDownloader.git
synced 2026-10-19 15:51:50 +00:00
Don't attempt cm0 servers
This commit is contained in:
1 parent
a0a1db448a
commit
81a9057779
1 file changed
+1
-16
@@ -340,28 +340,13 @@ namespace DepotDownloader
|
||||
}
|
||||
}
|
||||
|
||||
private static int retry_count = 0;
|
||||
|
||||
private void DisconnectedCallback(SteamClient.DisconnectedCallback disconnected)
|
||||
{
|
||||
if ((!bConnected && !bConnecting) || bAborted)
|
||||
return;
|
||||
|
||||
Console.WriteLine("Reconnecting");
|
||||
|
||||
if ( ++retry_count < 2 )
|
||||
{
|
||||
steamClient.Connect();
|
||||
}
|
||||
else
|
||||
{
|
||||
var addresses = Dns.GetHostAddresses( "cm0.steampowered.com" );
|
||||
Random random = new Random();
|
||||
|
||||
var addr = addresses[ random.Next( addresses.Length ) ];
|
||||
|
||||
steamClient.Connect( new IPEndPoint( addr, 27017 /* expose this as a constant someday? */ ) );
|
||||
}
|
||||
steamClient.Connect();
|
||||
}
|
||||
|
||||
private void LogOnCallback(SteamUser.LoggedOnCallback loggedOn)
|
||||
|
||||
Reference in new issue
Block a user