Template:Infobox NPC: Difference between revisions
From OpenSpell Wiki
Jump to navigationJump to search
Created page with "<noinclude> {{#cargo_declare:_table=npcs | name = String | combat_level = Integer | hitpoints = Integer | accuracy = Integer | strength = Integer | defense = Integer | magic = Integer | range = Integer | speed = Integer | aggro = Boolean | aggro_radius = Integer | respawn = Integer | pickpocketable = Boolean | can_shop = Boolean }} == Usage == Place on any NPC article page. All parameters are optional except <..." |
No edit summary |
||
| (3 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
<noinclude> | <noinclude> | ||
== Infobox NPC == | |||
Use this template at the top of every NPC article. | |||
== | === Parameters === | ||
{| class="wikitable" | |||
! Parameter !! Required !! Description | |||
|- | |||
| <code>name</code> || Yes || The NPC's in-game name, exactly as it appears | |||
|- | |||
| <code>image</code> || No || Full image syntax, e.g. <code><nowiki>[[File:Knight.png|250px]]</nowiki></code>. Upload images via [[Special:Upload]]. | |||
|- | |||
| <code>caption</code> || No || Short caption shown below the image | |||
|- | |||
| <code>description</code> || No || The in-game description/examine text | |||
|- | |||
| <code>combat_level</code> || No || Leave empty for non-combat NPCs | |||
|- | |||
| <code>hitpoints</code> || No || | |||
|- | |||
| <code>accuracy</code> || No || | |||
|- | |||
| <code>strength</code> || No || | |||
|- | |||
| <code>defense</code> || No || | |||
|- | |||
| <code>magic</code> || No || | |||
|- | |||
| <code>range</code> || No || | |||
|- | |||
| <code>speed</code> || No || | |||
|- | |||
| <code>aggro</code> || No || <code>yes</code> or <code>no</code> | |||
|- | |||
| <code>respawn</code> || No || Respawn time in game ticks | |||
|- | |||
| <code>pickpocketable</code> || No || <code>yes</code> or <code>no</code> | |||
|- | |||
| <code>can_shop</code> || No || <code>yes</code> or <code>no</code> | |||
|} | |||
=== Example === | |||
<pre> | <pre> | ||
{{Infobox NPC | {{Infobox NPC | ||
| name | | name = Knight | ||
| image = | | image = [[File:Knight.png|250px]] | ||
| description | | caption = A Knight patrolling the overworld | ||
| combat_level = | | description = A noble warrior | ||
| hitpoints | | combat_level = 60 | ||
| accuracy | | hitpoints = 65 | ||
| strength | | accuracy = 40 | ||
| defense | | strength = 45 | ||
| magic | | defense = 40 | ||
| range | | magic = 1 | ||
| speed | | range = 1 | ||
| aggro | | speed = 1 | ||
| aggro = no | |||
| respawn | | respawn = 75 | ||
| pickpocketable = | | pickpocketable = yes | ||
| can_shop | | can_shop = no | ||
}} | }} | ||
</pre> | </pre> | ||
See also: [[Template:NPC/preload]] for the full NPC page skeleton. | |||
[[Category:Infobox templates]] | [[Category:Infobox templates]] | ||
</noinclude><includeonly | </noinclude> | ||
<includeonly> | |||
{| class="wikitable | {| class="wikitable" style="float:right; clear:right; margin:0 0 1em 1.5em; text-align:left; width:300px; font-size:13px; border:1px solid #a2a9b1;" | ||
|- | |- | ||
! colspan="2 | ! colspan="2" style="background:#2c2c2c; color:#f0e6c8; font-size:1.15em; padding:8px 12px; text-align:center; border-bottom:2px solid #c8a96e;" | {{{name|Unknown NPC}}} | ||
|- | |- | ||
| colspan="2" style="padding: | | colspan="2" style="text-align:center; padding:10px; background:#1a1a1a;" | | ||
{{{image|}}} | |||
{{{caption|}}} | |||
|- | |- | ||
! colspan="2 | ! colspan="2" style="background:#3a3a3a; color:#c8a96e; text-align:center; padding:4px;" | General | ||
|- | |- | ||
! style="width:45%; padding:4px 8px; background:#f8f9fa;" | Description | |||
| style="padding:4px 8px;" | ''{{{description|}}}'' | |||
| style=" | |||
|- | |- | ||
! style="padding:4px 8px; background:#f8f9fa;" | Pickpocketable | |||
| style="padding:4px 8px;" | {{{pickpocketable|}}} | |||
| {{ | |||
|- | |- | ||
! style="padding:4px 8px; background:#f8f9fa;" | Shop | |||
| style="padding:4px 8px;" | {{{can_shop|}}} | |||
| {{ | |||
|- | |- | ||
! colspan="2" style="background:#3a3a3a; color:#c8a96e; text-align:center; padding:4px;" | Combat stats | |||
! colspan="2 | |||
|- | |- | ||
! | Combat level | ! style="padding:4px 8px; background:#f8f9fa;" | Combat level | ||
| {{{combat_level}}} | | style="padding:4px 8px;" | {{{combat_level|—}}} | ||
|- | |- | ||
! | Hitpoints | ! style="padding:4px 8px; background:#f8f9fa;" | Hitpoints | ||
| {{{hitpoints|}}} | | style="padding:4px 8px;" | {{{hitpoints|—}}} | ||
|- | |- | ||
! | Accuracy | ! style="padding:4px 8px; background:#f8f9fa;" | Accuracy | ||
| {{{accuracy|}}} | | style="padding:4px 8px;" | {{{accuracy|—}}} | ||
|- | |- | ||
! | Strength | ! style="padding:4px 8px; background:#f8f9fa;" | Strength | ||
| {{{strength|}}} | | style="padding:4px 8px;" | {{{strength|—}}} | ||
|- | |- | ||
! | Defense | ! style="padding:4px 8px; background:#f8f9fa;" | Defense | ||
| {{{defense|}}} | | style="padding:4px 8px;" | {{{defense|—}}} | ||
|- | |- | ||
! | Magic | ! style="padding:4px 8px; background:#f8f9fa;" | Magic | ||
| {{{magic|}}} | | style="padding:4px 8px;" | {{{magic|—}}} | ||
|- | |- | ||
! | Ranged | ! style="padding:4px 8px; background:#f8f9fa;" | Ranged | ||
| {{{range|}}} | | style="padding:4px 8px;" | {{{range|—}}} | ||
|- | |- | ||
! | Speed | ! style="padding:4px 8px; background:#f8f9fa;" | Speed | ||
| {{{speed|}}} | | style="padding:4px 8px;" | {{{speed|—}}} | ||
|- | |- | ||
! style="padding:4px 8px; background:#f8f9fa;" | Aggressive | |||
| style="padding:4px 8px;" | {{{aggro|—}}} | |||
| | |||
|- | |- | ||
! style="padding:4px 8px; background:#f8f9fa;" | Respawn (ticks) | |||
| style="padding:4px 8px;" | {{{respawn|—}}} | |||
| {{{respawn | |||
| | |||
} | |||
}} | |||
|} | |} | ||
</includeonly> | |||
Latest revision as of 09:17, 28 February 2026
Infobox NPC
[edit]Use this template at the top of every NPC article.
Parameters
[edit]| Parameter | Required | Description |
|---|---|---|
name |
Yes | The NPC's in-game name, exactly as it appears |
image |
No | Full image syntax, e.g. [[File:Knight.png|250px]]. Upload images via Special:Upload.
|
caption |
No | Short caption shown below the image |
description |
No | The in-game description/examine text |
combat_level |
No | Leave empty for non-combat NPCs |
hitpoints |
No | |
accuracy |
No | |
strength |
No | |
defense |
No | |
magic |
No | |
range |
No | |
speed |
No | |
aggro |
No | yes or no
|
respawn |
No | Respawn time in game ticks |
pickpocketable |
No | yes or no
|
can_shop |
No | yes or no
|
Example
[edit]{{Infobox NPC
| name = Knight
| image = [[File:Knight.png|250px]]
| caption = A Knight patrolling the overworld
| description = A noble warrior
| combat_level = 60
| hitpoints = 65
| accuracy = 40
| strength = 45
| defense = 40
| magic = 1
| range = 1
| speed = 1
| aggro = no
| respawn = 75
| pickpocketable = yes
| can_shop = no
}}
See also: Template:NPC/preload for the full NPC page skeleton.