Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/jahredhope/canvas-rock-paper-scissors

Canvas Animation Zero-Player Game
https://github.com/jahredhope/canvas-rock-paper-scissors

canvas

Last synced: 16 days ago
JSON representation

Canvas Animation Zero-Player Game

Awesome Lists containing this project

README

        

# Rock Paper Scissors Zero-Player game

## Want to build your own?

Follow the tutorial at: https://github.com/jahredhope/tutorial-rock-paper-scissors/

---

A weekend hack project to create autonomous rock, paper and scissor pieces who move around a 2D plane.

Using:

- [HTML Canvas](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas)
- [requestAnimationFrame Web API](https://developer.mozilla.org/en-US/docs/Web/API/window/requestAnimationFrame)
- [Web Workers Web API](https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API)
- Vector logic & rudimentary AI

Each piece attempts to move towards it's nearest thing that it can beat (prey) and away from the nearest thing that it beats it (predator). This can create amusing and entertaining visuals. Try it out see who wins.

By [@jahredhope](https://github.com/jahredhope)