/* SevTech: Ages Table Industrial Mill Recipes Script This script handles custom integration control to a mod. Note: These scripts are created and for the usage in SevTech: Ages and other modpacks curated by DarkPacks. You can use these scripts for reference and for learning but not for copying and pasting and claiming as your own. */ import crafttweaker.item.IItemStack; import crafttweaker.oredict.IOreDictEntry; import mods.modularmachinery.RecipeBuilder; import mods.modularmachinery.RecipePrimer; import scripts.crafttweaker.utils; /* Helper function to create a Mill Recipe for the MM Machine. */ function createMillRecipe(name as string, output as IItemStack, inputs as IItemStack[]) as void { var machineName = "industrial_mill"; var builder as RecipePrimer = RecipeBuilder.newBuilder(utils.createRecipeName(machineName, name), machineName, 128); builder.addEnergyPerTickInput(4); // Set the power input. builder.addItemOutput(output); // Set the output item. for input in inputs { // Loop over the inputs and add them to the builder. builder.addItemInput(input); } builder.build(); // Build the recipe. } function createOreMillRecipe(name as string, output as IItemStack, inputs as IOreDictEntry[]) as void { var machineName = "industrial_mill"; var builder as RecipePrimer = RecipeBuilder.newBuilder(utils.createRecipeName(machineName, name), machineName, 128); builder.addEnergyPerTickInput(4); // Set the power input. builder.addItemOutput(output); // Set the output item. for input in inputs { // Loop over the inputs and add them to the builder. builder.addItemInput(input); } builder.build(); // Build the recipe. } function init() { for dye, items in scripts.crafttweaker.integrations.dye.dyeCrushingRecipes { for item in items { createMillRecipe(item.displayName, dye * 2, [item]); } } /* Multi Input Recipes */ createMillRecipe("grout", * 2, [ , , ]); createMillRecipe("porcelain", , [ , , ]); /* Resource/Plant Based */ createOreMillRecipe("resin", * 2, [ ]); createMillRecipe("hemp_fibre", * 3, [ ]); createOreMillRecipe("ground_netherrack", , [ ]); createMillRecipe("coal_dust", , [ ]); createMillRecipe("charcoal_dust", , [ ]); createMillRecipe("sugar", * 2, [ ]); createMillRecipe("charcoal_low_grade", * 4, [ ]); /* Bone Meal */ createMillRecipe("bonemeal_bone", * 6, [ ]); createMillRecipe("bonemeal_block", * 9, [ ]); /* Flour */ createMillRecipe("flour", , [ ]); createMillRecipe("barley_flour", , [ ]); createMillRecipe("rice_flour", , [ ]); /* Ground Meat */ createMillRecipe("ground_meat_pork", * 3, [ ]); createMillRecipe("ground_meat_beef", * 3, [ ]); createMillRecipe("ground_meat_rabbit", * 3, [ ]); createMillRecipe("ground_meat_chicken", * 2, [ ]); createMillRecipe("ground_meat_mutton", * 2, [ ]); createMillRecipe("ground_meat_mystery", * 2, [ ]); createMillRecipe("ground_meat_fish", * 2, [ ]); createMillRecipe("ground_meat_salmon", * 2, [ ]); }