My auth plugin it works but when a player join the server i have this error on Console: What should i do whit this error in ALPHA7, what should i change for ALPHA 7? 14.09 11:50:18 [Server] Server thread/CRITICAL Could not pass event 'pocketmine\event\server\DataPacketSendEvent' to 'LeoHarduA v4.0.0': Return value of pocketmine\entity\Entity::getId() must be of the type integer, null returned on HereAuth\EventRouter 14.09 11:50:18 [Server] Server thread/CRITICAL TypeError: "Return value of pocketmine\entity\Entity::getId() must be of the type integer, null returned" (EXCEPTION) in "src/pocketmine/entity/Entity" at line 1854 14.09 11:50:18 [Server] Server thread/DEBUG #0 LeoHarduA/src/HereAuth/HereAuth(250): pocketmine\entity\Entity->getId() 14.09 11:50:18 [Server] Server thread/DEBUG #1 LeoHarduA/src/HereAuth/EventRouter(257): HereAuth\HereAuth->getUserByPlayer(pocketmine\Player object) 14.09 11:50:18 [Server] Server thread/DEBUG #2 src/pocketmine/plugin/MethodEventExecutor(38): HereAuth\EventRouter->onSend(pocketmine\event\server\DataPacketSendEvent object) 14.09 11:50:18 [Server] Server thread/DEBUG #3 src/pocketmine/plugin/RegisteredListener(98): pocketmine\plugin\MethodEventExecutor->execute(HereAuth\EventRouter object, pocketmine\event\server\DataPacketSendEvent object) 14.09 11:50:18 [Server] Server thread/DEBUG #4 src/pocketmine/plugin/PluginManager(714): pocketmine\plugin\RegisteredListener->callEvent(pocketmine\event\server\DataPacketSendEvent object) 14.09 11:50:18 [Server] Server thread/DEBUG #5 src/pocketmine/Player(1104): pocketmine\plugin\PluginManager->callEvent(pocketmine\event\server\DataPacketSendEvent object) 14.09 11:50:18 [Server] Server thread/DEBUG #6 src/pocketmine/Player(1072): pocketmine\Player->sendDataPacket(pocketmine\network\mcpe\protocol\PlayStatusPacket object, boolean , boolean ) 14.09 11:50:18 [Server] Server thread/DEBUG #7 src/pocketmine/Player(1999): pocketmine\Player->dataPacket(pocketmine\network\mcpe\protocol\PlayStatusPacket object) 14.09 11:50:18 [Server] Server thread/DEBUG #8 src/pocketmine/Player(1845): pocketmine\Player->sendPlayStatus(integer 0) 14.09 11:50:18 [Server] Server thread/DEBUG #9 src/pocketmine/Player(1988): pocketmine\Player->processLogin() 14.09 11:50:18 [Server] Server thread/DEBUG #10src/pocketmine/network/mcpe/PlayerNetworkSessionAdapter(102): pocketmine\Player->handleLogin(pocketmine\network\mcpe\protocol\LoginPacket object) 14.09 11:50:18 [Server] Server thread/DEBUG #11 src/pocketmine/network/mcpe/protocol/LoginPacket(109): pocketmine\network\mcpe\PlayerNetworkSessionAdapter->handleLogin(pocketmine\network\mcpe\protocol\LoginPacket object) 14.09 11:50:18 [Server] Server thread/DEBUG #12src/pocketmine/network/mcpe/PlayerNetworkSessionAdapter(94): pocketmine\network\mcpe\protocol\LoginPacket->handle(pocketmine\network\mcpe\PlayerNetworkSessionAdapter object) 14.09 11:50:18 [Server] Server thread/DEBUG #13 src/pocketmine/network/mcpe/protocol/BatchPacket(106): pocketmine\network\mcpe\PlayerNetworkSessionAdapter->handleDataPacket(pocketmine\network\mcpe\protocol\LoginPacket object) 14.09 11:50:18 [Server] Server thread/DEBUG #14src/pocketmine/network/mcpe/PlayerNetworkSessionAdapter(94): pocketmine\network\mcpe\protocol\BatchPacket->handle(pocketmine\network\mcpe\PlayerNetworkSessionAdapter object) 14.09 11:50:18 [Server] Server thread/DEBUG #15 src/pocketmine/Player(3072): pocketmine\network\mcpe\PlayerNetworkSessionAdapter->handleDataPacket(pocketmine\network\mcpe\protocol\BatchPacket object) 14.09 11:50:18 [Server] Server thread/DEBUG #16 src/pocketmine/network/mcpe/RakLibInterface(145): pocketmine\Player->handleDataPacket(pocketmine\network\mcpe\protocol\BatchPacket object) 14.09 11:50:18 [Server] Server thread/DEBUG #17 src/raklib/server/ServerHandler(97): pocketmine\network\mcpe\RakLibInterface->handleEncapsulated(string 201.92.75.130:65138, raklib\protocol\EncapsulatedPacket object, integer 0) 14.09 11:50:18 [Server] Server thread/DEBUG #18 src/pocketmine/network/mcpe/RakLibInterface(84): raklib\server\ServerHandler->handlePacket() 14.09 11:50:18 [Server] Server thread/DEBUG #19 src/pocketmine/network/Network(89): pocketmine\network\mcpe\RakLibInterface->process() 14.09 11:50:18 [Server] Server thread/DEBUG #20 src/pocketmine/Server(2473): pocketmine\network\Network->processInterfaces() 14.09 11:50:18 [Server] Server thread/DEBUG #21 src/pocketmine/Server(2239): pocketmine\Server->tick() 14.09 11:50:18 [Server] Server thread/DEBUG #22 src/pocketmine/Server(2118): pocketmine\Server->tickProcessor() 14.09 11:50:18 [Server] Server thread/DEBUG #23 src/pocketmine/Server(1700): pocketmine\Server->start() 14.09 11:50:18 [Server] Server thread/DEBUG #24 src/pocketmine/PocketMine(541): pocketmine\Server->__construct(BaseClassLoader object, pocketmine\utils\MainLogger object, string phar:///custom7.phar/, string /, string /plugins/) 14.09 11:50:18 [Server] Server thread/DEBUG #25 /custom7.phar(1): require(string phar:///custom7.phar/src/pocketmine/PocketMine.php)
It looks like Entity::getId() was called on a closed entity. You might want to check if the entity is closed beforehand