Allow wooden doors in maps (#551)
This commit is contained in:
parent
22e2e03798
commit
05fba3f5ce
1 changed files with 7 additions and 6 deletions
|
@ -150,13 +150,14 @@ function _doors.door_toggle(pos, node, clicker)
|
|||
|
||||
replace_old_owner_information(pos)
|
||||
|
||||
-- If team door, check clicker's team
|
||||
if node.name:find("doors:door_steel") then
|
||||
local tname = ctf.player(clicker:get_player_name()).team
|
||||
local owner_team = meta:get_string("owner_team")
|
||||
local is_right_team = tname == owner_team
|
||||
if clicker and not minetest.check_player_privs(clicker, "protection_bypass") and
|
||||
not is_right_team then
|
||||
if clicker and tname ~= owner_team then
|
||||
return false
|
||||
end
|
||||
end
|
||||
|
||||
-- until Lua-5.2 we have no bitwise operators :(
|
||||
if state % 2 == 1 then
|
||||
|
|
Loading…
Reference in a new issue