diff --git a/AI.h b/AI.h index 71bd476..14e69cf 100644 --- a/AI.h +++ b/AI.h @@ -22,12 +22,11 @@ class AI void setTargetGrid(Grid *grid); - void impossibleAITurn(); private: enum difficultyScale{Normal = 1, Impossible = 2}; void normalAITurn(); - + void impossibleAITurn(); // Moves for impossible difficulty AI to use int impMoveWin(); diff --git a/Game.cpp b/Game.cpp index 92dadee..a47fd39 100644 --- a/Game.cpp +++ b/Game.cpp @@ -10,23 +10,6 @@ void Game::runGame() // Starts the game and handles overall flow of events aiObj.setTargetGrid(gridPtr); playerObj.setTargetGrid(gridPtr); - - aiObj.setSymbol('O'); - - gridObj.printGrid(); - std::cout << std::endl; - - gridObj.checkChoice('X', 4); - gridObj.checkChoice('X', 7); - - gridObj.printGrid(); - std::cout << std::endl; - - aiObj.impossibleAITurn(); - - gridObj.printGrid(); - - /* gameIntro(); do { @@ -34,7 +17,6 @@ void Game::runGame() }while(playAgain()); quitGame(); - */ } bool Game::checkWin(char symbol) diff --git a/Tic-Tac-Toe.depend b/Tic-Tac-Toe.depend index 1d9db5b..ec1102e 100644 --- a/Tic-Tac-Toe.depend +++ b/Tic-Tac-Toe.depend @@ -47,10 +47,10 @@ -1565482083 source:e:\richard\programming projects\c++\tic-tac-toe\ai.cpp +1565546187 source:e:\richard\programming projects\c++\tic-tac-toe\ai.cpp "AI.h" -1565525911 e:\richard\programming projects\c++\tic-tac-toe\ai.h +1565546404 e:\richard\programming projects\c++\tic-tac-toe\ai.h @@ -77,6 +77,6 @@ 1565481586 source:e:\richard\programming projects\c++\tic-tac-toe\player.cpp "Player.h" -1565481560 source:e:\richard\programming projects\c++\tic-tac-toe\game.cpp +1565546175 source:e:\richard\programming projects\c++\tic-tac-toe\game.cpp "Game.h" diff --git a/Tic-Tac-Toe.layout b/Tic-Tac-Toe.layout index 4b914d8..36dc125 100644 --- a/Tic-Tac-Toe.layout +++ b/Tic-Tac-Toe.layout @@ -2,14 +2,9 @@ - - - - - - + @@ -17,34 +12,39 @@ - + - + - + - + - + - + - + - + - + - + + + + + + - +