Jump to content

Recommended Posts

I have no idea if you've done something incorrectly or not done it at all as I can't see your code, but follow the example in AddCharacterRecipe. This specifically makes character items.

As an example, this is all the code I use to make one of my character's items appear properly in the crafting menu, with descriptions and icons.

Spoiler
Quote

RegisterInventoryItemAtlas("images/inventoryimages/blankmask.xml", "blankmask.tex")

GLOBAL.STRINGS.NAMES.BLANKMASK = "Blank Mask"
GLOBAL.STRINGS.RECIPE_DESC.BLANKMASK = "A base for a face."

AddCharacterRecipe("blankmask", -- name
    { -- ingredients
        GLOBAL.Ingredient("papyrus", 1),
        GLOBAL.Ingredient("rope", 1),
    },
    GLOBAL.TECH.NONE, -- tech
    { -- config
        product = "blankmask",
        builder_tag = "maskmaker",
        numtogive = 1,
    },
    { -- filters
        "CHARACTER",
        "REFINE",
    }
)

 

If you have already done all of this and it does not work, you'll have better luck posting your mod files so people can look at the problem.

Edited by Chesed
5 hours ago, Chesed said:

I have no idea if you've done something incorrectly or not done it at all as I can't see your code, but follow the example in AddCharacterRecipe. This specifically makes character items.

As an example, this is all the code I use to make one of my character's items appear properly in the crafting menu, with descriptions and icons.

  Hide contents

 

If you have already done all of this and it does not work, you'll have better luck posting your mod files so people can look at the problem.

Thanks, it worked!

This is the code I used at first, I just found it online:

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

Ingredient = GLOBAL.Ingredient
TECH = GLOBAL.TECH

GLOBAL.Recipe("name", {Ingredient("ingredient name",number of ingredients), Ingredient("ingredient name",number of ingredients)}, RECIPETABS.your recipe tab, TECH.(ex. TECH.SCIENCE_TWO) TECH LEVEL, nil, nil, nil, nil, "the tag you gave yourself")

3 hours ago, doraexplora said:

Thanks, it worked!

This is the code I used at first, I just found it online:

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

Ingredient = GLOBAL.Ingredient
TECH = GLOBAL.TECH

GLOBAL.Recipe("name", {Ingredient("ingredient name",number of ingredients), Ingredient("ingredient name",number of ingredients)}, RECIPETABS.your recipe tab, TECH.(ex. TECH.SCIENCE_TWO) TECH LEVEL, nil, nil, nil, nil, "the tag you gave yourself")

Yeaaah, this happens very commonly, don't worry! Basically there are some older methods of adding items that were used before the 2022 crafting menu update, and those methods are still listed in a lot of old threads and tutorials.They work, but they don't display properly with the newer crafting menu.

No problem, and good luck with your mod!

Edited by Chesed

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