\r
### //hollowsphere <radius> <node>\r
\r
-Add hollow sphere at WorldEdit position 1 with radius <radius>, composed of <node>.\r
+Add hollow sphere centered at WorldEdit position 1 with radius <radius>, composed of <node>.\r
\r
//hollowsphere 5 Diamond Block\r
//hollowsphere 12 glass\r
\r
### //sphere <radius> <node>\r
\r
-Add sphere at WorldEdit position 1 with radius <radius>, composed of <node>.\r
+Add sphere centered at WorldEdit position 1 with radius <radius>, composed of <node>.\r
\r
//sphere 5 Diamond Block\r
//sphere 12 glass\r
\r
### //hollowdome <radius> <node>\r
\r
-Add hollow dome at WorldEdit position 1 with radius <radius>, composed of <node>.\r
+Add hollow dome centered at WorldEdit position 1 with radius <radius>, composed of <node>.\r
\r
//hollowdome 5 Diamond Block\r
//hollowdome 12 glass\r
\r
### //dome <radius> <node>\r
\r
-Add dome at WorldEdit position 1 with radius <radius>, composed of <node>.\r
+Add dome centered at WorldEdit position 1 with radius <radius>, composed of <node>.\r
\r
//dome 5 Diamond Block\r
//dome 12 glass\r
\r
### //pyramid <height> <node>\r
\r
-Add pyramid at WorldEdit position 1 with height <height>, composed of <node>.\r
+Add pyramid centered at WorldEdit position 1 with height <height>, composed of <node>.\r
\r
//pyramid 8 Diamond Block\r
//pyramid 5 glass\r
\r
### //spiral <width> <height> <spacer> <node>\r
\r
-Add spiral at WorldEdit position 1 with width <width>, height <height>, space between walls <spacer>, composed of <node>.\r
+Add spiral centered at WorldEdit position 1 with width <width>, height <height>, space between walls <spacer>, composed of <node>.\r
\r
//spiral 20 5 3 Diamond Block\r
//spiral 5 2 1 glass\r
\r
### count = worldedit.hollow_sphere(pos, radius, nodename)\r
\r
-Adds a hollow sphere at `pos` with radius `radius`, composed of `nodename`.\r
+Adds a hollow sphere centered at `pos` with radius `radius`, composed of `nodename`.\r
\r
Returns the number of nodes added.\r
\r
### count = worldedit.sphere(pos, radius, nodename)\r
\r
-Adds a sphere at `pos` with radius `radius`, composed of `nodename`.\r
+Adds a sphere centered at `pos` with radius `radius`, composed of `nodename`.\r
\r
Returns the number of nodes added.\r
\r
### count = worldedit.hollow_dome(pos, radius, nodename)\r
\r
-Adds a hollow dome at `pos` with radius `radius`, composed of `nodename`.\r
+Adds a hollow dome centered at `pos` with radius `radius`, composed of `nodename`.\r
\r
Returns the number of nodes added.\r
\r
### count = worldedit.dome(pos, radius, nodename)\r
\r
-Adds a dome at `pos` with radius `radius`, composed of `nodename`.\r
+Adds a dome centered at `pos` with radius `radius`, composed of `nodename`.\r
\r
Returns the number of nodes added.\r
\r
\r
### count = worldedit.pyramid(pos, height, nodename)\r
\r
-Adds a pyramid at `pos` with height `height`.\r
+Adds a pyramid centered at `pos` with height `height`.\r
\r
Returns the number of nodes added.\r
\r
### count = worldedit.spiral(pos, width, height, spacer, nodename)\r
\r
-Adds a spiral at `pos` with width `width`, height `height`, space between walls `spacer`, composed of `nodename`.\r
+Adds a spiral centered at `pos` with width `width`, height `height`, space between walls `spacer`, composed of `nodename`.\r
\r
Returns the number of nodes added.\r
\r
worldedit = worldedit or {}\r
\r
---adds a hollow sphere at `pos` with radius `radius`, composed of `nodename`, returning the number of nodes added\r
+--adds a hollow sphere centered at `pos` with radius `radius`, composed of `nodename`, returning the number of nodes added\r
worldedit.hollow_sphere = function(pos, radius, nodename, env)\r
local node = {name=nodename}\r
local pos1 = {x=0, y=0, z=0}\r
return count\r
end\r
\r
---adds a sphere at `pos` with radius `radius`, composed of `nodename`, returning the number of nodes added\r
+--adds a sphere centered at `pos` with radius `radius`, composed of `nodename`, returning the number of nodes added\r
worldedit.sphere = function(pos, radius, nodename, env)\r
local node = {name=nodename}\r
local pos1 = {x=0, y=0, z=0}\r
return count\r
end\r
\r
---adds a hollow dome at `pos` with radius `radius`, composed of `nodename`, returning the number of nodes added\r
+--adds a hollow dome centered at `pos` with radius `radius`, composed of `nodename`, returning the number of nodes added\r
worldedit.hollow_dome = function(pos, radius, nodename, env) --wip: use bresenham sphere for maximum speed\r
local node = {name=nodename}\r
local pos1 = {x=0, y=0, z=0}\r
return count\r
end\r
\r
---adds a dome at `pos` with radius `radius`, composed of `nodename`, returning the number of nodes added\r
+--adds a dome centered at `pos` with radius `radius`, composed of `nodename`, returning the number of nodes added\r
worldedit.dome = function(pos, radius, nodename, env) --wip: use bresenham sphere for maximum speed\r
local node = {name=nodename}\r
local pos1 = {x=0, y=0, z=0}\r
return count\r
end\r
\r
---adds a pyramid at `pos` with height `height`, composed of `nodename`, returning the number of nodes added\r
+--adds a pyramid centered at `pos` with height `height`, composed of `nodename`, returning the number of nodes added\r
worldedit.pyramid = function(pos, height, nodename, env)\r
local pos1x, pos1y, pos1z = pos.x - height, pos.y, pos.z - height\r
local pos2x, pos2y, pos2z = pos.x + height, pos.y + height, pos.z + height\r
return count\r
end\r
\r
---adds a spiral at `pos` with width `width`, height `height`, space between walls `spacer`, composed of `nodename`, returning the number of nodes added\r
+--adds a spiral centered at `pos` with width `width`, height `height`, space between walls `spacer`, composed of `nodename`, returning the number of nodes added\r
worldedit.spiral = function(pos, width, height, spacer, nodename, env) --wip: clean this up\r
-- spiral matrix - http://rosettacode.org/wiki/Spiral_matrix#Lua\r
av, sn = math.abs, function(s) return s~=0 and s/av(s) or 0 end\r
\r
minetest.register_chatcommand("/hollowsphere", {\r
params = "<radius> <node>",\r
- description = "Add hollow sphere at WorldEdit position 1 with radius <radius>, composed of <node>",\r
+ description = "Add hollow sphere centered at WorldEdit position 1 with radius <radius>, composed of <node>",\r
privs = {worldedit=true},\r
func = function(name, param)\r
local pos = worldedit.pos1[name]\r
\r
minetest.register_chatcommand("/sphere", {\r
params = "<radius> <node>",\r
- description = "Add sphere at WorldEdit position 1 with radius <radius>, composed of <node>",\r
+ description = "Add sphere centered at WorldEdit position 1 with radius <radius>, composed of <node>",\r
privs = {worldedit=true},\r
func = function(name, param)\r
local pos = worldedit.pos1[name]\r
\r
minetest.register_chatcommand("/hollowdome", {\r
params = "<radius> <node>",\r
- description = "Add hollow dome at WorldEdit position 1 with radius <radius>, composed of <node>",\r
+ description = "Add hollow dome centered at WorldEdit position 1 with radius <radius>, composed of <node>",\r
privs = {worldedit=true},\r
func = function(name, param)\r
local pos = worldedit.pos1[name]\r
\r
minetest.register_chatcommand("/dome", {\r
params = "<radius> <node>",\r
- description = "Add dome at WorldEdit position 1 with radius <radius>, composed of <node>",\r
+ description = "Add dome centered at WorldEdit position 1 with radius <radius>, composed of <node>",\r
privs = {worldedit=true},\r
func = function(name, param)\r
local pos = worldedit.pos1[name]\r
\r
minetest.register_chatcommand("/pyramid", {\r
params = "<height> <node>",\r
- description = "Add pyramid at WorldEdit position 1 with height <height>, composed of <node>",\r
+ description = "Add pyramid centered at WorldEdit position 1 with height <height>, composed of <node>",\r
privs = {worldedit=true},\r
func = function(name, param)\r
local pos = worldedit.pos1[name]\r
\r
minetest.register_chatcommand("/spiral", {\r
params = "<width> <height> <space> <node>",\r
- description = "Add spiral at WorldEdit position 1 with width <width>, height <height>, space between walls <space>, composed of <node>",\r
+ description = "Add spiral centered at WorldEdit position 1 with width <width>, height <height>, space between walls <space>, composed of <node>",\r
privs = {worldedit=true},\r
func = function(name, param)\r
local pos = worldedit.pos1[name]\r