Jump to content

Template:Character: Difference between revisions

From Ulrapedia
No edit summary
 
(11 intermediate revisions by the same user not shown)
Line 6: Line 6:
|class=String
|class=String
|subclass=String
|subclass=String
|occupation=String
|gender=String
|gender=String
|age=String
|titles=String
|alignment=String
|aliases=String
|status=String
|birthplace=String
|residence=String
|nation=String
|religion=String
|groups=String
|affiliation=String
|player=String
|introduced=String
|last_seen=String
}}
}}


== About ==
== About ==
This template creates a character infobox that floats on the right side of the page.
This template creates a character infobox that floats on the right side of the page. All fields are optional — empty fields are automatically hidden.
All fields are optional — empty fields are automatically hidden.


Fields that auto-link to other wiki pages: campaign, species, birthplace, residence, nation, spouse.
It also supports automatic categorization and linking for certain fields.


Fields that support comma-separated lists with auto-linking: titles, aliases, affiliation, groups, parents, siblings, children.
== Field Reference ==
{| class="wikitable" style="width:100%;"
! Field !! Auto-Links? !! Auto-Categorizes?
|-
| Name || {{No}} || {{No}}
|-
| Campaign || {{Yes}} || {{Yes}}
|-
| Species || {{Yes}} || {{Yes}}
|-
| Class || {{Yes}} || {{Yes}}
|-
| Subclass || {{Yes}} || {{Yes}}
|-
| Gender || {{Yes}} || {{Yes}}
|-
| Titles || {{No}} || {{No}}
|-
| Aliases || {{No}} || {{No}}
|}


Status automatically categorizes the page into Living characters, Dead characters, or Missing characters.
Additionally, the character template adds the Character category and a dynamic campaign dependent character category. IE Allesian Archives Character if that is filled in for campaign. I may also add an important connections tag, unless I can find a better way to fast track important links. Same with Age but like better.


If the player field is filled in the page is categorized as a Player Character, otherwise as an NPC. All character pages are added to the Characters category.
== Usage ==
<pre>
{{Character
|name=
|image=
|campaign=
|species=
|gender=
|class=
|subclass=
|titles=
|aliases=
}}
</pre>
[[Category:Infobox templates]]
</noinclude>
</noinclude>


