Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function getTankAmount()--{{{
- local tank = peripheral.wrap("back")
- return tank.getTanks("unknown")[1].amount
- end--}}}
- while true do
- os.startTimer(60)
- event, param1, param2, param3 = os.pullEvent("timer")
- amount = getTankAmount()
- if amount > 800000 then
- rs.setOutput("left", true)
- else
- rs.setOutput("left", false)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement