ATOMIC SPACE NEWS #6: Binaries and other fun things

I was feeling down on my most recent progress until I pulled back up News#5 realized just how much I’ve really done in the last month. Last time, I’d just got saving and loading working. A few things have happened since then.


I’ve gotten most of the way to making objects sharing a mutual center of mass, like binary stars or binary planets, work in the editor. There are a few hiccups in saving out final state vectors for simulation, but the path to solving them seems a clear one to me. I’m not going to go down it until some other things are cleared out, because binary systems aren’t a requirement to hit the next milestone I’m aiming for, but it’s definitely on the to do list later.

Here’s a snapshot of a binary system in the editor. It may not be immediately evident at a glance, but the central ‘Nirgal System’ marker does not represent a physical object, but rather the shared center of mass of the stars Anlil and Naanlil. A different icon for this kind of object might be a good idea. The outline of a dot perhaps, rather than a filled one? The main object dot is probably going to get replaced at some point too, so that can wait till then.

An interesting wrinkle that I didn’t realize would crop up before really getting into the math here is that if you’re designing a binary system, the mass and separation are interconnected such that you can only set one of them independently. What I mean by that is that you can have each star be of a specific mass, then set their total separation from each other, or you can set their individual orbital radii and set the total mass of the system. Then the editor will have to distribute appropriate portions of the set total value based on the independent values. At the moment I’ve only implemented one of these two options, the one with setting the masses of the objects independently.


Getting system loading by the simulation working led surprisingly easily into a very rewarding other feature, one button testing. The editor now has a button that will immediately fire off a simulation of the currently loaded system. Seen below, a quick snippet of simulation of the famous[link]Trappist-1 star system

link to full size video

I’ve not yet got it to where I can immediately jump into a test of race gameplay from the editor, but I’m closing in on that, and it’s my next major target.


The current thing on my plate is getting mission goals from the editor into the simulation. While working on that I decided it’d likely help people if the objectives were drawn visibly. Even with all my playing with my test scene I’ve never been entirely certain how close I need to get, I picked the distance for the objectives relatively at random and simply know from experience that it’s not that hard to hit, but neither is it that easy.

So I did that. Here’s an Io intercept, both from normal reference and from Io reference. No other objectives are completed, so you can see the difference in how they’re drawn.

In the future there may be a few different kinds of objectives. So far four major ones have come to mind.

  • Get within distance X at least once
  • Get beyond distance X at least once
  • Never get within distance X
  • Never get beyond distance X

Maybe there are more, but those are the obvious ones so far. None of them should be that hard to represent in code, either.

That’s most of the month’s progress. Maybe next time I’ll have hit that milestone of going from editor to full playable level. Getting very close!

Leave a Reply