Package net.minecraft.item
Class BookItem
java.lang.Object
net.minecraft.item.Item
net.minecraft.item.BookItem
- All Implemented Interfaces:
ItemConvertible
,ToggleableFeature
- Mappings:
Namespace Name named net/minecraft/item/BookItem
intermediary net/minecraft/class_1751
official csr
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.item.Item
Item.Settings, Item.TooltipContext
-
Field Summary
Fields inherited from class net.minecraft.item.Item
BASE_ATTACK_DAMAGE_MODIFIER_ID, BASE_ATTACK_SPEED_MODIFIER_ID, BLOCK_ITEMS, DEFAULT_MAX_COUNT, ITEM_BAR_STEPS, MAX_MAX_COUNT
Fields inherited from interface net.minecraft.resource.featuretoggle.ToggleableFeature
FEATURE_ENABLED_REGISTRY_KEYS
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
Gets the enchantability of an item.boolean
isEnchantable
(ItemStack stack) Returns whether the givenItemStack
is enchantable.Methods inherited from class net.minecraft.item.Item
appendTooltip, asItem, byRawId, canBeNested, canMine, canRepair, finishUsing, fromBlock, getAttributeModifiers, getBonusAttackDamage, getBreakSound, getComponents, getDefaultStack, getDrinkSound, getEatSound, getItemBarColor, getItemBarStep, getMaxCount, getMaxUseTime, getMiningSpeed, getName, getName, getOrCreateTranslationKey, getRawId, getRecipeRemainder, getRegistryEntry, getRequiredFeatures, getTooltipData, getTranslationKey, getTranslationKey, getUseAction, hasGlint, hasRecipeRemainder, inventoryTick, isCorrectForDrops, isItemBarVisible, isNetworkSynced, isUsedOnRelease, onClicked, onCraft, onCraftByPlayer, onItemEntityDestroyed, onStackClicked, onStoppedUsing, postDamageEntity, postHit, postMine, postProcessComponents, raycast, toString, usageTick, use, useOnBlock, useOnEntity
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface net.minecraft.resource.featuretoggle.ToggleableFeature
isEnabled
-
Constructor Details
-
BookItem
- Mappings:
Namespace Name Mixin selector named <init>
Lnet/minecraft/item/Item;<init>(Lnet/minecraft/item/Item$Settings;)V
intermediary <init>
Lnet/minecraft/class_1792;<init>(Lnet/minecraft/class_1792$class_1793;)V
official <init>
Lcul;<init>(Lcul$a;)V
-
-
Method Details
-
isEnchantable
Returns whether the givenItemStack
is enchantable.By default, ItemStacks are enchantable if their max stack count is 1 and they can be damaged.
- Overrides:
isEnchantable
in classItem
- Returns:
- whether the given
ItemStack
is enchantable - Mappings:
Namespace Name Mixin selector named isEnchantable
Lnet/minecraft/item/Item;isEnchantable(Lnet/minecraft/item/ItemStack;)Z
intermediary method_7870
Lnet/minecraft/class_1792;method_7870(Lnet/minecraft/class_1799;)Z
official a
Lcul;a(Lcuq;)Z
-
getEnchantability
public int getEnchantability()Gets the enchantability of an item. This specifies the ability of an item to receive enchantments when enchanted using an enchanting table. As the value increases, the amount and level of enchantments applied increase.If the value of this method is 0, the item cannot be enchanted using an enchanting table.
- Overrides:
getEnchantability
in classItem
- Mappings:
Namespace Name Mixin selector named getEnchantability
Lnet/minecraft/item/Item;getEnchantability()I
intermediary method_7837
Lnet/minecraft/class_1792;method_7837()I
official g
Lcul;g()I
-