Advertisement
AwesomeSorcery

rednetmonitor

Jul 17th, 2018
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.29 KB | None | 0 0
  1. local monitor = peripheral.wrap("left")
  2.  
  3. while true do
  4. print("Listening")
  5. rednet.open("right")
  6. event,id,message,distance = os.pullEvent("rednet_message")
  7. print(id)
  8. if id == 5 then
  9. monitor.clear()
  10. monitor.setCursorPos(1,1)
  11. monitor.write(message)
  12. end
  13. rednet.close("right")
  14. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement