Class ItemInteractionEvent

java.lang.Object
net.neoforged.bus.api.Event
com.pixelmonmod.pixelmon.api.events.pokemon.ItemInteractionEvent
Direct Known Subclasses:
ItemInteractionEvent.Post, ItemInteractionEvent.Pre

public class ItemInteractionEvent extends net.neoforged.bus.api.Event
Called when a player attempts to interact with a Pokémon with an item in order to change the Pokémon's ability, nature, or moveset. Cancelling will cancel the action and the item shrinking.
  • Constructor Details

    • ItemInteractionEvent

      public ItemInteractionEvent(net.minecraft.world.entity.player.Player player, PixelmonEntity pixelmon, net.minecraft.world.item.ItemStack item)
  • Method Details

    • getPlayer

      public net.minecraft.world.entity.player.Player getPlayer()
    • getPixelmon

      public PixelmonEntity getPixelmon()
    • getPokemon

      public Pokemon getPokemon()
    • getItemStack

      public net.minecraft.world.item.ItemStack getItemStack()
    • getItem

      public net.minecraft.world.item.Item getItem()