Advertisement
Guest User

startup

a guest
Dec 17th, 2014
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.12 KB | None | 0 0
  1. rednet.open("left")
  2.  
  3. local id = 1848
  4. local data = {}
  5.  
  6. while true do
  7.   i,mess,dist = rednet.receive()
  8.   if i == id then
  9.     print(mess)
  10.     if mess == "craft" then
  11.       data = turtle.getItemDetail(1)
  12.       if data ~= nil then
  13.         if data.name == "AWWayofTime:AlchemicalWizardrybloodRune" then
  14.           turtle.select(2)
  15.           while not turtle.digUp() do
  16.             if not turtle.detectUp() then
  17.               break
  18.             end
  19.             sleep(1)
  20.           end
  21.           turtle.select(1)
  22.           while not turtle.placeUp() do
  23.             sleep(1)
  24.           end
  25.         end
  26.       end
  27.     elseif mess == "blood" then
  28.       data = turtle.getItemDetail(2)
  29.       if data ~= nil then
  30.         if data.name == "AWWayofTime:runeOfSacrifice" then
  31.           turtle.select(1)
  32.           while not turtle.digUp() do
  33.             if not turtle.detectUp() then
  34.               break
  35.             end
  36.             sleep(1)
  37.           end
  38.           turtle.select(2)
  39.           while not turtle.placeUp() do
  40.             sleep(1)
  41.           end
  42.           turtle.select(1)
  43.         end
  44.       end
  45.     end
  46.   end
  47. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement