Space Engineers

Space Engineers

[UPD 07/2017] Cargo Inventory Sorter
132 kommentarer
kinngrimm 15. apr. 2024 kl. 5:51 
is this still working?
Shrike 9. jan. 2018 kl. 16:30 
i got "script is too complex" error right now
Lord Syanide 26. okt. 2017 kl. 8:00 
Is there an updated complete item name list? I saw in the video to use the comman components.sbc but am unsure where to enter that? Any help would be appreciated!
Эльфик 3. juli 2017 kl. 0:08 
hooray
Sakata 8. maj 2016 kl. 23:02 
Can someone update this, if it's not already being updated? Can't find a decent replacement anywhere....
ente_legent 15. apr. 2016 kl. 19:06 
can somebody fix that?
VORG 2. mar. 2016 kl. 4:52 
CIS SCUM!...haha sorry I had to
Kilstr 29. nov. 2015 kl. 16:55 
Please fix the script before I worked. But now the planets are not.
mar3usmc 7. juni 2015 kl. 11:19 
I think we can all consider this mod abandoned as it has not been updated since January.
Uncle Mel 11. apr. 2015 kl. 12:08 
@Alduin041, check the second to last page of the comments
se7en 9. apr. 2015 kl. 14:02 
would be nice if u add sort of $components:1000 so it will keep only UP to 1k of every component... or maybe there is other script to allow for example moving items to welder ship (selected amount, not all obviously)
r Cubed3 11. mar. 2015 kl. 6:42 
@mrraybaker the script will only touch containers/processing units that begin with "$", if you only have $ with no wildcards, it will try to keep said container empty at all times

the script seems crash if #OTHER becomes full, and i have not had success with sorting a items into multiple containers... best work around i've found is the Large Azimuth container as "#OTHER"
HisEvilness 10. mar. 2015 kl. 19:07 
Sorry does not work, even tried to make a setup that is a copy of the screenshot.
Does not sort, restart script, restart game, turn of the whole factory etc etc.
-CML- Alduin041 8. mar. 2015 kl. 16:58 
Can someone please paste all known terms used for sorting (such as: Ammo ETC...)
raymazoida 8. mar. 2015 kl. 14:04 
Not sure why but this just doesn't seem to be working properly.

I have the timer set up, running the script every 2 seconds, I have a #OTHER container, a $ore and a $components

I also have another large container that had a load of stuff in it

Nothing gets moved out of the large container, no components get moved to $ components, either from the other cargo or from my assemblers, the only thing it does do is move ingots to #OTHER

Am I doing somthing wrong?
NameEnterer 7. mar. 2015 kl. 2:12 
Wouldn't it be possible with this idea of sorting the cargo to programm a mining drone which only collects one kind of ore? Like mining a tunnel till the drills dont get any more iron an then drilling to the sides to look if theres some iron, then rotating and mining in the new direction?
Lighted Shadows 6. mar. 2015 kl. 18:45 
Can I have more than 1 cargo container collect that same ore like $ CargoL1 Iron:ore and $ CargoL2 Iron:ore ?
mar3usmc 4. mar. 2015 kl. 8:37 
Tried to get this to work for over an hour, and have given up. As it has been reported in the past, the unsorted container just fills up and does not then organize anything into the labeled containers.

I think the idea of using an unsorted container as a go between is a very bad idea and seems to be breaking this script. It simply does not work for me.

Consider that I have 26 Large Cargo Containers. The unsorted simply fills up, and then nothing happens. I tried the "all" thing with the other containers, nothing happens.

I haven't seen the author respond in a great deal of time. Seems abandoned.
starman01 4. mar. 2015 kl. 3:14 
Anyone can tell me how I can control my refineries with that ? Sorting sofar works great, but the refinieres don't work correctly...

Example :

One of my refineries (an arc furnace) has vanilla settings to grab iron, nickel and cobalt...

I set it up this way :

$Arc furnace 2 ore iron -nickel -cobalt | $

So this one should refine iron, but ignore the other two. But let's say I have no raw iron, the furnace still collects the nickel (vanilla behaviour) and starts refining for 1 seconds, and then this script here kicks in and withdraw the nickel ore again.... So vanilla code and this script are constantly fighting over the ore, which results in an extrem slow production (because the furnace can only refine for 1 second every 5 seconds)..

Can this be even controlled ? the problem is much worse with the large refinieries since they are allowed to do everthing.
Lumios 1. mar. 2015 kl. 11:56 
Will this sort ammo by type?
Lumios 1. mar. 2015 kl. 11:45 
It would be helpful if you defined all the labels you use to sort. For example...listing all the ores, listing all the ingots, so we know your default terminology.
amsedal 26. feb. 2015 kl. 12:58 
is it possible to also add, say I want a certain amount to stay in a container ... 500 of this and 200 of that and 4000 of this other thing ? basicly my build box with a little bit of everything in it... - great script, cant wait for more, thanks!
hors of discordia 20. feb. 2015 kl. 12:30 
lcd screem!!! use it! to display the total of resource, pleace XD
Damaged Geeenius 19. feb. 2015 kl. 18:57 
It doesn't seem to like cooperative assemblers. I've tried "|$" as their name and a few other combinations but it doesn't seem to actually pull inventory from them.
Maspien 13. feb. 2015 kl. 0:33 
staman it will not take from the refiners at all if you don't name the refiners. The script never touchs the input of a assembler/refiner unless you tell it to.
hors of discordia 8. feb. 2015 kl. 13:26 
seria genial colocar prioridades!
asi se podria hacer convoy de carga y descarga
starman01 8. feb. 2015 kl. 6:38 
Hi,

i'm completly new to all this programming stuff... Since my base has become quite big, I would like to have my inventory sorted automatically (I would do it manually, but the list scrolling is getting longer and longer).

I'm not fully sure how to use this, but according to the explanation I should get along.

However, there is one thing unclear to me and I would like to have that checked first.

When I make one container to select "$ ore" so that it stashes everything not refined yet, and what doesn't fit into the inventory of my refiners, but my refiners already automatically fetch ore from the storage (vanilla, without your script), wouldn't I create a big loop ?

The container would try to collect the ore, and will also take it from the refiner, while the refiner then takes it back from the container.... How do I prevent that ?

Thanks for helping :)
Maspien 28. jan. 2015 kl. 4:11 
Works great but I have a question. Is it possible to tell connectors to not grab items with this? I was looking to set up a system where the ore stays all together and once processed it gets pushed into a assemby area. Once something is made then it gets pushed to a final cargo container that I can pull from when I need stuff.

As of right now the connectors just grab everything and throw them out. You can make a loop but it defeats the purpose of the sorter.
DontBlameMe 26. jan. 2015 kl. 17:46 
Works great for me, thank you very much
Spiritwind 15. jan. 2015 kl. 20:36 
Working fine on my dedicated server.
Beach-Brews 15. jan. 2015 kl. 20:30 
Awesome! Thanks for the script. It has helped me with learning how to modify inventories using the programming block! I was trying to do something using assemblers and welders and couldn't figure out how to get their invetories. I am keeping it around just to keep organized!

However, as a suggestion, try and look into using Regular Expressions instead of using multiple string splits. It would also really help cut down the number of instructions in the "ParseInventoryString" method. Let me know if you want some help!
Capitalist 14. jan. 2015 kl. 7:46 
Mister Goldstein thanks you for helping him sort all his valuable gems!
CoffinDodger 14. jan. 2015 kl. 7:44 
Working as long as none of the continers gets full (which happens very often!)

Could you add more code comments to the next version? It might be easier for us to help you debug it and give feedback - something I'd be happy to help with if you need.
Morvar 13. jan. 2015 kl. 4:23 
Didn't really work here either on dedicated server. Good potential though.
Foximion 13. jan. 2015 kl. 3:19 
Автор вроде понимает русский)
В общем, если две дуговые печи назвать "$Дуговая печь 1 iron:ore |$" и "$Дуговая печь 2 iron:ore |$", то скрипт игнорирует вторую дуговую печь. Это можно как то исправить, либо это ограничение скрипта?

На всякий случай по нерусски затранслейтю)
----------------
If two arc furnaces give names: "$Arc furnace 1 iron:ore |$" and "$Arc furnace 2 iron:ore |$", then the second arc furnace is not processed by the script. Can fix it?
Wolfgang 11. jan. 2015 kl. 19:28 
@SkullBrother / Everyone: From what I understand use just a $ before the inventory name for the inventory to be considered for sorting. Used it on my 27 small drill miner containers and they emptied out into the corresponding large container on my large ship as my refineries were already full. Worked Beautifully.
Wolfgang 11. jan. 2015 kl. 19:23 
very good but does the system work where multiple inventories are all wanting to sort the same items. Like for instance 9x cargo containers (inventories) are all set to collect all the stone. Does each of the inventories share the stone or will only one container be sorted. I see massive utilization of this mod coming from me and my rather large group that plays Space Engineers. - [1COG] Griswaldwolfgan
The Great Ricktator 11. jan. 2015 kl. 16:56 
Had a little trouble figuring out at first but once I did it worked like a dream, its a very handy script
ChoMar 11. jan. 2015 kl. 6:37 
No succes here either on a dedicated server
Ghost Catus 10. jan. 2015 kl. 13:51 
Can someone do a video tutorial on how this is supposed to work? I have alot of stuff in the #Other container and it's not sorting it to the proper places on my mothership. I have 6 Refineries, 4 Arc Furnaces, 4 Cargo Containers, and 2 Assemblers to handle all types of items, but nothing ever moves.
Drakeniir 10. jan. 2015 kl. 10:19 
If I say, wanted to set some containers so that they were sorted but allowed no contents (for instance, when docked to a station, the containers would automatically empty) is that possible? I tried #OTHER but it didn't seem to work..
Caboose -1 9. jan. 2015 kl. 23:22 
ive tried dedicated servers.friends, self host, simple orders. complex orders. it just refuses to move for me. if anyone has any other troubleshooting ideas let me know please. i loved it when it did work.
Caboose -1 9. jan. 2015 kl. 22:10 
I've tried all flavors of ownership. no dice.... I've had it working before.... and beautifully at that.
Sakata 9. jan. 2015 kl. 21:31 
caboose - you probably need it set to owner='Me'. I'm really looking forward to the next bit of updates. This script is imho much better than the other one I've used from the workshop, and seems much more configurable.
Caboose -1 9. jan. 2015 kl. 21:20 
the scripit is running. but nothing is being moved. also have checked. and nothing is full. also everything is set to ownership nobody
Caboose -1 9. jan. 2015 kl. 18:20 
then.... i don't know
Gardentwine 9. jan. 2015 kl. 17:54 
i using it now and it works fine
Caboose -1 9. jan. 2015 kl. 17:26 
did the latest update break it. i can't seam to get it working. had it working before
Gardentwine 9. jan. 2015 kl. 16:40 
Great script Borg, just missing Amount of Item and Overide command would be very usefull for Fine tunning the assembler and refinery
Karelzarath 8. jan. 2015 kl. 23:29 
I fixed the bug where the script stops moving items when it hits a full container. Simply replace line 173 with the following:

var amount = otherItems[j].Amount;

if (amount <= 0)
{
//We moved it all!
break;
}

By default, the TransferItemTo method willl only move as much as it can. If you keep trying successive containers, either they will all fill up or you'll move it all. In light of this, you can also remove the "amount" parameter from CanCarry()