From: Perttu Ahola Date: Mon, 9 Apr 2012 21:41:28 +0000 (+0300) Subject: basic_privs to allow granting/revoking interact_extra too X-Git-Tag: 0.4.dev-20120603~48 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=8742b3dab21a60ae78456d54212c18c764e6dc7f;p=oweals%2Fminetest.git basic_privs to allow granting/revoking interact_extra too --- diff --git a/builtin/chatcommands.lua b/builtin/chatcommands.lua index a7061e3a3..e5d31c6aa 100644 --- a/builtin/chatcommands.lua +++ b/builtin/chatcommands.lua @@ -130,7 +130,7 @@ minetest.register_chatcommand("grant", { local privs = minetest.get_player_privs(grantname) local privs_known = true for priv, _ in pairs(grantprivs) do - if priv ~= "interact" and priv ~= "shout" and not minetest.check_player_privs(name, {privs=true}) then + if priv ~= "interact" and priv ~= "shout" and priv ~= "interact_extra" and not minetest.check_player_privs(name, {privs=true}) then minetest.chat_send_player(name, "Your privileges are insufficient.") return end @@ -168,7 +168,7 @@ minetest.register_chatcommand("revoke", { local revokeprivs = minetest.string_to_privs(revokeprivstr) local privs = minetest.get_player_privs(revokename) for priv, _ in pairs(revokeprivs) do - if priv ~= "interact" and priv ~= "shout" and not minetest.check_player_privs(name, {privs=true}) then + if priv ~= "interact" and priv ~= "shout" and priv ~= "interact_extra" and not minetest.check_player_privs(name, {privs=true}) then minetest.chat_send_player(name, "Your privileges are insufficient.") return end