ecco7777

turtle floor builder

Mar 26th, 2016
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.32 KB | None | 0 0
  1. args={...}
  2. z=tonumber(args[1])
  3. x=tonumber(args[2])
  4. side=1
  5. function place()
  6. for i=1,z do
  7. turtle.placeDown()
  8. turtle.forward()
  9. end
  10. end
  11. for i2=1,x do
  12. place()
  13. if side==1 then
  14. turtle.turnRight()
  15. turtle.forward()
  16. turtle.turnRight()
  17. side=2
  18. else
  19. turtle.turnLeft()
  20. turtle.forward()
  21. turtle.turnLeft()
  22. side=1
  23. end
  24. end
Add Comment
Please, Sign In to add comment