5 in a row game using JavaScript and Node.js.
- Single device and multiplayer / multiple device communication working (See Heroku link).
- Different games can take place at the same time.
- Opponent move is highlighted
- Added chat feature
- Added tooltip to indicate when messages were sent/received
Click to expand
Click to expand
Click to expand
- Player 1 creates a game and is assigned a Game ID
- Player 2 enters game ID from Player 1 to join game
- Player 1 goes first
- Winning 5-in-a-row is highlighted when game is won
- Head-to-head scores are kept
- If Player 1 (Host) leaves a room the game returns to start screen for both players
- If Player 2 (Challenger) leaves room, game resets and another player can be invited
- Press reset to reset the game at any time, or restart when game has been won
Click to expand
- Download and unzip project
- Install Node.js
- Initialise NPM (from root directory type the following commands in command prompt)
npm init npm install --save express socket.io
- Run the server
node server.js
npm start
- navigate to http://localhost:3000 (Server will run on localhost '127.0.0.1' port: 1337)