Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local s1 = -1;
- local s2 = -1;
- local done1 = false;
- local done2 = false;
- local w1,w2,w3,w4,w5,w1b,w2b,w3b,w4b,w5b
- while true do
- os.startTimer(3)
- os.pullEvent("timer")
- w1 = commands.testforblock("715 71 632 wool 14")
- w2 = commands.testforblock("723 71 649 wool 14")
- w3 = commands.testforblock("715 71 681 wool 14")
- w4 = commands.testforblock("719 71 692 wool 14")
- w5 = commands.testforblock("723 71 662 wool 14")
- if w1~=w1b or w2~=w2b or w3~=w3b or w4~=w4b or w5~=w5b then
- if w1==false and w2==false and s1~=2 and done1==false then
- commands.clone("1067 68 639 1066 72 639 714 79 624") --grün-gelb
- s1 = 2
- done1 = true
- elseif w1==true and w3==false and s1~=0 and done1==false then
- commands.clone("1073 75 648 1072 72 648 714 79 624") --rot
- s1 = 0
- done1 = true
- elseif w1==false and w2==true and s1~=0 and done1==false then
- commands.clone("1073 75 648 1072 72 648 714 79 624") --rot
- s1 = 0
- done1 = true
- elseif w1==true and w3==true and w4==true and s1~=1 and done1==false then
- commands.clone("1073 68 639 1072 72 639 714 79 624") --grün
- s1 = 1
- done1 = true
- elseif w1==true and w3==true and w4==false and s1~=2 and done1==false then
- commands.clone("1067 68 639 1066 72 639 714 79 624") --grün-gelb
- s1 = 2
- done1 = true
- end
- if w2==true and w5==true and s2~=1 and done2==false then
- commands.clone("1073 68 639 1072 72 639 718 79 626") --grün
- s2 = 1
- done2 = true
- elseif w2==false and s2~=0 and done2==false then
- commands.clone("1073 75 648 1072 72 648 718 79 626") --rot
- s2 = 0
- done2 = true
- elseif w2==true and w5==false and w3==false and w4==true and s2~=2 and done2==false then
- commands.clone("1067 68 639 1066 72 639 718 79 626") --grün-gelb
- s2 = 2
- done2 = true
- elseif w2==true and w5==false and w3==false and w4==false and s2~=2 and done2==false then
- commands.clone("1067 68 639 1066 72 639 718 79 626") --grün-gelb
- s2 = 2
- done2 = true
- elseif w2==true and w5==false and w3==true and s2~=2 and done2==false then
- commands.clone("1073 75 648 1072 72 648 718 79 626") --rot
- s2 = 2
- done2 = true
- end
- done1 = false
- done2 = false
- w1b = w1
- w2b = w2
- w3b = w3
- w4b = w4
- w5b = w5
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement