Play Gomoku

Interactive browser recreation

Gomoku Board

Configure the board

Place one stone per turn and complete the winning line before your opponent.

Ready to play

Configure the match and select Start New Game.

Select an empty position to place your stone. The highlighted stones show the completed winning line.

Match history

Game Log

  1. Game activity will appear here.

About this project

Original C++ Gomoku logic, recreated for the browser.

This project began as a Windows Console application written in C++. The original coursework supports configurable board dimensions, custom player names and symbols, mouse-based input, turn management, and win detection.

The browser recreation preserves the original horizontal, vertical, and diagonal win logic while presenting the game through an accessible responsive interface built with HTML, CSS, and Vanilla JavaScript.

How to play

Complete the required line before your opponent.

  1. Choose Player vs Computer or Two Players.
  2. Configure the board rows, columns, and number of stones required to win.
  3. Enter unique player symbols. The dash character is reserved for empty positions.
  4. Players alternate turns and place one stone in any empty board position.
  5. A player wins by completing the required number of stones horizontally, vertically, or diagonally.
  6. The match is declared a draw only when the board is full and no winning line exists.

Repository

Original C++ source and browser recreation in one project.

The repository preserves the original coursework file alongside the corrected C++ version, browser implementation, and feature-parity documentation.