Fix some beduino command issues

This commit is contained in:
Joachim Stolberg 2023-01-08 14:00:36 +01:00
parent 71d0d6f012
commit 26558ce1eb
5 changed files with 15 additions and 15 deletions

View File

@ -17,7 +17,7 @@ local M = minetest.get_meta
local S = techage.S
-- Consumer Related Data
local CRD = function(pos) return (minetest.registered_nodes[techage.get_node_lvm(pos).name] or {}).consumer end
local CRD = function(pos) return (minetest.registered_nodes[techage.get_node_lvm(pos).name] or {}).consumer or {} end
local STANDBY_TICKS = 3
local COUNTDOWN_TICKS = 4

View File

@ -341,7 +341,7 @@ local tubing = {
CRD(pos).State:stop(pos, nvm)
config_item(pos, payload)
return 0
elseif topic == 68 then -- Set push limit
elseif topic == 68 or topic == 20 then -- Set push limit
local nvm = techage.get_nvm(pos)
CRD(pos).State:stop(pos, nvm)
set_limit(pos, nvm, payload[1])

View File

@ -30,16 +30,16 @@ if minetest.global_exists("mesecon") then
},
time = 6,
})
else
techage.furnace.register_recipe({
output = "techage:ta4_silicon_wafer 16",
recipe = {
"basic_materials:silicon",
"basic_materials:silicon",
"basic_materials:silicon",
"techage:baborium_ingot"
},
time = 6,
})
end
techage.furnace.register_recipe({
output = "techage:ta4_silicon_wafer 16",
recipe = {
"basic_materials:silicon",
"basic_materials:silicon",
"basic_materials:silicon",
"techage:baborium_ingot"
},
time = 6,
})

View File

@ -343,7 +343,7 @@ techage.register_node({"techage:t4_pump", "techage:t4_pump_on"}, {
end
end,
on_beduino_receive_cmnd = function(pos, src, topic, payload)
if topic == 69 and payload then -- Set pump limit
if (topic == 69 or topic == 21) and payload then -- Set pump limit
local nvm = techage.get_nvm(pos)
State4:stop(pos, nvm)
if payload[1] > 0 then

View File

@ -148,7 +148,7 @@ local function register_signallamp(name, description, tiles_off, tiles_on, node_
local node = techage.get_node_lvm(pos)
switch_off(pos, node)
return 0
elseif topic == 70 then
elseif topic == 70 or topic == 22 then
local node = techage.get_node_lvm(pos)
switch_on(pos, node, nil, payload[1])
return 0