Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- sides={"top","bottom","back","front","left","right"}
- for i=1,6 do if peripheral.getType(sides[i]) == "modem" then rednet.open(sides[i]) end end
- message="talk1"
- function send()
- rednet.broadcast(io.read())
- end
- function recieve()
- e,modemSide,channel,id,modemMessage =os.pullEvent("modem_message")
- print(id.." : "..modemMessage)
- end
- while true do
- parallel.waitForAny(recieve,send)
- end
Add Comment
Please, Sign In to add comment