public function __construct(array $kwargs) { parent::__construct($kwargs); if (array_key_exists('speed', $kwargs)) { $this->setSpeed($kwargs['speed']); } if (array_key_exists('max_shield', $kwargs)) { $this->_max_shield = intval($kwargs['max_shield']); } if (array_key_exists('power', $kwargs)) { $this->setPower($kwargs['power']); } if (array_key_exists('orientation', $kwargs)) { $this->setOrientation($kwargs['orientation']); } $this->_weapons = array(); if (array_key_exists('weapons', $kwargs)) { $this->setWeapons($kwargs['weapons']); } }
/** * Set up the initial pawn set * */ public function SetUpPawns() { Pawn::GenerateSet(); }