mirror of
https://github.com/minetest-mods/3d_armor.git
synced 2024-11-26 14:23:45 +01:00
Fix armor stand entity duplication bug
This commit is contained in:
parent
1dd904f5be
commit
59bbc55b73
@ -20,8 +20,10 @@ local function update_entity(pos)
|
||||
local object = nil
|
||||
local node = minetest.get_node(pos)
|
||||
local objects = minetest.get_objects_inside_radius(pos, 1) or {}
|
||||
pos = vector.round(pos)
|
||||
for _, obj in pairs(objects) do
|
||||
if vector.equals(obj:getpos(), pos) then
|
||||
local p = vector.round(obj:getpos())
|
||||
if vector.equals(p, pos) then
|
||||
local ent = obj:get_luaentity()
|
||||
if ent then
|
||||
if ent.name == "3d_armor_stand:armor_entity" then
|
||||
|
Loading…
Reference in New Issue
Block a user