Merge pull request #124 from Niklp09/drops

fix unknown item drops
This commit is contained in:
Joachim Stolberg 2023-04-11 11:00:42 +02:00 committed by GitHub
commit a3079dae78
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -53,8 +53,8 @@ local NodeNames = {
"techage:basalt_glass", "techage:basalt_glass",
"techage:basalt_glass2", "techage:basalt_glass2",
"techage:bauxite_stone",
"techage:bauxite_cobble", "techage:bauxite_cobble",
"techage:bauxite_stone",
"techage:cement_block", "techage:cement_block",
} }
@ -64,6 +64,9 @@ if(minetest.get_modpath("moreblocks")) then
local ndef = minetest.registered_nodes[name] local ndef = minetest.registered_nodes[name]
if ndef then if ndef then
ndef = table.copy(ndef) ndef = table.copy(ndef)
if ndef.drop then -- this fixes https://github.com/fluxionary/minetest-moreblocks/issues/19
ndef.drop = nil
end
local subname = string.split(name, ":")[2] local subname = string.split(name, ":")[2]
ndef.sunlight_propagates = true ndef.sunlight_propagates = true
ndef.groups.not_in_creative_inventory = 1 ndef.groups.not_in_creative_inventory = 1