Difference between revisions of "Template:LootList Header"

From 7 Days to Die Wiki
Jump to: navigation, search
 
(15 intermediate revisions by the same user not shown)
Line 9: Line 9:
 
{{#if: {{{mincount|}}}{{{maxcount|}}} |{{#ifeq:{{{mincount|}}}|all|{{#dplvar:set|includeall|yes}}| }}| }}
 
{{#if: {{{mincount|}}}{{{maxcount|}}} |{{#ifeq:{{{mincount|}}}|all|{{#dplvar:set|includeall|yes}}| }}| }}
 
<!-- {{#if: {{{maxcount|}}}| *There will be {{{mincount}}} - {{{maxcount}}} items in this container| {{#if: {{#dplvar:includeall}}| This container gives all the items listed below.| }} }} -->
 
<!-- {{#if: {{{maxcount|}}}| *There will be {{{mincount}}} - {{{maxcount}}} items in this container| {{#if: {{#dplvar:includeall}}| This container gives all the items listed below.| }} }} -->
{{#dplvar:set|scaler|1 }}
+
{{#dplvar:set|scaler|1 }}<!--
   
<!-- Calculates the total probability of all items -->
+
Calculates the total probability of all items -->
  +
{{#dplvar:
{{#dplvar:set|totalprobability|{{#expr:{{#dpl:debug=0|skipthispage=no|title={{#var:pagename}}|include={LootList-item}:probability|secseparators=+}} }} }}
 
  +
set|totalprobability|{{#expr:
  +
{{#dpl:
  +
debug=0|skipthispage=no|title={{#var:pagename}}| {{#if:
  +
{{{modlist|}}} | {{#if: {{#dpl:skipthispage=no|title={{#var:pagename}}|include={LootList-Item}:probability}} | include={LootList-mod}:probability, {LootList-Item}:probability | include={LootList-mod}:probability }} | include={LootList-Item}:probability
  +
}}|secseparators=+
  +
}}
  +
}}
  +
}}<!--
   
<!-- Defines the different availability types. -->
+
Defines the different availability types. -->
 
{{#dplvar:set|common|{{{common|10}}}}} {{#dplvar:set|uncommon|{{{uncommon|2}}}}} {{#dplvar:set|rare|{{{rare|1}}}}}
 
{{#dplvar:set|common|{{{common|10}}}}} {{#dplvar:set|uncommon|{{{uncommon|2}}}}} {{#dplvar:set|rare|{{{rare|1}}}}}
   

Latest revision as of 13:37, 10 May 2021


Template documentation (for the above template, sometimes hidden or invisible)

Use this in a loot list as the first template.
Needs variables quiet, mincount, maxcount, pageid and size (in x*y format).
Only give quiet a value if the list is not a loot container.
Only give pageid a value if the list is a loot container (eg. pageid=70 at Loot Container 70).

Things to fix:

  • Groups where all items are got.
    • Fix'dd
  • Groups where probability varies.