MinecraftRcon 1.0.1

dotnet add package MinecraftRcon --version 1.0.1
NuGet\Install-Package MinecraftRcon -Version 1.0.1
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="MinecraftRcon" Version="1.0.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add MinecraftRcon --version 1.0.1
#r "nuget: MinecraftRcon, 1.0.1"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install MinecraftRcon as a Cake Addin
#addin nuget:?package=MinecraftRcon&version=1.0.1

// Install MinecraftRcon as a Cake Tool
#tool nuget:?package=MinecraftRcon&version=1.0.1

Minecraft Rcon

Description

A simple program for remote management of a Minecraft server using the RCON protocol.

Features

  • Authentication using RCON password.
  • Sending commands to the server using the RCON protocol.

Requirements

  • .NET 8.0 or later

Configuration

Default settings, such as host address, port, and RCON password, can be changed in the Terminal.cs file under the Default Configuration section.

Running the Program

To run the program as a standalone application, follow these steps:

  1. Open a terminal in the project directory.

  2. Run the application using the following command:

    dotnet run
    
  3. Upon launch, enter the required information such as host address, port, and RCON password.

Using as a NuGet Package

If you want to use this project as a NuGet package in your own project, follow these steps:

  1. Install the NuGet package using the package manager console:

    Install-Package MinecraftRcon
    
  2. In your code, you can use the Client class to interact with the Minecraft server using RCON:

    using MinecraftRcon;
    
    class Program
    {
        static async Task Main(string[] args)
        {
            var host = "your_server_host";
            var port = 25575;
            var password = "your_rcon_password";
    
            using var client = new Client(host, port);
    
            if (await client.AuthenticateAsync(password))
            {
                var command = "your_minecraft_command";
                var response = await client.SendCommandAsync(command);
    
                Console.WriteLine(response?.Body ?? "Command failed");
            }
            else
            {
                Console.WriteLine("Authentication failure");
            }
        }
    }
    

Author

rallez

Contact

Discord: rallez Email: rallezg1@gmail.com

License

This project is licensed under the MIT License - see the LICENSE.md file for details.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net8.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.1 87 2/19/2024
1.0.0 77 2/19/2024