Hello there! We are conducting a survey to better understand the user experience in making a first edit. If you have ever made an edit on Gamepedia, please fill out the survey. Thank you!

Template:G/Cell

From Feed The Beast Wiki
Jump to: navigation, search


Template-info.png Documentation
Lua logo.svg This template uses Module:Grid, a script written in Lua.
Please see wikipedia:wp:Lua and mw:Extension:Scribunto to learn more.

This template is the display logic for grids.

Parameters

All parameters are optional.

  • 1: The name of the item to display.
  • 2: 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.
  • style: Adds CSS styling to add to the cell.
  • numstyle: Adds CSS styling to the number.
  • no-bg: Disables the cell background.
  • link: Changes the article that the cell will link to. Set to "none" to disable links.
  • mod: Sets the item mod, if not provided, an extension will attempt to find the correct image to display. You can use both the mod abbreviation as defined in Module:Mods/list or the full mod name.
  • dis: If set, the link points directly to the item name, otherwise points to the disambiguated item name "Item name (Mod name)" if mod is set.

Usage

Cells of crafting grid templates are filled by calling {{Gc}} to reference specific items from specific mods, or by calling {{O}} to reference items by Ore Dictionary tags. In the past, {{G}} served both of these purposes, but it is not recommended for use anymore as it can have unpredictable results if not used correctly.

Examples

Code Result Comment
{{Gc|mod=V|dis=false|TNT|10}}

10
Normal usage

History

In the past, {{G}} was used to combine both {{G/Cell}} and {{G/O}} into one template, and was used all over the wiki. However, this is no longer the case; {{G}} has various issues associated with it- it is significantly slower (by about 2 times per use). Secondly, it very often displays the incorrect items. Therefor, {{G/Cell}} and {{G/O}} should always be used over it, and existing {{G}} usage should be converted to {{G/Cell}}/{{G/O}} usage.