Browse Source

Add camera privilege in order to use camera commands

master nalc-1.0
sys4-fr 3 years ago
parent
commit
e106ac96f9
  1. 4
      init.lua

4
init.lua

@ -1,3 +1,4 @@
minetest.register_privilege("camera", { description = "Can use camera commands" })
local recordings = {}
-- [function] Load recordings
@ -251,6 +252,9 @@ minetest.register_chatcommand("camera", {
description = "Manipulate recording",
params = "<option> <value>",
func = function(name, param)
if not minetest.check_player_privs(name, { camera = true }) then
return false, "You need camera privilege!"
end
local player = minetest.get_player_by_name(name)
local param1, param2 = param:split(" ")[1], param:split(" ")[2]

Loading…
Cancel
Save