From 9b9ee66b00376f05e7ac6fc851d257653963eee2 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Mon, 7 Dec 2020 00:49:46 +0100 Subject: [PATCH] Enderman will take nodes only below air --- mods/ENTITIES/mobs_mc/enderman.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mods/ENTITIES/mobs_mc/enderman.lua b/mods/ENTITIES/mobs_mc/enderman.lua index bd63ec0cc3..89c7b47f05 100644 --- a/mods/ENTITIES/mobs_mc/enderman.lua +++ b/mods/ENTITIES/mobs_mc/enderman.lua @@ -364,7 +364,7 @@ mobs:register_mob("mobs_mc:enderman", { self._take_place_timer = 0 self._next_take_place_time = math.random(place_frequency_min, place_frequency_max) local pos = self.object:get_pos() - local takable_nodes = minetest.find_nodes_in_area({x=pos.x-2, y=pos.y-1, z=pos.z-2}, {x=pos.x+2, y=pos.y+1, z=pos.z+2}, mobs_mc.enderman_takable) + local takable_nodes = minetest.find_nodes_in_area_under_air({x=pos.x-2, y=pos.y-1, z=pos.z-2}, {x=pos.x+2, y=pos.y+1, z=pos.z+2}, mobs_mc.enderman_takable) if #takable_nodes >= 1 then local r = pr:next(1, #takable_nodes) local take_pos = takable_nodes[r]