mirror of
https://github.com/minetest-mods/teleport-request.git
synced 2025-01-08 14:07:28 +01:00
Merge pull request #2 from DonBatman/master
Added areas support --Thanks DonBatman!
This commit is contained in:
commit
52b520fa23
1
depends.txt
Normal file
1
depends.txt
Normal file
@ -0,0 +1 @@
|
||||
areas
|
2
init.lua
2
init.lua
@ -90,7 +90,7 @@ local function tpc_send(player,coordinates)
|
||||
-- In future release we'll actually query the player who owns the area, if they're online, and ask for their permission.
|
||||
local protected = minetest.is_protected(target_coords,pname)
|
||||
if protected then
|
||||
local owner_string = get_owner_string(target_coords)
|
||||
local owner_string = areas:getNodeOwners(target_coords)
|
||||
if pname ~= owner_string then
|
||||
minetest.chat_send_player(player, "Error: These coordinates are within a protected area.")
|
||||
return
|
||||
|
Loading…
Reference in New Issue
Block a user