×
Create a new article
Write your page title here:
We currently have 3,121 articles on YumeWiki. Type your article name above or click on one of the titles below and start writing!



YumeWiki
3,121Articles

Template:NPCBox/doc: Difference between revisions

(rearranged parameters as they are listed, added 4 new parameters to list)
(add image_class, change param order, add categories)
 
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<templatedata>
<templatedata>
{
{ "description": "Displays an infobox containing a character's details.",
"params": {
"params": {
"headercolor": {
"headercolor": {
"label": "Header color",
"description": "The header's background color.",
"description": "The header's background color.",
"type": "string",
"type": "string",
"suggested": true,
"suggested": true,
"example": "#3366CC"
"default": "#3366CC"
},
},
"headerfontcolor": {
"headerfontcolor": {
"label": "Header font color",
"description": "The header's text color.",
"description": "The header's text color.",
"type": "string",
"type": "string",
"suggested": true,
"suggested": true,
"example": "#ffffff"
"default": "#ffffff"
},
},
"image": {
"image": {
"description": "An image representing the NPC.",
"label": "NPC image",
"description": "The file name for the image to be displayed. It should clearly show the NPC in its usual appearance.",
"type": "wiki-file-name",
"example": "Uboa.png",
"required": true
},
"role": {
"label": "Role",
"description": "The NPC's purpose.",
"example": "Gives the [[Yume 2kki:Effects#Boy|Boy]] effect",
"type": "string",
"type": "string",
"required": true
"required": true
},
},
"caption": {
"Collectibles": {
"description": "A caption describing the NPC's image.",
"label": "Collectibles",
"type": "string"
"description": "Collectibles that you can unlock by interacting with the NPC.",
"example": "WP #87, Menu Theme #65",
"type": "string",
"aliases": [
"Wallpapers",
"Menu"
],
"required": true
},
},
"location": {
"Events": {
"description": "The NPC's location.",
"label": "Events",
"description": "Events associated with this NPC.",
"type": "string",
"type": "string",
"required": true
"required": true
},
},
"role": {
"location": {
"description": "The NPC's purpose.",
"label": "Location",
"type": "content",
"description": "The NPC's location, or a comma-separated list of locations.",
"type": "string",
"required": true
"required": true
},
},
"size": {
"size": {
"label": "Size",
"description": "The NPC's physical size.",
"description": "The NPC's physical size.",
"type": "string"
"example": "Standard",
"type": "string",
"suggested": true
},
},
"killable": {
"killable": {
"description": "Whether the NPC can be killed.",
"label": "Killable?",
"description": "Whether the NPC is able to be killed using the game's weapon effect.",
"suggestedvalues": ["Yes","No"],
"type": "string",
"type": "string",
"required": true
},
"notes": {
"description": "Additional notes related to the NPC.",
"type": "content",
"suggested": true
"suggested": true
},
},
"EffectName": {
"species": {
"description": "The name of the effect associated with this NPC.",
"label": "Species",
"description": "The in-game species of the NPC.",
"type": "string"
"type": "string"
},
},
"Effects": {
"notes": {
"description": "The effect that you can get from this NPC.",
"label": "Misc. Notes",
"description": "Any further notes on the NPC that are important enough to include in the box.",
"type": "string"
"type": "string"
},
},
"Wallpapers": {
"name": {
"description": "Wallpapers that you can get from this NPC.",
"label": "Display Name",
"example": "WP #1",
"description": "Overrides using the page name as the header text. If the name of the character should be changed on the wiki, move the page instead of using this parameter.",
"type": "string",
"type": "string",
"suggested": true
"autovalue": "{{PAGENAME}}"
},
},
"Menu": {
"headerfontsize": {
"description": "Menu themes that the NPC would you.",
"label": "Header font size",
"example": "Menu Theme #1",
"description": "The header's font size as a percentage.",
"type": "string",
"type": "string",
"suggested": true
"default": "200%"
},
"imagewidth": {
"label": "Image width",
"description": "The image width in px.",
"type": "number",
"default": "250"
},
},
"Events": {
"image_class": {
"description": "Events associated with this NPC.",
"label": "Image class",
"description": "A CSS class to apply to the image.",
"type": "string",
"type": "string",
"suggested": true
"default": "pixel-perfect"
},
},
"species": {
"caption": {
"description": "The in-game species of the NPC.",
"label": "Image caption",
"type": "string"
"description": "A corresponding caption for the image, visible if a value is provided.",
},
"name": {
"description": "The name of the NPC (if different than the page name).",
"type": "string"
},
"imagewidth": {
"description": "A custom width for the NPC's image.",
"example": "200px",
"type": "string"
"type": "string"
},
"headerfontsize": {
"example": "40px",
"type": "string",
"description": "The header's font size."
}
}
},
},
"description": "A template used in displaying NPC information.",
"format": "{{_\n|_ = _\n}}",
"format": "{{_\n|_ = _\n}}",
"paramOrder": [
"paramOrder": [
Line 100: Line 115:
"image",
"image",
"imagewidth",
"imagewidth",
"image_class",
"caption",
"caption",
"species",
"role",
"role",
"Collectibles",
"Events",
"location",
"location",
"Effects",
"Wallpapers",
"Menu",
"Events",
"size",
"size",
"killable",
"killable",
"notes",
"species",
"EffectName"
"notes"
]
]
}
}
</templatedata>
</templatedata>
==General usage==
<pre style="line-height:1.6;">
{{NPCBox
|name = Uboa
|headercolor = #000000
|headerfontcolor = #ffffff
|image = Uboa.png
|role = Traps [[Yume Nikki:Madotsuki|Madotsuki]] in [[Yume Nikki:Poniko's House#Uboa's Trap|Uboa's Trap]]
|Collectibles = None
|Events = [[Yume Nikki:Events#Uboa|Uboa]]
|location = [[Yume Nikki:Poniko's House|Poniko's House]], [[Yume Nikki:Uboa's Trap|Uboa's Trap]]
|size = Standard
|killable = No
|species =
|notes =
}}
</pre>
will return:
{{NPCBox
|name = Uboa
|headercolor = #000000
|headerfontcolor = #ffffff
|image = Uboa.png
|role = Traps [[Yume Nikki:Madotsuki|Madotsuki]] in [[Yume Nikki:Poniko's House#Uboa's Trap|Uboa's Trap]]
|Collectibles = None
|Events = [[Yume Nikki:Events#Uboa|Uboa]]
|location = [[Yume Nikki:Poniko's House|Poniko's House]], [[Yume Nikki:Uboa's Trap|Uboa's Trap]]
|size = Standard
|killable = No
|species =
|notes =
}}
<noinclude>__NOTOC__ [[Category:Template documentation]]</noinclude>
<includeonly>__NOEDITSECTION__
[[Category:Infobox templates]]
[[Category:Character templates]]
</includeonly>

Latest revision as of 01:50, 19 November 2024

Displays an infobox containing a character's details.

Template parameters

This template has custom formatting.

ParameterDescriptionTypeStatus
Display Namename

Overrides using the page name as the header text. If the name of the character should be changed on the wiki, move the page instead of using this parameter.

Auto value
{{PAGENAME}}
Stringoptional
Header colorheadercolor

The header's background color.

Default
#3366CC
Stringsuggested
Header font colorheaderfontcolor

The header's text color.

Default
#ffffff
Stringsuggested
Header font sizeheaderfontsize

The header's font size as a percentage.

Default
200%
Stringoptional
NPC imageimage

The file name for the image to be displayed. It should clearly show the NPC in its usual appearance.

Example
Uboa.png
Filerequired
Image widthimagewidth

The image width in px.

Default
250
Numberoptional
Image classimage_class

A CSS class to apply to the image.

Default
pixel-perfect
Stringoptional
Image captioncaption

A corresponding caption for the image, visible if a value is provided.

Stringoptional
Rolerole

The NPC's purpose.

Example
Gives the [[Yume 2kki:Effects#Boy|Boy]] effect
Stringrequired
CollectiblesCollectibles Wallpapers Menu

Collectibles that you can unlock by interacting with the NPC.

Example
WP #87, Menu Theme #65
Stringrequired
EventsEvents

Events associated with this NPC.

Stringrequired
Locationlocation

The NPC's location, or a comma-separated list of locations.

Stringrequired
Sizesize

The NPC's physical size.

Example
Standard
Stringsuggested
Killable?killable

Whether the NPC is able to be killed using the game's weapon effect.

Suggested values
Yes No
Stringsuggested
Speciesspecies

The in-game species of the NPC.

Stringoptional
Misc. Notesnotes

Any further notes on the NPC that are important enough to include in the box.

Stringoptional

General usage

{{NPCBox
|name = Uboa
|headercolor = #000000
|headerfontcolor = #ffffff
|image = Uboa.png
|role = Traps [[Yume Nikki:Madotsuki|Madotsuki]] in [[Yume Nikki:Poniko's House#Uboa's Trap|Uboa's Trap]]
|Collectibles = None
|Events = [[Yume Nikki:Events#Uboa|Uboa]]
|location = [[Yume Nikki:Poniko's House|Poniko's House]], [[Yume Nikki:Uboa's Trap|Uboa's Trap]]
|size = Standard
|killable = No
|species = 
|notes = 
}}

will return:

Uboa
Uboa.png
Basic Info
Role Traps Madotsuki in Uboa's Trap
Collectibles None
Events Uboa
Location

Poniko's House
Uboa's Trap

Other
Size Standard
Killable? No