Package net.minecraft.block
Class PlantBlock
java.lang.Object
net.minecraft.block.Block
net.minecraft.block.PlantBlock
- Direct Known Subclasses:
AttachedStemBlock,CropBlock,DeadBushBlock,DoublePlantBlock,FlowerBlock,LilyPadBlock,MushroomBlock,NetherWartBlock,SaplingBlock,TallPlantBlock
public class PlantBlock extends Block
- Mappings:
Namespace Name official afmintermediary net/minecraft/class_167named net/minecraft/block/PlantBlock
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.block.Block
Block.OffsetType, Block.Sound -
Field Summary
Fields inherited from class net.minecraft.block.Block
ANVIL, BLOCK_STATES, blockEntity, boundingBoxMaxX, boundingBoxMaxY, boundingBoxMaxZ, boundingBoxMinX, boundingBoxMinY, boundingBoxMinZ, CLOTH, fullBlock, GLASS, GRASS, GRAVEL, LADDER, lightLevel, material, materialColor, opacity, ORE, particleGravity, RAIL, randomTicks, REGISTRY, resistance, SAND, SLIME, slipperiness, SNOW, sound, stateManager, stats, STONE, strength, transluscent, useNeighbourLight, WOOD -
Constructor Summary
Constructors Modifier Constructor Description protectedPlantBlock()protectedPlantBlock(Material material)protectedPlantBlock(Material material, MaterialColor color) -
Method Summary
Modifier and Type Method Description booleancanBePlacedAtPos(World world, BlockPos pos)Returns whether the current block can be placed at a certainBlockPosprotected booleancanPlantOnTop(Block block)BoxgetCollisionBox(World world, BlockPos pos, BlockState state)Returns a box by adding the block's current location and the block's corresponding value in its Bounding BoxRenderLayergetRenderLayerType()Returns the appropriate RenderLayer for a block.booleanhasTransperancy()protected voidmethod_754(World world, BlockPos blockPos, BlockState blockState)booleanmethod_755(World world, BlockPos blockPos, BlockState blockState)voidneighborUpdate(World world, BlockPos pos, BlockState state, Block block)Runs when its adjacent blocks are updated.booleanrenderAsNormalBlock()Returns whether the block can be rendered as a normal blockvoidscheduledTick(World world, BlockPos pos, BlockState state, Random rand)Runs when the block is updated as per a scheduleMethods inherited from class net.minecraft.block.Block
appendCollisionBoxes, appendItemStacks, appendProperties, areBlocksEqual, blocksMovement, calcBlockBreakingData, canBePlacedAdjacent, canBeReplaced, canCollide, canMobSpawnInside, createStackFromBlock, disableStats, dropAsItem, dropExperience, emitsRedstonePower, get, getAmbientOcclusionLightLevel, getBlastResistance, getBlendColor, getBlockColor, getBlockFromItem, getBlockState, getBlockType, getBonusDrops, getBrightness, getByBlockState, getById, getColor, getColor, getComparatorOutput, getData, getDefaultState, getDropCount, getDropItem, getIdByBlock, getItemGroup, getLightLevel, getMaterial, getMaterialColor, getMaxX, getMaxY, getMaxZ, getMeta, getMeta, getMinX, getMinY, getMinZ, getOffsetType, getOpacity, getPickItem, getPistonInteractionType, getSelectionBox, getStateFromData, getStateFromRawId, getStateManager, getStrength, getStrongRedstonePower, getTickRate, getTranslatedName, getTranslationKey, getWeakRedstonePower, harvest, hasBlockEntity, hasCollision, hasCollision, hasComparatorOutput, hasStats, isEqualTo, isFire, isFlowerPot, isFullBlock, isFullCube, isLeafBlock, isNormalBlock, isReplaceable, isSideInvisible, isTransluscent, method_655, method_696, onBlockBreak, onBlockBreakStart, onBreakByPlayer, onBreakByPlayer, onBreaking, onCreation, onDestroyedByExplosion, onEntityCollision, onEntityCollision, onEvent, onLandedUpon, onPlaced, onSteppedOn, onUpdateTick, onUse, rainTick, randomDisplayTick, randomDropAsItem, requiresSilkTouch, setBlockItemBounds, setBoundingBox, setBoundingBox, setDefaultState, setEntityVelocity, setItemGroup, setLightLevel, setOpacity, setResistance, setSound, setStrength, setTickRandomly, setTranslationKey, setUnbreakable, setup, shouldDropItemsOnExplosion, stateFromData, ticksRandomly, toString, usesNeighbourLight
-
Constructor Details
-
PlantBlock
protected PlantBlock() -
PlantBlock
- Parameters:
material- The block's material- Mappings:
Namespace Name Mixin selector official <init>Lafh;<init>(Larm;)Vintermediary <init>Lnet/minecraft/class_160;<init>(Lnet/minecraft/class_591;)Vnamed <init>Lnet/minecraft/block/Block;<init>(Lnet/minecraft/block/Material;)V
-
PlantBlock
- Parameters:
material- The block's materialcolor- The block's material color- Mappings:
Namespace Name Mixin selector official <init>Lafh;<init>(Larm;Larn;)Vintermediary <init>Lnet/minecraft/class_160;<init>(Lnet/minecraft/class_591;Lnet/minecraft/class_592;)Vnamed <init>Lnet/minecraft/block/Block;<init>(Lnet/minecraft/block/Material;Lnet/minecraft/block/MaterialColor;)V
-
-
Method Details
-
canBePlacedAtPos
Returns whether the current block can be placed at a certainBlockPos- Overrides:
canBePlacedAtPosin classBlock- Returns:
- Whether the current block can be placed at a BlockPos
- Mappings:
Namespace Name Mixin selector official dLafh;d(Ladm;Lcj;)Zintermediary method_711Lnet/minecraft/class_160;method_711(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;)Znamed canBePlacedAtPosLnet/minecraft/block/Block;canBePlacedAtPos(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;)Z
-
canPlantOnTop
- Mappings:
Namespace Name Mixin selector official cLafm;c(Lafh;)Zintermediary method_753Lnet/minecraft/class_167;method_753(Lnet/minecraft/class_160;)Znamed canPlantOnTopLnet/minecraft/block/PlantBlock;canPlantOnTop(Lnet/minecraft/block/Block;)Z
-
neighborUpdate
Runs when its adjacent blocks are updated. It will also run when the block is placed or removed as Air is being updated.- Overrides:
neighborUpdatein classBlock- Parameters:
world- The world that the block is placed inpos- The block's positionstate- The block's BlockStateblock- The adjacent Block that updated the current block- Mappings:
Namespace Name Mixin selector official aLafh;a(Ladm;Lcj;Lalz;Lafh;)Vintermediary method_648Lnet/minecraft/class_160;method_648(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;Lnet/minecraft/class_160;)Vnamed neighborUpdateLnet/minecraft/block/Block;neighborUpdate(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Lnet/minecraft/block/Block;)V
-
scheduledTick
Runs when the block is updated as per a schedule- Overrides:
scheduledTickin classBlock- Parameters:
world- The world that the block is placed inpos- The block's positionstate- The block's BlockStaterand- Random object- Mappings:
Namespace Name Mixin selector official bLafh;b(Ladm;Lcj;Lalz;Ljava/util/Random;)Vintermediary method_690Lnet/minecraft/class_160;method_690(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;Ljava/util/Random;)Vnamed scheduledTickLnet/minecraft/block/Block;scheduledTick(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Ljava/util/Random;)V
-
method_754
- Mappings:
Namespace Name Mixin selector official eLafm;e(Ladm;Lcj;Lalz;)Vintermediary method_754Lnet/minecraft/class_167;method_754(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;)Vnamed method_754Lnet/minecraft/block/PlantBlock;method_754(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)V
-
method_755
- Mappings:
Namespace Name Mixin selector official fLafm;f(Ladm;Lcj;Lalz;)Zintermediary method_755Lnet/minecraft/class_167;method_755(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;)Znamed method_755Lnet/minecraft/block/PlantBlock;method_755(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)Z
-
getCollisionBox
Returns a box by adding the block's current location and the block's corresponding value in its Bounding Box- Overrides:
getCollisionBoxin classBlock- Parameters:
world- The world that the block has been placedpos- The block's positionstate- The block's BlockState- Returns:
- The Collision box
- Mappings:
Namespace Name Mixin selector official aLafh;a(Ladm;Lcj;Lalz;)Laug;intermediary method_645Lnet/minecraft/class_160;method_645(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;)Lnet/minecraft/class_646;named getCollisionBoxLnet/minecraft/block/Block;getCollisionBox(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)Lnet/minecraft/util/math/Box;
-
hasTransperancy
public boolean hasTransperancy()- Overrides:
hasTransperancyin classBlock- Mappings:
Namespace Name Mixin selector official cLafh;c()Zintermediary method_699Lnet/minecraft/class_160;method_699()Znamed hasTransperancyLnet/minecraft/block/Block;hasTransperancy()Z
-
renderAsNormalBlock
public boolean renderAsNormalBlock()Returns whether the block can be rendered as a normal block- Overrides:
renderAsNormalBlockin classBlock- Returns:
- Whether the block can be rendered as a normal block
- Mappings:
Namespace Name Mixin selector official dLafh;d()Zintermediary method_709Lnet/minecraft/class_160;method_709()Znamed renderAsNormalBlockLnet/minecraft/block/Block;renderAsNormalBlock()Z
-
getRenderLayerType
Returns the appropriate RenderLayer for a block. Only called on the client.- Overrides:
getRenderLayerTypein classBlock- Returns:
- The block's RenderLayer
- Mappings:
Namespace Name Mixin selector official mLafh;m()Ladf;intermediary method_731Lnet/minecraft/class_160;method_731()Lnet/minecraft/class_91;named getRenderLayerTypeLnet/minecraft/block/Block;getRenderLayerType()Lnet/minecraft/client/render/RenderLayer;
-