Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local time = os.time()
- while true do
- time = os.time()
- rs.setOutput("back",false)
- rs.setOutput("left",false)
- rs.setOutput("front",false)
- rs.setOutput("right",false)
- if time > 0 then <-- midnight
- if time < 3 then
- rs.setOutput("back",true)
- end
- end
- if time > 3 then
- if time < 6 then
- rs.setOutput("right",true)
- end
- end
- if time > 6 then
- if time < 9 then
- rs.setOutput("front",true)
- end
- end
- if time > 9 then -- sunrise
- if time < 12 then
- rs.setOutput("left",true)
- end
- end
- sleep(1)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement