Added /reload command (does not reload source code)

This commit is contained in:
Shoghi Cervantes
2014-04-03 15:49:00 +02:00
parent ee6dc989ce
commit 80f9093875
12 changed files with 210 additions and 70 deletions

View File

@ -31,6 +31,7 @@ class RCONInstance extends \Thread{
private $password;
private $maxClients;
public function __construct($socket, $password, $maxClients = 50){
$this->stop = false;
$this->cmd = "";
@ -43,6 +44,7 @@ class RCONInstance extends \Thread{
$this->{"status" . $n} = 0;
$this->{"timeout" . $n} = 0;
}
$this->start();
}
@ -80,6 +82,7 @@ class RCONInstance extends \Thread{
}
public function run(){
while($this->stop !== true){
usleep(2000);
$r = array($socket = $this->socket);