master #5

Merged
epCode merged 255 commits from VoxeLibre/VoxeLibre:master into master 2021-02-02 23:20:01 +01:00
1 changed files with 4 additions and 5 deletions
Showing only changes of commit 5385a3f202 - Show all commits

View File

@ -145,7 +145,7 @@ function mesecon.mvps_get_stack(pos, dir, maximum, piston_pos)
if not node_replaceable(nn.name) then if not node_replaceable(nn.name) then
if #nodes >= maximum then return nil, false end if #nodes >= maximum then return nil, false end
table.insert(nodes, {node = nn, pos = np}) table.insert(nodes, {node = nn, pos = {x=np.x, y=np.y, z=np.z}})
-- add connected nodes to frontiers, connected is a vector list -- add connected nodes to frontiers, connected is a vector list
-- the vectors must be absolute positions -- the vectors must be absolute positions
@ -195,10 +195,9 @@ function mesecon.mvps_set_owner(pos, placer)
end end
end end
local function are_protected(positions, player_name) local function are_protected(nodes, player_name)
local name = player_name for _, node in pairs(nodes) do
for _, pos in pairs(positions) do if minetest.is_protected(node.pos, player_name) then
if is_protected(pos, name) then
return true return true
end end
end end