Jump to content




Items Sorting Turtle [Selfbuilding][Quarry-suitable][Rednet][0.4.1+]

turtle utility

  • You cannot reply to this topic
46 replies to this topic

#1 unobtanium

  • Members
  • 505 posts

Posted 18 January 2013 - 11:31 AM

Posted Image

Hello MinecraftCommunity,

it's me again, and this time i presenting you my Items Sorting Turtle.
This Turtle will set up a layout and then takes out item stacks from a chest to put these in a chest for each individual kind of item. This could be used for items from a quarry. Now with rednet!!!
Feel free to leave feedback on this to keep me updating.
PS: 3000 views and 300 downloads! Great :D

ITEMS SORTING TURTLE BETA 0.4.1
Spoiler

ITEMS SORTING TURTLE BETA 0.4.1+
Spoiler

Installation:
Install the program with the following code typed in your turtle:

pastebin get hcwy8SQ2 ist


Programs:
Type
ist
in your turtle to start the program and get into the menu.

Build standard layout
This program needs a mining turtle. I will change this in the future, so a normal turtle will be enough.
Place the Turtle on the ground. It needs one block space in the front and two to the left. The back will be the user interaction and where the chests will be displayed. Its accually the front :D
The chests where the items will be stored after sorting them, will be build to the right. Examples down below.
If you start the program, it asks you how many horizontal chests you want. This means how many lines of chests will be set up. The bigger this number is, more space is needed to the right.
The second question is how many vertical chests you want to have for the storage. The bigger this number is, the higher will be the whole storage.
After typing in the two numbers, it will show you how many items you need:
In this case i wanted three horizontal chests but just one height.
I put the needed materials allready in the slots of the turtle.
This will build the sorting layout you can see at the top of this post.

Posted Image

The pattern of the materials needed for this program is like the following picture:

Posted Image
Spoiler

After pressing Enter the Turtle should start building it. Stay back and be sure nothing blocks the turtle.
If the Turtle finished its job, it stays in the base. From there you can start the sort program.

Build compact layout
Does the same like the standard layout building program above.
You dont have to use chests to run the program. You can place them manually later on if you want to.If you use chests, the Turtle needs chests which dont connect to each other. If you place the chests manually, you can make a crossed pattern with normal chests and another kind of chest. (If trapchests are avaiable i recommand these!)
You have to use the sorting program for compact layouts!

Posted Image


Start standard sorting
This is the main program of the pack.
Place the items you want to sort into the bottom left chest (lowerst one of the four ones! You can put an enderchest there, too).
Above this chests, put some coal or charcoal. At least ten.
The last two chests should be empty. The Turtle will drop all items which couldn't be sorted in these top chests.
The Turtle needs two coal or charcoal in the last slot (bottom right).
After starting the program the Turtle will take out the materials from the lowest chest and sort them into the other ones to the right. If one of the chests are empty, it automatically fills it with an item which wasnt sorted allready. However, you can put one item you want to have sorted in the chest in it.
If one chest is full, the turtle continues sorting and maybe put it into an empty chests further right. If the turtle reaches the last chest and there are still items left in the inventory, these items will be dropped in the top two chests near the base.
If this was too confusing, just try it out! It makes sense :D

Start compact sorting
This program does the same like for standard sorting. It just travels one block instead of two to get to the next chest.

Example:
Check out the picture at the top of this post. I wanted 3 horizontal and one vertikal chest.
More expamples:

Spoiler
Spoiler
Spoiler


Updates:
Spoiler

To-Do:
- a normal turtle can build the layout

More programs made by myself:
Items Sorting Turtle --- Set up a sorting layout with chests and let it sort items for you. Perfect for Quarries!
ULTIMATE WOOD CHOPPER --- Set up a farm to chop wood or cut down single 1x1 or 2x2 trees.
Turtle Interactions - Simply naviagate the turtle with a menu
Two High Door - Opens one or more two high doors over rednet.


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

#2 xInDiGo

  • Members
  • 105 posts

Posted 22 January 2013 - 08:59 PM

this is fantastic! i replaced the drop off chest with an enderchest and have my other turtles deposit into an enderchest! gonna see if i can make a simple script to loop istsort ;)

thanks for this!

#3 unobtanium

  • Members
  • 505 posts

Posted 22 January 2013 - 10:50 PM

