Nike622000

Timer

May 4th, 2016
153
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. --Timer--
  2.  
  3. --Zeit in Sekunden
  4. t = 2
  5. --Seite Inputs
  6. i = "left"
  7. --Seite Output
  8. o = "right"
  9.  
  10. if rs.getInput(i) then
  11. print("Timer tickt alle " .. t .. " Sekunden")
  12. print("Redstone Input ist " .. i .. " ")
  13. print("Redstone Output: " .. o .. " ")
  14. end
  15.  
  16. while true do
  17.  
  18. if rs.getInput(i) then
  19. redstone.setOutput(o, true)
  20. sleep(t)
  21. redstone.setOutput(o, false)
  22. sleep(t)
  23. end
  24. end
Advertisement
Add Comment
Please, Sign In to add comment