Template

Difference between revisions of "Character/new/Vitals"

From Children of StarClan

< Template:Character‎ | new
(Age Improvements, Part 1. Cleanup of basic selector code.)
(Solved a longstanding bug. System could not handle unspecified birthdate with specified death date. Now it can!)
 
(18 intermediate revisions by the same user not shown)
Line 4: Line 4:
 
</div>
 
</div>
 
<div class="row">
 
<div class="row">
<div class="large-12 columns" style="padding-left: 25px;"><!-- GENDER and LINIAGE -->A {{{gender}}} by {{Name|{{{sire}}}|{{#if: {{{sire2|}}}|X|}}|{{{sire2|}}}}} out of {{Name|{{{dame}}}|{{#if: {{{dame2|}}}|X|}}|{{{dame2|}}}}}{{#ifeq: {{{status}}}|Living|<BR>'''ALIVE'''|{{#ifeq: {{{status}}}|Dead|<BR>'''DEAD'''|{{#ifeq: {{{status}}}|Unborn|<BR>'''UNBORN'''|{{#ifeq: {{{status}}}|Living (Off Camera)|<BR>'''LIVING OFF CAMERA'''|<BR><SPAN style="color: red;">'''STATUS NOT SPECIFIED'''</SPAN>
+
<div class="large-12 columns" style="padding-left: 25px;"><!-- GENDER and LINIAGE -->A {{{gender|cat}}} by {{Name|{{{sire|Unknown Tom}}}|{{#if: {{{sire2|}}}|X|}}|{{{sire2|}}}}} out of {{Name|{{{dame|Unknown Queen}}}|{{#if: {{{dame2|}}}|X|}}|{{{dame2|}}}}}<SPAN style="display: none;">{{{birth}}}{{{died}}}</SPAN>{{#vardefine:birthnumber|{{Datenum|{{#var:birthmoon}}}}}}{{#vardefine:deathnumber|{{Datenum|{{#var:deathmoon}}}}}}{{#ifeq: {{{status}}}|Living|<BR>Living {{#ifeq: {{#varexists:birthmoon}}|1|at the age of {{#expr:({{moon}} - {{#var:birthnumber}})}} Moons {{Moon-year|{{#expr:({{moon}} - {{#var:birthnumber}})}}}} }}|{{#ifeq: {{{status}}}|Dead|<BR>Dead {{#ifeq: {{#var:deathmoon}}|An Unspecified Moon||{{#if: {{#var:birthmoon|}}|at the age of {{#expr:({{#var:deathnumber}} - {{#var:birthnumber}})}} moons {{Moon-year|{{#expr:({{#var:deathnumber}} - {{#var:birthnumber}})}}}}|}}<BR>and has been so for {{#expr:({{moon}} - {{#var:deathnumber}})}} moons {{Moon-year|{{#expr:({{moon}} - {{#var:deathnumber}})}}}}. }}|{{#ifeq: {{{status}}}|Unborn|<BR>Unborn {{#ifeq: {{#varexists:birthmoon}}|1|and will be in {{#expr:({{#var:birthnumber}} - {{moon}})}} moons, during the {{#var:birthmoon}} }}|{{#ifeq: {{{status}}}|Living (Off Camera)|<BR>Living (off camera) {{#ifeq: {{#varexists:birthmoon}}|1|at the age of {{#expr:({{moon}} - {{#var:birthnumber}})}} Moon(s) {{Moon-year|{{#expr:({{moon}} - {{#var:birthnumber}})}}}} }}|<BR><SPAN style="color: red;">'''STATUS NOT SPECIFIED'''</SPAN><!-- off camera-->}}<!-- unborn -->}}<!-- dead -->}}<!-- living -->}}{{#if: {{{warborn|}}}|{{warborn}}|}}{{#if: {{{fierceblood|}}}|{{fierceblood}}|}}</div>
<!-- off camera-->}}<!-- unborn -->}}<!-- dead -->}}<!-- living -->}}{{#if: {{{warborn|}}}|{{warborn}}|}}{{#if: {{{fierceblood|}}}|{{fierceblood}}|}}</div>
 
 
</div>
 
</div>

Latest revision as of 00:08, 28 May 2017

Vitals
 
A cat by Unknown Tom out of Unknown Queen{{{birth}}}{{{died}}}
STATUS NOT SPECIFIED