Git Product home page Git Product logo

ildeathmatch-server's Introduction

ILDeathmatch-Server

An API for monetizing ILDeathmatch

Overview

ILDeathmatch-Server is a server that implements the dm-web-monetization middleware for payments over the Interledger. It is meant to be used with ILDeathmatch, which is a Quake III Arena server that makes API calls to this server as certain events occur in that Quake session.

Running the Server

Prerequisites:

To start, make sure an instance of moneyd is running on the machine you wish to host the server on. This daemon will allow the server to send and receive payments.

Now run npm install.

Then, create a file in the root directory called config.json and insert the following data:

{
  "JWT_SECRET": "YOUR_OWN_SECRET"
}

JWT_SECRET is a string that is used to verify the signatures of JSON Web Tokens sent to the Web Monetization Module at ILDeathmatch-Server from the Quake server at ILDeathmatch. This prevents any third parties from calling your monetized APIs. Make sure your secret here is the same as the secret you define in config.json at ILDeathmatch!

Now you can start your server with node index.js.

The server will now be listening on http://localhost:8080. To start using it for Quake, follow the instructions at ILDeathmatch to launch a Quake server instance that uses this API.

Connecting as a Client

Prerequisites

In order for a client to connect to your server and start earning/losing money on ILDeathmatch, they'll first need to install the Minute extenstion, which allows the streaming of payment to the server for spawning, and set up an ILP-SPSP receiver, which will allow the receiving of payment for kills. The section "Receiving an SPSP Payment" is the most relevant section for connecting to ILDeathmatch.

How it works

Upon loading to the ILDeathmatch-Server homepage, a client will begin streaming payments to the server through Minute. This payment stream adds to a balance associated with the client that is spent when the client connects to the game, and each time they die. The site will ask for the client's SPSP receiver, and upon receiving it will first ping it to make sure it's live, then send the client into the game. ILDeathmatch-Server will send payments to this receiver each time the client kills other players on the Quake server.

ildeathmatch-server's People

Contributors

njlie avatar

Watchers

James Cloos avatar  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.