Since the autorove mod is not updated, and it does not seem like it will happen soon, I'm considering assume maintenance. However, my first attempt in getting it to work in KSP 1.1.2 was only partially successfull.
My first autorove ended up underground.... That's no good
Currently the mod is calculating the height at which to place the rover, at a given latitude/longitude on a specific body like this.
internal static double surfaceHeight(double latitude, double longitude, CelestialBody body)
{
Vector3d pqsRadialVector = QuaternionD.AngleAxis(longitude, Vector3d.down) * QuaternionD.AngleAxis(latitude, Vector3d.forward) * Vector3d.right;
double altitude = body.pqsController.GetSurfaceHeight(pqsRadialVector) - body.pqsController.radius;
return altitude;
}
Now my question is, what is the best way to calculate the height to put the vessel after moving it. There must be some robust way of determining where to spawn the vessel, I'm just not sure how.
Can anybody help me figuring this out?