Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/ably-labs/ably-rock-paper-scissors

A game of rock, paper scissors unlike any other.
https://github.com/ably-labs/ably-rock-paper-scissors

demo game javascipt

Last synced: 5 days ago
JSON representation

A game of rock, paper scissors unlike any other.

Awesome Lists containing this project

README

        

# ably-rock-paper-scissors

[![Discord](https://img.shields.io/discord/823552399909584908?label=Get%20help&style=for-the-badge)](https://discord.gg/7qWKqdQWYB)

This project contains a multiplayer game in which players battle as ever-changing hand shapes of rock, paper, and scissors.

## Running it

Firstly, [sign up to Ably](https://ably.com/signup) to get a free Ably Account. Go to one of your Ably Account's [Apps](https://ably.com/accounts/any/apps/any), and get an [API key](https://ably.com/accounts/any/apps/any/app_keys) 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.

## About the game
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!