Skip to content

Smoking Rack (The Betweenlands)

Description

Converts an input item into an output itemstack over a configurable period of time, consuming Fallen Leaves to do so.

Identifier

Refer to this via any of the following:

groovy
mods.betweenlands.smoking_rack
mods.betweenlands.smokingrack
mods.betweenlands.smokingRack
mods.betweenlands.SmokingRack
mods.thebetweenlands.smoking_rack/* Used as page default */
mods.thebetweenlands.smokingrack
mods.thebetweenlands.smokingRack
mods.thebetweenlands.SmokingRack

Adding Recipes

  • Add the given recipe to the recipe list:

    groovy
    mods.thebetweenlands.smoking_rack.add(ISmokingRackRecipe)

Recipe Builder

Just like other recipe types, the Smoking Rack also uses a recipe builder.

Don't know what a builder is? Check the builder info page out.

mods.thebetweenlands.smoking_rack.recipeBuilder()
  • IngredientList<IIngredient>. Sets the item inputs of the recipe. Requires exactly 1.

    groovy
    input(IIngredient)
    input(IIngredient...)
    input(Collection<IIngredient>)
  • ItemStackList. Sets the item outputs of the recipe. Requires exactly 1.

    groovy
    output(ItemStack)
    output(ItemStack...)
    output(Collection<ItemStack>)
  • int. Sets the time the recipe takes times 10 in seconds (3 = 30 seconds). Requires greater than or equal to 1. (Default 1).

    groovy
    time(int)
  • First validates the builder, returning null and outputting errors to the log file if the validation failed, then registers the builder and returns the registered object. (returns null or thebetweenlands.api.recipes.ISmokingRackRecipe).

    groovy
    register()
Example
groovy
mods.thebetweenlands.smoking_rack.recipeBuilder()
    .input(item('minecraft:clay'))
    .output(item('minecraft:diamond'))
    .register()

mods.thebetweenlands.smoking_rack.recipeBuilder()
    .input(item('minecraft:gold_ingot'))
    .output(item('minecraft:clay'))
    .time(50)
    .register()

Removing Recipes

  • Removes the given recipe from the recipe list:

    groovy
    mods.thebetweenlands.smoking_rack.remove(ISmokingRackRecipe)
  • Removes all recipes that match the given input:

    groovy
    mods.thebetweenlands.smoking_rack.removeByInput(IIngredient)
  • Removes all recipes that match the given output:

    groovy
    mods.thebetweenlands.smoking_rack.removeByOutput(IIngredient)
  • Removes all registered recipes:

    groovy
    mods.thebetweenlands.smoking_rack.removeAll()
Example
groovy
mods.thebetweenlands.smoking_rack.removeByInput(item('thebetweenlands:anadia'))
mods.thebetweenlands.smoking_rack.removeByOutput(item('thebetweenlands:barnacle_smoked'))
mods.thebetweenlands.smoking_rack.removeAll()

Getting the value of recipes

  • Iterates through every entry in the registry, with the ability to call remove on any element to remove it:

    groovy
    mods.thebetweenlands.smoking_rack.streamRecipes()

Contributors

© 2024 CleanroomMC. All Rights Reserved.