summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWuzzy <almikes@aol.com>2016-12-14 13:19:37 +0100
committerWuzzy <almikes@aol.com>2016-12-14 13:37:17 +0100
commit8f3dca8e937d3fa36b7837f2b19afa8e2ee0cf21 (patch)
tree59acd9f5ff934b401e8f822ad8e21685c2a92d1e
parent24db5de70f51223cc587a306085e599031b0677d (diff)
Replace “mining capabilities” w/ maxlevel
-rw-r--r--init.lua11
1 files changed, 5 insertions, 6 deletions
diff --git a/init.lua b/init.lua
index e6f2572..96735f3 100644
--- a/init.lua
+++ b/init.lua
@@ -190,14 +190,12 @@ local toolcaps_to_text = function(tool_capabilities, check_uses)
end
end
local levelstring
- if v.maxlevel == 0 then
- levelstring = S("level 0")
- elseif v.maxlevel ~= nil then
- levelstring = S("level 0-@1", v.maxlevel)
+ if v.maxlevel ~= nil then
+ levelstring = tostring(v.maxlevel)
else
levelstring = S("any level")
end
- miningcapstr = miningcapstr .. S("• @1: @2, @3", doc.sub.items.get_group_name(k), ratingstring, levelstring)
+ miningcapstr = miningcapstr .. S("• @1: @2", doc.sub.items.get_group_name(k), levelstring)
miningcapstr = miningcapstr .. "\n"
caplines = caplines + 1
@@ -219,6 +217,7 @@ local toolcaps_to_text = function(tool_capabilities, check_uses)
doc.sub.items.get_group_name(k), rating,
mintimestr, maxtimestr)
else
+ miningtimesstr = miningtimesstr ..
S("• @1, rating @2: @3s",
doc.sub.items.get_group_name(k), rating,
mintimestr)
@@ -239,7 +238,7 @@ local toolcaps_to_text = function(tool_capabilities, check_uses)
end
end
if caplines > 0 then
- formstring = formstring .. S("This tool is capable of mining.\nMining capabilities:\n")
+ formstring = formstring .. S("This tool is capable of mining.\nMaximum mining levels:\n")
formstring = formstring .. miningcapstr
formstring = newline(formstring)
end