Template:AgeOSR

From NationStates Sports Wiki
Revision as of 15:16, 28 May 2024 by Osarius (talk | contribs) (Created page with "<includeonly>{{#ifeq: {{{year|}}} | df | {{#expr:({{SpecYr/OSR}})-({{{1}}})-(({{{5|{{SpecMth/OSR|{{{code}}}}}}}})<({{{2}}})or({{{5|{{SpecMth/OSR|{{{code}}}}}}}})=({{{2}}})and({{{6|{{SpecDay/OSR|{{{code}}}}}}}})<({{{3}}}))}}-{{#expr:1+({{SpecYr/OSR}})-({{{1}}})-(({{{5|{{SpecMth/OSR|{{{code}}}}}}}})<({{{2}}})or({{{5|{{SpecMth/OSR|{{{code}}}}}}}})=({{{2}}})and({{{6|{{SpecDay/OSR|{{{code}}}}}}}})<({{{3}}}))}} | {{#expr:({{{year|{{SpecYr/OSR|{{{code}}}}}}}})-({{{1}}})-(({{{5|...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Template specifically for figuring out ages based on the Osarian/Cobre calendar.

Requires a birth date in yyyy-mm-dd format in parameters 1, 2, and 3, and a "code" referring to an event.

For example: {{AgeOSR|2190|9|1|code=AOCAF50}} will return 35, which is the age of a person born on September 1st, 2200 at the start of AOCAF Cup 50.

Alternatively, a year parameter can be passed (or set to "dy"; this will default to an approximation based on the RL date).

For example: {{AgeOSR|2200|9|1|year=2230}} will return 29-30, which is the possible ages of a person born on September 1st, 2200 at an undetermined point in the year 2230.

Similarly, {{AgeOSR|2300|9|1|year=df}} will return 38-39, which is the possible ages of a person born on September 1st, 2300 at an undetermined point in the estimated "current" year (2339) based on the RL date (04:26, Saturday, May 16, 2026 (UTC)).