Template:Recipes/register/doc

From Terraria Mods Wiki
Jump to navigation Jump to search

This template is used to store the data for a recipe into the cargo database.

Usage

{{recipes/register
| result = <result item name> | amount = <result item amount> | note = <note text> | image = <result item image>
| station = <crafting station name>
| <ingredient 1 name> | <ingredient 1 amount>
| <ingredient 2 name> | <ingredient 2 amount>
...
| <ingredient n name> | <ingredient n amount>
}}

For <crafting station name>, you can customize the text by registering it with {{recipes|station=[...]|title=[...]}} on <mod name>/Recipes/[station] subpages. This registration page must be in Category:<mod name>/Recipes for it to activate. Useful for multi-station recipes.

For <ingredient name>, you can use the following syntax to customize its image/note: <itemname>(#i:<image>)?(#n:<note>)?. You can use & to represent the item name in #i:<image>. Further more, #i:old is a shortcut for #i:& (old).png. For example: Tungsten Bar#i:old is same as Tungsten Bar#i:& (old).png and will get Tungsten BarTungsten Bar (same as the result of {{item|Tungsten Bar|image=Tungsten Bar (old).png}}).

Notes

  • All result and ingredient amounts are required, even if they are 1.
  • The note and image parameters are rarely used, and are only appropriate in edge cases.
  • This template shouldn't be used on normal pages, and instead should only be used on <mod name>/Recipes/[station]/register subpages. Here's a list of all those subpages: