Advertisement
Pandana

Untitled

Feb 10th, 2022
848
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local dest={"End", "Home"}
  2.  
  3. for i=1, 2, 1 do
  4.     print(dest[i])
  5. end
  6.  
  7. local tp=io.read()
  8.  
  9. rednet.open("back")
  10.  
  11. if tp==dest[1] then
  12.     term.clear()
  13.     term.setCursorPos(1, 1
  14.     print("Teleporting to", dest[1])
  15.     rednet.send(00, "tp")
  16.     sleep(2)
  17.     term.clear()
  18. elseif tp==dest[2] then
  19.     term.clear()
  20.     term.setCursorPos(1, 1)
  21.     print("Teleporting to", dest[2], "sweet", dest[2])
  22.     rednet.send(01, "tp")
  23.     sleep(2)
  24.     term.clear()
  25. else
  26.     term.clear()
  27.     term.setCursorPos(1, 1)
  28.     print("Unknown Destination")
  29.     sleep(2)
  30. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement