TrackManiaControl/application/plugins/Dedimania/DedimaniaPlayer.php

41 lines
800 B
PHP
Raw Normal View History

2014-02-23 13:15:28 +01:00
<?php
/**
* Created by PhpStorm.
* User: Lukas
* Date: 23.02.14
* Time: 12:45
*/
namespace Dedimania;
class DedimaniaPlayer {
public $login = '';
public $maxRank = -1;
public $banned = false;
public $optionsEnabled = false;
public $options = '';
public function __construct($player) {
if ($player == null) {
return;
}
$this->login = $player['Login'];
$this->maxRank = $player['MaxRank'];
$this->banned = $player['Banned'];
$this->optionsEnabled = $player['OptionsEnabled'];
2014-02-24 20:20:17 +01:00
$this->options = $player['Options'];
2014-02-23 13:15:28 +01:00
}
/**
* Construct a new Player by its login and maxRank
2014-02-24 20:20:17 +01:00
*
2014-02-23 13:15:28 +01:00
* @param $login
* @param $maxRank
*/
2014-02-24 20:20:17 +01:00
public function constructNewPlayer($login, $maxRank) {
$this->login = $login;
2014-02-23 13:15:28 +01:00
$this->maxRank = $maxRank;
}
}