I had almost identical problem to tackle. Splines are really slow if you want to spawn them trough code. Niagara may work here.
However i made C++ code that calculates transforms on ellipse (no Kepler calculations, just ellipse with focal points). Transform is done so it always points (rotation) to next point on ellipse, and scale is scaling 1uu to distance between points.
However all that code is in C++ function library, i can provide copy of it, there are multiple functions all blueprintable.
ps (just remembered):
My function draws ellipses in 2d, then i have another function that recalculates array of those transforms into 3d space. I did not work on it for like 9 months (we dropped idea of drawing orbits).
Hello! Did you find a good way to do this?
I tried using a spline with the solar system method that our friend shared, but I wanted the lines to not be affected by distance. For example, when we get closer to the spline, the lines created with the mesh become huge.
I need the lines to maintain the same thickness regardless of distance, just like the debug lines of the spline.
I’m not exactly sure what kind of lines these are, but I managed to get something similar using a wireframe material on the spline mesh. However, now I can’t control the thickness of the wireframe line, so I’m stuck again.
I know that there is a way to scale material to pixels in actual UMG widgets. Maybe there is way to scale it in 3d space. It should be some 3d vector math:
So stuff to consider:
you can make material that uses world coordiantes, and it can draw lines/circles etc that are always 1 meter thick, however that will make those lines thinner further they are.
you can get world position of pixel, and world position of camera
all you need to do is calculate distance, then rescale that 1 meter thick line to something that is same size on screen