Skip to content

PistonPushReaction 5.46.0 ​

enum · pocketmine\block\utils\PistonPushReaction · source

How a block reacts to being moved by a piston (Bedrock Edition rules).

Cases ​

BLOCK ​

php
case BLOCK

Stops the piston: nothing in the line moves.

BREAK ​

php
case BREAK

Destroyed (dropping its items) when pushed; not pulled.

NORMAL ​

php
case NORMAL

Pushed and pulled normally.

PUSH_ONLY ​

php
case PUSH_ONLY

Pushed, but never pulled (by a sticky piston or by slime/honey dragging it along).

Methods ​

defaultFor() ​

php
public static function defaultFor(\pocketmine\block\Block $block) : self

Default reaction of a block, used by Block::getPistonPushReaction().

Sources: Minecraft Wiki (Piston, Leaves, Shulker Box pages) and PowerNukkitX's Bedrock block definitions (canBePushed/canBePulled/breaksWhenMoved). Bedrock moves most blocks with a block entity (chests, furnaces, hoppers...) together with their data, unlike Java.

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