Difference between revisions of "Template:Creature Summary"

The Beyond Skyrim Wiki — Hosted by UESP
Jump to: navigation, search
m (1 revision imported: templates from UESPWiki)
m (clean out MetaTemplate - part-complete)
Line 1: Line 1:
<includeonly><cleanspace>
+
<includeonly><!--
<!-- Note: This template makes use of instructions like {{#if:1|{{{attack}}}}} instead of just {{{attack}}} to trigger correct bullet handling with parameters like "drops=* Minor Loot" (without requiring a leading line break in the template call). -->
+
--><!-- Note: This template makes use of instructions like {{#if:1|{{{attack}}}}} instead of just {{{attack}}} to trigger correct bullet handling with parameters like "drops=* Minor Loot" (without requiring a leading line break in the template call). --><!--
 
+
--><!-- Trail --><!--
<!-- Defines -->
+
-->{{#if:{{{notrail|}}}||{{Trail|Fauna|{{{type|}}}}}}}<<!--
{{#inherit:ns_base}}
+
--><!-- Categories --><!--
{{#define:ns_base|Oblivion|if={{#switch:{{NAMESPACE}}|User|Template=1|0}}}}
+
-->[[Category:{{NAMESPACE}}-Creatures-All]]<!--
{{#define:bgcolor|{{Race Color|{{{type|}}}|noquotes=1}}}}
+
-->{{#if:{{{type|}}}|{{#ifeq:{{{type|}}}|N/A||[[Category:{{NAMESPACE}}-Creatures-{{{type}}}]]}}}}<!--
{{#define:fcolor|{{Race Color FC|{{{type|}}}|noquotes=1}}}}
+
-->{{#if:{{{soul|}}}|[[Category:{{NAMESPACE}}-Souls-{{{soul|}}}]]}}<!--
{{#define:headerStyle|style="color:{{{fcolor}}}; background-color:{{{bgcolor}}}"}}
+
-->__NOTOC__
{{#define:image|case=any}}
+
{| class="wikitable infobox" style="width:25%; float:right;"
{{#define:titlename|{{LABELNAME}}}}
 
{{Parameter Check|type=Creature}}
 
{{#unset:image|ifnot={{#ifeq:{{{image|}}}|none||{{{image|}}}}}}}
 
 
 
<!-- Bread Crumb Trail -->
 
{{#ifeq:{{NAMESPACE}}|User||{{#inittrail:Creatures|if={{#if:{{{notrail|}}}|0|1}}}}
 
{{#addtotrail:{{{type}}}|ns={{{typenamesp|{{NS_ID}}}}}|if={{#if:{{{notrail|}}}|0|{{{type|}}}}}}}
 
{{#addtotrail:Merchants|separator=' / '|if={{#if:{{{notrail|}}}|0|{{{buys|}}}{{{sells|}}}}}}}
 
{{#addtotrail:[[{{NS_FULL}}Blacksmith|Blacksmiths]]|separator=' / '|if={{#if:{{{notrail|}}}|0|{{{repair|}}}}}}}}}
 
 
 
<!-- Categories -->
 
{{#if:{{{nocat|}}}||
 
{{#switch:{{SUBJECTSPACE}}|User|Template=
 
|[[Category:{{NS_CATEGORY}}-Creatures-All]]
 
{{#define:speciescat|{{#ifeq:{{{species|}}}|Radiant|Radiant Creatures|{{{species|}}}}}}}
 
{{#ifeq:{{{health|}}}|0|[[Category:{{NS_CATEGORY}}-Dead Creatures]]|
 
{{#if:{{{type|}}}|{{#ifeq:{{{type|}}}|N/A||{{#ifeq:{{{type|}}}|Radiant||[[Category:{{NS_CATEGORY}}-Creatures-{{{type}}}]]}}}}}}
 
{{#if:{{{tribe|}}}|[[Category:{{NS_CATEGORY}}-Creatures-{{{type}}}-{{{tribe}}}]]}}
 
{{#ifeq:{{{speciescat|}}}|none||{{#ifeq:{{{species|}}}|N/A||{{#if:{{{speciescat|{{{species|}}}}}}|{{#ifeq:{{{speciescat|}}}|Radiant Creatures|[[Category:{{NS_CATEGORY}}-{{{speciescat|}}}]]|[[Category:{{NS_CATEGORY}}-Creatures-{{{type}}}-{{{speciescat|{{{species}}}}}}]]}}}}}}}}
 
{{#if:{{{buys|{{{sells|}}}}}}|[[Category:{{NS_CATEGORY}}-Merchants]]}}
 
{{#if:{{{repair|}}}|[[Category:{{NS_CATEGORY}}-Repairs]]}}
 
{{#if:{{{follower|}}}|[[Category:{{NS_CATEGORY}}-Follower Creatures]]|}}
 
{{#if:{{{essential|}}}|[[Category:{{NS_CATEGORY}}-Essential Creatures]]|}}
 
{{#if:{{{protected|}}}|[[Category:{{NS_CATEGORY}}-Protected Creatures]]|}}}}}}
 
{{#local:soultype|{{#switch:{{NS_PARENT}}
 
  |Morrowind={{#iferror:{{#expr:{{{soul|}}} * 1}}||{{#ifexpr:{{{soul|}}}<=30|Petty
 
    |{{#ifexpr:{{{soul|}}}<=60|Lesser
 
    |{{#ifexpr:{{{soul|}}}<=120|Common
 
    |{{#ifexpr:{{{soul|}}}<=180|Greater
 
    |{{#ifexpr:{{{soul|}}}<=600|Grand|Divine
 
    }}}}}}}}}}}}
 
  |Oblivion={{#switch:{{{soul}}}|Petty|Lesser|Common|Greater|Grand={{{soul}}}|{{#ifeq:{{#sub:{{{soul|}}}|0|7}}|Leveled|Leveled}}}}
 
  |Skyrim={{#switch:{{{soul}}}|Petty|Lesser|Common|Greater|Grand|Black|Dragon={{{soul}}}|{{#ifeq:{{#sub:{{{soul|}}}|0|7}}|Leveled|Leveled}}}}
 
}}|if={{#if:{{{soul|}}}|1}}}}
 
{{#if:{{{soultype|}}}|[[Category:{{NS_CATEGORY}}-Souls-{{{soultype|}}}]]}}
 
}}
 
 
 
<!-- Infobox -->
 
</cleanspace><cleantable>
 
{|class="wikitable" width="{{{tablewidth|33%}}}" style="float:right; margin:0 0 0.75em 1em"
 
 
|-
 
|-
!colspan=4 {{{headerStyle}}}|{{{titlename}}} {{#ifeq:{{NS_PARENT}}|Morrowind|{{Small|({{#if:{{{id|}}}|{{{id}}}|{{lc:{{{titlename}}}}}}})}}|{{#if:{{{refid|}}}|{{IDs2|addbefore=(RefID:&#32;|{{{refid}}}|addafter=)}}}}}}
+
!colspan=4 style="color:{{{fgcolor}}}; background-color:{{{bgcolor}}}"|{{{titlename|{{PAGENAME}}}}} {{#if:{{{refid|}}}|<br><small>(RefID:&#32;{{{refid}}})</small>}}
 
|-
 
|-
!Added by
+
{{#if:{{{projects|}}}|
|colspan=3|{{{mod|}}}
+
!Found in
|-
+
{{!}} colspan=3 {{!}} {{{projects}}} }}
!Home&nbsp;City
 
|colspan=3|{{{city|}}}
 
|-
 
!House
 
|colspan=3|{{{house|}}}
 
 
|-
 
|-
 +
{{#if:{{{location|}}}|
 
!Location
 
!Location
|colspan=3|{{{loc|}}}
+
{{!}} colspan=3 {{!}} {{{location}}} }}
 
|-
 
|-
 +
{{#if:{{{species|}}}|
 
!Species
 
!Species
|{{#if:{{{species|}}}|{{#ifeq:{{{species|}}}|N/A|N/A|{{#if:{{#pos:{{{species|}}}|:}}|{{{species}}}|{{#ifeq:{{{speciescat|}}}|none|{{{species}}}|{{SkipLink|{{NS_FULL}}{{{species}}}|{{{species}}}}}}}}}}}|{{huh}}}}
+
{{!}} {{#ifeq:{{{species|}}}|N/A|N/A|{{#if:{{#pos:{{{species|}}}|:}}|{{{species}}}|{{Autolink|{{{species}}}}}}}}}
!{{SkipLink|{{NS_PARENT}}:Souls|Soul}}
+
!{{UESP|Skyrim:Souls|Soul}}
| {{#ifeq:{{NS_PARENT}}|Morrowind
+
{{!}} {{{soul|}}}
  |{{#if:{{{soultype|}}}
+
<!----------------- HALF DONE ---------------------->
    |{{{soultype}}} ({{{soul}}})
 
    |{{{soul|}}}}}
 
  |{{{soul|}}}}}
 
 
|-
 
|-
 
!Level
 
!Level

Revision as of 17:35, 18 May 2019

Summary

This template creates an infobox for use on all Creature pages. It includes the appropriate bread crumb trails and categories.

Parameters

Creature Summary
Parameter Scope Description
titlename optional Creature's name as displayed at the top of the infobox. Will default to use PAGENAME.
refid optional Creature's reference FormID. Multiple IDs should be separated with a comma.
baseid optional Creature's base FormID. Multiple IDs should be separated with a comma.
type optional Creature's type (e.g. Daedra, Undead, etc.)
species optional Species of the creature.
soul optional Creature's soul (Petty, Common, Grand, etc.)
level optional Creature's level
health optional Creature's health.
magicka optional Creature's magicka.
stamina optional Creature's stamina.
perks optional Creature's perks.
skills optional Creature's primary skills.
abilities optional Creature's passive abilities - resistances, weaknesses, etc.
image optional The name of an image file for this Creature, just the file name.
notrail optional If set to "yes", the breadcrumb trail normally created by the template is suppressed (for cases where multiple templates are used on one page or when used for a generic NPC).
nocat optional If set to "yes", the categories normally added by the template are suppressed.

Example

{{Creature Summary
|image=Zombie.jpg
|caption=A zombie
|type=Undead
|species=Zombie
|soul=Leveled
|level=lvl-1
|health=50×(lvl-1)
|magicka=N/A
|abilities=
*[[Oblivion:Resist Frost|Resist Frost]] 30%
*[[Oblivion:Resist Magic|Resist Magic]] 30%
*[[Oblivion:Resist Poison|Resist Poison]] 100%
*[[Oblivion:Weakness to Fire|Weakness to Fire]] 60%
|refid=00091AAA
|baseid=00091AA9
}}


Creature Summary
Zombie.jpg
A zombie
Type Undead
Species Zombie
Soul Leveled
Level lvl-1
Health 50×(lvl-1)
Magicka N/A
Abilities
BaseID: 00091AA9
RefID: 00091AAA