I have a problem with my code thx for helping Code: PHP: public function onMove(PlayerMoveEvent $event){ $player = $event->getPlayer(); $block = $player->getLevel()->getBlock($player->floor()->subtract(0, 1, 0)); if($block->getId() === 1) { $player->getLevel()->setBlock(new Vector3($block->getX(), $block->getY(), $block->getZ()), Block::AIR); } }} Error: PHP: [20:51:41] [Server thread/CRITICAL]: "Could not pass event 'pocketmine\event\player\PlayerMoveEvent' to 'test v1': Argument 2 passed to pocketmine\level\Level::setBlock() must be an instance of pocketmine\block\Block, integer given, called in C:\Users\User\Downloads\PocketMine-MP\plugins\test\src\test\Main.php on line 21 and defined on test\Main[20:51:41] [Server thread/NOTICE]: InvalidArgumentException: "Argument 2 passed to pocketmine\level\Level::setBlock() must be an instance of pocketmine\block\Block, integer given, called in C:\Users\User\Downloads\PocketMine-MP\plugins\test\src\test\Main.php on line 21 and defined" (E_RECOVERABLE_ERROR) in "/src/pocketmine/level/Level" at line 1582
Maybe: PHP: $airblock = new Block(0);$player->getLevel()->setBlock(new Vector3($block->getX(), $block->getY(), $block->getZ()), $airblock);