Jigsaw 5.47.0
Extends Opaque
Implements AnyFacing
Jigsaw block (https://minecraft.wiki/w/Jigsaw_Block). Holds the connection data of a structure piece in its block entity (TileJigsaw); the vanilla generator reads that data from the templates, so in the world it is only a data holder that operators in creative mode can edit. The front faces away from the clicked block; the rotation (0-3) turns the block around its front: for a front facing up or down it is the direction of the top (Jigsaw::TOP_DIRECTIONS). Never drops.
Constants
MAX_ROTATION
php
public const MAX_ROTATION = 3TOP_DIRECTIONS
php
public const TOP_DIRECTIONS = [\pocketmine\math\Facing::NORTH, \pocketmine\math\Facing::EAST, \pocketmine\math\Facing::SOUTH, \pocketmine\math\Facing::WEST]Direction of the top of a jigsaw facing up or down, by rotation
Properties
$rotation protected
php
protected int $rotationMethods
describeBlockOnlyState() protected
php
protected function describeBlockOnlyState(\pocketmine\data\runtime\RuntimeDataDescriber $w) : voidgetDropsForCompatibleTool()
php
public function getDropsForCompatibleTool(\pocketmine\item\Item $item) : arraygetRotation()
php
public function getRotation() : intisAffectedBySilkTouch()
php
public function isAffectedBySilkTouch() : boolonInteract()
php
public function onInteract(\pocketmine\item\Item $item, int $face, \pocketmine\math\Vector3 $clickVector, ?\pocketmine\player\Player $player = null, array &$returnedItems = []) : boolplace()
php
public function place(\pocketmine\world\BlockTransaction $tx, \pocketmine\item\Item $item, \pocketmine\block\Block $blockReplace, \pocketmine\block\Block $blockClicked, int $face, \pocketmine\math\Vector3 $clickVector, ?\pocketmine\player\Player $player = null) : boolsetRotation()
php
public function setRotation(int $rotation) : self