Class ElvenTradeRecipe

java.lang.Object
vazkii.botania.common.crafting.ElvenTradeRecipe
All Implemented Interfaces:
net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>, ElvenTradeRecipe

public class ElvenTradeRecipe extends Object implements ElvenTradeRecipe
  • Field Details

    • SERIALIZER

      public static final net.minecraft.world.item.crafting.RecipeSerializer<ElvenTradeRecipe> SERIALIZER
  • Constructor Details

    • ElvenTradeRecipe

      public ElvenTradeRecipe(net.minecraft.world.item.ItemStack[] outputs, net.minecraft.world.item.crafting.Ingredient... inputs)
    • ElvenTradeRecipe

      public ElvenTradeRecipe(List<net.minecraft.world.item.ItemStack> outputs, List<net.minecraft.world.item.crafting.Ingredient> ingredients)
  • Method Details

    • match

      public Optional<List<net.minecraft.world.item.ItemStack>> match(List<net.minecraft.world.item.ItemStack> stacks)
      Description copied from interface: ElvenTradeRecipe
      Attempts to match the recipe
      Specified by:
      match in interface ElvenTradeRecipe
      Parameters:
      stacks - Entire contents of the portal's buffer
      Returns:
      Optional.empty() if recipe doesn't match, Optional with a set of items used by recipe otherwise
    • containsItem

      public boolean containsItem(net.minecraft.world.item.ItemStack stack)
      Description copied from interface: ElvenTradeRecipe
      If the recipe does not contain the item, it will be destroyed upon entering the portal.
      Specified by:
      containsItem in interface ElvenTradeRecipe
    • getSerializer

      public net.minecraft.world.item.crafting.RecipeSerializer<?> getSerializer()
      Specified by:
      getSerializer in interface net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
    • getIngredients

      public net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> getIngredients()
      Specified by:
      getIngredients in interface ElvenTradeRecipe
      Specified by:
      getIngredients in interface net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
      Returns:
      Preview of the inputs
    • getToastSymbol

      public net.minecraft.world.item.ItemStack getToastSymbol()
      Specified by:
      getToastSymbol in interface net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
    • getOutputs

      public List<net.minecraft.world.item.ItemStack> getOutputs()
      Specified by:
      getOutputs in interface ElvenTradeRecipe
      Returns:
      Preview of the outputs
    • getOutputs

      public List<net.minecraft.world.item.ItemStack> getOutputs(List<net.minecraft.world.item.ItemStack> inputs)
      Description copied from interface: ElvenTradeRecipe
      Actually evaluate the recipe
      Specified by:
      getOutputs in interface ElvenTradeRecipe