Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local minimum = 25
- local maximum = 75
- while true do
- local reactor = peripheral.wrap("BigReactors-Reactor_1")
- local display = peripheral.wrap("monitor_0")
- local power = reactor.getEnergyStored()
- local maxenergy = 10000000
- local percent = (power / 10000000) * 100
- if percent < minimum then
- reactor.setActive(true)
- elseif percent > maximum then
- reactor.setActive(false)
- end
- term.setCursorPos(1,1)
- term.clear()
- display.clear()
- display.setCursorPos(1,1)
- print("Reactor Internal Buffer(RF)")
- print(power, "RF")
- print("")
- print("Reactor Internal Buffer(%)")
- print(math.floor(percent), "%")
- print("")
- print("Is This Reactor Currently On?")
- print(reactor.getActive())
- display.write("Reactor Internal Buffer(RF)")
- display.setCursorPos(1,2)
- display.write(power, "RF")
- display.setCursorPos(1,4)
- display.write("Reactor Internal Buffer(%)")
- display.setCursorPos(1,5)
- display.write(math.floor(percent), "%")
- display.setCursorPos(1,7)
- display.write("Is This Reactor Currently On?")
- display.setCursorPos(1,8)
- display.write(reactor.getActive())
- sleep(0.5)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement