SHARE
TWEET

ComputerCraft Tutorial: monitor_test0_1

hevohevo Jan 5th, 2014 399 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. -- ##################################
  2. -- monitor_test
  3. -- version 0.1
  4. -- http://hevohevo.hatenablog.com/
  5.  
  6. r_mon=peripheral.wrap("right")
  7.  
  8. while true do
  9.   local event, side, x, y = os.pullEvent("monitor_touch")
  10.   r_mon.clear()
  11.  
  12.   if event == "monitor_touch" then
  13.     r_mon.setCursorPos(1,1)
  14.     r_mon.write(string.format("%s / %s / (%d, %d)", event, side, x, y))
  15.   end
  16. end
RAW Paste Data
Pastebin PRO Summer Special!
Get 40% OFF on Pastebin PRO accounts!
Top