Raft Wiki
No edit summary
No edit summary
(36 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
<noinclude>
<div style="padding-left:20px;">
 
  +
{{#cargo_attach:
{| class="infoboxtable" style="width:350px" style="margin-left:10px;"
 
  +
_table = ItemData
|-
 
  +
}}</noinclude><includeonly>{{#cargo_store:
! colspan="2" style="border-bottom: 4px solid #baa16a; text-transform: uppercase; text-align: center; color: #a48754;" |
 
  +
_table = ItemData
{| style="width:100%;"
 
  +
|ItemName={{{name|{{PAGENAME}}}}}
! width=50 | {{#if: {{{image|}}} | <div class="infoboximage">[[File:{{{image}}}{{!}}50px|center]]</div> | ''No image yet''{{#ifeq: {{NAMESPACE}} | Template | | <includeonly>[[Category:Infoboxes lacking images]]</includeonly>}} }}
 
  +
|ItemDesc={{{desc|}}}
| <big><big>'''{{{name}}}'''</big></big>
 
  +
|Stacksize={{{stack|}}}
|}
 
  +
|achieve={{{achieve}}}
|- valign="top"
 
  +
|component1name={{{component1name|}}}
{{#if: {{{desc|}}} | {{!}} colspan="2" {{!}} <center>'''{{{desc}}}'''</center> }}
 
  +
|component1amount={{{component1amount|}}}
|-
 
  +
|component2name={{{component2name|}}}
{{#if: {{{component1name|}}} | {{!}} colspan="2" style="text-transform: uppercase; text-align: left;" {{!}} '''Requires''' }}
 
  +
|component2amount={{{component2amount|}}}
|-
 
  +
|component3name={{{component3name|}}}
{{#if: {{{component1name|}}} | {{!}} width=50 class="image" {{!}} <div class="componentsimage">[[File:{{#titleparts:{{{component1name}}}|1}}.png{{!}}center{{!}}48px]]</div> {{!!}} style="padding:0;" {{!}} <div style="font-size:120%;" class="components">'''[[{{{component1name|}}}]]''' <span style="float: right; padding-right: 15px;">'''{{{component1amount|}}}'''</span></div> | <includeonly>[[Category:Infoboxes without crafting recipes]]</includeonly> }}
 
  +
|component3amount={{{component3amount|}}}
|-
 
  +
|component4name={{{component4name|}}}
{{#if: {{{component2name|}}} | {{!}} width=50 {{!}} <div class="componentsimage">[[File:{{#titleparts:{{{component2name}}}|1}}.png{{!}}center{{!}}48px]]</div> {{!!}} <div style="font-size:120%;" class="components">'''[[{{{component2name|}}}]]''' <span style="float: right; padding-right: 15px;">'''{{{component2amount|}}}'''</span></div> }}
 
  +
|component4amount={{{component4amount|}}}
|-
 
  +
|component5name={{{component5name|}}}
{{#if: {{{component3name|}}} | {{!}} width=50 {{!}} <div class="componentsimage">[[File:{{#titleparts:{{{component3name}}}|1}}.png{{!}}center{{!}}48px]]</div> {{!!}} <div style="font-size:120%;" class="components">'''[[{{{component3name|}}}]]''' <span style="float: right; padding-right: 15px;">'''{{{component3amount|}}}'''</span></div> }}
 
  +
|component5amount={{{component5amount|}}}
|-
 
  +
}}</includeonly>
{{#if: {{{component4name|}}} | {{!}} width=50 {{!}} <div class="componentsimage">[[File:{{#titleparts:{{{component4name}}}|1}}.png{{!}}center{{!}}48px]]</div> {{!!}} <div style="font-size:120%;" class="components">'''[[{{{component4name|}}}]]''' <span style="float: right; padding-right: 15px;">'''{{{component4amount|}}}'''</span></div> }}
 
  +
{{Infobox
|-
 
  +
|name = {{{name|{{PAGENAME}}}}}
{{#if: {{{component5name|}}} | {{!}} width=50 {{!}} <div class="componentsimage">[[File:{{#titleparts:{{{component5name}}}|1}}.png{{!}}center{{!}}48px]]</div> {{!!}} <div style="font-size:120%;" class="components">'''[[{{{component5name|}}}]]''' <span style="float: right; padding-right: 15px;">'''{{{component5amount|}}}'''</span></div> }}
 
  +
|image = {{{image|}}}
|-
 
  +
|desc = {{{desc|}}}
{{#if: {{{type|}}} | {{!}} colspan="2" class="" style="text-transform: uppercase; text-align: left;" {{!}} '''Description''' }}
 
  +
|component1name = {{{component1name|}}}
|- valign="top"
 
  +
|component1amount = {{{component1amount|}}}
{{#if: {{{uses|}}} | {{!}} width=80 {{!}} <div>'''Uses'''</div> {{!!}} {{{uses}}} }}
 
  +
|component2name = {{{component2name|}}}
|- valign="top"
 
  +
|component2amount = {{{component2amount|}}}
{{#if: {{{damage|}}} | {{!}} width=80 {{!}} <div>'''Damage'''</div> {{!!}} {{{damage}}} }}
 
  +
|component3name = {{{component3name|}}}
|- valign="top"
 
  +
|component3amount = {{{component3amount|}}}
{{#if: {{{stack|}}} | {{!}} width=80 {{!}} <div>'''Stacksize'''</div> {{!!}} {{{stack}}} | <includeonly>[[Category:Infoboxes without stacksize]]</includeonly> }}
 
  +
|component4name = {{{component4name|}}}
|- valign="top"
 
  +
|component4amount = {{{component4amount|}}}
{{#if: {{{cooktime|}}} | {{!}} width=80 {{!}} <div>'''[[Cook Time]]'''</div> {{!!}} {{{cooktime}}} Seconds }}
 
  +
|component5name = {{{component5name|}}}
|- valign="top"
 
  +
|component5amount = {{{component5amount|}}}
{{#if: {{{smelttime|}}} | {{!}} width=80 {{!}} <div>'''[[Smelt Time]]'''</div> {{!!}} {{{smelttime}}} Seconds }}
 
  +
|title1 = Achievements
|- valign="top"
 
  +
|data1 = {{{achieve|}}}
{{#if: {{{portions|}}} | {{!}} width=80 {{!}} <div>'''[[Portions]]'''</div> {{!!}} {{{portions}}}}}
 
  +
|title2 = Uses
|- valign="top"
 
  +
|data2 = {{{uses|}}}
{{#if: {{{hunger|}}} | {{!}} width=80 {{!}} <div>'''[[Hunger]]'''</div> {{!!}} +{{{hunger}}}}}
 
  +
|title3 = Damage
|- valign="top"
 
  +
|data3 = {{{damage|}}}
{{#if: {{{bonus|}}} | {{!}} width=80 {{!}} <div>'''[[Hunger#Bonus_Hunger|Bonus]]'''</div> {{!!}} +{{{bonus}}}}}
 
  +
|title4 = Stacksize
|- valign="top"
 
  +
|data4 = {{{stack|}}}
{{#if: {{{thirst|}}} | {{!}} width=80 {{!}} <div>'''[[Thirst]]'''</div> {{!!}} {{#ifexpr:{{{thirst}}}<0|{{{thirst}}}|+{{{thirst}}}}}}}
 
  +
|title5 = [[Cook Time]]
|- valign="top"
 
{{#if: {{{burntime|}}} | {{!}} width=80 {{!}} <div>'''[[Burn Time]]'''</div> {{!!}} {{{burntime}}} Seconds }}
+
|data5 = {{#if: {{{cooktime|}}}| {{{cooktime}}} Seconds}}
  +
|title6 = [[Smelt Time]]
|- valign="top"
 
{{#if: {{{type|}}} | {{!}} width=80 {{!}} <div>'''Type'''</div> {{!!}} [[{{{type}}}]] }}
+
|data6 = {{#if: {{{smelttime|}}}| {{{smelttime}}} Seconds}}
  +
|title7 = [[Hunger#Raw Foods|Raw]]
|}
 
  +
|data7 = {{{raw|}}}
</div>
 
  +
|title8 = [[Hunger]]
<noinclude>{{clear}}{{doc}}
 
  +
|data8 = {{#if: {{{hunger|}}}| +{{{hunger}}}}}
[[Category:Infobox templates]]</noinclude>
 
  +
|title9 = [[Hunger#Bonus_Hunger|Bonus]]
  +
|data9 = {{#if: {{{bonus|}}}| +{{{bonus}}}}}
  +
|title10 = [[Thirst]]
 
|data10 = {{#if: {{{thirst|}}}|{{#ifexpr: {{{thirst|}}}<0|{{{thirst}}}|+{{{thirst}}}}}}}
  +
|title11 = [[Burn Time]]
  +
|data11 = {{#if: {{{burntime|}}}| {{{burntime}}} Seconds}}
  +
|title12 = Type
  +
|data12 = {{#if: {{{type|}}}|[[{{{type}}}]]}}
 
}}

Revision as of 22:29, 2 March 2021

This template adds rows to the table "ItemData", which is declared by the template Cargo-Items. View table.

ItemInfobox