Use configuration setting to decide whether to download the server list or directly connect to the server. Accept other server lists. Accept un'zlib'ed server lists. Use IPv6 address from server list if configured.

This commit is contained in:
lotodore committed 2008-05-10 15:47:48 +00:00
1 parent 8aad232ef2
commit b5c2399603
9 files changed
+80 -64

No files matched your search

+4 -3
View File
@@ -74,8 +74,8 @@ ClientThread::~ClientThread()
void
ClientThread::Init(
const string &serverAddress, const string &alternateServerAddress,
unsigned serverPort, bool ipv6, bool sctp,
const string &serverAddress, const string &serverListUrl,
bool useServerList, unsigned serverPort, bool ipv6, bool sctp,
const string &pwd, const string &playerName, const string &avatarFile,
const string &cacheDir)
{
@@ -90,7 +90,8 @@ ClientThread::Init(
context.SetProtocol(sctp ? SOCKET_IPPROTO_SCTP : 0);
context.SetAddrFamily(ipv6 ? AF_INET6 : AF_INET);
context.SetServerAddr(serverAddress);
context.SetAlternateServerAddr(alternateServerAddress);
context.SetServerListUrl(serverListUrl);
context.SetUseServerList(useServerList);
context.SetServerPort(serverPort);
context.SetPassword(pwd);
context.SetPlayerName(playerName);