mirror of
https://git.minetest.land/MineClone2/MineClone2.git
synced 2024-09-12 08:58:36 +02:00
Merge pull request 'Fix endermen dropping node AND taking it (#2122)' (#2130) from fix_enderman_dupe into master
Reviewed-on: https://git.minetest.land/MineClone2/MineClone2/pulls/2130 Reviewed-by: kabou <kabou@noreply.git.minetest.land>
This commit is contained in:
commit
1bcbdfbc4c
@ -395,8 +395,9 @@ mobs:register_mob("mobs_mc:enderman", {
|
||||
local node = minetest.get_node(take_pos)
|
||||
-- Don't destroy protected stuff.
|
||||
if not minetest.is_protected(take_pos, "") then
|
||||
local dug = minetest.dig_node(take_pos)
|
||||
if dug then
|
||||
minetest.remove_node(take_pos)
|
||||
local dug = minetest.get_node_or_nil(take_pos)
|
||||
if dug and dug.name == "air" then
|
||||
if mobs_mc.enderman_replace_on_take[node.name] then
|
||||
self._taken_node = mobs_mc.enderman_replace_on_take[node.name]
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user