Rot Web Api Save

roguelike dungeon generator RESTful web api

Project README

Dungeon generator server Build Status

A self-hosted dungeon generation server!

Deploy

Table of Contents

How it works

This server comes with a sample index.html that shows when you send a GET request to the server, it responds with a new map in kind. This allows you to fully decouple the dungeon generation into a microservice, so that the game can be written in any language that can send HTTP requests and read JSON. Thus, the responsibility for (at least, the initial) dungeon generation itself is offloaded completely.

API

Should you send a GET request to the server, you will receive JSON data. Read the API documentation on apiary for endpoint information with examples.

Server setup

The API server runs on Node.js, and has been engineered to be a microservice and run in the cloud. The easiest way to get your own server up and running is to deploy with heroku (which is of no cost to you), that way, you dont need to setup your own server or install nodejs.

Test environment

To run on your own system, you need Node.js v7.x installed. From there, you can run your own version by cloning this repo, then running npm install/start.

git clone https://github.com/MattMcFarland/rot-web-api.git
cd rot-web-api
npm install
npm start

Your server should then be running on localhost:8080, from which you can use the REST API end points.

Examples

When the server is running, you can navigate to the root url to see a very basic example of API usage.

There is an example server running on heroku right now, if you would like to give it a test drive. That being said, I highly recommend you check out the documentation on apiary, as it includes live examples and hits the same server endpoints, anyway.

Acknowledgements

This would not be possible without the hard work and tireless efforts from the contributors/authors of the following projects:

  • ROT-JS provides the algorithms for creating the dungeons, authored by Ondrej Zara
  • Merry provides the RESTful API service, authored by Yoshua Wuyts
  • NodeJS provides the run-time environment, authored by many.
  • NPM, the package manager for nodejs, authored by many

LICENSE

MIT

Open Source Agenda is not affiliated with "Rot Web Api" Project. README Source: MattMcFarland/rot-web-api
Stars
58
Open Issues
0
Last Commit
7 years ago
License
MIT

Open Source Agenda Badge

Open Source Agenda Rating