Is there any way to prevent players from using toolbox on t server? tried that way but it didn't work PHP: public function aoRcb(DataPacketReceiveEvent $event){ $packet = $event->getPacket(); $player = $event->getPlayer(); if ($packet instanceof LoginPacket) { if ($packet->clientId === 0) { $player->kick("YOU GET OUT", false); } }}
The code would work If you were in MCPE 1.1 or under, or 3 years ago. Toolbox now randomizes their clientId. Maybe just create an anti-cheat system or use one from poggit.
Anti-Xray : https://poggit.pmmp.io/p/AntiXray/1.0.1 Anti-Instabrak : https://poggit.pmmp.io/p/AntiInstaBreak/0.1.2 and there is more
hi i apologize for bad english as i am russian. I know a way to solve this problem. You need to dump (var_dump) the player's model, the toolbox will seem to have the entire line with its model in uppercase, and in the original Minecraft the first letter will be in uppercase, the rest in lowercase
PHP: public function onEnable () { \pocketmine\Server::getInstance()->getPluginManager()->registerEvents($this, $this); } public function join (\pocketmine\event\server\DataPacketReceiveEvent $event) { $packet = $event->getPacket(); $player = $event->getPlayer(); if($packet instanceof \pocketmine\network\mcpe\protocol\LoginPacket) { if ($packet->clientData["DeviceOS"] === 1) { $model = $packet->clientData["DeviceModel"]; $ruskiy = substr($model, 0, 3); if (ctype_upper ($ruskiy)) { $this->getLogger()->info("The string consists of uppercase letters only"); } } } }