Difference between revisions of "Template:Block list"

From Space Engineers Wiki
Jump to: navigation, search
m
m (Expanded the example usage)
 
(10 intermediate revisions by 2 users not shown)
Line 3: Line 3:
 
   -->|{{#if: {{#vardefineecho:icon-size|{{#explode:{{{userparam}}}|;|1}}}}|{{#var:icon-size|64px}}}}<!--
 
   -->|{{#if: {{#vardefineecho:icon-size|{{#explode:{{{userparam}}}|;|1}}}}|{{#var:icon-size|64px}}}}<!--
 
   -->|link={{#show:{{{1}}}|?Main article#-}}{{lang}}]]<!--
 
   -->|link={{#show:{{{1}}}|?Main article#-}}{{lang}}]]<!--
   -->&nbsp;[[{{#show:{{{1}}}|?Main article#-}}|{{#if: {{lang}}|{{{{{1}}}{{lang}}}}|{{#show:{{{1}}}|?Translation}}}}]]<!--
+
   -->&nbsp;[[{{#show:{{{1}}}|?Main article#-}}{{lang}}|{{translate|{{{1}}}}}]]<!--
   -->{{#if:{{#vardefineecho:prop0|{{#explode:{{{userparam}}}|;|2}}}}|{{!}}style="text-align:right;"{{!}}{{#ifeq:{{#show:Property:{{#var:prop0}}|?Has type#-}}|Text|{{Property:{{#var:prop0}}/{{#show:{{{1}}}|?{{#var:prop0}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop0}}}}}}
+
   -->{{Block list/cell|{{{1}}}|{{{userparam}}}|2}}<!--
}}{{#if:{{#vardefineecho:prop1|{{#explode:{{{userparam}}}|;|3}}}}|{{!}} style="text-align:right;" {{!}} {{#ifeq:{{#show:Property:{{#var:prop1}}|?Has type#-}}|Text|{{Property:{{#var:prop1}}/{{#show:{{{1}}}|?{{#var:prop1}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop1}}}}}}
+
  -->{{Block list/cell|{{{1}}}|{{{userparam}}}|3}}<!--
}}{{#if:{{#vardefineecho:prop2|{{#explode:{{{userparam}}}|;|4}}}}|{{!}} style="text-align:right;" {{!}} {{#ifeq:{{#show:Property:{{#var:prop2}}|?Has type#-}}|Text|{{Property:{{#var:prop2}}/{{#show:{{{1}}}|?{{#var:prop2}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop2}}}}}}
+
  -->{{Block list/cell|{{{1}}}|{{{userparam}}}|4}}<!--
}}{{#if:{{#vardefineecho:prop3|{{#explode:{{{userparam}}}|;|5}}}}|{{!}} style="text-align:right;" {{!}} {{#ifeq:{{#show:Property:{{#var:prop3}}|?Has type#-}}|Text|{{Property:{{#var:prop3}}/{{#show:{{{1}}}|?{{#var:prop3}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop3}}}}}}
+
  -->{{Block list/cell|{{{1}}}|{{{userparam}}}|5}}<!--
}}{{#if:{{#vardefineecho:prop4|{{#explode:{{{userparam}}}|;|6}}}}|{{!}} style="text-align:right;" {{!}} {{#ifeq:{{#show:Property:{{#var:prop4}}|?Has type#-}}|Text|{{Property:{{#var:prop4}}/{{#show:{{{1}}}|?{{#var:prop4}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop4}}}}}}
+
  -->{{Block list/cell|{{{1}}}|{{{userparam}}}|6}}<!--
}}{{#if:{{#vardefineecho:prop5|{{#explode:{{{userparam}}}|;|7}}}}|{{!}} style="text-align:right;" {{!}} {{#ifeq:{{#show:Property:{{#var:prop5}}|?Has type#-}}|Text|{{Property:{{#var:prop5}}/{{#show:{{{1}}}|?{{#var:prop5}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop5}}}}}}
+
  -->{{Block list/cell|{{{1}}}|{{{userparam}}}|7}}<!--
}}{{#if:{{#vardefineecho:prop6|{{#explode:{{{userparam}}}|;|8}}}}|{{!}} style="text-align:right;" {{!}} {{#ifeq:{{#show:Property:{{#var:prop6}}|?Has type#-}}|Text|{{Property:{{#var:prop6}}/{{#show:{{{1}}}|?{{#var:prop6}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop6}}}}}}
+
  -->{{Block list/cell|{{{1}}}|{{{userparam}}}|8}}<!--
}}{{#if:{{#vardefineecho:prop7|{{#explode:{{{userparam}}}|;|9}}}}|{{!}} style="text-align:right;" {{!}} {{#ifeq:{{#show:Property:{{#var:prop7}}|?Has type#-}}|Text|{{Property:{{#var:prop7}}/{{#show:{{{1}}}|?{{#var:prop7}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop7}}}}}}
+
  -->{{Block list/cell|{{{1}}}|{{{userparam}}}|9}}<!--
}}{{#if:{{#vardefineecho:prop8|{{#explode:{{{userparam}}}|;|10}}}}|{{!}} style="text-align:right;" {{!}} {{#ifeq:{{#show:Property:{{#var:prop8}}|?Has type#-}}|Text|{{Property:{{#var:prop8}}/{{#show:{{{1}}}|?{{#var:prop8}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop8}}}}}}
+
  -->{{Block list/cell|{{{1}}}|{{{userparam}}}|10}}<!--
}}{{#if:{{#vardefineecho:prop9|{{#explode:{{{userparam}}}|;|11}}}}|{{!}} style="text-align:right;" {{!}} {{#ifeq:{{#show:Property:{{#var:prop9}}|?Has type#-}}|Text|{{Property:{{#var:prop9}}/{{#show:{{{1}}}|?{{#var:prop9}}}}{{lang}}}}|{{#show:{{{1}}}|?{{#var:prop9}}}}}}}}
+
  -->{{Block list/cell|{{{1}}}|{{{userparam}}}|11}}
 
{{!}}-
 
{{!}}-
 
|{{#vardefine:page|{{removelc | {{{1}}} }} }}
 
|{{#vardefine:page|{{removelc | {{{1}}} }} }}
Line 25: Line 25:
 
{| class="wikitable sortable"
 
{| class="wikitable sortable"
 
|-
 
|-
| [[{{{1}}}]] {{!!}} {{icon|No Item}} || {{{2}}} || {{{3}}}
+
| [[{{{1}}}]] {{!!}} {{icon|No Image}} || {{{2}}} || {{{3}}}
 
|}
 
|}
  
Line 33: Line 33:
 
:<code>First column's title;icon-size;property1;property2;property3...</code>
 
:<code>First column's title;icon-size;property1;property2;property3...</code>
 
;Example usage
 
;Example usage
:<code>Armor Block;64px;Mass;Integrity;IsAirTight;DeformationRatio</code>
+
<pre>{{#ask: [[Concept:Components]]
 +
| format=template
 +
| link=none
 +
| template=Block list
 +
| introtemplate=Block list/header
 +
| outrotemplate=Block list/footer
 +
| userparam=Component;32px;Mass;Volume#L;MaxIntegrity;BaseProductionTimeInSeconds;
 +
}}</pre>
 +
;Result
 +
{{#ask: [[Concept:Components]]
 +
| format=template
 +
| link=none
 +
| template=Block list
 +
| introtemplate=Block list/header
 +
| outrotemplate=Block list/footer
 +
| userparam=Component;32px;Mass;Volume#L;MaxIntegrity;BaseProductionTimeInSeconds;
 +
}}
  
 
[[Category:Templates]]</noinclude>
 
[[Category:Templates]]</noinclude>

Latest revision as of 10:18, 25 January 2021

Block list template, for use in #ask queries.

Defaults to this for backwards compatibility:

[[{{{1}}}]] No Image Icon.png {{{2}}} {{{3}}}

If |userparam= is defined in the query, the columns will be picked by each property.

userparam
First column's title;icon-size;property1;property2;property3...
Example usage
{{#ask: [[Concept:Components]]
| format=template
| link=none
| template=Block list
| introtemplate=Block list/header
| outrotemplate=Block list/footer
| userparam=Component;32px;Mass;Volume#L;MaxIntegrity;BaseProductionTimeInSeconds;
}}
Result
Component Mass Volume Integrity Base Production Time
Bulletproof Glass Icon.png Bulletproof Glass  15 kg
15,000 g
15,000,000 mg
0.015 t
 
8 L
0.008 m³
5.12e-4 Large-Blocks
0.064 Small-Blocks
0.8 hL
8,000 mL
 
60  1 s
Canvas Icon.png Canvas  15 kg
15,000 g
15,000,000 mg
0.015 t
 
8 L
0.008 m³
5.12e-4 Large-Blocks
0.064 Small-Blocks
0.8 hL
8,000 mL
 
4 s
Computer Icon.png Computer  0.2 kg
200 g
200,000 mg
2.0e-4 t
 
1 L
1.0e-3 m³
6.4e-5 Large-Blocks
0.008 Small-Blocks
0.1 hL
1,000 mL
 
1 s
Construction Component Icon.png Construction Component  8 kg
8,000 g
8,000,000 mg
0.008 t
 
2 L
0.002 m³
1.28e-4 Large-Blocks
0.016 Small-Blocks
0.2 hL
2,000 mL
 
30  1 s
Detector Components Icon.png Detector Components  5 kg
5,000 g
5,000,000 mg
0.005 t
 
6 L
0.006 m³
3.84e-4 Large-Blocks
0.048 Small-Blocks
0.6 hL
6,000 mL
 
4 s
Display Icon.png Display  8 kg
8,000 g
8,000,000 mg
0.008 t
 
6 L
0.006 m³
3.84e-4 Large-Blocks
0.048 Small-Blocks
0.6 hL
6,000 mL
 
1 s
Plushie Icon.PNG Engineer Plushie  1 kg
1,000 g
1,000,000 mg
1.0e-3 t
 
3 L
0.003 m³
1.92e-4 Large-Blocks
0.024 Small-Blocks
0.3 hL
3,000 mL
 
Explosives Icon.png Explosives  2 kg
2,000 g
2,000,000 mg
0.002 t
 
2 L
0.002 m³
1.28e-4 Large-Blocks
0.016 Small-Blocks
0.2 hL
2,000 mL
 
6 s
Girder Icon.png Girder  6 kg
6,000 g
6,000,000 mg
0.006 t
 
2 L
0.002 m³
1.28e-4 Large-Blocks
0.016 Small-Blocks
0.2 hL
2,000 mL
 
15  1 s
Gravity Generator Components Icon.png Gravity Generator Components  800 kg
800,000 g
800,000,000 mg
0.8 t
 
200 L
0.2 m³
0.0128 Large-Blocks
1.6 Small-Blocks
20 hL
200,000 mL
 
500  10 s
Interior Plate Icon.png Interior Plate  3 kg
3,000 g
3,000,000 mg
0.003 t
 
5 L
0.005 m³
3.2e-4 Large-Blocks
0.04 Small-Blocks
0.5 hL
5,000 mL
 
15  1 s
Large Steel Tube Icon.png Large Steel Tube  25 kg
25,000 g
25,000,000 mg
0.025 t
 
38 L
0.038 m³
0.00243 Large-Blocks
0.304 Small-Blocks
3.8 hL
38,000 mL
 
60  2 s
Medical Components Icon.png Medical Components  150 kg
150,000 g
150,000,000 mg
0.15 t
 
160 L
0.16 m³
0.0102 Large-Blocks
1.28 Small-Blocks
16 hL
160,000 mL
 
70  6 s
Metal Grid Icon.png Metal Grid  6 kg
6,000 g
6,000,000 mg
0.006 t
 
15 L
0.015 m³
9.6e-4 Large-Blocks
0.12 Small-Blocks
1.5 hL
15,000 mL
 
30  2 s
Motor Icon.png Motor  24 kg
24,000 g
24,000,000 mg
0.024 t
 
8 L
0.008 m³
5.12e-4 Large-Blocks
0.064 Small-Blocks
0.8 hL
8,000 mL
 
40  3 s
Power Cell Icon.png Power Cell  25 kg
25,000 g
25,000,000 mg
0.025 t
 
40 L
0.04 m³
0.00256 Large-Blocks
0.32 Small-Blocks
4 hL
40,000 mL
 
50  4 s
Radio-Communication Components Icon.png Radio-Communication Components  8 kg
8,000 g
8,000,000 mg
0.008 t
 
70 L
0.07 m³
0.00448 Large-Blocks
0.56 Small-Blocks
7 hL
70,000 mL
 
15  4 s
Reactor Components Icon.png Reactor Components  25 kg
25,000 g
25,000,000 mg
0.025 t
 
8 L
0.008 m³
5.12e-4 Large-Blocks
0.064 Small-Blocks
0.8 hL
8,000 mL
 
20  8 s
SabiroidPlushie Icon.PNG Saberoid Plushie  1 kg
1,000 g
1,000,000 mg
1.0e-3 t
 
3 L
0.003 m³
1.92e-4 Large-Blocks
0.024 Small-Blocks
0.3 hL
3,000 mL
 
Small Steel Tube Icon.png Small Steel Tube  4 kg
4,000 g
4,000,000 mg
0.004 t
 
2 L
0.002 m³
1.28e-4 Large-Blocks
0.016 Small-Blocks
0.2 hL
2,000 mL
 
15  1 s
Solar Cell Icon.png Solar Cell  6 kg
6,000 g
6,000,000 mg
0.006 t
 
12 L
0.012 m³
7.68e-4 Large-Blocks
0.096 Small-Blocks
1.2 hL
12,000 mL
 
2 s
Steel Plate Icon.png Steel Plate  20 kg
20,000 g
20,000,000 mg
0.02 t
 
3 L
0.003 m³
1.92e-4 Large-Blocks
0.024 Small-Blocks
0.3 hL
3,000 mL
 
100  1 s
Superconductor Component Icon.png Superconductor Component  15 kg
15,000 g
15,000,000 mg
0.015 t
 
8 L
0.008 m³
5.12e-4 Large-Blocks
0.064 Small-Blocks
0.8 hL
8,000 mL
 
8 s
Thruster Components Icon.png Thruster Components  40 kg
40,000 g
40,000,000 mg
0.04 t
 
10 L
0.01 m³
6.4e-4 Large-Blocks
0.08 Small-Blocks
1 hL
10,000 mL
 
30  4 s
Zone Chip Icon.png Zone Chip  0.25 kg
250 g
250,000 mg
2.5e-4 t
 
0.2 L
2.0e-4 m³
1.28e-5 Large-Blocks
0.0016 Small-Blocks
0.02 hL
200 mL