master
JPG 2017-10-06 10:50:46 +02:00
parent e955adb556
commit d990ee25f1
2 changed files with 7 additions and 2 deletions

View File

@ -1,3 +1,6 @@
local worldpath = minetest.get_worldpath()
local worldname = worldpath:match("/([%w%s_]+)$") or worldpath:match("\\([%w%s_]+)$")
local player_inventory = {} local player_inventory = {}
function creative.init_creative_inventory(player_name) function creative.init_creative_inventory(player_name)
@ -169,7 +172,8 @@ function creative.register_tab(name, title, items)
else for item in pairs(fields) do else for item in pairs(fields) do
if item:find(":") then if item:find(":") then
if not is_mapmaker and not is_teacher then if worldname:sub(1,6) ~= "build_" and
not is_mapmaker and not is_teacher then
minetest.chat_send_player(player_name, minetest.chat_send_player(player_name,
minetest.colorize("#FF0000", minetest.colorize("#FF0000",
"ERROR: Privilege 'mapmaker' or 'teacher'" .. "ERROR: Privilege 'mapmaker' or 'teacher'" ..

View File

@ -1 +1,2 @@
worldedit worldedit
utils