Template:Infobox character: Difference between revisions
m (changed doc from referencing sandbox) |
m (Automated Formatting) |
||
(6 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
<noinclude>{{Documentation/sandbox|doc= | <noinclude>{{Documentation/sandbox|doc= | ||
This is an infobox used on articles about an in-game character. | This is an infobox used on articles about an in-game character. | ||
==Usage== | ==Usage== | ||
{{Infobox character | {{Infobox character | ||
| name = name | |name=name | ||
| | |image=Image.png | ||
| image2 = Image.png | |image2=Image.png | ||
| image3 = Image.png | |image3=Image.png | ||
| image4 = Image.png | |image4=Image.png | ||
| image5 = Image.png | |image5=Image.png | ||
| | |image_name=image1 | ||
| | |image_name2=image2 | ||
| | |image_name3=image3 | ||
| | |image_name4=image4 | ||
| | |image_name5=image5 | ||
| nickname = nickname | |nickname=nickname | ||
| sex = sex | |sex=sex | ||
| personality = personality | |personality=personality | ||
| occupation = occupation | |occupation=occupation | ||
| traits = traits | |traits=traits | ||
| location = location | |location=location | ||
| coordinates = coordinates | |coordinates=coordinates | ||
<!-- ITEMS --> | <!-- ITEMS --> | ||
| items = items | |items=items | ||
}} | }} | ||
<syntaxhighlight lang=text>{{Infobox character | <syntaxhighlight lang=text>{{Infobox character | ||
| name = | |name= | ||
| | |image= | ||
| image2 = | |image2= | ||
| image3 = | |image3= | ||
| image4 = | |image4= | ||
| image5 = | |image5= | ||
| | |image_name= | ||
| | |image_name2= | ||
| | |image_name3= | ||
| | |image_name4= | ||
| | |image_name5= | ||
<!-- GENERAL --> | <!-- GENERAL --> | ||
| nickname = | |nickname= | ||
| sex = | |sex= | ||
| personality = | |personality= | ||
| occupation = | |occupation= | ||
| traits = | |traits= | ||
| location = | |location= | ||
| coordinates = | |coordinates= | ||
<!-- ITEMS --> | <!-- ITEMS --> | ||
| items = | |items= | ||
}}</syntaxhighlight> | }}</syntaxhighlight> | ||
{{ | {{Clear}} | ||
==Example== | ==Example== | ||
{{Infobox character | {{Infobox character | ||
| name = Kate Smith | |name=Kate Smith | ||
| | |image=805 max.jpg | ||
| | |image2=Kate.png | ||
| | |image3=Kate Smith.png | ||
| | |image4=K&B intro.png | ||
| sex = Female | |image_name=Concept art | ||
| personality = Friendly | |image_name2=Outfit | ||
| location = Kate | |image_name3=In-game (past) | ||
| coordinates = 10746x9415 | |image_name4=In-game (future) | ||
| items = Crutches, Bandages, Painkillers, Pillow | |sex=Female | ||
|personality=Friendly | |||
|location=Bob and Kate's safehouse | |||
|coordinates=10746x9415 | |||
|items=Crutches, Bandages, Painkillers, Pillow | |||
}} | }} | ||
<syntaxhighlight lang=text>{{Infobox character | <syntaxhighlight lang=text>{{Infobox character | ||
| name = Kate Smith | |name=Kate Smith | ||
| | |image=805 max.jpg | ||
| | |image3=Kate Smith.png | ||
| | |image4=K&B intro.png | ||
| | |image_name=Concept art | ||
|image_name2=Outfit | |||
| sex = Female | |image_name3=In-game (past) | ||
| personality = Friendly | |image_name4=In-game (future) | ||
| location = Kate | |sex=Female | ||
| coordinates = 10746x9415 | |personality=Friendly | ||
|location=Bob and Kate's safehouse | |||
| items = Crutches, Bandages, Painkillers, Pillow | |coordinates=10746x9415 | ||
|items=Crutches, Bandages, Painkillers, Pillow | |||
}}</syntaxhighlight> | }}</syntaxhighlight> | ||
{{ | {{Clear}} | ||
{{Translation guide|<syntaxhighlight lang="html"> | {{Translation guide|<syntaxhighlight lang="html"> | ||
Line 97: | Line 102: | ||
{{ll|Category:Infobox}} | {{ll|Category:Infobox}} | ||
</noinclude><includeonly>{{Infobox/sandbox | </noinclude><includeonly>{{Infobox/sandbox | ||
| title = {{{name|{{#getdisplaytitle:{{FULLPAGENAME}}}}}}} | |||
| color = var(--color-red) | |||
| {{Infobox/image <!-- ## Image --> | |||
| p1 = {{#if:{{{image|}}}|[[File:{{{image}}}|{{{image_size|}}}|{{{image_name|{{{name|}}}}}}]]}} | |||
| 1 = {{#if:{{{image2|}}}|[[File:{{{icon|{{{image}}}}}}|{{{icon_name|{{{image_name|{{{name|}}}}}}}}}|link=]]}} | |||
| p2 = {{#if:{{{image2|}}}|[[File:{{{image2}}}|{{{image_size2|}}}|{{{image_name2|{{{name|}}}}}}]]}} | |||
| 2 = {{#if:{{{image2|}}}|[[File:{{{icon2|{{{image2}}}}}}|{{{icon_name2|{{{image_name2|{{{name|}}}}}}}}}|link=]]}} | |||
| p3 = {{#if:{{{image3|}}}|[[File:{{{image3}}}|{{{image_size3|}}}|{{{image_name3|{{{name|}}}}}}]]}} | |||
| 3 = {{#if:{{{image3|}}}|[[File:{{{icon3|{{{image3}}}}}}|{{{icon_name3|{{{image_name3|{{{name|}}}}}}}}}|link=]]}} | |||
| p4 = {{#if:{{{image4|}}}|[[File:{{{image4}}}|{{{image_size4|}}}|{{{image_name4|{{{name|}}}}}}]]}} | |||
| 4 = {{#if:{{{image4|}}}|[[File:{{{icon4|{{{image4}}}}}}|{{{icon_name4|{{{image_name4|{{{name|}}}}}}}}}|link=]]}} | |||
| p5 = {{#if:{{{image5|}}}|[[File:{{{image5}}}|{{{image_size5|}}}|{{{image_name5|{{{name|}}}}}}]]}} | |||
| 5 = {{#if:{{{image5|}}}|[[File:{{{icon5|{{{image5}}}}}}|{{{icon_name5|{{{image_name5|{{{name|}}}}}}}}}|link=]]}} | |||
| caption = {{#if: {{{image_caption|}}}|''{{{image_caption|}}}''}} | |||
}}{{#if:{{{nickname|}}}{{{sex|}}}{{{personality|}}}{{{occupation|}}}{{{traits|}}}{{{location|}}} | |||
| {{Infobox/section <!-- ## General ## --> | |||
| {{tt|name=Infobox character|default=General|arg1=general}} | |||
| color = var(--color-red) | |||
| id = character-general | |||
| {{#if:{{{nickname|}}} | |||
|{{Infobox/sandbox/row | |||
|{{tt|name=Infobox character|default=Nickname|arg1=nickname}} | |||
|{{{nickname|}}} | |||
}} | |||
}}}} | }}{{#if:{{{sex|}}} | ||
|{{Infobox/sandbox/row | |||
|{{tt|name=Infobox character|default=Sex|arg1=sex}} | |||
|{{{sex|}}} | |||
}} | |||
}}{{#if:{{{personality|}}} | |||
}}}} | |{{Infobox/sandbox/row | ||
|{{tt|name=Infobox character|default=Personality|arg1=personality}} | |||
|{{{personality|}}} | |||
}} | |||
}}{{#if:{{{occupation|}}} | |||
|{{Infobox/sandbox/row | |||
}}}} | |{{tt|name=Infobox character|default=Occupation|arg1=occupation}} | ||
|{{{occupation|}}} | |||
}} | |||
}}{{#if:{{{traits|}}} | |||
|{{Infobox/sandbox/row | |||
|{{tt|name=Infobox character|default=Traits|arg1=traits}} | |||
}}}} | |{{{traits|}}} | ||
}} | |||
}}{{#if:{{{location|}}} | |||
|{{Infobox/sandbox/row | |||
|{{tt|name=Infobox character|default=Location|arg1=location}} | |||
|{{{location|}}}<br>{{#if:{{{coordinates|}}}|[[File:Geographylogo.png{{!}}26px{{!}}link=https://map.projectzomboid.com/?#{{{coordinates}}}{{!}}Show location on an interactive map.]]<span class="plainlinks" title="Show location on an interactive map.">[https://map.projectzomboid.com/?#{{{coordinates}}} {{{coordinates}}}]</span>}} | |||
}}}} | }} | ||
}} | |||
}} | |||
}}{{#if:{{{items|}}} | |||
|{{Infobox/section <!-- ## Items ## --> | |||
| {{tt|name=Infobox character|default=Items|arg1=items}} | |||
}}}} | | color = var(--color-red) | ||
| id = character-items | |||
| <div style{{=}}"padding:0em 0.5em 0.5em;">{{{items|}}}</div> | |||
}} | |||
}} | |||
}}</includeonly> | }}</includeonly> |
Latest revision as of 14:09, 14 April 2024
This is an infobox used on articles about an in-game character.
Usage
{{Infobox character
|name=
|image=
|image2=
|image3=
|image4=
|image5=
|image_name=
|image_name2=
|image_name3=
|image_name4=
|image_name5=
<!-- GENERAL -->
|nickname=
|sex=
|personality=
|occupation=
|traits=
|location=
|coordinates=
<!-- ITEMS -->
|items=
}}
Example
{{Infobox character
|name=Kate Smith
|image=805 max.jpg
|image3=Kate Smith.png
|image4=K&B intro.png
|image_name=Concept art
|image_name2=Outfit
|image_name3=In-game (past)
|image_name4=In-game (future)
|sex=Female
|personality=Friendly
|location=Bob and Kate's safehouse
|coordinates=10746x9415
|items=Crutches, Bandages, Painkillers, Pillow
}}
How to translate
This template is translatable.
Template code
Paste the following code into the <includeonly>
tag of the translated template and translate the text after each =
sign (except for #default =
).
{{#switch: {{{1|}}}
<!-- section -->
| general = General
| items = Items
<!-- data -->
| nickname = Nickname
| sex = Sex
| personality = Personality
| occupation = Occupation
| traits = Traits
| location = Location
| #default = [[Category:Incorrect template usage]]
}}
Template documentation
Copy the code wrapped in the <noinclude>
tag in this template and translate the text after doc =
in the {{Documentation}}
template.
{{Translation guide}}
template should be removed from the translated documentation.