The grid template is a singular grid cell, which has the ability to display any image (usually a block or item) that is uploaded as Grid {{{1}}}.png, within it.
== Usage ==
Put
{{Grid|Name}}}
where you want the image.
All inputs are optional (however Amount, Mod, Link and Title won't do anything without Name):{{Grid|Name|Amount|mod=Mod item|default=Image always shown under the Name image|align=Vertical Alignment|link=Link override|title=Title, removes link|class=Adds additional classes to the .grid class}}
== Examples ==
To display this image File:Grid Raw Porkchop.png with an amount of 20 you would put: {{Grid|Raw Porkchop|20}}
;which will result in:
32px2020
Amount supports from 2 - 999, anything else will not be displayed.
{{Grid|TNT}}{{Grid|TNT}}{{Grid}}{{Grid}}{{Grid|TNT}}{{Grid|TNT}}<br><br />{{Grid|TNT}}{{Grid|TNT}}{{Grid}}{{Grid}}{{Grid|TNT}}{{Grid|TNT}}<br><br />{{Grid}}{{Grid}}{{Grid|TNT}}{{Grid|TNT}}{{Grid}}{{Grid}}<br><br />{{Grid}}{{Grid|TNT}}{{Grid|TNT}}{{Grid|TNT}}{{Grid|TNT}}{{Grid}}<br><br />{{Grid}}{{Grid|TNT}}{{Grid|TNT}}{{Grid|TNT}}{{Grid|TNT}}{{Grid}}<br><br />{{Grid}}{{Grid|TNT}}{{Grid}}{{Grid}}{{Grid|TNT}}{{Grid}}
;which will result in:
32px 32px 32px 32px
32px 32px 32px 32px
32px 32px
32px 32px 32px 32px
32px 32px 32px 32px
32px 32px
A mod image is specified with the mod parameter. The image link will then link to the mod sub-page allowing correct linking of mod images. The uploaded image name should also have (<Modname>) at the end and should be added to the Grid mods category, which prevents them from being confused with official Minecraft items.
For example, to display this mod image File:Grid Bronze Sword (IndustrialCraft).png: {{Grid|mod=IndustrialCraft|Bronze Sword}}
;which will result in:
32px
Animation is fully supported up to 16 frames, frames are separated by commas. However, mod and normal items cannot be combined in a single animation.{{Grid|Grass Block,Dirt,,TNT,Sand|5,,8,64}}{{Grid|mod=IndustrialCraft|Bronze Sword,,Bronze Helmet,Copper,Copper Dust|6,,12,50}}
;which will result in:
32px55 32px646432px 32px66 32px121232px505032px
If more than 16 frames are added then the page will be added to the Too many frames category and the extra frames will not be displayed. If you don't know how to add more frames, request for them to be added on the talk page.
Align supports anything vertical-align supports, for example to align to the middle:Smells like {{Grid|Raw Porkchop|align=middle}} in here!
;which will result in:
Smells like 32px in here!
Default is always shown and is placed under the image. {{Grid|default=layout Brewing Empty}}{{Grid|Splash Mundane Potion|default=layout Brewing Empty}}
;which will result in:
File:Grid layout Brewing Empty.png File:Grid layout Brewing Empty.png32px
To change the link from the image name put: {{Grid|Charcoal|link=Coal#Charcoal}}
;which will result in:
32px
To remove the link, set link to none: {{Grid|Charcoal|link=none}}
;which will result in:
32px
Note that this will retain the title.
To add a different title, put: {{Grid|Raw Porkchop|title=Smelly Pork}}
;which will result in:
32px
To remove the title, set title to none: {{Grid|Raw Porkchop|title=}}
32px
Note that setting title will remove the link, this is due to the automatic titling of a link overwriting what title is set to.
Template:Grid/Available images
== Other templates ==
These templates implement this template into a GUI screen which mimics how it would look in Minecraft. Thus, they have mostly the same features as this template.
Template:Grid/See also
fr:Modèle:Grille/doc