don't need to set downPull to 0 because it was 0

This commit is contained in:
Lilian Jónsdóttir 2021-08-14 13:41:25 -07:00
parent 201984761a
commit b71c4d32ec

View file

@ -135,11 +135,8 @@ local function sinkInWater(e)
local downPull = 0 local downPull = 0
local debugStr = "" local debugStr = ""
-- don't calculate if disabled -- calculate the down-pull with the configured formula if enabled
if not config.enabled then if config.enabled then
downPull = 0
-- calculate the down-pull with the configured formula
else
for _, t in ipairs(common.modes) do for _, t in ipairs(common.modes) do
if t.mode == config.mode then if t.mode == config.mode then
downPull, debugStr = formulas[t.mode](actor, mobile, ref) downPull, debugStr = formulas[t.mode](actor, mobile, ref)