예제 #1
0
 public Tuple <VirtualPiece, Vector2Int> GetBestMove2()
 {
     virtualBoard = new VirtualBoard();
     virtualBoard.SetVirtualBoard(gameBoard);
     virtualBoard.CreateRecursiveBoardDict();
     foreach (KeyValuePair <Tuple <VirtualPiece, Vector2Int>, VirtualBoard> kvp in virtualBoard.recursiveBoardDict)
     {
         kvp.Value.CreateRecursiveBoardDict();
         foreach (KeyValuePair <Tuple <VirtualPiece, Vector2Int>, VirtualBoard> kvp2 in kvp.Value.recursiveBoardDict)
         {
             kvp2.Value.CreateRecursiveBoardDict();
             foreach (KeyValuePair <Tuple <VirtualPiece, Vector2Int>, VirtualBoard> kvp3 in kvp2.Value.recursiveBoardDict)
             {
                 kvp3.Value.CreateRecursiveBoardDict();
                 foreach (KeyValuePair <Tuple <VirtualPiece, Vector2Int>, VirtualBoard> kvp4 in kvp3.Value.recursiveBoardDict)
                 {
                     kvp4.Value.CreateRecursiveBoardDict();
                 }
                 kvp3.Value.GetBestMove();
             }
             kvp2.Value.GetBestMove();
         }
         kvp.Value.GetBestMove();
     }
     virtualBoard.GetBestMove();
     return(virtualBoard.bestMove);
 }
예제 #2
0
 public void ResetNewBoard()
 {
     virtualBoard = new VirtualBoard();
     virtualBoard.SetVirtualBoard(gameBoard);
     virtualBoard.CreateRecursiveBoardDict();
     foreach (KeyValuePair <Tuple <VirtualPiece, Vector2Int>, VirtualBoard> kvp in virtualBoard.recursiveBoardDict)
     {
         kvp.Value.CreateRecursiveBoardDict();
         foreach (KeyValuePair <Tuple <VirtualPiece, Vector2Int>, VirtualBoard> kvp2 in kvp.Value.recursiveBoardDict)
         {
             kvp2.Value.CreateRecursiveBoardDict();
         }
     }
     foreach (KeyValuePair <Tuple <VirtualPiece, Vector2Int>, VirtualBoard> kvp in virtualBoard.recursiveBoardDict)
     {
         foreach (KeyValuePair <Tuple <VirtualPiece, Vector2Int>, VirtualBoard> kvp2 in kvp.Value.recursiveBoardDict)
         {
             kvp2.Value.GetUtilsFromFutureMove();
         }
         kvp.Value.GetUtilsFromFutureMove();
     }
 }
예제 #3
0
 public Tuple <VirtualPiece, Vector2Int> GetBestMove()
 {
     virtualBoard = new VirtualBoard();
     virtualBoard.SetVirtualBoard(gameBoard);
     return(virtualBoard.DoEverythingBecauseNothingWorks());
 }