Jump to content




Ultimate Wood Chopper [0.9.5 Prerelease B][Session Persistent]

turtle utility

415 replies to this topic

#1 unobtanium

  • Members
  • 505 posts

Posted 28 December 2012 - 10:40 AM

Posted Image

Hello Minecraftcommunity,

i presenting you my fully automated Ultimate Wood Chopper (UWC), a logger program for ComputerCraft and its Turtles.
Multiples programs are put together in this program pack to help you gain wood and saplings very fast. I hope you enjoy.
Feel free to leave some feedback. If you need help, check down below how to post a report.



Shoutoutbox:
If i make changes to the code, without changing the version of the program i will write these in the shoutoutbox. Sometimes i will write in some news and informations as well. Before posting a bug, please check if it is listed in the shoutoutbox allready and download the code again.

Quote


This program is one year old. Happy birthday :D


Potentially fixed the "digging-down-to-bedrock" bug! Download the prerelease version and test it. I just fixing the stand-alone version, later on the rednet version.
Going to finish this program in the next months i hope :S

No fir tree in FTB Unleashed or higher! :(

Feel free to check out my newest programs here



What does Ultimate Wood Chopper?
This program can chop down single trees, both 1x1 and 2x2. You also can set up an automatic farm which replants trees either with or without bonemeal and chops it down. The farm is selfbuilding and i just recommend using Fir Wood (Saplings) for it, because the Fir Saplings dont check if there are leaves above and instantly grow if bonmeal is used on them. Fir Trees also grow in 2x2 trunks without branches. You also can set specific variables of the program for your personal usage.

Overview video about "how to build the standard farm and expanding it" made by Seleck:
Check out his channel! He is making awesome let's plays and tutorials.

Posted Image



ULTIMATE WOOD CHOPPER BETA VERSION 0.9.5 prerelease B (newest):

Pastebin:

Single Program for the Turtle:
Kngv6tWj

Rednet Computer:
PaxTx2xT
Rednet Turtle:
THa8YtH4


SingleProgram for the Turtle UWC Beta Version 0.9.0 (stable, no session persistence):
iVKtHaWk

Downloads:

ULTIMATE WOOD CHOPPER TEST WORLD


Features:
- very easy and user friendly
- menu
- just needs one mining turtle
- rednet (startup versions)

- Farm
-- saves and starts where it was left before the chunk unloaded (session persistence)
-- selfbuilding
-- selfsustaining
-- with and without bonemeal
-- fairly cheap
-- controlled shutdown by a user's redstone signal or pressing a key
-- debug
-- expandable
-- change many variables for the personal usage

- Single tree
-- 1x1
-- 2x2
-- any height



Installation:
Label your turtle and computer to let it save the programs and save files.
label set <name>

Put the code in a text document without ending in ...yourMinecraftDirection\mods\ComputerCraft.zip\lua\rom\programs\turtle
Or if you are running a server you have to put it in ...yourMinecraftServerDirection\mods\ComputerCraft.zip\lua\rom\programs\turtle
Restart your Minecraft Client or Server (or both)
The computer rednet program you have to put in
...yourMinecraftDirection\mods\ComputerCraft.zip\lua\rom\programs\computer

Or you can use the pastebin import. Simply type the following words into your turtle.
pastebin get Kngv6tWj startup


Programs:

I recommend using a mining turtle for all programs!
To enter the menu, simply tipe

Quote

startup
in the Turtle screen.
D or Enter --- Open up submenu or start program
W or Up-key --- Select menu point above
S or Down-key --- Select menu point below
A or Backspace --- Go back to the menu before


Posted Image



Set up a farm

Expanded Farm
This will build the expanded farm right away. It is much bigger then the standard farm to catch more/most saplings.
If you having a standard farm allready, you can expand it with the "Expand the standard farm" program under "Build and Expand ".
Posted Image

Place a turtle facing the direction where the tree will be and a chest behind it. The turtle ask if you want to have blocks removed in its way. However it needs a flat 18x22 free place.
Posted Image

Now place the following items shown in the picture in the correct order in the chest.
Posted Image
Spoiler

Start the program and be sure the turtle doesnt get interupted or the chunks unloaded.
Tip: You get asked, if you want the turtle to remove blocks in it's way. So you dont need to dig the 22x18x3 pit with your hands!

After building the farm, the Turtle will stay in the Base, facing the coal chest. Fill every chest with enough materials before let it start chopping the tree.
- You only need 15 charcoal (or maybe even less if the turtle has fuel left) in the charcoal chest
- The turtle needs 17+ saplings or more and 8+ bonemeal
Warning: You have to manually flip the lever for the redstone engine. You also have to put water in the right spots to transport the saplings to the obsidianpipes. You also should take out all left materials from the turtle's inventory.

You also have to be sure that no mobs can get into the water stream and block the turtle while its working. So add some fences or raise the edge of the farm a bit higher.

Standard Farm
This program will set up your standard farm, usefull if you are just interested in wood and less the saplings. It automatically will build the layout, place chests and the piping system.
You need:
- Enough space below, around and above for the farm layout and the tree.
- 10x16x8 free area
- Turtle has to be at the coordinate 5|3|5 called Base and facing in the direction, where the tree well be.
If you have problems with position your turtle right, check out the "Position your turtle" and "Dig needed space" section down below.


- The Base is above the furnace, and at the sides are the wood chests, charcoal chest and the lever
- You need the following materials:
Use charcoal instead of normal coal. You also can use an iron furnace if you have one.
For a cheaper set up you can use cobblestonepipe/stonepipe instead of a goldpipe. If you dont have obsidian for the obsidianpipe, let your turtle dig some or do it on your own. The sapling and bonemeal are optional, but recommended as indication in which chest the supplies go.
Posted Image

Spoiler


After building the farm, the Turtle will stay in the Base, facing the coal chest. Fill every chest with enough materials before let it start chopping the tree.
- You only need 15 charcoal (or maybe even less if the turtle has fuel left) in the charcoal chest
- The turtle needs 17+ saplings or more and 8+ bonemeal
Warning: You have to manually flip the lever for the redstone engine. You also have to put water in the right spots to transport the saplings to the obsidianpipes. You also should take out all left materials from the turtle's inventory.

There is a way to make your existing farm bigger. Check out the "How to expand your farm" section down below.
You also have to be sure that no mobs can get into the water stream and block the turtle while its working. So add some fences or raise the edge of the farm a bit higher.



Chop Programs:

For Farms:
Chop -> Farm
Check the following magical three things:
- Your farm is build and all chests are filled (one or two stacks are enough.).
- The Turtle stays in the Base, facing the coal chest.
- Don't forget that the turtle needs a redstone signal, so flip the lever in the back of the turtle, otherwise it wont work.
- The turtle should have an empty inventory on it's first run to prevent bad stuff from happening.
The Turtle takes what it needs out of the chests.
If you want to shut down the turtle while it is working, simply switch the lever and the next time the turtle comes back to Base it stops.
Be sure you use the right program for the right farm (Standard or Expanded).
It's no problem if you have no bonemeal for the moment. Change the variable in the variable change menu (Chop -> Farm -> Variables).
You can change specific variables in the variables menu (Chop -> Farm -> Variables). The turtle will safe them and will load them on every start. Every turtle has their own variables and you have to/can change them for every single one individually.
Tip: The farm maybe just works with Fir Saplings, because this kind of tree doesnt wait for leaves to disappear.
If the turtle shutdown in an unloaded chunk, the turtle will restart where it was left and tries to go back to base as soon as possible. Then it will keep going until the lever got flipped. This requieres the turtle program as startup file...
If you are having problems with the turtle, you should delete the files like below in the main turtle os menu. Holding STRG + T stops a running program.
delete uwcvariables0.9.2
delete uwcsavepoint
You have to remake your variables after this.

For single trees:
Chop -> Single Tree
There also are single tree chop programs for 1x1 and 2x2 trees. Place the Tutle in front of the tree you want to chop down. For 2x2 trees place it on the left side. Put some fuel in the first slot (top left) and start the program. This can be used to chop down forests or trees which grew in the wrong spot.

Change Variables
It is possible to change variables for the farm under Chop -> Farm -> Variables.
Starting the program opens up a interface, showing you every changeable variable one by one and explains for what it is used for. You can press Enter to skip the variable and let it where it is. Tipe in a number and press Enter to change the variable. The change is shown afterwards at the top of the screen.
These variables are saved and loaded for every turtle individually.



Help Programs:

Position your turtle
Help -> Help Programs -> Position
This program helps you to find the Base before the Turtle starts set up the layout. If you place your Turtle on the ground and start this program, it just goes 4 blocks up, 2 forward and 4 to the right. it will look in the direction the tree will be. Usefull if you want to build the farm up in the air.


Dig needed space
Help -> Help Programs -> Dig needed space
Instead of building your farm up in the air, you can let the turtle dig a hole in the ground.
The Turtle just digs enough space for building the Standard Farm. You have to manually dig more space if you want to expand your farm. This will be around 4-5 blocks to all sides.
This program needs:
- a mining turtle
- five coal in the first slot; everything else empty
- a flat ground. Stay some blocks away from the turtle and dont interrupt it.

Debug farm
Help -> Help Programs -> Debug
Use these programs for your farm if the turtle shutdown while chopping the tree. It removes all left wood blocks.
The Turtle has to stay in the base, facing the coal chest. It just need some coal in the first slot.
Here too: Be sure you use the right program for the right farm. You have to manually take out the coal and the wood.

Go Down
Help -> Help Programs -> Go Down
The turtle will move down until it hits a block. Useful if using rednet and the turtle was stuck in the tree.



How to expand your farm:
Build & Expand

Add more chests
If you want more wood storage, simply place the amount of chests you want to add in the second slot. Some coal in the first slot. The turtle has to stay in base.
If you want to store even more wood, you can use double chests or an other kind of chest (e.g. diamondchest).
The turtle will the block above the chests, which needs a mining turtle. Have all other inventory slots empty.

Posted Image


Expand your farm
This program increases the size of the sapling collecting area of your standard farm. Nearly every sapling will get pulled into the sapling chest to use these for biomass production or something else.
You have to use a mining turtle for this program, because the turtle will go and remove parts of the standard farm and use these blocks for the expanded farm.

Posted Image


The Mining Turtle has to stay in the Base facing the charcoal chest.
Be sure you dont have water in the farm left. Otherwise it will flow all over the place!
Put the following materials in the Turtle. You dont need that much coal. Around 10 should be okay.

Posted Image

Spoiler


The turtle will remove the layout of the standard farm and uses these blocks for the expanded farm, so please be sure, which type of block you are using. For example Stone drops Cobblestone and then you get a stone-cobblestone-expanded farm instead of pure stone expanded farm. So please use this patter if you are using such a type of block:


Posted Image
Spoiler



You have to put water in the four corners to transport all saplings to the obsidianpipe.
You have to use the chop program for expanded farms.
You also have to be sure that no mobs can get into the water stream and block the turtle while its working. So add some fences or raise the edge of the farm a bit higher.

Rednet:
The rednet version comes in a program for the turtle and the computer. The programs are made as a startup program, so you can go ahead and navigate the turtle out of the tree if it got stuck in it. The computer has the same menu as the normal program, but just shows if it reached a turtle or not. In the rednet version you are not able to change the variables of the turtle yet. Please use the normal program for this, because it will use these in the rednet program too.
Especially for the rednet version there is a program under Help -> Help Programs -> Go down which simply let's the turtle go down until it hits a block underneath. That makes it easy to call the turtle back out of the tree if it got shutdown while chopping.
You also can set up multiple turtle and start them all from one computer at the same time. That might be a good use if you chop down a whole forest too.

Turtle Interactions
This program is made to easily navigate your turtle. For more informations check out Turtle Interactions


To-Do:
Before i release Version 1.0 i want to have this list finished or even more points.
- maybe let someone with english skills rewrite the whole post (if someone want to or knows someone, let me know)
- improve the rednet version so that the turle wont need a redstone signal anymore


Updates:
Spoiler

Found a bug, got an error or something didnt worked?

Questions & Answer:
Spoiler


Something is strange or you even get a error message, please fill in this following layout and post it in this post:
Does the problem still occures if uwc gets redownloaded:
FTB Version:
Singleplayer or Multiplayer:
Error Code:
What happened:

This is helping me a lot to simply find where your problem is and hopefully how to fix it. If you get an error please write it down too. Mention which programs you where using and what/how many items in the turtle and chests were.

More programs made by myself:
Link

Facebook:
https://www.facebook...362726857167297


That's it! I hope i didn't forget anything. Btw, my english isnt the best :/
Because the program is still in beta i cant say that it is bugfree!
If there are any questions, suggestions, errors or bugs, feel free to leave a comment to improve this program pack.
Thank you for your attention.
UNOBTANIUM

Edited by unobtanium, 11 December 2014 - 04:51 AM.


#2 unobtanium

  • Members
  • 505 posts

Posted 29 December 2012 - 09:02 AM

--- NEW VERSION OUT
Spoiler


#3 HotGirlEAN

  • Banned
  • 101 posts

Posted 29 December 2012 - 09:06 AM

Neat program! However, can you put it in a pastebin or dropbox so it's easier to download and "install"?

#4 unobtanium

  • Members
  • 505 posts

Posted 29 December 2012 - 09:21 AM

Thank you!
I added some pastebin links in the spoiler under the Download section.

#5 snoxx

  • New Members
  • 1 posts

Posted 30 December 2012 - 09:37 PM

Doesn't work the turtle just breaks the 1st layer of the wood and replants the saplings and stands in front of the bottom left sapling

#6 Hoppingmad9

  • Members
  • 4 posts

Posted 31 December 2012 - 07:10 AM

Hey,
This looks like a great program the build, position and help programs are great but chop just doesn't work.
It takes the materials fine, plants the saplings and grows the tree. But then it cuts down the first layer and tries to replant.
I guess this is just a very small mistake in the repeat somewhere so it's a shame it ruins the main feature of the program.
Finally never apologise for not knowing English! Very few of us know your language!

Thanks
Sam

#7 Hoppingmad9

  • Members
  • 4 posts

Posted 31 December 2012 - 08:13 AM

Hey,
I think I've found the problem:

local function cutWood()
local height = 0
turtle.select(2)
turtle.dig()
turtle.forward()
turtle.dig()
while turtle.detect() do
turtle.digUp()
turtle.up()
turtle.dig()
height = height + 1
end

Firstly: The red text is detecting a block in front of the turtle.
Secondly: The blue text has broken the block in front of the turtle.

So there won't be a block in front of the turtle so it doesn't go up.
So I assume the red text should be:
"while turtle.detectUp() do"
Trying to work out a fix for it but I'm not very good!

Sam

EDIT:: Corrected mistake

#8 Hoppingmad9

  • Members
  • 4 posts

Posted 31 December 2012 - 09:05 AM

Hey, yep that's your fix!
In the cut wood local program you just need to change the detect to detectUp.

Hope I've helped!
Sam

#9 unobtanium

  • Members
  • 505 posts

Posted 01 January 2013 - 03:25 PM

Hello and thank you everybody :D
Sorry that i couldn't answered earlier. My internet does not work correctly at the moment.
If i have it running again, i will fix the files and the pastebin code like Hoppingmad9 allready did.
So please stay tunned. I hope my internet will be fixed in two days ;D


edit: I fixed it allready! Sorry for this fail, guys :(

NEW VERSION OUT
Spoiler


#10 steel_toed_boot

  • Members
  • 25 posts

Posted 01 January 2013 - 07:46 PM

Wow you really got carried away with the options and coding haha :P

#11 unobtanium

  • Members
  • 505 posts

Posted 03 January 2013 - 07:23 AM

Yeah, i know :D
I was bored a bit and because i am playing on a server and need a lot of wood, i wanted to make a big tree farm with turtles without setting up every farm with my own hands. Other players can use it too. it is very funny to see your own farm in someone else house ^^
On the other hand i wanted to have something special. There exist so many programs and every day they are getting more and more; e.g. this forum :D

#12 Zagi

  • New Members
  • 5 posts

Posted 05 January 2013 - 07:55 AM

Hey UNOBTANIUM, loving your program! Got me loads of wood. I've encountered just 1 little problem.

When the turtle runs out of bonemeal it doesn't go get some more. It stays there infront of the saplings switching between slot 2 and 3 rapidly. This also happens when it runs out of saplings. Is this fixable, because that's the only thing that it stops from being 100% automatic.

EDIT: Nevermind, the chest with bonemeal was empty :D.

#13 unobtanium

  • Members
  • 505 posts

Posted 06 January 2013 - 02:21 AM

Haha, yeah! I might change this a little bit and let the turtle say, what is wrong or what it needs to continue.
So there is a Version 0.4 comming i think ;D

#14 Kylun

  • Members
  • 9 posts
  • LocationFlorida, USA

Posted 06 January 2013 - 09:02 PM

Very awesome. thanks for your hard work.

A suggestion when/if you do make an updated one.. i want all the saplings, but the platform is too small.. it needs to be about 5-6 blocks bigger on all sides. :-/

#15 unobtanium

  • Members
  • 505 posts

Posted 07 January 2013 - 01:58 AM

I can make a building program which builds it bigger if you want. At the moment the size is enough to get enough saplings into the chest to refill the Turtle.
I just wanted a cheap way to set up the farm.
I will add it to the list for Version 0.4 :D

#16 unobtanium

  • Members
  • 505 posts

Posted 07 January 2013 - 01:49 PM

#this post can be deleted

#17 unobtanium

  • Members
  • 505 posts

Posted 08 January 2013 - 02:37 AM

#this post can be deleted

#18 unobtanium

  • Members
  • 505 posts

Posted 10 January 2013 - 11:15 PM

NEW VERSION OUT!
Spoiler


#19 xInDiGo

  • Members
  • 105 posts

Posted 12 January 2013 - 02:36 PM

not sure whats going on, i start it up, and it says its checking for coal in chest, if nothing happens then chest is empty. well he just grabs charcoal out over and over and does nothing. did i do something wrong?

::edit::

my problem was i had too small of a stack of charcoal and a to small of a stack of fir in the chests.

#20 unobtanium

  • Members
  • 505 posts

Posted 13 January 2013 - 02:15 AM

Yeah, it accually checks if there is enough of the material in the chest. So it doesnt have to go back after every tree was chopped down. Maybe i have to edit this line and say that there has to be more stuff in the chest :/

edit:

Quote

Chop Programs
Your farm is build and all chests are filled (one or two stacks are enough.).
:D
NEW VERSION OUT
Spoiler






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users