Template:MoveTooltip-MBTL: Difference between revisions

From Mizuumi Wiki
Jump to navigation Jump to search
No edit summary
(Added aoko.)
 
(14 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<!--     // If there are 2 unnamed arguments, then set 'character' to the first argument and 'moveInput' to the second argument
<includeonly><!--
// If there are 2 unnamed arguments, then set 'character' to the first argument and 'moveInput' to the second argument
-->{{#if:{{{2|}}}|<!--
-->{{#if:{{{2|}}}|<!--
---->{{#vardefine:character|{{{1}}}}}<!--
-->{{#vardefine:character|{{{1}}}}}<!--
---->{{#vardefine:moveInput|{{{2}}}}}<!--
-->{{#vardefine:moveInput|{{{2}}}}}<!--
          // Else If there is only 1 unnamed argument, assume that the 'character' is the subpage and the 'moveInput' is the first argument
// Else If there is only 1 unnamed argument, assume that the 'character' is the subpage and the 'moveInput' is the first argument
---->|{{#if:{{{1|}}}|<!--
-->|{{#if:{{{1|}}}|<!--
-------->{{#vardefine:character|{{SUBPAGENAME}}}}<!--
-->{{#vardefine:character|{{SUBPAGENAME}}}}<!--
-------->{{#vardefine:moveInput|{{{1}}}}}<!--
-->{{#vardefine:moveInput|{{{1}}}}}<!--
---->}}<!--
-->}}<!--
-->}}<!--
-->}}<!--
          // If at least 1 unnamed parameter exists, make the tooltip.
-->{{safesubst:#switch: {{lc:{{#var:character}}}}
-->{{#if:{{{1|}}}{{{2|}}}|<!--
| tohno
--><span class="ajaxttlink"><span>[[Melty Blood/MBTL/{{#var:character}}#id-{{#replace:{{#replace:<!--
| shiki tohno
            // AttackDataCargo-MBTL has an anchor set for the moveId
| shiki = {{#vardefine:pageName|Shiki Tohno}}{{#vardefine:iconName|tohno}}
            // Cargo Query to get moveId
| arcueid
        -->{{#cargo_query:tables=MBTL_MoveData|fields=MBTL_MoveData.moveId|where=chara='Ciel' AND input='5A'}}<!--
| arcueid brunestud
-->|[|.5B}}|]|.5D}}|<span class="ttlink">{{{text|{{#var:moveInput}}}}}</span>]]</span></span>|<!--
| arc = {{#vardefine:pageName|Arcueid Brunestud}}{{#vardefine:iconName|arcueid}}
          // Otherwise, show this error and add the below tracking category
| akiha tohno
-->'''Invalid Move Tooltip'''<includeonly>[[Category:Pages with invalid move tooltips]]</includeonly><!--
| akiha = {{#vardefine:pageName|Akiha Tohno}}{{#vardefine:iconName|akiha}}
-->}}
| ciel = {{#vardefine:pageName|Ciel}}{{#vardefine:iconName|ciel}}
| hisui = {{#vardefine:pageName|Hisui}}{{#vardefine:iconName|hisui}}
| kohaku = {{#vardefine:pageName|Kohaku}}{{#vardefine:iconName|kohaku}}
| hisui & kohaku
| maids = {{#vardefine:pageName|Hisui & Kohaku}}{{#vardefine:iconName|maids}}
| miyako arima
| miyako = {{#vardefine:pageName|Miyako Arima}}{{#vardefine:iconName|miyako}}
| kouma kishima
| kouma = {{#vardefine:pageName|Kouma Kishima}}{{#vardefine:iconName|kouma}}
| noel = {{#vardefine:pageName|Noel}}{{#vardefine:iconName|noel}}
| michael roa valdamjong
| roa = {{#vardefine:pageName|Michael Roa Valdamjong}}{{#vardefine:iconName|roa}}
| vlov arkhangel
| vlov = {{#vardefine:pageName|Vlov Arkhangel}}{{#vardefine:iconName|vlov}}
| red arcueid
| warc = {{#vardefine:pageName|Red Arcueid}}{{#vardefine:iconName|warc}}
| saber = {{#vardefine:pageName|Saber}}{{#vardefine:iconName|saber}}
| aoko
| aoko aozaki = {{#vardefine:pageName|Aoko Aozaki}}{{#vardefine:iconName|aoko}}
| mario = {{#vardefine:pageName|Mario}}{{#vardefine:iconName|mario}}
}}<!--
 
// AttackDataCargo-MBTL has an anchor set for the moveId
// Cargo Query to get moveId
-->{{#vardefine:moveId|{{#cargo_query:tables=MBTL_MoveData|fields=MBTL_MoveData.moveId|where=chara='{{#var:pageName}}' AND input='{{#var:moveInput}}'|no html}}}}<!--
 
// If at least 1 unnamed parameter exists, make the tooltip.
-->{{#if:{{{1|}}}{{{2|}}}<!--
-->|<span class="tt-move"><!--
--><span>[[File:MBTL_{{lc:{{#var:iconName}}}}_icon.png|20x20px|top|link=Melty_Blood/MBTL/{{#var:pageName}}#id-{{#var:moveId}}]]</span><!--
--><span class="tt-move-link"><!--
-->[[Melty_Blood/MBTL/{{#var:pageName}}#id-{{#var:moveId}}|{{{text|{{#var:moveInput}}}}}]]<!--
--></span><!--
--><span class="tt-move-data" style="display:none;"><!--
-->[[Melty_Blood/MBTL/{{#var:pageName}}/Data#{{#var:moveInput}}]]<!--
--></span><!--
--></span><!--
// Otherwise, show this error and add the below tracking category
-->|'''Invalid Move Tooltip'''[[Category:Pages with invalid move tooltips]]<!--
-->}}</includeonly><noinclude>
{{doc}}
[[Category:Melty Blood: Type Lumina]]
[[Category:Templates]]
</noinclude>

Latest revision as of 19:18, 5 March 2023

Template DocumentationEdit This Documentation
Create a hover-over tooltip for text to show a character's move using Cargo. (This is semi-experimental)

This may not work properly for Maids or Vlov pages as they are using Tabber.

Arguments

|first unnamed argument=
Character Subpage Name
|second unnamed argument=
Move header on character overview page
|text=
Text that you can hover over to show the tooltip. (Default: second unnamed argument)

Example

Without custom text

{{MoveTooltip-MBTL|miyako|5A}}

MBTL miyako icon.png5A

With custom text

{{MoveTooltip-MBTL|shiki|5A|text=Shiki 5A}}
{{MoveTooltip-MBTL|arc|5A|text=Arc 5A}}
{{MoveTooltip-MBTL|akiha|5A|text=Akiha Akiha 5A}}
{{MoveTooltip-MBTL|ciel|5A|text=Ciel 5A}}
{{MoveTooltip-MBTL|hisui|5A|text=Hisui 5A}}
{{MoveTooltip-MBTL|kohaku|5A|text=Kohaku 5A}}
{{MoveTooltip-MBTL|maids|H5A|text=Maids H5A}}
{{MoveTooltip-MBTL|miyako|5A|text=Miyako 5A}}
{{MoveTooltip-MBTL|kouma|5A|text=Kouma 5A}}
{{MoveTooltip-MBTL|noel|5A|text=Noel 5A}}
{{MoveTooltip-MBTL|roa|5A|text=Roa 5A}}
{{MoveTooltip-MBTL|vlov|5A|text=Vlov 5A}}
{{MoveTooltip-MBTL|warc|5A|text=Warc 5A}}
{{MoveTooltip-MBTL|saber|5A|text=Saber 5A}}

MBTL tohno icon.pngShiki 5A
MBTL arcueid icon.pngArc 5A
MBTL akiha icon.pngAkiha Akiha 5A
MBTL ciel icon.pngCiel 5A
MBTL hisui icon.pngHisui 5A
MBTL kohaku icon.pngKohaku 5A
MBTL maids icon.pngMaids H5A
MBTL miyako icon.pngMiyako 5A
MBTL kouma icon.pngKouma 5A
MBTL noel icon.pngNoel 5A
MBTL roa icon.pngRoa 5A
MBTL vlov icon.pngVlov 5A
MBTL warc icon.pngWarc 5A

MBTL saber icon.pngSaber 5A

This documentation is automatically transcluded from Template:MoveTooltip-MBTL/Documentation and is not included when this page is transcluded.