Template:Npc infobox

From Calamity Mod Wiki
Jump to navigation Jump to search

{{#cargo_attach _table = Immunities }}

Template-info.svg Documentation The documentation below is transcluded from Template:Npc infobox/doc. (edit | history)

Usage

All variables except Type are optional.

  • The image parameter replaces the main image. A single bare filename must be entered, without any other code.
  • The imagealt parameter replicates the functionality of the image parameter in {{item infobox}}. It replaces the main image, but takes any code. Multiple images can be provided, and/or text and other formatting. Images specified using imagealt require the full [[File: ]] markup.
{{npc infobox
| width = custom width for the infobox; default = 23em
| name = character name; default = page name
| variant = yes; only if it is a console/mobile exclusive variant
| namesub = name sub-line; default = none
| image = imagename.png; default = pagename.png
| imagealt = [[File:imagename.png]]
| image2 = imagename2.png, displays at the bottom on the infobox
| image2caption = caption for image2
| type = character type: Enemy for enemies, Town for friendly NPCs, Critter for friendly critters
| environment = biome where can they be found
| environment2 = sub-biome
| damage = damage inflicted per hit from this character
| life = total max health
| defense = defense the character has
| knockback = knockback resistance
| debuff = debuff inflicted
| debuffchance = chances of inflicting the debuff
| debufftip = debuff tooltip
| duration = length of time the debuff lasts
| debuff2 = second debuff inflicted
| debuffchance2 = chances of inflicting the second debuff
| debufftip2 = second debuff's tooltip
| duration2 = length of time the second debuff lasts
| debuff3 = third debuff inflicted
| debuffchance3 = chances of inflicting the third debuff
| debufftip3 = third debuff's tooltip
| duration3 = length of time the third debuff lasts
| power = for catchable characters, like critters, which can be used for things like bait (enter "15% bait", for example)
| banner = yes, if this character drops a Banner
| bannername = if banner=yes, use this to specify a custom banner name. default: "[page name] Banner" or "[name parameter] Banner"
| id = id of the npc
| idbuff = id of the (de)buff caused by the npc
| money = dropped coins, enter using coin templates: {{value}}
| hardmode = yes, for NPCs that only become available in Hardmode worlds
| postml = yes, for NPCs that only become available after the Moon Lord is defeated
| hurt = adds the hurt sound made by the NPC
| killed = adds the death sound made by the NPC
| sound = adds a sound made by the NPC
| soundtext = adds a label to the sound
| sound2 = adds another sound made by the NPC, works with sound3, sound4, etc
| sound2text = adds a label to the second sound, works with sound3text, sound4text, etc
| item1|quantity1|rate1
...
| item15|quantity15|rate15
}}
This template is i18n-ready, which means it is easy to localize for different languages. Please see I18n & l10n for Templates to learn more.
See Template:Npc infobox/l10n for the localization of this template.