In this tutorial we’ll set up new items to serve as our materials for crafting.
This tutorial is the start of the sub-series for setting up crafting.
A crafting recipe usually takes some ingredients and creates an outcome. We’ll set up new items for our crafting recipes to use as ingredients.
Learn more about the crafting system in this documentation.
Item Types #
First, we’ll set up new item types for our materials and crafting recipes.
Navigate to Inventory > Item Types, we’ll add 2 new item types.
Materials #
Add a new item type and change the following settings.
- Name
Set to: Materials - Description
Set to: Materials for crafting. - Sprite (Icon)
Select icons_97.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Type Settings #
- Damage Type
Select Default.
It’s not really needed as there’ll be no useable items in this item type, but it’s always a good idea to have it set up.
Recipes #
Add a new item type and change the following settings.
- Name
Set to: Recipes - Description
Set to: Recipes for crafting. - Sprite (Icon)
Select icons_142.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Type Settings #
- Damage Type
Select Default.
Items #
We’ll now set up a bunch of new items that’ll be used as materials (ingredients) in our crafting recipes.
Navigate to Inventory > Items, we’ll add several new items.
Empty Bottle #
Add a new item.
- Name
Set to: Empty Bottle - Description
Set to: Used to create potions. - Sprite (Icon)
Select icons_62.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Settings #
- Item Type
Select Materials.
Item Settings > Price Settings #
- Buy Price
Select Value > Value.
Set the value to 1. - Sellable
Enable this setting.
The default sell price settings should already be correct, selling for 50% of the original price.
- Sell Price
Select Value > Value.
Set the value to 50. - Sell In
Select Percent.
Use Settings #
- Useable In
Select None.
Strange Liquid #
Copy the Empty Bottle item and change the following settings.
- Name
Set to: Strange Liquid - Description
Set to: A bad smelling liquid coming from monsters.
Used to create various potions. - Sprite (Icon)
Select icons_199.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Settings > Price Settings #
- Buy Price
Select Value > Value.
Set the value to 3.
Slime #
Copy the Strange Liquid item and change the following settings.
- Name
Set to: Slime - Description
Set to: A slimy secretion.
Used to create magic potions. - Sprite (Icon)
Select icons_157.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Settings > Price Settings #
- Buy Price
Select Value > Value.
Set the value to 10.
Bone #
Copy the Slime item and change the following settings.
- Name
Set to: Bone - Description
Set to: A bone.
Used to create revive potions. - Sprite (Icon)
Select icons_57.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Settings > Price Settings #
- Buy Price
Select Value > Value.
Set the value to 20.
Venom #
Copy the Bone item and change the following settings.
- Name
Set to: Venom - Description
Set to: Venomous secretion.
Used to create antidote. - Sprite (Icon)
Select icons_166.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Settings > Price Settings #
- Buy Price
Select Value > Value.
Set the value to 5.
Bat Wing #
Copy the Venom item and change the following settings.
- Name
Set to: Bat Wing - Description
Set to: A wing of a bat.
Used to create cough drops. - Sprite (Icon)
Select icons_55.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Settings > Price Settings #
- Buy Price
Select Value > Value.
Set the value to 6.
Wood #
Copy the Bat Wing item and change the following settings.
- Name
Set to: Wood - Description
Set to: A piece of wood.
Used to create equipment. - Sprite (Icon)
Select icons_152.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Settings > Price Settings #
- Buy Price
Select Value > Value.
Set the value to 10.
Iron #
Copy the Wood item and change the following settings.
- Name
Set to: Iron - Description
Set to: An iron ingot.
Used to create equipment. - Sprite (Icon)
Select icons_143.
Click on the Find TMP Tag button to get the icon’s tag for displaying it in texts (via text codes). This uses TextMesh Pro’s sprite asset setup.
Item Settings > Price Settings #
- Buy Price
Select Value > Value.
Set the value to 20.
Save Changes #
And that’s it for the item setup.
Don’t forget to save your changes by clicking on Save Settings at the bottom of the editor.
Next, we’ll set up the crafting recipes.