Implemented budding amethyst and amethyst clusters

This commit is contained in:
Dylan K. Taylor
2023-09-27 17:02:37 +01:00
parent 4f13e446a1
commit 56d7039086
11 changed files with 318 additions and 8 deletions

View File

@ -90,6 +90,20 @@ final class BlockStateWriter{
return $this;
}
/** @return $this */
public function writeBlockFace(int $value) : self{
$this->writeString(BlockStateNames::MC_BLOCK_FACE, match($value){
Facing::DOWN => StringValues::MC_BLOCK_FACE_DOWN,
Facing::UP => StringValues::MC_BLOCK_FACE_UP,
Facing::NORTH => StringValues::MC_BLOCK_FACE_NORTH,
Facing::SOUTH => StringValues::MC_BLOCK_FACE_SOUTH,
Facing::WEST => StringValues::MC_BLOCK_FACE_WEST,
Facing::EAST => StringValues::MC_BLOCK_FACE_EAST,
default => throw new BlockStateSerializeException("Invalid Facing $value")
});
return $this;
}
/**
* @param int[] $faces
* @phpstan-param array<int, int> $faces