Advertisement
Namentis

Porte_computercraft_elevator

Feb 19th, 2015
163
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.43 KB | None | 0 0
  1. os.loadAPI("button")
  2. m = peripheral.wrap("left")
  3. m.clear()
  4.  
  5. function button1() button.toggleButton("Appel")
  6. rs.setOutput("top", true)
  7. sleep(2)
  8. rs.setOutput("top", false)
  9. button.toggleButton("Appel")
  10. end
  11.  
  12. function ecran()
  13. button.setTable("Appel",button1,1,7,1,5)
  14. button.screen()
  15. end
  16.  
  17. function getClick()
  18. event,side,x,y = os.pullEvent("monitor_touch")
  19. button.checkxy(x,y)
  20. end
  21.  
  22. ecran()
  23.  
  24. while true do getClick() end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement