Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- while true do
- local reactor1 = peripheral.wrap("BigReactors-Reactor_82")
- local mon = peripheral.wrap("monitor_317")
- local low = 100000
- local high = 800000
- local full = 999000
- if reactor1.getEnergyStored() <= low then
- reactor1.setAllControlRodLevels(20)
- if reactor1.getActive() == false then
- reactor1.setActive(true)
- end
- else
- if reactor1.getEnergyStored() < high then
- reactor1.setAllControlRodLevels(20)
- end
- end
- if reactor1.getEnergyStored() >= full then
- reactor1.setActive(false)
- else
- if reactor1.getEnergyStored() >= high then
- reactor1.setAllControlRodLevels(90)
- reactor1.setActive(true)
- end
- end
- mon.clear()
- mon.setCursorPos(1,1)
- mon.write("On: ")
- mon.write(reactor1.getActive())
- mon.setCursorPos(1,2)
- mon.write("CHeat: ")
- mon.write(math.floor(reactor1.getCasingTemperature()))
- mon.setCursorPos(1,3)
- mon.write("FHeat: ")
- mon.write(math.floor(reactor1.getFuelTemperature()))
- mon.setCursorPos(1,4)
- mon.write("RF: ")
- mon.write(math.floor(reactor1.getEnergyStored()))
- sleep(10)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement