View difference between Paste ID: ffzGEuEb and Qjq5n70e
SHOW: | | - or go back to the newest paste.
1
local aspectCountValue = 64 -- change to 0 for the turtle at the farm
2
3
while true do
4
  local m = peripheral.wrap("front")
5
  if m ~= nil then
6-
    if aspectCount == 64 then
6+
7-
      print("Jar is full, sending redstone signal.")
7+
8-
      redstone.setOutput("back", true)
8+
    if aspectCount == aspectCountValue then
9-
      sleep(20)
9+
      print("Jar is full, sending to farm.")
10-
      print("Stopping redstone signal.")
10+
      turtle.dig() 
11-
      redstone.setOutput("back", false)
11+
12
      print("Jar isn't full. It only has " .. aspectCount .. ".")
13
    end
14
  else 
15
    print("No Jar, check again in 60.")
16
  end
17
  sleep(60)
18
end