<commit_before><?php

namespace Matthww\PlayerInfo;

use Matthww\PlayerInfo\utils\SpoonDetector;
use pocketmine\command\Command;
use pocketmine\command\CommandSender;
use pocketmine\command\ConsoleCommandSender;
use pocketmine\event\Listener;
use pocketmine\event\player\PlayerJoinEvent;
use pocketmine\event\server\DataPacketReceiveEvent;
use pocketmine\network\mcpe\protocol\LoginPacket;
use pocketmine\Player;
use pocketmine\plugin\PluginBase;
use pocketmine\utils\TextFormat as TF;

class PlayerInfo extends PluginBase implements Listener {

    protected $DeviceOS;
    protected $DeviceModel;
    protected $UIProfile;
    protected $PlayerData;
    protected $config;

    public function onEnable() {
        $this->getServer()->getPluginManager()->registerEvents($this, $this);

        if(!is_dir($this->getDataFolder())) {
            mkdir($this->getDataFolder());
        }
        if(!is_dir($this->getDataFolder() . "players")) {
            mkdir($this->getDataFolder() . "players");
        }
        if(!file_exists($this->getDataFolder() . "config.yml")) {
            $this->saveDefaultConfig();
        }
        if(!file_exists($this->getDataFolder() . "models.yml")) {
            $this->saveResource("models.yml", false);
        }

        SpoonDetector::printSpoon($this, 'spoon.txt');
        $this->getLogger()->notice("is enabled");
    }

    public function onDisable() {
        $this->getLogger()->notice("is disabled!");
    }

    public function onPacketReceived(DataPacketReceiveEvent $receiveEvent) {
        $pk = $receiveEvent->getPacket();

        if($pk instanceof LoginPacket) {
            $this->PlayerData[$pk->username] = $pk->clientData;
        }
    }

    public function onJoin(PlayerJoinEvent $joinEvent) {<commit_msg>Remove extra loading messages<commit_after><?php

namespace Matthww\PlayerInfo;

use Matthww\PlayerInfo\utils\SpoonDetector;
use pocketmine\command\Command;
use pocketmine\command\CommandSender;
use pocketmine\command\ConsoleCommandSender;
use pocketmine\event\Listener;
use pocketmine\event\player\PlayerJoinEvent;
use pocketmine\event\server\DataPacketReceiveEvent;
use pocketmine\network\mcpe\protocol\LoginPacket;
use pocketmine\Player;
use pocketmine\plugin\PluginBase;
use pocketmine\utils\TextFormat as TF;

class PlayerInfo extends PluginBase implements Listener {

    protected $DeviceOS;
    protected $DeviceModel;
    protected $UIProfile;
    protected $PlayerData;
    protected $config;

    public function onEnable() {
        $this->getServer()->getPluginManager()->registerEvents($this, $this);

        if(!is_dir($this->getDataFolder())) {
            mkdir($this->getDataFolder());
        }
        if(!is_dir($this->getDataFolder() . "players")) {
            mkdir($this->getDataFolder() . "players");
        }
        if(!file_exists($this->getDataFolder() . "config.yml")) {
            $this->saveDefaultConfig();
        }
        if(!file_exists($this->getDataFolder() . "models.yml")) {
            $this->saveResource("models.yml", false);
		}

        SpoonDetector::printSpoon($this, 'spoon.txt');
    }

    public function onPacketReceived(DataPacketReceiveEvent $receiveEvent) {
        $pk = $receiveEvent->getPacket();

        if($pk instanceof LoginPacket) {
            $this->PlayerData[$pk->username] = $pk->clientData;
        }
    }

    public function onJoin(PlayerJoinEvent $joinEvent) {
{'fraction_non_alphanumeric': 0.1345646437994723, 'fraction_numerical': 0.0, 'mean_word_length': 3.477690288713911, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 37, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5510120', 'n_tokens_mistral': 981, 'n_tokens_neox': 958, 'n_words': 166}