Package commoble.morered.wire_post

# Class AbstractPoweredWirePostBlock

java.lang.Object
net.minecraft.world.level.block.state.BlockBehaviour
net.minecraft.world.level.block.Block
commoble.morered.wire_post.AbstractPostBlock
commoble.morered.wire_post.AbstractPoweredWirePostBlock

All Implemented Interfaces:
  `net.minecraft.world.flag.FeatureElement`, `net.minecraft.world.level.block.EntityBlock`, `net.minecraft.world.level.ItemLike`, `net.minecraftforge.common.extensions.IForgeBlock`

Direct Known Subclasses:
  `WirePostBlock`, `WirePostPlateBlock`

public abstract class AbstractPoweredWirePostBlock extends AbstractPostBlock implements net.minecraft.world.level.block.EntityBlock

## Nested Class Summary

## Nested classes/interfaces inherited from class net.minecraft.world.level.block.Block

`net.minecraft.world.level.block.Block.BlockStatePairKey`

## Nested classes/interfaces inherited from class net.minecraft.world.level.block.state.BlockBehaviour

`net.minecraft.world.level.block.state.BlockBehaviour.BlockStateBase, net.minecraft.world.level.block.state.BlockBehaviour.OffsetFunction, net.minecraft.world.level.block.state.BlockBehaviour.OffsetType, net.minecraft.world.level.block.state.BlockBehaviour.Properties, net.minecraft.world.level.block.state.BlockBehaviour.StateArgumentPredicate<A extends Object>, net.minecraft.world.level.block.state.BlockBehaviour.StatePredicate`

## Field Summary

Fields
Modifier and Type
Field
Description
`static final EnumSet<net.minecraft.core.Direction>`
`NO_DIRECTIONS`
`protected static final net.minecraft.world.phys.shapes.VoxelShape[]`
`POST_SHAPES_DUNSWE`
`static final net.minecraft.world.level.block.state.properties.IntegerProperty`
`POWER`

### Fields inherited from class commoble.morered.wire_post.AbstractPostBlock

`DIRECTION_OF_ATTACHMENT, TRANSFORM`

### Fields inherited from class net.minecraft.world.level.block.Block

`BLOCK_STATE_REGISTRY, INDESTRUCTIBLE, INSTANT, stateDefinition, UPDATE_ALL, UPDATE_ALL_IMMEDIATE, UPDATE_CLIENTS, UPDATE_IMMEDIATE, UPDATE_INVISIBLE, UPDATE_KNOWN_SHAPE, UPDATE_LIMIT, UPDATE_MOVE_BY_PISTON, UPDATE_NEIGHBORS, UPDATE_NONE, UPDATE_SUPPRESS_DROPS`

### Fields inherited from class net.minecraft.world.level.block.state.BlockBehaviour

`drops, dynamicShape, explosionResistance, friction, hasCollision, isRandomlyTicking, jumpFactor, properties, requiredFeatures, soundType, speedFactor, UPDATE_SHAPE_ORDER`

### Fields inherited from interface net.minecraft.world.flag.FeatureElement

`FILTERED_REGISTRIES`

## Constructor Summary

Constructors
Constructor
Description
`AbstractPoweredWirePostBlock(net.minecraft.world.level.block.state.BlockBehaviour.Properties properties, Function<net.minecraft.world.level.block.state.BlockState,EnumSet<net.minecraft.core.Direction>> connectionGetter)`

## Method Summary

Modifier and Type
Method
Description
`boolean`
`canConnectRedstone(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.BlockGetter world, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction side)`
`protected void`
`createBlockStateDefinition(net.minecraft.world.level.block.state.StateDefinition.Builder<net.minecraft.world.level.block.Block,net.minecraft.world.level.block.state.BlockState> builder)`
`EnumSet<net.minecraft.core.Direction>`
`getConnectableDirections(net.minecraft.world.level.block.state.BlockState state)`
`int`
`getConnectionPower(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos)`
Returns the highest redstone power level among the posts connected to this post
`int`
`getDirectSignal(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.BlockGetter world, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction directionFromNeighbor)`
Deprecated.
`int`
`getNeighborPower(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos)`
Returns the highest redstone power level among the neighbors adjacent to this block's redstone-connecting sides
`int`
`getNewPower(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos)`
Returns a power level equal to one less than the highest power level among the blocks that this block can connect to
`int`
`getSignal(net.minecraft.world.level.block.state.BlockState blockState, net.minecraft.world.level.BlockGetter blockAccess, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction directionOfThisBlockFromCaller)`
Deprecated.
`net.minecraft.world.level.block.state.BlockState`
`getStateForPlacement(net.minecraft.world.item.context.BlockPlaceContext context)`
`boolean`
`isSignalSource(net.minecraft.world.level.block.state.BlockState state)`
Deprecated.
`void`
`neighborChanged(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.Block blockIn, net.minecraft.core.BlockPos fromPos, boolean isMoving)`
Deprecated.
`net.minecraft.world.level.block.entity.BlockEntity`
`newBlockEntity(net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state)`
`void`
`notifyNeighbors(net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state)`
`void`
`setPlacedBy(net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.entity.LivingEntity placer, net.minecraft.world.item.ItemStack stack)`
Called by ItemBlocks after a block is set in the world, to allow post-place logic
`net.minecraft.world.level.block.state.BlockState`
`updateShape(net.minecraft.world.level.block.state.BlockState state, net.minecraft.core.Direction facing, net.minecraft.world.level.block.state.BlockState facingState, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos, net.minecraft.core.BlockPos facingPos)`
Called after a block is placed next to this block Update the provided state given the provided neighbor facing and neighbor state, returning a new state.

