Interface ItemPart.IUseAction

Enclosing class:
ItemPart<P extends IPartType<P,S>,S extends IPartState<P>>

public static interface ItemPart.IUseAction
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    attempItemUseTarget(ItemPart itemPart, net.minecraft.world.item.ItemStack itemStack, net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction sideHit)
    Attempt to use the given item.
  • Method Details

    • attempItemUseTarget

      boolean attempItemUseTarget(ItemPart itemPart, net.minecraft.world.item.ItemStack itemStack, net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction sideHit)
      Attempt to use the given item.
      Parameters:
      itemPart - The part item instance.
      itemStack - The item stack that is being used.
      world - The world.
      pos - The position.
      sideHit - The side that is being hit.
      Returns:
      If the use action was applied.