Package net.minecraft.block
Class NoteBlock
java.lang.Object
net.minecraft.block.Block
net.minecraft.block.BlockWithEntity
net.minecraft.block.NoteBlock
- All Implemented Interfaces:
BlockEntityProvider
public class NoteBlock extends BlockWithEntity
- Mappings:
Namespace Name official aiiintermediary net/minecraft/class_260named net/minecraft/block/NoteBlock
-
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 Constructor Description NoteBlock() -
Method Summary
Modifier and Type Method Description BlockEntitycreateBlockEntity(World world, int id)intgetBlockType()private Stringmethod_928(int int2)voidneighborUpdate(World world, BlockPos pos, BlockState state, Block block)Runs when its adjacent blocks are updated.voidonBlockBreakStart(World world, BlockPos pos, PlayerEntity player)booleanonEvent(World world, BlockPos pos, BlockState state, int id, int meta)Runs when an event takes placebooleanonUse(World world, BlockPos pos, BlockState state, PlayerEntity player, Direction direction, float float2, float float3, float float4)Runs when the block is used, i.e.Methods inherited from class net.minecraft.block.BlockWithEntity
method_580, method_581, onBreakingMethods inherited from class net.minecraft.block.Block
appendCollisionBoxes, appendItemStacks, appendProperties, areBlocksEqual, blocksMovement, calcBlockBreakingData, canBePlacedAdjacent, canBePlacedAtPos, canBeReplaced, canCollide, canMobSpawnInside, createStackFromBlock, disableStats, dropAsItem, dropExperience, emitsRedstonePower, get, getAmbientOcclusionLightLevel, getBlastResistance, getBlendColor, getBlockColor, getBlockFromItem, getBlockState, getBonusDrops, getBrightness, getByBlockState, getById, getCollisionBox, getColor, getColor, getComparatorOutput, getData, getDefaultState, getDropCount, getDropItem, getIdByBlock, getItemGroup, getLightLevel, getMaterial, getMaterialColor, getMaxX, getMaxY, getMaxZ, getMeta, getMeta, getMinX, getMinY, getMinZ, getOffsetType, getOpacity, getPickItem, getPistonInteractionType, getRenderLayerType, getSelectionBox, getStateFromData, getStateFromRawId, getStateManager, getStrength, getStrongRedstonePower, getTickRate, getTranslatedName, getTranslationKey, getWeakRedstonePower, harvest, hasBlockEntity, hasCollision, hasCollision, hasComparatorOutput, hasStats, hasTransperancy, isEqualTo, isFire, isFlowerPot, isFullBlock, isFullCube, isLeafBlock, isNormalBlock, isReplaceable, isSideInvisible, isTransluscent, method_655, method_696, onBlockBreak, onBreakByPlayer, onBreakByPlayer, onCreation, onDestroyedByExplosion, onEntityCollision, onEntityCollision, onLandedUpon, onPlaced, onSteppedOn, onUpdateTick, rainTick, randomDisplayTick, randomDropAsItem, renderAsNormalBlock, requiresSilkTouch, scheduledTick, setBlockItemBounds, setBoundingBox, setBoundingBox, setDefaultState, setEntityVelocity, setItemGroup, setLightLevel, setOpacity, setResistance, setSound, setStrength, setTickRandomly, setTranslationKey, setUnbreakable, setup, shouldDropItemsOnExplosion, stateFromData, ticksRandomly, toString, usesNeighbourLight
-
Field Details
-
TUNES
- Mappings:
Namespace Name Mixin selector official aLaii;a:Ljava/util/List;intermediary field_1067Lnet/minecraft/class_260;field_1067:Ljava/util/List;named TUNESLnet/minecraft/block/NoteBlock;TUNES:Ljava/util/List;
-
-
Constructor Details
-
NoteBlock
public NoteBlock()
-
-
Method Details
-
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
-
onUse
public boolean onUse(World world, BlockPos pos, BlockState state, PlayerEntity player, Direction direction, float float2, float float3, float float4)Runs when the block is used, i.e. right clicked in most cases. It is similar to the same method in Item, but this method is called only when the player uses it when the block is placed, not when the player is holding the BlockItem.- Overrides:
onUsein classBlock- Parameters:
world- The world that the block is placed inpos- The block's positionstate- The block's BlockStateplayer- The player who used the blockdirection- The direction that the block is facing- Returns:
- Whether the action is succesful
- Mappings:
Namespace Name Mixin selector official aLafh;a(Ladm;Lcj;Lalz;Lwn;Lcq;FFF)Zintermediary method_654Lnet/minecraft/class_160;method_654(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;Lnet/minecraft/class_1963;Lnet/minecraft/class_1383;FFF)Znamed onUseLnet/minecraft/block/Block;onUse(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;Lnet/minecraft/entity/player/PlayerEntity;Lnet/minecraft/util/math/Direction;FFF)Z
-
onBlockBreakStart
- Overrides:
onBlockBreakStartin classBlock- Mappings:
Namespace Name Mixin selector official aLafh;a(Ladm;Lcj;Lwn;)Vintermediary method_661Lnet/minecraft/class_160;method_661(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_1963;)Vnamed onBlockBreakStartLnet/minecraft/block/Block;onBlockBreakStart(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/entity/player/PlayerEntity;)V
-
createBlockEntity
- Mappings:
Namespace Name Mixin selector official aLagq;a(Ladm;I)Lakw;intermediary method_841Lnet/minecraft/class_205;method_841(Lnet/minecraft/class_99;I)Lnet/minecraft/class_348;named createBlockEntityLnet/minecraft/block/BlockEntityProvider;createBlockEntity(Lnet/minecraft/world/World;I)Lnet/minecraft/block/entity/BlockEntity;
-
method_928
- Mappings:
Namespace Name Mixin selector official bLaii;b(I)Ljava/lang/String;intermediary method_928Lnet/minecraft/class_260;method_928(I)Ljava/lang/String;named method_928Lnet/minecraft/block/NoteBlock;method_928(I)Ljava/lang/String;
-
onEvent
Runs when an event takes place- Overrides:
onEventin classBlockWithEntity- Parameters:
world- The world that the block is placed inpos- The block's positionstate- The block's BlockStateid- Idmeta- Metadata- Returns:
- Whether the event is successful
- Mappings:
Namespace Name Mixin selector official aLafh;a(Ladm;Lcj;Lalz;II)Zintermediary method_647Lnet/minecraft/class_160;method_647(Lnet/minecraft/class_99;Lnet/minecraft/class_1372;Lnet/minecraft/class_376;II)Znamed onEventLnet/minecraft/block/Block;onEvent(Lnet/minecraft/world/World;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/BlockState;II)Z
-
getBlockType
public int getBlockType()- Overrides:
getBlockTypein classBlockWithEntity- Mappings:
Namespace Name Mixin selector official bLafh;b()Iintermediary method_684Lnet/minecraft/class_160;method_684()Inamed getBlockTypeLnet/minecraft/block/Block;getBlockType()I
-