### Methods inherited from class commoble.morered.wire_post.AbstractPostBlock

`getCollisionShape, mirror, onPlace, onRemove, rotate, updatePostSet`

### Methods inherited from class net.minecraft.world.level.block.Block

`animateTick, appendHoverText, asBlock, asItem, box, builtInRegistryHolder, byItem, canSupportCenter, canSupportRigidBlock, canSustainPlant, defaultBlockState, destroy, dropFromExplosion, dropResources, dropResources, dropResources, dropResources, fallOn, getCloneItemStack, getDescriptionId, getDrops, getDrops, getExplosionResistance, getFriction, getId, getJumpFactor, getName, getRenderPropertiesInternal, getShapeForEachState, getSoundType, getSpeedFactor, getStateDefinition, handlePrecipitation, hasDynamicShape, initializeClient, isExceptionForConnection, isFaceFull, isPossibleToRespawnInThis, isRandomlyTicking, isShapeFullBlock, playerDestroy, playerWillDestroy, popExperience, popResource, popResourceFromFace, propagatesSkylightDown, pushEntitiesUp, registerDefaultState, shouldRenderFace, spawnDestroyParticles, stateById, stepOn, toString, tryDropExperience, updateEntityAfterFallOn, updateFromNeighbourShapes, updateOrDestroy, updateOrDestroy, wasExploded, withPropertiesOf`

### Methods inherited from class net.minecraft.world.level.block.state.BlockBehaviour

`attack, canBeReplaced, canBeReplaced, canSurvive, defaultDestroyTime, defaultMapColor, entityInside, getAnalogOutputSignal, getBlockSupportShape, getDestroyProgress, getDrops, getFluidState, getInteractionShape, getLightBlock, getLootTable, getMaxHorizontalOffset, getMaxVerticalOffset, getMenuProvider, getOcclusionShape, getRenderShape, getSeed, getShadeBrightness, getShape, getVisualShape, hasAnalogOutputSignal, isAir, isCollisionShapeFullBlock, isOcclusionShapeFullBlock, isPathfindable, onProjectileHit, randomTick, requiredFeatures, skipRendering, spawnAfterBreak, tick, triggerEvent, updateIndirectNeighbourShapes, use, useShapeForLightOcclusion`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Methods inherited from interface net.minecraft.world.level.block.EntityBlock

`getListener, getTicker`

### Methods inherited from interface net.minecraft.world.flag.FeatureElement

`isEnabled`

### Methods inherited from interface net.minecraftforge.common.extensions.IForgeBlock

`addLandingEffects, addRunningEffects, canBeHydrated, canDropFromExplosion, canEntityDestroy, canHarvestBlock, canStickTo, collisionExtendsVertically, getAdjacentBlockPathType, getAppearance, getBeaconColorMultiplier, getBedDirection, getBlockPathType, getCloneItemStack, getEnchantPowerBonus, getExpDrop, getExplosionResistance, getFireSpreadSpeed, getFlammability, getFriction, getLightEmission, getMapColor, getPistonPushReaction, getRespawnPosition, getSoundType, getStateAtViewpoint, getToolModifiedState, getWeakChanges, hidesNeighborFace, isBed, isBurning, isConduitFrame, isFertile, isFireSource, isFlammable, isLadder, isPortalFrame, isScaffolding, isSlimeBlock, isStickyBlock, isValidSpawn, makesOpenTrapdoorAboveClimbable, onBlockExploded, onBlockStateChange, onCaughtFire, onDestroyedByPlayer, onNeighborChange, onTreeGrow, rotate, setBedOccupied, shouldCheckWeakPower, shouldDisplayFluidOverlay, supportsExternalFaceHiding`

## Field Details

### POWER

public static final net.minecraft.world.level.block.state.properties.IntegerProperty POWER

### NO_DIRECTIONS

public static final EnumSet<net.minecraft.core.Direction> NO_DIRECTIONS

### POST_SHAPES_DUNSWE