hey, nice to see you again :D
Can you show me the loop script if you have it done? Maybe i will implement this if its usefull for more people :D
Or do you just want to let the turtle wait for more items in the enderchest`?

NEW VERSION OUT!

#4 xInDiGo

  • Members
  • 105 posts

Posted 23 January 2013 - 05:59 AM

basically yeah i'm trying to just get it to check every once in a while for items in the enderchest. the script would be something simple to just run the istsort program over and over every 3 minutes or so. i like the way it is now cause i'm able to use rednet to tell it to sort, & if you made it all one program that may be more difficult for me to do!

one question, when it asks how many chests per item, lets say i make that 2, and it stacks the chests. well if i put a different item i the top chest would that work as another sorting chest? or would it have to be the same as the chest below it?

minor suggestions: if you can make this double sided! (chests on both sides) the way its goes right now, the turtle could easily just turn around after droping an item to deposit other items to a chest behind it. i only mention this cause its really long if you've got lets say 10 chests to sort!


::edit:: the new version doesn't seem to work. i do the build, and then run sort, and i get:

Quote

ist:476 attempt to call nill


#5 unobtanium

  • Members
  • 505 posts

Posted 23 January 2013 - 07:03 AM

I can add the single programs again if you use rednet. The deal is that i didnt get into it yet (i dont even know what it accually does :s). I may take some time to do this. :D
I will add the 3 minutes waiting time in the next version.

The turtle checks the slot 16 which item should be placed in the chests. And if a chest is full, there is still the same item in slot 16 from the chest below. It will allways ignore the items you put in the chests above the lowest one. You accually just waste a slot for the storage :D

The mirror idea, to have chests on both sides, seems quite nice. The problem is (and thats why i just have chests on on side) that the player has to place the whole building in a free area to have access on both sides. The setup now can be placed on a wall. I will check if i can add this.

I am working on a compact version at the moment. In this one, you use chests, which are not connecting to each other. You also could use a crossed pattern e.g. normal chests and another kind of chest (maybe trapchests some day). This makes a flush wall of chests and would let the Turtle just travel one block to get to the next chest and would be quicker.

#6 xInDiGo

  • Members
  • 105 posts

Posted 23 January 2013 - 07:14 AM

yeah i just got into rednet last night! i read this tutorial here to learn about rednet! & you're right about needing a free area, but it can be done!

but what about the error i was getting,

Quote

ist:476 attempt to call nill


#7 unobtanium

  • Members
  • 505 posts

Posted 23 January 2013 - 08:43 AM

Thank you for the tutorial link. This looks very awesome and will be added very soon i hope ^^

I cant produce the error myself. Do you know what the Turtle did or at which position it stopped?

#8 xInDiGo

  • Members
  • 105 posts

Posted 23 January 2013 - 12:09 PM

it was on another computer in a single player game. i'll have to check on it and see what the issue was. i'm trying to do some minor tweaks of my own, to make it more rednet friendly. i'm hoping i can change the shutdown to run my listen command

::edit:: i was able to remove the shutdown and add my listen now i'm working on a repeat, but i noticed its not putting coal in the coal chest. sup w/ that?

#9 unobtanium

  • Members
  • 505 posts

Posted 25 January 2013 - 01:13 AM

I found the bug and fixed it. I also added a timer which checks for new stuff in the chest every 3 minutes. I also added two new programs if you use rednet. However i didnt implemented that the turtle checks if it has coal in its inventory. I will add it as soon as possible.

NEW VERSION OUT 0.3

#10 xInDiGo

  • Members
  • 105 posts

Posted 25 January 2013 - 05:44 AM

this is great, i'm very excited to use this! question:

on the compact build does it stack the chests for smaller space or does it just remove the 1 space block?

i think stacking it could make it more compact, you could have 12 chests & it only takes up 3 spaces! sure it may be taller but as far as i can tell most people stack their chests about 3 or 4 tall anyways! if they need more space they can always just upgrade their chest to a gold or diamond chest!

#11 unobtanium

  • Members
  • 505 posts

Posted 25 January 2013 - 06:01 AM

Thank you!

It still works like before. The Turtle just has to move one less block (accually two because it has to travel back too). It just safes a bit of time.

The longer i think about this, the better it seems to be. It would be an ultimative small storage :D
I think i will change/implement this.

#12 xInDiGo

  • Members
  • 105 posts

Posted 25 January 2013 - 06:45 AM

makes sense in my mind! it seems more intuitive that way! for instance:

you need to make a diamond pick, but your diamonds are all the way in chest 16 down the line! so now you run down 16+ blocks to get your 3 diamonds. But now you need wood, which is in chest 3, so you have to run back! but now, *gasp* the crafting bench is down by chest 10! time to head over there!

anyways, i'm sure you get my point! i hope you enjoyed my short story, and i look forward to seeing what you come up with!

#13 unobtanium

  • Members
  • 505 posts

Posted 25 January 2013 - 07:28 AM

I think you throw the storage system and this sorting program together ;D
This program is just for sort different items. If you want an item you have to grab it yourself ;D
If i make a logistic storage i will make another program ;D

#14 xInDiGo

  • Members
  • 105 posts

Posted 25 January 2013 - 08:18 AM

heh i simply meant a more compact sorting system would be easier to use then your current long one. i know that your storage system will be different :P

#15 unobtanium

  • Members
  • 505 posts

Posted 25 January 2013 - 11:37 AM

Allright ^^'
I put the 0.3 Version in the Updates Section if someone still wants to use this one.
In 0.4 the turtle goes layer by layer up and puts in every chest one item. If you make a 3 by 3 pattern you now can store nine different items instead of just three :D

NEW VERSION OUT 0.4!!!

#16 xInDiGo

  • Members
  • 105 posts

Posted 26 January 2013 - 08:35 AM

hey i'm having a problem. after the turtle sorts it just stays are the end of the line and drops the overflow, instead of going back. also, when i quit out of the menu i get an error.

::edit:: removed and reinstalling the program seemed to help, although theres still the error if you quit the program "ist79: Attempt to index ? (a nill value)"

::edit 2:: seems that if i quit the program from the menu, it will glitch if i try to restart it and stay at the end of the chests, and drop the overflow on the ground.

#17 unobtanium

  • Members
  • 505 posts

Posted 26 January 2013 - 12:11 PM

I have to check and test my programs better before release them -.-
Thank you once again!!!!

This bug was quite difficult to fix. It took three ****ing hours before i found my mistake :D
I fixed it now. NEW VERSION OUT! 0.4.1

#18 xInDiGo

  • Members
  • 105 posts

Posted 27 January 2013 - 01:59 PM

looks like there may be a problem with refueling. i'll play around a bit more and see if i can reproduce the glitch.

#19 unobtanium

  • Members
  • 505 posts

Posted 28 January 2013 - 12:21 AM

Yep. It selected the first slot for refueling instead of slot 16... this messed it up :D

#20 PhilHibbs

  • Members
  • 98 posts

Posted 29 January 2013 - 11:32 PM

So this only stores one type of item per chest, right? How much slower would it be if it were to check all the items in a chest, so I could have a chest for diamonds, rubies, sapphires, and emeralds; another for all kinds of ores; another for all ingots...





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users