Space Engineers

Space Engineers

Supply Lines
37 Comments
[-SL-] Apophis 11 Jan @ 3:24am 
Hey TechCoder (and you may be interested norto22),

I have made a small change to the script that allows filtering the storage containers by some configuration in the Custom Data of the programmable block. Do you have this on GitHub (or other version control) where I may open a Pull Request so other may benefit?
norto22 24 Mar, 2024 @ 4:52am 
Yeah, sorry - I probably explained it rather poorly initially. Anything like that which you could add would be very appreciated, if at all possible.

On another note, I absolutely love SL so thankyou for bringing this into the game!
TechCoder  [author] 24 Mar, 2024 @ 4:32am 
I do now understand better what you are asking and like the idea - at the surface - though the challenge is that IIM _often_ reallocates containers - and often uses Ores and Ingots in the same one. I haven't used IIM in quite some time (too many bugs there for awhile and too complex IMHO...) The complexity of configuration complicates any program trying to work in conjunction - adding a lot of 'overhead' to just to 'reverse engineer' the IIM algorithm and break it down to "oh, this/these container(s)...".

I don't like the idea of adding all that 'bulk' - though, perhaps adding a config in SL to designate container(s) is not a bad idea....
norto22 23 Mar, 2024 @ 6:13pm 
Well, then the percentage would be for that container - not the entire storage on the grid so I could set it so I want 15% of my Ore container storage to be Iron ore, 5% Silver ore and so on.

Allows more accurate allocation of resources to specific containers rather than the entire grid storage
TechCoder  [author] 23 Mar, 2024 @ 2:32pm 
Not sure how that would "be really good" - nor any different result than we have now. We look in all Containers for the data.
norto22 21 Mar, 2024 @ 9:38pm 
Is there a way to make this look in certain containers? I'm using Isy's Inv Manager and it would be really good if I could set the ore count to look in just the ore container that's set by IIM, and same for ingots.
kinngrimm 24 Feb, 2024 @ 7:15pm 
" must be 'smooth' "
:) yes
TechCoder  [author] 23 Jan, 2024 @ 10:10am 
I've worked on doing 'components' quite a bit and even the current workshop version _can_ do it, but it takes quite a bit of work to set up the parts (not a script issue, but in the way they are named in the code). There is a 'v2' version I have on my game and it does components (which the script doesn't care if it is for a building or a gun - whatever) and much of what you have described, however, with all the 'gotchas' of the clunky way the game handles it, I haven't published it because it would look like the script is the issue (probably why nobody has done anything like this before.... - just a lot of UGLY stuff to go through in the code....)

I may take it up again but the end result must be 'smooth', or I won't release it, and the components going on the list certainly don't make that simple!
kinngrimm 20 Jan, 2024 @ 8:51pm 
besides munition, components would be the next big topic. Have them shoved on docking welder ships, removed from grinder ships. Put onto a transporter restocking a carrier, unloading the carrier.
kinngrimm 20 Jan, 2024 @ 8:48pm 
Simplified this works like an inverted pressure valve, right? Not enough, open the valve, too much close it.

Does the script only manage sorters on the same grid where the PB is or also connected grids/subgrids?

