Template:NPCDisplay: Difference between revisions
Jump to navigation
Jump to search
m (Made every name a hotlink) |
m (Added additional margin rules to make the tables not glue together when stacked on top of one another) |
||
Line 23: | Line 23: | ||
| The filename pointing to the third image. Not required. | | The filename pointing to the third image. Not required. | ||
|} | |} | ||
{{NPCDisplay | |||
| name = Ann | |||
| image1 = NPC Ann 01 Icon.png | |||
| image2 = NPC Ann 02 Icon.png | |||
| image3 = NPC Ann 03 Icon.png | |||
}} | |||
{{NPCDisplay | |||
| name = Ann | |||
| image1 = NPC Ann 01 Icon.png | |||
| image2 = NPC Ann 02 Icon.png | |||
| image3 = NPC Ann 03 Icon.png | |||
}} | |||
[[Category:Templates]] | [[Category:Templates]] | ||
Line 36: | Line 50: | ||
// If 3 images provided. // | // If 3 images provided. // | ||
-->{{#ifeq:{{#var:num_images}} | 3 | <table class="wikitable" style="margin:auto;"> | -->{{#ifeq:{{#var:num_images}} | 3 | <table class="wikitable" style="margin:auto;margin-top:0.5em;margin-bottom:0.5em;"> | ||
<tr><th colspan="3"><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | <tr><th colspan="3"><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | ||
<tr> | <tr> | ||
Line 49: | Line 63: | ||
| {{#if:{{{image1|}}} | | {{#if:{{{image1|}}} | ||
| {{#if:{{{image2|}}} | | {{#if:{{{image2|}}} | ||
| <!-- IMAGE 1 + 2 --><table class="wikitable" style="margin:auto;"> | | <!-- IMAGE 1 + 2 --><table class="wikitable" style="margin:auto;margin-top:0.5em;margin-bottom:0.5em;"> | ||
<tr><th colspan="2"><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | <tr><th colspan="2"><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | ||
<tr> | <tr> | ||
Line 55: | Line 69: | ||
<td>[[File:{{{image2}}}|frameless|center]]</td> | <td>[[File:{{{image2}}}|frameless|center]]</td> | ||
</tr></table> | </tr></table> | ||
| <!-- IMAGE 1 + 3 --><table class="wikitable" style="margin:auto;"> | | <!-- IMAGE 1 + 3 --><table class="wikitable" style="margin:auto;margin-top:0.5em;margin-bottom:0.5em;"> | ||
<tr><th colspan="2"><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | <tr><th colspan="2"><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | ||
<tr> | <tr> | ||
Line 62: | Line 76: | ||
</tr></table> | </tr></table> | ||
}} | }} | ||
| <!-- IMAGE 2 + 3 --><table class="wikitable" style="margin:auto;"> | | <!-- IMAGE 2 + 3 --><table class="wikitable" style="margin:auto;margin-top:0.5em;margin-bottom:0.5em;"> | ||
<tr><th colspan="2"><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | <tr><th colspan="2"><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | ||
<tr> | <tr> | ||
Line 74: | Line 88: | ||
-->{{#ifeq:{{#var:num_images}} | 1 | -->{{#ifeq:{{#var:num_images}} | 1 | ||
| {{#if:{{{image1|}}} | | {{#if:{{{image1|}}} | ||
| <!-- IMAGE 1 ONLY --><table class="wikitable" style="margin:auto;"> | | <!-- IMAGE 1 ONLY --><table class="wikitable" style="margin:auto;margin-top:0.5em;margin-bottom:0.5em;"> | ||
<tr><th><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | <tr><th><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | ||
<tr> | <tr> | ||
Line 80: | Line 94: | ||
</tr></table> | </tr></table> | ||
| {{#if:{{{image2|}}} | | {{#if:{{{image2|}}} | ||
| <!-- IMAGE 2 ONLY --><table class="wikitable" style="margin:auto;"> | | <!-- IMAGE 2 ONLY --><table class="wikitable" style="margin:auto;margin-top:0.5em;margin-bottom:0.5em;"> | ||
<tr><th><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | <tr><th><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | ||
<tr> | <tr> | ||
<td>[[File:{{{image2}}}|frameless|center]]</td> | <td>[[File:{{{image2}}}|frameless|center]]</td> | ||
</tr></table> | </tr></table> | ||
| <!-- IMAGE 3 ONLY --><table class="wikitable" style="margin:auto;"> | | <!-- IMAGE 3 ONLY --><table class="wikitable" style="margin:auto;margin-top:0.5em;margin-bottom:0.5em;"> | ||
<tr><th><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | <tr><th><span style="font-size:24px;">[[{{{name}}}]]</span></th></tr> | ||
<tr> | <tr> |
Revision as of 21:45, 22 November 2023
This template is used for the NPC displays on the main page. It comes in 1, 2, and 3 image variants.
Parameters
Parameter Name | Parameter Type | Function |
---|---|---|
name
|
String | The name of the NPC. Converts to a link. |
image1
|
Filename | The filename pointing to the first image. |
image2
|
Filename | The filename pointing to the second image. Not required. |
image3
|
Filename | The filename pointing to the third image. Not required. |
Ann | ||
---|---|---|
Ann | ||
---|---|---|