Template:ThievingTarget: Difference between revisions

From Melvor Idle
(Max hit added)
(Change to Lua powered template)
Line 1: Line 1:
{| class="wikitable" style="float:right; clear:right;"
Usage: {{T|ThievingTarget|name=<NPC_Name>}}. If the '''name''' parameter is omitted, the page name is used instead.
 
For example, {{T|ThievingTarget|Chef}} returns:
{{ThievingTarget|name=Chef}}
 
<onlyinclude><includeonly>
{{#vardefine:npc|{{{name|{{PAGENAME}}}}}}}
<!-- Manual override below for Goblin -->
{{#ifeq:{{#var:npc}}|Golbin (thieving)|{{#vardefine:npc|Golbin}}}}
 
{{#vardefine:itemDrops|{{#invoke:Skills|getThievingNPCStat|{{#var:npc}}|lootTable}}}}
{{#vardefine:itemDropsText|{{#ifeq:{{#var:itemDrops}}|||75% chance for:<br/>{{#var:itemDrops}}<br/>}}}}
 
<!-- Generate the box -->
{| class="wikitable" style="float:right; clear:right; max-width:250px; margin-left:10px"
|-  
|-  
! {{{name}}}
! {{#var:npc}}
|-
|-
| [[File:{{{name}}}_(thieving).svg|250px]]
| {{#invoke:Icons|Icon|{{#var:npc}}|type=thieving|size=250|notext=true}}
|-
|-
| Level {{{level}}} [[File:Thieving (skill).svg|25px]][[Thieving]]
| '''Requirement:''' {{#invoke:Skills|getThievingNPCStat|{{#var:npc}}|requirements}}
|-
|-
| Max Hit: {{{maxHit}}}
| '''Max Hit:''' {{#invoke:Skills|getThievingNPCStat|{{#var:npc}}|maxHit}}
|-
|-
| {{{xp}}} xp
| '''Experience:''' {{#invoke:Skills|getThievingNPCStat|{{#var:npc}}|xp}} XP
|-
|-
| Drops:
| '''Drops:'''
{{{drops}}}
* {{GP|1|{{#invoke:Skills|getThievingNPCStat|{{#var:npc}}|maxCoins}}}}
|}
{{#var:itemDropsText}}
0.83% chance for:
* {{ItemIcon|Bobby's Pocket}}
 
0.01% chance for:
* {{ItemIcon|Chapeau Noir}}
|}</includeonly></onlyinclude>

Revision as of 14:57, 11 April 2021

Usage: {{ThievingTarget|name=<NPC_Name>}}. If the name parameter is omitted, the page name is used instead.

For example, {{ThievingTarget|Chef}} returns:




Chef
Error creating thumbnail: File missing
Requirement:
Max Hit: 108
Experience: XP
Drops:
  • 1GP

75% chance for:
table
0.83% chance for:

0.01% chance for: