public class PistonBlock extends FacingBlock
Block.NeighborGroup
AbstractBlock.AbstractBlockState, AbstractBlock.ContextPredicate, AbstractBlock.OffsetType, AbstractBlock.Settings, AbstractBlock.TypedContextPredicate<A>
Modifier and Type | Field and Description |
---|---|
static BooleanProperty |
EXTENDED |
protected static VoxelShape |
EXTENDED_DOWN_SHAPE |
protected static VoxelShape |
EXTENDED_EAST_SHAPE |
protected static VoxelShape |
EXTENDED_NORTH_SHAPE |
protected static VoxelShape |
EXTENDED_SOUTH_SHAPE |
protected static VoxelShape |
EXTENDED_UP_SHAPE |
protected static VoxelShape |
EXTENDED_WEST_SHAPE |
private boolean |
sticky |
FACING
LOGGER, STATE_IDS, stateManager
collidable, dynamicBounds, FACINGS, jumpVelocityMultiplier, lootTableId, material, randomTicks, resistance, settings, slipperiness, soundGroup, velocityMultiplier
Constructor and Description |
---|
PistonBlock(boolean sticky,
AbstractBlock.Settings settings) |
addStacksForDisplay, afterBreak, asBlock, asItem, buildTooltip, canMobSpawnInside, cannotConnect, createCuboidShape, dropExperience, dropStack, dropStacks, dropStacks, dropStacks, getBlastResistance, getBlockFromItem, getDefaultState, getDroppedStacks, getDroppedStacks, getJumpVelocityMultiplier, getName, getPickStack, getRawIdFromState, getSlipperiness, getSoundGroup, getStateFromRawId, getStateManager, getTranslationKey, getVelocityMultiplier, hasDynamicBounds, hasRandomTicks, hasTopRim, isFaceFullSquare, isIn, isShapeFullCube, isSideSolidFullSquare, isTranslucent, onBreak, onBroken, onDestroyedByExplosion, onEntityLand, onLandedUpon, onSteppedOn, postProcessState, pushEntitiesUpBeforeBlockChange, rainTick, randomDisplayTick, replaceBlock, setDefaultState, shouldDrawSide, shouldDropItemsOnExplosion, sideCoversSmallSquare, toString
calcBlockBreakingDelta, canBucketPlace, canPlaceAt, canReplace, createScreenHandlerFactory, emitsRedstonePower, getAmbientOcclusionLightLevel, getCollisionShape, getComparatorOutput, getCullingShape, getDefaultMaterialColor, getDroppedStacks, getFluidState, getLootTableId, getOffsetType, getOpacity, getPistonBehavior, getRayTraceShape, getRenderingSeed, getRenderType, getSidesShape, getStateForNeighborUpdate, getStrongRedstonePower, getVisualShape, getWeakRedstonePower, hasBlockEntity, hasComparatorOutput, isSideInvisible, onBlockBreakStart, onBlockRemoved, onEntityCollision, onProjectileHit, onStacksDropped, onUse, prepare, randomTick, scheduledTick
public static final BooleanProperty EXTENDED
protected static final VoxelShape EXTENDED_EAST_SHAPE
protected static final VoxelShape EXTENDED_WEST_SHAPE
protected static final VoxelShape EXTENDED_SOUTH_SHAPE
protected static final VoxelShape EXTENDED_NORTH_SHAPE
protected static final VoxelShape EXTENDED_UP_SHAPE
protected static final VoxelShape EXTENDED_DOWN_SHAPE
private final boolean sticky
public PistonBlock(boolean sticky, AbstractBlock.Settings settings)
public VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context)
getOutlineShape
in class AbstractBlock
public void onPlaced(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack)
public void neighborUpdate(BlockState state, World world, BlockPos pos, Block block, BlockPos fromPos, boolean notify)
neighborUpdate
in class AbstractBlock
public void onBlockAdded(BlockState state, World world, BlockPos pos, BlockState oldState, boolean notify)
onBlockAdded
in class AbstractBlock
public BlockState getPlacementState(ItemPlacementContext ctx)
getPlacementState
in class Block
private void tryMove(World world, BlockPos pos, BlockState state)
public boolean onBlockAction(BlockState state, World world, BlockPos pos, int channel, int value)
onBlockAction
in class AbstractBlock
public static boolean isMovable(BlockState state, World world, BlockPos pos, Direction motionDir, boolean canBreak, Direction pistonDir)
public BlockState rotate(BlockState state, BlockRotation rotation)
rotate
in class AbstractBlock
public BlockState mirror(BlockState state, BlockMirror mirror)
mirror
in class AbstractBlock
protected void appendProperties(StateManager.Builder<Block,BlockState> builder)
appendProperties
in class Block
public boolean hasSidedTransparency(BlockState state)
hasSidedTransparency
in class AbstractBlock
public boolean canPathfindThrough(BlockState state, BlockView world, BlockPos pos, NavigationType type)
canPathfindThrough
in class AbstractBlock