buttercheetah

Game system Slave

Aug 5th, 2021
1,149
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local component = require("component")
  2. local event = require("event")
  3. local gpu = component.gpu -- get primary gpu component
  4. local m = component.modem -- get primary modem component
  5. m.open(1)
  6. print(m.isOpen(1)) -- true
  7. os.sleep(5)
  8. gpu.setResolution(4, 2)
  9. -- Send some message.
  10. -- Wait for a message from another network card.
  11. while (1==1) do
  12.   local _, _, from, port, _, message = event.pull("modem_message")
  13.   os.execute("cls")
  14.   print(tostring(message))
  15. end
RAW Paste Data