bug fix in MultithreadedAI