2017 © Pedro Peláez
 

library php-rcon-minecraft

Send commands from php to minecraft

image

goldman40/php-rcon-minecraft

Send commands from php to minecraft

  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 35 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

PHP-Minecraft-Rcon

Simple Rcon class for php., (*1)

Connection is established over TCP., (*2)

Available on https://packagist.org/packages/goldman40/php-rcon-minecraft, (*3)

Examples

For this script to work, rcon must be enabled on the server, by setting enable-rcon=true in the server's server.properties file. A password must also be set, and provided in the script., (*4)

use thedudeguy\Rcon;

$host = 'some.minecraftserver.com'; // Server host name or IP
$port = 25567;                      // Port rcon is listening on
$password = 'server-rcon-password'; // rcon.password setting set in server.properties
$timeout = 3;                       // How long to timeout. Default 3

$rcon = new Rcon($host, $port, $password, $timeout);

if ($rcon->connect())
{
  $rcon->send_command("say Hello World!");
}

The Versions

13/11 2016

dev-master

9999999-dev

Send commands from php to minecraft

  Sources   Download

MIT

The Requires

  • php >=5.4

 

php minecraft rcon