projects
/
zefram
/
minetest
/
pipeworks.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
012aa39
)
check for malformed table in scan_for_tube_objects()
author
Vanessa Ezekowitz
<vanessaezekowitz@gmail.com>
Sun, 9 Feb 2014 02:54:06 +0000
(21:54 -0500)
committer
Vanessa Ezekowitz
<vanessaezekowitz@gmail.com>
Sun, 9 Feb 2014 02:54:06 +0000
(21:54 -0500)
autoplace_tubes.lua
patch
|
blob
|
history
diff --git
a/autoplace_tubes.lua
b/autoplace_tubes.lua
index 385458c7de94a934b5e5cf698dee8ebddec1caf5..c9d5d9f688c0e849c7834810954ecf7cd5fb22e5 100644
(file)
--- a/
autoplace_tubes.lua
+++ b/
autoplace_tubes.lua
@@
-131,7
+131,7
@@
local function tube_autoroute(pos)
end
function pipeworks.scan_for_tube_objects(pos)
- if
pos == nil
then return end
+ if
not pos or not pos.x or not pos.y or not pos.z
then return end
tube_autoroute({ x=pos.x-1, y=pos.y , z=pos.z })
tube_autoroute({ x=pos.x+1, y=pos.y , z=pos.z })
tube_autoroute({ x=pos.x , y=pos.y-1, z=pos.z })