miped / rcon

Package for communicating with Source game servers

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

rcon

Build Status Test Coverage GoDoc License

This package implements the rcon protocol for communicating with Source engine servers.

Usage

A simple example:

package main

import (
    "github.com/madcitygg/rcon"
)

func main() {
    r, err := rcon.Dial("10.10.10.10:27015")
    if err != nil {
        panic(err)
    }
    defer r.Close()

    err = r.Authenticate("password")
    if err != nil {
        panic(err)
    }

    response, err := r.Execute("status")
    if err != nil {
        panic(err)
    }

    fmt.Printf("Response: %+v\n", response)
}

About

Package for communicating with Source game servers

License:MIT License


Languages

Language:Go 100.0%