All pastes #3185585 Raw Edit

Xp Farm Programs v2

public unlisted lua v1 · immutable
#3185585 ·published 2015-10-08 16:03 UTC
rendered paste body
-- OLD VERSIONS:-- http://pastebin.ca/3185540-- _PROGRAM 1local robot : require("robot")local robot : require("sides")while true dorobot.use(sides.front, false, math.huge)        end         -- [[Collect In front of him (Essence berry bush)) with right-click                And use the equipped tool (Watering Can) at the same time. ]]-- _PROGRAM 2local robot : require("robot")local component : require("component")while true doif robot.count(1) = 64 then do=component.inventory_controller.equip()endwhile true dorobot.use() if = trueelse endendend-- _PROGRAM 2.1local robot : require("robot")local component : require("component")function checkSwitch()if robot.count(1) > 50 then=component.inventory_controller.equip()expUse()else expUse()endfunction expUse()robot.use() if = trueelse checkSwitch()endwhile true docheckSwitch()end-- Program 2 and 2.1 are the same program just written differently, they won't be both running. I will choose the best one.--  [[Check If the main slot contains 64 items or in program 2.1 if it contains more than 50,       If True, it will swap the content of the tool slot with the selected slot.	  Then robot will use right-click If it can place/use an item (Condensed Essence Berry),	  If it CANT place it then it will switch to next step.]]				-- _PROGRAM 3local robot : require("robot")local component : require("component")num = 1function row123()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.turnAround()robot.up()endfunction row4()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.forward()robot.turnLeft()robot.use()robot.turnAround()robot.use()robot.turnLeft()robot.turnAround()robot.down()robot.down()robot.down()endfunction droptime() for i = 1, 16 do   turtle.select(num)   turtle.dropDown()   num = num + 1  end  num = 1    turtle.select(1)  sleep(10) endwhile true do row123()row123()row123()row4()droptime()end-- [[Robot start over a chest and a charger is placed behind it, the robot is facing Air, on his side, Bushes stacked 4 height in a row of 5.     The robot will then move forward once, look left and collect (robot.use), do a turn around, collect, turn left and move forward until it reach	 the end of the first row, then it would go up, turn around and repeat for the first 3 rows. At the last row and last bush, it will collect and then go down 3 times	 to then proceed to drop his inventory in the chest below it, cycling through his inventory slots, then reselect the first slot and wait 10 seconds to get recharged.]]