Jump to content

Custom Recipe? For my character.


Recommended Posts

Hi I'm kinda new to this modding thing and I have a problem. Maybe I'm overthinking it but I can't seem to figure out on how to make a custom recipe.

I want this recipe to be a character specific one so only that character is allowed to craft it.

So basically I want my character to craft her own tall bird eggs. (don't ask me why lol)

Am I missing something super obvious and simple? (probably...) Because I have been trying for hours. ehehe QQ

Any help is well appreciated. 

Link to comment
Share on other sites

AddRecipe("tallbirdegg", { Ingredient("egg", 1), Ingredient("cutgrass", 1) }, RECIPETABS.FARM, TECH.SCIENCE_ONE,nil,nil,nil,nil,"specifictag" )

you can replace the ingredient items and amount by how many you want.

change "specifictag" to a tag that only your character, for example if your character has this;

inst:AddTag("eumon")

then you can change "specifictag" to "eumon"

Link to comment
Share on other sites

7 minutes ago, Eumon said:

Yep they are in there. Is there a specific place where I have to put it? And what do I do with inst:AddTag("eumon") ?

that was just an example, on the character you want to craft it, add a tag that only they would have, to uniquely identify them. (by doing inst:AddTag("tag") in the common_postinit function)

Then in the recipe, change the text "specifictag" at the end, to the tag you chose, which makes it so only characters with that tag can craft it.

Edited by Aquaterion
Link to comment
Share on other sites

 

30 minutes ago, Aquaterion said:

that was just an example, on the character you want to craft it, add a tag that only he/she would have, to uniquely identify it.

Then in the recipe, change the text "specifictag" at the end, to the tag you chose, which makes it so only characters with that tag can craft it.

Yes I added the tag and changed the text but it's still not showing up. Do I have to make a lua file for it? 

Link to comment
Share on other sites

what is this for?

local fn = function() 
--[...]
inst:AddTag("yosh")
AddRecipe("tallbirdegg", { Ingredient("egg", 1), Ingredient("cutgrass", 1) }, RECIPETABS.DRESS, TECH.SCIENCE_ONE,nil,nil,nil,nil,"yosh" )
--[...]
end

also, the

inst:AddTag("yosh")

should go in yosh.lua un the common_postinit function

Edited by Aquaterion
Link to comment
Share on other sites

4 minutes ago, Aquaterion said:

what is this for?


local fn = function() 
--[...]
inst:AddTag("yosh")
AddRecipe("tallbirdegg", { Ingredient("egg", 1), Ingredient("cutgrass", 1) }, RECIPETABS.DRESS, TECH.SCIENCE_ONE,nil,nil,nil,nil,"yosh" )
--[...]
end

also, the

inst:AddTag("yosh")

should go in yosh.lua un the common_postinit function

eheheh I don't really want to talk about it. derp

But yes thank you so much it is working now! You da best sir/madam!

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...