Update to newest worldedit

This commit is contained in:
Hybrid Dog 2018-02-03 15:12:38 +01:00
parent 48553a1cdc
commit 1129cb1601
2 changed files with 8 additions and 12 deletions

@ -51,6 +51,7 @@ Not yet implemented:
* /contract
* /outset
* /inset
* /cube /hollowcube
* /copy
* /move
* /stack

@ -688,19 +688,14 @@ local function pyramid_func(_,_, ...)
end
local function my_we_pyramid(pos, axis, height, ...)
local h = math.ceil(math.abs(height))
-- This code is commented because of a worldedit pyramid wrapping bug. FIXME
--~ local pos1 = vector.subtract(pos, h-1)
--~ local pos2 = vector.add(pos, h-1)
local pos1 = vector.subtract(pos, h-1)
local pos2 = vector.add(pos, h-1)
--~ if height > 0 then
--~ pos1[axis] = pos[axis]
--~ else
--~ pos2[axis] = pos[axis]
--~ end
-- This workaround doesn't necessarily work right. It worked when tested.
local pos1 = vector.subtract(pos, h + 15)
local pos2 = vector.add(pos, h + 15)
if height > 0 then
pos1[axis] = pos[axis]
else
pos2[axis] = pos[axis]
end
return we_nodeset_wrapper(pyramid_func, pos1, pos2, pos, axis, height, ...)
end