Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- startX = 728
- startY = 253
- startZ = -169
- function gotoChunkCenter()
- local x,y,z = gps.locate()
- while x ~= startX or z ~= startZ do
- print("Cur pos: "..x..", "..y..", "..z)
- if x ~= startX then
- if x > startX then
- turtle.back()
- else
- turtle.forward()
- end
- end
- turtle.turnRight()
- if z ~= startZ then
- if z > startZ then
- turtle.back()
- else
- turtle.forward()
- end
- end
- turtle.turnLeft()
- x,y,z = gps.locate()
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement