Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- GPS BEACON
- -- Replace these with THIS computer's block coordinates.
- local X = 100
- local Y = 100
- local Z = 100
- -- Find an attached Ender Modem.
- local modem = peripheral.find("modem", function(name, m)
- return m.isWireless()
- end)
- if not modem then
- error("No wireless/Ender modem found!")
- end
- print("GPS Beacon Online")
- print(("Position: %d, %d, %d"):format(X, Y, Z))
- print("Waiting for GPS requests...")
- -- Start the built-in GPS host.
- shell.run("gps", "host", X, Y, Z)
Advertisement