Allow to repair node number

This commit is contained in:
Thomas--S 2021-10-12 16:35:26 +02:00
parent 90815845f9
commit 803c6b80f6

View File

@ -253,6 +253,14 @@ function techage.remove_node(pos, oldnode, oldmetadata)
end
end
-- Repairs the node number after it was erased by `backend.delete_invalid_entries`
function techage.repair_number(pos)
local number = techage.get_node_number(pos)
if number then
backend.set_nodepos(number, pos)
end
end
-------------------------------------------------------------------
-- Node register function