Turtle Stairbuilder (tutorial)

From ComputerCraft Wiki
Revision as of 00:17, 19 July 2012 by 195.154.238.178 (Talk) (Uses)

Jump to: navigation, search

Introduction

Welcome to this tutorial about Turtle Stairbuilders.

Programming your Stairbuilder

In this code we will program a stairbuilder that simply goes up a flat surface, when the wall ends it will create a stairway coming off of the wall

First we want it to determine the top of the wall

while turtle.detect() do
 turtle.up()
end

next we want it to decend one block and create the staircase

while turtle.detect() do
 turtle.up()
end
turtle.down()
turtle.back()
turtle.place()
while not turtle.detectDown() do
 turtle.back()
 turtle.down()
 turtle.place()
end
print("Staircase Built")

And there's your code!

Oh I see what happened. At arnuod 14:00 minutes (after the fast forward arrangement of the flakes) the audio shifts back to track 1. So if you download the zip package you can just change tracks from 2 to 1 at 14:00 minutes and you are back in business.Thanks,Tom