public function onPlayerConnect(Player $playerData)
    {
        $login = $playerData->getLogin();

        $this->online[$login] = $playerData;

        if ($playerData->isSpectator()) {
            $this->spectators[$login] = $playerData;
        } else {
            $this->players[$login] = $playerData;
        }
    }
public function onPlayerConnect(Player $playerData)
    {
        $login = $playerData->getLogin();

        $this->online[$login] = $playerData;

        if ($playerData->isSpectator()) {
            $this->spectators[$login] = $playerData;
        } else {
            $this->players[$login] = $playerData;
        }
    }
public function onPlayerConnect ( Player $ playerData ) { $ login = $ playerData -> getLogin ( ) ; $ this -> online [ $ login ] = $ playerData ; if ( $ playerData -> isSpectator ( ) ) { $ this -> spectators [ $ login ] = $ playerData ; } else { $ this -> players [ $ login ] = $ playerData ; } }
Fetch player data & store it when player connects.

@inheritdoc
Fetch player data & store it when player connects .