Crystallizer (Mekanism)
Description
Converts an input gasstack into an output itemstack.
Identifier
Refer to this via any of the following:
mods.mekanism.crystallizer/* Used as page default */
mods.mekanism.Crystallizer
Adding Recipes
Adds recipes in the format
input
,output
:groovymods.mekanism.crystallizer.add(GasStack, ItemStack)
Example
mods.mekanism.crystallizer.add(gas('cleanGold'), item('minecraft:gold_ingot'))
Recipe Builder
Just like other recipe types, the Crystallizer also uses a recipe builder.
Don't know what a builder is? Check the builder info page out.
mods.mekanism.crystallizer.recipeBuilder()
GasStackList
. Sets the gas inputs of the recipe. Requires exactly 1.groovygasInput(GasStack) gasInput(GasStack...) gasInput(Collection<GasStack>)
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
ormekanism.common.recipe.machines.CrystallizerRecipe
).groovyregister()
Example
mods.mekanism.crystallizer.recipeBuilder()
.gasInput(gas('cleanGold'))
.output(item('minecraft:gold_ingot'))
.register()
Removing Recipes
Removes all recipes that match the given input:
groovymods.mekanism.crystallizer.removeByInput(GasStack)
Removes all registered recipes:
groovymods.mekanism.crystallizer.removeAll()
Example
mods.mekanism.crystallizer.removeByInput(gas('cleanGold'))
mods.mekanism.crystallizer.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.mekanism.crystallizer.streamRecipes()