public function __construct($player_id) { PlayerData::getInstance()->setId($player_id); $this->name = PlayerData::getInstance()->getName(); $this->paramaters = PlayerData::getInstance()->getParam(); $this->hp = $this->paramaters['hp']; $this->atk = $this->paramaters['atk']; $this->def = $this->paramaters['def']; $this->mp = $this->paramaters['mp']; $this->actions = PlayerData::getInstance()->getAction(); }