Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local r = peripheral.wrap("right")
- local max = 9000000
- local min = 50000
- function Loop()
- while true do
- monitorReactor()
- renderStatus()
- os.sleep(50)
- end
- end
- function monitorReactor()
- if (r.getActive() == true) then
- if (r.getEnergyStored() >= max) then
- r.setActive(false)
- print("Disabling")
- end
- else
- if (r.getEnergyStored() <= min) then
- r.setActive(true)
- print("Enabling")
- end
- end
- end
- function renderStatus()
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement