跳转到内容

模板:CharacterBox:修订间差异

来自槌基百科
Fix: use {{!}} instead of | for table pipes inside #if blocks
Rewrite: use Lua module via #invoke for clean conditional rows
 
第1行: 第1行:
<noinclude>
<noinclude>
人物信息框模板。在角色词条页面顶部使用。
人物信息框模板。在角色词条页面顶部使用。所有参数均为可选,留空的行不显示。


用法示例:
用法示例:
<pre>
<pre>
{{CharacterBox
{{CharacterBox
| name       = 唐浩
| name       = 唐浩
| image     = 唐浩.jpg
| image       = 唐浩.jpg
| aliases   = 张寒、魂天帝
| aliases     = 张寒、魂天帝
| location   = 不定
| location   = 不定
| faction   = 万兽门
| faction     = 万兽门
| identity   = 客卿
| identity   = 客卿
| age       = 34岁
| age         = 34岁
| race       = 人族
| race       = 人族
| cultivation= 半步元婴
| cultivation = 半步元婴
| skills     = 灵血神通
| aptitude    = 中品无属性灵根
| skills     = 灵血神通
}}
}}
</pre>
</pre>
第92行: 第93行:
}
}
</templatedata>
</templatedata>
</noinclude><includeonly>{| class="infobox biography vcard"
</noinclude><includeonly>{{#invoke:Infobox|character}}</includeonly>
|+ '''{{#if:{{{name|}}}|{{{name}}}|{{PAGENAME}}}}'''
{{#if:{{{image|}}}|
|-
! colspan="2" style="text-align:center;" {{!}} [[File:{{{image}}}|200px]]}}
{{#if:{{{aliases|}}}|
|-
! 别称
{{!}} {{{aliases|}}}}}
{{#if:{{{location|}}}|
|-
! 所处地
{{!}} {{{location|}}}}}
{{#if:{{{faction|}}}|
|-
! 所属势力
{{!}} {{{faction|}}}}}
{{#if:{{{identity|}}}|
|-
! 身份
{{!}} {{{identity|}}}}}
{{#if:{{{position|}}}|
|-
! 职位
{{!}} {{{position|}}}}}
{{#if:{{{age|}}}|
|-
! 年龄
{{!}} {{{age|}}}}}
{{#if:{{{race|}}}|
|-
! 种族
{{!}} {{{race|}}}}}
{{#if:{{{cultivation|}}}|
|-
! 修为
{{!}} {{{cultivation|}}}}}
{{#if:{{{aptitude|}}}|
|-
! 资质
{{!}} {{{aptitude|}}}}}
{{#if:{{{skills|}}}|
|-
! 技能
{{!}} {{{skills|}}}}}
|}</includeonly>

2026年3月12日 (四) 11:49的最新版本

人物信息框模板。在角色词条页面顶部使用。所有参数均为可选,留空的行不显示。

用法示例:

{{CharacterBox
| name        = 唐浩
| image       = 唐浩.jpg
| aliases     = 张寒、魂天帝
| location    = 不定
| faction     = 万兽门
| identity    = 客卿
| age         = 34岁
| race        = 人族
| cultivation = 半步元婴
| aptitude    = 中品无属性灵根
| skills      = 灵血神通
}}

角色/人物信息卡片

模板参数[编辑模板数据]

参数描述类型状态
名称name

角色名称,留空则自动使用页面标题

字符串推荐
图片image

图片文件名,例如:唐浩.jpg

文件推荐
别称aliases

其他名字或绰号

字符串可选
所处地location

角色所在的地点或区域

字符串推荐
所属势力faction

门派、家族或阵营

字符串推荐
身份identity

职务、称号或身份

字符串推荐
职位position

具体职位或官职

字符串可选
年龄age

角色年龄

字符串可选
种族race

人族、妖族、异火等

字符串推荐
修为cultivation

修炼境界,例如:金丹期、元婴期

字符串可选
资质aptitude

灵根资质

字符串可选
技能skills

主要技能、神通或法宝

字符串可选