예제 #1
0
 public function __construct($login)
 {
     parent::__construct();
     $this->setRoomSettings($login);
     $this->whetherInRoom($login);
     //устанавливает UserBusyInfo
     if ($this->getUserBusyInfo()['roomStatus'] !== 'start' and $this->getUserBusyInfo()['roomStatus'] !== 'end') {
         //если игрок не находиться в игре
         $this->methodGet($login);
         $this->methodPost($login);
         if ($this->getUserBusyInfo()['roomStatus'] === 'created') {
             $this->textAddPlayersPage($login);
         }
         $this->setSingleRooms($login);
         //достать из базы все одиночные комнаты
     } else {
         $playGame = new playGameController($login, $this->getRoomSettings());
         startCore::setObject('playGame', $playGame);
     }
     $this->setJSCss();
     //устанавливает css
 }
예제 #2
0
 private function setUsersObject($login)
 {
     startCore::setCSS('viewUsers.css');
     startCore::setJS('viewUsers.js');
     startCore::setObject('viewUsers', new usersController($login, filter_input(INPUT_GET, 'action')));
 }
예제 #3
0
 protected function setPageParams($path)
 {
     $pageParams = $this->getData()->getPages($path);
     startCore::setObject('pageParams', $pageParams);
 }