From 5b5a254b1afecc7c28048f81ee601f688e6f720e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elias=20=C3=85str=C3=B6m?= Date: Thu, 11 Mar 2021 15:11:11 +0100 Subject: [PATCH] Fix tool uses not being set in _mcl_autogroups --- mods/CORE/_mcl_autogroup/init.lua | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/mods/CORE/_mcl_autogroup/init.lua b/mods/CORE/_mcl_autogroup/init.lua index 1d13c23a9b..bd8e249c4c 100644 --- a/mods/CORE/_mcl_autogroup/init.lua +++ b/mods/CORE/_mcl_autogroup/init.lua @@ -185,16 +185,17 @@ local function add_groupcaps(groupcaps, groupcaps_def) for g, capsdef in pairs(groupcaps_def) do local mult = capsdef.tool_multiplier or 1 local eff = capsdef.efficiency or 0 + local uses = capsdef.uses local def = mcl_autogroup.registered_diggroups[g] local level = capsdef.level or 1 local max_level = def.levels or 0 if max_level > 0 then level = math.min(level, max_level) - groupcaps[g .. "_0_dig"] = get_groupcap(g, false, mult, eff) - groupcaps[g .. "_" .. level .. "_dig"] = get_groupcap(g, true, mult, eff) + groupcaps[g .. "_0_dig"] = get_groupcap(g, false, mult, eff, uses) + groupcaps[g .. "_" .. level .. "_dig"] = get_groupcap(g, true, mult, eff, uses) else - groupcaps[g .. "_dig"] = get_groupcap(g, true, mult, eff) + groupcaps[g .. "_dig"] = get_groupcap(g, true, mult, eff, uses) end end return groupcaps