Template:AnimateSprite: Difference between revisions

From Horizon's End Wiki
Template_>IcyPhantom
(closing)
 
No edit summary
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
<includeonly>{{#invoke: AnimateSprite | animate }}</includeonly><noinclude>
This template was ported from https://minecraft.wiki. It is licensed under CC BY-NC-SA 3.0
{{documentation}}
 
<!-- Put categories/interwiki on the documentation page --></noinclude>
Using this template, you can create tables like those commonly used in the “Crafting” and “Crafting ingredient” sections of articles about blocks and items. It can be used similarly to {{tl|Crafting Table}}, except it creates the table for you.
 
By default, the table generates with 3 columns: Name, Ingredients, and the main column containing {{tl|Crafting Table}}. You can set the parameter <code><nowiki>{{{showname=1}}}</nowiki></code> or <code><nowiki>{{{showname=0}}}</nowiki></code> in the first template of the table to show or hide the Name column. To group multiple crafting templates into one table, you also need to set <code><nowiki>{{{head=1}}}</nowiki></code> in the first template of the table, and <code><nowiki>{{{foot=1}}}</nowiki></code> in the last. A 4th column called Description can be added with <code><nowiki>{{{showdescription=1}}}</nowiki></code> and <code><nowiki>{{{description=The description for the recipe}}}</nowiki></code>.
 
Displaying a shapeless recipe can be accomplished by simply leaving out the grid positions for all ingredients. If the recipe is shapeless and uses less than 5 slots, the template will automatically arrange the items into the bottom-left square, indicating that the recipe can be used in the inventory crafting area.
 
If using this template outside of the “Crafting” section (e. g. instead of {{tl|Crafting usage}} or together with it), it is '''highly important''' that the <code><nowiki>{{{ignoreusage}}}</nowiki></code> parameter must be set to 1. This will ensure that the template would not be tracked by {{tl|Crafting usage}} which could lead to issues with that template on other articles.
 
Example usage:
<pre>
{{Crafting
  |head=1
  |B2=Coal
  |B3=Stick
  |Output=Torch,4
  |showdescription=1
  |description=The description cell can contain ''formatted'' text.
}}
{{Crafting
  |Blaze Powder
  |Gunpowder
  |Coal
  |Output=Fire Charge,3
  }}
{{Crafting
  |A1= Coal |B1= Coal |C1= Coal
  |A2= Coal |B2= Coal |C2= Coal
  |A3= Coal |B3= Coal |C3= Coal
  |Output=Block of Coal
}}
{{Crafting
  |name=[[Pickaxe]]
  |ingredients=[[Stick]]s +<br>[[Planks]] or<br> [[Cobblestone]] or<br>[[Iron Ingot]]s or<br>[[Gold Ingot]]s or<br>[[Diamond]]s
  |A1=Oak Planks; Cobblestone; Iron Ingot; Gold Ingot; Diamond
  |B1=Oak Planks; Cobblestone; Iron Ingot; Gold Ingot; Diamond
  |C1=Oak Planks; Cobblestone; Iron Ingot; Gold Ingot; Diamond
  |B2=Stick
  |B3=Stick
  |Output=Wooden Pickaxe; Stone Pickaxe; Iron Pickaxe; Golden Pickaxe; Diamond Pickaxe
  |foot=1
}}
</pre>
produces:
 
{{Crafting
  |head=1
  |B2=Coal
  |B3=Stick
  |Output=Torch,4
  |showdescription=1
  |description=The description cell can contain ''formatted'' text.
}}
{{Crafting
  |Blaze Powder
  |Gunpowder
  |Coal
  |Output=Fire Charge,3
  }}
{{Crafting
  |A1= Coal |B1= Coal |C1= Coal
  |A2= Coal |B2= Coal |C2= Coal
  |A3= Coal |B3= Coal |C3= Coal
  |Output=Block of Coal
}}
{{Crafting
  |name=[[Pickaxe]]
  |ingredients=[[Stick]]s +<br>[[ Planks]] or<br> [[Cobblestone]] or<br>[[Iron Ingot]]s or<br>[[Gold Ingot]]s or<br>[[Diamond]]s
  |A1=Oak Planks; Cobblestone; Iron Ingot; Gold Ingot; Diamond
  |B1=Oak Planks; Cobblestone; Iron Ingot; Gold Ingot; Diamond
  |C1=Oak Planks; Cobblestone; Iron Ingot; Gold Ingot; Diamond
  |B2=Stick
  |B3=Stick
  |Output=Wooden Pickaxe; Stone Pickaxe; Iron Pickaxe; Golden Pickaxe; Diamond Pickaxe
  |foot=1
}}
 
== Details ==
{{TemplateData}}
<templatedata>
{
"params": {
"1": {
"label": "First ingredient",
"description": "First ingredient in a shapeless recipe",
"example": "Flint",
"type": "string"
},
"2": {
"label": "Second ingredient",
"description": "Second ingredient in a shapeless recipe",
"type": "string",
"example": "Iron Ingot"
},
"3": {
"label": "Third ingredient",
"description": "Third ingredient in a shapeless recipe",
"type": "string"
},
"4": {
"label": "Fourth ingredient",
"description": "Fourth ingredient in a shapeless recipe",
"type": "string"
},
"5": {
"label": "Fifth ingredient",
"description": "Fifth ingredient in a shapeless recipe",
"type": "string"
},
"6": {
"label": "Sixth ingredient",
"description": "Sixth ingredient in a shapeless recipe",
"type": "string"
},
"7": {
"label": "Seventh ingredient",
"description": "Seventh ingredient in a shapeless recipe",
"type": "string"
},
"8": {
"label": "Eighth ingredient",
"description": "Eighth ingredient in a shapeless recipe",
"type": "string"
},
"9": {
"label": "Ninth ingredient",
"description": "Ninth ingredient in a shapeless recipe",
"type": "string"
},
"A1": {
"label": "Top left slot",
"description": "Specifies ingredients in the top left slot",
"example": "{Any Planks}; {Any stone-tier block}; Iron Ingot; Gold Ingot; Diamond",
"type": "string",
"suggested": true
},
"B1": {
"label": "Top slot",
"description": "Specifies ingredients in the top slot",
"example": "{Any Planks}; {Any stone-tier block}; Iron Ingot; Gold Ingot; Diamond",
"type": "string",
"suggested": true
},
"C1": {
"label": "Top right slot",
"description": "Specifies ingredients in the top right slot",
"example": "{Any Planks}; {Any stone-tier block}; Iron Ingot; Gold Ingot; Diamond",
"type": "string",
"suggested": true
},
"A2": {
"label": "Left slot",
"description": "Specifies ingredients in the left slot",
"type": "string",
"suggested": true
},
"B2": {
"label": "Middle slot",
"description": "Specifies ingredients in the middle slot",
"example": "Stick",
"type": "string",
"suggested": true
},
"C2": {
"label": "Right slot",
"description": "Specifies ingredients in the right slot",
"type": "string",
"suggested": true
},
"A3": {
"label": "Bottom left slot",
"description": "Specifies ingredients in the bottom left slot",
"type": "string",
"suggested": true
},
"B3": {
"label": "Bottom slot",
"description": "Specifies ingredients in the bottom slot",
"example": "Stick",
"type": "string",
"suggested": true
},
"C3": {
"label": "Bottom right slot",
"description": "Specifies ingredients in the bottom right slot",
"type": "string",
"suggested": true
},
"shapeless": {
"label": "Shapeless recipe override",
"description": "Forces shapeless recipe mode if \"top left slot\" and similar parameters are used.",
"type": "unknown",
"suggestedvalues": [
"1"
],
"default": "Shapeless mode is automatically enabled when \"first ingredient\" parameter is used.",
"autovalue": "1"
},
"fixed": {
"label": "Fixed recipe mode",
"description": "Enables fixed recipe mode for cases when ingredient layout cannot be mirrored (usually for banners)",
"type": "unknown",
"suggestedvalues": [
"1"
],
"autovalue": "1"
},
"Output": {
"label": "Recipe output",
"description": "Sets the recipe's output. If multiple blocks or items are crafted simultaneously, make sure to specify the number after a comma.",
"example": "Wooden Pickaxe; Stone Pickaxe; Iron Pickaxe; Gold Pickaxe; Diamond Pickaxe",
"type": "string",
"suggested": true
},
"notfixed": {
"label": "Ingredient that is not fixed",
"description": "For fixed recipes, describes the ingredient that can be placed in any free slot as an exception.",
"example": "the banner"
},
"head": {
"label": "Table header",
"description": "Sets this template instance as the first one in a sequence.",
"suggestedvalues": [
"1"
],
"autovalue": "1"
},
"foot": {
"label": "Table footer",
"description": "Sets this template instance as the last one in a sequence.",
"suggestedvalues": [
"1"
],
"autovalue": "1"
},
"showname": {
"label": "Name column control",
"description": "Controls whether to display the \"name\" column which lists what block(s) or item(s) is/are made by the recipe. Value of 1 makes the column show, any other values disable it. For multi-template tables, only set this parameter in the first template (which as the \"head\" parameter set).",
"suggestedvalues": [
"0",
"1"
],
"default": "The name column is shown by default when the template has the \"head\" parameter set to 1; subsequent templates in the sequence use the first one's value. The column is not shown when the template is standalone.",
"autovalue": "1"
},
"showdescription": {
"label": "Description column control",
"description": "Controls whether to display the description column. Value of 1 makes it show, any other values disable it. For multi-template tables, only set this parameter in the first template (which as the \"head\" parameter set).",
"suggestedvalues": [
"1"
],
"default": "The column is not shown by default. In template sequences, templates use the same value as the first template.",
"autovalue": "1"
},
"name": {
"label": "Name override",
"description": "Overrides what is displayed in the Name cell.",
"example": "Any Pickaxe (except Netherite)",
"type": "content",
"default": "The name is inferred automatically from the output slot."
},
"description": {
"label": "Additional desciption",
"description": "Provides an additional description to the recipe, such as edition exclusivity or upcoming version which will add the recipe. Make sure to set the \"showdescription\" parameter, or it will not show.",
"type": "content"
},
"ingredients": {
"label": "Ingredients override",
"description": "Overrides what is displayed in the Ingredients cell.",
"type": "content",
"default": "The ingredients are inferred automatically."
},
"ignoreusage": {
"label": "Ignored by Crafting usage",
"description": "Sets the template to be ignored by the Crafting usage template. This means the recipe will not appear in the \"Crafting ingredient\" subsection of \"Usage\" on other articles. When not using the template inside the \"Crafting\" subsection of \"Obtaining\", this parameter is mandatory to avoid issues with Crafting usage.",
"suggestedvalues": [
"1"
],
"autovalue": "1"
},
"nocat": {
"label": "Disable categories",
"description": "Sets the template to not add the page to any category. For technical reasons, this will also imply \"ignoreusage\" because Crafting usage relies on hidden categories set by this template.",
"suggestedvalues": [
"1"
],
"default": "Categories are not added on subarticles or outside of the article namespace.",
"autovalue": "1"
},
"type": {
"label": "Recipe type",
"description": "Sets the category for this recipe. If set, the recipe will be automatically added to the corresponding subsection in the Crafting article's \"Complete recipe list\" section. Has no effect if \"ignoreusage\" parameter is active.",
"example": "Combat",
"type": "string",
"suggestedvalues": [
"Building blocks",
"Decoration blocks",
"Redstone",
"Transportation",
"Foodstuffs",
"Tools",
"Utilities",
"Combat",
"Brewing",
"Materials",
"Miscellaneous"
]
}
},
"description": "Builds a table that lists crafting recipes. Slot/ingredient parameters use the same syntax as Inventory slot.",
"paramOrder": [
"A1",
"B1",
"C1",
"A2",
"B2",
"C2",
"A3",
"B3",
"C3",
"1",
"2",
"3",
"4",
"5",
"6",
"7",
"8",
"9",
"Output",
"ignoreusage",
"type",
"shapeless",
"fixed",
"notfixed",
"head",
"foot",
"showdescription",
"description",
"showname",
"name",
"ingredients",
"nocat"
],
"format": "\n{{_\n|_ = _\n}}\n"
}</templatedata>

Latest revision as of 22:06, 16 February 2025

This template was ported from https://minecraft.wiki. It is licensed under CC BY-NC-SA 3.0

Using this template, you can create tables like those commonly used in the “Crafting” and “Crafting ingredient” sections of articles about blocks and items. It can be used similarly to {{Crafting Table}}, except it creates the table for you.

By default, the table generates with 3 columns: Name, Ingredients, and the main column containing {{Crafting Table}}. You can set the parameter {{{showname=1}}} or {{{showname=0}}} in the first template of the table to show or hide the Name column. To group multiple crafting templates into one table, you also need to set {{{head=1}}} in the first template of the table, and {{{foot=1}}} in the last. A 4th column called Description can be added with {{{showdescription=1}}} and {{{description=The description for the recipe}}}.

Displaying a shapeless recipe can be accomplished by simply leaving out the grid positions for all ingredients. If the recipe is shapeless and uses less than 5 slots, the template will automatically arrange the items into the bottom-left square, indicating that the recipe can be used in the inventory crafting area.

If using this template outside of the “Crafting” section (e. g. instead of {{Crafting usage}} or together with it), it is highly important that the {{{ignoreusage}}} parameter must be set to 1. This will ensure that the template would not be tracked by {{Crafting usage}} which could lead to issues with that template on other articles.

Example usage:

{{Crafting
  |head=1
  |B2=Coal
  |B3=Stick
  |Output=Torch,4
  |showdescription=1
  |description=The description cell can contain ''formatted'' text.
}}
{{Crafting
  |Blaze Powder
  |Gunpowder
  |Coal
  |Output=Fire Charge,3
  }}
{{Crafting
  |A1= Coal |B1= Coal |C1= Coal
  |A2= Coal |B2= Coal |C2= Coal
  |A3= Coal |B3= Coal |C3= Coal
  |Output=Block of Coal
}}
{{Crafting
  |name=[[Pickaxe]]
  |ingredients=[[Stick]]s +<br>[[Planks]] or<br> [[Cobblestone]] or<br>[[Iron Ingot]]s or<br>[[Gold Ingot]]s or<br>[[Diamond]]s
  |A1=Oak Planks; Cobblestone; Iron Ingot; Gold Ingot; Diamond 
  |B1=Oak Planks; Cobblestone; Iron Ingot; Gold Ingot; Diamond 
  |C1=Oak Planks; Cobblestone; Iron Ingot; Gold Ingot; Diamond 
  |B2=Stick
  |B3=Stick
  |Output=Wooden Pickaxe; Stone Pickaxe; Iron Pickaxe; Golden Pickaxe; Diamond Pickaxe
  |foot=1
}}

produces:

Template:Crafting Template:Crafting Template:Crafting Template:Crafting

Details[edit source]

Template:TemplateData

Builds a table that lists crafting recipes. Slot/ingredient parameters use the same syntax as Inventory slot.

Template parameters[Edit template data]

This template has custom formatting.

ParameterDescriptionTypeStatus
Top left slotA1

Specifies ingredients in the top left slot

Example
{Any Planks}; {Any stone-tier block}; Iron Ingot; Gold Ingot; Diamond
Stringsuggested
Top slotB1

Specifies ingredients in the top slot

Example
{Any Planks}; {Any stone-tier block}; Iron Ingot; Gold Ingot; Diamond
Stringsuggested
Top right slotC1

Specifies ingredients in the top right slot

Example
{Any Planks}; {Any stone-tier block}; Iron Ingot; Gold Ingot; Diamond
Stringsuggested
Left slotA2

Specifies ingredients in the left slot

Stringsuggested
Middle slotB2

Specifies ingredients in the middle slot

Example
Stick
Stringsuggested
Right slotC2

Specifies ingredients in the right slot

Stringsuggested
Bottom left slotA3

Specifies ingredients in the bottom left slot

Stringsuggested
Bottom slotB3

Specifies ingredients in the bottom slot

Example
Stick
Stringsuggested
Bottom right slotC3

Specifies ingredients in the bottom right slot

Stringsuggested
First ingredient1

First ingredient in a shapeless recipe

Example
Flint
Stringoptional
Second ingredient2

Second ingredient in a shapeless recipe

Example
Iron Ingot
Stringoptional
Third ingredient3

Third ingredient in a shapeless recipe

Stringoptional
Fourth ingredient4

Fourth ingredient in a shapeless recipe

Stringoptional
Fifth ingredient5

Fifth ingredient in a shapeless recipe

Stringoptional
Sixth ingredient6

Sixth ingredient in a shapeless recipe

Stringoptional
Seventh ingredient7

Seventh ingredient in a shapeless recipe

Stringoptional
Eighth ingredient8

Eighth ingredient in a shapeless recipe

Stringoptional
Ninth ingredient9

Ninth ingredient in a shapeless recipe

Stringoptional
Recipe outputOutput

Sets the recipe's output. If multiple blocks or items are crafted simultaneously, make sure to specify the number after a comma.

Example
Wooden Pickaxe; Stone Pickaxe; Iron Pickaxe; Gold Pickaxe; Diamond Pickaxe
Stringsuggested
Ignored by Crafting usageignoreusage

Sets the template to be ignored by the Crafting usage template. This means the recipe will not appear in the "Crafting ingredient" subsection of "Usage" on other articles. When not using the template inside the "Crafting" subsection of "Obtaining", this parameter is mandatory to avoid issues with Crafting usage.

Suggested values
1
Auto value
1
Unknownoptional
Recipe typetype

Sets the category for this recipe. If set, the recipe will be automatically added to the corresponding subsection in the Crafting article's "Complete recipe list" section. Has no effect if "ignoreusage" parameter is active.

Suggested values
Building blocks Decoration blocks Redstone Transportation Foodstuffs Tools Utilities Combat Brewing Materials Miscellaneous
Example
Combat
Stringoptional
Shapeless recipe overrideshapeless

Forces shapeless recipe mode if "top left slot" and similar parameters are used.

Suggested values
1
Default
Shapeless mode is automatically enabled when "first ingredient" parameter is used.
Auto value
1
Unknownoptional
Fixed recipe modefixed

Enables fixed recipe mode for cases when ingredient layout cannot be mirrored (usually for banners)

Suggested values
1
Auto value
1
Unknownoptional
Ingredient that is not fixednotfixed

For fixed recipes, describes the ingredient that can be placed in any free slot as an exception.

Example
the banner
Unknownoptional
Table headerhead

Sets this template instance as the first one in a sequence.

Suggested values
1
Auto value
1
Unknownoptional
Table footerfoot

Sets this template instance as the last one in a sequence.

Suggested values
1
Auto value
1
Unknownoptional
Description column controlshowdescription

Controls whether to display the description column. Value of 1 makes it show, any other values disable it. For multi-template tables, only set this parameter in the first template (which as the "head" parameter set).

Suggested values
1
Default
The column is not shown by default. In template sequences, templates use the same value as the first template.
Auto value
1
Unknownoptional
Additional desciptiondescription

Provides an additional description to the recipe, such as edition exclusivity or upcoming version which will add the recipe. Make sure to set the "showdescription" parameter, or it will not show.

Contentoptional
Name column controlshowname

Controls whether to display the "name" column which lists what block(s) or item(s) is/are made by the recipe. Value of 1 makes the column show, any other values disable it. For multi-template tables, only set this parameter in the first template (which as the "head" parameter set).

Suggested values
0 1
Default
The name column is shown by default when the template has the "head" parameter set to 1; subsequent templates in the sequence use the first one's value. The column is not shown when the template is standalone.
Auto value
1
Unknownoptional
Name overridename

Overrides what is displayed in the Name cell.

Default
The name is inferred automatically from the output slot.
Example
Any Pickaxe (except Netherite)
Contentoptional
Ingredients overrideingredients

Overrides what is displayed in the Ingredients cell.

Default
The ingredients are inferred automatically.
Contentoptional
Disable categoriesnocat

Sets the template to not add the page to any category. For technical reasons, this will also imply "ignoreusage" because Crafting usage relies on hidden categories set by this template.

Suggested values
1
Default
Categories are not added on subarticles or outside of the article namespace.
Auto value
1
Unknownoptional