net.minecraft.world.item

public class Item

implements ItemLike

bzw
net.minecraft.world.item.Item
net.minecraft.class_1792
net.minecraft.item.Item
net.minecraft.src.C_1381_
net.minecraft.world.item.Item

Field summary

Modifier and TypeField
private static final org.slf4j.Logger
a
LOGGER
field_27017
LOGGER
f_150883_
public static final Map<Block, Item>
k
BY_BLOCK
field_8003
BLOCK_ITEMS
f_41373_
protected static final UUID
l
BASE_ATTACK_DAMAGE_UUID
field_8006
ATTACK_DAMAGE_MODIFIER_ID
f_41374_
protected static final UUID
m
BASE_ATTACK_SPEED_UUID
field_8001
ATTACK_SPEED_MODIFIER_ID
f_41375_
public static final int
n
MAX_STACK_SIZE
field_30887
DEFAULT_MAX_COUNT
f_150884_
public static final int
o
EAT_DURATION
field_30888
field_30888
f_150885_
public static final int
p
MAX_BAR_WIDTH
field_30889
field_30889
f_150886_
private final Holder$Reference<Item>
b
builtInRegistryHolder
field_36401
registryEntry
f_204113_
protected final CreativeModeTab
q
category
field_8004
group
f_41377_
private final Rarity
c
rarity
field_8009
rarity
f_41369_
private final int
d
maxStackSize
field_8013
maxCount
f_41370_
private final int
e
maxDamage
field_8012
maxDamage
f_41371_
private final boolean
f
isFireResistant
field_21979
fireproof
f_41372_
private final Item
g
craftingRemainingItem
field_8008
recipeRemainder
f_41378_
private String
h
descriptionId
field_8014
translationKey
f_41379_
private final FoodProperties
i
foodProperties
field_18672
foodComponent
f_41380_

Constructor summary

ModifierConstructor
public (Item$Properties settings)

Method summary

