mirror of
https://github.com/vcmi/vcmi.git
synced 2025-07-07 00:58:39 +02:00
Change ClientCommandManager to become non-static
This commit is contained in:
@ -1154,7 +1154,13 @@ void CInGameConsole::endEnteringText(bool processEnteredText)
|
||||
if(txt.at(0) == '/')
|
||||
{
|
||||
//some commands like gosolo don't work when executed from GUI thread
|
||||
boost::thread clientCommandThread(ClientCommandManager::processCommand, txt.substr(1), true);
|
||||
auto threadFunction = [=]()
|
||||
{
|
||||
ClientCommandManager commandController;
|
||||
commandController.processCommand(txt.substr(1), true);
|
||||
};
|
||||
|
||||
boost::thread clientCommandThread(threadFunction);
|
||||
clientCommandThread.detach();
|
||||
}
|
||||
else
|
||||
|
Reference in New Issue
Block a user