Template:ItemInfoBox: Difference between revisions
From Ymirheim Wiki
No edit summary |
No edit summary |
||
(41 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
<templatestyles src="Template:ItemInfoBox/styles.css"/><div class="item-infobox"><!-- | <includeonly><templatestyles src="Template:InfoBox/styles.css"/><templatestyles src="Template:ItemInfoBox/styles.css"/><div class="infobox-wrapper"><!-- | ||
-->{{#if:{{{hint|}}}|<div class="infobox-hint">{{{hint|}}}</div>}}<!-- | |||
--><div class="infobox item-infobox"><!-- | |||
-->[[File:Item Icon {{#yh_data:item_prototypes|{{{1}}}|Icon}}.png|64px|icon]]<!-- | -->[[File:Item Icon {{#yh_data:item_prototypes|{{{1}}}|Icon}}.png|64px|icon]]<!-- | ||
-->< | --><div class="heading grade-{{#yh_data:item_prototypes|{{{1}}}|Grade}}">{{#yh_data:item_prototypes|{{{1}}}|Name}}</div><!-- | ||
--><div class="item-type">{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Part}} |0|{{#switch: {{#yh_data:item_prototypes|{{{1}}}|Type}} | |||
| 1 = <translate nowrap><!--T:1--> Consumable</translate> | |||
| 2 = <translate nowrap><!--T:2--> Material</translate> | |||
| 3 = <translate nowrap><!--T:3--> Normal</translate> | |||
| 4 = <translate nowrap><!--T:4--> Auge</translate> | |||
| 8 = <translate nowrap><!--T:5--> Skill Book</translate> | |||
| 9 = <translate nowrap><!--T:6--> Map</translate> | |||
| 10 = <translate nowrap><!--T:7--> Document</translate> | |||
| 11 = <translate nowrap><!--T:8--> Quest Item</translate> | |||
| 17 = <translate nowrap><!--T:9--> Book</translate> | |||
| 18 = <translate nowrap><!--T:10--> Dye</translate> | |||
| 20 = <translate nowrap><!--T:11--> Food</translate> | |||
| 21 = <translate nowrap><!--T:12--> Charm</translate> | |||
| 30 = <translate nowrap><!--T:13--> Card</translate> | |||
| 31 = <translate nowrap><!--T:14--> Spirit</translate> | |||
| 32 = <translate nowrap><!--T:15--> Spirit</translate> | |||
}}{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_Equip_Part}} |0||<br/>}}{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_Equip_Part}} |19| {{ItemWeaponRequirements|{{{1}}}}} |{{ItemEquipmentPartName|{{#yh_data:item_prototypes|{{{1}}}|Req_Equip_Part}}}} }} | |||
| {{ItemEquipmentPartName|{{#yh_data:item_prototypes|{{{1}}}|Part}}}} }}</div><!-- | |||
--><div style="clear: left;"></div><!-- | |||
--><translate nowrap><!--T:31--> Weight:</translate> {{#expr: floor({{#yh_data:item_prototypes|{{{1}}}|Weight}} / 1000) }}.{{padleft:{{#expr: {{#yh_data:item_prototypes|{{{1}}}|Weight}} mod 1000 }}|3}}<br/><!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|MaxStackQuantity}} | 1 || <translate nowrap><!--T:32--> Max stack:</translate> {{#yh_data:item_prototypes|{{{1}}}|MaxStackQuantity}}<br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|MaxDurability}} | 0 || <translate nowrap><!--T:35--> Max Durability:</translate> {{#yh_data:item_prototypes|{{{1}}}|MaxDurability}}<br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|CanTrade}} | 0 | <translate nowrap><!--T:45--> This item can't be traded.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|CanSell}} | 0 | <translate nowrap><!--T:46--> This item can't be sold.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|CanThrow}} | 0 | <translate nowrap><!--T:47--> This item can't be discarded.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_BaseLevel}} | 0 || <translate nowrap><!--T:36--> Level <tvar name="level">{{#yh_data:item_prototypes|{{{1}}}|Req_BaseLevel}}</tvar> required.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_AllowMale}} | 0 | <translate nowrap><!--T:37--> Female only.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_AllowFemale}} | 0 | <translate nowrap><!--T:38--> Male only.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_STR}} | 0 || <translate nowrap><!--T:39--> <tvar name="value">{{#yh_data:item_prototypes|{{{1}}}|Req_STR}}</tvar> Strength required.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_DEX}} | 0 || <translate nowrap><!--T:40--> <tvar name="value">{{#yh_data:item_prototypes|{{{1}}}|Req_DEX}}</tvar> Dexterity required.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_INT}} | 0 || <translate nowrap><!--T:41--> <tvar name="value">{{#yh_data:item_prototypes|{{{1}}}|Req_INT}}</tvar> Intelligence required.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_CON}} | 0 || <translate nowrap><!--T:42--> <tvar name="value">{{#yh_data:item_prototypes|{{{1}}}|Req_CON}}</tvar> Concentration required.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|Req_LUK}} | 0 || <translate nowrap><!--T:43--> <tvar name="value">{{#yh_data:item_prototypes|{{{1}}}|Req_LUK}}</tvar> Luck required.</translate> <br/> }}<!-- | |||
-->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|IsDyeing}} | 0 || <translate nowrap><!--T:44--> Dyeable Item</translate> <br/> }}<!-- | |||
-- | -->{{#ifeq: {{#yh_data:item_prototypes|{{{1}}}|CanSeal}} | 1 | <translate nowrap><!--T:48--> Sealed.</translate> <br/> }}<!-- | ||
-->{{#if:{{#yh_data:item_prototypes|{{{1}}}|StatusEffectId}}| <hr/>{{#yh_data_format:{{#yh_data:status_effects|{{{1}}}|Description}}|full}} }}<!-- | |||
--><hr/><!-- | |||
}}< | |||
-->{{#yh_data_format:{{#yh_data:item_prototypes|{{{1}}}|Description}}|full}}<!-- | -->{{#yh_data_format:{{#yh_data:item_prototypes|{{{1}}}|Description}}|full}}<!-- | ||
--></div> | -->{{#ifeq:{{#yh_data:item_prototypes|{{{1}}}|Price}}|0||<!-- | ||
--><hr/><!-- | |||
--><translate nowrap><!--T:33--> Price:</translate> {{PriceFormatted| {{#yh_data:item_prototypes|{{{1}}}|Price}} }}<br/><!-- | |||
-->{{#ifeq:{{#yh_data:item_prototypes|{{{1}}}|CanSell}}|1|<translate nowrap><!--T:34--> Selling price:</translate> {{PriceFormatted| {{#expr: {{#yh_data:item_prototypes|{{{1}}}|Price}} / 4 }} }}}}<!-- | |||
-->}}<!-- | |||
--></div></div></includeonly><noinclude> | |||
This template can be used to display an information box about a specific item on a page. | |||
== Usage == | |||
<nowiki>{{ItemInfoBox|ITEM_ID | |||
| obtain_by_purchase = no | |||
| obtain_by_trade = no | |||
}}</nowiki> | |||
You have to supply the specific item ID, not the item name. | |||
[[File:Item ID Search On Ymirheim Translate.png|thumb|How to find Item ID]] | |||
You can find the item ID by searching the item in [https://translate.ymirheim.org/browse/ymirheim/item_prototypes/en/'''Ymirheim Translate'''] (item_prototypes component). | |||
The item ID is contained in the string key. | |||
For example, if you look up [https://translate.ymirheim.org/browse/ymirheim/item_prototypes/en/?q=Pukui+Peel&sort_by=-priority%2Cposition&checksum= "Pukui Peel"] in Ymirheim Translate, you will see the item ID in the "Key" column (the portion before the forward slash). | |||
== Examples == | |||
{{ItemInfoBox|1330000004 | |||
| obtain_by_purchase = no | |||
| obtain_by_trade = no | |||
}} | |||
<pre><nowiki>{{ItemInfoBox|1330000004 | |||
| obtain_by_purchase = no | |||
| obtain_by_trade = no | |||
}}</nowiki></pre> | |||
{{Clear}} | |||
{{ItemInfoBox|1601006401 | |||
| obtain_by_purchase = no | |||
| obtain_by_trade = no | |||
}} | |||
<pre><nowiki>{{ItemInfoBox|1601006401 | |||
| obtain_by_purchase = no | |||
| obtain_by_trade = no | |||
}}</nowiki></pre> | |||
{{Clear}} | |||
{{ItemInfoBox|1022001402 | |||
| obtain_by_purchase = no | |||
| obtain_by_trade = no | |||
}} | |||
<pre><nowiki>{{ItemInfoBox|1022001402 | |||
| obtain_by_purchase = no | |||
| obtain_by_trade = yes | |||
}}</nowiki></pre> | |||
[[Category:Game Data Templates{{#translation:}}]] | |||
</noinclude> |
Latest revision as of 13:07, 25 July 2024
This template can be used to display an information box about a specific item on a page.
Usage
{{ItemInfoBox|ITEM_ID | obtain_by_purchase = no | obtain_by_trade = no }}
You have to supply the specific item ID, not the item name.
You can find the item ID by searching the item in Ymirheim Translate (item_prototypes component).
The item ID is contained in the string key.
For example, if you look up "Pukui Peel" in Ymirheim Translate, you will see the item ID in the "Key" column (the portion before the forward slash).
Examples
{{ItemInfoBox|1330000004 | obtain_by_purchase = no | obtain_by_trade = no }}
{{ItemInfoBox|1601006401 | obtain_by_purchase = no | obtain_by_trade = no }}
{{ItemInfoBox|1022001402 | obtain_by_purchase = no | obtain_by_trade = yes }}