public class BlockRedstoneComparator extends BlockRedstoneDiode implements ITileEntityProvider
| Modifier and Type | Class and Description |
|---|---|
static class |
BlockRedstoneComparator.Mode |
Block.EnumOffsetTypeIForgeRegistryEntry.Impl<T extends IForgeRegistryEntry<T>>| Modifier and Type | Field and Description |
|---|---|
static PropertyEnum<BlockRedstoneComparator.Mode> |
MODE |
static PropertyBool |
POWERED |
isRepeaterPowered, REDSTONE_DIODE_AABBFACINGBLOCK_STATE_IDS, blockHardness, blockMapColor, blockMaterial, blockParticleGravity, blockResistance, blockSoundType, blockState, capturedDrops, captureDrops, enableStats, FULL_BLOCK_AABB, fullBlock, harvesters, hasTileEntity, lightOpacity, lightValue, needsRandomTick, NULL_AABB, RANDOM, REGISTRY, slipperiness, translucent, useNeighborBrightnessdelegate| Constructor and Description |
|---|
BlockRedstoneComparator(boolean powered) |
| Modifier and Type | Method and Description |
|---|---|
void |
breakBlock(World worldIn,
BlockPos pos,
IBlockState state)
Called serverside after this block is replaced with another in Chunk, but before the Tile Entity is updated
|
protected int |
calculateInputStrength(World worldIn,
BlockPos pos,
IBlockState state) |
protected BlockStateContainer |
createBlockState() |
TileEntity |
createNewTileEntity(World worldIn,
int meta)
Returns a new instance of a block's tile entity class.
|
boolean |
eventReceived(IBlockState state,
World worldIn,
BlockPos pos,
int id,
int param)
Called on server when World#addBlockEvent is called.
|
protected int |
getActiveSignal(IBlockAccess worldIn,
BlockPos pos,
IBlockState state) |
protected int |
getDelay(IBlockState state) |
ItemStack |
getItem(World worldIn,
BlockPos pos,
IBlockState state) |
Item |
getItemDropped(IBlockState state,
java.util.Random rand,
int fortune)
Get the Item that this Block should drop when harvested.
|
java.lang.String |
getLocalizedName()
Gets the localized name of this block.
|
int |
getMetaFromState(IBlockState state)
Convert the BlockState into the correct metadata value
|
protected IBlockState |
getPoweredState(IBlockState unpoweredState) |
IBlockState |
getStateForPlacement(World worldIn,
BlockPos pos,
EnumFacing facing,
float hitX,
float hitY,
float hitZ,
int meta,
EntityLivingBase placer)
Called by ItemBlocks just before a block is actually set in the world, to allow for adjustments to the
IBlockstate
|
IBlockState |
getStateFromMeta(int meta)
Convert the given metadata into a BlockState for this Block
|
protected IBlockState |
getUnpoweredState(IBlockState poweredState) |
boolean |
getWeakChanges(IBlockAccess world,
BlockPos pos)
If this block should be notified of weak changes.
|
protected boolean |
isPowered(IBlockState state) |
boolean |
onBlockActivated(World worldIn,
BlockPos pos,
IBlockState state,
EntityPlayer playerIn,
EnumHand hand,
EnumFacing facing,
float hitX,
float hitY,
float hitZ)
Called when the block is right clicked by a player.
|
void |
onBlockAdded(World worldIn,
BlockPos pos,
IBlockState state)
Called after the block is set in the Chunk data, but before the Tile Entity is set
|
void |
onNeighborChange(IBlockAccess world,
BlockPos pos,
BlockPos neighbor)
Called when a tile entity on a side of this block changes is created or is destroyed.
|
protected boolean |
shouldBePowered(World worldIn,
BlockPos pos,
IBlockState state) |
protected void |
updateState(World worldIn,
BlockPos pos,
IBlockState state) |
void |
updateTick(World worldIn,
BlockPos pos,
IBlockState state,
java.util.Random rand) |
IBlockState |
withMirror(IBlockState state,
Mirror mirrorIn)
Returns the blockstate with the given mirror of the passed blockstate.
|
IBlockState |
withRotation(IBlockState state,
Rotation rot)
Returns the blockstate with the given rotation from the passed blockstate.
|
canBlockStay, canPlaceBlockAt, canProvidePower, getBlockFaceShape, getBlockLayer, getBoundingBox, getPowerOnSide, getPowerOnSides, getStrongPower, getTickDelay, getWeakPower, isAlternateInput, isAssociatedBlock, isDiode, isFacingTowardsRepeater, isFullCube, isLocked, isOpaqueCube, isSameDiode, neighborChanged, notifyNeighbors, onBlockDestroyedByPlayer, onBlockPlacedBy, randomTick, rotateBlock, shouldSideBeRenderedaddCollisionBoxToList, addCollisionBoxToList, addDestroyEffects, addHitEffects, addInformation, addLandingEffects, addRunningEffects, beginLeavesDecay, canBeConnectedTo, canBeReplacedByLeaves, canCollideCheck, canConnectRedstone, canCreatureSpawn, canDropFromExplosion, canEntityDestroy, canEntitySpawn, canHarvestBlock, canPlaceBlockOnSide, canPlaceTorchOnTop, canRenderInLayer, canSilkHarvest, canSilkHarvest, canSpawnInBlock, canSustainLeaves, canSustainPlant, captureDrops, causesSuffocation, collisionRayTrace, createTileEntity, damageDropped, disableStats, doesSideBlockChestOpening, doesSideBlockRendering, dropBlockAsItem, dropBlockAsItemWithChance, dropXpOnBlockBreak, fillWithRain, getActualState, getAiPathNodeType, getAiPathNodeType, getAmbientOcclusionLightValue, getBeaconColorMultiplier, getBedDirection, getBedSpawnPosition, getBlockById, getBlockFromItem, getBlockFromName, getBlockHardness, getBlockLiquidHeight, getBlockState, getCollisionBoundingBox, getComparatorInputOverride, getCreativeTabToDisplayOn, getDefaultState, getDrops, getDrops, getEnableStats, getEnchantPowerBonus, getExpDrop, getExplosionResistance, getExplosionResistance, getExtendedState, getFireSpreadSpeed, getFlammability, getFogColor, getHarvestLevel, getHarvestTool, getIdFromBlock, getLightOpacity, getLightOpacity, getLightValue, getLightValue, getMapColor, getMaterial, getMobilityFlag, getOffset, getOffsetType, getPackedLightmapCoords, getPickBlock, getPlayerRelativeBlockHardness, getRenderType, getSelectedBoundingBox, getSilkTouchDrop, getSlipperiness, getSoundType, getSoundType, getStateAtViewpoint, getStateById, getStateForPlacement, getStateId, getSubBlocks, getTickRandomly, getUnlocalizedName, getUseNeighborBrightness, getValidRotations, harvestBlock, hasComparatorInputOverride, hasCustomBreakingProgress, hasTileEntity, hasTileEntity, isAABBInsideLiquid, isAABBInsideMaterial, isAir, isBeaconBase, isBed, isBedFoot, isBlockNormalCube, isBurning, isCollidable, isEntityInsideMaterial, isEqualTo, isExceptBlockForAttachWithPiston, isExceptionBlockForAttaching, isFertile, isFireSource, isFlammable, isFoliage, isFullBlock, isLadder, isLeaves, isNormalCube, isNormalCube, isPassable, isReplaceable, isReplaceableOreGen, isSideSolid, isStickyBlock, isToolEffective, isTopSolid, isTranslucent, isWood, modifyAcceleration, observedNeighborChange, onBlockClicked, onBlockDestroyedByExplosion, onBlockExploded, onBlockHarvested, onEntityCollidedWithBlock, onEntityWalk, onFallenUpon, onLanded, onPlantGrow, quantityDropped, quantityDropped, quantityDroppedWithBonus, randomDisplayTick, rayTrace, recolorBlock, registerBlocks, removedByPlayer, requiresUpdates, setBedOccupied, setBlockUnbreakable, setCreativeTab, setDefaultSlipperiness, setDefaultState, setHardness, setHarvestLevel, setHarvestLevel, setLightLevel, setLightOpacity, setResistance, setSoundType, setTickRandomly, setUnlocalizedName, shouldCheckWeakPower, spawnAsEntity, tickRate, toStringgetRegistryName, getRegistryType, setRegistryName, setRegistryName, setRegistryNamepublic static final PropertyBool POWERED
public static final PropertyEnum<BlockRedstoneComparator.Mode> MODE
public java.lang.String getLocalizedName()
getLocalizedName in class Blockpublic Item getItemDropped(IBlockState state, java.util.Random rand, int fortune)
getItemDropped in class Blockpublic ItemStack getItem(World worldIn, BlockPos pos, IBlockState state)
protected int getDelay(IBlockState state)
getDelay in class BlockRedstoneDiodeprotected IBlockState getPoweredState(IBlockState unpoweredState)
getPoweredState in class BlockRedstoneDiodeprotected IBlockState getUnpoweredState(IBlockState poweredState)
getUnpoweredState in class BlockRedstoneDiodeprotected boolean isPowered(IBlockState state)
isPowered in class BlockRedstoneDiodeprotected int getActiveSignal(IBlockAccess worldIn, BlockPos pos, IBlockState state)
getActiveSignal in class BlockRedstoneDiodeprotected boolean shouldBePowered(World worldIn, BlockPos pos, IBlockState state)
shouldBePowered in class BlockRedstoneDiodeprotected int calculateInputStrength(World worldIn, BlockPos pos, IBlockState state)
calculateInputStrength in class BlockRedstoneDiodepublic boolean onBlockActivated(World worldIn, BlockPos pos, IBlockState state, EntityPlayer playerIn, EnumHand hand, EnumFacing facing, float hitX, float hitY, float hitZ)
onBlockActivated in class Blockprotected void updateState(World worldIn, BlockPos pos, IBlockState state)
updateState in class BlockRedstoneDiodepublic void updateTick(World worldIn, BlockPos pos, IBlockState state, java.util.Random rand)
updateTick in class BlockRedstoneDiodepublic void onBlockAdded(World worldIn, BlockPos pos, IBlockState state)
onBlockAdded in class BlockRedstoneDiodepublic void breakBlock(World worldIn, BlockPos pos, IBlockState state)
breakBlock in class Blockpublic boolean eventReceived(IBlockState state, World worldIn, BlockPos pos, int id, int param)
eventReceived in class Blockpublic TileEntity createNewTileEntity(World worldIn, int meta)
createNewTileEntity in interface ITileEntityProviderpublic IBlockState getStateFromMeta(int meta)
getStateFromMeta in class Blockpublic int getMetaFromState(IBlockState state)
getMetaFromState in class Blockpublic IBlockState withRotation(IBlockState state, Rotation rot)
withRotation in class Blockpublic IBlockState withMirror(IBlockState state, Mirror mirrorIn)
withMirror in class Blockprotected BlockStateContainer createBlockState()
createBlockState in class Blockpublic IBlockState getStateForPlacement(World worldIn, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
getStateForPlacement in class BlockRedstoneDiodepublic void onNeighborChange(IBlockAccess world, BlockPos pos, BlockPos neighbor)
BlockonNeighborChange in class Blockworld - The worldpos - Block position in worldneighbor - Block position of neighborpublic boolean getWeakChanges(IBlockAccess world, BlockPos pos)
BlockgetWeakChanges in class Blockworld - The current worldpos - Block position in world