Package net.minecraft.block
Class TorchBlock
java.lang.Object
net.minecraft.block.Block
net.minecraft.block.TorchBlock
- Direct Known Subclasses:
RedstoneTorchBlock
public class TorchBlock extends Block
- Mappings:
Namespace Name official akfintermediary net/minecraft/class_327named net/minecraft/block/TorchBlock
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.block.Block
Block.OffsetType, Block.Sound -
Field Summary
Fields Modifier and Type Field Description static DirectionPropertyFACINGFields 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 protectedTorchBlock() -
Method Summary
Modifier and Type Method Description protected StateManagerappendProperties()Returns a new state manager with a property array.booleancanBePlacedAtPos(World world, BlockPos pos)Returns whether the current block can be placed at a certainBlockPosBoxgetCollisionBox(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 BoxintgetData(BlockState state)Returns the data value for a blockstate Throws anIllegalArmumentExceptionas this method does not workRenderLayergetRenderLayerType()Returns the appropriate RenderLayer for a block.BlockStategetStateFromData(World world, BlockPos pos, Direction dir, float float2, float float3, float float4, int id, LivingEntity entity)Returns a BlockState from an idbooleanhasTransperancy()private booleanmethod_1035(World world, BlockPos blockPos, Direction direction)private booleanmethod_1036(World world, BlockPos blockPos)protected booleanmethod_1037(World world, BlockPos blockPos, BlockState blockState)protected booleanmethod_1038(World world, BlockPos blockPos, BlockState blockState)HitResultmethod_655(World world, BlockPos pos, Vec3d vec1, Vec3d vec2)voidneighborUpdate(World world, BlockPos pos, BlockState state, Block block)Runs when its adjacent blocks are updated.voidonCreation(World world, BlockPos pos, BlockState state)Runs when the block is placed (by a player or enderman).voidrandomDisplayTick(World world, BlockPos pos, BlockState state, Random rand)Runs every random display Tick.booleanrenderAsNormalBlock()Returns whether the block can be rendered as a normal blockBlockStatestateFromData(int data)Returns a blockstate of the current block from it's idMethods inherited from class net.minecraft.block.Block
appendCollisionBoxes, appendItemStacks, 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, getDefaultState, getDropCount, getDropItem, getIdByBlock, getItemGroup, getLightLevel, getMaterial, getMaterialColor, getMaxX, getMaxY, getMaxZ, getMeta, getMeta, getMinX, getMinY, getMinZ, getOffsetType, getOpacity, getPickItem, getPistonInteractionType, getSelectionBox, 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_696, onBlockBreak, onBlockBreakStart, onBreakByPlayer, onBreakByPlayer, onBreaking, onDestroyedByExplosion, onEntityCollision, onEntityCollision, onEvent, onLandedUpon, onPlaced, onSteppedOn, onUpdateTick, onUse, rainTick, randomDropAsItem, requiresSilkTouch, scheduledTick, setBlockItemBounds, setBoundingBox, setBoundingBox, setDefaultState, setEntityVelocity, setItemGroup, setLightLevel, setOpacity, setResistance, setSound, setStrength, setTickRandomly, setTranslationKey, setUnbreakable, setup, shouldDropItemsOnExplosion, ticksRandomly, toString, usesNeighbourLight
-
Field Details
-
FACING
- Mappings:
Namespace Name Mixin selector official aLakf;a:Laml;intermediary field_1276Lnet/minecraft/class_327;field_1276:Lnet/minecraft/class_389;named FACINGLnet/minecraft/block/TorchBlock;FACING:Lnet/minecraft/state/property/DirectionProperty;
-
-
Constructor Details
-
TorchBlock
protected TorchBlock()
-
-
Method Details
-
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
-
method_1036
- Mappings:
Namespace Name Mixin selector official eLakf;e(Ladm;Lcj;)Zintermediary method_1036Lnet/minecraft/class_327;method_1036(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;)Znamed method_1036Lnet/minecraft/block/TorchBlock;method_1036(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;)Z
-
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
-
method_1035
- Mappings:
Namespace Name Mixin selector official aLakf;a(Ladm;Lcj;Lcq;)Zintermediary method_1035Lnet/minecraft/class_327;method_1035(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_1383;)Znamed method_1035Lnet/minecraft/block/TorchBlock;method_1035(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/util/math/Direction;)Z
-
getStateFromData
public BlockState getStateFromData(World world, BlockPos pos, Direction dir, float float2, float float3, float float4, int id, LivingEntity entity)Returns a BlockState from an id- Overrides:
getStateFromDatain classBlock- Parameters:
world- The world that the block is placed inpos- The block's positiondir- The block's direction- Mappings:
Namespace Name Mixin selector official aLafh;a(Ladm;Lcj;Lcq;FFFILpr;)Lalz;intermediary method_656Lnet/minecraft/class_160;method_656(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_1383;FFFILnet/minecraft/class_1752;)Lnet/minecraft/class_376;named getStateFromDataLnet/minecraft/block/Block;getStateFromData(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/util/math/Direction;FFFILnet/minecraft/entity/LivingEntity;)Lnet/minecraft/block/BlockState;
-
onCreation
Runs when the block is placed (by a player or enderman).- Overrides:
onCreationin classBlock- Parameters:
world- The world that the block is placed inpos- The block's positionstate- The block's BlockState- Mappings:
Namespace Name Mixin selector official cLafh;c(Ladm;Lcj;Lalz;)Vintermediary method_703Lnet/minecraft/class_160;method_703(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;)Vnamed onCreationLnet/minecraft/block/Block;onCreation(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)V
-
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
-
method_1037
- Mappings:
Namespace Name Mixin selector official eLakf;e(Ladm;Lcj;Lalz;)Zintermediary method_1037Lnet/minecraft/class_327;method_1037(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;)Znamed method_1037Lnet/minecraft/block/TorchBlock;method_1037(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)Z
-
method_1038
- Mappings:
Namespace Name Mixin selector official fLakf;f(Ladm;Lcj;Lalz;)Zintermediary method_1038Lnet/minecraft/class_327;method_1038(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;)Znamed method_1038Lnet/minecraft/block/TorchBlock;method_1038(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;)Z
-
method_655
- Overrides:
method_655in classBlock- Mappings:
Namespace Name Mixin selector official aLafh;a(Ladm;Lcj;Laui;Laui;)Lauh;intermediary method_655Lnet/minecraft/class_160;method_655(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_649;Lnet/minecraft/class_649;)Lnet/minecraft/class_647;named method_655Lnet/minecraft/block/Block;method_655(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/util/math/Vec3d;Lnet/minecraft/util/math/Vec3d;)Lnet/minecraft/util/hit/HitResult;
-
randomDisplayTick
@Environment(CLIENT) public void randomDisplayTick(World world, BlockPos pos, BlockState state, Random rand)Runs every random display Tick. Useful for displaying particles around a block, like Redstone Ore.- Overrides:
randomDisplayTickin 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 cLafh;c(Ladm;Lcj;Lalz;Ljava/util/Random;)Vintermediary method_704Lnet/minecraft/class_160;method_704(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;Ljava/util/Random;)Vnamed randomDisplayTickLnet/minecraft/block/Block;randomDisplayTick(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Ljava/util/Random;)V
-
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;
-
stateFromData
Returns a blockstate of the current block from it's id- Overrides:
stateFromDatain classBlock- Parameters:
data- The Blockstate's associated data value- Returns:
- The Default state
- Mappings:
Namespace Name Mixin selector official aLafh;a(I)Lalz;intermediary method_637Lnet/minecraft/class_160;method_637(I)Lnet/minecraft/class_376;named stateFromDataLnet/minecraft/block/Block;stateFromData(I)Lnet/minecraft/block/BlockState;
-
getData
Returns the data value for a blockstate Throws anIllegalArmumentExceptionas this method does not work- Overrides:
getDatain classBlock- Parameters:
state- The Blockstate- Returns:
- Zero
- Mappings:
Namespace Name Mixin selector official cLafh;c(Lalz;)Iintermediary method_706Lnet/minecraft/class_160;method_706(Lnet/minecraft/class_376;)Inamed getDataLnet/minecraft/block/Block;getData(Lnet/minecraft/block/BlockState;)I
-
appendProperties
Returns a new state manager with a property array.- Overrides:
appendPropertiesin classBlock- Returns:
- New state manager
- Mappings:
Namespace Name Mixin selector official eLafh;e()Lama;intermediary method_714Lnet/minecraft/class_160;method_714()Lnet/minecraft/class_378;named appendPropertiesLnet/minecraft/block/Block;appendProperties()Lnet/minecraft/state/StateManager;
-