Skip to content

takashiro/sanguosha-react

Repository files navigation

Sanguosha GUI (React.js) Node.js CI Build Status

Example Page http://sgs.takashiro.cn
Author Kazuichi Takashiro

Introduction

It's a GUI client application of the famous board game Legends of the Three Kingdoms based on React.js.

It connects to the server application via WebSocket.

Running Environment

  1. Node.js v10 or later versions
  2. karuta-node-server
  3. sanguosha-server

Build and Run

  1. You'll need 3 repositories to debug the project, including karuta-node-server, sanguosha-server and sanguosha-react (this repository). The 3 repositories should be in the same folder.
  2. Clone karuta-node-server.
  3. Enter karuta-node-server.
  4. Run npm i and npm run build
  5. Clone sanguosha-server.
  6. Enter sanguosha-server.
  7. Run npm i and npm run build
  8. Create a symlink karuta-node-server/extension/sanguosha <----> sanguosha-server/dist
  9. Open sanguosha-server with Visual Studio Code.
  10. Click Launch to start the server.
  11. Open sanguosha-react with Visual Studio Code.
  12. Run npm start to start webpack.
  13. Click Launch (http).
  14. Now you are ready! Type your nickname and start a new game.