Creating an item

Creating a new ItemStack through the FluidItem class.

To create an item, instantiate a new FluidItem by passing in a Material (optional parameters being the amount, or creating an item from an existing one) then building it:

ItemStack item = new FluidItem(MATERIAL).build();
ItemStack item = new FluidItem(MATERIAL, AMOUNT).build();
ItemStack item = new FluidItem(ITEM STACK).build();

Last updated

Was this helpful?