This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
5tarKaster's profile picture

Turtle Builder

Started by 5tarKaster, 07 June 2013 - 07:05 AM
5tarKaster #1
Posted 07 June 2013 - 09:05 AM
I'll edit this post when I have more time and add some more explanation later but for now….
This is a turtle builder program much like that of NitrogenFingers 3D printer and NPaintPro but this has about a million less lines of code to it :D/> and a lot less functionality, however if all you want is to build a little house with your turtle then this is just as good … I am still going to add more features and things of that nature later but again I have little time right now to do that.


USAGE
grab the BluPrint program and design your building one layer at a time, note that each colour in their respective order from top to bottom is the same respective slots on the turtle. So basically let me lay it out here bellow.


turtle slot = colour
1 = white
2 = orange
3 = magenta
4 = light blue
5 = yellow
6 = green
7 = pink
8 = grey
9 = lime
10 = cyan
11 = purple
12 = brown

then after you've made the file, grab it and drop it in your turtle in a file called "bluprints" and run the builder program

some functions
the turtle will stop when out of a particular block
the turtle can build (I assume) any size thing you tell it to
the turtle will stop if you get in its way and continue when you get out

some faults
the turtle will skip a block if you get in its way :/

Here are the paste bin links numbers
Builder: w76Casgb
BluPrint: grs6P5wq

suggestions? if you have then you should tell :)/>
unobtanium #2
Posted 08 June 2013 - 05:19 AM
You can detect if the space in front of a turtle is free by checking it like this:


while not turtle.forward() do sleep(1) end

Overall a good program :D/>
5tarKaster #3
Posted 08 June 2013 - 12:02 PM
I'm glad someone got it to work :D/>/> that means it's conceivably usable, my future plans are also to make it send over modems and such but for now I'm busy with another project… about that code, yes I did do something similar to that but for some reason I can't understand why it decides to just skip the block to place down… I'll try your exact code now and see if that fixes it, my guess is its a fault in that part of the program
unobtanium #4
Posted 08 June 2013 - 12:10 PM
A lot of commands return true or false so you can easyly check with a if-statement if it got executed correctly. And if not then wait a seconds or two and try it again.
Works for refueling, moving, drop, suck, place, dig, ect.
Rednet isnt that complicated ;D
Drake #5
Posted 10 June 2013 - 09:59 AM
Wait… while not works….. dang it, I didn't see it listed with the Lua logic page I read so thought they left it out of Lua and I've been using == false instead of not. Looks like I have some code to clean up.