Plastic Mixer (PneumaticCraft: Repressurized)
Description
Converts a fluidstack and an item with a variable damage value into each other, requiring temperature to operate the process, optionally consuming dye, and allowing either only melting or only solidifying.
Warning
Items with metadata 15 will never consume dye, even if the option is enabled.
Danger
Only one meta value can be used for a recipe per fluid, and the meta value will be applied to the item.
Identifier
Refer to this via any of the following:
mods.pneumaticcraft.plastic_mixer/* Used as page default */
mods.pneumaticcraft.plasticmixer
mods.pneumaticcraft.plasticMixer
mods.pneumaticcraft.PlasticMixer
Adding Recipes
Add the given recipe to the recipe list:
groovymods.pneumaticcraft.plastic_mixer.add(PlasticMixerRegistry.PlasticMixerRecipe)
Recipe Builder
Just like other recipe types, the Plastic Mixer also uses a recipe builder.
Don't know what a builder is? Check the builder info page out.
mods.pneumaticcraft.plastic_mixer.recipeBuilder()
FluidStackList
. Sets the fluid inputs of the recipe. Requires exactly 1.groovyfluidInput(FluidStack) fluidInput(FluidStack...) fluidInput(Collection<FluidStack>)
ItemStackList
. Sets the item outputs of the recipe. Requires exactly 1.groovyoutput(ItemStack) output(ItemStack...) output(Collection<ItemStack>)
int
. Sets the meta value for selecting the recipe, only one meta value can be used for a fluid. (Default0
).groovymeta(int)
boolean
. Sets if the recipe consumes a random dye. (Defaultfalse
).groovyuseDye() useDye(boolean)
boolean
. Sets if the recipe allows melting the output item back into the input fluid. (Defaultfalse
).groovyallowMelting() allowMelting(boolean)
boolean
. Sets if the recipe allows solidifying the input fluid into the output item. (Defaultfalse
).groovyallowSolidifying() allowSolidifying(boolean)
int
. Sets the required temperature in Kelvin to melt or solidify the recipe. (Default0
).groovyrequiredTemperature(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. (returnsnull
orme.desht.pneumaticcraft.common.recipes.PlasticMixerRegistry$PlasticMixerRecipe
).groovyregister()
Example
mods.pneumaticcraft.plastic_mixer.recipeBuilder()
.fluidInput(fluid('lava') * 100)
.output(item('minecraft:clay'))
.allowMelting()
.allowSolidifying()
.requiredTemperature(323)
.register()
mods.pneumaticcraft.plastic_mixer.recipeBuilder()
.fluidInput(fluid('water') * 50)
.output(item('minecraft:sapling'))
.allowSolidifying()
.requiredTemperature(298)
.meta(-1)
.register()
Removing Recipes
Removes the given recipe from the recipe list:
groovymods.pneumaticcraft.plastic_mixer.remove(PlasticMixerRegistry.PlasticMixerRecipe)
Removes all recipes with the given fluid input:
groovymods.pneumaticcraft.plastic_mixer.removeByFluid(IIngredient)
Removes all recipes with the given item output:
groovymods.pneumaticcraft.plastic_mixer.removeByItem(IIngredient)
Removes all registered recipes:
groovymods.pneumaticcraft.plastic_mixer.removeAll()
Example
mods.pneumaticcraft.plastic_mixer.removeByFluid(fluid('plastic'))
mods.pneumaticcraft.plastic_mixer.removeByItem(item('pneumaticcraft:plastic'))
mods.pneumaticcraft.plastic_mixer.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.pneumaticcraft.plastic_mixer.streamRecipes()