Fabrication Chamber (Calculator)
Description
Converts Stable and Analysed Circuits into output itemstacks.
Identifier
Refer to this via any of the following:
mods.calculator.fabrication_chamber/* Used as page default */
mods.calculator.fabricationchamber
mods.calculator.fabricationChamber
mods.calculator.FabricationChamber
Adding Recipes
Add the given recipe to the recipe list:
groovymods.calculator.fabrication_chamber.add(FabricationSonarRecipe)
Recipe Builder
Just like other recipe types, the Fabrication Chamber also uses a recipe builder.
Don't know what a builder is? Check the builder info page out.
mods.calculator.fabrication_chamber.recipeBuilder()
IngredientList<IIngredient>
. Sets the item inputs of the recipe. Requires greater than or equal to 1.groovyinput(IIngredient) input(IIngredient...) input(Collection<IIngredient>)
ItemStackList
. Sets the item outputs of the recipe. Requires exactly 1.groovyoutput(ItemStack) output(ItemStack...) output(Collection<ItemStack>)
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. (returnsnull
orsonar.calculator.mod.common.recipes.FabricationSonarRecipe
).groovyregister()
Example
mods.calculator.fabrication_chamber.recipeBuilder()
.input(item('calculator:circuitboard:8').withNbt([Stable: 0, Analysed: 1]))
.output(item('minecraft:diamond'))
.register()
mods.calculator.fabrication_chamber.recipeBuilder()
.input(item('calculator:circuitboard:0').withNbt([Stable: 0, Analysed: true]), item('calculator:circuitboard:1').withNbt([Stable: 0, Analysed: true]), item('calculator:circuitboard:2').withNbt([Stable: 0, Analysed: true]), item('calculator:circuitboard:3').withNbt([Stable: 0, Analysed: true]), item('calculator:circuitboard:4').withNbt([Stable: 0, Analysed: true]))
.input(item('calculator:circuitboard:0').withNbt([Stable: 1, Analysed: true]), item('calculator:circuitboard:1').withNbt([Stable: 1, Analysed: true]), item('calculator:circuitboard:2').withNbt([Stable: 1, Analysed: true]), item('calculator:circuitboard:3').withNbt([Stable: 1, Analysed: true]), item('calculator:circuitboard:4').withNbt([Stable: 1, Analysed: true]))
.output(item('minecraft:clay'))
.register()
Removing Recipes
Removes the given recipe from the recipe list:
groovymods.calculator.fabrication_chamber.remove(FabricationSonarRecipe)
Removes all recipes that match the given input:
groovymods.calculator.fabrication_chamber.removeByInput(IIngredient)
Removes all recipes that match the given output:
groovymods.calculator.fabrication_chamber.removeByOutput(IIngredient)
Removes all registered recipes:
groovymods.calculator.fabrication_chamber.removeAll()
Example
mods.calculator.fabrication_chamber.removeByInput(item('calculator:circuitboard:8').withNbt([Stable: 0, Analysed: 1]))
mods.calculator.fabrication_chamber.removeByOutput(item('calculator:calculatorassembly'))
mods.calculator.fabrication_chamber.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:
groovymods.calculator.fabrication_chamber.streamRecipes()