Skip to content

consultchwong/rock-paper-scissors-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

rock-paper-scissors-demo

This is a demo project for presenting advanced features of boardgame.io including:

  1. Turn Order = ANY
  2. Secret State
  3. Multiple Players

The game features classic game play of rock paper scissors which both players take action in same web page.

The original demo of boardgame.io features game play in turn base.

To simulate the real live game play of rock paper scissors, Turn Order = ANY is used so that both players can select actions (rock paper scissors) at any time without waiting another player finishing the move.

Also, the game uses "Secret State" to hide the action of another players before end game.

To review the game and the code, you may directly click the button below.

Edit boardgameio-rps-local-multiplayer

Install

$ git clone https://github.com/consultchwong/rock-paper-scissors-demo/
$ cd rock-paper-scissors-demo
$ npm install
$ npm start