Template:NpcInfoBox: Difference between revisions
From Ymirheim Wiki
No edit summary |
(Marked this version for translation) |
||
Line 6: | Line 6: | ||
{{#if:{{{image|}}}|<div class="npc-info-image">[[File:{{{image|}}}|280px]]</div>|}} | {{#if:{{{image|}}}|<div class="npc-info-image">[[File:{{{image|}}}|280px]]</div>|}} | ||
<table class="npc-info-table"> | <table class="npc-info-table"> | ||
<th scope="row"><translate nowrap>Type</translate></th> | <th scope="row"><translate nowrap><!--T:1--> Type</translate></th> | ||
<td>{{#yh_data:npc_types|{{#yh_data:npc_prototypes|{{{1}}}|Type}}|Type}}</td> | <td>{{#yh_data:npc_types|{{#yh_data:npc_prototypes|{{{1}}}|Type}}|Type}}</td> | ||
</tr> | </tr> | ||
<tr> | <tr> | ||
<th scope="row"><translate nowrap>Race</translate></th> | <th scope="row"><translate nowrap><!--T:2--> Race</translate></th> | ||
<td>{{#yh_data:npc_races|{{#yh_data:npc_prototypes|{{{1}}}|Race}}|Race}}</td> | <td>{{#yh_data:npc_races|{{#yh_data:npc_prototypes|{{{1}}}|Race}}|Race}}</td> | ||
</tr> | </tr> | ||
<tr> | <tr> | ||
<th scope="row"><translate nowrap>Size</translate></th> | <th scope="row"><translate nowrap><!--T:3--> Size</translate></th> | ||
<td>{{#yh_data:body_sizes|{{#yh_data:npc_prototypes|{{{1}}}|Size}}|Size}}</td> | <td>{{#yh_data:body_sizes|{{#yh_data:npc_prototypes|{{{1}}}|Size}}|Size}}</td> | ||
</tr> | </tr> | ||
{{#if:{{{zone|}}}{{{location|}}}{{{coordinates|}}}| | {{#if:{{{zone|}}}{{{location|}}}{{{coordinates|}}}| | ||
<tr> | <tr> | ||
<th scope="row"><translate nowrap>Location</translate></th> | <th scope="row"><translate nowrap><!--T:4--> Location</translate></th> | ||
<td><!-- | <td><!-- | ||
Line 29: | Line 29: | ||
</tr> | </tr> | ||
|}} | |}} | ||
{{#if:{{{occupation|}}}|<tr><th scope="row"><translate nowrap>Occupation</translate></th><td>{{{occupation|}}}</td></tr>|}} | {{#if:{{{occupation|}}}|<tr><th scope="row"><translate nowrap><!--T:5--> Occupation</translate></th><td>{{{occupation|}}}</td></tr>|}} | ||
</table> | </table> | ||
</div> | </div> |
Revision as of 17:26, 7 July 2024
This template can be used to display an information box about a specific NPC on a page.
Usage
{{NpcInfoBox|NPC_ID}}
{{NpcInfoBox|NPC_ID|image=IMAGE_LINK}}
You have to supply the specific NPC ID, not the NPC name.
You can find the NPC ID by searching the NPC prototype in Ymirheim Translate (npc_prototypes component).
The NPC ID is contained in the string key. There can be multiple NPCs with the same name, those are variations. Please pick the first one.
For example, if you look up "Poporing" in Ymirheim Translate, you will see the NPC ID in the "Key" column (the portion before the forward slash).
Examples
{{NpcInfoBox | 1001 | image = Natali Klaret.png | zone = Hoddmimis | location = Magic Shop | coordinates = D5 | occupation = Magic Shop Keeper }}