Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local senderId, message, distance
- function netClose()
- rednet.close("right")
- end
- function netOpen()
- netClose()
- rednet.open("right")
- end
- function getData()
- senderId, message, distance = rednet.receive()
- end
- while true do
- netOpen()
- getData()
- if message == open then
- redstone.setOutput("top", true)
- else
- redstone.setOutput("top", false)
- end
- sleep(1)
- end
Advertisement
Add Comment
Please, Sign In to add comment