mirror of
https://gitlab.com/lunovox/minertrade.git
synced 2025-03-15 05:31:20 +00:00
Adicionando compatibilidade com mod Areas. A partir de agora o jogador poderá mexer na máquina dispensadora de outro jogador se esta máquina estiver em seu terreno protegido tanto pelo mod tradelands quanto pelo mod areas.
futuramente também adicionarei compatibilidade com mod protector.
This commit is contained in:
parent
63fc241ac8
commit
27dadab3a3
2 changed files with 3 additions and 1 deletions
|
@ -2,3 +2,4 @@ default
|
|||
dye
|
||||
intllib?
|
||||
tradelands?
|
||||
areas?
|
||||
|
|
|
@ -108,7 +108,8 @@ modMinerTrade.dispensing.canOpen = function(pos, playername)
|
|||
local meta = minetest.env:get_meta(pos)
|
||||
if
|
||||
meta:get_string("owner")==playername
|
||||
or (minetest.get_modpath("tradelands") and modTradeLands.canInteract(pos, playername))
|
||||
or (minetest.get_modpath("tradelands") and modTradeLands.getOwnerName(pos)~="" and modTradeLands.canInteract(pos, playername))
|
||||
or (minetest.get_modpath("areas") and #areas:getNodeOwners(pos)>=1 and areas.canInteract(pos, playername))
|
||||
then
|
||||
return true
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue