So I am currently expirimenting with making plugins. Right now i just made a simple death event: PHP: public function onDeath(PlayerDeathEvent $event) : void{ $event->setDeathMessage("§l§3" . $event->getPlayer()->getName() . " §8just died"); $level->setBlock(new Vector3($p->getX(), $p->getY()-1, $p->getZ()), Block::get(1));} In order for that block to be placed would'nt i need to do something like: PHP: use pocketmine\Blocks; Any help would be great!
The class you're looking for is this https://github.com/pmmp/PocketMine-MP/blob/stable/src/pocketmine/block/Block.php call will be : use pocketmine\block\Block; also you can just call the block class, if we want Anvil to be spawned : new Anvil(); $level->setBlock($position, new Anvil(), false); the false at the end is to not update the blocks around it (causes less lags) with higher a call of the class : use pocketmine\block\Anvil;