Interface ElvenTradeRecipe

All Superinterfaces:
net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
All Known Implementing Classes:
ElvenTradeRecipe, LexiconElvenTradeRecipe

public interface ElvenTradeRecipe extends net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final net.minecraft.resources.ResourceLocation
     
    static final net.minecraft.resources.ResourceLocation
     

    Fields inherited from interface net.minecraft.world.item.crafting.Recipe

    CODEC, STREAM_CODEC
  • Method Summary

    Modifier and Type
    Method
    Description
    default net.minecraft.world.item.ItemStack
    assemble(net.minecraft.world.item.crafting.RecipeInput inv, net.minecraft.core.HolderLookup.Provider registries)
     
    default boolean
    canCraftInDimensions(int width, int height)
     
    boolean
    containsItem(net.minecraft.world.item.ItemStack stack)
    If the recipe does not contain the item, it will be destroyed upon entering the portal.
    net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient>
     
    List<net.minecraft.world.item.ItemStack>
     
    List<net.minecraft.world.item.ItemStack>
    getOutputs(List<net.minecraft.world.item.ItemStack> inputs)
    Actually evaluate the recipe
    default net.minecraft.world.item.ItemStack
    getResultItem(net.minecraft.core.HolderLookup.Provider registries)
     
    default net.minecraft.world.item.crafting.RecipeType<?>
     
    default boolean
    Checks if this recipe is a "return" recipe, meaning that it returns the item that was thrown into it.
    default boolean
     
    Optional<List<net.minecraft.world.item.ItemStack>>
    match(List<net.minecraft.world.item.ItemStack> stacks)
    Attempts to match the recipe
    default boolean
    matches(net.minecraft.world.item.crafting.RecipeInput inv, net.minecraft.world.level.Level world)
     

    Methods inherited from interface net.minecraft.world.item.crafting.Recipe

    getGroup, getRemainingItems, getSerializer, getToastSymbol, isIncomplete, showNotification
  • Field Details

    • TYPE_ID

      static final net.minecraft.resources.ResourceLocation TYPE_ID
    • TYPE_ID_LEXICON

      static final net.minecraft.resources.ResourceLocation TYPE_ID_LEXICON
  • Method Details

    • match

      Optional<List<net.minecraft.world.item.ItemStack>> match(List<net.minecraft.world.item.ItemStack> stacks)
      Attempts to match the recipe
      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

      boolean containsItem(net.minecraft.world.item.ItemStack stack)
      If the recipe does not contain the item, it will be destroyed upon entering the portal.
    • getIngredients

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

      List<net.minecraft.world.item.ItemStack> getOutputs()
      Returns:
      Preview of the outputs
    • getOutputs

      List<net.minecraft.world.item.ItemStack> getOutputs(List<net.minecraft.world.item.ItemStack> inputs)
      Actually evaluate the recipe
    • getType

      default net.minecraft.world.item.crafting.RecipeType<?> getType()
      Specified by:
      getType in interface net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
    • matches

      default boolean matches(net.minecraft.world.item.crafting.RecipeInput inv, net.minecraft.world.level.Level world)
      Specified by:
      matches in interface net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
    • assemble

      default net.minecraft.world.item.ItemStack assemble(net.minecraft.world.item.crafting.RecipeInput inv, net.minecraft.core.HolderLookup.Provider registries)
      Specified by:
      assemble in interface net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
    • canCraftInDimensions

      default boolean canCraftInDimensions(int width, int height)
      Specified by:
      canCraftInDimensions in interface net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
    • getResultItem

      default net.minecraft.world.item.ItemStack getResultItem(net.minecraft.core.HolderLookup.Provider registries)
      Specified by:
      getResultItem in interface net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
    • isSpecial

      default boolean isSpecial()
      Specified by:
      isSpecial in interface net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
    • isReturnRecipe

      default boolean isReturnRecipe()
      Checks if this recipe is a "return" recipe, meaning that it returns the item that was thrown into it.
      Returns:
      true if recipe is a return recipe, false otherwise.