I am making an auto moon orbit program.

Tags
Question

3 Comments

  • Log in to leave a comment
  • Profile image
    3,634 JSO18

    @sflanker the problem is that I am not in Luna orbit yet, so it points at the planet but does not do what I want. Is there any way to stay perpendicular to prograde and retrograde while making sure it is in towards the middle of the orbit?

    3.3 years ago
  • Profile image
    3,634 JSO18

    @sflanker thanks! That should really help!

    3.3 years ago
  • Profile image
    Mod sflanker

    It's not a single instruction, but it's not that complicated. Because you can lock heading to a PCI vector all you need to do is lock heading to the radial vector in a loop. Assuming that by "radial" you mean away from your parent body you can just use your position vector (toward the parent body would be your position vector * -1). I'm not sure it is necessary, but I tend to normalize vectors in this case by force of habit.

    3.3 years ago

1 Upvote

Log in in to upvote this post.