protected static final net.minecraft.world.phys.shapes.VoxelShape[] POST_SHAPES_DUNSWE

## Constructor Details

### AbstractPoweredWirePostBlock

public AbstractPoweredWirePostBlock(net.minecraft.world.level.block.state.BlockBehaviour.Properties properties, Function<net.minecraft.world.level.block.state.BlockState,EnumSet<net.minecraft.core.Direction>> connectionGetter)

## Method Details

### newBlockEntity

public net.minecraft.world.level.block.entity.BlockEntity newBlockEntity(net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state)

Specified by:
  `newBlockEntity` in interface `net.minecraft.world.level.block.EntityBlock`

### createBlockStateDefinition

protected void createBlockStateDefinition(net.minecraft.world.level.block.state.StateDefinition.Builder<net.minecraft.world.level.block.Block,net.minecraft.world.level.block.state.BlockState> builder)

Overrides:
  `createBlockStateDefinition` in class `AbstractPostBlock`

### setPlacedBy

public void setPlacedBy(net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.entity.LivingEntity placer, net.minecraft.world.item.ItemStack stack)
Called by ItemBlocks after a block is set in the world, to allow post-place logic

Overrides:
  `setPlacedBy` in class `net.minecraft.world.level.block.Block`

### neighborChanged

@Deprecated public void neighborChanged(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.Block blockIn, net.minecraft.core.BlockPos fromPos, boolean isMoving)
Deprecated.

Overrides:
  `neighborChanged` in class `net.minecraft.world.level.block.state.BlockBehaviour`

### getStateForPlacement

@Nullable public net.minecraft.world.level.block.state.BlockState getStateForPlacement(net.minecraft.world.item.context.BlockPlaceContext context)

Overrides:
  `getStateForPlacement` in class `AbstractPostBlock`

### updateShape

public net.minecraft.world.level.block.state.BlockState updateShape(net.minecraft.world.level.block.state.BlockState state, net.minecraft.core.Direction facing, net.minecraft.world.level.block.state.BlockState facingState, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos, net.minecraft.core.BlockPos facingPos)
Called after a block is placed next to this block Update the provided state given the provided neighbor facing and neighbor state, returning a new state. For example, fences make their connections to the passed in state if possible, and wet concrete powder immediately returns its solidified counterpart. Note that this method should ideally consider only the specific face passed in.

Overrides:
  `updateShape` in class `net.minecraft.world.level.block.state.BlockBehaviour`

### isSignalSource

@Deprecated public boolean isSignalSource(net.minecraft.world.level.block.state.BlockState state)
Deprecated.
Can this block provide power. Only wire currently seems to have this change based on its state.

Overrides:
  `isSignalSource` in class `net.minecraft.world.level.block.state.BlockBehaviour`
Parameters:
  `state` - A blockstate of this block

### canConnectRedstone

public boolean canConnectRedstone(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.BlockGetter world, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction side)

Specified by:
  `canConnectRedstone` in interface `net.minecraftforge.common.extensions.IForgeBlock`

### getSignal

@Deprecated public int getSignal(net.minecraft.world.level.block.state.BlockState blockState, net.minecraft.world.level.BlockGetter blockAccess, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction directionOfThisBlockFromCaller)
Deprecated.

Overrides:
  `getSignal` in class `net.minecraft.world.level.block.state.BlockBehaviour`

### getDirectSignal

@Deprecated public int getDirectSignal(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.BlockGetter world, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction directionFromNeighbor)
Deprecated.

Overrides:
  `getDirectSignal` in class `net.minecraft.world.level.block.state.BlockBehaviour`

### getConnectableDirections

public EnumSet<net.minecraft.core.Direction> getConnectableDirections(net.minecraft.world.level.block.state.BlockState state)

### getNewPower

public int getNewPower(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos)
Returns a power level equal to one less than the highest power level among the blocks that this block can connect to

Parameters:
  `state` - The blockstate of this block
  `world` - The world where the blockstate lives
  `pos` - The position of the blockstate in the world
Returns:
  The new power level to be used by this block

### getNeighborPower

public int getNeighborPower(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos)
Returns the highest redstone power level among the neighbors adjacent to this block's redstone-connecting sides

Parameters:
  `state` - The blockstate of this block
  `world` - The world where the blockstate lives
  `pos` - The position of the state in the world
Returns:
  The highest redstone power level among the relevant neighbors adjacent to this block

### getConnectionPower

public int getConnectionPower(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos)
Returns the highest redstone power level among the posts connected to this post

Parameters:
  `state` - The blockstate of this post block
  `world` - The world object the blockstate lives in
  `pos` - The position of the blockstate in the world
Returns:
  The highest emitted redstone power level among the posts connected to this post

### notifyNeighbors

public void notifyNeighbors(net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state)

Specified by:
  `notifyNeighbors` in class `AbstractPostBlock`