Skip to content

GabrielJSuarez/TicTacToe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

66 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TicTacToe

In this project we:

  • first: Setup the Project

    • Created two folders. lib to contain the logic file and Bin for the main file.
  • Second: User Interface

    • Organized all the steps that were needed to build the Tic Tac Toe game.
  • Third: Game Logic

    • Separated the logic and the displayable for the user. (The first in Lib and the second in Bin)
    • Structured the logic of the game in Classes and Modules in the Lib folder.
    • Compiled all together in the main file
  • Fourth: Game Instructions

    • Added the instructions of the game for the Users

screenshot

What is Tic Tac Toe

Tic Tac Toe it's a game where two players place "x"s or "o"s in a grid with nine spaces. The winner is the first player who places three "x"s or three "o"s in a straight line.

Game Rules

  1. The game is played on a grid with nine spaces.

  2. Enter the name of the players (if no name entered it will ask you to enter again)

  3. Player 1 is "x", Player 2 is "o".

  4. You can place your move in the table by selecting a space between 1 & 3 for rows and columns (if it's different you will be asked to place it again)

  5. If the place its already taken, it will ask you to select a new space

  6. The first player to get 3 of "x" or "o" in a row (up, down, across, or diagonally) is the winner of the round.

  7. If no player has three marks, the game ends in "Draw!"

  8. When all nine squares are full or there is a winner, the game is over, and you will be asked if you "Want to play another round?"

Built with

Ruby

Live Demo

Click for live webpage

Getting Started

  • Clone the repository

  • For Windows Users:

    • In the folder that contains the cloned repository, hold down SHIFT, and right-click.
    • In the context menu click in the option Open command window here (this will open the CDM Window)
    • In the CMD Window run bin/main.rb
    • Enjoy the game
  • For Linux Users (Ubuntu):

    • In the folder that contains the cloned repository, right-click.
    • In the context menu click in the option Open in Terminal (this will open the Terminal)
    • In the Terminal run bin/main.rb
    • Enjoy the game

Author 1

Author 2

🤝 Contributing

Contributions, issues and feature requests are welcome! Start by:

  • Forking the project
  • Cloning the project to your local machine
  • cd into the project directory
  • Run git checkout -b your-branch-name
  • Make your contributions
  • Push your branch up to your forked repository
  • Open a Pull Request with a detailed description to the development branch of the original project for a review

Show your support

Give a ⭐️ if you like this project!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages