public class FenceGateBlock extends HorizontalFacingBlock
Block.NeighborGroupAbstractBlock.AbstractBlockState, AbstractBlock.ContextPredicate, AbstractBlock.OffsetType, AbstractBlock.Settings, AbstractBlock.TypedContextPredicate<A>| Modifier and Type | Field and Description |
|---|---|
static BooleanProperty |
IN_WALL |
protected static VoxelShape |
IN_WALL_X_AXIS_CULL_SHAPE |
protected static VoxelShape |
IN_WALL_X_AXIS_SHAPE |
protected static VoxelShape |
IN_WALL_Z_AXIS_CULL_SHAPE |
protected static VoxelShape |
IN_WALL_Z_AXIS_SHAPE |
static BooleanProperty |
OPEN |
static BooleanProperty |
POWERED |
protected static VoxelShape |
X_AXIS_COLLISION_SHAPE |
protected static VoxelShape |
X_AXIS_CULL_SHAPE |
protected static VoxelShape |
X_AXIS_SHAPE |
protected static VoxelShape |
Z_AXIS_COLLISION_SHAPE |
protected static VoxelShape |
Z_AXIS_CULL_SHAPE |
protected static VoxelShape |
Z_AXIS_SHAPE |
FACINGLOGGER, STATE_IDS, stateManagercollidable, dynamicBounds, FACINGS, jumpVelocityMultiplier, lootTableId, material, randomTicks, resistance, settings, slipperiness, soundGroup, velocityMultiplier| Constructor and Description |
|---|
FenceGateBlock(AbstractBlock.Settings settings) |
mirror, rotateaddStacksForDisplay, 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, hasRandomTicks, hasTopRim, is, isFaceFullSquare, isIn, isShapeFullCube, isTranslucent, onBreak, onBroken, onDestroyedByExplosion, onEntityLand, onLandedUpon, onPlaced, onSteppedOn, postProcessState, pushEntitiesUpBeforeBlockChange, rainTick, randomDisplayTick, replace, replace, setDefaultState, shouldDrawSide, shouldDropItemsOnExplosion, sideCoversSmallSquare, toStringcalcBlockBreakingDelta, canBucketPlace, canPlaceAt, canReplace, createScreenHandlerFactory, emitsRedstonePower, getAmbientOcclusionLightLevel, getComparatorOutput, getDefaultMaterialColor, getDroppedStacks, getFluidState, getLootTableId, getOffsetType, getOpacity, getPistonBehavior, getRaycastShape, getRenderingSeed, getRenderType, getSidesShape, getStrongRedstonePower, getVisualShape, getWeakRedstonePower, hasBlockEntity, hasComparatorOutput, hasSidedTransparency, isSideInvisible, onBlockAdded, onBlockBreakStart, onEntityCollision, onProjectileHit, onStacksDropped, onStateReplaced, onSyncedBlockEvent, prepare, randomTick, scheduledTickpublic static final BooleanProperty OPEN
public static final BooleanProperty POWERED
public static final BooleanProperty IN_WALL
protected static final VoxelShape Z_AXIS_SHAPE
protected static final VoxelShape X_AXIS_SHAPE
protected static final VoxelShape IN_WALL_Z_AXIS_SHAPE
protected static final VoxelShape IN_WALL_X_AXIS_SHAPE
protected static final VoxelShape Z_AXIS_COLLISION_SHAPE
protected static final VoxelShape X_AXIS_COLLISION_SHAPE
protected static final VoxelShape Z_AXIS_CULL_SHAPE
protected static final VoxelShape X_AXIS_CULL_SHAPE
protected static final VoxelShape IN_WALL_Z_AXIS_CULL_SHAPE
protected static final VoxelShape IN_WALL_X_AXIS_CULL_SHAPE
public FenceGateBlock(AbstractBlock.Settings settings)
public VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context)
getOutlineShape in class AbstractBlockpublic BlockState getStateForNeighborUpdate(BlockState state, Direction direction, BlockState newState, WorldAccess world, BlockPos pos, BlockPos posFrom)
getStateForNeighborUpdate in class AbstractBlockpublic VoxelShape getCollisionShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context)
getCollisionShape in class AbstractBlockpublic VoxelShape getCullingShape(BlockState state, BlockView world, BlockPos pos)
getCullingShape in class AbstractBlockpublic boolean canPathfindThrough(BlockState state, BlockView world, BlockPos pos, NavigationType type)
canPathfindThrough in class AbstractBlockpublic BlockState getPlacementState(ItemPlacementContext ctx)
getPlacementState in class Blockprivate boolean isWall(BlockState state)
public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit)
This method is called on both the logical client and logical server, so take caution when overriding this method.
The logical side can be checked using world.isClient().
If the action result is successful on a logical client, then the action will be sent to the logical server for processing.
onUse in class AbstractBlockpublic void neighborUpdate(BlockState state, World world, BlockPos pos, Block block, BlockPos fromPos, boolean notify)
neighborUpdate in class AbstractBlockprotected void appendProperties(StateManager.Builder<Block,BlockState> builder)
appendProperties in class Blockpublic static boolean canWallConnect(BlockState state, Direction side)