Package net.minecraft.item
Class PotionItem
java.lang.Object
net.minecraft.item.Item
net.minecraft.item.PotionItem
- Mappings:
Namespace Name official aaiintermediary net/minecraft/class_1080named net/minecraft/item/PotionItem
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.item.Item
Item.ToolMaterialType -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Map<Integer,List<StatusEffectInstance>> private static final Map<List<StatusEffectInstance>,Integer> Fields inherited from class net.minecraft.item.Item
ATTACK_DAMAGE_MODIFIER_UUID, damageable, handheld, maxCount, RANDOM, REGISTRY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidappendItemStacks(Item item, ItemGroup group, List<ItemStack> list) Registers an item's sub itemsvoidappendTooltip(ItemStack stack, PlayerEntity player, List<String> lines, boolean advanced) intgetDisplayColor(ItemStack stack, int color) getDisplayName(ItemStack stack) intgetMaxUseTime(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_3457(int int2) static booleanmethod_3458(int int2) booleanmethod_3459(int int2) method_3460(ItemStack itemStack) intmethod_4629(int int2) onFinishUse(ItemStack stack, World world, PlayerEntity player) onStartUse(ItemStack stack, World world, PlayerEntity player) Methods inherited from class net.minecraft.item.Item
byRawId, canRepair, canUseOnEntity, fromBlock, getAttributeModifierMap, getEnchantability, getFromId, getItemGroup, getItemstackTranslatedName, getMaxCount, getMaxDamage, getMeta, getMiningSpeedMultiplier, getRarity, getRawId, getRecipeRemainder, getStatusEffectString, getTranslationKey, getTranslationKey, hasStatusEffectString, hasSubTypes, inventoryTick, isDamageable, isEffectiveOn, isEnchantable, isFood, isHandheld, isNetworkSynced, isUnbreakable, onBlockBroken, onCraft, onEntityHit, onHit, onUseStopped, postProcessNbt, registerBlockItem, setHandheld, setItemGroup, setMaxCount, setMaxDamage, setRecipeRemainder, setStatusEffectString, setTranslationKey, setUnbreakable, setup, shouldRotate, shouldSyncNbtToClient, use
-
Field Details
-
STATUS_EFFECTS_2
- Mappings:
Namespace Name Mixin selector official bLaai;b:Ljava/util/Map;intermediary field_4384Lnet/minecraft/class_1080;field_4384:Ljava/util/Map;named STATUS_EFFECTS_2Lnet/minecraft/item/PotionItem;STATUS_EFFECTS_2:Ljava/util/Map;
-
STATUS_EFFECTS_1
- Mappings:
Namespace Name Mixin selector official aLaai;a:Ljava/util/Map;intermediary field_9151Lnet/minecraft/class_1080;field_9151:Ljava/util/Map;named STATUS_EFFECTS_1Lnet/minecraft/item/PotionItem;STATUS_EFFECTS_1:Ljava/util/Map;
-
-
Constructor Details
-
PotionItem
public PotionItem()- Mappings:
Namespace Name Mixin selector official <init>Lzw;<init>()Vintermediary <init>Lnet/minecraft/class_1069;<init>()Vnamed <init>Lnet/minecraft/item/Item;<init>()V
-
-
Method Details
-
method_3460
- Mappings:
Namespace Name Mixin selector official hLaai;h(Lzx;)Ljava/util/List;intermediary method_3460Lnet/minecraft/class_1080;method_3460(Lnet/minecraft/class_1071;)Ljava/util/List;named method_3460Lnet/minecraft/item/PotionItem;method_3460(Lnet/minecraft/item/ItemStack;)Ljava/util/List;
-
method_3457
- Mappings:
Namespace Name Mixin selector official eLaai;e(I)Ljava/util/List;intermediary method_3457Lnet/minecraft/class_1080;method_3457(I)Ljava/util/List;named method_3457Lnet/minecraft/item/PotionItem;method_3457(I)Ljava/util/List;
-
onFinishUse
- Overrides:
onFinishUsein classItem- Mappings:
Namespace Name Mixin selector official bLzw;b(Lzx;Ladm;Lwn;)Lzx;intermediary method_3367Lnet/minecraft/class_1069;method_3367(Lnet/minecraft/class_1071;Lnet/minecraft/class_1150;Lnet/minecraft/class_988;)Lnet/minecraft/class_1071;named onFinishUseLnet/minecraft/item/Item;onFinishUse(Lnet/minecraft/item/ItemStack;Lnet/minecraft/world/World;Lnet/minecraft/entity/player/PlayerEntity;)Lnet/minecraft/item/ItemStack;
-
getMaxUseTime
- Overrides:
getMaxUseTimein classItem- Mappings:
Namespace Name Mixin selector official dLzw;d(Lzx;)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 eLzw;e(Lzx;)Laba;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;
-
onStartUse
- Overrides:
onStartUsein classItem- Mappings:
Namespace Name Mixin selector official aLzw;a(Lzx;Ladm;Lwn;)Lzx;intermediary method_3358Lnet/minecraft/class_1069;method_3358(Lnet/minecraft/class_1071;Lnet/minecraft/class_1150;Lnet/minecraft/class_988;)Lnet/minecraft/class_1071;named onStartUseLnet/minecraft/item/Item;onStartUse(Lnet/minecraft/item/ItemStack;Lnet/minecraft/world/World;Lnet/minecraft/entity/player/PlayerEntity;)Lnet/minecraft/item/ItemStack;
-
method_3458
public static boolean method_3458(int int2) - Mappings:
Namespace Name Mixin selector official fLaai;f(I)Zintermediary method_3458Lnet/minecraft/class_1080;method_3458(I)Znamed method_3458Lnet/minecraft/item/PotionItem;method_3458(I)Z
-
method_4629
- Mappings:
Namespace Name Mixin selector official gLaai;g(I)Iintermediary method_4629Lnet/minecraft/class_1080;method_4629(I)Inamed method_4629Lnet/minecraft/item/PotionItem;method_4629(I)I
-
getDisplayColor
- Overrides:
getDisplayColorin classItem- Mappings:
Namespace Name Mixin selector official aLzw;a(Lzx;I)Iintermediary method_3344Lnet/minecraft/class_1069;method_3344(Lnet/minecraft/class_1071;I)Inamed getDisplayColorLnet/minecraft/item/Item;getDisplayColor(Lnet/minecraft/item/ItemStack;I)I
-
method_3459
- Mappings:
Namespace Name Mixin selector official hLaai;h(I)Zintermediary method_3459Lnet/minecraft/class_1080;method_3459(I)Znamed method_3459Lnet/minecraft/item/PotionItem;method_3459(I)Z
-
getDisplayName
- Overrides:
getDisplayNamein classItem- Mappings:
Namespace Name Mixin selector official aLzw;a(Lzx;)Ljava/lang/String;intermediary method_3383Lnet/minecraft/class_1069;method_3383(Lnet/minecraft/class_1071;)Ljava/lang/String;named getDisplayNameLnet/minecraft/item/Item;getDisplayName(Lnet/minecraft/item/ItemStack;)Ljava/lang/String;
-
appendTooltip
@Environment(CLIENT) public void appendTooltip(ItemStack stack, PlayerEntity player, List<String> lines, boolean advanced) - Overrides:
appendTooltipin classItem- Mappings:
Namespace Name Mixin selector official aLzw;a(Lzx;Lwn;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
-
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 fLzw;f(Lzx;)Zintermediary method_3374Lnet/minecraft/class_1069;method_3374(Lnet/minecraft/class_1071;)Znamed hasEnchantmentGlintLnet/minecraft/item/Item;hasEnchantmentGlint(Lnet/minecraft/item/ItemStack;)Z
-
appendItemStacks
Registers an item's sub items- Overrides:
appendItemStacksin classItem- Parameters:
item- The Item instancegroup- The ItemGrouplist- The list of sub items- Mappings:
Namespace Name Mixin selector official aLzw;a(Lzw;Lyz;Ljava/util/List;)Vintermediary method_3345Lnet/minecraft/class_1069;method_3345(Lnet/minecraft/class_1069;Lnet/minecraft/class_1041;Ljava/util/List;)Vnamed appendItemStacksLnet/minecraft/item/Item;appendItemStacks(Lnet/minecraft/item/Item;Lnet/minecraft/item/itemgroup/ItemGroup;Ljava/util/List;)V
-