added log message on player join / leave

This commit is contained in:
kremsy
2013-12-09 19:31:55 +01:00
parent 323cec03ac
commit 16c5a12cff
2 changed files with 13 additions and 9 deletions

View File

@ -30,7 +30,7 @@ class Player {
public $ladderScore = -1.;
public $ladderRank = -1;
public $joinTime = -1;
public $ipAddress = '';
/**
* Construct a player from XmlRpc data
*
@ -40,7 +40,6 @@ class Player {
if (!$rpcInfos) {
return;
}
$this->pid = $rpcInfos['PlayerId'];
$this->login = $rpcInfos['Login'];
$this->nickname = $rpcInfos['NickName'];
@ -56,7 +55,9 @@ class Player {
$this->isReferee = $rpcInfos['IsReferee'];
$this->ladderScore = $rpcInfos['LadderStats']['PlayerRankings'][0]['Score'];
$this->ladderRank = $rpcInfos['LadderStats']['PlayerRankings'][0]['Ranking'];
$this->ipAddress = $rpcInfos['IPAddress'];
$this->joinTime = time();
}