Package net.minecraft.item
Class BlockItem
java.lang.Object
net.minecraftforge.registries.ForgeRegistryEntry<Item>
net.minecraft.item.Item
net.minecraft.item.BlockItem
- All Implemented Interfaces:
IItemProvider
,IForgeItem
,IForgeRegistryEntry<Item>
- Direct Known Subclasses:
BedItem
,BlockNamedItem
,LilyPadItem
,OperatorOnlyItem
,ScaffoldingItem
,TallBlockItem
,WallOrFloorItem
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.item.Item
Item.Properties
Nested classes/interfaces inherited from class net.minecraftforge.registries.ForgeRegistryEntry
ForgeRegistryEntry.UncheckedRegistryEntry<V extends IForgeRegistryEntry<V>>
-
Field Summary
Fields inherited from class net.minecraft.item.Item
BASE_ATTACK_DAMAGE_UUID, BASE_ATTACK_SPEED_UUID, BY_BLOCK, canRepair, category, random
Fields inherited from class net.minecraftforge.registries.ForgeRegistryEntry
delegate
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
appendHoverText
(ItemStack p_77624_1_, World p_77624_2_, List<ITextComponent> p_77624_3_, ITooltipFlag p_77624_4_) protected boolean
canPlace
(BlockItemUseContext p_195944_1_, BlockState p_195944_2_) void
fillItemCategory
(ItemGroup p_150895_1_, NonNullList<ItemStack> p_150895_2_) getBlock()
private Block
protected BlockState
getPlacementState
(BlockItemUseContext p_195945_1_) protected SoundEvent
getPlaceSound
(BlockState p_219983_1_) Deprecated.protected SoundEvent
getPlaceSound
(BlockState state, World world, BlockPos pos, PlayerEntity entity) protected boolean
place
(BlockItemUseContext p_195942_1_) protected boolean
placeBlock
(BlockItemUseContext p_195941_1_, BlockState p_195941_2_) void
registerBlocks
(Map<Block, Item> p_195946_1_, Item p_195946_2_) void
removeFromBlockToItemMap
(Map<Block, Item> blockToItemMap, Item itemIn) private BlockState
updateBlockStateFromTag
(BlockPos p_219985_1_, World p_219985_2_, ItemStack p_219985_3_, BlockState p_219985_4_) protected boolean
updateCustomBlockEntityTag
(BlockPos p_195943_1_, World p_195943_2_, PlayerEntity p_195943_3_, ItemStack p_195943_4_, BlockState p_195943_5_) static boolean
updateCustomBlockEntityTag
(World p_179224_0_, PlayerEntity p_179224_1_, BlockPos p_179224_2_, ItemStack p_179224_3_) updatePlacementContext
(BlockItemUseContext p_219984_1_) private static <T extends Comparable<T>>
BlockStateupdateState
(BlockState p_219988_0_, Property<T> p_219988_1_, String p_219988_2_) useOn
(ItemUseContext p_195939_1_) Methods inherited from class net.minecraft.item.Item
allowdedIn, asItem, byBlock, byId, canAttackBlock, canBeDepleted, canBeHurtBy, finishUsingItem, getCraftingRemainingItem, getDefaultAttributeModifiers, getDefaultInstance, getDescription, getDescriptionId, getDestroySpeed, getDrinkingSound, getEatingSound, getEnchantmentValue, getFoodProperties, getHarvestLevel, getId, getItemCategory, getItemStackTileEntityRenderer, getMaxDamage, getMaxStackSize, getName, getOrCreateDescriptionId, getPlayerPOVHitResult, getRarity, getTags, getToolTypes, getUseAnimation, getUseDuration, hasCraftingRemainingItem, hurtEnemy, interactLivingEntity, inventoryTick, is, isComplex, isCorrectToolForDrops, isEdible, isEnchantable, isFireResistant, isFoil, isRepairable, isValidRepairItem, mineBlock, onCraftedBy, onUseTick, releaseUsing, shouldOverrideMultiplayerNbt, toString, use, useOnRelease, verifyTagAfterLoad
Methods inherited from class net.minecraftforge.registries.ForgeRegistryEntry
getRegistryName, getRegistryType, setRegistryName, setRegistryName, setRegistryName
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface net.minecraftforge.common.extensions.IForgeItem
canApplyAtEnchantingTable, canContinueUsing, canDisableShield, canElytraFly, canEquip, canHarvestBlock, createEntity, damageItem, doesSneakBypassUse, elytraFlightTick, getArmorModel, getArmorTexture, getAttributeModifiers, getBurnTime, getBurnTime, getContainerItem, getCreativeTabs, getCreatorModId, getDamage, getDurabilityForDisplay, getEntityLifespan, getEquipmentSlot, getFontRenderer, getHighlightTip, getItem, getItemEnchantability, getItemStackLimit, getMaxDamage, getRGBDurabilityForDisplay, getShareTag, getSmeltingExperience, getXpRepairRatio, hasContainerItem, hasCustomEntity, initCapabilities, isBookEnchantable, isDamageable, isDamaged, isEnderMask, isPiglinCurrency, isShield, makesPiglinsNeutral, onArmorTick, onBlockStartBreak, onDroppedByPlayer, onEntityItemUpdate, onEntitySwing, onHorseArmorTick, onItemUseFirst, onLeftClickEntity, onUsingTick, readShareTag, renderHelmetOverlay, setDamage, shouldCauseBlockBreakReset, shouldCauseReequipAnimation, showDurabilityBar
-
Field Details
-
block
Deprecated.
-
-
Constructor Details
-
BlockItem
-
-
Method Details
-
useOn
-
place
-
getPlaceSound
Deprecated. -
getPlaceSound
protected SoundEvent getPlaceSound(BlockState state, World world, BlockPos pos, PlayerEntity entity) -
updatePlacementContext
-
updateCustomBlockEntityTag
protected boolean updateCustomBlockEntityTag(BlockPos p_195943_1_, World p_195943_2_, @Nullable PlayerEntity p_195943_3_, ItemStack p_195943_4_, BlockState p_195943_5_) -
getPlacementState
-
updateBlockStateFromTag
private BlockState updateBlockStateFromTag(BlockPos p_219985_1_, World p_219985_2_, ItemStack p_219985_3_, BlockState p_219985_4_) -
updateState
private static <T extends Comparable<T>> BlockState updateState(BlockState p_219988_0_, Property<T> p_219988_1_, String p_219988_2_) -
canPlace
-
mustSurvive
protected boolean mustSurvive() -
placeBlock
-
updateCustomBlockEntityTag
public static boolean updateCustomBlockEntityTag(World p_179224_0_, @Nullable PlayerEntity p_179224_1_, BlockPos p_179224_2_, ItemStack p_179224_3_) -
getDescriptionId
- Overrides:
getDescriptionId
in classItem
-
fillItemCategory
- Overrides:
fillItemCategory
in classItem
-
appendHoverText
public void appendHoverText(ItemStack p_77624_1_, @Nullable World p_77624_2_, List<ITextComponent> p_77624_3_, ITooltipFlag p_77624_4_) - Overrides:
appendHoverText
in classItem
-
getBlock
-
getBlockRaw
-
registerBlocks
-
removeFromBlockToItemMap
-