Template:Infobox Recipe: Difference between revisions

1,661 bytes removed ,  Yesterday at 20:56
m
Add docs
No edit summary
m (Add docs)
 
(74 intermediate revisions by 8 users not shown)
Line 1:
<includeonly>{{#invoke:Infobox Recipe|_main}}</includeonly><noinclude>{{/doc}}</noinclude>
{| class="wikitable"
! colspan="4" | Requirements
|-
! colspan="2" | Facility
| colspan="2" | {{#if:{{{facility|}}}|[[{{{facility}}}]]|{{Unknown}}}}
|-
! colspan="2" | Profession
! Level
! XP
|-
| colspan="2" | {{#if:{{{profession|}}}|{{{profession}}}|{{Unknown}}}}
| style="text-align: center;" | {{#if:{{{level|}}}|{{{level}}}|{{Unknown}}}}
| style="text-align: center;" | {{#if:{{{exp|}}}|{{{exp}}}|{{Unknown}}}}
|-
! colspan="2" | Material
! Quantity
! Cost
|-
{{#if:{{{mat1|}}}|
{{!}} [[File:{{{mat1}}}.png|x30px]]
{{!}} [[{{{mat1}}}]]
{{!}} style="text-align: right;" {{!}} {{{mat1qty|1}}}
{{!}} style="text-align: right;" {{!}} {{formatnum:{{#vardefineecho:mat1total|{{#expr:{{{mat1qty|1}}} * {{formatnum:{{#ask:[[{{{mat1}}}]]|?Cost=|mainlabel=-}}|R}}}}}}}}
{{!}}-
}}
{{#if:{{{mat2|}}}|
{{!}} [[File:{{{mat2}}}.png|x30px]]
{{!}} [[{{{mat2}}}]]
{{!}} style="text-align: right;" {{!}} {{{mat2qty|1}}}
{{!}} style="text-align: right;" {{!}} {{formatnum:{{#vardefineecho:mat1total|{{#expr:{{{mat2qty|1}}} * {{formatnum:{{#ask:[[{{{mat2}}}]]|?Cost=|mainlabel=-}}|R}}}}}}}}
{{!}}-
}}
! colspan="3" | Total cost
| style="text-align: right;" {{!}} {{formatnum:{{#vardefineecho:totalcost|{{#expr:{{#varexists:mat1total|{{#var:mat1total}}|0}} + {{#varexists:mat2total|{{#var:mat2total}}|0}}}}}}}}
|-
! colspan="2" | Ouput
! Quantity
! Cost
|-
{{!}} [[File:{{{output1}}}.png|x30px]]
{{!}} [[{{{output1}}}]]
| style="text-align: right;" {{!}} {{{output1qty|1}}}
| style="text-align: right;" {{!}} {{formatnum:{{#vardefineecho:output1|{{#expr:{{{output1qty|1}}} * {{formatnum:{{#ask:[[{{{output1}}}]]|?Cost=|mainlabel=-}}|R}}}}}}}}
|-
! colspan="3" | Profit
| style="text-align: right;" {{!}} {{formatnum:{{#expr:{{#var:output1}} - {{#var:mat1total}}}}}}
|}