Rcon

API Documentation

\GSPPanel\Rcon

This class allows rcon interactions with gameservers

Methods

SendCommand(array $params) : array

Sends the rcon command

$params requires the following:

  • ip: The ip for the gameserver(REQUIRED)
  • port: The Rcon port for the gameserver(REQUIRED)
  • protocol: The Rcon protocol(REQUIRED)
  • password: The Rcon password
  • command: The command to send to the server(REQUIRED)

Returns one of the following in an array format:

  • error
    • -1 - No ip specified
    • -2 - No port specified
    • -3 - No protocol specified
    • -4 - No command specified
    • -5 - Protocol not found
    • -6 - Unknown rcon error
  • array of game information, this varies depending on game
Parameters
NameTypeDescription
$paramsarray
Returns
TypeDescription
array
Documentation was generated by phpDocumentor 2.9.0.