Jump to content

How do I change crafting recipes


Recommended Posts

So I was thinking of making a mod that makes crafting recipes harder to add a little challenge but I cannot figure out how I would go about doing this.

My problem is that I cannot figure out how I would change the crafting recipes of items. For an example I was thinking of changing the lightning rod recipe to...

2x Gold nuggets - 1x Cut stone - 1x Volt goat horn. 

If someone could post how I would code this then I could figure out how I would do this then I can start making it.

Much thanks!

Link to comment
Share on other sites

Well if you're fine with changing each individual recipe:

Quote

STRINGS = GLOBAL.STRINGS
RECIPETABS = GLOBAL.RECIPETABS
Recipe = GLOBAL.Recipe
Ingredient = GLOBAL.Ingredient
TECH = GLOBAL.TECH
Recipe("researchlab", {Ingredient("log", 6),Ingredient("nitre", 4),Ingredient("goldnugget", 4),Ingredient("silk", 2)}, RECIPETABS.SCIENCE, TECH.NONE, "researchlab_placer")

Is an example. This applies to all characters

Link to comment
Share on other sites

Okay so I have an issue with it. When in the game, the recipes I edit will not need a science machine or alchemy engine to craft. I assumed that it was TECH.NONE that I had to change but I tried everything I could think of, I also downloaded other mods to see what they did. Nothing has worked and I really need to know how to change this.

Another issue is that I cannot get items from crafting non-structures.

I am sorry that I couldn't figure this out for myself like I thought I could.

Thank you!

Edited by IHasRoadRage
Link to comment
Share on other sites

While this is not required, I would suggest going into scripts/recipes.lua. It has the list of all the recipes, which you can copy any recipe you want to change into modmain.lua and then adjust it. This is all to make sure you don't mistakenly change values that you didn't mean to change.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
  • Create New...