added admin to remove or edit
This commit is contained in:
parent
fb47dde7d3
commit
75c8981dc3
@ -269,8 +269,12 @@ minetest.register_entity("trike:trike", {
|
||||
if not puncher or not puncher:is_player() then
|
||||
return
|
||||
end
|
||||
local is_admin = false
|
||||
is_admin = minetest.check_player_privs(puncher, {server=true})
|
||||
local name = puncher:get_player_name()
|
||||
if self.owner and self.owner ~= name and self.owner ~= "" then return end
|
||||
if self.owner and self.owner ~= name and self.owner ~= "" then
|
||||
if is_admin == false then return end
|
||||
end
|
||||
if self.owner == nil then
|
||||
self.owner = name
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user