Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function listen()
- rednet.open("left")
- while true do
- local sender, message, protocol = rednet.receive()
- if message == "ping" then
- broadcastGPS()
- end
- end
- end
- function broadcastGPS()
- rednet.open("left")
- local a = vector.new(gps.locate())
- --rednet.broadcast("gps: "..a.x.." "..a.y.." "..a.z)
- rednet.broadcast(a)
- end
- listen()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement