View difference between Paste ID: LEctauaV and QmW9emr2
SHOW: | | - or go back to the newest paste.
1
function movetotree()
2
   for i=1,7 do
3
      turtle.forward()
4
   end
5
end
6
7
function drop()
8
   for d=1,15 do
9
      turtle.select(i)
10
      turtle.dropDown()
11
   end
12
end
13
14
function cut()
15
   while true do
16
      if not turtle.digUp() then
17
      turtle.up()
18
      else turtle.back()
19
      break
20
      end
21
   end
22
end
23
24
function movetodrop()
25
   for g=1,7 do
26
      turtle.back()
27
   end
28
end
29
30
function refuel()
31
   if (turtle.getFuel()=="Unlimited") then
32
      end
33
   else turtle.select(16)
34
   turtle.suck()
35
   turtle.refuel(64)
36
   turtle.select(1)
37
end
38
39
function plant()
40
   turtle.select(15)
41
   turtle.place()
42
   turtle.select(1)
43
end
44
45
function saplings()
46
   turtle.select(15)
47
   turtle.suckRight()
48
   turtle.select(1)
49
end
50
51
while true do
52
   refuel()
53
   saplings()
54
   movetotree()
55
   for z=1,64 do
56
      plant()
57
      sleep(180)
58
      cut()
59
   end
60
   movetodrop()
61
   drop()
62
end