How to send "status" server cod2(NO RCON)? with the results:
1) Number of players
2) The map / mode
3) Nicky players / Statistics
and so on.
PHP
How to send "status" server cod2(NO RCON)? with the results:
1) Number of players
2) The map / mode
3) Nicky players / Statistics
and so on.
PHP
Basically you just make an UDP request and parse it, e.g. with explode(...)
Example code could be found in these projects, google for "php rcon call of duty".
http://callofduty.filefront.com/file...oD4_RCON;84664
https://ashus.ashus.net/viewtopic.php?t=27
timescale 0.01
fuleX (4th May 2015),maxdamage99 (4th May 2015)
This method is known to me, I thought there is any other!
But anyway, thank you!
But still, it can be done without rcon password?!?!
Rcon commands, no.
But none rcon commands like getstatus and getinfo are used without passwords.
See: http://killtube.org/showthread.php?2...ng-server-info (if you don't like to search it yourself within this forum)
kung foo man (6th May 2015)
@maxdamage99 You can always use API from services like game-monitor.
I made an example in PHP:
PHP Code:
<?php
ini_set( "display_errors", false );
//$host = "192.168.1.2"; // localhost
//$port = 28960;
$host = "46.4.55.66"; // evil.High Jump CRACKED
$port = 28958;
$serialized = file_get_contents( "http://module.game-monitor.com/$host:$port/data/server.php" );
$json_data = unserialize( $serialized );
$array = ( array )$json_data;
if( $array["error"] == 0 )
{
$hostname = $array["name"];
$ip = $array["ip"];
$port = $array["port"];
$player = $array["player"];
$maxplayer = $array["maxplayer"];
$hostname = "<pre>Hostname: $hostname</pre>";
$ip = "<pre>IP: $ip:$port</pre>";
$players = "<pre>Players: $player/$maxplayer</pre>";
}
else
{
$hostname = "<pre>Server offline or wrong IP</pre>";
$ip = "<pre>IP: $host:$port</pre>";
}
?>
<html>
<body>
<?php echo $hostname; ?>
<?php echo $ip; ?>
<?php echo $players; ?>
</body>
</html>
kung foo man (15th May 2015)
No thanks, I do not need it! I need a way to himself. There is an option nicks count after mod\1\. But I need to make sure the script is needed!