SHOW:
|
|
- or go back to the newest paste.
1 | chest=peripheral.wrap("left") | |
2 | colors={ | |
3 | 1,2,4,8,16,32,64,128,256,512,1024,2048,4096,8192,16384,32768 | |
4 | } | |
5 | args={ ... } | |
6 | - | for i=i,27 do |
6 | + | if args[1]==nil then |
7 | - | slotContent=getStackInSlot(i) |
7 | + | args={1,1,1} |
8 | - | content=content+slotContent |
8 | + | |
9 | ||
10 | - | sleep(1) |
10 | + | |
11 | repeat | |
12 | - | |
12 | + | |
13 | for i=1,27 do | |
14 | slotContent=chest.getStackInSlot(i) | |
15 | if slotContent==nil then | |
16 | - | colorL,colorM,colorR=getColors() |
16 | + | content=content |
17 | - | for i=1,16 do |
17 | + | else |
18 | - | colorL=i |
18 | + | content=content+1 |
19 | - | for i=1,16 do |
19 | + | |
20 | - | colorM=i |
20 | + | |
21 | - | for i=1,16 do |
21 | + | if content>0 then |
22 | - | colorR=i |
22 | + | sleep(1) |
23 | end | |
24 | until content<=0 | |
25 | return content | |
26 | end | |
27 | ||
28 | - | end |
28 | + | |
29 | colorL,colorM,colorR=chest.getColors() | |
30 | for i=0+tonumber(args[1]),16 do | |
31 | colorL=colors[i] | |
32 | for i=0+tonumber(args[2]),16 do | |
33 | colorM=colors[i] | |
34 | for i=0+tonumber(args[3]),16 do | |
35 | colorR=colors[i] | |
36 | chest.setColours(colorL,colorM,colorR) | |
37 | checkContents() | |
38 | end | |
39 | end | |
40 | end | |
41 | end | |
42 | ||
43 | colorCycle() |