Fibinger Ádám
2019-10-17 a4186ab0762833a4c4dd741e6dd112185efc2272
EOG/Models/MatchHistory.php
@@ -9,7 +9,7 @@
    const ROLE_ATTACK = 'att';
    const ROLE_DEFEND = 'def';
    protected $sites = [
    protected $maps = [
        'Bank' => [
            'CEO Office / Executive Lounge',
            'Open Area / Staff Room',
@@ -84,9 +84,14 @@
    /**
     * @return array
     */
    public function getSites(): array
    public function getMaps(): array
    {
        return $this->sites;
        return $this->maps;
    }
    public function getMapNames()
    {
        return array_keys($this->maps);
    }
    /**
@@ -95,6 +100,11 @@
    public function getCurrentMap(): string
    {
        return $this->currentMap;
    }
    public function getCurrentSites(): array
    {
        return $this->maps[$this->currentMap];
    }
    /**
@@ -107,13 +117,13 @@
    private function validMap($mapName)
    {
        $mapList = array_keys($this->sites);
        $mapList = array_keys($this->maps);
        return in_array($mapName, $mapList);
    }
    private function validSite($siteName)
    {
        return in_array($siteName, $this->sites[$this->currentMap]);
        return in_array($siteName, $this->maps[$this->currentMap]);
    }
    public function setCurrentMap(string $mapName)