• Welcome to the Kancolle Wiki!
  • If you have any questions regarding site content, account registration, etc., please visit the KanColle Wiki Discord

Difference between revisions of "Template:Ship/Banner"

From Kancolle Wiki
Jump to navigation Jump to search
Line 1: Line 1:
<includeonly>{{#vardefine:name|{{#ifeq:{{#sub:{{#var:pre_name}}|-1}}|&#32;|{{#sub:{{#var:pre_name}}|0|-1}}|{{#var:pre_name}}}}}}{{#if:{{{1|}}}|<span class="image-stack" style="display:inline-block;overflow:hidden;vertical-align:middle;position:relative;">[[File:Ship Banner {{#var:name}}{{#if:{{{damaged|}}}|&#32;Damaged}}.png|{{#if:{{{small|}}}|160x40px|240x60px}}|link={{{link|{{#var:name}}}}}|{{{caption|{{#var:name}}}}}]]{{#if:{{{ring|}}}|<span class="image-layer" style="line-height:0px;position:absolute;{{#if:{{{small|}}}|top:19px;left:138px;|top:29px;left:210px;}}">[[File:Battle Card Marriage Ring.png|link={{{link|{{#var:name}}}}}|{{{caption|{{#var:name}}}}}]]</span>|}}{{#if:{{{ring_glow|}}}|<span class="image-layer" style="line-height:0px;position:absolute;opacity:0.7;{{#if:{{{small|}}}|top:10px;left:126px;|top:25px;left:206px;}}">[[File:Battle Card Marriage Ring Glow.png|link={{{link|{{#var:name}}}}}|{{{caption|{{#var:name}}}}}]]</span>|}}</span>|[[File:Catbomb.png|{{#if:{{{small|}}}|160x40px|240x60px}}]]}}</includeonly><noinclude>
+
<includeonly>{{#vardefine:pre_name|{{#replace:{{{1}}}|/|&#32;}}}}{{#vardefine:name|{{#ifeq:{{#sub:{{#var:pre_name}}|-1}}|&#32;|{{#sub:{{#var:pre_name}}|0|-1}}|{{#var:pre_name}}}}}}{{#if:{{{1|}}}|<span class="image-stack" style="display:inline-block;overflow:hidden;vertical-align:middle;position:relative;">[[File:Ship Banner {{#var:name}}{{#if:{{{damaged|}}}|&#32;Damaged}}.png|{{#if:{{{small|}}}|160x40px|240x60px}}|link={{{link|{{#var:name}}}}}|{{{caption|{{#var:name}}}}}]]{{#if:{{{ring|}}}|<span class="image-layer" style="line-height:0px;position:absolute;{{#if:{{{small|}}}|top:19px;left:138px;|top:29px;left:210px;}}">[[File:Battle Card Marriage Ring.png|link={{{link|{{#var:name}}}}}|{{{caption|{{#var:name}}}}}]]</span>|}}{{#if:{{{ring_glow|}}}|<span class="image-layer" style="line-height:0px;position:absolute;opacity:0.7;{{#if:{{{small|}}}|top:10px;left:126px;|top:25px;left:206px;}}">[[File:Battle Card Marriage Ring Glow.png|link={{{link|{{#var:name}}}}}|{{{caption|{{#var:name}}}}}]]</span>|}}</span>|[[File:Catbomb.png|{{#if:{{{small|}}}|160x40px|240x60px}}]]}}</includeonly><noinclude>
 
Simplified version of [[Template:ShipBattleCardKai]]. Doesn't use Lua, so it's possible to have (practically) unlimited number of invokes on a page.
 
Simplified version of [[Template:ShipBattleCardKai]]. Doesn't use Lua, so it's possible to have (practically) unlimited number of invokes on a page.
  

Revision as of 21:02, 30 November 2020

Simplified version of Template:ShipBattleCardKai. Doesn't use Lua, so it's possible to have (practically) unlimited number of invokes on a page.

Interface

  • Supported parameters: [1], link, caption, ring, ring_glow, damaged, small (downscale HD card to Phase 1 size).
  • The following parameters can be added: name, model, grayscale, mode.
  • Other layers also can be supported (flagship, etc.).
  • Automatic enemy aircraft layers are not supported.

Examples

{{ShipBattleCardHD|I-401}}

Template:ShipBattleCardHD

{{ShipBattleCardHD|I-401/}}

Template:ShipBattleCardHD

{{ShipBattleCardHD|I-401 Kai}}

Template:ShipBattleCardHD

{{ShipBattleCardHD|I-401/Kai}}

Template:ShipBattleCardHD

{{ShipBattleCardHD|I-401/Kai|damaged=true}}

Template:ShipBattleCardHD

{{ShipBattleCardHD|I-401/Kai|caption=Shioi|ring=true|ring_glow=true}}

Template:ShipBattleCardHD

{{ShipBattleCardHD|I-401/Kai|caption=Shioi|ring=true|ring_glow=true|damaged=true|small=true}}

Template:ShipBattleCardHD