Quake 3 PHP rcon class
Programming, phpI couldn’t find one, so I made my own Quake 3 PHP rcon class. It’s quite simple at the moment, but it works just fine. I put a one second pause before each rcon command because Quake 3 seems to ignore packets that are sent too quickly.








August 8th, 2006 at 4:08 am
Could you point me in the right direction for accessing server stats. for example. programs like x-fire or the all seeing eye, can retrieve player information form a server. like there name and how many frags ect.
how do you go about accessing that information. PHP related material would be good - but any would do !
August 8th, 2006 at 3:16 pm
maxim, take a look at QStat. It is written in C, but it is open source and you can investigate the protocols used to access server information. I have written a site called ACSSR which runs under PHP and uses QStat to collect Counter-Strike: Source server info.
November 3rd, 2006 at 2:38 am
I just downloaded ur RCON/PHP code for QUAKE3,
But can’t get it work… it says me
Parse error: syntax error, unexpected T_VARIABLE, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or ‘}’ in /home/c312942/public_html/rcon/q3query.php on line 5
Please, somebody just tell me what to do if possible??
Thanks a lot.
Best REgards (Progressive Quake3 Player)!
November 3rd, 2006 at 12:31 pm
Fest,
To me that error makes me think that you have an old version of PHP.
The script will only work on PHP 5+.
If you want to make it compatible do this:
- remove every mention of “private” and “public” before a function.
e.g. “public function set_rconpassword($p)” should say “function
set_rconpassword($p)”
- change “private” to “var” on lines 5-8.
- change “public function __construct($address, $port)” to “function
q3query($address, $port)”
Good luck.