Skip to content

Latest commit

 

History

History
29 lines (23 loc) · 1.29 KB

README.md

File metadata and controls

29 lines (23 loc) · 1.29 KB

RCONsole

A light weight and thread-safe RCON library for Minecraft servers written in .NET Standard 2.0 Based on MinecraftServerRCONSharp

Issues or Bugs

If you come across any bugs or issues of the sort (even ideas for things I could add) please feel free to open a new issue outlining your problem :)

Limitations

Due to limitations with Minecrafts own implementation of RCON, sending multiple commands to the same server from seperate or identical clients on seperate threads can result in unexpected behaviour and is not recommended

Setup

Easiest way to use this library is via NuGet

Or download the library from the releases page.

Example usage: Change the gamemode of the player "Steve" to creative

using MinecraftServerRCON;

class RCONTest
{
    static void Main(string[] args)
    {
        using var rcon = new RCONClient();
        rcon.SetupStream("127.0.0.1", 25575, "123", new ClientConfiguration());
        string answer = rcon.SendMessage(RCONMessageType.Command, "gamemode creative Steve");
        Console.WriteLine(answer.RemoveColorCodes());
    }
}