Skip to content

CraftTweaker

Cout970 edited this page Jan 4, 2020 · 6 revisions

CraftTweaker Support

Note: To use the CraftTweaker you need to include the lib mtlib otherwise the mod will crash when trying to use the Api. Usually mtlib is already included because is needed for ModTweaker.

Crushing table

# Remove all recipes with a creeper skull as input
mods.magneticraft.CrushingTable.removeRecipe(<minecraft:skull:4>);

# Remove all recipes with iron ore as input
mods.magneticraft.CrushingTable.removeRecipe(<minecraft:iron_ore>);

# Add a recipe with iron ore as input and 9 iron ingots as output, the las parameter is a oredict flag, if is true, the recipe will use any item with the same oreDict name as iron ore, if it's false it will only accept iron ore
mods.magneticraft.CrushingTable.addRecipe(<minecraft:iron_ore>, <minecraft:iron_ingot> * 9, true);

# This lines add the vanilla pickaxes as equivalent hammers
# The args are: mining level, speed and durability spend per item processed
mods.magneticraft.CrushingTable.addHammer(<minecraft:stone_pickaxe>, 1, 8, 1);
mods.magneticraft.CrushingTable.addHammer(<minecraft:iron_pickaxe>, 2, 10, 1);
mods.magneticraft.CrushingTable.addHammer(<minecraft:diamond_pickaxe>, 4, 15, 1);

# Remove the stone_hammer so it can't be used in the crushing table
mods.magneticraft.CrushingTable.removeHammer(<magneticraft:stone_hammer>);

SluiceBox

# Remove all recipes with sand ore as input
mods.magneticraft.SluiceBox.removeRecipe(<minecraft:sand>);

# addRecipe: Arguments:
# 1. input: the recipe input stack
# 3. output1Probability: The probability to get the ouput1
# 2. output1: The result of the recipe
# 4. [optional] Repeat 2 and 3 up to 6 times
# 5. oredictFlag: If true, it will use the oreDictionary to check if an input stack is equivalent to the recipe input

# Add a recipe with gold ore as input and 9 gold nuggets as output
mods.magneticraft.SluiceBox.addRecipe(<minecraft:gold_ore>, 1.0, <minecraft:gold_nugget> * 9, true);

# Add a recipe with gravel as input where 50% of the time returns a flint piece and 15% of the time retuns a gold nugget
mods.magneticraft.SluiceBox.addRecipe(<minecraft:gravel>, 0.15, <minecraft:gold_nugget>, 0.5, <minecraft:flint>, true);

# Add a recipe with sand as input where 5% of the time returns a gold nugget, 0.1% of the time retuns a flint pieze and 10% of the time returns a quarts pieze
mods.magneticraft.SluiceBox.addRecipe(<minecraft:sand>, 0.05, <minecraft:gold_nugget>, 0.001, <minecraft:flint>, 0.1, <minecraft:quartz>, true);

Grinder

# Remove all recipes with iron ore as input
mods.magneticraft.Grinder.removeRecipe(<minecraft:iron_ore>);

# addRecipe: Arguments:
# 1. input: the recipe input stack
# 2. primaryOutput: The result of the recipe, there is a 100% chance to get it
# 3. extraOutput: Extra result that you get sometimes
# 4. probability: the probability to get an extra output, for example 0.5 is 50% of the time and 0.0 is never
# 5. ticks: amount of game ticks need to complete the recipe
# 6. oredictFlag: If true, it will use the oreDictionary to check if an input stack is equivalent to the recipe input

# Add a recipe with iron ore as input, iron ingot as output and with a 0.5 (50%) extra chance to get a gold ingot as extra output
mods.magneticraft.Grinder.addRecipe(<minecraft:iron_ore>, <minecraft:iron_ingot>, <minecraft:gold_ingot>, 0.5, 80, true);

