Class ItemStackHelper

java.lang.Object
com.pixelmonmod.pixelmon.api.util.helpers.ItemStackHelper

public class ItemStackHelper extends Object
Useful methods for ItemStacks
Since:
25/06/2022
  • Constructor Details

    • ItemStackHelper

      public ItemStackHelper()
  • Method Details

    • parseUserInput

      public static Optional<net.minecraft.world.item.ItemStack> parseUserInput(String data, int amount) throws RuntimeException
      Reads the data from a user and converts it into an ItemStack with the given amount
      Parameters:
      data - The user data
      amount - The amount
      Returns:
      The parsed itemstack
      Throws:
      RuntimeException