Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- rednet.open("top")
- rsSide = "right"
- while true do
- local id, msg = rednet.receive()
- print(msg)
- if msg == "rainoff" then
- if rs.getInput("back", true) then
- print("received command")
- rs.setOutput(rsSide, true)
- sleep(1)
- rs.setOutput(rsSide, false)
- rednet.send(id, "done")
- print("done")
- else
- print("received command")
- print("not raining")
- rednet.send(id, "norain")
- print("done")
- end
- end
- sleep(0.1)
- end
RAW Paste Data