dubbleM

Piston Door 3x3

Jun 21st, 2013
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.88 KB | None | 0 0
  1. ticks = 0.2
  2.  
  3. function close()
  4. rs.setOutput("bottom", true)
  5. rs.setBundledOutput("top", colors.orange)
  6. sleep(ticks)
  7. rs.setBundledOutput("top", 0)
  8. sleep(ticks)
  9. rs.setBundledOutput("top", colors.white)
  10. sleep(ticks)
  11. rs.setBundledOutput("top", colors.white+colors.magenta)
  12. end
  13.  
  14. function open()
  15. rs.setBundledOutput("top", colors.white)
  16. sleep(ticks)
  17. rs.setBundledOutput("top", 0)
  18. sleep(ticks)
  19. rs.setBundledOutput("top", colors.orange)
  20. sleep(ticks)
  21. rs.setBundledOutput("top", colors.orange+colors.magenta)
  22. sleep(ticks)
  23. rs.setBundledOutput("top", colors.orange)
  24. sleep(ticks)
  25. rs.setBundledOutput("top", 0)
  26. sleep(ticks)
  27. rs.setBundledOutput("top", colors.magenta)
  28. sleep(ticks)
  29. rs.setBundledOutput("top", 0)
  30. rs.setOutput("bottom", false)
  31. end
  32.  
  33. while true do
  34.  
  35. if rs.getInput("left", true) then
  36. function open()
  37. else
  38. function close()
  39. end
  40.  
  41. end
Advertisement
Add Comment
Please, Sign In to add comment