public class LeavesBlock extends Block
Block.NeighborGroupAbstractBlock.AbstractBlockState, AbstractBlock.ContextPredicate, AbstractBlock.OffsetType, AbstractBlock.Settings, AbstractBlock.TypedContextPredicate<A>| Modifier and Type | Field and Description |
|---|---|
static IntProperty |
DISTANCE |
static BooleanProperty |
PERSISTENT |
LOGGER, STATE_IDS, stateManagercollidable, dynamicBounds, FACINGS, jumpVelocityMultiplier, lootTableId, material, randomTicks, resistance, settings, slipperiness, soundGroup, velocityMultiplier| Constructor and Description |
|---|
LeavesBlock(AbstractBlock.Settings settings) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
appendProperties(StateManager.Builder<Block,BlockState> builder) |
private static int |
getDistanceFromLog(BlockState state) |
int |
getOpacity(BlockState state,
BlockView world,
BlockPos pos) |
BlockState |
getPlacementState(ItemPlacementContext ctx) |
VoxelShape |
getSidesShape(BlockState state,
BlockView world,
BlockPos pos) |
BlockState |
getStateForNeighborUpdate(BlockState state,
Direction direction,
BlockState newState,
WorldAccess world,
BlockPos pos,
BlockPos posFrom) |
boolean |
hasRandomTicks(BlockState state) |
void |
randomDisplayTick(BlockState state,
World world,
BlockPos pos,
Random random) |
void |
randomTick(BlockState state,
ServerWorld world,
BlockPos pos,
Random random) |
void |
scheduledTick(BlockState state,
ServerWorld world,
BlockPos pos,
Random random) |
private static BlockState |
updateDistanceFromLogs(BlockState state,
WorldAccess world,
BlockPos pos) |
addStacksForDisplay, afterBreak, appendTooltip, asBlock, asItem, canMobSpawnInside, cannotConnect, createCuboidShape, dropExperience, dropStack, dropStacks, dropStacks, dropStacks, getBlastResistance, getBlockFromItem, getDefaultState, getDroppedStacks, getDroppedStacks, getJumpVelocityMultiplier, getName, getPickStack, getRawIdFromState, getSlipperiness, getSoundGroup, getStateFromRawId, getStateManager, getTranslationKey, getVelocityMultiplier, hasDynamicBounds, hasTopRim, is, isFaceFullSquare, isIn, isShapeFullCube, isTranslucent, onBreak, onBroken, onDestroyedByExplosion, onEntityLand, onLandedUpon, onPlaced, onSteppedOn, postProcessState, pushEntitiesUpBeforeBlockChange, rainTick, replace, replace, setDefaultState, shouldDrawSide, shouldDropItemsOnExplosion, sideCoversSmallSquare, toStringcalcBlockBreakingDelta, canBucketPlace, canPathfindThrough, canPlaceAt, canReplace, createScreenHandlerFactory, emitsRedstonePower, getAmbientOcclusionLightLevel, getCollisionShape, getComparatorOutput, getCullingShape, getDefaultMaterialColor, getDroppedStacks, getFluidState, getLootTableId, getOffsetType, getOutlineShape, getPistonBehavior, getRaycastShape, getRenderingSeed, getRenderType, getStrongRedstonePower, getVisualShape, getWeakRedstonePower, hasBlockEntity, hasComparatorOutput, hasSidedTransparency, isSideInvisible, mirror, neighborUpdate, onBlockAdded, onBlockBreakStart, onEntityCollision, onProjectileHit, onStacksDropped, onStateReplaced, onSyncedBlockEvent, onUse, prepare, rotatepublic static final IntProperty DISTANCE
public static final BooleanProperty PERSISTENT
public LeavesBlock(AbstractBlock.Settings settings)
public VoxelShape getSidesShape(BlockState state, BlockView world, BlockPos pos)
getSidesShape in class AbstractBlockpublic boolean hasRandomTicks(BlockState state)
hasRandomTicks in class Blockpublic void randomTick(BlockState state, ServerWorld world, BlockPos pos, Random random)
randomTick in class AbstractBlockpublic void scheduledTick(BlockState state, ServerWorld world, BlockPos pos, Random random)
scheduledTick in class AbstractBlockpublic int getOpacity(BlockState state, BlockView world, BlockPos pos)
getOpacity in class AbstractBlockpublic BlockState getStateForNeighborUpdate(BlockState state, Direction direction, BlockState newState, WorldAccess world, BlockPos pos, BlockPos posFrom)
getStateForNeighborUpdate in class AbstractBlockprivate static BlockState updateDistanceFromLogs(BlockState state, WorldAccess world, BlockPos pos)
private static int getDistanceFromLog(BlockState state)
@Environment(value=CLIENT) public void randomDisplayTick(BlockState state, World world, BlockPos pos, Random random)
randomDisplayTick in class Blockprotected void appendProperties(StateManager.Builder<Block,BlockState> builder)
appendProperties in class Blockpublic BlockState getPlacementState(ItemPlacementContext ctx)
getPlacementState in class Block