public class ItemStackHelper
extends java.lang.Object
ItemStack
sConstructor and Description |
---|
ItemStackHelper() |
Modifier and Type | Method and Description |
---|---|
static java.util.Optional<net.minecraft.item.ItemStack> |
parseUserInput(java.lang.String data,
int amount)
Reads the data from a user and converts it into an
ItemStack with the given amount |
public static java.util.Optional<net.minecraft.item.ItemStack> parseUserInput(java.lang.String data, int amount) throws java.lang.RuntimeException
ItemStack
with the given amountdata
- The user dataamount
- The amountjava.lang.RuntimeException