This commit is contained in:
Elias Fleckenstein 2021-01-06 12:48:39 +01:00
parent 08a8b155d7
commit 034174390d
2 changed files with 6 additions and 3 deletions

View file

@ -320,7 +320,7 @@ local function trace_explode(pos, strength, raydirs, radius, drop_chance, fire,
if do_drop or on_blast ~= nil then
local npos = minetest.get_position_from_hash(hash)
if on_blast ~= nil then
on_blast(npos, 1.0)
on_blast(npos, 1.0, do_drop)
remove = false
else
local name = minetest.get_name_from_content_id(data[idx])

View file

@ -223,7 +223,7 @@ minetest.register_node("mcl_armor_stand:armor_stand", {
after_destruct = function(pos)
update_entity(pos)
end,
on_blast = function(pos)
on_blast = function(pos, _, do_drop)
local object = get_stand_object(pos)
if object then
object:remove()
@ -231,7 +231,10 @@ minetest.register_node("mcl_armor_stand:armor_stand", {
minetest.after(1, function(pos)
update_entity(pos)
end, pos)
minetest.set_node(pos, {name = "air"})
minetest.remove_node(pos)
if do_drop then
minetest.add_item(pos, "mcl_armor_stand:armor_stand")
end
end,
on_rotate = function(pos, node, user, mode)
if mode == screwdriver.ROTATE_FACE then