SHOW:
|
|
- or go back to the newest paste.
1 | i=0 | |
2 | while true do | |
3 | if redstone.getInput("left") then | |
4 | SpawnWither() | |
5 | turtle.down() | |
6 | turtle.down() | |
7 | sleep(10) | |
8 | turtle.up() | |
9 | turtle.up() | |
10 | else | |
11 | sleep(10) | |
12 | end | |
13 | if turtle.getFuelLevel()<10000 then | |
14 | print "Low Fuel" | |
15 | end | |
16 | end | |
17 | ||
18 | - | funcion SpawnWither() |
18 | + | function SpawnWither() |
19 | Forward(7) | |
20 | turtle.turnLeft() | |
21 | turtle.select(1) | |
22 | turtle.place() | |
23 | turtle.up() | |
24 | turtle.place() | |
25 | PlaceOnRight() | |
26 | PlaceOnLeft() | |
27 | turtle.up() | |
28 | turtle.select(2) | |
29 | PlaceOnRight() | |
30 | PlaceOnLeft() | |
31 | turtle.place() | |
32 | turtle.down() | |
33 | turtle.down() | |
34 | turtle.turnLeft() | |
35 | Forward(7) | |
36 | turtle.turnLeft() | |
37 | turtle.turnLeft() | |
38 | Pickup() | |
39 | end | |
40 | ||
41 | function Forward(i) | |
42 | while i>0 do | |
43 | turtle.forward() | |
44 | i=i-1 | |
45 | end | |
46 | end | |
47 | ||
48 | function PlaceOnLeft() | |
49 | turtle.turnLeft() | |
50 | turtle.forward() | |
51 | turtle.turnRight() | |
52 | turtle.place() | |
53 | turtle.turnRight() | |
54 | turtle.forward() | |
55 | turtle.turnLeft() | |
56 | end | |
57 | ||
58 | function PlaceOnRight() | |
59 | turtle.turnRight() | |
60 | turtle.forward() | |
61 | turtle.turnLeft() | |
62 | turtle.place() | |
63 | turtle.turnLeft() | |
64 | turtle.forward() | |
65 | turtle.turnRight() | |
66 | end | |
67 | ||
68 | function Pickup() | |
69 | redstone.setOutput("back",true) | |
70 | sleep(0.2) | |
71 | redstone.setOutput("back",false) | |
72 | sleep(120) | |
73 | Forward(7) | |
74 | turtle.turnLeft() | |
75 | turtle.select(3) | |
76 | turtle.place() | |
77 | turtle.sleep(0.5) | |
78 | turtle.dig() | |
79 | turtle.turnLeft() | |
80 | Forward(7) | |
81 | turtle.turnLeft() | |
82 | turtle.turnLeft() | |
83 | end |