|
|
@ -89,9 +89,7 @@ enum |
|
|
|
{ |
|
|
|
{ |
|
|
|
kArgToDni, |
|
|
|
kArgToDni, |
|
|
|
kArgSkipLoginDialog, |
|
|
|
kArgSkipLoginDialog, |
|
|
|
kArgAuthSrv, |
|
|
|
kArgServerIni, |
|
|
|
kArgFileSrv, |
|
|
|
|
|
|
|
kArgGateKeeperSrv, |
|
|
|
|
|
|
|
kArgLocalData, |
|
|
|
kArgLocalData, |
|
|
|
kArgBackgroundDownloader, |
|
|
|
kArgBackgroundDownloader, |
|
|
|
}; |
|
|
|
}; |
|
|
@ -99,9 +97,7 @@ enum |
|
|
|
static const CmdArgDef s_cmdLineArgs[] = { |
|
|
|
static const CmdArgDef s_cmdLineArgs[] = { |
|
|
|
{ kCmdArgFlagged | kCmdTypeBool, L"ToDni", kArgToDni }, |
|
|
|
{ kCmdArgFlagged | kCmdTypeBool, L"ToDni", kArgToDni }, |
|
|
|
{ kCmdArgFlagged | kCmdTypeBool, L"SkipLoginDialog", kArgSkipLoginDialog }, |
|
|
|
{ kCmdArgFlagged | kCmdTypeBool, L"SkipLoginDialog", kArgSkipLoginDialog }, |
|
|
|
{ kCmdArgFlagged | kCmdTypeString, L"AuthSrv", kArgAuthSrv }, |
|
|
|
{ kCmdArgFlagged | kCmdTypeString, L"ServerIni", kArgServerIni }, |
|
|
|
{ kCmdArgFlagged | kCmdTypeString, L"FileSrv", kArgFileSrv }, |
|
|
|
|
|
|
|
{ kCmdArgFlagged | kCmdTypeString, L"GateKeeperSrv", kArgGateKeeperSrv }, |
|
|
|
|
|
|
|
{ kCmdArgFlagged | kCmdTypeBool, L"LocalData", kArgLocalData }, |
|
|
|
{ kCmdArgFlagged | kCmdTypeBool, L"LocalData", kArgLocalData }, |
|
|
|
{ kCmdArgFlagged | kCmdTypeBool, L"BGDownload", kArgBackgroundDownloader }, |
|
|
|
{ kCmdArgFlagged | kCmdTypeBool, L"BGDownload", kArgBackgroundDownloader }, |
|
|
|
}; |
|
|
|
}; |
|
|
@ -1576,19 +1572,11 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR lpCmdLine, int nC |
|
|
|
if(cmdParser.IsSpecified(kArgBackgroundDownloader)) |
|
|
|
if(cmdParser.IsSpecified(kArgBackgroundDownloader)) |
|
|
|
gUseBackgroundDownloader = true; |
|
|
|
gUseBackgroundDownloader = true; |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
if(cmdParser.IsSpecified(kArgAuthSrv)) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
SetAuthSrvHostname(cmdParser.GetString(kArgAuthSrv)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(cmdParser.IsSpecified(kArgFileSrv)) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
SetFileSrvHostname(cmdParser.GetString(kArgFileSrv)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(cmdParser.IsSpecified(kArgGateKeeperSrv)) |
|
|
|
const wchar *serverIni = L"server.ini"; |
|
|
|
|
|
|
|
if(cmdParser.IsSpecified(kArgServerIni)) |
|
|
|
{ |
|
|
|
{ |
|
|
|
SetGateKeeperSrvHostname(cmdParser.GetString(kArgGateKeeperSrv)); |
|
|
|
serverIni = cmdParser.GetString(kArgServerIni); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// check to see if we were launched from the patcher
|
|
|
|
// check to see if we were launched from the patcher
|
|
|
@ -1679,9 +1667,18 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR lpCmdLine, int nC |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/////////<<<<<<<<
|
|
|
|
/////////<<<<<<<<
|
|
|
|
pfConsoleEngine *tempConsole = TRACKED_NEW pfConsoleEngine(); |
|
|
|
FILE *serverini = _wfopen(serverIni, L"rb"); |
|
|
|
tempConsole->ExecuteFile("server.ini"); |
|
|
|
if (serverini) |
|
|
|
delete tempConsole; |
|
|
|
{ |
|
|
|
|
|
|
|
fclose(serverini); |
|
|
|
|
|
|
|
pfConsoleEngine tempConsole; |
|
|
|
|
|
|
|
tempConsole.ExecuteFile(serverIni); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
else |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
hsMessageBox("No server.ini file found. Please check your URU installation.", "Error", hsMessageBoxNormal); |
|
|
|
|
|
|
|
return PARABLE_NORMAL_EXIT; |
|
|
|
|
|
|
|
} |
|
|
|
/////////<<<<<<<<
|
|
|
|
/////////<<<<<<<<
|
|
|
|
|
|
|
|
|
|
|
|
NetCliAuthAutoReconnectEnable(false); |
|
|
|
NetCliAuthAutoReconnectEnable(false); |
|
|
|