Git Product home page Git Product logo

dcs-mission-planner-server's Introduction

dcs-mission-planner-server

The server component of the DCS: World Mission Planner

How to run

The server requires Python 3 and the modules listed in requirements.txt.

On Linux, the following commands should get you up and running:

$ git clone [email protected]:jboecker/dcs-mission-planner-server.git
$ cd dcs-mission-planner-server
$ virtualenv -p python3 venv
$ source venv/bin/activate
$ pip install -r requirements.txt
$ cd src
$ python serve.py 8080

On Windows, you may be interested in the following links:

Please note that there is no official support for running your own server.

Quick Overview

The server side of the mission planner does not do much. It facilitates communication between the clients and otherwise stays out of the way.

Data is stored in a key-value store. All keys are simple strings, most values are encoded as JSON before saving.

Instances are stored under the key "instance-<instance_id>". The key "instance-list" stores a JSON array of all existing instance IDs. The "next_instance_id" key stores the next instance ID to be assigned.

Instances

An instance is represented by a python dictionary. See the handle_create_instance_request method for a list of fields. The most important field is instance["data"]["objects"]. This is a mapping of object IDs to values and can be thought of as a per-instance key-value store.

Clients connect to the server over a WebSocket.

Connected clients will be notified of any changes to this shared key-value store and can change it with "transaction" requests. A transaction request has a list of preconditions (if this is not a subset of the objects in the key-value store, the transaction fails), a list of (IDs of) objects that should be deleted, and a list of objects that should be updated or created.

License

The airports.kml file was made by kosmos224 and was downloaded from DCS User Files, which lists "Freeware - Free version, Unlimited distribution" in the license field.

jQuery (js/jquery-2.1.0.min.js) is under the MIT license (see https://jquery.org/license/ for details).

Everything else is released under the terms of the GNU AGPL license (see AGPL.txt).

dcs-mission-planner-server's People

Contributors

crash-horror avatar jboecker avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

dcs-mission-planner-server's Issues

A little 'print' to indicate server is running

I have been fiddling with hosting this to our squad server and works great.
Many thanks for this.
For simlicity sake I made a *.bat thingy for starting the server and added the line below to indicate it is running, cause otherwise it pops an empty cmd window.

line 243:

if __name__ == "__main__":
    app.listen(int(sys.argv[1]))
#-------CRASH ADDED THIS-----------
    print("Server running @ port {0} - Hit CTRL-C to quit".format(int(sys.argv[1])))
#----------------------------------
    tornado.ioloop.IOLoop.instance().start()

start_server.bat:

START cmd.exe /k "cd C:\YOUR\PATH\TO\dcs-mission-planner-server-master & python serve.py 5000"

I am new at this, so if I posted this incorrectly I apologize.

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.