summaryrefslogtreecommitdiff
path: root/init.lua
diff options
context:
space:
mode:
authorWuzzy <almikes@aol.com>2016-08-01 23:47:24 +0200
committerWuzzy <almikes@aol.com>2016-08-01 23:47:24 +0200
commit724f67cfd2bd4ba34801dde4a6ea4e6b77e20c81 (patch)
tree236708fd9f801d7839a82f3c7d41e71f8336e8af /init.lua
parent7c45abfee3c8c9203857f7708f2163ee65f71774 (diff)
Fix bug of drops being displayed too often
Diffstat (limited to 'init.lua')
-rw-r--r--init.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/init.lua b/init.lua
index 704aa07..dbd4403 100644
--- a/init.lua
+++ b/init.lua
@@ -346,7 +346,7 @@ doc.new_category("nodes", {
end
-- Non-default drops
- if data.def.drop ~= nil and data.def.drop ~= data.def.itemstring then
+ if data.def.drop ~= nil and data.def.drop ~= data.itemstring and data.itemstring ~= "air" then
local get_desc = function(stack)
local desc = minetest.registered_items[stack:get_name()].description
if desc == nil then
@@ -359,7 +359,7 @@ doc.new_category("nodes", {
formstring = formstring .. "This block won't drop anything when mined.\n"
elseif type(data.def.drop) == "string" then
local dropstack = ItemStack(data.def.drop)
- if dropstack:get_name() ~= data.def.itemstring and dropstack:get_name() ~= 1 then
+ if dropstack:get_name() ~= data.itemstring and dropstack:get_name() ~= 1 then
local desc = get_desc(dropstack)
local count = dropstack:get_count()
local finalstring