Package net.minecraft.item
Class PotionItem
java.lang.Object
net.minecraft.item.Item
net.minecraft.item.PotionItem
- All Implemented Interfaces:
Itemable
- Direct Known Subclasses:
LingeringPotionItem,SplashPotionItem
- Mappings:
Namespace Name official atpintermediary net/minecraft/class_1080named net/minecraft/item/PotionItem
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.item.Item
Item.Settings -
Field Summary
Fields inherited from class net.minecraft.item.Item
ATTACK_DAMAGE_MODIFIER_UUID, ATTACK_SPEED_MODIFIER, BLOCK_ITEMS, itemGroup, RANDOM -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidappendToItemGroup(ItemGroup group, DefaultedList<ItemStack> stacks) voidappendTooltips(ItemStack stack, World world, List<Text> tooltip, TooltipContext tooltipContext) intgetMaxUseTime(ItemStack stack) getTranslationKey(ItemStack stack) getUseAction(ItemStack stack) Returns the UseAction for an item when the item is used.booleanhasEnchantmentGlint(ItemStack stack) Returns whether the current item has an enchantment glint.method_13649(World world, PlayerEntity player, Hand hand) method_3367(ItemStack stack, World world, LivingEntity entity) Methods inherited from class net.minecraft.item.Item
addProperty, beforeBlockBreak, byRawId, canAddTo, canRepair, computeTranslationKey, fromBlock, getBlockBreakingSpeed, getEnchantability, getItem, getItemGroup, getMaxCount, getMaxDamage, getProperty, getRarity, getRawId, getRecipeRemainder, getTranslationKey, hasProperties, inventoryTick, isDamageable, isEnchantable, isFood, isNetworkSynced, method_16075, method_16080, method_3346, method_3353, method_3356, method_3359, method_3383, method_6326, onCraft, onEntityHit, onHit, postProcessNbt, registerBlockItem, setup, shouldSyncNbtToClient, useOnBlock
-
Constructor Details
-
PotionItem
- Mappings:
Namespace Name Mixin selector official <init>Lata;<init>(Lata$a;)Vintermediary <init>Lnet/minecraft/class_1069;<init>(Lnet/minecraft/class_1069$class_3555;)Vnamed <init>Lnet/minecraft/item/Item;<init>(Lnet/minecraft/item/Item$Settings;)V
-
-
Method Details
-
getDefaultStack
- Overrides:
getDefaultStackin classItem- Mappings:
Namespace Name Mixin selector official sLata;s()Late;intermediary method_13650Lnet/minecraft/class_1069;method_13650()Lnet/minecraft/class_1071;named getDefaultStackLnet/minecraft/item/Item;getDefaultStack()Lnet/minecraft/item/ItemStack;
-
method_3367
- Overrides:
method_3367in classItem- Mappings:
Namespace Name Mixin selector official aLata;a(Late;Laxy;Lafa;)Late;intermediary method_3367Lnet/minecraft/class_1069;method_3367(Lnet/minecraft/class_1071;Lnet/minecraft/class_1150;Lnet/minecraft/class_1699;)Lnet/minecraft/class_1071;named method_3367Lnet/minecraft/item/Item;method_3367(Lnet/minecraft/item/ItemStack;Lnet/minecraft/world/World;Lnet/minecraft/entity/LivingEntity;)Lnet/minecraft/item/ItemStack;
-
getMaxUseTime
- Overrides:
getMaxUseTimein classItem- Mappings:
Namespace Name Mixin selector official cLata;c(Late;)Iintermediary method_3350Lnet/minecraft/class_1069;method_3350(Lnet/minecraft/class_1071;)Inamed getMaxUseTimeLnet/minecraft/item/Item;getMaxUseTime(Lnet/minecraft/item/ItemStack;)I
-
getUseAction
Returns the UseAction for an item when the item is used. Used by food, potions, bows, etc.- Overrides:
getUseActionin classItem- Parameters:
stack- The ItemStack that was used- See Also:
- Mappings:
Namespace Name Mixin selector official dLata;d(Late;)Lauo;intermediary method_3366Lnet/minecraft/class_1069;method_3366(Lnet/minecraft/class_1071;)Lnet/minecraft/class_1099;named getUseActionLnet/minecraft/item/Item;getUseAction(Lnet/minecraft/item/ItemStack;)Lnet/minecraft/util/UseAction;
-
method_13649
- Overrides:
method_13649in classItem- Mappings:
Namespace Name Mixin selector official aLata;a(Laxy;Laog;Ladk;)Ladn;intermediary method_13649Lnet/minecraft/class_1069;method_13649(Lnet/minecraft/class_1150;Lnet/minecraft/class_988;Lnet/minecraft/class_2961;)Lnet/minecraft/class_2963;named method_13649Lnet/minecraft/item/Item;method_13649(Lnet/minecraft/world/World;Lnet/minecraft/entity/player/PlayerEntity;Lnet/minecraft/util/Hand;)Lnet/minecraft/util/TypedActionResult;
-
getTranslationKey
- Overrides:
getTranslationKeyin classItem- Mappings:
Namespace Name Mixin selector official hLata;h(Late;)Ljava/lang/String;intermediary method_3371Lnet/minecraft/class_1069;method_3371(Lnet/minecraft/class_1071;)Ljava/lang/String;named getTranslationKeyLnet/minecraft/item/Item;getTranslationKey(Lnet/minecraft/item/ItemStack;)Ljava/lang/String;
-
appendTooltips
@Environment(CLIENT) public void appendTooltips(ItemStack stack, @Nullable World world, List<Text> tooltip, TooltipContext tooltipContext) - Overrides:
appendTooltipsin classItem- Mappings:
Namespace Name Mixin selector official aLata;a(Late;Laxy;Ljava/util/List;Laum;)Vintermediary method_14234Lnet/minecraft/class_1069;method_14234(Lnet/minecraft/class_1071;Lnet/minecraft/class_1150;Ljava/util/List;Lnet/minecraft/class_3191;)Vnamed appendTooltipsLnet/minecraft/item/Item;appendTooltips(Lnet/minecraft/item/ItemStack;Lnet/minecraft/world/World;Ljava/util/List;Lnet/minecraft/client/TooltipContext;)V
-
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 bLata;b(Late;)Zintermediary method_3374Lnet/minecraft/class_1069;method_3374(Lnet/minecraft/class_1071;)Znamed hasEnchantmentGlintLnet/minecraft/item/Item;hasEnchantmentGlint(Lnet/minecraft/item/ItemStack;)Z
-
appendToItemGroup
- Overrides:
appendToItemGroupin classItem- Mappings:
Namespace Name Mixin selector official aLata;a(Lary;Lez;)Vintermediary method_14233Lnet/minecraft/class_1069;method_14233(Lnet/minecraft/class_1041;Lnet/minecraft/class_3114;)Vnamed appendToItemGroupLnet/minecraft/item/Item;appendToItemGroup(Lnet/minecraft/item/itemgroup/ItemGroup;Lnet/minecraft/util/collection/DefaultedList;)V
-