This is a simple Tic Tac Toe game built with HTML, CSS, and JavaScript. The game features a single-player mode where the user plays against the computer in 5 rounds.
- Single-Player Game: Play against a computer opponent.
- 5-Round Match: Play 5 rounds of Tic Tac Toe, with the results tracked across rounds.
- Game Screens:
- Start screen to begin the game.
- Game screen to play the rounds.
- Result screen to display the final score after all 5 rounds.
- Open the game in your browser by opening the
index.html
file. - The game will start with the Start Screen, where you can click the "Start Game" button to begin.
- Once the game begins, you will be taken to the Game Screen where you can take turns playing Tic Tac Toe against the computer.
- After each round, the winner of the round will be announced.
- After 5 rounds, you will be taken to the Result Screen, where the final winner will be displayed, and you can choose to play again.
- HTML: Structure of the game.
- CSS: Styling of the game.
- JavaScript: Game logic for playing against the computer, handling turns, and tracking results.
- Start Screen: Click the "Start Game" button.
- Game Screen:
- Player and computer take turns placing their marks on the grid.
- The player is always "X" and the computer is "O".
- A round ends when a player wins or the grid is full (draw).
- Result Screen: After 5 rounds, the game shows the total score and declares the overall winner. You can restart the game from here.
- Clone or download this repository.
git clone https://github.com/jAnubhav/Tic-Tac-Toe-JS
- Open the
index.html
file in any modern web browser to play the game.
- Start Screen: Displays a button to start the game.
- Game Screen: 3x3 grid where the player and computer take turns.
- Result Screen: Shows the final winner after 5 rounds.
Feel free to suggest improvements.