Advertisement
ElijahCrafter

Untitled

Mar 26th, 2025
221
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.34 KB | None | 0 0
  1. local IDENTIFIER = user
  2. local DELAY_TIME = 60
  3.  
  4. local function main_loop()
  5.   while true do
  6.     local x, y, z = gps.locate()
  7.     peripheral.call("back", "transmit", 1500, 1500, {identifier = IDENTIFIER, x, y, z})
  8.     sleep(DELAY_TIME)
  9.   end
  10. end
  11.  
  12. local function _shell()
  13.   shell.run("shell")
  14. end
  15.  
  16. parallel.waitForAny(main_loop, _shell)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement