LlamaDom Posted July 3, 2021 Share Posted July 3, 2021 Hi! My significant other and I have a custom character that has custom items, but when we play with him, all characters can craft his items. How do we make it exclusive to him only? would it be in the item.lua, or the modmain.lua? Link to comment https://forums.kleientertainment.com/forums/topic/131525-craftable-armor-for-custom-character/ Share on other sites More sharing options...
HarryPPP Posted July 4, 2021 Share Posted July 4, 2021 (edited) It's quite simple. An example taken out of my mod: AddRecipe("potions_station_item", {Ingredient("boards", 4), Ingredient("transistor", 2), Ingredient("cutstone", 2)}, RECIPETABS.SCIENCE, TECH.SCIENCE_ONE, nil, nil, nil, nil, "scientist","images/inventoryimages/potions_station_item.xml") Here's a little breakdown of each component: AddRecipe( "youritem", -- Prefab to be crafted. {Ingredient("item1", 1), Ingredient("item2", 1), Ingredient("item3", 1)}, -- Ingredients. RECIPETABS.WAR, -- Tab. TECH.NONE, -- Tech. nil, -- Extra data. Not needed. nil, -- Minimal spacing. Not needed. nil, -- Wether or not you can Prototype the recipe. Prototyped recipes can be crafted anytime after crafted. (true or false) nil, -- The amount of the item that is given upon crafting. "customtag", -- THIS is what we are looking for: the tag your character needs to have in order to see the recipe. ) See the "customtag" written there? You need to replace it with a Tag your character has. Edited July 4, 2021 by HarryPPP Link to comment https://forums.kleientertainment.com/forums/topic/131525-craftable-armor-for-custom-character/#findComment-1476122 Share on other sites More sharing options...
LlamaDom Posted July 4, 2021 Author Share Posted July 4, 2021 wow thanks! For the custom tag, can I put multiple tags? Link to comment https://forums.kleientertainment.com/forums/topic/131525-craftable-armor-for-custom-character/#findComment-1476128 Share on other sites More sharing options...
HarryPPP Posted July 4, 2021 Share Posted July 4, 2021 12 hours ago, LlamaDom said: For the custom tag, can I put multiple tags? I'm not quite sure... I never tried, but I would guess it's a no. Link to comment https://forums.kleientertainment.com/forums/topic/131525-craftable-armor-for-custom-character/#findComment-1476241 Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now