Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local name = "joey" -- ascii only
- local uri = "https://discor"
- print("Warpdrive security active!")
- while true do
- local p = peripheral.find("warpdriveAirGenerator")
- local x,y,z = p.getLocalPosition()
- local text = x .. " "..y.." "..z
- local oldText = ""
- if fs.exists(".lastpos") then
- local f = fs.open(".lastpos","r")
- oldText = f.readAll()
- f.close()
- end
- if oldText ~= text then
- local f2 = fs.open(".lastpos","w")
- f2.write(text)
- http.post(uri,"{\"content\":\""..name..": "..text.."\"}",{['content-type']="application/json"})
- f2.close()
- end
- sleep(10)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement