621
edits
Tag: Undo |
(second attempt, this should work!) |
||
Line 104: | Line 104: | ||
local fmt = (dropChance < 0.10 and '%.2g') or '%.2f' | local fmt = (dropChance < 0.10 and '%.2g') or '%.2f' | ||
table.insert(result, 'style="text-align:right"|'..string.format(fmt, dropChance * 100)..'%') | table.insert(result, 'style="text-align:right"|'..string.format(fmt, dropChance * 100)..'%') | ||
lootValue = lootValue + (dropChance | lootValue = lootValue + (dropChance * thisItem.sellsFor * ((row.minQuantity + row.maxQuantity)/ 2)) | ||
end | end | ||