Advertisement
Guest User

ControlloBarre

a guest
Jan 23rd, 2017
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1.  
  2. local count = 0
  3. local lastInput = false
  4.  
  5. while true do
  6. os.pullEvent("redstone")
  7. local input = rs.getInput(left)
  8. if input ~= lastInput then
  9. if input then
  10. term.clear()
  11. count = count + 10
  12. print(count)
  13. end
  14. lastInput = input
  15. end
  16. end
  17.  
  18.  
  19. while true do
  20. os.pullEvent("redstone")
  21. local input = rs.getInput(right)
  22. if input ~= lastInput then
  23. if input then
  24. term.clear()
  25. count = count - 10
  26. print(count)
  27. end
  28.  
  29. end
  30. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement