Template:DropsLine: Difference between revisions

m
janky support for quantity ranges in value column, lua would be better
(Undo revision 16533 by Melmelcom (talk) This is for frequency of how often the drop is obtained, not for the rarity of equipment.)
Tag: Undo
m (janky support for quantity ranges in value column, lua would be better)
Line 11:
|#default = <td data-sort-value="65536" class="table-bg-grey"><span>Unknown</span></td>
}}
<td>{{#vardefine:value|{{#ifeq:{{{name}}}|Coins|12|{{#ask:[[{{{name}}}]]|?Value=|mainlabel=-}}}}}}{{#if:{{#var:value}}|{{#if:{{{quantity|}}}|{{#ifeq:{{#rpos:{{{quantity}}}|-}}|-1|{{Currency|{{#expr:{{#var:value}}*{{{quantity}}}}}}}|{{formatnum:{{#expr:{{#var:value}}*{{#explode:{{{quantity}}}|-|0}}}}}}–{{formatnum:{{#expr:{{#var:value}}*{{#explode:{{{quantity}}}|-|1}}}}}}}}|{{Currency|{{#var:value}}}}}}|Unknown}}</td>
</tr>{{#subobject:DROP_{{{name}}}_{{#if:{{{rarity|}}}|{{{rarity}}}|Unknown}}|Dropped from={{FULLPAGENAME}}|Dropped item={{{name}}}|Dropped quantity={{#if:{{{quantity|}}}|{{{quantity}}}|Unknown}}|Rarity={{#if:{{{frequency|}}}|{{{frequency}}}|Unknown}}}}</includeonly><noinclude>{{/doc}}</noinclude>
172

edits