Advertisement
Guest User

Untitled

a guest
Apr 23rd, 2019
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. var i = 0
  2.  
  3. onevent buttons
  4.  
  5.  
  6.  
  7. if i < 0 and i < 32 then
  8. call leds.top(32,0,0)
  9. else
  10. call leds.top(0,32,0)
  11. end
  12. if button.left ==1 then
  13. i = i-1
  14. end
  15. if button.right ==1 then
  16. i =i+1
  17. end
  18.  
  19. if button.left == 1 or button.right ==1 then
  20. call leds.top(0,32,0)
  21. call leds.circle(i,i,i,i,i,i,i,i)
  22.  
  23. elseif button.center == 1 then
  24. call leds.top (0,0,32)
  25. if button.forward ==1 or button.backward ==1 then
  26. call leds.top(32,0,0)
  27. end
  28.  
  29. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement