[_mcl_autogroup] fix warnings
This commit is contained in:
parent
f5a91f7c24
commit
f61102279f
|
@ -121,7 +121,7 @@ local hardness_values = get_hardness_values_for_groups()
|
||||||
-- hardness_value. Used for quick lookup.
|
-- hardness_value. Used for quick lookup.
|
||||||
local hardness_lookup = get_hardness_lookup_for_groups(hardness_values)
|
local hardness_lookup = get_hardness_lookup_for_groups(hardness_values)
|
||||||
|
|
||||||
local function compute_creativetimes(group)
|
--[[local function compute_creativetimes(group)
|
||||||
local creativetimes = {}
|
local creativetimes = {}
|
||||||
|
|
||||||
for index, hardness in pairs(hardness_values[group]) do
|
for index, hardness in pairs(hardness_values[group]) do
|
||||||
|
@ -129,7 +129,7 @@ local function compute_creativetimes(group)
|
||||||
end
|
end
|
||||||
|
|
||||||
return creativetimes
|
return creativetimes
|
||||||
end
|
end]]
|
||||||
|
|
||||||
-- Get the list of digging times for using a specific tool on a specific
|
-- Get the list of digging times for using a specific tool on a specific
|
||||||
-- diggroup.
|
-- diggroup.
|
||||||
|
@ -239,13 +239,13 @@ function mcl_autogroup.can_harvest(nodename, toolname)
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Get one groupcap field for using a specific tool on a specific group.
|
-- Get one groupcap field for using a specific tool on a specific group.
|
||||||
local function get_groupcap(group, can_harvest, multiplier, efficiency, uses)
|
--[[local function get_groupcap(group, can_harvest, multiplier, efficiency, uses)
|
||||||
return {
|
return {
|
||||||
times = get_digtimes(group, can_harvest, multiplier, efficiency),
|
times = get_digtimes(group, can_harvest, multiplier, efficiency),
|
||||||
uses = uses,
|
uses = uses,
|
||||||
maxlevel = 0,
|
maxlevel = 0,
|
||||||
}
|
}
|
||||||
end
|
end]]
|
||||||
|
|
||||||
-- Returns the tool_capabilities from a tool definition or a default set of
|
-- Returns the tool_capabilities from a tool definition or a default set of
|
||||||
-- tool_capabilities
|
-- tool_capabilities
|
||||||
|
@ -315,12 +315,12 @@ local overwrite = function()
|
||||||
newgroups.opaque = 1
|
newgroups.opaque = 1
|
||||||
end
|
end
|
||||||
|
|
||||||
local creative_breakable = false
|
--local creative_breakable = false
|
||||||
|
|
||||||
-- Assign groups used for digging this node depending on
|
-- Assign groups used for digging this node depending on
|
||||||
-- the registered digging groups
|
-- the registered digging groups
|
||||||
for g, gdef in pairs(mcl_autogroup.registered_diggroups) do
|
for g, gdef in pairs(mcl_autogroup.registered_diggroups) do
|
||||||
creative_breakable = true
|
--creative_breakable = true
|
||||||
local index = hardness_lookup[g][ndef._mcl_hardness or 0]
|
local index = hardness_lookup[g][ndef._mcl_hardness or 0]
|
||||||
if ndef.groups[g] then
|
if ndef.groups[g] then
|
||||||
if gdef.levels then
|
if gdef.levels then
|
||||||
|
|
Loading…
Reference in New Issue
Block a user