Advertisement
MavricMC

turtle

Nov 28th, 2020 (edited)
173
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.57 KB | None | 0 0
  1. rednet.open("right")
  2. while true do
  3.     local ID, msg, did = rednet.receive()
  4.     if msg == "fwd" then
  5.         print("fwd")
  6.         turtle.forward()
  7.     end
  8.     if msg == "left" then
  9.         print("left")
  10.         turtle.turnLeft()
  11.     end
  12.     if msg == "right" then
  13.         print("right")
  14.         turtle.turnRight()
  15.     end
  16.     if msg == "back" then
  17.         print("back")
  18.         turtle.back()
  19.     end
  20.     if msg == "up" then
  21.         print("up")
  22.         turtle.up()
  23.     end
  24.     if msg == "down" then
  25.         print("down")
  26.         turtle.down()
  27.     end
  28. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement