Giter Site home page Giter Site logo

kennethehmsen / battlecon Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dcodeio/battlecon

0.0 1.0 0.0 5.8 MB

A Battlefield / Frostbite engine RCON layer on node.js.

Home Page: http://dcode.io

License: Apache License 2.0

Python 41.08% JavaScript 58.92%

battlecon's Introduction

BattleCon - BATTLEFIELD layer on node.js

BattleCon is a Battlefield / Frostbite engine RCON layer built on top of nothing less than the excellent node.js platform.

With BattleCon it's easy to create your very own server management interface, like automatic map votings, auto team balancing, live player stats and more.

Usage

Executing commands:

var BattleCon = require("battlecon"),
    bc = new BattleCon("host", port, "pass").use("core");
    
bc.on("login", function() {
    bc.exec("version", function(err, res) {
        if (err) {
            console.log("Error: "+err);
            return;
        }
        console.log("version:", res);
    });
});

bc.connect(); // Connects and logs in

Processing (raw) server events:

...
bc.on("event", function(evt) {
    console.log("Event:", evt);
});

Core

The core module implements common commands used between Frostbite-driven games, like logging in and out, version and server info querying.

Modules

Additionally, BattleCon supports game-specific modules, like the BF3 and BF4 modules. Loading modules is simple:

...
var bc = new BattleCon("host", port, "pass").use("BF4");

...your logic...

bc.connect();

Currently, the game modules are quite basic and provide basic functionality only. Feel free to extend them and send me a pull request!

Examples

There is a simple example of how to use BattleCon, like reacting to server events and issuing commands:

License

Apache License, Version 2.0

battlecon's People

Contributors

dcodeio avatar

Watchers

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