Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --put blocks in the inventory of the turtle and specefie how far he needs to go when you start the program
- --remember to put enough fuel before starting
- local tArgs = {...}
- rtrn = 0
- afst = 0
- sel = 0
- if #tArgs~=1 then
- print("not enough info please specefie length")
- end
- lengte = tonumber(tArgs[1])
- function info()
- print("fuel: "..turtle.getFuelLevel())
- print("length: "..lengte)
- print("made by wv1106 on reddit and pastebin")
- end
- function move()
- if turtle.forward() then
- afst = afst + 1
- end
- end
- function place()
- if not turtle.detectDown() then
- while not turtle.placeDown() do
- sel = sel + 1
- turtle.select(sel)
- end
- end
- end
- --here starts ectual code
- info()
- for i=1,lengte do
- move()
- place()
- end
- turtle.turnLeft()
- turtle.turnLeft()
- for i=1,afst do
- if not turtle.forward() then
- turtle.attack()
- end
- end
- print("finished!")
Add Comment
Please, Sign In to add comment