Commit 5a06dc86 authored by mercury233's avatar mercury233

format

parent e2f82571
...@@ -256,7 +256,7 @@ bool MenuHandler::OnEvent(const irr::SEvent& event) { ...@@ -256,7 +256,7 @@ bool MenuHandler::OnEvent(const irr::SEvent& event) {
int flag = 0; int flag = 0;
flag += (mainGame->chkBotHand->isChecked() ? 0x1 : 0); flag += (mainGame->chkBotHand->isChecked() ? 0x1 : 0);
myswprintf(cmd, L"Bot.exe \"%ls\" %d %d", mainGame->botInfo[sel].command, flag, mainGame->gameConf.serverport); myswprintf(cmd, L"Bot.exe \"%ls\" %d %d", mainGame->botInfo[sel].command, flag, mainGame->gameConf.serverport);
if(!CreateProcessW(NULL, (LPWSTR)cmd, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi)) if(!CreateProcessW(NULL, cmd, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi))
{ {
NetServer::StopServer(); NetServer::StopServer();
break; break;
...@@ -274,8 +274,7 @@ bool MenuHandler::OnEvent(const irr::SEvent& event) { ...@@ -274,8 +274,7 @@ bool MenuHandler::OnEvent(const irr::SEvent& event) {
sprintf(arg3, "%d", mainGame->gameConf.serverport); sprintf(arg3, "%d", mainGame->gameConf.serverport);
execl("./bot", "bot", arg1, arg2, arg3, NULL); execl("./bot", "bot", arg1, arg2, arg3, NULL);
exit(0); exit(0);
} } else {
else {
if(!NetServer::StartServer(mainGame->gameConf.serverport)) if(!NetServer::StartServer(mainGame->gameConf.serverport))
break; break;
if(!DuelClient::StartClient(0x7f000001, mainGame->gameConf.serverport)) { if(!DuelClient::StartClient(0x7f000001, mainGame->gameConf.serverport)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment