summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--functions.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/functions.lua b/functions.lua
index 53e5e20..00f73fc 100644
--- a/functions.lua
+++ b/functions.lua
@@ -50,6 +50,9 @@ worldedit.replace = function(pos1, pos2, searchnode, replacenode)
if minetest.registered_nodes[searchnode] == nil then
searchnode = "default:" .. searchnode
end
+ if minetest.registered_nodes[replacenode] == nil then
+ replacenode = "default:" .. replacenode
+ end
local pos = {x=pos1.x, y=0, z=0}
local node = {name=replacenode}