Advertisement
Guest User

Untitled

a guest
Aug 9th, 2017
43
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.34 KB | None | 0 0
  1. minetest.override_item("default:chest_locked", {
  2.  
  3. on_rightclick = function(pos, node, clicker, itemstack, pointed_thing)
  4.  
  5. local name = clicker:get_player_name()
  6.  
  7. if minetest.is_protected(pos,name) then
  8. minetest.chat_send_all(name,"You cannot use this shared chest, because you are not part of the protection.")
  9. return itemstack
  10. end
  11.  
  12. end
  13.  
  14. })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement