Giter VIP home page Giter VIP logo

canoe-game's Introduction

🛶 Canoe 🛶

A tic-tac-toe like two-player strategy game.

Objective

Players take turns placing colored pegs into available holes, one at a time. The first to complete two completed "canoes" wins. A "canoe" is formed by four pegs in this configuration (or any rotation). The two canoes may not share any pegs.

Horizontal Vertical
⚪ ⚪ ⚪ ⚪ ⚪ ⚪ ⚪ ⚪ ⚪ 🔴 ⚪ ⚪
⚪ 🔴 ⚪ ⚪ 🔴 ⚪ ⚪ ⚪ 🔴 ⚪ ⚪ ⚪
⚪ ⚪ 🔴 🔴 ⚪ ⚪ ⚪ ⚪ 🔴 ⚪ ⚪ ⚪
⚪ ⚪ ⚪ ⚪ ⚪ ⚪ ⚪ ⚪ ⚪ 🔴 ⚪ ⚪

Default board layout

The only available board is based on the original design by Dale Walton.

Compiling

Compile changes into javascript and run the Elm reactor server with elm make src/Canoe.elm --output=assets/js/main.js && elm reactor

JSON Codes

Backend -> Frontend

"action" "content" Description
connect_to_server "" Server has connected. Respond with a request to create a user.

To be continued

Frontend -> Backend

"action" "content" Description
submit_move {"team": 1, "pos": {"x": x, "y": y} Submit list of moves
create_user "" Add user
update_user {"username": "User", "color": "#faefa0", "score": 5, "is_admin": true, "is_muted": false} Update user
update_chat {"user": <User>, "msg": "Hello!", "kind": 0} Send chat message
ping "ping" Send "ping" every 50 seconds to maintain the connection.

canoe-game's People

Contributors

gg314 avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

canoe-game's Issues

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.