Assigning crafting screen subcategories to new recipes

With the new crafting screen upgrade I thought it would be a good idea to explain how to assign new recipes to a subcategory.

Recipes must be given a “subcategory” field:

  "type" : "recipe",
  "result": "water_clean",
  "category": "CC_FOOD",
  "subcategory": "CSC_FOOD_DRINKS",

Any recipe without the subcategory field will be put in category->Other.

As you may be able to tell from the above example or may have noticed in game, the drinks category is gone. Drinks have been moved into a subcategory under food.

Valid category->subcategory combinations are:


[li]CSC_WEAPONS_PIERCING - (SPEAR or STAB flagged items)[/li]
[li]CSC_WEAPONS_EXPLOSIVES - (Not ammo)[/li]
[li]CSC_WEAPONS_OTHER - Anything else.[/li][/ul]


[li]CSC_AMMO_COMPONENTS - (Parts to make ammo)[/li]
[li]CSC_AMMO_OTHER - Anything else.[/li][/ul]


[li]CSC_FOOD_SNACK - (Junk food)[/li]
[li]CSC_FOOD_OTHER - Anything else. (Powders go here - Flour, Sugar, etc.[/li][/ul]


[li]CSC_CHEM_CHEMICALS - (Bleach, Disinfectant, etc.[/li]
[li]CSC_CHEM_OTHER - Anything else.[/li][/ul]




[ul][li]CSC_ARMOR_STORAGE - (Bags, packs, pouches, etc.)[/li]
[li]CSC_ARMOR_SUIT - (Covers whole body)[/li]
[li]CSC_ARMOR_BACK - (Cloaks and such)[/li]
[li]CSC_ARMOR_OTHER - Anything else.[/li][/ul]


[li]CSC_OTHER_CONTAINERS - (Liquid storage)[/li]
[li]CSC_OTHER_MATERIALS - (Glass, metal, etc.[/li]
[li]CSC_OTHER_PARTS - (Vehicle parts)[/li]
[li]CSC_OTHER_OTHER - Anything else.[/li][/ul]

One thing that might be useful is to allow some items to show up in multiple subcategories eventually. Like for example if there were a recipe to make gunpowder (not sure if there is or not), it might fall under both chemistry->other and ammo->components, or fusion packs in electronics->other and ammo->other.

That’s a good idea. I mean, hydrogen peroxide is both a drug(for its medical purpose) and a highly useful chemical reagent. I think.

While I agree that some things could belong in multiple places, the crafting menu is already so packed with stuff I really don’t want multiples