cargoInfo.frontPos = { 0, -0.65, 0.65 };
cargoInfo.rightPos = { 0.65, -0.65, -0.65 };
cargoInfo.leftPos = { -0.65, -0.65, -0.65 };
double stiffness = 100 * GetMass();
double damping = 2 * sqrt(GetMass() * stiffness);
std::array<TOUCHDOWNVTX, 7> tdVtx
{ {
{{ 0, -0.65, 0.65 }, stiffness, damping, 3, 3},
{{ -0.65, -0.65, -0.65 }, stiffness, damping, 3, 3},
{{ 0.65, -0.65, -0.65 }, stiffness, damping, 3, 3},
{{ -0.65, 0.65, -0.65 }, stiffness, damping, 3, 3},
{{ 0.65, 0.65, -0.65 }, stiffness, damping, 3, 3},
{{ -0.65, -0.65, 0.65 }, stiffness, damping, 3, 3},
{{ 0.65, -0.65, 0.65 }, stiffness, damping, 3, 3}
} };
SetTouchdownPoints(tdVtx.data(), tdVtx.size());
// If the cargo was unpacked and it is landed
if (init && status.status)
{
SetGroundRotation(status, cargoInfo.frontPos, cargoInfo.rightPos, cargoInfo.leftPos);
DefSetStateEx(&status);
}
}
It is also based off the cfg. But if the cargo is on the surface it it landed. I can't find that function SetGroundRotation
I think what needs to happen if the vessel is on the ground then make it landed. I think I have that. But it is not landing