fix
This commit is contained in:
parent
f4e6593c7a
commit
18dfa2d933
@ -2524,12 +2524,10 @@ int CServer::LoadMap(const char *pMapName)
|
|||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
bool initConsole=false;
|
|
||||||
//控制台线程
|
//控制台线程
|
||||||
void* CreateConsoleThread(void* p){
|
void* CreateConsoleThread(void* p){
|
||||||
IConsole* console=(IConsole*)p;
|
IConsole* console=(IConsole*)p;
|
||||||
while(true){
|
while(true){
|
||||||
if(!initConsole) continue;
|
|
||||||
printf(" ->");
|
printf(" ->");
|
||||||
char cmd[256];
|
char cmd[256];
|
||||||
int result=scanf("%s",cmd);
|
int result=scanf("%s",cmd);
|
||||||
@ -2662,7 +2660,6 @@ int CServer::Run()
|
|||||||
m_GameStartTime = time_get();
|
m_GameStartTime = time_get();
|
||||||
//更新服务器信息
|
//更新服务器信息
|
||||||
UpdateServerInfo();
|
UpdateServerInfo();
|
||||||
initConsole=true;
|
|
||||||
//服务器非停止时
|
//服务器非停止时
|
||||||
while(m_RunServer < STOPPING)
|
while(m_RunServer < STOPPING)
|
||||||
{
|
{
|
||||||
@ -2879,7 +2876,6 @@ int CServer::Run()
|
|||||||
}
|
}
|
||||||
if(IsInterrupted())
|
if(IsInterrupted())
|
||||||
{
|
{
|
||||||
initConsole=false;
|
|
||||||
Console()->Print(IConsole::OUTPUT_LEVEL_STANDARD, "server", "服务器被终止");
|
Console()->Print(IConsole::OUTPUT_LEVEL_STANDARD, "server", "服务器被终止");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user