Go learn to program.I wish there was a program for LUA noobs that would basically help you with writing programs, where you could say what you want to do and the program writes the codes, but that kind of program is probably impossible.
like I'd love for a turtle to mine 1 certain block above surface, like if you'd tell the turtle to mine basalt, and you place it at a volcano, it'll mine all the basalt it can detect.
Exactly that. I don't want to seem rude, but Turtles can be incredibly OP if you know how to code. If I just released my super quarry program with a few instructions then people could get one mining turtle, a couple saplings and some blaze rods, then sit back and watch them eat the whole world.Go learn to program.
Seriously, the one reason ComputerCraft Turtles are not OP is because it takes so long to write a proper program.
Yup.Exactly that. I don't want to seem rude, but Turtles can be incredibly OP if you know how to code. If I just released my super quarry program with a few instructions then people could get one mining turtle, a couple saplings and some blaze rods, then sit back and watch them eat the whole world.
That said, there are places, the best one is the computercraft forum, that can help you with the basics.
Go learn to program.
Seriously, the one reason ComputerCraft Turtles are not OP is because it takes so long to write a proper program.
Lua is not that bad. I've written in much worse languages.Actually, their carefully balanced to set my brain on fire and make my eyes leak rage lava. I googled around for a popular turtle quarry program to see what CC Lua looked like. I found this and wept blood. I punched the wall and cried about coroutines incoherently for about 20 minutes.
Oh the humanity. Oh the tragedy. Truly, Turing is turning in his grave with such force as to provide infinite electricity for all.
Lua is not that bad. I've written in much worse languages.
And for a mining turtle you still need 3 diamonds for a pickaxe. A Quarry needs, what, 8? And some gold (gold is like water in MindCrack). Oh the humanity!
Well, the advantage with Turtles, is they eventually hit coal, and can refuel themselves.Well really with redpower you can just use a gem pickaxe, though you can't get obsidian, it makes it even easier to get. Also the quarry needs 11 diamonds, plus a ton of power compared to the amount the turtles use, though I hear the fuel usage was increased recently.
A coroutine-based pathfinding generator (I assume you mean for returning to a chest the way you came, or vice versa), is do-able, but in a simple mining program, you don't really have a clearly defined producer/consumer.Lua is awkward, but has some nice features. I'm more saying that this is the state of the community; basically everyone is doing with turtles on minecraft what I did with turtles on an Apple ][ and that makes me sad. I tried to find a single library that even thought of using a corotuine-based generator for pathfinding to radically shorten the code; they didn't.
A coroutine-based pathfinding generator (I assume you mean for returning to a chest the way you came, or vice versa), is do-able, but in a simple mining program, you don't really have a clearly defined producer/consumer.
Keep in mind ComputerCraft has only been out for about a year. And a lot of the APIs to do the juicy stuff have been more recent. I did see finally someone made an Octree library:
http://www.computercraft.info/forum...fficient-way-of-storing-and-querying-3d-data/
Perhaps if you had a more complicated program that did animal breeding, beekeeping, or farming, but for a Quarry that seems like overkill. Really, for mining, you have two choices: Choose a direction to move, and dig then move, or go home (for whatever reason, fuel, inventory full, etc).Sure you do. The consumer is the action loop selecting from one of a variety of actions based on the current state of the turtle. If it's full or low on fuel, take an action from the "goHome" generator.
Coroutines are a great way to capture stepwise execution of a process best described as a loop and "invert" the invocation of it. It's also good for taking stepwise computations and turning them into a stream.
Thank you, that is cool. Maybe there is hope for the world.
Perhaps if you had a more complicated program that did animal breeding, beekeeping, or farming, but for a Quarry that seems like overkill. Really, for mining, you have two choices: Choose a direction to move, and dig then move, or go home (for whatever reason, fuel, inventory full, etc).
But yeah, glad to find the octree program. Should make gps-less navigation much easier (specifically the return home part.... mine in a random direction, following the ores, then return home).
That was my point. A Diamond hunting turtle (and maybe Thaumcraft Shards).In a pure quarry where you are raking everything down to the bedrock into a chest, that's overkill. For a branch mining program where you maintain your path as a stack it's exactly what you want.
That was my point. A Diamond hunting turtle (and maybe Thaumcraft Shards).
When you have 14 trillion chunks in a Minecraft world, does it matter if you only get 14 trillion diamond and not 28 trillion diamond? For reference, that's 2 billion diamond chests full of diamond blocks.If I were to write a mining turtle, my first priority would be detecting and avoiding blocks that can be silk touched or fortuned (coal, diamonds, redstone, gems, etc.) Let the turtle dig branch mine tunnels for you and deposit all the iron/gold/copper/etc., then you come with a ST pickaxe and get the good stuff to your macerators/grinders.