From 2e257a7b1eb7732c793c566b6530496c1a492cd8 Mon Sep 17 00:00:00 2001 From: itzmarkoni Date: Sat, 14 Jun 2025 12:34:13 -0400 Subject: [PATCH] updated --- temperature_monitor.lua | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/temperature_monitor.lua b/temperature_monitor.lua index 197506c..5e42d45 100644 --- a/temperature_monitor.lua +++ b/temperature_monitor.lua @@ -1,12 +1,11 @@ local function report() - local peripherals = peripheral.getNames() - for i, name in ipairs(peripherals) do - print("Peripheral " .. i .. ": " .. name) + local reactor = peripheral.find("fissionReactorLogicAdapter") + if reactor then + return reactor.getTemperature() + else + return "No reactor found" end - return "abc" - -- local reactor = peripheral.find("fissionReactorLogicAdapter") - -- return reactor.getTemerature() end return { report = report } \ No newline at end of file