| 1 | <?php |
||
| 8 | abstract class AbstractGameOptions implements GameOptions |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * @var PlayerOptions[] |
||
| 12 | */ |
||
| 13 | protected $playerOptions; |
||
| 14 | |||
| 15 | /** |
||
| 16 | * Constructor |
||
| 17 | * |
||
| 18 | * @param PlayerOptions[] $playerOptions |
||
| 19 | */ |
||
| 20 | 3 | public function __construct(array $playerOptions = []) |
|
| 21 | { |
||
| 22 | 3 | $this->init($playerOptions); |
|
| 23 | 3 | } |
|
| 24 | |||
| 25 | /** |
||
| 26 | * Init. |
||
| 27 | * |
||
| 28 | * @param PlayerOptions[] $playerOptions |
||
| 29 | */ |
||
| 30 | 3 | protected function init(array $playerOptions) |
|
| 31 | { |
||
| 32 | 3 | $this->playerOptions = $playerOptions; |
|
| 33 | 3 | } |
|
| 34 | |||
| 35 | /** |
||
| 36 | * Returns the list of players |
||
| 37 | * |
||
| 38 | * @return PlayerOptions[] |
||
| 39 | */ |
||
| 40 | 3 | public function getPlayerOptions() |
|
| 44 | } |
||
| 45 |