Skip to content

A strategic two-player game where opponents stack colored discs to form four in a row and win.

License

Notifications You must be signed in to change notification settings

gayanukabulegoda/connect-4-game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

drawing The Connect Four Game

The Connect 4 game is a classic strategy game in which 2 players go head-to-head in a battle to own the grid!

Players choose GREEN and BLUE discs. They drop the discs into the grid, starting in the middle or at the edge to stack their colored discs vertically or horizontally. Use strategy to block opponents while aiming to be the first player to get 4 in a row to win.

Overview

Welcome to the Connect Four game repository, where players strategically drop GREEN or BLUE discs into the grid to form vertical or horizontal lines of four. In this classic battle, the game unfolds as opponents vie to outmaneuver each other.

What sets this implementation apart is the integration of the Monte Carlo Tree Search (MCTS) algorithm, bringing advanced artificial intelligence to the computer player. Whether challenging the intelligent computer opponent, every move counts in this quest to be the first to connect four in a row and claim victory. Immerse yourself in the thrill of strategic gameplay and enjoy a timeless duel of wits in Connect Four!

How to use this repo

  • Clone the repository: git clone https://github.com/gayanukabulegoda/connect-4-game.git
  • Open the pom.xml via IntelliJ IDEA
  • Make sure to the open it as a project, if prompt
  • Reload the pom.xml file via Maven Tool Window
  • Create a run configuration for Maven via Run > Edit Configuration
  • Add javafx:run as the Run command
  • That's it.

License

This project is licensed under the MIT License.


© 2023 Gayanuka Bulegoda