Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local REG_TRACK_COUNT = 37
- function regTrack()
- turtle.select(1)
- for i = 1, REG_TRACK_COUNT do
- if turtle.detect() == true then
- print("regTrack: Block in the way")
- return false
- else
- print("regTrack: moving forward.")
- turtle.forward()
- print("regTrack: laying track.")
- turtle.placeDown(1)
- end
- end
- return true
- end
- turtle.up()
- for i=1, 5 do
- if regTrack() == true then
- print("Reg track complete.")
- else
- print("Reg track error.")
- end
- end
Add Comment
Please, Sign In to add comment