Last active
January 31, 2024 18:05
-
-
Save grey-cat-1908/6aa7894ae94588886aa5a1c7e786b5e4 to your computer and use it in GitHub Desktop.
A simple automated script for using Minecraft RCON on Windows
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
@cls | |
chcp 65001 | |
TITLE MCRCON | |
if exist mcrcon\ ( | |
@echo mcrcon is already installed. | |
) else ( | |
@echo installing mcrcon... | |
powershell -command "Start-BitsTransfer -Source https://github.com/Tiiffi/mcrcon/releases/download/v0.7.2/mcrcon-0.7.2-windows-x86-64.zip -Destination mcrcon-unpacked.zip" | |
powershell -command "Expand-Archive mcrcon-unpacked.zip mcrcon" | |
) | |
@set /p host="Enter host (default: 127.0.0.1): " | |
@if "%host%"=="" set host=127.0.0.1 | |
@set /p port="Enter port (default: 25575): " | |
@if "%port%"=="" set port=25575 | |
@set /p password="Enter password: " | |
@if "%password%"=="" set password= | |
TITLE MCRCON - %host%:%port% | |
@echo. | |
mcrcon\mcrcon.exe -t -H %host% -P %port% -p %password% | |
@echo. | |
@set "host=" | |
@set "port=" | |
@set "password=" | |
@pause |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment