|
|
|
|
@ -187,6 +187,8 @@ static Vec3 calc_orbital_velocity(CelestialBody* body, CelestialBody* parent) {
|
|
|
|
|
assert(v_squared >= 0); |
|
|
|
|
double speed = (double) sqrt(v_squared); |
|
|
|
|
|
|
|
|
|
// FIXME: this whole section is just wrong and will break with inclined orbits
|
|
|
|
|
// it's also a failure of our testing that we're not catching it
|
|
|
|
|
Vec3 z_axis = {0.0, 0.0, 1.0}; |
|
|
|
|
Vec3 vel_dir = vec3_cross(z_axis, r); |
|
|
|
|
|
|
|
|
|
|