public override void MakeMove() { tree = new GameTree(board, aicode); int max = int.MinValue; Move bestMove = new Move(0, 0, 0, 0, false); foreach (GameTree.Node n in tree.root.children.Values) { if (n.value > max) { max = n.value; bestMove = n.move; } } ExecuteMove(board, aicode, bestMove); }
public override void MakeMove() { tree = new GameTree(board, aicode); int max = int.MinValue; Move bestMove = new Move(0, 0, 0, 0, false); foreach (GameTree.Node n in tree.root.children.Values) if (n.value > max) { max = n.value; bestMove = n.move; } ExecuteMove(board, aicode, bestMove); }