1
What does this mean ? Is it possible to echo each players team ? [ madquery ]
//
function rcon_expand_players() {
if(!isset($this->_players) || sizeof($this->_players)==0 || $this->_rcon_password=="" || $this->_rcon_challenge=="")
return 0;
foreach($this->_players as $id => $plyr) {
$this->_rcon_send("user "".$plyr["Name"].""");
$buff=trim($this->_getmore());
if(strlen($buff)==0) $buff=trim($this->_getmore());
$buff=substr($buff,5);
foreach(split("n",$buff) as $line) {
list($key,$val)=split("[ ]+",$line);
if($key!="name") $this->_players[$id][$key]=$val;
//echo "$key => $val
n";
if($key=="model") {
if(preg_match("/(gign|sas|gsg9)/",$val)) $this->_players[$id]["Team"]="CT";
elseif(preg_match("/(terror|arctic|leet|urban)/",$val)) $this->_players[$id]["Team"]="T";
}
}
ksort($this->_players[$id]);
reset($this->_players[$id]);
}
...