Merge pull request #2 from oversword/bls-370
Check if huds exist before removing them
This commit is contained in:
commit
cb88628e19
|
@ -230,8 +230,12 @@ minetest.register_node("cottages:anvil", {
|
||||||
minetest.after(2, function()
|
minetest.after(2, function()
|
||||||
if( puncher ) then
|
if( puncher ) then
|
||||||
puncher:hud_remove(hud1);
|
puncher:hud_remove(hud1);
|
||||||
puncher:hud_remove(hud2);
|
if hud2 then
|
||||||
puncher:hud_remove(hud3);
|
puncher:hud_remove(hud2);
|
||||||
|
end
|
||||||
|
if hud3 then
|
||||||
|
puncher:hud_remove(hud3);
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end)
|
end)
|
||||||
|
|
||||||
|
@ -300,4 +304,3 @@ minetest.register_craft({
|
||||||
{'cottages:anvil'},
|
{'cottages:anvil'},
|
||||||
{cottages.craftitem_stick} }
|
{cottages.craftitem_stick} }
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue