Skip to content
Stefano Balietti edited this page Nov 8, 2021 · 10 revisions
  • status: complete
  • version: 7.x

Preparation

  • Install version 14.x (or higher) of Node.js for your operating system (Win/Mac/Linux).

  • Install git for your operating system (Win/Mac/Linux).

  • Check that node and git are installed. Open a terminal or a command prompt and type:

    node --version
    

    You should see something like: v12.15.0

    npm --version
    

    You should see something like: 6.13.4

    git --version
    

    You should see something like: git version 2.22.0

  • Important: some Linux distributions install an executable named nodejs, and it might cause the installation to break. If this is the case, make a symbolic link from nodejs to node.

  • Important: for Windows, Git-Bash (installed with git) is the recommended command-prompt, and it can be opened as a normal program form the start menu.

Install nodeGame

  • Download the nodeGame installer (right-click, save as)
  • Open a terminal and navigate to the folder where you downloaded the installer
  • Install the desired version of nodeGame v7 with one of the following commands:

Stable

 node nodegame-installer.js

Development version

node nodegame-installer.js @dev

Older versions

node nodegame-installer.js @v6

Note: Windows users using PowerShell V2+: @ is also the Splat operator, so you need to escape it:

Running Your First Game

NodeGame has an Ultimatum Game included in the default installation.

To play it, start the server and follow these steps:

  1. Open a terminal and navigate to the nodegame folder (for Windows, Git-Bash is the recommended command-prompt)
  2. Start the server with the command: node launcher.js
  3. While the server is running, open one browser tab pointing to: localhost:8080
  4. Open more tabs, click "Play with Bots", or manually launch a bot connecting to: localhost:8080/ultimatum/?clientType=autoplay
  5. Check the monitor interface: localhost:8080/ultimatum/monitor

Next Topics

Next: Create a new game in nodeGame

Clone this wiki locally