localize a variable
This commit is contained in:
parent
43cdcd2de2
commit
a0764085f2
2
init.lua
2
init.lua
@ -52,7 +52,7 @@ local on_digiline_receive_deca = function(pos, node, channel, msg)
|
||||
local meta = minetest.get_meta(pos)
|
||||
local setchan = meta:get_string("channel")
|
||||
if setchan ~= channel then return end
|
||||
tubenum = string.gsub(node.name, "nixie_tubes:decatron_", "")
|
||||
local tubenum = string.gsub(node.name, "nixie_tubes:decatron_", "")
|
||||
local num = tonumber(msg)
|
||||
|
||||
if msg == "off" or (num and (num >= 0 and num <= 9)) then
|
||||
|
Loading…
Reference in New Issue
Block a user