From 47e280c9770e9a45e2962c1c02b50ad2b28a826f Mon Sep 17 00:00:00 2001 From: onyx-and-iris Date: Thu, 30 Nov 2023 22:38:05 +0000 Subject: [PATCH] add Rcon class section to README. --- README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/README.md b/README.md index 2a8663d..16dedcc 100644 --- a/README.md +++ b/README.md @@ -35,3 +35,21 @@ finally { Disconnect-Rcon -rcon $rcon } ``` + +## Rcon Class + +### `Send($cmd) | Send($cmd, $timeout)` + +Send a RCON command as a string. For example: + +```powershell +$rcon.Send("mapname") + +$rcon.Send("g_gametype dm") + +$rcon.Send("map_rotate", 2000) +``` + +If the command returns a response it will be printed to the console. + +Pass an optional timeout (ms) for commands that return responses in fragments. (status, map_rotate etc...)