Code Monkey home page Code Monkey logo

elements's Introduction

Elements Board Game

This is a digital port of a classic abstract board game known by various names, here called Elements. Two users take turns drawing and placing stones, and moving their pawns around the board. Different colors of stones have unique effects. When your opponent's pawn is surrounded, you win!

I've designed this with sort of a muted earth-tone palette to represent the elements abstractly, rather than trying to make stones that really look like water, fire, etc, as in the cardboard version. You can drag-and-drop the stones or have them slide across, and toggle on or off animation.

game-in-progress

  • elements-game-in-progress

Contents

  1. Setup
  2. Rules of Play
  3. Elemental Powers
  4. Roadmap
  5. Development
  6. License
  7. Notes

Setup

To clone and run this servce, you'll need Git installed on your computer, and a modern browser. From the command line:

# Clone this repo
$ git clone https://github.com/dtklumpp/elements

# Go into the repository
$ cd elements

# Run the app
$ open -a "Google Chrome" index.html

Rules-of-Play

  1. Draw stones from the "bag" with the orange Draw buttons
  2. Each extra stone is one less move for your pawn
  3. Take turns placing your stones and moving your pawn until you're out of moves
  4. Now it is your opponent's turn to play
  5. Each time a stone is placed, its "Elemental Powers" are activated (see below)
  6. When one pawn is surrounded with no moves to take, that player forfeits the match
  7. Reset the match with the "New Game" button

Elemental-Powers

These powers are applied when placing a stone of one of the four "element" types: air, earth, fire, and water.

  • Fire: The fire spreads across the board: you may place an additional adjacent fire stone from the bag.
  • Water: The river of water flows: you may "flow" the river 7 spaces around the board.
  • Earth: The earth forms an impassible mountain; a pawn may not move between two diagonal earth stones.
  • Air: A pawn may "float" or jump across any number of adjacent air stones.

Roadmap -- pending features

  • allow pawn movement through drag-and-drop
  • flesh out pawn animation
  • allow variable board size
  • incorporate advanced rules for water and fire
  • highlight legal moves in real-time
  • add 3D appearance to stones
  • add figurine images for pawns
  • translate rulebook from Italian
  • fix wall-of-water bug
  • allow asyncronous play
  • incorporate account metrics / leaderboard

Development

Help me improve the game!

To help with a bug or add functionality, do this:

  • Fork this repo
  • Make a branch (git checkout -b new-feature)
  • Make modifications where necessary
  • Add comments corresponding to your changes
  • Commit (git commit -m 'explanation')
  • Push up (git push origin new-feature)
  • Make a Pull Request

License

MIT ©

Notes

This is one of my first digital board game ports. I'd encourage you to check out a fine wood-and-cardboard version of this old classic from Dashing Games viewable at BGG here. Note some slight rule differences.

elements's People

Contributors

dtklumpp avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.