I am trying to create a sign tile (+ block placement). But the sign text doesn't seem to appear. I logged the sign texts and it reads the sign texts (doesn't return null). I also logged the world, looks like the sign tile isn't created at all. Here's the code: PHP: /** @var Position $position *//** @var Vector3 $vector */$chunk = $pos->getLevel()->getChunk($vector->x >> 4, $vector->z >> 4);/*** $block = [* Block::getId(),* Block::getDamage()* ];*/$pos->getLevel()->setBlock($vector, Block::get($block[0], $block[1]), true);/** @var string[] $data */$nbt = new CompoundTag("", [ "id" => new StringTag("id", Tile::SIGN), "x" => new IntTag("x", $vector->x), "y" => new IntTag("y", $vector->y), "z" => new IntTag("z", $vector->z), "Text1" => new StringTag("Text1", $data["Text1"]), "Text2" => new StringTag("Text2", $data["Text2"]), "Text3" => new StringTag("Text3", $data["Text3"]), "Text4" => new StringTag("Text4", $data["Text4"])]);Tile::createTile("Sign", $chunk, $nbt);
How about spawning it? PHP: /** @var Position $position *//** @var Vector3 $vector */$chunk = $pos->getLevel()->getChunk($vector->x >> 4, $vector->z >> 4);/*** $block = [* Block::getId(),* Block::getDamage()* ];*/$pos->getLevel()->setBlock($vector, Block::get($block[0], $block[1]), true);/** @var string[] $data */$nbt = new CompoundTag("", [ "id" => new StringTag("id", Tile::SIGN), "x" => new IntTag("x", $vector->x), "y" => new IntTag("y", $vector->y), "z" => new IntTag("z", $vector->z), "Text1" => new StringTag("Text1", $data["Text1"]), "Text2" => new StringTag("Text2", $data["Text2"]), "Text3" => new StringTag("Text3", $data["Text3"]), "Text4" => new StringTag("Text4", $data["Text4"])]);$tile = Tile::createTile(Tile::SIGN, $chunk, $nbt);$tile->spawnToAll();