Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- os.loadAPI("button")
- m = peripheral.wrap("top")
- m.clear()
- function fillTable()
- button.setTable("Test 1", test1, 10, 20, 3, 5)
- button.setTable("Test 2", test2, 22, 32, 3, 5)
- end
- function getClick()
- event, side, x, y = os.pullEvent("monitor_touch")
- button.checkxy(x, y)
- end
- function test1()
- m.setCursorPos(1, 1)
- m.write("test1")
- end
- function test2()
- m.setCursorPos(1, 1)
- m.write("test1")
- end
- while true do
- getClick()
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement