Rock Paper Scissors Lizard Spock
This is a pure javascript/node.js implementation of the game. The purpose was to use this code in a workshop so the code is partitioned in steps. Each step have 2 branches: an initial one (ex. play) and a final one (ex. play-done)
- walking-skeleton: the initial environment and basic project automation
- play: basic game mechanics implemented with a simple protocol over HTTP
- bot: when no humas are around a bot should play with you
- socket.io: each board has a channel where all board's event are published so a client could avoid board's status polling
- score: basic score for players and a leaderboard using redis
- simulation: how do you know it's working if no one is really playing with it?
- ui: basic game interface as a single HTML application, this is the last branch and so the complete application
INSTALL/DEPENDENCIES
- node >= 0.4.10 is required (http://nodejs.org/)
- redis >= 2.2.12 is required (http://redis.io)
- npm is required (https://github.com/isaacs/npm)
- jake is required (npm install -g jake)
- jshint is required (npm install -g jshint)
USAGE
- jake clean: clean all the artifacts created in ./.work directory
- jake start: start all services (dropit server and redis server)
- jake stop: stop all services (dropit server and redis server)
- jake spec: run all specs
- jake simulation: run a bunch of simulated games with a few of simulated players (see Jakefile to change games/players number)