Advertisement
LOLROW

Untitled

Jul 15th, 2022 (edited)
24
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.19 KB | None | 0 0
  1. --> Phone / mainstation whatever unga bunga monga dunga
  2. rednet.open("back")
  3.  
  4. mainTurtleID = 36 --> Set to your turtle's id
  5.  
  6. print("[1]: Goto, [2]: Deploy, [3]: Set Turtle ID")
  7.  
  8. local function GetCommand()
  9. local cmd = io.read()
  10.  
  11. if (tonumber(cmd) == 1) then
  12. rednet.send(mainTurtleID, "comeback", "roombaNET-1")
  13.  
  14. for i = 0, 2, 1 do --> Take in x, y, and z and send it to the turtle.
  15. local coord = io.read()
  16. rednet.send(mainTurtleID, coord, "roombaNET-1")
  17. end
  18. end
  19. if (tonumber(cmd) == 2) then
  20. print("[1]: Mining turtle, [2]: Attack Turtle")
  21.  
  22. if (tonumber(cmd) == 1) then
  23. rednet.send(mainTurtleID, "mine", "roombaNET-1")
  24. end
  25. if (tonumber(cmd) == 2) then
  26. rednet.send(mainTurtleID, "attack", "roombaNET-1")
  27. local targetComputerID = io.read() --> The attack turtle will just sit at someones computer and wait for somone.
  28. rednet.send(mainTurtleID, targetComputerID, "roombaNET-1")
  29. end
  30. end
  31. if (tonumber(cmd) == 3) then
  32. print("Turtle ID: ")
  33. local turtleID = io.read()
  34. mainTurtleID = turtleID
  35. end
  36. end
  37. GetCommand()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement