Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local idChannel = 124
- rs.setOutput("back", false)
- rs.setOutput("right", false)
- modem = peripheral.wrap("left")
- while true do
- modem.open(idChannel)
- event, modemSide, senderChannel, replyChannel, text, senderDistance = os.pullEvent("modem_message")
- if text == "grinder" then
- rs.setOutput("back", true)
- rs.setOutput("right", true)
- sleep(6)
- rs.setOutput("right", false)
- elseif text == "ouvre" then
- rs.setOutput("back", false)
- end
- modem.close(idChannel)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement