Tutorial - Adding a smelting recipe
In this part we're going to add a smelting recipe, so we can smelt our platinum ore in our platinum ingot. I also introduce aliases.
Let's start with aliases. Aliases are nifty things that let you use custom names for items and blocks in all kind of places. Once you've added an alias to the mod.js file, they can be used everywhere in your mod.
For the smelting recipe we need two aliases: one for the ore and one for the ingot. Add the following two lines to the mod.js file:
mod.addAlias("Tutorial:platinumIngot", "platinumIngot");
The mod.addAlias() function needs two arguments: The first argument is the name of the item or block and the second argument
is the new custom name of the alias.
Now that we have our aliases, we can create our smelting recipe. Add the following line to the mod.js file:
// Without aliases it would look like this:
mod.addSmeltingRecipe("Tutorial:platinumIngot", "Tutorial:platinumOre");
The first argument is the result item and second argument is the input item of the recipe.
Continue with: Creation of tools