Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Loosely based on http://pastebin.com/y8vXg8ew
- function chop()
- turtle.select(1)
- -- Up one side
- while turtle.compareUp() do
- turtle.dig()
- turtle.digUp()
- turtle.up()
- end
- turtle.dig()
- -- Go to the other side
- turtle.turnRight()
- turtle.dig()
- turtle.turnLeft()
- -- Down other side
- turtle.dig()
- turtle.digDown()
- turtle.down()
- -- Check for more
- turtle.turnLeft()
- if turtle.compare() then
- turtle.dig()
- turtle.forward()
- turtle.turnRight()
- while turtle.compareUp() do
- turtle.dig()
- turtle.digUp()
- turtle.up()
- end
- turtle.dig()
- turtle.up()
- end
- end
- function orient()
- turtle.turnLeft()
- if not turtle.detect() then
- turtle.turnRight()
- end
- end
- print("Welcome to Portablejim's")
- print("giant redwood cutting program")
- print(" ")
- print("Replace a redwood log with the turtle")
- print("and place the log in slot 1")
- print(" ")
- print("Hit enter when ready")
- read()
- chop()
Add Comment
Please, Sign In to add comment