Advertisement
Guest User

startup

a guest
Aug 27th, 2014
143
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.54 KB | None | 0 0
  1. os.loadAPI("button")
  2. m=peripheral.wrap("right")
  3. m.clear()
  4.  
  5. function gotoln()
  6. local x, y = m.getCursorPos()
  7. if y1 == y then
  8. m.scroll()
  9. m.setCursorPos(1, y)
  10. else
  11. m.setCursorPos(1, y+1)
  12. end
  13. end
  14.  
  15. function button1() button.toggleButton("Courant")
  16. m.write("Courant change")
  17. sleep(1)
  18. button.toggleButton("Courant")
  19. end
  20.  
  21. function ecran()
  22. button.setTable("Courant",button1,8,25,3,3)
  23. button.screen()
  24. end
  25.  
  26. function getClick()
  27. event,side,x,y = os.pullEvent("monitor_touch")
  28. button.checkxy(x,y)
  29. end
  30.  
  31. ecran()
  32.  
  33. while true do getClick() end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement