This commit is contained in:
2025-06-14 13:06:15 -04:00
parent d979871c48
commit 1b7b0a17b7
2 changed files with 2 additions and 4 deletions

View File

@@ -1,12 +1,13 @@
local function report(reactor) local function report(reactor)
if reactor then if reactor then
return reactor.getCoolantFilledPercentage() return (reactor.getCoolantFilledPercentage() or 0) * 100
else else
return "No reactor found" return "No reactor found"
end end
end end
local function watch(reactor, monitor) local function watch(reactor, monitor)
local coolantLevel =
print("Coolant: " .. report(reactor)) print("Coolant: " .. report(reactor))
sleep(1) sleep(1)
end end

View File

@@ -8,7 +8,6 @@ local function runMonitors()
while true do while true do
tempDriver.watch(reactor, monitor) tempDriver.watch(reactor, monitor)
coolantDriver.watch(reactor, monitor) coolantDriver.watch(reactor, monitor)
sleep(1)
end end
end end
@@ -26,8 +25,6 @@ local function runDisplay()
monitor.write(item.Label .. ": " .. item.value) monitor.write(item.Label .. ": " .. item.value)
monitor.setCursorPos(1, i + 1) monitor.setCursorPos(1, i + 1)
end end
sleep(1)
end end
end end