Class AppleItem


public class AppleItem extends FoodItem
Mappings:
Namespace Name
official aik
intermediary net/minecraft/class_1066
named net/minecraft/item/AppleItem
  • Constructor Details

    • AppleItem

      public AppleItem(int hungerPoints, float saturation, boolean cookable)
      Mappings:
      Namespace Name Mixin selector
      official <init> Laij;<init>(IFZ)V
      intermediary <init> Lnet/minecraft/class_1065;<init>(IFZ)V
      named <init> Lnet/minecraft/item/FoodItem;<init>(IFZ)V
  • Method Details

    • hasEnchantmentGlint

      @Environment(CLIENT) public boolean hasEnchantmentGlint(ItemStack stack)
      Returns whether the current item has an enchantment glint. Used by enchanted golden apples and enchanted items.
      Overrides:
      hasEnchantmentGlint in class Item
      See Also:
      • net.minecraft.item.GoldenAppleItem
      Mappings:
      Namespace Name Mixin selector
      official f_ Lain;f_(Laip;)Z
      intermediary method_3374 Lnet/minecraft/class_1069;method_3374(Lnet/minecraft/class_1071;)Z
      named hasEnchantmentGlint Lnet/minecraft/item/Item;hasEnchantmentGlint(Lnet/minecraft/item/ItemStack;)Z
    • getRarity

      public Rarity getRarity(ItemStack stack)
      Returns the rarity of the current Item. Used by golden apples, enchanted items and potions.
      Overrides:
      getRarity in class Item
      Parameters:
      stack - The item in an ItemStack form
      Returns:
      The rarity of the ItemStack
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official g Lain;g(Laip;)Laje;
      intermediary method_3377 Lnet/minecraft/class_1069;method_3377(Lnet/minecraft/class_1071;)Lnet/minecraft/class_1081;
      named getRarity Lnet/minecraft/item/Item;getRarity(Lnet/minecraft/item/ItemStack;)Lnet/minecraft/util/Rarity;
    • eat

      protected void eat(ItemStack stack, World world, PlayerEntity player)
      Overrides:
      eat in class FoodItem
      Mappings:
      Namespace Name Mixin selector
      official a Laij;a(Laip;Lamu;Laed;)V
      intermediary method_3336 Lnet/minecraft/class_1065;method_3336(Lnet/minecraft/class_1071;Lnet/minecraft/class_1150;Lnet/minecraft/class_988;)V
      named eat Lnet/minecraft/item/FoodItem;eat(Lnet/minecraft/item/ItemStack;Lnet/minecraft/world/World;Lnet/minecraft/entity/player/PlayerEntity;)V
    • appendToItemGroup

      public void appendToItemGroup(ItemGroup group, DefaultedList<ItemStack> stacks)
      Overrides:
      appendToItemGroup in class Item
      Mappings:
      Namespace Name Mixin selector
      official a Lain;a(Lahp;Lfi;)V
      intermediary method_14233 Lnet/minecraft/class_1069;method_14233(Lnet/minecraft/class_1041;Lnet/minecraft/class_3114;)V
      named appendToItemGroup Lnet/minecraft/item/Item;appendToItemGroup(Lnet/minecraft/item/itemgroup/ItemGroup;Lnet/minecraft/util/collection/DefaultedList;)V