Class ShulkerBoxBlock
- All Implemented Interfaces:
BlockEntityProvider,ItemConvertible,ToggleableFeature
- Mappings:
Namespace Name official cwjintermediary net/minecraft/class_2480named net/minecraft/block/ShulkerBoxBlock
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.block.Block
Block.NeighborGroupNested classes/interfaces inherited from class net.minecraft.block.AbstractBlock
AbstractBlock.AbstractBlockState, AbstractBlock.ContextPredicate, AbstractBlock.Offsetter, AbstractBlock.OffsetType, AbstractBlock.Settings, AbstractBlock.TypedContextPredicate<A> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Identifierprivate static final VoxelShapeprivate static final VoxelShapestatic final EnumProperty<Direction>private static final floatprivate static final VoxelShapeprivate static final Map<Direction,VoxelShape> private static final VoxelShapeprivate static final VoxelShapeprivate static final VoxelShapeFields inherited from class net.minecraft.block.Block
field_31022, field_31023, field_31024, field_31025, field_31035, FORCE_STATE, MOVED, NO_REDRAW, NOTIFY_ALL, NOTIFY_LISTENERS, NOTIFY_NEIGHBORS, REDRAW_ON_MAIN_THREAD, SKIP_DROPS, STATE_IDS, stateManagerFields inherited from class net.minecraft.block.AbstractBlock
collidable, DIRECTIONS, dynamicBounds, jumpVelocityMultiplier, lootTableId, randomTicks, requiredFeatures, resistance, settings, slipperiness, soundGroup, velocityMultiplierFields inherited from interface net.minecraft.resource.featuretoggle.ToggleableFeature
FEATURE_ENABLED_REGISTRY_KEYS -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidappendProperties(StateManager.Builder<Block, BlockState> builder) Appends block state properties to this block.voidappendTooltip(ItemStack stack, @Nullable BlockView world, List<Text> tooltip, TooltipContext options) Appends tooltips to a stack of this block's corresponding block item.private static booleancanOpen(BlockState state, World world, BlockPos pos, ShulkerBoxBlockEntity entity) createBlockEntity(BlockPos pos, BlockState state) Returns a new block entity instance.static BlockgetColor()intgetComparatorOutput(BlockState state, World world, BlockPos pos) Returns the comparator output of the block, from0to15.getDroppedStacks(BlockState state, class_8567.class_8568 builder) Returns the block's dropped item stacks.static ItemStackgetItemStack(@Nullable DyeColor color) getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) getPickStack(BlockView world, BlockPos pos, BlockState state) Returns the new item stack when using pick block functionality.getRenderType(BlockState state) Returns the block's render type (invisible, animated, model).getSidesShape(BlockState state, BlockView world, BlockPos pos) <T extends BlockEntity>
@Nullable BlockEntityTicker<T>getTicker(World world, BlockState state, BlockEntityType<T> type) Returns the "ticker" for the block's block entity, ornullif the block entity does not need to be ticked.booleanhasComparatorOutput(BlockState state) Returns whether the block can have a comparator output.mirror(BlockState state, BlockMirror mirror) Returnsstatemirrored bymirror.voidonBreak(World world, BlockPos pos, BlockState state, PlayerEntity player) Called when a player breaks a block before the block is removed from the world.voidonPlaced(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.voidonStateReplaced(BlockState state, World world, BlockPos pos, BlockState newState, boolean moved) Called server-side on the old block when the block state is changed.onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) Called when this block is used by a player.rotate(BlockState state, BlockRotation rotation) Returnsstaterotated byrotation.Methods inherited from class net.minecraft.block.BlockWithEntity
checkType, createScreenHandlerFactory, onSyncedBlockEventMethods inherited from class net.minecraft.block.Block
afterBreak, asBlock, asItem, canMobSpawnInside, cannotConnect, createCuboidShape, dropExperience, dropExperienceWhenMined, dropStack, dropStack, dropStacks, dropStacks, dropStacks, getBlastResistance, getBlockFromItem, getDefaultState, getDroppedStacks, getDroppedStacks, getJumpVelocityMultiplier, getName, getRawIdFromState, getRegistryEntry, getShapesForStates, getSlipperiness, getSoundGroup, getStateFromRawId, getStateManager, getStateWithProperties, getTranslationKey, getVelocityMultiplier, hasDynamicBounds, hasRandomTicks, hasTopRim, isFaceFullSquare, isShapeFullCube, isTransparent, onBroken, onDestroyedByExplosion, onEntityLand, onLandedUpon, onSteppedOn, postProcessState, precipitationTick, pushEntitiesUpBeforeBlockChange, randomDisplayTick, replace, replace, setDefaultState, shouldDrawSide, shouldDropItemsOnExplosion, sideCoversSmallSquare, spawnBreakParticles, toStringMethods inherited from class net.minecraft.block.AbstractBlock
calcBlockBreakingDelta, canBucketPlace, canPathfindThrough, canPlaceAt, canReplace, emitsRedstonePower, getAmbientOcclusionLightLevel, getCameraCollisionShape, getCollisionShape, getCullingShape, getDefaultMapColor, getFluidState, getHardness, getLootTableId, getMaxHorizontalModelOffset, getOpacity, getRaycastShape, getRenderingSeed, getRequiredFeatures, getStateForNeighborUpdate, getStrongRedstonePower, getVerticalModelOffsetMultiplier, getWeakRedstonePower, hasSidedTransparency, isCullingShapeFullCube, isShapeFullCube, isSideInvisible, neighborUpdate, onBlockAdded, onBlockBreakStart, onEntityCollision, onProjectileHit, onStacksDropped, prepare, randomTick, scheduledTickMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.block.BlockEntityProvider
getGameEventListenerMethods inherited from interface net.minecraft.resource.featuretoggle.ToggleableFeature
isEnabled
-
Field Details
-
field_41075
private static final float field_41075- See Also:
- Mappings:
Namespace Name Mixin selector official cLcwj;c:Fintermediary field_41075Lnet/minecraft/class_2480;field_41075:Fnamed field_41075Lnet/minecraft/block/ShulkerBoxBlock;field_41075:F
-
UP_SHAPE
- Mappings:
Namespace Name Mixin selector official dLcwj;d:Leet;intermediary field_41076Lnet/minecraft/class_2480;field_41076:Lnet/minecraft/class_265;named UP_SHAPELnet/minecraft/block/ShulkerBoxBlock;UP_SHAPE:Lnet/minecraft/util/shape/VoxelShape;
-
DOWN_SHAPE
- Mappings:
Namespace Name Mixin selector official eLcwj;e:Leet;intermediary field_41077Lnet/minecraft/class_2480;field_41077:Lnet/minecraft/class_265;named DOWN_SHAPELnet/minecraft/block/ShulkerBoxBlock;DOWN_SHAPE:Lnet/minecraft/util/shape/VoxelShape;
-
WEST_SHAPE
- Mappings:
Namespace Name Mixin selector official fLcwj;f:Leet;intermediary field_41078Lnet/minecraft/class_2480;field_41078:Lnet/minecraft/class_265;named WEST_SHAPELnet/minecraft/block/ShulkerBoxBlock;WEST_SHAPE:Lnet/minecraft/util/shape/VoxelShape;
-
EAST_SHAPE
- Mappings:
Namespace Name Mixin selector official gLcwj;g:Leet;intermediary field_41079Lnet/minecraft/class_2480;field_41079:Lnet/minecraft/class_265;named EAST_SHAPELnet/minecraft/block/ShulkerBoxBlock;EAST_SHAPE:Lnet/minecraft/util/shape/VoxelShape;
-
NORTH_SHAPE
- Mappings:
Namespace Name Mixin selector official hLcwj;h:Leet;intermediary field_41080Lnet/minecraft/class_2480;field_41080:Lnet/minecraft/class_265;named NORTH_SHAPELnet/minecraft/block/ShulkerBoxBlock;NORTH_SHAPE:Lnet/minecraft/util/shape/VoxelShape;
-
SOUTH_SHAPE
- Mappings:
Namespace Name Mixin selector official iLcwj;i:Leet;intermediary field_41081Lnet/minecraft/class_2480;field_41081:Lnet/minecraft/class_265;named SOUTH_SHAPELnet/minecraft/block/ShulkerBoxBlock;SOUTH_SHAPE:Lnet/minecraft/util/shape/VoxelShape;
-
SIDES_SHAPES
- Mappings:
Namespace Name Mixin selector official jLcwj;j:Ljava/util/Map;intermediary field_41082Lnet/minecraft/class_2480;field_41082:Ljava/util/Map;named SIDES_SHAPESLnet/minecraft/block/ShulkerBoxBlock;SIDES_SHAPES:Ljava/util/Map;
-
FACING
- Mappings:
Namespace Name Mixin selector official aLcwj;a:Ldcw;intermediary field_11496Lnet/minecraft/class_2480;field_11496:Lnet/minecraft/class_2754;named FACINGLnet/minecraft/block/ShulkerBoxBlock;FACING:Lnet/minecraft/state/property/EnumProperty;
-
CONTENTS
- Mappings:
Namespace Name Mixin selector official bLcwj;b:Lacq;intermediary field_11495Lnet/minecraft/class_2480;field_11495:Lnet/minecraft/class_2960;named CONTENTSLnet/minecraft/block/ShulkerBoxBlock;CONTENTS:Lnet/minecraft/util/Identifier;
-
color
- Mappings:
Namespace Name Mixin selector official kLcwj;k:Lcel;intermediary field_11494Lnet/minecraft/class_2480;field_11494:Lnet/minecraft/class_1767;named colorLnet/minecraft/block/ShulkerBoxBlock;color:Lnet/minecraft/util/DyeColor;
-
-
Constructor Details
-
ShulkerBoxBlock
- Mappings:
Namespace Name Mixin selector official <init>Lcwj;<init>(Lcel;Ldbx$d;)Vintermediary <init>Lnet/minecraft/class_2480;<init>(Lnet/minecraft/class_1767;Lnet/minecraft/class_4970$class_2251;)Vnamed <init>Lnet/minecraft/block/ShulkerBoxBlock;<init>(Lnet/minecraft/util/DyeColor;Lnet/minecraft/block/AbstractBlock$Settings;)V
-
-
Method Details
-
createBlockEntity
Returns a new block entity instance.For example:
@Override public BlockEntity createBlockEntity(BlockPos pos, BlockState state) { return new MyBlockEntity(pos, state); }- Returns:
- a new block entity instance
- Mappings:
Namespace Name Mixin selector official aLcrz;a(Lgu;Ldby;)Lczk;intermediary method_10123Lnet/minecraft/class_2343;method_10123(Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;)Lnet/minecraft/class_2586;named createBlockEntityLnet/minecraft/block/BlockEntityProvider;createBlockEntity(Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)Lnet/minecraft/block/entity/BlockEntity;
-
getTicker
@Nullable public <T extends BlockEntity> @Nullable BlockEntityTicker<T> getTicker(World world, BlockState state, BlockEntityType<T> type) Returns the "ticker" for the block's block entity, ornullif the block entity does not need to be ticked.Ticker is a functional interface called every tick to tick the block entity on both the client and the server.
Tickers should validate that the passed
typeis the one this block expects, and returnnullif it isn't. This is to prevent crashes in rare cases where a mismatch occurs between the position's block and block entity.BlockWithEntity.checkType(net.minecraft.block.entity.BlockEntityType<A>, net.minecraft.block.entity.BlockEntityType<E>, net.minecraft.block.entity.BlockEntityTicker<? super E>)can be used to implement the check.Example:
public <T extends BlockEntity> BlockEntityTicker<T> getTicker(World world, BlockState state, BlockEntityType<T> type) { if (type != YourMod.MY_BLOCK_ENTITY_TYPE) return null; // This should be a static method usable as a BlockEntityTicker. return YourBlockEntity::tick; }- Returns:
- the "ticker" for the block's block entity, or
nullif the block entity does not need to be ticked - Mappings:
Namespace Name Mixin selector official aLcrz;a(Lcmk;Ldby;Lczm;)Lczl;intermediary method_31645Lnet/minecraft/class_2343;method_31645(Lnet/minecraft/class_1937;Lnet/minecraft/class_2680;Lnet/minecraft/class_2591;)Lnet/minecraft/class_5558;named getTickerLnet/minecraft/block/BlockEntityProvider;getTicker(Lnet/minecraft/world/World;Lnet/minecraft/block/BlockState;Lnet/minecraft/block/entity/BlockEntityType;)Lnet/minecraft/block/entity/BlockEntityTicker;
-
getRenderType
Returns the block's render type (invisible, animated, model).- Overrides:
getRenderTypein classBlockWithEntity- Returns:
- the block's render type (invisible, animated, model)
- Mappings:
Namespace Name Mixin selector official b_Ldbx;b_(Ldby;)Lcvp;intermediary method_9604Lnet/minecraft/class_4970;method_9604(Lnet/minecraft/class_2680;)Lnet/minecraft/class_2464;named getRenderTypeLnet/minecraft/block/AbstractBlock;getRenderType(Lnet/minecraft/block/BlockState;)Lnet/minecraft/block/BlockRenderType;
-
onUse
public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) Called when this block is used by a player. This, by default, is bound to using the right mouse button.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.
- Overrides:
onUsein classAbstractBlock- Returns:
- an action result that specifies if using the block was successful.
- Mappings:
Namespace Name Mixin selector official aLdbx;a(Ldby;Lcmk;Lgu;Lbym;Lbdv;Ledw;)Lbdw;intermediary method_9534Lnet/minecraft/class_4970;method_9534(Lnet/minecraft/class_2680;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;Lnet/minecraft/class_1657;Lnet/minecraft/class_1268;Lnet/minecraft/class_3965;)Lnet/minecraft/class_1269;named onUseLnet/minecraft/block/AbstractBlock;onUse(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/entity/player/PlayerEntity;Lnet/minecraft/util/Hand;Lnet/minecraft/util/hit/BlockHitResult;)Lnet/minecraft/util/ActionResult;
-
canOpen
private static boolean canOpen(BlockState state, World world, BlockPos pos, ShulkerBoxBlockEntity entity) - Mappings:
Namespace Name Mixin selector official aLcwj;a(Ldby;Lcmk;Lgu;Ldar;)Zintermediary method_33383Lnet/minecraft/class_2480;method_33383(Lnet/minecraft/class_2680;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;Lnet/minecraft/class_2627;)Znamed canOpenLnet/minecraft/block/ShulkerBoxBlock;canOpen(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/entity/ShulkerBoxBlockEntity;)Z
-
getPlacementState
- Overrides:
getPlacementStatein classBlock- Mappings:
Namespace Name Mixin selector official aLcpl;a(Lcif;)Ldby;intermediary method_9605Lnet/minecraft/class_2248;method_9605(Lnet/minecraft/class_1750;)Lnet/minecraft/class_2680;named getPlacementStateLnet/minecraft/block/Block;getPlacementState(Lnet/minecraft/item/ItemPlacementContext;)Lnet/minecraft/block/BlockState;
-
appendProperties
Appends block state properties to this block. To use this, override and callStateManager.Builder.add(net.minecraft.state.property.Property<?>[])inside the method. SeePropertiesfor the list of pre-defined properties.- Overrides:
appendPropertiesin classBlock- Mappings:
Namespace Name Mixin selector official aLcpl;a(Ldbz$a;)Vintermediary method_9515Lnet/minecraft/class_2248;method_9515(Lnet/minecraft/class_2689$class_2690;)Vnamed appendPropertiesLnet/minecraft/block/Block;appendProperties(Lnet/minecraft/state/StateManager$Builder;)V
-
onBreak
Called when a player breaks a block before the block is removed from the world. Explosions do not trigger this.Default implementation spawns block breaking particles, angers piglins, and emits game events. Tall or wide blocks such as doors or beds should override this to break the other part (along with
AbstractBlock.getStateForNeighborUpdate(net.minecraft.block.BlockState, net.minecraft.util.math.Direction, net.minecraft.block.BlockState, net.minecraft.world.WorldAccess, net.minecraft.util.math.BlockPos, net.minecraft.util.math.BlockPos).)In most cases,
AbstractBlock.onStateReplaced(net.minecraft.block.BlockState, net.minecraft.world.World, net.minecraft.util.math.BlockPos, net.minecraft.block.BlockState, boolean)orAbstractBlock.onStacksDropped(net.minecraft.block.BlockState, net.minecraft.server.world.ServerWorld, net.minecraft.util.math.BlockPos, net.minecraft.item.ItemStack, boolean)should be used instead. Note that they are called when blocks are broken by explosions as well as players breaking them.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.- Overrides:
onBreakin classBlock- See Also:
- Mappings:
Namespace Name Mixin selector official aLcpl;a(Lcmk;Lgu;Ldby;Lbym;)Vintermediary method_9576Lnet/minecraft/class_2248;method_9576(Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;Lnet/minecraft/class_1657;)Vnamed onBreakLnet/minecraft/block/Block;onBreak(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Lnet/minecraft/entity/player/PlayerEntity;)V
-
getDroppedStacks
Returns the block's dropped item stacks.The default implementation uses loot tables. Blocks with custom drops should not hardcode the drops; instead, make a new loot table. If the loot table needs an additional context, override this method and modify
builderbefore callingsuper.getDroppedStacks. An example of this isShulkerBoxBlock. Note that to prevent item duplication, when appending item stacks to the builder,ItemStack.split(int)should be called.This method should not be used for dropping inventory contents (
AbstractBlock.onStateReplaced(net.minecraft.block.BlockState, net.minecraft.world.World, net.minecraft.util.math.BlockPos, net.minecraft.block.BlockState, boolean)should be used instead) or to drop experience orbs (AbstractBlock.onStacksDropped(net.minecraft.block.BlockState, net.minecraft.server.world.ServerWorld, net.minecraft.util.math.BlockPos, net.minecraft.item.ItemStack, boolean)should be used instead).- Overrides:
getDroppedStacksin classAbstractBlock- Returns:
- the block's dropped item stacks
- See Also:
- Mappings:
Namespace Name Mixin selector official aLdbx;a(Ldby;Ldzn$a;)Ljava/util/List;intermediary method_9560Lnet/minecraft/class_4970;method_9560(Lnet/minecraft/class_2680;Lnet/minecraft/class_8567$class_8568;)Ljava/util/List;named getDroppedStacksLnet/minecraft/block/AbstractBlock;getDroppedStacks(Lnet/minecraft/block/BlockState;Lnet/minecraft/class_8567$class_8568;)Ljava/util/List;
-
onPlaced
public void onPlaced(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.Tall or wide blocks (such as doors or beds) should override this to place the other half of the block. Blocks with block entities can use this to copy the data from the item stack, such as the custom name.
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.- Overrides:
onPlacedin classBlock- See Also:
- Mappings:
Namespace Name Mixin selector official aLcpl;a(Lcmk;Lgu;Ldby;Lbfx;Lcfx;)Vintermediary method_9567Lnet/minecraft/class_2248;method_9567(Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;Lnet/minecraft/class_1309;Lnet/minecraft/class_1799;)Vnamed onPlacedLnet/minecraft/block/Block;onPlaced(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Lnet/minecraft/entity/LivingEntity;Lnet/minecraft/item/ItemStack;)V
-
onStateReplaced
public void onStateReplaced(BlockState state, World world, BlockPos pos, BlockState newState, boolean moved) Called server-side on the old block when the block state is changed. This includes block removal. This is used to update neighboring blocks when an active redstone power source is removed, or to drop the contents of an inventory. The checkstate.isOf(newState.getBlock())can be used to see if the block was removed or not.- Overrides:
onStateReplacedin classAbstractBlock- See Also:
- Mappings:
Namespace Name Mixin selector official aLdbx;a(Ldby;Lcmk;Lgu;Ldby;Z)Vintermediary method_9536Lnet/minecraft/class_4970;method_9536(Lnet/minecraft/class_2680;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;Z)Vnamed onStateReplacedLnet/minecraft/block/AbstractBlock;onStateReplaced(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Z)V
-
appendTooltip
public void appendTooltip(ItemStack stack, @Nullable @Nullable BlockView world, List<Text> tooltip, TooltipContext options) Appends tooltips to a stack of this block's corresponding block item. Used by shulker boxes.- Overrides:
appendTooltipin classBlock- See Also:
- Mappings:
Namespace Name Mixin selector official aLcpl;a(Lcfx;Lclq;Ljava/util/List;Lcho;)Vintermediary method_9568Lnet/minecraft/class_2248;method_9568(Lnet/minecraft/class_1799;Lnet/minecraft/class_1922;Ljava/util/List;Lnet/minecraft/class_1836;)Vnamed appendTooltipLnet/minecraft/block/Block;appendTooltip(Lnet/minecraft/item/ItemStack;Lnet/minecraft/world/BlockView;Ljava/util/List;Lnet/minecraft/client/item/TooltipContext;)V
-
getSidesShape
- Overrides:
getSidesShapein classAbstractBlock- Mappings:
Namespace Name Mixin selector official b_Ldbx;b_(Ldby;Lclq;Lgu;)Leet;intermediary method_25959Lnet/minecraft/class_4970;method_25959(Lnet/minecraft/class_2680;Lnet/minecraft/class_1922;Lnet/minecraft/class_2338;)Lnet/minecraft/class_265;named getSidesShapeLnet/minecraft/block/AbstractBlock;getSidesShape(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/BlockView;Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/util/shape/VoxelShape;
-
getOutlineShape
public VoxelShape getOutlineShape(BlockState state, BlockView world, BlockPos pos, ShapeContext context) - Overrides:
getOutlineShapein classAbstractBlock- Mappings:
Namespace Name Mixin selector official aLdbx;a(Ldby;Lclq;Lgu;Leef;)Leet;intermediary method_9530Lnet/minecraft/class_4970;method_9530(Lnet/minecraft/class_2680;Lnet/minecraft/class_1922;Lnet/minecraft/class_2338;Lnet/minecraft/class_3726;)Lnet/minecraft/class_265;named getOutlineShapeLnet/minecraft/block/AbstractBlock;getOutlineShape(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/BlockView;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/ShapeContext;)Lnet/minecraft/util/shape/VoxelShape;
-
hasComparatorOutput
Returns whether the block can have a comparator output.This does not check the current comparator output of the block. Use
AbstractBlock.getComparatorOutput(net.minecraft.block.BlockState, net.minecraft.world.World, net.minecraft.util.math.BlockPos)in that case.- Overrides:
hasComparatorOutputin classAbstractBlock- Returns:
- whether the block can have a comparator output
- See Also:
- Mappings:
Namespace Name Mixin selector official d_Ldbx;d_(Ldby;)Zintermediary method_9498Lnet/minecraft/class_4970;method_9498(Lnet/minecraft/class_2680;)Znamed hasComparatorOutputLnet/minecraft/block/AbstractBlock;hasComparatorOutput(Lnet/minecraft/block/BlockState;)Z
-
getComparatorOutput
Returns the comparator output of the block, from0to15.When overriding this,
AbstractBlock.hasComparatorOutput(net.minecraft.block.BlockState)must also be overridden.- Overrides:
getComparatorOutputin classAbstractBlock- Returns:
- the comparator output of the block, from
0to15 - See Also:
- Mappings:
Namespace Name Mixin selector official aLdbx;a(Ldby;Lcmk;Lgu;)Iintermediary method_9572Lnet/minecraft/class_4970;method_9572(Lnet/minecraft/class_2680;Lnet/minecraft/class_1937;Lnet/minecraft/class_2338;)Inamed getComparatorOutputLnet/minecraft/block/AbstractBlock;getComparatorOutput(Lnet/minecraft/block/BlockState;Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;)I
-
getPickStack
Returns the new item stack when using pick block functionality.Pick block is available via middle-clicking by default. Blocks without the corresponding
BlockItem, such as crops, should override this method to return the correct item stack.- Overrides:
getPickStackin classBlock- Returns:
- the new item stack when using pick block functionality
- Mappings:
Namespace Name Mixin selector official aLcpl;a(Lclq;Lgu;Ldby;)Lcfx;intermediary method_9574Lnet/minecraft/class_2248;method_9574(Lnet/minecraft/class_1922;Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;)Lnet/minecraft/class_1799;named getPickStackLnet/minecraft/block/Block;getPickStack(Lnet/minecraft/world/BlockView;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)Lnet/minecraft/item/ItemStack;
-
getColor
- Mappings:
Namespace Name Mixin selector official bLcwj;b(Lcfs;)Lcel;intermediary method_10527Lnet/minecraft/class_2480;method_10527(Lnet/minecraft/class_1792;)Lnet/minecraft/class_1767;named getColorLnet/minecraft/block/ShulkerBoxBlock;getColor(Lnet/minecraft/item/Item;)Lnet/minecraft/util/DyeColor;
-
getColor
- Mappings:
Namespace Name Mixin selector official aLcwj;a(Lcpl;)Lcel;intermediary method_10526Lnet/minecraft/class_2480;method_10526(Lnet/minecraft/class_2248;)Lnet/minecraft/class_1767;named getColorLnet/minecraft/block/ShulkerBoxBlock;getColor(Lnet/minecraft/block/Block;)Lnet/minecraft/util/DyeColor;
-
get
- Mappings:
Namespace Name Mixin selector official aLcwj;a(Lcel;)Lcpl;intermediary method_10525Lnet/minecraft/class_2480;method_10525(Lnet/minecraft/class_1767;)Lnet/minecraft/class_2248;named getLnet/minecraft/block/ShulkerBoxBlock;get(Lnet/minecraft/util/DyeColor;)Lnet/minecraft/block/Block;
-
getColor
- Mappings:
Namespace Name Mixin selector official aLcwj;a()Lcel;intermediary method_10528Lnet/minecraft/class_2480;method_10528()Lnet/minecraft/class_1767;named getColorLnet/minecraft/block/ShulkerBoxBlock;getColor()Lnet/minecraft/util/DyeColor;
-
getItemStack
- Mappings:
Namespace Name Mixin selector official bLcwj;b(Lcel;)Lcfx;intermediary method_10529Lnet/minecraft/class_2480;method_10529(Lnet/minecraft/class_1767;)Lnet/minecraft/class_1799;named getItemStackLnet/minecraft/block/ShulkerBoxBlock;getItemStack(Lnet/minecraft/util/DyeColor;)Lnet/minecraft/item/ItemStack;
-
rotate
Returnsstaterotated byrotation.By default, this returns the provided block state.
- Overrides:
rotatein classAbstractBlock- Returns:
staterotated byrotation- Mappings:
Namespace Name Mixin selector official aLdbx;a(Ldby;Lcvw;)Ldby;intermediary method_9598Lnet/minecraft/class_4970;method_9598(Lnet/minecraft/class_2680;Lnet/minecraft/class_2470;)Lnet/minecraft/class_2680;named rotateLnet/minecraft/block/AbstractBlock;rotate(Lnet/minecraft/block/BlockState;Lnet/minecraft/util/BlockRotation;)Lnet/minecraft/block/BlockState;
-
mirror
Returnsstatemirrored bymirror.By default, this returns the provided block state.
- Overrides:
mirrorin classAbstractBlock- Returns:
statemirrored bymirror- Mappings:
Namespace Name Mixin selector official aLdbx;a(Ldby;Lcuf;)Ldby;intermediary method_9569Lnet/minecraft/class_4970;method_9569(Lnet/minecraft/class_2680;Lnet/minecraft/class_2415;)Lnet/minecraft/class_2680;named mirrorLnet/minecraft/block/AbstractBlock;mirror(Lnet/minecraft/block/BlockState;Lnet/minecraft/util/BlockMirror;)Lnet/minecraft/block/BlockState;
-