Jump to content

[WIP] [1.2.2] SupplyChain - Moving Things from Place to Place in Space


Visionary

Recommended Posts

So, inspired by the KSTS and Routine Mission Manager mods, I've decided to try my hand at making a mod designed to automate resource shuttling (and maybe other things). Much like both KSTS and Routine Mission Manager, this mod relies on essentially recording and replaying flights. However, unlike either of these mods, this mod is designed to be general-- it should be applicable / usable even outside of Kerbin's orbit.

So far I've boiled the concept down to several ideas that I consider key features:

--

Supply Points are where everything happens, essentially. These are specific locations where (for instance) resource transfer happens. Specific types of Point include:

  • Specific orbits (to make things slightly easier only inclination and SMA are looked at when matching orbits)
  • Specific points on the surface
  • Vessels in orbit / on the surface.

Resource Transfer can be performed after a vessel has "proven" it can dock in the given situation (surface docking is tracked separately from orbital docking). This can be done on any body or in any SOI-- one can perform "trial docking" in LKO and then perform resource transfer around the Mun.

Supply Links allow a specific vessel to move from Point to Point. In order to create a Link, you must begin at the origin Point and do whatever is necessary to get to the destination Point. For example, making a Kerbin Orbit -> Mun Orbit Supply Link will require you to perform TLI, get into the proper orbit, etc.

The following statistics are currently tracked when recording a Link:

  • Vessel Mass: The vessel mass at the beginning of a recording will determine a mass limit for future traversals-- if your vessel masses 20 tons when you begin recording, then that same vessel will only be able to traverse that link later if it masses <= 20 tons.
  • Vessel Resources: Resource levels at the beginning and end of recordings are tracked. If the resource level at the end of a recording is less than what it was at the beginning, the deficit is considered to be a requirement and will be consumed on later traversals. I.E if you use up 476 units of LF and 582 units of OX when performing your recorded Kerbin->Mun transfer, then later traversals will use the same amount.
  • Time: Much like resources, the total MET between the beginning and end of recording is tracked. Later traversals take the same amount of time.

Each vessel's selection of available Links and Points is specific to that vessel only, not to the vessel type as a whole.

Supply Chains are sequences of Actions (which include resource transfers, Supply Link traversals, etc.) that can be specified to run periodically, run on certain triggers, or simply on command. One should, for instance, be able to specify a Supply Chain to automatically land a vessel, have it mine, and then return LFO or Ore to a station in orbit; resupply life support resources for surface / orbital bases, etc.

--

So far I have orbital Supply Points and Supply Links working, as well as orbital resource transfer. Next up: Supply Chains and Automation.

If you want to see what's been done so far, here's a link to the repo: https://github.com/stmobo/SupplyChain

Be warned, this is very much a work in progress, and this is actually my first time writing in C# specifically and my first time making a KSP mod. The GUI is rough, there are probably tons of bugs lurking, I'm probably doing certain operations in the worst way possible, etc. But it does work. Sort of.

--

I'd like to thank the creators of KSTS, Hyperedit, and SCANSat-- their mod code has really helped act as a reference for mine when the API documentation here fell short.

Edited by Visionary
Link to comment
Share on other sites

  • 1 month later...
  • 3 weeks later...
  • 3 months later...
7 hours ago, alexandertheII said:

Man, that is a really great idea for a mod. Any idea when it will be out for 1.3?

 

dont hold ya breath for this one,theres been no activity from the poster since december

Link to comment
Share on other sites

14 hours ago, alexandertheII said:

Very sad, was a very promising idea. Any suggestions for something similar that one could use? Except KSTS, already know that one.

there is routine mission manager though it probably needs an update for 1.3 

ive also seen roverdude is working on something similar but no clue when and if that will be ready....i believe it was somewhere in the mks thread feel free to try finding it lol

 

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...