fork update #10

Merged
chmodsayshello merged 220 commits from VoxeLibre/VoxeLibre:master into master 2023-06-04 12:44:03 +02:00
1 changed files with 8 additions and 8 deletions
Showing only changes of commit 952c72c414 - Show all commits

View File

@ -113,14 +113,6 @@ local function on_dig_banner(pos, node, digger)
minetest.record_protection_violation(pos, name) minetest.record_protection_violation(pos, name)
return return
end end
-- Drop item
local meta = minetest.get_meta(pos)
local item = meta:get_inventory():get_stack("banner", 1)
if not item:is_empty() then
minetest.handle_node_drops(pos, {item:to_string()}, digger)
else
minetest.handle_node_drops(pos, {"mcl_banners:banner_item_white"}, digger)
end
-- Remove node -- Remove node
minetest.remove_node(pos) minetest.remove_node(pos)
end end
@ -143,6 +135,14 @@ local function on_destruct_banner(pos, hanging)
v:remove() v:remove()
end end
end end
-- Drop item
local meta = minetest.get_meta(pos)
local item = meta:get_inventory():get_stack("banner", 1)
if not item:is_empty() then
minetest.handle_node_drops(pos, {item:to_string()})
else
minetest.handle_node_drops(pos, {"mcl_banners:banner_item_white"})
end
end end
local function on_destruct_standing_banner(pos) local function on_destruct_standing_banner(pos)