r/KerbalSpaceProgram • • Jun 26 '22

Self assembling space station

14.5k Upvotes

427 comments sorted by

View all comments

979

u/lodurr_voluspa Jun 26 '22

My latest science station has a full crew compliment of 40, replete with a fuel depot, communications pod, and docking zone. The hab area doubles as life rafts, as they can each detach and survive re-entry.

Also, it puts itself together for me, which is nice.The assembly is sped up to be respectful of the viewers time.

Actual assembly is about 6 minutes. One of the biggest issues was that the physics engine seems to impart some excess energy to the docking vessels immediately after they are docked. Normal physics don't seem to affect it, as even very clean docks to large objects result in some violent rocking motion. So the pods had to be able to account for that and reset if their path was interrupted by the reaction of another pod docking.

0

u/[deleted] Jun 26 '22

[deleted]

257

u/lodurr_voluspa Jun 26 '22

Dockus assemblarium!

47

u/[deleted] Jun 26 '22

Gravity: You dare use my own spell against me Voluspa!

8

u/GarlicThread Jun 26 '22

Biggus Dockus!

→ More replies (1)

71

u/15_Redstones Jun 26 '22

Just excess energy or also momentum out of nowhere?

Energy I could understand if docking ports have a strong attractive pair potential between each other.

111

u/lodurr_voluspa Jun 26 '22

It seems to teleport ever so slightly and also aquire some rotational momentum.

I tried turning the docking magnets way down but it could still rock heavily during the lightest docking. I think the game engine just has some artifacts as it recalculates the size of the vessel.

33

u/KerPop42 KSP Is an Aero Sim First Jun 26 '22

Probably also the CoM of the vessel

9

u/[deleted] Jun 27 '22

yeah sounds like game engine error like position and speeds in all vectors is recalculated and there might be tiny rounding errors which result in the rapid changes you see when they're applied the instant you dock. I would expect ksp to look at the new craft as one fully new connected craft instead of a sum of its multiple parts.

does the error change with distance to kerbin? I read somewhere that kerbin is the 0,0,0 point in the game and the further you go the more floating point errors you'd get, but it might be an old hat

0

u/[deleted] Jun 26 '22

[deleted]

97

u/lodurr_voluspa Jun 26 '22

I've been hesitant to release scripts since they are often wonky and cobbled together and my life is too complicated at the moment to properly support them.

So I think my plan is to create some youtube videos on the basic principles behind how some of my scripts work with some code explained as I go.

0

u/[deleted] Jun 26 '22

[deleted]

38

u/lodurr_voluspa Jun 26 '22

I'll work on getting something our there.

9

u/JedisLikeToForceFuck Jun 27 '22

Your efforts will be appreciated brother

6

u/quantumhealer42069 Jun 26 '22

This is insanely cool, well done GG

5

u/SpaceHub Jun 26 '22

I just throw out whatever I have since I use git to maintain them locally anyways.

Breaking the functions into a lot of files helps a lot with maintaining sanity.

→ More replies (5)

15

u/viperfan7 Jun 26 '22

Does it do collision detection of any kind? Or is it just predefined paths?

39

u/lodurr_voluspa Jun 26 '22

Rudimentary collision detection. No predefined paths at all. You can pack it into pretty much any configuration and it will sort itself out.

38

u/Tom_Brokaw_is_a_Punk Jun 26 '22

Me: Barely able to get into orbit with MechJeb

You:

10

u/viperfan7 Jun 26 '22

Oh that is sexy

→ More replies (3)

6

u/MightBBlueovrU Jun 27 '22

So what did you do to make this happen? I'm sorry I am a vetnoob , I've been playing for years but am still such a novice. Can you do a video or link me something to learn it. I am at like a skylab level rn I have alot of research but that many do king's at once. I mean dang

→ More replies (1)
→ More replies (9)