Skip to content

PointedDripstone 5.46.0 ​

class · pocketmine\block\PointedDripstone · source

Extends Transparent

Pointed dripstone (also used for the sulfur spike, which has the same states).

A standing block (stalagmite) needs a full top face or a standing block of the same type below it; a hanging block (stalactite) needs a full bottom face or a hanging block of the same type above it. The thickness is recalculated from the neighbouring blocks like in vanilla, including merged tips.

Stalactites of pointed dripstone drip the water or lava source above the block they hang from into a cauldron up to 11 blocks below their tip (Java PointedDripstoneBlock.maybeTransferFluid()): on a random tick of the top block of the stalactite, water drips with a 17.6% chance and lava with 5.9%; the drop lands 50 ticks + 1 tick per block of fall later. Water adds a third of a cauldron (2 of the 6 Bedrock levels), lava fills it. Mud above the root block dries into clay instead. The dripping particles are drawn by the client from the block states.

Not implemented: falling stalactites, extra fall damage on stalagmites and growth. Blocks that lose their support break and drop instead of falling.

Constants ​

DRIP_BASE_DELAY_TICKS ​

php
public const DRIP_BASE_DELAY_TICKS = 50

FLUID_LAVA ​

php
public const FLUID_LAVA = 2

FLUID_NONE ​

php
public const FLUID_NONE = 0

FLUID_WATER ​

php
public const FLUID_WATER = 1

LAVA_TRANSFER_CHANCE ​

php
public const LAVA_TRANSFER_CHANCE = 0.05859375

MAX_DRIP_SEARCH_LENGTH ​

php
public const MAX_DRIP_SEARCH_LENGTH = 11

WATER_DRIP_FILL_AMOUNT ​

php
public const WATER_DRIP_FILL_AMOUNT = 2

Bedrock cauldron levels added by one drop of water (a third of the cauldron, like one Java level)

WATER_TRANSFER_CHANCE ​

php
public const WATER_TRANSFER_CHANCE = 0.17578125

Properties ​

$hanging protected ​

php
protected bool $hanging

$thickness protected ​

php
protected \pocketmine\block\utils\DripstoneThickness $thickness

Methods ​

canBePlacedAt() ​

php
public function canBePlacedAt(\pocketmine\block\Block $blockReplace, \pocketmine\math\Vector3 $clickVector, int $face, bool $isClickedBlock) : bool

canCauldronReceiveDrip() ​

php
public static function canCauldronReceiveDrip(\pocketmine\block\Block $block, int $fluid) : bool

Returns whether a drop of the fluid (FLUID_* constant) can go into the cauldron: an empty cauldron takes water and lava, a water cauldron which isn't full (nor dyed) takes water.

canDripThrough() ​

php
public static function canDripThrough(\pocketmine\block\Block $block) : bool

Returns whether a drop can fall through the block: air, or a non-solid block without fluid that leaves the central 4x4 pixel column free (Java canDripThrough()).

describeBlockOnlyState() protected ​

php
protected function describeBlockOnlyState(\pocketmine\data\runtime\RuntimeDataDescriber $w) : void

fillCauldron() ​

php
public static function fillCauldron(\pocketmine\block\Block $cauldron, int $fluid) : void

Adds a drop of the fluid to the cauldron: water adds a third of a cauldron, lava fills it.

findFillableCauldronBelow() ​

php
public static function findFillableCauldronBelow(\pocketmine\block\PointedDripstone $tip, int $fluid) : ?\pocketmine\block\Block

Returns the cauldron up to 11 blocks below the tip that a drop of the fluid falls into, or null.

findTip() ​

php
public function findTip() : ?\pocketmine\block\PointedDripstone

Returns the tip of the stalactite this block belongs to (not a merged tip), or null if none is found within 11 blocks.

getFluidAboveStalactite() ​

php
public function getFluidAboveStalactite() : array

Returns the fluid that drips from the stalactite this block belongs to (FLUID_* constant) and the block it comes from: a water or lava source (or waterlogged block) above the block the stalactite hangs from. Mud counts as water.

getSupportType() ​

php
public function getSupportType(int $facing) : \pocketmine\block\utils\SupportType

getThickness() ​

php
public function getThickness() : \pocketmine\block\utils\DripstoneThickness

isHanging() ​

php
public function isHanging() : bool

isStalactiteStart() ​

php
public function isStalactiteStart() : bool

Returns whether this is the top block of a stalactite.

maybeTransferFluid() ​

php
public function maybeTransferFluid(float $random) : bool

Java PointedDripstoneBlock.maybeTransferFluid(): lets a drop of the fluid above the stalactite fall towards a cauldron below its tip (it lands in PointedDripstone::onScheduledUpdate()), or dries mud into clay. Only the top block of a stalactite drips.

onNearbyBlockChange() ​

php
public function onNearbyBlockChange() : void

onRandomTick() ​

php
public function onRandomTick() : void

onScheduledUpdate() ​

php
public function onScheduledUpdate() : void

A drop let fall by PointedDripstone::maybeTransferFluid() lands: the cauldron below the tip is filled if the stalactite, the fluid and the cauldron are still there (Java fills from the cauldron's scheduled tick).

place() ​

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) : bool

recalculateCollisionBoxes() protected ​

php
protected function recalculateCollisionBoxes() : array

setHanging() ​

php
public function setHanging(bool $hanging) : self

setThickness() ​

php
public function setThickness(\pocketmine\block\utils\DripstoneThickness $thickness) : self

ticksRandomly() ​

php
public function ticksRandomly() : bool

VanillaMine is a fork of PocketMine-MP, maintained by Luxury Nodes. Not affiliated with the PMMP team or Mojang.