Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- while true do
- local monitor = peripheral.find("monitor")
- local sx,sy = monitor.getSize()
- local drinks = ["Apple","Coffee","Coffee with milk","Strawberry iced coffee"]
- local eventData = {os.pullEvent()}
- local event = eventData[1]
- if event == "monitor_touch" then
- print("Monitor was clicked at", eventData[4]," ", eventData[3])
- elseif event == "key" then
- print("Key code", eventData[2], "was pressed")
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement