This project contains a multiplayer game in which players battle as ever-changing hand shapes of rock, paper, and scissors.
Firstly, sign up to Ably to get a free Ably Account. Go to one of your Ably Account's Apps, and get an API key for it.
Once you have the API key, create a .env
file, and add the API key as:
API_KEY={your Ably API key}
With that, simply run npm run
to start up a server!
Navigate to localhost:3000
if you're running it locally to access the game's welcome page.
You will appear on a map as a hand. You will be either rock, paper or scissors.
If you collide with another player, then one of you will be defeated if you are different hand shape.
- Paper defeats rock
- Rock defeats scissors
- Scissors defeats paper
Every 5 seconds, everyone's colour and shape will change. Each player you defeat gets you a point. Good luck!