Class MegaStoneItem

java.lang.Object
net.minecraft.world.item.Item
com.pixelmonmod.pixelmon.items.PixelmonItem
com.pixelmonmod.pixelmon.items.HeldItem
com.pixelmonmod.pixelmon.items.heldItems.MegaStoneItem
All Implemented Interfaces:
ITranslatable, net.minecraft.world.flag.FeatureElement, net.minecraft.world.level.ItemLike, net.neoforged.neoforge.common.extensions.IItemExtension

public class MegaStoneItem extends HeldItem
A held item that can Mega Evolve a Pokémon.
  • Constructor Details

    • MegaStoneItem

      public MegaStoneItem(String species, String megaForm)
  • Method Details

    • verifyComponentsAfterLoad

      public void verifyComponentsAfterLoad(net.minecraft.world.item.ItemStack stack)
      Overrides:
      verifyComponentsAfterLoad in class net.minecraft.world.item.Item
    • isFoil

      public boolean isFoil(net.minecraft.world.item.ItemStack itemstack)
      Overrides:
      isFoil in class PixelmonItem
    • appendHoverText

      public void appendHoverText(net.minecraft.world.item.ItemStack stack, net.minecraft.world.item.Item.TooltipContext context, List<net.minecraft.network.chat.Component> tooltipComponents, net.minecraft.world.item.TooltipFlag tooltipFlag)
      Overrides:
      appendHoverText in class PixelmonItem
    • getMegaEvolution

      public MegaEvolution getMegaEvolution(net.minecraft.world.item.ItemStack stack)
    • getNextUsableTime

      public Instant getNextUsableTime(net.minecraft.world.item.ItemStack stack)
    • isUsable

      public boolean isUsable(net.minecraft.world.item.ItemStack stack)
    • setUsed

      public void setUsed(net.minecraft.world.item.ItemStack stack)
    • interact

      public HeldItemInteractionResult interact(PixelmonEntity pixelmon, net.minecraft.world.item.ItemStack stack, net.minecraft.world.entity.player.Player player)
      Description copied from class: HeldItem
      Overrides the standard held item interaction (not consuming the held item) if needed.
      Overrides:
      interact in class HeldItem
      Parameters:
      pixelmon - The Pokémon being given the item.
      stack - The itemstack used to interact.
      player - The player using the item.
      Returns:
      Whether the item was consumed.