mirror of
https://github.com/vcmi/vcmi.git
synced 2024-11-28 08:48:48 +02:00
Merge pull request #2414 from IvanSavenko/fix_autocombat_crash
Fix autocombat crash
This commit is contained in:
commit
ff2ae1d2d3
@ -727,7 +727,7 @@ void BattleInterface::requestAutofightingAIToTakeAction()
|
||||
// FIXME: unsafe
|
||||
// Run task in separate thread to avoid UI lock while AI is making turn (which might take some time)
|
||||
// HOWEVER this thread won't atttempt to lock game state, potentially leading to races
|
||||
boost::thread aiThread([&]()
|
||||
boost::thread aiThread([this, activeStack]()
|
||||
{
|
||||
curInt->autofightingAI->activeStack(activeStack);
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user