새로 오신 분들은 길라잡이를 꼭 읽어주세요.

문서의 정리·작성번역을 도와주시면 마인크래프트 위키에 큰 힘이 됩니다.

Hi Gamepedia users and contributors! Please complete this survey to help us learn how to better meet your needs in the future. We have one for editors and readers. This should only take about 7 minutes!

틀:격자/설명문서

Minecraft Wiki
이동: 둘러보기, 검색
이 문서는 설명문서입니다. 틀 페이지 본문에 삽입되어야 합니다. 자세한 정보는 틀:설명문서를 참조하십시오.
Lua logo.svg
이 틀은 모듈:격자을(를) 사용하고 모듈:Grid/Aliases에 저장된 데이터를 참조하는,
루아로 작성된 스크립트입니다. 자세히 알아보려면 루아 혹은 mw:Extension:Scribunto를 참조하십시오.

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 <Name>.png, within it.

Usage[원본 편집]

All inputs are optional:

{{Grid
|[Title]Mod:Name,Amount[Description]; [Title2]Mod2:Name2,Amount2[Description2]
|mod=Default mod (useful for animations and layout templates)
|default=Image always shown under the main image
|align=Vertical Alignment
|link=Link override
|title=Text show on mouseover
|class=Adds additional classes to the .grid class
|style=Adds styling to the .grid
|imgclass=Adds additional classes to the .item
|numstyle=Adds styling to the number
}}

Parts[원본 편집]

The first parameter is a special parameter consisting of various "parts" grouped together in frames (delimited by ;) which will be display one after another if JavaScript is enabled. Every part is optional, but without "name", won't do anything.

Simple example[원본 편집]

To display this image File:Grid Raw Porkchop.png with an amount of 20 you would put: {{Grid|Raw Porkchop,20}}

shows


20

An amount of 2–999 is supported, anything else will not be displayed.

If no image is specified, the background will be added on its own, this could be used to do layouts like so:

{{Grid|TNT}}{{Grid|TNT}}{{Grid}}{{Grid}}{{Grid|TNT}}{{Grid|TNT}}<br>
{{Grid|TNT}}{{Grid|TNT}}{{Grid}}{{Grid}}{{Grid|TNT}}{{Grid|TNT}}<br>
{{Grid}}{{Grid}}{{Grid|TNT}}{{Grid|TNT}}{{Grid}}{{Grid}}<br>
{{Grid}}{{Grid|TNT}}{{Grid|TNT}}{{Grid|TNT}}{{Grid|TNT}}{{Grid}}<br>
{{Grid}}{{Grid|TNT}}{{Grid|TNT}}{{Grid|TNT}}{{Grid|TNT}}{{Grid}}<br>
{{Grid}}{{Grid|TNT}}{{Grid}}{{Grid}}{{Grid|TNT}}{{Grid}}
shows


























However this is really inefficient and produces ugly code, so don't do this. Use Template:BlockGrid or Template:Schematic instead.

Aliases[원본 편집]

Note: Banner variations are not included due to how many there are.

The above aliases can be used to shorten common items, such as all wood blocks or adding parts to certain names by default.

{{Grid|Any Wood;Golden Apple}}

shows









When using the alias, parts can be added which will override any parts in the alias.

{{Grid|Any Wood,4;[&oShiny Apple]Enchanted Golden Apple}}

shows


4

4

4

4

4

4


Mods can specify an additional aliases table using the modaliases parameter.

Titles and description[원본 편집]

The title parameter can be used to set a title for all frames.

{{Grid|Raw Porkchop; Cooked Porkchop|title=Smelly Pork}}

shows




To remove the title, set it to "none": {{Grid|Raw Porkchop; Cooked Porkchop|title=none}}

shows




However, the first bracketed text can be used to specify a title for each frame individually, and also supports standard formatting codes using & instead of §. If the title only contains formatting codes and no actual text, the formatting will be added to the normal title.

{{Grid|[&e]Enchanted Book}}

shows



The last bracketed text can be used to specify a description, this also supports standard formatting codes, and can also have multiple lines by using forward slashes (/).

{{Grid|[&b&oExcalibur]Iron Sword[&7Smite V/Fire Aspect I//&9+6 Attack Damage]}}

shows


Align[원본 편집]

Align uses the vertical-align CSS property. For example to align to the middle: Smells like {{Grid|Raw Porkchop|align=middle}} in here!

shows

Smells like
in here!

Default[원본 편집]

Default is always shown and is placed under the image. {{Grid|default=layout Brewing Empty}}{{Grid|Splash Mundane Potion|default=layout Brewing Empty}}

shows


Link[원본 편집]

To change the link for all frames from the image name put: {{Grid|Charcoal|link=Coal#Charcoal}}

shows



To remove the link, set link to none: {{Grid|Charcoal|link=none}}

shows


Note that this retains the title.


Mods[원본 편집]

A mod image is specified with the Mod: section of the name (or by setting a default mod using 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 by uploaded as Grid <Name> (<Mod>).png 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|IndustrialCraft:Bronze Sword}} (or {{Grid|mod=IndustrialCraft|Bronze Sword}})

shows

Bronze Sword


Grids can be animated with a theoretically unlimited amount of frames, between mod items and vanilla items. Frames are separated by semi-colons (;).

{{Grid|
Dirt;
TNT,64;
IndustrialCraft:Bronze Sword,6;
;
Grass Block,5;
Sand;
Gold Helmet,12;
IndustrialCraft:Bronze Helmet,2;
IndustrialCraft:Copper,50;
Redstone
}}
shows



64
Bronze Sword6
5

Gold Helmet12Bronze Helmet2Copper50

As you can see, the mod had to be specified for each mod frame, this is where the default mod parameter is useful. {{Grid|mod=IndustrialCraft|Bronze Sword,6; ; Bronze Helmet,12; Copper,50; Copper Dust}}

shows

Bronze Sword6Bronze Helmet12Copper50Copper Dust

To use a vanilla minecraft item when a default mod is set, use "vanilla" (shortcut "v") or "minecraft" (shortcut "mc") as the mod (case insensitive).

{{Grid|mod=IndustrialCraft|
Vanilla:Dirt;
vanilla:TNT,64;
Bronze Sword,6;
;
V:Grass Block,5;
v:Sand;
Minecraft:Gold Helmet,12;
Bronze Helmet,2;
Copper,50;
mc:Redstone Dust
}}
shows



64
Bronze Sword6
5

Gold Helmet12Bronze Helmet2Copper50

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. 틀:Grid/See also