1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-09-15 18:57:08 +00:00

Private nodemeta (#5702)

* Private node metadata that isn't sent to the client
This commit is contained in:
sfan5 2017-05-10 15:29:21 +02:00 committed by Loïc Blot
parent 6945f807ab
commit 071e114ffa
10 changed files with 114 additions and 27 deletions

View file

@ -1228,6 +1228,8 @@ minetest.register_node("default:chest_locked", {
meta:set_string("owner", "")
local inv = meta:get_inventory()
inv:set_size("main", 8*4)
-- this is not really the intended usage but works for testing purposes:
meta:mark_as_private("owner")
end,
can_dig = function(pos,player)
local meta = minetest.get_meta(pos);