#priority 10 /* SevTech: Ages Dye Integration Script This script handles changing how dyes are worked in the pack. 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.IIngredient; import crafttweaker.item.IItemStack; import crafttweaker.oredict.IOreDictEntry; import scripts.crafttweaker.utils; /* Map contaning the Dyes and the flowers which can be turned into the Dye. Notes: Thanks to Neosghost for pairing ferdinands flowers! */ static dyeCrushingRecipes as IItemStack[][IItemStack] = { // White .firstItem : [ , , , , , , , ], // Orange .firstItem : [ , , , , , , , , , , , , , , , , , , , , , ], // Magenta .firstItem : [ , , , , , , , , , , , ], // Light Blue .firstItem : [ , , , , , , , , , , ], // Yellow .firstItem : [ , , , , , , , , , , , , , , , , , ], // Lime .firstItem : [ ], // Pink .firstItem : [ , , , , , , , , , , , , , , , , , , ], // Gray .firstItem : [ ], // Light Gray .firstItem : [ , , , ], // Cyan .firstItem : [ , ], // Purple .firstItem : [ , , , , , , , , , , , , , , , , , , , , , , , , , ], // Blue .firstItem : [ , , , , , , , , , , , , , , ], // Brown .firstItem : [ , , , , , , ], // Green .firstItem : [ , , , , , , , , , ], // Red .firstItem : [ , , , , , , , , , , , , , , , , ], // Black .firstItem : [ , , ] }; function init() { // ================================== // Loop over the Vanilla Dyes and remove all recipes for them. for minecraftDye in minecraftDyes { // Remove Vanilla recipes. recipes.remove(minecraftDye); // Remove AA Crusher recipes. actuallyAdditions.removeCrusher(minecraftDye); } var IE_CRUSHER_ENERGY as int = 3200; var HP_GRINDSTONE_TIME as int = 12; // ================================== // Loop over the Crushing recipes to create the correct recipes based on our Dye setup. for dye, items in scripts.crafttweaker.integrations.dye.dyeCrushingRecipes { // Re-create wool -> string/dye recipe if (dye.metadata == 0) { // White wool doesn't output dye. immersiveEngineering.addCrusher( * 4, .definition.makeStack(dye.metadata), IE_CRUSHER_ENERGY); } else { immersiveEngineering.addCrusher( * 4, .definition.makeStack(dye.metadata), IE_CRUSHER_ENERGY, dye, 0.05); } for item in items { actuallyAdditions.addCrusher(dye * 2, item); betterWithMods.addMilling([item], [dye * 2]); immersiveEngineering.addCrusher(dye * 2, item, IE_CRUSHER_ENERGY); horsePower.addGrindstone(dye, item, HP_GRINDSTONE_TIME, false); mekanism.addCrusher(item, dye * 2); } // ================================== // Re-create Minecraft Wool Dying Recipes var dyeName as string = minecraftDyeIdTable[15 - dye.metadata]; var dyeOredict as IOreDictEntry = oreDict.get("dye" ~ utils.capitalize(dyeName)); recipes.addShaped("dye_wool_" ~ dyeName, .definition.makeStack(dye.metadata) * 8, [ [, , ], [, dyeOredict, ], [, , ] ] ); } .add(.firstItem); // TODO: remove when AE2 accepts dyeLightGray }