Difference between revisions of "Template:Animals/Additional/Row"

From RimWorld Wiki
Jump to navigation Jump to search
(maybe this reduces the include size?)
 
(12 intermediate revisions by 4 users not shown)
Line 1: Line 1:
<noinclude>This template pulls the data from each animal's individual page and formats it into a neat row summary. It is only intended for use on the [[List of animals/Additional]] page.
+
<includeonly>
 
+
! {{DLC Icons|{{{?Name|{{{1}}}}}}}}<br/>[[{{#show:{{{?Name|{{{1|Horse}}} }}}|?Image#}}|32px]]
Usage:  <code><nowiki>{{Animals/Additional/Row|*name*}}</nowiki></code>
+
| {{#show:{{{?Name|{{{1}}}}}}|?Type}}
 
+
| {{#expr: {{#show:{{{?Name|{{{1}}}}}}|?Wildness}} * 100}}%  
The template takes a single parameter, the name of the animal being referenced, which must be the exact name of the animal's main page.
+
| {{#show:{{{?Name|{{{1}}}}}}|?Body Size}}
 
+
| {{#show:{{{?Name|{{{1}}}}}}|?Mass - Adult}}
Example:
+
| {{#if:{{#vardefineecho:val|{{#show:{{{?Name|{{{1}}}}}}|?Market Value Base}}}}|{{#var:val}}|-}}
{| {{STDT| sortable c_08 text-center}}
+
| {{#if:{{#vardefineecho:combatPower|{{#show:{{{?Name|{{{1}}}}}}|?Combat Power}}}}|{{#var:combatPower}}|-}}
! Animal !! Type !! Wildness !! Body Size !! Mass !! Health Scale !! Market Value !! Juvenile Age !! Maturity Age !! Life Expectancy !! Gestation Period !! Average Offspring !! Filth Rate !! Roam Interval !! Min Temperature !! Max Temperature
+
| {{#if:{{#vardefineecho:juv_age|{{#show:{{{?Name|{{{1}}}}}}|?Juvenile Age}}}}|{{#expr:{{#var:juv_age}}*60 round 2}}|-}}
|-
+
| {{#if:{{#vardefineecho:mat_age|{{#show:{{{?Name|{{{1}}}}}}|?Maturity Age}}}}|{{#expr:{{#var:mat_age}}*60 round 2}}|-}}
{{Animals/Additional/Row|Horse}}
+
| {{#show:{{{?Name|{{{1}}}}}}|?Life Expectancy}}
|}
+
| {{#if:{{#vardefineecho:egg_interval|{{#show:{{{?Name|{{{1}}}}}}|?Egg Laying Interval}}}}|{{#var:egg_interval}}
</noinclude><includeonly>
+
   | {{#if:{{#vardefineecho:gestation|{{#show:{{{?Name|{{{1}}}}}}|?Gestation Period Days}}}}|{{#var:gestation}}
! [[{{{1}}}]]
 
| {{#show:{{{1}}}|?Type}}
 
| {{#expr: {{#show:{{{1}}}|?Wildness}} * 100}}%  
 
| {{#show:{{{1}}}|?Body Size}}
 
| {{#show:{{{1}}}|?Mass - Adult}}
 
| {{#show:{{{1}}}|?Health Scale}}
 
| {{#show:{{{1}}}|?Market Value Base}}
 
| {{#expr: {{#show:{{{1}}}|?Juvenile Age}}*60 round 2}}
 
| {{#expr: {{#show:{{{1}}}|?Maturity Age}}*60 round 2}}
 
| {{#show:{{{1}}}|?Life Expectancy}}
 
| {{#if:{{#vardefineecho:egg_interval|{{#show:{{{1}}}|?Egg Laying Interval}}}}|{{#var:egg_interval}}
 
   | {{#if:{{#vardefineecho:gestation|{{#show:{{{1}}}|?Gestation Period Days}}}}|{{#var:gestation}}
 
 
     | -
 
     | -
 
   }}
 
   }}
 
}}
 
}}
| {{#if:{{#vardefineecho:clutch_size|{{#show:{{{1}}}|?Eggs Per Clutch Average}}}}|{{#var:clutch_size}}
+
| {{#if:{{#vardefineecho:clutch_size|{{#show:{{{?Name|{{{1}}}}}}|?Eggs Per Clutch Average}}}}|{{#var:clutch_size}}
   | {{#if:{{#vardefineecho:litter_size|{{#show:{{{1}}}|?Average Offspring Per Birth}}}}|{{#var:litter_size}}
+
   | {{#if:{{#vardefineecho:litter_size|{{#show:{{{?Name|{{{1}}}}}}|?Average Offspring Per Birth}}}}|{{#var:litter_size}}
 
     | {{#if:{{#var:gestation}}|1|-}}
 
     | {{#if:{{#var:gestation}}|1|-}}
 
   }}
 
   }}
 
}}
 
}}
| {{#show:{{{1}}}|?Animal Filth Rate}}
+
| {{#if:{{#vardefineecho:mate|{{#show:{{{?Name|{{{1}}}}}}|?Mate Mtb Hours}}}}|{{#var:mate}}|-}}
| {{#if:{{#vardefineecho:roam|{{#show:{{{1}}}|?Roam Mtb Days}}}}|{{#var:roam}}|-}}
+
| {{#show:{{{?Name|{{{1}}}}}}|?Animal Filth Rate}}
| {{#show:{{{1}}}|?Min Comfortable Temperature}}
+
| {{#if:{{#vardefineecho:roam|{{#show:{{{?Name|{{{1}}}}}}|?Roam Mtb Days}}}}|{{#var:roam}}|-}}
| {{#show:{{{1}}}|?Max Comfortable Temperature}}
+
| {{Q|{{{?Name|{{{1|Horse}}} }}}|Nuzzle Mtb Hours#|Never}}
 +
| {{#show:{{{?Name|{{{1}}}}}}|?Min Comfortable Temperature}}
 +
| {{#show:{{{?Name|{{{1}}}}}}|?Max Comfortable Temperature}}
 
|-
 
|-
</includeonly>
+
</includeonly><noinclude>{{Documentation}}</noinclude>
<noinclude>[[Category:Customized table templates]]</noinclude>
 

Latest revision as of 07:59, 8 October 2024

Documentation icon Template documentation[view] [edit] [history] [purge]

Summary[edit]

This template pulls the data from each animal's individual page and formats it into a neat row summary. It is only intended for use on the List of animals/Additional page.

Usage[edit]

{{Animals/Additional/Row|*name*}}

The template takes a single parameter, the name of the animal being referenced, which must be the exact name of the animal's main page.

Example[edit]

{| {{STDT| sortable c_08 text-center}}
! Animal !! Type !! Wildness !! Body Size !! <abbr title=kg>Mass</abbr> !! data-sort-type=number|Market Value !! data-sort-type=number|Combat Power !! data-sort-type=number|<abbr title=days>Juvenile Age</abbr> !! data-sort-type=number|<abbr title=days>Maturity Age</abbr> !! <abbr title=years>Life Expectancy</abbr> !! data-sort-type=number|<abbr title=days>Gestation Period !! data-sort-type=number|Average Offspring !! data-sort-type=number|Mate Interval !! Filth Rate !! data-sort-type=number|Roam Interval !! data-sort-type=number|Nuzzle Interval !! <abbr title=°C>Min Temperature</abbr> !! <abbr title=°C>Max Temperature</abbr>
|-
{{Animals/Additional/Row|Chinchilla}}
|}


Animal Type Wildness Body Size Mass Market Value Combat Power Juvenile Age Maturity Age Life Expectancy Gestation Period Average Offspring Mate Interval Filth Rate Roam Interval Nuzzle Interval Min Temperature Max Temperature
Chinchilla
Chinchilla.png
Animal 60% 0.35 21 150 33 6 13.32 9 5.661 1.75 8 1 2 Never -15 55