Weird that SLS and STS2016 both have an issue in Open Orbiter. They thrusters fire but the rocket does not move
//*******Body flap
static UINT bfGrp[1] = { GRP_Group2 };
static MGROUP_ROTATE BodyFlap(midx, bfGrp, 1,
_V(0, -2.199202, -12.13037), _V(-1, 0, 0), (float)(34.2 * RAD));
anim_bodyflap = CreateAnimation(0.34);
AddAnimationComponent(anim_bodyflap, 0, 1, &BodyFlap);
if (status == 1)bodyflap = 0;
if (status == 3)bodyflap = .34;
case OAPI_KEY_L:
{
RevertDockingRing();
DoIDARing();
//case OAPI_KEY_B: // deploy/retract speedbrake
// if (!Playback()) RevertSpeedbrake();
return 1;
}
void Atlantis::DoIDARing()
{
VECTOR3 new_dock_pos = SHUTTLE_DOCKPOS;
new_dock_pos.y += (soft_capture_ring_proc * 0.4);//0.45
OBJHANDLE v = GetHandle();
int idx = 0; // dock index
OBJHANDLE docked_ship = GetDockStatus(GetDockHandle(0)); // object handle of docked vessel
if (docked_ship != NULL) // make sure handle is valid, if it is...
{
VESSEL* docked = oapiGetVesselInterface(docked_ship); // get VESSEL interface for docked vessel
int dcount = docked->DockCount(); // get number of docking ports
for (int i = 0; i < dcount; i++) // Cycle through ports
{
if (docked->GetDockStatus(docked->GetDockHandle(i)) == GetHandle())
{
idx = i;
docked->Undock(idx, 0);
SetDockParams(hDockODS1, new_dock_pos, SHUTTLE_DOCKDIR, SHUTTLE_DOCKROT);
docked->Dock(v, idx, 0, 0);
}
}
}
else {
SetDockParams(hDockODS1, new_dock_pos, SHUTTLE_DOCKDIR, SHUTTLE_DOCKROT);
}
}
//dockring
if (ODS == 1) {//ODS is present
if (DOCKRING_status >= HATCH_RAISING) {
double da = simdt * .1;
if (DOCKRING_status == HATCH_RAISING) {
if (soft_capture_ring_proc > 0.0) soft_capture_ring_proc = max(0.0, soft_capture_ring_proc - da);
else DOCKRING_status = HATCH_UP;
}
else {
if (soft_capture_ring_proc < 1.0) soft_capture_ring_proc = min(1.0, soft_capture_ring_proc + da);
else DOCKRING_status = HATCH_DOWN;
}
SetAnimation(anim_DOCKRING, soft_capture_ring_proc);
}
}
UUUGGGGHHHHH. This fighting me tooth and nail. I think the easy way to do it Use the SSU ODS as is and magically move the mesh to fit the STS2016 shuttle external lock.
Thanks. I can get the mesh to fit. just not the animation. BUt I am thinking just show the ODS mesh and move it to the correct location. Then all the animation should be the same as SSU code.Might not fit to your Orbiter mesh though, the SSV/SSU payload bay is wider and generally, the dimensions are pretty far apart from the default Orbiter mesh. I believe up to 60 cm difference in some locations, but @DaveS is the nuts and bolts counter and expert on that subject.
CreateDock(_V(-0.042, 0, 2.136), _V(0, 0, 1), _V(0, -1, 0));
CreateDock(_V(-0.006, 0.000, - 2.125), _V(0, 0, -1), _V(0.500011, -0.866019, 0));
void Atlantis::DoIDARing()
{
if (TUNNELODS == 1) {
VECTOR3 new_dock_pos = _V(-0.042, 2.2250, 8.2264);;
new_dock_pos.y += (soft_capture_ring_proc * 0.4);//0.45
OBJHANDLE v = GetHandle();
int idx = 0; // dock index
OBJHANDLE docked_ship = GetDockStatus(GetDockHandle(0)); // object handle of docked vessel
if (docked_ship != NULL) // make sure handle is valid, if it is...
{
VESSEL* docked = oapiGetVesselInterface(docked_ship); // get VESSEL interface for docked vessel
int dcount = docked->DockCount(); // get number of docking ports
for (int i = 0; i < dcount; i++) // Cycle through ports
{
if (docked->GetDockStatus(docked->GetDockHandle(i)) == GetHandle())
{
idx = i;
docked->Undock(idx, 0);
SetDockParams(hDockODS2, new_dock_pos, SHUTTLE_DOCKDIR, SHUTTLE_DOCKROT);
//sprintf(oapiDebugString(), "SHUTTLE_DOCKDIR.x %lf SHUTTLE_DOCKDIR.y %lf SHUTTLE_DOCKDIR.z %lf SHUTTLE_DOCKROT.x %lf SHUTTLE_DOCKROT.y %lf SHUTTLE_DOCKROT.z %lf", SHUTTLE_DOCKDIR.x, SHUTTLE_DOCKDIR.y, SHUTTLE_DOCKDIR.z, SHUTTLE_DOCKROT.x, SHUTTLE_DOCKROT.y, SHUTTLE_DOCKROT.z);
docked->Dock(v, idx, 0, 0);
}
}
}
else {
SetDockParams(hDockODS2, new_dock_pos, SHUTTLE_DOCKDIR, SHUTTLE_DOCKROT);
}
}
}
CreateDock(_V(-0.006, 0.000, - 2.125), _V(0, 0, -1), _V(0.500011, -0.866019, 0));
which is 30 degrees offset