Advertisement
CelticCoder

templatedelete

Aug 9th, 2024 (edited)
13
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.74 KB | None | 0 0
  1. --opens the current modem on the computer (specifying the modem is on top) to send/receive messages
  2. --directions include: top, bottom, left, right, front and back
  3. rednet.open("top")
  4.  
  5. --Sends a string message over rednet to computer 3 (this message specifically asks the server for all sellable items on ATM Machines)
  6. rednet.send(3, "items please")
  7.  
  8. -- Receives a message from any sources sending a message to this computer (and/or broadcasting to all computers in range)
  9. -- rednet.Recieve() will return an id and a message sent to the computer
  10. -- (parameter tells rednet to wait 5 seconds? (tick? I am pretty sure its seconds), if no response will return nil, if no parameter is specified it will infinitely wait)
  11. id, itemlist = rednet.recieve(5)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement