Package net.minecraft.item
Class EnchantedBookItem
java.lang.Object
net.minecraft.item.Item
net.minecraft.item.EnchantedBookItem
- Mappings:
Namespace Name official aaxintermediary net/minecraft/class_1428named net/minecraft/item/EnchantedBookItem
-
Field Summary
Fields inherited from class net.minecraft.item.Item
ATTACK_DAMAGE_MODIFIER_UUID, damageable, field_6201, field_6941, handheld, maxCount, RANDOM, REGISTRY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddEnchantment(ItemStack itemStack, EnchantmentLevelEntry info) voidappendTooltip(ItemStack stack, PlayerEntity player, List lines, boolean advanced) getEnchantmentNbt(ItemStack itemStack) voidgetEnchantments(Enchantment enchantment, List list) Returns the rarity of the current Item.booleanhasEnchantmentGlint(ItemStack stack) Returns whether the current item has an enchantment glint.booleanisEnchantable(ItemStack stack) Returns whether the current item can have enchantments.method_4610(Random random) method_6347(Random random, int int2, int int3, int int4) Methods inherited from class net.minecraft.item.Item
appendItemStacks, byRawId, canRepair, canUseOnEntity, fromBlock, getAttributeModifierMap, getDisplayColor, getDisplayName, getEnchantability, getFromId, getItemGroup, getItemstackTranslatedName, getMaxCount, getMaxDamage, getMaxUseTime, getMeta, getMiningSpeedMultiplier, getRawId, getRecipeRemainder, getStatusEffectString, getTranslationKey, getTranslationKey, getUseAction, hasStatusEffectString, hasSubTypes, inventoryTick, isDamageable, isEffectiveOn, isFood, isHandheld, isNetworkSynced, isUnbreakable, method_3343, method_3355, method_3356, method_3369, method_3378, method_3380, method_3397, method_5462, method_5463, method_6324, onCraft, onEntityHit, onFinishUse, onHit, onStartUse, onUseStopped, setHandheld, setItemGroup, setMaxCount, setMaxDamage, setRecipeRemainder, setStatusEffectString, setTranslationKey, setUnbreakable, setup, shouldRotate, shouldSyncNbtToClient
-
Constructor Details
-
EnchantedBookItem
public EnchantedBookItem()- Mappings:
Namespace Name Mixin selector official <init>Labm;<init>()Vintermediary <init>Lnet/minecraft/class_1069;<init>()Vnamed <init>Lnet/minecraft/item/Item;<init>()V
-
-
Method Details
-
hasEnchantmentGlint
Returns whether the current item has an enchantment glint. Used by enchanted golden apples and enchanted items.- Overrides:
hasEnchantmentGlintin classItem- See Also:
-
net.minecraft.item.GoldenAppleItem
- Mappings:
Namespace Name Mixin selector official eLabm;e(Labo;)Zintermediary method_3374Lnet/minecraft/class_1069;method_3374(Lnet/minecraft/class_1071;)Znamed hasEnchantmentGlintLnet/minecraft/item/Item;hasEnchantmentGlint(Lnet/minecraft/item/ItemStack;)Z
-
isEnchantable
Returns whether the current item can have enchantments. It does this by verifying that the item's maximum stack size is 1 and the item can break.- Overrides:
isEnchantablein classItem- Mappings:
Namespace Name Mixin selector official e_Labm;e_(Labo;)Zintermediary method_3385Lnet/minecraft/class_1069;method_3385(Lnet/minecraft/class_1071;)Znamed isEnchantableLnet/minecraft/item/Item;isEnchantable(Lnet/minecraft/item/ItemStack;)Z
-
getRarity
Returns the rarity of the current Item. Used by golden apples, enchanted items and potions.- Overrides:
getRarityin classItem- Parameters:
stack- The item in an ItemStack form- Returns:
- The rarity of the ItemStack
- See Also:
-
net.minecraft.item.GoldenAppleItemPotionItem
- Mappings:
Namespace Name Mixin selector official fLabm;f(Labo;)Lacb;intermediary method_3377Lnet/minecraft/class_1069;method_3377(Lnet/minecraft/class_1071;)Lnet/minecraft/class_1081;named getRarityLnet/minecraft/item/Item;getRarity(Lnet/minecraft/item/ItemStack;)Lnet/minecraft/util/Rarity;
-
getEnchantmentNbt
- Mappings:
Namespace Name Mixin selector official gLaax;g(Labo;)Ldp;intermediary method_4611Lnet/minecraft/class_1428;method_4611(Lnet/minecraft/class_1071;)Lnet/minecraft/class_474;named getEnchantmentNbtLnet/minecraft/item/EnchantedBookItem;getEnchantmentNbt(Lnet/minecraft/item/ItemStack;)Lnet/minecraft/nbt/NbtList;
-
appendTooltip
@Environment(CLIENT) public void appendTooltip(ItemStack stack, PlayerEntity player, List lines, boolean advanced) - Overrides:
appendTooltipin classItem- Mappings:
Namespace Name Mixin selector official aLabm;a(Labo;Lxk;Ljava/util/List;Z)Vintermediary method_3352Lnet/minecraft/class_1069;method_3352(Lnet/minecraft/class_1071;Lnet/minecraft/class_988;Ljava/util/List;Z)Vnamed appendTooltipLnet/minecraft/item/Item;appendTooltip(Lnet/minecraft/item/ItemStack;Lnet/minecraft/entity/player/PlayerEntity;Ljava/util/List;Z)V
-
addEnchantment
- Mappings:
Namespace Name Mixin selector official aLaax;a(Labo;Laen;)Vintermediary method_4607Lnet/minecraft/class_1428;method_4607(Lnet/minecraft/class_1071;Lnet/minecraft/class_1134;)Vnamed addEnchantmentLnet/minecraft/item/EnchantedBookItem;addEnchantment(Lnet/minecraft/item/ItemStack;Lnet/minecraft/enchantment/EnchantmentLevelEntry;)V
-
getAsItemStack
- Mappings:
Namespace Name Mixin selector official aLaax;a(Laen;)Labo;intermediary method_4609Lnet/minecraft/class_1428;method_4609(Lnet/minecraft/class_1134;)Lnet/minecraft/class_1071;named getAsItemStackLnet/minecraft/item/EnchantedBookItem;getAsItemStack(Lnet/minecraft/enchantment/EnchantmentLevelEntry;)Lnet/minecraft/item/ItemStack;
-
getEnchantments
- Mappings:
Namespace Name Mixin selector official aLaax;a(Laee;Ljava/util/List;)Vintermediary method_4608Lnet/minecraft/class_1428;method_4608(Lnet/minecraft/class_1127;Ljava/util/List;)Vnamed getEnchantmentsLnet/minecraft/item/EnchantedBookItem;getEnchantments(Lnet/minecraft/enchantment/Enchantment;Ljava/util/List;)V
-
method_4610
- Mappings:
Namespace Name Mixin selector official bLaax;b(Ljava/util/Random;)Lpj;intermediary method_4610Lnet/minecraft/class_1428;method_4610(Ljava/util/Random;)Lnet/minecraft/class_847;named method_4610Lnet/minecraft/item/EnchantedBookItem;method_4610(Ljava/util/Random;)Lnet/minecraft/util/WeightedRandomChestContent;
-
method_6347
- Mappings:
Namespace Name Mixin selector official aLaax;a(Ljava/util/Random;III)Lpj;intermediary method_6347Lnet/minecraft/class_1428;method_6347(Ljava/util/Random;III)Lnet/minecraft/class_847;named method_6347Lnet/minecraft/item/EnchantedBookItem;method_6347(Ljava/util/Random;III)Lnet/minecraft/util/WeightedRandomChestContent;
-