Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function gets()
- while true do
- local resa = http.get("http://paitorocxon.bplaced.net/cc").readAll()
- local checked = http.get("http://paitorocxon.bplaced.net/ccengine.php?check=1").readAll()
- write("'"..resa.."'")
- local fil = fs.open("tmp", "w")
- fil.write(resa)
- fil.close()
- local ret = fs.open("tmp", "r")
- if resa == "back" then
- turtle.back(1)
- elseif resa == "dig" then
- turtle.dig()
- elseif resa == "fore" then
- turtle.forward(1)
- elseif resa == "left" then
- turtle.turnLeft(1)
- elseif resa == "right" then
- turtle.turnRight(1)
- elseif resa == "up" then
- turtle.up(1)
- elseif resa == "down" then
- turtle.down(1)
- elseif resa == "digdown" then
- turtle.digDown()
- elseif resa == "digup" then
- turtle.digUp()
- elseif resa == "exit" then
- break
- end
- os.sleep(0.5)
- end
- end
- gets()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement