Training Create a Connect 4 online

The objective of this video series is to show you a concrete use case of NodeJS and websockets by creating an online version of the Connect 4 game. The structure that will be put in place in this series can be adapted to any any other board game including the use of a state machine. The scenario of a game will be as follows:

  • The first user chooses a nickname and gets the URL to share to invite other players
  • Player 2 also chooses a nickname and joins the game
  • Both players choose a color
  • The game creator starts the game
  • Players take turns placing pawns in a 7 by 6 grid
  • A player wins if 4 pawns are aligned vertically / horizontally or diagonally
  • They can then restart the game.