Electrolytic Separator (Mekanism)
Description
Converts an input fluid into two output gasstacks at the cost of power.
Identifier
Refer to this via any of the following:
mods.mekanism.electrolytic_separator/* Used as page default */
mods.mekanism.electrolyticseparator
mods.mekanism.electrolyticSeparator
mods.mekanism.ElectrolyticSeparator
mods.mekanism.separator
mods.mekanism.Separator
Adding Recipes
Adds recipes in the format
input
,leftOutput
,rightOutput
,energy
:groovymods.mekanism.electrolytic_separator.add(FluidStack, GasStack, GasStack, double)
Example
mods.mekanism.electrolytic_separator.add(fluid('lava') * 10, gas('cleanGold') * 5, gas('cleanCopper') * 3, 3000)
Recipe Builder
Just like other recipe types, the Electrolytic Separator also uses a recipe builder.
Don't know what a builder is? Check the builder info page out.
mods.mekanism.electrolytic_separator.recipeBuilder()
FluidStackList
. Sets the fluid inputs of the recipe. Requires exactly 1.groovyfluidInput(FluidStack) fluidInput(FluidStack...) fluidInput(Collection<FluidStack>)
GasStackList
. Sets the gas outputs of the recipe. Requires exactly 2.groovygasOutput(GasStack) gasOutput(GasStack...) gasOutput(Collection<GasStack>)
double
. Sets the energy cost of the recipe. Requires greater than 0. (Default0.0d
).groovyenergy(double)
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.SeparatorRecipe
).groovyregister()
Example
mods.mekanism.electrolytic_separator.recipeBuilder()
.fluidInput(fluid('lava') * 10)
.gasOutput(gas('cleanGold') * 5, gas('cleanCopper') * 3)
.energy(3000)
.register()
Removing Recipes
Removes all recipes that match the given input:
groovymods.mekanism.electrolytic_separator.removeByInput(FluidStack)
Removes all registered recipes:
groovymods.mekanism.electrolytic_separator.removeAll()
Example
mods.mekanism.electrolytic_separator.removeByInput(fluid('water'))
mods.mekanism.electrolytic_separator.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.electrolytic_separator.streamRecipes()