Need a unique gift idea?
A Pastebin account makes a great Christmas gift
SHARE
TWEET

CC Turtle Block Swapper

Xyzzy Mar 14th, 2016 (edited) 60 Never
Upgrade to PRO!
ENDING IN00days00hours00mins00secs
 
  1. --CC Turtle Block Swapper by wok86
  2. --Swaps the block on top of the turtle
  3.  
  4. local block1 = "BiomesOPlenty:hardSand"
  5. local block2 = "bluepower:lampinvertedwhite"
  6. local rsSide = "back"
  7.  
  8. while true do
  9.   if rs.getInput(rsSide) == true then
  10.     local block,type = turtle.inspectUp()
  11.     if type.name == block1 then
  12.       sleep(1)
  13.       term.clear()
  14.       term.setCursorPos(1,1)
  15.       print("Sand det")
  16.       turtle.select(1)
  17.       turtle.digUp()
  18.       turtle.select(16)
  19.       turtle.placeUp()
  20.     elseif type.name == block2 then
  21.       sleep(1)
  22.       term.clear()
  23.       term.setCursorPos(1,1)
  24.       print("Lamp det")
  25.       turtle.select(16)
  26.       turtle.digUp()
  27.       turtle.select(1)
  28.       turtle.placeUp()
  29.     end  
  30.   else
  31.     term.clear()
  32.     term.setCursorPos(1,1)
  33.     print("No RS")
  34.     sleep(0.5)
  35.   end
  36. end
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top