I have no idea what I'm doing.

This commit is contained in:
Diego Martínez 2017-02-22 20:48:24 -03:00
parent 7657d0d1f2
commit c655902676
1 changed files with 1 additions and 10 deletions

View File

@ -498,21 +498,12 @@ signs_lib.update_sign = function(pos, fields, owner)
local text = meta:get_string("text") local text = meta:get_string("text")
if text == nil then return end if text == nil then return end
local objects = minetest.get_objects_inside_radius(pos, 0.5) local objects = minetest.get_objects_inside_radius(pos, 0.5)
local found
for _, v in ipairs(objects) do for _, v in ipairs(objects) do
local e = v:get_luaentity() local e = v:get_luaentity()
if e and e.name == "signs:text" then if e and e.name == "signs:text" then
if found then v:remove()
v:remove()
else
set_obj_text(v, text, new, pos)
found = true
end
end end
end end
if found then
return
end
-- if there is no entity -- if there is no entity
local sign_info local sign_info