Class FlowerPotBlockEntityTranslator
java.lang.Object
org.geysermc.geyser.translator.level.block.entity.FlowerPotBlockEntityTranslator
- All Implemented Interfaces:
BedrockOnlyBlockEntity,RequiresBlockState
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic com.nukkitx.nbt.NbtMapgetTag(GeyserSession session, int blockState, com.nukkitx.math.vector.Vector3i position)Get the Nukkit CompoundTag of the flower pot.booleanisBlock(int blockState)Determines if block is part of classstatic booleanisFlowerBlock(int blockState)voidupdateBlock(GeyserSession session, int blockState, com.nukkitx.math.vector.Vector3i position)Update the block on Bedrock Edition.
-
Constructor Details
-
FlowerPotBlockEntityTranslator
public FlowerPotBlockEntityTranslator()
-
-
Method Details
-
isFlowerBlock
public static boolean isFlowerBlock(int blockState)- Parameters:
blockState- the Java block state of a potential flower pot block- Returns:
- true if the block is a flower pot
-
getTag
public static com.nukkitx.nbt.NbtMap getTag(GeyserSession session, int blockState, com.nukkitx.math.vector.Vector3i position)Get the Nukkit CompoundTag of the flower pot.- Parameters:
blockState- Java block state of flower pot.position- Bedrock position of flower pot.- Returns:
- Bedrock tag of flower pot.
-
isBlock
public boolean isBlock(int blockState)Description copied from interface:BedrockOnlyBlockEntityDetermines if block is part of class- Specified by:
isBlockin interfaceBedrockOnlyBlockEntity- Parameters:
blockState- BlockState to be compared- Returns:
- true if part of the class
-
updateBlock
public void updateBlock(GeyserSession session, int blockState, com.nukkitx.math.vector.Vector3i position)Description copied from interface:BedrockOnlyBlockEntityUpdate the block on Bedrock Edition.- Specified by:
updateBlockin interfaceBedrockOnlyBlockEntity- Parameters:
session- GeyserConnection.blockState- The Java block state.position- The Bedrock block position.
-