Does this work with munition? Say i have a container on a ship i want to keep filled up with 1/3 each of 3 types of munition? Would i need to have an additional script running on that ship? Does it have to be incoming sorters or could it be outgoing sorters in those cases?
Napier 13 Oct, 2023 @ 5:16am 
Thanks for creating this, I will be looking at implementing this once once I get automated mining running. Those ship refueling notes just below might be important enough to add to the script description so that users don't overlook that element.
SKY.fungi-guy 12 May, 2023 @ 1:20pm 
Very cool! Thank you!
TechCoder  [author] 20 Feb, 2023 @ 3:35am 
With the published version of SL, you will need to gather any 'fuel' for your drones (well, anything other than battery charge) from another connector - or, you could also use an 'outgoing' Sorter in parallel to only deliver U and/or other fuel to them.
R5Dad 19 Feb, 2023 @ 3:50pm 
Still searching through comments. I need to be able to refill my drones with uranium. Can't seem to get it to refill once I add the sorter. Any suggestions?
TechCoder  [author] 1 Jan, 2023 @ 10:24am 
hmmmm, that is interesting, though it sounds like whatever you are using to copy/paste is adding some sort of other characters (macs often do that from what I've seen with clients). Be sure to use the 'paste as plain text' or 'paste without formatting' option - my guess is it will work just fine (as from your description it doesn't seem to be the code itself because it reads "plain' text that the script puts in there)
Deadmeat 31 Dec, 2022 @ 11:29pm 
I have noticed That if you put "Gravel=-0+0" it says that "Gravel" is not found see https:// (you know the rest). I did some testing and found that anything that is set to "=-0+0" in the "Custom Data" of the PB, gives the same error, and the scrip seems to stop processing the list at that point.

Update: If you remove all off the lines that have "=-0+0" in the "Custom Data" of the PB, and recompile the program it puts them back in, but the script works with out the error. So only if you copy and paste the "Custom Data" example and change it to have "=-0+0" or type them in manually with "=-0+0" does it not work. I hope this helps.
TechCoder  [author] 22 Dec, 2022 @ 12:34pm 
Custom ores/ingots (and 'soon' - when I get some time from IRL...- components..) _should_ work, though it all depends on how those custom things are programmed. Supply Lines uses standard SE notation (as referenced in the docs) and as long as the custom stuff works like that, I know of no reason it won't work - however,.... I have not tried and currently don't have it in my bandwidth to test (there's a LOT of stuff on that link you gave!). Drop into the Discord and put out the question - maybe somebody has more info and we can all work together to get the answer.
Battlemage 22 Dec, 2022 @ 5:48am 
Is there any way to add in custom ore & ingots? I've been trying to add Ganymite to the custom data list but it keeps breaking the script.
TechCoder  [author] 6 Dec, 2022 @ 8:46am 
@Brianetta - that is the sort of thing I think SE needs... - some 'application' stuff that works together. Give SL a try and see what you think - get on my Discord and we can talk about how these scripts can complement and maybe work together.
Brianetta 6 Dec, 2022 @ 8:32am 
This looks like a really good companion to my Printer Toner (or, my script Printer Toner might be a really good companion to Supply Lines). One handles the movement of materials, the other their assembly into components.
TigersFangs 29 Nov, 2022 @ 5:01pm 
@SlientFur I am sincerely hoping that you are joking even though it is a really horrible joke.

TechCoder has made a great little inventory monitoring system here that controls conveyor sorters and allows you to determine how much of your available inventory space you would like to allow to be used by various ores and ingots (can't wait for components!). From my understanding and experience, it doesn't currently interface directly with any scripts (SAM integration is supposedly in the works). What it does is allows things like PAM, Resource Drills, Transport Ships, and other resource collectors/generators/gatherers/transporters to function more autonomously without overloading your storage systems or constantly requiring your intervention.

PAM does none of this. PAM does mining, salvaging, and transport. If anything, adding this script to a base that you have setup PAM to dock to will just allow PAM to be more efficient and effective. Not really sure what you think was stolen...
TechCoder  [author] 29 Nov, 2022 @ 3:14pm 
"stole the PAM stuff....", hmmm - not sure how you might think that true in any fashion..... The screenshots do show other scripts that this system supports/enhances and I am happy to pay royalties to any/all authors at current standard rates - from every penny I make off this script (you DID pay for your copy, right?????) I think you should check whatever 'law' you think you are quoting before you start accusing someone of "STOLE".......

If anything, I have (from various comments) 'breathed new life' into SAM and PAM by enhancing their activities.

You are certainly welcome to your opinion - I just ask that you show your legal reference before calling anyone a thief!
MrFox 29 Nov, 2022 @ 1:31pm 
BRO YOU STOLE THE PAM STUFF HOW DARE YOU!!!
BIV 29 Nov, 2022 @ 10:17am 
This looks like a really handy script for controlling and tracking al the different ores / ingots that are in your stores or not. Well done on a 'simple' looking script (I'm sure it's a lot more complex than I'm suggesting) when someone gets later on in the game and your builds become larger and components become more complex this will really ease that stress of tracking down ingots etc that are needed. Great work mate.
TigersFangs 28 Nov, 2022 @ 6:15pm 
@TechCoder: Love it! Not good enough myself to figure out how to make something like this, even if it is simple as you say. This nicely fills the gap and prevents system overload. I figured that PAM would work with a simple backlog system since the miners/salvagers won't undock until their cargo is emptied. Not sure about PAM shuttle mode... Looking forward to seeing how you integrate this with SAM.

As for the 'Event Controller'/Logic Block, yes, I already have some BIG plans for those in ALL of my builds. :lunar2020playfuldog:
TechCoder  [author] 28 Nov, 2022 @ 4:11am 
@TigersFangs - Glad you like it!
You are very right - this script controls the flow of ores/ingots at the individual level, where IIM doesn't.

Integration with SAM is in the works and planned to be more than 'activate timer'. PAM is already 'done' as those ships start/stop/load/unload with the script-controlled Sorters. (if you are looking for timers/conditions, there's a new block coming out soon that may be what you want!)

@Abisius - This script controls the Sorters that are tagged in the Group you set up for the script to use.....

I don't know about weaponcore (other than it is very popular) - never used it, etc., though unless it wants to control all Sorters, then there likely won't be an issue.

Why not TRY IT YOURSELF and see? Then, you become the 'expert' on it! (and, if you find any issues, you are much better equipped to figure out the cause because you know both programs). There is nothing that I know of in this (fairly simple) script that could bother others.
Abisius Xarvenius Carbensius 27 Nov, 2022 @ 7:20pm 
@TechCoder
would this work with weaponcore?
i ask cause most weaponcore weapons are based on sorters to be able to use advanced functions and as far as i understand the moddescription the script controls the sorters.
TigersFangs 27 Nov, 2022 @ 5:01pm 
This is a really neat script! Glad that someone made one like this. I have wanted a way to do some sort of management like this for a while and things like TIM or ISY just don't quite have the control that I would like. The full management that you have here is excellent. I'll give this a try with some of my worlds that I am playing now.

I am curious to see how you integrate it with PAM and SAM. You could potentially rig it to optionally activate timers when conditions are met for certain items in addition to Conveyor Sorter control. Something like Iron Ingots <x activate timer A, =x activate timer B, >x activate timer C. Then people could use timers to activate other scripts or actions.

Not a coder, just an amateur that dabbles so I don't know how simple that would be to implement or if it would even work for what you have in mind.

Thanks for taking the time to make this script! Very much looking forward to using it! :lunar2019grinningpig:
Quickshadow10m 27 Nov, 2022 @ 9:01am 
I purchased SE in 2019, played it off and on for a while, the BIGGEST problem I have with it is really the lack of functioning MMO due to lag. I love the concept of SE but I need it to have options for MMO. If so,, I would 100% rejoin SE, love scripts, love the building systems and etc, is the lag problem for MMO's solved?
Tinhead111 27 Nov, 2022 @ 7:40am 
This script will even get better with the next SE Patch!
TechCoder  [author] 26 Nov, 2022 @ 8:56am 
THANKS! (and thanks to all who have made this a TOP RATED script - in just a few days!)

I've always felt this was something I needed, I'm very glad that others are finding it useful as well.

We all have had to 'hack' at various things here/there to make the bases we need - I'm hoping to bring Supply Lines to a point that at least a portion of those hacks can go away!

I'm working on SAMv2 now to get it more integrated - far more difficult than we'd like, though I'm trying some work-arounds as well (don't like them, but then, it is SE.... :) - things are slowly coming together, so "stay tuned" as they say!

and @Dots - I hear you - your ideas have been discussed before and likely that is at least part of the direction, though I want SL to be more than a PAM/SAM start/stop button! (part of being just a start/stop is that you'd have to configure which ships do what ores, etc. - sorters are much simpler to control)
Marredone 26 Nov, 2022 @ 8:36am 
This is way more efficient than the jank I've been doing for something similar. Neat!
Dots 26 Nov, 2022 @ 2:29am 
this is a very cool script but i prefer a free flow without sorters and just let Isy's Inv Manager to sort things out because my base is constantly expanding. I would also like to have the script on a LCD say that it detected all of the above mods/scripts when booting this script up. Basically this script is like the cherry on cake but I shal wait a bit longer before use. Instead of sorters I would just use the antena to send out cmd lines with arguements like apply for PAM-Controller or start/stop for SAM.
DlriumTrgger 25 Nov, 2022 @ 9:23pm 
i feel like the next update would address some these concerns
TechCoder  [author] 25 Nov, 2022 @ 4:42am 
Glad you see a use for it - be sure to let us know (and 'like' if that suits) how it went for you.

Note that the plan is to expand this soon to include 'delivery' of things from other bases (truly supplying....), so watch for that in the near future
Titan Nya 25 Nov, 2022 @ 4:37am 
So... It's basically the script I made using VSB but WAY better (I was using lots of connectors to connect to own grid to offload the drill to the main base based on ingots)
So I guess I'll test it out later xD Just restarting and will probably setup this script to transmute ingots/ores that i have too much into ones I don't have much (gonna think on how ot set it up correctly xD)
kota 22 Nov, 2022 @ 9:56pm 
nice