A couple of questions so Hope someone can help.
I am trying to create 6 new vessels. Then attach them to the mother vessel and from the mother ship interact with a module.
This is the code I am using to create the 6 vessels. But I get a CTD right now. If only create 1 vessel then no CTD.
cfg for leonovairbag1B
So once they are created then attach to the mother ship.
I am trying to create 6 new vessels. Then attach them to the mother vessel and from the mother ship interact with a module.
This is the code I am using to create the 6 vessels. But I get a CTD right now. If only create 1 vessel then no CTD.
Code:
void LEONOVOEXT::Airbag_Check()
{
OBJHANDLE airbag;
VESSELSTATUS2 vs;
vs.version = 2;
GetStatusEx (&vs);
VESSEL *airbag_vessel;
ATTACHMENTHANDLE airbag_attach;
if (airbag_created == 0 && airbag_jettison == 0)
{
airbag = oapiCreateVesselEx ("Airbag1", "leonovairbag1B", &vs);
airbag = oapiCreateVesselEx ("Airbag2", "leonovairbag2B", &vs);
airbag = oapiCreateVesselEx ("Airbag3", "leonovairbag3B", &vs);
airbag = oapiCreateVesselEx ("Airbag4", "leonovairbag4B", &vs);
airbag = oapiCreateVesselEx ("Airbag5", "leonovairbag5B", &vs);
airbag = oapiCreateVesselEx ("Airbag6", "leonovairbag6B", &vs);
//airbag_vessel = oapiGetVesselInterface (airbag);
//airbag_attach = airbag_vessel->GetAttachmentHandle (1, 0);
//AttachChild (airbag, BAG1, airbag_attach);
airbag_created =1;
} }
Code:
; === Configuration file for vessel class DeltaGlider ===
ClassName = leonovairbag1
MeshName = leonovairbag1
;Module = LEOAIRBAG
So once they are created then attach to the mother ship.