Skip to content

sdumetz/Maya

Repository files navigation

Maya

Maya is a city builder aiming to have a strong population simulation.

##ES6

Maya relies quiete heavily on cutting-edge ES6 spec. See es6.md

Roadmap

  • Merge Canvas Branch
  • Decide if we use creatjs for canvas management
  • Make a simple REST API with basic query
  • Make a simple grid display
  • Add back drag & click support
  • Extend REST API for data POST to server

Docker

This app is containerized. To create the image, run : docker build -t maya ./

To run the app, run : docker run -p 8080:8080 maya (or daemonize with the -d option)

Data synchronization from src dir to container : docker run -p 8080:8080 -v :/src maya

Other usefull commands : docker run -v :/src maya npm test docker run maya npm install

App is then available on port 8080

Data model

Basic

basic model is an array of tiles represented by :

  • Required (valid and not null)
    • content (string hash)
    • x (int)
    • y (int)

Network

Networking is mainly event-based

Routes

GET /

Get game client

Events

Events are sent using the socket.io library

They can be categorized as server-sent events or client-sent events

subscribe (client)

Subscribe on a chunk of data modifications

unsubscribe (client)

Unsubscribe from a chunck

update (server)

notify clients of an array of updated tiles.

About

Maya Project

Resources

License

Stars

1 star

Watchers

4 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors