Skip to content

Final Java course project, simple XO game using JavaFx.

Notifications You must be signed in to change notification settings

alaawahba13/XO-game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 

Repository files navigation

XO Game Project

This is a JavaFX implementation of the classic XO game (also known as Tic Tac Toe). The game is played by two players who take turns marking spaces in a 3x3 grid. The first player to place three of their marks in a row, column, or diagonal wins the game. If all spaces are filled and no player has won, the game ends in a tie.

Getting Started

To run the game, you must have JavaFX installed on your machine. You can download JavaFX from the official website: https://openjfx.io/

Once JavaFX is installed, you can run the game by executing the ticTacToe.java file in your preferred IDE.

How to Play

When the game starts, Player 1 (X) will be prompted to make the first move. Player 1 should click on the desired space in the grid to place their mark. Player 2 (O) will then take their turn by clicking on an empty space.

The game will continue until one of the players gets three marks in a row, column, or diagonal, or until all spaces are filled. If a player wins, a message will appear declaring them the winner. If the game ends in a tie, a message will appear declaring the game a draw.

To start a new game, click on the "New Game" button.

Demo

XO.mp4

Authors

This code was developed by

About

Final Java course project, simple XO game using JavaFx.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages