Bugfix
authorNovatux <nathanael.courant@laposte.net>
Thu, 7 Feb 2013 16:21:35 +0000 (17:21 +0100)
committerNovatux <nathanael.courant@laposte.net>
Thu, 7 Feb 2013 16:21:35 +0000 (17:21 +0100)
tubes.lua

index f5f68ef6e93f0ab8744d627733a48c23f96984f5..19139a37a527d48a38c7bd038ab7c43fe48171c6 100644 (file)
--- a/tubes.lua
+++ b/tubes.lua
@@ -332,6 +332,7 @@ register_tube("pipeworks:mese_tube","Mese pneumatic tube segment",mese_plain_tex
                local meta=minetest.env:get_meta(pos)
                local i
                for key,_ in pairs(fields) do i=key end
+               if i==nil then return end
                i=string.sub(i,-1)
                newstate=1-meta:get_int("l"..i.."s")
                meta:set_int("l"..i.."s",newstate)