{{Infobox
 
|title={{{name|{{PAGENAME}}}}}
|1=
{{#if:{{{image|}}}|{{RowImage|{{{image}}}}}|}}
{{#if:{{{player|}}}|{{RowKV|Player|{{{player}}}}}|}}
{{#if:{{{campaign|}}}|{{RowKV|Campaign|[[{{{campaign}}}]]}}|}}
{{#if:{{{species|}}}|{{RowKV|Species|[[{{{species}}}]]}}|}}
{{#if:{{{gender|}}}|{{RowKV|Gender|{{{gender}}}}}|}}
{{#if:{{{age|}}}|{{RowKV|Age|{{{age}}}}}|}}
{{#if:{{{class|}}}|{{RowKV|Class|{{{class}}}}}|}}
{{#if:{{{subclass|}}}|{{RowKV|Subclass|{{{subclass}}}}}|}}
{{#if:{{{alignment|}}}|{{RowKV|Alignment|{{{alignment}}}}}|}}
{{#if:{{{occupation|}}}|{{RowKV|Occupation|{{{occupation}}}}}|}}
{{#if:{{{titles|}}}|{{RowKV|Titles|{{CommaLink|{{{titles}}}}}}}|}}
{{#if:{{{aliases|}}}|{{RowKV|Aliases|{{CommaLink|{{{aliases}}}}}}}|}}
{{#if:{{{affiliation|}}}|{{RowKV|Affiliation|{{CommaLink|{{{affiliation}}}}}}}|}}
{{#if:{{{groups|}}}|{{RowKV|Groups|{{CommaLink|{{{groups}}}}}}}|}}
{{#if:{{{religion|}}}|{{RowKV|Religion|{{{religion}}}}}|}}
{{#if:{{{birthplace|}}}|{{RowKV|Birthplace|[[{{{birthplace}}}]]}}|}}
{{#if:{{{residence|}}}|{{RowKV|Residence|[[{{{residence}}}]]}}|}}
{{#if:{{{nation|}}}|{{RowKV|Nation|[[{{{nation}}}]]}}|}}
{{#if:{{{born|}}}|{{RowKV|Born|{{{born}}}}}|}}
{{#if:{{{died|}}}|{{RowKV|Died|{{{died}}}}}|}}
{{#if:{{{parents|}}}|{{RowKV|Parents|{{CommaLink|{{{parents}}}}}}}|}}
{{#if:{{{spouse|}}}|{{RowKV|Spouse|[[{{{spouse}}}]]}}|}}
{{#if:{{{siblings|}}}|{{RowKV|Siblings|{{CommaLink|{{{siblings}}}}}}}|}}
{{#if:{{{children|}}}|{{RowKV|Children|{{CommaLink|{{{children}}}}}}}|}}
{{#if:{{{status|}}}|{{RowKV|Status|{{{status}}}}}|}}
{{#if:{{{introduced|}}}|{{RowKV|First Seen|''{{{introduced}}}''}}|}}
{{#if:{{{last_seen|}}}|{{RowKV|Last Seen|''{{{last_seen}}}''}}|}}
}}
== Lore ==
<includeonly>
<includeonly>
{{#cargo_store:_table=Characters
{{#cargo_store:_table=Characters
Line 74: Line 64:
|class={{{class|}}}
|class={{{class|}}}
|subclass={{{subclass|}}}
|subclass={{{subclass|}}}
|occupation={{{occupation|}}}
|gender={{{gender|}}}
|gender={{{gender|}}}
|age={{{age|}}}
|titles={{{titles|}}}
|alignment={{{alignment|}}}
|aliases={{{aliases|}}}
|status={{{status|}}}
|birthplace={{{birthplace|}}}
|residence={{{residence|}}}
|nation={{{nation|}}}
|religion={{{religion|}}}
|groups={{{groups|}}}
|affiliation={{{affiliation|}}}
|player={{{player|}}}
|introduced={{{introduced|}}}
|last_seen={{{last_seen|}}}
}}
}}
{{#if:{{{campaign|}}}|[[Category:{{ucfirst:{{{campaign}}}}} Characters]]}}
{{#if:{{{species|}}}|[[Category:{{ucfirst:{{{species}}}}}]]}}
{{#if:{{{class|}}}|[[Category:{{ucfirst:{{{class}}}}}]]}}
{{#if:{{{subclass|}}}|[[Category:{{ucfirst:{{{subclass}}}}}]]}}
{{#if:{{{gender|}}}|[[Category:{{ucfirst:{{{gender}}}}} Characters]]}}


{{#if:{{{player|}}}|[[Category:Player Characters]]|[[Category:Non Player Characters]]}}
{{Infobox|title={{{name|{{PAGENAME}}}}}|1=
 
{{#if:{{{image|}}}|{{RowImage|{{{image}}}}}}}
{{#switch:{{{status|}}}
{{#if:{{{campaign|}}}|{{RowKV|Campaign|[[{{{campaign}}}]]}}}}
| Dead = [[Category:Dead Characters]]
{{#if:{{{species|}}}|{{RowKV|Species|[[{{{species}}}]]}}}}
| Alive = [[Category:Living Characters]]
{{#if:{{{gender|}}}|{{RowKV|Gender|[[{{{gender}}}]]}}}}
| Missing = [[Category:Missing Characters]]
{{#if:{{{class|}}}|{{RowKV|Class|[[{{{class}}}]]}}}}
{{#if:{{{subclass|}}}|{{RowKV|Subclass|[[{{{subclass}}}]]}}}}
{{#if:{{{titles|}}}|{{RowKV|Titles|{{{titles}}}}}}}
{{#if:{{{aliases|}}}|{{RowKV|Aliases|{{{aliases}}}}}}}
}}
}}
{{#if:{{{species|}}}|[[Category:{{ucfirst:{{{species}}}}}]]}}
{{#if:{{{class|}}}|[[Category:{{ucfirst:{{{class}}}}}]]}}
{{#if:{{{campaign|}}}|[[Category:{{ucfirst:{{{campaign}}}}}]]}}
{{#if:{{{nation|}}}|[[Category:{{ucfirst:{{{nation}}}}}]]}}
{{#if:{{{alignment|}}}|[[Category:{{ucfirst:{{{alignment}}}}}]]}}


[[Category:Characters]]
[[Category:Characters]]
</includeonly>
</includeonly>
<noinclude>
== Usage ==
<pre>
{{Character
|name=
|image=
|campaign=
|player=
|species=
|gender=
|age=
|class=
|subclass=
|alignment=
|occupation=
|titles=
|aliases=
|affiliation=
|groups=
|religion=
|birthplace=
|residence=
|nation=
|born=
|died=
|parents=
|spouse=
|siblings=
|children=
|status=
|introduced=
|last_seen=
}}
</pre>
[[Category:Infobox templates]]
</noinclude>

Latest revision as of 03:22, 8 June 2026

This template defines the table "Characters". View table.

About

This template creates a character infobox that floats on the right side of the page. All fields are optional — empty fields are automatically hidden.

It also supports automatic categorization and linking for certain fields.

Field Reference

Field Auto-Links? Auto-Categorizes?
Name No No
Campaign Yes Yes
Species Yes Yes
Class Yes Yes
Subclass Yes Yes
Gender Yes Yes
Titles No No
Aliases No No

Additionally, the character template adds the Character category and a dynamic campaign dependent character category. IE Allesian Archives Character if that is filled in for campaign. I may also add an important connections tag, unless I can find a better way to fast track important links. Same with Age but like better.

Usage

{{Character
|name=
|image=
|campaign=
|species=
|gender=
|class=
|subclass=
|titles=
|aliases=
}}