Advertisement
minimite

compact_turtle_walk

Jun 11th, 2015
241
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.19 KB | None | 0 0
  1. local l = {1, 0, 3, 2}
  2. while true do
  3.   for i = 1, l[math.random(1, 4)] do
  4.     turtle.turnLeft()
  5.   end
  6.   turtle.forward(math.random(1, 4))
  7.   if not turtle.forward() then turtle.attack() end
  8. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement