Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --This works with the Extreme Reactors Reactor & Turbine. Just set the amount at wich the reactor should turn on/off
- local side = "back" -- the computer side where the computer is connected to the reactor or turbine (left/right/back/front/up/down)
- local energyAmountToStop = 800000 -- Amount for stopping the reactor
- local energyAmountToStart = 100000 -- Amount for starting the reactor
- local turbine = peripheral.wrap(side)
- while true do
- if(turbine.getEnergyStored() >= energyAmountToStop)then
- turbine.setActive(false)
- end
- if(turbine.getEnergyStored() <= energyAmountToStart)then
- turbine.setActive(true)
- end
- os.sleep(0.25)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement