Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- TIME = 300 -- input your time (in seconds)
- running = true
- while running do
- local time = TIME
- while time > 0 do
- print(time.." seconds remaining")
- local first = os.startTimer(1)
- while true do
- local event, timerID = os.pullEvent("timer")
- if timerID == first then
- time = time - 1
- break
- end
- end
- end
- local second = os.startTimer(1)
- rs.setAnalogOutput("left", 15)
- while true do
- local event, timerID = os.pullEvent("timer")
- if timerID == second then
- break
- end
- end
- rs.setAnalogOutput("left", 0)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement