Advertisement
cromulator

cc rednet pulse receiver

Jul 25th, 2014
221
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.42 KB | None | 0 0
  1. while true do -- makes the program loop
  2.     rednet.open("left") -- listens for rednet
  3.     id,message = rednet.receive() -- listens for rednet signal
  4.     if id == 33 and message == "asdf" then -- checks sender and message content, then does something
  5.         print("bonjourno!")
  6.         rs.setOutput("right", true) --sends the redstone signal and pulses it with sleep
  7.         sleep(3)
  8.         rs.setOutput("right", false)
  9.     end  -- needed
  10. end -- needed
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement