Module:WillpowerCooldownTable

local WillpowerCooldownTable = {}

local ProcessArgs = require'Module:ProcessArgs'

function WillpowerCooldownTable.calcCooldown(willpower, basecooldown) local internalCooldown = basecooldown * 10.0 local wpAdjustedCooldown = math.floor((internalCooldown * (100.0 - ((willpower - 16.0) * 5.0))) / 100.0) local minimumCooldown = math.max(math.floor(internalCooldown * 0.2 + 0.5), math.min(50.0, internalCooldown)) local calculatedCooldown = math.max(wpAdjustedCooldown, minimumCooldown) local finalCooldown = math.ceil(calculatedCooldown / 10.0) return finalCooldown end

function WillpowerCooldownTable.makeTable(frame) local args = ProcessArgs.merge(true) local baseCooldown = args.basecooldown

local result = " "

return result end

return WillpowerCooldownTable