diff --git a/README.md b/README.md index 69914bd..42ee4f0 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ In contrast to TechPack, the resources are more limited and it is much more diff ### License -Copyright (C) 2019-2021 Joachim Stolberg +Copyright (C) 2019-2022 Joachim Stolberg Code: Licensed under the GNU AGPL version 3 or later. See LICENSE.txt Textures: CC BY-SA 3.0 @@ -80,6 +80,9 @@ Available worlds will be converted to 'lsqlite3', but there is no way back, so: ### History +**2022-01-22 V1.07** +- TA5 fusion reactor added + **2022-01-03 V1.06** - TA5 teleport blocks added - Many improvements diff --git a/fusion_reactor/controller.lua b/fusion_reactor/controller.lua index ed10b82..31f0401 100644 --- a/fusion_reactor/controller.lua +++ b/fusion_reactor/controller.lua @@ -91,7 +91,7 @@ sched.register(tSched, CALL_RATE1, 3, function(pos, outdir) sched.register(tSched, CALL_RATE2, 4, function(pos, outdir) local resp = control.request(pos, Cable, outdir, "con", "inc_power") local cnt = count_trues(resp) - print("inc_power", cnt) + --print("inc_power", cnt) if cnt < 52 then return S("Cooling failed") end diff --git a/fusion_reactor/generator.lua b/fusion_reactor/generator.lua index 87c06c9..cd78b5c 100644 --- a/fusion_reactor/generator.lua +++ b/fusion_reactor/generator.lua @@ -17,6 +17,7 @@ local S = techage.S local Cable = techage.ElectricCable local power = networks.power +local control = networks.control local CYCLE_TIME = 2 local PWR_PERF = 800 @@ -172,6 +173,27 @@ techage.register_node({"techage:ta5_generator", "techage:ta5_generator_on"}, { end, }) +control.register_nodes({"techage:ta5_generator", "techage:ta5_generator_on"}, { + on_receive = function(pos, tlib2, topic, payload) + end, + on_request = function(pos, tlib2, topic) + if topic == "info" then + local nvm = techage.get_nvm(pos) + local meta = M(pos) + return { + type = S("TA5 Generator"), + number = "-", + running = (nvm.alive_cnt or 0) > 0, + available = PWR_PERF, + provided = nvm.provided or 0, + termpoint = meta:get_string("termpoint"), + } + end + return false + end, + } +) + minetest.register_craft({ output = "techage:ta5_generator", recipe = { diff --git a/fusion_reactor/heatexchanger2.lua b/fusion_reactor/heatexchanger2.lua index 832782e..3d52c79 100644 --- a/fusion_reactor/heatexchanger2.lua +++ b/fusion_reactor/heatexchanger2.lua @@ -111,7 +111,7 @@ sched.register(tSched, CALL_RATE1, 3, function(pos) sched.register(tSched, CALL_RATE2, 4, function(pos) local resp = heatexchanger3_cmnd(pos, "dec_power") local cnt = count_trues(resp) - print("dec_power", cnt) + --print("dec_power", cnt) if cnt < 52 then return 0 end @@ -217,7 +217,7 @@ end local function node_timer(pos, elapsed) local nvm = techage.get_nvm(pos) nvm.temperature = nvm.temperature or 0 - print("node_timer", nvm.temperature) + --print("node_timer", nvm.temperature) if consume_power(pos, nvm) then if steam_management(pos, nvm) then State:keep_running(pos, nvm, COUNTDOWN_TICKS) diff --git a/init.lua b/init.lua index 8e8accd..7674ca0 100644 --- a/init.lua +++ b/init.lua @@ -13,7 +13,7 @@ techage = {} -- Version for compatibility checks, see readme.md/history -techage.version = 1.06 +techage.version = 1.07 if minetest.global_exists("tubelib") then minetest.log("error", "[techage] Techage can't be used together with the mod tubelib!") diff --git a/items/ceramic.lua b/items/ceramic.lua index f94e57f..5bdcad6 100644 --- a/items/ceramic.lua +++ b/items/ceramic.lua @@ -64,6 +64,14 @@ minetest.register_craftitem("techage:ta5_ceramic_turbine", { inventory_image = "techage_ceramic_turbine.png", }) +techage.furnace.register_recipe({ + output = "techage:ta4_round_ceramic 2", + recipe = { + "techage:ta4_ceramic_material", "techage:ta4_ceramic_material", + "techage:ta4_ceramic_material", "techage:ta4_ceramic_material", + }, + time = 16, +}) techage.furnace.register_recipe({ output = "techage:ta5_ceramic_turbine",