Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --CC Turtle Block Swapper by wok86
- --Swaps the block on top of the turtle
- local block1 = "BiomesOPlenty:hardSand"
- local block2 = "bluepower:lampinvertedwhite"
- local rsSide = "back"
- while true do
- if rs.getInput(rsSide) == true then
- local block,type = turtle.inspectUp()
- if type.name == block1 then
- sleep(1)
- term.clear()
- term.setCursorPos(1,1)
- print("Sand det")
- turtle.select(1)
- turtle.digUp()
- turtle.select(16)
- turtle.placeUp()
- elseif type.name == block2 then
- sleep(1)
- term.clear()
- term.setCursorPos(1,1)
- print("Lamp det")
- turtle.select(16)
- turtle.digUp()
- turtle.select(1)
- turtle.placeUp()
- end
- else
- term.clear()
- term.setCursorPos(1,1)
- print("No RS")
- sleep(0.5)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement