public void GetMoveWithTime(PlayerColor player, int time, Action <Pos, TimeSpan> getMoveWithTimeSuccess) { if (_error) { return; } _actions.Enqueue(() => { var startTime = DateTime.Now; var pos = _bot.GetMoveWithTime(player, time); if (getMoveWithTimeSuccess != null) { getMoveWithTimeSuccess(pos, DateTime.Now - startTime); } }); ExecuteNext(); }