# Adds a recipe with only one output, basically anything with 0 chance is ignored
mods.magneticraft.Grinder.addRecipe(<minecraft:gold_ore>, <minecraft:gold_ingot>, <minecraft:stone>, 0.0, 50, true);

Sieve

# Remove all recipes with iron rocky chunk as input
mods.magneticraft.Sieve.removeRecipe(<magneticraft:rocky_chunks>);

# addRecipe: Arguments:
# 1. input: the recipe input stack
# 2. output1: The primary result of the recipe
# 3. output1Probability: The probability to get the output1
# 4. output2: The secondary result of the recipe
# 5. output2Probability: The probability to get the output2
# 6. output3: The tertiary result of the recipe
# 7. output3Probability: The probability to get the output3
# 8. ticks: amount of game ticks need to complete the recipe
# 9. oredictFlag: If true, it will use the oreDictionary to check if an input stack is equivalent to the recipe input

# Add a recipe with iron ore as input,
mods.magneticraft.Sieve.addRecipe(<minecraft:iron_ore>, <minecraft:iron_ingot>, 1.0, <minecraft:gold_ingot>, 0.25, <minecraft:gravel>, 0.15, 40, true);

# Adds a recipe with only one output, basically anything with 0 chance is ignored
mods.magneticraft.Sieve.addRecipe(<minecraft:iron_ore>, <minecraft:iron_ingot>, 1.0, <minecraft:stone>, 0.0, <minecraft:stone>, 0.0, 100, true);

Thermopile

# Remove a block from the list of heat source, this includes hot blocks and cold blocks (Note: must be a block)
mods.magneticraft.Thermopile.removeRecipe(<minecraft:ice>);

# Add a block to the list of heat source, the first argument is the block (must be a block) and the second argument is the "heat",
# basicaly a simbolic value of the heat of the block, if it's positive, the block is a heat source, if it's negative, the block is a cold source, 0 is not allowed
mods.magneticraft.Thermopile.addRecipe(<minecraft:ice>, -200);

Hydraulic Press

# Remove the recipe with iron ingot as input min the mode 0.
mods.magneticraft.HydraulicPress.removeRecipe(<minecraft:iron_ingot>, 0);

# addRecipe: Arguments:
# 1. input: the recipe input stack
# 2. output: The primary result of the recipe
# 3. duration: amount of game ticks need to complete the recipe
# 4. mode: 0 -> Plates from other mods, 1 -> Double plates, 2 -> Heavy plates
# 5. useOreDict:  If true, it will use the oreDictionary to check if an input stack is equivalent to the recipe input

# Add a new Hydraulic Press recipe to convert snow blocks into snow balls.
mods.magneticraft.HydraulicPress.addRecipe(<minecraft:snow>, <minecraft:snowball> * 4, 10, 0, true);

Oil Heater

# Remove the recipe with water as input
mods.magneticraft.OilHeater.removeRecipe(<liquid:water>);

# addRecipe: Arguments:
# 1. input: the recipe input stack
# 2. output: The result of the recipe
# 3. duration: amount of game ticks need to complete the recipe
# 4. minTemprature: temperature in kelvin needed to start to the processing

# Add a recipe to convert lava into steam, every 10 ticks, with the temperature of 2550K
mods.magneticraft.OilHeater.addRecipe(<liquid:lava> * 10, <liquid:steam> * 100, 10, 2500);

Refinery

# Remove the recipe with hot crude as input
mods.magneticraft.Refinery.removeRecipe(<liquid:hot_crude>);

# addRecipe: Arguments:
# 1. input: the recipe input stack
# 2. output1: The result of the recipe in the level 1
# 3. output2: The result of the recipe in the level 2
# 4. output3: The result of the recipe in the level 3
# 5. duration: amount of game ticks need to complete the recipe

# Add a recipe to convert steam into water every 10 ticks
mods.magneticraft.Refinery.addRecipe(<liquid:lava> * 10, <liquid:water>, null, null, 10);
Clone this wiki locally