public class BlockRedstoneWire extends Block
| Modifier and Type | Class and Description |
|---|---|
(package private) static class |
BlockRedstoneWire.EnumAttachPosition |
Block.EnumOffsetType, Block.SoundType| Modifier and Type | Field and Description |
|---|---|
private java.util.Set<BlockPos> |
blocksNeedingUpdate |
private boolean |
canProvidePower |
static PropertyEnum<BlockRedstoneWire.EnumAttachPosition> |
EAST |
static PropertyEnum<BlockRedstoneWire.EnumAttachPosition> |
NORTH |
static PropertyInteger |
POWER |
static PropertyEnum<BlockRedstoneWire.EnumAttachPosition> |
SOUTH |
static PropertyEnum<BlockRedstoneWire.EnumAttachPosition> |
WEST |
BLOCK_STATE_IDS, blockHardness, blockMaterial, blockParticleGravity, blockRegistry, blockResistance, blockState, enableStats, field_181083_K, fullBlock, isBlockContainer, lightOpacity, lightValue, maxX, maxY, maxZ, minX, minY, minZ, needsRandomTick, SLIME_SOUND, slipperiness, soundTypeAnvil, soundTypeCloth, soundTypeGlass, soundTypeGrass, soundTypeGravel, soundTypeLadder, soundTypeMetal, soundTypePiston, soundTypeSand, soundTypeSnow, soundTypeStone, soundTypeWood, stepSound, translucent, useNeighborBrightness| Constructor and Description |
|---|
BlockRedstoneWire() |
| Modifier and Type | Method and Description |
|---|---|
void |
breakBlock(World worldIn,
BlockPos pos,
IBlockState state) |
private IBlockState |
calculateCurrentChanges(World worldIn,
BlockPos pos1,
BlockPos pos2,
IBlockState state) |
protected static boolean |
canConnectTo(IBlockState blockState,
EnumFacing side) |
protected static boolean |
canConnectUpwardsTo(IBlockAccess worldIn,
BlockPos pos) |
protected static boolean |
canConnectUpwardsTo(IBlockState state) |
boolean |
canPlaceBlockAt(World worldIn,
BlockPos pos) |
boolean |
canProvidePower()
Can this block provide power.
|
int |
colorMultiplier(IBlockAccess worldIn,
BlockPos pos,
int renderPass) |
private int |
colorMultiplier(int powerLevel) |
protected BlockState |
createBlockState() |
private boolean |
func_176339_d(IBlockAccess worldIn,
BlockPos pos,
EnumFacing side) |
IBlockState |
getActualState(IBlockState state,
IBlockAccess worldIn,
BlockPos pos)
Get the actual Block state of this Block at the given position.
|
private BlockRedstoneWire.EnumAttachPosition |
getAttachPosition(IBlockAccess worldIn,
BlockPos pos,
EnumFacing direction) |
EnumWorldBlockLayer |
getBlockLayer() |
AxisAlignedBB |
getCollisionBoundingBox(World worldIn,
BlockPos pos,
IBlockState state) |
Item |
getItem(World worldIn,
BlockPos pos) |
Item |
getItemDropped(IBlockState state,
java.util.Random rand,
int fortune)
Get the Item that this Block should drop when harvested.
|
private int |
getMaxCurrentStrength(World worldIn,
BlockPos pos,
int strength) |
int |
getMetaFromState(IBlockState state)
Convert the BlockState into the correct metadata value
|
IBlockState |
getStateFromMeta(int meta)
Convert the given metadata into a BlockState for this Block
|
int |
getStrongPower(IBlockAccess worldIn,
BlockPos pos,
IBlockState state,
EnumFacing side) |
int |
getWeakPower(IBlockAccess worldIn,
BlockPos pos,
IBlockState state,
EnumFacing side) |
boolean |
isFullCube() |
boolean |
isOpaqueCube()
Used to determine ambient occlusion and culling when rebuilding chunks for render
|
private void |
notifyWireNeighborsOfStateChange(World worldIn,
BlockPos pos)
Calls World.notifyNeighborsOfStateChange() for all neighboring blocks, but only if the given block is a redstone
wire.
|
void |
onBlockAdded(World worldIn,
BlockPos pos,
IBlockState state) |
void |
onNeighborBlockChange(World worldIn,
BlockPos pos,
IBlockState state,
Block neighborBlock)
Called when a neighboring block changes.
|
void |
randomDisplayTick(World worldIn,
BlockPos pos,
IBlockState state,
java.util.Random rand) |
private IBlockState |
updateSurroundingRedstone(World worldIn,
BlockPos pos,
IBlockState state) |
addCollisionBoxesToList, canCollideCheck, canDropFromExplosion, canPlaceBlockOnSide, canReplace, canSilkHarvest, collisionRayTrace, colorMultiplier, createStackedBlock, damageDropped, disableStats, dropBlockAsItem, dropBlockAsItemWithChance, dropXpOnBlockBreak, fillWithRain, func_181623_g, getAmbientOcclusionLightValue, getBlockBoundsMaxX, getBlockBoundsMaxY, getBlockBoundsMaxZ, getBlockBoundsMinX, getBlockBoundsMinY, getBlockBoundsMinZ, getBlockById, getBlockColor, getBlockFromItem, getBlockFromName, getBlockHardness, getBlockState, getComparatorInputOverride, getCreativeTabToDisplayOn, getDamageValue, getDefaultState, getEnableStats, getExplosionResistance, getIdFromBlock, getLightOpacity, getLightValue, getLocalizedName, getMapColor, getMaterial, getMixedBrightnessForBlock, getMobilityFlag, getOffsetType, getPlayerRelativeBlockHardness, getRenderColor, getRenderType, getSelectedBoundingBox, getStateById, getStateForEntityRender, getStateId, getSubBlocks, getTickRandomly, getUnlocalizedName, getUseNeighborBrightness, harvestBlock, hasComparatorInputOverride, hasTileEntity, isAssociatedBlock, isBlockNormalCube, isBlockSolid, isCollidable, isEqualTo, isFlowerPot, isFullBlock, isNormalCube, isPassable, isReplaceable, isTranslucent, isVisuallyOpaque, modifyAcceleration, onBlockActivated, onBlockClicked, onBlockDestroyedByExplosion, onBlockDestroyedByPlayer, onBlockEventReceived, onBlockHarvested, onBlockPlaced, onBlockPlacedBy, onEntityCollidedWithBlock, onEntityCollidedWithBlock, onFallenUpon, onLanded, quantityDropped, quantityDroppedWithBonus, randomTick, registerBlocks, requiresUpdates, setBlockBounds, setBlockBoundsBasedOnState, setBlockBoundsForItemRender, setBlockUnbreakable, setCreativeTab, setDefaultState, setHardness, setLightLevel, setLightOpacity, setResistance, setStepSound, setTickRandomly, setUnlocalizedName, shouldSideBeRendered, spawnAsEntity, tickRate, toString, updateTickpublic static final PropertyEnum<BlockRedstoneWire.EnumAttachPosition> NORTH
public static final PropertyEnum<BlockRedstoneWire.EnumAttachPosition> EAST
public static final PropertyEnum<BlockRedstoneWire.EnumAttachPosition> SOUTH
public static final PropertyEnum<BlockRedstoneWire.EnumAttachPosition> WEST
public static final PropertyInteger POWER
private boolean canProvidePower
private final java.util.Set<BlockPos> blocksNeedingUpdate
public IBlockState getActualState(IBlockState state, IBlockAccess worldIn, BlockPos pos)
getActualState in class Blockprivate BlockRedstoneWire.EnumAttachPosition getAttachPosition(IBlockAccess worldIn, BlockPos pos, EnumFacing direction)
public AxisAlignedBB getCollisionBoundingBox(World worldIn, BlockPos pos, IBlockState state)
getCollisionBoundingBox in class Blockpublic boolean isOpaqueCube()
isOpaqueCube in class Blockpublic boolean isFullCube()
isFullCube in class Blockpublic int colorMultiplier(IBlockAccess worldIn, BlockPos pos, int renderPass)
colorMultiplier in class Blockpublic boolean canPlaceBlockAt(World worldIn, BlockPos pos)
canPlaceBlockAt in class Blockprivate IBlockState updateSurroundingRedstone(World worldIn, BlockPos pos, IBlockState state)
private IBlockState calculateCurrentChanges(World worldIn, BlockPos pos1, BlockPos pos2, IBlockState state)
private void notifyWireNeighborsOfStateChange(World worldIn, BlockPos pos)
public void onBlockAdded(World worldIn, BlockPos pos, IBlockState state)
onBlockAdded in class Blockpublic void breakBlock(World worldIn, BlockPos pos, IBlockState state)
breakBlock in class Blockpublic void onNeighborBlockChange(World worldIn, BlockPos pos, IBlockState state, Block neighborBlock)
onNeighborBlockChange in class Blockpublic Item getItemDropped(IBlockState state, java.util.Random rand, int fortune)
getItemDropped in class Blockpublic int getStrongPower(IBlockAccess worldIn, BlockPos pos, IBlockState state, EnumFacing side)
getStrongPower in class Blockpublic int getWeakPower(IBlockAccess worldIn, BlockPos pos, IBlockState state, EnumFacing side)
getWeakPower in class Blockprivate boolean func_176339_d(IBlockAccess worldIn, BlockPos pos, EnumFacing side)
protected static boolean canConnectUpwardsTo(IBlockAccess worldIn, BlockPos pos)
protected static boolean canConnectUpwardsTo(IBlockState state)
protected static boolean canConnectTo(IBlockState blockState, EnumFacing side)
public boolean canProvidePower()
canProvidePower in class Blockprivate int colorMultiplier(int powerLevel)
public void randomDisplayTick(World worldIn, BlockPos pos, IBlockState state, java.util.Random rand)
randomDisplayTick in class Blockpublic EnumWorldBlockLayer getBlockLayer()
getBlockLayer in class Blockpublic IBlockState getStateFromMeta(int meta)
getStateFromMeta in class Blockpublic int getMetaFromState(IBlockState state)
getMetaFromState in class Blockprotected BlockState createBlockState()
createBlockState in class Block