Modifier and TypeMethod
public static int
a(bzw arg0)
getId(Item arg0)
method_7880(class_1792 arg0)
getRawId(Item item)
m_41393_(C_1381_ p_41394_)
public static Item
b(int arg0)
byId(int arg0)
method_7875(int arg0)
byRawId(int id)
m_41445_(int p_41446_)
public static Item
a(ciw arg0)
byBlock(Block arg0)
method_7867(class_2248 arg0)
fromBlock(Block block)
m_41439_(C_1706_ p_41440_)
public Holder$Reference<Item>
k()
builtInRegistryHolder()
method_40131()
getRegistryEntry()
m_204114_()
public void
a(cga arg0, bbf arg1, caa arg2, int arg3)
onUseTick(Level arg0, LivingEntity arg1, ItemStack arg2, int arg3)
method_7852(class_1937 arg0, class_1309 arg1, class_1799 arg2, int arg3)
usageTick(World world, LivingEntity user, ItemStack stack, int remainingUseTicks)
m_5929_(C_1596_ p_41429_, C_524_ p_41430_, C_1391_ p_41431_, int arg3)
public void
a(bpy arg0)
onDestroyed(ItemEntity arg0)
method_33261(class_1542 arg0)
onItemEntityDestroyed(ItemEntity entity)
m_142023_(C_976_ arg0)
public void
b(pj arg0)
verifyTagAfterLoad(CompoundTag arg0)
method_7860(class_2487 arg0)
postProcessNbt(NbtCompound nbt)
m_142312_(C_4917_ arg0)
public boolean
a(cur arg0, cga arg1, gt arg2, btf arg3)
canAttackBlock(BlockState arg0, Level arg1, BlockPos arg2, Player arg3)
method_7885(class_2680 arg0, class_1937 arg1, class_2338 arg2, class_1657 arg3)
canMine(BlockState state, World world, BlockPos pos, PlayerEntity miner)
m_6777_(C_2064_ p_41442_, C_1596_ p_41443_, C_4675_ p_41444_, C_1141_ arg3)
public Item
l()
asItem()
method_8389()
asItem()
m_5456_()
public InteractionResult
a(ccc arg0)
useOn(UseOnContext arg0)
method_7884(class_1838 arg0)
useOnBlock(ItemUsageContext context)
m_6225_(C_1450_ arg0)
public float
a(caa arg0, cur arg1)
getDestroySpeed(ItemStack arg0, BlockState arg1)
method_7865(class_1799 arg0, class_2680 arg1)
getMiningSpeedMultiplier(ItemStack stack, BlockState state)
m_8102_(C_1391_ p_41426_, C_2064_ arg1)
public InteractionResultHolder<ItemStack>
a(cga arg0, btf arg1, azl arg2)
use(Level arg0, Player arg1, InteractionHand arg2)
method_7836(class_1937 arg0, class_1657 arg1, class_1268 arg2)
use(World world, PlayerEntity user, Hand hand)
m_7203_(C_1596_ p_41433_, C_1141_ p_41434_, C_470_ arg2)
public ItemStack
a(caa arg0, cga arg1, bbf arg2)
finishUsingItem(ItemStack arg0, Level arg1, LivingEntity arg2)
method_7861(class_1799 arg0, class_1937 arg1, class_1309 arg2)
finishUsing(ItemStack stack, World world, LivingEntity user)
m_5922_(C_1391_ p_41410_, C_1596_ p_41411_, C_524_ arg2)
public final int
m()
getMaxStackSize()
method_7882()
getMaxCount()
m_41459_()
public final int
n()
getMaxDamage()
method_7841()
getMaxDamage()
m_41462_()
public boolean
o()
canBeDepleted()
method_7846()
isDamageable()
m_41465_()
public boolean
e(caa arg0)
isBarVisible(ItemStack arg0)
method_31567(class_1799 arg0)
isItemBarVisible(ItemStack stack)
m_142522_(C_1391_ arg0)
public int
f(caa arg0)
getBarWidth(ItemStack arg0)
method_31569(class_1799 arg0)
getItemBarStep(ItemStack stack)
m_142158_(C_1391_ arg0)
public int
g(caa arg0)
getBarColor(ItemStack arg0)
method_31571(class_1799 arg0)
getItemBarColor(ItemStack stack)
m_142159_(C_1391_ arg0)
public boolean
a(caa arg0, bxg arg1, bvx arg2, btf arg3)
overrideStackedOnOther(ItemStack arg0, Slot arg1, ClickAction arg2, Player arg3)
method_31565(class_1799 arg0, class_1735 arg1, class_5536 arg2, class_1657 arg3)
onStackClicked(ItemStack stack, Slot slot, ClickType clickType, PlayerEntity player)
m_142207_(C_1391_ p_150889_, C_1305_ p_150890_, C_141163_ p_150891_, C_1141_ arg3)
public boolean
a(caa arg0, caa arg1, bxg arg2, bvx arg3, btf arg4, bbw arg5)
overrideOtherStackedOnMe(ItemStack arg0, ItemStack arg1, Slot arg2, ClickAction arg3, Player arg4, SlotAccess arg5)
method_31566(class_1799 arg0, class_1799 arg1, class_1735 arg2, class_5536 arg3, class_1657 arg4, class_5630 arg5)
onClicked(ItemStack stack, ItemStack otherStack, Slot slot, ClickType clickType, PlayerEntity player, StackReference cursorStackReference)
m_142305_(C_1391_ p_150893_, C_1391_ p_150894_, C_1305_ p_150895_, C_141163_ p_150896_, C_1141_ p_150897_, C_141073_ arg5)
public boolean
a(caa arg0, bbf arg1, bbf arg2)
hurtEnemy(ItemStack arg0, LivingEntity arg1, LivingEntity arg2)
method_7873(class_1799 arg0, class_1309 arg1, class_1309 arg2)
postHit(ItemStack stack, LivingEntity target, LivingEntity attacker)
m_7579_(C_1391_ p_41396_, C_524_ p_41397_, C_524_ arg2)
public boolean
a(caa arg0, cga arg1, cur arg2, gt arg3, bbf arg4)
mineBlock(ItemStack arg0, Level arg1, BlockState arg2, BlockPos arg3, LivingEntity arg4)
method_7879(class_1799 arg0, class_1937 arg1, class_2680 arg2, class_2338 arg3, class_1309 arg4)
postMine(ItemStack stack, World world, BlockState state, BlockPos pos, LivingEntity miner)
m_6813_(C_1391_ p_41417_, C_1596_ p_41418_, C_2064_ p_41419_, C_4675_ p_41420_, C_524_ arg4)
public boolean
a_(cur arg0)
isCorrectToolForDrops(BlockState arg0)
method_7856(class_2680 arg0)
isSuitableFor(BlockState state)
m_8096_(C_2064_ arg0)
public InteractionResult
a(caa arg0, btf arg1, bbf arg2, azl arg3)
interactLivingEntity(ItemStack arg0, Player arg1, LivingEntity arg2, InteractionHand arg3)
method_7847(class_1799 arg0, class_1657 arg1, class_1309 arg2, class_1268 arg3)
useOnEntity(ItemStack stack, PlayerEntity user, LivingEntity entity, Hand hand)
m_6880_(C_1391_ p_41399_, C_1141_ p_41400_, C_524_ p_41401_, C_470_ arg3)
public Component
p()
getDescription()
method_7848()
getName()
m_41466_()
protected String
q()
getOrCreateDescriptionId()
method_7869()
getOrCreateTranslationKey()
m_41467_()
public String
a()
getDescriptionId()
method_7876()
getTranslationKey()
m_5524_()
public String
j(caa arg0)
getDescriptionId(ItemStack arg0)
method_7866(class_1799 arg0)
getTranslationKey(ItemStack stack)
m_5671_(C_1391_ arg0)
public boolean
r()
shouldOverrideMultiplayerNbt()
method_7887()
isNbtSynced()
m_41468_()
public final Item
s()
getCraftingRemainingItem()
method_7858()
getRecipeRemainder()
m_41469_()
public boolean
t()
hasCraftingRemainingItem()
method_7857()
hasRecipeRemainder()
m_41470_()
public void
a(caa arg0, cga arg1, baq arg2, int arg3, boolean arg4)
inventoryTick(ItemStack arg0, Level arg1, Entity arg2, int arg3, boolean arg4)
method_7888(class_1799 arg0, class_1937 arg1, class_1297 arg2, int arg3, boolean arg4)
inventoryTick(ItemStack stack, World world, Entity entity, int slot, boolean selected)
m_6883_(C_1391_ p_41405_, C_1596_ p_41406_, C_507_ p_41407_, int p_41408_, boolean arg4)
public void
b(caa arg0, cga arg1, btf arg2)
onCraftedBy(ItemStack arg0, Level arg1, Player arg2)
method_7843(class_1799 arg0, class_1937 arg1, class_1657 arg2)
onCraft(ItemStack stack, World world, PlayerEntity player)
m_7836_(C_1391_ p_41448_, C_1596_ p_41449_, C_1141_ arg2)
public boolean
Q_()
isComplex()
method_16698()
isNetworkSynced()
m_7807_()
public UseAnim
c(caa arg0)
getUseAnimation(ItemStack arg0)
method_7853(class_1799 arg0)
getUseAction(ItemStack stack)
m_6164_(C_1391_ arg0)
public int
b(caa arg0)
getUseDuration(ItemStack arg0)
method_7881(class_1799 arg0)
getMaxUseTime(ItemStack stack)
m_8105_(C_1391_ arg0)
public void
a(caa arg0, cga arg1, bbf arg2, int arg3)
releaseUsing(ItemStack arg0, Level arg1, LivingEntity arg2, int arg3)
method_7840(class_1799 arg0, class_1937 arg1, class_1309 arg2, int arg3)
onStoppedUsing(ItemStack stack, World world, LivingEntity user, int remainingUseTicks)
m_5551_(C_1391_ p_41413_, C_1596_ p_41414_, C_524_ p_41415_, int arg3)
public void
a(caa arg0, cga arg1, List<rm> arg2, cbo arg3)
appendHoverText(ItemStack arg0, Level arg1, List<Component> arg2, TooltipFlag arg3)
method_7851(class_1799 arg0, class_1937 arg1, List<class_2561> arg2, class_1836 arg3)
appendTooltip(ItemStack stack, World world, List<Text> tooltip, TooltipContext context)
m_7373_(C_1391_ p_41422_, C_1596_ p_41423_, List<C_4996_> p_41424_, C_1431_ arg3)
public Optional<TooltipComponent>
h(caa arg0)
getTooltipImage(ItemStack arg0)
method_32346(class_1799 arg0)
getTooltipData(ItemStack stack)
m_142422_(C_1391_ arg0)
public Component
m(caa arg0)
getName(ItemStack arg0)
method_7864(class_1799 arg0)
getName(ItemStack stack)
m_7626_(C_1391_ arg0)
public boolean
i(caa arg0)
isFoil(ItemStack arg0)
method_7886(class_1799 arg0)
hasGlint(ItemStack stack)
m_5812_(C_1391_ arg0)
public Rarity
n(caa arg0)
getRarity(ItemStack arg0)
method_7862(class_1799 arg0)
getRarity(ItemStack stack)
m_41460_(C_1391_ arg0)
public boolean
c_(caa arg0)
isEnchantable(ItemStack arg0)
method_7870(class_1799 arg0)
isEnchantable(ItemStack stack)
m_8120_(C_1391_ arg0)
protected static BlockHitResult
a(cga arg0, btf arg1, cfj$b arg2)
getPlayerPOVHitResult(Level arg0, Player arg1, ClipContext$Fluid arg2)
method_7872(class_1937 arg0, class_1657 arg1, class_3959$class_242 arg2)
raycast(World world, PlayerEntity player, RaycastContext$FluidHandling fluidHandling)
m_41435_(C_1596_ p_41436_, C_1141_ p_41437_, C_1567_ p_41438_)
public int
c()
getEnchantmentValue()
method_7837()
getEnchantability()
m_6473_()
public void
a(bym arg0, hi<caa> arg1)
fillItemCategory(CreativeModeTab arg0, NonNullList<ItemStack> arg1)
method_7850(class_1761 arg0, class_2371<class_1799> arg1)
appendStacks(ItemGroup group, DefaultedList<ItemStack> stacks)
m_6787_(C_1336_ p_41392_, C_4702_<C_1391_> arg1)
protected boolean
a(bym arg0)
allowedIn(CreativeModeTab arg0)
method_7877(class_1761 arg0)
isIn(ItemGroup group)
m_220152_(C_1336_ arg0)
public final CreativeModeTab
u()
getItemCategory()
method_7859()
getGroup()
m_41471_()
public boolean
a(caa arg0, caa arg1)
isValidRepairItem(ItemStack arg0, ItemStack arg1)
method_7878(class_1799 arg0, class_1799 arg1)
canRepair(ItemStack stack, ItemStack ingredient)
m_6832_(C_1391_ p_41403_, C_1391_ arg1)
public com.google.common.collect.Multimap<Attribute, AttributeModifier>
a(bav arg0)
getDefaultAttributeModifiers(EquipmentSlot arg0)
method_7844(class_1304 arg0)
getAttributeModifiers(EquipmentSlot slot)
m_7167_(C_516_ arg0)
public boolean
l(caa arg0)
useOnRelease(ItemStack arg0)
method_7838(class_1799 arg0)
isUsedOnRelease(ItemStack stack)
m_41463_(C_1391_ arg0)
public ItemStack
R_()
getDefaultInstance()
method_7854()
getDefaultStack()
m_7968_()
public boolean
v()
isEdible()
method_19263()
isFood()
m_41472_()
public FoodProperties
w()
getFoodProperties()
method_19264()
getFoodComponent()
m_41473_()
public SoundEvent
S_()
getDrinkingSound()
method_21831()
getDrinkSound()
m_6023_()
public SoundEvent
h()
getEatingSound()
method_21830()
getEatSound()
m_6061_()
public boolean
x()
isFireResistant()
method_24358()
isFireproof()
m_41475_()
public boolean
a(azz arg0)
canBeHurtBy(DamageSource arg0)
method_24357(class_1282 arg0)
damage(DamageSource source)
m_41386_(C_489_ arg0)
public SoundEvent
g()
getEquipSound()
method_31570()
getEquipSound()
m_142602_()
public boolean
T_()
canFitInsideContainerItems()
method_31568()
canBeNested()
m_142095_()