Crafting Grids are an important aspect of almost every article on the wiki, used to inform readers about how they can obtain the items and blocks they are reading about. This wiki has a dedicated set of templates, originally created by Template:U, for use in displaying these grids. It is extremely important that this template syntax is understood and used correctly by all editors. This guide page has been written for that purpose.
As a general note, remember to preview pages before you save them, until you fully understand how everything works and are comfortable with it. It allows you to make sure the page was built and displays correctly, and more importantly it allows you to make sure you did not make a mistake when calling a template (like, say, forgetting the brackets used to close it).
Basics[]
All Crafting Grid templates are named and called using the following convention:
{{Cg/name}}
For example:
- Crafting Table:
{{Cg/Crafting Table}}
- Furnace:
{{Cg/Furnace}}
- Macerator (IndustrialCraft 2):
{{Cg/Macerator}}
- Sawmill:
{{Cg/Sawmill}}
A full list of available crafting grid templates can be found here. If a crafting grid is not available, please post a request on the discussion board or be BOLD and make it yourself.
Each location within a crafting grid that can contain an item will have a specific cell name that corresponds to it. The cell names can vary across different grids, so it it is important to always read the templates’ documentation pages. If no item is to be placed in a specific cell of a crafting grid, it does not need to be entered into the template call. For example, when designating cells in {{Cg/Crafting Table}}
, the columns are (from left to right) A→C and the rows are (from top to bottom) 1→3, with the letter being first and the number second (A1 for the top-left cell).
The cells are filled by using the templates {{G/Cell}}
and {{G/O}}
: Template:Grid/Cell and Template:Grid/Ore Dictionary. These will be explained later in this guide, but in short, their purpose is to take the name of an item, or an Ore Dictionary tag name, and display an image of it, which also displays a tooltip when the mouse is hovered over it. The choice between which to use is dependent upon how the recipe in question is defined by the mod that adds it. To find that out, it is usually necessary to look through the mod’s source code for where the recipe is added. A program such as JD-GUI may be helpful for this, though many mods have their source visible in code repositories on websites such as GitHub and BitBucket.
Template:G/Cell[]
{{G/Cell}}
, abbreviated as {{Gc}}
, is the standard template used to display items. It requests an item name and an abbreviated mod name, and displays an image of that item and a link to that item’s page. A list of abbreviated mod names can be found here. {{Gc}}
can also accept an alternate page for the image to link to (or link=none for no link), alternate text to use for the tooltip, and a stack size to display for the item it displays. The text to use for the tooltip is defined with the parameters title=
and desc=
. title=
changes the displayed item name and desc=
adds additional lines of descriptive text to the tooltip. Both title=
and desc=
accept formatting codes as defined in {{Tooltip}}
. (Use / to produce a new line, & for formatting codes, and \ to end the use of a formatting code.) Related to link=
is dis=
, a true/false parameter (true
by default) that sets whether or not the image links to a mod-disambiguated page title (e.g., {{Gc|mod=V|dis=false|Stick}}
would link readers to Stick when clicked on; removing dis=false
would direct readers to Stick (Vanilla)). Do not define both dis=
and link=
in a single use of {{Gc}}
.
Shown below are one incorrect and four correct uses of {{Gc}}
:
This template is the display logic for grids. Parameters[]All parameters are optional, except for
Usage[]
Use To display items inside ordinary page text or tables, use For more information and examples, see the Crafting Grid Guide. Examples[]
History[]In the past, |
{{Gc|Certus Quartz}} |
Incorrect usage with no mod= parameter defined. When previewing the page, an error message will appear. | ||||||
This template is the display logic for grids. Parameters[]All parameters are optional, except for
Usage[]
Use To display items inside ordinary page text or tables, use For more information and examples, see the Crafting Grid Guide. Examples[]
History[]In the past, |
{{Gc|Crowbar|mod=RC}} |
Correct usage for an item whose page link requires disambiguation (as multiple mods add a Crowbar). | ||||||
This template is the display logic for grids. Parameters[]All parameters are optional, except for
Usage[]
Use To display items inside ordinary page text or tables, use For more information and examples, see the Crafting Grid Guide. Examples[]
History[]In the past, |
{{Gc|Stone Fluid Pipe|mod=BC|dis=false}} |
Correct usage for an item whose page links do not require disambiguation. | ||||||
This template is the display logic for grids. Parameters[]All parameters are optional, except for
Usage[]
Use To display items inside ordinary page text or tables, use For more information and examples, see the Crafting Grid Guide. Examples[]
History[]In the past, |
{{Gc|Iron Ingot|4|mod=V|link=Iron}} |
Correct usage for an item, with a stack size of 4, which should link to a page different from its listed name. | ||||||
This template is the display logic for grids. Parameters[]All parameters are optional, except for
Usage[]
Use To display items inside ordinary page text or tables, use For more information and examples, see the Crafting Grid Guide. Examples[]
History[]In the past, |
{{Gc|Low Voltage Battery Buffer (1)|mod=GT|link=Battery Buffer|title=Low Voltage Battery Buffer|desc=&71 Slot}} |
Correct usage for an item whose tilesheet name is not the same as the name that should be displayed, should link to a page different from its name, and has additional tooltip text. |
If a mod= parameter is not properly defined, the following error will be displayed: File:Multiple entries tilesheet.png
Shown below is the template call for the recipe of a Diamond Pickaxe as it would be defined in vanilla Minecraft.
{{Cg/Crafting Table |A1={{Gc|mod=V|dis=false|Diamond}} |B1={{Gc|mod=V|dis=false|Diamond}} |C1={{Gc|mod=V|dis=false|Diamond}} |B2={{Gc|mod=V|dis=false|Stick}} |B3={{Gc|mod=V|dis=false|Stick}} |O={{Gc|mod=V|dis=false|Diamond Pickaxe}} }}
This code produces: Template:Cg/Crafting Table
Template:Grid/Ore Dictionary[]
The Ore Dictionary is a component of Minecraft Forge, designed to allow ores and ingots of the same type to be used by different mods and treated as the same. The FTB Wiki contains an OreDict extension, allowing Crafting Grid displays to do the same.
{{G/O}}
, abbreviated to {{O}}
, is the normal way to display an object in a crafting grid, in which the crafting recipe uses the Ore Dictionary to determine recipe inputs. {{O}}
is called using an Ore Dictionary tag name rather than an item name. A full list of all currently registered Ore Dictionary tags and the items they correspond to can be found on Special:OreDictList. Ore Dictionary tags can be added on Special:ImportOreDict. Like {{Gc}}
, {{O}}
accepts an item stack size parameter, but unlike {{Gc}}
, {{O}}
does not request any other parameters. Additionally, {{O}}
automatically animates itself, alternating its display among all possible items.
Shown below is an isolated use of {{O}}
.
{{O|oreCopper}}
This code produces:
Lua error: callParserFunction: function "#dict" was not found.
Shown below is the template call for the recipe of a Diamond Pickaxe, using the Ore Dictionary.
{{Cg/Crafting Table |A1={{O|gemDiamond}} |B1={{O|gemDiamond}} |C1={{O|gemDiamond}} |B2={{O|stickWood}} |B3={{O|stickWood}} |O={{Gc|mod=V|dis=false|Diamond Pickaxe}} }}
This code produces:
Template:Cg/Crafting Table
{{O}}
should not be used for displaying crafting grid outputs (O=
) unless the mod actually outputs an OreDictionary tag instead of a specific item. However, this is generally considered a bug in the mod and should be reported to the author(s) immediately.
Tilesheets[]
The images displayed by {{Gc}}
and {{O}}
are retrieved from Tilesheets, large image files of every block and item added by a mod, and linked to by a server-side registry. A list of all tilesheets currently on the wiki can be found on Special:SheetList and a list of all items stored in all sheets can be found on Special:TileList. If {{Gc}}
is given the name of an item that does not appear in a tilesheet, or is given the wrong mod name, {{Gc}}
will display a flat red box. An example is shown below.
{{Gc|mod=AE|This Item Does Not Exist}}
Produces:
This template is the display logic for grids.
Parameters[]
All parameters are optional, except for mod
.
- 1: The name of the item to display.
- 2: (Default: 1) The amount of the item to display.
- title: Tooltip title override. See Template:Tooltip/doc for formatting information.
- desc: Tooltip description override. See Template:Tooltip/doc for formatting information.
- class: Adds a class to the cell.
- align: Change vertical-alignment of cell to surrounding text.
- padding: Sets the padding of the grid icon; useful for the
{{Effect}}
template. - style: Adds CSS styling to add to the cell.
- numstyle: Adds CSS styling to the number.
- size: (Default: 32) Sets the icon size to retrieve. If an invalid size is provided, the smallest size is used (usually 16).
- no-bg: Disables the cell background.
- appendtitle: If set, turns the
title
arg into a string that is appended onto the localized item name. If you want a space between the localized name and the appended string, you must start with<nowiki />
and then the space. - link: Changes the article that the cell will link to. Set to "none" to disable links.
- mod: Sets the mod that the item comes from. You can use both the mod abbreviation as defined in Module:Mods/list or the full mod name. The mod abbreviation is recommended for standardization purposes.
- dis: By default, points to the disambiguated item name in the form
Item (Mod)
. Otherwise, if set tofalse
or any other value, the link points directly to the item name.
Usage[]
{{Gc}}
is used to display items, for use in Crafting Grid templates ({{Cg}}
) and Infobox templates ({{Infobox}}
).
Use {{Cg}}
to display single items, or {{O}}
if the crafting recipe uses Ore Dictionary tags to determine allowable items.
To display items inside ordinary page text or tables, use {{P}}
or {{Pn}}
.
For more information and examples, see the Crafting Grid Guide.
Examples[]
Code | Result | Comment |
---|---|---|
{{Gc|mod=V|dis=false|TNT|10}} |
Template loop detected: Template:Gc | Normal usage |
History[]
In the past, {{G}}
was used to combine both {{G/Cell}}
and {{G/O}}
into one template (assisted by the now-removed {{G?}}
), and was used all over the wiki. However, this is no longer the case; {{G}}
had various issues associated with performance and incorrect displays. Therefore, all existing {{G}}
usage was converted to {{G/Cell}}
/{{G/O}}
, and, with the creation of Module:Grid, {{G}}
was fully removed and now redirects to {{G/Cell}}
.
The above documentation is transcluded from Lua error in Module:Language at line 52: attempt to call field 'normDefault' (a nil value).. (edit | history)
<languages />
If this occurs, an error will also appear under Tilesheet extension warnings in the page preview.
File:No item tilesheet.png
If this occurs when editing a page, check to make sure the mod abbreviation and item name are set correctly (check the Item List to be sure), and if you are sure that the red box comes from a missing tilesheet entry, finish your editing, save the page, and report the missing entry on the Tilesheet requests page.
In certain rare cases, the name of an item in a tilesheet will not match the name of the item in game. This is usually done deliberately by the wiki staff member who set up the tilesheet, as an individual tilesheet cannot contain two items with identical names. If this is the case, the {{Gc}}
parameter title= should be used to change the tooltip to display the correct item name.
Mod abbreviations can be added and viewed on Module:Mods/list, as well as on the Template:FTB-Wiki-IRC, using Template:U’s bot.
Shapeless crafting recipes[]
Shapeless crafting recipes are defined in the same way as shaped crafting recipes, but with one additional parameter and a somewhat different display. To define a crafting recipe as shapeless, add the parameter shapeless=true to the crafting grid template call. Shown below is an example of a shapeless crafting recipe.
{{Cg/Crafting Table |A1={{O|dustCopper}} |B1={{O|dustCopper}} |A2={{O|dustCopper}} |B2={{O|dustTin}} |O={{Gc|mod=IC2|link=Bronze|Bronze Dust}} |shapeless=true }}
This code produces: Template:Cg/Crafting Table
Multiple recipes in a single grid[]
Multiple crafting recipes can be defined within a single crafting grid. To do so, simply give multiple separate items to a single crafting grid slot. The grid will become paged, with each page displaying an individual recipe.
If an item is only defined once in a crafting grid slot, it will be used in that slot in all displayed recipes. To display a blank slot in a grid, define an empty {{Gc}}
in that slot.
An example of a paged crafting grid is shown below.
{{Cg/Crafting Table |A1={{Gc|mod=V|link=Iron|Iron Ingot}} |B1={{Gc|mod=V|link=Iron|Iron Ingot}} |C1={{Gc|mod=V|link=Iron|Iron Ingot}}{{Gc}} |A2={{Gc|mod=V|link=Iron|Iron Ingot}} |B2={{Gc|mod=V|dis=false|Stick}}{{Gc|mod=V|link=Iron|Iron Ingot}} |C2={{Gc|mod=V|link=Iron|Iron Ingot}}{{Gc|mod=V|dis=false|Stick}} |A3={{Gc|mod=V|link=Iron|Iron Ingot}}{{Gc}} |B3={{Gc|mod=V|dis=false|Stick}}{{Gc|mod=V|link=Iron|Iron Ingot}} |O={{Gc|mod=IC2|Forge Hammer}}{{Gc|mod=GT|Hammer}} }}
This code produces: Template:Cg/Crafting Table
Alternatively, editors may wish to use {{N}}
to animate cells, especially if there are many possible candidates for a component but excludes a few such that {{O}}
cannot be used.
{{Cg/Crafting Table |A1={{N|begin}}{{Gc|mod=V|dis=false|Oak Wood Planks}}{{Gc|mod=V|dis=false|Birch Wood Planks}}{{N|end}} |A2={{N|begin}}{{Gc|mod=V|dis=false|Oak Wood Planks}}{{Gc|mod=V|dis=false|Birch Wood Planks}}{{N|end}} |O={{Gc|mod=V|dis=false|Stick|4}} }}
This code produces:
Template:Cg/Crafting Table
Special crafting grid inputs[]
Tank Cells[]
Tank Cells are not a feature used in all crafting grids, but certain mods add machines that have internal fluid tanks, and have recipes that consume fluid from those tanks. Tank cells are never used in isolation; they are only ever used in crafting grids that would use them. Tank cells are filled using {{T}}
, Template:Tank. {{T}}
is called with a fluid name and an amount in mB, millibuckets.
A small number of alternate crafting grids also have areas in them that show internal energy storage and/or energy consumed by a recipe. These visual displays also use {{T}}
. An example of this is shown below
{{Cg/Liquid Transposer |I={{Gc|Bucket|mod=V}} |O={{Gc|Water Bucket|mod=V}} |tank={{T|Water|1000}} |power={{T|Redstone Flux|4000}} }}
This code produces: Template:Cg/Liquid Transposer
Text strings[]
Certain crafting recipes require strings of text or numbers as inputs to their recipes. For cases like this, use {{S}}
.
Shown below is an example of a (rather complicated) crafting grid that requires string inputs.
{{Cg/Blast Furnace/RotaryCraft |I1={{Gc|mod=V|Sand}} |I2={{Gc|mod=V|dis=false|Coal}} |I3={{Gc|mod=V|Gunpowder}} |I4={{Gc|mod=V|Iron Ingot}} |I5={{Gc|mod=V|Iron Ingot}} |I6={{Gc|mod=V|Iron Ingot}} |I7={{Gc|mod=V|Iron Ingot}} |I8={{Gc|mod=V|Iron Ingot}} |I9={{Gc|mod=V|Iron Ingot}} |I10={{Gc|mod=V|Iron Ingot}} |I11={{Gc|mod=V|Iron Ingot}} |I12={{Gc|mod=V|Iron Ingot}} |O2={{Gc|mod=ROC|link=none|HSLA Steel Ingot|9}} |Temp=600 |T1={{S|Coal x1 (100.0%)}} |T2={{S|Gunpowder x1 (3.6%)}} |T3={{S|Sand x1 (0.2%)}} |Bonus={{S|No}} }}
This code produces: Template:Cg/Blast Furnace/RotaryCraft
What not to do[]
While {{Gc}}
and {{O}}
can be used outside of crafting grids, the images they produce are sized and formatted specifically for use in crafting grids, and as such they do not fit well into the text of regular pages. Using them in an {{Infobox}}
is, however, expected. Using {{P}}
and {{Pn}}
is preferred in tables or in text.
When in doubt, view the source of some pages recently created, or ask editors for help.
Template:Navbox portals
<languages />