You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
--replaces all nodes other than `searchnode` with `replacenode` in a region defined by positions `pos1` and `pos2`, returning the number of nodes replaced
--copies the region defined by positions `pos1` and `pos2` along the `axis` axis ("x" or "y" or "z") by `amount` nodes, returning the number of nodes copied
--moves the region defined by positions `pos1` and `pos2` along the `axis` axis ("x" or "y" or "z") by `amount` nodes, returning the number of nodes moved
--duplicates the region defined by positions `pos1` and `pos2` along the `axis` axis ("x" or "y" or "z") `count` times, returning the number of nodes stacked
--transposes a region defined by the positions `pos1` and `pos2` between the `axis1` and `axis2` axes, returning the number of nodes transposed, the new position 1, and the new position 2
--rotates a region defined by the positions `pos1` and `pos2` by `angle` degrees clockwise around axis `axis` (90 degree increment), returning the number of nodes rotated
--rotates all oriented nodes in a region defined by the positions `pos1` and `pos2` by `angle` degrees clockwise (90 degree increment) around the Y axis, returning the number of nodes oriented
--adds a dome at `pos` with radius `radius`, composed of `nodename`, returning the number of nodes added
75
-
worldedit.dome=function(pos, radius, nodename) --wip: use bresenham sphere for maximum speed
75
+
worldedit.dome=function(pos, radius, nodename, env) --wip: use bresenham sphere for maximum speed
76
76
localnode= {name=nodename}
77
77
localpos1= {x=0, y=0, z=0}
78
78
localmax_radius=radius* (radius+1)
79
79
localcount=0
80
-
localenv=minetest.env
80
+
ifenv==nilthenenv=minetest.envend
81
81
forx=-radius, radiusdo
82
82
pos1.x=pos.x+x
83
83
fory=0, radiusdo
@@ -95,7 +95,7 @@ worldedit.dome = function(pos, radius, nodename) --wip: use bresenham sphere for
95
95
end
96
96
97
97
--adds a hollow cylinder at `pos` along the `axis` axis ("x" or "y" or "z") with length `length` and radius `radius`, composed of `nodename`, returning the number of nodes added
--adds a cylinder at `pos` along the `axis` axis ("x" or "y" or "z") with length `length` and radius `radius`, composed of `nodename`, returning the number of nodes added
--adds a spiral at `pos` with width `width`, height `height`, space between walls `spacer`, composed of `nodename`, returning the number of nodes added
247
-
worldedit.spiral=function(pos, width, height, spacer, nodename) --wip: clean this up
247
+
worldedit.spiral=function(pos, width, height, spacer, nodename, env) --wip: clean this up
0 commit comments