Jump to content

Recommended Posts

Hello, I require help because I am farley new to modding in don't starve together and I would like to know how to make a custom crafting recipe and e.g upload it to the workshop so my friends can have it and etc.

I hope someone can help me with my struggles :):p

 

Thank you the forum of klei entertainment!

Edited by officialpinq

	
AddRecipe("warg_coat", {Ingredient("warg_fur", 2, "images/inventoryimages/warg_fur.xml"), Ingredient("houndstooth", 2), Ingredient("log", 1) }, RECIPETABS.WAR, TECH.SCIENCE_TWO, nil, nil, nil, nil, nil,  "images/inventoryimages/warg_coat.xml", "warg_coat.tex" )

This is an example recipe for a custom recipe for a custom item with custom ingredients.


AddRecipe("gears",  {Ingredient("steelwool", 1), Ingredient("transistor", 1), Ingredient("purplegem", 1) }, RECIPETABS.SCIENCE, TECH.SCIENCE_TWO)

This is an example for a custom recipe for an existing item without recipe.

 

You need to put the code in modmain.lua with :

local RECIPETABS = GLOBAL.RECIPETABS
local Ingredient = GLOBAL.Ingredient
local TECH = GLOBAL.TECH

This in both case

 

You also need a modinfo.lua

 

I suggest you to download a mod adding a simple recipe and using it as a template. After that, for uploading your mod, you need to use Don't Starve Mod Tool (you can find it on Steam in the tool section).

On 28/02/2017 at 2:21 PM, Lumina said:


	
AddRecipe("warg_coat", {Ingredient("warg_fur", 2, "images/inventoryimages/warg_fur.xml"), Ingredient("houndstooth", 2), Ingredient("log", 1) }, RECIPETABS.WAR, TECH.SCIENCE_TWO, nil, nil, nil, nil, nil,  "images/inventoryimages/warg_coat.xml", "warg_coat.tex" )

This is an example recipe for a custom recipe for a custom item with custom ingredients.



AddRecipe("gears",  {Ingredient("steelwool", 1), Ingredient("transistor", 1), Ingredient("purplegem", 1) }, RECIPETABS.SCIENCE, TECH.SCIENCE_TWO)

This is an example for a custom recipe for an existing item without recipe.

 

You need to put the code in modmain.lua with :


local RECIPETABS = GLOBAL.RECIPETABS
local Ingredient = GLOBAL.Ingredient
local TECH = GLOBAL.TECH

This in both case

 

You also need a modinfo.lua

 

I suggest you to download a mod adding a simple recipe and using it as a template. After that, for uploading your mod, you need to use Don't Starve Mod Tool (you can find it on Steam in the tool section).

Could you link me to a "mod adding a simple recipe"

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
×
  • Create New...