public class RedstoneWireBlock extends Block
Block.RenderSideCacheKey
AbstractBlock.AbstractBlockState, AbstractBlock.IExtendedPositionPredicate<A>, AbstractBlock.IPositionPredicate, AbstractBlock.OffsetType, AbstractBlock.Properties
ForgeRegistryEntry.UncheckedRegistryEntry<V extends IForgeRegistryEntry<V>>
Modifier and Type | Field and Description |
---|---|
private static Vector3f[] |
COLORS |
private BlockState |
crossState |
static EnumProperty<RedstoneSide> |
EAST |
static EnumProperty<RedstoneSide> |
NORTH |
static IntegerProperty |
POWER |
static java.util.Map<Direction,EnumProperty<RedstoneSide>> |
PROPERTY_BY_DIRECTION |
private static VoxelShape |
SHAPE_DOT |
private java.util.Map<BlockState,VoxelShape> |
SHAPES_CACHE |
private static java.util.Map<Direction,VoxelShape> |
SHAPES_FLOOR |
private static java.util.Map<Direction,VoxelShape> |
SHAPES_UP |
private boolean |
shouldSignal |
static EnumProperty<RedstoneSide> |
SOUTH |
static EnumProperty<RedstoneSide> |
WEST |
BLOCK_STATE_REGISTRY, LOGGER, RANDOM, stateDefinition
drops, dynamicShape, explosionResistance, friction, hasCollision, isRandomlyTicking, jumpFactor, material, properties, soundType, speedFactor, UPDATE_SHAPE_ORDER
delegate
Constructor and Description |
---|
RedstoneWireBlock(AbstractBlock.Properties p_i48344_1_) |
Modifier and Type | Method and Description |
---|---|
void |
animateTick(BlockState p_180655_1_,
World p_180655_2_,
BlockPos p_180655_3_,
java.util.Random p_180655_4_) |
private VoxelShape |
calculateShape(BlockState p_235554_1_) |
private int |
calculateTargetStrength(World p_235546_1_,
BlockPos p_235546_2_) |
protected static boolean |
canConnectTo(BlockState p_176343_0_,
IBlockReader world,
BlockPos pos,
Direction p_176343_1_) |
boolean |
canSurvive(BlockState p_196260_1_,
IWorldReader p_196260_2_,
BlockPos p_196260_3_) |
private boolean |
canSurviveOn(IBlockReader p_235552_1_,
BlockPos p_235552_2_,
BlockState p_235552_3_) |
private void |
checkCornerChangeAt(World p_176344_1_,
BlockPos p_176344_2_) |
protected void |
createBlockStateDefinition(StateContainer.Builder<Block,BlockState> p_206840_1_) |
static int |
getColorForPower(int p_235550_0_) |
private RedstoneSide |
getConnectingSide(IBlockReader p_208074_1_,
BlockPos p_208074_2_,
Direction p_208074_3_) |
private RedstoneSide |
getConnectingSide(IBlockReader p_235545_1_,
BlockPos p_235545_2_,
Direction p_235545_3_,
boolean p_235545_4_) |
private BlockState |
getConnectionState(IBlockReader p_235544_1_,
BlockState p_235544_2_,
BlockPos p_235544_3_) |
int |
getDirectSignal(BlockState p_176211_1_,
IBlockReader p_176211_2_,
BlockPos p_176211_3_,
Direction p_176211_4_) |
private BlockState |
getMissingConnections(IBlockReader p_235551_1_,
BlockState p_235551_2_,
BlockPos p_235551_3_) |
VoxelShape |
getShape(BlockState p_220053_1_,
IBlockReader p_220053_2_,
BlockPos p_220053_3_,
ISelectionContext p_220053_4_) |
int |
getSignal(BlockState p_180656_1_,
IBlockReader p_180656_2_,
BlockPos p_180656_3_,
Direction p_180656_4_) |
BlockState |
getStateForPlacement(BlockItemUseContext p_196258_1_) |
private int |
getWireSignal(BlockState p_235557_1_) |
private static boolean |
isCross(BlockState p_235555_0_) |
private static boolean |
isDot(BlockState p_235556_0_) |
boolean |
isSignalSource(BlockState p_149744_1_) |
BlockState |
mirror(BlockState p_185471_1_,
Mirror p_185471_2_) |
void |
neighborChanged(BlockState p_220069_1_,
World p_220069_2_,
BlockPos p_220069_3_,
Block p_220069_4_,
BlockPos p_220069_5_,
boolean p_220069_6_) |
void |
onPlace(BlockState p_220082_1_,
World p_220082_2_,
BlockPos p_220082_3_,
BlockState p_220082_4_,
boolean p_220082_5_) |
void |
onRemove(BlockState p_196243_1_,
World p_196243_2_,
BlockPos p_196243_3_,
BlockState p_196243_4_,
boolean p_196243_5_) |
BlockState |
rotate(BlockState p_185499_1_,
Rotation p_185499_2_) |
private void |
spawnParticlesAlongLine(World p_235549_1_,
java.util.Random p_235549_2_,
BlockPos p_235549_3_,
Vector3f p_235549_4_,
Direction p_235549_5_,
Direction p_235549_6_,
float p_235549_7_,
float p_235549_8_) |
void |
updateIndirectNeighbourShapes(BlockState p_196248_1_,
IWorld p_196248_2_,
BlockPos p_196248_3_,
int p_196248_4_,
int p_196248_5_) |
private void |
updateNeighborsOfNeighboringWires(World p_235553_1_,
BlockPos p_235553_2_) |
private void |
updatePowerStrength(World p_235547_1_,
BlockPos p_235547_2_,
BlockState p_235547_3_) |
BlockState |
updateShape(BlockState p_196271_1_,
Direction p_196271_2_,
BlockState p_196271_3_,
IWorld p_196271_4_,
BlockPos p_196271_5_,
BlockPos p_196271_6_) |
private void |
updatesOnShapeChange(World p_235548_1_,
BlockPos p_235548_2_,
BlockState p_235548_3_,
BlockState p_235548_4_) |
ActionResultType |
use(BlockState p_225533_1_,
World p_225533_2_,
BlockPos p_225533_3_,
PlayerEntity p_225533_4_,
Hand p_225533_5_,
BlockRayTraceResult p_225533_6_) |
appendHoverText, asBlock, asItem, box, byItem, canSupportCenter, canSupportRigidBlock, canSustainPlant, defaultBlockState, destroy, dropFromExplosion, dropResources, dropResources, dropResources, fallOn, fillItemCategory, getCloneItemStack, getDescriptionId, getDrops, getDrops, getExplosionResistance, getFriction, getHarvestLevel, getHarvestTool, getId, getJumpFactor, getName, getSoundType, getSpeedFactor, getStateDefinition, getTags, handleRain, hasDynamicShape, is, is, isExceptionForConnection, isFaceFull, isPossibleToRespawnInThis, isRandomlyTicking, isShapeFullBlock, playerDestroy, playerWillDestroy, popExperience, popResource, propagatesSkylightDown, pushEntitiesUp, registerDefaultState, setPlacedBy, shouldRenderFace, stateById, stepOn, toString, updateEntityAfterFallOn, updateFromNeighbourShapes, updateOrDestroy, updateOrDestroy, wasExploded
attack, canBeReplaced, canBeReplaced, defaultMaterialColor, entityInside, getAnalogOutputSignal, getBlockSupportShape, getCollisionShape, getDestroyProgress, getDrops, getFluidState, getInteractionShape, getLightBlock, getLootTable, getMenuProvider, getOcclusionShape, getOffsetType, getPistonPushReaction, getRenderShape, getSeed, getShadeBrightness, getVisualShape, hasAnalogOutputSignal, isAir, isEntityBlock, isPathfindable, onProjectileHit, randomTick, skipRendering, spawnAfterBreak, tick, triggerEvent, useShapeForLightOcclusion
getRegistryName, getRegistryType, setRegistryName, setRegistryName, setRegistryName
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addDestroyEffects, addHitEffects, addLandingEffects, addRunningEffects, canBeReplacedByLeaves, canBeReplacedByLogs, canConnectRedstone, canCreatureSpawn, canDropFromExplosion, canEntityDestroy, canHarvestBlock, canStickTo, catchFire, collisionExtendsVertically, createTileEntity, getAiPathNodeType, getBeaconColorMultiplier, getBedDirection, getBedSpawnPosition, getBlock, getEnchantPowerBonus, getExpDrop, getExplosionResistance, getFireSpreadSpeed, getFlammability, getFogColor, getLightValue, getPickBlock, getRespawnPosition, getSlipperiness, getSoundType, getStateAtViewpoint, getToolModifiedState, getWeakChanges, hasTileEntity, isAir, isBed, isBurning, isConduitFrame, isFertile, isFireSource, isFlammable, isLadder, isPortalFrame, isScaffolding, isSlimeBlock, isStickyBlock, isToolEffective, makesOpenTrapdoorAboveClimbable, observedNeighborChange, onBlockExploded, onNeighborChange, onPlantGrow, removedByPlayer, rotate, setBedOccupied, shouldCheckWeakPower, shouldDisplayFluidOverlay
public static final EnumProperty<RedstoneSide> NORTH
public static final EnumProperty<RedstoneSide> EAST
public static final EnumProperty<RedstoneSide> SOUTH
public static final EnumProperty<RedstoneSide> WEST
public static final IntegerProperty POWER
public static final java.util.Map<Direction,EnumProperty<RedstoneSide>> PROPERTY_BY_DIRECTION
private static final VoxelShape SHAPE_DOT
private static final java.util.Map<Direction,VoxelShape> SHAPES_FLOOR
private static final java.util.Map<Direction,VoxelShape> SHAPES_UP
private final java.util.Map<BlockState,VoxelShape> SHAPES_CACHE
private static final Vector3f[] COLORS
private final BlockState crossState
private boolean shouldSignal
public RedstoneWireBlock(AbstractBlock.Properties p_i48344_1_)
private VoxelShape calculateShape(BlockState p_235554_1_)
public VoxelShape getShape(BlockState p_220053_1_, IBlockReader p_220053_2_, BlockPos p_220053_3_, ISelectionContext p_220053_4_)
getShape
in class AbstractBlock
public BlockState getStateForPlacement(BlockItemUseContext p_196258_1_)
getStateForPlacement
in class Block
private BlockState getConnectionState(IBlockReader p_235544_1_, BlockState p_235544_2_, BlockPos p_235544_3_)
private BlockState getMissingConnections(IBlockReader p_235551_1_, BlockState p_235551_2_, BlockPos p_235551_3_)
public BlockState updateShape(BlockState p_196271_1_, Direction p_196271_2_, BlockState p_196271_3_, IWorld p_196271_4_, BlockPos p_196271_5_, BlockPos p_196271_6_)
updateShape
in class AbstractBlock
private static boolean isCross(BlockState p_235555_0_)
private static boolean isDot(BlockState p_235556_0_)
public void updateIndirectNeighbourShapes(BlockState p_196248_1_, IWorld p_196248_2_, BlockPos p_196248_3_, int p_196248_4_, int p_196248_5_)
updateIndirectNeighbourShapes
in class AbstractBlock
private RedstoneSide getConnectingSide(IBlockReader p_208074_1_, BlockPos p_208074_2_, Direction p_208074_3_)
private RedstoneSide getConnectingSide(IBlockReader p_235545_1_, BlockPos p_235545_2_, Direction p_235545_3_, boolean p_235545_4_)
public boolean canSurvive(BlockState p_196260_1_, IWorldReader p_196260_2_, BlockPos p_196260_3_)
canSurvive
in class AbstractBlock
private boolean canSurviveOn(IBlockReader p_235552_1_, BlockPos p_235552_2_, BlockState p_235552_3_)
private void updatePowerStrength(World p_235547_1_, BlockPos p_235547_2_, BlockState p_235547_3_)
private int calculateTargetStrength(World p_235546_1_, BlockPos p_235546_2_)
private int getWireSignal(BlockState p_235557_1_)
public void onPlace(BlockState p_220082_1_, World p_220082_2_, BlockPos p_220082_3_, BlockState p_220082_4_, boolean p_220082_5_)
onPlace
in class AbstractBlock
public void onRemove(BlockState p_196243_1_, World p_196243_2_, BlockPos p_196243_3_, BlockState p_196243_4_, boolean p_196243_5_)
onRemove
in class AbstractBlock
private void updateNeighborsOfNeighboringWires(World p_235553_1_, BlockPos p_235553_2_)
public void neighborChanged(BlockState p_220069_1_, World p_220069_2_, BlockPos p_220069_3_, Block p_220069_4_, BlockPos p_220069_5_, boolean p_220069_6_)
neighborChanged
in class AbstractBlock
public int getDirectSignal(BlockState p_176211_1_, IBlockReader p_176211_2_, BlockPos p_176211_3_, Direction p_176211_4_)
getDirectSignal
in class AbstractBlock
public int getSignal(BlockState p_180656_1_, IBlockReader p_180656_2_, BlockPos p_180656_3_, Direction p_180656_4_)
getSignal
in class AbstractBlock
protected static boolean canConnectTo(BlockState p_176343_0_, IBlockReader world, BlockPos pos, @Nullable Direction p_176343_1_)
public boolean isSignalSource(BlockState p_149744_1_)
isSignalSource
in class AbstractBlock
public static int getColorForPower(int p_235550_0_)
private void spawnParticlesAlongLine(World p_235549_1_, java.util.Random p_235549_2_, BlockPos p_235549_3_, Vector3f p_235549_4_, Direction p_235549_5_, Direction p_235549_6_, float p_235549_7_, float p_235549_8_)
public void animateTick(BlockState p_180655_1_, World p_180655_2_, BlockPos p_180655_3_, java.util.Random p_180655_4_)
animateTick
in class Block
public BlockState rotate(BlockState p_185499_1_, Rotation p_185499_2_)
rotate
in class AbstractBlock
public BlockState mirror(BlockState p_185471_1_, Mirror p_185471_2_)
mirror
in class AbstractBlock
protected void createBlockStateDefinition(StateContainer.Builder<Block,BlockState> p_206840_1_)
createBlockStateDefinition
in class Block
public ActionResultType use(BlockState p_225533_1_, World p_225533_2_, BlockPos p_225533_3_, PlayerEntity p_225533_4_, Hand p_225533_5_, BlockRayTraceResult p_225533_6_)
use
in class AbstractBlock
private void updatesOnShapeChange(World p_235548_1_, BlockPos p_235548_2_, BlockState p_235548_3_, BlockState p_235548_4_)