From Dark and Darker Wiki

m (Testing page layout)
m (Changing Template to use calls that work with Weapon Data.)
Line 1: Line 1:
<includeonly>{{#vardefine:active}}<!--
<!--
 
NOTE TO FUTURE EDITORS:
This template makes the assumption that Artifacts only exist for weapons. If this is not the case, the template will need to be updated to account for that.
 
--><includeonly>{{#vardefine:active}}<!--
Rarity flags for whether or not the item has a drop table for that rarity.
Rarity flags for whether or not the item has a drop table for that rarity.
-->{{#vardefine:Poor|<!--
-->{{#vardefine:Poor|<!--
Line 32: Line 37:
-->||{{#vardefine:active|Legendary}} }} }} }}<!--
-->||{{#vardefine:active|Legendary}} }} }} }}<!--
-->{{#vardefine:Unique|<!--
-->{{#vardefine:Unique|<!--
If the item has a unique variant check the DropTable for it. Else check the DropTable for the item itself.
If the item has a unique weapon variant check the DropTable for it. Else check the DropTable for the item itself.
-->{{#ifexist:DropTable:{{#if:{{Item Data|Weapon|{{{1|{{PAGENAME}}}}}|artifactname}}|{{Item Data|Weapon|{{{1|{{PAGENAME}}}}}|artifactname}} 7|{{{1|{{PAGENAME}}}}} 7}}<!--
-->{{#ifexist:DropTable:{{#if:{{Weapon Data|{{{1|{{PAGENAME}}}}}|artifactname}}|{{Weapon Data|{{{1|{{PAGENAME}}}}}|artifactname}} 7|{{{1|{{PAGENAME}}}}} 7}}<!--
-->|1<!--
-->|1<!--
-->{{#if:{{#var:active}}<!--
-->{{#if:{{#var:active}}<!--
Line 78: Line 83:
-->|<div class="Unique-data"style="width:50%;{{#ifeq:Unique|{{#var:active}}|| display:none;}}"><!--
-->|<div class="Unique-data"style="width:50%;{{#ifeq:Unique|{{#var:active}}|| display:none;}}"><!--
If the item has a artifact variant display the DropTable for it. Else display the DropTable for the item itself.
If the item has a artifact variant display the DropTable for it. Else display the DropTable for the item itself.
-->{{:DropTable:{{#if:{{Item Data|Weapon|{{{1|{{PAGENAME}}}}}|artifactname}}<!--
-->{{:DropTable:{{#if:{{Weapon Data|{{{1|{{PAGENAME}}}}}|artifactname}}<!--
-->|{{Item Data|Weapon|{{{1|{{PAGENAME}}}}}|artifactname}}<!--
-->|{{Weapon Data|{{{1|{{PAGENAME}}}}}|artifactname}}<!--
-->|{{{1|{{PAGENAME}}}}}}}<!--
-->|{{{1|{{PAGENAME}}}}}}}<!--
--> 7}}</div>}}</span>}}<!--
--> 7}}</div>}}</span>}}<!--
Line 90: Line 95:


==Example 1==
==Example 1==
<pre>{{GenerateDropTables|Arming Sword}}</pre>
<pre>{{GenerateDropTables|Longbow}}</pre>


{{GenerateDropTables|Arming Sword}}
{{GenerateDropTables|Longbow}}


==Example 2==
==Example 2==

Revision as of 01:25, 19 March 2024

Generate Drop Tables

Intended usage for individual pages:

{{GenerateDropTables}}

default value for item is -PAGENAME-, therefore the above code is same as

{{GenerateDropTables|{{PAGENAME}} }}

Example 1

{{GenerateDropTables|Longbow}}

Dropped By


Loot/Drop tables last updated for Patch:6.6#Hotfix 69-2$green


Common
Uncommon
Rare
Epic
Legendary

Example 2

{{GenerateDropTables|Armet}}

Dropped By


Loot/Drop tables last updated for Patch:6.6#Hotfix 69-2$green


Poor
Common
Uncommon
Rare
Epic
Legendary
Unique
Drop Source Table at 0 Luck
NameSorted by Total Expected Value (TEV) in Descending Order
TEV = Sum of all (Count * Probability)
TypeCountProbability
Containers10.3205%

Example 3

Only displays the rarity it can drop

{{GenerateDropTables|Bone}}

Dropped By


Loot/Drop tables last updated for Patch:6.6#Hotfix 69-2$green


Common
Drop Source Table at 0 Luck
NameSorted by Total Expected Value (TEV) in Descending Order
TEV = Sum of all (Count * Probability)
TypeCountProbability
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%
Monster16.6667%

Example 4

Doesn't display anything if there are no drops

{{GenerateDropTables|Potion of Luck}}